@camtomlabs/malix-design-system 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/LICENSE +19 -5
  2. package/dist/index.cjs +2338 -0
  3. package/dist/index.d.cts +524 -0
  4. package/dist/index.d.ts +524 -0
  5. package/dist/index.js +2251 -0
  6. package/package.json +21 -8
  7. package/src/components/Accordion.tsx +0 -52
  8. package/src/components/Avatar.tsx +0 -18
  9. package/src/components/Badge.tsx +0 -27
  10. package/src/components/Banner.tsx +0 -75
  11. package/src/components/Breadcrumb.tsx +0 -58
  12. package/src/components/Button.tsx +0 -47
  13. package/src/components/Card.tsx +0 -34
  14. package/src/components/ChatInput.tsx +0 -53
  15. package/src/components/Checkbox.tsx +0 -85
  16. package/src/components/CreditsIndicator.tsx +0 -41
  17. package/src/components/DataTable.tsx +0 -75
  18. package/src/components/DateInput.tsx +0 -57
  19. package/src/components/Divider.tsx +0 -12
  20. package/src/components/Dropzone.tsx +0 -94
  21. package/src/components/EmptyState.tsx +0 -65
  22. package/src/components/FileCard.tsx +0 -78
  23. package/src/components/FilterTabs.tsx +0 -49
  24. package/src/components/FlyoutMenu.tsx +0 -36
  25. package/src/components/GlassPopover.tsx +0 -38
  26. package/src/components/Header.tsx +0 -22
  27. package/src/components/Input.tsx +0 -18
  28. package/src/components/InputGroup.tsx +0 -37
  29. package/src/components/LanguageSelector.tsx +0 -81
  30. package/src/components/Modal.tsx +0 -104
  31. package/src/components/OnboardingPopover.tsx +0 -61
  32. package/src/components/OperationStatus.tsx +0 -73
  33. package/src/components/Overlay.tsx +0 -66
  34. package/src/components/Pagination.tsx +0 -89
  35. package/src/components/Pill.tsx +0 -19
  36. package/src/components/PricingCard.tsx +0 -74
  37. package/src/components/ProgressBar.tsx +0 -47
  38. package/src/components/Radio.tsx +0 -56
  39. package/src/components/SectionHeader.tsx +0 -32
  40. package/src/components/SegmentedControl.tsx +0 -42
  41. package/src/components/Select.tsx +0 -62
  42. package/src/components/SelectGroup.tsx +0 -32
  43. package/src/components/SelectionCard.tsx +0 -47
  44. package/src/components/SidebarItem.tsx +0 -27
  45. package/src/components/SidebarPanel.tsx +0 -84
  46. package/src/components/SplitPane.tsx +0 -85
  47. package/src/components/StatCard.tsx +0 -64
  48. package/src/components/StatusDot.tsx +0 -26
  49. package/src/components/Stepper.tsx +0 -40
  50. package/src/components/TabBar.tsx +0 -45
  51. package/src/components/Textarea.tsx +0 -43
  52. package/src/components/Toggle.tsx +0 -50
  53. package/src/components/Tooltip.tsx +0 -33
  54. package/src/components/UserProfilePopover.tsx +0 -100
  55. package/src/components/ValidationAlert.tsx +0 -72
  56. package/src/index.ts +0 -177
