@nutui/nutui 4.1.4 → 4.1.5-beta.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 +1 -1
- package/dist/nutui.es.js +1 -1
- package/dist/nutui.js +2100 -2067
- package/dist/nutui.umd.js +1 -1
- package/dist/packages/_es/ActionSheet.js +6 -5
- package/dist/packages/_es/Address.js +17 -17
- package/dist/packages/_es/AddressList.js +3 -3
- package/dist/packages/_es/Animate.js +2 -2
- package/dist/packages/_es/Audio.js +7 -7
- package/dist/packages/_es/Avatar.js +2 -2
- package/dist/packages/_es/AvatarGroup.js +3 -3
- package/dist/packages/_es/Badge.js +3 -3
- package/dist/packages/_es/Calendar.js +23 -18
- package/dist/packages/_es/CalendarItem.js +1 -1
- package/dist/packages/_es/Cascader.js +16 -16
- package/dist/packages/_es/Category.js +2 -2
- package/dist/packages/_es/CategoryPane.js +3 -3
- package/dist/packages/_es/Collapse.js +2 -2
- package/dist/packages/_es/CollapseItem.js +7 -7
- package/dist/packages/_es/Comment.js +3 -3
- package/dist/packages/_es/ConfigProvider.js +57 -66
- package/dist/packages/_es/Countdown.js +20 -6
- package/dist/packages/_es/Countup.js +11 -11
- package/dist/packages/_es/DatePicker.js +11 -11
- package/dist/packages/_es/Dialog.js +3 -3
- package/dist/packages/_es/Drag.js +1 -1
- package/dist/packages/_es/Ecard.js +3 -3
- package/dist/packages/_es/Elevator.js +8 -8
- package/dist/packages/_es/Ellipsis.js +2 -2
- package/dist/packages/_es/FormItem.js +0 -1
- package/dist/packages/_es/GridItem.js +1 -1
- package/dist/packages/_es/Image.js +2 -2
- package/dist/packages/_es/ImagePreview.js +18 -18
- package/dist/packages/_es/InfiniteLoading.js +5 -5
- package/dist/packages/_es/Input.js +5 -5
- package/dist/packages/_es/Invoice.js +11 -5
- package/dist/packages/_es/List.js +11 -11
- package/dist/packages/_es/Menu.js +4 -4
- package/dist/packages/_es/MenuItem.js +11 -12
- package/dist/packages/_es/Navbar.js +21 -7
- package/dist/packages/_es/Noticebar.js +20 -14
- package/dist/packages/_es/Notify.js +3 -3
- package/dist/packages/_es/NumberKeyboard.js +10 -5
- package/dist/packages/_es/Overlay.js +3 -3
- package/dist/packages/_es/Picker.js +3 -3
- package/dist/packages/_es/Popover.js +9 -9
- package/dist/packages/_es/Popup.js +1 -1
- package/dist/packages/_es/PullRefresh.js +1 -1
- package/dist/packages/_es/Range.js +5 -5
- package/dist/packages/_es/Row.js +0 -1
- package/dist/packages/_es/Searchbar.js +10 -10
- package/dist/packages/_es/ShortPassword.js +14 -9
- package/dist/packages/_es/SideNavbar.js +2 -3
- package/dist/packages/_es/SideNavbarItem.js +2 -2
- package/dist/packages/_es/Signature.js +2 -2
- package/dist/packages/_es/Sku.js +38 -37
- package/dist/packages/_es/Step.js +1 -1
- package/dist/packages/_es/Steps.js +2 -2
- package/dist/packages/_es/Sticky.js +2 -2
- package/dist/packages/_es/SubSideNavbar.js +2 -2
- package/dist/packages/_es/Swipe.js +2 -2
- package/dist/packages/_es/SwipeGroup.js +2 -2
- package/dist/packages/_es/Swiper.js +4 -4
- package/dist/packages/_es/Switch.js +2 -2
- package/dist/packages/_es/Tabbar.js +2 -2
- package/dist/packages/_es/Table.js +6 -6
- package/dist/packages/_es/Tabs.js +13 -13
- package/dist/packages/_es/Textarea.js +3 -3
- package/dist/packages/_es/TimeDetail.js +1 -1
- package/dist/packages/_es/TimeSelect.js +3 -3
- package/dist/packages/_es/Tour.js +7 -7
- package/dist/packages/_es/Uploader.js +11 -11
- package/dist/packages/_es/Video.js +11 -11
- package/dist/packages/_es/{index-7fe29a2f.js → index-3032df15.js} +8 -9
- package/dist/packages/_es/{index-66fff386.js → index-7fdbc8f1.js} +13 -10
- package/dist/packages/circleprogress/index.scss +3 -1
- package/dist/packages/popover/index.scss +3 -1
- package/dist/packages/video/index.scss +4 -1
- package/dist/smartips/web-types.json +2 -2
- package/dist/style.css +1 -1
- package/dist/styles/themes/default.scss +42 -42
- package/dist/styles/themes/jdb.scss +42 -42
- package/dist/styles/themes/jddkh.scss +42 -42
- package/dist/styles/themes/jdt.scss +42 -42
- package/dist/styles/variables-jdb.scss +7 -1
- package/dist/styles/variables-jddkh.scss +7 -1
- package/dist/types/__VUE/actionsheet/index.vue.d.ts +1 -1
- package/dist/types/__VUE/address/index.vue.d.ts +3 -3
- package/dist/types/__VUE/addresslist/components/GeneralShell.vue.d.ts +60 -0
- package/dist/types/__VUE/addresslist/components/ItemContents.vue.d.ts +23 -0
- package/dist/types/__VUE/addresslist/index.vue.d.ts +2 -2
- package/dist/types/__VUE/audio/index.vue.d.ts +3 -3
- package/dist/types/__VUE/calendar/index.vue.d.ts +9 -0
- package/dist/types/__VUE/cascader/cascader-item.vue.d.ts +77 -0
- package/dist/types/__VUE/collapseitem/index.vue.d.ts +3 -3
- package/dist/types/__VUE/comment/components/CmtBottom.vue.d.ts +42 -0
- package/dist/types/__VUE/comment/components/CmtHeader.vue.d.ts +36 -0
- package/dist/types/__VUE/comment/components/CmtImages.vue.d.ts +59 -0
- package/dist/types/__VUE/comment/index.vue.d.ts +4 -4
- package/dist/types/__VUE/configprovider/common.d.ts +19 -0
- package/dist/types/__VUE/countdown/index.vue.d.ts +7 -4
- package/dist/types/__VUE/countup/index.vue.d.ts +3 -3
- package/dist/types/__VUE/datepicker/index.vue.d.ts +3 -3
- package/dist/types/__VUE/elevator/index.vue.d.ts +3 -3
- package/dist/types/__VUE/empty/index.vue.d.ts +1 -1
- package/dist/types/__VUE/formitem/index.vue.d.ts +2 -4
- package/dist/types/__VUE/grid/index.vue.d.ts +1 -1
- package/dist/types/__VUE/imagepreview/imagePreviewItem.vue.d.ts +126 -0
- package/dist/types/__VUE/imagepreview/index.vue.d.ts +3 -3
- package/dist/types/__VUE/indicator/index.vue.d.ts +1 -0
- package/dist/types/__VUE/infiniteloading/index.vue.d.ts +3 -3
- package/dist/types/__VUE/input/index.vue.d.ts +3 -3
- package/dist/types/__VUE/inputnumber/index.vue.d.ts +1 -1
- package/dist/types/__VUE/invoice/index.vue.d.ts +3 -2
- package/dist/types/__VUE/list/index.vue.d.ts +4 -4
- package/dist/types/__VUE/navbar/index.vue.d.ts +9 -5
- package/dist/types/__VUE/noticebar/index.vue.d.ts +3 -3
- package/dist/types/__VUE/numberkeyboard/index.vue.d.ts +13 -4
- package/dist/types/__VUE/picker/Column.vue.d.ts +134 -0
- package/dist/types/__VUE/picker/common.d.ts +484 -4
- package/dist/types/__VUE/picker/index.vue.d.ts +125 -5
- package/dist/types/__VUE/popover/index.vue.d.ts +1 -1
- package/dist/types/__VUE/popup/index.vue.d.ts +4 -4
- package/dist/types/__VUE/range/index.vue.d.ts +8 -7
- package/dist/types/__VUE/rate/index.vue.d.ts +5 -5
- package/dist/types/__VUE/row/index.vue.d.ts +2 -2
- package/dist/types/__VUE/searchbar/index.vue.d.ts +7 -7
- package/dist/types/__VUE/shortpassword/index.vue.d.ts +9 -0
- package/dist/types/__VUE/sidenavbar/index.vue.d.ts +2 -2
- package/dist/types/__VUE/signature/index.vue.d.ts +1 -1
- package/dist/types/__VUE/sku/components/SkuHeader.vue.d.ts +17 -0
- package/dist/types/__VUE/sku/components/SkuOperate.vue.d.ts +60 -0
- package/dist/types/__VUE/sku/components/SkuSelect.vue.d.ts +25 -0
- package/dist/types/__VUE/sku/components/SkuStepper.vue.d.ts +56 -0
- package/dist/types/__VUE/sku/index.vue.d.ts +9 -9
- package/dist/types/__VUE/step/index.vue.d.ts +2 -2
- package/dist/types/__VUE/steps/index.vue.d.ts +2 -2
- package/dist/types/__VUE/subsidenavbar/index.vue.d.ts +2 -2
- package/dist/types/__VUE/swiper/index.vue.d.ts +2 -2
- package/dist/types/__VUE/tabbar/index.vue.d.ts +2 -2
- package/dist/types/__VUE/tabbaritem/index.vue.d.ts +3 -3
- package/dist/types/__VUE/table/common.d.ts +1 -1
- package/dist/types/__VUE/tabs/index.vue.d.ts +1 -1
- package/dist/types/__VUE/tag/index.vue.d.ts +3 -0
- package/dist/types/__VUE/textarea/index.vue.d.ts +1 -1
- package/dist/types/__VUE/toast/index.vue.d.ts +4 -4
- package/dist/types/__VUE/uploader/index.vue.d.ts +2 -2
- package/dist/types/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,75 +1,66 @@
|
|
|
1
1
|
import { c as createComponent } from "./component-0fbad28e.js";
|
|
2
|
-
import { h } from "vue";
|
|
2
|
+
import { computed, h } from "vue";
|
|
3
3
|
import "../locale/lang";
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
|
|
21
|
-
if (sColor && reg.test(sColor)) {
|
|
22
|
-
if (sColor.length === 4) {
|
|
23
|
-
var sColorNew = "#";
|
|
24
|
-
for (let i = 1; i < 4; i += 1) {
|
|
25
|
-
sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1));
|
|
26
|
-
}
|
|
27
|
-
sColor = sColorNew;
|
|
4
|
+
const component = (tag) => {
|
|
5
|
+
return {
|
|
6
|
+
props: {
|
|
7
|
+
theme: { type: String, default: "" },
|
|
8
|
+
themeVars: { type: Object, default: {} },
|
|
9
|
+
tag: { type: String, default: tag }
|
|
10
|
+
},
|
|
11
|
+
setup(props, { slots }) {
|
|
12
|
+
var _a;
|
|
13
|
+
const hexToRgb = (color) => {
|
|
14
|
+
const reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/;
|
|
15
|
+
if (!reg.test(color))
|
|
16
|
+
return "";
|
|
17
|
+
color = color.toLowerCase();
|
|
18
|
+
if (color.length === 4) {
|
|
19
|
+
color = "#" + color.slice(1).split("").map((char) => char + char).join("");
|
|
28
20
|
}
|
|
29
|
-
|
|
21
|
+
const colors = [];
|
|
30
22
|
for (let i = 1; i < 7; i += 2) {
|
|
31
|
-
|
|
23
|
+
colors.push(parseInt("0x" + color.slice(i, i + 2)));
|
|
32
24
|
}
|
|
33
|
-
return
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
primaryColor
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
primaryColor
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
});
|
|
57
|
-
return cssVars;
|
|
58
|
-
};
|
|
59
|
-
return () => {
|
|
60
|
-
var _a;
|
|
25
|
+
return colors.join(",");
|
|
26
|
+
};
|
|
27
|
+
const kebabCase = (str) => {
|
|
28
|
+
str = str.replace(str.charAt(0), str.charAt(0).toLocaleLowerCase());
|
|
29
|
+
return str.replace(/([a-z])([A-Z])/g, (_, p1, p2) => p1 + "-" + p2.toLowerCase());
|
|
30
|
+
};
|
|
31
|
+
const mapThemeVarsToCSSVars = (themeVars) => {
|
|
32
|
+
if (!themeVars)
|
|
33
|
+
return;
|
|
34
|
+
const cssVars = {};
|
|
35
|
+
const primaryColor = themeVars == null ? void 0 : themeVars.primaryColor;
|
|
36
|
+
if (primaryColor) {
|
|
37
|
+
const primaryColorRgb = hexToRgb(primaryColor);
|
|
38
|
+
cssVars["--nut-address-region-tab-line"] = `linear-gradient(90deg, ${primaryColor} 0%, rgba(${primaryColorRgb}, 0.15) 100%)`;
|
|
39
|
+
cssVars["--nut-tabs-horizontal-tab-line-color"] = `linear-gradient(90deg, ${primaryColor} 0%, rgba(${primaryColorRgb}, 0.15) 100%)`;
|
|
40
|
+
cssVars["--nut-tabs-vertical-tab-line-color"] = `linear-gradient(180deg, ${primaryColor} 0%, rgba(${primaryColorRgb}, 0.15) 100%)`;
|
|
41
|
+
}
|
|
42
|
+
Object.keys(themeVars).forEach((key) => {
|
|
43
|
+
cssVars[`--nut-${kebabCase(key)}`] = themeVars[key];
|
|
44
|
+
});
|
|
45
|
+
return cssVars;
|
|
46
|
+
};
|
|
47
|
+
const themeStyle = computed(() => mapThemeVarsToCSSVars(props.themeVars));
|
|
61
48
|
const defaultSlots = (_a = slots.default) == null ? void 0 : _a.call(slots);
|
|
62
|
-
return
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
}
|
|
49
|
+
return () => {
|
|
50
|
+
return h(
|
|
51
|
+
props.tag,
|
|
52
|
+
{
|
|
53
|
+
class: `nut-theme-${props.theme}`,
|
|
54
|
+
style: themeStyle.value
|
|
55
|
+
},
|
|
56
|
+
defaultSlots
|
|
57
|
+
);
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
};
|
|
62
|
+
const { create } = createComponent("config-provider");
|
|
63
|
+
const _sfc_main = create(component("div"));
|
|
73
64
|
export {
|
|
74
65
|
_sfc_main as default
|
|
75
66
|
};
|
|
@@ -76,7 +76,17 @@ const _sfc_main = create({
|
|
|
76
76
|
default: 0
|
|
77
77
|
}
|
|
78
78
|
},
|
|
79
|
-
emits: [
|
|
79
|
+
emits: [
|
|
80
|
+
"input",
|
|
81
|
+
"update:modelValue",
|
|
82
|
+
"end",
|
|
83
|
+
"restart",
|
|
84
|
+
"paused",
|
|
85
|
+
// will be deprecated
|
|
86
|
+
"onEnd",
|
|
87
|
+
"onRestart",
|
|
88
|
+
"onPaused"
|
|
89
|
+
],
|
|
80
90
|
setup(props, { emit, slots }) {
|
|
81
91
|
const state = reactive({
|
|
82
92
|
restTime: 0,
|
|
@@ -115,7 +125,8 @@ const _sfc_main = create({
|
|
|
115
125
|
if (!remainTime) {
|
|
116
126
|
state.counting = false;
|
|
117
127
|
pause();
|
|
118
|
-
emit("
|
|
128
|
+
emit("end");
|
|
129
|
+
emit("onEnd");
|
|
119
130
|
}
|
|
120
131
|
if (remainTime > 0) {
|
|
121
132
|
tick();
|
|
@@ -176,7 +187,7 @@ const _sfc_main = create({
|
|
|
176
187
|
} else if (format.includes("SS")) {
|
|
177
188
|
format = format.replace("SS", msC.slice(0, 2));
|
|
178
189
|
} else if (format.includes("S")) {
|
|
179
|
-
format = format.replace("
|
|
190
|
+
format = format.replace("S", msC.slice(0, 1));
|
|
180
191
|
}
|
|
181
192
|
}
|
|
182
193
|
return format;
|
|
@@ -186,13 +197,15 @@ const _sfc_main = create({
|
|
|
186
197
|
state.counting = true;
|
|
187
198
|
state.handleEndTime = Date.now() + Number(state.restTime);
|
|
188
199
|
tick();
|
|
189
|
-
emit("
|
|
200
|
+
emit("restart", state.restTime);
|
|
201
|
+
emit("onRestart", state.restTime);
|
|
190
202
|
}
|
|
191
203
|
};
|
|
192
204
|
const pause = () => {
|
|
193
205
|
cancelAnimationFrame(state.timer);
|
|
194
206
|
state.counting = false;
|
|
195
|
-
emit("
|
|
207
|
+
emit("paused", state.restTime);
|
|
208
|
+
emit("onPaused", state.restTime);
|
|
196
209
|
};
|
|
197
210
|
const reset = () => {
|
|
198
211
|
if (!props.autoStart) {
|
|
@@ -228,7 +241,8 @@ const _sfc_main = create({
|
|
|
228
241
|
state.handleEndTime = Date.now() + Number(state.restTime);
|
|
229
242
|
tick();
|
|
230
243
|
}
|
|
231
|
-
emit("
|
|
244
|
+
emit("restart", state.restTime);
|
|
245
|
+
emit("onRestart", state.restTime);
|
|
232
246
|
}
|
|
233
247
|
}
|
|
234
248
|
);
|
|
@@ -103,7 +103,7 @@ const _sfc_main = create({
|
|
|
103
103
|
}
|
|
104
104
|
},
|
|
105
105
|
components: {},
|
|
106
|
-
emits: ["click", "
|
|
106
|
+
emits: ["click", "scrollEnd"],
|
|
107
107
|
setup(props, { emit }) {
|
|
108
108
|
const runNumberImg = ref(null);
|
|
109
109
|
const numberItemRef = ref([]);
|
|
@@ -226,7 +226,7 @@ const _sfc_main = create({
|
|
|
226
226
|
if (Number(data.current) <= endNum || Number(data.current) <= speed) {
|
|
227
227
|
data.current = endNum.toFixed(toFixed);
|
|
228
228
|
clearInterval(countTimer);
|
|
229
|
-
emit("
|
|
229
|
+
emit("scrollEnd");
|
|
230
230
|
data.valFlag = false;
|
|
231
231
|
} else {
|
|
232
232
|
let num = parseFloat(String(data.current)) - parseFloat(String(speed));
|
|
@@ -236,7 +236,7 @@ const _sfc_main = create({
|
|
|
236
236
|
if (Number(data.current) >= endNum) {
|
|
237
237
|
data.current = endNum.toFixed(toFixed);
|
|
238
238
|
clearInterval(countTimer);
|
|
239
|
-
emit("
|
|
239
|
+
emit("scrollEnd");
|
|
240
240
|
data.valFlag = false;
|
|
241
241
|
} else {
|
|
242
242
|
let num = parseFloat(String(data.current)) + parseFloat(String(speed));
|
|
@@ -341,7 +341,7 @@ const _sfc_main = create({
|
|
|
341
341
|
data.totalCount = calculation(data.totalCount, m, "-");
|
|
342
342
|
if (data.totalCount <= 0) {
|
|
343
343
|
clearIntervalTime();
|
|
344
|
-
emit("
|
|
344
|
+
emit("scrollEnd");
|
|
345
345
|
data.valFlag = false;
|
|
346
346
|
}
|
|
347
347
|
}, props.during);
|
|
@@ -387,7 +387,7 @@ const _sfc_main = create({
|
|
|
387
387
|
const imgNumberScroll = () => {
|
|
388
388
|
nextTick(() => {
|
|
389
389
|
runNumberImg.value.addEventListener("webkitTransitionEnd", () => {
|
|
390
|
-
emit("
|
|
390
|
+
emit("scrollEnd");
|
|
391
391
|
data.valFlag = false;
|
|
392
392
|
});
|
|
393
393
|
});
|
|
@@ -452,10 +452,10 @@ const _sfc_main = create({
|
|
|
452
452
|
setTimeout(() => {
|
|
453
453
|
data.finshMachine = 0;
|
|
454
454
|
if (data.prizeLevelTrun < 0) {
|
|
455
|
-
emit("
|
|
455
|
+
emit("scrollEnd", false);
|
|
456
456
|
data.valFlag = false;
|
|
457
457
|
} else {
|
|
458
|
-
emit("
|
|
458
|
+
emit("scrollEnd", true);
|
|
459
459
|
data.valFlag = false;
|
|
460
460
|
}
|
|
461
461
|
}, 130);
|
|
@@ -493,8 +493,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
493
493
|
}, [
|
|
494
494
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.machineNum, (val, index2) => {
|
|
495
495
|
return openBlock(), createElementBlock("view", {
|
|
496
|
-
class: "nut-countup__machine-item",
|
|
497
496
|
key: "mImg" + index2,
|
|
497
|
+
class: "nut-countup__machine-item",
|
|
498
498
|
style: normalizeStyle({
|
|
499
499
|
width: _ctx.numWidth + "px",
|
|
500
500
|
height: _ctx.numHeight + "px",
|
|
@@ -511,8 +511,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
511
511
|
}, [
|
|
512
512
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.num_total_len, (val, index2) => {
|
|
513
513
|
return openBlock(), createElementBlock("view", {
|
|
514
|
-
class: "nut-countup__numberimg__item",
|
|
515
514
|
key: "cImg" + index2,
|
|
515
|
+
class: "nut-countup__numberimg__item",
|
|
516
516
|
style: normalizeStyle({
|
|
517
517
|
width: _ctx.numWidth + "px",
|
|
518
518
|
height: _ctx.numHeight + "px",
|
|
@@ -549,8 +549,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
549
549
|
return openBlock(), createElementBlock("view", {
|
|
550
550
|
ref_for: true,
|
|
551
551
|
ref: (el) => _ctx.setRef(el),
|
|
552
|
-
class: "nut-countup__number-item",
|
|
553
552
|
key: val,
|
|
553
|
+
class: "nut-countup__number-item",
|
|
554
554
|
style: normalizeStyle({
|
|
555
555
|
top: _ctx.topNumber(index2),
|
|
556
556
|
left: _ctx.numWidth * (index2 > _ctx.num_total_len - _ctx.pointNum - 1 ? index2 * 1.1 : index2) + "px"
|
|
@@ -559,8 +559,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
559
559
|
}, [
|
|
560
560
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.to0_10, (item, idx) => {
|
|
561
561
|
return openBlock(), createElementBlock("view", {
|
|
562
|
-
class: "nut-countup__number-item__span",
|
|
563
562
|
key: "dote" + idx,
|
|
563
|
+
class: "nut-countup__number-item__span",
|
|
564
564
|
style: normalizeStyle({
|
|
565
565
|
width: _ctx.numWidth + "px",
|
|
566
566
|
height: _ctx.numHeight + "px",
|
|
@@ -356,18 +356,18 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
356
356
|
return openBlock(), createBlock(_component_nut_picker, {
|
|
357
357
|
modelValue: _ctx.selectedValue,
|
|
358
358
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.selectedValue = $event),
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
onCancel: _ctx.closeHandler,
|
|
359
|
+
"ok-text": _ctx.okText,
|
|
360
|
+
"cancel-text": _ctx.cancelText,
|
|
362
361
|
columns: _ctx.columns,
|
|
363
|
-
onChange: _ctx.changeHandler,
|
|
364
362
|
title: _ctx.title,
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
363
|
+
"three-dimensional": _ctx.threeDimensional,
|
|
364
|
+
"swipe-duration": _ctx.swipeDuration,
|
|
365
|
+
"show-toolbar": _ctx.showToolbar,
|
|
366
|
+
"visible-option-num": _ctx.visibleOptionNum,
|
|
367
|
+
"option-height": _ctx.optionHeight,
|
|
368
|
+
onCancel: _ctx.closeHandler,
|
|
369
|
+
onChange: _ctx.changeHandler,
|
|
370
|
+
onConfirm: _ctx.confirm
|
|
371
371
|
}, {
|
|
372
372
|
top: withCtx(() => [
|
|
373
373
|
renderSlot(_ctx.$slots, "top")
|
|
@@ -376,7 +376,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
376
376
|
renderSlot(_ctx.$slots, "default")
|
|
377
377
|
]),
|
|
378
378
|
_: 3
|
|
379
|
-
}, 8, ["modelValue", "
|
|
379
|
+
}, 8, ["modelValue", "ok-text", "cancel-text", "columns", "title", "three-dimensional", "swipe-duration", "show-toolbar", "visible-option-num", "option-height", "onCancel", "onChange", "onConfirm"]);
|
|
380
380
|
}
|
|
381
381
|
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
382
382
|
export {
|
|
@@ -24,7 +24,7 @@ var __publicField = (obj, key, value) => {
|
|
|
24
24
|
import { ref, onMounted, watch, computed, resolveComponent, openBlock, createBlock, normalizeStyle, withCtx, createElementVNode, normalizeClass, createElementBlock, renderSlot, Fragment, createTextVNode, toDisplayString, createCommentVNode, resolveDynamicComponent, nextTick, h } from "vue";
|
|
25
25
|
import { c as createComponent } from "./component-0fbad28e.js";
|
|
26
26
|
import { f as funInterceptor } from "./Interceptor-c05a39f2.js";
|
|
27
|
-
import { P as Popup, p as popupProps } from "./index-
|
|
27
|
+
import { P as Popup, p as popupProps } from "./index-3032df15.js";
|
|
28
28
|
import Button from "./Button.js";
|
|
29
29
|
import { _ as _export_sfc } from "./_plugin-vue_export-helper-cc2b3d55.js";
|
|
30
30
|
import Overlay from "./Overlay.js";
|
|
@@ -178,9 +178,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
178
178
|
const _component_nut_button = resolveComponent("nut-button");
|
|
179
179
|
const _component_nut_popup = resolveComponent("nut-popup");
|
|
180
180
|
return openBlock(), createBlock(_component_nut_popup, {
|
|
181
|
-
teleport: _ctx.teleport,
|
|
182
181
|
visible: _ctx.showPopup,
|
|
183
182
|
"onUpdate:visible": _cache[0] || (_cache[0] = ($event) => _ctx.showPopup = $event),
|
|
183
|
+
teleport: _ctx.teleport,
|
|
184
184
|
"close-on-click-overlay": false,
|
|
185
185
|
"lock-scroll": _ctx.lockScroll,
|
|
186
186
|
"pop-class": _ctx.popClass,
|
|
@@ -244,7 +244,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
244
244
|
], 2)
|
|
245
245
|
]),
|
|
246
246
|
_: 3
|
|
247
|
-
}, 8, ["
|
|
247
|
+
}, 8, ["visible", "teleport", "lock-scroll", "pop-class", "overlay-class", "overlay-style", "style", "onClickOverlay", "onClickCloseIcon"]);
|
|
248
248
|
}
|
|
249
249
|
const Dialog = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
250
250
|
class DialogOptions {
|
|
@@ -186,8 +186,8 @@ const _sfc_main = create({
|
|
|
186
186
|
});
|
|
187
187
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
188
188
|
return openBlock(), createElementBlock("view", {
|
|
189
|
-
class: normalizeClass(_ctx.classes),
|
|
190
189
|
ref: "myDrag",
|
|
190
|
+
class: normalizeClass(_ctx.classes),
|
|
191
191
|
onTouchstart: _cache[0] || (_cache[0] = ($event) => _ctx.touchStart($event)),
|
|
192
192
|
onTouchmove: _cache[1] || (_cache[1] = ($event) => _ctx.touchMove($event)),
|
|
193
193
|
onTouchend: _cache[2] || (_cache[2] = ($event) => _ctx.touchEnd($event))
|
|
@@ -138,11 +138,11 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
138
138
|
createElementVNode("view", null, toDisplayString(_ctx.otherValueText || _ctx.translate("otherValueText")), 1),
|
|
139
139
|
createElementVNode("view", _hoisted_5, [
|
|
140
140
|
withDirectives(createElementVNode("input", {
|
|
141
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.inputValue = $event),
|
|
141
142
|
class: "nut-ecard__list__input--input",
|
|
142
143
|
type: "text",
|
|
143
|
-
|
|
144
|
-
onInput: _cache[1] || (_cache[1] = (...args) => _ctx.change && _ctx.change(...args))
|
|
145
|
-
placeholder: _ctx.placeholder || _ctx.translate("placeholder")
|
|
144
|
+
placeholder: _ctx.placeholder || _ctx.translate("placeholder"),
|
|
145
|
+
onInput: _cache[1] || (_cache[1] = (...args) => _ctx.change && _ctx.change(...args))
|
|
146
146
|
}, null, 40, _hoisted_6), [
|
|
147
147
|
[vModelText, _ctx.inputValue]
|
|
148
148
|
]),
|
|
@@ -52,7 +52,7 @@ const _sfc_main = create({
|
|
|
52
52
|
default: 35
|
|
53
53
|
}
|
|
54
54
|
},
|
|
55
|
-
emits: ["
|
|
55
|
+
emits: ["clickItem", "clickIndex", "change"],
|
|
56
56
|
setup(props, context) {
|
|
57
57
|
const listview = ref(null);
|
|
58
58
|
const state = reactive({
|
|
@@ -137,12 +137,12 @@ const _sfc_main = create({
|
|
|
137
137
|
state.scrollStart = false;
|
|
138
138
|
};
|
|
139
139
|
const handleClickItem = (key, item) => {
|
|
140
|
-
context.emit("
|
|
140
|
+
context.emit("clickItem", key, item);
|
|
141
141
|
state.currentData = item;
|
|
142
142
|
state.currentKey = key;
|
|
143
143
|
};
|
|
144
144
|
const handleClickIndex = (key) => {
|
|
145
|
-
context.emit("
|
|
145
|
+
context.emit("clickIndex", key);
|
|
146
146
|
};
|
|
147
147
|
const listViewScroll = (e) => {
|
|
148
148
|
let target = e.target;
|
|
@@ -219,24 +219,24 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
219
219
|
class: normalizeClass(_ctx.classes)
|
|
220
220
|
}, [
|
|
221
221
|
createElementVNode("view", {
|
|
222
|
-
class: "nut-elevator__list",
|
|
223
222
|
ref: "listview",
|
|
223
|
+
class: "nut-elevator__list",
|
|
224
224
|
style: normalizeStyle({ height: isNaN(+_ctx.height) ? _ctx.height : `${_ctx.height}px` })
|
|
225
225
|
}, [
|
|
226
226
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.indexList, (item) => {
|
|
227
227
|
return openBlock(), createElementBlock("view", {
|
|
228
|
-
class: "nut-elevator__list__item",
|
|
229
228
|
key: item[_ctx.acceptKey],
|
|
230
229
|
ref_for: true,
|
|
231
|
-
ref: _ctx.setListGroup
|
|
230
|
+
ref: _ctx.setListGroup,
|
|
231
|
+
class: "nut-elevator__list__item"
|
|
232
232
|
}, [
|
|
233
233
|
createElementVNode("view", _hoisted_1, toDisplayString(item[_ctx.acceptKey]), 1),
|
|
234
234
|
(openBlock(true), createElementBlock(Fragment, null, renderList(item.list, (subitem) => {
|
|
235
235
|
return openBlock(), createElementBlock("view", {
|
|
236
|
+
key: subitem["id"],
|
|
236
237
|
class: normalizeClass(["nut-elevator__list__item__name", {
|
|
237
238
|
"nut-elevator__list__item__name--highcolor": _ctx.currentData.id === subitem.id && _ctx.currentKey === item[_ctx.acceptKey]
|
|
238
239
|
}]),
|
|
239
|
-
key: subitem["id"],
|
|
240
240
|
onClick: ($event) => _ctx.handleClickItem(item[_ctx.acceptKey], subitem)
|
|
241
241
|
}, [
|
|
242
242
|
!_ctx.$slots.default ? (openBlock(), createElementBlock("span", {
|
|
@@ -275,9 +275,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
275
275
|
createElementVNode("view", _hoisted_5, [
|
|
276
276
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.indexList, (item, index) => {
|
|
277
277
|
return openBlock(), createElementBlock("view", {
|
|
278
|
+
key: item[_ctx.acceptKey],
|
|
278
279
|
class: normalizeClass(["nut-elevator__bars__inner__item", { active: item[_ctx.acceptKey] === _ctx.indexList[_ctx.currentIndex][_ctx.acceptKey] }]),
|
|
279
280
|
"data-index": index,
|
|
280
|
-
key: item[_ctx.acceptKey],
|
|
281
281
|
onClick: ($event) => _ctx.handleClickIndex(item[_ctx.acceptKey])
|
|
282
282
|
}, toDisplayString(item[_ctx.acceptKey]), 11, _hoisted_6);
|
|
283
283
|
}), 128))
|
|
@@ -201,9 +201,9 @@ const _hoisted_2 = { key: 1 };
|
|
|
201
201
|
const _hoisted_3 = { key: 2 };
|
|
202
202
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
203
203
|
return openBlock(), createElementBlock("view", {
|
|
204
|
+
ref: "root",
|
|
204
205
|
class: normalizeClass(_ctx.classes),
|
|
205
|
-
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
|
|
206
|
-
ref: "root"
|
|
206
|
+
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
|
|
207
207
|
}, [
|
|
208
208
|
!_ctx.exceeded ? (openBlock(), createElementBlock("view", _hoisted_1, toDisplayString(_ctx.content), 1)) : createCommentVNode("", true),
|
|
209
209
|
_ctx.exceeded && !_ctx.expanded ? (openBlock(), createElementBlock("view", _hoisted_2, [
|
|
@@ -63,7 +63,7 @@ const _sfc_main = create({
|
|
|
63
63
|
style.paddingTop = `${100 / +parent.columnNum}%`;
|
|
64
64
|
} else if (parent.gutter) {
|
|
65
65
|
style.paddingRight = pxCheck(parent.gutter);
|
|
66
|
-
if (index2.value >= parent.columnNum) {
|
|
66
|
+
if (index2.value >= +parent.columnNum) {
|
|
67
67
|
style.marginTop = pxCheck(parent.gutter);
|
|
68
68
|
}
|
|
69
69
|
}
|
|
@@ -172,9 +172,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
172
172
|
src: _ctx.lazyLoad ? _ctx.show ? _ctx.src : void 0 : _ctx.src,
|
|
173
173
|
"date-src": _ctx.lazyLoad ? _ctx.show ? void 0 : _ctx.src : void 0,
|
|
174
174
|
alt: _ctx.alt,
|
|
175
|
+
style: normalizeStyle(_ctx.styles),
|
|
175
176
|
onLoad: _cache[0] || (_cache[0] = (...args) => _ctx.load && _ctx.load(...args)),
|
|
176
|
-
onError: _cache[1] || (_cache[1] = (...args) => _ctx.error && _ctx.error(...args))
|
|
177
|
-
style: normalizeStyle(_ctx.styles)
|
|
177
|
+
onError: _cache[1] || (_cache[1] = (...args) => _ctx.error && _ctx.error(...args))
|
|
178
178
|
}, null, 44, _hoisted_1),
|
|
179
179
|
_ctx.loading ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
180
180
|
!_ctx.slotLoding ? (openBlock(), createBlock(_component_Image, {
|
|
@@ -30,7 +30,7 @@ import Video from "./Video.js";
|
|
|
30
30
|
import SwiperItem from "./SwiperItem.js";
|
|
31
31
|
import { _ as _export_sfc } from "./_plugin-vue_export-helper-cc2b3d55.js";
|
|
32
32
|
import { CircleClose } from "@nutui/icons-vue";
|
|
33
|
-
import { P as Popup } from "./index-
|
|
33
|
+
import { P as Popup } from "./index-3032df15.js";
|
|
34
34
|
import Swiper from "./Swiper.js";
|
|
35
35
|
import { f as funInterceptor } from "./Interceptor-c05a39f2.js";
|
|
36
36
|
import "../locale/lang";
|
|
@@ -405,8 +405,8 @@ const _sfc_main = create({
|
|
|
405
405
|
}
|
|
406
406
|
});
|
|
407
407
|
const _hoisted_1 = {
|
|
408
|
-
|
|
409
|
-
|
|
408
|
+
ref: "swipeRef",
|
|
409
|
+
class: "nut-image-preview"
|
|
410
410
|
};
|
|
411
411
|
const _hoisted_2 = {
|
|
412
412
|
key: 0,
|
|
@@ -418,13 +418,13 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
418
418
|
const _component_CircleClose = resolveComponent("CircleClose");
|
|
419
419
|
const _component_nut_popup = resolveComponent("nut-popup");
|
|
420
420
|
return openBlock(), createBlock(_component_nut_popup, {
|
|
421
|
-
"pop-class": "nut-image-preview-custom-pop",
|
|
422
421
|
visible: _ctx.showPop,
|
|
423
422
|
"onUpdate:visible": _cache[1] || (_cache[1] = ($event) => _ctx.showPop = $event),
|
|
424
|
-
|
|
423
|
+
"pop-class": "nut-image-preview-custom-pop",
|
|
424
|
+
"teleport-disable": _ctx.teleportDisable,
|
|
425
425
|
teleport: _ctx.teleport,
|
|
426
|
-
|
|
427
|
-
|
|
426
|
+
"lock-scroll": "",
|
|
427
|
+
onClosed: _ctx.onClose
|
|
428
428
|
}, {
|
|
429
429
|
default: withCtx(() => [
|
|
430
430
|
createElementVNode("view", _hoisted_1, [
|
|
@@ -433,12 +433,12 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
433
433
|
"auto-play": _ctx.autoplay,
|
|
434
434
|
class: "nut-image-preview-swiper",
|
|
435
435
|
loop: _ctx.isLoop,
|
|
436
|
-
"is-
|
|
436
|
+
"is-prevent-default": false,
|
|
437
437
|
direction: "horizontal",
|
|
438
|
-
onChange: _ctx.setActive,
|
|
439
438
|
"init-page": _ctx.initNo,
|
|
440
439
|
"pagination-visible": _ctx.paginationVisible,
|
|
441
|
-
"pagination-color": _ctx.paginationColor
|
|
440
|
+
"pagination-color": _ctx.paginationColor,
|
|
441
|
+
onChange: _ctx.setActive
|
|
442
442
|
}, {
|
|
443
443
|
default: withCtx(() => [
|
|
444
444
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.mergeImages, (item, index) => {
|
|
@@ -446,19 +446,19 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
446
446
|
key: index,
|
|
447
447
|
video: index < _ctx.videos.length ? item : {},
|
|
448
448
|
image: index >= _ctx.videos.length ? item : {},
|
|
449
|
-
|
|
450
|
-
|
|
449
|
+
"root-height": _ctx.rootHeight,
|
|
450
|
+
"root-width": _ctx.rootWidth,
|
|
451
451
|
show: _ctx.showPop,
|
|
452
452
|
"init-no": _ctx.active + 1,
|
|
453
|
-
onClose: _ctx.onClose,
|
|
454
453
|
"content-close": _ctx.contentClose,
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
454
|
+
"max-zoom": _ctx.maxZoom,
|
|
455
|
+
"min-zoom": _ctx.minZoom,
|
|
456
|
+
onClose: _ctx.onClose
|
|
457
|
+
}, null, 8, ["video", "image", "root-height", "root-width", "show", "init-no", "content-close", "max-zoom", "min-zoom", "onClose"]);
|
|
458
458
|
}), 128))
|
|
459
459
|
]),
|
|
460
460
|
_: 1
|
|
461
|
-
}, 8, ["auto-play", "loop", "
|
|
461
|
+
}, 8, ["auto-play", "loop", "init-page", "pagination-visible", "pagination-color", "onChange"])) : createCommentVNode("", true)
|
|
462
462
|
], 512),
|
|
463
463
|
_ctx.showIndex ? (openBlock(), createElementBlock("view", _hoisted_2, toDisplayString(_ctx.active + 1) + " / " + toDisplayString(_ctx.mergeImages.length), 1)) : createCommentVNode("", true),
|
|
464
464
|
_ctx.closeable ? (openBlock(), createElementBlock("view", {
|
|
@@ -472,7 +472,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
472
472
|
], 2)) : createCommentVNode("", true)
|
|
473
473
|
]),
|
|
474
474
|
_: 3
|
|
475
|
-
}, 8, ["visible", "
|
|
475
|
+
}, 8, ["visible", "teleport-disable", "teleport", "onClosed"]);
|
|
476
476
|
}
|
|
477
477
|
const ImagePreview = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
478
478
|
class ImagePreviewOptions {
|
|
@@ -52,7 +52,7 @@ const _sfc_main = create({
|
|
|
52
52
|
default: false
|
|
53
53
|
}
|
|
54
54
|
},
|
|
55
|
-
emits: ["
|
|
55
|
+
emits: ["scrollChange", "loadMore", "update:modelValue"],
|
|
56
56
|
components: {
|
|
57
57
|
Loading
|
|
58
58
|
},
|
|
@@ -96,7 +96,7 @@ const _sfc_main = create({
|
|
|
96
96
|
direction = "down";
|
|
97
97
|
}
|
|
98
98
|
state.beforeScrollTop = resScrollTop;
|
|
99
|
-
emit("
|
|
99
|
+
emit("scrollChange", resScrollTop);
|
|
100
100
|
return offsetDistance <= props.threshold && direction == "down";
|
|
101
101
|
};
|
|
102
102
|
const handleScroll = () => {
|
|
@@ -106,7 +106,7 @@ const _sfc_main = create({
|
|
|
106
106
|
} else {
|
|
107
107
|
state.isInfiniting = true;
|
|
108
108
|
emit("update:modelValue", true);
|
|
109
|
-
nextTick(() => emit("
|
|
109
|
+
nextTick(() => emit("loadMore"));
|
|
110
110
|
}
|
|
111
111
|
});
|
|
112
112
|
};
|
|
@@ -161,8 +161,8 @@ const _hoisted_5 = { class: "nut-infinite__bottom-tips" };
|
|
|
161
161
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
162
162
|
const _component_Loading = resolveComponent("Loading");
|
|
163
163
|
return openBlock(), createElementBlock("view", {
|
|
164
|
-
|
|
165
|
-
|
|
164
|
+
ref: "scroller",
|
|
165
|
+
class: normalizeClass(_ctx.classes)
|
|
166
166
|
}, [
|
|
167
167
|
createElementVNode("view", _hoisted_1, [
|
|
168
168
|
renderSlot(_ctx.$slots, "default")
|