Comments (2)
I don't really know about Android, but on iOS you can set zoom level separately in the Safari's settings. The system's font size settings that you're referring to do not affect websites content.
In Chrome (iOS) I couldn't even change the zoom, and the system's font size setting affected only browser's UI, not the website's content.
So I'd say that it does depend on the browser, and they handle the general zoom, not the font scaling.
from react-native-web.
On Android, the issue is a bit more complex. You can find all the details here
Basically, if you change the font scale in Android params, the browser will apply that scale on the computed style, but only on the fontSize property. This leads to a major problem for developers because, if you set the fontSize of a TextInput to 10px, and the user uses a font scale of 1.2, the TextInput will instead have a fontSize of 12px. Now, if your code also sets the width and height based on the fontSize you provided, you'll end up with a problem because your dimensions are planned for a fontSize of 10px, not 12. For instance, you could specify the lineHeight to be the same of the fontSize, and that would break your design on android.
To clarify, the problem is that the fontScale is being silently applied on the fontSize, but not on the other dimensions.
Notice that ReactNative provides the fontScale value, probably for that specific case. That's why I think it might be important to fix it in RNWeb.
from react-native-web.
Related Issues (20)
- tabIndex doesn't work for values more than 0 HOT 4
- react-native-web with server side rendering boilerplate HOT 1
- role="switch" should map to element <button> HOT 2
- Image in SSR
- Pressable does not accept aria-disabled HOT 2
- Add `draggable` prop to `<Text />`
- Image isn't support aspectRatio style
- onResponderEnd not called when tabbing while holding onto a view HOT 2
- VirtializedList on web error to scroll inverter. Unable to preventDefault inside passive event listener invocation
- onKeyDown is not registered until component is clicked.
- Appearance does not export `setColorScheme`
- Accessibility migration from react native web 18 to 19 is broken HOT 1
- Vite in a SSR context HOT 4
- CSS Style not Inline
- Add "use client" directive for a proper usage with Next App Router HOT 3
- `AppState.isAvailable` is a string instead of a boolean
- When releasing a new version, create a new GitHub "release" HOT 1
- [Feature Request] add support for onTextLayout props of Text component (Reiterating it once again)
- Pressable's onPress method is not triggered by "enter" key when role="link"
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-native-web.