@nutui/nutui 3.1.23-beta.6 → 3.2.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 (213) hide show
  1. package/CHANGELOG.md +41 -1
  2. package/dist/nutui.es.js +275 -257
  3. package/dist/nutui.umd.js +275 -257
  4. package/dist/packages/_es/ActionSheet.js +4 -22
  5. package/dist/packages/_es/Address.js +12 -29
  6. package/dist/packages/_es/AddressList.js +2 -2
  7. package/dist/packages/_es/Animate.js +2 -21
  8. package/dist/packages/_es/Audio.js +33 -65
  9. package/dist/packages/_es/AudioOperate.js +2 -21
  10. package/dist/packages/_es/Avatar.js +5 -20
  11. package/dist/packages/_es/AvatarGroup.js +1 -1
  12. package/dist/packages/_es/BackTop.js +1 -1
  13. package/dist/packages/_es/Badge.js +1 -1
  14. package/dist/packages/_es/Barrage.js +1 -1
  15. package/dist/packages/_es/Button.js +1 -1
  16. package/dist/packages/_es/Calendar.js +1 -1
  17. package/dist/packages/_es/CalendarItem.js +1 -1
  18. package/dist/packages/_es/Card.js +1 -1
  19. package/dist/packages/_es/Cascader.js +19 -46
  20. package/dist/packages/_es/Category.js +1 -1
  21. package/dist/packages/_es/CategoryPane.js +1 -1
  22. package/dist/packages/_es/Cell.js +1 -1
  23. package/dist/packages/_es/CellGroup.js +1 -1
  24. package/dist/packages/_es/Checkbox.js +1 -1
  25. package/dist/packages/_es/CheckboxGroup.js +1 -1
  26. package/dist/packages/_es/CircleProgress.js +1 -1
  27. package/dist/packages/_es/Col.js +1 -1
  28. package/dist/packages/_es/Collapse.js +2 -2
  29. package/dist/packages/_es/CollapseItem.js +7 -24
  30. package/dist/packages/_es/Comment.js +1 -1
  31. package/dist/packages/_es/ConfigProvider.js +1 -1
  32. package/dist/packages/_es/CountDown.js +5 -23
  33. package/dist/packages/_es/CountUp.js +5 -22
  34. package/dist/packages/_es/DatePicker.js +7 -24
  35. package/dist/packages/_es/Dialog.js +4 -22
  36. package/dist/packages/_es/Divider.js +7 -24
  37. package/dist/packages/_es/Drag.js +1 -1
  38. package/dist/packages/_es/Ecard.js +1 -1
  39. package/dist/packages/_es/Elevator.js +5 -24
  40. package/dist/packages/_es/Ellipsis.js +2 -21
  41. package/dist/packages/_es/Empty.js +1 -1
  42. package/dist/packages/_es/FixedNav.js +1 -1
  43. package/dist/packages/_es/Form.js +1 -1
  44. package/dist/packages/_es/FormItem.js +1 -1
  45. package/dist/packages/_es/Grid.js +1 -1
  46. package/dist/packages/_es/GridItem.js +1 -1
  47. package/dist/packages/_es/Icon.js +1 -1
  48. package/dist/packages/_es/Image.js +2 -21
  49. package/dist/packages/_es/ImagePreview.js +8 -26
  50. package/dist/packages/_es/Indicator.js +1 -1
  51. package/dist/packages/_es/InfiniteLoading.js +5 -24
  52. package/dist/packages/_es/Input.js +1 -1
  53. package/dist/packages/_es/InputNumber.js +1 -1
  54. package/dist/packages/_es/Layout.js +1 -1
  55. package/dist/packages/_es/List.js +4 -22
  56. package/dist/packages/_es/Menu.js +2 -2
  57. package/dist/packages/_es/MenuItem.js +2 -21
  58. package/dist/packages/_es/Navbar.js +1 -1
  59. package/dist/packages/_es/NoticeBar.js +6 -23
  60. package/dist/packages/_es/Notify.js +9 -28
  61. package/dist/packages/_es/NumberKeyboard.js +1 -1
  62. package/dist/packages/_es/OldPicker.js +12 -28
  63. package/dist/packages/_es/OverLay.js +5 -20
  64. package/dist/packages/_es/Pagination.js +1 -1
  65. package/dist/packages/_es/Picker.js +12 -28
  66. package/dist/packages/_es/Popover.js +4 -22
  67. package/dist/packages/_es/Popup.js +14 -28
  68. package/dist/packages/_es/Price.js +1 -1
  69. package/dist/packages/_es/Progress.js +1 -1
  70. package/dist/packages/_es/PullRefresh.js +5 -20
  71. package/dist/packages/_es/Radio.js +1 -1
  72. package/dist/packages/_es/RadioGroup.js +1 -1
  73. package/dist/packages/_es/Range.js +5 -24
  74. package/dist/packages/_es/Rate.js +5 -24
  75. package/dist/packages/_es/Row.js +1 -1
  76. package/dist/packages/_es/SearchBar.js +5 -24
  77. package/dist/packages/_es/ShortPassword.js +1 -1
  78. package/dist/packages/_es/SideNavBar.js +4 -22
  79. package/dist/packages/_es/SideNavBarItem.js +1 -1
  80. package/dist/packages/_es/Signature.js +15 -23
  81. package/dist/packages/_es/Skeleton.js +1 -1
  82. package/dist/packages/_es/Sku.js +4 -22
  83. package/dist/packages/_es/Step.js +4 -22
  84. package/dist/packages/_es/Steps.js +1 -1
  85. package/dist/packages/_es/Sticky.js +1 -1
  86. package/dist/packages/_es/SubSideNavBar.js +4 -22
  87. package/dist/packages/_es/Swipe.js +5 -24
  88. package/dist/packages/_es/Swiper.js +1 -1
  89. package/dist/packages/_es/SwiperItem.js +1 -1
  90. package/dist/packages/_es/Switch.js +1 -1
  91. package/dist/packages/_es/TabPane.js +1 -1
  92. package/dist/packages/_es/Tabbar.js +1 -1
  93. package/dist/packages/_es/TabbarItem.js +1 -1
  94. package/dist/packages/_es/Table.js +4 -22
  95. package/dist/packages/_es/Tabs.js +5 -20
  96. package/dist/packages/_es/Tag.js +1 -1
  97. package/dist/packages/_es/TextArea.js +1 -1
  98. package/dist/packages/_es/TimeDetail.js +5 -24
  99. package/dist/packages/_es/TimePannel.js +4 -22
  100. package/dist/packages/_es/TimeSelect.js +1 -1
  101. package/dist/packages/_es/Toast.js +12 -31
  102. package/dist/packages/_es/Uploader.js +12 -22
  103. package/dist/packages/_es/Video.js +6 -24
  104. package/dist/packages/_es/WaterMark.js +2 -21
  105. package/dist/packages/_es/common.js +2 -2
  106. package/dist/packages/_es/component.js +5 -5
  107. package/dist/packages/_es/index.js +1 -1
  108. package/dist/packages/_es/index2.js +1 -1
  109. package/dist/packages/_es/index3.js +1 -1
  110. package/dist/packages/_es/index4.js +1 -1
  111. package/dist/packages/_es/index5.js +6 -24
  112. package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
  113. package/dist/packages/_es/pxCheck.js +1 -1
  114. package/dist/packages/_es/raf.js +1 -1
  115. package/dist/packages/actionsheet/index.scss +17 -0
  116. package/dist/packages/address/index.scss +60 -0
  117. package/dist/packages/audio/index.scss +8 -0
  118. package/dist/packages/barrage/index.scss +7 -0
  119. package/dist/packages/card/index.scss +8 -1
  120. package/dist/packages/circleprogress/index.scss +6 -0
  121. package/dist/packages/collapseitem/index.scss +21 -0
  122. package/dist/packages/comment/index.scss +37 -0
  123. package/dist/packages/countup/index.scss +24 -3
  124. package/dist/packages/ecard/index.scss +31 -1
  125. package/dist/packages/elevator/index.scss +16 -0
  126. package/dist/packages/empty/index.scss +6 -0
  127. package/dist/packages/image/index.scss +12 -0
  128. package/dist/packages/infiniteloading/index.scss +18 -0
  129. package/dist/packages/locale/lang/baseLang.js +1 -1
  130. package/dist/packages/locale/lang/en-US.js +1 -1
  131. package/dist/packages/locale/lang/id-ID.js +1 -1
  132. package/dist/packages/locale/lang/index.js +1 -1
  133. package/dist/packages/locale/lang/zh-CN.js +1 -1
  134. package/dist/packages/locale/lang/zh-TW.js +1 -1
  135. package/dist/packages/noticebar/index.scss +13 -0
  136. package/dist/packages/numberkeyboard/index.scss +10 -0
  137. package/dist/packages/picker/index.scss +33 -0
  138. package/dist/packages/popup/index.scss +10 -0
  139. package/dist/packages/shortpassword/index.scss +20 -0
  140. package/dist/packages/sidenavbaritem/index.scss +9 -0
  141. package/dist/packages/sku/index.scss +40 -0
  142. package/dist/packages/subsidenavbar/index.scss +12 -0
  143. package/dist/smartips/attributes.json +5 -1
  144. package/dist/smartips/tags.json +2 -1
  145. package/dist/smartips/web-types.json +11 -2
  146. package/dist/style.css +1 -1
  147. package/dist/styles/themes/default.scss +52 -52
  148. package/dist/styles/themes/jdb.scss +52 -52
  149. package/dist/styles/themes/jdt.scss +52 -52
  150. package/dist/styles/variables-jdb.scss +6 -0
  151. package/dist/styles/variables-jdt.scss +6 -0
  152. package/dist/styles/variables.scss +6 -0
  153. package/dist/types/__VUE/actionsheet/index.vue.d.ts +1 -1
  154. package/dist/types/__VUE/address/index.vue.d.ts +2 -2
  155. package/dist/types/__VUE/addresslist/index.vue.d.ts +1 -1
  156. package/dist/types/__VUE/audio/index.vue.d.ts +4 -1
  157. package/dist/types/__VUE/audiooperate/index.vue.d.ts +1 -1
  158. package/dist/types/__VUE/avatargroup/index.vue.d.ts +1 -1
  159. package/dist/types/__VUE/backtop/index.vue.d.ts +3 -3
  160. package/dist/types/__VUE/calendaritem/index.vue.d.ts +1 -1
  161. package/dist/types/__VUE/cascader/index.vue.d.ts +1 -1
  162. package/dist/types/__VUE/categorypane/index.vue.d.ts +1 -1
  163. package/dist/types/__VUE/cell/index.vue.d.ts +2 -2
  164. package/dist/types/__VUE/cellgroup/index.vue.d.ts +1 -1
  165. package/dist/types/__VUE/checkboxgroup/index.vue.d.ts +1 -1
  166. package/dist/types/__VUE/circleprogress/index.vue.d.ts +1 -1
  167. package/dist/types/__VUE/collapse/index.vue.d.ts +2 -2
  168. package/dist/types/__VUE/collapseitem/index.vue.d.ts +1 -1
  169. package/dist/types/__VUE/configprovider/index.vue.d.ts +1 -1
  170. package/dist/types/__VUE/countdown/index.vue.d.ts +1 -1
  171. package/dist/types/__VUE/countup/index.vue.d.ts +1 -1
  172. package/dist/types/__VUE/datepicker/index.vue.d.ts +1 -1
  173. package/dist/types/__VUE/divider/index.vue.d.ts +2 -2
  174. package/dist/types/__VUE/fixednav/index.vue.d.ts +1 -1
  175. package/dist/types/__VUE/formitem/index.vue.d.ts +1 -1
  176. package/dist/types/__VUE/grid/index.vue.d.ts +1 -1
  177. package/dist/types/__VUE/griditem/index.vue.d.ts +2 -2
  178. package/dist/types/__VUE/imagepreview/imagePreviewItem.vue.d.ts +1 -1
  179. package/dist/types/__VUE/imagepreview/index.vue.d.ts +1 -1
  180. package/dist/types/__VUE/infiniteloading/index.vue.d.ts +1 -1
  181. package/dist/types/__VUE/inputnumber/index.vue.d.ts +1 -1
  182. package/dist/types/__VUE/menuitem/index.vue.d.ts +1 -1
  183. package/dist/types/__VUE/noticebar/index.vue.d.ts +1 -1
  184. package/dist/types/__VUE/numberkeyboard/index.vue.d.ts +1 -1
  185. package/dist/types/__VUE/oldpicker/Column.vue.d.ts +1 -1
  186. package/dist/types/__VUE/oldpicker/index.vue.d.ts +1 -1
  187. package/dist/types/__VUE/overlay/index.vue.d.ts +1 -1
  188. package/dist/types/__VUE/picker/index.vue.d.ts +13 -13
  189. package/dist/types/__VUE/popover/index.vue.d.ts +2 -2
  190. package/dist/types/__VUE/pullrefresh/index.vue.d.ts +1 -1
  191. package/dist/types/__VUE/radiogroup/index.vue.d.ts +1 -1
  192. package/dist/types/__VUE/range/index.vue.d.ts +1 -1
  193. package/dist/types/__VUE/rate/index.vue.d.ts +2 -2
  194. package/dist/types/__VUE/searchbar/index.vue.d.ts +1 -1
  195. package/dist/types/__VUE/shortpassword/index.vue.d.ts +1 -1
  196. package/dist/types/__VUE/sidenavbar/index.vue.d.ts +1 -1
  197. package/dist/types/__VUE/sidenavbaritem/index.vue.d.ts +1 -1
  198. package/dist/types/__VUE/signature/index.vue.d.ts +5 -2
  199. package/dist/types/__VUE/subsidenavbar/index.vue.d.ts +1 -1
  200. package/dist/types/__VUE/swiperitem/index.vue.d.ts +1 -1
  201. package/dist/types/__VUE/switch/index.vue.d.ts +4 -4
  202. package/dist/types/__VUE/tabbaritem/index.vue.d.ts +1 -1
  203. package/dist/types/__VUE/tabpane/index.vue.d.ts +1 -1
  204. package/dist/types/__VUE/textarea/index.vue.d.ts +1 -1
  205. package/dist/types/__VUE/timedetail/index.vue.d.ts +1 -1
  206. package/dist/types/__VUE/timepannel/index.vue.d.ts +1 -1
  207. package/dist/types/__VUE/timeselect/index.vue.d.ts +1 -1
  208. package/dist/types/__VUE/uploader/index.vue.d.ts +9 -2
  209. package/dist/types/__VUE/uploader/uploader.d.ts +1 -0
  210. package/dist/types/__VUE/watermark/index.vue.d.ts +1 -1
  211. package/dist/types/index.d.ts +1 -1
  212. package/package.json +1 -1
  213. package/dist/packages/index.d.ts +0 -3
@@ -1,24 +1,5 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
1
  /*!
21
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
22
3
  * (c) 2022 @jdf2e.
23
4
  * Released under the MIT License.
24
5
  */
@@ -32,7 +13,8 @@ import "./Icon.js";
32
13
  import "./pxCheck.js";
33
14
  const { componentName, create } = createComponent("actionsheet");
34
15
  const _sfc_main = create({
35
- props: __spreadProps(__spreadValues({}, popupProps), {
16
+ props: {
17
+ ...popupProps,
36
18
  cancelTxt: {
37
19
  type: String,
38
20
  default: ""
@@ -73,7 +55,7 @@ const _sfc_main = create({
73
55
  type: Boolean,
74
56
  default: true
75
57
  }
76
- }),
58
+ },
77
59
  emits: ["cancel", "close", "choose", "update:visible"],
78
60
  setup(props, { emit }) {
79
61
  const slotDefault = !!useSlots().default;
@@ -1,28 +1,9 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
1
  /*!
21
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
22
3
  * (c) 2022 @jdf2e.
23
4
  * Released under the MIT License.
24
5
  */
25
- import { ref, computed, reactive, onMounted, watch, toRefs, nextTick, resolveComponent, openBlock, createBlock, withCtx, createElementVNode, withDirectives, createVNode, vShow, toDisplayString, createCommentVNode, createElementBlock, Fragment, renderList, normalizeClass, normalizeStyle, createTextVNode } from "vue";
6
+ import { ref, computed, reactive, onMounted, watch, toRefs, nextTick, resolveComponent, openBlock, createBlock, withCtx, createElementVNode, withDirectives, createVNode, vShow, toDisplayString, createCommentVNode, createElementBlock, Fragment, renderList, normalizeClass, normalizeStyle, createTextVNode, renderSlot } from "vue";
26
7
  import { c as createComponent } from "./component.js";
27
8
  import { popupProps } from "./Popup.js";
28
9
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
@@ -33,7 +14,8 @@ import "./pxCheck.js";
33
14
  const { componentName, create, translate } = createComponent("address");
34
15
  const _sfc_main = create({
35
16
  inheritAttrs: false,
36
- props: __spreadProps(__spreadValues({}, popupProps), {
17
+ props: {
18
+ ...popupProps,
37
19
  modelValue: {
38
20
  type: Array,
39
21
  default: () => []
@@ -102,7 +84,7 @@ const _sfc_main = create({
102
84
  type: [String, Array],
103
85
  default: ""
104
86
  }
105
- }),
87
+ },
106
88
  emits: ["update:visible", "update:modelValue", "type", "change", "selected", "close", "close-mask", "switch-module"],
107
89
  setup(props, { emit }) {
108
90
  const regionLine = ref(null);
@@ -353,7 +335,7 @@ const _sfc_main = create({
353
335
  }
354
336
  });
355
337
  });
356
- return __spreadProps(__spreadValues({
338
+ return {
357
339
  showPopup,
358
340
  privateType,
359
341
  tabIndex,
@@ -374,10 +356,10 @@ const _sfc_main = create({
374
356
  clickOverlay,
375
357
  handClose,
376
358
  handleElevatorItem,
377
- initCustomSelected
378
- }, toRefs(props)), {
359
+ initCustomSelected,
360
+ ...toRefs(props),
379
361
  translate
380
- });
362
+ };
381
363
  }
382
364
  });
383
365
  const _hoisted_1 = { class: "nut-address" };
@@ -559,10 +541,11 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
559
541
  }, [
560
542
  createElementVNode("div", _hoisted_23, toDisplayString(_ctx.customAndExistTitle || _ctx.translate("chooseAnotherAddress")), 1)
561
543
  ])) : createCommentVNode("", true)
562
- ])) : createCommentVNode("", true)
544
+ ])) : createCommentVNode("", true),
545
+ renderSlot(_ctx.$slots, "bottom")
563
546
  ])
