You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If it's truly a subtitle and title
So, generally, a subtitle should be a <p> immediately after a heading (any <h#>). So if we wanted to visually put the sub-title above the heading, I'd flip it with CSS (flex-direction: column-reverse or something like that).
An example of a title with a subtitle could be:
h1: Learning about web accessibility
p: Or, how I stopped worrying about ARIA and embrace HTML
If it's truly a heading and a lower level heading
But... I went looking in the docs and it looks like the intend use of {subtitle} is to be the title of the tour overall, not actually to be a subtitle to the individual tour step.
If that's the case, I'd drop the h1 to an h2 and the h2 to an h3 and that's probably all that needs to happen.
An example of a heading and lower level heading:
h2: Learning about web accessibility
h3: History of ARIA
If we're not sure and we need to support both
No great answer here. Probably just need to go with whichever pattern we think will be most common.
Activity
myasonik commentedon Jun 1, 2021
🤔 As usual... It depends.
If it's truly a subtitle and title
So, generally, a subtitle should be a
<p>immediately after a heading (any<h#>). So if we wanted to visually put the sub-title above the heading, I'd flip it with CSS (flex-direction: column-reverseor something like that).An example of a title with a subtitle could be:
If it's truly a heading and a lower level heading
But... I went looking in the docs and it looks like the intend use of
{subtitle}is to be the title of the tour overall, not actually to be a subtitle to the individual tour step.If that's the case, I'd drop the
h1to anh2and theh2to anh3and that's probably all that needs to happen.An example of a heading and lower level heading:
If we're not sure and we need to support both
No great answer here. Probably just need to go with whichever pattern we think will be most common.