Skip to content
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

fix: global layers #1492

Closed
wants to merge 2 commits into from
Closed

fix: global layers #1492

wants to merge 2 commits into from

Conversation

KermanX
Copy link
Member

@KermanX KermanX commented Apr 2, 2024

This PR:

Copy link

netlify bot commented Apr 2, 2024

Deploy Preview for slidev ready!

Name Link
🔨 Latest commit e7dbea6
🔍 Latest deploy log https://app.netlify.com/sites/slidev/deploys/660bda67fff7540008bf3e70
😎 Deploy Preview https://deploy-preview-1492--slidev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@antfu
Copy link
Member

antfu commented Apr 2, 2024

It breaks my usage of having a single instance of global layers. One of the point of global layers was to live out of slides lifecycle. I think maybe we should still keep the original behavior for playback but only duplicates in print mode (I use the --per-slide flag to workaround it in export, btw).

@KermanX
Copy link
Member Author

KermanX commented Apr 2, 2024

As mentioned in https://sli.dev/custom/global-layers#example, the global layers are used as something like footers. For footers they don't need to be singleton, but should be displayed with each slide. Should we add SlideTop and SlideBottom for footers, while preserving the current usage of global layers? If there are the SlideTop and SlideBottom components, I think the global layers are intended to be used as something like a navigator or so, which should not be printed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants