如何为React-Native-Nect-Checkbox库设置背景颜色

发布于 2025-02-02 06:09:19 字数 260 浏览 3 评论 0原文

我如何为复选框库设置背景彩色 https://github.com /react-native-native-checkbox/react-native-native-checkbox

我将iOS用作平台。

感谢您的帮助!

How can i set the background-color for checkboxes library https://github.com/react-native-checkbox/react-native-checkbox?

I use iOS as a platform.

Thank you for your help!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

漫漫岁月 2025-02-09 06:09:19

使用tintcolor prop在复选框关闭时设置框的颜色。

使用OnCheckColor Prop在打开时设置复选标记的颜色。

使用onfillcolor prop在打开时设置框内部的颜色。

使用ontintColor在框打开时围绕框的颜色prop。

上述道具的价值将是颜色的十六进制值。

例如

<CheckBox
onFillColor={"#FF5733"}
disabled={false}
value={toggleCheckBox}
onValueChange={(newValue) => setToggleCheckBox(newValue)}
/>

use tintColor prop to set color of the box when the checkbox is Off.

use onCheckColor prop to set color of the check mark when it is On.

use onFillColor prop to set color of the inside of the box when it is On.

use onTintColor prop to The color of the line around the box when it is On.

the value of above mentioned props will be hexadecimal value of color.

For example

<CheckBox
onFillColor={"#FF5733"}
disabled={false}
value={toggleCheckBox}
onValueChange={(newValue) => setToggleCheckBox(newValue)}
/>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文