Open vanadium23 opened 1 week ago
Hmm, there is already a header component. My feeling is that having another field (that sorta work the same, albeit you can do some scss to stick the header on top) would probably make it confusing for end users
Hmm, there is already a header component. My feeling is that having another field (that sorta work the same, albeit you can do some scss to stick the header on top) would probably make it confusing for end users
The header component by default contains the page title, breadcrumbs, and metadata. It is not suitable for this purpose.
Hmm, there is already a header component. My feeling is that having another field (that sorta work the same, albeit you can do some scss to stick the header on top) would probably make it confusing for end users
@aarnphm I agree; I think this is mainly a naming issue. The header is currently located only in the main part. If we follow semantic elements: https://www.w3schools.com/html/html5_semantic_elements.asp, the header should ideally represent the navbar.
However, renaming navbar to header or header to navbar would be backward incompatible. So, we have two options:
The header component by default contains the page title, breadcrumbs, and metadata. It is not suitable for this purpose.
Currently header is empty, all of that component you mention are in beforeBody
The header component by default contains the page title, breadcrumbs, and metadata. It is not suitable for this purpose.
Currently header is empty, all of that component you mention are in beforeBody
Check.
Then I suppose we should move the <header>
tag out of the center and for accuracy sake?
https://github.com/jackyzha0/quartz/blob/v4/quartz%2Fcomponents%2FrenderPage.tsx#L229-L240
I'm not sure if this would be considered a breaking change. I mean, it technically is, but it is not used by default.
Supposedly the <footer>
should also be moved around as it technically supposed to be at the bottom of the page, not the center.
Also, seems we currently have our 'footer' inside the afterBody
.
@aarnphm what do you think about @saberzero1 suggestion?
iirc breadcrumbs is using nav? I might be wrong here
iirc breadcrumbs is using nav? I might be wrong here
It appears you are correct. Breadcrumbs uses the <nav>
tag.
https://github.com/jackyzha0/quartz/blob/v4/quartz%2Fcomponents%2FBreadcrumbs.tsx#L127-L133
Semantic tags wise:
<footer>
, but not for the footer, which is a div with the footer class. <header>
by default. Instead we use a div with the header class. <nav>
for the Breadcrumbs.<article>
for the note content and every popover on the page.Perhaps we should give the semantic elements a pass for accuracy at some point? For example, using the <aside>
for sidebars. Using <main>
for the center. Splitting parts of the note using <section>
, using <nav>
for the Explorer component instead of Breadcrumbs, <time>
for the published date, etc.
yeah, we should a semantic pass.
(wrt
Example from personal website: