@cloudoperators/juno-messages-provider 0.2.6 → 0.2.7

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 (3) hide show
  1. package/README.md +13 -5
  2. package/build/index.js +194 -194
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -12,12 +12,12 @@ This lib uses a **context** store based on Zustand to manage the messages. That
12
12
 
13
13
  In order to run this library in your application you need to install also following libraries which are not included in the bundle:
14
14
 
15
- - @cloudoperators/juno-ui-components, recommended version ^2.14.1
16
- - react, recommended version 18.2.0
17
- - zustand, recommended version ^4.5.2
15
+ - @cloudoperators/juno-ui-components
16
+ - react
17
+ - zustand
18
18
 
19
19
  ```bash
20
- yarn add zustand@4.5.2, react@18.2.0 @cloudoperators/juno-ui-components
20
+ pnpm add zustand, react @cloudoperators/juno-ui-components
21
21
  ```
22
22
 
23
23
  ## Usage
@@ -25,7 +25,7 @@ yarn add zustand@4.5.2, react@18.2.0 @cloudoperators/juno-ui-components
25
25
  1. Import this lib
26
26
 
27
27
  ```bash
28
- yarn add @cloudoperators//messages-provider
28
+ pnpm add @cloudoperators//messages-provider
29
29
  ```
30
30
 
31
31
  2. Add the message **MessagesProvider**. Normally it is set on the top of your application so you can use it from everywhere underneath.
@@ -219,3 +219,11 @@ Following variants are available:
219
219
  - success
220
220
 
221
221
  Variant **info** and **success** will be automatically dismissed after 10 seconds by default.
