@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.
Files changed (137) hide show
  1. package/CHANGELOG.md +37 -0
  2. package/README.md +1 -1
  3. package/dist/nutui.d.ts +3 -1
  4. package/dist/nutui.es.js +1860 -773
  5. package/dist/nutui.umd.js +1871 -778
  6. package/dist/packages/_es/ActionSheet.js +8 -3
  7. package/dist/packages/_es/Address.js +60 -7
  8. package/dist/packages/_es/Audio.js +289 -0
  9. package/dist/packages/_es/Avatar.js +1 -1
  10. package/dist/packages/_es/BackTop.js +3 -3
  11. package/dist/packages/_es/Badge.js +1 -1
  12. package/dist/packages/_es/Barrage.js +1 -1
  13. package/dist/packages/_es/Button.js +13 -4
  14. package/dist/packages/_es/Calendar.js +428 -209
  15. package/dist/packages/_es/Card.js +1 -2
  16. package/dist/packages/_es/Cascader.js +2 -2
  17. package/dist/packages/_es/Cell.js +2 -2
  18. package/dist/packages/_es/CellGroup.js +1 -1
  19. package/dist/packages/_es/Checkbox.js +2 -2
  20. package/dist/packages/_es/CheckboxGroup.js +2 -2
  21. package/dist/packages/_es/CircleProgress.js +1 -1
  22. package/dist/packages/_es/Col.js +1 -1
  23. package/dist/packages/_es/Collapse.js +1 -1
  24. package/dist/packages/_es/CollapseItem.js +4 -2
  25. package/dist/packages/_es/CountDown.js +1 -1
  26. package/dist/packages/_es/CountUp.js +1 -1
  27. package/dist/packages/_es/DatePicker.js +1 -2
  28. package/dist/packages/_es/Dialog.js +1 -1
  29. package/dist/packages/_es/Divider.js +1 -1
  30. package/dist/packages/_es/Drag.js +1 -1
  31. package/dist/packages/_es/Elevator.js +10 -5
  32. package/dist/packages/_es/Empty.js +1 -1
  33. package/dist/packages/_es/FixedNav.js +1 -1
  34. package/dist/packages/_es/Form.js +1 -1
  35. package/dist/packages/_es/FormItem.js +1 -1
  36. package/dist/packages/_es/Grid.js +1 -1
  37. package/dist/packages/_es/GridItem.js +2 -2
  38. package/dist/packages/_es/Icon.js +1 -1
  39. package/dist/packages/_es/ImagePreview.js +8 -5
  40. package/dist/packages/_es/Indicator.js +1 -1
  41. package/dist/packages/_es/InfiniteLoading.js +1 -1
  42. package/dist/packages/_es/Input.js +7 -2
  43. package/dist/packages/_es/InputNumber.js +1 -1
  44. package/dist/packages/_es/Layout.js +1 -1
  45. package/dist/packages/_es/Menu.js +1 -1
  46. package/dist/packages/_es/MenuItem.js +1 -1
  47. package/dist/packages/_es/Navbar.js +18 -59
  48. package/dist/packages/_es/NoticeBar.js +38 -23
  49. package/dist/packages/_es/Notify.js +2 -2
  50. package/dist/packages/_es/NumberKeyboard.js +1 -2
  51. package/dist/packages/_es/OverLay.js +1 -1
  52. package/dist/packages/_es/Pagination.js +1 -1
  53. package/dist/packages/_es/Picker.js +2 -1
  54. package/dist/packages/_es/Popover.js +4 -1
  55. package/dist/packages/_es/Popup.js +1 -1
  56. package/dist/packages/_es/Price.js +1 -1
  57. package/dist/packages/_es/Progress.js +24 -11
  58. package/dist/packages/_es/Radio.js +2 -2
  59. package/dist/packages/_es/RadioGroup.js +1 -1
  60. package/dist/packages/_es/Range.js +2 -2
  61. package/dist/packages/_es/Rate.js +1 -1
  62. package/dist/packages/_es/Row.js +1 -1
  63. package/dist/packages/_es/SearchBar.js +1 -1
  64. package/dist/packages/_es/ShortPassword.js +12 -4
  65. package/dist/packages/_es/SideNavBar.js +1 -1
  66. package/dist/packages/_es/SideNavBarItem.js +1 -1
  67. package/dist/packages/_es/Signature.js +1 -1
  68. package/dist/packages/_es/Skeleton.js +8 -6
  69. package/dist/packages/_es/Sku.js +1 -1
  70. package/dist/packages/_es/Step.js +1 -1
  71. package/dist/packages/_es/Steps.js +1 -1
  72. package/dist/packages/_es/Sticky.js +143 -0
  73. package/dist/packages/_es/SubSideNavBar.js +1 -1
  74. package/dist/packages/_es/Swipe.js +2 -2
  75. package/dist/packages/_es/Swiper.js +2 -2
  76. package/dist/packages/_es/SwiperItem.js +3 -8
  77. package/dist/packages/_es/Switch.js +2 -2
  78. package/dist/packages/_es/TabPane.js +1 -1
  79. package/dist/packages/_es/Tabbar.js +1 -1
  80. package/dist/packages/_es/TabbarItem.js +7 -3
  81. package/dist/packages/_es/Table.js +2 -2
  82. package/dist/packages/_es/Tabs.js +1 -1
  83. package/dist/packages/_es/Tag.js +1 -1
  84. package/dist/packages/_es/TextArea.js +1 -1
  85. package/dist/packages/_es/TimeDetail.js +1 -1
  86. package/dist/packages/_es/TimePannel.js +1 -1
  87. package/dist/packages/_es/TimeSelect.js +7 -2
  88. package/dist/packages/_es/Toast.js +15 -8
  89. package/dist/packages/_es/Uploader.js +1 -1
  90. package/dist/packages/_es/Video.js +1 -55
  91. package/dist/packages/_es/common.js +1 -1
  92. package/dist/packages/_es/component.js +1 -1
  93. package/dist/packages/_es/index.js +5 -7
  94. package/dist/packages/_es/index2.js +7 -58
  95. package/dist/packages/_es/index3.js +1 -1
  96. package/dist/packages/_es/index4.js +64 -0
  97. package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
  98. package/dist/packages/_es/pxCheck.js +1 -1
  99. package/dist/packages/_es/raf.js +1 -1
  100. package/dist/packages/_es/util.js +1 -1
  101. package/dist/packages/actionsheet/index.scss +7 -6
  102. package/dist/packages/address/index.scss +8 -0
  103. package/dist/packages/audio/index.scss +66 -0
  104. package/dist/packages/audiooperate/index.scss +13 -0
  105. package/dist/packages/button/index.scss +5 -5
  106. package/dist/packages/calendar/index.scss +47 -41
  107. package/dist/packages/calendaritem/index.scss +57 -42
  108. package/dist/packages/cell/index.scss +3 -3
  109. package/dist/packages/cellgroup/index.scss +1 -1
  110. package/dist/packages/elevator/index.scss +3 -0
  111. package/dist/packages/infiniteloading/index.scss +1 -1
  112. package/dist/packages/input/index.scss +4 -2
  113. package/dist/packages/navbar/index.scss +2 -0
  114. package/dist/packages/noticebar/index.scss +11 -5
  115. package/dist/packages/notify/index.scss +1 -0
  116. package/dist/packages/progress/index.scss +21 -17
  117. package/dist/packages/range/index.scss +8 -8
  118. package/dist/packages/row/index.scss +3 -0
  119. package/dist/packages/sticky/index.scss +5 -0
  120. package/dist/packages/swiper/index.scss +4 -4
  121. package/dist/packages/switch/index.scss +8 -8
  122. package/dist/packages/tabbar/index.scss +7 -4
  123. package/dist/packages/tabbaritem/index.scss +4 -3
  124. package/dist/packages/tabs/index.scss +1 -0
  125. package/dist/packages/toast/index.scss +8 -7
  126. package/dist/style.css +1 -1
  127. package/dist/styles/font/config.json +6 -1
  128. package/dist/styles/font/demo_index.html +118 -3
  129. package/dist/styles/font/iconfont.css +23 -3
  130. package/dist/styles/font/iconfont.js +25 -24
  131. package/dist/styles/font/iconfont.json +35 -0
  132. package/dist/styles/font/iconfont.ttf +0 -0
  133. package/dist/styles/font/iconfont.woff +0 -0
  134. package/dist/styles/font/iconfont.woff2 +0 -0
  135. package/dist/styles/themes/default.scss +46 -43
  136. package/dist/styles/variables.scss +123 -42
  137. package/package.json +12 -13
package/dist/nutui.es.js CHANGED
@@ -35,12 +35,11 @@ var __publicField = (obj, key, value) => {
35
35
  return value;
36
36
  };
37
37
  /*!
38
- * @nutui/nutui v3.1.16 Sun Jan 30 2022 10:58:05 GMT+0800 (中国标准时间)
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
- import { defineComponent, toRefs, computed, resolveComponent, openBlock, createElementBlock, normalizeStyle, normalizeClass, createVNode, renderSlot, createCommentVNode, h, createElementVNode, createBlock, Fragment, toDisplayString, createTextVNode, watch, onDeactivated, onBeforeUnmount, onMounted, onActivated, Transition, withCtx, withDirectives, withModifiers, vShow, inject, provide, reactive, onBeforeMount, Teleport, ref, nextTick, getCurrentInstance, renderList, render, onUnmounted, unref, mergeProps, watchEffect, shallowReactive, markRaw, isVNode, toRaw, readonly, vModelText, createSlots } from "vue";
43
- import { useRouter } from "vue-router";
42
+ import { defineComponent, toRefs, computed, resolveComponent, openBlock, createElementBlock, normalizeStyle, normalizeClass, createVNode, renderSlot, createCommentVNode, h, createElementVNode, createBlock, getCurrentInstance, Fragment, toDisplayString, createTextVNode, watch, onDeactivated, onBeforeUnmount, onMounted, onActivated, Transition, withCtx, withDirectives, withModifiers, vShow, inject, provide, reactive, onBeforeMount, Teleport, ref, nextTick, renderList, render, unref, onUnmounted, useSlots, mergeProps, watchEffect, shallowReactive, markRaw, isVNode, createSlots, toRaw, readonly, vModelText } from "vue";
44
43
  function createComponent(name) {
45
44
  const componentName2 = "nut-" + name;
46
45
  return {
@@ -67,8 +66,8 @@ var _export_sfc = (sfc, props) => {
67
66
  }
68
67
  return target;
69
68
  };
70
- const { componentName: componentName$14, create: create$1p } = createComponent("avatar");
71
- const _sfc_main$1p = create$1p({
69
+ const { componentName: componentName$18, create: create$1t } = createComponent("avatar");
70
+ const _sfc_main$1t = create$1t({
72
71
  props: {
73
72
  size: {
74
73
  type: String,
@@ -92,7 +91,7 @@ const _sfc_main$1p = create$1p({
92
91
  const { size, shape, bgColor, icon } = toRefs(props);
93
92
  const sizeValue = ["large", "normal", "small"];
94
93
  const classes = computed(() => {
95
- const prefixCls = componentName$14;
94
+ const prefixCls = componentName$18;
96
95
  return {
97
96
  [prefixCls]: true,
98
97
  ["avatar-" + size.value]: true,
@@ -124,11 +123,11 @@ const _sfc_main$1p = create$1p({
124
123
  };
125
124
  }
126
125
  });
127
- const _hoisted_1$$ = {
126
+ const _hoisted_1$12 = {
128
127
  key: 0,
129
128
  class: "text"
130
129
  };
131
- function _sfc_render$1h(_ctx, _cache, $props, $setup, $data, $options) {
130
+ function _sfc_render$1k(_ctx, _cache, $props, $setup, $data, $options) {
132
131
  const _component_nut_icon = resolveComponent("nut-icon");
133
132
  return openBlock(), createElementBlock("view", {
134
133
  style: normalizeStyle(_ctx.styles),
@@ -139,17 +138,17 @@ function _sfc_render$1h(_ctx, _cache, $props, $setup, $data, $options) {
139
138
  class: "icon",
140
139
  name: _ctx.iconStyles
141
140
  }, null, 8, ["name"]),
142
- _ctx.isShowText ? (openBlock(), createElementBlock("view", _hoisted_1$$, [
141
+ _ctx.isShowText ? (openBlock(), createElementBlock("view", _hoisted_1$12, [
143
142
  renderSlot(_ctx.$slots, "default")
144
143
  ])) : createCommentVNode("", true)
145
144
  ], 6);
146
145
  }
147
- var Avatar = /* @__PURE__ */ _export_sfc(_sfc_main$1p, [["render", _sfc_render$1h]]);
146
+ var Avatar = /* @__PURE__ */ _export_sfc(_sfc_main$1t, [["render", _sfc_render$1k]]);
148
147
  const pxCheck = (value) => {
149
148
  return isNaN(Number(value)) ? String(value) : `${value}px`;
150
149
  };
