@nutui/nutui 3.2.7 → 3.2.8-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 (206) hide show
  1. package/dist/nutui.es.js +1931 -3371
  2. package/dist/nutui.umd.js +1928 -3369
  3. package/dist/packages/_es/ActionSheet.js +2 -5
  4. package/dist/packages/_es/Address.js +162 -250
  5. package/dist/packages/_es/AddressList.js +229 -307
  6. package/dist/packages/_es/Animate.js +1 -1
  7. package/dist/packages/_es/Audio.js +1 -1
  8. package/dist/packages/_es/AudioOperate.js +1 -1
  9. package/dist/packages/_es/Avatar.js +1 -1
  10. package/dist/packages/_es/AvatarGroup.js +1 -1
  11. package/dist/packages/_es/BackTop.js +1 -1
  12. package/dist/packages/_es/Badge.js +1 -1
  13. package/dist/packages/_es/Barrage.js +1 -1
  14. package/dist/packages/_es/Button.js +1 -1
  15. package/dist/packages/_es/Calendar.js +1 -1
  16. package/dist/packages/_es/CalendarItem.js +1 -1
  17. package/dist/packages/_es/Card.js +1 -1
  18. package/dist/packages/_es/Cascader.js +2 -5
  19. package/dist/packages/_es/Category.js +1 -1
  20. package/dist/packages/_es/CategoryPane.js +1 -1
  21. package/dist/packages/_es/Cell.js +1 -1
  22. package/dist/packages/_es/CellGroup.js +1 -1
  23. package/dist/packages/_es/Checkbox.js +1 -1
  24. package/dist/packages/_es/CheckboxGroup.js +1 -1
  25. package/dist/packages/_es/CircleProgress.js +2 -2
  26. package/dist/packages/_es/Col.js +1 -1
  27. package/dist/packages/_es/Collapse.js +4 -11
  28. package/dist/packages/_es/CollapseItem.js +8 -5
  29. package/dist/packages/_es/Comment.js +1 -1
  30. package/dist/packages/_es/ConfigProvider.js +1 -1
  31. package/dist/packages/_es/CountDown.js +2 -10
  32. package/dist/packages/_es/CountUp.js +1 -1
  33. package/dist/packages/_es/DatePicker.js +8 -17
  34. package/dist/packages/_es/Dialog.js +38 -63
  35. package/dist/packages/_es/Divider.js +1 -1
  36. package/dist/packages/_es/Drag.js +1 -1
  37. package/dist/packages/_es/Ecard.js +1 -1
  38. package/dist/packages/_es/Elevator.js +2 -2
  39. package/dist/packages/_es/Ellipsis.js +1 -1
  40. package/dist/packages/_es/Empty.js +1 -1
  41. package/dist/packages/_es/FixedNav.js +1 -1
  42. package/dist/packages/_es/Form.js +39 -31
  43. package/dist/packages/_es/FormItem.js +1 -1
  44. package/dist/packages/_es/Grid.js +2 -2
  45. package/dist/packages/_es/GridItem.js +1 -1
  46. package/dist/packages/_es/Icon.js +1 -1
  47. package/dist/packages/_es/Image.js +1 -1
  48. package/dist/packages/_es/ImagePreview.js +126 -220
  49. package/dist/packages/_es/Indicator.js +4 -4
  50. package/dist/packages/_es/InfiniteLoading.js +1 -1
  51. package/dist/packages/_es/Input.js +107 -123
  52. package/dist/packages/_es/InputNumber.js +1 -1
  53. package/dist/packages/_es/Invoice.js +1 -1
  54. package/dist/packages/_es/Layout.js +1 -1
  55. package/dist/packages/_es/List.js +1 -1
  56. package/dist/packages/_es/Menu.js +14 -1
  57. package/dist/packages/_es/MenuItem.js +10 -7
  58. package/dist/packages/_es/Navbar.js +1 -1
  59. package/dist/packages/_es/NoticeBar.js +1 -1
  60. package/dist/packages/_es/Notify.js +5 -7
  61. package/dist/packages/_es/NumberKeyboard.js +4 -4
  62. package/dist/packages/_es/OverLay.js +60 -63
  63. package/dist/packages/_es/Pagination.js +1 -1
  64. package/dist/packages/_es/Picker.js +25 -50
  65. package/dist/packages/_es/Popover.js +111 -930
  66. package/dist/packages/_es/Popup.js +105 -217
  67. package/dist/packages/_es/Price.js +1 -1
  68. package/dist/packages/_es/Progress.js +1 -1
  69. package/dist/packages/_es/Radio.js +1 -1
  70. package/dist/packages/_es/RadioGroup.js +1 -1
  71. package/dist/packages/_es/Range.js +1 -1
  72. package/dist/packages/_es/Rate.js +1 -1
  73. package/dist/packages/_es/Row.js +1 -1
  74. package/dist/packages/_es/SearchBar.js +1 -1
  75. package/dist/packages/_es/ShortPassword.js +4 -4
  76. package/dist/packages/_es/SideNavBar.js +1 -1
  77. package/dist/packages/_es/SideNavBarItem.js +1 -1
  78. package/dist/packages/_es/Signature.js +1 -1
  79. package/dist/packages/_es/Skeleton.js +1 -1
  80. package/dist/packages/_es/Sku.js +4 -7
  81. package/dist/packages/_es/Step.js +1 -1
  82. package/dist/packages/_es/Steps.js +1 -1
  83. package/dist/packages/_es/Sticky.js +1 -1
  84. package/dist/packages/_es/SubSideNavBar.js +1 -1
  85. package/dist/packages/_es/Swipe.js +1 -1
  86. package/dist/packages/_es/Swiper.js +1 -1
  87. package/dist/packages/_es/SwiperItem.js +1 -1
  88. package/dist/packages/_es/Switch.js +1 -1
  89. package/dist/packages/_es/TabPane.js +1 -1
  90. package/dist/packages/_es/Tabbar.js +1 -1
  91. package/dist/packages/_es/TabbarItem.js +2 -2
  92. package/dist/packages/_es/Table.js +1 -1
  93. package/dist/packages/_es/Tabs.js +2 -2
  94. package/dist/packages/_es/Tag.js +1 -1
  95. package/dist/packages/_es/TextArea.js +1 -1
  96. package/dist/packages/_es/TimeDetail.js +1 -1
  97. package/dist/packages/_es/TimePannel.js +1 -1
  98. package/dist/packages/_es/TimeSelect.js +4 -4
  99. package/dist/packages/_es/Toast.js +5 -6
  100. package/dist/packages/_es/TrendArrow.js +1 -1
  101. package/dist/packages/_es/Uploader.js +2 -2
  102. package/dist/packages/_es/Video.js +1 -1
  103. package/dist/packages/_es/WaterMark.js +1 -1
  104. package/dist/packages/_es/common.js +1 -1
  105. package/dist/packages/_es/component.js +22 -2
  106. package/dist/packages/_es/index.js +1 -1
  107. package/dist/packages/_es/index2.js +1 -1
  108. package/dist/packages/_es/index3.js +1 -1
  109. package/dist/packages/_es/index4.js +1 -1
  110. package/dist/packages/_es/index5.js +1 -1
  111. package/dist/packages/_es/interceptor.js +32 -0
  112. package/dist/packages/_es/mountComponent.js +42 -0
  113. package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
  114. package/dist/packages/_es/props.js +80 -0
  115. package/dist/packages/_es/pxCheck.js +1 -1
  116. package/dist/packages/_es/raf.js +1 -1
  117. package/dist/packages/_es/style.css +1 -1
  118. package/dist/packages/address/index.scss +7 -2
  119. package/dist/packages/addresslist/index.scss +61 -101
  120. package/dist/packages/imagepreview/index.scss +9 -1
  121. package/dist/packages/inputnumber/index.scss +5 -1
  122. package/dist/packages/locale/lang/baseLang.js +1 -1
  123. package/dist/packages/locale/lang/en-US.js +1 -1
  124. package/dist/packages/locale/lang/id-ID.js +1 -1
  125. package/dist/packages/locale/lang/index.js +1 -1
  126. package/dist/packages/locale/lang/zh-CN.js +1 -1
  127. package/dist/packages/locale/lang/zh-TW.js +1 -1
  128. package/dist/packages/menuitem/index.scss +0 -15
  129. package/dist/packages/notify/index.scss +2 -2
  130. package/dist/packages/overlay/index.scss +2 -1
  131. package/dist/packages/picker/index.scss +20 -12
  132. package/dist/packages/popover/index.scss +191 -363
  133. package/dist/packages/popup/index.scss +3 -14
  134. package/dist/smartips/attributes.json +59 -55
  135. package/dist/smartips/tags.json +16 -19
  136. package/dist/smartips/web-types.json +114 -112
  137. package/dist/style.css +1 -1
  138. package/dist/styles/themes/default.scss +51 -52
  139. package/dist/styles/themes/jdb.scss +51 -52
  140. package/dist/styles/themes/jddkh.scss +51 -52
  141. package/dist/styles/themes/jdt.scss +51 -52
  142. package/dist/styles/variables.scss +9 -0
  143. package/dist/types/__VUE/actionsheet/index.vue.d.ts +58 -54
  144. package/dist/types/__VUE/address/index.vue.d.ts +72 -92
  145. package/dist/types/__VUE/addresslist/components/GeneralShell.vue.d.ts +29 -9
  146. package/dist/types/__VUE/addresslist/components/ItemContents.vue.d.ts +4 -13
  147. package/dist/types/__VUE/addresslist/components/SwipeShell.vue.d.ts +9 -9
  148. package/dist/types/__VUE/addresslist/index.vue.d.ts +23 -20
  149. package/dist/types/__VUE/avatar/index.vue.d.ts +2 -2
  150. package/dist/types/__VUE/avatargroup/index.vue.d.ts +1 -1
  151. package/dist/types/__VUE/backtop/index.vue.d.ts +1 -1
  152. package/dist/types/__VUE/badge/index.vue.d.ts +1 -1
  153. package/dist/types/__VUE/button/index.vue.d.ts +1 -1
  154. package/dist/types/__VUE/cascader/index.vue.d.ts +47 -52
  155. package/dist/types/__VUE/cell/index.vue.d.ts +3 -3
  156. package/dist/types/__VUE/collapseitem/index.vue.d.ts +1 -1
  157. package/dist/types/__VUE/countdown/index.vue.d.ts +0 -1
  158. package/dist/types/__VUE/countdown/util.d.ts +0 -1
  159. package/dist/types/__VUE/datepicker/index.vue.d.ts +55 -60
  160. package/dist/types/__VUE/dialog/index.d.ts +0 -3
  161. package/dist/types/__VUE/dialog/index.vue.d.ts +48 -57
  162. package/dist/types/__VUE/form/common.d.ts +4 -2
  163. package/dist/types/__VUE/form/index.vue.d.ts +4 -4
  164. package/dist/types/__VUE/grid/index.vue.d.ts +1 -1
  165. package/dist/types/__VUE/image/index.vue.d.ts +1 -1
  166. package/dist/types/__VUE/imagepreview/imagePreviewItem.vue.d.ts +27 -20
  167. package/dist/types/__VUE/imagepreview/index.d.ts +19 -5
  168. package/dist/types/__VUE/imagepreview/index.vue.d.ts +56 -42
  169. package/dist/types/__VUE/imagepreview/types.d.ts +44 -0
  170. package/dist/types/__VUE/indicator/index.vue.d.ts +1 -0
  171. package/dist/types/__VUE/input/index.vue.d.ts +37 -25
  172. package/dist/types/__VUE/inputnumber/index.vue.d.ts +1 -1
  173. package/dist/types/__VUE/invoice/index.vue.d.ts +1 -1
  174. package/dist/types/__VUE/menuitem/index.vue.d.ts +1 -1
  175. package/dist/types/__VUE/navbar/index.vue.d.ts +1 -1
  176. package/dist/types/__VUE/noticebar/index.vue.d.ts +2 -2
  177. package/dist/types/__VUE/notify/index.vue.d.ts +3 -3
  178. package/dist/types/__VUE/numberkeyboard/index.vue.d.ts +3 -3
  179. package/dist/types/__VUE/overlay/index.vue.d.ts +11 -12
  180. package/dist/types/__VUE/picker/Column.vue.d.ts +0 -2
  181. package/dist/types/__VUE/picker/index.vue.d.ts +56 -63
  182. package/dist/types/__VUE/popover/index.vue.d.ts +37 -140
  183. package/dist/types/__VUE/popup/common.d.ts +103 -0
  184. package/dist/types/__VUE/popup/index.vue.d.ts +55 -1591
  185. package/dist/types/__VUE/popup/props.d.ts +82 -0
  186. package/dist/types/__VUE/rate/index.vue.d.ts +1 -1
  187. package/dist/types/__VUE/searchbar/index.vue.d.ts +1 -1
  188. package/dist/types/__VUE/shortpassword/index.vue.d.ts +4 -4
  189. package/dist/types/__VUE/sku/index.vue.d.ts +56 -61
  190. package/dist/types/__VUE/step/index.vue.d.ts +1 -1
  191. package/dist/types/__VUE/switch/index.vue.d.ts +1 -1
  192. package/dist/types/__VUE/tabbaritem/index.vue.d.ts +1 -1
  193. package/dist/types/__VUE/timeselect/index.vue.d.ts +3 -3
  194. package/dist/types/__VUE/toast/index.vue.d.ts +1 -1
  195. package/dist/types/__VUE/uploader/index.vue.d.ts +1 -1
  196. package/dist/types/__VUE/video/index.vue.d.ts +3 -3
  197. package/dist/types/nutui.d.ts +1 -2
  198. package/package.json +2 -3
  199. package/dist/packages/_es/PullRefresh.js +0 -349
  200. package/dist/packages/pullrefresh/index.scss +0 -71
  201. package/dist/types/__VUE/addresslist/components/LongPressShell.vue.d.ts +0 -47
  202. package/dist/types/__VUE/datepicker/utils.d.ts +0 -5
  203. package/dist/types/__VUE/popup/use-lock-scroll.d.ts +0 -5
  204. package/dist/types/__VUE/pullrefresh/index.vue.d.ts +0 -128
  205. package/dist/types/__VUE/pullrefresh/use-touch.d.ts +0 -20
  206. package/dist/types/__VUE/pullrefresh/util.d.ts +0 -6
