@lumx/vue 4.2.1-alpha.8 → 4.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -1,235 +1,22 @@
1
- import { ColorVariant as jr, Theme as kr } from '@lumx/core/js/constants/index.js';
1
+ import { ColorVariant as kr, Theme as Pr } from '@lumx/core/js/constants/index.js';
2
2
  export * from '@lumx/core/js/constants/index.js';
3
3
  export * from '@lumx/core/js/types/index.js';
4
- import { createVNode as d, mergeProps as g, inject as Ue, defineComponent as _, useAttrs as P, isVNode as We, computed as A, unref as W, provide as Vt, getCurrentScope as wr, onScopeDispose as xr, watch as He, toValue as Ke, shallowRef as Or, getCurrentInstance as Ir, onMounted as $r, ref as Cr, useSlots as Gt, Fragment as zt, useTemplateRef as Br, openBlock as Ut, createBlock as Wt, resolveDynamicComponent as Er, withCtx as Ht, normalizeProps as qr, guardReactiveProps as Rr, renderSlot as Kt, toRefs as Mr, reactive as Lr } from "vue";
5
- import { getDisabledState as Dr } from "@lumx/core/js/utils/disabledState";
4
+ import { createVNode as f, mergeProps as g, isVNode as X, inject as ze, computed as A, unref as Ze, defineComponent as S, provide as Wt, useAttrs as P, getCurrentScope as jr, onScopeDispose as xr, watch as Q, toValue as He, shallowRef as wr, getCurrentInstance as Cr, onMounted as Ir, ref as zt, useSlots as Ht, Fragment as Kt, useTemplateRef as Or, toRefs as $r, reactive as Er } from "vue";
5
+ import { getDisabledState as qr } from "@lumx/core/js/utils/disabledState";
6
6
  import { mdiAlertCircle as Yt } from '@lumx/icons/esm/alert-circle.js';
