@das-fed/upf-ui 6.4.0-dev.131 → 6.4.0-dev.133

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 (108) hide show
  1. package/package.json +5 -5
  2. package/packages/business-components/change-pwd/src/hooks/use-changePwd.d.ts +8 -2
  3. package/packages/business-components/process-form/src/hooks/useForm.d.ts +8 -2
  4. package/packages/components/button/index.d.ts +3 -0
  5. package/packages/components/button/index.js +276 -283
  6. package/packages/components/button/index.js.gz +0 -0
  7. package/packages/components/button/src/Index.vue.d.ts +1 -0
  8. package/packages/components/button/style.css +1 -1
  9. package/packages/components/button/style.css.gz +0 -0
  10. package/packages/components/cascader/index.d.ts +9 -9
  11. package/packages/components/cascader/index.js +113 -103
  12. package/packages/components/cascader/index.js.gz +0 -0
  13. package/packages/components/cascader/src/Index.vue.d.ts +1 -1
  14. package/packages/components/cascader/style.css +1 -1
  15. package/packages/components/cascader/style.css.gz +0 -0
  16. package/packages/components/checkbox/index.js +355 -334
  17. package/packages/components/checkbox/index.js.gz +0 -0
  18. package/packages/components/checkbox/src/Index.vue.d.ts +5 -0
  19. package/packages/components/checkbox/style.css +1 -1
  20. package/packages/components/checkbox/style.css.gz +0 -0
  21. package/packages/components/color-picker/index.js +42 -41
  22. package/packages/components/color-picker/index.js.gz +0 -0
  23. package/packages/components/color-picker/style.css +1 -1
  24. package/packages/components/color-picker/style.css.gz +0 -0
  25. package/packages/components/date-picker/index.js +503 -486
  26. package/packages/components/date-picker/index.js.gz +0 -0
  27. package/packages/components/date-picker/style.css +1 -1
  28. package/packages/components/date-picker/style.css.gz +0 -0
  29. package/packages/components/edit-table/index.js +1 -1
  30. package/packages/components/edit-table/index.js.gz +0 -0
  31. package/packages/components/edit-table/style.css +1 -1
  32. package/packages/components/edit-table/style.css.gz +0 -0
  33. package/packages/components/error-overlay-model/index.js +15 -15
  34. package/packages/components/error-overlay-model/index.js.gz +0 -0
  35. package/packages/components/form/hooks/use-form-size.d.ts +3 -0
  36. package/packages/components/form/index.d.ts +12 -2
  37. package/packages/components/form/index.js +62 -69
  38. package/packages/components/form/index.js.gz +0 -0
  39. package/packages/components/form/src/Index.vue.d.ts +9 -0
  40. package/packages/components/form/src/type.d.ts +3 -0
  41. package/packages/components/form/style.css +1 -1
  42. package/packages/components/form-item/index.js +1110 -1082
  43. package/packages/components/form-item/index.js.gz +0 -0
  44. package/packages/components/form-item/src/hooks/use-form.d.ts +13 -3
  45. package/packages/components/form-item/src/type.d.ts +6 -0
  46. package/packages/components/form-item/style.css +1 -1
  47. package/packages/components/form-item/style.css.gz +0 -0
  48. package/packages/components/input/index.js +399 -215
  49. package/packages/components/input/index.js.gz +0 -0
  50. package/packages/components/input/src/constants.d.ts +17 -0
  51. package/packages/components/input/src/hooks/use-overflow-tip.d.ts +13 -0
  52. package/packages/components/input/src/type.d.ts +9 -9
  53. package/packages/components/input/style.css +1 -1
  54. package/packages/components/input/style.css.gz +0 -0
  55. package/packages/components/input-dialog-select/index.js +74 -66
  56. package/packages/components/input-dialog-select/index.js.gz +0 -0
  57. package/packages/components/input-dialog-select/style.css +1 -1
  58. package/packages/components/input-dialog-select/style.css.gz +0 -0
  59. package/packages/components/input-number/index.js +76 -70
  60. package/packages/components/input-number/index.js.gz +0 -0
  61. package/packages/components/input-number/style.css +1 -1
  62. package/packages/components/input-number/style.css.gz +0 -0
  63. package/packages/components/radio/index.js +116 -103
  64. package/packages/components/radio/index.js.gz +0 -0
  65. package/packages/components/radio/src/Index.vue.d.ts +5 -0
  66. package/packages/components/radio/style.css +1 -1
  67. package/packages/components/radio/style.css.gz +0 -0
  68. package/packages/components/select/index.js +92 -88
  69. package/packages/components/select/index.js.gz +0 -0
  70. package/packages/components/select/style.css +1 -1
  71. package/packages/components/select/style.css.gz +0 -0
  72. package/packages/components/select-input/index.js +39 -37
  73. package/packages/components/select-input/index.js.gz +0 -0
  74. package/packages/components/select-input/style.css +1 -1
  75. package/packages/components/select-input/style.css.gz +0 -0
  76. package/packages/components/split-panel/index.js +209 -193
  77. package/packages/components/split-panel/index.js.gz +0 -0
  78. package/packages/components/split-panel/style.css +1 -1
  79. package/packages/components/split-panel/style.css.gz +0 -0
  80. package/packages/components/switch/index.js +45 -29
  81. package/packages/components/switch/index.js.gz +0 -0
  82. package/packages/components/switch/style.css +1 -1
  83. package/packages/components/switch/style.css.gz +0 -0
  84. package/packages/components/table/index.js +1944 -1932
  85. package/packages/components/table/index.js.gz +0 -0
  86. package/packages/components/table/src/Table.vue.d.ts +12 -9
  87. package/packages/components/table/style.css +1 -1
  88. package/packages/components/table/style.css.gz +0 -0
  89. package/packages/components/tree-select/index.js +13 -12
  90. package/packages/components/tree-select/index.js.gz +0 -0
  91. package/packages/components/tree-table/index.js +143 -142
  92. package/packages/components/tree-table/index.js.gz +0 -0
  93. package/packages/components/tree-table/style.css +1 -1
  94. package/packages/components/tree-table/style.css.gz +0 -0
  95. package/packages/components/tree-v2/index.d.ts +16 -2
  96. package/packages/components/tree-v2/index.js +1944 -1920
  97. package/packages/components/tree-v2/index.js.gz +0 -0
  98. package/packages/components/tree-v2/src/App.vue.d.ts +4 -0
  99. package/packages/components/tree-v2/style.css +1 -1
  100. package/packages/components/tree-v2/style.css.gz +0 -0
  101. package/packages/components/upload/index.js +3 -2
  102. package/packages/components/upload/index.js.gz +0 -0
  103. package/packages/components/upload/style.css +1 -1
  104. package/packages/components/upload/style.css.gz +0 -0
  105. package/packages/components/upload/theme/index.d.ts +3 -0
  106. package/packages/components/form-item/src/hooks/useFormLabelWidth.d.ts +0 -6
  107. package/packages/components/input/index.d.ts +0 -124
  108. package/packages/components/input/src/index.vue.d.ts +0 -49
@@ -1,29 +1,30 @@
1
1
  import '@das-fed/upf-ui/packages/components/checkbox/style.css';
2
- import { defineComponent as Z, computed as m, reactive as _, toRefs as ee, watchEffect as ae, watch as le, useSlots as oe, ref as K, onMounted as se, createElementBlock as u, openBlock as o, createBlock as E, createCommentVNode as c, unref as r, mergeProps as P, isRef as U, withCtx as W, withDirectives as y, normalizeStyle as g, renderSlot as w, normalizeClass as n, Fragment as C, renderList as $, createElementVNode as A, createTextVNode as M, toDisplayString as p, createVNode as j } from "vue";
3
- import { withInstall as te } from "@das-fed/upf-utils/with-install/index";
4
- import { CheckboxGroup as ue } from "ant-design-vue/es";
2
+ import { defineComponent as ae, computed as m, reactive as le, toRefs as oe, watchEffect as te, watch as se, useSlots as ue, ref as Q, onMounted as re, createElementBlock as u, openBlock as o, normalizeStyle as y, createBlock as W, createCommentVNode as c, unref as r, mergeProps as U, isRef as A, withCtx as M, withDirectives as g, renderSlot as C, normalizeClass as n, Fragment as $, renderList as B, createElementVNode as j, createTextVNode as N, toDisplayString as p, createVNode as G } from "vue";
3
+ import { withInstall as ie } from "@das-fed/upf-utils/with-install/index";
4
+ import { CheckboxGroup as de } from "ant-design-vue/es";
5
5
  import "ant-design-vue/es/checkbox/style/css";
6
- import { Checkbox as G } from "ant-design-vue";
7
- import { DasAutoRegisterIcon as re, DasIcon as H } from "@das-fed/upf-ui/packages/components/icon/index";
6
+ import { Checkbox as H } from "ant-design-vue";
7
+ import { DasAutoRegisterIcon as ce, DasIcon as J } from "@das-fed/upf-ui/packages/components/icon/index";
8
8
  import { vDasTooltip as x } from "@das-fed/upf-ui/packages/components/text-tooltip/index";
9
- import { useModelValue as J } from "@das-fed/upf-utils/vue";
10
- import { setThemeRule as ie } from "@das-fed/upf-web/packages/theme/index";
11
- const de = { class: "das-ui-checkbox" }, ce = { class: "label" }, ne = ["onClick", "onBlur", "tabindex"], fe = {
9
+ import { useModelValue as K } from "@das-fed/upf-utils/vue";
10
+ import { useFormSize as ne } from "@das-fed/upf-ui/packages/components/form";
11
+ import { setThemeRule as fe } from "@das-fed/upf-web/packages/theme/index";
12
+ const he = { class: "label" }, be = ["onClick", "onBlur", "tabindex"], pe = {
12
13
  key: 0,
13
14
  class: "square-select-icon"
14
- }, be = {
15
+ }, ve = {
15
16
  key: 1,
16
17
  class: "empty-text"
17
- }, he = ["onClick", "tabindex"], pe = {
18
+ }, ke = ["onClick", "tabindex"], me = {
18
19
  key: 6,
19
20
  class: "das-checkbox-error-label-content"
20
- }, ve = {
21
+ }, ye = {
21
22
  key: 0,
22
23
  class: "das-input-error-label"
23
- }, ke = {
24
+ }, ge = {
24
25
  key: 7,
25
26
  class: "das-checkbox-overlay-error-label-content"
26
- }, me = { class: "label" }, ye = /* @__PURE__ */ Z({
27
+ }, xe = { class: "label" }, Te = /* @__PURE__ */ ae({
27
28
  __name: "Index",
28
29
  props: {
29
30
  modelValue: { default: null },
@@ -50,371 +51,391 @@ const de = { class: "das-ui-checkbox" }, ce = { class: "label" }, ne = ["onClick
50
51
  noSetDefaultVal: { type: Boolean, default: !1 }
51
52
  },
52
53
  emits: ["change", "update:modelValue", "update:indeterminate"],
53
- setup(T, { emit: B }) {
54
- re({
54
+ setup(T, { emit: S }) {
55
+ ce({
55
56
  select: import("@das-fed/upf-ui/packages/icons/select")
56
57
  });
57
- const s = T, D = m(() => s.noSetDefaultVal ? "" : "-"), F = _({
58
+ const t = T, z = m(() => t.noSetDefaultVal ? "" : "-"), D = le({
58
59
  checkboxValue: null,
59
60
  isFocus: !1,
60
61
  checkboxLayout: "",
61
62
  checkboxIndeterminate: !1
62
63
  });
63
- let { checkboxValue: t, isFocus: S, checkboxIndeterminate: v } = ee(F);
64
- const z = s.layout, k = B;
65
- ae(() => {
66
- t.value = s.modelValue, v.value = s.indeterminate, s.checkboxType == "default" && s.optionType == "default" && s.modelValue && (v.value = !1);
67
- }), le(t, (e) => {
64
+ let { checkboxValue: s, isFocus: F, checkboxIndeterminate: v } = oe(D);
65
+ const I = t.layout, k = S;
66
+ te(() => {
67
+ s.value = t.modelValue, v.value = t.indeterminate, t.checkboxType == "default" && t.optionType == "default" && t.modelValue && (v.value = !1);
68
+ }), se(s, (e) => {
68
69
  k("update:modelValue", e);
69
70
  });
70
- const f = J(s, "defaultProps"), V = J(s, "options"), b = m(() => V.value.length ? V.value.map((e) => {
71
+ const f = K(t, "defaultProps"), V = K(t, "options"), h = m(() => V.value.length ? V.value.map((e) => {
71
72
  var l;
72
73
  return {
73
74
  value: e[f.value.value],
74
75
  label: e[f.value.label],
75
76
  disabled: e.disabled,
76
77
  isFocus: !1,
77
- checked: (l = s.modelValue) == null ? void 0 : l.includes(e[f.value.value]),
78
+ checked: (l = t.modelValue) == null ? void 0 : l.includes(e[f.value.value]),
78
79
  mutual: e.mutual
79
80
  };
80
- }) : []), N = () => {
81
- v && (v.value = !1, k("update:indeterminate", v.value), k("update:modelValue", t.value)), k("change", t.value);
82
- }, Q = s.disabled, X = b.value.some((e) => !!e.mutual), I = (e, l) => {
83
- if (!Q)
81
+ }) : []), O = () => {
82
+ v && (v.value = !1, k("update:indeterminate", v.value), k("update:modelValue", s.value)), k("change", s.value);
83
+ }, X = t.disabled, Y = h.value.some((e) => !!e.mutual), L = (e, l) => {
84
+ if (!X)
84
85
  if (e == "group") {
85
86
  if (l.disabled) return;
86
- X ? l.mutual ? (b.value.forEach((i) => {
87
+ Y ? l.mutual ? (h.value.forEach((i) => {
87
88
  i.checked = !1;
88
- }), l.checked = !0) : (l.checked = !l.checked, b.value.forEach((i) => {
89
- i.mutual && (i.checked = !b.value.some((a) => a.checked));
90
- })) : l.checked = !l.checked, l.isFocus = !0, t.value = b.value.filter((i) => i.checked).map((i) => i.value), k("change", t.value);
89
+ }), l.checked = !0) : (l.checked = !l.checked, h.value.forEach((i) => {
90
+ i.mutual && (i.checked = !h.value.some((a) => a.checked));
91
+ })) : l.checked = !l.checked, l.isFocus = !0, s.value = h.value.filter((i) => i.checked).map((i) => i.value), k("change", s.value);
91
92
  } else
92
- t.value = !t.value, S.value = !0, k("change", t.value);
93
- }, L = m(() => {
93
+ s.value = !s.value, F.value = !0, k("change", s.value);
94
+ }, R = m(() => {
94
95
  var e, l, i;
95
- if (!s.isView) return [];
96
- if ((!((e = V.value) != null && e.length) || !((l = t.value) != null && l.length)) && s.checkboxType == "group") return [];
97
- if (s.checkboxType == "group")
96
+ if (!t.isView) return [];
97
+ if ((!((e = V.value) != null && e.length) || !((l = s.value) != null && l.length)) && t.checkboxType == "group") return [];
98
+ if (t.checkboxType == "group")
98
99
  return V.value.filter((a) => {
99
- if (t.value.includes(a[f.value.value]))
100
+ if (s.value.includes(a[f.value.value]))
100
101
  return a;
101
102
  });
102
103
  {
103
- if (!t.value) return [];
104
- const a = oe();
104
+ if (!s.value) return [];
105
+ const a = ue();
105
106
  let d = null;
106
107
  return a && a.default && ((i = a.default()) == null ? void 0 : i.length) == 0 && (d = a.default()[0].children), [
107
108
  {
108
- value: t.value,
109
+ value: s.value,
109
110
  label: d
110
111
  }
111
112
  ];
112
113
  }
113
- }), O = (e, l) => {
114
- e == "group" ? l.isFocus = !1 : S.value = !1;
115
- }, Y = m(() => s.maxWidth ? s.maxWidth : s.width), h = m(() => {
116
- let e = `${Number(String(Y.value).split("px")[0])}`;
117
- if (s.maxWidth)
114
+ }), P = (e, l) => {
115
+ e == "group" ? l.isFocus = !1 : F.value = !1;
116
+ }, Z = m(() => t.maxWidth ? t.maxWidth : t.width), b = m(() => {
117
+ let e = `${Number(String(Z.value).split("px")[0])}`;
118
+ if (t.maxWidth)
118
119
  return `max-width:${e}px`;
119
- if (s.width)
120
- return Number(e) > 72 && s.maxWidth ? `width:${e};max-width:${e}px;` : `width:${e}px`;
121
- }), R = K(null);
122
- return se(() => {
120
+ if (t.width)
121
+ return Number(e) > 72 && t.maxWidth ? `width:${e};max-width:${e}px;` : `width:${e}px`;
122
+ }), E = Q(null), _ = () => {
123
123
  setTimeout(() => {
124
124
  var l, i;
125
- const e = (i = (l = R.value) == null ? void 0 : l.$el) == null ? void 0 : i.querySelectorAll(".ant-checkbox-input");
125
+ const e = (i = (l = E.value) == null ? void 0 : l.$el) == null ? void 0 : i.querySelectorAll(".ant-checkbox-input");
126
126
  e && e.length && e.forEach((a) => a.setAttribute("tabindex", "-1"));
127
127
  }, 1e3);
128
- }), (e, l) => {
129
- const i = ue;
130
- return o(), u("div", de, [
131
- e.checkboxType == "default" && e.optionType == "default" && !e.isView ? (o(), E(r(G), P({
132
- key: 0,
133
- ref_key: "checkboxRef",
134
- ref: R,
135
- checked: r(t),
136
- "onUpdate:checked": l[0] || (l[0] = (a) => U(t) ? t.value = a : t = a),
137
- disabled: e.disabled
138
- }, e.$attrs, {
139
- optionType: e.optionType,
140
- indeterminate: r(v),
141
- onChange: N,
142
- class: [e.size, { nolabel: Object.keys(e.$slots).length == 0 }]
143
- }), {
144
- default: W(() => [
145
- y((o(), u(
146
- "div",
147
- {
148
- class: "label",
149
- style: g([h.value, { color: "#666" }])
150
- },
151
- [
152
- w(e.$slots, "default", {}, void 0, !0)
153
- ],
154
- 4
155
- /* STYLE */
156
- )), [
157
- [r(x)]
158
- ])
159
- ]),
160
- _: 3
161
- /* FORWARDED */
162
- }, 16, ["checked", "disabled", "optionType", "indeterminate", "class"])) : c("v-if", !0),
163
- e.checkboxType == "default" && e.optionType == "square" && !e.isView ? (o(), u(
164
- "div",
165
- {
166
- key: 1,
167
- class: n([
168
- "das-ui-checkbox-square",
169
- e.size,
170
- {
171
- "das-ui-checkbox-square--disabled": e.disabled,
172
- "das-ui-checkbox-square--checked": !!r(t),
173
- "das-ui-checkbox-square--focus": r(S),
174
- "ellipsis-square-checkbox": !!h.value
175
- }
176
- ]),
177
- tabindex: "0",
178
- onClick: l[1] || (l[1] = (a) => I("default", "")),
179
- onBlur: l[2] || (l[2] = (a) => O("default", "")),
180
- style: g(h.value)
181
- },
182
- [
183
- y((o(), u("div", ce, [
184
- w(e.$slots, "default", {}, void 0, !0)
185
- ])), [
186
- [r(x)]
187
- ])
188
- ],
189
- 38
190
- /* CLASS, STYLE, NEED_HYDRATION */
191
- )) : c("v-if", !0),
192
- e.checkboxType == "group" && e.optionType == "default" && !e.isView ? (o(), E(i, P({
193
- key: 2,
194
- ref_key: "checkboxRef",
195
- ref: R
196
- }, e.$attrs, {
197
- class: [e.size, { "das-ui-checkbox-vertical": r(z) == "vertical" }],
198
- value: r(t),
199
- "onUpdate:value": l[3] || (l[3] = (a) => U(t) ? t.value = a : t = a),
200
- name: e.name,
201
- onChange: N
202
- }), {
203
- default: W(() => [
204
- (o(!0), u(
205
- C,
206
- null,
207
- $(b.value, (a, d) => (o(), E(r(G), {
208
- key: d,
209
- value: a.value,
210
- "onUpdate:value": (q) => a.value = q,
211
- disabled: a.disabled || e.disabled
212
- }, {
213
- default: W(() => [
214
- A(
215
- "div",
216
- {
217
- class: n(["label", { "label-min-width": !!h.value }]),
218
- style: g([h.value, { color: "#666" }])
219
- },
220
- [
221
- w(e.$slots, "content", {
222
- item: a,
223
- index: d
224
- }, () => [
225
- y((o(), u("div", null, [
226
- M(
227
- p(a.label),
228
- 1
229
- /* TEXT */
230
- )
231
- ])), [
232
- [r(x)]
233
- ])
234
- ], !0)
235
- ],
236
- 6
237
- /* CLASS, STYLE */
238
- )
239
- ]),
240
- _: 2
241
- /* DYNAMIC */
242
- }, 1032, ["value", "onUpdate:value", "disabled"]))),
243
- 128
244
- /* KEYED_FRAGMENT */
245
- ))
246
- ]),
247
- _: 3
248
- /* FORWARDED */
249
- }, 16, ["class", "value", "name"])) : c("v-if", !0),
250
- e.checkboxType == "group" && e.optionType == "square" && !e.isView ? (o(), u(
251
- "div",
252
- {
253
- key: 3,
254
- class: n(["das-ui-checkbox-square-group", [e.size, { "das-ui-checkbox-vertical": r(z) == "vertical" }]])
255
- },
256
- [
257
- (o(!0), u(
258
- C,
259
- null,
260
- $(b.value, (a, d) => (o(), u("div", {
261
- class: n([
262
- "das-ui-checkbox-square",
263
- {
264
- "das-ui-checkbox-square--disabled": a.disabled || e.disabled,
265
- "das-ui-checkbox-square--checked": a.checked,
266
- "das-ui-checkbox-square--focus": a.isFocus,
267
- "ellipsis-square-checkbox": !!h.value
268
- }
269
- ]),
270
- style: g(h.value),
271
- onClick: (q) => I("group", a),
272
- onBlur: (q) => O("group", a),
273
- tabindex: d,
274
- key: d
275
- }, [
276
- a.checked ? (o(), u("span", fe, [
277
- j(r(H), {
278
- size: "mini",
279
- icon: "select",
280
- iconColor: "#fff",
281
- class: "view-icon"
282
- })
283
- ])) : c("v-if", !0),
284
- y((o(), u("div", null, [
285
- M(
286
- p(a.label),
287
- 1
288
- /* TEXT */
289
- )
290
- ])), [
291
- [r(x)]
292
- ])
293
- ], 46, ne))),
294
- 128
295
- /* KEYED_FRAGMENT */
296
- ))
297
- ],
298
- 2
299
- /* CLASS */
300
- )) : c("v-if", !0),
301
- c("多选组 查看状态 "),
302
- e.isView ? (o(), u(
303
- "div",
304
- {
305
- key: 4,
306
- class: n(["das-ui-checkbox-view-group", { "flex-view": L.value.length > 1 }])
307
- },
308
- [
309
- L.value.length ? (o(!0), u(
310
- C,
311
- { key: 0 },
312
- $(L.value, (a, d) => (o(), u(
128
+ }, q = ne(), ee = m(() => ({
129
+ "--checkbox-height": q.value && {
130
+ small: "24px",
131
+ default: "32px",
132
+ large: "40px"
133
+ }[q.value],
134
+ "--checkbox-font-size": q.value && {
135
+ small: "12px",
136
+ default: "14px",
137
+ large: "14px"
138
+ }[q.value]
139
+ }));
140
+ return re(_), (e, l) => {
141
+ const i = de;
142
+ return o(), u(
143
+ "div",
144
+ {
145
+ class: "das-ui-checkbox",
146
+ style: y(ee.value)
147
+ },
148
+ [
149
+ e.checkboxType == "default" && e.optionType == "default" && !e.isView ? (o(), W(r(H), U({
150
+ key: 0,
151
+ ref_key: "checkboxRef",
152
+ ref: E,
153
+ checked: r(s),
154
+ "onUpdate:checked": l[0] || (l[0] = (a) => A(s) ? s.value = a : s = a),
155
+ disabled: e.disabled
156
+ }, e.$attrs, {
157
+ optionType: e.optionType,
158
+ indeterminate: r(v),
159
+ onChange: O,
160
+ class: [e.size, { nolabel: Object.keys(e.$slots).length == 0 }]
161
+ }), {
162
+ default: M(() => [
163
+ g((o(), u(
313
164
  "div",
314
165
  {
315
- class: n(["das-checkbox-item-view", a[r(f).label] && "nonelabel-item-view"]),
316
- key: d
166
+ class: "label",
167
+ style: y([b.value, { color: "#666" }])
317
168
  },
318
169
  [
319
- j(r(H), {
320
- size: "mini",
321
- icon: "select",
322
- iconColor: "#666",
323
- class: n(["view-icon", { "m-r-5": a[r(f).label] || Object.keys(e.$slots).length > 0 }])
324
- }, null, 8, ["class"]),
325
- a[r(f).label] ? y((o(), u(
326
- "div",
170
+ C(e.$slots, "default", {}, void 0, !0)
171
+ ],
172
+ 4
173
+ /* STYLE */
174
+ )), [
175
+ [r(x)]
176
+ ])
177
+ ]),
178
+ _: 3
179
+ /* FORWARDED */
180
+ }, 16, ["checked", "disabled", "optionType", "indeterminate", "class"])) : c("v-if", !0),
181
+ e.checkboxType == "default" && e.optionType == "square" && !e.isView ? (o(), u(
182
+ "div",
183
+ {
184
+ key: 1,
185
+ class: n([
186
+ "das-ui-checkbox-square",
187
+ e.size,
188
+ {
189
+ "das-ui-checkbox-square--disabled": e.disabled,
190
+ "das-ui-checkbox-square--checked": !!r(s),
191
+ "das-ui-checkbox-square--focus": r(F),
192
+ "ellipsis-square-checkbox": !!b.value
193
+ }
194
+ ]),
195
+ tabindex: "0",
196
+ onClick: l[1] || (l[1] = (a) => L("default", "")),
197
+ onBlur: l[2] || (l[2] = (a) => P("default", "")),
198
+ style: y(b.value)
199
+ },
200
+ [
201
+ g((o(), u("div", he, [
202
+ C(e.$slots, "default", {}, void 0, !0)
203
+ ])), [
204
+ [r(x)]
205
+ ])
206
+ ],
207
+ 38
208
+ /* CLASS, STYLE, NEED_HYDRATION */
209
+ )) : c("v-if", !0),
210
+ e.checkboxType == "group" && e.optionType == "default" && !e.isView ? (o(), W(i, U({
211
+ key: 2,
212
+ ref_key: "checkboxRef",
213
+ ref: E
214
+ }, e.$attrs, {
215
+ class: [e.size, { "das-ui-checkbox-vertical": r(I) == "vertical" }],
216
+ value: r(s),
217
+ "onUpdate:value": l[3] || (l[3] = (a) => A(s) ? s.value = a : s = a),
218
+ name: e.name,
219
+ onChange: O
220
+ }), {
221
+ default: M(() => [
222
+ (o(!0), u(
223
+ $,
224
+ null,
225
+ B(h.value, (a, d) => (o(), W(r(H), {
226
+ key: d,
227
+ value: a.value,
228
+ "onUpdate:value": (w) => a.value = w,
229
+ disabled: a.disabled || e.disabled
230
+ }, {
231
+ default: M(() => [
232
+ j(
233
+ "div",
234
+ {
235
+ class: n(["label", { "label-min-width": !!b.value }]),
236
+ style: y([b.value, { color: "#666" }])
237
+ },
238
+ [
239
+ C(e.$slots, "content", {
240
+ item: a,
241
+ index: d
242
+ }, () => [
243
+ g((o(), u("div", null, [
244
+ N(
245
+ p(a.label),
246
+ 1
247
+ /* TEXT */
248
+ )
249
+ ])), [
250
+ [r(x)]
251
+ ])
252
+ ], !0)
253
+ ],
254
+ 6
255
+ /* CLASS, STYLE */
256
+ )
257
+ ]),
258
+ _: 2
259
+ /* DYNAMIC */
260
+ }, 1032, ["value", "onUpdate:value", "disabled"]))),
261
+ 128
262
+ /* KEYED_FRAGMENT */
263
+ ))
264
+ ]),
265
+ _: 3
266
+ /* FORWARDED */
267
+ }, 16, ["class", "value", "name"])) : c("v-if", !0),
268
+ e.checkboxType == "group" && e.optionType == "square" && !e.isView ? (o(), u(
269
+ "div",
270
+ {
271
+ key: 3,
272
+ class: n(["das-ui-checkbox-square-group", [e.size, { "das-ui-checkbox-vertical": r(I) == "vertical" }]])
273
+ },
274
+ [
275
+ (o(!0), u(
276
+ $,
277
+ null,
278
+ B(h.value, (a, d) => (o(), u("div", {
279
+ class: n([
280
+ "das-ui-checkbox-square",
327
281
  {
328
- key: 0,
329
- class: n(["label", e.size]),
330
- style: g([h.value, { color: "#666" }])
331
- },
332
- [
333
- M(
334
- p(a[r(f).label]),
335
- 1
336
- /* TEXT */
337
- )
338
- ],
339
- 6
340
- /* CLASS, STYLE */
341
- )), [
282
+ "das-ui-checkbox-square--disabled": a.disabled || e.disabled,
283
+ "das-ui-checkbox-square--checked": a.checked,
284
+ "das-ui-checkbox-square--focus": a.isFocus,
285
+ "ellipsis-square-checkbox": !!b.value
286
+ }
287
+ ]),
288
+ style: y(b.value),
289
+ onClick: (w) => L("group", a),
290
+ onBlur: (w) => P("group", a),
291
+ tabindex: d,
292
+ key: d
293
+ }, [
294
+ a.checked ? (o(), u("span", pe, [
295
+ G(r(J), {
296
+ size: "mini",
297
+ icon: "select",
298
+ iconColor: "#fff",
299
+ class: "view-icon"
300
+ })
301
+ ])) : c("v-if", !0),
302
+ g((o(), u("div", null, [
303
+ N(
304
+ p(a.label),
305
+ 1
306
+ /* TEXT */
307
+ )
308
+ ])), [
342
309
  [r(x)]
343
- ]) : w(e.$slots, "default", { key: 1 }, void 0, !0)
344
- ],
345
- 2
346
- /* CLASS */
347
- ))),
348
- 128
349
- /* KEYED_FRAGMENT */
350
- )) : (o(), u(
310
+ ])
311
+ ], 46, be))),
312
+ 128
313
+ /* KEYED_FRAGMENT */
314
+ ))
315
+ ],
316
+ 2
317
+ /* CLASS */
318
+ )) : c("v-if", !0),
319
+ c("多选组 查看状态 "),
320
+ e.isView ? (o(), u(
321
+ "div",
322
+ {
323
+ key: 4,
324
+ class: n(["das-ui-checkbox-view-group", { "flex-view": R.value.length > 1 }])
325
+ },
326
+ [
327
+ R.value.length ? (o(!0), u(
328
+ $,
329
+ { key: 0 },
330
+ B(R.value, (a, d) => (o(), u(
331
+ "div",
332
+ {
333
+ class: n(["das-checkbox-item-view", a[r(f).label] && "nonelabel-item-view"]),
334
+ key: d
335
+ },
336
+ [
337
+ G(r(J), {
338
+ size: "mini",
339
+ icon: "select",
340
+ iconColor: "#666",
341
+ class: n(["view-icon", { "m-r-5": a[r(f).label] || Object.keys(e.$slots).length > 0 }])
342
+ }, null, 8, ["class"]),
343
+ a[r(f).label] ? g((o(), u(
344
+ "div",
345
+ {
346
+ key: 0,
347
+ class: n(["label", e.size]),
348
+ style: y([b.value, { color: "#666" }])
349
+ },
350
+ [
351
+ N(
352
+ p(a[r(f).label]),
353
+ 1
354
+ /* TEXT */
355
+ )
356
+ ],
357
+ 6
358
+ /* CLASS, STYLE */
359
+ )), [
360
+ [r(x)]
361
+ ]) : C(e.$slots, "default", { key: 1 }, void 0, !0)
362
+ ],
363
+ 2
364
+ /* CLASS */
365
+ ))),
366
+ 128
367
+ /* KEYED_FRAGMENT */
368
+ )) : (o(), u(
369
+ "span",
370
+ ve,
371
+ p(z.value),
372
+ 1
373
+ /* TEXT */
374
+ ))
375
+ ],
376
+ 2
377
+ /* CLASS */
378
+ )) : c("v-if", !0),
379
+ c(" 用于过滤条件的多选 "),
380
+ e.checkboxType == "group" && e.optionType == "filterSquare" ? (o(), u(
381
+ "div",
382
+ {
383
+ key: 5,
384
+ class: n(["das-ui-checkbox-square-group das-ui-checkbox-filter-square-group", { "das-ui-checkbox-vertical": r(I) == "vertical" }])
385
+ },
386
+ [
387
+ (o(!0), u(
388
+ $,
389
+ null,
390
+ B(h.value, (a, d) => (o(), u("div", {
391
+ class: n([
392
+ "das-ui-checkbox-square",
393
+ {
394
+ "das-ui-checkbox-square--disabled": a.disabled || e.disabled,
395
+ "das-ui-checkbox-square--checked": a.checked
396
+ }
397
+ ]),
398
+ onClick: (w) => L("group", a),
399
+ tabindex: d,
400
+ key: d
401
+ }, p(a.label), 11, ke))),
402
+ 128
403
+ /* KEYED_FRAGMENT */
404
+ ))
405
+ ],
406
+ 2
407
+ /* CLASS */
408
+ )) : c("v-if", !0),
409
+ e.error && e.errorLabel && e.errorMode === "default" ? (o(), u("div", me, [
410
+ e.error ? (o(), u(
351
411
  "span",
352
- be,
353
- p(D.value),
412
+ ye,
413
+ p(e.errorLabel),
354
414
  1
355
415
  /* TEXT */
356
- ))
357
- ],
358
- 2
359
- /* CLASS */
360
- )) : c("v-if", !0),
361
- c(" 用于过滤条件的多选 "),
362
- e.checkboxType == "group" && e.optionType == "filterSquare" ? (o(), u(
363
- "div",
364
- {
365
- key: 5,
366
- class: n(["das-ui-checkbox-square-group das-ui-checkbox-filter-square-group", { "das-ui-checkbox-vertical": r(z) == "vertical" }])
367
- },
368
- [
369
- (o(!0), u(
370
- C,
371
- null,
372
- $(b.value, (a, d) => (o(), u("div", {
373
- class: n([
374
- "das-ui-checkbox-square",
375
- {
376
- "das-ui-checkbox-square--disabled": a.disabled || e.disabled,
377
- "das-ui-checkbox-square--checked": a.checked
378
- }
379
- ]),
380
- onClick: (q) => I("group", a),
381
- tabindex: d,
382
- key: d
383
- }, p(a.label), 11, he))),
384
- 128
385
- /* KEYED_FRAGMENT */
386
- ))
387
- ],
388
- 2
389
- /* CLASS */
390
- )) : c("v-if", !0),
391
- e.error && e.errorLabel && e.errorMode === "default" ? (o(), u("div", pe, [
392
- e.error ? (o(), u(
393
- "span",
394
- ve,
395
- p(e.errorLabel),
396
- 1
397
- /* TEXT */
398
- )) : c("v-if", !0)
399
- ])) : c("v-if", !0),
400
- e.error && e.errorLabel && e.errorMode === "overlay" ? (o(), u("div", ke, [
401
- A(
402
- "span",
403
- me,
404
- p(e.errorLabel),
405
- 1
406
- /* TEXT */
407
- )
408
- ])) : c("v-if", !0)
409
- ]);
416
+ )) : c("v-if", !0)
417
+ ])) : c("v-if", !0),
418
+ e.error && e.errorLabel && e.errorMode === "overlay" ? (o(), u("div", ge, [
419
+ j(
420
+ "span",
421
+ xe,
422
+ p(e.errorLabel),
423
+ 1
424
+ /* TEXT */
425
+ )
426
+ ])) : c("v-if", !0)
427
+ ],
428
+ 4
429
+ /* STYLE */
430
+ );
410
431
  };
411
432
  }
412
- }), ge = (T, B) => {
413
- const s = T.__vccOpts || T;
414
- for (const [D, F] of B)
415
- s[D] = F;
416
- return s;
417
- }, xe = /* @__PURE__ */ ge(ye, [["__scopeId", "data-v-453bdecd"]]), Te = {
433
+ }), Ve = (T, S) => {
434
+ const t = T.__vccOpts || T;
435
+ for (const [z, D] of S)
436
+ t[z] = D;
437
+ return t;
438
+ }, qe = /* @__PURE__ */ Ve(Te, [["__scopeId", "data-v-38011197"]]), we = {
418
439
  "--demo-alert-bg": {
419
440
  light: "#fff",
420
441
  dark: "rgba(255,255,255,.2)"
@@ -427,10 +448,10 @@ const de = { class: "das-ui-checkbox" }, ce = { class: "label" }, ne = ["onClick
427
448
  "--das-ui-radio-bgff": "#fff",
428
449
  "--das-ui-radio-shadow": "rgba(85, 130, 243, 0.1)"
429
450
  };
430
- ie(Te);
431
- const Ie = () => K(null), Le = te(xe);
451
+ fe(we);
452
+ const Ee = () => Q(null), We = ie(qe);
432
453
  export {
433
- Le as DasCheckbox,
434
- Ie as DasCheckboxRef,
435
- Le as default
454
+ We as DasCheckbox,
455
+ Ee as DasCheckboxRef,
456
+ We as default
436
457
  };