←back to thread

197 points OuterVale | 2 comments | | HN request time: 0.485s | source
Show context
nfw2 ◴[] No.46227886[source]
I'd like to propose for the list:

Default heading styles should not have equal top and bottom margin. Headings should be closer to the content they label than to the content they are setting their content apart from.

h1, h2, h3 should not have different styles. it's an anti-pattern that leads to broken accessibility

replies(4): >>46228089 #>>46228201 #>>46228647 #>>46230155 #
IshKebab ◴[] No.46230155[source]
> h1, h2, h3 should not have different styles. it's an anti-pattern that leads to broken accessibility

How does that hurt accessibility? Are you saying people use h3 in order to get its style even when they didn't mean h3?

I think the opposite could happen too - if they all have the same style then people might just use h1 everywhere which is probably just as bad. People tend not to use elements that have no obvious use, like <output> which apparently has better accessibility but does absolutely nothing else, so nobody bothers. The whole "semantic web" thing failed partly because of this.

replies(1): >>46230165 #
1. nfw2 ◴[] No.46230165[source]
> Are you saying people use h3 in order to get its style

yes, and that people assume the purpose of having different tags is to control styling

replies(1): >>46232071 #
2. IshKebab ◴[] No.46232071[source]
I mean, they aren't wrong. That is part of the purpose. Of course now we try and do it via CSS but it's definitely still fine to use <b> as bold and <i> as italic, even if the semantic pedants will insist that they mean "Bring attention to" and "Idiomatic" (that name's stretched so thin you can see through it!).