微信小程序自定义checkbox样式

作者: wechat 发布时间: 2021-01-26 浏览: 2106 次 编辑
微信小程序自定义checkbox样式
checkbox .wx-checkbox-input{
  width:16px;
  height:16px;

}
checkbox .wx-checkbox-input.wx-checkbox-input-checked{
  border-color:#e33c2b !important;
  background:#e33c2b !important;

}
checkbox .wx-checkbox-input.wx-checkbox-input-checked::before{
  width:16px;
  height:16px;
  line-height:16px;
  text-align:center;
  font-size:12px;
  color:#fff;
  background:transparent;
  transform:translate(-50%, -50%) scale(1);
  -webkit-transform:translate(-50%, -50%) scale(1);
}