@coolms/ui-react 0.1.0-alpha.21 → 0.1.0-alpha.22

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.
package/dist/index.js CHANGED
@@ -1,15 +1,15 @@
1
- import { jsx as e, jsxs as d, Fragment as M } from "react/jsx-runtime";
2
- import { useId as X, useState as A, useRef as K, useEffect as Y, useCallback as be, useMemo as Oe, useLayoutEffect as xe, useContext as Re, createContext as Ue } from "react";
1
+ import { jsx as e, jsxs as u, Fragment as M } from "react/jsx-runtime";
2
+ import { useId as G, useState as E, useRef as R, useEffect as Y, useCallback as be, useMemo as Oe, useLayoutEffect as xe, useContext as Ke, createContext as Ue } from "react";
3
3
  import { createPortal as Me } from "react-dom";
4
4
  function ce(n, l) {
5
5
  const t = { ...n };
6
6
  for (const o of Object.keys(l ?? {})) {
7
- const c = l == null ? void 0 : l[o];
8
- c !== void 0 && (t[o] = c);
7
+ const i = l == null ? void 0 : l[o];
8
+ i !== void 0 && (t[o] = i);
9
9
  }
10
10
  return t;
11
11
  }
12
- function E(...n) {
12
+ function A(...n) {
13
13
  return n.filter(Boolean).join(" ");
14
14
  }
15
15
  function z({ name: n }) {
@@ -36,44 +36,44 @@ function le({
36
36
  busy: l = !1,
37
37
  busyLabel: t,
38
38
  locked: o = !1,
39
- lockedReason: c,
40
- icon: a,
39
+ lockedReason: i,
40
+ icon: s,
41
41
  disabled: r,
42
- className: s,
43
- children: m,
44
- type: f = "button",
45
- title: i,
46
- ...h
42
+ className: a,
43
+ children: h,
44
+ type: _ = "button",
45
+ title: d,
46
+ ...m
47
47
  }) {
48
- const u = !!r || l;
49
- return /* @__PURE__ */ d(
48
+ const c = !!r || l;
49
+ return /* @__PURE__ */ u(
50
50
  "button",
51
51
  {
52
- ...h,
53
- type: f,
54
- className: E("cms-button", `cms-button--${n}`, l && "is-busy", o && "is-locked", s),
55
- disabled: u,
52
+ ...m,
53
+ type: _,
54
+ className: A("cms-button", `cms-button--${n}`, l && "is-busy", o && "is-locked", a),
55
+ disabled: c,
56
56
  "aria-busy": l || void 0,
57
- title: o ? c ?? i : i,
57
+ title: o ? i ?? d : d,
58
58
  children: [
59
- l ? /* @__PURE__ */ e(z, { name: "spinner" }) : o ? /* @__PURE__ */ e(z, { name: "lock" }) : a,
60
- /* @__PURE__ */ e("span", { className: "cms-button__label", children: l && t !== void 0 ? t : m }),
61
- o && c ? /* @__PURE__ */ d("span", { className: "cms-visually-hidden", children: [
59
+ l ? /* @__PURE__ */ e(z, { name: "spinner" }) : o ? /* @__PURE__ */ e(z, { name: "lock" }) : s,
60
+ /* @__PURE__ */ e("span", { className: "cms-button__label", children: l && t !== void 0 ? t : h }),
61
+ o && i ? /* @__PURE__ */ u("span", { className: "cms-visually-hidden", children: [
62
62
  ", ",
63
- c
63
+ i
64
64
  ] }) : null
65
65
  ]
66
66
  }
67
67
  );
68
68
  }
69
- function Ce({ id: n, label: l, help: t, error: o, pinned: c, children: a }) {
70
- return /* @__PURE__ */ d("div", { className: E("cms-field", o != null && "is-invalid"), children: [
69
+ function Ce({ id: n, label: l, help: t, error: o, pinned: i, children: s }) {
70
+ return /* @__PURE__ */ u("div", { className: A("cms-field", o != null && "is-invalid"), children: [
71
71
  /* @__PURE__ */ e("label", { className: "cms-field__label", htmlFor: n, children: l }),
72
- a,
73
- c != null ? /* @__PURE__ */ d("p", { className: "cms-field__pinned", id: `${n}-pinned`, children: [
72
+ s,
73
+ i != null ? /* @__PURE__ */ u("p", { className: "cms-field__pinned", id: `${n}-pinned`, children: [
74
74
  /* @__PURE__ */ e(z, { name: "lock" }),
75
75
  " ",
76
- c
76
+ i
77
77
  ] }) : null,
78
78
  o != null ? /* @__PURE__ */ e("p", { className: "cms-field__error", id: `${n}-error`, role: "alert", children: o }) : null,
79
79
  t != null ? /* @__PURE__ */ e("p", { className: "cms-field__help", id: `${n}-help`, children: t }) : null
@@ -85,26 +85,26 @@ function Se(n, l) {
85
85
  }
86
86
  const ze = /^(\d{4})-(\d{2})-(\d{2})(?:T(\d{2}):(\d{2})(?::(\d{2}))?)?$/, Ze = /^(\d{2}):(\d{2})(?::(\d{2}))?$/;
87
87
  function Ve(n, l, t) {
88
- const o = (a, r, s, m = 0, f = 0, i = 0) => {
89
- const h = new Date(Date.UTC(a, r - 1, s, m, f, i));
90
- return h.setUTCFullYear(a), h.getUTCFullYear() === a && h.getUTCMonth() === r - 1 && h.getUTCDate() === s && h.getUTCHours() === m && h.getUTCMinutes() === f && h.getUTCSeconds() === i ? h : null;
91
- }, c = (a) => ({ hour: Number(a[1]), minute: Number(a[2]), second: Number(a[3] ?? 0) });
88
+ const o = (s, r, a, h = 0, _ = 0, d = 0) => {
89
+ const m = new Date(Date.UTC(s, r - 1, a, h, _, d));
90
+ return m.setUTCFullYear(s), m.getUTCFullYear() === s && m.getUTCMonth() === r - 1 && m.getUTCDate() === a && m.getUTCHours() === h && m.getUTCMinutes() === _ && m.getUTCSeconds() === d ? m : null;
91
+ }, i = (s) => ({ hour: Number(s[1]), minute: Number(s[2]), second: Number(s[3] ?? 0) });
92
92
  try {
93
93
  if (n === "time") {
94
94
  const r = l.match(Ze);
95
95
  if (r === null) return l;
96
- const s = c(r), m = o(2e3, 1, 1, s.hour, s.minute, s.second);
97
- return m === null ? l : new Intl.DateTimeFormat(t, { timeStyle: r[3] === void 0 ? "short" : "medium", timeZone: "UTC" }).format(m);
96
+ const a = i(r), h = o(2e3, 1, 1, a.hour, a.minute, a.second);
97
+ return h === null ? l : new Intl.DateTimeFormat(t, { timeStyle: r[3] === void 0 ? "short" : "medium", timeZone: "UTC" }).format(h);
98
98
  }
99
- const a = l.match(ze);
100
- if (a === null) return l;
101
- if (n === "date" && a[4] === void 0) {
102
- const r = o(Number(a[1]), Number(a[2]), Number(a[3]));
99
+ const s = l.match(ze);
100
+ if (s === null) return l;
101
+ if (n === "date" && s[4] === void 0) {
102
+ const r = o(Number(s[1]), Number(s[2]), Number(s[3]));
103
103
  return r === null ? l : new Intl.DateTimeFormat(t, { dateStyle: "medium", timeZone: "UTC" }).format(r);
104
104
  }
105
- if (n === "datetime-local" && a[4] !== void 0) {
106
- const r = o(Number(a[1]), Number(a[2]), Number(a[3]), Number(a[4]), Number(a[5]), Number(a[6] ?? 0));
107
- return r === null ? l : new Intl.DateTimeFormat(t, { dateStyle: "medium", timeStyle: a[6] === void 0 ? "short" : "medium", timeZone: "UTC" }).format(r);
105
+ if (n === "datetime-local" && s[4] !== void 0) {
106
+ const r = o(Number(s[1]), Number(s[2]), Number(s[3]), Number(s[4]), Number(s[5]), Number(s[6] ?? 0));
107
+ return r === null ? l : new Intl.DateTimeFormat(t, { dateStyle: "medium", timeStyle: s[6] === void 0 ? "short" : "medium", timeZone: "UTC" }).format(r);
108
108
  }
109
109
  } catch {
110
110
  return l;
@@ -112,136 +112,136 @@ function Ve(n, l, t) {
112
112
  return l;
113
113
  }
114
114
  const We = /* @__PURE__ */ new Set(["date", "time", "datetime-local"]);
115
- function Pn({ label: n, help: l, error: t, disabled: o, readOnly: c, pinned: a, value: r, onChange: s, placeholder: m, type: f = "text", name: i, locale: h, min: u, max: p, step: _, minLength: g, maxLength: N, required: w }) {
116
- const x = X(), S = c === !0 || a != null, C = S && We.has(f), F = f === "number" && (_ === "any" || typeof _ == "number" && !Number.isInteger(_));
117
- return /* @__PURE__ */ e(Ce, { id: x, label: n, help: l, error: t, pinned: a, children: /* @__PURE__ */ e(
115
+ function Bn({ label: n, help: l, error: t, disabled: o, readOnly: i, pinned: s, value: r, onChange: a, placeholder: h, type: _ = "text", name: d, locale: m, min: c, max: f, step: p, minLength: g, maxLength: N, required: w }) {
116
+ const x = G(), S = i === !0 || s != null, C = S && We.has(_), F = _ === "number" && (p === "any" || typeof p == "number" && !Number.isInteger(p));
117
+ return /* @__PURE__ */ e(Ce, { id: x, label: n, help: l, error: t, pinned: s, children: /* @__PURE__ */ e(
118
118
  "input",
119
119
  {
120
120
  id: x,
121
- name: i,
122
- type: C ? "text" : f,
121
+ name: d,
122
+ type: C ? "text" : _,
123
123
  className: "cms-input",
124
- value: C ? Ve(f, r, h) : r,
124
+ value: C ? Ve(_, r, m) : r,
125
125
  ...C ? { "data-value": r } : {},
126
- lang: h,
127
- placeholder: m,
126
+ lang: m,
127
+ placeholder: h,
128
128
  disabled: o,
129
129
  readOnly: S,
130
130
  required: w,
131
131
  "aria-required": w || void 0,
132
- min: C ? void 0 : u,
133
- max: C ? void 0 : p,
134
- step: C ? void 0 : _,
132
+ min: C ? void 0 : c,
133
+ max: C ? void 0 : f,
134
+ step: C ? void 0 : p,
135
135
  minLength: g,
136
136
  maxLength: N,
137
- inputMode: f === "number" ? F ? "decimal" : "numeric" : void 0,
137
+ inputMode: _ === "number" ? F ? "decimal" : "numeric" : void 0,
138
138
  "aria-invalid": t != null || void 0,
139
- "aria-describedby": Se(x, { help: l, error: t, pinned: a }),
140
- onChange: (H) => s == null ? void 0 : s(H.target.value)
139
+ "aria-describedby": Se(x, { help: l, error: t, pinned: s }),
140
+ onChange: (H) => a == null ? void 0 : a(H.target.value)
141
141
  }
142
142
  ) });
143
143
  }
144
- function In({ label: n, help: l, error: t, disabled: o, readOnly: c, pinned: a, value: r, onChange: s, placeholder: m, rows: f = 4, name: i, locale: h, minLength: u, maxLength: p, required: _ }) {
145
- const g = X();
146
- return /* @__PURE__ */ e(Ce, { id: g, label: n, help: l, error: t, pinned: a, children: /* @__PURE__ */ e(
144
+ function Fn({ label: n, help: l, error: t, disabled: o, readOnly: i, pinned: s, value: r, onChange: a, placeholder: h, rows: _ = 4, name: d, locale: m, minLength: c, maxLength: f, required: p }) {
145
+ const g = G();
146
+ return /* @__PURE__ */ e(Ce, { id: g, label: n, help: l, error: t, pinned: s, children: /* @__PURE__ */ e(
147
147
  "textarea",
148
148
  {
149
149
  id: g,
150
- name: i,
150
+ name: d,
151
151
  className: "cms-input cms-textarea",
152
- rows: f,
152
+ rows: _,
153
153
  value: r,
154
- lang: h,
155
- placeholder: m,
154
+ lang: m,
155
+ placeholder: h,
156
156
  disabled: o,
157
- readOnly: c === !0 || a != null,
158
- required: _,
159
- "aria-required": _ || void 0,
160
- minLength: u,
161
- maxLength: p,
157
+ readOnly: i === !0 || s != null,
158
+ required: p,
159
+ "aria-required": p || void 0,
160
+ minLength: c,
161
+ maxLength: f,
162
162
  "aria-invalid": t != null || void 0,
163
- "aria-describedby": Se(g, { help: l, error: t, pinned: a }),
164
- onChange: (N) => s == null ? void 0 : s(N.target.value)
163
+ "aria-describedby": Se(g, { help: l, error: t, pinned: s }),
164
+ onChange: (N) => a == null ? void 0 : a(N.target.value)
165
165
  }
166
166
  ) });
167
167
  }
168
- function Bn({ label: n, help: l, error: t, disabled: o, readOnly: c, value: a, options: r, onChange: s, emptyText: m = "Nothing to choose from yet.", name: f }) {
169
- const i = X(), h = r.length === 0;
170
- return /* @__PURE__ */ e(Ce, { id: i, label: n, help: h ? m : l, error: t, children: /* @__PURE__ */ e(
168
+ function Hn({ label: n, help: l, error: t, disabled: o, readOnly: i, value: s, options: r, onChange: a, emptyText: h = "Nothing to choose from yet.", name: _ }) {
169
+ const d = G(), m = r.length === 0;
170
+ return /* @__PURE__ */ e(Ce, { id: d, label: n, help: m ? h : l, error: t, children: /* @__PURE__ */ e(
171
171
  "select",
172
172
  {
173
- id: i,
174
- name: f,
173
+ id: d,
174
+ name: _,
175
175
  className: "cms-input cms-select",
176
- value: a,
177
- disabled: o || h,
178
- "aria-readonly": c || void 0,
176
+ value: s,
177
+ disabled: o || m,
178
+ "aria-readonly": i || void 0,
179
179
  "aria-invalid": t != null || void 0,
180
- "aria-describedby": Se(i, { help: h ? m : l, error: t }),
181
- onChange: (u) => {
182
- c || s == null || s(u.target.value);
180
+ "aria-describedby": Se(d, { help: m ? h : l, error: t }),
181
+ onChange: (c) => {
182
+ i || a == null || a(c.target.value);
183
183
  },
184
- children: r.map((u) => /* @__PURE__ */ e("option", { value: u.value, disabled: c && u.value !== a, children: u.label }, u.value))
184
+ children: r.map((c) => /* @__PURE__ */ e("option", { value: c.value, disabled: i && c.value !== s, children: c.label }, c.value))
185
185
  }
186
186
  ) });
187
187
  }
188
- function Fn({ label: n, checked: l, onChange: t, disabled: o, readOnly: c, help: a }) {
189
- const r = X();
190
- return /* @__PURE__ */ d("div", { className: "cms-toggle-row", children: [
188
+ function Rn({ label: n, checked: l, onChange: t, disabled: o, readOnly: i, help: s }) {
189
+ const r = G();
190
+ return /* @__PURE__ */ u("div", { className: "cms-toggle-row", children: [
191
191
  /* @__PURE__ */ e(
192
192
  "button",
193
193
  {
194
194
  id: r,
195
195
  type: "button",
196
196
  role: "switch",
197
- className: E("cms-toggle", l && "is-on"),
197
+ className: A("cms-toggle", l && "is-on"),
198
198
  "aria-checked": l,
199
- "aria-readonly": c || void 0,
200
- "aria-describedby": a != null ? `${r}-help` : void 0,
199
+ "aria-readonly": i || void 0,
200
+ "aria-describedby": s != null ? `${r}-help` : void 0,
201
201
  disabled: o,
202
202
  onClick: () => {
203
- c || t == null || t(!l);
203
+ i || t == null || t(!l);
204
204
  },
205
205
  children: /* @__PURE__ */ e("span", { className: "cms-toggle__thumb" })
206
206
  }
207
207
  ),
208
208
  /* @__PURE__ */ e("label", { className: "cms-toggle__label", htmlFor: r, children: n }),
209
- a != null ? /* @__PURE__ */ e("p", { className: "cms-field__help", id: `${r}-help`, children: a }) : null
209
+ s != null ? /* @__PURE__ */ e("p", { className: "cms-field__help", id: `${r}-help`, children: s }) : null
210
210
  ] });
211
211
  }
212
212
  const je = 150;
213
- function Ie({ open: n, title: l, onClose: t, dirty: o = !1, onDirtyClose: c, children: a, footer: r, closeLabel: s = "Close", initialFocus: m, className: f }) {
214
- const [i, h] = A(n), [u, p] = A(!1), _ = K(null), g = K(null), N = X();
213
+ function Pe({ open: n, title: l, onClose: t, dirty: o = !1, onDirtyClose: i, children: s, footer: r, closeLabel: a = "Close", initialFocus: h, className: _ }) {
214
+ const [d, m] = E(n), [c, f] = E(!1), p = R(null), g = R(null), N = G();
215
215
  if (Y(() => {
216
216
  if (n) {
217
- g.current = document.activeElement, h(!0), p(!1);
217
+ g.current = document.activeElement, m(!0), f(!1);
218
218
  return;
219
219
  }
220
- if (!i) return;
221
- p(!0);
220
+ if (!d) return;
221
+ f(!0);
222
222
  const x = window.setTimeout(() => {
223
223
  var S, C;
224
- h(!1), p(!1), (C = (S = g.current) == null ? void 0 : S.focus) == null || C.call(S);
224
+ m(!1), f(!1), (C = (S = g.current) == null ? void 0 : S.focus) == null || C.call(S);
225
225
  }, je);
226
226
  return () => window.clearTimeout(x);
227
- }, [n, i]), Y(() => {
227
+ }, [n, d]), Y(() => {
228
228
  var x, S;
229
- if (n && i) {
229
+ if (n && d) {
230
230
  const C = 'input, select, textarea, button, [href], [tabindex]:not([tabindex="-1"])';
231
- (S = (m == null ? void 0 : m.current) ?? ((x = _.current) == null ? void 0 : x.querySelector(`.cms-modal__body :is(${C}), .cms-modal__foot :is(${C})`)) ?? _.current) == null || S.focus();
231
+ (S = (h == null ? void 0 : h.current) ?? ((x = p.current) == null ? void 0 : x.querySelector(`.cms-modal__body :is(${C}), .cms-modal__foot :is(${C})`)) ?? p.current) == null || S.focus();
232
232
  }
233
- }, [n, i, m]), !i) return null;
233
+ }, [n, d, h]), !d) return null;
234
234
  const w = () => {
235
- o ? c == null || c() : t();
235
+ o ? i == null || i() : t();
236
236
  };
237
237
  return Me(
238
- /* @__PURE__ */ e("div", { className: E("cms-modal-scrim", u && "is-closing"), onMouseDown: (x) => {
238
+ /* @__PURE__ */ e("div", { className: A("cms-modal-scrim", c && "is-closing"), onMouseDown: (x) => {
239
239
  x.target === x.currentTarget && w();
240
- }, children: /* @__PURE__ */ d(
240
+ }, children: /* @__PURE__ */ u(
241
241
  "div",
242
242
  {
243
- ref: _,
244
- className: E("cms-modal", f, u && "is-closing", o && "is-dirty"),
243
+ ref: p,
244
+ className: A("cms-modal", _, c && "is-closing", o && "is-dirty"),
245
245
  role: "dialog",
246
246
  "aria-modal": "true",
247
247
  "aria-labelledby": N,
@@ -251,18 +251,18 @@ function Ie({ open: n, title: l, onClose: t, dirty: o = !1, onDirtyClose: c, chi
251
251
  if (x.key === "Escape")
252
252
  x.stopPropagation(), w();
253
253
  else if (x.key === "Tab") {
254
- const C = (S = _.current) == null ? void 0 : S.querySelectorAll('input, select, textarea, button:not([disabled]), [href], [tabindex]:not([tabindex="-1"])');
254
+ const C = (S = p.current) == null ? void 0 : S.querySelectorAll('input, select, textarea, button:not([disabled]), [href], [tabindex]:not([tabindex="-1"])');
255
255
  if (!C || C.length === 0) return;
256
256
  const F = C[0], H = C[C.length - 1];
257
257
  x.shiftKey && document.activeElement === F ? (x.preventDefault(), H.focus()) : !x.shiftKey && document.activeElement === H && (x.preventDefault(), F.focus());
258
258
  }
259
259
  },
260
260
  children: [
261
- /* @__PURE__ */ d("header", { className: "cms-modal__head", children: [
261
+ /* @__PURE__ */ u("header", { className: "cms-modal__head", children: [
262
262
  /* @__PURE__ */ e("h2", { className: "cms-modal__title", id: N, children: l }),
263
- /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": s, onClick: w, children: /* @__PURE__ */ e(z, { name: "close" }) })
263
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": a, onClick: w, children: /* @__PURE__ */ e(z, { name: "close" }) })
264
264
  ] }),
265
- /* @__PURE__ */ e("div", { className: "cms-modal__body", children: a }),
265
+ /* @__PURE__ */ e("div", { className: "cms-modal__body", children: s }),
266
266
  r != null ? /* @__PURE__ */ e("footer", { className: "cms-modal__foot", children: r }) : null
267
267
  ]
268
268
  }
@@ -270,20 +270,20 @@ function Ie({ open: n, title: l, onClose: t, dirty: o = !1, onDirtyClose: c, chi
270
270
  document.body
271
271
  );
272
272
  }
273
- function Hn({ open: n, title: l, message: t, kind: o = "default", confirmLabel: c, cancelLabel: a, closeLabel: r, onConfirm: s, onCancel: m }) {
274
- const f = o === "discard-changes";
273
+ function On({ open: n, title: l, message: t, kind: o = "default", confirmLabel: i, cancelLabel: s, closeLabel: r, onConfirm: a, onCancel: h }) {
274
+ const _ = o === "discard-changes";
275
275
  return /* @__PURE__ */ e(
276
- Ie,
276
+ Pe,
277
277
  {
278
278
  open: n,
279
279
  title: l,
280
- onClose: m,
280
+ onClose: h,
281
281
  ...r === void 0 ? {} : { closeLabel: r },
282
- footer: /* @__PURE__ */ d(M, { children: [
283
- /* @__PURE__ */ e(le, { onClick: m, children: a ?? (f ? "Keep editing" : "Cancel") }),
284
- /* @__PURE__ */ e(le, { variant: o === "default" ? "primary" : "danger", onClick: s, children: c ?? (f ? "Discard changes" : "Confirm") })
282
+ footer: /* @__PURE__ */ u(M, { children: [
283
+ /* @__PURE__ */ e(le, { onClick: h, children: s ?? (_ ? "Keep editing" : "Cancel") }),
284
+ /* @__PURE__ */ e(le, { variant: o === "default" ? "primary" : "danger", onClick: a, children: i ?? (_ ? "Discard changes" : "Confirm") })
285
285
  ] }),
286
- children: o !== "default" ? /* @__PURE__ */ d("p", { className: "cms-confirm__warning", children: [
286
+ children: o !== "default" ? /* @__PURE__ */ u("p", { className: "cms-confirm__warning", children: [
287
287
  /* @__PURE__ */ e(z, { name: "warning" }),
288
288
  " ",
289
289
  t
@@ -291,70 +291,70 @@ function Hn({ open: n, title: l, message: t, kind: o = "default", confirmLabel:
291
291
  }
292
292
  );
293
293
  }
294
- function Kn({ kind: n, message: l, action: t, onDismiss: o, dismissLabel: c = "Dismiss" }) {
295
- return /* @__PURE__ */ d("div", { className: E("cms-toast", `cms-toast--${n}`), role: n === "error" ? "alert" : "status", children: [
294
+ function Kn({ kind: n, message: l, action: t, onDismiss: o, dismissLabel: i = "Dismiss" }) {
295
+ return /* @__PURE__ */ u("div", { className: A("cms-toast", `cms-toast--${n}`), role: n === "error" ? "alert" : "status", children: [
296
296
  /* @__PURE__ */ e(z, { name: n === "success" ? "check" : n === "error" ? "warning" : "info" }),
297
297
  /* @__PURE__ */ e("span", { className: "cms-toast__message", children: l }),
298
298
  t ? /* @__PURE__ */ e(le, { className: "cms-toast__action", onClick: t.onAction, children: t.label }) : null,
299
- o ? /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": c, onClick: o, children: /* @__PURE__ */ e(z, { name: "close" }) }) : null
299
+ o ? /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": i, onClick: o, children: /* @__PURE__ */ e(z, { name: "close" }) }) : null
300
300
  ] });
301
301
  }
302
- function On({ children: n }) {
302
+ function Un({ children: n }) {
303
303
  return /* @__PURE__ */ e("div", { className: "cms-toast-region", children: n });
304
304
  }
305
305
  function qe({ what: n, layout: l = "inline" }) {
306
- return /* @__PURE__ */ d("div", { className: E("cms-loading", `cms-loading--${l}`), role: "status", "aria-live": "polite", children: [
306
+ return /* @__PURE__ */ u("div", { className: A("cms-loading", `cms-loading--${l}`), role: "status", "aria-live": "polite", children: [
307
307
  /* @__PURE__ */ e(z, { name: "spinner" }),
308
308
  /* @__PURE__ */ e("span", { children: n })
309
309
  ] });
310
310
  }
311
311
  function Ye({ title: n, hint: l, action: t }) {
312
- return /* @__PURE__ */ d("div", { className: "cms-empty", children: [
312
+ return /* @__PURE__ */ u("div", { className: "cms-empty", children: [
313
313
  /* @__PURE__ */ e("p", { className: "cms-empty__title", children: n }),
314
314
  l != null ? /* @__PURE__ */ e("p", { className: "cms-empty__hint", children: l }) : null,
315
315
  t != null ? /* @__PURE__ */ e("div", { className: "cms-empty__action", children: t }) : null
316
316
  ] });
317
317
  }
318
- function Xe({ message: n, onRetry: l, retryLabel: t = "Try again" }) {
319
- return /* @__PURE__ */ d("div", { className: "cms-error-banner", role: "alert", children: [
318
+ function Ge({ message: n, onRetry: l, retryLabel: t = "Try again" }) {
319
+ return /* @__PURE__ */ u("div", { className: "cms-error-banner", role: "alert", children: [
320
320
  /* @__PURE__ */ e(z, { name: "warning" }),
321
321
  /* @__PURE__ */ e("span", { className: "cms-error-banner__message", children: n }),
322
322
  l ? /* @__PURE__ */ e(le, { onClick: l, children: t }) : null
323
323
  ] });
324
324
  }
325
325
  const ye = 300;
326
- function Ge() {
326
+ function Xe() {
327
327
  if (typeof window > "u" || typeof getComputedStyle != "function") return ye;
328
328
  const n = getComputedStyle(document.documentElement).getPropertyValue("--cms-state-delay").trim(), l = n.endsWith("ms") ? Number.parseFloat(n) : n.endsWith("s") ? Number.parseFloat(n) * 1e3 : Number.NaN;
329
329
  return Number.isFinite(l) && l >= 0 ? l : ye;
330
330
  }
331
331
  function Je() {
332
- return /* @__PURE__ */ d("svg", { className: "cms-state__spinner", viewBox: "0 0 24 24", "aria-hidden": "true", focusable: "false", children: [
332
+ return /* @__PURE__ */ u("svg", { className: "cms-state__spinner", viewBox: "0 0 24 24", "aria-hidden": "true", focusable: "false", children: [
333
333
  /* @__PURE__ */ e("circle", { className: "cms-state__track", cx: "12", cy: "12", r: "10", fill: "none" }),
334
334
  /* @__PURE__ */ e("circle", { className: "cms-state__arc", cx: "12", cy: "12", r: "10", fill: "none", pathLength: "100", strokeDasharray: "28 72" })
335
335
  ] });
336
336
  }
337
- function ne({ kind: n, title: l, description: t, action: o, placement: c = "block" }) {
338
- const [a, r] = A(n !== "loading");
337
+ function ne({ kind: n, title: l, description: t, action: o, placement: i = "block" }) {
338
+ const [s, r] = E(n !== "loading");
339
339
  return Y(() => {
340
340
  if (n !== "loading") {
341
341
  r(!0);
342
342
  return;
343
343
  }
344
344
  r(!1);
345
- const s = window.setTimeout(() => r(!0), Ge());
346
- return () => window.clearTimeout(s);
347
- }, [n]), /* @__PURE__ */ d(
345
+ const a = window.setTimeout(() => r(!0), Xe());
346
+ return () => window.clearTimeout(a);
347
+ }, [n]), /* @__PURE__ */ u(
348
348
  "div",
349
349
  {
350
- className: E("cms-state", `cms-state--${n}`, `cms-state--${c}`, !a && "is-waiting"),
350
+ className: A("cms-state", `cms-state--${n}`, `cms-state--${i}`, !s && "is-waiting"),
351
351
  role: "status",
352
352
  "aria-live": "polite",
353
353
  "data-kind": n,
354
354
  children: [
355
355
  n === "loading" ? /* @__PURE__ */ e(Je, {}) : null,
356
356
  n === "error" || n === "denied" ? /* @__PURE__ */ e(z, { name: n === "error" ? "warning" : "lock" }) : null,
357
- /* @__PURE__ */ d("span", { className: "cms-state__text", children: [
357
+ /* @__PURE__ */ u("span", { className: "cms-state__text", children: [
358
358
  /* @__PURE__ */ e("span", { className: "cms-state__title", children: l }),
359
359
  t !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-state__description", children: t }) : null
360
360
  ] }),
@@ -364,132 +364,132 @@ function ne({ kind: n, title: l, description: t, action: o, placement: c = "bloc
364
364
  );
365
365
  }
366
366
  const Be = {
367
- mail: /* @__PURE__ */ d(M, { children: [
367
+ mail: /* @__PURE__ */ u(M, { children: [
368
368
  /* @__PURE__ */ e("rect", { x: "3", y: "5", width: "18", height: "14", rx: "2" }),
369
369
  /* @__PURE__ */ e("path", { d: "m3 7 9 6 9-6" })
370
370
  ] }),
371
371
  // The envelope with its flap open above it: a message read, or the message itself again.
372
- "mail-open": /* @__PURE__ */ d(M, { children: [
372
+ "mail-open": /* @__PURE__ */ u(M, { children: [
373
373
  /* @__PURE__ */ e("path", { d: "M3 10v9a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-9" }),
374
374
  /* @__PURE__ */ e("path", { d: "m3 10 9-6 9 6" }),
375
375
  /* @__PURE__ */ e("path", { d: "m3 10 9 6 9-6" })
376
376
  ] }),
377
377
  // A clipboard: copy what is shown.
378
- copy: /* @__PURE__ */ d(M, { children: [
378
+ copy: /* @__PURE__ */ u(M, { children: [
379
379
  /* @__PURE__ */ e("rect", { x: "6", y: "4", width: "12", height: "17", rx: "2" }),
380
380
  /* @__PURE__ */ e("path", { d: "M9 4V3h6v1" }),
381
381
  /* @__PURE__ */ e("path", { d: "M9 10h6M9 14h6M9 18h3" })
382
382
  ] }),
383
383
  chat: /* @__PURE__ */ e("path", { d: "M4 12a8 8 0 1 1 4 6.9L4 20l1.1-4A8 8 0 0 1 4 12Z" }),
384
384
  phone: /* @__PURE__ */ e("path", { d: "M5 3h3l2 5-2.5 1.5a11 11 0 0 0 7 7L16 14l5 2v3a2 2 0 0 1-2 2A16 16 0 0 1 3 5a2 2 0 0 1 2-2Z" }),
385
- calendar: /* @__PURE__ */ d(M, { children: [
385
+ calendar: /* @__PURE__ */ u(M, { children: [
386
386
  /* @__PURE__ */ e("rect", { x: "3", y: "5", width: "18", height: "16", rx: "2" }),
387
387
  /* @__PURE__ */ e("path", { d: "M3 10h18M8 3v4M16 3v4" })
388
388
  ] }),
389
- file: /* @__PURE__ */ d(M, { children: [
389
+ file: /* @__PURE__ */ u(M, { children: [
390
390
  /* @__PURE__ */ e("path", { d: "M14 3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9Z" }),
391
391
  /* @__PURE__ */ e("path", { d: "M14 3v6h6M8 13h8M8 17h6" })
392
392
  ] }),
393
393
  // The file, with code's angle brackets in place of its lines: a message's source.
394
- "file-code": /* @__PURE__ */ d(M, { children: [
394
+ "file-code": /* @__PURE__ */ u(M, { children: [
395
395
  /* @__PURE__ */ e("path", { d: "M14 3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9Z" }),
396
396
  /* @__PURE__ */ e("path", { d: "M14 3v6h6" }),
397
397
  /* @__PURE__ */ e("path", { d: "m10 12-2 2.5 2 2.5M14 12l2 2.5-2 2.5" })
398
398
  ] }),
399
- image: /* @__PURE__ */ d(M, { children: [
399
+ image: /* @__PURE__ */ u(M, { children: [
400
400
  /* @__PURE__ */ e("rect", { x: "3", y: "4", width: "18", height: "16", rx: "2" }),
401
401
  /* @__PURE__ */ e("circle", { cx: "9", cy: "10", r: "2" }),
402
402
  /* @__PURE__ */ e("path", { d: "m21 17-5-5-9 8" })
403
403
  ] }),
404
- search: /* @__PURE__ */ d(M, { children: [
404
+ search: /* @__PURE__ */ u(M, { children: [
405
405
  /* @__PURE__ */ e("circle", { cx: "11", cy: "11", r: "7" }),
406
406
  /* @__PURE__ */ e("path", { d: "m20 20-4-4" })
407
407
  ] }),
408
- bell: /* @__PURE__ */ d(M, { children: [
408
+ bell: /* @__PURE__ */ u(M, { children: [
409
409
  /* @__PURE__ */ e("path", { d: "M6 9a6 6 0 1 1 12 0c0 6 2 8 2 8H4s2-2 2-8Z" }),
410
410
  /* @__PURE__ */ e("path", { d: "M10 20a2 2 0 0 0 4 0" })
411
411
  ] }),
412
- pencil: /* @__PURE__ */ d(M, { children: [
412
+ pencil: /* @__PURE__ */ u(M, { children: [
413
413
  /* @__PURE__ */ e("path", { d: "M4 20h4L19 9l-4-4L4 16Z" }),
414
414
  /* @__PURE__ */ e("path", { d: "m13 7 4 4" })
415
415
  ] }),
416
- download: /* @__PURE__ */ d(M, { children: [
416
+ download: /* @__PURE__ */ u(M, { children: [
417
417
  /* @__PURE__ */ e("path", { d: "M12 4v11" }),
418
418
  /* @__PURE__ */ e("path", { d: "m7 11 5 5 5-5" }),
419
419
  /* @__PURE__ */ e("path", { d: "M4 20h16" })
420
420
  ] }),
421
421
  // Download's arrow turned up, from the line: a file sent up.
422
- upload: /* @__PURE__ */ d(M, { children: [
422
+ upload: /* @__PURE__ */ u(M, { children: [
423
423
  /* @__PURE__ */ e("path", { d: "M12 20V9" }),
424
424
  /* @__PURE__ */ e("path", { d: "m7 13 5-5 5 5" }),
425
425
  /* @__PURE__ */ e("path", { d: "M4 4h16" })
426
426
  ] }),
427
- print: /* @__PURE__ */ d(M, { children: [
427
+ print: /* @__PURE__ */ u(M, { children: [
428
428
  /* @__PURE__ */ e("path", { d: "M7 8V4h10v4" }),
429
429
  /* @__PURE__ */ e("rect", { x: "3", y: "8", width: "18", height: "8", rx: "2" }),
430
430
  /* @__PURE__ */ e("path", { d: "M7 14h10v6H7Z" })
431
431
  ] }),
432
- "open-separately": /* @__PURE__ */ d(M, { children: [
432
+ "open-separately": /* @__PURE__ */ u(M, { children: [
433
433
  /* @__PURE__ */ e("path", { d: "M14 4h6v6" }),
434
434
  /* @__PURE__ */ e("path", { d: "m20 4-9 9" }),
435
435
  /* @__PURE__ */ e("path", { d: "M18 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h5" })
436
436
  ] }),
437
437
  star: /* @__PURE__ */ e("path", { d: "m12 3 2.8 5.8 6.2.9-4.5 4.4 1 6.2L12 17.4l-5.5 2.9 1-6.2L3 9.7l6.2-.9Z" }),
438
- send: /* @__PURE__ */ d(M, { children: [
438
+ send: /* @__PURE__ */ u(M, { children: [
439
439
  /* @__PURE__ */ e("path", { d: "M21 3 10 14" }),
440
440
  /* @__PURE__ */ e("path", { d: "M21 3 14 21l-4-7-7-4Z" })
441
441
  ] }),
442
- inbox: /* @__PURE__ */ d(M, { children: [
442
+ inbox: /* @__PURE__ */ u(M, { children: [
443
443
  /* @__PURE__ */ e("path", { d: "M3 13h5l1 3h6l1-3h5" }),
444
444
  /* @__PURE__ */ e("path", { d: "M5 5h14l2 8v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-6Z" })
445
445
  ] }),
446
- archive: /* @__PURE__ */ d(M, { children: [
446
+ archive: /* @__PURE__ */ u(M, { children: [
447
447
  /* @__PURE__ */ e("rect", { x: "3", y: "4", width: "18", height: "5", rx: "1" }),
448
448
  /* @__PURE__ */ e("path", { d: "M5 9v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V9M10 13h4" })
449
449
  ] }),
450
- trash: /* @__PURE__ */ d(M, { children: [
450
+ trash: /* @__PURE__ */ u(M, { children: [
451
451
  /* @__PURE__ */ e("path", { d: "M4 7h16M10 11v6M14 11v6" }),
452
452
  /* @__PURE__ */ e("path", { d: "M6 7l1 13a2 2 0 0 0 2 1h6a2 2 0 0 0 2-1l1-13M9 7V4h6v3" })
453
453
  ] }),
454
454
  paperclip: /* @__PURE__ */ e("path", { d: "m20 11-8.5 8.5a5 5 0 0 1-7-7L13 4a3.5 3.5 0 0 1 5 5l-8.5 8.5a2 2 0 0 1-3-3L14 7" }),
455
- mic: /* @__PURE__ */ d(M, { children: [
455
+ mic: /* @__PURE__ */ u(M, { children: [
456
456
  /* @__PURE__ */ e("rect", { x: "9", y: "3", width: "6", height: "11", rx: "3" }),
457
457
  /* @__PURE__ */ e("path", { d: "M5 11a7 7 0 0 0 14 0M12 18v3" })
458
458
  ] }),
459
- speaker: /* @__PURE__ */ d(M, { children: [
459
+ speaker: /* @__PURE__ */ u(M, { children: [
460
460
  /* @__PURE__ */ e("path", { d: "M4 9h4l5-4v14l-5-4H4Z" }),
461
461
  /* @__PURE__ */ e("path", { d: "M16 9a4 4 0 0 1 0 6M19 6a8 8 0 0 1 0 12" })
462
462
  ] }),
463
- "user-plus": /* @__PURE__ */ d(M, { children: [
463
+ "user-plus": /* @__PURE__ */ u(M, { children: [
464
464
  /* @__PURE__ */ e("circle", { cx: "10", cy: "8", r: "4" }),
465
465
  /* @__PURE__ */ e("path", { d: "M3 21a7 7 0 0 1 14 0M19 8v6M16 11h6" })
466
466
  ] }),
467
467
  // A person, nothing more: one whose account is gone.
468
- user: /* @__PURE__ */ d(M, { children: [
468
+ user: /* @__PURE__ */ u(M, { children: [
469
469
  /* @__PURE__ */ e("circle", { cx: "12", cy: "8", r: "4" }),
470
470
  /* @__PURE__ */ e("path", { d: "M4 21a8 8 0 0 1 16 0" })
471
471
  ] }),
472
472
  // A person with a tick: someone allowed.
473
- "user-check": /* @__PURE__ */ d(M, { children: [
473
+ "user-check": /* @__PURE__ */ u(M, { children: [
474
474
  /* @__PURE__ */ e("circle", { cx: "10", cy: "8", r: "4" }),
475
475
  /* @__PURE__ */ e("path", { d: "M3 21a7 7 0 0 1 14 0M16 11l2 2 4-4" })
476
476
  ] }),
477
477
  // A person with a cross: someone no longer allowed.
478
- "user-x": /* @__PURE__ */ d(M, { children: [
478
+ "user-x": /* @__PURE__ */ u(M, { children: [
479
479
  /* @__PURE__ */ e("circle", { cx: "10", cy: "8", r: "4" }),
480
480
  /* @__PURE__ */ e("path", { d: "M3 21a7 7 0 0 1 14 0M17 8l4 4M21 8l-4 4" })
481
481
  ] }),
482
482
  // Two people: the members of a group.
483
- users: /* @__PURE__ */ d(M, { children: [
483
+ users: /* @__PURE__ */ u(M, { children: [
484
484
  /* @__PURE__ */ e("circle", { cx: "9", cy: "8", r: "3.5" }),
485
485
  /* @__PURE__ */ e("path", { d: "M2.5 20a6.5 6.5 0 0 1 13 0M16 4.6a3.5 3.5 0 0 1 0 6.8M18 14a6.5 6.5 0 0 1 3.5 6" })
486
486
  ] }),
487
487
  "phone-off": /* @__PURE__ */ e("path", { d: "M3 14c5-5 13-5 18 0l-2 3-4-1v-3a10 10 0 0 0-6 0v3l-4 1Z" }),
488
- video: /* @__PURE__ */ d(M, { children: [
488
+ video: /* @__PURE__ */ u(M, { children: [
489
489
  /* @__PURE__ */ e("rect", { x: "3", y: "6", width: "13", height: "12", rx: "2" }),
490
490
  /* @__PURE__ */ e("path", { d: "m16 10 5-3v10l-5-3" })
491
491
  ] }),
492
- info: /* @__PURE__ */ d(M, { children: [
492
+ info: /* @__PURE__ */ u(M, { children: [
493
493
  /* @__PURE__ */ e("circle", { cx: "12", cy: "12", r: "9" }),
494
494
  /* @__PURE__ */ e("path", { d: "M12 11v6M12 7.5v.5" })
495
495
  ] }),
@@ -498,17 +498,17 @@ const Be = {
498
498
  plus: /* @__PURE__ */ e("path", { d: "M12 5v14M5 12h14" }),
499
499
  folder: /* @__PURE__ */ e("path", { d: "M3 6a2 2 0 0 1 2-2h4l2 3h8a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2Z" }),
500
500
  // The folder with a plus inside: a new folder.
501
- "folder-plus": /* @__PURE__ */ d(M, { children: [
501
+ "folder-plus": /* @__PURE__ */ u(M, { children: [
502
502
  /* @__PURE__ */ e("path", { d: "M3 6a2 2 0 0 1 2-2h4l2 3h8a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2Z" }),
503
503
  /* @__PURE__ */ e("path", { d: "M12 10.5v6M9 13.5h6" })
504
504
  ] }),
505
505
  // The folder with a cross inside: a folder removed.
506
- "folder-x": /* @__PURE__ */ d(M, { children: [
506
+ "folder-x": /* @__PURE__ */ u(M, { children: [
507
507
  /* @__PURE__ */ e("path", { d: "M3 6a2 2 0 0 1 2-2h4l2 3h8a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2Z" }),
508
508
  /* @__PURE__ */ e("path", { d: "m9.5 11 5 5M14.5 11l-5 5" })
509
509
  ] }),
510
510
  check: /* @__PURE__ */ e("path", { d: "m5 12 5 5 9-10" }),
511
- server: /* @__PURE__ */ d(M, { children: [
511
+ server: /* @__PURE__ */ u(M, { children: [
512
512
  /* @__PURE__ */ e("rect", { x: "3", y: "4", width: "18", height: "7", rx: "2" }),
513
513
  /* @__PURE__ */ e("rect", { x: "3", y: "13", width: "18", height: "7", rx: "2" }),
514
514
  /* @__PURE__ */ e("path", { d: "M7 7.5h.5M7 16.5h.5" })
@@ -520,7 +520,7 @@ const Be = {
520
520
  more: /* @__PURE__ */ e("path", { d: "M5 12h.5M12 12h.5M19 12h.5" }),
521
521
  important: /* @__PURE__ */ e("path", { d: "M4 6h11l5 6-5 6H4l4-6-4-6Z" })
522
522
  };
523
- function L({ name: n, size: l = 20, label: t }) {
523
+ function T({ name: n, size: l = 20, label: t }) {
524
524
  return /* @__PURE__ */ e(
525
525
  "svg",
526
526
  {
@@ -539,7 +539,7 @@ function L({ name: n, size: l = 20, label: t }) {
539
539
  }
540
540
  );
541
541
  }
542
- const Rn = Object.keys(Be), Ee = {
542
+ const zn = Object.keys(Be), Ae = {
543
543
  reply: "reply",
544
544
  "reply-all": "reply",
545
545
  forward: "forward",
@@ -572,7 +572,7 @@ const Rn = Object.keys(Be), Ee = {
572
572
  "file-earmark-spreadsheet": "file"
573
573
  };
574
574
  function re(n) {
575
- return Object.prototype.hasOwnProperty.call(Ee, n) ? Ee[n] : null;
575
+ return Object.prototype.hasOwnProperty.call(Ae, n) ? Ae[n] : null;
576
576
  }
577
577
  function Qe() {
578
578
  try {
@@ -581,11 +581,11 @@ function Qe() {
581
581
  return !1;
582
582
  }
583
583
  }
584
- const Te = /* @__PURE__ */ new Set();
585
- function Un({ name: n, size: l = 18 }) {
584
+ const Le = /* @__PURE__ */ new Set();
585
+ function Zn({ name: n, size: l = 18 }) {
586
586
  if (n === "") return null;
587
587
  const t = re(n);
588
- return t !== null ? /* @__PURE__ */ e(L, { name: t, size: l }) : (!Te.has(n) && Qe() && (Te.add(n), console.warn(`@coolms/ui-react: no icon for the server's icon name "${n}"; its space is kept empty`)), /* @__PURE__ */ e("span", { className: "cms-icon cms-icon--blank", style: { width: l, height: l }, "aria-hidden": "true", "data-icon-name": n }));
588
+ return t !== null ? /* @__PURE__ */ e(T, { name: t, size: l }) : (!Le.has(n) && Qe() && (Le.add(n), console.warn(`@coolms/ui-react: no icon for the server's icon name "${n}"; its space is kept empty`)), /* @__PURE__ */ e("span", { className: "cms-icon cms-icon--blank", style: { width: l, height: l }, "aria-hidden": "true", "data-icon-name": n }));
589
589
  }
590
590
  const en = 'input, select, textarea, button:not([disabled]), iframe, [href], [tabindex]:not([tabindex="-1"])', nn = 60;
591
591
  function ln(n) {
@@ -597,73 +597,73 @@ function tn(n) {
597
597
  function an(n) {
598
598
  return n.getClientRects().length > 0;
599
599
  }
600
- function zn(n) {
601
- const { name: l, badge: t, closeLabel: o, onClose: c, actions: a = [], moreLabel: r = "More", edit: s, editing: m, state: f, siblings: i, bar: h, thumbnails: u, strip: p, onZoom: _, children: g } = n, N = K(null), w = K(null), x = X(), [S, C] = A(!1), F = K(null);
600
+ function Vn(n) {
601
+ const { name: l, badge: t, closeLabel: o, onClose: i, actions: s = [], moreLabel: r = "More", edit: a, editing: h, state: _, siblings: d, bar: m, thumbnails: c, strip: f, onZoom: p, children: g } = n, N = R(null), w = R(null), x = G(), [S, C] = E(!1), F = R(null);
602
602
  Y(() => {
603
603
  var V;
604
- const y = document.activeElement, I = document.body.style.overflow;
604
+ const y = document.activeElement, P = document.body.style.overflow;
605
605
  return document.body.style.overflow = "hidden", (V = w.current) == null || V.focus(), () => {
606
606
  var D;
607
- document.body.style.overflow = I, (D = y == null ? void 0 : y.focus) == null || D.call(y);
607
+ document.body.style.overflow = P, (D = y == null ? void 0 : y.focus) == null || D.call(y);
608
608
  };
609
609
  }, []);
610
610
  const H = () => {
611
- m != null && m.dirty ? m.onDirtyClose() : c();
611
+ h != null && h.dirty ? h.onDirtyClose() : i();
612
612
  }, ee = (y) => {
613
- const I = y.touches.length === 1 ? y.touches[0] : void 0;
614
- F.current = I === void 0 || m !== void 0 || tn(y.target) ? null : { x: I.clientX, y: I.clientY };
613
+ const P = y.touches.length === 1 ? y.touches[0] : void 0;
614
+ F.current = P === void 0 || h !== void 0 || tn(y.target) ? null : { x: P.clientX, y: P.clientY };
615
615
  }, j = (y) => {
616
- var G, O;
617
- const I = F.current, V = y.changedTouches[0];
618
- if (F.current = null, I === null || V === void 0) return;
619
- const D = V.clientX - I.x;
620
- Math.abs(D) < nn || Math.abs(D) < Math.abs(V.clientY - I.y) || (D > 0 ? (G = i == null ? void 0 : i.onPrevious) == null || G.call(i) : (O = i == null ? void 0 : i.onNext) == null || O.call(i));
616
+ var X, O;
617
+ const P = F.current, V = y.changedTouches[0];
618
+ if (F.current = null, P === null || V === void 0) return;
619
+ const D = V.clientX - P.x;
620
+ Math.abs(D) < nn || Math.abs(D) < Math.abs(V.clientY - P.y) || (D > 0 ? (X = d == null ? void 0 : d.onPrevious) == null || X.call(d) : (O = d == null ? void 0 : d.onNext) == null || O.call(d));
621
621
  };
622
622
  return Me(
623
- /* @__PURE__ */ d(
623
+ /* @__PURE__ */ u(
624
624
  "div",
625
625
  {
626
626
  ref: N,
627
- className: E("cms-viewer", m !== void 0 && "is-editing"),
627
+ className: A("cms-viewer", h !== void 0 && "is-editing"),
628
628
  role: "dialog",
629
629
  "aria-modal": "true",
630
630
  "aria-labelledby": x,
631
631
  tabIndex: -1,
632
632
  onKeyDown: (y) => {
633
- var I, V, D;
633
+ var P, V, D;
634
634
  if (y.key === "Escape") {
635
- if (m !== void 0) return;
636
- y.stopPropagation(), S ? C(!1) : c();
635
+ if (h !== void 0) return;
636
+ y.stopPropagation(), S ? C(!1) : i();
637
637
  } else if (y.key === "Tab") {
638
- const G = Array.from(((I = N.current) == null ? void 0 : I.querySelectorAll(en)) ?? []).filter(an);
639
- if (G.length === 0) return;
640
- const O = G[0], J = G[G.length - 1];
638
+ const X = Array.from(((P = N.current) == null ? void 0 : P.querySelectorAll(en)) ?? []).filter(an);
639
+ if (X.length === 0) return;
640
+ const O = X[0], J = X[X.length - 1];
641
641
  y.shiftKey && document.activeElement === O ? (y.preventDefault(), J.focus()) : !y.shiftKey && document.activeElement === J && (y.preventDefault(), O.focus());
642
- } else m === void 0 && !ln(y.target) && !y.ctrlKey && !y.metaKey && !y.altKey && (y.key === "ArrowLeft" ? (V = i == null ? void 0 : i.onPrevious) == null || V.call(i) : y.key === "ArrowRight" ? (D = i == null ? void 0 : i.onNext) == null || D.call(i) : y.key === "+" || y.key === "=" ? _ == null || _("in") : y.key === "-" ? _ == null || _("out") : y.key === "0" && (_ == null || _("reset")));
642
+ } else h === void 0 && !ln(y.target) && !y.ctrlKey && !y.metaKey && !y.altKey && (y.key === "ArrowLeft" ? (V = d == null ? void 0 : d.onPrevious) == null || V.call(d) : y.key === "ArrowRight" ? (D = d == null ? void 0 : d.onNext) == null || D.call(d) : y.key === "+" || y.key === "=" ? p == null || p("in") : y.key === "-" ? p == null || p("out") : y.key === "0" && (p == null || p("reset")));
643
643
  },
644
644
  children: [
645
- i !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-visually-hidden", role: "status", children: `${l}, ${i.position}` }) : null,
646
- /* @__PURE__ */ d("header", { className: "cms-viewer__top", children: [
645
+ d !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-visually-hidden", role: "status", children: `${l}, ${d.position}` }) : null,
646
+ /* @__PURE__ */ u("header", { className: "cms-viewer__top", children: [
647
647
  /* @__PURE__ */ e("button", { ref: w, type: "button", className: "cms-viewer__icon", "aria-label": o, onClick: H, children: /* @__PURE__ */ e(z, { name: "close" }) }),
648
648
  /* @__PURE__ */ e("span", { className: "cms-viewer__badge", children: t }),
649
649
  /* @__PURE__ */ e("h2", { className: "cms-viewer__name", id: x, title: l, children: l }),
650
- i !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-viewer__position", children: i.position }) : null,
650
+ d !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-viewer__position", children: d.position }) : null,
651
651
  /* @__PURE__ */ e("span", { className: "cms-viewer__space" }),
652
- m !== void 0 ? /* @__PURE__ */ d(M, { children: [
653
- /* @__PURE__ */ e("span", { className: "cms-viewer__status", role: "status", children: m.status }),
654
- /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__button cms-viewer__button--edit", onClick: m.onDone, children: m.doneLabel })
655
- ] }) : /* @__PURE__ */ d(M, { children: [
656
- /* @__PURE__ */ e("span", { className: "cms-viewer__actions", children: a.map((y) => /* @__PURE__ */ d("button", { type: "button", className: "cms-viewer__button", onClick: y.onSelect, children: [
652
+ h !== void 0 ? /* @__PURE__ */ u(M, { children: [
653
+ /* @__PURE__ */ e("span", { className: "cms-viewer__status", role: "status", children: h.status }),
654
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__button cms-viewer__button--edit", onClick: h.onDone, children: h.doneLabel })
655
+ ] }) : /* @__PURE__ */ u(M, { children: [
656
+ /* @__PURE__ */ e("span", { className: "cms-viewer__actions", children: s.map((y) => /* @__PURE__ */ u("button", { type: "button", className: "cms-viewer__button", onClick: y.onSelect, children: [
657
657
  y.icon,
658
658
  y.label
659
659
  ] }, y.label)) }),
660
- s !== void 0 ? /* @__PURE__ */ d("button", { type: "button", className: "cms-viewer__button cms-viewer__button--edit", "aria-label": s.label, onClick: s.onEdit, children: [
661
- s.icon,
662
- /* @__PURE__ */ e("span", { className: "cms-viewer__wide", children: s.label })
660
+ a !== void 0 ? /* @__PURE__ */ u("button", { type: "button", className: "cms-viewer__button cms-viewer__button--edit", "aria-label": a.label, onClick: a.onEdit, children: [
661
+ a.icon,
662
+ /* @__PURE__ */ e("span", { className: "cms-viewer__wide", children: a.label })
663
663
  ] }) : null,
664
- a.length > 0 ? /* @__PURE__ */ d("span", { className: "cms-viewer__more", children: [
665
- /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__icon", "aria-label": r, "aria-expanded": S, onClick: () => C((y) => !y), children: /* @__PURE__ */ e(L, { name: "more" }) }),
666
- S ? /* @__PURE__ */ e("span", { className: "cms-viewer__menu", children: a.map((y) => /* @__PURE__ */ d(
664
+ s.length > 0 ? /* @__PURE__ */ u("span", { className: "cms-viewer__more", children: [
665
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__icon", "aria-label": r, "aria-expanded": S, onClick: () => C((y) => !y), children: /* @__PURE__ */ e(T, { name: "more" }) }),
666
+ S ? /* @__PURE__ */ e("span", { className: "cms-viewer__menu", children: s.map((y) => /* @__PURE__ */ u(
667
667
  "button",
668
668
  {
669
669
  type: "button",
@@ -681,22 +681,22 @@ function zn(n) {
681
681
  ] }) : null
682
682
  ] })
683
683
  ] }),
684
- /* @__PURE__ */ d("div", { className: "cms-viewer__body", children: [
685
- u != null && m === void 0 ? /* @__PURE__ */ e("nav", { className: "cms-viewer__thumbnails", children: u }) : null,
686
- /* @__PURE__ */ d("div", { className: "cms-viewer__content", onTouchStart: ee, onTouchEnd: j, children: [
687
- (m == null ? void 0 : m.conflict) !== void 0 ? /* @__PURE__ */ d("div", { className: "cms-viewer__conflict", role: "alert", children: [
688
- /* @__PURE__ */ e("p", { className: "cms-viewer__conflict-text", children: m.conflict.message }),
689
- /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__button", onClick: m.conflict.onOverwrite, children: m.conflict.overwriteLabel }),
690
- /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__button cms-viewer__button--edit", onClick: m.conflict.onKeepBoth, children: m.conflict.keepBothLabel })
684
+ /* @__PURE__ */ u("div", { className: "cms-viewer__body", children: [
685
+ c != null && h === void 0 ? /* @__PURE__ */ e("nav", { className: "cms-viewer__thumbnails", children: c }) : null,
686
+ /* @__PURE__ */ u("div", { className: "cms-viewer__content", onTouchStart: ee, onTouchEnd: j, children: [
687
+ (h == null ? void 0 : h.conflict) !== void 0 ? /* @__PURE__ */ u("div", { className: "cms-viewer__conflict", role: "alert", children: [
688
+ /* @__PURE__ */ e("p", { className: "cms-viewer__conflict-text", children: h.conflict.message }),
689
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__button", onClick: h.conflict.onOverwrite, children: h.conflict.overwriteLabel }),
690
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__button cms-viewer__button--edit", onClick: h.conflict.onKeepBoth, children: h.conflict.keepBothLabel })
691
691
  ] }) : null,
692
- f === void 0 ? g : /* @__PURE__ */ e(sn, { state: f }),
693
- m === void 0 && (i != null && i.onPrevious) ? /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__side cms-viewer__side--previous", "aria-label": i.previousLabel, title: i.previousLabel, onClick: i.onPrevious, children: /* @__PURE__ */ e(z, { name: "back" }) }) : null,
694
- m === void 0 && (i != null && i.onNext) ? /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__side cms-viewer__side--next", "aria-label": i.nextLabel, title: i.nextLabel, onClick: i.onNext, children: /* @__PURE__ */ e(z, { name: "back" }) }) : null,
695
- m === void 0 && i !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-viewer__dots", "aria-hidden": "true", children: Array.from({ length: Math.min(i.total, 7) }, (y, I) => /* @__PURE__ */ e("i", { className: I === Math.min(i.index, 6) ? "is-current" : void 0 }, I)) }) : null
692
+ _ === void 0 ? g : /* @__PURE__ */ e(sn, { state: _ }),
693
+ h === void 0 && (d != null && d.onPrevious) ? /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__side cms-viewer__side--previous", "aria-label": d.previousLabel, title: d.previousLabel, onClick: d.onPrevious, children: /* @__PURE__ */ e(z, { name: "back" }) }) : null,
694
+ h === void 0 && (d != null && d.onNext) ? /* @__PURE__ */ e("button", { type: "button", className: "cms-viewer__side cms-viewer__side--next", "aria-label": d.nextLabel, title: d.nextLabel, onClick: d.onNext, children: /* @__PURE__ */ e(z, { name: "back" }) }) : null,
695
+ h === void 0 && d !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-viewer__dots", "aria-hidden": "true", children: Array.from({ length: Math.min(d.total, 7) }, (y, P) => /* @__PURE__ */ e("i", { className: P === Math.min(d.index, 6) ? "is-current" : void 0 }, P)) }) : null
696
696
  ] })
697
697
  ] }),
698
- m === void 0 && p != null ? /* @__PURE__ */ e("div", { className: "cms-viewer__strip", children: p }) : null,
699
- h != null ? /* @__PURE__ */ e("footer", { className: "cms-viewer__bar", children: h }) : null
698
+ h === void 0 && f != null ? /* @__PURE__ */ e("div", { className: "cms-viewer__strip", children: f }) : null,
699
+ m != null ? /* @__PURE__ */ e("footer", { className: "cms-viewer__bar", children: m }) : null
700
700
  ]
701
701
  }
702
702
  ),
@@ -738,141 +738,141 @@ class rn extends Error {
738
738
  }
739
739
  const Ne = (n, l) => `${n}
740
740
  ${l}`, cn = (n, l) => n === "" ? l : `${n}/${l}`, on = 48;
741
- function Zn(n) {
741
+ function Wn(n) {
742
742
  var me, he;
743
- const { open: l, spaces: t, list: o, disabledReason: c, budget: a, formatSize: r, labels: s, onConfirm: m, onCancel: f } = n, [i, h] = A(((me = t[0]) == null ? void 0 : me.id) ?? ""), [u, p] = A(""), [_, g] = A({ status: "loading" }), [N, w] = A(0), [x, S] = A(/* @__PURE__ */ new Map()), [C, F] = A(0), [H, ee] = A(!1), j = K(null), y = X();
743
+ const { open: l, spaces: t, list: o, disabledReason: i, budget: s, formatSize: r, labels: a, onConfirm: h, onCancel: _ } = n, [d, m] = E(((me = t[0]) == null ? void 0 : me.id) ?? ""), [c, f] = E(""), [p, g] = E({ status: "loading" }), [N, w] = E(0), [x, S] = E(/* @__PURE__ */ new Map()), [C, F] = E(0), [H, ee] = E(!1), j = R(null), y = G();
744
744
  Y(() => {
745
745
  var b;
746
- l && (h(((b = t[0]) == null ? void 0 : b.id) ?? ""), p(""), S(/* @__PURE__ */ new Map()), ee(!1));
746
+ l && (m(((b = t[0]) == null ? void 0 : b.id) ?? ""), f(""), S(/* @__PURE__ */ new Map()), ee(!1));
747
747
  }, [l]), Y(() => {
748
- if (!l || i === "") return;
748
+ if (!l || d === "") return;
749
749
  let b = !0;
750
- return g({ status: "loading" }), F(0), o(i, u).then(
750
+ return g({ status: "loading" }), F(0), o(d, c).then(
751
751
  (k) => b && g({ status: "ready", entries: k.entries, next: k.next ?? null, paging: !1 }),
752
752
  (k) => b && g({ status: k instanceof rn ? "denied" : "error" })
753
753
  ), () => {
754
754
  b = !1;
755
755
  };
756
- }, [l, i, u, o, N]);
757
- const I = be(() => {
758
- if (_.status !== "ready" || _.next === null || _.paging) return;
759
- const b = _.next, k = _.entries;
760
- g({ ..._, paging: !0 }), o(i, u, b).then(
756
+ }, [l, d, c, o, N]);
757
+ const P = be(() => {
758
+ if (p.status !== "ready" || p.next === null || p.paging) return;
759
+ const b = p.next, k = p.entries;
760
+ g({ ...p, paging: !0 }), o(d, c, b).then(
761
761
  (B) => g({ status: "ready", entries: [...k, ...B.entries], next: B.next ?? null, paging: !1 }),
762
762
  () => g({ status: "ready", entries: k, next: b, paging: !1 })
763
763
  );
764
- }, [_, o, i, u]), V = be((b) => {
764
+ }, [p, o, d, c]), V = be((b) => {
765
765
  var k;
766
- return ((k = a == null ? void 0 : a.cost) == null ? void 0 : k.call(a, b)) ?? b.size ?? 0;
767
- }, [a]), D = Oe(() => [...x.values()], [x]), G = D.reduce((b, k) => b + (k.size ?? 0), 0), O = a === void 0 ? null : a.limitBytes - a.usedBytes - D.reduce((b, k) => b + V(k), 0), J = O !== null && O < 0, ie = (b) => {
766
+ return ((k = s == null ? void 0 : s.cost) == null ? void 0 : k.call(s, b)) ?? b.size ?? 0;
767
+ }, [s]), D = Oe(() => [...x.values()], [x]), X = D.reduce((b, k) => b + (k.size ?? 0), 0), O = s === void 0 ? null : s.limitBytes - s.usedBytes - D.reduce((b, k) => b + V(k), 0), J = O !== null && O < 0, ie = (b) => {
768
768
  if (b.kind !== "file") return null;
769
- const k = c == null ? void 0 : c(b);
770
- return k || (O !== null && !x.has(Ne(i, b.id)) && V(b) > O ? s.overBudget : null);
769
+ const k = i == null ? void 0 : i(b);
770
+ return k || (O !== null && !x.has(Ne(d, b.id)) && V(b) > O ? a.overBudget : null);
771
771
  }, oe = (b) => {
772
- const k = Ne(i, b.id);
772
+ const k = Ne(d, b.id);
773
773
  !x.has(k) && ie(b) !== null || S((B) => {
774
- const R = new Map(B);
775
- return R.has(k) ? R.delete(k) : R.set(k, { ...b, space: i, path: u }), R;
774
+ const K = new Map(B);
775
+ return K.has(k) ? K.delete(k) : K.set(k, { ...b, space: d, path: c }), K;
776
776
  });
777
- }, v = (b) => p(cn(u, b.name)), T = () => p(u.includes("/") ? u.slice(0, u.lastIndexOf("/")) : ""), Z = (b) => S((k) => {
777
+ }, v = (b) => f(cn(c, b.name)), L = () => f(c.includes("/") ? c.slice(0, c.lastIndexOf("/")) : ""), Z = (b) => S((k) => {
778
778
  const B = new Map(k);
779
779
  return B.delete(b), B;
780
- }), W = _.status === "ready" ? _.entries : [], $ = (b) => {
780
+ }), W = p.status === "ready" ? p.entries : [], $ = (b) => {
781
781
  const k = W[C];
782
782
  if (b.key === "ArrowDown" || b.key === "ArrowUp" || b.key === "Home" || b.key === "End") {
783
783
  b.preventDefault();
784
- const B = W.length - 1, R = b.key === "Home" ? 0 : b.key === "End" ? B : Math.min(B, Math.max(0, C + (b.key === "ArrowDown" ? 1 : -1)));
785
- F(R), R >= B - 1 && I();
786
- } else b.key === "Enter" && (k == null ? void 0 : k.kind) === "folder" ? (b.preventDefault(), v(k)) : b.key === " " && (k == null ? void 0 : k.kind) === "file" ? (b.preventDefault(), oe(k)) : b.key === "Backspace" && u !== "" && (b.preventDefault(), T());
787
- }, q = u === "" ? [] : u.split("/"), de = ((he = t.find((b) => b.id === i)) == null ? void 0 : he.name) ?? "", ue = (b) => `${y}-entry-${String(b)}`;
788
- return /* @__PURE__ */ d(
789
- Ie,
784
+ const B = W.length - 1, K = b.key === "Home" ? 0 : b.key === "End" ? B : Math.min(B, Math.max(0, C + (b.key === "ArrowDown" ? 1 : -1)));
785
+ F(K), K >= B - 1 && P();
786
+ } else b.key === "Enter" && (k == null ? void 0 : k.kind) === "folder" ? (b.preventDefault(), v(k)) : b.key === " " && (k == null ? void 0 : k.kind) === "file" ? (b.preventDefault(), oe(k)) : b.key === "Backspace" && c !== "" && (b.preventDefault(), L());
787
+ }, q = c === "" ? [] : c.split("/"), de = ((he = t.find((b) => b.id === d)) == null ? void 0 : he.name) ?? "", ue = (b) => `${y}-entry-${String(b)}`;
788
+ return /* @__PURE__ */ u(
789
+ Pe,
790
790
  {
791
791
  open: l,
792
- title: s.title,
793
- onClose: f,
794
- closeLabel: s.close,
792
+ title: a.title,
793
+ onClose: _,
794
+ closeLabel: a.close,
795
795
  initialFocus: j,
796
796
  className: "cms-file-picker",
797
- footer: /* @__PURE__ */ d("div", { className: "cms-file-picker__foot", children: [
798
- /* @__PURE__ */ d("div", { className: "cms-file-picker__summary", "aria-live": "polite", children: [
799
- D.length > 0 ? /* @__PURE__ */ e("span", { children: s.total(D.length, r(G)) }) : null,
800
- a !== void 0 && O !== null ? /* @__PURE__ */ e("span", { className: E(J && "is-over"), children: J ? s.overBudget : s.left(r(Math.max(0, O)), r(a.limitBytes)) }) : null
797
+ footer: /* @__PURE__ */ u("div", { className: "cms-file-picker__foot", children: [
798
+ /* @__PURE__ */ u("div", { className: "cms-file-picker__summary", "aria-live": "polite", children: [
799
+ D.length > 0 ? /* @__PURE__ */ e("span", { children: a.total(D.length, r(X)) }) : null,
800
+ s !== void 0 && O !== null ? /* @__PURE__ */ e("span", { className: A(J && "is-over"), children: J ? a.overBudget : a.left(r(Math.max(0, O)), r(s.limitBytes)) }) : null
801
801
  ] }),
802
- /* @__PURE__ */ d("div", { className: "cms-file-picker__actions", children: [
803
- /* @__PURE__ */ e(le, { variant: "secondary", onClick: f, children: s.cancel }),
804
- /* @__PURE__ */ e(le, { variant: "primary", disabled: D.length === 0 || J, onClick: () => m(D), children: s.confirm(D.length) })
802
+ /* @__PURE__ */ u("div", { className: "cms-file-picker__actions", children: [
803
+ /* @__PURE__ */ e(le, { variant: "secondary", onClick: _, children: a.cancel }),
804
+ /* @__PURE__ */ e(le, { variant: "primary", disabled: D.length === 0 || J, onClick: () => h(D), children: a.confirm(D.length) })
805
805
  ] })
806
806
  ] }),
807
807
  children: [
808
- /* @__PURE__ */ d("div", { className: "cms-file-picker__top", children: [
809
- t.length > 1 ? /* @__PURE__ */ d("label", { className: "cms-file-picker__space", children: [
810
- /* @__PURE__ */ e("span", { className: "cms-visually-hidden", children: s.space }),
811
- /* @__PURE__ */ e("select", { className: "cms-input cms-select", value: i, onChange: (b) => {
812
- h(b.target.value), p("");
808
+ /* @__PURE__ */ u("div", { className: "cms-file-picker__top", children: [
809
+ t.length > 1 ? /* @__PURE__ */ u("label", { className: "cms-file-picker__space", children: [
810
+ /* @__PURE__ */ e("span", { className: "cms-visually-hidden", children: a.space }),
811
+ /* @__PURE__ */ e("select", { className: "cms-input cms-select", value: d, onChange: (b) => {
812
+ m(b.target.value), f("");
813
813
  }, children: t.map((b) => /* @__PURE__ */ e("option", { value: b.id, children: b.name }, b.id)) })
814
814
  ] }) : null,
815
- /* @__PURE__ */ d("nav", { className: "cms-file-picker__path", "aria-label": s.path, children: [
816
- /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": s.up, disabled: u === "", onClick: T, children: /* @__PURE__ */ e(L, { name: "chevron-left" }) }),
817
- /* @__PURE__ */ d("ol", { children: [
818
- /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e("button", { type: "button", className: "cms-file-picker__crumb", "aria-current": u === "" ? "location" : void 0, onClick: () => p(""), children: de }) }),
815
+ /* @__PURE__ */ u("nav", { className: "cms-file-picker__path", "aria-label": a.path, children: [
816
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": a.up, disabled: c === "", onClick: L, children: /* @__PURE__ */ e(T, { name: "chevron-left" }) }),
817
+ /* @__PURE__ */ u("ol", { children: [
818
+ /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e("button", { type: "button", className: "cms-file-picker__crumb", "aria-current": c === "" ? "location" : void 0, onClick: () => f(""), children: de }) }),
819
819
  q.map((b, k) => {
820
820
  const B = q.slice(0, k + 1).join("/");
821
- return /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e("button", { type: "button", className: "cms-file-picker__crumb", "aria-current": B === u ? "location" : void 0, onClick: () => p(B), children: b }) }, B);
821
+ return /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e("button", { type: "button", className: "cms-file-picker__crumb", "aria-current": B === c ? "location" : void 0, onClick: () => f(B), children: b }) }, B);
822
822
  })
823
823
  ] })
824
824
  ] }),
825
- D.length > 0 ? /* @__PURE__ */ e("button", { type: "button", className: "cms-file-picker__chip", "aria-expanded": H, onClick: () => ee((b) => !b), children: s.selected(D.length) }) : null
825
+ D.length > 0 ? /* @__PURE__ */ e("button", { type: "button", className: "cms-file-picker__chip", "aria-expanded": H, onClick: () => ee((b) => !b), children: a.selected(D.length) }) : null
826
826
  ] }),
827
- H && D.length > 0 ? /* @__PURE__ */ d("div", { className: "cms-file-picker__chosen", children: [
828
- /* @__PURE__ */ e("ul", { children: [...x.entries()].map(([b, k]) => /* @__PURE__ */ d("li", { children: [
827
+ H && D.length > 0 ? /* @__PURE__ */ u("div", { className: "cms-file-picker__chosen", children: [
828
+ /* @__PURE__ */ e("ul", { children: [...x.entries()].map(([b, k]) => /* @__PURE__ */ u("li", { children: [
829
829
  /* @__PURE__ */ e("span", { className: "cms-file-picker__name", children: k.name }),
830
- /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": s.remove(k.name), onClick: () => Z(b), children: /* @__PURE__ */ e(z, { name: "close" }) })
830
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button", "aria-label": a.remove(k.name), onClick: () => Z(b), children: /* @__PURE__ */ e(z, { name: "close" }) })
831
831
  ] }, b)) }),
832
832
  /* @__PURE__ */ e(le, { variant: "secondary", onClick: () => {
833
833
  S(/* @__PURE__ */ new Map()), ee(!1);
834
- }, children: s.clear })
834
+ }, children: a.clear })
835
835
  ] }) : null,
836
- /* @__PURE__ */ d("div", { className: "cms-file-picker__list", onScroll: (b) => {
836
+ /* @__PURE__ */ u("div", { className: "cms-file-picker__list", onScroll: (b) => {
837
837
  const k = b.currentTarget;
838
- k.scrollTop + k.clientHeight >= k.scrollHeight - on && I();
838
+ k.scrollTop + k.clientHeight >= k.scrollHeight - on && P();
839
839
  }, children: [
840
- _.status === "loading" ? /* @__PURE__ */ e(ne, { kind: "loading", title: s.loading, placement: "block" }) : null,
841
- _.status === "error" ? /* @__PURE__ */ e(ne, { kind: "error", title: s.error, placement: "block", action: { label: s.retry, onAction: () => w((b) => b + 1) } }) : null,
842
- _.status === "denied" ? /* @__PURE__ */ e(ne, { kind: "denied", title: s.denied, placement: "block" }) : null,
843
- _.status === "ready" && W.length === 0 ? /* @__PURE__ */ e(ne, { kind: "empty", title: s.empty, placement: "block" }) : null,
844
- /* @__PURE__ */ d(
840
+ p.status === "loading" ? /* @__PURE__ */ e(ne, { kind: "loading", title: a.loading, placement: "block" }) : null,
841
+ p.status === "error" ? /* @__PURE__ */ e(ne, { kind: "error", title: a.error, placement: "block", action: { label: a.retry, onAction: () => w((b) => b + 1) } }) : null,
842
+ p.status === "denied" ? /* @__PURE__ */ e(ne, { kind: "denied", title: a.denied, placement: "block" }) : null,
843
+ p.status === "ready" && W.length === 0 ? /* @__PURE__ */ e(ne, { kind: "empty", title: a.empty, placement: "block" }) : null,
844
+ /* @__PURE__ */ u(
845
845
  "div",
846
846
  {
847
847
  ref: j,
848
848
  role: "listbox",
849
849
  "aria-multiselectable": "true",
850
- "aria-label": s.files,
850
+ "aria-label": a.files,
851
851
  "aria-activedescendant": W.length > 0 ? ue(C) : void 0,
852
852
  tabIndex: 0,
853
853
  className: "cms-file-picker__entries",
854
- hidden: _.status !== "ready" || W.length === 0,
854
+ hidden: p.status !== "ready" || W.length === 0,
855
855
  onKeyDown: $,
856
856
  children: [
857
857
  W.map((b, k) => {
858
- const B = b.kind === "file" && x.has(Ne(i, b.id)), R = ie(b);
859
- return /* @__PURE__ */ d(
858
+ const B = b.kind === "file" && x.has(Ne(d, b.id)), K = ie(b);
859
+ return /* @__PURE__ */ u(
860
860
  "div",
861
861
  {
862
862
  id: ue(k),
863
863
  role: "option",
864
864
  "aria-selected": b.kind === "file" ? B : void 0,
865
- "aria-disabled": R !== null || void 0,
866
- className: E("cms-file-picker__entry", k === C && "is-active", B && "is-ticked", R !== null && "is-disabled"),
865
+ "aria-disabled": K !== null || void 0,
866
+ className: A("cms-file-picker__entry", k === C && "is-active", B && "is-ticked", K !== null && "is-disabled"),
867
867
  onClick: () => {
868
868
  F(k), b.kind === "folder" ? v(b) : oe(b);
869
869
  },
870
870
  children: [
871
- /* @__PURE__ */ e("span", { className: "cms-file-picker__tick", "aria-hidden": "true", children: B ? /* @__PURE__ */ e(L, { name: "check" }) : null }),
872
- /* @__PURE__ */ e(L, { name: b.kind === "folder" ? "folder" : "file" }),
873
- /* @__PURE__ */ d("span", { className: "cms-file-picker__text", children: [
871
+ /* @__PURE__ */ e("span", { className: "cms-file-picker__tick", "aria-hidden": "true", children: B ? /* @__PURE__ */ e(T, { name: "check" }) : null }),
872
+ /* @__PURE__ */ e(T, { name: b.kind === "folder" ? "folder" : "file" }),
873
+ /* @__PURE__ */ u("span", { className: "cms-file-picker__text", children: [
874
874
  /* @__PURE__ */ e("span", { className: "cms-file-picker__name", children: b.name }),
875
- R !== null ? /* @__PURE__ */ e("span", { className: "cms-file-picker__reason", children: R }) : null
875
+ K !== null ? /* @__PURE__ */ e("span", { className: "cms-file-picker__reason", children: K }) : null
876
876
  ] }),
877
877
  b.kind === "file" && b.size != null ? /* @__PURE__ */ e("span", { className: "cms-file-picker__size", children: r(b.size) }) : null
878
878
  ]
@@ -880,7 +880,7 @@ function Zn(n) {
880
880
  b.id
881
881
  );
882
882
  }),
883
- _.status === "ready" && _.paging ? /* @__PURE__ */ e("div", { className: "cms-file-picker__paging", children: /* @__PURE__ */ e(ne, { kind: "loading", title: s.loading, placement: "inline" }) }) : null
883
+ p.status === "ready" && p.paging ? /* @__PURE__ */ e("div", { className: "cms-file-picker__paging", children: /* @__PURE__ */ e(ne, { kind: "loading", title: a.loading, placement: "inline" }) }) : null
884
884
  ]
885
885
  }
886
886
  )
@@ -889,15 +889,15 @@ function Zn(n) {
889
889
  }
890
890
  );
891
891
  }
892
- function Vn({ title: n, scope: l, actions: t, backLink: o }) {
893
- return /* @__PURE__ */ d("header", { className: "cms-page-header", children: [
894
- o ? /* @__PURE__ */ d(
892
+ function jn({ title: n, scope: l, actions: t, backLink: o }) {
893
+ return /* @__PURE__ */ u("header", { className: "cms-page-header", children: [
894
+ o ? /* @__PURE__ */ u(
895
895
  "a",
896
896
  {
897
897
  className: "cms-page-header__back",
898
898
  href: o.href ?? "#",
899
- onClick: (c) => {
900
- o.onBack && (c.preventDefault(), o.onBack());
899
+ onClick: (i) => {
900
+ o.onBack && (i.preventDefault(), o.onBack());
901
901
  },
902
902
  children: [
903
903
  /* @__PURE__ */ e(z, { name: "back" }),
@@ -906,8 +906,8 @@ function Vn({ title: n, scope: l, actions: t, backLink: o }) {
906
906
  ]
907
907
  }
908
908
  ) : null,
909
- /* @__PURE__ */ d("div", { className: "cms-page-header__row", children: [
910
- /* @__PURE__ */ d("div", { className: "cms-page-header__titles", children: [
909
+ /* @__PURE__ */ u("div", { className: "cms-page-header__row", children: [
910
+ /* @__PURE__ */ u("div", { className: "cms-page-header__titles", children: [
911
911
  /* @__PURE__ */ e("h1", { className: "cms-page-header__title", children: n }),
912
912
  l != null ? /* @__PURE__ */ e("p", { className: "cms-page-header__scope", children: l }) : null
913
913
  ] }),
@@ -915,30 +915,30 @@ function Vn({ title: n, scope: l, actions: t, backLink: o }) {
915
915
  ] })
916
916
  ] });
917
917
  }
918
- function Wn({ tabs: n, active: l, onSelect: t, label: o }) {
919
- const c = K([]), a = (r, s) => {
920
- var h;
921
- const m = n.length - 1, f = r.key === "ArrowRight" ? s === m ? 0 : s + 1 : r.key === "ArrowLeft" ? s === 0 ? m : s - 1 : r.key === "Home" ? 0 : r.key === "End" ? m : null;
922
- if (f === null) return;
918
+ function qn({ tabs: n, active: l, onSelect: t, label: o }) {
919
+ const i = R([]), s = (r, a) => {
920
+ var m;
921
+ const h = n.length - 1, _ = r.key === "ArrowRight" ? a === h ? 0 : a + 1 : r.key === "ArrowLeft" ? a === 0 ? h : a - 1 : r.key === "Home" ? 0 : r.key === "End" ? h : null;
922
+ if (_ === null) return;
923
923
  r.preventDefault();
924
- const i = n[f];
925
- i && (t(i.id), (h = c.current[f]) == null || h.focus());
924
+ const d = n[_];
925
+ d && (t(d.id), (m = i.current[_]) == null || m.focus());
926
926
  };
927
- return /* @__PURE__ */ e("div", { className: "cms-tabs", role: "tablist", "aria-label": o, children: n.map((r, s) => {
928
- const m = r.id === l;
929
- return /* @__PURE__ */ d(
927
+ return /* @__PURE__ */ e("div", { className: "cms-tabs", role: "tablist", "aria-label": o, children: n.map((r, a) => {
928
+ const h = r.id === l;
929
+ return /* @__PURE__ */ u(
930
930
  "button",
931
931
  {
932
- ref: (f) => {
933
- c.current[s] = f;
932
+ ref: (_) => {
933
+ i.current[a] = _;
934
934
  },
935
935
  type: "button",
936
936
  role: "tab",
937
- className: E("cms-tab", m && "is-active"),
938
- "aria-selected": m,
939
- tabIndex: m ? 0 : -1,
937
+ className: A("cms-tab", h && "is-active"),
938
+ "aria-selected": h,
939
+ tabIndex: h ? 0 : -1,
940
940
  onClick: () => t(r.id),
941
- onKeyDown: (f) => a(f, s),
941
+ onKeyDown: (_) => s(_, a),
942
942
  children: [
943
943
  r.label,
944
944
  r.count !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-tab__count", children: r.count }) : null
@@ -949,9 +949,9 @@ function Wn({ tabs: n, active: l, onSelect: t, label: o }) {
949
949
  }) });
950
950
  }
951
951
  function dn(n) {
952
- const l = n.trim().replace(/\s+via\s+\S.*$/, "").split(/\s+/).filter(Boolean), t = (c) => {
953
- var a;
954
- return (a = c == null ? void 0 : c.match(/[\p{L}\p{N}]/u)) == null ? void 0 : a[0];
952
+ const l = n.trim().replace(/\s+via\s+\S.*$/, "").split(/\s+/).filter(Boolean), t = (i) => {
953
+ var s;
954
+ return (s = i == null ? void 0 : i.match(/[\p{L}\p{N}]/u)) == null ? void 0 : s[0];
955
955
  };
956
956
  return (l.length > 1 ? [t(l[0]), t(l[l.length - 1])] : [t(l[0])]).filter(Boolean).join("").toUpperCase();
957
957
  }
@@ -961,76 +961,76 @@ function un(n) {
961
961
  l = l * 31 + (t.codePointAt(0) ?? 0) >>> 0;
962
962
  return l % 6 + 1;
963
963
  }
964
- function ve({ name: n, pictureUrl: l, presence: t, connection: o, deleted: c = !1, size: a = 32 }) {
965
- const r = o !== void 0 ? `is-${o.state === "offline" ? "disconnected" : o.state}` : t === void 0 ? null : `is-${t === "busy" ? "away" : t}`, s = o !== void 0 ? `${n}, ${o.label}` : t ? `${n}, ${t}` : n;
966
- return /* @__PURE__ */ d(
964
+ function ve({ name: n, pictureUrl: l, presence: t, connection: o, deleted: i = !1, size: s = 32 }) {
965
+ const r = o !== void 0 ? `is-${o.state === "offline" ? "disconnected" : o.state}` : t === void 0 ? null : `is-${t === "busy" ? "away" : t}`, a = o !== void 0 ? `${n}, ${o.label}` : t ? `${n}, ${t}` : n;
966
+ return /* @__PURE__ */ u(
967
967
  "span",
968
968
  {
969
- className: E("cms-avatar", c ? "cms-avatar--deleted" : `cms-avatar--tint-${un(n)}`),
970
- style: { width: a, height: a, fontSize: Math.round(a * 0.4) },
969
+ className: A("cms-avatar", i ? "cms-avatar--deleted" : `cms-avatar--tint-${un(n)}`),
970
+ style: { width: s, height: s, fontSize: Math.round(s * 0.4) },
971
971
  role: "img",
972
- "aria-label": s,
972
+ "aria-label": a,
973
973
  ...o === void 0 ? {} : { title: o.label },
974
974
  children: [
975
- c ? /* @__PURE__ */ e(L, { name: "user", size: Math.round(a * 0.6) }) : l ? /* @__PURE__ */ e("img", { src: l, alt: "", className: "cms-avatar__picture" }) : /* @__PURE__ */ e("span", { "aria-hidden": "true", children: dn(n) }),
976
- r === null ? null : /* @__PURE__ */ e("span", { className: E("cms-avatar__presence", r), "aria-hidden": "true" })
975
+ i ? /* @__PURE__ */ e(T, { name: "user", size: Math.round(s * 0.6) }) : l ? /* @__PURE__ */ e("img", { src: l, alt: "", className: "cms-avatar__picture" }) : /* @__PURE__ */ e("span", { "aria-hidden": "true", children: dn(n) }),
976
+ r === null ? null : /* @__PURE__ */ e("span", { className: A("cms-avatar__presence", r), "aria-hidden": "true" })
977
977
  ]
978
978
  }
979
979
  );
980
980
  }
981
981
  function mn({ count: n, label: l, max: t = 99 }) {
982
- return n <= 0 ? null : /* @__PURE__ */ d("span", { className: "cms-badge", children: [
982
+ return n <= 0 ? null : /* @__PURE__ */ u("span", { className: "cms-badge", children: [
983
983
  /* @__PURE__ */ e("span", { "aria-hidden": "true", children: n > t ? `${t}+` : n }),
984
984
  /* @__PURE__ */ e("span", { className: "cms-visually-hidden", children: l })
985
985
  ] });
986
986
  }
987
- function jn({ product: n, mark: l, rail: t, active: o, onNavigate: c, server: a, search: r, account: s, children: m, railLabel: f = "Sections" }) {
988
- return /* @__PURE__ */ d("div", { className: "cms-shell", children: [
989
- /* @__PURE__ */ d("nav", { className: "cms-shell__rail", "aria-label": f, children: [
987
+ function Yn({ product: n, mark: l, rail: t, active: o, onNavigate: i, server: s, search: r, account: a, children: h, railLabel: _ = "Sections" }) {
988
+ return /* @__PURE__ */ u("div", { className: "cms-shell", children: [
989
+ /* @__PURE__ */ u("nav", { className: "cms-shell__rail", "aria-label": _, children: [
990
990
  /* @__PURE__ */ e("span", { className: "cms-shell__mark", "aria-hidden": "true", children: l }),
991
- /* @__PURE__ */ e("ul", { className: "cms-shell__items", children: t.map((i) => {
992
- const h = i.id === o;
993
- return /* @__PURE__ */ e("li", { children: /* @__PURE__ */ d(
991
+ /* @__PURE__ */ e("ul", { className: "cms-shell__items", children: t.map((d) => {
992
+ const m = d.id === o;
993
+ return /* @__PURE__ */ e("li", { children: /* @__PURE__ */ u(
994
994
  "a",
995
995
  {
996
- href: i.href,
997
- className: E("cms-shell__item", h && "is-active"),
998
- "aria-current": h ? "page" : void 0,
999
- title: i.label,
1000
- onClick: (u) => {
1001
- c && (u.preventDefault(), c(i.id));
996
+ href: d.href,
997
+ className: A("cms-shell__item", m && "is-active"),
998
+ "aria-current": m ? "page" : void 0,
999
+ title: d.label,
1000
+ onClick: (c) => {
1001
+ i && (c.preventDefault(), i(d.id));
1002
1002
  },
1003
1003
  children: [
1004
- /* @__PURE__ */ d("span", { className: "cms-shell__icon", children: [
1005
- /* @__PURE__ */ e(L, { name: i.icon, size: 22 }),
1006
- i.badge ? /* @__PURE__ */ e(mn, { count: i.badge.count, label: i.badge.label }) : null
1004
+ /* @__PURE__ */ u("span", { className: "cms-shell__icon", children: [
1005
+ /* @__PURE__ */ e(T, { name: d.icon, size: 22 }),
1006
+ d.badge ? /* @__PURE__ */ e(mn, { count: d.badge.count, label: d.badge.label }) : null
1007
1007
  ] }),
1008
- /* @__PURE__ */ e("span", { className: "cms-shell__label", children: i.label })
1008
+ /* @__PURE__ */ e("span", { className: "cms-shell__label", children: d.label })
1009
1009
  ]
1010
1010
  }
1011
- ) }, i.id);
1011
+ ) }, d.id);
1012
1012
  }) })
1013
1013
  ] }),
1014
- /* @__PURE__ */ d("header", { className: "cms-shell__top", children: [
1014
+ /* @__PURE__ */ u("header", { className: "cms-shell__top", children: [
1015
1015
  /* @__PURE__ */ e("span", { className: "cms-shell__product", children: n }),
1016
- a != null ? /* @__PURE__ */ e("div", { className: "cms-shell__server", children: a }) : null,
1016
+ s != null ? /* @__PURE__ */ e("div", { className: "cms-shell__server", children: s }) : null,
1017
1017
  r != null ? /* @__PURE__ */ e("div", { className: "cms-shell__search", children: r }) : null,
1018
- s != null ? /* @__PURE__ */ e("div", { className: "cms-shell__account", children: s }) : null
1018
+ a != null ? /* @__PURE__ */ e("div", { className: "cms-shell__account", children: a }) : null
1019
1019
  ] }),
1020
- /* @__PURE__ */ e("main", { className: "cms-shell__main", children: m })
1020
+ /* @__PURE__ */ e("main", { className: "cms-shell__main", children: h })
1021
1021
  ] });
1022
1022
  }
1023
- function qn({ label: n, placeholder: l, value: t, onChange: o, onSearch: c }) {
1024
- return /* @__PURE__ */ d(
1023
+ function Gn({ label: n, placeholder: l, value: t, onChange: o, onSearch: i }) {
1024
+ return /* @__PURE__ */ u(
1025
1025
  "form",
1026
1026
  {
1027
1027
  role: "search",
1028
1028
  className: "cms-search",
1029
- onSubmit: (a) => {
1030
- a.preventDefault(), c == null || c(t);
1029
+ onSubmit: (s) => {
1030
+ s.preventDefault(), i == null || i(t);
1031
1031
  },
1032
1032
  children: [
1033
- /* @__PURE__ */ e(L, { name: "search", size: 18 }),
1033
+ /* @__PURE__ */ e(T, { name: "search", size: 18 }),
1034
1034
  /* @__PURE__ */ e(
1035
1035
  "input",
1036
1036
  {
@@ -1039,7 +1039,7 @@ function qn({ label: n, placeholder: l, value: t, onChange: o, onSearch: c }) {
1039
1039
  "aria-label": n,
1040
1040
  placeholder: l,
1041
1041
  value: t,
1042
- onChange: (a) => o(a.target.value)
1042
+ onChange: (s) => o(s.target.value)
1043
1043
  }
1044
1044
  )
1045
1045
  ]
@@ -1047,31 +1047,31 @@ function qn({ label: n, placeholder: l, value: t, onChange: o, onSearch: c }) {
1047
1047
  );
1048
1048
  }
1049
1049
  function hn({ options: n, value: l, onChange: t, label: o }) {
1050
- const c = K([]), a = (r, s) => {
1051
- var h;
1052
- const m = n.length - 1, f = r.key === "ArrowRight" || r.key === "ArrowDown" ? s === m ? 0 : s + 1 : r.key === "ArrowLeft" || r.key === "ArrowUp" ? s === 0 ? m : s - 1 : null;
1053
- if (f === null) return;
1050
+ const i = R([]), s = (r, a) => {
1051
+ var m;
1052
+ const h = n.length - 1, _ = r.key === "ArrowRight" || r.key === "ArrowDown" ? a === h ? 0 : a + 1 : r.key === "ArrowLeft" || r.key === "ArrowUp" ? a === 0 ? h : a - 1 : null;
1053
+ if (_ === null) return;
1054
1054
  r.preventDefault();
1055
- const i = n[f];
1056
- i && (t(i.id), (h = c.current[f]) == null || h.focus());
1055
+ const d = n[_];
1056
+ d && (t(d.id), (m = i.current[_]) == null || m.focus());
1057
1057
  };
1058
- return /* @__PURE__ */ e("div", { className: "cms-chips", role: "radiogroup", "aria-label": o, children: n.map((r, s) => {
1059
- const m = r.id === l;
1060
- return /* @__PURE__ */ d(
1058
+ return /* @__PURE__ */ e("div", { className: "cms-chips", role: "radiogroup", "aria-label": o, children: n.map((r, a) => {
1059
+ const h = r.id === l;
1060
+ return /* @__PURE__ */ u(
1061
1061
  "button",
1062
1062
  {
1063
- ref: (f) => {
1064
- c.current[s] = f;
1063
+ ref: (_) => {
1064
+ i.current[a] = _;
1065
1065
  },
1066
1066
  type: "button",
1067
1067
  role: "radio",
1068
- "aria-checked": m,
1069
- tabIndex: m ? 0 : -1,
1070
- className: E("cms-chip", m && "is-on"),
1068
+ "aria-checked": h,
1069
+ tabIndex: h ? 0 : -1,
1070
+ className: A("cms-chip", h && "is-on"),
1071
1071
  onClick: () => t(r.id),
1072
- onKeyDown: (f) => a(f, s),
1072
+ onKeyDown: (_) => s(_, a),
1073
1073
  children: [
1074
- m ? /* @__PURE__ */ e(L, { name: "check", size: 16 }) : null,
1074
+ h ? /* @__PURE__ */ e(T, { name: "check", size: 16 }) : null,
1075
1075
  r.label
1076
1076
  ]
1077
1077
  },
@@ -1079,18 +1079,18 @@ function hn({ options: n, value: l, onChange: t, label: o }) {
1079
1079
  );
1080
1080
  }) });
1081
1081
  }
1082
- const Le = 16;
1082
+ const Te = 16;
1083
1083
  function fn(n, l, t) {
1084
- const o = n.map((a) => Math.min(Math.max(a.width, a.min), a.max));
1085
- let c = o.reduce((a, r) => a + r, 0) + t - l;
1086
- for (let a = o.length - 1; a >= 0 && c > 0; a -= 1) {
1087
- const r = Math.min(c, o[a] - n[a].min);
1088
- o[a] = o[a] - r, c -= r;
1084
+ const o = n.map((s) => Math.min(Math.max(s.width, s.min), s.max));
1085
+ let i = o.reduce((s, r) => s + r, 0) + t - l;
1086
+ for (let s = o.length - 1; s >= 0 && i > 0; s -= 1) {
1087
+ const r = Math.min(i, o[s] - n[s].min);
1088
+ o[s] = o[s] - r, i -= r;
1089
1089
  }
1090
1090
  return o;
1091
1091
  }
1092
- function pn({ index: n, size: l, shown: t, others: o, room: c, lastMin: a, onResize: r }) {
1093
- const s = Math.max(l.min, Math.min(l.max, c > 0 ? c - o - a : l.max)), m = (h) => Math.round(Math.min(Math.max(h, l.min), s)), f = K(null), i = (h, u) => r == null ? void 0 : r(n, m(h), u);
1092
+ function pn({ index: n, size: l, shown: t, others: o, room: i, lastMin: s, onResize: r }) {
1093
+ const a = Math.max(l.min, Math.min(l.max, i > 0 ? i - o - s : l.max)), h = (m) => Math.round(Math.min(Math.max(m, l.min), a)), _ = R(null), d = (m, c) => r == null ? void 0 : r(n, h(m), c);
1094
1094
  return /* @__PURE__ */ e(
1095
1095
  "div",
1096
1096
  {
@@ -1100,102 +1100,102 @@ function pn({ index: n, size: l, shown: t, others: o, room: c, lastMin: a, onRes
1100
1100
  "aria-label": l.label,
1101
1101
  "aria-valuenow": t,
1102
1102
  "aria-valuemin": l.min,
1103
- "aria-valuemax": s,
1103
+ "aria-valuemax": a,
1104
1104
  className: "cms-panes__splitter",
1105
1105
  style: { "--split-at": `var(--split-pane-end-${String(n)})` },
1106
- onPointerDown: (h) => {
1107
- var u, p, _;
1108
- h.button > 0 || (h.preventDefault(), (p = (u = h.currentTarget).setPointerCapture) == null || p.call(u, h.pointerId), f.current = { x: h.clientX, from: t, last: t }, (_ = h.currentTarget.closest(".cms-panes")) == null || _.classList.add("is-resizing"));
1106
+ onPointerDown: (m) => {
1107
+ var c, f, p;
1108
+ m.button > 0 || (m.preventDefault(), (f = (c = m.currentTarget).setPointerCapture) == null || f.call(c, m.pointerId), _.current = { x: m.clientX, from: t, last: t }, (p = m.currentTarget.closest(".cms-panes")) == null || p.classList.add("is-resizing"));
1109
1109
  },
1110
- onPointerMove: (h) => {
1111
- const u = f.current;
1112
- u === null || !Number.isFinite(h.clientX) || (u.last = m(u.from + h.clientX - u.x), i(u.last, !1));
1110
+ onPointerMove: (m) => {
1111
+ const c = _.current;
1112
+ c === null || !Number.isFinite(m.clientX) || (c.last = h(c.from + m.clientX - c.x), d(c.last, !1));
1113
1113
  },
1114
- onPointerUp: (h) => {
1115
- var p;
1116
- const u = f.current;
1117
- u !== null && (f.current = null, (p = h.currentTarget.closest(".cms-panes")) == null || p.classList.remove("is-resizing"), i(u.last, !0));
1114
+ onPointerUp: (m) => {
1115
+ var f;
1116
+ const c = _.current;
1117
+ c !== null && (_.current = null, (f = m.currentTarget.closest(".cms-panes")) == null || f.classList.remove("is-resizing"), d(c.last, !0));
1118
1118
  },
1119
- onPointerCancel: (h) => {
1120
- var p;
1121
- const u = f.current;
1122
- f.current = null, (p = h.currentTarget.closest(".cms-panes")) == null || p.classList.remove("is-resizing"), u !== null && i(u.last, !0);
1119
+ onPointerCancel: (m) => {
1120
+ var f;
1121
+ const c = _.current;
1122
+ _.current = null, (f = m.currentTarget.closest(".cms-panes")) == null || f.classList.remove("is-resizing"), c !== null && d(c.last, !0);
1123
1123
  },
1124
- onDoubleClick: () => i(l.reset, !0),
1125
- onKeyDown: (h) => {
1126
- const u = h.key === "ArrowLeft" ? t - Le : h.key === "ArrowRight" ? t + Le : h.key === "Home" ? l.min : h.key === "End" ? s : h.key === "Enter" ? l.reset : null;
1127
- u !== null && (h.preventDefault(), i(u, !0));
1124
+ onDoubleClick: () => d(l.reset, !0),
1125
+ onKeyDown: (m) => {
1126
+ const c = m.key === "ArrowLeft" ? t - Te : m.key === "ArrowRight" ? t + Te : m.key === "Home" ? l.min : m.key === "End" ? a : m.key === "Enter" ? l.reset : null;
1127
+ c !== null && (m.preventDefault(), d(c, !0));
1128
1128
  }
1129
1129
  }
1130
1130
  );
1131
1131
  }
1132
- function Yn({ panes: n, active: l, back: t, sizes: o, lastMin: c = 360, onResize: a }) {
1133
- const r = Math.min(Math.max(l ?? n.length - 1, 0), n.length - 1), s = K(null), [m, f] = A(0), i = (o ?? []).slice(0, n.length - 1), h = i.length === n.length - 1 && i.every((_) => _ !== void 0);
1132
+ function Xn({ panes: n, active: l, back: t, sizes: o, lastMin: i = 360, onResize: s }) {
1133
+ const r = Math.min(Math.max(l ?? n.length - 1, 0), n.length - 1), a = R(null), [h, _] = E(0), d = (o ?? []).slice(0, n.length - 1), m = d.length === n.length - 1 && d.every((p) => p !== void 0);
1134
1134
  xe(() => {
1135
- const _ = s.current;
1136
- if (_ === null || !h) return;
1137
- const g = () => f(_.clientWidth);
1135
+ const p = a.current;
1136
+ if (p === null || !m) return;
1137
+ const g = () => _(p.clientWidth);
1138
1138
  if (g(), typeof ResizeObserver > "u") return;
1139
1139
  const N = new ResizeObserver(g);
1140
- return N.observe(_), () => N.disconnect();
1141
- }, [h]);
1142
- const u = h ? fn(i, m > 0 ? m : Number.POSITIVE_INFINITY, c) : [], p = h ? Object.fromEntries(u.flatMap((_, g) => [
1143
- [`--split-pane-${String(g)}`, `${String(_)}px`],
1144
- [`--split-pane-end-${String(g)}`, `${String(u.slice(0, g + 1).reduce((N, w) => N + w, 0))}px`]
1140
+ return N.observe(p), () => N.disconnect();
1141
+ }, [m]);
1142
+ const c = m ? fn(d, h > 0 ? h : Number.POSITIVE_INFINITY, i) : [], f = m ? Object.fromEntries(c.flatMap((p, g) => [
1143
+ [`--split-pane-${String(g)}`, `${String(p)}px`],
1144
+ [`--split-pane-end-${String(g)}`, `${String(c.slice(0, g + 1).reduce((N, w) => N + w, 0))}px`]
1145
1145
  ])) : void 0;
1146
- return /* @__PURE__ */ d(
1146
+ return /* @__PURE__ */ u(
1147
1147
  "div",
1148
1148
  {
1149
- ref: s,
1150
- className: E("cms-panes", n.length === 3 ? "cms-panes--three" : "cms-panes--two", h && "cms-panes--sized"),
1149
+ ref: a,
1150
+ className: A("cms-panes", n.length === 3 ? "cms-panes--three" : "cms-panes--two", m && "cms-panes--sized"),
1151
1151
  "data-active": r,
1152
- style: p,
1152
+ style: f,
1153
1153
  children: [
1154
- n.map((_, g) => /* @__PURE__ */ d("section", { className: "cms-panes__pane", "aria-label": _.label, "data-offset": r - g, children: [
1155
- g === r && t ? /* @__PURE__ */ d("a", { className: "cms-panes__back", href: t.href, children: [
1156
- /* @__PURE__ */ e(L, { name: "chevron-left", size: 18 }),
1154
+ n.map((p, g) => /* @__PURE__ */ u("section", { className: "cms-panes__pane", "aria-label": p.label, "data-offset": r - g, children: [
1155
+ g === r && t ? /* @__PURE__ */ u("a", { className: "cms-panes__back", href: t.href, children: [
1156
+ /* @__PURE__ */ e(T, { name: "chevron-left", size: 18 }),
1157
1157
  t.label
1158
1158
  ] }) : null,
1159
- _.content
1160
- ] }, _.label)),
1161
- h ? i.map((_, g) => /* @__PURE__ */ e(
1159
+ p.content
1160
+ ] }, p.label)),
1161
+ m ? d.map((p, g) => /* @__PURE__ */ e(
1162
1162
  pn,
1163
1163
  {
1164
1164
  index: g,
1165
- size: _,
1166
- shown: u[g],
1167
- others: u.reduce((N, w, x) => x === g ? N : N + w, 0),
1168
- room: m,
1169
- lastMin: c,
1170
- onResize: a
1165
+ size: p,
1166
+ shown: c[g],
1167
+ others: c.reduce((N, w, x) => x === g ? N : N + w, 0),
1168
+ room: h,
1169
+ lastMin: i,
1170
+ onResize: s
1171
1171
  },
1172
- _.label
1172
+ p.label
1173
1173
  )) : null
1174
1174
  ]
1175
1175
  }
1176
1176
  );
1177
1177
  }
1178
1178
  const _n = { attachment: "Has an attachment", unread: "Unread" };
1179
- function Xn({ from: n, subject: l, preview: t, time: o, unread: c, hasAttachment: a, selected: r, onOpen: s, labels: m }) {
1180
- const f = ce(_n, m);
1181
- return /* @__PURE__ */ d(
1179
+ function Jn({ from: n, subject: l, preview: t, time: o, unread: i, hasAttachment: s, selected: r, onOpen: a, labels: h }) {
1180
+ const _ = ce(_n, h);
1181
+ return /* @__PURE__ */ u(
1182
1182
  "button",
1183
1183
  {
1184
1184
  type: "button",
1185
- className: E("cms-mail-row", c && "is-unread", r && "is-selected"),
1185
+ className: A("cms-mail-row", i && "is-unread", r && "is-selected"),
1186
1186
  "aria-current": r ? "true" : void 0,
1187
- onClick: s,
1187
+ onClick: a,
1188
1188
  children: [
1189
1189
  /* @__PURE__ */ e(ve, { name: n, size: 40 }),
1190
- /* @__PURE__ */ d("span", { className: "cms-mail-row__body", children: [
1191
- /* @__PURE__ */ d("span", { className: "cms-mail-row__line", children: [
1190
+ /* @__PURE__ */ u("span", { className: "cms-mail-row__body", children: [
1191
+ /* @__PURE__ */ u("span", { className: "cms-mail-row__line", children: [
1192
1192
  /* @__PURE__ */ e("span", { className: "cms-mail-row__from", children: n }),
1193
- a ? /* @__PURE__ */ e(L, { name: "paperclip", size: 16, label: f.attachment }) : null,
1193
+ s ? /* @__PURE__ */ e(T, { name: "paperclip", size: 16, label: _.attachment }) : null,
1194
1194
  /* @__PURE__ */ e("span", { className: "cms-mail-row__time", children: o })
1195
1195
  ] }),
1196
- /* @__PURE__ */ d("span", { className: "cms-mail-row__line", children: [
1196
+ /* @__PURE__ */ u("span", { className: "cms-mail-row__line", children: [
1197
1197
  /* @__PURE__ */ e("span", { className: "cms-mail-row__subject", children: l }),
1198
- c ? /* @__PURE__ */ e("span", { className: "cms-mail-row__dot", role: "img", "aria-label": f.unread }) : null
1198
+ i ? /* @__PURE__ */ e("span", { className: "cms-mail-row__dot", role: "img", "aria-label": _.unread }) : null
1199
1199
  ] }),
1200
1200
  /* @__PURE__ */ e("span", { className: "cms-mail-row__preview", children: t })
1201
1201
  ] })
@@ -1203,49 +1203,49 @@ function Xn({ from: n, subject: l, preview: t, time: o, unread: c, hasAttachment
1203
1203
  }
1204
1204
  );
1205
1205
  }
1206
- function Gn({ direction: n, children: l, time: t, read: o, readLabel: c = "Read" }) {
1207
- return /* @__PURE__ */ d("div", { className: E("cms-bubble", `cms-bubble--${n}`), children: [
1206
+ function Qn({ direction: n, children: l, time: t, read: o, readLabel: i = "Read" }) {
1207
+ return /* @__PURE__ */ u("div", { className: A("cms-bubble", `cms-bubble--${n}`), children: [
1208
1208
  /* @__PURE__ */ e("div", { className: "cms-bubble__text", children: l }),
1209
- /* @__PURE__ */ d("div", { className: "cms-bubble__meta", children: [
1209
+ /* @__PURE__ */ u("div", { className: "cms-bubble__meta", children: [
1210
1210
  t,
1211
- n === "out" && o ? /* @__PURE__ */ d(M, { children: [
1211
+ n === "out" && o ? /* @__PURE__ */ u(M, { children: [
1212
1212
  " · ",
1213
- c
1213
+ i
1214
1214
  ] }) : null
1215
1215
  ] })
1216
1216
  ] });
1217
1217
  }
1218
- function Jn({ label: n, value: l, onChange: t, onSend: o, onAttach: c, placeholder: a, variant: r = "chat", sendLabel: s = "Send", attachLabel: m = "Attach a file", leading: f, canSend: i }) {
1219
- const h = X(), u = i ?? l.trim() !== "", p = (g) => {
1220
- g.preventDefault(), u && o();
1221
- }, _ = c ? /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button cms-composer__attach", "aria-label": m, onClick: c, children: /* @__PURE__ */ e(L, { name: "paperclip" }) }) : null;
1222
- return /* @__PURE__ */ d("form", { className: E("cms-composer", `cms-composer--${r}`), onSubmit: p, children: [
1223
- /* @__PURE__ */ e("label", { htmlFor: h, className: r === "reply" ? "cms-composer__title" : "cms-visually-hidden", children: n }),
1224
- r === "chat" ? _ : null,
1218
+ function el({ label: n, value: l, onChange: t, onSend: o, onAttach: i, placeholder: s, variant: r = "chat", sendLabel: a = "Send", attachLabel: h = "Attach a file", leading: _, canSend: d }) {
1219
+ const m = G(), c = d ?? l.trim() !== "", f = (g) => {
1220
+ g.preventDefault(), c && o();
1221
+ }, p = i ? /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button cms-composer__attach", "aria-label": h, onClick: i, children: /* @__PURE__ */ e(T, { name: "paperclip" }) }) : null;
1222
+ return /* @__PURE__ */ u("form", { className: A("cms-composer", `cms-composer--${r}`), onSubmit: f, children: [
1223
+ /* @__PURE__ */ e("label", { htmlFor: m, className: r === "reply" ? "cms-composer__title" : "cms-visually-hidden", children: n }),
1224
+ r === "chat" ? p : null,
1225
1225
  /* @__PURE__ */ e(
1226
1226
  "textarea",
1227
1227
  {
1228
- id: h,
1228
+ id: m,
1229
1229
  className: "cms-composer__input",
1230
1230
  rows: r === "reply" ? 3 : 1,
1231
- placeholder: a,
1231
+ placeholder: s,
1232
1232
  value: l,
1233
1233
  onChange: (g) => t(g.target.value),
1234
1234
  onKeyDown: (g) => {
1235
- g.nativeEvent.isComposing || g.keyCode === 229 || r === "chat" && g.key === "Enter" && !g.shiftKey && (g.preventDefault(), u && o());
1235
+ g.nativeEvent.isComposing || g.keyCode === 229 || r === "chat" && g.key === "Enter" && !g.shiftKey && (g.preventDefault(), c && o());
1236
1236
  }
1237
1237
  }
1238
1238
  ),
1239
- r === "reply" && f !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-composer__leading", children: f }) : null,
1240
- r === "reply" ? _ : null,
1241
- r === "chat" ? /* @__PURE__ */ e("button", { type: "submit", className: "cms-composer__send-round", "aria-label": s, disabled: !u, children: /* @__PURE__ */ e(L, { name: "send" }) }) : /* @__PURE__ */ d("button", { type: "submit", className: "cms-button cms-button--chrome cms-composer__send", disabled: !u, children: [
1242
- s,
1239
+ r === "reply" && _ !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-composer__leading", children: _ }) : null,
1240
+ r === "reply" ? p : null,
1241
+ r === "chat" ? /* @__PURE__ */ e("button", { type: "submit", className: "cms-composer__send-round", "aria-label": a, disabled: !c, children: /* @__PURE__ */ e(T, { name: "send" }) }) : /* @__PURE__ */ u("button", { type: "submit", className: "cms-button cms-button--chrome cms-composer__send", disabled: !c, children: [
1242
+ a,
1243
1243
  " ",
1244
- /* @__PURE__ */ e(L, { name: "send", size: 18 })
1244
+ /* @__PURE__ */ e(T, { name: "send", size: 18 })
1245
1245
  ] })
1246
1246
  ] });
1247
1247
  }
1248
- const Ae = {
1248
+ const Ee = {
1249
1249
  incomingAudio: "Incoming audio call",
1250
1250
  incomingVideo: "Incoming video call",
1251
1251
  incomingFrom: (n, l) => `${n} from ${l}`,
@@ -1266,88 +1266,88 @@ const Ae = {
1266
1266
  onCallWith: (n) => `On a call with ${n}`,
1267
1267
  returnToCall: "Return to call"
1268
1268
  };
1269
- function Qn({ name: n, media: l, onAccept: t, onDecline: o, labels: c }) {
1270
- const a = ce(Ae, c), r = l === "video" ? a.incomingVideo : a.incomingAudio;
1271
- return /* @__PURE__ */ d("div", { className: "cms-call-incoming", role: "alertdialog", "aria-label": a.incomingFrom(r, n), children: [
1269
+ function nl({ name: n, media: l, onAccept: t, onDecline: o, labels: i }) {
1270
+ const s = ce(Ee, i), r = l === "video" ? s.incomingVideo : s.incomingAudio;
1271
+ return /* @__PURE__ */ u("div", { className: "cms-call-incoming", role: "alertdialog", "aria-label": s.incomingFrom(r, n), children: [
1272
1272
  /* @__PURE__ */ e("span", { className: "cms-call-incoming__ring", "aria-hidden": "true", children: /* @__PURE__ */ e(ve, { name: n, size: 112 }) }),
1273
1273
  /* @__PURE__ */ e("p", { className: "cms-call-incoming__name", children: n }),
1274
1274
  /* @__PURE__ */ e("p", { className: "cms-call-incoming__what", children: r }),
1275
- /* @__PURE__ */ d("div", { className: "cms-call-incoming__actions", children: [
1276
- /* @__PURE__ */ e(ae, { icon: "phone-off", label: a.decline, tone: "hang-up", onClick: o }),
1277
- /* @__PURE__ */ e(ae, { icon: "phone", label: a.accept, tone: "accept", onClick: t })
1275
+ /* @__PURE__ */ u("div", { className: "cms-call-incoming__actions", children: [
1276
+ /* @__PURE__ */ e(ae, { icon: "phone-off", label: s.decline, tone: "hang-up", onClick: o }),
1277
+ /* @__PURE__ */ e(ae, { icon: "phone", label: s.accept, tone: "accept", onClick: t })
1278
1278
  ] })
1279
1279
  ] });
1280
1280
  }
1281
- function ae({ icon: n, label: l, onClick: t, tone: o = "plain", pressed: c }) {
1282
- return /* @__PURE__ */ d(
1281
+ function ae({ icon: n, label: l, onClick: t, tone: o = "plain", pressed: i }) {
1282
+ return /* @__PURE__ */ u(
1283
1283
  "button",
1284
1284
  {
1285
1285
  type: "button",
1286
- className: E("cms-call-button", `cms-call-button--${o}`, c && "is-pressed"),
1287
- "aria-pressed": c,
1286
+ className: A("cms-call-button", `cms-call-button--${o}`, i && "is-pressed"),
1287
+ "aria-pressed": i,
1288
1288
  onClick: t,
1289
1289
  children: [
1290
- /* @__PURE__ */ e("span", { className: "cms-call-button__disc", children: /* @__PURE__ */ e(L, { name: n, size: 24 }) }),
1290
+ /* @__PURE__ */ e("span", { className: "cms-call-button__disc", children: /* @__PURE__ */ e(T, { name: n, size: 24 }) }),
1291
1291
  /* @__PURE__ */ e("span", { className: "cms-call-button__label", children: l })
1292
1292
  ]
1293
1293
  }
1294
1294
  );
1295
1295
  }
1296
- function el({ name: n, duration: l, connection: t, you: o, muted: c, speaker: a, onToggleMute: r, onToggleSpeaker: s, onAddPerson: m, onChat: f, onHangUp: i, labels: h }) {
1297
- const u = ce(Ae, h);
1298
- return /* @__PURE__ */ d("section", { className: "cms-call-panel", "aria-label": u.callWith(n), children: [
1299
- /* @__PURE__ */ d("div", { className: "cms-call-panel__head", children: [
1296
+ function ll({ name: n, duration: l, connection: t, you: o, muted: i, speaker: s, onToggleMute: r, onToggleSpeaker: a, onAddPerson: h, onChat: _, onHangUp: d, labels: m }) {
1297
+ const c = ce(Ee, m);
1298
+ return /* @__PURE__ */ u("section", { className: "cms-call-panel", "aria-label": c.callWith(n), children: [
1299
+ /* @__PURE__ */ u("div", { className: "cms-call-panel__head", children: [
1300
1300
  /* @__PURE__ */ e(ve, { name: n, size: 64 }),
1301
- /* @__PURE__ */ d("div", { className: "cms-call-panel__who", children: [
1301
+ /* @__PURE__ */ u("div", { className: "cms-call-panel__who", children: [
1302
1302
  /* @__PURE__ */ e("p", { className: "cms-call-panel__name", children: n }),
1303
- /* @__PURE__ */ e("p", { className: "cms-call-panel__time", "aria-label": u.callTime(l), children: l })
1303
+ /* @__PURE__ */ e("p", { className: "cms-call-panel__time", "aria-label": c.callTime(l), children: l })
1304
1304
  ] }),
1305
- /* @__PURE__ */ e("span", { className: E("cms-pill", t === "good" ? "cms-pill--success" : "cms-pill--warning"), children: t === "good" ? u.goodConnection : u.poorConnection })
1305
+ /* @__PURE__ */ e("span", { className: A("cms-pill", t === "good" ? "cms-pill--success" : "cms-pill--warning"), children: t === "good" ? c.goodConnection : c.poorConnection })
1306
1306
  ] }),
1307
- /* @__PURE__ */ d("div", { className: "cms-call-panel__you", children: [
1307
+ /* @__PURE__ */ u("div", { className: "cms-call-panel__you", children: [
1308
1308
  /* @__PURE__ */ e(ve, { name: o.name, size: 36 }),
1309
- /* @__PURE__ */ e("span", { children: u.you }),
1310
- o.speaking ? /* @__PURE__ */ e("span", { className: "cms-call-panel__level", role: "img", "aria-label": u.speaking }) : null
1309
+ /* @__PURE__ */ e("span", { children: c.you }),
1310
+ o.speaking ? /* @__PURE__ */ e("span", { className: "cms-call-panel__level", role: "img", "aria-label": c.speaking }) : null
1311
1311
  ] }),
1312
- /* @__PURE__ */ d("div", { className: "cms-call-panel__controls", children: [
1313
- /* @__PURE__ */ e(ae, { icon: "mic", label: c ? u.unmute : u.mute, pressed: c, onClick: r }),
1314
- /* @__PURE__ */ e(ae, { icon: "speaker", label: u.speaker, pressed: a, onClick: s }),
1315
- m ? /* @__PURE__ */ e(ae, { icon: "user-plus", label: u.addPerson, onClick: m }) : null,
1316
- f ? /* @__PURE__ */ e(ae, { icon: "chat", label: u.chat, onClick: f }) : null,
1317
- /* @__PURE__ */ e(ae, { icon: "phone-off", label: u.hangUp, tone: "hang-up", onClick: i })
1312
+ /* @__PURE__ */ u("div", { className: "cms-call-panel__controls", children: [
1313
+ /* @__PURE__ */ e(ae, { icon: "mic", label: i ? c.unmute : c.mute, pressed: i, onClick: r }),
1314
+ /* @__PURE__ */ e(ae, { icon: "speaker", label: c.speaker, pressed: s, onClick: a }),
1315
+ h ? /* @__PURE__ */ e(ae, { icon: "user-plus", label: c.addPerson, onClick: h }) : null,
1316
+ _ ? /* @__PURE__ */ e(ae, { icon: "chat", label: c.chat, onClick: _ }) : null,
1317
+ /* @__PURE__ */ e(ae, { icon: "phone-off", label: c.hangUp, tone: "hang-up", onClick: d })
1318
1318
  ] })
1319
1319
  ] });
1320
1320
  }
1321
- function nl({ name: n, duration: l, muted: t, onToggleMute: o, onReturn: c, onHangUp: a, labels: r }) {
1322
- const s = ce(Ae, r);
1323
- return /* @__PURE__ */ d("section", { className: "cms-call-bar", "aria-label": s.callWith(n), children: [
1321
+ function tl({ name: n, duration: l, muted: t, onToggleMute: o, onReturn: i, onHangUp: s, labels: r }) {
1322
+ const a = ce(Ee, r);
1323
+ return /* @__PURE__ */ u("section", { className: "cms-call-bar", "aria-label": a.callWith(n), children: [
1324
1324
  /* @__PURE__ */ e("span", { className: "cms-call-bar__live", "aria-hidden": "true" }),
1325
- /* @__PURE__ */ e("span", { className: "cms-call-bar__name", children: s.onCallWith(n) }),
1325
+ /* @__PURE__ */ e("span", { className: "cms-call-bar__name", children: a.onCallWith(n) }),
1326
1326
  /* @__PURE__ */ e("span", { className: "cms-call-bar__time", children: l }),
1327
- /* @__PURE__ */ d("span", { className: "cms-call-bar__actions", children: [
1328
- /* @__PURE__ */ e("button", { type: "button", className: "cms-call-bar__icon", "aria-label": t ? s.unmute : s.mute, "aria-pressed": t, onClick: o, children: /* @__PURE__ */ e(L, { name: "mic" }) }),
1329
- /* @__PURE__ */ e("button", { type: "button", className: "cms-button cms-button--primary", onClick: c, children: s.returnToCall }),
1330
- /* @__PURE__ */ e("button", { type: "button", className: "cms-call-bar__icon cms-call-bar__icon--hang-up", "aria-label": s.hangUp, onClick: a, children: /* @__PURE__ */ e(L, { name: "phone-off" }) })
1327
+ /* @__PURE__ */ u("span", { className: "cms-call-bar__actions", children: [
1328
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-call-bar__icon", "aria-label": t ? a.unmute : a.mute, "aria-pressed": t, onClick: o, children: /* @__PURE__ */ e(T, { name: "mic" }) }),
1329
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-button cms-button--primary", onClick: i, children: a.returnToCall }),
1330
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-call-bar__icon cms-call-bar__icon--hang-up", "aria-label": a.hangUp, onClick: s, children: /* @__PURE__ */ e(T, { name: "phone-off" }) })
1331
1331
  ] })
1332
1332
  ] });
1333
1333
  }
1334
- function ll({ mark: n, product: l, headline: t, lead: o, features: c = [], children: a }) {
1335
- return /* @__PURE__ */ d("div", { className: "cms-signin", children: [
1336
- /* @__PURE__ */ d("aside", { className: "cms-signin__brand", children: [
1337
- /* @__PURE__ */ d("p", { className: "cms-signin__logo", children: [
1334
+ function al({ mark: n, product: l, headline: t, lead: o, features: i = [], children: s }) {
1335
+ return /* @__PURE__ */ u("div", { className: "cms-signin", children: [
1336
+ /* @__PURE__ */ u("aside", { className: "cms-signin__brand", children: [
1337
+ /* @__PURE__ */ u("p", { className: "cms-signin__logo", children: [
1338
1338
  /* @__PURE__ */ e("span", { className: "cms-signin__mark", "aria-hidden": "true", children: n }),
1339
1339
  l
1340
1340
  ] }),
1341
- /* @__PURE__ */ d("div", { className: "cms-signin__pitch", children: [
1341
+ /* @__PURE__ */ u("div", { className: "cms-signin__pitch", children: [
1342
1342
  /* @__PURE__ */ e("p", { className: "cms-signin__headline", children: t }),
1343
1343
  /* @__PURE__ */ e("p", { className: "cms-signin__lead", children: o }),
1344
- c.length ? /* @__PURE__ */ e("ul", { className: "cms-signin__features", children: c.map((r) => /* @__PURE__ */ d("li", { children: [
1345
- /* @__PURE__ */ e(L, { name: r.icon, size: 18 }),
1344
+ i.length ? /* @__PURE__ */ e("ul", { className: "cms-signin__features", children: i.map((r) => /* @__PURE__ */ u("li", { children: [
1345
+ /* @__PURE__ */ e(T, { name: r.icon, size: 18 }),
1346
1346
  r.label
1347
1347
  ] }, r.label)) }) : null
1348
1348
  ] })
1349
1349
  ] }),
1350
- /* @__PURE__ */ e("main", { className: "cms-signin__form", children: a })
1350
+ /* @__PURE__ */ e("main", { className: "cms-signin__form", children: s })
1351
1351
  ] });
1352
1352
  }
1353
1353
  const bn = {
@@ -1362,52 +1362,52 @@ const bn = {
1362
1362
  newHere: "New here?",
1363
1363
  create: "Create an account"
1364
1364
  };
1365
- function tl({ server: n, onSubmit: l, forgotHref: t, createHref: o, error: c, busy: a, labels: r }) {
1366
- const s = ce(bn, r), m = X(), [f, i] = A(""), [h, u] = A(""), [p, _] = A(!1);
1367
- return /* @__PURE__ */ d("form", { className: "cms-signin-form", onSubmit: (N) => {
1368
- N.preventDefault(), l(f, h);
1369
- }, "aria-describedby": c ? `${m}-error` : void 0, children: [
1370
- /* @__PURE__ */ e("h1", { className: "cms-signin-form__title", children: s.title }),
1371
- /* @__PURE__ */ d("p", { className: "cms-signin-form__server", children: [
1372
- /* @__PURE__ */ e(L, { name: "server", size: 18 }),
1365
+ function sl({ server: n, onSubmit: l, forgotHref: t, createHref: o, error: i, busy: s, labels: r }) {
1366
+ const a = ce(bn, r), h = G(), [_, d] = E(""), [m, c] = E(""), [f, p] = E(!1);
1367
+ return /* @__PURE__ */ u("form", { className: "cms-signin-form", onSubmit: (N) => {
1368
+ N.preventDefault(), l(_, m);
1369
+ }, "aria-describedby": i ? `${h}-error` : void 0, children: [
1370
+ /* @__PURE__ */ e("h1", { className: "cms-signin-form__title", children: a.title }),
1371
+ /* @__PURE__ */ u("p", { className: "cms-signin-form__server", children: [
1372
+ /* @__PURE__ */ e(T, { name: "server", size: 18 }),
1373
1373
  n
1374
1374
  ] }),
1375
- /* @__PURE__ */ e("label", { className: "cms-signin-form__label", htmlFor: `${m}-identifier`, children: s.identifier }),
1375
+ /* @__PURE__ */ e("label", { className: "cms-signin-form__label", htmlFor: `${h}-identifier`, children: a.identifier }),
1376
1376
  /* @__PURE__ */ e(
1377
1377
  "input",
1378
1378
  {
1379
- id: `${m}-identifier`,
1379
+ id: `${h}-identifier`,
1380
1380
  className: "cms-signin-form__input",
1381
1381
  type: "text",
1382
1382
  autoComplete: "username",
1383
- placeholder: s.identifierPlaceholder,
1384
- value: f,
1385
- onChange: (N) => i(N.target.value),
1383
+ placeholder: a.identifierPlaceholder,
1384
+ value: _,
1385
+ onChange: (N) => d(N.target.value),
1386
1386
  required: !0
1387
1387
  }
1388
1388
  ),
1389
- /* @__PURE__ */ e("label", { className: "cms-signin-form__label", htmlFor: `${m}-password`, children: s.password }),
1390
- /* @__PURE__ */ d("span", { className: "cms-signin-form__password", children: [
1389
+ /* @__PURE__ */ e("label", { className: "cms-signin-form__label", htmlFor: `${h}-password`, children: a.password }),
1390
+ /* @__PURE__ */ u("span", { className: "cms-signin-form__password", children: [
1391
1391
  /* @__PURE__ */ e(
1392
1392
  "input",
1393
1393
  {
1394
- id: `${m}-password`,
1394
+ id: `${h}-password`,
1395
1395
  className: "cms-signin-form__input",
1396
- type: p ? "text" : "password",
1396
+ type: f ? "text" : "password",
1397
1397
  autoComplete: "current-password",
1398
- value: h,
1399
- onChange: (N) => u(N.target.value),
1398
+ value: m,
1399
+ onChange: (N) => c(N.target.value),
1400
1400
  required: !0
1401
1401
  }
1402
1402
  ),
1403
- /* @__PURE__ */ e("button", { type: "button", className: "cms-signin-form__show", "aria-pressed": p, onClick: () => _((N) => !N), children: p ? s.hide : s.show })
1403
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-signin-form__show", "aria-pressed": f, onClick: () => p((N) => !N), children: f ? a.hide : a.show })
1404
1404
  ] }),
1405
- t ? /* @__PURE__ */ e("a", { className: "cms-signin-form__forgot", href: t, children: s.forgot }) : null,
1406
- c ? /* @__PURE__ */ e("p", { id: `${m}-error`, className: "cms-signin-form__error", role: "alert", children: c }) : null,
1407
- /* @__PURE__ */ e("button", { type: "submit", className: "cms-button cms-button--chrome cms-signin-form__submit", disabled: a, "aria-busy": a || void 0, children: s.submit }),
1408
- o ? /* @__PURE__ */ d(M, { children: [
1409
- /* @__PURE__ */ e("p", { className: "cms-signin-form__or", children: /* @__PURE__ */ e("span", { children: s.newHere }) }),
1410
- /* @__PURE__ */ e("a", { className: "cms-button cms-signin-form__create", href: o, children: s.create })
1405
+ t ? /* @__PURE__ */ e("a", { className: "cms-signin-form__forgot", href: t, children: a.forgot }) : null,
1406
+ i ? /* @__PURE__ */ e("p", { id: `${h}-error`, className: "cms-signin-form__error", role: "alert", children: i }) : null,
1407
+ /* @__PURE__ */ e("button", { type: "submit", className: "cms-button cms-button--chrome cms-signin-form__submit", disabled: s, "aria-busy": s || void 0, children: a.submit }),
1408
+ o ? /* @__PURE__ */ u(M, { children: [
1409
+ /* @__PURE__ */ e("p", { className: "cms-signin-form__or", children: /* @__PURE__ */ e("span", { children: a.newHere }) }),
1410
+ /* @__PURE__ */ e("a", { className: "cms-button cms-signin-form__create", href: o, children: a.create })
1411
1411
  ] }) : null
1412
1412
  ] });
1413
1413
  }
@@ -1420,157 +1420,157 @@ function vn(n, l) {
1420
1420
  return l.scrollTop <= 0;
1421
1421
  }
1422
1422
  function gn(n, l) {
1423
- const [t, o] = A(0), c = K(l);
1424
- return c.current = l, Y(() => {
1425
- const a = n.current;
1426
- if (a === null) return;
1427
- let r = null, s = 0;
1428
- const m = (h) => {
1429
- r = vn(h.target, a) && h.touches.length === 1 ? h.touches[0].clientY : null, s = 0;
1430
- }, f = (h) => {
1431
- if (r === null || c.current === null) return;
1432
- const u = h.touches[0].clientY - r;
1433
- if (u <= 0) {
1423
+ const [t, o] = E(0), i = R(l);
1424
+ return i.current = l, Y(() => {
1425
+ const s = n.current;
1426
+ if (s === null) return;
1427
+ let r = null, a = 0;
1428
+ const h = (m) => {
1429
+ r = vn(m.target, s) && m.touches.length === 1 ? m.touches[0].clientY : null, a = 0;
1430
+ }, _ = (m) => {
1431
+ if (r === null || i.current === null) return;
1432
+ const c = m.touches[0].clientY - r;
1433
+ if (c <= 0) {
1434
1434
  r = null, o(0);
1435
1435
  return;
1436
1436
  }
1437
- h.cancelable && h.preventDefault(), s = Math.min(u * 0.6, we * 1.5), o(s);
1438
- }, i = () => {
1439
- var h;
1440
- r !== null && s >= we && ((h = c.current) == null || h.call(c)), r = null, s = 0, o(0);
1437
+ m.cancelable && m.preventDefault(), a = Math.min(c * 0.6, we * 1.5), o(a);
1438
+ }, d = () => {
1439
+ var m;
1440
+ r !== null && a >= we && ((m = i.current) == null || m.call(i)), r = null, a = 0, o(0);
1441
1441
  };
1442
- return a.addEventListener("touchstart", m, { passive: !0 }), a.addEventListener("touchmove", f, { passive: !1 }), a.addEventListener("touchend", i), a.addEventListener("touchcancel", i), () => {
1443
- a.removeEventListener("touchstart", m), a.removeEventListener("touchmove", f), a.removeEventListener("touchend", i), a.removeEventListener("touchcancel", i);
1442
+ return s.addEventListener("touchstart", h, { passive: !0 }), s.addEventListener("touchmove", _, { passive: !1 }), s.addEventListener("touchend", d), s.addEventListener("touchcancel", d), () => {
1443
+ s.removeEventListener("touchstart", h), s.removeEventListener("touchmove", _), s.removeEventListener("touchend", d), s.removeEventListener("touchcancel", d);
1444
1444
  };
1445
1445
  }, [n]), t;
1446
1446
  }
1447
1447
  const Fe = Ue(null);
1448
1448
  function Nn() {
1449
- return Re(Fe);
1450
- }
1451
- function al({ label: n, rows: l, error: t, onRetry: o, loadingText: c = "Loading", emptyTitle: a = "Nothing here yet", emptyHint: r, selected: s, onOpen: m, onRowMenu: f }) {
1452
- const i = K([]), h = Nn();
1453
- if (t != null) return /* @__PURE__ */ e(Xe, { message: t, onRetry: o });
1454
- if (l === null) return /* @__PURE__ */ e(qe, { what: c, layout: "block" });
1455
- if (l.length === 0) return /* @__PURE__ */ e(Ye, { title: a, hint: r });
1456
- const u = (p, _, g) => {
1449
+ return Ke(Fe);
1450
+ }
1451
+ function rl({ label: n, rows: l, error: t, onRetry: o, loadingText: i = "Loading", emptyTitle: s = "Nothing here yet", emptyHint: r, selected: a, onOpen: h, onRowMenu: _ }) {
1452
+ const d = R([]), m = Nn();
1453
+ if (t != null) return /* @__PURE__ */ e(Ge, { message: t, onRetry: o });
1454
+ if (l === null) return /* @__PURE__ */ e(qe, { what: i, layout: "block" });
1455
+ if (l.length === 0) return /* @__PURE__ */ e(Ye, { title: s, hint: r });
1456
+ const c = (f, p, g) => {
1457
1457
  var N;
1458
- if (p.key === "ArrowDown" || p.key === "ArrowUp")
1459
- p.preventDefault(), (N = i.current[Math.min(l.length - 1, Math.max(0, _ + (p.key === "ArrowDown" ? 1 : -1)))]) == null || N.focus();
1460
- else if (p.key === "Enter")
1461
- m == null || m(g);
1462
- else if ((p.key === "ContextMenu" || p.shiftKey && p.key === "F10") && f) {
1463
- p.preventDefault();
1464
- const w = p.currentTarget.getBoundingClientRect();
1465
- f(g, { x: w.left + 16, y: w.bottom });
1458
+ if (f.key === "ArrowDown" || f.key === "ArrowUp")
1459
+ f.preventDefault(), (N = d.current[Math.min(l.length - 1, Math.max(0, p + (f.key === "ArrowDown" ? 1 : -1)))]) == null || N.focus();
1460
+ else if (f.key === "Enter")
1461
+ h == null || h(g);
1462
+ else if ((f.key === "ContextMenu" || f.shiftKey && f.key === "F10") && _) {
1463
+ f.preventDefault();
1464
+ const w = f.currentTarget.getBoundingClientRect();
1465
+ _(g, { x: w.left + 16, y: w.bottom });
1466
1466
  }
1467
1467
  };
1468
- return /* @__PURE__ */ d(M, { children: [
1469
- h !== null && (h.distance > 0 || h.refreshing) ? /* @__PURE__ */ d("div", { className: "cms-list__pull", role: "status", style: { height: h.refreshing ? void 0 : h.distance }, "data-ready": h.distance >= we ? "" : void 0, children: [
1470
- h.refreshing ? /* @__PURE__ */ e(z, { name: "spinner" }) : null,
1471
- h.text != null ? /* @__PURE__ */ e("span", { className: "cms-list__pull-text", children: h.text }) : null
1468
+ return /* @__PURE__ */ u(M, { children: [
1469
+ m !== null && (m.distance > 0 || m.refreshing) ? /* @__PURE__ */ u("div", { className: "cms-list__pull", role: "status", style: { height: m.refreshing ? void 0 : m.distance }, "data-ready": m.distance >= we ? "" : void 0, children: [
1470
+ m.refreshing ? /* @__PURE__ */ e(z, { name: "spinner" }) : null,
1471
+ m.text != null ? /* @__PURE__ */ e("span", { className: "cms-list__pull-text", children: m.text }) : null
1472
1472
  ] }) : null,
1473
- /* @__PURE__ */ e("ul", { className: "cms-list", role: "listbox", "aria-label": n, children: l.map((p, _) => {
1474
- const g = p.id === s;
1475
- return /* @__PURE__ */ d(
1473
+ /* @__PURE__ */ e("ul", { className: "cms-list", role: "listbox", "aria-label": n, children: l.map((f, p) => {
1474
+ const g = f.id === a;
1475
+ return /* @__PURE__ */ u(
1476
1476
  "li",
1477
1477
  {
1478
1478
  ref: (N) => {
1479
- i.current[_] = N;
1479
+ d.current[p] = N;
1480
1480
  },
1481
1481
  role: "option",
1482
1482
  "aria-selected": g,
1483
- tabIndex: g || s == null && _ === 0 ? 0 : -1,
1484
- className: E("cms-list__row", g && "is-selected"),
1485
- onClick: () => m == null ? void 0 : m(p.id),
1486
- onKeyDown: (N) => u(N, _, p.id),
1487
- onContextMenu: f ? (N) => {
1488
- N.preventDefault(), f(p.id, { x: N.clientX, y: N.clientY });
1483
+ tabIndex: g || a == null && p === 0 ? 0 : -1,
1484
+ className: A("cms-list__row", g && "is-selected"),
1485
+ onClick: () => h == null ? void 0 : h(f.id),
1486
+ onKeyDown: (N) => c(N, p, f.id),
1487
+ onContextMenu: _ ? (N) => {
1488
+ N.preventDefault(), _(f.id, { x: N.clientX, y: N.clientY });
1489
1489
  } : void 0,
1490
1490
  children: [
1491
- p.lead != null ? /* @__PURE__ */ e("span", { className: "cms-list__lead", children: p.lead }) : null,
1492
- /* @__PURE__ */ d("span", { className: "cms-list__text", children: [
1493
- /* @__PURE__ */ e("span", { className: E("cms-list__primary", p.unread === !0 && "is-unread"), children: p.primary }),
1494
- p.secondary != null ? /* @__PURE__ */ e("span", { className: "cms-list__secondary", children: p.secondary }) : null
1491
+ f.lead != null ? /* @__PURE__ */ e("span", { className: "cms-list__lead", children: f.lead }) : null,
1492
+ /* @__PURE__ */ u("span", { className: "cms-list__text", children: [
1493
+ /* @__PURE__ */ e("span", { className: A("cms-list__primary", f.unread === !0 && "is-unread"), children: f.primary }),
1494
+ f.secondary != null ? /* @__PURE__ */ e("span", { className: "cms-list__secondary", children: f.secondary }) : null
1495
1495
  ] }),
1496
- p.meta != null || p.count !== void 0 ? /* @__PURE__ */ d("span", { className: "cms-list__end", children: [
1497
- p.meta != null ? /* @__PURE__ */ e("span", { className: "cms-list__meta", children: p.meta }) : null,
1498
- p.count !== void 0 && p.count > 0 ? /* @__PURE__ */ e("span", { className: "cms-badge cms-list__count", children: p.count }) : null
1496
+ f.meta != null || f.count !== void 0 ? /* @__PURE__ */ u("span", { className: "cms-list__end", children: [
1497
+ f.meta != null ? /* @__PURE__ */ e("span", { className: "cms-list__meta", children: f.meta }) : null,
1498
+ f.count !== void 0 && f.count > 0 ? /* @__PURE__ */ e("span", { className: "cms-badge cms-list__count", children: f.count }) : null
1499
1499
  ] }) : null
1500
1500
  ]
1501
1501
  },
1502
- p.id
1502
+ f.id
1503
1503
  );
1504
1504
  }) })
1505
1505
  ] });
1506
1506
  }
1507
- function He({ at: n, items: l, onClose: t, label: o = "Actions", focus: c = "first" }) {
1508
- const a = K(null), r = K(null), s = X(), [m, f] = A(n), i = l.filter((u) => u.offer.offered);
1507
+ function He({ at: n, items: l, onClose: t, label: o = "Actions", focus: i = "first" }) {
1508
+ const s = R(null), r = R(null), a = G(), [h, _] = E(n), d = l.filter((c) => c.offer.offered);
1509
1509
  if (xe(() => {
1510
1510
  if (!n) return;
1511
- const u = a.current, p = (u == null ? void 0 : u.offsetWidth) ?? 0, _ = (u == null ? void 0 : u.offsetHeight) ?? 0;
1512
- f({ x: Math.max(0, Math.min(n.x, window.innerWidth - p)), y: Math.max(0, Math.min(n.y, window.innerHeight - _)) });
1511
+ const c = s.current, f = (c == null ? void 0 : c.offsetWidth) ?? 0, p = (c == null ? void 0 : c.offsetHeight) ?? 0;
1512
+ _({ x: Math.max(0, Math.min(n.x, window.innerWidth - f)), y: Math.max(0, Math.min(n.y, window.innerHeight - p)) });
1513
1513
  }, [n]), Y(() => {
1514
- var _, g;
1514
+ var p, g;
1515
1515
  if (!n) return;
1516
1516
  r.current = document.activeElement;
1517
- const u = Array.from(((_ = a.current) == null ? void 0 : _.querySelectorAll('[role="menuitem"]:not([aria-disabled="true"])')) ?? []);
1518
- (g = c === "last" ? u[u.length - 1] : u[0]) == null || g.focus();
1519
- const p = (N) => {
1517
+ const c = Array.from(((p = s.current) == null ? void 0 : p.querySelectorAll('[role="menuitem"]:not([aria-disabled="true"])')) ?? []);
1518
+ (g = i === "last" ? c[c.length - 1] : c[0]) == null || g.focus();
1519
+ const f = (N) => {
1520
1520
  var w;
1521
- (w = a.current) != null && w.contains(N.target) || t();
1521
+ (w = s.current) != null && w.contains(N.target) || t();
1522
1522
  };
1523
- return document.addEventListener("mousedown", p), () => {
1523
+ return document.addEventListener("mousedown", f), () => {
1524
1524
  var N, w;
1525
- document.removeEventListener("mousedown", p), (w = (N = r.current) == null ? void 0 : N.focus) == null || w.call(N);
1525
+ document.removeEventListener("mousedown", f), (w = (N = r.current) == null ? void 0 : N.focus) == null || w.call(N);
1526
1526
  };
1527
- }, [n, t, c]), !n || i.length === 0) return null;
1528
- const h = (u) => {
1527
+ }, [n, t, i]), !n || d.length === 0) return null;
1528
+ const m = (c) => {
1529
1529
  var g, N;
1530
- const p = Array.from(((g = a.current) == null ? void 0 : g.querySelectorAll('[role="menuitem"]')) ?? []), _ = p.indexOf(document.activeElement);
1531
- if (u.key === "Escape" || u.key === "Tab")
1532
- u.preventDefault(), t();
1533
- else if (u.key === "ArrowDown" || u.key === "ArrowUp") {
1534
- u.preventDefault();
1535
- const w = u.key === "ArrowDown" ? 1 : -1;
1536
- (N = p[(_ + w + p.length) % p.length]) == null || N.focus();
1530
+ const f = Array.from(((g = s.current) == null ? void 0 : g.querySelectorAll('[role="menuitem"]')) ?? []), p = f.indexOf(document.activeElement);
1531
+ if (c.key === "Escape" || c.key === "Tab")
1532
+ c.preventDefault(), t();
1533
+ else if (c.key === "ArrowDown" || c.key === "ArrowUp") {
1534
+ c.preventDefault();
1535
+ const w = c.key === "ArrowDown" ? 1 : -1;
1536
+ (N = f[(p + w + f.length) % f.length]) == null || N.focus();
1537
1537
  }
1538
1538
  };
1539
1539
  return Me(
1540
1540
  /* @__PURE__ */ e(
1541
1541
  "div",
1542
1542
  {
1543
- ref: a,
1543
+ ref: s,
1544
1544
  className: "cms-menu",
1545
1545
  role: "menu",
1546
1546
  "aria-label": o,
1547
- style: { left: (m ?? n).x, top: (m ?? n).y },
1548
- onKeyDown: h,
1549
- onContextMenu: (u) => u.preventDefault(),
1550
- children: i.map((u) => {
1551
- const p = u.offer.refusal !== void 0;
1552
- return /* @__PURE__ */ d(
1547
+ style: { left: (h ?? n).x, top: (h ?? n).y },
1548
+ onKeyDown: m,
1549
+ onContextMenu: (c) => c.preventDefault(),
1550
+ children: d.map((c) => {
1551
+ const f = c.offer.refusal !== void 0;
1552
+ return /* @__PURE__ */ u(
1553
1553
  "div",
1554
1554
  {
1555
1555
  role: "menuitem",
1556
1556
  tabIndex: -1,
1557
- "aria-disabled": p || void 0,
1558
- "aria-describedby": p ? `${s}-${u.id}` : void 0,
1559
- title: p ? u.offer.refusal : void 0,
1560
- className: E("cms-menu__item", u.danger && "is-danger", u.offer.locked && "is-locked", p && "is-refused"),
1557
+ "aria-disabled": f || void 0,
1558
+ "aria-describedby": f ? `${a}-${c.id}` : void 0,
1559
+ title: f ? c.offer.refusal : void 0,
1560
+ className: A("cms-menu__item", c.danger && "is-danger", c.offer.locked && "is-locked", f && "is-refused"),
1561
1561
  onClick: () => {
1562
- p || (t(), u.onSelect());
1562
+ f || (t(), c.onSelect());
1563
1563
  },
1564
- onKeyDown: (_) => {
1565
- (_.key === "Enter" || _.key === " ") && !p && (_.preventDefault(), t(), u.onSelect());
1564
+ onKeyDown: (p) => {
1565
+ (p.key === "Enter" || p.key === " ") && !f && (p.preventDefault(), t(), c.onSelect());
1566
1566
  },
1567
1567
  children: [
1568
- u.offer.locked ? /* @__PURE__ */ e(z, { name: "lock" }) : null,
1569
- /* @__PURE__ */ e("span", { className: "cms-menu__label", children: u.label }),
1570
- p ? /* @__PURE__ */ e("span", { id: `${s}-${u.id}`, className: "cms-menu__refusal", children: u.offer.refusal }) : null
1568
+ c.offer.locked ? /* @__PURE__ */ e(z, { name: "lock" }) : null,
1569
+ /* @__PURE__ */ e("span", { className: "cms-menu__label", children: c.label }),
1570
+ f ? /* @__PURE__ */ e("span", { id: `${a}-${c.id}`, className: "cms-menu__refusal", children: c.offer.refusal }) : null
1571
1571
  ]
1572
1572
  },
1573
- u.id
1573
+ c.id
1574
1574
  );
1575
1575
  })
1576
1576
  }
@@ -1589,66 +1589,66 @@ function wn(n) {
1589
1589
  for (const t of n) t.overflow !== void 0 && t.overflow !== 0 && l.set(t.overflow, [...l.get(t.overflow) ?? [], t.id]);
1590
1590
  return [...l.entries()].sort(([t], [o]) => t - o).map(([, t]) => t);
1591
1591
  }
1592
- function sl({ label: n, actions: l, onAction: t, status: o, moreLabel: c, leading: a }) {
1593
- const r = K(null), s = K(null), [m, f] = A(De), [i, h] = A(null), [u, p] = A("first"), [_, g] = A(null), [N, w] = A(null), x = yn(l), S = wn(l), C = x.flat(), F = C.filter((v) => v.overflow === 0), H = C.filter((v) => v.overflow !== 0), ee = JSON.stringify([l.map((v) => [v.id, v.label, v.icon, v.group, v.overflow ?? null]), o ?? "", a !== void 0]), j = be(() => {
1594
- const v = r.current, T = s.current;
1595
- if (v === null || T === null) return;
1596
- const Z = getComputedStyle(v), W = parseFloat(Z.columnGap || "0") || 0, $ = v.clientWidth - (parseFloat(Z.paddingLeft) || 0) - (parseFloat(Z.paddingRight) || 0), q = (P) => {
1592
+ function cl({ label: n, actions: l, onAction: t, status: o, moreLabel: i, leading: s }) {
1593
+ const r = R(null), a = R(null), [h, _] = E(De), [d, m] = E(null), [c, f] = E("first"), [p, g] = E(null), [N, w] = E(null), x = yn(l), S = wn(l), C = x.flat(), F = C.filter((v) => v.overflow === 0), H = C.filter((v) => v.overflow !== 0), ee = JSON.stringify([l.map((v) => [v.id, v.label, v.icon, v.group, v.overflow ?? null]), o ?? "", s !== void 0]), j = be(() => {
1594
+ const v = r.current, L = a.current;
1595
+ if (v === null || L === null) return;
1596
+ const Z = getComputedStyle(v), W = parseFloat(Z.columnGap || "0") || 0, $ = v.clientWidth - (parseFloat(Z.paddingLeft) || 0) - (parseFloat(Z.paddingRight) || 0), q = (I) => {
1597
1597
  var U;
1598
- return ((U = T.querySelector(P)) == null ? void 0 : U.getBoundingClientRect().width) ?? 0;
1599
- }, de = q('[data-measure="leading"]'), ue = q('[data-measure="separator"]'), me = q('[data-measure="more"]'), he = (P, U) => q(`[data-measure="${U ? "full" : "icon"}"][data-measure-action="${CSS.escape(P)}"]`), b = (P, U) => {
1600
- const Q = /* @__PURE__ */ new Set([...F.map((te) => te.id), ...U]), se = x.map((te) => te.filter((pe) => !Q.has(pe.id))).filter((te) => te.length > 0), fe = se.flat(), Ke = fe.length + (se.length - 1) + (Q.size > 0 ? 1 : 0) + (de > 0 ? 1 : 0);
1601
- return de + fe.reduce((te, pe) => te + he(pe.id, !P.has(pe.id)), 0) + ue * Math.max(0, se.length - 1) + (Q.size > 0 ? me : 0) + W * Math.max(0, Ke - 1);
1602
- }, k = H.filter((P) => !S.some((U) => U.includes(P.id))).map((P) => P.id), B = [...S, ...[...k].reverse().map((P) => [P])];
1603
- let R = null;
1604
- if (b(/* @__PURE__ */ new Set(), /* @__PURE__ */ new Set()) <= $) R = De;
1598
+ return ((U = L.querySelector(I)) == null ? void 0 : U.getBoundingClientRect().width) ?? 0;
1599
+ }, de = q('[data-measure="leading"]'), ue = q('[data-measure="separator"]'), me = q('[data-measure="more"]'), he = (I, U) => q(`[data-measure="${U ? "full" : "icon"}"][data-measure-action="${CSS.escape(I)}"]`), b = (I, U) => {
1600
+ const Q = /* @__PURE__ */ new Set([...F.map((te) => te.id), ...U]), se = x.map((te) => te.filter((pe) => !Q.has(pe.id))).filter((te) => te.length > 0), fe = se.flat(), Re = fe.length + (se.length - 1) + (Q.size > 0 ? 1 : 0) + (de > 0 ? 1 : 0);
1601
+ return de + fe.reduce((te, pe) => te + he(pe.id, !I.has(pe.id)), 0) + ue * Math.max(0, se.length - 1) + (Q.size > 0 ? me : 0) + W * Math.max(0, Re - 1);
1602
+ }, k = H.filter((I) => !S.some((U) => U.includes(I.id))).map((I) => I.id), B = [...S, ...[...k].reverse().map((I) => [I])];
1603
+ let K = null;
1604
+ if (b(/* @__PURE__ */ new Set(), /* @__PURE__ */ new Set()) <= $) K = De;
1605
1605
  else {
1606
- const P = /* @__PURE__ */ new Set();
1606
+ const I = /* @__PURE__ */ new Set();
1607
1607
  for (const U of B) {
1608
- for (const Q of U) P.add(Q);
1609
- if (b(P, /* @__PURE__ */ new Set()) <= $) {
1610
- R = { bare: P, hidden: /* @__PURE__ */ new Set() };
1608
+ for (const Q of U) I.add(Q);
1609
+ if (b(I, /* @__PURE__ */ new Set()) <= $) {
1610
+ K = { bare: I, hidden: /* @__PURE__ */ new Set() };
1611
1611
  break;
1612
1612
  }
1613
1613
  }
1614
1614
  }
1615
- if (R === null) {
1616
- const P = new Set(H.map((Q) => Q.id)), U = /* @__PURE__ */ new Set();
1615
+ if (K === null) {
1616
+ const I = new Set(H.map((Q) => Q.id)), U = /* @__PURE__ */ new Set();
1617
1617
  for (const Q of S) {
1618
1618
  for (const se of Q) H.some((fe) => fe.id === se) && U.add(se);
1619
- if (U.size >= 2 && b(P, U) <= $) break;
1619
+ if (U.size >= 2 && b(I, U) <= $) break;
1620
1620
  }
1621
- if (b(P, U) > $) {
1621
+ if (b(I, U) > $) {
1622
1622
  for (const Q of [...k].reverse())
1623
- if (U.add(Q), b(P, U) <= $) break;
1623
+ if (U.add(Q), b(I, U) <= $) break;
1624
1624
  }
1625
- R = { bare: P, hidden: U };
1625
+ K = { bare: I, hidden: U };
1626
1626
  }
1627
- const ge = R;
1628
- f((P) => $e(P.bare, ge.bare) && $e(P.hidden, ge.hidden) ? P : ge);
1627
+ const ge = K;
1628
+ _((I) => $e(I.bare, ge.bare) && $e(I.hidden, ge.hidden) ? I : ge);
1629
1629
  }, [ee]);
1630
1630
  xe(j, [j]), Y(() => {
1631
1631
  const v = r.current;
1632
1632
  if (v === null || typeof ResizeObserver > "u") return;
1633
- const T = new ResizeObserver(() => j());
1634
- return T.observe(v), () => T.disconnect();
1633
+ const L = new ResizeObserver(() => j());
1634
+ return L.observe(v), () => L.disconnect();
1635
1635
  }, [j]);
1636
- const y = /* @__PURE__ */ new Set([...F.map((v) => v.id), ...m.hidden]), V = x.map((v) => v.filter((T) => !y.has(T.id))).filter((v) => v.length > 0).flat(), D = [
1636
+ const y = /* @__PURE__ */ new Set([...F.map((v) => v.id), ...h.hidden]), V = x.map((v) => v.filter((L) => !y.has(L.id))).filter((v) => v.length > 0).flat(), D = [
1637
1637
  ...F,
1638
- ...S.flat().map((v) => C.find((T) => T.id === v)).filter((v) => v !== void 0 && m.hidden.has(v.id)),
1638
+ ...S.flat().map((v) => C.find((L) => L.id === v)).filter((v) => v !== void 0 && h.hidden.has(v.id)),
1639
1639
  // The pinned that a row too narrow for them sent behind ..., in the row's order.
1640
- ...H.filter((v) => m.hidden.has(v.id) && !S.some((T) => T.includes(v.id)))
1641
- ], G = new Set(H.filter((v) => !S.some((T) => T.includes(v.id))).map((v) => v.id)), O = [...V.map((v) => v.id), ...D.length > 0 ? ["more"] : []], J = _ !== null && O.includes(_) ? _ : O[0] ?? null, ie = (v) => {
1640
+ ...H.filter((v) => h.hidden.has(v.id) && !S.some((L) => L.includes(v.id)))
1641
+ ], X = new Set(H.filter((v) => !S.some((L) => L.includes(v.id))).map((v) => v.id)), O = [...V.map((v) => v.id), ...D.length > 0 ? ["more"] : []], J = p !== null && O.includes(p) ? p : O[0] ?? null, ie = (v) => {
1642
1642
  var $, q;
1643
- const T = O.indexOf(J ?? "");
1643
+ const L = O.indexOf(J ?? "");
1644
1644
  let Z = null;
1645
- if (v.key === "ArrowRight" ? Z = Math.min(O.length - 1, T + 1) : v.key === "ArrowLeft" ? Z = Math.max(0, T - 1) : v.key === "Home" ? Z = 0 : v.key === "End" ? Z = O.length - 1 : v.key === "Escape" && w(J), Z === null) return;
1645
+ if (v.key === "ArrowRight" ? Z = Math.min(O.length - 1, L + 1) : v.key === "ArrowLeft" ? Z = Math.max(0, L - 1) : v.key === "Home" ? Z = 0 : v.key === "End" ? Z = O.length - 1 : v.key === "Escape" && w(J), Z === null) return;
1646
1646
  v.preventDefault();
1647
1647
  const W = O[Z] ?? null;
1648
1648
  g(W), (q = ($ = r.current) == null ? void 0 : $.querySelector(`[data-stop="${CSS.escape(W ?? "")}"]`)) == null || q.focus();
1649
1649
  }, oe = D.map((v) => ({
1650
1650
  id: v.id,
1651
- label: /* @__PURE__ */ d(M, { children: [
1651
+ label: /* @__PURE__ */ u(M, { children: [
1652
1652
  /* @__PURE__ */ e(_e, { name: v.icon }),
1653
1653
  v.label
1654
1654
  ] }),
@@ -1658,31 +1658,31 @@ function sl({ label: n, actions: l, onAction: t, status: o, moreLabel: c, leadin
1658
1658
  !v.disabled && !v.busy && t(v.id);
1659
1659
  }
1660
1660
  }));
1661
- return /* @__PURE__ */ d(
1661
+ return /* @__PURE__ */ u(
1662
1662
  "div",
1663
1663
  {
1664
1664
  ref: r,
1665
1665
  role: "toolbar",
1666
1666
  "aria-label": n,
1667
- className: E(
1667
+ className: A(
1668
1668
  "cms-pane-toolbar",
1669
- H.length > 0 && m.bare.size >= H.length && "cms-pane-toolbar--labels-hidden",
1670
- m.bare.size > 0 && m.bare.size < H.length && "cms-pane-toolbar--labels-partly-hidden"
1669
+ H.length > 0 && h.bare.size >= H.length && "cms-pane-toolbar--labels-hidden",
1670
+ h.bare.size > 0 && h.bare.size < H.length && "cms-pane-toolbar--labels-partly-hidden"
1671
1671
  ),
1672
1672
  onKeyDown: ie,
1673
1673
  children: [
1674
- a !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-pane-toolbar__leading", children: a }) : null,
1675
- x.map((v, T) => {
1676
- const Z = v.filter(($) => !y.has($.id)), W = x.slice(0, T).some(($) => $.some((q) => !y.has(q.id)));
1677
- return /* @__PURE__ */ d("div", { className: "cms-pane-toolbar__group-wrap", children: [
1674
+ s !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-pane-toolbar__leading", children: s }) : null,
1675
+ x.map((v, L) => {
1676
+ const Z = v.filter(($) => !y.has($.id)), W = x.slice(0, L).some(($) => $.some((q) => !y.has(q.id)));
1677
+ return /* @__PURE__ */ u("div", { className: "cms-pane-toolbar__group-wrap", children: [
1678
1678
  Z.length > 0 && W ? /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__separator", role: "separator", "aria-orientation": "vertical" }) : null,
1679
1679
  /* @__PURE__ */ e("div", { className: "cms-pane-toolbar__group", hidden: Z.length === 0, children: v.map(($) => /* @__PURE__ */ e(
1680
1680
  kn,
1681
1681
  {
1682
1682
  action: $,
1683
- labels: !m.bare.has($.id),
1683
+ labels: !h.bare.has($.id),
1684
1684
  overflowed: y.has($.id),
1685
- pinned: G.has($.id),
1685
+ pinned: X.has($.id),
1686
1686
  tabbable: J === $.id,
1687
1687
  tipOff: N === $.id,
1688
1688
  onChoose: () => t($.id),
@@ -1692,7 +1692,7 @@ function sl({ label: n, actions: l, onAction: t, status: o, moreLabel: c, leadin
1692
1692
  },
1693
1693
  $.id
1694
1694
  )) })
1695
- ] }, T);
1695
+ ] }, L);
1696
1696
  }),
1697
1697
  D.length > 0 ? /* @__PURE__ */ e(
1698
1698
  "button",
@@ -1700,60 +1700,60 @@ function sl({ label: n, actions: l, onAction: t, status: o, moreLabel: c, leadin
1700
1700
  type: "button",
1701
1701
  className: "cms-icon-button cms-pane-toolbar__more",
1702
1702
  "data-stop": "more",
1703
- "aria-label": c,
1704
- title: c,
1703
+ "aria-label": i,
1704
+ title: i,
1705
1705
  "aria-haspopup": "menu",
1706
- "aria-expanded": i !== null,
1706
+ "aria-expanded": d !== null,
1707
1707
  tabIndex: J === "more" ? 0 : -1,
1708
1708
  onFocus: () => g("more"),
1709
1709
  onClick: (v) => {
1710
- const T = v.currentTarget.getBoundingClientRect();
1711
- p("first"), h(i === null ? { x: T.left, y: T.bottom } : null);
1710
+ const L = v.currentTarget.getBoundingClientRect();
1711
+ f("first"), m(d === null ? { x: L.left, y: L.bottom } : null);
1712
1712
  },
1713
1713
  onKeyDown: (v) => {
1714
1714
  if (v.key === "ArrowDown" || v.key === "ArrowUp") {
1715
1715
  v.preventDefault(), v.stopPropagation();
1716
- const T = v.currentTarget.getBoundingClientRect();
1717
- p(v.key === "ArrowUp" ? "last" : "first"), h({ x: T.left, y: T.bottom });
1716
+ const L = v.currentTarget.getBoundingClientRect();
1717
+ f(v.key === "ArrowUp" ? "last" : "first"), m({ x: L.left, y: L.bottom });
1718
1718
  }
1719
1719
  },
1720
- children: /* @__PURE__ */ e(L, { name: "more" })
1720
+ children: /* @__PURE__ */ e(T, { name: "more" })
1721
1721
  }
1722
1722
  ) : null,
1723
1723
  o !== void 0 ? /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__status", title: o, children: o }) : null,
1724
- /* @__PURE__ */ e(He, { at: i, items: oe, onClose: () => h(null), label: c, focus: u }),
1725
- /* @__PURE__ */ d("div", { ref: s, className: "cms-pane-toolbar__measure", "aria-hidden": "true", children: [
1726
- a !== void 0 ? /* @__PURE__ */ e("div", { "data-measure": "leading", children: a }) : null,
1724
+ /* @__PURE__ */ e(He, { at: d, items: oe, onClose: () => m(null), label: i, focus: c }),
1725
+ /* @__PURE__ */ u("div", { ref: a, className: "cms-pane-toolbar__measure", "aria-hidden": "true", children: [
1726
+ s !== void 0 ? /* @__PURE__ */ e("div", { "data-measure": "leading", children: s }) : null,
1727
1727
  /* @__PURE__ */ e("span", { "data-measure": "separator", className: "cms-pane-toolbar__separator" }),
1728
- /* @__PURE__ */ e("span", { "data-measure": "more", className: "cms-icon-button cms-pane-toolbar__more", children: /* @__PURE__ */ e(L, { name: "more" }) }),
1729
- C.map((v) => /* @__PURE__ */ d("span", { children: [
1730
- /* @__PURE__ */ d("span", { "data-measure": "full", "data-measure-action": v.id, className: "cms-pane-toolbar__action", children: [
1728
+ /* @__PURE__ */ e("span", { "data-measure": "more", className: "cms-icon-button cms-pane-toolbar__more", children: /* @__PURE__ */ e(T, { name: "more" }) }),
1729
+ C.map((v) => /* @__PURE__ */ u("span", { children: [
1730
+ /* @__PURE__ */ u("span", { "data-measure": "full", "data-measure-action": v.id, className: "cms-pane-toolbar__action", children: [
1731
1731
  /* @__PURE__ */ e(_e, { name: v.icon }),
1732
1732
  /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__label", children: v.label })
1733
1733
  ] }),
1734
- /* @__PURE__ */ e("span", { "data-measure": "icon", "data-measure-action": v.id, className: E("cms-pane-toolbar__action", re(v.icon) !== null && "cms-pane-toolbar__action--bare"), children: re(v.icon) !== null ? /* @__PURE__ */ e(_e, { name: v.icon }) : /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__label", children: v.label }) })
1734
+ /* @__PURE__ */ e("span", { "data-measure": "icon", "data-measure-action": v.id, className: A("cms-pane-toolbar__action", re(v.icon) !== null && "cms-pane-toolbar__action--bare"), children: re(v.icon) !== null ? /* @__PURE__ */ e(_e, { name: v.icon }) : /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__label", children: v.label }) })
1735
1735
  ] }, v.id))
1736
1736
  ] })
1737
1737
  ]
1738
1738
  }
1739
1739
  );
1740
1740
  }
1741
- function kn({ action: n, labels: l, overflowed: t, pinned: o, tabbable: c, tipOff: a, onChoose: r, onFocus: s }) {
1742
- const [m, f] = A(!1);
1741
+ function kn({ action: n, labels: l, overflowed: t, pinned: o, tabbable: i, tipOff: s, onChoose: r, onFocus: a }) {
1742
+ const [h, _] = E(!1);
1743
1743
  Y(() => {
1744
1744
  if (!n.busy) {
1745
- f(!1);
1745
+ _(!1);
1746
1746
  return;
1747
1747
  }
1748
- const w = setTimeout(() => f(!0), ye);
1748
+ const w = setTimeout(() => _(!0), ye);
1749
1749
  return () => clearTimeout(w);
1750
1750
  }, [n.busy]);
1751
- const i = re(n.icon) === null, h = l || i, u = n.disabled && n.reason ? n.reason : null, p = u ?? (h ? null : n.label), _ = X(), [g, N] = A(!1);
1752
- return /* @__PURE__ */ d(
1751
+ const d = re(n.icon) === null, m = l || d, c = n.disabled && n.reason ? n.reason : null, f = c ?? (m ? null : n.label), p = G(), [g, N] = E(!1);
1752
+ return /* @__PURE__ */ u(
1753
1753
  "button",
1754
1754
  {
1755
1755
  type: "button",
1756
- className: E("cms-pane-toolbar__action", !h && "cms-pane-toolbar__action--bare", i && "cms-pane-toolbar__action--text", n.danger && "is-danger"),
1756
+ className: A("cms-pane-toolbar__action", !m && "cms-pane-toolbar__action--bare", d && "cms-pane-toolbar__action--text", n.danger && "is-danger"),
1757
1757
  "data-action": n.id,
1758
1758
  "data-stop": n.id,
1759
1759
  ...t ? { "data-overflowed": "" } : {},
@@ -1762,62 +1762,62 @@ function kn({ action: n, labels: l, overflowed: t, pinned: o, tabbable: c, tipOf
1762
1762
  "aria-label": n.label,
1763
1763
  "aria-disabled": n.disabled || void 0,
1764
1764
  "aria-busy": n.busy || void 0,
1765
- ...u === null ? {} : { "aria-describedby": _ },
1766
- ...g && u !== null ? { "data-reason-shown": "" } : {},
1767
- tabIndex: c ? 0 : -1,
1768
- onFocus: s,
1765
+ ...c === null ? {} : { "aria-describedby": p },
1766
+ ...g && c !== null ? { "data-reason-shown": "" } : {},
1767
+ tabIndex: i ? 0 : -1,
1768
+ onFocus: a,
1769
1769
  onBlur: () => N(!1),
1770
1770
  onKeyDown: (w) => {
1771
1771
  w.key === "Escape" && N(!1);
1772
1772
  },
1773
1773
  onClick: () => {
1774
- u !== null ? N(!0) : !n.disabled && !n.busy && r();
1774
+ c !== null ? N(!0) : !n.disabled && !n.busy && r();
1775
1775
  },
1776
1776
  children: [
1777
- m ? /* @__PURE__ */ e(z, { name: "spinner" }) : /* @__PURE__ */ e(_e, { name: n.icon }),
1778
- h ? /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__label", "aria-hidden": "true", children: n.label }) : null,
1779
- u !== null || p !== null && !a ? /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__tip", role: "tooltip", id: _, children: p }) : null
1777
+ h ? /* @__PURE__ */ e(z, { name: "spinner" }) : /* @__PURE__ */ e(_e, { name: n.icon }),
1778
+ m ? /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__label", "aria-hidden": "true", children: n.label }) : null,
1779
+ c !== null || f !== null && !s ? /* @__PURE__ */ e("span", { className: "cms-pane-toolbar__tip", role: "tooltip", id: p, children: f }) : null
1780
1780
  ]
1781
1781
  }
1782
1782
  );
1783
1783
  }
1784
1784
  function _e({ name: n }) {
1785
1785
  const l = re(n);
1786
- return l === null ? null : /* @__PURE__ */ e(L, { name: l, size: 18 });
1786
+ return l === null ? null : /* @__PURE__ */ e(T, { name: l, size: 18 });
1787
1787
  }
1788
- function rl({ title: n, body: l = null, time: t = null, unread: o, unreadLabel: c, expandLabel: a, collapseLabel: r, action: s = null, onRead: m, leading: f }) {
1789
- const [i, h] = A(!1), u = X(), p = () => {
1790
- o && m();
1791
- }, _ = (s == null ? void 0 : s.presentation) === "row" && s.onAction !== void 0, g = (s == null ? void 0 : s.presentation) === "button" && s.onAction !== void 0 ? s : null, N = () => {
1788
+ function il({ title: n, body: l = null, time: t = null, unread: o, unreadLabel: i, expandLabel: s, collapseLabel: r, action: a = null, onRead: h, leading: _ }) {
1789
+ const [d, m] = E(!1), c = G(), f = () => {
1790
+ o && h();
1791
+ }, p = (a == null ? void 0 : a.presentation) === "row" && a.onAction !== void 0, g = (a == null ? void 0 : a.presentation) === "button" && a.onAction !== void 0 ? a : null, N = () => {
1792
1792
  var w;
1793
- p(), _ && ((w = s.onAction) == null || w.call(s));
1793
+ f(), p && ((w = a.onAction) == null || w.call(a));
1794
1794
  };
1795
- return /* @__PURE__ */ d("article", { className: E("cms-notification", o && "is-unread", i && "is-expanded", _ && "is-row-action"), "data-state": o ? "unread" : "read", children: [
1796
- /* @__PURE__ */ d(
1795
+ return /* @__PURE__ */ u("article", { className: A("cms-notification", o && "is-unread", d && "is-expanded", p && "is-row-action"), "data-state": o ? "unread" : "read", children: [
1796
+ /* @__PURE__ */ u(
1797
1797
  "div",
1798
1798
  {
1799
1799
  className: "cms-notification__row",
1800
1800
  role: "button",
1801
1801
  tabIndex: 0,
1802
- "aria-describedby": l === null ? void 0 : u,
1802
+ "aria-describedby": l === null ? void 0 : c,
1803
1803
  onClick: N,
1804
1804
  onKeyDown: (w) => {
1805
1805
  w.target !== w.currentTarget || w.key !== "Enter" && w.key !== " " || (w.preventDefault(), N());
1806
1806
  },
1807
1807
  children: [
1808
- f != null ? /* @__PURE__ */ e("span", { className: "cms-notification__leading", children: f }) : null,
1809
- /* @__PURE__ */ d("span", { className: "cms-notification__text", children: [
1810
- /* @__PURE__ */ d("span", { className: "cms-notification__head", children: [
1811
- /* @__PURE__ */ d("span", { className: "cms-notification__title", children: [
1812
- o ? /* @__PURE__ */ d("span", { className: "cms-visually-hidden", children: [
1813
- c,
1808
+ _ != null ? /* @__PURE__ */ e("span", { className: "cms-notification__leading", children: _ }) : null,
1809
+ /* @__PURE__ */ u("span", { className: "cms-notification__text", children: [
1810
+ /* @__PURE__ */ u("span", { className: "cms-notification__head", children: [
1811
+ /* @__PURE__ */ u("span", { className: "cms-notification__title", children: [
1812
+ o ? /* @__PURE__ */ u("span", { className: "cms-visually-hidden", children: [
1813
+ i,
1814
1814
  " "
1815
1815
  ] }) : null,
1816
1816
  n
1817
1817
  ] }),
1818
1818
  t !== null ? /* @__PURE__ */ e("span", { className: "cms-notification__time", children: t }) : null
1819
1819
  ] }),
1820
- l !== null && l !== "" ? /* @__PURE__ */ e("span", { className: "cms-notification__body", id: u, children: l }) : null
1820
+ l !== null && l !== "" ? /* @__PURE__ */ e("span", { className: "cms-notification__body", id: c, children: l }) : null
1821
1821
  ] }),
1822
1822
  o ? /* @__PURE__ */ e("span", { className: "cms-notification__dot", "aria-hidden": "true" }) : null
1823
1823
  ]
@@ -1828,14 +1828,14 @@ function rl({ title: n, body: l = null, time: t = null, unread: o, unreadLabel:
1828
1828
  {
1829
1829
  type: "button",
1830
1830
  className: "cms-notification__chevron",
1831
- "aria-expanded": i,
1832
- "aria-controls": u,
1833
- "aria-label": i ? r : a,
1834
- title: i ? r : a,
1831
+ "aria-expanded": d,
1832
+ "aria-controls": c,
1833
+ "aria-label": d ? r : s,
1834
+ title: d ? r : s,
1835
1835
  onClick: () => {
1836
- i || p(), h((w) => !w);
1836
+ d || f(), m((w) => !w);
1837
1837
  },
1838
- children: /* @__PURE__ */ e(L, { name: "chevron-down", size: 18 })
1838
+ children: /* @__PURE__ */ e(T, { name: "chevron-down", size: 18 })
1839
1839
  }
1840
1840
  ) : null,
1841
1841
  g !== null ? /* @__PURE__ */ e(
@@ -1845,7 +1845,7 @@ function rl({ title: n, body: l = null, time: t = null, unread: o, unreadLabel:
1845
1845
  className: "cms-button cms-notification__action",
1846
1846
  onClick: () => {
1847
1847
  var w;
1848
- p(), (w = g.onAction) == null || w.call(g);
1848
+ f(), (w = g.onAction) == null || w.call(g);
1849
1849
  },
1850
1850
  children: g.label
1851
1851
  }
@@ -1855,7 +1855,7 @@ function rl({ title: n, body: l = null, time: t = null, unread: o, unreadLabel:
1855
1855
  function xn(n) {
1856
1856
  return n === "allowed" || n === "elevate" || n === "denied";
1857
1857
  }
1858
- function cl(n, l) {
1858
+ function ol(n, l) {
1859
1859
  if (!xn(n))
1860
1860
  return l.showRefused ? { offered: !0, locked: !1, refusal: "not available: the server gave an answer this app does not know", unknown: !0 } : { offered: !1, locked: !1, unknown: !0 };
1861
1861
  switch (n) {
@@ -1870,7 +1870,7 @@ function cl(n, l) {
1870
1870
  function Mn(n, l) {
1871
1871
  if (!n) return;
1872
1872
  if (typeof n.get == "function") return n.get(l) ?? void 0;
1873
- const t = n, o = Object.keys(t).find((c) => c.toLowerCase() === l.toLowerCase());
1873
+ const t = n, o = Object.keys(t).find((i) => i.toLowerCase() === l.toLowerCase());
1874
1874
  return o === void 0 ? void 0 : t[o];
1875
1875
  }
1876
1876
  function Cn(n) {
@@ -1880,189 +1880,204 @@ function Cn(n) {
1880
1880
  if (typeof l.title == "string" && l.title !== "") return l.title;
1881
1881
  }
1882
1882
  }
1883
- function il(n, l, t, o) {
1883
+ function dl(n, l, t, o) {
1884
1884
  if (n !== 403) return { kind: "none" };
1885
- const c = Cn(t);
1886
- return Mn(l, "X-Elevation-Required") !== void 0 ? o.elevates ? { kind: "elevation-required", message: c ?? "This needs an elevated session." } : { kind: "refused", message: "This can only be done in the admin, in an elevated session." } : { kind: "refused", message: c ?? "The server refused this." };
1885
+ const i = Cn(t);
1886
+ return Mn(l, "X-Elevation-Required") !== void 0 ? o.elevates ? { kind: "elevation-required", message: i ?? "This needs an elevated session." } : { kind: "refused", message: "This can only be done in the admin, in an elevated session." } : { kind: "refused", message: i ?? "The server refused this." };
1887
1887
  }
1888
1888
  const ke = "coolms-kit:reread";
1889
- function ol() {
1889
+ function ul() {
1890
1890
  window.dispatchEvent(new Event(ke));
1891
1891
  }
1892
- function dl(n) {
1893
- const [l, t] = A(void 0), [o, c] = A(void 0), [a, r] = A(!0), s = K(n);
1894
- s.current = n;
1895
- const m = K(0), f = be(() => {
1896
- const i = ++m.current;
1897
- r(!0), s.current().then(
1898
- (h) => {
1899
- i === m.current && (t(h), c(void 0), r(!1));
1892
+ function ml(n) {
1893
+ const [l, t] = E(void 0), [o, i] = E(void 0), [s, r] = E(!0), a = R(n);
1894
+ a.current = n;
1895
+ const h = R(0), _ = be(() => {
1896
+ const d = ++h.current;
1897
+ r(!0), a.current().then(
1898
+ (m) => {
1899
+ d === h.current && (t(m), i(void 0), r(!1));
1900
1900
  },
1901
- (h) => {
1902
- i === m.current && (c(h), r(!1));
1901
+ (m) => {
1902
+ d === h.current && (i(m), r(!1));
1903
1903
  }
1904
1904
  );
1905
1905
  }, []);
1906
1906
  return Y(() => {
1907
- f();
1908
- const i = () => f();
1909
- return window.addEventListener("focus", i), window.addEventListener(ke, i), () => {
1910
- window.removeEventListener("focus", i), window.removeEventListener(ke, i);
1907
+ _();
1908
+ const d = () => _();
1909
+ return window.addEventListener("focus", d), window.addEventListener(ke, d), () => {
1910
+ window.removeEventListener("focus", d), window.removeEventListener(ke, d);
1911
1911
  };
1912
- }, [f]), { value: l, error: o, loading: a, reread: f };
1912
+ }, [_]), { value: l, error: o, loading: s, reread: _ };
1913
1913
  }
1914
- function ul(n) {
1914
+ function hl(n) {
1915
1915
  return n === 412 ? { conflict: !0, message: "Someone changed this since you opened it. Nothing was saved; read it again to see the change." } : { conflict: !1 };
1916
1916
  }
1917
1917
  const Sn = "/errors/client-update-required";
1918
- function An(n, l) {
1919
- const t = n.split(".").map((c) => Number.parseInt(c, 10) || 0), o = l.split(".").map((c) => Number.parseInt(c, 10) || 0);
1920
- for (let c = 0; c < Math.max(t.length, o.length); c++) {
1921
- const a = t[c] ?? 0, r = o[c] ?? 0;
1922
- if (a !== r) return a < r;
1918
+ function En(n, l) {
1919
+ const t = n.split(".").map((i) => Number.parseInt(i, 10) || 0), o = l.split(".").map((i) => Number.parseInt(i, 10) || 0);
1920
+ for (let i = 0; i < Math.max(t.length, o.length); i++) {
1921
+ const s = t[i] ?? 0, r = o[i] ?? 0;
1922
+ if (s !== r) return s < r;
1923
1923
  }
1924
1924
  return !1;
1925
1925
  }
1926
- function ml(n) {
1927
- return n.problemType !== void 0 && n.problemType.endsWith(Sn) ? !0 : n.minimumVersion !== void 0 && An(n.version, n.minimumVersion);
1926
+ function fl(n) {
1927
+ return n.problemType !== void 0 && n.problemType.endsWith(Sn) ? !0 : n.minimumVersion !== void 0 && En(n.version, n.minimumVersion);
1928
1928
  }
1929
- const Pe = 4, En = 48;
1930
- function Tn(n, l) {
1931
- const [t, o] = A(!1);
1929
+ const Ie = 4, An = 48, Ln = 800, Tn = /* @__PURE__ */ new Set(["ArrowDown", "ArrowUp", "PageDown", "PageUp", "Home", "End", " "]);
1930
+ function Dn(n, l) {
1931
+ const [t, o] = E(!1);
1932
1932
  return Y(() => {
1933
- const c = n.current;
1934
- if (c === null || !l) {
1933
+ const i = n.current;
1934
+ if (i === null || !l) {
1935
1935
  o(!1);
1936
1936
  return;
1937
1937
  }
1938
- const a = /* @__PURE__ */ new WeakMap(), r = (s) => {
1939
- const m = s.target;
1940
- if (!(m instanceof HTMLElement)) return;
1941
- const f = m.scrollTop, i = a.get(m) ?? 0;
1942
- a.set(m, f), f <= 0 || f < i - Pe ? o(!1) : f > i + Pe && f > En && o(!0);
1938
+ const s = /* @__PURE__ */ new WeakMap();
1939
+ let r = Number.NEGATIVE_INFINITY;
1940
+ const a = () => {
1941
+ r = performance.now();
1942
+ }, h = (m) => {
1943
+ const c = m.target;
1944
+ !(c instanceof HTMLElement && (c.isContentEditable || c.closest("input, textarea, select") !== null)) && Tn.has(m.key) && a();
1945
+ }, _ = (m) => {
1946
+ const c = m.target;
1947
+ if (!(c instanceof HTMLElement)) return;
1948
+ const f = c.scrollTop, p = s.get(c) ?? 0;
1949
+ if (s.set(c, f), f <= 0) {
1950
+ o(!1);
1951
+ return;
1952
+ }
1953
+ performance.now() - r > Ln || (f < p - Ie ? o(!1) : f > p + Ie && f > An && o(!0));
1954
+ }, d = [["wheel", a], ["touchmove", a], ["pointerdown", a], ["keydown", h]];
1955
+ for (const [m, c] of d) i.addEventListener(m, c, { capture: !0, passive: !0 });
1956
+ return i.addEventListener("scroll", _, { capture: !0, passive: !0 }), () => {
1957
+ for (const [m, c] of d) i.removeEventListener(m, c, { capture: !0 });
1958
+ i.removeEventListener("scroll", _, { capture: !0 });
1943
1959
  };
1944
- return c.addEventListener("scroll", r, { capture: !0, passive: !0 }), () => c.removeEventListener("scroll", r, { capture: !0 });
1945
1960
  }, [n, l]), [t, o];
1946
1961
  }
1947
- function hl({ title: n, back: l, navigation: t, search: o, searching: c, globals: a, filters: r, primary: s, onRefresh: m, pullText: f, barHidden: i, children: h }) {
1948
- const u = K(null), p = K(null), [_, g] = A(!1), [N, w] = A(null), S = gn(p, m === void 0 ? null : () => {
1949
- _ || (g(!0), m().finally(() => g(!1)));
1950
- }), C = m === void 0 ? null : { distance: S, refreshing: _, text: f ?? null }, F = c !== void 0 || S > 0 || _, [H, ee] = Tn(u, i === void 0 && !F), j = !F && (i ?? H);
1951
- return /* @__PURE__ */ d(
1962
+ function pl({ title: n, back: l, navigation: t, search: o, searching: i, globals: s, filters: r, primary: a, onRefresh: h, pullText: _, barHidden: d, children: m }) {
1963
+ const c = R(null), f = R(null), [p, g] = E(!1), [N, w] = E(null), S = gn(f, h === void 0 ? null : () => {
1964
+ p || (g(!0), h().finally(() => g(!1)));
1965
+ }), C = h === void 0 ? null : { distance: S, refreshing: p, text: _ ?? null }, F = i !== void 0 || S > 0 || p, [H, ee] = Dn(c, d === void 0 && !F), j = !F && (d ?? H);
1966
+ return /* @__PURE__ */ u(
1952
1967
  "div",
1953
1968
  {
1954
- ref: u,
1955
- className: E("cms-screen", s !== void 0 && "cms-screen--with-primary"),
1969
+ ref: c,
1970
+ className: A("cms-screen", a !== void 0 && "cms-screen--with-primary"),
1956
1971
  "data-bar-hidden": j ? "" : void 0,
1957
1972
  onFocus: (y) => {
1958
1973
  j && y.target instanceof Element && y.target.closest(".cms-screen__bar, .cms-screen__filters") !== null && ee(!1);
1959
1974
  },
1960
1975
  children: [
1961
- c !== void 0 ? /* @__PURE__ */ d("header", { className: "cms-screen__bar cms-screen__bar--searching", children: [
1962
- /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button cms-screen__icon", "aria-label": c.closeLabel, title: c.closeLabel, onClick: c.onClose, children: /* @__PURE__ */ e(L, { name: "chevron-left" }) }),
1963
- /* @__PURE__ */ e("div", { className: "cms-screen__search", children: c.field })
1964
- ] }) : /* @__PURE__ */ d("header", { className: "cms-screen__bar", children: [
1965
- /* @__PURE__ */ e("div", { className: "cms-screen__leading", children: l !== void 0 ? l.href !== void 0 ? /* @__PURE__ */ d("a", { className: "cms-screen__back", href: l.href, onClick: l.onBack, children: [
1966
- /* @__PURE__ */ e(L, { name: "chevron-left" }),
1976
+ i !== void 0 ? /* @__PURE__ */ u("header", { className: "cms-screen__bar cms-screen__bar--searching", children: [
1977
+ /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button cms-screen__icon", "aria-label": i.closeLabel, title: i.closeLabel, onClick: i.onClose, children: /* @__PURE__ */ e(T, { name: "chevron-left" }) }),
1978
+ /* @__PURE__ */ e("div", { className: "cms-screen__search", children: i.field })
1979
+ ] }) : /* @__PURE__ */ u("header", { className: "cms-screen__bar", children: [
1980
+ /* @__PURE__ */ e("div", { className: "cms-screen__leading", children: l !== void 0 ? l.href !== void 0 ? /* @__PURE__ */ u("a", { className: "cms-screen__back", href: l.href, onClick: l.onBack, children: [
1981
+ /* @__PURE__ */ e(T, { name: "chevron-left" }),
1967
1982
  /* @__PURE__ */ e("span", { className: "cms-screen__back-name", children: l.label })
1968
- ] }) : /* @__PURE__ */ d("button", { type: "button", className: "cms-screen__back", onClick: l.onBack, children: [
1969
- /* @__PURE__ */ e(L, { name: "chevron-left" }),
1983
+ ] }) : /* @__PURE__ */ u("button", { type: "button", className: "cms-screen__back", onClick: l.onBack, children: [
1984
+ /* @__PURE__ */ e(T, { name: "chevron-left" }),
1970
1985
  /* @__PURE__ */ e("span", { className: "cms-screen__back-name", children: l.label })
1971
1986
  ] }) : t }),
1972
1987
  /* @__PURE__ */ e("h1", { className: "cms-screen__title", title: n, children: n }),
1973
- /* @__PURE__ */ d("div", { className: "cms-screen__trailing", children: [
1974
- o !== void 0 ? /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button cms-screen__icon", "aria-label": o.label, title: o.label, onClick: o.onOpen, children: /* @__PURE__ */ e(L, { name: "search" }) }) : null,
1975
- a
1988
+ /* @__PURE__ */ u("div", { className: "cms-screen__trailing", children: [
1989
+ o !== void 0 ? /* @__PURE__ */ e("button", { type: "button", className: "cms-icon-button cms-screen__icon", "aria-label": o.label, title: o.label, onClick: o.onOpen, children: /* @__PURE__ */ e(T, { name: "search" }) }) : null,
1990
+ s
1976
1991
  ] })
1977
1992
  ] }),
1978
1993
  r !== void 0 ? /* @__PURE__ */ e("div", { className: "cms-screen__filters", children: /* @__PURE__ */ e(hn, { label: r.label, options: r.options, value: r.selected, onChange: r.onSelect }) }) : null,
1979
- /* @__PURE__ */ e("div", { ref: p, className: "cms-screen__content", "data-pulling": S > 0 ? "" : void 0, "data-refreshing": _ ? "" : void 0, children: /* @__PURE__ */ e(Fe.Provider, { value: C, children: h }) }),
1980
- s !== void 0 ? /* @__PURE__ */ e(
1994
+ /* @__PURE__ */ e("div", { ref: f, className: "cms-screen__content", "data-pulling": S > 0 ? "" : void 0, "data-refreshing": p ? "" : void 0, children: /* @__PURE__ */ e(Fe.Provider, { value: C, children: m }) }),
1995
+ a !== void 0 ? /* @__PURE__ */ e(
1981
1996
  "button",
1982
1997
  {
1983
1998
  type: "button",
1984
1999
  className: "cms-button cms-button--primary cms-screen__primary",
1985
- "aria-label": s.label,
1986
- title: s.label,
1987
- ..."menu" in s ? { "aria-haspopup": "menu", "aria-expanded": N !== null } : {},
2000
+ "aria-label": a.label,
2001
+ title: a.label,
2002
+ ..."menu" in a ? { "aria-haspopup": "menu", "aria-expanded": N !== null } : {},
1988
2003
  onClick: (y) => {
1989
- if ("menu" in s) {
1990
- const I = y.currentTarget.getBoundingClientRect();
1991
- w(N === null ? { x: I.left, y: I.top } : null);
2004
+ if ("menu" in a) {
2005
+ const P = y.currentTarget.getBoundingClientRect();
2006
+ w(N === null ? { x: P.left, y: P.top } : null);
1992
2007
  } else
1993
- s.onPress();
2008
+ a.onPress();
1994
2009
  },
1995
- children: /* @__PURE__ */ e(L, { name: s.icon, size: 24 })
2010
+ children: /* @__PURE__ */ e(T, { name: a.icon, size: 24 })
1996
2011
  }
1997
2012
  ) : null,
1998
- s !== void 0 && "menu" in s ? /* @__PURE__ */ e(He, { at: N, items: s.menu, onClose: () => w(null), label: s.label }) : null
2013
+ a !== void 0 && "menu" in a ? /* @__PURE__ */ e(He, { at: N, items: a.menu, onClose: () => w(null), label: a.label }) : null
1999
2014
  ]
2000
2015
  }
2001
2016
  );
2002
2017
  }
2003
2018
  export {
2004
- jn as AppShell,
2019
+ Yn as AppShell,
2005
2020
  ve as Avatar,
2006
- Ee as BOOTSTRAP_ICONS,
2021
+ Ae as BOOTSTRAP_ICONS,
2007
2022
  mn as Badge,
2008
2023
  le as Button,
2009
- Ae as CALL_LABELS,
2024
+ Ee as CALL_LABELS,
2010
2025
  Sn as CLIENT_UPDATE_REQUIRED,
2011
- nl as CallBar,
2012
- el as CallPanel,
2013
- Gn as ChatBubble,
2014
- Jn as Composer,
2015
- Hn as ConfirmDialog,
2026
+ tl as CallBar,
2027
+ ll as CallPanel,
2028
+ Qn as ChatBubble,
2029
+ el as Composer,
2030
+ On as ConfirmDialog,
2016
2031
  He as ContextMenu,
2017
2032
  Ye as EmptyState,
2018
- Xe as ErrorBanner,
2019
- Zn as FilePicker,
2033
+ Ge as ErrorBanner,
2034
+ Wn as FilePicker,
2020
2035
  rn as FilePickerDenied,
2021
- zn as FileViewer,
2036
+ Vn as FileViewer,
2022
2037
  hn as FilterChips,
2023
- Rn as ICON_NAMES,
2024
- L as Icon,
2025
- Qn as IncomingCall,
2026
- al as List,
2038
+ zn as ICON_NAMES,
2039
+ T as Icon,
2040
+ nl as IncomingCall,
2041
+ rl as List,
2027
2042
  qe as Loading,
2028
2043
  _n as MAIL_ROW_LABELS,
2029
2044
  je as MODAL_CLOSE_MS,
2030
- Xn as MailRow,
2031
- Ie as Modal,
2032
- Un as NamedIcon,
2033
- rl as Notification,
2045
+ Jn as MailRow,
2046
+ Pe as Modal,
2047
+ Zn as NamedIcon,
2048
+ il as Notification,
2034
2049
  we as PULL_AT,
2035
- Vn as PageHeader,
2036
- sl as PaneToolbar,
2050
+ jn as PageHeader,
2051
+ cl as PaneToolbar,
2037
2052
  bn as SIGN_IN_LABELS,
2038
2053
  ye as STATE_DELAY_MS,
2039
- hl as ScreenShell,
2040
- qn as SearchField,
2041
- Bn as Select,
2042
- tl as SignInForm,
2043
- ll as SignInLayout,
2044
- Yn as SplitPanes,
2054
+ pl as ScreenShell,
2055
+ Gn as SearchField,
2056
+ Hn as Select,
2057
+ sl as SignInForm,
2058
+ al as SignInLayout,
2059
+ Xn as SplitPanes,
2045
2060
  ne as State,
2046
- Wn as TabStrip,
2047
- In as TextArea,
2048
- Pn as TextField,
2061
+ qn as TabStrip,
2062
+ Fn as TextArea,
2063
+ Bn as TextField,
2049
2064
  Kn as Toast,
2050
- On as ToastRegion,
2051
- Fn as Toggle,
2065
+ Un as ToastRegion,
2066
+ Rn as Toggle,
2052
2067
  fn as fitPanes,
2053
2068
  re as iconForName,
2054
2069
  dn as initialsOf,
2055
2070
  xn as isCapability,
2056
- ml as needsClientUpdate,
2057
- cl as offerFor,
2058
- ul as readConflict,
2059
- il as readRefusal,
2071
+ fl as needsClientUpdate,
2072
+ ol as offerFor,
2073
+ hl as readConflict,
2074
+ dl as readRefusal,
2060
2075
  Cn as refusalText,
2061
- ol as rereadAll,
2076
+ ul as rereadAll,
2062
2077
  un as tintOf,
2063
2078
  gn as usePull,
2064
2079
  Nn as usePullState,
2065
- dl as useReread,
2066
- An as versionBelow,
2080
+ ml as useReread,
2081
+ En as versionBelow,
2067
2082
  Ve as writtenOut
2068
2083
  };