package/dist/index.cjs ADDED
@@ -0,0 +1,2338 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+
30
+ // src/index.ts
31
+ var index_exports = {};
32
+ __export(index_exports, {
33
+ Accordion: () => Accordion,
34
+ Avatar: () => Avatar,
35
+ Badge: () => Badge,
36
+ Banner: () => Banner,
37
+ Breadcrumb: () => Breadcrumb,
38
+ Button: () => Button,
39
+ Card: () => Card,
40
+ ChatInput: () => ChatInput,
41
+ Checkbox: () => Checkbox,
42
+ CreditsIndicator: () => CreditsIndicator,
43
+ DataTable: () => DataTable,
44
+ DateInput: () => DateInput,
45
+ Divider: () => Divider,
46
+ Dropzone: () => Dropzone,
47
+ EmptyState: () => EmptyState,
48
+ FileCard: () => FileCard,
49
+ FilterTabs: () => FilterTabs,
50
+ FlyoutMenu: () => FlyoutMenu,
51
+ GlassPopover: () => GlassPopover,
52
+ Header: () => Header,
53
+ Input: () => Input,
54
+ InputGroup: () => InputGroup,
55
+ LanguageSelector: () => LanguageSelector,
56
+ Modal: () => Modal,
57
+ OnboardingPopover: () => OnboardingPopover,
58
+ OperationStatus: () => OperationStatus,
59
+ Overlay: () => Overlay,
60
+ Pagination: () => Pagination,
61
+ Pill: () => Pill,
62
+ PricingCard: () => PricingCard,
63
+ ProgressBar: () => ProgressBar,
64
+ Radio: () => Radio,
65
+ SearchInput: () => SearchInput,
66
+ SectionHeader: () => SectionHeader,
67
+ SegmentedControl: () => SegmentedControl,
68
+ Select: () => Select,
69
+ SelectGroup: () => SelectGroup,
70
+ SelectionCard: () => SelectionCard,
71
+ SidebarItem: () => SidebarItem,
72
+ SidebarPanel: () => SidebarPanel,
73
+ SplitPane: () => SplitPane,
74
+ StatCard: () => StatCard,
75
+ StatusDot: () => StatusDot,
76
+ Stepper: () => Stepper,
77
+ TabBar: () => TabBar,
78
+ Textarea: () => Textarea,
79
+ Toggle: () => Toggle,
80
+ Tooltip: () => Tooltip,
81
+ UserProfilePopover: () => UserProfilePopover,
82
+ ValidationAlert: () => ValidationAlert,
83
+ tokenRegistry: () => tokens_registry_default
84
+ });
85
+ module.exports = __toCommonJS(index_exports);
86
+
87
+ // src/tokens.registry.json
88
+ var tokens_registry_default = {
89
+ version: 1,
90
+ tokens: [
91
+ "--malix-background-main",
92
+ "--malix-surface",
93
+ "--malix-surface-secondary",
94
+ "--malix-surface-hover",
95
+ "--malix-foreground",
96
+ "--malix-foreground-secondary",
97
+ "--malix-foreground-tertiary",
98
+ "--malix-foreground-disabled",
99
+ "--malix-border",
100
+ "--malix-border-strong",
101
+ "--malix-border-focus",
102
+ "--malix-overlay",
103
+ "--malix-cta-primary-bg",
104
+ "--malix-primary-hover",
105
+ "--malix-primary-active",
106
+ "--malix-primary-foreground",
107
+ "--malix-primary-light",
108
+ "--malix-success",
109
+ "--malix-success-light",
110
+ "--malix-success-foreground",
111
+ "--malix-warning",
112
+ "--malix-warning-light",
113
+ "--malix-warning-foreground",
114
+ "--malix-error",
115
+ "--malix-error-light",
116
+ "--malix-error-foreground",
117
+ "--malix-info",
118
+ "--malix-info-light",
119
+ "--malix-info-foreground",
120
+ "--malix-glass-bg",
121
+ "--malix-glass-border",
122
+ "--malix-glass-blur",
123
+ "--malix-sidebar-bg",
124
+ "--malix-sidebar-hover-bg",
125
+ "--malix-sidebar-active-bg",
126
+ "--malix-space-xs",
127
+ "--malix-space-sm",
128
+ "--malix-space-md",
129
+ "--malix-space-lg",
130
+ "--malix-space-xl",
131
+ "--malix-space-2xl",
132
+ "--malix-space-3xl",
133
+ "--malix-radius-sm",
134
+ "--malix-radius-md",
135
+ "--malix-radius-lg",
136
+ "--malix-radius-xl",
137
+ "--malix-radius-pill",
138
+ "--malix-text-xs",
139
+ "--malix-text-sm",
140
+ "--malix-text-base",
141
+ "--malix-text-lg",
142
+ "--malix-text-xl",
143
+ "--malix-text-2xl",
144
+ "--malix-font-body",
145
+ "--malix-font-heading",
146
+ "--malix-weight-normal",
147
+ "--malix-weight-medium",
148
+ "--malix-weight-semibold",
149
+ "--malix-weight-bold",
150
+ "--malix-shadow-btn-primary",
151
+ "--malix-shadow-btn-secondary",
152
+ "--malix-shadow-input",
153
+ "--malix-shadow-depth",
154
+ "--malix-shadow-card-l1",
155
+ "--malix-shadow-card-l2",
156
+ "--malix-shadow-card-l3",
157
+ "--malix-shadow-overlay",
158
+ "--malix-shadow-tooltip",
159
+ "--malix-shadow-sidebar",
160
+ "--malix-shadow-header"
161
+ ]
162
+ };
163
+
164
+ // src/components/Divider.tsx
165
+ var import_jsx_runtime = require("react/jsx-runtime");
166
+ function Divider({ className, ...props }) {
167
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
168
+ "hr",
169
+ {
170
+ className: `malix-divider${className ? ` ${className}` : ""}`,
171
+ ...props
172
+ }
173
+ );
174
+ }
175
+
176
+ // src/components/Avatar.tsx
177
+ var import_jsx_runtime2 = require("react/jsx-runtime");
178
+ function Avatar({ initials, size = 40, className, style, ...props }) {
179
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
180
+ "span",
181
+ {
182
+ className: `malix-avatar${className ? ` ${className}` : ""}`,
183
+ style: { width: size, height: size, borderRadius: size * 0.35, ...style },
184
+ ...props,
185
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "malix-avatar__text", children: initials })
186
+ }
187
+ );
188
+ }
189
+
190
+ // src/components/Pill.tsx
191
+ var import_jsx_runtime3 = require("react/jsx-runtime");
192
+ function Pill({ variant = "default", children, className, ...props }) {
193
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
194
+ "span",
195
+ {
196
+ className: `malix-pill${className ? ` ${className}` : ""}`,
197
+ "data-variant": variant,
198
+ ...props,
199
+ children
200
+ }
201
+ );
202
+ }
203
+
204
+ // src/components/Button.tsx
205
+ var import_jsx_runtime4 = require("react/jsx-runtime");
206
+ function Button({
207
+ hierarchy = "primary",
208
+ variant = "text",
209
+ icon,
210
+ badge,
211
+ loading = false,
212
+ disabled,
213
+ children,
214
+ label,
215
+ ...props
216
+ }) {
217
+ const isDisabled = disabled || loading;
218
+ const isIconOnly = variant === "icon-only";
219
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
220
+ "button",
221
+ {
222
+ type: "button",
223
+ className: "malix-button",
224
+ "data-hierarchy": hierarchy,
225
+ "data-variant": variant,
226
+ "data-loading": loading,
227
+ disabled: isDisabled,
228
+ "aria-busy": loading || void 0,
229
+ "aria-label": isIconOnly ? label : props["aria-label"],
230
+ ...props,
231
+ children: [
232
+ icon ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "malix-button__icon", children: icon }) : null,
233
+ !isIconOnly ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { children: loading ? "Loading..." : children }) : null,
234
+ variant === "icon-badge" && badge ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { className: "malix-button__badge", children: badge }) : null,
235
+ isIconOnly && !icon ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("span", { children: loading ? "..." : label }) : null
236
+ ]
237
+ }
238
+ );
239
+ }
240
+
241
+ // src/components/Input.tsx
242
+ var import_jsx_runtime5 = require("react/jsx-runtime");
243
+ function Input({ leadingIcon, ...props }) {
244
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("label", { className: "malix-input-wrap", children: [
245
+ leadingIcon ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: "malix-button__icon", children: leadingIcon }) : null,
246
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("input", { className: "malix-input", ...props })
247
+ ] });
248
+ }
249
+ function SearchInput(props) {
250
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Input, { type: "search", placeholder: "Search", ...props });
251
+ }
252
+
253
+ // src/components/InputGroup.tsx
254
+ var import_react = __toESM(require("react"), 1);
255
+ var import_jsx_runtime6 = require("react/jsx-runtime");
256
+ function InputGroup({
257
+ label,
258
+ helperText,
259
+ leadingIcon,
260
+ error,
261
+ id,
262
+ className,
263
+ ...props
264
+ }) {
265
+ const inputId = id || `input-${import_react.default.useId()}`;
266
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: `malix-input-group${className ? ` ${className}` : ""}`, "data-error": error || void 0, children: [
267
+ label ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("label", { htmlFor: inputId, className: "malix-input-group__label", children: label }) : null,
268
+ /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: "malix-input-group__field", children: [
269
+ leadingIcon ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "malix-input-group__icon", children: leadingIcon }) : null,
270
+ /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("input", { id: inputId, className: "malix-input", ...props })
271
+ ] }),
272
+ helperText ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "malix-input-group__helper", children: helperText }) : null
273
+ ] });
274
+ }
275
+
276
+ // src/components/Tooltip.tsx
277
+ var import_react2 = __toESM(require("react"), 1);
278
+ var import_jsx_runtime7 = require("react/jsx-runtime");
279
+ function Tooltip({ content, children, placement = "top" }) {
280
+ const [open, setOpen] = (0, import_react2.useState)(false);
281
+ const tooltipId = (0, import_react2.useId)();
282
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
283
+ "span",
284
+ {
285
+ className: "malix-tooltip-wrap",
286
+ onMouseEnter: () => setOpen(true),
287
+ onMouseLeave: () => setOpen(false),
288
+ onFocus: () => setOpen(true),
289
+ onBlur: () => setOpen(false),
290
+ children: [
291
+ import_react2.default.cloneElement(children, {
292
+ "aria-describedby": open ? tooltipId : void 0
293
+ }),
294
+ open ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { role: "tooltip", id: tooltipId, className: "malix-tooltip", "data-placement": placement, children: content }) : null
295
+ ]
296
+ }
297
+ );
298
+ }
299
+
300
+ // src/components/SidebarItem.tsx
301
+ var import_jsx_runtime8 = require("react/jsx-runtime");
302
+ function SidebarItem({
303
+ icon,
304
+ active = false,
305
+ children,
306
+ className,
307
+ ...props
308
+ }) {
309
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
310
+ "button",
311
+ {
312
+ type: "button",
313
+ className: `malix-sidebar-item${className ? ` ${className}` : ""}`,
314
+ "data-active": active || void 0,
315
+ "aria-current": active ? "page" : void 0,
316
+ ...props,
317
+ children: [
318
+ icon ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "malix-sidebar-item__icon", children: icon }) : null,
319
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "malix-sidebar-item__label", children })
320
+ ]
321
+ }
322
+ );
323
+ }
324
+
325
+ // src/components/FlyoutMenu.tsx
326
+ var import_jsx_runtime9 = require("react/jsx-runtime");
327
+ function FlyoutMenu({ items, className, ...props }) {
328
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
329
+ "nav",
330
+ {
331
+ className: `malix-flyout-menu${className ? ` ${className}` : ""}`,
332
+ role: "menu",
333
+ ...props,
334
+ children: items.map((item, i) => /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
335
+ "button",
336
+ {
337
+ type: "button",
338
+ className: "malix-flyout-menu__item",
339
+ "data-active": item.active || void 0,
340
+ role: "menuitem",
341
+ onClick: item.onClick,
342
+ children: [
343
+ item.icon ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("span", { className: "malix-flyout-menu__icon", children: item.icon }) : null,
344
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("span", { className: "malix-flyout-menu__label", children: item.label })
345
+ ]
346
+ },
347
+ i
348
+ ))
349
+ }
350
+ );
351
+ }
352
+
353
+ // src/components/SidebarPanel.tsx
354
+ var import_react3 = require("react");
355
+ var import_jsx_runtime10 = require("react/jsx-runtime");
356
+ function SidebarPanel({
357
+ collapsed = false,
358
+ logo,
359
+ collapsedLogo,
360
+ navigation,
361
+ footer,
362
+ onToggleCollapse,
363
+ className,
364
+ ...props
365
+ }) {
366
+ const [hovered, setHovered] = (0, import_react3.useState)(false);
367
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
368
+ "aside",
369
+ {
370
+ className: `malix-sidebar-panel${className ? ` ${className}` : ""}`,
371
+ "data-collapsed": collapsed || void 0,
372
+ onMouseEnter: collapsed ? () => setHovered(true) : void 0,
373
+ onMouseLeave: collapsed ? () => setHovered(false) : void 0,
374
+ ...props,
375
+ children: [
376
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "malix-sidebar-panel__top", children: [
377
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "malix-sidebar-panel__brand", children: collapsed ? (
378
+ /* Collapsed: show isotype by default, toggle button on hover */
379
+ hovered && onToggleCollapse ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
380
+ "button",
381
+ {
382
+ type: "button",
383
+ className: "malix-sidebar-panel__toggle",
384
+ onClick: onToggleCollapse,
385
+ "aria-label": "Expand sidebar",
386
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
387
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
388
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("path", { d: "M9 3v18" }),
389
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("path", { d: "m14 9 3 3-3 3" })
390
+ ] })
391
+ }
392
+ ) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "malix-sidebar-panel__collapsed-logo", children: collapsedLogo ?? logo })
393
+ ) : (
394
+ /* Expanded: logo + toggle button */
395
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
396
+ logo,
397
+ onToggleCollapse ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
398
+ "button",
399
+ {
400
+ type: "button",
401
+ className: "malix-sidebar-panel__toggle",
402
+ onClick: onToggleCollapse,
403
+ "aria-label": "Collapse sidebar",
404
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
405
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
406
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("path", { d: "M9 3v18" }),
407
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("path", { d: "m16 15-3-3 3-3" })
408
+ ] })
409
+ }
410
+ ) : null
411
+ ] })
412
+ ) }),
413
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("nav", { className: "malix-sidebar-panel__nav", children: navigation })
414
+ ] }),
415
+ footer ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "malix-sidebar-panel__bottom", children: footer }) : null
416
+ ]
417
+ }
418
+ );
419
+ }
420
+
421
+ // src/components/Header.tsx
422
+ var import_jsx_runtime11 = require("react/jsx-runtime");
423
+ function Header({ pageTitle, actions, className, ...props }) {
424
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
425
+ "header",
426
+ {
427
+ className: `malix-header${className ? ` ${className}` : ""}`,
428
+ ...props,
429
+ children: [
430
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "malix-header__left", children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("h1", { className: "malix-header__title", children: pageTitle }) }),
431
+ actions ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { className: "malix-header__right", children: actions }) : null
432
+ ]
433
+ }
434
+ );
435
+ }
436
+
437
+ // src/components/Card.tsx
438
+ var import_jsx_runtime12 = require("react/jsx-runtime");
439
+ function Card({
440
+ level = 1,
441
+ title,
442
+ description,
443
+ children,
444
+ className,
445
+ ...props
446
+ }) {
447
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
448
+ "div",
449
+ {
450
+ className: `malix-card${className ? ` ${className}` : ""}`,
451
+ "data-level": level,
452
+ ...props,
453
+ children: [
454
+ title || description ? /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "malix-card__header", children: [
455
+ title ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("h3", { className: "malix-card__title", children: title }) : null,
456
+ description ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("p", { className: "malix-card__desc", children: description }) : null
457
+ ] }) : null,
458
+ children ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { className: "malix-card__body", children }) : null
459
+ ]
460
+ }
461
+ );
462
+ }
463
+
464
+ // src/components/StatCard.tsx
465
+ var import_jsx_runtime13 = require("react/jsx-runtime");
466
+ function ChangeIcon({ type }) {
467
+ const shared = { width: 12, height: 12, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" };
468
+ switch (type) {
469
+ case "positive":
470
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("svg", { ...shared, children: [
471
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("polyline", { points: "22 7 13.5 15.5 8.5 10.5 2 17" }),
472
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("polyline", { points: "16 7 22 7 22 13" })
473
+ ] });
474
+ case "negative":
475
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("svg", { ...shared, children: [
476
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("polyline", { points: "22 17 13.5 8.5 8.5 13.5 2 7" }),
477
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("polyline", { points: "16 17 22 17 22 11" })
478
+ ] });
479
+ case "neutral":
480
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("svg", { ...shared, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("line", { x1: "5", y1: "12", x2: "19", y2: "12" }) });
481
+ }
482
+ }
483
+ function StatCard({
484
+ label,
485
+ value,
486
+ change,
487
+ changeType = "neutral",
488
+ className,
489
+ ...props
490
+ }) {
491
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
492
+ "div",
493
+ {
494
+ className: `malix-stat-card${className ? ` ${className}` : ""}`,
495
+ ...props,
496
+ children: [
497
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: "malix-stat-card__label", children: label }),
498
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: "malix-stat-card__value", children: value }),
499
+ change ? /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("span", { className: "malix-stat-card__change", "data-type": changeType, children: [
500
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: "malix-stat-card__change-icon", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ChangeIcon, { type: changeType }) }),
501
+ change
502
+ ] }) : null
503
+ ]
504
+ }
505
+ );
506
+ }
507
+
508
+ // src/components/DateInput.tsx
509
+ var import_react4 = __toESM(require("react"), 1);
510
+ var import_jsx_runtime14 = require("react/jsx-runtime");
511
+ function DateInput({
512
+ value,
513
+ placeholder = "dd/mm/yyyy",
514
+ onChange,
515
+ disabled,
516
+ className,
517
+ id,
518
+ ...props
519
+ }) {
520
+ const inputId = id || `date-input-${import_react4.default.useId()}`;
521
+ const handleChange = (e) => {
522
+ onChange?.(e.target.value);
523
+ };
524
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
525
+ "div",
526
+ {
527
+ className: `malix-date-input${className ? ` ${className}` : ""}`,
528
+ "data-filled": value ? true : void 0,
529
+ "data-disabled": disabled || void 0,
530
+ children: [
531
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
532
+ "input",
533
+ {
534
+ id: inputId,
535
+ type: "date",
536
+ className: "malix-date-input__native",
537
+ value,
538
+ onChange: handleChange,
539
+ disabled,
540
+ "aria-label": placeholder,
541
+ ...props
542
+ }
543
+ ),
544
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "malix-date-input__value", children: value || placeholder }),
545
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "malix-date-input__icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
546
+ "path",
547
+ {
548
+ d: "M12.667 2.667H3.333C2.597 2.667 2 3.264 2 4v9.333c0 .737.597 1.334 1.333 1.334h9.334c.736 0 1.333-.597 1.333-1.334V4c0-.736-.597-1.333-1.333-1.333ZM10.667 1.333V4M5.333 1.333V4M2 6.667h12",
549
+ stroke: "currentColor",
550
+ strokeWidth: "1.33",
551
+ strokeLinecap: "round",
552
+ strokeLinejoin: "round"
553
+ }
554
+ ) }) })
555
+ ]
556
+ }
557
+ );
558
+ }
559
+
560
+ // src/components/FilterTabs.tsx
561
+ var import_jsx_runtime15 = require("react/jsx-runtime");
562
+ function FilterTabs({
563
+ items,
564
+ value,
565
+ onChange,
566
+ className,
567
+ ...props
568
+ }) {
569
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
570
+ "div",
571
+ {
572
+ className: `malix-filter-tabs${className ? ` ${className}` : ""}`,
573
+ role: "tablist",
574
+ ...props,
575
+ children: items.map((item) => {
576
+ const isActive = item.value === value;
577
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
578
+ "button",
579
+ {
580
+ type: "button",
581
+ role: "tab",
582
+ className: "malix-filter-tabs__tab",
583
+ "data-active": isActive || void 0,
584
+ "aria-selected": isActive,
585
+ onClick: () => onChange(item.value),
586
+ children: [
587
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "malix-filter-tabs__tab-label", children: item.label }),
588
+ item.count != null ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "malix-filter-tabs__tab-count", children: item.count }) : null
589
+ ]
590
+ },
591
+ item.value
592
+ );
593
+ })
594
+ }
595
+ );
596
+ }
597
+
598
+ // src/components/Breadcrumb.tsx
599
+ var import_react5 = __toESM(require("react"), 1);
600
+ var import_jsx_runtime16 = require("react/jsx-runtime");
601
+ var DefaultSeparator = () => /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("path", { d: "M6 3L11 8L6 13", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
602
+ function Breadcrumb({ items, separator, className, ...props }) {
603
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
604
+ "nav",
605
+ {
606
+ className: `malix-breadcrumb${className ? ` ${className}` : ""}`,
607
+ "aria-label": "Breadcrumb",
608
+ ...props,
609
+ children: items.map((item, index) => {
610
+ const isLast = index === items.length - 1;
611
+ const isActive = item.active ?? isLast;
612
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(import_react5.default.Fragment, { children: [
613
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("span", { className: "malix-breadcrumb__item", "data-active": isActive || void 0, children: [
614
+ item.icon ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "malix-breadcrumb__icon", children: item.icon }) : null,
615
+ isActive || !item.href ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "malix-breadcrumb__label", "aria-current": isActive ? "page" : void 0, children: item.label }) : /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("a", { className: "malix-breadcrumb__label", href: item.href, children: item.label })
616
+ ] }),
617
+ !isLast ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { className: "malix-breadcrumb__separator", "aria-hidden": "true", children: separator ?? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(DefaultSeparator, {}) }) : null
618
+ ] }, index);
619
+ })
620
+ }
621
+ );
622
+ }
623
+
624
+ // src/components/ProgressBar.tsx
625
+ var import_jsx_runtime17 = require("react/jsx-runtime");
626
+ function ProgressBar({
627
+ value,
628
+ label,
629
+ showPercent = true,
630
+ variant = "default",
631
+ className,
632
+ ...props
633
+ }) {
634
+ const clampedValue = Math.max(0, Math.min(100, value));
635
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
636
+ "div",
637
+ {
638
+ className: `malix-progress-bar${className ? ` ${className}` : ""}`,
639
+ "data-variant": variant,
640
+ role: "progressbar",
641
+ "aria-valuenow": clampedValue,
642
+ "aria-valuemin": 0,
643
+ "aria-valuemax": 100,
644
+ "aria-label": label,
645
+ ...props,
646
+ children: [
647
+ label || showPercent ? /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", { className: "malix-progress-bar__label-row", children: [
648
+ label ? /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("span", { className: "malix-progress-bar__label", children: label }) : null,
649
+ showPercent ? /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("span", { className: "malix-progress-bar__percent", children: [
650
+ clampedValue,
651
+ "%"
652
+ ] }) : null
653
+ ] }) : null,
654
+ /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: "malix-progress-bar__track", children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
655
+ "div",
656
+ {
657
+ className: "malix-progress-bar__fill",
658
+ style: { width: `${clampedValue}%` }
659
+ }
660
+ ) })
661
+ ]
662
+ }
663
+ );
664
+ }
665
+
666
+ // src/components/EmptyState.tsx
667
+ var import_jsx_runtime18 = require("react/jsx-runtime");
668
+ var DefaultIcon = () => /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
669
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
670
+ "path",
671
+ {
672
+ d: "M3 7V5C3 3.895 3.895 3 5 3H9L11 5H19C20.105 5 21 5.895 21 7V9",
673
+ stroke: "currentColor",
674
+ strokeWidth: "1.5",
675
+ strokeLinecap: "round",
676
+ strokeLinejoin: "round"
677
+ }
678
+ ),
679
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
680
+ "rect",
681
+ {
682
+ x: "2",
683
+ y: "9",
684
+ width: "20",
685
+ height: "12",
686
+ rx: "2",
687
+ stroke: "currentColor",
688
+ strokeWidth: "1.5",
689
+ strokeLinecap: "round",
690
+ strokeLinejoin: "round"
691
+ }
692
+ ),
693
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
694
+ "path",
695
+ {
696
+ d: "M9 15H15",
697
+ stroke: "currentColor",
698
+ strokeWidth: "1.5",
699
+ strokeLinecap: "round",
700
+ strokeLinejoin: "round"
701
+ }
702
+ )
703
+ ] });
704
+ function EmptyState({
705
+ icon,
706
+ title,
707
+ description,
708
+ action,
709
+ className,
710
+ ...props
711
+ }) {
712
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
713
+ "div",
714
+ {
715
+ className: `malix-empty-state${className ? ` ${className}` : ""}`,
716
+ ...props,
717
+ children: [
718
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "malix-empty-state__icon-wrap", children: icon ?? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(DefaultIcon, {}) }),
719
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("h3", { className: "malix-empty-state__title", children: title }),
720
+ description ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("p", { className: "malix-empty-state__description", children: description }) : null,
721
+ action ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "malix-empty-state__action", children: action }) : null
722
+ ]
723
+ }
724
+ );
725
+ }
726
+
727
+ // src/components/Stepper.tsx
728
+ var import_react6 = __toESM(require("react"), 1);
729
+ var import_jsx_runtime19 = require("react/jsx-runtime");
730
+ function Stepper({ steps, className }) {
731
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: `malix-stepper${className ? ` ${className}` : ""}`, children: steps.map((step, index) => /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(import_react6.default.Fragment, { children: [
732
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "malix-stepper__step", "data-status": step.status, children: [
733
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "malix-stepper__step-icon", children: step.status === "completed" ? /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("path", { d: "M11.5 3.5L5.5 10L2.5 7", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }) }) : step.icon ?? null }),
734
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "malix-stepper__step-label", children: step.label })
735
+ ] }),
736
+ index < steps.length - 1 ? /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { className: "malix-stepper__connector" }) : null
737
+ ] }, index)) });
738
+ }
739
+
740
+ // src/components/Textarea.tsx
741
+ var import_react7 = __toESM(require("react"), 1);
742
+ var import_jsx_runtime20 = require("react/jsx-runtime");
743
+ function Textarea({
744
+ label,
745
+ helperText,
746
+ error,
747
+ errorMessage,
748
+ id,
749
+ className,
750
+ ...props
751
+ }) {
752
+ const textareaId = id || `textarea-${import_react7.default.useId()}`;
753
+ const displayHelper = error && errorMessage ? errorMessage : helperText;
754
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(
755
+ "div",
756
+ {
757
+ className: `malix-textarea-group${className ? ` ${className}` : ""}`,
758
+ "data-error": error || void 0,
759
+ children: [
760
+ label ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("label", { htmlFor: textareaId, className: "malix-textarea-group__label", children: label }) : null,
761
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
762
+ "textarea",
763
+ {
764
+ id: textareaId,
765
+ className: "malix-textarea-group__field",
766
+ "aria-invalid": error || void 0,
767
+ ...props
768
+ }
769
+ ),
770
+ displayHelper ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { className: "malix-textarea-group__helper", children: displayHelper }) : null
771
+ ]
772
+ }
773
+ );
774
+ }
775
+
776
+ // src/components/ChatInput.tsx
777
+ var import_jsx_runtime21 = require("react/jsx-runtime");
778
+ function ChatInput({
779
+ value,
780
+ onChange,
781
+ onSend,
782
+ placeholder = "Type a message...",
783
+ disabled,
784
+ className
785
+ }) {
786
+ const handleKeyDown = (e) => {
787
+ if (e.key === "Enter" && !e.shiftKey && value.trim()) {
788
+ e.preventDefault();
789
+ onSend();
790
+ }
791
+ };
792
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: `malix-chat-input${className ? ` ${className}` : ""}`, children: [
793
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
794
+ "input",
795
+ {
796
+ type: "text",
797
+ className: "malix-chat-input__field",
798
+ value,
799
+ onChange: (e) => onChange(e.target.value),
800
+ onKeyDown: handleKeyDown,
801
+ placeholder,
802
+ disabled,
803
+ "aria-label": placeholder
804
+ }
805
+ ),
806
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
807
+ "button",
808
+ {
809
+ type: "button",
810
+ className: "malix-chat-input__send-btn",
811
+ onClick: onSend,
812
+ disabled: disabled || !value.trim(),
813
+ "aria-label": "Send message",
814
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
815
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("path", { d: "M12 19V5" }),
816
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("path", { d: "m5 12 7-7 7 7" })
817
+ ] })
818
+ }
819
+ )
820
+ ] });
821
+ }
822
+
823
+ // src/components/SectionHeader.tsx
824
+ var import_jsx_runtime22 = require("react/jsx-runtime");
825
+ function SectionHeader({
826
+ title,
827
+ description,
828
+ actions,
829
+ className,
830
+ ...props
831
+ }) {
832
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
833
+ "div",
834
+ {
835
+ className: `malix-section-header${className ? ` ${className}` : ""}`,
836
+ ...props,
837
+ children: [
838
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "malix-section-header__left", children: [
839
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("h2", { className: "malix-section-header__title", children: title }),
840
+ description ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("p", { className: "malix-section-header__description", children: description }) : null
841
+ ] }),
842
+ actions ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "malix-section-header__actions", children: actions }) : null
843
+ ]
844
+ }
845
+ );
846
+ }
847
+
848
+ // src/components/FileCard.tsx
849
+ var import_jsx_runtime23 = require("react/jsx-runtime");
850
+ var DefaultFileIcon = () => /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
851
+ "svg",
852
+ {
853
+ width: "20",
854
+ height: "20",
855
+ viewBox: "0 0 24 24",
856
+ fill: "none",
857
+ stroke: "currentColor",
858
+ strokeWidth: "2",
859
+ strokeLinecap: "round",
860
+ strokeLinejoin: "round",
861
+ children: [
862
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("path", { d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z" }),
863
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("polyline", { points: "14 2 14 8 20 8" }),
864
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("line", { x1: "16", y1: "13", x2: "8", y2: "13" }),
865
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("line", { x1: "16", y1: "17", x2: "8", y2: "17" }),
866
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("polyline", { points: "10 9 9 9 8 9" })
867
+ ]
868
+ }
869
+ );
870
+ var MoreVerticalIcon = () => /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
871
+ "svg",
872
+ {
873
+ width: "16",
874
+ height: "16",
875
+ viewBox: "0 0 24 24",
876
+ fill: "currentColor",
877
+ children: [
878
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: "12", cy: "5", r: "1.5" }),
879
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: "12", cy: "12", r: "1.5" }),
880
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: "12", cy: "19", r: "1.5" })
881
+ ]
882
+ }
883
+ );
884
+ function FileCard({
885
+ fileName,
886
+ meta,
887
+ icon,
888
+ onAction,
889
+ className,
890
+ ...props
891
+ }) {
892
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
893
+ "div",
894
+ {
895
+ className: `malix-file-card${className ? ` ${className}` : ""}`,
896
+ ...props,
897
+ children: [
898
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "malix-file-card__icon-wrap", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "malix-file-card__icon", children: icon ?? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(DefaultFileIcon, {}) }) }),
899
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "malix-file-card__info", children: [
900
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "malix-file-card__name", children: fileName }),
901
+ meta ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "malix-file-card__meta", children: meta }) : null
902
+ ] }),
903
+ onAction ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
904
+ "button",
905
+ {
906
+ type: "button",
907
+ className: "malix-file-card__action",
908
+ onClick: onAction,
909
+ "aria-label": "More actions",
910
+ children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(MoreVerticalIcon, {})
911
+ }
912
+ ) : null
913
+ ]
914
+ }
915
+ );
916
+ }
917
+
918
+ // src/components/TabBar.tsx
919
+ var import_jsx_runtime24 = require("react/jsx-runtime");
920
+ function TabBar({
921
+ items,
922
+ value,
923
+ onChange,
924
+ className,
925
+ ...props
926
+ }) {
927
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
928
+ "div",
929
+ {
930
+ className: `malix-tab-bar${className ? ` ${className}` : ""}`,
931
+ role: "tablist",
932
+ ...props,
933
+ children: items.map((item) => {
934
+ const isActive = item.value === value;
935
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
936
+ "button",
937
+ {
938
+ type: "button",
939
+ role: "tab",
940
+ className: "malix-tab-bar__tab",
941
+ "data-active": isActive || void 0,
942
+ "aria-selected": isActive,
943
+ onClick: () => onChange(item.value),
944
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("span", { className: "malix-tab-bar__tab-label", children: item.label })
945
+ },
946
+ item.value
947
+ );
948
+ })
949
+ }
950
+ );
951
+ }
952
+
953
+ // src/components/OperationStatus.tsx
954
+ var import_jsx_runtime25 = require("react/jsx-runtime");
955
+ var DEFAULT_LABELS = {
956
+ active: "Active",
957
+ completed: "Completed",
958
+ failed: "Failed",
959
+ pending: "Pending"
960
+ };
961
+ function StatusIcon({ status }) {
962
+ const shared = { width: 14, height: 14, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" };
963
+ switch (status) {
964
+ case "active":
965
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("svg", { width: "14", height: "14", viewBox: "0 0 14 14", fill: "currentColor", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("circle", { cx: "7", cy: "7", r: "4" }) });
966
+ case "completed":
967
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("svg", { ...shared, children: [
968
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
969
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("path", { d: "m9 12 2 2 4-4" })
970
+ ] });
971
+ case "failed":
972
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("svg", { ...shared, children: [
973
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
974
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("path", { d: "m15 9-6 6" }),
975
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("path", { d: "m9 9 6 6" })
976
+ ] });
977
+ case "pending":
978
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("svg", { ...shared, children: [
979
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
980
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("polyline", { points: "12 6 12 12 16 14" })
981
+ ] });
982
+ }
983
+ }
984
+ function OperationStatus({
985
+ status,
986
+ label,
987
+ className,
988
+ ...props
989
+ }) {
990
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
991
+ "span",
992
+ {
993
+ className: `malix-op-status${className ? ` ${className}` : ""}`,
994
+ "data-status": status,
995
+ ...props,
996
+ children: [
997
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "malix-op-status__icon", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(StatusIcon, { status }) }),
998
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "malix-op-status__label", children: label ?? DEFAULT_LABELS[status] })
999
+ ]
1000
+ }
1001
+ );
1002
+ }
1003
+
1004
+ // src/components/ValidationAlert.tsx
1005
+ var import_jsx_runtime26 = require("react/jsx-runtime");
1006
+ function AlertIcon({ variant }) {
1007
+ const shared = { width: 16, height: 16, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" };
1008
+ switch (variant) {
1009
+ case "error":
1010
+ case "warning":
1011
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { ...shared, children: [
1012
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z" }),
1013
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("line", { x1: "12", y1: "9", x2: "12", y2: "13" }),
1014
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("line", { x1: "12", y1: "17", x2: "12.01", y2: "17" })
1015
+ ] });
1016
+ case "info":
1017
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { ...shared, children: [
1018
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
1019
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("line", { x1: "12", y1: "16", x2: "12", y2: "12" }),
1020
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("line", { x1: "12", y1: "8", x2: "12.01", y2: "8" })
1021
+ ] });
1022
+ }
1023
+ }
1024
+ function ValidationAlert({
1025
+ title,
1026
+ message,
1027
+ onClose,
1028
+ variant = "error",
1029
+ className
1030
+ }) {
1031
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
1032
+ "div",
1033
+ {
1034
+ className: `malix-validation-alert${className ? ` ${className}` : ""}`,
1035
+ "data-variant": variant,
1036
+ role: "alert",
1037
+ children: [
1038
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "malix-validation-alert__icon", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(AlertIcon, { variant }) }),
1039
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "malix-validation-alert__content", children: [
1040
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "malix-validation-alert__title", children: title }),
1041
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "malix-validation-alert__message", children: message })
1042
+ ] }),
1043
+ onClose ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
1044
+ "button",
1045
+ {
1046
+ type: "button",
1047
+ className: "malix-validation-alert__close",
1048
+ onClick: onClose,
1049
+ "aria-label": "Close",
1050
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1051
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
1052
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
1053
+ ] })
1054
+ }
1055
+ ) : null
1056
+ ]
1057
+ }
1058
+ );
1059
+ }
1060
+
1061
+ // src/components/SelectionCard.tsx
1062
+ var import_jsx_runtime27 = require("react/jsx-runtime");
1063
+ function SelectionCard({
1064
+ title,
1065
+ description,
1066
+ icon,
1067
+ active = false,
1068
+ onClick,
1069
+ className
1070
+ }) {
1071
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
1072
+ "div",
1073
+ {
1074
+ className: `malix-selection-card${className ? ` ${className}` : ""}`,
1075
+ "data-active": active || void 0,
1076
+ onClick,
1077
+ role: onClick ? "button" : void 0,
1078
+ tabIndex: onClick ? 0 : void 0,
1079
+ onKeyDown: onClick ? (e) => {
1080
+ if (e.key === "Enter" || e.key === " ") {
1081
+ e.preventDefault();
1082
+ onClick();
1083
+ }
1084
+ } : void 0,
1085
+ children: [
1086
+ icon ? /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "malix-selection-card__icon-wrap", children: icon }) : null,
1087
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "malix-selection-card__title", children: title }),
1088
+ description ? /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { className: "malix-selection-card__description", children: description }) : null
1089
+ ]
1090
+ }
1091
+ );
1092
+ }
1093
+
1094
+ // src/components/Overlay.tsx
1095
+ var import_react8 = require("react");
1096
+ var import_jsx_runtime28 = require("react/jsx-runtime");
1097
+ var FOCUSABLE_SELECTOR = 'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])';
1098
+ function Overlay({ open, title, onClose, children }) {
1099
+ const panelRef = (0, import_react8.useRef)(null);
1100
+ (0, import_react8.useEffect)(() => {
1101
+ if (!open || !panelRef.current) return;
1102
+ const panel = panelRef.current;
1103
+ const focusables = Array.from(panel.querySelectorAll(FOCUSABLE_SELECTOR));
1104
+ const first = focusables[0];
1105
+ const last = focusables[focusables.length - 1];
1106
+ first?.focus();
1107
+ function onKeyDown(event) {
1108
+ if (event.key === "Escape") {
1109
+ event.preventDefault();
1110
+ onClose();
1111
+ }
1112
+ if (event.key === "Tab" && focusables.length > 0) {
1113
+ if (event.shiftKey && document.activeElement === first) {
1114
+ event.preventDefault();
1115
+ last?.focus();
1116
+ } else if (!event.shiftKey && document.activeElement === last) {
1117
+ event.preventDefault();
1118
+ first?.focus();
1119
+ }
1120
+ }
1121
+ }
1122
+ document.addEventListener("keydown", onKeyDown);
1123
+ return () => document.removeEventListener("keydown", onKeyDown);
1124
+ }, [open, onClose]);
1125
+ if (!open) return null;
1126
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className: "malix-overlay-backdrop", onMouseDown: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
1127
+ "div",
1128
+ {
1129
+ ref: panelRef,
1130
+ className: "malix-overlay-panel",
1131
+ role: "dialog",
1132
+ "aria-modal": "true",
1133
+ "aria-label": title,
1134
+ onMouseDown: (event) => event.stopPropagation(),
1135
+ children: [
1136
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("h2", { className: "malix-overlay-title", children: title }),
1137
+ children,
1138
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("button", { type: "button", className: "malix-button malix-overlay-close", "data-hierarchy": "secondary", onClick: onClose, children: "Close" })
1139
+ ]
1140
+ }
1141
+ ) });
1142
+ }
1143
+
1144
+ // src/components/Modal.tsx
1145
+ var import_react9 = require("react");
1146
+ var import_jsx_runtime29 = require("react/jsx-runtime");
1147
+ var FOCUSABLE_SELECTOR2 = 'button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])';
1148
+ function Modal({
1149
+ open,
1150
+ title,
1151
+ onClose,
1152
+ onConfirm,
1153
+ confirmLabel = "Confirm",
1154
+ cancelLabel = "Cancel",
1155
+ children
1156
+ }) {
1157
+ const panelRef = (0, import_react9.useRef)(null);
1158
+ (0, import_react9.useEffect)(() => {
1159
+ if (!open || !panelRef.current) return;
1160
+ const panel = panelRef.current;
1161
+ const focusables = Array.from(panel.querySelectorAll(FOCUSABLE_SELECTOR2));
1162
+ const first = focusables[0];
1163
+ const last = focusables[focusables.length - 1];
1164
+ first?.focus();
1165
+ function onKeyDown(event) {
1166
+ if (event.key === "Escape") {
1167
+ event.preventDefault();
1168
+ onClose();
1169
+ }
1170
+ if (event.key === "Tab" && focusables.length > 0) {
1171
+ if (event.shiftKey && document.activeElement === first) {
1172
+ event.preventDefault();
1173
+ last?.focus();
1174
+ } else if (!event.shiftKey && document.activeElement === last) {
1175
+ event.preventDefault();
1176
+ first?.focus();
1177
+ }
1178
+ }
1179
+ }
1180
+ document.addEventListener("keydown", onKeyDown);
1181
+ return () => document.removeEventListener("keydown", onKeyDown);
1182
+ }, [open, onClose]);
1183
+ if (!open) return null;
1184
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "malix-overlay-backdrop", onMouseDown: onClose, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
1185
+ "div",
1186
+ {
1187
+ ref: panelRef,
1188
+ className: "malix-modal",
1189
+ role: "dialog",
1190
+ "aria-modal": "true",
1191
+ "aria-label": title,
1192
+ onMouseDown: (event) => event.stopPropagation(),
1193
+ children: [
1194
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "malix-modal__header", children: [
1195
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("h2", { className: "malix-modal__title", children: title }),
1196
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1197
+ "button",
1198
+ {
1199
+ type: "button",
1200
+ className: "malix-modal__close",
1201
+ onClick: onClose,
1202
+ "aria-label": "Close",
1203
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1204
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
1205
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
1206
+ ] })
1207
+ }
1208
+ )
1209
+ ] }),
1210
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "malix-modal__body", children }),
1211
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "malix-modal__footer", children: [
1212
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1213
+ "button",
1214
+ {
1215
+ type: "button",
1216
+ className: "malix-button",
1217
+ "data-hierarchy": "secondary",
1218
+ onClick: onClose,
1219
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("span", { children: cancelLabel })
1220
+ }
1221
+ ),
1222
+ onConfirm ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
1223
+ "button",
1224
+ {
1225
+ type: "button",
1226
+ className: "malix-button",
1227
+ "data-hierarchy": "primary",
1228
+ onClick: onConfirm,
1229
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("span", { children: confirmLabel })
1230
+ }
1231
+ ) : null
1232
+ ] })
1233
+ ]
1234
+ }
1235
+ ) });
1236
+ }
1237
+
1238
+ // src/components/GlassPopover.tsx
1239
+ var import_jsx_runtime30 = require("react/jsx-runtime");
1240
+ function GlassPopover({
1241
+ title,
1242
+ onClose,
1243
+ children,
1244
+ className,
1245
+ ...props
1246
+ }) {
1247
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
1248
+ "div",
1249
+ {
1250
+ className: `malix-glass-popover${className ? ` ${className}` : ""}`,
1251
+ ...props,
1252
+ children: [
1253
+ title || onClose ? /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "malix-glass-popover__header", children: [
1254
+ title ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("span", { className: "malix-glass-popover__title", children: title }) : null,
1255
+ onClose ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
1256
+ "button",
1257
+ {
1258
+ type: "button",
1259
+ className: "malix-glass-popover__close",
1260
+ onClick: onClose,
1261
+ "aria-label": "Close",
1262
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1263
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
1264
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
1265
+ ] })
1266
+ }
1267
+ ) : null
1268
+ ] }) : null,
1269
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "malix-glass-popover__body", children })
1270
+ ]
1271
+ }
1272
+ );
1273
+ }
1274
+
1275
+ // src/components/Accordion.tsx
1276
+ var import_react10 = require("react");
1277
+ var import_jsx_runtime31 = require("react/jsx-runtime");
1278
+ function Accordion({
1279
+ title,
1280
+ children,
1281
+ defaultOpen = false,
1282
+ icon,
1283
+ className,
1284
+ ...props
1285
+ }) {
1286
+ const [open, setOpen] = (0, import_react10.useState)(defaultOpen);
1287
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
1288
+ "div",
1289
+ {
1290
+ className: `malix-accordion${className ? ` ${className}` : ""}`,
1291
+ "data-open": open,
1292
+ ...props,
1293
+ children: [
1294
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
1295
+ "button",
1296
+ {
1297
+ type: "button",
1298
+ className: "malix-accordion__header",
1299
+ onClick: () => setOpen((prev) => !prev),
1300
+ "aria-expanded": open,
1301
+ children: [
1302
+ icon ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "malix-accordion__icon", children: icon }) : null,
1303
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { className: "malix-accordion__title", children: title }),
1304
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
1305
+ "svg",
1306
+ {
1307
+ className: "malix-accordion__chevron",
1308
+ width: "16",
1309
+ height: "16",
1310
+ viewBox: "0 0 24 24",
1311
+ fill: "none",
1312
+ stroke: "currentColor",
1313
+ strokeWidth: "2",
1314
+ strokeLinecap: "round",
1315
+ strokeLinejoin: "round",
1316
+ "aria-hidden": "true",
1317
+ children: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("polyline", { points: "6 9 12 15 18 9" })
1318
+ }
1319
+ )
1320
+ ]
1321
+ }
1322
+ ),
1323
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("div", { className: "malix-accordion__body", children })
1324
+ ]
1325
+ }
1326
+ );
1327
+ }
1328
+
1329
+ // src/components/Badge.tsx
1330
+ var import_jsx_runtime32 = require("react/jsx-runtime");
1331
+ function Badge({
1332
+ variant = "default",
1333
+ dot = false,
1334
+ children,
1335
+ className,
1336
+ ...props
1337
+ }) {
1338
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
1339
+ "span",
1340
+ {
1341
+ className: `malix-badge${className ? ` ${className}` : ""}`,
1342
+ "data-variant": variant,
1343
+ ...props,
1344
+ children: [
1345
+ dot ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { className: "malix-badge__dot" }) : null,
1346
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)("span", { className: "malix-badge__label", children })
1347
+ ]
1348
+ }
1349
+ );
1350
+ }
1351
+
1352
+ // src/components/Banner.tsx
1353
+ var import_jsx_runtime33 = require("react/jsx-runtime");
1354
+ var defaultIcons = {
1355
+ info: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1356
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
1357
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "12", y1: "16", x2: "12", y2: "12" }),
1358
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "12", y1: "8", x2: "12.01", y2: "8" })
1359
+ ] }),
1360
+ success: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1361
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("path", { d: "M22 11.08V12a10 10 0 1 1-5.93-9.14" }),
1362
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("polyline", { points: "22 4 12 14.01 9 11.01" })
1363
+ ] }),
1364
+ warning: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1365
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("path", { d: "M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z" }),
1366
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "12", y1: "9", x2: "12", y2: "13" }),
1367
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "12", y1: "17", x2: "12.01", y2: "17" })
1368
+ ] }),
1369
+ error: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1370
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
1371
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "15", y1: "9", x2: "9", y2: "15" }),
1372
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "9", y1: "9", x2: "15", y2: "15" })
1373
+ ] })
1374
+ };
1375
+ function Banner({
1376
+ variant = "info",
1377
+ onClose,
1378
+ icon,
1379
+ children,
1380
+ className,
1381
+ ...props
1382
+ }) {
1383
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
1384
+ "div",
1385
+ {
1386
+ className: `malix-banner${className ? ` ${className}` : ""}`,
1387
+ "data-variant": variant,
1388
+ role: "alert",
1389
+ ...props,
1390
+ children: [
1391
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { className: "malix-banner__icon", children: icon ?? defaultIcons[variant] }),
1392
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { className: "malix-banner__content", children }),
1393
+ onClose ? /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
1394
+ "button",
1395
+ {
1396
+ type: "button",
1397
+ className: "malix-banner__close",
1398
+ onClick: onClose,
1399
+ "aria-label": "Dismiss",
1400
+ children: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
1401
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
1402
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
1403
+ ] })
1404
+ }
1405
+ ) : null
1406
+ ]
1407
+ }
1408
+ );
1409
+ }
1410
+
1411
+ // src/components/Checkbox.tsx
1412
+ var import_jsx_runtime34 = require("react/jsx-runtime");
1413
+ function Checkbox({
1414
+ checked = false,
1415
+ onChange,
1416
+ disabled = false,
1417
+ label,
1418
+ indeterminate = false,
1419
+ className,
1420
+ ...props
1421
+ }) {
1422
+ const handleClick = () => {
1423
+ if (!disabled && onChange) {
1424
+ onChange(!checked);
1425
+ }
1426
+ };
1427
+ const checkbox = /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
1428
+ "button",
1429
+ {
1430
+ type: "button",
1431
+ role: "checkbox",
1432
+ className: `malix-checkbox${className ? ` ${className}` : ""}`,
1433
+ "data-checked": checked,
1434
+ "data-disabled": disabled,
1435
+ "data-indeterminate": indeterminate,
1436
+ "aria-checked": indeterminate ? "mixed" : checked,
1437
+ disabled,
1438
+ onClick: handleClick,
1439
+ ...props,
1440
+ children: [
1441
+ checked && !indeterminate ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1442
+ "svg",
1443
+ {
1444
+ className: "malix-checkbox__icon",
1445
+ viewBox: "0 0 12 12",
1446
+ fill: "none",
1447
+ xmlns: "http://www.w3.org/2000/svg",
1448
+ "aria-hidden": "true",
1449
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1450
+ "path",
1451
+ {
1452
+ d: "M2 6l3 3 5-5",
1453
+ stroke: "currentColor",
1454
+ strokeWidth: "2",
1455
+ strokeLinecap: "round",
1456
+ strokeLinejoin: "round"
1457
+ }
1458
+ )
1459
+ }
1460
+ ) : null,
1461
+ indeterminate ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1462
+ "svg",
1463
+ {
1464
+ className: "malix-checkbox__icon",
1465
+ viewBox: "0 0 12 12",
1466
+ fill: "none",
1467
+ xmlns: "http://www.w3.org/2000/svg",
1468
+ "aria-hidden": "true",
1469
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
1470
+ "path",
1471
+ {
1472
+ d: "M2 6h8",
1473
+ stroke: "currentColor",
1474
+ strokeWidth: "2",
1475
+ strokeLinecap: "round"
1476
+ }
1477
+ )
1478
+ }
1479
+ ) : null
1480
+ ]
1481
+ }
1482
+ );
1483
+ if (label) {
1484
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)("label", { className: "malix-checkbox-row", children: [
1485
+ checkbox,
1486
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "malix-checkbox-row__label", children: label })
1487
+ ] });
1488
+ }
1489
+ return checkbox;
1490
+ }
1491
+
1492
+ // src/components/Radio.tsx
1493
+ var import_jsx_runtime35 = require("react/jsx-runtime");
1494
+ function Radio({
1495
+ checked = false,
1496
+ onChange,
1497
+ disabled = false,
1498
+ label,
1499
+ name,
1500
+ value,
1501
+ className,
1502
+ ...props
1503
+ }) {
1504
+ const handleClick = () => {
1505
+ if (!disabled && onChange) {
1506
+ onChange(value);
1507
+ }
1508
+ };
1509
+ const radio = /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
1510
+ "button",
1511
+ {
1512
+ type: "button",
1513
+ role: "radio",
1514
+ className: `malix-radio${className ? ` ${className}` : ""}`,
1515
+ "data-checked": checked,
1516
+ "data-disabled": disabled,
1517
+ "aria-checked": checked,
1518
+ disabled,
1519
+ "data-name": name,
1520
+ "data-value": value,
1521
+ onClick: handleClick,
1522
+ ...props,
1523
+ children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "malix-radio__dot" })
1524
+ }
1525
+ );
1526
+ if (label) {
1527
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("label", { className: "malix-radio-row", children: [
1528
+ radio,
1529
+ /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("span", { className: "malix-radio-row__label", children: label })
1530
+ ] });
1531
+ }
1532
+ return radio;
1533
+ }
1534
+
1535
+ // src/components/Toggle.tsx
1536
+ var import_jsx_runtime36 = require("react/jsx-runtime");
1537
+ function Toggle({
1538
+ checked = false,
1539
+ onChange,
1540
+ disabled = false,
1541
+ label,
1542
+ className,
1543
+ ...props
1544
+ }) {
1545
+ const handleClick = () => {
1546
+ if (!disabled && onChange) {
1547
+ onChange(!checked);
1548
+ }
1549
+ };
1550
+ const toggle = /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
1551
+ "button",
1552
+ {
1553
+ type: "button",
1554
+ role: "switch",
1555
+ className: `malix-toggle${className ? ` ${className}` : ""}`,
1556
+ "data-checked": checked,
1557
+ "data-disabled": disabled,
1558
+ "aria-checked": checked,
1559
+ disabled,
1560
+ onClick: handleClick,
1561
+ ...props,
1562
+ children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "malix-toggle__knob" })
1563
+ }
1564
+ );
1565
+ if (label) {
1566
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "malix-toggle-row", children: [
1567
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "malix-toggle-row__label", children: label }),
1568
+ toggle
1569
+ ] });
1570
+ }
1571
+ return toggle;
1572
+ }
1573
+
1574
+ // src/components/Select.tsx
1575
+ var import_jsx_runtime37 = require("react/jsx-runtime");
1576
+ function Select({
1577
+ value,
1578
+ placeholder,
1579
+ options = [],
1580
+ onChange,
1581
+ disabled,
1582
+ filled,
1583
+ className,
1584
+ ...props
1585
+ }) {
1586
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
1587
+ "div",
1588
+ {
1589
+ className: `malix-select${className ? ` ${className}` : ""}`,
1590
+ "data-filled": filled || void 0,
1591
+ "data-disabled": disabled || void 0,
1592
+ children: [
1593
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
1594
+ "select",
1595
+ {
1596
+ className: "malix-select__native",
1597
+ value,
1598
+ disabled,
1599
+ onChange: (e) => onChange?.(e.target.value),
1600
+ ...props,
1601
+ children: [
1602
+ placeholder ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("option", { value: "", disabled: true, children: placeholder }) : null,
1603
+ options.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("option", { value: opt.value, children: opt.label }, opt.value))
1604
+ ]
1605
+ }
1606
+ ),
1607
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "malix-select__icon", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
1608
+ "path",
1609
+ {
1610
+ d: "M4 6L8 10L12 6",
1611
+ stroke: "currentColor",
1612
+ strokeWidth: "1.5",
1613
+ strokeLinecap: "round",
1614
+ strokeLinejoin: "round"
1615
+ }
1616
+ ) }) })
1617
+ ]
1618
+ }
1619
+ );
1620
+ }
1621
+
1622
+ // src/components/SelectGroup.tsx
1623
+ var import_jsx_runtime38 = require("react/jsx-runtime");
1624
+ function SelectGroup({
1625
+ label,
1626
+ helperText,
1627
+ error,
1628
+ children,
1629
+ className,
1630
+ ...props
1631
+ }) {
1632
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
1633
+ "div",
1634
+ {
1635
+ className: `malix-select-group${className ? ` ${className}` : ""}`,
1636
+ "data-error": error || void 0,
1637
+ ...props,
1638
+ children: [
1639
+ label ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "malix-select-group__label", children: label }) : null,
1640
+ children,
1641
+ helperText ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "malix-select-group__helper", children: helperText }) : null
1642
+ ]
1643
+ }
1644
+ );
1645
+ }
1646
+
1647
+ // src/components/SegmentedControl.tsx
1648
+ var import_jsx_runtime39 = require("react/jsx-runtime");
1649
+ function SegmentedControl({
1650
+ items,
1651
+ value,
1652
+ onChange,
1653
+ className,
1654
+ ...props
1655
+ }) {
1656
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
1657
+ "div",
1658
+ {
1659
+ className: `malix-segmented-control${className ? ` ${className}` : ""}`,
1660
+ role: "radiogroup",
1661
+ ...props,
1662
+ children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
1663
+ "button",
1664
+ {
1665
+ type: "button",
1666
+ className: "malix-segmented-control__item",
1667
+ role: "radio",
1668
+ "aria-checked": item.value === value,
1669
+ "data-active": item.value === value || void 0,
1670
+ onClick: () => onChange(item.value),
1671
+ children: item.label
1672
+ },
1673
+ item.value
1674
+ ))
1675
+ }
1676
+ );
1677
+ }
1678
+
1679
+ // src/components/DataTable.tsx
1680
+ var import_jsx_runtime40 = require("react/jsx-runtime");
1681
+ function DataTable({
1682
+ columns,
1683
+ data,
1684
+ onRowClick,
1685
+ emptyMessage,
1686
+ className,
1687
+ ...props
1688
+ }) {
1689
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(
1690
+ "table",
1691
+ {
1692
+ className: `malix-data-table${className ? ` ${className}` : ""}`,
1693
+ ...props,
1694
+ children: [
1695
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("thead", { children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("tr", { className: "malix-data-table__header-row", children: columns.map((col) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1696
+ "th",
1697
+ {
1698
+ className: "malix-data-table__header-cell",
1699
+ style: col.width ? { width: col.width } : void 0,
1700
+ children: col.header
1701
+ },
1702
+ col.key
1703
+ )) }) }),
1704
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("tbody", { className: "malix-data-table__body", children: data.length > 0 ? data.map((row, rowIndex) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1705
+ "tr",
1706
+ {
1707
+ className: "malix-data-table__data-row",
1708
+ "data-clickable": onRowClick ? true : void 0,
1709
+ onClick: onRowClick ? () => onRowClick(row) : void 0,
1710
+ children: columns.map((col) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("td", { className: "malix-data-table__cell", children: col.render ? col.render(row[col.key], row) : row[col.key] }, col.key))
1711
+ },
1712
+ rowIndex
1713
+ )) : /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("tr", { className: "malix-data-table__data-row", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
1714
+ "td",
1715
+ {
1716
+ className: "malix-data-table__cell",
1717
+ colSpan: columns.length,
1718
+ children: emptyMessage || "No data available"
1719
+ }
1720
+ ) }) })
1721
+ ]
1722
+ }
1723
+ );
1724
+ }
1725
+
1726
+ // src/components/Pagination.tsx
1727
+ var import_jsx_runtime41 = require("react/jsx-runtime");
1728
+ function ChevronLeft() {
1729
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("path", { d: "M10 12L6 8L10 4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1730
+ }
1731
+ function ChevronRight() {
1732
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("path", { d: "M6 4L10 8L6 12", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1733
+ }
1734
+ function Pagination({
1735
+ currentPage,
1736
+ totalPages,
1737
+ onPageChange,
1738
+ variant = "full",
1739
+ className
1740
+ }) {
1741
+ const isFirstPage = currentPage <= 1;
1742
+ const isLastPage = currentPage >= totalPages;
1743
+ const pages = Array.from({ length: totalPages }, (_, i) => i + 1);
1744
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
1745
+ "nav",
1746
+ {
1747
+ className: `malix-pagination${className ? ` ${className}` : ""}`,
1748
+ "data-variant": variant,
1749
+ "aria-label": "Pagination",
1750
+ children: [
1751
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
1752
+ "button",
1753
+ {
1754
+ type: "button",
1755
+ className: "malix-pagination__arrow",
1756
+ "data-disabled": isFirstPage || void 0,
1757
+ disabled: isFirstPage,
1758
+ onClick: () => onPageChange(currentPage - 1),
1759
+ "aria-label": "Previous page",
1760
+ children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ChevronLeft, {})
1761
+ }
1762
+ ),
1763
+ variant === "full" ? pages.map((page) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
1764
+ "button",
1765
+ {
1766
+ type: "button",
1767
+ className: "malix-pagination__item",
1768
+ "data-active": page === currentPage || void 0,
1769
+ "aria-current": page === currentPage ? "page" : void 0,
1770
+ onClick: () => onPageChange(page),
1771
+ children: page
1772
+ },
1773
+ page
1774
+ )) : /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("span", { className: "malix-pagination__label", children: [
1775
+ currentPage,
1776
+ " of ",
1777
+ totalPages
1778
+ ] }),
1779
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
1780
+ "button",
1781
+ {
1782
+ type: "button",
1783
+ className: "malix-pagination__arrow",
1784
+ "data-disabled": isLastPage || void 0,
1785
+ disabled: isLastPage,
1786
+ onClick: () => onPageChange(currentPage + 1),
1787
+ "aria-label": "Next page",
1788
+ children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ChevronRight, {})
1789
+ }
1790
+ )
1791
+ ]
1792
+ }
1793
+ );
1794
+ }
1795
+
1796
+ // src/components/StatusDot.tsx
1797
+ var import_jsx_runtime42 = require("react/jsx-runtime");
1798
+ function StatusDot({
1799
+ variant = "default",
1800
+ label,
1801
+ className,
1802
+ ...props
1803
+ }) {
1804
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
1805
+ "span",
1806
+ {
1807
+ className: `malix-status-dot${className ? ` ${className}` : ""}`,
1808
+ "data-variant": variant,
1809
+ ...props,
1810
+ children: [
1811
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "malix-status-dot__dot", "aria-hidden": "true" }),
1812
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "malix-status-dot__label", children: label })
1813
+ ]
1814
+ }
1815
+ );
1816
+ }
1817
+
1818
+ // src/components/Dropzone.tsx
1819
+ var import_react11 = require("react");
1820
+ var import_jsx_runtime43 = require("react/jsx-runtime");
1821
+ function Dropzone({
1822
+ onDrop,
1823
+ accept,
1824
+ title = "Drop files here",
1825
+ hint = "or click to browse",
1826
+ disabled = false,
1827
+ className,
1828
+ ...props
1829
+ }) {
1830
+ const [dragging, setDragging] = (0, import_react11.useState)(false);
1831
+ const inputRef = (0, import_react11.useRef)(null);
1832
+ function handleDragOver(event) {
1833
+ event.preventDefault();
1834
+ if (!disabled) setDragging(true);
1835
+ }
1836
+ function handleDragLeave(event) {
1837
+ event.preventDefault();
1838
+ setDragging(false);
1839
+ }
1840
+ function handleDrop(event) {
1841
+ event.preventDefault();
1842
+ setDragging(false);
1843
+ if (disabled) return;
1844
+ const files = Array.from(event.dataTransfer.files);
1845
+ onDrop?.(files);
1846
+ }
1847
+ function handleInputChange(event) {
1848
+ const files = event.target.files ? Array.from(event.target.files) : [];
1849
+ if (files.length > 0) onDrop?.(files);
1850
+ event.target.value = "";
1851
+ }
1852
+ function handleClick() {
1853
+ if (!disabled) inputRef.current?.click();
1854
+ }
1855
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
1856
+ "div",
1857
+ {
1858
+ className: `malix-dropzone${className ? ` ${className}` : ""}`,
1859
+ "data-dragging": dragging,
1860
+ "data-disabled": disabled,
1861
+ onDragOver: handleDragOver,
1862
+ onDragLeave: handleDragLeave,
1863
+ onDrop: handleDrop,
1864
+ onClick: handleClick,
1865
+ role: "button",
1866
+ tabIndex: disabled ? -1 : 0,
1867
+ "aria-disabled": disabled || void 0,
1868
+ ...props,
1869
+ children: [
1870
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
1871
+ "input",
1872
+ {
1873
+ ref: inputRef,
1874
+ type: "file",
1875
+ accept,
1876
+ onChange: handleInputChange,
1877
+ hidden: true,
1878
+ "aria-hidden": "true"
1879
+ }
1880
+ ),
1881
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
1882
+ "svg",
1883
+ {
1884
+ className: "malix-dropzone__icon",
1885
+ width: "32",
1886
+ height: "32",
1887
+ viewBox: "0 0 24 24",
1888
+ fill: "none",
1889
+ stroke: "currentColor",
1890
+ strokeWidth: "1.5",
1891
+ strokeLinecap: "round",
1892
+ strokeLinejoin: "round",
1893
+ "aria-hidden": "true",
1894
+ children: [
1895
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { d: "M4 14.899A7 7 0 1 1 15.71 8h1.79a4.5 4.5 0 0 1 2.5 8.242" }),
1896
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { d: "M12 12v9" }),
1897
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("path", { d: "m16 16-4-4-4 4" })
1898
+ ]
1899
+ }
1900
+ ),
1901
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "malix-dropzone__title", children: title }),
1902
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "malix-dropzone__hint", children: hint }),
1903
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "malix-dropzone__browse-btn", children: "Browse files" })
1904
+ ]
1905
+ }
1906
+ );
1907
+ }
1908
+
1909
+ // src/components/SplitPane.tsx
1910
+ var import_react12 = require("react");
1911
+ var import_jsx_runtime44 = require("react/jsx-runtime");
1912
+ function SplitPane({
1913
+ leftPanel,
1914
+ rightPanel,
1915
+ leftTitle,
1916
+ rightTitle,
1917
+ defaultSplit = 50,
1918
+ className,
1919
+ ...props
1920
+ }) {
1921
+ const [split, setSplit] = (0, import_react12.useState)(defaultSplit);
1922
+ const containerRef = (0, import_react12.useRef)(null);
1923
+ const dragging = (0, import_react12.useRef)(false);
1924
+ const onMouseDown = (0, import_react12.useCallback)((e) => {
1925
+ e.preventDefault();
1926
+ dragging.current = true;
1927
+ }, []);
1928
+ (0, import_react12.useEffect)(() => {
1929
+ function onMouseMove(e) {
1930
+ if (!dragging.current || !containerRef.current) return;
1931
+ const rect = containerRef.current.getBoundingClientRect();
1932
+ const x = e.clientX - rect.left;
1933
+ const pct = Math.min(Math.max(x / rect.width * 100, 5), 95);
1934
+ setSplit(pct);
1935
+ }
1936
+ function onMouseUp() {
1937
+ dragging.current = false;
1938
+ }
1939
+ document.addEventListener("mousemove", onMouseMove);
1940
+ document.addEventListener("mouseup", onMouseUp);
1941
+ return () => {
1942
+ document.removeEventListener("mousemove", onMouseMove);
1943
+ document.removeEventListener("mouseup", onMouseUp);
1944
+ };
1945
+ }, []);
1946
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
1947
+ "div",
1948
+ {
1949
+ ref: containerRef,
1950
+ className: `malix-split-pane${className ? ` ${className}` : ""}`,
1951
+ ...props,
1952
+ children: [
1953
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)("div", { className: "malix-split-pane__left", style: { width: `${split}%` }, children: [
1954
+ leftTitle ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "malix-split-pane__panel-title", children: leftTitle }) : null,
1955
+ leftPanel
1956
+ ] }),
1957
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
1958
+ "div",
1959
+ {
1960
+ className: "malix-split-pane__handle",
1961
+ role: "separator",
1962
+ "aria-valuenow": Math.round(split),
1963
+ "aria-valuemin": 5,
1964
+ "aria-valuemax": 95,
1965
+ "aria-label": "Resize panels",
1966
+ onMouseDown,
1967
+ children: [
1968
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "malix-split-pane__handle-dot", "aria-hidden": "true" }),
1969
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "malix-split-pane__handle-dot", "aria-hidden": "true" }),
1970
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "malix-split-pane__handle-dot", "aria-hidden": "true" })
1971
+ ]
1972
+ }
1973
+ ),
1974
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)("div", { className: "malix-split-pane__right", style: { width: `${100 - split}%` }, children: [
1975
+ rightTitle ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "malix-split-pane__panel-title", children: rightTitle }) : null,
1976
+ rightPanel
1977
+ ] })
1978
+ ]
1979
+ }
1980
+ );
1981
+ }
1982
+
1983
+ // src/components/PricingCard.tsx
1984
+ var import_jsx_runtime45 = require("react/jsx-runtime");
1985
+ function PricingCard({
1986
+ planName,
1987
+ price,
1988
+ period = "/month",
1989
+ description,
1990
+ features,
1991
+ ctaLabel = "Get Started",
1992
+ onCtaClick,
1993
+ highlighted = false,
1994
+ className,
1995
+ ...props
1996
+ }) {
1997
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
1998
+ "div",
1999
+ {
2000
+ className: `malix-pricing-card${className ? ` ${className}` : ""}`,
2001
+ "data-highlighted": highlighted || void 0,
2002
+ ...props,
2003
+ children: [
2004
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "malix-pricing-card__badge", children: planName }),
2005
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: "malix-pricing-card__price-row", children: [
2006
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "malix-pricing-card__price", children: price }),
2007
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "malix-pricing-card__period", children: period })
2008
+ ] }),
2009
+ description ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: "malix-pricing-card__description", children: description }) : null,
2010
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("ul", { className: "malix-pricing-card__features", children: features.map((feature, i) => /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("li", { className: "malix-pricing-card__feature-item", children: [
2011
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
2012
+ "svg",
2013
+ {
2014
+ className: "malix-pricing-card__check-icon",
2015
+ width: "16",
2016
+ height: "16",
2017
+ viewBox: "0 0 24 24",
2018
+ fill: "none",
2019
+ stroke: "currentColor",
2020
+ strokeWidth: "2",
2021
+ strokeLinecap: "round",
2022
+ strokeLinejoin: "round",
2023
+ "aria-hidden": "true",
2024
+ children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("polyline", { points: "20 6 9 17 4 12" })
2025
+ }
2026
+ ),
2027
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { children: feature })
2028
+ ] }, i)) }),
2029
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
2030
+ "button",
2031
+ {
2032
+ type: "button",
2033
+ className: "malix-pricing-card__cta",
2034
+ onClick: onCtaClick,
2035
+ children: ctaLabel
2036
+ }
2037
+ )
2038
+ ]
2039
+ }
2040
+ );
2041
+ }
2042
+
2043
+ // src/components/OnboardingPopover.tsx
2044
+ var import_jsx_runtime46 = require("react/jsx-runtime");
2045
+ function OnboardingPopover({
2046
+ step,
2047
+ totalSteps,
2048
+ title,
2049
+ description,
2050
+ onNext,
2051
+ onSkip,
2052
+ nextLabel = "Next",
2053
+ className,
2054
+ ...props
2055
+ }) {
2056
+ return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)(
2057
+ "div",
2058
+ {
2059
+ className: `malix-onboarding-popover${className ? ` ${className}` : ""}`,
2060
+ role: "dialog",
2061
+ "aria-label": `Step ${step} of ${totalSteps}: ${title}`,
2062
+ ...props,
2063
+ children: [
2064
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("span", { className: "malix-onboarding-popover__step", children: [
2065
+ "Step ",
2066
+ step,
2067
+ " of ",
2068
+ totalSteps
2069
+ ] }),
2070
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("h3", { className: "malix-onboarding-popover__title", children: title }),
2071
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("p", { className: "malix-onboarding-popover__description", children: description }),
2072
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: "malix-onboarding-popover__actions", children: [
2073
+ onSkip ? /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
2074
+ "button",
2075
+ {
2076
+ type: "button",
2077
+ className: "malix-onboarding-popover__skip",
2078
+ onClick: onSkip,
2079
+ children: "Skip"
2080
+ }
2081
+ ) : null,
2082
+ onNext ? /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
2083
+ "button",
2084
+ {
2085
+ type: "button",
2086
+ className: "malix-onboarding-popover__next-btn",
2087
+ onClick: onNext,
2088
+ children: nextLabel
2089
+ }
2090
+ ) : null
2091
+ ] })
2092
+ ]
2093
+ }
2094
+ );
2095
+ }
2096
+
2097
+ // src/components/CreditsIndicator.tsx
2098
+ var import_jsx_runtime47 = require("react/jsx-runtime");
2099
+ function CreditsIndicator({
2100
+ remaining,
2101
+ label = "Credits Remaining",
2102
+ className,
2103
+ ...props
2104
+ }) {
2105
+ return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
2106
+ "div",
2107
+ {
2108
+ className: `malix-credits-indicator${className ? ` ${className}` : ""}`,
2109
+ ...props,
2110
+ children: [
2111
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "malix-credits-indicator__icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
2112
+ "svg",
2113
+ {
2114
+ width: "20",
2115
+ height: "20",
2116
+ viewBox: "0 0 24 24",
2117
+ fill: "none",
2118
+ stroke: "currentColor",
2119
+ strokeWidth: "2",
2120
+ strokeLinecap: "round",
2121
+ strokeLinejoin: "round",
2122
+ children: [
2123
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("ellipse", { cx: "12", cy: "6", rx: "8", ry: "3" }),
2124
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("path", { d: "M4 6v6c0 1.66 3.58 3 8 3s8-1.34 8-3V6" }),
2125
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("path", { d: "M4 12v6c0 1.66 3.58 3 8 3s8-1.34 8-3v-6" })
2126
+ ]
2127
+ }
2128
+ ) }),
2129
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "malix-credits-indicator__info", children: [
2130
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "malix-credits-indicator__label", children: label }),
2131
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "malix-credits-indicator__value", children: remaining })
2132
+ ] })
2133
+ ]
2134
+ }
2135
+ );
2136
+ }
2137
+
2138
+ // src/components/LanguageSelector.tsx
2139
+ var import_jsx_runtime48 = require("react/jsx-runtime");
2140
+ function LanguageSelector({
2141
+ value,
2142
+ options,
2143
+ onChange,
2144
+ className,
2145
+ ...props
2146
+ }) {
2147
+ const selectedOption = options?.find((opt) => opt.value === value);
2148
+ const displayLabel = selectedOption?.label ?? value;
2149
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
2150
+ "div",
2151
+ {
2152
+ className: `malix-language-selector${className ? ` ${className}` : ""}`,
2153
+ ...props,
2154
+ children: [
2155
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "malix-language-selector__icon", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
2156
+ "svg",
2157
+ {
2158
+ width: "16",
2159
+ height: "16",
2160
+ viewBox: "0 0 24 24",
2161
+ fill: "none",
2162
+ stroke: "currentColor",
2163
+ strokeWidth: "2",
2164
+ strokeLinecap: "round",
2165
+ strokeLinejoin: "round",
2166
+ children: [
2167
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("circle", { cx: "12", cy: "12", r: "10" }),
2168
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("line", { x1: "2", y1: "12", x2: "22", y2: "12" }),
2169
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("path", { d: "M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10A15.3 15.3 0 0 1 12 2z" })
2170
+ ]
2171
+ }
2172
+ ) }),
2173
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
2174
+ "select",
2175
+ {
2176
+ className: "malix-language-selector__select",
2177
+ value,
2178
+ onChange: (e) => onChange?.(e.target.value),
2179
+ "aria-label": "Select language",
2180
+ children: options ? options.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("option", { value: opt.value, children: opt.label }, opt.value)) : /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("option", { value, children: displayLabel })
2181
+ }
2182
+ ),
2183
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "malix-language-selector__label", children: displayLabel }),
2184
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "malix-language-selector__chevron", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
2185
+ "svg",
2186
+ {
2187
+ width: "14",
2188
+ height: "14",
2189
+ viewBox: "0 0 24 24",
2190
+ fill: "none",
2191
+ stroke: "currentColor",
2192
+ strokeWidth: "2",
2193
+ strokeLinecap: "round",
2194
+ strokeLinejoin: "round",
2195
+ children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("polyline", { points: "6 9 12 15 18 9" })
2196
+ }
2197
+ ) })
2198
+ ]
2199
+ }
2200
+ );
2201
+ }
2202
+
2203
+ // src/components/UserProfilePopover.tsx
2204
+ var import_jsx_runtime49 = require("react/jsx-runtime");
2205
+ function UserProfilePopover({
2206
+ name,
2207
+ email,
2208
+ avatar,
2209
+ menuItems,
2210
+ onLogout,
2211
+ credits,
2212
+ className,
2213
+ ...props
2214
+ }) {
2215
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
2216
+ "div",
2217
+ {
2218
+ className: `malix-user-profile${className ? ` ${className}` : ""}`,
2219
+ ...props,
2220
+ children: [
2221
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "malix-user-profile__header", children: [
2222
+ avatar ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__avatar", children: avatar }) : null,
2223
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "malix-user-profile__info", children: [
2224
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__name", children: name }),
2225
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__email", children: email })
2226
+ ] })
2227
+ ] }),
2228
+ credits !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "malix-user-profile__credits", children: [
2229
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__credits-label", children: "Credits" }),
2230
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__credits-value", children: credits })
2231
+ ] }) : null,
2232
+ menuItems && menuItems.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(import_jsx_runtime49.Fragment, { children: [
2233
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("hr", { className: "malix-user-profile__divider" }),
2234
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("nav", { className: "malix-user-profile__menu", role: "menu", children: menuItems.map((item, i) => /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
2235
+ "button",
2236
+ {
2237
+ type: "button",
2238
+ className: "malix-user-profile__menu-item",
2239
+ role: "menuitem",
2240
+ onClick: item.onClick,
2241
+ children: [
2242
+ item.icon ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__menu-item-icon", children: item.icon }) : null,
2243
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "malix-user-profile__menu-item-label", children: item.label })
2244
+ ]
2245
+ },
2246
+ i
2247
+ )) })
2248
+ ] }) : null,
2249
+ onLogout ? /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(import_jsx_runtime49.Fragment, { children: [
2250
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("hr", { className: "malix-user-profile__divider" }),
2251
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
2252
+ "button",
2253
+ {
2254
+ type: "button",
2255
+ className: "malix-user-profile__logout",
2256
+ onClick: onLogout,
2257
+ children: [
2258
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
2259
+ "svg",
2260
+ {
2261
+ width: "16",
2262
+ height: "16",
2263
+ viewBox: "0 0 24 24",
2264
+ fill: "none",
2265
+ stroke: "currentColor",
2266
+ strokeWidth: "2",
2267
+ strokeLinecap: "round",
2268
+ strokeLinejoin: "round",
2269
+ children: [
2270
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
2271
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("polyline", { points: "16 17 21 12 16 7" }),
2272
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("line", { x1: "21", y1: "12", x2: "9", y2: "12" })
2273
+ ]
2274
+ }
2275
+ ),
2276
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { children: "Log out" })
2277
+ ]
2278
+ }
2279
+ )
2280
+ ] }) : null
2281
+ ]
2282
+ }
2283
+ );
2284
+ }
2285
+ // Annotate the CommonJS export names for ESM import in node:
2286
+ 0 && (module.exports = {
2287
+ Accordion,
2288
+ Avatar,
2289
+ Badge,
2290
+ Banner,
2291
+ Breadcrumb,
2292
+ Button,
2293
+ Card,
2294
+ ChatInput,
2295
+ Checkbox,
2296
+ CreditsIndicator,
2297
+ DataTable,
2298
+ DateInput,
2299
+ Divider,
2300
+ Dropzone,
2301
+ EmptyState,
2302
+ FileCard,
2303
+ FilterTabs,
2304
+ FlyoutMenu,
2305
+ GlassPopover,
2306
+ Header,
2307
+ Input,
2308
+ InputGroup,
2309
+ LanguageSelector,
2310
+ Modal,
2311
+ OnboardingPopover,
2312
+ OperationStatus,
2313
+ Overlay,
2314
+ Pagination,
2315
+ Pill,
2316
+ PricingCard,
2317
+ ProgressBar,
2318
+ Radio,
2319
+ SearchInput,
2320
+ SectionHeader,
2321
+ SegmentedControl,
2322
+ Select,
2323
+ SelectGroup,
2324
+ SelectionCard,
2325
+ SidebarItem,
2326
+ SidebarPanel,
2327
+ SplitPane,
2328
+ StatCard,
2329
+ StatusDot,
2330
+ Stepper,
2331
+ TabBar,
2332
+ Textarea,
2333
+ Toggle,
2334
+ Tooltip,
2335
+ UserProfilePopover,
2336
+ ValidationAlert,
2337
+ tokenRegistry
2338
+ });