vft 0.0.429 → 0.0.431

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 (234) hide show
  1. package/attributes.json +1 -1
  2. package/dist/index.css +1 -1
  3. package/es/components/alert/alert.vue2.js +38 -38
  4. package/es/components/autocomplete/autocomplete.vue2.js +82 -82
  5. package/es/components/avatar/avatar.vue2.js +23 -23
  6. package/es/components/avatar-stack/avatar-stack.vue2.js +25 -25
  7. package/es/components/breadcrumb/breadcrumb-item.vue2.js +19 -19
  8. package/es/components/button/button.vue2.js +37 -37
  9. package/es/components/card/card.vue2.js +19 -19
  10. package/es/components/carousel/carousel.vue2.js +75 -75
  11. package/es/components/carousel/use-carousel.js +1 -1
  12. package/es/components/cascader-panel/index.vue2.js +2 -2
  13. package/es/components/cascader-panel/menu.vue2.js +2 -2
  14. package/es/components/cascader-panel/node.vue2.js +3 -4
  15. package/es/components/checkbox/checkbox-button.vue2.js +52 -52
  16. package/es/components/checkbox/checkbox-group.vue2.js +26 -26
  17. package/es/components/checkbox/checkbox.vue2.js +57 -57
  18. package/es/components/clamp/clamp.vue2.js +14 -14
  19. package/es/components/clamp-toggle/clamp-toggle.vue2.js +17 -17
  20. package/es/components/clamp-tooltip/clamp-tooltip.vue2.js +19 -19
  21. package/es/components/col/col.vue2.js +20 -20
  22. package/es/components/color-picker/color-picker.vue2.js +126 -128
  23. package/es/components/color-picker/components/sv-panel.vue.js +2 -2
  24. package/es/components/config-provider/hooks/use-global-config.js +3 -3
  25. package/es/components/context-menu/context-menu.vue2.js +18 -18
  26. package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +37 -39
  27. package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +8 -10
  28. package/es/components/date-picker/date-picker.d.ts +1 -1
  29. package/es/components/date-picker/index.d.ts +2 -2
  30. package/es/components/descriptions/description.vue2.js +44 -44
  31. package/es/components/descriptions/descriptions-row.vue2.js +12 -12
  32. package/es/components/dialog/dialog-content.vue2.js +31 -31
  33. package/es/components/dialog/dialog.vue2.js +46 -46
  34. package/es/components/divider/divider.vue2.js +19 -19
  35. package/es/components/drawer/drawer.vue2.js +41 -41
  36. package/es/components/dropdown/dropdown-item-impl.vue2.js +40 -40
  37. package/es/components/dropdown/dropdown-item.vue2.js +28 -28
  38. package/es/components/dropdown/dropdown.vue2.js +124 -124
  39. package/es/components/form/form-item.vue2.js +71 -71
  40. package/es/components/header-layout/header-layout.vue2.js +25 -25
  41. package/es/components/icon/icon.vue2.js +15 -15
  42. package/es/components/icon-text/icon-text.vue2.js +28 -28
  43. package/es/components/iframe-layout/iframe-layout.vue2.js +13 -13
  44. package/es/components/iframe-layout/iframe-page.vue2.js +11 -11
  45. package/es/components/image/image.vue2.js +63 -63
  46. package/es/components/image-viewer/image-viewer.vue2.js +88 -88
  47. package/es/components/infinite-scroll/index.d.ts +1 -1
  48. package/es/components/input/input.vue2.js +112 -112
  49. package/es/components/input-number/input-number.vue2.js +100 -100
  50. package/es/components/input-tag/composables/use-input-tag.js +1 -1
  51. package/es/components/link/link.vue2.js +20 -20
  52. package/es/components/list-cell/list-cell.vue2.js +19 -19
  53. package/es/components/logo/logo.vue2.js +22 -22
  54. package/es/components/menu/menu-item-group.vue2.js +8 -8
  55. package/es/components/menu/menu-item.vue2.js +48 -48
  56. package/es/components/menu/sub-menu.vue2.js +33 -31
  57. package/es/components/message/message.vue2.js +66 -66
  58. package/es/components/modal/modal-footer-action.vue2.js +25 -25
  59. package/es/components/modal/modal.vue2.js +40 -40
  60. package/es/components/multiple-tabs/multiple-tabs.vue2.js +30 -30
  61. package/es/components/page-wrapper/page-wrapper.vue2.js +12 -12
  62. package/es/components/pagination/components/jumper.vue2.js +18 -18
  63. package/es/components/pagination/components/next.vue2.js +11 -11
  64. package/es/components/pagination/components/pager.vue2.js +74 -74
  65. package/es/components/pagination/components/prev.vue2.js +9 -9
  66. package/es/components/pagination/components/sizes.vue2.js +18 -18
  67. package/es/components/pagination/components/total.vue2.js +8 -8
  68. package/es/components/popconfirm/popconfirm.vue2.js +47 -47
  69. package/es/components/popover/popover.vue2.js +28 -28
  70. package/es/components/popper/trigger.vue2.js +9 -9
  71. package/es/components/progress/progress.vue2.js +87 -87
  72. package/es/components/qrcode/qrcode.vue2.js +31 -31
  73. package/es/components/radio/radio-button.vue2.js +17 -17
  74. package/es/components/radio/radio-group.vue2.js +35 -35
  75. package/es/components/router-view-content/router-view-content.vue2.js +25 -25
  76. package/es/components/roving-focus-group/roving-focus-item.vue2.js +30 -30
  77. package/es/components/row/row.vue2.js +5 -5
  78. package/es/components/scrollbar/bar.vue2.js +16 -16
  79. package/es/components/scrollbar/scrollbar.vue2.js +48 -48
  80. package/es/components/scrollbar/thumb.vue2.js +27 -27
  81. package/es/components/search/search.vue2.js +29 -29
  82. package/es/components/select/index.d.ts +1 -1
  83. package/es/components/select/select.vue.d.ts +1 -1
  84. package/es/components/side-menu/index.d.ts +2 -8
  85. package/es/components/side-menu/side-menu.vue.d.ts +8 -62
  86. package/es/components/side-menu/side-menu.vue2.js +48 -46
  87. package/es/components/side-menu/types.d.ts +107 -0
  88. package/es/components/side-menu/use-drag-line.d.ts +3 -1
  89. package/es/components/side-menu/use-drag-line.js +39 -28
  90. package/es/components/skeleton/skeleton-item.vue2.js +9 -9
  91. package/es/components/skeleton/skeleton.vue2.js +14 -14
  92. package/es/components/slider/button.vue2.js +54 -54
  93. package/es/components/slider/slider.vue2.js +106 -106
  94. package/es/components/steps/item.vue2.js +56 -56
  95. package/es/components/steps/steps.vue2.js +16 -16
  96. package/es/components/super-form/super-form-action.vue2.js +28 -28
  97. package/es/components/super-form/super-form-item.vue2.js +1 -1
  98. package/es/components/switch/switch.vue2.js +108 -108
  99. package/es/components/table/field.d.ts +4 -4
  100. package/es/components/teleport/teleport.vue2.js +6 -6
  101. package/es/components/time-picker/common/picker.vue.d.ts +1 -1
  102. package/es/components/time-picker/index.d.ts +2 -2
  103. package/es/components/time-picker/time-picker.d.ts +1 -1
  104. package/es/components/timeline/timeline-item.vue2.js +20 -20
  105. package/es/components/tooltip/content.vue2.js +57 -57
  106. package/es/components/tooltip/tooltip.vue2.js +66 -66
  107. package/es/components/tooltip/trigger.vue2.js +42 -42
  108. package/es/components/tree/tree.vue2.js +72 -72
  109. package/es/components/upload/upload-content.vue2.js +85 -85
  110. package/es/components/upload/upload-list.vue2.js +70 -70
  111. package/es/components/upload/upload.vue2.js +86 -86
  112. package/es/components/verify-code/verify-code.vue2.js +18 -18
  113. package/es/package.json.d.ts +1 -1
  114. package/es/package.json.js +1 -1
  115. package/es/utils/vue/vnode.js +1 -1
  116. package/lib/components/alert/alert.vue2.cjs +1 -1
  117. package/lib/components/autocomplete/autocomplete.vue2.cjs +1 -1
  118. package/lib/components/avatar/avatar.vue2.cjs +1 -1
  119. package/lib/components/avatar-stack/avatar-stack.vue2.cjs +1 -1
  120. package/lib/components/breadcrumb/breadcrumb-item.vue2.cjs +1 -1
  121. package/lib/components/button/button.vue2.cjs +1 -1
  122. package/lib/components/card/card.vue2.cjs +1 -1
  123. package/lib/components/carousel/carousel.vue2.cjs +1 -1
  124. package/lib/components/cascader-panel/index.vue2.cjs +1 -1
  125. package/lib/components/cascader-panel/menu.vue2.cjs +1 -1
  126. package/lib/components/cascader-panel/node.vue2.cjs +1 -1
  127. package/lib/components/checkbox/checkbox-button.vue2.cjs +1 -1
  128. package/lib/components/checkbox/checkbox-group.vue2.cjs +1 -1
  129. package/lib/components/checkbox/checkbox.vue2.cjs +1 -1
  130. package/lib/components/clamp/clamp.vue2.cjs +1 -1
  131. package/lib/components/clamp-toggle/clamp-toggle.vue2.cjs +1 -1
  132. package/lib/components/clamp-tooltip/clamp-tooltip.vue2.cjs +1 -1
  133. package/lib/components/col/col.vue2.cjs +1 -1
  134. package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
  135. package/lib/components/color-picker/components/sv-panel.vue.cjs +1 -1
  136. package/lib/components/context-menu/context-menu.vue2.cjs +1 -1
  137. package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
  138. package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
  139. package/lib/components/date-picker/date-picker.d.ts +1 -1
  140. package/lib/components/date-picker/index.d.ts +2 -2
  141. package/lib/components/descriptions/description.vue2.cjs +1 -1
  142. package/lib/components/descriptions/descriptions-row.vue2.cjs +1 -1
  143. package/lib/components/dialog/dialog-content.vue2.cjs +1 -1
  144. package/lib/components/dialog/dialog.vue2.cjs +1 -1
  145. package/lib/components/divider/divider.vue2.cjs +1 -1
  146. package/lib/components/drawer/drawer.vue2.cjs +1 -1
  147. package/lib/components/dropdown/dropdown-item-impl.vue2.cjs +1 -1
  148. package/lib/components/dropdown/dropdown-item.vue2.cjs +1 -1
  149. package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
  150. package/lib/components/form/form-item.vue2.cjs +1 -1
  151. package/lib/components/header-layout/header-layout.vue2.cjs +1 -1
  152. package/lib/components/icon/icon.vue2.cjs +1 -1
  153. package/lib/components/icon-text/icon-text.vue2.cjs +1 -1
  154. package/lib/components/iframe-layout/iframe-layout.vue2.cjs +1 -1
  155. package/lib/components/iframe-layout/iframe-page.vue2.cjs +1 -1
  156. package/lib/components/image/image.vue2.cjs +1 -1
  157. package/lib/components/image-viewer/image-viewer.vue2.cjs +1 -1
  158. package/lib/components/infinite-scroll/index.d.ts +1 -1
  159. package/lib/components/input/input.vue2.cjs +1 -1
  160. package/lib/components/input-number/input-number.vue2.cjs +1 -1
  161. package/lib/components/link/link.vue2.cjs +1 -1
  162. package/lib/components/list-cell/list-cell.vue2.cjs +1 -1
  163. package/lib/components/logo/logo.vue2.cjs +1 -1
  164. package/lib/components/menu/menu-item-group.vue2.cjs +1 -1
  165. package/lib/components/menu/menu-item.vue2.cjs +1 -1
  166. package/lib/components/menu/sub-menu.vue2.cjs +1 -1
  167. package/lib/components/message/message.vue2.cjs +1 -1
  168. package/lib/components/modal/modal-footer-action.vue2.cjs +1 -1
  169. package/lib/components/modal/modal.vue2.cjs +1 -1
  170. package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
  171. package/lib/components/page-wrapper/page-wrapper.vue2.cjs +1 -1
  172. package/lib/components/pagination/components/jumper.vue2.cjs +1 -1
  173. package/lib/components/pagination/components/next.vue2.cjs +1 -1
  174. package/lib/components/pagination/components/pager.vue2.cjs +1 -1
  175. package/lib/components/pagination/components/prev.vue2.cjs +1 -1
  176. package/lib/components/pagination/components/sizes.vue2.cjs +1 -1
  177. package/lib/components/pagination/components/total.vue2.cjs +1 -1
  178. package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -1
  179. package/lib/components/popover/popover.vue2.cjs +1 -1
  180. package/lib/components/popper/trigger.vue2.cjs +1 -1
  181. package/lib/components/progress/progress.vue2.cjs +5 -5
  182. package/lib/components/qrcode/qrcode.vue2.cjs +1 -1
  183. package/lib/components/radio/radio-button.vue2.cjs +1 -1
  184. package/lib/components/radio/radio-group.vue2.cjs +1 -1
  185. package/lib/components/router-view-content/router-view-content.vue2.cjs +1 -1
  186. package/lib/components/roving-focus-group/roving-focus-item.vue2.cjs +1 -1
  187. package/lib/components/row/row.vue2.cjs +1 -1
  188. package/lib/components/scrollbar/bar.vue2.cjs +1 -1
  189. package/lib/components/scrollbar/scrollbar.vue2.cjs +1 -1
  190. package/lib/components/scrollbar/thumb.vue2.cjs +1 -1
  191. package/lib/components/search/search.vue2.cjs +1 -1
  192. package/lib/components/select/index.d.ts +1 -1
  193. package/lib/components/select/select.vue.d.ts +1 -1
  194. package/lib/components/side-menu/index.d.ts +2 -8
  195. package/lib/components/side-menu/side-menu.vue.d.ts +8 -62
  196. package/lib/components/side-menu/side-menu.vue2.cjs +1 -1
  197. package/lib/components/side-menu/types.d.ts +107 -0
  198. package/lib/components/side-menu/use-drag-line.cjs +1 -1
  199. package/lib/components/side-menu/use-drag-line.d.ts +3 -1
  200. package/lib/components/skeleton/skeleton-item.vue2.cjs +1 -1
  201. package/lib/components/skeleton/skeleton.vue2.cjs +1 -1
  202. package/lib/components/slider/button.vue2.cjs +1 -1
  203. package/lib/components/slider/slider.vue2.cjs +1 -1
  204. package/lib/components/steps/item.vue2.cjs +1 -1
  205. package/lib/components/steps/steps.vue2.cjs +1 -1
  206. package/lib/components/super-form/super-form-action.vue2.cjs +1 -1
  207. package/lib/components/switch/switch.vue2.cjs +1 -1
  208. package/lib/components/table/field.d.ts +4 -4
  209. package/lib/components/teleport/teleport.vue2.cjs +1 -1
  210. package/lib/components/time-picker/common/picker.vue.d.ts +1 -1
  211. package/lib/components/time-picker/index.d.ts +2 -2
  212. package/lib/components/time-picker/time-picker.d.ts +1 -1
  213. package/lib/components/timeline/timeline-item.vue2.cjs +1 -1
  214. package/lib/components/tooltip/content.vue2.cjs +1 -1
  215. package/lib/components/tooltip/tooltip.vue2.cjs +1 -1
  216. package/lib/components/tooltip/trigger.vue2.cjs +1 -1
  217. package/lib/components/tree/tree.vue2.cjs +1 -1
  218. package/lib/components/upload/upload-content.vue2.cjs +1 -1
  219. package/lib/components/upload/upload-list.vue2.cjs +1 -1
  220. package/lib/components/upload/upload.vue2.cjs +1 -1
  221. package/lib/components/verify-code/verify-code.vue2.cjs +1 -1
  222. package/lib/package.json.cjs +1 -1
  223. package/lib/package.json.d.ts +1 -1
  224. package/package.json +4 -4
  225. package/tags.json +1 -1
  226. package/theme-style/index.css +1 -1
  227. package/theme-style/src/header-layout.scss +1 -1
  228. package/theme-style/src/menu.scss +7 -2
  229. package/theme-style/src/mixins/mixins.scss +1 -0
  230. package/theme-style/src/side-menu.scss +0 -3
  231. package/theme-style/vft-header-layout.css +1 -1
  232. package/theme-style/vft-menu.css +1 -1
  233. package/theme-style/vft-side-menu.css +1 -1
  234. package/web-types.json +1 -1
@@ -1,4 +1,4 @@
1
- import { defineComponent as c, useSlots as z, inject as D, computed as v, createElementBlock as r, openBlock as i, normalizeClass as d, withDirectives as f, createCommentVNode as k, unref as o, isRef as y, vModelCheckbox as C, normalizeStyle as F, createTextVNode as V, renderSlot as j, toDisplayString as B } from "vue";
1
+ import { defineComponent as B, useSlots as z, inject as D, computed as f, createElementBlock as d, openBlock as r, normalizeClass as b, withDirectives as x, createCommentVNode as k, unref as t, isRef as y, vModelCheckbox as C, normalizeStyle as F, createTextVNode as V, renderSlot as j, toDisplayString as p } from "vue";
2
2
  import "@vueuse/core";
3
3
  import "@vft/utils";
4
4
  import "../config-provider/hooks/use-global-config.js";
@@ -10,9 +10,9 @@ import "@popperjs/core";
10
10
  import "../../hooks/use-z-index/index.js";
11
11
  import { useCheckbox as E } from "./composables/use-checkbox.js";
12
12
  import { checkboxGroupContextKey as G } from "./constants.js";
13
- const K = ["name", "tabindex", "disabled", "true-value", "false-value"], U = ["name", "tabindex", "disabled", "value"], M = c({
13
+ const K = ["name", "tabindex", "disabled", "true-value", "false-value"], U = ["name", "tabindex", "disabled", "value"], M = B({
14
14
  name: "VftCheckboxButton"
15
- }), X = /* @__PURE__ */ c({
15
+ }), X = /* @__PURE__ */ B({
16
16
  ...M,
17
17
  props: {
18
18
  modelValue: { type: [Number, String, Boolean] },
@@ -32,72 +32,72 @@ const K = ["name", "tabindex", "disabled", "true-value", "false-value"], U = ["n
32
32
  validateEvent: { type: Boolean }
33
33
  },
34
34
  emits: ["update:modelValue", "change"],
35
- setup(g) {
36
- const S = g, x = z(), {
37
- isFocused: u,
38
- isChecked: m,
39
- isDisabled: b,
35
+ setup(l) {
36
+ const g = l, S = z(), {
37
+ isFocused: i,
38
+ isChecked: v,
39
+ isDisabled: m,
40
40
  checkboxButtonSize: $,
41
- model: n,
41
+ model: u,
42
42
  handleChange: s
43
- } = E(S, x), p = D(G, void 0), a = w("checkbox"), h = v(() => {
44
- const e = p?.fill?.value ?? "";
43
+ } = E(g, S), c = D(G, void 0), a = w("checkbox"), h = f(() => {
44
+ const n = c?.fill?.value ?? "";
45
45
  return {
46
- backgroundColor: e,
47
- borderColor: e,
48
- color: p?.textColor?.value ?? "",
49
- boxShadow: e ? `-1px 0 0 0 ${e}` : void 0
46
+ backgroundColor: n,
47
+ borderColor: n,
48
+ color: c?.textColor?.value ?? "",
49
+ boxShadow: n ? `-1px 0 0 0 ${n}` : void 0
50
50
  };
51
- }), N = v(() => [
51
+ }), N = f(() => [
52
52
  a.b("button"),
53
53
  a.bm("button", $.value),
54
- a.is("disabled", b.value),
55
- a.is("checked", m.value),
56
- a.is("focus", u.value)
54
+ a.is("disabled", m.value),
55
+ a.is("checked", v.value),
56
+ a.is("focus", i.value)
57
57
  ]);
58
- return (e, l) => (i(), r("label", {
59
- class: d(N.value)
58
+ return (n, e) => (r(), d("label", {
59
+ class: b(N.value)
60
60
  }, [
61
- e.trueValue || e.falseValue ? f((i(), r("input", {
61
+ l.trueValue || l.falseValue ? x((r(), d("input", {
62
62
  key: 0,
63
- "onUpdate:modelValue": l[0] || (l[0] = (t) => y(n) ? n.value = t : null),
64
- class: d(o(a).be("button", "original")),
63
+ "onUpdate:modelValue": e[0] || (e[0] = (o) => y(u) ? u.value = o : null),
64
+ class: b(t(a).be("button", "original")),
65
65
  type: "checkbox",
66
- name: e.name,
67
- tabindex: e.tabindex,
68
- disabled: o(b),
69
- "true-value": e.trueValue,
70
- "false-value": e.falseValue,
71
- onChange: l[1] || (l[1] = //@ts-ignore
72
- (...t) => o(s) && o(s)(...t)),
73
- onFocus: l[2] || (l[2] = (t) => u.value = !0),
74
- onBlur: l[3] || (l[3] = (t) => u.value = !1)
66
+ name: l.name,
67
+ tabindex: l.tabindex,
68
+ disabled: t(m),
69
+ "true-value": l.trueValue,
70
+ "false-value": l.falseValue,
71
+ onChange: e[1] || (e[1] = //@ts-ignore
72
+ (...o) => t(s) && t(s)(...o)),
73
+ onFocus: e[2] || (e[2] = (o) => i.value = !0),
74
+ onBlur: e[3] || (e[3] = (o) => i.value = !1)
75
75
  }, null, 42, K)), [
76
- [C, o(n)]
77
- ]) : f((i(), r("input", {
76
+ [C, t(u)]
77
+ ]) : x((r(), d("input", {
78
78
  key: 1,
79
- "onUpdate:modelValue": l[4] || (l[4] = (t) => y(n) ? n.value = t : null),
80
- class: d(o(a).be("button", "original")),
79
+ "onUpdate:modelValue": e[4] || (e[4] = (o) => y(u) ? u.value = o : null),
80
+ class: b(t(a).be("button", "original")),
81
81
  type: "checkbox",
82
- name: e.name,
83
- tabindex: e.tabindex,
84
- disabled: o(b),
85
- value: e.value,
86
- onChange: l[5] || (l[5] = //@ts-ignore
87
- (...t) => o(s) && o(s)(...t)),
88
- onFocus: l[6] || (l[6] = (t) => u.value = !0),
89
- onBlur: l[7] || (l[7] = (t) => u.value = !1)
82
+ name: l.name,
83
+ tabindex: l.tabindex,
84
+ disabled: t(m),
85
+ value: l.value,
86
+ onChange: e[5] || (e[5] = //@ts-ignore
87
+ (...o) => t(s) && t(s)(...o)),
88
+ onFocus: e[6] || (e[6] = (o) => i.value = !0),
89
+ onBlur: e[7] || (e[7] = (o) => i.value = !1)
90
90
  }, null, 42, U)), [
91
- [C, o(n)]
91
+ [C, t(u)]
92
92
  ]),
93
- e.$slots.default || e.value || e.label ? (i(), r("span", {
93
+ n.$slots.default || l.value || l.label ? (r(), d("span", {
94
94
  key: 2,
95
- class: d(o(a).be("button", "inner")),
96
- style: F(o(m) ? h.value : void 0)
95
+ class: b(t(a).be("button", "inner")),
96
+ style: F(t(v) ? h.value : void 0)
97
97
  }, [
98
- V(B(e.label) + " ", 1),
99
- e.label ? k("", !0) : j(e.$slots, "default", { key: 0 }, () => [
100
- V(B(e.value), 1)
98
+ V(p(l.label) + " ", 1),
99
+ l.label ? k("", !0) : j(n.$slots, "default", { key: 0 }, () => [
100
+ V(p(l.value), 1)
101
101
  ])
102
102
  ], 6)) : k("", !0)
103
103
  ], 2));
@@ -1,9 +1,9 @@
1
- import { defineComponent as u, computed as h, provide as k, toRefs as g, watch as y, createBlock as s, openBlock as r, resolveDynamicComponent as m, unref as t, normalizeClass as x, withCtx as E, createElementBlock as I, renderSlot as B, Fragment as C, renderList as V, nextTick as _ } from "vue";
1
+ import { defineComponent as c, computed as x, provide as h, toRefs as k, watch as g, createBlock as m, openBlock as n, resolveDynamicComponent as u, unref as l, normalizeClass as y, withCtx as E, createElementBlock as I, renderSlot as B, Fragment as C, renderList as V, nextTick as z } from "vue";
2
2
  import "../form/index.js";
3
- import { UPDATE_MODEL_EVENT as z } from "../../constants/event.js";
3
+ import { UPDATE_MODEL_EVENT as F } from "../../constants/event.js";
4
4
  import "@vueuse/core";
5
5
  import "@vft/utils";
6
- import { debugWarn as F } from "../../utils/error.js";
6
+ import { debugWarn as _ } from "../../utils/error.js";
7
7
  import "../config-provider/hooks/use-global-config.js";
8
8
  import { pick as w } from "lodash-es";
9
9
  import { useNamespace as D } from "../../hooks/use-namespace/index.js";
@@ -14,9 +14,9 @@ import L from "./checkbox.vue2.js";
14
14
  import T from "./checkbox-button.vue2.js";
15
15
  import { checkboxGroupContextKey as $ } from "./constants.js";
16
16
  import { useFormItem as G, useFormItemInputId as N } from "../form/hooks/use-form-item.js";
17
- const A = u({
17
+ const A = c({
18
18
  name: "VftCheckboxGroup"
19
- }), ae = /* @__PURE__ */ u({
19
+ }), te = /* @__PURE__ */ c({
20
20
  ...A,
21
21
  props: {
22
22
  modelValue: { default: () => [] },
@@ -33,21 +33,21 @@ const A = u({
33
33
  options: {}
34
34
  },
35
35
  emits: ["update:modelValue", "change"],
36
- setup(c, { emit: p }) {
37
- const o = c, n = p, f = D("checkbox"), { formItem: l } = G(), { inputId: b, isLabeledByFormItem: i } = N(o, {
38
- formItemContext: l
39
- }), d = async (a) => {
40
- n(z, a), await _(), n("change", a);
41
- }, v = h({
36
+ setup(a, { emit: p }) {
37
+ const o = a, i = p, f = D("checkbox"), { formItem: r } = G(), { inputId: b, isLabeledByFormItem: d } = N(o, {
38
+ formItemContext: r
39
+ }), s = async (t) => {
40
+ i(F, t), await z(), i("change", t);
41
+ }, v = x({
42
42
  get() {
43
43
  return o.modelValue;
44
44
  },
45
- set(a) {
46
- d(a);
45
+ set(t) {
46
+ s(t);
47
47
  }
48
48
  });
49
- return k($, {
50
- ...w(g(o), [
49
+ return h($, {
50
+ ...w(k(o), [
51
51
  "size",
52
52
  "min",
53
53
  "max",
@@ -57,21 +57,21 @@ const A = u({
57
57
  "textColor"
58
58
  ]),
59
59
  modelValue: v,
60
- changeEvent: d
61
- }), y(
60
+ changeEvent: s
61
+ }), g(
62
62
  () => o.modelValue,
63
63
  () => {
64
- o.validateEvent && l?.validate("change").catch((a) => F(a));
64
+ o.validateEvent && r?.validate("change").catch((t) => _(t));
65
65
  }
66
- ), (a, K) => (r(), s(m(a.tag), {
67
- id: t(b),
68
- class: x(t(f).b("group")),
66
+ ), (t, K) => (n(), m(u(a.tag), {
67
+ id: l(b),
68
+ class: y(l(f).b("group")),
69
69
  role: "group",
70
- "aria-label": t(i) ? void 0 : a.label || "checkbox-group",
71
- "aria-labelledby": t(i) ? t(l)?.labelId : void 0
70
+ "aria-label": l(d) ? void 0 : a.label || "checkbox-group",
71
+ "aria-labelledby": l(d) ? l(r)?.labelId : void 0
72
72
  }, {
73
73
  default: E(() => [
74
- a.options ? (r(!0), I(C, { key: 0 }, V(a.options, (e) => (r(), s(m(a.useButton ? T : L), {
74
+ a.options ? (n(!0), I(C, { key: 0 }, V(a.options, (e) => (n(), m(u(a.useButton ? T : L), {
75
75
  value: e.value,
76
76
  label: e.label,
77
77
  indeterminate: e.indeterminate,
@@ -87,12 +87,12 @@ const A = u({
87
87
  tabindex: e.tabindex,
88
88
  "validate-event": e.validateEvent,
89
89
  key: e.value
90
- }, null, 8, ["value", "label", "indeterminate", "disabled", "checked", "name", "true-value", "false-value", "id", "controls", "border", "size", "tabindex", "validate-event"]))), 128)) : B(a.$slots, "default", { key: 1 })
90
+ }, null, 8, ["value", "label", "indeterminate", "disabled", "checked", "name", "true-value", "false-value", "id", "controls", "border", "size", "tabindex", "validate-event"]))), 128)) : B(t.$slots, "default", { key: 1 })
91
91
  ]),
92
92
  _: 3
93
93
  }, 8, ["id", "class", "aria-label", "aria-labelledby"]));
94
94
  }
95
95
  });
96
96
  export {
97
- ae as default
97
+ te as default
98
98
  };
@@ -1,14 +1,14 @@
1
- import { defineComponent as S, useSlots as K, computed as c, createBlock as L, openBlock as i, resolveDynamicComponent as O, unref as a, normalizeClass as s, withCtx as R, createElementVNode as y, createElementBlock as d, createCommentVNode as b, withDirectives as h, isRef as C, vModelCheckbox as B, createTextVNode as V, toDisplayString as g, Fragment as N, renderSlot as U } from "vue";
1
+ import { defineComponent as S, useSlots as I, computed as y, createBlock as K, openBlock as o, resolveDynamicComponent as L, unref as a, normalizeClass as d, withCtx as O, createElementVNode as h, createElementBlock as s, createCommentVNode as c, withDirectives as C, isRef as B, vModelCheckbox as V, createTextVNode as g, toDisplayString as p, Fragment as N, renderSlot as R } from "vue";
2
2
  import "@vueuse/core";
3
3
  import "@vft/utils";
4
4
  import "../config-provider/hooks/use-global-config.js";
5
5
  import "lodash-es";
6
6
  import "../form/index.js";
7
- import { useNamespace as j } from "../../hooks/use-namespace/index.js";
7
+ import { useNamespace as U } from "../../hooks/use-namespace/index.js";
8
8
  import "../../hooks/use-model-toggle/index.js";
9
9
  import "@popperjs/core";
10
10
  import "../../hooks/use-z-index/index.js";
11
- import { useCheckbox as x } from "./composables/use-checkbox.js";
11
+ import { useCheckbox as j } from "./composables/use-checkbox.js";
12
12
  const M = ["tabindex", "role", "aria-checked"], T = ["id", "aria-hidden", "name", "tabindex", "disabled", "true-value", "false-value"], q = ["id", "aria-hidden", "disabled", "value", "name", "tabindex"], A = S({
13
13
  name: "vft-checkbox"
14
14
  }), ae = /* @__PURE__ */ S({
@@ -31,95 +31,95 @@ const M = ["tabindex", "role", "aria-checked"], T = ["id", "aria-hidden", "name"
31
31
  validateEvent: { type: Boolean, default: !0 }
32
32
  },
33
33
  emits: ["update:modelValue", "change"],
34
- setup($) {
35
- const p = $, n = j("checkbox"), F = K(), {
34
+ setup(e) {
35
+ const b = e, l = U("checkbox"), $ = I(), {
36
36
  inputId: v,
37
- isLabeledByFormItem: D,
37
+ isLabeledByFormItem: F,
38
38
  isChecked: k,
39
- isDisabled: u,
40
- isFocused: r,
41
- checkboxSize: w,
39
+ isDisabled: r,
40
+ isFocused: u,
41
+ checkboxSize: D,
42
42
  hasOwnLabel: f,
43
- model: t,
43
+ model: i,
44
44
  handleChange: m,
45
- onClickRoot: z
46
- } = x(p, F), E = c(() => [
47
- n.b(),
48
- n.m(w.value),
49
- n.is("disabled", u.value),
50
- n.is("bordered", p.border),
51
- n.is("checked", k.value)
52
- ]), I = c(() => [
53
- n.e("input"),
54
- n.is("disabled", u.value),
55
- n.is("checked", k.value),
56
- n.is("indeterminate", p.indeterminate),
57
- n.is("focus", r.value)
45
+ onClickRoot: w
46
+ } = j(b, $), z = y(() => [
47
+ l.b(),
48
+ l.m(D.value),
49
+ l.is("disabled", r.value),
50
+ l.is("bordered", b.border),
51
+ l.is("checked", k.value)
52
+ ]), E = y(() => [
53
+ l.e("input"),
54
+ l.is("disabled", r.value),
55
+ l.is("checked", k.value),
56
+ l.is("indeterminate", b.indeterminate),
57
+ l.is("focus", u.value)
58
58
  ]);
59
- return (e, l) => (i(), L(O(!a(f) && a(D) ? "span" : "label"), {
60
- class: s(E.value),
59
+ return (x, t) => (o(), K(L(!a(f) && a(F) ? "span" : "label"), {
60
+ class: d(z.value),
61
61
  "aria-controls": e.indeterminate ? e.controls : null,
62
- onClick: a(z)
62
+ onClick: a(w)
63
63
  }, {
64
- default: R(() => [
65
- y("span", {
66
- class: s(I.value),
64
+ default: O(() => [
65
+ h("span", {
66
+ class: d(E.value),
67
67
  tabindex: e.indeterminate ? 0 : void 0,
68
68
  role: e.indeterminate ? "checkbox" : void 0,
69
69
  "aria-checked": e.indeterminate ? "mixed" : void 0
70
70
  }, [
71
- e.trueValue || e.falseValue ? h((i(), d("input", {
71
+ e.trueValue || e.falseValue ? C((o(), s("input", {
72
72
  key: 0,
73
73
  id: a(v),
74
- "onUpdate:modelValue": l[0] || (l[0] = (o) => C(t) ? t.value = o : null),
75
- class: s(a(n).e("original")),
74
+ "onUpdate:modelValue": t[0] || (t[0] = (n) => B(i) ? i.value = n : null),
75
+ class: d(a(l).e("original")),
76
76
  type: "checkbox",
77
77
  "aria-hidden": e.indeterminate ? "true" : "false",
78
78
  name: e.name,
79
79
  tabindex: e.tabindex,
80
- disabled: a(u),
80
+ disabled: a(r),
81
81
  "true-value": e.trueValue,
82
82
  "false-value": e.falseValue,
83
- onChange: l[1] || (l[1] = //@ts-ignore
84
- (...o) => a(m) && a(m)(...o)),
85
- onFocus: l[2] || (l[2] = (o) => r.value = !0),
86
- onBlur: l[3] || (l[3] = (o) => r.value = !1)
83
+ onChange: t[1] || (t[1] = //@ts-ignore
84
+ (...n) => a(m) && a(m)(...n)),
85
+ onFocus: t[2] || (t[2] = (n) => u.value = !0),
86
+ onBlur: t[3] || (t[3] = (n) => u.value = !1)
87
87
  }, null, 42, T)), [
88
- [B, a(t)]
89
- ]) : h((i(), d("input", {
88
+ [V, a(i)]
89
+ ]) : C((o(), s("input", {
90
90
  key: 1,
91
91
  id: a(v),
92
- "onUpdate:modelValue": l[4] || (l[4] = (o) => C(t) ? t.value = o : null),
93
- class: s(a(n).e("original")),
92
+ "onUpdate:modelValue": t[4] || (t[4] = (n) => B(i) ? i.value = n : null),
93
+ class: d(a(l).e("original")),
94
94
  type: "checkbox",
95
95
  "aria-hidden": e.indeterminate ? "true" : "false",
96
- disabled: a(u),
96
+ disabled: a(r),
97
97
  value: e.value,
98
98
  name: e.name,
99
99
  tabindex: e.tabindex,
100
- onChange: l[5] || (l[5] = //@ts-ignore
101
- (...o) => a(m) && a(m)(...o)),
102
- onFocus: l[6] || (l[6] = (o) => r.value = !0),
103
- onBlur: l[7] || (l[7] = (o) => r.value = !1)
100
+ onChange: t[5] || (t[5] = //@ts-ignore
101
+ (...n) => a(m) && a(m)(...n)),
102
+ onFocus: t[6] || (t[6] = (n) => u.value = !0),
103
+ onBlur: t[7] || (t[7] = (n) => u.value = !1)
104
104
  }, null, 42, q)), [
105
- [B, a(t)]
105
+ [V, a(i)]
106
106
  ]),
107
- y("span", {
108
- class: s(a(n).e("inner"))
107
+ h("span", {
108
+ class: d(a(l).e("inner"))
109
109
  }, null, 2)
110
110
  ], 10, M),
111
- a(f) ? (i(), d("span", {
111
+ a(f) ? (o(), s("span", {
112
112
  key: 0,
113
- class: s(a(n).e("label"))
113
+ class: d(a(l).e("label"))
114
114
  }, [
115
- V(g(e.label) + " ", 1),
116
- e.label ? b("", !0) : (i(), d(N, { key: 0 }, [
117
- U(e.$slots, "default"),
118
- e.$slots.default ? b("", !0) : (i(), d(N, { key: 0 }, [
119
- V(g(e.value), 1)
115
+ g(p(e.label) + " ", 1),
116
+ e.label ? c("", !0) : (o(), s(N, { key: 0 }, [
117
+ R(x.$slots, "default"),
118
+ x.$slots.default ? c("", !0) : (o(), s(N, { key: 0 }, [
119
+ g(p(e.value), 1)
120
120
  ], 64))
121
121
  ], 64))
122
- ], 2)) : b("", !0)
122
+ ], 2)) : c("", !0)
123
123
  ]),
124
124
  _: 3
125
125
  }, 8, ["class", "aria-controls", "onClick"]));
@@ -1,13 +1,13 @@
1
- import { defineComponent as M, ref as v, reactive as N, computed as u, watch as s, nextTick as E, onUnmounted as V, onMounted as p, createElementBlock as q, openBlock as D, normalizeStyle as G, createElementVNode as w, renderSlot as B } from "vue";
1
+ import { defineComponent as M, ref as v, reactive as N, computed as u, watch as s, nextTick as E, onUnmounted as V, onMounted as q, createElementBlock as D, openBlock as G, normalizeStyle as I, createElementVNode as w, renderSlot as B } from "vue";
2
2
  import "@vueuse/core";
3
- import { addListener as I, removeListener as J } from "@vft/utils";
4
- import { addUnit as K } from "../../utils/helper.js";
3
+ import { addListener as J, removeListener as K } from "@vft/utils";
4
+ import { addUnit as P } from "../../utils/helper.js";
5
5
  import "lodash-es";
6
6
  import "../form/index.js";
7
- const P = ["title", "aria-label"], Q = M({
7
+ const Q = ["title", "aria-label"], W = M({
8
8
  name: "vft-clamp"
9
9
  }), te = /* @__PURE__ */ M({
10
- ...Q,
10
+ ...W,
11
11
  props: {
12
12
  text: {},
13
13
  maxHeight: {},
@@ -25,14 +25,14 @@ const P = ["title", "aria-label"], Q = M({
25
25
  unregisterResizeCallback: null
26
26
  }), j = u(() => {
27
27
  if (!l.localExpanded && e.maxHeight)
28
- return K(e.maxHeight);
28
+ return P(e.maxHeight);
29
29
  }), y = () => {
30
30
  x.value && (x.value.textContent = S.value);
31
31
  }, c = () => {
32
32
  l.localExpanded || (y(), (d() || n.value) && g());
33
33
  }, k = () => {
34
- e.text && (l.offset = e.text.length, C(), e.autoResize && a.value && (I(a.value, c), l.unregisterResizeCallback = () => {
35
- a.value && J(a.value, c);
34
+ e.text && (l.offset = e.text.length, C(), e.autoResize && a.value && (J(a.value, c), l.unregisterResizeCallback = () => {
35
+ a.value && K(a.value, c);
36
36
  }), c());
37
37
  }, C = () => {
38
38
  l.unregisterResizeCallback?.();
@@ -112,15 +112,15 @@ const P = ["title", "aria-label"], Q = M({
112
112
  }
113
113
  ), V(() => {
114
114
  C();
115
- }), p(() => {
115
+ }), q(() => {
116
116
  k();
117
117
  }), T({
118
118
  isClamped: n
119
- }), (t, i) => (D(), q("div", {
119
+ }), (t, i) => (G(), D("div", {
120
120
  ref_key: "textClampRef",
121
121
  ref: a,
122
122
  class: "text-clamp",
123
- style: G({
123
+ style: I({
124
124
  overflow: "hidden",
125
125
  maxHeight: j.value
126
126
  })
@@ -139,9 +139,9 @@ const P = ["title", "aria-label"], Q = M({
139
139
  w("span", {
140
140
  ref_key: "textRef",
141
141
  ref: x,
142
- title: t.text,
143
- "aria-label": t.text
144
- }, null, 8, P),
142
+ title: e.text,
143
+ "aria-label": e.text
144
+ }, null, 8, Q),
145
145
  B(t.$slots, "after", {
146
146
  expand: L,
147
147
  collapse: b,
@@ -1,19 +1,19 @@
1
- import { defineComponent as i, computed as p, createBlock as g, openBlock as l, unref as a, normalizeStyle as c, withCtx as d, createElementBlock as u, createCommentVNode as f, normalizeClass as x, toDisplayString as z } from "vue";
2
- import { VftClamp as C } from "../clamp/index.js";
1
+ import { defineComponent as a, computed as s, createBlock as c, openBlock as o, unref as l, normalizeStyle as g, withCtx as d, createElementBlock as u, createCommentVNode as x, normalizeClass as f, toDisplayString as p } from "vue";
2
+ import { VftClamp as z } from "../clamp/index.js";
3
3
  import "@vueuse/core";
4
4
  import "@vft/utils";
5
5
  import "../config-provider/hooks/use-global-config.js";
6
- import { generateCssVars as h } from "../../utils/ns-cover.js";
6
+ import { generateCssVars as C } from "../../utils/ns-cover.js";
7
7
  import "lodash-es";
8
8
  import "../form/index.js";
9
- import { useNamespace as y } from "../../hooks/use-namespace/index.js";
9
+ import { useNamespace as h } from "../../hooks/use-namespace/index.js";
10
10
  import "../../hooks/use-model-toggle/index.js";
11
11
  import "@popperjs/core";
12
12
  import "../../hooks/use-z-index/index.js";
13
- const k = ["onClick"], B = i({
13
+ const y = ["onClick"], k = a({
14
14
  name: "vft-clamp-toggle"
15
- }), A = /* @__PURE__ */ i({
16
- ...B,
15
+ }), A = /* @__PURE__ */ a({
16
+ ...k,
17
17
  props: {
18
18
  text: {},
19
19
  maxHeight: {},
@@ -28,13 +28,13 @@ const k = ["onClick"], B = i({
28
28
  toggleSize: {},
29
29
  toggleText: { default: () => ["展开", "收缩"] }
30
30
  },
31
- setup(t) {
32
- const r = y("clamp-toggle"), s = p(() => h(
33
- { color: t.color, size: t.size, toggleColor: t.toggleColor, toggleSize: t.toggleSize },
31
+ setup(e) {
32
+ const i = h("clamp-toggle"), n = s(() => C(
33
+ { color: e.color, size: e.size, toggleColor: e.toggleColor, toggleSize: e.toggleSize },
34
34
  "clamp-toggle"
35
35
  ));
36
- return (e, S) => (l(), g(a(C), {
37
- style: c(s.value),
36
+ return (B, S) => (o(), c(l(z), {
37
+ style: g(n.value),
38
38
  text: e.text,
39
39
  "max-height": e.maxHeight,
40
40
  "max-lines": e.maxLines,
@@ -43,12 +43,12 @@ const k = ["onClick"], B = i({
43
43
  ellipsis: e.ellipsis,
44
44
  "auto-resize": e.autoResize
45
45
  }, {
46
- after: d(({ toggle: n, expanded: o, clamped: m }) => [
47
- o || m ? (l(), u("span", {
46
+ after: d(({ toggle: m, expanded: t, clamped: r }) => [
47
+ t || r ? (o(), u("span", {
48
48
  key: 0,
49
- class: x(["cursor-pointer", a(r).e("more")]),
50
- onClick: n
51
- }, z(o ? e.toggleText[1] : e.toggleText[0]), 11, k)) : f("", !0)
49
+ class: f(["cursor-pointer", l(i).e("more")]),
50
+ onClick: m
51
+ }, p(t ? e.toggleText[1] : e.toggleText[0]), 11, y)) : x("", !0)
52
52
  ]),
53
53
  _: 1
54
54
  }, 8, ["style", "text", "max-height", "max-lines", "expanded", "location", "ellipsis", "auto-resize"]));
@@ -1,8 +1,8 @@
1
- import { defineComponent as s, ref as f, createElementBlock as c, openBlock as t, Fragment as u, createVNode as l, createBlock as n, unref as e, withCtx as r, mergeProps as m } from "vue";
2
- import { createReusableTemplate as d } from "@vueuse/core";
3
- import { VftClamp as _ } from "../clamp/index.js";
4
- import { VftTooltip as k } from "../tooltip/index.js";
5
- const R = /* @__PURE__ */ s({
1
+ import { defineComponent as c, ref as s, createElementBlock as u, openBlock as o, Fragment as d, createVNode as l, createBlock as p, unref as e, withCtx as m, mergeProps as r } from "vue";
2
+ import { createReusableTemplate as x } from "@vueuse/core";
3
+ import { VftClamp as k } from "../clamp/index.js";
4
+ import { VftTooltip as y } from "../tooltip/index.js";
5
+ const R = /* @__PURE__ */ c({
6
6
  __name: "clamp-tooltip",
7
7
  props: {
8
8
  showTooltip: { type: Boolean },
@@ -15,28 +15,28 @@ const R = /* @__PURE__ */ s({
15
15
  autoResize: { type: Boolean },
16
16
  location: {}
17
17
  },
18
- setup(y) {
19
- const p = f(), [i, a] = d();
20
- return (o, B) => (t(), c(u, null, [
18
+ setup(t) {
19
+ const a = s(), [i, n] = x();
20
+ return (f, B) => (o(), u(d, null, [
21
21
  l(e(i), null, {
22
- default: r(() => [
23
- l(e(_), m({
22
+ default: m(() => [
23
+ l(e(k), r({
24
24
  ref_key: "clampRef",
25
- ref: p
26
- }, o.$props), null, 16)
25
+ ref: a
26
+ }, f.$props), null, 16)
27
27
  ]),
28
28
  _: 1
29
29
  }),
30
- o.showTooltip ? (t(), n(e(k), m({
30
+ t.showTooltip ? (o(), p(e(y), r({
31
31
  key: 0,
32
- disabled: !p.value?.isClamped,
33
- content: o.text
34
- }, o.tooltipCfg), {
35
- default: r(() => [
36
- l(e(a))
32
+ disabled: !a.value?.isClamped,
33
+ content: t.text
34
+ }, t.tooltipCfg), {
35
+ default: m(() => [
36
+ l(e(n))
37
37
  ]),
38
38
  _: 1
39
- }, 16, ["disabled", "content"])) : (t(), n(e(a), { key: 1 }))
39
+ }, 16, ["disabled", "content"])) : (o(), p(e(n), { key: 1 }))
40
40
  ], 64));
41
41
  }
42
42
  });