@easypost/easy-ui 1.0.0-alpha.64 → 1.0.0-alpha.66

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 (219) hide show
  1. package/Badge/index.js +14 -14
  2. package/Badge/index.mjs +14 -14
  3. package/Banner/index.js +5 -5
  4. package/Banner/index.mjs +5 -5
  5. package/Button/index.js +1 -1
  6. package/Button/index.mjs +1 -1
  7. package/CHANGELOG.md +14 -0
  8. package/Calendar/index.js +1 -1
  9. package/Calendar/index.mjs +1 -1
  10. package/Card/index.js +1 -1
  11. package/Card/index.mjs +1 -1
  12. package/Checkbox/index.js +1 -1
  13. package/Checkbox/index.mjs +1 -1
  14. package/CodeBlock/index.js +13 -13
  15. package/CodeBlock/index.mjs +13 -13
  16. package/CodeSnippet/index.js +1 -1
  17. package/CodeSnippet/index.mjs +1 -1
  18. package/DataGrid/index.js +57 -57
  19. package/DataGrid/index.mjs +58 -58
  20. package/DatePicker/index.js +3 -3
  21. package/DatePicker/index.mjs +5 -5
  22. package/DateRangePicker/index.js +3 -3
  23. package/DateRangePicker/index.mjs +5 -5
  24. package/Drawer/index.js +18 -18
  25. package/Drawer/index.mjs +22 -22
  26. package/DropdownButton/index.js +12 -12
  27. package/DropdownButton/index.mjs +12 -12
  28. package/EmptyStateCard/index.js +8 -8
  29. package/EmptyStateCard/index.mjs +8 -8
  30. package/FocusedProductLayout/index.js +23 -23
  31. package/FocusedProductLayout/index.mjs +23 -23
  32. package/ForgeLayout/index.js +41 -231
  33. package/ForgeLayout/index.mjs +40 -230
  34. package/FormLayout/index.js +5 -5
  35. package/FormLayout/index.mjs +5 -5
  36. package/HorizontalGrid/index.js +1 -1
  37. package/HorizontalGrid/index.mjs +1 -1
  38. package/HorizontalStack/index.js +1 -1
  39. package/HorizontalStack/index.mjs +1 -1
  40. package/Icon/index.js +1 -1
  41. package/Icon/index.mjs +1 -1
  42. package/IconButton/index.js +12 -12
  43. package/IconButton/index.mjs +12 -12
  44. package/InputField/index.js +1 -1
  45. package/InputField/index.mjs +1 -1
  46. package/KebabButton/index.js +1 -1
  47. package/KebabButton/index.mjs +1 -1
  48. package/Menu/MenuOverlay.d.ts.map +1 -1
  49. package/Menu/index.js +1 -1
  50. package/Menu/index.mjs +1 -1
  51. package/Menu/utilities.d.ts +3 -0
  52. package/Menu/utilities.d.ts.map +1 -1
  53. package/Modal/index.js +19 -19
  54. package/Modal/index.mjs +23 -23
  55. package/MultiSelect/MultiSelect.d.ts +123 -0
  56. package/MultiSelect/MultiSelect.d.ts.map +1 -0
  57. package/MultiSelect/MultiSelect.stories.d.ts +11 -0
  58. package/MultiSelect/MultiSelect.stories.d.ts.map +1 -0
  59. package/MultiSelect/MultiSelect.test.d.ts +2 -0
  60. package/MultiSelect/MultiSelect.test.d.ts.map +1 -0
  61. package/MultiSelect/MultiSelectDropdown.d.ts +22 -0
  62. package/MultiSelect/MultiSelectDropdown.d.ts.map +1 -0
  63. package/MultiSelect/index.d.ts +2 -0
  64. package/MultiSelect/index.d.ts.map +1 -0
  65. package/MultiSelect/index.js +1989 -0
  66. package/MultiSelect/index.mjs +1974 -0
  67. package/MultiSelect/utilities.d.ts +3 -0
  68. package/MultiSelect/utilities.d.ts.map +1 -0
  69. package/NexusLayout/index.js +28 -28
  70. package/NexusLayout/index.mjs +28 -28
  71. package/Notification/index.js +1 -1
  72. package/Notification/index.mjs +1 -1
  73. package/Pagination/index.js +7 -7
  74. package/Pagination/index.mjs +7 -7
  75. package/PillGroup/index.js +3 -1681
  76. package/PillGroup/index.mjs +3 -1681
  77. package/ProductLayout/index.js +21 -21
  78. package/ProductLayout/index.mjs +25 -25
  79. package/Provider/index.js +1 -1
  80. package/Provider/index.mjs +1 -1
  81. package/RadioButtonGroup/index.js +3 -3
  82. package/RadioButtonGroup/index.mjs +3 -3
  83. package/RadioGroup/index.js +1 -1
  84. package/RadioGroup/index.mjs +1 -1
  85. package/RangeCalendar/index.js +1 -1
  86. package/RangeCalendar/index.mjs +1 -1
  87. package/SearchNav/index.js +29 -29
  88. package/SearchNav/index.mjs +29 -29
  89. package/SectionCard/index.js +7 -7
  90. package/SectionCard/index.mjs +7 -7
  91. package/Select/index.js +5 -5
  92. package/Select/index.mjs +5 -5
  93. package/SelectorErrorTooltip/index.js +1 -1
  94. package/SelectorErrorTooltip/index.mjs +1 -1
  95. package/Spinner/index.js +1 -1
  96. package/Spinner/index.mjs +1 -1
  97. package/SplitToggleCard/index.js +4 -4
  98. package/SplitToggleCard/index.mjs +4 -4
  99. package/Stepper/index.js +1 -1
  100. package/Stepper/index.mjs +1 -1
  101. package/TabNav/index.js +1 -1
  102. package/TabNav/index.mjs +1 -1
  103. package/TabPanels/index.js +1 -1
  104. package/TabPanels/index.mjs +2 -2
  105. package/Tabs/index.js +1 -1
  106. package/Tabs/index.mjs +1 -1
  107. package/Text/index.js +1 -1
  108. package/Text/index.mjs +1 -1
  109. package/TextField/index.js +1 -1
  110. package/TextField/index.mjs +1 -1
  111. package/Textarea/index.js +1 -1
  112. package/Textarea/index.mjs +1 -1
  113. package/Toggle/index.js +1 -1
  114. package/Toggle/index.mjs +1 -1
  115. package/ToggleCard/index.js +2 -2
  116. package/ToggleCard/index.mjs +2 -2
  117. package/Tooltip/index.js +1 -1
  118. package/Tooltip/index.mjs +1 -1
  119. package/VerticalNav/index.js +24 -24
  120. package/VerticalNav/index.mjs +24 -24
  121. package/VerticalStack/index.js +1 -1
  122. package/VerticalStack/index.mjs +1 -1
  123. package/__chunks__/{Button-CDRssWxC.mjs → Button-BqogJAQ3.mjs} +3 -3
  124. package/__chunks__/{Button-SuH-KkYi.js → Button-CVaEK94Q.js} +18 -18
  125. package/__chunks__/{Button-DfkicQp7.mjs → Button-CVbi-24J.mjs} +18 -18
  126. package/__chunks__/{Button-BvLvcmfd.js → Button-Y550ybuK.js} +1 -1
  127. package/__chunks__/{Calendar-CB3kTGpr.mjs → Calendar-C2JlXaSY.mjs} +1 -1
  128. package/__chunks__/{Calendar-D5V31Ypy.js → Calendar-CmF_v-Dn.js} +1 -1
  129. package/__chunks__/{CalendarBase-CIkCiMYk.js → CalendarBase-Cavy4k_H.js} +18 -18
  130. package/__chunks__/{CalendarBase-Cq-ReOPx.mjs → CalendarBase-aeU9JZC2.mjs} +18 -18
  131. package/__chunks__/{Card-BKC3iEwF.mjs → Card-B5c1vM8E.mjs} +12 -12
  132. package/__chunks__/{Card-BGmLybqD.js → Card-BHZOcCVB.js} +12 -12
  133. package/__chunks__/{Checkbox-B-c8_oGX.js → Checkbox-BmtLwm3J.js} +19 -19
  134. package/__chunks__/{Checkbox-AbvJCEnW.mjs → Checkbox-IhSMESiF.mjs} +20 -20
  135. package/__chunks__/{CodeSnippet-CzP6GP8p.mjs → CodeSnippet-DA3SuGi9.mjs} +2 -2
  136. package/__chunks__/{CodeSnippet-D9Gfaozc.js → CodeSnippet-HAojQDBb.js} +2 -2
  137. package/__chunks__/{DatePickerBase-DVe9Z17z.mjs → DatePickerBase-DYuliQ2j.mjs} +20 -64
  138. package/__chunks__/{DatePickerBase-BW867uS-.js → DatePickerBase-PqJZhPW5.js} +18 -62
  139. package/__chunks__/Dialog-CFyC5TFs.js +232 -0
  140. package/__chunks__/Dialog-DnCSZh3s.mjs +233 -0
  141. package/__chunks__/{HelpMenu-BikR3il4.js → HelpMenu-DttT1pkc.js} +6 -6
  142. package/__chunks__/{HelpMenu-ylsZtQ2y.mjs → HelpMenu-dPaIsmEG.mjs} +6 -6
  143. package/__chunks__/{HorizontalGrid-7W4Y5Vah.js → HorizontalGrid-BFqXCljf.js} +1 -1
  144. package/__chunks__/{HorizontalGrid-B399c2dw.mjs → HorizontalGrid-CyBrrh6k.mjs} +1 -1
  145. package/__chunks__/{HorizontalStack-Bz49rrqk.js → HorizontalStack-BG-lZii5.js} +1 -1
  146. package/__chunks__/{HorizontalStack-9tVfFqP2.mjs → HorizontalStack-p9m9muAJ.mjs} +1 -1
  147. package/__chunks__/{Icon-AWZqgFkO.js → Icon-BHbBKuGB.js} +2 -2
  148. package/__chunks__/{Icon-tvIiMl4h.mjs → Icon-ZRjQkfey.mjs} +2 -2
  149. package/__chunks__/{InputCaption-DMwqCmEY.js → InputCaption-BQw7pLl1.js} +2 -2
  150. package/__chunks__/{InputCaption-BPHL8W55.mjs → InputCaption-DE7SnGJr.mjs} +2 -2
  151. package/__chunks__/{InputField-LUuwaWK6.mjs → InputField-1toY1X94.mjs} +6 -89
  152. package/__chunks__/{InputField-BBG9VjEM.js → InputField-e2dBsTrQ.js} +6 -89
  153. package/__chunks__/{InputIcon-C6fRUjFn.mjs → InputIcon-CKwsgYvg.mjs} +31 -31
  154. package/__chunks__/{InputIcon-BOj4dVSh.js → InputIcon-DM19rdNu.js} +31 -31
  155. package/__chunks__/{KebabButton-DXxpDShY.js → KebabButton-3APOVOtc.js} +4 -4
  156. package/__chunks__/{KebabButton-DdERbhKc.mjs → KebabButton-CGvwEB3q.mjs} +4 -4
  157. package/__chunks__/{Menu-BtQxi784.js → Menu-90Db_wYM.js} +22 -62
  158. package/__chunks__/{Menu-CGSgffvA.mjs → Menu-D7JiGJt4.mjs} +22 -62
  159. package/__chunks__/{Notification-sLPjuMls.mjs → Notification-C4gEE6IM.mjs} +14 -14
  160. package/__chunks__/{Notification-CTV7jwBV.js → Notification-DZ0uDsoT.js} +14 -14
  161. package/__chunks__/{Overlay-DyfvFsGi.mjs → Overlay-BEmOdNIB.mjs} +3 -3
  162. package/__chunks__/PillGroup-BetDOSFz.js +2061 -0
  163. package/__chunks__/PillGroup-Bp5vfk6Z.mjs +2062 -0
  164. package/__chunks__/{RadioGroup-jGUuixrB.mjs → RadioGroup-DPJOnxCi.mjs} +16 -16
  165. package/__chunks__/{RadioGroup-CN_RSlFy.js → RadioGroup-Qn2c29rT.js} +15 -15
  166. package/__chunks__/{RangeCalendar-D5fz339R.mjs → RangeCalendar-BNySCRAa.mjs} +1 -1
  167. package/__chunks__/{RangeCalendar-odwkDlEn.js → RangeCalendar-lhIzCnWl.js} +1 -1
  168. package/__chunks__/{SelectOverlay-BegZKkp1.js → SelectOverlay-CoOED545.js} +28 -188
  169. package/__chunks__/{SelectOverlay-CoSQv1a0.mjs → SelectOverlay-D12QgA_I.mjs} +29 -189
  170. package/__chunks__/{SelectorErrorTooltip-DT7rcGh6.js → SelectorErrorTooltip-CNinvIcU.js} +4 -4
  171. package/__chunks__/{SelectorErrorTooltip-By-GwbSg.mjs → SelectorErrorTooltip-Cz7Uw_O_.mjs} +4 -4
  172. package/__chunks__/{Spinner-dtD1VQqy.mjs → Spinner-Co64ezt-.mjs} +5 -5
  173. package/__chunks__/{Spinner-nHnby3-R.js → Spinner-DTH0xdij.js} +5 -5
  174. package/__chunks__/{Stepper-vfWux5uh.js → Stepper-DqcfNOrn.js} +25 -25
  175. package/__chunks__/{Stepper-DCWfT6Sx.mjs → Stepper-OFWKfhi3.mjs} +25 -25
  176. package/__chunks__/{TabNav-BRBhGNv8.mjs → TabNav-B44TuB70.mjs} +1 -1
  177. package/__chunks__/{TabNav-BJUikM9a.js → TabNav-DzF57oTN.js} +1 -1
  178. package/__chunks__/{Tabs-Do2OPQch.mjs → Tabs-ClOwavjv.mjs} +17 -17
  179. package/__chunks__/{Tabs-DX6oanPk.js → Tabs-CsxDAl1X.js} +17 -17
  180. package/__chunks__/{Text-DM6H1mZu.js → Text-BwXTDw77.js} +34 -34
  181. package/__chunks__/{Text-DLBOW0Eu.mjs → Text-DYLBjpe-.mjs} +34 -34
  182. package/__chunks__/{TextField-BmHD0Ts_.mjs → TextField-DVWDMYaM.mjs} +1 -1
  183. package/__chunks__/{TextField-DN6oGeBc.js → TextField-YD_1oSnk.js} +1 -1
  184. package/__chunks__/{Toggle-CDwSjy-c.mjs → Toggle-DiK1wHdG.mjs} +11 -11
  185. package/__chunks__/{Toggle-CkJcayVz.js → Toggle-gPKUf7QS.js} +11 -11
  186. package/__chunks__/{Tooltip-CSsijgRV.mjs → Tooltip-BX_C7x_7.mjs} +10 -10
  187. package/__chunks__/{Tooltip-U0vMQeot.js → Tooltip-DPZMv6Ia.js} +8 -8
  188. package/__chunks__/{VerticalStack-1CrrssEd.mjs → VerticalStack-C466n8W1.mjs} +3 -3
  189. package/__chunks__/{VerticalStack-D25ZR-UD.js → VerticalStack-DIpmkisq.js} +3 -3
  190. package/__chunks__/{useDialog-c-C07qhw.mjs → useDialog-h-MPfyGr.mjs} +1 -1
  191. package/__chunks__/{useEdgeInterceptors-DM6DGJVL.mjs → useEdgeInterceptors-BORL2txk.mjs} +5 -5
  192. package/__chunks__/{useEdgeInterceptors-g_iE4uY5.js → useEdgeInterceptors-DU8I_hQ1.js} +5 -5
  193. package/__chunks__/useFilter-D-K0Oj-7.mjs +65 -0
  194. package/__chunks__/useFilter-DpnZ54nd.js +64 -0
  195. package/__chunks__/{useFormValidation-v2O6VL2V.mjs → useFormValidation-B3euLzzR.mjs} +4 -4
  196. package/__chunks__/useListBoxSection-BlFRlBZy.js +192 -0
  197. package/__chunks__/useListBoxSection-BsSdeGKp.mjs +193 -0
  198. package/__chunks__/{useTriggerWidth-CRz8zSDa.mjs → useMenuTrigger-D4pQ727R.mjs} +3 -130
  199. package/__chunks__/{useTriggerWidth-Dj7C0lza.js → useMenuTrigger-qbIPy-fg.js} +0 -127
  200. package/__chunks__/useMenuTriggerState-Cf_X36NC.mjs +67 -0
  201. package/__chunks__/useMenuTriggerState-Dai3rheB.js +66 -0
  202. package/__chunks__/{useModalOverlay-S0R2uVTX.mjs → useModalOverlay-CkOujl0G.mjs} +1 -1
  203. package/__chunks__/{useOverlayPosition-BjK7cu6U.mjs → useOverlayPosition-dua8TTSS.mjs} +1 -1
  204. package/__chunks__/{useOverlayTrigger-DDcXdZOM.mjs → useOverlayTrigger-BS8c6XEz.mjs} +1 -1
  205. package/__chunks__/{useSelectableItem-D61t76J1.mjs → useSelectableItem-B8l2VAQ8.mjs} +2 -2
  206. package/__chunks__/{useSelectableList-UkBCcTuC.js → useSelectableList-CzTJAukw.js} +15 -0
  207. package/__chunks__/{useSelectableList-BdG5I7cy.mjs → useSelectableList-DsUuWr0P.mjs} +18 -3
  208. package/__chunks__/useTextField-CErFc3WZ.js +106 -0
  209. package/__chunks__/useTextField-Dd-YTxI4.mjs +107 -0
  210. package/__chunks__/useTriggerWidth-B-IM2wNY.js +132 -0
  211. package/__chunks__/useTriggerWidth-CAYuGPNq.mjs +133 -0
  212. package/__chunks__/{utilities-CaBPUKEB.js → utilities-BDABIMDb.js} +4 -0
  213. package/__chunks__/{utilities-DASknbaa.mjs → utilities-DpKIaDkW.mjs} +5 -1
  214. package/__chunks__/{utils-D4ddhsBL.mjs → utils-Dt6xdGol.mjs} +10 -2
  215. package/__chunks__/{utils-DIF5XAA2.js → utils-eHk7b-OB.js} +8 -0
  216. package/package.json +2 -2
  217. package/style.css +1609 -1444
  218. package/utilities/storybook.d.ts +1 -0
  219. package/utilities/storybook.d.ts.map +1 -1
