Hacker Newsnew | past | comments | ask | show | jobs | submit | pupppet's commentslogin

Why is this set as a meta tag rather than via CSS with html{text-scale:scale} for example?

The linked explainer [1] gets into this:

"The new CSS env(preferred-text-scale) variable provides a mechanism for authors to respect the user’s text scale setting that they’ve set either in their operating system or web browser settings. Authors can use it to scale the font-size and alter the layout accordingly.

Note: See the env(preferred-text-scale) Explainer [2] for a comparison of the various ways users can scale content and examples of how to use the environment variable.

However, if authors have already used font-relative units like rem and em to conform to the Resize Text guideline, the browser could automatically incorporate the OS-level text scale setting into those font-relative units. This would allow authors to avoid having to determine the precise elements to apply the env() variable to.

We propose a new HTML meta tag that tells the user agent to apply the scaling factor from env(preferred-text-scale) to the entire page. We expect it will become best practice for authors to use this meta tag, just as they would use the viewport meta tag. The environment variable would be reserved for atypical use cases."

There's no need for a text-scale CSS property because font-size already exists. The latter explainer [2] suggests that developers use font-size: calc(100% * env(preferred-text-scale)) to get the desired effect, if they are doing this in CSS rather than with just the meta tag.

[1] https://github.com/w3c/csswg-drafts/blob/main/css-env-1/expl... [2] https://github.com/w3c/csswg-drafts/blob/main/css-env-1/expl...


Actually I don't think the explainer gets into the full story. The reality is it's not CSS's problem. It's the browsers that have historically made text scaling weird on each platform that they support.

And now just like with the viewport meta tag, we need a meta tag to say, 'Stop doing that please. Make the default font size in my CSS work the way it always should have'.

The other reason why the flag can't be in CSS is because it needs to make em and rem units in media queries get affected by the user's text scale. See the explainer for more info on that.


Speculation on my part: Your site either supports accessible text scaling, or it doesn't. If only partly supports it – it might as well not at all.

So disappointing.

It won't replace all engineers, but it will replace many. Code is no longer some precious resource. You now turn on the tap and code flows out, and it requires only so many people to turn on a tap.

Yeah man, remember when Biden called people retards and piggy, used his position to make millions off memecoins, draped his mug and name over government institutions, bulldozed half the White House, wanted to take over multiple countries, sicced masked idiots on the poor, pulled out of the WHO, the list goes on.

[flagged]


"I have clear evidence of wrongdoing in one case, and admittedly not very good evidence of wrongdoing in the other... I prefer the former."

Epistemologically insane, and that's not to mention the plainly obvious fact that even if the corruption were equal (which you openly admit actually doesn't comport with visible evidence), doing it visibly is clearly much more harmful to our society.

Taken to the extreme, someone can be the most rotten, corrupt soul on the planet, and so long as they truly keep it to themselves, none of us would even know about it, much less be affected by it.


[flagged]


A tree falling in the forest with no one to hear it is in fact of far less nuisance and risk than a tree that falls on top of a house.

A more important question: How would someone look if they walked around insisting that a tree had recently fallen, but they can't tell you when/where/how because no one was around to hear it?

"But trust me, it was just as big as the one that fell on Bob's house, so I don't even see what anyone is upset about."


Probably just a broken blood vessel in the eye.

Not sure why this was downvoted, his people literally just confirmed this.

There once was a lady in France,

Whose right fist struck as if by chance;

  Her husband, called M...on,

  Said his eyesight was gone,
“Just an eye infection, come on!”

Is this a really bad attempt at a Limerick or some other form I'm not familiar with?

Let’s rename our breadwinner MS Office to the product we’re still trying to find a use for.

What a load of BS, Canada is the best friend the US could ask for.

Remember in 2018 when Canada held Huawei CFO Meng Wanzhou under a U.S. extradition request? It tanked Canada/China relations and had trade ramifications Canada is still feeling today.


It's quite odd, the past days there's been this messaging from different users about how old allies haven't been good allies. First I saw this point about Denmark, now Canada.

Hard to understand where this is coming from, it's really odd to see it popping up out of nowhere when barely a year ago this would never have been brought up about any of these countries... Where is the messaging coming from?


That’s fair enough. Part of it is the Trump effect. I tend to dive pretty deep into things when they catch my interest. A lot of time we write things off as crazy simply because we don’t understand the context behind the presumption of insanity. So I try to look under the surface so to speak. I want to know why someone feels the way they do, even if their thesis is a little confused. Almost like: “I see you are very passionate about this, let me figure out why.”

I try to make the world make sense. Communication is a skill and many otherwise smart people simply fail to invest in it. Curiousity I suppose.


With that argument we should give the US all of Europe.

A̶O̶L̶ Humans Online

Sort of. Those of us outside the US are aware his support hasn’t cratered. There’s going to be the concern the US will just swap him out for someone similar.

If past history is anything to go by, the US will elect the current opposition, who won't be nearly strong enough to enact the reforms that would prevent an extremist party from returning to power in 4 years' time.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: