Skip to content

Commit 5565d44

Browse files
committed
style: 样式多尺寸适配
1 parent 478e924 commit 5565d44

7 files changed

Lines changed: 28 additions & 23 deletions

File tree

src/packages/calendarcard/calendarcard.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
border-radius: scale-px(12px);
44
overflow: hidden;
55
font-size: $calendar-base-font-size;
6+
line-height: $calendar-base-font-size;
67
color: $color-title;
78

89
&-header {

src/packages/inputnumber/inputnumber.scss

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323
height: $inputnumber-button-height;
2424
background-color: $inputnumber-button-background-color;
2525
.nut-icon {
26-
--nut-icon-width: scale-px(10px);
27-
--nut-icon-height: scale-px(10px);
26+
width: scale-px(10px);
27+
height: scale-px(10px);
2828
}
2929
}
3030

@@ -66,12 +66,12 @@
6666
}
6767

6868
&-icon-minus {
69-
--nut-icon-width: scale-px(16px);
70-
--nut-icon-height: scale-px(16px);
69+
width: scale-px(16px);
70+
height: scale-px(16px);
7171
}
7272

7373
&-icon-plus {
74-
--nut-icon-width: scale-px(16px);
75-
--nut-icon-height: scale-px(16px);
74+
width: scale-px(16px);
75+
height: scale-px(16px);
7676
}
7777
}

src/packages/price/price.scss

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
&-decimal {
1111
color: $price-color;
1212
font-family: 'JDZH-Bold';
13-
line-height: 1;
1413
}
1514

1615
&-darkgray {
@@ -39,18 +38,22 @@
3938
padding-right: $price-symbol-padding-right;
4039
&-xlarge {
4140
font-size: $price-symbol-xlarge-size;
41+
line-height: $price-symbol-xlarge-size;
4242
}
4343

4444
&-large {
4545
font-size: $price-symbol-large-size;
46+
line-height: $price-symbol-large-size;
4647
}
4748

4849
&-normal {
4950
font-size: $price-symbol-normal-size;
51+
line-height: $price-symbol-normal-size;
5052
}
5153

5254
&-small {
5355
font-size: $price-symbol-small-size;
56+
line-height: $price-symbol-small-size;
5457
}
5558

5659
&-rtl {
@@ -62,45 +65,44 @@
6265
&-integer {
6366
&-xlarge {
6467
font-size: $price-integer-xlarge-size;
65-
/* #ifdef dynamic */
6668
line-height: $price-integer-xlarge-size;
67-
/* #endif */
6869
}
6970

7071
&-large {
7172
font-size: $price-integer-large-size;
72-
/* #ifdef dynamic */
7373
line-height: $price-integer-large-size;
74-
/* #endif */
7574
}
7675

7776
&-normal {
7877
font-size: $price-integer-normal-size;
79-
/* #ifdef dynamic */
8078
line-height: $price-integer-normal-size;
81-
/* #endif */
8279
}
8380

8481
&-small {
8582
font-size: $price-integer-small-size;
83+
line-height: $price-integer-small-size;
8684
}
8785
}
8886

8987
&-decimal {
9088
&-xlarge {
9189
font-size: $price-decimal-xlarge-size;
90+
line-height: $price-decimal-xlarge-size;
9291
}
9392

9493
&-large {
9594
font-size: $price-decimal-large-size;
95+
line-height: $price-decimal-large-size;
9696
}
9797

9898
&-normal {
9999
font-size: $price-decimal-normal-size;
100+
line-height: $price-decimal-normal-size;
100101
}
101102

102103
&-small {
103104
font-size: $price-decimal-small-size;
105+
line-height: $price-decimal-small-size;
104106
}
105107
}
106108

src/packages/rate/rate.scss

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,20 +106,22 @@
106106
align-items: center;
107107
color: $rate-font-color;
108108
font-family: 'JDZH-Regular';
109-
line-height: 1;
110109

111110
&-normal {
112111
padding-left: $rate-item-margin;
113112
font-size: $rate-font-size;
113+
line-height: $rate-font-size;
114114
}
115115

116116
&-large {
117117
font-size: calc($rate-font-size + scale-font-px(6px));
118+
line-height: calc($rate-font-size + scale-font-px(6px));
118119
padding-left: calc($rate-item-margin * 2);
119120
}
120121

121122
&-small {
122123
font-size: calc($rate-font-size - scale-font-px(2px));
124+
line-height: calc($rate-font-size - scale-font-px(2px));
123125
padding-left: calc($rate-item-margin / 2);
124126
}
125127

src/packages/segmented/segmented.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
border-radius: $segmented-item-radius;
2424
color: $segmented-item-color;
2525
font-size: $segmented-item-fontsize;
26-
line-height: 1;
26+
line-height: $segmented-item-fontsize;
2727
box-sizing: border-box;
2828
}
2929

src/packages/shortpassword/shortpassword.scss

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
&-title {
1111
display: flex;
1212
justify-content: center;
13-
line-height: 1;
13+
line-height: $font-size-l;
1414
font-size: $font-size-l;
1515
color: $color-title;
1616
}
@@ -20,7 +20,7 @@
2020
justify-content: center;
2121
margin-top: scale-px(12px);
2222
margin-bottom: scale-px(24px);
23-
line-height: 1;
23+
line-height: $font-size-s;
2424
font-size: $font-size-s;
2525
color: $color-text;
2626
}
@@ -85,13 +85,13 @@
8585
width: scale-px(247px);
8686

8787
&-error {
88-
line-height: 1;
88+
line-height: $font-size-xs;
8989
font-size: $font-size-xs;
9090
color: $shortpassword-error;
9191
}
9292

9393
&-forget {
94-
line-height: 1;
94+
line-height: $font-size-s;
9595
font-size: $font-size-s;
9696
color: $shortpassword-forget;
9797
display: flex;
@@ -113,7 +113,7 @@
113113
border: scale-px(1px) solid $color-primary;
114114
border-radius: scale-px(15px);
115115
padding: scale-px(8px) scale-px(38px);
116-
line-height: 1;
116+
line-height: $font-size-base;
117117
font-size: $font-size-base;
118118
color: $color-primary;
119119
}
@@ -126,7 +126,7 @@
126126
);
127127
border-radius: scale-px(15px);
128128
padding: scale-px(8px) scale-px(38px);
129-
line-height: 1;
129+
line-height: $font-size-base;
130130
font-size: $font-size-base;
131131
color: $color-primary-text;
132132
}

src/packages/tour/tour.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
text-align: end;
3030

3131
&-close {
32-
--nut-icon-width: scale-px(10px);
33-
--nut-icon-height: scale-px(10px);
32+
width: scale-px(10px);
33+
height: scale-px(10px);
3434
}
3535
}
3636

0 commit comments

Comments
 (0)