@@ -0,0 +1,1989 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __defProps = Object.defineProperties;
4
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
5
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
8
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
9
+ var __spreadValues = (a, b) => {
10
+ for (var prop in b || (b = {}))
11
+ if (__hasOwnProp.call(b, prop))
12
+ __defNormalProp(a, prop, b[prop]);
13
+ if (__getOwnPropSymbols)
14
+ for (var prop of __getOwnPropSymbols(b)) {
15
+ if (__propIsEnum.call(b, prop))
16
+ __defNormalProp(a, prop, b[prop]);
17
+ }
18
+ return a;
19
+ };
20
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
21
+ var __objRest = (source, exclude) => {
22
+ var target = {};
23
+ for (var prop in source)
24
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
25
+ target[prop] = source[prop];
26
+ if (source != null && __getOwnPropSymbols)
27
+ for (var prop of __getOwnPropSymbols(source)) {
28
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
29
+ target[prop] = source[prop];
30
+ }
31
+ return target;
32
+ };
33
+ var __async = (__this, __arguments, generator) => {
34
+ return new Promise((resolve, reject) => {
35
+ var fulfilled = (value) => {
36
+ try {
37
+ step(generator.next(value));
38
+ } catch (e) {
39
+ reject(e);
40
+ }
41
+ };
42
+ var rejected = (value) => {
43
+ try {
44
+ step(generator.throw(value));
45
+ } catch (e) {
46
+ reject(e);
47
+ }
48
+ };
49
+ var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
50
+ step((generator = generator.apply(__this, __arguments)).next());
51
+ });
52
+ };
53
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
54
+ const React = require("react");
55
+ const Button = require("../__chunks__/Button-Y550ybuK.js");
56
+ const utils = require("../__chunks__/utils-eHk7b-OB.js");
57
+ const useHover = require("../__chunks__/useHover-BIKwjrCT.js");
58
+ const useFocusRing = require("../__chunks__/useFocusRing-DFRFvht_.js");
59
+ const mergeProps = require("../__chunks__/mergeProps-DniMwM6P.js");
60
+ const PillGroup = require("../__chunks__/PillGroup-BetDOSFz.js");
61
+ const Dialog = require("../__chunks__/Dialog-CFyC5TFs.js");
62
+ const filterDOMProps = require("../__chunks__/filterDOMProps-D3iOHP0H.js");
63
+ const useResizeObserver = require("../__chunks__/useResizeObserver-BsbT3mjh.js");
64
+ const useFilter = require("../__chunks__/useFilter-DpnZ54nd.js");
65
+ const useFormValidation = require("../__chunks__/useFormValidation-DYz5WFze.js");
66
+ const SelectionManager = require("../__chunks__/SelectionManager-DuX6geJg.js");
67
+ const useSingleSelectListState = require("../__chunks__/useSingleSelectListState-5RB1w9vv.js");
68
+ const useListState = require("../__chunks__/useListState-I5rva0Fq.js");
69
+ const useControlledState = require("../__chunks__/useControlledState-mnKBd6Uc.js");
70
+ const Overlay = require("../__chunks__/Overlay-Dmwy9VjC.js");
71
+ const LiveAnnouncer = require("../__chunks__/LiveAnnouncer-CzeNwq2D.js");
72
+ const ariaHideOutside = require("../__chunks__/ariaHideOutside-B6WqGXJj.js");
73
+ const useListBoxSection = require("../__chunks__/useListBoxSection-BlFRlBZy.js");
74
+ const usePress = require("../__chunks__/usePress-DNETV97g.js");
75
+ const useLabels = require("../__chunks__/useLabels-KmwewLTv.js");
76
+ const isVirtualEvent = require("../__chunks__/isVirtualEvent-DwoP1rNI.js");
77
+ const useSelectableList = require("../__chunks__/useSelectableList-CzTJAukw.js");
78
+ const useSelectableItem = require("../__chunks__/useSelectableItem-DpEX9QBc.js");
79
+ const useLocalizedStringFormatter = require("../__chunks__/useLocalizedStringFormatter-CaF1VsOH.js");
80
+ const useMenuTrigger = require("../__chunks__/useMenuTrigger-qbIPy-fg.js");
81
+ const useTextField = require("../__chunks__/useTextField-CErFc3WZ.js");
82
+ const Icon = require("../__chunks__/Icon-BHbBKuGB.js");
83
+ const utilities = require("../__chunks__/utilities-BDABIMDb.js");
84
+ const Spinner = require("../__chunks__/Spinner-DTH0xdij.js");
85
+ const Text = require("../__chunks__/Text-BwXTDw77.js");
86
+ const utilities_css = require("../utilities/css.js");
87
+ const utilities_useScrollbar = require("../utilities/useScrollbar.js");
88
+ const VisuallyHidden = require("../__chunks__/VisuallyHidden-CVfjb1YY.js");
89
+ function _interopNamespaceDefault(e) {
90
+ const n = Object.create(null, { [Symbol.toStringTag]: { value: "Module" } });
91
+ if (e) {
92
+ for (const k in e) {
93
+ if (k !== "default") {
94
+ const d = Object.getOwnPropertyDescriptor(e, k);
95
+ Object.defineProperty(n, k, d.get ? d : {
96
+ enumerable: true,
97
+ get: () => e[k]
98
+ });
99
+ }
100
+ }
101
+ }
102
+ n.default = e;
103
+ return Object.freeze(n);
104
+ }
105
+ const React__namespace = /* @__PURE__ */ _interopNamespaceDefault(React);
106
+ function $a9e7382a7d111cb5$export$b453a3bfd4a5fa9e(props) {
107
+ var _collection_getItem;
108
+ let { defaultFilter, menuTrigger = "input", allowsEmptyCollection = false, allowsCustomValue, shouldCloseOnBlur = true } = props;
109
+ let [showAllItems, setShowAllItems] = React.useState(false);
110
+ let [isFocused, setFocusedState] = React.useState(false);
111
+ let [focusStrategy, setFocusStrategy] = React.useState(null);
112
+ let onSelectionChange = (key) => {
113
+ if (props.onSelectionChange) props.onSelectionChange(key);
114
+ if (key === selectedKey) {
115
+ resetInputValue();
116
+ closeMenu();
117
+ }
118
+ };
119
+ var _props_items;
120
+ let { collection, selectionManager, selectedKey, setSelectedKey, selectedItem, disabledKeys } = useSingleSelectListState.$a0d645289fe9b86b$export$e7f05e985daf4b5f(__spreadProps(__spreadValues({}, props), {
121
+ onSelectionChange,
122
+ items: (_props_items = props.items) !== null && _props_items !== void 0 ? _props_items : props.defaultItems
123
+ }));
124
+ let defaultInputValue = props.defaultInputValue;
125
+ if (defaultInputValue == null) {
126
+ var _collection_getItem1;
127
+ var _collection_getItem_textValue;
128
+ if (selectedKey == null) defaultInputValue = "";
129
+ else defaultInputValue = (_collection_getItem_textValue = (_collection_getItem1 = collection.getItem(selectedKey)) === null || _collection_getItem1 === void 0 ? void 0 : _collection_getItem1.textValue) !== null && _collection_getItem_textValue !== void 0 ? _collection_getItem_textValue : "";
130
+ }
131
+ let [inputValue, setInputValue] = useControlledState.$458b0a5536c1a7cf$export$40bfa8c7b0832715(props.inputValue, defaultInputValue, props.onInputChange);
132
+ let originalCollection = collection;
133
+ let filteredCollection = React.useMemo(() => (
134
+ // No default filter if items are controlled.
135
+ props.items != null || !defaultFilter ? collection : $a9e7382a7d111cb5$var$filterCollection(collection, inputValue, defaultFilter)
136
+ ), [
137
+ collection,
138
+ inputValue,
139
+ defaultFilter,
140
+ props.items
141
+ ]);
142
+ let [lastCollection, setLastCollection] = React.useState(filteredCollection);
143
+ let menuOpenTrigger = React.useRef("focus");
144
+ let onOpenChange = (open2) => {
145
+ if (props.onOpenChange) props.onOpenChange(open2, open2 ? menuOpenTrigger.current : void 0);
146
+ selectionManager.setFocused(open2);
147
+ if (!open2) selectionManager.setFocusedKey(null);
148
+ };
149
+ let triggerState = Overlay.$fc909762b330b746$export$61c6a8c84e605fb6(__spreadProps(__spreadValues({}, props), {
150
+ onOpenChange,
151
+ isOpen: void 0,
152
+ defaultOpen: void 0
153
+ }));
154
+ let open = (focusStrategy2 = null, trigger) => {
155
+ let displayAllItems = trigger === "manual" || trigger === "focus" && menuTrigger === "focus";
156
+ if (allowsEmptyCollection || filteredCollection.size > 0 || displayAllItems && originalCollection.size > 0 || props.items) {
157
+ if (displayAllItems && !triggerState.isOpen && props.items === void 0)
158
+ setShowAllItems(true);
159
+ menuOpenTrigger.current = trigger;
160
+ setFocusStrategy(focusStrategy2);
161
+ triggerState.open();
162
+ }
163
+ };
164
+ let toggle = (focusStrategy2 = null, trigger) => {
165
+ let displayAllItems = trigger === "manual" || trigger === "focus" && menuTrigger === "focus";
166
+ if (!(allowsEmptyCollection || filteredCollection.size > 0 || displayAllItems && originalCollection.size > 0 || props.items) && !triggerState.isOpen) return;
167
+ if (displayAllItems && !triggerState.isOpen && props.items === void 0)
168
+ setShowAllItems(true);
169
+ if (!triggerState.isOpen) menuOpenTrigger.current = trigger;
170
+ toggleMenu(focusStrategy2);
171
+ };
172
+ let updateLastCollection = React.useCallback(() => {
173
+ setLastCollection(showAllItems ? originalCollection : filteredCollection);
174
+ }, [
175
+ showAllItems,
176
+ originalCollection,
177
+ filteredCollection
178
+ ]);
179
+ let toggleMenu = React.useCallback((focusStrategy2 = null) => {
180
+ if (triggerState.isOpen) updateLastCollection();
181
+ setFocusStrategy(focusStrategy2);
182
+ triggerState.toggle();
183
+ }, [
184
+ triggerState,
185
+ updateLastCollection
186
+ ]);
187
+ let closeMenu = React.useCallback(() => {
188
+ if (triggerState.isOpen) {
189
+ updateLastCollection();
190
+ triggerState.close();
191
+ }
192
+ }, [
193
+ triggerState,
194
+ updateLastCollection
195
+ ]);
196
+ let [lastValue, setLastValue] = React.useState(inputValue);
197
+ let resetInputValue = () => {
198
+ var _collection_getItem2;
199
+ var _collection_getItem_textValue2;
200
+ let itemText = selectedKey != null ? (_collection_getItem_textValue2 = (_collection_getItem2 = collection.getItem(selectedKey)) === null || _collection_getItem2 === void 0 ? void 0 : _collection_getItem2.textValue) !== null && _collection_getItem_textValue2 !== void 0 ? _collection_getItem_textValue2 : "" : "";
201
+ setLastValue(itemText);
202
+ setInputValue(itemText);
203
+ };
204
+ var _props_selectedKey, _ref;
205
+ let lastSelectedKey = React.useRef((_ref = (_props_selectedKey = props.selectedKey) !== null && _props_selectedKey !== void 0 ? _props_selectedKey : props.defaultSelectedKey) !== null && _ref !== void 0 ? _ref : null);
206
+ var _collection_getItem_textValue1;
207
+ let lastSelectedKeyText = React.useRef(selectedKey != null ? (_collection_getItem_textValue1 = (_collection_getItem = collection.getItem(selectedKey)) === null || _collection_getItem === void 0 ? void 0 : _collection_getItem.textValue) !== null && _collection_getItem_textValue1 !== void 0 ? _collection_getItem_textValue1 : "" : "");
208
+ React.useEffect(() => {
209
+ var _collection_getItem2;
210
+ if (isFocused && (filteredCollection.size > 0 || allowsEmptyCollection) && !triggerState.isOpen && inputValue !== lastValue && menuTrigger !== "manual") open(null, "input");
211
+ if (!showAllItems && !allowsEmptyCollection && triggerState.isOpen && filteredCollection.size === 0) closeMenu();
212
+ if (selectedKey != null && selectedKey !== lastSelectedKey.current) closeMenu();
213
+ if (inputValue !== lastValue) {
214
+ selectionManager.setFocusedKey(null);
215
+ setShowAllItems(false);
216
+ if (inputValue === "" && (props.inputValue === void 0 || props.selectedKey === void 0)) setSelectedKey(null);
217
+ }
218
+ if (selectedKey !== lastSelectedKey.current && (props.inputValue === void 0 || props.selectedKey === void 0)) resetInputValue();
219
+ else if (lastValue !== inputValue) setLastValue(inputValue);
220
+ var _collection_getItem_textValue2;
221
+ let selectedItemText = selectedKey != null ? (_collection_getItem_textValue2 = (_collection_getItem2 = collection.getItem(selectedKey)) === null || _collection_getItem2 === void 0 ? void 0 : _collection_getItem2.textValue) !== null && _collection_getItem_textValue2 !== void 0 ? _collection_getItem_textValue2 : "" : "";
222
+ if (!isFocused && selectedKey != null && props.inputValue === void 0 && selectedKey === lastSelectedKey.current) {
223
+ if (lastSelectedKeyText.current !== selectedItemText) {
224
+ setLastValue(selectedItemText);
225
+ setInputValue(selectedItemText);
226
+ }
227
+ }
228
+ lastSelectedKey.current = selectedKey;
229
+ lastSelectedKeyText.current = selectedItemText;
230
+ });
231
+ let validation = useFormValidation.$e5be200c675c3b3a$export$fc1a364ae1f3ff10(__spreadProps(__spreadValues({}, props), {
232
+ value: React.useMemo(() => ({
233
+ inputValue,
234
+ selectedKey
235
+ }), [
236
+ inputValue,
237
+ selectedKey
238
+ ])
239
+ }));
240
+ let revert = () => {
241
+ if (allowsCustomValue && selectedKey == null) commitCustomValue();
242
+ else commitSelection();
243
+ };
244
+ let commitCustomValue = () => {
245
+ lastSelectedKey.current = null;
246
+ setSelectedKey(null);
247
+ closeMenu();
248
+ };
249
+ let commitSelection = () => {
250
+ if (props.selectedKey !== void 0 && props.inputValue !== void 0) {
251
+ var _props_onSelectionChange, _collection_getItem2;
252
+ (_props_onSelectionChange = props.onSelectionChange) === null || _props_onSelectionChange === void 0 ? void 0 : _props_onSelectionChange.call(props, selectedKey);
253
+ var _collection_getItem_textValue2;
254
+ let itemText = selectedKey != null ? (_collection_getItem_textValue2 = (_collection_getItem2 = collection.getItem(selectedKey)) === null || _collection_getItem2 === void 0 ? void 0 : _collection_getItem2.textValue) !== null && _collection_getItem_textValue2 !== void 0 ? _collection_getItem_textValue2 : "" : "";
255
+ setLastValue(itemText);
256
+ closeMenu();
257
+ } else {
258
+ resetInputValue();
259
+ closeMenu();
260
+ }
261
+ };
262
+ const commitValue = () => {
263
+ if (allowsCustomValue) {
264
+ var _collection_getItem2;
265
+ var _collection_getItem_textValue2;
266
+ const itemText = selectedKey != null ? (_collection_getItem_textValue2 = (_collection_getItem2 = collection.getItem(selectedKey)) === null || _collection_getItem2 === void 0 ? void 0 : _collection_getItem2.textValue) !== null && _collection_getItem_textValue2 !== void 0 ? _collection_getItem_textValue2 : "" : "";
267
+ inputValue === itemText ? commitSelection() : commitCustomValue();
268
+ } else
269
+ commitSelection();
270
+ };
271
+ let commit = () => {
272
+ if (triggerState.isOpen && selectionManager.focusedKey != null) {
273
+ if (selectedKey === selectionManager.focusedKey) commitSelection();
274
+ else setSelectedKey(selectionManager.focusedKey);
275
+ } else commitValue();
276
+ };
277
+ let valueOnFocus = React.useRef(inputValue);
278
+ let setFocused = (isFocused2) => {
279
+ if (isFocused2) {
280
+ valueOnFocus.current = inputValue;
281
+ if (menuTrigger === "focus" && !props.isReadOnly) open(null, "focus");
282
+ } else {
283
+ if (shouldCloseOnBlur) commitValue();
284
+ if (inputValue !== valueOnFocus.current) validation.commitValidation();
285
+ }
286
+ setFocusedState(isFocused2);
287
+ };
288
+ let displayedCollection = React.useMemo(() => {
289
+ if (triggerState.isOpen) {
290
+ if (showAllItems) return originalCollection;
291
+ else return filteredCollection;
292
+ } else return lastCollection;
293
+ }, [
294
+ triggerState.isOpen,
295
+ originalCollection,
296
+ filteredCollection,
297
+ showAllItems,
298
+ lastCollection
299
+ ]);
300
+ return __spreadProps(__spreadValues(__spreadValues({}, validation), triggerState), {
301
+ focusStrategy,
302
+ toggle,
303
+ open,
304
+ close: commitValue,
305
+ selectionManager,
306
+ selectedKey,
307
+ setSelectedKey,
308
+ disabledKeys,
309
+ isFocused,
310
+ setFocused,
311
+ selectedItem,
312
+ collection: displayedCollection,
313
+ inputValue,
314
+ setInputValue,
315
+ commit,
316
+ revert
317
+ });
318
+ }
319
+ function $a9e7382a7d111cb5$var$filterCollection(collection, inputValue, filter) {
320
+ return new useListState.$a02d57049d202695$export$d085fb9e920b5ca7($a9e7382a7d111cb5$var$filterNodes(collection, collection, inputValue, filter));
321
+ }
322
+ function $a9e7382a7d111cb5$var$filterNodes(collection, nodes, inputValue, filter) {
323
+ let filteredNode = [];
324
+ for (let node of nodes) {
325
+ if (node.type === "section" && node.hasChildNodes) {
326
+ let filtered = $a9e7382a7d111cb5$var$filterNodes(collection, SelectionManager.$c5a24bc478652b5f$export$1005530eda016c13(node, collection), inputValue, filter);
327
+ if ([
328
+ ...filtered
329
+ ].some((node2) => node2.type === "item")) filteredNode.push(__spreadProps(__spreadValues({}, node), {
330
+ childNodes: filtered
331
+ }));
332
+ } else if (node.type === "item" && filter(node.textValue, inputValue)) filteredNode.push(__spreadValues({}, node));
333
+ else if (node.type !== "item") filteredNode.push(__spreadValues({}, node));
334
+ }
335
+ return filteredNode;
336
+ }
337
+ function $f86e6c1ec7da6ebb$var$reducer(data, action) {
338
+ let selectedKeys;
339
+ switch (data.state) {
340
+ case "idle":
341
+ case "error":
342
+ switch (action.type) {
343
+ case "loading":
344
+ case "loadingMore":
345
+ case "sorting":
346
+ case "filtering":
347
+ var _action_filterText, _action_sortDescriptor;
348
+ return __spreadProps(__spreadValues({}, data), {
349
+ filterText: (_action_filterText = action.filterText) !== null && _action_filterText !== void 0 ? _action_filterText : data.filterText,
350
+ state: action.type,
351
+ // Reset items to an empty list if loading, but not when sorting.
352
+ items: action.type === "loading" ? [] : data.items,
353
+ sortDescriptor: (_action_sortDescriptor = action.sortDescriptor) !== null && _action_sortDescriptor !== void 0 ? _action_sortDescriptor : data.sortDescriptor,
354
+ abortController: action.abortController
355
+ });
356
+ case "update":
357
+ var _action_updater;
358
+ return __spreadValues(__spreadValues({}, data), (_action_updater = action.updater) === null || _action_updater === void 0 ? void 0 : _action_updater.call(action, data));
359
+ case "success":
360
+ case "error":
361
+ return data;
362
+ default:
363
+ throw new Error(`Invalid action "${action.type}" in state "${data.state}"`);
364
+ }
365
+ case "loading":
366
+ case "sorting":
367
+ case "filtering":
368
+ switch (action.type) {
369
+ case "success":
370
+ if (action.abortController !== data.abortController) return data;
371
+ var _action_selectedKeys;
372
+ selectedKeys = (_action_selectedKeys = action.selectedKeys) !== null && _action_selectedKeys !== void 0 ? _action_selectedKeys : data.selectedKeys;
373
+ var _action_filterText1, _action_items, _action_sortDescriptor1;
374
+ return __spreadProps(__spreadValues({}, data), {
375
+ filterText: (_action_filterText1 = action.filterText) !== null && _action_filterText1 !== void 0 ? _action_filterText1 : data.filterText,
376
+ state: "idle",
377
+ items: [
378
+ ...(_action_items = action.items) !== null && _action_items !== void 0 ? _action_items : []
379
+ ],
380
+ selectedKeys: selectedKeys === "all" ? "all" : new Set(selectedKeys),
381
+ sortDescriptor: (_action_sortDescriptor1 = action.sortDescriptor) !== null && _action_sortDescriptor1 !== void 0 ? _action_sortDescriptor1 : data.sortDescriptor,
382
+ abortController: void 0,
383
+ cursor: action.cursor
384
+ });
385
+ case "error":
386
+ if (action.abortController !== data.abortController) return data;
387
+ return __spreadProps(__spreadValues({}, data), {
388
+ state: "error",
389
+ error: action.error,
390
+ abortController: void 0
391
+ });
392
+ case "loading":
393
+ case "loadingMore":
394
+ case "sorting":
395
+ case "filtering":
396
+ var _data_abortController;
397
+ (_data_abortController = data.abortController) === null || _data_abortController === void 0 ? void 0 : _data_abortController.abort();
398
+ var _action_filterText2;
399
+ return __spreadProps(__spreadValues({}, data), {
400
+ filterText: (_action_filterText2 = action.filterText) !== null && _action_filterText2 !== void 0 ? _action_filterText2 : data.filterText,
401
+ state: action.type,
402
+ // Reset items to an empty list if loading, but not when sorting.
403
+ items: action.type === "loading" ? [] : data.items,
404
+ abortController: action.abortController
405
+ });
406
+ case "update":
407
+ var _action_updater1;
408
+ return __spreadValues(__spreadValues({}, data), (_action_updater1 = action.updater) === null || _action_updater1 === void 0 ? void 0 : _action_updater1.call(action, data));
409
+ default:
410
+ throw new Error(`Invalid action "${action.type}" in state "${data.state}"`);
411
+ }
412
+ case "loadingMore":
413
+ switch (action.type) {
414
+ case "success":
415
+ var _action_selectedKeys1;
416
+ selectedKeys = data.selectedKeys === "all" || action.selectedKeys === "all" ? "all" : /* @__PURE__ */ new Set([
417
+ ...data.selectedKeys,
418
+ ...(_action_selectedKeys1 = action.selectedKeys) !== null && _action_selectedKeys1 !== void 0 ? _action_selectedKeys1 : []
419
+ ]);
420
+ var _action_items1, _action_sortDescriptor2;
421
+ return __spreadProps(__spreadValues({}, data), {
422
+ state: "idle",
423
+ items: [
424
+ ...data.items,
425
+ ...(_action_items1 = action.items) !== null && _action_items1 !== void 0 ? _action_items1 : []
426
+ ],
427
+ selectedKeys,
428
+ sortDescriptor: (_action_sortDescriptor2 = action.sortDescriptor) !== null && _action_sortDescriptor2 !== void 0 ? _action_sortDescriptor2 : data.sortDescriptor,
429
+ abortController: void 0,
430
+ cursor: action.cursor
431
+ });
432
+ case "error":
433
+ if (action.abortController !== data.abortController) return data;
434
+ return __spreadProps(__spreadValues({}, data), {
435
+ state: "error",
436
+ error: action.error
437
+ });
438
+ case "loading":
439
+ case "sorting":
440
+ case "filtering":
441
+ var _data_abortController1;
442
+ (_data_abortController1 = data.abortController) === null || _data_abortController1 === void 0 ? void 0 : _data_abortController1.abort();
443
+ var _action_filterText3;
444
+ return __spreadProps(__spreadValues({}, data), {
445
+ filterText: (_action_filterText3 = action.filterText) !== null && _action_filterText3 !== void 0 ? _action_filterText3 : data.filterText,
446
+ state: action.type,
447
+ // Reset items to an empty list if loading, but not when sorting.
448
+ items: action.type === "loading" ? [] : data.items,
449
+ abortController: action.abortController
450
+ });
451
+ case "loadingMore":
452
+ var _action_abortController;
453
+ (_action_abortController = action.abortController) === null || _action_abortController === void 0 ? void 0 : _action_abortController.abort();
454
+ return data;
455
+ case "update":
456
+ var _action_updater2;
457
+ return __spreadValues(__spreadValues({}, data), (_action_updater2 = action.updater) === null || _action_updater2 === void 0 ? void 0 : _action_updater2.call(action, data));
458
+ default:
459
+ throw new Error(`Invalid action "${action.type}" in state "${data.state}"`);
460
+ }
461
+ default:
462
+ throw new Error(`Invalid state "${data.state}"`);
463
+ }
464
+ }
465
+ function $f86e6c1ec7da6ebb$export$bc3384a35de93d66(options) {
466
+ const { load, sort, initialSelectedKeys, initialSortDescriptor, getKey = (item) => item.id || item.key, initialFilterText = "" } = options;
467
+ let [data, dispatch] = React.useReducer($f86e6c1ec7da6ebb$var$reducer, {
468
+ state: "idle",
469
+ error: void 0,
470
+ items: [],
471
+ selectedKeys: initialSelectedKeys === "all" ? "all" : new Set(initialSelectedKeys),
472
+ sortDescriptor: initialSortDescriptor,
473
+ filterText: initialFilterText
474
+ });
475
+ const dispatchFetch = (action, fn) => __async(this, null, function* () {
476
+ let abortController = new AbortController();
477
+ try {
478
+ dispatch(__spreadProps(__spreadValues({}, action), {
479
+ abortController
480
+ }));
481
+ var _action_filterText;
482
+ let previousFilterText = (_action_filterText = action.filterText) !== null && _action_filterText !== void 0 ? _action_filterText : data.filterText;
483
+ var _action_sortDescriptor;
484
+ let response = yield fn({
485
+ items: data.items.slice(),
486
+ selectedKeys: data.selectedKeys,
487
+ sortDescriptor: (_action_sortDescriptor = action.sortDescriptor) !== null && _action_sortDescriptor !== void 0 ? _action_sortDescriptor : data.sortDescriptor,
488
+ signal: abortController.signal,
489
+ cursor: action.type === "loadingMore" ? data.cursor : void 0,
490
+ filterText: previousFilterText
491
+ });
492
+ var _response_filterText;
493
+ let filterText = (_response_filterText = response.filterText) !== null && _response_filterText !== void 0 ? _response_filterText : previousFilterText;
494
+ dispatch(__spreadProps(__spreadValues({
495
+ type: "success"
496
+ }, response), {
497
+ abortController
498
+ }));
499
+ if (filterText && filterText !== previousFilterText && !abortController.signal.aborted) dispatchFetch({
500
+ type: "filtering",
501
+ filterText
502
+ }, load);
503
+ } catch (e) {
504
+ dispatch({
505
+ type: "error",
506
+ error: e,
507
+ abortController
508
+ });
509
+ }
510
+ });
511
+ let didDispatchInitialFetch = React.useRef(false);
512
+ React.useEffect(() => {
513
+ if (!didDispatchInitialFetch.current) {
514
+ dispatchFetch({
515
+ type: "loading"
516
+ }, load);
517
+ didDispatchInitialFetch.current = true;
518
+ }
519
+ }, []);
520
+ return __spreadProps(__spreadValues({
521
+ items: data.items,
522
+ selectedKeys: data.selectedKeys,
523
+ sortDescriptor: data.sortDescriptor,
524
+ isLoading: data.state === "loading" || data.state === "loadingMore" || data.state === "sorting" || data.state === "filtering",
525
+ loadingState: data.state,
526
+ error: data.error,
527
+ filterText: data.filterText,
528
+ getItem(key) {
529
+ return data.items.find((item) => getKey(item) === key);
530
+ },
531
+ reload() {
532
+ dispatchFetch({
533
+ type: "loading"
534
+ }, load);
535
+ },
536
+ loadMore() {
537
+ if (data.state === "loadingMore" || data.state === "filtering" || data.cursor == null) return;
538
+ dispatchFetch({
539
+ type: "loadingMore"
540
+ }, load);
541
+ },
542
+ sort(sortDescriptor) {
543
+ dispatchFetch({
544
+ type: "sorting",
545
+ sortDescriptor
546
+ }, sort || load);
547
+ }
548
+ }, PillGroup.$0d86e9c8f07f9a7b$export$79c0c687a5963b0a(__spreadProps(__spreadValues({}, options), {
549
+ getKey,
550
+ cursor: data.cursor
551
+ }), (fn) => {
552
+ dispatch({
553
+ type: "update",
554
+ updater: fn
555
+ });
556
+ })), {
557
+ setFilterText(filterText) {
558
+ dispatchFetch({
559
+ type: "filtering",
560
+ filterText
561
+ }, load);
562
+ }
563
+ });
564
+ }
565
+ var $02cb4c75c506befe$exports = {};
566
+ $02cb4c75c506befe$exports = {
567
+ "buttonLabel": `عرض المقترحات`,
568
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
569
+ one: () => `${formatter.number(args.optionCount)} خيار`,
570
+ other: () => `${formatter.number(args.optionCount)} خيارات`
571
+ })} متاحة.`,
572
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
573
+ true: () => `المجموعة المدخلة ${args.groupTitle}, مع ${formatter.plural(args.groupCount, {
574
+ one: () => `${formatter.number(args.groupCount)} خيار`,
575
+ other: () => `${formatter.number(args.groupCount)} خيارات`
576
+ })}. `,
577
+ other: ``
578
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
579
+ true: `, محدد`,
580
+ other: ``
581
+ }, args.isSelected)}`,
582
+ "listboxLabel": `مقترحات`,
583
+ "selectedAnnouncement": (args) => `${args.optionText}، محدد`
584
+ };
585
+ var $568b8163f1e56faf$exports = {};
586
+ $568b8163f1e56faf$exports = {
587
+ "buttonLabel": `Покажи предложения`,
588
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
589
+ one: () => `${formatter.number(args.optionCount)} опция`,
590
+ other: () => `${formatter.number(args.optionCount)} опции`
591
+ })} на разположение.`,
592
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
593
+ true: () => `Въведена група ${args.groupTitle}, с ${formatter.plural(args.groupCount, {
594
+ one: () => `${formatter.number(args.groupCount)} опция`,
595
+ other: () => `${formatter.number(args.groupCount)} опции`
596
+ })}. `,
597
+ other: ``
598
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
599
+ true: `, избрани`,
600
+ other: ``
601
+ }, args.isSelected)}`,
602
+ "listboxLabel": `Предложения`,
603
+ "selectedAnnouncement": (args) => `${args.optionText}, избрани`
604
+ };
605
+ var $87581c0202d106b8$exports = {};
606
+ $87581c0202d106b8$exports = {
607
+ "buttonLabel": `Zobrazit doporučení`,
608
+ "countAnnouncement": (args, formatter) => `K dispozici ${formatter.plural(args.optionCount, {
609
+ one: () => `je ${formatter.number(args.optionCount)} možnost`,
610
+ other: () => `jsou/je ${formatter.number(args.optionCount)} možnosti/-í`
611
+ })}.`,
612
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
613
+ true: () => `Zadaná skupina „${args.groupTitle}“ ${formatter.plural(args.groupCount, {
614
+ one: () => `s ${formatter.number(args.groupCount)} možností`,
615
+ other: () => `se ${formatter.number(args.groupCount)} možnostmi`
616
+ })}. `,
617
+ other: ``
618
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
619
+ true: ` (vybráno)`,
620
+ other: ``
621
+ }, args.isSelected)}`,
622
+ "listboxLabel": `Návrhy`,
623
+ "selectedAnnouncement": (args) => `${args.optionText}, vybráno`
624
+ };
625
+ var $a10a0369f5433ed1$exports = {};
626
+ $a10a0369f5433ed1$exports = {
627
+ "buttonLabel": `Vis forslag`,
628
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
629
+ one: () => `${formatter.number(args.optionCount)} mulighed tilgængelig`,
630
+ other: () => `${formatter.number(args.optionCount)} muligheder tilgængelige`
631
+ })}.`,
632
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
633
+ true: () => `Angivet gruppe ${args.groupTitle}, med ${formatter.plural(args.groupCount, {
634
+ one: () => `${formatter.number(args.groupCount)} mulighed`,
635
+ other: () => `${formatter.number(args.groupCount)} muligheder`
636
+ })}. `,
637
+ other: ``
638
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
639
+ true: `, valgt`,
640
+ other: ``
641
+ }, args.isSelected)}`,
642
+ "listboxLabel": `Forslag`,
643
+ "selectedAnnouncement": (args) => `${args.optionText}, valgt`
644
+ };
645
+ var $bfd288727d5cb166$exports = {};
646
+ $bfd288727d5cb166$exports = {
647
+ "buttonLabel": `Empfehlungen anzeigen`,
648
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
649
+ one: () => `${formatter.number(args.optionCount)} Option`,
650
+ other: () => `${formatter.number(args.optionCount)} Optionen`
651
+ })} verfügbar.`,
652
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
653
+ true: () => `Eingetretene Gruppe ${args.groupTitle}, mit ${formatter.plural(args.groupCount, {
654
+ one: () => `${formatter.number(args.groupCount)} Option`,
655
+ other: () => `${formatter.number(args.groupCount)} Optionen`
656
+ })}. `,
657
+ other: ``
658
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
659
+ true: `, ausgewählt`,
660
+ other: ``
661
+ }, args.isSelected)}`,
662
+ "listboxLabel": `Empfehlungen`,
663
+ "selectedAnnouncement": (args) => `${args.optionText}, ausgewählt`
664
+ };
665
+ var $ca177778f9a74e3c$exports = {};
666
+ $ca177778f9a74e3c$exports = {
667
+ "buttonLabel": `Προβολή προτάσεων`,
668
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
669
+ one: () => `${formatter.number(args.optionCount)} επιλογή`,
670
+ other: () => `${formatter.number(args.optionCount)} επιλογές `
671
+ })} διαθέσιμες.`,
672
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
673
+ true: () => `Εισαγμένη ομάδα ${args.groupTitle}, με ${formatter.plural(args.groupCount, {
674
+ one: () => `${formatter.number(args.groupCount)} επιλογή`,
675
+ other: () => `${formatter.number(args.groupCount)} επιλογές`
676
+ })}. `,
677
+ other: ``
678
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
679
+ true: `, επιλεγμένο`,
680
+ other: ``
681
+ }, args.isSelected)}`,
682
+ "listboxLabel": `Προτάσεις`,
683
+ "selectedAnnouncement": (args) => `${args.optionText}, επιλέχθηκε`
684
+ };
685
+ var $9b5aa79ef84beb6c$exports = {};
686
+ $9b5aa79ef84beb6c$exports = {
687
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
688
+ true: () => `Entered group ${args.groupTitle}, with ${formatter.plural(args.groupCount, {
689
+ one: () => `${formatter.number(args.groupCount)} option`,
690
+ other: () => `${formatter.number(args.groupCount)} options`
691
+ })}. `,
692
+ other: ``
693
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
694
+ true: `, selected`,
695
+ other: ``
696
+ }, args.isSelected)}`,
697
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
698
+ one: () => `${formatter.number(args.optionCount)} option`,
699
+ other: () => `${formatter.number(args.optionCount)} options`
700
+ })} available.`,
701
+ "selectedAnnouncement": (args) => `${args.optionText}, selected`,
702
+ "buttonLabel": `Show suggestions`,
703
+ "listboxLabel": `Suggestions`
704
+ };
705
+ var $57968e8209de2557$exports = {};
706
+ $57968e8209de2557$exports = {
707
+ "buttonLabel": `Mostrar sugerencias`,
708
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
709
+ one: () => `${formatter.number(args.optionCount)} opción`,
710
+ other: () => `${formatter.number(args.optionCount)} opciones`
711
+ })} disponible(s).`,
712
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
713
+ true: () => `Se ha unido al grupo ${args.groupTitle}, con ${formatter.plural(args.groupCount, {
714
+ one: () => `${formatter.number(args.groupCount)} opción`,
715
+ other: () => `${formatter.number(args.groupCount)} opciones`
716
+ })}. `,
717
+ other: ``
718
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
719
+ true: `, seleccionado`,
720
+ other: ``
721
+ }, args.isSelected)}`,
722
+ "listboxLabel": `Sugerencias`,
723
+ "selectedAnnouncement": (args) => `${args.optionText}, seleccionado`
724
+ };
725
+ var $60690790bf4c1c6a$exports = {};
726
+ $60690790bf4c1c6a$exports = {
727
+ "buttonLabel": `Kuva soovitused`,
728
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
729
+ one: () => `${formatter.number(args.optionCount)} valik`,
730
+ other: () => `${formatter.number(args.optionCount)} valikud`
731
+ })} saadaval.`,
732
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
733
+ true: () => `Sisestatud rühm ${args.groupTitle}, valikuga ${formatter.plural(args.groupCount, {
734
+ one: () => `${formatter.number(args.groupCount)} valik`,
735
+ other: () => `${formatter.number(args.groupCount)} valikud`
736
+ })}. `,
737
+ other: ``
738
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
739
+ true: `, valitud`,
740
+ other: ``
741
+ }, args.isSelected)}`,
742
+ "listboxLabel": `Soovitused`,
743
+ "selectedAnnouncement": (args) => `${args.optionText}, valitud`
744
+ };
745
+ var $1101246e8c7d9357$exports = {};
746
+ $1101246e8c7d9357$exports = {
747
+ "buttonLabel": `Näytä ehdotukset`,
748
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
749
+ one: () => `${formatter.number(args.optionCount)} vaihtoehto`,
750
+ other: () => `${formatter.number(args.optionCount)} vaihtoehdot`
751
+ })} saatavilla.`,
752
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
753
+ true: () => `Mentiin ryhmään ${args.groupTitle}, ${formatter.plural(args.groupCount, {
754
+ one: () => `${formatter.number(args.groupCount)} vaihtoehdon`,
755
+ other: () => `${formatter.number(args.groupCount)} vaihtoehdon`
756
+ })} kanssa.`,
757
+ other: ``
758
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
759
+ true: `, valittu`,
760
+ other: ``
761
+ }, args.isSelected)}`,
762
+ "listboxLabel": `Ehdotukset`,
763
+ "selectedAnnouncement": (args) => `${args.optionText}, valittu`
764
+ };
765
+ var $6404b5cb5b241730$exports = {};
766
+ $6404b5cb5b241730$exports = {
767
+ "buttonLabel": `Afficher les suggestions`,
768
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
769
+ one: () => `${formatter.number(args.optionCount)} option`,
770
+ other: () => `${formatter.number(args.optionCount)} options`
771
+ })} disponible(s).`,
772
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
773
+ true: () => `Groupe ${args.groupTitle} rejoint, avec ${formatter.plural(args.groupCount, {
774
+ one: () => `${formatter.number(args.groupCount)} option`,
775
+ other: () => `${formatter.number(args.groupCount)} options`
776
+ })}. `,
777
+ other: ``
778
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
779
+ true: `, sélectionné(s)`,
780
+ other: ``
781
+ }, args.isSelected)}`,
782
+ "listboxLabel": `Suggestions`,
783
+ "selectedAnnouncement": (args) => `${args.optionText}, sélectionné`
784
+ };
785
+ var $dfeafa702e92e31f$exports = {};
786
+ $dfeafa702e92e31f$exports = {
787
+ "buttonLabel": `הצג הצעות`,
788
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
789
+ one: () => `אפשרות ${formatter.number(args.optionCount)}`,
790
+ other: () => `${formatter.number(args.optionCount)} אפשרויות`
791
+ })} במצב זמין.`,
792
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
793
+ true: () => `נכנס לקבוצה ${args.groupTitle}, עם ${formatter.plural(args.groupCount, {
794
+ one: () => `אפשרות ${formatter.number(args.groupCount)}`,
795
+ other: () => `${formatter.number(args.groupCount)} אפשרויות`
796
+ })}. `,
797
+ other: ``
798
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
799
+ true: `, נבחר`,
800
+ other: ``
801
+ }, args.isSelected)}`,
802
+ "listboxLabel": `הצעות`,
803
+ "selectedAnnouncement": (args) => `${args.optionText}, נבחר`
804
+ };
805
+ var $2d125e0b34676352$exports = {};
806
+ $2d125e0b34676352$exports = {
807
+ "buttonLabel": `Prikaži prijedloge`,
808
+ "countAnnouncement": (args, formatter) => `Dostupno još: ${formatter.plural(args.optionCount, {
809
+ one: () => `${formatter.number(args.optionCount)} opcija`,
810
+ other: () => `${formatter.number(args.optionCount)} opcije/a`
811
+ })}.`,
812
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
813
+ true: () => `Unesena skupina ${args.groupTitle}, s ${formatter.plural(args.groupCount, {
814
+ one: () => `${formatter.number(args.groupCount)} opcijom`,
815
+ other: () => `${formatter.number(args.groupCount)} opcije/a`
816
+ })}. `,
817
+ other: ``
818
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
819
+ true: `, odabranih`,
820
+ other: ``
821
+ }, args.isSelected)}`,
822
+ "listboxLabel": `Prijedlozi`,
823
+ "selectedAnnouncement": (args) => `${args.optionText}, odabrano`
824
+ };
825
+ var $ea029611d7634059$exports = {};
826
+ $ea029611d7634059$exports = {
827
+ "buttonLabel": `Javaslatok megjelenítése`,
828
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
829
+ one: () => `${formatter.number(args.optionCount)} lehetőség`,
830
+ other: () => `${formatter.number(args.optionCount)} lehetőség`
831
+ })} áll rendelkezésre.`,
832
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
833
+ true: () => `Belépett a(z) ${args.groupTitle} csoportba, amely ${formatter.plural(args.groupCount, {
834
+ one: () => `${formatter.number(args.groupCount)} lehetőséget`,
835
+ other: () => `${formatter.number(args.groupCount)} lehetőséget`
836
+ })} tartalmaz. `,
837
+ other: ``
838
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
839
+ true: `, kijelölve`,
840
+ other: ``
841
+ }, args.isSelected)}`,
842
+ "listboxLabel": `Javaslatok`,
843
+ "selectedAnnouncement": (args) => `${args.optionText}, kijelölve`
844
+ };
845
+ var $77f075bb86ad7091$exports = {};
846
+ $77f075bb86ad7091$exports = {
847
+ "buttonLabel": `Mostra suggerimenti`,
848
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
849
+ one: () => `${formatter.number(args.optionCount)} opzione disponibile`,
850
+ other: () => `${formatter.number(args.optionCount)} opzioni disponibili`
851
+ })}.`,
852
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
853
+ true: () => `Ingresso nel gruppo ${args.groupTitle}, con ${formatter.plural(args.groupCount, {
854
+ one: () => `${formatter.number(args.groupCount)} opzione`,
855
+ other: () => `${formatter.number(args.groupCount)} opzioni`
856
+ })}. `,
857
+ other: ``
858
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
859
+ true: `, selezionato`,
860
+ other: ``
861
+ }, args.isSelected)}`,
862
+ "listboxLabel": `Suggerimenti`,
863
+ "selectedAnnouncement": (args) => `${args.optionText}, selezionato`
864
+ };
865
+ var $6e87462e84907983$exports = {};
866
+ $6e87462e84907983$exports = {
867
+ "buttonLabel": `候補を表示`,
868
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
869
+ one: () => `${formatter.number(args.optionCount)} 個のオプション`,
870
+ other: () => `${formatter.number(args.optionCount)} 個のオプション`
871
+ })}を利用できます。`,
872
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
873
+ true: () => `入力されたグループ ${args.groupTitle}、${formatter.plural(args.groupCount, {
874
+ one: () => `${formatter.number(args.groupCount)} 個のオプション`,
875
+ other: () => `${formatter.number(args.groupCount)} 個のオプション`
876
+ })}を含む。`,
877
+ other: ``
878
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
879
+ true: `、選択済み`,
880
+ other: ``
881
+ }, args.isSelected)}`,
882
+ "listboxLabel": `候補`,
883
+ "selectedAnnouncement": (args) => `${args.optionText}、選択済み`
884
+ };
885
+ var $9246f2c6edc6b232$exports = {};
886
+ $9246f2c6edc6b232$exports = {
887
+ "buttonLabel": `제안 사항 표시`,
888
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
889
+ one: () => `${formatter.number(args.optionCount)}개 옵션`,
890
+ other: () => `${formatter.number(args.optionCount)}개 옵션`
891
+ })}을 사용할 수 있습니다.`,
892
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
893
+ true: () => `입력한 그룹 ${args.groupTitle}, ${formatter.plural(args.groupCount, {
894
+ one: () => `${formatter.number(args.groupCount)}개 옵션`,
895
+ other: () => `${formatter.number(args.groupCount)}개 옵션`
896
+ })}. `,
897
+ other: ``
898
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
899
+ true: `, 선택됨`,
900
+ other: ``
901
+ }, args.isSelected)}`,
902
+ "listboxLabel": `제안`,
903
+ "selectedAnnouncement": (args) => `${args.optionText}, 선택됨`
904
+ };
905
+ var $e587accc6c0a434c$exports = {};
906
+ $e587accc6c0a434c$exports = {
907
+ "buttonLabel": `Rodyti pasiūlymus`,
908
+ "countAnnouncement": (args, formatter) => `Yra ${formatter.plural(args.optionCount, {
909
+ one: () => `${formatter.number(args.optionCount)} parinktis`,
910
+ other: () => `${formatter.number(args.optionCount)} parinktys (-ių)`
911
+ })}.`,
912
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
913
+ true: () => `Įvesta grupė ${args.groupTitle}, su ${formatter.plural(args.groupCount, {
914
+ one: () => `${formatter.number(args.groupCount)} parinktimi`,
915
+ other: () => `${formatter.number(args.groupCount)} parinktimis (-ių)`
916
+ })}. `,
917
+ other: ``
918
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
919
+ true: `, pasirinkta`,
920
+ other: ``
921
+ }, args.isSelected)}`,
922
+ "listboxLabel": `Pasiūlymai`,
923
+ "selectedAnnouncement": (args) => `${args.optionText}, pasirinkta`
924
+ };
925
+ var $03a1900e7400b5ab$exports = {};
926
+ $03a1900e7400b5ab$exports = {
927
+ "buttonLabel": `Rādīt ieteikumus`,
928
+ "countAnnouncement": (args, formatter) => `Pieejamo opciju skaits: ${formatter.plural(args.optionCount, {
929
+ one: () => `${formatter.number(args.optionCount)} opcija`,
930
+ other: () => `${formatter.number(args.optionCount)} opcijas`
931
+ })}.`,
932
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
933
+ true: () => `Ievadīta grupa ${args.groupTitle}, ar ${formatter.plural(args.groupCount, {
934
+ one: () => `${formatter.number(args.groupCount)} opciju`,
935
+ other: () => `${formatter.number(args.groupCount)} opcijām`
936
+ })}. `,
937
+ other: ``
938
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
939
+ true: `, atlasīta`,
940
+ other: ``
941
+ }, args.isSelected)}`,
942
+ "listboxLabel": `Ieteikumi`,
943
+ "selectedAnnouncement": (args) => `${args.optionText}, atlasīta`
944
+ };
945
+ var $1387676441be6cf6$exports = {};
946
+ $1387676441be6cf6$exports = {
947
+ "buttonLabel": `Vis forslag`,
948
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
949
+ one: () => `${formatter.number(args.optionCount)} alternativ`,
950
+ other: () => `${formatter.number(args.optionCount)} alternativer`
951
+ })} finnes.`,
952
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
953
+ true: () => `Angitt gruppe ${args.groupTitle}, med ${formatter.plural(args.groupCount, {
954
+ one: () => `${formatter.number(args.groupCount)} alternativ`,
955
+ other: () => `${formatter.number(args.groupCount)} alternativer`
956
+ })}. `,
957
+ other: ``
958
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
959
+ true: `, valgt`,
960
+ other: ``
961
+ }, args.isSelected)}`,
962
+ "listboxLabel": `Forslag`,
963
+ "selectedAnnouncement": (args) => `${args.optionText}, valgt`
964
+ };
965
+ var $17e82ebf0f8ab91f$exports = {};
966
+ $17e82ebf0f8ab91f$exports = {
967
+ "buttonLabel": `Suggesties weergeven`,
968
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
969
+ one: () => `${formatter.number(args.optionCount)} optie`,
970
+ other: () => `${formatter.number(args.optionCount)} opties`
971
+ })} beschikbaar.`,
972
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
973
+ true: () => `Groep ${args.groupTitle} ingevoerd met ${formatter.plural(args.groupCount, {
974
+ one: () => `${formatter.number(args.groupCount)} optie`,
975
+ other: () => `${formatter.number(args.groupCount)} opties`
976
+ })}. `,
977
+ other: ``
978
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
979
+ true: `, geselecteerd`,
980
+ other: ``
981
+ }, args.isSelected)}`,
982
+ "listboxLabel": `Suggesties`,
983
+ "selectedAnnouncement": (args) => `${args.optionText}, geselecteerd`
984
+ };
985
+ var $2f5377d3471630e5$exports = {};
986
+ $2f5377d3471630e5$exports = {
987
+ "buttonLabel": `Wyświetlaj sugestie`,
988
+ "countAnnouncement": (args, formatter) => `dostępna/dostępne(-nych) ${formatter.plural(args.optionCount, {
989
+ one: () => `${formatter.number(args.optionCount)} opcja`,
990
+ other: () => `${formatter.number(args.optionCount)} opcje(-i)`
991
+ })}.`,
992
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
993
+ true: () => `Dołączono do grupy ${args.groupTitle}, z ${formatter.plural(args.groupCount, {
994
+ one: () => `${formatter.number(args.groupCount)} opcją`,
995
+ other: () => `${formatter.number(args.groupCount)} opcjami`
996
+ })}. `,
997
+ other: ``
998
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
999
+ true: `, wybrano`,
1000
+ other: ``
1001
+ }, args.isSelected)}`,
1002
+ "listboxLabel": `Sugestie`,
1003
+ "selectedAnnouncement": (args) => `${args.optionText}, wybrano`
1004
+ };
1005
+ var $dee9868b6fa95ffe$exports = {};
1006
+ $dee9868b6fa95ffe$exports = {
1007
+ "buttonLabel": `Mostrar sugestões`,
1008
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1009
+ one: () => `${formatter.number(args.optionCount)} opção`,
1010
+ other: () => `${formatter.number(args.optionCount)} opções`
1011
+ })} disponível.`,
1012
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1013
+ true: () => `Grupo inserido ${args.groupTitle}, com ${formatter.plural(args.groupCount, {
1014
+ one: () => `${formatter.number(args.groupCount)} opção`,
1015
+ other: () => `${formatter.number(args.groupCount)} opções`
1016
+ })}. `,
1017
+ other: ``
1018
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1019
+ true: `, selecionado`,
1020
+ other: ``
1021
+ }, args.isSelected)}`,
1022
+ "listboxLabel": `Sugestões`,
1023
+ "selectedAnnouncement": (args) => `${args.optionText}, selecionado`
1024
+ };
1025
+ var $f8b2e63637cbb5a6$exports = {};
1026
+ $f8b2e63637cbb5a6$exports = {
1027
+ "buttonLabel": `Apresentar sugestões`,
1028
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1029
+ one: () => `${formatter.number(args.optionCount)} opção`,
1030
+ other: () => `${formatter.number(args.optionCount)} opções`
1031
+ })} disponível.`,
1032
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1033
+ true: () => `Grupo introduzido ${args.groupTitle}, com ${formatter.plural(args.groupCount, {
1034
+ one: () => `${formatter.number(args.groupCount)} opção`,
1035
+ other: () => `${formatter.number(args.groupCount)} opções`
1036
+ })}. `,
1037
+ other: ``
1038
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1039
+ true: `, selecionado`,
1040
+ other: ``
1041
+ }, args.isSelected)}`,
1042
+ "listboxLabel": `Sugestões`,
1043
+ "selectedAnnouncement": (args) => `${args.optionText}, selecionado`
1044
+ };
1045
+ var $46a885db3b44ea95$exports = {};
1046
+ $46a885db3b44ea95$exports = {
1047
+ "buttonLabel": `Afișare sugestii`,
1048
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1049
+ one: () => `${formatter.number(args.optionCount)} opțiune`,
1050
+ other: () => `${formatter.number(args.optionCount)} opțiuni`
1051
+ })} disponibile.`,
1052
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1053
+ true: () => `Grup ${args.groupTitle} introdus, cu ${formatter.plural(args.groupCount, {
1054
+ one: () => `${formatter.number(args.groupCount)} opțiune`,
1055
+ other: () => `${formatter.number(args.groupCount)} opțiuni`
1056
+ })}. `,
1057
+ other: ``
1058
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1059
+ true: `, selectat`,
1060
+ other: ``
1061
+ }, args.isSelected)}`,
1062
+ "listboxLabel": `Sugestii`,
1063
+ "selectedAnnouncement": (args) => `${args.optionText}, selectat`
1064
+ };
1065
+ var $50d8a8f0afa9dee5$exports = {};
1066
+ $50d8a8f0afa9dee5$exports = {
1067
+ "buttonLabel": `Показать предложения`,
1068
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1069
+ one: () => `${formatter.number(args.optionCount)} параметр`,
1070
+ other: () => `${formatter.number(args.optionCount)} параметров`
1071
+ })} доступно.`,
1072
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1073
+ true: () => `Введенная группа ${args.groupTitle}, с ${formatter.plural(args.groupCount, {
1074
+ one: () => `${formatter.number(args.groupCount)} параметром`,
1075
+ other: () => `${formatter.number(args.groupCount)} параметрами`
1076
+ })}. `,
1077
+ other: ``
1078
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1079
+ true: `, выбранными`,
1080
+ other: ``
1081
+ }, args.isSelected)}`,
1082
+ "listboxLabel": `Предложения`,
1083
+ "selectedAnnouncement": (args) => `${args.optionText}, выбрано`
1084
+ };
1085
+ var $2867ee6173245507$exports = {};
1086
+ $2867ee6173245507$exports = {
1087
+ "buttonLabel": `Zobraziť návrhy`,
1088
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1089
+ one: () => `${formatter.number(args.optionCount)} možnosť`,
1090
+ other: () => `${formatter.number(args.optionCount)} možnosti/-í`
1091
+ })} k dispozícii.`,
1092
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1093
+ true: () => `Zadaná skupina ${args.groupTitle}, s ${formatter.plural(args.groupCount, {
1094
+ one: () => `${formatter.number(args.groupCount)} možnosťou`,
1095
+ other: () => `${formatter.number(args.groupCount)} možnosťami`
1096
+ })}. `,
1097
+ other: ``
1098
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1099
+ true: `, vybraté`,
1100
+ other: ``
1101
+ }, args.isSelected)}`,
1102
+ "listboxLabel": `Návrhy`,
1103
+ "selectedAnnouncement": (args) => `${args.optionText}, vybraté`
1104
+ };
1105
+ var $0631b65beeb09b50$exports = {};
1106
+ $0631b65beeb09b50$exports = {
1107
+ "buttonLabel": `Prikaži predloge`,
1108
+ "countAnnouncement": (args, formatter) => `Na voljo je ${formatter.plural(args.optionCount, {
1109
+ one: () => `${formatter.number(args.optionCount)} opcija`,
1110
+ other: () => `${formatter.number(args.optionCount)} opcije`
1111
+ })}.`,
1112
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1113
+ true: () => `Vnesena skupina ${args.groupTitle}, z ${formatter.plural(args.groupCount, {
1114
+ one: () => `${formatter.number(args.groupCount)} opcija`,
1115
+ other: () => `${formatter.number(args.groupCount)} opcije`
1116
+ })}. `,
1117
+ other: ``
1118
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1119
+ true: `, izbrano`,
1120
+ other: ``
1121
+ }, args.isSelected)}`,
1122
+ "listboxLabel": `Predlogi`,
1123
+ "selectedAnnouncement": (args) => `${args.optionText}, izbrano`
1124
+ };
1125
+ var $65fc749265dcd686$exports = {};
1126
+ $65fc749265dcd686$exports = {
1127
+ "buttonLabel": `Prikaži predloge`,
1128
+ "countAnnouncement": (args, formatter) => `Dostupno još: ${formatter.plural(args.optionCount, {
1129
+ one: () => `${formatter.number(args.optionCount)} opcija`,
1130
+ other: () => `${formatter.number(args.optionCount)} opcije/a`
1131
+ })}.`,
1132
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1133
+ true: () => `Unesena grupa ${args.groupTitle}, s ${formatter.plural(args.groupCount, {
1134
+ one: () => `${formatter.number(args.groupCount)} opcijom`,
1135
+ other: () => `${formatter.number(args.groupCount)} optione/a`
1136
+ })}. `,
1137
+ other: ``
1138
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1139
+ true: `, izabranih`,
1140
+ other: ``
1141
+ }, args.isSelected)}`,
1142
+ "listboxLabel": `Predlozi`,
1143
+ "selectedAnnouncement": (args) => `${args.optionText}, izabrano`
1144
+ };
1145
+ var $69ba655c7853c08e$exports = {};
1146
+ $69ba655c7853c08e$exports = {
1147
+ "buttonLabel": `Visa förslag`,
1148
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1149
+ one: () => `${formatter.number(args.optionCount)} alternativ`,
1150
+ other: () => `${formatter.number(args.optionCount)} alternativ`
1151
+ })} tillgängliga.`,
1152
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1153
+ true: () => `Ingick i gruppen ${args.groupTitle} med ${formatter.plural(args.groupCount, {
1154
+ one: () => `${formatter.number(args.groupCount)} alternativ`,
1155
+ other: () => `${formatter.number(args.groupCount)} alternativ`
1156
+ })}. `,
1157
+ other: ``
1158
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1159
+ true: `, valda`,
1160
+ other: ``
1161
+ }, args.isSelected)}`,
1162
+ "listboxLabel": `Förslag`,
1163
+ "selectedAnnouncement": (args) => `${args.optionText}, valda`
1164
+ };
1165
+ var $a79794784d61577c$exports = {};
1166
+ $a79794784d61577c$exports = {
1167
+ "buttonLabel": `Önerileri göster`,
1168
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1169
+ one: () => `${formatter.number(args.optionCount)} seçenek`,
1170
+ other: () => `${formatter.number(args.optionCount)} seçenekler`
1171
+ })} kullanılabilir.`,
1172
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1173
+ true: () => `Girilen grup ${args.groupTitle}, ile ${formatter.plural(args.groupCount, {
1174
+ one: () => `${formatter.number(args.groupCount)} seçenek`,
1175
+ other: () => `${formatter.number(args.groupCount)} seçenekler`
1176
+ })}. `,
1177
+ other: ``
1178
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1179
+ true: `, seçildi`,
1180
+ other: ``
1181
+ }, args.isSelected)}`,
1182
+ "listboxLabel": `Öneriler`,
1183
+ "selectedAnnouncement": (args) => `${args.optionText}, seçildi`
1184
+ };
1185
+ var $c2845791417ebaf4$exports = {};
1186
+ $c2845791417ebaf4$exports = {
1187
+ "buttonLabel": `Показати пропозиції`,
1188
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1189
+ one: () => `${formatter.number(args.optionCount)} параметр`,
1190
+ other: () => `${formatter.number(args.optionCount)} параметри(-ів)`
1191
+ })} доступно.`,
1192
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1193
+ true: () => `Введена група ${args.groupTitle}, з ${formatter.plural(args.groupCount, {
1194
+ one: () => `${formatter.number(args.groupCount)} параметр`,
1195
+ other: () => `${formatter.number(args.groupCount)} параметри(-ів)`
1196
+ })}. `,
1197
+ other: ``
1198
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1199
+ true: `, вибрано`,
1200
+ other: ``
1201
+ }, args.isSelected)}`,
1202
+ "listboxLabel": `Пропозиції`,
1203
+ "selectedAnnouncement": (args) => `${args.optionText}, вибрано`
1204
+ };
1205
+ var $29b642d0025cc7a4$exports = {};
1206
+ $29b642d0025cc7a4$exports = {
1207
+ "buttonLabel": `显示建议`,
1208
+ "countAnnouncement": (args, formatter) => `有 ${formatter.plural(args.optionCount, {
1209
+ one: () => `${formatter.number(args.optionCount)} 个选项`,
1210
+ other: () => `${formatter.number(args.optionCount)} 个选项`
1211
+ })}可用。`,
1212
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1213
+ true: () => `进入了 ${args.groupTitle} 组,其中有 ${formatter.plural(args.groupCount, {
1214
+ one: () => `${formatter.number(args.groupCount)} 个选项`,
1215
+ other: () => `${formatter.number(args.groupCount)} 个选项`
1216
+ })}. `,
1217
+ other: ``
1218
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1219
+ true: `, 已选择`,
1220
+ other: ``
1221
+ }, args.isSelected)}`,
1222
+ "listboxLabel": `建议`,
1223
+ "selectedAnnouncement": (args) => `${args.optionText}, 已选择`
1224
+ };
1225
+ var $cd36dd33f9d46936$exports = {};
1226
+ $cd36dd33f9d46936$exports = {
1227
+ "buttonLabel": `顯示建議`,
1228
+ "countAnnouncement": (args, formatter) => `${formatter.plural(args.optionCount, {
1229
+ one: () => `${formatter.number(args.optionCount)} 選項`,
1230
+ other: () => `${formatter.number(args.optionCount)} 選項`
1231
+ })} 可用。`,
1232
+ "focusAnnouncement": (args, formatter) => `${formatter.select({
1233
+ true: () => `輸入的群組 ${args.groupTitle}, 有 ${formatter.plural(args.groupCount, {
1234
+ one: () => `${formatter.number(args.groupCount)} 選項`,
1235
+ other: () => `${formatter.number(args.groupCount)} 選項`
1236
+ })}. `,
1237
+ other: ``
1238
+ }, args.isGroupChange)}${args.optionText}${formatter.select({
1239
+ true: `, 已選取`,
1240
+ other: ``
1241
+ }, args.isSelected)}`,
1242
+ "listboxLabel": `建議`,
1243
+ "selectedAnnouncement": (args) => `${args.optionText}, 已選取`
1244
+ };
1245
+ var $de5926a92e8ebc5b$exports = {};
1246
+ $de5926a92e8ebc5b$exports = {
1247
+ "ar-AE": $02cb4c75c506befe$exports,
1248
+ "bg-BG": $568b8163f1e56faf$exports,
1249
+ "cs-CZ": $87581c0202d106b8$exports,
1250
+ "da-DK": $a10a0369f5433ed1$exports,
1251
+ "de-DE": $bfd288727d5cb166$exports,
1252
+ "el-GR": $ca177778f9a74e3c$exports,
1253
+ "en-US": $9b5aa79ef84beb6c$exports,
1254
+ "es-ES": $57968e8209de2557$exports,
1255
+ "et-EE": $60690790bf4c1c6a$exports,
1256
+ "fi-FI": $1101246e8c7d9357$exports,
1257
+ "fr-FR": $6404b5cb5b241730$exports,
1258
+ "he-IL": $dfeafa702e92e31f$exports,
1259
+ "hr-HR": $2d125e0b34676352$exports,
1260
+ "hu-HU": $ea029611d7634059$exports,
1261
+ "it-IT": $77f075bb86ad7091$exports,
1262
+ "ja-JP": $6e87462e84907983$exports,
1263
+ "ko-KR": $9246f2c6edc6b232$exports,
1264
+ "lt-LT": $e587accc6c0a434c$exports,
1265
+ "lv-LV": $03a1900e7400b5ab$exports,
1266
+ "nb-NO": $1387676441be6cf6$exports,
1267
+ "nl-NL": $17e82ebf0f8ab91f$exports,
1268
+ "pl-PL": $2f5377d3471630e5$exports,
1269
+ "pt-BR": $dee9868b6fa95ffe$exports,
1270
+ "pt-PT": $f8b2e63637cbb5a6$exports,
1271
+ "ro-RO": $46a885db3b44ea95$exports,
1272
+ "ru-RU": $50d8a8f0afa9dee5$exports,
1273
+ "sk-SK": $2867ee6173245507$exports,
1274
+ "sl-SI": $0631b65beeb09b50$exports,
1275
+ "sr-SP": $65fc749265dcd686$exports,
1276
+ "sv-SE": $69ba655c7853c08e$exports,
1277
+ "tr-TR": $a79794784d61577c$exports,
1278
+ "uk-UA": $c2845791417ebaf4$exports,
1279
+ "zh-CN": $29b642d0025cc7a4$exports,
1280
+ "zh-TW": $cd36dd33f9d46936$exports
1281
+ };
1282
+ function $parcel$interopDefault(a) {
1283
+ return a && a.__esModule ? a.default : a;
1284
+ }
1285
+ function $c350ade66beef0af$export$8c18d1b4f7232bbf(props, state) {
1286
+ let { buttonRef, popoverRef, inputRef, listBoxRef, keyboardDelegate, layoutDelegate, shouldFocusWrap, isReadOnly, isDisabled } = props;
1287
+ let backupBtnRef = React.useRef(null);
1288
+ buttonRef = buttonRef !== null && buttonRef !== void 0 ? buttonRef : backupBtnRef;
1289
+ let stringFormatter = useLocalizedStringFormatter.$fca6afa0e843324b$export$f12b703ca79dfbb1($parcel$interopDefault($de5926a92e8ebc5b$exports), "@react-aria/combobox");
1290
+ let { menuTriggerProps, menuProps } = useMenuTrigger.$168583247155ddda$export$dc9c12ed27dd1b49({
1291
+ type: "listbox",
1292
+ isDisabled: isDisabled || isReadOnly
1293
+ }, state, buttonRef);
1294
+ useListBoxSection.$b1f0cad8af73213b$export$3585ede4d035bf14.set(state, {
1295
+ id: menuProps.id
1296
+ });
1297
+ let { collection } = state;
1298
+ let { disabledKeys } = state.selectionManager;
1299
+ let delegate = React.useMemo(() => keyboardDelegate || new useSelectableList.$2a25aae57d74318e$export$a05409b8bb224a5a({
1300
+ collection,
1301
+ disabledKeys,
1302
+ ref: listBoxRef,
1303
+ layoutDelegate
1304
+ }), [
1305
+ keyboardDelegate,
1306
+ layoutDelegate,
1307
+ collection,
1308
+ disabledKeys,
1309
+ listBoxRef
1310
+ ]);
1311
+ let { collectionProps } = useSelectableItem.$ae20dd8cbca75726$export$d6daf82dcd84e87c({
1312
+ selectionManager: state.selectionManager,
1313
+ keyboardDelegate: delegate,
1314
+ disallowTypeAhead: true,
1315
+ disallowEmptySelection: true,
1316
+ shouldFocusWrap,
1317
+ ref: inputRef,
1318
+ // Prevent item scroll behavior from being applied here, should be handled in the user's Popover + ListBox component
1319
+ isVirtualized: true
1320
+ });
1321
+ let router = usePress.$ea8dcbcb9ea1b556$export$9a302a45f65d0572();
1322
+ let onKeyDown = (e) => {
1323
+ if (e.nativeEvent.isComposing) return;
1324
+ switch (e.key) {
1325
+ case "Enter":
1326
+ case "Tab":
1327
+ if (state.isOpen && e.key === "Enter") e.preventDefault();
1328
+ if (state.isOpen && listBoxRef.current && state.selectionManager.focusedKey != null && state.selectionManager.isLink(state.selectionManager.focusedKey)) {
1329
+ let item = listBoxRef.current.querySelector(`[data-key="${CSS.escape(state.selectionManager.focusedKey.toString())}"]`);
1330
+ if (e.key === "Enter" && item instanceof HTMLAnchorElement) {
1331
+ let collectionItem = state.collection.getItem(state.selectionManager.focusedKey);
1332
+ if (collectionItem) router.open(item, e, collectionItem.props.href, collectionItem.props.routerOptions);
1333
+ }
1334
+ state.close();
1335
+ } else state.commit();
1336
+ break;
1337
+ case "Escape":
1338
+ if (state.selectedKey !== null || state.inputValue === "" || props.allowsCustomValue) e.continuePropagation();
1339
+ state.revert();
1340
+ break;
1341
+ case "ArrowDown":
1342
+ state.open("first", "manual");
1343
+ break;
1344
+ case "ArrowUp":
1345
+ state.open("last", "manual");
1346
+ break;
1347
+ case "ArrowLeft":
1348
+ case "ArrowRight":
1349
+ state.selectionManager.setFocusedKey(null);
1350
+ break;
1351
+ }
1352
+ };
1353
+ let onBlur = (e) => {
1354
+ var _popoverRef_current;
1355
+ let blurFromButton = (buttonRef === null || buttonRef === void 0 ? void 0 : buttonRef.current) && buttonRef.current === e.relatedTarget;
1356
+ let blurIntoPopover = (_popoverRef_current = popoverRef.current) === null || _popoverRef_current === void 0 ? void 0 : _popoverRef_current.contains(e.relatedTarget);
1357
+ if (blurFromButton || blurIntoPopover) return;
1358
+ if (props.onBlur) props.onBlur(e);
1359
+ state.setFocused(false);
1360
+ };
1361
+ let onFocus = (e) => {
1362
+ if (state.isFocused) return;
1363
+ if (props.onFocus) props.onFocus(e);
1364
+ state.setFocused(true);
1365
+ };
1366
+ let { isInvalid, validationErrors, validationDetails } = state.displayValidation;
1367
+ let { labelProps, inputProps, descriptionProps, errorMessageProps } = useTextField.$2d73ec29415bd339$export$712718f7aec83d5(__spreadProps(__spreadValues({}, props), {
1368
+ onChange: state.setInputValue,
1369
+ onKeyDown: !isReadOnly ? mergeProps.$ff5963eb1fccf552$export$e08e3b67e392101e(state.isOpen && collectionProps.onKeyDown, onKeyDown, props.onKeyDown) : props.onKeyDown,
1370
+ onBlur,
1371
+ value: state.inputValue,
1372
+ onFocus,
1373
+ autoComplete: "off",
1374
+ validate: void 0,
1375
+ [useFormValidation.$e5be200c675c3b3a$export$a763b9476acd3eb]: state
1376
+ }), inputRef);
1377
+ let onPress = (e) => {
1378
+ if (e.pointerType === "touch") {
1379
+ var _inputRef_current;
1380
+ (_inputRef_current = inputRef.current) === null || _inputRef_current === void 0 ? void 0 : _inputRef_current.focus();
1381
+ state.toggle(null, "manual");
1382
+ }
1383
+ };
1384
+ let onPressStart = (e) => {
1385
+ if (e.pointerType !== "touch") {
1386
+ var _inputRef_current;
1387
+ (_inputRef_current = inputRef.current) === null || _inputRef_current === void 0 ? void 0 : _inputRef_current.focus();
1388
+ state.toggle(e.pointerType === "keyboard" || e.pointerType === "virtual" ? "first" : null, "manual");
1389
+ }
1390
+ };
1391
+ let triggerLabelProps = useLabels.$313b98861ee5dd6c$export$d6875122194c7b44({
1392
+ id: menuTriggerProps.id,
1393
+ "aria-label": stringFormatter.format("buttonLabel"),
1394
+ "aria-labelledby": props["aria-labelledby"] || labelProps.id
1395
+ });
1396
+ let listBoxProps = useLabels.$313b98861ee5dd6c$export$d6875122194c7b44({
1397
+ id: menuProps.id,
1398
+ "aria-label": stringFormatter.format("listboxLabel"),
1399
+ "aria-labelledby": props["aria-labelledby"] || labelProps.id
1400
+ });
1401
+ let lastEventTime = React.useRef(0);
1402
+ let onTouchEnd = (e) => {
1403
+ if (isDisabled || isReadOnly) return;
1404
+ if (e.timeStamp - lastEventTime.current < 500) {
1405
+ var _inputRef_current;
1406
+ e.preventDefault();
1407
+ (_inputRef_current = inputRef.current) === null || _inputRef_current === void 0 ? void 0 : _inputRef_current.focus();
1408
+ return;
1409
+ }
1410
+ let rect = e.target.getBoundingClientRect();
1411
+ let touch = e.changedTouches[0];
1412
+ let centerX = Math.ceil(rect.left + 0.5 * rect.width);
1413
+ let centerY = Math.ceil(rect.top + 0.5 * rect.height);
1414
+ if (touch.clientX === centerX && touch.clientY === centerY) {
1415
+ var _inputRef_current1;
1416
+ e.preventDefault();
1417
+ (_inputRef_current1 = inputRef.current) === null || _inputRef_current1 === void 0 ? void 0 : _inputRef_current1.focus();
1418
+ state.toggle(null, "manual");
1419
+ lastEventTime.current = e.timeStamp;
1420
+ }
1421
+ };
1422
+ let focusedItem = state.selectionManager.focusedKey != null && state.isOpen ? state.collection.getItem(state.selectionManager.focusedKey) : void 0;
1423
+ var _focusedItem_parentKey;
1424
+ let sectionKey = (_focusedItem_parentKey = focusedItem === null || focusedItem === void 0 ? void 0 : focusedItem.parentKey) !== null && _focusedItem_parentKey !== void 0 ? _focusedItem_parentKey : null;
1425
+ var _state_selectionManager_focusedKey;
1426
+ let itemKey = (_state_selectionManager_focusedKey = state.selectionManager.focusedKey) !== null && _state_selectionManager_focusedKey !== void 0 ? _state_selectionManager_focusedKey : null;
1427
+ let lastSection = React.useRef(sectionKey);
1428
+ let lastItem = React.useRef(itemKey);
1429
+ React.useEffect(() => {
1430
+ if (isVirtualEvent.$c87311424ea30a05$export$e1865c3bedcd822b() && focusedItem != null && itemKey != null && itemKey !== lastItem.current) {
1431
+ let isSelected = state.selectionManager.isSelected(itemKey);
1432
+ let section = sectionKey != null ? state.collection.getItem(sectionKey) : null;
1433
+ let sectionTitle = (section === null || section === void 0 ? void 0 : section["aria-label"]) || (typeof (section === null || section === void 0 ? void 0 : section.rendered) === "string" ? section.rendered : "") || "";
1434
+ var _ref;
1435
+ let announcement = stringFormatter.format("focusAnnouncement", {
1436
+ isGroupChange: (_ref = section && sectionKey !== lastSection.current) !== null && _ref !== void 0 ? _ref : false,
1437
+ groupTitle: sectionTitle,
1438
+ groupCount: section ? [
1439
+ ...SelectionManager.$c5a24bc478652b5f$export$1005530eda016c13(section, state.collection)
1440
+ ].length : 0,
1441
+ optionText: focusedItem["aria-label"] || focusedItem.textValue || "",
1442
+ isSelected
1443
+ });
1444
+ LiveAnnouncer.$319e236875307eab$export$a9b970dcc4ae71a9(announcement);
1445
+ }
1446
+ lastSection.current = sectionKey;
1447
+ lastItem.current = itemKey;
1448
+ });
1449
+ let optionCount = useSelectableList.$453cc9f0df89c0a5$export$77d5aafae4e095b2(state.collection);
1450
+ let lastSize = React.useRef(optionCount);
1451
+ let lastOpen = React.useRef(state.isOpen);
1452
+ React.useEffect(() => {
1453
+ let didOpenWithoutFocusedItem = state.isOpen !== lastOpen.current && (state.selectionManager.focusedKey == null || isVirtualEvent.$c87311424ea30a05$export$e1865c3bedcd822b());
1454
+ if (state.isOpen && (didOpenWithoutFocusedItem || optionCount !== lastSize.current)) {
1455
+ let announcement = stringFormatter.format("countAnnouncement", {
1456
+ optionCount
1457
+ });
1458
+ LiveAnnouncer.$319e236875307eab$export$a9b970dcc4ae71a9(announcement);
1459
+ }
1460
+ lastSize.current = optionCount;
1461
+ lastOpen.current = state.isOpen;
1462
+ });
1463
+ let lastSelectedKey = React.useRef(state.selectedKey);
1464
+ React.useEffect(() => {
1465
+ if (isVirtualEvent.$c87311424ea30a05$export$e1865c3bedcd822b() && state.isFocused && state.selectedItem && state.selectedKey !== lastSelectedKey.current) {
1466
+ let optionText = state.selectedItem["aria-label"] || state.selectedItem.textValue || "";
1467
+ let announcement = stringFormatter.format("selectedAnnouncement", {
1468
+ optionText
1469
+ });
1470
+ LiveAnnouncer.$319e236875307eab$export$a9b970dcc4ae71a9(announcement);
1471
+ }
1472
+ lastSelectedKey.current = state.selectedKey;
1473
+ });
1474
+ React.useEffect(() => {
1475
+ if (state.isOpen) return ariaHideOutside.$5e3802645cc19319$export$1c3ebcada18427bf([
1476
+ inputRef.current,
1477
+ popoverRef.current
1478
+ ].filter((element) => element != null));
1479
+ }, [
1480
+ state.isOpen,
1481
+ inputRef,
1482
+ popoverRef
1483
+ ]);
1484
+ return {
1485
+ labelProps,
1486
+ buttonProps: __spreadProps(__spreadValues(__spreadValues({}, menuTriggerProps), triggerLabelProps), {
1487
+ excludeFromTabOrder: true,
1488
+ preventFocusOnPress: true,
1489
+ onPress,
1490
+ onPressStart,
1491
+ isDisabled: isDisabled || isReadOnly
1492
+ }),
1493
+ inputProps: mergeProps.$3ef42575df84b30b$export$9d1611c77c2fe928(inputProps, {
1494
+ role: "combobox",
1495
+ "aria-expanded": menuTriggerProps["aria-expanded"],
1496
+ "aria-controls": state.isOpen ? menuProps.id : void 0,
1497
+ // TODO: readd proper logic for completionMode = complete (aria-autocomplete: both)
1498
+ "aria-autocomplete": "list",
1499
+ "aria-activedescendant": focusedItem ? useListBoxSection.$b1f0cad8af73213b$export$9145995848b05025(state, focusedItem.key) : void 0,
1500
+ onTouchEnd,
1501
+ // This disable's iOS's autocorrect suggestions, since the combo box provides its own suggestions.
1502
+ autoCorrect: "off",
1503
+ // This disable's the macOS Safari spell check auto corrections.
1504
+ spellCheck: "false"
1505
+ }),
1506
+ listBoxProps: mergeProps.$3ef42575df84b30b$export$9d1611c77c2fe928(menuProps, listBoxProps, {
1507
+ autoFocus: state.focusStrategy,
1508
+ shouldUseVirtualFocus: true,
1509
+ shouldSelectOnPressUp: true,
1510
+ shouldFocusOnHover: true,
1511
+ linkBehavior: "selection"
1512
+ }),
1513
+ descriptionProps,
1514
+ errorMessageProps,
1515
+ isInvalid,
1516
+ validationErrors,
1517
+ validationDetails
1518
+ };
1519
+ }
1520
+ const $ee014567cb39d3f0$export$ff05c3ac10437e03 = /* @__PURE__ */ React.createContext(null);
1521
+ const $d3e0e05bdfcf66bd$export$c24727297075ec6a = /* @__PURE__ */ React.createContext(null);
1522
+ const $3985021b0ad6602f$export$37fb8590cf2c088c = /* @__PURE__ */ React.createContext({});
1523
+ let $3985021b0ad6602f$var$filterHoverProps = (props) => {
1524
+ let _a = props, { onHoverStart, onHoverChange, onHoverEnd } = _a, otherProps = __objRest(_a, ["onHoverStart", "onHoverChange", "onHoverEnd"]);
1525
+ return otherProps;
1526
+ };
1527
+ function $3985021b0ad6602f$var$Input(props, ref) {
1528
+ [props, ref] = utils.$64fa3d84918910a7$export$29f1550f4b0d4415(props, ref, $3985021b0ad6602f$export$37fb8590cf2c088c);
1529
+ let { hoverProps, isHovered } = useHover.$6179b936705e76d3$export$ae780daf29e6d456(props);
1530
+ let { isFocused, isFocusVisible, focusProps } = useFocusRing.$f7dceffc5ad7768b$export$4e328f61c538687f({
1531
+ isTextInput: true,
1532
+ autoFocus: props.autoFocus
1533
+ });
1534
+ let isInvalid = !!props["aria-invalid"] && props["aria-invalid"] !== "false";
1535
+ let renderProps = utils.$64fa3d84918910a7$export$4d86445c2cf5e3(__spreadProps(__spreadValues({}, props), {
1536
+ values: {
1537
+ isHovered,
1538
+ isFocused,
1539
+ isFocusVisible,
1540
+ isDisabled: props.disabled || false,
1541
+ isInvalid
1542
+ },
1543
+ defaultClassName: "react-aria-Input"
1544
+ }));
1545
+ return /* @__PURE__ */ React.createElement("input", __spreadProps(__spreadValues(__spreadValues({}, mergeProps.$3ef42575df84b30b$export$9d1611c77c2fe928($3985021b0ad6602f$var$filterHoverProps(props), focusProps, hoverProps)), renderProps), {
1546
+ ref,
1547
+ "data-focused": isFocused || void 0,
1548
+ "data-disabled": props.disabled || void 0,
1549
+ "data-hovered": isHovered || void 0,
1550
+ "data-focus-visible": isFocusVisible || void 0,
1551
+ "data-invalid": isInvalid || void 0
1552
+ }));
1553
+ }
1554
+ const $3985021b0ad6602f$export$f5b8910cec6cf069 = /* @__PURE__ */ Button.$f39a9eba43920ace$export$86427a43e3e48ebb($3985021b0ad6602f$var$Input);
1555
+ const $a049562f99e7db0e$export$f9c6924e160136d1 = /* @__PURE__ */ React.createContext({});
1556
+ const $d01f2c01039c0eec$export$d414ccceff7063c3 = /* @__PURE__ */ React.createContext(null);
1557
+ const $d01f2c01039c0eec$export$c02625b26074192c = /* @__PURE__ */ React.createContext(null);
1558
+ function $d01f2c01039c0eec$var$ComboBox(props, ref) {
1559
+ [props, ref] = utils.$64fa3d84918910a7$export$29f1550f4b0d4415(props, ref, $d01f2c01039c0eec$export$d414ccceff7063c3);
1560
+ let { children, isDisabled = false, isInvalid = false, isRequired = false } = props;
1561
+ let content = React.useMemo(() => {
1562
+ var _props_items;
1563
+ return /* @__PURE__ */ React.createElement(PillGroup.$eed445e0843c11d0$export$7ff8f37d2d81a48d.Provider, {
1564
+ value: {
1565
+ items: (_props_items = props.items) !== null && _props_items !== void 0 ? _props_items : props.defaultItems
1566
+ }
1567
+ }, typeof children === "function" ? children({
1568
+ isOpen: false,
1569
+ isDisabled,
1570
+ isInvalid,
1571
+ isRequired,
1572
+ defaultChildren: null
1573
+ }) : children);
1574
+ }, [
1575
+ children,
1576
+ isDisabled,
1577
+ isInvalid,
1578
+ isRequired,
1579
+ props.items,
1580
+ props.defaultItems
1581
+ ]);
1582
+ return /* @__PURE__ */ React.createElement(PillGroup.$e1995378a142960e$export$bf788dd355e3a401, {
1583
+ content
1584
+ }, (collection) => /* @__PURE__ */ React.createElement($d01f2c01039c0eec$var$ComboBoxInner, {
1585
+ props,
1586
+ collection,
1587
+ comboBoxRef: ref
1588
+ }));
1589
+ }
1590
+ function $d01f2c01039c0eec$var$ComboBoxInner({ props, collection, comboBoxRef: ref }) {
1591
+ let { name, formValue = "key", allowsCustomValue } = props;
1592
+ if (allowsCustomValue) formValue = "text";
1593
+ let { validationBehavior: formValidationBehavior } = utils.$64fa3d84918910a7$export$fabf2dc03a41866e($d3e0e05bdfcf66bd$export$c24727297075ec6a) || {};
1594
+ var _props_validationBehavior, _ref;
1595
+ let validationBehavior = (_ref = (_props_validationBehavior = props.validationBehavior) !== null && _props_validationBehavior !== void 0 ? _props_validationBehavior : formValidationBehavior) !== null && _ref !== void 0 ? _ref : "native";
1596
+ let { contains } = useFilter.$bb77f239b46e8c72$export$3274cf84b703fff({
1597
+ sensitivity: "base"
1598
+ });
1599
+ let state = $a9e7382a7d111cb5$export$b453a3bfd4a5fa9e(__spreadProps(__spreadValues({
1600
+ defaultFilter: props.defaultFilter || contains
1601
+ }, props), {
1602
+ // If props.items isn't provided, rely on collection filtering (aka listbox.items is provided or defaultItems provided to Combobox)
1603
+ items: props.items,
1604
+ children: void 0,
1605
+ collection,
1606
+ validationBehavior
1607
+ }));
1608
+ let buttonRef = React.useRef(null);
1609
+ let inputRef = React.useRef(null);
1610
+ let listBoxRef = React.useRef(null);
1611
+ let popoverRef = React.useRef(null);
1612
+ let [labelRef, label] = utils.$64fa3d84918910a7$export$9d4c57ee4c6ffdd8();
1613
+ let _a = $c350ade66beef0af$export$8c18d1b4f7232bbf(__spreadProps(__spreadValues({}, utils.$64fa3d84918910a7$export$ef03459518577ad4(props)), {
1614
+ label,
1615
+ inputRef,
1616
+ buttonRef,
1617
+ listBoxRef,
1618
+ popoverRef,
1619
+ name: formValue === "text" ? name : void 0,
1620
+ validationBehavior
1621
+ }), state), { buttonProps, inputProps, listBoxProps, labelProps, descriptionProps, errorMessageProps } = _a, validation = __objRest(_a, ["buttonProps", "inputProps", "listBoxProps", "labelProps", "descriptionProps", "errorMessageProps"]);
1622
+ let [menuWidth, setMenuWidth] = React.useState(null);
1623
+ let onResize = React.useCallback(() => {
1624
+ if (inputRef.current) {
1625
+ var _buttonRef_current;
1626
+ let buttonRect = (_buttonRef_current = buttonRef.current) === null || _buttonRef_current === void 0 ? void 0 : _buttonRef_current.getBoundingClientRect();
1627
+ let inputRect = inputRef.current.getBoundingClientRect();
1628
+ let minX = buttonRect ? Math.min(buttonRect.left, inputRect.left) : inputRect.left;
1629
+ let maxX = buttonRect ? Math.max(buttonRect.right, inputRect.right) : inputRect.right;
1630
+ setMenuWidth(maxX - minX + "px");
1631
+ }
1632
+ }, [
1633
+ buttonRef,
1634
+ inputRef,
1635
+ setMenuWidth
1636
+ ]);
1637
+ useResizeObserver.$9daab02d461809db$export$683480f191c0e3ea({
1638
+ ref: inputRef,
1639
+ onResize
1640
+ });
1641
+ let renderPropsState = React.useMemo(() => ({
1642
+ isOpen: state.isOpen,
1643
+ isDisabled: props.isDisabled || false,
1644
+ isInvalid: validation.isInvalid || false,
1645
+ isRequired: props.isRequired || false
1646
+ }), [
1647
+ state.isOpen,
1648
+ props.isDisabled,
1649
+ validation.isInvalid,
1650
+ props.isRequired
1651
+ ]);
1652
+ let renderProps = utils.$64fa3d84918910a7$export$4d86445c2cf5e3(__spreadProps(__spreadValues({}, props), {
1653
+ values: renderPropsState,
1654
+ defaultClassName: "react-aria-ComboBox"
1655
+ }));
1656
+ let DOMProps = filterDOMProps.$65484d02dcb7eb3e$export$457c3d6518dd4c6f(props);
1657
+ delete DOMProps.id;
1658
+ var _state_selectedKey;
1659
+ return /* @__PURE__ */ React.createElement(utils.$64fa3d84918910a7$export$2881499e37b75b9a, {
1660
+ values: [
1661
+ [
1662
+ $d01f2c01039c0eec$export$c02625b26074192c,
1663
+ state
1664
+ ],
1665
+ [
1666
+ PillGroup.$01b77f81d0f07f68$export$75b6ee27786ba447,
1667
+ __spreadProps(__spreadValues({}, labelProps), {
1668
+ ref: labelRef
1669
+ })
1670
+ ],
1671
+ [
1672
+ Button.$d2b4bc8c273e7be6$export$24d547caef80ccd1,
1673
+ __spreadProps(__spreadValues({}, buttonProps), {
1674
+ ref: buttonRef,
1675
+ isPressed: state.isOpen
1676
+ })
1677
+ ],
1678
+ [
1679
+ $3985021b0ad6602f$export$37fb8590cf2c088c,
1680
+ __spreadProps(__spreadValues({}, inputProps), {
1681
+ ref: inputRef
1682
+ })
1683
+ ],
1684
+ [
1685
+ Dialog.$de32f1b87079253c$export$d2f961adcb0afbe,
1686
+ state
1687
+ ],
1688
+ [
1689
+ Dialog.$07b14b47974efb58$export$9b9a0cd73afb7ca4,
1690
+ {
1691
+ ref: popoverRef,
1692
+ triggerRef: inputRef,
1693
+ scrollRef: listBoxRef,
1694
+ placement: "bottom start",
1695
+ isNonModal: true,
1696
+ trigger: "ComboBox",
1697
+ style: {
1698
+ "--trigger-width": menuWidth
1699
+ }
1700
+ }
1701
+ ],
1702
+ [
1703
+ PillGroup.$eed445e0843c11d0$export$7ff8f37d2d81a48d,
1704
+ __spreadProps(__spreadValues({}, listBoxProps), {
1705
+ ref: listBoxRef
1706
+ })
1707
+ ],
1708
+ [
1709
+ PillGroup.$eed445e0843c11d0$export$7c5906fe4f1f2af2,
1710
+ state
1711
+ ],
1712
+ [
1713
+ PillGroup.$514c0188e459b4c0$export$9afb8bc826b033ea,
1714
+ {
1715
+ slots: {
1716
+ description: descriptionProps,
1717
+ errorMessage: errorMessageProps
1718
+ }
1719
+ }
1720
+ ],
1721
+ [
1722
+ $a049562f99e7db0e$export$f9c6924e160136d1,
1723
+ {
1724
+ isInvalid: validation.isInvalid,
1725
+ isDisabled: props.isDisabled || false
1726
+ }
1727
+ ],
1728
+ [
1729
+ $ee014567cb39d3f0$export$ff05c3ac10437e03,
1730
+ validation
1731
+ ]
1732
+ ]
1733
+ }, /* @__PURE__ */ React.createElement("div", __spreadProps(__spreadValues(__spreadValues({}, DOMProps), renderProps), {
1734
+ ref,
1735
+ slot: props.slot || void 0,
1736
+ "data-focused": state.isFocused || void 0,
1737
+ "data-open": state.isOpen || void 0,
1738
+ "data-disabled": props.isDisabled || void 0,
1739
+ "data-invalid": validation.isInvalid || void 0,
1740
+ "data-required": props.isRequired || void 0
1741
+ })), name && formValue === "key" && /* @__PURE__ */ React.createElement("input", {
1742
+ type: "hidden",
1743
+ name,
1744
+ value: (_state_selectedKey = state.selectedKey) !== null && _state_selectedKey !== void 0 ? _state_selectedKey : ""
1745
+ }));
1746
+ }
1747
+ const $d01f2c01039c0eec$export$72b9695b8216309a = /* @__PURE__ */ React.forwardRef($d01f2c01039c0eec$var$ComboBox);
1748
+ var __defProp2 = Object.defineProperty;
1749
+ var __getOwnPropSymbols2 = Object.getOwnPropertySymbols;
1750
+ var __hasOwnProp2 = Object.prototype.hasOwnProperty;
1751
+ var __propIsEnum2 = Object.prototype.propertyIsEnumerable;
1752
+ var __defNormalProp2 = (obj, key, value) => key in obj ? __defProp2(obj, key, {
1753
+ enumerable: true,
1754
+ configurable: true,
1755
+ writable: true,
1756
+ value
1757
+ }) : obj[key] = value;
1758
+ var __spreadValues2 = (a, b) => {
1759
+ for (var prop in b || (b = {})) if (__hasOwnProp2.call(b, prop)) __defNormalProp2(a, prop, b[prop]);
1760
+ if (__getOwnPropSymbols2) for (var prop of __getOwnPropSymbols2(b)) {
1761
+ if (__propIsEnum2.call(b, prop)) __defNormalProp2(a, prop, b[prop]);
1762
+ }
1763
+ return a;
1764
+ };
1765
+ var __objRest2 = (source, exclude) => {
1766
+ var target = {};
1767
+ for (var prop in source) if (__hasOwnProp2.call(source, prop) && exclude.indexOf(prop) < 0) target[prop] = source[prop];
1768
+ if (source != null && __getOwnPropSymbols2) for (var prop of __getOwnPropSymbols2(source)) {
1769
+ if (exclude.indexOf(prop) < 0 && __propIsEnum2.call(source, prop)) target[prop] = source[prop];
1770
+ }
1771
+ return target;
1772
+ };
1773
+ const KeyboardArrowDown = (_a) => {
1774
+ var _b = _a, { title, titleId } = _b, props = __objRest2(_b, ["title", "titleId"]);
1775
+ return React__namespace.createElement("svg", __spreadValues2({
1776
+ xmlns: "http://www.w3.org/2000/svg",
1777
+ viewBox: "0 -960 960 960",
1778
+ "aria-labelledby": titleId
1779
+ }, props), title ? React__namespace.createElement("title", {
1780
+ id: titleId
1781
+ }, title) : null, React__namespace.createElement("path", {
1782
+ d: "M480-357.85 253.85-584l32.61-32.61L480-423.08l193.54-193.53L706.15-584 480-357.85Z"
1783
+ }));
1784
+ };
1785
+ const popover = "_popover_c33uy_5";
1786
+ const menu = "_menu_c33uy_23";
1787
+ const option = "_option_c33uy_28";
1788
+ const listEmptyState = "_listEmptyState_c33uy_29";
1789
+ const spinnerContainer = "_spinnerContainer_c33uy_53";
1790
+ const spinner = "_spinner_c33uy_53";
1791
+ const styles$1 = {
1792
+ popover,
1793
+ menu,
1794
+ option,
1795
+ listEmptyState,
1796
+ spinnerContainer,
1797
+ spinner
1798
+ };
1799
+ function MultiSelectDropdown(props) {
1800
+ const { children, maxItemsUntilScroll = utilities.DEFAULT_MAX_ITEMS_UNTIL_SCROLL, isLoading, triggerRef, menuRef, width } = props;
1801
+ const style = __spreadValues(__spreadValues({
1802
+ width
1803
+ }, utilities_css.getComponentToken("menu", "item_height", `${utilities_css.pxToRem(utilities.ITEM_HEIGHT)}rem`)), utilities_css.getComponentToken("menu", "padding.y", `${utilities_css.pxToRem(utilities.Y_PADDING_INSIDE_OVERLAY)}rem`));
1804
+ return React.createElement(Dialog.$07b14b47974efb58$export$5b6b19405a83ff9d, {
1805
+ isNonModal: true,
1806
+ className: styles$1.popover,
1807
+ style,
1808
+ triggerRef,
1809
+ scrollRef: menuRef,
1810
+ trigger: "ComboBox",
1811
+ maxHeight: utilities.getMenuPopoverMaxHeight({
1812
+ maxItemsUntilScroll
1813
+ })
1814
+ }, isLoading ? React.createElement("div", {
1815
+ className: styles$1.spinnerContainer
1816
+ }, React.createElement("div", {
1817
+ className: styles$1.spinner
1818
+ }, React.createElement(Spinner.Spinner, {
1819
+ isIndeterminate: true,
1820
+ "aria-label": "Loading",
1821
+ size: "sm"
1822
+ }))) : React.createElement(ScrollContainer, {
1823
+ scrollRef: menuRef
1824
+ }, React.createElement(PillGroup.$eed445e0843c11d0$export$41f133550aa26f48, {
1825
+ renderEmptyState: () => React.createElement("div", {
1826
+ className: styles$1.listEmptyState
1827
+ }, React.createElement(Text.Text, {
1828
+ variant: "subtitle2",
1829
+ color: "neutral.400"
1830
+ }, "No results found")),
1831
+ selectionMode: "multiple"
1832
+ }, children)));
1833
+ }
1834
+ function MultiSelectDropdownOption(props) {
1835
+ return React.createElement(PillGroup.$eed445e0843c11d0$export$a11e76429ed99b4, __spreadProps(__spreadValues({}, props), {
1836
+ className: styles$1.option
1837
+ }));
1838
+ }
1839
+ function MultiSelectDropdownOptionText(props) {
1840
+ return React.createElement(Text.Text, __spreadValues({
1841
+ variant: "body1"
1842
+ }, props));
1843
+ }
1844
+ function ScrollContainer({ scrollRef, children }) {
1845
+ utilities_useScrollbar.useScrollbar(scrollRef, "ezui-os-theme-overlay");
1846
+ return React.createElement("div", {
1847
+ className: styles$1.menu,
1848
+ ref: scrollRef
1849
+ }, children);
1850
+ }
1851
+ function useElementWidth(elementRef) {
1852
+ const [width, setWidth] = React.useState(0);
1853
+ useResizeObserver.$9daab02d461809db$export$683480f191c0e3ea({
1854
+ ref: elementRef,
1855
+ onResize() {
1856
+ if (elementRef.current) {
1857
+ const { width: width2 } = elementRef.current.getBoundingClientRect();
1858
+ setWidth(width2);
1859
+ }
1860
+ }
1861
+ });
1862
+ return width;
1863
+ }
1864
+ const MultiSelect$1 = "_MultiSelect_1g32f_5";
1865
+ const input = "_input_1g32f_38";
1866
+ const comboBoxContainer = "_comboBoxContainer_1g32f_43";
1867
+ const comboBox = "_comboBox_1g32f_43";
1868
+ const inputContainer = "_inputContainer_1g32f_53";
1869
+ const dropdownArrowButton = "_dropdownArrowButton_1g32f_84";
1870
+ const styles = {
1871
+ MultiSelect: MultiSelect$1,
1872
+ input,
1873
+ comboBoxContainer,
1874
+ comboBox,
1875
+ inputContainer,
1876
+ dropdownArrowButton
1877
+ };
1878
+ function MultiSelect(props) {
1879
+ const { children, disabledKeys, dropdownItems = [], inputValue, isLoading, maxItemsUntilScroll = utilities.DEFAULT_MAX_ITEMS_UNTIL_SCROLL, onInputChange = () => {
1880
+ }, onSelectionChange, placeholder, renderPill, selectedItems } = props;
1881
+ const rootRef = React.useRef(null);
1882
+ const clearComboBoxButtonRef = React.useRef(null);
1883
+ const menuRef = React.useRef(null);
1884
+ const [tempSelectedKey, setTempSelectedKey] = React.useState(null);
1885
+ const rootWidth = useElementWidth(rootRef);
1886
+ const onRemoveSelectedItem = (keys) => {
1887
+ const key = keys.values().next().value;
1888
+ if (key) {
1889
+ onSelectionChange(selectedItems.filter((k) => k.key !== key));
1890
+ onInputChange("");
1891
+ setTempSelectedKey(null);
1892
+ }
1893
+ };
1894
+ const onComboBoxSelectionChange = (key) => {
1895
+ if (!key) {
1896
+ return;
1897
+ }
1898
+ const item = [...dropdownItems].find((i) => i.key === key);
1899
+ if (!item) {
1900
+ return;
1901
+ }
1902
+ if (!selectedItems.map((i) => i.key).includes(key)) {
1903
+ onSelectionChange([...selectedItems, item]);
1904
+ setTempSelectedKey(key);
1905
+ }
1906
+ onInputChange("");
1907
+ };
1908
+ const onComboBoxInputChange = (value) => {
1909
+ onInputChange(value);
1910
+ setTempSelectedKey((prevSelectedKey) => value === "" ? null : prevSelectedKey);
1911
+ };
1912
+ const onComboBoxInputKeyDownCapture = (e) => {
1913
+ if (e.key === "Backspace" && inputValue === "") {
1914
+ if (selectedItems.length === 0) {
1915
+ return;
1916
+ }
1917
+ if (selectedItems.length > 0) {
1918
+ const endItem = selectedItems[selectedItems.length - 1];
1919
+ onSelectionChange(selectedItems.filter((k) => k.key !== endItem.key));
1920
+ }
1921
+ onInputChange("");
1922
+ setTempSelectedKey(null);
1923
+ }
1924
+ };
1925
+ const onComboBoxInputBlur = () => {
1926
+ onInputChange("");
1927
+ setTempSelectedKey(null);
1928
+ };
1929
+ return React.createElement("div", {
1930
+ ref: rootRef,
1931
+ className: styles.MultiSelect
1932
+ }, selectedItems.length > 0 ? React.createElement(PillGroup.PillGroup, {
1933
+ items: selectedItems,
1934
+ horizontalStackContainerProps: {
1935
+ gap: "1"
1936
+ },
1937
+ onRemove: onRemoveSelectedItem,
1938
+ label: "Selected items"
1939
+ }, renderPill) : React.createElement(VisuallyHidden.$5c3e21d68f1c4674$export$439d29a4e110a164, null, React.createElement(Text.Text, null, "No selected items")), React.createElement("div", {
1940
+ className: styles.comboBoxContainer
1941
+ }, React.createElement($d01f2c01039c0eec$export$72b9695b8216309a, {
1942
+ className: styles.comboBox,
1943
+ allowsEmptyCollection: true,
1944
+ "aria-label": "Available items",
1945
+ selectedKey: tempSelectedKey,
1946
+ onSelectionChange: onComboBoxSelectionChange,
1947
+ items: dropdownItems,
1948
+ inputValue,
1949
+ onInputChange: onComboBoxInputChange,
1950
+ disabledKeys
1951
+ }, React.createElement("div", {
1952
+ className: styles.inputContainer
1953
+ }, React.createElement($3985021b0ad6602f$export$f5b8910cec6cf069, {
1954
+ placeholder,
1955
+ className: styles.input,
1956
+ onBlur: onComboBoxInputBlur,
1957
+ onKeyDownCapture: onComboBoxInputKeyDownCapture
1958
+ }), React.createElement(VisuallyHidden.$5c3e21d68f1c4674$export$439d29a4e110a164, null, React.createElement(Button.$d2b4bc8c273e7be6$export$353f5b6fc5456de1, {
1959
+ type: "button",
1960
+ slot: "remove",
1961
+ "aria-label": "Clear",
1962
+ ref: clearComboBoxButtonRef
1963
+ }))), React.createElement(MultiSelectDropdown, {
1964
+ triggerRef: rootRef,
1965
+ menuRef,
1966
+ maxItemsUntilScroll,
1967
+ isLoading,
1968
+ width: rootWidth
1969
+ }, children)), React.createElement("button", {
1970
+ type: "button",
1971
+ className: styles.dropdownArrowButton,
1972
+ onClick: () => {
1973
+ var _a;
1974
+ return (_a = clearComboBoxButtonRef.current) == null ? void 0 : _a.click();
1975
+ },
1976
+ tabIndex: -1
1977
+ }, React.createElement(Text.Text, {
1978
+ visuallyHidden: true
1979
+ }, "Open dropdown"), React.createElement(Icon.Icon, {
1980
+ symbol: KeyboardArrowDown
1981
+ }))));
1982
+ }
1983
+ MultiSelect.Pill = PillGroup.PillGroup.Pill;
1984
+ MultiSelect.Option = MultiSelectDropdownOption;
1985
+ MultiSelect.OptionText = MultiSelectDropdownOptionText;
1986
+ exports.useListData = PillGroup.$0d86e9c8f07f9a7b$export$762f73dccccd255d;
1987
+ exports.useFilter = useFilter.$bb77f239b46e8c72$export$3274cf84b703fff;
1988
+ exports.MultiSelect = MultiSelect;
1989
+ exports.useAsyncList = $f86e6c1ec7da6ebb$export$bc3384a35de93d66;