-
Notifications
You must be signed in to change notification settings - Fork 80
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
Consider using explicit markup for each section to avoid numbering-related classes #5
Comments
Running the HTML5 Outliner bookmarklet on the updated HTML shows that the outline is improved: compared to the current sample HTML, where most of the sections are nested under the Introduction: |
Thanks for opening up the issue. I agree that the less special classes we can rely on, the better. The HTML Outliner output for your markup turns out great, so that is definitely a point in your favor. My approach came from trying to make the markup as simple and intuitive as possible. One of my concerns was that for something like subsubsections, you end up with a pretty complex nesting structure as compared to the more linear structure that coding novices and/or Word users might be comfortable with (a la Markdown). It also increases the chances of unmatched tags, or simply forgetting to wrap section tags. I'll experiment with making the PubCSS markup compatible with Paper Now, and see if I run into any issues with my themes while doing that. |
It does seems like requiring sections for every level might be too much to ask of articles authored in Markdown (and in fact Paper Now, where I'm hoping to use the PubCSS styles) only adds a single level of explicit sections. However, the PubCSS template does already use some The main requirement then would be that the heading elements used ( |
Here's an implementation of that idea: master...hubgit:heading-sections The main changes are
|
I like the changes. Having just one However, I think I prefer how in the current version of PubCSS, the heading number corresponds with the depth of numbering: I also like that all of the metadata is tidily contained in There was one problem I ran into with this. A If |
If the template wraps each section explicitly in a
<section>
tag, and usesh1
,h2
, etc +section > section > …
to indicate the depth of nesting, then it's possible to avoid all the.counter-skip
classes by only applying the numbering to headings insidesection
elements.Here's an example: master...hubgit:explicit-sections
The article layout basically looks like this:
The text was updated successfully, but these errors were encountered: