You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: css-env-1/explainers/meta-text-scale.md
+27Lines changed: 27 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -143,6 +143,33 @@ That means:
143
143
144
144
We expect `scale` to become best practice for authors to use on all new website designs, just as they use the viewport meta tag. It allows authors to continue to use font-relative units like `rem` and `em` like they normally would and mostly avoid using `env(preferred-text-scale)`.
145
145
146
+
> [!NOTE]
147
+
> It has been pointed out that these two approaches
148
+
> **currently behave identically** on mobile,
149
+
> though there is a theoretical difference in the specification:
> * **With `<meta>`:** (r)em-based media queries **will include** the OS-level font setting.
166
+
> * **With `:root`:** (r)em-based media queries **will NOT include** the OS-level font setting.
167
+
>
168
+
> *The difference is theoretical because the `env` spec says
169
+
> [`env()` works in media queries](https://drafts.csswg.org/css-env-1/#valdef-env-preferred-text-scale:~:text=Because%20environment%20variables%20don%E2%80%99t%20depend%20on%20the%20value),
170
+
> but no browser supports that as of 2025.
171
+
> Consequently, there is no difference.*
172
+
146
173
### Comparison of `legacy` and `scale`
147
174
148
175
This comparison table summarises our proposal. **`legacy`** describes current behavior. **`scale`** represents a simple way for sites to obey the OS-level text settings.
0 commit comments