564
547
  ]),
565
- _: 1
548
+ _: 3
566
549
  }, 8, ["lock-scroll", "onClose", "onClickOverlay", "visible", "isWrapTeleport", "teleport"]);
567
550
  }
568
551
  var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -476,7 +476,7 @@ const _sfc_main = create({
476
476
  });
477
477
  const trowelData = () => {
478
478
  console.log("props.data", props.data);
479
- if (Object.keys(props.dataMapOptions).length > 0 && props.data.length > 0) {
479
+ if (Object.keys(props.dataMapOptions).length > 0) {
480
480
  dataArray.value = props.data.map((item, index2) => {
481
481
  return floatData(dataInfo, item, props.dataMapOptions);
482
482
  });
@@ -1,24 +1,5 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
1
  /*!
21
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
22
3
  * (c) 2022 @jdf2e.
23
4
  * Released under the MIT License.
24
5
  */
@@ -65,7 +46,7 @@ const _sfc_main = create({
65
46
  }
66
47
  emit("click", event);
67
48
  };
68
- return __spreadProps(__spreadValues({}, toRefs(state)), { classes, handleClick });
49
+ return { ...toRefs(state), classes, handleClick };
69
50
  }
70
51
  });
71
52
  const _hoisted_1 = { class: "nut-animate" };