222
+
223
+ ## Contributing
224
+
225
+ We welcome contributions from the community. Please follow our [contribution guidelines](https://github.com/cloudoperators/juno/blob/main/CONTRIBUTING.md) to contribute to this project.
226
+
227
+ ## License
228
+
229
+ Licensed under the [Apache License](LICENSE).
package/build/index.js CHANGED
@@ -1,17 +1,17 @@
1
1
  import * as p from "react";
2
- import V, { createContext as we, useContext as Ee, forwardRef as te, useId as Ne, useMemo as se, Fragment as Je, useRef as ie, useCallback as le, useState as xe, useEffect as Oe, useLayoutEffect as Jr, useReducer as Jl, isValidElement as ql, cloneElement as Xl, createElement as es, useSyncExternalStore as ts } from "react";
2
+ import V, { createContext as we, useContext as Ee, forwardRef as te, useId as Ne, useMemo as se, Fragment as qe, useRef as ie, useCallback as le, useState as xe, useEffect as Oe, useLayoutEffect as qr, useReducer as ql, isValidElement as Jl, cloneElement as Xl, createElement as es, useSyncExternalStore as ts } from "react";
3
3
  import { createStore as ns, useStore as rs } from "zustand";
4
4
  import * as kn from "react-dom";
5
- import { createPortal as qr, flushSync as Re } from "react-dom";
5
+ import { createPortal as Jr, flushSync as Re } from "react-dom";
6
6
  const Wo = (t) => `${t}-${(+/* @__PURE__ */ new Date() + Math.random()).toString(36).slice(-5)}}`, os = (t, n) => ({
7
7
  storeId: Wo("store-"),
8
8
  messages: [],
9
9
  // this is the messages state
10
10
  actions: {
11
11
  addMessage: (e) => {
12
- if (n().messages.findIndex((a) => JSON.stringify(a.text) === JSON.stringify(e.text) && a.variant === e.variant) >= 0) return;
12
+ if (n().messages.findIndex((a) => a.text === e.text && a.variant === e.variant) >= 0) return;
13
13
  const o = n().messages.slice(), i = Wo("message-");
14
- o.push({ id: i, ...e }), t((a) => ({ ...a, messages: o }));
14
+ return o.push({ id: i, ...e }), t((a) => ({ ...a, messages: o })), i;
15
15
  },
16
16
  removeMessage: (e) => {
17
17
  let r = n().messages.slice();
@@ -21,13 +21,13 @@ const Wo = (t) => `${t}-${(+/* @__PURE__ */ new Date() + Math.random()).toString
21
21
  t((e) => ({ ...e, messages: [] }));
22
22
  }
23
23
  }
24
- }), Qi = we(void 0), Tg = ({ children: t }) => /* @__PURE__ */ V.createElement(Qi.Provider, { value: ns(os) }, t), Ji = (t) => {
24
+ }), Qi = we(void 0), Tg = ({ children: t }) => /* @__PURE__ */ V.createElement(Qi.Provider, { value: ns(os) }, t), qi = (t) => {
25
25
  const n = Ee(Qi);
26
26
  if (!n)
27
27
  throw new Error("StoreContext not provided");
28
28
  return rs(n, t);
29
- }, is = () => Ji((t) => t.messages), as = () => Ji((t) => t.actions);
30
- function qi(t) {
29
+ }, is = () => qi((t) => t.messages), as = () => qi((t) => t.actions);
30
+ function Ji(t) {
31
31
  if (Object.prototype.hasOwnProperty.call(t, "__esModule")) return t;
32
32
  var n = t.default;
33
33
  if (typeof n == "function") {
@@ -146,8 +146,8 @@ function ss() {
146
146
  }
147
147
  if (U) {
148
148
  U = console;
149
- var q = U.error, ae = typeof Symbol == "function" && Symbol.toStringTag && D[Symbol.toStringTag] || D.constructor.name || "Object";
150
- return q.call(
149
+ var J = U.error, ae = typeof Symbol == "function" && Symbol.toStringTag && D[Symbol.toStringTag] || D.constructor.name || "Object";
150
+ return J.call(
151
151
  U,
152
152
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
153
153
  ae
@@ -180,14 +180,14 @@ function ss() {
180
180
  return D.key !== void 0;
181
181
  }
182
182
  function l(D, U) {
183
- function q() {
183
+ function J() {
184
184
  I || (I = !0, console.error(
185
185
  "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
186
186
  U
187
187
  ));
188
188
  }
189
- q.isReactWarning = !0, Object.defineProperty(D, "key", {
190
- get: q,
189
+ J.isReactWarning = !0, Object.defineProperty(D, "key", {
190
+ get: J,
191
191
  configurable: !0
192
192
  });
193
193
  }
@@ -197,14 +197,14 @@ function ss() {
197
197
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
198
198
  )), D = this.props.ref, D !== void 0 ? D : null;
199
199
  }
200
- function u(D, U, q, ae, K, de, me, X) {
201
- return q = de.ref, D = {
200
+ function u(D, U, J, ae, K, de, me, X) {
201
+ return J = de.ref, D = {
202
202
  $$typeof: d,
203
203
  type: D,
204
204
  key: U,
205
205
  props: de,
206
206
  _owner: K
207
- }, (q !== void 0 ? q : null) !== null ? Object.defineProperty(D, "ref", {
207
+ }, (J !== void 0 ? J : null) !== null ? Object.defineProperty(D, "ref", {
208
208
  enumerable: !1,
209
209
  get: s
210
210
  }) : Object.defineProperty(D, "ref", { enumerable: !1, value: null }), D._store = {}, Object.defineProperty(D._store, "validated", {
@@ -229,7 +229,7 @@ function ss() {
229
229
  value: X
230
230
  }), Object.freeze && (Object.freeze(D.props), Object.freeze(D)), D;
231
231
  }
232
- function c(D, U, q, ae, K, de, me, X) {
232
+ function c(D, U, J, ae, K, de, me, X) {
233
233
  var B = U.children;
234
234
  if (B !== void 0)
235
235
  if (ae)
@@ -260,13 +260,13 @@ React keys must be passed directly to JSX without using spread:
260
260
  B
261
261
  ), N[B + ae] = !0);
262
262
  }
263
- if (B = null, q !== void 0 && (e(q), B = "" + q), a(U) && (e(U.key), B = "" + U.key), "key" in U) {
264
- q = {};
263
+ if (B = null, J !== void 0 && (e(J), B = "" + J), a(U) && (e(U.key), B = "" + U.key), "key" in U) {
264
+ J = {};
265
265
  for (var he in U)
266
- he !== "key" && (q[he] = U[he]);
267
- } else q = U;
266
+ he !== "key" && (J[he] = U[he]);
267
+ } else J = U;
268
268
  return B && l(
269
- q,
269
+ J,
270
270
  typeof D == "function" ? D.displayName || D.name || "Unknown" : D
271
271
  ), u(
272
272
  D,
@@ -274,7 +274,7 @@ React keys must be passed directly to JSX without using spread:
274
274
  de,
275
275
  K,
276
276
  o(),
277
- q,
277
+ J,
278
278
  me,
279
279
  X
280
280
  );
@@ -294,24 +294,24 @@ React keys must be passed directly to JSX without using spread:
294
294
  h,
295
295
  i
296
296
  )(), Y = z(r(i)), N = {};
297
- wn.Fragment = b, wn.jsx = function(D, U, q, ae, K) {
297
+ wn.Fragment = b, wn.jsx = function(D, U, J, ae, K) {
298
298
  var de = 1e4 > w.recentlyCreatedOwnerStacks++;
299
299
  return c(
300
300
  D,
301
301
  U,
302
- q,
302
+ J,
303
303
  !1,
304
304
  ae,
305
305
  K,
306
306
  de ? Error("react-stack-top-frame") : Z,
307
307
  de ? z(r(D)) : Y
308
308
  );
309
- }, wn.jsxs = function(D, U, q, ae, K) {
309
+ }, wn.jsxs = function(D, U, J, ae, K) {
310
310
  var de = 1e4 > w.recentlyCreatedOwnerStacks++;
311
311
  return c(
312
312
  D,
313
313
  U,
314
- q,
314
+ J,
315
315
  !0,
316
316
  ae,
317
317
  K,
@@ -346,7 +346,7 @@ const fs = {
346
346
  const n = Ee(ms), [e, r] = xe(!1);
347
347
  return Oe(() => {
348
348
  n != null && n.current && r(!0);
349
- }, [n]), e ? qr(/* @__PURE__ */ H.jsx("div", { className: "juno-portal", style: fs, children: t }), n.current || document.body) : null;
349
+ }, [n]), e ? Jr(/* @__PURE__ */ H.jsx("div", { className: "juno-portal", style: fs, children: t }), n.current || document.body) : null;
350
350
  };
351
351
  ps.displayName = "PortalProvider.Portal";
352
352
  const ms = we(void 0), hs = ({
@@ -425,11 +425,11 @@ const ms = we(void 0), hs = ({
425
425
  title: t,
426
426
  titleId: n,
427
427
  ...e
428
- }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z" })), Js = te(Qs), qs = ({
428
+ }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z" })), qs = te(Qs), Js = ({
429
429
  title: t,
430
430
  titleId: n,
431
431
  ...e
432
- }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M20 13H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zM7 19c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM20 3H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1zM7 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z" })), Xs = te(qs), ec = ({
432
+ }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M20 13H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1v-6c0-.55-.45-1-1-1zM7 19c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM20 3H4c-.55 0-1 .45-1 1v6c0 .55.45 1 1 1h16c.55 0 1-.45 1-1V4c0-.55-.45-1-1-1zM7 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z" })), Xs = te(Js), ec = ({
433
433
  title: t,
434
434
  titleId: n,
435
435
  ...e
@@ -533,11 +533,11 @@ const ms = we(void 0), hs = ({
533
533
  title: t,
534
534
  titleId: n,
535
535
  ...e
536
- }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M5 20h14v-2H5v2zm0-10h4v6h6v-6h4l-7-7-7 7z" })), Qc = te(Gc), Jc = ({
536
+ }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M5 20h14v-2H5v2zm0-10h4v6h6v-6h4l-7-7-7 7z" })), Qc = te(Gc), qc = ({
537
537
  title: t,
538
538
  titleId: n,
539
539
  ...e
540
- }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z" })), qc = te(Jc), Xc = ({
540
+ }, r) => /* @__PURE__ */ p.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, viewBox: "0 0 24 24", ref: r, "aria-labelledby": n, ...e }, t ? /* @__PURE__ */ p.createElement("title", { id: n }, t) : null, /* @__PURE__ */ p.createElement("path", { d: "M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z" })), Jc = te(qc), Xc = ({
541
541
  title: t,
542
542
  titleId: n,
543
543
  ...e
@@ -805,7 +805,7 @@ const iu = ({ icon: t, color: n, size: e, title: r, iconClassName: o, ...i }) =>
805
805
  );
806
806
  case "description":
807
807
  return /* @__PURE__ */ H.jsx(
808
- Js,
808
+ qs,
809
809
  {
810
810
  width: e,
811
811
  height: e,
@@ -1195,7 +1195,7 @@ const iu = ({ icon: t, color: n, size: e, title: r, iconClassName: o, ...i }) =>
1195
1195
  );
1196
1196
  case "warning":
1197
1197
  return /* @__PURE__ */ H.jsx(
1198
- qc,
1198
+ Jc,
1199
1199
  {
1200
1200
  width: e,
1201
1201
  height: e,
@@ -1364,10 +1364,10 @@ const iu = ({ icon: t, color: n, size: e, title: r, iconClassName: o, ...i }) =>
1364
1364
  disabled:jn-opacity-50
1365
1365
  disabled:jn-cursor-not-allowed
1366
1366
  disabled:jn-pointer-events-none
1367
- `, Jo = `
1367
+ `, qo = `
1368
1368
  jn-text-sm
1369
1369
  jn-leading-5
1370
- `, qo = `
1370
+ `, Jo = `
1371
1371
  jn-text-base
1372
1372
  jn-leading-6
1373
1373
  `, pu = `
@@ -1431,7 +1431,7 @@ const iu = ({ icon: t, color: n, size: e, title: r, iconClassName: o, ...i }) =>
1431
1431
  juno-button-${v}
1432
1432
  juno-button-${r}-size
1433
1433
  ${Qo}
1434
- ${r === "small" ? Jo : qo}
1434
+ ${r === "small" ? qo : Jo}
1435
1435
  ${Xo(r, e)}
1436
1436
  ${ei(c)}
1437
1437
  ${l}`,
@@ -1456,7 +1456,7 @@ const iu = ({ icon: t, color: n, size: e, title: r, iconClassName: o, ...i }) =>
1456
1456
  juno-button-${v}
1457
1457
  juno-button-${r}-size
1458
1458
  ${Qo}
1459
- ${r === "small" ? Jo : qo}
1459
+ ${r === "small" ? qo : Jo}
1460
1460
  ${Xo(r, e)}
1461
1461
  ${ei(c)}
1462
1462
  ${l}
@@ -2029,8 +2029,8 @@ function Kn(t = {}) {
2029
2029
  focusProps: r ? h : g
2030
2030
  };
2031
2031
  }
2032
- var Qu = Object.defineProperty, Ju = (t, n, e) => n in t ? Qu(t, n, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[n] = e, br = (t, n, e) => (Ju(t, typeof n != "symbol" ? n + "" : n, e), e);
2033
- let qu = class {
2032
+ var Qu = Object.defineProperty, qu = (t, n, e) => n in t ? Qu(t, n, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[n] = e, br = (t, n, e) => (qu(t, typeof n != "symbol" ? n + "" : n, e), e);
2033
+ let Ju = class {
2034
2034
  constructor() {
2035
2035
  br(this, "current", this.detect()), br(this, "handoffState", "pending"), br(this, "currentId", 0);
2036
2036
  }
@@ -2058,7 +2058,7 @@ let qu = class {
2058
2058
  get isHandoffComplete() {
2059
2059
  return this.handoffState === "complete";
2060
2060
  }
2061
- }, Dt = new qu();
2061
+ }, Dt = new Ju();
2062
2062
  function It(t) {
2063
2063
  var n, e;
2064
2064
  return Dt.isServer ? null : t ? "ownerDocument" in t ? t.ownerDocument : "current" in t ? (e = (n = t.current) == null ? void 0 : n.ownerDocument) != null ? e : document : null : document;
@@ -2109,7 +2109,7 @@ function jt() {
2109
2109
  return Oe(() => () => t.dispose(), [t]), t;
2110
2110
  }
2111
2111
  let ve = (t, n) => {
2112
- Dt.isServer ? Oe(t, n) : Jr(t, n);
2112
+ Dt.isServer ? Oe(t, n) : qr(t, n);
2113
2113
  };
2114
2114
  function vt(t) {
2115
2115
  let n = ie(t);
@@ -2198,7 +2198,7 @@ function yn(t, n = {}, e, r, o) {
2198
2198
  for (let v of d) g[`data-${v}`] = "";
2199
2199
  }
2200
2200
  }
2201
- if (i === Je && (Object.keys(bt(s)).length > 0 || Object.keys(bt(g)).length > 0)) if (!ql(c) || Array.isArray(c) && c.length > 1) {
2201
+ if (i === qe && (Object.keys(bt(s)).length > 0 || Object.keys(bt(g)).length > 0)) if (!Jl(c) || Array.isArray(c) && c.length > 1) {
2202
2202
  if (Object.keys(bt(s)).length > 0) throw new Error(['Passing props on "Fragment"!', "", `The current component <${r} /> is rendering a "Fragment".`, "However we need to passthrough the following props:", Object.keys(bt(s)).concat(Object.keys(bt(g))).map((h) => ` - ${h}`).join(`
2203
2203
  `), "", "You can apply a few solutions:", ['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".', "Render a single element as the child so that we can forward the props onto that element."].map((h) => ` - ${h}`).join(`
2204
2204
  `)].join(`
@@ -2208,7 +2208,7 @@ function yn(t, n = {}, e, r, o) {
2208
2208
  for (let C in g) C in y && delete g[C];
2209
2209
  return Xl(c, Object.assign({}, y, g, u, { ref: o(ad(c), u.ref) }, b));
2210
2210
  }
2211
- return es(i, Object.assign({}, wr(s, ["ref"]), i !== Je && u, i !== Je && g), c);
2211
+ return es(i, Object.assign({}, wr(s, ["ref"]), i !== qe && u, i !== qe && g), c);
2212
2212
  }
2213
2213
  function od() {
2214
2214
  let t = ie([]), n = le((e) => {
@@ -2311,7 +2311,7 @@ function dd({ children: t }) {
2311
2311
  let n = Ee(ud);
2312
2312
  if (!n) return V.createElement(V.Fragment, null, t);
2313
2313
  let { target: e } = n;
2314
- return e ? qr(V.createElement(V.Fragment, null, t), e) : null;
2314
+ return e ? Jr(V.createElement(V.Fragment, null, t), e) : null;
2315
2315
  }
2316
2316
  function ba({ data: t, form: n, disabled: e, onReset: r, overrides: o }) {
2317
2317
  let [i, a] = xe(null), l = jt();
@@ -2431,10 +2431,10 @@ function Ed(t, n) {
2431
2431
  let Od = Ce(Ed);
2432
2432
  Object.assign(Od, {});
2433
2433
  var ne = ((t) => (t.Space = " ", t.Enter = "Enter", t.Escape = "Escape", t.Backspace = "Backspace", t.Delete = "Delete", t.ArrowLeft = "ArrowLeft", t.ArrowUp = "ArrowUp", t.ArrowRight = "ArrowRight", t.ArrowDown = "ArrowDown", t.Home = "Home", t.End = "End", t.PageUp = "PageUp", t.PageDown = "PageDown", t.Tab = "Tab", t))(ne || {});
2434
- let Jn = we(null);
2435
- Jn.displayName = "LabelContext";
2434
+ let qn = we(null);
2435
+ qn.displayName = "LabelContext";
2436
2436
  function so() {
2437
- let t = Ee(Jn);
2437
+ let t = Ee(qn);
2438
2438
  if (t === null) {
2439
2439
  let n = new Error("You used a <Label /> component, but it is not inside a relevant parent.");
2440
2440
  throw Error.captureStackTrace && Error.captureStackTrace(n, so), n;
@@ -2443,17 +2443,17 @@ function so() {
2443
2443
  }
2444
2444
  function cn(t) {
2445
2445
  var n, e, r;
2446
- let o = (e = (n = Ee(Jn)) == null ? void 0 : n.value) != null ? e : void 0;
2446
+ let o = (e = (n = Ee(qn)) == null ? void 0 : n.value) != null ? e : void 0;
2447
2447
  return ((r = t == null ? void 0 : t.length) != null ? r : 0) > 0 ? [o, ...t].filter(Boolean).join(" ") : o;
2448
2448
  }
2449
- function qn({ inherit: t = !1 } = {}) {
2449
+ function Jn({ inherit: t = !1 } = {}) {
2450
2450
  let n = cn(), [e, r] = xe([]), o = t ? [n, ...e].filter(Boolean) : e;
2451
2451
  return [o.length > 0 ? o.join(" ") : void 0, se(() => function(i) {
2452
2452
  let a = Q((s) => (r((u) => [...u, s]), () => r((u) => {
2453
2453
  let c = u.slice(), g = c.indexOf(s);
2454
2454
  return g !== -1 && c.splice(g, 1), c;
2455
2455
  }))), l = se(() => ({ register: a, slot: i.slot, name: i.name, props: i.props, value: i.value }), [a, i.slot, i.name, i.props, i.value]);
2456
- return V.createElement(Jn.Provider, { value: l }, i.children);
2456
+ return V.createElement(qn.Provider, { value: l }, i.children);
2457
2457
  }, [r])];
2458
2458
  }
2459
2459
  let Dd = "label";
@@ -3037,7 +3037,7 @@ function zd(t) {
3037
3037
  return { width: n, height: e };
3038
3038
  }
3039
3039
  function An(t, n = !1) {
3040
- let [e, r] = Jl(() => ({}), {}), o = se(() => zd(t), [t, e]);
3040
+ let [e, r] = ql(() => ({}), {}), o = se(() => zd(t), [t, e]);
3041
3041
  return ve(() => {
3042
3042
  if (!t) return;
3043
3043
  let i = new ResizeObserver(r);
@@ -3110,7 +3110,7 @@ function ci(t) {
3110
3110
  let n = Object.getPrototypeOf(t);
3111
3111
  return n === null || Object.getPrototypeOf(n) === null;
3112
3112
  }
3113
- function Jt(t) {
3113
+ function qt(t) {
3114
3114
  let [n, e] = t(), r = He();
3115
3115
  return (...o) => {
3116
3116
  n(...o), r.dispose(), r.microTask(e);
@@ -3268,11 +3268,11 @@ var mi;
3268
3268
  function Qd() {
3269
3269
  return mi || (mi = 1, process.env.NODE_ENV === "production" ? Or.exports = Zd() : Or.exports = Gd()), Or.exports;
3270
3270
  }
3271
- var Jd = Qd();
3271
+ var qd = Qd();
3272
3272
  function ue(t, n, e = ka) {
3273
- return Jd.useSyncExternalStoreWithSelector(Q((r) => t.subscribe(qd, r)), Q(() => t.state), Q(() => t.state), Q(n), e);
3273
+ return qd.useSyncExternalStoreWithSelector(Q((r) => t.subscribe(Jd, r)), Q(() => t.state), Q(() => t.state), Q(n), e);
3274
3274
  }
3275
- function qd(t) {
3275
+ function Jd(t) {
3276
3276
  return t;
3277
3277
  }
3278
3278
  function Ia(t, n) {
@@ -3281,16 +3281,16 @@ function Ia(t, n) {
3281
3281
  if (t) return r.actions.push(e), () => r.actions.pop(e);
3282
3282
  }, [r, t, e]), t ? i ? o : !0 : !1;
3283
3283
  }
3284
- let Br = /* @__PURE__ */ new Map(), qt = /* @__PURE__ */ new Map();
3284
+ let Br = /* @__PURE__ */ new Map(), Jt = /* @__PURE__ */ new Map();
3285
3285
  function hi(t) {
3286
3286
  var n;
3287
- let e = (n = qt.get(t)) != null ? n : 0;
3288
- return qt.set(t, e + 1), e !== 0 ? () => gi(t) : (Br.set(t, { "aria-hidden": t.getAttribute("aria-hidden"), inert: t.inert }), t.setAttribute("aria-hidden", "true"), t.inert = !0, () => gi(t));
3287
+ let e = (n = Jt.get(t)) != null ? n : 0;
3288
+ return Jt.set(t, e + 1), e !== 0 ? () => gi(t) : (Br.set(t, { "aria-hidden": t.getAttribute("aria-hidden"), inert: t.inert }), t.setAttribute("aria-hidden", "true"), t.inert = !0, () => gi(t));
3289
3289
  }
3290
3290
  function gi(t) {
3291
3291
  var n;
3292
- let e = (n = qt.get(t)) != null ? n : 1;
3293
- if (e === 1 ? qt.delete(t) : qt.set(t, e - 1), e !== 1) return;
3292
+ let e = (n = Jt.get(t)) != null ? n : 1;
3293
+ if (e === 1 ? Jt.delete(t) : Jt.set(t, e - 1), e !== 1) return;
3294
3294
  let r = Br.get(t);
3295
3295
  r && (r["aria-hidden"] === null ? t.removeAttribute("aria-hidden") : t.setAttribute("aria-hidden", r["aria-hidden"]), t.inert = r.inert, Br.delete(t));
3296
3296
  }
@@ -3776,7 +3776,7 @@ function un(t) {
3776
3776
  overflowX: e,
3777
3777
  overflowY: r,
3778
3778
  display: o
3779
- } = qe(t);
3779
+ } = Je(t);
3780
3780
  return /auto|scroll|overlay|hidden|clip/.test(n + r + e) && !["inline", "contents"].includes(o);
3781
3781
  }
3782
3782
  function Cf(t) {
@@ -3792,7 +3792,7 @@ function ir(t) {
3792
3792
  });
3793
3793
  }
3794
3794
  function wo(t) {
3795
- const n = yo(), e = Fe(t) ? qe(t) : t;
3795
+ const n = yo(), e = Fe(t) ? Je(t) : t;
3796
3796
  return ["transform", "translate", "scale", "rotate", "perspective"].some((r) => e[r] ? e[r] !== "none" : !1) || (e.containerType ? e.containerType !== "normal" : !1) || !n && (e.backdropFilter ? e.backdropFilter !== "none" : !1) || !n && (e.filter ? e.filter !== "none" : !1) || ["transform", "translate", "scale", "rotate", "perspective", "filter"].some((r) => (e.willChange || "").includes(r)) || ["paint", "layout", "strict", "content"].some((r) => (e.contain || "").includes(r));
3797
3797
  }
3798
3798
  function Mf(t) {
@@ -3812,7 +3812,7 @@ function yo() {
3812
3812
  function zt(t) {
3813
3813
  return ["html", "body", "#document"].includes(Bt(t));
3814
3814
  }
3815
- function qe(t) {
3815
+ function Je(t) {
3816
3816
  return Ye(t).getComputedStyle(t);
3817
3817
  }
3818
3818
  function ar(t) {
@@ -4158,12 +4158,12 @@ var Va = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
4158
4158
  if (n = n || {}, !t)
4159
4159
  throw new Error("No node provided");
4160
4160
  return kt.call(t, Rn) === !1 ? !1 : Wr(n, t);
4161
- }, Jf = /* @__PURE__ */ Va.concat("iframe").join(","), Cn = function(t, n) {
4161
+ }, qf = /* @__PURE__ */ Va.concat("iframe").join(","), Cn = function(t, n) {
4162
4162
  if (n = n || {}, !t)
4163
4163
  throw new Error("No node provided");
4164
- return kt.call(t, Jf) === !1 ? !1 : zn(n, t);
4164
+ return kt.call(t, qf) === !1 ? !1 : zn(n, t);
4165
4165
  };
4166
- const qf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4166
+ const Jf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4167
4167
  __proto__: null,
4168
4168
  focusable: Ga,
4169
4169
  getTabIndex: ct,
@@ -4556,7 +4556,7 @@ const np = function(t) {
4556
4556
  };
4557
4557
  };
4558
4558
  function Qa(t) {
4559
- const n = qe(t);
4559
+ const n = Je(t);
4560
4560
  let e = parseFloat(n.width) || 0, r = parseFloat(n.height) || 0;
4561
4561
  const o = it(t), i = o ? t.offsetWidth : e, a = o ? t.offsetHeight : r, l = rn(e) !== i || rn(r) !== a;
4562
4562
  return l && (e = i, r = a), {
@@ -4584,7 +4584,7 @@ function Rt(t) {
4584
4584
  };
4585
4585
  }
4586
4586
  const ip = /* @__PURE__ */ ot(0);
4587
- function Ja(t) {
4587
+ function qa(t) {
4588
4588
  const n = Ye(t);
4589
4589
  return !yo() || !n.visualViewport ? ip : {
4590
4590
  x: n.visualViewport.offsetLeft,
@@ -4599,13 +4599,13 @@ function Tt(t, n, e, r) {
4599
4599
  const o = t.getBoundingClientRect(), i = xo(t);
4600
4600
  let a = ot(1);
4601
4601
  n && (r ? Fe(r) && (a = Rt(r)) : a = Rt(t));
4602
- const l = ap(i, e, r) ? Ja(i) : ot(0);
4602
+ const l = ap(i, e, r) ? qa(i) : ot(0);
4603
4603
  let s = (o.left + l.x) / a.x, u = (o.top + l.y) / a.y, c = o.width / a.x, g = o.height / a.y;
4604
4604
  if (i) {
4605
4605
  const h = Ye(i), d = r && Fe(r) ? Ye(r) : r;
4606
4606
  let v = h, b = $r(v);
4607
4607
  for (; b && r && d !== v; ) {
4608
- const y = Rt(b), C = b.getBoundingClientRect(), S = qe(b), T = C.left + (b.clientLeft + parseFloat(S.paddingLeft)) * y.x, L = C.top + (b.clientTop + parseFloat(S.paddingTop)) * y.y;
4608
+ const y = Rt(b), C = b.getBoundingClientRect(), S = Je(b), T = C.left + (b.clientLeft + parseFloat(S.paddingLeft)) * y.x, L = C.top + (b.clientTop + parseFloat(S.paddingTop)) * y.y;
4609
4609
  s *= y.x, u *= y.y, c *= y.x, g *= y.y, s += T, u += L, v = Ye(b), b = $r(v);
4610
4610
  }
4611
4611
  }
@@ -4620,7 +4620,7 @@ function Eo(t, n) {
4620
4620
  const e = ar(t).scrollLeft;
4621
4621
  return n ? n.left + e : Tt(at(t)).left + e;
4622
4622
  }
4623
- function qa(t, n, e) {
4623
+ function Ja(t, n, e) {
4624
4624
  e === void 0 && (e = !1);
4625
4625
  const r = t.getBoundingClientRect(), o = r.left + n.scrollLeft - (e ? 0 : (
4626
4626
  // RTL <body> scrollbar.
@@ -4650,7 +4650,7 @@ function lp(t) {
4650
4650
  const d = Tt(r);
4651
4651
  u = Rt(r), c.x = d.x + r.clientLeft, c.y = d.y + r.clientTop;
4652
4652
  }
4653
- const h = a && !g && !i ? qa(a, s, !0) : ot(0);
4653
+ const h = a && !g && !i ? Ja(a, s, !0) : ot(0);
4654
4654
  return {
4655
4655
  width: e.width * u.x,
4656
4656
  height: e.height * u.y,
@@ -4665,7 +4665,7 @@ function cp(t) {
4665
4665
  const n = at(t), e = ar(t), r = t.ownerDocument.body, o = Pe(n.scrollWidth, n.clientWidth, r.scrollWidth, r.clientWidth), i = Pe(n.scrollHeight, n.clientHeight, r.scrollHeight, r.clientHeight);
4666
4666
  let a = -e.scrollLeft + Eo(t);
4667
4667
  const l = -e.scrollTop;
4668
- return qe(r).direction === "rtl" && (a += Pe(n.clientWidth, r.clientWidth) - o), {
4668
+ return Je(r).direction === "rtl" && (a += Pe(n.clientWidth, r.clientWidth) - o), {
4669
4669
  width: o,
4670
4670
  height: i,
4671
4671
  x: a,
@@ -4705,7 +4705,7 @@ function Ci(t, n, e) {
4705
4705
  else if (Fe(n))
4706
4706
  r = dp(n, e);
4707
4707
  else {
4708
- const o = Ja(t);
4708
+ const o = qa(t);
4709
4709
  r = {
4710
4710
  x: n.x - o.x,
4711
4711
  y: n.y - o.y,
@@ -4717,17 +4717,17 @@ function Ci(t, n, e) {
4717
4717
  }
4718
4718
  function Xa(t, n) {
4719
4719
  const e = mt(t);
4720
- return e === n || !Fe(e) || zt(e) ? !1 : qe(e).position === "fixed" || Xa(e, n);
4720
+ return e === n || !Fe(e) || zt(e) ? !1 : Je(e).position === "fixed" || Xa(e, n);
4721
4721
  }
4722
4722
  function fp(t, n) {
4723
4723
  const e = n.get(t);
4724
4724
  if (e)
4725
4725
  return e;
4726
4726
  let r = nn(t, [], !1).filter((l) => Fe(l) && Bt(l) !== "body"), o = null;
4727
- const i = qe(t).position === "fixed";
4727
+ const i = Je(t).position === "fixed";
4728
4728
  let a = i ? mt(t) : t;
4729
4729
  for (; Fe(a) && !zt(a); ) {
4730
- const l = qe(a), s = wo(a);
4730
+ const l = Je(a), s = wo(a);
4731
4731
  !s && l.position === "fixed" && (o = null), (i ? !s && !o : !s && l.position === "static" && o && ["absolute", "fixed"].includes(o.position) || un(a) && !s && Xa(t, a)) ? r = r.filter((u) => u !== a) : o = l, a = mt(a);
4732
4732
  }
4733
4733
  return n.set(t, r), r;
@@ -4776,7 +4776,7 @@ function hp(t, n, e) {
4776
4776
  s.x = d.x + n.clientLeft, s.y = d.y + n.clientTop;
4777
4777
  } else o && u();
4778
4778
  i && !r && o && u();
4779
- const c = o && !r && !i ? qa(o, l) : ot(0), g = a.left + l.scrollLeft - s.x - c.x, h = a.top + l.scrollTop - s.y - c.y;
4779
+ const c = o && !r && !i ? Ja(o, l) : ot(0), g = a.left + l.scrollLeft - s.x - c.x, h = a.top + l.scrollTop - s.y - c.y;
4780
4780
  return {
4781
4781
  x: g,
4782
4782
  y: h,
@@ -4785,10 +4785,10 @@ function hp(t, n, e) {
4785
4785
  };
4786
4786
  }
4787
4787
  function Sr(t) {
4788
- return qe(t).position === "static";
4788
+ return Je(t).position === "static";
4789
4789
  }
4790
4790
  function Mi(t, n) {
4791
- if (!it(t) || qe(t).position === "fixed")
4791
+ if (!it(t) || Je(t).position === "fixed")
4792
4792
  return null;
4793
4793
  if (n)
4794
4794
  return n(t);
@@ -4826,7 +4826,7 @@ const gp = async function(t) {
4826
4826
  };
4827
4827
  };
4828
4828
  function vp(t) {
4829
- return qe(t).direction === "rtl";
4829
+ return Je(t).direction === "rtl";
4830
4830
  }
4831
4831
  const bp = {
4832
4832
  convertOffsetParentRelativeRectToViewportRelativeRect: lp,
@@ -4938,7 +4938,7 @@ const Cr = lr, xp = np, Ep = rp, Op = ep, Dp = op, Sp = (t, n, e) => {
4938
4938
  platform: i
4939
4939
  });
4940
4940
  };
4941
- var Mn = typeof document < "u" ? Jr : Oe;
4941
+ var Mn = typeof document < "u" ? qr : Oe;
4942
4942
  function Bn(t, n) {
4943
4943
  if (t === n)
4944
4944
  return !0;
@@ -5112,7 +5112,7 @@ function il(t) {
5112
5112
  return n.current == null ? void 0 : n.current(...r);
5113
5113
  }, []);
5114
5114
  }
5115
- var Ur = typeof document < "u" ? Jr : Oe;
5115
+ var Ur = typeof document < "u" ? qr : Oe;
5116
5116
  let Ti = !1, Np = 0;
5117
5117
  const Ii = () => (
5118
5118
  // Ensure the id is unique with multiple independent versions of Floating UI
@@ -5477,10 +5477,10 @@ function ko({ children: t, enabled: n = !0 }) {
5477
5477
  if (!z) return;
5478
5478
  let I = parseFloat(getComputedStyle(z).scrollPaddingBottom) || 0, $ = Math.min(Pi, z.childElementCount), Z = 0, Y = 0;
5479
5479
  for (let N of (j = (E = T.elements.floating) == null ? void 0 : E.childNodes) != null ? j : []) if (Xe(N)) {
5480
- let D = N.offsetTop, U = D + N.clientHeight + I, q = z.scrollTop, ae = q + z.clientHeight;
5481
- if (D >= q && U <= ae) $--;
5480
+ let D = N.offsetTop, U = D + N.clientHeight + I, J = z.scrollTop, ae = J + z.clientHeight;
5481
+ if (D >= J && U <= ae) $--;
5482
5482
  else {
5483
- Y = Math.max(0, Math.min(U, ae) - Math.max(D, q)), Z = N.clientHeight;
5483
+ Y = Math.max(0, Math.min(U, ae) - Math.max(D, J)), Z = N.clientHeight;
5484
5484
  break;
5485
5485
  }
5486
5486
  }
@@ -5568,7 +5568,7 @@ function Fi(t, n) {
5568
5568
  let r = parseFloat(window.getComputedStyle(e).marginTop) || 0;
5569
5569
  return n.removeChild(e), r;
5570
5570
  }
5571
- function Jp({ children: t, freeze: n }) {
5571
+ function qp({ children: t, freeze: n }) {
5572
5572
  let e = Vn(n, t);
5573
5573
  return V.createElement(V.Fragment, null, e);
5574
5574
  }
@@ -5585,14 +5585,14 @@ function Io() {
5585
5585
  function jo({ value: t, children: n }) {
5586
5586
  return V.createElement(To.Provider, { value: t }, n);
5587
5587
  }
5588
- function qp(t) {
5588
+ function Jp(t) {
5589
5589
  function n() {
5590
5590
  document.readyState !== "loading" && (t(), document.removeEventListener("DOMContentLoaded", n));
5591
5591
  }
5592
5592
  typeof window < "u" && typeof document < "u" && (document.addEventListener("DOMContentLoaded", n), n());
5593
5593
  }
5594
5594
  let yt = [];
5595
- qp(() => {
5595
+ Jp(() => {
5596
5596
  function t(n) {
5597
5597
  if (!ut(n.target) || n.target === document.body || yt[0] === n.target) return;
5598
5598
  let e = n.target;
@@ -5603,7 +5603,7 @@ qp(() => {
5603
5603
  function Xp(t) {
5604
5604
  throw new Error("Unexpected object: " + t);
5605
5605
  }
5606
- var J = ((t) => (t[t.First = 0] = "First", t[t.Previous = 1] = "Previous", t[t.Next = 2] = "Next", t[t.Last = 3] = "Last", t[t.Specific = 4] = "Specific", t[t.Nothing = 5] = "Nothing", t))(J || {});
5606
+ var q = ((t) => (t[t.First = 0] = "First", t[t.Previous = 1] = "Previous", t[t.Next = 2] = "Next", t[t.Last = 3] = "Last", t[t.Specific = 4] = "Specific", t[t.Nothing = 5] = "Nothing", t))(q || {});
5607
5607
  function nt(t, n) {
5608
5608
  let e = n.resolveItems();
5609
5609
  if (e.length <= 0) return null;
@@ -5677,7 +5677,7 @@ function om(t) {
5677
5677
  n || e !== null && o(e.current);
5678
5678
  }, [e, o, n]), r;
5679
5679
  }
5680
- let sl = Je, im = Ce(function(t, n) {
5680
+ let sl = qe, im = Ce(function(t, n) {
5681
5681
  let { ownerDocument: e = null, ...r } = t, o = ie(null), i = Ie(wd((d) => {
5682
5682
  o.current = d;
5683
5683
  }), n), a = pt(o), l = e ?? a, s = om(l), [u] = xe(() => {
@@ -5693,13 +5693,13 @@ let sl = Je, im = Ce(function(t, n) {
5693
5693
  !s || !u || (ao(u) && s.contains(u) && s.removeChild(u), s.childNodes.length <= 0 && ((d = s.parentElement) == null || d.removeChild(s)));
5694
5694
  });
5695
5695
  let h = Se();
5696
- return g ? !s || !u ? null : qr(h({ ourProps: { ref: i }, theirProps: r, slot: {}, defaultTag: sl, name: "Portal" }), u) : null;
5696
+ return g ? !s || !u ? null : Jr(h({ ourProps: { ref: i }, theirProps: r, slot: {}, defaultTag: sl, name: "Portal" }), u) : null;
5697
5697
  });
5698
5698
  function am(t, n) {
5699
5699
  let e = Ie(n), { enabled: r = !0, ownerDocument: o, ...i } = t, a = Se();
5700
5700
  return r ? V.createElement(im, { ...i, ownerDocument: o, ref: e }) : a({ ourProps: { ref: e }, theirProps: i, slot: {}, defaultTag: sl, name: "Portal" });
5701
5701
  }
5702
- let lm = Je, cl = we(null);
5702
+ let lm = qe, cl = we(null);
5703
5703
  function sm(t, n) {
5704
5704
  let { target: e, ...r } = t, o = { ref: Ie(n) }, i = Se();
5705
5705
  return V.createElement(cl.Provider, { value: e }, i({ ourProps: o, theirProps: r, defaultTag: lm, name: "Popover.Group" }));
@@ -5727,7 +5727,7 @@ let mm = { 1(t) {
5727
5727
  var e, r, o, i;
5728
5728
  if ((e = t.dataRef.current) != null && e.disabled || t.optionsElement && !((r = t.dataRef.current) != null && r.optionsPropsRef.current.static) && t.comboboxState === 1) return t;
5729
5729
  if (t.virtual) {
5730
- let { options: u, disabled: c } = t.virtual, g = n.focus === J.Specific ? n.idx : nt(n, { resolveItems: () => u, resolveActiveIndex: () => {
5730
+ let { options: u, disabled: c } = t.virtual, g = n.focus === q.Specific ? n.idx : nt(n, { resolveItems: () => u, resolveActiveIndex: () => {
5731
5731
  var d, v;
5732
5732
  return (v = (d = t.activeOptionIndex) != null ? d : u.findIndex((b) => !c(b))) != null ? v : null;
5733
5733
  }, resolveDisabled: c, resolveId() {
@@ -5740,7 +5740,7 @@ let mm = { 1(t) {
5740
5740
  let u = a.options.findIndex((c) => !c.dataRef.current.disabled);
5741
5741
  u !== -1 && (a.activeOptionIndex = u);
5742
5742
  }
5743
- let l = n.focus === J.Specific ? n.idx : nt(n, { resolveItems: () => a.options, resolveActiveIndex: () => a.activeOptionIndex, resolveId: (u) => u.id, resolveDisabled: (u) => u.dataRef.current.disabled }), s = (i = n.trigger) != null ? i : 2;
5743
+ let l = n.focus === q.Specific ? n.idx : nt(n, { resolveItems: () => a.options, resolveActiveIndex: () => a.activeOptionIndex, resolveId: (u) => u.id, resolveDisabled: (u) => u.dataRef.current.disabled }), s = (i = n.trigger) != null ? i : 2;
5744
5744
  return t.activeOptionIndex === l && t.activationTrigger === s ? t : { ...t, ...a, isTyping: !1, activeOptionIndex: l, activationTrigger: s, __demoMode: !1 };
5745
5745
  }, 4: (t, n) => {
5746
5746
  var e, r, o, i;
@@ -5794,7 +5794,7 @@ let mm = { 1(t) {
5794
5794
  let { dataRef: r } = this.state.options[e];
5795
5795
  this.actions.onChange(r.current.value);
5796
5796
  }
5797
- this.actions.goToOption({ focus: J.Specific, idx: e });
5797
+ this.actions.goToOption({ focus: q.Specific, idx: e });
5798
5798
  }
5799
5799
  }, setInputElement: (e) => {
5800
5800
  this.send({ type: 9, element: e });
@@ -5886,10 +5886,10 @@ function gm(t) {
5886
5886
  d && (g || h !== null && r.length > h && l.scrollToIndex(h));
5887
5887
  } }, c.map((d) => {
5888
5888
  var v;
5889
- return V.createElement(Je, { key: d.key }, V.cloneElement((v = t.children) == null ? void 0 : v.call(t, { ...t.slot, option: r[d.index] }), { key: `${s}-${d.key}`, "data-index": d.index, "aria-setsize": r.length, "aria-posinset": d.index + 1, style: { position: "absolute", top: 0, left: 0, transform: `translateY(${d.start}px)`, overflowAnchor: "none" } }));
5889
+ return V.createElement(qe, { key: d.key }, V.cloneElement((v = t.children) == null ? void 0 : v.call(t, { ...t.slot, option: r[d.index] }), { key: `${s}-${d.key}`, "data-index": d.index, "aria-setsize": r.length, "aria-posinset": d.index + 1, style: { position: "absolute", top: 0, left: 0, transform: `translateY(${d.start}px)`, overflowAnchor: "none" } }));
5890
5890
  })));
5891
5891
  }
5892
- let vm = Je;
5892
+ let vm = qe;
5893
5893
  function bm(t, n) {
5894
5894
  let e = Ne(), r = Zn(), { value: o, defaultValue: i, onChange: a, form: l, name: s, by: u, invalid: c = !1, disabled: g = r || !1, onClose: h, __demoMode: d = !1, multiple: v = !1, immediate: b = !1, virtual: y = null, nullable: C, ...S } = t, T = pa(i), [L = v ? [] : void 0, R] = fa(o, a, T), F = pl({ id: e, virtual: y, __demoMode: d }), A = ie({ static: !1, hold: !1 }), k = Sa(u), P = Q((B) => y ? u === null ? y.options.indexOf(B) : y.options.findIndex((fe) => k(fe, B)) : F.state.options.findIndex((fe) => k(fe.dataRef.current.value, B))), O = le((B) => Te(j.mode, { [$e.Multi]: () => L.some((fe) => k(fe, B)), [$e.Single]: () => k(L, B) }), [L]), w = ue(F, (B) => B.virtual), E = Q(() => h == null ? void 0 : h()), j = se(() => ({ __demoMode: d, immediate: b, optionsPropsRef: A, value: L, defaultValue: T, disabled: g, invalid: c, mode: v ? $e.Multi : $e.Single, virtual: y ? w : null, onChange: R, isSelected: O, calculateIndex: P, compare: k, onClose: E }), [L, T, g, c, v, R, O, d, F, y, w, E]);
5895
5895
  ve(() => {
@@ -5900,16 +5900,16 @@ function bm(t, n) {
5900
5900
  }, [j]);
5901
5901
  let [z, I, $, Z] = ue(F, (B) => [B.comboboxState, B.buttonElement, B.inputElement, B.optionsElement]), Y = At.get(null), N = ue(Y, le((B) => Y.selectors.isTop(B, e), [Y, e]));
5902
5902
  fo(N, [I, $, Z], () => F.actions.closeCombobox());
5903
- let D = ue(F, F.selectors.activeOptionIndex), U = ue(F, F.selectors.activeOption), q = se(() => ({ open: z === pe.Open, disabled: g, invalid: c, activeIndex: D, activeOption: U, value: L }), [j, g, L, c, U, z]), [ae, K] = qn(), de = n === null ? {} : { ref: n }, me = le(() => {
5903
+ let D = ue(F, F.selectors.activeOptionIndex), U = ue(F, F.selectors.activeOption), J = se(() => ({ open: z === pe.Open, disabled: g, invalid: c, activeIndex: D, activeOption: U, value: L }), [j, g, L, c, U, z]), [ae, K] = Jn(), de = n === null ? {} : { ref: n }, me = le(() => {
5904
5904
  if (T !== void 0) return R == null ? void 0 : R(T);
5905
5905
  }, [R, T]), X = Se();
5906
- return V.createElement(K, { value: ae, props: { htmlFor: $ == null ? void 0 : $.id }, slot: { open: z === pe.Open, disabled: g } }, V.createElement(ko, null, V.createElement(an.Provider, { value: j }, V.createElement(fl.Provider, { value: F }, V.createElement(jo, { value: Te(z, { [pe.Open]: We.Open, [pe.Closed]: We.Closed }) }, s != null && V.createElement(ba, { disabled: g, data: L != null ? { [s]: L } : {}, form: l, onReset: me }), X({ ourProps: de, theirProps: S, slot: q, defaultTag: vm, name: "Combobox" }))))));
5906
+ return V.createElement(K, { value: ae, props: { htmlFor: $ == null ? void 0 : $.id }, slot: { open: z === pe.Open, disabled: g } }, V.createElement(ko, null, V.createElement(an.Provider, { value: j }, V.createElement(fl.Provider, { value: F }, V.createElement(jo, { value: Te(z, { [pe.Open]: We.Open, [pe.Closed]: We.Closed }) }, s != null && V.createElement(ba, { disabled: g, data: L != null ? { [s]: L } : {}, form: l, onReset: me }), X({ ourProps: de, theirProps: S, slot: J, defaultTag: vm, name: "Combobox" }))))));
5907
5907
  }
5908
5908
  let wm = "input";
5909
5909
  function ym(t, n) {
5910
5910
  var e, r;
5911
5911
  let o = fn("Combobox.Input"), i = Yt("Combobox.Input"), a = Ne(), l = io(), { id: s = l || `headlessui-combobox-input-${a}`, onChange: u, displayValue: c, disabled: g = i.disabled || !1, autoFocus: h = !1, type: d = "text", ...v } = t, [b] = ue(o, (K) => [K.inputElement]), y = ie(null), C = Ie(y, n, So(), o.actions.setInputElement), S = pt(b), [T, L] = ue(o, (K) => [K.comboboxState, K.isTyping]), R = jt(), F = Q(() => {
5912
- o.actions.onChange(null), o.state.optionsElement && (o.state.optionsElement.scrollTop = 0), o.actions.goToOption({ focus: J.Nothing });
5912
+ o.actions.onChange(null), o.state.optionsElement && (o.state.optionsElement.scrollTop = 0), o.actions.goToOption({ focus: q.Nothing });
5913
5913
  }), A = se(() => {
5914
5914
  var K;
5915
5915
  return typeof c == "function" && i.value !== void 0 ? (K = c(i.value)) != null ? K : "" : typeof i.value == "string" ? i.value : "";
@@ -5948,21 +5948,21 @@ function ym(t, n) {
5948
5948
  o.actions.selectActiveOption(), i.mode === $e.Single && o.actions.closeCombobox();
5949
5949
  break;
5950
5950
  case ne.ArrowDown:
5951
- return K.preventDefault(), K.stopPropagation(), Te(o.state.comboboxState, { [pe.Open]: () => o.actions.goToOption({ focus: J.Next }), [pe.Closed]: () => o.actions.openCombobox() });
5951
+ return K.preventDefault(), K.stopPropagation(), Te(o.state.comboboxState, { [pe.Open]: () => o.actions.goToOption({ focus: q.Next }), [pe.Closed]: () => o.actions.openCombobox() });
5952
5952
  case ne.ArrowUp:
5953
- return K.preventDefault(), K.stopPropagation(), Te(o.state.comboboxState, { [pe.Open]: () => o.actions.goToOption({ focus: J.Previous }), [pe.Closed]: () => {
5954
- Re(() => o.actions.openCombobox()), i.value || o.actions.goToOption({ focus: J.Last });
5953
+ return K.preventDefault(), K.stopPropagation(), Te(o.state.comboboxState, { [pe.Open]: () => o.actions.goToOption({ focus: q.Previous }), [pe.Closed]: () => {
5954
+ Re(() => o.actions.openCombobox()), i.value || o.actions.goToOption({ focus: q.Last });
5955
5955
  } });
5956
5956
  case ne.Home:
5957
5957
  if (K.shiftKey) break;
5958
- return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: J.First });
5958
+ return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: q.First });
5959
5959
  case ne.PageUp:
5960
- return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: J.First });
5960
+ return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: q.First });
5961
5961
  case ne.End:
5962
5962
  if (K.shiftKey) break;
5963
- return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: J.Last });
5963
+ return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: q.Last });
5964
5964
  case ne.PageDown:
5965
- return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: J.Last });
5965
+ return K.preventDefault(), K.stopPropagation(), o.actions.goToOption({ focus: q.Last });
5966
5966
  case ne.Escape:
5967
5967
  return o.state.comboboxState !== pe.Open ? void 0 : (K.preventDefault(), o.state.optionsElement && !i.optionsPropsRef.current.static && K.stopPropagation(), i.mode === $e.Single && i.value === null && F(), o.actions.closeCombobox());
5968
5968
  case ne.Tab:
@@ -5982,8 +5982,8 @@ function ym(t, n) {
5982
5982
  (me = o.state.buttonElement) != null && me.contains(B) || (X = o.state.optionsElement) != null && X.contains(B) || i.disabled || i.immediate && o.state.comboboxState !== pe.Open && R.microTask(() => {
5983
5983
  Re(() => o.actions.openCombobox()), o.actions.setActivationTrigger(ft.Focus);
5984
5984
  });
5985
- }), I = cn(), $ = Ea(), { isFocused: Z, focusProps: Y } = Kn({ autoFocus: h }), { isHovered: N, hoverProps: D } = Un({ isDisabled: g }), U = ue(o, (K) => K.optionsElement), q = se(() => ({ open: T === pe.Open, disabled: g, invalid: i.invalid, hover: N, focus: Z, autofocus: h }), [i, N, Z, h, g, i.invalid]), ae = Nt({ ref: C, id: s, role: "combobox", type: d, "aria-controls": U == null ? void 0 : U.id, "aria-expanded": T === pe.Open, "aria-activedescendant": ue(o, o.selectors.activeDescendantId), "aria-labelledby": I, "aria-describedby": $, "aria-autocomplete": "list", defaultValue: (r = (e = t.defaultValue) != null ? e : i.defaultValue !== void 0 ? c == null ? void 0 : c(i.defaultValue) : null) != null ? r : i.defaultValue, disabled: g || void 0, autoFocus: h, onCompositionStart: P, onCompositionEnd: O, onKeyDown: w, onChange: E, onFocus: z, onBlur: j }, Y, D);
5986
- return Se()({ ourProps: ae, theirProps: v, slot: q, defaultTag: wm, name: "Combobox.Input" });
5985
+ }), I = cn(), $ = Ea(), { isFocused: Z, focusProps: Y } = Kn({ autoFocus: h }), { isHovered: N, hoverProps: D } = Un({ isDisabled: g }), U = ue(o, (K) => K.optionsElement), J = se(() => ({ open: T === pe.Open, disabled: g, invalid: i.invalid, hover: N, focus: Z, autofocus: h }), [i, N, Z, h, g, i.invalid]), ae = Nt({ ref: C, id: s, role: "combobox", type: d, "aria-controls": U == null ? void 0 : U.id, "aria-expanded": T === pe.Open, "aria-activedescendant": ue(o, o.selectors.activeDescendantId), "aria-labelledby": I, "aria-describedby": $, "aria-autocomplete": "list", defaultValue: (r = (e = t.defaultValue) != null ? e : i.defaultValue !== void 0 ? c == null ? void 0 : c(i.defaultValue) : null) != null ? r : i.defaultValue, disabled: g || void 0, autoFocus: h, onCompositionStart: P, onCompositionEnd: O, onKeyDown: w, onChange: E, onFocus: z, onBlur: j }, Y, D);
5986
+ return Se()({ ourProps: ae, theirProps: v, slot: J, defaultTag: wm, name: "Combobox.Input" });
5987
5987
  }
5988
5988
  let xm = "button";
5989
5989
  function Em(t, n) {
@@ -6000,10 +6000,10 @@ function Em(t, n) {
6000
6000
  E.preventDefault(), E.stopPropagation(), e.state.comboboxState === pe.Closed && Re(() => e.actions.openCombobox()), b();
6001
6001
  return;
6002
6002
  case ne.ArrowDown:
6003
- E.preventDefault(), E.stopPropagation(), e.state.comboboxState === pe.Closed && (Re(() => e.actions.openCombobox()), e.state.dataRef.current.value || e.actions.goToOption({ focus: J.First })), b();
6003
+ E.preventDefault(), E.stopPropagation(), e.state.comboboxState === pe.Closed && (Re(() => e.actions.openCombobox()), e.state.dataRef.current.value || e.actions.goToOption({ focus: q.First })), b();
6004
6004
  return;
6005
6005
  case ne.ArrowUp:
6006
- E.preventDefault(), E.stopPropagation(), e.state.comboboxState === pe.Closed && (Re(() => e.actions.openCombobox()), e.state.dataRef.current.value || e.actions.goToOption({ focus: J.Last })), b();
6006
+ E.preventDefault(), E.stopPropagation(), e.state.comboboxState === pe.Closed && (Re(() => e.actions.openCombobox()), e.state.dataRef.current.value || e.actions.goToOption({ focus: q.Last })), b();
6007
6007
  return;
6008
6008
  case ne.Escape:
6009
6009
  if (e.state.comboboxState !== pe.Open) return;
@@ -6041,14 +6041,14 @@ function Sm(t, n) {
6041
6041
  d.actions.setActivationTrigger(ft.Pointer);
6042
6042
  }), U = Q((he) => {
6043
6043
  he.preventDefault(), d.actions.setActivationTrigger(ft.Pointer);
6044
- }), q = Nt(b ? L() : {}, { "aria-labelledby": Y, role: "listbox", "aria-multiselectable": v.mode === $e.Multi ? !0 : void 0, id: a, ref: R, style: { ...h.style, ...C, "--input-width": An(A, !0).width, "--button-width": An(k, !0).width }, onWheel: O === ft.Pointer ? void 0 : D, onMouseDown: U, ...vo(I) }), ae = z && F === pe.Closed, K = Vn(ae, (e = v.virtual) == null ? void 0 : e.options), de = Vn(ae, v.value), me = Q((he) => v.compare(de, he)), X = se(() => {
6044
+ }), J = Nt(b ? L() : {}, { "aria-labelledby": Y, role: "listbox", "aria-multiselectable": v.mode === $e.Multi ? !0 : void 0, id: a, ref: R, style: { ...h.style, ...C, "--input-width": An(A, !0).width, "--button-width": An(k, !0).width }, onWheel: O === ft.Pointer ? void 0 : D, onMouseDown: U, ...vo(I) }), ae = z && F === pe.Closed, K = Vn(ae, (e = v.virtual) == null ? void 0 : e.options), de = Vn(ae, v.value), me = Q((he) => v.compare(de, he)), X = se(() => {
6045
6045
  if (!v.virtual) return v;
6046
6046
  if (K === void 0) throw new Error("Missing `options` in virtual mode");
6047
6047
  return K !== v.virtual.options ? { ...v, virtual: { ...v.virtual, options: K } } : v;
6048
6048
  }, [v, K, (r = v.virtual) == null ? void 0 : r.options]);
6049
6049
  v.virtual && Object.assign(h, { children: V.createElement(an.Provider, { value: X }, V.createElement(gm, { slot: N }, h.children)) });
6050
6050
  let B = Se(), fe = se(() => v.mode === $e.Multi ? v : { ...v, isSelected: me }, [v, me]);
6051
- return V.createElement(Ao, { enabled: u ? t.static || z : !1, ownerDocument: w }, V.createElement(an.Provider, { value: fe }, B({ ourProps: q, theirProps: { ...h, children: V.createElement(Jp, { freeze: ae }, typeof h.children == "function" ? (o = h.children) == null ? void 0 : o.call(h, N) : h.children) }, slot: N, defaultTag: Om, features: Dm, visible: z, name: "Combobox.Options" })));
6051
+ return V.createElement(Ao, { enabled: u ? t.static || z : !1, ownerDocument: w }, V.createElement(an.Provider, { value: fe }, B({ ourProps: J, theirProps: { ...h, children: V.createElement(qp, { freeze: ae }, typeof h.children == "function" ? (o = h.children) == null ? void 0 : o.call(h, N) : h.children) }, slot: N, defaultTag: Om, features: Dm, visible: z, name: "Combobox.Options" })));
6052
6052
  }
6053
6053
  let Cm = "div";
6054
6054
  function Mm(t, n) {
@@ -6067,15 +6067,15 @@ function Mm(t, n) {
6067
6067
  let A = Q((I) => {
6068
6068
  I.preventDefault(), I.button === No.Left && (c || (R(), Vr() || requestAnimationFrame(() => v()), i.mode === $e.Single && a.actions.closeCombobox()));
6069
6069
  }), k = Q(() => {
6070
- if (c) return a.actions.goToOption({ focus: J.Nothing });
6070
+ if (c) return a.actions.goToOption({ focus: q.Nothing });
6071
6071
  let I = i.calculateIndex(u);
6072
- a.actions.goToOption({ focus: J.Specific, idx: I });
6072
+ a.actions.goToOption({ focus: q.Specific, idx: I });
6073
6073
  }), P = go(), O = Q((I) => P.update(I)), w = Q((I) => {
6074
6074
  if (!P.wasMoved(I) || c || b) return;
6075
6075
  let $ = i.calculateIndex(u);
6076
- a.actions.goToOption({ focus: J.Specific, idx: $ }, ft.Pointer);
6076
+ a.actions.goToOption({ focus: q.Specific, idx: $ }, ft.Pointer);
6077
6077
  }), E = Q((I) => {
6078
- P.wasMoved(I) && (c || b && (i.optionsPropsRef.current.hold || a.actions.goToOption({ focus: J.Nothing })));
6078
+ P.wasMoved(I) && (c || b && (i.optionsPropsRef.current.hold || a.actions.goToOption({ focus: q.Nothing })));
6079
6079
  }), j = se(() => ({ active: b, focus: b, selected: y, disabled: c }), [b, y, c]), z = { id: s, ref: L, role: "option", tabIndex: c === !0 ? void 0 : -1, "aria-disabled": c === !0 ? !0 : void 0, "aria-selected": y, disabled: void 0, onMouseDown: A, onFocus: k, onPointerEnter: O, onMouseEnter: O, onPointerMove: w, onMouseMove: w, onPointerLeave: E, onMouseLeave: E };
6080
6080
  return Se()({ ourProps: z, theirProps: h, slot: j, defaultTag: Cm, name: "Combobox.Option" });
6081
6081
  }
@@ -6135,7 +6135,7 @@ function zi(t, n = (e) => e) {
6135
6135
  return o === -1 && (o = null), { options: r, activeOptionIndex: o };
6136
6136
  }
6137
6137
  let Rm = { 1(t) {
6138
- return t.dataRef.current.disabled || t.listboxState === 1 ? t : { ...t, activeOptionIndex: null, pendingFocus: { focus: J.Nothing }, listboxState: 1, __demoMode: !1 };
6138
+ return t.dataRef.current.disabled || t.listboxState === 1 ? t : { ...t, activeOptionIndex: null, pendingFocus: { focus: q.Nothing }, listboxState: 1, __demoMode: !1 };
6139
6139
  }, 0(t, n) {
6140
6140
  if (t.dataRef.current.disabled || t.listboxState === 0) return t;
6141
6141
  let e = t.activeOptionIndex, { isSelected: r } = t.dataRef.current, o = t.options.findIndex((i) => r(i.dataRef.current.value));
@@ -6144,9 +6144,9 @@ let Rm = { 1(t) {
6144
6144
  var e, r, o, i, a;
6145
6145
  if (t.dataRef.current.disabled || t.listboxState === 1) return t;
6146
6146
  let l = { ...t, searchQuery: "", activationTrigger: (e = n.trigger) != null ? e : 1, __demoMode: !1 };
6147
- if (n.focus === J.Nothing) return { ...l, activeOptionIndex: null };
6148
- if (n.focus === J.Specific) return { ...l, activeOptionIndex: t.options.findIndex((c) => c.id === n.id) };
6149
- if (n.focus === J.Previous) {
6147
+ if (n.focus === q.Nothing) return { ...l, activeOptionIndex: null };
6148
+ if (n.focus === q.Specific) return { ...l, activeOptionIndex: t.options.findIndex((c) => c.id === n.id) };
6149
+ if (n.focus === q.Previous) {
6150
6150
  let c = t.activeOptionIndex;
6151
6151
  if (c !== null) {
6152
6152
  let g = t.options[c].dataRef.current.domRef, h = nt(n, { resolveItems: () => t.options, resolveActiveIndex: () => t.activeOptionIndex, resolveId: (d) => d.id, resolveDisabled: (d) => d.dataRef.current.disabled });
@@ -6155,7 +6155,7 @@ let Rm = { 1(t) {
6155
6155
  if (((r = g.current) == null ? void 0 : r.previousElementSibling) === d.current || ((o = d.current) == null ? void 0 : o.previousElementSibling) === null) return { ...l, activeOptionIndex: h };
6156
6156
  }
6157
6157
  }
6158
- } else if (n.focus === J.Next) {
6158
+ } else if (n.focus === q.Next) {
6159
6159
  let c = t.activeOptionIndex;
6160
6160
  if (c !== null) {
6161
6161
  let g = t.options[c].dataRef.current.domRef, h = nt(n, { resolveItems: () => t.options, resolveActiveIndex: () => t.activeOptionIndex, resolveId: (d) => d.id, resolveDisabled: (d) => d.dataRef.current.disabled });
@@ -6178,14 +6178,14 @@ let Rm = { 1(t) {
6178
6178
  return t.dataRef.current.disabled || t.listboxState === 1 || t.searchQuery === "" ? t : { ...t, searchQuery: "" };
6179
6179
  }, 5: (t, n) => {
6180
6180
  let e = t.options.concat(n.options), r = t.activeOptionIndex;
6181
- if (t.pendingFocus.focus !== J.Nothing && (r = nt(t.pendingFocus, { resolveItems: () => e, resolveActiveIndex: () => t.activeOptionIndex, resolveId: (o) => o.id, resolveDisabled: (o) => o.dataRef.current.disabled })), t.activeOptionIndex === null) {
6181
+ if (t.pendingFocus.focus !== q.Nothing && (r = nt(t.pendingFocus, { resolveItems: () => e, resolveActiveIndex: () => t.activeOptionIndex, resolveId: (o) => o.id, resolveDisabled: (o) => o.dataRef.current.disabled })), t.activeOptionIndex === null) {
6182
6182
  let { isSelected: o } = t.dataRef.current;
6183
6183
  if (o) {
6184
6184
  let i = e.findIndex((a) => o == null ? void 0 : o(a.dataRef.current.value));
6185
6185
  i !== -1 && (r = i);
6186
6186
  }
6187
6187
  }
6188
- return { ...t, options: e, activeOptionIndex: r, pendingFocus: { focus: J.Nothing }, pendingShouldSort: !0 };
6188
+ return { ...t, options: e, activeOptionIndex: r, pendingFocus: { focus: q.Nothing }, pendingShouldSort: !0 };
6189
6189
  }, 6: (t, n) => {
6190
6190
  let e = t.options, r = [], o = new Set(n.options);
6191
6191
  for (let [i, a] of e.entries()) if (o.has(a.id) && (r.push(i), o.delete(a.id), o.size === 0)) break;
@@ -6202,17 +6202,17 @@ let Rm = { 1(t) {
6202
6202
  let l = a.slice(), s = l.findIndex((u) => o(u, e));
6203
6203
  return s === -1 ? l.push(e) : l.splice(s, 1), r == null ? void 0 : r(l);
6204
6204
  } });
6205
- }, registerOption: Jt(() => {
6205
+ }, registerOption: qt(() => {
6206
6206
  let e = [], r = /* @__PURE__ */ new Set();
6207
6207
  return [(o, i) => {
6208
6208
  r.has(i) || (r.add(i), e.push({ id: o, dataRef: i }));
6209
6209
  }, () => (r.clear(), this.send({ type: 5, options: e.splice(0) }))];
6210
- }), unregisterOption: Jt(() => {
6210
+ }), unregisterOption: qt(() => {
6211
6211
  let e = [];
6212
6212
  return [(r) => e.push(r), () => {
6213
6213
  this.send({ type: 6, options: e.splice(0) });
6214
6214
  }];
6215
- }), goToOption: Jt(() => {
6215
+ }), goToOption: qt(() => {
6216
6216
  let e = null;
6217
6217
  return [(r, o) => {
6218
6218
  e = { type: 2, ...r, trigger: o };
@@ -6224,7 +6224,7 @@ let Rm = { 1(t) {
6224
6224
  }, selectActiveOption: () => {
6225
6225
  if (this.state.activeOptionIndex !== null) {
6226
6226
  let { dataRef: e, id: r } = this.state.options[this.state.activeOptionIndex];
6227
- this.actions.onChange(e.current.value), this.send({ type: 2, focus: J.Specific, id: r });
6227
+ this.actions.onChange(e.current.value), this.send({ type: 2, focus: q.Specific, id: r });
6228
6228
  }
6229
6229
  }, selectOption: (e) => {
6230
6230
  let r = this.state.options.find((o) => o.id === e);
@@ -6260,7 +6260,7 @@ let Rm = { 1(t) {
6260
6260
  }
6261
6261
  }
6262
6262
  static new({ id: n, __demoMode: e = !1 }) {
6263
- return new bl({ id: n, dataRef: { current: {} }, listboxState: e ? 0 : 1, options: [], searchQuery: "", activeOptionIndex: null, activationTrigger: 1, buttonElement: null, optionsElement: null, pendingShouldSort: !1, pendingFocus: { focus: J.Nothing }, __demoMode: e });
6263
+ return new bl({ id: n, dataRef: { current: {} }, listboxState: e ? 0 : 1, options: [], searchQuery: "", activeOptionIndex: null, activationTrigger: 1, buttonElement: null, optionsElement: null, pendingShouldSort: !1, pendingFocus: { focus: q.Nothing }, __demoMode: e });
6264
6264
  }
6265
6265
  reduce(n, e) {
6266
6266
  return Te(e.type, Rm, n, e);
@@ -6289,19 +6289,19 @@ function pn(t) {
6289
6289
  }
6290
6290
  return n;
6291
6291
  }
6292
- let Hm = Je;
6292
+ let Hm = qe;
6293
6293
  function zm(t, n) {
6294
6294
  let e = Ne(), r = Zn(), { value: o, defaultValue: i, form: a, name: l, onChange: s, by: u, invalid: c = !1, disabled: g = r || !1, horizontal: h = !1, multiple: d = !1, __demoMode: v = !1, ...b } = t;
6295
6295
  const y = h ? "horizontal" : "vertical";
6296
- let C = Ie(n), S = pa(i), [T = d ? [] : void 0, L] = fa(o, s, S), R = yl({ id: e, __demoMode: v }), F = ie({ static: !1, hold: !1 }), A = ie(/* @__PURE__ */ new Map()), k = Sa(u), P = le((q) => Te(O.mode, { [rt.Multi]: () => T.some((ae) => k(ae, q)), [rt.Single]: () => k(T, q) }), [T]), O = se(() => ({ value: T, disabled: g, invalid: c, mode: d ? rt.Multi : rt.Single, orientation: y, onChange: L, compare: k, isSelected: P, optionsPropsRef: F, listRef: A }), [T, g, c, d, y, L, k, P, F, A]);
6296
+ let C = Ie(n), S = pa(i), [T = d ? [] : void 0, L] = fa(o, s, S), R = yl({ id: e, __demoMode: v }), F = ie({ static: !1, hold: !1 }), A = ie(/* @__PURE__ */ new Map()), k = Sa(u), P = le((J) => Te(O.mode, { [rt.Multi]: () => T.some((ae) => k(ae, J)), [rt.Single]: () => k(T, J) }), [T]), O = se(() => ({ value: T, disabled: g, invalid: c, mode: d ? rt.Multi : rt.Single, orientation: y, onChange: L, compare: k, isSelected: P, optionsPropsRef: F, listRef: A }), [T, g, c, d, y, L, k, P, F, A]);
6297
6297
  ve(() => {
6298
6298
  R.state.dataRef.current = O;
6299
6299
  }, [O]);
6300
- let w = ue(R, (q) => q.listboxState), E = At.get(null), j = ue(E, le((q) => E.selectors.isTop(q, e), [E, e])), [z, I] = ue(R, (q) => [q.buttonElement, q.optionsElement]);
6301
- fo(j, [z, I], (q, ae) => {
6302
- R.send({ type: vl.CloseListbox }), nr(ae, tr.Loose) || (q.preventDefault(), z == null || z.focus());
6300
+ let w = ue(R, (J) => J.listboxState), E = At.get(null), j = ue(E, le((J) => E.selectors.isTop(J, e), [E, e])), [z, I] = ue(R, (J) => [J.buttonElement, J.optionsElement]);
6301
+ fo(j, [z, I], (J, ae) => {
6302
+ R.send({ type: vl.CloseListbox }), nr(ae, tr.Loose) || (J.preventDefault(), z == null || z.focus());
6303
6303
  });
6304
- let $ = se(() => ({ open: w === ke.Open, disabled: g, invalid: c, value: T }), [w, g, c, T]), [Z, Y] = qn({ inherit: !0 }), N = { ref: C }, D = le(() => {
6304
+ let $ = se(() => ({ open: w === ke.Open, disabled: g, invalid: c, value: T }), [w, g, c, T]), [Z, Y] = Jn({ inherit: !0 }), N = { ref: C }, D = le(() => {
6305
6305
  if (S !== void 0) return L == null ? void 0 : L(S);
6306
6306
  }, [L, S]), U = Se();
6307
6307
  return V.createElement(Y, { value: Z, props: { htmlFor: z == null ? void 0 : z.id }, slot: { open: w === ke.Open, disabled: g } }, V.createElement(ko, null, V.createElement(wl.Provider, { value: R }, V.createElement(cr.Provider, { value: O }, V.createElement(jo, { value: Te(w, { [ke.Open]: We.Open, [ke.Closed]: We.Closed }) }, l != null && T != null && V.createElement(ba, { disabled: g, data: { [l]: T }, form: a, onReset: D }), U({ ourProps: N, theirProps: b, slot: $, defaultTag: Hm, name: "Listbox" }))))));
@@ -6321,10 +6321,10 @@ function Vm(t, n) {
6321
6321
  break;
6322
6322
  case ne.Space:
6323
6323
  case ne.ArrowDown:
6324
- I.preventDefault(), i.actions.openListbox({ focus: o.value ? J.Nothing : J.First });
6324
+ I.preventDefault(), i.actions.openListbox({ focus: o.value ? q.Nothing : q.First });
6325
6325
  break;
6326
6326
  case ne.ArrowUp:
6327
- I.preventDefault(), i.actions.openListbox({ focus: o.value ? J.Nothing : J.Last });
6327
+ I.preventDefault(), i.actions.openListbox({ focus: o.value ? q.Nothing : q.Last });
6328
6328
  break;
6329
6329
  }
6330
6330
  }), C = Q((I) => {
@@ -6337,7 +6337,7 @@ function Vm(t, n) {
6337
6337
  var $;
6338
6338
  if (I.button === 0) {
6339
6339
  if (lo(I.currentTarget)) return I.preventDefault();
6340
- i.state.listboxState === ke.Open ? (Re(() => i.actions.closeListbox()), ($ = i.state.buttonElement) == null || $.focus({ preventScroll: !0 })) : (I.preventDefault(), i.actions.openListbox({ focus: J.Nothing }));
6340
+ i.state.listboxState === ke.Open ? (Re(() => i.actions.closeListbox()), ($ = i.state.buttonElement) == null || $.focus({ preventScroll: !0 })) : (I.preventDefault(), i.actions.openListbox({ focus: q.Nothing }));
6341
6341
  }
6342
6342
  }), T = Q((I) => I.preventDefault()), L = cn([a]), R = Ea(), { isFocusVisible: F, focusProps: A } = Kn({ autoFocus: s }), { isHovered: k, hoverProps: P } = Un({ isDisabled: l }), { pressed: O, pressProps: w } = ro({ disabled: l }), E = se(() => ({ open: h === ke.Open, active: O || h === ke.Open, disabled: l, invalid: o.invalid, value: o.value, hover: k, focus: F, autofocus: s }), [h, o.value, l, k, F, O, o.invalid, s]), j = ue(i, (I) => I.listboxState === ke.Open), z = Nt(g(), { ref: c, id: a, type: mo(t, d), "aria-haspopup": "listbox", "aria-controls": v == null ? void 0 : v.id, "aria-expanded": j, "aria-labelledby": L, "aria-describedby": R, disabled: l || void 0, autoFocus: s, onKeyDown: y, onKeyUp: C, onKeyPress: T, onPointerDown: S }, A, P, w);
6343
6343
  return Se()({ ourProps: z, theirProps: u, slot: E, defaultTag: Bm, name: "Listbox.Button" });
@@ -6381,15 +6381,15 @@ function Wm(t, n) {
6381
6381
  h.mode === rt.Single && (Re(() => d.actions.closeListbox()), (B = d.state.buttonElement) == null || B.focus({ preventScroll: !0 }));
6382
6382
  break;
6383
6383
  case Te(h.orientation, { vertical: ne.ArrowDown, horizontal: ne.ArrowRight }):
6384
- return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: J.Next });
6384
+ return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: q.Next });
6385
6385
  case Te(h.orientation, { vertical: ne.ArrowUp, horizontal: ne.ArrowLeft }):
6386
- return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: J.Previous });
6386
+ return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: q.Previous });
6387
6387
  case ne.Home:
6388
6388
  case ne.PageUp:
6389
- return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: J.First });
6389
+ return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: q.First });
6390
6390
  case ne.End:
6391
6391
  case ne.PageDown:
6392
- return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: J.Last });
6392
+ return X.preventDefault(), X.stopPropagation(), d.actions.goToOption({ focus: q.Last });
6393
6393
  case ne.Escape:
6394
6394
  X.preventDefault(), X.stopPropagation(), Re(() => d.actions.closeListbox()), (fe = d.state.buttonElement) == null || fe.focus({ preventScroll: !0 });
6395
6395
  return;
@@ -6400,10 +6400,10 @@ function Wm(t, n) {
6400
6400
  X.key.length === 1 && (d.actions.search(X.key), D.setTimeout(() => d.actions.clearSearch(), 350));
6401
6401
  break;
6402
6402
  }
6403
- }), q = ue(d, (X) => {
6403
+ }), J = ue(d, (X) => {
6404
6404
  var B;
6405
6405
  return (B = X.buttonElement) == null ? void 0 : B.id;
6406
- }), ae = se(() => ({ open: v === ke.Open }), [v]), K = Nt(u ? Y() : {}, { id: r, ref: N, "aria-activedescendant": ue(d, d.selectors.activeDescendantId), "aria-multiselectable": h.mode === rt.Multi ? !0 : void 0, "aria-labelledby": q, "aria-orientation": h.orientation, onKeyDown: U, role: "listbox", tabIndex: v === ke.Open ? 0 : void 0, style: { ...s.style, ...Z, "--button-width": An(b, !0).width }, ...vo(F) }), de = Se(), me = se(() => h.mode === rt.Multi ? h : { ...h, isSelected: j }, [h, j]);
6406
+ }), ae = se(() => ({ open: v === ke.Open }), [v]), K = Nt(u ? Y() : {}, { id: r, ref: N, "aria-activedescendant": ue(d, d.selectors.activeDescendantId), "aria-multiselectable": h.mode === rt.Multi ? !0 : void 0, "aria-labelledby": J, "aria-orientation": h.orientation, onKeyDown: U, role: "listbox", tabIndex: v === ke.Open ? 0 : void 0, style: { ...s.style, ...Z, "--button-width": An(b, !0).width }, ...vo(F) }), de = Se(), me = se(() => h.mode === rt.Multi ? h : { ...h, isSelected: j }, [h, j]);
6407
6407
  return V.createElement(Ao, { enabled: i ? t.static || R : !1, ownerDocument: S }, V.createElement(cr.Provider, { value: me }, de({ ourProps: K, theirProps: s, slot: ae, defaultTag: $m, features: Ym, visible: O, name: "Listbox.Options" })));
6408
6408
  }
6409
6409
  let Um = "div";
@@ -6426,40 +6426,40 @@ function Km(t, n) {
6426
6426
  if (o) return O.preventDefault();
6427
6427
  u.actions.onChange(i), s.mode === rt.Single && (Re(() => u.actions.closeListbox()), (w = u.state.buttonElement) == null || w.focus({ preventScroll: !0 }));
6428
6428
  }), S = Q(() => {
6429
- if (o) return u.actions.goToOption({ focus: J.Nothing });
6430
- u.actions.goToOption({ focus: J.Specific, id: r });
6429
+ if (o) return u.actions.goToOption({ focus: q.Nothing });
6430
+ u.actions.goToOption({ focus: q.Specific, id: r });
6431
6431
  }), T = go(), L = Q((O) => {
6432
- T.update(O), !o && (c || u.actions.goToOption({ focus: J.Specific, id: r }, Kr.Pointer));
6432
+ T.update(O), !o && (c || u.actions.goToOption({ focus: q.Specific, id: r }, Kr.Pointer));
6433
6433
  }), R = Q((O) => {
6434
- T.wasMoved(O) && (o || c || u.actions.goToOption({ focus: J.Specific, id: r }, Kr.Pointer));
6434
+ T.wasMoved(O) && (o || c || u.actions.goToOption({ focus: q.Specific, id: r }, Kr.Pointer));
6435
6435
  }), F = Q((O) => {
6436
- T.wasMoved(O) && (o || c && u.actions.goToOption({ focus: J.Nothing }));
6436
+ T.wasMoved(O) && (o || c && u.actions.goToOption({ focus: q.Nothing }));
6437
6437
  }), A = se(() => ({ active: c, focus: c, selected: g, disabled: o, selectedOption: g && l }), [c, g, o, l]), k = l ? {} : { id: r, ref: b, role: "option", tabIndex: o === !0 ? void 0 : -1, "aria-disabled": o === !0 ? !0 : void 0, "aria-selected": g, disabled: void 0, onClick: C, onFocus: S, onPointerEnter: L, onMouseEnter: L, onPointerMove: R, onMouseMove: R, onPointerLeave: F, onMouseLeave: F }, P = Se();
6438
6438
  return !g && l ? null : P({ ourProps: k, theirProps: a, slot: A, defaultTag: Um, name: "Listbox.Option" });
6439
6439
  }
6440
- let Zm = Je;
6440
+ let Zm = qe;
6441
6441
  function Gm(t, n) {
6442
6442
  let { options: e, placeholder: r, ...o } = t, i = { ref: Ie(n) }, a = pn("ListboxSelectedOption"), l = se(() => ({}), []), s = a.value === void 0 || a.value === null || a.mode === rt.Multi && Array.isArray(a.value) && a.value.length === 0, u = Se();
6443
6443
  return V.createElement(xl.Provider, { value: !0 }, u({ ourProps: i, theirProps: { ...o, children: V.createElement(V.Fragment, null, r && s ? r : e) }, slot: l, defaultTag: Zm, name: "ListboxSelectedOption" }));
6444
6444
  }
6445
- let Qm = Ce(zm), Jm = Ce(Vm), qm = Oa, Xm = Ce(Wm), eh = Ce(Km), th = Ce(Gm);
6446
- Object.assign(Qm, { Button: Jm, Label: qm, Options: Xm, Option: eh, SelectedOption: th });
6445
+ let Qm = Ce(zm), qm = Ce(Vm), Jm = Oa, Xm = Ce(Wm), eh = Ce(Km), th = Ce(Gm);
6446
+ Object.assign(Qm, { Button: qm, Label: Jm, Options: Xm, Option: eh, SelectedOption: th });
6447
6447
  var nh = Object.defineProperty, rh = (t, n, e) => n in t ? nh(t, n, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[n] = e, Bi = (t, n, e) => (rh(t, typeof n != "symbol" ? n + "" : n, e), e), je = ((t) => (t[t.Open = 0] = "Open", t[t.Closed = 1] = "Closed", t))(je || {}), $n = ((t) => (t[t.Pointer = 0] = "Pointer", t[t.Other = 1] = "Other", t))($n || {}), be = ((t) => (t[t.OpenMenu = 0] = "OpenMenu", t[t.CloseMenu = 1] = "CloseMenu", t[t.GoToItem = 2] = "GoToItem", t[t.Search = 3] = "Search", t[t.ClearSearch = 4] = "ClearSearch", t[t.RegisterItems = 5] = "RegisterItems", t[t.UnregisterItems = 6] = "UnregisterItems", t[t.SetButtonElement = 7] = "SetButtonElement", t[t.SetItemsElement = 8] = "SetItemsElement", t[t.SortItems = 9] = "SortItems", t))(be || {});
6448
6448
  function Vi(t, n = (e) => e) {
6449
6449
  let e = t.activeItemIndex !== null ? t.items[t.activeItemIndex] : null, r = rr(n(t.items.slice()), (i) => i.dataRef.current.domRef.current), o = e ? r.indexOf(e) : null;
6450
6450
  return o === -1 && (o = null), { items: r, activeItemIndex: o };
6451
6451
  }
6452
6452
  let oh = { 1(t) {
6453
- return t.menuState === 1 ? t : { ...t, activeItemIndex: null, pendingFocus: { focus: J.Nothing }, menuState: 1 };
6453
+ return t.menuState === 1 ? t : { ...t, activeItemIndex: null, pendingFocus: { focus: q.Nothing }, menuState: 1 };
6454
6454
  }, 0(t, n) {
6455
6455
  return t.menuState === 0 ? t : { ...t, __demoMode: !1, pendingFocus: n.focus, menuState: 0 };
6456
6456
  }, 2: (t, n) => {
6457
6457
  var e, r, o, i, a;
6458
6458
  if (t.menuState === 1) return t;
6459
6459
  let l = { ...t, searchQuery: "", activationTrigger: (e = n.trigger) != null ? e : 1, __demoMode: !1 };
6460
- if (n.focus === J.Nothing) return { ...l, activeItemIndex: null };
6461
- if (n.focus === J.Specific) return { ...l, activeItemIndex: t.items.findIndex((c) => c.id === n.id) };
6462
- if (n.focus === J.Previous) {
6460
+ if (n.focus === q.Nothing) return { ...l, activeItemIndex: null };
6461
+ if (n.focus === q.Specific) return { ...l, activeItemIndex: t.items.findIndex((c) => c.id === n.id) };
6462
+ if (n.focus === q.Previous) {
6463
6463
  let c = t.activeItemIndex;
6464
6464
  if (c !== null) {
6465
6465
  let g = t.items[c].dataRef.current.domRef, h = nt(n, { resolveItems: () => t.items, resolveActiveIndex: () => t.activeItemIndex, resolveId: (d) => d.id, resolveDisabled: (d) => d.dataRef.current.disabled });
@@ -6468,7 +6468,7 @@ let oh = { 1(t) {
6468
6468
  if (((r = g.current) == null ? void 0 : r.previousElementSibling) === d.current || ((o = d.current) == null ? void 0 : o.previousElementSibling) === null) return { ...l, activeItemIndex: h };
6469
6469
  }
6470
6470
  }
6471
- } else if (n.focus === J.Next) {
6471
+ } else if (n.focus === q.Next) {
6472
6472
  let c = t.activeItemIndex;
6473
6473
  if (c !== null) {
6474
6474
  let g = t.items[c].dataRef.current.domRef, h = nt(n, { resolveItems: () => t.items, resolveActiveIndex: () => t.activeItemIndex, resolveId: (d) => d.id, resolveDisabled: (d) => d.dataRef.current.disabled });
@@ -6490,7 +6490,7 @@ let oh = { 1(t) {
6490
6490
  return t.searchQuery === "" ? t : { ...t, searchQuery: "", searchActiveItemIndex: null };
6491
6491
  }, 5: (t, n) => {
6492
6492
  let e = t.items.concat(n.items.map((o) => o)), r = t.activeItemIndex;
6493
- return t.pendingFocus.focus !== J.Nothing && (r = nt(t.pendingFocus, { resolveItems: () => e, resolveActiveIndex: () => t.activeItemIndex, resolveId: (o) => o.id, resolveDisabled: (o) => o.dataRef.current.disabled })), { ...t, items: e, activeItemIndex: r, pendingFocus: { focus: J.Nothing }, pendingShouldSort: !0 };
6493
+ return t.pendingFocus.focus !== q.Nothing && (r = nt(t.pendingFocus, { resolveItems: () => e, resolveActiveIndex: () => t.activeItemIndex, resolveId: (o) => o.id, resolveDisabled: (o) => o.dataRef.current.disabled })), { ...t, items: e, activeItemIndex: r, pendingFocus: { focus: q.Nothing }, pendingShouldSort: !0 };
6494
6494
  }, 6: (t, n) => {
6495
6495
  let e = t.items, r = [], o = new Set(n.items);
6496
6496
  for (let [i, a] of e.entries()) if (o.has(a.id) && (r.push(i), o.delete(a.id), o.size === 0)) break;
@@ -6502,12 +6502,12 @@ let oh = { 1(t) {
6502
6502
  }, 7: (t, n) => t.buttonElement === n.element ? t : { ...t, buttonElement: n.element }, 8: (t, n) => t.itemsElement === n.element ? t : { ...t, itemsElement: n.element }, 9: (t) => t.pendingShouldSort ? { ...t, ...Vi(t), pendingShouldSort: !1 } : t };
6503
6503
  class Fo extends Xn {
6504
6504
  constructor(n) {
6505
- super(n), Bi(this, "actions", { registerItem: Jt(() => {
6505
+ super(n), Bi(this, "actions", { registerItem: qt(() => {
6506
6506
  let e = [], r = /* @__PURE__ */ new Set();
6507
6507
  return [(o, i) => {
6508
6508
  r.has(i) || (r.add(i), e.push({ id: o, dataRef: i }));
6509
6509
  }, () => (r.clear(), this.send({ type: 5, items: e.splice(0) }))];
6510
- }), unregisterItem: Jt(() => {
6510
+ }), unregisterItem: qt(() => {
6511
6511
  let e = [];
6512
6512
  return [(r) => e.push(r), () => this.send({ type: 6, items: e.splice(0) })];
6513
6513
  }) }), Bi(this, "selectors", { activeDescendantId(e) {
@@ -6533,7 +6533,7 @@ class Fo extends Xn {
6533
6533
  }
6534
6534
  }
6535
6535
  static new({ id: n, __demoMode: e = !1 }) {
6536
- return new Fo({ id: n, __demoMode: e, menuState: e ? 0 : 1, buttonElement: null, itemsElement: null, items: [], searchQuery: "", activeItemIndex: null, activationTrigger: 1, pendingShouldSort: !1, pendingFocus: { focus: J.Nothing } });
6536
+ return new Fo({ id: n, __demoMode: e, menuState: e ? 0 : 1, buttonElement: null, itemsElement: null, items: [], searchQuery: "", activeItemIndex: null, activationTrigger: 1, pendingShouldSort: !1, pendingFocus: { focus: q.Nothing } });
6537
6537
  }
6538
6538
  reduce(n, e) {
6539
6539
  return Te(e.type, oh, n, e);
@@ -6552,7 +6552,7 @@ function Ol({ id: t, __demoMode: n = !1 }) {
6552
6552
  let e = se(() => Fo.new({ id: t, __demoMode: n }), []);
6553
6553
  return sr(() => e.dispose()), e;
6554
6554
  }
6555
- let ih = Je;
6555
+ let ih = qe;
6556
6556
  function ah(t, n) {
6557
6557
  let e = Ne(), { __demoMode: r = !1, ...o } = t, i = Ol({ id: e, __demoMode: r }), [a, l, s] = ue(i, (y) => [y.menuState, y.itemsElement, y.buttonElement]), u = Ie(n), c = At.get(null), g = ue(c, le((y) => c.selectors.isTop(y, e), [c, e]));
6558
6558
  fo(g, [s, l], (y, C) => {
@@ -6571,10 +6571,10 @@ function sh(t, n) {
6571
6571
  case ne.Space:
6572
6572
  case ne.Enter:
6573
6573
  case ne.ArrowDown:
6574
- O.preventDefault(), O.stopPropagation(), e.send({ type: be.OpenMenu, focus: { focus: J.First } });
6574
+ O.preventDefault(), O.stopPropagation(), e.send({ type: be.OpenMenu, focus: { focus: q.First } });
6575
6575
  break;
6576
6576
  case ne.ArrowUp:
6577
- O.preventDefault(), O.stopPropagation(), e.send({ type: be.OpenMenu, focus: { focus: J.Last } });
6577
+ O.preventDefault(), O.stopPropagation(), e.send({ type: be.OpenMenu, focus: { focus: q.Last } });
6578
6578
  break;
6579
6579
  }
6580
6580
  }), h = Q((O) => {
@@ -6593,7 +6593,7 @@ function sh(t, n) {
6593
6593
  var w;
6594
6594
  if (O.button === 0) {
6595
6595
  if (lo(O.currentTarget)) return O.preventDefault();
6596
- i || (d === je.Open ? (Re(() => e.send({ type: be.CloseMenu })), (w = s.current) == null || w.focus({ preventScroll: !0 })) : (O.preventDefault(), e.send({ type: be.OpenMenu, focus: { focus: J.Nothing }, trigger: $n.Pointer })));
6596
+ i || (d === je.Open ? (Re(() => e.send({ type: be.CloseMenu })), (w = s.current) == null || w.focus({ preventScroll: !0 })) : (O.preventDefault(), e.send({ type: be.OpenMenu, focus: { focus: q.Nothing }, trigger: $n.Pointer })));
6597
6597
  }
6598
6598
  }), { isFocusVisible: S, focusProps: T } = Kn({ autoFocus: a }), { isHovered: L, hoverProps: R } = Un({ isDisabled: i }), { pressed: F, pressProps: A } = ro({ disabled: i }), k = se(() => ({ open: d === je.Open, active: F || d === je.Open, disabled: i, hover: L, focus: S, autofocus: a }), [d, L, S, F, i, a]), P = Nt(u(), { ref: c, id: o, type: mo(t, s.current), "aria-haspopup": "menu", "aria-controls": b == null ? void 0 : b.id, "aria-expanded": d === je.Open, disabled: i || void 0, autoFocus: a, onKeyDown: g, onKeyUp: h, onPointerDown: C }, T, R, A);
6599
6599
  return Se()({ ourProps: P, theirProps: l, slot: k, defaultTag: lh, name: "Menu.Button" });
@@ -6620,7 +6620,7 @@ function dh(t, n) {
6620
6620
  N.setAttribute("role", "none");
6621
6621
  } });
6622
6622
  let j = jt(), z = Q((N) => {
6623
- var D, U, q;
6623
+ var D, U, J;
6624
6624
  switch (j.dispose(), N.key) {
6625
6625
  case ne.Space:
6626
6626
  if (c.state.searchQuery !== "") return N.preventDefault(), N.stopPropagation(), c.send({ type: be.Search, value: N.key });
@@ -6632,17 +6632,17 @@ function dh(t, n) {
6632
6632
  c.send({ type: be.CloseMenu }), Na(c.state.buttonElement);
6633
6633
  break;
6634
6634
  case ne.ArrowDown:
6635
- return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: J.Next });
6635
+ return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: q.Next });
6636
6636
  case ne.ArrowUp:
6637
- return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: J.Previous });
6637
+ return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: q.Previous });
6638
6638
  case ne.Home:
6639
6639
  case ne.PageUp:
6640
- return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: J.First });
6640
+ return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: q.First });
6641
6641
  case ne.End:
6642
6642
  case ne.PageDown:
6643
- return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: J.Last });
6643
+ return N.preventDefault(), N.stopPropagation(), c.send({ type: be.GoToItem, focus: q.Last });
6644
6644
  case ne.Escape:
6645
- N.preventDefault(), N.stopPropagation(), Re(() => c.send({ type: be.CloseMenu })), (q = c.state.buttonElement) == null || q.focus({ preventScroll: !0 });
6645
+ N.preventDefault(), N.stopPropagation(), Re(() => c.send({ type: be.CloseMenu })), (J = c.state.buttonElement) == null || J.focus({ preventScroll: !0 });
6646
6646
  break;
6647
6647
  case ne.Tab:
6648
6648
  N.preventDefault(), N.stopPropagation(), Re(() => c.send({ type: be.CloseMenu })), Aa(c.state.buttonElement, N.shiftKey ? tn.Previous : tn.Next);
@@ -6663,7 +6663,7 @@ function dh(t, n) {
6663
6663
  }), id: r, onKeyDown: z, onKeyUp: I, role: "menu", tabIndex: C === je.Open ? 0 : void 0, ref: y, style: { ...s.style, ...h, "--button-width": An(S, !0).width }, ...vo(A) }), Y = Se();
6664
6664
  return V.createElement(Ao, { enabled: i ? t.static || F : !1, ownerDocument: T }, Y({ ourProps: Z, theirProps: s, slot: $, defaultTag: ch, features: uh, visible: E, name: "Menu.Items" }));
6665
6665
  }
6666
- let fh = Je;
6666
+ let fh = qe;
6667
6667
  function ph(t, n) {
6668
6668
  let e = Ne(), { id: r = `headlessui-menu-item-${e}`, disabled: o = !1, ...i } = t, a = Lo("Menu.Item"), l = ue(a, (w) => a.selectors.isActive(w, r)), s = ie(null), u = Ie(n, s), c = ue(a, (w) => a.selectors.shouldScrollIntoView(w, r));
6669
6669
  ve(() => {
@@ -6684,20 +6684,20 @@ function ph(t, n) {
6684
6684
  if (o) return w.preventDefault();
6685
6685
  a.send({ type: be.CloseMenu }), Na(a.state.buttonElement);
6686
6686
  }), b = Q(() => {
6687
- if (o) return a.send({ type: be.GoToItem, focus: J.Nothing });
6688
- a.send({ type: be.GoToItem, focus: J.Specific, id: r });
6687
+ if (o) return a.send({ type: be.GoToItem, focus: q.Nothing });
6688
+ a.send({ type: be.GoToItem, focus: q.Specific, id: r });
6689
6689
  }), y = go(), C = Q((w) => {
6690
- y.update(w), !o && (l || a.send({ type: be.GoToItem, focus: J.Specific, id: r, trigger: $n.Pointer }));
6690
+ y.update(w), !o && (l || a.send({ type: be.GoToItem, focus: q.Specific, id: r, trigger: $n.Pointer }));
6691
6691
  }), S = Q((w) => {
6692
- y.wasMoved(w) && (o || l || a.send({ type: be.GoToItem, focus: J.Specific, id: r, trigger: $n.Pointer }));
6692
+ y.wasMoved(w) && (o || l || a.send({ type: be.GoToItem, focus: q.Specific, id: r, trigger: $n.Pointer }));
6693
6693
  }), T = Q((w) => {
6694
- y.wasMoved(w) && (o || l && a.send({ type: be.GoToItem, focus: J.Nothing }));
6695
- }), [L, R] = qn(), [F, A] = yd(), k = se(() => ({ active: l, focus: l, disabled: o, close: d }), [l, o, d]), P = { id: r, ref: u, role: "menuitem", tabIndex: o === !0 ? void 0 : -1, "aria-disabled": o === !0 ? !0 : void 0, "aria-labelledby": L, "aria-describedby": F, disabled: void 0, onClick: v, onFocus: b, onPointerEnter: C, onMouseEnter: C, onPointerMove: S, onMouseMove: S, onPointerLeave: T, onMouseLeave: T }, O = Se();
6694
+ y.wasMoved(w) && (o || l && a.send({ type: be.GoToItem, focus: q.Nothing }));
6695
+ }), [L, R] = Jn(), [F, A] = yd(), k = se(() => ({ active: l, focus: l, disabled: o, close: d }), [l, o, d]), P = { id: r, ref: u, role: "menuitem", tabIndex: o === !0 ? void 0 : -1, "aria-disabled": o === !0 ? !0 : void 0, "aria-labelledby": L, "aria-describedby": F, disabled: void 0, onClick: v, onFocus: b, onPointerEnter: C, onMouseEnter: C, onPointerMove: S, onMouseMove: S, onPointerLeave: T, onMouseLeave: T }, O = Se();
6696
6696
  return V.createElement(R, null, V.createElement(A, null, O({ ourProps: P, theirProps: i, slot: k, defaultTag: fh, name: "Menu.Item" })));
6697
6697
  }
6698
6698
  let mh = "div";
6699
6699
  function hh(t, n) {
6700
- let [e, r] = qn(), o = t, i = { ref: n, "aria-labelledby": e, role: "group" }, a = Se();
6700
+ let [e, r] = Jn(), o = t, i = { ref: n, "aria-labelledby": e, role: "group" }, a = Se();
6701
6701
  return V.createElement(r, null, a({ ourProps: i, theirProps: o, slot: {}, defaultTag: mh, name: "Menu.Section" }));
6702
6702
  }
6703
6703
  let gh = "header";
@@ -7282,7 +7282,7 @@ function zh(t, n) {
7282
7282
  config: Ae(Ae({}, _t), Me.defaultConfig),
7283
7283
  l10n: ln
7284
7284
  };
7285
- e.parseDate = Gr({ config: e.config, l10n: e.l10n }), e._handlers = [], e.pluginElements = [], e.loadedPlugins = [], e._bind = b, e._setHoursFromDate = h, e._positionCalendar = gn, e.changeMonth = U, e.changeYear = X, e.clear = q, e.close = ae, e.onMouseOver = hn, e._createElement = ge, e.createDay = F, e.destroy = K, e.isEnabled = B, e.jumpToDate = S, e.updateValue = lt, e.open = Tl, e.redraw = zo, e.set = Al, e.setDate = Pl, e.toggle = _l;
7285
+ e.parseDate = Gr({ config: e.config, l10n: e.l10n }), e._handlers = [], e.pluginElements = [], e.loadedPlugins = [], e._bind = b, e._setHoursFromDate = h, e._positionCalendar = gn, e.changeMonth = U, e.changeYear = X, e.clear = J, e.close = ae, e.onMouseOver = hn, e._createElement = ge, e.createDay = F, e.destroy = K, e.isEnabled = B, e.jumpToDate = S, e.updateValue = lt, e.open = Tl, e.redraw = zo, e.set = Al, e.setDate = Pl, e.toggle = _l;
7286
7286
  function r() {
7287
7287
  e.utils = {
7288
7288
  getDaysInMonth: function(f, m) {
@@ -7597,7 +7597,7 @@ function zh(t, n) {
7597
7597
  var x = m ? f : f - e.currentMonth;
7598
7598
  x < 0 && e._hidePrevMonthArrow === !0 || x > 0 && e._hideNextMonthArrow === !0 || (e.currentMonth += x, (e.currentMonth < 0 || e.currentMonth > 11) && (e.currentYear += e.currentMonth > 11 ? 1 : -1, e.currentMonth = (e.currentMonth + 12) % 12, De("onYearChange"), j()), E(), De("onMonthChange"), bn());
7599
7599
  }
7600
- function q(f, m) {
7600
+ function J(f, m) {
7601
7601
  if (f === void 0 && (f = !0), m === void 0 && (m = !0), e.input.value = "", e.altInput !== void 0 && (e.altInput.value = ""), e.mobileInput !== void 0 && (e.mobileInput.value = ""), e.selectedDates = [], e.latestSelectedDateObj = void 0, m === !0 && (e.currentYear = e._initialDate.getFullYear(), e.currentMonth = e._initialDate.getMonth()), e.config.enableTime === !0) {
7602
7602
  var x = Fr(e.config), M = x.hours, _ = x.minutes, W = x.seconds;
7603
7603
  d(M, _, W);
@@ -8325,11 +8325,11 @@ const Vh = `
8325
8325
  default:
8326
8326
  return Ge.default;
8327
8327
  }
8328
- }, Gh = (t) => new Set(Object.values(Xr)).has(t), Qh = (t) => t === "error" ? "dangerous" : Gh(t) ? t : "default", Jh = (t, n, e, r) => {
8328
+ }, Gh = (t) => new Set(Object.values(Xr)).has(t), Qh = (t) => t === "error" ? "dangerous" : Gh(t) ? t : "default", qh = (t, n, e, r) => {
8329
8329
  !t || n < 1 || (r.current !== null && clearTimeout(r.current), r.current = window.setTimeout(() => {
8330
8330
  e();
8331
8331
  }, n));
8332
- }, qh = (t) => {
8332
+ }, Jh = (t) => {
8333
8333
  t.current !== null && (clearTimeout(t.current), t.current = null);
8334
8334
  }, Xh = ({
8335
8335
  title: t,
@@ -8345,9 +8345,9 @@ const Vh = `
8345
8345
  u(!1), i && i();
8346
8346
  };
8347
8347
  if (Oe(() => () => {
8348
- qh(c);
8348
+ Jh(c);
8349
8349
  }, []), Oe(() => {
8350
- Jh(r, o, d, c);
8350
+ qh(r, o, d, c);
8351
8351
  }, [r, o]), !s) return null;
8352
8352
  const v = Qh(n), b = Kh(n), y = Zh(n);
8353
8353
  return /* @__PURE__ */ H.jsxs(
@@ -8611,10 +8611,10 @@ var Ki = {
8611
8611
  */
8612
8612
  nextTabbableNode: function(N) {
8613
8613
  var D = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, U = E.indexOf(N);
8614
- return U < 0 ? D ? j.slice(j.indexOf(N) + 1).find(function(q) {
8615
- return wt(q);
8616
- }) : j.slice(0, j.indexOf(N)).reverse().find(function(q) {
8617
- return wt(q);
8614
+ return U < 0 ? D ? j.slice(j.indexOf(N) + 1).find(function(J) {
8615
+ return wt(J);
8616
+ }) : j.slice(0, j.indexOf(N)).reverse().find(function(J) {
8617
+ return wt(J);
8618
8618
  }) : E[U + (D ? 1 : -1)];
8619
8619
  }
8620
8620
  };
@@ -8663,12 +8663,12 @@ var Ki = {
8663
8663
  $ = ct(E) >= 0 ? U.lastTabbableNode : U.lastDomTabbableNode;
8664
8664
  } else en(j) || ($ = Y.nextTabbableNode(E, !1));
8665
8665
  } else {
8666
- var q = i.tabbableGroups.findIndex(function(de) {
8666
+ var J = i.tabbableGroups.findIndex(function(de) {
8667
8667
  var me = de.lastTabbableNode;
8668
8668
  return E === me;
8669
8669
  });
8670
- if (q < 0 && (Y.container === E || Cn(E, o.tabbableOptions) && !wt(E, o.tabbableOptions) && !Y.nextTabbableNode(E)) && (q = Z), q >= 0) {
8671
- var ae = q === i.tabbableGroups.length - 1 ? 0 : q + 1, K = i.tabbableGroups[ae];
8670
+ if (J < 0 && (Y.container === E || Cn(E, o.tabbableOptions) && !wt(E, o.tabbableOptions) && !Y.nextTabbableNode(E)) && (J = Z), J >= 0) {
8671
+ var ae = J === i.tabbableGroups.length - 1 ? 0 : J + 1, K = i.tabbableGroups[ae];
8672
8672
  $ = ct(E) >= 0 ? K.firstTabbableNode : K.firstDomTabbableNode;
8673
8673
  } else en(j) || ($ = Y.nextTabbableNode(E));
8674
8674
  }
@@ -8847,7 +8847,7 @@ var Ki = {
8847
8847
  const mg = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
8848
8848
  __proto__: null,
8849
8849
  createFocusTrap: pg
8850
- }, Symbol.toStringTag, { value: "Module" })), hg = /* @__PURE__ */ qi(mg), gg = /* @__PURE__ */ qi(qf);
8850
+ }, Symbol.toStringTag, { value: "Module" })), hg = /* @__PURE__ */ Ji(mg), gg = /* @__PURE__ */ Ji(Jf);
8851
8851
  var Gi;
8852
8852
  function vg() {
8853
8853
  if (Gi) return Dn.exports;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudoperators/juno-messages-provider",
3
- "version": "0.2.6",
3
+ "version": "0.2.7",
4
4
  "description": "Messages provider",
5
5
  "author": "UI-Team",
6
6
  "contributors": [