@pantograph/vue 0.10.1 → 0.10.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (217) hide show
  1. package/dist/ActionButton/ActionButton.d.ts +79 -3
  2. package/dist/ActionButton/index.js.js +1 -1
  3. package/dist/ActionButton/index.umd.cjs.js +1 -1
  4. package/dist/{ActionButton.vue_vue_type_script_setup_true_lang-KL8JuFlI.js → ActionButton.vue_vue_type_script_setup_true_lang-Bmld__SV.js} +1 -2
  5. package/dist/ActionButton.vue_vue_type_script_setup_true_lang-Bno9iBJg.js +1 -0
  6. package/dist/Avatar/Avatar.d.ts +14 -7
  7. package/dist/Avatar/index.js.js +1 -1
  8. package/dist/Avatar/index.umd.cjs.js +1 -1
  9. package/dist/Avatar.vue_vue_type_style_index_0_lang-BBmLnOBV.js +1 -0
  10. package/dist/Avatar.vue_vue_type_style_index_0_lang-ZqNWAzDy.js +182 -0
  11. package/dist/AvatarGroup/AvatarGroup.d.ts +3 -6
  12. package/dist/AvatarGroup/index.js.js +1 -1
  13. package/dist/AvatarGroup/index.umd.cjs.js +1 -1
  14. package/dist/Badge/Badge.d.ts +9 -2
  15. package/dist/Badge/index.js.js +1 -1
  16. package/dist/Badge/index.umd.cjs.js +1 -1
  17. package/dist/{Badge.vue_vue_type_script_setup_true_lang-nmw9qfJ_.js → Badge.vue_vue_type_script_setup_true_lang-CCIamdNB.js} +1 -2
  18. package/dist/Badge.vue_vue_type_script_setup_true_lang-ooDlpl8j.js +1 -0
  19. package/dist/Base/BaseBadge/BaseBadge.d.ts +12 -7
  20. package/dist/Base/BaseButton/BaseButton.d.ts +14 -7
  21. package/dist/BaseBadge.vue_vue_type_style_index_0_lang-BNs69VP4.js +1 -0
  22. package/dist/{BaseBadge.vue_vue_type_style_index_0_lang-MM6bsdzR.js → BaseBadge.vue_vue_type_style_index_0_lang-Bh1152XC.js} +46 -52
  23. package/dist/BaseButton.vue_vue_type_style_index_0_lang-4ju_QUXH.js +1 -0
  24. package/dist/BaseButton.vue_vue_type_style_index_0_lang-CEY27kcT.js +160 -0
  25. package/dist/Button/Button.d.ts +79 -3
  26. package/dist/Button/index.js.js +1 -1
  27. package/dist/Button/index.umd.cjs.js +1 -1
  28. package/dist/{Button.vue_vue_type_script_setup_true_lang-DIj3gT2D.js → Button.vue_vue_type_script_setup_true_lang-BHumLt2E.js} +5 -6
  29. package/dist/Button.vue_vue_type_script_setup_true_lang-BZ0h9oaW.js +1 -0
  30. package/dist/ButtonGroup/ButtonGroup.d.ts +3 -5
  31. package/dist/ButtonGroup/index.js.js +1 -1
  32. package/dist/ButtonGroup/index.umd.cjs.js +1 -1
  33. package/dist/ButtonGroup.vue_vue_type_script_setup_true_lang-CT_Kgpjf.js +47 -0
  34. package/dist/ButtonGroup.vue_vue_type_script_setup_true_lang-D486_o-Z.js +1 -0
  35. package/dist/Checkbox/Checkbox.d.ts +12 -4
  36. package/dist/Checkbox/index.js.js +1 -1
  37. package/dist/Checkbox/index.umd.cjs.js +1 -1
  38. package/dist/Checkbox.vue_vue_type_style_index_0_lang-CSmeTeZh.js +209 -0
  39. package/dist/Checkbox.vue_vue_type_style_index_0_lang-D0sF0-hW.js +1 -0
  40. package/dist/CheckboxGroup/CheckboxGroup.d.ts +2 -5
  41. package/dist/CheckboxGroup/index.js.js +1 -1
  42. package/dist/CheckboxGroup/index.umd.cjs.js +1 -1
  43. package/dist/ColorPicker/index.js.js +1 -1
  44. package/dist/ColorPicker/index.umd.cjs.js +1 -1
  45. package/dist/{ColorPicker.vue_vue_type_style_index_0_lang-Dq-kFXox.js → ColorPicker.vue_vue_type_style_index_0_lang-Bj735O4E.js} +2 -2
  46. package/dist/{ColorPicker.vue_vue_type_style_index_0_lang-C36JPo4m.js → ColorPicker.vue_vue_type_style_index_0_lang-C86gVRVp.js} +1 -1
  47. package/dist/ColorSwatch/ColorSwatch.d.ts +11 -4
  48. package/dist/ColorSwatch/index.js.js +1 -1
  49. package/dist/ColorSwatch/index.umd.cjs.js +1 -1
  50. package/dist/ColorSwatch.vue_vue_type_style_index_0_lang-8sQWWbLp.js +100 -0
  51. package/dist/ColorSwatch.vue_vue_type_style_index_0_lang-Bt9Tu3La.js +1 -0
  52. package/dist/ColorSwatchGroup/ColorSwatchGroup.d.ts +17 -11
  53. package/dist/ColorSwatchGroup/index.js.js +1 -1
  54. package/dist/ColorSwatchGroup/index.umd.cjs.js +1 -1
  55. package/dist/ColorSwatchGroup.vue_vue_type_style_index_0_lang-BiHYDJTg.js +159 -0
  56. package/dist/ColorSwatchGroup.vue_vue_type_style_index_0_lang-DmF-FkKK.js +1 -0
  57. package/dist/ColorTrigger/ColorTrigger.d.ts +13 -5
  58. package/dist/ColorTrigger/index.js.js +1 -1
  59. package/dist/ColorTrigger/index.umd.cjs.js +1 -1
  60. package/dist/ColorTrigger.vue_vue_type_style_index_0_lang-BNFu93Ns.js +86 -0
  61. package/dist/ColorTrigger.vue_vue_type_style_index_0_lang-C8kPa338.js +1 -0
  62. package/dist/ConfigProvider/index.d.ts +6 -6
  63. package/dist/ConfigProvider/utils.d.ts +2 -2
  64. package/dist/Divider/Divider.d.ts +13 -8
  65. package/dist/Divider/index.js.js +1 -1
  66. package/dist/Divider/index.umd.cjs.js +1 -1
  67. package/dist/Divider.vue_vue_type_style_index_0_lang-BELWThBf.js +1 -0
  68. package/dist/Divider.vue_vue_type_style_index_0_lang-CRs1KEcj.js +34 -0
  69. package/dist/FloatButton/FloatButton.d.ts +79 -3
  70. package/dist/FloatButton/index.js.js +1 -1
  71. package/dist/FloatButton/index.umd.cjs.js +1 -1
  72. package/dist/{FloatButton.vue_vue_type_script_setup_true_lang-Bapsnc_p.js → FloatButton.vue_vue_type_script_setup_true_lang-Bg4MdrWW.js} +1 -2
  73. package/dist/FloatButton.vue_vue_type_script_setup_true_lang-Bsmuycb8.js +1 -0
  74. package/dist/GraphicalObject/GraphicalObject.d.ts +9 -2
  75. package/dist/GraphicalObject/index.js.js +1 -1
  76. package/dist/GraphicalObject/index.umd.cjs.js +1 -1
  77. package/dist/{GraphicalObject.vue_vue_type_script_setup_true_lang-B3FouRlw.js → GraphicalObject.vue_vue_type_script_setup_true_lang-BEZ6FkRf.js} +1 -2
  78. package/dist/GraphicalObject.vue_vue_type_script_setup_true_lang-CdO2zArd.js +1 -0
  79. package/dist/Icon/Icon.d.ts +11 -4
  80. package/dist/IconButton/IconButton.d.ts +79 -3
  81. package/dist/IconButton/index.js.js +1 -1
  82. package/dist/IconButton/index.umd.cjs.js +1 -1
  83. package/dist/{IconButton.vue_vue_type_script_setup_true_lang-dI6-RNyi.js → IconButton.vue_vue_type_script_setup_true_lang-DJGgntqa.js} +1 -2
  84. package/dist/IconButton.vue_vue_type_script_setup_true_lang-DU9MPZq2.js +1 -0
  85. package/dist/Image/Image.d.ts +16 -8
  86. package/dist/Image/index.js.js +1 -1
  87. package/dist/Image/index.umd.cjs.js +1 -1
  88. package/dist/{Image.vue_vue_type_style_index_0_lang-DbqKKOAs.js → Image.vue_vue_type_style_index_0_lang-Hg1jFz-L.js} +1 -1
  89. package/dist/{Image.vue_vue_type_style_index_0_lang-Cku5hiNE.js → Image.vue_vue_type_style_index_0_lang-pkzjPQyu.js} +2 -2
  90. package/dist/IndentLevel/IndentLevel.d.ts +14 -8
  91. package/dist/IndentLevel/index.js.js +1 -1
  92. package/dist/IndentLevel/index.umd.cjs.js +1 -1
  93. package/dist/IndentLevel.vue_vue_type_style_index_0_lang-DqqJTrDF.js +1 -0
  94. package/dist/IndentLevel.vue_vue_type_style_index_0_lang-ZZ1uEhji.js +94 -0
  95. package/dist/Indicator/Indicator.d.ts +9 -2
  96. package/dist/Indicator/index.js.js +1 -1
  97. package/dist/Indicator/index.umd.cjs.js +1 -1
  98. package/dist/{Indicator.vue_vue_type_script_setup_true_lang-ICqvLVbq.js → Indicator.vue_vue_type_script_setup_true_lang-B16OmZLF.js} +1 -2
  99. package/dist/Indicator.vue_vue_type_script_setup_true_lang-BibzfVax.js +1 -0
  100. package/dist/Input/Input.d.ts +15 -7
  101. package/dist/Input/index.js.js +1 -1
  102. package/dist/Input/index.umd.cjs.js +1 -1
  103. package/dist/Input.vue_vue_type_style_index_0_lang-CcR6oCIR.js +407 -0
  104. package/dist/Input.vue_vue_type_style_index_0_lang-DVN491cI.js +1 -0
  105. package/dist/Kbd/Kbd.d.ts +13 -9
  106. package/dist/Kbd/index.js.js +1 -1
  107. package/dist/Kbd/index.umd.cjs.js +1 -1
  108. package/dist/Kbd.vue_vue_type_style_index_0_lang-CpDjSQqg.js +1 -0
  109. package/dist/Kbd.vue_vue_type_style_index_0_lang-D1y-0kBN.js +47 -0
  110. package/dist/Menu/Menu.d.ts +9 -10
  111. package/dist/Menu/index.js.js +1 -1
  112. package/dist/Menu/index.umd.cjs.js +1 -1
  113. package/dist/Menu.vue_vue_type_style_index_0_lang-CG9UOulA.js +1 -0
  114. package/dist/Menu.vue_vue_type_style_index_0_lang-CtqLC5y9.js +482 -0
  115. package/dist/MenuItem/MenuItem.d.ts +1 -1
  116. package/dist/MenuItem/index.js.js +1 -1
  117. package/dist/MenuItem/index.umd.cjs.js +1 -1
  118. package/dist/Popover/Popover.d.ts +83 -5
  119. package/dist/Popover/index.js.js +1 -1
  120. package/dist/Popover/index.umd.cjs.js +1 -1
  121. package/dist/Popover.vue_vue_type_style_index_0_lang-DRMPu5Ij.js +1 -0
  122. package/dist/{Popover.vue_vue_type_style_index_0_lang-C0IwnsU5.js → Popover.vue_vue_type_style_index_0_lang-vZfwRHoU.js} +22 -21
  123. package/dist/RadioGroup/RadioGroup.d.ts +12 -5
  124. package/dist/RadioGroup/RadioGroupItem.d.ts +11 -3
  125. package/dist/RadioGroup/index.d.ts +1 -1
  126. package/dist/RadioGroup/index.js.js +3 -2
  127. package/dist/RadioGroup/index.umd.cjs.js +1 -1
  128. package/dist/RadioGroup.vue_vue_type_script_setup_true_lang-C8nd4TEI.js +100 -0
  129. package/dist/RadioGroup.vue_vue_type_script_setup_true_lang-DjEHmvMo.js +1 -0
  130. package/dist/Shortcut/Shortcut.d.ts +1 -2
  131. package/dist/Shortcut/index.js.js +1 -1
  132. package/dist/Shortcut/index.umd.cjs.js +1 -1
  133. package/dist/Shortcut.vue_vue_type_style_index_0_lang-D4xo_UgO.js +32 -0
  134. package/dist/Shortcut.vue_vue_type_style_index_0_lang-D8_aLpYM.js +1 -0
  135. package/dist/Skeleton/Skeleton.d.ts +4 -8
  136. package/dist/Skeleton/index.js.js +1 -1
  137. package/dist/Skeleton/index.umd.cjs.js +1 -1
  138. package/dist/Skeleton.vue_vue_type_style_index_0_lang-BjcjY70B.js +58 -0
  139. package/dist/Skeleton.vue_vue_type_style_index_0_lang-gJRxIuPb.js +1 -0
  140. package/dist/Spinner/Spinner.d.ts +11 -6
  141. package/dist/Spinner/index.js.js +1 -1
  142. package/dist/Spinner/index.umd.cjs.js +1 -1
  143. package/dist/Spinner.vue_vue_type_style_index_0_lang-BP7P5xu8.js +1 -0
  144. package/dist/Spinner.vue_vue_type_style_index_0_lang-BYqqSQAx.js +73 -0
  145. package/dist/Switch/Switch.d.ts +14 -3
  146. package/dist/Switch/index.js.js +1 -1
  147. package/dist/Switch/index.umd.cjs.js +1 -1
  148. package/dist/Switch.vue_vue_type_style_index_0_lang-CoXu3YJ-.js +1 -0
  149. package/dist/Switch.vue_vue_type_style_index_0_lang-CvWay8Wa.js +106 -0
  150. package/dist/Tree/Tree.d.ts +12 -3
  151. package/dist/Tree/TreeNode.d.ts +11 -2
  152. package/dist/Tree/index.js.js +1 -1
  153. package/dist/Tree/index.umd.cjs.js +1 -1
  154. package/dist/Tree.vue_vue_type_style_index_0_lang-BCYjSwUH.js +545 -0
  155. package/dist/Tree.vue_vue_type_style_index_0_lang-CvskECfv.js +1 -0
  156. package/dist/index.js.js +66 -62
  157. package/dist/index.umd.cjs.js +1 -1
  158. package/dist/style/index.css +1 -1
  159. package/dist/useId-DvOSMFGX.js +9 -0
  160. package/dist/useId-Ku3O_8TK.js +1 -0
  161. package/dist/useInputDataStates-CZbdWpyp.js +26 -0
  162. package/dist/useInputDataStates-CbRgNQqU.js +1 -0
  163. package/dist/utils/index.d.ts +2 -0
  164. package/dist/utils/index.js.js +10 -6
  165. package/dist/utils/index.umd.cjs.js +1 -1
  166. package/dist/utils/useId.d.ts +1 -0
  167. package/dist/utils/useInputDataStates.d.ts +19 -0
  168. package/package.json +7 -3
  169. package/dist/ActionButton.vue_vue_type_script_setup_true_lang-BVtP6mpl.js +0 -1
  170. package/dist/Avatar.vue_vue_type_style_index_0_lang-BHYcXGuX.js +0 -188
  171. package/dist/Avatar.vue_vue_type_style_index_0_lang-DKGY3npY.js +0 -1
  172. package/dist/Badge.vue_vue_type_script_setup_true_lang-BcdNUohN.js +0 -1
  173. package/dist/Base/Primitive.d.ts +0 -39
  174. package/dist/Base/Slot.d.ts +0 -6
  175. package/dist/BaseBadge.vue_vue_type_style_index_0_lang-OEeJw0Sy.js +0 -1
  176. package/dist/BaseButton.vue_vue_type_style_index_0_lang-BrQJfrgg.js +0 -159
  177. package/dist/BaseButton.vue_vue_type_style_index_0_lang-CTK5nNR6.js +0 -1
  178. package/dist/Button.vue_vue_type_script_setup_true_lang-7V57ztN4.js +0 -1
  179. package/dist/ButtonGroup.vue_vue_type_script_setup_true_lang-BSj1Y1j2.js +0 -1
  180. package/dist/ButtonGroup.vue_vue_type_script_setup_true_lang-CdSgBboA.js +0 -52
  181. package/dist/Checkbox.vue_vue_type_style_index_0_lang-C6Mdufam.js +0 -1
  182. package/dist/Checkbox.vue_vue_type_style_index_0_lang-DNlvOQmv.js +0 -216
  183. package/dist/ColorSwatch.vue_vue_type_style_index_0_lang-Bo-zDAyc.js +0 -1
  184. package/dist/ColorSwatch.vue_vue_type_style_index_0_lang-DmLhCPh4.js +0 -102
  185. package/dist/ColorSwatchGroup.vue_vue_type_style_index_0_lang-CIkTvqD_.js +0 -165
  186. package/dist/ColorSwatchGroup.vue_vue_type_style_index_0_lang-T_L-D2SS.js +0 -1
  187. package/dist/ColorTrigger.vue_vue_type_style_index_0_lang-DSZ8fAZ9.js +0 -91
  188. package/dist/ColorTrigger.vue_vue_type_style_index_0_lang-DwyinKNj.js +0 -1
  189. package/dist/Divider.vue_vue_type_style_index_0_lang-B_4XMyuu.js +0 -40
  190. package/dist/Divider.vue_vue_type_style_index_0_lang-C6Suy0tD.js +0 -1
  191. package/dist/FloatButton.vue_vue_type_script_setup_true_lang-C56u1xaL.js +0 -1
  192. package/dist/GraphicalObject.vue_vue_type_script_setup_true_lang-DlMeNk_1.js +0 -1
  193. package/dist/IconButton.vue_vue_type_script_setup_true_lang-7QB-mmyg.js +0 -1
  194. package/dist/IndentLevel.vue_vue_type_style_index_0_lang-CM6s5E6c.js +0 -1
  195. package/dist/IndentLevel.vue_vue_type_style_index_0_lang-nGsyFkwr.js +0 -104
  196. package/dist/Indicator.vue_vue_type_script_setup_true_lang-C4Ecg4iy.js +0 -1
  197. package/dist/Input.vue_vue_type_style_index_0_lang-D0zx-hd_.js +0 -1
  198. package/dist/Input.vue_vue_type_style_index_0_lang-cjYJlwXf.js +0 -413
  199. package/dist/Kbd.vue_vue_type_style_index_0_lang-BqEaW_kJ.js +0 -1
  200. package/dist/Kbd.vue_vue_type_style_index_0_lang-DbtLbpq-.js +0 -60
  201. package/dist/Menu.vue_vue_type_style_index_0_lang-DHGED80D.js +0 -481
  202. package/dist/Menu.vue_vue_type_style_index_0_lang-DU0Rexv8.js +0 -1
  203. package/dist/Popover.vue_vue_type_style_index_0_lang-CM8qMFEi.js +0 -1
  204. package/dist/Primitive-BT1RjuGS.js +0 -1
  205. package/dist/Primitive-nOVjbfuc.js +0 -47
  206. package/dist/RadioGroup.vue_vue_type_script_setup_true_lang-DWfKIuDH.js +0 -100
  207. package/dist/RadioGroup.vue_vue_type_script_setup_true_lang-s-m7W1By.js +0 -1
  208. package/dist/Shortcut.vue_vue_type_style_index_0_lang-BQb7DjFe.js +0 -41
  209. package/dist/Shortcut.vue_vue_type_style_index_0_lang-C49ZdQFd.js +0 -1
  210. package/dist/Skeleton.vue_vue_type_style_index_0_lang-B6bCkLlD.js +0 -66
  211. package/dist/Skeleton.vue_vue_type_style_index_0_lang-PNNUgKOq.js +0 -1
  212. package/dist/Spinner.vue_vue_type_style_index_0_lang-CxNO28J7.js +0 -1
  213. package/dist/Spinner.vue_vue_type_style_index_0_lang-D6nB06Z8.js +0 -85
  214. package/dist/Switch.vue_vue_type_style_index_0_lang-BzC8-ylY.js +0 -103
  215. package/dist/Switch.vue_vue_type_style_index_0_lang-DnNHGn1c.js +0 -1
  216. package/dist/Tree.vue_vue_type_style_index_0_lang-B-BPV_p7.js +0 -547
  217. package/dist/Tree.vue_vue_type_style_index_0_lang-BIpFWo5L.js +0 -1
@@ -1,11 +1,10 @@
1
- import { defineComponent as _, useSlots as C, computed as a, createBlock as u, openBlock as o, unref as r, normalizeStyle as h, normalizeClass as S, withCtx as m, createElementBlock as w, createCommentVNode as p, Fragment as V, renderSlot as f, createTextVNode as $, toDisplayString as I } from "vue";
2
- import { Primitive as N } from "radix-vue";
3
- import { g as P, a as i } from "./class-DziTeW9B.js";
1
+ import { defineComponent as k, useSlots as _, computed as a, createElementBlock as c, openBlock as o, normalizeStyle as C, normalizeClass as h, unref as u, createCommentVNode as m, Fragment as S, createBlock as w, renderSlot as p, withCtx as V, createTextVNode as $, toDisplayString as I } from "vue";
2
+ import { g as N, a as l } from "./class-DziTeW9B.js";
4
3
  import { cva as T } from "class-variance-authority";
5
4
  import { g as D } from "./options-JBqnVZUl.js";
6
5
  import "@iconify/vue";
7
6
  import { _ as E } from "./Icon.vue_vue_type_style_index_0_lang-BfPcw6PU.js";
8
- const b = ["2xsm", "xsm", "sm", "md", "tiny", "tinier"], d = ["rect", "pill", "minify"], J = [
7
+ const b = ["2xsm", "xsm", "sm", "md", "tiny", "tinier"], d = ["rect", "pill", "minify"], G = [
9
8
  "primary",
10
9
  "red",
11
10
  "orange",
@@ -23,7 +22,7 @@ const b = ["2xsm", "xsm", "sm", "md", "tiny", "tinier"], d = ["rect", "pill", "m
23
22
  "fuchsia",
24
23
  "pink",
25
24
  "gray"
26
- ], K = [
25
+ ], H = [
27
26
  "primary-subtle",
28
27
  "red-subtle",
29
28
  "orange-subtle",
@@ -41,7 +40,7 @@ const b = ["2xsm", "xsm", "sm", "md", "tiny", "tinier"], d = ["rect", "pill", "m
41
40
  "fuchsia-subtle",
42
41
  "pink-subtle",
43
42
  "gray-subtle"
44
- ], M = /* @__PURE__ */ _({
43
+ ], J = /* @__PURE__ */ k({
45
44
  ...D("BaseBadge"),
46
45
  __name: "BaseBadge",
47
46
  props: {
@@ -52,23 +51,22 @@ const b = ["2xsm", "xsm", "sm", "md", "tiny", "tinier"], d = ["rect", "pill", "m
52
51
  fg: {},
53
52
  br: {},
54
53
  type: { default: "pill" },
55
- icon: {},
56
- as: { default: "div" }
54
+ icon: {}
57
55
  },
58
- setup(y) {
59
- const l = P("badge"), t = y, g = T(l, {
56
+ setup(f) {
57
+ const n = N("badge"), t = f, y = T(n, {
60
58
  variants: {
61
- size: i(b, l),
62
- type: i(d, l),
63
- text: i("text", l),
64
- icon: i("icon", l),
65
- br: i("br", l)
59
+ size: l(b, n),
60
+ type: l(d, n),
61
+ text: l("text", n),
62
+ icon: l("icon", n),
63
+ br: l("br", n)
66
64
  }
67
- }), n = C(), s = a(() => d.includes(t.type) ? t.type : "pill"), v = a(() => !!(t.text || n.default)), B = a(() => !!(t.icon || n.icon)), c = a(() => {
65
+ }), i = _(), s = a(() => d.includes(t.type) ? t.type : "pill"), g = a(() => !!(t.text || i.default)), v = a(() => !!(t.icon || i.icon)), r = a(() => {
68
66
  let e = b.includes(t.size) ? t.size : "md";
69
67
  return e === "sm" && s.value !== "rect" ? s.value === "minify" ? e = "tiny" : s.value === "pill" && (e = "md") : s.value === "minify" && !["tiny", "tinier"].includes(e) ? e = "tiny" : s.value !== "minify" && ["tiny", "tinier"].includes(e) && (e = "md"), e;
70
- }), x = a(() => {
71
- switch (c.value) {
68
+ }), B = a(() => {
69
+ switch (r.value) {
72
70
  case "sm":
73
71
  return "xsm";
74
72
  case "xsm":
@@ -79,51 +77,47 @@ const b = ["2xsm", "xsm", "sm", "md", "tiny", "tinier"], d = ["rect", "pill", "m
79
77
  default:
80
78
  return "sm";
81
79
  }
82
- }), z = a(() => ({
83
- size: c.value,
80
+ }), x = a(() => ({
81
+ size: r.value,
84
82
  // color,
85
83
  type: s.value,
86
- text: v.value,
87
- icon: B.value,
84
+ text: g.value,
85
+ icon: v.value,
88
86
  br: !!t.br
89
- })), k = a(() => {
90
- const e = n.icon ?? t.icon;
91
- return t.type === "rect" && (n.default || t.text) ? !1 : e;
87
+ })), z = a(() => {
88
+ const e = i.icon ?? t.icon;
89
+ return t.type === "rect" && (i.default || t.text) ? !1 : e;
92
90
  });
93
- return (e, F) => (o(), u(r(N), {
94
- as: e.as,
95
- class: S([r(g)(z.value), t.class]),
96
- style: h({
91
+ return (e, F) => (o(), c("div", {
92
+ class: h([u(y)(x.value), t.class]),
93
+ style: C({
97
94
  "--ptc-badge-fg": t.fg,
98
95
  "--ptc-badge-bg": t.bg,
99
96
  "--ptc-badge-br": t.br
100
97
  })
101
- }, {
102
- default: m(() => [
103
- s.value !== "minify" ? (o(), w(V, { key: 0 }, [
104
- k.value ? (o(), u(r(E), {
105
- key: 0,
106
- icon: e.icon,
107
- size: x.value
108
- }, {
109
- default: m(() => [
110
- f(e.$slots, "icon")
111
- ]),
112
- _: 3
113
- }, 8, ["icon", "size"])) : p("", !0),
114
- f(e.$slots, "default", {}, () => [
115
- $(I(e.text), 1)
116
- ])
117
- ], 64)) : p("", !0)
118
- ]),
119
- _: 3
120
- }, 8, ["as", "class", "style"]));
98
+ }, [
99
+ s.value !== "minify" ? (o(), c(S, { key: 0 }, [
100
+ z.value ? (o(), w(u(E), {
101
+ key: 0,
102
+ icon: e.icon,
103
+ size: B.value
104
+ }, {
105
+ default: V(() => [
106
+ p(e.$slots, "icon")
107
+ ]),
108
+ _: 3
109
+ }, 8, ["icon", "size"])) : m("", !0),
110
+ p(e.$slots, "default", {}, () => [
111
+ $(I(e.text), 1)
112
+ ])
113
+ ], 64)) : m("", !0)
114
+ ], 6));
121
115
  }
122
116
  });
123
117
  export {
124
- K as B,
125
- M as _,
126
- J as a,
118
+ H as B,
119
+ J as _,
120
+ G as a,
127
121
  b,
128
122
  d as c
129
123
  };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("vue"),g=require("./Icon.vue_vue_type_style_index_0_lang-BvHCdzZP.js"),b=require("./Spinner.vue_vue_type_style_index_0_lang-BP7P5xu8.js"),k=require("./Badge.vue_vue_type_script_setup_true_lang-ooDlpl8j.js"),i=require("./ButtonGroup.vue_vue_type_script_setup_true_lang-D486_o-Z.js"),a=require("./class-CjZYGZDW.js"),V=require("class-variance-authority"),S=require("./options-B4iSAKol.js"),f="2xsm",x=e.defineComponent({...S.getComponentOptions("BaseButton"),__name:"BaseButton",props:{class:{},text:{},size:{},color:{default:"primary"},type:{default:"fill"},variant:{},loading:{type:Boolean},action:{type:Boolean},active:{type:Boolean},badgeText:{},badgeIcon:{},icon:{},preIcon:{},postIcon:{}},setup(y,{expose:B}){const o=y,n=a.getBemBlock("button"),_=V.cva(n,{variants:{size:a.generateVariantClassList(i.ButtonSizes,n),type:a.generateVariantClassList(i.ButtonTypes,n),color:a.generateVariantClassList(i.ButtonColors,n),variant:a.generateVariantClassList(i.ButtonVariants,n),action:a.generateVariantClassList("action",n),active:a.generateVariantClassList("active",n),text:a.generateVariantClassList("text",n),preIcon:a.generateVariantClassList("preIcon",n),postIcon:a.generateVariantClassList("postIcon",n),loading:a.generateVariantClassList("loading",n)}}),v=i.injectButtonGroupContext({size:e.computed(()=>o.size),variant:e.computed(()=>o.variant)}),l=e.computed(()=>o.variant??v.variant.value??"simple"),r=e.computed(()=>["icon","float"].includes(l.value)),s=e.useSlots(),I=e.computed(()=>{let t=i.ButtonTypes.includes(o.type)?o.type:"fill";const c=o.size??v.size.value,C=c&&i.ButtonSizes.includes(c)?c:"md";let u=o.color&&i.ButtonColors.includes(o.color)?o.color:"primary",p=l.value&&i.ButtonVariants.includes(l.value)?l.value:"simple";return o.action?(p==="float"&&(p="icon"),t==="fill"&&(t="outline"),u=void 0):p==="float"&&(t==="ghost"&&(t="fill"),["primary","gray"].includes(u)||(u="primary")),{size:C,type:t,color:u,variant:p,action:o.action,active:o.active,loading:o.loading,text:!r.value&&!!(o.text||s.default),preIcon:!r.value&&!!(o.preIcon||s.preIcon),postIcon:!r.value&&!!(o.postIcon||s.postIcon)}}),d=e.computed(()=>{switch(o.size){case"sm":return"3xsm";default:return"2xsm"}}),z=e.computed(()=>{switch(o.size){case"sm":return"3xsm";case"lg":return"xsm";case"md":default:return"2xsm"}}),m=e.ref();return B({focus(){var t;(t=m.value)==null||t.focus()},blur(){var t;(t=m.value)==null||t.blur()}}),(t,c)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass([e.unref(_)(I.value),o.class]),tabindex:"0",ref_key:"buttonRef",ref:m},[t.loading?(e.openBlock(),e.createBlock(b._sfc_main,{key:1,class:e.normalizeClass(e.unref(a.getBemElement)(e.unref(n),"loading")),size:d.value},null,8,["class","size"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(t.preIcon||s.preIcon)&&!r.value?(e.openBlock(),e.createBlock(g._sfc_main,{key:0,icon:t.preIcon,size:d.value},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"preIcon")]),_:3},8,["icon","size"])):e.createCommentVNode("",!0),r.value?(e.openBlock(),e.createBlock(g._sfc_main,{key:1,icon:t.icon,size:z.value},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"icon")]),_:3},8,["icon","size"])):e.renderSlot(t.$slots,"default",{key:2},()=>[e.createTextVNode(e.toDisplayString(t.text),1)]),t.action&&t.active&&!r.value&&(t.badgeText||s.badgeText||t.badgeIcon||s.badgeIcon)?e.renderSlot(t.$slots,"badge",e.normalizeProps(e.mergeProps({key:3},{color:t.$attrs.disabled?"gray":"primary",size:f})),()=>[e.createVNode(k._sfc_main,{text:t.badgeText,icon:t.badgeIcon,color:t.$attrs.disabled?"gray":"primary",size:f},e.createSlots({_:2},[s.badgeText?{name:"default",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"badgeText")]),key:"0"}:void 0,s.badgeIcon?{name:"icon",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"badgeIcon")]),key:"1"}:void 0]),1032,["text","icon","color"])]):e.createCommentVNode("",!0),(t.postIcon||s.postIcon)&&!r.value?(e.openBlock(),e.createBlock(g._sfc_main,{key:4,icon:t.postIcon,size:d.value},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"postIcon")]),_:3},8,["icon","size"])):e.createCommentVNode("",!0)],64))],2))}});exports._sfc_main=x;
@@ -0,0 +1,160 @@
1
+ import { defineComponent as R, computed as i, useSlots as j, ref as A, createElementBlock as B, openBlock as r, normalizeClass as k, unref as y, createBlock as f, Fragment as D, createCommentVNode as I, renderSlot as l, withCtx as c, createTextVNode as F, toDisplayString as G, normalizeProps as L, mergeProps as O, createVNode as _, createSlots as q } from "vue";
2
+ import { _ as z } from "./Icon.vue_vue_type_style_index_0_lang-BfPcw6PU.js";
3
+ import { _ as H } from "./Spinner.vue_vue_type_style_index_0_lang-BYqqSQAx.js";
4
+ import { _ as J } from "./Badge.vue_vue_type_script_setup_true_lang-CCIamdNB.js";
5
+ import { i as K, a as $, c as C, b as S, B as T } from "./ButtonGroup.vue_vue_type_script_setup_true_lang-CT_Kgpjf.js";
6
+ import { g as M, a, b as Q } from "./class-DziTeW9B.js";
7
+ import { cva as U } from "class-variance-authority";
8
+ import { g as W } from "./options-JBqnVZUl.js";
9
+ const x = "2xsm", se = /* @__PURE__ */ R({
10
+ ...W("BaseButton"),
11
+ __name: "BaseButton",
12
+ props: {
13
+ class: {},
14
+ text: {},
15
+ size: {},
16
+ color: { default: "primary" },
17
+ type: { default: "fill" },
18
+ variant: {},
19
+ loading: { type: Boolean },
20
+ action: { type: Boolean },
21
+ active: { type: Boolean },
22
+ badgeText: {},
23
+ badgeIcon: {},
24
+ icon: {},
25
+ preIcon: {},
26
+ postIcon: {}
27
+ },
28
+ setup(h, { expose: V }) {
29
+ const o = h, t = M("button"), w = U(t, {
30
+ variants: {
31
+ size: a(C, t),
32
+ type: a($, t),
33
+ color: a(S, t),
34
+ variant: a(T, t),
35
+ action: a("action", t),
36
+ active: a("active", t),
37
+ text: a("text", t),
38
+ preIcon: a("preIcon", t),
39
+ postIcon: a("postIcon", t),
40
+ loading: a("loading", t)
41
+ }
42
+ }), b = K({
43
+ size: i(() => o.size),
44
+ variant: i(() => o.variant)
45
+ }), u = i(() => o.variant ?? b.variant.value ?? "simple"), s = i(() => ["icon", "float"].includes(u.value)), n = j(), N = i(() => {
46
+ let e = $.includes(o.type) ? o.type : "fill";
47
+ const p = o.size ?? b.size.value, E = p && C.includes(p) ? p : "md";
48
+ let d = o.color && S.includes(o.color) ? o.color : "primary", m = u.value && T.includes(u.value) ? u.value : "simple";
49
+ return o.action ? (m === "float" && (m = "icon"), e === "fill" && (e = "outline"), d = void 0) : m === "float" && (e === "ghost" && (e = "fill"), ["primary", "gray"].includes(d) || (d = "primary")), {
50
+ size: E,
51
+ type: e,
52
+ color: d,
53
+ variant: m,
54
+ action: o.action,
55
+ active: o.active,
56
+ loading: o.loading,
57
+ text: !s.value && !!(o.text || n.default),
58
+ preIcon: !s.value && !!(o.preIcon || n.preIcon),
59
+ postIcon: !s.value && !!(o.postIcon || n.postIcon)
60
+ };
61
+ }), v = i(() => {
62
+ switch (o.size) {
63
+ case "sm":
64
+ return "3xsm";
65
+ default:
66
+ return "2xsm";
67
+ }
68
+ }), P = i(() => {
69
+ switch (o.size) {
70
+ case "sm":
71
+ return "3xsm";
72
+ case "lg":
73
+ return "xsm";
74
+ case "md":
75
+ default:
76
+ return "2xsm";
77
+ }
78
+ }), g = A();
79
+ return V({
80
+ focus() {
81
+ var e;
82
+ (e = g.value) == null || e.focus();
83
+ },
84
+ blur() {
85
+ var e;
86
+ (e = g.value) == null || e.blur();
87
+ }
88
+ }), (e, p) => (r(), B("button", {
89
+ class: k([y(w)(N.value), o.class]),
90
+ tabindex: "0",
91
+ ref_key: "buttonRef",
92
+ ref: g
93
+ }, [
94
+ e.loading ? (r(), f(H, {
95
+ key: 1,
96
+ class: k(y(Q)(y(t), "loading")),
97
+ size: v.value
98
+ }, null, 8, ["class", "size"])) : (r(), B(D, { key: 0 }, [
99
+ (e.preIcon || n.preIcon) && !s.value ? (r(), f(z, {
100
+ key: 0,
101
+ icon: e.preIcon,
102
+ size: v.value
103
+ }, {
104
+ default: c(() => [
105
+ l(e.$slots, "preIcon")
106
+ ]),
107
+ _: 3
108
+ }, 8, ["icon", "size"])) : I("", !0),
109
+ s.value ? (r(), f(z, {
110
+ key: 1,
111
+ icon: e.icon,
112
+ size: P.value
113
+ }, {
114
+ default: c(() => [
115
+ l(e.$slots, "icon")
116
+ ]),
117
+ _: 3
118
+ }, 8, ["icon", "size"])) : l(e.$slots, "default", { key: 2 }, () => [
119
+ F(G(e.text), 1)
120
+ ]),
121
+ e.action && e.active && !s.value && (e.badgeText || n.badgeText || e.badgeIcon || n.badgeIcon) ? l(e.$slots, "badge", L(O({ key: 3 }, { color: e.$attrs.disabled ? "gray" : "primary", size: x })), () => [
122
+ _(J, {
123
+ text: e.badgeText,
124
+ icon: e.badgeIcon,
125
+ color: e.$attrs.disabled ? "gray" : "primary",
126
+ size: x
127
+ }, q({ _: 2 }, [
128
+ n.badgeText ? {
129
+ name: "default",
130
+ fn: c(() => [
131
+ l(e.$slots, "badgeText")
132
+ ]),
133
+ key: "0"
134
+ } : void 0,
135
+ n.badgeIcon ? {
136
+ name: "icon",
137
+ fn: c(() => [
138
+ l(e.$slots, "badgeIcon")
139
+ ]),
140
+ key: "1"
141
+ } : void 0
142
+ ]), 1032, ["text", "icon", "color"])
143
+ ]) : I("", !0),
144
+ (e.postIcon || n.postIcon) && !s.value ? (r(), f(z, {
145
+ key: 4,
146
+ icon: e.postIcon,
147
+ size: v.value
148
+ }, {
149
+ default: c(() => [
150
+ l(e.$slots, "postIcon")
151
+ ]),
152
+ _: 3
153
+ }, 8, ["icon", "size"])) : I("", !0)
154
+ ], 64))
155
+ ], 2));
156
+ }
157
+ });
158
+ export {
159
+ se as _
160
+ };
@@ -1,10 +1,86 @@
1
1
  import { BaseButtonSlots, BaseButtonProps } from '../Base/BaseButton/BaseButton';
2
- export type ButtonProps = Partial<Pick<BaseButtonProps, 'as' | 'class' | 'type' | 'color' | 'loading' | 'preIcon' | 'postIcon' | 'size' | 'text'>>;
2
+ export type ButtonProps = Partial<Pick<BaseButtonProps, 'class' | 'type' | 'color' | 'loading' | 'preIcon' | 'postIcon' | 'size' | 'text'>>;
3
3
  type ButtonSlots = Omit<BaseButtonSlots, 'icon' | 'badge'>;
4
- declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<Partial<Pick<BaseButtonProps, "size" | "class" | "type" | "color" | "text" | "as" | "loading" | "preIcon" | "postIcon">>, {
4
+ declare function __VLS_template(): {
5
+ slots: Readonly<ButtonSlots> & ButtonSlots;
6
+ refs: {
7
+ buttonRef: ({
8
+ $: import('vue').ComponentInternalInstance;
9
+ $data: {};
10
+ $props: {
11
+ readonly class?: import('../index.ts', { with: { "resolution-mode": "import" } }).Class | undefined;
12
+ readonly text?: (string | number) | undefined;
13
+ readonly size?: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonSize | undefined;
14
+ readonly color?: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonColor | undefined;
15
+ readonly type?: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonType | undefined;
16
+ readonly variant?: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonVariant | undefined;
17
+ readonly loading?: boolean | undefined;
18
+ readonly action?: boolean | undefined;
19
+ readonly active?: boolean | undefined;
20
+ readonly badgeText?: string | undefined;
21
+ readonly badgeIcon?: string | undefined;
22
+ readonly icon?: string | undefined;
23
+ readonly preIcon?: string | undefined;
24
+ readonly postIcon?: string | undefined;
25
+ } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps;
26
+ $attrs: {
27
+ [x: string]: unknown;
28
+ };
29
+ $refs: {
30
+ [x: string]: unknown;
31
+ };
32
+ $slots: Readonly<{
33
+ [name: string]: import('vue').Slot<any> | undefined;
34
+ }>;
35
+ $root: import('vue').ComponentPublicInstance | null;
36
+ $parent: import('vue').ComponentPublicInstance | null;
37
+ $host: Element | null;
38
+ $emit: (event: string, ...args: any[]) => void;
39
+ $el: any;
40
+ $options: import('vue').ComponentOptionsBase<Readonly<BaseButtonProps> & Readonly<{}>, {
41
+ focus(): void;
42
+ blur(): void;
43
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, {
44
+ type: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonType;
45
+ color: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonColor;
46
+ }, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & {
47
+ beforeCreate?: (() => void) | (() => void)[];
48
+ created?: (() => void) | (() => void)[];
49
+ beforeMount?: (() => void) | (() => void)[];
50
+ mounted?: (() => void) | (() => void)[];
51
+ beforeUpdate?: (() => void) | (() => void)[];
52
+ updated?: (() => void) | (() => void)[];
53
+ activated?: (() => void) | (() => void)[];
54
+ deactivated?: (() => void) | (() => void)[];
55
+ beforeDestroy?: (() => void) | (() => void)[];
56
+ beforeUnmount?: (() => void) | (() => void)[];
57
+ destroyed?: (() => void) | (() => void)[];
58
+ unmounted?: (() => void) | (() => void)[];
59
+ renderTracked?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
60
+ renderTriggered?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
61
+ errorCaptured?: ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void)[];
62
+ };
63
+ $forceUpdate: () => void;
64
+ $nextTick: typeof import('vue').nextTick;
65
+ $watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import('@vue/reactivity').OnCleanup]) => any : (...args: [any, any, import('@vue/reactivity').OnCleanup]) => any, options?: import('vue').WatchOptions): import('vue').WatchStopHandle;
66
+ } & Readonly<{
67
+ type: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonType;
68
+ color: import('../index.ts', { with: { "resolution-mode": "import" } }).ButtonColor;
69
+ }> & Omit<Readonly<BaseButtonProps> & Readonly<{}>, "blur" | "focus" | ("type" | "color")> & import('vue').ShallowUnwrapRef<{
70
+ focus(): void;
71
+ blur(): void;
72
+ }> & {} & import('vue').ComponentCustomProperties & {} & {
73
+ $slots: Readonly<BaseButtonSlots> & BaseButtonSlots;
74
+ }) | null;
75
+ };
76
+ attrs: Partial<{}>;
77
+ };
78
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
79
+ declare const __VLS_component: import('vue').DefineComponent<Partial<Pick<BaseButtonProps, "size" | "class" | "type" | "color" | "text" | "loading" | "preIcon" | "postIcon">>, {
5
80
  focus(): void;
6
81
  blur(): void;
7
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Partial<Pick<BaseButtonProps, "size" | "class" | "type" | "color" | "text" | "as" | "loading" | "preIcon" | "postIcon">>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>, Readonly<ButtonSlots> & ButtonSlots>;
82
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Partial<Pick<BaseButtonProps, "size" | "class" | "type" | "color" | "text" | "loading" | "preIcon" | "postIcon">>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
83
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
8
84
  export default _default;
9
85
  type __VLS_WithTemplateSlots<T, S> = T & {
10
86
  new (): {
@@ -1,4 +1,4 @@
1
- import { _ as o, _ as e } from "../Button.vue_vue_type_script_setup_true_lang-DIj3gT2D.js";
1
+ import { _ as o, _ as e } from "../Button.vue_vue_type_script_setup_true_lang-BHumLt2E.js";
2
2
  export {
3
3
  o as Button,
4
4
  e as default
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Button.vue_vue_type_script_setup_true_lang-7V57ztN4.js");exports.Button=e._sfc_main;exports.default=e._sfc_main;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Button.vue_vue_type_script_setup_true_lang-BZ0h9oaW.js");exports.Button=e._sfc_main;exports.default=e._sfc_main;
@@ -1,12 +1,11 @@
1
1
  import { defineComponent as i, useAttrs as m, computed as u, ref as l, createBlock as f, openBlock as _, mergeProps as d, createSlots as b, renderList as g, withCtx as v, renderSlot as B, normalizeProps as k, guardReactiveProps as x } from "vue";
2
2
  import { o as y } from "./omit-BEkBWXra.js";
3
- import { _ as C } from "./BaseButton.vue_vue_type_style_index_0_lang-BrQJfrgg.js";
3
+ import { _ as C } from "./BaseButton.vue_vue_type_style_index_0_lang-CEY27kcT.js";
4
4
  import { g as P } from "./options-JBqnVZUl.js";
5
5
  const O = /* @__PURE__ */ i({
6
6
  ...P("Button", !1),
7
7
  __name: "Button",
8
8
  props: {
9
- as: {},
10
9
  class: {},
11
10
  type: {},
12
11
  color: {},
@@ -16,12 +15,12 @@ const O = /* @__PURE__ */ i({
16
15
  size: {},
17
16
  text: {}
18
17
  },
19
- setup(r, { expose: s }) {
20
- const n = r, a = m(), c = u(() => ({
18
+ setup(r, { expose: n }) {
19
+ const s = r, a = m(), c = u(() => ({
21
20
  ...y(a, "variant", "icon", "action", "active", "badgeText"),
22
- ...n
21
+ ...s
23
22
  })), o = l();
24
- return s({
23
+ return n({
25
24
  focus() {
26
25
  var e;
27
26
  (e = o.value) == null || e.focus();
@@ -0,0 +1 @@
1
+ "use strict";const e=require("vue"),p=require("./omit-BKPbELUG.js"),l=require("./BaseButton.vue_vue_type_style_index_0_lang-4ju_QUXH.js"),_=require("./options-B4iSAKol.js"),f=e.defineComponent({..._.getComponentOptions("Button",!1),__name:"Button",props:{class:{},type:{},color:{},loading:{type:Boolean},preIcon:{},postIcon:{},size:{},text:{}},setup(s,{expose:r}){const c=s,a=e.useAttrs(),i=e.computed(()=>({...p.omit(a,"variant","icon","action","active","badgeText"),...c})),o=e.ref();return r({focus(){var t;(t=o.value)==null||t.focus()},blur(){var t;(t=o.value)==null||t.blur()}}),(t,m)=>(e.openBlock(),e.createBlock(l._sfc_main,e.mergeProps(i.value,{variant:"simple",ref_key:"buttonRef",ref:o}),e.createSlots({_:2},[e.renderList(Object.keys(t.$slots),n=>({name:n,fn:e.withCtx(u=>[e.renderSlot(t.$slots,n,e.normalizeProps(e.guardReactiveProps(u)))])}))]),1040))}});exports._sfc_main=f;
@@ -1,9 +1,8 @@
1
1
  import { ButtonSize, ButtonVariant } from '../Base/BaseButton/BaseButton.model';
2
- import { PrimitiveProps } from 'radix-vue';
3
2
  import { ComputedRef } from 'vue';
4
3
  import { Class } from '../types';
5
4
  declare const ButtonGroupGaps: readonly ["sm", "md", "lg", "none"];
6
- export type ButtonGroupProps = Omit<PrimitiveProps, 'asChild'> & {
5
+ export type ButtonGroupProps = {
7
6
  class?: Class;
8
7
  size?: ButtonSize;
9
8
  variant?: ButtonVariant;
@@ -30,10 +29,9 @@ export declare const injectButtonGroupContext: <T extends {
30
29
  variant: ComputedRef<ButtonVariant | undefined>;
31
30
  };
32
31
  declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<ButtonGroupProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ButtonGroupProps> & Readonly<{}>, {
33
- size: "sm" | "md" | "lg";
32
+ size: ButtonSize;
34
33
  split: boolean;
35
- as: import('radix-vue', { with: { "resolution-mode": "import" } }).AsTag | import('vue').Component;
36
- variant: "icon" | "simple" | "float";
34
+ variant: ButtonVariant;
37
35
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>, {
38
36
  default?(_: {}): any;
39
37
  }>;
@@ -1,4 +1,4 @@
1
- import { _ as u, _ as e, i as n, p } from "../ButtonGroup.vue_vue_type_script_setup_true_lang-CdSgBboA.js";
1
+ import { _ as u, _ as e, i as n, p } from "../ButtonGroup.vue_vue_type_script_setup_true_lang-CT_Kgpjf.js";
2
2
  export {
3
3
  u as ButtonGroup,
4
4
  e as default,
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../ButtonGroup.vue_vue_type_script_setup_true_lang-BSj1Y1j2.js");exports.ButtonGroup=t._sfc_main;exports.default=t._sfc_main;exports.injectButtonGroupContext=t.injectButtonGroupContext;exports.provideButtonGroupContext=t.provideButtonGroupContext;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../ButtonGroup.vue_vue_type_script_setup_true_lang-D486_o-Z.js");exports.ButtonGroup=t._sfc_main;exports.default=t._sfc_main;exports.injectButtonGroupContext=t.injectButtonGroupContext;exports.provideButtonGroupContext=t.provideButtonGroupContext;
@@ -0,0 +1,47 @@
1
+ import { defineComponent as i, computed as n, createElementBlock as l, openBlock as u, normalizeClass as c, unref as m, renderSlot as B } from "vue";
2
+ import { b as f, a as e, g } from "./class-DziTeW9B.js";
3
+ import { g as d } from "./options-JBqnVZUl.js";
4
+ import { cva as C } from "class-variance-authority";
5
+ import { createContext as v } from "radix-vue";
6
+ const S = ["simple", "icon", "float"], V = ["fill", "outline", "ghost"], j = ["primary", "danger", "success", "warning", "gray"], G = ["sm", "md", "lg"], z = [...G, "none"], [w, x] = v("ButtonGroup"), L = /* @__PURE__ */ i({
7
+ ...d("ButtonGroup"),
8
+ __name: "ButtonGroup",
9
+ props: {
10
+ class: {},
11
+ size: { default: "md" },
12
+ variant: { default: "simple" },
13
+ gap: {},
14
+ split: { type: Boolean, default: !0 }
15
+ },
16
+ setup(a) {
17
+ const t = a, r = g("button"), o = f(r, "group"), p = C(o, {
18
+ variants: {
19
+ gap: e(z, o),
20
+ split: e("split", o)
21
+ }
22
+ });
23
+ return x({
24
+ size: n(() => t.size),
25
+ variant: n(() => t.variant)
26
+ }), (s, _) => (u(), l("div", {
27
+ class: c([
28
+ m(p)({
29
+ gap: t.gap ?? t.size,
30
+ split: s.split
31
+ }),
32
+ t.class
33
+ ])
34
+ }, [
35
+ B(s.$slots, "default")
36
+ ], 2));
37
+ }
38
+ });
39
+ export {
40
+ S as B,
41
+ L as _,
42
+ V as a,
43
+ j as b,
44
+ G as c,
45
+ w as i,
46
+ x as p
47
+ };
@@ -0,0 +1 @@
1
+ "use strict";const t=require("vue"),o=require("./class-CjZYGZDW.js"),c=require("./options-B4iSAKol.js"),l=require("class-variance-authority"),B=require("radix-vue"),m=["simple","icon","float"],d=["fill","outline","ghost"],g=["primary","danger","success","warning","gray"],r=["sm","md","lg"],C=[...r,"none"],[f,a]=B.createContext("ButtonGroup"),v=t.defineComponent({...c.getComponentOptions("ButtonGroup"),__name:"ButtonGroup",props:{class:{},size:{default:"md"},variant:{default:"simple"},gap:{},split:{type:Boolean,default:!0}},setup(i){const e=i,u=o.getBemBlock("button"),n=o.getBemElement(u,"group"),p=l.cva(n,{variants:{gap:o.generateVariantClassList(C,n),split:o.generateVariantClassList("split",n)}});return a({size:t.computed(()=>e.size),variant:t.computed(()=>e.variant)}),(s,G)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass([t.unref(p)({gap:e.gap??e.size,split:s.split}),e.class])},[t.renderSlot(s.$slots,"default")],2))}});exports.ButtonColors=g;exports.ButtonSizes=r;exports.ButtonTypes=d;exports.ButtonVariants=m;exports._sfc_main=v;exports.injectButtonGroupContext=f;exports.provideButtonGroupContext=a;
@@ -1,7 +1,7 @@
1
- import { CheckboxRootProps } from 'radix-vue';
1
+ import { CheckboxRootEmits, CheckboxRootProps } from 'radix-vue';
2
2
  import { CheckboxSize } from './Checkbox.model';
3
3
  import { Class } from '../types';
4
- export interface CheckboxProps extends Omit<CheckboxRootProps, 'asChild' | 'value'> {
4
+ export interface CheckboxProps extends Omit<CheckboxRootProps, 'as' | 'asChild' | 'value'> {
5
5
  size?: CheckboxSize;
6
6
  class?: Class;
7
7
  rootCls?: Class;
@@ -16,15 +16,23 @@ export interface CheckboxProps extends Omit<CheckboxRootProps, 'asChild' | 'valu
16
16
  export interface CheckboxSlots {
17
17
  default?: (props: object) => never;
18
18
  }
19
+ export type CheckboxEmits = CheckboxRootEmits & {
20
+ change: [value: boolean | 'indeterminate'];
21
+ blur: [event: InputEvent];
22
+ focus: [event: InputEvent];
23
+ };
19
24
  declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<CheckboxProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
25
+ blur: (event: InputEvent) => any;
20
26
  change: (value: boolean | "indeterminate") => any;
27
+ focus: (event: InputEvent) => any;
21
28
  "update:checked": (value: boolean) => any;
22
29
  }, string, import('vue').PublicProps, Readonly<CheckboxProps> & Readonly<{
30
+ onBlur?: ((event: InputEvent) => any) | undefined;
23
31
  onChange?: ((value: boolean | "indeterminate") => any) | undefined;
32
+ onFocus?: ((event: InputEvent) => any) | undefined;
24
33
  "onUpdate:checked"?: ((value: boolean) => any) | undefined;
25
34
  }>, {
26
- size: "2xsm" | "xsm";
27
- as: import('radix-vue', { with: { "resolution-mode": "import" } }).AsTag | import('vue').Component;
35
+ size: CheckboxSize;
28
36
  checked: boolean | "indeterminate";
29
37
  valueAsLabel: boolean;
30
38
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>, Readonly<CheckboxSlots> & CheckboxSlots>;
@@ -1,4 +1,4 @@
1
- import { _ as e, C as s, _ as r, u as C, a as h } from "../Checkbox.vue_vue_type_style_index_0_lang-DNlvOQmv.js";
1
+ import { _ as e, C as s, _ as r, u as C, a as h } from "../Checkbox.vue_vue_type_style_index_0_lang-CSmeTeZh.js";
2
2
  export {
3
3
  e as Checkbox,
4
4
  s as CheckboxSizes,
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Checkbox.vue_vue_type_style_index_0_lang-C6Mdufam.js");exports.Checkbox=e._sfc_main;exports.CheckboxSizes=e.CheckboxSizes;exports.default=e._sfc_main;exports.useColoredPantographCheckbox=e.useColoredPantographCheckbox;exports.useColoredPantographCheckboxGroup=e.useColoredPantographCheckboxGroup;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../Checkbox.vue_vue_type_style_index_0_lang-D0sF0-hW.js");exports.Checkbox=e._sfc_main;exports.CheckboxSizes=e.CheckboxSizes;exports.default=e._sfc_main;exports.useColoredPantographCheckbox=e.useColoredPantographCheckbox;exports.useColoredPantographCheckboxGroup=e.useColoredPantographCheckboxGroup;