@@ -1,24 +1,5 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
1
  /*!
21
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
22
3
  * (c) 2022 @jdf2e.
23
4
  * Released under the MIT License.
24
5
  */
@@ -59,7 +40,7 @@ const _sfc_main = create({
59
40
  }
60
41
  },
61
42
  components: {},
62
- emits: ["fastBack", "play", "forward", "ended", "changeProgress", "mute"],
43
+ emits: ["fastBack", "play", "forward", "ended", "changeProgress", "mute", "can-play"],
63
44
  setup(props, { emit }) {
64
45
  const audioRef = ref(null);
65
46
  const audioData = reactive({
@@ -91,22 +72,25 @@ const _sfc_main = create({
91
72
  } catch (e) {
92
73
  console.log(e.message);
93
74
  }
94
- setTimeout(() => {
95
- const audioR = audioRef.value;
96
- if (props.autoplay) {
97
- if (audioR && audioR.paused) {
98
- audioR.play();
99
- }
100
- }
101
- audioData.second = audioR.duration;
102
- audioData.duration = formatSeconds(audioR.duration);
103
- }, 500);
104
75
  });
76
+ const onCanplay = (e) => {
77
+ const audioR = audioRef.value;
78
+ if (props.autoplay) {
79
+ if (audioR && audioR.paused) {
80
+ audioR.play();
81
+ }
82
+ }
83
+ audioData.second = audioR.duration;
84
+ audioData.duration = formatSeconds(audioR.duration);
85
+ emit("can-play", e);
86
+ };
105
87
  const onTimeupdate = (e) => {
106
88
  audioData.currentTime = parseInt(e.target.currentTime);
107
89
  };
108
90
  const fastBack = () => {
109
- audioData.currentTime--;
91
+ if (audioData.currentTime > 0) {
92
+ audioData.currentTime--;
93
+ }
110
94
  audioRef.value.currentTime = audioData.currentTime;
111
95
  emit("fastBack", audioData.currentTime);
112
96
  };
@@ -145,37 +129,17 @@ const _sfc_main = create({
145
129
  emit("mute", audioData.hanMuted);
146
130
  };
147
131
  const formatSeconds = (value) => {
148
- let theTime = parseInt(value);
149
- let theTime1 = 0;
150
- let theTime2 = 0;
151
- if (theTime > 60) {
152
- theTime1 = Math.floor(theTime / 60);
153
- theTime = Math.floor(theTime % 60);
154
- if (theTime1 > 60) {
155
- theTime2 = Math.floor(theTime1 / 60);
156
- theTime1 = Math.floor(theTime1 % 60);
157
- }
132
+ if (!value) {
133
+ return "00:00:00";
158
134
  }
135
+ let time = parseInt(value);
136
+ let hours = Math.floor(time / 3600);
137
+ let minutes = Math.floor((time - hours * 3600) / 60);
138
+ let seconds = time - hours * 3600 - minutes * 60;
159
139
  let result = "";
160
- if (theTime < 10) {
161
- result = "0" + result;
162
- }
163
- if (theTime1 > 0) {
164
- result = "" + theTime1 + ":" + result;
165
- if (theTime1 < 10) {
166
- result = "0" + result;
167
- }
168
- } else {
169
- result = "00:" + result;
170
- }
171
- if (theTime2 > 0) {
172
- result = "" + theTime2 + ":" + result;
173
- if (theTime2 < 10) {
174
- result = "0" + result;
175
- }
176
- } else {
177
- result = "00:" + result;
178
- }
140
+ result += ("0" + hours.toString()).slice(-2) + ":";
141
+ result += ("0" + minutes.toString()).slice(-2) + ":";
142
+ result += ("0" + seconds.toString()).slice(-2);
179
143
  return result;
180
144
  };
181
145
  watch(() => audioData.currentTime, (value) => {
@@ -190,7 +154,9 @@ const _sfc_main = create({
190
154
  fastBack,
191
155
  changeStatus
192
156
  });
193
- return __spreadProps(__spreadValues(__spreadValues({}, toRefs(props)), toRefs(audioData)), {
157
+ return {
158
+ ...toRefs(props),
159
+ ...toRefs(audioData),
194
160
  audioRef,
195
161
  fastBack,
196
162
  forward,
@@ -198,8 +164,9 @@ const _sfc_main = create({
198
164
  progressChange,
199
165
  audioEnd,
200
166
  onTimeupdate,
201
- handleMute
202
- });
167
+ handleMute,
168
+ onCanplay
169
+ };
203
170
  }
204
171
  });
205
172
  const _hoisted_1 = { class: "nut-audio" };
@@ -271,7 +238,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
271
238
  autoplay: _ctx.autoplay,
272
239
  loop: _ctx.loop,
273
240
  onTimeupdate: _cache[3] || (_cache[3] = (...args) => _ctx.onTimeupdate && _ctx.onTimeupdate(...args)),
274
- onEnded: _cache[4] || (_cache[4] = (...args) => _ctx.audioEnd && _ctx.audioEnd(...args)),
241
+ onCanplay: _cache[4] || (_cache[4] = (...args) => _ctx.onCanplay && _ctx.onCanplay(...args)),
242
+ onEnded: _cache[5] || (_cache[5] = (...args) => _ctx.audioEnd && _ctx.audioEnd(...args)),
275
243
  muted: _ctx.hanMuted
276
244
  }, null, 40, _hoisted_8)
277
245
  ]);
@@ -1,24 +1,5 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
1
  /*!
21
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
22
3
  * (c) 2022 @jdf2e.
23
4
  * Released under the MIT License.
24
5
  */
@@ -42,7 +23,7 @@ const _sfc_main = create({
42
23
  const audio = inject("audioParent");
43
24
  const parent = reactive(audio);
44
25
  const customSlot = ref(useSlots().default);
45
- return __spreadProps(__spreadValues(__spreadValues({}, toRefs(props)), toRefs(parent)), { customSlot, translate });
26
+ return { ...toRefs(props), ...toRefs(parent), customSlot, translate };
46
27
  }
47
28
  });
