@ahmetilhn/hanui 1.0.2 → 1.1.1

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/build/index.js CHANGED
@@ -1,9 +1,9 @@
1
1
  "use client";
2
- import { jsx as a, jsxs as _, Fragment as Je } from "react/jsx-runtime";
3
- import { useContext as Za, createContext as Ja, useMemo as aa, useEffect as R, useState as G, useCallback as Z, memo as h, forwardRef as ge, useId as te, useRef as Y, Children as Va } from "react";
4
- import { isClient as Ce, isDefined as Pe, normalize as ha, isNumber as pa } from "@ahmetilhn/handy-utils";
5
- import { createPortal as Qa } from "react-dom";
6
- const g = {
2
+ import { jsx as a, jsxs as _, Fragment as aa } from "react/jsx-runtime";
3
+ import { useContext as en, createContext as an, useMemo as ia, useEffect as F, useRef as Y, useState as Z, useCallback as Q, memo as v, forwardRef as xe, useId as ce, Children as nn } from "react";
4
+ import { isClient as Me, isDefined as Ge, normalize as fa, isNumber as ya } from "@ahmetilhn/handy-utils";
5
+ import { createPortal as tn } from "react-dom";
6
+ const k = {
7
7
  n0: "#ffffff",
8
8
  n25: "#fafbfc",
9
9
  n50: "#f6f7f9",
@@ -26,14 +26,14 @@ const g = {
26
26
  n550: "#6b7583",
27
27
  n600: "#5a6472",
28
28
  n900: "#11151b"
29
- }, W = {
29
+ }, ne = {
30
30
  base: "#1f2937",
31
31
  two: "#2b3646",
32
32
  three: "#3a4658",
33
33
  /** Koyu temada üst bant; sayfadan koyu kalmalı. */
34
34
  ink: "#12161d",
35
35
  inkTwo: "#1c222b"
36
- }, ae = {
36
+ }, ie = {
37
37
  base: "#f59e0b",
38
38
  hover: "#d98706",
39
39
  active: "#b87205",
@@ -43,7 +43,7 @@ const g = {
43
43
  darkHover: "#f0af12",
44
44
  /** Amber üzerinde metin — beyaz 2,3:1'de kalıyor, okunmuyor. */
45
45
  on: "#291500"
46
- }, B = {
46
+ }, z = {
47
47
  base: "#2f6fed",
48
48
  hover: "#1d54c4",
49
49
  active: "#17439c",
@@ -55,7 +55,7 @@ const g = {
55
55
  darkHover: "#7aa8ff",
56
56
  darkTint: "#16243c",
57
57
  darkLine: "#2a3f63"
58
- }, w = {
58
+ }, C = {
59
59
  /* Yeşil ailesi `ANCHOR.green`den türetildi (L +44 / S −24, L +33 / S −14). */
60
60
  okBg: "#e8f4eb",
61
61
  /** 5,58:1 tint üzerinde — metin katmanı. */
@@ -105,13 +105,13 @@ const g = {
105
105
  altBgDark: "#1d1a33",
106
106
  altFgDark: "#bfb3f5",
107
107
  altLineDark: "#332d56"
108
- }, $e = {
108
+ }, Ie = {
109
109
  base: "#dc2626",
110
110
  hover: "#bb1e1e",
111
111
  dark: "#e45b5b",
112
112
  darkHover: "#ef7a72",
113
113
  onDark: "#1a0b0a"
114
- }, me = {
114
+ }, ve = {
115
115
  red: "#dc2626",
116
116
  redDark: "#e35252",
117
117
  green: "#34c759",
@@ -120,37 +120,37 @@ const g = {
120
120
  greenHoverDark: "#63e084",
121
121
  /** Yeşil dolgu üzerindeki metin. BEYAZ DEĞİL: #34c759 üzerinde 2,22:1. */
122
122
  onGreen: "#06280f"
123
- }, na = {
123
+ }, sa = {
124
124
  bg: "#e8f4eb",
125
125
  fg: "#1d6e31",
126
126
  bgDark: "#122817",
127
127
  fgDark: "#34c759"
128
- }, ka = {
128
+ }, La = {
129
129
  /** 5,23:1 beyaz üzerinde. */
130
130
  light: "#9a5f04",
131
131
  /** 9,82:1 koyu zemin üzerinde. */
132
132
  dark: "#f0b429"
133
- }, x = (e, n) => {
134
- const t = e.replace("#", ""), o = t.length === 3 ? t.split("").map((l) => l + l).join("") : t, r = parseInt(o.slice(0, 2), 16), i = parseInt(o.slice(2, 4), 16), s = parseInt(o.slice(4, 6), 16);
135
- return `rgba(${r}, ${i}, ${s}, ${n})`;
136
- }, J = "#000000", Wa = {
133
+ }, w = (e, n) => {
134
+ const t = e.replace("#", ""), o = t.length === 3 ? t.split("").map((c) => c + c).join("") : t, i = parseInt(o.slice(0, 2), 16), r = parseInt(o.slice(2, 4), 16), s = parseInt(o.slice(4, 6), 16);
135
+ return `rgba(${i}, ${r}, ${s}, ${n})`;
136
+ }, V = "#000000", on = {
137
137
  // --- Yüzey ---
138
- page: g.n50,
139
- surface: g.n0,
140
- "surface-2": g.n100,
141
- "surface-3": g.n150,
142
- "surface-inset": g.n25,
138
+ page: k.n50,
139
+ surface: k.n0,
140
+ "surface-2": k.n100,
141
+ "surface-3": k.n150,
142
+ "surface-inset": k.n25,
143
143
  // --- Kenarlık ---
144
- border: g.n250,
145
- "border-strong": g.n300,
144
+ border: k.n250,
145
+ "border-strong": k.n300,
146
146
  // --- Metin ---
147
- text: g.n900,
148
- "text-2": g.n600,
149
- "text-3": g.n550,
147
+ text: k.n900,
148
+ "text-2": k.n600,
149
+ "text-3": k.n550,
150
150
  // --- Grafit: bant, alt bilgi, tablo başlığı, teknik blok ---
151
- graphite: W.base,
152
- "graphite-2": W.two,
153
- "graphite-3": W.three,
151
+ graphite: ne.base,
152
+ "graphite-2": ne.two,
153
+ "graphite-3": ne.three,
154
154
  /*
155
155
  * BİRİNCİL EYLEM (dolgulu, nötr).
156
156
  *
@@ -158,56 +158,56 @@ const g = {
158
158
  * ayrılmıştır; her dolu düğmeyi amber yapmak o tekilliği yok eder ve
159
159
  * kullanıcı hangi turuncunun dönüşüm olduğunu bilemez.
160
160
  */
161
- action: W.base,
162
- "action-hover": W.two,
163
- "action-active": W.three,
164
- "on-action": g.n0,
161
+ action: ne.base,
162
+ "action-hover": ne.two,
163
+ "action-active": ne.three,
164
+ "on-action": k.n0,
165
165
  /** Pasif dolgu; saydamlık DEĞİL kendi rengi (bkz. Button `:disabled`). */
166
- "action-soft": g.n300,
166
+ "action-soft": k.n300,
167
167
  // --- Dönüşüm eylemi: ekrandaki tek doygun turuncu ---
168
- amber: ae.base,
169
- "amber-hover": ae.hover,
170
- "amber-active": ae.active,
171
- "amber-soft": ae.soft,
172
- "on-amber": ae.on,
168
+ amber: ie.base,
169
+ "amber-hover": ie.hover,
170
+ "amber-active": ie.active,
171
+ "amber-soft": ie.soft,
172
+ "on-amber": ie.on,
173
173
  // --- Mavi: gezinme ve keşif ---
174
- blue: B.base,
175
- "blue-hover": B.hover,
176
- "blue-active": B.active,
177
- "blue-text": B.text,
178
- "blue-tint": B.tint,
179
- "blue-line": B.line,
174
+ blue: z.base,
175
+ "blue-hover": z.hover,
176
+ "blue-active": z.active,
177
+ "blue-text": z.text,
178
+ "blue-tint": z.tint,
179
+ "blue-line": z.line,
180
180
  // --- Durum: tint zemin + koyu metin + eşleşen hairline ---
181
- "ok-bg": w.okBg,
182
- "ok-fg": w.okFg,
183
- "ok-line": w.okLine,
184
- "warn-bg": w.warnBg,
185
- "warn-fg": w.warnFg,
186
- "warn-line": w.warnLine,
187
- "off-bg": w.offBg,
188
- "off-fg": w.offFg,
189
- "off-line": w.offLine,
190
- "bad-bg": w.badBg,
191
- "bad-fg": w.badFg,
192
- "bad-line": w.badLine,
193
- "oem-bg": w.oemBg,
194
- "oem-fg": w.oemFg,
195
- "oem-line": w.oemLine,
196
- "alt-bg": w.altBg,
197
- "alt-fg": w.altFg,
198
- "alt-line": w.altLine,
199
- "sale-bg": na.bg,
200
- "sale-fg": na.fg,
181
+ "ok-bg": C.okBg,
182
+ "ok-fg": C.okFg,
183
+ "ok-line": C.okLine,
184
+ "warn-bg": C.warnBg,
185
+ "warn-fg": C.warnFg,
186
+ "warn-line": C.warnLine,
187
+ "off-bg": C.offBg,
188
+ "off-fg": C.offFg,
189
+ "off-line": C.offLine,
190
+ "bad-bg": C.badBg,
191
+ "bad-fg": C.badFg,
192
+ "bad-line": C.badLine,
193
+ "oem-bg": C.oemBg,
194
+ "oem-fg": C.oemFg,
195
+ "oem-line": C.oemLine,
196
+ "alt-bg": C.altBg,
197
+ "alt-fg": C.altFg,
198
+ "alt-line": C.altLine,
199
+ "sale-bg": sa.bg,
200
+ "sale-fg": sa.fg,
201
201
  // --- İkon vurguları: METİN DEĞİL (WCAG grafik eşiği 3:1) ---
202
- "red-accent": me.red,
203
- "green-accent": me.green,
204
- "green-accent-hover": me.greenHover,
205
- "on-green": me.onGreen,
206
- star: ka.light,
202
+ "red-accent": ve.red,
203
+ "green-accent": ve.green,
204
+ "green-accent-hover": ve.greenHover,
205
+ "on-green": ve.onGreen,
206
+ star: La.light,
207
207
  // --- Yıkıcı eylem: durum tinti DEĞİL, gerçek bir dolgu ---
208
- "danger-solid": $e.base,
209
- "danger-solid-hover": $e.hover,
210
- "on-danger": g.n0,
208
+ "danger-solid": Ie.base,
209
+ "danger-solid-hover": Ie.hover,
210
+ "on-danger": k.n0,
211
211
  /*
212
212
  * ÜST BANT / ALT BİLGİ / KAHRAMAN BÖLÜMÜ.
213
213
  *
@@ -217,49 +217,49 @@ const g = {
217
217
  * sayfa üzerinde), alt bilgi bir kademe çöker. Bunu `surface` ile yazmak
218
218
  * iki bandı sayfayla aynı tonda bırakıyordu.
219
219
  */
220
- "nav-bg": g.n0,
221
- "nav-bg-2": g.n100,
222
- "nav-fg": g.n900,
223
- "nav-fg-2": g.n600,
224
- "nav-fg-3": g.n500,
225
- "nav-line": g.n200,
226
- "nav-line-strong": g.n300,
227
- "nav-hover": g.n100,
228
- "footer-bg": g.n100,
220
+ "nav-bg": k.n0,
221
+ "nav-bg-2": k.n100,
222
+ "nav-fg": k.n900,
223
+ "nav-fg-2": k.n600,
224
+ "nav-fg-3": k.n500,
225
+ "nav-line": k.n200,
226
+ "nav-line-strong": k.n300,
227
+ "nav-hover": k.n100,
228
+ "footer-bg": k.n100,
229
229
  // --- Gölge: nötr-serin (sıcak gölge serin gri zeminde kirli durur) ---
230
- "shadow-xs": `0 1px 2px ${x(g.n900, 0.05)}`,
231
- "shadow-sm": `0 1px 2px ${x(g.n900, 0.05)}, 0 1px 3px ${x(g.n900, 0.04)}`,
232
- "shadow-md": `0 2px 4px ${x(g.n900, 0.04)}, 0 6px 16px ${x(g.n900, 0.07)}`,
233
- "shadow-lg": `0 4px 8px ${x(g.n900, 0.05)}, 0 16px 32px ${x(g.n900, 0.1)}`,
234
- "shadow-xl": `0 8px 16px ${x(g.n900, 0.06)}, 0 28px 56px ${x(g.n900, 0.13)}`,
230
+ "shadow-xs": `0 1px 2px ${w(k.n900, 0.05)}`,
231
+ "shadow-sm": `0 1px 2px ${w(k.n900, 0.05)}, 0 1px 3px ${w(k.n900, 0.04)}`,
232
+ "shadow-md": `0 2px 4px ${w(k.n900, 0.04)}, 0 6px 16px ${w(k.n900, 0.07)}`,
233
+ "shadow-lg": `0 4px 8px ${w(k.n900, 0.05)}, 0 16px 32px ${w(k.n900, 0.1)}`,
234
+ "shadow-xl": `0 8px 16px ${w(k.n900, 0.06)}, 0 28px 56px ${w(k.n900, 0.13)}`,
235
235
  /** Yapışkan alt bar; gölge YUKARI düşer. */
236
- "shadow-up": `0 -2px 4px ${x(g.n900, 0.03)}, 0 -8px 24px ${x(g.n900, 0.08)}`,
236
+ "shadow-up": `0 -2px 4px ${w(k.n900, 0.03)}, 0 -8px 24px ${w(k.n900, 0.08)}`,
237
237
  /** Odak halkası MAVİ: odak bir gezinme olayıdır, bir dönüşüm değil. */
238
- ring: `0 0 0 3px ${x(B.base, 0.28)}`,
239
- "ring-color": B.base,
240
- "ring-danger": `0 0 0 3px ${x($e.base, 0.24)}`,
241
- "ring-ok": `0 0 0 4px ${x(w.okFg, 0.16)}`,
238
+ ring: `0 0 0 3px ${w(z.base, 0.28)}`,
239
+ "ring-color": z.base,
240
+ "ring-danger": `0 0 0 3px ${w(Ie.base, 0.24)}`,
241
+ "ring-ok": `0 0 0 4px ${w(C.okFg, 0.16)}`,
242
242
  // --- Örtü ve cam: görsel üzerine binen yüzeyler ---
243
- scrim: x(g.n900, 0.55),
244
- "scrim-soft": x(g.n900, 0.32),
245
- glass: x(g.n0, 0.92),
246
- "glass-solid": g.n0,
247
- "on-scrim": g.n0,
243
+ scrim: w(k.n900, 0.55),
244
+ "scrim-soft": w(k.n900, 0.32),
245
+ glass: w(k.n0, 0.92),
246
+ "glass-solid": k.n0,
247
+ "on-scrim": k.n0,
248
248
  // --- İskelet ve dönen gösterge ---
249
- "skeleton-a": g.n100,
250
- "skeleton-b": g.n25,
251
- track: x(g.n900, 0.12),
249
+ "skeleton-a": k.n100,
250
+ "skeleton-b": k.n25,
251
+ track: w(k.n900, 0.12),
252
252
  /** Görsel yer tutucu (medya yoksa). */
253
- "media-bg": g.n100,
253
+ "media-bg": k.n100,
254
254
  /*
255
255
  * Vurgu bloğundaki ışık lekeleri. Açık temada ZEMİN DE AÇIK olduğu için
256
256
  * lekeler çok daha hafif: koyu bant için ayarlanmış %22 opaklık açık
257
257
  * zeminde lekeyi kirli bir dasa çeviriyordu.
258
258
  */
259
- "glow-1": x(B.base, 0.1),
260
- "glow-2": x(B.base, 0.06),
261
- "glow-amber": x(ae.base, 0.09)
262
- }, en = {
259
+ "glow-1": w(z.base, 0.1),
260
+ "glow-2": w(z.base, 0.06),
261
+ "glow-amber": w(ie.base, 0.09)
262
+ }, rn = {
263
263
  page: "#0e1116",
264
264
  surface: "#171b22",
265
265
  "surface-2": "#1f242d",
@@ -270,124 +270,124 @@ const g = {
270
270
  text: "#e7eaee",
271
271
  "text-2": "#9aa4b2",
272
272
  "text-3": "#6b7583",
273
- graphite: W.ink,
274
- "graphite-2": W.inkTwo,
275
- "graphite-3": W.two,
273
+ graphite: ne.ink,
274
+ "graphite-2": ne.inkTwo,
275
+ "graphite-3": ne.two,
276
276
  /*
277
277
  * Koyu temada grafit dolgu sayfadan ayırt edilemez. Birincil eylem AÇIK bir
278
278
  * nötr yüzeye döner — koyu zeminde en yüksek vurgu budur.
279
279
  */
280
- action: g.n150,
281
- "action-hover": g.n0,
282
- "action-active": g.n300,
283
- "on-action": g.n900,
280
+ action: k.n150,
281
+ "action-hover": k.n0,
282
+ "action-active": k.n300,
283
+ "on-action": k.n900,
284
284
  "action-soft": "#414a58",
285
- amber: ae.dark,
286
- "amber-hover": ae.darkHover,
287
- "amber-active": ae.base,
285
+ amber: ie.dark,
286
+ "amber-hover": ie.darkHover,
287
+ "amber-active": ie.base,
288
288
  "amber-soft": "#6d5316",
289
- "on-amber": ae.on,
290
- blue: B.dark,
291
- "blue-hover": B.darkHover,
292
- "blue-active": B.base,
293
- "blue-text": B.dark,
294
- "blue-tint": B.darkTint,
295
- "blue-line": B.darkLine,
296
- "ok-bg": w.okBgDark,
297
- "ok-fg": w.okFgDark,
298
- "ok-line": w.okLineDark,
299
- "warn-bg": w.warnBgDark,
300
- "warn-fg": w.warnFgDark,
301
- "warn-line": w.warnLineDark,
302
- "off-bg": w.offBgDark,
303
- "off-fg": w.offFgDark,
304
- "off-line": w.offLineDark,
305
- "bad-bg": w.badBgDark,
306
- "bad-fg": w.badFgDark,
307
- "bad-line": w.badLineDark,
308
- "oem-bg": w.oemBgDark,
309
- "oem-fg": w.oemFgDark,
310
- "oem-line": w.oemLineDark,
311
- "alt-bg": w.altBgDark,
312
- "alt-fg": w.altFgDark,
313
- "alt-line": w.altLineDark,
314
- "sale-bg": na.bgDark,
315
- "sale-fg": na.fgDark,
316
- "red-accent": me.redDark,
317
- "green-accent": me.greenDark,
318
- "green-accent-hover": me.greenHoverDark,
319
- "on-green": me.onGreen,
320
- star: ka.dark,
321
- "danger-solid": $e.dark,
322
- "danger-solid-hover": $e.darkHover,
323
- "on-danger": $e.onDark,
289
+ "on-amber": ie.on,
290
+ blue: z.dark,
291
+ "blue-hover": z.darkHover,
292
+ "blue-active": z.base,
293
+ "blue-text": z.dark,
294
+ "blue-tint": z.darkTint,
295
+ "blue-line": z.darkLine,
296
+ "ok-bg": C.okBgDark,
297
+ "ok-fg": C.okFgDark,
298
+ "ok-line": C.okLineDark,
299
+ "warn-bg": C.warnBgDark,
300
+ "warn-fg": C.warnFgDark,
301
+ "warn-line": C.warnLineDark,
302
+ "off-bg": C.offBgDark,
303
+ "off-fg": C.offFgDark,
304
+ "off-line": C.offLineDark,
305
+ "bad-bg": C.badBgDark,
306
+ "bad-fg": C.badFgDark,
307
+ "bad-line": C.badLineDark,
308
+ "oem-bg": C.oemBgDark,
309
+ "oem-fg": C.oemFgDark,
310
+ "oem-line": C.oemLineDark,
311
+ "alt-bg": C.altBgDark,
312
+ "alt-fg": C.altFgDark,
313
+ "alt-line": C.altLineDark,
314
+ "sale-bg": sa.bgDark,
315
+ "sale-fg": sa.fgDark,
316
+ "red-accent": ve.redDark,
317
+ "green-accent": ve.greenDark,
318
+ "green-accent-hover": ve.greenHoverDark,
319
+ "on-green": ve.onGreen,
320
+ star: La.dark,
321
+ "danger-solid": Ie.dark,
322
+ "danger-solid-hover": Ie.darkHover,
323
+ "on-danger": Ie.onDark,
324
324
  /* Koyu temada bant sayfadan daha KOYU: aynı tonda olsa yüzüyor görünüyor. */
325
- "nav-bg": W.ink,
326
- "nav-bg-2": W.inkTwo,
325
+ "nav-bg": ne.ink,
326
+ "nav-bg-2": ne.inkTwo,
327
327
  "nav-fg": "#e7eaee",
328
328
  "nav-fg-2": "#9aa4b2",
329
329
  "nav-fg-3": "#6b7583",
330
330
  "nav-line": "#262c36",
331
331
  "nav-line-strong": "#363e4a",
332
- "nav-hover": x(g.n0, 0.07),
333
- "footer-bg": W.ink,
332
+ "nav-hover": w(k.n0, 0.07),
333
+ "footer-bg": ne.ink,
334
334
  /*
335
335
  * Koyu zeminde gölge okunmaz; derinlik daha çok kenarlıkla kurulur.
336
336
  * Gölgeler yine de KORUNUR ama daha derin: modal ve açılır liste yüzeyin
337
337
  * üzerinde durmalı.
338
338
  */
339
- "shadow-xs": `0 1px 2px ${x(J, 0.4)}`,
340
- "shadow-sm": `0 1px 2px ${x(J, 0.4)}, 0 1px 3px ${x(J, 0.3)}`,
341
- "shadow-md": `0 2px 4px ${x(J, 0.35)}, 0 6px 16px ${x(J, 0.45)}`,
342
- "shadow-lg": `0 4px 8px ${x(J, 0.4)}, 0 16px 32px ${x(J, 0.55)}`,
343
- "shadow-xl": `0 8px 16px ${x(J, 0.45)}, 0 28px 56px ${x(J, 0.6)}`,
344
- "shadow-up": `0 -2px 4px ${x(J, 0.3)}, 0 -8px 24px ${x(J, 0.45)}`,
345
- ring: `0 0 0 3px ${x(B.dark, 0.36)}`,
346
- "ring-color": B.dark,
347
- "ring-danger": `0 0 0 3px ${x($e.dark, 0.32)}`,
348
- "ring-ok": `0 0 0 4px ${x(w.okFgDark, 0.2)}`,
349
- scrim: x(J, 0.68),
350
- "scrim-soft": x(J, 0.45),
351
- glass: x("#1f242d", 0.92),
339
+ "shadow-xs": `0 1px 2px ${w(V, 0.4)}`,
340
+ "shadow-sm": `0 1px 2px ${w(V, 0.4)}, 0 1px 3px ${w(V, 0.3)}`,
341
+ "shadow-md": `0 2px 4px ${w(V, 0.35)}, 0 6px 16px ${w(V, 0.45)}`,
342
+ "shadow-lg": `0 4px 8px ${w(V, 0.4)}, 0 16px 32px ${w(V, 0.55)}`,
343
+ "shadow-xl": `0 8px 16px ${w(V, 0.45)}, 0 28px 56px ${w(V, 0.6)}`,
344
+ "shadow-up": `0 -2px 4px ${w(V, 0.3)}, 0 -8px 24px ${w(V, 0.45)}`,
345
+ ring: `0 0 0 3px ${w(z.dark, 0.36)}`,
346
+ "ring-color": z.dark,
347
+ "ring-danger": `0 0 0 3px ${w(Ie.dark, 0.32)}`,
348
+ "ring-ok": `0 0 0 4px ${w(C.okFgDark, 0.2)}`,
349
+ scrim: w(V, 0.68),
350
+ "scrim-soft": w(V, 0.45),
351
+ glass: w("#1f242d", 0.92),
352
352
  "glass-solid": "#1f242d",
353
- "on-scrim": g.n0,
353
+ "on-scrim": k.n0,
354
354
  "skeleton-a": "#1f242d",
355
355
  "skeleton-b": "#262c36",
356
- track: x(g.n0, 0.14),
356
+ track: w(k.n0, 0.14),
357
357
  "media-bg": "#1f242d",
358
- "glow-1": x(B.base, 0.2),
359
- "glow-2": x(B.dark, 0.1),
360
- "glow-amber": x(ae.dark, 0.12)
361
- }, Ss = {
358
+ "glow-1": w(z.base, 0.2),
359
+ "glow-2": w(z.dark, 0.1),
360
+ "glow-amber": w(ie.dark, 0.12)
361
+ }, zs = {
362
362
  heading: "system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif",
363
363
  body: "system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif",
364
364
  mono: "ui-monospace, 'SF Mono', Menlo, Consolas, monospace"
365
- }, ba = "--hanui-", ma = "hanui-theme-overrides", De = "data-hanui-theme", ga = "hanui-theme-switching", Fs = (e, n) => {
366
- const t = e === "dark" ? en : Wa, o = (e === "dark" ? n == null ? void 0 : n.dark : n == null ? void 0 : n.light) ?? {};
365
+ }, va = "--hanui-", xa = "hanui-theme-overrides", Ee = "data-hanui-theme", ka = "hanui-theme-switching", Ks = (e, n) => {
366
+ const t = e === "dark" ? rn : on, o = (e === "dark" ? n == null ? void 0 : n.dark : n == null ? void 0 : n.light) ?? {};
367
367
  return { ...t, ...o };
368
- }, an = (e) => {
369
- const n = [], t = (i, s = " ") => Object.entries(i).map(([l, u]) => `${s}${ba}${l}: ${u};`).join(`
370
- `), o = e.fonts ?? {}, r = Object.entries(o).filter(([, i]) => !!i);
371
- if (r.length > 0 && n.push(
368
+ }, sn = (e) => {
369
+ const n = [], t = (r, s = " ") => Object.entries(r).map(([c, l]) => `${s}${va}${c}: ${l};`).join(`
370
+ `), o = e.fonts ?? {}, i = Object.entries(o).filter(([, r]) => !!r);
371
+ if (i.length > 0 && n.push(
372
372
  `:root {
373
- ${r.map(([i, s]) => ` ${ba}font-${i}: ${s};`).join(`
373
+ ${i.map(([r, s]) => ` ${va}font-${r}: ${s};`).join(`
374
374
  `)}
375
375
  }`
376
376
  ), e.light && Object.keys(e.light).length > 0) {
377
- const i = t(e.light);
377
+ const r = t(e.light);
378
378
  n.push(`:root {
379
- ${i}
380
- }`), n.push(`:root[${De}='light'] {
381
- ${i}
379
+ ${r}
380
+ }`), n.push(`:root[${Ee}='light'] {
381
+ ${r}
382
382
  }`);
383
383
  }
384
384
  if (e.dark && Object.keys(e.dark).length > 0) {
385
- const i = t(e.dark);
386
- n.push(`:root[${De}='dark'] {
387
- ${i}
385
+ const r = t(e.dark);
386
+ n.push(`:root[${Ee}='dark'] {
387
+ ${r}
388
388
  }`), n.push(
389
389
  `@media (prefers-color-scheme: dark) {
390
- :root:not([${De}]) {
390
+ :root:not([${Ee}]) {
391
391
  ${t(
392
392
  e.dark,
393
393
  " "
@@ -399,76 +399,86 @@ ${t(
399
399
  return n.join(`
400
400
 
401
401
  `);
402
- }, Na = (e) => {
403
- if (!Ce()) return;
404
- const n = e ? an(e) : "", t = document.getElementById(ma);
402
+ }, Ca = (e) => {
403
+ if (!Me()) return;
404
+ const n = e ? sn(e) : "", t = document.getElementById(xa);
405
405
  if (n === "") {
406
406
  t == null || t.remove();
407
407
  return;
408
408
  }
409
409
  const o = t ?? document.createElement("style");
410
- o.id = ma, o.textContent = n, t || document.head.appendChild(o);
411
- }, wa = Ja({}), nn = () => Za(wa), Os = ({ children: e, theme: n, linkComponent: t }) => {
412
- const o = aa(() => n ? JSON.stringify(n) : "", [n]);
413
- R(() => {
414
- Na(n);
415
- }, [o]);
416
- const r = aa(() => ({ theme: n, linkComponent: t }), [o, t]);
417
- return /* @__PURE__ */ a(wa.Provider, { value: r, children: e });
418
- }, Hs = (e = {}) => {
419
- Na(e.theme), !(!Ce() || !e.colorScheme) && document.documentElement.setAttribute(De, e.colorScheme);
420
- }, $a = () => {
410
+ o.id = xa, o.textContent = n, t || document.head.appendChild(o);
411
+ }, Ia = an({}), P = () => en(Ia), qs = ({ children: e, theme: n, linkComponent: t, labels: o }) => {
412
+ const i = ia(() => n ? JSON.stringify(n) : "", [n]);
413
+ F(() => {
414
+ Ca(n);
415
+ }, [i]);
416
+ const r = Y(n);
417
+ r.current = n;
418
+ const s = ia(
419
+ () => ({ theme: r.current, linkComponent: t, labels: o }),
420
+ /* `themeKey` denetciye GEREKSIZ gorunuyor cunku memo'nun govdesinde
421
+ gecmiyor — ama tam da isi bu: temanin ICERIGI degistiginde yeni bir
422
+ nesne uretilmesini saglayan tetik o. Cikarilirsa tema ezmesi degisse
423
+ de tuketiciler eski degeri gorurdu. */
424
+ // eslint-disable-next-line react-hooks/exhaustive-deps
425
+ [i, t, o]
426
+ );
427
+ return /* @__PURE__ */ a(Ia.Provider, { value: s, children: e });
428
+ }, js = (e = {}) => {
429
+ Ca(e.theme), !(!Me() || !e.colorScheme) && document.documentElement.setAttribute(Ee, e.colorScheme);
430
+ }, Ea = () => {
421
431
  var e;
422
- return Ce() && ((e = window.matchMedia) != null && e.call(window, "(prefers-color-scheme: dark)").matches) ? "dark" : "light";
423
- }, tn = () => {
424
- if (!Ce()) return "light";
425
- const e = document.documentElement.getAttribute(De);
426
- return e === "dark" || e === "light" ? e : $a();
427
- }, Ps = () => {
428
- const [e, n] = G("light"), [t, o] = G(!1);
429
- R(() => {
430
- n(tn()), o(!0);
431
- }, []), R(() => {
432
- if (!Ce() || !window.matchMedia) return;
433
- const s = window.matchMedia("(prefers-color-scheme: dark)"), l = () => {
434
- document.documentElement.hasAttribute(De) || n($a());
432
+ return Me() && ((e = window.matchMedia) != null && e.call(window, "(prefers-color-scheme: dark)").matches) ? "dark" : "light";
433
+ }, cn = () => {
434
+ if (!Me()) return "light";
435
+ const e = document.documentElement.getAttribute(Ee);
436
+ return e === "dark" || e === "light" ? e : Ea();
437
+ }, Gs = () => {
438
+ const [e, n] = Z("light"), [t, o] = Z(!1);
439
+ F(() => {
440
+ n(cn()), o(!0);
441
+ }, []), F(() => {
442
+ if (!Me() || !window.matchMedia) return;
443
+ const s = window.matchMedia("(prefers-color-scheme: dark)"), c = () => {
444
+ document.documentElement.hasAttribute(Ee) || n(Ea());
435
445
  };
436
- return s.addEventListener("change", l), () => s.removeEventListener("change", l);
446
+ return s.addEventListener("change", c), () => s.removeEventListener("change", c);
437
447
  }, []);
438
- const r = Z((s) => {
439
- if (!Ce()) return;
440
- const l = document.documentElement;
441
- l.classList.add(ga), l.setAttribute(De, s), n(s), window.requestAnimationFrame(() => {
442
- window.requestAnimationFrame(() => l.classList.remove(ga));
448
+ const i = Q((s) => {
449
+ if (!Me()) return;
450
+ const c = document.documentElement;
451
+ c.classList.add(ka), c.setAttribute(Ee, s), n(s), window.requestAnimationFrame(() => {
452
+ window.requestAnimationFrame(() => c.classList.remove(ka));
443
453
  });
444
- }, []), i = Z(
445
- () => r(e === "dark" ? "light" : "dark"),
446
- [e, r]
454
+ }, []), r = Q(
455
+ () => i(e === "dark" ? "light" : "dark"),
456
+ [e, i]
447
457
  );
448
- return { scheme: e, setScheme: r, toggle: i, isReady: t };
449
- }, Da = "--hanui-sheet-height", Ca = "--hanui-sheet-inset-bottom";
450
- let Ve = 0, ze = 0;
451
- const Ia = () => {
458
+ return { scheme: e, setScheme: i, toggle: r, isReady: t };
459
+ }, Ma = "--hanui-sheet-height", Ta = "--hanui-sheet-inset-bottom";
460
+ let na = 0, Ue = 0;
461
+ const Ra = () => {
452
462
  const e = window.visualViewport;
453
463
  if (!e) return;
454
464
  const n = window.innerHeight - e.height - e.offsetTop, t = document.documentElement;
455
- t.style.setProperty(Ca, `${Math.max(0, Math.round(n))}px`), t.style.setProperty(Da, `${Math.round(e.height)}px`);
456
- }, Me = () => {
457
- ze || (ze = window.requestAnimationFrame(() => {
458
- ze = 0, Ia();
465
+ t.style.setProperty(Ta, `${Math.max(0, Math.round(n))}px`), t.style.setProperty(Ma, `${Math.round(e.height)}px`);
466
+ }, Be = () => {
467
+ Ue || (Ue = window.requestAnimationFrame(() => {
468
+ Ue = 0, Ra();
459
469
  }));
460
- }, on = (e = !0) => {
461
- R(() => {
470
+ }, ln = (e = !0) => {
471
+ F(() => {
462
472
  if (!e) return;
463
473
  const n = window.visualViewport;
464
474
  if (n)
465
- return Ve += 1, Ve === 1 && (n.addEventListener("resize", Me), n.addEventListener("scroll", Me), window.addEventListener("orientationchange", Me)), Ia(), () => {
466
- Ve -= 1, !(Ve > 0) && (n.removeEventListener("resize", Me), n.removeEventListener("scroll", Me), window.removeEventListener("orientationchange", Me), ze && (window.cancelAnimationFrame(ze), ze = 0), document.documentElement.style.removeProperty(Ca), document.documentElement.style.removeProperty(Da));
475
+ return na += 1, na === 1 && (n.addEventListener("resize", Be), n.addEventListener("scroll", Be), window.addEventListener("orientationchange", Be)), Ra(), () => {
476
+ na -= 1, !(na > 0) && (n.removeEventListener("resize", Be), n.removeEventListener("scroll", Be), window.removeEventListener("orientationchange", Be), Ue && (window.cancelAnimationFrame(Ue), Ue = 0), document.documentElement.style.removeProperty(Ta), document.documentElement.style.removeProperty(Ma));
467
477
  };
468
478
  }, [e]);
469
479
  };
470
- var ue = /* @__PURE__ */ ((e) => (e.PRIMARY = "PRIMARY", e.CART = "CART", e.SECONDARY = "SECONDARY", e.OUTLINE = "OUTLINE", e.DARK = "DARK", e.LIGHT = "LIGHT", e.GHOST = "GHOST", e.DANGER = "DANGER", e))(ue || {}), Ie = /* @__PURE__ */ ((e) => (e.SMALL = "SMALL", e.MEDIUM = "MEDIUM", e.LARGE = "LARGE", e))(Ie || {});
471
- const rn = 640, zs = 768, sn = 1024, Ks = `(min-width: ${sn + 1}px)`, ca = `(min-width: ${rn + 1}px)`, fa = (e) => e.replace(/İ/g, "i").replace(/I/g, "i").replace(/ı/g, "i").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/ş/g, "s").replace(/ğ/g, "g").replace(/ç/g, "c").replace(/ø/g, "o").replace(/æ/g, "ae").replace(/ß/g, "ss").replace(/đ/g, "d").replace(/ł/g, "l").replace(/\s+/g, " ").trim(), va = (e, n) => fa(e).includes(fa(n)), cn = /* @__PURE__ */ new Set([
480
+ var ge = /* @__PURE__ */ ((e) => (e.PRIMARY = "PRIMARY", e.CART = "CART", e.SECONDARY = "SECONDARY", e.OUTLINE = "OUTLINE", e.DARK = "DARK", e.LIGHT = "LIGHT", e.GHOST = "GHOST", e.DANGER = "DANGER", e))(ge || {}), Te = /* @__PURE__ */ ((e) => (e.SMALL = "SMALL", e.MEDIUM = "MEDIUM", e.LARGE = "LARGE", e))(Te || {});
481
+ const dn = 640, Us = 768, _n = 1024, Xs = `(min-width: ${_n + 1}px)`, ha = `(min-width: ${dn + 1}px)`, Na = (e) => e.replace(/İ/g, "i").replace(/I/g, "i").replace(/ı/g, "i").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/ş/g, "s").replace(/ğ/g, "g").replace(/ç/g, "c").replace(/ø/g, "o").replace(/æ/g, "ae").replace(/ß/g, "ss").replace(/đ/g, "d").replace(/ł/g, "l").replace(/\s+/g, " ").trim(), wa = (e, n) => Na(e).includes(Na(n)), un = /* @__PURE__ */ new Set([
472
482
  "button",
473
483
  "checkbox",
474
484
  "color",
@@ -479,36 +489,44 @@ const rn = 640, zs = 768, sn = 1024, Ks = `(min-width: ${sn + 1}px)`, ca = `(min
479
489
  "range",
480
490
  "reset",
481
491
  "submit"
482
- ]), ln = (e) => {
492
+ ]), hn = (e) => {
483
493
  if (!(e instanceof HTMLElement)) return !1;
484
494
  if (e.isContentEditable) return !0;
485
495
  const n = e.getAttribute("contenteditable");
486
496
  if (n === "" || n === "true" || n === "plaintext-only") return !0;
487
497
  const t = e.tagName;
488
- return t === "TEXTAREA" ? !0 : t !== "INPUT" ? !1 : !cn.has(e.type);
489
- }, La = (e) => {
498
+ return t === "TEXTAREA" ? !0 : t !== "INPUT" ? !1 : !un.has(e.type);
499
+ }, Aa = (e) => {
490
500
  const n = e.ownerDocument.activeElement;
491
- !e.contains(n) || !ln(n) || (n.blur(), e.tabIndex = -1, e.focus({ preventScroll: !0 }));
501
+ !e.contains(n) || !hn(n) || (n.blur(), e.tabIndex = -1, e.focus({ preventScroll: !0 }));
492
502
  }, d = (...e) => {
493
503
  let n = "";
494
504
  for (const t of e)
495
505
  t && (n = n === "" ? t : `${n} ${t}`);
496
506
  return n;
497
- }, oe = ({ children: e, ...n }) => {
498
- const { linkComponent: t } = nn();
507
+ }, le = ({ children: e, ...n }) => {
508
+ const { linkComponent: t } = P();
499
509
  return t ? /* @__PURE__ */ a(t, { ...n, children: e }) : /* @__PURE__ */ a("a", { ...n, children: e });
500
- }, dn = "hanui-spinner-7pXwf", _n = "hanui-spinner__label-sZvSq", ia = {
501
- spinner: dn,
510
+ }, $a = /* @__PURE__ */ new Set(), I = (e, ...n) => {
511
+ for (const t of n) if (t !== void 0) return t;
512
+ return process.env.NODE_ENV !== "production" && !$a.has(e) && ($a.add(e), console.error(
513
+ `[hanui] Eksik metin: ${e}. Prop olarak geçin ya da <HanuiProvider labels={…}> içinde bir kez tanımlayın. Metinsiz bırakılan öğe ekran okuyucuda adsız kalır.`
514
+ )), "";
515
+ }, qe = (e, n, ...t) => n ? n(...t) : I(e), pn = "hanui-spinner-7pXwf", bn = "hanui-spinner__label-sZvSq", da = {
516
+ spinner: pn,
502
517
  "hanui-spin": "hanui-hanui-spin-wTV0a",
503
- spinner__label: _n,
518
+ spinner__label: bn,
504
519
  "spinner--sm": "hanui-spinner--sm-uI0wH",
505
520
  "spinner--md": "hanui-spinner--md--VmFK",
506
521
  "spinner--lg": "hanui-spinner--lg-K9k-Z"
507
- }, un = ({ size: e = "md", label: n, className: t }) => /* @__PURE__ */ a("span", { className: d(ia.spinner, ia[`spinner--${e}`], t), role: "status", children: /* @__PURE__ */ a("span", { className: ia.spinner__label, children: n }) }), Ea = h(un), hn = "hanui-button-SRu4R", pn = "hanui-button__icon-giom6", bn = "hanui-button__spinner-vexVG", mn = "hanui-button__label-qiMHm", ce = {
508
- button: hn,
509
- button__icon: pn,
510
- button__spinner: bn,
511
- button__label: mn,
522
+ }, mn = ({ size: e = "md", label: n, className: t }) => {
523
+ const { labels: o } = P();
524
+ return /* @__PURE__ */ a("span", { className: d(da.spinner, da[`spinner--${e}`], t), role: "status", children: /* @__PURE__ */ a("span", { className: da.spinner__label, children: n ?? I("Spinner.label", o == null ? void 0 : o.loading) }) });
525
+ }, Ba = v(mn), gn = "hanui-button-SRu4R", fn = "hanui-button__icon-giom6", yn = "hanui-button__spinner-vexVG", vn = "hanui-button__label-qiMHm", he = {
526
+ button: gn,
527
+ button__icon: fn,
528
+ button__spinner: yn,
529
+ button__label: vn,
512
530
  "button--full": "hanui-button--full-CwPHR",
513
531
  "button--loading": "hanui-button--loading-O-naJ",
514
532
  "button--small": "hanui-button--small-TF9Hz",
@@ -522,64 +540,64 @@ const rn = 640, zs = 768, sn = 1024, Ks = `(min-width: ${sn + 1}px)`, ca = `(min
522
540
  "button--light": "hanui-button--light-YzEPs",
523
541
  "button--ghost": "hanui-button--ghost-rijnZ",
524
542
  "button--danger": "hanui-button--danger-TNGd2"
525
- }, Ma = ge(
543
+ }, Sa = xe(
526
544
  ({
527
- variant: e = ue.PRIMARY,
528
- size: n = Ie.MEDIUM,
545
+ variant: e = ge.PRIMARY,
546
+ size: n = Te.MEDIUM,
529
547
  isLoading: t,
530
548
  isFullWidth: o,
531
- startIcon: r,
532
- endIcon: i,
549
+ startIcon: i,
550
+ endIcon: r,
533
551
  className: s,
534
- children: l,
535
- disabled: u,
536
- href: p,
537
- isExternal: m,
538
- linkProps: b,
539
- testId: c,
540
- ...v
541
- }, f) => {
542
- const C = d(
543
- ce.button,
544
- ce[`button--${e.toLowerCase()}`],
545
- ce[`button--${n.toLowerCase()}`],
546
- o && ce["button--full"],
547
- t && ce["button--loading"],
552
+ children: c,
553
+ disabled: l,
554
+ href: u,
555
+ isExternal: b,
556
+ linkProps: g,
557
+ testId: h,
558
+ ...p
559
+ }, N) => {
560
+ const m = d(
561
+ he.button,
562
+ he[`button--${e.toLowerCase()}`],
563
+ he[`button--${n.toLowerCase()}`],
564
+ o && he["button--full"],
565
+ t && he["button--loading"],
548
566
  s
549
- ), D = /* @__PURE__ */ _(Je, { children: [
550
- t && /* @__PURE__ */ a(Ea, { size: "sm", className: ce.button__spinner, label: "" }),
551
- !t && r && /* @__PURE__ */ a("span", { className: ce.button__icon, children: r }),
552
- /* @__PURE__ */ a("span", { className: ce.button__label, children: l }),
553
- i && /* @__PURE__ */ a("span", { className: ce.button__icon, children: i })
567
+ ), f = /* @__PURE__ */ _(aa, { children: [
568
+ t && /* @__PURE__ */ a(Ba, { size: "sm", className: he.button__spinner, label: "" }),
569
+ !t && i && /* @__PURE__ */ a("span", { className: he.button__icon, children: i }),
570
+ /* @__PURE__ */ a("span", { className: he.button__label, children: c }),
571
+ r && /* @__PURE__ */ a("span", { className: he.button__icon, children: r })
554
572
  ] });
555
- return p && m ? /* @__PURE__ */ a(
573
+ return u && b ? /* @__PURE__ */ a(
556
574
  "a",
557
575
  {
558
- href: p,
559
- className: C,
576
+ href: u,
577
+ className: m,
560
578
  target: "_blank",
561
579
  rel: "noopener noreferrer",
562
- "aria-label": v["aria-label"],
563
- "data-testid": c,
564
- children: D
580
+ "aria-label": p["aria-label"],
581
+ "data-testid": h,
582
+ children: f
565
583
  }
566
- ) : p ? /* @__PURE__ */ a(oe, { href: p, className: C, "data-testid": c, ...b, children: D }) : /* @__PURE__ */ a(
584
+ ) : u ? /* @__PURE__ */ a(le, { href: u, className: m, "data-testid": h, ...g, children: f }) : /* @__PURE__ */ a(
567
585
  "button",
568
586
  {
569
- ref: f,
570
- className: C,
571
- disabled: u || t,
587
+ ref: N,
588
+ className: m,
589
+ disabled: l || t,
572
590
  "aria-busy": t,
573
- "data-testid": c,
574
- ...v,
575
- children: D
591
+ "data-testid": h,
592
+ ...p,
593
+ children: f
576
594
  }
577
595
  );
578
596
  }
579
597
  );
580
- Ma.displayName = "Button";
581
- const Ze = h(Ma), gn = "hanui-iconButton-JdtwM", ra = {
582
- iconButton: gn,
598
+ Sa.displayName = "Button";
599
+ const ea = v(Sa), xn = "hanui-iconButton-JdtwM", _a = {
600
+ iconButton: xn,
583
601
  "iconButton--sm": "hanui-iconButton--sm-wE6zE",
584
602
  "iconButton--md": "hanui-iconButton--md-iTNNS",
585
603
  "iconButton--ghost": "hanui-iconButton--ghost-w-8K3",
@@ -587,53 +605,53 @@ const Ze = h(Ma), gn = "hanui-iconButton-JdtwM", ra = {
587
605
  "iconButton--solid": "hanui-iconButton--solid-NUszP",
588
606
  "iconButton--cart": "hanui-iconButton--cart-nVsH-",
589
607
  "iconButton--danger": "hanui-iconButton--danger-xKkEA"
590
- }, Aa = ge(
608
+ }, Fa = xe(
591
609
  ({
592
610
  icon: e,
593
611
  label: n,
594
612
  variant: t = "ghost",
595
613
  size: o = "md",
596
- className: r,
597
- type: i = "button",
614
+ className: i,
615
+ type: r = "button",
598
616
  href: s,
599
- linkProps: l,
600
- testId: u,
601
- ...p
602
- }, m) => {
603
- const b = d(
604
- ra.iconButton,
605
- ra[`iconButton--${t}`],
606
- ra[`iconButton--${o}`],
607
- r
617
+ linkProps: c,
618
+ testId: l,
619
+ ...u
620
+ }, b) => {
621
+ const g = d(
622
+ _a.iconButton,
623
+ _a[`iconButton--${t}`],
624
+ _a[`iconButton--${o}`],
625
+ i
608
626
  );
609
627
  return s ? /* @__PURE__ */ a(
610
- oe,
628
+ le,
611
629
  {
612
630
  href: s,
613
- className: b,
631
+ className: g,
614
632
  "aria-label": n,
615
- title: p.title ?? n,
616
- "data-testid": u,
617
- ...l,
633
+ title: u.title ?? n,
634
+ "data-testid": l,
635
+ ...c,
618
636
  children: e
619
637
  }
620
638
  ) : /* @__PURE__ */ a(
621
639
  "button",
622
640
  {
623
- ref: m,
624
- type: i,
625
- className: b,
641
+ ref: b,
642
+ type: r,
643
+ className: g,
626
644
  "aria-label": n,
627
645
  title: n,
628
- "data-testid": u,
629
- ...p,
646
+ "data-testid": l,
647
+ ...u,
630
648
  children: e
631
649
  }
632
650
  );
633
651
  }
634
652
  );
635
- Aa.displayName = "IconButton";
636
- const ta = h(Aa), T = ({ children: e, ...n }) => /* @__PURE__ */ a(
653
+ Fa.displayName = "IconButton";
654
+ const ca = v(Fa), O = ({ children: e, ...n }) => /* @__PURE__ */ a(
637
655
  "svg",
638
656
  {
639
657
  xmlns: "http://www.w3.org/2000/svg",
@@ -646,497 +664,526 @@ const ta = h(Aa), T = ({ children: e, ...n }) => /* @__PURE__ */ a(
646
664
  ...n,
647
665
  children: e
648
666
  }
649
- ), la = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M1.293 1.293a1 1 0 0 1 1.414 0L8 6.586l5.293-5.293a1 1 0 1 1 1.414 1.414L9.414 8l5.293 5.293a1 1 0 0 1-1.414 1.414L8 9.414l-5.293 5.293a1 1 0 0 1-1.414-1.414L6.586 8 1.293 2.707a1 1 0 0 1 0-1.414" }) }), Ra = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M12.736 3.97a.733.733 0 0 1 1.047 0c.286.289.29.756.01 1.05L7.88 12.01a.733.733 0 0 1-1.065.02L3.217 8.384a.757.757 0 0 1 0-1.06.733.733 0 0 1 1.047 0l3.052 3.093 5.4-6.425z" }) }), fn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0" }) }), Ta = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a(
667
+ ), pa = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M1.293 1.293a1 1 0 0 1 1.414 0L8 6.586l5.293-5.293a1 1 0 1 1 1.414 1.414L9.414 8l5.293 5.293a1 1 0 0 1-1.414 1.414L8 9.414l-5.293 5.293a1 1 0 0 1-1.414-1.414L6.586 8 1.293 2.707a1 1 0 0 1 0-1.414" }) }), Pa = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M12.736 3.97a.733.733 0 0 1 1.047 0c.286.289.29.756.01 1.05L7.88 12.01a.733.733 0 0 1-1.065.02L3.217 8.384a.757.757 0 0 1 0-1.06.733.733 0 0 1 1.047 0l3.052 3.093 5.4-6.425z" }) }), kn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M13.854 3.646a.5.5 0 0 1 0 .708l-7 7a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L6.5 10.293l6.646-6.647a.5.5 0 0 1 .708 0" }) }), Oa = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a(
650
668
  "path",
651
669
  {
652
670
  fillRule: "evenodd",
653
671
  d: "M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708"
654
672
  }
655
- ) }), vn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a(
673
+ ) }), Nn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a(
656
674
  "path",
657
675
  {
658
676
  fillRule: "evenodd",
659
677
  d: "M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0"
660
678
  }
661
- ) }), Ba = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a(
679
+ ) }), Ha = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a(
662
680
  "path",
663
681
  {
664
682
  fillRule: "evenodd",
665
683
  d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708"
666
684
  }
667
- ) }), yn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a(
685
+ ) }), wn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a(
668
686
  "path",
669
687
  {
670
688
  fillRule: "evenodd",
671
689
  d: "M1 8a.5.5 0 0 1 .5-.5h11.793l-3.147-3.146a.5.5 0 0 1 .708-.708l4 4a.5.5 0 0 1 0 .708l-4 4a.5.5 0 0 1-.708-.708L13.293 8.5H1.5A.5.5 0 0 1 1 8"
672
690
  }
673
- ) }), xn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001q.44.31.98.85l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1 1 0 0 0-.85-.98zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0" }) }), kn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M8 2a.5.5 0 0 1 .5.5v5h5a.5.5 0 0 1 0 1h-5v5a.5.5 0 0 1-1 0v-5h-5a.5.5 0 0 1 0-1h5v-5A.5.5 0 0 1 8 2" }) }), Nn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M2 8a.5.5 0 0 1 .5-.5h11a.5.5 0 0 1 0 1h-11A.5.5 0 0 1 2 8" }) }), wn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a(
691
+ ) }), $n = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001q.44.31.98.85l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1 1 0 0 0-.85-.98zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0" }) }), Dn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M8 2a.5.5 0 0 1 .5.5v5h5a.5.5 0 0 1 0 1h-5v5a.5.5 0 0 1-1 0v-5h-5a.5.5 0 0 1 0-1h5v-5A.5.5 0 0 1 8 2" }) }), Ln = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M2 8a.5.5 0 0 1 .5-.5h11a.5.5 0 0 1 0 1h-11A.5.5 0 0 1 2 8" }) }), Cn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a(
674
692
  "path",
675
693
  {
676
694
  fillRule: "evenodd",
677
695
  d: "M4 2a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2zm2-1a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1zM2 5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1v-1h1v1a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h1v1z"
678
696
  }
679
- ) }), $n = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16m.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.287.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2" }) }), Dn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0m-3.97-3.03a.75.75 0 0 0-1.08.022L7.477 9.417 5.384 7.323a.75.75 0 0 0-1.06 1.06L6.97 11.03a.75.75 0 0 0 1.079-.02l3.992-4.99a.75.75 0 0 0-.01-1.05z" }) }), Sa = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M8.982 1.566a1.13 1.13 0 0 0-1.96 0L.165 13.233c-.457.778.091 1.767.98 1.767h13.713c.889 0 1.438-.99.98-1.767zM8 5c.535 0 .954.462.9.995l-.35 3.507a.552.552 0 0 1-1.1 0L7.1 5.995A.905.905 0 0 1 8 5m.002 6a1 1 0 1 1 0 2 1 1 0 0 1 0-2" }) }), Cn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0M5.354 4.646a.5.5 0 1 0-.708.708L7.293 8l-2.647 2.646a.5.5 0 0 0 .708.708L8 8.707l2.646 2.647a.5.5 0 0 0 .708-.708L8.707 8l2.647-2.646a.5.5 0 0 0-.708-.708L8 7.293z" }) }), Fa = (e) => /* @__PURE__ */ _(T, { ...e, children: [
697
+ ) }), In = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16m.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.287.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2" }) }), En = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0m-3.97-3.03a.75.75 0 0 0-1.08.022L7.477 9.417 5.384 7.323a.75.75 0 0 0-1.06 1.06L6.97 11.03a.75.75 0 0 0 1.079-.02l3.992-4.99a.75.75 0 0 0-.01-1.05z" }) }), za = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M8.982 1.566a1.13 1.13 0 0 0-1.96 0L.165 13.233c-.457.778.091 1.767.98 1.767h13.713c.889 0 1.438-.99.98-1.767zM8 5c.535 0 .954.462.9.995l-.35 3.507a.552.552 0 0 1-1.1 0L7.1 5.995A.905.905 0 0 1 8 5m.002 6a1 1 0 1 1 0 2 1 1 0 0 1 0-2" }) }), Mn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0M5.354 4.646a.5.5 0 1 0-.708.708L7.293 8l-2.647 2.646a.5.5 0 0 0 .708.708L8 8.707l2.646 2.647a.5.5 0 0 0 .708-.708L8.707 8l2.647-2.646a.5.5 0 0 0-.708-.708L8 7.293z" }) }), Ka = (e) => /* @__PURE__ */ _(O, { ...e, children: [
680
698
  /* @__PURE__ */ a("path", { d: "M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14m0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16" }),
681
699
  /* @__PURE__ */ a("path", { d: "M7.002 11a1 1 0 1 1 2 0 1 1 0 0 1-2 0M7.1 4.995a.905.905 0 1 1 1.8 0l-.35 3.507a.552.552 0 0 1-1.1 0z" })
682
- ] }), In = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0M5.496 6.033h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286a.237.237 0 0 0 .241.247m2.325 6.443c.61 0 1.029-.394 1.029-.927 0-.552-.42-.94-1.03-.94-.584 0-1.009.388-1.009.94 0 .533.425.927 1.01.927" }) }), Ln = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M2.5 1a1 1 0 0 0-1 1v1a1 1 0 0 0 1 1H3v9a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2V4h.5a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H10a1 1 0 0 0-1-1H7a1 1 0 0 0-1 1zm3 4a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 .5-.5M8 5a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7A.5.5 0 0 1 8 5m3 .5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 1 0" }) }), En = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M2.866 14.85c-.078.444.36.791.746.593l4.39-2.256 4.389 2.256c.386.198.824-.149.746-.592l-.83-4.73 3.522-3.356c.33-.314.16-.888-.282-.95l-4.898-.696L8.465.792a.513.513 0 0 0-.927 0L5.354 5.12l-4.898.696c-.441.062-.612.636-.283.95l3.523 3.356-.83 4.73zm4.905-2.767-3.686 1.894.694-3.957a.56.56 0 0 0-.163-.505L1.71 6.745l4.052-.576a.53.53 0 0 0 .393-.288L8 2.223l1.847 3.658a.53.53 0 0 0 .393.288l4.052.575-2.906 2.77a.56.56 0 0 0-.163.506l.694 3.957-3.686-1.894a.5.5 0 0 0-.461 0z" }) }), Oa = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M3.612 15.443c-.386.198-.824-.149-.746-.592l.83-4.73L.173 6.765c-.329-.314-.158-.888.283-.95l4.898-.696L7.538.792c.197-.39.73-.39.927 0l2.184 4.327 4.898.696c.441.062.612.636.283.95l-3.523 3.356.83 4.73c.078.443-.36.79-.746.592L8 13.187l-4.389 2.256z" }) }), Mn = (e) => /* @__PURE__ */ a(T, { ...e, children: /* @__PURE__ */ a("path", { d: "M5.354 5.119 7.538.792A.52.52 0 0 1 8 .5c.183 0 .366.097.465.292l2.184 4.327 4.898.696A.54.54 0 0 1 16 6.32a.55.55 0 0 1-.17.445l-3.523 3.356.83 4.73c.078.443-.36.79-.746.592L8 13.187l-4.389 2.256a.5.5 0 0 1-.146.05c-.342.06-.668-.254-.6-.642l.83-4.73L.173 6.765a.55.55 0 0 1-.171-.443.5.5 0 0 1 .084-.302.5.5 0 0 1 .37-.245zM8 12.027a.5.5 0 0 1 .232.056l3.686 1.894-.694-3.957a.56.56 0 0 1 .162-.505l2.907-2.77-4.052-.576a.53.53 0 0 1-.393-.288L8.001 2.223 8 2.226z" }) }), An = "hanui-link-WBmXY", Rn = "hanui-link__label--OEu-", Tn = "hanui-link__arrow-JKXm-", Ke = {
683
- link: An,
684
- link__label: Rn,
685
- link__arrow: Tn,
700
+ ] }), Tn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0M5.496 6.033h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286a.237.237 0 0 0 .241.247m2.325 6.443c.61 0 1.029-.394 1.029-.927 0-.552-.42-.94-1.03-.94-.584 0-1.009.388-1.009.94 0 .533.425.927 1.01.927" }) }), Rn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M2.5 1a1 1 0 0 0-1 1v1a1 1 0 0 0 1 1H3v9a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2V4h.5a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H10a1 1 0 0 0-1-1H7a1 1 0 0 0-1 1zm3 4a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 .5-.5M8 5a.5.5 0 0 1 .5.5v7a.5.5 0 0 1-1 0v-7A.5.5 0 0 1 8 5m3 .5v7a.5.5 0 0 1-1 0v-7a.5.5 0 0 1 1 0" }) }), An = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M2.866 14.85c-.078.444.36.791.746.593l4.39-2.256 4.389 2.256c.386.198.824-.149.746-.592l-.83-4.73 3.522-3.356c.33-.314.16-.888-.282-.95l-4.898-.696L8.465.792a.513.513 0 0 0-.927 0L5.354 5.12l-4.898.696c-.441.062-.612.636-.283.95l3.523 3.356-.83 4.73zm4.905-2.767-3.686 1.894.694-3.957a.56.56 0 0 0-.163-.505L1.71 6.745l4.052-.576a.53.53 0 0 0 .393-.288L8 2.223l1.847 3.658a.53.53 0 0 0 .393.288l4.052.575-2.906 2.77a.56.56 0 0 0-.163.506l.694 3.957-3.686-1.894a.5.5 0 0 0-.461 0z" }) }), qa = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M3.612 15.443c-.386.198-.824-.149-.746-.592l.83-4.73L.173 6.765c-.329-.314-.158-.888.283-.95l4.898-.696L7.538.792c.197-.39.73-.39.927 0l2.184 4.327 4.898.696c.441.062.612.636.283.95l-3.523 3.356.83 4.73c.078.443-.36.79-.746.592L8 13.187l-4.389 2.256z" }) }), Bn = (e) => /* @__PURE__ */ a(O, { ...e, children: /* @__PURE__ */ a("path", { d: "M5.354 5.119 7.538.792A.52.52 0 0 1 8 .5c.183 0 .366.097.465.292l2.184 4.327 4.898.696A.54.54 0 0 1 16 6.32a.55.55 0 0 1-.17.445l-3.523 3.356.83 4.73c.078.443-.36.79-.746.592L8 13.187l-4.389 2.256a.5.5 0 0 1-.146.05c-.342.06-.668-.254-.6-.642l.83-4.73L.173 6.765a.55.55 0 0 1-.171-.443.5.5 0 0 1 .084-.302.5.5 0 0 1 .37-.245zM8 12.027a.5.5 0 0 1 .232.056l3.686 1.894-.694-3.957a.56.56 0 0 1 .162-.505l2.907-2.77-4.052-.576a.53.53 0 0 1-.393-.288L8.001 2.223 8 2.226z" }) }), Sn = "hanui-link-WBmXY", Fn = "hanui-link__label--OEu-", Pn = "hanui-link__arrow-JKXm-", Xe = {
701
+ link: Sn,
702
+ link__label: Fn,
703
+ link__arrow: Pn,
686
704
  "link--sm": "hanui-link--sm-a-3Dz",
687
705
  "link--md": "hanui-link--md-lZdYP",
688
706
  "link--brand": "hanui-link--brand-vr8sW",
689
707
  "link--muted": "hanui-link--muted-EeN6l"
690
- }, Bn = ({
708
+ }, On = ({
691
709
  href: e,
692
710
  children: n,
693
711
  hasArrow: t,
694
712
  tone: o = "brand",
695
- size: r = "md",
696
- className: i,
713
+ size: i = "md",
714
+ className: r,
697
715
  linkProps: s,
698
- ...l
716
+ ...c
699
717
  }) => /* @__PURE__ */ _(
700
- oe,
718
+ le,
701
719
  {
702
720
  href: e,
703
- className: d(Ke.link, Ke[`link--${o}`], Ke[`link--${r}`], i),
721
+ className: d(Xe.link, Xe[`link--${o}`], Xe[`link--${i}`], r),
704
722
  ...s,
705
- ...l,
723
+ ...c,
706
724
  children: [
707
- /* @__PURE__ */ a("span", { className: Ke.link__label, children: n }),
708
- t && /* @__PURE__ */ a(yn, { className: Ke.link__arrow })
725
+ /* @__PURE__ */ a("span", { className: Xe.link__label, children: n }),
726
+ t && /* @__PURE__ */ a(wn, { className: Xe.link__arrow })
709
727
  ]
710
728
  }
711
- ), js = h(Bn), Sn = "hanui-tooltip-RG1g1", Fn = "hanui-tooltip__trigger-nWZtO", On = "hanui-bubble-bcBNk", Qe = {
712
- tooltip: Sn,
713
- tooltip__trigger: Fn,
714
- bubble: On,
729
+ ), Ys = v(On), Hn = "hanui-tooltip-RG1g1", zn = "hanui-tooltip__trigger-nWZtO", Kn = "hanui-bubble-bcBNk", ta = {
730
+ tooltip: Hn,
731
+ tooltip__trigger: zn,
732
+ bubble: Kn,
715
733
  "hanui-fade-in-up": "hanui-hanui-fade-in-up-Fwj3A",
716
734
  "bubble--top": "hanui-bubble--top-uWSZy",
717
735
  "bubble--bottom": "hanui-bubble--bottom-jKokL"
718
- }, Hn = ({ content: e, children: n, position: t = "top", className: o }) => {
719
- const [r, i] = G(!1), s = te();
736
+ }, qn = ({ content: e, children: n, position: t = "top", className: o }) => {
737
+ const [i, r] = Z(!1), s = ce();
720
738
  return /* @__PURE__ */ _(
721
739
  "span",
722
740
  {
723
- className: d(Qe.tooltip, o),
724
- onMouseEnter: () => i(!0),
725
- onMouseLeave: () => i(!1),
726
- onFocus: () => i(!0),
727
- onBlur: () => i(!1),
728
- onKeyDown: (l) => {
729
- l.key === "Escape" && i(!1);
741
+ className: d(ta.tooltip, o),
742
+ onMouseEnter: () => r(!0),
743
+ onMouseLeave: () => r(!1),
744
+ onFocus: () => r(!0),
745
+ onBlur: () => r(!1),
746
+ onKeyDown: (c) => {
747
+ c.key === "Escape" && r(!1);
730
748
  },
731
749
  children: [
732
- /* @__PURE__ */ a("span", { "aria-describedby": r ? s : void 0, className: Qe.tooltip__trigger, children: n }),
733
- r && /* @__PURE__ */ a("span", { id: s, role: "tooltip", className: d(Qe.bubble, Qe[`bubble--${t}`]), children: e })
750
+ /* @__PURE__ */ a("span", { "aria-describedby": i ? s : void 0, className: ta.tooltip__trigger, children: n }),
751
+ i && /* @__PURE__ */ a("span", { id: s, role: "tooltip", className: d(ta.bubble, ta[`bubble--${t}`]), children: e })
734
752
  ]
735
753
  }
736
754
  );
737
- }, Gs = h(Hn), Pn = "hanui-chip--NLgU", zn = "hanui-chip__icon-IjjSb", Kn = "hanui-chip__label-cT4hw", jn = "hanui-chip__count-MBGO3", be = {
738
- chip: Pn,
739
- chip__icon: zn,
740
- chip__label: Kn,
741
- chip__count: jn,
755
+ }, Zs = v(qn), jn = "hanui-chip--NLgU", Gn = "hanui-chip__icon-IjjSb", Un = "hanui-chip__label-cT4hw", Xn = "hanui-chip__count-MBGO3", ye = {
756
+ chip: jn,
757
+ chip__icon: Gn,
758
+ chip__label: Un,
759
+ chip__count: Xn,
742
760
  "chip--sm": "hanui-chip--sm-60H-S",
743
761
  "chip--md": "hanui-chip--md--yAlm",
744
762
  "chip--iconOnly": "hanui-chip--iconOnly-5LT1h",
745
763
  "chip--selected": "hanui-chip--selected-FdpCr"
746
- }, Ha = ge(
764
+ }, ja = xe(
747
765
  ({
748
766
  children: e,
749
767
  icon: n,
750
768
  endIcon: t,
751
769
  count: o,
752
- isSelected: r,
753
- size: i = "md",
770
+ isSelected: i,
771
+ size: r = "md",
754
772
  label: s,
755
- href: l,
756
- linkProps: u,
757
- className: p,
758
- type: m = "button",
759
- role: b,
760
- testId: c,
761
- ...v
762
- }, f) => {
763
- const C = d(
764
- be.chip,
765
- be[`chip--${i}`],
766
- r && be["chip--selected"],
767
- !e && be["chip--iconOnly"],
768
- p
769
- ), D = /* @__PURE__ */ _(Je, { children: [
770
- n && /* @__PURE__ */ a("span", { className: be.chip__icon, "aria-hidden": !0, children: n }),
771
- e && /* @__PURE__ */ a("span", { className: be.chip__label, children: e }),
772
- Pe(o) && /* @__PURE__ */ a("span", { className: be.chip__count, children: o }),
773
- t && /* @__PURE__ */ a("span", { className: be.chip__icon, "aria-hidden": !0, children: t })
773
+ href: c,
774
+ linkProps: l,
775
+ className: u,
776
+ type: b = "button",
777
+ role: g,
778
+ testId: h,
779
+ ...p
780
+ }, N) => {
781
+ const m = d(
782
+ ye.chip,
783
+ ye[`chip--${r}`],
784
+ i && ye["chip--selected"],
785
+ !e && ye["chip--iconOnly"],
786
+ u
787
+ ), f = /* @__PURE__ */ _(aa, { children: [
788
+ n && /* @__PURE__ */ a("span", { className: ye.chip__icon, "aria-hidden": !0, children: n }),
789
+ e && /* @__PURE__ */ a("span", { className: ye.chip__label, children: e }),
790
+ Ge(o) && /* @__PURE__ */ a("span", { className: ye.chip__count, children: o }),
791
+ t && /* @__PURE__ */ a("span", { className: ye.chip__icon, "aria-hidden": !0, children: t })
774
792
  ] });
775
- return l ? /* @__PURE__ */ a(
776
- oe,
793
+ return c ? /* @__PURE__ */ a(
794
+ le,
777
795
  {
778
- href: l,
779
- className: C,
796
+ href: c,
797
+ className: m,
780
798
  "aria-label": e ? void 0 : s,
781
- "aria-current": r ? "page" : void 0,
799
+ "aria-current": i ? "page" : void 0,
782
800
  title: e ? void 0 : s,
783
- "data-testid": c,
784
- ...u,
785
- children: D
801
+ "data-testid": h,
802
+ ...l,
803
+ children: f
786
804
  }
787
805
  ) : /* @__PURE__ */ a(
788
806
  "button",
789
807
  {
790
- ref: f,
791
- type: m,
792
- role: b,
793
- className: C,
808
+ ref: N,
809
+ type: b,
810
+ role: g,
811
+ className: m,
794
812
  "aria-label": e ? void 0 : s,
795
813
  title: e ? void 0 : s,
796
- "data-testid": c,
797
- ...b === "radio" ? { "aria-checked": !!r } : { "aria-pressed": !!r },
798
- ...v,
799
- children: D
814
+ "data-testid": h,
815
+ ...g === "radio" ? { "aria-checked": !!i } : { "aria-pressed": !!i },
816
+ ...p,
817
+ children: f
800
818
  }
801
819
  );
802
820
  }
803
821
  );
804
- Ha.displayName = "Chip";
805
- const Gn = h(Ha), Un = "hanui-group-0tnVf", ya = {
806
- group: Un,
822
+ ja.displayName = "Chip";
823
+ const Yn = v(ja), Zn = "hanui-group-0tnVf", Da = {
824
+ group: Zn,
807
825
  "group--scrollable": "hanui-group--scrollable-PMu6V"
808
- }, qn = ({
826
+ }, Jn = ({
809
827
  options: e,
810
828
  label: n,
811
829
  size: t = "md",
812
830
  isScrollable: o,
813
- className: r,
814
- ...i
831
+ className: i,
832
+ ...r
815
833
  }) => {
816
- var b;
817
- const s = Y(null), l = (c) => i.isMultiple ? i.value.includes(c) : i.value === c, u = (c) => {
818
- if (i.isMultiple) {
819
- const v = i.value.includes(c) ? i.value.filter((f) => f !== c) : [...i.value, c];
820
- i.onChange(v);
834
+ var g;
835
+ const s = Y(null), c = (h) => r.isMultiple ? r.value.includes(h) : r.value === h, l = (h) => {
836
+ if (r.isMultiple) {
837
+ const p = r.value.includes(h) ? r.value.filter((N) => N !== h) : [...r.value, h];
838
+ r.onChange(p);
821
839
  return;
822
840
  }
823
- i.onChange(i.value === c ? null : c);
824
- }, p = (c) => {
825
- var $, N;
826
- if (i.isMultiple) return;
827
- const v = c.key === "ArrowRight" || c.key === "ArrowDown" ? 1 : c.key === "ArrowLeft" || c.key === "ArrowUp" ? -1 : 0;
828
- if (v === 0) return;
829
- c.preventDefault();
830
- const f = e.filter((E) => !E.isDisabled);
831
- if (f.length === 0) return;
832
- const C = f.findIndex((E) => E.value === i.value), D = f[(C + v + f.length) % f.length];
833
- i.onChange(D.value), (N = ($ = s.current) == null ? void 0 : $.querySelector(`[data-chip-value="${D.value}"]`)) == null || N.focus();
834
- }, m = i.isMultiple ? null : i.value ?? ((b = e.find((c) => !c.isDisabled)) == null ? void 0 : b.value) ?? null;
841
+ r.onChange(r.value === h ? null : h);
842
+ }, u = (h) => {
843
+ var D, x;
844
+ if (r.isMultiple) return;
845
+ const p = h.key === "ArrowRight" || h.key === "ArrowDown" ? 1 : h.key === "ArrowLeft" || h.key === "ArrowUp" ? -1 : 0;
846
+ if (p === 0) return;
847
+ h.preventDefault();
848
+ const N = e.filter((L) => !L.isDisabled);
849
+ if (N.length === 0) return;
850
+ const m = N.findIndex((L) => L.value === r.value), f = N[(m + p + N.length) % N.length];
851
+ r.onChange(f.value), (x = (D = s.current) == null ? void 0 : D.querySelector(`[data-chip-value="${f.value}"]`)) == null || x.focus();
852
+ }, b = r.isMultiple ? null : r.value ?? ((g = e.find((h) => !h.isDisabled)) == null ? void 0 : g.value) ?? null;
835
853
  return /* @__PURE__ */ a(
836
854
  "div",
837
855
  {
838
856
  ref: s,
839
- className: d(ya.group, o && ya["group--scrollable"], r),
840
- role: i.isMultiple ? "group" : "radiogroup",
857
+ className: d(Da.group, o && Da["group--scrollable"], i),
858
+ role: r.isMultiple ? "group" : "radiogroup",
841
859
  "aria-label": n,
842
- onKeyDown: p,
843
- children: e.map((c) => /* @__PURE__ */ a(
844
- Gn,
860
+ onKeyDown: u,
861
+ children: e.map((h) => /* @__PURE__ */ a(
862
+ Yn,
845
863
  {
846
864
  size: t,
847
- icon: c.icon,
848
- count: c.count,
849
- isSelected: l(c.value),
850
- disabled: c.isDisabled,
851
- role: i.isMultiple ? void 0 : "radio",
852
- tabIndex: i.isMultiple || c.value === m ? 0 : -1,
853
- "data-chip-value": c.value,
854
- onClick: () => u(c.value),
855
- children: c.label
865
+ icon: h.icon,
866
+ count: h.count,
867
+ isSelected: c(h.value),
868
+ disabled: h.isDisabled,
869
+ role: r.isMultiple ? void 0 : "radio",
870
+ tabIndex: r.isMultiple || h.value === b ? 0 : -1,
871
+ "data-chip-value": h.value,
872
+ onClick: () => l(h.value),
873
+ children: h.label
856
874
  },
857
- c.value
875
+ h.value
858
876
  ))
859
877
  }
860
878
  );
861
- }, Us = h(qn), Xn = "hanui-sheet-GEvdE", Yn = "hanui-sheet__header-NJgw-", Zn = "hanui-sheet__title-f-b07", Jn = "hanui-sheet__toolbar-eyhmW", Vn = "hanui-sheet__body-eJ2KB", Qn = "hanui-sheet__footer-NpsY5", Ae = {
862
- sheet: Xn,
863
- sheet__header: Yn,
864
- sheet__title: Zn,
865
- sheet__toolbar: Jn,
866
- sheet__body: Vn,
867
- sheet__footer: Qn
868
- }, Wn = ({
879
+ }, Js = v(Jn), Qn = "hanui-sheet-GEvdE", Vn = "hanui-sheet__header-NJgw-", Wn = "hanui-sheet__title-f-b07", et = "hanui-sheet__toolbar-eyhmW", at = "hanui-sheet__body-eJ2KB", nt = "hanui-sheet__footer-NpsY5", Se = {
880
+ sheet: Qn,
881
+ sheet__header: Vn,
882
+ sheet__title: Wn,
883
+ sheet__toolbar: et,
884
+ sheet__body: at,
885
+ sheet__footer: nt
886
+ }, tt = ({
869
887
  title: e,
870
888
  closeLabel: n,
871
889
  onClose: t,
872
890
  children: o,
873
- toolbar: r,
874
- footer: i,
875
- closeAbove: s = ca,
876
- className: l,
877
- testId: u
891
+ toolbar: i,
892
+ footer: r,
893
+ closeAbove: s = ha,
894
+ className: c,
895
+ testId: l
878
896
  }) => {
879
- const p = te();
880
- on(), R(() => {
881
- const c = document.body.style.overflow;
897
+ const { labels: u } = P(), b = ce();
898
+ ln(), F(() => {
899
+ const p = document.body.style.overflow;
882
900
  return document.body.style.overflow = "hidden", () => {
883
- document.body.style.overflow = c;
901
+ document.body.style.overflow = p;
884
902
  };
885
- }, []), R(() => {
886
- const c = window.matchMedia(s);
887
- return c.addEventListener("change", t), () => c.removeEventListener("change", t);
903
+ }, []), F(() => {
904
+ const p = window.matchMedia(s);
905
+ return p.addEventListener("change", t), () => p.removeEventListener("change", t);
888
906
  }, [s, t]);
889
- const m = Z((c) => {
890
- !c || c.open || (c.showModal(), La(c));
891
- }, []), b = Z(
892
- (c) => {
893
- c.target === c.currentTarget && t();
907
+ const g = Q((p) => {
908
+ !p || p.open || (p.showModal(), Aa(p));
909
+ }, []), h = Q(
910
+ (p) => {
911
+ p.target === p.currentTarget && t();
894
912
  },
895
913
  [t]
896
914
  );
897
- return Ce() ? Qa(
915
+ return Me() ? tn(
898
916
  /* @__PURE__ */ _(
899
917
  "dialog",
900
918
  {
901
- ref: m,
902
- className: d(Ae.sheet, l),
903
- "aria-labelledby": p,
904
- "data-testid": u,
905
- onCancel: (c) => {
906
- c.preventDefault(), t();
919
+ ref: g,
920
+ className: d(Se.sheet, c),
921
+ "aria-labelledby": b,
922
+ "data-testid": l,
923
+ onCancel: (p) => {
924
+ p.preventDefault(), t();
907
925
  },
908
- onClick: b,
926
+ onClick: h,
909
927
  children: [
910
- /* @__PURE__ */ _("header", { className: Ae.sheet__header, children: [
911
- /* @__PURE__ */ a("h2", { id: p, className: Ae.sheet__title, children: e }),
928
+ /* @__PURE__ */ _("header", { className: Se.sheet__header, children: [
929
+ /* @__PURE__ */ a("h2", { id: b, className: Se.sheet__title, children: e }),
912
930
  /* @__PURE__ */ a(
913
- ta,
931
+ ca,
914
932
  {
915
- icon: /* @__PURE__ */ a(la, {}),
916
- label: n,
933
+ icon: /* @__PURE__ */ a(pa, {}),
934
+ label: I("BottomSheet.closeLabel", n, u == null ? void 0 : u.close),
917
935
  variant: "ghost",
918
936
  size: "sm",
919
937
  onClick: t
920
938
  }
921
939
  )
922
940
  ] }),
923
- r && /* @__PURE__ */ a("div", { className: Ae.sheet__toolbar, children: r }),
924
- /* @__PURE__ */ a("div", { className: Ae.sheet__body, children: o }),
925
- i && /* @__PURE__ */ a("div", { className: Ae.sheet__footer, children: i })
941
+ i && /* @__PURE__ */ a("div", { className: Se.sheet__toolbar, children: i }),
942
+ /* @__PURE__ */ a("div", { className: Se.sheet__body, children: o }),
943
+ r && /* @__PURE__ */ a("div", { className: Se.sheet__footer, children: r })
926
944
  ]
927
945
  }
928
946
  ),
929
947
  document.body
930
948
  ) : null;
931
- }, Pa = h(Wn), et = "hanui-combobox-NtZoV", at = "hanui-combobox__trigger-2riRR", nt = "hanui-combobox__leadingIcon-it2xz", tt = "hanui-combobox__value-acDlr", ot = "hanui-combobox__clear-EXOsc", it = "hanui-combobox__chevron-g-QzQ", rt = "hanui-combobox__panel-srBxl", st = "hanui-combobox__search-THjer", ct = "hanui-combobox__searchIcon-vr4Bg", lt = "hanui-combobox__searchInput-JPp5h", dt = "hanui-combobox__list-p-eCs", _t = "hanui-combobox__option-CLWh-", ut = "hanui-combobox__optionText-Zm0D6", ht = "hanui-combobox__optionLabel-WvT4W", pt = "hanui-combobox__optionDescription-8OEzi", bt = "hanui-combobox__check-MKlLz", mt = "hanui-combobox__empty-mZwBq", M = {
932
- combobox: et,
933
- combobox__trigger: at,
949
+ }, Ga = v(tt), ot = "hanui-combobox-NtZoV", rt = "hanui-combobox__trigger-2riRR", it = "hanui-combobox__leadingIcon-it2xz", st = "hanui-combobox__value-acDlr", ct = "hanui-combobox__clear-EXOsc", lt = "hanui-combobox__chevron-g-QzQ", dt = "hanui-combobox__panel-srBxl", _t = "hanui-combobox__search-THjer", ut = "hanui-combobox__searchIcon-vr4Bg", ht = "hanui-combobox__searchInput-JPp5h", pt = "hanui-combobox__list-p-eCs", bt = "hanui-combobox__option-CLWh-", mt = "hanui-combobox__optionText-Zm0D6", gt = "hanui-combobox__optionLabel-WvT4W", ft = "hanui-combobox__optionDescription-8OEzi", yt = "hanui-combobox__check-MKlLz", vt = "hanui-combobox__empty-mZwBq", R = {
950
+ combobox: ot,
951
+ combobox__trigger: rt,
934
952
  "combobox__trigger--empty": "hanui-combobox__trigger--empty-RxwCq",
935
953
  "combobox__trigger--open": "hanui-combobox__trigger--open-rw1ZS",
936
954
  "combobox__trigger--invalid": "hanui-combobox__trigger--invalid-iZgiN",
937
- combobox__leadingIcon: nt,
938
- combobox__value: tt,
939
- combobox__clear: ot,
940
- combobox__chevron: it,
955
+ combobox__leadingIcon: it,
956
+ combobox__value: st,
957
+ combobox__clear: ct,
958
+ combobox__chevron: lt,
941
959
  "combobox__chevron--open": "hanui-combobox__chevron--open-9kj1j",
942
- combobox__panel: rt,
943
- combobox__search: st,
944
- combobox__searchIcon: ct,
945
- combobox__searchInput: lt,
946
- combobox__list: dt,
960
+ combobox__panel: dt,
961
+ combobox__search: _t,
962
+ combobox__searchIcon: ut,
963
+ combobox__searchInput: ht,
964
+ combobox__list: pt,
947
965
  "combobox__list--sheet": "hanui-combobox__list--sheet-r3MzB",
948
- combobox__option: _t,
966
+ combobox__option: bt,
949
967
  "combobox__option--active": "hanui-combobox__option--active--75Vq",
950
968
  "combobox__option--selected": "hanui-combobox__option--selected-DVFGy",
951
969
  "combobox__option--disabled": "hanui-combobox__option--disabled-e6VjI",
952
- combobox__optionText: ut,
953
- combobox__optionLabel: ht,
954
- combobox__optionDescription: pt,
955
- combobox__check: bt,
956
- combobox__empty: mt
957
- }, gt = ({
970
+ combobox__optionText: mt,
971
+ combobox__optionLabel: gt,
972
+ combobox__optionDescription: ft,
973
+ combobox__check: yt,
974
+ combobox__empty: vt
975
+ }, xt = ({
958
976
  options: e,
959
977
  value: n,
960
978
  onChange: t,
961
979
  labels: o,
962
- isSearchHidden: r,
963
- onSearch: i,
980
+ isSearchHidden: i,
981
+ onSearch: r,
964
982
  isLoading: s,
965
- isDisabled: l,
966
- isClearable: u,
967
- icon: p,
968
- id: m,
969
- className: b,
970
- testId: c,
971
- "aria-describedby": v,
972
- "aria-invalid": f
983
+ isDisabled: c,
984
+ isClearable: l,
985
+ icon: u,
986
+ id: b,
987
+ className: g,
988
+ testId: h,
989
+ "aria-describedby": p,
990
+ "aria-invalid": N
973
991
  }) => {
974
- const C = te(), D = m ?? C, $ = `${D}-listbox`, N = Y(null), E = Y(null), U = Y(null), q = Y(null), [I, he] = G(null), A = I !== null, [z, O] = G(""), [H, K] = G(0), [ie, fe] = G(null), re = aa(() => {
975
- if (i || z.trim() === "") return e;
976
- const y = z.trim();
992
+ const { labels: m } = P(), f = {
993
+ get search() {
994
+ var y;
995
+ return I(
996
+ "Combobox.searchPlaceholder",
997
+ o.searchPlaceholder,
998
+ (y = m == null ? void 0 : m.combobox) == null ? void 0 : y.searchPlaceholder
999
+ );
1000
+ },
1001
+ get empty() {
1002
+ var y;
1003
+ return I(
1004
+ "Combobox.emptyMessage",
1005
+ o.emptyMessage,
1006
+ (y = m == null ? void 0 : m.combobox) == null ? void 0 : y.emptyMessage
1007
+ );
1008
+ },
1009
+ get loading() {
1010
+ var y;
1011
+ return I(
1012
+ "Combobox.loadingMessage",
1013
+ o.loadingMessage,
1014
+ (y = m == null ? void 0 : m.combobox) == null ? void 0 : y.loadingMessage
1015
+ );
1016
+ },
1017
+ get clear() {
1018
+ var y;
1019
+ return I("Combobox.clearLabel", o.clearLabel, (y = m == null ? void 0 : m.combobox) == null ? void 0 : y.clearLabel);
1020
+ }
1021
+ }, D = ce(), x = b ?? D, L = `${x}-listbox`, E = Y(null), S = Y(null), j = Y(null), te = Y(null), [B, oe] = Z(null), M = B !== null, [A, H] = Z(""), [U, ee] = Z(0), [de, ke] = Z(null), _e = ia(() => {
1022
+ if (r || A.trim() === "") return e;
1023
+ const y = A.trim();
977
1024
  return e.filter(
978
- (L) => va(L.label, y) || (L.description ? va(L.description, y) : !1)
1025
+ (T) => wa(T.label, y) || (T.description ? wa(T.description, y) : !1)
979
1026
  );
980
- }, [e, z, i]), se = e.find((y) => y.value === n) ?? null;
981
- R(() => {
982
- se ? fe(se.label) : n === null && fe(null);
983
- }, [se, n]);
984
- const Le = (se == null ? void 0 : se.label) ?? ie, pe = Y(i);
985
- pe.current = i, R(() => {
986
- if (!A || !pe.current) return;
1027
+ }, [e, A, r]), ue = e.find((y) => y.value === n) ?? null;
1028
+ F(() => {
1029
+ ue ? ke(ue.label) : n === null && ke(null);
1030
+ }, [ue, n]);
1031
+ const Re = (ue == null ? void 0 : ue.label) ?? de, fe = Y(r);
1032
+ fe.current = r, F(() => {
1033
+ if (!M || !fe.current) return;
987
1034
  const y = window.setTimeout(() => {
988
- var L;
989
- return (L = pe.current) == null ? void 0 : L.call(pe, z.trim());
1035
+ var T;
1036
+ return (T = fe.current) == null ? void 0 : T.call(fe, A.trim());
990
1037
  }, 300);
991
1038
  return () => window.clearTimeout(y);
992
- }, [z, A]);
993
- const k = Z(() => {
994
- he(null), O("");
995
- }, []), P = Z(() => {
996
- if (l) return;
997
- he(window.matchMedia(ca).matches ? "popover" : "sheet"), O("");
998
- const y = e.findIndex((L) => L.value === n);
999
- K(y >= 0 ? y : 0);
1000
- }, [l, e, n]);
1001
- R(() => {
1002
- if (I !== "popover") return;
1003
- const y = (L) => {
1004
- var j;
1005
- (j = N.current) != null && j.contains(L.target) || k();
1039
+ }, [A, M]);
1040
+ const $ = Q(() => {
1041
+ oe(null), H("");
1042
+ }, []), G = Q(() => {
1043
+ if (c) return;
1044
+ oe(window.matchMedia(ha).matches ? "popover" : "sheet"), H("");
1045
+ const y = e.findIndex((T) => T.value === n);
1046
+ ee(y >= 0 ? y : 0);
1047
+ }, [c, e, n]);
1048
+ F(() => {
1049
+ if (B !== "popover") return;
1050
+ const y = (T) => {
1051
+ var X;
1052
+ (X = E.current) != null && X.contains(T.target) || $();
1006
1053
  };
1007
1054
  return document.addEventListener("mousedown", y), () => document.removeEventListener("mousedown", y);
1008
- }, [I, k]), R(() => {
1055
+ }, [B, $]), F(() => {
1009
1056
  var y;
1010
- I === "popover" && ((y = U.current) == null || y.focus({ preventScroll: !0 }));
1011
- }, [I]), R(() => {
1012
- var y, L;
1013
- A && ((L = (y = q.current) == null ? void 0 : y.querySelector(`[data-index="${H}"]`)) == null || L.scrollIntoView({ block: "nearest" }));
1014
- }, [H, A, re.length]);
1015
- const S = (y) => {
1016
- y.isDisabled || (fe(y.label), t(y.value), k());
1017
- }, Ee = Y(!1);
1018
- R(() => {
1057
+ B === "popover" && ((y = j.current) == null || y.focus({ preventScroll: !0 }));
1058
+ }, [B]), F(() => {
1059
+ var y, T;
1060
+ M && ((T = (y = te.current) == null ? void 0 : y.querySelector(`[data-index="${U}"]`)) == null || T.scrollIntoView({ block: "nearest" }));
1061
+ }, [U, M, _e.length]);
1062
+ const K = (y) => {
1063
+ y.isDisabled || (ke(y.label), t(y.value), $());
1064
+ }, Ae = Y(!1);
1065
+ F(() => {
1019
1066
  var y;
1020
- Ee.current && !A && ((y = E.current) == null || y.focus()), Ee.current = A;
1021
- }, [A]);
1022
- const Xa = (y) => {
1023
- const L = re.length - 1;
1067
+ Ae.current && !M && ((y = S.current) == null || y.focus()), Ae.current = M;
1068
+ }, [M]);
1069
+ const Va = (y) => {
1070
+ const T = _e.length - 1;
1024
1071
  switch (y.key) {
1025
1072
  case "ArrowDown":
1026
- y.preventDefault(), K((j) => j >= L ? 0 : j + 1);
1073
+ y.preventDefault(), ee((X) => X >= T ? 0 : X + 1);
1027
1074
  break;
1028
1075
  case "ArrowUp":
1029
- y.preventDefault(), K((j) => j <= 0 ? L : j - 1);
1076
+ y.preventDefault(), ee((X) => X <= 0 ? T : X - 1);
1030
1077
  break;
1031
1078
  case "Home":
1032
- y.preventDefault(), K(0);
1079
+ y.preventDefault(), ee(0);
1033
1080
  break;
1034
1081
  case "End":
1035
- y.preventDefault(), K(L);
1082
+ y.preventDefault(), ee(T);
1036
1083
  break;
1037
1084
  case "Enter": {
1038
1085
  y.preventDefault();
1039
- const j = re[H];
1040
- j && S(j);
1086
+ const X = _e[U];
1087
+ X && K(X);
1041
1088
  break;
1042
1089
  }
1043
1090
  case "Escape":
1044
- y.preventDefault(), k();
1091
+ y.preventDefault(), $();
1045
1092
  break;
1046
1093
  case "Tab":
1047
- k();
1094
+ $();
1048
1095
  break;
1049
1096
  }
1050
- }, da = () => {
1051
- t(null), fe(null);
1052
- }, _a = r ? null : /* @__PURE__ */ _("div", { className: M.combobox__search, children: [
1053
- /* @__PURE__ */ a(xn, { className: M.combobox__searchIcon }),
1097
+ }, ba = () => {
1098
+ t(null), ke(null);
1099
+ }, ma = i ? null : /* @__PURE__ */ _("div", { className: R.combobox__search, children: [
1100
+ /* @__PURE__ */ a($n, { className: R.combobox__searchIcon }),
1054
1101
  /* @__PURE__ */ a(
1055
1102
  "input",
1056
1103
  {
1057
- ref: U,
1104
+ ref: j,
1058
1105
  type: "text",
1059
1106
  role: "combobox",
1060
- className: M.combobox__searchInput,
1061
- value: z,
1062
- placeholder: o.searchPlaceholder,
1107
+ className: R.combobox__searchInput,
1108
+ value: A,
1109
+ placeholder: f.search,
1063
1110
  autoComplete: "off",
1064
1111
  "aria-autocomplete": "list",
1065
1112
  "aria-expanded": !0,
1066
- "aria-controls": $,
1067
- "aria-activedescendant": re[H] ? `${D}-option-${H}` : void 0,
1068
- "aria-label": o.searchPlaceholder,
1113
+ "aria-controls": L,
1114
+ "aria-activedescendant": _e[U] ? `${x}-option-${U}` : void 0,
1115
+ "aria-label": f.search,
1069
1116
  onChange: (y) => {
1070
- O(y.target.value), K(0);
1117
+ H(y.target.value), ee(0);
1071
1118
  },
1072
- onKeyDown: Xa
1119
+ onKeyDown: Va
1073
1120
  }
1074
1121
  ),
1075
- s && /* @__PURE__ */ a(Ea, { size: "sm", label: "" })
1076
- ] }), ua = (y) => /* @__PURE__ */ _(
1122
+ s && /* @__PURE__ */ a(Ba, { size: "sm", label: "" })
1123
+ ] }), ga = (y) => /* @__PURE__ */ _(
1077
1124
  "ul",
1078
1125
  {
1079
- ref: q,
1080
- id: $,
1126
+ ref: te,
1127
+ id: L,
1081
1128
  role: "listbox",
1082
- className: d(M.combobox__list, y && M["combobox__list--sheet"]),
1129
+ className: d(R.combobox__list, y && R["combobox__list--sheet"]),
1083
1130
  children: [
1084
- re.map((L, j) => {
1085
- const Ya = j === H, oa = L.value === n;
1131
+ _e.map((T, X) => {
1132
+ const Wa = X === U, la = T.value === n;
1086
1133
  return /* @__PURE__ */ a("li", { children: /* @__PURE__ */ _(
1087
1134
  "div",
1088
1135
  {
1089
- id: `${D}-option-${j}`,
1136
+ id: `${x}-option-${X}`,
1090
1137
  role: "option",
1091
- "data-index": j,
1092
- "aria-selected": oa,
1093
- "aria-disabled": L.isDisabled,
1138
+ "data-index": X,
1139
+ "aria-selected": la,
1140
+ "aria-disabled": T.isDisabled,
1094
1141
  className: d(
1095
- M.combobox__option,
1096
- Ya && M["combobox__option--active"],
1097
- oa && M["combobox__option--selected"],
1098
- L.isDisabled && M["combobox__option--disabled"]
1142
+ R.combobox__option,
1143
+ Wa && R["combobox__option--active"],
1144
+ la && R["combobox__option--selected"],
1145
+ T.isDisabled && R["combobox__option--disabled"]
1099
1146
  ),
1100
- onMouseEnter: () => K(j),
1101
- onClick: () => S(L),
1147
+ onMouseEnter: () => ee(X),
1148
+ onClick: () => K(T),
1102
1149
  children: [
1103
- /* @__PURE__ */ _("span", { className: M.combobox__optionText, children: [
1104
- /* @__PURE__ */ a("span", { className: M.combobox__optionLabel, children: L.label }),
1105
- L.description && /* @__PURE__ */ a("span", { className: M.combobox__optionDescription, children: L.description })
1150
+ /* @__PURE__ */ _("span", { className: R.combobox__optionText, children: [
1151
+ /* @__PURE__ */ a("span", { className: R.combobox__optionLabel, children: T.label }),
1152
+ T.description && /* @__PURE__ */ a("span", { className: R.combobox__optionDescription, children: T.description })
1106
1153
  ] }),
1107
- oa && /* @__PURE__ */ a(Ra, { className: M.combobox__check })
1154
+ la && /* @__PURE__ */ a(Pa, { className: R.combobox__check })
1108
1155
  ]
1109
1156
  }
1110
- ) }, L.value);
1157
+ ) }, T.value);
1111
1158
  }),
1112
- re.length === 0 && /* @__PURE__ */ a("li", { className: M.combobox__empty, children: s ? o.loadingMessage : o.emptyMessage })
1159
+ _e.length === 0 && /* @__PURE__ */ a("li", { className: R.combobox__empty, children: s ? f.loading : f.empty })
1113
1160
  ]
1114
1161
  }
1115
1162
  );
1116
- return /* @__PURE__ */ _("div", { ref: N, className: d(M.combobox, b), "data-testid": c, children: [
1163
+ return /* @__PURE__ */ _("div", { ref: E, className: d(R.combobox, g), "data-testid": h, children: [
1117
1164
  /* @__PURE__ */ _(
1118
1165
  "button",
1119
1166
  {
1120
- ref: E,
1121
- id: D,
1167
+ ref: S,
1168
+ id: x,
1122
1169
  type: "button",
1123
1170
  className: d(
1124
- M.combobox__trigger,
1125
- !Le && M["combobox__trigger--empty"],
1126
- A && M["combobox__trigger--open"],
1127
- f && M["combobox__trigger--invalid"]
1171
+ R.combobox__trigger,
1172
+ !Re && R["combobox__trigger--empty"],
1173
+ M && R["combobox__trigger--open"],
1174
+ N && R["combobox__trigger--invalid"]
1128
1175
  ),
1129
- disabled: l,
1176
+ disabled: c,
1130
1177
  "aria-haspopup": "listbox",
1131
- "aria-expanded": A,
1132
- "aria-controls": A ? $ : void 0,
1178
+ "aria-expanded": M,
1179
+ "aria-controls": M ? L : void 0,
1133
1180
  "aria-label": o.placeholder,
1134
- "aria-describedby": v,
1135
- onClick: () => A ? k() : P(),
1181
+ "aria-describedby": p,
1182
+ onClick: () => M ? $() : G(),
1136
1183
  children: [
1137
- p && /* @__PURE__ */ a("span", { className: M.combobox__leadingIcon, "aria-hidden": !0, children: p }),
1138
- /* @__PURE__ */ a("span", { className: M.combobox__value, children: Le ?? o.placeholder }),
1139
- u && Le && !l && /*
1184
+ u && /* @__PURE__ */ a("span", { className: R.combobox__leadingIcon, "aria-hidden": !0, children: u }),
1185
+ /* @__PURE__ */ a("span", { className: R.combobox__value, children: Re ?? o.placeholder }),
1186
+ l && Re && !c && /*
1140
1187
  Temizleme, tetikleyicinin İÇİNDE ayrı bir düğme olamaz (iç içe
1141
1188
  düğme geçersiz HTML). Görsel olarak içeride duran, DOM'da kardeş
1142
1189
  olan bir düğme kullanılır.
@@ -1146,342 +1193,343 @@ const Gn = h(Ha), Un = "hanui-group-0tnVf", ya = {
1146
1193
  {
1147
1194
  role: "button",
1148
1195
  tabIndex: 0,
1149
- className: M.combobox__clear,
1150
- "aria-label": o.clearLabel,
1196
+ className: R.combobox__clear,
1197
+ "aria-label": f.clear,
1151
1198
  onClick: (y) => {
1152
- y.stopPropagation(), da();
1199
+ y.stopPropagation(), ba();
1153
1200
  },
1154
1201
  onKeyDown: (y) => {
1155
- y.key !== "Enter" && y.key !== " " || (y.preventDefault(), y.stopPropagation(), da());
1202
+ y.key !== "Enter" && y.key !== " " || (y.preventDefault(), y.stopPropagation(), ba());
1156
1203
  },
1157
- children: /* @__PURE__ */ a(la, {})
1204
+ children: /* @__PURE__ */ a(pa, {})
1158
1205
  }
1159
1206
  ),
1160
1207
  /* @__PURE__ */ a(
1161
- Ta,
1208
+ Oa,
1162
1209
  {
1163
- className: d(M.combobox__chevron, A && M["combobox__chevron--open"])
1210
+ className: d(R.combobox__chevron, M && R["combobox__chevron--open"])
1164
1211
  }
1165
1212
  )
1166
1213
  ]
1167
1214
  }
1168
1215
  ),
1169
- I === "popover" && /* @__PURE__ */ _("div", { className: M.combobox__panel, children: [
1170
- _a,
1171
- ua(!1)
1216
+ B === "popover" && /* @__PURE__ */ _("div", { className: R.combobox__panel, children: [
1217
+ ma,
1218
+ ga(!1)
1172
1219
  ] }),
1173
- I === "sheet" && /* @__PURE__ */ a(
1174
- Pa,
1220
+ B === "sheet" && /* @__PURE__ */ a(
1221
+ Ga,
1175
1222
  {
1176
1223
  title: o.placeholder,
1177
- closeLabel: o.closeLabel,
1178
- onClose: k,
1179
- toolbar: _a ?? void 0,
1180
- children: ua(!0)
1224
+ closeLabel: o.closeLabel ?? (m == null ? void 0 : m.close),
1225
+ onClose: $,
1226
+ toolbar: ma ?? void 0,
1227
+ children: ga(!0)
1181
1228
  }
1182
1229
  )
1183
1230
  ] });
1184
- }, qs = h(gt), ft = "hanui-select-tiiPL", vt = "hanui-trigger-rHQJz", yt = "hanui-trigger__icon-apCcx", xt = "hanui-trigger__value-ioH7K", kt = "hanui-trigger__chevron-FtsIZ", Nt = "hanui-panel-rGOOd", wt = "hanui-list-SOKf8", $t = "hanui-option-ZDPef", Dt = "hanui-option__label-SsoYB", Ct = "hanui-option__check-8CPSG", F = {
1185
- select: ft,
1186
- trigger: vt,
1231
+ }, Qs = v(xt), kt = "hanui-select-tiiPL", Nt = "hanui-trigger-rHQJz", wt = "hanui-trigger__icon-apCcx", $t = "hanui-trigger__value-ioH7K", Dt = "hanui-trigger__chevron-FtsIZ", Lt = "hanui-panel-rGOOd", Ct = "hanui-list-SOKf8", It = "hanui-option-ZDPef", Et = "hanui-option__label-SsoYB", Mt = "hanui-option__check-8CPSG", q = {
1232
+ select: kt,
1233
+ trigger: Nt,
1187
1234
  "trigger--empty": "hanui-trigger--empty-cuinb",
1188
1235
  "trigger--open": "hanui-trigger--open-1nsvu",
1189
1236
  "trigger--sm": "hanui-trigger--sm-Xnu1C",
1190
- trigger__icon: yt,
1191
- trigger__value: xt,
1192
- trigger__chevron: kt,
1237
+ trigger__icon: wt,
1238
+ trigger__value: $t,
1239
+ trigger__chevron: Dt,
1193
1240
  "trigger__chevron--open": "hanui-trigger__chevron--open-1P2P-",
1194
- panel: Nt,
1241
+ panel: Lt,
1195
1242
  "hanui-fade-in-up": "hanui-hanui-fade-in-up-Lt0Bt",
1196
1243
  "panel--start": "hanui-panel--start-Fotwa",
1197
1244
  "panel--end": "hanui-panel--end-ClVl2",
1198
- list: wt,
1245
+ list: Ct,
1199
1246
  "list--sheet": "hanui-list--sheet-BIjCb",
1200
- option: $t,
1247
+ option: It,
1201
1248
  "option--active": "hanui-option--active-R4lLF",
1202
1249
  "option--selected": "hanui-option--selected-glQMj",
1203
1250
  "option--disabled": "hanui-option--disabled-h4rdd",
1204
- option__label: Dt,
1205
- option__check: Ct
1206
- }, It = ({
1251
+ option__label: Et,
1252
+ option__check: Mt
1253
+ }, Tt = ({
1207
1254
  options: e,
1208
1255
  value: n,
1209
1256
  onChange: t,
1210
1257
  label: o,
1211
- placeholder: r,
1212
- closeLabel: i,
1258
+ placeholder: i,
1259
+ closeLabel: r,
1213
1260
  icon: s,
1214
- size: l = "md",
1215
- align: u = "start",
1216
- isDisabled: p,
1217
- id: m,
1218
- className: b,
1219
- testId: c,
1220
- "aria-describedby": v,
1221
- "aria-invalid": f
1261
+ size: c = "md",
1262
+ align: l = "start",
1263
+ isDisabled: u,
1264
+ id: b,
1265
+ className: g,
1266
+ testId: h,
1267
+ "aria-describedby": p,
1268
+ "aria-invalid": N
1222
1269
  }) => {
1223
- const C = te(), D = m ?? C, $ = `${D}-listbox`, N = (k) => `${D}-option-${k}`, E = Y(null), U = Y(null), q = Y(null), [I, he] = G(null), [A, z] = G(0), O = I !== null, H = e.findIndex((k) => k.value === n), K = H >= 0 ? e[H] : null, ie = Z(() => he(null), []), fe = Z(() => {
1224
- p || e.length === 0 || (he(window.matchMedia(ca).matches ? "popover" : "sheet"), z(H >= 0 ? H : 0));
1225
- }, [p, e.length, H]), re = (k) => {
1226
- k.isDisabled || (t(k.value), ie());
1227
- }, se = Y(!1);
1228
- R(() => {
1229
- var k;
1230
- se.current && !O && ((k = U.current) == null || k.focus()), se.current = O;
1231
- }, [O]), R(() => {
1232
- if (I !== "popover") return;
1233
- const k = (P) => {
1234
- var S;
1235
- (S = E.current) != null && S.contains(P.target) || ie();
1270
+ const { labels: m } = P(), f = I("Select.placeholder", i, m == null ? void 0 : m.selectPlaceholder), D = ce(), x = b ?? D, L = `${x}-listbox`, E = ($) => `${x}-option-${$}`, S = Y(null), j = Y(null), te = Y(null), [B, oe] = Z(null), [M, A] = Z(0), H = B !== null, U = e.findIndex(($) => $.value === n), ee = U >= 0 ? e[U] : null, de = Q(() => oe(null), []), ke = Q(() => {
1271
+ u || e.length === 0 || (oe(window.matchMedia(ha).matches ? "popover" : "sheet"), A(U >= 0 ? U : 0));
1272
+ }, [u, e.length, U]), _e = ($) => {
1273
+ $.isDisabled || (t($.value), de());
1274
+ }, ue = Y(!1);
1275
+ F(() => {
1276
+ var $;
1277
+ ue.current && !H && (($ = j.current) == null || $.focus()), ue.current = H;
1278
+ }, [H]), F(() => {
1279
+ if (B !== "popover") return;
1280
+ const $ = (G) => {
1281
+ var K;
1282
+ (K = S.current) != null && K.contains(G.target) || de();
1236
1283
  };
1237
- return document.addEventListener("mousedown", k), () => document.removeEventListener("mousedown", k);
1238
- }, [I, ie]), R(() => {
1239
- var k;
1240
- I === "sheet" && ((k = q.current) == null || k.focus({ preventScroll: !0 }));
1241
- }, [I]), R(() => {
1242
- var k, P;
1243
- O && ((P = (k = q.current) == null ? void 0 : k.querySelector(`[data-index="${A}"]`)) == null || P.scrollIntoView({ block: "nearest" }));
1244
- }, [A, O]);
1245
- const Le = (k) => {
1246
- const P = e.length - 1;
1247
- if (!O) {
1248
- ["ArrowDown", "ArrowUp", "Enter", " "].includes(k.key) && (k.preventDefault(), fe());
1284
+ return document.addEventListener("mousedown", $), () => document.removeEventListener("mousedown", $);
1285
+ }, [B, de]), F(() => {
1286
+ var $;
1287
+ B === "sheet" && (($ = te.current) == null || $.focus({ preventScroll: !0 }));
1288
+ }, [B]), F(() => {
1289
+ var $, G;
1290
+ H && ((G = ($ = te.current) == null ? void 0 : $.querySelector(`[data-index="${M}"]`)) == null || G.scrollIntoView({ block: "nearest" }));
1291
+ }, [M, H]);
1292
+ const Re = ($) => {
1293
+ const G = e.length - 1;
1294
+ if (!H) {
1295
+ ["ArrowDown", "ArrowUp", "Enter", " "].includes($.key) && ($.preventDefault(), ke());
1249
1296
  return;
1250
1297
  }
1251
- switch (k.key) {
1298
+ switch ($.key) {
1252
1299
  case "ArrowDown":
1253
- k.preventDefault(), z((S) => S >= P ? 0 : S + 1);
1300
+ $.preventDefault(), A((K) => K >= G ? 0 : K + 1);
1254
1301
  break;
1255
1302
  case "ArrowUp":
1256
- k.preventDefault(), z((S) => S <= 0 ? P : S - 1);
1303
+ $.preventDefault(), A((K) => K <= 0 ? G : K - 1);
1257
1304
  break;
1258
1305
  case "Home":
1259
- k.preventDefault(), z(0);
1306
+ $.preventDefault(), A(0);
1260
1307
  break;
1261
1308
  case "End":
1262
- k.preventDefault(), z(P);
1309
+ $.preventDefault(), A(G);
1263
1310
  break;
1264
1311
  case "Enter":
1265
1312
  case " ": {
1266
- k.preventDefault();
1267
- const S = e[A];
1268
- S && re(S);
1313
+ $.preventDefault();
1314
+ const K = e[M];
1315
+ K && _e(K);
1269
1316
  break;
1270
1317
  }
1271
1318
  case "Escape":
1272
- k.preventDefault(), ie();
1319
+ $.preventDefault(), de();
1273
1320
  break;
1274
1321
  case "Tab":
1275
- ie();
1322
+ de();
1276
1323
  break;
1277
1324
  }
1278
- }, pe = (k) => /* @__PURE__ */ a(
1325
+ }, fe = ($) => /* @__PURE__ */ a(
1279
1326
  "ul",
1280
1327
  {
1281
- ref: q,
1282
- id: $,
1328
+ ref: te,
1329
+ id: L,
1283
1330
  role: "listbox",
1284
1331
  "aria-label": o,
1285
- "aria-activedescendant": k && e[A] ? N(A) : void 0,
1286
- tabIndex: k ? 0 : -1,
1287
- className: d(F.list, k && F["list--sheet"]),
1288
- onKeyDown: k ? Le : void 0,
1289
- children: e.map((P, S) => {
1290
- const Ee = P.value === n;
1332
+ "aria-activedescendant": $ && e[M] ? E(M) : void 0,
1333
+ tabIndex: $ ? 0 : -1,
1334
+ className: d(q.list, $ && q["list--sheet"]),
1335
+ onKeyDown: $ ? Re : void 0,
1336
+ children: e.map((G, K) => {
1337
+ const Ae = G.value === n;
1291
1338
  return /* @__PURE__ */ _(
1292
1339
  "li",
1293
1340
  {
1294
- id: N(S),
1341
+ id: E(K),
1295
1342
  role: "option",
1296
- "data-index": S,
1297
- "aria-selected": Ee,
1298
- "aria-disabled": P.isDisabled,
1343
+ "data-index": K,
1344
+ "aria-selected": Ae,
1345
+ "aria-disabled": G.isDisabled,
1299
1346
  className: d(
1300
- F.option,
1301
- S === A && F["option--active"],
1302
- Ee && F["option--selected"],
1303
- P.isDisabled && F["option--disabled"]
1347
+ q.option,
1348
+ K === M && q["option--active"],
1349
+ Ae && q["option--selected"],
1350
+ G.isDisabled && q["option--disabled"]
1304
1351
  ),
1305
- onMouseEnter: () => z(S),
1306
- onClick: () => re(P),
1352
+ onMouseEnter: () => A(K),
1353
+ onClick: () => _e(G),
1307
1354
  children: [
1308
- /* @__PURE__ */ a("span", { className: F.option__label, children: P.label }),
1309
- Ee && /* @__PURE__ */ a(Ra, { className: F.option__check })
1355
+ /* @__PURE__ */ a("span", { className: q.option__label, children: G.label }),
1356
+ Ae && /* @__PURE__ */ a(Pa, { className: q.option__check })
1310
1357
  ]
1311
1358
  },
1312
- P.value
1359
+ G.value
1313
1360
  );
1314
1361
  })
1315
1362
  }
1316
1363
  );
1317
- return /* @__PURE__ */ _("span", { ref: E, className: d(F.select, b), "data-testid": c, children: [
1364
+ return /* @__PURE__ */ _("span", { ref: S, className: d(q.select, g), "data-testid": h, children: [
1318
1365
  /* @__PURE__ */ _(
1319
1366
  "button",
1320
1367
  {
1321
- ref: U,
1322
- id: D,
1368
+ ref: j,
1369
+ id: x,
1323
1370
  type: "button",
1324
1371
  role: "combobox",
1325
1372
  className: d(
1326
- F.trigger,
1327
- F[`trigger--${l}`],
1328
- !K && F["trigger--empty"],
1329
- O && F["trigger--open"]
1373
+ q.trigger,
1374
+ q[`trigger--${c}`],
1375
+ !ee && q["trigger--empty"],
1376
+ H && q["trigger--open"]
1330
1377
  ),
1331
- disabled: p,
1378
+ disabled: u,
1332
1379
  "aria-haspopup": "listbox",
1333
- "aria-expanded": O,
1334
- "aria-controls": O ? $ : void 0,
1335
- "aria-activedescendant": I === "popover" && e[A] ? N(A) : void 0,
1380
+ "aria-expanded": H,
1381
+ "aria-controls": H ? L : void 0,
1382
+ "aria-activedescendant": B === "popover" && e[M] ? E(M) : void 0,
1336
1383
  "aria-label": o,
1337
- "aria-describedby": v,
1338
- "aria-invalid": f,
1339
- onClick: () => O ? ie() : fe(),
1340
- onKeyDown: Le,
1384
+ "aria-describedby": p,
1385
+ "aria-invalid": N,
1386
+ onClick: () => H ? de() : ke(),
1387
+ onKeyDown: Re,
1341
1388
  children: [
1342
- s && /* @__PURE__ */ a("span", { className: F.trigger__icon, "aria-hidden": !0, children: s }),
1343
- /* @__PURE__ */ a("span", { className: F.trigger__value, children: (K == null ? void 0 : K.label) ?? r }),
1389
+ s && /* @__PURE__ */ a("span", { className: q.trigger__icon, "aria-hidden": !0, children: s }),
1390
+ /* @__PURE__ */ a("span", { className: q.trigger__value, children: (ee == null ? void 0 : ee.label) ?? f }),
1344
1391
  /* @__PURE__ */ a(
1345
- Ta,
1392
+ Oa,
1346
1393
  {
1347
- className: d(F.trigger__chevron, O && F["trigger__chevron--open"])
1394
+ className: d(q.trigger__chevron, H && q["trigger__chevron--open"])
1348
1395
  }
1349
1396
  )
1350
1397
  ]
1351
1398
  }
1352
1399
  ),
1353
- I === "popover" && /* @__PURE__ */ a("div", { className: d(F.panel, F[`panel--${u}`]), children: pe(!1) }),
1354
- I === "sheet" && /* @__PURE__ */ a(Pa, { title: o, closeLabel: i, onClose: ie, children: pe(!0) })
1400
+ B === "popover" && /* @__PURE__ */ a("div", { className: d(q.panel, q[`panel--${l}`]), children: fe(!1) }),
1401
+ B === "sheet" && /* @__PURE__ */ a(Ga, { title: o, closeLabel: r ?? (m == null ? void 0 : m.close), onClose: de, children: fe(!0) })
1355
1402
  ] });
1356
- }, Xs = h(It), Lt = "hanui-checkbox-FaFCj", Et = "hanui-checkbox__input-nTHne", Mt = "hanui-checkbox__body-VAEW2", At = "hanui-checkbox__label-sSNZY", Rt = "hanui-checkbox__hint-ish-J", je = {
1357
- checkbox: Lt,
1358
- checkbox__input: Et,
1359
- checkbox__body: Mt,
1360
- checkbox__label: At,
1361
- checkbox__hint: Rt
1362
- }, za = ge(
1363
- ({ label: e, hint: n, className: t, testId: o, ...r }, i) => /* @__PURE__ */ _("label", { className: d(je.checkbox, t), "data-testid": o, children: [
1364
- /* @__PURE__ */ a("input", { ref: i, type: "checkbox", className: je.checkbox__input, ...r }),
1365
- /* @__PURE__ */ _("span", { className: je.checkbox__body, children: [
1366
- /* @__PURE__ */ a("span", { className: je.checkbox__label, children: e }),
1367
- n && /* @__PURE__ */ a("span", { className: je.checkbox__hint, children: n })
1403
+ }, Vs = v(Tt), Rt = "hanui-checkbox-FaFCj", At = "hanui-checkbox__input-nTHne", Bt = "hanui-checkbox__body-VAEW2", St = "hanui-checkbox__label-sSNZY", Ft = "hanui-checkbox__hint-ish-J", Ye = {
1404
+ checkbox: Rt,
1405
+ checkbox__input: At,
1406
+ checkbox__body: Bt,
1407
+ checkbox__label: St,
1408
+ checkbox__hint: Ft
1409
+ }, Ua = xe(
1410
+ ({ label: e, hint: n, className: t, testId: o, ...i }, r) => /* @__PURE__ */ _("label", { className: d(Ye.checkbox, t), "data-testid": o, children: [
1411
+ /* @__PURE__ */ a("input", { ref: r, type: "checkbox", className: Ye.checkbox__input, ...i }),
1412
+ /* @__PURE__ */ _("span", { className: Ye.checkbox__body, children: [
1413
+ /* @__PURE__ */ a("span", { className: Ye.checkbox__label, children: e }),
1414
+ n && /* @__PURE__ */ a("span", { className: Ye.checkbox__hint, children: n })
1368
1415
  ] })
1369
1416
  ] })
1370
1417
  );
1371
- za.displayName = "Checkbox";
1372
- const Ys = h(za), Tt = "hanui-radio-KoZak", Bt = "hanui-radio__input-gVMgh", St = "hanui-radio__body-oZWg6", Ft = "hanui-radio__label-d-5ce", Ot = "hanui-radio__hint-baVbs", Ht = "hanui-radio__count-OtkUM", Re = {
1373
- radio: Tt,
1374
- radio__input: Bt,
1375
- radio__body: St,
1376
- radio__label: Ft,
1377
- radio__hint: Ot,
1378
- radio__count: Ht
1379
- }, Ka = ge(
1380
- ({ label: e, hint: n, count: t, className: o, testId: r, ...i }, s) => /* @__PURE__ */ _("label", { className: d(Re.radio, o), "data-testid": r, children: [
1381
- /* @__PURE__ */ a("input", { ref: s, type: "radio", className: Re.radio__input, ...i }),
1382
- /* @__PURE__ */ _("span", { className: Re.radio__body, children: [
1383
- /* @__PURE__ */ a("span", { className: Re.radio__label, children: e }),
1384
- n && /* @__PURE__ */ a("span", { className: Re.radio__hint, children: n })
1418
+ Ua.displayName = "Checkbox";
1419
+ const Ws = v(Ua), Pt = "hanui-radio-KoZak", Ot = "hanui-radio__input-gVMgh", Ht = "hanui-radio__body-oZWg6", zt = "hanui-radio__label-d-5ce", Kt = "hanui-radio__hint-baVbs", qt = "hanui-radio__count-OtkUM", Fe = {
1420
+ radio: Pt,
1421
+ radio__input: Ot,
1422
+ radio__body: Ht,
1423
+ radio__label: zt,
1424
+ radio__hint: Kt,
1425
+ radio__count: qt
1426
+ }, Xa = xe(
1427
+ ({ label: e, hint: n, count: t, className: o, testId: i, ...r }, s) => /* @__PURE__ */ _("label", { className: d(Fe.radio, o), "data-testid": i, children: [
1428
+ /* @__PURE__ */ a("input", { ref: s, type: "radio", className: Fe.radio__input, ...r }),
1429
+ /* @__PURE__ */ _("span", { className: Fe.radio__body, children: [
1430
+ /* @__PURE__ */ a("span", { className: Fe.radio__label, children: e }),
1431
+ n && /* @__PURE__ */ a("span", { className: Fe.radio__hint, children: n })
1385
1432
  ] }),
1386
- Pe(t) && /* @__PURE__ */ a("span", { className: Re.radio__count, children: t })
1433
+ Ge(t) && /* @__PURE__ */ a("span", { className: Fe.radio__count, children: t })
1387
1434
  ] })
1388
1435
  );
1389
- Ka.displayName = "Radio";
1390
- const Zs = h(Ka), Pt = "hanui-radioCard-sndiC", zt = "hanui-radioCard__input-6vuoD", Kt = "hanui-radioCard__indicator--x9LT", jt = "hanui-radioCard__body-CFqoi", Te = {
1391
- radioCard: Pt,
1392
- radioCard__input: zt,
1436
+ Xa.displayName = "Radio";
1437
+ const ec = v(Xa), jt = "hanui-radioCard-sndiC", Gt = "hanui-radioCard__input-6vuoD", Ut = "hanui-radioCard__indicator--x9LT", Xt = "hanui-radioCard__body-CFqoi", Pe = {
1438
+ radioCard: jt,
1439
+ radioCard__input: Gt,
1393
1440
  "radioCard--selected": "hanui-radioCard--selected-Mi7ee",
1394
- radioCard__indicator: Kt,
1441
+ radioCard__indicator: Ut,
1395
1442
  "radioCard--disabled": "hanui-radioCard--disabled-YlYee",
1396
- radioCard__body: jt
1397
- }, Gt = ({
1443
+ radioCard__body: Xt
1444
+ }, Yt = ({
1398
1445
  name: e,
1399
1446
  value: n,
1400
1447
  isSelected: t,
1401
1448
  isDisabled: o,
1402
- onChange: r,
1403
- children: i,
1449
+ onChange: i,
1450
+ children: r,
1404
1451
  className: s,
1405
- id: l,
1406
- testId: u
1452
+ id: c,
1453
+ testId: l
1407
1454
  }) => /* @__PURE__ */ _(
1408
1455
  "label",
1409
1456
  {
1410
1457
  className: d(
1411
- Te.radioCard,
1412
- t && Te["radioCard--selected"],
1413
- o && Te["radioCard--disabled"],
1458
+ Pe.radioCard,
1459
+ t && Pe["radioCard--selected"],
1460
+ o && Pe["radioCard--disabled"],
1414
1461
  s
1415
1462
  ),
1416
- "data-testid": u,
1463
+ "data-testid": l,
1417
1464
  children: [
1418
1465
  /* @__PURE__ */ a(
1419
1466
  "input",
1420
1467
  {
1421
1468
  type: "radio",
1422
- id: l,
1469
+ id: c,
1423
1470
  name: e,
1424
1471
  value: n,
1425
1472
  checked: t,
1426
1473
  disabled: o,
1427
- onChange: () => r(n),
1428
- className: Te.radioCard__input
1474
+ onChange: () => i(n),
1475
+ className: Pe.radioCard__input
1429
1476
  }
1430
1477
  ),
1431
- /* @__PURE__ */ a("span", { className: Te.radioCard__indicator, "aria-hidden": !0 }),
1432
- /* @__PURE__ */ a("span", { className: Te.radioCard__body, children: i })
1478
+ /* @__PURE__ */ a("span", { className: Pe.radioCard__indicator, "aria-hidden": !0 }),
1479
+ /* @__PURE__ */ a("span", { className: Pe.radioCard__body, children: r })
1433
1480
  ]
1434
1481
  }
1435
- ), Js = h(Gt), Ut = "hanui-range-RpDPh", qt = "hanui-range__readout-itDMd", Xt = "hanui-range__separator-u-ZJX", Yt = "hanui-range__track-bCh5Y", Zt = "hanui-range__fill-VXMCE", Jt = "hanui-range__input-TAN2I", Vt = "hanui-range__bounds-GIhFd", ee = {
1436
- range: Ut,
1482
+ ), ac = v(Yt), Zt = "hanui-range-RpDPh", Jt = "hanui-range__readout-itDMd", Qt = "hanui-range__separator-u-ZJX", Vt = "hanui-range__track-bCh5Y", Wt = "hanui-range__fill-VXMCE", eo = "hanui-range__input-TAN2I", ao = "hanui-range__bounds-GIhFd", re = {
1483
+ range: Zt,
1437
1484
  "range--disabled": "hanui-range--disabled-13hlc",
1438
- range__readout: qt,
1439
- range__separator: Xt,
1440
- range__track: Yt,
1441
- range__fill: Zt,
1442
- range__input: Jt,
1443
- range__bounds: Vt
1444
- }, Qt = ({
1485
+ range__readout: Jt,
1486
+ range__separator: Qt,
1487
+ range__track: Vt,
1488
+ range__fill: Wt,
1489
+ range__input: eo,
1490
+ range__bounds: ao
1491
+ }, no = ({
1445
1492
  min: e,
1446
1493
  max: n,
1447
1494
  step: t = 1,
1448
1495
  value: o,
1449
- onChange: r,
1450
- onCommit: i,
1496
+ onChange: i,
1497
+ onCommit: r,
1451
1498
  formatValue: s = String,
1452
- label: l,
1453
- minLabel: u,
1454
- maxLabel: p,
1455
- isDisabled: m,
1456
- className: b,
1457
- testId: c
1499
+ label: c,
1500
+ minLabel: l,
1501
+ maxLabel: u,
1502
+ isDisabled: b,
1503
+ className: g,
1504
+ testId: h
1458
1505
  }) => {
1459
- const [v, f] = o, C = Z(
1460
- (I) => r([Math.min(I, f), f]),
1461
- [f, r]
1462
- ), D = Z(
1463
- (I) => r([v, Math.max(I, v)]),
1464
- [v, r]
1465
- ), $ = Z(() => i == null ? void 0 : i([v, f]), [v, f, i]), N = n - e, E = N === 0 ? 0 : ha(v - e, N), U = N === 0 ? 0 : ha(f - e, N), q = E > 50;
1506
+ var oe, M;
1507
+ const { labels: p } = P(), N = I("RangeSlider.minLabel", l, (oe = p == null ? void 0 : p.range) == null ? void 0 : oe.min), m = I("RangeSlider.maxLabel", u, (M = p == null ? void 0 : p.range) == null ? void 0 : M.max), [f, D] = o, x = Q(
1508
+ (A) => i([Math.min(A, D), D]),
1509
+ [D, i]
1510
+ ), L = Q(
1511
+ (A) => i([f, Math.max(A, f)]),
1512
+ [f, i]
1513
+ ), E = Q(() => r == null ? void 0 : r([f, D]), [f, D, r]), S = n - e, j = S === 0 ? 0 : fa(f - e, S), te = S === 0 ? 0 : fa(D - e, S), B = j > 50;
1466
1514
  return /* @__PURE__ */ _(
1467
1515
  "div",
1468
1516
  {
1469
- className: d(ee.range, m && ee["range--disabled"], b),
1517
+ className: d(re.range, b && re["range--disabled"], g),
1470
1518
  role: "group",
1471
- "aria-label": l,
1472
- "data-testid": c,
1519
+ "aria-label": c,
1520
+ "data-testid": h,
1473
1521
  children: [
1474
- /* @__PURE__ */ _("div", { className: ee.range__readout, children: [
1475
- /* @__PURE__ */ a("span", { className: ee.range__value, children: s(v) }),
1476
- /* @__PURE__ */ a("span", { className: ee.range__separator, "aria-hidden": !0, children: "—" }),
1477
- /* @__PURE__ */ a("span", { className: ee.range__value, children: s(f) })
1522
+ /* @__PURE__ */ _("div", { className: re.range__readout, children: [
1523
+ /* @__PURE__ */ a("span", { className: re.range__value, children: s(f) }),
1524
+ /* @__PURE__ */ a("span", { className: re.range__separator, "aria-hidden": !0, children: "—" }),
1525
+ /* @__PURE__ */ a("span", { className: re.range__value, children: s(D) })
1478
1526
  ] }),
1479
- /* @__PURE__ */ _("div", { className: ee.range__track, children: [
1527
+ /* @__PURE__ */ _("div", { className: re.range__track, children: [
1480
1528
  /* @__PURE__ */ a(
1481
1529
  "span",
1482
1530
  {
1483
- className: ee.range__fill,
1484
- style: { left: `${E}%`, right: `${100 - U}%` },
1531
+ className: re.range__fill,
1532
+ style: { left: `${j}%`, right: `${100 - te}%` },
1485
1533
  "aria-hidden": !0
1486
1534
  }
1487
1535
  ),
@@ -1489,341 +1537,362 @@ const Zs = h(Ka), Pt = "hanui-radioCard-sndiC", zt = "hanui-radioCard__input-6vu
1489
1537
  "input",
1490
1538
  {
1491
1539
  type: "range",
1492
- className: ee.range__input,
1493
- style: { zIndex: q ? 4 : 3 },
1540
+ className: re.range__input,
1541
+ style: { zIndex: B ? 4 : 3 },
1494
1542
  min: e,
1495
1543
  max: n,
1496
1544
  step: t,
1497
- value: v,
1498
- disabled: m,
1499
- "aria-label": `${l} — ${u}`,
1500
- "aria-valuetext": s(v),
1501
- onChange: (I) => C(Number(I.target.value)),
1502
- onPointerUp: $,
1503
- onKeyUp: $
1545
+ value: f,
1546
+ disabled: b,
1547
+ "aria-label": `${c} — ${N}`,
1548
+ "aria-valuetext": s(f),
1549
+ onChange: (A) => x(Number(A.target.value)),
1550
+ onPointerUp: E,
1551
+ onKeyUp: E
1504
1552
  }
1505
1553
  ),
1506
1554
  /* @__PURE__ */ a(
1507
1555
  "input",
1508
1556
  {
1509
1557
  type: "range",
1510
- className: ee.range__input,
1511
- style: { zIndex: q ? 3 : 4 },
1558
+ className: re.range__input,
1559
+ style: { zIndex: B ? 3 : 4 },
1512
1560
  min: e,
1513
1561
  max: n,
1514
1562
  step: t,
1515
- value: f,
1516
- disabled: m,
1517
- "aria-label": `${l} — ${p}`,
1518
- "aria-valuetext": s(f),
1519
- onChange: (I) => D(Number(I.target.value)),
1520
- onPointerUp: $,
1521
- onKeyUp: $
1563
+ value: D,
1564
+ disabled: b,
1565
+ "aria-label": `${c} — ${m}`,
1566
+ "aria-valuetext": s(D),
1567
+ onChange: (A) => L(Number(A.target.value)),
1568
+ onPointerUp: E,
1569
+ onKeyUp: E
1522
1570
  }
1523
1571
  )
1524
1572
  ] }),
1525
- /* @__PURE__ */ _("div", { className: ee.range__bounds, "aria-hidden": !0, children: [
1573
+ /* @__PURE__ */ _("div", { className: re.range__bounds, "aria-hidden": !0, children: [
1526
1574
  /* @__PURE__ */ a("span", { children: s(e) }),
1527
1575
  /* @__PURE__ */ a("span", { children: s(n) })
1528
1576
  ] })
1529
1577
  ]
1530
1578
  }
1531
1579
  );
1532
- }, Vs = h(Qt), Wt = "hanui-rating-neNnF", eo = "hanui-rating__legend-uYvFS", ao = "hanui-rating__stars-vJFLk", no = "hanui-rating__star-BANFJ", to = "hanui-rating__input-s2iiO", oo = "hanui-rating__srOnly-iSCoz", io = "hanui-rating__caption-13KFX", le = {
1533
- rating: Wt,
1580
+ }, nc = v(no), to = "hanui-rating-neNnF", oo = "hanui-rating__legend-uYvFS", ro = "hanui-rating__stars-vJFLk", io = "hanui-rating__star-BANFJ", so = "hanui-rating__input-s2iiO", co = "hanui-rating__srOnly-iSCoz", lo = "hanui-rating__caption-13KFX", pe = {
1581
+ rating: to,
1534
1582
  "rating--disabled": "hanui-rating--disabled-ZKjHa",
1535
- rating__legend: eo,
1536
- rating__stars: ao,
1537
- rating__star: no,
1583
+ rating__legend: oo,
1584
+ rating__stars: ro,
1585
+ rating__star: io,
1538
1586
  "rating__star--filled": "hanui-rating__star--filled-L3AkT",
1539
- rating__input: to,
1540
- rating__srOnly: oo,
1541
- rating__caption: io
1542
- }, ro = [1, 2, 3, 4, 5], so = ({
1587
+ rating__input: so,
1588
+ rating__srOnly: co,
1589
+ rating__caption: lo
1590
+ }, _o = [1, 2, 3, 4, 5], uo = ({
1543
1591
  value: e,
1544
1592
  onChange: n,
1545
1593
  label: t,
1546
1594
  ratingLabels: o,
1547
- formatStarCount: r,
1548
- isDisabled: i,
1595
+ formatStarCount: i,
1596
+ isDisabled: r,
1549
1597
  className: s,
1550
- testId: l
1598
+ testId: c
1551
1599
  }) => {
1552
- const u = te(), [p, m] = G(null), b = p ?? e;
1600
+ var N;
1601
+ const { labels: l } = P(), u = o ?? ((N = l == null ? void 0 : l.rating) == null ? void 0 : N.scale), b = ce(), [g, h] = Z(null), p = g ?? e;
1553
1602
  return /* @__PURE__ */ _(
1554
1603
  "fieldset",
1555
1604
  {
1556
- className: d(le.rating, i && le["rating--disabled"], s),
1557
- disabled: i,
1558
- "data-testid": l,
1605
+ className: d(pe.rating, r && pe["rating--disabled"], s),
1606
+ disabled: r,
1607
+ "data-testid": c,
1559
1608
  children: [
1560
- /* @__PURE__ */ a("legend", { className: le.rating__legend, children: t }),
1561
- /* @__PURE__ */ a("div", { className: le.rating__stars, onMouseLeave: () => m(null), children: ro.map((c) => /* @__PURE__ */ _(
1562
- "label",
1563
- {
1564
- className: d(
1565
- le.rating__star,
1566
- b !== null && c <= b && le["rating__star--filled"]
1567
- ),
1568
- onMouseEnter: () => m(c),
1569
- children: [
1570
- /* @__PURE__ */ a(
1571
- "input",
1572
- {
1573
- type: "radio",
1574
- name: u,
1575
- value: c,
1576
- checked: e === c,
1577
- onChange: () => n(c),
1578
- className: le.rating__input
1579
- }
1609
+ /* @__PURE__ */ a("legend", { className: pe.rating__legend, children: t }),
1610
+ /* @__PURE__ */ a("div", { className: pe.rating__stars, onMouseLeave: () => h(null), children: _o.map((m) => {
1611
+ var f;
1612
+ return /* @__PURE__ */ _(
1613
+ "label",
1614
+ {
1615
+ className: d(
1616
+ pe.rating__star,
1617
+ p !== null && m <= p && pe["rating__star--filled"]
1580
1618
  ),
1581
- /* @__PURE__ */ a(Oa, {}),
1582
- /* @__PURE__ */ _("span", { className: le.rating__srOnly, children: [
1583
- r(c),
1584
- " — ",
1585
- o[c]
1586
- ] })
1587
- ]
1588
- },
1589
- c
1590
- )) }),
1591
- b !== null && /* @__PURE__ */ a("span", { className: le.rating__caption, "aria-hidden": !0, children: o[b] })
1619
+ onMouseEnter: () => h(m),
1620
+ children: [
1621
+ /* @__PURE__ */ a(
1622
+ "input",
1623
+ {
1624
+ type: "radio",
1625
+ name: b,
1626
+ value: m,
1627
+ checked: e === m,
1628
+ onChange: () => n(m),
1629
+ className: pe.rating__input
1630
+ }
1631
+ ),
1632
+ /* @__PURE__ */ a(qa, {}),
1633
+ /* @__PURE__ */ _("span", { className: pe.rating__srOnly, children: [
1634
+ qe(
1635
+ "RatingInput.formatStarCount",
1636
+ i ?? ((f = l == null ? void 0 : l.rating) == null ? void 0 : f.starCount),
1637
+ m
1638
+ ),
1639
+ " ",
1640
+ "— ",
1641
+ (u == null ? void 0 : u[m]) ?? ""
1642
+ ] })
1643
+ ]
1644
+ },
1645
+ m
1646
+ );
1647
+ }) }),
1648
+ p !== null && /* @__PURE__ */ a("span", { className: pe.rating__caption, "aria-hidden": !0, children: (u == null ? void 0 : u[p]) ?? "" })
1592
1649
  ]
1593
1650
  }
1594
1651
  );
1595
- }, Qs = h(so), co = "hanui-stepper-8s5Ih", lo = "hanui-stepper__button-h6g7d", _o = "hanui-stepper__input-OQh5v", Ge = {
1596
- stepper: co,
1597
- stepper__button: lo,
1598
- stepper__input: _o,
1652
+ }, tc = v(uo), ho = "hanui-stepper-8s5Ih", po = "hanui-stepper__button-h6g7d", bo = "hanui-stepper__input-OQh5v", Ze = {
1653
+ stepper: ho,
1654
+ stepper__button: po,
1655
+ stepper__input: bo,
1599
1656
  "stepper--sm": "hanui-stepper--sm-RvrBP",
1600
1657
  "stepper--md": "hanui-stepper--md-Cnjei"
1601
- }, uo = ({
1658
+ }, mo = ({
1602
1659
  value: e,
1603
1660
  onChange: n,
1604
1661
  label: t,
1605
1662
  decreaseLabel: o,
1606
- increaseLabel: r,
1607
- min: i = 1,
1663
+ increaseLabel: i,
1664
+ min: r = 1,
1608
1665
  max: s = 99,
1609
- isDisabled: l,
1610
- size: u = "md",
1611
- className: p,
1612
- testId: m
1666
+ isDisabled: c,
1667
+ size: l = "md",
1668
+ className: u,
1669
+ testId: b
1613
1670
  }) => {
1614
- const [b, c] = G(null), v = (f) => {
1615
- c(null);
1616
- const C = Number(f.replace(/\D/g, ""));
1617
- C && n(Math.min(Math.max(C, i), s));
1671
+ var f, D, x;
1672
+ const { labels: g } = P(), h = I("QuantityStepper.label", t, (f = g == null ? void 0 : g.quantity) == null ? void 0 : f.label), [p, N] = Z(null), m = (L) => {
1673
+ N(null);
1674
+ const E = Number(L.replace(/\D/g, ""));
1675
+ E && n(Math.min(Math.max(E, r), s));
1618
1676
  };
1619
1677
  return /* @__PURE__ */ _(
1620
1678
  "div",
1621
1679
  {
1622
- className: d(Ge.stepper, Ge[`stepper--${u}`], p),
1680
+ className: d(Ze.stepper, Ze[`stepper--${l}`], u),
1623
1681
  role: "group",
1624
- "aria-label": t,
1625
- "data-testid": m,
1682
+ "aria-label": h,
1683
+ "data-testid": b,
1626
1684
  children: [
1627
1685
  /* @__PURE__ */ a(
1628
1686
  "button",
1629
1687
  {
1630
1688
  type: "button",
1631
- className: Ge.stepper__button,
1632
- onClick: () => n(Math.max(e - 1, i)),
1633
- disabled: l || e <= i,
1634
- "aria-label": o,
1635
- children: /* @__PURE__ */ a(Nn, {})
1689
+ className: Ze.stepper__button,
1690
+ onClick: () => n(Math.max(e - 1, r)),
1691
+ disabled: c || e <= r,
1692
+ "aria-label": I(
1693
+ "QuantityStepper.decreaseLabel",
1694
+ o,
1695
+ (D = g == null ? void 0 : g.quantity) == null ? void 0 : D.decrease
1696
+ ),
1697
+ children: /* @__PURE__ */ a(Ln, {})
1636
1698
  }
1637
1699
  ),
1638
1700
  /* @__PURE__ */ a(
1639
1701
  "input",
1640
1702
  {
1641
- className: Ge.stepper__input,
1642
- value: b ?? String(e),
1643
- onChange: (f) => c(f.target.value.replace(/\D/g, "").slice(0, 2)),
1644
- onBlur: (f) => v(f.target.value),
1645
- onKeyDown: (f) => {
1646
- f.key === "Enter" && (f.preventDefault(), v(f.target.value));
1703
+ className: Ze.stepper__input,
1704
+ value: p ?? String(e),
1705
+ onChange: (L) => N(L.target.value.replace(/\D/g, "").slice(0, 2)),
1706
+ onBlur: (L) => m(L.target.value),
1707
+ onKeyDown: (L) => {
1708
+ L.key === "Enter" && (L.preventDefault(), m(L.target.value));
1647
1709
  },
1648
1710
  inputMode: "numeric",
1649
- disabled: l,
1650
- "aria-label": `${t} (${i}-${s})`
1711
+ disabled: c,
1712
+ "aria-label": `${h} (${r}-${s})`
1651
1713
  }
1652
1714
  ),
1653
1715
  /* @__PURE__ */ a(
1654
1716
  "button",
1655
1717
  {
1656
1718
  type: "button",
1657
- className: Ge.stepper__button,
1719
+ className: Ze.stepper__button,
1658
1720
  onClick: () => n(Math.min(e + 1, s)),
1659
- disabled: l || e >= s,
1660
- "aria-label": r,
1661
- children: /* @__PURE__ */ a(kn, {})
1721
+ disabled: c || e >= s,
1722
+ "aria-label": I(
1723
+ "QuantityStepper.increaseLabel",
1724
+ i,
1725
+ (x = g == null ? void 0 : g.quantity) == null ? void 0 : x.increase
1726
+ ),
1727
+ children: /* @__PURE__ */ a(Dn, {})
1662
1728
  }
1663
1729
  )
1664
1730
  ]
1665
1731
  }
1666
1732
  );
1667
- }, Ws = h(uo), ho = "hanui-checkbox--dvpB", po = {
1668
- checkbox: ho
1669
- }, ja = ge(
1670
- ({ label: e, className: n, testId: t, ...o }, r) => /* @__PURE__ */ a(
1733
+ }, oc = v(mo), go = "hanui-checkbox--dvpB", fo = {
1734
+ checkbox: go
1735
+ }, Ya = xe(
1736
+ ({ label: e, className: n, testId: t, ...o }, i) => /* @__PURE__ */ a(
1671
1737
  "input",
1672
1738
  {
1673
- ref: r,
1739
+ ref: i,
1674
1740
  type: "checkbox",
1675
1741
  "aria-label": e,
1676
- className: d(po.checkbox, n),
1742
+ className: d(fo.checkbox, n),
1677
1743
  "data-testid": t,
1678
1744
  ...o
1679
1745
  }
1680
1746
  )
1681
1747
  );
1682
- ja.displayName = "TableCheckbox";
1683
- const ec = h(ja), bo = "hanui-wrapper-IAI4E", mo = "hanui-wrapper__prefix-XKDlV", go = "hanui-wrapper__suffix-lT35q", fo = "hanui-input-pIS2u", ve = {
1684
- wrapper: bo,
1685
- wrapper__prefix: mo,
1686
- wrapper__suffix: go,
1687
- input: fo,
1748
+ Ya.displayName = "TableCheckbox";
1749
+ const rc = v(Ya), yo = "hanui-wrapper-IAI4E", vo = "hanui-wrapper__prefix-XKDlV", xo = "hanui-wrapper__suffix-lT35q", ko = "hanui-input-pIS2u", Ne = {
1750
+ wrapper: yo,
1751
+ wrapper__prefix: vo,
1752
+ wrapper__suffix: xo,
1753
+ input: ko,
1688
1754
  "input--hasPrefix": "hanui-input--hasPrefix-nsrWh",
1689
1755
  "input--hasSuffix": "hanui-input--hasSuffix-OrE5A",
1690
1756
  "input--technical": "hanui-input--technical---DCD"
1691
- }, Ga = ge(
1692
- ({ prefix: e, suffix: n, isTechnical: t, className: o, testId: r, ...i }, s) => /* @__PURE__ */ _("span", { className: d(ve.wrapper, o), children: [
1693
- e && /* @__PURE__ */ a("span", { className: ve.wrapper__prefix, "aria-hidden": !0, children: e }),
1757
+ }, Za = xe(
1758
+ ({ prefix: e, suffix: n, isTechnical: t, className: o, testId: i, ...r }, s) => /* @__PURE__ */ _("span", { className: d(Ne.wrapper, o), children: [
1759
+ e && /* @__PURE__ */ a("span", { className: Ne.wrapper__prefix, "aria-hidden": !0, children: e }),
1694
1760
  /* @__PURE__ */ a(
1695
1761
  "input",
1696
1762
  {
1697
1763
  ref: s,
1698
1764
  className: d(
1699
- ve.input,
1765
+ Ne.input,
1700
1766
  /* `Boolean(...)`: `prefix` bir `ReactNode` ve `0` da gecerli bir
1701
1767
  deger — `prefix &&` ifadesi o durumda dize degil sayi donuyordu. */
1702
- !!e && ve["input--hasPrefix"],
1703
- !!n && ve["input--hasSuffix"],
1704
- t && ve["input--technical"]
1768
+ !!e && Ne["input--hasPrefix"],
1769
+ !!n && Ne["input--hasSuffix"],
1770
+ t && Ne["input--technical"]
1705
1771
  ),
1706
- "data-testid": r,
1707
- ...i
1772
+ "data-testid": i,
1773
+ ...r
1708
1774
  }
1709
1775
  ),
1710
- n && /* @__PURE__ */ a("span", { className: ve.wrapper__suffix, "aria-hidden": !0, children: n })
1776
+ n && /* @__PURE__ */ a("span", { className: Ne.wrapper__suffix, "aria-hidden": !0, children: n })
1711
1777
  ] })
1712
1778
  );
1713
- Ga.displayName = "Input";
1714
- const vo = h(Ga), yo = "hanui-textarea-zwJcB", xo = {
1715
- textarea: yo
1716
- }, Ua = ge(
1717
- ({ className: e, rows: n = 4, testId: t, ...o }, r) => /* @__PURE__ */ a(
1779
+ Za.displayName = "Input";
1780
+ const No = v(Za), wo = "hanui-textarea-zwJcB", $o = {
1781
+ textarea: wo
1782
+ }, Ja = xe(
1783
+ ({ className: e, rows: n = 4, testId: t, ...o }, i) => /* @__PURE__ */ a(
1718
1784
  "textarea",
1719
1785
  {
1720
- ref: r,
1786
+ ref: i,
1721
1787
  rows: n,
1722
- className: d(xo.textarea, e),
1788
+ className: d($o.textarea, e),
1723
1789
  "data-testid": t,
1724
1790
  ...o
1725
1791
  }
1726
1792
  )
1727
1793
  );
1728
- Ua.displayName = "Textarea";
1729
- const ko = h(Ua), No = "hanui-field-KKvre", wo = "hanui-field__label-9dlYd", $o = "hanui-field__required-hbDJk", Do = "hanui-field__srOnly-2WQFH", Co = "hanui-field__hint-SQPiL", Io = "hanui-field__error-gLlZ-", ye = {
1730
- field: No,
1731
- field__label: wo,
1794
+ Ja.displayName = "Textarea";
1795
+ const Do = v(Ja), Lo = "hanui-field-KKvre", Co = "hanui-field__label-9dlYd", Io = "hanui-field__required-hbDJk", Eo = "hanui-field__srOnly-2WQFH", Mo = "hanui-field__hint-SQPiL", To = "hanui-field__error-gLlZ-", we = {
1796
+ field: Lo,
1797
+ field__label: Co,
1732
1798
  "field__label--hidden": "hanui-field__label--hidden-ufuVt",
1733
- field__required: $o,
1734
- field__srOnly: Do,
1735
- field__hint: Co,
1736
- field__error: Io
1737
- }, Lo = ({
1799
+ field__required: Io,
1800
+ field__srOnly: Eo,
1801
+ field__hint: Mo,
1802
+ field__error: To
1803
+ }, Ro = ({
1738
1804
  label: e,
1739
1805
  children: n,
1740
1806
  hint: t,
1741
1807
  error: o,
1742
- isRequired: r,
1743
- requiredLabel: i,
1808
+ isRequired: i,
1809
+ requiredLabel: r,
1744
1810
  isLabelHidden: s,
1745
- className: l
1811
+ className: c
1746
1812
  }) => {
1747
- const u = te(), p = `${u}-error`, m = `${u}-hint`;
1748
- return /* @__PURE__ */ _("div", { className: d(ye.field, l), children: [
1813
+ const { labels: l } = P(), u = ce(), b = `${u}-error`, g = `${u}-hint`;
1814
+ return /* @__PURE__ */ _("div", { className: d(we.field, c), children: [
1749
1815
  /* @__PURE__ */ _(
1750
1816
  "label",
1751
1817
  {
1752
1818
  htmlFor: u,
1753
- className: d(ye.field__label, s && ye["field__label--hidden"]),
1819
+ className: d(we.field__label, s && we["field__label--hidden"]),
1754
1820
  children: [
1755
1821
  e,
1756
- r && /* @__PURE__ */ _(Je, { children: [
1757
- /* @__PURE__ */ a("span", { className: ye.field__required, "aria-hidden": !0, children: "*" }),
1758
- /* @__PURE__ */ a("span", { className: ye.field__srOnly, children: i })
1822
+ i && /* @__PURE__ */ _(aa, { children: [
1823
+ /* @__PURE__ */ a("span", { className: we.field__required, "aria-hidden": !0, children: "*" }),
1824
+ /* @__PURE__ */ a("span", { className: we.field__srOnly, children: I("Field.requiredLabel", r, l == null ? void 0 : l.required) })
1759
1825
  ] })
1760
1826
  ]
1761
1827
  }
1762
1828
  ),
1763
1829
  n({
1764
1830
  id: u,
1765
- required: r || void 0,
1831
+ required: i || void 0,
1766
1832
  "aria-invalid": o ? !0 : void 0,
1767
- "aria-describedby": o ? p : t ? m : void 0
1833
+ "aria-describedby": o ? b : t ? g : void 0
1768
1834
  }),
1769
- o ? /* @__PURE__ */ _("p", { id: p, className: ye.field__error, role: "alert", children: [
1770
- /* @__PURE__ */ a(Fa, {}),
1835
+ o ? /* @__PURE__ */ _("p", { id: b, className: we.field__error, role: "alert", children: [
1836
+ /* @__PURE__ */ a(Ka, {}),
1771
1837
  o
1772
- ] }) : t && /* @__PURE__ */ a("p", { id: m, className: ye.field__hint, children: t })
1838
+ ] }) : t && /* @__PURE__ */ a("p", { id: g, className: we.field__hint, children: t })
1773
1839
  ] });
1774
- }, xa = h(Lo), Eo = "hanui-alert-gHI-9", Mo = "hanui-alert__icon-DhiCT", Ao = "hanui-alert__body-52-z2", Ro = "hanui-alert__title-I8BAh", To = "hanui-alert__content-lhBEo", Bo = "hanui-alert__action-1mTje", xe = {
1775
- alert: Eo,
1776
- alert__icon: Mo,
1777
- alert__body: Ao,
1778
- alert__title: Ro,
1779
- alert__content: To,
1780
- alert__action: Bo,
1840
+ }, Ao = v(Ro), Bo = "hanui-alert-gHI-9", So = "hanui-alert__icon-DhiCT", Fo = "hanui-alert__body-52-z2", Po = "hanui-alert__title-I8BAh", Oo = "hanui-alert__content-lhBEo", Ho = "hanui-alert__action-1mTje", $e = {
1841
+ alert: Bo,
1842
+ alert__icon: So,
1843
+ alert__body: Fo,
1844
+ alert__title: Po,
1845
+ alert__content: Oo,
1846
+ alert__action: Ho,
1781
1847
  "alert--info": "hanui-alert--info-lsAVw",
1782
1848
  "alert--success": "hanui-alert--success-RMJR6",
1783
1849
  "alert--warning": "hanui-alert--warning-Rkgln",
1784
1850
  "alert--danger": "hanui-alert--danger-9ei0Y"
1785
- }, So = {
1786
- info: /* @__PURE__ */ a($n, {}),
1787
- success: /* @__PURE__ */ a(Dn, {}),
1788
- warning: /* @__PURE__ */ a(Sa, {}),
1789
- danger: /* @__PURE__ */ a(Cn, {})
1790
- }, Fo = ({ children: e, tone: n = "info", title: t, action: o, className: r, testId: i }) => /* @__PURE__ */ _(
1851
+ }, zo = {
1852
+ info: /* @__PURE__ */ a(In, {}),
1853
+ success: /* @__PURE__ */ a(En, {}),
1854
+ warning: /* @__PURE__ */ a(za, {}),
1855
+ danger: /* @__PURE__ */ a(Mn, {})
1856
+ }, Ko = ({ children: e, tone: n = "info", title: t, action: o, className: i, testId: r }) => /* @__PURE__ */ _(
1791
1857
  "div",
1792
1858
  {
1793
- className: d(xe.alert, xe[`alert--${n}`], r),
1859
+ className: d($e.alert, $e[`alert--${n}`], i),
1794
1860
  role: n === "danger" || n === "warning" ? "alert" : void 0,
1795
- "data-testid": i,
1861
+ "data-testid": r,
1796
1862
  children: [
1797
- /* @__PURE__ */ a("span", { className: xe.alert__icon, children: So[n] }),
1798
- /* @__PURE__ */ _("div", { className: xe.alert__body, children: [
1799
- t && /* @__PURE__ */ a("strong", { className: xe.alert__title, children: t }),
1800
- /* @__PURE__ */ a("div", { className: xe.alert__content, children: e })
1863
+ /* @__PURE__ */ a("span", { className: $e.alert__icon, children: zo[n] }),
1864
+ /* @__PURE__ */ _("div", { className: $e.alert__body, children: [
1865
+ t && /* @__PURE__ */ a("strong", { className: $e.alert__title, children: t }),
1866
+ /* @__PURE__ */ a("div", { className: $e.alert__content, children: e })
1801
1867
  ] }),
1802
- o && /* @__PURE__ */ a("div", { className: xe.alert__action, children: o })
1868
+ o && /* @__PURE__ */ a("div", { className: $e.alert__action, children: o })
1803
1869
  ]
1804
1870
  }
1805
- ), ac = h(Fo), Oo = "hanui-avatar-qoh3P", Ho = "hanui-avatar__image-uAyAX", sa = {
1806
- avatar: Oo,
1807
- avatar__image: Ho,
1871
+ ), ic = v(Ko), qo = "hanui-avatar-qoh3P", jo = "hanui-avatar__image-uAyAX", ua = {
1872
+ avatar: qo,
1873
+ avatar__image: jo,
1808
1874
  "avatar--sm": "hanui-avatar--sm-GGjU4",
1809
1875
  "avatar--md": "hanui-avatar--md-xhXnK",
1810
1876
  "avatar--lg": "hanui-avatar--lg-ULP-r"
1811
- }, Po = (e, n) => {
1877
+ }, Go = (e, n) => {
1812
1878
  const t = e.trim().split(/\s+/).filter(Boolean);
1813
1879
  if (t.length === 0) return "?";
1814
1880
  const o = t.length === 1 ? t[0].slice(0, 2) : `${t[0][0]}${t[t.length - 1][0]}`;
1815
1881
  return n ? o.toLocaleUpperCase(n) : o.toLocaleUpperCase();
1816
- }, zo = ({ name: e, imageUrl: n, locale: t, size: o = "md", className: r, testId: i }) => /* @__PURE__ */ a(
1817
- "span",
1818
- {
1819
- className: d(sa.avatar, sa[`avatar--${o}`], r),
1820
- "aria-hidden": !0,
1821
- "data-testid": i,
1822
- children: n ? /* @__PURE__ */ a("img", { className: sa.avatar__image, src: n, alt: "" }) : Po(e, t)
1823
- }
1824
- ), nc = h(zo), Ko = "hanui-badge-uLAaI", jo = "hanui-badge__icon-R2goZ", We = {
1825
- badge: Ko,
1826
- badge__icon: jo,
1882
+ }, Uo = ({ name: e, imageUrl: n, locale: t, size: o = "md", className: i, testId: r }) => {
1883
+ const { labels: s } = P();
1884
+ return /* @__PURE__ */ a(
1885
+ "span",
1886
+ {
1887
+ className: d(ua.avatar, ua[`avatar--${o}`], i),
1888
+ "aria-hidden": !0,
1889
+ "data-testid": r,
1890
+ children: n ? /* @__PURE__ */ a("img", { className: ua.avatar__image, src: n, alt: "" }) : Go(e, t ?? (s == null ? void 0 : s.locale))
1891
+ }
1892
+ );
1893
+ }, sc = v(Uo), Xo = "hanui-badge-uLAaI", Yo = "hanui-badge__icon-R2goZ", oa = {
1894
+ badge: Xo,
1895
+ badge__icon: Yo,
1827
1896
  "badge--neutral": "hanui-badge--neutral-6kddt",
1828
1897
  "badge--soft": "hanui-badge--soft-gFeRF",
1829
1898
  "badge--solid": "hanui-badge--solid-rtdHI",
@@ -1837,76 +1906,87 @@ const ko = h(Ua), No = "hanui-field-KKvre", wo = "hanui-field__label-9dlYd", $o
1837
1906
  "badge--sale": "hanui-badge--sale-Li1tG",
1838
1907
  "badge--action": "hanui-badge--action-7pUio",
1839
1908
  "badge--link": "hanui-badge--link-zcNJZ"
1840
- }, Go = ({
1909
+ }, Zo = ({
1841
1910
  children: e,
1842
1911
  tone: n = "neutral",
1843
1912
  variant: t = "soft",
1844
1913
  icon: o,
1845
- className: r,
1846
- testId: i
1914
+ className: i,
1915
+ testId: r
1847
1916
  }) => /* @__PURE__ */ _(
1848
1917
  "span",
1849
1918
  {
1850
- className: d(We.badge, We[`badge--${n}`], We[`badge--${t}`], r),
1851
- "data-testid": i,
1919
+ className: d(oa.badge, oa[`badge--${n}`], oa[`badge--${t}`], i),
1920
+ "data-testid": r,
1852
1921
  children: [
1853
- o && /* @__PURE__ */ a("span", { className: We.badge__icon, children: o }),
1922
+ o && /* @__PURE__ */ a("span", { className: oa.badge__icon, children: o }),
1854
1923
  e
1855
1924
  ]
1856
1925
  }
1857
- ), tc = h(Go), Uo = "hanui-breadcrumb-amB9n", qo = "hanui-breadcrumb__item-Icv1S", Xo = "hanui-breadcrumb__link-eVkPq", Yo = "hanui-breadcrumb__current-8XjhU", Zo = "hanui-breadcrumb__separator-vvaUi", Ue = {
1858
- breadcrumb: Uo,
1859
- breadcrumb__item: qo,
1860
- breadcrumb__link: Xo,
1861
- breadcrumb__current: Yo,
1862
- breadcrumb__separator: Zo
1863
- }, Jo = ({ items: e, label: n, linkProps: t, className: o, testId: r }) => /* @__PURE__ */ a("nav", { className: o, "aria-label": n, "data-testid": r, children: /* @__PURE__ */ a("ol", { className: d(Ue.breadcrumb), children: e.map((i, s) => {
1864
- const l = s === e.length - 1;
1865
- return /* @__PURE__ */ _("li", { className: Ue.breadcrumb__item, children: [
1866
- i.href && !l ? /* @__PURE__ */ a(oe, { href: i.href, className: Ue.breadcrumb__link, ...t, children: i.label }) : /* @__PURE__ */ a("span", { className: Ue.breadcrumb__current, "aria-current": "page", children: i.label }),
1867
- !l && /* @__PURE__ */ a(Ba, { className: Ue.breadcrumb__separator })
1868
- ] }, `${i.label}-${s}`);
1869
- }) }) }), oc = h(Jo), Vo = "hanui-card-CaHUG", Qo = "hanui-media__frame-eBv-s", Wo = "hanui-media-eggk5", ei = "hanui-media__link-ujyVV", ai = "hanui-overlay-AVMTX", ni = "hanui-body-DyI-6", ti = "hanui-footer-2WNCZ", ne = {
1870
- card: Vo,
1926
+ ), cc = v(Zo), Jo = "hanui-breadcrumb-amB9n", Qo = "hanui-breadcrumb__item-Icv1S", Vo = "hanui-breadcrumb__link-eVkPq", Wo = "hanui-breadcrumb__current-8XjhU", er = "hanui-breadcrumb__separator-vvaUi", Je = {
1927
+ breadcrumb: Jo,
1928
+ breadcrumb__item: Qo,
1929
+ breadcrumb__link: Vo,
1930
+ breadcrumb__current: Wo,
1931
+ breadcrumb__separator: er
1932
+ }, ar = ({ items: e, label: n, linkProps: t, className: o, testId: i }) => {
1933
+ const { labels: r } = P();
1934
+ return /* @__PURE__ */ a(
1935
+ "nav",
1936
+ {
1937
+ className: o,
1938
+ "aria-label": I("Breadcrumb.label", n, r == null ? void 0 : r.breadcrumb),
1939
+ "data-testid": i,
1940
+ children: /* @__PURE__ */ a("ol", { className: d(Je.breadcrumb), children: e.map((s, c) => {
1941
+ const l = c === e.length - 1;
1942
+ return /* @__PURE__ */ _("li", { className: Je.breadcrumb__item, children: [
1943
+ s.href && !l ? /* @__PURE__ */ a(le, { href: s.href, className: Je.breadcrumb__link, ...t, children: s.label }) : /* @__PURE__ */ a("span", { className: Je.breadcrumb__current, "aria-current": "page", children: s.label }),
1944
+ !l && /* @__PURE__ */ a(Ha, { className: Je.breadcrumb__separator })
1945
+ ] }, `${s.label}-${c}`);
1946
+ }) })
1947
+ }
1948
+ );
1949
+ }, lc = v(ar), nr = "hanui-card-CaHUG", tr = "hanui-media__frame-eBv-s", or = "hanui-media-eggk5", rr = "hanui-media__link-ujyVV", ir = "hanui-overlay-AVMTX", sr = "hanui-body-DyI-6", cr = "hanui-footer-2WNCZ", se = {
1950
+ card: nr,
1871
1951
  "card--interactive": "hanui-card--interactive-C1pXZ",
1872
- media__frame: Qo,
1873
- media: Wo,
1874
- media__link: ei,
1952
+ media__frame: tr,
1953
+ media: or,
1954
+ media__link: rr,
1875
1955
  "media__frame--contained": "hanui-media__frame--contained-Nv9gh",
1876
- overlay: ai,
1956
+ overlay: ir,
1877
1957
  "overlay--top-left": "hanui-overlay--top-left-td1xA",
1878
1958
  "overlay--top-right": "hanui-overlay--top-right-GqD9H",
1879
1959
  "overlay--bottom-left": "hanui-overlay--bottom-left-T5Quw",
1880
1960
  "overlay--bottom-right": "hanui-overlay--bottom-right-za3z3",
1881
- body: ni,
1882
- footer: ti
1883
- }, oi = ({ children: e, isInteractive: n, as: t = "div", className: o, testId: r }) => /* @__PURE__ */ a(
1961
+ body: sr,
1962
+ footer: cr
1963
+ }, lr = ({ children: e, isInteractive: n, as: t = "div", className: o, testId: i }) => /* @__PURE__ */ a(
1884
1964
  t,
1885
1965
  {
1886
- className: d(ne.card, n && ne["card--interactive"], o),
1887
- "data-testid": r,
1966
+ className: d(se.card, n && se["card--interactive"], o),
1967
+ "data-testid": i,
1888
1968
  children: e
1889
1969
  }
1890
- ), ii = h(
1891
- ({ children: e, ratio: n = 1, href: t, linkProps: o, isContained: r = !0, className: i }) => {
1970
+ ), dr = v(
1971
+ ({ children: e, ratio: n = 1, href: t, linkProps: o, isContained: i = !0, className: r }) => {
1892
1972
  const s = /* @__PURE__ */ a(
1893
1973
  "span",
1894
1974
  {
1895
- className: d(ne.media__frame, r && ne["media__frame--contained"]),
1975
+ className: d(se.media__frame, i && se["media__frame--contained"]),
1896
1976
  style: { aspectRatio: n },
1897
1977
  children: e
1898
1978
  }
1899
1979
  );
1900
- return /* @__PURE__ */ a("div", { className: d(ne.media, i), children: t ? (
1980
+ return /* @__PURE__ */ a("div", { className: d(se.media, r), children: t ? (
1901
1981
  // `tabIndex={-1}` + `aria-hidden`: aynı hedefe giden başlık bağlantısı
1902
1982
  // zaten sekme sırasında. Görseli ikinci bir durak yapmak klavye
1903
1983
  // gezinmesini iki katına çıkarıyor, ekran okuyucuda da aynı kayıt
1904
1984
  // arka arkaya iki kez duyuruluyordu.
1905
1985
  /* @__PURE__ */ a(
1906
- oe,
1986
+ le,
1907
1987
  {
1908
1988
  href: t,
1909
- className: ne.media__link,
1989
+ className: se.media__link,
1910
1990
  tabIndex: -1,
1911
1991
  "aria-hidden": !0,
1912
1992
  ...o,
@@ -1916,960 +1996,1004 @@ const ko = h(Ua), No = "hanui-field-KKvre", wo = "hanui-field__label-9dlYd", $o
1916
1996
  ) : s });
1917
1997
  }
1918
1998
  );
1919
- ii.displayName = "CardMedia";
1920
- const ri = h(
1921
- ({ children: e, position: n = "top-left", className: t }) => /* @__PURE__ */ a("div", { className: d(ne.overlay, ne[`overlay--${n}`], t), children: e })
1999
+ dr.displayName = "CardMedia";
2000
+ const _r = v(
2001
+ ({ children: e, position: n = "top-left", className: t }) => /* @__PURE__ */ a("div", { className: d(se.overlay, se[`overlay--${n}`], t), children: e })
1922
2002
  );
1923
- ri.displayName = "CardOverlay";
1924
- const si = h(({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(ne.body, n), children: e }));
1925
- si.displayName = "CardBody";
1926
- const ci = h(({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(ne.footer, n), children: e }));
1927
- ci.displayName = "CardFooter";
1928
- const ic = h(oi), li = "hanui-copy-Yht5s", di = "hanui-copy__code-CYlCA", _i = "hanui-copy__button-GDdH6", ui = "hanui-copy__srOnly-WMTNN", Be = {
1929
- copy: li,
2003
+ _r.displayName = "CardOverlay";
2004
+ const ur = v(({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(se.body, n), children: e }));
2005
+ ur.displayName = "CardBody";
2006
+ const hr = v(({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(se.footer, n), children: e }));
2007
+ hr.displayName = "CardFooter";
2008
+ const dc = v(lr), pr = "hanui-copy-Yht5s", br = "hanui-copy__code-CYlCA", mr = "hanui-copy__button-GDdH6", gr = "hanui-copy__srOnly-WMTNN", Oe = {
2009
+ copy: pr,
1930
2010
  "copy--sm": "hanui-copy--sm-Tjqws",
1931
- copy__code: di,
2011
+ copy__code: br,
1932
2012
  "copy--md": "hanui-copy--md-00rhU",
1933
- copy__button: _i,
2013
+ copy__button: mr,
1934
2014
  "copy__button--done": "hanui-copy__button--done-MujUR",
1935
- copy__srOnly: ui
1936
- }, hi = 1600, pi = ({
2015
+ copy__srOnly: gr
2016
+ }, fr = 1600, yr = ({
1937
2017
  value: e,
1938
2018
  copyLabel: n,
1939
2019
  copiedLabel: t,
1940
2020
  copiedAnnouncement: o,
1941
- size: r = "sm",
1942
- isReadOnly: i,
2021
+ size: i = "sm",
2022
+ isReadOnly: r,
1943
2023
  className: s,
1944
- testId: l
2024
+ testId: c
1945
2025
  }) => {
1946
- const [u, p] = G(!1), m = Y(null), b = Y(void 0);
1947
- R(() => () => window.clearTimeout(b.current), []);
1948
- const c = Z(() => {
1949
- const f = m.current;
1950
- if (!f) return;
1951
- const C = document.createRange();
1952
- C.selectNodeContents(f);
1953
- const D = window.getSelection();
1954
- D == null || D.removeAllRanges(), D == null || D.addRange(C);
1955
- }, []), v = Z(async () => {
2026
+ var m, f, D, x, L;
2027
+ const { labels: l } = P(), [u, b] = Z(!1), g = Y(null), h = Y(void 0);
2028
+ F(() => () => window.clearTimeout(h.current), []);
2029
+ const p = Q(() => {
2030
+ const E = g.current;
2031
+ if (!E) return;
2032
+ const S = document.createRange();
2033
+ S.selectNodeContents(E);
2034
+ const j = window.getSelection();
2035
+ j == null || j.removeAllRanges(), j == null || j.addRange(S);
2036
+ }, []), N = Q(async () => {
1956
2037
  try {
1957
- await navigator.clipboard.writeText(e), p(!0), b.current = window.setTimeout(() => p(!1), hi);
2038
+ await navigator.clipboard.writeText(e), b(!0), h.current = window.setTimeout(() => b(!1), fr);
1958
2039
  } catch {
1959
- c();
2040
+ p();
1960
2041
  }
1961
- }, [e, c]);
1962
- return /* @__PURE__ */ _("span", { className: d(Be.copy, Be[`copy--${r}`], s), "data-testid": l, children: [
1963
- /* @__PURE__ */ a("span", { className: Be.copy__code, ref: m, children: e }),
1964
- !i && /* @__PURE__ */ a(
2042
+ }, [e, p]);
2043
+ return /* @__PURE__ */ _("span", { className: d(Oe.copy, Oe[`copy--${i}`], s), "data-testid": c, children: [
2044
+ /* @__PURE__ */ a("span", { className: Oe.copy__code, ref: g, children: e }),
2045
+ !r && /* @__PURE__ */ a(
1965
2046
  "button",
1966
2047
  {
1967
2048
  type: "button",
1968
- className: d(Be.copy__button, u && Be["copy__button--done"]),
1969
- onClick: v,
1970
- "aria-label": u ? t : n,
1971
- title: u ? t : n,
1972
- children: u ? /* @__PURE__ */ a(fn, {}) : /* @__PURE__ */ a(wn, {})
2049
+ className: d(Oe.copy__button, u && Oe["copy__button--done"]),
2050
+ onClick: N,
2051
+ "aria-label": u ? t ?? qe("CopyField.copiedLabel", (m = l == null ? void 0 : l.copyField) == null ? void 0 : m.copied, e) : n ?? qe("CopyField.copyLabel", (f = l == null ? void 0 : l.copyField) == null ? void 0 : f.copy, e),
2052
+ title: u ? t ?? qe("CopyField.copiedLabel", (D = l == null ? void 0 : l.copyField) == null ? void 0 : D.copied, e) : n ?? qe("CopyField.copyLabel", (x = l == null ? void 0 : l.copyField) == null ? void 0 : x.copy, e),
2053
+ children: u ? /* @__PURE__ */ a(kn, {}) : /* @__PURE__ */ a(Cn, {})
1973
2054
  }
1974
2055
  ),
1975
- /* @__PURE__ */ a("span", { "aria-live": "polite", className: Be.copy__srOnly, children: u ? o : "" })
2056
+ /* @__PURE__ */ a("span", { "aria-live": "polite", className: Oe.copy__srOnly, children: u ? I(
2057
+ "CopyField.copiedAnnouncement",
2058
+ o,
2059
+ (L = l == null ? void 0 : l.copyField) == null ? void 0 : L.announcement
2060
+ ) : "" })
1976
2061
  ] });
1977
- }, rc = h(pi), bi = "hanui-divider-RJqCw", mi = "hanui-divider__label-M8sBA", ea = {
1978
- divider: bi,
2062
+ }, _c = v(yr), vr = "hanui-divider-RJqCw", xr = "hanui-divider__label-M8sBA", ra = {
2063
+ divider: vr,
1979
2064
  "divider--labelled": "hanui-divider--labelled-jZH1-",
1980
- divider__label: mi
1981
- }, gi = ({ label: e, className: n }) => e ? /* @__PURE__ */ a("div", { className: d(ea.divider, ea["divider--labelled"], n), children: /* @__PURE__ */ a("span", { className: ea.divider__label, children: e }) }) : /* @__PURE__ */ a("hr", { className: d(ea.divider, n) }), sc = h(gi), fi = "hanui-directory-badEd", vi = "hanui-group-i6An9", yi = "hanui-group__header-rc19c", xi = "hanui-group__label-vQTcs", ki = "hanui-group__link-es5V7", Ni = "hanui-group__meta-LtC-u", wi = "hanui-group__list-YxBCG", $i = "hanui-row-3LH7X", Di = "hanui-row__name-75Wbq", Ci = "hanui-row__media-AxZEh", Ii = "hanui-row__marker-RYHb-", Li = "hanui-jump-vpGwB", Ei = "hanui-jump__link-rRnT6", V = {
1982
- directory: fi,
1983
- group: vi,
1984
- group__header: yi,
1985
- group__label: xi,
1986
- group__link: ki,
1987
- group__meta: Ni,
1988
- group__list: wi,
1989
- row: $i,
1990
- row__name: Di,
1991
- row__media: Ci,
1992
- row__marker: Ii,
1993
- jump: Li,
1994
- jump__link: Ei
1995
- }, Mi = ({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(V.directory, n), children: e }), Ai = h(
1996
- ({ label: e, href: n, linkProps: t, meta: o, children: r, id: i }) => /* @__PURE__ */ _("section", { className: V.group, id: i, children: [
1997
- /* @__PURE__ */ _("header", { className: V.group__header, children: [
1998
- /* @__PURE__ */ a("h2", { className: V.group__label, children: n ? /* @__PURE__ */ a(oe, { href: n, className: V.group__link, ...t, children: e }) : e }),
1999
- o && /* @__PURE__ */ a("span", { className: V.group__meta, children: o })
2065
+ divider__label: xr
2066
+ }, kr = ({ label: e, className: n }) => e ? /* @__PURE__ */ a("div", { className: d(ra.divider, ra["divider--labelled"], n), children: /* @__PURE__ */ a("span", { className: ra.divider__label, children: e }) }) : /* @__PURE__ */ a("hr", { className: d(ra.divider, n) }), uc = v(kr), Nr = "hanui-directory-badEd", wr = "hanui-group-i6An9", $r = "hanui-group__header-rc19c", Dr = "hanui-group__label-vQTcs", Lr = "hanui-group__link-es5V7", Cr = "hanui-group__meta-LtC-u", Ir = "hanui-group__list-YxBCG", Er = "hanui-row-3LH7X", Mr = "hanui-row__name-75Wbq", Tr = "hanui-row__media-AxZEh", Rr = "hanui-row__marker-RYHb-", Ar = "hanui-jump-vpGwB", Br = "hanui-jump__link-rRnT6", W = {
2067
+ directory: Nr,
2068
+ group: wr,
2069
+ group__header: $r,
2070
+ group__label: Dr,
2071
+ group__link: Lr,
2072
+ group__meta: Cr,
2073
+ group__list: Ir,
2074
+ row: Er,
2075
+ row__name: Mr,
2076
+ row__media: Tr,
2077
+ row__marker: Rr,
2078
+ jump: Ar,
2079
+ jump__link: Br
2080
+ }, Sr = ({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(W.directory, n), children: e }), Fr = v(
2081
+ ({ label: e, href: n, linkProps: t, meta: o, children: i, id: r }) => /* @__PURE__ */ _("section", { className: W.group, id: r, children: [
2082
+ /* @__PURE__ */ _("header", { className: W.group__header, children: [
2083
+ /* @__PURE__ */ a("h2", { className: W.group__label, children: n ? /* @__PURE__ */ a(le, { href: n, className: W.group__link, ...t, children: e }) : e }),
2084
+ o && /* @__PURE__ */ a("span", { className: W.group__meta, children: o })
2000
2085
  ] }),
2001
- /* @__PURE__ */ a("ul", { className: V.group__list, children: r })
2086
+ /* @__PURE__ */ a("ul", { className: W.group__list, children: i })
2002
2087
  ] })
2003
2088
  );
2004
- Ai.displayName = "DirectoryGroup";
2005
- const Ri = h(
2006
- ({ href: e, name: n, media: t, marker: o, linkProps: r, className: i }) => /* @__PURE__ */ a("li", { children: /* @__PURE__ */ _(oe, { href: e, className: d(V.row, i), ...r, children: [
2007
- t && /* @__PURE__ */ a("span", { className: V.row__media, children: t }),
2008
- /* @__PURE__ */ a("span", { className: V.row__name, children: n }),
2009
- o && /* @__PURE__ */ a("span", { className: V.row__marker, children: o })
2089
+ Fr.displayName = "DirectoryGroup";
2090
+ const Pr = v(
2091
+ ({ href: e, name: n, media: t, marker: o, linkProps: i, className: r }) => /* @__PURE__ */ a("li", { children: /* @__PURE__ */ _(le, { href: e, className: d(W.row, r), ...i, children: [
2092
+ t && /* @__PURE__ */ a("span", { className: W.row__media, children: t }),
2093
+ /* @__PURE__ */ a("span", { className: W.row__name, children: n }),
2094
+ o && /* @__PURE__ */ a("span", { className: W.row__marker, children: o })
2010
2095
  ] }) })
2011
2096
  );
2012
- Ri.displayName = "DirectoryRow";
2013
- const Ti = h(({ labels: e, toId: n, label: t }) => /* @__PURE__ */ a("nav", { className: V.jump, "aria-label": t, children: e.map((o) => /* @__PURE__ */ a("a", { href: `#${n(o)}`, className: V.jump__link, children: o }, o)) }));
2014
- Ti.displayName = "DirectoryJump";
2015
- const cc = h(Mi), Bi = "hanui-empty-47qZR", Si = "hanui-empty__icon-okfEc", Fi = "hanui-empty__title-Z7Dzd", Oi = "hanui-empty__description-6BoCk", Hi = "hanui-empty__actions-ARk-k", Se = {
2016
- empty: Bi,
2017
- empty__icon: Si,
2018
- empty__title: Fi,
2019
- empty__description: Oi,
2020
- empty__actions: Hi,
2097
+ Pr.displayName = "DirectoryRow";
2098
+ const Or = v(({ labels: e, toId: n, label: t }) => {
2099
+ const { labels: o } = P();
2100
+ return /* @__PURE__ */ a(
2101
+ "nav",
2102
+ {
2103
+ className: W.jump,
2104
+ "aria-label": I("DirectoryJump.label", t, o == null ? void 0 : o.directoryJump),
2105
+ children: e.map((i) => /* @__PURE__ */ a("a", { href: `#${n(i)}`, className: W.jump__link, children: i }, i))
2106
+ }
2107
+ );
2108
+ });
2109
+ Or.displayName = "DirectoryJump";
2110
+ const hc = v(Sr), Hr = "hanui-empty-47qZR", zr = "hanui-empty__icon-okfEc", Kr = "hanui-empty__title-Z7Dzd", qr = "hanui-empty__description-6BoCk", jr = "hanui-empty__actions-ARk-k", He = {
2111
+ empty: Hr,
2112
+ empty__icon: zr,
2113
+ empty__title: Kr,
2114
+ empty__description: qr,
2115
+ empty__actions: jr,
2021
2116
  "empty--sm": "hanui-empty--sm-QXaXx"
2022
- }, Pi = ({
2117
+ }, Gr = ({
2023
2118
  title: e,
2024
2119
  description: n,
2025
2120
  icon: t,
2026
2121
  action: o,
2027
- secondaryAction: r,
2028
- size: i = "md",
2122
+ secondaryAction: i,
2123
+ size: r = "md",
2029
2124
  className: s,
2030
- testId: l
2031
- }) => /* @__PURE__ */ _("div", { className: d(Se.empty, Se[`empty--${i}`], s), "data-testid": l, children: [
2032
- t && /* @__PURE__ */ a("span", { className: Se.empty__icon, children: t }),
2033
- /* @__PURE__ */ a("h3", { className: Se.empty__title, children: e }),
2034
- n && /* @__PURE__ */ a("p", { className: Se.empty__description, children: n }),
2035
- (o || r) && /* @__PURE__ */ _("div", { className: Se.empty__actions, children: [
2125
+ testId: c
2126
+ }) => /* @__PURE__ */ _("div", { className: d(He.empty, He[`empty--${r}`], s), "data-testid": c, children: [
2127
+ t && /* @__PURE__ */ a("span", { className: He.empty__icon, children: t }),
2128
+ /* @__PURE__ */ a("h3", { className: He.empty__title, children: e }),
2129
+ n && /* @__PURE__ */ a("p", { className: He.empty__description, children: n }),
2130
+ (o || i) && /* @__PURE__ */ _("div", { className: He.empty__actions, children: [
2036
2131
  o,
2037
- r
2132
+ i
2038
2133
  ] })
2039
- ] }), lc = h(Pi), zi = "hanui-header-yJwus", Ki = "hanui-header__top-UK4si", ji = "hanui-header__text-HIo8U", Gi = "hanui-header__eyebrow-dZ9Zc", Ui = "hanui-header__titleRow-KgDZj", qi = "hanui-header__title-s1giF", Xi = "hanui-header__meta-UxuaD", Yi = "hanui-header__description-NXbbC", Zi = "hanui-header__actions-aShpt", de = {
2040
- header: zi,
2041
- header__top: Ki,
2042
- header__text: ji,
2043
- header__eyebrow: Gi,
2044
- header__titleRow: Ui,
2045
- header__title: qi,
2046
- header__meta: Xi,
2047
- header__description: Yi,
2048
- header__actions: Zi
2049
- }, Ji = ({
2134
+ ] }), pc = v(Gr), Ur = "hanui-header-yJwus", Xr = "hanui-header__top-UK4si", Yr = "hanui-header__text-HIo8U", Zr = "hanui-header__eyebrow-dZ9Zc", Jr = "hanui-header__titleRow-KgDZj", Qr = "hanui-header__title-s1giF", Vr = "hanui-header__meta-UxuaD", Wr = "hanui-header__description-NXbbC", ei = "hanui-header__actions-aShpt", be = {
2135
+ header: Ur,
2136
+ header__top: Xr,
2137
+ header__text: Yr,
2138
+ header__eyebrow: Zr,
2139
+ header__titleRow: Jr,
2140
+ header__title: Qr,
2141
+ header__meta: Vr,
2142
+ header__description: Wr,
2143
+ header__actions: ei
2144
+ }, ai = ({
2050
2145
  title: e,
2051
2146
  eyebrow: n,
2052
2147
  description: t,
2053
2148
  actions: o,
2054
- breadcrumb: r,
2055
- meta: i,
2149
+ breadcrumb: i,
2150
+ meta: r,
2056
2151
  children: s,
2057
- as: l = "h1",
2058
- className: u,
2059
- testId: p
2060
- }) => /* @__PURE__ */ _("header", { className: d(de.header, u), "data-testid": p, children: [
2061
- r,
2062
- /* @__PURE__ */ _("div", { className: de.header__top, children: [
2063
- /* @__PURE__ */ _("div", { className: de.header__text, children: [
2064
- n && /* @__PURE__ */ a("span", { className: de.header__eyebrow, children: n }),
2065
- /* @__PURE__ */ _("div", { className: de.header__titleRow, children: [
2066
- /* @__PURE__ */ a(l, { className: de.header__title, children: e }),
2067
- i && /* @__PURE__ */ a("span", { className: de.header__meta, children: i })
2152
+ as: c = "h1",
2153
+ className: l,
2154
+ testId: u
2155
+ }) => /* @__PURE__ */ _("header", { className: d(be.header, l), "data-testid": u, children: [
2156
+ i,
2157
+ /* @__PURE__ */ _("div", { className: be.header__top, children: [
2158
+ /* @__PURE__ */ _("div", { className: be.header__text, children: [
2159
+ n && /* @__PURE__ */ a("span", { className: be.header__eyebrow, children: n }),
2160
+ /* @__PURE__ */ _("div", { className: be.header__titleRow, children: [
2161
+ /* @__PURE__ */ a(c, { className: be.header__title, children: e }),
2162
+ r && /* @__PURE__ */ a("span", { className: be.header__meta, children: r })
2068
2163
  ] }),
2069
- t && /* @__PURE__ */ a("p", { className: de.header__description, children: t })
2164
+ t && /* @__PURE__ */ a("p", { className: be.header__description, children: t })
2070
2165
  ] }),
2071
- o && /* @__PURE__ */ a("div", { className: de.header__actions, children: o })
2166
+ o && /* @__PURE__ */ a("div", { className: be.header__actions, children: o })
2072
2167
  ] }),
2073
2168
  s
2074
- ] }), dc = h(Ji), Vi = "hanui-panel-Sv-1m", Qi = "hanui-panel__header-ysexh", Wi = "hanui-panel__heading-xLCsB", er = "hanui-panel__icon--yPQT", ar = "hanui-panel__headingText--XqxW", nr = "hanui-panel__title-6-6uC", tr = "hanui-panel__description-qXTSM", or = "hanui-panel__actions-Ra-zy", ir = "hanui-panel__body-lo5aX", rr = "hanui-panel__footer-qLpR1", sr = "hanui-form-o9UqJ", cr = "hanui-row-vUGpa", X = {
2075
- panel: Vi,
2076
- panel__header: Qi,
2077
- panel__heading: Wi,
2078
- panel__icon: er,
2079
- panel__headingText: ar,
2080
- panel__title: nr,
2081
- panel__description: tr,
2082
- panel__actions: or,
2083
- panel__body: ir,
2169
+ ] }), bc = v(ai), ni = "hanui-panel-Sv-1m", ti = "hanui-panel__header-ysexh", oi = "hanui-panel__heading-xLCsB", ri = "hanui-panel__icon--yPQT", ii = "hanui-panel__headingText--XqxW", si = "hanui-panel__title-6-6uC", ci = "hanui-panel__description-qXTSM", li = "hanui-panel__actions-Ra-zy", di = "hanui-panel__body-lo5aX", _i = "hanui-panel__footer-qLpR1", ui = "hanui-form-o9UqJ", hi = "hanui-row-vUGpa", J = {
2170
+ panel: ni,
2171
+ panel__header: ti,
2172
+ panel__heading: oi,
2173
+ panel__icon: ri,
2174
+ panel__headingText: ii,
2175
+ panel__title: si,
2176
+ panel__description: ci,
2177
+ panel__actions: li,
2178
+ panel__body: di,
2084
2179
  "panel__body--sm": "hanui-panel__body--sm-6XP6W",
2085
2180
  "panel__body--lg": "hanui-panel__body--lg-RTK5B",
2086
2181
  "panel__body--flush": "hanui-panel__body--flush-iK75R",
2087
- panel__footer: rr,
2088
- form: sr,
2182
+ panel__footer: _i,
2183
+ form: ui,
2089
2184
  "form--2": "hanui-form--2-HdwDc",
2090
- row: cr
2091
- }, lr = ({
2185
+ row: hi
2186
+ }, pi = ({
2092
2187
  children: e,
2093
2188
  title: n,
2094
2189
  description: t,
2095
2190
  actions: o,
2096
- icon: r,
2097
- isFlush: i,
2191
+ icon: i,
2192
+ isFlush: r,
2098
2193
  gap: s = "md",
2099
- footer: l,
2100
- as: u = "section",
2101
- className: p,
2102
- bodyClassName: m,
2103
- testId: b
2104
- }) => /* @__PURE__ */ _(u, { className: d(X.panel, p), "data-testid": b, children: [
2105
- (n || o) && /* @__PURE__ */ _("div", { className: X.panel__header, children: [
2106
- /* @__PURE__ */ _("div", { className: X.panel__heading, children: [
2107
- r && /* @__PURE__ */ a("span", { className: X.panel__icon, children: r }),
2108
- /* @__PURE__ */ _("div", { className: X.panel__headingText, children: [
2109
- n && /* @__PURE__ */ a("h2", { className: X.panel__title, children: n }),
2110
- t && /* @__PURE__ */ a("p", { className: X.panel__description, children: t })
2194
+ footer: c,
2195
+ as: l = "section",
2196
+ className: u,
2197
+ bodyClassName: b,
2198
+ testId: g
2199
+ }) => /* @__PURE__ */ _(l, { className: d(J.panel, u), "data-testid": g, children: [
2200
+ (n || o) && /* @__PURE__ */ _("div", { className: J.panel__header, children: [
2201
+ /* @__PURE__ */ _("div", { className: J.panel__heading, children: [
2202
+ i && /* @__PURE__ */ a("span", { className: J.panel__icon, children: i }),
2203
+ /* @__PURE__ */ _("div", { className: J.panel__headingText, children: [
2204
+ n && /* @__PURE__ */ a("h2", { className: J.panel__title, children: n }),
2205
+ t && /* @__PURE__ */ a("p", { className: J.panel__description, children: t })
2111
2206
  ] })
2112
2207
  ] }),
2113
- o && /* @__PURE__ */ a("div", { className: X.panel__actions, children: o })
2208
+ o && /* @__PURE__ */ a("div", { className: J.panel__actions, children: o })
2114
2209
  ] }),
2115
2210
  /* @__PURE__ */ a(
2116
2211
  "div",
2117
2212
  {
2118
2213
  className: d(
2119
- X.panel__body,
2120
- X[`panel__body--${s}`],
2121
- i && X["panel__body--flush"],
2122
- m
2214
+ J.panel__body,
2215
+ J[`panel__body--${s}`],
2216
+ r && J["panel__body--flush"],
2217
+ b
2123
2218
  ),
2124
2219
  children: e
2125
2220
  }
2126
2221
  ),
2127
- l && /* @__PURE__ */ a("div", { className: X.panel__footer, children: l })
2128
- ] }), dr = h(({ children: e, columns: n = 1, className: t }) => /* @__PURE__ */ a("div", { className: d(X.form, X[`form--${n}`], t), children: e }));
2129
- dr.displayName = "PanelForm";
2130
- const _r = h(({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(X.row, n), children: e }));
2131
- _r.displayName = "PanelRow";
2132
- const _c = h(lr), ur = "hanui-price-Oc5Nr", hr = "hanui-price__current-2Xup2", pr = "hanui-price__currency-32NLN", br = "hanui-price__list-MlQgT", mr = "hanui-price__discount-5Yc6W", ke = {
2133
- price: ur,
2134
- price__current: hr,
2135
- price__currency: pr,
2136
- price__list: br,
2137
- price__discount: mr,
2222
+ c && /* @__PURE__ */ a("div", { className: J.panel__footer, children: c })
2223
+ ] }), bi = v(({ children: e, columns: n = 1, className: t }) => /* @__PURE__ */ a("div", { className: d(J.form, J[`form--${n}`], t), children: e }));
2224
+ bi.displayName = "PanelForm";
2225
+ const mi = v(({ children: e, className: n }) => /* @__PURE__ */ a("div", { className: d(J.row, n), children: e }));
2226
+ mi.displayName = "PanelRow";
2227
+ const mc = v(pi), gi = "hanui-price-Oc5Nr", fi = "hanui-price__current-2Xup2", yi = "hanui-price__currency-32NLN", vi = "hanui-price__list-MlQgT", xi = "hanui-price__discount-5Yc6W", De = {
2228
+ price: gi,
2229
+ price__current: fi,
2230
+ price__currency: yi,
2231
+ price__list: vi,
2232
+ price__discount: xi,
2138
2233
  "price--sm": "hanui-price--sm-Hd8Oe",
2139
2234
  "price--md": "hanui-price--md-JMxlK",
2140
2235
  "price--lg": "hanui-price--lg-TFqIF",
2141
2236
  "price--xl": "hanui-price--xl-EJBYq"
2142
- }, gr = ({
2237
+ }, ki = ({
2143
2238
  value: e,
2144
2239
  currency: n,
2145
2240
  listValue: t,
2146
2241
  discountPercent: o,
2147
- formatDiscount: r = (u) => `%${u}`,
2148
- size: i = "md",
2242
+ formatDiscount: i = (l) => `%${l}`,
2243
+ size: r = "md",
2149
2244
  className: s,
2150
- testId: l
2151
- }) => /* @__PURE__ */ _("span", { className: d(ke.price, ke[`price--${i}`], s), "data-testid": l, children: [
2152
- /* @__PURE__ */ _("span", { className: ke.price__current, children: [
2153
- e,
2154
- /* @__PURE__ */ a("span", { className: ke.price__currency, children: n })
2155
- ] }),
2156
- t && /* @__PURE__ */ _("s", { className: ke.price__list, children: [
2157
- t,
2158
- /* @__PURE__ */ a("span", { className: ke.price__currency, children: n })
2159
- ] }),
2160
- o !== void 0 && o > 0 && /* @__PURE__ */ a("span", { className: ke.price__discount, children: r(o) })
2161
- ] }), uc = h(gr), fr = "hanui-rating-94dke", vr = "hanui-rating__stars-QkpVU", yr = "hanui-rating__empty-Wf6-K", xr = "hanui-rating__count-pIoEs", kr = "hanui-rating__srOnly-E9h0d", Fe = {
2162
- rating: fr,
2163
- rating__stars: vr,
2164
- rating__empty: yr,
2165
- rating__count: xr,
2166
- rating__srOnly: kr,
2245
+ testId: c
2246
+ }) => {
2247
+ const { labels: l } = P(), u = I("Price.currency", n, l == null ? void 0 : l.currency);
2248
+ return /* @__PURE__ */ _("span", { className: d(De.price, De[`price--${r}`], s), "data-testid": c, children: [
2249
+ /* @__PURE__ */ _("span", { className: De.price__current, children: [
2250
+ e,
2251
+ /* @__PURE__ */ a("span", { className: De.price__currency, children: u })
2252
+ ] }),
2253
+ t && /* @__PURE__ */ _("s", { className: De.price__list, children: [
2254
+ t,
2255
+ /* @__PURE__ */ a("span", { className: De.price__currency, children: u })
2256
+ ] }),
2257
+ o !== void 0 && o > 0 && /* @__PURE__ */ a("span", { className: De.price__discount, children: i(o) })
2258
+ ] });
2259
+ }, gc = v(ki), Ni = "hanui-rating-94dke", wi = "hanui-rating__stars-QkpVU", $i = "hanui-rating__empty-Wf6-K", Di = "hanui-rating__count-pIoEs", Li = "hanui-rating__srOnly-E9h0d", ze = {
2260
+ rating: Ni,
2261
+ rating__stars: wi,
2262
+ rating__empty: $i,
2263
+ rating__count: Di,
2264
+ rating__srOnly: Li,
2167
2265
  "rating--sm": "hanui-rating--sm-AtY7U",
2168
2266
  "rating--md": "hanui-rating--md-Q0nxN"
2169
- }, Nr = ({ value: e, count: n, srLabel: t, size: o = "sm", className: r, testId: i }) => {
2170
- const s = Math.round(e * 2) / 2;
2171
- return /* @__PURE__ */ _("span", { className: d(Fe.rating, Fe[`rating--${o}`], r), "data-testid": i, children: [
2172
- /* @__PURE__ */ a("span", { className: Fe.rating__stars, "aria-hidden": !0, children: Array.from({ length: 5 }, (l, u) => {
2173
- const p = u + 1;
2174
- return s >= p ? /* @__PURE__ */ a(Oa, {}, u) : s >= p - 0.5 ? /* @__PURE__ */ a(Mn, {}, u) : /* @__PURE__ */ a(En, { className: Fe.rating__empty }, u);
2267
+ }, Ci = ({ value: e, count: n, srLabel: t, size: o = "sm", className: i, testId: r }) => {
2268
+ var l;
2269
+ const { labels: s } = P(), c = Math.round(e * 2) / 2;
2270
+ return /* @__PURE__ */ _("span", { className: d(ze.rating, ze[`rating--${o}`], i), "data-testid": r, children: [
2271
+ /* @__PURE__ */ a("span", { className: ze.rating__stars, "aria-hidden": !0, children: Array.from({ length: 5 }, (u, b) => {
2272
+ const g = b + 1;
2273
+ return c >= g ? /* @__PURE__ */ a(qa, {}, b) : c >= g - 0.5 ? /* @__PURE__ */ a(Bn, {}, b) : /* @__PURE__ */ a(An, { className: ze.rating__empty }, b);
2175
2274
  }) }),
2176
- /* @__PURE__ */ a("span", { className: Fe.rating__srOnly, children: t }),
2177
- Pe(n) && /* @__PURE__ */ _("span", { className: Fe.rating__count, "aria-hidden": !0, children: [
2275
+ /* @__PURE__ */ a("span", { className: ze.rating__srOnly, children: t ?? qe("Rating.srLabel", (l = s == null ? void 0 : s.rating) == null ? void 0 : l.srLabel, e, n) }),
2276
+ Ge(n) && /* @__PURE__ */ _("span", { className: ze.rating__count, "aria-hidden": !0, children: [
2178
2277
  "(",
2179
2278
  n,
2180
2279
  ")"
2181
2280
  ] })
2182
2281
  ] });
2183
- }, hc = h(Nr), wr = "hanui-header-a08Jh", $r = "hanui-header__text-ArJkA", Dr = "hanui-header__overline-X5Epo", Cr = "hanui-header__title-nQQQJ", Ir = "hanui-header__description-08oCr", Lr = "hanui-header__action-xsxQF", Ne = {
2184
- header: wr,
2185
- header__text: $r,
2186
- header__overline: Dr,
2187
- header__title: Cr,
2188
- header__description: Ir,
2189
- header__action: Lr,
2282
+ }, fc = v(Ci), Ii = "hanui-header-a08Jh", Ei = "hanui-header__text-ArJkA", Mi = "hanui-header__overline-X5Epo", Ti = "hanui-header__title-nQQQJ", Ri = "hanui-header__description-08oCr", Ai = "hanui-header__action-xsxQF", Le = {
2283
+ header: Ii,
2284
+ header__text: Ei,
2285
+ header__overline: Mi,
2286
+ header__title: Ti,
2287
+ header__description: Ri,
2288
+ header__action: Ai,
2190
2289
  "header--sm": "hanui-header--sm-mIJWZ",
2191
2290
  "header--lg": "hanui-header--lg-QBLIz"
2192
- }, Er = ({
2291
+ }, Bi = ({
2193
2292
  title: e,
2194
2293
  description: n,
2195
2294
  overline: t,
2196
2295
  action: o,
2197
- as: r = "h2",
2198
- size: i = "md",
2296
+ as: i = "h2",
2297
+ size: r = "md",
2199
2298
  className: s,
2200
- testId: l
2201
- }) => /* @__PURE__ */ _("header", { className: d(Ne.header, Ne[`header--${i}`], s), "data-testid": l, children: [
2202
- /* @__PURE__ */ _("div", { className: Ne.header__text, children: [
2203
- t && /* @__PURE__ */ a("span", { className: Ne.header__overline, children: t }),
2204
- /* @__PURE__ */ a(r, { className: Ne.header__title, children: e }),
2205
- n && /* @__PURE__ */ a("p", { className: Ne.header__description, children: n })
2299
+ testId: c
2300
+ }) => /* @__PURE__ */ _("header", { className: d(Le.header, Le[`header--${r}`], s), "data-testid": c, children: [
2301
+ /* @__PURE__ */ _("div", { className: Le.header__text, children: [
2302
+ t && /* @__PURE__ */ a("span", { className: Le.header__overline, children: t }),
2303
+ /* @__PURE__ */ a(i, { className: Le.header__title, children: e }),
2304
+ n && /* @__PURE__ */ a("p", { className: Le.header__description, children: n })
2206
2305
  ] }),
2207
- o && /* @__PURE__ */ a("div", { className: Ne.header__action, children: o })
2208
- ] }), pc = h(Er), Mr = "hanui-skeleton-n92if", Ar = "hanui-group-YMfwa", qe = {
2209
- skeleton: Mr,
2306
+ o && /* @__PURE__ */ a("div", { className: Le.header__action, children: o })
2307
+ ] }), yc = v(Bi), Si = "hanui-skeleton-n92if", Fi = "hanui-group-YMfwa", Qe = {
2308
+ skeleton: Si,
2210
2309
  "hanui-shimmer": "hanui-hanui-shimmer-6yd48",
2211
2310
  "skeleton--block": "hanui-skeleton--block-tOZ-a",
2212
2311
  "skeleton--text": "hanui-skeleton--text-k-ROi",
2213
2312
  "skeleton--circle": "hanui-skeleton--circle-x-mX3",
2214
- group: Ar
2215
- }, Rr = ({ width: e, height: n, variant: t = "block", lines: o = 1, className: r }) => {
2216
- const i = {
2217
- width: pa(e) ? `${e}px` : e,
2218
- height: pa(n) ? `${n}px` : n
2313
+ group: Fi
2314
+ }, Pi = ({ width: e, height: n, variant: t = "block", lines: o = 1, className: i }) => {
2315
+ const r = {
2316
+ width: ya(e) ? `${e}px` : e,
2317
+ height: ya(n) ? `${n}px` : n
2219
2318
  };
2220
- return t === "text" && o > 1 ? /* @__PURE__ */ a("span", { className: d(qe.group, r), "aria-hidden": !0, children: Array.from({ length: o }, (s, l) => /* @__PURE__ */ a(
2319
+ return t === "text" && o > 1 ? /* @__PURE__ */ a("span", { className: d(Qe.group, i), "aria-hidden": !0, children: Array.from({ length: o }, (s, c) => /* @__PURE__ */ a(
2221
2320
  "span",
2222
2321
  {
2223
- className: d(qe.skeleton, qe["skeleton--text"]),
2224
- style: l === o - 1 ? { width: "60%" } : void 0
2322
+ className: d(Qe.skeleton, Qe["skeleton--text"]),
2323
+ style: c === o - 1 ? { width: "60%" } : void 0
2225
2324
  },
2226
- l
2325
+ c
2227
2326
  )) }) : /* @__PURE__ */ a(
2228
2327
  "span",
2229
2328
  {
2230
- className: d(qe.skeleton, qe[`skeleton--${t}`], r),
2231
- style: i,
2329
+ className: d(Qe.skeleton, Qe[`skeleton--${t}`], i),
2330
+ style: r,
2232
2331
  "aria-hidden": !0
2233
2332
  }
2234
2333
  );
2235
- }, bc = h(Rr), Tr = "hanui-tabs-l4dFE", Br = "hanui-tabs__list-HJvR8", Sr = "hanui-tabs__tab-7gDW7", Fr = "hanui-tabs__count-8JX8s", Or = "hanui-tabs__panel-CPklY", Oe = {
2236
- tabs: Tr,
2237
- tabs__list: Br,
2238
- tabs__tab: Sr,
2334
+ }, vc = v(Pi), Oi = "hanui-tabs-l4dFE", Hi = "hanui-tabs__list-HJvR8", zi = "hanui-tabs__tab-7gDW7", Ki = "hanui-tabs__count-8JX8s", qi = "hanui-tabs__panel-CPklY", Ke = {
2335
+ tabs: Oi,
2336
+ tabs__list: Hi,
2337
+ tabs__tab: zi,
2239
2338
  "tabs__tab--active": "hanui-tabs__tab--active-riqNp",
2240
- tabs__count: Fr,
2241
- tabs__panel: Or
2242
- }, Hr = ({
2339
+ tabs__count: Ki,
2340
+ tabs__panel: qi
2341
+ }, ji = ({
2243
2342
  items: e,
2244
2343
  defaultTabId: n,
2245
2344
  activeId: t,
2246
2345
  onChange: o,
2247
- ariaLabel: r,
2248
- className: i,
2346
+ ariaLabel: i,
2347
+ className: r,
2249
2348
  testId: s
2250
2349
  }) => {
2251
- var $;
2252
- const l = te(), [u, p] = G(n ?? (($ = e[0]) == null ? void 0 : $.id)), m = Pe(t), b = m ? t : u, c = e.findIndex((N) => N.id === b), v = e[c] ?? e[0], f = (N) => {
2253
- m || p(N), o == null || o(N);
2254
- }, C = (N) => {
2255
- var q;
2256
- const E = N.key === "ArrowRight" ? 1 : N.key === "ArrowLeft" ? -1 : 0;
2257
- if (E === 0) return;
2258
- N.preventDefault();
2259
- const U = (c + E + e.length) % e.length;
2260
- f(e[U].id), (q = document.getElementById(`${l}-tab-${e[U].id}`)) == null || q.focus();
2350
+ var D;
2351
+ const c = ce(), [l, u] = Z(n ?? ((D = e[0]) == null ? void 0 : D.id)), b = Ge(t), g = b ? t : l, h = e.findIndex((x) => x.id === g), p = e[h] ?? e[0], N = (x) => {
2352
+ b || u(x), o == null || o(x);
2353
+ }, m = (x) => {
2354
+ var S;
2355
+ const L = x.key === "ArrowRight" ? 1 : x.key === "ArrowLeft" ? -1 : 0;
2356
+ if (L === 0) return;
2357
+ x.preventDefault();
2358
+ const E = (h + L + e.length) % e.length;
2359
+ N(e[E].id), (S = document.getElementById(`${c}-tab-${e[E].id}`)) == null || S.focus();
2261
2360
  };
2262
2361
  if (e.length === 0) return null;
2263
- const D = Pe(v == null ? void 0 : v.content);
2264
- return /* @__PURE__ */ _("div", { className: d(Oe.tabs, i), "data-testid": s, children: [
2362
+ const f = Ge(p == null ? void 0 : p.content);
2363
+ return /* @__PURE__ */ _("div", { className: d(Ke.tabs, r), "data-testid": s, children: [
2265
2364
  /* @__PURE__ */ a(
2266
2365
  "div",
2267
2366
  {
2268
- className: Oe.tabs__list,
2367
+ className: Ke.tabs__list,
2269
2368
  role: "tablist",
2270
- "aria-label": r,
2271
- onKeyDown: C,
2272
- children: e.map((N) => {
2273
- const E = N.id === v.id;
2369
+ "aria-label": i,
2370
+ onKeyDown: m,
2371
+ children: e.map((x) => {
2372
+ const L = x.id === p.id;
2274
2373
  return /* @__PURE__ */ _(
2275
2374
  "button",
2276
2375
  {
2277
- id: `${l}-tab-${N.id}`,
2376
+ id: `${c}-tab-${x.id}`,
2278
2377
  type: "button",
2279
2378
  role: "tab",
2280
- "aria-selected": E,
2281
- "aria-controls": D ? `${l}-panel-${N.id}` : void 0,
2282
- tabIndex: E ? 0 : -1,
2283
- className: d(Oe.tabs__tab, E && Oe["tabs__tab--active"]),
2284
- onClick: () => f(N.id),
2379
+ "aria-selected": L,
2380
+ "aria-controls": f ? `${c}-panel-${x.id}` : void 0,
2381
+ tabIndex: L ? 0 : -1,
2382
+ className: d(Ke.tabs__tab, L && Ke["tabs__tab--active"]),
2383
+ onClick: () => N(x.id),
2285
2384
  children: [
2286
- N.label,
2287
- Pe(N.count) && /* @__PURE__ */ a("span", { className: Oe.tabs__count, children: N.count })
2385
+ x.label,
2386
+ Ge(x.count) && /* @__PURE__ */ a("span", { className: Ke.tabs__count, children: x.count })
2288
2387
  ]
2289
2388
  },
2290
- N.id
2389
+ x.id
2291
2390
  );
2292
2391
  })
2293
2392
  }
2294
2393
  ),
2295
- D && /* @__PURE__ */ a(
2394
+ f && /* @__PURE__ */ a(
2296
2395
  "div",
2297
2396
  {
2298
- id: `${l}-panel-${v.id}`,
2397
+ id: `${c}-panel-${p.id}`,
2299
2398
  role: "tabpanel",
2300
- "aria-labelledby": `${l}-tab-${v.id}`,
2301
- className: Oe.tabs__panel,
2399
+ "aria-labelledby": `${c}-tab-${p.id}`,
2400
+ className: Ke.tabs__panel,
2302
2401
  tabIndex: 0,
2303
- children: v.content
2402
+ children: p.content
2304
2403
  }
2305
2404
  )
2306
2405
  ] });
2307
- }, mc = h(Hr), Pr = "hanui-tile-TGur-", zr = "hanui-tile__medallion--Y0pz", Kr = "hanui-tile__label-mI1OQ", jr = "hanui-tile__meta-22qnR", Xe = {
2308
- tile: Pr,
2309
- tile__medallion: zr,
2310
- tile__label: Kr,
2311
- tile__meta: jr,
2406
+ }, xc = v(ji), Gi = "hanui-tile-TGur-", Ui = "hanui-tile__medallion--Y0pz", Xi = "hanui-tile__label-mI1OQ", Yi = "hanui-tile__meta-22qnR", Ve = {
2407
+ tile: Gi,
2408
+ tile__medallion: Ui,
2409
+ tile__label: Xi,
2410
+ tile__meta: Yi,
2312
2411
  "tile--active": "hanui-tile--active-z0F2M"
2313
- }, Gr = ({ label: e, icon: n, href: t, meta: o, isActive: r, linkProps: i, className: s, testId: l }) => /* @__PURE__ */ _(
2314
- oe,
2412
+ }, Zi = ({ label: e, icon: n, href: t, meta: o, isActive: i, linkProps: r, className: s, testId: c }) => /* @__PURE__ */ _(
2413
+ le,
2315
2414
  {
2316
2415
  href: t,
2317
- className: d(Xe.tile, r && Xe["tile--active"], s),
2318
- "aria-current": r ? "page" : void 0,
2319
- "data-testid": l,
2320
- ...i,
2416
+ className: d(Ve.tile, i && Ve["tile--active"], s),
2417
+ "aria-current": i ? "page" : void 0,
2418
+ "data-testid": c,
2419
+ ...r,
2321
2420
  children: [
2322
- /* @__PURE__ */ a("span", { className: Xe.tile__medallion, "aria-hidden": !0, children: n }),
2323
- /* @__PURE__ */ a("span", { className: Xe.tile__label, children: e }),
2324
- o && /* @__PURE__ */ a("span", { className: Xe.tile__meta, children: o })
2421
+ /* @__PURE__ */ a("span", { className: Ve.tile__medallion, "aria-hidden": !0, children: n }),
2422
+ /* @__PURE__ */ a("span", { className: Ve.tile__label, children: e }),
2423
+ o && /* @__PURE__ */ a("span", { className: Ve.tile__meta, children: o })
2325
2424
  ]
2326
2425
  }
2327
- ), gc = h(Gr), Ur = "hanui-modal-3IDi9", qr = "hanui-modal__panel--qLSz", Xr = "hanui-modal__header-meWm6", Yr = "hanui-modal__icon-df2dd", Zr = "hanui-modal__heading-PwDS8", Jr = "hanui-modal__title-80Sh6", Vr = "hanui-modal__description-fsCHI", Qr = "hanui-modal__close-vFPbw", Wr = "hanui-modal__body-PDF12", es = "hanui-modal__footer-CCCkx", Q = {
2328
- modal: Ur,
2426
+ ), kc = v(Zi), Ji = "hanui-modal-3IDi9", Qi = "hanui-modal__panel--qLSz", Vi = "hanui-modal__header-meWm6", Wi = "hanui-modal__icon-df2dd", es = "hanui-modal__heading-PwDS8", as = "hanui-modal__title-80Sh6", ns = "hanui-modal__description-fsCHI", ts = "hanui-modal__close-vFPbw", os = "hanui-modal__body-PDF12", rs = "hanui-modal__footer-CCCkx", ae = {
2427
+ modal: Ji,
2329
2428
  "modal--sm": "hanui-modal--sm-A7WsS",
2330
2429
  "modal--lg": "hanui-modal--lg-z99Em",
2331
2430
  "hanui-fade-in": "hanui-hanui-fade-in-oHUfh",
2332
2431
  "hanui-fade-in-up": "hanui-hanui-fade-in-up-RF4Hl",
2333
2432
  "hanui-slide-up": "hanui-hanui-slide-up-ibKAg",
2334
- modal__panel: qr,
2335
- modal__header: Xr,
2336
- modal__icon: Yr,
2433
+ modal__panel: Qi,
2434
+ modal__header: Vi,
2435
+ modal__icon: Wi,
2337
2436
  "modal__icon--neutral": "hanui-modal__icon--neutral-QSL7c",
2338
2437
  "modal__icon--danger": "hanui-modal__icon--danger-6V90a",
2339
2438
  "modal__icon--warning": "hanui-modal__icon--warning-a--FX",
2340
2439
  "modal__icon--success": "hanui-modal__icon--success-YWxZs",
2341
2440
  "modal__icon--info": "hanui-modal__icon--info-WRLah",
2342
- modal__heading: Zr,
2343
- modal__title: Jr,
2344
- modal__description: Vr,
2345
- modal__close: Qr,
2346
- modal__body: Wr,
2347
- modal__footer: es
2348
- }, as = ({
2441
+ modal__heading: es,
2442
+ modal__title: as,
2443
+ modal__description: ns,
2444
+ modal__close: ts,
2445
+ modal__body: os,
2446
+ modal__footer: rs
2447
+ }, is = ({
2349
2448
  isOpen: e,
2350
2449
  onClose: n,
2351
2450
  title: t,
2352
2451
  closeLabel: o,
2353
- children: r,
2354
- description: i,
2452
+ children: i,
2453
+ description: r,
2355
2454
  footer: s,
2356
- icon: l,
2357
- tone: u = "neutral",
2358
- size: p = "md",
2359
- isDismissable: m = !0,
2360
- className: b,
2361
- testId: c
2455
+ icon: c,
2456
+ tone: l = "neutral",
2457
+ size: u = "md",
2458
+ isDismissable: b = !0,
2459
+ className: g,
2460
+ testId: h
2362
2461
  }) => {
2363
- const v = Y(null), f = te(), C = te();
2364
- R(() => {
2365
- const $ = v.current;
2366
- $ && (e && !$.open && ($.showModal(), La($)), !e && $.open && $.close());
2367
- }, [e]), R(() => {
2462
+ const { labels: p } = P(), N = Y(null), m = ce(), f = ce();
2463
+ F(() => {
2464
+ const x = N.current;
2465
+ x && (e && !x.open && (x.showModal(), Aa(x)), !e && x.open && x.close());
2466
+ }, [e]), F(() => {
2368
2467
  if (!e) return;
2369
- const $ = document.body.style.overflow;
2468
+ const x = document.body.style.overflow;
2370
2469
  return document.body.style.overflow = "hidden", () => {
2371
- document.body.style.overflow = $;
2470
+ document.body.style.overflow = x;
2372
2471
  };
2373
- }, [e]), R(() => {
2374
- const $ = v.current;
2375
- if (!$) return;
2376
- const N = (E) => {
2377
- E.preventDefault(), m && n();
2472
+ }, [e]), F(() => {
2473
+ const x = N.current;
2474
+ if (!x) return;
2475
+ const L = (E) => {
2476
+ E.preventDefault(), b && n();
2378
2477
  };
2379
- return $.addEventListener("cancel", N), () => $.removeEventListener("cancel", N);
2380
- }, [n, m]);
2381
- const D = Z(
2382
- ($) => {
2383
- m && $.target === v.current && n();
2478
+ return x.addEventListener("cancel", L), () => x.removeEventListener("cancel", L);
2479
+ }, [n, b]);
2480
+ const D = Q(
2481
+ (x) => {
2482
+ b && x.target === N.current && n();
2384
2483
  },
2385
- [m, n]
2484
+ [b, n]
2386
2485
  );
2387
2486
  return /* @__PURE__ */ a(
2388
2487
  "dialog",
2389
2488
  {
2390
- ref: v,
2391
- className: d(Q.modal, Q[`modal--${p}`], b),
2392
- "aria-labelledby": f,
2393
- "aria-describedby": i ? C : void 0,
2394
- "data-testid": c,
2489
+ ref: N,
2490
+ className: d(ae.modal, ae[`modal--${u}`], g),
2491
+ "aria-labelledby": m,
2492
+ "aria-describedby": r ? f : void 0,
2493
+ "data-testid": h,
2395
2494
  onClick: D,
2396
- children: /* @__PURE__ */ _("div", { className: Q.modal__panel, children: [
2397
- /* @__PURE__ */ _("header", { className: Q.modal__header, children: [
2398
- l && /* @__PURE__ */ a("span", { className: d(Q.modal__icon, Q[`modal__icon--${u}`]), children: l }),
2399
- /* @__PURE__ */ _("div", { className: Q.modal__heading, children: [
2400
- /* @__PURE__ */ a("h2", { id: f, className: Q.modal__title, children: t }),
2401
- i && /* @__PURE__ */ a("p", { id: C, className: Q.modal__description, children: i })
2495
+ children: /* @__PURE__ */ _("div", { className: ae.modal__panel, children: [
2496
+ /* @__PURE__ */ _("header", { className: ae.modal__header, children: [
2497
+ c && /* @__PURE__ */ a("span", { className: d(ae.modal__icon, ae[`modal__icon--${l}`]), children: c }),
2498
+ /* @__PURE__ */ _("div", { className: ae.modal__heading, children: [
2499
+ /* @__PURE__ */ a("h2", { id: m, className: ae.modal__title, children: t }),
2500
+ r && /* @__PURE__ */ a("p", { id: f, className: ae.modal__description, children: r })
2402
2501
  ] }),
2403
- m && /* @__PURE__ */ a(
2404
- ta,
2502
+ b && /* @__PURE__ */ a(
2503
+ ca,
2405
2504
  {
2406
- icon: /* @__PURE__ */ a(la, {}),
2407
- label: o,
2505
+ icon: /* @__PURE__ */ a(pa, {}),
2506
+ label: I("Modal.closeLabel", o, p == null ? void 0 : p.close),
2408
2507
  variant: "ghost",
2409
2508
  size: "sm",
2410
- className: Q.modal__close,
2509
+ className: ae.modal__close,
2411
2510
  onClick: n
2412
2511
  }
2413
2512
  )
2414
2513
  ] }),
2415
- r && /* @__PURE__ */ a("div", { className: Q.modal__body, children: r }),
2416
- s && /* @__PURE__ */ a("footer", { className: Q.modal__footer, children: s })
2514
+ i && /* @__PURE__ */ a("div", { className: ae.modal__body, children: i }),
2515
+ s && /* @__PURE__ */ a("footer", { className: ae.modal__footer, children: s })
2417
2516
  ] })
2418
2517
  }
2419
2518
  );
2420
- }, qa = h(as), ns = {
2421
- destructive: /* @__PURE__ */ a(Ln, {}),
2422
- warning: /* @__PURE__ */ a(Sa, {}),
2423
- neutral: /* @__PURE__ */ a(In, {})
2424
- }, ts = {
2519
+ }, Qa = v(is), ss = {
2520
+ destructive: /* @__PURE__ */ a(Rn, {}),
2521
+ warning: /* @__PURE__ */ a(za, {}),
2522
+ neutral: /* @__PURE__ */ a(Tn, {})
2523
+ }, cs = {
2425
2524
  destructive: "danger",
2426
2525
  warning: "warning",
2427
2526
  neutral: "info"
2428
- }, os = {
2429
- destructive: ue.DANGER,
2430
- warning: ue.PRIMARY,
2431
- neutral: ue.PRIMARY
2432
- }, is = ({
2527
+ }, ls = {
2528
+ destructive: ge.DANGER,
2529
+ warning: ge.PRIMARY,
2530
+ neutral: ge.PRIMARY
2531
+ }, ds = ({
2433
2532
  isOpen: e,
2434
2533
  onClose: n,
2435
2534
  onConfirm: t,
2436
2535
  title: o,
2437
- description: r,
2438
- confirmLabel: i,
2536
+ description: i,
2537
+ confirmLabel: r,
2439
2538
  cancelLabel: s,
2440
- closeLabel: l,
2441
- kind: u = "neutral",
2442
- children: p
2539
+ closeLabel: c,
2540
+ kind: l = "neutral",
2541
+ children: u
2443
2542
  }) => {
2444
- const [m, b] = G(!1), c = async () => {
2445
- b(!0);
2543
+ const { labels: b } = P(), [g, h] = Z(!1), p = async () => {
2544
+ h(!0);
2446
2545
  try {
2447
2546
  await t();
2448
2547
  } finally {
2449
- b(!1);
2548
+ h(!1);
2450
2549
  }
2451
2550
  };
2452
2551
  return /* @__PURE__ */ a(
2453
- qa,
2552
+ Qa,
2454
2553
  {
2455
2554
  isOpen: e,
2456
2555
  onClose: n,
2457
2556
  title: o,
2458
- closeLabel: l,
2459
- description: r,
2460
- icon: ns[u],
2461
- tone: ts[u],
2557
+ closeLabel: c ?? (b == null ? void 0 : b.close),
2558
+ description: i,
2559
+ icon: ss[l],
2560
+ tone: cs[l],
2462
2561
  size: "sm",
2463
- isDismissable: !m,
2464
- footer: /* @__PURE__ */ _(Je, { children: [
2562
+ isDismissable: !g,
2563
+ footer: /* @__PURE__ */ _(aa, { children: [
2465
2564
  /* @__PURE__ */ a(
2466
- Ze,
2565
+ ea,
2467
2566
  {
2468
- variant: ue.SECONDARY,
2469
- size: Ie.MEDIUM,
2567
+ variant: ge.SECONDARY,
2568
+ size: Te.MEDIUM,
2470
2569
  onClick: n,
2471
- disabled: m,
2472
- children: s
2570
+ disabled: g,
2571
+ children: I("ConfirmDialog.cancelLabel", s, b == null ? void 0 : b.cancel)
2473
2572
  }
2474
2573
  ),
2475
2574
  /* @__PURE__ */ a(
2476
- Ze,
2575
+ ea,
2477
2576
  {
2478
- variant: os[u],
2479
- size: Ie.MEDIUM,
2480
- onClick: c,
2481
- isLoading: m,
2482
- children: i
2577
+ variant: ls[l],
2578
+ size: Te.MEDIUM,
2579
+ onClick: p,
2580
+ isLoading: g,
2581
+ children: r
2483
2582
  }
2484
2583
  )
2485
2584
  ] }),
2486
- children: p
2585
+ children: u
2487
2586
  }
2488
2587
  );
2489
- }, fc = h(is), rs = "hanui-form-zpZn4", ss = {
2490
- form: rs
2491
- }, cs = ({
2588
+ }, Nc = v(ds), _s = "hanui-form-zpZn4", us = {
2589
+ form: _s
2590
+ }, hs = ({
2492
2591
  isOpen: e,
2493
2592
  onClose: n,
2494
2593
  onSubmit: t,
2495
2594
  title: o,
2496
- label: r,
2497
- submitLabel: i,
2595
+ label: i,
2596
+ submitLabel: r,
2498
2597
  cancelLabel: s,
2499
- closeLabel: l,
2500
- description: u,
2501
- hint: p,
2502
- placeholder: m,
2503
- defaultValue: b = "",
2504
- isRequired: c,
2505
- requiredLabel: v,
2506
- inputMode: f = "text",
2507
- maxLength: C,
2508
- rows: D = 4
2598
+ closeLabel: c,
2599
+ description: l,
2600
+ hint: u,
2601
+ placeholder: b,
2602
+ defaultValue: g = "",
2603
+ isRequired: h,
2604
+ requiredLabel: p,
2605
+ inputMode: N = "text",
2606
+ maxLength: m,
2607
+ rows: f = 4
2509
2608
  }) => {
2510
- const $ = te(), [N, E] = G(b), [U, q] = G(!1), I = Y(!1);
2511
- R(() => {
2512
- e && !I.current && E(b), I.current = e;
2513
- }, [e, b]);
2514
- const he = N.trim(), A = !!c && he === "", z = (H) => f === "multiline" ? /* @__PURE__ */ a(
2515
- ko,
2609
+ const { labels: D } = P(), x = ce(), [L, E] = Z(g), [S, j] = Z(!1), te = Y(!1);
2610
+ F(() => {
2611
+ e && !te.current && E(g), te.current = e;
2612
+ }, [e, g]);
2613
+ const B = L.trim(), oe = !!h && B === "", M = (H) => N === "multiline" ? /* @__PURE__ */ a(
2614
+ Do,
2516
2615
  {
2517
2616
  ...H,
2518
- value: N,
2519
- onChange: (K) => E(K.target.value),
2520
- placeholder: m,
2521
- maxLength: C,
2522
- rows: D
2617
+ value: L,
2618
+ onChange: (U) => E(U.target.value),
2619
+ placeholder: b,
2620
+ maxLength: m,
2621
+ rows: f
2523
2622
  }
2524
2623
  ) : /* @__PURE__ */ a(
2525
- vo,
2624
+ No,
2526
2625
  {
2527
2626
  ...H,
2528
- type: f === "number" ? "number" : "text",
2529
- value: N,
2530
- onChange: (K) => E(K.target.value),
2531
- placeholder: m,
2532
- maxLength: C
2627
+ type: N === "number" ? "number" : "text",
2628
+ value: L,
2629
+ onChange: (U) => E(U.target.value),
2630
+ placeholder: b,
2631
+ maxLength: m
2533
2632
  }
2534
- ), O = async () => {
2535
- if (!(A || U)) {
2536
- q(!0);
2633
+ ), A = async () => {
2634
+ if (!(oe || S)) {
2635
+ j(!0);
2537
2636
  try {
2538
- await t(he), n();
2637
+ await t(B), n();
2539
2638
  } catch {
2540
2639
  } finally {
2541
- q(!1);
2640
+ j(!1);
2542
2641
  }
2543
2642
  }
2544
2643
  };
2545
2644
  return /* @__PURE__ */ a(
2546
- qa,
2645
+ Qa,
2547
2646
  {
2548
2647
  isOpen: e,
2549
2648
  onClose: n,
2550
2649
  title: o,
2551
- closeLabel: l,
2552
- description: u,
2650
+ closeLabel: c ?? (D == null ? void 0 : D.close),
2651
+ description: l,
2553
2652
  size: "sm",
2554
- isDismissable: !U,
2555
- footer: /* @__PURE__ */ _(Je, { children: [
2653
+ isDismissable: !S,
2654
+ footer: /* @__PURE__ */ _(aa, { children: [
2556
2655
  /* @__PURE__ */ a(
2557
- Ze,
2656
+ ea,
2558
2657
  {
2559
- variant: ue.SECONDARY,
2560
- size: Ie.MEDIUM,
2658
+ variant: ge.SECONDARY,
2659
+ size: Te.MEDIUM,
2561
2660
  onClick: n,
2562
- disabled: U,
2563
- children: s
2661
+ disabled: S,
2662
+ children: I("PromptDialog.cancelLabel", s, D == null ? void 0 : D.cancel)
2564
2663
  }
2565
2664
  ),
2566
2665
  /* @__PURE__ */ a(
2567
- Ze,
2666
+ ea,
2568
2667
  {
2569
2668
  type: "submit",
2570
- form: $,
2571
- variant: ue.PRIMARY,
2572
- size: Ie.MEDIUM,
2573
- disabled: A,
2574
- isLoading: U,
2575
- children: i
2669
+ form: x,
2670
+ variant: ge.PRIMARY,
2671
+ size: Te.MEDIUM,
2672
+ disabled: oe,
2673
+ isLoading: S,
2674
+ children: I("PromptDialog.submitLabel", r, D == null ? void 0 : D.submit)
2576
2675
  }
2577
2676
  )
2578
2677
  ] }),
2579
2678
  children: /* @__PURE__ */ a(
2580
2679
  "form",
2581
2680
  {
2582
- id: $,
2583
- className: ss.form,
2681
+ id: x,
2682
+ className: us.form,
2584
2683
  onSubmit: (H) => {
2585
- H.preventDefault(), O();
2684
+ H.preventDefault(), A();
2586
2685
  },
2587
- children: c ? /* @__PURE__ */ a(xa, { label: r, hint: p, isRequired: !0, requiredLabel: v, children: z }) : /* @__PURE__ */ a(xa, { label: r, hint: p, children: z })
2686
+ children: /* @__PURE__ */ a(Ao, { label: i, hint: u, isRequired: h, requiredLabel: p, children: M })
2588
2687
  }
2589
2688
  )
2590
2689
  }
2591
2690
  );
2592
- }, vc = h(cs), ls = "hanui-scroller-EtDmS", ds = "hanui-table-uCv4q", He = {
2593
- scroller: ls,
2691
+ }, wc = v(hs), ps = "hanui-scroller-EtDmS", bs = "hanui-table-uCv4q", je = {
2692
+ scroller: ps,
2594
2693
  "scroller--frame": "hanui-scroller--frame-84zz6",
2595
- table: ds,
2694
+ table: bs,
2596
2695
  "table--compact": "hanui-table--compact-4KCVl",
2597
2696
  "table--regular": "hanui-table--regular-hsA3-",
2598
2697
  "table--spacious": "hanui-table--spacious-BBUX-",
2599
2698
  "table--sticky-head": "hanui-table--sticky-head-FO2L4",
2600
2699
  "table--row-hover": "hanui-table--row-hover--MAoe"
2601
- }, _s = h(
2700
+ }, ms = v(
2602
2701
  ({ hasFrame: e = !0, className: n, children: t, ...o }) => /* @__PURE__ */ a(
2603
2702
  "div",
2604
2703
  {
2605
- className: d(He.scroller, e && He["scroller--frame"], n),
2704
+ className: d(je.scroller, e && je["scroller--frame"], n),
2606
2705
  ...o,
2607
2706
  children: t
2608
2707
  }
2609
2708
  )
2610
2709
  );
2611
- _s.displayName = "TableScroller";
2612
- const us = ({
2710
+ ms.displayName = "TableScroller";
2711
+ const gs = ({
2613
2712
  density: e = "regular",
2614
2713
  hasStickyHead: n,
2615
2714
  hasRowHover: t,
2616
2715
  className: o,
2617
- children: r,
2618
- ...i
2716
+ children: i,
2717
+ ...r
2619
2718
  }) => /* @__PURE__ */ a(
2620
2719
  "table",
2621
2720
  {
2622
2721
  className: d(
2623
- He.table,
2624
- He[`table--${e}`],
2625
- n && He["table--sticky-head"],
2626
- t && He["table--row-hover"],
2722
+ je.table,
2723
+ je[`table--${e}`],
2724
+ n && je["table--sticky-head"],
2725
+ t && je["table--row-hover"],
2627
2726
  o
2628
2727
  ),
2629
- ...i,
2630
- children: r
2728
+ ...r,
2729
+ children: i
2631
2730
  }
2632
- ), yc = h(us), hs = "hanui-wrapper-KXCZg", ps = "hanui-table-LF5Ow", bs = "hanui-state-YPPb0", ms = "hanui-state__message-wwbIW", we = {
2633
- wrapper: hs,
2731
+ ), $c = v(gs), fs = "hanui-wrapper-KXCZg", ys = "hanui-table-LF5Ow", vs = "hanui-state-YPPb0", xs = "hanui-state__message-wwbIW", Ce = {
2732
+ wrapper: fs,
2634
2733
  "wrapper--capped": "hanui-wrapper--capped-M2QUJ",
2635
- table: ps,
2636
- state: bs,
2734
+ table: ys,
2735
+ state: vs,
2637
2736
  "state--error": "hanui-state--error-A492d",
2638
- state__message: ms,
2737
+ state__message: xs,
2639
2738
  "row--warning": "hanui-row--warning-BAUN2"
2640
- }, gs = ({
2739
+ }, ks = ({
2641
2740
  columns: e,
2642
2741
  children: n,
2643
2742
  isLoading: t,
2644
2743
  error: o,
2645
- emptyMessage: r,
2646
- loadingMessage: i,
2744
+ emptyMessage: i,
2745
+ loadingMessage: r,
2647
2746
  hasViewportCap: s,
2648
- className: l,
2649
- testId: u
2747
+ className: c,
2748
+ testId: l
2650
2749
  }) => {
2651
- const p = Va.count(n), m = (b, c) => /* @__PURE__ */ a("tr", { children: /* @__PURE__ */ a(
2750
+ var h, p;
2751
+ const { labels: u } = P(), b = nn.count(n), g = (N, m) => /* @__PURE__ */ a("tr", { children: /* @__PURE__ */ a(
2652
2752
  "td",
2653
2753
  {
2654
2754
  colSpan: e.length,
2655
- className: d(we.state, c && we[`state--${c}`]),
2656
- children: b
2755
+ className: d(Ce.state, m && Ce[`state--${m}`]),
2756
+ children: N
2657
2757
  }
2658
2758
  ) });
2659
2759
  return /* @__PURE__ */ a(
2660
2760
  "div",
2661
2761
  {
2662
- className: d(we.wrapper, s && we["wrapper--capped"], l),
2663
- "data-testid": u,
2664
- children: /* @__PURE__ */ _("table", { className: we.table, children: [
2665
- /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ a("tr", { children: e.map((b) => /* @__PURE__ */ a(
2762
+ className: d(Ce.wrapper, s && Ce["wrapper--capped"], c),
2763
+ "data-testid": l,
2764
+ children: /* @__PURE__ */ _("table", { className: Ce.table, children: [
2765
+ /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ a("tr", { children: e.map((N) => /* @__PURE__ */ a(
2666
2766
  "th",
2667
2767
  {
2668
2768
  scope: "col",
2669
- "aria-label": b.srLabel,
2670
- "aria-sort": b.ariaSort,
2671
- className: b.className,
2672
- children: b.label
2769
+ "aria-label": N.srLabel,
2770
+ "aria-sort": N.ariaSort,
2771
+ className: N.className,
2772
+ children: N.label
2673
2773
  },
2674
- b.key
2774
+ N.key
2675
2775
  )) }) }),
2676
- /* @__PURE__ */ a("tbody", { children: o ? m(
2677
- /* @__PURE__ */ _("span", { role: "alert", className: we.state__message, children: [
2678
- /* @__PURE__ */ a(Fa, {}),
2776
+ /* @__PURE__ */ a("tbody", { children: o ? g(
2777
+ /* @__PURE__ */ _("span", { role: "alert", className: Ce.state__message, children: [
2778
+ /* @__PURE__ */ a(Ka, {}),
2679
2779
  o
2680
2780
  ] }),
2681
2781
  "error"
2682
- ) : t ? m(i) : p === 0 ? m(r) : n })
2782
+ ) : t ? g(
2783
+ I(
2784
+ "DataTable.loadingMessage",
2785
+ r,
2786
+ (h = u == null ? void 0 : u.dataTable) == null ? void 0 : h.loading
2787
+ )
2788
+ ) : b === 0 ? g(
2789
+ I("DataTable.emptyMessage", i, (p = u == null ? void 0 : u.dataTable) == null ? void 0 : p.empty)
2790
+ ) : n })
2683
2791
  ] })
2684
2792
  }
2685
2793
  );
2686
- }, fs = h(({ isWarning: e, className: n, children: t, ...o }) => /* @__PURE__ */ a("tr", { className: d(e && we["row--warning"], n), ...o, children: t }));
2687
- fs.displayName = "DataTableRow";
2688
- const xc = h(gs), vs = "hanui-bar-b4PP4", ys = "hanui-bar__hiddenSubmit-jeCyX", xs = "hanui-bar__actions-rG69L", ks = "hanui-field-f-rvu", Ye = {
2689
- bar: vs,
2690
- bar__hiddenSubmit: ys,
2691
- bar__actions: xs,
2692
- field: ks,
2794
+ }, Ns = v(({ isWarning: e, className: n, children: t, ...o }) => /* @__PURE__ */ a("tr", { className: d(e && Ce["row--warning"], n), ...o, children: t }));
2795
+ Ns.displayName = "DataTableRow";
2796
+ const Dc = v(ks), ws = "hanui-bar-b4PP4", $s = "hanui-bar__hiddenSubmit-jeCyX", Ds = "hanui-bar__actions-rG69L", Ls = "hanui-field-f-rvu", We = {
2797
+ bar: ws,
2798
+ bar__hiddenSubmit: $s,
2799
+ bar__actions: Ds,
2800
+ field: Ls,
2693
2801
  "field--wide": "hanui-field--wide-FA5gf"
2694
- }, Ns = ({ onSubmit: e, children: n, actions: t, label: o, className: r, testId: i }) => /* @__PURE__ */ _(
2695
- "form",
2696
- {
2697
- className: d(Ye.bar, r),
2698
- "aria-label": o,
2699
- "data-testid": i,
2700
- onSubmit: (s) => {
2701
- s.preventDefault(), e();
2702
- },
2703
- children: [
2704
- n,
2705
- /* @__PURE__ */ a("button", { type: "submit", className: Ye.bar__hiddenSubmit, tabIndex: -1, "aria-hidden": !0 }),
2706
- t && /* @__PURE__ */ a("div", { className: Ye.bar__actions, children: t })
2707
- ]
2708
- }
2709
- ), ws = h(({ children: e, isWide: n, className: t }) => /* @__PURE__ */ a("div", { className: d(Ye.field, n && Ye["field--wide"], t), children: e }));
2710
- ws.displayName = "FilterBarField";
2711
- const kc = h(Ns), $s = "hanui-pagination-K-L20", Ds = "hanui-pagination__list--9HqC", Cs = "hanui-pagination__arrow-XIgoX", Is = "hanui-pagination__page-TpoJM", Ls = "hanui-pagination__gap-qoDyI", _e = {
2712
- pagination: $s,
2713
- pagination__list: Ds,
2714
- pagination__arrow: Cs,
2715
- pagination__page: Is,
2802
+ }, Cs = ({ onSubmit: e, children: n, actions: t, label: o, className: i, testId: r }) => {
2803
+ const { labels: s } = P();
2804
+ return /* @__PURE__ */ _(
2805
+ "form",
2806
+ {
2807
+ className: d(We.bar, i),
2808
+ "aria-label": I("FilterBar.label", o, s == null ? void 0 : s.filters),
2809
+ "data-testid": r,
2810
+ onSubmit: (c) => {
2811
+ c.preventDefault(), e();
2812
+ },
2813
+ children: [
2814
+ n,
2815
+ /* @__PURE__ */ a("button", { type: "submit", className: We.bar__hiddenSubmit, tabIndex: -1, "aria-hidden": !0 }),
2816
+ t && /* @__PURE__ */ a("div", { className: We.bar__actions, children: t })
2817
+ ]
2818
+ }
2819
+ );
2820
+ }, Is = v(({ children: e, isWide: n, className: t }) => /* @__PURE__ */ a("div", { className: d(We.field, n && We["field--wide"], t), children: e }));
2821
+ Is.displayName = "FilterBarField";
2822
+ const Lc = v(Cs), Es = "hanui-pagination-K-L20", Ms = "hanui-pagination__list--9HqC", Ts = "hanui-pagination__arrow-XIgoX", Rs = "hanui-pagination__page-TpoJM", As = "hanui-pagination__gap-qoDyI", me = {
2823
+ pagination: Es,
2824
+ pagination__list: Ms,
2825
+ pagination__arrow: Ts,
2826
+ pagination__page: Rs,
2716
2827
  "pagination__page--active": "hanui-pagination__page--active-XHeaz",
2717
- pagination__gap: Ls
2718
- }, Es = (e, n) => {
2719
- if (n <= 7) return Array.from({ length: n }, (i, s) => s + 1);
2828
+ pagination__gap: As
2829
+ }, Bs = (e, n) => {
2830
+ if (n <= 7) return Array.from({ length: n }, (r, s) => s + 1);
2720
2831
  const t = /* @__PURE__ */ new Set([1, n, e]);
2721
2832
  e - 1 > 1 && t.add(e - 1), e + 1 < n && t.add(e + 1);
2722
- const o = [...t].sort((i, s) => i - s), r = [];
2723
- return o.forEach((i, s) => {
2724
- s > 0 && i - o[s - 1] > 1 && r.push("gap"), r.push(i);
2725
- }), r;
2726
- }, Ms = ({
2833
+ const o = [...t].sort((r, s) => r - s), i = [];
2834
+ return o.forEach((r, s) => {
2835
+ s > 0 && r - o[s - 1] > 1 && i.push("gap"), i.push(r);
2836
+ }), i;
2837
+ }, Ss = ({
2727
2838
  page: e,
2728
2839
  totalPages: n,
2729
2840
  label: t,
2730
2841
  previousLabel: o,
2731
- nextLabel: r,
2732
- buildHref: i,
2842
+ nextLabel: i,
2843
+ buildHref: r,
2733
2844
  onPageChange: s,
2734
- linkProps: l,
2735
- className: u,
2736
- testId: p
2845
+ linkProps: c,
2846
+ className: l,
2847
+ testId: u
2737
2848
  }) => {
2738
- const m = aa(() => Es(e, n), [e, n]);
2849
+ var p, N, m;
2850
+ const { labels: b } = P(), g = ia(() => Bs(e, n), [e, n]);
2739
2851
  if (n <= 1) return null;
2740
- const b = (c) => {
2741
- s && s(c);
2852
+ const h = (f) => {
2853
+ s && s(f);
2742
2854
  };
2743
- return /* @__PURE__ */ _("nav", { className: d(_e.pagination, u), "aria-label": t, "data-testid": p, children: [
2744
- /* @__PURE__ */ a(
2745
- ta,
2746
- {
2747
- className: _e.pagination__arrow,
2748
- icon: /* @__PURE__ */ a(vn, {}),
2749
- label: o,
2750
- variant: "outline",
2751
- disabled: e <= 1,
2752
- onClick: () => b(e - 1)
2753
- }
2754
- ),
2755
- /* @__PURE__ */ a("ul", { className: _e.pagination__list, children: m.map(
2756
- (c, v) => c === "gap" ? /* @__PURE__ */ a("li", { className: _e.pagination__gap, "aria-hidden": !0, children: "…" }, `gap-${v}`) : /* @__PURE__ */ a("li", { children: i ? /* @__PURE__ */ a(
2757
- oe,
2758
- {
2759
- href: i(c),
2760
- className: d(
2761
- _e.pagination__page,
2762
- c === e && _e["pagination__page--active"]
2763
- ),
2764
- "aria-current": c === e ? "page" : void 0,
2765
- ...l,
2766
- children: c
2767
- }
2768
- ) : /* @__PURE__ */ a(
2769
- Ze,
2770
- {
2771
- variant: ue.SECONDARY,
2772
- size: Ie.SMALL,
2773
- className: d(
2774
- _e.pagination__page,
2775
- c === e && _e["pagination__page--active"]
2776
- ),
2777
- "aria-current": c === e ? "page" : void 0,
2778
- onClick: () => b(c),
2779
- children: c
2780
- }
2781
- ) }, c)
2782
- ) }),
2783
- /* @__PURE__ */ a(
2784
- ta,
2785
- {
2786
- className: _e.pagination__arrow,
2787
- icon: /* @__PURE__ */ a(Ba, {}),
2788
- label: r,
2789
- variant: "outline",
2790
- disabled: e >= n,
2791
- onClick: () => b(e + 1)
2792
- }
2793
- )
2794
- ] });
2795
- }, Nc = h(Ms);
2855
+ return /* @__PURE__ */ _(
2856
+ "nav",
2857
+ {
2858
+ className: d(me.pagination, l),
2859
+ "aria-label": I("Pagination.label", t, (p = b == null ? void 0 : b.pagination) == null ? void 0 : p.label),
2860
+ "data-testid": u,
2861
+ children: [
2862
+ /* @__PURE__ */ a(
2863
+ ca,
2864
+ {
2865
+ className: me.pagination__arrow,
2866
+ icon: /* @__PURE__ */ a(Nn, {}),
2867
+ label: I(
2868
+ "Pagination.previousLabel",
2869
+ o,
2870
+ (N = b == null ? void 0 : b.pagination) == null ? void 0 : N.previous
2871
+ ),
2872
+ variant: "outline",
2873
+ disabled: e <= 1,
2874
+ onClick: () => h(e - 1)
2875
+ }
2876
+ ),
2877
+ /* @__PURE__ */ a("ul", { className: me.pagination__list, children: g.map(
2878
+ (f, D) => f === "gap" ? /* @__PURE__ */ a("li", { className: me.pagination__gap, "aria-hidden": !0, children: "…" }, `gap-${D}`) : /* @__PURE__ */ a("li", { children: r ? /* @__PURE__ */ a(
2879
+ le,
2880
+ {
2881
+ href: r(f),
2882
+ className: d(
2883
+ me.pagination__page,
2884
+ f === e && me["pagination__page--active"]
2885
+ ),
2886
+ "aria-current": f === e ? "page" : void 0,
2887
+ ...c,
2888
+ children: f
2889
+ }
2890
+ ) : /* @__PURE__ */ a(
2891
+ ea,
2892
+ {
2893
+ variant: ge.SECONDARY,
2894
+ size: Te.SMALL,
2895
+ className: d(
2896
+ me.pagination__page,
2897
+ f === e && me["pagination__page--active"]
2898
+ ),
2899
+ "aria-current": f === e ? "page" : void 0,
2900
+ onClick: () => h(f),
2901
+ children: f
2902
+ }
2903
+ ) }, f)
2904
+ ) }),
2905
+ /* @__PURE__ */ a(
2906
+ ca,
2907
+ {
2908
+ className: me.pagination__arrow,
2909
+ icon: /* @__PURE__ */ a(Ha, {}),
2910
+ label: I("Pagination.nextLabel", i, (m = b == null ? void 0 : b.pagination) == null ? void 0 : m.next),
2911
+ variant: "outline",
2912
+ disabled: e >= n,
2913
+ onClick: () => h(e + 1)
2914
+ }
2915
+ )
2916
+ ]
2917
+ }
2918
+ );
2919
+ }, Cc = v(Ss);
2796
2920
  export {
2797
- ca as ABOVE_MOBILE_MEDIA_QUERY,
2798
- Ks as ABOVE_TABLET_MEDIA_QUERY,
2799
- ac as Alert,
2800
- nc as Avatar,
2801
- tc as Badge,
2802
- Pa as BottomSheet,
2803
- oc as Breadcrumb,
2804
- Ze as Button,
2805
- ic as Card,
2806
- si as CardBody,
2807
- ci as CardFooter,
2808
- ii as CardMedia,
2809
- ri as CardOverlay,
2810
- Ys as Checkbox,
2811
- Gn as Chip,
2812
- Us as ChipGroup,
2813
- qs as Combobox,
2814
- fc as ConfirmDialog,
2815
- rc as CopyField,
2816
- en as DARK_THEME,
2817
- Ss as DEFAULT_FONTS,
2818
- xc as DataTable,
2819
- fs as DataTableRow,
2820
- cc as Directory,
2821
- Ai as DirectoryGroup,
2822
- Ti as DirectoryJump,
2823
- Ri as DirectoryRow,
2824
- sc as Divider,
2825
- lc as EmptyState,
2826
- xa as Field,
2827
- kc as FilterBar,
2828
- ws as FilterBarField,
2829
- Os as HanuiProvider,
2830
- ta as IconButton,
2831
- vo as Input,
2832
- Wa as LIGHT_THEME,
2833
- rn as MOBILE_BREAKPOINT,
2834
- qa as Modal,
2835
- dc as PageHeader,
2836
- Nc as Pagination,
2837
- _c as Panel,
2838
- dr as PanelForm,
2839
- _r as PanelRow,
2840
- uc as Price,
2841
- vc as PromptDialog,
2842
- Ws as QuantityStepper,
2843
- Zs as Radio,
2844
- Js as RadioCard,
2845
- Vs as RangeSlider,
2846
- hc as Rating,
2847
- Qs as RatingInput,
2848
- pc as SectionHeader,
2849
- Xs as Select,
2850
- bc as Skeleton,
2851
- Ea as Spinner,
2852
- sn as TABLET_BREAKPOINT,
2853
- zs as TABLET_PORTRAIT_BREAKPOINT,
2854
- yc as Table,
2855
- ec as TableCheckbox,
2856
- _s as TableScroller,
2857
- mc as Tabs,
2858
- js as TextLink,
2859
- ko as Textarea,
2860
- gc as Tile,
2861
- Gs as Tooltip,
2862
- Ie as UISize,
2863
- ue as UIVariant,
2864
- an as buildThemeCss,
2865
- Hs as initHanui,
2866
- ln as isKeyboardOpeningElement,
2867
- va as matchesSearch,
2868
- fa as normalizeSearchTerm,
2869
- La as preventAutoKeyboard,
2870
- Fs as resolveTokens,
2871
- nn as useHanui,
2872
- Ps as useHanuiTheme,
2873
- on as useSheetViewport
2921
+ ha as ABOVE_MOBILE_MEDIA_QUERY,
2922
+ Xs as ABOVE_TABLET_MEDIA_QUERY,
2923
+ ic as Alert,
2924
+ sc as Avatar,
2925
+ cc as Badge,
2926
+ Ga as BottomSheet,
2927
+ lc as Breadcrumb,
2928
+ ea as Button,
2929
+ dc as Card,
2930
+ ur as CardBody,
2931
+ hr as CardFooter,
2932
+ dr as CardMedia,
2933
+ _r as CardOverlay,
2934
+ Ws as Checkbox,
2935
+ Yn as Chip,
2936
+ Js as ChipGroup,
2937
+ Qs as Combobox,
2938
+ Nc as ConfirmDialog,
2939
+ _c as CopyField,
2940
+ rn as DARK_THEME,
2941
+ zs as DEFAULT_FONTS,
2942
+ Dc as DataTable,
2943
+ Ns as DataTableRow,
2944
+ hc as Directory,
2945
+ Fr as DirectoryGroup,
2946
+ Or as DirectoryJump,
2947
+ Pr as DirectoryRow,
2948
+ uc as Divider,
2949
+ pc as EmptyState,
2950
+ Ao as Field,
2951
+ Lc as FilterBar,
2952
+ Is as FilterBarField,
2953
+ qs as HanuiProvider,
2954
+ ca as IconButton,
2955
+ No as Input,
2956
+ on as LIGHT_THEME,
2957
+ dn as MOBILE_BREAKPOINT,
2958
+ Qa as Modal,
2959
+ bc as PageHeader,
2960
+ Cc as Pagination,
2961
+ mc as Panel,
2962
+ bi as PanelForm,
2963
+ mi as PanelRow,
2964
+ gc as Price,
2965
+ wc as PromptDialog,
2966
+ oc as QuantityStepper,
2967
+ ec as Radio,
2968
+ ac as RadioCard,
2969
+ nc as RangeSlider,
2970
+ fc as Rating,
2971
+ tc as RatingInput,
2972
+ yc as SectionHeader,
2973
+ Vs as Select,
2974
+ vc as Skeleton,
2975
+ Ba as Spinner,
2976
+ _n as TABLET_BREAKPOINT,
2977
+ Us as TABLET_PORTRAIT_BREAKPOINT,
2978
+ $c as Table,
2979
+ rc as TableCheckbox,
2980
+ ms as TableScroller,
2981
+ xc as Tabs,
2982
+ Ys as TextLink,
2983
+ Do as Textarea,
2984
+ kc as Tile,
2985
+ Zs as Tooltip,
2986
+ Te as UISize,
2987
+ ge as UIVariant,
2988
+ sn as buildThemeCss,
2989
+ js as initHanui,
2990
+ hn as isKeyboardOpeningElement,
2991
+ wa as matchesSearch,
2992
+ Na as normalizeSearchTerm,
2993
+ Aa as preventAutoKeyboard,
2994
+ Ks as resolveTokens,
2995
+ P as useHanui,
2996
+ Gs as useHanuiTheme,
2997
+ ln as useSheetViewport
2874
2998
  };
2875
2999
  //# sourceMappingURL=index.js.map