Nesting slots is tricky, and the purpose of our Story objects is to illustrate how they work. In this case, the container object doesn't have a named slot, so providing a name confused the renderer and it didn't render the message as expected. This is now fixed.

This commit is contained in:
Ken Sternberg
2024-11-01 14:28:27 -07:00
parent 3f691b8a76
commit d8c0793f5d

View File

@ -70,5 +70,5 @@ export const DefaultStory: StoryObj = {
export const WithAMessage: StoryObj = {
...DefaultStory,
args: { ...DefaultStory.args, message: html`<p slot="body">Overlay with a message</p>` },
args: { ...DefaultStory.args, message: html`<p>Overlay with a message</p>` },
};