3 ms·
I agree that we should just let the computer keep track of heading levels. TFA suggests, convincingly to me, that "<h1>" would serve this purpose as well as "<h
by jessaustin 10y ago
I agree that we should just let the computer keep track of heading levels. TFA suggests, convincingly to me, that "<h1>" would serve this purpose as well as "<h>". This wouldn't even run afoul of CSS single-pass concerns the way that lots of reasonable styling requests do. The first time the browser sees "<h1>", the immediate parent is the top level. Any child with an "<h1>" is the next level, any sibling with one is the same level, and so on.
- crooked-v 10y agoThis is how section tags were supposed to work with headers, but nobody ever implemented it.
- arthur2e5 10y agoChrome 58 gives a smaller font size (1.5em, same as <h2>) for <h1> elements under <section> and friends: /* user agent stylesheet */ :-webkit-any(article,aside,nav,section) h1 { font-size: 1.5em; -webkit-margin-before: 0.83em; -webkit-margin-after: 0.83em; } And <h1> keeps shrinking as you nest <section>s. So yes, someone has actually implemented it. (I personally don't like the <article> part, but well -- whatever.)