welcome-ui 8.0.0-alpha.0 → 8.0.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 (90) hide show
  1. package/dist/AXB53BZF-BOEe01VW.mjs +25 -0
  2. package/dist/Accordion.mjs +17 -17
  3. package/dist/Alert.mjs +19 -19
  4. package/dist/{BYC7LY2E-CVjUW1dr.mjs → BYC7LY2E-B1IDizRs.mjs} +298 -295
  5. package/dist/Badge.mjs +1 -1
  6. package/dist/Breadcrumb.mjs +27 -26
  7. package/dist/Button.mjs +2 -2
  8. package/dist/Checkbox.mjs +1 -1
  9. package/dist/{CustomInput-D_13Gd_3.mjs → CustomInput-IA_gVoXd.mjs} +2991 -2859
  10. package/dist/DatePicker.mjs +4 -4
  11. package/dist/DateTimePicker.mjs +9 -9
  12. package/dist/DateTimePickerCommon.mjs +1 -1
  13. package/dist/Drawer.mjs +7 -7
  14. package/dist/DropdownMenu.mjs +262 -262
  15. package/dist/Field.mjs +25 -25
  16. package/dist/FileDrop.mjs +273 -267
  17. package/dist/FileUpload.mjs +26 -26
  18. package/dist/Files.mjs +1 -1
  19. package/dist/Hint.mjs +1 -1
  20. package/dist/{ITI7HKP4-BONrZ9Pq.mjs → ITI7HKP4-EL9KXYBU.mjs} +150 -150
  21. package/dist/Icons.mjs +88 -88
  22. package/dist/IconsFont.mjs +159 -159
  23. package/dist/InputText.mjs +1 -1
  24. package/dist/{JC64G2H7-Dey-8h60.mjs → JC64G2H7-BzklVBKM.mjs} +70 -70
  25. package/dist/KUU7WJ55-CS4NemC6.mjs +61 -0
  26. package/dist/{LVA2YJMS-qFC9J-lt.mjs → LVA2YJMS-DDEmK0pp.mjs} +491 -488
  27. package/dist/Label.mjs +2 -2
  28. package/dist/Link.mjs +3 -3
  29. package/dist/MTZPJQMC-CMjAwC0N.mjs +15 -0
  30. package/dist/Modal.mjs +13 -13
  31. package/dist/NLEBE274-QOMV1l7e.mjs +84 -0
  32. package/dist/P2CTZE2T-Cl2w7OLV.mjs +300 -0
  33. package/dist/P4IRICAX-DezbJY4s.mjs +37 -0
  34. package/dist/Pagination.mjs +22 -22
  35. package/dist/Picker.mjs +2 -2
  36. package/dist/Popover.mjs +2 -2
  37. package/dist/QYJ6MIDR-Bb0O5xUM.mjs +97 -0
  38. package/dist/Radio.mjs +18 -18
  39. package/dist/RadioGroup.mjs +15 -15
  40. package/dist/RadioTab.mjs +9 -9
  41. package/dist/{SYRFVSLH-cVmYtx36.mjs → SYRFVSLH-jn06-eLy.mjs} +17 -17
  42. package/dist/Search.mjs +2 -2
  43. package/dist/Select.mjs +719 -716
  44. package/dist/Shape.mjs +1 -1
  45. package/dist/Slider.mjs +1 -1
  46. package/dist/Swiper.mjs +284 -278
  47. package/dist/Tabs.mjs +128 -128
  48. package/dist/Tag.mjs +16 -16
  49. package/dist/Text.mjs +1 -1
  50. package/dist/Textarea.mjs +4 -4
  51. package/dist/TimePicker.mjs +6 -6
  52. package/dist/Toast.mjs +69 -69
  53. package/dist/Toggle.mjs +2 -2
  54. package/dist/Tooltip.mjs +60 -60
  55. package/dist/UniversalLink.mjs +8 -8
  56. package/dist/VEVQD5MH-CuegL0m0.mjs +20 -0
  57. package/dist/{VGCJ63VH-B39w1tBw.mjs → VGCJ63VH-BMzoZtCu.mjs} +31 -33
  58. package/dist/VariantIcon.mjs +4 -4
  59. package/dist/WelcomeLoader.mjs +4862 -9223
  60. package/dist/X5NMLKT6-CvSCix-_.mjs +25 -0
  61. package/dist/YV4JVR4I-Bh7B7TET.mjs +344 -0
  62. package/dist/downshift.esm-D0ns_SQs.mjs +1082 -0
  63. package/dist/{field-styles-DLIhqG_8.mjs → field-styles-CfVLcVQp.mjs} +1 -1
  64. package/dist/{index-BDeIsk2X.mjs → index-5PUh49rV.mjs} +56 -56
  65. package/dist/{index-DEJJvyGk.mjs → index-B0gDDiFm.mjs} +7 -7
  66. package/dist/{index-CExLVjET.mjs → index-B22SHR8h.mjs} +4 -4
  67. package/dist/index-BhcLigYU.mjs +77 -0
  68. package/dist/{index-BJAZgeHL.mjs → index-Bkl89twW.mjs} +4 -4
  69. package/dist/{index-BYdkhqH4.mjs → index-CBBbX29m.mjs} +3652 -3584
  70. package/dist/{index-BpRjq7lj.mjs → index-CQD9fgf_.mjs} +3 -3
  71. package/dist/{index-BRDOakbf.mjs → index-CmsWSKKs.mjs} +5 -5
  72. package/dist/{index-SbQUT2mU.mjs → index-DgSynio4.mjs} +244 -239
  73. package/dist/{index-BrfXjmHY.mjs → index-wr_b5GSV.mjs} +6 -6
  74. package/dist/radio-group-RFyDp0KD.mjs +51 -0
  75. package/dist/theme.mjs +670 -615
  76. package/dist/{use-viewport-m3glsbna.mjs → use-viewport-CfklieD-.mjs} +5 -5
  77. package/dist/utils.mjs +29 -91
  78. package/package.json +12 -15
  79. package/dist/AXB53BZF-CGoc4K3d.mjs +0 -25
  80. package/dist/KUU7WJ55-3sP-w1F1.mjs +0 -61
  81. package/dist/MTZPJQMC-C0Xe_WK4.mjs +0 -13
  82. package/dist/NLEBE274-C94QU78N.mjs +0 -84
  83. package/dist/P2CTZE2T-YPes1GXe.mjs +0 -297
  84. package/dist/P4IRICAX-DzXqUYe-.mjs +0 -37
  85. package/dist/QYJ6MIDR-BLLqyXdd.mjs +0 -97
  86. package/dist/VEVQD5MH-ZMnHV8ZJ.mjs +0 -20
  87. package/dist/X5NMLKT6-uFSu0Lii.mjs +0 -25
  88. package/dist/YV4JVR4I-BGfUf3Nu.mjs +0 -341
  89. package/dist/downshift.esm-CEHW4VDy.mjs +0 -1085
  90. package/dist/radio-group-CGC6DTFJ.mjs +0 -51
