hy-app 0.2.0 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/components/hy-back-top/index.scss +1 -10
- package/components/hy-badge/index.scss +5 -5
- package/components/hy-button/hy-button.vue +6 -7
- package/components/hy-button/index.scss +4 -11
- package/components/hy-calendar/index.scss +21 -24
- package/components/hy-calendar/month.vue +28 -6
- package/components/hy-calendar/props.ts +1 -1
- package/components/hy-card/index.scss +2 -11
- package/components/hy-cell/index.scss +9 -22
- package/components/hy-checkbox/hy-checkbox.vue +9 -6
- package/components/hy-checkbox/index.scss +14 -17
- package/components/hy-code-input/hy-code-input.vue +223 -0
- package/components/hy-code-input/index.scss +108 -0
- package/components/hy-code-input/props.ts +21 -0
- package/components/hy-code-input/typing.d.ts +65 -0
- package/components/hy-config-provider/hy-config-provider.vue +2 -1
- package/components/hy-config-provider/index.scss +2 -6
- package/components/hy-count-down/index.scss +0 -9
- package/components/hy-count-to/index.scss +1 -9
- package/components/hy-divider/index.scss +2 -1
- package/components/hy-divider/props.ts +2 -2
- package/components/hy-dropdown/index.scss +1 -1
- package/components/hy-dropdown/props.ts +1 -1
- package/components/hy-dropdown-item/hy-dropdown-item.vue +2 -5
- package/components/hy-dropdown-item/index.scss +13 -30
- package/components/hy-empty/index.scss +1 -10
- package/components/hy-float-button/index.scss +4 -9
- package/components/hy-form/index.scss +1 -8
- package/components/hy-grid/hy-grid.vue +5 -5
- package/components/hy-grid/index.scss +1 -1
- package/components/hy-icon/index.scss +4 -9
- package/components/hy-image/hy-image.vue +5 -5
- package/components/hy-image/index.scss +2 -2
- package/components/hy-image/props.ts +1 -1
- package/components/hy-input/hy-input.vue +9 -14
- package/components/hy-input/index.scss +10 -12
- package/components/hy-input/props.ts +1 -1
- package/components/hy-line/index.scss +1 -0
- package/components/hy-line/props.ts +1 -1
- package/components/hy-line-progress/index.scss +1 -12
- package/components/hy-loading/index.scss +2 -2
- package/components/hy-modal/hy-modal.vue +8 -5
- package/components/hy-modal/index.scss +7 -25
- package/components/hy-modal/props.ts +3 -3
- package/components/hy-navbar/index.scss +3 -14
- package/components/hy-notice-bar/index.scss +31 -41
- package/components/hy-notice-bar/props.ts +2 -2
- package/components/hy-notify/hy-notify.vue +169 -0
- package/components/hy-notify/index.scss +25 -0
- package/components/hy-notify/props.ts +14 -0
- package/components/hy-notify/typing.d.ts +44 -0
- package/components/hy-number-step/index.scss +6 -24
- package/components/hy-pagination/hy-pagination.vue +125 -0
- package/components/hy-pagination/index.scss +46 -0
- package/components/hy-pagination/props.ts +15 -0
- package/components/hy-pagination/typing.d.ts +44 -0
- package/components/hy-picker/index.scss +5 -1
- package/components/hy-popup/index.scss +1 -10
- package/components/hy-price/index.scss +0 -6
- package/components/hy-qrcode/index.scss +1 -1
- package/components/hy-radio/hy-radio.vue +8 -5
- package/components/hy-radio/index.scss +16 -18
- package/components/hy-rate/index.scss +1 -6
- package/components/hy-read-more/index.scss +3 -20
- package/components/hy-scroll-list/index.scss +1 -1
- package/components/hy-search/index.scss +6 -26
- package/components/hy-signature/canvasHelper.ts +51 -0
- package/components/hy-signature/hy-signature.vue +656 -0
- package/components/hy-signature/index.scss +31 -0
- package/components/hy-signature/props.ts +28 -0
- package/components/hy-signature/typing.d.ts +177 -0
- package/components/hy-slider/index.scss +6 -2
- package/components/hy-slider/props.ts +2 -2
- package/components/hy-steps/hy-steps.vue +38 -20
- package/components/hy-steps/index.scss +6 -17
- package/components/hy-submit-bar/index.scss +1 -9
- package/components/hy-subsection/index.scss +2 -16
- package/components/hy-swipe-action/hy-swipe-action.vue +288 -248
- package/components/hy-swipe-action/index.scss +32 -7
- package/components/hy-swipe-action/index.ts +34 -0
- package/components/hy-swipe-action/props.ts +15 -9
- package/components/hy-swipe-action/typing.d.ts +20 -22
- package/components/hy-swiper/index.scss +5 -10
- package/components/hy-switch/index.scss +19 -18
- package/components/hy-switch/props.ts +0 -1
- package/components/hy-tabs/index.scss +4 -18
- package/components/hy-tag/index.scss +3 -3
- package/components/hy-text/hy-text.vue +5 -4
- package/components/hy-text/index.scss +3 -15
- package/components/hy-textarea/hy-textarea.vue +5 -5
- package/components/hy-textarea/index.scss +8 -20
- package/components/hy-toast/index.scss +5 -22
- package/components/hy-tooltip/index.scss +7 -5
- package/components/hy-upload/index.scss +5 -15
- package/composables/index.ts +1 -0
- package/composables/useTouch.ts +48 -0
- package/index.scss +1 -0
- package/libs/css/mixin.scss +58 -13
- package/libs/css/vars.css +53 -0
- package/package.json +2 -2
- package/theme.scss +42 -54
- package/components/hy-swipe-action/index.wxs +0 -235
- package/components/hy-swipe-action/wxs.js +0 -15
package/README.md
CHANGED
|
@@ -1,15 +1,6 @@
|
|
|
1
1
|
@use "../../libs/css/mixin.scss" as *;
|
|
2
2
|
@use "../../theme.scss" as *;
|
|
3
3
|
|
|
4
|
-
/* 暗色主题 */
|
|
5
|
-
@include b(theme){
|
|
6
|
-
@include m(dark) {
|
|
7
|
-
@include b(back-top) {
|
|
8
|
-
background-color: $hy-dark-background--track;
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
4
|
@include b(back-top) {
|
|
14
5
|
@include flex;
|
|
15
6
|
flex-direction: column;
|
|
@@ -17,7 +8,7 @@
|
|
|
17
8
|
flex: 1;
|
|
18
9
|
height: 100%;
|
|
19
10
|
justify-content: center;
|
|
20
|
-
background-color:
|
|
11
|
+
background-color: $hy-background--3;
|
|
21
12
|
|
|
22
13
|
&__tips {
|
|
23
14
|
font-size: 12px;
|
|
@@ -33,18 +33,18 @@ $hy-badge-text-font-size: 11px !default;
|
|
|
33
33
|
|
|
34
34
|
/* 主题色 */
|
|
35
35
|
@include themeColor(primary, $hy-primary);
|
|
36
|
-
@include themeColor(primary--inverted, "",
|
|
36
|
+
@include themeColor(primary--inverted, "", transparent, $hy-primary);
|
|
37
37
|
|
|
38
38
|
@include themeColor(error, $hy-error);
|
|
39
|
-
@include themeColor(error--inverted, "",
|
|
39
|
+
@include themeColor(error--inverted, "", transparent, $hy-error);
|
|
40
40
|
|
|
41
41
|
@include themeColor(success, $hy-success);
|
|
42
|
-
@include themeColor(success--inverted, "",
|
|
42
|
+
@include themeColor(success--inverted, "", transparent, $hy-success);
|
|
43
43
|
|
|
44
44
|
@include themeColor(warning, $hy-warning);
|
|
45
|
-
@include themeColor(warning--inverted, "",
|
|
45
|
+
@include themeColor(warning--inverted, "", transparent, $hy-warning);
|
|
46
46
|
|
|
47
47
|
@include themeColor(info, $hy-info);
|
|
48
|
-
@include themeColor(info--inverted, "",
|
|
48
|
+
@include themeColor(info--inverted, "", transparent, $hy-info);
|
|
49
49
|
|
|
50
50
|
}
|
|
@@ -127,13 +127,13 @@
|
|
|
127
127
|
|
|
128
128
|
<script lang="ts">
|
|
129
129
|
export default {
|
|
130
|
-
name:
|
|
130
|
+
name: "hy-button",
|
|
131
131
|
options: {
|
|
132
132
|
addGlobalClass: true,
|
|
133
133
|
virtualHost: true,
|
|
134
|
-
styleIsolation:
|
|
135
|
-
}
|
|
136
|
-
}
|
|
134
|
+
styleIsolation: "shared",
|
|
135
|
+
},
|
|
136
|
+
};
|
|
137
137
|
</script>
|
|
138
138
|
|
|
139
139
|
<script setup lang="ts">
|
|
@@ -197,7 +197,7 @@ const bemClass = computed(() => {
|
|
|
197
197
|
const loadingColor = computed(() => {
|
|
198
198
|
if (plain.value) {
|
|
199
199
|
// 如果有设置color值,则用color值,否则使用type主题颜色
|
|
200
|
-
return color.value ? color.value :
|
|
200
|
+
return color.value ? color.value : "";
|
|
201
201
|
}
|
|
202
202
|
if (type.value === "info") {
|
|
203
203
|
return "#c9c9c9";
|
|
@@ -207,10 +207,9 @@ const loadingColor = computed(() => {
|
|
|
207
207
|
|
|
208
208
|
const iconColorCom = computed((): string => {
|
|
209
209
|
// 如果是镂空状态,设置了color就用color值,否则使用主题颜色,
|
|
210
|
-
// u-icon的color能接受一个主题颜色的值
|
|
211
210
|
if (icon.value?.color) return icon.value?.color;
|
|
212
211
|
if (plain.value) {
|
|
213
|
-
return color.value ? color.value :
|
|
212
|
+
return color.value ? color.value : "";
|
|
214
213
|
} else {
|
|
215
214
|
return (type.value = "#ffffff");
|
|
216
215
|
}
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
@use "../../libs/css/mixin.scss" as *;
|
|
2
2
|
@use "../../theme.scss" as *;
|
|
3
3
|
|
|
4
|
+
uni-button {
|
|
5
|
+
margin: 0;
|
|
6
|
+
}
|
|
7
|
+
|
|
4
8
|
@include b(button){
|
|
5
9
|
height: 40px;
|
|
6
10
|
position: relative;
|
|
@@ -78,17 +82,6 @@
|
|
|
78
82
|
@include borderRadio(circle);
|
|
79
83
|
@include borderRadio(square);
|
|
80
84
|
|
|
81
|
-
&__icon {
|
|
82
|
-
min-width: 1em;
|
|
83
|
-
line-height: inherit !important;
|
|
84
|
-
vertical-align: top;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
//&--plain {
|
|
88
|
-
// //color: v-bind(textColor);
|
|
89
|
-
// color: $hy-primary;
|
|
90
|
-
// background-color: #fff;
|
|
91
|
-
//}
|
|
92
85
|
|
|
93
86
|
@include m(hairline) {
|
|
94
87
|
border-width: 0.5px;
|
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
@use "../../libs/css/mixin.scss" as *;
|
|
2
2
|
@use "../../theme.scss" as *;
|
|
3
3
|
|
|
4
|
-
@include b(theme) {
|
|
5
|
-
@include m(dark) {
|
|
6
|
-
background-color: $hy-dark-background;
|
|
7
|
-
color: $hy-dark-color;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
4
|
|
|
11
5
|
/* 主样式 */
|
|
12
6
|
@include b(calendar){
|
|
@@ -23,7 +17,6 @@
|
|
|
23
17
|
|
|
24
18
|
&__title {
|
|
25
19
|
font-size: 16px;
|
|
26
|
-
color: $hy-color-title;
|
|
27
20
|
text-align: center;
|
|
28
21
|
height: 42px;
|
|
29
22
|
line-height: 42px;
|
|
@@ -32,7 +25,7 @@
|
|
|
32
25
|
|
|
33
26
|
&__subtitle {
|
|
34
27
|
font-size: 14px;
|
|
35
|
-
color: $hy-color
|
|
28
|
+
color: $hy-text-color--2;
|
|
36
29
|
height: 40px;
|
|
37
30
|
text-align: center;
|
|
38
31
|
line-height: 40px;
|
|
@@ -45,7 +38,7 @@
|
|
|
45
38
|
|
|
46
39
|
&__weekday {
|
|
47
40
|
font-size: 13px;
|
|
48
|
-
color: $hy-
|
|
41
|
+
color: $hy-text-color--grey;
|
|
49
42
|
line-height: 30px;
|
|
50
43
|
flex: 1;
|
|
51
44
|
text-align: center;
|
|
@@ -61,7 +54,7 @@
|
|
|
61
54
|
font-size: 14px;
|
|
62
55
|
line-height: 42px;
|
|
63
56
|
height: 42px;
|
|
64
|
-
color: $hy-color
|
|
57
|
+
color: $hy-text-color--2;
|
|
65
58
|
text-align: center;
|
|
66
59
|
font-weight: bold;
|
|
67
60
|
}
|
|
@@ -88,7 +81,7 @@
|
|
|
88
81
|
|
|
89
82
|
&__text {
|
|
90
83
|
font-size: 155px;
|
|
91
|
-
color: $hy-
|
|
84
|
+
color: $hy-text-color--4;
|
|
92
85
|
}
|
|
93
86
|
}
|
|
94
87
|
|
|
@@ -107,6 +100,19 @@
|
|
|
107
100
|
align-items: center;
|
|
108
101
|
justify-content: center;
|
|
109
102
|
position: relative;
|
|
103
|
+
&--selected {
|
|
104
|
+
background-color: $hy-primary;
|
|
105
|
+
@include flex;
|
|
106
|
+
justify-content: center;
|
|
107
|
+
align-items: center;
|
|
108
|
+
flex: 1;
|
|
109
|
+
border-radius: 3px;
|
|
110
|
+
@include m(center) {
|
|
111
|
+
border-radius: 0;
|
|
112
|
+
//color: #000000;
|
|
113
|
+
background-color: $hy-primary-light;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
110
116
|
|
|
111
117
|
&__dot {
|
|
112
118
|
width: 7px;
|
|
@@ -119,12 +125,11 @@
|
|
|
119
125
|
}
|
|
120
126
|
|
|
121
127
|
&__buttom-info {
|
|
122
|
-
color: $hy-color
|
|
128
|
+
color: $hy-text-color--2;
|
|
123
129
|
text-align: center;
|
|
124
130
|
position: absolute;
|
|
125
131
|
bottom: 5px;
|
|
126
132
|
font-size: 10px;
|
|
127
|
-
text-align: center;
|
|
128
133
|
left: 0;
|
|
129
134
|
right: 0;
|
|
130
135
|
|
|
@@ -133,7 +138,7 @@
|
|
|
133
138
|
}
|
|
134
139
|
|
|
135
140
|
&--disabled {
|
|
136
|
-
color:
|
|
141
|
+
background-color: $hy-primary-disabled;
|
|
137
142
|
}
|
|
138
143
|
}
|
|
139
144
|
|
|
@@ -143,22 +148,14 @@
|
|
|
143
148
|
|
|
144
149
|
&--selected {
|
|
145
150
|
color: #ffffff;
|
|
151
|
+
background-color: $hy-primary;
|
|
146
152
|
}
|
|
147
153
|
|
|
148
154
|
&--disabled {
|
|
149
|
-
color: $hy-
|
|
155
|
+
color: $hy-text-color--disabled;
|
|
150
156
|
}
|
|
151
157
|
}
|
|
152
158
|
|
|
153
|
-
&--selected {
|
|
154
|
-
background-color: var(--hy-theme-dark, $hy-primary);
|
|
155
|
-
@include flex;
|
|
156
|
-
justify-content: center;
|
|
157
|
-
align-items: center;
|
|
158
|
-
flex: 1;
|
|
159
|
-
border-radius: 3px;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
159
|
&--range-selected {
|
|
163
160
|
opacity: 0.3;
|
|
164
161
|
border-radius: 0;
|
|
@@ -25,12 +25,9 @@
|
|
|
25
25
|
:key="index1"
|
|
26
26
|
:style="[dayStyle(index, index1, item1)]"
|
|
27
27
|
@tap="clickHandler(index, index1, item1)"
|
|
28
|
-
:class="[
|
|
29
|
-
item1.selected && 'hy-calendar-month__days__day__select--selected',
|
|
30
|
-
]"
|
|
31
28
|
>
|
|
32
29
|
<view
|
|
33
|
-
class="
|
|
30
|
+
:class="daySelectClass(index, index1, item1)"
|
|
34
31
|
:style="[daySelectStyle(index, index1, item1)]"
|
|
35
32
|
>
|
|
36
33
|
<text
|
|
@@ -67,7 +64,8 @@
|
|
|
67
64
|
|
|
68
65
|
<script>
|
|
69
66
|
import { addUnit, colorGradient, deepClone, getRect, sleep } from "../../utils";
|
|
70
|
-
import dayjs from "dayjs/esm
|
|
67
|
+
import dayjs from "dayjs/esm";
|
|
68
|
+
import { formatTime } from "../../utils";
|
|
71
69
|
export default {
|
|
72
70
|
name: "hy-calendar-month",
|
|
73
71
|
props: {
|
|
@@ -187,7 +185,7 @@ export default {
|
|
|
187
185
|
selectedChange() {
|
|
188
186
|
return [this.minDate, this.maxDate, this.defaultDate];
|
|
189
187
|
},
|
|
190
|
-
dayStyle(
|
|
188
|
+
dayStyle() {
|
|
191
189
|
return (index1, index2, item) => {
|
|
192
190
|
const style = {};
|
|
193
191
|
let week = item.week;
|
|
@@ -217,6 +215,29 @@ export default {
|
|
|
217
215
|
return style;
|
|
218
216
|
};
|
|
219
217
|
},
|
|
218
|
+
daySelectClass() {
|
|
219
|
+
return (index1, index2, item) => {
|
|
220
|
+
const date = dayjs(item.date).format("YYYY-MM-DD");
|
|
221
|
+
const len = this.selected.length - 1;
|
|
222
|
+
const classes = ["hy-calendar-month__days__day__select"];
|
|
223
|
+
// 判断选中的
|
|
224
|
+
if (this.selected.some((item) => this.dateSame(item, date))) {
|
|
225
|
+
classes.push("hy-calendar-month__days__day__select--selected");
|
|
226
|
+
if (this.selected.length >= 2) {
|
|
227
|
+
// 判断非两边选中内容
|
|
228
|
+
if (
|
|
229
|
+
!this.dateSame(date, this.selected[0]) &&
|
|
230
|
+
!this.dateSame(date, this.selected[len])
|
|
231
|
+
) {
|
|
232
|
+
classes.push(
|
|
233
|
+
"hy-calendar-month__days__day__select--selected--center",
|
|
234
|
+
);
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
return classes;
|
|
239
|
+
};
|
|
240
|
+
},
|
|
220
241
|
daySelectStyle() {
|
|
221
242
|
return (index1, index2, item) => {
|
|
222
243
|
let date = dayjs(item.date).format("YYYY-MM-DD"),
|
|
@@ -337,6 +358,7 @@ export default {
|
|
|
337
358
|
this.init();
|
|
338
359
|
},
|
|
339
360
|
methods: {
|
|
361
|
+
dayjs,
|
|
340
362
|
init() {
|
|
341
363
|
// 初始化默认选中
|
|
342
364
|
this.$emit("monthSelected", this.selected);
|
|
@@ -1,21 +1,12 @@
|
|
|
1
1
|
@use "../../libs/css/mixin.scss" as *;
|
|
2
2
|
@use "../../theme.scss" as *;
|
|
3
3
|
|
|
4
|
-
/* 暗色主题 */
|
|
5
|
-
@include b(theme){
|
|
6
|
-
@include m(dark) {
|
|
7
|
-
@include b(card) {
|
|
8
|
-
color: $hy-dark-color;
|
|
9
|
-
background-color: $hy-dark-background--container;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
4
|
|
|
14
5
|
@include b(card) {
|
|
15
6
|
position: relative;
|
|
16
7
|
overflow: hidden;
|
|
17
8
|
font-size: 28rpx;
|
|
18
|
-
background-color:
|
|
9
|
+
background-color: $hy-background--container;
|
|
19
10
|
box-sizing: border-box;
|
|
20
11
|
|
|
21
12
|
&-full {
|
|
@@ -50,7 +41,7 @@
|
|
|
50
41
|
}
|
|
51
42
|
|
|
52
43
|
&--right {
|
|
53
|
-
color: $hy-text-color
|
|
44
|
+
color: $hy-text-color--grey;
|
|
54
45
|
margin-left: 6rpx;
|
|
55
46
|
}
|
|
56
47
|
}
|
|
@@ -1,24 +1,7 @@
|
|
|
1
1
|
@use "../../libs/css/mixin.scss" as *;
|
|
2
2
|
@use "../../theme.scss" as *;
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
@include b(theme){
|
|
6
|
-
@include m(dark) {
|
|
7
|
-
@include b(cell) {
|
|
8
|
-
color: $hy-dark-color;
|
|
9
|
-
&__body--container {
|
|
10
|
-
background-color: $hy-dark-background--container;
|
|
11
|
-
&__right-icon {
|
|
12
|
-
:deep() {
|
|
13
|
-
@include b(icon) {
|
|
14
|
-
color: $hy-dark-icon;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
}
|
|
4
|
+
|
|
22
5
|
@include b(cell) {
|
|
23
6
|
flex: 1;
|
|
24
7
|
|
|
@@ -74,6 +57,7 @@
|
|
|
74
57
|
align-items: center;
|
|
75
58
|
justify-content: space-between;
|
|
76
59
|
flex: 1;
|
|
60
|
+
background-color: $hy-background--container;
|
|
77
61
|
|
|
78
62
|
/* 大 */
|
|
79
63
|
&__large {
|
|
@@ -98,7 +82,7 @@
|
|
|
98
82
|
|
|
99
83
|
/*点击状态*/
|
|
100
84
|
&__clickable {
|
|
101
|
-
background-color: $hy-
|
|
85
|
+
background-color: $hy-background--hover;
|
|
102
86
|
}
|
|
103
87
|
|
|
104
88
|
&__content {
|
|
@@ -119,7 +103,7 @@
|
|
|
119
103
|
/*sub值*/
|
|
120
104
|
&--sub {
|
|
121
105
|
margin-top: $hy-border-margin-padding-sm;
|
|
122
|
-
color: $hy-text-color
|
|
106
|
+
color: $hy-text-color--grey;
|
|
123
107
|
}
|
|
124
108
|
}
|
|
125
109
|
}
|
|
@@ -131,7 +115,7 @@
|
|
|
131
115
|
flex: 1;
|
|
132
116
|
&__value {
|
|
133
117
|
line-height: 24px;
|
|
134
|
-
color: $hy-text-color
|
|
118
|
+
color: $hy-text-color--grey;
|
|
135
119
|
margin-right: $hy-border-margin-padding-sm;
|
|
136
120
|
}
|
|
137
121
|
}
|
|
@@ -139,6 +123,9 @@
|
|
|
139
123
|
/*右边icon*/
|
|
140
124
|
&__right-icon {
|
|
141
125
|
transition: transform 0.3s;
|
|
126
|
+
:deep(.hy-icon) {
|
|
127
|
+
color: $hy-text-color--3;
|
|
128
|
+
}
|
|
142
129
|
|
|
143
130
|
&--up {
|
|
144
131
|
transform: rotate(-90deg);
|
|
@@ -156,7 +143,7 @@
|
|
|
156
143
|
}
|
|
157
144
|
|
|
158
145
|
@include m(disabled) {
|
|
159
|
-
color: $hy-text-color
|
|
146
|
+
color: $hy-text-color--disabled;
|
|
160
147
|
/* #ifndef APP-NVUE */
|
|
161
148
|
cursor: not-allowed;
|
|
162
149
|
/* #endif */
|
|
@@ -30,7 +30,11 @@
|
|
|
30
30
|
</slot>
|
|
31
31
|
</view>
|
|
32
32
|
<view
|
|
33
|
-
class="
|
|
33
|
+
:class="[
|
|
34
|
+
'hy-checkbox__label-wrap',
|
|
35
|
+
'cursor-pointer',
|
|
36
|
+
disabled && 'hy-checkbox__label-wrap--disabled',
|
|
37
|
+
]"
|
|
34
38
|
@tap.stop="labelClickHandler($event, item)"
|
|
35
39
|
>
|
|
36
40
|
<slot name="label" :record="item">
|
|
@@ -50,13 +54,13 @@
|
|
|
50
54
|
|
|
51
55
|
<script lang="ts">
|
|
52
56
|
export default {
|
|
53
|
-
name:
|
|
57
|
+
name: "hy-checkbox",
|
|
54
58
|
options: {
|
|
55
59
|
addGlobalClass: true,
|
|
56
60
|
virtualHost: true,
|
|
57
|
-
styleIsolation:
|
|
58
|
-
}
|
|
59
|
-
}
|
|
61
|
+
styleIsolation: "shared",
|
|
62
|
+
},
|
|
63
|
+
};
|
|
60
64
|
</script>
|
|
61
65
|
|
|
62
66
|
<script setup lang="ts">
|
|
@@ -219,7 +223,6 @@ const setRadioCheckedStatus = (temp: CheckboxColumnsVo) => {
|
|
|
219
223
|
return item;
|
|
220
224
|
});
|
|
221
225
|
emit("change", temp);
|
|
222
|
-
console.log(columns_1.value[0].checked, "前");
|
|
223
226
|
emit(
|
|
224
227
|
"update:modelValue",
|
|
225
228
|
columns_1.value.length === 1
|
|
@@ -1,15 +1,6 @@
|
|
|
1
1
|
@use "../../libs/css/mixin.scss" as *;
|
|
2
2
|
@use "../../theme.scss" as *;
|
|
3
3
|
|
|
4
|
-
/* 暗色主题 */
|
|
5
|
-
@include b(theme){
|
|
6
|
-
@include m(dark) {
|
|
7
|
-
@include b(checkbox) {
|
|
8
|
-
color: $hy-dark-color;
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
4
|
@include b(checkbox) {
|
|
14
5
|
&-group {
|
|
15
6
|
&--row {
|
|
@@ -65,28 +56,34 @@
|
|
|
65
56
|
|
|
66
57
|
/* #endif */
|
|
67
58
|
|
|
68
|
-
|
|
59
|
+
@include m(circle) {
|
|
69
60
|
border-radius: 50%;
|
|
70
61
|
}
|
|
71
62
|
|
|
72
|
-
|
|
63
|
+
@include m(square) {
|
|
73
64
|
border-radius: 3px;
|
|
74
65
|
}
|
|
75
66
|
|
|
76
|
-
|
|
67
|
+
@include m(checked) {
|
|
77
68
|
color: #FFFFFF;
|
|
78
69
|
background-color: $hy-primary;
|
|
79
70
|
border-color: $hy-primary;
|
|
80
71
|
}
|
|
81
72
|
|
|
82
|
-
|
|
83
|
-
background-color: $hy-
|
|
73
|
+
@include m(disabled) {
|
|
74
|
+
background-color: $hy-text-color--disabled;
|
|
75
|
+
:deep(.hy-icon) {
|
|
76
|
+
display: none;
|
|
77
|
+
}
|
|
84
78
|
}
|
|
85
79
|
|
|
86
|
-
|
|
80
|
+
@include m([disabled--checked]){
|
|
87
81
|
background-color: $hy-primary;
|
|
88
82
|
border-color: $hy-primary;
|
|
89
83
|
opacity: 0.5;
|
|
84
|
+
:deep(.hy-icon) {
|
|
85
|
+
display: block;
|
|
86
|
+
}
|
|
90
87
|
}
|
|
91
88
|
}
|
|
92
89
|
|
|
@@ -97,8 +94,8 @@
|
|
|
97
94
|
font-size: $hy-font-size-base;
|
|
98
95
|
margin-right: $hy-border-margin-padding-sm;
|
|
99
96
|
|
|
100
|
-
|
|
101
|
-
color: $hy-text-color
|
|
97
|
+
@include m(disabled) {
|
|
98
|
+
color: $hy-text-color--disabled;
|
|
102
99
|
}
|
|
103
100
|
}
|
|
104
101
|
}
|