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

Add automated ids for vertical slides #3566

Open
cjdb opened this issue Feb 3, 2024 · 0 comments
Open

Add automated ids for vertical slides #3566

cjdb opened this issue Feb 3, 2024 · 0 comments

Comments

@cjdb
Copy link

cjdb commented Feb 3, 2024

Problem

I like to name my vertical slides the same thing as the first slide, but with an index. This makes it easier for me to find specific slides without needing to come up with novel names when they're not particularly helpful.

I'm currently doing a lot of manual naming, like id="intro-0", id="intro-1", etc., which can be error-prone if I add a slide between two existing slides or move content around.

Proposed solution

It'd be nice if I could inform reveal.js to take use the id field of a top-level slide to automate naming its nested slides. I haven't been able to find anything that fills this niche in the documentation.

Example

<section id="intro"
         data-markdown="content/introduction.md"
         data-separator="^\n\n\n"
         data-separator-vertical="^\n\n"
         data-separator-notes="^Note:">
</section>
## Page 1


## Page 2


## Page 3
Page URL before change URL after change
Page 1 http://localhost:8000/#/1 http://localhost:8000/#/intro/1
Page 2 http://localhost:8000/#/1/1 http://localhost:8000/#/intro/2
Page 3 http://localhost:8000/#/1/2 http://localhost:8000/#/intro/3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant