-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Controller: @phase2/outline-controller-slot-manager
#389
base: next
Are you sure you want to change the base?
Conversation
|
✅ Deploy Preview for outlinejs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@phase2/outline-controller-slot-manager
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add code examples for usage with ShadowDOM, LightDOM and how to handle a single unnamed (default) slot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At a core level, I'd like to see/discuss this being moved into TWO controllers.
- Controller 1:
SlotManager
- Has all sorts of cool slot tools for ALL components that have slots.- Testing if a slot exists
- Conditional rendering a slot
- Controller 2:
SlotShifter
(lol) - This one should, and I know this is a pain be a standalone piece that can be additive to theSlotManager
.- Can this EXTEND the
SlotManager
to add in the additional functionality related to managing slot movement/event delegation/etc??
- Can this EXTEND the
TODO:
|
WalkthroughThe update introduces the Changes
TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 9
Configuration used: CodeRabbit UI
Files ignored due to path filters (2)
packages/controllers/slot-manager/package.json
is excluded by:!**/*.json
packages/controllers/slot-manager/tsconfig.build.json
is excluded by:!**/*.json
Files selected for processing (3)
- packages/controllers/slot-manager/README.md (1 hunks)
- packages/controllers/slot-manager/index.ts (1 hunks)
- packages/controllers/slot-manager/src/slot-manager.ts (1 hunks)
Files skipped from review due to trivial changes (1)
- packages/controllers/slot-manager/index.ts
Additional comments: 1
packages/controllers/slot-manager/src/slot-manager.ts (1)
- 373-400: The
conditionalSlot
method's implementation is clear, but ensure that the use ofifDefined
andclassMap
fromlit
is optimal for the intended use cases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files selected for processing (1)
- packages/controllers/slot-manager/src/slot-manager.ts (1 hunks)
Files skipped from review as they are similar to previous changes (1)
- packages/controllers/slot-manager/src/slot-manager.ts
@coderabbitai review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files ignored due to path filters (1)
packages/controllers/slot-manager/package.json
is excluded by:!**/*.json
Files selected for processing (2)
- packages/controllers/slot-manager/README.md (1 hunks)
- packages/controllers/slot-manager/src/slot-manager.ts (1 hunks)
Files skipped from review as they are similar to previous changes (2)
- packages/controllers/slot-manager/README.md
- packages/controllers/slot-manager/src/slot-manager.ts
Description
Separated Slot Controller into its own package and renamed as Slot Manager
Summary by CodeRabbit
SlotManager
for enhanced slot management within the shadow DOM, including cloning slots, adding annotations, and event dispatching between shadow and light DOM slots.SlotManager
with usage and feature documentation.SlotManager
class fromsrc/slot-manager
in a newindex.ts
file.slot-manager.ts
file with theSlotManager
class for managing slots in Lit web components.