@refinn/core-ui 0.1.3 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs ADDED
@@ -0,0 +1,2636 @@
1
+ "use client";
2
+ "use strict";
3
+ var __create = Object.create;
4
+ var __defProp = Object.defineProperty;
5
+ var __defProps = Object.defineProperties;
6
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
7
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
8
+ var __getOwnPropNames = Object.getOwnPropertyNames;
9
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
10
+ var __getProtoOf = Object.getPrototypeOf;
11
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
12
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
13
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
14
+ var __spreadValues = (a, b) => {
15
+ for (var prop in b || (b = {}))
16
+ if (__hasOwnProp.call(b, prop))
17
+ __defNormalProp(a, prop, b[prop]);
18
+ if (__getOwnPropSymbols)
19
+ for (var prop of __getOwnPropSymbols(b)) {
20
+ if (__propIsEnum.call(b, prop))
21
+ __defNormalProp(a, prop, b[prop]);
22
+ }
23
+ return a;
24
+ };
25
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
26
+ var __objRest = (source, exclude) => {
27
+ var target = {};
28
+ for (var prop in source)
29
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
30
+ target[prop] = source[prop];
31
+ if (source != null && __getOwnPropSymbols)
32
+ for (var prop of __getOwnPropSymbols(source)) {
33
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
34
+ target[prop] = source[prop];
35
+ }
36
+ return target;
37
+ };
38
+ var __export = (target, all) => {
39
+ for (var name in all)
40
+ __defProp(target, name, { get: all[name], enumerable: true });
41
+ };
42
+ var __copyProps = (to, from, except, desc) => {
43
+ if (from && typeof from === "object" || typeof from === "function") {
44
+ for (let key of __getOwnPropNames(from))
45
+ if (!__hasOwnProp.call(to, key) && key !== except)
46
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
47
+ }
48
+ return to;
49
+ };
50
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
51
+ // If the importer is in node compatibility mode or this is not an ESM
52
+ // file that has been converted to a CommonJS file using a Babel-
53
+ // compatible transform (i.e. "__esModule" has not been set), then set
54
+ // "default" to the CommonJS "module.exports" for node compatibility.
55
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
56
+ mod
57
+ ));
58
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
59
+
60
+ // src/components/index.ts
61
+ var index_exports = {};
62
+ __export(index_exports, {
63
+ Accordion: () => Accordion,
64
+ AlertBanner: () => AlertBanner,
65
+ Avatar: () => Avatar,
66
+ Badge: () => Badge,
67
+ BottomSheet: () => BottomSheet,
68
+ Branding: () => Branding,
69
+ Button: () => Button,
70
+ Checkbox: () => Checkbox,
71
+ Chip: () => Chip,
72
+ Dialog: () => Dialog,
73
+ Dropdown: () => Dropdown,
74
+ FinancialLogo: () => FinancialLogo,
75
+ Icon: () => Icon,
76
+ Link: () => Link,
77
+ Loading: () => Loading,
78
+ Radio: () => Radio,
79
+ SegmentControl: () => SegmentControl,
80
+ Slider: () => Slider,
81
+ Tab: () => Tab,
82
+ TextArea: () => TextArea,
83
+ TextField: () => TextField,
84
+ Toast: () => Toast,
85
+ ToggleSwitch: () => ToggleSwitch,
86
+ Tooltip: () => Tooltip
87
+ });
88
+ module.exports = __toCommonJS(index_exports);
89
+
90
+ // src/components/Accordion/Accordion.tsx
91
+ var import_react = require("react");
92
+ var import_jsx_runtime = require("react/jsx-runtime");
93
+ function ChevronIcon({ className }) {
94
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", { className, viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
95
+ "path",
96
+ {
97
+ d: "M5 7.5L10 12.5L15 7.5",
98
+ stroke: "currentColor",
99
+ strokeWidth: "1.67",
100
+ strokeLinecap: "round",
101
+ strokeLinejoin: "round"
102
+ }
103
+ ) });
104
+ }
105
+ function AccordionItem({ item, isOpen, onToggle, generatedId }) {
106
+ const triggerId = `${generatedId}-trigger`;
107
+ const panelId = `${generatedId}-panel`;
108
+ const iconClasses = [
109
+ "shrink-0 transition-transform duration-200 text-accordion-icon h-28 w-28 p-4 my-8 mx-12 lg:h-40 lg:w-40 lg:p-8 lg:mx-12 lg:my-8",
110
+ isOpen ? "rotate-180" : "",
111
+ item.disabled ? "text-static-icon-disabled" : "text-static-icon-primary"
112
+ ].join(" ");
113
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { children: [
114
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
115
+ "button",
116
+ {
117
+ id: triggerId,
118
+ type: "button",
119
+ "aria-expanded": isOpen,
120
+ "aria-controls": panelId,
121
+ disabled: item.disabled,
122
+ className: "flex flex-row items-center justify-between w-full pl-16 pr-8 py-8 lg:pl-24 lg:py-16 lg:pr-12",
123
+ onClick: onToggle,
124
+ children: [
125
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { className: `flex flex-col`, children: [
126
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
127
+ "span",
128
+ {
129
+ className: `
130
+ text-label-large
131
+ text-start
132
+ lg:text-heading-3
133
+ ${item.disabled ? "text-accordion-text-disabled" : "text-accordion-text-primary"}
134
+ `,
135
+ children: item.title
136
+ }
137
+ ),
138
+ item.subtitle && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: [
139
+ "text-body-small",
140
+ item.disabled ? "text-accordion-text-disabled" : "text-accordion-text-secondary"
141
+ ].join(" "), children: item.subtitle })
142
+ ] }),
143
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ChevronIcon, { className: iconClasses })
144
+ ]
145
+ }
146
+ ),
147
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
148
+ "div",
149
+ {
150
+ id: panelId,
151
+ role: "region",
152
+ "aria-labelledby": triggerId,
153
+ className: "overflow-hidden transition-[grid-template-rows] duration-200",
154
+ style: { display: "grid", gridTemplateRows: isOpen ? "1fr" : "0fr" },
155
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "overflow-hidden", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: `text-accordion-text-secondary text-body-small pt-8 pb-16 px-16 lg:text-body-regular lg:pl-24 lg:pr-64 lg:pb-24 lg:pt-12`, children: item.content }) })
156
+ }
157
+ )
158
+ ] });
159
+ }
160
+ var Accordion = (0, import_react.forwardRef)(
161
+ (_a, ref) => {
162
+ var _b = _a, {
163
+ items,
164
+ multiple = false,
165
+ loading = false,
166
+ className = ""
167
+ } = _b, rest = __objRest(_b, [
168
+ "items",
169
+ "multiple",
170
+ "loading",
171
+ "className"
172
+ ]);
173
+ const baseId = (0, import_react.useId)();
174
+ const defaultOpen = () => {
175
+ const set = /* @__PURE__ */ new Set();
176
+ items.forEach((item, i) => {
177
+ var _a2;
178
+ if (item.defaultOpen) set.add((_a2 = item.id) != null ? _a2 : String(i));
179
+ });
180
+ return set;
181
+ };
182
+ const [openItems, setOpenItems] = (0, import_react.useState)(defaultOpen);
183
+ const handleToggle = (0, import_react.useCallback)(
184
+ (itemId) => {
185
+ setOpenItems((prev) => {
186
+ const next = new Set(multiple ? prev : []);
187
+ if (prev.has(itemId)) {
188
+ next.delete(itemId);
189
+ } else {
190
+ next.add(itemId);
191
+ }
192
+ return next;
193
+ });
194
+ },
195
+ [multiple]
196
+ );
197
+ const containerClasses = [
198
+ "rounded-lg border border-accordion-border bg-accordion-bg font-sans",
199
+ "divide-y divide-accordion-border",
200
+ className
201
+ ].filter(Boolean).join(" ");
202
+ if (loading) {
203
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", __spreadProps(__spreadValues({ ref, className: containerClasses }, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: `flex items-center justify-between gap-8 pl-16 pr-8 py-8`, children: [
204
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "flex-1 flex flex-col gap-4", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "h-16 w-3/4 rounded bg-gray-200 animate-pulse" }) }),
205
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ChevronIcon, { className: `shrink-0 text-accordion-icon w-20 h-20 my-8 mx-12` })
206
+ ] }) }));
207
+ }
208
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", __spreadProps(__spreadValues({ ref, className: containerClasses }, rest), { children: items.map((item, i) => {
209
+ var _a2;
210
+ const itemId = (_a2 = item.id) != null ? _a2 : String(i);
211
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
212
+ AccordionItem,
213
+ {
214
+ item,
215
+ isOpen: openItems.has(itemId),
216
+ onToggle: () => handleToggle(itemId),
217
+ generatedId: `${baseId}-${itemId}`
218
+ },
219
+ itemId
220
+ );
221
+ }) }));
222
+ }
223
+ );
224
+ Accordion.displayName = "Accordion";
225
+
226
+ // src/components/AlertBanner/AlertBanner.tsx
227
+ var import_react2 = require("react");
228
+ var import_jsx_runtime2 = require("react/jsx-runtime");
229
+ var pageClasses = {
230
+ info: "bg-alert-page-info-bg text-alert-text-primary-inverse",
231
+ success: "bg-alert-page-success-bg text-alert-text-primary-inverse",
232
+ warning: "bg-alert-page-warning-bg text-alert-text-primary-inverse",
233
+ danger: "bg-alert-page-danger-bg text-alert-text-primary-inverse",
234
+ none: "bg-alert-page-common-bg text-alert-text-primary-inverse"
235
+ };
236
+ var SectionClasses = {
237
+ info: "bg-alert-banner-background-info-subtle text-alert-text-primary",
238
+ success: "bg-alert-banner-background-success-subtle text-alert-text-primary",
239
+ warning: "bg-alert-banner-background-warning-subtle text-alert-text-primary",
240
+ danger: "bg-alert-banner-background-danger-subtle text-alert-text-primary",
241
+ none: "bg-alert-banner-background-common-subtle text-alert-text-primary"
242
+ };
243
+ var inlineClasses = {
244
+ info: "bg-alert-banner-background-transparent text-alert-text-primary",
245
+ success: "bg-alert-banner-background-transparent text-alert-text-primary",
246
+ warning: "bg-alert-banner-background-transparent text-alert-text-primary",
247
+ danger: "bg-alert-banner-background-transparent text-alert-text-primary",
248
+ none: "bg-alert-banner-background-transparent text-alert-text-primary"
249
+ };
250
+ var actionsPageClasses = {
251
+ info: "text-enabled-inverse",
252
+ success: "text-enabled-inverse",
253
+ warning: "text-enabled-dark",
254
+ danger: "text-enabled-inverse",
255
+ none: "text-enabled-inverse"
256
+ };
257
+ var inlineIconClasses = {
258
+ info: "text-alert-inline-info-icon",
259
+ success: "text-alert-inline-success-icon",
260
+ warning: "text-alert-inline-warning-icon",
261
+ danger: "text-alert-inline-danger-icon",
262
+ none: "text-alert-inline-common-icon"
263
+ };
264
+ function InfoIcon({ className }) {
265
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16ZM10 6h.01M9 10h1v4h1", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
266
+ }
267
+ function SuccessIcon({ className }) {
268
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
269
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z", stroke: "currentColor", strokeWidth: "1.5" }),
270
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "m7 10 2 2 4-4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })
271
+ ] });
272
+ }
273
+ function WarningIcon({ className }) {
274
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M8.57 3.22 1.53 15.5a1.67 1.67 0 0 0 1.43 2.5h14.08a1.67 1.67 0 0 0 1.43-2.5L11.43 3.22a1.67 1.67 0 0 0-2.86 0ZM10 7.5v3.33M10 14.17h.01", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
275
+ }
276
+ function DangerIcon({ className }) {
277
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16ZM12.5 7.5l-5 5M7.5 7.5l5 5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
278
+ }
279
+ function NoneIcon({ className }) {
280
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_jsx_runtime2.Fragment, {});
281
+ }
282
+ function CloseIcon({ className }) {
283
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("svg", { className, width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("path", { d: "M12 4 4 12M4 4l8 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
284
+ }
285
+ var defaultIcons = {
286
+ info: InfoIcon,
287
+ success: SuccessIcon,
288
+ warning: WarningIcon,
289
+ danger: DangerIcon,
290
+ none: NoneIcon
291
+ };
292
+ var AlertBanner = (0, import_react2.forwardRef)(
293
+ (_a, ref) => {
294
+ var _b = _a, {
295
+ variant = "info",
296
+ mode = "inline",
297
+ title,
298
+ description,
299
+ action,
300
+ icon,
301
+ onClose,
302
+ className = "",
303
+ children
304
+ } = _b, rest = __objRest(_b, [
305
+ "variant",
306
+ "mode",
307
+ "title",
308
+ "description",
309
+ "action",
310
+ "icon",
311
+ "onClose",
312
+ "className",
313
+ "children"
314
+ ]);
315
+ const isPage = mode === "page";
316
+ const isSection = mode === "section";
317
+ const variantClass = isPage ? pageClasses[variant] : isSection ? SectionClasses[variant] : inlineClasses[variant];
318
+ const actionClass = isPage ? actionsPageClasses[variant] : "text-enabled";
319
+ const DefaultIcon = defaultIcons[variant];
320
+ const iconColorClass = isPage ? "" : inlineIconClasses[variant];
321
+ const descColorClass = isPage ? "text-alert-text-secondary-inverse" : "text-alert-text-secondary";
322
+ const closeColorClass = isPage ? "text-alert-close-inverse hover:text-alert-close-inverse-hover" : "text-alert-close hover:text-alert-close-hover";
323
+ const classes = [
324
+ "flex items-start gap-24 font-sans justify-between",
325
+ isPage ? "p-12" : isSection ? "p-12 rounded-md" : "p-0",
326
+ variantClass,
327
+ className
328
+ ].filter(Boolean).join(" ");
329
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", __spreadProps(__spreadValues({ ref, role: "alert", className: classes }, rest), { children: [
330
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "flex items-start gap-8", children: [
331
+ icon != null ? icon : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(DefaultIcon, { className: `h-20 w-20 ${iconColorClass}` }),
332
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "flex-1 min-w-0 flex flex-col", children: [
333
+ title && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("p", { className: "text-label-medium", children: title }),
334
+ description && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("p", { className: `text-body-small ${descColorClass} ${title ? "mt-2" : ""} ${children ? "mb-8" : ""}`, children: description }),
335
+ children
336
+ ] })
337
+ ] }),
338
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: `flex ${children ? "items-start" : "self-center"} gap-24`, children: [
339
+ (action == null ? void 0 : action[0]) && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("a", { className: `${actionClass} underline text-sm font-medium`, href: action[1], children: action[0] }),
340
+ onClose && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
341
+ "button",
342
+ {
343
+ type: "button",
344
+ onClick: onClose,
345
+ className: `shrink-0 p-2 rounded transition-colors ${closeColorClass}`,
346
+ "aria-label": "Close",
347
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(CloseIcon, { className: "h-16 w-16" })
348
+ }
349
+ )
350
+ ] })
351
+ ] }));
352
+ }
353
+ );
354
+ AlertBanner.displayName = "AlertBanner";
355
+
356
+ // src/components/Avatar/Avatar.tsx
357
+ var import_react3 = require("react");
358
+ var import_jsx_runtime3 = require("react/jsx-runtime");
359
+ var sizeClasses = {
360
+ sm: { container: "h-24 w-24", text: "text-sm", status: "h-6 w-6", statusRing: "ring-1" },
361
+ md: { container: "h-32 w-32", text: "text-base", status: "h-8 w-8", statusRing: "ring-[1.5px]" },
362
+ lg: { container: "h-40 w-40", text: "text-lg", status: "h-10 w-10", statusRing: "ring-2" },
363
+ xl: { container: "h-48 w-48", text: "text-xl", status: "h-12 w-12", statusRing: "ring-2" }
364
+ };
365
+ var statusColorClasses = {
366
+ online: "bg-avatar-status-online",
367
+ offline: "bg-avatar-status-offline",
368
+ busy: "bg-avatar-status-busy",
369
+ "": ""
370
+ };
371
+ function getInitials(name) {
372
+ const parts = name.trim().split(/\s+/);
373
+ if (parts.length === 1) return parts[0][0].toUpperCase();
374
+ return (parts[0][0] + parts[parts.length - 1][0]).toUpperCase();
375
+ }
376
+ function PersonIcon({ className }) {
377
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("svg", { className, viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("path", { d: "M10 10a3.75 3.75 0 1 0 0-7.5 3.75 3.75 0 0 0 0 7.5ZM3.75 17.5a6.25 6.25 0 0 1 12.5 0" }) });
378
+ }
379
+ var Avatar = (0, import_react3.forwardRef)(
380
+ (_a, ref) => {
381
+ var _b = _a, {
382
+ size = "md",
383
+ src,
384
+ alt = "",
385
+ name,
386
+ icon,
387
+ status,
388
+ className = ""
389
+ } = _b, rest = __objRest(_b, [
390
+ "size",
391
+ "src",
392
+ "alt",
393
+ "name",
394
+ "icon",
395
+ "status",
396
+ "className"
397
+ ]);
398
+ const sz = sizeClasses[size];
399
+ const containerClasses = [
400
+ "relative inline-flex items-center justify-center shrink-0 rounded-full",
401
+ "bg-avatar-bg text-avatar-text font-medium font-sans",
402
+ "transition-colors duration-150",
403
+ "select-none",
404
+ sz.container,
405
+ className
406
+ ].filter(Boolean).join(" ");
407
+ let content;
408
+ if (src) {
409
+ content = /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
410
+ "img",
411
+ {
412
+ src,
413
+ alt: alt || name || "",
414
+ className: "h-full w-full object-cover rounded-full"
415
+ }
416
+ );
417
+ } else if (icon) {
418
+ content = icon;
419
+ } else if (name) {
420
+ content = /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { className: sz.text, children: getInitials(name) });
421
+ } else {
422
+ content = /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(PersonIcon, { className: `${sz.text} h-[60%] w-[60%]` });
423
+ }
424
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", __spreadProps(__spreadValues({ ref, className: containerClasses }, rest), { children: [
425
+ content,
426
+ status && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
427
+ "span",
428
+ {
429
+ className: [
430
+ "absolute bottom-0 right-0 block rounded-full",
431
+ "ring-avatar-status-border",
432
+ sz.status,
433
+ sz.statusRing,
434
+ statusColorClasses[status]
435
+ ].join(" ")
436
+ }
437
+ )
438
+ ] }));
439
+ }
440
+ );
441
+ Avatar.displayName = "Avatar";
442
+
443
+ // src/components/Badge/Badge.tsx
444
+ var import_react4 = require("react");
445
+ var import_jsx_runtime4 = require("react/jsx-runtime");
446
+ var sizeClasses2 = {
447
+ sm: "h-20 px-8 py-2 text-label-small gap-4",
448
+ md: "h-28 px-10 py-4 text-label-medium gap-4",
449
+ lg: "h-32 px-14 py-6 text-label-large gap-6"
450
+ };
451
+ var iconSizeClasses = {
452
+ sm: "h-16 w-16",
453
+ md: "h-20 w-20",
454
+ lg: "h-24 w-24"
455
+ };
456
+ var minimalClasses = {
457
+ common: "bg-transparent border border-badges-border-primary text-badges-text-primary",
458
+ success: "bg-transparent border border-badges-border-success text-badges-text-success",
459
+ warning: "bg-transparent border border-badges-border-warning text-badges-text-warning",
460
+ info: "bg-transparent border border-badges-border-info text-badges-text-info",
461
+ brand: "bg-transparent border border-badges-border-brand text-badges-text-brand",
462
+ danger: "bg-transparent border border-badges-border-danger text-badges-text-danger"
463
+ };
464
+ var subtleClasses = {
465
+ common: "bg-badges-background-common-subtle text-badges-text-primary",
466
+ success: "bg-badges-background-success-subtle text-badges-text-success",
467
+ warning: "bg-badges-background-warning-subtle text-badges-text-warning",
468
+ info: "bg-badges-background-info-subtle text-badges-text-info",
469
+ brand: "bg-badges-background-brand-subtle text-badges-text-brand",
470
+ danger: "bg-badges-background-danger-subtle text-badges-text-danger"
471
+ };
472
+ var boldClasses = {
473
+ common: "bg-badges-background-common text-badges-text-inverse",
474
+ success: "bg-badges-background-success text-badges-text-inverse",
475
+ warning: "bg-badges-background-warning text-badges-text-primary",
476
+ info: "bg-badges-background-info text-badges-text-inverse",
477
+ brand: "bg-badges-background-brand text-badges-text-inverse",
478
+ danger: "bg-badges-background-danger text-badges-text-inverse"
479
+ };
480
+ var styleMap = {
481
+ minimal: minimalClasses,
482
+ subtle: subtleClasses,
483
+ bold: boldClasses
484
+ };
485
+ var Badge = (0, import_react4.forwardRef)(
486
+ (_a, ref) => {
487
+ var _b = _a, {
488
+ status = "common",
489
+ badgeStyle = "subtle",
490
+ size = "md",
491
+ shape = "round",
492
+ icon,
493
+ children,
494
+ className = ""
495
+ } = _b, rest = __objRest(_b, [
496
+ "status",
497
+ "badgeStyle",
498
+ "size",
499
+ "shape",
500
+ "icon",
501
+ "children",
502
+ "className"
503
+ ]);
504
+ const classes = [
505
+ "inline-flex items-center justify-center font-medium font-sans",
506
+ "whitespace-nowrap select-none",
507
+ sizeClasses2[size],
508
+ shape === "round" ? "rounded-full" : `rounded-${size}`,
509
+ styleMap[badgeStyle][status],
510
+ className
511
+ ].filter(Boolean).join(" ");
512
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("span", __spreadProps(__spreadValues({ ref, className: classes }, rest), { children: [
513
+ icon && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: `shrink-0 ${iconSizeClasses[size]}`, children: icon }),
514
+ children
515
+ ] }));
516
+ }
517
+ );
518
+ Badge.displayName = "Badge";
519
+
520
+ // src/components/Branding/Branding.tsx
521
+ var import_react5 = require("react");
522
+ var import_jsx_runtime5 = require("react/jsx-runtime");
523
+ var Branding = (0, import_react5.forwardRef)(
524
+ (_a, ref) => {
525
+ var _b = _a, { type = "brand", className = "" } = _b, rest = __objRest(_b, ["type", "className"]);
526
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
527
+ "div",
528
+ __spreadProps(__spreadValues({
529
+ ref,
530
+ className: `${type === "black" ? "text-gray-900" : type === "white" ? "text-white-100" : "text-blue-600"} ${className}`
531
+ }, rest), {
532
+ children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
533
+ "svg",
534
+ {
535
+ xmlns: "http://www.w3.org/2000/svg",
536
+ width: "89",
537
+ height: "20",
538
+ viewBox: "0 0 89 20",
539
+ fill: "currentColor",
540
+ children: [
541
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("g", { "clip-path": "url(#clip0_828_998)", children: [
542
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
543
+ "path",
544
+ {
545
+ "fill-rule": "evenodd",
546
+ "clip-rule": "evenodd",
547
+ d: "M16.7368 16.8241H16.7425L12.5943 11.7367C14.2529 11.1183 16.1138 9.64704 16.1138 6.12635C16.1138 -0.239164 10.023 0.0275032 10.0092 0.0275032H1.92874C1.91035 0.0275032 1.89311 0.0275032 1.87587 0.0275032C1.37851 0.0275032 0.901524 0.225077 0.549839 0.576762C0.198155 0.928447 0.000580351 1.40543 0.000580351 1.90279C0.000580351 2.40015 0.198155 2.87713 0.549839 3.22882C0.901524 3.5805 1.37851 3.77808 1.87587 3.77808C1.89426 3.77808 1.9115 3.77808 1.92874 3.77808H10.1149C10.7376 3.79195 11.3292 4.0526 11.7597 4.50268C12.1902 4.95277 12.4242 5.55543 12.4103 6.17808C12.3965 6.80073 12.1358 7.39236 11.6857 7.82284C11.2357 8.25331 10.633 8.48735 10.0103 8.47348H1.88621H1.87472C1.62814 8.47348 1.38398 8.52212 1.15623 8.61662C0.928482 8.71112 0.721611 8.84963 0.547468 9.0242C0.373325 9.19877 0.23533 9.40598 0.141388 9.63396C0.0474455 9.86194 -0.00059909 10.1062 5.6384e-06 10.3528C5.6384e-06 10.3528 5.6384e-06 10.3631 5.6384e-06 10.3677V17.9746C0.0121171 18.4636 0.214886 18.9286 0.565035 19.2701C0.915184 19.6117 1.38498 19.8029 1.87414 19.8029C2.36331 19.8029 2.8331 19.6117 3.18325 19.2701C3.5334 18.9286 3.73617 18.4636 3.74828 17.9746V12.1631H8.14943L13.8149 19.1643L13.8218 19.1585C14.1314 19.5449 14.5818 19.7925 15.0739 19.8468C15.566 19.9012 16.0596 19.7578 16.446 19.4482C16.8324 19.1386 17.08 18.6882 17.1343 18.1961C17.1886 17.704 17.0452 17.2104 16.7356 16.8241H16.7368Z",
548
+ fill: "currentColor"
549
+ }
550
+ ),
551
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
552
+ "path",
553
+ {
554
+ d: "M30.3851 15.1575C31.5816 13.5 34.0989 15.2805 32.9023 16.9379C31.9828 18.1966 30.3241 19.854 27.2241 19.823C23.6241 19.823 20.5575 16.7195 20.4736 12.6379C20.4671 12.5169 20.4671 12.3957 20.4736 12.2747C20.5621 8.18966 23.6241 5.08966 27.1931 5.08966H27.2241C30.815 5.08966 33.977 8.28162 33.977 12.4563C33.979 12.6584 33.9407 12.8588 33.8643 13.0459C33.7879 13.233 33.6749 13.4029 33.532 13.5458C33.3891 13.6887 33.2192 13.8017 33.0321 13.8781C32.845 13.9545 32.6446 13.9928 32.4425 13.9908H23.7851C24.3046 15.5667 25.6023 16.7494 27.223 16.7494H27.254C28.9736 16.7816 29.8943 15.8621 30.3851 15.1575ZM23.7851 10.9195H30.9115C30.9115 10.1828 29.346 8.16093 27.2333 8.16093C25.6023 8.16093 24.3046 9.34598 23.7851 10.9195Z",
555
+ fill: "currentColor"
556
+ }
557
+ ),
558
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
559
+ "path",
560
+ {
561
+ "fill-rule": "evenodd",
562
+ "clip-rule": "evenodd",
563
+ d: "M44.1379 5.09414H41.4805V4.56196C41.4808 4.16209 41.6398 3.77869 41.9225 3.49595C42.2052 3.2132 42.5886 3.05422 42.9885 3.05391H43.9977C44.398 3.05391 44.7818 2.89491 45.0649 2.61188C45.3479 2.32885 45.5069 1.94498 45.5069 1.54472C45.5069 1.14445 45.3479 0.760585 45.0649 0.477556C44.7818 0.194527 44.398 0.0355225 43.9977 0.0355225H41.9713V0.0435684C41.0274 0.0827094 40.1351 0.485118 39.4809 1.1667C38.8268 1.84829 38.4613 2.75632 38.4609 3.70104V5.08955H37.7402C37.3897 5.08955 37.0534 5.22881 36.8056 5.4767C36.5577 5.7246 36.4184 6.06081 36.4184 6.41138C36.4184 6.76196 36.5577 7.09817 36.8056 7.34607C37.0534 7.59396 37.3897 7.73322 37.7402 7.73322H38.4609V18.4229H38.4713C38.4925 18.806 38.6597 19.1665 38.9384 19.4303C39.2172 19.694 39.5864 19.841 39.9701 19.841C40.3539 19.841 40.7231 19.694 41.0018 19.4303C41.2806 19.1665 41.4477 18.806 41.469 18.4229H41.4793V7.73322H44.1379C44.4885 7.73322 44.8247 7.59396 45.0726 7.34607C45.3205 7.09817 45.4598 6.76196 45.4598 6.41138C45.4598 6.06081 45.3205 5.7246 45.0726 5.4767C44.8247 5.22881 44.4885 5.08955 44.1379 5.08955V5.09414Z",
564
+ fill: "currentColor"
565
+ }
566
+ ),
567
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
568
+ "path",
569
+ {
570
+ "fill-rule": "evenodd",
571
+ "clip-rule": "evenodd",
572
+ d: "M72.2724 10.154C72.2414 7.48161 70.0678 5.04368 67.3885 5.04368C66.4874 5.04385 65.6039 5.29338 64.8358 5.76464C64.0678 6.2359 63.4451 6.91052 63.0368 7.7138C63.0368 7.7138 63.0368 6.56437 63.0368 6.53334C63.0368 6.13307 62.8778 5.7492 62.5947 5.46617C62.3117 5.18314 61.9278 5.02414 61.5276 5.02414C61.1273 5.02414 60.7434 5.18314 60.4604 5.46617C60.1774 5.7492 60.0184 6.13307 60.0184 6.53334V18.4356H60.0287C60.0499 18.8188 60.2171 19.1793 60.4959 19.443C60.7746 19.7068 61.1438 19.8537 61.5276 19.8537C61.9113 19.8537 62.2805 19.7068 62.5593 19.443C62.838 19.1793 63.0052 18.8188 63.0264 18.4356H63.0368V11.1805L63.0483 11.1989C63.0483 9.47472 64.4414 7.80575 66.1598 7.80575C67.7758 7.80575 69.1046 9.32069 69.2563 10.8977V18.4368H69.2666C69.2879 18.82 69.455 19.1804 69.7338 19.4442C70.0126 19.7079 70.3817 19.8549 70.7655 19.8549C71.1493 19.8549 71.5184 19.7079 71.7972 19.4442C72.076 19.1804 72.2431 18.82 72.2644 18.4368H72.2747V10.154H72.2724Z",
573
+ fill: "currentColor"
574
+ }
575
+ ),
576
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
577
+ "path",
578
+ {
579
+ "fill-rule": "evenodd",
580
+ "clip-rule": "evenodd",
581
+ d: "M55.4322 2.2V1.96897H55.4126C55.2287 0.904602 53.7586 0.0758667 51.9724 0.0758667C50.1862 0.0758667 48.7161 0.905751 48.5322 1.96897H48.5126V4.4046H48.5241C48.6391 5.51035 50.1333 6.38621 51.9724 6.38621C53.8115 6.38621 55.3057 5.51035 55.4207 4.4046H55.431V4.27242L55.4322 2.2ZM54.1678 4.40575C54.1678 4.80115 53.1851 5.12184 51.9724 5.12184C50.7598 5.12184 49.777 4.80115 49.777 4.40575V3.53564C49.777 3.93104 50.7598 4.25173 51.9724 4.25173C53.1851 4.25173 54.1678 3.93104 54.1678 3.53564V4.40575ZM51.9724 3.09426C50.7598 3.09426 49.777 2.69196 49.777 2.19541C49.777 1.69885 50.7598 1.29541 51.9724 1.29541C53.1851 1.29541 54.1678 1.69771 54.1678 2.19541C54.1678 2.69311 53.1839 3.09426 51.9724 3.09426Z",
582
+ fill: "currentColor"
583
+ }
584
+ ),
585
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
586
+ "path",
587
+ {
588
+ "fill-rule": "evenodd",
589
+ "clip-rule": "evenodd",
590
+ d: "M55.4321 17.708V9.16092V9.08046C55.3689 7.94483 53.8482 7.03448 51.9781 7.03448C50.108 7.03448 48.5804 7.94598 48.5172 9.08046H48.5115V17.7012C48.5115 17.7012 48.5115 17.7115 48.5115 17.7161C48.5115 18.8862 50.0609 19.8356 51.9724 19.8356C53.8839 19.8356 55.4333 18.8874 55.4333 17.7161C55.4333 17.7161 55.4333 17.7058 55.4333 17.7012L55.4321 17.708ZM54.1678 17.8954C54.1678 18.2908 53.185 18.6115 51.9724 18.6115C50.7597 18.6115 49.777 18.2908 49.777 17.8954V17.0264C49.777 17.4218 50.7597 17.7425 51.9724 17.7425C53.185 17.7425 54.1678 17.4218 54.1678 17.0264V17.8954ZM54.1678 15.792C54.1678 16.1874 53.185 16.508 51.9724 16.508C50.7597 16.508 49.777 16.1874 49.777 15.792V14.923C49.777 15.3184 50.7597 15.6391 51.9724 15.6391C53.185 15.6391 54.1678 15.3184 54.1678 14.923V15.792ZM54.1678 13.6885C54.1678 14.0839 53.185 14.4046 51.9724 14.4046C50.7597 14.4046 49.777 14.0839 49.777 13.6885V12.8195C49.777 13.2149 50.7597 13.5356 51.9724 13.5356C53.185 13.5356 54.1678 13.2149 54.1678 12.8195V13.6885ZM54.1678 11.5161C54.1678 11.9115 53.185 12.2322 51.9724 12.2322C50.7597 12.2322 49.777 11.9115 49.777 11.5161V10.646C49.777 11.0414 50.7597 11.3621 51.9724 11.3621C53.185 11.3621 54.1678 11.0414 54.1678 10.646V11.5161ZM51.9724 10.0678C50.7597 10.0678 49.777 9.66552 49.777 9.16897C49.777 8.67242 50.7597 8.27012 51.9724 8.27012C53.185 8.27012 54.1678 8.67242 54.1678 9.16897C54.1678 9.66552 53.1839 10.0667 51.9724 10.0667V10.0678Z",
591
+ fill: "currentColor"
592
+ }
593
+ ),
594
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
595
+ "path",
596
+ {
597
+ "fill-rule": "evenodd",
598
+ "clip-rule": "evenodd",
599
+ d: "M88.8885 10.154C88.8574 7.48161 86.6839 5.04368 84.0046 5.04368C83.1039 5.04427 82.2209 5.294 81.4532 5.76524C80.6856 6.23648 80.0633 6.91086 79.6552 7.71379C79.6552 7.71379 79.6552 6.56437 79.6552 6.53333C79.6552 6.13307 79.4962 5.7492 79.2131 5.46617C78.9301 5.18314 78.5462 5.02414 78.146 5.02414C77.7457 5.02414 77.3618 5.18314 77.0788 5.46617C76.7958 5.7492 76.6368 6.13307 76.6368 6.53333V18.4356H76.6471C76.6684 18.8188 76.8355 19.1793 77.1143 19.443C77.393 19.7068 77.7622 19.8537 78.146 19.8537C78.5297 19.8537 78.8989 19.7068 79.1777 19.443C79.4564 19.1793 79.6236 18.8188 79.6448 18.4356H79.6552V11.1805L79.6667 11.1989C79.6667 9.47471 81.0598 7.80575 82.7781 7.80575C84.3942 7.80575 85.723 9.32069 85.8747 10.8977V18.4368H85.885C85.9063 18.8199 86.0734 19.1804 86.3522 19.4442C86.6309 19.7079 87.0001 19.8549 87.3839 19.8549C87.7676 19.8549 88.1368 19.7079 88.4156 19.4442C88.6943 19.1804 88.8615 18.8199 88.8827 18.4368H88.8931V10.154H88.8885Z",
600
+ fill: "currentColor"
601
+ }
602
+ )
603
+ ] }),
604
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("clipPath", { id: "clip0_828_998", children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("rect", { width: "88.892", height: "20", fill: "currentColor" }) }) })
605
+ ]
606
+ }
607
+ )
608
+ })
609
+ );
610
+ }
611
+ );
612
+ Branding.displayName = "Branding";
613
+
614
+ // src/components/Button/Button.tsx
615
+ var import_react7 = require("react");
616
+
617
+ // src/components/Loading/Loading.tsx
618
+ var import_react6 = require("react");
619
+ var import_jsx_runtime6 = require("react/jsx-runtime");
620
+ var Loading = (0, import_react6.forwardRef)(
621
+ (_a, ref) => {
622
+ var _b = _a, { size = "sm", isDark = false, className = "" } = _b, rest = __objRest(_b, ["size", "isDark", "className"]);
623
+ const containerClasses = [
624
+ isDark ? "text-white-100" : "text-blue-600",
625
+ className
626
+ ].filter(Boolean).join(" ");
627
+ return size === "sm" && !isDark ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", __spreadProps(__spreadValues({ ref, className: containerClasses }, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
628
+ "svg",
629
+ {
630
+ className: "animate-spin",
631
+ xmlns: "http://www.w3.org/2000/svg",
632
+ width: "18",
633
+ height: "18",
634
+ viewBox: "0 0 18 18",
635
+ fill: "none",
636
+ children: [
637
+ /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
638
+ "path",
639
+ {
640
+ d: "M1 9C1 6.87827 1.84286 4.84344 3.34315 3.34315C4.84344 1.84285 6.87827 1 9 1C11.1217 1 13.1566 1.84286 14.6569 3.34315C16.1571 4.84344 17 6.87827 17 9C17 11.1217 16.1571 13.1566 14.6569 14.6569C13.1566 16.1571 11.1217 17 9 17C6.87827 17 4.84344 16.1571 3.34315 14.6569C1.84285 13.1566 1 11.1217 1 9L1 9Z",
641
+ stroke: "#F3F4F6",
642
+ "stroke-width": "2"
643
+ }
644
+ ),
645
+ /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
646
+ "path",
647
+ {
648
+ d: "M1 9C1 7.31057 1.53484 5.6645 2.52786 4.29772C3.52089 2.93094 4.92112 1.91361 6.52787 1.39155C8.13461 0.869484 9.86539 0.869484 11.4721 1.39155C13.0789 1.91361 14.4791 2.93094 15.4721 4.29772",
649
+ stroke: "#0193D7",
650
+ "stroke-width": "2"
651
+ }
652
+ )
653
+ ]
654
+ }
655
+ ) })) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", __spreadProps(__spreadValues({ ref, className: containerClasses }, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
656
+ "svg",
657
+ {
658
+ className: "animate-spin",
659
+ width: size === "sm" ? 18 : 88,
660
+ height: size === "sm" ? 18 : 88,
661
+ viewBox: "0 0 20 20",
662
+ fill: "none",
663
+ children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
664
+ "path",
665
+ {
666
+ d: "M10 2.5a7.5 7.5 0 1 0 7.5 7.5",
667
+ stroke: "currentColor",
668
+ strokeWidth: size === "sm" ? 2 : 1,
669
+ strokeLinecap: "round"
670
+ }
671
+ )
672
+ }
673
+ ) }));
674
+ }
675
+ );
676
+ Loading.displayName = "Loading";
677
+
678
+ // src/components/Button/Button.tsx
679
+ var import_jsx_runtime7 = require("react/jsx-runtime");
680
+ var variantClasses = {
681
+ primary: [
682
+ "bg-blue-600 text-white-100",
683
+ "hover:bg-blue-700",
684
+ "active:bg-blue-800",
685
+ "focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2",
686
+ "disabled:bg-gray-100 disabled:text-gray-400"
687
+ ].join(" "),
688
+ secondary: [
689
+ "bg-gray-100 text-gray-900",
690
+ "hover:bg-gray-200",
691
+ "active:bg-gray-300",
692
+ "focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2",
693
+ "disabled:bg-gray-100 disabled:text-gray-400"
694
+ ].join(" "),
695
+ tertiary: [
696
+ "bg-black-0 text-gray-900",
697
+ "hover:bg-gray-200",
698
+ "active:bg-gray-300",
699
+ "focus-visible:ring-2 focus-visible:ring-blue-500 focus-visible:ring-offset-2",
700
+ "disabled:bg-gray-100 disabled:text-gray-400"
701
+ ].join(" "),
702
+ contrast: [
703
+ "bg-white-100 text-blue-600",
704
+ "hover:bg-white-90",
705
+ "active:bg-white-80",
706
+ "focus-visible:ring-2 focus-visible:ring-white-100 focus-visible:ring-offset-2",
707
+ "disabled:bg-gray-50 disabled:text-gray-400"
708
+ ].join(" "),
709
+ transparent: [
710
+ "bg-black-0 text-white-100",
711
+ "hover:bg-white-20",
712
+ "active:bg-white-30",
713
+ "focus-visible:ring-2 focus-visible:ring-white-100 focus-visible:bg-black-0 focus-visible:ring-offset-2",
714
+ "disabled:bg-black-0 disabled:text-white-40"
715
+ ].join(" ")
716
+ };
717
+ var sizeClasses3 = {
718
+ sm: "px-16 py-6 text-label-medium",
719
+ md: "px-20 py-8 text-label-large",
720
+ lg: "px-24 py-12 text-label-large",
721
+ xl: "px-32 py-16 text-label-large"
722
+ };
723
+ var Button = (0, import_react7.forwardRef)(
724
+ (_a, ref) => {
725
+ var _b = _a, {
726
+ variant = "primary",
727
+ size = "md",
728
+ rounded = false,
729
+ loading = false,
730
+ disabled = false,
731
+ startIcon,
732
+ endIcon,
733
+ children,
734
+ className = ""
735
+ } = _b, rest = __objRest(_b, [
736
+ "variant",
737
+ "size",
738
+ "rounded",
739
+ "loading",
740
+ "disabled",
741
+ "startIcon",
742
+ "endIcon",
743
+ "children",
744
+ "className"
745
+ ]);
746
+ const isDisabled = disabled;
747
+ const classes = [
748
+ "inline-flex items-center justify-center gap-8",
749
+ "transition-colors duration-150",
750
+ "outline-none",
751
+ "disabled:cursor-not-allowed",
752
+ loading ? "pointer-events-none" : "cursor-pointer",
753
+ sizeClasses3[size],
754
+ variantClasses[variant],
755
+ rounded ? "rounded-full" : size === "sm" ? "rounded-6" : size === "xl" ? "rounded-12" : "rounded-8",
756
+ className
757
+ ].filter(Boolean).join(" ");
758
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("button", __spreadProps(__spreadValues({ ref, disabled: isDisabled, className: classes }, rest), { children: [
759
+ loading ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Loading, { size: "sm", isDark: variant === "primary" || variant === "transparent" }) : startIcon,
760
+ children,
761
+ !loading && endIcon
762
+ ] }));
763
+ }
764
+ );
765
+ Button.displayName = "Button";
766
+
767
+ // src/components/BottomSheet/BottomSheet.tsx
768
+ var import_react8 = __toESM(require("react"));
769
+ var import_react_dom = require("react-dom");
770
+ var import_jsx_runtime8 = require("react/jsx-runtime");
771
+ var BottomSheet = (0, import_react8.forwardRef)(
772
+ (_a, ref) => {
773
+ var _b = _a, {
774
+ isForceOpen = false,
775
+ setIsForceOpen,
776
+ isClosedAble = true,
777
+ children,
778
+ startModalBtn,
779
+ stopModalBtn,
780
+ afterStopBtn,
781
+ size = "md",
782
+ modalTitle = "\u0E2B\u0E31\u0E27\u0E02\u0E49\u0E2D",
783
+ modalDesc = "\u0E04\u0E33\u0E2D\u0E18\u0E34\u0E1A\u0E32\u0E22",
784
+ className = ""
785
+ } = _b, rest = __objRest(_b, [
786
+ "isForceOpen",
787
+ "setIsForceOpen",
788
+ "isClosedAble",
789
+ "children",
790
+ "startModalBtn",
791
+ "stopModalBtn",
792
+ "afterStopBtn",
793
+ "size",
794
+ "modalTitle",
795
+ "modalDesc",
796
+ "className"
797
+ ]);
798
+ const [isOpen, setIsOpen] = (0, import_react8.useState)(false);
799
+ const [shouldRender, setShouldRender] = (0, import_react8.useState)(false);
800
+ const [animate, setAnimate] = (0, import_react8.useState)(false);
801
+ (0, import_react8.useEffect)(() => {
802
+ if (isOpen) {
803
+ setShouldRender(true);
804
+ setTimeout(() => setAnimate(true), 10);
805
+ } else {
806
+ setAnimate(false);
807
+ const timer = setTimeout(() => setShouldRender(false), 300);
808
+ return () => clearTimeout(timer);
809
+ }
810
+ }, [isOpen]);
811
+ (0, import_react8.useEffect)(() => {
812
+ if (isForceOpen) {
813
+ setIsOpen(true);
814
+ } else {
815
+ setIsOpen(false);
816
+ }
817
+ }, [isForceOpen]);
818
+ const handleStartClick = (0, import_react8.useCallback)(
819
+ (e) => {
820
+ var _a2, _b2;
821
+ (_b2 = startModalBtn == null ? void 0 : (_a2 = startModalBtn.props).onClick) == null ? void 0 : _b2.call(_a2, e);
822
+ setIsForceOpen == null ? void 0 : setIsForceOpen(true);
823
+ setIsOpen(true);
824
+ },
825
+ [startModalBtn]
826
+ );
827
+ const handleStopClick = (0, import_react8.useCallback)(
828
+ (e) => {
829
+ var _a2, _b2;
830
+ (_b2 = stopModalBtn == null ? void 0 : (_a2 = stopModalBtn.props).onClick) == null ? void 0 : _b2.call(_a2, e);
831
+ setIsForceOpen == null ? void 0 : setIsForceOpen(false);
832
+ setIsOpen(false);
833
+ },
834
+ [stopModalBtn]
835
+ );
836
+ const handleCloseClick = () => {
837
+ setIsForceOpen == null ? void 0 : setIsForceOpen(false);
838
+ setIsOpen(false);
839
+ };
840
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("span", { ref, style: { display: "contents" }, children: [
841
+ startModalBtn && import_react8.default.cloneElement(startModalBtn, {
842
+ onClick: handleStartClick
843
+ }),
844
+ shouldRender && (0, import_react_dom.createPortal)(
845
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
846
+ "div",
847
+ {
848
+ className: `fixed inset-0 z-50 flex items-end justify-center transition-opacity duration-300 ${animate ? "opacity-100" : "opacity-0"}`,
849
+ "aria-modal": "true",
850
+ role: "dialog",
851
+ children: [
852
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
853
+ "div",
854
+ {
855
+ className: "absolute inset-0 bg-black/40",
856
+ onClick: () => isClosedAble ? handleCloseClick() : null,
857
+ "aria-label": "Close modal"
858
+ }
859
+ ),
860
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
861
+ "div",
862
+ {
863
+ className: `flex flex-col z-10 w-full rounded-t-xl bg-white pt-8 pb-16 px-16 shadow-lg transform transition-all duration-300
864
+ ${size === "sm" ? "h-auto max-h-auto" : size === "md" ? "h-full max-h-[85vh]" : "h-full max-h-screen rounded-t-none!"}
865
+ ${animate ? "scale-100 translate-y-0" : "scale-95 translate-y-full"}`,
866
+ children: [
867
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "w-full flex flex-row relative items-center pt-8 pb-16", children: [
868
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "flex flex-col px-8 max-w-225", children: [
869
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "text-heading-3 text-button-sheet-text-primary", children: modalTitle }),
870
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "text-body-small text-button-sheet-text-secondary", children: modalDesc })
871
+ ] }),
872
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
873
+ "i",
874
+ {
875
+ className: "fi fi-br-cross-small flex text-xl text-gray-600 w-44 h-44 absolute top-0 right-0 p-12",
876
+ onClick: () => handleCloseClick()
877
+ }
878
+ ),
879
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
880
+ "div",
881
+ {
882
+ className: "text-gray-600 text-xl absolute top-0 right-0 p-12",
883
+ onClick: () => handleCloseClick(),
884
+ children: "x"
885
+ }
886
+ )
887
+ ] }),
888
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "w-full h-full grow overflow-y-auto overflow-x-visible", children: [
889
+ children,
890
+ stopModalBtn && import_react8.default.cloneElement(stopModalBtn, {
891
+ onClick: handleStopClick
892
+ }),
893
+ afterStopBtn && afterStopBtn
894
+ ] })
895
+ ]
896
+ }
897
+ )
898
+ ]
899
+ }
900
+ ),
901
+ document.body
902
+ )
903
+ ] });
904
+ }
905
+ );
906
+ BottomSheet.displayName = "BottomSheet";
907
+
908
+ // src/components/Checkbox/Checkbox.tsx
909
+ var import_react9 = require("react");
910
+ var import_jsx_runtime9 = require("react/jsx-runtime");
911
+ function CheckIcon({ className }) {
912
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
913
+ "svg",
914
+ {
915
+ className,
916
+ viewBox: "0 0 16 16",
917
+ fill: "none",
918
+ "aria-hidden": "true",
919
+ children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
920
+ "path",
921
+ {
922
+ d: "M13.333 4.667 6 12l-3.333-3.333",
923
+ stroke: "currentColor",
924
+ strokeWidth: "2",
925
+ strokeLinecap: "round",
926
+ strokeLinejoin: "round"
927
+ }
928
+ )
929
+ }
930
+ );
931
+ }
932
+ function IndeterminateIcon({ className }) {
933
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
934
+ "svg",
935
+ {
936
+ className,
937
+ viewBox: "0 0 16 16",
938
+ fill: "none",
939
+ "aria-hidden": "true",
940
+ children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
941
+ "path",
942
+ {
943
+ d: "M3.333 8h9.334",
944
+ stroke: "currentColor",
945
+ strokeWidth: "2",
946
+ strokeLinecap: "round"
947
+ }
948
+ )
949
+ }
950
+ );
951
+ }
952
+ var Checkbox = (0, import_react9.forwardRef)(
953
+ (_a, ref) => {
954
+ var _b = _a, {
955
+ label,
956
+ description,
957
+ error = false,
958
+ contrast = false,
959
+ indeterminate = false,
960
+ disabled = false,
961
+ className = "",
962
+ id,
963
+ defaultChecked
964
+ } = _b, rest = __objRest(_b, [
965
+ "label",
966
+ "description",
967
+ "error",
968
+ "contrast",
969
+ "indeterminate",
970
+ "disabled",
971
+ "className",
972
+ "id",
973
+ "defaultChecked"
974
+ ]);
975
+ const reactId = (0, import_react9.useId)();
976
+ const inputId = id != null ? id : reactId;
977
+ const [isChecked, setIsChecked] = (0, import_react9.useState)(defaultChecked != null ? defaultChecked : false);
978
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
979
+ "label",
980
+ {
981
+ htmlFor: inputId,
982
+ className: `flex select-none font-sans ${disabled ? "cursor-not-allowed" : "cursor-pointer"} ${className}`,
983
+ children: [
984
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "relative mr-16", children: [
985
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
986
+ "input",
987
+ __spreadValues({
988
+ ref,
989
+ id: inputId,
990
+ type: "checkbox",
991
+ defaultChecked,
992
+ onChange: (e) => {
993
+ var _a2;
994
+ setIsChecked(e.target.checked);
995
+ (_a2 = rest.onChange) == null ? void 0 : _a2.call(rest, e);
996
+ },
997
+ disabled,
998
+ "aria-checked": indeterminate ? "mixed" : isChecked,
999
+ className: "sr-only"
1000
+ }, rest)
1001
+ ),
1002
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1003
+ "div",
1004
+ {
1005
+ className: `box m-6 flex h-20 w-20 rounded-md items-center justify-center border ${contrast ? isChecked || indeterminate ? "border-white bg-white" : "border-white" : isChecked || indeterminate ? "bg-static-icon-brand border-static-icon-brand" : "border-static-icon-primary"}`,
1006
+ children: isChecked ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1007
+ CheckIcon,
1008
+ {
1009
+ className: `h-20 ${contrast ? "text-static-icon-brand" : "text-white"}`
1010
+ }
1011
+ ) : indeterminate ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1012
+ IndeterminateIcon,
1013
+ {
1014
+ className: `h-20 ${contrast ? "text-static-icon-brand" : "text-white"}`
1015
+ }
1016
+ ) : null
1017
+ }
1018
+ )
1019
+ ] }),
1020
+ (label || description) && /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("span", { className: "flex flex-col", children: [
1021
+ label && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1022
+ "span",
1023
+ {
1024
+ className: `text-label-large ${disabled ? "text-checkbox-text-disabled" : contrast ? "text-checkbox-text-primary-inverse" : "text-checkbox-text-primary"}`,
1025
+ children: label
1026
+ }
1027
+ ),
1028
+ description && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1029
+ "span",
1030
+ {
1031
+ className: `text-body-small ${error ? "text-checkbox-text-danger" : disabled ? "text-checkbox-text-disabled" : contrast ? "text-checkbox-text-primary-inverse" : "text-checkbox-text-secondary"}`,
1032
+ children: description
1033
+ }
1034
+ )
1035
+ ] })
1036
+ ]
1037
+ }
1038
+ );
1039
+ }
1040
+ );
1041
+ Checkbox.displayName = "Checkbox";
1042
+
1043
+ // src/components/Chip/Chip.tsx
1044
+ var import_react10 = require("react");
1045
+ var import_jsx_runtime10 = require("react/jsx-runtime");
1046
+ var sizeClasses4 = {
1047
+ sm: "h-32 text-label-medium px-12 py-6",
1048
+ md: "h-40 text-label-large px-16 py-10",
1049
+ lg: "h-48 text-label-large px-24 py-14"
1050
+ };
1051
+ var marginImgClasses = {
1052
+ sm: "-ml-10 -my-4 h-28 w-28",
1053
+ md: "-ml-12 -my-6 h-32 w-32",
1054
+ lg: "-ml-18 -my-8 h-32 w-32"
1055
+ };
1056
+ var isOutlinedClasses = {
1057
+ true: "border border-chip-border-enabled bg-chip-background-inverse",
1058
+ false: "border-0 bg-chip-background-enabled"
1059
+ };
1060
+ var isDarkClasses = {
1061
+ true: "!bg-chip-background-black-active !text-chip-text-inverse",
1062
+ false: "!bg-chip-background-active !text-chip-text-inverse"
1063
+ };
1064
+ var Chip = (0, import_react10.forwardRef)(
1065
+ (_a, ref) => {
1066
+ var _b = _a, {
1067
+ size = "md",
1068
+ src,
1069
+ alt = "",
1070
+ label,
1071
+ icon,
1072
+ isOutlined = false,
1073
+ isDark = false,
1074
+ defaultSelected = false,
1075
+ disabled = false,
1076
+ className = ""
1077
+ } = _b, rest = __objRest(_b, [
1078
+ "size",
1079
+ "src",
1080
+ "alt",
1081
+ "label",
1082
+ "icon",
1083
+ "isOutlined",
1084
+ "isDark",
1085
+ "defaultSelected",
1086
+ "disabled",
1087
+ "className"
1088
+ ]);
1089
+ const [selected, setSelected] = (0, import_react10.useState)(defaultSelected);
1090
+ const sz = sizeClasses4[size];
1091
+ const outlinedClass = isOutlinedClasses[String(isOutlined)];
1092
+ const darkClass = isDarkClasses[String(isDark)];
1093
+ const containerClasses = [
1094
+ "w-fit rounded-full flex flex-row gap-8 items-center justify-center text-chip-text-enabled",
1095
+ disabled ? "cursor-not-allowed" : "cursor-pointer",
1096
+ outlinedClass,
1097
+ sz,
1098
+ className,
1099
+ selected ? darkClass : ""
1100
+ ].filter(Boolean).join(" ");
1101
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
1102
+ "div",
1103
+ __spreadProps(__spreadValues({
1104
+ ref,
1105
+ className: containerClasses
1106
+ }, rest), {
1107
+ onClick: () => !disabled && setSelected(!selected),
1108
+ children: [
1109
+ icon ? icon : src && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("img", { src, alt, className: `${marginImgClasses[size]} rounded-full` }),
1110
+ label
1111
+ ]
1112
+ })
1113
+ );
1114
+ }
1115
+ );
1116
+ Chip.displayName = "Chip";
1117
+
1118
+ // src/components/Dialog/Dialog.tsx
1119
+ var import_react11 = __toESM(require("react"));
1120
+ var import_react_dom2 = require("react-dom");
1121
+ var import_jsx_runtime11 = require("react/jsx-runtime");
1122
+ var Dialog = (0, import_react11.forwardRef)(
1123
+ ({
1124
+ isForceOpen = false,
1125
+ setIsForceOpen,
1126
+ isClosedAble = true,
1127
+ isCloseIcon = true,
1128
+ children,
1129
+ startModalBtn,
1130
+ stopModalBtn,
1131
+ afterStopBtn,
1132
+ p = "20",
1133
+ maxW = "md"
1134
+ }, ref) => {
1135
+ const [isOpen, setIsOpen] = (0, import_react11.useState)(false);
1136
+ const [isRender, setIsRender] = (0, import_react11.useState)(false);
1137
+ const [animate, setAnimate] = (0, import_react11.useState)(false);
1138
+ (0, import_react11.useEffect)(() => {
1139
+ if (isOpen) {
1140
+ setIsRender(true);
1141
+ setTimeout(() => setAnimate(true), 10);
1142
+ } else {
1143
+ setAnimate(false);
1144
+ const timer = setTimeout(() => setIsRender(false), 300);
1145
+ return () => clearTimeout(timer);
1146
+ }
1147
+ }, [isOpen]);
1148
+ (0, import_react11.useEffect)(() => {
1149
+ if (isForceOpen) {
1150
+ setIsOpen(true);
1151
+ } else {
1152
+ setIsOpen(false);
1153
+ }
1154
+ }, [isForceOpen]);
1155
+ const handleStartClick = (0, import_react11.useCallback)(
1156
+ (e) => {
1157
+ var _a, _b;
1158
+ (_b = startModalBtn == null ? void 0 : (_a = startModalBtn.props).onClick) == null ? void 0 : _b.call(_a, e);
1159
+ setIsForceOpen == null ? void 0 : setIsForceOpen(true);
1160
+ setIsOpen(true);
1161
+ },
1162
+ [startModalBtn]
1163
+ );
1164
+ const handleStopClick = (0, import_react11.useCallback)(
1165
+ (e) => {
1166
+ var _a, _b;
1167
+ (_b = stopModalBtn == null ? void 0 : (_a = stopModalBtn.props).onClick) == null ? void 0 : _b.call(_a, e);
1168
+ setIsForceOpen == null ? void 0 : setIsForceOpen(false);
1169
+ setIsOpen(false);
1170
+ },
1171
+ [stopModalBtn]
1172
+ );
1173
+ const handleCloseClick = () => {
1174
+ setIsForceOpen == null ? void 0 : setIsForceOpen(false);
1175
+ setIsOpen(false);
1176
+ };
1177
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("span", { ref, style: { display: "contents" }, children: [
1178
+ startModalBtn && import_react11.default.cloneElement(startModalBtn, {
1179
+ onClick: handleStartClick
1180
+ }),
1181
+ isRender && (0, import_react_dom2.createPortal)(
1182
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
1183
+ "div",
1184
+ {
1185
+ className: `fixed inset-0 z-50 flex items-center justify-center transition-opacity duration-300 ${animate ? "opacity-100" : "opacity-0"}`,
1186
+ "aria-modal": "true",
1187
+ role: "dialog",
1188
+ children: [
1189
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
1190
+ "div",
1191
+ {
1192
+ className: "absolute inset-0 bg-black/40",
1193
+ onClick: () => isClosedAble ? handleCloseClick() : null,
1194
+ "aria-label": "Close modal"
1195
+ }
1196
+ ),
1197
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
1198
+ "div",
1199
+ {
1200
+ className: `relative z-10 w-[calc(100%-40px)] max-w-${maxW} rounded-xl bg-white p-${p || "20"} shadow-lg transform transition-all duration-300 ${animate ? "scale-100 opacity-100" : "scale-95 opacity-0"}`,
1201
+ children: [
1202
+ isCloseIcon && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
1203
+ "svg",
1204
+ {
1205
+ xmlns: "http://www.w3.org/2000/svg",
1206
+ width: "20",
1207
+ height: "20",
1208
+ viewBox: "0 0 20 20",
1209
+ fill: "none",
1210
+ className: "text-gray-900 flex h-20 w-20 items-center justify-center absolute right-16 top-16 cursor-pointer",
1211
+ onMouseDown: (e) => {
1212
+ e.preventDefault();
1213
+ handleCloseClick();
1214
+ },
1215
+ children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
1216
+ "path",
1217
+ {
1218
+ d: "M14.7119 6.0625L10.7744 10L14.7119 13.9375L13.9375 14.7119L10 10.7744L6.0625 14.7119L5.28809 13.9375L9.22559 10L5.28809 6.0625L6.0625 5.28809L10 9.22559L13.9375 5.28809L14.7119 6.0625Z",
1219
+ fill: "#111827"
1220
+ }
1221
+ )
1222
+ }
1223
+ ),
1224
+ children,
1225
+ stopModalBtn && import_react11.default.cloneElement(stopModalBtn, {
1226
+ onClick: handleStopClick
1227
+ }),
1228
+ afterStopBtn && afterStopBtn
1229
+ ]
1230
+ }
1231
+ )
1232
+ ]
1233
+ }
1234
+ ),
1235
+ document.body
1236
+ )
1237
+ ] });
1238
+ }
1239
+ );
1240
+ Dialog.displayName = "Dialog";
1241
+
1242
+ // src/components/Dropdown/Dropdown.tsx
1243
+ var import_react12 = require("react");
1244
+ var import_jsx_runtime12 = require("react/jsx-runtime");
1245
+ var IconDanger = () => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1246
+ "svg",
1247
+ {
1248
+ xmlns: "http://www.w3.org/2000/svg",
1249
+ width: "20",
1250
+ height: "20",
1251
+ viewBox: "0 0 20 20",
1252
+ fill: "none",
1253
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1254
+ "path",
1255
+ {
1256
+ d: "M10.0078 2.41699C11.0548 2.41699 12.0363 2.61407 12.9512 3.00879C13.8657 3.40341 14.6687 3.94646 15.3604 4.6377C16.0522 5.32922 16.5962 6.13426 16.9912 7.05176C17.386 7.96936 17.583 8.95002 17.583 9.99316C17.583 11.0363 17.3859 12.0187 16.9912 12.9404C16.5966 13.862 16.0536 14.6687 15.3623 15.3604C14.6708 16.0522 13.8657 16.5962 12.9482 16.9912C12.0306 17.386 11.05 17.583 10.0068 17.583C8.96373 17.583 7.9813 17.3859 7.05957 16.9912C6.13798 16.5966 5.33135 16.0536 4.63965 15.3623C3.94784 14.6708 3.40379 13.8642 3.00879 12.9434C2.61398 12.0228 2.41703 11.039 2.41699 9.99219C2.41699 8.94524 2.61407 7.96369 3.00879 7.04883C3.40341 6.13429 3.94646 5.33128 4.6377 4.63965C5.32922 3.94784 6.13581 3.40379 7.05664 3.00879C7.97723 2.61398 8.961 2.41703 10.0078 2.41699ZM10.0039 12.5967C9.83828 12.5968 9.69804 12.6527 9.58301 12.7646C9.46793 12.8769 9.41016 13.0159 9.41016 13.1816C9.4102 13.3472 9.46621 13.4875 9.57812 13.6025C9.69035 13.7177 9.83026 13.7754 9.99609 13.7754C10.1617 13.7753 10.302 13.7195 10.417 13.6074C10.5321 13.4952 10.5898 13.3562 10.5898 13.1904C10.5898 13.0246 10.534 12.8837 10.4219 12.7686C10.3097 12.6536 10.1697 12.5967 10.0039 12.5967ZM9.45801 11.0645H10.542V6.06445H9.45801V11.0645Z",
1257
+ fill: "#EF4444"
1258
+ }
1259
+ )
1260
+ }
1261
+ );
1262
+ function IconCheck({ className }) {
1263
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1264
+ "svg",
1265
+ {
1266
+ xmlns: "http://www.w3.org/2000/svg",
1267
+ width: "20",
1268
+ height: "20",
1269
+ viewBox: "0 0 20 20",
1270
+ fill: "none",
1271
+ className,
1272
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1273
+ "path",
1274
+ {
1275
+ d: "M15.6328 6.64062L8.10449 14.1494L4.36719 10.4326L5.13281 9.64551L8.10449 12.6172L14.8672 5.875L15.6328 6.64062Z",
1276
+ fill: "#111827"
1277
+ }
1278
+ )
1279
+ }
1280
+ );
1281
+ }
1282
+ function ChevronDown({ className }) {
1283
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1284
+ "svg",
1285
+ {
1286
+ xmlns: "http://www.w3.org/2000/svg",
1287
+ width: "20",
1288
+ height: "20",
1289
+ viewBox: "0 0 20 20",
1290
+ fill: "none",
1291
+ className,
1292
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1293
+ "path",
1294
+ {
1295
+ d: "M14.7119 8.0625L10 12.7744L5.28809 8.0625L6.0625 7.28809L10 11.2256L13.9375 7.28809L14.7119 8.0625Z",
1296
+ fill: "#111827"
1297
+ }
1298
+ )
1299
+ }
1300
+ );
1301
+ }
1302
+ var Dropdown = ({
1303
+ error,
1304
+ label,
1305
+ placeholder,
1306
+ isDisabled = false,
1307
+ isSearchable = false,
1308
+ isTextCenter = false,
1309
+ value,
1310
+ setValue,
1311
+ dropDownItems = [
1312
+ { label: "Bonnie Green", value: "Bonnie Green" },
1313
+ { label: "Jese Leos", value: "Jese Leos" },
1314
+ { label: "Joseph Mcfall", value: "Joseph Mcfall" },
1315
+ { label: "John Smith", value: "John Smith" },
1316
+ { label: "Maria Garcia", value: "Maria Garcia" }
1317
+ ]
1318
+ }) => {
1319
+ const [isOpen, setIsOpen] = (0, import_react12.useState)(false);
1320
+ const [search, setSearch] = (0, import_react12.useState)("");
1321
+ const dropdownRef = (0, import_react12.useRef)(null);
1322
+ const filteredItems = dropDownItems.filter(
1323
+ (item) => item.label.toLowerCase().includes(search.toLowerCase())
1324
+ );
1325
+ (0, import_react12.useEffect)(() => {
1326
+ function handleClickOutside(event) {
1327
+ if (dropdownRef.current && !dropdownRef.current.contains(event.target)) {
1328
+ setIsOpen(false);
1329
+ }
1330
+ }
1331
+ document.addEventListener("mousedown", handleClickOutside);
1332
+ return () => {
1333
+ document.removeEventListener("mousedown", handleClickOutside);
1334
+ };
1335
+ }, []);
1336
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "w-full", children: [
1337
+ label ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1338
+ "p",
1339
+ {
1340
+ className: `text-label-medium text-left items-left font-medium mb-4 ${isDisabled ? "text-dropdown-text-disabled" : "text-dropdown-text-primary"}`,
1341
+ children: label
1342
+ }
1343
+ ) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, {}),
1344
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "w-full flex flex-col relative", ref: dropdownRef, children: [
1345
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
1346
+ "button",
1347
+ {
1348
+ onClick: () => !isDisabled && setIsOpen(!isOpen),
1349
+ className: `w-full rounded-md text-body-small px-16 py-10 text-center inline-flex gap-8 items-center border **:focus:outline-none focus:border-2 focus:px-15 focus:py-9
1350
+ ${isDisabled ? "pointer-events-none bg-dropdown-background-disabled text-dropdown-text-disabled border-dropdown-border-disabled" : error ? "border-red-600 bg-dropdown-background-enabled focus:border-red-600" : value ? "text-dropdown-text-primary bg-dropdown-background-enabled border-dropdown-border-enabled focus:border-dropdown-border-active " : "text-dropdown-text-secondary bg-dropdown-background-enabled border-dropdown-border-enabled focus:border-dropdown-border-active "} `,
1351
+ type: "button",
1352
+ children: [
1353
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("p", { className: `grow ${isTextCenter ? "text-center" : "text-start"}`, children: value.label || placeholder }),
1354
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "flex items-center gap-8", children: [
1355
+ isDisabled ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, {}) : error ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(IconDanger, {}) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, {}),
1356
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1357
+ ChevronDown,
1358
+ {
1359
+ className: `h-20 w-20 duration-300 ${isOpen ? "rotate-180" : ""}`
1360
+ }
1361
+ )
1362
+ ] })
1363
+ ]
1364
+ }
1365
+ ),
1366
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
1367
+ "div",
1368
+ {
1369
+ id: "dropdownSearch",
1370
+ className: `${isOpen ? "flex" : "hidden"} top-[calc(100%+4px)] left-8 absolute z-10000 bg-white-100 rounded-lg shadow-base w-9/10 min-w-fit flex-col`,
1371
+ children: [
1372
+ isSearchable ? /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "p-3", children: [
1373
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("label", { htmlFor: "input-group-search", className: "sr-only", children: "Search" }),
1374
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "relative", children: [
1375
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { className: "absolute inset-y-0 rtl:inset-r-0 inset-s-0 flex items-center ps-12 pointer-events-none", children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
1376
+ "svg",
1377
+ {
1378
+ xmlns: "http://www.w3.org/2000/svg",
1379
+ width: "20",
1380
+ height: "20",
1381
+ viewBox: "0 0 20 20",
1382
+ fill: "none",
1383
+ children: [
1384
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1385
+ "mask",
1386
+ {
1387
+ id: "mask0_3218_5077",
1388
+ style: { maskType: "alpha" },
1389
+ maskUnits: "userSpaceOnUse",
1390
+ x: "0",
1391
+ y: "0",
1392
+ width: "20",
1393
+ height: "20",
1394
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("rect", { width: "20", height: "20", fill: "#D9D9D9" })
1395
+ }
1396
+ ),
1397
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("g", { mask: "url(#mask0_3218_5077)", children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1398
+ "path",
1399
+ {
1400
+ d: "M15.8894 16.6476L10.9263 11.6842C10.5096 12.0005 10.0527 12.2454 9.55563 12.419C9.05855 12.5926 8.54556 12.6794 8.01667 12.6794C6.7182 12.6794 5.61354 12.2241 4.70271 11.3134C3.79202 10.4026 3.33667 9.29811 3.33667 8.00005C3.33667 6.702 3.79202 5.59755 4.70271 4.68672C5.61354 3.77603 6.71799 3.32068 8.01604 3.32068C9.3141 3.32068 10.4185 3.77603 11.3294 4.68672C12.2401 5.59755 12.6954 6.70221 12.6954 8.00068C12.6954 8.54554 12.606 9.06651 12.4271 9.56359C12.2481 10.0608 12.0058 10.5097 11.7002 10.9103L16.6633 15.8734L15.8894 16.6476ZM8.01604 11.5963C9.02035 11.5963 9.87077 11.248 10.5673 10.5513C11.264 9.85478 11.6123 9.00436 11.6123 8.00005C11.6123 6.99575 11.264 6.14533 10.5673 5.4488C9.87077 4.75214 9.02035 4.4038 8.01604 4.4038C7.01174 4.4038 6.16132 4.75214 5.46479 5.4488C4.76813 6.14533 4.41979 6.99575 4.41979 8.00005C4.41979 9.00436 4.76813 9.85478 5.46479 10.5513C6.16132 11.248 7.01174 11.5963 8.01604 11.5963Z",
1401
+ fill: "#111827"
1402
+ }
1403
+ ) })
1404
+ ]
1405
+ }
1406
+ ) }),
1407
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1408
+ "input",
1409
+ {
1410
+ type: "text",
1411
+ className: "block w-full p-8 ps-40 text-body-small text-gray-900 border border-gray-300 rounded-lg bg-gray-50 focus:ring-bubblegum focus:border-bubblegum",
1412
+ placeholder: "Search...",
1413
+ value: search,
1414
+ onChange: (e) => setSearch(e.target.value)
1415
+ }
1416
+ )
1417
+ ] })
1418
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, {}),
1419
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1420
+ "ul",
1421
+ {
1422
+ className: "h-auto max-h-392 overflow-y-auto cursor-pointer",
1423
+ "aria-labelledby": "dropdownSearchButton",
1424
+ children: filteredItems.length > 0 ? filteredItems.map((item, idx) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
1425
+ "div",
1426
+ {
1427
+ onClick: () => {
1428
+ setValue(item);
1429
+ setSearch("");
1430
+ setIsOpen(false);
1431
+ },
1432
+ className: "relative text-gray-900 py-12 px-16 rounded-sm text-label-medium hover:bg-gray-100",
1433
+ children: [
1434
+ item.label,
1435
+ value.value === item.value && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(IconCheck, { className: "absolute h-20 w-20 right-24 top-2 translate-y-1/2" })
1436
+ ]
1437
+ }
1438
+ ) }, idx)) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("li", { className: "px-8 py-8 text-label-medium text-gray-900", children: "No results found" })
1439
+ }
1440
+ )
1441
+ ]
1442
+ }
1443
+ )
1444
+ ] }),
1445
+ error ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1446
+ "p",
1447
+ {
1448
+ className: `text-caption-caption text-left items-left text-dropdown-text-danger mt-4 ${isDisabled ? "hidden" : ""}`,
1449
+ children: error
1450
+ }
1451
+ ) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, {})
1452
+ ] });
1453
+ };
1454
+ Dropdown.displayName = "Dropdown";
1455
+
1456
+ // src/components/FinancialLogo/FinancialLogo.tsx
1457
+ var import_react13 = require("react");
1458
+ var import_jsx_runtime13 = require("react/jsx-runtime");
1459
+ var inlineClasses2 = {
1460
+ info: "bg-alert-inline-info-bg border-alert-inline-info-border text-alert-text-primary",
1461
+ success: "bg-alert-inline-success-bg border-alert-inline-success-border text-alert-text-primary",
1462
+ warning: "bg-alert-inline-warning-bg border-alert-inline-warning-border text-alert-text-primary",
1463
+ danger: "bg-alert-inline-danger-bg border-alert-inline-danger-border text-alert-text-primary",
1464
+ common: "bg-alert-inline-common-bg border-alert-inline-common-border text-alert-text-primary"
1465
+ };
1466
+ var pageClasses2 = {
1467
+ info: "bg-alert-page-info-bg text-alert-text-primary-inverse",
1468
+ success: "bg-alert-page-success-bg text-alert-text-primary-inverse",
1469
+ warning: "bg-alert-page-warning-bg text-alert-text-primary-inverse",
1470
+ danger: "bg-alert-page-danger-bg text-alert-text-primary-inverse",
1471
+ common: "bg-alert-page-common-bg text-alert-text-primary-inverse"
1472
+ };
1473
+ var actionsPageClasses2 = {
1474
+ info: "text-enabled-inverse",
1475
+ success: "text-enabled-inverse",
1476
+ warning: "text-enabled-dark",
1477
+ danger: "text-enabled-inverse",
1478
+ common: "text-enabled-inverse"
1479
+ };
1480
+ var inlineIconClasses2 = {
1481
+ info: "text-alert-inline-info-icon",
1482
+ success: "text-alert-inline-success-icon",
1483
+ warning: "text-alert-inline-warning-icon",
1484
+ danger: "text-alert-inline-danger-icon",
1485
+ common: "text-alert-inline-common-icon"
1486
+ };
1487
+ function InfoIcon2({ className }) {
1488
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16ZM10 6h.01M9 10h1v4h1", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1489
+ }
1490
+ function SuccessIcon2({ className }) {
1491
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
1492
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z", stroke: "currentColor", strokeWidth: "1.5" }),
1493
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "m7 10 2 2 4-4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })
1494
+ ] });
1495
+ }
1496
+ function WarningIcon2({ className }) {
1497
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "M8.57 3.22 1.53 15.5a1.67 1.67 0 0 0 1.43 2.5h14.08a1.67 1.67 0 0 0 1.43-2.5L11.43 3.22a1.67 1.67 0 0 0-2.86 0ZM10 7.5v3.33M10 14.17h.01", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1498
+ }
1499
+ function DangerIcon2({ className }) {
1500
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16ZM12.5 7.5l-5 5M7.5 7.5l5 5", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1501
+ }
1502
+ function CommonIcon({ className }) {
1503
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16ZM10 6v4M10 14h.01", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1504
+ }
1505
+ function CloseIcon2({ className }) {
1506
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("svg", { className, width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("path", { d: "M12 4 4 12M4 4l8 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1507
+ }
1508
+ var defaultIcons2 = {
1509
+ info: InfoIcon2,
1510
+ success: SuccessIcon2,
1511
+ warning: WarningIcon2,
1512
+ danger: DangerIcon2,
1513
+ common: CommonIcon
1514
+ };
1515
+ var FinancialLogo = (0, import_react13.forwardRef)(
1516
+ (_a, ref) => {
1517
+ var _b = _a, {
1518
+ variant = "info",
1519
+ mode = "inline",
1520
+ title,
1521
+ description,
1522
+ action,
1523
+ icon,
1524
+ onClose,
1525
+ className = "",
1526
+ children
1527
+ } = _b, rest = __objRest(_b, [
1528
+ "variant",
1529
+ "mode",
1530
+ "title",
1531
+ "description",
1532
+ "action",
1533
+ "icon",
1534
+ "onClose",
1535
+ "className",
1536
+ "children"
1537
+ ]);
1538
+ const isPage = mode === "page";
1539
+ const variantClass = isPage ? pageClasses2[variant] : inlineClasses2[variant];
1540
+ const actionClass = isPage ? actionsPageClasses2[variant] : "text-enabled";
1541
+ const DefaultIcon = defaultIcons2[variant];
1542
+ const iconColorClass = isPage ? "" : inlineIconClasses2[variant];
1543
+ const descColorClass = isPage ? "text-alert-text-secondary-inverse" : "text-alert-text-secondary";
1544
+ const closeColorClass = isPage ? "text-alert-close-inverse hover:text-alert-close-inverse-hover" : "text-alert-close hover:text-alert-close-hover";
1545
+ const classes = [
1546
+ "flex items-start gap-12 font-sans",
1547
+ isPage ? "px-16 py-12" : "px-16 py-12 border-l-4 rounded-lg",
1548
+ variantClass,
1549
+ className
1550
+ ].filter(Boolean).join(" ");
1551
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", __spreadProps(__spreadValues({ ref, role: "alert", className: classes }, rest), { children: [
1552
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: `shrink-0 mt-2 ${iconColorClass}`, children: icon != null ? icon : /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(DefaultIcon, { className: "h-20 w-20" }) }),
1553
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "flex-1 min-w-0", children: [
1554
+ title && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("p", { className: "text-sm font-medium leading-20", children: title }),
1555
+ description && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("p", { className: `text-sm leading-20 ${descColorClass} ${title ? "mt-4" : ""}`, children: description }),
1556
+ children
1557
+ ] }),
1558
+ action && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { className: `${actionClass} underline text-sm font-medium`, children: action }),
1559
+ onClose && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
1560
+ "button",
1561
+ {
1562
+ type: "button",
1563
+ onClick: onClose,
1564
+ className: `shrink-0 p-2 rounded transition-colors ${closeColorClass}`,
1565
+ "aria-label": "Close",
1566
+ children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(CloseIcon2, { className: "h-16 w-16" })
1567
+ }
1568
+ )
1569
+ ] }));
1570
+ }
1571
+ );
1572
+ FinancialLogo.displayName = "FinancialLogo";
1573
+
1574
+ // src/components/Icon/Icon.tsx
1575
+ var import_react14 = require("react");
1576
+ var import_jsx_runtime14 = require("react/jsx-runtime");
1577
+ var Icon = (0, import_react14.forwardRef)(
1578
+ (_a, ref) => {
1579
+ var _b = _a, {
1580
+ name,
1581
+ size = 20,
1582
+ weight = 300,
1583
+ fill = false,
1584
+ grade = 0,
1585
+ opticalSize,
1586
+ className = "",
1587
+ style,
1588
+ "aria-label": ariaLabel
1589
+ } = _b, rest = __objRest(_b, [
1590
+ "name",
1591
+ "size",
1592
+ "weight",
1593
+ "fill",
1594
+ "grade",
1595
+ "opticalSize",
1596
+ "className",
1597
+ "style",
1598
+ "aria-label"
1599
+ ]);
1600
+ const opsz = opticalSize != null ? opticalSize : size === 16 ? 20 : size === 20 ? 20 : 24;
1601
+ const classes = [
1602
+ "material-symbols-outlined select-none shrink-0 inline-block leading-none",
1603
+ className
1604
+ ].filter(Boolean).join(" ");
1605
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
1606
+ "span",
1607
+ __spreadProps(__spreadValues({
1608
+ ref,
1609
+ className: classes,
1610
+ "aria-hidden": ariaLabel ? void 0 : true,
1611
+ "aria-label": ariaLabel,
1612
+ role: ariaLabel ? "img" : void 0,
1613
+ style: __spreadValues({
1614
+ fontSize: `${size}px`,
1615
+ width: `${size}px`,
1616
+ height: `${size}px`,
1617
+ fontVariationSettings: `'FILL' ${fill ? 1 : 0}, 'wght' ${weight}, 'GRAD' ${grade}, 'opsz' ${opsz}`
1618
+ }, style)
1619
+ }, rest), {
1620
+ children: name
1621
+ })
1622
+ );
1623
+ }
1624
+ );
1625
+ Icon.displayName = "Icon";
1626
+
1627
+ // src/components/Link/Link.tsx
1628
+ var import_react15 = require("react");
1629
+ var import_jsx_runtime15 = require("react/jsx-runtime");
1630
+ var linkStyleClasses = {
1631
+ brand: "font-sans text-link-text-enabled",
1632
+ white: "font-sans text-link-text-enabled-inverse",
1633
+ black: "font-sans text-link-text-enabled-dark",
1634
+ brandLooped: "font-looped text-link-text-enabled",
1635
+ whiteLooped: "font-looped text-link-text-enabled-inverse",
1636
+ blackLooped: "font-looped text-link-text-enabled-dark"
1637
+ };
1638
+ var linkVariantClasses = {
1639
+ xs: "text-link-extra-small gap-2",
1640
+ sm: "text-link-small gap-2",
1641
+ md: "text-link-medium gap-2",
1642
+ lg: "text-link-large gap-4"
1643
+ };
1644
+ var iconVariantClasses = {
1645
+ xs: "w-20 h-20",
1646
+ sm: "w-20 h-20",
1647
+ md: "w-20 h-20",
1648
+ lg: "w-24 h-24"
1649
+ };
1650
+ function SuccessIcon3({ className }) {
1651
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
1652
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { d: "M10 18a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z", stroke: "currentColor", strokeWidth: "1.5" }),
1653
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { d: "m7 10 2 2 4-4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })
1654
+ ] });
1655
+ }
1656
+ var Link = (0, import_react15.forwardRef)(
1657
+ (_a, ref) => {
1658
+ var _b = _a, {
1659
+ variant = "sm",
1660
+ isInline = false,
1661
+ linkStyle = "brand",
1662
+ text,
1663
+ href,
1664
+ icon = true,
1665
+ className = "",
1666
+ children
1667
+ } = _b, rest = __objRest(_b, [
1668
+ "variant",
1669
+ "isInline",
1670
+ "linkStyle",
1671
+ "text",
1672
+ "href",
1673
+ "icon",
1674
+ "className",
1675
+ "children"
1676
+ ]);
1677
+ const styleClass = linkStyleClasses[linkStyle];
1678
+ const variantClass = linkVariantClasses[variant];
1679
+ const iconClass = iconVariantClasses[variant];
1680
+ const classes = [
1681
+ "flex items-center",
1682
+ isInline ? "underline" : "",
1683
+ styleClass,
1684
+ variantClass,
1685
+ className
1686
+ ].filter(Boolean).join(" ");
1687
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", __spreadProps(__spreadValues({ ref, role: "link", className: classes }, rest), { children: [
1688
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("a", { className: "", href, children: text }),
1689
+ icon && !isInline ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(SuccessIcon3, { className: iconClass }) : null
1690
+ ] }));
1691
+ }
1692
+ );
1693
+ Link.displayName = "Link";
1694
+
1695
+ // src/components/Radio/Radio.tsx
1696
+ var import_react16 = require("react");
1697
+ var import_jsx_runtime16 = require("react/jsx-runtime");
1698
+ var Radio = (0, import_react16.forwardRef)(
1699
+ (_a, ref) => {
1700
+ var _b = _a, {
1701
+ size = "sm",
1702
+ label,
1703
+ description,
1704
+ error = false,
1705
+ checked,
1706
+ defaultChecked,
1707
+ disabled = false,
1708
+ className = "",
1709
+ id,
1710
+ name
1711
+ } = _b, rest = __objRest(_b, [
1712
+ "size",
1713
+ "label",
1714
+ "description",
1715
+ "error",
1716
+ "checked",
1717
+ "defaultChecked",
1718
+ "disabled",
1719
+ "className",
1720
+ "id",
1721
+ "name"
1722
+ ]);
1723
+ const reactId = (0, import_react16.useId)();
1724
+ const inputId = id != null ? id : reactId;
1725
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1726
+ "div",
1727
+ {
1728
+ className: `${disabled ? "cursor-not-allowed" : "cursor-pointer"} ${className}`,
1729
+ children: /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
1730
+ "label",
1731
+ {
1732
+ htmlFor: inputId,
1733
+ className: `flex gap-4 ${disabled ? "pointer-events-none text-gray-400" : "text-gray-900 cursor-pointer"}`,
1734
+ children: [
1735
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { children: [
1736
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1737
+ "input",
1738
+ __spreadValues({
1739
+ ref,
1740
+ id: inputId,
1741
+ type: "radio",
1742
+ className: "sr-only peer",
1743
+ checked,
1744
+ defaultChecked,
1745
+ disabled,
1746
+ name
1747
+ }, rest)
1748
+ ),
1749
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1750
+ "div",
1751
+ {
1752
+ className: `relative box flex items-center justify-center rounded-full border-2 group bg-white
1753
+ ${size === "sm" ? "h-16 w-16 my-4 ml-3 mr-3" : "m-3 h-20 w-20 text-label-large"}
1754
+ ${error ? "border-red-500" : "border-gray-600 peer-checked:border-blue-600 peer-disabled:border-gray-400!"}
1755
+ `,
1756
+ children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1757
+ "span",
1758
+ {
1759
+ className: `absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2
1760
+ ${size === "sm" ? "h-8 w-8" : "h-10 w-10"}
1761
+ rounded-full bg-white group-peer-checked:bg-blue-600 group-peer-disabled:bg-white`
1762
+ }
1763
+ )
1764
+ }
1765
+ )
1766
+ ] }),
1767
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
1768
+ "div",
1769
+ {
1770
+ className: `flex flex-col gap-1 ${size === "sm" ? "mt-2" : "mt-4"}`,
1771
+ children: [
1772
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1773
+ "p",
1774
+ {
1775
+ className: `
1776
+ ${size === "sm" ? "text-label-medium" : "text-label-large"}
1777
+ ${disabled ? "text-gray-400" : "text-gray-900"}
1778
+ `,
1779
+ children: label
1780
+ }
1781
+ ),
1782
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1783
+ "p",
1784
+ {
1785
+ className: `text-caption-caption ${disabled ? "text-gray-400" : error ? "text-red-600" : "text-gray-600"}`,
1786
+ children: description
1787
+ }
1788
+ )
1789
+ ]
1790
+ }
1791
+ )
1792
+ ]
1793
+ }
1794
+ )
1795
+ }
1796
+ );
1797
+ }
1798
+ );
1799
+ Radio.displayName = "Radio";
1800
+
1801
+ // src/components/SegmentControl/SegmentControl.tsx
1802
+ var import_react17 = require("react");
1803
+ var import_jsx_runtime17 = require("react/jsx-runtime");
1804
+ var SegmentControl = (0, import_react17.forwardRef)(
1805
+ (_a, ref) => {
1806
+ var _b = _a, { size = "md", items, selected, setSelected, className = "" } = _b, rest = __objRest(_b, ["size", "items", "selected", "setSelected", "className"]);
1807
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
1808
+ "div",
1809
+ __spreadProps(__spreadValues({
1810
+ ref,
1811
+ className: `bg-background-tertiary rounded-full flex flex-row items-center justify-center p-4 gap-4 ${className}`
1812
+ }, rest), {
1813
+ children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
1814
+ "div",
1815
+ {
1816
+ onClick: () => setSelected == null ? void 0 : setSelected(item.value),
1817
+ className: `cursor-pointer rounded-full text-center grow
1818
+ ${size === "sm" ? "px-8 py-6 text-label-medium" : size === "md" ? "px-12 py-10 text-label-large" : "px-16 py-14 text-label-large"} ${selected === item.value ? "bg-segmented-control-background-active shadow-base text-segmented-control-text-primary hover:bg-segmented-control-background-active-hover" : "bg-segmented-control-background-enabled text-segmented-control-text-primary hover:bg-segmented-control-background-hover"} `,
1819
+ children: item.label
1820
+ },
1821
+ item.value
1822
+ ))
1823
+ })
1824
+ );
1825
+ }
1826
+ );
1827
+ SegmentControl.displayName = "SegmentControl";
1828
+
1829
+ // src/components/Slider/Slider.tsx
1830
+ var import_react18 = require("react");
1831
+ var import_jsx_runtime18 = require("react/jsx-runtime");
1832
+ var sizeConfig = {
1833
+ small: {
1834
+ trackH: "h-4",
1835
+ thumbPx: 24,
1836
+ thumbClass: "h-24 w-24",
1837
+ iconPx: 12,
1838
+ containerH: "h-24",
1839
+ label: "text-sm leading-20",
1840
+ description: "text-xs leading-16"
1841
+ },
1842
+ medium: {
1843
+ trackH: "h-6",
1844
+ thumbPx: 28,
1845
+ thumbClass: "h-28 w-28",
1846
+ iconPx: 14,
1847
+ containerH: "h-28",
1848
+ label: "text-base leading-24",
1849
+ description: "text-sm leading-20"
1850
+ },
1851
+ large: {
1852
+ trackH: "h-8",
1853
+ thumbPx: 32,
1854
+ thumbClass: "h-32 w-32",
1855
+ iconPx: 16,
1856
+ containerH: "h-32",
1857
+ label: "text-base leading-24",
1858
+ description: "text-sm leading-20"
1859
+ }
1860
+ };
1861
+ function ChevronGlyphs({ size, color }) {
1862
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
1863
+ "svg",
1864
+ {
1865
+ width: size,
1866
+ height: size,
1867
+ viewBox: "0 0 12 12",
1868
+ fill: "none",
1869
+ xmlns: "http://www.w3.org/2000/svg",
1870
+ "aria-hidden": "true",
1871
+ children: [
1872
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
1873
+ "path",
1874
+ {
1875
+ d: "M4.75 3.25L2.25 6L4.75 8.75",
1876
+ stroke: color,
1877
+ strokeWidth: "1.25",
1878
+ strokeLinecap: "round",
1879
+ strokeLinejoin: "round"
1880
+ }
1881
+ ),
1882
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
1883
+ "path",
1884
+ {
1885
+ d: "M7.25 3.25L9.75 6L7.25 8.75",
1886
+ stroke: color,
1887
+ strokeWidth: "1.25",
1888
+ strokeLinecap: "round",
1889
+ strokeLinejoin: "round"
1890
+ }
1891
+ )
1892
+ ]
1893
+ }
1894
+ );
1895
+ }
1896
+ var Slider = (0, import_react18.forwardRef)(
1897
+ (_a, ref) => {
1898
+ var _b = _a, {
1899
+ size = "medium",
1900
+ label,
1901
+ description,
1902
+ error = false,
1903
+ showValue = false,
1904
+ min = 0,
1905
+ max = 100,
1906
+ step = 1,
1907
+ value: controlledValue,
1908
+ defaultValue,
1909
+ disabled = false,
1910
+ className = "",
1911
+ id,
1912
+ onChange,
1913
+ "aria-label": ariaLabelProp
1914
+ } = _b, rest = __objRest(_b, [
1915
+ "size",
1916
+ "label",
1917
+ "description",
1918
+ "error",
1919
+ "showValue",
1920
+ "min",
1921
+ "max",
1922
+ "step",
1923
+ "value",
1924
+ "defaultValue",
1925
+ "disabled",
1926
+ "className",
1927
+ "id",
1928
+ "onChange",
1929
+ "aria-label"
1930
+ ]);
1931
+ const reactId = (0, import_react18.useId)();
1932
+ const inputId = id != null ? id : reactId;
1933
+ const sz = sizeConfig[size];
1934
+ const ariaLabel = ariaLabelProp != null ? ariaLabelProp : typeof label === "string" ? void 0 : "Slider";
1935
+ const ariaDescriptionId = description ? `${inputId}-description` : void 0;
1936
+ const isControlled = controlledValue !== void 0;
1937
+ const [internalValue, setInternalValue] = (0, import_react18.useState)(defaultValue != null ? defaultValue : min);
1938
+ const currentValue = isControlled ? controlledValue : internalValue;
1939
+ const handleChange = (0, import_react18.useCallback)(
1940
+ (e) => {
1941
+ const val = Number(e.target.value);
1942
+ if (!isControlled) {
1943
+ setInternalValue(val);
1944
+ }
1945
+ onChange == null ? void 0 : onChange(val, e);
1946
+ },
1947
+ [isControlled, onChange]
1948
+ );
1949
+ const percent = (currentValue - min) / (max - min) * 100;
1950
+ const trackBg = disabled ? "bg-slider-track-disabled" : "bg-slider-track";
1951
+ const fillBg = disabled ? "bg-slider-fill-disabled" : error ? "bg-slider-fill-error" : "bg-slider-fill";
1952
+ const thumbBorder = disabled ? "border-slider-thumb-border-disabled" : error ? "border-slider-thumb-border-error" : "border-gray-200";
1953
+ const thumbBg = disabled ? "bg-slider-thumb-disabled" : "bg-slider-thumb";
1954
+ const iconColor = disabled ? "var(--color-gray-400)" : "var(--color-gray-500)";
1955
+ const labelColor = disabled ? "text-slider-label-disabled" : error ? "text-slider-label-error" : "text-slider-label";
1956
+ const descriptionColor = disabled ? "text-slider-label-disabled" : "text-slider-description";
1957
+ const thumbOffset = percent * sz.thumbPx / 100;
1958
+ const fillOffset = sz.thumbPx / 2 - thumbOffset;
1959
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
1960
+ "div",
1961
+ {
1962
+ className: ["flex w-full flex-col gap-8 font-sans", className].filter(Boolean).join(" "),
1963
+ children: [
1964
+ (label || showValue && !disabled) && /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "flex items-center justify-between", children: [
1965
+ label && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
1966
+ "label",
1967
+ {
1968
+ htmlFor: inputId,
1969
+ className: [
1970
+ sz.label,
1971
+ "font-medium",
1972
+ labelColor,
1973
+ disabled ? "cursor-not-allowed" : "cursor-default"
1974
+ ].join(" "),
1975
+ children: label
1976
+ }
1977
+ ),
1978
+ showValue && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
1979
+ "span",
1980
+ {
1981
+ className: [sz.description, "tabular-nums", labelColor].join(" "),
1982
+ children: currentValue
1983
+ }
1984
+ )
1985
+ ] }),
1986
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
1987
+ "div",
1988
+ {
1989
+ className: [
1990
+ "relative flex items-center",
1991
+ sz.containerH,
1992
+ disabled ? "cursor-not-allowed" : "cursor-pointer"
1993
+ ].join(" "),
1994
+ children: [
1995
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
1996
+ "div",
1997
+ {
1998
+ className: [
1999
+ "absolute inset-x-0 rounded-full",
2000
+ sz.trackH,
2001
+ trackBg
2002
+ ].join(" ")
2003
+ }
2004
+ ),
2005
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2006
+ "div",
2007
+ {
2008
+ className: ["absolute left-0 rounded-full", sz.trackH, fillBg].join(" "),
2009
+ style: { width: `calc(${percent}% + ${fillOffset}px)` }
2010
+ }
2011
+ ),
2012
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2013
+ "input",
2014
+ __spreadValues({
2015
+ ref,
2016
+ id: inputId,
2017
+ type: "range",
2018
+ min,
2019
+ max,
2020
+ step,
2021
+ value: currentValue,
2022
+ disabled,
2023
+ onChange: handleChange,
2024
+ "aria-label": ariaLabel,
2025
+ "aria-describedby": ariaDescriptionId,
2026
+ className: [
2027
+ "peer absolute inset-0 z-20 w-full appearance-none bg-transparent opacity-0",
2028
+ disabled ? "cursor-not-allowed" : "cursor-pointer",
2029
+ "focus:outline-none"
2030
+ ].join(" ")
2031
+ }, rest)
2032
+ ),
2033
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2034
+ "div",
2035
+ {
2036
+ className: [
2037
+ "pointer-events-none absolute z-10 flex items-center justify-center rounded-full border",
2038
+ sz.thumbClass,
2039
+ thumbBg,
2040
+ thumbBorder,
2041
+ disabled ? "" : "shadow-base transition-shadow duration-150",
2042
+ !disabled && (error ? "peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-slider-ring-error" : "peer-focus-visible:ring-2 peer-focus-visible:ring-offset-2 peer-focus-visible:ring-slider-ring"),
2043
+ !disabled && "peer-hover:shadow-medium"
2044
+ ].filter(Boolean).join(" "),
2045
+ style: { left: `calc(${percent}% - ${thumbOffset}px)` },
2046
+ children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(ChevronGlyphs, { size: sz.iconPx, color: iconColor })
2047
+ }
2048
+ )
2049
+ ]
2050
+ }
2051
+ ),
2052
+ description && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2053
+ "span",
2054
+ {
2055
+ id: ariaDescriptionId,
2056
+ className: [sz.description, descriptionColor].join(" "),
2057
+ children: description
2058
+ }
2059
+ )
2060
+ ]
2061
+ }
2062
+ );
2063
+ }
2064
+ );
2065
+ Slider.displayName = "Slider";
2066
+
2067
+ // src/components/Tab/Tab.tsx
2068
+ var import_react19 = require("react");
2069
+ var import_jsx_runtime19 = require("react/jsx-runtime");
2070
+ var Tab = (0, import_react19.forwardRef)(
2071
+ (_a, ref) => {
2072
+ var _b = _a, {
2073
+ size = "md",
2074
+ label,
2075
+ value,
2076
+ isDisabled = false,
2077
+ selected,
2078
+ setSelected,
2079
+ className = ""
2080
+ } = _b, rest = __objRest(_b, [
2081
+ "size",
2082
+ "label",
2083
+ "value",
2084
+ "isDisabled",
2085
+ "selected",
2086
+ "setSelected",
2087
+ "className"
2088
+ ]);
2089
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
2090
+ "div",
2091
+ __spreadProps(__spreadValues({
2092
+ ref,
2093
+ className: `flex items-center justify-center
2094
+ ${size === "md" ? "text-label-medium px-16 pt-12 pb-8" : "text-label-large p-16"}
2095
+ ${value === selected ? isDisabled ? "cursor-not-allowed text-gray-400 border-gray-100 border-b-2" : "text-blue-600 border-blue-600 border-b-2 cursor-pointer" : isDisabled ? "cursor-not-allowed text-gray-400" : "text-gray-600 hover:border-b-2 hover:border-gray-200 cursor-pointer"}
2096
+ ${className}`,
2097
+ onClick: () => !isDisabled && (setSelected == null ? void 0 : setSelected(value))
2098
+ }, rest), {
2099
+ children: label
2100
+ })
2101
+ );
2102
+ }
2103
+ );
2104
+ Tab.displayName = "Tab";
2105
+
2106
+ // src/components/TextArea/TextArea.tsx
2107
+ var import_react20 = require("react");
2108
+ var import_jsx_runtime20 = require("react/jsx-runtime");
2109
+ var TextArea = (0, import_react20.forwardRef)(
2110
+ (_a, ref) => {
2111
+ var _b = _a, {
2112
+ maxText = 500,
2113
+ height = 100,
2114
+ error,
2115
+ label,
2116
+ placeholder,
2117
+ description,
2118
+ icon,
2119
+ isDisabled = false,
2120
+ isLoading = false,
2121
+ isVertify = false,
2122
+ isClearable = true,
2123
+ disabled,
2124
+ value,
2125
+ onChange
2126
+ } = _b, props = __objRest(_b, [
2127
+ "maxText",
2128
+ "height",
2129
+ "error",
2130
+ "label",
2131
+ "placeholder",
2132
+ "description",
2133
+ "icon",
2134
+ "isDisabled",
2135
+ "isLoading",
2136
+ "isVertify",
2137
+ "isClearable",
2138
+ "disabled",
2139
+ "value",
2140
+ "onChange"
2141
+ ]);
2142
+ const [isFocused, setIsFocused] = (0, import_react20.useState)(false);
2143
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "w-full flex flex-col gap-4", children: [
2144
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "w-full flex justify-between items-center ", children: [
2145
+ label ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2146
+ "p",
2147
+ {
2148
+ className: `text-label-medium text-left items-left ${isDisabled || disabled ? "text-gray-400" : "text-gray-900"}`,
2149
+ children: label
2150
+ }
2151
+ ) : /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_jsx_runtime20.Fragment, {}),
2152
+ maxText ? /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("p", { className: "text-gray-400 text-caption-caption", children: [
2153
+ " ",
2154
+ (value == null ? void 0 : value.length) || 0,
2155
+ " / ",
2156
+ maxText
2157
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_jsx_runtime20.Fragment, {})
2158
+ ] }),
2159
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "relative w-full", children: [
2160
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2161
+ "textarea",
2162
+ __spreadValues({
2163
+ ref,
2164
+ name: "text-input",
2165
+ placeholder,
2166
+ disabled: isDisabled || disabled || isLoading,
2167
+ onFocus: () => setIsFocused(true),
2168
+ onBlur: () => setIsFocused(false),
2169
+ value,
2170
+ onChange,
2171
+ className: `w-full min-h-${height} focus:min-h-${height - 2} pt-12 pb-8 pr-44 pl-16 focus:pt-11 focus:pb-7 focus:pr-43 focus:pl-15 border border-gray-300 text-base rounded-md focus:outline-none focus:ring-1 focus:m-1 focus:w-[calc(100%-2px)] ${isDisabled || disabled ? "bg-gray-50 text-gray-400" : error ? "bg-white text-gray-900 border-red-500 focus:border-red-500 focus:ring-red-500" : "bg-white text-gray-900 focus:border-blue-600 focus:ring-blue-600"}`
2172
+ }, props)
2173
+ ),
2174
+ isLoading ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2175
+ Loading,
2176
+ {
2177
+ size: "sm",
2178
+ className: `absolute right-12 top-12`
2179
+ }
2180
+ ) : isClearable && isFocused && value ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2181
+ "svg",
2182
+ {
2183
+ xmlns: "http://www.w3.org/2000/svg",
2184
+ width: "20",
2185
+ height: "20",
2186
+ viewBox: "0 0 20 20",
2187
+ fill: "none",
2188
+ className: "text-gray-900 flex h-20 w-20 items-center justify-center absolute right-12 top-12",
2189
+ onMouseDown: (e) => {
2190
+ e.preventDefault();
2191
+ onChange == null ? void 0 : onChange({ target: { value: "" } });
2192
+ },
2193
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2194
+ "path",
2195
+ {
2196
+ d: "M14.7119 6.0625L10.7744 10L14.7119 13.9375L13.9375 14.7119L10 10.7744L6.0625 14.7119L5.28809 13.9375L9.22559 10L5.28809 6.0625L6.0625 5.28809L10 9.22559L13.9375 5.28809L14.7119 6.0625Z",
2197
+ fill: "#111827"
2198
+ }
2199
+ )
2200
+ }
2201
+ ) : isVertify ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2202
+ "svg",
2203
+ {
2204
+ xmlns: "http://www.w3.org/2000/svg",
2205
+ width: "20",
2206
+ height: "20",
2207
+ viewBox: "0 0 20 20",
2208
+ fill: "none",
2209
+ className: "text-green-600 flex h-20 w-20 items-center justify-center absolute right-12 top-12",
2210
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2211
+ "path",
2212
+ {
2213
+ "fill-rule": "evenodd",
2214
+ "clip-rule": "evenodd",
2215
+ d: "M15.6328 6.64062L8.10449 14.1494L4.36719 10.4326L5.13281 9.64551L8.10449 12.6172L14.8672 5.875L15.6328 6.64062Z",
2216
+ fill: "#16A34A"
2217
+ }
2218
+ )
2219
+ }
2220
+ ) : error ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2221
+ "svg",
2222
+ {
2223
+ xmlns: "http://www.w3.org/2000/svg",
2224
+ width: "20",
2225
+ height: "20",
2226
+ viewBox: "0 0 20 20",
2227
+ fill: "none",
2228
+ className: "text-red-500 flex h-20 w-20 items-center justify-center absolute right-12 top-12",
2229
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
2230
+ "path",
2231
+ {
2232
+ d: "M10.0078 2.41699C11.0548 2.41699 12.0363 2.61407 12.9512 3.00879C13.8657 3.40341 14.6687 3.94646 15.3604 4.6377C16.0522 5.32922 16.5962 6.13426 16.9912 7.05176C17.386 7.96936 17.583 8.95002 17.583 9.99316C17.583 11.0363 17.3859 12.0187 16.9912 12.9404C16.5966 13.862 16.0536 14.6687 15.3623 15.3604C14.6708 16.0522 13.8657 16.5962 12.9482 16.9912C12.0306 17.386 11.05 17.583 10.0068 17.583C8.96373 17.583 7.9813 17.3859 7.05957 16.9912C6.13798 16.5966 5.33135 16.0536 4.63965 15.3623C3.94784 14.6708 3.40379 13.8642 3.00879 12.9434C2.61398 12.0228 2.41703 11.039 2.41699 9.99219C2.41699 8.94524 2.61407 7.96369 3.00879 7.04883C3.40341 6.13429 3.94646 5.33128 4.6377 4.63965C5.32922 3.94784 6.13581 3.40379 7.05664 3.00879C7.97723 2.61398 8.961 2.41703 10.0078 2.41699ZM10.0039 12.5967C9.83828 12.5968 9.69804 12.6527 9.58301 12.7646C9.46793 12.8769 9.41016 13.0159 9.41016 13.1816C9.4102 13.3472 9.46621 13.4875 9.57812 13.6025C9.69035 13.7177 9.83026 13.7754 9.99609 13.7754C10.1617 13.7753 10.302 13.7195 10.417 13.6074C10.5321 13.4952 10.5898 13.3562 10.5898 13.1904C10.5898 13.0246 10.534 12.8837 10.4219 12.7686C10.3097 12.6536 10.1697 12.5967 10.0039 12.5967ZM9.45801 11.0645H10.542V6.06445H9.45801V11.0645Z",
2233
+ fill: "#EF4444"
2234
+ }
2235
+ )
2236
+ }
2237
+ ) : /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_jsx_runtime20.Fragment, {})
2238
+ ] }),
2239
+ error ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("p", { className: "text-caption-caption text-left items-left text-red-600", children: error }) : description ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("p", { className: "text-caption-caption text-left items-left text-gray-600", children: description }) : /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_jsx_runtime20.Fragment, {})
2240
+ ] });
2241
+ }
2242
+ );
2243
+ TextArea.displayName = "TextArea";
2244
+
2245
+ // src/components/TextField/TextField.tsx
2246
+ var import_react21 = require("react");
2247
+ var import_jsx_runtime21 = require("react/jsx-runtime");
2248
+ var TextField = (0, import_react21.forwardRef)(
2249
+ (_a, ref) => {
2250
+ var _b = _a, {
2251
+ inputSize,
2252
+ error,
2253
+ label,
2254
+ placeholder,
2255
+ description,
2256
+ icon,
2257
+ isDisabled = false,
2258
+ isLoading = false,
2259
+ isVertify = false,
2260
+ isUnrequired = false,
2261
+ isClearable = true,
2262
+ disabled,
2263
+ value,
2264
+ onChange
2265
+ } = _b, props = __objRest(_b, [
2266
+ "inputSize",
2267
+ "error",
2268
+ "label",
2269
+ "placeholder",
2270
+ "description",
2271
+ "icon",
2272
+ "isDisabled",
2273
+ "isLoading",
2274
+ "isVertify",
2275
+ "isUnrequired",
2276
+ "isClearable",
2277
+ "disabled",
2278
+ "value",
2279
+ "onChange"
2280
+ ]);
2281
+ const [isFocused, setIsFocused] = (0, import_react21.useState)(false);
2282
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "w-full flex flex-col gap-4", children: [
2283
+ label ? /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
2284
+ "p",
2285
+ {
2286
+ className: `text-label-medium text-left items-left ${isDisabled || disabled ? "text-gray-400" : "text-gray-900"}`,
2287
+ children: [
2288
+ label,
2289
+ " ",
2290
+ isUnrequired && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("span", { className: "text-gray-400", children: `(\u0E44\u0E21\u0E48\u0E1A\u0E31\u0E07\u0E04\u0E31\u0E1A)` })
2291
+ ]
2292
+ }
2293
+ ) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_jsx_runtime21.Fragment, {}),
2294
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "relative w-full", children: [
2295
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2296
+ "input",
2297
+ __spreadValues({
2298
+ ref,
2299
+ name: "text-input",
2300
+ type: "text",
2301
+ placeholder,
2302
+ disabled: isDisabled || disabled || isLoading,
2303
+ onFocus: () => setIsFocused(true),
2304
+ onBlur: () => setIsFocused(false),
2305
+ value,
2306
+ onChange,
2307
+ className: `w-full ${inputSize === "md" ? "px-16 py-12 focus:px-15 focus:py-11" : "p-16 focus:p-15"} border border-gray-300 text-base rounded-md focus:outline-none focus:ring-1 focus:m-1 focus:w-[calc(100%-2px)] ${isDisabled || disabled ? "bg-gray-50 text-gray-400" : error ? "bg-white text-gray-900 border-red-500 focus:border-red-500 focus:ring-red-500" : "bg-white text-gray-900 focus:border-blue-600 focus:ring-blue-600"}`
2308
+ }, props)
2309
+ ),
2310
+ isLoading ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2311
+ Loading,
2312
+ {
2313
+ size: "sm",
2314
+ className: `absolute right-16 top-1/2 -translate-y-1/2`
2315
+ }
2316
+ ) : isClearable && isFocused && value ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2317
+ "svg",
2318
+ {
2319
+ xmlns: "http://www.w3.org/2000/svg",
2320
+ width: "20",
2321
+ height: "20",
2322
+ viewBox: "0 0 20 20",
2323
+ fill: "none",
2324
+ className: "text-gray-900 flex h-20 w-20 items-center justify-center absolute right-16 top-1/2 -translate-y-1/2",
2325
+ onMouseDown: (e) => {
2326
+ e.preventDefault();
2327
+ onChange == null ? void 0 : onChange({ target: { value: "" } });
2328
+ },
2329
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2330
+ "path",
2331
+ {
2332
+ d: "M14.7119 6.0625L10.7744 10L14.7119 13.9375L13.9375 14.7119L10 10.7744L6.0625 14.7119L5.28809 13.9375L9.22559 10L5.28809 6.0625L6.0625 5.28809L10 9.22559L13.9375 5.28809L14.7119 6.0625Z",
2333
+ fill: "#111827"
2334
+ }
2335
+ )
2336
+ }
2337
+ ) : isVertify ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2338
+ "svg",
2339
+ {
2340
+ xmlns: "http://www.w3.org/2000/svg",
2341
+ width: "20",
2342
+ height: "20",
2343
+ viewBox: "0 0 20 20",
2344
+ fill: "none",
2345
+ className: "text-green-600 flex h-20 w-20 items-center justify-center absolute right-16 top-1/2 -translate-y-1/2",
2346
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2347
+ "path",
2348
+ {
2349
+ "fill-rule": "evenodd",
2350
+ "clip-rule": "evenodd",
2351
+ d: "M15.6328 6.64062L8.10449 14.1494L4.36719 10.4326L5.13281 9.64551L8.10449 12.6172L14.8672 5.875L15.6328 6.64062Z",
2352
+ fill: "#16A34A"
2353
+ }
2354
+ )
2355
+ }
2356
+ ) : error ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2357
+ "svg",
2358
+ {
2359
+ xmlns: "http://www.w3.org/2000/svg",
2360
+ width: "20",
2361
+ height: "20",
2362
+ viewBox: "0 0 20 20",
2363
+ fill: "none",
2364
+ className: "text-red-500 flex h-20 w-20 items-center justify-center absolute right-16 top-1/2 -translate-y-1/2",
2365
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2366
+ "path",
2367
+ {
2368
+ d: "M10.0078 2.41699C11.0548 2.41699 12.0363 2.61407 12.9512 3.00879C13.8657 3.40341 14.6687 3.94646 15.3604 4.6377C16.0522 5.32922 16.5962 6.13426 16.9912 7.05176C17.386 7.96936 17.583 8.95002 17.583 9.99316C17.583 11.0363 17.3859 12.0187 16.9912 12.9404C16.5966 13.862 16.0536 14.6687 15.3623 15.3604C14.6708 16.0522 13.8657 16.5962 12.9482 16.9912C12.0306 17.386 11.05 17.583 10.0068 17.583C8.96373 17.583 7.9813 17.3859 7.05957 16.9912C6.13798 16.5966 5.33135 16.0536 4.63965 15.3623C3.94784 14.6708 3.40379 13.8642 3.00879 12.9434C2.61398 12.0228 2.41703 11.039 2.41699 9.99219C2.41699 8.94524 2.61407 7.96369 3.00879 7.04883C3.40341 6.13429 3.94646 5.33128 4.6377 4.63965C5.32922 3.94784 6.13581 3.40379 7.05664 3.00879C7.97723 2.61398 8.961 2.41703 10.0078 2.41699ZM10.0039 12.5967C9.83828 12.5968 9.69804 12.6527 9.58301 12.7646C9.46793 12.8769 9.41016 13.0159 9.41016 13.1816C9.4102 13.3472 9.46621 13.4875 9.57812 13.6025C9.69035 13.7177 9.83026 13.7754 9.99609 13.7754C10.1617 13.7753 10.302 13.7195 10.417 13.6074C10.5321 13.4952 10.5898 13.3562 10.5898 13.1904C10.5898 13.0246 10.534 12.8837 10.4219 12.7686C10.3097 12.6536 10.1697 12.5967 10.0039 12.5967ZM9.45801 11.0645H10.542V6.06445H9.45801V11.0645Z",
2369
+ fill: "#EF4444"
2370
+ }
2371
+ )
2372
+ }
2373
+ ) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_jsx_runtime21.Fragment, {})
2374
+ ] }),
2375
+ error ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { className: "text-caption-caption text-left items-left text-red-600", children: error }) : description ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { className: "text-caption-caption text-left items-left text-gray-600", children: description }) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_jsx_runtime21.Fragment, {})
2376
+ ] });
2377
+ }
2378
+ );
2379
+ TextField.displayName = "TextField";
2380
+
2381
+ // src/components/Toast/Toast.tsx
2382
+ var import_react22 = require("react");
2383
+ var import_jsx_runtime22 = require("react/jsx-runtime");
2384
+ function CheckCircleIcon({ className }) {
2385
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
2386
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: "10", cy: "10", r: "8", stroke: "currentColor", strokeWidth: "1.5" }),
2387
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("path", { d: "m7 10 2 2 4-4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" })
2388
+ ] });
2389
+ }
2390
+ function ProgressIcon({ className }) {
2391
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
2392
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: "10", cy: "10", r: "8", stroke: "currentColor", strokeWidth: "1.5", opacity: "0.3" }),
2393
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("path", { d: "M10 2a8 8 0 0 1 8 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("animateTransform", { attributeName: "transform", type: "rotate", from: "0 10 10", to: "360 10 10", dur: "1s", repeatCount: "indefinite" }) })
2394
+ ] });
2395
+ }
2396
+ function ErrorIcon({ className }) {
2397
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("svg", { className, width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", "aria-hidden": "true", children: [
2398
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: "10", cy: "10", r: "8", stroke: "currentColor", strokeWidth: "1.5" }),
2399
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("path", { d: "M10 6.5v4M10 13.5h.01", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round" })
2400
+ ] });
2401
+ }
2402
+ function CloseIcon3({ className }) {
2403
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("svg", { className, width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("path", { d: "M12 4 4 12M4 4l8 8", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
2404
+ }
2405
+ var defaultIcons3 = {
2406
+ default: CheckCircleIcon,
2407
+ progress: ProgressIcon,
2408
+ error: ErrorIcon
2409
+ };
2410
+ var typeClasses = {
2411
+ default: "bg-toast-default-bg text-toast-default-text",
2412
+ progress: "bg-toast-progress-bg text-toast-progress-text",
2413
+ error: "bg-toast-error-bg text-toast-error-text"
2414
+ };
2415
+ var iconColorClasses = {
2416
+ default: "text-toast-default-icon",
2417
+ progress: "text-toast-progress-icon",
2418
+ error: "text-toast-error-icon"
2419
+ };
2420
+ var Toast = (0, import_react22.forwardRef)(
2421
+ (_a, ref) => {
2422
+ var _b = _a, {
2423
+ type = "default",
2424
+ icon = true,
2425
+ actionLabel,
2426
+ onAction,
2427
+ onDismiss,
2428
+ children,
2429
+ className = ""
2430
+ } = _b, rest = __objRest(_b, [
2431
+ "type",
2432
+ "icon",
2433
+ "actionLabel",
2434
+ "onAction",
2435
+ "onDismiss",
2436
+ "children",
2437
+ "className"
2438
+ ]);
2439
+ const DefaultIcon = defaultIcons3[type];
2440
+ const classes = [
2441
+ "inline-flex items-center gap-12 font-sans",
2442
+ "rounded-xl px-16 py-12",
2443
+ "min-w-[320px] max-w-[480px]",
2444
+ "shadow-large",
2445
+ typeClasses[type],
2446
+ className
2447
+ ].filter(Boolean).join(" ");
2448
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", __spreadProps(__spreadValues({ ref, role: "alert", className: classes }, rest), { children: [
2449
+ icon && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: `shrink-0 ${iconColorClasses[type]}`, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(DefaultIcon, { className: "h-20 w-20" }) }),
2450
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "flex-1 text-sm font-medium leading-20 truncate", children }),
2451
+ actionLabel && onAction && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
2452
+ "button",
2453
+ {
2454
+ type: "button",
2455
+ onClick: onAction,
2456
+ className: "shrink-0 text-sm font-medium text-toast-action-text hover:bg-toast-action-bg-hover rounded-md px-8 py-4 transition-colors",
2457
+ children: actionLabel
2458
+ }
2459
+ ),
2460
+ onDismiss && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
2461
+ "button",
2462
+ {
2463
+ type: "button",
2464
+ onClick: onDismiss,
2465
+ className: "shrink-0 p-4 rounded-md text-toast-dismiss hover:text-toast-dismiss-hover transition-colors",
2466
+ "aria-label": "Dismiss",
2467
+ children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(CloseIcon3, { className: "h-16 w-16" })
2468
+ }
2469
+ )
2470
+ ] }));
2471
+ }
2472
+ );
2473
+ Toast.displayName = "Toast";
2474
+
2475
+ // src/components/ToggleSwitch/ToggleSwitch.tsx
2476
+ var import_react23 = require("react");
2477
+ var import_jsx_runtime23 = require("react/jsx-runtime");
2478
+ var ToggleSwitch = (0, import_react23.forwardRef)(
2479
+ (_a, ref) => {
2480
+ var _b = _a, {
2481
+ value,
2482
+ isDisabled = false,
2483
+ isSelected,
2484
+ setIsSelected,
2485
+ className = ""
2486
+ } = _b, rest = __objRest(_b, [
2487
+ "value",
2488
+ "isDisabled",
2489
+ "isSelected",
2490
+ "setIsSelected",
2491
+ "className"
2492
+ ]);
2493
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
2494
+ "label",
2495
+ __spreadProps(__spreadValues({
2496
+ ref,
2497
+ className: `inline-flex items-center ${className}`
2498
+ }, rest), {
2499
+ children: [
2500
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
2501
+ "input",
2502
+ {
2503
+ type: "checkbox",
2504
+ value,
2505
+ className: "sr-only peer",
2506
+ checked: isSelected,
2507
+ onChange: () => !isDisabled && (setIsSelected == null ? void 0 : setIsSelected(!isSelected))
2508
+ }
2509
+ ),
2510
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
2511
+ "div",
2512
+ {
2513
+ className: `${isDisabled ? "opacity-40 cursor-not-allowed" : "cursor-pointer hover:bg-gray-300 hover:peer-checked:bg-green-700"} relative w-48 h-26 bg-gray-200 rounded-full peer-checked:after:translate-x-22 rtl:peer-checked:after:-translate-x-22 peer-checked:after:border-white after:content-[''] after:absolute after:top-4 after:left-4 after:bg-white after:border-gray-300 after:border after:rounded-full after:h-18 after:w-18 after:transition-all peer-checked:bg-green-600 `
2514
+ }
2515
+ )
2516
+ ]
2517
+ })
2518
+ );
2519
+ }
2520
+ );
2521
+ ToggleSwitch.displayName = "ToggleSwitch";
2522
+
2523
+ // src/components/Tooltip/Tooltip.tsx
2524
+ var import_react24 = require("react");
2525
+ var import_jsx_runtime24 = require("react/jsx-runtime");
2526
+ var Tooltip = (0, import_react24.forwardRef)(
2527
+ (_a, ref) => {
2528
+ var _b = _a, {
2529
+ size = "md",
2530
+ children,
2531
+ headText,
2532
+ text,
2533
+ position = "top",
2534
+ className = ""
2535
+ } = _b, rest = __objRest(_b, [
2536
+ "size",
2537
+ "children",
2538
+ "headText",
2539
+ "text",
2540
+ "position",
2541
+ "className"
2542
+ ]);
2543
+ const wrapperRef = (0, import_react24.useRef)(null);
2544
+ const [isVisible, setIsVisible] = (0, import_react24.useState)(false);
2545
+ const [isHovered, setIsHovered] = (0, import_react24.useState)(false);
2546
+ (0, import_react24.useEffect)(() => {
2547
+ const handleClickOutside = (event) => {
2548
+ if (wrapperRef.current && !wrapperRef.current.contains(event.target)) {
2549
+ setIsVisible(false);
2550
+ setIsHovered(false);
2551
+ }
2552
+ };
2553
+ document.addEventListener("mousedown", handleClickOutside);
2554
+ return () => {
2555
+ document.removeEventListener("mousedown", handleClickOutside);
2556
+ };
2557
+ }, []);
2558
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
2559
+ "div",
2560
+ __spreadProps(__spreadValues({
2561
+ className: `group relative inline-block ${className}`,
2562
+ ref
2563
+ }, rest), {
2564
+ children: [
2565
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
2566
+ "div",
2567
+ {
2568
+ ref: wrapperRef,
2569
+ onClick: () => {
2570
+ if (isVisible) {
2571
+ setIsVisible(false);
2572
+ setIsHovered(false);
2573
+ } else {
2574
+ setIsVisible(true);
2575
+ }
2576
+ },
2577
+ onMouseEnter: () => setIsHovered(true),
2578
+ onMouseLeave: () => setIsHovered(false),
2579
+ children
2580
+ }
2581
+ ),
2582
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
2583
+ "div",
2584
+ {
2585
+ className: `min-w-100 max-w-300 whitespace-nowrap rounded bg-gray-900 text-white ${size === "lg" ? "text-body-regular py-12 px-16" : size === "md" ? "text-body-small px-12 pt-10 pb-8" : "text-body-small px-8 pt-6 pb-4"} ${position === "right" && `absolute left-full top-1/2 z-20 ml-8 -translate-y-1/2 ${isVisible || isHovered ? "opacity-100" : "opacity-0"}` || position === "top" && `absolute bottom-full left-1/2 z-20 mb-8 -translate-x-1/2 ${isVisible || isHovered ? "opacity-100" : "opacity-0"}` || position === "left" && `absolute right-full top-1/2 z-20 mr-8 -translate-y-1/2 ${isVisible || isHovered ? "opacity-100" : "opacity-0"}` || position === "bottom" && `absolute left-1/2 top-full z-20 mt-8 -translate-x-1/2 ${isVisible || isHovered ? "opacity-100" : "opacity-0"}`}`,
2586
+ children: [
2587
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
2588
+ "span",
2589
+ {
2590
+ className: ` ${position === "right" && `absolute -left-3 top-1/2 -z-10 h-8 w-8 -translate-y-1/2 rotate-45 rounded-xs bg-black` || position === "top" && `absolute -bottom-3 left-1/2 -z-10 h-8 w-8 -translate-x-1/2 rotate-45 rounded-xs bg-black` || position === "left" && `absolute -right-3 top-1/2 -z-10 h-8 w-8 -translate-y-1/2 rotate-45 rounded-xs bg-black` || position === "bottom" && `absolute left-1/2 -top-3 -z-10 h-8 w-8 -translate-x-1/2 rotate-45 rounded-xs bg-black`} `
2591
+ }
2592
+ ),
2593
+ headText ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
2594
+ "p",
2595
+ {
2596
+ className: `text-sm text-white font-semibold text-center ${text ? "mb-5" : ""}`,
2597
+ children: headText
2598
+ }
2599
+ ) : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_jsx_runtime24.Fragment, {}),
2600
+ text ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("p", { className: "text-xs text-white font-normal text-center text-wrap", children: text }) : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_jsx_runtime24.Fragment, {})
2601
+ ]
2602
+ }
2603
+ )
2604
+ ]
2605
+ })
2606
+ );
2607
+ }
2608
+ );
2609
+ Tooltip.displayName = "Tooltip";
2610
+ // Annotate the CommonJS export names for ESM import in node:
2611
+ 0 && (module.exports = {
2612
+ Accordion,
2613
+ AlertBanner,
2614
+ Avatar,
2615
+ Badge,
2616
+ BottomSheet,
2617
+ Branding,
2618
+ Button,
2619
+ Checkbox,
2620
+ Chip,
2621
+ Dialog,
2622
+ Dropdown,
2623
+ FinancialLogo,
2624
+ Icon,
2625
+ Link,
2626
+ Loading,
2627
+ Radio,
2628
+ SegmentControl,
2629
+ Slider,
2630
+ Tab,
2631
+ TextArea,
2632
+ TextField,
2633
+ Toast,
2634
+ ToggleSwitch,
2635
+ Tooltip
2636
+ });