Comments (3)
Hey there, I had the same problem some weeks ago, installing the individual font families fixed this for me. I also had to remove 'fontWeight' property from all of my fonts' config. Example code below:
export const fonts {
titleLarge: {
fontFamily: 'RedHatDisplay-ExtraBold',
fontSize: 34,
letterSpacing: 0.37,
lineHeight: 41,
},
bodyMedium: {
fontFamily: 'RedHatDisplay-Medium',
fontSize: 16,
letterSpacing: 0.36,
lineHeight: 34,
},
bodySmall: {
fontFamily: 'RedHatDisplay-Regular',
fontSize: 14
letterSpacing: 0.35,
lineHeight: 46,
},
...
};
This way I set the fontWeight using the specific fontFamily I installed. I also tried using some variable fonts but it seems those aren't compatible yet.
So I'd try removing fontWeight from your fonts' config, and setting it just with fontFamily.
Here's another useful issue you could check: facebook/react-native#42116
from react-native-paper.
thanks for your response.. i tried removing fontWeight but somehow its still not working ..
from react-native-paper.
Only other thing is I noticed you're importing Text
from "react-native". I don't know if you're also importing it that way in other modules but it should be imported from "react-native-paper". That way it'll properly use the fonts provided by your theme.
from react-native-paper.
Related Issues (20)
- Elevation prop does not work for M2 theme
- update value in textField unexpected behavior in ios due secureTextEntry HOT 2
- Usage of defaultProps HOT 2
- fontWeight and custom fontFamily are not working properly together. HOT 3
- Unable to Remove Persistent Shadow from Modal Component in React Native Paper HOT 1
- Documentation about the use of react-native-safe-area-context HOT 5
- Allow Drawer.Item to wrap across multiple lines
- SearchBar's clearIcon to have ability to always stay visible
- The tutorial suggests using App.js but this is missing when creating a project? HOT 2
- Icons "triangle-down" and "triangle-down-outline" don't exist HOT 1
- How can I install "react-native-paper/react-navigation"? HOT 4
- Warning: TextInput.Icon: Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead. HOT 3
- Using Portal and a TextInput with "value=" inside it makes the Backspace key to not behave properly when using finger sliding to write on Android HOT 2
- Badge font-scaling handling doesn't work on iOS
- Button showing weird behaviour HOT 1
- DataTable.Pagination numberOfItemsPerPageList appears in the wrong position HOT 1
- Can you please add Ratting component?
- Fix hover support to web for Drawer.Item component HOT 2
- How can I change icon position using BottomNavigation.Bar in a Tab.Navigator
- How can I change icon position using BottomNavigation.Bar in a Tab.Navigator HOT 1
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-paper.