Skip to content

implement headingoffset & headingreset attributes #11086

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

Draft
wants to merge 22 commits into
base: main
Choose a base branch
from

Conversation

keithamus
Copy link
Member

@keithamus keithamus commented Feb 28, 2025

This specifies the headingoffset and headingstart attributes as proposed in #5033.

Closes #5033

(See WHATWG Working Mode: Changes for more details.)


/dom.html ( diff )
/index.html ( diff )
/infrastructure.html ( diff )
/sections.html ( diff )

@scottaohara
Copy link
Collaborator

thank you for working on this.

aside from the comments i left in my quick review, does it make sense to explicitly call out as a note that aria-level is not considered/taken into account with these attributes?

from re-reading the issue this stems from, i'm assuming people are likely thinking that if someone declares an aria-level on a heading, the value of that attribute is what the heading level will be exposed as, yes?

Or to be very clear, do people agree with the following:

<div headingoffset=1>
  <h1 aria-level=4> level 4 </h1>
  <h1> level 2 </h1>
  <h1 headingoffset=20 headingreset aria-level=3><!-- 3 --></h1>
</div>

if HTML doesn't have a note for this, then we can get it into html aam, aria in html, or both - and i'd assume MDN author guidance.

@domenic
Copy link
Member

domenic commented Mar 1, 2025

I haven't looked at the PR text itself yet, but I think such a note/example would be valuable.

@keithamus
Copy link
Member Author

I've added a note mentioning aria-level as well as an example demonstrating their combinations.

Copy link
Member

@annevk annevk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is not marked as draft and is still getting updates I'm going to make it extra clear that I consider #5033 (comment) to be blocking concerns.

@keithamus keithamus force-pushed the implement-headingoffset-headingreset-attributes branch from a83d233 to cc8c891 Compare June 27, 2025 12:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Consider adding a headingoffset attribute
5 participants