Checkbox.scss
1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/* packageMine/pages/questionnaire/components/Checkbox/Checkbox.wxss */
.checkbox-item {
margin-bottom: 20rpx;
font-size: 28rpx;
color: #333333;
line-height: 40rpx;
display: flex;
align-items: center;
word-wrap: break-word;
.icon {
width: 24rpx;
height: 24rpx;
border: 2rpx solid #999999;
border-radius: 4rpx;
flex-shrink: 0;
margin-right: 10rpx;
transition: all .25s;
}
.active {
border-color: var(--themeColor);
position: relative;
&::after {
width: 28rpx;
height: 28rpx;
content: '';
position: absolute;
top: 50%;
left: 50%;
animation: radio-active .25s forwards;
background: url(https://img02.glsx.com.cn/weapp/resource/miniprogram/wuye/questionnaire/checkbox.png) no-repeat;
background-size: 100%;
}
}
@keyframes radio-active {
0%{
opacity: 0;
transform: translate(-50%,-50%) scale(.1);
}
100%{
opacity: 1;
transform: translate(-50%,-50%) scale(1);
}
}
}