solid-baseui 0.1.0-alpha.1 → 0.1.0-alpha.2

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 (189) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/README.md +51 -20
  3. package/dist/lib/client/DialogHandle-DluOK_7u.js +521 -0
  4. package/dist/lib/client/DialogPopup-CfEb3F54.js +138 -0
  5. package/dist/lib/client/FieldControl-eDe-Jnp9.js +142 -0
  6. package/dist/lib/client/{FieldRootContext-izCEh80D.js → FieldRootContext-D3fuVjs3.js} +1 -1
  7. package/dist/lib/client/{FocusManager-NP1uPXTi.js → FocusManager-q7z7PMV1.js} +92 -89
  8. package/dist/lib/client/{InternalBackdrop-cSK13gaM.js → InternalBackdrop-B8_lfUvf.js} +1 -1
  9. package/dist/lib/client/{MenuSubmenuTrigger-yfncqM-D.js → MenuSubmenuTrigger-DMb5CwTF.js} +386 -386
  10. package/dist/lib/client/{PopupHandle-CQI6Om1Z.js → PopupHandle-DyX5gY1e.js} +17 -11
  11. package/dist/lib/client/{PopupStore-Du0O57fL.js → PopupStore-BjRwcvbG.js} +91 -88
  12. package/dist/lib/client/PopupViewport-BanYHrD-.js +154 -0
  13. package/dist/lib/client/{TriggerFocusGuards-Cs8LVBj5.js → TriggerFocusGuards-Fzspp3Y1.js} +2 -2
  14. package/dist/lib/client/accordion/index.js +1 -1
  15. package/dist/lib/client/{accordion-BFeZFpJZ.js → accordion-CA2DfX67.js} +144 -144
  16. package/dist/lib/client/alert-dialog/index.js +1 -1
  17. package/dist/lib/client/{alert-dialog-BxGUF8_Q.js → alert-dialog-Bup88Dpx.js} +2 -2
  18. package/dist/lib/client/autocomplete/index.js +1 -1
  19. package/dist/lib/client/{autocomplete-C9QA98XD.js → autocomplete-oyy_uRpU.js} +2 -2
  20. package/dist/lib/client/avatar/index.js +1 -1
  21. package/dist/lib/client/avatar-DNZ4fnBd.js +191 -0
  22. package/dist/lib/client/button/index.js +1 -1
  23. package/dist/lib/client/button-BJZYmCVv.js +88 -0
  24. package/dist/lib/client/checkbox/index.js +1 -1
  25. package/dist/lib/client/checkbox-group/index.js +1 -1
  26. package/dist/lib/client/{checkbox-group-CwMDoSTK.js → checkbox-group-DGyrciZJ.js} +1 -1
  27. package/dist/lib/client/checkbox-sQHYTbpB.js +425 -0
  28. package/dist/lib/client/collapsible/index.js +1 -1
  29. package/dist/lib/client/collapsible-BENbFFCc.js +230 -0
  30. package/dist/lib/client/combobox/index.js +1 -1
  31. package/dist/lib/client/{combobox-6DhOdzit.js → combobox-BGH8QLXH.js} +143 -141
  32. package/dist/lib/client/compositeNavigation-DCt1sQon.js +82 -0
  33. package/dist/lib/client/{constants-cOVxAoxB.js → constants-ByOMFJAe.js} +100 -100
  34. package/dist/lib/client/context-menu/index.js +1 -1
  35. package/dist/lib/client/context-menu-xQ1sBCET.js +220 -0
  36. package/dist/lib/client/{createAnchorPositioning-D96gu-Dz.js → createAnchorPositioning-DCXIApS1.js} +1 -1
  37. package/dist/lib/client/{createAnchoredPopupScrollLock-Cx0cbh1_.js → createAnchoredPopupScrollLock-BxKpJbCE.js} +2 -2
  38. package/dist/lib/client/{createClickInteraction-CTaIFBiV.js → createClickInteraction-BeBsTqtY.js} +1 -1
  39. package/dist/lib/client/{createFocusInteraction--s9_qBf3.js → createFocusInteraction-DQPWkZe2.js} +7 -7
  40. package/dist/lib/client/{createPopupAutoResize-Dn-stj-8.js → createPopupAutoResize-CSNpMz5v.js} +3 -3
  41. package/dist/lib/client/dialog/index.js +1 -1
  42. package/dist/lib/client/{dialog-B9tR9X48.js → dialog-C0EF0a5u.js} +2 -2
  43. package/dist/lib/client/{dom-BEAeQ9Eb.js → dom-lDdayFF_.js} +25 -15
  44. package/dist/lib/client/drawer/index.js +1 -1
  45. package/dist/lib/client/{drawer-dyr3_sKQ.js → drawer-uKoNBwDU.js} +519 -518
  46. package/dist/lib/client/field/index.js +1 -1
  47. package/dist/lib/client/{field-CjUAjp1m.js → field-DIMrgpBW.js} +144 -144
  48. package/dist/lib/client/form/index.js +1 -1
  49. package/dist/lib/client/form-Bqq8wSLY.js +109 -0
  50. package/dist/lib/client/index.js +34 -34
  51. package/dist/lib/client/input/index.js +1 -1
  52. package/dist/lib/client/{input-_QHvSSqM.js → input-YthuKwIE.js} +1 -1
  53. package/dist/lib/client/internals/composeEventHandlers.js +14 -8
  54. package/dist/lib/client/internals/field-root-context/index.js +2 -2
  55. package/dist/lib/client/{mergeStyleValue-DhTA9Nwe.js → isSolidAccessor-BH_FevwH.js} +1 -12
  56. package/dist/lib/client/menu/index.js +1 -1
  57. package/dist/lib/client/{menu-DLqUBmMK.js → menu-4rNLN6aX.js} +79 -79
  58. package/dist/lib/client/menubar/index.js +1 -1
  59. package/dist/lib/client/menubar-nFQGtNmY.js +163 -0
  60. package/dist/lib/client/mergeStyleValue-Dcd36yxZ.js +12 -0
  61. package/dist/lib/client/navigation-menu/index.js +1 -1
  62. package/dist/lib/client/{navigation-menu-mVHV41Ky.js → navigation-menu-BbRyun3a.js} +284 -284
  63. package/dist/lib/client/number-field/index.js +1 -1
  64. package/dist/lib/client/{number-field-DusLw_0X.js → number-field-hT_H0hVu.js} +356 -356
  65. package/dist/lib/client/otp-field/index.js +1 -1
  66. package/dist/lib/client/otp-field-lsy2iGID.js +584 -0
  67. package/dist/lib/client/popover/index.js +1 -1
  68. package/dist/lib/client/{popover-Cv7xn0nW.js → popover-Cmvmuf1L.js} +250 -248
  69. package/dist/lib/client/{popupStateMapping-C6jQ_LKo.js → popupStateMapping-nhukB8NK.js} +51 -51
  70. package/dist/lib/client/preview-card/index.js +1 -1
  71. package/dist/lib/client/{preview-card-FTN_aafM.js → preview-card-Dtu8AnBN.js} +168 -168
  72. package/dist/lib/client/radio/index.js +1 -1
  73. package/dist/lib/client/{radio-DA_oZhQT.js → radio-CeCU-Qqi.js} +77 -77
  74. package/dist/lib/client/radio-group/index.js +1 -1
  75. package/dist/lib/client/radio-group-NbuJvjQe.js +195 -0
  76. package/dist/lib/client/{safePolygon-DJG0VIVo.js → safePolygon-DVAR5dQD.js} +70 -70
  77. package/dist/lib/client/scroll-area/index.js +1 -1
  78. package/dist/lib/client/scroll-area-DqbvoAd7.js +717 -0
  79. package/dist/lib/client/{scrollable-SRNYlhF7.js → scrollable-BVaDUXng.js} +12 -12
  80. package/dist/lib/client/select/index.js +1 -1
  81. package/dist/lib/client/{select-DSPJt7Rk.js → select-Dad51Xbn.js} +635 -634
  82. package/dist/lib/client/slider/index.js +1 -1
  83. package/dist/lib/client/slider-CLSKFq_M.js +927 -0
  84. package/dist/lib/client/switch/index.js +1 -1
  85. package/dist/lib/client/{switch-CPl7QHKI.js → switch-Bzuu5EIg.js} +61 -61
  86. package/dist/lib/client/tabs/index.js +1 -1
  87. package/dist/lib/client/{tabs-Bn4rZDyZ.js → tabs-DWiBDv8D.js} +252 -249
  88. package/dist/lib/client/toast/index.js +1 -1
  89. package/dist/lib/client/{toast-7LdqZWOs.js → toast-DmtPJW2k.js} +353 -353
  90. package/dist/lib/client/toggle/index.js +1 -1
  91. package/dist/lib/client/{toggle-CsC37e3e.js → toggle-CAe-Z8Xn.js} +33 -33
  92. package/dist/lib/client/toggle-group/index.js +1 -1
  93. package/dist/lib/client/{toggle-group-DSWb9HxN.js → toggle-group-BbQg5s-m.js} +44 -44
  94. package/dist/lib/client/toolbar/index.js +1 -1
  95. package/dist/lib/client/{toolbar-DcCi3HNp.js → toolbar-BXT_g-oX.js} +218 -218
  96. package/dist/lib/client/tooltip/index.js +1 -1
  97. package/dist/lib/client/{tooltip-D-PkGco9.js → tooltip-h2r2_Xuo.js} +250 -249
  98. package/dist/lib/client/{useFilteredItems-B7z2CGMV.js → useFilteredItems-BX0BEuSI.js} +850 -819
  99. package/dist/lib/server/{DialogHandle-nJSSy_jM.js → DialogHandle-BGIISmG7.js} +16 -16
  100. package/dist/lib/server/{DialogPopup-Da1aIxVA.js → DialogPopup-C2ZDGf42.js} +4 -4
  101. package/dist/lib/server/{FieldControl-BDeNR3ug.js → FieldControl-CDMMyvuj.js} +6 -6
  102. package/dist/lib/server/{FieldRootContext-IC-LWzVp.js → FieldRootContext-Bfpna6gA.js} +3 -3
  103. package/dist/lib/server/{FocusManager-1LfoCsya.js → FocusManager-D-xgblGs.js} +9 -3
  104. package/dist/lib/server/{InternalBackdrop-C_iDPVR-.js → InternalBackdrop-D_2zAWnl.js} +1 -1
  105. package/dist/lib/server/{MenuSubmenuTrigger-rR8ZN7YR.js → MenuSubmenuTrigger-BMQKlOvU.js} +50 -50
  106. package/dist/lib/server/{PopupHandle-Ct6wywmP.js → PopupHandle-QNj4mED2.js} +14 -5
  107. package/dist/lib/server/{PopupStore-kHjFPiQ5.js → PopupStore-evylvVnN.js} +5 -2
  108. package/dist/lib/server/{PopupViewport-DftN5VUp.js → PopupViewport-BDttjORN.js} +37 -27
  109. package/dist/lib/server/{TriggerFocusGuards-CvoGfft9.js → TriggerFocusGuards-B9GNbLrL.js} +2 -2
  110. package/dist/lib/server/accordion/index.js +7 -7
  111. package/dist/lib/server/alert-dialog/index.js +2 -2
  112. package/dist/lib/server/autocomplete/index.js +2 -2
  113. package/dist/lib/server/avatar/index.js +3 -3
  114. package/dist/lib/server/button/index.js +6 -6
  115. package/dist/lib/server/checkbox/index.js +7 -7
  116. package/dist/lib/server/checkbox-group/index.js +1 -1
  117. package/dist/lib/server/collapsible/index.js +6 -6
  118. package/dist/lib/server/combobox/index.js +18 -18
  119. package/dist/lib/server/{compositeNavigation-BRVT1C38.js → compositeNavigation-D5jKM4yk.js} +32 -1
  120. package/dist/lib/server/{constants-D7ciIzsV.js → constants-ByqXubhO.js} +2 -2
  121. package/dist/lib/server/context-menu/index.js +9 -9
  122. package/dist/lib/server/{createAnchorPositioning-B5Y0WEev.js → createAnchorPositioning-DrQYe7RS.js} +1 -1
  123. package/dist/lib/server/{createAnchoredPopupScrollLock-DFuUrykR.js → createAnchoredPopupScrollLock-q6gnOSmv.js} +2 -2
  124. package/dist/lib/server/{createClickInteraction-BYsMgvup.js → createClickInteraction-D7oc1Vco.js} +1 -1
  125. package/dist/lib/server/{createFocusInteraction-DMyKsniI.js → createFocusInteraction-DFKr4G7a.js} +1 -1
  126. package/dist/lib/server/{createPopupAutoResize-ImBjwdj_.js → createPopupAutoResize-Cg0-lLf4.js} +1 -1
  127. package/dist/lib/server/dialog/index.js +2 -2
  128. package/dist/lib/server/{dom-Crg_2R-j.js → dom-D8_aB1yy.js} +14 -1
  129. package/dist/lib/server/drawer/index.js +38 -34
  130. package/dist/lib/server/field/index.js +6 -6
  131. package/dist/lib/server/form/index.js +2 -2
  132. package/dist/lib/server/input/index.js +1 -1
  133. package/dist/lib/server/internals/composeEventHandlers.js +15 -9
  134. package/dist/lib/server/internals/field-root-context/index.js +1 -1
  135. package/dist/lib/server/{mergeStyleValue-BwJ10_X2.js → isSolidAccessor-CZpzAH5l.js} +1 -20
  136. package/dist/lib/server/menu/index.js +17 -17
  137. package/dist/lib/server/menubar/index.js +4 -4
  138. package/dist/lib/server/mergeStyleValue-DecVaoac.js +20 -0
  139. package/dist/lib/server/navigation-menu/index.js +21 -21
  140. package/dist/lib/server/number-field/index.js +21 -21
  141. package/dist/lib/server/otp-field/index.js +8 -8
  142. package/dist/lib/server/popover/index.js +27 -26
  143. package/dist/lib/server/{popupStateMapping-B2KsiiLb.js → popupStateMapping-VHqr6M4H.js} +1 -1
  144. package/dist/lib/server/preview-card/index.js +16 -16
  145. package/dist/lib/server/radio/index.js +6 -6
  146. package/dist/lib/server/radio-group/index.js +5 -5
  147. package/dist/lib/server/{safePolygon-C1GNJbKR.js → safePolygon-B8QtiIZ3.js} +1 -1
  148. package/dist/lib/server/scroll-area/index.js +18 -18
  149. package/dist/lib/server/{scrollable-CjsSxbGr.js → scrollable-C9Pgq8T5.js} +1 -1
  150. package/dist/lib/server/select/index.js +39 -38
  151. package/dist/lib/server/slider/index.js +14 -14
  152. package/dist/lib/server/switch/index.js +9 -9
  153. package/dist/lib/server/tabs/index.js +12 -8
  154. package/dist/lib/server/toast/index.js +32 -32
  155. package/dist/lib/server/toggle/index.js +7 -7
  156. package/dist/lib/server/toggle-group/index.js +2 -2
  157. package/dist/lib/server/toolbar/index.js +14 -14
  158. package/dist/lib/server/tooltip/index.js +32 -27
  159. package/dist/lib/server/{useFilteredItems-DCxq20Is.js → useFilteredItems-BmhL0nf1.js} +181 -137
  160. package/dist/lib/types/accordion/trigger/AccordionTrigger.d.ts +7 -7
  161. package/dist/lib/types/combobox/chip/ComboboxChip.d.ts +2 -0
  162. package/dist/lib/types/combobox/root/ComboboxRoot.d.ts +6 -1
  163. package/dist/lib/types/combobox/store/ComboboxStore.d.ts +1 -0
  164. package/dist/lib/types/combobox/utils/handleInputPress.d.ts +1 -1
  165. package/dist/lib/types/field/control/FieldControl.d.ts +5 -5
  166. package/dist/lib/types/internals/composeEventHandlers.d.ts +9 -2
  167. package/dist/lib/types/internals/field-root-context/FieldRootContext.d.ts +1 -0
  168. package/dist/lib/types/internals/overlay/dom.d.ts +2 -0
  169. package/dist/lib/types/number-field/input/NumberFieldInput.d.ts +5 -5
  170. package/dist/lib/types/slider/track/SliderTrack.d.ts +2 -2
  171. package/dist/lib/types/toolbar/link/ToolbarLink.d.ts +10 -3
  172. package/dist/lib/types/toolbar/root/ToolbarRoot.d.ts +10 -4
  173. package/package.json +1 -1
  174. package/dist/lib/client/DialogHandle-BGyIbcvg.js +0 -521
  175. package/dist/lib/client/DialogPopup-Df7MC358.js +0 -138
  176. package/dist/lib/client/FieldControl-C0PATyKV.js +0 -142
  177. package/dist/lib/client/PopupViewport-IS4XU03s.js +0 -152
  178. package/dist/lib/client/avatar-BQoEzzav.js +0 -191
  179. package/dist/lib/client/button-akYS6FyY.js +0 -88
  180. package/dist/lib/client/checkbox-DOXtzBhA.js +0 -425
  181. package/dist/lib/client/collapsible-t8YReaIp.js +0 -230
  182. package/dist/lib/client/compositeNavigation-sxniYTc7.js +0 -58
  183. package/dist/lib/client/context-menu-CplDpqmi.js +0 -220
  184. package/dist/lib/client/form-6Ne_bWQX.js +0 -109
  185. package/dist/lib/client/menubar-DhPRUQZ6.js +0 -163
  186. package/dist/lib/client/otp-field-D-B9tZzF.js +0 -584
  187. package/dist/lib/client/radio-group-CWtQxWDl.js +0 -195
  188. package/dist/lib/client/scroll-area-NCr49LkD.js +0 -717
  189. package/dist/lib/client/slider-CWq9hxFf.js +0 -927
@@ -1,195 +0,0 @@
1
- import { t as e } from "./useRender-CxZ8PI-g.js";
2
- import { getStateAttributesProps as t } from "./internals/getStateAttributesProps.js";
3
- import { n, t as r } from "./resolveStyle-XcgAuaKR.js";
4
- import { composeEventHandlers as i } from "./internals/composeEventHandlers.js";
5
- import { n as a } from "./DirectionContext-BwMabICS.js";
6
- import { fieldStateAttributesMapping as o } from "./internals/field-constants.js";
7
- import { n as ee } from "./FieldRootContext-izCEh80D.js";
8
- import { n as te } from "./FormContext-CwLBtm_d.js";
9
- import { r as ne } from "./LabelableContext-CmQF-TX2.js";
10
- import { n as s } from "./FieldsetRootContext-BgThSAcd.js";
11
- import { t as c } from "./RadioGroupContext-CZexBsPa.js";
12
- import { createComponent as l, getNextElement as re, mergeProps as ie, runHydrationEvents as ae, spread as oe, template as u } from "@solidjs/web";
13
- import { createEffect as d, createMemo as f, createSignal as p, createUniqueId as m, omit as h, onCleanup as g, onSettled as _, untrack as v } from "solid-js";
14
- //#region src/radio-group/RadioGroup.tsx
15
- var y = /* @__PURE__ */ u("<div>");
16
- function b(u) {
17
- let b = ee(!0), le = s(!0), C = te(), w = ne(), ue = a(), T = u, de = u, E = Symbol("RadioGroup"), D = `base-ui-${m()}`, O = v(() => T.value !== void 0), [k, A] = p(() => v(() => T.defaultValue)), [j, M] = p(), [N, P] = p(!1), [F, I] = p(), [L, R] = p(0), z = /* @__PURE__ */ new Map(), B, V = v(() => O ? T.value : k()), H, U, fe = h(de, "aria-describedby", "aria-labelledby", "render", "class", "defaultValue", "disabled", "form", "inputRef", "name", "onBlur", "onFocus", "onKeyDown", "onValueChange", "readOnly", "ref", "required", "style", "value"), W = f(() => O ? T.value : k()), G = f(() => b.disabled() || (T.disabled ?? !1)), K = f(() => T.readOnly ?? !1), q = f(() => T.required ?? !1), J = f(() => b.name() ?? T.name), pe = f(() => W() ?? null), Y = f(() => ({
18
- ...b.state(),
19
- disabled: G(),
20
- readOnly: K(),
21
- required: q()
22
- })), me = f(() => n(u.class, Y())), he = e(u, () => Y(), (e) => (() => {
23
- var t = re(y);
24
- return oe(t, e, !1), ae(), t;
25
- })()), ge = f(() => r(u.style, Y())), _e = f(() => t(Y(), o)), ve = f(() => T["aria-labelledby"] ?? w.labelId() ?? le?.legendId()), ye = f(() => w.getAriaDescribedBy(T["aria-describedby"])), be = f(() => {
26
- L();
27
- let e = Array.from(z.values()), t = e.find((e) => e.checked() && !e.disabled());
28
- return t ? t.token : e.find((e) => e.token === F() && !e.disabled())?.token ?? e.find((e) => !e.disabled())?.token;
29
- });
30
- function xe(e) {
31
- return z.set(e.token, e), (v(e.checked) || !B && !v(e.disabled)) && (B = e.token, I(e.token)), X(), () => {
32
- if (z.delete(e.token), B === e.token) {
33
- let e = Array.from(z.values()).find((e) => v(e.checked) && !v(e.disabled)) ?? Array.from(z.values()).find((e) => !v(e.disabled));
34
- B = e?.token, I(e?.token);
35
- }
36
- X();
37
- };
38
- }
39
- function X() {
40
- R((e) => e + 1);
41
- }
42
- function Z(e) {
43
- e.disabled() || (B = e.token, I(e.token));
44
- }
45
- function Q(e) {
46
- return !e.disabled() && be() === e.token;
47
- }
48
- function Se(e, t) {
49
- return T.onValueChange?.(e, t), !t.isCanceled && (O || A(() => e), !0);
50
- }
51
- function Ce() {
52
- for (let e of z.values()) {
53
- let t = v(e.input);
54
- t && (t.checked = v(e.checked));
55
- }
56
- }
57
- function we() {
58
- let e = C.formElement();
59
- if (!e) return W() ?? null;
60
- L();
61
- for (let t of z.values()) {
62
- let n = t.input();
63
- if (n?.checked && ce(n, e)) return W() ?? null;
64
- }
65
- return null;
66
- }
67
- let $ = {
68
- id: D,
69
- name: T.name,
70
- value: pe,
71
- getValue: we,
72
- getControl: () => b.validation.getInputControl() ?? j() ?? null
73
- }, Te = i(() => T.onFocus), Ee = i(() => T.onBlur), De = i(() => T.onKeyDown);
74
- function Oe(e) {
75
- Te.call(e.currentTarget, e), !e.baseUIHandlerPrevented && b.setFocused(!0);
76
- }
77
- function ke(e) {
78
- if (Ee.call(e.currentTarget, e), e.baseUIHandlerPrevented) return;
79
- let t = e.relatedTarget;
80
- t instanceof Element && se(e.currentTarget, t) || (b.setTouched(!0), b.setFocused(!1), b.validationMode() === "onBlur" && b.validation.commit(W()));
81
- }
82
- function Ae(e) {
83
- if (De.call(e.currentTarget, e), e.baseUIHandlerPrevented) return;
84
- let t = x(e, ue());
85
- if (t === 0 || e.ctrlKey || e.altKey || e.metaKey) return;
86
- L();
87
- let n = Array.from(z.values()).filter((e) => !e.disabled());
88
- if (n.length < 2) return;
89
- let r = e.composedPath()[0], i = n.findIndex((e) => r instanceof Node && e.element()?.contains(r));
90
- if (i === -1) return;
91
- let a = n[(i + t + n.length) % n.length];
92
- !a || a === n[i] || (e.preventDefault(), e.stopPropagation(), P(!0), Z(a), queueMicrotask(() => a.element()?.focus()));
93
- }
94
- let je = {
95
- checkedValue: W,
96
- disabled: G,
97
- fieldControlSource: E,
98
- form: () => T.form,
99
- name: J,
100
- readOnly: K,
101
- required: q,
102
- state: Y,
103
- touched: N,
104
- isTabStop: Q,
105
- notifyRadioChange: X,
106
- registerRadio: xe,
107
- selectValue: Se,
108
- setActiveRadio: Z,
109
- setTouched: P,
110
- syncInputs: Ce
111
- };
112
- return d(() => ({
113
- disabled: G(),
114
- element: j(),
115
- id: T.id ?? D,
116
- name: T.name
117
- }), (e) => {
118
- $.id = e.id, $.name = e.name, b.registerFieldControl(E, e.disabled || !e.element ? void 0 : $);
119
- }), d(() => ({
120
- initialValue: b.validityData().initialValue,
121
- name: J(),
122
- value: W()
123
- }), (e) => {
124
- e.value !== V && (V = e.value, v(() => {
125
- C.clearError(e.name), b.setDirty(e.value !== e.initialValue), b.setFilled(e.value != null), b.validation.change(e.value), X();
126
- }));
127
- }), d(() => {
128
- L();
129
- let e = Array.from(z.values()), t = e.find((e) => e.checked() && !e.disabled() && e.input())?.input();
130
- return {
131
- inputRef: T.inputRef,
132
- representative: t ?? e.find((e) => !e.disabled() && e.input())?.input()
133
- };
134
- }, (e) => {
135
- (e.representative !== H || e.inputRef !== U) && (H = e.representative, U = e.inputRef, e.representative && S(e.inputRef, e.representative));
136
- }), _(() => {
137
- b.setFilled(W() != null);
138
- }), g(() => b.registerFieldControl(E, void 0)), l(c, {
139
- value: je,
140
- get children() {
141
- return l(he, ie({
142
- ref: [((e) => M(e)), T.ref],
143
- get class() {
144
- return me();
145
- },
146
- get style() {
147
- return ge();
148
- },
149
- role: "radiogroup",
150
- get "aria-required"() {
151
- return q() ? "true" : void 0;
152
- },
153
- get "aria-disabled"() {
154
- return G() ? "true" : void 0;
155
- },
156
- get "aria-readonly"() {
157
- return K() ? "true" : void 0;
158
- },
159
- get "aria-labelledby"() {
160
- return ve();
161
- },
162
- get "aria-describedby"() {
163
- return ye();
164
- },
165
- get "aria-invalid"() {
166
- return Y().valid === !1 && !G() ? "true" : void 0;
167
- },
168
- onFocus: Oe,
169
- onBlur: ke,
170
- onKeyDown: Ae
171
- }, _e, fe));
172
- }
173
- });
174
- }
175
- function x(e, t) {
176
- return e.key === "ArrowDown" ? 1 : e.key === "ArrowUp" ? -1 : e.key === "ArrowRight" ? t === "rtl" ? -1 : 1 : e.key === "ArrowLeft" ? t === "rtl" ? 1 : -1 : 0;
177
- }
178
- function se(e, t) {
179
- if (e.contains(t)) return !0;
180
- let n = t;
181
- for (; n;) {
182
- if (n === e) return !0;
183
- n = n.parentNode ?? (n instanceof ShadowRoot ? n.host : null);
184
- }
185
- return !1;
186
- }
187
- function ce(e, t) {
188
- return e.matches(":disabled") ? !1 : e.form === t || e.form === null && !e.hasAttribute("form");
189
- }
190
- function S(e, t) {
191
- if (Array.isArray(e)) for (let n of e) S(n, t);
192
- else typeof e == "function" && e(t);
193
- }
194
- //#endregion
195
- export { b as t };