在更改checkbox的样式不生效,勾选框还是方形而不是我需要的圆形,查询了一些资料之后,修改如下:
checkbox .wx-checkbox-input {
width: 36rpx !important;
height: 36rpx !important;
border-radius: 50% !important;
border-color: #409eff !important;
}
这些代码需要放在引用该组件的页面的wxss中。
例如,我在组件note中使用checkbox,但是在note.wxss中更改样式是不生效的
因为我是在页面 test-note 中使用了组件 note ,所以我需要将上述代码放在 test-note.wxss 中书写。