twenty-ui 2.50.0 → 2.51.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 (215) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/README.md +36 -32
  3. package/dist/{AllIcons-Cyd7721G.cjs → AllIcons-1tBWXXrE.cjs} +1 -1
  4. package/dist/{AllIcons-D132B8_i.js → AllIcons-ayl8BCtV.js} +1 -1
  5. package/dist/Dropdown-D_hFndP5.cjs +1 -0
  6. package/dist/Dropdown-xXsGBv57.js +1056 -0
  7. package/dist/Input-D1sIHUZ5.js +25 -0
  8. package/dist/Input-D69M4UwD.cjs +1 -0
  9. package/dist/ListItem-B-SFWJZb.cjs +1 -0
  10. package/dist/ListItem-WLONJMo5.js +91 -0
  11. package/dist/ListItem.module-B31VK9XZ.js +34 -0
  12. package/dist/ListItem.module-DiUK6-0Z.cjs +1 -0
  13. package/dist/OverflowingTextWithTooltip-ClpPsdpP.cjs +1 -0
  14. package/dist/OverflowingTextWithTooltip-D4eZc-7P.js +96 -0
  15. package/dist/ProgressBar-8pjpGrmZ.js +99 -0
  16. package/dist/ProgressBar-goqxS9NE.cjs +1 -0
  17. package/dist/Radio-CpQPRHXa.cjs +1 -0
  18. package/dist/Radio-VTjpEz8M.js +175 -0
  19. package/dist/Skeleton-BbIF780H.js +31 -0
  20. package/dist/Skeleton-tXeIy4qq.cjs +1 -0
  21. package/dist/TablerIcons-B-5Ua_Ne.js +460 -0
  22. package/dist/{Tooltip-DL3sfbuw.cjs → Tooltip-08dDawT_.cjs} +1 -1
  23. package/dist/components/data-display/DetailsRow/DetailsRow.d.ts +2 -0
  24. package/dist/components/data-display/DetailsRow/types/DetailsRowProps.d.ts +9 -0
  25. package/dist/components/data-display/index.d.ts +2 -0
  26. package/dist/components/data-display.cjs +1 -1
  27. package/dist/components/data-display.mjs +9 -8
  28. package/dist/components/feedback/InlineBanner/types/InlineBannerProps.d.ts +1 -1
  29. package/dist/components/feedback.cjs +1 -1
  30. package/dist/components/feedback.mjs +1 -1
  31. package/dist/components/input/DatePicker/DatePicker.d.ts +2 -0
  32. package/dist/components/input/DatePicker/__stories__/DatePickerCssVariableThemeExample.d.ts +1 -0
  33. package/dist/components/input/DatePicker/__stories__/DatePickerExample.d.ts +5 -0
  34. package/dist/components/input/DatePicker/__stories__/DatePickerExternalMonthExample.d.ts +4 -0
  35. package/dist/components/input/DatePicker/__stories__/DatePickerNavigationUnmountExample.d.ts +2 -0
  36. package/dist/components/input/DatePicker/__stories__/datePickerWeekdayLabels.d.ts +1 -0
  37. package/dist/components/input/DatePicker/internal/DatePickerException.d.ts +5 -0
  38. package/dist/components/input/DatePicker/internal/DatePickerHeader.d.ts +3 -0
  39. package/dist/components/input/DatePicker/internal/DatePickerSelect.d.ts +15 -0
  40. package/dist/components/input/DatePicker/internal/DatePickerSelectLifecycleEffect.d.ts +7 -0
  41. package/dist/components/input/DatePicker/internal/DatePickerViewedMonthEffect.d.ts +9 -0
  42. package/dist/components/input/DatePicker/internal/ReactDatePickerLibrary.d.ts +2 -0
  43. package/dist/components/input/DatePicker/internal/datePickerConstants.d.ts +6 -0
  44. package/dist/components/input/DatePicker/internal/formatDatePickerLocalDate.d.ts +1 -0
  45. package/dist/components/input/DatePicker/internal/parseDatePickerDateOrThrow.d.ts +1 -0
  46. package/dist/components/input/DatePicker/internal/parseDatePickerLocalDateOrThrow.d.ts +1 -0
  47. package/dist/components/input/DatePicker/internal/validateDatePickerHighlightedRangeOrThrow.d.ts +4 -0
  48. package/dist/components/input/DatePicker/types/DatePickerHeaderProps.d.ts +9 -0
  49. package/dist/components/input/DatePicker/types/DatePickerProps.d.ts +42 -0
  50. package/dist/components/input/EmojiPicker/EmojiPicker.d.ts +2 -0
  51. package/dist/components/input/EmojiPicker/__stories__/EmojiPickerExample.d.ts +4 -0
  52. package/dist/components/input/EmojiPicker/__stories__/emojiPickerStoryData.d.ts +30 -0
  53. package/dist/components/input/EmojiPicker/__stories__/emojiPickerStoryEmojibaseUrl.d.ts +1 -0
  54. package/dist/components/input/EmojiPicker/__stories__/mockEmojiPickerStoryData.d.ts +5 -0
  55. package/dist/components/input/EmojiPicker/internal/EmojiPickerEmoji.d.ts +2 -0
  56. package/dist/components/input/EmojiPicker/internal/EmojiPickerRow.d.ts +2 -0
  57. package/dist/components/input/EmojiPicker/internal/EmojiPickerScrollEffect.d.ts +6 -0
  58. package/dist/components/input/EmojiPicker/internal/scrollActiveEmojiIntoView.d.ts +1 -0
  59. package/dist/components/input/EmojiPicker/types/EmojiPickerProps.d.ts +11 -0
  60. package/dist/components/input/FormFieldRow/FormFieldRow.d.ts +2 -0
  61. package/dist/components/input/FormFieldRow/types/FormFieldRowProps.d.ts +12 -0
  62. package/dist/components/input/ReactionButton/ReactionButton.d.ts +2 -0
  63. package/dist/components/input/ReactionButton/__stories__/ReactionButtonExample.d.ts +2 -0
  64. package/dist/components/input/ReactionButton/types/ReactionButtonProps.d.ts +14 -0
  65. package/dist/components/input/SearchInput/SearchInput.d.ts +1 -1
  66. package/dist/components/input/SearchInput/types/SearchInputProps.d.ts +1 -1
  67. package/dist/components/input/SegmentedControl/SegmentedControl.d.ts +1 -1
  68. package/dist/components/input/SegmentedControl/types/SegmentedControlProps.d.ts +2 -0
  69. package/dist/components/input/SegmentedControl/types/SegmentedControlVariant.d.ts +1 -0
  70. package/dist/components/input/index.d.ts +10 -0
  71. package/dist/components/input.cjs +1 -1
  72. package/dist/components/input.mjs +17 -13
  73. package/dist/components/layout/LabeledSeparator/LabeledSeparator.d.ts +2 -0
  74. package/dist/components/layout/LabeledSeparator/types/LabeledSeparatorProps.d.ts +7 -0
  75. package/dist/components/layout/index.d.ts +2 -0
  76. package/dist/components/layout.cjs +1 -1
  77. package/dist/components/layout.mjs +5 -4
  78. package/dist/components/navigation/CountPager/CountPager.d.ts +2 -0
  79. package/dist/components/navigation/CountPager/__stories__/CountPagerCollectionExample.d.ts +3 -0
  80. package/dist/components/navigation/CountPager/__stories__/CountPagerExample.d.ts +2 -0
  81. package/dist/components/navigation/CountPager/types/CountPagerProps.d.ts +11 -0
  82. package/dist/components/navigation/Dropdown/Dropdown.d.ts +4 -4
  83. package/dist/components/navigation/Dropdown/__stories__/DropdownControlledPageSessionExample.d.ts +1 -0
  84. package/dist/components/navigation/Dropdown/__stories__/DropdownNestedPageSessionExample.d.ts +6 -0
  85. package/dist/components/navigation/Dropdown/__stories__/DropdownPageActivityExample.d.ts +1 -0
  86. package/dist/components/navigation/Dropdown/__stories__/DropdownPageSessionExample.d.ts +5 -0
  87. package/dist/components/navigation/Dropdown/__stories__/DropdownPickerPageSessionExample.d.ts +1 -0
  88. package/dist/components/navigation/Dropdown/hooks/useDropdownPage.d.ts +1 -0
  89. package/dist/components/navigation/Dropdown/internal/DropdownContent.d.ts +1 -1
  90. package/dist/components/navigation/Dropdown/internal/DropdownContextValue.d.ts +3 -0
  91. package/dist/components/navigation/Dropdown/internal/DropdownEmpty.d.ts +1 -1
  92. package/dist/components/navigation/Dropdown/internal/DropdownLoading.d.ts +1 -1
  93. package/dist/components/navigation/Dropdown/internal/DropdownPageEffect.d.ts +8 -0
  94. package/dist/components/navigation/Dropdown/internal/DropdownSearch.d.ts +1 -1
  95. package/dist/components/navigation/Dropdown/internal/isActiveDropdownElement.d.ts +1 -0
  96. package/dist/components/navigation/Dropdown/types/DropdownSearchProps.d.ts +1 -1
  97. package/dist/components/navigation/ListItemButton/ListItemButton.d.ts +1 -1
  98. package/dist/components/navigation/ListItemButton/types/ListItemButtonProps.d.ts +1 -1
  99. package/dist/components/navigation/index.d.ts +2 -0
  100. package/dist/components/navigation.cjs +1 -1
  101. package/dist/components/navigation.mjs +7 -6
  102. package/dist/components/settings.cjs +1 -1
  103. package/dist/components/settings.mjs +1 -1
  104. package/dist/components.cjs +1 -1
  105. package/dist/components.mjs +44 -37
  106. package/dist/{data-display-CXw-mxeS.js → data-display-DUMj_z1t.js} +25 -25
  107. package/dist/data-display-D_kbXJJd.cjs +2 -0
  108. package/dist/{data-display-DdES9XqZ.cjs → data-display-DzHM5j7j.cjs} +1 -1
  109. package/dist/data-display-b-9s0RTe.js +422 -0
  110. package/dist/feedback-B50I0C35.cjs +1 -0
  111. package/dist/feedback-BQFSnMjh.js +10 -0
  112. package/dist/{feedback-DspXawf9.cjs → feedback-BzR4ggrP.cjs} +1 -1
  113. package/dist/{feedback-4HKPcMRs.js → feedback-EaZszoXf.js} +29 -29
  114. package/dist/icon/components/TablerIcons.d.ts +1 -1
  115. package/dist/icon/constants/TwentyIconDictionary.d.ts +9 -0
  116. package/dist/icon/index.d.ts +1 -1
  117. package/dist/{icon-CUE-QGQK.js → icon-ICz2_dVB.js} +550 -944
  118. package/dist/icon-TSBamkxk.cjs +1 -0
  119. package/dist/icon.cjs +1 -1
  120. package/dist/icon.mjs +510 -504
  121. package/dist/index.cjs +1 -1
  122. package/dist/index.mjs +666 -652
  123. package/dist/input-BQABEELu.cjs +1 -0
  124. package/dist/input-CuySKbhm.js +2356 -0
  125. package/dist/input-DxoXgI5-.js +373 -0
  126. package/dist/input-ExCbk62Y.cjs +1 -0
  127. package/dist/layout-B1Iwc9ku.cjs +1 -0
  128. package/dist/layout-B2KvJ900.js +479 -0
  129. package/dist/navigation-DP5Edsq_.cjs +1 -0
  130. package/dist/navigation-DXMjQMPm.js +134 -0
  131. package/dist/primitives/data-display.cjs +1 -1
  132. package/dist/primitives/data-display.mjs +1 -1
  133. package/dist/primitives/feedback/Banner/Banner.d.ts +1 -1
  134. package/dist/primitives/feedback/Banner/internal/BannerComponent.d.ts +1 -1
  135. package/dist/primitives/feedback/Banner/types/BannerProps.d.ts +2 -0
  136. package/dist/primitives/feedback.cjs +1 -1
  137. package/dist/primitives/feedback.mjs +9 -8
  138. package/dist/primitives/input/Autocomplete/types/AutocompleteItemProps.d.ts +3 -1
  139. package/dist/primitives/input/Input/Input.d.ts +1 -1
  140. package/dist/primitives/input/Input/types/InputProps.d.ts +3 -0
  141. package/dist/primitives/input/InputGroup/InputGroup.d.ts +1 -1
  142. package/dist/primitives/input/InputGroup/types/InputGroupProps.d.ts +1 -0
  143. package/dist/primitives/input/Textarea/Textarea.d.ts +1 -1
  144. package/dist/primitives/input/Textarea/internal/TextareaAutoResizeEffect.d.ts +8 -0
  145. package/dist/primitives/input/Textarea/types/TextareaProps.d.ts +2 -0
  146. package/dist/primitives/input/index.d.ts +1 -0
  147. package/dist/primitives/input/types/InputVariant.d.ts +1 -0
  148. package/dist/primitives/input.cjs +1 -1
  149. package/dist/primitives/input.mjs +14 -14
  150. package/dist/primitives/navigation/ListItem/ListItem.d.ts +1 -1
  151. package/dist/primitives/navigation/ListItem/__stories__/ListItemMultilineExample.d.ts +7 -0
  152. package/dist/primitives/navigation/ListItem/types/ListItemDescriptionPlacement.d.ts +1 -1
  153. package/dist/primitives/navigation/ListItem/types/ListItemProps.d.ts +3 -0
  154. package/dist/primitives/navigation/ListItem/types/ListItemState.d.ts +1 -0
  155. package/dist/primitives/navigation.cjs +1 -1
  156. package/dist/primitives/navigation.mjs +1 -1
  157. package/dist/primitives/surfaces/Card/Card.d.ts +2 -0
  158. package/dist/primitives/surfaces/Card/internal/CardAction.d.ts +2 -0
  159. package/dist/primitives/surfaces/Card/internal/CardControl.d.ts +2 -0
  160. package/dist/primitives/surfaces/Card/types/CardActionProps.d.ts +2 -0
  161. package/dist/primitives/surfaces/Card/types/CardControlProps.d.ts +2 -0
  162. package/dist/primitives/surfaces/index.d.ts +2 -0
  163. package/dist/primitives/surfaces.cjs +1 -1
  164. package/dist/primitives/surfaces.mjs +2 -2
  165. package/dist/primitives/typography/Heading/types/HeadingProps.d.ts +4 -2
  166. package/dist/primitives/typography/OverflowingTextWithTooltip/types/OverflowingTextWithTooltipProps.d.ts +2 -1
  167. package/dist/primitives/typography/Text/Text.d.ts +1 -1
  168. package/dist/primitives/typography/Text/internal/TextTypographyProps.d.ts +7 -0
  169. package/dist/primitives/typography/Text/types/TextProps.d.ts +2 -1
  170. package/dist/primitives/typography/internal/TypographyColor.d.ts +2 -0
  171. package/dist/primitives/typography/internal/TypographyFontSize.d.ts +2 -0
  172. package/dist/primitives/typography.cjs +1 -1
  173. package/dist/primitives/typography.mjs +2 -2
  174. package/dist/primitives.cjs +1 -1
  175. package/dist/primitives.mjs +52 -51
  176. package/dist/{settings-XGSJtobU.js → settings-BTFAqYrD.js} +1 -1
  177. package/dist/{settings-DT5bEO6A.cjs → settings-D_iT1ngl.cjs} +1 -1
  178. package/dist/style.css +1 -1
  179. package/dist/surfaces-DtZwsfms.cjs +1 -0
  180. package/dist/surfaces-v0kQLZYO.js +224 -0
  181. package/dist/{typography-CWtuNruY.cjs → typography-B05olPwL.cjs} +1 -1
  182. package/dist/{typography-BPdXzW2T.js → typography-BwyZEDDi.js} +1 -1
  183. package/dist/utilities/color/utils/themeColorSchema.d.ts +15 -15
  184. package/package.json +3 -1
  185. package/dist/Dropdown-ChTVyesF.js +0 -1018
  186. package/dist/Dropdown-DlItz8Gh.cjs +0 -1
  187. package/dist/Input-DZWl81G_.js +0 -23
  188. package/dist/Input-DvL77rvu.cjs +0 -1
  189. package/dist/ListItem-C6Xl00m1.cjs +0 -1
  190. package/dist/ListItem-C84ANa76.js +0 -86
  191. package/dist/ListItem.module-BJ9Ttjrc.js +0 -34
  192. package/dist/ListItem.module-CO4u2oeF.cjs +0 -1
  193. package/dist/OverflowingTextWithTooltip-BQmpPObX.cjs +0 -1
  194. package/dist/OverflowingTextWithTooltip-BtB9cGdJ.js +0 -89
  195. package/dist/ProgressBar-CzGs7cuE.cjs +0 -1
  196. package/dist/ProgressBar-D4tKQ7OA.js +0 -84
  197. package/dist/Radio-BwBZ4e8g.js +0 -103
  198. package/dist/Radio-sIYxZnR_.cjs +0 -1
  199. package/dist/data-display-C-eoJ5En.js +0 -378
  200. package/dist/data-display-CM1yXpnE.cjs +0 -2
  201. package/dist/feedback-BSOWDBI0.js +0 -38
  202. package/dist/feedback-DBRXDPSP.cjs +0 -1
  203. package/dist/icon-BNcdwwdl.cjs +0 -1
  204. package/dist/input-CWWp7cqL.cjs +0 -1
  205. package/dist/input-CvZ_uB_9.cjs +0 -1
  206. package/dist/input-Qn5_aFYU.js +0 -785
  207. package/dist/input-k5cMhFI_.js +0 -428
  208. package/dist/layout-DDqeMgFv.js +0 -439
  209. package/dist/layout-iSfGrMrH.cjs +0 -1
  210. package/dist/navigation-7Y6gHFlj.cjs +0 -1
  211. package/dist/navigation-BcXCiLE1.js +0 -86
  212. package/dist/primitives/typography/internal/Label/Label.d.ts +0 -8
  213. package/dist/surfaces-q8voTXEJ.cjs +0 -1
  214. package/dist/surfaces-vhSZBmbz.js +0 -201
  215. package/dist/{Tooltip-6uS8_wdA.js → Tooltip-C7zc16gI.js} +1 -1
@@ -1,785 +0,0 @@
1
- import { t as y } from "./isDefined-fMi6eQ4r.js";
2
- import { Pn as Se, So as je, Tn as he, Uc as He, Wo as We, Zc as Ke, gl as Xe, js as Ye, ml as Ze, ts as Je } from "./icon-CUE-QGQK.js";
3
- import { t as P } from "./doNotTranslate-BSVT8Xyd.js";
4
- import { r as Ie } from "./theme-B2EaXhye.js";
5
- import { t as U } from "./mergeClassNames-ClFMR1v0.js";
6
- import { t as K } from "./normalizeSearchText-DLmPiBUZ.js";
7
- import { r as Ne, t as z } from "./Button-CU8BS-Yd.js";
8
- import { t as de } from "./isRenderableSlot-DT_depzM.js";
9
- import { t as ve } from "./OverflowingTextWithTooltip-BtB9cGdJ.js";
10
- import { n as Qe, o as J, r as ea, t as _ } from "./Dropdown-ChTVyesF.js";
11
- import { n as ne, t as aa } from "./Input-DZWl81G_.js";
12
- import { i as ue, n as ra, r as te, t as ta } from "./Radio-BwBZ4e8g.js";
13
- import { useRender as be } from "@base-ui/react/use-render";
14
- import { isFunction as oe, isNonEmptyArray as Q, isNonEmptyString as R, isNull as Oe, isString as na, isUndefined as le } from "@sniptt/guards";
15
- import { clsx as G } from "clsx";
16
- import { createContext as _e, createElement as oa, useContext as ee, useEffect as la, useId as M, useMemo as Ce, useRef as ia, useState as D } from "react";
17
- import { Fragment as L, jsx as e, jsxs as S } from "react/jsx-runtime";
18
- import { useMergedRefs as sa } from "@base-ui/utils/useMergedRefs";
19
- import { useControlled as Te } from "@base-ui/utils/useControlled";
20
- import { useStableCallback as ca } from "@base-ui/utils/useStableCallback";
21
- import { useValueAsRef as da } from "@base-ui/utils/useValueAsRef";
22
- import { formatNumber as ye } from "@base-ui/utils/formatNumber";
23
- import { RadioGroup as ua } from "@base-ui/react/radio-group";
24
- var Pe = _e(void 0), ma = "country:", ke = (a) => `${ma}${a}`, Re = ({ countries: a, value: r, defaultValue: t = null, onValueChange: o, disabled: l = !1, noCountryLabel: n = P("No country"), children: i }) => {
25
- const d = M(), [c, u] = Te({
26
- controlled: r,
27
- default: t,
28
- name: P("CountrySelect"),
29
- state: "value"
30
- }), v = Ce(() => a.map((m) => ({
31
- ...m,
32
- selectionValue: ke(m.value),
33
- searchText: K(m.label)
34
- })), [a]), p = Ce(() => new Map(v.map((m) => [m.value, m])), [v]), h = l || !Q(v);
35
- return /* @__PURE__ */ e(Pe.Provider, {
36
- value: {
37
- countries: v,
38
- selectedCountry: Oe(c) ? void 0 : p.get(c),
39
- value: c,
40
- disabled: h,
41
- noCountryLabel: n,
42
- selectionGroupId: d,
43
- changeValue: (m, C) => {
44
- if (h) {
45
- C.cancel();
46
- return;
47
- }
48
- o?.(m, C), C.isCanceled || u(m);
49
- }
50
- },
51
- children: i
52
- });
53
- }, Ee = ({ disabled: a, open: r, onOpenChange: t }) => {
54
- const o = ca(t);
55
- return la(() => {
56
- !a || !r || o(!1);
57
- }, [
58
- a,
59
- r,
60
- o
61
- ]), null;
62
- }, pa = "_root_1x3d7_1", ha = "_label_1x3d7_6", va = "_flag_1x3d7_14", Z = {
63
- root: pa,
64
- label: ha,
65
- flag: va
66
- }, ba = ({ ariaLabelledBy: a, ariaLabel: r, visibleLabelId: t }) => {
67
- if (R(a)) return a;
68
- if (!R(r))
69
- return t;
70
- }, ge = () => {
71
- const a = ee(Pe);
72
- if (!y(a)) throw new Error(P("CountrySelect parts must be inside CountrySelect.Root"));
73
- return a;
74
- }, Y = (a) => a.preventBaseUIHandler?.(), we = ({ label: a, wrapperProps: r, children: t, className: o, style: l, render: n, onClick: i, onMouseDown: d, onPointerDown: c, onKeyDown: u, onKeyUp: v, openOnHover: p, id: h, "aria-label": m, "aria-labelledby": C, "aria-describedby": O, ...I }) => {
75
- const { selectedCountry: f, disabled: b, noCountryLabel: T } = ge(), { open: N, setOpen: g } = J(), s = M(), k = h ?? s, E = `${s}-label`, V = `${s}-value`, B = R(a), A = R(m) ? m : void 0, w = ba({
76
- ariaLabelledBy: C,
77
- ariaLabel: A,
78
- visibleLabelId: B ? E : void 0
79
- }), $ = [O, (y(w) || y(A)) && !y(t) ? V : void 0].filter(R), ae = f?.label ?? T, j = y(f) ? f.flag : /* @__PURE__ */ e(Se, {}), X = (x) => ({
80
- ...x,
81
- disabled: b
82
- }), se = U(G(ne.input, ne.md, ue.trigger), o);
83
- return /* @__PURE__ */ S("div", {
84
- ...r,
85
- className: G(Z.root, r?.className),
86
- children: [
87
- /* @__PURE__ */ e(Ee, {
88
- disabled: b,
89
- open: N,
90
- onOpenChange: g
91
- }),
92
- B && /* @__PURE__ */ e("label", {
93
- id: E,
94
- className: Z.label,
95
- htmlFor: k,
96
- children: a
97
- }),
98
- /* @__PURE__ */ e(_.Trigger, {
99
- ...I,
100
- id: k,
101
- "aria-label": A,
102
- "aria-labelledby": w,
103
- "aria-describedby": Q($) ? $.join(" ") : void 0,
104
- "aria-disabled": b || void 0,
105
- openOnHover: b ? !1 : p,
106
- "data-disabled": b ? "" : void 0,
107
- onClick: b ? Y : i,
108
- onMouseDown: b ? Y : d,
109
- onPointerDown: b ? Y : c,
110
- onKeyDown: b ? Y : u,
111
- onKeyUp: b ? Y : v,
112
- className: (x) => se(X(x)),
113
- style: oe(l) ? (x) => l(X(x)) : l,
114
- render: oe(n) ? (x, re) => n(x, X(re)) : n,
115
- children: t ?? /* @__PURE__ */ S(L, { children: [
116
- /* @__PURE__ */ e("span", {
117
- className: Z.flag,
118
- "aria-hidden": "true",
119
- children: j
120
- }),
121
- /* @__PURE__ */ e("span", {
122
- className: ue.value,
123
- id: V,
124
- children: /* @__PURE__ */ e(ve, { text: ae })
125
- }),
126
- /* @__PURE__ */ e("span", {
127
- className: ue.icon,
128
- "aria-hidden": "true",
129
- children: /* @__PURE__ */ e(he, {})
130
- })
131
- ] })
132
- })
133
- ]
134
- });
135
- }, _a = "no-country", ga = ({ searchLabel: a = P("Search"), noResultsLabel: r = P("No results"), searchProps: t, render: o, ...l }) => {
136
- const { countries: n, value: i, changeValue: d, disabled: c, noCountryLabel: u, selectionGroupId: v } = ge(), { titleId: p, triggerId: h } = J(), m = y(l["aria-label"]) || y(l["aria-labelledby"]) ? void 0 : p ?? h, [C, O] = D(""), I = K(C.trim()), f = R(I), b = n.filter((s) => s.searchText.includes(I)), T = K(u).includes(I), N = T || Q(b), g = T && /* @__PURE__ */ e(_.OptionItem, {
137
- value: "no-country",
138
- disabled: c,
139
- startIcon: /* @__PURE__ */ e("span", {
140
- className: Z.flag,
141
- "aria-hidden": "true",
142
- children: /* @__PURE__ */ e(Se, {})
143
- }),
144
- children: u
145
- });
146
- return /* @__PURE__ */ S(L, { children: [
147
- /* @__PURE__ */ e(_.Search, {
148
- placeholder: a,
149
- "aria-label": a,
150
- ...t,
151
- value: C,
152
- onValueChange: O,
153
- disabled: c || t?.disabled
154
- }),
155
- N && /* @__PURE__ */ e(_.Separator, {}),
156
- /* @__PURE__ */ S(_.SelectionGroup, {
157
- ...l,
158
- "aria-labelledby": l["aria-labelledby"] ?? m,
159
- render: oe(o) ? (s) => o(s, {
160
- value: i,
161
- multiple: !1
162
- }) : o,
163
- id: v,
164
- value: Oe(i) ? _a : ke(i),
165
- onValueChange: (s, k) => {
166
- d(n.find((E) => E.selectionValue === s)?.value ?? null, k);
167
- },
168
- children: [N && /* @__PURE__ */ S(_.Section, {
169
- scrollable: !0,
170
- children: [
171
- !f && g,
172
- b.map((s) => /* @__PURE__ */ e(_.OptionItem, {
173
- value: s.selectionValue,
174
- disabled: c || s.disabled,
175
- startIcon: /* @__PURE__ */ e("span", {
176
- className: Z.flag,
177
- "aria-hidden": "true",
178
- children: s.flag
179
- }),
180
- children: s.label
181
- }, s.value)),
182
- f && g
183
- ]
184
- }), !N && /* @__PURE__ */ e(_.Empty, { children: r })]
185
- })
186
- ] });
187
- }, xe = (a) => {
188
- const { open: r } = J(), [t, o] = D(r), [l, n] = D(0);
189
- return t !== r && (o(r), r && n(l + 1)), /* @__PURE__ */ oa(ga, {
190
- ...a,
191
- key: l
192
- });
193
- }, fa = ({ open: a, defaultOpen: r = !1, onOpenChange: t, onEscapeKeyDown: o, onInteractOutside: l, defaultPage: n, popupProps: i, optionsProps: d, searchLabel: c, noResultsLabel: u, searchProps: v, closeOnSelect: p, ...h }) => {
194
- const { disabled: m } = ge(), [C, O] = D(r), I = a ?? C, f = !m && I, b = (s) => {
195
- s && m || (O(s), t?.(s));
196
- }, T = [h["aria-label"], h.label].find(R), N = y(i?.["aria-label"]) || y(i?.["aria-labelledby"]), g = y(d?.["aria-label"]) || y(d?.["aria-labelledby"]);
197
- return /* @__PURE__ */ S(L, { children: [/* @__PURE__ */ e(Ee, {
198
- disabled: m,
199
- open: I,
200
- onOpenChange: b
201
- }), /* @__PURE__ */ S(_.Root, {
202
- type: "picker",
203
- open: f,
204
- onOpenChange: b,
205
- onEscapeKeyDown: o,
206
- onInteractOutside: l,
207
- defaultPage: n,
208
- children: [/* @__PURE__ */ e(we, { ...h }), /* @__PURE__ */ e(_.Content, {
209
- "aria-label": N ? void 0 : T,
210
- "aria-labelledby": N ? void 0 : h["aria-labelledby"],
211
- ...i,
212
- children: /* @__PURE__ */ e(xe, {
213
- "aria-label": g ? void 0 : T,
214
- "aria-labelledby": g ? void 0 : h["aria-labelledby"],
215
- ...d,
216
- searchLabel: c,
217
- noResultsLabel: u,
218
- searchProps: v,
219
- closeOnSelect: p
220
- })
221
- })]
222
- })] });
223
- }, Ca = ({ countries: a, value: r, defaultValue: t, onValueChange: o, disabled: l, noCountryLabel: n, ...i }) => /* @__PURE__ */ e(Re, {
224
- countries: a,
225
- value: r,
226
- defaultValue: t,
227
- onValueChange: o,
228
- disabled: l,
229
- noCountryLabel: n,
230
- children: /* @__PURE__ */ e(fa, { ...i })
231
- }), Gr = Object.assign(Ca, {
232
- Root: Re,
233
- Trigger: we,
234
- Options: xe
235
- }), ya = "_trigger_18tlx_1", Sa = "_chevron_18tlx_40", Ia = "_options_18tlx_45", Na = "_emptyStatus_18tlx_51", ie = {
236
- trigger: ya,
237
- chevron: Sa,
238
- options: Ia,
239
- emptyStatus: Na
240
- }, $e = _e(void 0), Le = () => {
241
- const a = ee($e);
242
- if (!y(a)) throw new Error(P("CurrencyPicker parts must be inside CurrencyPicker.Root"));
243
- return a;
244
- }, Ve = ({ disabled: a = !1, searchable: r = !0, searchLabel: t = P("Search"), listLabel: o, emptyLabel: l = P("No results"), searchProps: n, className: i, render: d, ref: c, ...u }) => {
245
- const { state: v, groupId: p, options: h, selectionProps: m } = Le(), { titleId: C, triggerId: O } = J(), { value: I, defaultValue: f = "", onValueChange: b, ...T } = n ?? {}, [N, g] = D(f), s = I ?? N, k = r ? String(s).trim().toLowerCase() : "", E = h.filter(({ searchText: w }) => w.includes(k)), V = Q(E), B = v.disabled || a, A = y(o) ? void 0 : C ?? O;
246
- return be({
247
- render: d,
248
- ref: c,
249
- props: {
250
- ...u,
251
- className: G(ie.options, i),
252
- children: /* @__PURE__ */ S(L, { children: [
253
- r && /* @__PURE__ */ S(L, { children: [/* @__PURE__ */ e(_.Search, {
254
- placeholder: t,
255
- "aria-label": t,
256
- ...T,
257
- value: s,
258
- onValueChange: (w) => {
259
- b?.(w), le(I) && g(w);
260
- },
261
- disabled: B || n?.disabled
262
- }), /* @__PURE__ */ e(_.Separator, {})] }),
263
- /* @__PURE__ */ e(_.SelectionGroup, {
264
- ...m,
265
- id: p,
266
- "aria-label": o,
267
- "aria-labelledby": A,
268
- children: V && /* @__PURE__ */ e(_.Section, {
269
- scrollable: !0,
270
- children: E.map(({ currency: w, label: $ }) => /* @__PURE__ */ e(_.OptionItem, {
271
- value: w.code,
272
- disabled: B || w.disabled,
273
- children: na($) ? /* @__PURE__ */ e(ve, { text: $ }) : $
274
- }, w.code))
275
- })
276
- }),
277
- /* @__PURE__ */ e(_.Empty, {
278
- className: ie.emptyStatus,
279
- children: V ? null : l
280
- })
281
- ] })
282
- }
283
- });
284
- }, Ae = ({ code: a, name: r }) => `${r} (${a})`, Oa = (a) => `${Ae(a)} ${a.symbol ?? ""}`, Fe = ({ currencies: a, value: r, defaultValue: t = null, onValueChange: o, closeOnSelect: l, disabled: n = !1, selectedFirst: i = !1, getOptionLabel: d = Ae, getSearchText: c = Oa, renderValue: u, children: v }) => {
285
- const p = M(), { selections: h, initializeSelection: m } = J(), C = {
286
- value: r,
287
- defaultValue: t,
288
- onValueChange: o,
289
- closeOnSelect: l
290
- }, O = Qe({
291
- props: {
292
- ...C,
293
- id: p
294
- },
295
- storedState: h.get(p)
296
- }), I = O.multiple ? null : O.value, f = a.map((g) => ({
297
- currency: g,
298
- label: d(g),
299
- searchText: c(g).toLowerCase()
300
- })), b = f.find(({ currency: g }) => g.code === I), T = i && y(b) ? [b, ...f.filter((g) => g !== b)] : f, N = {
301
- value: I,
302
- selectedCurrency: b?.currency,
303
- disabled: n
304
- };
305
- return /* @__PURE__ */ S($e.Provider, {
306
- value: {
307
- state: N,
308
- groupId: p,
309
- options: T,
310
- selectionProps: C,
311
- renderValue: u
312
- },
313
- children: [le(r) && /* @__PURE__ */ e(ea, {
314
- id: p,
315
- initialState: O,
316
- initializeSelection: m
317
- }), oe(v) ? v(N) : v]
318
- });
319
- }, Ge = ({ children: a, placeholder: r, disabled: t = !1, className: o, ...l }) => {
320
- const { state: n, renderValue: i } = Le(), d = y(n.value) ? n.value : r;
321
- return /* @__PURE__ */ S(_.Trigger, {
322
- ...l,
323
- disabled: n.disabled || t,
324
- className: U(ie.trigger, o),
325
- children: [a ?? (y(i) ? i(n) : d), /* @__PURE__ */ e(he, {
326
- "aria-hidden": "true",
327
- className: ie.chevron
328
- })]
329
- });
330
- }, Ta = ({ currencies: a, value: r, defaultValue: t, onValueChange: o, closeOnSelect: l, disabled: n, selectedFirst: i, getOptionLabel: d, getSearchText: c, renderValue: u, open: v, defaultOpen: p, onOpenChange: h, onEscapeKeyDown: m, onInteractOutside: C, triggerProps: O, contentProps: I, optionsProps: f, ...b }) => /* @__PURE__ */ e(_.Root, {
331
- type: "picker",
332
- open: v,
333
- defaultOpen: p,
334
- onOpenChange: h,
335
- onEscapeKeyDown: m,
336
- onInteractOutside: C,
337
- children: /* @__PURE__ */ S(Fe, {
338
- currencies: a,
339
- value: r,
340
- defaultValue: t,
341
- onValueChange: o,
342
- closeOnSelect: l,
343
- disabled: n,
344
- selectedFirst: i,
345
- getOptionLabel: d,
346
- getSearchText: c,
347
- renderValue: u,
348
- children: [/* @__PURE__ */ e(Ge, {
349
- ...b,
350
- ...O
351
- }), /* @__PURE__ */ e(_.Content, {
352
- ...I,
353
- children: /* @__PURE__ */ e(Ve, { ...f })
354
- })]
355
- })
356
- }), Dr = Object.assign(Ta, {
357
- Root: Fe,
358
- Trigger: Ge,
359
- Options: Ve
360
- }), Pa = "_root_u3myi_1", ka = "_preview_u3myi_6", Ra = "_image_u3myi_35", Ea = "_fileInput_u3myi_48", wa = "_content_u3myi_58", xa = "_actions_u3myi_67", $a = "_helperText_u3myi_73", La = "_errorMessage_u3myi_78", F = {
361
- root: Pa,
362
- preview: ka,
363
- image: Ra,
364
- fileInput: Ea,
365
- content: wa,
366
- actions: xa,
367
- helperText: $a,
368
- errorMessage: La
369
- }, Va = ({ src: a }) => {
370
- const r = Ie(), [t, o] = D(!1);
371
- return !R(a) || t ? /* @__PURE__ */ e(We, {
372
- size: r.icon.size.lg,
373
- "aria-hidden": !0
374
- }) : /* @__PURE__ */ e("img", {
375
- className: F.image,
376
- src: a,
377
- alt: "",
378
- onError: () => o(!0)
379
- });
380
- }, Aa = "image/*", Mr = ({ src: a, onFileSelect: r, onRemove: t, onAbort: o, disabled: l = !1, isUploading: n = !1, helperText: i, errorMessage: d, uploadLabel: c = P("Upload"), removeLabel: u = P("Remove"), abortLabel: v = P("Abort"), accept: p = Aa, inputRef: h, onChange: m, "aria-describedby": C, className: O, style: I, dir: f, render: b, ref: T, ...N }) => {
381
- const g = ia(null), s = sa(g, h), k = M(), E = `${k}-helper`, V = `${k}-error`, B = R(a), A = R(i), w = R(d), $ = l || !y(r), ae = l || !B || !y(t), j = $ || n, X = ae || n, se = n && y(o), x = [
382
- C,
383
- A && E,
384
- w && V
385
- ].filter(R).join(" ") || void 0, re = () => {
386
- j || g.current?.click();
387
- }, Ue = (ce) => {
388
- const fe = ce.currentTarget.files?.[0];
389
- try {
390
- m?.(ce);
391
- } finally {
392
- ce.currentTarget.value = "";
393
- }
394
- j || !y(fe) || r?.(fe);
395
- };
396
- return be({
397
- render: b,
398
- ref: T,
399
- props: {
400
- className: G(F.root, O),
401
- style: I,
402
- dir: f,
403
- "aria-busy": n || N["aria-busy"],
404
- children: /* @__PURE__ */ S(L, { children: [/* @__PURE__ */ e("button", {
405
- className: F.preview,
406
- type: "button",
407
- disabled: $,
408
- "aria-disabled": n || void 0,
409
- "aria-label": c,
410
- "aria-describedby": x,
411
- onClick: re,
412
- children: /* @__PURE__ */ e(Va, { src: a }, a)
413
- }), /* @__PURE__ */ S("div", {
414
- className: F.content,
415
- children: [
416
- /* @__PURE__ */ S("div", {
417
- className: F.actions,
418
- children: [
419
- /* @__PURE__ */ e("input", {
420
- "aria-label": c,
421
- ...N,
422
- ref: s,
423
- className: F.fileInput,
424
- dir: f,
425
- children: void 0,
426
- dangerouslySetInnerHTML: void 0,
427
- type: "file",
428
- multiple: !1,
429
- value: void 0,
430
- defaultValue: void 0,
431
- accept: p,
432
- disabled: j,
433
- "aria-describedby": x,
434
- hidden: !0,
435
- onChange: Ue
436
- }),
437
- se ? /* @__PURE__ */ e(z, {
438
- type: "button",
439
- startIcon: /* @__PURE__ */ e(Xe, {}),
440
- onClick: o,
441
- disabled: l,
442
- variant: "outline",
443
- children: v
444
- }) : /* @__PURE__ */ e(z, {
445
- type: "button",
446
- startIcon: /* @__PURE__ */ e(Ke, {}),
447
- onClick: re,
448
- disabled: j,
449
- focusableWhenDisabled: n && !$,
450
- "aria-describedby": x,
451
- variant: "outline",
452
- children: c
453
- }),
454
- /* @__PURE__ */ e(z, {
455
- type: "button",
456
- startIcon: /* @__PURE__ */ e(He, {}),
457
- onClick: t,
458
- disabled: X,
459
- focusableWhenDisabled: n && !ae,
460
- variant: "outline",
461
- children: u
462
- })
463
- ]
464
- }),
465
- A && /* @__PURE__ */ e("span", {
466
- className: F.helperText,
467
- id: E,
468
- children: i
469
- }),
470
- w && /* @__PURE__ */ e("span", {
471
- className: F.errorMessage,
472
- id: V,
473
- role: "alert",
474
- children: d
475
- })
476
- ]
477
- })] })
478
- }
479
- });
480
- }, Fa = "_button_k3e4y_1", Ga = { button: Fa }, Br = ({ className: a, emphasis: r = "standard", size: t, variant: o, ...l }) => {
481
- const n = ee(Ne), i = t ?? n?.size ?? "sm", d = o ?? n?.variant ?? "ghost";
482
- return /* @__PURE__ */ e(z, {
483
- ...l,
484
- size: i,
485
- variant: d,
486
- "data-emphasis": r,
487
- className: U(Ga.button, a)
488
- });
489
- }, Da = "_button_1fwx7_1", Ma = { button: Da }, qr = ({ className: a, elevated: r = !0, variant: t, ...o }) => {
490
- const l = ee(Ne), n = t ?? l?.variant ?? "solid";
491
- return /* @__PURE__ */ e(z, {
492
- ...o,
493
- elevated: r,
494
- variant: n,
495
- className: U(Ma.button, a)
496
- });
497
- }, pe = {
498
- maximumFractionDigits: 15,
499
- numberingSystem: "latn",
500
- useGrouping: "min2"
501
- }, Ba = ({ nextValue: a, currentValue: r, reason: t }) => t === "input-blur" && ye(a, void 0, pe) === ye(r, void 0, pe), qa = "_root_17bio_1", za = "_valueInput_17bio_7", Ua = "_button_17bio_14", ja = "_icon_17bio_32", H = {
502
- root: qa,
503
- valueInput: za,
504
- button: Ua,
505
- icon: ja
506
- }, zr = ({ value: a, defaultValue: r, onValueChange: t, onValueCommitted: o, allowOutOfRange: l = !1, min: n, max: i, step: d = 1, disabled: c, readOnly: u, required: v, name: p, form: h, id: m, showButtons: C = !0, decrementLabel: O = P("Decrease value"), incrementLabel: I = P("Increase value"), className: f, ...b }) => {
507
- const [T, N] = Te({
508
- controlled: a,
509
- default: r ?? null,
510
- name: P("NumberStepper"),
511
- state: "value"
512
- }), g = da(T), s = (k, E) => {
513
- if (k !== g.current) {
514
- if (Ba({
515
- nextValue: k,
516
- currentValue: g.current,
517
- reason: E.reason
518
- })) {
519
- E.cancel();
520
- return;
521
- }
522
- t?.(k, E), !E.isCanceled && (g.current = k, N(k));
523
- }
524
- };
525
- return /* @__PURE__ */ S(te.Root, {
526
- value: T,
527
- onValueChange: s,
528
- onValueCommitted: o,
529
- min: n,
530
- max: i,
531
- allowOutOfRange: l,
532
- step: d,
533
- smallStep: d,
534
- largeStep: d,
535
- disabled: c,
536
- readOnly: u,
537
- required: v,
538
- name: p,
539
- form: h,
540
- id: m,
541
- format: pe,
542
- className: H.root,
543
- children: [
544
- C && /* @__PURE__ */ e(te.Decrement, {
545
- "aria-label": O,
546
- render: /* @__PURE__ */ e(z, {
547
- type: "button",
548
- size: "sm",
549
- className: H.button,
550
- startIcon: /* @__PURE__ */ e("span", {
551
- className: H.icon,
552
- children: /* @__PURE__ */ e(je, {})
553
- })
554
- })
555
- }),
556
- /* @__PURE__ */ e(te.Input, {
557
- ...b,
558
- form: h,
559
- className: U(G(ne.input, ne.sm, H.valueInput), f)
560
- }),
561
- C && /* @__PURE__ */ e(te.Increment, {
562
- "aria-label": I,
563
- render: /* @__PURE__ */ e(z, {
564
- type: "button",
565
- size: "sm",
566
- className: H.button,
567
- startIcon: /* @__PURE__ */ e("span", {
568
- className: H.icon,
569
- children: /* @__PURE__ */ e(Je, {})
570
- })
571
- })
572
- })
573
- ]
574
- });
575
- }, Ha = "_trigger_kh8iq_1", Wa = "_triggerFlag_kh8iq_35", Ka = "_optionFlag_kh8iq_36", Xa = "_chevron_kh8iq_56", Ya = "_selectedCountryLabel_kh8iq_61", Za = "_options_kh8iq_70", Ja = "_emptyStatus_kh8iq_76", q = {
576
- trigger: Ha,
577
- triggerFlag: Wa,
578
- optionFlag: Ka,
579
- chevron: Xa,
580
- selectedCountryLabel: Ya,
581
- options: Za,
582
- emptyStatus: Ja
583
- }, Qa = ({ label: a, callingCode: r }) => `${a} (+${r})`, er = "⁦", ar = "⁩", rr = ({ label: a, callingCode: r }) => `${a} (${er}+${r}${ar})`, tr = ({ country: a, normalizedSearch: r, callingCodeSearch: t }) => a.searchLabel.includes(r) || a.searchValue.includes(r) || R(t) && a.callingCode.includes(t), De = _e(null), Me = () => {
584
- const a = ee(De);
585
- if (!y(a)) throw new Error(P("PhoneCountryPicker parts require PhoneCountryPicker.Root."));
586
- return a;
587
- }, Be = ({ searchLabel: a = P("Search"), listLabel: r = P("Countries"), emptyLabel: t = P("No results"), disabled: o = !1, className: l, render: n, ref: i, ...d }) => {
588
- const { countries: c, value: u, onValueChange: v, disabled: p, closeOnSelect: h } = Me(), m = p || o, C = M(), [O, I] = D(""), f = K(O).trim(), b = f.startsWith("+") ? f.slice(1) : f, T = c.filter((s) => tr({
589
- country: s,
590
- normalizedSearch: f,
591
- callingCodeSearch: b
592
- })), N = T.find((s) => s.value === u), g = y(N) ? [N, ...T.filter((s) => s.value !== u)] : T;
593
- return be({
594
- render: n,
595
- ref: i,
596
- props: {
597
- ...d,
598
- className: G(q.options, l),
599
- children: /* @__PURE__ */ S(L, { children: [
600
- /* @__PURE__ */ e(_.Search, {
601
- value: O,
602
- onValueChange: I,
603
- placeholder: a,
604
- "aria-label": a,
605
- disabled: m
606
- }),
607
- /* @__PURE__ */ e(_.Separator, {}),
608
- /* @__PURE__ */ e(_.Section, {
609
- scrollable: !0,
610
- children: /* @__PURE__ */ e(_.SelectionGroup, {
611
- id: C,
612
- "aria-label": r,
613
- value: u,
614
- onValueChange: v,
615
- closeOnSelect: h,
616
- children: g.map((s) => {
617
- const k = Qa(s);
618
- return /* @__PURE__ */ e(_.OptionItem, {
619
- value: s.value,
620
- "aria-label": k,
621
- disabled: m || s.disabled,
622
- startIcon: /* @__PURE__ */ e("span", {
623
- className: q.optionFlag,
624
- "aria-hidden": !0,
625
- children: s.flag
626
- }),
627
- children: /* @__PURE__ */ e(ve, {
628
- text: /* @__PURE__ */ S(L, { children: [
629
- s.label,
630
- " (",
631
- /* @__PURE__ */ S("bdi", {
632
- dir: "ltr",
633
- children: ["+", s.callingCode]
634
- }),
635
- ")"
636
- ] }),
637
- tooltipContent: rr(s)
638
- })
639
- }, s.value);
640
- })
641
- })
642
- }),
643
- /* @__PURE__ */ e(_.Empty, {
644
- className: q.emptyStatus,
645
- children: Q(g) ? null : t
646
- })
647
- ] })
648
- }
649
- });
650
- }, qe = ({ children: a, countries: r, value: t, defaultValue: o = null, onValueChange: l, disabled: n = !1, closeOnSelect: i = !0 }) => {
651
- const [d, c] = D(o), u = le(t) ? d : t, v = r.map((p) => ({
652
- ...p,
653
- searchLabel: K(p.label),
654
- searchValue: K(p.value)
655
- }));
656
- return /* @__PURE__ */ e(De.Provider, {
657
- value: {
658
- countries: v,
659
- value: u,
660
- disabled: n,
661
- closeOnSelect: i,
662
- onValueChange: (p, h) => {
663
- l?.(p, h), !h.isCanceled && le(t) && c(p);
664
- }
665
- },
666
- children: a
667
- });
668
- }, ze = ({ children: a, disabled: r = !1, className: t, "aria-describedby": o, ...l }) => {
669
- const { countries: n, value: i, disabled: d } = Me(), c = n.find((p) => p.value === i), u = M(), v = [y(c) && u, o].filter(R).join(" ") || void 0;
670
- return /* @__PURE__ */ S(_.Trigger, {
671
- ...l,
672
- disabled: d || r,
673
- "aria-describedby": v,
674
- className: U(q.trigger, t),
675
- children: [a ?? /* @__PURE__ */ S(L, { children: [/* @__PURE__ */ e("span", {
676
- className: q.triggerFlag,
677
- "aria-hidden": !0,
678
- children: c?.flag ?? /* @__PURE__ */ e(Ze, {})
679
- }), /* @__PURE__ */ e(he, {
680
- className: q.chevron,
681
- "aria-hidden": !0
682
- })] }), y(c) && /* @__PURE__ */ e("span", {
683
- id: u,
684
- className: q.selectedCountryLabel,
685
- children: c.label
686
- })]
687
- });
688
- }, nr = ({ countries: a, value: r, defaultValue: t, onValueChange: o, disabled: l, closeOnSelect: n, dropdownProps: i, contentProps: d, optionsProps: c, ...u }) => /* @__PURE__ */ e(qe, {
689
- countries: a,
690
- value: r,
691
- defaultValue: t,
692
- onValueChange: o,
693
- disabled: l,
694
- closeOnSelect: n,
695
- children: /* @__PURE__ */ S(_.Root, {
696
- ...i,
697
- type: "picker",
698
- children: [/* @__PURE__ */ e(ze, { ...u }), /* @__PURE__ */ e(_.Content, {
699
- width: 280,
700
- ...d,
701
- children: /* @__PURE__ */ e(Be, { ...c })
702
- })]
703
- })
704
- }), Ur = Object.assign(nr, {
705
- Root: qe,
706
- Trigger: ze,
707
- Options: Be
708
- }), or = "_wrapper_c0mqd_1", lr = "_inputGroup_c0mqd_8", ir = "_searchIcon_c0mqd_14", me = {
709
- wrapper: or,
710
- inputGroup: lr,
711
- searchIcon: ir
712
- }, jr = ({ placeholder: a, actions: r, size: t = "md", id: o, "aria-label": l, "aria-labelledby": n, ...i }) => {
713
- const d = Ie(), c = M(), u = o ?? c;
714
- return /* @__PURE__ */ S("div", {
715
- className: me.wrapper,
716
- children: [/* @__PURE__ */ e(ra, {
717
- className: me.inputGroup,
718
- size: t,
719
- startElement: /* @__PURE__ */ e(Ye, {
720
- className: me.searchIcon,
721
- size: d.icon.size.md,
722
- "aria-hidden": !0
723
- }),
724
- children: /* @__PURE__ */ e(aa, {
725
- ...i,
726
- id: u,
727
- placeholder: a,
728
- "aria-label": R(n) ? void 0 : l ?? a,
729
- "aria-labelledby": n
730
- })
731
- }), r]
732
- });
733
- }, sr = "_container_1eoop_1", cr = "_sm_1eoop_20", dr = "_md_1eoop_26", ur = "_item_1eoop_32", mr = "_iconOnly_1eoop_72", pr = "_icon_1eoop_72", hr = "_label_1eoop_91", W = {
734
- container: sr,
735
- sm: cr,
736
- md: dr,
737
- item: ur,
738
- iconOnly: mr,
739
- icon: pr,
740
- label: hr
741
- }, Hr = ({ className: a, itemWidth: r = "equal", options: t, size: o = "md", ...l }) => {
742
- const n = M();
743
- return /* @__PURE__ */ e(ua, {
744
- ...l,
745
- className: U(G(W.container, W[o]), a),
746
- "data-item-width": r,
747
- children: t.map(({ "aria-label": i, disabled: d, label: c, startIcon: u, value: v }, p) => {
748
- const h = `${n}-${p}`, m = R(i);
749
- return /* @__PURE__ */ S(ta.Root, {
750
- value: v,
751
- disabled: d,
752
- "aria-labelledby": h,
753
- className: G(W.item, !de(c) && W.iconOnly),
754
- children: [
755
- de(u) && /* @__PURE__ */ e("span", {
756
- className: W.icon,
757
- "aria-hidden": !0,
758
- children: u
759
- }),
760
- de(c) && /* @__PURE__ */ e("span", {
761
- id: m ? void 0 : h,
762
- className: W.label,
763
- children: c
764
- }),
765
- m && /* @__PURE__ */ e("span", {
766
- id: h,
767
- hidden: !0,
768
- children: i
769
- })
770
- ]
771
- }, v);
772
- })
773
- });
774
- };
775
- export {
776
- qr as a,
777
- Dr as c,
778
- zr as i,
779
- Gr as l,
780
- jr as n,
781
- Br as o,
782
- Ur as r,
783
- Mr as s,
784
- Hr as t
785
- };