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

When landmark height is 0px, the highlight box looks flat #415

Open
carmacleod opened this issue Feb 9, 2021 · 1 comment
Open

When landmark height is 0px, the highlight box looks flat #415

carmacleod opened this issue Feb 9, 2021 · 1 comment
Milestone

Comments

@carmacleod
Copy link

If all children of a landmark have CSS float, the landmark height is 0px.
This looks "off" when the highlight box is drawn around the landmark.
For example, the nav inside the banner on https://www.paciellogroup.com/

How about making a rudimentary guess at the height of a 0px-high landmark by using the height of the first child (well, the first one that has height)? I realize that won't be correct all the time, but maybe it will catch a bunch of cases? Just a thought. :)

@matatk matatk added this to the next milestone Feb 14, 2021
@matatk
Copy link
Owner

matatk commented Feb 14, 2021

I've noticed this before, and wondered if there are any good heuristics that could be used. What you suggest sounds reasonable. I plan to look into it for the next release, though may need to test it for a while before it can be be released. If there's a reliable way to figure out the height of all contained elements, and it isn't too slow, that might be the way to go.

My concern about his before is that it may produce misleading results for devs (implying the landmark is somewhere else), though the DevTools panel would help address that, and the "flat" landmark does look confusing to someone who isn't a developer.

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