7
- import { classNames as Fr } from "@lumx/core/js/utils";
8
- import { mdiAlert as Vr } from '@lumx/icons/esm/alert.js';
9
- import { mdiCheckCircle as Gr } from '@lumx/icons/esm/check-circle.js';
10
- import { mdiClose as zr } from '@lumx/icons/esm/close.js';
11
- import { mdiInformation as Ur } from '@lumx/icons/esm/information.js';
12
- var U = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
13
- function Ye(e) {
7
+ import { classNames as Br } from "@lumx/core/js/utils";
8
+ import { mdiCheck as Mr } from '@lumx/icons/esm/check.js';
9
+ import { mdiMinus as Rr } from '@lumx/icons/esm/minus.js';
10
+ import { mdiAlert as Lr } from '@lumx/icons/esm/alert.js';
11
+ import { mdiCheckCircle as Dr } from '@lumx/icons/esm/check-circle.js';
12
+ import { mdiClose as Fr } from '@lumx/icons/esm/close.js';
13
+ import { mdiInformation as Vr } from '@lumx/icons/esm/information.js';
14
+ var K = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
15
+ function Ke(e) {
14
16
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
15
17
  }
16
- var re = { exports: {} };
17
- var Qe;
18
- function Wr() {
19
- return Qe || (Qe = 1, (function(e) {
20
- (function() {
21
- var t = {}.hasOwnProperty;
22
- function r() {
23
- for (var n = [], a = 0; a < arguments.length; a++) {
24
- var o = arguments[a];
25
- if (o) {
26
- var s = typeof o;
27
- if (s === "string" || s === "number")
28
- n.push(o);
29
- else if (Array.isArray(o)) {
30
- if (o.length) {
31
- var i = r.apply(null, o);
32
- i && n.push(i);
33
- }
34
- } else if (s === "object") {
35
- if (o.toString !== Object.prototype.toString && !o.toString.toString().includes("[native code]")) {
36
- n.push(o.toString());
37
- continue;
38
- }
39
- for (var c in o)
40
- t.call(o, c) && o[c] && n.push(c);
41
- }
42
- }
43
- }
44
- return n.join(" ");
45
- }
46
- e.exports ? (r.default = r, e.exports = r) : window.classNames = r;
47
- })();
48
- })(re)), re.exports;
49
- }
50
- var Hr = Wr();
51
- const S = /* @__PURE__ */ Ye(Hr);
52
- function Jt(e, t) {
53
- if (!e) return [void 0, t];
54
- const [r, n] = e.split("-");
55
- return [r, t || n];
56
- }
57
- function Kr(e, t, r) {
58
- const [n, a = jr.N] = Jt(t, r);
59
- return `lumx-color-${e}-${n}-${a}`;
60
- }
61
- const Yr = (e, t) => Kr("font", e, t);
62
- function Xt(e) {
63
- return `lumx-typography-${e}`;
64
- }
65
- function Qt(e, t) {
66
- const r = [];
67
- for (const [n, a] of Object.entries(t))
68
- a && r.push(`${e}--${n}`);
69
- return r.join(" ");
70
- }
71
- function H(e, t, r) {
72
- let n, a;
73
- return Array.isArray(t) ? a = t : (n = t, a = r), !n && !a ? e : S(
74
- // Additional classes
75
- a,
76
- // Base class
77
- e,
78
- // Modifier(s)
79
- n ? Qt(e, n) : null
80
- );
81
- }
82
- function Ze(e, t, r, n) {
83
- return Array.isArray(r) ? H(`${e}__${t}`, r) : H(`${e}__${t}`, r, n);
84
- }
85
- function k(e) {
86
- function t(n, a) {
87
- return Array.isArray(n) ? H(e, n) : H(e, n, a);
88
- }
89
- function r(n, a, o) {
90
- return Array.isArray(a) ? Ze(e, n, a) : Ze(e, n, a, o);
91
- }
92
- return {
93
- block: t,
94
- element: r,
95
- modifier: (n) => Qt(e, n)
96
- };
97
- }
98
- const K = {
99
- light: "light",
100
- dark: "dark"
101
- }, j = {
102
- xxs: "xxs",
103
- xs: "xs",
104
- s: "s",
105
- m: "m",
106
- xl: "xl",
107
- xxl: "xxl"
108
- }, Jr = {
109
- horizontal: "horizontal"
110
- }, $ = {
111
- low: "low",
112
- high: "high"
113
- }, Xr = {
114
- overline: "overline",
115
- caption: "caption",
116
- body1: "body1",
117
- body2: "body2",
118
- subtitle1: "subtitle1",
119
- subtitle2: "subtitle2",
120
- title: "title",
121
- headline: "headline",
122
- display1: "display1"
123
- }, R = {
124
- ...Xr
125
- }, O = {
126
- info: "info",
127
- success: "success",
128
- warning: "warning",
129
- error: "error"
130
- }, v = {
131
- primary: "primary",
132
- blue: "blue",
133
- dark: "dark",
134
- green: "green",
135
- yellow: "yellow",
136
- red: "red",
137
- light: "light"
138
- }, Qr = {
139
- [O.error]: { color: "red" },
140
- [O.success]: { color: "green" },
141
- [O.warning]: { color: "yellow" }
142
- }, Zr = "InputHelper", en = "lumx-input-helper", Zt = en, {
143
- block: tn
144
- } = k(Zt), er = {
145
- kind: O.info
146
- };
147
- function Y(e) {
148
- const {
149
- children: t,
150
- className: r,
151
- kind: n = er.kind,
152
- theme: a,
153
- ref: o,
154
- ...s
155
- } = e, {
156
- color: i
157
- } = Qr[n] || {};
158
- return d("p", g({
159
- ref: o
160
- }, s, {
161
- className: S(r, tn({
162
- [`color-${i}`]: !!i,
163
- [`theme-${a}`]: !!a
164
- }))
165
- }), [t]);
166
- }
167
- Y.displayName = Zr;
168
- Y.className = Zt;
169
- Y.defaultProps = er;
170
- function C(e = { defaultTheme: kr.light }) {
171
- const { defaultTheme: t } = e;
172
- return Ue("theme", void 0) || t;
173
- }
174
- const w = () => (...e) => e, Ma = /* @__PURE__ */ _((e, {
175
- slots: t
176
- }) => {
177
- const r = P(), n = C();
178
- return () => d(Y, g(e, r, {
179
- className: e.class,
180
- theme: e.theme || n,
181
- children: t.default?.()
182
- }), null);
183
- }, {
184
- name: "InputHelper",
185
- inheritAttrs: !1,
186
- // Redefine properties so that they come in as `props` on the `defineComponent` function
187
- props: w()("kind", "theme", "class")
188
- }), rn = "InputLabel", nn = "lumx-input-label", tr = nn, {
189
- block: an
190
- } = k(tr), on = {};
191
- function J(e) {
192
- const {
193
- children: t,
194
- className: r,
195
- htmlFor: n,
196
- isRequired: a,
197
- theme: o,
198
- typography: s,
199
- ref: i,
200
- ...c
201
- } = e;
202
- return d("label", g({
203
- ref: i
204
- }, c, {
205
- htmlFor: n,
206
- className: S(r, an({
207
- "is-required": a,
208
- [`theme-${o}`]: !!o,
209
- "has-custom-typography": !!s
210
- }), s && Xt(s))
211
- }), [t]);
212
- }
213
- J.displayName = rn;
214
- J.className = tr;
215
- J.defaultProps = on;
216
- const La = /* @__PURE__ */ _((e, {
217
- slots: t
218
- }) => {
219
- const r = P(), n = C();
220
- return () => d(J, g(e, r, {
221
- className: e.class,
222
- theme: e.theme || n,
223
- children: t.default?.()
224
- }), null);
225
- }, {
226
- name: "InputLabel",
227
- inheritAttrs: !1,
228
- // Redefine properties so that they come in as `props` on the `defineComponent` function
229
- props: w()("htmlFor", "isRequired", "typography", "theme", "class")
230
- });
231
18
  var ne, et;
232
- function rr() {
19
+ function Jt() {
233
20
  if (et) return ne;
234
21
  et = 1;
235
22
  var e = Object.prototype;
@@ -240,7 +27,7 @@ function rr() {
240
27
  return ne = t, ne;
241
28
  }
242
29
  var ae, tt;
243
- function sn() {
30
+ function Gr() {
244
31
  if (tt) return ae;
245
32
  tt = 1;
246
33
  function e(t, r) {
@@ -251,17 +38,17 @@ function sn() {
251
38
  return ae = e, ae;
252
39
  }
253
40
  var oe, rt;
254
- function cn() {
41
+ function Ur() {
255
42
  if (rt) return oe;
256
43
  rt = 1;
257
- var e = sn(), t = e(Object.keys, Object);
44
+ var e = Gr(), t = e(Object.keys, Object);
258
45
  return oe = t, oe;
259
46
  }
260
47
  var se, nt;
261
- function ln() {
48
+ function Wr() {
262
49
  if (nt) return se;
263
50
  nt = 1;
264
- var e = rr(), t = cn(), r = Object.prototype, n = r.hasOwnProperty;
51
+ var e = Jt(), t = Ur(), r = Object.prototype, n = r.hasOwnProperty;
265
52
  function a(o) {
266
53
  if (!e(o))
267
54
  return t(o);
@@ -273,31 +60,31 @@ function ln() {
273
60
  return se = a, se;
274
61
  }
275
62
  var ie, at;
276
- function nr() {
63
+ function Xt() {
277
64
  if (at) return ie;
278
65
  at = 1;
279
- var e = typeof U == "object" && U && U.Object === Object && U;
66
+ var e = typeof K == "object" && K && K.Object === Object && K;
280
67
  return ie = e, ie;
281
68
  }
282
69
  var ce, ot;
283
- function I() {
70
+ function $() {
284
71
  if (ot) return ce;
285
72
  ot = 1;
286
- var e = nr(), t = typeof self == "object" && self && self.Object === Object && self, r = e || t || Function("return this")();
73
+ var e = Xt(), t = typeof self == "object" && self && self.Object === Object && self, r = e || t || Function("return this")();
287
74
  return ce = r, ce;
288
75
  }
289
76
  var le, st;
290
- function ar() {
77
+ function Qt() {
291
78
  if (st) return le;
292
79
  st = 1;
293
- var e = I(), t = e.Symbol;
80
+ var e = $(), t = e.Symbol;
294
81
  return le = t, le;
295
82
  }
296
83
  var ue, it;
297
- function un() {
84
+ function zr() {
298
85
  if (it) return ue;
299
86
  it = 1;
300
- var e = ar(), t = Object.prototype, r = t.hasOwnProperty, n = t.toString, a = e ? e.toStringTag : void 0;
87
+ var e = Qt(), t = Object.prototype, r = t.hasOwnProperty, n = t.toString, a = e ? e.toStringTag : void 0;
301
88
  function o(s) {
302
89
  var i = r.call(s, a), c = s[a];
303
90
  try {
@@ -310,28 +97,28 @@ function un() {
310
97
  }
311
98
  return ue = o, ue;
312
99
  }
313
- var fe, ct;
314
- function fn() {
315
- if (ct) return fe;
100
+ var de, ct;
101
+ function Hr() {
102
+ if (ct) return de;
316
103
  ct = 1;
317
104
  var e = Object.prototype, t = e.toString;
318
105
  function r(n) {
319
106
  return t.call(n);
320
107
  }
321
- return fe = r, fe;
108
+ return de = r, de;
322
109
  }
323
- var de, lt;
324
- function X() {
325
- if (lt) return de;
110
+ var fe, lt;
111
+ function Z() {
112
+ if (lt) return fe;
326
113
  lt = 1;
327
- var e = ar(), t = un(), r = fn(), n = "[object Null]", a = "[object Undefined]", o = e ? e.toStringTag : void 0;
114
+ var e = Qt(), t = zr(), r = Hr(), n = "[object Null]", a = "[object Undefined]", o = e ? e.toStringTag : void 0;
328
115
  function s(i) {
329
116
  return i == null ? i === void 0 ? a : n : o && o in Object(i) ? t(i) : r(i);
330
117
  }
331
- return de = s, de;
118
+ return fe = s, fe;
332
119
  }
333
120
  var pe, ut;
334
- function or() {
121
+ function Zt() {
335
122
  if (ut) return pe;
336
123
  ut = 1;
337
124
  function e(t) {
@@ -340,11 +127,11 @@ function or() {
340
127
  }
341
128
  return pe = e, pe;
342
129
  }
343
- var he, ft;
344
- function sr() {
345
- if (ft) return he;
346
- ft = 1;
347
- var e = X(), t = or(), r = "[object AsyncFunction]", n = "[object Function]", a = "[object GeneratorFunction]", o = "[object Proxy]";
130
+ var he, dt;
131
+ function er() {
132
+ if (dt) return he;
133
+ dt = 1;
134
+ var e = Z(), t = Zt(), r = "[object AsyncFunction]", n = "[object Function]", a = "[object GeneratorFunction]", o = "[object Proxy]";
348
135
  function s(i) {
349
136
  if (!t(i))
350
137
  return !1;
@@ -353,18 +140,18 @@ function sr() {
353
140
  }
354
141
  return he = s, he;
355
142
  }
356
- var me, dt;
357
- function dn() {
358
- if (dt) return me;
359
- dt = 1;
360
- var e = I(), t = e["__core-js_shared__"];
143
+ var me, ft;
144
+ function Kr() {
145
+ if (ft) return me;
146
+ ft = 1;
147
+ var e = $(), t = e["__core-js_shared__"];
361
148
  return me = t, me;
362
149
  }
363
150
  var be, pt;
364
- function pn() {
151
+ function Yr() {
365
152
  if (pt) return be;
366
153
  pt = 1;
367
- var e = dn(), t = (function() {
154
+ var e = Kr(), t = (function() {
368
155
  var n = /[^.]+$/.exec(e && e.keys && e.keys.IE_PROTO || "");
369
156
  return n ? "Symbol(src)_1." + n : "";
370
157
  })();
@@ -374,7 +161,7 @@ function pn() {
374
161
  return be = r, be;
375
162
  }
376
163
  var ve, ht;
377
- function ir() {
164
+ function tr() {
378
165
  if (ht) return ve;
379
166
  ht = 1;
380
167
  var e = Function.prototype, t = e.toString;
@@ -394,22 +181,22 @@ function ir() {
394
181
  return ve = r, ve;
395
182
  }
396
183
  var ge, mt;
397
- function hn() {
184
+ function Jr() {
398
185
  if (mt) return ge;
399
186
  mt = 1;
400
- var e = sr(), t = pn(), r = or(), n = ir(), a = /[\\^$.*+?()[\]{}|]/g, o = /^\[object .+?Constructor\]$/, s = Function.prototype, i = Object.prototype, c = s.toString, u = i.hasOwnProperty, l = RegExp(
187
+ var e = er(), t = Yr(), r = Zt(), n = tr(), a = /[\\^$.*+?()[\]{}|]/g, o = /^\[object .+?Constructor\]$/, s = Function.prototype, i = Object.prototype, c = s.toString, u = i.hasOwnProperty, l = RegExp(
401
188
  "^" + c.call(u).replace(a, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
402
189
  );
403
- function f(p) {
190
+ function d(p) {
404
191
  if (!r(p) || t(p))
405
192
  return !1;
406
193
  var h = e(p) ? l : o;
407
194
  return h.test(n(p));
408
195
  }
409
- return ge = f, ge;
196
+ return ge = d, ge;
410
197
  }
411
198
  var ye, bt;
412
- function mn() {
199
+ function Xr() {
413
200
  if (bt) return ye;
414
201
  bt = 1;
415
202
  function e(t, r) {
@@ -418,176 +205,176 @@ function mn() {
418
205
  return ye = e, ye;
419
206
  }
420
207
  var Ae, vt;
421
- function D() {
208
+ function F() {
422
209
  if (vt) return Ae;
423
210
  vt = 1;
424
- var e = hn(), t = mn();
211
+ var e = Jr(), t = Xr();
425
212
  function r(n, a) {
426
213
  var o = t(n, a);
427
214
  return e(o) ? o : void 0;
428
215
  }
429
216
  return Ae = r, Ae;
430
217
  }
431
- var _e, gt;
432
- function bn() {
433
- if (gt) return _e;
218
+ var Te, gt;
219
+ function Qr() {
220
+ if (gt) return Te;
434
221
  gt = 1;
435
- var e = D(), t = I(), r = e(t, "DataView");
436
- return _e = r, _e;
437
- }
438
- var Te, yt;
439
- function vn() {
440
- if (yt) return Te;
441
- yt = 1;
442
- var e = D(), t = I(), r = e(t, "Map");
222
+ var e = F(), t = $(), r = e(t, "DataView");
443
223
  return Te = r, Te;
444
224
  }
445
- var Se, At;
446
- function gn() {
447
- if (At) return Se;
448
- At = 1;
449
- var e = D(), t = I(), r = e(t, "Promise");
225
+ var Se, yt;
226
+ function Zr() {
227
+ if (yt) return Se;
228
+ yt = 1;
229
+ var e = F(), t = $(), r = e(t, "Map");
450
230
  return Se = r, Se;
451
231
  }
452
- var Ne, _t;
453
- function yn() {
454
- if (_t) return Ne;
455
- _t = 1;
456
- var e = D(), t = I(), r = e(t, "Set");
457
- return Ne = r, Ne;
232
+ var _e, At;
233
+ function en() {
234
+ if (At) return _e;
235
+ At = 1;
236
+ var e = F(), t = $(), r = e(t, "Promise");
237
+ return _e = r, _e;
458
238
  }
459
- var Pe, Tt;
460
- function An() {
461
- if (Tt) return Pe;
239
+ var Ne, Tt;
240
+ function tn() {
241
+ if (Tt) return Ne;
462
242
  Tt = 1;
463
- var e = D(), t = I(), r = e(t, "WeakMap");
464
- return Pe = r, Pe;
243
+ var e = F(), t = $(), r = e(t, "Set");
244
+ return Ne = r, Ne;
465
245
  }
466
- var je, St;
467
- function _n() {
468
- if (St) return je;
246
+ var ke, St;
247
+ function rn() {
248
+ if (St) return ke;
469
249
  St = 1;
470
- var e = bn(), t = vn(), r = gn(), n = yn(), a = An(), o = X(), s = ir(), i = "[object Map]", c = "[object Object]", u = "[object Promise]", l = "[object Set]", f = "[object WeakMap]", p = "[object DataView]", h = s(e), b = s(t), y = s(r), N = s(n), E = s(a), T = o;
471
- return (e && T(new e(new ArrayBuffer(1))) != p || t && T(new t()) != i || r && T(r.resolve()) != u || n && T(new n()) != l || a && T(new a()) != f) && (T = function(x) {
472
- var q = o(x), G = q == c ? x.constructor : void 0, z = G ? s(G) : "";
473
- if (z)
474
- switch (z) {
250
+ var e = F(), t = $(), r = e(t, "WeakMap");
251
+ return ke = r, ke;
252
+ }
253
+ var Pe, _t;
254
+ function nn() {
255
+ if (_t) return Pe;
256
+ _t = 1;
257
+ var e = Qr(), t = Zr(), r = en(), n = tn(), a = rn(), o = Z(), s = tr(), i = "[object Map]", c = "[object Object]", u = "[object Promise]", l = "[object Set]", d = "[object WeakMap]", p = "[object DataView]", h = s(e), b = s(t), v = s(r), _ = s(n), x = s(a), T = o;
258
+ return (e && T(new e(new ArrayBuffer(1))) != p || t && T(new t()) != i || r && T(r.resolve()) != u || n && T(new n()) != l || a && T(new a()) != d) && (T = function(w) {
259
+ var M = o(w), z = M == c ? w.constructor : void 0, H = z ? s(z) : "";
260
+ if (H)
261
+ switch (H) {
475
262
  case h:
476
263
  return p;
477
264
  case b:
478
265
  return i;
479
- case y:
266
+ case v:
480
267
  return u;
481
- case N:
268
+ case _:
482
269
  return l;
483
- case E:
484
- return f;
270
+ case x:
271
+ return d;
485
272
  }
486
- return q;
487
- }), je = T, je;
273
+ return M;
274
+ }), Pe = T, Pe;
488
275
  }
489
- var ke, Nt;
490
- function Je() {
491
- if (Nt) return ke;
276
+ var je, Nt;
277
+ function Ye() {
278
+ if (Nt) return je;
492
279
  Nt = 1;
493
280
  function e(t) {
494
281
  return t != null && typeof t == "object";
495
282
  }
496
- return ke = e, ke;
283
+ return je = e, je;
497
284
  }
498
- var we, Pt;
499
- function Tn() {
500
- if (Pt) return we;
501
- Pt = 1;
502
- var e = X(), t = Je(), r = "[object Arguments]";
285
+ var xe, kt;
286
+ function an() {
287
+ if (kt) return xe;
288
+ kt = 1;
289
+ var e = Z(), t = Ye(), r = "[object Arguments]";
503
290
  function n(a) {
504
291
  return t(a) && e(a) == r;
505
292
  }
506
- return we = n, we;
293
+ return xe = n, xe;
507
294
  }
508
- var xe, jt;
509
- function Sn() {
510
- if (jt) return xe;
511
- jt = 1;
512
- var e = Tn(), t = Je(), r = Object.prototype, n = r.hasOwnProperty, a = r.propertyIsEnumerable, o = e(/* @__PURE__ */ (function() {
295
+ var we, Pt;
296
+ function on() {
297
+ if (Pt) return we;
298
+ Pt = 1;
299
+ var e = an(), t = Ye(), r = Object.prototype, n = r.hasOwnProperty, a = r.propertyIsEnumerable, o = e(/* @__PURE__ */ (function() {
513
300
  return arguments;
514
301
  })()) ? e : function(s) {
515
302
  return t(s) && n.call(s, "callee") && !a.call(s, "callee");
516
303
  };
517
- return xe = o, xe;
304
+ return we = o, we;
518
305
  }
519
- var Oe, kt;
520
- function cr() {
521
- if (kt) return Oe;
522
- kt = 1;
306
+ var Ce, jt;
307
+ function rr() {
308
+ if (jt) return Ce;
309
+ jt = 1;
523
310
  var e = Array.isArray;
524
- return Oe = e, Oe;
311
+ return Ce = e, Ce;
525
312
  }
526
- var Ie, wt;
527
- function lr() {
528
- if (wt) return Ie;
529
- wt = 1;
313
+ var Ie, xt;
314
+ function nr() {
315
+ if (xt) return Ie;
316
+ xt = 1;
530
317
  var e = 9007199254740991;
531
318
  function t(r) {
532
319
  return typeof r == "number" && r > -1 && r % 1 == 0 && r <= e;
533
320
  }
534
321
  return Ie = t, Ie;
535
322
  }
536
- var $e, xt;
537
- function Nn() {
538
- if (xt) return $e;
539
- xt = 1;
540
- var e = sr(), t = lr();
323
+ var Oe, wt;
324
+ function sn() {
325
+ if (wt) return Oe;
326
+ wt = 1;
327
+ var e = er(), t = nr();
541
328
  function r(n) {
542
329
  return n != null && t(n.length) && !e(n);
543
330
  }
544
- return $e = r, $e;
331
+ return Oe = r, Oe;
545
332
  }
546
- var M = { exports: {} }, Ce, Ot;
547
- function Pn() {
548
- if (Ot) return Ce;
549
- Ot = 1;
333
+ var L = { exports: {} }, $e, Ct;
334
+ function cn() {
335
+ if (Ct) return $e;
336
+ Ct = 1;
550
337
  function e() {
551
338
  return !1;
552
339
  }
553
- return Ce = e, Ce;
340
+ return $e = e, $e;
554
341
  }
555
- M.exports;
342
+ L.exports;
556
343
  var It;
557
- function jn() {
344
+ function ln() {
558
345
  return It || (It = 1, (function(e, t) {
559
- var r = I(), n = Pn(), a = t && !t.nodeType && t, o = a && !0 && e && !e.nodeType && e, s = o && o.exports === a, i = s ? r.Buffer : void 0, c = i ? i.isBuffer : void 0, u = c || n;
346
+ var r = $(), n = cn(), a = t && !t.nodeType && t, o = a && !0 && e && !e.nodeType && e, s = o && o.exports === a, i = s ? r.Buffer : void 0, c = i ? i.isBuffer : void 0, u = c || n;
560
347
  e.exports = u;
561
- })(M, M.exports)), M.exports;
348
+ })(L, L.exports)), L.exports;
562
349
  }
563
- var Be, $t;
564
- function kn() {
565
- if ($t) return Be;
566
- $t = 1;
567
- var e = X(), t = lr(), r = Je(), n = "[object Arguments]", a = "[object Array]", o = "[object Boolean]", s = "[object Date]", i = "[object Error]", c = "[object Function]", u = "[object Map]", l = "[object Number]", f = "[object Object]", p = "[object RegExp]", h = "[object Set]", b = "[object String]", y = "[object WeakMap]", N = "[object ArrayBuffer]", E = "[object DataView]", T = "[object Float32Array]", x = "[object Float64Array]", q = "[object Int8Array]", G = "[object Int16Array]", z = "[object Int32Array]", _r = "[object Uint8Array]", Tr = "[object Uint8ClampedArray]", Sr = "[object Uint16Array]", Nr = "[object Uint32Array]", m = {};
568
- m[T] = m[x] = m[q] = m[G] = m[z] = m[_r] = m[Tr] = m[Sr] = m[Nr] = !0, m[n] = m[a] = m[N] = m[o] = m[E] = m[s] = m[i] = m[c] = m[u] = m[l] = m[f] = m[p] = m[h] = m[b] = m[y] = !1;
569
- function Pr(te) {
570
- return r(te) && t(te.length) && !!m[e(te)];
350
+ var Ee, Ot;
351
+ function un() {
352
+ if (Ot) return Ee;
353
+ Ot = 1;
354
+ var e = Z(), t = nr(), r = Ye(), n = "[object Arguments]", a = "[object Array]", o = "[object Boolean]", s = "[object Date]", i = "[object Error]", c = "[object Function]", u = "[object Map]", l = "[object Number]", d = "[object Object]", p = "[object RegExp]", h = "[object Set]", b = "[object String]", v = "[object WeakMap]", _ = "[object ArrayBuffer]", x = "[object DataView]", T = "[object Float32Array]", w = "[object Float64Array]", M = "[object Int8Array]", z = "[object Int16Array]", H = "[object Int32Array]", Ar = "[object Uint8Array]", Tr = "[object Uint8ClampedArray]", Sr = "[object Uint16Array]", _r = "[object Uint32Array]", m = {};
355
+ m[T] = m[w] = m[M] = m[z] = m[H] = m[Ar] = m[Tr] = m[Sr] = m[_r] = !0, m[n] = m[a] = m[_] = m[o] = m[x] = m[s] = m[i] = m[c] = m[u] = m[l] = m[d] = m[p] = m[h] = m[b] = m[v] = !1;
356
+ function Nr(re) {
357
+ return r(re) && t(re.length) && !!m[e(re)];
571
358
  }
572
- return Be = Pr, Be;
359
+ return Ee = Nr, Ee;
573
360
  }
574
- var Ee, Ct;
575
- function wn() {
576
- if (Ct) return Ee;
577
- Ct = 1;
361
+ var qe, $t;
362
+ function dn() {
363
+ if ($t) return qe;
364
+ $t = 1;
578
365
  function e(t) {
579
366
  return function(r) {
580
367
  return t(r);
581
368
  };
582
369
  }
583
- return Ee = e, Ee;
370
+ return qe = e, qe;
584
371
  }
585
- var L = { exports: {} };
586
- L.exports;
587
- var Bt;
588
- function xn() {
589
- return Bt || (Bt = 1, (function(e, t) {
590
- var r = nr(), n = t && !t.nodeType && t, a = n && !0 && e && !e.nodeType && e, o = a && a.exports === n, s = o && r.process, i = (function() {
372
+ var D = { exports: {} };
373
+ D.exports;
374
+ var Et;
375
+ function fn() {
376
+ return Et || (Et = 1, (function(e, t) {
377
+ var r = Xt(), n = t && !t.nodeType && t, a = n && !0 && e && !e.nodeType && e, o = a && a.exports === n, s = o && r.process, i = (function() {
591
378
  try {
592
379
  var c = a && a.require && a.require("util").types;
593
380
  return c || s && s.binding && s.binding("util");
@@ -595,43 +382,165 @@ function xn() {
595
382
  }
596
383
  })();
597
384
  e.exports = i;
598
- })(L, L.exports)), L.exports;
385
+ })(D, D.exports)), D.exports;
386
+ }
387
+ var Be, qt;
388
+ function pn() {
389
+ if (qt) return Be;
390
+ qt = 1;
391
+ var e = un(), t = dn(), r = fn(), n = r && r.isTypedArray, a = n ? t(n) : e;
392
+ return Be = a, Be;
393
+ }
394
+ var Me, Bt;
395
+ function hn() {
396
+ if (Bt) return Me;
397
+ Bt = 1;
398
+ var e = Wr(), t = nn(), r = on(), n = rr(), a = sn(), o = ln(), s = Jt(), i = pn(), c = "[object Map]", u = "[object Set]", l = Object.prototype, d = l.hasOwnProperty;
399
+ function p(h) {
400
+ if (h == null)
401
+ return !0;
402
+ if (a(h) && (n(h) || typeof h == "string" || typeof h.splice == "function" || o(h) || i(h) || r(h)))
403
+ return !h.length;
404
+ var b = t(h);
405
+ if (b == c || b == u)
406
+ return !h.size;
407
+ if (s(h))
408
+ return !e(h).length;
409
+ for (var v in h)
410
+ if (d.call(h, v))
411
+ return !1;
412
+ return !0;
413
+ }
414
+ return Me = p, Me;
415
+ }
416
+ var mn = hn();
417
+ const Mt = /* @__PURE__ */ Ke(mn), Y = {
418
+ light: "light",
419
+ dark: "dark"
420
+ }, C = {
421
+ xxs: "xxs",
422
+ xs: "xs",
423
+ s: "s",
424
+ m: "m",
425
+ xl: "xl",
426
+ xxl: "xxl"
427
+ }, bn = {
428
+ horizontal: "horizontal"
429
+ }, q = {
430
+ low: "low",
431
+ high: "high"
432
+ }, vn = {
433
+ overline: "overline",
434
+ caption: "caption",
435
+ body1: "body1",
436
+ body2: "body2",
437
+ subtitle1: "subtitle1",
438
+ subtitle2: "subtitle2",
439
+ title: "title",
440
+ headline: "headline",
441
+ display1: "display1"
442
+ }, R = {
443
+ ...vn
444
+ }, O = {
445
+ info: "info",
446
+ success: "success",
447
+ warning: "warning",
448
+ error: "error"
449
+ }, y = {
450
+ primary: "primary",
451
+ blue: "blue",
452
+ dark: "dark",
453
+ green: "green",
454
+ yellow: "yellow",
455
+ red: "red",
456
+ light: "light"
457
+ };
458
+ var Re = { exports: {} };
459
+ var Rt;
460
+ function gn() {
461
+ return Rt || (Rt = 1, (function(e) {
462
+ (function() {
463
+ var t = {}.hasOwnProperty;
464
+ function r() {
465
+ for (var n = [], a = 0; a < arguments.length; a++) {
466
+ var o = arguments[a];
467
+ if (o) {
468
+ var s = typeof o;
469
+ if (s === "string" || s === "number")
470
+ n.push(o);
471
+ else if (Array.isArray(o)) {
472
+ if (o.length) {
473
+ var i = r.apply(null, o);
474
+ i && n.push(i);
475
+ }
476
+ } else if (s === "object") {
477
+ if (o.toString !== Object.prototype.toString && !o.toString.toString().includes("[native code]")) {
478
+ n.push(o.toString());
479
+ continue;
480
+ }
481
+ for (var c in o)
482
+ t.call(o, c) && o[c] && n.push(c);
483
+ }
484
+ }
485
+ }
486
+ return n.join(" ");
487
+ }
488
+ e.exports ? (r.default = r, e.exports = r) : window.classNames = r;
489
+ })();
490
+ })(Re)), Re.exports;
491
+ }
492
+ var yn = gn();
493
+ const N = /* @__PURE__ */ Ke(yn);
494
+ function ar(e, t) {
495
+ if (!e) return [void 0, t];
496
+ const [r, n] = e.split("-");
497
+ return [r, t || n];
498
+ }
499
+ function An(e, t, r) {
500
+ const [n, a = kr.N] = ar(t, r);
501
+ return `lumx-color-${e}-${n}-${a}`;
502
+ }
503
+ const Tn = (e, t) => An("font", e, t);
504
+ function or(e) {
505
+ return `lumx-typography-${e}`;
506
+ }
507
+ function sr(e, t) {
508
+ const r = [];
509
+ for (const [n, a] of Object.entries(t))
510
+ a && r.push(`${e}--${n}`);
511
+ return r.join(" ");
512
+ }
513
+ function J(e, t, r) {
514
+ let n, a;
515
+ return Array.isArray(t) ? a = t : (n = t, a = r), !n && !a ? e : N(
516
+ // Additional classes
517
+ a,
518
+ // Base class
519
+ e,
520
+ // Modifier(s)
521
+ n ? sr(e, n) : null
522
+ );
599
523
  }
600
- var qe, Et;
601
- function On() {
602
- if (Et) return qe;
603
- Et = 1;
604
- var e = kn(), t = wn(), r = xn(), n = r && r.isTypedArray, a = n ? t(n) : e;
605
- return qe = a, qe;
524
+ function Lt(e, t, r, n) {
525
+ return Array.isArray(r) ? J(`${e}__${t}`, r) : J(`${e}__${t}`, r, n);
606
526
  }
607
- var Re, qt;
608
- function In() {
609
- if (qt) return Re;
610
- qt = 1;
611
- var e = ln(), t = _n(), r = Sn(), n = cr(), a = Nn(), o = jn(), s = rr(), i = On(), c = "[object Map]", u = "[object Set]", l = Object.prototype, f = l.hasOwnProperty;
612
- function p(h) {
613
- if (h == null)
614
- return !0;
615
- if (a(h) && (n(h) || typeof h == "string" || typeof h.splice == "function" || o(h) || i(h) || r(h)))
616
- return !h.length;
617
- var b = t(h);
618
- if (b == c || b == u)
619
- return !h.size;
620
- if (s(h))
621
- return !e(h).length;
622
- for (var y in h)
623
- if (f.call(h, y))
624
- return !1;
625
- return !0;
527
+ function j(e) {
528
+ function t(n, a) {
529
+ return Array.isArray(n) ? J(e, n) : J(e, n, a);
530
+ }
531
+ function r(n, a, o) {
532
+ return Array.isArray(a) ? Lt(e, n, a) : Lt(e, n, a, o);
626
533
  }
627
- return Re = p, Re;
534
+ return {
535
+ block: t,
536
+ element: r,
537
+ modifier: (n) => sr(e, n)
538
+ };
628
539
  }
629
- var $n = In();
630
- const Rt = /* @__PURE__ */ Ye($n);
631
- function Cn(e) {
632
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !We(e);
540
+ function Sn(e) {
541
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !X(e);
633
542
  }
634
- const Bn = (e) => {
543
+ const _n = (e) => {
635
544
  const {
636
545
  children: t,
637
546
  onClick: r,
@@ -647,29 +556,30 @@ const Bn = (e) => {
647
556
  disabled: a
648
557
  } : l = {
649
558
  tabIndex: a ? "-1" : i.tabIndex
650
- }, d(u, g(i, l, {
651
- "aria-disabled": c || void 0,
652
- onClick: (f) => {
559
+ }, f(u, g({
560
+ "aria-disabled": c || void 0
561
+ }, i, l, {
562
+ onClick: (d) => {
653
563
  if (c) {
654
- f.stopPropagation(), f.preventDefault();
564
+ d.stopPropagation(), d.preventDefault();
655
565
  return;
656
566
  }
657
- r?.(f);
567
+ r?.(d);
658
568
  }
659
- }), Cn(t) ? t : {
569
+ }), Sn(t) ? t : {
660
570
  default: () => [t]
661
571
  });
662
- }, En = "ButtonRoot", qn = "lumx-button-wrapper", {
663
- block: Rn
664
- } = k(qn), Mn = "lumx-button", {
665
- block: Ln
666
- } = k(Mn), Dn = (e) => {
572
+ }, Nn = "ButtonRoot", kn = "lumx-button-wrapper", {
573
+ block: Pn
574
+ } = j(kn), jn = "lumx-button", {
575
+ block: xn
576
+ } = j(jn), wn = (e) => {
667
577
  const {
668
578
  color: t,
669
579
  emphasis: r,
670
580
  variant: n,
671
581
  fullWidth: a
672
- } = e, o = r === $.low && (t === v.light ? v.dark : v.light), s = Rn({
582
+ } = e, o = r === q.low && (t === y.light ? y.dark : y.light), s = Pn({
673
583
  [`color-${o}`]: !!o,
674
584
  [`variant-${n}`]: !!n,
675
585
  "is-full-width": a
@@ -677,10 +587,10 @@ const Bn = (e) => {
677
587
  ...e,
678
588
  hasBackground: !1
679
589
  };
680
- return d("div", {
590
+ return f("div", {
681
591
  className: s
682
- }, [F(i)]);
683
- }, F = (e) => {
592
+ }, [V(i)]);
593
+ }, V = (e) => {
684
594
  const {
685
595
  "aria-label": t,
686
596
  "aria-disabled": r,
@@ -692,65 +602,65 @@ const Bn = (e) => {
692
602
  isSelected: c,
693
603
  isActive: u,
694
604
  isFocused: l,
695
- isHovered: f,
605
+ isHovered: d,
696
606
  linkAs: p,
697
607
  size: h,
698
- theme: b = K.light,
699
- variant: y,
700
- fullWidth: N,
701
- ref: E,
608
+ theme: b = Y.light,
609
+ variant: v,
610
+ fullWidth: _,
611
+ ref: x,
702
612
  ...T
703
- } = e, x = o || s !== $.high && b === K.dark && v.light || s === $.high && v.primary || v.dark;
613
+ } = e, w = o || s !== q.high && b === Y.dark && y.light || s === q.high && y.primary || y.dark;
704
614
  if (i)
705
- return Dn({
615
+ return wn({
706
616
  ...e,
707
- ref: E,
708
- variant: y,
709
- color: x
617
+ ref: x,
618
+ variant: v,
619
+ color: w
710
620
  });
711
- const q = S(a, Ln({
712
- [`color-${x}`]: !!x,
621
+ const M = N(a, xn({
622
+ [`color-${w}`]: !!w,
713
623
  [`emphasis-${s}`]: !!s,
714
624
  "is-selected": c,
715
625
  "is-disabled": !!(e.isDisabled || e["aria-disabled"]),
716
626
  "is-active": u,
717
627
  "is-focused": l,
718
- "is-hovered": f,
628
+ "is-hovered": d,
719
629
  [`size-${h}`]: !!h,
720
- [`theme-${b}`]: !!(s === $.high && b),
721
- [`variant-${y}`]: !!y,
722
- "is-full-width": N
630
+ [`theme-${b}`]: !!(s === q.high && b),
631
+ [`variant-${v}`]: !!v,
632
+ "is-full-width": _
723
633
  }));
724
- return Bn({
634
+ return _n({
725
635
  as: p || (T.href ? "a" : "button"),
726
636
  ...T,
727
637
  "aria-disabled": r,
728
638
  "aria-label": t,
729
- ref: E,
730
- className: q,
639
+ ref: x,
640
+ className: M,
731
641
  children: n
732
642
  });
733
643
  };
734
- F.displayName = En;
735
- F.defaultProps = {};
736
- const Fn = "Button", ur = "lumx-button", {
737
- modifier: Vn
738
- } = k(ur), De = {
739
- emphasis: $.high,
740
- size: j.m
741
- }, Q = (e) => {
644
+ V.displayName = Nn;
645
+ V.defaultProps = {};
646
+ const Cn = "Button", ir = "lumx-button", {
647
+ modifier: In
648
+ } = j(ir), Fe = {
649
+ emphasis: q.high,
650
+ size: C.m
651
+ }, ee = (e) => {
742
652
  const {
743
653
  className: t,
744
- emphasis: r = De.emphasis,
654
+ emphasis: r = Fe.emphasis,
745
655
  leftIcon: n,
746
656
  rightIcon: a,
747
- size: o = De.size,
657
+ size: o = Fe.size,
748
658
  ...s
749
- } = e, i = S(t, Vn({
659
+ } = e, i = N(t, In({
750
660
  "has-left-icon": !!n,
751
661
  "has-right-icon": !!a
752
662
  }));
753
- return F({
663
+ return V({
754
664
  emphasis: r,
755
665
  size: o,
756
666
  ...s,
@@ -758,17 +668,21 @@ const Fn = "Button", ur = "lumx-button", {
758
668
  variant: "button"
759
669
  });
760
670
  };
761
- Q.displayName = Fn;
762
- Q.className = ur;
763
- Q.defaultProps = De;
764
- const Gn = /* @__PURE__ */ Symbol("DISABLED_STATE_KEY");
765
- function zn() {
766
- return Ue(Gn, { state: null });
767
- }
768
- function fr(e) {
769
- const t = zn(), r = A(() => {
770
- const o = typeof e == "function" ? e() : W(e);
771
- return Dr(t, {
671
+ ee.displayName = Cn;
672
+ ee.className = ir;
673
+ ee.defaultProps = Fe;
674
+ function B(e = { defaultTheme: Pr.light }) {
675
+ const { defaultTheme: t } = e;
676
+ return ze("theme", void 0) || t;
677
+ }
678
+ const On = /* @__PURE__ */ Symbol("DISABLED_STATE_KEY");
679
+ function $n() {
680
+ return ze(On, { state: null });
681
+ }
682
+ function Je(e) {
683
+ const t = $n(), r = A(() => {
684
+ const o = typeof e == "function" ? e() : Ze(e);
685
+ return qr(t, {
772
686
  disabled: o.disabled,
773
687
  isDisabled: o.isDisabled,
774
688
  "aria-disabled": o["aria-disabled"] ?? o.ariaDisabled
@@ -776,19 +690,19 @@ function fr(e) {
776
690
  }), n = A(
777
691
  () => r.value["aria-disabled"] || r.value.disabled || void 0
778
692
  ), a = A(() => {
779
- const o = typeof e == "function" ? e() : W(e), { disabled: s, isDisabled: i, "aria-disabled": c, ariaDisabled: u, onClick: l, onChange: f, ...p } = o;
780
- return n.value || (l && (p.onClick = l), f && (p.onChange = f)), p;
693
+ const o = typeof e == "function" ? e() : Ze(e), { disabled: s, isDisabled: i, "aria-disabled": c, ariaDisabled: u, onClick: l, onChange: d, ...p } = o;
694
+ return n.value || (l && (p.onClick = l), d && (p.onChange = d)), p;
781
695
  });
782
696
  return { disabledStateProps: r, isAnyDisabled: n, otherProps: a };
783
697
  }
784
- const Mt = _({
698
+ const k = () => (...e) => e, Dt = S({
785
699
  name: "ResetTheme",
786
700
  setup(e, { slots: t }) {
787
- return Vt("theme", void 0), () => t.default?.();
701
+ return Wt("theme", void 0), () => t.default?.();
788
702
  }
789
- }), Un = "Icon", Wn = "lumx-icon", dr = Wn, {
790
- block: Hn
791
- } = k(dr), Kn = {}, B = (e) => {
703
+ }), En = "Icon", qn = "lumx-icon", cr = qn, {
704
+ block: Bn
705
+ } = j(cr), Mn = {}, E = (e) => {
792
706
  const {
793
707
  className: t,
794
708
  color: r,
@@ -800,28 +714,28 @@ const Mt = _({
800
714
  theme: c,
801
715
  alt: u,
802
716
  verticalAlign: l,
803
- ...f
804
- } = e, [p, h] = Jt(r, n);
717
+ ...d
718
+ } = e, [p, h] = ar(r, n);
805
719
  let b = p;
806
- !b && (a || c) && (b = c === K.dark ? v.light : v.dark);
807
- let y = h;
808
- !y && a && b === v.dark && (y = "L2");
809
- let N = s;
810
- return s && a ? s === j.xxs || s === j.xs ? N = j.s : s === j.xxl && (N = j.xl) : a && (N = j.m), d("i", g({
720
+ !b && (a || c) && (b = c === Y.dark ? y.light : y.dark);
721
+ let v = h;
722
+ !v && a && b === y.dark && (v = "L2");
723
+ let _ = s;
724
+ return s && a ? s === C.xxs || s === C.xs ? _ = C.s : s === C.xxl && (_ = C.xl) : a && (_ = C.m), f("i", g({
811
725
  ref: i
812
- }, f, {
813
- className: S(t, Hn({
726
+ }, d, {
727
+ className: N(t, Bn({
814
728
  [`color-${b}`]: !!b,
815
- [`color-variant-${y}`]: !!y,
729
+ [`color-variant-${v}`]: !!v,
816
730
  "has-shape": a,
817
731
  [`theme-${c}`]: !!c,
818
- [`size-${N}`]: !!N,
732
+ [`size-${_}`]: !!_,
819
733
  "no-shape": !a,
820
- "has-dark-layer": !a && b === v.yellow && o === Yt,
734
+ "has-dark-layer": !a && b === y.yellow && o === Yt,
821
735
  path: !0,
822
736
  "vertical-align-middle": l === "middle"
823
737
  }))
824
- }), [d("svg", {
738
+ }), [f("svg", {
825
739
  "aria-hidden": u ? void 0 : "true",
826
740
  role: u ? "img" : void 0,
827
741
  "aria-label": u,
@@ -832,19 +746,19 @@ const Mt = _({
832
746
  },
833
747
  viewBox: "0 0 24 24",
834
748
  width: "1em"
835
- }, [d("path", {
749
+ }, [f("path", {
836
750
  d: o,
837
751
  fill: "currentColor"
838
752
  }, null)])]);
839
753
  };
840
- B.displayName = Un;
841
- B.className = dr;
842
- B.defaultProps = Kn;
843
- const Fe = /* @__PURE__ */ _((e) => {
844
- const t = P(), r = C({
754
+ E.displayName = En;
755
+ E.className = cr;
756
+ E.defaultProps = Mn;
757
+ const Ve = /* @__PURE__ */ S((e) => {
758
+ const t = P(), r = B({
845
759
  defaultTheme: void 0
846
760
  });
847
- return () => d(B, g(e, t, {
761
+ return () => f(E, g(e, t, {
848
762
  className: e.class,
849
763
  theme: e.theme || r
850
764
  }), null);
@@ -852,10 +766,10 @@ const Fe = /* @__PURE__ */ _((e) => {
852
766
  name: "Icon",
853
767
  inheritAttrs: !1,
854
768
  // Redefine properties so that they come in as `props` on the `defineComponent` function
855
- props: w()("icon", "color", "colorVariant", "hasShape", "size", "alt", "verticalAlign", "theme", "class")
856
- }), pr = "lumx-text", {
857
- block: Yn
858
- } = k(pr), Jn = (e) => {
769
+ props: k()("icon", "color", "colorVariant", "hasShape", "size", "alt", "verticalAlign", "theme", "class")
770
+ }), Rn = "lumx-text", {
771
+ block: Ln
772
+ } = j(Rn), Dn = (e) => {
859
773
  const {
860
774
  className: t,
861
775
  color: r,
@@ -867,15 +781,15 @@ const Fe = /* @__PURE__ */ _((e) => {
867
781
  style: c
868
782
  } = e, u = typeof s == "object" && s.lines > 1 && {
869
783
  "--lumx-text-truncate-lines": s.lines
870
- }, l = !!u, f = !!s, p = !a && !(f && !l) && i && {
784
+ }, l = !!u, d = !!s, p = !a && !(d && !l) && i && {
871
785
  "--lumx-text-white-space": i
872
786
  };
873
787
  return {
874
- className: S(t, Yn({
875
- "is-truncated": f && !l,
788
+ className: N(t, Ln({
789
+ "is-truncated": d && !l,
876
790
  "is-truncated-multiline": l,
877
791
  "no-wrap": a
878
- }), o && Xt(o), r && Yr(r, n)),
792
+ }), o && or(o), r && Tn(r, n)),
879
793
  style: {
880
794
  ...u,
881
795
  ...p,
@@ -883,67 +797,67 @@ const Fe = /* @__PURE__ */ _((e) => {
883
797
  }
884
798
  };
885
799
  };
886
- function hr(e, t) {
887
- return wr() ? (xr(e, t), !0) : !1;
800
+ function lr(e, t) {
801
+ return jr() ? (xr(e, t), !0) : !1;
888
802
  }
889
- const Xn = typeof window < "u" && typeof document < "u";
803
+ const Fn = typeof window < "u" && typeof document < "u";
890
804
  typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
891
- const Qn = (e) => e != null;
892
- function Zn(e) {
805
+ const Vn = (e) => e != null;
806
+ function Gn(e) {
893
807
  return Array.isArray(e) ? e : [e];
894
808
  }
895
- const mr = Xn ? window : void 0;
896
- function Ve(e) {
809
+ const ur = Fn ? window : void 0;
810
+ function Ge(e) {
897
811
  var t;
898
- const r = Ke(e);
812
+ const r = He(e);
899
813
  return (t = r?.$el) !== null && t !== void 0 ? t : r;
900
814
  }
901
815
  // @__NO_SIDE_EFFECTS__
902
- function ea() {
903
- const e = Or(!1), t = Ir();
904
- return t && $r(() => {
816
+ function Un() {
817
+ const e = wr(!1), t = Cr();
818
+ return t && Ir(() => {
905
819
  e.value = !0;
906
820
  }, t), e;
907
821
  }
908
822
  // @__NO_SIDE_EFFECTS__
909
- function br(e) {
910
- const t = /* @__PURE__ */ ea();
823
+ function dr(e) {
824
+ const t = /* @__PURE__ */ Un();
911
825
  return A(() => (t.value, !!e()));
912
826
  }
913
- function ta(e, t, r = {}) {
914
- const { window: n = mr, ...a } = r;
827
+ function Wn(e, t, r = {}) {
828
+ const { window: n = ur, ...a } = r;
915
829
  let o;
916
- const s = /* @__PURE__ */ br(() => n && "MutationObserver" in n), i = () => {
830
+ const s = /* @__PURE__ */ dr(() => n && "MutationObserver" in n), i = () => {
917
831
  o && (o.disconnect(), o = void 0);
918
- }, c = He(A(() => {
919
- const f = Zn(Ke(e)).map(Ve).filter(Qn);
920
- return new Set(f);
921
- }), (f) => {
922
- i(), s.value && f.size && (o = new MutationObserver(t), f.forEach((p) => o.observe(p, a)));
832
+ }, c = Q(A(() => {
833
+ const d = Gn(He(e)).map(Ge).filter(Vn);
834
+ return new Set(d);
835
+ }), (d) => {
836
+ i(), s.value && d.size && (o = new MutationObserver(t), d.forEach((p) => o.observe(p, a)));
923
837
  }, {
924
838
  immediate: !0,
925
839
  flush: "post"
926
840
  }), u = () => o?.takeRecords(), l = () => {
927
841
  c(), i();
928
842
  };
929
- return hr(l), {
843
+ return lr(l), {
930
844
  isSupported: s,
931
845
  stop: l,
932
846
  takeRecords: u
933
847
  };
934
848
  }
935
- function ra(e, t, r = {}) {
936
- const { window: n = mr, ...a } = r;
849
+ function zn(e, t, r = {}) {
850
+ const { window: n = ur, ...a } = r;
937
851
  let o;
938
- const s = /* @__PURE__ */ br(() => n && "ResizeObserver" in n), i = () => {
852
+ const s = /* @__PURE__ */ dr(() => n && "ResizeObserver" in n), i = () => {
939
853
  o && (o.disconnect(), o = void 0);
940
- }, c = He(A(() => {
941
- const l = Ke(e);
942
- return Array.isArray(l) ? l.map((f) => Ve(f)) : [Ve(l)];
854
+ }, c = Q(A(() => {
855
+ const l = He(e);
856
+ return Array.isArray(l) ? l.map((d) => Ge(d)) : [Ge(l)];
943
857
  }), (l) => {
944
858
  if (i(), s.value && n) {
945
859
  o = new ResizeObserver(t);
946
- for (const f of l) f && o.observe(f, a);
860
+ for (const d of l) d && o.observe(d, a);
947
861
  }
948
862
  }, {
949
863
  immediate: !0,
@@ -951,121 +865,123 @@ function ra(e, t, r = {}) {
951
865
  }), u = () => {
952
866
  i(), c();
953
867
  };
954
- return hr(u), {
868
+ return lr(u), {
955
869
  isSupported: s,
956
870
  stop: u
957
871
  };
958
872
  }
959
- function na(e) {
960
- const t = Cr(void 0), r = () => {
873
+ function Hn(e) {
874
+ const t = zt(void 0), r = () => {
961
875
  const n = e.value;
962
- n && !n.closest(`.${Fr.visuallyHidden()}`) && n.offsetWidth < n.scrollWidth ? t.value = n.innerText : t.value = void 0;
876
+ n && !n.closest(`.${Br.visuallyHidden()}`) && n.offsetWidth < n.scrollWidth ? t.value = n.innerText : t.value = void 0;
963
877
  };
964
- return ta(e, r, {
878
+ return Wn(e, r, {
965
879
  childList: !0,
966
880
  attributes: !0,
967
881
  characterData: !0,
968
882
  subtree: !0
969
- }), ra(e, r), He(e, r, { immediate: !0 }), { tooltipLabel: t };
883
+ }), zn(e, r), Q(e, r, { immediate: !0 }), { tooltipLabel: t };
970
884
  }
971
- const aa = (e = "default") => {
972
- const t = Gt();
885
+ const Kn = (e = "default") => {
886
+ const t = Ht();
973
887
  return () => {
974
888
  const r = t?.[e];
975
889
  return r ? r() : null;
976
890
  };
977
891
  };
978
- function Ge(e) {
892
+ function Ue(e) {
979
893
  if (!e) return;
980
894
  const t = [];
981
895
  for (const r of e) {
982
- if (!We(r)) {
896
+ if (!X(r)) {
983
897
  t.push(r);
984
898
  continue;
985
899
  }
986
- if (r.type === Fe) {
900
+ if (r.type === Ve) {
987
901
  t.push(" "), t.push(r), t.push(" ");
988
902
  continue;
989
903
  }
990
- if (r.type === zt && Array.isArray(r.children)) {
991
- const n = Ge(r.children);
904
+ if (r.type === Kt && Array.isArray(r.children)) {
905
+ const n = Ue(r.children);
992
906
  n && t.push(...n);
993
907
  continue;
994
908
  }
995
909
  if (typeof r.type == "string" && Array.isArray(r.children)) {
996
- const n = Ge(r.children), a = { ...r.props || {} };
997
- r.key != null && (a.key = r.key), r.ref != null && (a.ref = r.ref), t.push(d(r.type, a, n));
910
+ const n = Ue(r.children), a = { ...r.props || {} };
911
+ r.key != null && (a.key = r.key), r.ref != null && (a.ref = r.ref), t.push(f(r.type, a, n));
998
912
  continue;
999
913
  }
1000
914
  t.push(r);
1001
915
  }
1002
916
  return t;
1003
917
  }
1004
- const Z = /* @__PURE__ */ _({
918
+ function Yn(e) {
919
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !X(e);
920
+ }
921
+ const Xe = /* @__PURE__ */ S((e, {
922
+ slots: t
923
+ }) => {
924
+ const r = P(), n = Kn(), a = Or("tooltip-label"), {
925
+ tooltipLabel: o
926
+ } = Hn(a), s = A(() => Dn({
927
+ ...e,
928
+ className: e.class || r.class || r.className
929
+ })), i = A(() => {
930
+ const {
931
+ children: c,
932
+ ...u
933
+ } = r;
934
+ return {
935
+ ...u,
936
+ ...s.value
937
+ };
938
+ });
939
+ return () => {
940
+ const c = e.as || "div", u = n() || t.default?.(), l = u ? Ue(u) : null;
941
+ return f(c, g({
942
+ ref: "tooltip-label"
943
+ }, i.value, {
944
+ class: i.value.className,
945
+ style: i.value.style,
946
+ title: o.value
947
+ }), Yn(l) ? l : {
948
+ default: () => [l]
949
+ });
950
+ };
951
+ }, {
952
+ name: "LumxText",
1005
953
  inheritAttrs: !1,
1006
- __name: "Text",
1007
- props: {
1008
- color: {},
1009
- colorVariant: {},
1010
- typography: {},
1011
- as: {},
1012
- truncate: { type: [Boolean, Object] },
1013
- noWrap: { type: Boolean },
1014
- whiteSpace: {},
1015
- children: {},
1016
- style: {},
1017
- className: {}
1018
- },
1019
- setup(e) {
1020
- const t = e, r = P(), n = aa(), a = Br("tooltip-label"), { tooltipLabel: o } = na(a), s = A(
1021
- () => Jn({
1022
- ...t,
1023
- className: t.className || r.class
1024
- })
1025
- ), i = () => {
1026
- const u = n();
1027
- return u ? Ge(u) : null;
1028
- }, c = A(() => ({ ...r, ...s.value }));
1029
- return (u, l) => (Ut(), Wt(Er(t.as), g({ ref: "tooltip-label" }, c.value, {
1030
- class: c.value.className,
1031
- style: c.value.style,
1032
- title: W(o)
1033
- }), {
1034
- default: Ht(() => [
1035
- d(i)
1036
- ]),
1037
- _: 1
1038
- }, 16, ["class", "style", "title"]));
1039
- }
1040
- }), oa = {
954
+ // Redefine properties so that they come in as `props` on the `defineComponent` function
955
+ props: k()("as", "color", "colorVariant", "typography", "truncate", "noWrap", "whiteSpace", "style", "class")
956
+ }), Jn = {
1041
957
  click: (e) => e instanceof MouseEvent
1042
- }, Da = /* @__PURE__ */ _((e, {
958
+ }, Ua = /* @__PURE__ */ S((e, {
1043
959
  emit: t
1044
960
  }) => {
1045
- const r = Gt(), n = P(), a = C(), {
961
+ const r = Ht(), n = P(), a = B(), {
1046
962
  isAnyDisabled: o,
1047
963
  disabledStateProps: s,
1048
964
  otherProps: i
1049
- } = fr(A(() => ({
965
+ } = Je(A(() => ({
1050
966
  ...e,
1051
967
  ...n
1052
968
  }))), c = (l) => {
1053
969
  o.value || (l.stopImmediatePropagation(), t("click", l));
1054
970
  }, u = () => {
1055
971
  const l = r.default?.();
1056
- return !l || l.length === 0 ? null : l.length === 1 && l[0].type === Z ? l[0] : d("span", null, [l]);
972
+ return !l || l.length === 0 ? null : l.length === 1 && l[0].type === Xe ? l[0] : f("span", null, [l]);
1057
973
  };
1058
974
  return () => {
1059
- const l = d(zt, null, [e.leftIcon && !Rt(e.leftIcon) && d(Mt, null, {
1060
- default: () => [d(Fe, {
975
+ const l = f(Kt, null, [e.leftIcon && !Mt(e.leftIcon) && f(Dt, null, {
976
+ default: () => [f(Ve, {
1061
977
  icon: e.leftIcon
1062
978
  }, null)]
1063
- }), u(), e.rightIcon && !Rt(e.rightIcon) && d(Mt, null, {
1064
- default: () => [d(Fe, {
979
+ }), u(), e.rightIcon && !Mt(e.rightIcon) && f(Dt, null, {
980
+ default: () => [f(Ve, {
1065
981
  icon: e.rightIcon
1066
982
  }, null)]
1067
983
  })]);
1068
- return d(Q, g(i.value, s.value, {
984
+ return f(ee, g(i.value, s.value, {
1069
985
  className: e.class,
1070
986
  theme: e.theme || a,
1071
987
  onClick: c,
@@ -1076,26 +992,26 @@ const Z = /* @__PURE__ */ _({
1076
992
  name: "LumxButton",
1077
993
  inheritAttrs: !1,
1078
994
  // Redefine properties so that they come in as `props` on the `defineComponent` function
1079
- props: w()("leftIcon", "rightIcon", "color", "emphasis", "hasBackground", "href", "isDisabled", "isSelected", "name", "size", "theme", "class", "aria-expanded", "aria-disabled", "aria-haspopup", "aria-label", "aria-pressed", "disabled", "fullWidth", "isActive", "isFocused", "isHovered", "linkAs", "target", "type"),
1080
- emits: oa
1081
- }), sa = "IconButton", ia = "lumx-icon-button", ze = {
1082
- emphasis: $.high,
1083
- size: j.m
1084
- }, V = (e) => {
995
+ props: k()("leftIcon", "rightIcon", "color", "emphasis", "hasBackground", "href", "isDisabled", "isSelected", "name", "size", "theme", "class", "aria-expanded", "aria-disabled", "aria-haspopup", "aria-label", "aria-pressed", "disabled", "fullWidth", "isActive", "isFocused", "isHovered", "linkAs", "target", "type"),
996
+ emits: Jn
997
+ }), Xn = "IconButton", Qn = "lumx-icon-button", We = {
998
+ emphasis: q.high,
999
+ size: C.m
1000
+ }, G = (e) => {
1085
1001
  const {
1086
- emphasis: t = ze.emphasis,
1002
+ emphasis: t = We.emphasis,
1087
1003
  image: r,
1088
1004
  icon: n,
1089
1005
  label: a,
1090
- size: o = ze.size,
1006
+ size: o = We.size,
1091
1007
  ...s
1092
- } = e, i = r ? d("img", {
1008
+ } = e, i = r ? f("img", {
1093
1009
  alt: "",
1094
1010
  src: r
1095
- }, null) : B({
1011
+ }, null) : E({
1096
1012
  icon: n
1097
1013
  });
1098
- return F({
1014
+ return V({
1099
1015
  emphasis: t,
1100
1016
  size: o,
1101
1017
  ...s,
@@ -1104,25 +1020,25 @@ const Z = /* @__PURE__ */ _({
1104
1020
  children: i
1105
1021
  });
1106
1022
  };
1107
- V.displayName = sa;
1108
- V.className = ia;
1109
- V.defaultProps = ze;
1110
- const ca = {
1023
+ G.displayName = Xn;
1024
+ G.className = Qn;
1025
+ G.defaultProps = We;
1026
+ const Zn = {
1111
1027
  click: (e) => e instanceof MouseEvent
1112
- }, Fa = /* @__PURE__ */ _((e, {
1028
+ }, Wa = /* @__PURE__ */ S((e, {
1113
1029
  emit: t
1114
1030
  }) => {
1115
- const r = P(), n = C(), {
1031
+ const r = P(), n = B(), {
1116
1032
  isAnyDisabled: a,
1117
1033
  disabledStateProps: o,
1118
1034
  otherProps: s
1119
- } = fr(A(() => ({
1035
+ } = Je(A(() => ({
1120
1036
  ...e,
1121
1037
  ...r
1122
1038
  }))), i = (c) => {
1123
1039
  a.value || (c.stopImmediatePropagation(), t("click", c));
1124
1040
  };
1125
- return () => d(V, g(s.value, o.value, {
1041
+ return () => f(G, g(s.value, o.value, {
1126
1042
  className: e.class,
1127
1043
  theme: e.theme || n,
1128
1044
  title: e.label,
@@ -1132,26 +1048,26 @@ const ca = {
1132
1048
  name: "IconButton",
1133
1049
  inheritAttrs: !1,
1134
1050
  // Redefine properties so that they come in as `props` on the `defineComponent` function
1135
- props: w()("icon", "image", "label", "color", "emphasis", "hasBackground", "href", "isDisabled", "isSelected", "name", "size", "theme", "class", "aria-expanded", "aria-disabled", "aria-haspopup", "aria-label", "aria-pressed", "disabled", "fullWidth", "isActive", "isFocused", "isHovered", "isDisabled", "linkAs", "target", "type", "title"),
1136
- emits: ca
1137
- }), la = "ButtonGroup", vr = "lumx-button-group", ua = {}, ee = (e) => {
1051
+ props: k()("icon", "image", "label", "color", "emphasis", "hasBackground", "href", "isDisabled", "isSelected", "name", "size", "theme", "class", "aria-expanded", "aria-disabled", "aria-haspopup", "aria-label", "aria-pressed", "disabled", "fullWidth", "isActive", "isFocused", "isHovered", "isDisabled", "linkAs", "target", "type", "title"),
1052
+ emits: Zn
1053
+ }), ea = "ButtonGroup", fr = "lumx-button-group", ta = {}, te = (e) => {
1138
1054
  const {
1139
1055
  children: t,
1140
1056
  className: r,
1141
1057
  ...n
1142
1058
  } = e;
1143
- return d("div", g(n, {
1144
- className: S(r, vr)
1059
+ return f("div", g(n, {
1060
+ className: N(r, fr)
1145
1061
  }), [t]);
1146
1062
  };
1147
- ee.displayName = la;
1148
- ee.className = vr;
1149
- ee.defaultProps = ua;
1150
- const Va = /* @__PURE__ */ _((e, {
1063
+ te.displayName = ea;
1064
+ te.className = fr;
1065
+ te.defaultProps = ta;
1066
+ const za = /* @__PURE__ */ S((e, {
1151
1067
  slots: t
1152
1068
  }) => {
1153
1069
  const r = P();
1154
- return () => d(ee, g(e, r, {
1070
+ return () => f(te, g(e, r, {
1155
1071
  className: e.class,
1156
1072
  children: t.default?.()
1157
1073
  }), null);
@@ -1159,167 +1075,192 @@ const Va = /* @__PURE__ */ _((e, {
1159
1075
  name: "ButtonGroup",
1160
1076
  inheritAttrs: !1,
1161
1077
  // Redefine properties so that they come in as `props` on the `defineComponent` function
1162
- props: w()("class")
1163
- });
1164
- Z.className = pr;
1165
- const Lt = 6, fa = {
1166
- h1: R.display1,
1167
- h2: R.headline,
1168
- h3: R.title,
1169
- h4: R.subtitle2,
1170
- h5: R.subtitle1,
1171
- h6: R.body2
1172
- }, da = { level: 1, headingElement: "h1" }, pa = "lumx-heading", ha = (e, t) => {
1173
- const { as: r, className: n, typography: a, ...o } = e, s = r || t || "h1";
1174
- return {
1175
- ...o,
1176
- as: s,
1177
- className: S(n, pa),
1178
- typography: a || fa[s]
1179
- };
1180
- }, gr = /* @__PURE__ */ Symbol("HeadingLevelContext"), yr = () => Ue(gr, da), Ga = /* @__PURE__ */ _({
1181
- inheritAttrs: !1,
1182
- __name: "Heading",
1183
- props: {
1184
- as: {},
1185
- color: {},
1186
- colorVariant: {},
1187
- typography: {},
1188
- truncate: { type: [Boolean, Object] },
1189
- noWrap: { type: Boolean },
1190
- whiteSpace: {},
1191
- children: {},
1192
- style: {},
1193
- className: {}
1194
- },
1195
- setup(e) {
1196
- const t = e, r = P(), n = C(), a = yr(), o = A(() => {
1197
- const { className: s, ...i } = ha(
1198
- {
1199
- ...r,
1200
- ...t,
1201
- className: r.class
1202
- },
1203
- a.headingElement
1204
- );
1205
- return {
1206
- ...i,
1207
- class: s,
1208
- theme: t.theme || r.theme || n
1209
- };
1210
- });
1211
- return (s, i) => (Ut(), Wt(W(Z), qr(Rr(o.value)), {
1212
- default: Ht(() => [
1213
- Kt(s.$slots, "default")
1214
- ]),
1215
- _: 3
1216
- }, 16));
1217
- }
1218
- }), ma = (e, t) => {
1219
- const r = e || t + 1;
1220
- return r > Lt ? Lt : r;
1221
- }, za = /* @__PURE__ */ _({
1222
- name: "HeadingLevelProvider",
1223
- __name: "HeadingLevelProvider",
1224
- props: {
1225
- level: {}
1226
- },
1227
- setup(e) {
1228
- const t = e, { level: r } = Mr(t), n = yr(), a = A(() => ma(r?.value, n.level)), o = A(() => `h${a.value}`), s = Lr({
1229
- level: a,
1230
- headingElement: o
1231
- });
1232
- return Vt(gr, s), (i, c) => Kt(i.$slots, "default");
1233
- }
1234
- }), ba = "Message", Ar = "lumx-message", {
1235
- block: va,
1236
- element: Me
1237
- } = k(Ar), ga = {
1238
- [O.error]: {
1239
- color: v.red,
1240
- icon: Vr
1241
- },
1242
- [O.info]: {
1243
- color: v.blue,
1244
- icon: Ur
1245
- },
1246
- [O.success]: {
1247
- color: v.green,
1248
- icon: Gr
1249
- },
1250
- [O.warning]: {
1251
- color: v.yellow,
1252
- icon: Yt
1253
- }
1254
- }, Xe = (e) => {
1078
+ props: k()("class")
1079
+ }), ra = "InputLabel", na = "lumx-input-label", pr = na, {
1080
+ block: aa
1081
+ } = j(pr), oa = {};
1082
+ function U(e) {
1255
1083
  const {
1256
1084
  children: t,
1257
1085
  className: r,
1258
- hasBackground: n,
1259
- kind: a,
1260
- icon: o,
1261
- closeButtonProps: s,
1086
+ htmlFor: n,
1087
+ isRequired: a,
1088
+ theme: o,
1089
+ typography: s,
1262
1090
  ref: i,
1263
1091
  ...c
1092
+ } = e;
1093
+ return f("label", g({
1094
+ ref: i
1095
+ }, c, {
1096
+ htmlFor: n,
1097
+ className: N(r, aa({
1098
+ "is-required": a,
1099
+ [`theme-${o}`]: !!o,
1100
+ "has-custom-typography": !!s
1101
+ }), s && or(s))
1102
+ }), [t]);
1103
+ }
1104
+ U.displayName = ra;
1105
+ U.className = pr;
1106
+ U.defaultProps = oa;
1107
+ const sa = {
1108
+ [O.error]: { color: "red" },
1109
+ [O.success]: { color: "green" },
1110
+ [O.warning]: { color: "yellow" }
1111
+ }, ia = "InputHelper", ca = "lumx-input-helper", hr = ca, {
1112
+ block: la
1113
+ } = j(hr), mr = {
1114
+ kind: O.info
1115
+ };
1116
+ function W(e) {
1117
+ const {
1118
+ children: t,
1119
+ className: r,
1120
+ kind: n = mr.kind,
1121
+ theme: a,
1122
+ ref: o,
1123
+ ...s
1264
1124
  } = e, {
1265
- color: u,
1266
- icon: l
1267
- } = ga[a] || {}, {
1268
- onClick: f,
1269
- label: p
1270
- } = s || {}, h = n && a === "info" && f && p;
1271
- return d("div", g(c, {
1272
- ref: i,
1273
- className: S(r, va({
1274
- [`color-${u}`]: !!u,
1275
- "has-background": n
1125
+ color: i
1126
+ } = sa[n] || {};
1127
+ return f("p", g({
1128
+ ref: o
1129
+ }, s, {
1130
+ className: N(r, la({
1131
+ [`color-${i}`]: !!i,
1132
+ [`theme-${a}`]: !!a
1276
1133
  }))
1277
- }), [(o || l) && B({
1278
- className: Me("icon"),
1279
- icon: o || l,
1280
- size: j.xs,
1281
- color: u
1282
- }), d("div", {
1283
- className: Me("text")
1284
- }, [t]), h && V({
1285
- className: Me("close-button"),
1286
- icon: zr,
1287
- onClick: f,
1288
- label: p,
1289
- emphasis: $.low
1290
- })]);
1134
+ }), [t]);
1135
+ }
1136
+ W.displayName = ia;
1137
+ W.className = hr;
1138
+ W.defaultProps = mr;
1139
+ const br = "intermediate", ua = "lumx-checkbox", {
1140
+ block: da,
1141
+ element: I
1142
+ } = j(ua), fa = (e) => {
1143
+ const {
1144
+ checked: t,
1145
+ className: r,
1146
+ helper: n,
1147
+ id: a,
1148
+ inputRef: o,
1149
+ isChecked: s = t,
1150
+ label: i,
1151
+ name: c,
1152
+ ref: u,
1153
+ onChange: l,
1154
+ theme: d,
1155
+ value: p,
1156
+ inputProps: h = {},
1157
+ isDisabled: b,
1158
+ inputId: v,
1159
+ ..._
1160
+ } = e, x = s === br, T = (w) => {
1161
+ l && l(!s, p, c, w);
1162
+ };
1163
+ return f("div", g({
1164
+ ref: u
1165
+ }, _, {
1166
+ className: N(r, da({
1167
+ // Whether state is intermediate class name will "-checked"
1168
+ "is-checked": x ? !0 : s,
1169
+ "is-disabled": b,
1170
+ "is-unchecked": !s,
1171
+ [`theme-${d}`]: !!d
1172
+ }))
1173
+ }), [f("div", {
1174
+ className: I("input-wrapper")
1175
+ }, [f("input", g({
1176
+ ref: o,
1177
+ type: "checkbox",
1178
+ id: v,
1179
+ className: I("input-native"),
1180
+ name: c,
1181
+ value: p,
1182
+ checked: s,
1183
+ onChange: T,
1184
+ "aria-describedby": n ? `${v}-helper` : void 0,
1185
+ "aria-checked": x ? "mixed" : !!s
1186
+ }, h?.readOnly ? {
1187
+ readOnly: h.readOnly
1188
+ } : {}, h), null), f("div", {
1189
+ className: I("input-placeholder")
1190
+ }, [f("div", {
1191
+ className: I("input-background")
1192
+ }, null), f("div", {
1193
+ className: I("input-indicator")
1194
+ }, [E({
1195
+ icon: x ? Rr : Mr
1196
+ })])])]), f("div", {
1197
+ className: I("content")
1198
+ }, [i && U({
1199
+ htmlFor: v,
1200
+ className: I("label"),
1201
+ theme: d,
1202
+ children: i
1203
+ }), n && W({
1204
+ id: `${v}-helper`,
1205
+ className: I("helper"),
1206
+ theme: d,
1207
+ children: n
1208
+ })])]);
1291
1209
  };
1292
- Xe.displayName = ba;
1293
- Xe.className = Ar;
1294
- const Ua = /* @__PURE__ */ _((e, {
1295
- slots: t,
1296
- emit: r
1210
+ let Ft = 0;
1211
+ function pa() {
1212
+ return Ft += 1, `:lumx${Ft}:`;
1213
+ }
1214
+ const ha = {
1215
+ change: (e, t, r, n) => typeof e == "boolean" && n instanceof Event
1216
+ }, Ha = /* @__PURE__ */ S((e, {
1217
+ emit: t
1297
1218
  }) => {
1298
- const n = P(), {
1299
- closeButtonLabel: a
1300
- } = e;
1301
- return () => d(Xe, g(e, n, {
1219
+ const r = P(), n = B(), a = pa(), o = A(() => e.id || a), s = zt(null), {
1220
+ isAnyDisabled: i,
1221
+ disabledStateProps: c,
1222
+ otherProps: u
1223
+ } = Je(A(() => ({
1224
+ ...e,
1225
+ ...r
1226
+ }))), l = A(() => e.isChecked === br);
1227
+ Q(l, (p) => {
1228
+ s.value && (s.value.indeterminate = p);
1229
+ }, {
1230
+ immediate: !0
1231
+ });
1232
+ const d = (p, h, b, v) => {
1233
+ i.value || t("change", p, h, b, v);
1234
+ };
1235
+ return () => fa({
1236
+ ...u.value,
1302
1237
  className: e.class,
1303
- children: t.default?.(),
1304
- closeButtonProps: a ? {
1305
- label: a,
1306
- onClick: () => r("close")
1307
- } : void 0
1308
- }), null);
1238
+ theme: e.theme || n,
1239
+ inputId: o.value,
1240
+ inputRef: s,
1241
+ isDisabled: i.value,
1242
+ onChange: d,
1243
+ label: e.label,
1244
+ inputProps: {
1245
+ ...e.inputProps,
1246
+ ...c.value,
1247
+ readOnly: c.value["aria-disabled"]
1248
+ }
1249
+ });
1309
1250
  }, {
1310
- name: "Message",
1251
+ name: "Checkbox",
1311
1252
  inheritAttrs: !1,
1312
1253
  // Redefine properties so that they come in as `props` on the `defineComponent` function
1313
- props: w()("hasBackground", "icon", "kind", "class", "closeButtonLabel"),
1314
- emits: ["close"]
1254
+ props: k()("checked", "class", "helper", "id", "inputProps", "isChecked", "isDisabled", "label", "name", "theme", "value", "aria-disabled"),
1255
+ emits: ha
1315
1256
  });
1316
- function ya(e) {
1317
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !We(e);
1257
+ function ma(e) {
1258
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !X(e);
1318
1259
  }
1319
- const Aa = "lumx-flag", {
1320
- block: _a,
1321
- element: Dt
1322
- } = k(Aa), Ta = (e) => {
1260
+ const ba = "lumx-flag", {
1261
+ block: va,
1262
+ element: Vt
1263
+ } = j(ba), ga = (e) => {
1323
1264
  const {
1324
1265
  children: t,
1325
1266
  icon: r,
@@ -1329,45 +1270,45 @@ const Aa = "lumx-flag", {
1329
1270
  truncate: s,
1330
1271
  Text: i,
1331
1272
  ...c
1332
- } = e, u = n || (o === K.light ? v.dark : v.light), l = !!s;
1333
- return d("div", g(c, {
1334
- className: S(a, _a({
1273
+ } = e, u = n || (o === Y.light ? y.dark : y.light), l = !!s;
1274
+ return f("div", g(c, {
1275
+ className: N(a, va({
1335
1276
  [`color-${u}`]: !!u,
1336
1277
  "is-truncated": l
1337
1278
  }))
1338
- }), [r && B({
1279
+ }), [r && E({
1339
1280
  icon: r,
1340
- size: j.xxs,
1341
- className: Dt("icon")
1342
- }), d(i, {
1281
+ size: C.xxs,
1282
+ className: Vt("icon")
1283
+ }), f(i, {
1343
1284
  as: "span",
1344
1285
  truncate: !!s,
1345
1286
  typography: "overline",
1346
- className: Dt("label")
1347
- }, ya(t) ? t : {
1287
+ className: Vt("label")
1288
+ }, ma(t) ? t : {
1348
1289
  default: () => [t]
1349
1290
  })]);
1350
- }, Wa = /* @__PURE__ */ _((e, {
1291
+ }, Ka = /* @__PURE__ */ S((e, {
1351
1292
  slots: t
1352
1293
  }) => {
1353
- const r = P(), n = C();
1354
- return () => d(Ta, g(e, r, {
1294
+ const r = P(), n = B();
1295
+ return () => f(ga, g(e, r, {
1355
1296
  className: e.class,
1356
1297
  theme: e.theme || n,
1357
1298
  children: t.default?.(),
1358
- Text: Z
1299
+ Text: Xe
1359
1300
  }), null);
1360
1301
  }, {
1361
1302
  name: "Flag",
1362
1303
  inheritAttrs: !1,
1363
1304
  // Redefine properties so that they come in as `props` on the `defineComponent` function
1364
- props: w()("color", "icon", "truncate", "theme", "class")
1305
+ props: k()("color", "icon", "truncate", "theme", "class")
1365
1306
  });
1366
- var Le, Ft;
1367
- function Sa() {
1368
- if (Ft) return Le;
1369
- Ft = 1;
1370
- var e = cr();
1307
+ var Le, Gt;
1308
+ function ya() {
1309
+ if (Gt) return Le;
1310
+ Gt = 1;
1311
+ var e = rr();
1371
1312
  function t() {
1372
1313
  if (!arguments.length)
1373
1314
  return [];
@@ -1376,11 +1317,11 @@ function Sa() {
1376
1317
  }
1377
1318
  return Le = t, Le;
1378
1319
  }
1379
- var Na = Sa();
1380
- const Pa = /* @__PURE__ */ Ye(Na), ja = "lumx-flex-box", {
1381
- block: ka
1382
- } = k(ja);
1383
- function wa(e) {
1320
+ var Aa = ya();
1321
+ const Ta = /* @__PURE__ */ Ke(Aa), Sa = "lumx-flex-box", {
1322
+ block: _a
1323
+ } = j(Sa);
1324
+ function Na(e) {
1384
1325
  const {
1385
1326
  className: t,
1386
1327
  fillSpace: r,
@@ -1392,32 +1333,32 @@ function wa(e) {
1392
1333
  wrap: c,
1393
1334
  orientation: u,
1394
1335
  ...l
1395
- } = e, f = u ?? (c || a || i ? Jr.horizontal : null);
1336
+ } = e, d = u ?? (c || a || i ? bn.horizontal : null);
1396
1337
  return {
1397
1338
  ...l,
1398
- className: S(t, ka({
1399
- [`orientation-${f}`]: !!f,
1339
+ className: N(t, _a({
1340
+ [`orientation-${d}`]: !!d,
1400
1341
  [`v-align-${i}`]: !!i,
1401
1342
  [`h-align-${a}`]: !!a,
1402
1343
  [`gap-${n}`]: !!n,
1403
1344
  wrap: !!c,
1404
1345
  "fill-space": r,
1405
1346
  "no-shrink": s,
1406
- ...Object.fromEntries(Pa(o).filter(Boolean).map((p) => [`margin-auto-${p}`, !0]))
1347
+ ...Object.fromEntries(Ta(o).filter(Boolean).map((p) => [`margin-auto-${p}`, !0]))
1407
1348
  }))
1408
1349
  };
1409
1350
  }
1410
- const Ha = /* @__PURE__ */ _((e, {
1351
+ const Ya = /* @__PURE__ */ S((e, {
1411
1352
  slots: t
1412
1353
  }) => {
1413
1354
  const r = P();
1414
1355
  return () => {
1415
- const n = e.as || "div", a = wa({
1356
+ const n = e.as || "div", a = Na({
1416
1357
  ...e,
1417
1358
  ...r,
1418
1359
  className: e.class
1419
1360
  });
1420
- return d(n, a, {
1361
+ return f(n, a, {
1421
1362
  default: () => [t.default?.()]
1422
1363
  });
1423
1364
  };
@@ -1425,21 +1366,187 @@ const Ha = /* @__PURE__ */ _((e, {
1425
1366
  name: "FlexBox",
1426
1367
  inheritAttrs: !1,
1427
1368
  // Redefine properties so that they come in as `props` on the `defineComponent` function
1428
- props: w()("as", "fillSpace", "gap", "hAlign", "marginAuto", "noShrink", "orientation", "vAlign", "wrap", "class")
1369
+ props: k()("as", "fillSpace", "gap", "hAlign", "marginAuto", "noShrink", "orientation", "vAlign", "wrap", "class")
1370
+ }), Ut = 6, ka = {
1371
+ h1: R.display1,
1372
+ h2: R.headline,
1373
+ h3: R.title,
1374
+ h4: R.subtitle2,
1375
+ h5: R.subtitle1,
1376
+ h6: R.body2
1377
+ }, Pa = { level: 1, headingElement: "h1" }, ja = "lumx-heading", xa = (e, t) => {
1378
+ const { as: r, className: n, typography: a, ...o } = e, s = r || t || "h1";
1379
+ return {
1380
+ ...o,
1381
+ as: s,
1382
+ className: N(n, ja),
1383
+ typography: a || ka[s]
1384
+ };
1385
+ }, vr = /* @__PURE__ */ Symbol("HeadingLevelContext"), gr = () => ze(vr, Pa), Ja = /* @__PURE__ */ S((e, {
1386
+ slots: t
1387
+ }) => {
1388
+ const r = P(), n = gr(), a = A(() => {
1389
+ const {
1390
+ className: o,
1391
+ ...s
1392
+ } = xa({
1393
+ ...r,
1394
+ ...e,
1395
+ className: e.class || r.class || r.className
1396
+ }, n.headingElement);
1397
+ return {
1398
+ ...s,
1399
+ class: o
1400
+ };
1401
+ });
1402
+ return () => f(Xe, a.value, {
1403
+ default: () => [t.default?.()]
1404
+ });
1405
+ }, {
1406
+ name: "Heading",
1407
+ inheritAttrs: !1,
1408
+ // Redefine properties so that they come in as `props` on the `defineComponent` function
1409
+ props: k()("as", "color", "colorVariant", "typography", "truncate", "noWrap", "whiteSpace", "style", "class")
1410
+ }), wa = (e, t) => {
1411
+ const r = e || t + 1;
1412
+ return r > Ut ? Ut : r;
1413
+ }, Xa = /* @__PURE__ */ S((e, {
1414
+ slots: t
1415
+ }) => {
1416
+ const {
1417
+ level: r
1418
+ } = $r(e), n = gr(), a = A(() => wa(r?.value, n.level)), o = A(() => `h${a.value}`), s = Er({
1419
+ level: a,
1420
+ headingElement: o
1421
+ });
1422
+ return Wt(vr, s), () => t.default?.();
1423
+ }, {
1424
+ name: "HeadingLevelProvider",
1425
+ props: k()("level")
1426
+ }), Qa = /* @__PURE__ */ S((e, {
1427
+ slots: t
1428
+ }) => {
1429
+ const r = P(), n = B();
1430
+ return () => f(W, g(e, r, {
1431
+ className: e.class,
1432
+ theme: e.theme || n,
1433
+ children: t.default?.()
1434
+ }), null);
1435
+ }, {
1436
+ name: "InputHelper",
1437
+ inheritAttrs: !1,
1438
+ // Redefine properties so that they come in as `props` on the `defineComponent` function
1439
+ props: k()("kind", "theme", "class", "id")
1440
+ }), Za = /* @__PURE__ */ S((e, {
1441
+ slots: t
1442
+ }) => {
1443
+ const r = P(), n = B();
1444
+ return () => f(U, g(e, r, {
1445
+ className: e.class,
1446
+ theme: e.theme || n,
1447
+ children: t.default?.()
1448
+ }), null);
1449
+ }, {
1450
+ name: "InputLabel",
1451
+ inheritAttrs: !1,
1452
+ // Redefine properties so that they come in as `props` on the `defineComponent` function
1453
+ props: k()("htmlFor", "isRequired", "typography", "theme", "class")
1454
+ }), Ca = "Message", yr = "lumx-message", {
1455
+ block: Ia,
1456
+ element: De
1457
+ } = j(yr), Oa = {
1458
+ [O.error]: {
1459
+ color: y.red,
1460
+ icon: Lr
1461
+ },
1462
+ [O.info]: {
1463
+ color: y.blue,
1464
+ icon: Vr
1465
+ },
1466
+ [O.success]: {
1467
+ color: y.green,
1468
+ icon: Dr
1469
+ },
1470
+ [O.warning]: {
1471
+ color: y.yellow,
1472
+ icon: Yt
1473
+ }
1474
+ }, Qe = (e) => {
1475
+ const {
1476
+ children: t,
1477
+ className: r,
1478
+ hasBackground: n,
1479
+ kind: a,
1480
+ icon: o,
1481
+ closeButtonProps: s,
1482
+ ref: i,
1483
+ ...c
1484
+ } = e, {
1485
+ color: u,
1486
+ icon: l
1487
+ } = Oa[a] || {}, {
1488
+ onClick: d,
1489
+ label: p
1490
+ } = s || {}, h = n && a === "info" && d && p;
1491
+ return f("div", g(c, {
1492
+ ref: i,
1493
+ className: N(r, Ia({
1494
+ [`color-${u}`]: !!u,
1495
+ "has-background": n
1496
+ }))
1497
+ }), [(o || l) && E({
1498
+ className: De("icon"),
1499
+ icon: o || l,
1500
+ size: C.xs,
1501
+ color: u
1502
+ }), f("div", {
1503
+ className: De("text")
1504
+ }, [t]), h && G({
1505
+ className: De("close-button"),
1506
+ icon: Fr,
1507
+ onClick: d,
1508
+ label: p,
1509
+ emphasis: q.low
1510
+ })]);
1511
+ };
1512
+ Qe.displayName = Ca;
1513
+ Qe.className = yr;
1514
+ const eo = /* @__PURE__ */ S((e, {
1515
+ slots: t,
1516
+ emit: r
1517
+ }) => {
1518
+ const n = P(), {
1519
+ closeButtonLabel: a
1520
+ } = e;
1521
+ return () => f(Qe, g(e, n, {
1522
+ className: e.class,
1523
+ children: t.default?.(),
1524
+ closeButtonProps: a ? {
1525
+ label: a,
1526
+ onClick: () => r("close")
1527
+ } : void 0
1528
+ }), null);
1529
+ }, {
1530
+ name: "Message",
1531
+ inheritAttrs: !1,
1532
+ // Redefine properties so that they come in as `props` on the `defineComponent` function
1533
+ props: k()("hasBackground", "icon", "kind", "class", "closeButtonLabel"),
1534
+ emits: ["close"]
1429
1535
  });
1430
1536
  export {
1431
- Da as Button,
1432
- Va as ButtonGroup,
1433
- Wa as Flag,
1434
- Ha as FlexBox,
1435
- Ga as Heading,
1436
- za as HeadingLevelProvider,
1437
- Fe as Icon,
1438
- Fa as IconButton,
1439
- Ma as InputHelper,
1440
- La as InputLabel,
1441
- Ua as Message,
1442
- Z as Text,
1443
- yr as useHeadingLevel
1537
+ Ua as Button,
1538
+ za as ButtonGroup,
1539
+ Ha as Checkbox,
1540
+ Ka as Flag,
1541
+ Ya as FlexBox,
1542
+ Ja as Heading,
1543
+ Xa as HeadingLevelProvider,
1544
+ Ve as Icon,
1545
+ Wa as IconButton,
1546
+ Qa as InputHelper,
1547
+ Za as InputLabel,
1548
+ eo as Message,
1549
+ Xe as Text,
1550
+ gr as useHeadingLevel
1444
1551
  };
1445
1552
  //# sourceMappingURL=index.js.map