Created
November 28, 2016 20:33
-
-
Save EliJDonahue/01334c5563355374c9ba4c3d81d3ae39 to your computer and use it in GitHub Desktop.
Use CSS counters to auto-number Aras Tech Doc sections
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Set a CSS counter using counter-reset (starts at 0) */ | |
body { | |
counter-reset: sectionNum; | |
} | |
/* Increment sectionNum counter at each .Section element */ | |
.Section { | |
counter-increment: sectionNum; | |
} | |
/* Display sectionNum value before each Section Title */ | |
.Section>.Title::before { | |
content: counter(sectionNum, upper-alpha) ". "; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment