/* 自定義 radio 樣式 */
radio{
width: 38rpx;
}
radio .wx-radio-input{
border-radius: 50%;
width: 28rpx;
height: 28rpx;
}
/* 選中后的樣式 (可根據設計稿需求自己修改) */
radio .wx-radio-input.wx-radio-input-checked::before{
border-radius: 50%;
width: 44rpx;
height: 44rpx; /
line-height: 44rpx;
text-align: center;
font-size: 26rpx; /* 對勾大小 26rpx */
color:#fff; /* 對勾顏色 */
background: #2facff;
border-color: #2facff;
}
/* 自定義 checkbox 樣式 */
checkbox-group{
width: 50rpx;
}
/* 未選中的 背景樣式 */
checkbox .wx-checkbox-input{
border-radius: 50%;/* 圓角 */
width: 40rpx; /* 背景的寬 */
height: 40rpx; /* 背景的高 */
}
/* 選中后的樣式 (可根據設計稿需求自己修改) */
checkbox .wx-checkbox-input.wx-checkbox-input-checked{
background: #2facff;
border-color: #2facff;
}
checkbox .wx-checkbox-input.wx-checkbox-input-checked::before{
border-radius: 50%;
width: 46rpx;
height: 46rpx;
line-height: 46rpx;
text-align: center;
font-size: 28rpx; /* 對勾大小 28rpx */
color: #fff; /* 對勾顏色 白色 */
background: transparent;
transform: translate(-50%, -50%) scale(1);
-webkit-transform: translate(-50%, -50%) scale(1);
}
原文:https://blog.csdn.net/Hug_rj/article/details/82017393