48
29
  const _hoisted_1 = { class: "nut-audio-operate" };
@@ -1,21 +1,5 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3
- var __hasOwnProp = Object.prototype.hasOwnProperty;
4
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
5
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6
- var __spreadValues = (a, b) => {
7
- for (var prop in b || (b = {}))
8
- if (__hasOwnProp.call(b, prop))
9
- __defNormalProp(a, prop, b[prop]);
10
- if (__getOwnPropSymbols)
11
- for (var prop of __getOwnPropSymbols(b)) {
12
- if (__propIsEnum.call(b, prop))
13
- __defNormalProp(a, prop, b[prop]);
14
- }
15
- return a;
16
- };
17
1
  /*!
18
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
19
3
  * (c) 2022 @jdf2e.
20
4
  * Released under the MIT License.
21
5
  */
@@ -128,7 +112,7 @@ const _sfc_main = create({
128
112
  const onError = (event) => {
129
113
  emit("onError", event);
130
114
  };
131
- return __spreadValues({
115
+ return {
132
116
  classes,
133
117
  styles,
134
118
  iconStyles,
@@ -138,8 +122,9 @@ const _sfc_main = create({
138
122
  onError,
139
123
  avatarGroup,
140
124
  visible,
141
- avatarRef
142
- }, toRefs(state));
125
+ avatarRef,
126
+ ...toRefs(state)
127
+ };
143
128
  }
144
129
  });
145
130
  const _hoisted_1 = ["src", "alt"];
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,37 +1,5 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
- var __restKey = (key) => typeof key === "symbol" ? key : key + "";
21
- var __objRest = (source, exclude) => {
22
- var target = {};
23
- for (var prop in source)
24
- if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
25
- target[prop] = source[prop];
26
- if (source != null && __getOwnPropSymbols)
27
- for (var prop of __getOwnPropSymbols(source)) {
28
- if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
29
- target[prop] = source[prop];
30
- }
31
- return target;
32
- };
33
1
  /*!
34
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
35
3
  * (c) 2022 @jdf2e.
36
4
  * Released under the MIT License.
37
5
  */
@@ -45,16 +13,16 @@ import "./Icon.js";
45
13
  import "./pxCheck.js";
46
14
  const formatTree = (tree, parent, config) => tree.map((node) => {
47
15
  const { value: valueKey = "value", text: textKey = "text", children: childrenKey = "children" } = config;
48
- const _a = node, { [valueKey]: value, [textKey]: text, [childrenKey]: children } = _a, others = __objRest(_a, [__restKey(valueKey), __restKey(textKey), __restKey(childrenKey)]);
49
- const newNode = __spreadProps(__spreadValues({
50
- loading: false
51
- }, others), {
16
+ const { [valueKey]: value, [textKey]: text, [childrenKey]: children, ...others } = node;
17
+ const newNode = {
18
+ loading: false,
19
+ ...others,
52
20
  level: parent ? (parent && parent.level || 0) + 1 : 0,
53
21
  value,
54
22
  text,
55
23
  children,
56
24
  _parent: parent
57
- });
25
+ };
58
26
  if (newNode.children && newNode.children.length) {
59
27
  newNode.children = formatTree(newNode.children, newNode, config);
60
28
  }
@@ -79,12 +47,15 @@ const defaultConvertConfig = {
79
47
  sortKey: ""
80
48
  };
81
49
  const convertListToOptions = (list, options) => {
82
- const mergedOptions = __spreadValues(__spreadValues({}, defaultConvertConfig), options || {});
50
+ const mergedOptions = {
51
+ ...defaultConvertConfig,
52
+ ...options || {}
53
+ };
83
54
  const { topId, idKey, pidKey, sortKey } = mergedOptions;
84
55
  let result = [];
85
56
  let map = {};
86
57
  list.forEach((node) => {
87
- node = __spreadValues({}, node);
58
+ node = { ...node };
88
59
  const { [idKey]: id, [pidKey]: pid } = node;
89
60
  const children = map[pid] = map[pid] || [];
90
61
  if (!result.length && pid === topId) {
@@ -105,11 +76,12 @@ const convertListToOptions = (list, options) => {
105
76
  };
106
77
  class Tree {
107
78
  constructor(nodes, config) {
108
- this.config = __spreadValues({
79
+ this.config = {
109
80
  value: "value",
110
81
  text: "text",
111
- children: "children"
112
- }, config || {});
82
+ children: "children",
83
+ ...config || {}
84
+ };
113
85
  this.nodes = formatTree(nodes, null, this.config);
114
86
  }
115
87
  updateChildren(nodes, parent) {
@@ -374,7 +346,7 @@ const _sfc_main$1 = create$1({
374
346
  syncValue();
375
347
  }
376
348
  });
377
- return __spreadValues({ panes, initLoading, tabsCursor }, methods);
349
+ return { panes, initLoading, tabsCursor, ...methods };
378
350
  }
379
351
  });
380
352
  const _hoisted_1$1 = {
@@ -447,7 +419,8 @@ const _sfc_main = create({
447
419
  components: {
448
420
  [CascaderItem.name]: CascaderItem
449
421
  },
450
- props: __spreadProps(__spreadValues({}, popupProps), {
422
+ props: {
423
+ ...popupProps,
451
424
  modelValue: Array,
452
425
  visible: Boolean,
453
426
  title: String,
@@ -470,7 +443,7 @@ const _sfc_main = create({
470
443
  default: "children"
471
444
  },
472
445
  convertConfig: Object
473
- }),
446
+ },
474
447
  emits: ["update:modelValue", "change", "pathChange", "update:visible"],
475
448
  setup(props, { emit }) {
476
449
  const innerValue = ref(props.modelValue);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.23-beta.6 Thu Jul 28 2022 18:06:31 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.0 Mon Aug 01 2022 21:25:20 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */