-
Notifications
You must be signed in to change notification settings - Fork 7
Expose Menu placement
attribute
#114
Conversation
🦋 Changeset detectedLatest commit: 2731196 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
c356292
to
f968420
Compare
set open(isOpen) { | ||
this.#isOpen = isOpen; | ||
|
||
if (isOpen) { |
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.
This makes sure Menu responds to assignments to placement
after render. It also ensures Floating UI isn't doing stuff in the background when Menu is closed.
ca7069e
to
39bfd54
Compare
return html`<div style="height: 8rem;"> | ||
<cs-menu size=${arguments_.size || nothing} ?open=${arguments_.open}> | ||
return html`<div | ||
style="height: 13rem; display: flex; align-items: center; justify-content: center;" |
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.
Make room for the various placement options.
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.
This is the only case I know of where we were setting the default this way.
39bfd54
to
2731196
Compare
🚀 Description
N/A
📋 Checklist
exports
inpackages/components/package.json
(if applicable).🔬 How to Test
Open Storybook and play around with the
placement
options.📸 Images/Videos of Functionality
N/A