welcome-ui 8.1.3 → 8.2.0-alpha.1

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 (244) hide show
  1. package/dist/{AXB53BZF-BOEe01VW.mjs → AXB53BZF-XKOjjeWO.mjs} +3 -3
  2. package/dist/Accordion.mjs +30 -23
  3. package/dist/Alert.mjs +72 -66
  4. package/dist/AspectRatio.mjs +9 -9
  5. package/dist/Avatar.mjs +45 -41
  6. package/dist/{BYC7LY2E-B1IDizRs.mjs → BYC7LY2E-CWSI38FM.mjs} +128 -127
  7. package/dist/Badge.mjs +25 -25
  8. package/dist/Box.mjs +5 -5
  9. package/dist/Breadcrumb.mjs +118 -112
  10. package/dist/Button.mjs +72 -67
  11. package/dist/ButtonGroup.mjs +12 -11
  12. package/dist/Card.mjs +14 -14
  13. package/dist/Checkbox.mjs +2 -2
  14. package/dist/ClearButton.mjs +15 -15
  15. package/dist/CloseButton.mjs +9 -9
  16. package/dist/{CustomInput-IA_gVoXd.mjs → CustomPopper-DezjKb9n.mjs} +1458 -1442
  17. package/dist/DatePicker.mjs +63 -62
  18. package/dist/DateTimePicker.mjs +69 -63
  19. package/dist/DateTimePickerCommon.mjs +1 -1
  20. package/dist/Drawer.mjs +180 -168
  21. package/dist/DropdownMenu.mjs +354 -351
  22. package/dist/Field.mjs +103 -92
  23. package/dist/FieldGroup.mjs +12 -9
  24. package/dist/FileDrop.mjs +316 -295
  25. package/dist/FileUpload.mjs +83 -69
  26. package/dist/Files.mjs +41 -41
  27. package/dist/Flex.mjs +13 -13
  28. package/dist/Grid.mjs +29 -29
  29. package/dist/Hint.mjs +12 -12
  30. package/dist/{ITI7HKP4-EL9KXYBU.mjs → ITI7HKP4-C89kOQb8.mjs} +68 -67
  31. package/dist/Icon.mjs +25 -25
  32. package/dist/Icons.mjs +988 -988
  33. package/dist/IconsFont.mjs +22 -22
  34. package/dist/InputText.mjs +64 -56
  35. package/dist/{JC64G2H7-BzklVBKM.mjs → JC64G2H7-afsomHuH.mjs} +47 -46
  36. package/dist/{KUU7WJ55-CS4NemC6.mjs → KUU7WJ55-CzsjuIMv.mjs} +1 -1
  37. package/dist/LVA2YJMS-C-kJ1lkr.mjs +873 -0
  38. package/dist/Label.mjs +37 -35
  39. package/dist/Link.mjs +32 -28
  40. package/dist/Loader.mjs +20 -16
  41. package/dist/Logo.mjs +55 -42
  42. package/dist/{MTZPJQMC-CMjAwC0N.mjs → MTZPJQMC-TybFZCho.mjs} +2 -2
  43. package/dist/Modal.mjs +263 -244
  44. package/dist/{NLEBE274-QOMV1l7e.mjs → NLEBE274-oSxMftGy.mjs} +9 -9
  45. package/dist/{P2CTZE2T-Cl2w7OLV.mjs → P2CTZE2T-DOT1mNnX.mjs} +49 -48
  46. package/dist/{P4IRICAX-DezbJY4s.mjs → P4IRICAX-CWSZLTGz.mjs} +3 -3
  47. package/dist/Pagination.mjs +105 -103
  48. package/dist/PasswordInput.mjs +35 -34
  49. package/dist/Picker.mjs +36 -34
  50. package/dist/Popover.mjs +106 -99
  51. package/dist/{QYJ6MIDR-Bb0O5xUM.mjs → QYJ6MIDR-DJ-vUdAM.mjs} +31 -30
  52. package/dist/Radio.mjs +52 -46
  53. package/dist/RadioGroup.mjs +47 -47
  54. package/dist/RadioTab.mjs +37 -35
  55. package/dist/{SYRFVSLH-jn06-eLy.mjs → SYRFVSLH-B6m278Vb.mjs} +11 -10
  56. package/dist/Search.mjs +147 -135
  57. package/dist/Select.mjs +348 -330
  58. package/dist/Shape.mjs +9 -9
  59. package/dist/Slider.mjs +353 -326
  60. package/dist/Stack.mjs +24 -23
  61. package/dist/Swiper.mjs +192 -186
  62. package/dist/Table.mjs +23 -23
  63. package/dist/Tabs.mjs +205 -200
  64. package/dist/Tag.mjs +49 -47
  65. package/dist/Text.mjs +20 -20
  66. package/dist/Textarea.mjs +40 -40
  67. package/dist/TimePicker.mjs +59 -58
  68. package/dist/Toast.mjs +135 -128
  69. package/dist/Toggle.mjs +27 -24
  70. package/dist/Tooltip.mjs +103 -99
  71. package/dist/UniversalLink.mjs +15 -15
  72. package/dist/{VEVQD5MH-CuegL0m0.mjs → VEVQD5MH-0w9Y7Ytc.mjs} +3 -3
  73. package/dist/{VGCJ63VH-BMzoZtCu.mjs → VGCJ63VH-C0UPBY-5.mjs} +39 -38
  74. package/dist/VariantIcon.mjs +23 -22
  75. package/dist/WelcomeLoader.mjs +122 -121
  76. package/dist/WuiProvider.mjs +52 -44
  77. package/dist/{X5NMLKT6-CvSCix-_.mjs → X5NMLKT6-BJw3xE-K.mjs} +2 -2
  78. package/dist/{YV4JVR4I-Bh7B7TET.mjs → YV4JVR4I-DPC8mMuG.mjs} +57 -57
  79. package/dist/hide-focus-rings-root-CCXdysih.mjs +15 -0
  80. package/dist/{index-5PUh49rV.mjs → index-62h-enZF.mjs} +62 -61
  81. package/dist/{index-C7zM96J_.mjs → index-BaLGEKs7.mjs} +8 -8
  82. package/dist/index-CYmF7qCH.mjs +11 -0
  83. package/dist/index-C_k-m0Rl.mjs +36 -0
  84. package/dist/index-D8v_VJ9z.mjs +26 -0
  85. package/dist/{index-BNGGwOCo.mjs → index-DAZ1SYdj.mjs} +7 -7
  86. package/dist/index-DpkNUfAS.mjs +11 -0
  87. package/dist/{index-DqBUFsqP.mjs → index-DvzWKxKE.mjs} +7 -7
  88. package/dist/{index-Bkl89twW.mjs → index-QaLwIvZS.mjs} +8 -8
  89. package/dist/{index-BQtDgQBH.mjs → index-SQQQ4dEE.mjs} +8 -8
  90. package/dist/index-i_anpNhw.mjs +66 -0
  91. package/dist/index-wl3X6EM1.mjs +16 -0
  92. package/dist/jsx-runtime-B7I4PJ0H.mjs +613 -0
  93. package/dist/radio-group-C0fUHvam.mjs +52 -0
  94. package/dist/theme.mjs +805 -805
  95. package/dist/types/components/Accordion/index.d.ts +1 -1
  96. package/dist/types/components/Alert/index.d.ts +2 -2
  97. package/dist/types/components/Alert/styles.d.ts +4 -4
  98. package/dist/types/components/Alert/theme.d.ts +4 -4
  99. package/dist/types/components/Avatar/index.d.ts +1 -1
  100. package/dist/types/components/Avatar/styles.d.ts +4 -4
  101. package/dist/types/components/Avatar/theme.d.ts +1 -1
  102. package/dist/types/components/Badge/index.d.ts +2 -2
  103. package/dist/types/components/Badge/styles.d.ts +2 -2
  104. package/dist/types/components/Breadcrumb/Item.d.ts +1 -1
  105. package/dist/types/components/Breadcrumb/index.d.ts +1 -1
  106. package/dist/types/components/Button/index.d.ts +4 -5
  107. package/dist/types/components/Button/theme.d.ts +7 -7
  108. package/dist/types/components/ButtonGroup/index.d.ts +3 -3
  109. package/dist/types/components/Card/Cover.styles.d.ts +2 -2
  110. package/dist/types/components/Card/index.d.ts +2 -3
  111. package/dist/types/components/Checkbox/index.d.ts +2 -2
  112. package/dist/types/components/ClearButton/index.d.ts +4 -5
  113. package/dist/types/components/ClearButton/styles.d.ts +2 -2
  114. package/dist/types/components/CloseButton/styles.d.ts +2 -2
  115. package/dist/types/components/DatePicker/index.d.ts +3 -3
  116. package/dist/types/components/DateTimePicker/index.d.ts +2 -2
  117. package/dist/types/components/DateTimePickerCommon/CustomHeader.d.ts +1 -1
  118. package/dist/types/components/DateTimePickerCommon/CustomInput.d.ts +5 -5
  119. package/dist/types/components/DateTimePickerCommon/CustomPopper.d.ts +1 -1
  120. package/dist/types/components/DateTimePickerCommon/index.d.ts +2 -2
  121. package/dist/types/components/DateTimePickerCommon/utils.d.ts +1 -1
  122. package/dist/types/components/Drawer/AssetDrawer/Header.d.ts +1 -1
  123. package/dist/types/components/Drawer/AssetDrawer/index.d.ts +1 -1
  124. package/dist/types/components/Drawer/index.d.ts +8 -8
  125. package/dist/types/components/Drawer/styles.d.ts +3 -3
  126. package/dist/types/components/Drawer/theme.d.ts +1 -1
  127. package/dist/types/components/DropdownMenu/index.d.ts +4 -4
  128. package/dist/types/components/Field/index.d.ts +8 -8
  129. package/dist/types/components/Field/styles.d.ts +1 -1
  130. package/dist/types/components/Field/utils.d.ts +1 -1
  131. package/dist/types/components/FileDrop/FilePreview.d.ts +2 -2
  132. package/dist/types/components/FileDrop/Message.d.ts +1 -1
  133. package/dist/types/components/FileDrop/index.d.ts +16 -16
  134. package/dist/types/components/FileUpload/index.d.ts +13 -13
  135. package/dist/types/components/Files/index.d.ts +4 -4
  136. package/dist/types/components/Files/types.d.ts +1 -1
  137. package/dist/types/components/Hint/index.d.ts +1 -2
  138. package/dist/types/components/Icon/index.d.ts +3 -3
  139. package/dist/types/components/Icon/styles.d.ts +3 -3
  140. package/dist/types/components/Icon/theme.d.ts +1 -1
  141. package/dist/types/components/Icons/index.d.ts +2 -2
  142. package/dist/types/components/IconsFont/index.d.ts +2 -3
  143. package/dist/types/components/IconsFont/styles.d.ts +1 -1
  144. package/dist/types/components/InputText/index.d.ts +1 -1
  145. package/dist/types/components/InputText/styles.d.ts +1 -1
  146. package/dist/types/components/Label/index.d.ts +2 -3
  147. package/dist/types/components/Link/index.d.ts +3 -3
  148. package/dist/types/components/Link/styles.d.ts +2 -2
  149. package/dist/types/components/Loader/index.d.ts +1 -1
  150. package/dist/types/components/Loader/styles.d.ts +2 -2
  151. package/dist/types/components/Loader/theme.d.ts +2 -2
  152. package/dist/types/components/Logo/Solutions.d.ts +1 -2
  153. package/dist/types/components/Logo/Symbol.d.ts +1 -2
  154. package/dist/types/components/Logo/Wui.d.ts +1 -2
  155. package/dist/types/components/Logo/index.d.ts +5 -5
  156. package/dist/types/components/Modal/Assets/Backdrop.d.ts +4 -5
  157. package/dist/types/components/Modal/Assets/Iframe.d.ts +1 -2
  158. package/dist/types/components/Modal/Assets/index.d.ts +5 -5
  159. package/dist/types/components/Modal/Assets/styles.d.ts +4 -4
  160. package/dist/types/components/Modal/Close.d.ts +1 -2
  161. package/dist/types/components/Modal/Footer.d.ts +1 -1
  162. package/dist/types/components/Modal/Header.d.ts +2 -2
  163. package/dist/types/components/Modal/index.d.ts +11 -11
  164. package/dist/types/components/Modal/styles.d.ts +4 -4
  165. package/dist/types/components/Modal/theme.d.ts +1 -1
  166. package/dist/types/components/Pagination/index.d.ts +2 -2
  167. package/dist/types/components/Pagination/utils.d.ts +1 -1
  168. package/dist/types/components/Popover/Arrow.d.ts +1 -2
  169. package/dist/types/components/Popover/Content.d.ts +2 -3
  170. package/dist/types/components/Popover/Popover.d.ts +4 -5
  171. package/dist/types/components/Popover/PopoverHover.d.ts +3 -4
  172. package/dist/types/components/Popover/Trigger.d.ts +1 -1
  173. package/dist/types/components/Popover/usePopover.d.ts +6 -6
  174. package/dist/types/components/Radio/index.d.ts +5 -5
  175. package/dist/types/components/Radio/styles.d.ts +2 -2
  176. package/dist/types/components/RadioGroup/index.d.ts +2 -2
  177. package/dist/types/components/RadioTab/index.d.ts +2 -2
  178. package/dist/types/components/RadioTab/styles.d.ts +9 -9
  179. package/dist/types/components/Search/index.d.ts +4 -4
  180. package/dist/types/components/Select/index.d.ts +9 -9
  181. package/dist/types/components/Select/styles.d.ts +4 -4
  182. package/dist/types/components/Select/utils.d.ts +4 -4
  183. package/dist/types/components/Shape/index.d.ts +1 -1
  184. package/dist/types/components/Shape/styles.d.ts +2 -2
  185. package/dist/types/components/Slider/Range.d.ts +3 -3
  186. package/dist/types/components/Slider/index.d.ts +2 -2
  187. package/dist/types/components/Slider/styles.d.ts +10 -10
  188. package/dist/types/components/Stack/index.d.ts +1 -1
  189. package/dist/types/components/Swiper/index.d.ts +16 -17
  190. package/dist/types/components/Swiper/styles.d.ts +55 -55
  191. package/dist/types/components/System/index.d.ts +10 -10
  192. package/dist/types/components/Table/index.d.ts +6 -7
  193. package/dist/types/components/Table/styles.d.ts +1 -1
  194. package/dist/types/components/Tabs/ActiveBar.d.ts +5 -5
  195. package/dist/types/components/Tabs/TabList.d.ts +2 -2
  196. package/dist/types/components/Tabs/TabPanel.d.ts +2 -2
  197. package/dist/types/components/Tabs/theme.d.ts +1 -1
  198. package/dist/types/components/Tag/index.d.ts +2 -3
  199. package/dist/types/components/Tag/styles.d.ts +1 -1
  200. package/dist/types/components/Tag/theme.d.ts +2 -2
  201. package/dist/types/components/Text/index.d.ts +2 -2
  202. package/dist/types/components/Textarea/index.d.ts +1 -1
  203. package/dist/types/components/TimePicker/index.d.ts +2 -2
  204. package/dist/types/components/Toast/Growl.d.ts +1 -1
  205. package/dist/types/components/Toast/Snackbar.d.ts +1 -1
  206. package/dist/types/components/Toast/ToastWrapper.d.ts +4 -4
  207. package/dist/types/components/Toast/index.d.ts +5 -5
  208. package/dist/types/components/Toast/styles.d.ts +10 -10
  209. package/dist/types/components/Toast/theme.d.ts +1 -1
  210. package/dist/types/components/Toast/utils.d.ts +13 -13
  211. package/dist/types/components/Toggle/index.d.ts +2 -2
  212. package/dist/types/components/Toggle/theme.d.ts +4 -4
  213. package/dist/types/components/Tooltip/index.d.ts +3 -3
  214. package/dist/types/components/VariantIcon/index.d.ts +1 -1
  215. package/dist/types/components/VariantIcon/styles.d.ts +1 -1
  216. package/dist/types/components/VariantIcon/theme.d.ts +1 -1
  217. package/dist/types/theme/colors.d.ts +3 -3
  218. package/dist/types/theme/dark.d.ts +1 -1
  219. package/dist/types/theme/defaultFields.d.ts +5 -5
  220. package/dist/types/theme/fonts.d.ts +5 -5
  221. package/dist/types/theme/index.d.ts +31 -31
  222. package/dist/types/theme/screens.d.ts +7 -7
  223. package/dist/types/theme/space.d.ts +9 -9
  224. package/dist/types/utils/field-styles.d.ts +2 -2
  225. package/dist/types/utils/index.d.ts +2 -2
  226. package/dist/types/utils/ts-utils.d.ts +1 -1
  227. package/dist/types/utils/use-copy-text.d.ts +1 -1
  228. package/dist/types/utils/use-create-portal.d.ts +1 -1
  229. package/dist/types/utils/wrap-children.d.ts +1 -1
  230. package/dist/{use-viewport-CfklieD-.mjs → use-viewport-CWpjoHXy.mjs} +2 -2
  231. package/dist/utils.mjs +13 -13
  232. package/dist/wrap-children-CzmhoRzd.mjs +13 -0
  233. package/package.json +3 -27
  234. package/dist/LVA2YJMS-DDEmK0pp.mjs +0 -1482
  235. package/dist/hide-focus-rings-root-BNyva1yb.mjs +0 -14
  236. package/dist/index-B0gDDiFm.mjs +0 -66
  237. package/dist/index-B22SHR8h.mjs +0 -26
  238. package/dist/index-CQD9fgf_.mjs +0 -11
  239. package/dist/index-CmsWSKKs.mjs +0 -11
  240. package/dist/index-u1oHKa7X.mjs +0 -16
  241. package/dist/index-wr_b5GSV.mjs +0 -36
  242. package/dist/radio-group-RFyDp0KD.mjs +0 -51
  243. package/dist/wrap-children-aq69jtFP.mjs +0 -12
  244. package/dist/{downshift.esm-D0ns_SQs.mjs → downshift.esm-B7Jil1wW.mjs} +9 -9
@@ -1,9 +1,10 @@
1
1
  "use client";
2
- import { v as Y, p as $, I as Ce, c as G, J as xe, _ as J, x as q, d as S, e as Q, g as P, z as X, f as Z, h as ee, l as Se, b as D, K as Pe, L as O, o as F, M as we, u as j, N as he, O as Ee, E as ye, t as Te, k as Re, P as De, w as Oe } from "./LVA2YJMS-DDEmK0pp.mjs";
3
- import { createContext as te, useRef as _, useEffect as Fe, useContext as _e, useCallback as Ae, useMemo as ke } from "react";
4
- import { u as ze } from "./KUU7WJ55-CS4NemC6.mjs";
5
- import { f as Ke } from "./YV4JVR4I-Bh7B7TET.mjs";
6
- var w = Y(), Le = w.useContext;
2
+ import { t as Y, p as $, H as Ce, c as G, I as xe, _ as J, w as q, d as S, e as Q, g as P, y as X, f as Z, h as ee, l as Se, b as R, J as Pe, K as O, o as F, L as we, u as V, M as he, N as Ee, D as ye, k as Te, O as De, v as Re } from "./LVA2YJMS-C-kJ1lkr.mjs";
3
+ import { createContext as te, useRef as _, useEffect as Oe, useContext as Fe, useCallback as _e, useMemo as Ae } from "react";
4
+ import { u as ke } from "./KUU7WJ55-CzsjuIMv.mjs";
5
+ import { f as Ke } from "./YV4JVR4I-DPC8mMuG.mjs";
6
+ import { j as Le } from "./jsx-runtime-B7I4PJ0H.mjs";
7
+ var w = Y(), ze = w.useContext;
7
8
  w.useScopedContext;
8
9
  w.useProviderContext;
9
10
  var Ne = w.ContextProvider, Me = w.ScopedContextProvider, h = Y(
@@ -11,26 +12,26 @@ var Ne = w.ContextProvider, Me = w.ScopedContextProvider, h = Y(
11
12
  [Me]
12
13
  ), Be = h.useContext;
13
14
  h.useScopedContext;
14
- var st = h.useProviderContext, ut = h.ContextProvider, at = h.ScopedContextProvider, He = te(
15
+ var ut = h.useProviderContext, at = h.ContextProvider, lt = h.ScopedContextProvider, He = te(
15
16
  void 0
16
- ), Ue = te(
17
+ ), je = te(
17
18
  void 0
18
- ), Ve = { id: null };
19
- function lt(r, n, o = !1) {
19
+ ), Ue = { id: null };
20
+ function ct(r, n, o = !1) {
20
21
  const t = r.findIndex((a) => a.id === n);
21
22
  return [
22
23
  ...r.slice(t + 1),
23
- ...o ? [Ve] : [],
24
+ ...o ? [Ue] : [],
24
25
  ...r.slice(0, t)
25
26
  ];
26
27
  }
27
- function ct(r, n) {
28
+ function ft(r, n) {
28
29
  return r.find((o) => !o.disabled);
29
30
  }
30
- function je(r, n) {
31
+ function Ve(r, n) {
31
32
  return n && r.item(n) || null;
32
33
  }
33
- function ft(r) {
34
+ function dt(r) {
34
35
  const n = [];
35
36
  for (const o of r) {
36
37
  const t = n.find((a) => {
@@ -56,7 +57,7 @@ var A = Symbol("FOCUS_SILENTLY");
56
57
  function Ye(r) {
57
58
  r[A] = !0, r.focus({ preventScroll: !0 });
58
59
  }
59
- function dt(r) {
60
+ function mt(r) {
60
61
  const n = r[A];
61
62
  return delete r[A], n;
62
63
  }
@@ -77,10 +78,10 @@ var $e = "div", ne = G(
77
78
  // @ts-expect-error This prop may come from a collection renderer.
78
79
  "element"
79
80
  ]);
80
- const c = Le();
81
+ const c = ze();
81
82
  t = t || c;
82
83
  const m = q(v.id), p = _(g);
83
- return Fe(() => {
84
+ return Oe(() => {
84
85
  const i = p.current;
85
86
  if (!m || !i || !a) return;
86
87
  const b = d({ id: m, element: i });
@@ -96,7 +97,7 @@ Z(function(n) {
96
97
  });
97
98
  var Ge = "button";
98
99
  function Je(r) {
99
- return O(r) ? !0 : r.tagName === "INPUT" && !Re(r);
100
+ return O(r) ? !0 : r.tagName === "INPUT" && !Te(r);
100
101
  }
101
102
  function qe(r, n = !1) {
102
103
  const o = r.clientHeight, { top: t } = r.getBoundingClientRect(), a = Math.max(o * 0.875, o - 40) * 1.5, d = n ? o - a + t : a + t;
@@ -117,7 +118,7 @@ function W(r, n, o, t = !1) {
117
118
  const i = c;
118
119
  if (c = o(p), !c) break;
119
120
  if (c === i) continue;
120
- const b = (a = je(n, c)) == null ? void 0 : a.element;
121
+ const b = (a = Ve(n, c)) == null ? void 0 : a.element;
121
122
  if (!b) continue;
122
123
  const C = Qe(b, t) - v, l = Math.abs(C);
123
124
  if (t && C <= 0 || !t && C >= 0) {
@@ -154,9 +155,9 @@ var Ze = G(
154
155
  ]);
155
156
  const b = Be();
156
157
  t = t || b;
157
- const f = q(i.id), C = _(null), l = _e(Ue), k = Se(i) && !i.accessibleWhenDisabled, {
158
+ const f = q(i.id), C = _(null), l = Fe(je), k = Se(i) && !i.accessibleWhenDisabled, {
158
159
  rowId: y,
159
- baseElement: z,
160
+ baseElement: K,
160
161
  isActiveItem: oe,
161
162
  ariaSetSize: ie,
162
163
  ariaPosInSet: se,
@@ -194,7 +195,7 @@ var Ze = G(
194
195
  const s = t == null ? void 0 : t.item(e.activeId);
195
196
  return s != null && s.disabled || !(s != null && s.element) ? !0 : e.activeId === f;
196
197
  }
197
- }), ae = Ae(
198
+ }), ae = _e(
198
199
  (e) => {
199
200
  var s;
200
201
  const u = S(P({}, e), {
@@ -206,21 +207,21 @@ var Ze = G(
206
207
  return c ? c(u) : u;
207
208
  },
208
209
  [f, y, k, c]
209
- ), K = i.onFocus, T = _(!1), le = D((e) => {
210
- if (K == null || K(e), e.defaultPrevented || Pe(e) || !f || !t || Xe(e, t)) return;
210
+ ), L = i.onFocus, T = _(!1), le = R((e) => {
211
+ if (L == null || L(e), e.defaultPrevented || Pe(e) || !f || !t || Xe(e, t)) return;
211
212
  const { virtualFocus: s, baseElement: u } = t.getState();
212
213
  if (t.setActiveId(f), O(e.currentTarget) && We(e.currentTarget), !s || !F(e) || Je(e.currentTarget) || !(u != null && u.isConnected)) return;
213
214
  we() && e.currentTarget.hasAttribute("data-autofocus") && e.currentTarget.scrollIntoView({
214
215
  block: "nearest",
215
216
  inline: "nearest"
216
217
  }), T.current = !0, e.relatedTarget === u || re(t, e.relatedTarget) ? Ye(u) : u.focus();
217
- }), L = i.onBlurCapture, ce = D((e) => {
218
- if (L == null || L(e), e.defaultPrevented) return;
218
+ }), z = i.onBlurCapture, ce = R((e) => {
219
+ if (z == null || z(e), e.defaultPrevented) return;
219
220
  const s = t == null ? void 0 : t.getState();
220
221
  s != null && s.virtualFocus && T.current && (T.current = !1, e.preventDefault(), e.stopPropagation());
221
- }), N = i.onKeyDown, fe = j(d), de = j(g), me = D((e) => {
222
+ }), N = i.onKeyDown, fe = V(d), de = V(g), me = R((e) => {
222
223
  if (N == null || N(e), e.defaultPrevented || !F(e) || !t) return;
223
- const { currentTarget: s } = e, u = t.getState(), R = t.item(f), I = !!(R != null && R.rowId), E = u.orientation !== "horizontal", x = u.orientation !== "vertical", B = () => !!(I || x || !u.baseElement || !$(u.baseElement)), H = {
224
+ const { currentTarget: s } = e, u = t.getState(), D = t.item(f), I = !!(D != null && D.rowId), E = u.orientation !== "horizontal", x = u.orientation !== "vertical", B = () => !!(I || x || !u.baseElement || !$(u.baseElement)), H = {
224
225
  ArrowUp: (I || E) && t.up,
225
226
  ArrowRight: (I || x) && t.next,
226
227
  ArrowDown: (I || E) && t.down,
@@ -238,25 +239,25 @@ var Ze = G(
238
239
  }[e.key];
239
240
  if (H) {
240
241
  if (O(s)) {
241
- const V = he(s), ve = x && e.key === "ArrowLeft", pe = x && e.key === "ArrowRight", Ie = E && e.key === "ArrowUp", ge = E && e.key === "ArrowDown";
242
+ const U = he(s), ve = x && e.key === "ArrowLeft", pe = x && e.key === "ArrowRight", Ie = E && e.key === "ArrowUp", ge = E && e.key === "ArrowDown";
242
243
  if (pe || ge) {
243
244
  const { length: be } = Ee(s);
244
- if (V.end !== be) return;
245
- } else if ((ve || Ie) && V.start !== 0) return;
245
+ if (U.end !== be) return;
246
+ } else if ((ve || Ie) && U.start !== 0) return;
246
247
  }
247
- const U = H();
248
- if (fe(e) || U !== void 0) {
248
+ const j = H();
249
+ if (fe(e) || j !== void 0) {
249
250
  if (!de(e)) return;
250
- e.preventDefault(), t.move(U);
251
+ e.preventDefault(), t.move(j);
251
252
  }
252
253
  }
253
- }), M = ke(
254
- () => ({ id: f, baseElement: z }),
255
- [f, z]
254
+ }), M = Ae(
255
+ () => ({ id: f, baseElement: K }),
256
+ [f, K]
256
257
  );
257
258
  return i = ye(
258
259
  i,
259
- (e) => /* @__PURE__ */ Te.jsx(He.Provider, { value: M, children: e }),
260
+ (e) => /* @__PURE__ */ Le.jsx(He.Provider, { value: M, children: e }),
260
261
  [M]
261
262
  ), i = S(P({
262
263
  id: f,
@@ -267,7 +268,7 @@ var Ze = G(
267
268
  onFocus: le,
268
269
  onBlurCapture: ce,
269
270
  onKeyDown: me
270
- }), i = ze(i), i = ne(S(P({
271
+ }), i = ke(i), i = ne(S(P({
271
272
  store: t
272
273
  }, i), {
273
274
  getItem: ae,
@@ -277,24 +278,24 @@ var Ze = G(
277
278
  "aria-posinset": se
278
279
  }));
279
280
  }
280
- ), mt = Oe(
281
+ ), vt = Re(
281
282
  Z(function(n) {
282
283
  const o = Ze(n);
283
284
  return ee(Ge, o);
284
285
  })
285
286
  );
286
287
  export {
287
- at as C,
288
- ut as a,
289
- st as b,
290
- ft as c,
291
- mt as d,
288
+ lt as C,
289
+ at as a,
290
+ ut as b,
291
+ dt as c,
292
+ vt as d,
292
293
  ne as e,
293
- ct as f,
294
- je as g,
294
+ ft as f,
295
+ Ve as g,
295
296
  Be as h,
296
297
  re as i,
297
- lt as j,
298
- dt as s,
298
+ ct as j,
299
+ mt as s,
299
300
  Ze as u
300
301
  };
@@ -1,7 +1,7 @@
1
1
  "use client";
2
- import { u as P } from "./X5NMLKT6-CvSCix-_.mjs";
3
- import { u as _ } from "./VGCJ63VH-BMzoZtCu.mjs";
4
- import { f as b, c as k, _ as x, i as S, u as O, a as R, b as N, d as h, e as w, g as c, h as y } from "./LVA2YJMS-DDEmK0pp.mjs";
2
+ import { u as P } from "./X5NMLKT6-BJw3xE-K.mjs";
3
+ import { u as _ } from "./VGCJ63VH-C0UPBY-5.mjs";
4
+ import { f as b, c as k, _ as x, i as S, u as O, a as R, b as N, d as h, e as w, g as c, h as y } from "./LVA2YJMS-C-kJ1lkr.mjs";
5
5
  import { useRef as B, useState as M, useEffect as T } from "react";
6
6
  var V = "button", j = Symbol("disclosure"), H = k(
7
7
  function(n) {
@@ -1,39 +1,17 @@
1
1
  "use client";
2
- import i, { useMemo as j, useRef as R, useCallback as y } from "react";
3
- import m, { th as v, css as x } from "@xstyled/styled-components";
4
- import { h as z } from "./hide-focus-rings-root-BNyva1yb.mjs";
2
+ import { j as o } from "./jsx-runtime-B7I4PJ0H.mjs";
3
+ import { useMemo as z, useRef as k, useCallback as p } from "react";
5
4
  import "./Icon.mjs";
6
- import { L as G } from "./index-CQD9fgf_.mjs";
7
- import { R as F } from "./index-CmsWSKKs.mjs";
8
- import { forwardRef as M } from "./System.mjs";
9
- const a = 5, S = 3;
10
- function d(e, t) {
11
- return Array.from({ length: e }, (r, s) => t(s));
12
- }
13
- function q(e, t) {
14
- return e.reduce((r, s, c) => {
15
- const n = [];
16
- return n.push(...r), n.push(...s), s.length && c < e.length - 1 && n.push(t), n;
17
- }, []);
18
- }
19
- function J(e, t) {
20
- if (e < a) return "before";
21
- if (e >= a && e <= t - a + 1) return "center";
22
- if (e > t - a + 1) return "after";
23
- }
24
- function K({ page: e, pageCount: t, rangeDisplay: r }) {
25
- return j(() => {
26
- if (t <= r || t <= a + 1)
27
- return d(t, (l) => l + 1);
28
- const s = J(e, t), c = s === "before" ? d(a, (l) => l + 1) : [1], n = s === "center" ? d(S, (l) => l + e - 1) : [], u = s === "after" ? d(a, (l) => l + t - a + 1) : [t];
29
- return q([c, n, u], "-");
30
- }, [e, t, r]);
31
- }
32
- const O = m.navBox``, Q = m.ulBox`
5
+ import { L as G } from "./index-DpkNUfAS.mjs";
6
+ import { R as _ } from "./index-CYmF7qCH.mjs";
7
+ import { forwardRef as F } from "./System.mjs";
8
+ import d, { th as h, css as b } from "@xstyled/styled-components";
9
+ import { h as M } from "./hide-focus-rings-root-CCXdysih.mjs";
10
+ const S = d.navBox``, q = d.ulBox`
33
11
  list-style-type: none;
34
12
  padding: 0;
35
13
  margin: 0;
36
- `, b = m.liBox`
14
+ `, m = d.liBox`
37
15
  display: inline-block;
38
16
  vertical-align: bottom;
39
17
  padding: 0;
@@ -42,14 +20,14 @@ const O = m.navBox``, Q = m.ulBox`
42
20
  &:last-child {
43
21
  margin-right: 0;
44
22
  }
45
- `, U = m.span`
46
- ${v("paginations.default")};
23
+ `, J = d.span`
24
+ ${h("paginations.default")};
47
25
  display: flex;
48
26
  justify-content: center;
49
27
  align-items: center;
50
- `, p = x`
51
- ${v("paginations.default")};
52
- ${v("paginations.item")};
28
+ `, B = b`
29
+ ${h("paginations.default")};
30
+ ${h("paginations.item")};
53
31
  border-radius: 50%;
54
32
  display: flex;
55
33
  align-items: center;
@@ -62,99 +40,123 @@ const O = m.navBox``, Q = m.ulBox`
62
40
  transition: none;
63
41
  }
64
42
 
65
- [${z}] &:focus {
43
+ [${M}] &:focus {
66
44
  box-shadow: none;
67
45
  }
68
- `, B = m.aBox(
69
- (e) => x`
70
- ${p};
71
- ${e["aria-disabled"] && x`
46
+ `, y = d.aBox(
47
+ (n) => b`
48
+ ${B};
49
+ ${n["aria-disabled"] && b`
72
50
  color: beige-70;
73
51
  background-color: beige-40;
74
52
  `}
75
53
  `
76
- ), V = m.aBox(
77
- (e) => x`
78
- ${p};
79
- ${e["aria-current"] && v("paginations.active")}
54
+ ), K = d.aBox(
55
+ (n) => b`
56
+ ${B};
57
+ ${n["aria-current"] && h("paginations.active")}
80
58
  `
81
- ), C = M(
59
+ ), f = 5, O = 3;
60
+ function Q({ page: n, pageCount: t, rangeDisplay: r }) {
61
+ return z(() => {
62
+ if (t <= r || t <= f + 1)
63
+ return x(t, (l) => l + 1);
64
+ const e = U(n, t), c = e === "before" ? x(f, (l) => l + 1) : [1], i = e === "center" ? x(O, (l) => l + n - 1) : [], u = e === "after" ? x(f, (l) => l + t - f + 1) : [t];
65
+ return V([c, i, u], "-");
66
+ }, [n, t, r]);
67
+ }
68
+ function x(n, t) {
69
+ return Array.from({ length: n }, (r, e) => t(e));
70
+ }
71
+ function U(n, t) {
72
+ if (n < f) return "before";
73
+ if (n >= f && n <= t - f + 1) return "center";
74
+ if (n > t - f + 1) return "after";
75
+ }
76
+ function V(n, t) {
77
+ return n.reduce((r, e, c) => {
78
+ const i = [];
79
+ return i.push(...r), i.push(...e), e.length && c < n.length - 1 && i.push(t), i;
80
+ }, []);
81
+ }
82
+ const g = F(
82
83
  ({
83
- "aria-label": e,
84
+ "aria-label": n,
84
85
  dataTestId: t,
85
86
  getHref: r,
86
- leftArrow: s,
87
+ leftArrow: e,
87
88
  onChange: c,
88
- page: n,
89
+ page: i,
89
90
  pageCount: u,
90
91
  rangeDisplay: l = 5,
91
92
  rightArrow: A,
92
93
  ...D
93
94
  }, L) => {
94
- const w = K({ page: n, pageCount: u, rangeDisplay: l }), $ = R(null), k = R(null), E = n === 1, h = n === u, N = y(
95
- (o) => {
96
- o.preventDefault();
97
- const f = n - 1;
98
- f === 1 && $.current.focus(), c(f);
95
+ const w = Q({ page: i, pageCount: u, rangeDisplay: l }), $ = k(null), R = k(null), j = i === 1, v = i === u, E = p(
96
+ (s) => {
97
+ s.preventDefault();
98
+ const a = i - 1;
99
+ a === 1 && $.current.focus(), c(a);
99
100
  },
100
- [n, c]
101
- ), P = y(
102
- (o) => {
103
- o.preventDefault();
104
- const f = n + 1;
105
- f === u && k.current.focus(), c(f);
101
+ [i, c]
102
+ ), N = p(
103
+ (s) => {
104
+ s.preventDefault();
105
+ const a = i + 1;
106
+ a === u && R.current.focus(), c(a);
106
107
  },
107
- [n, u, c]
108
+ [i, u, c]
108
109
  );
109
- return /* @__PURE__ */ i.createElement(
110
- O,
110
+ return /* @__PURE__ */ o.jsx(
111
+ S,
111
112
  {
112
- "aria-label": e,
113
+ "aria-label": n,
113
114
  "data-testid": t,
114
115
  ref: L,
115
116
  role: "navigation",
116
- ...D
117
- },
118
- /* @__PURE__ */ i.createElement(Q, null, /* @__PURE__ */ i.createElement(b, null, /* @__PURE__ */ i.createElement(
119
- B,
120
- {
121
- "aria-disabled": E,
122
- "data-testid": t ? `${t}-arrow-prev` : void 0,
123
- href: r ? r(E ? n : n - 1) : "",
124
- onClick: E ? void 0 : N,
125
- ref: $
126
- },
127
- s || /* @__PURE__ */ i.createElement(G, { size: "sm" })
128
- )), w.map(
129
- (o, f) => o === "-" ? (
130
- // eslint-disable-next-line react/no-array-index-key
131
- /* @__PURE__ */ i.createElement(b, { key: `${f}-` }, /* @__PURE__ */ i.createElement(U, null, "..."))
132
- ) : /* @__PURE__ */ i.createElement(b, { key: o }, /* @__PURE__ */ i.createElement(
133
- V,
134
- {
135
- "aria-current": o === n,
136
- "data-testid": t ? `${t}-${o}` : void 0,
137
- href: r ? r(o) : "",
138
- onClick: (_) => {
139
- _.preventDefault(), c(o);
117
+ ...D,
118
+ children: /* @__PURE__ */ o.jsxs(q, { children: [
119
+ /* @__PURE__ */ o.jsx(m, { children: /* @__PURE__ */ o.jsx(
120
+ y,
121
+ {
122
+ "aria-disabled": j,
123
+ "data-testid": t ? `${t}-arrow-prev` : void 0,
124
+ href: r ? r(j ? i : i - 1) : "",
125
+ onClick: j ? void 0 : E,
126
+ ref: $,
127
+ children: e || /* @__PURE__ */ o.jsx(G, { size: "sm" })
128
+ }
129
+ ) }),
130
+ w.map(
131
+ (s, a) => s === "-" ? /* @__PURE__ */ o.jsx(m, { children: /* @__PURE__ */ o.jsx(J, { children: "..." }) }, `${a}-`) : /* @__PURE__ */ o.jsx(m, { children: /* @__PURE__ */ o.jsx(
132
+ K,
133
+ {
134
+ "aria-current": s === i,
135
+ "data-testid": t ? `${t}-${s}` : void 0,
136
+ href: r ? r(s) : "",
137
+ onClick: (P) => {
138
+ P.preventDefault(), c(s);
139
+ },
140
+ children: s
141
+ }
142
+ ) }, s)
143
+ ),
144
+ /* @__PURE__ */ o.jsx(m, { children: /* @__PURE__ */ o.jsx(
145
+ y,
146
+ {
147
+ "aria-disabled": v,
148
+ "data-testid": t ? `${t}-arrow-next` : void 0,
149
+ href: r ? r(v ? i : i + 1) : "",
150
+ onClick: v ? void 0 : N,
151
+ ref: R,
152
+ children: A || /* @__PURE__ */ o.jsx(_, { size: "sm" })
140
153
  }
141
- },
142
- o
143
- ))
144
- ), /* @__PURE__ */ i.createElement(b, null, /* @__PURE__ */ i.createElement(
145
- B,
146
- {
147
- "aria-disabled": h,
148
- "data-testid": t ? `${t}-arrow-next` : void 0,
149
- href: r ? r(h ? n : n + 1) : "",
150
- onClick: h ? void 0 : P,
151
- ref: k
152
- },
153
- A || /* @__PURE__ */ i.createElement(F, { size: "sm" })
154
- )))
154
+ ) })
155
+ ] })
156
+ }
155
157
  );
156
158
  }
157
159
  );
158
160
  export {
159
- C as Pagination
161
+ g as Pagination
160
162
  };
@@ -1,55 +1,56 @@
1
1
  "use client";
2
- import t, { useState as i } from "react";
2
+ import { j as t } from "./jsx-runtime-B7I4PJ0H.mjs";
3
+ import { useState as c } from "react";
4
+ import { InputText as m } from "./InputText.mjs";
5
+ import { forwardRef as x } from "./System.mjs";
6
+ import { Button as l } from "./Button.mjs";
3
7
  import "./Icon.mjs";
4
- import { S as l, H as m } from "./index-u1oHKa7X.mjs";
5
- import { Button as u } from "./Button.mjs";
6
- import { InputText as d } from "./InputText.mjs";
7
- import { forwardRef as f } from "./System.mjs";
8
- const w = ({
9
- dataTestId: e,
10
- isHidden: o,
8
+ import { S as d, H as u } from "./index-wl3X6EM1.mjs";
9
+ const f = ({
10
+ dataTestId: o,
11
+ isHidden: s,
11
12
  onClick: r,
12
- title: n
13
- }) => /* @__PURE__ */ t.createElement(
14
- u,
13
+ title: e
14
+ }) => /* @__PURE__ */ t.jsx(
15
+ l,
15
16
  {
16
17
  "aria-controls": "password",
17
- "aria-expanded": `${!o}`,
18
- dataTestId: e && `${e}-action`,
18
+ "aria-expanded": `${!s}`,
19
+ dataTestId: o ? `${o}-action` : null,
19
20
  onClick: r,
20
21
  shape: "circle",
21
22
  size: "xs",
22
- title: n,
23
- variant: "ghost"
24
- },
25
- o ? /* @__PURE__ */ t.createElement(l, null) : /* @__PURE__ */ t.createElement(m, null)
26
- ), x = f(
27
- ({ dataTestId: e, title: o, ...r }, n) => {
28
- const [a, c] = i("password"), s = a === "password", p = () => {
29
- c(s ? "text" : "password");
23
+ title: e,
24
+ variant: "ghost",
25
+ children: s ? /* @__PURE__ */ t.jsx(d, {}) : /* @__PURE__ */ t.jsx(u, {})
26
+ }
27
+ ), w = x(
28
+ ({ dataTestId: o, title: s, ...r }, e) => {
29
+ const [n, a] = c("password"), p = n === "password", i = () => {
30
+ a(p ? "text" : "password");
30
31
  };
31
- return /* @__PURE__ */ t.createElement(
32
- d,
32
+ return /* @__PURE__ */ t.jsx(
33
+ m,
33
34
  {
34
35
  ...r,
35
- dataTestId: e,
36
- icon: /* @__PURE__ */ t.createElement(
37
- w,
36
+ dataTestId: o,
37
+ icon: /* @__PURE__ */ t.jsx(
38
+ f,
38
39
  {
39
- dataTestId: e,
40
- isHidden: s,
41
- onClick: p,
42
- title: o
40
+ dataTestId: o,
41
+ isHidden: p,
42
+ onClick: i,
43
+ title: s
43
44
  }
44
45
  ),
45
46
  iconPlacement: "right",
46
- ref: n,
47
- type: a
47
+ ref: e,
48
+ type: n
48
49
  }
49
50
  );
50
51
  }
51
52
  );
52
- x.displayName = "PasswordInput";
53
+ w.displayName = "PasswordInput";
53
54
  export {
54
- x as PasswordInput
55
+ w as PasswordInput
55
56
  };
package/dist/Picker.mjs CHANGED
@@ -1,46 +1,48 @@
1
1
  "use client";
2
- import e from "react";
3
- import u, { system as R } from "@xstyled/styled-components";
4
- import { shouldForwardProp as $, forwardRef as k } from "./System.mjs";
5
- import { R as y } from "./NLEBE274-QOMV1l7e.mjs";
6
- import { Label as E } from "./Label.mjs";
7
- import { FieldGroup as b } from "./FieldGroup.mjs";
8
- import { Box as w } from "./Box.mjs";
9
- import { u as x, R as P } from "./radio-group-RFyDp0KD.mjs";
10
- const h = u(y).withConfig({ shouldForwardProp: $ })`
2
+ import { j as o } from "./jsx-runtime-B7I4PJ0H.mjs";
3
+ import { Box as u } from "./Box.mjs";
4
+ import { FieldGroup as x } from "./FieldGroup.mjs";
5
+ import { Label as R } from "./Label.mjs";
6
+ import { shouldForwardProp as $, forwardRef as j } from "./System.mjs";
7
+ import h, { system as k } from "@xstyled/styled-components";
8
+ import { R as y } from "./NLEBE274-oSxMftGy.mjs";
9
+ import { u as b, R as w } from "./radio-group-C0fUHvam.mjs";
10
+ const P = h(y).withConfig({ shouldForwardProp: $ })`
11
11
  position: absolute;
12
12
  top: 0;
13
13
  left: 0;
14
14
  opacity: 0;
15
15
 
16
- ${R};
17
- `, F = k(
18
- ({ dataTestId: t, label: l, name: i, onChange: a, options: s, required: c, value: m, ...p }, f) => {
19
- const d = x({ defaultValue: m }), n = (o) => {
20
- o.stopPropagation(), a && a(o);
16
+ ${k};
17
+ `, F = j(
18
+ ({ dataTestId: e, label: m, name: s, onChange: t, options: p, required: a, value: l, ...c }, d) => {
19
+ const f = b({ defaultValue: l }), n = (r) => {
20
+ r.stopPropagation(), t && t(r);
21
21
  };
22
- return /* @__PURE__ */ e.createElement(
23
- b,
22
+ return /* @__PURE__ */ o.jsx(
23
+ x,
24
24
  {
25
- ...p,
26
- as: P,
27
- dataTestId: t,
25
+ ...c,
26
+ as: w,
27
+ dataTestId: e,
28
28
  mb: 0,
29
- ref: f,
30
- required: c,
31
- store: d
32
- },
33
- /* @__PURE__ */ e.createElement(w, { display: "flex", flexWrap: "wrap" }, s.map(({ element: o, value: r }) => /* @__PURE__ */ e.createElement(
34
- E,
35
- {
36
- checkableField: !0,
37
- dataTestId: t && `${t}-item-${i}-${r}`,
38
- key: `${l}-${i}-${r}`,
39
- onClick: n
40
- },
41
- /* @__PURE__ */ e.createElement(h, { name: i, value: r }),
42
- /* @__PURE__ */ e.createElement(o, { selected: m === r })
43
- )))
29
+ ref: d,
30
+ required: a,
31
+ store: f,
32
+ children: /* @__PURE__ */ o.jsx(u, { display: "flex", flexWrap: "wrap", children: p.map(({ element: r, value: i }) => /* @__PURE__ */ o.jsxs(
33
+ R,
34
+ {
35
+ checkableField: !0,
36
+ dataTestId: e ? `${e}-item-${s}-${i}` : null,
37
+ onClick: n,
38
+ children: [
39
+ /* @__PURE__ */ o.jsx(P, { name: s, value: i }),
40
+ /* @__PURE__ */ o.jsx(r, { selected: l === i })
41
+ ]
42
+ },
43
+ `${m}-${s}-${i}`
44
+ )) })
45
+ }
44
46
  );
45
47
  }
46
48
  );