@phillips/seldon 1.144.0 → 1.145.0

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 (145) hide show
  1. package/dist/_virtual/build.js +4 -0
  2. package/dist/_virtual/defaults.js +4 -0
  3. package/dist/_virtual/encode-new-lines.js +4 -0
  4. package/dist/_virtual/encode-param-value.js +4 -0
  5. package/dist/_virtual/fold-line.js +4 -0
  6. package/dist/_virtual/format-date.js +4 -0
  7. package/dist/_virtual/format-duration.js +4 -0
  8. package/dist/_virtual/format-text.js +4 -0
  9. package/dist/_virtual/format.js +4 -0
  10. package/dist/_virtual/index.browser.js +6 -0
  11. package/dist/_virtual/index.cjs.production.min.js +4 -0
  12. package/dist/_virtual/index.esm.js +6 -0
  13. package/dist/_virtual/index10.js +4 -0
  14. package/dist/_virtual/index11.js +4 -0
  15. package/dist/_virtual/index12.js +4 -0
  16. package/dist/_virtual/index7.js +4 -0
  17. package/dist/_virtual/index8.js +4 -0
  18. package/dist/_virtual/index9.js +4 -0
  19. package/dist/_virtual/set-alarm.js +4 -0
  20. package/dist/_virtual/set-contact.js +4 -0
  21. package/dist/_virtual/set-description.js +4 -0
  22. package/dist/_virtual/set-geolocation.js +4 -0
  23. package/dist/_virtual/set-location.js +4 -0
  24. package/dist/_virtual/set-organizer.js +4 -0
  25. package/dist/_virtual/set-summary.js +4 -0
  26. package/dist/_virtual/validate.js +4 -0
  27. package/dist/components/AddToCalendar/AddToCalendar.d.ts +10 -0
  28. package/dist/components/AddToCalendar/AddToCalendar.js +62 -0
  29. package/dist/components/AddToCalendar/AddToCalendar.stories.d.ts +25 -0
  30. package/dist/components/AddToCalendar/AddToCalendar.test.d.ts +1 -0
  31. package/dist/components/AddToCalendar/calendarLinks.d.ts +6 -0
  32. package/dist/components/AddToCalendar/calendarLinks.js +89 -0
  33. package/dist/components/AddToCalendar/calendarLinks.test.d.ts +1 -0
  34. package/dist/components/AddToCalendar/index.d.ts +1 -0
  35. package/dist/components/AddToCalendar/types.d.ts +8 -0
  36. package/dist/index.d.ts +1 -0
  37. package/dist/index.js +27 -25
  38. package/dist/node_modules/@radix-ui/react-context/dist/index.js +49 -34
  39. package/dist/node_modules/@radix-ui/react-dialog/dist/index.js +12 -12
  40. package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.js +208 -0
  41. package/dist/node_modules/{cmdk → @radix-ui/react-dropdown-menu}/node_modules/@radix-ui/react-primitive/dist/index.js +7 -6
  42. package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-slot/dist/index.js +49 -0
  43. package/dist/node_modules/@radix-ui/react-dropdown-menu/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +52 -0
  44. package/dist/node_modules/@radix-ui/react-menu/dist/index.js +608 -0
  45. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-arrow/dist/index.js +24 -0
  46. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-collection/dist/index.js +48 -0
  47. package/dist/node_modules/@radix-ui/{react-dialog → react-menu}/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +4 -4
  48. package/dist/node_modules/@radix-ui/{react-dialog → react-menu}/node_modules/@radix-ui/react-focus-scope/dist/index.js +2 -2
  49. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-popper/dist/index.js +218 -0
  50. package/dist/node_modules/@radix-ui/{react-dialog → react-menu}/node_modules/@radix-ui/react-portal/dist/index.js +1 -1
  51. package/dist/node_modules/@radix-ui/{react-dialog → react-menu}/node_modules/@radix-ui/react-presence/dist/index.js +4 -4
  52. package/dist/node_modules/@radix-ui/{react-dialog → react-menu}/node_modules/@radix-ui/react-primitive/dist/index.js +6 -5
  53. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-roving-focus/dist/index.js +183 -0
  54. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.js +49 -0
  55. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +52 -0
  56. package/dist/node_modules/@radix-ui/react-popover/dist/index.js +5 -5
  57. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +4 -4
  58. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-focus-scope/dist/index.js +2 -2
  59. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-popper/dist/index.js +5 -5
  60. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-portal/dist/index.js +1 -1
  61. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-presence/dist/index.js +2 -2
  62. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.js +31 -30
  63. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +1 -1
  64. package/dist/node_modules/cmdk/dist/index.js +2 -2
  65. package/dist/node_modules/date-fns/_lib/addLeadingZeros.js +7 -0
  66. package/dist/node_modules/date-fns/_lib/format/formatters.js +517 -0
  67. package/dist/node_modules/date-fns/_lib/format/lightFormatters.js +59 -0
  68. package/dist/node_modules/date-fns/_lib/format/longFormatters.js +52 -0
  69. package/dist/node_modules/date-fns/_lib/protectedTokens.js +20 -0
  70. package/dist/node_modules/date-fns/addHours.js +9 -0
  71. package/dist/node_modules/date-fns/addMilliseconds.js +9 -0
  72. package/dist/node_modules/date-fns/constants.js +6 -5
  73. package/dist/node_modules/date-fns/format.js +58 -0
  74. package/dist/node_modules/date-fns/getDayOfYear.js +11 -0
  75. package/dist/node_modules/date-fns/getISOWeek.js +12 -0
  76. package/dist/node_modules/date-fns/getISOWeekYear.js +15 -0
  77. package/dist/node_modules/date-fns/getWeek.js +12 -0
  78. package/dist/node_modules/date-fns/getWeekYear.js +16 -0
  79. package/dist/node_modules/date-fns/isDate.js +7 -0
  80. package/dist/node_modules/date-fns/isValid.js +9 -0
  81. package/dist/node_modules/date-fns/startOfISOWeek.js +8 -0
  82. package/dist/node_modules/date-fns/startOfISOWeekYear.js +11 -0
  83. package/dist/node_modules/date-fns/startOfWeekYear.js +12 -0
  84. package/dist/node_modules/date-fns/startOfYear.js +9 -0
  85. package/dist/node_modules/date-fns-tz/dist/esm/_lib/getTimezoneOffsetInMilliseconds/index.js +7 -0
  86. package/dist/node_modules/date-fns-tz/dist/esm/_lib/newDateUTC/index.js +7 -0
  87. package/dist/node_modules/date-fns-tz/dist/esm/_lib/tzParseTimezone/index.js +63 -0
  88. package/dist/node_modules/date-fns-tz/dist/esm/_lib/tzPattern/index.js +4 -0
  89. package/dist/node_modules/date-fns-tz/dist/esm/_lib/tzTokenizeDate/index.js +71 -0
  90. package/dist/node_modules/date-fns-tz/dist/esm/toDate/index.js +180 -0
  91. package/dist/node_modules/date-fns-tz/dist/esm/toZonedTime/index.js +10 -0
  92. package/dist/node_modules/ics/dist/defaults.js +23 -0
  93. package/dist/node_modules/ics/dist/index.js +115 -0
  94. package/dist/node_modules/ics/dist/pipeline/build.js +50 -0
  95. package/dist/node_modules/ics/dist/pipeline/format.js +70 -0
  96. package/dist/node_modules/ics/dist/pipeline/index.js +53 -0
  97. package/dist/node_modules/ics/dist/pipeline/validate.js +17 -0
  98. package/dist/node_modules/ics/dist/schema/index.js +211 -0
  99. package/dist/node_modules/ics/dist/utils/encode-new-lines.js +9 -0
  100. package/dist/node_modules/ics/dist/utils/encode-param-value.js +9 -0
  101. package/dist/node_modules/ics/dist/utils/fold-line.js +14 -0
  102. package/dist/node_modules/ics/dist/utils/format-date.js +68 -0
  103. package/dist/node_modules/ics/dist/utils/format-duration.js +10 -0
  104. package/dist/node_modules/ics/dist/utils/format-text.js +9 -0
  105. package/dist/node_modules/ics/dist/utils/index.js +87 -0
  106. package/dist/node_modules/ics/dist/utils/set-alarm.js +49 -0
  107. package/dist/node_modules/ics/dist/utils/set-contact.js +18 -0
  108. package/dist/node_modules/ics/dist/utils/set-description.js +15 -0
  109. package/dist/node_modules/ics/dist/utils/set-geolocation.js +10 -0
  110. package/dist/node_modules/ics/dist/utils/set-location.js +15 -0
  111. package/dist/node_modules/ics/dist/utils/set-organizer.js +16 -0
  112. package/dist/node_modules/ics/dist/utils/set-summary.js +15 -0
  113. package/dist/node_modules/nanoid/index.browser.js +19 -0
  114. package/dist/node_modules/nanoid/url-alphabet/index.js +4 -0
  115. package/dist/node_modules/property-expr/index.js +77 -0
  116. package/dist/node_modules/runes2/dist/index.cjs.development.js +139 -0
  117. package/dist/node_modules/runes2/dist/index.cjs.production.min.js +86 -0
  118. package/dist/node_modules/runes2/dist/index.js +8 -0
  119. package/dist/node_modules/tiny-case/index.js +17 -0
  120. package/dist/node_modules/toposort/index.js +65 -0
  121. package/dist/node_modules/yup/index.esm.js +1899 -0
  122. package/dist/scss/componentStyles.scss +1 -0
  123. package/dist/scss/components/AddToCalendar/_addToCalendar.scss +64 -0
  124. package/package.json +5 -1
  125. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/primitive/dist/index.js +0 -9
  126. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-compose-refs/dist/index.js +0 -29
  127. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-context/dist/index.js +0 -68
  128. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-focus-guards/dist/index.js +0 -17
  129. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-id/dist/index.js +0 -13
  130. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.js +0 -48
  131. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +0 -10
  132. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +0 -32
  133. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +0 -14
  134. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +0 -6
  135. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/primitive/dist/index.js +0 -9
  136. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-compose-refs/dist/index.js +0 -29
  137. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-context/dist/index.js +0 -53
  138. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-focus-guards/dist/index.js +0 -17
  139. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-id/dist/index.js +0 -13
  140. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +0 -10
  141. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +0 -14
  142. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +0 -6
  143. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-use-size/dist/index.js +0 -27
  144. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-compose-refs/dist/index.js +0 -25
  145. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-slot/dist/index.js +0 -48
@@ -1,7 +1,7 @@
1
1
  import * as d from "react";
2
- import { useComposedRefs as R } from "../../react-compose-refs/dist/index.js";
2
+ import { useComposedRefs as R } from "../../../../../react-compose-refs/dist/index.js";
3
3
  import { Primitive as M } from "../../react-primitive/dist/index.js";
4
- import { useCallbackRef as y } from "../../react-use-callback-ref/dist/index.js";
4
+ import { useCallbackRef as y } from "../../../../../react-use-callback-ref/dist/index.js";
5
5
  import { jsx as _ } from "react/jsx-runtime";
6
6
  var F = "focusScope.autoFocusOnMount", T = "focusScope.autoFocusOnUnmount", N = { bubbles: !1, cancelable: !0 }, K = "FocusScope", k = d.forwardRef((e, t) => {
7
7
  const {
@@ -0,0 +1,218 @@
1
+ import * as s from "react";
2
+ import { useFloating as fe, offset as me, shift as he, limitShift as ge, flip as ue, size as we, arrow as Pe, hide as xe } from "../../../../../../@floating-ui/react-dom/dist/floating-ui.react-dom.js";
3
+ import { Root as ye } from "../../react-arrow/dist/index.js";
4
+ import { useComposedRefs as I } from "../../../../../react-compose-refs/dist/index.js";
5
+ import { createContextScope as Ae } from "../../../../../react-context/dist/index.js";
6
+ import { Primitive as Y } from "../../react-primitive/dist/index.js";
7
+ import { useCallbackRef as ve } from "../../../../../react-use-callback-ref/dist/index.js";
8
+ import { useLayoutEffect as z } from "../../../../../react-use-layout-effect/dist/index.js";
9
+ import { useSize as Ce } from "../../../../../react-use-size/dist/index.js";
10
+ import { jsx as f } from "react/jsx-runtime";
11
+ import { autoUpdate as Se } from "../../../../../../@floating-ui/dom/dist/floating-ui.dom.js";
12
+ var b = "Popper", [M, ke] = Ae(b), [be, X] = M(b), D = (e) => {
13
+ const { __scopePopper: a, children: o } = e, [i, n] = s.useState(null);
14
+ return /* @__PURE__ */ f(be, { scope: a, anchor: i, onAnchorChange: n, children: o });
15
+ };
16
+ D.displayName = b;
17
+ var F = "PopperAnchor", k = s.forwardRef(
18
+ (e, a) => {
19
+ const { __scopePopper: o, virtualRef: i, ...n } = e, t = X(F, o), r = s.useRef(null), g = I(a, r);
20
+ return s.useEffect(() => {
21
+ t.onAnchorChange(i?.current || r.current);
22
+ }), i ? null : /* @__PURE__ */ f(Y.div, { ...n, ref: g });
23
+ }
24
+ );
25
+ k.displayName = F;
26
+ var O = "PopperContent", [Oe, Re] = M(O), B = s.forwardRef(
27
+ (e, a) => {
28
+ const {
29
+ __scopePopper: o,
30
+ side: i = "bottom",
31
+ sideOffset: n = 0,
32
+ align: t = "center",
33
+ alignOffset: r = 0,
34
+ arrowPadding: g = 0,
35
+ avoidCollisions: p = !0,
36
+ collisionBoundary: c = [],
37
+ collisionPadding: u = 0,
38
+ sticky: m = "partial",
39
+ hideWhenDetached: P = !1,
40
+ updatePositionStrategy: x = "optimized",
41
+ onPlaced: l,
42
+ ...d
43
+ } = e, Z = X(O, o), [C, U] = s.useState(null), q = I(a, (w) => U(w)), [S, G] = s.useState(null), R = Ce(S), J = R?.width ?? 0, E = R?.height ?? 0, K = i + (t !== "center" ? "-" + t : ""), Q = typeof u == "number" ? u : { top: 0, right: 0, bottom: 0, left: 0, ...u }, N = Array.isArray(c) ? c : [c], V = N.length > 0, y = {
44
+ padding: Q,
45
+ boundary: N.filter(Ne),
46
+ // with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
47
+ altBoundary: V
48
+ }, { refs: ee, floatingStyles: _, placement: te, isPositioned: A, middlewareData: h } = fe({
49
+ // default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
50
+ strategy: "fixed",
51
+ placement: K,
52
+ whileElementsMounted: (...w) => Se(...w, {
53
+ animationFrame: x === "always"
54
+ }),
55
+ elements: {
56
+ reference: Z.anchor
57
+ },
58
+ middleware: [
59
+ me({ mainAxis: n + E, alignmentAxis: r }),
60
+ p && he({
61
+ mainAxis: !0,
62
+ crossAxis: !1,
63
+ limiter: m === "partial" ? ge() : void 0,
64
+ ...y
65
+ }),
66
+ p && ue({ ...y }),
67
+ we({
68
+ ...y,
69
+ apply: ({ elements: w, rects: W, availableWidth: pe, availableHeight: ce }) => {
70
+ const { width: de, height: le } = W.reference, v = w.floating.style;
71
+ v.setProperty("--radix-popper-available-width", `${pe}px`), v.setProperty("--radix-popper-available-height", `${ce}px`), v.setProperty("--radix-popper-anchor-width", `${de}px`), v.setProperty("--radix-popper-anchor-height", `${le}px`);
72
+ }
73
+ }),
74
+ S && Pe({ element: S, padding: g }),
75
+ _e({ arrowWidth: J, arrowHeight: E }),
76
+ P && xe({ strategy: "referenceHidden", ...y })
77
+ ]
78
+ }), [$, re] = L(te), H = ve(l);
79
+ z(() => {
80
+ A && H?.();
81
+ }, [A, H]);
82
+ const oe = h.arrow?.x, ne = h.arrow?.y, ae = h.arrow?.centerOffset !== 0, [ie, se] = s.useState();
83
+ return z(() => {
84
+ C && se(window.getComputedStyle(C).zIndex);
85
+ }, [C]), /* @__PURE__ */ f(
86
+ "div",
87
+ {
88
+ ref: ee.setFloating,
89
+ "data-radix-popper-content-wrapper": "",
90
+ style: {
91
+ ..._,
92
+ transform: A ? _.transform : "translate(0, -200%)",
93
+ // keep off the page when measuring
94
+ minWidth: "max-content",
95
+ zIndex: ie,
96
+ "--radix-popper-transform-origin": [
97
+ h.transformOrigin?.x,
98
+ h.transformOrigin?.y
99
+ ].join(" "),
100
+ // hide the content if using the hide middleware and should be hidden
101
+ // set visibility to hidden and disable pointer events so the UI behaves
102
+ // as if the PopperContent isn't there at all
103
+ ...h.hide?.referenceHidden && {
104
+ visibility: "hidden",
105
+ pointerEvents: "none"
106
+ }
107
+ },
108
+ dir: e.dir,
109
+ children: /* @__PURE__ */ f(
110
+ Oe,
111
+ {
112
+ scope: o,
113
+ placedSide: $,
114
+ onArrowChange: G,
115
+ arrowX: oe,
116
+ arrowY: ne,
117
+ shouldHideArrow: ae,
118
+ children: /* @__PURE__ */ f(
119
+ Y.div,
120
+ {
121
+ "data-side": $,
122
+ "data-align": re,
123
+ ...d,
124
+ ref: q,
125
+ style: {
126
+ ...d.style,
127
+ // if the PopperContent hasn't been placed yet (not all measurements done)
128
+ // we prevent animations so that users's animation don't kick in too early referring wrong sides
129
+ animation: A ? void 0 : "none"
130
+ }
131
+ }
132
+ )
133
+ }
134
+ )
135
+ }
136
+ );
137
+ }
138
+ );
139
+ B.displayName = O;
140
+ var T = "PopperArrow", Ee = {
141
+ top: "bottom",
142
+ right: "left",
143
+ bottom: "top",
144
+ left: "right"
145
+ }, j = s.forwardRef(function(a, o) {
146
+ const { __scopePopper: i, ...n } = a, t = Re(T, i), r = Ee[t.placedSide];
147
+ return (
148
+ // we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)
149
+ // doesn't report size as we'd expect on SVG elements.
150
+ // it reports their bounding box which is effectively the largest path inside the SVG.
151
+ /* @__PURE__ */ f(
152
+ "span",
153
+ {
154
+ ref: t.onArrowChange,
155
+ style: {
156
+ position: "absolute",
157
+ left: t.arrowX,
158
+ top: t.arrowY,
159
+ [r]: 0,
160
+ transformOrigin: {
161
+ top: "",
162
+ right: "0 0",
163
+ bottom: "center 0",
164
+ left: "100% 0"
165
+ }[t.placedSide],
166
+ transform: {
167
+ top: "translateY(100%)",
168
+ right: "translateY(50%) rotate(90deg) translateX(-50%)",
169
+ bottom: "rotate(180deg)",
170
+ left: "translateY(50%) rotate(-90deg) translateX(50%)"
171
+ }[t.placedSide],
172
+ visibility: t.shouldHideArrow ? "hidden" : void 0
173
+ },
174
+ children: /* @__PURE__ */ f(
175
+ ye,
176
+ {
177
+ ...n,
178
+ ref: o,
179
+ style: {
180
+ ...n.style,
181
+ // ensures the element can be measured correctly (mostly for if SVG)
182
+ display: "block"
183
+ }
184
+ }
185
+ )
186
+ }
187
+ )
188
+ );
189
+ });
190
+ j.displayName = T;
191
+ function Ne(e) {
192
+ return e !== null;
193
+ }
194
+ var _e = (e) => ({
195
+ name: "transformOrigin",
196
+ options: e,
197
+ fn(a) {
198
+ const { placement: o, rects: i, middlewareData: n } = a, r = n.arrow?.centerOffset !== 0, g = r ? 0 : e.arrowWidth, p = r ? 0 : e.arrowHeight, [c, u] = L(o), m = { start: "0%", center: "50%", end: "100%" }[u], P = (n.arrow?.x ?? 0) + g / 2, x = (n.arrow?.y ?? 0) + p / 2;
199
+ let l = "", d = "";
200
+ return c === "bottom" ? (l = r ? m : `${P}px`, d = `${-p}px`) : c === "top" ? (l = r ? m : `${P}px`, d = `${i.floating.height + p}px`) : c === "right" ? (l = `${-p}px`, d = r ? m : `${x}px`) : c === "left" && (l = `${i.floating.width + p}px`, d = r ? m : `${x}px`), { data: { x: l, y: d } };
201
+ }
202
+ });
203
+ function L(e) {
204
+ const [a, o = "center"] = e.split("-");
205
+ return [a, o];
206
+ }
207
+ var Be = D, Te = k, je = B, Le = j;
208
+ export {
209
+ Te as Anchor,
210
+ Le as Arrow,
211
+ je as Content,
212
+ D as Popper,
213
+ k as PopperAnchor,
214
+ j as PopperArrow,
215
+ B as PopperContent,
216
+ Be as Root,
217
+ ke as createPopperScope
218
+ };
@@ -1,7 +1,7 @@
1
1
  import * as o from "react";
2
2
  import n from "react-dom";
3
3
  import { Primitive as s } from "../../react-primitive/dist/index.js";
4
- import { useLayoutEffect as c } from "../../react-use-layout-effect/dist/index.js";
4
+ import { useLayoutEffect as c } from "../../../../../react-use-layout-effect/dist/index.js";
5
5
  import { jsx as u } from "react/jsx-runtime";
6
6
  var l = "Portal", p = o.forwardRef((r, e) => {
7
7
  const { container: a, ...f } = r, [i, m] = o.useState(!1);
@@ -1,6 +1,6 @@
1
1
  import * as i from "react";
2
- import { useComposedRefs as O } from "../../react-compose-refs/dist/index.js";
3
- import { useLayoutEffect as A } from "../../react-use-layout-effect/dist/index.js";
2
+ import { useComposedRefs as O } from "../../../../../react-compose-refs/dist/index.js";
3
+ import { useLayoutEffect as A } from "../../../../../react-use-layout-effect/dist/index.js";
4
4
  function E(n, e) {
5
5
  return i.useReducer((t, r) => e[t][r] ?? t, n);
6
6
  }
@@ -10,7 +10,7 @@ var T = (n) => {
10
10
  };
11
11
  T.displayName = "Presence";
12
12
  function R(n) {
13
- const [e, t] = i.useState(), r = i.useRef({}), a = i.useRef(n), c = i.useRef("none"), p = n ? "mounted" : "unmounted", [N, s] = E(p, {
13
+ const [e, t] = i.useState(), r = i.useRef(null), a = i.useRef(n), c = i.useRef("none"), p = n ? "mounted" : "unmounted", [N, s] = E(p, {
14
14
  mounted: {
15
15
  UNMOUNT: "unmounted",
16
16
  ANIMATION_OUT: "unmountSuspended"
@@ -54,7 +54,7 @@ function R(n) {
54
54
  }, [e, s]), {
55
55
  isPresent: ["mounted", "unmountSuspended"].includes(N),
56
56
  ref: i.useCallback((o) => {
57
- o && (r.current = getComputedStyle(o)), t(o);
57
+ r.current = o ? getComputedStyle(o) : null, t(o);
58
58
  }, [])
59
59
  };
60
60
  }
@@ -1,8 +1,8 @@
1
1
  import * as f from "react";
2
2
  import * as p from "react-dom";
3
3
  import { createSlot as c } from "../../react-slot/dist/index.js";
4
- import { jsx as u } from "react/jsx-runtime";
5
- var l = [
4
+ import { jsx as l } from "react/jsx-runtime";
5
+ var u = [
6
6
  "a",
7
7
  "button",
8
8
  "div",
@@ -16,13 +16,14 @@ var l = [
16
16
  "nav",
17
17
  "ol",
18
18
  "p",
19
+ "select",
19
20
  "span",
20
21
  "svg",
21
22
  "ul"
22
- ], h = l.reduce((t, i) => {
23
+ ], h = u.reduce((t, i) => {
23
24
  const o = c(`Primitive.${i}`), r = f.forwardRef((e, m) => {
24
- const { asChild: a, ...s } = e, n = a ? o : i;
25
- return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ u(n, { ...s, ref: m });
25
+ const { asChild: s, ...a } = e, n = s ? o : i;
26
+ return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ l(n, { ...a, ref: m });
26
27
  });
27
28
  return r.displayName = `Primitive.${i}`, { ...t, [i]: r };
28
29
  }, {});
@@ -0,0 +1,183 @@
1
+ import * as c from "react";
2
+ import { composeEventHandlers as p } from "../../../../../primitive/dist/index.js";
3
+ import { createCollection as V } from "../../react-collection/dist/index.js";
4
+ import { useComposedRefs as j } from "../../../../../react-compose-refs/dist/index.js";
5
+ import { createContextScope as z } from "../../../../../react-context/dist/index.js";
6
+ import { useId as q } from "../../../../../react-id/dist/index.js";
7
+ import { Primitive as G } from "../../react-primitive/dist/index.js";
8
+ import { useCallbackRef as J } from "../../../../../react-use-callback-ref/dist/index.js";
9
+ import { useControllableState as Q } from "../../react-use-controllable-state/dist/index.js";
10
+ import { useDirection as W } from "../../../../../react-direction/dist/index.js";
11
+ import { jsx as d } from "react/jsx-runtime";
12
+ var y = "rovingFocusGroup.onEntryFocus", X = { bubbles: !1, cancelable: !0 }, I = "RovingFocusGroup", [D, N, Z] = V(I), [$, Fe] = z(
13
+ I,
14
+ [Z]
15
+ ), [ee, oe] = $(I), O = c.forwardRef(
16
+ (e, r) => /* @__PURE__ */ d(D.Provider, { scope: e.__scopeRovingFocusGroup, children: /* @__PURE__ */ d(D.Slot, { scope: e.__scopeRovingFocusGroup, children: /* @__PURE__ */ d(te, { ...e, ref: r }) }) })
17
+ );
18
+ O.displayName = I;
19
+ var te = c.forwardRef((e, r) => {
20
+ const {
21
+ __scopeRovingFocusGroup: s,
22
+ orientation: o,
23
+ loop: T = !1,
24
+ dir: w,
25
+ currentTabStopId: v,
26
+ defaultCurrentTabStopId: C,
27
+ onCurrentTabStopIdChange: S,
28
+ onEntryFocus: m,
29
+ preventScrollOnEntryFocus: u = !1,
30
+ ...b
31
+ } = e, F = c.useRef(null), g = j(r, F), R = W(w), [E, t] = Q({
32
+ prop: v,
33
+ defaultProp: C ?? null,
34
+ onChange: S,
35
+ caller: I
36
+ }), [i, h] = c.useState(!1), a = J(m), l = N(s), A = c.useRef(!1), [L, P] = c.useState(0);
37
+ return c.useEffect(() => {
38
+ const n = F.current;
39
+ if (n)
40
+ return n.addEventListener(y, a), () => n.removeEventListener(y, a);
41
+ }, [a]), /* @__PURE__ */ d(
42
+ ee,
43
+ {
44
+ scope: s,
45
+ orientation: o,
46
+ dir: R,
47
+ loop: T,
48
+ currentTabStopId: E,
49
+ onItemFocus: c.useCallback(
50
+ (n) => t(n),
51
+ [t]
52
+ ),
53
+ onItemShiftTab: c.useCallback(() => h(!0), []),
54
+ onFocusableItemAdd: c.useCallback(
55
+ () => P((n) => n + 1),
56
+ []
57
+ ),
58
+ onFocusableItemRemove: c.useCallback(
59
+ () => P((n) => n - 1),
60
+ []
61
+ ),
62
+ children: /* @__PURE__ */ d(
63
+ G.div,
64
+ {
65
+ tabIndex: i || L === 0 ? -1 : 0,
66
+ "data-orientation": o,
67
+ ...b,
68
+ ref: g,
69
+ style: { outline: "none", ...e.style },
70
+ onMouseDown: p(e.onMouseDown, () => {
71
+ A.current = !0;
72
+ }),
73
+ onFocus: p(e.onFocus, (n) => {
74
+ const U = !A.current;
75
+ if (n.target === n.currentTarget && U && !i) {
76
+ const x = new CustomEvent(y, X);
77
+ if (n.currentTarget.dispatchEvent(x), !x.defaultPrevented) {
78
+ const _ = l().filter((f) => f.focusable), B = _.find((f) => f.active), Y = _.find((f) => f.id === E), H = [B, Y, ..._].filter(
79
+ Boolean
80
+ ).map((f) => f.ref.current);
81
+ k(H, u);
82
+ }
83
+ }
84
+ A.current = !1;
85
+ }),
86
+ onBlur: p(e.onBlur, () => h(!1))
87
+ }
88
+ )
89
+ }
90
+ );
91
+ }), K = "RovingFocusGroupItem", M = c.forwardRef(
92
+ (e, r) => {
93
+ const {
94
+ __scopeRovingFocusGroup: s,
95
+ focusable: o = !0,
96
+ active: T = !1,
97
+ tabStopId: w,
98
+ children: v,
99
+ ...C
100
+ } = e, S = q(), m = w || S, u = oe(K, s), b = u.currentTabStopId === m, F = N(s), { onFocusableItemAdd: g, onFocusableItemRemove: R, currentTabStopId: E } = u;
101
+ return c.useEffect(() => {
102
+ if (o)
103
+ return g(), () => R();
104
+ }, [o, g, R]), /* @__PURE__ */ d(
105
+ D.ItemSlot,
106
+ {
107
+ scope: s,
108
+ id: m,
109
+ focusable: o,
110
+ active: T,
111
+ children: /* @__PURE__ */ d(
112
+ G.span,
113
+ {
114
+ tabIndex: b ? 0 : -1,
115
+ "data-orientation": u.orientation,
116
+ ...C,
117
+ ref: r,
118
+ onMouseDown: p(e.onMouseDown, (t) => {
119
+ o ? u.onItemFocus(m) : t.preventDefault();
120
+ }),
121
+ onFocus: p(e.onFocus, () => u.onItemFocus(m)),
122
+ onKeyDown: p(e.onKeyDown, (t) => {
123
+ if (t.key === "Tab" && t.shiftKey) {
124
+ u.onItemShiftTab();
125
+ return;
126
+ }
127
+ if (t.target !== t.currentTarget) return;
128
+ const i = ce(t, u.orientation, u.dir);
129
+ if (i !== void 0) {
130
+ if (t.metaKey || t.ctrlKey || t.altKey || t.shiftKey) return;
131
+ t.preventDefault();
132
+ let a = F().filter((l) => l.focusable).map((l) => l.ref.current);
133
+ if (i === "last") a.reverse();
134
+ else if (i === "prev" || i === "next") {
135
+ i === "prev" && a.reverse();
136
+ const l = a.indexOf(t.currentTarget);
137
+ a = u.loop ? se(a, l + 1) : a.slice(l + 1);
138
+ }
139
+ setTimeout(() => k(a));
140
+ }
141
+ }),
142
+ children: typeof v == "function" ? v({ isCurrentTabStop: b, hasTabStop: E != null }) : v
143
+ }
144
+ )
145
+ }
146
+ );
147
+ }
148
+ );
149
+ M.displayName = K;
150
+ var re = {
151
+ ArrowLeft: "prev",
152
+ ArrowUp: "prev",
153
+ ArrowRight: "next",
154
+ ArrowDown: "next",
155
+ PageUp: "first",
156
+ Home: "first",
157
+ PageDown: "last",
158
+ End: "last"
159
+ };
160
+ function ne(e, r) {
161
+ return r !== "rtl" ? e : e === "ArrowLeft" ? "ArrowRight" : e === "ArrowRight" ? "ArrowLeft" : e;
162
+ }
163
+ function ce(e, r, s) {
164
+ const o = ne(e.key, s);
165
+ if (!(r === "vertical" && ["ArrowLeft", "ArrowRight"].includes(o)) && !(r === "horizontal" && ["ArrowUp", "ArrowDown"].includes(o)))
166
+ return re[o];
167
+ }
168
+ function k(e, r = !1) {
169
+ const s = document.activeElement;
170
+ for (const o of e)
171
+ if (o === s || (o.focus({ preventScroll: r }), document.activeElement !== s)) return;
172
+ }
173
+ function se(e, r) {
174
+ return e.map((s, o) => e[(r + o) % e.length]);
175
+ }
176
+ var ge = O, Re = M;
177
+ export {
178
+ Re as Item,
179
+ ge as Root,
180
+ O as RovingFocusGroup,
181
+ M as RovingFocusGroupItem,
182
+ Fe as createRovingFocusGroupScope
183
+ };
@@ -0,0 +1,49 @@
1
+ import * as t from "react";
2
+ import { useComposedRefs as m } from "../../../../../react-compose-refs/dist/index.js";
3
+ import { jsx as u } from "react/jsx-runtime";
4
+ // @__NO_SIDE_EFFECTS__
5
+ function V(e) {
6
+ const r = /* @__PURE__ */ y(e), o = t.forwardRef((l, n) => {
7
+ const { children: i, ...a } = l, c = t.Children.toArray(i), s = c.find(g);
8
+ if (s) {
9
+ const f = s.props.children, d = c.map((p) => p === s ? t.Children.count(f) > 1 ? t.Children.only(null) : t.isValidElement(f) ? f.props.children : null : p);
10
+ return /* @__PURE__ */ u(r, { ...a, ref: n, children: t.isValidElement(f) ? t.cloneElement(f, void 0, d) : null });
11
+ }
12
+ return /* @__PURE__ */ u(r, { ...a, ref: n, children: i });
13
+ });
14
+ return o.displayName = `${e}.Slot`, o;
15
+ }
16
+ // @__NO_SIDE_EFFECTS__
17
+ function y(e) {
18
+ const r = t.forwardRef((o, l) => {
19
+ const { children: n, ...i } = o, a = t.isValidElement(n) ? R(n) : void 0, c = m(a, l);
20
+ if (t.isValidElement(n)) {
21
+ const s = C(i, n.props);
22
+ return n.type !== t.Fragment && (s.ref = c), t.cloneElement(n, s);
23
+ }
24
+ return t.Children.count(n) > 1 ? t.Children.only(null) : null;
25
+ });
26
+ return r.displayName = `${e}.SlotClone`, r;
27
+ }
28
+ var E = Symbol("radix.slottable");
29
+ function g(e) {
30
+ return t.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === E;
31
+ }
32
+ function C(e, r) {
33
+ const o = { ...r };
34
+ for (const l in r) {
35
+ const n = e[l], i = r[l];
36
+ /^on[A-Z]/.test(l) ? n && i ? o[l] = (...c) => {
37
+ const s = i(...c);
38
+ return n(...c), s;
39
+ } : n && (o[l] = n) : l === "style" ? o[l] = { ...n, ...i } : l === "className" && (o[l] = [n, i].filter(Boolean).join(" "));
40
+ }
41
+ return { ...e, ...o };
42
+ }
43
+ function R(e) {
44
+ let r = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, o = r && "isReactWarning" in r && r.isReactWarning;
45
+ return o ? e.ref : (r = Object.getOwnPropertyDescriptor(e, "ref")?.get, o = r && "isReactWarning" in r && r.isReactWarning, o ? e.props.ref : e.props.ref || e.ref);
46
+ }
47
+ export {
48
+ V as createSlot
49
+ };
@@ -0,0 +1,52 @@
1
+ import * as o from "react";
2
+ import { useLayoutEffect as m } from "../../../../../react-use-layout-effect/dist/index.js";
3
+ var v = o[" useInsertionEffect ".trim().toString()] || m;
4
+ function w({
5
+ prop: e,
6
+ defaultProp: s,
7
+ onChange: t = () => {
8
+ },
9
+ caller: f
10
+ }) {
11
+ const [u, c, i] = R({
12
+ defaultProp: s,
13
+ onChange: t
14
+ }), n = e !== void 0, a = n ? e : u;
15
+ {
16
+ const r = o.useRef(e !== void 0);
17
+ o.useEffect(() => {
18
+ const l = r.current;
19
+ l !== n && console.warn(
20
+ `${f} is changing from ${l ? "controlled" : "uncontrolled"} to ${n ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
21
+ ), r.current = n;
22
+ }, [n, f]);
23
+ }
24
+ const d = o.useCallback(
25
+ (r) => {
26
+ if (n) {
27
+ const l = C(r) ? r(e) : r;
28
+ l !== e && i.current?.(l);
29
+ } else
30
+ c(r);
31
+ },
32
+ [n, e, c, i]
33
+ );
34
+ return [a, d];
35
+ }
36
+ function R({
37
+ defaultProp: e,
38
+ onChange: s
39
+ }) {
40
+ const [t, f] = o.useState(e), u = o.useRef(t), c = o.useRef(s);
41
+ return v(() => {
42
+ c.current = s;
43
+ }, [s]), o.useEffect(() => {
44
+ u.current !== t && (c.current?.(t), u.current = t);
45
+ }, [t, u]), [t, f, c];
46
+ }
47
+ function C(e) {
48
+ return typeof e == "function";
49
+ }
50
+ export {
51
+ w as useControllableState
52
+ };
@@ -1,11 +1,11 @@
1
1
  import * as c from "react";
2
- import { composeEventHandlers as P } from "../node_modules/@radix-ui/primitive/dist/index.js";
3
- import { useComposedRefs as O } from "../node_modules/@radix-ui/react-compose-refs/dist/index.js";
4
- import { createContextScope as L } from "../node_modules/@radix-ui/react-context/dist/index.js";
2
+ import { composeEventHandlers as P } from "../../primitive/dist/index.js";
3
+ import { useComposedRefs as O } from "../../react-compose-refs/dist/index.js";
4
+ import { createContextScope as L } from "../../react-context/dist/index.js";
5
5
  import { DismissableLayer as G } from "../node_modules/@radix-ui/react-dismissable-layer/dist/index.js";
6
- import { useFocusGuards as H } from "../node_modules/@radix-ui/react-focus-guards/dist/index.js";
6
+ import { useFocusGuards as H } from "../../react-focus-guards/dist/index.js";
7
7
  import { FocusScope as K } from "../node_modules/@radix-ui/react-focus-scope/dist/index.js";
8
- import { useId as $ } from "../node_modules/@radix-ui/react-id/dist/index.js";
8
+ import { useId as $ } from "../../react-id/dist/index.js";
9
9
  import { createPopperScope as _, Anchor as x, Content as j, Arrow as U, Root as V } from "../node_modules/@radix-ui/react-popper/dist/index.js";
10
10
  import { Portal as W } from "../node_modules/@radix-ui/react-portal/dist/index.js";
11
11
  import { Presence as w } from "../node_modules/@radix-ui/react-presence/dist/index.js";
@@ -1,9 +1,9 @@
1
1
  import * as n from "react";
2
- import { composeEventHandlers as h } from "../../primitive/dist/index.js";
2
+ import { composeEventHandlers as h } from "../../../../../primitive/dist/index.js";
3
3
  import { Primitive as w, dispatchDiscreteCustomEvent as k } from "../../react-primitive/dist/index.js";
4
- import { useComposedRefs as g } from "../../react-compose-refs/dist/index.js";
5
- import { useCallbackRef as R } from "../../react-use-callback-ref/dist/index.js";
6
- import { useEscapeKeydown as U } from "../../react-use-escape-keydown/dist/index.js";
4
+ import { useComposedRefs as g } from "../../../../../react-compose-refs/dist/index.js";
5
+ import { useCallbackRef as R } from "../../../../../react-use-callback-ref/dist/index.js";
6
+ import { useEscapeKeydown as U } from "../../../../../react-use-escape-keydown/dist/index.js";
7
7
  import { jsx as T } from "react/jsx-runtime";
8
8
  var z = "DismissableLayer", y = "dismissableLayer.update", H = "dismissableLayer.pointerDownOutside", M = "dismissableLayer.focusOutside", C, B = n.createContext({
9
9
  layers: /* @__PURE__ */ new Set(),
@@ -1,7 +1,7 @@
1
1
  import * as d from "react";
2
- import { useComposedRefs as R } from "../../react-compose-refs/dist/index.js";
2
+ import { useComposedRefs as R } from "../../../../../react-compose-refs/dist/index.js";
3
3
  import { Primitive as M } from "../../react-primitive/dist/index.js";
4
- import { useCallbackRef as y } from "../../react-use-callback-ref/dist/index.js";
4
+ import { useCallbackRef as y } from "../../../../../react-use-callback-ref/dist/index.js";
5
5
  import { jsx as _ } from "react/jsx-runtime";
6
6
  var F = "focusScope.autoFocusOnMount", T = "focusScope.autoFocusOnUnmount", N = { bubbles: !1, cancelable: !0 }, K = "FocusScope", k = d.forwardRef((e, t) => {
7
7
  const {
@@ -1,12 +1,12 @@
1
1
  import * as s from "react";
2
2
  import { useFloating as fe, offset as me, shift as he, flip as ge, size as ue, arrow as we, hide as Pe, limitShift as xe } from "../../../../../../@floating-ui/react-dom/dist/floating-ui.react-dom.js";
3
3
  import { Root as ye } from "../../react-arrow/dist/index.js";
4
- import { useComposedRefs as I } from "../../react-compose-refs/dist/index.js";
5
- import { createContextScope as Ae } from "../../react-context/dist/index.js";
4
+ import { useComposedRefs as I } from "../../../../../react-compose-refs/dist/index.js";
5
+ import { createContextScope as Ae } from "../../../../../react-context/dist/index.js";
6
6
  import { Primitive as Y } from "../../react-primitive/dist/index.js";
7
- import { useCallbackRef as ve } from "../../react-use-callback-ref/dist/index.js";
8
- import { useLayoutEffect as z } from "../../react-use-layout-effect/dist/index.js";
9
- import { useSize as Ce } from "../../react-use-size/dist/index.js";
7
+ import { useCallbackRef as ve } from "../../../../../react-use-callback-ref/dist/index.js";
8
+ import { useLayoutEffect as z } from "../../../../../react-use-layout-effect/dist/index.js";
9
+ import { useSize as Ce } from "../../../../../react-use-size/dist/index.js";
10
10
  import { jsx as f } from "react/jsx-runtime";
11
11
  import { autoUpdate as Se } from "../../../../../../@floating-ui/dom/dist/floating-ui.dom.js";
12
12
  var b = "Popper", [M, ke] = Ae(b), [be, X] = M(b), D = (e) => {
@@ -1,7 +1,7 @@
1
1
  import * as o from "react";
2
2
  import n from "react-dom";
3
3
  import { Primitive as s } from "../../react-primitive/dist/index.js";
4
- import { useLayoutEffect as c } from "../../react-use-layout-effect/dist/index.js";
4
+ import { useLayoutEffect as c } from "../../../../../react-use-layout-effect/dist/index.js";
5
5
  import { jsx as u } from "react/jsx-runtime";
6
6
  var l = "Portal", p = o.forwardRef((r, e) => {
7
7
  const { container: a, ...f } = r, [i, m] = o.useState(!1);
@@ -1,6 +1,6 @@
1
1
  import * as i from "react";
2
- import { useComposedRefs as O } from "../../react-compose-refs/dist/index.js";
3
- import { useLayoutEffect as A } from "../../react-use-layout-effect/dist/index.js";
2
+ import { useComposedRefs as O } from "../../../../../react-compose-refs/dist/index.js";
3
+ import { useLayoutEffect as A } from "../../../../../react-use-layout-effect/dist/index.js";
4
4
  function E(n, e) {
5
5
  return i.useReducer((t, r) => e[t][r] ?? t, n);
6
6
  }