@@ -1,15 +1,15 @@
1
1
  "use client";
2
- import { useState as t } from "react";
3
- import { u as r } from "./use-isomorphic-layout-effect-Izr-e2pi.mjs";
2
+ import { useState as n } from "react";
3
+ import { u as o } from "./use-isomorphic-layout-effect-Izr-e2pi.mjs";
4
4
  function w() {
5
- const [n, e] = t({ height: void 0, width: void 0 });
6
- return r(() => {
5
+ const [t, e] = n({ height: void 0, width: void 0 });
6
+ return o(() => {
7
7
  e({ width: window.innerWidth, height: window.innerHeight });
8
8
  function i() {
9
9
  e({ width: window.innerWidth, height: window.innerHeight });
10
10
  }
11
11
  return window.addEventListener("resize", i), () => window.removeEventListener("resize", i);
12
- }, []), n;
12
+ }, []), t;
13
13
  }
14
14
  export {
15
15
  w as u
package/dist/utils.mjs CHANGED
@@ -1,95 +1,33 @@
1
1
  "use client";
2
- import { f as k } from "./format-bytes-gST0dTWd.mjs";
3
- import { h as A } from "./hex-to-rgba-BIDK-3ab.mjs";
4
- import { F as U, d as L } from "./field-styles-DLIhqG_8.mjs";
5
- import { o as N } from "./overflow-ellipsis-DGV5Kgt-.mjs";
6
- import { t as P } from "./throttle-BDBzFeFj.mjs";
7
- import { useState as d, useCallback as m } from "react";
8
- import { g as y } from "./_commonjsHelpers-CXJ7dpIk.mjs";
9
- import { s as B, u as _ } from "./use-fork-ref-CUZErtAC.mjs";
10
- import { u as G } from "./use-isomorphic-layout-effect-Izr-e2pi.mjs";
11
- import { u as O } from "./use-viewport-m3glsbna.mjs";
12
- var g = function() {
13
- var e = document.getSelection();
14
- if (!e.rangeCount)
15
- return function() {
16
- };
17
- for (var t = document.activeElement, r = [], o = 0; o < e.rangeCount; o++)
18
- r.push(e.getRangeAt(o));
19
- switch (t.tagName.toUpperCase()) {
20
- case "INPUT":
21
- case "TEXTAREA":
22
- t.blur();
23
- break;
24
- default:
25
- t = null;
26
- break;
27
- }
28
- return e.removeAllRanges(), function() {
29
- e.type === "Caret" && e.removeAllRanges(), e.rangeCount || r.forEach(function(c) {
30
- e.addRange(c);
31
- }), t && t.focus();
32
- };
33
- }, v = g, f = {
34
- "text/plain": "Text",
35
- "text/html": "Url",
36
- default: "Text"
37
- }, b = "Copy to clipboard: #{key}, Enter";
38
- function C(e) {
39
- var t = (/mac os x/i.test(navigator.userAgent) ? "⌘" : "Ctrl") + "+C";
40
- return e.replace(/#{\s*key\s*}/g, t);
41
- }
42
- function x(e, t) {
43
- var r, o, c, n, s, a, i = !1;
44
- t || (t = {}), r = t.debug || !1;
45
- try {
46
- c = v(), n = document.createRange(), s = document.getSelection(), a = document.createElement("span"), a.textContent = e, a.ariaHidden = "true", a.style.all = "unset", a.style.position = "fixed", a.style.top = 0, a.style.clip = "rect(0, 0, 0, 0)", a.style.whiteSpace = "pre", a.style.webkitUserSelect = "text", a.style.MozUserSelect = "text", a.style.msUserSelect = "text", a.style.userSelect = "text", a.addEventListener("copy", function(l) {
47
- if (l.stopPropagation(), t.format)
48
- if (l.preventDefault(), typeof l.clipboardData > "u") {
49
- r && console.warn("unable to use e.clipboardData"), r && console.warn("trying IE specific stuff"), window.clipboardData.clearData();
50
- var u = f[t.format] || f.default;
51
- window.clipboardData.setData(u, e);
52
- } else
53
- l.clipboardData.clearData(), l.clipboardData.setData(t.format, e);
54
- t.onCopy && (l.preventDefault(), t.onCopy(l.clipboardData));
55
- }), document.body.appendChild(a), n.selectNodeContents(a), s.addRange(n);
56
- var p = document.execCommand("copy");
57
- if (!p)
58
- throw new Error("copy command was unsuccessful");
59
- i = !0;
60
- } catch (l) {
61
- r && console.error("unable to copy using execCommand: ", l), r && console.warn("trying IE specific stuff");
62
- try {
63
- window.clipboardData.setData(t.format || "text", e), t.onCopy && t.onCopy(window.clipboardData), i = !0;
64
- } catch (u) {
65
- r && console.error("unable to copy using clipboardData: ", u), r && console.error("falling back to prompt"), o = C("message" in t ? t.message : b), window.prompt(o, e);
66
- }
67
- } finally {
68
- s && (typeof s.removeRange == "function" ? s.removeRange(n) : s.removeAllRanges()), a && document.body.removeChild(a), c();
69
- }
70
- return i;
71
- }
72
- var w = x;
73
- const D = /* @__PURE__ */ y(w);
74
- function S(e, t) {
75
- const [r, o] = d();
76
- return [m(() => {
77
- let n;
78
- typeof e == "number" || typeof e == "string" ? n = e.toString() : e.current instanceof HTMLInputElement ? n = e.current.value : e.current instanceof HTMLElement && (n = e.current.textContent);
79
- const s = D(n);
80
- o(s), t && setTimeout(o, t);
81
- }, [e, t]), r];
2
+ import { f as y } from "./format-bytes-gST0dTWd.mjs";
3
+ import { h as C } from "./hex-to-rgba-BIDK-3ab.mjs";
4
+ import { F as S, d as T } from "./field-styles-CfVLcVQp.mjs";
5
+ import { o as h } from "./overflow-ellipsis-DGV5Kgt-.mjs";
6
+ import { t as L } from "./throttle-BDBzFeFj.mjs";
7
+ import { useState as p, useCallback as a } from "react";
8
+ import { c as i } from "./index-BhcLigYU.mjs";
9
+ import { s as g, u as v } from "./use-fork-ref-CUZErtAC.mjs";
10
+ import { u as k } from "./use-isomorphic-layout-effect-Izr-e2pi.mjs";
11
+ import { u as B } from "./use-viewport-CfklieD-.mjs";
12
+ function c(e, r) {
13
+ const [s, t] = p();
14
+ return [a(() => {
15
+ let o;
16
+ typeof e == "number" || typeof e == "string" ? o = e.toString() : e.current instanceof HTMLInputElement ? o = e.current.value : e.current instanceof HTMLElement && (o = e.current.textContent);
17
+ const f = i(o);
18
+ t(f), r && setTimeout(t, r);
19
+ }, [e, r]), s];
82
20
  }
83
21
  export {
84
- U as FIELD_ICON_SIZE,
85
- L as defaultFieldStyles,
86
- k as formatBytes,
87
- A as hexToRGBA,
88
- N as overflowEllipsis,
89
- B as setRef,
90
- P as throttle,
91
- S as useCopyText,
92
- _ as useForkRef,
93
- G as useIsomorphicLayoutEffect,
94
- O as useViewportSize
22
+ S as FIELD_ICON_SIZE,
23
+ T as defaultFieldStyles,
24
+ y as formatBytes,
25
+ C as hexToRGBA,
26
+ h as overflowEllipsis,
27
+ g as setRef,
28
+ L as throttle,
29
+ c as useCopyText,
30
+ v as useForkRef,
31
+ k as useIsomorphicLayoutEffect,
32
+ B as useViewportSize
95
33
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "welcome-ui",
3
- "version": "8.0.0-alpha.0",
3
+ "version": "8.0.2",
4
4
  "description": "Customizable design system with react • styled-components • styled-system and ariakit.",
5
5
  "files": [
6
6
  "dist"
@@ -26,7 +26,7 @@
26
26
  "scripts": {
27
27
  "start": "vite build --watch",
28
28
  "build": "vite build",
29
- "test": "yarn jest"
29
+ "test": "vitest"
30
30
  },
31
31
  "repository": {
32
32
  "type": "git",
@@ -51,8 +51,8 @@
51
51
  },
52
52
  "dependencies": {
53
53
  "@ariakit/react": "0.4.15",
54
- "@juggle/resize-observer": "^3.4.0",
55
54
  "@emotion/is-prop-valid": "^1.3.1",
55
+ "@juggle/resize-observer": "^3.4.0",
56
56
  "copy-to-clipboard": "^3.3.3",
57
57
  "date-fns": "^4.1.0",
58
58
  "downshift": "^7.4.1",
@@ -68,7 +68,7 @@
68
68
  },
69
69
  "devDependencies": {
70
70
  "@babel/cli": "7.25.9",
71
- "@babel/core": "7.25.2",
71
+ "@babel/core": "7.26.10",
72
72
  "@babel/eslint-parser": "^7.25.1",
73
73
  "@babel/plugin-proposal-class-properties": "7.18.6",
74
74
  "@babel/plugin-proposal-optional-chaining": "7.21.0",
@@ -80,8 +80,7 @@
80
80
  "@testing-library/dom": "^10.4.0",
81
81
  "@testing-library/jest-dom": "^6.6.3",
82
82
  "@testing-library/react": "^16.2.0",
83
- "@testing-library/user-event": "^14.5.2",
84
- "@types/jest": "^29.5.13",
83
+ "@testing-library/user-event": "^14.6.1",
85
84
  "@types/lodash.capitalize": "^4.2.9",
86
85
  "@types/lodash.debounce": "^4.0.6",
87
86
  "@types/lodash.range": "^3.2.9",
@@ -91,29 +90,27 @@
91
90
  "@types/react-datepicker": "^4.15.0",
92
91
  "@types/react-dom": "18.3.1",
93
92
  "@xstyled/styled-components": "^4.0.0",
94
- "babel-jest": "^29.7.0",
95
93
  "babel-plugin-annotate-pure-calls": "^0.4.0",
96
94
  "babel-plugin-styled-components": "^2.1.4",
97
95
  "babel-plugin-transform-async-to-promises": "^0.8.18",
98
96
  "babel-preset-vite": "^1.1.3",
99
- "jest": "29.7.0",
100
- "jest-environment-jsdom": "^29.7.0",
101
- "jest-styled-components": "7.2.0",
97
+ "jsdom": "^26.0.0",
102
98
  "ramda": "^0.30.1",
103
99
  "react": "^18.3.1",
104
100
  "release-it": "^18.1.2",
105
101
  "rollup-preserve-directives": "^1.1.3",
106
102
  "styled-components": "^6.1.15",
107
103
  "typescript": "^5.6.3",
108
- "vite": "^5.4.10",
109
- "vite-plugin-dts": "^4.3.0",
110
- "vite-plugin-static-copy": "^2.2.0",
111
- "wttj-config": "^3.0.1"
104
+ "vite": "^6.2.1",
105
+ "vite-plugin-dts": "^4.5.3",
106
+ "vite-plugin-static-copy": "^2.3.0",
107
+ "vitest": "^3.0.8",
108
+ "wttj-config": "3.1.2"
112
109
  },
113
110
  "peerDependencies": {
114
111
  "@xstyled/styled-components": "^4.0.0",
115
112
  "react": "^18.3.1",
116
- "styled-components": "^6.1.5"
113
+ "styled-components": "^6.1.15"
117
114
  },
118
115
  "resolutions": {
119
116
  "@babel/traverse": ">=7.23.2"
@@ -1,25 +0,0 @@
1
- "use client";
2
- import { u } from "./P4IRICAX-DzXqUYe-.mjs";
3
- import { a as c } from "./VGCJ63VH-B39w1tBw.mjs";
4
- import { c as l, _ as p, i as D, g as a, s as m, f as g, h as v } from "./LVA2YJMS-qFC9J-lt.mjs";
5
- var f = "button", d = l(
6
- function(r) {
7
- var s = r, { store: o } = s, e = p(s, ["store"]);
8
- const i = c();
9
- o = o || i, D(
10
- o,
11
- process.env.NODE_ENV !== "production" && "DialogDisclosure must receive a `store` prop or be wrapped in a DialogProvider component."
12
- );
13
- const n = o.useState("contentElement");
14
- return e = a({
15
- "aria-haspopup": m(n, "dialog")
16
- }, e), e = u(a({ store: o }, e)), e;
17
- }
18
- ), P = g(function(r) {
19
- const s = d(r);
20
- return v(f, s);
21
- });
22
- export {
23
- P as D,
24
- d as u
25
- };
@@ -1,61 +0,0 @@
1
- "use client";
2
- import { c as F, _ as d, k as p, l as I, a as O, b as N, m as x, n as Y, o as j, q as H, p as _, d as L, e as V, g as T, r as z, f as G, h as J } from "./LVA2YJMS-qFC9J-lt.mjs";
3
- import { useRef as C, useState as D, useEffect as Q } from "react";
4
- var W = "button";
5
- function M(n) {
6
- if (!n.isTrusted) return !1;
7
- const t = n.currentTarget;
8
- return n.key === "Enter" ? p(t) || t.tagName === "SUMMARY" || t.tagName === "A" : n.key === " " ? p(t) || t.tagName === "SUMMARY" || t.tagName === "INPUT" || t.tagName === "SELECT" : !1;
9
- }
10
- var X = Symbol("command"), Z = F(
11
- function(t) {
12
- var a = t, { clickOnEnter: m = !0, clickOnSpace: o = !0 } = a, r = d(a, ["clickOnEnter", "clickOnSpace"]);
13
- const c = C(null), [K, R] = D(!1);
14
- Q(() => {
15
- c.current && R(p(c.current));
16
- }, []);
17
- const [w, k] = D(!1), f = C(!1), y = I(r), [E, U] = O(r, X, !0), g = r.onKeyDown, v = N((e) => {
18
- g == null || g(e);
19
- const s = e.currentTarget;
20
- if (e.defaultPrevented || E || y || !x(e) || Y(s) || s.isContentEditable) return;
21
- const u = m && e.key === "Enter", i = o && e.key === " ", l = e.key === "Enter" && !m, q = e.key === " " && !o;
22
- if (l || q) {
23
- e.preventDefault();
24
- return;
25
- }
26
- if (u || i) {
27
- const b = M(e);
28
- if (u) {
29
- if (!b) {
30
- e.preventDefault();
31
- const A = e, B = d(A, ["view"]), S = () => _(s, B);
32
- j() ? H(s, "keyup", S) : queueMicrotask(S);
33
- }
34
- } else i && (f.current = !0, b || (e.preventDefault(), k(!0)));
35
- }
36
- }), P = r.onKeyUp, h = N((e) => {
37
- if (P == null || P(e), e.defaultPrevented || E || y || e.metaKey) return;
38
- const s = o && e.key === " ";
39
- if (f.current && s && (f.current = !1, !M(e))) {
40
- e.preventDefault(), k(!1);
41
- const u = e.currentTarget, i = e, l = d(i, ["view"]);
42
- queueMicrotask(() => _(u, l));
43
- }
44
- });
45
- return r = L(T(T({
46
- "data-active": w || void 0,
47
- type: K ? "button" : void 0
48
- }, U), r), {
49
- ref: V(c, r.ref),
50
- onKeyDown: v,
51
- onKeyUp: h
52
- }), r = z(r), r;
53
- }
54
- );
55
- G(function(t) {
56
- const a = Z(t);
57
- return J(W, a);
58
- });
59
- export {
60
- Z as u
61
- };
@@ -1,13 +0,0 @@
1
- "use client";
2
- import { D as e, c as r } from "./VGCJ63VH-B39w1tBw.mjs";
3
- import { v as t } from "./LVA2YJMS-qFC9J-lt.mjs";
4
- var o = t(
5
- [r],
6
- [e]
7
- ), i = o.useContext, x = o.useProviderContext, P = o.ContextProvider, n = o.ScopedContextProvider;
8
- export {
9
- n as P,
10
- P as a,
11
- i as b,
12
- x as u
13
- };
@@ -1,84 +0,0 @@
1
- "use client";
2
- import { C as U, a as A, u as T } from "./P2CTZE2T-YPes1GXe.mjs";
3
- import { v as j, c as w, w as z, f as D, _ as H, x as M, j as O, l as $, y as q, b as p, d as B, e as G, g as m, z as J, h as K } from "./LVA2YJMS-qFC9J-lt.mjs";
4
- import { u as L } from "./YV4JVR4I-BGfUf3Nu.mjs";
5
- import { useRef as Q, useEffect as R } from "react";
6
- var v = j(
7
- [A],
8
- [U]
9
- ), V = v.useContext, re = v.useProviderContext, oe = v.ScopedContextProvider, k = "input";
10
- function W(d, r) {
11
- if (r !== void 0)
12
- return d != null && r != null ? r === d : !!r;
13
- }
14
- function X(d, r) {
15
- return d === "input" && (!r || r === "radio");
16
- }
17
- var Y = w(function(r) {
18
- var s = r, {
19
- store: n,
20
- name: c,
21
- value: i,
22
- checked: C
23
- } = s, t = H(s, [
24
- "store",
25
- "name",
26
- "value",
27
- "checked"
28
- ]);
29
- const x = V();
30
- n = n || x;
31
- const u = M(t.id), f = Q(null), a = L(
32
- n,
33
- (e) => C ?? W(i, e == null ? void 0 : e.value)
34
- );
35
- R(() => {
36
- !u || !a || (n == null ? void 0 : n.getState().activeId) === u || n == null || n.setActiveId(u);
37
- }, [n, a, u]);
38
- const P = t.onChange, S = O(f, k), o = X(S, t.type), I = $(t), [_, b] = q();
39
- R(() => {
40
- const e = f.current;
41
- e && (o || (a !== void 0 && (e.checked = a), c !== void 0 && (e.name = c), i !== void 0 && (e.value = `${i}`)));
42
- }, [_, o, a, c, i]);
43
- const l = p((e) => {
44
- if (I) {
45
- e.preventDefault(), e.stopPropagation();
46
- return;
47
- }
48
- (n == null ? void 0 : n.getState().value) !== i && (o || (e.currentTarget.checked = !0, b()), P == null || P(e), !e.defaultPrevented && (n == null || n.setValue(i)));
49
- }), g = t.onClick, F = p((e) => {
50
- g == null || g(e), !e.defaultPrevented && (o || l(e));
51
- }), h = t.onFocus, y = p((e) => {
52
- if (h == null || h(e), e.defaultPrevented || !o || !n) return;
53
- const { moves: E, activeId: N } = n.getState();
54
- E && (u && N !== u || l(e));
55
- });
56
- return t = B(m({
57
- id: u,
58
- role: o ? void 0 : "radio",
59
- type: o ? "radio" : void 0,
60
- "aria-checked": a
61
- }, t), {
62
- ref: G(f, t.ref),
63
- onChange: l,
64
- onClick: F,
65
- onFocus: y
66
- }), t = T(m({
67
- store: n,
68
- clickOnEnter: !o
69
- }, t)), J(m({
70
- name: o ? c : void 0,
71
- value: o ? i : void 0,
72
- checked: a
73
- }, t));
74
- }), ie = z(
75
- D(function(r) {
76
- const s = Y(r);
77
- return K(k, s);
78
- })
79
- );
80
- export {
81
- ie as R,
82
- oe as a,
83
- re as u
84
- };