4 ms·
Wow, they managed to make a website that scales everything except the main text when adjusting the browser's zoom setting.
by cwillu 2y ago
Wow, they managed to make a website that scales everything except the main text when adjusting the browser's zoom setting.
- rezonant 2y agoThere should be a law for this. Who in their right mind wants this?
- essentia0 2y agoThey set the root font size relative to the total width of the screen (1.04vw) with the rest of the styling using rem units Ive never seen anyone do that before.. It may well be the only way to circumvent browser zoom
- rendaw 2y agoWhy don't browsers reduce the screen width when you zoom in, as they adjust every other unit (cm, px)?
- zamadatix 2y agoThey effectively do. All css absolute units are effectively defined as ratios of each other and zoom*DPI*physicalPixels sets the ratio of how many physical pixels each absolute unit will end up turning into. Increase zoom and the screen seems to have shrunk to some smaller 'cm' and so on. For things like 'vh' and 'vw' it just doesn't matter "how many cm" the screen is as 20% of the viewing space always comes out to 20% of the viewing space regardless how many 'cm' that is said to be equivalent to.
- rendaw 2y agoOh duh, right. Thanks!
- imglorp 2y agoWhy is it so desirable to circumvent browser zoom? I hate it.
- hiisukun 2y agoIt's interesting how this (and other css?) means the website is readable in a phone in portrait, but the text is tiny in landscape!
- BiteCode_dev 2y agoIt's a quantum zoom: it's zoomed in and not zoomed in at the same time.