151
- const { componentName: componentName$13, create: create$1o } = createComponent("icon");
152
- const _sfc_main$1o = create$1o({
150
+ const { componentName: componentName$17, create: create$1s } = createComponent("icon");
151
+ const _sfc_main$1s = create$1s({
153
152
  props: {
154
153
  name: { type: String, default: "" },
155
154
  size: { type: [String, Number], default: "" },
@@ -170,7 +169,7 @@ const _sfc_main$1o = create$1o({
170
169
  var _a;
171
170
  const _isImage = isImage();
172
171
  return h(_isImage ? "img" : props.tag, {
173
- class: _isImage ? `${componentName$13}__img` : `${props.fontClassName} ${componentName$13} ${props.classPrefix}-${props.name}`,
172
+ class: _isImage ? `${componentName$17}__img` : `${props.fontClassName} ${componentName$17} ${props.classPrefix}-${props.name}`,
174
173
  style: {
175
174
  color: props.color,
176
175
  fontSize: pxCheck(props.size),
@@ -183,10 +182,10 @@ const _sfc_main$1o = create$1o({
183
182
  };
184
183
  }
185
184
  });
186
- const { componentName: componentName$12, create: create$1n } = createComponent("button");
187
- const _sfc_main$1n = create$1n({
185
+ const { componentName: componentName$16, create: create$1r } = createComponent("button");
186
+ const _sfc_main$1r = create$1r({
188
187
  components: {
189
- [_sfc_main$1o.name]: _sfc_main$1o
188
+ [_sfc_main$1s.name]: _sfc_main$1s
190
189
  },
191
190
  props: {
192
191
  color: String,
@@ -221,6 +220,14 @@ const _sfc_main$1n = create$1n({
221
220
  icon: {
222
221
  type: String,
223
222
  default: ""
223
+ },
224
+ iconClassPrefix: {
225
+ type: String,
226
+ default: "nut-icon"
227
+ },
228
+ iconFontClassName: {
229
+ type: String,
230
+ default: "nutui-iconfont"
224
231
  }
225
232
  },
226
233
  emits: ["click"],
@@ -232,7 +239,7 @@ const _sfc_main$1n = create$1n({
232
239
  }
233
240
  };
234
241
  const classes = computed(() => {
235
- const prefixCls = componentName$12;
242
+ const prefixCls = componentName$16;
236
243
  return {
237
244
  [prefixCls]: true,
238
245
  [`${prefixCls}--${type.value}`]: type.value,
@@ -268,24 +275,25 @@ const _sfc_main$1n = create$1n({
268
275
  };
269
276
  }
270
277
  });
271
- const _hoisted_1$_ = { class: "nut-button__warp" };
272
- function _sfc_render$1g(_ctx, _cache, $props, $setup, $data, $options) {
278
+ const _hoisted_1$11 = { class: "nut-button__warp" };
279
+ function _sfc_render$1j(_ctx, _cache, $props, $setup, $data, $options) {
273
280
  const _component_nut_icon = resolveComponent("nut-icon");
274
281
  return openBlock(), createElementBlock("view", {
275
282
  class: normalizeClass(_ctx.classes),
276
283
  style: normalizeStyle(_ctx.getStyle),
277
284
  onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
278
285
  }, [
279
- createElementVNode("view", _hoisted_1$_, [
286
+ createElementVNode("view", _hoisted_1$11, [
280
287
  _ctx.loading ? (openBlock(), createBlock(_component_nut_icon, {
281
288
  key: 0,
282
289
  class: "nut-icon-loading"
283
290
  })) : createCommentVNode("", true),
284
291
  _ctx.icon && !_ctx.loading ? (openBlock(), createBlock(_component_nut_icon, {
285
292
  key: 1,
286
- class: normalizeClass(_ctx.icon),
287
- name: _ctx.icon
288
- }, null, 8, ["class", "name"])) : createCommentVNode("", true),
293
+ name: _ctx.icon,
294
+ "class-prefix": _ctx.iconClassPrefix,
295
+ "font-class-name": _ctx.iconFontClassName
296
+ }, null, 8, ["name", "class-prefix", "font-class-name"])) : createCommentVNode("", true),
289
297
  _ctx.$slots.default ? (openBlock(), createElementBlock("view", {
290
298
  key: 2,
291
299
  class: normalizeClass({ text: _ctx.icon || _ctx.loading })
@@ -295,9 +303,13 @@ function _sfc_render$1g(_ctx, _cache, $props, $setup, $data, $options) {
295
303
  ])
296
304
  ], 6);
297
305
  }
298
- var Button = /* @__PURE__ */ _export_sfc(_sfc_main$1n, [["render", _sfc_render$1g]]);
299
- const { componentName: componentName$11, create: create$1m } = createComponent("cell");
300
- const _sfc_main$1m = create$1m({
306
+ var Button = /* @__PURE__ */ _export_sfc(_sfc_main$1r, [["render", _sfc_render$1j]]);
307
+ function useRouter() {
308
+ const proxy = getCurrentInstance().proxy;
309
+ return proxy.$router || null;
310
+ }
311
+ const { componentName: componentName$15, create: create$1q } = createComponent("cell");
312
+ const _sfc_main$1q = create$1q({
301
313
  props: {
302
314
  title: { type: String, default: "" },
303
315
  subTitle: { type: String, default: "" },
@@ -313,7 +325,7 @@ const _sfc_main$1m = create$1m({
313
325
  emits: ["click"],
314
326
  setup(props, { emit }) {
315
327
  const classes = computed(() => {
316
- const prefixCls = componentName$11;
328
+ const prefixCls = componentName$15;
317
329
  return {
318
330
  [prefixCls]: true,
319
331
  [`${prefixCls}--clickable`]: props.isLink || props.to
@@ -340,9 +352,9 @@ const _sfc_main$1m = create$1m({
340
352
  };
341
353
  }
342
354
  });
343
- const _hoisted_1$Z = { class: "title" };
344
- const _hoisted_2$O = { class: "nut-cell__title-desc" };
345
- function _sfc_render$1f(_ctx, _cache, $props, $setup, $data, $options) {
355
+ const _hoisted_1$10 = { class: "title" };
356
+ const _hoisted_2$R = { class: "nut-cell__title-desc" };
357
+ function _sfc_render$1i(_ctx, _cache, $props, $setup, $data, $options) {
346
358
  const _component_nut_icon = resolveComponent("nut-icon");
347
359
  return openBlock(), createElementBlock("view", {
348
360
  class: normalizeClass(_ctx.classes),
@@ -360,8 +372,8 @@ function _sfc_render$1f(_ctx, _cache, $props, $setup, $data, $options) {
360
372
  name: _ctx.icon
361
373
  }, null, 8, ["name"])) : createCommentVNode("", true),
362
374
  _ctx.subTitle ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
363
- createElementVNode("view", _hoisted_1$Z, toDisplayString(_ctx.title), 1),
364
- createElementVNode("view", _hoisted_2$O, toDisplayString(_ctx.subTitle), 1)
375
+ createElementVNode("view", _hoisted_1$10, toDisplayString(_ctx.title), 1),
376
+ createElementVNode("view", _hoisted_2$R, toDisplayString(_ctx.subTitle), 1)
365
377
  ], 64)) : (openBlock(), createElementBlock(Fragment, { key: 3 }, [
366
378
  createTextVNode(toDisplayString(_ctx.title), 1)
367
379
  ], 64))
@@ -379,16 +391,16 @@ function _sfc_render$1f(_ctx, _cache, $props, $setup, $data, $options) {
379
391
  ])
380
392
  ], 6);
381
393
  }
382
- var Cell = /* @__PURE__ */ _export_sfc(_sfc_main$1m, [["render", _sfc_render$1f]]);
383
- const { componentName: componentName$10, create: create$1l } = createComponent("cell-group");
384
- const _sfc_main$1l = create$1l({
394
+ var Cell = /* @__PURE__ */ _export_sfc(_sfc_main$1q, [["render", _sfc_render$1i]]);
395
+ const { componentName: componentName$14, create: create$1p } = createComponent("cell-group");
396
+ const _sfc_main$1p = create$1p({
385
397
  props: {
386
398
  title: { type: String, default: "" },
387
399
  desc: { type: String, default: "" }
388
400
  },
389
401
  setup() {
390
402
  const classes = computed(() => {
391
- const prefixCls = componentName$10;
403
+ const prefixCls = componentName$14;
392
404
  return {
393
405
  [prefixCls]: true
394
406
  };
@@ -398,29 +410,29 @@ const _sfc_main$1l = create$1l({
398
410
  };
399
411
  }
400
412
  });
401
- const _hoisted_1$Y = {
413
+ const _hoisted_1$$ = {
402
414
  key: 1,
403
415
  class: "nut-cell-group__title"
404
416
  };
405
- const _hoisted_2$N = {
417
+ const _hoisted_2$Q = {
406
418
  key: 3,
407
419
  class: "nut-cell-group__desc"
408
420
  };
409
- const _hoisted_3$B = { class: "nut-cell-group__warp" };
410
- function _sfc_render$1e(_ctx, _cache, $props, $setup, $data, $options) {
421
+ const _hoisted_3$E = { class: "nut-cell-group__warp" };
422
+ function _sfc_render$1h(_ctx, _cache, $props, $setup, $data, $options) {
411
423
  return openBlock(), createElementBlock("view", {
412
424
  class: normalizeClass(_ctx.classes)
413
425
  }, [
414
- _ctx.$slots.title ? renderSlot(_ctx.$slots, "title", { key: 0 }) : _ctx.title ? (openBlock(), createElementBlock("view", _hoisted_1$Y, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
415
- _ctx.$slots.desc ? renderSlot(_ctx.$slots, "desc", { key: 2 }) : _ctx.desc ? (openBlock(), createElementBlock("view", _hoisted_2$N, toDisplayString(_ctx.desc), 1)) : createCommentVNode("", true),
416
- createElementVNode("view", _hoisted_3$B, [
426
+ _ctx.$slots.title ? renderSlot(_ctx.$slots, "title", { key: 0 }) : _ctx.title ? (openBlock(), createElementBlock("view", _hoisted_1$$, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
427
+ _ctx.$slots.desc ? renderSlot(_ctx.$slots, "desc", { key: 2 }) : _ctx.desc ? (openBlock(), createElementBlock("view", _hoisted_2$Q, toDisplayString(_ctx.desc), 1)) : createCommentVNode("", true),
428
+ createElementVNode("view", _hoisted_3$E, [
417
429
  renderSlot(_ctx.$slots, "default")
418
430
  ])
419
431
  ], 2);
420
432
  }
421
- var CellGroup = /* @__PURE__ */ _export_sfc(_sfc_main$1l, [["render", _sfc_render$1e]]);
422
- const { componentName: componentName$$, create: create$1k } = createComponent("price");
423
- const _sfc_main$1k = create$1k({
433
+ var CellGroup = /* @__PURE__ */ _export_sfc(_sfc_main$1p, [["render", _sfc_render$1h]]);
434
+ const { componentName: componentName$13, create: create$1o } = createComponent("price");
435
+ const _sfc_main$1o = create$1o({
424
436
  props: {
425
437
  price: {
426
438
  type: [Number, String],
@@ -454,7 +466,7 @@ const _sfc_main$1k = create$1k({
454
466
  setup(props) {
455
467
  const classes = computed(() => {
456
468
  return {
457
- [componentName$$]: true
469
+ [componentName$13]: true
458
470
  };
459
471
  });
460
472
  const showSymbol = computed(() => {
@@ -503,9 +515,9 @@ const _sfc_main$1k = create$1k({
503
515
  };
504
516
  }
505
517
  });
506
- const _hoisted_1$X = ["innerHTML"];
507
- const _hoisted_2$M = ["innerHTML"];
508
- function _sfc_render$1d(_ctx, _cache, $props, $setup, $data, $options) {
518
+ const _hoisted_1$_ = ["innerHTML"];
519
+ const _hoisted_2$P = ["innerHTML"];
520
+ function _sfc_render$1g(_ctx, _cache, $props, $setup, $data, $options) {
509
521
  return openBlock(), createElementBlock("view", {
510
522
  class: normalizeClass(_ctx.classes)
511
523
  }, [
@@ -513,7 +525,7 @@ function _sfc_render$1d(_ctx, _cache, $props, $setup, $data, $options) {
513
525
  key: 0,
514
526
  class: normalizeClass(["nut-price--symbol", `nut-price--symbol-${_ctx.size}`]),
515
527
  innerHTML: _ctx.showSymbol
516
- }, null, 10, _hoisted_1$X)) : createCommentVNode("", true),
528
+ }, null, 10, _hoisted_1$_)) : createCommentVNode("", true),
517
529
  createElementVNode("view", {
518
530
  class: normalizeClass(`nut-price--${_ctx.size}`)
519
531
  }, toDisplayString(_ctx.formatThousands(_ctx.price)), 3),
@@ -528,11 +540,11 @@ function _sfc_render$1d(_ctx, _cache, $props, $setup, $data, $options) {
528
540
  key: 2,
529
541
  class: normalizeClass(["nut-price--symbol", `nut-price--symbol-${_ctx.size}`]),
530
542
  innerHTML: _ctx.showSymbol
531
- }, null, 10, _hoisted_2$M)) : createCommentVNode("", true)
543
+ }, null, 10, _hoisted_2$P)) : createCommentVNode("", true)
532
544
  ], 2);
533
545
  }
534
- var Price = /* @__PURE__ */ _export_sfc(_sfc_main$1k, [["render", _sfc_render$1d]]);
535
- const { componentName: componentName$_, create: create$1j } = createComponent("overlay");
546
+ var Price = /* @__PURE__ */ _export_sfc(_sfc_main$1o, [["render", _sfc_render$1g]]);
547
+ const { componentName: componentName$12, create: create$1n } = createComponent("overlay");
536
548
  const overlayProps = {
537
549
  visible: {
538
550
  type: Boolean,
@@ -562,12 +574,12 @@ const overlayProps = {
562
574
  default: true
563
575
  }
564
576
  };
565
- const _sfc_main$1j = create$1j({
577
+ const _sfc_main$1n = create$1n({
566
578
  props: overlayProps,
567
579
  emits: ["click", "update:visible"],
568
580
  setup(props, { emit }) {
569
581
  const classes = computed(() => {
570
- const prefixCls = componentName$_;
582
+ const prefixCls = componentName$12;
571
583
  return {
572
584
  [prefixCls]: true,
573
585
  [props.overlayClass]: true
@@ -607,7 +619,7 @@ const _sfc_main$1j = create$1j({
607
619
  return { classes, style, touchmove, onClick };
608
620
  }
609
621
  });
610
- function _sfc_render$1c(_ctx, _cache, $props, $setup, $data, $options) {
622
+ function _sfc_render$1f(_ctx, _cache, $props, $setup, $data, $options) {
611
623
  return openBlock(), createBlock(Transition, { name: "overlay-fade" }, {
612
624
  default: withCtx(() => [
613
625
  withDirectives(createElementVNode("view", {
@@ -624,9 +636,9 @@ function _sfc_render$1c(_ctx, _cache, $props, $setup, $data, $options) {
624
636
  _: 3
625
637
  });
626
638
  }
627
- var OverLay = /* @__PURE__ */ _export_sfc(_sfc_main$1j, [["render", _sfc_render$1c]]);
628
- const { componentName: componentName$Z, create: create$1i } = createComponent("divider");
629
- const _sfc_main$1i = create$1i({
639
+ var OverLay = /* @__PURE__ */ _export_sfc(_sfc_main$1n, [["render", _sfc_render$1f]]);
640
+ const { componentName: componentName$11, create: create$1m } = createComponent("divider");
641
+ const _sfc_main$1m = create$1m({
630
642
  props: {
631
643
  contentPosition: {
632
644
  type: String,
@@ -644,7 +656,7 @@ const _sfc_main$1i = create$1i({
644
656
  components: {},
645
657
  setup(props, context) {
646
658
  const classes = computed(() => {
647
- const prefixCls = componentName$Z;
659
+ const prefixCls = componentName$11;
648
660
  return {
649
661
  [prefixCls]: true,
650
662
  [`${prefixCls}-center`]: context.slots.default,
@@ -657,18 +669,18 @@ const _sfc_main$1i = create$1i({
657
669
  return { classes };
658
670
  }
659
671
  });
660
- function _sfc_render$1b(_ctx, _cache, $props, $setup, $data, $options) {
672
+ function _sfc_render$1e(_ctx, _cache, $props, $setup, $data, $options) {
661
673
  return openBlock(), createElementBlock("div", {
662
674
  class: normalizeClass(_ctx.classes)
663
675
  }, [
664
676
  renderSlot(_ctx.$slots, "default")
665
677
  ], 2);
666
678
  }
667
- var Divider = /* @__PURE__ */ _export_sfc(_sfc_main$1i, [["render", _sfc_render$1b]]);
668
- const { create: create$1h } = createComponent("layout");
669
- const _sfc_main$1h = create$1h({});
670
- const { componentName: componentName$Y, create: create$1g } = createComponent("col");
671
- const _sfc_main$1g = create$1g({
679
+ var Divider = /* @__PURE__ */ _export_sfc(_sfc_main$1m, [["render", _sfc_render$1e]]);
680
+ const { create: create$1l } = createComponent("layout");
681
+ const _sfc_main$1l = create$1l({});
682
+ const { componentName: componentName$10, create: create$1k } = createComponent("col");
683
+ const _sfc_main$1k = create$1k({
672
684
  props: {
673
685
  span: {
674
686
  type: [String, Number],
@@ -680,7 +692,7 @@ const _sfc_main$1g = create$1g({
680
692
  }
681
693
  },
682
694
  setup(props) {
683
- const prefixCls = componentName$Y;
695
+ const prefixCls = componentName$10;
684
696
  const gutter = inject("gutter");
685
697
  const classes = computed(() => {
686
698
  return {
@@ -702,7 +714,7 @@ const _sfc_main$1g = create$1g({
702
714
  };
703
715
  }
704
716
  });
705
- function _sfc_render$1a(_ctx, _cache, $props, $setup, $data, $options) {
717
+ function _sfc_render$1d(_ctx, _cache, $props, $setup, $data, $options) {
706
718
  return openBlock(), createElementBlock("view", {
707
719
  class: normalizeClass(_ctx.classes),
708
720
  style: normalizeStyle(_ctx.style)
@@ -710,9 +722,9 @@ function _sfc_render$1a(_ctx, _cache, $props, $setup, $data, $options) {
710
722
  renderSlot(_ctx.$slots, "default")
711
723
  ], 6);
712
724
  }
713
- var Col = /* @__PURE__ */ _export_sfc(_sfc_main$1g, [["render", _sfc_render$1a]]);
714
- const { componentName: componentName$X, create: create$1f } = createComponent("row");
715
- const _sfc_main$1f = create$1f({
725
+ var Col = /* @__PURE__ */ _export_sfc(_sfc_main$1k, [["render", _sfc_render$1d]]);
726
+ const { componentName: componentName$$, create: create$1j } = createComponent("row");
727
+ const _sfc_main$1j = create$1j({
716
728
  props: {
717
729
  type: {
718
730
  type: String,
@@ -736,7 +748,7 @@ const _sfc_main$1f = create$1f({
736
748
  }
737
749
  },
738
750
  setup(props) {
739
- const prefixCls = componentName$X;
751
+ const prefixCls = componentName$$;
740
752
  provide("gutter", props.gutter);
741
753
  const getClass = (prefix, type) => {
742
754
  return prefix ? type ? `nut-row-${prefix}-${type}` : "" : `nut-row-${type}`;
@@ -755,14 +767,14 @@ const _sfc_main$1f = create$1f({
755
767
  };
756
768
  }
757
769
  });
758
- function _sfc_render$19(_ctx, _cache, $props, $setup, $data, $options) {
770
+ function _sfc_render$1c(_ctx, _cache, $props, $setup, $data, $options) {
759
771
  return openBlock(), createElementBlock("view", {
760
772
  class: normalizeClass(_ctx.getClasses())
761
773
  }, [
762
774
  renderSlot(_ctx.$slots, "default")
763
775
  ], 2);
764
776
  }
765
- var Row = /* @__PURE__ */ _export_sfc(_sfc_main$1f, [["render", _sfc_render$19]]);
777
+ var Row = /* @__PURE__ */ _export_sfc(_sfc_main$1j, [["render", _sfc_render$1c]]);
766
778
  let count = 0;
767
779
  const CLSNAME = "nut-overflow-hidden";
768
780
  const useLockScroll = (isLock) => {
@@ -780,7 +792,7 @@ const useLockScroll = (isLock) => {
780
792
  };
781
793
  return [lock, unlock];
782
794
  };
783
- const { componentName: componentName$W, create: create$1e } = createComponent("popup");
795
+ const { componentName: componentName$_, create: create$1i } = createComponent("popup");
784
796
  let _zIndex = 2e3;
785
797
  const popupProps = __spreadProps(__spreadValues({}, overlayProps), {
786
798
  position: {
@@ -828,10 +840,10 @@ const popupProps = __spreadProps(__spreadValues({}, overlayProps), {
828
840
  default: true
829
841
  }
830
842
  });
831
- const _sfc_main$1e = create$1e({
843
+ const _sfc_main$1i = create$1i({
832
844
  components: {
833
845
  [OverLay.name]: OverLay,
834
- [_sfc_main$1o.name]: _sfc_main$1o
846
+ [_sfc_main$1s.name]: _sfc_main$1s
835
847
  },
836
848
  props: __spreadValues({}, popupProps),
837
849
  emits: ["click", "click-close-icon", "open", "close", "opend", "closed", "update:visible", "click-overlay"],
@@ -846,7 +858,7 @@ const _sfc_main$1e = create$1e({
846
858
  });
847
859
  const [lockScroll, unlockScroll] = useLockScroll(() => props.lockScroll);
848
860
  const classes = computed(() => {
849
- const prefixCls = componentName$W;
861
+ const prefixCls = componentName$_;
850
862
  return {
851
863
  [prefixCls]: true,
852
864
  ["round"]: props.round,
@@ -953,8 +965,8 @@ const _sfc_main$1e = create$1e({
953
965
  });
954
966
  }
955
967
  });
956
- const _hoisted_1$W = { key: 1 };
957
- function _sfc_render$18(_ctx, _cache, $props, $setup, $data, $options) {
968
+ const _hoisted_1$Z = { key: 1 };
969
+ function _sfc_render$1b(_ctx, _cache, $props, $setup, $data, $options) {
958
970
  const _component_nut_overlay = resolveComponent("nut-overlay");
959
971
  const _component_nut_icon = resolveComponent("nut-icon");
960
972
  return _ctx.isWrapTeleport ? (openBlock(), createBlock(Teleport, {
@@ -1000,7 +1012,7 @@ function _sfc_render$18(_ctx, _cache, $props, $setup, $data, $options) {
1000
1012
  ]),
1001
1013
  _: 3
1002
1014
  }, 8, ["name", "onAfterEnter", "onAfterLeave"])
1003
- ], 8, ["to"])) : (openBlock(), createElementBlock("view", _hoisted_1$W, [
1015
+ ], 8, ["to"])) : (openBlock(), createElementBlock("view", _hoisted_1$Z, [
1004
1016
  _ctx.overlay ? (openBlock(), createBlock(_component_nut_overlay, {
1005
1017
  key: 0,
1006
1018
  visible: _ctx.visible,
@@ -1042,34 +1054,9 @@ function _sfc_render$18(_ctx, _cache, $props, $setup, $data, $options) {
1042
1054
  }, 8, ["name", "onAfterEnter", "onAfterLeave"])
1043
1055
  ]));
1044
1056
  }
1045
- var Popup = /* @__PURE__ */ _export_sfc(_sfc_main$1e, [["render", _sfc_render$18]]);
1046
- const throttle = (func, wait, type) => {
1047
- if (type === 1) {
1048
- var previous = 0;
1049
- } else if (type === 2) {
1050
- var timeout;
1051
- }
1052
- return function() {
1053
- let context = this;
1054
- let args = arguments;
1055
- if (type === 1) {
1056
- let now = Date.now();
1057
- if (now - previous > wait) {
1058
- func.apply(context, args);
1059
- previous = now;
1060
- }
1061
- } else if (type === 2) {
1062
- if (!timeout) {
1063
- timeout = setTimeout(() => {
1064
- timeout = null;
1065
- func.apply(context, args);
1066
- }, wait);
1067
- }
1068
- }
1069
- };
1070
- };
1071
- const { create: create$1d } = createComponent("video");
1072
- const _sfc_main$1d = create$1d({
1057
+ var Popup = /* @__PURE__ */ _export_sfc(_sfc_main$1i, [["render", _sfc_render$1b]]);
1058
+ const { create: create$1h } = createComponent("video");
1059
+ const _sfc_main$1h = create$1h({
1073
1060
  props: {
1074
1061
  source: {
1075
1062
  type: Object,
@@ -1174,7 +1161,6 @@ const _sfc_main$1d = create$1d({
1174
1161
  emit("pause", state.videoElm);
1175
1162
  });
1176
1163
  state.videoElm.addEventListener("ended", playEnded);
1177
- state.videoElm.addEventListener("timeupdate", throttle(getPlayTime, 100, 1));
1178
1164
  }
1179
1165
  };
1180
1166
  const customerInit = () => {
@@ -1198,7 +1184,6 @@ const _sfc_main$1d = create$1d({
1198
1184
  state.videoElm.addEventListener("progress", () => {
1199
1185
  getLoadTime();
1200
1186
  });
1201
- state.videoElm.addEventListener("timeupdate", throttle(getPlayTime, 100, 1));
1202
1187
  state.videoElm.addEventListener("ended", playEnded);
1203
1188
  emit("play", state.videoElm);
1204
1189
  } catch (e) {
@@ -1210,37 +1195,10 @@ const _sfc_main$1d = create$1d({
1210
1195
  }
1211
1196
  }
1212
1197
  };
1213
- const timeFormat = (t) => {
1214
- var h2 = Math.floor(t / 3600);
1215
- if (h2 < 10) {
1216
- h2 = "0" + h2;
1217
- }
1218
- var m = Math.floor(t % 3600 / 60);
1219
- if (m < 10) {
1220
- m = "0" + m;
1221
- }
1222
- var s = Math.round(t % 3600 % 60);
1223
- if (s < 10) {
1224
- s = "0" + s;
1225
- }
1226
- var str = "";
1227
- if (h2 != 0) {
1228
- str = h2 + ":" + m + ":" + s;
1229
- } else {
1230
- str = m + ":" + s;
1231
- }
1232
- return str;
1233
- };
1234
1198
  const getLoadTime = () => {
1235
1199
  if (state.videoSet.loaded)
1236
1200
  state.videoSet.loaded = state.videoElm.buffered.end(0) / state.videoElm.duration * 100;
1237
1201
  };
1238
- const getPlayTime = () => {
1239
- const percent = state.videoElm.currentTime / state.videoElm.duration;
1240
- state.videoSet.progress.current = Math.round(state.videoSet.progress.width * percent);
1241
- state.videoSet.totalTime = timeFormat(state.videoElm.duration);
1242
- state.videoSet.displayTime = timeFormat(state.videoElm.currentTime);
1243
- };
1244
1202
  const playEnded = () => {
1245
1203
  state.state.playing = false;
1246
1204
  state.state.isEnd = true;
@@ -1315,21 +1273,21 @@ const _sfc_main$1d = create$1d({
1315
1273
  });
1316
1274
  }
1317
1275
  });
1318
- const _hoisted_1$V = {
1276
+ const _hoisted_1$Y = {
1319
1277
  class: "nut-video",
1320
1278
  ref: "videocon"
1321
1279
  };
1322
- const _hoisted_2$L = ["muted", "autoplay", "loop", "poster", "controls", "preload"];
1323
- const _hoisted_3$A = ["src", "type"];
1324
- const _hoisted_4$r = { class: "current-time" };
1325
- const _hoisted_5$j = { class: "progress-container" };
1326
- const _hoisted_6$g = {
1280
+ const _hoisted_2$O = ["muted", "autoplay", "loop", "poster", "controls", "preload"];
1281
+ const _hoisted_3$D = ["src", "type"];
1282
+ const _hoisted_4$t = { class: "current-time" };
1283
+ const _hoisted_5$k = { class: "progress-container" };
1284
+ const _hoisted_6$h = {
1327
1285
  class: "progress",
1328
1286
  ref: "progressBar"
1329
1287
  };
1330
- const _hoisted_7$b = /* @__PURE__ */ createElementVNode("div", { class: "move-handle" }, null, -1);
1331
- const _hoisted_8$8 = [
1332
- _hoisted_7$b
1288
+ const _hoisted_7$c = /* @__PURE__ */ createElementVNode("div", { class: "move-handle" }, null, -1);
1289
+ const _hoisted_8$9 = [
1290
+ _hoisted_7$c
1333
1291
  ];
1334
1292
  const _hoisted_9$6 = {
1335
1293
  class: "played",
@@ -1338,8 +1296,8 @@ const _hoisted_9$6 = {
1338
1296
  const _hoisted_10$4 = { class: "duration-time" };
1339
1297
  const _hoisted_11$4 = { class: "nut-video-error" };
1340
1298
  const _hoisted_12$4 = /* @__PURE__ */ createElementVNode("p", { class: "lose" }, "\u89C6\u9891\u52A0\u8F7D\u5931\u8D25", -1);
1341
- function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
1342
- return openBlock(), createElementBlock("div", _hoisted_1$V, [
1299
+ function _sfc_render$1a(_ctx, _cache, $props, $setup, $data, $options) {
1300
+ return openBlock(), createElementBlock("div", _hoisted_1$Y, [
1343
1301
  createElementVNode("video", {
1344
1302
  ref: "root",
1345
1303
  class: "nut-video-player",
@@ -1354,8 +1312,8 @@ function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
1354
1312
  createElementVNode("source", {
1355
1313
  src: _ctx.source.src,
1356
1314
  type: _ctx.source.type
1357
- }, null, 8, _hoisted_3$A)
1358
- ], 40, _hoisted_2$L),
1315
+ }, null, 8, _hoisted_3$D)
1316
+ ], 40, _hoisted_2$O),
1359
1317
  _ctx.showToolbox && !_ctx.isDisabled ? (openBlock(), createElementBlock("div", {
1360
1318
  key: 0,
1361
1319
  class: "playing-mask",
@@ -1377,9 +1335,9 @@ function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
1377
1335
  class: "control-play-btn",
1378
1336
  onClick: _cache[3] || (_cache[3] = (...args) => _ctx.play && _ctx.play(...args))
1379
1337
  }),
1380
- createElementVNode("div", _hoisted_4$r, toDisplayString(_ctx.videoSet.displayTime), 1),
1381
- createElementVNode("div", _hoisted_5$j, [
1382
- createElementVNode("div", _hoisted_6$g, [
1338
+ createElementVNode("div", _hoisted_4$t, toDisplayString(_ctx.videoSet.displayTime), 1),
1339
+ createElementVNode("div", _hoisted_5$k, [
1340
+ createElementVNode("div", _hoisted_6$h, [
1383
1341
  createElementVNode("div", {
1384
1342
  class: "buffered",
1385
1343
  style: normalizeStyle({ width: `${_ctx.videoSet.loaded}%` })
@@ -1392,7 +1350,7 @@ function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
1392
1350
  onTouchmove: _cache[4] || (_cache[4] = withModifiers(($event) => _ctx.touchSlidMove($event), ["stop", "prevent"])),
1393
1351
  onTouchstart: _cache[5] || (_cache[5] = withModifiers(($event) => _ctx.touchSlidSrart($event), ["stop"])),
1394
1352
  onTouchend: _cache[6] || (_cache[6] = withModifiers(($event) => _ctx.touchSlidEnd($event), ["stop"]))
1395
- }, _hoisted_8$8, 36),
1353
+ }, _hoisted_8$9, 36),
1396
1354
  createElementVNode("div", _hoisted_9$6, null, 512)
1397
1355
  ], 512)
1398
1356
  ]),
@@ -1419,9 +1377,9 @@ function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
1419
1377
  ])
1420
1378
  ], 512);
1421
1379
  }
1422
- var Video = /* @__PURE__ */ _export_sfc(_sfc_main$1d, [["render", _sfc_render$17]]);
1380
+ var Video = /* @__PURE__ */ _export_sfc(_sfc_main$1h, [["render", _sfc_render$1a]]);
1423
1381
  const DISTANCE = 5;
1424
- function useTouch$1() {
1382
+ function useTouch$2() {
1425
1383
  const state = reactive({
1426
1384
  startX: 0,
1427
1385
  startY: 0,
@@ -1468,14 +1426,14 @@ function useTouch$1() {
1468
1426
  move
1469
1427
  };
1470
1428
  }
1471
- function useExpose$1(apis) {
1429
+ function useExpose(apis) {
1472
1430
  const instance = getCurrentInstance();
1473
1431
  if (instance) {
1474
1432
  Object.assign(instance.proxy, apis);
1475
1433
  }
1476
1434
  }
1477
- const { create: create$1c, componentName: componentName$V } = createComponent("swiper");
1478
- const _sfc_main$1c = create$1c({
1435
+ const { create: create$1g, componentName: componentName$Z } = createComponent("swiper");
1436
+ const _sfc_main$1g = create$1g({
1479
1437
  props: {
1480
1438
  width: {
1481
1439
  type: [Number, String],
@@ -1542,9 +1500,9 @@ const _sfc_main$1c = create$1c({
1542
1500
  children: [],
1543
1501
  style: {}
1544
1502
  });
1545
- const touch = useTouch$1();
1503
+ const touch = useTouch$2();
1546
1504
  const classes = computed(() => {
1547
- const prefixCls = componentName$V;
1505
+ const prefixCls = componentName$Z;
1548
1506
  return {
1549
1507
  [prefixCls]: true
1550
1508
  };
@@ -1759,7 +1717,7 @@ const _sfc_main$1c = create$1c({
1759
1717
  size,
1760
1718
  relation
1761
1719
  });
1762
- useExpose$1({
1720
+ useExpose({
1763
1721
  prev,
1764
1722
  next,
1765
1723
  to
@@ -1797,7 +1755,7 @@ const _sfc_main$1c = create$1c({
1797
1755
  state,
1798
1756
  classes,
1799
1757
  container,
1800
- componentName: componentName$V,
1758
+ componentName: componentName$Z,
1801
1759
  isVertical,
1802
1760
  slots,
1803
1761
  activePagination,
@@ -1807,7 +1765,7 @@ const _sfc_main$1c = create$1c({
1807
1765
  };
1808
1766
  }
1809
1767
  });
1810
- function _sfc_render$16(_ctx, _cache, $props, $setup, $data, $options) {
1768
+ function _sfc_render$19(_ctx, _cache, $props, $setup, $data, $options) {
1811
1769
  return openBlock(), createElementBlock("view", {
1812
1770
  ref: "container",
1813
1771
  class: normalizeClass(_ctx.classes),
@@ -1844,15 +1802,9 @@ function _sfc_render$16(_ctx, _cache, $props, $setup, $data, $options) {
1844
1802
  ], 2)) : createCommentVNode("", true)
1845
1803
  ], 34);
1846
1804
  }
1847
- var Swiper = /* @__PURE__ */ _export_sfc(_sfc_main$1c, [["render", _sfc_render$16]]);
1848
- function useExpose(apis) {
1849
- const instance = getCurrentInstance();
1850
- if (instance) {
1851
- Object.assign(instance.proxy, apis);
1852
- }
1853
- }
1854
- const { create: create$1b, componentName: componentName$U } = createComponent("swiper-item");
1855
- const _sfc_main$1b = create$1b({
1805
+ var Swiper = /* @__PURE__ */ _export_sfc(_sfc_main$1g, [["render", _sfc_render$19]]);
1806
+ const { create: create$1f, componentName: componentName$Y } = createComponent("swiper-item");
1807
+ const _sfc_main$1f = create$1f({
1856
1808
  props: {},
1857
1809
  setup(props, { slots }) {
1858
1810
  const parent = inject("parent");
@@ -1861,7 +1813,7 @@ const _sfc_main$1b = create$1b({
1861
1813
  offset: 0
1862
1814
  });
1863
1815
  const classes = computed(() => {
1864
- const prefixCls = componentName$U;
1816
+ const prefixCls = componentName$Y;
1865
1817
  return {
1866
1818
  [prefixCls]: true
1867
1819
  };
@@ -1887,7 +1839,7 @@ const _sfc_main$1b = create$1b({
1887
1839
  };
1888
1840
  }
1889
1841
  });
1890
- function _sfc_render$15(_ctx, _cache, $props, $setup, $data, $options) {
1842
+ function _sfc_render$18(_ctx, _cache, $props, $setup, $data, $options) {
1891
1843
  return openBlock(), createElementBlock("view", {
1892
1844
  class: normalizeClass(_ctx.classes),
1893
1845
  style: normalizeStyle(_ctx.style)
@@ -1895,9 +1847,9 @@ function _sfc_render$15(_ctx, _cache, $props, $setup, $data, $options) {
1895
1847
  renderSlot(_ctx.$slots, "default")
1896
1848
  ], 6);
1897
1849
  }
1898
- var SwiperItem = /* @__PURE__ */ _export_sfc(_sfc_main$1b, [["render", _sfc_render$15]]);
1899
- const { componentName: componentName$T, create: create$1a } = createComponent("imagepreview");
1900
- const _sfc_main$1a = create$1a({
1850
+ var SwiperItem = /* @__PURE__ */ _export_sfc(_sfc_main$1f, [["render", _sfc_render$18]]);
1851
+ const { componentName: componentName$X, create: create$1e } = createComponent("imagepreview");
1852
+ const _sfc_main$1e = create$1e({
1901
1853
  props: {
1902
1854
  show: {
1903
1855
  type: Boolean,
@@ -1930,6 +1882,10 @@ const _sfc_main$1a = create$1a({
1930
1882
  autoplay: {
1931
1883
  type: [Number, String],
1932
1884
  default: 3e3
1885
+ },
1886
+ isWrapTeleport: {
1887
+ type: Boolean,
1888
+ default: false
1933
1889
  }
1934
1890
  },
1935
1891
  emits: ["close"],
@@ -1982,7 +1938,6 @@ const _sfc_main$1a = create$1a({
1982
1938
  state.eleImg.style.transform = "scale(" + state.store.scale + ")";
1983
1939
  };
1984
1940
  const onTouchStart = (event) => {
1985
- console.log("start");
1986
1941
  const curTouchTime = new Date().getTime();
1987
1942
  if (curTouchTime - state.lastTouchEndTime < 300) {
1988
1943
  const store2 = state.store;
@@ -2034,7 +1989,6 @@ const _sfc_main$1a = create$1a({
2034
1989
  }
2035
1990
  };
2036
1991
  const onTouchEnd = () => {
2037
- console.log("end");
2038
1992
  state.lastTouchEndTime = new Date().getTime();
2039
1993
  const store = state.store;
2040
1994
  store.moveable = false;
@@ -2070,9 +2024,9 @@ const _sfc_main$1a = create$1a({
2070
2024
  });
2071
2025
  }
2072
2026
  });
2073
- const _hoisted_1$U = ["src"];
2074
- const _hoisted_2$K = { class: "nut-imagepreview-index" };
2075
- function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
2027
+ const _hoisted_1$X = ["src"];
2028
+ const _hoisted_2$N = { class: "nut-imagepreview-index" };
2029
+ function _sfc_render$17(_ctx, _cache, $props, $setup, $data, $options) {
2076
2030
  const _component_nut_video = resolveComponent("nut-video");
2077
2031
  const _component_nut_swiper_item = resolveComponent("nut-swiper-item");
2078
2032
  const _component_nut_swiper = resolveComponent("nut-swiper");
@@ -2081,6 +2035,7 @@ function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
2081
2035
  "pop-class": "custom-pop",
2082
2036
  visible: _ctx.showPop,
2083
2037
  "onUpdate:visible": _cache[2] || (_cache[2] = ($event) => _ctx.showPop = $event),
2038
+ isWrapTeleport: _ctx.isWrapTeleport,
2084
2039
  onClick: _ctx.onClose,
2085
2040
  style: { "width": "100%" }
2086
2041
  }, {
@@ -2120,7 +2075,7 @@ function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
2120
2075
  createElementVNode("img", {
2121
2076
  src: item.src,
2122
2077
  class: "nut-imagepreview-img"
2123
- }, null, 8, _hoisted_1$U)
2078
+ }, null, 8, _hoisted_1$X)
2124
2079
  ]),
2125
2080
  _: 2
2126
2081
  }, 1024);
@@ -2129,12 +2084,12 @@ function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
2129
2084
  _: 1
2130
2085
  }, 8, ["auto-play", "onChange", "init-page", "pagination-visible", "pagination-color"])) : createCommentVNode("", true)
2131
2086
  ], 32),
2132
- createElementVNode("view", _hoisted_2$K, toDisplayString(_ctx.active) + " / " + toDisplayString(_ctx.images.length + _ctx.videos.length), 1)
2087
+ createElementVNode("view", _hoisted_2$N, toDisplayString(_ctx.active) + " / " + toDisplayString(_ctx.images.length + _ctx.videos.length), 1)
2133
2088
  ]),
2134
2089
  _: 1
2135
- }, 8, ["visible", "onClick"]);
2090
+ }, 8, ["visible", "isWrapTeleport", "onClick"]);
2136
2091
  }
2137
- var ImagePreview = /* @__PURE__ */ _export_sfc(_sfc_main$1a, [["render", _sfc_render$14]]);
2092
+ var ImagePreview = /* @__PURE__ */ _export_sfc(_sfc_main$1e, [["render", _sfc_render$17]]);
2138
2093
  class ImagePreviewOptions {
2139
2094
  constructor() {
2140
2095
  __publicField(this, "show", false);
@@ -2182,17 +2137,180 @@ _ImagePreview.install = (app) => {
2182
2137
  app.use(ImagePreview);
2183
2138
  app.config.globalProperties.$imagepreview = _ImagePreview;
2184
2139
  };
2185
- const MIN_DISTANCE = 10;
2186
- function getDirection(x, y) {
2187
- if (x > y && x > MIN_DISTANCE) {
2140
+ function isWindow(val) {
2141
+ return val === window;
2142
+ }
2143
+ const useRect = (elementRef) => {
2144
+ const element = unref(elementRef);
2145
+ if (isWindow(element)) {
2146
+ const width = element.innerWidth;
2147
+ const height = element.innerHeight;
2148
+ return {
2149
+ top: 0,
2150
+ left: 0,
2151
+ right: width,
2152
+ bottom: height,
2153
+ width,
2154
+ height
2155
+ };
2156
+ }
2157
+ if (element && element.getBoundingClientRect) {
2158
+ return element.getBoundingClientRect();
2159
+ }
2160
+ return {
2161
+ top: 0,
2162
+ left: 0,
2163
+ right: 0,
2164
+ bottom: 0,
2165
+ width: 0,
2166
+ height: 0
2167
+ };
2168
+ };
2169
+ const { componentName: componentName$W, create: create$1d } = createComponent("sticky");
2170
+ const _sfc_main$1d = create$1d({
2171
+ props: {
2172
+ position: {
2173
+ type: String,
2174
+ default: "top"
2175
+ },
2176
+ top: {
2177
+ type: [Number, String],
2178
+ default: 0
2179
+ },
2180
+ bottom: {
2181
+ type: [Number, String],
2182
+ default: 0
2183
+ },
2184
+ container: {
2185
+ type: Object
2186
+ },
2187
+ zIndex: {
2188
+ type: [Number, String],
2189
+ default: 2e3
2190
+ }
2191
+ },
2192
+ emits: ["change", "scroll"],
2193
+ setup(props, { emit, slots }) {
2194
+ const root = ref();
2195
+ const state = reactive({
2196
+ width: 0,
2197
+ height: 0,
2198
+ fixed: false,
2199
+ transform: 0
2200
+ });
2201
+ const rootStyle = computed(() => {
2202
+ const { fixed, width, height } = state;
2203
+ if (fixed) {
2204
+ return {
2205
+ width: `${width}px`,
2206
+ height: `${height}px`
2207
+ };
2208
+ }
2209
+ });
2210
+ const stickyStyle = computed(() => {
2211
+ if (!state.fixed)
2212
+ return;
2213
+ const style = {
2214
+ width: `${state.width}px`,
2215
+ height: `${state.height}px`,
2216
+ [props.position]: `${offset.value}px`,
2217
+ zIndex: +props.zIndex
2218
+ };
2219
+ if (state.transform)
2220
+ style.transform = `translate3d(0, ${state.transform}px, 0)`;
2221
+ return style;
2222
+ });
2223
+ const offset = computed(() => {
2224
+ return props.position === "top" ? props.top : props.bottom;
2225
+ });
2226
+ const isHidden = (elementRef) => {
2227
+ const el = unref(elementRef);
2228
+ if (!el)
2229
+ return false;
2230
+ const style = window.getComputedStyle(el);
2231
+ const hidden = style.display === "none";
2232
+ const parentHidden = el.offsetParent === null && style.position !== "fixed";
2233
+ return hidden || parentHidden;
2234
+ };
2235
+ const isExistRoot = () => {
2236
+ if (!root.value || isHidden(root))
2237
+ return false;
2238
+ return true;
2239
+ };
2240
+ const getScrollTop = (el) => {
2241
+ return Math.max(0, "scrollTop" in el ? el.scrollTop : el.pageYOffset);
2242
+ };
2243
+ const renderFixed = () => {
2244
+ var _a;
2245
+ return h("view", {
2246
+ style: stickyStyle.value,
2247
+ class: state.fixed ? `${componentName$W} nut-sticky--fixed` : componentName$W
2248
+ }, (_a = slots.default) == null ? void 0 : _a.call(slots));
2249
+ };
2250
+ const onScroll = () => {
2251
+ if (!isExistRoot())
2252
+ return;
2253
+ const { container, position } = props;
2254
+ const scrollTop = getScrollTop(window);
2255
+ const rootRect = useRect(root);
2256
+ if (rootRect.width || rootRect.height) {
2257
+ state.width = rootRect.width;
2258
+ state.height = rootRect.height;
2259
+ }
2260
+ if (position === "top") {
2261
+ if (container) {
2262
+ const containerRect = useRect(container);
2263
+ const diff = containerRect.bottom - +offset.value - state.height;
2264
+ state.fixed = +offset.value > rootRect.top && containerRect.bottom > 0;
2265
+ state.transform = diff < 0 ? diff : 0;
2266
+ } else {
2267
+ state.fixed = offset.value > rootRect.top;
2268
+ }
2269
+ } else if (position === "bottom") {
2270
+ const clientHeight = document.documentElement.clientHeight;
2271
+ if (container) {
2272
+ const containerRect = useRect(container);
2273
+ const diff = clientHeight - containerRect.top - +offset.value - state.height;
2274
+ state.fixed = clientHeight - +offset.value < rootRect.bottom && clientHeight > containerRect.top;
2275
+ state.transform = diff < 0 ? -diff : 0;
2276
+ } else {
2277
+ state.fixed = clientHeight - +offset.value < rootRect.bottom;
2278
+ }
2279
+ }
2280
+ emit("scroll", {
2281
+ top: scrollTop,
2282
+ fixed: state.fixed
2283
+ });
2284
+ };
2285
+ watch(() => state.fixed, (val) => {
2286
+ emit("change", val);
2287
+ });
2288
+ onMounted(() => {
2289
+ window.addEventListener("scroll", onScroll);
2290
+ onScroll();
2291
+ });
2292
+ onUnmounted(() => {
2293
+ window.removeEventListener("scroll", onScroll);
2294
+ });
2295
+ return () => {
2296
+ return h("view", {
2297
+ style: rootStyle.value,
2298
+ ref: root
2299
+ }, [renderFixed()]);
2300
+ };
2301
+ }
2302
+ });
2303
+ const MIN_DISTANCE$1 = 10;
2304
+ function getDirection$1(x, y) {
2305
+ if (x > y && x > MIN_DISTANCE$1) {
2188
2306
  return "horizontal";
2189
2307
  }
2190
- if (y > x && y > MIN_DISTANCE) {
2308
+ if (y > x && y > MIN_DISTANCE$1) {
2191
2309
  return "vertical";
2192
2310
  }
2193
2311
  return "";
2194
2312
  }
2195
- function useTouch() {
2313
+ function useTouch$1() {
2196
2314
  const startX = ref(0);
2197
2315
  const startY = ref(0);
2198
2316
  const deltaX = ref(0);
@@ -2221,7 +2339,7 @@ function useTouch() {
2221
2339
  offsetX.value = Math.abs(deltaX.value);
2222
2340
  offsetY.value = Math.abs(deltaY.value);
2223
2341
  if (!direction.value) {
2224
- direction.value = getDirection(offsetX.value, offsetY.value);
2342
+ direction.value = getDirection$1(offsetX.value, offsetY.value);
2225
2343
  }
2226
2344
  };
2227
2345
  return {
@@ -2239,8 +2357,8 @@ function useTouch() {
2239
2357
  isHorizontal
2240
2358
  };
2241
2359
  }
2242
- const { componentName: componentName$S, create: create$19 } = createComponent("swipe");
2243
- const _sfc_main$19 = create$19({
2360
+ const { componentName: componentName$V, create: create$1c } = createComponent("swipe");
2361
+ const _sfc_main$1c = create$1c({
2244
2362
  props: {
2245
2363
  name: {
2246
2364
  type: String,
@@ -2262,7 +2380,7 @@ const _sfc_main$19 = create$19({
2262
2380
  emits: ["open", "close"],
2263
2381
  setup(props, { emit }) {
2264
2382
  const classes = computed(() => {
2265
- const prefixCls = componentName$S;
2383
+ const prefixCls = componentName$V;
2266
2384
  return {
2267
2385
  [prefixCls]: true
2268
2386
  };
@@ -2328,7 +2446,7 @@ const _sfc_main$19 = create$19({
2328
2446
  }
2329
2447
  state.offset = offset;
2330
2448
  };
2331
- const touch = useTouch();
2449
+ const touch = useTouch$1();
2332
2450
  const touchMethods = {
2333
2451
  onTouchStart(event) {
2334
2452
  if (props.disabled)
@@ -2386,16 +2504,16 @@ const _sfc_main$19 = create$19({
2386
2504
  });
2387
2505
  }
2388
2506
  });
2389
- const _hoisted_1$T = {
2507
+ const _hoisted_1$W = {
2390
2508
  class: "nut-swipe__left",
2391
2509
  ref: "leftRef"
2392
2510
  };
2393
- const _hoisted_2$J = { class: "nut-swipe__content" };
2394
- const _hoisted_3$z = {
2511
+ const _hoisted_2$M = { class: "nut-swipe__content" };
2512
+ const _hoisted_3$C = {
2395
2513
  class: "nut-swipe__right",
2396
2514
  ref: "rightRef"
2397
2515
  };
2398
- function _sfc_render$13(_ctx, _cache, $props, $setup, $data, $options) {
2516
+ function _sfc_render$16(_ctx, _cache, $props, $setup, $data, $options) {
2399
2517
  return openBlock(), createElementBlock("view", {
2400
2518
  class: normalizeClass(_ctx.classes),
2401
2519
  style: normalizeStyle(_ctx.touchStyle),
@@ -2404,20 +2522,20 @@ function _sfc_render$13(_ctx, _cache, $props, $setup, $data, $options) {
2404
2522
  onTouchend: _cache[2] || (_cache[2] = (...args) => _ctx.onTouchEnd && _ctx.onTouchEnd(...args)),
2405
2523
  onTouchcancel: _cache[3] || (_cache[3] = (...args) => _ctx.onTouchEnd && _ctx.onTouchEnd(...args))
2406
2524
  }, [
2407
- createElementVNode("view", _hoisted_1$T, [
2525
+ createElementVNode("view", _hoisted_1$W, [
2408
2526
  renderSlot(_ctx.$slots, "left")
2409
2527
  ], 512),
2410
- createElementVNode("view", _hoisted_2$J, [
2528
+ createElementVNode("view", _hoisted_2$M, [
2411
2529
  renderSlot(_ctx.$slots, "default")
2412
2530
  ]),
2413
- createElementVNode("view", _hoisted_3$z, [
2531
+ createElementVNode("view", _hoisted_3$C, [
2414
2532
  renderSlot(_ctx.$slots, "right")
2415
2533
  ], 512)
2416
2534
  ], 38);
2417
2535
  }
2418
- var Swipe = /* @__PURE__ */ _export_sfc(_sfc_main$19, [["render", _sfc_render$13]]);
2419
- const { componentName: componentName$R, create: create$18 } = createComponent("actionsheet");
2420
- const _sfc_main$18 = create$18({
2536
+ var Swipe = /* @__PURE__ */ _export_sfc(_sfc_main$1c, [["render", _sfc_render$16]]);
2537
+ const { componentName: componentName$U, create: create$1b } = createComponent("actionsheet");
2538
+ const _sfc_main$1b = create$1b({
2421
2539
  props: __spreadProps(__spreadValues({}, popupProps), {
2422
2540
  cancelTxt: {
2423
2541
  type: String,
@@ -2450,12 +2568,16 @@ const _sfc_main$18 = create$18({
2450
2568
  menuItems: {
2451
2569
  type: Array,
2452
2570
  default: () => []
2571
+ },
2572
+ isWrapTeleport: {
2573
+ type: Boolean,
2574
+ default: true
2453
2575
  }
2454
2576
  }),
2455
- emits: ["cancel", "choose", "update:visible"],
2577
+ emits: ["cancel", "close", "choose", "update:visible"],
2456
2578
  setup(props, { emit }) {
2457
2579
  const classes = computed(() => {
2458
- const prefixCls = componentName$R;
2580
+ const prefixCls = componentName$U;
2459
2581
  return {
2460
2582
  [prefixCls]: true
2461
2583
  };
@@ -2486,22 +2608,22 @@ const _sfc_main$18 = create$18({
2486
2608
  };
2487
2609
  }
2488
2610
  });
2489
- const _hoisted_1$S = { class: "nut-actionsheet-panel" };
2490
- const _hoisted_2$I = {
2611
+ const _hoisted_1$V = { class: "nut-actionsheet-panel" };
2612
+ const _hoisted_2$L = {
2491
2613
  key: 0,
2492
2614
  class: "nut-actionsheet-title"
2493
2615
  };
2494
- const _hoisted_3$y = {
2616
+ const _hoisted_3$B = {
2495
2617
  key: 1,
2496
2618
  class: "nut-actionsheet-item desc"
2497
2619
  };
2498
- const _hoisted_4$q = {
2620
+ const _hoisted_4$s = {
2499
2621
  key: 2,
2500
2622
  class: "nut-actionsheet-menu"
2501
2623
  };
2502
- const _hoisted_5$i = ["onClick"];
2503
- const _hoisted_6$f = { class: "subdesc" };
2504
- function _sfc_render$12(_ctx, _cache, $props, $setup, $data, $options) {
2624
+ const _hoisted_5$j = ["onClick"];
2625
+ const _hoisted_6$g = { class: "subdesc" };
2626
+ function _sfc_render$15(_ctx, _cache, $props, $setup, $data, $options) {
2505
2627
  const _component_nut_popup = resolveComponent("nut-popup");
2506
2628
  return openBlock(), createElementBlock("view", {
2507
2629
  class: normalizeClass(_ctx.classes)
@@ -2509,15 +2631,16 @@ function _sfc_render$12(_ctx, _cache, $props, $setup, $data, $options) {
2509
2631
  createVNode(_component_nut_popup, {
2510
2632
  "pop-class": "popclass",
2511
2633
  visible: _ctx.visible,
2634
+ isWrapTeleport: _ctx.isWrapTeleport,
2512
2635
  position: "bottom",
2513
2636
  round: "",
2514
2637
  onClickOverlay: _ctx.close
2515
2638
  }, {
2516
2639
  default: withCtx(() => [
2517
- createElementVNode("view", _hoisted_1$S, [
2518
- _ctx.title ? (openBlock(), createElementBlock("view", _hoisted_2$I, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
2519
- _ctx.description ? (openBlock(), createElementBlock("view", _hoisted_3$y, toDisplayString(_ctx.description), 1)) : createCommentVNode("", true),
2520
- _ctx.menuItems.length ? (openBlock(), createElementBlock("view", _hoisted_4$q, [
2640
+ createElementVNode("view", _hoisted_1$V, [
2641
+ _ctx.title ? (openBlock(), createElementBlock("view", _hoisted_2$L, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
2642
+ _ctx.description ? (openBlock(), createElementBlock("view", _hoisted_3$B, toDisplayString(_ctx.description), 1)) : createCommentVNode("", true),
2643
+ _ctx.menuItems.length ? (openBlock(), createElementBlock("view", _hoisted_4$s, [
2521
2644
  (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.menuItems, (item, index) => {
2522
2645
  return openBlock(), createElementBlock("view", {
2523
2646
  class: normalizeClass(["nut-actionsheet-item", { "nut-actionsheet-item-disabled": item.disable }]),
@@ -2526,8 +2649,8 @@ function _sfc_render$12(_ctx, _cache, $props, $setup, $data, $options) {
2526
2649
  onClick: ($event) => _ctx.chooseItem(item, index)
2527
2650
  }, [
2528
2651
  createTextVNode(toDisplayString(item[_ctx.optionTag]), 1),
2529
- createElementVNode("view", _hoisted_6$f, toDisplayString(item[_ctx.optionSubTag]), 1)
2530
- ], 14, _hoisted_5$i);
2652
+ createElementVNode("view", _hoisted_6$g, toDisplayString(item[_ctx.optionSubTag]), 1)
2653
+ ], 14, _hoisted_5$j);
2531
2654
  }), 128))
2532
2655
  ])) : createCommentVNode("", true),
2533
2656
  _ctx.cancelTxt ? (openBlock(), createElementBlock("view", {
@@ -2538,12 +2661,12 @@ function _sfc_render$12(_ctx, _cache, $props, $setup, $data, $options) {
2538
2661
  ])
2539
2662
  ]),
2540
2663
  _: 1
2541
- }, 8, ["visible", "onClickOverlay"])
2664
+ }, 8, ["visible", "isWrapTeleport", "onClickOverlay"])
2542
2665
  ], 2);
2543
2666
  }
2544
- var ActionSheet = /* @__PURE__ */ _export_sfc(_sfc_main$18, [["render", _sfc_render$12]]);
2545
- const { componentName: componentName$Q, create: create$17 } = createComponent("backtop");
2546
- const _sfc_main$17 = create$17({
2667
+ var ActionSheet = /* @__PURE__ */ _export_sfc(_sfc_main$1b, [["render", _sfc_render$15]]);
2668
+ const { componentName: componentName$T, create: create$1a } = createComponent("backtop");
2669
+ const _sfc_main$1a = create$1a({
2547
2670
  props: {
2548
2671
  bottom: {
2549
2672
  type: Number,
@@ -2554,8 +2677,8 @@ const _sfc_main$17 = create$17({
2554
2677
  default: 10
2555
2678
  },
2556
2679
  elId: {
2557
- type: String,
2558
- default: ""
2680
+ type: [String, Element],
2681
+ default: "body"
2559
2682
  },
2560
2683
  distance: {
2561
2684
  type: Number,
@@ -2584,7 +2707,7 @@ const _sfc_main$17 = create$17({
2584
2707
  keepAlive: false
2585
2708
  });
2586
2709
  const classes = computed(() => {
2587
- const prefixCls = componentName$Q;
2710
+ const prefixCls = componentName$T;
2588
2711
  return {
2589
2712
  [prefixCls]: true,
2590
2713
  show: state.backTop
@@ -2675,7 +2798,7 @@ const _sfc_main$17 = create$17({
2675
2798
  };
2676
2799
  }
2677
2800
  });
2678
- function _sfc_render$11(_ctx, _cache, $props, $setup, $data, $options) {
2801
+ function _sfc_render$14(_ctx, _cache, $props, $setup, $data, $options) {
2679
2802
  const _component_nut_icon = resolveComponent("nut-icon");
2680
2803
  return openBlock(), createElementBlock("div", {
2681
2804
  class: normalizeClass(_ctx.classes),
@@ -2691,9 +2814,9 @@ function _sfc_render$11(_ctx, _cache, $props, $setup, $data, $options) {
2691
2814
  ])
2692
2815
  ], 6);
2693
2816
  }
2694
- var BackTop = /* @__PURE__ */ _export_sfc(_sfc_main$17, [["render", _sfc_render$11]]);
2695
- const { create: create$16 } = createComponent("collapse");
2696
- const _sfc_main$16 = create$16({
2817
+ var BackTop = /* @__PURE__ */ _export_sfc(_sfc_main$1a, [["render", _sfc_render$14]]);
2818
+ const { create: create$19 } = createComponent("collapse");
2819
+ const _sfc_main$19 = create$19({
2697
2820
  props: {
2698
2821
  active: {
2699
2822
  type: [String, Number, Array]
@@ -2766,14 +2889,14 @@ const _sfc_main$16 = create$16({
2766
2889
  });
2767
2890
  }
2768
2891
  });
2769
- function _sfc_render$10(_ctx, _cache, $props, $setup, $data, $options) {
2892
+ function _sfc_render$13(_ctx, _cache, $props, $setup, $data, $options) {
2770
2893
  return openBlock(), createElementBlock("view", null, [
2771
2894
  renderSlot(_ctx.$slots, "default")
2772
2895
  ]);
2773
2896
  }
2774
- var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main$16, [["render", _sfc_render$10]]);
2775
- const { create: create$15, componentName: componentName$P } = createComponent("collapse-item");
2776
- const _sfc_main$15 = create$15({
2897
+ var Collapse = /* @__PURE__ */ _export_sfc(_sfc_main$19, [["render", _sfc_render$13]]);
2898
+ const { create: create$18, componentName: componentName$S } = createComponent("collapse-item");
2899
+ const _sfc_main$18 = create$18({
2777
2900
  props: {
2778
2901
  title: {
2779
2902
  type: String,
@@ -2800,7 +2923,7 @@ const _sfc_main$15 = create$15({
2800
2923
  const collapse = inject("collapseParent");
2801
2924
  const parent = reactive(collapse);
2802
2925
  const classes = computed(() => {
2803
- const prefixCls = componentName$P;
2926
+ const prefixCls = componentName$S;
2804
2927
  return {
2805
2928
  [prefixCls]: true,
2806
2929
  [`${prefixCls}-icon`]: parent.props.icon
@@ -2832,7 +2955,9 @@ const _sfc_main$15 = create$15({
2832
2955
  const contentRef = ref(null);
2833
2956
  const onTransitionEnd = () => {
2834
2957
  const wrapperRefEle = document.getElementsByClassName("collapse-wrapper")[0];
2835
- wrapperRefEle.style.willChange = "auto";
2958
+ if (wrapperRefEle) {
2959
+ wrapperRefEle.style.willChange = "auto";
2960
+ }
2836
2961
  };
2837
2962
  const animation = () => {
2838
2963
  const wrapperRefEle = wrapperRef.value;
@@ -2933,23 +3058,23 @@ const _sfc_main$15 = create$15({
2933
3058
  });
2934
3059
  }
2935
3060
  });
2936
- const _hoisted_1$R = { class: "collapse-title" };
2937
- const _hoisted_2$H = { class: "collapse-title-value" };
2938
- const _hoisted_3$x = ["innerHTML"];
2939
- const _hoisted_4$p = {
3061
+ const _hoisted_1$U = { class: "collapse-title" };
3062
+ const _hoisted_2$K = { class: "collapse-title-value" };
3063
+ const _hoisted_3$A = ["innerHTML"];
3064
+ const _hoisted_4$r = {
2940
3065
  key: 0,
2941
3066
  class: "subTitle"
2942
3067
  };
2943
- const _hoisted_5$h = ["innerHTML"];
2944
- const _hoisted_6$e = {
3068
+ const _hoisted_5$i = ["innerHTML"];
3069
+ const _hoisted_6$f = {
2945
3070
  class: "collapse-wrapper",
2946
3071
  ref: "wrapperRef"
2947
3072
  };
2948
- const _hoisted_7$a = {
3073
+ const _hoisted_7$b = {
2949
3074
  class: "collapse-content",
2950
3075
  ref: "contentRef"
2951
3076
  };
2952
- function _sfc_render$$(_ctx, _cache, $props, $setup, $data, $options) {
3077
+ function _sfc_render$12(_ctx, _cache, $props, $setup, $data, $options) {
2953
3078
  const _component_nut_icon = resolveComponent("nut-icon");
2954
3079
  return openBlock(), createElementBlock("view", {
2955
3080
  class: normalizeClass(_ctx.classes)
@@ -2958,9 +3083,9 @@ function _sfc_render$$(_ctx, _cache, $props, $setup, $data, $options) {
2958
3083
  class: normalizeClass(["collapse-item", { "item-expanded": _ctx.openExpanded }, { "nut-collapse-item-disabled": _ctx.disabled }]),
2959
3084
  onClick: _cache[0] || (_cache[0] = (...args) => _ctx.toggleOpen && _ctx.toggleOpen(...args))
2960
3085
  }, [
2961
- createElementVNode("view", _hoisted_1$R, [
3086
+ createElementVNode("view", _hoisted_1$U, [
2962
3087
  createElementVNode("view", null, [
2963
- createElementVNode("view", _hoisted_2$H, [
3088
+ createElementVNode("view", _hoisted_2$K, [
2964
3089
  _ctx.titleIcon ? (openBlock(), createBlock(_component_nut_icon, {
2965
3090
  key: 0,
2966
3091
  name: _ctx.titleIcon,
@@ -2972,17 +3097,17 @@ function _sfc_render$$(_ctx, _cache, $props, $setup, $data, $options) {
2972
3097
  key: 2,
2973
3098
  innerHTML: _ctx.title,
2974
3099
  class: "collapse-icon-title"
2975
- }, null, 8, _hoisted_3$x))
3100
+ }, null, 8, _hoisted_3$A))
2976
3101
  ])
2977
3102
  ])
2978
3103
  ]),
2979
- _ctx.$slots.sTitle ? (openBlock(), createElementBlock("view", _hoisted_4$p, [
3104
+ _ctx.$slots.sTitle ? (openBlock(), createElementBlock("view", _hoisted_4$r, [
2980
3105
  renderSlot(_ctx.$slots, "sTitle")
2981
3106
  ])) : (openBlock(), createElementBlock("view", {
2982
3107
  key: 1,
2983
3108
  innerHTML: _ctx.subTitle,
2984
3109
  class: "subTitle"
2985
- }, null, 8, _hoisted_5$h)),
3110
+ }, null, 8, _hoisted_5$i)),
2986
3111
  _ctx.icon ? (openBlock(), createBlock(_component_nut_icon, {
2987
3112
  key: 2,
2988
3113
  name: _ctx.icon,
@@ -2992,14 +3117,14 @@ function _sfc_render$$(_ctx, _cache, $props, $setup, $data, $options) {
2992
3117
  style: normalizeStyle(_ctx.iconStyle)
2993
3118
  }, null, 8, ["name", "size", "color", "class", "style"])) : createCommentVNode("", true)
2994
3119
  ], 2),
2995
- createElementVNode("view", _hoisted_6$e, [
2996
- createElementVNode("view", _hoisted_7$a, [
3120
+ createElementVNode("view", _hoisted_6$f, [
3121
+ createElementVNode("view", _hoisted_7$b, [
2997
3122
  renderSlot(_ctx.$slots, "default")
2998
3123
  ], 512)
2999
3124
  ], 512)
3000
3125
  ], 2);
3001
3126
  }
3002
- var CollapseItem = /* @__PURE__ */ _export_sfc(_sfc_main$15, [["render", _sfc_render$$]]);
3127
+ var CollapseItem = /* @__PURE__ */ _export_sfc(_sfc_main$18, [["render", _sfc_render$12]]);
3003
3128
  const _window = window;
3004
3129
  function requestAniFrame() {
3005
3130
  if (typeof _window !== "undefined") {
@@ -3013,8 +3138,8 @@ function requestAniFrame() {
3013
3138
  }
3014
3139
  }
3015
3140
  var requestAniFrame$1 = requestAniFrame();
3016
- const { componentName: componentName$O, create: create$14 } = createComponent("drag");
3017
- const _sfc_main$14 = create$14({
3141
+ const { componentName: componentName$R, create: create$17 } = createComponent("drag");
3142
+ const _sfc_main$17 = create$17({
3018
3143
  props: {
3019
3144
  attract: {
3020
3145
  type: Boolean,
@@ -3059,7 +3184,7 @@ const _sfc_main$14 = create$14({
3059
3184
  }
3060
3185
  });
3061
3186
  const classes = computed(() => {
3062
- const prefixCls = componentName$O;
3187
+ const prefixCls = componentName$R;
3063
3188
  return {
3064
3189
  [prefixCls]: true
3065
3190
  };
@@ -3194,7 +3319,7 @@ const _sfc_main$14 = create$14({
3194
3319
  };
3195
3320
  }
3196
3321
  });
3197
- function _sfc_render$_(_ctx, _cache, $props, $setup, $data, $options) {
3322
+ function _sfc_render$11(_ctx, _cache, $props, $setup, $data, $options) {
3198
3323
  return openBlock(), createElementBlock("view", {
3199
3324
  class: normalizeClass(_ctx.classes),
3200
3325
  ref: "myDrag",
@@ -3205,9 +3330,9 @@ function _sfc_render$_(_ctx, _cache, $props, $setup, $data, $options) {
3205
3330
  renderSlot(_ctx.$slots, "default")
3206
3331
  ], 34);
3207
3332
  }
3208
- var Drag = /* @__PURE__ */ _export_sfc(_sfc_main$14, [["render", _sfc_render$_]]);
3209
- const { componentName: componentName$N, create: create$13 } = createComponent("dialog");
3210
- const _sfc_main$13 = create$13({
3333
+ var Drag = /* @__PURE__ */ _export_sfc(_sfc_main$17, [["render", _sfc_render$11]]);
3334
+ const { componentName: componentName$Q, create: create$16 } = createComponent("dialog");
3335
+ const _sfc_main$16 = create$16({
3211
3336
  inheritAttrs: false,
3212
3337
  components: {
3213
3338
  [Popup.name]: Popup,
@@ -3282,7 +3407,7 @@ const _sfc_main$13 = create$13({
3282
3407
  });
3283
3408
  const classes = computed(() => {
3284
3409
  return {
3285
- [componentName$N]: true
3410
+ [componentName$Q]: true
3286
3411
  };
3287
3412
  });
3288
3413
  const update = (val) => {
@@ -3312,12 +3437,12 @@ const _sfc_main$13 = create$13({
3312
3437
  };
3313
3438
  }
3314
3439
  });
3315
- const _hoisted_1$Q = {
3440
+ const _hoisted_1$T = {
3316
3441
  key: 0,
3317
3442
  class: "nut-dialog__header"
3318
3443
  };
3319
- const _hoisted_2$G = ["innerHTML"];
3320
- function _sfc_render$Z(_ctx, _cache, $props, $setup, $data, $options) {
3444
+ const _hoisted_2$J = ["innerHTML"];
3445
+ function _sfc_render$10(_ctx, _cache, $props, $setup, $data, $options) {
3321
3446
  const _component_nut_button = resolveComponent("nut-button");
3322
3447
  const _component_nut_popup = resolveComponent("nut-popup");
3323
3448
  return openBlock(), createBlock(_component_nut_popup, {
@@ -3334,7 +3459,7 @@ function _sfc_render$Z(_ctx, _cache, $props, $setup, $data, $options) {
3334
3459
  createElementVNode("view", {
3335
3460
  class: normalizeClass(_ctx.classes)
3336
3461
  }, [
3337
- _ctx.title ? (openBlock(), createElementBlock("view", _hoisted_1$Q, [
3462
+ _ctx.title ? (openBlock(), createElementBlock("view", _hoisted_1$T, [
3338
3463
  _ctx.$slots.header ? renderSlot(_ctx.$slots, "header", { key: 0 }) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
3339
3464
  createTextVNode(toDisplayString(_ctx.title), 1)
3340
3465
  ], 64))
@@ -3346,7 +3471,7 @@ function _sfc_render$Z(_ctx, _cache, $props, $setup, $data, $options) {
3346
3471
  _ctx.$slots.default ? renderSlot(_ctx.$slots, "default", { key: 0 }) : (openBlock(), createElementBlock("view", {
3347
3472
  key: 1,
3348
3473
  innerHTML: _ctx.content
3349
- }, null, 8, _hoisted_2$G))
3474
+ }, null, 8, _hoisted_2$J))
3350
3475
  ], 4),
3351
3476
  !_ctx.noFooter ? (openBlock(), createElementBlock("view", {
3352
3477
  key: 1,
@@ -3386,7 +3511,7 @@ function _sfc_render$Z(_ctx, _cache, $props, $setup, $data, $options) {
3386
3511
  _: 3
3387
3512
  }, 8, ["teleport", "visible", "close-on-click-overlay", "lock-scroll", "onClickOverlay", "onClickCloseIcon"]);
3388
3513
  }
3389
- var Dialog = /* @__PURE__ */ _export_sfc(_sfc_main$13, [["render", _sfc_render$Z]]);
3514
+ var Dialog = /* @__PURE__ */ _export_sfc(_sfc_main$16, [["render", _sfc_render$10]]);
3390
3515
  class DialogOptions {
3391
3516
  constructor() {
3392
3517
  __publicField(this, "title", "");
@@ -3460,8 +3585,8 @@ _Dialog.install = (app) => {
3460
3585
  app.use(Dialog);
3461
3586
  app.config.globalProperties.$dialog = _Dialog;
3462
3587
  };
3463
- const { componentName: componentName$M, create: create$12 } = createComponent("infiniteloading");
3464
- const _sfc_main$12 = create$12({
3588
+ const { componentName: componentName$P, create: create$15 } = createComponent("infiniteloading");
3589
+ const _sfc_main$15 = create$15({
3465
3590
  props: {
3466
3591
  hasMore: {
3467
3592
  type: Boolean,
@@ -3523,7 +3648,7 @@ const _sfc_main$12 = create$12({
3523
3648
  distance: 0
3524
3649
  });
3525
3650
  const classes = computed(() => {
3526
- const prefixCls = componentName$M;
3651
+ const prefixCls = componentName$P;
3527
3652
  return {
3528
3653
  [prefixCls]: true
3529
3654
  };
@@ -3647,20 +3772,20 @@ const _sfc_main$12 = create$12({
3647
3772
  });
3648
3773
  }
3649
3774
  });
3650
- const _hoisted_1$P = { class: "top-box" };
3651
- const _hoisted_2$F = { class: "top-text" };
3652
- const _hoisted_3$w = { class: "nut-infinite-container" };
3653
- const _hoisted_4$o = { class: "nut-infinite-bottom" };
3654
- const _hoisted_5$g = {
3775
+ const _hoisted_1$S = { class: "top-box" };
3776
+ const _hoisted_2$I = { class: "top-text" };
3777
+ const _hoisted_3$z = { class: "nut-infinite-container" };
3778
+ const _hoisted_4$q = { class: "nut-infinite-bottom" };
3779
+ const _hoisted_5$h = {
3655
3780
  key: 0,
3656
3781
  class: "bottom-box"
3657
3782
  };
3658
- const _hoisted_6$d = { class: "bottom-text" };
3659
- const _hoisted_7$9 = {
3783
+ const _hoisted_6$e = { class: "bottom-text" };
3784
+ const _hoisted_7$a = {
3660
3785
  key: 1,
3661
3786
  class: "tips"
3662
3787
  };
3663
- function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
3788
+ function _sfc_render$$(_ctx, _cache, $props, $setup, $data, $options) {
3664
3789
  const _component_nut_icon = resolveComponent("nut-icon");
3665
3790
  return openBlock(), createElementBlock("view", {
3666
3791
  class: normalizeClass(_ctx.classes),
@@ -3674,31 +3799,31 @@ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
3674
3799
  ref: "refreshTop",
3675
3800
  style: normalizeStyle(_ctx.getStyle)
3676
3801
  }, [
3677
- createElementVNode("view", _hoisted_1$P, [
3802
+ createElementVNode("view", _hoisted_1$S, [
3678
3803
  createVNode(_component_nut_icon, {
3679
3804
  class: "top-img",
3680
3805
  name: _ctx.pullIcon
3681
3806
  }, null, 8, ["name"]),
3682
- createElementVNode("view", _hoisted_2$F, toDisplayString(_ctx.pullTxt), 1)
3807
+ createElementVNode("view", _hoisted_2$I, toDisplayString(_ctx.pullTxt), 1)
3683
3808
  ])
3684
3809
  ], 4),
3685
- createElementVNode("view", _hoisted_3$w, [
3810
+ createElementVNode("view", _hoisted_3$z, [
3686
3811
  renderSlot(_ctx.$slots, "default")
3687
3812
  ]),
3688
- createElementVNode("view", _hoisted_4$o, [
3689
- _ctx.isInfiniting ? (openBlock(), createElementBlock("view", _hoisted_5$g, [
3813
+ createElementVNode("view", _hoisted_4$q, [
3814
+ _ctx.isInfiniting ? (openBlock(), createElementBlock("view", _hoisted_5$h, [
3690
3815
  createVNode(_component_nut_icon, {
3691
3816
  class: "bottom-img",
3692
3817
  name: _ctx.loadIcon
3693
3818
  }, null, 8, ["name"]),
3694
- createElementVNode("view", _hoisted_6$d, toDisplayString(_ctx.loadTxt), 1)
3695
- ])) : !_ctx.hasMore ? (openBlock(), createElementBlock("view", _hoisted_7$9, toDisplayString(_ctx.loadMoreTxt), 1)) : createCommentVNode("", true)
3819
+ createElementVNode("view", _hoisted_6$e, toDisplayString(_ctx.loadTxt), 1)
3820
+ ])) : !_ctx.hasMore ? (openBlock(), createElementBlock("view", _hoisted_7$a, toDisplayString(_ctx.loadMoreTxt), 1)) : createCommentVNode("", true)
3696
3821
  ])
3697
3822
  ], 34);
3698
3823
  }
3699
- var InfiniteLoading = /* @__PURE__ */ _export_sfc(_sfc_main$12, [["render", _sfc_render$Y]]);
3700
- const { componentName: componentName$L, create: create$11 } = createComponent("notify");
3701
- const _sfc_main$11 = create$11({
3824
+ var InfiniteLoading = /* @__PURE__ */ _export_sfc(_sfc_main$15, [["render", _sfc_render$$]]);
3825
+ const { componentName: componentName$O, create: create$14 } = createComponent("notify");
3826
+ const _sfc_main$14 = create$14({
3702
3827
  components: {
3703
3828
  [Popup.name]: Popup
3704
3829
  },
@@ -3768,14 +3893,14 @@ const _sfc_main$11 = create$11({
3768
3893
  return { state, hide, onAfterLeave, clickCover };
3769
3894
  }
3770
3895
  });
3771
- function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
3896
+ function _sfc_render$_(_ctx, _cache, $props, $setup, $data, $options) {
3772
3897
  return openBlock(), createBlock(Transition, {
3773
3898
  name: "toast-fade",
3774
3899
  onAfterLeave: _ctx.onAfterLeave
3775
3900
  }, {
3776
3901
  default: withCtx(() => [
3777
3902
  withDirectives(createElementVNode("view", {
3778
- class: normalizeClass(["popup-top", "nut-notify", `nut-notify--${_ctx.type}`, { className: _ctx.className }]),
3903
+ class: normalizeClass(["popup-top", "nut-notify", `nut-notify--${_ctx.type}`, [_ctx.className]]),
3779
3904
  style: normalizeStyle({ color: _ctx.color, background: _ctx.background }),
3780
3905
  onClick: _cache[0] || (_cache[0] = (...args) => _ctx.clickCover && _ctx.clickCover(...args))
3781
3906
  }, [
@@ -3789,7 +3914,7 @@ function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
3789
3914
  _: 3
3790
3915
  }, 8, ["onAfterLeave"]);
3791
3916
  }
3792
- var Notify = /* @__PURE__ */ _export_sfc(_sfc_main$11, [["render", _sfc_render$X]]);
3917
+ var Notify = /* @__PURE__ */ _export_sfc(_sfc_main$14, [["render", _sfc_render$_]]);
3793
3918
  const defaultOptions$1 = {
3794
3919
  type: "base",
3795
3920
  showPopup: false,
@@ -3898,37 +4023,8 @@ const NotifyFunction = {
3898
4023
  app.config.globalProperties.$notify = NotifyFunction;
3899
4024
  }
3900
4025
  };
3901
- function isWindow(val) {
3902
- return val === window;
3903
- }
3904
- const useRect = (elementRef) => {
3905
- const element = unref(elementRef);
3906
- if (isWindow(element)) {
3907
- const width = element.innerWidth;
3908
- const height = element.innerHeight;
3909
- return {
3910
- top: 0,
3911
- left: 0,
3912
- right: width,
3913
- bottom: height,
3914
- width,
3915
- height
3916
- };
3917
- }
3918
- if (element && element.getBoundingClientRect) {
3919
- return element.getBoundingClientRect();
3920
- }
3921
- return {
3922
- top: 0,
3923
- left: 0,
3924
- right: 0,
3925
- bottom: 0,
3926
- width: 0,
3927
- height: 0
3928
- };
3929
- };
3930
- const { componentName: componentName$K, create: create$10 } = createComponent("range");
3931
- const _sfc_main$10 = create$10({
4026
+ const { componentName: componentName$N, create: create$13 } = createComponent("range");
4027
+ const _sfc_main$13 = create$13({
3932
4028
  props: {
3933
4029
  range: {
3934
4030
  type: Boolean,
@@ -3970,10 +4066,10 @@ const _sfc_main$10 = create$10({
3970
4066
  let currentValue;
3971
4067
  const root = ref();
3972
4068
  const dragStatus = ref();
3973
- const touch = useTouch();
4069
+ const touch = useTouch$1();
3974
4070
  const scope = computed(() => Number(props.max) - Number(props.min));
3975
4071
  const classes = computed(() => {
3976
- const prefixCls = componentName$K;
4072
+ const prefixCls = componentName$N;
3977
4073
  return {
3978
4074
  [prefixCls]: true,
3979
4075
  [`${prefixCls}-disabled`]: props.disabled,
@@ -4124,28 +4220,28 @@ const _sfc_main$10 = create$10({
4124
4220
  });
4125
4221
  }
4126
4222
  });
4127
- const _hoisted_1$O = { class: "nut-range-container" };
4128
- const _hoisted_2$E = {
4223
+ const _hoisted_1$R = { class: "nut-range-container" };
4224
+ const _hoisted_2$H = {
4129
4225
  key: 0,
4130
4226
  class: "min"
4131
4227
  };
4132
- const _hoisted_3$v = ["tabindex", "aria-valuemin", "aria-valuenow", "aria-valuemax", "onTouchstart"];
4133
- const _hoisted_4$n = {
4228
+ const _hoisted_3$y = ["tabindex", "aria-valuemin", "aria-valuenow", "aria-valuemax", "onTouchstart"];
4229
+ const _hoisted_4$p = {
4134
4230
  key: 0,
4135
4231
  class: "number"
4136
4232
  };
4137
- const _hoisted_5$f = ["tabindex", "aria-valuemin", "aria-valuenow", "aria-valuemax"];
4138
- const _hoisted_6$c = {
4233
+ const _hoisted_5$g = ["tabindex", "aria-valuemin", "aria-valuenow", "aria-valuemax"];
4234
+ const _hoisted_6$d = {
4139
4235
  key: 0,
4140
4236
  class: "number"
4141
4237
  };
4142
- const _hoisted_7$8 = {
4238
+ const _hoisted_7$9 = {
4143
4239
  key: 1,
4144
4240
  class: "max"
4145
4241
  };
4146
- function _sfc_render$W(_ctx, _cache, $props, $setup, $data, $options) {
4147
- return openBlock(), createElementBlock("view", _hoisted_1$O, [
4148
- !_ctx.hiddenRange ? (openBlock(), createElementBlock("view", _hoisted_2$E, toDisplayString(+_ctx.min), 1)) : createCommentVNode("", true),
4242
+ function _sfc_render$Z(_ctx, _cache, $props, $setup, $data, $options) {
4243
+ return openBlock(), createElementBlock("view", _hoisted_1$R, [
4244
+ !_ctx.hiddenRange ? (openBlock(), createElementBlock("view", _hoisted_2$H, toDisplayString(+_ctx.min), 1)) : createCommentVNode("", true),
4149
4245
  createElementVNode("view", {
4150
4246
  ref: "root",
4151
4247
  style: normalizeStyle(_ctx.wrapperStyle),
@@ -4185,9 +4281,9 @@ function _sfc_render$W(_ctx, _cache, $props, $setup, $data, $options) {
4185
4281
  class: "nut-range-button",
4186
4282
  style: normalizeStyle(_ctx.buttonStyle)
4187
4283
  }, [
4188
- !_ctx.hiddenTag ? (openBlock(), createElementBlock("view", _hoisted_4$n, toDisplayString(_ctx.curValue(index)), 1)) : createCommentVNode("", true)
4284
+ !_ctx.hiddenTag ? (openBlock(), createElementBlock("view", _hoisted_4$p, toDisplayString(_ctx.curValue(index)), 1)) : createCommentVNode("", true)
4189
4285
  ], 4))
4190
- ], 42, _hoisted_3$v);
4286
+ ], 42, _hoisted_3$y);
4191
4287
  }), 64)) : (openBlock(), createElementBlock("view", {
4192
4288
  key: 1,
4193
4289
  role: "slider",
@@ -4210,17 +4306,355 @@ function _sfc_render$W(_ctx, _cache, $props, $setup, $data, $options) {
4210
4306
  class: "nut-range-button",
4211
4307
  style: normalizeStyle(_ctx.buttonStyle)
4212
4308
  }, [
4213
- !_ctx.hiddenTag ? (openBlock(), createElementBlock("view", _hoisted_6$c, toDisplayString(_ctx.curValue()), 1)) : createCommentVNode("", true)
4309
+ !_ctx.hiddenTag ? (openBlock(), createElementBlock("view", _hoisted_6$d, toDisplayString(_ctx.curValue()), 1)) : createCommentVNode("", true)
4214
4310
  ], 4))
4215
- ], 40, _hoisted_5$f))
4311
+ ], 40, _hoisted_5$g))
4216
4312
  ], 4)
4217
4313
  ], 6),
4218
- !_ctx.hiddenRange ? (openBlock(), createElementBlock("view", _hoisted_7$8, toDisplayString(+_ctx.max), 1)) : createCommentVNode("", true)
4314
+ !_ctx.hiddenRange ? (openBlock(), createElementBlock("view", _hoisted_7$9, toDisplayString(+_ctx.max), 1)) : createCommentVNode("", true)
4219
4315
  ]);
4220
4316
  }
4221
- var Range = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["render", _sfc_render$W]]);
4222
- const { create: create$$, componentName: componentName$J } = createComponent("steps");
4223
- const _sfc_main$$ = create$$({
4317
+ var Range = /* @__PURE__ */ _export_sfc(_sfc_main$13, [["render", _sfc_render$Z]]);
4318
+ const MIN_DISTANCE = 10;
4319
+ function getDirection(x, y) {
4320
+ if (x > y && x > MIN_DISTANCE) {
4321
+ return "horizontal";
4322
+ }
4323
+ if (y > x && y > MIN_DISTANCE) {
4324
+ return "vertical";
4325
+ }
4326
+ return "";
4327
+ }
4328
+ function useTouch() {
4329
+ const startX = ref(0);
4330
+ const startY = ref(0);
4331
+ const deltaX = ref(0);
4332
+ const deltaY = ref(0);
4333
+ const offsetX = ref(0);
4334
+ const offsetY = ref(0);
4335
+ const direction = ref("");
4336
+ const isVertical = () => direction.value === "vertical";
4337
+ const isHorizontal = () => direction.value === "horizontal";
4338
+ const reset = () => {
4339
+ deltaX.value = 0;
4340
+ deltaY.value = 0;
4341
+ offsetX.value = 0;
4342
+ offsetY.value = 0;
4343
+ direction.value = "";
4344
+ };
4345
+ const start = (event) => {
4346
+ reset();
4347
+ startX.value = event.touches[0].clientX;
4348
+ startY.value = event.touches[0].clientY;
4349
+ };
4350
+ const move = (event) => {
4351
+ const touch = event.touches[0];
4352
+ deltaX.value = touch.clientX - startX.value;
4353
+ deltaY.value = touch.clientY - startY.value;
4354
+ offsetX.value = Math.abs(deltaX.value);
4355
+ offsetY.value = Math.abs(deltaY.value);
4356
+ if (!direction.value) {
4357
+ direction.value = getDirection(offsetX.value, offsetY.value);
4358
+ }
4359
+ };
4360
+ return {
4361
+ move,
4362
+ start,
4363
+ reset,
4364
+ startX,
4365
+ startY,
4366
+ deltaX,
4367
+ deltaY,
4368
+ offsetX,
4369
+ offsetY,
4370
+ direction,
4371
+ isVertical,
4372
+ isHorizontal
4373
+ };
4374
+ }
4375
+ function preventDefault(event, isStopPropagation) {
4376
+ if (typeof event.cancelable !== "boolean" || event.cancelable) {
4377
+ event.preventDefault();
4378
+ }
4379
+ if (isStopPropagation)
4380
+ event.stopPropagation();
4381
+ }
4382
+ const { componentName: componentName$M, create: create$12 } = createComponent("pullrefresh");
4383
+ const _sfc_main$12 = create$12({
4384
+ props: {
4385
+ useWindow: {
4386
+ type: Boolean,
4387
+ default: true
4388
+ },
4389
+ containerId: {
4390
+ type: String,
4391
+ default: ""
4392
+ },
4393
+ disabled: {
4394
+ type: Boolean,
4395
+ default: false
4396
+ },
4397
+ direction: {
4398
+ type: String,
4399
+ default: "vertical"
4400
+ },
4401
+ pullingText: {
4402
+ type: Object,
4403
+ default: {
4404
+ top: "\u4E0B\u62C9\u5237\u65B0",
4405
+ bottom: "\u4E0A\u62C9\u52A0\u8F7D",
4406
+ left: "\u5DE6\u6ED1\u5237\u65B0",
4407
+ right: "\u53F3\u6ED1\u52A0\u8F7D"
4408
+ }
4409
+ },
4410
+ loosingText: {
4411
+ type: Object,
4412
+ default: {
4413
+ top: "\u677E\u624B\u91CA\u653E\u5237\u65B0",
4414
+ bottom: "\u677E\u624B\u91CA\u653E\u5237\u65B0",
4415
+ left: "\u91CA\u653E\u5237\u65B0",
4416
+ right: "\u52A0\u8F7D\u66F4\u591A"
4417
+ }
4418
+ },
4419
+ loadingText: {
4420
+ type: Object,
4421
+ default: {
4422
+ top: "\u52A0\u8F7D\u4E2D...",
4423
+ bottom: "\u52A0\u8F7D\u4E2D...",
4424
+ left: "\u52A0\u8F7D\u4E2D...",
4425
+ right: "\u52A0\u8F7D\u4E2D..."
4426
+ }
4427
+ }
4428
+ },
4429
+ emits: ["refresh", "downRefresh"],
4430
+ setup(props, { emit }) {
4431
+ const { containerId, useWindow, direction, disabled } = toRefs(props);
4432
+ const reachTop = ref(false);
4433
+ const reachBottom = ref(false);
4434
+ const reachLeft = ref(false);
4435
+ const reachRight = ref(false);
4436
+ const state = reactive({
4437
+ status: "normal",
4438
+ distance: 0,
4439
+ duration: 0
4440
+ });
4441
+ let scrollEl = document.documentElement || document.body;
4442
+ const scroller = ref(null);
4443
+ const touch = useTouch();
4444
+ const getStyle = computed(() => {
4445
+ let style = {};
4446
+ const { deltaY, deltaX } = touch;
4447
+ if (direction.value == "vertical" && (reachTop.value && deltaY.value > 0 || reachBottom.value && deltaY.value < 0) && touch.isVertical()) {
4448
+ style = {
4449
+ transitionDuration: `${state.duration}ms`,
4450
+ transform: state.distance ? `translate3d(0,${state.distance}px, 0)` : `translate3d(0,0,0)`
4451
+ };
4452
+ }
4453
+ if (direction.value == "horizontal" && (reachLeft.value && deltaX.value > 0 || reachRight.value && deltaX.value < 0) && touch.isHorizontal()) {
4454
+ style = {
4455
+ transitionDuration: `${state.duration}ms`,
4456
+ transform: state.distance ? `translate3d(${state.distance}px, 0,0)` : `translate3d(0,0,0)`
4457
+ };
4458
+ }
4459
+ return style;
4460
+ });
4461
+ const getBottomStyle = computed(() => {
4462
+ let style = {};
4463
+ if (direction.value == "vertical" && reachBottom.value && touch.deltaY.value < 0 && touch.isVertical()) {
4464
+ const dis = Math.abs(state.distance) < 50 ? -state.distance : 50;
4465
+ style = {
4466
+ height: dis + "px"
4467
+ };
4468
+ }
4469
+ if (direction.value == "horizontal" && reachRight.value && touch.deltaX.value < 0 && touch.isVertical()) {
4470
+ const dis = Math.abs(state.distance) < 50 ? -state.distance : 50;
4471
+ style = {
4472
+ width: dis + "px"
4473
+ };
4474
+ }
4475
+ return style;
4476
+ });
4477
+ const refreshTopTem = computed(() => {
4478
+ const { status, distance } = state;
4479
+ const tag = direction.value == "vertical" ? "top" : "left";
4480
+ if (status == "loading" && (reachTop.value || reachLeft.value) && distance > 0) {
4481
+ return props.loadingText[tag];
4482
+ }
4483
+ if (status == "pulling" && (reachTop.value || reachLeft.value) && distance > 0) {
4484
+ return props.pullingText[tag];
4485
+ }
4486
+ if (status == "loosing" && (reachTop.value || reachLeft.value) && distance > 0) {
4487
+ return props.loosingText[tag];
4488
+ }
4489
+ return "";
4490
+ });
4491
+ const refreshBottomTem = computed(() => {
4492
+ const { status, distance } = state;
4493
+ const tag = direction.value == "vertical" ? "bottom" : "right";
4494
+ if (status == "loading" && (reachBottom.value || reachRight.value) && distance < 0) {
4495
+ return props.loadingText[tag];
4496
+ }
4497
+ if (status == "pulling" && (reachBottom.value || reachRight.value) && distance < 0) {
4498
+ return props.pullingText[tag];
4499
+ }
4500
+ if (status == "loosing" && (reachBottom.value || reachRight.value) && distance < 0) {
4501
+ return props.loosingText[tag];
4502
+ }
4503
+ return "";
4504
+ });
4505
+ const isTouchable = () => state.status !== "loading" && !disabled.value;
4506
+ const setStatus = (distance, isLoading) => {
4507
+ state.distance = distance;
4508
+ if (isLoading) {
4509
+ state.status = "loading";
4510
+ } else if (distance === 0) {
4511
+ state.status = "normal";
4512
+ } else if (Math.abs(distance) < 50) {
4513
+ state.status = "pulling";
4514
+ } else {
4515
+ state.status = "loosing";
4516
+ }
4517
+ };
4518
+ const getParentElement = (el) => {
4519
+ if (containerId.value != "") {
4520
+ return document.querySelector(`#${containerId.value}`);
4521
+ }
4522
+ return el && el.parentNode;
4523
+ };
4524
+ onMounted(() => {
4525
+ const parentElement = getParentElement(scroller);
4526
+ let scrollElCopy = document.documentElement || document.body;
4527
+ if (useWindow.value === false) {
4528
+ scrollElCopy = parentElement;
4529
+ }
4530
+ scrollEl = scrollElCopy;
4531
+ });
4532
+ const ease = (distance) => {
4533
+ const headHeight = 50;
4534
+ if (distance > headHeight) {
4535
+ if (distance < headHeight * 2) {
4536
+ distance = headHeight + (distance - headHeight) / 2;
4537
+ } else {
4538
+ distance = headHeight * 1.5 + (distance - headHeight * 2) / 4;
4539
+ }
4540
+ }
4541
+ return Math.round(distance);
4542
+ };
4543
+ const refreshDone = () => {
4544
+ setStatus(0);
4545
+ };
4546
+ const touchStart = (event) => {
4547
+ if (isTouchable()) {
4548
+ if (direction.value == "vertical") {
4549
+ const top = "scrollTop" in scrollEl ? scrollEl.scrollTop : 0;
4550
+ reachTop.value = Math.max(top, 0) == 0 ? true : false;
4551
+ const { scrollHeight, clientHeight, scrollTop } = scrollEl;
4552
+ reachBottom.value = clientHeight + scrollTop == scrollHeight ? true : false;
4553
+ if (reachTop.value || reachBottom.value) {
4554
+ state.duration = 0;
4555
+ touch.start(event);
4556
+ }
4557
+ } else {
4558
+ const { scrollWidth, clientWidth, scrollLeft } = scrollEl;
4559
+ const left = "scrollLeft" in scrollEl ? scrollEl.scrollLeft : 0;
4560
+ reachLeft.value = Math.max(left, 0) == 0 ? true : false;
4561
+ reachRight.value = clientWidth + scrollLeft == scrollWidth ? true : false;
4562
+ if (reachLeft.value || reachRight.value) {
4563
+ state.duration = 0;
4564
+ touch.start(event);
4565
+ }
4566
+ }
4567
+ } else {
4568
+ preventDefault(event);
4569
+ }
4570
+ };
4571
+ const touchMove = (event) => {
4572
+ if (isTouchable()) {
4573
+ const { deltaY, deltaX } = touch;
4574
+ touch.move(event);
4575
+ if (direction.value == "vertical" && (reachBottom.value && deltaY.value < 0 || reachTop.value && deltaY.value >= 0) && touch.isVertical()) {
4576
+ preventDefault(event);
4577
+ setStatus(ease(deltaY.value));
4578
+ }
4579
+ if (direction.value == "horizontal" && (reachLeft.value && deltaX.value >= 0 || reachRight.value && deltaX.value < 0) && touch.isHorizontal()) {
4580
+ preventDefault(event);
4581
+ setStatus(ease(deltaX.value));
4582
+ }
4583
+ } else {
4584
+ preventDefault(event);
4585
+ }
4586
+ };
4587
+ const touchEnd = () => {
4588
+ if (isTouchable()) {
4589
+ const { deltaY, deltaX } = touch;
4590
+ if (state.status === "loosing") {
4591
+ let dis = 0;
4592
+ if (direction.value == "vertical" && reachTop.value && deltaY.value > 0) {
4593
+ dis = 50;
4594
+ emit("downRefresh", refreshDone);
4595
+ }
4596
+ if (direction.value == "vertical" && reachBottom.value && deltaY.value < 0) {
4597
+ dis = -50;
4598
+ emit("refresh", refreshDone);
4599
+ }
4600
+ if (direction.value == "horizontal" && reachLeft.value && deltaX.value > 0) {
4601
+ dis = 50;
4602
+ emit("downRefresh", refreshDone);
4603
+ }
4604
+ if (direction.value == "horizontal" && reachRight.value && deltaX.value < 0) {
4605
+ dis = -50;
4606
+ emit("refresh", refreshDone);
4607
+ }
4608
+ setStatus(dis, true);
4609
+ } else {
4610
+ setStatus(0);
4611
+ }
4612
+ }
4613
+ };
4614
+ return __spreadValues({
4615
+ scroller,
4616
+ touchStart,
4617
+ touchMove,
4618
+ touchEnd,
4619
+ getStyle,
4620
+ reachBottom,
4621
+ reachTop,
4622
+ reachRight,
4623
+ reachLeft,
4624
+ getBottomStyle,
4625
+ refreshTopTem,
4626
+ refreshBottomTem
4627
+ }, toRefs(state));
4628
+ }
4629
+ });
4630
+ const _hoisted_1$Q = {
4631
+ class: "pullrefresh-content",
4632
+ ref: "pull"
4633
+ };
4634
+ function _sfc_render$Y(_ctx, _cache, $props, $setup, $data, $options) {
4635
+ return openBlock(), createElementBlock("view", {
4636
+ class: "nut-pullrefresh",
4637
+ ref: "scroller",
4638
+ style: normalizeStyle(_ctx.getStyle),
4639
+ onTouchstart: _cache[0] || (_cache[0] = (...args) => _ctx.touchStart && _ctx.touchStart(...args)),
4640
+ onTouchmove: _cache[1] || (_cache[1] = (...args) => _ctx.touchMove && _ctx.touchMove(...args)),
4641
+ onTouchend: _cache[2] || (_cache[2] = (...args) => _ctx.touchEnd && _ctx.touchEnd(...args))
4642
+ }, [
4643
+ createElementVNode("view", {
4644
+ class: normalizeClass(["pullrefresh-top", _ctx.direction == "horizontal" ? "pullrefresh-top-h" : "pullrefresh-top-v"])
4645
+ }, toDisplayString(_ctx.refreshTopTem), 3),
4646
+ createElementVNode("view", _hoisted_1$Q, [
4647
+ renderSlot(_ctx.$slots, "default")
4648
+ ], 512),
4649
+ createElementVNode("view", {
4650
+ class: normalizeClass(["pullrefresh-bottom", _ctx.direction == "horizontal" ? "pullrefresh-bottom-h" : "pullrefresh-bottom-v"]),
4651
+ style: normalizeStyle(_ctx.getBottomStyle)
4652
+ }, toDisplayString(_ctx.refreshBottomTem), 7)
4653
+ ], 36);
4654
+ }
4655
+ var PullRefresh = /* @__PURE__ */ _export_sfc(_sfc_main$12, [["render", _sfc_render$Y]]);
4656
+ const { create: create$11, componentName: componentName$L } = createComponent("steps");
4657
+ const _sfc_main$11 = create$11({
4224
4658
  props: {
4225
4659
  direction: {
4226
4660
  type: String,
@@ -4240,7 +4674,7 @@ const _sfc_main$$ = create$$({
4240
4674
  children: []
4241
4675
  });
4242
4676
  const classes = computed(() => {
4243
- const prefixCls = componentName$J;
4677
+ const prefixCls = componentName$L;
4244
4678
  return {
4245
4679
  [prefixCls]: true,
4246
4680
  [`${prefixCls}-${props.direction}`]: true,
@@ -4263,8 +4697,8 @@ const _sfc_main$$ = create$$({
4263
4697
  };
4264
4698
  }
4265
4699
  });
4266
- const { create: create$_, componentName: componentName$I } = createComponent("step");
4267
- const _sfc_main$_ = create$_({
4700
+ const { create: create$10, componentName: componentName$K } = createComponent("step");
4701
+ const _sfc_main$10 = create$10({
4268
4702
  props: {
4269
4703
  title: {
4270
4704
  type: String,
@@ -4305,7 +4739,7 @@ const _sfc_main$_ = create$_({
4305
4739
  return getCurrentStatus();
4306
4740
  });
4307
4741
  const classes = computed(() => {
4308
- const prefixCls = componentName$I;
4742
+ const prefixCls = componentName$K;
4309
4743
  return {
4310
4744
  [prefixCls]: true,
4311
4745
  [`${prefixCls}-${status.value}`]: true
@@ -4317,22 +4751,22 @@ const _sfc_main$_ = create$_({
4317
4751
  });
4318
4752
  }
4319
4753
  });
4320
- const _hoisted_1$N = { class: "nut-step-head" };
4321
- const _hoisted_2$D = /* @__PURE__ */ createElementVNode("view", { class: "nut-step-line" }, null, -1);
4322
- const _hoisted_3$u = {
4754
+ const _hoisted_1$P = { class: "nut-step-head" };
4755
+ const _hoisted_2$G = /* @__PURE__ */ createElementVNode("view", { class: "nut-step-line" }, null, -1);
4756
+ const _hoisted_3$x = {
4323
4757
  key: 2,
4324
4758
  class: "nut-step-inner"
4325
4759
  };
4326
- const _hoisted_4$m = { class: "nut-step-main" };
4327
- const _hoisted_5$e = { class: "nut-step-title" };
4328
- const _hoisted_6$b = ["innerHTML"];
4329
- function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
4760
+ const _hoisted_4$o = { class: "nut-step-main" };
4761
+ const _hoisted_5$f = { class: "nut-step-title" };
4762
+ const _hoisted_6$c = ["innerHTML"];
4763
+ function _sfc_render$X(_ctx, _cache, $props, $setup, $data, $options) {
4330
4764
  const _component_nut_icon = resolveComponent("nut-icon");
4331
4765
  return openBlock(), createElementBlock("view", {
4332
4766
  class: normalizeClass(_ctx.classes)
4333
4767
  }, [
4334
- createElementVNode("view", _hoisted_1$N, [
4335
- _hoisted_2$D,
4768
+ createElementVNode("view", _hoisted_1$P, [
4769
+ _hoisted_2$G,
4336
4770
  createElementVNode("view", {
4337
4771
  class: normalizeClass(["nut-step-icon", [!_ctx.dot ? _ctx.icon ? "is-icon" : "is-text" : ""]])
4338
4772
  }, [
@@ -4342,22 +4776,22 @@ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
4342
4776
  color: _ctx.iconColor,
4343
4777
  name: _ctx.icon,
4344
4778
  size: _ctx.size
4345
- }, null, 8, ["color", "name", "size"])) : _ctx.dot ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [], 64)) : (openBlock(), createElementBlock("view", _hoisted_3$u, toDisplayString(_ctx.index), 1))
4779
+ }, null, 8, ["color", "name", "size"])) : _ctx.dot ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [], 64)) : (openBlock(), createElementBlock("view", _hoisted_3$x, toDisplayString(_ctx.index), 1))
4346
4780
  ], 2)
4347
4781
  ]),
4348
- createElementVNode("view", _hoisted_4$m, [
4349
- createElementVNode("view", _hoisted_5$e, toDisplayString(_ctx.title), 1),
4782
+ createElementVNode("view", _hoisted_4$o, [
4783
+ createElementVNode("view", _hoisted_5$f, toDisplayString(_ctx.title), 1),
4350
4784
  _ctx.content ? (openBlock(), createElementBlock("view", {
4351
4785
  key: 0,
4352
4786
  class: "nut-step-content",
4353
4787
  innerHTML: _ctx.content
4354
- }, null, 8, _hoisted_6$b)) : createCommentVNode("", true)
4788
+ }, null, 8, _hoisted_6$c)) : createCommentVNode("", true)
4355
4789
  ])
4356
4790
  ], 2);
4357
4791
  }
4358
- var Step = /* @__PURE__ */ _export_sfc(_sfc_main$_, [["render", _sfc_render$V]]);
4359
- const { componentName: componentName$H, create: create$Z } = createComponent("switch");
4360
- const _sfc_main$Z = create$Z({
4792
+ var Step = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["render", _sfc_render$X]]);
4793
+ const { componentName: componentName$J, create: create$$ } = createComponent("switch");
4794
+ const _sfc_main$$ = create$$({
4361
4795
  props: {
4362
4796
  modelValue: {
4363
4797
  type: [String, Number, Boolean],
@@ -4408,11 +4842,11 @@ const _sfc_main$Z = create$Z({
4408
4842
  default: ""
4409
4843
  }
4410
4844
  },
4411
- emits: ["change", "update:modelValue"],
4845
+ emits: ["change", "update:modelValue", "update:loading"],
4412
4846
  setup(props, { emit }) {
4413
4847
  const isActive = computed(() => props.modelValue === props.activeValue);
4414
4848
  const classes = computed(() => {
4415
- const prefixCls = componentName$H;
4849
+ const prefixCls = componentName$J;
4416
4850
  return {
4417
4851
  [prefixCls]: true,
4418
4852
  [isActive.value ? "switch-open" : "switch-close"]: true,
@@ -4440,15 +4874,15 @@ const _sfc_main$Z = create$Z({
4440
4874
  };
4441
4875
  }
4442
4876
  });
4443
- const _hoisted_1$M = { class: "switch-button" };
4444
- function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
4877
+ const _hoisted_1$O = { class: "switch-button" };
4878
+ function _sfc_render$W(_ctx, _cache, $props, $setup, $data, $options) {
4445
4879
  const _component_nut_icon = resolveComponent("nut-icon");
4446
4880
  return openBlock(), createElementBlock("view", {
4447
4881
  class: normalizeClass(_ctx.classes),
4448
4882
  onClick: _cache[0] || (_cache[0] = (...args) => _ctx.onClick && _ctx.onClick(...args)),
4449
4883
  style: normalizeStyle(_ctx.style)
4450
4884
  }, [
4451
- createElementVNode("view", _hoisted_1$M, [
4885
+ createElementVNode("view", _hoisted_1$O, [
4452
4886
  _ctx.loading ? (openBlock(), createBlock(_component_nut_icon, {
4453
4887
  key: 0,
4454
4888
  name: _ctx.name,
@@ -4466,11 +4900,11 @@ function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
4466
4900
  ])
4467
4901
  ], 6);
4468
4902
  }
4469
- var Switch = /* @__PURE__ */ _export_sfc(_sfc_main$Z, [["render", _sfc_render$U]]);
4470
- const { create: create$Y } = createComponent("toast");
4471
- const _sfc_main$Y = create$Y({
4903
+ var Switch = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["render", _sfc_render$W]]);
4904
+ const { create: create$_ } = createComponent("toast");
4905
+ const _sfc_main$_ = create$_({
4472
4906
  components: {
4473
- [_sfc_main$1o.name]: _sfc_main$1o
4907
+ [_sfc_main$1s.name]: _sfc_main$1s
4474
4908
  },
4475
4909
  props: {
4476
4910
  id: String,
@@ -4493,6 +4927,10 @@ const _sfc_main$Y = create$Y({
4493
4927
  type: [String, Number],
4494
4928
  default: "base"
4495
4929
  },
4930
+ iconSize: {
4931
+ type: String,
4932
+ default: "20"
4933
+ },
4496
4934
  icon: String,
4497
4935
  textAlignCenter: {
4498
4936
  type: Boolean,
@@ -4504,7 +4942,7 @@ const _sfc_main$Y = create$Y({
4504
4942
  },
4505
4943
  bgColor: {
4506
4944
  type: String,
4507
- default: "rgba(0, 0, 0, .8)"
4945
+ default: ""
4508
4946
  },
4509
4947
  onClose: Function,
4510
4948
  unmount: Function,
@@ -4514,7 +4952,7 @@ const _sfc_main$Y = create$Y({
4514
4952
  },
4515
4953
  coverColor: {
4516
4954
  type: String,
4517
- default: "rgba(0, 0, 0, 0)"
4955
+ default: ""
4518
4956
  },
4519
4957
  title: {
4520
4958
  type: String,
@@ -4525,7 +4963,8 @@ const _sfc_main$Y = create$Y({
4525
4963
  default: false
4526
4964
  }
4527
4965
  },
4528
- setup(props) {
4966
+ emits: ["close"],
4967
+ setup(props, { emit }) {
4529
4968
  let timer;
4530
4969
  const state = reactive({
4531
4970
  mounted: false
@@ -4553,6 +4992,7 @@ const _sfc_main$Y = create$Y({
4553
4992
  const clickCover = () => {
4554
4993
  if (props.closeOnClickOverlay) {
4555
4994
  hide();
4995
+ emit("close");
4556
4996
  }
4557
4997
  };
4558
4998
  if (props.duration) {
@@ -4596,16 +5036,16 @@ const _sfc_main$Y = create$Y({
4596
5036
  };
4597
5037
  }
4598
5038
  });
4599
- const _hoisted_1$L = {
5039
+ const _hoisted_1$N = {
4600
5040
  key: 0,
4601
5041
  class: "nut-toast-icon-wrapper"
4602
5042
  };
4603
- const _hoisted_2$C = {
5043
+ const _hoisted_2$F = {
4604
5044
  key: 1,
4605
5045
  class: "nut-toast-title"
4606
5046
  };
4607
- const _hoisted_3$t = ["innerHTML"];
4608
- function _sfc_render$T(_ctx, _cache, $props, $setup, $data, $options) {
5047
+ const _hoisted_3$w = ["innerHTML"];
5048
+ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
4609
5049
  const _component_nut_icon = resolveComponent("nut-icon");
4610
5050
  return openBlock(), createBlock(Transition, {
4611
5051
  name: "toast-fade",
@@ -4627,18 +5067,18 @@ function _sfc_render$T(_ctx, _cache, $props, $setup, $data, $options) {
4627
5067
  "background-color": _ctx.bgColor
4628
5068
  })
4629
5069
  }, [
4630
- _ctx.hasIcon ? (openBlock(), createElementBlock("view", _hoisted_1$L, [
5070
+ _ctx.hasIcon ? (openBlock(), createElementBlock("view", _hoisted_1$N, [
4631
5071
  createVNode(_component_nut_icon, {
4632
- size: "20",
5072
+ size: _ctx.iconSize,
4633
5073
  color: "#ffffff",
4634
5074
  name: _ctx.icon
4635
- }, null, 8, ["name"])
5075
+ }, null, 8, ["size", "name"])
4636
5076
  ])) : createCommentVNode("", true),
4637
- _ctx.title ? (openBlock(), createElementBlock("div", _hoisted_2$C, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
5077
+ _ctx.title ? (openBlock(), createElementBlock("div", _hoisted_2$F, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
4638
5078
  createElementVNode("view", {
4639
5079
  class: "nut-toast-text",
4640
5080
  innerHTML: _ctx.msg
4641
- }, null, 8, _hoisted_3$t)
5081
+ }, null, 8, _hoisted_3$w)
4642
5082
  ], 4)
4643
5083
  ], 6), [
4644
5084
  [vShow, _ctx.state.mounted]
@@ -4647,7 +5087,7 @@ function _sfc_render$T(_ctx, _cache, $props, $setup, $data, $options) {
4647
5087
  _: 1
4648
5088
  }, 8, ["onAfterLeave"]);
4649
5089
  }
4650
- var Toast = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["render", _sfc_render$T]]);
5090
+ var Toast = /* @__PURE__ */ _export_sfc(_sfc_main$_, [["render", _sfc_render$V]]);
4651
5091
  const defaultOptions = {
4652
5092
  msg: "",
4653
5093
  id: "",
@@ -4658,14 +5098,15 @@ const defaultOptions = {
4658
5098
  customClass: "",
4659
5099
  bottom: "30px",
4660
5100
  size: "base",
5101
+ iconSize: "20",
4661
5102
  icon: null,
4662
5103
  textAlignCenter: true,
4663
5104
  loadingRotate: true,
4664
- bgColor: "rgba(0, 0, 0, .8)",
5105
+ bgColor: "",
4665
5106
  onClose: null,
4666
5107
  unmount: null,
4667
5108
  cover: false,
4668
- coverColor: "rgba(0, 0, 0, 0)",
5109
+ coverColor: "",
4669
5110
  closeOnClickOverlay: false
4670
5111
  };
4671
5112
  let idsMap = [];
@@ -4764,8 +5205,8 @@ const ToastFunction = {
4764
5205
  app.config.globalProperties.$toast = ToastFunction;
4765
5206
  }
4766
5207
  };
4767
- const { create: create$X } = createComponent("progress");
4768
- const _sfc_main$X = create$X({
5208
+ const { create: create$Z } = createComponent("progress");
5209
+ const _sfc_main$Z = create$Z({
4769
5210
  props: {
4770
5211
  percentage: {
4771
5212
  type: [Number, String],
@@ -4807,11 +5248,16 @@ const _sfc_main$X = create$X({
4807
5248
  iconColor: {
4808
5249
  type: String,
4809
5250
  default: "#439422"
5251
+ },
5252
+ isShowPercentage: {
5253
+ type: Boolean,
5254
+ default: true
4810
5255
  }
4811
5256
  },
4812
5257
  setup(props, { emit }) {
4813
5258
  const height = ref(props.strokeWidth + "px");
4814
5259
  const progressOuter = ref();
5260
+ const insideText = ref();
4815
5261
  const left = ref();
4816
5262
  const bgStyle = computed(() => {
4817
5263
  return {
@@ -4824,32 +5270,39 @@ const _sfc_main$X = create$X({
4824
5270
  color: props.textColor || ""
4825
5271
  };
4826
5272
  });
5273
+ const slideLeft = (values) => {
5274
+ if (props.textInside) {
5275
+ let offsetWidth = progressOuter.value.offsetWidth;
5276
+ let percentageWidth = progressOuter.value.offsetWidth * Number(values) * 0.01;
5277
+ let insideTextWidth = insideText.value.offsetWidth;
5278
+ left.value = percentageWidth - 5 + "px";
5279
+ if (offsetWidth == percentageWidth) {
5280
+ left.value = percentageWidth - insideTextWidth + "px";
5281
+ }
5282
+ }
5283
+ };
4827
5284
  watch(() => props.percentage, (values) => {
4828
- console.log("progressOuter.value.offsetWidth", progressOuter.value.offsetWidth);
4829
- console.log("values", values);
4830
- left.value = progressOuter.value.offsetWidth * Number(values) * 0.01 - 5 + "px";
5285
+ slideLeft(values);
4831
5286
  });
4832
5287
  onMounted(() => {
4833
- left.value = progressOuter.value.offsetWidth * Number(props.percentage) * 0.01 - 5 + "px";
5288
+ slideLeft(props.percentage);
4834
5289
  });
4835
5290
  return {
4836
5291
  height,
4837
5292
  bgStyle,
4838
5293
  textStyle,
4839
5294
  progressOuter,
5295
+ insideText,
4840
5296
  left
4841
5297
  };
4842
5298
  }
4843
5299
  });
4844
- const _hoisted_1$K = { class: "nut-progress" };
4845
- function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
5300
+ const _hoisted_1$M = { class: "nut-progress" };
5301
+ function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
4846
5302
  const _component_nut_icon = resolveComponent("nut-icon");
4847
- return openBlock(), createElementBlock("div", _hoisted_1$K, [
5303
+ return openBlock(), createElementBlock("div", _hoisted_1$M, [
4848
5304
  createElementVNode("div", {
4849
- class: normalizeClass(["nut-progress-outer", [
4850
- _ctx.showText && !_ctx.textInside ? "nut-progress-outer-part" : "",
4851
- _ctx.size ? "nut-progress-" + _ctx.size : ""
4852
- ]]),
5305
+ class: normalizeClass(["nut-progress-outer", [_ctx.showText && !_ctx.textInside ? "nut-progress-outer-part" : "", _ctx.size ? "nut-progress-" + _ctx.size : ""]]),
4853
5306
  ref: "progressOuter",
4854
5307
  style: normalizeStyle({ height: _ctx.height })
4855
5308
  }, [
@@ -4860,11 +5313,12 @@ function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
4860
5313
  _ctx.showText && _ctx.textInside ? (openBlock(), createElementBlock("div", {
4861
5314
  key: 0,
4862
5315
  class: "nut-progress-text nut-progress-insidetext",
5316
+ ref: "insideText",
4863
5317
  style: normalizeStyle({ lineHeight: _ctx.height, left: _ctx.left })
4864
5318
  }, [
4865
5319
  createElementVNode("span", {
4866
5320
  style: normalizeStyle(_ctx.textStyle)
4867
- }, toDisplayString(_ctx.percentage) + "%", 5)
5321
+ }, toDisplayString(_ctx.percentage) + toDisplayString(_ctx.isShowPercentage ? "%" : ""), 5)
4868
5322
  ], 4)) : createCommentVNode("", true)
4869
5323
  ], 6)
4870
5324
  ], 6),
@@ -4876,7 +5330,7 @@ function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
4876
5330
  _ctx.status == "active" || _ctx.status == "" ? (openBlock(), createElementBlock("span", {
4877
5331
  key: 0,
4878
5332
  style: normalizeStyle(_ctx.textStyle)
4879
- }, toDisplayString(_ctx.percentage) + "%", 5)) : _ctx.status == "icon" ? (openBlock(), createBlock(_component_nut_icon, {
5333
+ }, toDisplayString(_ctx.percentage) + toDisplayString(_ctx.isShowPercentage ? "%" : ""), 5)) : _ctx.status == "icon" ? (openBlock(), createBlock(_component_nut_icon, {
4880
5334
  key: 1,
4881
5335
  size: "16px",
4882
5336
  name: _ctx.iconName,
@@ -4885,9 +5339,9 @@ function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
4885
5339
  ], 4)) : createCommentVNode("", true)
4886
5340
  ]);
4887
5341
  }
4888
- var Progress = /* @__PURE__ */ _export_sfc(_sfc_main$X, [["render", _sfc_render$S]]);
4889
- const { componentName: componentName$G, create: create$W } = createComponent("circleprogress");
4890
- const _sfc_main$W = create$W({
5342
+ var Progress = /* @__PURE__ */ _export_sfc(_sfc_main$Z, [["render", _sfc_render$U]]);
5343
+ const { componentName: componentName$I, create: create$Y } = createComponent("circleprogress");
5344
+ const _sfc_main$Y = create$Y({
4891
5345
  props: {
4892
5346
  progress: {
4893
5347
  type: [Number, String],
@@ -4909,7 +5363,7 @@ const _sfc_main$W = create$W({
4909
5363
  },
4910
5364
  setup(props, { emit }) {
4911
5365
  const classes = computed(() => {
4912
- const prefixCls = componentName$G;
5366
+ const prefixCls = componentName$I;
4913
5367
  return {
4914
5368
  [prefixCls]: true
4915
5369
  };
@@ -4943,11 +5397,11 @@ const _sfc_main$W = create$W({
4943
5397
  };
4944
5398
  }
4945
5399
  });
4946
- const _hoisted_1$J = ["height", "width"];
4947
- const _hoisted_2$B = ["r", "cx", "cy", "stroke", "stroke-width"];
4948
- const _hoisted_3$s = ["r", "cx", "cy", "stroke", "stroke-dasharray", "stroke-width", "transform"];
4949
- const _hoisted_4$l = { class: "nut-circleprogress-content" };
4950
- function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
5400
+ const _hoisted_1$L = ["height", "width"];
5401
+ const _hoisted_2$E = ["r", "cx", "cy", "stroke", "stroke-width"];
5402
+ const _hoisted_3$v = ["r", "cx", "cy", "stroke", "stroke-dasharray", "stroke-width", "transform"];
5403
+ const _hoisted_4$n = { class: "nut-circleprogress-content" };
5404
+ function _sfc_render$T(_ctx, _cache, $props, $setup, $data, $options) {
4951
5405
  return openBlock(), createElementBlock("div", {
4952
5406
  class: normalizeClass(_ctx.classes),
4953
5407
  style: normalizeStyle({ height: _ctx.option.size + "px", width: _ctx.option.size + "px" })
@@ -4964,7 +5418,7 @@ function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
4964
5418
  stroke: _ctx.option.backColor,
4965
5419
  "stroke-width": _ctx.option.strokeOutWidth,
4966
5420
  fill: "none"
4967
- }, null, 8, _hoisted_2$B),
5421
+ }, null, 8, _hoisted_2$E),
4968
5422
  createElementVNode("circle", {
4969
5423
  r: _ctx.option.radius,
4970
5424
  cx: _ctx.option.cx,
@@ -4976,18 +5430,18 @@ function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
4976
5430
  transform: _ctx.option.startPosition,
4977
5431
  "stroke-linecap": "round",
4978
5432
  style: { "transition": "stroke-dasharray 0.6s ease 0s, stroke 0.6s ease 0s" }
4979
- }, null, 8, _hoisted_3$s)
4980
- ], 8, _hoisted_1$J)),
4981
- createElementVNode("div", _hoisted_4$l, [
5433
+ }, null, 8, _hoisted_3$v)
5434
+ ], 8, _hoisted_1$L)),
5435
+ createElementVNode("div", _hoisted_4$n, [
4982
5436
  !_ctx.isAuto ? renderSlot(_ctx.$slots, "default", { key: 0 }, () => [
4983
5437
  createTextVNode(toDisplayString(_ctx.progress) + "%", 1)
4984
5438
  ]) : renderSlot(_ctx.$slots, "default", { key: 1 })
4985
5439
  ])
4986
5440
  ], 6);
4987
5441
  }
4988
- var CircleProgress = /* @__PURE__ */ _export_sfc(_sfc_main$W, [["render", _sfc_render$R]]);
4989
- const { componentName: componentName$F, create: create$V } = createComponent("noticebar");
4990
- const _sfc_main$V = create$V({
5442
+ var CircleProgress = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["render", _sfc_render$T]]);
5443
+ const { componentName: componentName$H, create: create$X } = createComponent("noticebar");
5444
+ const _sfc_main$X = create$X({
4991
5445
  props: {
4992
5446
  direction: {
4993
5447
  type: String,
@@ -5024,6 +5478,7 @@ const _sfc_main$V = create$V({
5024
5478
  default: false
5025
5479
  },
5026
5480
  leftIcon: { type: String, default: "" },
5481
+ rightIcon: { type: String, default: "" },
5027
5482
  color: {
5028
5483
  type: String,
5029
5484
  default: ""
@@ -5038,7 +5493,7 @@ const _sfc_main$V = create$V({
5038
5493
  },
5039
5494
  scrollable: {
5040
5495
  type: Boolean,
5041
- default: true
5496
+ default: null
5042
5497
  },
5043
5498
  speed: {
5044
5499
  type: Number,
@@ -5048,12 +5503,12 @@ const _sfc_main$V = create$V({
5048
5503
  components: {
5049
5504
  ScrollItem: function(props) {
5050
5505
  props.item.props.style = props.style;
5506
+ props.item.key = props.key;
5051
5507
  return h(props.item);
5052
5508
  }
5053
5509
  },
5054
5510
  emits: ["click", "close"],
5055
5511
  setup(props, { emit, slots }) {
5056
- console.log("componentName", componentName$F);
5057
5512
  const wrap = ref(null);
5058
5513
  const content = ref(null);
5059
5514
  const state = reactive({
@@ -5067,14 +5522,22 @@ const _sfc_main$V = create$V({
5067
5522
  scrollList: [],
5068
5523
  distance: 0,
5069
5524
  timer: null,
5070
- keepAlive: false
5525
+ keepAlive: false,
5526
+ isCanScroll: null
5071
5527
  });
5072
5528
  const classes = computed(() => {
5073
- const prefixCls = componentName$F;
5529
+ const prefixCls = componentName$H;
5074
5530
  return {
5075
5531
  [prefixCls]: true
5076
5532
  };
5077
5533
  });
5534
+ const isEllipsis = computed(() => {
5535
+ if (state.isCanScroll == null) {
5536
+ return false;
5537
+ } else {
5538
+ return !state.isCanScroll && !props.wrapable;
5539
+ }
5540
+ });
5078
5541
  const iconShow = computed(() => {
5079
5542
  if (props.leftIcon == "close") {
5080
5543
  return false;
@@ -5093,9 +5556,9 @@ const _sfc_main$V = create$V({
5093
5556
  });
5094
5557
  const contentStyle = computed(() => {
5095
5558
  return {
5096
- paddingLeft: state.firstRound ? 0 : state.wrapWidth + "px",
5097
5559
  animationDelay: (state.firstRound ? props.delay : 0) + "s",
5098
- animationDuration: state.duration + "s"
5560
+ animationDuration: state.duration + "s",
5561
+ transform: `translateX(${state.firstRound ? 0 : state.wrapWidth + "px"})`
5099
5562
  };
5100
5563
  });
5101
5564
  const iconBg = computed(() => {
@@ -5138,7 +5601,8 @@ const _sfc_main$V = create$V({
5138
5601
  }
5139
5602
  const wrapWidth = wrap.value.getBoundingClientRect().width;
5140
5603
  const offsetWidth = content.value.getBoundingClientRect().width;
5141
- if (props.scrollable && offsetWidth > wrapWidth) {
5604
+ state.isCanScroll = props.scrollable == null ? offsetWidth > wrapWidth : props.scrollable;
5605
+ if (state.isCanScroll) {
5142
5606
  state.wrapWidth = wrapWidth;
5143
5607
  state.offsetWidth = offsetWidth;
5144
5608
  state.duration = offsetWidth / props.speed;
@@ -5152,7 +5616,9 @@ const _sfc_main$V = create$V({
5152
5616
  emit("click", event);
5153
5617
  };
5154
5618
  const onClickIcon = (event) => {
5155
- state.showNoticeBar = !props.closeMode;
5619
+ if (props.closeMode) {
5620
+ state.showNoticeBar = !props.closeMode;
5621
+ }
5156
5622
  emit("close", event);
5157
5623
  };
5158
5624
  const onAnimationEnd = () => {
@@ -5199,14 +5665,12 @@ const _sfc_main$V = create$V({
5199
5665
  emit("close", state.scrollList[0]);
5200
5666
  };
5201
5667
  onMounted(() => {
5202
- console.log(props.direction);
5203
5668
  if (props.direction == "vertical") {
5204
5669
  if (slots.default) {
5205
5670
  state.scrollList = [].concat(slots.default()[0].children);
5206
5671
  } else {
5207
5672
  state.scrollList = [].concat(props.list);
5208
5673
  }
5209
- console.log(state.scrollList);
5210
5674
  setTimeout(() => {
5211
5675
  props.complexAm ? startRoll() : startRollEasy();
5212
5676
  }, props.standTime);
@@ -5227,6 +5691,7 @@ const _sfc_main$V = create$V({
5227
5691
  clearInterval(state.timer);
5228
5692
  });
5229
5693
  return __spreadProps(__spreadValues(__spreadValues({}, toRefs(props)), toRefs(state)), {
5694
+ isEllipsis,
5230
5695
  classes,
5231
5696
  iconShow,
5232
5697
  barStyle,
@@ -5244,12 +5709,12 @@ const _sfc_main$V = create$V({
5244
5709
  });
5245
5710
  }
5246
5711
  });
5247
- const _hoisted_1$I = {
5712
+ const _hoisted_1$K = {
5248
5713
  ref: "wrap",
5249
5714
  class: "wrap"
5250
5715
  };
5251
- const _hoisted_2$A = ["onClick"];
5252
- function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
5716
+ const _hoisted_2$D = ["onClick"];
5717
+ function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
5253
5718
  const _component_nut_icon = resolveComponent("nut-icon");
5254
5719
  const _component_ScrollItem = resolveComponent("ScrollItem");
5255
5720
  return openBlock(), createElementBlock("view", {
@@ -5266,17 +5731,19 @@ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
5266
5731
  class: "left-icon",
5267
5732
  style: normalizeStyle({ "background-image": `url(${_ctx.iconBg})` })
5268
5733
  }, [
5269
- !_ctx.iconBg ? (openBlock(), createBlock(_component_nut_icon, {
5270
- key: 0,
5271
- name: "notice",
5272
- size: "16",
5273
- color: _ctx.color
5274
- }, null, 8, ["color"])) : createCommentVNode("", true)
5734
+ renderSlot(_ctx.$slots, "left-icon", {}, () => [
5735
+ !_ctx.iconBg ? (openBlock(), createBlock(_component_nut_icon, {
5736
+ key: 0,
5737
+ name: "notice",
5738
+ size: "16",
5739
+ color: _ctx.color
5740
+ }, null, 8, ["color"])) : createCommentVNode("", true)
5741
+ ])
5275
5742
  ], 4)) : createCommentVNode("", true),
5276
- createElementVNode("view", _hoisted_1$I, [
5743
+ createElementVNode("view", _hoisted_1$K, [
5277
5744
  createElementVNode("view", {
5278
5745
  ref: "content",
5279
- class: normalizeClass(["content", [_ctx.animationClass, { "nut-ellipsis": !_ctx.scrollable && !_ctx.wrapable }]]),
5746
+ class: normalizeClass(["content", [_ctx.animationClass, { "nut-ellipsis": _ctx.isEllipsis }]]),
5280
5747
  style: normalizeStyle(_ctx.contentStyle),
5281
5748
  onAnimationend: _cache[0] || (_cache[0] = (...args) => _ctx.onAnimationEnd && _ctx.onAnimationEnd(...args)),
5282
5749
  onWebkitAnimationEnd: _cache[1] || (_cache[1] = (...args) => _ctx.onAnimationEnd && _ctx.onAnimationEnd(...args))
@@ -5286,15 +5753,17 @@ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
5286
5753
  ])
5287
5754
  ], 38)
5288
5755
  ], 512),
5289
- _ctx.closeMode ? (openBlock(), createElementBlock("view", {
5756
+ _ctx.closeMode || _ctx.rightIcon ? (openBlock(), createElementBlock("view", {
5290
5757
  key: 1,
5291
5758
  class: "right-icon",
5292
5759
  onClick: _cache[2] || (_cache[2] = withModifiers((...args) => _ctx.onClickIcon && _ctx.onClickIcon(...args), ["stop"]))
5293
5760
  }, [
5294
- createVNode(_component_nut_icon, {
5295
- name: "close",
5296
- color: _ctx.color
5297
- }, null, 8, ["color"])
5761
+ renderSlot(_ctx.$slots, "right-icon", {}, () => [
5762
+ createVNode(_component_nut_icon, {
5763
+ name: _ctx.rightIcon ? _ctx.rightIcon : "close",
5764
+ color: _ctx.color
5765
+ }, null, 8, ["name", "color"])
5766
+ ])
5298
5767
  ])) : createCommentVNode("", true)
5299
5768
  ], 6)), [
5300
5769
  [vShow, _ctx.showNoticeBar]
@@ -5327,7 +5796,7 @@ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
5327
5796
  key: index,
5328
5797
  style: normalizeStyle({ height: _ctx.height }),
5329
5798
  onClick: ($event) => _ctx.go(item)
5330
- }, toDisplayString(item), 13, _hoisted_2$A);
5799
+ }, toDisplayString(item), 13, _hoisted_2$D);
5331
5800
  }), 128))
5332
5801
  ], 4)),
5333
5802
  createElementVNode("view", {
@@ -5344,9 +5813,9 @@ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
5344
5813
  ], 4)) : createCommentVNode("", true)
5345
5814
  ], 2);
5346
5815
  }
5347
- var NoticeBar = /* @__PURE__ */ _export_sfc(_sfc_main$V, [["render", _sfc_render$Q]]);
5348
- const { create: create$U } = createComponent("searchbar");
5349
- const _sfc_main$U = create$U({
5816
+ var NoticeBar = /* @__PURE__ */ _export_sfc(_sfc_main$X, [["render", _sfc_render$S]]);
5817
+ const { create: create$W } = createComponent("searchbar");
5818
+ const _sfc_main$W = create$W({
5350
5819
  props: {
5351
5820
  modelValue: {
5352
5821
  type: [String, Number],
@@ -5437,41 +5906,41 @@ const _sfc_main$U = create$U({
5437
5906
  });
5438
5907
  }
5439
5908
  });
5440
- const _hoisted_1$H = {
5909
+ const _hoisted_1$J = {
5441
5910
  key: 0,
5442
5911
  class: "nut-searchbar__search-icon nut-searchbar__left-search-icon"
5443
5912
  };
5444
- const _hoisted_2$z = {
5913
+ const _hoisted_2$C = {
5445
5914
  key: 0,
5446
5915
  class: "nut-searchbar__search-icon nut-searchbar__iptleft-search-icon"
5447
5916
  };
5448
- const _hoisted_3$r = { class: "nut-searchbar__input-inner" };
5449
- const _hoisted_4$k = ["type", "maxlength", "placeholder", "value"];
5450
- const _hoisted_5$d = {
5917
+ const _hoisted_3$u = { class: "nut-searchbar__input-inner" };
5918
+ const _hoisted_4$m = ["type", "maxlength", "placeholder", "value"];
5919
+ const _hoisted_5$e = {
5451
5920
  key: 1,
5452
5921
  class: "nut-searchbar__search-icon nut-searchbar__iptright-sarch-icon"
5453
5922
  };
5454
- const _hoisted_6$a = {
5923
+ const _hoisted_6$b = {
5455
5924
  key: 1,
5456
5925
  class: "nut-searchbar__search-icon nut-searchbar__right-search-icon"
5457
5926
  };
5458
- function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
5927
+ function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
5459
5928
  const _component_nut_icon = resolveComponent("nut-icon");
5460
5929
  return openBlock(), createElementBlock("view", {
5461
5930
  class: "nut-searchbar",
5462
5931
  style: normalizeStyle(_ctx.searchbarStyle)
5463
5932
  }, [
5464
- _ctx.$slots.leftout ? (openBlock(), createElementBlock("view", _hoisted_1$H, [
5933
+ _ctx.$slots.leftout ? (openBlock(), createElementBlock("view", _hoisted_1$J, [
5465
5934
  renderSlot(_ctx.$slots, "leftout")
5466
5935
  ])) : createCommentVNode("", true),
5467
5936
  createElementVNode("view", {
5468
5937
  class: "nut-searchbar__search-input",
5469
5938
  style: normalizeStyle(_ctx.inputSearchbarStyle)
5470
5939
  }, [
5471
- _ctx.$slots.leftin ? (openBlock(), createElementBlock("view", _hoisted_2$z, [
5940
+ _ctx.$slots.leftin ? (openBlock(), createElementBlock("view", _hoisted_2$C, [
5472
5941
  renderSlot(_ctx.$slots, "leftin")
5473
5942
  ])) : createCommentVNode("", true),
5474
- createElementVNode("view", _hoisted_3$r, [
5943
+ createElementVNode("view", _hoisted_3$u, [
5475
5944
  createElementVNode("form", {
5476
5945
  action: "#",
5477
5946
  onSubmit: _cache[3] || (_cache[3] = withModifiers((...args) => _ctx.handleSubmit && _ctx.handleSubmit(...args), ["prevent"]))
@@ -5485,7 +5954,7 @@ function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
5485
5954
  onInput: _cache[0] || (_cache[0] = (...args) => _ctx.valueChange && _ctx.valueChange(...args)),
5486
5955
  onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.valueFocus && _ctx.valueFocus(...args)),
5487
5956
  onBlur: _cache[2] || (_cache[2] = (...args) => _ctx.valueBlur && _ctx.valueBlur(...args))
5488
- }, null, 40, _hoisted_4$k)
5957
+ }, null, 40, _hoisted_4$m)
5489
5958
  ], 32),
5490
5959
  _ctx.clearable ? withDirectives((openBlock(), createElementBlock("view", {
5491
5960
  key: 0,
@@ -5501,23 +5970,23 @@ function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
5501
5970
  [vShow, _ctx.modelValue.length > 0]
5502
5971
  ]) : createCommentVNode("", true)
5503
5972
  ]),
5504
- _ctx.$slots.rightin ? (openBlock(), createElementBlock("view", _hoisted_5$d, [
5973
+ _ctx.$slots.rightin ? (openBlock(), createElementBlock("view", _hoisted_5$e, [
5505
5974
  renderSlot(_ctx.$slots, "rightin")
5506
5975
  ])) : createCommentVNode("", true)
5507
5976
  ], 4),
5508
- _ctx.$slots.rightout ? (openBlock(), createElementBlock("view", _hoisted_6$a, [
5977
+ _ctx.$slots.rightout ? (openBlock(), createElementBlock("view", _hoisted_6$b, [
5509
5978
  renderSlot(_ctx.$slots, "rightout")
5510
5979
  ])) : createCommentVNode("", true)
5511
5980
  ], 4);
5512
5981
  }
5513
- var SearchBar = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["render", _sfc_render$P]]);
5514
- const { componentName: componentName$E, create: create$T } = createComponent("empty");
5982
+ var SearchBar = /* @__PURE__ */ _export_sfc(_sfc_main$W, [["render", _sfc_render$R]]);
5983
+ const { componentName: componentName$G, create: create$V } = createComponent("empty");
5515
5984
  const defaultStatus = {
5516
5985
  empty: "https://static-ftcms.jd.com/p/files/61a9e3183985005b3958672b.png",
5517
5986
  error: "https://ftcms.jd.com/p/files/61a9e33ee7dcdbcc0ce62736.png",
5518
5987
  network: "https://static-ftcms.jd.com/p/files/61a9e31de7dcdbcc0ce62734.png"
5519
5988
  };
5520
- const _sfc_main$T = create$T({
5989
+ const _sfc_main$V = create$V({
5521
5990
  props: {
5522
5991
  image: {
5523
5992
  type: String,
@@ -5551,14 +6020,14 @@ const _sfc_main$T = create$T({
5551
6020
  };
5552
6021
  }
5553
6022
  });
5554
- const _hoisted_1$G = { class: "nut-empty" };
5555
- const _hoisted_2$y = ["src"];
5556
- const _hoisted_3$q = {
6023
+ const _hoisted_1$I = { class: "nut-empty" };
6024
+ const _hoisted_2$B = ["src"];
6025
+ const _hoisted_3$t = {
5557
6026
  key: 1,
5558
6027
  class: "nut-empty-description"
5559
6028
  };
5560
- function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
5561
- return openBlock(), createElementBlock("view", _hoisted_1$G, [
6029
+ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
6030
+ return openBlock(), createElementBlock("view", _hoisted_1$I, [
5562
6031
  createElementVNode("view", {
5563
6032
  class: "nut-empty-image",
5564
6033
  style: normalizeStyle(_ctx.imgStyle)
@@ -5568,41 +6037,385 @@ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
5568
6037
  key: 0,
5569
6038
  class: "img",
5570
6039
  src: _ctx.imageUrl
5571
- }, null, 8, _hoisted_2$y)) : createCommentVNode("", true)
6040
+ }, null, 8, _hoisted_2$B)) : createCommentVNode("", true)
5572
6041
  ], 64))
5573
6042
  ], 4),
5574
- _ctx.$slots.description ? renderSlot(_ctx.$slots, "description", { key: 0 }) : (openBlock(), createElementBlock("view", _hoisted_3$q, toDisplayString(_ctx.description), 1)),
6043
+ _ctx.$slots.description ? renderSlot(_ctx.$slots, "description", { key: 0 }) : (openBlock(), createElementBlock("view", _hoisted_3$t, toDisplayString(_ctx.description), 1)),
5575
6044
  _ctx.$slots.default ? renderSlot(_ctx.$slots, "default", { key: 2 }) : createCommentVNode("", true)
5576
6045
  ]);
5577
6046
  }
5578
- var Empty = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["render", _sfc_render$O]]);
6047
+ var Empty = /* @__PURE__ */ _export_sfc(_sfc_main$V, [["render", _sfc_render$Q]]);
6048
+ const { componentName: componentName$F, create: create$U } = createComponent("audio");
6049
+ const _sfc_main$U = create$U({
6050
+ props: {
6051
+ url: {
6052
+ type: String,
6053
+ default() {
6054
+ return "";
6055
+ }
6056
+ },
6057
+ muted: {
6058
+ type: Boolean,
6059
+ default() {
6060
+ return false;
6061
+ }
6062
+ },
6063
+ autoplay: {
6064
+ type: Boolean,
6065
+ default() {
6066
+ return false;
6067
+ }
6068
+ },
6069
+ loop: {
6070
+ type: Boolean,
6071
+ default() {
6072
+ return false;
6073
+ }
6074
+ },
6075
+ preload: {
6076
+ type: String,
6077
+ default() {
6078
+ return "auto";
6079
+ }
6080
+ },
6081
+ second: {
6082
+ type: Number,
6083
+ default() {
6084
+ return 0;
6085
+ }
6086
+ },
6087
+ type: {
6088
+ type: String,
6089
+ default() {
6090
+ return "progress";
6091
+ }
6092
+ }
6093
+ },
6094
+ components: {},
6095
+ emits: ["fastBack", "play", "forward", "ended", "changeProgress", "mute"],
6096
+ setup(props, { emit }) {
6097
+ const audioRef = ref(null);
6098
+ const audioData = reactive({
6099
+ currentTime: 0,
6100
+ currentDuration: "00:00:00",
6101
+ percent: 0,
6102
+ duration: "00:00:00",
6103
+ second: 0,
6104
+ hanMuted: props.muted,
6105
+ playing: props.autoplay
6106
+ });
6107
+ onMounted(() => {
6108
+ var arr = ["webkitVisibilityState", "visibilitychange"];
6109
+ try {
6110
+ for (let i = 0; i < arr.length; i++) {
6111
+ document.addEventListener(arr[i], () => {
6112
+ if (document.hidden) {
6113
+ audioRef.value.pause();
6114
+ } else {
6115
+ if (audioData.playing) {
6116
+ setTimeout(() => {
6117
+ audioRef.value.play();
6118
+ }, 200);
6119
+ }
6120
+ }
6121
+ });
6122
+ }
6123
+ } catch (e) {
6124
+ console.log(e.message);
6125
+ }
6126
+ setTimeout(() => {
6127
+ if (props.autoplay) {
6128
+ if (audioRef.value && audioRef.value.paused) {
6129
+ audioRef.value.play();
6130
+ }
6131
+ }
6132
+ audioData.second = audioRef.value.duration;
6133
+ audioData.duration = formatSeconds(audioRef.value.duration);
6134
+ }, 500);
6135
+ });
6136
+ const onTimeupdate = (e) => {
6137
+ audioData.currentTime = parseInt(e.target.currentTime);
6138
+ };
6139
+ const fastBack = () => {
6140
+ audioData.currentTime--;
6141
+ audioRef.value.currentTime = audioData.currentTime;
6142
+ emit("fastBack", audioData.currentTime);
6143
+ };
6144
+ const changeStatus = () => {
6145
+ if (audioData.playing) {
6146
+ audioRef.value.pause();
6147
+ audioData.handPlaying = false;
6148
+ } else {
6149
+ audioRef.value.play();
6150
+ audioData.handPlaying = true;
6151
+ }
6152
+ audioData.playing = !audioData.playing;
6153
+ emit("play", audioData.playing);
6154
+ };
6155
+ const forward = () => {
6156
+ audioData.currentTime++;
6157
+ audioRef.value.currentTime = audioData.currentTime;
6158
+ emit("forward", audioData.currentTime);
6159
+ };
6160
+ const handle = (val) => {
6161
+ audioData.currentDuration = formatSeconds(val);
6162
+ audioData.percent = val / audioData.second * 100;
6163
+ };
6164
+ const audioEnd = () => {
6165
+ audioData.playing = false;
6166
+ emit("ended");
6167
+ };
6168
+ const progressChange = (val) => {
6169
+ audioRef.value.currentTime = audioData.second * val / 100;
6170
+ emit("changeProgress", audioRef.value.currentTime);
6171
+ };
6172
+ const handleMute = () => {
6173
+ audioData.hanMuted = !audioData.hanMuted;
6174
+ emit("mute", audioData.hanMuted);
6175
+ };
6176
+ const formatSeconds = (value) => {
6177
+ let theTime = parseInt(value);
6178
+ let theTime1 = 0;
6179
+ let theTime2 = 0;
6180
+ if (theTime > 60) {
6181
+ theTime1 = parseInt(theTime / 60);
6182
+ theTime = parseInt(theTime % 60);
6183
+ if (theTime1 > 60) {
6184
+ theTime2 = parseInt(theTime1 / 60);
6185
+ theTime1 = parseInt(theTime1 % 60);
6186
+ }
6187
+ }
6188
+ let result = "" + parseInt(theTime);
6189
+ if (result < 10) {
6190
+ result = "0" + result;
6191
+ }
6192
+ if (theTime1 > 0) {
6193
+ result = "" + parseInt(theTime1) + ":" + result;
6194
+ if (theTime1 < 10) {
6195
+ result = "0" + result;
6196
+ }
6197
+ } else {
6198
+ result = "00:" + result;
6199
+ }
6200
+ if (theTime2 > 0) {
6201
+ result = "" + parseInt(theTime2) + ":" + result;
6202
+ if (theTime2 < 10) {
6203
+ result = "0" + result;
6204
+ }
6205
+ } else {
6206
+ result = "00:" + result;
6207
+ }
6208
+ return result;
6209
+ };
6210
+ watch(() => audioData.currentTime, (value) => {
6211
+ handle(value);
6212
+ });
6213
+ provide("audioParent", {
6214
+ children: [],
6215
+ props,
6216
+ audioData,
6217
+ handleMute,
6218
+ forward,
6219
+ fastBack,
6220
+ changeStatus
6221
+ });
6222
+ return __spreadProps(__spreadValues(__spreadValues({}, toRefs(props)), toRefs(audioData)), {
6223
+ audioRef,
6224
+ fastBack,
6225
+ forward,
6226
+ changeStatus,
6227
+ progressChange,
6228
+ audioEnd,
6229
+ onTimeupdate,
6230
+ handleMute
6231
+ });
6232
+ }
6233
+ });
6234
+ const _hoisted_1$H = { class: "nut-audio" };
6235
+ const _hoisted_2$A = {
6236
+ key: 0,
6237
+ class: "progress-wrapper"
6238
+ };
6239
+ const _hoisted_3$s = { class: "time" };
6240
+ const _hoisted_4$l = { class: "progress-bar-wrapper" };
6241
+ const _hoisted_5$d = /* @__PURE__ */ createElementVNode("div", { class: "custom-button" }, null, -1);
6242
+ const _hoisted_6$a = { class: "time" };
6243
+ const _hoisted_7$8 = {
6244
+ key: 1,
6245
+ class: "nut-audio-icon"
6246
+ };
6247
+ const _hoisted_8$8 = ["controls", "src", "preload", "autoplay", "loop", "muted"];
6248
+ function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
6249
+ const _component_nut_range = resolveComponent("nut-range");
6250
+ const _component_nut_icon = resolveComponent("nut-icon");
6251
+ return openBlock(), createElementBlock("div", _hoisted_1$H, [
6252
+ _ctx.type == "progress" ? (openBlock(), createElementBlock("div", _hoisted_2$A, [
6253
+ createElementVNode("div", _hoisted_3$s, toDisplayString(_ctx.currentDuration), 1),
6254
+ createElementVNode("div", _hoisted_4$l, [
6255
+ createVNode(_component_nut_range, {
6256
+ modelValue: _ctx.percent,
6257
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.percent = $event),
6258
+ "hidden-range": "",
6259
+ onChange: _ctx.progressChange,
6260
+ "inactive-color": "#cccccc",
6261
+ "active-color": "#fa2c19"
6262
+ }, {
6263
+ button: withCtx(() => [
6264
+ _hoisted_5$d
6265
+ ]),
6266
+ _: 1
6267
+ }, 8, ["modelValue", "onChange"])
6268
+ ]),
6269
+ createElementVNode("div", _hoisted_6$a, toDisplayString(_ctx.duration), 1)
6270
+ ])) : createCommentVNode("", true),
6271
+ _ctx.type == "icon" ? (openBlock(), createElementBlock("div", _hoisted_7$8, [
6272
+ createElementVNode("div", {
6273
+ class: normalizeClass(["nut-audio-icon-box", _ctx.playing ? "nut-audio-icon-play" : "nut-audio-icon-stop"]),
6274
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.changeStatus && _ctx.changeStatus(...args))
6275
+ }, [
6276
+ _ctx.playing ? (openBlock(), createBlock(_component_nut_icon, {
6277
+ key: 0,
6278
+ name: "service",
6279
+ class: "nut-icon-am-rotate nut-icon-am-infinite"
6280
+ })) : createCommentVNode("", true),
6281
+ !_ctx.playing ? (openBlock(), createBlock(_component_nut_icon, {
6282
+ key: 1,
6283
+ name: "service"
6284
+ })) : createCommentVNode("", true)
6285
+ ], 2)
6286
+ ])) : createCommentVNode("", true),
6287
+ _ctx.type == "none" ? (openBlock(), createElementBlock("div", {
6288
+ key: 2,
6289
+ onClick: _cache[2] || (_cache[2] = (...args) => _ctx.changeStatus && _ctx.changeStatus(...args))
6290
+ }, [
6291
+ renderSlot(_ctx.$slots, "default")
6292
+ ])) : createCommentVNode("", true),
6293
+ _ctx.type != "none" ? renderSlot(_ctx.$slots, "default", { key: 3 }) : createCommentVNode("", true),
6294
+ createElementVNode("audio", {
6295
+ class: "audioMain",
6296
+ controls: _ctx.type == "controls",
6297
+ ref: "audioRef",
6298
+ src: _ctx.url,
6299
+ preload: _ctx.preload,
6300
+ autoplay: _ctx.autoplay,
6301
+ loop: _ctx.loop,
6302
+ onTimeupdate: _cache[3] || (_cache[3] = (...args) => _ctx.onTimeupdate && _ctx.onTimeupdate(...args)),
6303
+ onEnded: _cache[4] || (_cache[4] = (...args) => _ctx.audioEnd && _ctx.audioEnd(...args)),
6304
+ muted: _ctx.hanMuted
6305
+ }, null, 40, _hoisted_8$8)
6306
+ ]);
6307
+ }
6308
+ var Audio = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["render", _sfc_render$P]]);
6309
+ const { componentName: componentName$E, create: create$T } = createComponent("audio-operate");
6310
+ const _sfc_main$T = create$T({
6311
+ props: {
6312
+ type: {
6313
+ type: Array,
6314
+ default() {
6315
+ return "play";
6316
+ }
6317
+ }
6318
+ },
6319
+ components: {},
6320
+ emits: ["click"],
6321
+ setup(props, { emit }) {
6322
+ const audio = inject("audioParent");
6323
+ const parent = reactive(audio);
6324
+ const customSlot = ref(useSlots().default);
6325
+ return __spreadProps(__spreadValues(__spreadValues({}, toRefs(props)), toRefs(parent)), { customSlot });
6326
+ }
6327
+ });
6328
+ const _hoisted_1$G = { class: "nut-audio-operate" };
6329
+ const _hoisted_2$z = /* @__PURE__ */ createTextVNode("\u5012\u9000");
6330
+ const _hoisted_3$r = /* @__PURE__ */ createTextVNode("\u5FEB\u8FDB");
6331
+ const _hoisted_4$k = /* @__PURE__ */ createTextVNode("\u9759\u97F3");
6332
+ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
6333
+ const _component_nut_button = resolveComponent("nut-button");
6334
+ return openBlock(), createElementBlock("div", _hoisted_1$G, [
6335
+ _ctx.type == "back" ? (openBlock(), createElementBlock("div", {
6336
+ key: 0,
6337
+ class: "nut-audio-operate-item",
6338
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.fastBack && _ctx.fastBack(...args))
6339
+ }, [
6340
+ !_ctx.customSlot ? (openBlock(), createBlock(_component_nut_button, {
6341
+ key: 0,
6342
+ type: "primary",
6343
+ size: "small"
6344
+ }, {
6345
+ default: withCtx(() => [
6346
+ _hoisted_2$z
6347
+ ]),
6348
+ _: 1
6349
+ })) : createCommentVNode("", true),
6350
+ renderSlot(_ctx.$slots, "default")
6351
+ ])) : createCommentVNode("", true),
6352
+ _ctx.type == "play" ? (openBlock(), createElementBlock("div", {
6353
+ key: 1,
6354
+ class: "nut-audio-operate-item",
6355
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.changeStatus && _ctx.changeStatus(...args))
6356
+ }, [
6357
+ !_ctx.customSlot ? (openBlock(), createBlock(_component_nut_button, {
6358
+ key: 0,
6359
+ type: "primary",
6360
+ size: "small"
6361
+ }, {
6362
+ default: withCtx(() => [
6363
+ createTextVNode(toDisplayString(!_ctx.audioData.playing ? "\u5F00\u59CB" : "\u6682\u505C"), 1)
6364
+ ]),
6365
+ _: 1
6366
+ })) : createCommentVNode("", true),
6367
+ renderSlot(_ctx.$slots, "default")
6368
+ ])) : createCommentVNode("", true),
6369
+ _ctx.type == "forward" ? (openBlock(), createElementBlock("div", {
6370
+ key: 2,
6371
+ class: "nut-audio-operate-item",
6372
+ onClick: _cache[2] || (_cache[2] = (...args) => _ctx.forward && _ctx.forward(...args))
6373
+ }, [
6374
+ !_ctx.customSlot ? (openBlock(), createBlock(_component_nut_button, {
6375
+ key: 0,
6376
+ type: "primary",
6377
+ size: "small"
6378
+ }, {
6379
+ default: withCtx(() => [
6380
+ _hoisted_3$r
6381
+ ]),
6382
+ _: 1
6383
+ })) : createCommentVNode("", true),
6384
+ renderSlot(_ctx.$slots, "default")
6385
+ ])) : createCommentVNode("", true),
6386
+ _ctx.type == "mute" ? (openBlock(), createElementBlock("div", {
6387
+ key: 3,
6388
+ class: "nut-audio-operate-item",
6389
+ onClick: _cache[3] || (_cache[3] = (...args) => _ctx.handleMute && _ctx.handleMute(...args))
6390
+ }, [
6391
+ !_ctx.customSlot ? (openBlock(), createBlock(_component_nut_button, {
6392
+ key: 0,
6393
+ type: !_ctx.audioData.hanMuted ? "primary" : "default",
6394
+ size: "small"
6395
+ }, {
6396
+ default: withCtx(() => [
6397
+ _hoisted_4$k
6398
+ ]),
6399
+ _: 1
6400
+ }, 8, ["type"])) : createCommentVNode("", true),
6401
+ renderSlot(_ctx.$slots, "default")
6402
+ ])) : createCommentVNode("", true)
6403
+ ]);
6404
+ }
6405
+ var AudioOperate = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["render", _sfc_render$O]]);
5579
6406
  const { componentName: componentName$D, create: create$S } = createComponent("navbar");
5580
6407
  const _sfc_main$S = create$S({
5581
6408
  props: {
5582
6409
  leftShow: { type: Boolean, default: true },
5583
6410
  title: { type: String, default: "" },
5584
6411
  titIcon: { type: String, default: "" },
5585
- icon: { type: String, default: "" },
5586
6412
  desc: { type: String, default: "" },
5587
6413
  defaultIndex: {
5588
6414
  type: Number,
5589
6415
  default: 0
5590
6416
  }
5591
6417
  },
5592
- emits: [
5593
- "click",
5594
- "on-click-back",
5595
- "on-click-title",
5596
- "on-click-right",
5597
- "on-click-desc",
5598
- "on-click-icon",
5599
- "on-click-more",
5600
- "on-click-clear",
5601
- "on-click-send",
5602
- "on-click-slot",
5603
- "on-click-slot-send",
5604
- "switch-tab"
5605
- ],
6418
+ emits: ["click", "on-click-back", "on-click-title", "on-click-icon", "on-click-right"],
5606
6419
  setup(props, { emit }) {
5607
6420
  const activeIndex = ref(props.defaultIndex);
5608
6421
  const classes = computed(() => {
@@ -5620,32 +6433,22 @@ const _sfc_main$S = create$S({
5620
6433
  function handleCenterIcon() {
5621
6434
  emit("on-click-icon");
5622
6435
  }
5623
- function handleClear() {
5624
- emit("on-click-clear");
5625
- }
5626
- function handleSend() {
5627
- emit("on-click-send");
5628
- }
5629
- function handleSlot() {
5630
- emit("on-click-slot");
5631
- }
5632
- function handleSends() {
5633
- emit("on-click-slot-send");
6436
+ function handleRight() {
6437
+ emit("on-click-right");
5634
6438
  }
5635
6439
  return {
5636
6440
  classes,
5637
6441
  handleLeft,
5638
6442
  handleCenter,
5639
6443
  handleCenterIcon,
5640
- handleClear,
5641
- handleSend,
5642
- handleSlot,
5643
- handleSends,
6444
+ handleRight,
5644
6445
  activeIndex
5645
6446
  };
5646
6447
  }
5647
6448
  });
5648
6449
  const _hoisted_1$F = { class: "nut-navbar__left" };
6450
+ const _hoisted_2$y = { class: "nut-navbar__title" };
6451
+ const _hoisted_3$q = { class: "nut-navbar__right" };
5649
6452
  function _sfc_render$N(_ctx, _cache, $props, $setup, $data, $options) {
5650
6453
  const _component_nut_icon = resolveComponent("nut-icon");
5651
6454
  return openBlock(), createElementBlock("view", {
@@ -5657,11 +6460,10 @@ function _sfc_render$N(_ctx, _cache, $props, $setup, $data, $options) {
5657
6460
  color: "#979797",
5658
6461
  name: "left",
5659
6462
  onClick: _ctx.handleLeft
5660
- }, null, 8, ["onClick"])) : createCommentVNode("", true)
6463
+ }, null, 8, ["onClick"])) : createCommentVNode("", true),
6464
+ renderSlot(_ctx.$slots, "left")
5661
6465
  ]),
5662
- createElementVNode("view", {
5663
- class: normalizeClass(["nut-navbar__title", { icon: _ctx.icon }])
5664
- }, [
6466
+ createElementVNode("view", _hoisted_2$y, [
5665
6467
  _ctx.title ? (openBlock(), createElementBlock("view", {
5666
6468
  key: 0,
5667
6469
  onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleCenter && _ctx.handleCenter(...args))
@@ -5673,31 +6475,15 @@ function _sfc_render$N(_ctx, _cache, $props, $setup, $data, $options) {
5673
6475
  onClick: _ctx.handleCenterIcon
5674
6476
  }, null, 8, ["name", "onClick"])) : createCommentVNode("", true),
5675
6477
  renderSlot(_ctx.$slots, "content")
5676
- ], 2),
5677
- _ctx.desc || _ctx.icon ? (openBlock(), createElementBlock("view", {
5678
- key: 0,
5679
- class: normalizeClass(["nut-navbar__right", { icon: _ctx.icon }])
5680
- }, [
6478
+ ]),
6479
+ createElementVNode("view", _hoisted_3$q, [
5681
6480
  _ctx.desc ? (openBlock(), createElementBlock("view", {
5682
6481
  key: 0,
5683
- style: normalizeStyle({ "text-align": _ctx.descTextAlign }),
5684
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleClear && _ctx.handleClear(...args))
5685
- }, toDisplayString(_ctx.desc), 5)) : createCommentVNode("", true),
5686
- _ctx.icon ? (openBlock(), createElementBlock("view", {
5687
- key: 1,
5688
- onClick: _cache[2] || (_cache[2] = (...args) => _ctx.handleSends && _ctx.handleSends(...args))
5689
- }, [
5690
- renderSlot(_ctx.$slots, "icons")
5691
- ])) : createCommentVNode("", true),
5692
- createElementVNode("view", null, [
5693
- _ctx.icon ? (openBlock(), createBlock(_component_nut_icon, {
5694
- key: 0,
5695
- class: "rightIcon",
5696
- name: _ctx.icon,
5697
- onClick: _ctx.handleSend
5698
- }, null, 8, ["name", "onClick"])) : createCommentVNode("", true)
5699
- ])
5700
- ], 2)) : createCommentVNode("", true)
6482
+ class: "right_text",
6483
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleRight && _ctx.handleRight(...args))
6484
+ }, toDisplayString(_ctx.desc), 1)) : createCommentVNode("", true),
6485
+ renderSlot(_ctx.$slots, "right")
6486
+ ])
5701
6487
  ], 2);
5702
6488
  }
5703
6489
  var Navbar = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["render", _sfc_render$N]]);
@@ -5950,7 +6736,7 @@ const _sfc_main$P = create$P({
5950
6736
  }
5951
6737
  },
5952
6738
  components: {
5953
- [_sfc_main$1o.name]: _sfc_main$1o,
6739
+ [_sfc_main$1s.name]: _sfc_main$1s,
5954
6740
  [Popup.name]: Popup
5955
6741
  },
5956
6742
  emits: ["update:modelValue", "change"],
@@ -6222,7 +7008,11 @@ const _sfc_main$N = create$N({
6222
7008
  }
6223
7009
  if (parent.children[value].to) {
6224
7010
  let to = parent.children[value].to;
6225
- router.push(to);
7011
+ if (to && router) {
7012
+ router.push(to);
7013
+ } else {
7014
+ location.replace(to);
7015
+ }
6226
7016
  }
6227
7017
  });
6228
7018
  });
@@ -6309,7 +7099,8 @@ const _sfc_main$M = create$M({
6309
7099
  y2: 0
6310
7100
  },
6311
7101
  scrollStart: false,
6312
- currentIndex: 0
7102
+ currentIndex: 0,
7103
+ currentData: {}
6313
7104
  });
6314
7105
  const classes = computed(() => {
6315
7106
  const prefixCls = componentName$z;
@@ -6369,7 +7160,6 @@ const _sfc_main$M = create$M({
6369
7160
  state.touchState.y1 = firstTouch.pageY;
6370
7161
  state.anchorIndex = +index;
6371
7162
  state.currentIndex = +index;
6372
- console.log(state.currentIndex);
6373
7163
  scrollTo(+index);
6374
7164
  };
6375
7165
  const touchMove = (e) => {
@@ -6384,10 +7174,14 @@ const _sfc_main$M = create$M({
6384
7174
  };
6385
7175
  const handleClickItem = (key, item) => {
6386
7176
  context.emit("click-item", key, item);
7177
+ state.currentData = item;
6387
7178
  };
6388
7179
  const handleClickIndex = (key) => {
6389
7180
  context.emit("click-index", key);
6390
7181
  };
7182
+ useExpose({
7183
+ scrollTo
7184
+ });
6391
7185
  return __spreadProps(__spreadValues({
6392
7186
  classes
6393
7187
  }, toRefs(state)), {
@@ -6424,11 +7218,11 @@ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
6424
7218
  createElementVNode("view", _hoisted_1$A, toDisplayString(item[_ctx.acceptKey]), 1),
6425
7219
  (openBlock(true), createElementBlock(Fragment, null, renderList(item.list, (subitem) => {
6426
7220
  return openBlock(), createElementBlock("view", {
6427
- class: "nut-elevator__list__item__name",
7221
+ class: normalizeClass(["nut-elevator__list__item__name", { "nut-elevator__list__item__name--highcolor": _ctx.currentData.id === subitem.id }]),
6428
7222
  key: subitem["id"],
6429
7223
  onClick: ($event) => _ctx.handleClickItem(item[_ctx.acceptKey], subitem),
6430
7224
  innerHTML: subitem.name
6431
- }, null, 8, _hoisted_2$t);
7225
+ }, null, 10, _hoisted_2$t);
6432
7226
  }), 128))
6433
7227
  ]);
6434
7228
  }), 128))
@@ -7440,12 +8234,36 @@ const _sfc_main$C = create$C({
7440
8234
  type: Boolean,
7441
8235
  default: true
7442
8236
  },
8237
+ showTitle: {
8238
+ type: Boolean,
8239
+ default: true
8240
+ },
8241
+ showSubTitle: {
8242
+ type: Boolean,
8243
+ default: true
8244
+ },
8245
+ showToday: {
8246
+ type: Boolean,
8247
+ default: true
8248
+ },
7443
8249
  title: {
7444
8250
  type: String,
7445
8251
  default: "\u65E5\u5386\u9009\u62E9"
7446
8252
  },
7447
- defaultValue: {
8253
+ confirmText: {
8254
+ type: String,
8255
+ default: "\u786E\u8BA4"
8256
+ },
8257
+ startText: {
7448
8258
  type: String,
8259
+ default: "\u5F00\u59CB"
8260
+ },
8261
+ endText: {
8262
+ type: String,
8263
+ default: "\u7ED3\u675F"
8264
+ },
8265
+ defaultValue: {
8266
+ type: [String, Array],
7449
8267
  default: null
7450
8268
  },
7451
8269
  startDate: {
@@ -7457,15 +8275,32 @@ const _sfc_main$C = create$C({
7457
8275
  default: Utils.getDay(365)
7458
8276
  }
7459
8277
  },
7460
- emits: ["choose", "update", "close"],
7461
- setup(props, { emit }) {
8278
+ emits: ["choose", "update", "close", "select"],
8279
+ setup(props, { emit, slots }) {
7462
8280
  const weeks = ref(["\u65E5", "\u4E00", "\u4E8C", "\u4E09", "\u56DB", "\u4E94", "\u516D"]);
7463
8281
  const months = ref(null);
7464
8282
  const monthsPanel = ref(null);
7465
8283
  const weeksPanel = ref(null);
8284
+ const viewArea = ref(null);
8285
+ const viewHeight = ref(0);
8286
+ const compConthsData = computed(() => {
8287
+ return state.monthsData.slice(state.defaultRange[0], state.defaultRange[1]);
8288
+ });
8289
+ const showTopBtn = computed(() => {
8290
+ return slots.btn;
8291
+ });
8292
+ const topInfo = computed(() => {
8293
+ return slots.topInfo;
8294
+ });
8295
+ const bottomInfo = computed(() => {
8296
+ return slots.bottomInfo;
8297
+ });
7466
8298
  const state = reactive({
7467
8299
  yearMonthTitle: "",
8300
+ defaultRange: [],
7468
8301
  currDate: "",
8302
+ propStartDate: "",
8303
+ propEndDate: "",
7469
8304
  unLoadPrev: false,
7470
8305
  touchParams: {
7471
8306
  startY: 0,
@@ -7485,7 +8320,10 @@ const _sfc_main$C = create$C({
7485
8320
  startData: "",
7486
8321
  endData: "",
7487
8322
  isRange: props.type === "range",
7488
- timer: 0
8323
+ timer: 0,
8324
+ currentIndex: 0,
8325
+ avgHeight: 0,
8326
+ monthsNum: 0
7489
8327
  });
7490
8328
  const splitDate = (date) => {
7491
8329
  return date.split("-");
@@ -7497,14 +8335,14 @@ const _sfc_main$C = create$C({
7497
8335
  return Utils.isEqual(state.currDate[1], currDate);
7498
8336
  };
7499
8337
  const getCurrDate = (day, month, isRange) => {
7500
- return isRange ? month.curData[3] + "-" + month.curData[4] + "-" + Utils.getNumTwoBit(+day.day) : month.curData[0] + "-" + month.curData[1] + "-" + Utils.getNumTwoBit(+day.day);
8338
+ return month.curData[0] + "-" + month.curData[1] + "-" + Utils.getNumTwoBit(+day.day);
7501
8339
  };
7502
8340
  const getClass = (day, month, isRange) => {
7503
- const currDate = getCurrDate(day, month, isRange);
8341
+ const currDate = getCurrDate(day, month);
7504
8342
  if (day.type == "curr") {
7505
8343
  if (!state.isRange && Utils.isEqual(state.currDate, currDate) || state.isRange && (isStart(currDate) || isEnd(currDate))) {
7506
8344
  return `${state.dayPrefix}-active`;
7507
- } else if (props.startDate && Utils.compareDate(currDate, props.startDate) || props.endDate && Utils.compareDate(props.endDate, currDate)) {
8345
+ } else if (state.propStartDate && Utils.compareDate(currDate, state.propStartDate) || state.propEndDate && Utils.compareDate(state.propEndDate, currDate)) {
7508
8346
  return `${state.dayPrefix}-disabled`;
7509
8347
  } 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])) {
7510
8348
  return `${state.dayPrefix}-choose`;
@@ -7524,9 +8362,8 @@ const _sfc_main$C = create$C({
7524
8362
  }
7525
8363
  };
7526
8364
  const chooseDay = (day, month, isFirst, isRange) => {
7527
- if (getClass(day, month, isRange) != `${state.dayPrefix}-disabled`) {
8365
+ if (getClass(day, month) != `${state.dayPrefix}-disabled`) {
7528
8366
  let days = [...month.curData];
7529
- days = isRange ? days.splice(3) : days.splice(0, 3);
7530
8367
  days[2] = typeof day.day == "number" ? Utils.getNumTwoBit(day.day) : day.day;
7531
8368
  days[3] = `${days[0]}-${days[1]}-${days[2]}`;
7532
8369
  days[4] = Utils.getWhatDay(+days[0], +days[1], +days[2]);
@@ -7553,8 +8390,11 @@ const _sfc_main$C = create$C({
7553
8390
  }
7554
8391
  }
7555
8392
  }
7556
- if (props.isAutoBackFill && !isFirst) {
7557
- confirm();
8393
+ if (!isFirst) {
8394
+ emit("select", state.chooseData);
8395
+ if (props.isAutoBackFill) {
8396
+ confirm();
8397
+ }
7558
8398
  }
7559
8399
  }
7560
8400
  };
@@ -7572,26 +8412,47 @@ const _sfc_main$C = create$C({
7572
8412
  month = month == 12 ? 1 : ++month;
7573
8413
  break;
7574
8414
  }
7575
- return [
7576
- year,
7577
- Utils.getNumTwoBit(month),
7578
- Utils.getMonthDays(String(year), String(month))
7579
- ];
8415
+ return [year, Utils.getNumTwoBit(month), Utils.getMonthDays(String(year), String(month))];
7580
8416
  };
7581
- const getDaysStatus = (days, type) => {
8417
+ const getDaysStatus = (days, type, dateInfo) => {
8418
+ let { year, month } = dateInfo;
7582
8419
  if (type == "prev" && days >= 7) {
7583
8420
  days -= 7;
7584
8421
  }
7585
8422
  return Array.from(Array(days), (v, k) => {
7586
8423
  return {
7587
8424
  day: k + 1,
7588
- type
8425
+ type,
8426
+ year,
8427
+ month
8428
+ };
8429
+ });
8430
+ };
8431
+ const getPreDaysStatus = (days, type, dateInfo, preCurrMonthDays) => {
8432
+ let { year, month } = dateInfo;
8433
+ if (type == "prev" && days >= 7) {
8434
+ days -= 7;
8435
+ }
8436
+ let months2 = Array.from(Array(preCurrMonthDays), (v, k) => {
8437
+ return {
8438
+ day: k + 1,
8439
+ type,
8440
+ year,
8441
+ month
7589
8442
  };
7590
8443
  });
8444
+ return months2.slice(preCurrMonthDays - days);
7591
8445
  };
7592
8446
  const getMonth = (curData, type) => {
7593
8447
  const preMonthDays = Utils.getMonthPreDay(+curData[0], +curData[1]);
8448
+ let preMonth = curData[1] - 1;
8449
+ let preYear = curData[0];
8450
+ if (preMonth <= 0) {
8451
+ preMonth = 12;
8452
+ preYear += 1;
8453
+ }
7594
8454
  const currMonthDays = Utils.getMonthDays(curData[0], curData[1]);
8455
+ const preCurrMonthDays = Utils.getMonthDays(preYear + "", preMonth + "");
7595
8456
  const title = {
7596
8457
  year: curData[0],
7597
8458
  month: curData[1]
@@ -7600,10 +8461,16 @@ const _sfc_main$C = create$C({
7600
8461
  curData,
7601
8462
  title: `${title.year}\u5E74${title.month}\u6708`,
7602
8463
  monthData: [
7603
- ...getDaysStatus(preMonthDays, "prev"),
7604
- ...getDaysStatus(currMonthDays, "curr")
8464
+ ...getPreDaysStatus(preMonthDays, "prev", { month: preMonth, year: preYear }, preCurrMonthDays),
8465
+ ...getDaysStatus(currMonthDays, "curr", title)
7605
8466
  ]
7606
8467
  };
8468
+ monthInfo.cssHeight = 39 + (monthInfo.monthData.length > 35 ? 384 : 320);
8469
+ let cssScrollHeight = 0;
8470
+ if (state.monthsData.length > 0) {
8471
+ cssScrollHeight = state.monthsData[state.monthsData.length - 1].cssScrollHeight + state.monthsData[state.monthsData.length - 1].cssHeight;
8472
+ }
8473
+ monthInfo.cssScrollHeight = cssScrollHeight;
7607
8474
  if (type == "next") {
7608
8475
  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]}`)) {
7609
8476
  state.monthsData.push(monthInfo);
@@ -7617,44 +8484,97 @@ const _sfc_main$C = create$C({
7617
8484
  }
7618
8485
  };
7619
8486
  const initData = () => {
7620
- state.startData = props.startDate ? splitDate(props.startDate) : "";
7621
- state.endData = props.endDate ? splitDate(props.endDate) : "";
7622
- if (!props.defaultValue) {
8487
+ let propStartDate = props.startDate ? props.startDate : Utils.getDay(0);
8488
+ let propEndDate = props.endDate ? props.endDate : Utils.getDay(365);
8489
+ state.propStartDate = propStartDate;
8490
+ state.propEndDate = propEndDate;
8491
+ state.startData = splitDate(propStartDate);
8492
+ state.endData = splitDate(propEndDate);
8493
+ if (!props.defaultValue || Array.isArray(props.defaultValue) && props.defaultValue.length <= 0) {
7623
8494
  state.currDate = state.isRange ? [Utils.date2Str(new Date()), Utils.getDay(1)] : Utils.date2Str(new Date());
7624
8495
  } else {
7625
8496
  state.currDate = state.isRange ? [...props.defaultValue] : props.defaultValue;
7626
8497
  }
8498
+ const startDate = {
8499
+ year: Number(state.startData[0]),
8500
+ month: Number(state.startData[1])
8501
+ };
8502
+ const endDate = {
8503
+ year: Number(state.endData[0]),
8504
+ month: Number(state.endData[1])
8505
+ };
8506
+ let monthsNum = endDate.month - startDate.month;
8507
+ if (endDate.year - startDate.year > 0) {
8508
+ monthsNum = monthsNum + 12 * (endDate.year - startDate.year);
8509
+ }
8510
+ getMonth(state.startData, "next");
8511
+ let i = 1;
8512
+ do {
8513
+ getMonth(getCurrData("next"), "next");
8514
+ } while (i++ < monthsNum);
8515
+ state.monthsNum = monthsNum;
7627
8516
  if (state.isRange && Array.isArray(state.currDate)) {
7628
- if (props.startDate && Utils.compareDate(state.currDate[0], props.startDate)) {
7629
- state.currDate.splice(0, 1, props.startDate);
8517
+ if (propStartDate && Utils.compareDate(state.currDate[0], propStartDate)) {
8518
+ state.currDate.splice(0, 1, propStartDate);
7630
8519
  }
7631
- if (props.endDate && Utils.compareDate(props.endDate, state.currDate[1])) {
7632
- state.currDate.splice(1, 1, props.endDate);
8520
+ if (propEndDate && Utils.compareDate(propEndDate, state.currDate[1])) {
8521
+ state.currDate.splice(1, 1, propEndDate);
7633
8522
  }
7634
- state.defaultData = [
7635
- ...splitDate(state.currDate[0]),
7636
- ...splitDate(state.currDate[1])
7637
- ];
8523
+ state.defaultData = [...splitDate(state.currDate[0]), ...splitDate(state.currDate[1])];
7638
8524
  } else {
7639
- if (props.startDate && Utils.compareDate(state.currDate, props.startDate)) {
7640
- state.currDate = props.startDate;
7641
- } else if (props.endDate && !Utils.compareDate(state.currDate, props.endDate)) {
7642
- state.currDate = props.endDate;
8525
+ if (propStartDate && Utils.compareDate(state.currDate, propStartDate)) {
8526
+ state.currDate = propStartDate;
8527
+ } else if (propEndDate && !Utils.compareDate(state.currDate, propEndDate)) {
8528
+ state.currDate = propEndDate;
7643
8529
  }
7644
8530
  state.defaultData = [...splitDate(state.currDate)];
7645
8531
  }
7646
- getMonth(state.defaultData, "next");
7647
- state.yearMonthTitle = state.monthsData[0].title;
7648
- let i = 1;
7649
- do {
7650
- getMonth(getCurrData("next"), "next");
7651
- } while (i++ < 4);
8532
+ let current = 0;
8533
+ let lastCurrent = 0;
8534
+ state.monthsData.forEach((item, index) => {
8535
+ if (item.title == `${state.defaultData[0]}\u5E74${state.defaultData[1]}\u6708`) {
8536
+ current = index;
8537
+ }
8538
+ if (state.isRange) {
8539
+ if (item.title == `${state.defaultData[3]}\u5E74${state.defaultData[4]}\u6708`) {
8540
+ lastCurrent = index;
8541
+ }
8542
+ }
8543
+ });
8544
+ setDefaultRange(monthsNum, current);
8545
+ state.currentIndex = current;
8546
+ state.yearMonthTitle = state.monthsData[state.currentIndex].title;
7652
8547
  if (state.isRange) {
7653
- chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[0], true);
7654
- chooseDay({ day: state.defaultData[5], type: "curr" }, state.monthsData[0], true, true);
8548
+ chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[state.currentIndex], true);
8549
+ chooseDay({ day: state.defaultData[5], type: "curr" }, state.monthsData[lastCurrent], true);
7655
8550
  } else {
7656
- chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[0], true);
8551
+ chooseDay({ day: state.defaultData[2], type: "curr" }, state.monthsData[state.currentIndex], true);
7657
8552
  }
8553
+ let lastItem = state.monthsData[state.monthsData.length - 1];
8554
+ let containerHeight = lastItem.cssHeight + lastItem.cssScrollHeight;
8555
+ requestAniFrame$1(() => {
8556
+ if ((months == null ? void 0 : months.value) && (monthsPanel == null ? void 0 : monthsPanel.value) && (viewArea == null ? void 0 : viewArea.value)) {
8557
+ viewHeight.value = months.value.clientHeight;
8558
+ monthsPanel.value.style.height = `${containerHeight}px`;
8559
+ months.value.scrollTop = state.monthsData[state.currentIndex].cssScrollHeight;
8560
+ }
8561
+ });
8562
+ state.avgHeight = Math.floor(containerHeight / (monthsNum + 1));
8563
+ };
8564
+ const setDefaultRange = (monthsNum, current) => {
8565
+ if (monthsNum >= 3) {
8566
+ if (current > 0 && current < monthsNum) {
8567
+ state.defaultRange = [current - 1, current + 3];
8568
+ } else if (current == 0) {
8569
+ state.defaultRange = [current, current + 4];
8570
+ } else if (current == monthsNum) {
8571
+ state.defaultRange = [current - 2, current + 2];
8572
+ }
8573
+ } else {
8574
+ state.defaultRange = [0, monthsNum + 2];
8575
+ }
8576
+ let defaultScrollTop = state.monthsData[state.defaultRange[0]].cssScrollHeight;
8577
+ state.translateY = defaultScrollTop;
7658
8578
  };
7659
8579
  const isActive = (day, month) => {
7660
8580
  return state.isRange && day.type == "curr" && getClass(day, month) == "calendar-month-day-active";
@@ -7667,139 +8587,72 @@ const _sfc_main$C = create$C({
7667
8587
  }
7668
8588
  };
7669
8589
  const isEndTip = (day, month) => {
7670
- return isActive(day, month);
8590
+ if (state.currDate.length >= 2 && isEnd(getCurrDate(day, month))) {
8591
+ return isActive(day, month);
8592
+ }
8593
+ return false;
8594
+ };
8595
+ const rangeTip = (day, month) => {
8596
+ if (state.currDate.length >= 2) {
8597
+ return Utils.isEqual(state.currDate[0], state.currDate[1]);
8598
+ }
7671
8599
  };
7672
8600
  const isCurrDay = (month, day) => {
7673
8601
  const date = `${month.curData[0]}-${month.curData[1]}-${day}`;
7674
8602
  return Utils.isEqual(date, Utils.date2Str(new Date()));
7675
8603
  };
7676
- const loadScroll = () => {
7677
- if (!props.poppable) {
7678
- return false;
7679
- }
7680
- requestAniFrame$1(() => {
7681
- if ((weeksPanel == null ? void 0 : weeksPanel.value) && (monthsPanel == null ? void 0 : monthsPanel.value)) {
7682
- const top = weeksPanel == null ? void 0 : weeksPanel.value.getBoundingClientRect().bottom;
7683
- const monthsDoms = monthsPanel.value.getElementsByClassName("calendar-month");
7684
- for (let i = 0; i < monthsDoms.length; i++) {
7685
- if (monthsDoms[i].getBoundingClientRect().top <= top && monthsDoms[i].getBoundingClientRect().bottom >= top) {
7686
- state.yearMonthTitle = state.monthsData[i].title;
7687
- } else if (state.scrollDistance === 0) {
7688
- state.yearMonthTitle = state.monthsData[0].title;
7689
- }
7690
- }
7691
- }
7692
- });
7693
- };
7694
- const setTransform = (translateY = 0, type, time = 1e3) => {
7695
- if (monthsPanel == null ? void 0 : monthsPanel.value) {
7696
- if (type === "end") {
7697
- monthsPanel.value.style.webkitTransition = `transform ${time}ms cubic-bezier(0.19, 1, 0.22, 1)`;
7698
- clearTimeout(state.timer);
7699
- state.timer = setTimeout(() => {
7700
- loadScroll();
7701
- }, time);
7702
- } else {
7703
- monthsPanel.value.style.webkitTransition = "";
7704
- loadScroll();
7705
- }
7706
- monthsPanel.value.style.webkitTransform = `translateY(${translateY}px)`;
7707
- state.scrollDistance = translateY;
7708
- }
7709
- };
7710
- const setMove = (move, type, time) => {
7711
- var _a, _b;
7712
- let updateMove = move + state.transformY;
7713
- const h2 = ((_a = months.value) == null ? void 0 : _a.offsetHeight) || 0;
7714
- const offsetHeight = ((_b = monthsPanel.value) == null ? void 0 : _b.offsetHeight) || 0;
7715
- if (type === "end") {
7716
- if (updateMove > 0) {
7717
- updateMove = 0;
8604
+ const mothsViewScroll = (e) => {
8605
+ var currentScrollTop = e.target.scrollTop;
8606
+ let current = Math.floor(currentScrollTop / state.avgHeight);
8607
+ if (current == 0) {
8608
+ if (currentScrollTop >= state.monthsData[current + 1].cssScrollHeight) {
8609
+ current += 1;
7718
8610
  }
7719
- if (updateMove < 0 && updateMove < -offsetHeight + h2) {
7720
- updateMove = -offsetHeight + h2;
8611
+ } else if (current > 0 && current < state.monthsNum - 1) {
8612
+ if (currentScrollTop >= state.monthsData[current + 1].cssScrollHeight) {
8613
+ current += 1;
7721
8614
  }
7722
- if (offsetHeight <= h2 && state.monthsData.length == 1) {
7723
- updateMove = 0;
8615
+ if (currentScrollTop < state.monthsData[current].cssScrollHeight) {
8616
+ current -= 1;
7724
8617
  }
7725
- setTransform(updateMove, type, time);
7726
8618
  } else {
7727
- if (updateMove > 0 && updateMove > 100) {
7728
- updateMove = 100;
7729
- }
7730
- if (updateMove < -offsetHeight + h2 - 100 && state.monthsData.length > 1) {
7731
- updateMove = -offsetHeight + h2 - 100;
8619
+ if (currentScrollTop + viewHeight.value < state.monthsData[current].cssScrollHeight + state.monthsData[current].cssHeight) {
8620
+ current -= 1;
7732
8621
  }
7733
- if (updateMove < 0 && updateMove < -100 && state.monthsData.length == 1) {
7734
- updateMove = -100;
8622
+ if (current + 1 <= state.monthsNum && currentScrollTop + viewHeight.value >= state.monthsData[current + 1].cssScrollHeight + state.monthsData[current + 1].cssHeight) {
8623
+ current += 1;
7735
8624
  }
7736
- setTransform(updateMove);
7737
- }
7738
- };
7739
- const touchStart = (event) => {
7740
- const changedTouches = event.changedTouches[0];
7741
- state.touchParams.startY = changedTouches.pageY;
7742
- state.touchParams.startTime = event.timeStamp || Date.now();
7743
- state.transformY = state.scrollDistance;
7744
- };
7745
- const touchMove = (event) => {
7746
- const changedTouches = event.changedTouches[0];
7747
- state.touchParams.lastY = changedTouches.pageY;
7748
- state.touchParams.lastTime = event.timeStamp || Date.now();
7749
- const move = state.touchParams.lastY - state.touchParams.startY;
7750
- if (Math.abs(move) < 5) {
7751
- return false;
7752
- }
7753
- setMove(move);
7754
- };
7755
- const touchEnd = (event) => {
7756
- var _a, _b;
7757
- const changedTouches = event.changedTouches[0];
7758
- state.touchParams.lastY = changedTouches.pageY;
7759
- state.touchParams.lastTime = event.timeStamp || Date.now();
7760
- let move = state.touchParams.lastY - state.touchParams.startY;
7761
- if (Math.abs(move) < 5) {
7762
- return false;
7763
- }
7764
- const updateMove = move + state.transformY;
7765
- const h2 = ((_a = months.value) == null ? void 0 : _a.offsetHeight) || 0;
7766
- const offsetHeight = ((_b = monthsPanel.value) == null ? void 0 : _b.offsetHeight) || 0;
7767
- if (updateMove > 0) {
7768
- getMonth(getCurrData("prev"), "prev");
7769
- } else if (updateMove < 0 && updateMove < -offsetHeight + (Math.abs(move) > h2 ? Math.abs(move) : h2) * 5) {
7770
- getMonth(getCurrData("next"), "next");
7771
- if (Math.abs(move) >= 300) {
7772
- getMonth(getCurrData("next"), "next");
8625
+ if (currentScrollTop < state.monthsData[current - 1].cssScrollHeight) {
8626
+ current -= 1;
7773
8627
  }
7774
8628
  }
7775
- let moveTime = state.touchParams.lastTime - state.touchParams.startTime;
7776
- if (moveTime <= 300) {
7777
- move = move * 2;
7778
- moveTime = moveTime + 1e3;
7779
- setMove(move, "end", moveTime);
7780
- } else {
7781
- setMove(move, "end");
8629
+ if (state.currentIndex !== current) {
8630
+ state.currentIndex = current;
8631
+ setDefaultRange(state.monthsNum, current);
7782
8632
  }
8633
+ state.yearMonthTitle = state.monthsData[current].title;
7783
8634
  };
7784
8635
  const resetRender = () => {
7785
8636
  state.chooseData.splice(0);
7786
8637
  state.monthsData.splice(0);
7787
- state.scrollDistance = 0;
7788
- state.translateY = 0;
7789
- setTransform(state.scrollDistance);
7790
8638
  initData();
7791
8639
  };
7792
8640
  initData();
7793
8641
  watch(() => props.defaultValue, (val) => {
7794
8642
  if (val) {
7795
- resetRender();
8643
+ if (props.poppable) {
8644
+ resetRender();
8645
+ }
7796
8646
  }
7797
8647
  });
7798
8648
  return __spreadValues(__spreadValues({
7799
8649
  weeks,
7800
- touchStart,
7801
- touchMove,
7802
- touchEnd,
8650
+ compConthsData,
8651
+ showTopBtn,
8652
+ topInfo,
8653
+ bottomInfo,
8654
+ rangeTip,
8655
+ mothsViewScroll,
7803
8656
  getClass,
7804
8657
  isStartTip,
7805
8658
  isEndTip,
@@ -7808,38 +8661,52 @@ const _sfc_main$C = create$C({
7808
8661
  confirm,
7809
8662
  monthsPanel,
7810
8663
  months,
7811
- weeksPanel
8664
+ weeksPanel,
8665
+ viewArea
7812
8666
  }, toRefs(state)), toRefs(props));
7813
8667
  }
7814
8668
  });
7815
- const _hoisted_1$t = { class: "calendar-title" };
7816
- const _hoisted_2$o = { class: "calendar-curr-month" };
8669
+ const _hoisted_1$t = {
8670
+ key: 0,
8671
+ class: "calendar-title"
8672
+ };
8673
+ const _hoisted_2$o = {
8674
+ key: 1,
8675
+ class: "calendar-top-slot"
8676
+ };
7817
8677
  const _hoisted_3$k = {
8678
+ key: 2,
8679
+ class: "calendar-curr-month"
8680
+ };
8681
+ const _hoisted_4$f = {
7818
8682
  class: "calendar-weeks",
7819
8683
  ref: "weeksPanel"
7820
8684
  };
7821
- const _hoisted_4$f = {
8685
+ const _hoisted_5$a = {
7822
8686
  class: "calendar-months-panel",
7823
8687
  ref: "monthsPanel"
7824
8688
  };
7825
- const _hoisted_5$a = { class: "calendar-loading-tip" };
7826
8689
  const _hoisted_6$8 = { class: "calendar-month-title" };
7827
8690
  const _hoisted_7$7 = { class: "calendar-month-con" };
7828
8691
  const _hoisted_8$7 = ["onClick"];
7829
8692
  const _hoisted_9$5 = { class: "calendar-day" };
7830
8693
  const _hoisted_10$3 = {
7831
8694
  key: 0,
7832
- class: "calendar-curr-tips"
8695
+ class: "calendar-curr-tips calendar-curr-tips-top"
7833
8696
  };
7834
8697
  const _hoisted_11$3 = {
7835
8698
  key: 1,
7836
- class: "calendar-day-tip"
8699
+ class: "calendar-curr-tips calendar-curr-tips-bottom"
7837
8700
  };
7838
8701
  const _hoisted_12$3 = {
7839
8702
  key: 2,
7840
- class: "calendar-day-tip"
8703
+ class: "calendar-curr-tip-curr"
7841
8704
  };
7842
8705
  const _hoisted_13$2 = {
8706
+ key: 4,
8707
+ class: "calendar-day-tip"
8708
+ };
8709
+ const _hoisted_14$2 = {
7843
8710
  key: 0,
7844
8711
  class: "nut-calendar-footer"
7845
8712
  };
@@ -7853,11 +8720,12 @@ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
7853
8720
  createElementVNode("view", {
7854
8721
  class: normalizeClass(["nut-calendar-header", { "nut-calendar-header-tile": !_ctx.poppable }])
7855
8722
  }, [
7856
- _ctx.poppable ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
7857
- createElementVNode("view", _hoisted_1$t, toDisplayString(_ctx.title), 1),
7858
- createElementVNode("view", _hoisted_2$o, toDisplayString(_ctx.yearMonthTitle), 1)
7859
- ], 64)) : createCommentVNode("", true),
7860
- createElementVNode("view", _hoisted_3$k, [
8723
+ _ctx.showTitle ? (openBlock(), createElementBlock("view", _hoisted_1$t, toDisplayString(_ctx.title), 1)) : createCommentVNode("", true),
8724
+ _ctx.showTopBtn ? (openBlock(), createElementBlock("view", _hoisted_2$o, [
8725
+ renderSlot(_ctx.$slots, "btn")
8726
+ ])) : createCommentVNode("", true),
8727
+ _ctx.showSubTitle ? (openBlock(), createElementBlock("view", _hoisted_3$k, toDisplayString(_ctx.yearMonthTitle), 1)) : createCommentVNode("", true),
8728
+ createElementVNode("view", _hoisted_4$f, [
7861
8729
  (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.weeks, (item, index) => {
7862
8730
  return openBlock(), createElementBlock("view", {
7863
8731
  class: "calendar-week-item",
@@ -7869,44 +8737,67 @@ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
7869
8737
  createElementVNode("view", {
7870
8738
  class: "nut-calendar-content",
7871
8739
  ref: "months",
7872
- onTouchstart: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.touchStart && _ctx.touchStart(...args), ["stop"])),
7873
- onTouchmove: _cache[1] || (_cache[1] = withModifiers((...args) => _ctx.touchMove && _ctx.touchMove(...args), ["stop", "prevent"])),
7874
- onTouchend: _cache[2] || (_cache[2] = withModifiers((...args) => _ctx.touchEnd && _ctx.touchEnd(...args), ["stop"]))
8740
+ onScroll: _cache[0] || (_cache[0] = (...args) => _ctx.mothsViewScroll && _ctx.mothsViewScroll(...args))
7875
8741
  }, [
7876
- createElementVNode("view", _hoisted_4$f, [
7877
- createElementVNode("view", _hoisted_5$a, toDisplayString(!_ctx.unLoadPrev ? "\u52A0\u8F7D\u4E0A\u4E00\u4E2A\u6708" : "\u6CA1\u6709\u66F4\u65E9\u6708\u4EFD"), 1),
7878
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.monthsData, (month, index) => {
7879
- return openBlock(), createElementBlock("view", {
7880
- class: "calendar-month",
7881
- key: index
7882
- }, [
7883
- createElementVNode("view", _hoisted_6$8, toDisplayString(month.title), 1),
7884
- createElementVNode("view", _hoisted_7$7, [
7885
- createElementVNode("view", {
7886
- class: normalizeClass(["calendar-month-item", _ctx.type === "range" ? "month-item-range" : ""])
7887
- }, [
7888
- (openBlock(true), createElementBlock(Fragment, null, renderList(month.monthData, (day, i) => {
7889
- return openBlock(), createElementBlock("view", {
7890
- key: i,
7891
- class: normalizeClass(["calendar-month-day", _ctx.getClass(day, month)]),
7892
- onClick: ($event) => _ctx.chooseDay(day, month)
7893
- }, [
7894
- createElementVNode("view", _hoisted_9$5, toDisplayString(day.type == "curr" ? day.day : ""), 1),
7895
- _ctx.isCurrDay(month, day.day) ? (openBlock(), createElementBlock("view", _hoisted_10$3, "\u4ECA\u5929")) : createCommentVNode("", true),
7896
- _ctx.isStartTip(day, month) ? (openBlock(), createElementBlock("view", _hoisted_11$3, toDisplayString("\u5F00\u59CB"))) : _ctx.isEndTip(day, month) ? (openBlock(), createElementBlock("view", _hoisted_12$3, toDisplayString("\u7ED3\u675F"))) : createCommentVNode("", true)
7897
- ], 10, _hoisted_8$7);
7898
- }), 128))
7899
- ], 2)
7900
- ])
7901
- ]);
7902
- }), 128))
8742
+ createElementVNode("view", _hoisted_5$a, [
8743
+ createElementVNode("view", {
8744
+ class: "viewArea",
8745
+ ref: "viewArea",
8746
+ style: normalizeStyle({ transform: `translateY(${_ctx.translateY}px)` })
8747
+ }, [
8748
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.compConthsData, (month, index) => {
8749
+ return openBlock(), createElementBlock("view", {
8750
+ class: "calendar-month",
8751
+ key: index
8752
+ }, [
8753
+ createElementVNode("view", _hoisted_6$8, toDisplayString(month.title), 1),
8754
+ createElementVNode("view", _hoisted_7$7, [
8755
+ createElementVNode("view", {
8756
+ class: normalizeClass(["calendar-month-item", _ctx.type === "range" ? "month-item-range" : ""])
8757
+ }, [
8758
+ (openBlock(true), createElementBlock(Fragment, null, renderList(month.monthData, (day, i) => {
8759
+ return openBlock(), createElementBlock("view", {
8760
+ key: i,
8761
+ class: normalizeClass(["calendar-month-day", _ctx.getClass(day, month)]),
8762
+ onClick: ($event) => _ctx.chooseDay(day, month)
8763
+ }, [
8764
+ createElementVNode("view", _hoisted_9$5, [
8765
+ renderSlot(_ctx.$slots, "day", {
8766
+ date: day.type == "curr" ? day : ""
8767
+ }, () => [
8768
+ createTextVNode(toDisplayString(day.type == "curr" ? day.day : ""), 1)
8769
+ ])
8770
+ ]),
8771
+ _ctx.topInfo ? (openBlock(), createElementBlock("view", _hoisted_10$3, [
8772
+ renderSlot(_ctx.$slots, "topInfo", {
8773
+ date: day.type == "curr" ? day : ""
8774
+ })
8775
+ ])) : createCommentVNode("", true),
8776
+ _ctx.bottomInfo ? (openBlock(), createElementBlock("view", _hoisted_11$3, [
8777
+ renderSlot(_ctx.$slots, "bottomInfo", {
8778
+ date: day.type == "curr" ? day : ""
8779
+ })
8780
+ ])) : createCommentVNode("", true),
8781
+ !_ctx.bottomInfo && _ctx.showToday && _ctx.isCurrDay(month, day.day) ? (openBlock(), createElementBlock("view", _hoisted_12$3, " \u4ECA\u5929 ")) : createCommentVNode("", true),
8782
+ _ctx.isStartTip(day, month) ? (openBlock(), createElementBlock("view", {
8783
+ key: 3,
8784
+ class: normalizeClass(["calendar-day-tip", { "calendar-curr-tips-top": _ctx.rangeTip(day, month) }])
8785
+ }, toDisplayString(_ctx.startText), 3)) : createCommentVNode("", true),
8786
+ _ctx.isEndTip(day, month) ? (openBlock(), createElementBlock("view", _hoisted_13$2, toDisplayString(_ctx.endText), 1)) : createCommentVNode("", true)
8787
+ ], 10, _hoisted_8$7);
8788
+ }), 128))
8789
+ ], 2)
8790
+ ])
8791
+ ]);
8792
+ }), 128))
8793
+ ], 4)
7903
8794
  ], 512)
7904
8795
  ], 544),
7905
- _ctx.poppable && !_ctx.isAutoBackFill ? (openBlock(), createElementBlock("view", _hoisted_13$2, [
8796
+ _ctx.poppable && !_ctx.isAutoBackFill ? (openBlock(), createElementBlock("view", _hoisted_14$2, [
7906
8797
  createElementVNode("view", {
7907
8798
  class: "calendar-confirm-btn",
7908
- onClick: _cache[3] || (_cache[3] = (...args) => _ctx.confirm && _ctx.confirm(...args))
7909
- }, "\u786E\u5B9A")
8799
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.confirm && _ctx.confirm(...args))
8800
+ }, toDisplayString(_ctx.confirmText), 1)
7910
8801
  ])) : createCommentVNode("", true)
7911
8802
  ], 2);
7912
8803
  }
@@ -7929,16 +8820,40 @@ const _sfc_main$B = create$B({
7929
8820
  type: Boolean,
7930
8821
  default: true
7931
8822
  },
8823
+ showTitle: {
8824
+ type: Boolean,
8825
+ default: true
8826
+ },
8827
+ showSubTitle: {
8828
+ type: Boolean,
8829
+ default: true
8830
+ },
7932
8831
  visible: {
7933
8832
  type: Boolean,
7934
8833
  default: false
7935
8834
  },
8835
+ showToday: {
8836
+ type: Boolean,
8837
+ default: true
8838
+ },
7936
8839
  title: {
7937
8840
  type: String,
7938
8841
  default: "\u65E5\u5386\u9009\u62E9"
7939
8842
  },
8843
+ confirmText: {
8844
+ type: String,
8845
+ default: "\u786E\u8BA4"
8846
+ },
8847
+ startText: {
8848
+ type: String,
8849
+ default: "\u5F00\u59CB"
8850
+ },
8851
+ endText: {
8852
+ type: String,
8853
+ default: "\u7ED3\u675F"
8854
+ },
7940
8855
  defaultValue: {
7941
- type: String
8856
+ type: [String, Array]
7942
8857
  },
7943
8858
  startDate: {
7944
8859
  type: String,
@@ -7949,8 +8864,20 @@ const _sfc_main$B = create$B({
7949
8864
  default: Utils.getDay(365)
7950
8865
  }
7951
8866
  },
7952
- emits: ["choose", "close", "update:visible"],
7953
- setup(props, { emit }) {
8867
+ emits: ["choose", "close", "update:visible", "select"],
8868
+ setup(props, { emit, slots }) {
8869
+ const showTopBtn = computed(() => {
8870
+ return slots.btn;
8871
+ });
8872
+ const topInfo = computed(() => {
8873
+ return slots.topInfo;
8874
+ });
8875
+ const dayInfo = computed(() => {
8876
+ return slots.day;
8877
+ });
8878
+ const bottomInfo = computed(() => {
8879
+ return slots.bottomInfo;
8880
+ });
7954
8881
  const calendarRef = ref(null);
7955
8882
  const update = () => {
7956
8883
  emit("update:visible", false);
@@ -7963,6 +8890,9 @@ const _sfc_main$B = create$B({
7963
8890
  close();
7964
8891
  emit("choose", param);
7965
8892
  };
8893
+ const select = (param) => {
8894
+ emit("select", param);
8895
+ };
7966
8896
  const closePopup = () => {
7967
8897
  close();
7968
8898
  };
@@ -7971,7 +8901,12 @@ const _sfc_main$B = create$B({
7971
8901
  update,
7972
8902
  close,
7973
8903
  choose,
7974
- calendarRef
8904
+ select,
8905
+ calendarRef,
8906
+ showTopBtn,
8907
+ topInfo,
8908
+ dayInfo,
8909
+ bottomInfo
7975
8910
  };
7976
8911
  }
7977
8912
  });
@@ -7985,43 +8920,121 @@ function _sfc_render$x(_ctx, _cache, $props, $setup, $data, $options) {
7985
8920
  round: "",
7986
8921
  closeable: true,
7987
8922
  onClickOverlay: _ctx.closePopup,
7988
- onClickCloseIcon: _ctx.closePopup
8923
+ onClickCloseIcon: _ctx.closePopup,
8924
+ "destroy-on-close": true,
8925
+ style: { height: "85vh" }
7989
8926
  }, {
7990
8927
  default: withCtx(() => [
7991
- createVNode(_component_nut_calendar_item, {
8928
+ _ctx.visible ? (openBlock(), createBlock(_component_nut_calendar_item, {
8929
+ key: 0,
7992
8930
  props: "",
7993
8931
  ref: "calendarRef",
7994
8932
  type: _ctx.type,
7995
8933
  "is-auto-back-fill": _ctx.isAutoBackFill,
7996
8934
  poppable: _ctx.poppable,
7997
8935
  title: _ctx.title,
8936
+ "confirm-text": _ctx.confirmText,
8937
+ "start-text": _ctx.startText,
8938
+ "end-text": _ctx.endText,
7998
8939
  "default-value": _ctx.defaultValue,
8940
+ "show-today": _ctx.showToday,
7999
8941
  "start-date": _ctx.startDate,
8000
8942
  "end-date": _ctx.endDate,
8001
8943
  onUpdate: _ctx.update,
8002
8944
  onClose: _ctx.close,
8003
- onChoose: _ctx.choose
8004
- }, null, 8, ["type", "is-auto-back-fill", "poppable", "title", "default-value", "start-date", "end-date", "onUpdate", "onClose", "onChoose"])
8945
+ onChoose: _ctx.choose,
8946
+ onSelect: _ctx.select,
8947
+ "show-title": _ctx.showTitle,
8948
+ "show-sub-title": _ctx.showSubTitle
8949
+ }, createSlots({ _: 2 }, [
8950
+ _ctx.showTopBtn ? {
8951
+ name: "btn",
8952
+ fn: withCtx(() => [
8953
+ renderSlot(_ctx.$slots, "btn")
8954
+ ])
8955
+ } : void 0,
8956
+ _ctx.dayInfo ? {
8957
+ name: "day",
8958
+ fn: withCtx((date) => [
8959
+ renderSlot(_ctx.$slots, "day", {
8960
+ date: date.date
8961
+ })
8962
+ ])
8963
+ } : void 0,
8964
+ _ctx.topInfo ? {
8965
+ name: "topInfo",
8966
+ fn: withCtx((date) => [
8967
+ renderSlot(_ctx.$slots, "topInfo", {
8968
+ date: date.date
8969
+ })
8970
+ ])
8971
+ } : void 0,
8972
+ _ctx.bottomInfo ? {
8973
+ name: "bottomInfo",
8974
+ fn: withCtx((date) => [
8975
+ renderSlot(_ctx.$slots, "bottomInfo", {
8976
+ date: date.date
8977
+ })
8978
+ ])
8979
+ } : void 0
8980
+ ]), 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"])) : createCommentVNode("", true)
8005
8981
  ]),
8006
- _: 1
8982
+ _: 3
8007
8983
  }, 8, ["visible", "onClickOverlay", "onClickCloseIcon"])) : (openBlock(), createBlock(_component_nut_calendar_item, {
8008
8984
  key: 1,
8009
8985
  type: _ctx.type,
8010
8986
  "is-auto-back-fill": _ctx.isAutoBackFill,
8011
8987
  poppable: _ctx.poppable,
8012
8988
  title: _ctx.title,
8989
+ "confirm-text": _ctx.confirmText,
8990
+ "start-text": _ctx.startText,
8991
+ "end-text": _ctx.endText,
8013
8992
  "default-value": _ctx.defaultValue,
8014
8993
  "start-date": _ctx.startDate,
8015
8994
  "end-date": _ctx.endDate,
8016
8995
  onClose: _ctx.close,
8017
- onChoose: _ctx.choose
8018
- }, null, 8, ["type", "is-auto-back-fill", "poppable", "title", "default-value", "start-date", "end-date", "onClose", "onChoose"]));
8996
+ onChoose: _ctx.choose,
8997
+ onSelect: _ctx.select,
8998
+ "show-title": _ctx.showTitle,
8999
+ "show-sub-title": _ctx.showSubTitle
9000
+ }, createSlots({ _: 2 }, [
9001
+ _ctx.showTopBtn ? {
9002
+ name: "btn",
9003
+ fn: withCtx(() => [
9004
+ renderSlot(_ctx.$slots, "btn")
9005
+ ])
9006
+ } : void 0,
9007
+ _ctx.dayInfo ? {
9008
+ name: "day",
9009
+ fn: withCtx((date) => [
9010
+ renderSlot(_ctx.$slots, "day", {
9011
+ date: date.date
9012
+ })
9013
+ ])
9014
+ } : void 0,
9015
+ _ctx.topInfo ? {
9016
+ name: "topInfo",
9017
+ fn: withCtx((date) => [
9018
+ renderSlot(_ctx.$slots, "topInfo", {
9019
+ date: date.date
9020
+ })
9021
+ ])
9022
+ } : void 0,
9023
+ _ctx.bottomInfo ? {
9024
+ name: "bottomInfo",
9025
+ fn: withCtx((date) => [
9026
+ renderSlot(_ctx.$slots, "bottomInfo", {
9027
+ date: date.date
9028
+ })
9029
+ ])
9030
+ } : void 0
9031
+ ]), 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"]));
8019
9032
  }
8020
9033
  var Calendar = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["render", _sfc_render$x]]);
8021
9034
  const { create: create$A, componentName: componentName$r } = createComponent("checkbox");
8022
9035
  const _sfc_main$A = create$A({
8023
9036
  components: {
8024
- nutIcon: _sfc_main$1o
9037
+ nutIcon: _sfc_main$1s
8025
9038
  },
8026
9039
  props: {
8027
9040
  modelValue: {
@@ -8055,7 +9068,7 @@ const _sfc_main$A = create$A({
8055
9068
  },
8056
9069
  emits: ["change", "update:modelValue"],
8057
9070
  setup(props, { emit, slots }) {
8058
- const parent = inject("parent");
9071
+ const parent = inject("parent", null);
8059
9072
  const hasParent = computed(() => !!parent);
8060
9073
  const pValue = computed(() => {
8061
9074
  if (hasParent.value) {
@@ -8077,7 +9090,7 @@ const _sfc_main$A = create$A({
8077
9090
  };
8078
9091
  const renderIcon = () => {
8079
9092
  const { iconName, iconSize, iconActiveName } = props;
8080
- return h(_sfc_main$1o, {
9093
+ return h(_sfc_main$1s, {
8081
9094
  name: !pValue.value ? iconName : iconActiveName,
8082
9095
  size: iconSize,
8083
9096
  class: color.value
@@ -8161,7 +9174,7 @@ const _sfc_main$z = create$z({
8161
9174
  watch(() => props.modelValue, (value) => {
8162
9175
  emit("change", value);
8163
9176
  });
8164
- useExpose$1({ toggleAll });
9177
+ useExpose({ toggleAll });
8165
9178
  return () => {
8166
9179
  var _a;
8167
9180
  return h("view", {
@@ -8444,6 +9457,7 @@ const _sfc_main$x = create$x({
8444
9457
  return "text";
8445
9458
  });
8446
9459
  const columnList = computed(() => {
9460
+ console.log("\u521D\u59CB\u5316", dataType.value);
8447
9461
  if (dataType.value === "text") {
8448
9462
  return [{ values: state.formattedColumns, defaultIndex: state.defaultIndex }];
8449
9463
  } else if (dataType.value === "multipleColumns") {
@@ -8809,7 +9823,6 @@ const _sfc_main$w = create$w({
8809
9823
  return 0;
8810
9824
  };
8811
9825
  const columns = computed(() => {
8812
- console.log(ranges.value);
8813
9826
  const val = ranges.value.map((res) => {
8814
9827
  return generateValue(res.range[0], res.range[1], getDateIndex(res.type), res.type);
8815
9828
  });
@@ -9089,6 +10102,9 @@ const _sfc_main$u = create$u({
9089
10102
  [`${prefixCls}-border`]: props.hasBorder
9090
10103
  };
9091
10104
  });
10105
+ const inputmode = computed(() => {
10106
+ return props.type === "digit" ? "decimal" : props.type === "number" ? "numeric" : "text";
10107
+ });
9092
10108
  const styles = computed(() => {
9093
10109
  return {
9094
10110
  textAlign: props.textAlign
@@ -9135,6 +10151,7 @@ const _sfc_main$u = create$u({
9135
10151
  active,
9136
10152
  classes,
9137
10153
  styles,
10154
+ inputmode,
9138
10155
  valueChange,
9139
10156
  valueFocus,
9140
10157
  valueBlur,
@@ -9147,7 +10164,7 @@ const _hoisted_1$p = {
9147
10164
  class: "nut-input-label"
9148
10165
  };
9149
10166
  const _hoisted_2$l = { class: "label-string" };
9150
- const _hoisted_3$i = ["type", "maxlength", "placeholder", "disabled", "readonly", "value"];
10167
+ const _hoisted_3$i = ["type", "maxlength", "placeholder", "disabled", "readonly", "value", "inputmode"];
9151
10168
  function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
9152
10169
  const _component_nut_icon = resolveComponent("nut-icon");
9153
10170
  return openBlock(), createElementBlock("view", {
@@ -9165,6 +10182,7 @@ function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
9165
10182
  disabled: _ctx.disabled,
9166
10183
  readonly: _ctx.readonly,
9167
10184
  value: _ctx.modelValue,
10185
+ inputmode: _ctx.inputmode,
9168
10186
  onInput: _cache[0] || (_cache[0] = (...args) => _ctx.valueChange && _ctx.valueChange(...args)),
9169
10187
  onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.valueFocus && _ctx.valueFocus(...args)),
9170
10188
  onBlur: _cache[2] || (_cache[2] = (...args) => _ctx.valueBlur && _ctx.valueBlur(...args))
@@ -9213,7 +10231,7 @@ const _sfc_main$t = create$t({
9213
10231
  }
9214
10232
  },
9215
10233
  setup(props, { emit, slots }) {
9216
- let parent = inject("parent");
10234
+ let parent = inject("parent", null);
9217
10235
  const isCurValue = computed(() => {
9218
10236
  return parent.label.value == props.label;
9219
10237
  });
@@ -9225,7 +10243,7 @@ const _sfc_main$t = create$t({
9225
10243
  });
9226
10244
  const renderIcon = () => {
9227
10245
  const { iconName, iconSize, iconActiveName } = props;
9228
- return h(_sfc_main$1o, {
10246
+ return h(_sfc_main$1s, {
9229
10247
  name: isCurValue.value ? iconActiveName : iconName,
9230
10248
  size: iconSize,
9231
10249
  class: color.value
@@ -9463,6 +10481,10 @@ const _sfc_main$q = create$q({
9463
10481
  length: {
9464
10482
  type: [String, Number],
9465
10483
  default: 6
10484
+ },
10485
+ isWrapTeleport: {
10486
+ type: Boolean,
10487
+ default: true
9466
10488
  }
9467
10489
  },
9468
10490
  emits: ["update:modelValue", "update:visible", "complete", "change", "ok", "tips", "close", "cancel"],
@@ -9482,7 +10504,10 @@ const _sfc_main$q = create$q({
9482
10504
  });
9483
10505
  watch(() => props.modelValue, (value) => {
9484
10506
  realInput.value = value;
9485
- console.log("watch", value);
10507
+ emit("update:modelValue", value);
10508
+ }, {
10509
+ deep: true,
10510
+ immediate: true
9486
10511
  });
9487
10512
  function changeValue(e) {
9488
10513
  const input = e.target;
@@ -9576,7 +10601,8 @@ function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
9576
10601
  closeable: true,
9577
10602
  onClickCloseIcon: _ctx.closeIcon,
9578
10603
  "close-on-click-overlay": _ctx.closeOnClickOverlay,
9579
- onClickOverlay: _ctx.close
10604
+ onClickOverlay: _ctx.close,
10605
+ isWrapTeleport: _ctx.isWrapTeleport
9580
10606
  }, {
9581
10607
  default: withCtx(() => [
9582
10608
  createElementVNode("view", _hoisted_1$n, toDisplayString(_ctx.title), 1),
@@ -9633,7 +10659,7 @@ function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
9633
10659
  ])) : createCommentVNode("", true)
9634
10660
  ]),
9635
10661
  _: 1
9636
- }, 8, ["visible", "onClickCloseIcon", "close-on-click-overlay", "onClickOverlay"])
10662
+ }, 8, ["visible", "onClickCloseIcon", "close-on-click-overlay", "onClickOverlay", "isWrapTeleport"])
9637
10663
  ]);
9638
10664
  }
9639
10665
  var ShortPassword = /* @__PURE__ */ _export_sfc(_sfc_main$q, [["render", _sfc_render$q]]);
@@ -10804,7 +11830,6 @@ const _sfc_main$m = create$m({
10804
11830
  },
10805
11831
  emits: ["input", "delete", "close", "update:value"],
10806
11832
  setup(props, { emit }) {
10807
- console.log(props.overlay);
10808
11833
  const clickKeyIndex = ref(void 0);
10809
11834
  const show = ref(props.visible);
10810
11835
  const root = ref();
@@ -11477,6 +12502,9 @@ const _sfc_main$i = create$i({
11477
12502
  emit("update:visible", false);
11478
12503
  };
11479
12504
  const chooseItem = (item, index) => {
12505
+ if (item.disabled) {
12506
+ return;
12507
+ }
11480
12508
  emit("choose", item, index);
11481
12509
  };
11482
12510
  return {
@@ -11885,7 +12913,7 @@ const component$1 = {
11885
12913
  };
11886
12914
  });
11887
12915
  const getStyle = () => {
11888
- if (avatarSize == null ? void 0 : avatarSize.value) {
12916
+ if (avatarSize.value) {
11889
12917
  return {
11890
12918
  width: avatarSize.value,
11891
12919
  height: avatarSize.value
@@ -11897,7 +12925,6 @@ const component$1 = {
11897
12925
  };
11898
12926
  };
11899
12927
  onMounted(() => {
11900
- console.log("row", props.row);
11901
12928
  });
11902
12929
  return {
11903
12930
  avatarShape,
@@ -11914,7 +12941,10 @@ const _hoisted_2$c = {
11914
12941
  key: 1,
11915
12942
  class: "skeleton"
11916
12943
  };
11917
- const _hoisted_3$b = /* @__PURE__ */ createElementVNode("view", { class: "skeleton-animation" }, null, -1);
12944
+ const _hoisted_3$b = {
12945
+ key: 0,
12946
+ class: "skeleton-animation"
12947
+ };
11918
12948
  const _hoisted_4$a = { class: "content" };
11919
12949
  const _hoisted_5$5 = { class: "content-line" };
11920
12950
  const _hoisted_6$3 = {
@@ -11926,7 +12956,7 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
11926
12956
  return !_ctx.loading ? (openBlock(), createElementBlock("view", _hoisted_1$e, [
11927
12957
  renderSlot(_ctx.$slots, "default")
11928
12958
  ])) : (openBlock(), createElementBlock("view", _hoisted_2$c, [
11929
- _hoisted_3$b,
12959
+ _ctx.animated ? (openBlock(), createElementBlock("view", _hoisted_3$b)) : createCommentVNode("", true),
11930
12960
  createElementVNode("view", _hoisted_4$a, [
11931
12961
  _ctx.avatar ? (openBlock(), createBlock(_component_nut_avatar, {
11932
12962
  key: 0,
@@ -12117,7 +13147,7 @@ const _sfc_main$e = create$e({
12117
13147
  const tree = ref(new Tree([], {}));
12118
13148
  const panes = ref([]);
12119
13149
  const isLazy = computed(() => configs.value.lazy && Boolean(configs.value.lazyLoad));
12120
- const lazyLoadMap = new Map();
13150
+ const lazyLoadMap = /* @__PURE__ */ new Map();
12121
13151
  let currentProcessNode;
12122
13152
  const init = async () => {
12123
13153
  lazyLoadMap.clear();
@@ -12460,6 +13490,10 @@ const { componentName: componentName$b, create: create$c } = createComponent("ad
12460
13490
  const _sfc_main$c = create$c({
12461
13491
  inheritAttrs: false,
12462
13492
  props: {
13493
+ modelValue: {
13494
+ type: Array,
13495
+ default: () => []
13496
+ },
12463
13497
  visible: {
12464
13498
  type: Boolean,
12465
13499
  default: false
@@ -12523,9 +13557,13 @@ const _sfc_main$c = create$c({
12523
13557
  height: {
12524
13558
  type: [String, Number],
12525
13559
  default: "200px"
13560
+ },
13561
+ columnsPlaceholder: {
13562
+ type: [String, Array],
13563
+ default: "\u8BF7\u9009\u62E9"
12526
13564
  }
12527
13565
  },
12528
- emits: ["update:visible", "type", "change", "selected", "close", "close-mask", "switch-module"],
13566
+ emits: ["update:visible", "update:modelValue", "type", "change", "selected", "close", "close-mask", "switch-module"],
12529
13567
  setup(props, { emit }) {
12530
13568
  const regionLine = ref(null);
12531
13569
  const tabRegion = ref(null);
@@ -12533,6 +13571,7 @@ const _sfc_main$c = create$c({
12533
13571
  const privateType = ref(props.type);
12534
13572
  const tabIndex = ref(0);
12535
13573
  const tabName = ref(["province", "city", "country", "town"]);
13574
+ const tabNameDefault = ref([""]);
12536
13575
  const isCustom2 = computed(() => props.type === "custom2");
12537
13576
  const transformData = (data) => {
12538
13577
  if (!Array.isArray(data))
@@ -12580,13 +13619,55 @@ const _sfc_main$c = create$c({
12580
13619
  let selectedExistAddress = reactive({});
12581
13620
  const closeWay = ref("self");
12582
13621
  const lineDistance = ref(20);
13622
+ onMounted(() => {
13623
+ customPlaceholder();
13624
+ });
13625
+ const initCustomSelected = () => {
13626
+ if (props.modelValue.length > 0) {
13627
+ tabIndex.value = props.modelValue.length - 1;
13628
+ for (let index = 0; index < props.modelValue.length; index++) {
13629
+ if (regionList[tabName.value[index]].length == 0) {
13630
+ tabIndex.value = index - 1;
13631
+ break;
13632
+ } else {
13633
+ const val = props.modelValue[index];
13634
+ const arr = regionList[tabName.value[index]];
13635
+ if (privateType.value == "custom") {
13636
+ selectedRegion[tabName.value[index]] = arr.filter((item) => item.id == val)[0];
13637
+ } else if (privateType.value == "custom2") {
13638
+ let sumArr = [];
13639
+ arr.map((item) => {
13640
+ sumArr.push(...item.list);
13641
+ });
13642
+ selectedRegion[tabName.value[index]] = sumArr.filter((item) => item.id == val)[0];
13643
+ }
13644
+ }
13645
+ }
13646
+ lineAnimation();
13647
+ }
13648
+ };
13649
+ const customPlaceholder = () => {
13650
+ let typeD = Object.prototype.toString.call(props.columnsPlaceholder);
13651
+ if (typeD == "[object String]") {
13652
+ tabNameDefault.value = new Array(4).fill(props.columnsPlaceholder);
13653
+ } else if (typeD == "[object Array]") {
13654
+ tabNameDefault.value = new Array(4).fill("");
13655
+ tabNameDefault.value.forEach((val, index) => {
13656
+ if (props.columnsPlaceholder[index]) {
13657
+ tabNameDefault.value[index] = props.columnsPlaceholder[index];
13658
+ } else {
13659
+ tabNameDefault.value[index] = "\u8BF7\u9009\u62E9";
13660
+ }
13661
+ });
13662
+ }
13663
+ };
12583
13664
  const getTabName = (item, index) => {
12584
13665
  if (item.name)
12585
13666
  return item.name;
12586
13667
  if (tabIndex.value < index) {
12587
13668
  return item.name;
12588
13669
  } else {
12589
- return "\u8BF7\u9009\u62E9";
13670
+ return tabNameDefault.value[index];
12590
13671
  }
12591
13672
  };
12592
13673
  const handClose = (type = "self") => {
@@ -12599,7 +13680,6 @@ const _sfc_main$c = create$c({
12599
13680
  closeWay.value = "mask";
12600
13681
  };
12601
13682
  const lineAnimation = () => {
12602
- console.log("\u6ED1\u52A8\u7EA2\u7EBF");
12603
13683
  nextTick(() => {
12604
13684
  const name = tabRegion.value && tabRegion.value.getElementsByClassName("active")[0];
12605
13685
  if (name) {
@@ -12615,7 +13695,7 @@ const _sfc_main$c = create$c({
12615
13695
  custom: tabName.value[tabIndex.value]
12616
13696
  };
12617
13697
  selectedRegion[tabName.value[tabIndex.value]] = item;
12618
- for (let i = tabIndex.value; i < tabIndex.value - 1; i++) {
13698
+ for (let i = tabIndex.value; i < 4; i++) {
12619
13699
  selectedRegion[tabName.value[i + 1]] = {};
12620
13700
  }
12621
13701
  if (tabIndex.value < 3) {
@@ -12626,6 +13706,7 @@ const _sfc_main$c = create$c({
12626
13706
  emit("change", calBack);
12627
13707
  } else {
12628
13708
  handClose();
13709
+ emit("update:modelValue");
12629
13710
  }
12630
13711
  };
12631
13712
  const changeRegionTab = (item, key, index) => {
@@ -12708,6 +13789,8 @@ const _sfc_main$c = create$c({
12708
13789
  watch(() => showPopup.value, (value) => {
12709
13790
  if (value == false) {
12710
13791
  close();
13792
+ } else {
13793
+ initCustomSelected();
12711
13794
  }
12712
13795
  });
12713
13796
  watch(() => props.province, (value) => {
@@ -12817,7 +13900,7 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
12817
13900
  name: _ctx.backBtnIcon,
12818
13901
  color: "#cccccc"
12819
13902
  }, null, 8, ["name"]), [
12820
- [vShow, _ctx.privateType == "custom" && _ctx.backBtnIcon]
13903
+ [vShow, _ctx.type == "exist" && _ctx.privateType == "custom" && _ctx.backBtnIcon]
12821
13904
  ])
12822
13905
  ]),
12823
13906
  createElementVNode("view", _hoisted_3$9, toDisplayString(_ctx.privateType == "custom" ? _ctx.customAddressTitle : _ctx.existAddressTitle), 1),
@@ -13227,6 +14310,10 @@ const _sfc_main$9 = create$9({
13227
14310
  default: () => {
13228
14311
  return [];
13229
14312
  }
14313
+ },
14314
+ isWrapTeleport: {
14315
+ type: Boolean,
14316
+ default: false
13230
14317
  }
13231
14318
  },
13232
14319
  emits: ["update:visible", "select"],
@@ -13269,6 +14356,7 @@ function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
13269
14356
  position: "bottom",
13270
14357
  closeable: "",
13271
14358
  round: "",
14359
+ isWrapTeleport: _ctx.isWrapTeleport,
13272
14360
  visible: _ctx.visible,
13273
14361
  style: normalizeStyle(_ctx.popStyle),
13274
14362
  onClickOverlay: _ctx.close,
@@ -13292,7 +14380,7 @@ function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
13292
14380
  ], 2)
13293
14381
  ]),
13294
14382
  _: 3
13295
- }, 8, ["visible", "style", "onClickOverlay", "onClickCloseIcon"]);
14383
+ }, 8, ["isWrapTeleport", "visible", "style", "onClickOverlay", "onClickCloseIcon"]);
13296
14384
  }
13297
14385
  var TimeSelect = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$9]]);
13298
14386
  const { componentName: componentName$7, create: create$8 } = createComponent("timepannel");
@@ -13931,7 +15019,6 @@ const _sfc_main$1 = create$1({
13931
15019
  }
13932
15020
  },
13933
15021
  setup(props, { emit, slots }) {
13934
- console.log(slots["origin"]);
13935
15022
  const isHaveSlot = (slot) => {
13936
15023
  return slots[slot];
13937
15024
  };
@@ -13999,7 +15086,7 @@ var RenderColumn = {
13999
15086
  return () => h(`view`, {}, props.slots());
14000
15087
  },
14001
15088
  props: {
14002
- slots: Object
15089
+ slots: Function
14003
15090
  }
14004
15091
  };
14005
15092
  const component = (componentName2) => {
@@ -14164,7 +15251,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
14164
15251
  }
14165
15252
  var Table = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
14166
15253
  function install(app) {
14167
- const packages = [Avatar, Button, Cell, CellGroup, _sfc_main$1o, Price, OverLay, Divider, _sfc_main$1h, Col, Row, _ImagePreview, Swipe, ActionSheet, BackTop, Collapse, CollapseItem, Drag, _Dialog, InfiniteLoading, NotifyFunction, Range, Video, Popup, _sfc_main$$, Step, Swiper, SwiperItem, Switch, ToastFunction, Progress, CircleProgress, NoticeBar, SearchBar, Empty, 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, Picker, ShortPassword, TextArea, Uploader, CountUp, NumberKeyboard, CountDown, Badge, Tag, Popover, Form, FormItem, Skeleton, Cascader, Address, Barrage, Signature, TimeSelect, TimePannel, TimeDetail, Sku, Card, Table];
15254
+ 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];
14168
15255
  packages.forEach((item) => {
14169
15256
  if (item.install) {
14170
15257
  app.use(item);
@@ -14173,6 +15260,6 @@ function install(app) {
14173
15260
  }
14174
15261
  });
14175
15262
  }
14176
- const version = "3.1.16";
15263
+ const version = "3.1.18-beta.0";
14177
15264
  var nutui_vue_build = { install, version };
14178
- export { ActionSheet, Address, Avatar, BackTop, Badge, Barrage, Button, Calendar, Card, Cascader, Cell, CellGroup, _sfc_main$A as Checkbox, _sfc_main$z as CheckboxGroup, CircleProgress, Col, Collapse, CollapseItem, CountDown, CountUp, DatePicker, _Dialog as Dialog, Divider, Drag, Elevator, Empty, FixedNav, Form, FormItem, _sfc_main$H as Grid, GridItem, _sfc_main$1o as Icon, _ImagePreview as ImagePreview, Indicator, InfiniteLoading, Input, InputNumber, _sfc_main$1h as Layout, Menu, MenuItem, Navbar, NoticeBar, NotifyFunction as Notify, NumberKeyboard, OverLay, Pagination, Picker, Popover, Popup, Price, Progress, _sfc_main$t as Radio, _sfc_main$s as RadioGroup, Range, Rate, Row, SearchBar, ShortPassword, SideNavBar, SideNavBarItem, Signature, Skeleton, Sku, Step, _sfc_main$$ as Steps, SubSideNavBar, Swipe, Swiper, SwiperItem, Switch, TabPane, Tabbar, TabbarItem, Table, Tabs, Tag, TextArea, TimeDetail, TimePannel, TimeSelect, ToastFunction as Toast, Uploader, Video, nutui_vue_build as default, install, version };
15265
+ export { ActionSheet, Address, Audio, AudioOperate, Avatar, BackTop, Badge, Barrage, Button, Calendar, CalendarItem, Card, Cascader, Cell, CellGroup, _sfc_main$A as Checkbox, _sfc_main$z as CheckboxGroup, CircleProgress, Col, Collapse, CollapseItem, CountDown, CountUp, DatePicker, _Dialog as Dialog, Divider, Drag, Elevator, Empty, FixedNav, Form, FormItem, _sfc_main$H as Grid, GridItem, _sfc_main$1s as Icon, _ImagePreview as ImagePreview, Indicator, InfiniteLoading, Input, InputNumber, _sfc_main$1l as Layout, Menu, MenuItem, Navbar, NoticeBar, NotifyFunction as Notify, NumberKeyboard, OverLay, Pagination, Picker, Popover, Popup, Price, Progress, PullRefresh, _sfc_main$t as Radio, _sfc_main$s as RadioGroup, Range, Rate, Row, SearchBar, ShortPassword, SideNavBar, SideNavBarItem, Signature, Skeleton, Sku, Step, _sfc_main$11 as Steps, _sfc_main$1d as Sticky, SubSideNavBar, Swipe, Swiper, SwiperItem, Switch, TabPane, Tabbar, TabbarItem, Table, Tabs, Tag, TextArea, TimeDetail, TimePannel, TimeSelect, ToastFunction as Toast, Uploader, Video, nutui_vue_build as default, install, version };