I want to change all button style, without having to add style one after another like that:
<Button mode="contained" style={{ backgroundColor: "#FF6766" }} >
I'm trying to do something with that:
const theme = {
...DefaultTheme,
roundness: 2,
colors: {
...DefaultTheme.colors,
primary: '#ffffff',
accent: '#f1c40f',
text: '#515151',
surface: '#FF6766',
underlineColor: 'transparent',
background: '#ffffff',
contained: '#000000',
}
};
But I don't know if it's possible here, I found this on this link: https://callstack.github.io/react-native-paper/theming.html
App.js
export default function App() {
const theme = {
...DefaultTheme,
roundness: 2,
colors: {
...DefaultTheme.colors,
primary: '#ffffff',
accent: '#f1c40f',
text: '#515151',
surface: '#FF6766',
underlineColor: 'transparent',
background: '#ffffff',
contained: '#000000',
}
};
return (
<PaperProvider theme={theme}>
<AppNavigator />
</PaperProvider>
)
}