@nutui/nutui 4.3.1 → 4.3.3

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 (130) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/dist/nutui.es.js +2 -4
  3. package/dist/nutui.js +6035 -6408
  4. package/dist/nutui.umd.js +1 -1
  5. package/dist/packages/actionsheet/ActionSheet.js +1 -1
  6. package/dist/packages/address/Address.js +1 -1
  7. package/dist/packages/addresslist/AddressList.js +2 -2
  8. package/dist/packages/animate/Animate.js +51 -44
  9. package/dist/packages/backtop/Backtop.js +79 -89
  10. package/dist/packages/calendar/Calendar.js +814 -3
  11. package/dist/packages/calendar/index.scss +0 -1
  12. package/dist/packages/calendarcard/CalendarCard.js +1 -1
  13. package/dist/packages/card/Card.js +4 -4
  14. package/dist/packages/cascader/Cascader.js +1 -1
  15. package/dist/packages/checkbox/Checkbox.js +1 -1
  16. package/dist/packages/circleprogress/CircleProgress.js +90 -97
  17. package/dist/packages/col/Col.js +41 -30
  18. package/dist/packages/comment/Comment.js +2 -2
  19. package/dist/packages/{common-LvGbU-A3.js → common-FZL3qC99.js} +5 -2
  20. package/dist/packages/dialog/Dialog.js +1 -1
  21. package/dist/packages/ecard/Ecard.js +2 -2
  22. package/dist/packages/form/Form.js +3 -1
  23. package/dist/packages/formitem/FormItem.js +1 -1
  24. package/dist/packages/imagepreview/ImagePreview.js +1 -1
  25. package/dist/packages/{index-wY4t0zYt.js → index-BqB5dTeo.js} +29 -17
  26. package/dist/packages/{index.vue_vue_type_script_lang-w2sgcysj.js → index.vue_vue_type_script_lang-n0HbjvfF.js} +1 -1
  27. package/dist/packages/input/Input.js +8 -8
  28. package/dist/packages/inputnumber/InputNumber.js +84 -103
  29. package/dist/packages/invoice/Invoice.js +87 -138
  30. package/dist/packages/layout/Layout.js +3 -0
  31. package/dist/packages/menuitem/MenuItem.js +1 -1
  32. package/dist/packages/navbar/Navbar.js +103 -115
  33. package/dist/packages/notify/Notify.js +1 -1
  34. package/dist/packages/numberkeyboard/NumberKeyboard.js +1 -1
  35. package/dist/packages/popover/Popover.js +1 -1
  36. package/dist/packages/popup/Popup.js +1 -1
  37. package/dist/packages/price/Price.js +69 -77
  38. package/dist/packages/progress/Progress.js +96 -115
  39. package/dist/packages/radio/Radio.js +1 -1
  40. package/dist/packages/range/Range.js +1 -1
  41. package/dist/packages/rate/Rate.js +99 -141
  42. package/dist/packages/row/Row.js +43 -39
  43. package/dist/packages/searchbar/Searchbar.js +1 -1
  44. package/dist/packages/shortpassword/ShortPassword.js +1 -1
  45. package/dist/packages/sku/Sku.js +5 -5
  46. package/dist/packages/swipe/Swipe.js +96 -110
  47. package/dist/packages/swipegroup/SwipeGroup.js +41 -23
  48. package/dist/packages/switch/Switch.js +12 -4
  49. package/dist/packages/switch/index.css +1 -1
  50. package/dist/packages/switch/index.scss +1 -1
  51. package/dist/packages/tag/Tag.js +57 -66
  52. package/dist/packages/textarea/Textarea.js +1 -1
  53. package/dist/packages/timeselect/TimeSelect.js +1 -1
  54. package/dist/packages/uploader/Uploader.js +5 -5
  55. package/dist/smartips/web-types.json +12 -3
  56. package/dist/style.css +1 -1
  57. package/dist/styles/base-jdb.css +1 -1
  58. package/dist/styles/base-jddkh.css +1 -1
  59. package/dist/styles/base-jdt.css +1 -1
  60. package/dist/styles/themes/default.scss +0 -1
  61. package/dist/styles/themes/jdb.scss +0 -1
  62. package/dist/styles/themes/jddkh.scss +0 -1
  63. package/dist/styles/themes/jdt.scss +0 -1
  64. package/dist/styles/variables-jdb.scss +0 -1
  65. package/dist/styles/variables-jddkh.scss +0 -1
  66. package/dist/styles/variables-jdt.scss +0 -1
  67. package/dist/styles/variables.scss +0 -1
  68. package/dist/types/__VUE/animate/animate.vue.d.ts +75 -0
  69. package/dist/types/__VUE/animate/index.d.ts +6 -0
  70. package/dist/types/__VUE/backtop/backtop.vue.d.ts +87 -0
  71. package/dist/types/__VUE/backtop/index.d.ts +5 -0
  72. package/dist/types/__VUE/calendaritem/index.vue.d.ts +2 -12
  73. package/dist/types/__VUE/circleprogress/circle-progress.vue.d.ts +88 -0
  74. package/dist/types/__VUE/circleprogress/index.d.ts +6 -0
  75. package/dist/types/__VUE/col/col.vue.d.ts +53 -0
  76. package/dist/types/__VUE/col/index.d.ts +5 -0
  77. package/dist/types/__VUE/form/common.d.ts +2 -0
  78. package/dist/types/__VUE/form/types.d.ts +0 -1
  79. package/dist/types/__VUE/input/index.vue.d.ts +1 -1
  80. package/dist/types/__VUE/inputnumber/index.d.ts +5 -0
  81. package/dist/types/__VUE/inputnumber/input-number.vue.d.ts +112 -0
  82. package/dist/types/__VUE/invoice/index.d.ts +6 -0
  83. package/dist/types/__VUE/invoice/invoice.vue.d.ts +59 -0
  84. package/dist/types/__VUE/invoice/types.d.ts +12 -0
  85. package/dist/types/__VUE/layout/index.d.ts +4 -0
  86. package/dist/types/__VUE/layout/layout.vue.d.ts +10 -0
  87. package/dist/types/__VUE/navbar/index.d.ts +5 -0
  88. package/dist/types/__VUE/navbar/navbar.vue.d.ts +125 -0
  89. package/dist/types/__VUE/price/index.d.ts +6 -0
  90. package/dist/types/__VUE/price/price.vue.d.ts +83 -0
  91. package/dist/types/__VUE/progress/index.d.ts +6 -0
  92. package/dist/types/__VUE/progress/progress.vue.d.ts +91 -0
  93. package/dist/types/__VUE/rate/index.d.ts +5 -0
  94. package/dist/types/__VUE/rate/rate.vue.d.ts +208 -0
  95. package/dist/types/__VUE/row/index.d.ts +5 -0
  96. package/dist/types/__VUE/row/row.vue.d.ts +71 -0
  97. package/dist/types/__VUE/swipe/index.d.ts +6 -0
  98. package/dist/types/__VUE/swipe/swipe.vue.d.ts +79 -0
  99. package/dist/types/__VUE/swipe/types.d.ts +1 -0
  100. package/dist/types/__VUE/swipegroup/index.d.ts +5 -0
  101. package/dist/types/__VUE/swipegroup/swipe-group.vue.d.ts +47 -0
  102. package/dist/types/__VUE/switch/index.vue.d.ts +9 -0
  103. package/dist/types/__VUE/tag/index.d.ts +6 -0
  104. package/dist/types/__VUE/tag/tag.vue.d.ts +90 -0
  105. package/dist/types/__VUE/tag/types.d.ts +1 -1
  106. package/dist/types/index.d.ts +32 -18
  107. package/package.json +1 -1
  108. package/dist/packages/calendaritem/CalendarItem.js +0 -819
  109. package/dist/packages/calendaritem/index.css +0 -0
  110. package/dist/packages/calendaritem/index.mjs +0 -2
  111. package/dist/packages/calendaritem/index.scss +0 -0
  112. package/dist/packages/calendaritem/style/css.mjs +0 -2
  113. package/dist/packages/calendaritem/style/index.mjs +0 -2
  114. package/dist/packages/types-Ynmct7na.js +0 -4
  115. package/dist/types/__VUE/animate/index.vue.d.ts +0 -71
  116. package/dist/types/__VUE/backtop/index.vue.d.ts +0 -98
  117. package/dist/types/__VUE/circleprogress/index.vue.d.ts +0 -95
  118. package/dist/types/__VUE/col/index.vue.d.ts +0 -42
  119. package/dist/types/__VUE/inputnumber/index.vue.d.ts +0 -117
  120. package/dist/types/__VUE/invoice/index.vue.d.ts +0 -53
  121. package/dist/types/__VUE/layout/index.vue.d.ts +0 -12
  122. package/dist/types/__VUE/navbar/index.vue.d.ts +0 -129
  123. package/dist/types/__VUE/price/index.vue.d.ts +0 -97
  124. package/dist/types/__VUE/progress/index.vue.d.ts +0 -120
  125. package/dist/types/__VUE/rate/index.vue.d.ts +0 -240
  126. package/dist/types/__VUE/row/index.vue.d.ts +0 -62
  127. package/dist/types/__VUE/swipe/index.vue.d.ts +0 -70
  128. package/dist/types/__VUE/swipegroup/index.vue.d.ts +0 -26
  129. package/dist/types/__VUE/tag/index.vue.d.ts +0 -94
  130. /package/dist/types/__VUE/animate/{type.d.ts → types.d.ts} +0 -0
@@ -1,5 +1,4 @@
1
1
  @import '../popup/index.scss';
2
- @import '../calendaritem/index.scss';
3
2
 
4
3
  .nut-theme-dark {
5
4
  .nut-calendar {
@@ -402,7 +402,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
402
402
  change([day]);
403
403
  } else if (len === 1) {
404
404
  const t = compareDay(innerValue.value[0], day);
405
- if (t === 0 || t === null || t === void 0) {
405
+ if (t === null || t === void 0) {
406
406
  change([]);
407
407
  } else if (t < 0) {
408
408
  change([innerValue.value[0], day]);
@@ -1,13 +1,13 @@
1
1
  import { c as createComponent } from "../component-TCzwHGVq.js";
2
2
  import { resolveComponent, openBlock, createElementBlock, createElementVNode, toDisplayString, renderSlot, createVNode, createCommentVNode, withCtx, createTextVNode } from "vue";
3
- import NutPrice from "../price/Price.js";
4
- import NutTag from "../tag/Tag.js";
3
+ import { Price as _sfc_main$1 } from "../price/Price.js";
4
+ import { Tag as _sfc_main$2 } from "../tag/Tag.js";
5
5
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
6
6
  const { create } = createComponent("card");
7
7
  const _sfc_main = create({
8
8
  components: {
9
- NutPrice,
10
- NutTag
9
+ NutPrice: _sfc_main$1,
10
+ NutTag: _sfc_main$2
11
11
  },
12
12
  props: {
13
13
  imgUrl: {
@@ -55,7 +55,7 @@ var __async = (__this, __arguments, generator) => {
55
55
  });
56
56
  };
57
57
  import { computed, ref, watch, resolveComponent, openBlock, createBlock, withCtx, createElementBlock, Fragment, renderList, createElementVNode, normalizeClass, toDisplayString, createCommentVNode, createVNode } from "vue";
58
- import { N as NutPopup, p as popupProps } from "../index-wY4t0zYt.js";
58
+ import { N as NutPopup, p as popupProps } from "../index-BqB5dTeo.js";
59
59
  import { c as createComponent } from "../component-TCzwHGVq.js";
60
60
  import { Loading, Checklist } from "@nutui/icons-vue";
61
61
  import NutTabs from "../tabs/Tabs.js";
@@ -3,7 +3,7 @@ import { c as createComponent } from "../component-TCzwHGVq.js";
3
3
  import { CheckNormal, Checked, CheckDisabled } from "@nutui/icons-vue";
4
4
  import { p as pxCheck } from "../pxCheck-OnXlN1NC.js";
5
5
  import { C as CHECKBOX_KEY } from "../types-zeKkNDAq.js";
6
- import { u as useFormDisabled } from "../common-LvGbU-A3.js";
6
+ import { u as useFormDisabled } from "../common-FZL3qC99.js";
7
7
  const { create, componentName } = createComponent("checkbox");
8
8
  const _sfc_main = create({
9
9
  props: {
@@ -1,40 +1,46 @@
1
- import { computed, openBlock, createElementBlock, normalizeStyle, createElementVNode, Fragment, renderList, renderSlot, toDisplayString } from "vue";
2
- import { c as createComponent } from "../component-TCzwHGVq.js";
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
+ import { defineComponent, computed, openBlock, createElementBlock, normalizeStyle, createElementVNode, unref, Fragment, renderList, renderSlot, toDisplayString } from "vue";
3
21
  import { k as isObject } from "../util-4Jkyw4BJ.js";
4
- import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
5
- const { create } = createComponent("circle-progress");
6
- const _sfc_main = create({
22
+ import { w as withInstall } from "../with-install-p59gYYU_.js";
23
+ const _hoisted_1 = { viewBox: "0 0 100 100" };
24
+ const _hoisted_2 = ["id"];
25
+ const _hoisted_3 = ["offset", "stop-color"];
26
+ const _hoisted_4 = ["d", "stroke-width"];
27
+ const _hoisted_5 = ["d", "stroke", "stroke-linecap", "stroke-width"];
28
+ const _hoisted_6 = { class: "nut-circle-progress__text" };
29
+ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
30
+ name: "NutCircleProgress"
31
+ }), {
32
+ __name: "circle-progress",
7
33
  props: {
8
- progress: {
9
- type: [Number, String],
10
- defualt: 0
11
- },
12
- strokeWidth: {
13
- type: [Number, String],
14
- default: 5
15
- },
16
- radius: {
17
- type: [Number, String],
18
- default: 50
19
- },
20
- strokeLinecap: {
21
- type: String,
22
- default: "round"
23
- },
24
- color: {
25
- type: [String, Object],
26
- default: ""
27
- },
28
- pathColor: {
29
- type: String,
30
- default: ""
31
- },
32
- clockwise: {
33
- type: Boolean,
34
- default: true
35
- }
34
+ progress: { default: 0 },
35
+ strokeWidth: { default: 5 },
36
+ radius: { default: 50 },
37
+ strokeLinecap: { default: "round" },
38
+ color: { default: "#fa2c19" },
39
+ pathColor: { default: "#d9d9d9" },
40
+ clockwise: { type: Boolean, default: true }
36
41
  },
37
- setup(props) {
42
+ setup(__props) {
43
+ const props = __props;
38
44
  const refRandomId = Math.random().toString(36).slice(-8);
39
45
  const path = computed(() => {
40
46
  const isWise = props.clockwise ? 1 : 0;
@@ -74,70 +80,57 @@ const _sfc_main = create({
74
80
  });
75
81
  return stopArr;
76
82
  });
77
- return {
78
- hoverStyle,
79
- pathStyle,
80
- path,
81
- hoverColor,
82
- stop,
83
- refRandomId
83
+ return (_ctx, _cache) => {
84
+ return openBlock(), createElementBlock("div", {
85
+ class: "nut-circle-progress",
86
+ style: normalizeStyle({ height: Number(_ctx.radius) * 2 + "px", width: Number(_ctx.radius) * 2 + "px" })
87
+ }, [
88
+ (openBlock(), createElementBlock("svg", _hoisted_1, [
89
+ createElementVNode("defs", null, [
90
+ createElementVNode("linearGradient", {
91
+ id: unref(refRandomId),
92
+ x1: "100%",
93
+ y1: "0%",
94
+ x2: "0%",
95
+ y2: "0%"
96
+ }, [
97
+ (openBlock(true), createElementBlock(Fragment, null, renderList(stop.value, (item, index) => {
98
+ return openBlock(), createElementBlock("stop", {
99
+ key: index,
100
+ offset: item.key,
101
+ "stop-color": item.value
102
+ }, null, 8, _hoisted_3);
103
+ }), 128))
104
+ ], 8, _hoisted_2)
105
+ ]),
106
+ createElementVNode("path", {
107
+ class: "nut-circle-progress__path",
108
+ style: normalizeStyle(pathStyle.value),
109
+ d: path.value,
110
+ fill: "none",
111
+ "stroke-width": _ctx.strokeWidth
112
+ }, " > ", 12, _hoisted_4),
113
+ createElementVNode("path", {
114
+ class: "nut-circle-progress__hover",
115
+ style: normalizeStyle(hoverStyle.value),
116
+ d: path.value,
117
+ fill: "none",
118
+ stroke: hoverColor.value,
119
+ "stroke-linecap": _ctx.strokeLinecap,
120
+ "stroke-width": _ctx.strokeWidth
121
+ }, null, 12, _hoisted_5)
122
+ ])),
123
+ createElementVNode("div", _hoisted_6, [
124
+ renderSlot(_ctx.$slots, "default", {}, () => [
125
+ createElementVNode("div", null, toDisplayString(_ctx.progress) + "%", 1)
126
+ ])
127
+ ])
128
+ ], 4);
84
129
  };
85
130
  }
86
- });
87
- const _hoisted_1 = { viewBox: "0 0 100 100" };
88
- const _hoisted_2 = ["id"];
89
- const _hoisted_3 = ["offset", "stop-color"];
90
- const _hoisted_4 = ["d", "stroke-width"];
91
- const _hoisted_5 = ["d", "stroke", "stroke-linecap", "stroke-width"];
92
- const _hoisted_6 = { class: "nut-circle-progress__text" };
93
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
94
- return openBlock(), createElementBlock("div", {
95
- class: "nut-circle-progress",
96
- style: normalizeStyle({ height: Number(_ctx.radius) * 2 + "px", width: Number(_ctx.radius) * 2 + "px" })
97
- }, [
98
- (openBlock(), createElementBlock("svg", _hoisted_1, [
99
- createElementVNode("defs", null, [
100
- createElementVNode("linearGradient", {
101
- id: _ctx.refRandomId,
102
- x1: "100%",
103
- y1: "0%",
104
- x2: "0%",
105
- y2: "0%"
106
- }, [
107
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.stop, (item, index2) => {
108
- return openBlock(), createElementBlock("stop", {
109
- key: index2,
110
- offset: item.key,
111
- "stop-color": item.value
112
- }, null, 8, _hoisted_3);
113
- }), 128))
114
- ], 8, _hoisted_2)
115
- ]),
116
- createElementVNode("path", {
117
- class: "nut-circle-progress__path",
118
- style: normalizeStyle(_ctx.pathStyle),
119
- d: _ctx.path,
120
- fill: "none",
121
- "stroke-width": _ctx.strokeWidth
122
- }, " > ", 12, _hoisted_4),
123
- createElementVNode("path", {
124
- class: "nut-circle-progress__hover",
125
- style: normalizeStyle(_ctx.hoverStyle),
126
- d: _ctx.path,
127
- fill: "none",
128
- stroke: _ctx.hoverColor,
129
- "stroke-linecap": _ctx.strokeLinecap,
130
- "stroke-width": _ctx.strokeWidth
131
- }, null, 12, _hoisted_5)
132
- ])),
133
- createElementVNode("div", _hoisted_6, [
134
- renderSlot(_ctx.$slots, "default", {}, () => [
135
- createElementVNode("div", null, toDisplayString(_ctx.progress) + "%", 1)
136
- ])
137
- ])
138
- ], 4);
139
- }
140
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
131
+ }));
132
+ withInstall(_sfc_main);
141
133
  export {
142
- index as default
134
+ _sfc_main as CircleProgress,
135
+ _sfc_main as default
143
136
  };
@@ -1,22 +1,36 @@
1
- import { inject, computed, openBlock, createElementBlock, normalizeClass, normalizeStyle, renderSlot } from "vue";
2
- import { c as createComponent } from "../component-TCzwHGVq.js";
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
+ import { defineComponent, inject, computed, openBlock, createElementBlock, normalizeClass, normalizeStyle, renderSlot } from "vue";
3
21
  import { L as LAYOUT_KEY } from "../types-Ww4ErYJT.js";
4
- import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
5
- const { create } = createComponent("col");
6
- const _sfc_main = create({
22
+ import { w as withInstall } from "../with-install-p59gYYU_.js";
23
+ const prefixCls = "nut-col";
24
+ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
25
+ name: "NutCol"
26
+ }), {
27
+ __name: "col",
7
28
  props: {
8
- span: {
9
- type: [String, Number],
10
- default: "24"
11
- },
12
- offset: {
13
- type: [String, Number],
14
- default: "0"
15
- }
29
+ span: { default: 24 },
30
+ offset: { default: 0 }
16
31
  },
17
- emits: [],
18
- setup(props) {
19
- const prefixCls = "nut-col";
32
+ setup(__props) {
33
+ const props = __props;
20
34
  const gutter = inject(LAYOUT_KEY);
21
35
  const classes = computed(() => {
22
36
  return {
@@ -32,21 +46,18 @@ const _sfc_main = create({
32
46
  paddingRight: gutter / 2 + "px"
33
47
  };
34
48
  });
35
- return {
36
- classes,
37
- style
49
+ return (_ctx, _cache) => {
50
+ return openBlock(), createElementBlock("view", {
51
+ class: normalizeClass(classes.value),
52
+ style: normalizeStyle(style.value)
53
+ }, [
54
+ renderSlot(_ctx.$slots, "default")
55
+ ], 6);
38
56
  };
39
57
  }
40
- });
41
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
42
- return openBlock(), createElementBlock("view", {
43
- class: normalizeClass(_ctx.classes),
44
- style: normalizeStyle(_ctx.style)
45
- }, [
46
- renderSlot(_ctx.$slots, "default")
47
- ], 6);
48
- }
49
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
58
+ }));
59
+ withInstall(_sfc_main);
50
60
  export {
51
- index as default
61
+ _sfc_main as Col,
62
+ _sfc_main as default
52
63
  };
@@ -1,13 +1,13 @@
1
1
  import { resolveComponent, openBlock, createElementBlock, createElementVNode, createCommentVNode, normalizeClass, toDisplayString, renderSlot, createVNode, ref, watch, onMounted, Fragment, renderList, createBlock, computed, withCtx, normalizeStyle, createTextVNode } from "vue";
2
2
  import { Right, Fabulous, Comment, MoreX } from "@nutui/icons-vue";
3
3
  import { c as createComponent } from "../component-TCzwHGVq.js";
4
- import NutRate from "../rate/Rate.js";
4
+ import { Rate as _sfc_main$4 } from "../rate/Rate.js";
5
5
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
6
6
  import { u as useLocale } from "../index-s3RgMhc7.js";
7
7
  const { create: create$3 } = createComponent("comment-header");
8
8
  const _sfc_main$3 = create$3({
9
9
  components: {
10
- NutRate
10
+ NutRate: _sfc_main$4
11
11
  },
12
12
  props: {
13
13
  type: {
@@ -1,13 +1,16 @@
1
1
  import { computed } from "vue";
2
2
  import { u as useParent } from "./useParent-KIxqkovs.js";
3
- import { F as FORM_KEY } from "./types-Ynmct7na.js";
3
+ const FORM_KEY = Symbol("nut-form");
4
+ const FORM_DISABLED_KEY = Symbol("nut-form-disabled");
4
5
  const useFormDisabled = (disabled) => {
5
- const { parent } = useParent(FORM_KEY);
6
+ const { parent } = useParent(FORM_DISABLED_KEY);
6
7
  return computed(() => {
7
8
  var _a;
8
9
  return disabled.value || ((_a = parent == null ? void 0 : parent.props) == null ? void 0 : _a.disabled) || false;
9
10
  });
10
11
  };
11
12
  export {
13
+ FORM_KEY as F,
14
+ FORM_DISABLED_KEY as a,
12
15
  useFormDisabled as u
13
16
  };
@@ -24,7 +24,7 @@ var __publicField = (obj, key, value) => {
24
24
  import { ref, onMounted, watch, computed, resolveComponent, openBlock, createBlock, normalizeStyle, withCtx, createElementVNode, normalizeClass, createElementBlock, renderSlot, Fragment, createTextVNode, toDisplayString, createCommentVNode, resolveDynamicComponent, nextTick, h } from "vue";
25
25
  import { c as createComponent } from "../component-TCzwHGVq.js";
26
26
  import { f as funInterceptor } from "../Interceptor-WYVtGbGC.js";
27
- import { N as NutPopup, p as popupProps } from "../index-wY4t0zYt.js";
27
+ import { N as NutPopup, p as popupProps } from "../index-BqB5dTeo.js";
28
28
  import { Button as _sfc_main$1 } from "../button/Button.js";
29
29
  import { u as useLocale } from "../index-s3RgMhc7.js";
30
30
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
@@ -1,13 +1,13 @@
1
1
  import { ref, watch, resolveComponent, openBlock, createElementBlock, createElementVNode, toDisplayString, Fragment, renderList, normalizeClass, withDirectives, vModelText, createTextVNode, createVNode } from "vue";
2
2
  import { c as createComponent } from "../component-TCzwHGVq.js";
3
- import NutInputNumber from "../inputnumber/InputNumber.js";
3
+ import { InputNumber as _sfc_main$1 } from "../inputnumber/InputNumber.js";
4
4
  import { u as useLocale } from "../index-s3RgMhc7.js";
5
5
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
6
6
  const { create } = createComponent("ecard");
7
7
  const cN = "NutEcard";
8
8
  const _sfc_main = create({
9
9
  components: {
10
- NutInputNumber
10
+ NutInputNumber: _sfc_main$1
11
11
  },
12
12
  props: {
13
13
  chooseText: {
@@ -53,7 +53,7 @@ import { defineComponent, computed, reactive, provide, watch, openBlock, createE
53
53
  import { u as useChildren } from "../useChildren-GU_NVfD8.js";
54
54
  import { g as getPropByPath, f as isPromise } from "../util-4Jkyw4BJ.js";
55
55
  import NutCellGroup from "../cellgroup/CellGroup.js";
56
- import { F as FORM_KEY } from "../types-Ynmct7na.js";
56
+ import { F as FORM_KEY, a as FORM_DISABLED_KEY } from "../common-FZL3qC99.js";
57
57
  import { w as withInstall } from "../with-install-p59gYYU_.js";
58
58
  const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
59
59
  name: "NutForm"
@@ -72,6 +72,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
72
72
  const emit = __emit;
73
73
  const { children, linkChildren } = useChildren(FORM_KEY);
74
74
  linkChildren({ props });
75
+ const { linkChildren: linkChildren2 } = useChildren(FORM_DISABLED_KEY);
76
+ linkChildren2({ props });
75
77
  const formErrorTip = computed(() => reactive({}));
76
78
  provide("formErrorTip", formErrorTip);
77
79
  const clearErrorTips = () => {
@@ -20,7 +20,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  import { defineComponent, computed, inject, openBlock, createBlock, normalizeClass, unref, normalizeStyle, withCtx, createElementBlock, renderSlot, createTextVNode, toDisplayString, createCommentVNode, createElementVNode } from "vue";
21
21
  import { p as pxCheck } from "../pxCheck-OnXlN1NC.js";
22
22
  import NutCell from "../cell/Cell.js";
23
- import { F as FORM_KEY } from "../types-Ynmct7na.js";
23
+ import { F as FORM_KEY } from "../common-FZL3qC99.js";
24
24
  import { u as useParent } from "../useParent-KIxqkovs.js";
25
25
  import { w as withInstall } from "../with-install-p59gYYU_.js";
26
26
  const _hoisted_1 = { class: "nut-cell__value nut-form-item__body" };
@@ -31,7 +31,7 @@ import NutVideo from "../video/Video.js";
31
31
  import NutSwiperItem from "../swiperitem/SwiperItem.js";
32
32
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
33
33
  import { CircleClose } from "@nutui/icons-vue";
34
- import { N as NutPopup } from "../index-wY4t0zYt.js";
34
+ import { N as NutPopup } from "../index-BqB5dTeo.js";
35
35
  import NutSwiper from "../swiper/Swiper.js";
36
36
  import { f as funInterceptor } from "../Interceptor-WYVtGbGC.js";
37
37
  import { C as CreateComponent } from "../mountComponent-uInXoTMp.js";
@@ -111,6 +111,7 @@ const _sfc_main = create({
111
111
  props: popupProps,
112
112
  emits: ["clickPop", "clickCloseIcon", "open", "close", "opened", "closed", "clickOverlay", "update:visible"],
113
113
  setup(props, { emit }) {
114
+ let opened;
114
115
  const state = reactive({
115
116
  zIndex: props.zIndex,
116
117
  showSlot: true,
@@ -136,23 +137,29 @@ const _sfc_main = create({
136
137
  return props.transition ? props.transition : `nut-popup-slide-${props.position}`;
137
138
  });
138
139
  const open = () => {
139
- if (props.zIndex !== initIndex) {
140
- _zIndex = Number(props.zIndex);
140
+ if (!opened) {
141
+ opened = true;
142
+ if (props.zIndex !== initIndex) {
143
+ _zIndex = Number(props.zIndex);
144
+ }
145
+ emit("update:visible", true);
146
+ state.zIndex = ++_zIndex;
147
+ if (props.destroyOnClose) {
148
+ state.showSlot = true;
149
+ }
150
+ emit("open");
141
151
  }
142
- emit("update:visible", true);
143
- state.zIndex = ++_zIndex;
144
- if (props.destroyOnClose) {
145
- state.showSlot = true;
146
- }
147
- emit("open");
148
152
  };
149
153
  const close = () => {
150
- emit("update:visible", false);
151
- emit("close");
152
- if (props.destroyOnClose) {
153
- setTimeout(() => {
154
- state.showSlot = false;
155
- }, +props.duration * 1e3);
154
+ if (opened) {
155
+ opened = false;
156
+ emit("update:visible", false);
157
+ emit("close");
158
+ if (props.destroyOnClose) {
159
+ setTimeout(() => {
160
+ state.showSlot = false;
161
+ }, +props.duration * 1e3);
162
+ }
156
163
  }
157
164
  };
158
165
  const onClick = (e) => {
@@ -161,12 +168,12 @@ const _sfc_main = create({
161
168
  const onClickCloseIcon = (e) => {
162
169
  e.stopPropagation();
163
170
  emit("clickCloseIcon", e);
164
- emit("update:visible", false);
171
+ close();
165
172
  };
166
173
  const onClickOverlay = (e) => {
167
174
  emit("clickOverlay", e);
168
175
  if (props.closeOnClickOverlay) {
169
- emit("update:visible", false);
176
+ close();
170
177
  }
171
178
  };
172
179
  const onOpened = (el) => {
@@ -178,7 +185,12 @@ const _sfc_main = create({
178
185
  watch(
179
186
  () => props.visible,
180
187
  () => {
181
- props.visible ? open() : close();
188
+ if (props.visible && !opened) {
189
+ open();
190
+ }
191
+ if (!props.visible && opened) {
192
+ close();
193
+ }
182
194
  }
183
195
  );
184
196
  watchEffect(() => {
@@ -3,7 +3,7 @@ import { c as createComponent } from "./component-TCzwHGVq.js";
3
3
  import { CheckNormal, CheckChecked } from "@nutui/icons-vue";
4
4
  import { p as pxCheck } from "./pxCheck-OnXlN1NC.js";
5
5
  import { R as RADIO_KEY } from "./types-odSRziQJ.js";
6
- import { u as useFormDisabled } from "./common-LvGbU-A3.js";
6
+ import { u as useFormDisabled } from "./common-FZL3qC99.js";
7
7
  const { componentName, create } = createComponent("radio");
8
8
  const _sfc_main = create({
9
9
  components: {
@@ -17,17 +17,17 @@ var __spreadValues = (a, b) => {
17
17
  import { toRef, ref, reactive, computed, watch, onMounted, h, resolveComponent, openBlock, createElementBlock, normalizeClass, createElementVNode, renderSlot, createCommentVNode, createBlock, resolveDynamicComponent, normalizeStyle, toDisplayString, createTextVNode, withDirectives, createVNode, mergeProps, vShow } from "vue";
18
18
  import { MaskClose } from "@nutui/icons-vue";
19
19
  import { c as createComponent } from "../component-TCzwHGVq.js";
20
- import { u as useFormDisabled } from "../common-LvGbU-A3.js";
20
+ import { u as useFormDisabled } from "../common-FZL3qC99.js";
21
21
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
22
22
  function trimExtraChar(value, char, regExp) {
23
- const index2 = value.indexOf(char);
24
- if (index2 === -1) {
23
+ const index = value.indexOf(char);
24
+ if (index === -1) {
25
25
  return value;
26
26
  }
27
- if (char === "-" && index2 !== 0) {
28
- return value.slice(0, index2);
27
+ if (char === "-" && index !== 0) {
28
+ return value.slice(0, index);
29
29
  }
30
- return value.slice(0, index2 + 1) + value.slice(index2).replace(regExp, "");
30
+ return value.slice(0, index + 1) + value.slice(index).replace(regExp, "");
31
31
  }
32
32
  function formatNumber(value, allowDot = true, allowMinus = true) {
33
33
  if (allowDot) {
@@ -375,7 +375,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
375
375
  ])
376
376
  ], 2);
377
377
  }
378
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
378
+ const NutInput = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
379
379
  export {
380
- index as default
380
+ NutInput as default
381
381
  };