如何更改 React Native 中安全区域中项目的文本颜色?
How can I change text color of items in safe area in React Native?
我正在尝试根据 react-native-ui-kitten 中的主题更改 SafeAreaView
中文本和其他图标的颜色(检查此 Screenshot)。我尝试在样式表中设置颜色但效果不佳。
我认为你应该使用 StatusBar
- 一个反应本机基础组件来改变你的项目颜色。
https://reactnative.dev/docs/statusbar#barstyle
您可以这样尝试 Status bar's props barStyle
:
import { StatusBar } from 'react-native';
...
<StatusBar barStyle="light-content" /> //or "dark-content"
...
我正在尝试根据 react-native-ui-kitten 中的主题更改 SafeAreaView
中文本和其他图标的颜色(检查此 Screenshot)。我尝试在样式表中设置颜色但效果不佳。
我认为你应该使用 StatusBar
- 一个反应本机基础组件来改变你的项目颜色。
https://reactnative.dev/docs/statusbar#barstyle
您可以这样尝试 Status bar's props barStyle
:
import { StatusBar } from 'react-native';
...
<StatusBar barStyle="light-content" /> //or "dark-content"
...