Skip to content
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

Semantic section markup #874

Open
ploeh opened this issue Mar 14, 2023 · 1 comment
Open

Semantic section markup #874

ploeh opened this issue Mar 14, 2023 · 1 comment

Comments

@ploeh
Copy link
Owner

ploeh commented Mar 14, 2023

When I migrated the blog to Jekyll (or possibly even before that), I just decided to use h3 tags for section headers.

I don't use h2 og h4, etc. so this looks consistent enough, but is semantically wrong. While I could probably do a search and replace, just replacing all the h3 tags with h1 is not going to look good, so I would also need to edit the blog's style sheet.

Additionally, I don't have a good grasp of what the Jekyll Bootstrap theme I'm using is doing when it comes to actual blog post titles and other headers like that. Does it use h1 for that?

And, I now reveal my abysmal ignorance of HTML and front-end technology, is there a more appropriate tag to use for those section headers? Is the semantic web still a thing?

@Danielovich
Copy link
Contributor

Unwrapping these

bootstrap.min.css seems a default Bootstrap theme.

style.css is your overwrites.

If you wish a different font-size for your h3 you can go into you style.css and adjust:

/* Permalinks */
h3 a {
font-size: 0.5em;
color: #f5f5f5;
}

/* show permalink when hovering over matching header /
h3:hover a {
color: #2a6496; /
copied from bootstrap.min.css */
}

If you wish to overwrite you H1 for the headlines on your posts it's basically the same thing.

My frontend skills are also very limited but I guess it suffices in this complex case :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants