@nutui/nutui 4.0.10-beta.1 → 4.0.10

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 (160) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/nutui.es.js +1 -1
  3. package/dist/nutui.js +6550 -8291
  4. package/dist/nutui.umd.js +1 -1
  5. package/dist/packages/_es/ActionSheet.js +78 -111
  6. package/dist/packages/_es/Address.js +250 -375
  7. package/dist/packages/_es/AddressList.js +269 -354
  8. package/dist/packages/_es/Animate.js +41 -58
  9. package/dist/packages/_es/Audio.js +128 -197
  10. package/dist/packages/_es/AudioOperate.js +60 -71
  11. package/dist/packages/_es/Avatar.js +66 -89
  12. package/dist/packages/_es/AvatarGroup.js +23 -31
  13. package/dist/packages/_es/Backtop.js +59 -99
  14. package/dist/packages/_es/Badge.js +36 -47
  15. package/dist/packages/_es/Barrage.js +68 -147
  16. package/dist/packages/_es/Button.js +47 -66
  17. package/dist/packages/_es/Calendar.js +135 -157
  18. package/dist/packages/_es/CalendarItem.js +6 -6
  19. package/dist/packages/_es/Card.js +42 -56
  20. package/dist/packages/_es/Cascader.js +315 -474
  21. package/dist/packages/_es/Category.js +29 -39
  22. package/dist/packages/_es/CategoryPane.js +57 -83
  23. package/dist/packages/_es/Cell.js +56 -71
  24. package/dist/packages/_es/CellGroup.js +19 -27
  25. package/dist/packages/_es/Checkbox.js +109 -156
  26. package/dist/packages/_es/CheckboxGroup.js +38 -59
  27. package/dist/packages/_es/CircleProgress.js +67 -96
  28. package/dist/packages/_es/Col.js +23 -31
  29. package/dist/packages/_es/Collapse.js +33 -58
  30. package/dist/packages/_es/CollapseItem.js +78 -108
  31. package/dist/packages/_es/Comment.js +207 -279
  32. package/dist/packages/_es/ConfigProvider.js +37 -55
  33. package/dist/packages/_es/Countdown.js +100 -212
  34. package/dist/packages/_es/Countup.js +232 -445
  35. package/dist/packages/_es/DatePicker.js +162 -265
  36. package/dist/packages/_es/Dialog.js +161 -213
  37. package/dist/packages/_es/Divider.js +42 -57
  38. package/dist/packages/_es/Drag.js +70 -153
  39. package/dist/packages/_es/Ecard.js +64 -104
  40. package/dist/packages/_es/Elevator.js +143 -219
  41. package/dist/packages/_es/Ellipsis.js +95 -178
  42. package/dist/packages/_es/Empty.js +23 -39
  43. package/dist/packages/_es/FixedNav.js +93 -116
  44. package/dist/packages/_es/Form.js +107 -178
  45. package/dist/packages/_es/FormItem.js +48 -61
  46. package/dist/packages/_es/Grid.js +5 -6
  47. package/dist/packages/_es/GridItem.js +58 -84
  48. package/dist/packages/_es/Image.js +90 -129
  49. package/dist/packages/_es/ImagePreview.js +256 -412
  50. package/dist/packages/_es/Indicator.js +30 -34
  51. package/dist/packages/_es/InfiniteLoading.js +83 -136
  52. package/dist/packages/_es/Input.js +160 -264
  53. package/dist/packages/_es/InputNumber.js +81 -117
  54. package/dist/packages/_es/Interceptor-6e26b757.js +18 -0
  55. package/dist/packages/_es/Invoice.js +104 -130
  56. package/dist/packages/_es/Layout.js +3 -4
  57. package/dist/packages/_es/List.js +117 -215
  58. package/dist/packages/_es/Menu.js +95 -150
  59. package/dist/packages/_es/MenuItem.js +109 -154
  60. package/dist/packages/_es/Navbar.js +103 -119
  61. package/dist/packages/_es/Noticebar.js +197 -312
  62. package/dist/packages/_es/Notify.js +110 -166
  63. package/dist/packages/_es/NumberKeyboard.js +127 -202
  64. package/dist/packages/_es/Overlay.js +52 -80
  65. package/dist/packages/_es/Pagination.js +70 -100
  66. package/dist/packages/_es/Picker.js +275 -437
  67. package/dist/packages/_es/Popover.js +122 -225
  68. package/dist/packages/_es/Popup.js +4 -4
  69. package/dist/packages/_es/Price.js +44 -82
  70. package/dist/packages/_es/Progress.js +63 -79
  71. package/dist/packages/_es/PullRefresh.js +95 -173
  72. package/dist/packages/_es/Radio.js +4 -4
  73. package/dist/packages/_es/RadioGroup.js +3 -3
  74. package/dist/packages/_es/Range.js +204 -347
  75. package/dist/packages/_es/Rate.js +92 -141
  76. package/dist/packages/_es/Row.js +21 -27
  77. package/dist/packages/_es/Searchbar.js +123 -174
  78. package/dist/packages/_es/ShortPassword.js +69 -93
  79. package/dist/packages/_es/SideNavbar.js +49 -80
  80. package/dist/packages/_es/SideNavbarItem.js +22 -32
  81. package/dist/packages/_es/Signature.js +83 -146
  82. package/dist/packages/_es/Skeleton.js +110 -130
  83. package/dist/packages/_es/Sku.js +250 -343
  84. package/dist/packages/_es/Step.js +59 -86
  85. package/dist/packages/_es/Steps.js +26 -31
  86. package/dist/packages/_es/Sticky.js +4 -4
  87. package/dist/packages/_es/SubSideNavbar.js +52 -74
  88. package/dist/packages/_es/Swipe.js +83 -155
  89. package/dist/packages/_es/Swiper.js +174 -311
  90. package/dist/packages/_es/SwiperItem.js +28 -44
  91. package/dist/packages/_es/Switch.js +55 -68
  92. package/dist/packages/_es/TabPane.js +30 -41
  93. package/dist/packages/_es/Tabbar.js +41 -52
  94. package/dist/packages/_es/TabbarItem.js +61 -82
  95. package/dist/packages/_es/Table.js +109 -165
  96. package/dist/packages/_es/Tabs.js +240 -388
  97. package/dist/packages/_es/Tag.js +44 -61
  98. package/dist/packages/_es/Textarea.js +80 -124
  99. package/dist/packages/_es/TimeDetail.js +49 -76
  100. package/dist/packages/_es/TimePannel.js +34 -48
  101. package/dist/packages/_es/TimeSelect.js +47 -68
  102. package/dist/packages/_es/Toast.js +144 -218
  103. package/dist/packages/_es/Tour.js +138 -192
  104. package/dist/packages/_es/TrendArrow.js +57 -77
  105. package/dist/packages/_es/Uploader.js +234 -359
  106. package/dist/packages/_es/Video.js +191 -316
  107. package/dist/packages/_es/Watermark.js +84 -117
  108. package/dist/packages/_es/_plugin-vue_export-helper-dad06003.js +9 -0
  109. package/dist/packages/_es/common-d218746f.js +116 -0
  110. package/dist/packages/_es/component-234624bc.js +89 -0
  111. package/dist/packages/_es/index-14dfadc4.js +561 -0
  112. package/dist/packages/_es/index-192a3ef6.js +29 -0
  113. package/dist/packages/_es/index-360c5092.js +210 -0
  114. package/dist/packages/_es/index-496e6e05.js +24 -0
  115. package/dist/packages/_es/index-50eed3d9.js +7 -0
  116. package/dist/packages/_es/index-53ec2d4d.js +34 -0
  117. package/dist/packages/_es/index-fadb0974.js +8 -0
  118. package/dist/packages/_es/index.vue_vue_type_script_lang-1139b29a.js +43 -0
  119. package/dist/packages/_es/index.vue_vue_type_script_lang-43b774dd.js +77 -0
  120. package/dist/packages/_es/index.vue_vue_type_script_lang-f44c159d.js +110 -0
  121. package/dist/packages/_es/mountComponent-6d4ff200.js +23 -0
  122. package/dist/packages/_es/pxCheck-38173291.js +4 -0
  123. package/dist/packages/_es/raf-a74f1a06.js +16 -0
  124. package/dist/packages/_es/renderIcon-47498b32.js +5 -0
  125. package/dist/smartips/web-types.json +1 -1
  126. package/dist/style.css +1 -1
  127. package/dist/styles/themes/default.scss +154 -51
  128. package/dist/styles/themes/jdb.scss +154 -51
  129. package/dist/styles/themes/jddkh.scss +154 -51
  130. package/dist/styles/themes/jdt.scss +154 -51
  131. package/dist/types/__VUE/address/index.vue.d.ts +1 -1
  132. package/dist/types/__VUE/collapseitem/index.vue.d.ts +110 -3
  133. package/dist/types/__VUE/image/index.vue.d.ts +2 -2
  134. package/dist/types/__VUE/rate/index.vue.d.ts +110 -3
  135. package/dist/types/__VUE/searchbar/index.vue.d.ts +110 -3
  136. package/dist/types/__VUE/skeleton/index.vue.d.ts +2 -2
  137. package/dist/types/__VUE/swiper/index.vue.d.ts +1 -1
  138. package/dist/types/__VUE/table/common.d.ts +55 -2
  139. package/dist/types/__VUE/timeselect/index.vue.d.ts +1 -1
  140. package/dist/types/__VUE/watermark/index.vue.d.ts +1 -1
  141. package/dist/types/index.d.ts +1 -1
  142. package/package.json +2 -2
  143. package/dist/packages/_es/Interceptor-956b24fc.js +0 -29
  144. package/dist/packages/_es/_plugin-vue_export-helper-cc2b3d55.js +0 -10
  145. package/dist/packages/_es/common-b9a5e726.js +0 -145
  146. package/dist/packages/_es/component-81a4c1d0.js +0 -145
  147. package/dist/packages/_es/index-29892cda.js +0 -33
  148. package/dist/packages/_es/index-43c34ac6.js +0 -30
  149. package/dist/packages/_es/index-54d03fc1.js +0 -8
  150. package/dist/packages/_es/index-79c5dc33.js +0 -10
  151. package/dist/packages/_es/index-7a7385e4.js +0 -67
  152. package/dist/packages/_es/index-87422be8.js +0 -942
  153. package/dist/packages/_es/index-da0a7662.js +0 -259
  154. package/dist/packages/_es/index.vue_vue_type_script_lang-22dfc112.js +0 -46
  155. package/dist/packages/_es/index.vue_vue_type_script_lang-442e4704.js +0 -98
  156. package/dist/packages/_es/index.vue_vue_type_script_lang-cc5c4086.js +0 -151
  157. package/dist/packages/_es/mountComponent-8b24c346.js +0 -39
  158. package/dist/packages/_es/pxCheck-c6b9f6b7.js +0 -6
  159. package/dist/packages/_es/raf-729dad54.js +0 -25
  160. package/dist/packages/_es/renderIcon-3d0fd47c.js +0 -9
@@ -1,16 +1,15 @@
1
- import { resolveComponent, openBlock, createElementBlock, createElementVNode, createCommentVNode, normalizeClass, toDisplayString, renderSlot, createVNode, ref, watch, onMounted, Fragment, renderList, createBlock, computed, withCtx, normalizeStyle, createTextVNode } from "vue";
2
- import { c as createComponent } from "./component-81a4c1d0.js";
3
- import { Right, Fabulous, Comment, MoreX } from "@nutui/icons-vue";
4
- import Rate from "./Rate.js";
5
- import { _ as _export_sfc } from "./_plugin-vue_export-helper-cc2b3d55.js";
1
+ import { resolveComponent as g, openBlock as t, createElementBlock as l, createElementVNode as i, createCommentVNode as m, normalizeClass as d, toDisplayString as p, renderSlot as $, createVNode as y, ref as C, watch as T, onMounted as S, Fragment as v, renderList as b, createBlock as I, computed as O, withCtx as z, normalizeStyle as E, createTextVNode as F } from "vue";
2
+ import { c as w } from "./component-234624bc.js";
3
+ import { Right as R, Fabulous as H, Comment as A, MoreX as M } from "@nutui/icons-vue";
4
+ import N from "./Rate.js";
5
+ import { _ } from "./_plugin-vue_export-helper-dad06003.js";
6
6
  import "../locale/lang";
7
- import "./renderIcon-3d0fd47c.js";
8
- import "./pxCheck-c6b9f6b7.js";
9
- import "./index-7a7385e4.js";
10
- const { componentName: componentName$3, create: create$3 } = createComponent("comment-header");
11
- const _sfc_main$3 = create$3({
7
+ import "./renderIcon-47498b32.js";
8
+ import "./pxCheck-38173291.js";
9
+ import "./index-53ec2d4d.js";
10
+ const { componentName: Ve, create: U } = w("comment-header"), j = U({
12
11
  components: {
13
- [Rate.name]: Rate
12
+ [N.name]: N
14
13
  },
15
14
  props: {
16
15
  type: {
@@ -29,91 +28,83 @@ const _sfc_main$3 = create$3({
29
28
  }
30
29
  },
31
30
  emits: ["handleClick"],
32
- setup(props, { emit }) {
33
- const handleClick = () => {
34
- emit("handleClick");
35
- };
36
- return { handleClick };
31
+ setup(e, { emit: n }) {
32
+ return { handleClick: () => {
33
+ n("handleClick");
34
+ } };
37
35
  }
38
- });
39
- const _hoisted_1$3 = { class: "nut-comment-header__user" };
40
- const _hoisted_2$3 = { class: "nut-comment-header__user-avter" };
41
- const _hoisted_3$3 = ["src"];
42
- const _hoisted_4$3 = { class: "nut-comment-header__user-score" };
43
- const _hoisted_5$1 = {
36
+ }), B = { class: "nut-comment-header__user" }, L = { class: "nut-comment-header__user-avter" }, X = ["src"], P = { class: "nut-comment-header__user-score" }, D = {
44
37
  key: 0,
45
38
  class: "nut-comment-header__time"
46
39
  };
47
- function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
48
- const _component_nut_rate = resolveComponent("nut-rate");
49
- return openBlock(), createElementBlock("view", null, [
50
- _ctx.info ? (openBlock(), createElementBlock("view", {
40
+ function q(e, n, r, u, f, h) {
41
+ const s = g("nut-rate");
42
+ return t(), l("view", null, [
43
+ e.info ? (t(), l("view", {
51
44
  key: 0,
52
45
  class: "nut-comment-header",
53
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
46
+ onClick: n[1] || (n[1] = (...o) => e.handleClick && e.handleClick(...o))
54
47
  }, [
55
- createElementVNode("view", _hoisted_1$3, [
56
- createElementVNode("view", _hoisted_2$3, [
57
- _ctx.info.avatar ? (openBlock(), createElementBlock("img", {
48
+ i("view", B, [
49
+ i("view", L, [
50
+ e.info.avatar ? (t(), l("img", {
58
51
  key: 0,
59
- src: _ctx.info.avatar
60
- }, null, 8, _hoisted_3$3)) : createCommentVNode("", true)
52
+ src: e.info.avatar
53
+ }, null, 8, X)) : m("", !0)
61
54
  ]),
62
- _ctx.type == "default" ? (openBlock(), createElementBlock("view", {
55
+ e.type == "default" ? (t(), l("view", {
63
56
  key: 0,
64
- class: normalizeClass([`nut-comment-header__user-${_ctx.type}`])
57
+ class: d([`nut-comment-header__user-${e.type}`])
65
58
  }, [
66
- createElementVNode("view", {
67
- class: normalizeClass([`nut-comment-header__user-${_ctx.type}-name`])
59
+ i("view", {
60
+ class: d([`nut-comment-header__user-${e.type}-name`])
68
61
  }, [
69
- createElementVNode("span", null, toDisplayString(_ctx.info.nickName), 1),
70
- renderSlot(_ctx.$slots, "labels")
62
+ i("span", null, p(e.info.nickName), 1),
63
+ $(e.$slots, "labels")
71
64
  ], 2),
72
- createElementVNode("view", _hoisted_4$3, [
73
- createVNode(_component_nut_rate, {
74
- modelValue: _ctx.info.score,
75
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.info.score = $event),
65
+ i("view", P, [
66
+ y(s, {
67
+ modelValue: e.info.score,
68
+ "onUpdate:modelValue": n[0] || (n[0] = (o) => e.info.score = o),
76
69
  size: "12",
77
70
  spacing: "5",
78
71
  readonly: "",
79
- onChange: _ctx.handleClick
72
+ onChange: e.handleClick
80
73
  }, null, 8, ["modelValue", "onChange"])
81
74
  ])
82
- ], 2)) : (openBlock(), createElementBlock("view", {
75
+ ], 2)) : (t(), l("view", {
83
76
  key: 1,
84
- class: normalizeClass([`nut-comment-header__user-${_ctx.type}`])
77
+ class: d([`nut-comment-header__user-${e.type}`])
85
78
  }, [
86
- createElementVNode("span", {
87
- class: normalizeClass([`nut-comment-header__user-${_ctx.type}-name`])
88
- }, toDisplayString(_ctx.info.nickName), 3),
89
- renderSlot(_ctx.$slots, "labels")
79
+ i("span", {
80
+ class: d([`nut-comment-header__user-${e.type}-name`])
81
+ }, p(e.info.nickName), 3),
82
+ $(e.$slots, "labels")
90
83
  ], 2))
91
84
  ]),
92
- _ctx.info.time ? (openBlock(), createElementBlock("view", _hoisted_5$1, toDisplayString(_ctx.info.time), 1)) : createCommentVNode("", true)
93
- ])) : createCommentVNode("", true),
94
- _ctx.type == "complex" ? (openBlock(), createElementBlock("view", {
85
+ e.info.time ? (t(), l("view", D, p(e.info.time), 1)) : m("", !0)
86
+ ])) : m("", !0),
87
+ e.type == "complex" ? (t(), l("view", {
95
88
  key: 1,
96
- class: normalizeClass([`nut-comment-header__${_ctx.type}-score`])
89
+ class: d([`nut-comment-header__${e.type}-score`])
97
90
  }, [
98
- createVNode(_component_nut_rate, {
99
- modelValue: _ctx.info.score,
100
- "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.info.score = $event),
91
+ y(s, {
92
+ modelValue: e.info.score,
93
+ "onUpdate:modelValue": n[2] || (n[2] = (o) => e.info.score = o),
101
94
  size: "12",
102
95
  spacing: "3",
103
96
  readonly: ""
104
97
  }, null, 8, ["modelValue"]),
105
- createElementVNode("i", {
106
- class: normalizeClass([`nut-comment-header__${_ctx.type}-score-i`])
98
+ i("i", {
99
+ class: d([`nut-comment-header__${e.type}-score-i`])
107
100
  }, null, 2),
108
- createElementVNode("view", {
109
- class: normalizeClass([`nut-comment-header__${_ctx.type}-score-size`])
110
- }, toDisplayString(_ctx.info.size), 3)
111
- ], 2)) : createCommentVNode("", true)
101
+ i("view", {
102
+ class: d([`nut-comment-header__${e.type}-score-size`])
103
+ }, p(e.info.size), 3)
104
+ ], 2)) : m("", !0)
112
105
  ]);
113
106
  }
114
- const CommentHeader = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$3]]);
115
- const { componentName: componentName$2, create: create$2 } = createComponent("comment-images");
116
- const _sfc_main$2 = create$2({
107
+ const G = /* @__PURE__ */ _(j, [["render", q]]), { componentName: Te, create: J } = w("comment-images"), K = J({
117
108
  props: {
118
109
  type: {
119
110
  type: String,
@@ -129,94 +120,70 @@ const _sfc_main$2 = create$2({
129
120
  default: () => []
130
121
  }
131
122
  },
132
- components: { Right },
123
+ components: { Right: R },
133
124
  emits: ["click", "clickImages"],
134
- setup(props, { emit }) {
135
- const isShowImage = ref(false);
136
- const initIndex = ref(1);
137
- const totalImages = ref([]);
138
- watch(
139
- () => [props.videos, props.images],
140
- (value) => {
141
- if (value[0].length > 0) {
142
- value[0].forEach((el) => {
143
- el.type = "video";
144
- });
145
- }
146
- totalImages.value = value[0].concat(value[1]);
125
+ setup(e, { emit: n }) {
126
+ const r = C(!1), u = C(1), f = C([]);
127
+ return T(
128
+ () => [e.videos, e.images],
129
+ (s) => {
130
+ s[0].length > 0 && s[0].forEach((o) => {
131
+ o.type = "video";
132
+ }), f.value = s[0].concat(s[1]);
147
133
  },
148
- { deep: true }
149
- );
150
- onMounted(() => {
151
- if (props.videos.length > 0) {
152
- props.videos.forEach((el) => {
153
- el.type = "video";
154
- });
155
- }
156
- totalImages.value = props.videos.concat(props.images);
157
- });
158
- const showImages = (type, index2) => {
159
- const { videos, images } = props;
160
- const i = type == "img" ? index2 - videos.length : index2;
161
- emit("clickImages", {
162
- type,
163
- index: i,
164
- value: type == "img" ? images[i] : videos[i]
134
+ { deep: !0 }
135
+ ), S(() => {
136
+ e.videos.length > 0 && e.videos.forEach((s) => {
137
+ s.type = "video";
138
+ }), f.value = e.videos.concat(e.images);
139
+ }), { isShowImage: r, initIndex: u, showImages: (s, o) => {
140
+ const { videos: c, images: a } = e, k = s == "img" ? o - c.length : o;
141
+ n("clickImages", {
142
+ type: s,
143
+ index: k,
144
+ value: s == "img" ? a[k] : c[k]
165
145
  });
166
- };
167
- return { isShowImage, initIndex, showImages, totalImages };
146
+ }, totalImages: f };
168
147
  }
169
- });
170
- const _hoisted_1$2 = ["onClick"];
171
- const _hoisted_2$2 = ["src"];
172
- const _hoisted_3$2 = /* @__PURE__ */ createElementVNode("view", { class: "nut-comment-images__play" }, null, -1);
173
- const _hoisted_4$2 = ["onClick"];
174
- const _hoisted_5 = ["src"];
175
- const _hoisted_6 = {
148
+ }), Q = ["onClick"], W = ["src"], Y = /* @__PURE__ */ i("view", { class: "nut-comment-images__play" }, null, -1), Z = ["onClick"], x = ["src"], ee = {
176
149
  key: 0,
177
150
  class: "nut-comment-images__mask"
178
151
  };
179
- function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
180
- const _component_Right = resolveComponent("Right");
181
- return openBlock(), createElementBlock("view", {
182
- class: normalizeClass(`nut-comment-images nut-comment-images--${_ctx.type}`)
152
+ function oe(e, n, r, u, f, h) {
153
+ const s = g("Right");
154
+ return t(), l("view", {
155
+ class: d(`nut-comment-images nut-comment-images--${e.type}`)
183
156
  }, [
184
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.videos, (itV, index2) => {
185
- return openBlock(), createElementBlock("view", {
186
- class: "nut-comment-images__item nut-comment-images__item--video",
187
- key: itV.id,
188
- onClick: ($event) => _ctx.showImages("video", index2)
189
- }, [
190
- createElementVNode("img", {
191
- src: itV.mainUrl
192
- }, null, 8, _hoisted_2$2),
193
- _hoisted_3$2
194
- ], 8, _hoisted_1$2);
195
- }), 128)),
196
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.images, (itI, index2) => {
197
- return openBlock(), createElementBlock(Fragment, {
198
- key: itI.id
157
+ (t(!0), l(v, null, b(e.videos, (o, c) => (t(), l("view", {
158
+ class: "nut-comment-images__item nut-comment-images__item--video",
159
+ key: o.id,
160
+ onClick: (a) => e.showImages("video", c)
161
+ }, [
162
+ i("img", {
163
+ src: o.mainUrl
164
+ }, null, 8, W),
165
+ Y
166
+ ], 8, Q))), 128)),
167
+ (t(!0), l(v, null, b(e.images, (o, c) => (t(), l(v, {
168
+ key: o.id
169
+ }, [
170
+ e.type == "multi" && e.videos.length + c < 9 || e.type != "multi" ? (t(), l("view", {
171
+ key: 0,
172
+ class: "nut-comment-images__item nut-comment-images__item--imgbox",
173
+ onClick: (a) => e.showImages("img", c + e.videos.length)
199
174
  }, [
200
- _ctx.type == "multi" && _ctx.videos.length + index2 < 9 || _ctx.type != "multi" ? (openBlock(), createElementBlock("view", {
201
- key: 0,
202
- class: "nut-comment-images__item nut-comment-images__item--imgbox",
203
- onClick: ($event) => _ctx.showImages("img", index2 + _ctx.videos.length)
204
- }, [
205
- createElementVNode("img", {
206
- src: itI.smallImgUrl ? itI.smallImgUrl : itI.imgUrl
207
- }, null, 8, _hoisted_5),
208
- _ctx.type == "multi" && _ctx.totalImages.length > 9 && _ctx.videos.length + index2 > 7 ? (openBlock(), createElementBlock("view", _hoisted_6, [
209
- createElementVNode("span", null, "共 " + toDisplayString(_ctx.totalImages.length) + " 张", 1),
210
- createVNode(_component_Right, { style: { "width": "12px" } })
211
- ])) : createCommentVNode("", true)
212
- ], 8, _hoisted_4$2)) : createCommentVNode("", true)
213
- ], 64);
214
- }), 128))
175
+ i("img", {
176
+ src: o.smallImgUrl ? o.smallImgUrl : o.imgUrl
177
+ }, null, 8, x),
178
+ e.type == "multi" && e.totalImages.length > 9 && e.videos.length + c > 7 ? (t(), l("view", ee, [
179
+ i("span", null, "共 " + p(e.totalImages.length) + " 张", 1),
180
+ y(s, { style: { width: "12px" } })
181
+ ])) : m("", !0)
182
+ ], 8, Z)) : m("", !0)
183
+ ], 64))), 128))
215
184
  ], 2);
216
185
  }
217
- const CommentImages = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$2]]);
218
- const { componentName: componentName$1, create: create$1, translate: translate$1 } = createComponent("comment-bottom");
219
- const _sfc_main$1 = create$1({
186
+ const ne = /* @__PURE__ */ _(K, [["render", oe]]), { componentName: ze, create: te, translate: se } = w("comment-bottom"), le = te({
220
187
  props: {
221
188
  type: {
222
189
  type: String,
@@ -232,75 +199,54 @@ const _sfc_main$1 = create$1({
232
199
  default: ["replay", "like", "more"]
233
200
  }
234
201
  },
235
- components: { Fabulous, Comment, MoreX },
202
+ components: { Fabulous: H, Comment: A, MoreX: M },
236
203
  emits: ["clickOperate", "handleClick"],
237
- setup(props, { emit }) {
238
- const showPopver = ref(false);
239
- const mergeOp = ref([]);
240
- onMounted(() => {
241
- const deOp = ["replay", "like", "more"];
242
- if (props.operation) {
243
- props.operation.forEach((name) => {
244
- if (deOp.includes(name)) {
245
- mergeOp.value.push(name);
246
- }
247
- });
248
- }
249
- });
250
- const operate = (type) => {
251
- if (type == "more") {
252
- showPopver.value = !showPopver.value;
253
- }
254
- emit("clickOperate", type);
255
- };
256
- const handleClick = () => {
257
- emit("handleClick");
258
- };
259
- return { showPopver, operate, mergeOp, handleClick, translate: translate$1 };
204
+ setup(e, { emit: n }) {
205
+ const r = C(!1), u = C([]);
206
+ return S(() => {
207
+ const s = ["replay", "like", "more"];
208
+ e.operation && e.operation.forEach((o) => {
209
+ s.includes(o) && u.value.push(o);
210
+ });
211
+ }), { showPopver: r, operate: (s) => {
212
+ s == "more" && (r.value = !r.value), n("clickOperate", s);
213
+ }, mergeOp: u, handleClick: () => {
214
+ n("handleClick");
215
+ }, translate: se };
260
216
  }
261
- });
262
- const _hoisted_1$1 = { class: "nut-comment-bottom" };
263
- const _hoisted_2$1 = { key: 0 };
264
- const _hoisted_3$1 = { class: "nut-comment-bottom__cpx" };
265
- const _hoisted_4$1 = ["onClick"];
266
- function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
267
- const _component_Fabulous = resolveComponent("Fabulous");
268
- const _component_Comment = resolveComponent("Comment");
269
- const _component_MoreX = resolveComponent("MoreX");
270
- return openBlock(), createElementBlock("view", _hoisted_1$1, [
271
- createElementVNode("view", {
272
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)),
217
+ }), ie = { class: "nut-comment-bottom" }, ae = { key: 0 }, me = { class: "nut-comment-bottom__cpx" }, re = ["onClick"];
218
+ function ce(e, n, r, u, f, h) {
219
+ const s = g("Fabulous"), o = g("Comment"), c = g("MoreX");
220
+ return t(), l("view", ie, [
221
+ i("view", {
222
+ onClick: n[0] || (n[0] = (...a) => e.handleClick && e.handleClick(...a)),
273
223
  class: "nut-comment-bottom__lable"
274
224
  }, [
275
- _ctx.type != "complex" ? (openBlock(), createElementBlock("span", _hoisted_2$1, toDisplayString(_ctx.info.size), 1)) : createCommentVNode("", true)
225
+ e.type != "complex" ? (t(), l("span", ae, p(e.info.size), 1)) : m("", !0)
276
226
  ]),
277
- createElementVNode("view", _hoisted_3$1, [
278
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.mergeOp, (name, i) => {
279
- return openBlock(), createElementBlock("view", {
280
- key: i,
281
- class: normalizeClass(["nut-comment-bottom__cpx-item", `nut-comment-bottom__cpx-item--${name}`]),
282
- onClick: ($event) => _ctx.operate(name)
283
- }, [
284
- name != "more" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
285
- createElementVNode("span", null, toDisplayString(_ctx.info[name]), 1),
286
- name == "like" ? (openBlock(), createBlock(_component_Fabulous, { key: 0 })) : (openBlock(), createBlock(_component_Comment, { key: 1 }))
287
- ], 64)) : createCommentVNode("", true),
288
- name == "more" ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
289
- createVNode(_component_MoreX),
290
- _ctx.showPopver ? (openBlock(), createElementBlock("view", {
291
- key: 0,
292
- class: "nut-comment-bottom__cpx-item-popover",
293
- onClick: _cache[1] || (_cache[1] = ($event) => _ctx.operate("popover"))
294
- }, toDisplayString(_ctx.translate("complaintsText")), 1)) : createCommentVNode("", true)
295
- ], 64)) : createCommentVNode("", true)
296
- ], 10, _hoisted_4$1);
297
- }), 128))
227
+ i("view", me, [
228
+ (t(!0), l(v, null, b(e.mergeOp, (a, k) => (t(), l("view", {
229
+ key: k,
230
+ class: d(["nut-comment-bottom__cpx-item", `nut-comment-bottom__cpx-item--${a}`]),
231
+ onClick: (V) => e.operate(a)
232
+ }, [
233
+ a != "more" ? (t(), l(v, { key: 0 }, [
234
+ i("span", null, p(e.info[a]), 1),
235
+ a == "like" ? (t(), I(s, { key: 0 })) : (t(), I(o, { key: 1 }))
236
+ ], 64)) : m("", !0),
237
+ a == "more" ? (t(), l(v, { key: 1 }, [
238
+ y(c),
239
+ e.showPopver ? (t(), l("view", {
240
+ key: 0,
241
+ class: "nut-comment-bottom__cpx-item-popover",
242
+ onClick: n[1] || (n[1] = (V) => e.operate("popover"))
243
+ }, p(e.translate("complaintsText")), 1)) : m("", !0)
244
+ ], 64)) : m("", !0)
245
+ ], 10, re))), 128))
298
246
  ])
299
247
  ]);
300
248
  }
301
- const CommentBottom = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1]]);
302
- const { componentName, create, translate } = createComponent("comment");
303
- const _sfc_main = create({
249
+ const pe = /* @__PURE__ */ _(le, [["render", ce]]), { componentName: ue, create: de, translate: fe } = w("comment"), ke = de({
304
250
  props: {
305
251
  headerType: {
306
252
  type: String,
@@ -314,7 +260,7 @@ const _sfc_main = create({
314
260
  },
315
261
  ellipsis: {
316
262
  type: [String, Number, Boolean],
317
- default: false
263
+ default: !1
318
264
  },
319
265
  videos: {
320
266
  type: Array,
@@ -342,99 +288,81 @@ const _sfc_main = create({
342
288
  }
343
289
  },
344
290
  components: {
345
- CommentHeader,
346
- CommentImages,
347
- CommentBottom,
348
- Right
291
+ CommentHeader: G,
292
+ CommentImages: ne,
293
+ CommentBottom: pe,
294
+ Right: R
349
295
  },
350
296
  emits: ["click", "clickImages", "clickOperate"],
351
- setup(props, { emit }) {
352
- const classes = computed(() => {
353
- const prefixCls = componentName;
354
- return {
355
- [prefixCls]: true
356
- };
357
- });
358
- const conEllipsis = computed(() => {
359
- if (props.ellipsis)
360
- return props.ellipsis;
361
- return props.headerType == "complex" ? 6 : 2;
362
- });
363
- const clickOperate = (t) => {
364
- emit("clickOperate", t);
365
- };
366
- const handleClick = () => {
367
- emit("click", props.info);
368
- };
369
- const clickImages = (value) => {
370
- emit("clickImages", value);
371
- };
372
- return { classes, conEllipsis, clickOperate, handleClick, clickImages, translate };
297
+ setup(e, { emit: n }) {
298
+ const r = O(() => ({
299
+ [ue]: !0
300
+ })), u = O(() => e.ellipsis ? e.ellipsis : e.headerType == "complex" ? 6 : 2);
301
+ return { classes: r, conEllipsis: u, clickOperate: (o) => {
302
+ n("clickOperate", o);
303
+ }, handleClick: () => {
304
+ n("click", e.info);
305
+ }, clickImages: (o) => {
306
+ n("clickImages", o);
307
+ }, translate: fe };
373
308
  }
374
- });
375
- const _hoisted_1 = ["innerHTML"];
376
- const _hoisted_2 = { class: "nut-comment__follow-title" };
377
- const _hoisted_3 = { class: "nut-comment__follow-com" };
378
- const _hoisted_4 = {
309
+ }), ge = ["innerHTML"], ye = { class: "nut-comment__follow-title" }, he = { class: "nut-comment__follow-com" }, ve = {
379
310
  key: 0,
380
311
  class: "nut-comment__follow-img"
381
312
  };
382
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
383
- const _component_comment_header = resolveComponent("comment-header");
384
- const _component_comment_images = resolveComponent("comment-images");
385
- const _component_Right = resolveComponent("Right");
386
- const _component_comment_bottom = resolveComponent("comment-bottom");
387
- return _ctx.info && Object.keys(_ctx.info) ? (openBlock(), createElementBlock("view", {
313
+ function $e(e, n, r, u, f, h) {
314
+ const s = g("comment-header"), o = g("comment-images"), c = g("Right"), a = g("comment-bottom");
315
+ return e.info && Object.keys(e.info) ? (t(), l("view", {
388
316
  key: 0,
389
- class: normalizeClass(_ctx.classes)
317
+ class: d(e.classes)
390
318
  }, [
391
- createVNode(_component_comment_header, {
392
- type: _ctx.headerType,
393
- info: _ctx.info,
394
- labels: _ctx.labels,
395
- onHandleClick: _ctx.handleClick
319
+ y(s, {
320
+ type: e.headerType,
321
+ info: e.info,
322
+ labels: e.labels,
323
+ onHandleClick: e.handleClick
396
324
  }, {
397
- labels: withCtx(() => [
398
- renderSlot(_ctx.$slots, "comment-labels")
325
+ labels: z(() => [
326
+ $(e.$slots, "comment-labels")
399
327
  ]),
400
328
  _: 3
401
329
  }, 8, ["type", "info", "labels", "onHandleClick"]),
402
- renderSlot(_ctx.$slots, "feature"),
403
- createElementVNode("view", {
330
+ $(e.$slots, "feature"),
331
+ i("view", {
404
332
  class: "nut-comment__main",
405
- style: normalizeStyle(`-webkit-line-clamp:${_ctx.conEllipsis}`),
406
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)),
407
- innerHTML: _ctx.info.content
408
- }, null, 12, _hoisted_1),
409
- createVNode(_component_comment_images, {
410
- images: _ctx.images,
411
- videos: _ctx.videos,
412
- type: _ctx.imagesRows,
413
- onClickImages: _ctx.clickImages
333
+ style: E(`-webkit-line-clamp:${e.conEllipsis}`),
334
+ onClick: n[0] || (n[0] = (...k) => e.handleClick && e.handleClick(...k)),
335
+ innerHTML: e.info.content
336
+ }, null, 12, ge),
337
+ y(o, {
338
+ images: e.images,
339
+ videos: e.videos,
340
+ type: e.imagesRows,
341
+ onClickImages: e.clickImages
414
342
  }, null, 8, ["images", "videos", "type", "onClickImages"]),
415
- _ctx.follow && _ctx.follow.days > 0 ? (openBlock(), createElementBlock("view", {
343
+ e.follow && e.follow.days > 0 ? (t(), l("view", {
416
344
  key: 0,
417
345
  class: "nut-comment__follow",
418
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
346
+ onClick: n[1] || (n[1] = (...k) => e.handleClick && e.handleClick(...k))
419
347
  }, [
420
- createElementVNode("view", _hoisted_2, toDisplayString(_ctx.translate("additionalReview", _ctx.follow.days)), 1),
421
- createElementVNode("view", _hoisted_3, toDisplayString(_ctx.follow.content), 1),
422
- _ctx.follow.images && _ctx.follow.images.length > 0 ? (openBlock(), createElementBlock("view", _hoisted_4, [
423
- createTextVNode(toDisplayString(_ctx.translate("additionalImages", _ctx.follow.images.length)) + " ", 1),
424
- createVNode(_component_Right, { width: "12px" })
425
- ])) : createCommentVNode("", true)
426
- ])) : createCommentVNode("", true),
427
- createVNode(_component_comment_bottom, {
428
- type: _ctx.headerType,
429
- info: _ctx.info,
430
- operation: _ctx.operation,
431
- onClickOperate: _ctx.clickOperate,
432
- onHandleClick: _ctx.handleClick
348
+ i("view", ye, p(e.translate("additionalReview", e.follow.days)), 1),
349
+ i("view", he, p(e.follow.content), 1),
350
+ e.follow.images && e.follow.images.length > 0 ? (t(), l("view", ve, [
351
+ F(p(e.translate("additionalImages", e.follow.images.length)) + " ", 1),
352
+ y(c, { width: "12px" })
353
+ ])) : m("", !0)
354
+ ])) : m("", !0),
355
+ y(a, {
356
+ type: e.headerType,
357
+ info: e.info,
358
+ operation: e.operation,
359
+ onClickOperate: e.clickOperate,
360
+ onHandleClick: e.handleClick
433
361
  }, null, 8, ["type", "info", "operation", "onClickOperate", "onHandleClick"]),
434
- renderSlot(_ctx.$slots, "comment-shop-reply")
435
- ], 2)) : createCommentVNode("", true);
362
+ $(e.$slots, "comment-shop-reply")
363
+ ], 2)) : m("", !0);
436
364
  }
437
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
365
+ const Ee = /* @__PURE__ */ _(ke, [["render", $e]]);
438
366
  export {
439
- index as default
367
+ Ee as default
440
368
  };