@nutui/nutui 3.1.16 → 3.1.18-beta.0
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/CHANGELOG.md +37 -0
- package/README.md +1 -1
- package/dist/nutui.d.ts +3 -1
- package/dist/nutui.es.js +1860 -773
- package/dist/nutui.umd.js +1871 -778
- package/dist/packages/_es/ActionSheet.js +8 -3
- package/dist/packages/_es/Address.js +60 -7
- package/dist/packages/_es/Audio.js +289 -0
- package/dist/packages/_es/Avatar.js +1 -1
- package/dist/packages/_es/BackTop.js +3 -3
- package/dist/packages/_es/Badge.js +1 -1
- package/dist/packages/_es/Barrage.js +1 -1
- package/dist/packages/_es/Button.js +13 -4
- package/dist/packages/_es/Calendar.js +428 -209
- package/dist/packages/_es/Card.js +1 -2
- package/dist/packages/_es/Cascader.js +2 -2
- package/dist/packages/_es/Cell.js +2 -2
- package/dist/packages/_es/CellGroup.js +1 -1
- package/dist/packages/_es/Checkbox.js +2 -2
- package/dist/packages/_es/CheckboxGroup.js +2 -2
- package/dist/packages/_es/CircleProgress.js +1 -1
- package/dist/packages/_es/Col.js +1 -1
- package/dist/packages/_es/Collapse.js +1 -1
- package/dist/packages/_es/CollapseItem.js +4 -2
- package/dist/packages/_es/CountDown.js +1 -1
- package/dist/packages/_es/CountUp.js +1 -1
- package/dist/packages/_es/DatePicker.js +1 -2
- package/dist/packages/_es/Dialog.js +1 -1
- package/dist/packages/_es/Divider.js +1 -1
- package/dist/packages/_es/Drag.js +1 -1
- package/dist/packages/_es/Elevator.js +10 -5
- package/dist/packages/_es/Empty.js +1 -1
- package/dist/packages/_es/FixedNav.js +1 -1
- package/dist/packages/_es/Form.js +1 -1
- package/dist/packages/_es/FormItem.js +1 -1
- package/dist/packages/_es/Grid.js +1 -1
- package/dist/packages/_es/GridItem.js +2 -2
- package/dist/packages/_es/Icon.js +1 -1
- package/dist/packages/_es/ImagePreview.js +8 -5
- package/dist/packages/_es/Indicator.js +1 -1
- package/dist/packages/_es/InfiniteLoading.js +1 -1
- package/dist/packages/_es/Input.js +7 -2
- package/dist/packages/_es/InputNumber.js +1 -1
- package/dist/packages/_es/Layout.js +1 -1
- package/dist/packages/_es/Menu.js +1 -1
- package/dist/packages/_es/MenuItem.js +1 -1
- package/dist/packages/_es/Navbar.js +18 -59
- package/dist/packages/_es/NoticeBar.js +38 -23
- package/dist/packages/_es/Notify.js +2 -2
- package/dist/packages/_es/NumberKeyboard.js +1 -2
- package/dist/packages/_es/OverLay.js +1 -1
- package/dist/packages/_es/Pagination.js +1 -1
- package/dist/packages/_es/Picker.js +2 -1
- package/dist/packages/_es/Popover.js +4 -1
- package/dist/packages/_es/Popup.js +1 -1
- package/dist/packages/_es/Price.js +1 -1
- package/dist/packages/_es/Progress.js +24 -11
- package/dist/packages/_es/Radio.js +2 -2
- package/dist/packages/_es/RadioGroup.js +1 -1
- package/dist/packages/_es/Range.js +2 -2
- package/dist/packages/_es/Rate.js +1 -1
- package/dist/packages/_es/Row.js +1 -1
- package/dist/packages/_es/SearchBar.js +1 -1
- package/dist/packages/_es/ShortPassword.js +12 -4
- package/dist/packages/_es/SideNavBar.js +1 -1
- package/dist/packages/_es/SideNavBarItem.js +1 -1
- package/dist/packages/_es/Signature.js +1 -1
- package/dist/packages/_es/Skeleton.js +8 -6
- package/dist/packages/_es/Sku.js +1 -1
- package/dist/packages/_es/Step.js +1 -1
- package/dist/packages/_es/Steps.js +1 -1
- package/dist/packages/_es/Sticky.js +143 -0
- package/dist/packages/_es/SubSideNavBar.js +1 -1
- package/dist/packages/_es/Swipe.js +2 -2
- package/dist/packages/_es/Swiper.js +2 -2
- package/dist/packages/_es/SwiperItem.js +3 -8
- package/dist/packages/_es/Switch.js +2 -2
- package/dist/packages/_es/TabPane.js +1 -1
- package/dist/packages/_es/Tabbar.js +1 -1
- package/dist/packages/_es/TabbarItem.js +7 -3
- package/dist/packages/_es/Table.js +2 -2
- package/dist/packages/_es/Tabs.js +1 -1
- package/dist/packages/_es/Tag.js +1 -1
- package/dist/packages/_es/TextArea.js +1 -1
- package/dist/packages/_es/TimeDetail.js +1 -1
- package/dist/packages/_es/TimePannel.js +1 -1
- package/dist/packages/_es/TimeSelect.js +7 -2
- package/dist/packages/_es/Toast.js +15 -8
- package/dist/packages/_es/Uploader.js +1 -1
- package/dist/packages/_es/Video.js +1 -55
- package/dist/packages/_es/common.js +1 -1
- package/dist/packages/_es/component.js +1 -1
- package/dist/packages/_es/index.js +5 -7
- package/dist/packages/_es/index2.js +7 -58
- package/dist/packages/_es/index3.js +1 -1
- package/dist/packages/_es/index4.js +64 -0
- package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
- package/dist/packages/_es/pxCheck.js +1 -1
- package/dist/packages/_es/raf.js +1 -1
- package/dist/packages/_es/util.js +1 -1
- package/dist/packages/actionsheet/index.scss +7 -6
- package/dist/packages/address/index.scss +8 -0
- package/dist/packages/audio/index.scss +66 -0
- package/dist/packages/audiooperate/index.scss +13 -0
- package/dist/packages/button/index.scss +5 -5
- package/dist/packages/calendar/index.scss +47 -41
- package/dist/packages/calendaritem/index.scss +57 -42
- package/dist/packages/cell/index.scss +3 -3
- package/dist/packages/cellgroup/index.scss +1 -1
- package/dist/packages/elevator/index.scss +3 -0
- package/dist/packages/infiniteloading/index.scss +1 -1
- package/dist/packages/input/index.scss +4 -2
- package/dist/packages/navbar/index.scss +2 -0
- package/dist/packages/noticebar/index.scss +11 -5
- package/dist/packages/notify/index.scss +1 -0
- package/dist/packages/progress/index.scss +21 -17
- package/dist/packages/range/index.scss +8 -8
- package/dist/packages/row/index.scss +3 -0
- package/dist/packages/sticky/index.scss +5 -0
- package/dist/packages/swiper/index.scss +4 -4
- package/dist/packages/switch/index.scss +8 -8
- package/dist/packages/tabbar/index.scss +7 -4
- package/dist/packages/tabbaritem/index.scss +4 -3
- package/dist/packages/tabs/index.scss +1 -0
- package/dist/packages/toast/index.scss +8 -7
- package/dist/style.css +1 -1
- package/dist/styles/font/config.json +6 -1
- package/dist/styles/font/demo_index.html +118 -3
- package/dist/styles/font/iconfont.css +23 -3
- package/dist/styles/font/iconfont.js +25 -24
- package/dist/styles/font/iconfont.json +35 -0
- package/dist/styles/font/iconfont.ttf +0 -0
- package/dist/styles/font/iconfont.woff +0 -0
- package/dist/styles/font/iconfont.woff2 +0 -0
- package/dist/styles/themes/default.scss +46 -43
- package/dist/styles/variables.scss +123 -42
- package/package.json +12 -13
package/dist/nutui.umd.js
CHANGED
|
@@ -35,13 +35,13 @@ var __publicField = (obj, key, value) => {
|
|
|
35
35
|
return value;
|
|
36
36
|
};
|
|
37
37
|
/*!
|
|
38
|
-
* @nutui/nutui v3.1.
|
|
38
|
+
* @nutui/nutui v3.1.18-beta.0 Tue Mar 08 2022 10:41:28 GMT+0800 (中国标准时间)
|
|
39
39
|
* (c) 2021 @jdf2e.
|
|
40
40
|
* Released under the MIT License.
|
|
41
41
|
*/
|
|
42
42
|
(function(global, factory) {
|
|
43
|
-
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("vue")
|
|
44
|
-
})(this, function(exports2, vue
|
|
43
|
+
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("vue")) : typeof define === "function" && define.amd ? define(["exports", "vue"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.nutui = {}, global.Vue));
|
|
44
|
+
})(this, function(exports2, vue) {
|
|
45
45
|
"use strict";
|
|
46
46
|
function createComponent(name) {
|
|
47
47
|
const componentName2 = "nut-" + name;
|
|
@@ -69,8 +69,8 @@ var __publicField = (obj, key, value) => {
|
|
|
69
69
|
}
|
|
70
70
|
return target;
|
|
71
71
|
};
|
|
72
|
-
const { componentName: componentName$
|
|
73
|
-
const _sfc_main$
|
|
72
|
+
const { componentName: componentName$18, create: create$1t } = createComponent("avatar");
|
|
73
|
+
const _sfc_main$1t = create$1t({
|
|
74
74
|
props: {
|
|
75
75
|
size: {
|
|
76
76
|
type: String,
|
|
@@ -94,7 +94,7 @@ var __publicField = (obj, key, value) => {
|
|
|
94
94
|
const { size, shape, bgColor, icon } = vue.toRefs(props);
|
|
95
95
|
const sizeValue = ["large", "normal", "small"];
|
|
96
96
|
const classes = vue.computed(() => {
|
|
97
|
-
const prefixCls = componentName$
|
|
97
|
+
const prefixCls = componentName$18;
|
|
98
98
|
return {
|
|
99
99
|
[prefixCls]: true,
|
|
100
100
|
["avatar-" + size.value]: true,
|
|
@@ -126,11 +126,11 @@ var __publicField = (obj, key, value) => {
|
|
|
126
126
|
};
|
|
127
127
|
}
|
|
128
128
|
});
|
|
129
|
-
const _hoisted_1
|
|
129
|
+
const _hoisted_1$12 = {
|
|
130
130
|
key: 0,
|
|
131
131
|
class: "text"
|
|
132
132
|
};
|
|
133
|
-
function _sfc_render$
|
|
133
|
+
function _sfc_render$1k(_ctx, _cache, $props, $setup, $data, $options) {
|
|
134
134
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
135
135
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
136
136
|
style: vue.normalizeStyle(_ctx.styles),
|
|
@@ -141,17 +141,17 @@ var __publicField = (obj, key, value) => {
|
|
|
141
141
|
class: "icon",
|
|
142
142
|
name: _ctx.iconStyles
|
|
143
143
|
}, null, 8, ["name"]),
|
|
144
|
-
_ctx.isShowText ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1
|
|
144
|
+
_ctx.isShowText ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$12, [
|
|
145
145
|
vue.renderSlot(_ctx.$slots, "default")
|
|
146
146
|
])) : vue.createCommentVNode("", true)
|
|
147
147
|
], 6);
|
|
148
148
|
}
|
|
149
|
-
var Avatar = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
149
|
+
var Avatar = /* @__PURE__ */ _export_sfc(_sfc_main$1t, [["render", _sfc_render$1k]]);
|
|
150
150
|
const pxCheck = (value) => {
|
|
151
151
|
return isNaN(Number(value)) ? String(value) : `${value}px`;
|
|
152
152
|
};
|
|
153
|
-
const { componentName: componentName$
|
|
154
|
-
const _sfc_main$
|
|
153
|
+
const { componentName: componentName$17, create: create$1s } = createComponent("icon");
|
|
154
|
+
const _sfc_main$1s = create$1s({
|
|
155
155
|
props: {
|
|
156
156
|
name: { type: String, default: "" },
|
|
157
157
|
size: { type: [String, Number], default: "" },
|
|
@@ -172,7 +172,7 @@ var __publicField = (obj, key, value) => {
|
|
|
172
172
|
var _a;
|
|
173
173
|
const _isImage = isImage();
|
|
174
174
|
return vue.h(_isImage ? "img" : props.tag, {
|
|
175
|
-
class: _isImage ? `${componentName$
|
|
175
|
+
class: _isImage ? `${componentName$17}__img` : `${props.fontClassName} ${componentName$17} ${props.classPrefix}-${props.name}`,
|
|
176
176
|
style: {
|
|
177
177
|
color: props.color,
|
|
178
178
|
fontSize: pxCheck(props.size),
|
|
@@ -185,10 +185,10 @@ var __publicField = (obj, key, value) => {
|
|
|
185
185
|
};
|
|
186
186
|
}
|
|
187
187
|
});
|
|
188
|
-
const { componentName: componentName$
|
|
189
|
-
const _sfc_main$
|
|
188
|
+
const { componentName: componentName$16, create: create$1r } = createComponent("button");
|
|
189
|
+
const _sfc_main$1r = create$1r({
|
|
190
190
|
components: {
|
|
191
|
-
[_sfc_main$
|
|
191
|
+
[_sfc_main$1s.name]: _sfc_main$1s
|
|
192
192
|
},
|
|
193
193
|
props: {
|
|
194
194
|
color: String,
|
|
@@ -223,6 +223,14 @@ var __publicField = (obj, key, value) => {
|
|
|
223
223
|
icon: {
|
|
224
224
|
type: String,
|
|
225
225
|
default: ""
|
|
226
|
+
},
|
|
227
|
+
iconClassPrefix: {
|
|
228
|
+
type: String,
|
|
229
|
+
default: "nut-icon"
|
|
230
|
+
},
|
|
231
|
+
iconFontClassName: {
|
|
232
|
+
type: String,
|
|
233
|
+
default: "nutui-iconfont"
|
|
226
234
|
}
|
|
227
235
|
},
|
|
228
236
|
emits: ["click"],
|
|
@@ -234,7 +242,7 @@ var __publicField = (obj, key, value) => {
|
|
|
234
242
|
}
|
|
235
243
|
};
|
|
236
244
|
const classes = vue.computed(() => {
|
|
237
|
-
const prefixCls = componentName$
|
|
245
|
+
const prefixCls = componentName$16;
|
|
238
246
|
return {
|
|
239
247
|
[prefixCls]: true,
|
|
240
248
|
[`${prefixCls}--${type.value}`]: type.value,
|
|
@@ -270,24 +278,25 @@ var __publicField = (obj, key, value) => {
|
|
|
270
278
|
};
|
|
271
279
|
}
|
|
272
280
|
});
|
|
273
|
-
const _hoisted_1$
|
|
274
|
-
function _sfc_render$
|
|
281
|
+
const _hoisted_1$11 = { class: "nut-button__warp" };
|
|
282
|
+
function _sfc_render$1j(_ctx, _cache, $props, $setup, $data, $options) {
|
|
275
283
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
276
284
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
277
285
|
class: vue.normalizeClass(_ctx.classes),
|
|
278
286
|
style: vue.normalizeStyle(_ctx.getStyle),
|
|
279
287
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
|
|
280
288
|
}, [
|
|
281
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
289
|
+
vue.createElementVNode("view", _hoisted_1$11, [
|
|
282
290
|
_ctx.loading ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
283
291
|
key: 0,
|
|
284
292
|
class: "nut-icon-loading"
|
|
285
293
|
})) : vue.createCommentVNode("", true),
|
|
286
294
|
_ctx.icon && !_ctx.loading ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
287
295
|
key: 1,
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
296
|
+
name: _ctx.icon,
|
|
297
|
+
"class-prefix": _ctx.iconClassPrefix,
|
|
298
|
+
"font-class-name": _ctx.iconFontClassName
|
|
299
|
+
}, null, 8, ["name", "class-prefix", "font-class-name"])) : vue.createCommentVNode("", true),
|
|
291
300
|
_ctx.$slots.default ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
292
301
|
key: 2,
|
|
293
302
|
class: vue.normalizeClass({ text: _ctx.icon || _ctx.loading })
|
|
@@ -297,9 +306,13 @@ var __publicField = (obj, key, value) => {
|
|
|
297
306
|
])
|
|
298
307
|
], 6);
|
|
299
308
|
}
|
|
300
|
-
var Button = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
301
|
-
|
|
302
|
-
|
|
309
|
+
var Button = /* @__PURE__ */ _export_sfc(_sfc_main$1r, [["render", _sfc_render$1j]]);
|
|
310
|
+
function useRouter() {
|
|
311
|
+
const proxy = vue.getCurrentInstance().proxy;
|
|
312
|
+
return proxy.$router || null;
|
|
313
|
+
}
|
|
314
|
+
const { componentName: componentName$15, create: create$1q } = createComponent("cell");
|
|
315
|
+
const _sfc_main$1q = create$1q({
|
|
303
316
|
props: {
|
|
304
317
|
title: { type: String, default: "" },
|
|
305
318
|
subTitle: { type: String, default: "" },
|
|
@@ -315,13 +328,13 @@ var __publicField = (obj, key, value) => {
|
|
|
315
328
|
emits: ["click"],
|
|
316
329
|
setup(props, { emit }) {
|
|
317
330
|
const classes = vue.computed(() => {
|
|
318
|
-
const prefixCls = componentName$
|
|
331
|
+
const prefixCls = componentName$15;
|
|
319
332
|
return {
|
|
320
333
|
[prefixCls]: true,
|
|
321
334
|
[`${prefixCls}--clickable`]: props.isLink || props.to
|
|
322
335
|
};
|
|
323
336
|
});
|
|
324
|
-
const router =
|
|
337
|
+
const router = useRouter();
|
|
325
338
|
const baseStyle = vue.computed(() => {
|
|
326
339
|
return {
|
|
327
340
|
borderRadius: pxCheck(props.roundRadius)
|
|
@@ -342,9 +355,9 @@ var __publicField = (obj, key, value) => {
|
|
|
342
355
|
};
|
|
343
356
|
}
|
|
344
357
|
});
|
|
345
|
-
const _hoisted_1$
|
|
346
|
-
const _hoisted_2$
|
|
347
|
-
function _sfc_render$
|
|
358
|
+
const _hoisted_1$10 = { class: "title" };
|
|
359
|
+
const _hoisted_2$R = { class: "nut-cell__title-desc" };
|
|
360
|
+
function _sfc_render$1i(_ctx, _cache, $props, $setup, $data, $options) {
|
|
348
361
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
349
362
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
350
363
|
class: vue.normalizeClass(_ctx.classes),
|
|
@@ -362,8 +375,8 @@ var __publicField = (obj, key, value) => {
|
|
|
362
375
|
name: _ctx.icon
|
|
363
376
|
}, null, 8, ["name"])) : vue.createCommentVNode("", true),
|
|
364
377
|
_ctx.subTitle ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 2 }, [
|
|
365
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
366
|
-
vue.createElementVNode("view", _hoisted_2$
|
|
378
|
+
vue.createElementVNode("view", _hoisted_1$10, vue.toDisplayString(_ctx.title), 1),
|
|
379
|
+
vue.createElementVNode("view", _hoisted_2$R, vue.toDisplayString(_ctx.subTitle), 1)
|
|
367
380
|
], 64)) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 3 }, [
|
|
368
381
|
vue.createTextVNode(vue.toDisplayString(_ctx.title), 1)
|
|
369
382
|
], 64))
|
|
@@ -381,16 +394,16 @@ var __publicField = (obj, key, value) => {
|
|
|
381
394
|
])
|
|
382
395
|
], 6);
|
|
383
396
|
}
|
|
384
|
-
var Cell = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
385
|
-
const { componentName: componentName$
|
|
386
|
-
const _sfc_main$
|
|
397
|
+
var Cell = /* @__PURE__ */ _export_sfc(_sfc_main$1q, [["render", _sfc_render$1i]]);
|
|
398
|
+
const { componentName: componentName$14, create: create$1p } = createComponent("cell-group");
|
|
399
|
+
const _sfc_main$1p = create$1p({
|
|
387
400
|
props: {
|
|
388
401
|
title: { type: String, default: "" },
|
|
389
402
|
desc: { type: String, default: "" }
|
|
390
403
|
},
|
|
391
404
|
setup() {
|
|
392
405
|
const classes = vue.computed(() => {
|
|
393
|
-
const prefixCls = componentName$
|
|
406
|
+
const prefixCls = componentName$14;
|
|
394
407
|
return {
|
|
395
408
|
[prefixCls]: true
|
|
396
409
|
};
|
|
@@ -400,29 +413,29 @@ var __publicField = (obj, key, value) => {
|
|
|
400
413
|
};
|
|
401
414
|
}
|
|
402
415
|
});
|
|
403
|
-
const _hoisted_1
|
|
416
|
+
const _hoisted_1$$ = {
|
|
404
417
|
key: 1,
|
|
405
418
|
class: "nut-cell-group__title"
|
|
406
419
|
};
|
|
407
|
-
const _hoisted_2$
|
|
420
|
+
const _hoisted_2$Q = {
|
|
408
421
|
key: 3,
|
|
409
422
|
class: "nut-cell-group__desc"
|
|
410
423
|
};
|
|
411
|
-
const _hoisted_3$
|
|
412
|
-
function _sfc_render$
|
|
424
|
+
const _hoisted_3$E = { class: "nut-cell-group__warp" };
|
|
425
|
+
function _sfc_render$1h(_ctx, _cache, $props, $setup, $data, $options) {
|
|
413
426
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
414
427
|
class: vue.normalizeClass(_ctx.classes)
|
|
415
428
|
}, [
|
|
416
|
-
_ctx.$slots.title ? vue.renderSlot(_ctx.$slots, "title", { key: 0 }) : _ctx.title ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1
|
|
417
|
-
_ctx.$slots.desc ? vue.renderSlot(_ctx.$slots, "desc", { key: 2 }) : _ctx.desc ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$
|
|
418
|
-
vue.createElementVNode("view", _hoisted_3$
|
|
429
|
+
_ctx.$slots.title ? vue.renderSlot(_ctx.$slots, "title", { key: 0 }) : _ctx.title ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$$, vue.toDisplayString(_ctx.title), 1)) : vue.createCommentVNode("", true),
|
|
430
|
+
_ctx.$slots.desc ? vue.renderSlot(_ctx.$slots, "desc", { key: 2 }) : _ctx.desc ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$Q, vue.toDisplayString(_ctx.desc), 1)) : vue.createCommentVNode("", true),
|
|
431
|
+
vue.createElementVNode("view", _hoisted_3$E, [
|
|
419
432
|
vue.renderSlot(_ctx.$slots, "default")
|
|
420
433
|
])
|
|
421
434
|
], 2);
|
|
422
435
|
}
|
|
423
|
-
var CellGroup = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
424
|
-
const { componentName: componentName
|
|
425
|
-
const _sfc_main$
|
|
436
|
+
var CellGroup = /* @__PURE__ */ _export_sfc(_sfc_main$1p, [["render", _sfc_render$1h]]);
|
|
437
|
+
const { componentName: componentName$13, create: create$1o } = createComponent("price");
|
|
438
|
+
const _sfc_main$1o = create$1o({
|
|
426
439
|
props: {
|
|
427
440
|
price: {
|
|
428
441
|
type: [Number, String],
|
|
@@ -456,7 +469,7 @@ var __publicField = (obj, key, value) => {
|
|
|
456
469
|
setup(props) {
|
|
457
470
|
const classes = vue.computed(() => {
|
|
458
471
|
return {
|
|
459
|
-
[componentName
|
|
472
|
+
[componentName$13]: true
|
|
460
473
|
};
|
|
461
474
|
});
|
|
462
475
|
const showSymbol = vue.computed(() => {
|
|
@@ -505,9 +518,9 @@ var __publicField = (obj, key, value) => {
|
|
|
505
518
|
};
|
|
506
519
|
}
|
|
507
520
|
});
|
|
508
|
-
const _hoisted_1$
|
|
509
|
-
const _hoisted_2$
|
|
510
|
-
function _sfc_render$
|
|
521
|
+
const _hoisted_1$_ = ["innerHTML"];
|
|
522
|
+
const _hoisted_2$P = ["innerHTML"];
|
|
523
|
+
function _sfc_render$1g(_ctx, _cache, $props, $setup, $data, $options) {
|
|
511
524
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
512
525
|
class: vue.normalizeClass(_ctx.classes)
|
|
513
526
|
}, [
|
|
@@ -515,7 +528,7 @@ var __publicField = (obj, key, value) => {
|
|
|
515
528
|
key: 0,
|
|
516
529
|
class: vue.normalizeClass(["nut-price--symbol", `nut-price--symbol-${_ctx.size}`]),
|
|
517
530
|
innerHTML: _ctx.showSymbol
|
|
518
|
-
}, null, 10, _hoisted_1$
|
|
531
|
+
}, null, 10, _hoisted_1$_)) : vue.createCommentVNode("", true),
|
|
519
532
|
vue.createElementVNode("view", {
|
|
520
533
|
class: vue.normalizeClass(`nut-price--${_ctx.size}`)
|
|
521
534
|
}, vue.toDisplayString(_ctx.formatThousands(_ctx.price)), 3),
|
|
@@ -530,11 +543,11 @@ var __publicField = (obj, key, value) => {
|
|
|
530
543
|
key: 2,
|
|
531
544
|
class: vue.normalizeClass(["nut-price--symbol", `nut-price--symbol-${_ctx.size}`]),
|
|
532
545
|
innerHTML: _ctx.showSymbol
|
|
533
|
-
}, null, 10, _hoisted_2$
|
|
546
|
+
}, null, 10, _hoisted_2$P)) : vue.createCommentVNode("", true)
|
|
534
547
|
], 2);
|
|
535
548
|
}
|
|
536
|
-
var Price = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
537
|
-
const { componentName: componentName$
|
|
549
|
+
var Price = /* @__PURE__ */ _export_sfc(_sfc_main$1o, [["render", _sfc_render$1g]]);
|
|
550
|
+
const { componentName: componentName$12, create: create$1n } = createComponent("overlay");
|
|
538
551
|
const overlayProps = {
|
|
539
552
|
visible: {
|
|
540
553
|
type: Boolean,
|
|
@@ -564,12 +577,12 @@ var __publicField = (obj, key, value) => {
|
|
|
564
577
|
default: true
|
|
565
578
|
}
|
|
566
579
|
};
|
|
567
|
-
const _sfc_main$
|
|
580
|
+
const _sfc_main$1n = create$1n({
|
|
568
581
|
props: overlayProps,
|
|
569
582
|
emits: ["click", "update:visible"],
|
|
570
583
|
setup(props, { emit }) {
|
|
571
584
|
const classes = vue.computed(() => {
|
|
572
|
-
const prefixCls = componentName$
|
|
585
|
+
const prefixCls = componentName$12;
|
|
573
586
|
return {
|
|
574
587
|
[prefixCls]: true,
|
|
575
588
|
[props.overlayClass]: true
|
|
@@ -609,7 +622,7 @@ var __publicField = (obj, key, value) => {
|
|
|
609
622
|
return { classes, style, touchmove, onClick };
|
|
610
623
|
}
|
|
611
624
|
});
|
|
612
|
-
function _sfc_render$
|
|
625
|
+
function _sfc_render$1f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
613
626
|
return vue.openBlock(), vue.createBlock(vue.Transition, { name: "overlay-fade" }, {
|
|
614
627
|
default: vue.withCtx(() => [
|
|
615
628
|
vue.withDirectives(vue.createElementVNode("view", {
|
|
@@ -626,9 +639,9 @@ var __publicField = (obj, key, value) => {
|
|
|
626
639
|
_: 3
|
|
627
640
|
});
|
|
628
641
|
}
|
|
629
|
-
var OverLay = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
630
|
-
const { componentName: componentName$
|
|
631
|
-
const _sfc_main$
|
|
642
|
+
var OverLay = /* @__PURE__ */ _export_sfc(_sfc_main$1n, [["render", _sfc_render$1f]]);
|
|
643
|
+
const { componentName: componentName$11, create: create$1m } = createComponent("divider");
|
|
644
|
+
const _sfc_main$1m = create$1m({
|
|
632
645
|
props: {
|
|
633
646
|
contentPosition: {
|
|
634
647
|
type: String,
|
|
@@ -646,7 +659,7 @@ var __publicField = (obj, key, value) => {
|
|
|
646
659
|
components: {},
|
|
647
660
|
setup(props, context) {
|
|
648
661
|
const classes = vue.computed(() => {
|
|
649
|
-
const prefixCls = componentName$
|
|
662
|
+
const prefixCls = componentName$11;
|
|
650
663
|
return {
|
|
651
664
|
[prefixCls]: true,
|
|
652
665
|
[`${prefixCls}-center`]: context.slots.default,
|
|
@@ -659,18 +672,18 @@ var __publicField = (obj, key, value) => {
|
|
|
659
672
|
return { classes };
|
|
660
673
|
}
|
|
661
674
|
});
|
|
662
|
-
function _sfc_render$
|
|
675
|
+
function _sfc_render$1e(_ctx, _cache, $props, $setup, $data, $options) {
|
|
663
676
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
664
677
|
class: vue.normalizeClass(_ctx.classes)
|
|
665
678
|
}, [
|
|
666
679
|
vue.renderSlot(_ctx.$slots, "default")
|
|
667
680
|
], 2);
|
|
668
681
|
}
|
|
669
|
-
var Divider = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
670
|
-
const { create: create$
|
|
671
|
-
const _sfc_main$
|
|
672
|
-
const { componentName: componentName$
|
|
673
|
-
const _sfc_main$
|
|
682
|
+
var Divider = /* @__PURE__ */ _export_sfc(_sfc_main$1m, [["render", _sfc_render$1e]]);
|
|
683
|
+
const { create: create$1l } = createComponent("layout");
|
|
684
|
+
const _sfc_main$1l = create$1l({});
|
|
685
|
+
const { componentName: componentName$10, create: create$1k } = createComponent("col");
|
|
686
|
+
const _sfc_main$1k = create$1k({
|
|
674
687
|
props: {
|
|
675
688
|
span: {
|
|
676
689
|
type: [String, Number],
|
|
@@ -682,7 +695,7 @@ var __publicField = (obj, key, value) => {
|
|
|
682
695
|
}
|
|
683
696
|
},
|
|
684
697
|
setup(props) {
|
|
685
|
-
const prefixCls = componentName$
|
|
698
|
+
const prefixCls = componentName$10;
|
|
686
699
|
const gutter = vue.inject("gutter");
|
|
687
700
|
const classes = vue.computed(() => {
|
|
688
701
|
return {
|
|
@@ -704,7 +717,7 @@ var __publicField = (obj, key, value) => {
|
|
|
704
717
|
};
|
|
705
718
|
}
|
|
706
719
|
});
|
|
707
|
-
function _sfc_render$
|
|
720
|
+
function _sfc_render$1d(_ctx, _cache, $props, $setup, $data, $options) {
|
|
708
721
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
709
722
|
class: vue.normalizeClass(_ctx.classes),
|
|
710
723
|
style: vue.normalizeStyle(_ctx.style)
|
|
@@ -712,9 +725,9 @@ var __publicField = (obj, key, value) => {
|
|
|
712
725
|
vue.renderSlot(_ctx.$slots, "default")
|
|
713
726
|
], 6);
|
|
714
727
|
}
|
|
715
|
-
var Col = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
716
|
-
const { componentName: componentName
|
|
717
|
-
const _sfc_main$
|
|
728
|
+
var Col = /* @__PURE__ */ _export_sfc(_sfc_main$1k, [["render", _sfc_render$1d]]);
|
|
729
|
+
const { componentName: componentName$$, create: create$1j } = createComponent("row");
|
|
730
|
+
const _sfc_main$1j = create$1j({
|
|
718
731
|
props: {
|
|
719
732
|
type: {
|
|
720
733
|
type: String,
|
|
@@ -738,7 +751,7 @@ var __publicField = (obj, key, value) => {
|
|
|
738
751
|
}
|
|
739
752
|
},
|
|
740
753
|
setup(props) {
|
|
741
|
-
const prefixCls = componentName
|
|
754
|
+
const prefixCls = componentName$$;
|
|
742
755
|
vue.provide("gutter", props.gutter);
|
|
743
756
|
const getClass = (prefix, type) => {
|
|
744
757
|
return prefix ? type ? `nut-row-${prefix}-${type}` : "" : `nut-row-${type}`;
|
|
@@ -757,14 +770,14 @@ var __publicField = (obj, key, value) => {
|
|
|
757
770
|
};
|
|
758
771
|
}
|
|
759
772
|
});
|
|
760
|
-
function _sfc_render$
|
|
773
|
+
function _sfc_render$1c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
761
774
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
762
775
|
class: vue.normalizeClass(_ctx.getClasses())
|
|
763
776
|
}, [
|
|
764
777
|
vue.renderSlot(_ctx.$slots, "default")
|
|
765
778
|
], 2);
|
|
766
779
|
}
|
|
767
|
-
var Row = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
780
|
+
var Row = /* @__PURE__ */ _export_sfc(_sfc_main$1j, [["render", _sfc_render$1c]]);
|
|
768
781
|
let count = 0;
|
|
769
782
|
const CLSNAME = "nut-overflow-hidden";
|
|
770
783
|
const useLockScroll = (isLock) => {
|
|
@@ -782,7 +795,7 @@ var __publicField = (obj, key, value) => {
|
|
|
782
795
|
};
|
|
783
796
|
return [lock, unlock];
|
|
784
797
|
};
|
|
785
|
-
const { componentName: componentName$
|
|
798
|
+
const { componentName: componentName$_, create: create$1i } = createComponent("popup");
|
|
786
799
|
let _zIndex = 2e3;
|
|
787
800
|
const popupProps = __spreadProps(__spreadValues({}, overlayProps), {
|
|
788
801
|
position: {
|
|
@@ -830,10 +843,10 @@ var __publicField = (obj, key, value) => {
|
|
|
830
843
|
default: true
|
|
831
844
|
}
|
|
832
845
|
});
|
|
833
|
-
const _sfc_main$
|
|
846
|
+
const _sfc_main$1i = create$1i({
|
|
834
847
|
components: {
|
|
835
848
|
[OverLay.name]: OverLay,
|
|
836
|
-
[_sfc_main$
|
|
849
|
+
[_sfc_main$1s.name]: _sfc_main$1s
|
|
837
850
|
},
|
|
838
851
|
props: __spreadValues({}, popupProps),
|
|
839
852
|
emits: ["click", "click-close-icon", "open", "close", "opend", "closed", "update:visible", "click-overlay"],
|
|
@@ -848,7 +861,7 @@ var __publicField = (obj, key, value) => {
|
|
|
848
861
|
});
|
|
849
862
|
const [lockScroll, unlockScroll] = useLockScroll(() => props.lockScroll);
|
|
850
863
|
const classes = vue.computed(() => {
|
|
851
|
-
const prefixCls = componentName$
|
|
864
|
+
const prefixCls = componentName$_;
|
|
852
865
|
return {
|
|
853
866
|
[prefixCls]: true,
|
|
854
867
|
["round"]: props.round,
|
|
@@ -955,8 +968,8 @@ var __publicField = (obj, key, value) => {
|
|
|
955
968
|
});
|
|
956
969
|
}
|
|
957
970
|
});
|
|
958
|
-
const _hoisted_1$
|
|
959
|
-
function _sfc_render$
|
|
971
|
+
const _hoisted_1$Z = { key: 1 };
|
|
972
|
+
function _sfc_render$1b(_ctx, _cache, $props, $setup, $data, $options) {
|
|
960
973
|
const _component_nut_overlay = vue.resolveComponent("nut-overlay");
|
|
961
974
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
962
975
|
return _ctx.isWrapTeleport ? (vue.openBlock(), vue.createBlock(vue.Teleport, {
|
|
@@ -1002,7 +1015,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1002
1015
|
]),
|
|
1003
1016
|
_: 3
|
|
1004
1017
|
}, 8, ["name", "onAfterEnter", "onAfterLeave"])
|
|
1005
|
-
], 8, ["to"])) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$
|
|
1018
|
+
], 8, ["to"])) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$Z, [
|
|
1006
1019
|
_ctx.overlay ? (vue.openBlock(), vue.createBlock(_component_nut_overlay, {
|
|
1007
1020
|
key: 0,
|
|
1008
1021
|
visible: _ctx.visible,
|
|
@@ -1044,34 +1057,9 @@ var __publicField = (obj, key, value) => {
|
|
|
1044
1057
|
}, 8, ["name", "onAfterEnter", "onAfterLeave"])
|
|
1045
1058
|
]));
|
|
1046
1059
|
}
|
|
1047
|
-
var Popup = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
1048
|
-
const
|
|
1049
|
-
|
|
1050
|
-
var previous = 0;
|
|
1051
|
-
} else if (type === 2) {
|
|
1052
|
-
var timeout;
|
|
1053
|
-
}
|
|
1054
|
-
return function() {
|
|
1055
|
-
let context = this;
|
|
1056
|
-
let args = arguments;
|
|
1057
|
-
if (type === 1) {
|
|
1058
|
-
let now = Date.now();
|
|
1059
|
-
if (now - previous > wait) {
|
|
1060
|
-
func.apply(context, args);
|
|
1061
|
-
previous = now;
|
|
1062
|
-
}
|
|
1063
|
-
} else if (type === 2) {
|
|
1064
|
-
if (!timeout) {
|
|
1065
|
-
timeout = setTimeout(() => {
|
|
1066
|
-
timeout = null;
|
|
1067
|
-
func.apply(context, args);
|
|
1068
|
-
}, wait);
|
|
1069
|
-
}
|
|
1070
|
-
}
|
|
1071
|
-
};
|
|
1072
|
-
};
|
|
1073
|
-
const { create: create$1d } = createComponent("video");
|
|
1074
|
-
const _sfc_main$1d = create$1d({
|
|
1060
|
+
var Popup = /* @__PURE__ */ _export_sfc(_sfc_main$1i, [["render", _sfc_render$1b]]);
|
|
1061
|
+
const { create: create$1h } = createComponent("video");
|
|
1062
|
+
const _sfc_main$1h = create$1h({
|
|
1075
1063
|
props: {
|
|
1076
1064
|
source: {
|
|
1077
1065
|
type: Object,
|
|
@@ -1176,7 +1164,6 @@ var __publicField = (obj, key, value) => {
|
|
|
1176
1164
|
emit("pause", state.videoElm);
|
|
1177
1165
|
});
|
|
1178
1166
|
state.videoElm.addEventListener("ended", playEnded);
|
|
1179
|
-
state.videoElm.addEventListener("timeupdate", throttle(getPlayTime, 100, 1));
|
|
1180
1167
|
}
|
|
1181
1168
|
};
|
|
1182
1169
|
const customerInit = () => {
|
|
@@ -1200,7 +1187,6 @@ var __publicField = (obj, key, value) => {
|
|
|
1200
1187
|
state.videoElm.addEventListener("progress", () => {
|
|
1201
1188
|
getLoadTime();
|
|
1202
1189
|
});
|
|
1203
|
-
state.videoElm.addEventListener("timeupdate", throttle(getPlayTime, 100, 1));
|
|
1204
1190
|
state.videoElm.addEventListener("ended", playEnded);
|
|
1205
1191
|
emit("play", state.videoElm);
|
|
1206
1192
|
} catch (e) {
|
|
@@ -1212,37 +1198,10 @@ var __publicField = (obj, key, value) => {
|
|
|
1212
1198
|
}
|
|
1213
1199
|
}
|
|
1214
1200
|
};
|
|
1215
|
-
const timeFormat = (t) => {
|
|
1216
|
-
var h = Math.floor(t / 3600);
|
|
1217
|
-
if (h < 10) {
|
|
1218
|
-
h = "0" + h;
|
|
1219
|
-
}
|
|
1220
|
-
var m = Math.floor(t % 3600 / 60);
|
|
1221
|
-
if (m < 10) {
|
|
1222
|
-
m = "0" + m;
|
|
1223
|
-
}
|
|
1224
|
-
var s = Math.round(t % 3600 % 60);
|
|
1225
|
-
if (s < 10) {
|
|
1226
|
-
s = "0" + s;
|
|
1227
|
-
}
|
|
1228
|
-
var str = "";
|
|
1229
|
-
if (h != 0) {
|
|
1230
|
-
str = h + ":" + m + ":" + s;
|
|
1231
|
-
} else {
|
|
1232
|
-
str = m + ":" + s;
|
|
1233
|
-
}
|
|
1234
|
-
return str;
|
|
1235
|
-
};
|
|
1236
1201
|
const getLoadTime = () => {
|
|
1237
1202
|
if (state.videoSet.loaded)
|
|
1238
1203
|
state.videoSet.loaded = state.videoElm.buffered.end(0) / state.videoElm.duration * 100;
|
|
1239
1204
|
};
|
|
1240
|
-
const getPlayTime = () => {
|
|
1241
|
-
const percent = state.videoElm.currentTime / state.videoElm.duration;
|
|
1242
|
-
state.videoSet.progress.current = Math.round(state.videoSet.progress.width * percent);
|
|
1243
|
-
state.videoSet.totalTime = timeFormat(state.videoElm.duration);
|
|
1244
|
-
state.videoSet.displayTime = timeFormat(state.videoElm.currentTime);
|
|
1245
|
-
};
|
|
1246
1205
|
const playEnded = () => {
|
|
1247
1206
|
state.state.playing = false;
|
|
1248
1207
|
state.state.isEnd = true;
|
|
@@ -1317,21 +1276,21 @@ var __publicField = (obj, key, value) => {
|
|
|
1317
1276
|
});
|
|
1318
1277
|
}
|
|
1319
1278
|
});
|
|
1320
|
-
const _hoisted_1$
|
|
1279
|
+
const _hoisted_1$Y = {
|
|
1321
1280
|
class: "nut-video",
|
|
1322
1281
|
ref: "videocon"
|
|
1323
1282
|
};
|
|
1324
|
-
const _hoisted_2$
|
|
1325
|
-
const _hoisted_3$
|
|
1326
|
-
const _hoisted_4$
|
|
1327
|
-
const _hoisted_5$
|
|
1328
|
-
const _hoisted_6$
|
|
1283
|
+
const _hoisted_2$O = ["muted", "autoplay", "loop", "poster", "controls", "preload"];
|
|
1284
|
+
const _hoisted_3$D = ["src", "type"];
|
|
1285
|
+
const _hoisted_4$t = { class: "current-time" };
|
|
1286
|
+
const _hoisted_5$k = { class: "progress-container" };
|
|
1287
|
+
const _hoisted_6$h = {
|
|
1329
1288
|
class: "progress",
|
|
1330
1289
|
ref: "progressBar"
|
|
1331
1290
|
};
|
|
1332
|
-
const _hoisted_7$
|
|
1333
|
-
const _hoisted_8$
|
|
1334
|
-
_hoisted_7$
|
|
1291
|
+
const _hoisted_7$c = /* @__PURE__ */ vue.createElementVNode("div", { class: "move-handle" }, null, -1);
|
|
1292
|
+
const _hoisted_8$9 = [
|
|
1293
|
+
_hoisted_7$c
|
|
1335
1294
|
];
|
|
1336
1295
|
const _hoisted_9$6 = {
|
|
1337
1296
|
class: "played",
|
|
@@ -1340,8 +1299,8 @@ var __publicField = (obj, key, value) => {
|
|
|
1340
1299
|
const _hoisted_10$4 = { class: "duration-time" };
|
|
1341
1300
|
const _hoisted_11$4 = { class: "nut-video-error" };
|
|
1342
1301
|
const _hoisted_12$4 = /* @__PURE__ */ vue.createElementVNode("p", { class: "lose" }, "\u89C6\u9891\u52A0\u8F7D\u5931\u8D25", -1);
|
|
1343
|
-
function _sfc_render$
|
|
1344
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
1302
|
+
function _sfc_render$1a(_ctx, _cache, $props, $setup, $data, $options) {
|
|
1303
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$Y, [
|
|
1345
1304
|
vue.createElementVNode("video", {
|
|
1346
1305
|
ref: "root",
|
|
1347
1306
|
class: "nut-video-player",
|
|
@@ -1356,8 +1315,8 @@ var __publicField = (obj, key, value) => {
|
|
|
1356
1315
|
vue.createElementVNode("source", {
|
|
1357
1316
|
src: _ctx.source.src,
|
|
1358
1317
|
type: _ctx.source.type
|
|
1359
|
-
}, null, 8, _hoisted_3$
|
|
1360
|
-
], 40, _hoisted_2$
|
|
1318
|
+
}, null, 8, _hoisted_3$D)
|
|
1319
|
+
], 40, _hoisted_2$O),
|
|
1361
1320
|
_ctx.showToolbox && !_ctx.isDisabled ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
1362
1321
|
key: 0,
|
|
1363
1322
|
class: "playing-mask",
|
|
@@ -1379,9 +1338,9 @@ var __publicField = (obj, key, value) => {
|
|
|
1379
1338
|
class: "control-play-btn",
|
|
1380
1339
|
onClick: _cache[3] || (_cache[3] = (...args) => _ctx.play && _ctx.play(...args))
|
|
1381
1340
|
}),
|
|
1382
|
-
vue.createElementVNode("div", _hoisted_4$
|
|
1383
|
-
vue.createElementVNode("div", _hoisted_5$
|
|
1384
|
-
vue.createElementVNode("div", _hoisted_6$
|
|
1341
|
+
vue.createElementVNode("div", _hoisted_4$t, vue.toDisplayString(_ctx.videoSet.displayTime), 1),
|
|
1342
|
+
vue.createElementVNode("div", _hoisted_5$k, [
|
|
1343
|
+
vue.createElementVNode("div", _hoisted_6$h, [
|
|
1385
1344
|
vue.createElementVNode("div", {
|
|
1386
1345
|
class: "buffered",
|
|
1387
1346
|
style: vue.normalizeStyle({ width: `${_ctx.videoSet.loaded}%` })
|
|
@@ -1394,7 +1353,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1394
1353
|
onTouchmove: _cache[4] || (_cache[4] = vue.withModifiers(($event) => _ctx.touchSlidMove($event), ["stop", "prevent"])),
|
|
1395
1354
|
onTouchstart: _cache[5] || (_cache[5] = vue.withModifiers(($event) => _ctx.touchSlidSrart($event), ["stop"])),
|
|
1396
1355
|
onTouchend: _cache[6] || (_cache[6] = vue.withModifiers(($event) => _ctx.touchSlidEnd($event), ["stop"]))
|
|
1397
|
-
}, _hoisted_8$
|
|
1356
|
+
}, _hoisted_8$9, 36),
|
|
1398
1357
|
vue.createElementVNode("div", _hoisted_9$6, null, 512)
|
|
1399
1358
|
], 512)
|
|
1400
1359
|
]),
|
|
@@ -1421,9 +1380,9 @@ var __publicField = (obj, key, value) => {
|
|
|
1421
1380
|
])
|
|
1422
1381
|
], 512);
|
|
1423
1382
|
}
|
|
1424
|
-
var Video = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
1383
|
+
var Video = /* @__PURE__ */ _export_sfc(_sfc_main$1h, [["render", _sfc_render$1a]]);
|
|
1425
1384
|
const DISTANCE = 5;
|
|
1426
|
-
function useTouch$
|
|
1385
|
+
function useTouch$2() {
|
|
1427
1386
|
const state = vue.reactive({
|
|
1428
1387
|
startX: 0,
|
|
1429
1388
|
startY: 0,
|
|
@@ -1470,14 +1429,14 @@ var __publicField = (obj, key, value) => {
|
|
|
1470
1429
|
move
|
|
1471
1430
|
};
|
|
1472
1431
|
}
|
|
1473
|
-
function useExpose
|
|
1432
|
+
function useExpose(apis) {
|
|
1474
1433
|
const instance = vue.getCurrentInstance();
|
|
1475
1434
|
if (instance) {
|
|
1476
1435
|
Object.assign(instance.proxy, apis);
|
|
1477
1436
|
}
|
|
1478
1437
|
}
|
|
1479
|
-
const { create: create$
|
|
1480
|
-
const _sfc_main$
|
|
1438
|
+
const { create: create$1g, componentName: componentName$Z } = createComponent("swiper");
|
|
1439
|
+
const _sfc_main$1g = create$1g({
|
|
1481
1440
|
props: {
|
|
1482
1441
|
width: {
|
|
1483
1442
|
type: [Number, String],
|
|
@@ -1544,9 +1503,9 @@ var __publicField = (obj, key, value) => {
|
|
|
1544
1503
|
children: [],
|
|
1545
1504
|
style: {}
|
|
1546
1505
|
});
|
|
1547
|
-
const touch = useTouch$
|
|
1506
|
+
const touch = useTouch$2();
|
|
1548
1507
|
const classes = vue.computed(() => {
|
|
1549
|
-
const prefixCls = componentName$
|
|
1508
|
+
const prefixCls = componentName$Z;
|
|
1550
1509
|
return {
|
|
1551
1510
|
[prefixCls]: true
|
|
1552
1511
|
};
|
|
@@ -1761,7 +1720,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1761
1720
|
size,
|
|
1762
1721
|
relation
|
|
1763
1722
|
});
|
|
1764
|
-
useExpose
|
|
1723
|
+
useExpose({
|
|
1765
1724
|
prev,
|
|
1766
1725
|
next,
|
|
1767
1726
|
to
|
|
@@ -1799,7 +1758,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1799
1758
|
state,
|
|
1800
1759
|
classes,
|
|
1801
1760
|
container,
|
|
1802
|
-
componentName: componentName$
|
|
1761
|
+
componentName: componentName$Z,
|
|
1803
1762
|
isVertical,
|
|
1804
1763
|
slots,
|
|
1805
1764
|
activePagination,
|
|
@@ -1809,7 +1768,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1809
1768
|
};
|
|
1810
1769
|
}
|
|
1811
1770
|
});
|
|
1812
|
-
function _sfc_render$
|
|
1771
|
+
function _sfc_render$19(_ctx, _cache, $props, $setup, $data, $options) {
|
|
1813
1772
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
1814
1773
|
ref: "container",
|
|
1815
1774
|
class: vue.normalizeClass(_ctx.classes),
|
|
@@ -1846,15 +1805,9 @@ var __publicField = (obj, key, value) => {
|
|
|
1846
1805
|
], 2)) : vue.createCommentVNode("", true)
|
|
1847
1806
|
], 34);
|
|
1848
1807
|
}
|
|
1849
|
-
var Swiper = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
if (instance) {
|
|
1853
|
-
Object.assign(instance.proxy, apis);
|
|
1854
|
-
}
|
|
1855
|
-
}
|
|
1856
|
-
const { create: create$1b, componentName: componentName$U } = createComponent("swiper-item");
|
|
1857
|
-
const _sfc_main$1b = create$1b({
|
|
1808
|
+
var Swiper = /* @__PURE__ */ _export_sfc(_sfc_main$1g, [["render", _sfc_render$19]]);
|
|
1809
|
+
const { create: create$1f, componentName: componentName$Y } = createComponent("swiper-item");
|
|
1810
|
+
const _sfc_main$1f = create$1f({
|
|
1858
1811
|
props: {},
|
|
1859
1812
|
setup(props, { slots }) {
|
|
1860
1813
|
const parent = vue.inject("parent");
|
|
@@ -1863,7 +1816,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1863
1816
|
offset: 0
|
|
1864
1817
|
});
|
|
1865
1818
|
const classes = vue.computed(() => {
|
|
1866
|
-
const prefixCls = componentName$
|
|
1819
|
+
const prefixCls = componentName$Y;
|
|
1867
1820
|
return {
|
|
1868
1821
|
[prefixCls]: true
|
|
1869
1822
|
};
|
|
@@ -1889,7 +1842,7 @@ var __publicField = (obj, key, value) => {
|
|
|
1889
1842
|
};
|
|
1890
1843
|
}
|
|
1891
1844
|
});
|
|
1892
|
-
function _sfc_render$
|
|
1845
|
+
function _sfc_render$18(_ctx, _cache, $props, $setup, $data, $options) {
|
|
1893
1846
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
1894
1847
|
class: vue.normalizeClass(_ctx.classes),
|
|
1895
1848
|
style: vue.normalizeStyle(_ctx.style)
|
|
@@ -1897,9 +1850,9 @@ var __publicField = (obj, key, value) => {
|
|
|
1897
1850
|
vue.renderSlot(_ctx.$slots, "default")
|
|
1898
1851
|
], 6);
|
|
1899
1852
|
}
|
|
1900
|
-
var SwiperItem = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
1901
|
-
const { componentName: componentName$
|
|
1902
|
-
const _sfc_main$
|
|
1853
|
+
var SwiperItem = /* @__PURE__ */ _export_sfc(_sfc_main$1f, [["render", _sfc_render$18]]);
|
|
1854
|
+
const { componentName: componentName$X, create: create$1e } = createComponent("imagepreview");
|
|
1855
|
+
const _sfc_main$1e = create$1e({
|
|
1903
1856
|
props: {
|
|
1904
1857
|
show: {
|
|
1905
1858
|
type: Boolean,
|
|
@@ -1932,6 +1885,10 @@ var __publicField = (obj, key, value) => {
|
|
|
1932
1885
|
autoplay: {
|
|
1933
1886
|
type: [Number, String],
|
|
1934
1887
|
default: 3e3
|
|
1888
|
+
},
|
|
1889
|
+
isWrapTeleport: {
|
|
1890
|
+
type: Boolean,
|
|
1891
|
+
default: false
|
|
1935
1892
|
}
|
|
1936
1893
|
},
|
|
1937
1894
|
emits: ["close"],
|
|
@@ -1984,7 +1941,6 @@ var __publicField = (obj, key, value) => {
|
|
|
1984
1941
|
state.eleImg.style.transform = "scale(" + state.store.scale + ")";
|
|
1985
1942
|
};
|
|
1986
1943
|
const onTouchStart = (event) => {
|
|
1987
|
-
console.log("start");
|
|
1988
1944
|
const curTouchTime = new Date().getTime();
|
|
1989
1945
|
if (curTouchTime - state.lastTouchEndTime < 300) {
|
|
1990
1946
|
const store2 = state.store;
|
|
@@ -2036,7 +1992,6 @@ var __publicField = (obj, key, value) => {
|
|
|
2036
1992
|
}
|
|
2037
1993
|
};
|
|
2038
1994
|
const onTouchEnd = () => {
|
|
2039
|
-
console.log("end");
|
|
2040
1995
|
state.lastTouchEndTime = new Date().getTime();
|
|
2041
1996
|
const store = state.store;
|
|
2042
1997
|
store.moveable = false;
|
|
@@ -2072,9 +2027,9 @@ var __publicField = (obj, key, value) => {
|
|
|
2072
2027
|
});
|
|
2073
2028
|
}
|
|
2074
2029
|
});
|
|
2075
|
-
const _hoisted_1$
|
|
2076
|
-
const _hoisted_2$
|
|
2077
|
-
function _sfc_render$
|
|
2030
|
+
const _hoisted_1$X = ["src"];
|
|
2031
|
+
const _hoisted_2$N = { class: "nut-imagepreview-index" };
|
|
2032
|
+
function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
|
|
2078
2033
|
const _component_nut_video = vue.resolveComponent("nut-video");
|
|
2079
2034
|
const _component_nut_swiper_item = vue.resolveComponent("nut-swiper-item");
|
|
2080
2035
|
const _component_nut_swiper = vue.resolveComponent("nut-swiper");
|
|
@@ -2083,6 +2038,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2083
2038
|
"pop-class": "custom-pop",
|
|
2084
2039
|
visible: _ctx.showPop,
|
|
2085
2040
|
"onUpdate:visible": _cache[2] || (_cache[2] = ($event) => _ctx.showPop = $event),
|
|
2041
|
+
isWrapTeleport: _ctx.isWrapTeleport,
|
|
2086
2042
|
onClick: _ctx.onClose,
|
|
2087
2043
|
style: { "width": "100%" }
|
|
2088
2044
|
}, {
|
|
@@ -2122,7 +2078,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2122
2078
|
vue.createElementVNode("img", {
|
|
2123
2079
|
src: item.src,
|
|
2124
2080
|
class: "nut-imagepreview-img"
|
|
2125
|
-
}, null, 8, _hoisted_1$
|
|
2081
|
+
}, null, 8, _hoisted_1$X)
|
|
2126
2082
|
]),
|
|
2127
2083
|
_: 2
|
|
2128
2084
|
}, 1024);
|
|
@@ -2131,12 +2087,12 @@ var __publicField = (obj, key, value) => {
|
|
|
2131
2087
|
_: 1
|
|
2132
2088
|
}, 8, ["auto-play", "onChange", "init-page", "pagination-visible", "pagination-color"])) : vue.createCommentVNode("", true)
|
|
2133
2089
|
], 32),
|
|
2134
|
-
vue.createElementVNode("view", _hoisted_2$
|
|
2090
|
+
vue.createElementVNode("view", _hoisted_2$N, vue.toDisplayString(_ctx.active) + " / " + vue.toDisplayString(_ctx.images.length + _ctx.videos.length), 1)
|
|
2135
2091
|
]),
|
|
2136
2092
|
_: 1
|
|
2137
|
-
}, 8, ["visible", "onClick"]);
|
|
2093
|
+
}, 8, ["visible", "isWrapTeleport", "onClick"]);
|
|
2138
2094
|
}
|
|
2139
|
-
var ImagePreview = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
2095
|
+
var ImagePreview = /* @__PURE__ */ _export_sfc(_sfc_main$1e, [["render", _sfc_render$17]]);
|
|
2140
2096
|
class ImagePreviewOptions {
|
|
2141
2097
|
constructor() {
|
|
2142
2098
|
__publicField(this, "show", false);
|
|
@@ -2184,17 +2140,180 @@ var __publicField = (obj, key, value) => {
|
|
|
2184
2140
|
app.use(ImagePreview);
|
|
2185
2141
|
app.config.globalProperties.$imagepreview = _ImagePreview;
|
|
2186
2142
|
};
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2143
|
+
function isWindow(val) {
|
|
2144
|
+
return val === window;
|
|
2145
|
+
}
|
|
2146
|
+
const useRect = (elementRef) => {
|
|
2147
|
+
const element = vue.unref(elementRef);
|
|
2148
|
+
if (isWindow(element)) {
|
|
2149
|
+
const width = element.innerWidth;
|
|
2150
|
+
const height = element.innerHeight;
|
|
2151
|
+
return {
|
|
2152
|
+
top: 0,
|
|
2153
|
+
left: 0,
|
|
2154
|
+
right: width,
|
|
2155
|
+
bottom: height,
|
|
2156
|
+
width,
|
|
2157
|
+
height
|
|
2158
|
+
};
|
|
2159
|
+
}
|
|
2160
|
+
if (element && element.getBoundingClientRect) {
|
|
2161
|
+
return element.getBoundingClientRect();
|
|
2162
|
+
}
|
|
2163
|
+
return {
|
|
2164
|
+
top: 0,
|
|
2165
|
+
left: 0,
|
|
2166
|
+
right: 0,
|
|
2167
|
+
bottom: 0,
|
|
2168
|
+
width: 0,
|
|
2169
|
+
height: 0
|
|
2170
|
+
};
|
|
2171
|
+
};
|
|
2172
|
+
const { componentName: componentName$W, create: create$1d } = createComponent("sticky");
|
|
2173
|
+
const _sfc_main$1d = create$1d({
|
|
2174
|
+
props: {
|
|
2175
|
+
position: {
|
|
2176
|
+
type: String,
|
|
2177
|
+
default: "top"
|
|
2178
|
+
},
|
|
2179
|
+
top: {
|
|
2180
|
+
type: [Number, String],
|
|
2181
|
+
default: 0
|
|
2182
|
+
},
|
|
2183
|
+
bottom: {
|
|
2184
|
+
type: [Number, String],
|
|
2185
|
+
default: 0
|
|
2186
|
+
},
|
|
2187
|
+
container: {
|
|
2188
|
+
type: Object
|
|
2189
|
+
},
|
|
2190
|
+
zIndex: {
|
|
2191
|
+
type: [Number, String],
|
|
2192
|
+
default: 2e3
|
|
2193
|
+
}
|
|
2194
|
+
},
|
|
2195
|
+
emits: ["change", "scroll"],
|
|
2196
|
+
setup(props, { emit, slots }) {
|
|
2197
|
+
const root = vue.ref();
|
|
2198
|
+
const state = vue.reactive({
|
|
2199
|
+
width: 0,
|
|
2200
|
+
height: 0,
|
|
2201
|
+
fixed: false,
|
|
2202
|
+
transform: 0
|
|
2203
|
+
});
|
|
2204
|
+
const rootStyle = vue.computed(() => {
|
|
2205
|
+
const { fixed, width, height } = state;
|
|
2206
|
+
if (fixed) {
|
|
2207
|
+
return {
|
|
2208
|
+
width: `${width}px`,
|
|
2209
|
+
height: `${height}px`
|
|
2210
|
+
};
|
|
2211
|
+
}
|
|
2212
|
+
});
|
|
2213
|
+
const stickyStyle = vue.computed(() => {
|
|
2214
|
+
if (!state.fixed)
|
|
2215
|
+
return;
|
|
2216
|
+
const style = {
|
|
2217
|
+
width: `${state.width}px`,
|
|
2218
|
+
height: `${state.height}px`,
|
|
2219
|
+
[props.position]: `${offset.value}px`,
|
|
2220
|
+
zIndex: +props.zIndex
|
|
2221
|
+
};
|
|
2222
|
+
if (state.transform)
|
|
2223
|
+
style.transform = `translate3d(0, ${state.transform}px, 0)`;
|
|
2224
|
+
return style;
|
|
2225
|
+
});
|
|
2226
|
+
const offset = vue.computed(() => {
|
|
2227
|
+
return props.position === "top" ? props.top : props.bottom;
|
|
2228
|
+
});
|
|
2229
|
+
const isHidden = (elementRef) => {
|
|
2230
|
+
const el = vue.unref(elementRef);
|
|
2231
|
+
if (!el)
|
|
2232
|
+
return false;
|
|
2233
|
+
const style = window.getComputedStyle(el);
|
|
2234
|
+
const hidden = style.display === "none";
|
|
2235
|
+
const parentHidden = el.offsetParent === null && style.position !== "fixed";
|
|
2236
|
+
return hidden || parentHidden;
|
|
2237
|
+
};
|
|
2238
|
+
const isExistRoot = () => {
|
|
2239
|
+
if (!root.value || isHidden(root))
|
|
2240
|
+
return false;
|
|
2241
|
+
return true;
|
|
2242
|
+
};
|
|
2243
|
+
const getScrollTop = (el) => {
|
|
2244
|
+
return Math.max(0, "scrollTop" in el ? el.scrollTop : el.pageYOffset);
|
|
2245
|
+
};
|
|
2246
|
+
const renderFixed = () => {
|
|
2247
|
+
var _a;
|
|
2248
|
+
return vue.h("view", {
|
|
2249
|
+
style: stickyStyle.value,
|
|
2250
|
+
class: state.fixed ? `${componentName$W} nut-sticky--fixed` : componentName$W
|
|
2251
|
+
}, (_a = slots.default) == null ? void 0 : _a.call(slots));
|
|
2252
|
+
};
|
|
2253
|
+
const onScroll = () => {
|
|
2254
|
+
if (!isExistRoot())
|
|
2255
|
+
return;
|
|
2256
|
+
const { container, position } = props;
|
|
2257
|
+
const scrollTop = getScrollTop(window);
|
|
2258
|
+
const rootRect = useRect(root);
|
|
2259
|
+
if (rootRect.width || rootRect.height) {
|
|
2260
|
+
state.width = rootRect.width;
|
|
2261
|
+
state.height = rootRect.height;
|
|
2262
|
+
}
|
|
2263
|
+
if (position === "top") {
|
|
2264
|
+
if (container) {
|
|
2265
|
+
const containerRect = useRect(container);
|
|
2266
|
+
const diff = containerRect.bottom - +offset.value - state.height;
|
|
2267
|
+
state.fixed = +offset.value > rootRect.top && containerRect.bottom > 0;
|
|
2268
|
+
state.transform = diff < 0 ? diff : 0;
|
|
2269
|
+
} else {
|
|
2270
|
+
state.fixed = offset.value > rootRect.top;
|
|
2271
|
+
}
|
|
2272
|
+
} else if (position === "bottom") {
|
|
2273
|
+
const clientHeight = document.documentElement.clientHeight;
|
|
2274
|
+
if (container) {
|
|
2275
|
+
const containerRect = useRect(container);
|
|
2276
|
+
const diff = clientHeight - containerRect.top - +offset.value - state.height;
|
|
2277
|
+
state.fixed = clientHeight - +offset.value < rootRect.bottom && clientHeight > containerRect.top;
|
|
2278
|
+
state.transform = diff < 0 ? -diff : 0;
|
|
2279
|
+
} else {
|
|
2280
|
+
state.fixed = clientHeight - +offset.value < rootRect.bottom;
|
|
2281
|
+
}
|
|
2282
|
+
}
|
|
2283
|
+
emit("scroll", {
|
|
2284
|
+
top: scrollTop,
|
|
2285
|
+
fixed: state.fixed
|
|
2286
|
+
});
|
|
2287
|
+
};
|
|
2288
|
+
vue.watch(() => state.fixed, (val) => {
|
|
2289
|
+
emit("change", val);
|
|
2290
|
+
});
|
|
2291
|
+
vue.onMounted(() => {
|
|
2292
|
+
window.addEventListener("scroll", onScroll);
|
|
2293
|
+
onScroll();
|
|
2294
|
+
});
|
|
2295
|
+
vue.onUnmounted(() => {
|
|
2296
|
+
window.removeEventListener("scroll", onScroll);
|
|
2297
|
+
});
|
|
2298
|
+
return () => {
|
|
2299
|
+
return vue.h("view", {
|
|
2300
|
+
style: rootStyle.value,
|
|
2301
|
+
ref: root
|
|
2302
|
+
}, [renderFixed()]);
|
|
2303
|
+
};
|
|
2304
|
+
}
|
|
2305
|
+
});
|
|
2306
|
+
const MIN_DISTANCE$1 = 10;
|
|
2307
|
+
function getDirection$1(x, y) {
|
|
2308
|
+
if (x > y && x > MIN_DISTANCE$1) {
|
|
2190
2309
|
return "horizontal";
|
|
2191
2310
|
}
|
|
2192
|
-
if (y > x && y > MIN_DISTANCE) {
|
|
2311
|
+
if (y > x && y > MIN_DISTANCE$1) {
|
|
2193
2312
|
return "vertical";
|
|
2194
2313
|
}
|
|
2195
2314
|
return "";
|
|
2196
2315
|
}
|
|
2197
|
-
function useTouch() {
|
|
2316
|
+
function useTouch$1() {
|
|
2198
2317
|
const startX = vue.ref(0);
|
|
2199
2318
|
const startY = vue.ref(0);
|
|
2200
2319
|
const deltaX = vue.ref(0);
|
|
@@ -2223,7 +2342,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2223
2342
|
offsetX.value = Math.abs(deltaX.value);
|
|
2224
2343
|
offsetY.value = Math.abs(deltaY.value);
|
|
2225
2344
|
if (!direction.value) {
|
|
2226
|
-
direction.value = getDirection(offsetX.value, offsetY.value);
|
|
2345
|
+
direction.value = getDirection$1(offsetX.value, offsetY.value);
|
|
2227
2346
|
}
|
|
2228
2347
|
};
|
|
2229
2348
|
return {
|
|
@@ -2241,8 +2360,8 @@ var __publicField = (obj, key, value) => {
|
|
|
2241
2360
|
isHorizontal
|
|
2242
2361
|
};
|
|
2243
2362
|
}
|
|
2244
|
-
const { componentName: componentName$
|
|
2245
|
-
const _sfc_main$
|
|
2363
|
+
const { componentName: componentName$V, create: create$1c } = createComponent("swipe");
|
|
2364
|
+
const _sfc_main$1c = create$1c({
|
|
2246
2365
|
props: {
|
|
2247
2366
|
name: {
|
|
2248
2367
|
type: String,
|
|
@@ -2264,7 +2383,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2264
2383
|
emits: ["open", "close"],
|
|
2265
2384
|
setup(props, { emit }) {
|
|
2266
2385
|
const classes = vue.computed(() => {
|
|
2267
|
-
const prefixCls = componentName$
|
|
2386
|
+
const prefixCls = componentName$V;
|
|
2268
2387
|
return {
|
|
2269
2388
|
[prefixCls]: true
|
|
2270
2389
|
};
|
|
@@ -2330,7 +2449,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2330
2449
|
}
|
|
2331
2450
|
state.offset = offset;
|
|
2332
2451
|
};
|
|
2333
|
-
const touch = useTouch();
|
|
2452
|
+
const touch = useTouch$1();
|
|
2334
2453
|
const touchMethods = {
|
|
2335
2454
|
onTouchStart(event) {
|
|
2336
2455
|
if (props.disabled)
|
|
@@ -2388,16 +2507,16 @@ var __publicField = (obj, key, value) => {
|
|
|
2388
2507
|
});
|
|
2389
2508
|
}
|
|
2390
2509
|
});
|
|
2391
|
-
const _hoisted_1$
|
|
2510
|
+
const _hoisted_1$W = {
|
|
2392
2511
|
class: "nut-swipe__left",
|
|
2393
2512
|
ref: "leftRef"
|
|
2394
2513
|
};
|
|
2395
|
-
const _hoisted_2$
|
|
2396
|
-
const _hoisted_3$
|
|
2514
|
+
const _hoisted_2$M = { class: "nut-swipe__content" };
|
|
2515
|
+
const _hoisted_3$C = {
|
|
2397
2516
|
class: "nut-swipe__right",
|
|
2398
2517
|
ref: "rightRef"
|
|
2399
2518
|
};
|
|
2400
|
-
function _sfc_render$
|
|
2519
|
+
function _sfc_render$16(_ctx, _cache, $props, $setup, $data, $options) {
|
|
2401
2520
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
2402
2521
|
class: vue.normalizeClass(_ctx.classes),
|
|
2403
2522
|
style: vue.normalizeStyle(_ctx.touchStyle),
|
|
@@ -2406,20 +2525,20 @@ var __publicField = (obj, key, value) => {
|
|
|
2406
2525
|
onTouchend: _cache[2] || (_cache[2] = (...args) => _ctx.onTouchEnd && _ctx.onTouchEnd(...args)),
|
|
2407
2526
|
onTouchcancel: _cache[3] || (_cache[3] = (...args) => _ctx.onTouchEnd && _ctx.onTouchEnd(...args))
|
|
2408
2527
|
}, [
|
|
2409
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
2528
|
+
vue.createElementVNode("view", _hoisted_1$W, [
|
|
2410
2529
|
vue.renderSlot(_ctx.$slots, "left")
|
|
2411
2530
|
], 512),
|
|
2412
|
-
vue.createElementVNode("view", _hoisted_2$
|
|
2531
|
+
vue.createElementVNode("view", _hoisted_2$M, [
|
|
2413
2532
|
vue.renderSlot(_ctx.$slots, "default")
|
|
2414
2533
|
]),
|
|
2415
|
-
vue.createElementVNode("view", _hoisted_3$
|
|
2534
|
+
vue.createElementVNode("view", _hoisted_3$C, [
|
|
2416
2535
|
vue.renderSlot(_ctx.$slots, "right")
|
|
2417
2536
|
], 512)
|
|
2418
2537
|
], 38);
|
|
2419
2538
|
}
|
|
2420
|
-
var Swipe = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
2421
|
-
const { componentName: componentName$
|
|
2422
|
-
const _sfc_main$
|
|
2539
|
+
var Swipe = /* @__PURE__ */ _export_sfc(_sfc_main$1c, [["render", _sfc_render$16]]);
|
|
2540
|
+
const { componentName: componentName$U, create: create$1b } = createComponent("actionsheet");
|
|
2541
|
+
const _sfc_main$1b = create$1b({
|
|
2423
2542
|
props: __spreadProps(__spreadValues({}, popupProps), {
|
|
2424
2543
|
cancelTxt: {
|
|
2425
2544
|
type: String,
|
|
@@ -2452,12 +2571,16 @@ var __publicField = (obj, key, value) => {
|
|
|
2452
2571
|
menuItems: {
|
|
2453
2572
|
type: Array,
|
|
2454
2573
|
default: () => []
|
|
2574
|
+
},
|
|
2575
|
+
isWrapTeleport: {
|
|
2576
|
+
type: Boolean,
|
|
2577
|
+
default: true
|
|
2455
2578
|
}
|
|
2456
2579
|
}),
|
|
2457
|
-
emits: ["cancel", "choose", "update:visible"],
|
|
2580
|
+
emits: ["cancel", "close", "choose", "update:visible"],
|
|
2458
2581
|
setup(props, { emit }) {
|
|
2459
2582
|
const classes = vue.computed(() => {
|
|
2460
|
-
const prefixCls = componentName$
|
|
2583
|
+
const prefixCls = componentName$U;
|
|
2461
2584
|
return {
|
|
2462
2585
|
[prefixCls]: true
|
|
2463
2586
|
};
|
|
@@ -2488,22 +2611,22 @@ var __publicField = (obj, key, value) => {
|
|
|
2488
2611
|
};
|
|
2489
2612
|
}
|
|
2490
2613
|
});
|
|
2491
|
-
const _hoisted_1$
|
|
2492
|
-
const _hoisted_2$
|
|
2614
|
+
const _hoisted_1$V = { class: "nut-actionsheet-panel" };
|
|
2615
|
+
const _hoisted_2$L = {
|
|
2493
2616
|
key: 0,
|
|
2494
2617
|
class: "nut-actionsheet-title"
|
|
2495
2618
|
};
|
|
2496
|
-
const _hoisted_3$
|
|
2619
|
+
const _hoisted_3$B = {
|
|
2497
2620
|
key: 1,
|
|
2498
2621
|
class: "nut-actionsheet-item desc"
|
|
2499
2622
|
};
|
|
2500
|
-
const _hoisted_4$
|
|
2623
|
+
const _hoisted_4$s = {
|
|
2501
2624
|
key: 2,
|
|
2502
2625
|
class: "nut-actionsheet-menu"
|
|
2503
2626
|
};
|
|
2504
|
-
const _hoisted_5$
|
|
2505
|
-
const _hoisted_6$
|
|
2506
|
-
function _sfc_render$
|
|
2627
|
+
const _hoisted_5$j = ["onClick"];
|
|
2628
|
+
const _hoisted_6$g = { class: "subdesc" };
|
|
2629
|
+
function _sfc_render$15(_ctx, _cache, $props, $setup, $data, $options) {
|
|
2507
2630
|
const _component_nut_popup = vue.resolveComponent("nut-popup");
|
|
2508
2631
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
2509
2632
|
class: vue.normalizeClass(_ctx.classes)
|
|
@@ -2511,15 +2634,16 @@ var __publicField = (obj, key, value) => {
|
|
|
2511
2634
|
vue.createVNode(_component_nut_popup, {
|
|
2512
2635
|
"pop-class": "popclass",
|
|
2513
2636
|
visible: _ctx.visible,
|
|
2637
|
+
isWrapTeleport: _ctx.isWrapTeleport,
|
|
2514
2638
|
position: "bottom",
|
|
2515
2639
|
round: "",
|
|
2516
2640
|
onClickOverlay: _ctx.close
|
|
2517
2641
|
}, {
|
|
2518
2642
|
default: vue.withCtx(() => [
|
|
2519
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
2520
|
-
_ctx.title ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$
|
|
2521
|
-
_ctx.description ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$
|
|
2522
|
-
_ctx.menuItems.length ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_4$
|
|
2643
|
+
vue.createElementVNode("view", _hoisted_1$V, [
|
|
2644
|
+
_ctx.title ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$L, vue.toDisplayString(_ctx.title), 1)) : vue.createCommentVNode("", true),
|
|
2645
|
+
_ctx.description ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$B, vue.toDisplayString(_ctx.description), 1)) : vue.createCommentVNode("", true),
|
|
2646
|
+
_ctx.menuItems.length ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_4$s, [
|
|
2523
2647
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.menuItems, (item, index) => {
|
|
2524
2648
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
2525
2649
|
class: vue.normalizeClass(["nut-actionsheet-item", { "nut-actionsheet-item-disabled": item.disable }]),
|
|
@@ -2528,8 +2652,8 @@ var __publicField = (obj, key, value) => {
|
|
|
2528
2652
|
onClick: ($event) => _ctx.chooseItem(item, index)
|
|
2529
2653
|
}, [
|
|
2530
2654
|
vue.createTextVNode(vue.toDisplayString(item[_ctx.optionTag]), 1),
|
|
2531
|
-
vue.createElementVNode("view", _hoisted_6$
|
|
2532
|
-
], 14, _hoisted_5$
|
|
2655
|
+
vue.createElementVNode("view", _hoisted_6$g, vue.toDisplayString(item[_ctx.optionSubTag]), 1)
|
|
2656
|
+
], 14, _hoisted_5$j);
|
|
2533
2657
|
}), 128))
|
|
2534
2658
|
])) : vue.createCommentVNode("", true),
|
|
2535
2659
|
_ctx.cancelTxt ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
@@ -2540,12 +2664,12 @@ var __publicField = (obj, key, value) => {
|
|
|
2540
2664
|
])
|
|
2541
2665
|
]),
|
|
2542
2666
|
_: 1
|
|
2543
|
-
}, 8, ["visible", "onClickOverlay"])
|
|
2667
|
+
}, 8, ["visible", "isWrapTeleport", "onClickOverlay"])
|
|
2544
2668
|
], 2);
|
|
2545
2669
|
}
|
|
2546
|
-
var ActionSheet = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
2547
|
-
const { componentName: componentName$
|
|
2548
|
-
const _sfc_main$
|
|
2670
|
+
var ActionSheet = /* @__PURE__ */ _export_sfc(_sfc_main$1b, [["render", _sfc_render$15]]);
|
|
2671
|
+
const { componentName: componentName$T, create: create$1a } = createComponent("backtop");
|
|
2672
|
+
const _sfc_main$1a = create$1a({
|
|
2549
2673
|
props: {
|
|
2550
2674
|
bottom: {
|
|
2551
2675
|
type: Number,
|
|
@@ -2556,8 +2680,8 @@ var __publicField = (obj, key, value) => {
|
|
|
2556
2680
|
default: 10
|
|
2557
2681
|
},
|
|
2558
2682
|
elId: {
|
|
2559
|
-
type: String,
|
|
2560
|
-
default: ""
|
|
2683
|
+
type: [String, Element],
|
|
2684
|
+
default: "body"
|
|
2561
2685
|
},
|
|
2562
2686
|
distance: {
|
|
2563
2687
|
type: Number,
|
|
@@ -2586,7 +2710,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2586
2710
|
keepAlive: false
|
|
2587
2711
|
});
|
|
2588
2712
|
const classes = vue.computed(() => {
|
|
2589
|
-
const prefixCls = componentName$
|
|
2713
|
+
const prefixCls = componentName$T;
|
|
2590
2714
|
return {
|
|
2591
2715
|
[prefixCls]: true,
|
|
2592
2716
|
show: state.backTop
|
|
@@ -2677,7 +2801,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2677
2801
|
};
|
|
2678
2802
|
}
|
|
2679
2803
|
});
|
|
2680
|
-
function _sfc_render$
|
|
2804
|
+
function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
|
|
2681
2805
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
2682
2806
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
2683
2807
|
class: vue.normalizeClass(_ctx.classes),
|
|
@@ -2693,9 +2817,9 @@ var __publicField = (obj, key, value) => {
|
|
|
2693
2817
|
])
|
|
2694
2818
|
], 6);
|
|
2695
2819
|
}
|
|
2696
|
-
var BackTop = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
2697
|
-
const { create: create$
|
|
2698
|
-
const _sfc_main$
|
|
2820
|
+
var BackTop = /* @__PURE__ */ _export_sfc(_sfc_main$1a, [["render", _sfc_render$14]]);
|
|
2821
|
+
const { create: create$19 } = createComponent("collapse");
|
|
2822
|
+
const _sfc_main$19 = create$19({
|
|
2699
2823
|
props: {
|
|
2700
2824
|
active: {
|
|
2701
2825
|
type: [String, Number, Array]
|
|
@@ -2768,14 +2892,14 @@ var __publicField = (obj, key, value) => {
|
|
|
2768
2892
|
});
|
|
2769
2893
|
}
|
|
2770
2894
|
});
|
|
2771
|
-
function _sfc_render$
|
|
2895
|
+
function _sfc_render$13(_ctx, _cache, $props, $setup, $data, $options) {
|
|
2772
2896
|
return vue.openBlock(), vue.createElementBlock("view", null, [
|
|
2773
2897
|
vue.renderSlot(_ctx.$slots, "default")
|
|
2774
2898
|
]);
|
|
2775
2899
|
}
|
|
2776
|
-
var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
2777
|
-
const { create: create$
|
|
2778
|
-
const _sfc_main$
|
|
2900
|
+
var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main$19, [["render", _sfc_render$13]]);
|
|
2901
|
+
const { create: create$18, componentName: componentName$S } = createComponent("collapse-item");
|
|
2902
|
+
const _sfc_main$18 = create$18({
|
|
2779
2903
|
props: {
|
|
2780
2904
|
title: {
|
|
2781
2905
|
type: String,
|
|
@@ -2802,7 +2926,7 @@ var __publicField = (obj, key, value) => {
|
|
|
2802
2926
|
const collapse = vue.inject("collapseParent");
|
|
2803
2927
|
const parent = vue.reactive(collapse);
|
|
2804
2928
|
const classes = vue.computed(() => {
|
|
2805
|
-
const prefixCls = componentName$
|
|
2929
|
+
const prefixCls = componentName$S;
|
|
2806
2930
|
return {
|
|
2807
2931
|
[prefixCls]: true,
|
|
2808
2932
|
[`${prefixCls}-icon`]: parent.props.icon
|
|
@@ -2834,7 +2958,9 @@ var __publicField = (obj, key, value) => {
|
|
|
2834
2958
|
const contentRef = vue.ref(null);
|
|
2835
2959
|
const onTransitionEnd = () => {
|
|
2836
2960
|
const wrapperRefEle = document.getElementsByClassName("collapse-wrapper")[0];
|
|
2837
|
-
wrapperRefEle
|
|
2961
|
+
if (wrapperRefEle) {
|
|
2962
|
+
wrapperRefEle.style.willChange = "auto";
|
|
2963
|
+
}
|
|
2838
2964
|
};
|
|
2839
2965
|
const animation = () => {
|
|
2840
2966
|
const wrapperRefEle = wrapperRef.value;
|
|
@@ -2935,23 +3061,23 @@ var __publicField = (obj, key, value) => {
|
|
|
2935
3061
|
});
|
|
2936
3062
|
}
|
|
2937
3063
|
});
|
|
2938
|
-
const _hoisted_1$
|
|
2939
|
-
const _hoisted_2$
|
|
2940
|
-
const _hoisted_3$
|
|
2941
|
-
const _hoisted_4$
|
|
3064
|
+
const _hoisted_1$U = { class: "collapse-title" };
|
|
3065
|
+
const _hoisted_2$K = { class: "collapse-title-value" };
|
|
3066
|
+
const _hoisted_3$A = ["innerHTML"];
|
|
3067
|
+
const _hoisted_4$r = {
|
|
2942
3068
|
key: 0,
|
|
2943
3069
|
class: "subTitle"
|
|
2944
3070
|
};
|
|
2945
|
-
const _hoisted_5$
|
|
2946
|
-
const _hoisted_6$
|
|
3071
|
+
const _hoisted_5$i = ["innerHTML"];
|
|
3072
|
+
const _hoisted_6$f = {
|
|
2947
3073
|
class: "collapse-wrapper",
|
|
2948
3074
|
ref: "wrapperRef"
|
|
2949
3075
|
};
|
|
2950
|
-
const _hoisted_7$
|
|
3076
|
+
const _hoisted_7$b = {
|
|
2951
3077
|
class: "collapse-content",
|
|
2952
3078
|
ref: "contentRef"
|
|
2953
3079
|
};
|
|
2954
|
-
function _sfc_render
|
|
3080
|
+
function _sfc_render$12(_ctx, _cache, $props, $setup, $data, $options) {
|
|
2955
3081
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
2956
3082
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
2957
3083
|
class: vue.normalizeClass(_ctx.classes)
|
|
@@ -2960,9 +3086,9 @@ var __publicField = (obj, key, value) => {
|
|
|
2960
3086
|
class: vue.normalizeClass(["collapse-item", { "item-expanded": _ctx.openExpanded }, { "nut-collapse-item-disabled": _ctx.disabled }]),
|
|
2961
3087
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.toggleOpen && _ctx.toggleOpen(...args))
|
|
2962
3088
|
}, [
|
|
2963
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
3089
|
+
vue.createElementVNode("view", _hoisted_1$U, [
|
|
2964
3090
|
vue.createElementVNode("view", null, [
|
|
2965
|
-
vue.createElementVNode("view", _hoisted_2$
|
|
3091
|
+
vue.createElementVNode("view", _hoisted_2$K, [
|
|
2966
3092
|
_ctx.titleIcon ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
2967
3093
|
key: 0,
|
|
2968
3094
|
name: _ctx.titleIcon,
|
|
@@ -2974,17 +3100,17 @@ var __publicField = (obj, key, value) => {
|
|
|
2974
3100
|
key: 2,
|
|
2975
3101
|
innerHTML: _ctx.title,
|
|
2976
3102
|
class: "collapse-icon-title"
|
|
2977
|
-
}, null, 8, _hoisted_3$
|
|
3103
|
+
}, null, 8, _hoisted_3$A))
|
|
2978
3104
|
])
|
|
2979
3105
|
])
|
|
2980
3106
|
]),
|
|
2981
|
-
_ctx.$slots.sTitle ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_4$
|
|
3107
|
+
_ctx.$slots.sTitle ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_4$r, [
|
|
2982
3108
|
vue.renderSlot(_ctx.$slots, "sTitle")
|
|
2983
3109
|
])) : (vue.openBlock(), vue.createElementBlock("view", {
|
|
2984
3110
|
key: 1,
|
|
2985
3111
|
innerHTML: _ctx.subTitle,
|
|
2986
3112
|
class: "subTitle"
|
|
2987
|
-
}, null, 8, _hoisted_5$
|
|
3113
|
+
}, null, 8, _hoisted_5$i)),
|
|
2988
3114
|
_ctx.icon ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
2989
3115
|
key: 2,
|
|
2990
3116
|
name: _ctx.icon,
|
|
@@ -2994,14 +3120,14 @@ var __publicField = (obj, key, value) => {
|
|
|
2994
3120
|
style: vue.normalizeStyle(_ctx.iconStyle)
|
|
2995
3121
|
}, null, 8, ["name", "size", "color", "class", "style"])) : vue.createCommentVNode("", true)
|
|
2996
3122
|
], 2),
|
|
2997
|
-
vue.createElementVNode("view", _hoisted_6$
|
|
2998
|
-
vue.createElementVNode("view", _hoisted_7$
|
|
3123
|
+
vue.createElementVNode("view", _hoisted_6$f, [
|
|
3124
|
+
vue.createElementVNode("view", _hoisted_7$b, [
|
|
2999
3125
|
vue.renderSlot(_ctx.$slots, "default")
|
|
3000
3126
|
], 512)
|
|
3001
3127
|
], 512)
|
|
3002
3128
|
], 2);
|
|
3003
3129
|
}
|
|
3004
|
-
var CollapseItem = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
3130
|
+
var CollapseItem = /* @__PURE__ */ _export_sfc(_sfc_main$18, [["render", _sfc_render$12]]);
|
|
3005
3131
|
const _window = window;
|
|
3006
3132
|
function requestAniFrame() {
|
|
3007
3133
|
if (typeof _window !== "undefined") {
|
|
@@ -3015,8 +3141,8 @@ var __publicField = (obj, key, value) => {
|
|
|
3015
3141
|
}
|
|
3016
3142
|
}
|
|
3017
3143
|
var requestAniFrame$1 = requestAniFrame();
|
|
3018
|
-
const { componentName: componentName$
|
|
3019
|
-
const _sfc_main$
|
|
3144
|
+
const { componentName: componentName$R, create: create$17 } = createComponent("drag");
|
|
3145
|
+
const _sfc_main$17 = create$17({
|
|
3020
3146
|
props: {
|
|
3021
3147
|
attract: {
|
|
3022
3148
|
type: Boolean,
|
|
@@ -3061,7 +3187,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3061
3187
|
}
|
|
3062
3188
|
});
|
|
3063
3189
|
const classes = vue.computed(() => {
|
|
3064
|
-
const prefixCls = componentName$
|
|
3190
|
+
const prefixCls = componentName$R;
|
|
3065
3191
|
return {
|
|
3066
3192
|
[prefixCls]: true
|
|
3067
3193
|
};
|
|
@@ -3196,7 +3322,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3196
3322
|
};
|
|
3197
3323
|
}
|
|
3198
3324
|
});
|
|
3199
|
-
function _sfc_render$
|
|
3325
|
+
function _sfc_render$11(_ctx, _cache, $props, $setup, $data, $options) {
|
|
3200
3326
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
3201
3327
|
class: vue.normalizeClass(_ctx.classes),
|
|
3202
3328
|
ref: "myDrag",
|
|
@@ -3207,9 +3333,9 @@ var __publicField = (obj, key, value) => {
|
|
|
3207
3333
|
vue.renderSlot(_ctx.$slots, "default")
|
|
3208
3334
|
], 34);
|
|
3209
3335
|
}
|
|
3210
|
-
var Drag = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
3211
|
-
const { componentName: componentName$
|
|
3212
|
-
const _sfc_main$
|
|
3336
|
+
var Drag = /* @__PURE__ */ _export_sfc(_sfc_main$17, [["render", _sfc_render$11]]);
|
|
3337
|
+
const { componentName: componentName$Q, create: create$16 } = createComponent("dialog");
|
|
3338
|
+
const _sfc_main$16 = create$16({
|
|
3213
3339
|
inheritAttrs: false,
|
|
3214
3340
|
components: {
|
|
3215
3341
|
[Popup.name]: Popup,
|
|
@@ -3284,7 +3410,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3284
3410
|
});
|
|
3285
3411
|
const classes = vue.computed(() => {
|
|
3286
3412
|
return {
|
|
3287
|
-
[componentName$
|
|
3413
|
+
[componentName$Q]: true
|
|
3288
3414
|
};
|
|
3289
3415
|
});
|
|
3290
3416
|
const update = (val) => {
|
|
@@ -3314,12 +3440,12 @@ var __publicField = (obj, key, value) => {
|
|
|
3314
3440
|
};
|
|
3315
3441
|
}
|
|
3316
3442
|
});
|
|
3317
|
-
const _hoisted_1$
|
|
3443
|
+
const _hoisted_1$T = {
|
|
3318
3444
|
key: 0,
|
|
3319
3445
|
class: "nut-dialog__header"
|
|
3320
3446
|
};
|
|
3321
|
-
const _hoisted_2$
|
|
3322
|
-
function _sfc_render$
|
|
3447
|
+
const _hoisted_2$J = ["innerHTML"];
|
|
3448
|
+
function _sfc_render$10(_ctx, _cache, $props, $setup, $data, $options) {
|
|
3323
3449
|
const _component_nut_button = vue.resolveComponent("nut-button");
|
|
3324
3450
|
const _component_nut_popup = vue.resolveComponent("nut-popup");
|
|
3325
3451
|
return vue.openBlock(), vue.createBlock(_component_nut_popup, {
|
|
@@ -3336,7 +3462,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3336
3462
|
vue.createElementVNode("view", {
|
|
3337
3463
|
class: vue.normalizeClass(_ctx.classes)
|
|
3338
3464
|
}, [
|
|
3339
|
-
_ctx.title ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$
|
|
3465
|
+
_ctx.title ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$T, [
|
|
3340
3466
|
_ctx.$slots.header ? vue.renderSlot(_ctx.$slots, "header", { key: 0 }) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
3341
3467
|
vue.createTextVNode(vue.toDisplayString(_ctx.title), 1)
|
|
3342
3468
|
], 64))
|
|
@@ -3348,7 +3474,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3348
3474
|
_ctx.$slots.default ? vue.renderSlot(_ctx.$slots, "default", { key: 0 }) : (vue.openBlock(), vue.createElementBlock("view", {
|
|
3349
3475
|
key: 1,
|
|
3350
3476
|
innerHTML: _ctx.content
|
|
3351
|
-
}, null, 8, _hoisted_2$
|
|
3477
|
+
}, null, 8, _hoisted_2$J))
|
|
3352
3478
|
], 4),
|
|
3353
3479
|
!_ctx.noFooter ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
3354
3480
|
key: 1,
|
|
@@ -3388,7 +3514,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3388
3514
|
_: 3
|
|
3389
3515
|
}, 8, ["teleport", "visible", "close-on-click-overlay", "lock-scroll", "onClickOverlay", "onClickCloseIcon"]);
|
|
3390
3516
|
}
|
|
3391
|
-
var Dialog = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
3517
|
+
var Dialog = /* @__PURE__ */ _export_sfc(_sfc_main$16, [["render", _sfc_render$10]]);
|
|
3392
3518
|
class DialogOptions {
|
|
3393
3519
|
constructor() {
|
|
3394
3520
|
__publicField(this, "title", "");
|
|
@@ -3462,8 +3588,8 @@ var __publicField = (obj, key, value) => {
|
|
|
3462
3588
|
app.use(Dialog);
|
|
3463
3589
|
app.config.globalProperties.$dialog = _Dialog;
|
|
3464
3590
|
};
|
|
3465
|
-
const { componentName: componentName$
|
|
3466
|
-
const _sfc_main$
|
|
3591
|
+
const { componentName: componentName$P, create: create$15 } = createComponent("infiniteloading");
|
|
3592
|
+
const _sfc_main$15 = create$15({
|
|
3467
3593
|
props: {
|
|
3468
3594
|
hasMore: {
|
|
3469
3595
|
type: Boolean,
|
|
@@ -3525,7 +3651,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3525
3651
|
distance: 0
|
|
3526
3652
|
});
|
|
3527
3653
|
const classes = vue.computed(() => {
|
|
3528
|
-
const prefixCls = componentName$
|
|
3654
|
+
const prefixCls = componentName$P;
|
|
3529
3655
|
return {
|
|
3530
3656
|
[prefixCls]: true
|
|
3531
3657
|
};
|
|
@@ -3649,20 +3775,20 @@ var __publicField = (obj, key, value) => {
|
|
|
3649
3775
|
});
|
|
3650
3776
|
}
|
|
3651
3777
|
});
|
|
3652
|
-
const _hoisted_1$
|
|
3653
|
-
const _hoisted_2$
|
|
3654
|
-
const _hoisted_3$
|
|
3655
|
-
const _hoisted_4$
|
|
3656
|
-
const _hoisted_5$
|
|
3778
|
+
const _hoisted_1$S = { class: "top-box" };
|
|
3779
|
+
const _hoisted_2$I = { class: "top-text" };
|
|
3780
|
+
const _hoisted_3$z = { class: "nut-infinite-container" };
|
|
3781
|
+
const _hoisted_4$q = { class: "nut-infinite-bottom" };
|
|
3782
|
+
const _hoisted_5$h = {
|
|
3657
3783
|
key: 0,
|
|
3658
3784
|
class: "bottom-box"
|
|
3659
3785
|
};
|
|
3660
|
-
const _hoisted_6$
|
|
3661
|
-
const _hoisted_7$
|
|
3786
|
+
const _hoisted_6$e = { class: "bottom-text" };
|
|
3787
|
+
const _hoisted_7$a = {
|
|
3662
3788
|
key: 1,
|
|
3663
3789
|
class: "tips"
|
|
3664
3790
|
};
|
|
3665
|
-
function _sfc_render
|
|
3791
|
+
function _sfc_render$$(_ctx, _cache, $props, $setup, $data, $options) {
|
|
3666
3792
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
3667
3793
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
3668
3794
|
class: vue.normalizeClass(_ctx.classes),
|
|
@@ -3676,31 +3802,31 @@ var __publicField = (obj, key, value) => {
|
|
|
3676
3802
|
ref: "refreshTop",
|
|
3677
3803
|
style: vue.normalizeStyle(_ctx.getStyle)
|
|
3678
3804
|
}, [
|
|
3679
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
3805
|
+
vue.createElementVNode("view", _hoisted_1$S, [
|
|
3680
3806
|
vue.createVNode(_component_nut_icon, {
|
|
3681
3807
|
class: "top-img",
|
|
3682
3808
|
name: _ctx.pullIcon
|
|
3683
3809
|
}, null, 8, ["name"]),
|
|
3684
|
-
vue.createElementVNode("view", _hoisted_2$
|
|
3810
|
+
vue.createElementVNode("view", _hoisted_2$I, vue.toDisplayString(_ctx.pullTxt), 1)
|
|
3685
3811
|
])
|
|
3686
3812
|
], 4),
|
|
3687
|
-
vue.createElementVNode("view", _hoisted_3$
|
|
3813
|
+
vue.createElementVNode("view", _hoisted_3$z, [
|
|
3688
3814
|
vue.renderSlot(_ctx.$slots, "default")
|
|
3689
3815
|
]),
|
|
3690
|
-
vue.createElementVNode("view", _hoisted_4$
|
|
3691
|
-
_ctx.isInfiniting ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_5$
|
|
3816
|
+
vue.createElementVNode("view", _hoisted_4$q, [
|
|
3817
|
+
_ctx.isInfiniting ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_5$h, [
|
|
3692
3818
|
vue.createVNode(_component_nut_icon, {
|
|
3693
3819
|
class: "bottom-img",
|
|
3694
3820
|
name: _ctx.loadIcon
|
|
3695
3821
|
}, null, 8, ["name"]),
|
|
3696
|
-
vue.createElementVNode("view", _hoisted_6$
|
|
3697
|
-
])) : !_ctx.hasMore ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_7$
|
|
3822
|
+
vue.createElementVNode("view", _hoisted_6$e, vue.toDisplayString(_ctx.loadTxt), 1)
|
|
3823
|
+
])) : !_ctx.hasMore ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_7$a, vue.toDisplayString(_ctx.loadMoreTxt), 1)) : vue.createCommentVNode("", true)
|
|
3698
3824
|
])
|
|
3699
3825
|
], 34);
|
|
3700
3826
|
}
|
|
3701
|
-
var InfiniteLoading = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
3702
|
-
const { componentName: componentName$
|
|
3703
|
-
const _sfc_main$
|
|
3827
|
+
var InfiniteLoading = /* @__PURE__ */ _export_sfc(_sfc_main$15, [["render", _sfc_render$$]]);
|
|
3828
|
+
const { componentName: componentName$O, create: create$14 } = createComponent("notify");
|
|
3829
|
+
const _sfc_main$14 = create$14({
|
|
3704
3830
|
components: {
|
|
3705
3831
|
[Popup.name]: Popup
|
|
3706
3832
|
},
|
|
@@ -3770,14 +3896,14 @@ var __publicField = (obj, key, value) => {
|
|
|
3770
3896
|
return { state, hide, onAfterLeave, clickCover };
|
|
3771
3897
|
}
|
|
3772
3898
|
});
|
|
3773
|
-
function _sfc_render$
|
|
3899
|
+
function _sfc_render$_(_ctx, _cache, $props, $setup, $data, $options) {
|
|
3774
3900
|
return vue.openBlock(), vue.createBlock(vue.Transition, {
|
|
3775
3901
|
name: "toast-fade",
|
|
3776
3902
|
onAfterLeave: _ctx.onAfterLeave
|
|
3777
3903
|
}, {
|
|
3778
3904
|
default: vue.withCtx(() => [
|
|
3779
3905
|
vue.withDirectives(vue.createElementVNode("view", {
|
|
3780
|
-
class: vue.normalizeClass(["popup-top", "nut-notify", `nut-notify--${_ctx.type}`,
|
|
3906
|
+
class: vue.normalizeClass(["popup-top", "nut-notify", `nut-notify--${_ctx.type}`, [_ctx.className]]),
|
|
3781
3907
|
style: vue.normalizeStyle({ color: _ctx.color, background: _ctx.background }),
|
|
3782
3908
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.clickCover && _ctx.clickCover(...args))
|
|
3783
3909
|
}, [
|
|
@@ -3791,7 +3917,7 @@ var __publicField = (obj, key, value) => {
|
|
|
3791
3917
|
_: 3
|
|
3792
3918
|
}, 8, ["onAfterLeave"]);
|
|
3793
3919
|
}
|
|
3794
|
-
var Notify = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
3920
|
+
var Notify = /* @__PURE__ */ _export_sfc(_sfc_main$14, [["render", _sfc_render$_]]);
|
|
3795
3921
|
const defaultOptions$1 = {
|
|
3796
3922
|
type: "base",
|
|
3797
3923
|
showPopup: false,
|
|
@@ -3900,37 +4026,8 @@ var __publicField = (obj, key, value) => {
|
|
|
3900
4026
|
app.config.globalProperties.$notify = NotifyFunction;
|
|
3901
4027
|
}
|
|
3902
4028
|
};
|
|
3903
|
-
|
|
3904
|
-
|
|
3905
|
-
}
|
|
3906
|
-
const useRect = (elementRef) => {
|
|
3907
|
-
const element = vue.unref(elementRef);
|
|
3908
|
-
if (isWindow(element)) {
|
|
3909
|
-
const width = element.innerWidth;
|
|
3910
|
-
const height = element.innerHeight;
|
|
3911
|
-
return {
|
|
3912
|
-
top: 0,
|
|
3913
|
-
left: 0,
|
|
3914
|
-
right: width,
|
|
3915
|
-
bottom: height,
|
|
3916
|
-
width,
|
|
3917
|
-
height
|
|
3918
|
-
};
|
|
3919
|
-
}
|
|
3920
|
-
if (element && element.getBoundingClientRect) {
|
|
3921
|
-
return element.getBoundingClientRect();
|
|
3922
|
-
}
|
|
3923
|
-
return {
|
|
3924
|
-
top: 0,
|
|
3925
|
-
left: 0,
|
|
3926
|
-
right: 0,
|
|
3927
|
-
bottom: 0,
|
|
3928
|
-
width: 0,
|
|
3929
|
-
height: 0
|
|
3930
|
-
};
|
|
3931
|
-
};
|
|
3932
|
-
const { componentName: componentName$K, create: create$10 } = createComponent("range");
|
|
3933
|
-
const _sfc_main$10 = create$10({
|
|
4029
|
+
const { componentName: componentName$N, create: create$13 } = createComponent("range");
|
|
4030
|
+
const _sfc_main$13 = create$13({
|
|
3934
4031
|
props: {
|
|
3935
4032
|
range: {
|
|
3936
4033
|
type: Boolean,
|
|
@@ -3972,10 +4069,10 @@ var __publicField = (obj, key, value) => {
|
|
|
3972
4069
|
let currentValue;
|
|
3973
4070
|
const root = vue.ref();
|
|
3974
4071
|
const dragStatus = vue.ref();
|
|
3975
|
-
const touch = useTouch();
|
|
4072
|
+
const touch = useTouch$1();
|
|
3976
4073
|
const scope = vue.computed(() => Number(props.max) - Number(props.min));
|
|
3977
4074
|
const classes = vue.computed(() => {
|
|
3978
|
-
const prefixCls = componentName$
|
|
4075
|
+
const prefixCls = componentName$N;
|
|
3979
4076
|
return {
|
|
3980
4077
|
[prefixCls]: true,
|
|
3981
4078
|
[`${prefixCls}-disabled`]: props.disabled,
|
|
@@ -4126,28 +4223,28 @@ var __publicField = (obj, key, value) => {
|
|
|
4126
4223
|
});
|
|
4127
4224
|
}
|
|
4128
4225
|
});
|
|
4129
|
-
const _hoisted_1$
|
|
4130
|
-
const _hoisted_2$
|
|
4226
|
+
const _hoisted_1$R = { class: "nut-range-container" };
|
|
4227
|
+
const _hoisted_2$H = {
|
|
4131
4228
|
key: 0,
|
|
4132
4229
|
class: "min"
|
|
4133
4230
|
};
|
|
4134
|
-
const _hoisted_3$
|
|
4135
|
-
const _hoisted_4$
|
|
4231
|
+
const _hoisted_3$y = ["tabindex", "aria-valuemin", "aria-valuenow", "aria-valuemax", "onTouchstart"];
|
|
4232
|
+
const _hoisted_4$p = {
|
|
4136
4233
|
key: 0,
|
|
4137
4234
|
class: "number"
|
|
4138
4235
|
};
|
|
4139
|
-
const _hoisted_5$
|
|
4140
|
-
const _hoisted_6$
|
|
4236
|
+
const _hoisted_5$g = ["tabindex", "aria-valuemin", "aria-valuenow", "aria-valuemax"];
|
|
4237
|
+
const _hoisted_6$d = {
|
|
4141
4238
|
key: 0,
|
|
4142
4239
|
class: "number"
|
|
4143
4240
|
};
|
|
4144
|
-
const _hoisted_7$
|
|
4241
|
+
const _hoisted_7$9 = {
|
|
4145
4242
|
key: 1,
|
|
4146
4243
|
class: "max"
|
|
4147
4244
|
};
|
|
4148
|
-
function _sfc_render$
|
|
4149
|
-
return vue.openBlock(), vue.createElementBlock("view", _hoisted_1$
|
|
4150
|
-
!_ctx.hiddenRange ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$
|
|
4245
|
+
function _sfc_render$Z(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4246
|
+
return vue.openBlock(), vue.createElementBlock("view", _hoisted_1$R, [
|
|
4247
|
+
!_ctx.hiddenRange ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$H, vue.toDisplayString(+_ctx.min), 1)) : vue.createCommentVNode("", true),
|
|
4151
4248
|
vue.createElementVNode("view", {
|
|
4152
4249
|
ref: "root",
|
|
4153
4250
|
style: vue.normalizeStyle(_ctx.wrapperStyle),
|
|
@@ -4187,9 +4284,9 @@ var __publicField = (obj, key, value) => {
|
|
|
4187
4284
|
class: "nut-range-button",
|
|
4188
4285
|
style: vue.normalizeStyle(_ctx.buttonStyle)
|
|
4189
4286
|
}, [
|
|
4190
|
-
!_ctx.hiddenTag ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_4$
|
|
4287
|
+
!_ctx.hiddenTag ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_4$p, vue.toDisplayString(_ctx.curValue(index)), 1)) : vue.createCommentVNode("", true)
|
|
4191
4288
|
], 4))
|
|
4192
|
-
], 42, _hoisted_3$
|
|
4289
|
+
], 42, _hoisted_3$y);
|
|
4193
4290
|
}), 64)) : (vue.openBlock(), vue.createElementBlock("view", {
|
|
4194
4291
|
key: 1,
|
|
4195
4292
|
role: "slider",
|
|
@@ -4212,17 +4309,355 @@ var __publicField = (obj, key, value) => {
|
|
|
4212
4309
|
class: "nut-range-button",
|
|
4213
4310
|
style: vue.normalizeStyle(_ctx.buttonStyle)
|
|
4214
4311
|
}, [
|
|
4215
|
-
!_ctx.hiddenTag ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_6$
|
|
4312
|
+
!_ctx.hiddenTag ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_6$d, vue.toDisplayString(_ctx.curValue()), 1)) : vue.createCommentVNode("", true)
|
|
4216
4313
|
], 4))
|
|
4217
|
-
], 40, _hoisted_5$
|
|
4314
|
+
], 40, _hoisted_5$g))
|
|
4218
4315
|
], 4)
|
|
4219
4316
|
], 6),
|
|
4220
|
-
!_ctx.hiddenRange ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_7$
|
|
4317
|
+
!_ctx.hiddenRange ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_7$9, vue.toDisplayString(+_ctx.max), 1)) : vue.createCommentVNode("", true)
|
|
4221
4318
|
]);
|
|
4222
4319
|
}
|
|
4223
|
-
var Range = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
4224
|
-
const
|
|
4225
|
-
|
|
4320
|
+
var Range = /* @__PURE__ */ _export_sfc(_sfc_main$13, [["render", _sfc_render$Z]]);
|
|
4321
|
+
const MIN_DISTANCE = 10;
|
|
4322
|
+
function getDirection(x, y) {
|
|
4323
|
+
if (x > y && x > MIN_DISTANCE) {
|
|
4324
|
+
return "horizontal";
|
|
4325
|
+
}
|
|
4326
|
+
if (y > x && y > MIN_DISTANCE) {
|
|
4327
|
+
return "vertical";
|
|
4328
|
+
}
|
|
4329
|
+
return "";
|
|
4330
|
+
}
|
|
4331
|
+
function useTouch() {
|
|
4332
|
+
const startX = vue.ref(0);
|
|
4333
|
+
const startY = vue.ref(0);
|
|
4334
|
+
const deltaX = vue.ref(0);
|
|
4335
|
+
const deltaY = vue.ref(0);
|
|
4336
|
+
const offsetX = vue.ref(0);
|
|
4337
|
+
const offsetY = vue.ref(0);
|
|
4338
|
+
const direction = vue.ref("");
|
|
4339
|
+
const isVertical = () => direction.value === "vertical";
|
|
4340
|
+
const isHorizontal = () => direction.value === "horizontal";
|
|
4341
|
+
const reset = () => {
|
|
4342
|
+
deltaX.value = 0;
|
|
4343
|
+
deltaY.value = 0;
|
|
4344
|
+
offsetX.value = 0;
|
|
4345
|
+
offsetY.value = 0;
|
|
4346
|
+
direction.value = "";
|
|
4347
|
+
};
|
|
4348
|
+
const start = (event) => {
|
|
4349
|
+
reset();
|
|
4350
|
+
startX.value = event.touches[0].clientX;
|
|
4351
|
+
startY.value = event.touches[0].clientY;
|
|
4352
|
+
};
|
|
4353
|
+
const move = (event) => {
|
|
4354
|
+
const touch = event.touches[0];
|
|
4355
|
+
deltaX.value = touch.clientX - startX.value;
|
|
4356
|
+
deltaY.value = touch.clientY - startY.value;
|
|
4357
|
+
offsetX.value = Math.abs(deltaX.value);
|
|
4358
|
+
offsetY.value = Math.abs(deltaY.value);
|
|
4359
|
+
if (!direction.value) {
|
|
4360
|
+
direction.value = getDirection(offsetX.value, offsetY.value);
|
|
4361
|
+
}
|
|
4362
|
+
};
|
|
4363
|
+
return {
|
|
4364
|
+
move,
|
|
4365
|
+
start,
|
|
4366
|
+
reset,
|
|
4367
|
+
startX,
|
|
4368
|
+
startY,
|
|
4369
|
+
deltaX,
|
|
4370
|
+
deltaY,
|
|
4371
|
+
offsetX,
|
|
4372
|
+
offsetY,
|
|
4373
|
+
direction,
|
|
4374
|
+
isVertical,
|
|
4375
|
+
isHorizontal
|
|
4376
|
+
};
|
|
4377
|
+
}
|
|
4378
|
+
function preventDefault(event, isStopPropagation) {
|
|
4379
|
+
if (typeof event.cancelable !== "boolean" || event.cancelable) {
|
|
4380
|
+
event.preventDefault();
|
|
4381
|
+
}
|
|
4382
|
+
if (isStopPropagation)
|
|
4383
|
+
event.stopPropagation();
|
|
4384
|
+
}
|
|
4385
|
+
const { componentName: componentName$M, create: create$12 } = createComponent("pullrefresh");
|
|
4386
|
+
const _sfc_main$12 = create$12({
|
|
4387
|
+
props: {
|
|
4388
|
+
useWindow: {
|
|
4389
|
+
type: Boolean,
|
|
4390
|
+
default: true
|
|
4391
|
+
},
|
|
4392
|
+
containerId: {
|
|
4393
|
+
type: String,
|
|
4394
|
+
default: ""
|
|
4395
|
+
},
|
|
4396
|
+
disabled: {
|
|
4397
|
+
type: Boolean,
|
|
4398
|
+
default: false
|
|
4399
|
+
},
|
|
4400
|
+
direction: {
|
|
4401
|
+
type: String,
|
|
4402
|
+
default: "vertical"
|
|
4403
|
+
},
|
|
4404
|
+
pullingText: {
|
|
4405
|
+
type: Object,
|
|
4406
|
+
default: {
|
|
4407
|
+
top: "\u4E0B\u62C9\u5237\u65B0",
|
|
4408
|
+
bottom: "\u4E0A\u62C9\u52A0\u8F7D",
|
|
4409
|
+
left: "\u5DE6\u6ED1\u5237\u65B0",
|
|
4410
|
+
right: "\u53F3\u6ED1\u52A0\u8F7D"
|
|
4411
|
+
}
|
|
4412
|
+
},
|
|
4413
|
+
loosingText: {
|
|
4414
|
+
type: Object,
|
|
4415
|
+
default: {
|
|
4416
|
+
top: "\u677E\u624B\u91CA\u653E\u5237\u65B0",
|
|
4417
|
+
bottom: "\u677E\u624B\u91CA\u653E\u5237\u65B0",
|
|
4418
|
+
left: "\u91CA\u653E\u5237\u65B0",
|
|
4419
|
+
right: "\u52A0\u8F7D\u66F4\u591A"
|
|
4420
|
+
}
|
|
4421
|
+
},
|
|
4422
|
+
loadingText: {
|
|
4423
|
+
type: Object,
|
|
4424
|
+
default: {
|
|
4425
|
+
top: "\u52A0\u8F7D\u4E2D...",
|
|
4426
|
+
bottom: "\u52A0\u8F7D\u4E2D...",
|
|
4427
|
+
left: "\u52A0\u8F7D\u4E2D...",
|
|
4428
|
+
right: "\u52A0\u8F7D\u4E2D..."
|
|
4429
|
+
}
|
|
4430
|
+
}
|
|
4431
|
+
},
|
|
4432
|
+
emits: ["refresh", "downRefresh"],
|
|
4433
|
+
setup(props, { emit }) {
|
|
4434
|
+
const { containerId, useWindow, direction, disabled } = vue.toRefs(props);
|
|
4435
|
+
const reachTop = vue.ref(false);
|
|
4436
|
+
const reachBottom = vue.ref(false);
|
|
4437
|
+
const reachLeft = vue.ref(false);
|
|
4438
|
+
const reachRight = vue.ref(false);
|
|
4439
|
+
const state = vue.reactive({
|
|
4440
|
+
status: "normal",
|
|
4441
|
+
distance: 0,
|
|
4442
|
+
duration: 0
|
|
4443
|
+
});
|
|
4444
|
+
let scrollEl = document.documentElement || document.body;
|
|
4445
|
+
const scroller = vue.ref(null);
|
|
4446
|
+
const touch = useTouch();
|
|
4447
|
+
const getStyle = vue.computed(() => {
|
|
4448
|
+
let style = {};
|
|
4449
|
+
const { deltaY, deltaX } = touch;
|
|
4450
|
+
if (direction.value == "vertical" && (reachTop.value && deltaY.value > 0 || reachBottom.value && deltaY.value < 0) && touch.isVertical()) {
|
|
4451
|
+
style = {
|
|
4452
|
+
transitionDuration: `${state.duration}ms`,
|
|
4453
|
+
transform: state.distance ? `translate3d(0,${state.distance}px, 0)` : `translate3d(0,0,0)`
|
|
4454
|
+
};
|
|
4455
|
+
}
|
|
4456
|
+
if (direction.value == "horizontal" && (reachLeft.value && deltaX.value > 0 || reachRight.value && deltaX.value < 0) && touch.isHorizontal()) {
|
|
4457
|
+
style = {
|
|
4458
|
+
transitionDuration: `${state.duration}ms`,
|
|
4459
|
+
transform: state.distance ? `translate3d(${state.distance}px, 0,0)` : `translate3d(0,0,0)`
|
|
4460
|
+
};
|
|
4461
|
+
}
|
|
4462
|
+
return style;
|
|
4463
|
+
});
|
|
4464
|
+
const getBottomStyle = vue.computed(() => {
|
|
4465
|
+
let style = {};
|
|
4466
|
+
if (direction.value == "vertical" && reachBottom.value && touch.deltaY.value < 0 && touch.isVertical()) {
|
|
4467
|
+
const dis = Math.abs(state.distance) < 50 ? -state.distance : 50;
|
|
4468
|
+
style = {
|
|
4469
|
+
height: dis + "px"
|
|
4470
|
+
};
|
|
4471
|
+
}
|
|
4472
|
+
if (direction.value == "horizontal" && reachRight.value && touch.deltaX.value < 0 && touch.isVertical()) {
|
|
4473
|
+
const dis = Math.abs(state.distance) < 50 ? -state.distance : 50;
|
|
4474
|
+
style = {
|
|
4475
|
+
width: dis + "px"
|
|
4476
|
+
};
|
|
4477
|
+
}
|
|
4478
|
+
return style;
|
|
4479
|
+
});
|
|
4480
|
+
const refreshTopTem = vue.computed(() => {
|
|
4481
|
+
const { status, distance } = state;
|
|
4482
|
+
const tag = direction.value == "vertical" ? "top" : "left";
|
|
4483
|
+
if (status == "loading" && (reachTop.value || reachLeft.value) && distance > 0) {
|
|
4484
|
+
return props.loadingText[tag];
|
|
4485
|
+
}
|
|
4486
|
+
if (status == "pulling" && (reachTop.value || reachLeft.value) && distance > 0) {
|
|
4487
|
+
return props.pullingText[tag];
|
|
4488
|
+
}
|
|
4489
|
+
if (status == "loosing" && (reachTop.value || reachLeft.value) && distance > 0) {
|
|
4490
|
+
return props.loosingText[tag];
|
|
4491
|
+
}
|
|
4492
|
+
return "";
|
|
4493
|
+
});
|
|
4494
|
+
const refreshBottomTem = vue.computed(() => {
|
|
4495
|
+
const { status, distance } = state;
|
|
4496
|
+
const tag = direction.value == "vertical" ? "bottom" : "right";
|
|
4497
|
+
if (status == "loading" && (reachBottom.value || reachRight.value) && distance < 0) {
|
|
4498
|
+
return props.loadingText[tag];
|
|
4499
|
+
}
|
|
4500
|
+
if (status == "pulling" && (reachBottom.value || reachRight.value) && distance < 0) {
|
|
4501
|
+
return props.pullingText[tag];
|
|
4502
|
+
}
|
|
4503
|
+
if (status == "loosing" && (reachBottom.value || reachRight.value) && distance < 0) {
|
|
4504
|
+
return props.loosingText[tag];
|
|
4505
|
+
}
|
|
4506
|
+
return "";
|
|
4507
|
+
});
|
|
4508
|
+
const isTouchable = () => state.status !== "loading" && !disabled.value;
|
|
4509
|
+
const setStatus = (distance, isLoading) => {
|
|
4510
|
+
state.distance = distance;
|
|
4511
|
+
if (isLoading) {
|
|
4512
|
+
state.status = "loading";
|
|
4513
|
+
} else if (distance === 0) {
|
|
4514
|
+
state.status = "normal";
|
|
4515
|
+
} else if (Math.abs(distance) < 50) {
|
|
4516
|
+
state.status = "pulling";
|
|
4517
|
+
} else {
|
|
4518
|
+
state.status = "loosing";
|
|
4519
|
+
}
|
|
4520
|
+
};
|
|
4521
|
+
const getParentElement = (el) => {
|
|
4522
|
+
if (containerId.value != "") {
|
|
4523
|
+
return document.querySelector(`#${containerId.value}`);
|
|
4524
|
+
}
|
|
4525
|
+
return el && el.parentNode;
|
|
4526
|
+
};
|
|
4527
|
+
vue.onMounted(() => {
|
|
4528
|
+
const parentElement = getParentElement(scroller);
|
|
4529
|
+
let scrollElCopy = document.documentElement || document.body;
|
|
4530
|
+
if (useWindow.value === false) {
|
|
4531
|
+
scrollElCopy = parentElement;
|
|
4532
|
+
}
|
|
4533
|
+
scrollEl = scrollElCopy;
|
|
4534
|
+
});
|
|
4535
|
+
const ease = (distance) => {
|
|
4536
|
+
const headHeight = 50;
|
|
4537
|
+
if (distance > headHeight) {
|
|
4538
|
+
if (distance < headHeight * 2) {
|
|
4539
|
+
distance = headHeight + (distance - headHeight) / 2;
|
|
4540
|
+
} else {
|
|
4541
|
+
distance = headHeight * 1.5 + (distance - headHeight * 2) / 4;
|
|
4542
|
+
}
|
|
4543
|
+
}
|
|
4544
|
+
return Math.round(distance);
|
|
4545
|
+
};
|
|
4546
|
+
const refreshDone = () => {
|
|
4547
|
+
setStatus(0);
|
|
4548
|
+
};
|
|
4549
|
+
const touchStart = (event) => {
|
|
4550
|
+
if (isTouchable()) {
|
|
4551
|
+
if (direction.value == "vertical") {
|
|
4552
|
+
const top = "scrollTop" in scrollEl ? scrollEl.scrollTop : 0;
|
|
4553
|
+
reachTop.value = Math.max(top, 0) == 0 ? true : false;
|
|
4554
|
+
const { scrollHeight, clientHeight, scrollTop } = scrollEl;
|
|
4555
|
+
reachBottom.value = clientHeight + scrollTop == scrollHeight ? true : false;
|
|
4556
|
+
if (reachTop.value || reachBottom.value) {
|
|
4557
|
+
state.duration = 0;
|
|
4558
|
+
touch.start(event);
|
|
4559
|
+
}
|
|
4560
|
+
} else {
|
|
4561
|
+
const { scrollWidth, clientWidth, scrollLeft } = scrollEl;
|
|
4562
|
+
const left = "scrollLeft" in scrollEl ? scrollEl.scrollLeft : 0;
|
|
4563
|
+
reachLeft.value = Math.max(left, 0) == 0 ? true : false;
|
|
4564
|
+
reachRight.value = clientWidth + scrollLeft == scrollWidth ? true : false;
|
|
4565
|
+
if (reachLeft.value || reachRight.value) {
|
|
4566
|
+
state.duration = 0;
|
|
4567
|
+
touch.start(event);
|
|
4568
|
+
}
|
|
4569
|
+
}
|
|
4570
|
+
} else {
|
|
4571
|
+
preventDefault(event);
|
|
4572
|
+
}
|
|
4573
|
+
};
|
|
4574
|
+
const touchMove = (event) => {
|
|
4575
|
+
if (isTouchable()) {
|
|
4576
|
+
const { deltaY, deltaX } = touch;
|
|
4577
|
+
touch.move(event);
|
|
4578
|
+
if (direction.value == "vertical" && (reachBottom.value && deltaY.value < 0 || reachTop.value && deltaY.value >= 0) && touch.isVertical()) {
|
|
4579
|
+
preventDefault(event);
|
|
4580
|
+
setStatus(ease(deltaY.value));
|
|
4581
|
+
}
|
|
4582
|
+
if (direction.value == "horizontal" && (reachLeft.value && deltaX.value >= 0 || reachRight.value && deltaX.value < 0) && touch.isHorizontal()) {
|
|
4583
|
+
preventDefault(event);
|
|
4584
|
+
setStatus(ease(deltaX.value));
|
|
4585
|
+
}
|
|
4586
|
+
} else {
|
|
4587
|
+
preventDefault(event);
|
|
4588
|
+
}
|
|
4589
|
+
};
|
|
4590
|
+
const touchEnd = () => {
|
|
4591
|
+
if (isTouchable()) {
|
|
4592
|
+
const { deltaY, deltaX } = touch;
|
|
4593
|
+
if (state.status === "loosing") {
|
|
4594
|
+
let dis = 0;
|
|
4595
|
+
if (direction.value == "vertical" && reachTop.value && deltaY.value > 0) {
|
|
4596
|
+
dis = 50;
|
|
4597
|
+
emit("downRefresh", refreshDone);
|
|
4598
|
+
}
|
|
4599
|
+
if (direction.value == "vertical" && reachBottom.value && deltaY.value < 0) {
|
|
4600
|
+
dis = -50;
|
|
4601
|
+
emit("refresh", refreshDone);
|
|
4602
|
+
}
|
|
4603
|
+
if (direction.value == "horizontal" && reachLeft.value && deltaX.value > 0) {
|
|
4604
|
+
dis = 50;
|
|
4605
|
+
emit("downRefresh", refreshDone);
|
|
4606
|
+
}
|
|
4607
|
+
if (direction.value == "horizontal" && reachRight.value && deltaX.value < 0) {
|
|
4608
|
+
dis = -50;
|
|
4609
|
+
emit("refresh", refreshDone);
|
|
4610
|
+
}
|
|
4611
|
+
setStatus(dis, true);
|
|
4612
|
+
} else {
|
|
4613
|
+
setStatus(0);
|
|
4614
|
+
}
|
|
4615
|
+
}
|
|
4616
|
+
};
|
|
4617
|
+
return __spreadValues({
|
|
4618
|
+
scroller,
|
|
4619
|
+
touchStart,
|
|
4620
|
+
touchMove,
|
|
4621
|
+
touchEnd,
|
|
4622
|
+
getStyle,
|
|
4623
|
+
reachBottom,
|
|
4624
|
+
reachTop,
|
|
4625
|
+
reachRight,
|
|
4626
|
+
reachLeft,
|
|
4627
|
+
getBottomStyle,
|
|
4628
|
+
refreshTopTem,
|
|
4629
|
+
refreshBottomTem
|
|
4630
|
+
}, vue.toRefs(state));
|
|
4631
|
+
}
|
|
4632
|
+
});
|
|
4633
|
+
const _hoisted_1$Q = {
|
|
4634
|
+
class: "pullrefresh-content",
|
|
4635
|
+
ref: "pull"
|
|
4636
|
+
};
|
|
4637
|
+
function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4638
|
+
return vue.openBlock(), vue.createElementBlock("view", {
|
|
4639
|
+
class: "nut-pullrefresh",
|
|
4640
|
+
ref: "scroller",
|
|
4641
|
+
style: vue.normalizeStyle(_ctx.getStyle),
|
|
4642
|
+
onTouchstart: _cache[0] || (_cache[0] = (...args) => _ctx.touchStart && _ctx.touchStart(...args)),
|
|
4643
|
+
onTouchmove: _cache[1] || (_cache[1] = (...args) => _ctx.touchMove && _ctx.touchMove(...args)),
|
|
4644
|
+
onTouchend: _cache[2] || (_cache[2] = (...args) => _ctx.touchEnd && _ctx.touchEnd(...args))
|
|
4645
|
+
}, [
|
|
4646
|
+
vue.createElementVNode("view", {
|
|
4647
|
+
class: vue.normalizeClass(["pullrefresh-top", _ctx.direction == "horizontal" ? "pullrefresh-top-h" : "pullrefresh-top-v"])
|
|
4648
|
+
}, vue.toDisplayString(_ctx.refreshTopTem), 3),
|
|
4649
|
+
vue.createElementVNode("view", _hoisted_1$Q, [
|
|
4650
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
4651
|
+
], 512),
|
|
4652
|
+
vue.createElementVNode("view", {
|
|
4653
|
+
class: vue.normalizeClass(["pullrefresh-bottom", _ctx.direction == "horizontal" ? "pullrefresh-bottom-h" : "pullrefresh-bottom-v"]),
|
|
4654
|
+
style: vue.normalizeStyle(_ctx.getBottomStyle)
|
|
4655
|
+
}, vue.toDisplayString(_ctx.refreshBottomTem), 7)
|
|
4656
|
+
], 36);
|
|
4657
|
+
}
|
|
4658
|
+
var PullRefresh = /* @__PURE__ */ _export_sfc(_sfc_main$12, [["render", _sfc_render$Y]]);
|
|
4659
|
+
const { create: create$11, componentName: componentName$L } = createComponent("steps");
|
|
4660
|
+
const _sfc_main$11 = create$11({
|
|
4226
4661
|
props: {
|
|
4227
4662
|
direction: {
|
|
4228
4663
|
type: String,
|
|
@@ -4242,7 +4677,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4242
4677
|
children: []
|
|
4243
4678
|
});
|
|
4244
4679
|
const classes = vue.computed(() => {
|
|
4245
|
-
const prefixCls = componentName$
|
|
4680
|
+
const prefixCls = componentName$L;
|
|
4246
4681
|
return {
|
|
4247
4682
|
[prefixCls]: true,
|
|
4248
4683
|
[`${prefixCls}-${props.direction}`]: true,
|
|
@@ -4265,8 +4700,8 @@ var __publicField = (obj, key, value) => {
|
|
|
4265
4700
|
};
|
|
4266
4701
|
}
|
|
4267
4702
|
});
|
|
4268
|
-
const { create: create$
|
|
4269
|
-
const _sfc_main$
|
|
4703
|
+
const { create: create$10, componentName: componentName$K } = createComponent("step");
|
|
4704
|
+
const _sfc_main$10 = create$10({
|
|
4270
4705
|
props: {
|
|
4271
4706
|
title: {
|
|
4272
4707
|
type: String,
|
|
@@ -4307,7 +4742,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4307
4742
|
return getCurrentStatus();
|
|
4308
4743
|
});
|
|
4309
4744
|
const classes = vue.computed(() => {
|
|
4310
|
-
const prefixCls = componentName$
|
|
4745
|
+
const prefixCls = componentName$K;
|
|
4311
4746
|
return {
|
|
4312
4747
|
[prefixCls]: true,
|
|
4313
4748
|
[`${prefixCls}-${status.value}`]: true
|
|
@@ -4319,22 +4754,22 @@ var __publicField = (obj, key, value) => {
|
|
|
4319
4754
|
});
|
|
4320
4755
|
}
|
|
4321
4756
|
});
|
|
4322
|
-
const _hoisted_1$
|
|
4323
|
-
const _hoisted_2$
|
|
4324
|
-
const _hoisted_3$
|
|
4757
|
+
const _hoisted_1$P = { class: "nut-step-head" };
|
|
4758
|
+
const _hoisted_2$G = /* @__PURE__ */ vue.createElementVNode("view", { class: "nut-step-line" }, null, -1);
|
|
4759
|
+
const _hoisted_3$x = {
|
|
4325
4760
|
key: 2,
|
|
4326
4761
|
class: "nut-step-inner"
|
|
4327
4762
|
};
|
|
4328
|
-
const _hoisted_4$
|
|
4329
|
-
const _hoisted_5$
|
|
4330
|
-
const _hoisted_6$
|
|
4331
|
-
function _sfc_render$
|
|
4763
|
+
const _hoisted_4$o = { class: "nut-step-main" };
|
|
4764
|
+
const _hoisted_5$f = { class: "nut-step-title" };
|
|
4765
|
+
const _hoisted_6$c = ["innerHTML"];
|
|
4766
|
+
function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4332
4767
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
4333
4768
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
4334
4769
|
class: vue.normalizeClass(_ctx.classes)
|
|
4335
4770
|
}, [
|
|
4336
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
4337
|
-
_hoisted_2$
|
|
4771
|
+
vue.createElementVNode("view", _hoisted_1$P, [
|
|
4772
|
+
_hoisted_2$G,
|
|
4338
4773
|
vue.createElementVNode("view", {
|
|
4339
4774
|
class: vue.normalizeClass(["nut-step-icon", [!_ctx.dot ? _ctx.icon ? "is-icon" : "is-text" : ""]])
|
|
4340
4775
|
}, [
|
|
@@ -4344,22 +4779,22 @@ var __publicField = (obj, key, value) => {
|
|
|
4344
4779
|
color: _ctx.iconColor,
|
|
4345
4780
|
name: _ctx.icon,
|
|
4346
4781
|
size: _ctx.size
|
|
4347
|
-
}, null, 8, ["color", "name", "size"])) : _ctx.dot ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [], 64)) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$
|
|
4782
|
+
}, null, 8, ["color", "name", "size"])) : _ctx.dot ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [], 64)) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$x, vue.toDisplayString(_ctx.index), 1))
|
|
4348
4783
|
], 2)
|
|
4349
4784
|
]),
|
|
4350
|
-
vue.createElementVNode("view", _hoisted_4$
|
|
4351
|
-
vue.createElementVNode("view", _hoisted_5$
|
|
4785
|
+
vue.createElementVNode("view", _hoisted_4$o, [
|
|
4786
|
+
vue.createElementVNode("view", _hoisted_5$f, vue.toDisplayString(_ctx.title), 1),
|
|
4352
4787
|
_ctx.content ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
4353
4788
|
key: 0,
|
|
4354
4789
|
class: "nut-step-content",
|
|
4355
4790
|
innerHTML: _ctx.content
|
|
4356
|
-
}, null, 8, _hoisted_6$
|
|
4791
|
+
}, null, 8, _hoisted_6$c)) : vue.createCommentVNode("", true)
|
|
4357
4792
|
])
|
|
4358
4793
|
], 2);
|
|
4359
4794
|
}
|
|
4360
|
-
var Step = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
4361
|
-
const { componentName: componentName$
|
|
4362
|
-
const _sfc_main
|
|
4795
|
+
var Step = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["render", _sfc_render$X]]);
|
|
4796
|
+
const { componentName: componentName$J, create: create$$ } = createComponent("switch");
|
|
4797
|
+
const _sfc_main$$ = create$$({
|
|
4363
4798
|
props: {
|
|
4364
4799
|
modelValue: {
|
|
4365
4800
|
type: [String, Number, Boolean],
|
|
@@ -4410,11 +4845,11 @@ var __publicField = (obj, key, value) => {
|
|
|
4410
4845
|
default: ""
|
|
4411
4846
|
}
|
|
4412
4847
|
},
|
|
4413
|
-
emits: ["change", "update:modelValue"],
|
|
4848
|
+
emits: ["change", "update:modelValue", "update:loading"],
|
|
4414
4849
|
setup(props, { emit }) {
|
|
4415
4850
|
const isActive = vue.computed(() => props.modelValue === props.activeValue);
|
|
4416
4851
|
const classes = vue.computed(() => {
|
|
4417
|
-
const prefixCls = componentName$
|
|
4852
|
+
const prefixCls = componentName$J;
|
|
4418
4853
|
return {
|
|
4419
4854
|
[prefixCls]: true,
|
|
4420
4855
|
[isActive.value ? "switch-open" : "switch-close"]: true,
|
|
@@ -4442,15 +4877,15 @@ var __publicField = (obj, key, value) => {
|
|
|
4442
4877
|
};
|
|
4443
4878
|
}
|
|
4444
4879
|
});
|
|
4445
|
-
const _hoisted_1$
|
|
4446
|
-
function _sfc_render$
|
|
4880
|
+
const _hoisted_1$O = { class: "switch-button" };
|
|
4881
|
+
function _sfc_render$W(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4447
4882
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
4448
4883
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
4449
4884
|
class: vue.normalizeClass(_ctx.classes),
|
|
4450
4885
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.onClick && _ctx.onClick(...args)),
|
|
4451
4886
|
style: vue.normalizeStyle(_ctx.style)
|
|
4452
4887
|
}, [
|
|
4453
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
4888
|
+
vue.createElementVNode("view", _hoisted_1$O, [
|
|
4454
4889
|
_ctx.loading ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
4455
4890
|
key: 0,
|
|
4456
4891
|
name: _ctx.name,
|
|
@@ -4468,11 +4903,11 @@ var __publicField = (obj, key, value) => {
|
|
|
4468
4903
|
])
|
|
4469
4904
|
], 6);
|
|
4470
4905
|
}
|
|
4471
|
-
var Switch = /* @__PURE__ */ _export_sfc(_sfc_main
|
|
4472
|
-
const { create: create$
|
|
4473
|
-
const _sfc_main$
|
|
4906
|
+
var Switch = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["render", _sfc_render$W]]);
|
|
4907
|
+
const { create: create$_ } = createComponent("toast");
|
|
4908
|
+
const _sfc_main$_ = create$_({
|
|
4474
4909
|
components: {
|
|
4475
|
-
[_sfc_main$
|
|
4910
|
+
[_sfc_main$1s.name]: _sfc_main$1s
|
|
4476
4911
|
},
|
|
4477
4912
|
props: {
|
|
4478
4913
|
id: String,
|
|
@@ -4495,6 +4930,10 @@ var __publicField = (obj, key, value) => {
|
|
|
4495
4930
|
type: [String, Number],
|
|
4496
4931
|
default: "base"
|
|
4497
4932
|
},
|
|
4933
|
+
iconSize: {
|
|
4934
|
+
type: String,
|
|
4935
|
+
default: "20"
|
|
4936
|
+
},
|
|
4498
4937
|
icon: String,
|
|
4499
4938
|
textAlignCenter: {
|
|
4500
4939
|
type: Boolean,
|
|
@@ -4506,7 +4945,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4506
4945
|
},
|
|
4507
4946
|
bgColor: {
|
|
4508
4947
|
type: String,
|
|
4509
|
-
default: "
|
|
4948
|
+
default: ""
|
|
4510
4949
|
},
|
|
4511
4950
|
onClose: Function,
|
|
4512
4951
|
unmount: Function,
|
|
@@ -4516,7 +4955,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4516
4955
|
},
|
|
4517
4956
|
coverColor: {
|
|
4518
4957
|
type: String,
|
|
4519
|
-
default: "
|
|
4958
|
+
default: ""
|
|
4520
4959
|
},
|
|
4521
4960
|
title: {
|
|
4522
4961
|
type: String,
|
|
@@ -4527,7 +4966,8 @@ var __publicField = (obj, key, value) => {
|
|
|
4527
4966
|
default: false
|
|
4528
4967
|
}
|
|
4529
4968
|
},
|
|
4530
|
-
|
|
4969
|
+
emits: ["close"],
|
|
4970
|
+
setup(props, { emit }) {
|
|
4531
4971
|
let timer;
|
|
4532
4972
|
const state = vue.reactive({
|
|
4533
4973
|
mounted: false
|
|
@@ -4555,6 +4995,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4555
4995
|
const clickCover = () => {
|
|
4556
4996
|
if (props.closeOnClickOverlay) {
|
|
4557
4997
|
hide();
|
|
4998
|
+
emit("close");
|
|
4558
4999
|
}
|
|
4559
5000
|
};
|
|
4560
5001
|
if (props.duration) {
|
|
@@ -4598,16 +5039,16 @@ var __publicField = (obj, key, value) => {
|
|
|
4598
5039
|
};
|
|
4599
5040
|
}
|
|
4600
5041
|
});
|
|
4601
|
-
const _hoisted_1$
|
|
5042
|
+
const _hoisted_1$N = {
|
|
4602
5043
|
key: 0,
|
|
4603
5044
|
class: "nut-toast-icon-wrapper"
|
|
4604
5045
|
};
|
|
4605
|
-
const _hoisted_2$
|
|
5046
|
+
const _hoisted_2$F = {
|
|
4606
5047
|
key: 1,
|
|
4607
5048
|
class: "nut-toast-title"
|
|
4608
5049
|
};
|
|
4609
|
-
const _hoisted_3$
|
|
4610
|
-
function _sfc_render$
|
|
5050
|
+
const _hoisted_3$w = ["innerHTML"];
|
|
5051
|
+
function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4611
5052
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
4612
5053
|
return vue.openBlock(), vue.createBlock(vue.Transition, {
|
|
4613
5054
|
name: "toast-fade",
|
|
@@ -4629,18 +5070,18 @@ var __publicField = (obj, key, value) => {
|
|
|
4629
5070
|
"background-color": _ctx.bgColor
|
|
4630
5071
|
})
|
|
4631
5072
|
}, [
|
|
4632
|
-
_ctx.hasIcon ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$
|
|
5073
|
+
_ctx.hasIcon ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$N, [
|
|
4633
5074
|
vue.createVNode(_component_nut_icon, {
|
|
4634
|
-
size:
|
|
5075
|
+
size: _ctx.iconSize,
|
|
4635
5076
|
color: "#ffffff",
|
|
4636
5077
|
name: _ctx.icon
|
|
4637
|
-
}, null, 8, ["name"])
|
|
5078
|
+
}, null, 8, ["size", "name"])
|
|
4638
5079
|
])) : vue.createCommentVNode("", true),
|
|
4639
|
-
_ctx.title ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$
|
|
5080
|
+
_ctx.title ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$F, vue.toDisplayString(_ctx.title), 1)) : vue.createCommentVNode("", true),
|
|
4640
5081
|
vue.createElementVNode("view", {
|
|
4641
5082
|
class: "nut-toast-text",
|
|
4642
5083
|
innerHTML: _ctx.msg
|
|
4643
|
-
}, null, 8, _hoisted_3$
|
|
5084
|
+
}, null, 8, _hoisted_3$w)
|
|
4644
5085
|
], 4)
|
|
4645
5086
|
], 6), [
|
|
4646
5087
|
[vue.vShow, _ctx.state.mounted]
|
|
@@ -4649,7 +5090,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4649
5090
|
_: 1
|
|
4650
5091
|
}, 8, ["onAfterLeave"]);
|
|
4651
5092
|
}
|
|
4652
|
-
var Toast = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
5093
|
+
var Toast = /* @__PURE__ */ _export_sfc(_sfc_main$_, [["render", _sfc_render$V]]);
|
|
4653
5094
|
const defaultOptions = {
|
|
4654
5095
|
msg: "",
|
|
4655
5096
|
id: "",
|
|
@@ -4660,14 +5101,15 @@ var __publicField = (obj, key, value) => {
|
|
|
4660
5101
|
customClass: "",
|
|
4661
5102
|
bottom: "30px",
|
|
4662
5103
|
size: "base",
|
|
5104
|
+
iconSize: "20",
|
|
4663
5105
|
icon: null,
|
|
4664
5106
|
textAlignCenter: true,
|
|
4665
5107
|
loadingRotate: true,
|
|
4666
|
-
bgColor: "
|
|
5108
|
+
bgColor: "",
|
|
4667
5109
|
onClose: null,
|
|
4668
5110
|
unmount: null,
|
|
4669
5111
|
cover: false,
|
|
4670
|
-
coverColor: "
|
|
5112
|
+
coverColor: "",
|
|
4671
5113
|
closeOnClickOverlay: false
|
|
4672
5114
|
};
|
|
4673
5115
|
let idsMap = [];
|
|
@@ -4766,8 +5208,8 @@ var __publicField = (obj, key, value) => {
|
|
|
4766
5208
|
app.config.globalProperties.$toast = ToastFunction;
|
|
4767
5209
|
}
|
|
4768
5210
|
};
|
|
4769
|
-
const { create: create$
|
|
4770
|
-
const _sfc_main$
|
|
5211
|
+
const { create: create$Z } = createComponent("progress");
|
|
5212
|
+
const _sfc_main$Z = create$Z({
|
|
4771
5213
|
props: {
|
|
4772
5214
|
percentage: {
|
|
4773
5215
|
type: [Number, String],
|
|
@@ -4809,11 +5251,16 @@ var __publicField = (obj, key, value) => {
|
|
|
4809
5251
|
iconColor: {
|
|
4810
5252
|
type: String,
|
|
4811
5253
|
default: "#439422"
|
|
5254
|
+
},
|
|
5255
|
+
isShowPercentage: {
|
|
5256
|
+
type: Boolean,
|
|
5257
|
+
default: true
|
|
4812
5258
|
}
|
|
4813
5259
|
},
|
|
4814
5260
|
setup(props, { emit }) {
|
|
4815
5261
|
const height = vue.ref(props.strokeWidth + "px");
|
|
4816
5262
|
const progressOuter = vue.ref();
|
|
5263
|
+
const insideText = vue.ref();
|
|
4817
5264
|
const left = vue.ref();
|
|
4818
5265
|
const bgStyle = vue.computed(() => {
|
|
4819
5266
|
return {
|
|
@@ -4826,32 +5273,39 @@ var __publicField = (obj, key, value) => {
|
|
|
4826
5273
|
color: props.textColor || ""
|
|
4827
5274
|
};
|
|
4828
5275
|
});
|
|
5276
|
+
const slideLeft = (values) => {
|
|
5277
|
+
if (props.textInside) {
|
|
5278
|
+
let offsetWidth = progressOuter.value.offsetWidth;
|
|
5279
|
+
let percentageWidth = progressOuter.value.offsetWidth * Number(values) * 0.01;
|
|
5280
|
+
let insideTextWidth = insideText.value.offsetWidth;
|
|
5281
|
+
left.value = percentageWidth - 5 + "px";
|
|
5282
|
+
if (offsetWidth == percentageWidth) {
|
|
5283
|
+
left.value = percentageWidth - insideTextWidth + "px";
|
|
5284
|
+
}
|
|
5285
|
+
}
|
|
5286
|
+
};
|
|
4829
5287
|
vue.watch(() => props.percentage, (values) => {
|
|
4830
|
-
|
|
4831
|
-
console.log("values", values);
|
|
4832
|
-
left.value = progressOuter.value.offsetWidth * Number(values) * 0.01 - 5 + "px";
|
|
5288
|
+
slideLeft(values);
|
|
4833
5289
|
});
|
|
4834
5290
|
vue.onMounted(() => {
|
|
4835
|
-
|
|
5291
|
+
slideLeft(props.percentage);
|
|
4836
5292
|
});
|
|
4837
5293
|
return {
|
|
4838
5294
|
height,
|
|
4839
5295
|
bgStyle,
|
|
4840
5296
|
textStyle,
|
|
4841
5297
|
progressOuter,
|
|
5298
|
+
insideText,
|
|
4842
5299
|
left
|
|
4843
5300
|
};
|
|
4844
5301
|
}
|
|
4845
5302
|
});
|
|
4846
|
-
const _hoisted_1$
|
|
4847
|
-
function _sfc_render$
|
|
5303
|
+
const _hoisted_1$M = { class: "nut-progress" };
|
|
5304
|
+
function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4848
5305
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
4849
|
-
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$
|
|
5306
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$M, [
|
|
4850
5307
|
vue.createElementVNode("div", {
|
|
4851
|
-
class: vue.normalizeClass(["nut-progress-outer", [
|
|
4852
|
-
_ctx.showText && !_ctx.textInside ? "nut-progress-outer-part" : "",
|
|
4853
|
-
_ctx.size ? "nut-progress-" + _ctx.size : ""
|
|
4854
|
-
]]),
|
|
5308
|
+
class: vue.normalizeClass(["nut-progress-outer", [_ctx.showText && !_ctx.textInside ? "nut-progress-outer-part" : "", _ctx.size ? "nut-progress-" + _ctx.size : ""]]),
|
|
4855
5309
|
ref: "progressOuter",
|
|
4856
5310
|
style: vue.normalizeStyle({ height: _ctx.height })
|
|
4857
5311
|
}, [
|
|
@@ -4862,11 +5316,12 @@ var __publicField = (obj, key, value) => {
|
|
|
4862
5316
|
_ctx.showText && _ctx.textInside ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
4863
5317
|
key: 0,
|
|
4864
5318
|
class: "nut-progress-text nut-progress-insidetext",
|
|
5319
|
+
ref: "insideText",
|
|
4865
5320
|
style: vue.normalizeStyle({ lineHeight: _ctx.height, left: _ctx.left })
|
|
4866
5321
|
}, [
|
|
4867
5322
|
vue.createElementVNode("span", {
|
|
4868
5323
|
style: vue.normalizeStyle(_ctx.textStyle)
|
|
4869
|
-
}, vue.toDisplayString(_ctx.percentage) + "%", 5)
|
|
5324
|
+
}, vue.toDisplayString(_ctx.percentage) + vue.toDisplayString(_ctx.isShowPercentage ? "%" : ""), 5)
|
|
4870
5325
|
], 4)) : vue.createCommentVNode("", true)
|
|
4871
5326
|
], 6)
|
|
4872
5327
|
], 6),
|
|
@@ -4878,7 +5333,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4878
5333
|
_ctx.status == "active" || _ctx.status == "" ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
4879
5334
|
key: 0,
|
|
4880
5335
|
style: vue.normalizeStyle(_ctx.textStyle)
|
|
4881
|
-
}, vue.toDisplayString(_ctx.percentage) + "%", 5)) : _ctx.status == "icon" ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
5336
|
+
}, vue.toDisplayString(_ctx.percentage) + vue.toDisplayString(_ctx.isShowPercentage ? "%" : ""), 5)) : _ctx.status == "icon" ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
4882
5337
|
key: 1,
|
|
4883
5338
|
size: "16px",
|
|
4884
5339
|
name: _ctx.iconName,
|
|
@@ -4887,9 +5342,9 @@ var __publicField = (obj, key, value) => {
|
|
|
4887
5342
|
], 4)) : vue.createCommentVNode("", true)
|
|
4888
5343
|
]);
|
|
4889
5344
|
}
|
|
4890
|
-
var Progress = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
4891
|
-
const { componentName: componentName$
|
|
4892
|
-
const _sfc_main$
|
|
5345
|
+
var Progress = /* @__PURE__ */ _export_sfc(_sfc_main$Z, [["render", _sfc_render$U]]);
|
|
5346
|
+
const { componentName: componentName$I, create: create$Y } = createComponent("circleprogress");
|
|
5347
|
+
const _sfc_main$Y = create$Y({
|
|
4893
5348
|
props: {
|
|
4894
5349
|
progress: {
|
|
4895
5350
|
type: [Number, String],
|
|
@@ -4911,7 +5366,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4911
5366
|
},
|
|
4912
5367
|
setup(props, { emit }) {
|
|
4913
5368
|
const classes = vue.computed(() => {
|
|
4914
|
-
const prefixCls = componentName$
|
|
5369
|
+
const prefixCls = componentName$I;
|
|
4915
5370
|
return {
|
|
4916
5371
|
[prefixCls]: true
|
|
4917
5372
|
};
|
|
@@ -4945,11 +5400,11 @@ var __publicField = (obj, key, value) => {
|
|
|
4945
5400
|
};
|
|
4946
5401
|
}
|
|
4947
5402
|
});
|
|
4948
|
-
const _hoisted_1$
|
|
4949
|
-
const _hoisted_2$
|
|
4950
|
-
const _hoisted_3$
|
|
4951
|
-
const _hoisted_4$
|
|
4952
|
-
function _sfc_render$
|
|
5403
|
+
const _hoisted_1$L = ["height", "width"];
|
|
5404
|
+
const _hoisted_2$E = ["r", "cx", "cy", "stroke", "stroke-width"];
|
|
5405
|
+
const _hoisted_3$v = ["r", "cx", "cy", "stroke", "stroke-dasharray", "stroke-width", "transform"];
|
|
5406
|
+
const _hoisted_4$n = { class: "nut-circleprogress-content" };
|
|
5407
|
+
function _sfc_render$T(_ctx, _cache, $props, $setup, $data, $options) {
|
|
4953
5408
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
4954
5409
|
class: vue.normalizeClass(_ctx.classes),
|
|
4955
5410
|
style: vue.normalizeStyle({ height: _ctx.option.size + "px", width: _ctx.option.size + "px" })
|
|
@@ -4966,7 +5421,7 @@ var __publicField = (obj, key, value) => {
|
|
|
4966
5421
|
stroke: _ctx.option.backColor,
|
|
4967
5422
|
"stroke-width": _ctx.option.strokeOutWidth,
|
|
4968
5423
|
fill: "none"
|
|
4969
|
-
}, null, 8, _hoisted_2$
|
|
5424
|
+
}, null, 8, _hoisted_2$E),
|
|
4970
5425
|
vue.createElementVNode("circle", {
|
|
4971
5426
|
r: _ctx.option.radius,
|
|
4972
5427
|
cx: _ctx.option.cx,
|
|
@@ -4978,18 +5433,18 @@ var __publicField = (obj, key, value) => {
|
|
|
4978
5433
|
transform: _ctx.option.startPosition,
|
|
4979
5434
|
"stroke-linecap": "round",
|
|
4980
5435
|
style: { "transition": "stroke-dasharray 0.6s ease 0s, stroke 0.6s ease 0s" }
|
|
4981
|
-
}, null, 8, _hoisted_3$
|
|
4982
|
-
], 8, _hoisted_1$
|
|
4983
|
-
vue.createElementVNode("div", _hoisted_4$
|
|
5436
|
+
}, null, 8, _hoisted_3$v)
|
|
5437
|
+
], 8, _hoisted_1$L)),
|
|
5438
|
+
vue.createElementVNode("div", _hoisted_4$n, [
|
|
4984
5439
|
!_ctx.isAuto ? vue.renderSlot(_ctx.$slots, "default", { key: 0 }, () => [
|
|
4985
5440
|
vue.createTextVNode(vue.toDisplayString(_ctx.progress) + "%", 1)
|
|
4986
5441
|
]) : vue.renderSlot(_ctx.$slots, "default", { key: 1 })
|
|
4987
5442
|
])
|
|
4988
5443
|
], 6);
|
|
4989
5444
|
}
|
|
4990
|
-
var CircleProgress = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
4991
|
-
const { componentName: componentName$
|
|
4992
|
-
const _sfc_main$
|
|
5445
|
+
var CircleProgress = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["render", _sfc_render$T]]);
|
|
5446
|
+
const { componentName: componentName$H, create: create$X } = createComponent("noticebar");
|
|
5447
|
+
const _sfc_main$X = create$X({
|
|
4993
5448
|
props: {
|
|
4994
5449
|
direction: {
|
|
4995
5450
|
type: String,
|
|
@@ -5026,6 +5481,7 @@ var __publicField = (obj, key, value) => {
|
|
|
5026
5481
|
default: false
|
|
5027
5482
|
},
|
|
5028
5483
|
leftIcon: { type: String, default: "" },
|
|
5484
|
+
rightIcon: { type: String, default: "" },
|
|
5029
5485
|
color: {
|
|
5030
5486
|
type: String,
|
|
5031
5487
|
default: ""
|
|
@@ -5040,7 +5496,7 @@ var __publicField = (obj, key, value) => {
|
|
|
5040
5496
|
},
|
|
5041
5497
|
scrollable: {
|
|
5042
5498
|
type: Boolean,
|
|
5043
|
-
default:
|
|
5499
|
+
default: null
|
|
5044
5500
|
},
|
|
5045
5501
|
speed: {
|
|
5046
5502
|
type: Number,
|
|
@@ -5050,12 +5506,12 @@ var __publicField = (obj, key, value) => {
|
|
|
5050
5506
|
components: {
|
|
5051
5507
|
ScrollItem: function(props) {
|
|
5052
5508
|
props.item.props.style = props.style;
|
|
5509
|
+
props.item.key = props.key;
|
|
5053
5510
|
return vue.h(props.item);
|
|
5054
5511
|
}
|
|
5055
5512
|
},
|
|
5056
5513
|
emits: ["click", "close"],
|
|
5057
5514
|
setup(props, { emit, slots }) {
|
|
5058
|
-
console.log("componentName", componentName$F);
|
|
5059
5515
|
const wrap = vue.ref(null);
|
|
5060
5516
|
const content = vue.ref(null);
|
|
5061
5517
|
const state = vue.reactive({
|
|
@@ -5069,14 +5525,22 @@ var __publicField = (obj, key, value) => {
|
|
|
5069
5525
|
scrollList: [],
|
|
5070
5526
|
distance: 0,
|
|
5071
5527
|
timer: null,
|
|
5072
|
-
keepAlive: false
|
|
5528
|
+
keepAlive: false,
|
|
5529
|
+
isCanScroll: null
|
|
5073
5530
|
});
|
|
5074
5531
|
const classes = vue.computed(() => {
|
|
5075
|
-
const prefixCls = componentName$
|
|
5532
|
+
const prefixCls = componentName$H;
|
|
5076
5533
|
return {
|
|
5077
5534
|
[prefixCls]: true
|
|
5078
5535
|
};
|
|
5079
5536
|
});
|
|
5537
|
+
const isEllipsis = vue.computed(() => {
|
|
5538
|
+
if (state.isCanScroll == null) {
|
|
5539
|
+
return false;
|
|
5540
|
+
} else {
|
|
5541
|
+
return !state.isCanScroll && !props.wrapable;
|
|
5542
|
+
}
|
|
5543
|
+
});
|
|
5080
5544
|
const iconShow = vue.computed(() => {
|
|
5081
5545
|
if (props.leftIcon == "close") {
|
|
5082
5546
|
return false;
|
|
@@ -5095,9 +5559,9 @@ var __publicField = (obj, key, value) => {
|
|
|
5095
5559
|
});
|
|
5096
5560
|
const contentStyle = vue.computed(() => {
|
|
5097
5561
|
return {
|
|
5098
|
-
paddingLeft: state.firstRound ? 0 : state.wrapWidth + "px",
|
|
5099
5562
|
animationDelay: (state.firstRound ? props.delay : 0) + "s",
|
|
5100
|
-
animationDuration: state.duration + "s"
|
|
5563
|
+
animationDuration: state.duration + "s",
|
|
5564
|
+
transform: `translateX(${state.firstRound ? 0 : state.wrapWidth + "px"})`
|
|
5101
5565
|
};
|
|
5102
5566
|
});
|
|
5103
5567
|
const iconBg = vue.computed(() => {
|
|
@@ -5140,7 +5604,8 @@ var __publicField = (obj, key, value) => {
|
|
|
5140
5604
|
}
|
|
5141
5605
|
const wrapWidth = wrap.value.getBoundingClientRect().width;
|
|
5142
5606
|
const offsetWidth = content.value.getBoundingClientRect().width;
|
|
5143
|
-
|
|
5607
|
+
state.isCanScroll = props.scrollable == null ? offsetWidth > wrapWidth : props.scrollable;
|
|
5608
|
+
if (state.isCanScroll) {
|
|
5144
5609
|
state.wrapWidth = wrapWidth;
|
|
5145
5610
|
state.offsetWidth = offsetWidth;
|
|
5146
5611
|
state.duration = offsetWidth / props.speed;
|
|
@@ -5154,7 +5619,9 @@ var __publicField = (obj, key, value) => {
|
|
|
5154
5619
|
emit("click", event);
|
|
5155
5620
|
};
|
|
5156
5621
|
const onClickIcon = (event) => {
|
|
5157
|
-
|
|
5622
|
+
if (props.closeMode) {
|
|
5623
|
+
state.showNoticeBar = !props.closeMode;
|
|
5624
|
+
}
|
|
5158
5625
|
emit("close", event);
|
|
5159
5626
|
};
|
|
5160
5627
|
const onAnimationEnd = () => {
|
|
@@ -5201,14 +5668,12 @@ var __publicField = (obj, key, value) => {
|
|
|
5201
5668
|
emit("close", state.scrollList[0]);
|
|
5202
5669
|
};
|
|
5203
5670
|
vue.onMounted(() => {
|
|
5204
|
-
console.log(props.direction);
|
|
5205
5671
|
if (props.direction == "vertical") {
|
|
5206
5672
|
if (slots.default) {
|
|
5207
5673
|
state.scrollList = [].concat(slots.default()[0].children);
|
|
5208
5674
|
} else {
|
|
5209
5675
|
state.scrollList = [].concat(props.list);
|
|
5210
5676
|
}
|
|
5211
|
-
console.log(state.scrollList);
|
|
5212
5677
|
setTimeout(() => {
|
|
5213
5678
|
props.complexAm ? startRoll() : startRollEasy();
|
|
5214
5679
|
}, props.standTime);
|
|
@@ -5229,6 +5694,7 @@ var __publicField = (obj, key, value) => {
|
|
|
5229
5694
|
clearInterval(state.timer);
|
|
5230
5695
|
});
|
|
5231
5696
|
return __spreadProps(__spreadValues(__spreadValues({}, vue.toRefs(props)), vue.toRefs(state)), {
|
|
5697
|
+
isEllipsis,
|
|
5232
5698
|
classes,
|
|
5233
5699
|
iconShow,
|
|
5234
5700
|
barStyle,
|
|
@@ -5246,12 +5712,12 @@ var __publicField = (obj, key, value) => {
|
|
|
5246
5712
|
});
|
|
5247
5713
|
}
|
|
5248
5714
|
});
|
|
5249
|
-
const _hoisted_1$
|
|
5715
|
+
const _hoisted_1$K = {
|
|
5250
5716
|
ref: "wrap",
|
|
5251
5717
|
class: "wrap"
|
|
5252
5718
|
};
|
|
5253
|
-
const _hoisted_2$
|
|
5254
|
-
function _sfc_render$
|
|
5719
|
+
const _hoisted_2$D = ["onClick"];
|
|
5720
|
+
function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
|
|
5255
5721
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
5256
5722
|
const _component_ScrollItem = vue.resolveComponent("ScrollItem");
|
|
5257
5723
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
@@ -5268,17 +5734,19 @@ var __publicField = (obj, key, value) => {
|
|
|
5268
5734
|
class: "left-icon",
|
|
5269
5735
|
style: vue.normalizeStyle({ "background-image": `url(${_ctx.iconBg})` })
|
|
5270
5736
|
}, [
|
|
5271
|
-
|
|
5272
|
-
|
|
5273
|
-
|
|
5274
|
-
|
|
5275
|
-
|
|
5276
|
-
|
|
5737
|
+
vue.renderSlot(_ctx.$slots, "left-icon", {}, () => [
|
|
5738
|
+
!_ctx.iconBg ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
5739
|
+
key: 0,
|
|
5740
|
+
name: "notice",
|
|
5741
|
+
size: "16",
|
|
5742
|
+
color: _ctx.color
|
|
5743
|
+
}, null, 8, ["color"])) : vue.createCommentVNode("", true)
|
|
5744
|
+
])
|
|
5277
5745
|
], 4)) : vue.createCommentVNode("", true),
|
|
5278
|
-
vue.createElementVNode("view", _hoisted_1$
|
|
5746
|
+
vue.createElementVNode("view", _hoisted_1$K, [
|
|
5279
5747
|
vue.createElementVNode("view", {
|
|
5280
5748
|
ref: "content",
|
|
5281
|
-
class: vue.normalizeClass(["content", [_ctx.animationClass, { "nut-ellipsis":
|
|
5749
|
+
class: vue.normalizeClass(["content", [_ctx.animationClass, { "nut-ellipsis": _ctx.isEllipsis }]]),
|
|
5282
5750
|
style: vue.normalizeStyle(_ctx.contentStyle),
|
|
5283
5751
|
onAnimationend: _cache[0] || (_cache[0] = (...args) => _ctx.onAnimationEnd && _ctx.onAnimationEnd(...args)),
|
|
5284
5752
|
onWebkitAnimationEnd: _cache[1] || (_cache[1] = (...args) => _ctx.onAnimationEnd && _ctx.onAnimationEnd(...args))
|
|
@@ -5288,15 +5756,17 @@ var __publicField = (obj, key, value) => {
|
|
|
5288
5756
|
])
|
|
5289
5757
|
], 38)
|
|
5290
5758
|
], 512),
|
|
5291
|
-
_ctx.closeMode ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
5759
|
+
_ctx.closeMode || _ctx.rightIcon ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
5292
5760
|
key: 1,
|
|
5293
5761
|
class: "right-icon",
|
|
5294
5762
|
onClick: _cache[2] || (_cache[2] = vue.withModifiers((...args) => _ctx.onClickIcon && _ctx.onClickIcon(...args), ["stop"]))
|
|
5295
5763
|
}, [
|
|
5296
|
-
vue.
|
|
5297
|
-
|
|
5298
|
-
|
|
5299
|
-
|
|
5764
|
+
vue.renderSlot(_ctx.$slots, "right-icon", {}, () => [
|
|
5765
|
+
vue.createVNode(_component_nut_icon, {
|
|
5766
|
+
name: _ctx.rightIcon ? _ctx.rightIcon : "close",
|
|
5767
|
+
color: _ctx.color
|
|
5768
|
+
}, null, 8, ["name", "color"])
|
|
5769
|
+
])
|
|
5300
5770
|
])) : vue.createCommentVNode("", true)
|
|
5301
5771
|
], 6)), [
|
|
5302
5772
|
[vue.vShow, _ctx.showNoticeBar]
|
|
@@ -5329,7 +5799,7 @@ var __publicField = (obj, key, value) => {
|
|
|
5329
5799
|
key: index,
|
|
5330
5800
|
style: vue.normalizeStyle({ height: _ctx.height }),
|
|
5331
5801
|
onClick: ($event) => _ctx.go(item)
|
|
5332
|
-
}, vue.toDisplayString(item), 13, _hoisted_2$
|
|
5802
|
+
}, vue.toDisplayString(item), 13, _hoisted_2$D);
|
|
5333
5803
|
}), 128))
|
|
5334
5804
|
], 4)),
|
|
5335
5805
|
vue.createElementVNode("view", {
|
|
@@ -5346,9 +5816,9 @@ var __publicField = (obj, key, value) => {
|
|
|
5346
5816
|
], 4)) : vue.createCommentVNode("", true)
|
|
5347
5817
|
], 2);
|
|
5348
5818
|
}
|
|
5349
|
-
var NoticeBar = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
5350
|
-
const { create: create$
|
|
5351
|
-
const _sfc_main$
|
|
5819
|
+
var NoticeBar = /* @__PURE__ */ _export_sfc(_sfc_main$X, [["render", _sfc_render$S]]);
|
|
5820
|
+
const { create: create$W } = createComponent("searchbar");
|
|
5821
|
+
const _sfc_main$W = create$W({
|
|
5352
5822
|
props: {
|
|
5353
5823
|
modelValue: {
|
|
5354
5824
|
type: [String, Number],
|
|
@@ -5439,41 +5909,41 @@ var __publicField = (obj, key, value) => {
|
|
|
5439
5909
|
});
|
|
5440
5910
|
}
|
|
5441
5911
|
});
|
|
5442
|
-
const _hoisted_1$
|
|
5912
|
+
const _hoisted_1$J = {
|
|
5443
5913
|
key: 0,
|
|
5444
5914
|
class: "nut-searchbar__search-icon nut-searchbar__left-search-icon"
|
|
5445
5915
|
};
|
|
5446
|
-
const _hoisted_2$
|
|
5916
|
+
const _hoisted_2$C = {
|
|
5447
5917
|
key: 0,
|
|
5448
5918
|
class: "nut-searchbar__search-icon nut-searchbar__iptleft-search-icon"
|
|
5449
5919
|
};
|
|
5450
|
-
const _hoisted_3$
|
|
5451
|
-
const _hoisted_4$
|
|
5452
|
-
const _hoisted_5$
|
|
5920
|
+
const _hoisted_3$u = { class: "nut-searchbar__input-inner" };
|
|
5921
|
+
const _hoisted_4$m = ["type", "maxlength", "placeholder", "value"];
|
|
5922
|
+
const _hoisted_5$e = {
|
|
5453
5923
|
key: 1,
|
|
5454
5924
|
class: "nut-searchbar__search-icon nut-searchbar__iptright-sarch-icon"
|
|
5455
5925
|
};
|
|
5456
|
-
const _hoisted_6$
|
|
5926
|
+
const _hoisted_6$b = {
|
|
5457
5927
|
key: 1,
|
|
5458
5928
|
class: "nut-searchbar__search-icon nut-searchbar__right-search-icon"
|
|
5459
5929
|
};
|
|
5460
|
-
function _sfc_render$
|
|
5930
|
+
function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
|
|
5461
5931
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
5462
5932
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
5463
5933
|
class: "nut-searchbar",
|
|
5464
5934
|
style: vue.normalizeStyle(_ctx.searchbarStyle)
|
|
5465
5935
|
}, [
|
|
5466
|
-
_ctx.$slots.leftout ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$
|
|
5936
|
+
_ctx.$slots.leftout ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$J, [
|
|
5467
5937
|
vue.renderSlot(_ctx.$slots, "leftout")
|
|
5468
5938
|
])) : vue.createCommentVNode("", true),
|
|
5469
5939
|
vue.createElementVNode("view", {
|
|
5470
5940
|
class: "nut-searchbar__search-input",
|
|
5471
5941
|
style: vue.normalizeStyle(_ctx.inputSearchbarStyle)
|
|
5472
5942
|
}, [
|
|
5473
|
-
_ctx.$slots.leftin ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$
|
|
5943
|
+
_ctx.$slots.leftin ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$C, [
|
|
5474
5944
|
vue.renderSlot(_ctx.$slots, "leftin")
|
|
5475
5945
|
])) : vue.createCommentVNode("", true),
|
|
5476
|
-
vue.createElementVNode("view", _hoisted_3$
|
|
5946
|
+
vue.createElementVNode("view", _hoisted_3$u, [
|
|
5477
5947
|
vue.createElementVNode("form", {
|
|
5478
5948
|
action: "#",
|
|
5479
5949
|
onSubmit: _cache[3] || (_cache[3] = vue.withModifiers((...args) => _ctx.handleSubmit && _ctx.handleSubmit(...args), ["prevent"]))
|
|
@@ -5487,7 +5957,7 @@ var __publicField = (obj, key, value) => {
|
|
|
5487
5957
|
onInput: _cache[0] || (_cache[0] = (...args) => _ctx.valueChange && _ctx.valueChange(...args)),
|
|
5488
5958
|
onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.valueFocus && _ctx.valueFocus(...args)),
|
|
5489
5959
|
onBlur: _cache[2] || (_cache[2] = (...args) => _ctx.valueBlur && _ctx.valueBlur(...args))
|
|
5490
|
-
}, null, 40, _hoisted_4$
|
|
5960
|
+
}, null, 40, _hoisted_4$m)
|
|
5491
5961
|
], 32),
|
|
5492
5962
|
_ctx.clearable ? vue.withDirectives((vue.openBlock(), vue.createElementBlock("view", {
|
|
5493
5963
|
key: 0,
|
|
@@ -5503,23 +5973,23 @@ var __publicField = (obj, key, value) => {
|
|
|
5503
5973
|
[vue.vShow, _ctx.modelValue.length > 0]
|
|
5504
5974
|
]) : vue.createCommentVNode("", true)
|
|
5505
5975
|
]),
|
|
5506
|
-
_ctx.$slots.rightin ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_5$
|
|
5976
|
+
_ctx.$slots.rightin ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_5$e, [
|
|
5507
5977
|
vue.renderSlot(_ctx.$slots, "rightin")
|
|
5508
5978
|
])) : vue.createCommentVNode("", true)
|
|
5509
5979
|
], 4),
|
|
5510
|
-
_ctx.$slots.rightout ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_6$
|
|
5980
|
+
_ctx.$slots.rightout ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_6$b, [
|
|
5511
5981
|
vue.renderSlot(_ctx.$slots, "rightout")
|
|
5512
5982
|
])) : vue.createCommentVNode("", true)
|
|
5513
5983
|
], 4);
|
|
5514
5984
|
}
|
|
5515
|
-
var SearchBar = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
5516
|
-
const { componentName: componentName$
|
|
5985
|
+
var SearchBar = /* @__PURE__ */ _export_sfc(_sfc_main$W, [["render", _sfc_render$R]]);
|
|
5986
|
+
const { componentName: componentName$G, create: create$V } = createComponent("empty");
|
|
5517
5987
|
const defaultStatus = {
|
|
5518
5988
|
empty: "https://static-ftcms.jd.com/p/files/61a9e3183985005b3958672b.png",
|
|
5519
5989
|
error: "https://ftcms.jd.com/p/files/61a9e33ee7dcdbcc0ce62736.png",
|
|
5520
5990
|
network: "https://static-ftcms.jd.com/p/files/61a9e31de7dcdbcc0ce62734.png"
|
|
5521
5991
|
};
|
|
5522
|
-
const _sfc_main$
|
|
5992
|
+
const _sfc_main$V = create$V({
|
|
5523
5993
|
props: {
|
|
5524
5994
|
image: {
|
|
5525
5995
|
type: String,
|
|
@@ -5553,14 +6023,14 @@ var __publicField = (obj, key, value) => {
|
|
|
5553
6023
|
};
|
|
5554
6024
|
}
|
|
5555
6025
|
});
|
|
5556
|
-
const _hoisted_1$
|
|
5557
|
-
const _hoisted_2$
|
|
5558
|
-
const _hoisted_3$
|
|
6026
|
+
const _hoisted_1$I = { class: "nut-empty" };
|
|
6027
|
+
const _hoisted_2$B = ["src"];
|
|
6028
|
+
const _hoisted_3$t = {
|
|
5559
6029
|
key: 1,
|
|
5560
6030
|
class: "nut-empty-description"
|
|
5561
6031
|
};
|
|
5562
|
-
function _sfc_render$
|
|
5563
|
-
return vue.openBlock(), vue.createElementBlock("view", _hoisted_1$
|
|
6032
|
+
function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
|
|
6033
|
+
return vue.openBlock(), vue.createElementBlock("view", _hoisted_1$I, [
|
|
5564
6034
|
vue.createElementVNode("view", {
|
|
5565
6035
|
class: "nut-empty-image",
|
|
5566
6036
|
style: vue.normalizeStyle(_ctx.imgStyle)
|
|
@@ -5570,41 +6040,385 @@ var __publicField = (obj, key, value) => {
|
|
|
5570
6040
|
key: 0,
|
|
5571
6041
|
class: "img",
|
|
5572
6042
|
src: _ctx.imageUrl
|
|
5573
|
-
}, null, 8, _hoisted_2$
|
|
6043
|
+
}, null, 8, _hoisted_2$B)) : vue.createCommentVNode("", true)
|
|
5574
6044
|
], 64))
|
|
5575
6045
|
], 4),
|
|
5576
|
-
_ctx.$slots.description ? vue.renderSlot(_ctx.$slots, "description", { key: 0 }) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$
|
|
6046
|
+
_ctx.$slots.description ? vue.renderSlot(_ctx.$slots, "description", { key: 0 }) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$t, vue.toDisplayString(_ctx.description), 1)),
|
|
5577
6047
|
_ctx.$slots.default ? vue.renderSlot(_ctx.$slots, "default", { key: 2 }) : vue.createCommentVNode("", true)
|
|
5578
6048
|
]);
|
|
5579
6049
|
}
|
|
5580
|
-
var Empty = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
6050
|
+
var Empty = /* @__PURE__ */ _export_sfc(_sfc_main$V, [["render", _sfc_render$Q]]);
|
|
6051
|
+
const { componentName: componentName$F, create: create$U } = createComponent("audio");
|
|
6052
|
+
const _sfc_main$U = create$U({
|
|
6053
|
+
props: {
|
|
6054
|
+
url: {
|
|
6055
|
+
type: String,
|
|
6056
|
+
default() {
|
|
6057
|
+
return "";
|
|
6058
|
+
}
|
|
6059
|
+
},
|
|
6060
|
+
muted: {
|
|
6061
|
+
type: Boolean,
|
|
6062
|
+
default() {
|
|
6063
|
+
return false;
|
|
6064
|
+
}
|
|
6065
|
+
},
|
|
6066
|
+
autoplay: {
|
|
6067
|
+
type: Boolean,
|
|
6068
|
+
default() {
|
|
6069
|
+
return false;
|
|
6070
|
+
}
|
|
6071
|
+
},
|
|
6072
|
+
loop: {
|
|
6073
|
+
type: Boolean,
|
|
6074
|
+
default() {
|
|
6075
|
+
return false;
|
|
6076
|
+
}
|
|
6077
|
+
},
|
|
6078
|
+
preload: {
|
|
6079
|
+
type: String,
|
|
6080
|
+
default() {
|
|
6081
|
+
return "auto";
|
|
6082
|
+
}
|
|
6083
|
+
},
|
|
6084
|
+
second: {
|
|
6085
|
+
type: Number,
|
|
6086
|
+
default() {
|
|
6087
|
+
return 0;
|
|
6088
|
+
}
|
|
6089
|
+
},
|
|
6090
|
+
type: {
|
|
6091
|
+
type: String,
|
|
6092
|
+
default() {
|
|
6093
|
+
return "progress";
|
|
6094
|
+
}
|
|
6095
|
+
}
|
|
6096
|
+
},
|
|
6097
|
+
components: {},
|
|
6098
|
+
emits: ["fastBack", "play", "forward", "ended", "changeProgress", "mute"],
|
|
6099
|
+
setup(props, { emit }) {
|
|
6100
|
+
const audioRef = vue.ref(null);
|
|
6101
|
+
const audioData = vue.reactive({
|
|
6102
|
+
currentTime: 0,
|
|
6103
|
+
currentDuration: "00:00:00",
|
|
6104
|
+
percent: 0,
|
|
6105
|
+
duration: "00:00:00",
|
|
6106
|
+
second: 0,
|
|
6107
|
+
hanMuted: props.muted,
|
|
6108
|
+
playing: props.autoplay
|
|
6109
|
+
});
|
|
6110
|
+
vue.onMounted(() => {
|
|
6111
|
+
var arr = ["webkitVisibilityState", "visibilitychange"];
|
|
6112
|
+
try {
|
|
6113
|
+
for (let i = 0; i < arr.length; i++) {
|
|
6114
|
+
document.addEventListener(arr[i], () => {
|
|
6115
|
+
if (document.hidden) {
|
|
6116
|
+
audioRef.value.pause();
|
|
6117
|
+
} else {
|
|
6118
|
+
if (audioData.playing) {
|
|
6119
|
+
setTimeout(() => {
|
|
6120
|
+
audioRef.value.play();
|
|
6121
|
+
}, 200);
|
|
6122
|
+
}
|
|
6123
|
+
}
|
|
6124
|
+
});
|
|
6125
|
+
}
|
|
6126
|
+
} catch (e) {
|
|
6127
|
+
console.log(e.message);
|
|
6128
|
+
}
|
|
6129
|
+
setTimeout(() => {
|
|
6130
|
+
if (props.autoplay) {
|
|
6131
|
+
if (audioRef.value && audioRef.value.paused) {
|
|
6132
|
+
audioRef.value.play();
|
|
6133
|
+
}
|
|
6134
|
+
}
|
|
6135
|
+
audioData.second = audioRef.value.duration;
|
|
6136
|
+
audioData.duration = formatSeconds(audioRef.value.duration);
|
|
6137
|
+
}, 500);
|
|
6138
|
+
});
|
|
6139
|
+
const onTimeupdate = (e) => {
|
|
6140
|
+
audioData.currentTime = parseInt(e.target.currentTime);
|
|
6141
|
+
};
|
|
6142
|
+
const fastBack = () => {
|
|
6143
|
+
audioData.currentTime--;
|
|
6144
|
+
audioRef.value.currentTime = audioData.currentTime;
|
|
6145
|
+
emit("fastBack", audioData.currentTime);
|
|
6146
|
+
};
|
|
6147
|
+
const changeStatus = () => {
|
|
6148
|
+
if (audioData.playing) {
|
|
6149
|
+
audioRef.value.pause();
|
|
6150
|
+
audioData.handPlaying = false;
|
|
6151
|
+
} else {
|
|
6152
|
+
audioRef.value.play();
|
|
6153
|
+
audioData.handPlaying = true;
|
|
6154
|
+
}
|
|
6155
|
+
audioData.playing = !audioData.playing;
|
|
6156
|
+
emit("play", audioData.playing);
|
|
6157
|
+
};
|
|
6158
|
+
const forward = () => {
|
|
6159
|
+
audioData.currentTime++;
|
|
6160
|
+
audioRef.value.currentTime = audioData.currentTime;
|
|
6161
|
+
emit("forward", audioData.currentTime);
|
|
6162
|
+
};
|
|
6163
|
+
const handle = (val) => {
|
|
6164
|
+
audioData.currentDuration = formatSeconds(val);
|
|
6165
|
+
audioData.percent = val / audioData.second * 100;
|
|
6166
|
+
};
|
|
6167
|
+
const audioEnd = () => {
|
|
6168
|
+
audioData.playing = false;
|
|
6169
|
+
emit("ended");
|
|
6170
|
+
};
|
|
6171
|
+
const progressChange = (val) => {
|
|
6172
|
+
audioRef.value.currentTime = audioData.second * val / 100;
|
|
6173
|
+
emit("changeProgress", audioRef.value.currentTime);
|
|
6174
|
+
};
|
|
6175
|
+
const handleMute = () => {
|
|
6176
|
+
audioData.hanMuted = !audioData.hanMuted;
|
|
6177
|
+
emit("mute", audioData.hanMuted);
|
|
6178
|
+
};
|
|
6179
|
+
const formatSeconds = (value) => {
|
|
6180
|
+
let theTime = parseInt(value);
|
|
6181
|
+
let theTime1 = 0;
|
|
6182
|
+
let theTime2 = 0;
|
|
6183
|
+
if (theTime > 60) {
|
|
6184
|
+
theTime1 = parseInt(theTime / 60);
|
|
6185
|
+
theTime = parseInt(theTime % 60);
|
|
6186
|
+
if (theTime1 > 60) {
|
|
6187
|
+
theTime2 = parseInt(theTime1 / 60);
|
|
6188
|
+
theTime1 = parseInt(theTime1 % 60);
|
|
6189
|
+
}
|
|
6190
|
+
}
|
|
6191
|
+
let result = "" + parseInt(theTime);
|
|
6192
|
+
if (result < 10) {
|
|
6193
|
+
result = "0" + result;
|
|
6194
|
+
}
|
|
6195
|
+
if (theTime1 > 0) {
|
|
6196
|
+
result = "" + parseInt(theTime1) + ":" + result;
|
|
6197
|
+
if (theTime1 < 10) {
|
|
6198
|
+
result = "0" + result;
|
|
6199
|
+
}
|
|
6200
|
+
} else {
|
|
6201
|
+
result = "00:" + result;
|
|
6202
|
+
}
|
|
6203
|
+
if (theTime2 > 0) {
|
|
6204
|
+
result = "" + parseInt(theTime2) + ":" + result;
|
|
6205
|
+
if (theTime2 < 10) {
|
|
6206
|
+
result = "0" + result;
|
|
6207
|
+
}
|
|
6208
|
+
} else {
|
|
6209
|
+
result = "00:" + result;
|
|
6210
|
+
}
|
|
6211
|
+
return result;
|
|
6212
|
+
};
|
|
6213
|
+
vue.watch(() => audioData.currentTime, (value) => {
|
|
6214
|
+
handle(value);
|
|
6215
|
+
});
|
|
6216
|
+
vue.provide("audioParent", {
|
|
6217
|
+
children: [],
|
|
6218
|
+
props,
|
|
6219
|
+
audioData,
|
|
6220
|
+
handleMute,
|
|
6221
|
+
forward,
|
|
6222
|
+
fastBack,
|
|
6223
|
+
changeStatus
|
|
6224
|
+
});
|
|
6225
|
+
return __spreadProps(__spreadValues(__spreadValues({}, vue.toRefs(props)), vue.toRefs(audioData)), {
|
|
6226
|
+
audioRef,
|
|
6227
|
+
fastBack,
|
|
6228
|
+
forward,
|
|
6229
|
+
changeStatus,
|
|
6230
|
+
progressChange,
|
|
6231
|
+
audioEnd,
|
|
6232
|
+
onTimeupdate,
|
|
6233
|
+
handleMute
|
|
6234
|
+
});
|
|
6235
|
+
}
|
|
6236
|
+
});
|
|
6237
|
+
const _hoisted_1$H = { class: "nut-audio" };
|
|
6238
|
+
const _hoisted_2$A = {
|
|
6239
|
+
key: 0,
|
|
6240
|
+
class: "progress-wrapper"
|
|
6241
|
+
};
|
|
6242
|
+
const _hoisted_3$s = { class: "time" };
|
|
6243
|
+
const _hoisted_4$l = { class: "progress-bar-wrapper" };
|
|
6244
|
+
const _hoisted_5$d = /* @__PURE__ */ vue.createElementVNode("div", { class: "custom-button" }, null, -1);
|
|
6245
|
+
const _hoisted_6$a = { class: "time" };
|
|
6246
|
+
const _hoisted_7$8 = {
|
|
6247
|
+
key: 1,
|
|
6248
|
+
class: "nut-audio-icon"
|
|
6249
|
+
};
|
|
6250
|
+
const _hoisted_8$8 = ["controls", "src", "preload", "autoplay", "loop", "muted"];
|
|
6251
|
+
function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
|
|
6252
|
+
const _component_nut_range = vue.resolveComponent("nut-range");
|
|
6253
|
+
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
6254
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$H, [
|
|
6255
|
+
_ctx.type == "progress" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$A, [
|
|
6256
|
+
vue.createElementVNode("div", _hoisted_3$s, vue.toDisplayString(_ctx.currentDuration), 1),
|
|
6257
|
+
vue.createElementVNode("div", _hoisted_4$l, [
|
|
6258
|
+
vue.createVNode(_component_nut_range, {
|
|
6259
|
+
modelValue: _ctx.percent,
|
|
6260
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.percent = $event),
|
|
6261
|
+
"hidden-range": "",
|
|
6262
|
+
onChange: _ctx.progressChange,
|
|
6263
|
+
"inactive-color": "#cccccc",
|
|
6264
|
+
"active-color": "#fa2c19"
|
|
6265
|
+
}, {
|
|
6266
|
+
button: vue.withCtx(() => [
|
|
6267
|
+
_hoisted_5$d
|
|
6268
|
+
]),
|
|
6269
|
+
_: 1
|
|
6270
|
+
}, 8, ["modelValue", "onChange"])
|
|
6271
|
+
]),
|
|
6272
|
+
vue.createElementVNode("div", _hoisted_6$a, vue.toDisplayString(_ctx.duration), 1)
|
|
6273
|
+
])) : vue.createCommentVNode("", true),
|
|
6274
|
+
_ctx.type == "icon" ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7$8, [
|
|
6275
|
+
vue.createElementVNode("div", {
|
|
6276
|
+
class: vue.normalizeClass(["nut-audio-icon-box", _ctx.playing ? "nut-audio-icon-play" : "nut-audio-icon-stop"]),
|
|
6277
|
+
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.changeStatus && _ctx.changeStatus(...args))
|
|
6278
|
+
}, [
|
|
6279
|
+
_ctx.playing ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
6280
|
+
key: 0,
|
|
6281
|
+
name: "service",
|
|
6282
|
+
class: "nut-icon-am-rotate nut-icon-am-infinite"
|
|
6283
|
+
})) : vue.createCommentVNode("", true),
|
|
6284
|
+
!_ctx.playing ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
6285
|
+
key: 1,
|
|
6286
|
+
name: "service"
|
|
6287
|
+
})) : vue.createCommentVNode("", true)
|
|
6288
|
+
], 2)
|
|
6289
|
+
])) : vue.createCommentVNode("", true),
|
|
6290
|
+
_ctx.type == "none" ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6291
|
+
key: 2,
|
|
6292
|
+
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.changeStatus && _ctx.changeStatus(...args))
|
|
6293
|
+
}, [
|
|
6294
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
6295
|
+
])) : vue.createCommentVNode("", true),
|
|
6296
|
+
_ctx.type != "none" ? vue.renderSlot(_ctx.$slots, "default", { key: 3 }) : vue.createCommentVNode("", true),
|
|
6297
|
+
vue.createElementVNode("audio", {
|
|
6298
|
+
class: "audioMain",
|
|
6299
|
+
controls: _ctx.type == "controls",
|
|
6300
|
+
ref: "audioRef",
|
|
6301
|
+
src: _ctx.url,
|
|
6302
|
+
preload: _ctx.preload,
|
|
6303
|
+
autoplay: _ctx.autoplay,
|
|
6304
|
+
loop: _ctx.loop,
|
|
6305
|
+
onTimeupdate: _cache[3] || (_cache[3] = (...args) => _ctx.onTimeupdate && _ctx.onTimeupdate(...args)),
|
|
6306
|
+
onEnded: _cache[4] || (_cache[4] = (...args) => _ctx.audioEnd && _ctx.audioEnd(...args)),
|
|
6307
|
+
muted: _ctx.hanMuted
|
|
6308
|
+
}, null, 40, _hoisted_8$8)
|
|
6309
|
+
]);
|
|
6310
|
+
}
|
|
6311
|
+
var Audio = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["render", _sfc_render$P]]);
|
|
6312
|
+
const { componentName: componentName$E, create: create$T } = createComponent("audio-operate");
|
|
6313
|
+
const _sfc_main$T = create$T({
|
|
6314
|
+
props: {
|
|
6315
|
+
type: {
|
|
6316
|
+
type: Array,
|
|
6317
|
+
default() {
|
|
6318
|
+
return "play";
|
|
6319
|
+
}
|
|
6320
|
+
}
|
|
6321
|
+
},
|
|
6322
|
+
components: {},
|
|
6323
|
+
emits: ["click"],
|
|
6324
|
+
setup(props, { emit }) {
|
|
6325
|
+
const audio = vue.inject("audioParent");
|
|
6326
|
+
const parent = vue.reactive(audio);
|
|
6327
|
+
const customSlot = vue.ref(vue.useSlots().default);
|
|
6328
|
+
return __spreadProps(__spreadValues(__spreadValues({}, vue.toRefs(props)), vue.toRefs(parent)), { customSlot });
|
|
6329
|
+
}
|
|
6330
|
+
});
|
|
6331
|
+
const _hoisted_1$G = { class: "nut-audio-operate" };
|
|
6332
|
+
const _hoisted_2$z = /* @__PURE__ */ vue.createTextVNode("\u5012\u9000");
|
|
6333
|
+
const _hoisted_3$r = /* @__PURE__ */ vue.createTextVNode("\u5FEB\u8FDB");
|
|
6334
|
+
const _hoisted_4$k = /* @__PURE__ */ vue.createTextVNode("\u9759\u97F3");
|
|
6335
|
+
function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
|
|
6336
|
+
const _component_nut_button = vue.resolveComponent("nut-button");
|
|
6337
|
+
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$G, [
|
|
6338
|
+
_ctx.type == "back" ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6339
|
+
key: 0,
|
|
6340
|
+
class: "nut-audio-operate-item",
|
|
6341
|
+
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.fastBack && _ctx.fastBack(...args))
|
|
6342
|
+
}, [
|
|
6343
|
+
!_ctx.customSlot ? (vue.openBlock(), vue.createBlock(_component_nut_button, {
|
|
6344
|
+
key: 0,
|
|
6345
|
+
type: "primary",
|
|
6346
|
+
size: "small"
|
|
6347
|
+
}, {
|
|
6348
|
+
default: vue.withCtx(() => [
|
|
6349
|
+
_hoisted_2$z
|
|
6350
|
+
]),
|
|
6351
|
+
_: 1
|
|
6352
|
+
})) : vue.createCommentVNode("", true),
|
|
6353
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
6354
|
+
])) : vue.createCommentVNode("", true),
|
|
6355
|
+
_ctx.type == "play" ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6356
|
+
key: 1,
|
|
6357
|
+
class: "nut-audio-operate-item",
|
|
6358
|
+
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.changeStatus && _ctx.changeStatus(...args))
|
|
6359
|
+
}, [
|
|
6360
|
+
!_ctx.customSlot ? (vue.openBlock(), vue.createBlock(_component_nut_button, {
|
|
6361
|
+
key: 0,
|
|
6362
|
+
type: "primary",
|
|
6363
|
+
size: "small"
|
|
6364
|
+
}, {
|
|
6365
|
+
default: vue.withCtx(() => [
|
|
6366
|
+
vue.createTextVNode(vue.toDisplayString(!_ctx.audioData.playing ? "\u5F00\u59CB" : "\u6682\u505C"), 1)
|
|
6367
|
+
]),
|
|
6368
|
+
_: 1
|
|
6369
|
+
})) : vue.createCommentVNode("", true),
|
|
6370
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
6371
|
+
])) : vue.createCommentVNode("", true),
|
|
6372
|
+
_ctx.type == "forward" ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6373
|
+
key: 2,
|
|
6374
|
+
class: "nut-audio-operate-item",
|
|
6375
|
+
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.forward && _ctx.forward(...args))
|
|
6376
|
+
}, [
|
|
6377
|
+
!_ctx.customSlot ? (vue.openBlock(), vue.createBlock(_component_nut_button, {
|
|
6378
|
+
key: 0,
|
|
6379
|
+
type: "primary",
|
|
6380
|
+
size: "small"
|
|
6381
|
+
}, {
|
|
6382
|
+
default: vue.withCtx(() => [
|
|
6383
|
+
_hoisted_3$r
|
|
6384
|
+
]),
|
|
6385
|
+
_: 1
|
|
6386
|
+
})) : vue.createCommentVNode("", true),
|
|
6387
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
6388
|
+
])) : vue.createCommentVNode("", true),
|
|
6389
|
+
_ctx.type == "mute" ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6390
|
+
key: 3,
|
|
6391
|
+
class: "nut-audio-operate-item",
|
|
6392
|
+
onClick: _cache[3] || (_cache[3] = (...args) => _ctx.handleMute && _ctx.handleMute(...args))
|
|
6393
|
+
}, [
|
|
6394
|
+
!_ctx.customSlot ? (vue.openBlock(), vue.createBlock(_component_nut_button, {
|
|
6395
|
+
key: 0,
|
|
6396
|
+
type: !_ctx.audioData.hanMuted ? "primary" : "default",
|
|
6397
|
+
size: "small"
|
|
6398
|
+
}, {
|
|
6399
|
+
default: vue.withCtx(() => [
|
|
6400
|
+
_hoisted_4$k
|
|
6401
|
+
]),
|
|
6402
|
+
_: 1
|
|
6403
|
+
}, 8, ["type"])) : vue.createCommentVNode("", true),
|
|
6404
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
6405
|
+
])) : vue.createCommentVNode("", true)
|
|
6406
|
+
]);
|
|
6407
|
+
}
|
|
6408
|
+
var AudioOperate = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["render", _sfc_render$O]]);
|
|
5581
6409
|
const { componentName: componentName$D, create: create$S } = createComponent("navbar");
|
|
5582
6410
|
const _sfc_main$S = create$S({
|
|
5583
6411
|
props: {
|
|
5584
6412
|
leftShow: { type: Boolean, default: true },
|
|
5585
6413
|
title: { type: String, default: "" },
|
|
5586
6414
|
titIcon: { type: String, default: "" },
|
|
5587
|
-
icon: { type: String, default: "" },
|
|
5588
6415
|
desc: { type: String, default: "" },
|
|
5589
6416
|
defaultIndex: {
|
|
5590
6417
|
type: Number,
|
|
5591
6418
|
default: 0
|
|
5592
6419
|
}
|
|
5593
6420
|
},
|
|
5594
|
-
emits: [
|
|
5595
|
-
"click",
|
|
5596
|
-
"on-click-back",
|
|
5597
|
-
"on-click-title",
|
|
5598
|
-
"on-click-right",
|
|
5599
|
-
"on-click-desc",
|
|
5600
|
-
"on-click-icon",
|
|
5601
|
-
"on-click-more",
|
|
5602
|
-
"on-click-clear",
|
|
5603
|
-
"on-click-send",
|
|
5604
|
-
"on-click-slot",
|
|
5605
|
-
"on-click-slot-send",
|
|
5606
|
-
"switch-tab"
|
|
5607
|
-
],
|
|
6421
|
+
emits: ["click", "on-click-back", "on-click-title", "on-click-icon", "on-click-right"],
|
|
5608
6422
|
setup(props, { emit }) {
|
|
5609
6423
|
const activeIndex = vue.ref(props.defaultIndex);
|
|
5610
6424
|
const classes = vue.computed(() => {
|
|
@@ -5622,32 +6436,22 @@ var __publicField = (obj, key, value) => {
|
|
|
5622
6436
|
function handleCenterIcon() {
|
|
5623
6437
|
emit("on-click-icon");
|
|
5624
6438
|
}
|
|
5625
|
-
function
|
|
5626
|
-
emit("on-click-
|
|
5627
|
-
}
|
|
5628
|
-
function handleSend() {
|
|
5629
|
-
emit("on-click-send");
|
|
5630
|
-
}
|
|
5631
|
-
function handleSlot() {
|
|
5632
|
-
emit("on-click-slot");
|
|
5633
|
-
}
|
|
5634
|
-
function handleSends() {
|
|
5635
|
-
emit("on-click-slot-send");
|
|
6439
|
+
function handleRight() {
|
|
6440
|
+
emit("on-click-right");
|
|
5636
6441
|
}
|
|
5637
6442
|
return {
|
|
5638
6443
|
classes,
|
|
5639
6444
|
handleLeft,
|
|
5640
6445
|
handleCenter,
|
|
5641
6446
|
handleCenterIcon,
|
|
5642
|
-
|
|
5643
|
-
handleSend,
|
|
5644
|
-
handleSlot,
|
|
5645
|
-
handleSends,
|
|
6447
|
+
handleRight,
|
|
5646
6448
|
activeIndex
|
|
5647
6449
|
};
|
|
5648
6450
|
}
|
|
5649
6451
|
});
|
|
5650
6452
|
const _hoisted_1$F = { class: "nut-navbar__left" };
|
|
6453
|
+
const _hoisted_2$y = { class: "nut-navbar__title" };
|
|
6454
|
+
const _hoisted_3$q = { class: "nut-navbar__right" };
|
|
5651
6455
|
function _sfc_render$N(_ctx, _cache, $props, $setup, $data, $options) {
|
|
5652
6456
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
5653
6457
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
@@ -5659,11 +6463,10 @@ var __publicField = (obj, key, value) => {
|
|
|
5659
6463
|
color: "#979797",
|
|
5660
6464
|
name: "left",
|
|
5661
6465
|
onClick: _ctx.handleLeft
|
|
5662
|
-
}, null, 8, ["onClick"])) : vue.createCommentVNode("", true)
|
|
6466
|
+
}, null, 8, ["onClick"])) : vue.createCommentVNode("", true),
|
|
6467
|
+
vue.renderSlot(_ctx.$slots, "left")
|
|
5663
6468
|
]),
|
|
5664
|
-
vue.createElementVNode("view",
|
|
5665
|
-
class: vue.normalizeClass(["nut-navbar__title", { icon: _ctx.icon }])
|
|
5666
|
-
}, [
|
|
6469
|
+
vue.createElementVNode("view", _hoisted_2$y, [
|
|
5667
6470
|
_ctx.title ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
5668
6471
|
key: 0,
|
|
5669
6472
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleCenter && _ctx.handleCenter(...args))
|
|
@@ -5675,31 +6478,15 @@ var __publicField = (obj, key, value) => {
|
|
|
5675
6478
|
onClick: _ctx.handleCenterIcon
|
|
5676
6479
|
}, null, 8, ["name", "onClick"])) : vue.createCommentVNode("", true),
|
|
5677
6480
|
vue.renderSlot(_ctx.$slots, "content")
|
|
5678
|
-
]
|
|
5679
|
-
|
|
5680
|
-
key: 0,
|
|
5681
|
-
class: vue.normalizeClass(["nut-navbar__right", { icon: _ctx.icon }])
|
|
5682
|
-
}, [
|
|
6481
|
+
]),
|
|
6482
|
+
vue.createElementVNode("view", _hoisted_3$q, [
|
|
5683
6483
|
_ctx.desc ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
5684
6484
|
key: 0,
|
|
5685
|
-
|
|
5686
|
-
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.
|
|
5687
|
-
}, vue.toDisplayString(_ctx.desc),
|
|
5688
|
-
|
|
5689
|
-
|
|
5690
|
-
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.handleSends && _ctx.handleSends(...args))
|
|
5691
|
-
}, [
|
|
5692
|
-
vue.renderSlot(_ctx.$slots, "icons")
|
|
5693
|
-
])) : vue.createCommentVNode("", true),
|
|
5694
|
-
vue.createElementVNode("view", null, [
|
|
5695
|
-
_ctx.icon ? (vue.openBlock(), vue.createBlock(_component_nut_icon, {
|
|
5696
|
-
key: 0,
|
|
5697
|
-
class: "rightIcon",
|
|
5698
|
-
name: _ctx.icon,
|
|
5699
|
-
onClick: _ctx.handleSend
|
|
5700
|
-
}, null, 8, ["name", "onClick"])) : vue.createCommentVNode("", true)
|
|
5701
|
-
])
|
|
5702
|
-
], 2)) : vue.createCommentVNode("", true)
|
|
6485
|
+
class: "right_text",
|
|
6486
|
+
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleRight && _ctx.handleRight(...args))
|
|
6487
|
+
}, vue.toDisplayString(_ctx.desc), 1)) : vue.createCommentVNode("", true),
|
|
6488
|
+
vue.renderSlot(_ctx.$slots, "right")
|
|
6489
|
+
])
|
|
5703
6490
|
], 2);
|
|
5704
6491
|
}
|
|
5705
6492
|
var Navbar = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["render", _sfc_render$N]]);
|
|
@@ -5952,7 +6739,7 @@ var __publicField = (obj, key, value) => {
|
|
|
5952
6739
|
}
|
|
5953
6740
|
},
|
|
5954
6741
|
components: {
|
|
5955
|
-
[_sfc_main$
|
|
6742
|
+
[_sfc_main$1s.name]: _sfc_main$1s,
|
|
5956
6743
|
[Popup.name]: Popup
|
|
5957
6744
|
},
|
|
5958
6745
|
emits: ["update:modelValue", "change"],
|
|
@@ -6198,7 +6985,7 @@ var __publicField = (obj, key, value) => {
|
|
|
6198
6985
|
active: parent.modelValue,
|
|
6199
6986
|
index: 0
|
|
6200
6987
|
});
|
|
6201
|
-
const router =
|
|
6988
|
+
const router = useRouter();
|
|
6202
6989
|
const relation = (child) => {
|
|
6203
6990
|
if (child.proxy) {
|
|
6204
6991
|
let index = parent.children.length;
|
|
@@ -6224,7 +7011,11 @@ var __publicField = (obj, key, value) => {
|
|
|
6224
7011
|
}
|
|
6225
7012
|
if (parent.children[value].to) {
|
|
6226
7013
|
let to = parent.children[value].to;
|
|
6227
|
-
|
|
7014
|
+
if (to && router) {
|
|
7015
|
+
router.push(to);
|
|
7016
|
+
} else {
|
|
7017
|
+
location.replace(to);
|
|
7018
|
+
}
|
|
6228
7019
|
}
|
|
6229
7020
|
});
|
|
6230
7021
|
});
|
|
@@ -6311,7 +7102,8 @@ var __publicField = (obj, key, value) => {
|
|
|
6311
7102
|
y2: 0
|
|
6312
7103
|
},
|
|
6313
7104
|
scrollStart: false,
|
|
6314
|
-
currentIndex: 0
|
|
7105
|
+
currentIndex: 0,
|
|
7106
|
+
currentData: {}
|
|
6315
7107
|
});
|
|
6316
7108
|
const classes = vue.computed(() => {
|
|
6317
7109
|
const prefixCls = componentName$z;
|
|
@@ -6371,7 +7163,6 @@ var __publicField = (obj, key, value) => {
|
|
|
6371
7163
|
state.touchState.y1 = firstTouch.pageY;
|
|
6372
7164
|
state.anchorIndex = +index;
|
|
6373
7165
|
state.currentIndex = +index;
|
|
6374
|
-
console.log(state.currentIndex);
|
|
6375
7166
|
scrollTo(+index);
|
|
6376
7167
|
};
|
|
6377
7168
|
const touchMove = (e) => {
|
|
@@ -6386,10 +7177,14 @@ var __publicField = (obj, key, value) => {
|
|
|
6386
7177
|
};
|
|
6387
7178
|
const handleClickItem = (key, item) => {
|
|
6388
7179
|
context.emit("click-item", key, item);
|
|
7180
|
+
state.currentData = item;
|
|
6389
7181
|
};
|
|
6390
7182
|
const handleClickIndex = (key) => {
|
|
6391
7183
|
context.emit("click-index", key);
|
|
6392
7184
|
};
|
|
7185
|
+
useExpose({
|
|
7186
|
+
scrollTo
|
|
7187
|
+
});
|
|
6393
7188
|
return __spreadProps(__spreadValues({
|
|
6394
7189
|
classes
|
|
6395
7190
|
}, vue.toRefs(state)), {
|
|
@@ -6426,11 +7221,11 @@ var __publicField = (obj, key, value) => {
|
|
|
6426
7221
|
vue.createElementVNode("view", _hoisted_1$A, vue.toDisplayString(item[_ctx.acceptKey]), 1),
|
|
6427
7222
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(item.list, (subitem) => {
|
|
6428
7223
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
6429
|
-
class: "nut-elevator__list__item__name",
|
|
7224
|
+
class: vue.normalizeClass(["nut-elevator__list__item__name", { "nut-elevator__list__item__name--highcolor": _ctx.currentData.id === subitem.id }]),
|
|
6430
7225
|
key: subitem["id"],
|
|
6431
7226
|
onClick: ($event) => _ctx.handleClickItem(item[_ctx.acceptKey], subitem),
|
|
6432
7227
|
innerHTML: subitem.name
|
|
6433
|
-
}, null,
|
|
7228
|
+
}, null, 10, _hoisted_2$t);
|
|
6434
7229
|
}), 128))
|
|
6435
7230
|
]);
|
|
6436
7231
|
}), 128))
|
|
@@ -7108,7 +7903,7 @@ var __publicField = (obj, key, value) => {
|
|
|
7108
7903
|
color: props.iconColor || parent.iconColor
|
|
7109
7904
|
};
|
|
7110
7905
|
});
|
|
7111
|
-
const router =
|
|
7906
|
+
const router = useRouter();
|
|
7112
7907
|
const handleClick = (event) => {
|
|
7113
7908
|
emit("click", event);
|
|
7114
7909
|
if (props.to && router) {
|
|
@@ -7442,12 +8237,36 @@ var __publicField = (obj, key, value) => {
|
|
|
7442
8237
|
type: Boolean,
|
|
7443
8238
|
default: true
|
|
7444
8239
|
},
|
|
8240
|
+
showTitle: {
|
|
8241
|
+
type: Boolean,
|
|
8242
|
+
default: true
|
|
8243
|
+
},
|
|
8244
|
+
showSubTitle: {
|
|
8245
|
+
type: Boolean,
|
|
8246
|
+
default: true
|
|
8247
|
+
},
|
|
8248
|
+
showToday: {
|
|
8249
|
+
type: Boolean,
|
|
8250
|
+
default: true
|
|
8251
|
+
},
|
|
7445
8252
|
title: {
|
|
7446
8253
|
type: String,
|
|
7447
8254
|
default: "\u65E5\u5386\u9009\u62E9"
|
|
7448
8255
|
},
|
|
7449
|
-
|
|
8256
|
+
confirmText: {
|
|
8257
|
+
type: String,
|
|
8258
|
+
default: "\u786E\u8BA4"
|
|
8259
|
+
},
|
|
8260
|
+
startText: {
|
|
7450
8261
|
type: String,
|
|
8262
|
+
default: "\u5F00\u59CB"
|
|
8263
|
+
},
|
|
8264
|
+
endText: {
|
|
8265
|
+
type: String,
|
|
8266
|
+
default: "\u7ED3\u675F"
|
|
8267
|
+
},
|
|
8268
|
+
defaultValue: {
|
|
8269
|
+
type: [String, Array],
|
|
7451
8270
|
default: null
|
|
7452
8271
|
},
|
|
7453
8272
|
startDate: {
|
|
@@ -7459,15 +8278,32 @@ var __publicField = (obj, key, value) => {
|
|
|
7459
8278
|
default: Utils.getDay(365)
|
|
7460
8279
|
}
|
|
7461
8280
|
},
|
|
7462
|
-
emits: ["choose", "update", "close"],
|
|
7463
|
-
setup(props, { emit }) {
|
|
8281
|
+
emits: ["choose", "update", "close", "select"],
|
|
8282
|
+
setup(props, { emit, slots }) {
|
|
7464
8283
|
const weeks = vue.ref(["\u65E5", "\u4E00", "\u4E8C", "\u4E09", "\u56DB", "\u4E94", "\u516D"]);
|
|
7465
8284
|
const months = vue.ref(null);
|
|
7466
8285
|
const monthsPanel = vue.ref(null);
|
|
7467
8286
|
const weeksPanel = vue.ref(null);
|
|
8287
|
+
const viewArea = vue.ref(null);
|
|
8288
|
+
const viewHeight = vue.ref(0);
|
|
8289
|
+
const compConthsData = vue.computed(() => {
|
|
8290
|
+
return state.monthsData.slice(state.defaultRange[0], state.defaultRange[1]);
|
|
8291
|
+
});
|
|
8292
|
+
const showTopBtn = vue.computed(() => {
|
|
8293
|
+
return slots.btn;
|
|
8294
|
+
});
|
|
8295
|
+
const topInfo = vue.computed(() => {
|
|
8296
|
+
return slots.topInfo;
|
|
8297
|
+
});
|
|
8298
|
+
const bottomInfo = vue.computed(() => {
|
|
8299
|
+
return slots.bottomInfo;
|
|
8300
|
+
});
|
|
7468
8301
|
const state = vue.reactive({
|
|
7469
8302
|
yearMonthTitle: "",
|
|
8303
|
+
defaultRange: [],
|
|
7470
8304
|
currDate: "",
|
|
8305
|
+
propStartDate: "",
|
|
8306
|
+
propEndDate: "",
|
|
7471
8307
|
unLoadPrev: false,
|
|
7472
8308
|
touchParams: {
|
|
7473
8309
|
startY: 0,
|
|
@@ -7487,7 +8323,10 @@ var __publicField = (obj, key, value) => {
|
|
|
7487
8323
|
startData: "",
|
|
7488
8324
|
endData: "",
|
|
7489
8325
|
isRange: props.type === "range",
|
|
7490
|
-
timer: 0
|
|
8326
|
+
timer: 0,
|
|
8327
|
+
currentIndex: 0,
|
|
8328
|
+
avgHeight: 0,
|
|
8329
|
+
monthsNum: 0
|
|
7491
8330
|
});
|
|
7492
8331
|
const splitDate = (date) => {
|
|
7493
8332
|
return date.split("-");
|
|
@@ -7499,14 +8338,14 @@ var __publicField = (obj, key, value) => {
|
|
|
7499
8338
|
return Utils.isEqual(state.currDate[1], currDate);
|
|
7500
8339
|
};
|
|
7501
8340
|
const getCurrDate = (day, month, isRange) => {
|
|
7502
|
-
return
|
|
8341
|
+
return month.curData[0] + "-" + month.curData[1] + "-" + Utils.getNumTwoBit(+day.day);
|
|
7503
8342
|
};
|
|
7504
8343
|
const getClass = (day, month, isRange) => {
|
|
7505
|
-
const currDate = getCurrDate(day, month
|
|
8344
|
+
const currDate = getCurrDate(day, month);
|
|
7506
8345
|
if (day.type == "curr") {
|
|
7507
8346
|
if (!state.isRange && Utils.isEqual(state.currDate, currDate) || state.isRange && (isStart(currDate) || isEnd(currDate))) {
|
|
7508
8347
|
return `${state.dayPrefix}-active`;
|
|
7509
|
-
} else if (
|
|
8348
|
+
} else if (state.propStartDate && Utils.compareDate(currDate, state.propStartDate) || state.propEndDate && Utils.compareDate(state.propEndDate, currDate)) {
|
|
7510
8349
|
return `${state.dayPrefix}-disabled`;
|
|
7511
8350
|
} else if (state.isRange && Array.isArray(state.currDate) && Object.values(state.currDate).length == 2 && Utils.compareDate(state.currDate[0], currDate) && Utils.compareDate(currDate, state.currDate[1])) {
|
|
7512
8351
|
return `${state.dayPrefix}-choose`;
|
|
@@ -7526,9 +8365,8 @@ var __publicField = (obj, key, value) => {
|
|
|
7526
8365
|
}
|
|
7527
8366
|
};
|
|
7528
8367
|
const chooseDay = (day, month, isFirst, isRange) => {
|
|
7529
|
-
if (getClass(day, month
|
|
8368
|
+
if (getClass(day, month) != `${state.dayPrefix}-disabled`) {
|
|
7530
8369
|
let days = [...month.curData];
|
|
7531
|
-
days = isRange ? days.splice(3) : days.splice(0, 3);
|
|
7532
8370
|
days[2] = typeof day.day == "number" ? Utils.getNumTwoBit(day.day) : day.day;
|
|
7533
8371
|
days[3] = `${days[0]}-${days[1]}-${days[2]}`;
|
|
7534
8372
|
days[4] = Utils.getWhatDay(+days[0], +days[1], +days[2]);
|
|
@@ -7555,8 +8393,11 @@ var __publicField = (obj, key, value) => {
|
|
|
7555
8393
|
}
|
|
7556
8394
|
}
|
|
7557
8395
|
}
|
|
7558
|
-
if (
|
|
7559
|
-
|
|
8396
|
+
if (!isFirst) {
|
|
8397
|
+
emit("select", state.chooseData);
|
|
8398
|
+
if (props.isAutoBackFill) {
|
|
8399
|
+
confirm();
|
|
8400
|
+
}
|
|
7560
8401
|
}
|
|
7561
8402
|
}
|
|
7562
8403
|
};
|
|
@@ -7574,26 +8415,47 @@ var __publicField = (obj, key, value) => {
|
|
|
7574
8415
|
month = month == 12 ? 1 : ++month;
|
|
7575
8416
|
break;
|
|
7576
8417
|
}
|
|
7577
|
-
return [
|
|
7578
|
-
year,
|
|
7579
|
-
Utils.getNumTwoBit(month),
|
|
7580
|
-
Utils.getMonthDays(String(year), String(month))
|
|
7581
|
-
];
|
|
8418
|
+
return [year, Utils.getNumTwoBit(month), Utils.getMonthDays(String(year), String(month))];
|
|
7582
8419
|
};
|
|
7583
|
-
const getDaysStatus = (days, type) => {
|
|
8420
|
+
const getDaysStatus = (days, type, dateInfo) => {
|
|
8421
|
+
let { year, month } = dateInfo;
|
|
7584
8422
|
if (type == "prev" && days >= 7) {
|
|
7585
8423
|
days -= 7;
|
|
7586
8424
|
}
|
|
7587
8425
|
return Array.from(Array(days), (v, k) => {
|
|
7588
8426
|
return {
|
|
7589
8427
|
day: k + 1,
|
|
7590
|
-
type
|
|
8428
|
+
type,
|
|
8429
|
+
year,
|
|
8430
|
+
month
|
|
8431
|
+
};
|
|
8432
|
+
});
|
|
8433
|
+
};
|
|
8434
|
+
const getPreDaysStatus = (days, type, dateInfo, preCurrMonthDays) => {
|
|
8435
|
+
let { year, month } = dateInfo;
|
|
8436
|
+
if (type == "prev" && days >= 7) {
|
|
8437
|
+
days -= 7;
|
|
8438
|
+
}
|
|
8439
|
+
let months2 = Array.from(Array(preCurrMonthDays), (v, k) => {
|
|
8440
|
+
return {
|
|
8441
|
+
day: k + 1,
|
|
8442
|
+
type,
|
|
8443
|
+
year,
|
|
8444
|
+
month
|
|
7591
8445
|
};
|
|
7592
8446
|
});
|
|
8447
|
+
return months2.slice(preCurrMonthDays - days);
|
|
7593
8448
|
};
|
|
7594
8449
|
const getMonth = (curData, type) => {
|
|
7595
8450
|
const preMonthDays = Utils.getMonthPreDay(+curData[0], +curData[1]);
|
|
8451
|
+
let preMonth = curData[1] - 1;
|
|
8452
|
+
let preYear = curData[0];
|
|
8453
|
+
if (preMonth <= 0) {
|
|
8454
|
+
preMonth = 12;
|
|
8455
|
+
preYear += 1;
|
|
8456
|
+
}
|
|
7596
8457
|
const currMonthDays = Utils.getMonthDays(curData[0], curData[1]);
|
|
8458
|
+
const preCurrMonthDays = Utils.getMonthDays(preYear + "", preMonth + "");
|
|
7597
8459
|
const title = {
|
|
7598
8460
|
year: curData[0],
|
|
7599
8461
|
month: curData[1]
|
|
@@ -7602,10 +8464,16 @@ var __publicField = (obj, key, value) => {
|
|
|
7602
8464
|
curData,
|
|
7603
8465
|
title: `${title.year}\u5E74${title.month}\u6708`,
|
|
7604
8466
|
monthData: [
|
|
7605
|
-
...
|
|
7606
|
-
...getDaysStatus(currMonthDays, "curr")
|
|
8467
|
+
...getPreDaysStatus(preMonthDays, "prev", { month: preMonth, year: preYear }, preCurrMonthDays),
|
|
8468
|
+
...getDaysStatus(currMonthDays, "curr", title)
|
|
7607
8469
|
]
|
|
7608
8470
|
};
|
|
8471
|
+
monthInfo.cssHeight = 39 + (monthInfo.monthData.length > 35 ? 384 : 320);
|
|
8472
|
+
let cssScrollHeight = 0;
|
|
8473
|
+
if (state.monthsData.length > 0) {
|
|
8474
|
+
cssScrollHeight = state.monthsData[state.monthsData.length - 1].cssScrollHeight + state.monthsData[state.monthsData.length - 1].cssHeight;
|
|
8475
|
+
}
|
|
8476
|
+
monthInfo.cssScrollHeight = cssScrollHeight;
|
|
7609
8477
|
if (type == "next") {
|
|
7610
8478
|
if (!state.endData || !Utils.compareDate(`${state.endData[0]}-${state.endData[1]}-${Utils.getMonthDays(state.endData[0], state.endData[1])}`, `${curData[0]}-${curData[1]}-${curData[2]}`)) {
|
|
7611
8479
|
state.monthsData.push(monthInfo);
|
|
@@ -7619,44 +8487,97 @@ var __publicField = (obj, key, value) => {
|
|
|
7619
8487
|
}
|
|
7620
8488
|
};
|
|
7621
8489
|
const initData = () => {
|
|
7622
|
-
|
|
7623
|
-
|
|
7624
|
-
|
|
8490
|
+
let propStartDate = props.startDate ? props.startDate : Utils.getDay(0);
|
|
8491
|
+
let propEndDate = props.endDate ? props.endDate : Utils.getDay(365);
|
|
8492
|
+
state.propStartDate = propStartDate;
|
|
8493
|
+
state.propEndDate = propEndDate;
|
|
8494
|
+
state.startData = splitDate(propStartDate);
|
|
8495
|
+
state.endData = splitDate(propEndDate);
|
|
8496
|
+
if (!props.defaultValue || Array.isArray(props.defaultValue) && props.defaultValue.length <= 0) {
|
|
7625
8497
|
state.currDate = state.isRange ? [Utils.date2Str(new Date()), Utils.getDay(1)] : Utils.date2Str(new Date());
|
|
7626
8498
|
} else {
|
|
7627
8499
|
state.currDate = state.isRange ? [...props.defaultValue] : props.defaultValue;
|
|
7628
8500
|
}
|
|
8501
|
+
const startDate = {
|
|
8502
|
+
year: Number(state.startData[0]),
|
|
8503
|
+
month: Number(state.startData[1])
|
|
8504
|
+
};
|
|
8505
|
+
const endDate = {
|
|
8506
|
+
year: Number(state.endData[0]),
|
|
8507
|
+
month: Number(state.endData[1])
|
|
8508
|
+
};
|
|
8509
|
+
let monthsNum = endDate.month - startDate.month;
|
|
8510
|
+
if (endDate.year - startDate.year > 0) {
|
|
8511
|
+
monthsNum = monthsNum + 12 * (endDate.year - startDate.year);
|
|
8512
|
+
}
|
|
8513
|
+
getMonth(state.startData, "next");
|
|
8514
|
+
let i = 1;
|
|
8515
|
+
do {
|
|
8516
|
+
getMonth(getCurrData("next"), "next");
|
|
8517
|
+
} while (i++ < monthsNum);
|
|
8518
|
+
state.monthsNum = monthsNum;
|
|
7629
8519
|
if (state.isRange && Array.isArray(state.currDate)) {
|
|
7630
|
-
if (
|
|
7631
|
-
state.currDate.splice(0, 1,
|
|
8520
|
+
if (propStartDate && Utils.compareDate(state.currDate[0], propStartDate)) {
|
|
8521
|
+
state.currDate.splice(0, 1, propStartDate);
|
|
7632
8522
|
}
|
|
7633
|
-
if (
|
|
7634
|
-
state.currDate.splice(1, 1,
|
|
8523
|
+
if (propEndDate && Utils.compareDate(propEndDate, state.currDate[1])) {
|
|
8524
|
+
state.currDate.splice(1, 1, propEndDate);
|
|
7635
8525
|
}
|
|
7636
|
-
state.defaultData = [
|
|
7637
|
-
...splitDate(state.currDate[0]),
|
|
7638
|
-
...splitDate(state.currDate[1])
|
|
7639
|
-
];
|
|
8526
|
+
state.defaultData = [...splitDate(state.currDate[0]), ...splitDate(state.currDate[1])];
|
|
7640
8527
|
} else {
|
|
7641
|
-
if (
|
|
7642
|
-
state.currDate =
|
|
7643
|
-
} else if (
|
|
7644
|
-
state.currDate =
|
|
8528
|
+
if (propStartDate && Utils.compareDate(state.currDate, propStartDate)) {
|
|
8529
|
+
state.currDate = propStartDate;
|
|
8530
|
+
} else if (propEndDate && !Utils.compareDate(state.currDate, propEndDate)) {
|
|
8531
|
+
state.currDate = propEndDate;
|
|
7645
8532
|
}
|
|
7646
8533
|
state.defaultData = [...splitDate(state.currDate)];
|
|
7647
8534
|
}
|
|
7648
|
-
|
|
7649
|
-
|
|
7650
|
-
|
|
7651
|
-
|
|
7652
|
-
|
|
7653
|
-
|
|
8535
|
+
let current = 0;
|
|
8536
|
+
let lastCurrent = 0;
|
|
8537
|
+
state.monthsData.forEach((item, index) => {
|
|
8538
|
+
if (item.title == `${state.defaultData[0]}\u5E74${state.defaultData[1]}\u6708`) {
|
|
8539
|
+
current = index;
|
|
8540
|
+
}
|
|
8541
|
+
if (state.isRange) {
|
|
8542
|
+
if (item.title == `${state.defaultData[3]}\u5E74${state.defaultData[4]}\u6708`) {
|
|
8543
|
+
lastCurrent = index;
|
|
8544
|
+
}
|
|
8545
|
+
}
|
|
8546
|
+
});
|
|
8547
|
+
setDefaultRange(monthsNum, current);
|
|
8548
|
+
state.currentIndex = current;
|
|
8549
|
+
state.yearMonthTitle = state.monthsData[state.currentIndex].title;
|
|
7654
8550
|
if (state.isRange) {
|
|
7655
|
-
chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[
|
|
7656
|
-
chooseDay({ day: state.defaultData[5], type: "curr" }, state.monthsData[
|
|
8551
|
+
chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[state.currentIndex], true);
|
|
8552
|
+
chooseDay({ day: state.defaultData[5], type: "curr" }, state.monthsData[lastCurrent], true);
|
|
7657
8553
|
} else {
|
|
7658
|
-
chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[
|
|
8554
|
+
chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[state.currentIndex], true);
|
|
7659
8555
|
}
|
|
8556
|
+
let lastItem = state.monthsData[state.monthsData.length - 1];
|
|
8557
|
+
let containerHeight = lastItem.cssHeight + lastItem.cssScrollHeight;
|
|
8558
|
+
requestAniFrame$1(() => {
|
|
8559
|
+
if ((months == null ? void 0 : months.value) && (monthsPanel == null ? void 0 : monthsPanel.value) && (viewArea == null ? void 0 : viewArea.value)) {
|
|
8560
|
+
viewHeight.value = months.value.clientHeight;
|
|
8561
|
+
monthsPanel.value.style.height = `${containerHeight}px`;
|
|
8562
|
+
months.value.scrollTop = state.monthsData[state.currentIndex].cssScrollHeight;
|
|
8563
|
+
}
|
|
8564
|
+
});
|
|
8565
|
+
state.avgHeight = Math.floor(containerHeight / (monthsNum + 1));
|
|
8566
|
+
};
|
|
8567
|
+
const setDefaultRange = (monthsNum, current) => {
|
|
8568
|
+
if (monthsNum >= 3) {
|
|
8569
|
+
if (current > 0 && current < monthsNum) {
|
|
8570
|
+
state.defaultRange = [current - 1, current + 3];
|
|
8571
|
+
} else if (current == 0) {
|
|
8572
|
+
state.defaultRange = [current, current + 4];
|
|
8573
|
+
} else if (current == monthsNum) {
|
|
8574
|
+
state.defaultRange = [current - 2, current + 2];
|
|
8575
|
+
}
|
|
8576
|
+
} else {
|
|
8577
|
+
state.defaultRange = [0, monthsNum + 2];
|
|
8578
|
+
}
|
|
8579
|
+
let defaultScrollTop = state.monthsData[state.defaultRange[0]].cssScrollHeight;
|
|
8580
|
+
state.translateY = defaultScrollTop;
|
|
7660
8581
|
};
|
|
7661
8582
|
const isActive = (day, month) => {
|
|
7662
8583
|
return state.isRange && day.type == "curr" && getClass(day, month) == "calendar-month-day-active";
|
|
@@ -7669,139 +8590,72 @@ var __publicField = (obj, key, value) => {
|
|
|
7669
8590
|
}
|
|
7670
8591
|
};
|
|
7671
8592
|
const isEndTip = (day, month) => {
|
|
7672
|
-
|
|
8593
|
+
if (state.currDate.length >= 2 && isEnd(getCurrDate(day, month))) {
|
|
8594
|
+
return isActive(day, month);
|
|
8595
|
+
}
|
|
8596
|
+
return false;
|
|
8597
|
+
};
|
|
8598
|
+
const rangeTip = (day, month) => {
|
|
8599
|
+
if (state.currDate.length >= 2) {
|
|
8600
|
+
return Utils.isEqual(state.currDate[0], state.currDate[1]);
|
|
8601
|
+
}
|
|
7673
8602
|
};
|
|
7674
8603
|
const isCurrDay = (month, day) => {
|
|
7675
8604
|
const date = `${month.curData[0]}-${month.curData[1]}-${day}`;
|
|
7676
8605
|
return Utils.isEqual(date, Utils.date2Str(new Date()));
|
|
7677
8606
|
};
|
|
7678
|
-
const
|
|
7679
|
-
|
|
7680
|
-
|
|
7681
|
-
|
|
7682
|
-
|
|
7683
|
-
|
|
7684
|
-
const top = weeksPanel == null ? void 0 : weeksPanel.value.getBoundingClientRect().bottom;
|
|
7685
|
-
const monthsDoms = monthsPanel.value.getElementsByClassName("calendar-month");
|
|
7686
|
-
for (let i = 0; i < monthsDoms.length; i++) {
|
|
7687
|
-
if (monthsDoms[i].getBoundingClientRect().top <= top && monthsDoms[i].getBoundingClientRect().bottom >= top) {
|
|
7688
|
-
state.yearMonthTitle = state.monthsData[i].title;
|
|
7689
|
-
} else if (state.scrollDistance === 0) {
|
|
7690
|
-
state.yearMonthTitle = state.monthsData[0].title;
|
|
7691
|
-
}
|
|
7692
|
-
}
|
|
7693
|
-
}
|
|
7694
|
-
});
|
|
7695
|
-
};
|
|
7696
|
-
const setTransform = (translateY = 0, type, time = 1e3) => {
|
|
7697
|
-
if (monthsPanel == null ? void 0 : monthsPanel.value) {
|
|
7698
|
-
if (type === "end") {
|
|
7699
|
-
monthsPanel.value.style.webkitTransition = `transform ${time}ms cubic-bezier(0.19, 1, 0.22, 1)`;
|
|
7700
|
-
clearTimeout(state.timer);
|
|
7701
|
-
state.timer = setTimeout(() => {
|
|
7702
|
-
loadScroll();
|
|
7703
|
-
}, time);
|
|
7704
|
-
} else {
|
|
7705
|
-
monthsPanel.value.style.webkitTransition = "";
|
|
7706
|
-
loadScroll();
|
|
7707
|
-
}
|
|
7708
|
-
monthsPanel.value.style.webkitTransform = `translateY(${translateY}px)`;
|
|
7709
|
-
state.scrollDistance = translateY;
|
|
7710
|
-
}
|
|
7711
|
-
};
|
|
7712
|
-
const setMove = (move, type, time) => {
|
|
7713
|
-
var _a, _b;
|
|
7714
|
-
let updateMove = move + state.transformY;
|
|
7715
|
-
const h = ((_a = months.value) == null ? void 0 : _a.offsetHeight) || 0;
|
|
7716
|
-
const offsetHeight = ((_b = monthsPanel.value) == null ? void 0 : _b.offsetHeight) || 0;
|
|
7717
|
-
if (type === "end") {
|
|
7718
|
-
if (updateMove > 0) {
|
|
7719
|
-
updateMove = 0;
|
|
8607
|
+
const mothsViewScroll = (e) => {
|
|
8608
|
+
var currentScrollTop = e.target.scrollTop;
|
|
8609
|
+
let current = Math.floor(currentScrollTop / state.avgHeight);
|
|
8610
|
+
if (current == 0) {
|
|
8611
|
+
if (currentScrollTop >= state.monthsData[current + 1].cssScrollHeight) {
|
|
8612
|
+
current += 1;
|
|
7720
8613
|
}
|
|
7721
|
-
|
|
7722
|
-
|
|
8614
|
+
} else if (current > 0 && current < state.monthsNum - 1) {
|
|
8615
|
+
if (currentScrollTop >= state.monthsData[current + 1].cssScrollHeight) {
|
|
8616
|
+
current += 1;
|
|
7723
8617
|
}
|
|
7724
|
-
if (
|
|
7725
|
-
|
|
8618
|
+
if (currentScrollTop < state.monthsData[current].cssScrollHeight) {
|
|
8619
|
+
current -= 1;
|
|
7726
8620
|
}
|
|
7727
|
-
setTransform(updateMove, type, time);
|
|
7728
8621
|
} else {
|
|
7729
|
-
if (
|
|
7730
|
-
|
|
7731
|
-
}
|
|
7732
|
-
if (updateMove < -offsetHeight + h - 100 && state.monthsData.length > 1) {
|
|
7733
|
-
updateMove = -offsetHeight + h - 100;
|
|
8622
|
+
if (currentScrollTop + viewHeight.value < state.monthsData[current].cssScrollHeight + state.monthsData[current].cssHeight) {
|
|
8623
|
+
current -= 1;
|
|
7734
8624
|
}
|
|
7735
|
-
if (
|
|
7736
|
-
|
|
8625
|
+
if (current + 1 <= state.monthsNum && currentScrollTop + viewHeight.value >= state.monthsData[current + 1].cssScrollHeight + state.monthsData[current + 1].cssHeight) {
|
|
8626
|
+
current += 1;
|
|
7737
8627
|
}
|
|
7738
|
-
|
|
7739
|
-
|
|
7740
|
-
};
|
|
7741
|
-
const touchStart = (event) => {
|
|
7742
|
-
const changedTouches = event.changedTouches[0];
|
|
7743
|
-
state.touchParams.startY = changedTouches.pageY;
|
|
7744
|
-
state.touchParams.startTime = event.timeStamp || Date.now();
|
|
7745
|
-
state.transformY = state.scrollDistance;
|
|
7746
|
-
};
|
|
7747
|
-
const touchMove = (event) => {
|
|
7748
|
-
const changedTouches = event.changedTouches[0];
|
|
7749
|
-
state.touchParams.lastY = changedTouches.pageY;
|
|
7750
|
-
state.touchParams.lastTime = event.timeStamp || Date.now();
|
|
7751
|
-
const move = state.touchParams.lastY - state.touchParams.startY;
|
|
7752
|
-
if (Math.abs(move) < 5) {
|
|
7753
|
-
return false;
|
|
7754
|
-
}
|
|
7755
|
-
setMove(move);
|
|
7756
|
-
};
|
|
7757
|
-
const touchEnd = (event) => {
|
|
7758
|
-
var _a, _b;
|
|
7759
|
-
const changedTouches = event.changedTouches[0];
|
|
7760
|
-
state.touchParams.lastY = changedTouches.pageY;
|
|
7761
|
-
state.touchParams.lastTime = event.timeStamp || Date.now();
|
|
7762
|
-
let move = state.touchParams.lastY - state.touchParams.startY;
|
|
7763
|
-
if (Math.abs(move) < 5) {
|
|
7764
|
-
return false;
|
|
7765
|
-
}
|
|
7766
|
-
const updateMove = move + state.transformY;
|
|
7767
|
-
const h = ((_a = months.value) == null ? void 0 : _a.offsetHeight) || 0;
|
|
7768
|
-
const offsetHeight = ((_b = monthsPanel.value) == null ? void 0 : _b.offsetHeight) || 0;
|
|
7769
|
-
if (updateMove > 0) {
|
|
7770
|
-
getMonth(getCurrData("prev"), "prev");
|
|
7771
|
-
} else if (updateMove < 0 && updateMove < -offsetHeight + (Math.abs(move) > h ? Math.abs(move) : h) * 5) {
|
|
7772
|
-
getMonth(getCurrData("next"), "next");
|
|
7773
|
-
if (Math.abs(move) >= 300) {
|
|
7774
|
-
getMonth(getCurrData("next"), "next");
|
|
8628
|
+
if (currentScrollTop < state.monthsData[current - 1].cssScrollHeight) {
|
|
8629
|
+
current -= 1;
|
|
7775
8630
|
}
|
|
7776
8631
|
}
|
|
7777
|
-
|
|
7778
|
-
|
|
7779
|
-
|
|
7780
|
-
moveTime = moveTime + 1e3;
|
|
7781
|
-
setMove(move, "end", moveTime);
|
|
7782
|
-
} else {
|
|
7783
|
-
setMove(move, "end");
|
|
8632
|
+
if (state.currentIndex !== current) {
|
|
8633
|
+
state.currentIndex = current;
|
|
8634
|
+
setDefaultRange(state.monthsNum, current);
|
|
7784
8635
|
}
|
|
8636
|
+
state.yearMonthTitle = state.monthsData[current].title;
|
|
7785
8637
|
};
|
|
7786
8638
|
const resetRender = () => {
|
|
7787
8639
|
state.chooseData.splice(0);
|
|
7788
8640
|
state.monthsData.splice(0);
|
|
7789
|
-
state.scrollDistance = 0;
|
|
7790
|
-
state.translateY = 0;
|
|
7791
|
-
setTransform(state.scrollDistance);
|
|
7792
8641
|
initData();
|
|
7793
8642
|
};
|
|
7794
8643
|
initData();
|
|
7795
8644
|
vue.watch(() => props.defaultValue, (val) => {
|
|
7796
8645
|
if (val) {
|
|
7797
|
-
|
|
8646
|
+
if (props.poppable) {
|
|
8647
|
+
resetRender();
|
|
8648
|
+
}
|
|
7798
8649
|
}
|
|
7799
8650
|
});
|
|
7800
8651
|
return __spreadValues(__spreadValues({
|
|
7801
8652
|
weeks,
|
|
7802
|
-
|
|
7803
|
-
|
|
7804
|
-
|
|
8653
|
+
compConthsData,
|
|
8654
|
+
showTopBtn,
|
|
8655
|
+
topInfo,
|
|
8656
|
+
bottomInfo,
|
|
8657
|
+
rangeTip,
|
|
8658
|
+
mothsViewScroll,
|
|
7805
8659
|
getClass,
|
|
7806
8660
|
isStartTip,
|
|
7807
8661
|
isEndTip,
|
|
@@ -7810,38 +8664,52 @@ var __publicField = (obj, key, value) => {
|
|
|
7810
8664
|
confirm,
|
|
7811
8665
|
monthsPanel,
|
|
7812
8666
|
months,
|
|
7813
|
-
weeksPanel
|
|
8667
|
+
weeksPanel,
|
|
8668
|
+
viewArea
|
|
7814
8669
|
}, vue.toRefs(state)), vue.toRefs(props));
|
|
7815
8670
|
}
|
|
7816
8671
|
});
|
|
7817
|
-
const _hoisted_1$t = {
|
|
7818
|
-
|
|
8672
|
+
const _hoisted_1$t = {
|
|
8673
|
+
key: 0,
|
|
8674
|
+
class: "calendar-title"
|
|
8675
|
+
};
|
|
8676
|
+
const _hoisted_2$o = {
|
|
8677
|
+
key: 1,
|
|
8678
|
+
class: "calendar-top-slot"
|
|
8679
|
+
};
|
|
7819
8680
|
const _hoisted_3$k = {
|
|
8681
|
+
key: 2,
|
|
8682
|
+
class: "calendar-curr-month"
|
|
8683
|
+
};
|
|
8684
|
+
const _hoisted_4$f = {
|
|
7820
8685
|
class: "calendar-weeks",
|
|
7821
8686
|
ref: "weeksPanel"
|
|
7822
8687
|
};
|
|
7823
|
-
const
|
|
8688
|
+
const _hoisted_5$a = {
|
|
7824
8689
|
class: "calendar-months-panel",
|
|
7825
8690
|
ref: "monthsPanel"
|
|
7826
8691
|
};
|
|
7827
|
-
const _hoisted_5$a = { class: "calendar-loading-tip" };
|
|
7828
8692
|
const _hoisted_6$8 = { class: "calendar-month-title" };
|
|
7829
8693
|
const _hoisted_7$7 = { class: "calendar-month-con" };
|
|
7830
8694
|
const _hoisted_8$7 = ["onClick"];
|
|
7831
8695
|
const _hoisted_9$5 = { class: "calendar-day" };
|
|
7832
8696
|
const _hoisted_10$3 = {
|
|
7833
8697
|
key: 0,
|
|
7834
|
-
class: "calendar-curr-tips"
|
|
8698
|
+
class: "calendar-curr-tips calendar-curr-tips-top"
|
|
7835
8699
|
};
|
|
7836
8700
|
const _hoisted_11$3 = {
|
|
7837
8701
|
key: 1,
|
|
7838
|
-
class: "calendar-
|
|
8702
|
+
class: "calendar-curr-tips calendar-curr-tips-bottom"
|
|
7839
8703
|
};
|
|
7840
8704
|
const _hoisted_12$3 = {
|
|
7841
8705
|
key: 2,
|
|
7842
|
-
class: "calendar-
|
|
8706
|
+
class: "calendar-curr-tip-curr"
|
|
7843
8707
|
};
|
|
7844
8708
|
const _hoisted_13$2 = {
|
|
8709
|
+
key: 4,
|
|
8710
|
+
class: "calendar-day-tip"
|
|
8711
|
+
};
|
|
8712
|
+
const _hoisted_14$2 = {
|
|
7845
8713
|
key: 0,
|
|
7846
8714
|
class: "nut-calendar-footer"
|
|
7847
8715
|
};
|
|
@@ -7855,11 +8723,12 @@ var __publicField = (obj, key, value) => {
|
|
|
7855
8723
|
vue.createElementVNode("view", {
|
|
7856
8724
|
class: vue.normalizeClass(["nut-calendar-header", { "nut-calendar-header-tile": !_ctx.poppable }])
|
|
7857
8725
|
}, [
|
|
7858
|
-
_ctx.
|
|
7859
|
-
|
|
7860
|
-
vue.
|
|
7861
|
-
]
|
|
7862
|
-
vue.
|
|
8726
|
+
_ctx.showTitle ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$t, vue.toDisplayString(_ctx.title), 1)) : vue.createCommentVNode("", true),
|
|
8727
|
+
_ctx.showTopBtn ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$o, [
|
|
8728
|
+
vue.renderSlot(_ctx.$slots, "btn")
|
|
8729
|
+
])) : vue.createCommentVNode("", true),
|
|
8730
|
+
_ctx.showSubTitle ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$k, vue.toDisplayString(_ctx.yearMonthTitle), 1)) : vue.createCommentVNode("", true),
|
|
8731
|
+
vue.createElementVNode("view", _hoisted_4$f, [
|
|
7863
8732
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.weeks, (item, index) => {
|
|
7864
8733
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
7865
8734
|
class: "calendar-week-item",
|
|
@@ -7871,44 +8740,67 @@ var __publicField = (obj, key, value) => {
|
|
|
7871
8740
|
vue.createElementVNode("view", {
|
|
7872
8741
|
class: "nut-calendar-content",
|
|
7873
8742
|
ref: "months",
|
|
7874
|
-
|
|
7875
|
-
onTouchmove: _cache[1] || (_cache[1] = vue.withModifiers((...args) => _ctx.touchMove && _ctx.touchMove(...args), ["stop", "prevent"])),
|
|
7876
|
-
onTouchend: _cache[2] || (_cache[2] = vue.withModifiers((...args) => _ctx.touchEnd && _ctx.touchEnd(...args), ["stop"]))
|
|
8743
|
+
onScroll: _cache[0] || (_cache[0] = (...args) => _ctx.mothsViewScroll && _ctx.mothsViewScroll(...args))
|
|
7877
8744
|
}, [
|
|
7878
|
-
vue.createElementVNode("view",
|
|
7879
|
-
vue.createElementVNode("view",
|
|
7880
|
-
|
|
7881
|
-
|
|
7882
|
-
|
|
7883
|
-
|
|
7884
|
-
|
|
7885
|
-
vue.
|
|
7886
|
-
|
|
7887
|
-
|
|
7888
|
-
|
|
7889
|
-
|
|
7890
|
-
|
|
7891
|
-
|
|
7892
|
-
|
|
7893
|
-
|
|
7894
|
-
|
|
7895
|
-
|
|
7896
|
-
|
|
7897
|
-
|
|
7898
|
-
|
|
7899
|
-
|
|
7900
|
-
|
|
7901
|
-
|
|
7902
|
-
|
|
7903
|
-
|
|
7904
|
-
|
|
8745
|
+
vue.createElementVNode("view", _hoisted_5$a, [
|
|
8746
|
+
vue.createElementVNode("view", {
|
|
8747
|
+
class: "viewArea",
|
|
8748
|
+
ref: "viewArea",
|
|
8749
|
+
style: vue.normalizeStyle({ transform: `translateY(${_ctx.translateY}px)` })
|
|
8750
|
+
}, [
|
|
8751
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.compConthsData, (month, index) => {
|
|
8752
|
+
return vue.openBlock(), vue.createElementBlock("view", {
|
|
8753
|
+
class: "calendar-month",
|
|
8754
|
+
key: index
|
|
8755
|
+
}, [
|
|
8756
|
+
vue.createElementVNode("view", _hoisted_6$8, vue.toDisplayString(month.title), 1),
|
|
8757
|
+
vue.createElementVNode("view", _hoisted_7$7, [
|
|
8758
|
+
vue.createElementVNode("view", {
|
|
8759
|
+
class: vue.normalizeClass(["calendar-month-item", _ctx.type === "range" ? "month-item-range" : ""])
|
|
8760
|
+
}, [
|
|
8761
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(month.monthData, (day, i) => {
|
|
8762
|
+
return vue.openBlock(), vue.createElementBlock("view", {
|
|
8763
|
+
key: i,
|
|
8764
|
+
class: vue.normalizeClass(["calendar-month-day", _ctx.getClass(day, month)]),
|
|
8765
|
+
onClick: ($event) => _ctx.chooseDay(day, month)
|
|
8766
|
+
}, [
|
|
8767
|
+
vue.createElementVNode("view", _hoisted_9$5, [
|
|
8768
|
+
vue.renderSlot(_ctx.$slots, "day", {
|
|
8769
|
+
date: day.type == "curr" ? day : ""
|
|
8770
|
+
}, () => [
|
|
8771
|
+
vue.createTextVNode(vue.toDisplayString(day.type == "curr" ? day.day : ""), 1)
|
|
8772
|
+
])
|
|
8773
|
+
]),
|
|
8774
|
+
_ctx.topInfo ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_10$3, [
|
|
8775
|
+
vue.renderSlot(_ctx.$slots, "topInfo", {
|
|
8776
|
+
date: day.type == "curr" ? day : ""
|
|
8777
|
+
})
|
|
8778
|
+
])) : vue.createCommentVNode("", true),
|
|
8779
|
+
_ctx.bottomInfo ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_11$3, [
|
|
8780
|
+
vue.renderSlot(_ctx.$slots, "bottomInfo", {
|
|
8781
|
+
date: day.type == "curr" ? day : ""
|
|
8782
|
+
})
|
|
8783
|
+
])) : vue.createCommentVNode("", true),
|
|
8784
|
+
!_ctx.bottomInfo && _ctx.showToday && _ctx.isCurrDay(month, day.day) ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_12$3, " \u4ECA\u5929 ")) : vue.createCommentVNode("", true),
|
|
8785
|
+
_ctx.isStartTip(day, month) ? (vue.openBlock(), vue.createElementBlock("view", {
|
|
8786
|
+
key: 3,
|
|
8787
|
+
class: vue.normalizeClass(["calendar-day-tip", { "calendar-curr-tips-top": _ctx.rangeTip(day, month) }])
|
|
8788
|
+
}, vue.toDisplayString(_ctx.startText), 3)) : vue.createCommentVNode("", true),
|
|
8789
|
+
_ctx.isEndTip(day, month) ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_13$2, vue.toDisplayString(_ctx.endText), 1)) : vue.createCommentVNode("", true)
|
|
8790
|
+
], 10, _hoisted_8$7);
|
|
8791
|
+
}), 128))
|
|
8792
|
+
], 2)
|
|
8793
|
+
])
|
|
8794
|
+
]);
|
|
8795
|
+
}), 128))
|
|
8796
|
+
], 4)
|
|
7905
8797
|
], 512)
|
|
7906
8798
|
], 544),
|
|
7907
|
-
_ctx.poppable && !_ctx.isAutoBackFill ? (vue.openBlock(), vue.createElementBlock("view",
|
|
8799
|
+
_ctx.poppable && !_ctx.isAutoBackFill ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_14$2, [
|
|
7908
8800
|
vue.createElementVNode("view", {
|
|
7909
8801
|
class: "calendar-confirm-btn",
|
|
7910
|
-
onClick: _cache[
|
|
7911
|
-
},
|
|
8802
|
+
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.confirm && _ctx.confirm(...args))
|
|
8803
|
+
}, vue.toDisplayString(_ctx.confirmText), 1)
|
|
7912
8804
|
])) : vue.createCommentVNode("", true)
|
|
7913
8805
|
], 2);
|
|
7914
8806
|
}
|
|
@@ -7931,16 +8823,40 @@ var __publicField = (obj, key, value) => {
|
|
|
7931
8823
|
type: Boolean,
|
|
7932
8824
|
default: true
|
|
7933
8825
|
},
|
|
8826
|
+
showTitle: {
|
|
8827
|
+
type: Boolean,
|
|
8828
|
+
default: true
|
|
8829
|
+
},
|
|
8830
|
+
showSubTitle: {
|
|
8831
|
+
type: Boolean,
|
|
8832
|
+
default: true
|
|
8833
|
+
},
|
|
7934
8834
|
visible: {
|
|
7935
8835
|
type: Boolean,
|
|
7936
8836
|
default: false
|
|
7937
8837
|
},
|
|
8838
|
+
showToday: {
|
|
8839
|
+
type: Boolean,
|
|
8840
|
+
default: true
|
|
8841
|
+
},
|
|
7938
8842
|
title: {
|
|
7939
8843
|
type: String,
|
|
7940
8844
|
default: "\u65E5\u5386\u9009\u62E9"
|
|
7941
8845
|
},
|
|
8846
|
+
confirmText: {
|
|
8847
|
+
type: String,
|
|
8848
|
+
default: "\u786E\u8BA4"
|
|
8849
|
+
},
|
|
8850
|
+
startText: {
|
|
8851
|
+
type: String,
|
|
8852
|
+
default: "\u5F00\u59CB"
|
|
8853
|
+
},
|
|
8854
|
+
endText: {
|
|
8855
|
+
type: String,
|
|
8856
|
+
default: "\u7ED3\u675F"
|
|
8857
|
+
},
|
|
7942
8858
|
defaultValue: {
|
|
7943
|
-
type: String
|
|
8859
|
+
type: [String, Array]
|
|
7944
8860
|
},
|
|
7945
8861
|
startDate: {
|
|
7946
8862
|
type: String,
|
|
@@ -7951,8 +8867,20 @@ var __publicField = (obj, key, value) => {
|
|
|
7951
8867
|
default: Utils.getDay(365)
|
|
7952
8868
|
}
|
|
7953
8869
|
},
|
|
7954
|
-
emits: ["choose", "close", "update:visible"],
|
|
7955
|
-
setup(props, { emit }) {
|
|
8870
|
+
emits: ["choose", "close", "update:visible", "select"],
|
|
8871
|
+
setup(props, { emit, slots }) {
|
|
8872
|
+
const showTopBtn = vue.computed(() => {
|
|
8873
|
+
return slots.btn;
|
|
8874
|
+
});
|
|
8875
|
+
const topInfo = vue.computed(() => {
|
|
8876
|
+
return slots.topInfo;
|
|
8877
|
+
});
|
|
8878
|
+
const dayInfo = vue.computed(() => {
|
|
8879
|
+
return slots.day;
|
|
8880
|
+
});
|
|
8881
|
+
const bottomInfo = vue.computed(() => {
|
|
8882
|
+
return slots.bottomInfo;
|
|
8883
|
+
});
|
|
7956
8884
|
const calendarRef = vue.ref(null);
|
|
7957
8885
|
const update = () => {
|
|
7958
8886
|
emit("update:visible", false);
|
|
@@ -7965,6 +8893,9 @@ var __publicField = (obj, key, value) => {
|
|
|
7965
8893
|
close();
|
|
7966
8894
|
emit("choose", param);
|
|
7967
8895
|
};
|
|
8896
|
+
const select = (param) => {
|
|
8897
|
+
emit("select", param);
|
|
8898
|
+
};
|
|
7968
8899
|
const closePopup = () => {
|
|
7969
8900
|
close();
|
|
7970
8901
|
};
|
|
@@ -7973,7 +8904,12 @@ var __publicField = (obj, key, value) => {
|
|
|
7973
8904
|
update,
|
|
7974
8905
|
close,
|
|
7975
8906
|
choose,
|
|
7976
|
-
|
|
8907
|
+
select,
|
|
8908
|
+
calendarRef,
|
|
8909
|
+
showTopBtn,
|
|
8910
|
+
topInfo,
|
|
8911
|
+
dayInfo,
|
|
8912
|
+
bottomInfo
|
|
7977
8913
|
};
|
|
7978
8914
|
}
|
|
7979
8915
|
});
|
|
@@ -7987,43 +8923,121 @@ var __publicField = (obj, key, value) => {
|
|
|
7987
8923
|
round: "",
|
|
7988
8924
|
closeable: true,
|
|
7989
8925
|
onClickOverlay: _ctx.closePopup,
|
|
7990
|
-
onClickCloseIcon: _ctx.closePopup
|
|
8926
|
+
onClickCloseIcon: _ctx.closePopup,
|
|
8927
|
+
"destroy-on-close": true,
|
|
8928
|
+
style: { height: "85vh" }
|
|
7991
8929
|
}, {
|
|
7992
8930
|
default: vue.withCtx(() => [
|
|
7993
|
-
vue.
|
|
8931
|
+
_ctx.visible ? (vue.openBlock(), vue.createBlock(_component_nut_calendar_item, {
|
|
8932
|
+
key: 0,
|
|
7994
8933
|
props: "",
|
|
7995
8934
|
ref: "calendarRef",
|
|
7996
8935
|
type: _ctx.type,
|
|
7997
8936
|
"is-auto-back-fill": _ctx.isAutoBackFill,
|
|
7998
8937
|
poppable: _ctx.poppable,
|
|
7999
8938
|
title: _ctx.title,
|
|
8939
|
+
"confirm-text": _ctx.confirmText,
|
|
8940
|
+
"start-text": _ctx.startText,
|
|
8941
|
+
"end-text": _ctx.endText,
|
|
8000
8942
|
"default-value": _ctx.defaultValue,
|
|
8943
|
+
"show-today": _ctx.showToday,
|
|
8001
8944
|
"start-date": _ctx.startDate,
|
|
8002
8945
|
"end-date": _ctx.endDate,
|
|
8003
8946
|
onUpdate: _ctx.update,
|
|
8004
8947
|
onClose: _ctx.close,
|
|
8005
|
-
onChoose: _ctx.choose
|
|
8006
|
-
|
|
8948
|
+
onChoose: _ctx.choose,
|
|
8949
|
+
onSelect: _ctx.select,
|
|
8950
|
+
"show-title": _ctx.showTitle,
|
|
8951
|
+
"show-sub-title": _ctx.showSubTitle
|
|
8952
|
+
}, vue.createSlots({ _: 2 }, [
|
|
8953
|
+
_ctx.showTopBtn ? {
|
|
8954
|
+
name: "btn",
|
|
8955
|
+
fn: vue.withCtx(() => [
|
|
8956
|
+
vue.renderSlot(_ctx.$slots, "btn")
|
|
8957
|
+
])
|
|
8958
|
+
} : void 0,
|
|
8959
|
+
_ctx.dayInfo ? {
|
|
8960
|
+
name: "day",
|
|
8961
|
+
fn: vue.withCtx((date) => [
|
|
8962
|
+
vue.renderSlot(_ctx.$slots, "day", {
|
|
8963
|
+
date: date.date
|
|
8964
|
+
})
|
|
8965
|
+
])
|
|
8966
|
+
} : void 0,
|
|
8967
|
+
_ctx.topInfo ? {
|
|
8968
|
+
name: "topInfo",
|
|
8969
|
+
fn: vue.withCtx((date) => [
|
|
8970
|
+
vue.renderSlot(_ctx.$slots, "topInfo", {
|
|
8971
|
+
date: date.date
|
|
8972
|
+
})
|
|
8973
|
+
])
|
|
8974
|
+
} : void 0,
|
|
8975
|
+
_ctx.bottomInfo ? {
|
|
8976
|
+
name: "bottomInfo",
|
|
8977
|
+
fn: vue.withCtx((date) => [
|
|
8978
|
+
vue.renderSlot(_ctx.$slots, "bottomInfo", {
|
|
8979
|
+
date: date.date
|
|
8980
|
+
})
|
|
8981
|
+
])
|
|
8982
|
+
} : void 0
|
|
8983
|
+
]), 1032, ["type", "is-auto-back-fill", "poppable", "title", "confirm-text", "start-text", "end-text", "default-value", "show-today", "start-date", "end-date", "onUpdate", "onClose", "onChoose", "onSelect", "show-title", "show-sub-title"])) : vue.createCommentVNode("", true)
|
|
8007
8984
|
]),
|
|
8008
|
-
_:
|
|
8985
|
+
_: 3
|
|
8009
8986
|
}, 8, ["visible", "onClickOverlay", "onClickCloseIcon"])) : (vue.openBlock(), vue.createBlock(_component_nut_calendar_item, {
|
|
8010
8987
|
key: 1,
|
|
8011
8988
|
type: _ctx.type,
|
|
8012
8989
|
"is-auto-back-fill": _ctx.isAutoBackFill,
|
|
8013
8990
|
poppable: _ctx.poppable,
|
|
8014
8991
|
title: _ctx.title,
|
|
8992
|
+
"confirm-text": _ctx.confirmText,
|
|
8993
|
+
"start-text": _ctx.startText,
|
|
8994
|
+
"end-text": _ctx.endText,
|
|
8015
8995
|
"default-value": _ctx.defaultValue,
|
|
8016
8996
|
"start-date": _ctx.startDate,
|
|
8017
8997
|
"end-date": _ctx.endDate,
|
|
8018
8998
|
onClose: _ctx.close,
|
|
8019
|
-
onChoose: _ctx.choose
|
|
8020
|
-
|
|
8999
|
+
onChoose: _ctx.choose,
|
|
9000
|
+
onSelect: _ctx.select,
|
|
9001
|
+
"show-title": _ctx.showTitle,
|
|
9002
|
+
"show-sub-title": _ctx.showSubTitle
|
|
9003
|
+
}, vue.createSlots({ _: 2 }, [
|
|
9004
|
+
_ctx.showTopBtn ? {
|
|
9005
|
+
name: "btn",
|
|
9006
|
+
fn: vue.withCtx(() => [
|
|
9007
|
+
vue.renderSlot(_ctx.$slots, "btn")
|
|
9008
|
+
])
|
|
9009
|
+
} : void 0,
|
|
9010
|
+
_ctx.dayInfo ? {
|
|
9011
|
+
name: "day",
|
|
9012
|
+
fn: vue.withCtx((date) => [
|
|
9013
|
+
vue.renderSlot(_ctx.$slots, "day", {
|
|
9014
|
+
date: date.date
|
|
9015
|
+
})
|
|
9016
|
+
])
|
|
9017
|
+
} : void 0,
|
|
9018
|
+
_ctx.topInfo ? {
|
|
9019
|
+
name: "topInfo",
|
|
9020
|
+
fn: vue.withCtx((date) => [
|
|
9021
|
+
vue.renderSlot(_ctx.$slots, "topInfo", {
|
|
9022
|
+
date: date.date
|
|
9023
|
+
})
|
|
9024
|
+
])
|
|
9025
|
+
} : void 0,
|
|
9026
|
+
_ctx.bottomInfo ? {
|
|
9027
|
+
name: "bottomInfo",
|
|
9028
|
+
fn: vue.withCtx((date) => [
|
|
9029
|
+
vue.renderSlot(_ctx.$slots, "bottomInfo", {
|
|
9030
|
+
date: date.date
|
|
9031
|
+
})
|
|
9032
|
+
])
|
|
9033
|
+
} : void 0
|
|
9034
|
+
]), 1032, ["type", "is-auto-back-fill", "poppable", "title", "confirm-text", "start-text", "end-text", "default-value", "start-date", "end-date", "onClose", "onChoose", "onSelect", "show-title", "show-sub-title"]));
|
|
8021
9035
|
}
|
|
8022
9036
|
var Calendar = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["render", _sfc_render$x]]);
|
|
8023
9037
|
const { create: create$A, componentName: componentName$r } = createComponent("checkbox");
|
|
8024
9038
|
const _sfc_main$A = create$A({
|
|
8025
9039
|
components: {
|
|
8026
|
-
nutIcon: _sfc_main$
|
|
9040
|
+
nutIcon: _sfc_main$1s
|
|
8027
9041
|
},
|
|
8028
9042
|
props: {
|
|
8029
9043
|
modelValue: {
|
|
@@ -8057,7 +9071,7 @@ var __publicField = (obj, key, value) => {
|
|
|
8057
9071
|
},
|
|
8058
9072
|
emits: ["change", "update:modelValue"],
|
|
8059
9073
|
setup(props, { emit, slots }) {
|
|
8060
|
-
const parent = vue.inject("parent");
|
|
9074
|
+
const parent = vue.inject("parent", null);
|
|
8061
9075
|
const hasParent = vue.computed(() => !!parent);
|
|
8062
9076
|
const pValue = vue.computed(() => {
|
|
8063
9077
|
if (hasParent.value) {
|
|
@@ -8079,7 +9093,7 @@ var __publicField = (obj, key, value) => {
|
|
|
8079
9093
|
};
|
|
8080
9094
|
const renderIcon = () => {
|
|
8081
9095
|
const { iconName, iconSize, iconActiveName } = props;
|
|
8082
|
-
return vue.h(_sfc_main$
|
|
9096
|
+
return vue.h(_sfc_main$1s, {
|
|
8083
9097
|
name: !pValue.value ? iconName : iconActiveName,
|
|
8084
9098
|
size: iconSize,
|
|
8085
9099
|
class: color.value
|
|
@@ -8163,7 +9177,7 @@ var __publicField = (obj, key, value) => {
|
|
|
8163
9177
|
vue.watch(() => props.modelValue, (value) => {
|
|
8164
9178
|
emit("change", value);
|
|
8165
9179
|
});
|
|
8166
|
-
useExpose
|
|
9180
|
+
useExpose({ toggleAll });
|
|
8167
9181
|
return () => {
|
|
8168
9182
|
var _a;
|
|
8169
9183
|
return vue.h("view", {
|
|
@@ -8446,6 +9460,7 @@ var __publicField = (obj, key, value) => {
|
|
|
8446
9460
|
return "text";
|
|
8447
9461
|
});
|
|
8448
9462
|
const columnList = vue.computed(() => {
|
|
9463
|
+
console.log("\u521D\u59CB\u5316", dataType.value);
|
|
8449
9464
|
if (dataType.value === "text") {
|
|
8450
9465
|
return [{ values: state.formattedColumns, defaultIndex: state.defaultIndex }];
|
|
8451
9466
|
} else if (dataType.value === "multipleColumns") {
|
|
@@ -8811,7 +9826,6 @@ var __publicField = (obj, key, value) => {
|
|
|
8811
9826
|
return 0;
|
|
8812
9827
|
};
|
|
8813
9828
|
const columns = vue.computed(() => {
|
|
8814
|
-
console.log(ranges.value);
|
|
8815
9829
|
const val = ranges.value.map((res) => {
|
|
8816
9830
|
return generateValue(res.range[0], res.range[1], getDateIndex(res.type), res.type);
|
|
8817
9831
|
});
|
|
@@ -9091,6 +10105,9 @@ var __publicField = (obj, key, value) => {
|
|
|
9091
10105
|
[`${prefixCls}-border`]: props.hasBorder
|
|
9092
10106
|
};
|
|
9093
10107
|
});
|
|
10108
|
+
const inputmode = vue.computed(() => {
|
|
10109
|
+
return props.type === "digit" ? "decimal" : props.type === "number" ? "numeric" : "text";
|
|
10110
|
+
});
|
|
9094
10111
|
const styles = vue.computed(() => {
|
|
9095
10112
|
return {
|
|
9096
10113
|
textAlign: props.textAlign
|
|
@@ -9137,6 +10154,7 @@ var __publicField = (obj, key, value) => {
|
|
|
9137
10154
|
active,
|
|
9138
10155
|
classes,
|
|
9139
10156
|
styles,
|
|
10157
|
+
inputmode,
|
|
9140
10158
|
valueChange,
|
|
9141
10159
|
valueFocus,
|
|
9142
10160
|
valueBlur,
|
|
@@ -9149,7 +10167,7 @@ var __publicField = (obj, key, value) => {
|
|
|
9149
10167
|
class: "nut-input-label"
|
|
9150
10168
|
};
|
|
9151
10169
|
const _hoisted_2$l = { class: "label-string" };
|
|
9152
|
-
const _hoisted_3$i = ["type", "maxlength", "placeholder", "disabled", "readonly", "value"];
|
|
10170
|
+
const _hoisted_3$i = ["type", "maxlength", "placeholder", "disabled", "readonly", "value", "inputmode"];
|
|
9153
10171
|
function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
|
|
9154
10172
|
const _component_nut_icon = vue.resolveComponent("nut-icon");
|
|
9155
10173
|
return vue.openBlock(), vue.createElementBlock("view", {
|
|
@@ -9167,6 +10185,7 @@ var __publicField = (obj, key, value) => {
|
|
|
9167
10185
|
disabled: _ctx.disabled,
|
|
9168
10186
|
readonly: _ctx.readonly,
|
|
9169
10187
|
value: _ctx.modelValue,
|
|
10188
|
+
inputmode: _ctx.inputmode,
|
|
9170
10189
|
onInput: _cache[0] || (_cache[0] = (...args) => _ctx.valueChange && _ctx.valueChange(...args)),
|
|
9171
10190
|
onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.valueFocus && _ctx.valueFocus(...args)),
|
|
9172
10191
|
onBlur: _cache[2] || (_cache[2] = (...args) => _ctx.valueBlur && _ctx.valueBlur(...args))
|
|
@@ -9215,7 +10234,7 @@ var __publicField = (obj, key, value) => {
|
|
|
9215
10234
|
}
|
|
9216
10235
|
},
|
|
9217
10236
|
setup(props, { emit, slots }) {
|
|
9218
|
-
let parent = vue.inject("parent");
|
|
10237
|
+
let parent = vue.inject("parent", null);
|
|
9219
10238
|
const isCurValue = vue.computed(() => {
|
|
9220
10239
|
return parent.label.value == props.label;
|
|
9221
10240
|
});
|
|
@@ -9227,7 +10246,7 @@ var __publicField = (obj, key, value) => {
|
|
|
9227
10246
|
});
|
|
9228
10247
|
const renderIcon = () => {
|
|
9229
10248
|
const { iconName, iconSize, iconActiveName } = props;
|
|
9230
|
-
return vue.h(_sfc_main$
|
|
10249
|
+
return vue.h(_sfc_main$1s, {
|
|
9231
10250
|
name: isCurValue.value ? iconActiveName : iconName,
|
|
9232
10251
|
size: iconSize,
|
|
9233
10252
|
class: color.value
|
|
@@ -9465,6 +10484,10 @@ var __publicField = (obj, key, value) => {
|
|
|
9465
10484
|
length: {
|
|
9466
10485
|
type: [String, Number],
|
|
9467
10486
|
default: 6
|
|
10487
|
+
},
|
|
10488
|
+
isWrapTeleport: {
|
|
10489
|
+
type: Boolean,
|
|
10490
|
+
default: true
|
|
9468
10491
|
}
|
|
9469
10492
|
},
|
|
9470
10493
|
emits: ["update:modelValue", "update:visible", "complete", "change", "ok", "tips", "close", "cancel"],
|
|
@@ -9484,7 +10507,10 @@ var __publicField = (obj, key, value) => {
|
|
|
9484
10507
|
});
|
|
9485
10508
|
vue.watch(() => props.modelValue, (value) => {
|
|
9486
10509
|
realInput.value = value;
|
|
9487
|
-
|
|
10510
|
+
emit("update:modelValue", value);
|
|
10511
|
+
}, {
|
|
10512
|
+
deep: true,
|
|
10513
|
+
immediate: true
|
|
9488
10514
|
});
|
|
9489
10515
|
function changeValue(e) {
|
|
9490
10516
|
const input = e.target;
|
|
@@ -9578,7 +10604,8 @@ var __publicField = (obj, key, value) => {
|
|
|
9578
10604
|
closeable: true,
|
|
9579
10605
|
onClickCloseIcon: _ctx.closeIcon,
|
|
9580
10606
|
"close-on-click-overlay": _ctx.closeOnClickOverlay,
|
|
9581
|
-
onClickOverlay: _ctx.close
|
|
10607
|
+
onClickOverlay: _ctx.close,
|
|
10608
|
+
isWrapTeleport: _ctx.isWrapTeleport
|
|
9582
10609
|
}, {
|
|
9583
10610
|
default: vue.withCtx(() => [
|
|
9584
10611
|
vue.createElementVNode("view", _hoisted_1$n, vue.toDisplayString(_ctx.title), 1),
|
|
@@ -9635,7 +10662,7 @@ var __publicField = (obj, key, value) => {
|
|
|
9635
10662
|
])) : vue.createCommentVNode("", true)
|
|
9636
10663
|
]),
|
|
9637
10664
|
_: 1
|
|
9638
|
-
}, 8, ["visible", "onClickCloseIcon", "close-on-click-overlay", "onClickOverlay"])
|
|
10665
|
+
}, 8, ["visible", "onClickCloseIcon", "close-on-click-overlay", "onClickOverlay", "isWrapTeleport"])
|
|
9639
10666
|
]);
|
|
9640
10667
|
}
|
|
9641
10668
|
var ShortPassword = /* @__PURE__ */ _export_sfc(_sfc_main$q, [["render", _sfc_render$q]]);
|
|
@@ -10806,7 +11833,6 @@ var __publicField = (obj, key, value) => {
|
|
|
10806
11833
|
},
|
|
10807
11834
|
emits: ["input", "delete", "close", "update:value"],
|
|
10808
11835
|
setup(props, { emit }) {
|
|
10809
|
-
console.log(props.overlay);
|
|
10810
11836
|
const clickKeyIndex = vue.ref(void 0);
|
|
10811
11837
|
const show = vue.ref(props.visible);
|
|
10812
11838
|
const root = vue.ref();
|
|
@@ -11479,6 +12505,9 @@ var __publicField = (obj, key, value) => {
|
|
|
11479
12505
|
emit("update:visible", false);
|
|
11480
12506
|
};
|
|
11481
12507
|
const chooseItem = (item, index) => {
|
|
12508
|
+
if (item.disabled) {
|
|
12509
|
+
return;
|
|
12510
|
+
}
|
|
11482
12511
|
emit("choose", item, index);
|
|
11483
12512
|
};
|
|
11484
12513
|
return {
|
|
@@ -11887,7 +12916,7 @@ var __publicField = (obj, key, value) => {
|
|
|
11887
12916
|
};
|
|
11888
12917
|
});
|
|
11889
12918
|
const getStyle = () => {
|
|
11890
|
-
if (avatarSize
|
|
12919
|
+
if (avatarSize.value) {
|
|
11891
12920
|
return {
|
|
11892
12921
|
width: avatarSize.value,
|
|
11893
12922
|
height: avatarSize.value
|
|
@@ -11899,7 +12928,6 @@ var __publicField = (obj, key, value) => {
|
|
|
11899
12928
|
};
|
|
11900
12929
|
};
|
|
11901
12930
|
vue.onMounted(() => {
|
|
11902
|
-
console.log("row", props.row);
|
|
11903
12931
|
});
|
|
11904
12932
|
return {
|
|
11905
12933
|
avatarShape,
|
|
@@ -11916,7 +12944,10 @@ var __publicField = (obj, key, value) => {
|
|
|
11916
12944
|
key: 1,
|
|
11917
12945
|
class: "skeleton"
|
|
11918
12946
|
};
|
|
11919
|
-
const _hoisted_3$b =
|
|
12947
|
+
const _hoisted_3$b = {
|
|
12948
|
+
key: 0,
|
|
12949
|
+
class: "skeleton-animation"
|
|
12950
|
+
};
|
|
11920
12951
|
const _hoisted_4$a = { class: "content" };
|
|
11921
12952
|
const _hoisted_5$5 = { class: "content-line" };
|
|
11922
12953
|
const _hoisted_6$3 = {
|
|
@@ -11928,7 +12959,7 @@ var __publicField = (obj, key, value) => {
|
|
|
11928
12959
|
return !_ctx.loading ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_1$e, [
|
|
11929
12960
|
vue.renderSlot(_ctx.$slots, "default")
|
|
11930
12961
|
])) : (vue.openBlock(), vue.createElementBlock("view", _hoisted_2$c, [
|
|
11931
|
-
_hoisted_3$b,
|
|
12962
|
+
_ctx.animated ? (vue.openBlock(), vue.createElementBlock("view", _hoisted_3$b)) : vue.createCommentVNode("", true),
|
|
11932
12963
|
vue.createElementVNode("view", _hoisted_4$a, [
|
|
11933
12964
|
_ctx.avatar ? (vue.openBlock(), vue.createBlock(_component_nut_avatar, {
|
|
11934
12965
|
key: 0,
|
|
@@ -12119,7 +13150,7 @@ var __publicField = (obj, key, value) => {
|
|
|
12119
13150
|
const tree = vue.ref(new Tree([], {}));
|
|
12120
13151
|
const panes = vue.ref([]);
|
|
12121
13152
|
const isLazy = vue.computed(() => configs.value.lazy && Boolean(configs.value.lazyLoad));
|
|
12122
|
-
const lazyLoadMap = new Map();
|
|
13153
|
+
const lazyLoadMap = /* @__PURE__ */ new Map();
|
|
12123
13154
|
let currentProcessNode;
|
|
12124
13155
|
const init = async () => {
|
|
12125
13156
|
lazyLoadMap.clear();
|
|
@@ -12462,6 +13493,10 @@ var __publicField = (obj, key, value) => {
|
|
|
12462
13493
|
const _sfc_main$c = create$c({
|
|
12463
13494
|
inheritAttrs: false,
|
|
12464
13495
|
props: {
|
|
13496
|
+
modelValue: {
|
|
13497
|
+
type: Array,
|
|
13498
|
+
default: () => []
|
|
13499
|
+
},
|
|
12465
13500
|
visible: {
|
|
12466
13501
|
type: Boolean,
|
|
12467
13502
|
default: false
|
|
@@ -12525,9 +13560,13 @@ var __publicField = (obj, key, value) => {
|
|
|
12525
13560
|
height: {
|
|
12526
13561
|
type: [String, Number],
|
|
12527
13562
|
default: "200px"
|
|
13563
|
+
},
|
|
13564
|
+
columnsPlaceholder: {
|
|
13565
|
+
type: [String, Array],
|
|
13566
|
+
default: "\u8BF7\u9009\u62E9"
|
|
12528
13567
|
}
|
|
12529
13568
|
},
|
|
12530
|
-
emits: ["update:visible", "type", "change", "selected", "close", "close-mask", "switch-module"],
|
|
13569
|
+
emits: ["update:visible", "update:modelValue", "type", "change", "selected", "close", "close-mask", "switch-module"],
|
|
12531
13570
|
setup(props, { emit }) {
|
|
12532
13571
|
const regionLine = vue.ref(null);
|
|
12533
13572
|
const tabRegion = vue.ref(null);
|
|
@@ -12535,6 +13574,7 @@ var __publicField = (obj, key, value) => {
|
|
|
12535
13574
|
const privateType = vue.ref(props.type);
|
|
12536
13575
|
const tabIndex = vue.ref(0);
|
|
12537
13576
|
const tabName = vue.ref(["province", "city", "country", "town"]);
|
|
13577
|
+
const tabNameDefault = vue.ref([""]);
|
|
12538
13578
|
const isCustom2 = vue.computed(() => props.type === "custom2");
|
|
12539
13579
|
const transformData = (data) => {
|
|
12540
13580
|
if (!Array.isArray(data))
|
|
@@ -12582,13 +13622,55 @@ var __publicField = (obj, key, value) => {
|
|
|
12582
13622
|
let selectedExistAddress = vue.reactive({});
|
|
12583
13623
|
const closeWay = vue.ref("self");
|
|
12584
13624
|
const lineDistance = vue.ref(20);
|
|
13625
|
+
vue.onMounted(() => {
|
|
13626
|
+
customPlaceholder();
|
|
13627
|
+
});
|
|
13628
|
+
const initCustomSelected = () => {
|
|
13629
|
+
if (props.modelValue.length > 0) {
|
|
13630
|
+
tabIndex.value = props.modelValue.length - 1;
|
|
13631
|
+
for (let index = 0; index < props.modelValue.length; index++) {
|
|
13632
|
+
if (regionList[tabName.value[index]].length == 0) {
|
|
13633
|
+
tabIndex.value = index - 1;
|
|
13634
|
+
break;
|
|
13635
|
+
} else {
|
|
13636
|
+
const val = props.modelValue[index];
|
|
13637
|
+
const arr = regionList[tabName.value[index]];
|
|
13638
|
+
if (privateType.value == "custom") {
|
|
13639
|
+
selectedRegion[tabName.value[index]] = arr.filter((item) => item.id == val)[0];
|
|
13640
|
+
} else if (privateType.value == "custom2") {
|
|
13641
|
+
let sumArr = [];
|
|
13642
|
+
arr.map((item) => {
|
|
13643
|
+
sumArr.push(...item.list);
|
|
13644
|
+
});
|
|
13645
|
+
selectedRegion[tabName.value[index]] = sumArr.filter((item) => item.id == val)[0];
|
|
13646
|
+
}
|
|
13647
|
+
}
|
|
13648
|
+
}
|
|
13649
|
+
lineAnimation();
|
|
13650
|
+
}
|
|
13651
|
+
};
|
|
13652
|
+
const customPlaceholder = () => {
|
|
13653
|
+
let typeD = Object.prototype.toString.call(props.columnsPlaceholder);
|
|
13654
|
+
if (typeD == "[object String]") {
|
|
13655
|
+
tabNameDefault.value = new Array(4).fill(props.columnsPlaceholder);
|
|
13656
|
+
} else if (typeD == "[object Array]") {
|
|
13657
|
+
tabNameDefault.value = new Array(4).fill("");
|
|
13658
|
+
tabNameDefault.value.forEach((val, index) => {
|
|
13659
|
+
if (props.columnsPlaceholder[index]) {
|
|
13660
|
+
tabNameDefault.value[index] = props.columnsPlaceholder[index];
|
|
13661
|
+
} else {
|
|
13662
|
+
tabNameDefault.value[index] = "\u8BF7\u9009\u62E9";
|
|
13663
|
+
}
|
|
13664
|
+
});
|
|
13665
|
+
}
|
|
13666
|
+
};
|
|
12585
13667
|
const getTabName = (item, index) => {
|
|
12586
13668
|
if (item.name)
|
|
12587
13669
|
return item.name;
|
|
12588
13670
|
if (tabIndex.value < index) {
|
|
12589
13671
|
return item.name;
|
|
12590
13672
|
} else {
|
|
12591
|
-
return
|
|
13673
|
+
return tabNameDefault.value[index];
|
|
12592
13674
|
}
|
|
12593
13675
|
};
|
|
12594
13676
|
const handClose = (type = "self") => {
|
|
@@ -12601,7 +13683,6 @@ var __publicField = (obj, key, value) => {
|
|
|
12601
13683
|
closeWay.value = "mask";
|
|
12602
13684
|
};
|
|
12603
13685
|
const lineAnimation = () => {
|
|
12604
|
-
console.log("\u6ED1\u52A8\u7EA2\u7EBF");
|
|
12605
13686
|
vue.nextTick(() => {
|
|
12606
13687
|
const name = tabRegion.value && tabRegion.value.getElementsByClassName("active")[0];
|
|
12607
13688
|
if (name) {
|
|
@@ -12617,7 +13698,7 @@ var __publicField = (obj, key, value) => {
|
|
|
12617
13698
|
custom: tabName.value[tabIndex.value]
|
|
12618
13699
|
};
|
|
12619
13700
|
selectedRegion[tabName.value[tabIndex.value]] = item;
|
|
12620
|
-
for (let i = tabIndex.value; i <
|
|
13701
|
+
for (let i = tabIndex.value; i < 4; i++) {
|
|
12621
13702
|
selectedRegion[tabName.value[i + 1]] = {};
|
|
12622
13703
|
}
|
|
12623
13704
|
if (tabIndex.value < 3) {
|
|
@@ -12628,6 +13709,7 @@ var __publicField = (obj, key, value) => {
|
|
|
12628
13709
|
emit("change", calBack);
|
|
12629
13710
|
} else {
|
|
12630
13711
|
handClose();
|
|
13712
|
+
emit("update:modelValue");
|
|
12631
13713
|
}
|
|
12632
13714
|
};
|
|
12633
13715
|
const changeRegionTab = (item, key, index) => {
|
|
@@ -12710,6 +13792,8 @@ var __publicField = (obj, key, value) => {
|
|
|
12710
13792
|
vue.watch(() => showPopup.value, (value) => {
|
|
12711
13793
|
if (value == false) {
|
|
12712
13794
|
close();
|
|
13795
|
+
} else {
|
|
13796
|
+
initCustomSelected();
|
|
12713
13797
|
}
|
|
12714
13798
|
});
|
|
12715
13799
|
vue.watch(() => props.province, (value) => {
|
|
@@ -12819,7 +13903,7 @@ var __publicField = (obj, key, value) => {
|
|
|
12819
13903
|
name: _ctx.backBtnIcon,
|
|
12820
13904
|
color: "#cccccc"
|
|
12821
13905
|
}, null, 8, ["name"]), [
|
|
12822
|
-
[vue.vShow, _ctx.privateType == "custom" && _ctx.backBtnIcon]
|
|
13906
|
+
[vue.vShow, _ctx.type == "exist" && _ctx.privateType == "custom" && _ctx.backBtnIcon]
|
|
12823
13907
|
])
|
|
12824
13908
|
]),
|
|
12825
13909
|
vue.createElementVNode("view", _hoisted_3$9, vue.toDisplayString(_ctx.privateType == "custom" ? _ctx.customAddressTitle : _ctx.existAddressTitle), 1),
|
|
@@ -13229,6 +14313,10 @@ var __publicField = (obj, key, value) => {
|
|
|
13229
14313
|
default: () => {
|
|
13230
14314
|
return [];
|
|
13231
14315
|
}
|
|
14316
|
+
},
|
|
14317
|
+
isWrapTeleport: {
|
|
14318
|
+
type: Boolean,
|
|
14319
|
+
default: false
|
|
13232
14320
|
}
|
|
13233
14321
|
},
|
|
13234
14322
|
emits: ["update:visible", "select"],
|
|
@@ -13271,6 +14359,7 @@ var __publicField = (obj, key, value) => {
|
|
|
13271
14359
|
position: "bottom",
|
|
13272
14360
|
closeable: "",
|
|
13273
14361
|
round: "",
|
|
14362
|
+
isWrapTeleport: _ctx.isWrapTeleport,
|
|
13274
14363
|
visible: _ctx.visible,
|
|
13275
14364
|
style: vue.normalizeStyle(_ctx.popStyle),
|
|
13276
14365
|
onClickOverlay: _ctx.close,
|
|
@@ -13294,7 +14383,7 @@ var __publicField = (obj, key, value) => {
|
|
|
13294
14383
|
], 2)
|
|
13295
14384
|
]),
|
|
13296
14385
|
_: 3
|
|
13297
|
-
}, 8, ["visible", "style", "onClickOverlay", "onClickCloseIcon"]);
|
|
14386
|
+
}, 8, ["isWrapTeleport", "visible", "style", "onClickOverlay", "onClickCloseIcon"]);
|
|
13298
14387
|
}
|
|
13299
14388
|
var TimeSelect = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$9]]);
|
|
13300
14389
|
const { componentName: componentName$7, create: create$8 } = createComponent("timepannel");
|
|
@@ -13933,7 +15022,6 @@ var __publicField = (obj, key, value) => {
|
|
|
13933
15022
|
}
|
|
13934
15023
|
},
|
|
13935
15024
|
setup(props, { emit, slots }) {
|
|
13936
|
-
console.log(slots["origin"]);
|
|
13937
15025
|
const isHaveSlot = (slot) => {
|
|
13938
15026
|
return slots[slot];
|
|
13939
15027
|
};
|
|
@@ -14001,7 +15089,7 @@ var __publicField = (obj, key, value) => {
|
|
|
14001
15089
|
return () => vue.h(`view`, {}, props.slots());
|
|
14002
15090
|
},
|
|
14003
15091
|
props: {
|
|
14004
|
-
slots:
|
|
15092
|
+
slots: Function
|
|
14005
15093
|
}
|
|
14006
15094
|
};
|
|
14007
15095
|
const component = (componentName2) => {
|
|
@@ -14166,7 +15254,7 @@ var __publicField = (obj, key, value) => {
|
|
|
14166
15254
|
}
|
|
14167
15255
|
var Table = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
14168
15256
|
function install(app) {
|
|
14169
|
-
const packages = [Avatar, Button, Cell, CellGroup, _sfc_main$
|
|
15257
|
+
const packages = [Avatar, Button, Cell, CellGroup, _sfc_main$1s, Price, OverLay, Divider, _sfc_main$1l, Col, Row, _ImagePreview, _sfc_main$1d, Swipe, ActionSheet, BackTop, Collapse, CollapseItem, Drag, _Dialog, InfiniteLoading, NotifyFunction, Range, PullRefresh, Video, Popup, _sfc_main$11, Step, Swiper, SwiperItem, Switch, ToastFunction, Progress, CircleProgress, NoticeBar, SearchBar, Empty, Audio, AudioOperate, Navbar, FixedNav, Menu, MenuItem, Tabbar, TabbarItem, Elevator, Pagination, Tabs, TabPane, Indicator, _sfc_main$H, GridItem, SideNavBar, SideNavBarItem, SubSideNavBar, Calendar, _sfc_main$A, _sfc_main$z, DatePicker, InputNumber, Input, _sfc_main$t, _sfc_main$s, Rate, CalendarItem, Picker, ShortPassword, TextArea, Uploader, CountUp, NumberKeyboard, CountDown, Badge, Tag, Popover, Form, FormItem, Skeleton, Cascader, Address, Barrage, Signature, TimeSelect, TimePannel, TimeDetail, Sku, Card, Table];
|
|
14170
15258
|
packages.forEach((item) => {
|
|
14171
15259
|
if (item.install) {
|
|
14172
15260
|
app.use(item);
|
|
@@ -14175,16 +15263,19 @@ var __publicField = (obj, key, value) => {
|
|
|
14175
15263
|
}
|
|
14176
15264
|
});
|
|
14177
15265
|
}
|
|
14178
|
-
const version = "3.1.
|
|
15266
|
+
const version = "3.1.18-beta.0";
|
|
14179
15267
|
var nutui_vue_build = { install, version };
|
|
14180
15268
|
exports2.ActionSheet = ActionSheet;
|
|
14181
15269
|
exports2.Address = Address;
|
|
15270
|
+
exports2.Audio = Audio;
|
|
15271
|
+
exports2.AudioOperate = AudioOperate;
|
|
14182
15272
|
exports2.Avatar = Avatar;
|
|
14183
15273
|
exports2.BackTop = BackTop;
|
|
14184
15274
|
exports2.Badge = Badge;
|
|
14185
15275
|
exports2.Barrage = Barrage;
|
|
14186
15276
|
exports2.Button = Button;
|
|
14187
15277
|
exports2.Calendar = Calendar;
|
|
15278
|
+
exports2.CalendarItem = CalendarItem;
|
|
14188
15279
|
exports2.Card = Card;
|
|
14189
15280
|
exports2.Cascader = Cascader;
|
|
14190
15281
|
exports2.Cell = Cell;
|
|
@@ -14208,13 +15299,13 @@ var __publicField = (obj, key, value) => {
|
|
|
14208
15299
|
exports2.FormItem = FormItem;
|
|
14209
15300
|
exports2.Grid = _sfc_main$H;
|
|
14210
15301
|
exports2.GridItem = GridItem;
|
|
14211
|
-
exports2.Icon = _sfc_main$
|
|
15302
|
+
exports2.Icon = _sfc_main$1s;
|
|
14212
15303
|
exports2.ImagePreview = _ImagePreview;
|
|
14213
15304
|
exports2.Indicator = Indicator;
|
|
14214
15305
|
exports2.InfiniteLoading = InfiniteLoading;
|
|
14215
15306
|
exports2.Input = Input;
|
|
14216
15307
|
exports2.InputNumber = InputNumber;
|
|
14217
|
-
exports2.Layout = _sfc_main$
|
|
15308
|
+
exports2.Layout = _sfc_main$1l;
|
|
14218
15309
|
exports2.Menu = Menu;
|
|
14219
15310
|
exports2.MenuItem = MenuItem;
|
|
14220
15311
|
exports2.Navbar = Navbar;
|
|
@@ -14228,6 +15319,7 @@ var __publicField = (obj, key, value) => {
|
|
|
14228
15319
|
exports2.Popup = Popup;
|
|
14229
15320
|
exports2.Price = Price;
|
|
14230
15321
|
exports2.Progress = Progress;
|
|
15322
|
+
exports2.PullRefresh = PullRefresh;
|
|
14231
15323
|
exports2.Radio = _sfc_main$t;
|
|
14232
15324
|
exports2.RadioGroup = _sfc_main$s;
|
|
14233
15325
|
exports2.Range = Range;
|
|
@@ -14241,7 +15333,8 @@ var __publicField = (obj, key, value) => {
|
|
|
14241
15333
|
exports2.Skeleton = Skeleton;
|
|
14242
15334
|
exports2.Sku = Sku;
|
|
14243
15335
|
exports2.Step = Step;
|
|
14244
|
-
exports2.Steps = _sfc_main
|
|
15336
|
+
exports2.Steps = _sfc_main$11;
|
|
15337
|
+
exports2.Sticky = _sfc_main$1d;
|
|
14245
15338
|
exports2.SubSideNavBar = SubSideNavBar;
|
|
14246
15339
|
exports2.Swipe = Swipe;
|
|
14247
15340
|
exports2.Swiper = Swiper;
|