-
-
Notifications
You must be signed in to change notification settings - Fork 8.5k
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
Theme Classic inconsistently wraps the doc page title into <header> #8476
Comments
Thanks I also noticed that. When introducing the I'm not an expert in semantic HTML and accessibility, does this violate any existing rule, or is it just more convenient for you to crawl the doc and create a search index if things are consistent? |
It was a bit surprising to me that the |
I am not sure either 😅 So I'd prefer if someone can back up with semantic HTML links what we should do exactly before we change anything |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
In my perspective, it would be beneficial for us to consistently include the |
Have you read the Contributing Guidelines on issues?
Prerequisites
npm run clear
oryarn clear
command.rm -rf node_modules yarn.lock package-lock.json
and re-installing packages.Description
The theme inconsistently wraps the title of a doc page into
<header>
: Only when a synthetic title is rendered, it is being wrapped into<header>
. Non-synthetic titles are not wrapped into<header>
.Relevant code:
docusaurus/packages/docusaurus-theme-classic/src/theme/DocItem/Content/index.tsx
Lines 41 to 43 in 024474a
Reproducible demo
https://codesandbox.io/s/dazzling-panini-566sqf
Steps to reproduce
Go to "Tutorial Intro" page: Title not wrapped in
<header>
Go to "Tutorial - Basics" -> "Create a Page": Title is wrapped in
<header>
Expected behavior
The doc title should either always, or never, be wrapped in
<header>
.Actual behavior
The doc page title is wrapped in
<header>
depending on whether it is a synthetic title or not.Your environment
Self-service
The text was updated successfully, but these errors were encountered: