- From: Benny Powers via GitHub <sysbot+gh@w3.org>
- Date: Wed, 06 Oct 2021 08:17:31 +0000
- To: public-css-archive@w3.org
Case: Slide decks. Author wants to compose private notes for each slide, and display them onscreen only when the parent deck element has a `presenter` attribute.
```html
<slide-deck>
#shadow-root
<style>
/* ...etc */
::host([presenter]) ::slotted([active])::part(notes) {
display: block;
/* show notes for the active slide outside the presentation area */
transform: translateY(30%);
}
</style>
<!-- slides -->
<slot></slot>
<slide-slide>
#shadow-root
<style>#notes { display: none; }</style>
<slot></slot>
<div part="notes"><slot name="notes"></slot></div>
<p>Slide Content!</p>
<p slot="notes">Be exuberant when presenting this slide</p>
</slide-slide>
</slide-deck>
```
--
GitHub Notification of comment by bennypowers
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/3896#issuecomment-935723396 using your GitHub account
--
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 6 October 2021 08:17:32 UTC