试图自定义单选按钮。它适用于背景或按钮大小,但不适用于图标大小、颜色和定位。
有什么问题?
这是我的代码和结果。
Radio.js
import { Platform } from "react-native";
import variable from "./../variables/platform";
export default (variables = variable) => {
const radioTheme = {
backgroundColor: '#000',
width: 20,
height: 20,
lineHeight: 20,
".selected": {
color: '#7ED321',
"NativeBase.IconNB": {
color: '#7ED321',
lineHeight: '20',
fontSize: '20'
}
},
"NativeBase.IconNB": {
color: '#7ED321',
lineHeight: '20',
fontSize: '20'
}
};
return radioTheme;
};
这是按钮的位置、大小和颜色。(颜色应该是绿色的十六进制)