@@ -1,9 +1,9 @@
1
1
  /*!
2
- * @nutui/nutui v3.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
6
- import { ref, reactive, computed, watch, onMounted, resolveComponent, openBlock, createElementBlock, normalizeClass, Fragment, normalizeStyle, createElementVNode, toDisplayString, createCommentVNode, renderSlot, createVNode, mergeProps, withDirectives, createBlock, vShow, createTextVNode } from "vue";
6
+ import { ref, reactive, computed, watch, onMounted, h, resolveComponent, openBlock, createElementBlock, normalizeClass, createVNode, mergeProps, createCommentVNode, normalizeStyle, createElementVNode, toDisplayString, renderSlot, createBlock, resolveDynamicComponent, withDirectives, vShow, createTextVNode } from "vue";
7
7
  import { c as createComponent } from "./component.js";
8
8
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
9
9
  import "../locale/lang";
@@ -43,7 +43,7 @@ const _sfc_main = create({
43
43
  default: "text"
44
44
  },
45
45
  modelValue: {
46
- type: [String, Number],
46
+ type: String,
47
47
  default: ""
48
48
  },
49
49
  placeholder: {
@@ -161,6 +161,10 @@ const _sfc_main = create({
161
161
  autofocus: {
162
162
  type: Boolean,
163
163
  default: false
164
+ },
165
+ confirmType: {
166
+ type: String,
167
+ default: "done"
164
168
  }
165
169
  },
166
170
  emits: [
@@ -177,11 +181,15 @@ const _sfc_main = create({
177
181
  setup(props, { emit, slots }) {
178
182
  const active = ref(false);
179
183
  const inputRef = ref();
180
- ref();
181
184
  const getModelValue = () => {
182
185
  var _a;
183
186
  return String((_a = props.modelValue) != null ? _a : "");
184
187
  };
188
+ const renderInput = (type) => {
189
+ return h(type == "textarea" ? "textarea" : "input", {
190
+ style: type == "textarea" ? stylesTextarea : styles
191
+ });
192
+ };
185
193
  const state = reactive({
186
194
  focused: false,
187
195
  validateFailed: false,
@@ -252,7 +260,8 @@ const _sfc_main = create({
252
260
  const input = event.target;
253
261
  let value = input.value;
254
262
  active.value = true;
255
- emit("focus", value, event);
263
+ emit("focus", event);
264
+ emit("update:modelValue", value);
256
265
  };
257
266
  const onBlur = (event) => {
258
267
  if (props.disabled || props.readonly) {
@@ -267,13 +276,13 @@ const _sfc_main = create({
267
276
  value = value.slice(0, Number(props.maxLength));
268
277
  }
269
278
  updateValue(getModelValue(), "onBlur");
270
- emit("blur", value, event);
279
+ emit("blur", event);
280
+ emit("update:modelValue", value);
271
281
  };
272
282
  const clear = (event) => {
283
+ event.stopPropagation();
273
284
  if (props.disabled)
274
285
  return;
275
- emit("update:modelValue", "", event);
276
- emit("change", "", event);
277
286
  emit("clear", "", event);
278
287
  };
279
288
  const resetValidation = () => {
@@ -289,12 +298,14 @@ const _sfc_main = create({
289
298
  emit("click-input", event);
290
299
  };
291
300
  const onClickLeftIcon = (event) => {
301
+ event.stopPropagation();
292
302
  if (props.disabled) {
293
303
  return;
294
304
  }
295
305
  emit("click-left-icon", event);
296
306
  };
297
307
  const onClickRightIcon = (event) => {
308
+ event.stopPropagation();
298
309
  if (props.disabled) {
299
310
  return;
300
311
  }
@@ -315,6 +326,7 @@ const _sfc_main = create({
315
326
  }
316
327
  });
317
328
  return {
329
+ renderInput,
318
330
  inputRef,
319
331
  active,
320
332
  classes,
@@ -332,137 +344,109 @@ const _sfc_main = create({
332
344
  }
333
345
  });
334
346
  const _hoisted_1 = { class: "label-string" };
335
- const _hoisted_2 = { class: "nut-input-value" };
336
- const _hoisted_3 = { class: "label-string" };
337
- const _hoisted_4 = { class: "nut-input-value" };
338
- const _hoisted_5 = { class: "nut-input-inner" };
339
- const _hoisted_6 = { class: "nut-input-box" };
340
- const _hoisted_7 = ["maxlength", "placeholder", "disabled", "readonly", "value", "formatTrigger", "autofocus"];
341
- const _hoisted_8 = ["type", "maxlength", "placeholder", "disabled", "readonly", "value", "formatTrigger", "autofocus"];
342
- const _hoisted_9 = { class: "nut-input-clear-box" };
343
- const _hoisted_10 = {
347
+ const _hoisted_2 = {
348
+ key: 2,
349
+ class: "nut-input-value"
350
+ };
351
+ const _hoisted_3 = {
352
+ key: 3,
353
+ class: "nut-input-value"
354
+ };
355
+ const _hoisted_4 = { class: "nut-input-inner" };
356
+ const _hoisted_5 = { class: "nut-input-box" };
357
+ const _hoisted_6 = { class: "nut-input-clear-box" };
358
+ const _hoisted_7 = {
344
359
  key: 0,
345
360
  class: "nut-input-word-limit"
346
361
  };
347
- const _hoisted_11 = { class: "nut-input-word-num" };
362
+ const _hoisted_8 = { class: "nut-input-word-num" };
348
363
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
349
364
  const _component_nut_icon = resolveComponent("nut-icon");
350
365
  return openBlock(), createElementBlock("view", {
351
366
  class: normalizeClass(_ctx.classes)
352
367
  }, [
353
- _ctx.$slots.input ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
354
- _ctx.label ? (openBlock(), createElementBlock("view", {
355
- key: 0,
356
- class: normalizeClass(["nut-input-label", _ctx.labelClass]),
357
- style: normalizeStyle({
358
- width: `${_ctx.labelWidth}px`,
359
- textAlign: _ctx.labelAlign
360
- })
368
+ _ctx.leftIcon && _ctx.leftIcon.length > 0 ? (openBlock(), createElementBlock("view", {
369
+ key: 0,
370
+ class: "nut-input-left-icon",
371
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.onClickLeftIcon && _ctx.onClickLeftIcon(...args))
372
+ }, [
373
+ createVNode(_component_nut_icon, mergeProps({ name: _ctx.leftIcon }, _ctx.$attrs, { size: _ctx.leftIconSize }), null, 16, ["name", "size"])
374
+ ])) : createCommentVNode("", true),
375
+ _ctx.label ? (openBlock(), createElementBlock("view", {
376
+ key: 1,
377
+ class: normalizeClass(["nut-input-label", _ctx.labelClass]),
378
+ style: normalizeStyle({
379
+ width: `${_ctx.labelWidth}px`,
380
+ textAlign: _ctx.labelAlign
381
+ })
382
+ }, [
383
+ createElementVNode("view", _hoisted_1, toDisplayString(_ctx.label) + " " + toDisplayString(_ctx.colon ? ":" : ""), 1)
384
+ ], 6)) : createCommentVNode("", true),
385
+ _ctx.$slots.input ? (openBlock(), createElementBlock("view", _hoisted_2, [
386
+ createElementVNode("view", {
387
+ class: "nut-input-inner",
388
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.onClickInput && _ctx.onClickInput(...args))
361
389
  }, [
362
- createElementVNode("view", _hoisted_1, toDisplayString(_ctx.label) + " " + toDisplayString(_ctx.colon ? ":" : ""), 1)
363
- ], 6)) : createCommentVNode("", true),
364
- createElementVNode("view", _hoisted_2, [
365
- createElementVNode("view", {
366
- class: "nut-input-inner",
367
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.onClickInput && _ctx.onClickInput(...args))
368
- }, [
369
- renderSlot(_ctx.$slots, "input")
370
- ])
390
+ renderSlot(_ctx.$slots, "input")
371
391
  ])
372
- ], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
373
- _ctx.leftIcon && _ctx.leftIcon.length > 0 ? (openBlock(), createElementBlock("view", {
374
- key: 0,
375
- class: "nut-input-left-icon",
376
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.onClickLeftIcon && _ctx.onClickLeftIcon(...args))
377
- }, [
378
- createVNode(_component_nut_icon, mergeProps({ name: _ctx.leftIcon }, _ctx.$attrs, { size: _ctx.leftIconSize }), null, 16, ["name", "size"])
379
- ])) : createCommentVNode("", true),
380
- _ctx.label ? (openBlock(), createElementBlock("view", {
381
- key: 1,
382
- class: normalizeClass(["nut-input-label", _ctx.labelClass]),
383
- style: normalizeStyle({
384
- width: `${_ctx.labelWidth}px`,
385
- textAlign: _ctx.labelAlign
386
- })
387
- }, [
388
- createElementVNode("view", _hoisted_3, toDisplayString(_ctx.label) + " " + toDisplayString(_ctx.colon ? ":" : ""), 1)
389
- ], 6)) : createCommentVNode("", true),
392
+ ])) : (openBlock(), createElementBlock("view", _hoisted_3, [
390
393
  createElementVNode("view", _hoisted_4, [
391
394
  createElementVNode("view", _hoisted_5, [
392
- createElementVNode("view", _hoisted_6, [
393
- _ctx.type == "textarea" ? (openBlock(), createElementBlock("textarea", {
394
- key: 0,
395
- class: "input-text",
396
- ref: "inputRef",
397
- style: normalizeStyle(_ctx.stylesTextarea),
398
- maxlength: _ctx.maxLength,
399
- placeholder: _ctx.placeholder,
400
- disabled: _ctx.disabled,
401
- readonly: _ctx.readonly,
402
- value: _ctx.modelValue,
403
- formatTrigger: _ctx.formatTrigger,
404
- autofocus: _ctx.autofocus,
405
- onInput: _cache[2] || (_cache[2] = (...args) => _ctx.onInput && _ctx.onInput(...args)),
406
- onFocus: _cache[3] || (_cache[3] = (...args) => _ctx.onFocus && _ctx.onFocus(...args)),
407
- onBlur: _cache[4] || (_cache[4] = (...args) => _ctx.onBlur && _ctx.onBlur(...args)),
408
- onClick: _cache[5] || (_cache[5] = (...args) => _ctx.onClickInput && _ctx.onClickInput(...args))
409
- }, null, 44, _hoisted_7)) : (openBlock(), createElementBlock("input", {
410
- key: 1,
411
- class: "input-text",
412
- ref: "inputRef",
413
- style: normalizeStyle(_ctx.styles),
414
- type: _ctx.inputType(_ctx.type),
415
- maxlength: _ctx.maxLength,
416
- placeholder: _ctx.placeholder,
417
- disabled: _ctx.disabled,
418
- readonly: _ctx.readonly,
419
- value: _ctx.modelValue,
420
- formatTrigger: _ctx.formatTrigger,
421
- autofocus: _ctx.autofocus,
422
- onInput: _cache[6] || (_cache[6] = (...args) => _ctx.onInput && _ctx.onInput(...args)),
423
- onFocus: _cache[7] || (_cache[7] = (...args) => _ctx.onFocus && _ctx.onFocus(...args)),
424
- onBlur: _cache[8] || (_cache[8] = (...args) => _ctx.onBlur && _ctx.onBlur(...args)),
425
- onClick: _cache[9] || (_cache[9] = (...args) => _ctx.onClickInput && _ctx.onClickInput(...args))
426
- }, null, 44, _hoisted_8))
427
- ]),
428
- createElementVNode("view", _hoisted_9, [
429
- _ctx.clearable && !_ctx.readonly ? withDirectives((openBlock(), createBlock(_component_nut_icon, mergeProps({
430
- key: 0,
431
- class: "nut-input-clear",
432
- name: _ctx.clearIcon
433
- }, _ctx.$attrs, {
434
- size: _ctx.clearSize,
435
- onClick: _ctx.clear
436
- }), null, 16, ["name", "size", "onClick"])), [
437
- [vShow, _ctx.active && _ctx.modelValue.length > 0]
438
- ]) : createCommentVNode("", true)
439
- ]),
440
- _ctx.rightIcon && _ctx.rightIcon.length > 0 ? (openBlock(), createElementBlock("view", {
395
+ (openBlock(), createBlock(resolveDynamicComponent(_ctx.renderInput(_ctx.type)), {
396
+ class: "input-text",
397
+ ref: "inputRef",
398
+ style: normalizeStyle(_ctx.styles),
399
+ maxlength: _ctx.maxLength,
400
+ placeholder: _ctx.placeholder,
401
+ disabled: _ctx.disabled,
402
+ readonly: _ctx.readonly,
403
+ value: _ctx.modelValue,
404
+ formatTrigger: _ctx.formatTrigger,
405
+ autofocus: _ctx.autofocus,
406
+ enterkeyhint: _ctx.confirmType,
407
+ onInput: _ctx.onInput,
408
+ onFocus: _ctx.onFocus,
409
+ onBlur: _ctx.onBlur,
410
+ onClick: _ctx.onClickInput
411
+ }, null, 40, ["style", "maxlength", "placeholder", "disabled", "readonly", "value", "formatTrigger", "autofocus", "enterkeyhint", "onInput", "onFocus", "onBlur", "onClick"]))
412
+ ]),
413
+ createElementVNode("view", _hoisted_6, [
414
+ _ctx.clearable && !_ctx.readonly ? withDirectives((openBlock(), createBlock(_component_nut_icon, mergeProps({
441
415
  key: 0,
442
- class: "nut-input-right-icon",
443
- onClick: _cache[10] || (_cache[10] = (...args) => _ctx.onClickRightIcon && _ctx.onClickRightIcon(...args))
444
- }, [
445
- createVNode(_component_nut_icon, mergeProps({ name: _ctx.rightIcon }, _ctx.$attrs, { size: _ctx.rightIconSize }), null, 16, ["name", "size"])
446
- ])) : createCommentVNode("", true),
447
- _ctx.$slots.button ? renderSlot(_ctx.$slots, "button", {
448
- key: 1,
449
- class: "nut-input-button"
450
- }) : createCommentVNode("", true),
451
- _ctx.$slots.rightExtra ? renderSlot(_ctx.$slots, "rightExtra", { key: 2 }) : createCommentVNode("", true)
416
+ class: "nut-input-clear",
417
+ name: _ctx.clearIcon
418
+ }, _ctx.$attrs, {
419
+ size: _ctx.clearSize,
420
+ onClick: _ctx.clear
421
+ }), null, 16, ["name", "size", "onClick"])), [
422
+ [vShow, _ctx.active && _ctx.modelValue.length > 0]
423
+ ]) : createCommentVNode("", true)
452
424
  ]),
453
- _ctx.showWordLimit && _ctx.maxLength ? (openBlock(), createElementBlock("view", _hoisted_10, [
454
- createElementVNode("span", _hoisted_11, toDisplayString(_ctx.modelValue ? _ctx.modelValue.length : 0), 1),
455
- createTextVNode("/" + toDisplayString(_ctx.maxLength), 1)
425
+ _ctx.rightIcon && _ctx.rightIcon.length > 0 ? (openBlock(), createElementBlock("view", {
426
+ key: 0,
427
+ class: "nut-input-right-icon",
428
+ onClick: _cache[2] || (_cache[2] = (...args) => _ctx.onClickRightIcon && _ctx.onClickRightIcon(...args))
429
+ }, [
430
+ createVNode(_component_nut_icon, mergeProps({ name: _ctx.rightIcon }, _ctx.$attrs, { size: _ctx.rightIconSize }), null, 16, ["name", "size"])
456
431
  ])) : createCommentVNode("", true),
457
- _ctx.errorMessage ? (openBlock(), createElementBlock("view", {
432
+ _ctx.$slots.button ? renderSlot(_ctx.$slots, "button", {
458
433
  key: 1,
459
- class: "nut-input-error-message",
460
- style: normalizeStyle({
461
- textAlign: _ctx.errorMessageAlign
462
- })
463
- }, toDisplayString(_ctx.errorMessage), 5)) : createCommentVNode("", true)
464
- ])
465
- ], 64))
434
+ class: "nut-input-button"
435
+ }) : createCommentVNode("", true),
436
+ _ctx.$slots.rightExtra ? renderSlot(_ctx.$slots, "rightExtra", { key: 2 }) : createCommentVNode("", true)
437
+ ]),
438
+ _ctx.showWordLimit && _ctx.maxLength ? (openBlock(), createElementBlock("view", _hoisted_7, [
439
+ createElementVNode("span", _hoisted_8, toDisplayString(_ctx.modelValue ? _ctx.modelValue.length : 0), 1),
440
+ createTextVNode("/" + toDisplayString(_ctx.maxLength), 1)
441
+ ])) : createCommentVNode("", true),
442
+ _ctx.errorMessage ? (openBlock(), createElementBlock("view", {
443
+ key: 1,
444
+ class: "nut-input-error-message",
445
+ style: normalizeStyle({
446
+ textAlign: _ctx.errorMessageAlign
447
+ })
448
+ }, toDisplayString(_ctx.errorMessage), 5)) : createCommentVNode("", true)
449
+ ]))
466
450
  ], 2);
467
451
  }
468
452
  var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 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.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 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.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 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.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 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.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -56,10 +56,23 @@ const _sfc_main = create({
56
56
  publicChildren.push(child.proxy);
57
57
  }
58
58
  };
59
+ const removeLink = (child) => {
60
+ if (child.proxy) {
61
+ let internalIndex = internalChildren.indexOf(child);
62
+ if (internalIndex > -1) {
63
+ internalChildren.splice(internalIndex, 1);
64
+ }
65
+ let publicIndex = publicChildren.indexOf(child.proxy);
66
+ if (internalIndex > -1) {
67
+ publicChildren.splice(publicIndex, 1);
68
+ }
69
+ }
70
+ };
59
71
  provide(
60
72
  "menuParent",
61
73
  Object.assign(
62
74
  {
75
+ removeLink,
63
76
  link,
64
77
  children: publicChildren,
65
78
  internalChildren
@@ -1,16 +1,16 @@
1
1
  /*!
2
- * @nutui/nutui v3.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
6
- import { reactive, computed, inject, getCurrentInstance, resolveComponent, withDirectives, openBlock, createElementBlock, normalizeClass, createElementVNode, normalizeStyle, vShow, createVNode, mergeProps, withCtx, Fragment, renderList, createBlock, createCommentVNode, toDisplayString, renderSlot } from "vue";
6
+ import { reactive, computed, inject, getCurrentInstance, onUnmounted, resolveComponent, withDirectives, openBlock, createElementBlock, normalizeClass, createElementVNode, normalizeStyle, vShow, createVNode, mergeProps, withCtx, Fragment, renderList, createBlock, createCommentVNode, toDisplayString, renderSlot } from "vue";
7
7
  import { c as createComponent } from "./component.js";
8
8
  import _sfc_main$1 from "./Icon.js";
9
9
  import Popup from "./Popup.js";
10
10
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
11
11
  import "../locale/lang";
12
12
  import "./pxCheck.js";
13
- import "./OverLay.js";
13
+ import "./props.js";
14
14
  const { componentName, create } = createComponent("menu-item");
15
15
  const _sfc_main = create({
16
16
  props: {
@@ -51,8 +51,11 @@ const _sfc_main = create({
51
51
  const parent2 = inject("menuParent", null);
52
52
  if (parent2) {
53
53
  const instance = getCurrentInstance();
54
- const { link } = parent2;
54
+ const { link, removeLink } = parent2;
55
55
  link(instance);
56
+ onUnmounted(() => {
57
+ removeLink(instance);
58
+ });
56
59
  return {
57
60
  parent: parent2
58
61
  };
@@ -139,18 +142,18 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
139
142
  ]),
140
143
  createVNode(_component_nut_popup, mergeProps({
141
144
  style: _ctx.parent.props.direction === "down" ? { top: _ctx.parent.offset.value + "px" } : { bottom: _ctx.parent.offset.value + "px" },
142
- overlayStyle: _ctx.parent.props.direction === "down" ? { top: _ctx.parent.offset.value + "px" } : { bottom: _ctx.parent.offset.value + "px" }
145
+ overlayStyle: _ctx.parent.props.direction === "down" ? { top: _ctx.parent.offset.value + "px" } : { bottom: _ctx.parent.offset.value + "px", top: "auto" }
143
146
  }, _ctx.$attrs, {
144
147
  visible: _ctx.state.showPopup,
145
148
  "onUpdate:visible": _cache[1] || (_cache[1] = ($event) => _ctx.state.showPopup = $event),
146
149
  position: _ctx.parent.props.direction === "down" ? "top" : "bottom",
147
150
  duration: _ctx.parent.props.duration,
148
151
  "pop-class": "nut-menu__pop",
149
- overlayClass: "nut-menu__overlay",
152
+ "destroy-on-close": false,
150
153
  overlay: _ctx.parent.props.overlay,
151
154
  onClosed: _ctx.handleClose,
152
155
  lockScroll: _ctx.parent.props.lockScroll,
153
- isWrapTeleport: false,
156
+ teleportDisable: false,
154
157
  "close-on-click-overlay": _ctx.parent.props.closeOnClickOverlay
155
158
  }), {
156
159
  default: withCtx(() => [
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 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.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 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.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -8,9 +8,7 @@ import { c as createComponent } from "./component.js";
8
8
  import Popup from "./Popup.js";
9
9
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
10
10
  import "../locale/lang";
11
- import "./OverLay.js";
12
- import "./Icon.js";
13
- import "./pxCheck.js";
11
+ import "./props.js";
14
12
  const { create } = createComponent("notify");
15
13
  const _sfc_main = create({
16
14
  components: {
@@ -38,7 +36,7 @@ const _sfc_main = create({
38
36
  type: String,
39
37
  default: "top"
40
38
  },
41
- isWrapTeleport: {
39
+ teleportDisable: {
42
40
  type: Boolean,
43
41
  default: true
44
42
  },
@@ -89,7 +87,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
89
87
  "onUpdate:visible": _cache[1] || (_cache[1] = ($event) => _ctx.isShowPopup = $event),
90
88
  position: _ctx.position,
91
89
  overlay: false,
92
- isWrapTeleport: _ctx.isWrapTeleport
90
+ teleportDisable: _ctx.teleportDisable
93
91
  }, {
94
92
  default: withCtx(() => [
95
93
  createElementVNode("div", {
@@ -103,7 +101,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
103
101
  ], 6)
104
102
  ]),
105
103
  _: 3
106
- }, 8, ["visible", "position", "isWrapTeleport"]);
104
+ }, 8, ["visible", "position", "teleportDisable"]);
107
105
  }
108
106
  var Notify = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
109
107
  const defaultOptions = {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.2.7 Fri Nov 18 2022 19:57:44 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -46,7 +46,7 @@ const _sfc_main = create({
46
46
  type: Boolean,
47
47
  default: true
48
48
  },
49
- isWrapTeleport: {
49
+ teleportDisable: {
50
50
  type: Boolean,
51
51
  default: true
52
52
  },
@@ -208,7 +208,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
208
208
  popClass: _ctx.popClass,
209
209
  overlay: _ctx.overlay,
210
210
  onClickOverlay: _cache[8] || (_cache[8] = ($event) => _ctx.closeBoard()),
211
- isWrapTeleport: _ctx.isWrapTeleport,
211
+ teleportDisable: _ctx.teleportDisable,
212
212
  "overlay-class": "nut-numberkeyboard-overlay"
213
213
  }, {
214
214
  default: withCtx(() => [
@@ -275,7 +275,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
275
275
  ], 512)
276
276
  ]),
277
277
  _: 1
278
- }, 8, ["visible", "teleport", "popClass", "overlay", "isWrapTeleport"]);
278
+ }, 8, ["visible", "teleport", "popClass", "overlay", "teleportDisable"]);
279
279
  }
280
280
  var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
281
281
  export { index as default };