Fix: map label overlap - #52
Merged
Merged
Conversation
Seven contributors arrived today and put three pairs of names on top of each other: San Francisco over Los Angeles, Paris over Amsterdam, and Toronto over Chicago. Two profile spellings were also unplaceable, so Brisbane had no dot at all and one of the three San Francisco people was counted as located-unknown. The offsets are solved against the names' measured ink rather than nudged by eye. Every one is now clear of every other name, and clear of every dot it does not belong to, at 1200, 1280, 1440 and 1920. Names are 13.5 units instead of 15. These are the map's units, not the screen's, so a name's width in them is what decides whether it collides — which means a bigger map cannot help, the names scale with it. Only shrinking them against the map does, and this is the ~12% of the two crowded spans that buys the next few contributors somewhere to go. They render at 12.5px on a wide screen, against 12.4px before; the floor is 11.6px at `xl`, a size the map already shipped at. The legend gives up a rem and the gap another, which is the only width in a 1188px container the map can grow into: 900px to 929px. "North America" and its share still share one line. Two things this does not fix, both geometry rather than placement. Paris and Barcelona are 21 units apart on almost the same meridian, and San Francisco and Palo Alto are 1.2 units apart, so a name beside either sits nearer a neighbour's dot than its own — no font size changes that, and the tooltip is what distinguishes them. Coincident dots stay countable through the hairline of page background around each mark.
A quarter off the hero's top padding, across the whole clamp so the phone case comes down by the same proportion rather than to nothing. Rendered, through the 0.9 zoom on the homepage sections: 50.4px to 36px between the navbar and the headline at 1440, 43.2 to 32.4 at 1200, 28.8 to 21.6 at 390. The page is 1320px tall at 1440 where it was 1334. The floor stays a floor because it is the only thing keeping the headline off the navbar on a narrow screen, where the headline is also at its largest relative to the space above it.
|
@kerthcet is attempting to deploy a commit to the InftyAI Team on Vercel. A member of the Team first needs to authorize it. |
Member
Author
|
/lgtm |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.