@codeandfunction/callaloo 3.16.4 → 3.16.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/dist/assets/CLInputMessages.css +1 -1
  2. package/dist/chunks/{CLA11yButton.vue_vue_type_style_index_0_lang-C9OzrJ6Y.js → CLA11yButton.vue_vue_type_style_index_0_lang-Drw6jsX_.js} +13 -12
  3. package/dist/chunks/{CLButton.vue_vue_type_style_index_0_lang--MP4S4D4.js → CLButton.vue_vue_type_style_index_0_lang-B4xTt-xw.js} +5 -5
  4. package/dist/chunks/{CLCard.vue_vue_type_style_index_0_lang-Ba1c7ZNn.js → CLCard.vue_vue_type_style_index_0_lang-Bj9WF_mX.js} +44 -43
  5. package/dist/chunks/{CLFormLabel.vue_vue_type_script_setup_true_lang-DNZdlItJ.js → CLFormLabel.vue_vue_type_script_setup_true_lang-CaHCD2xF.js} +1 -1
  6. package/dist/chunks/{CLHeading.vue_vue_type_style_index_0_lang-BO5OiCE-.js → CLHeading.vue_vue_type_style_index_0_lang-nUnSpm32.js} +11 -10
  7. package/dist/chunks/CLIcon.vue_vue_type_style_index_0_lang--1FTkRVd.js +87 -0
  8. package/dist/chunks/CLInputMessages.vue_vue_type_style_index_0_lang-Bt5xgOT4.js +153 -0
  9. package/dist/chunks/CLLink.vue_vue_type_style_index_0_lang-BDL4xcfJ.js +68 -0
  10. package/dist/chunks/{CLNavLink.vue_vue_type_script_setup_true_lang-DtzSW2Tr.js → CLNavLink.vue_vue_type_script_setup_true_lang-C_BQCWeg.js} +1 -1
  11. package/dist/chunks/CLPill.vue_vue_type_style_index_0_lang-DwNvvX0v.js +90 -0
  12. package/dist/chunks/{CLProgress.vue_vue_type_style_index_0_lang-BMozy0NJ.js → CLProgress.vue_vue_type_style_index_0_lang-Mikbgpn2.js} +16 -15
  13. package/dist/chunks/{CLSkeleton.vue_vue_type_style_index_0_lang-C82FyxKt.js → CLSkeleton.vue_vue_type_style_index_0_lang-Csb9YnTI.js} +11 -10
  14. package/dist/chunks/{CLSpinner.vue_vue_type_style_index_0_lang-DyT8L74M.js → CLSpinner.vue_vue_type_style_index_0_lang-BQ1w9Ik9.js} +17 -16
  15. package/dist/chunks/{CLText.vue_vue_type_style_index_0_lang-CG6043pv.js → CLText.vue_vue_type_style_index_0_lang-BJoS9z9q.js} +14 -13
  16. package/dist/chunks/CLToast.vue_vue_type_style_index_0_lang-C6gOJx7A.js +185 -0
  17. package/dist/chunks/utils-CAV1sBee.js +24 -0
  18. package/dist/chunks/utils-CS9Gz4oX.js +25 -0
  19. package/dist/chunks/utils-C_e2F4X7.js +17 -0
  20. package/dist/chunks/utils-Sqgt8Fa4.js +85 -0
  21. package/dist/chunks/utils-cOhtsyeB.js +41 -0
  22. package/dist/chunks/utils-zJwcNHl4.js +37 -0
  23. package/dist/components/Buttons/CLA11yButton/CLA11yButton.css +1 -1
  24. package/dist/components/Buttons/CLA11yButton/CLA11yButton.js +1 -1
  25. package/dist/components/Buttons/CLButton/CLButton.css +1 -1
  26. package/dist/components/Buttons/CLButton/CLButton.js +1 -1
  27. package/dist/components/Buttons/CLButton/CLButton.vue.d.ts +1 -1
  28. package/dist/components/Buttons/utils.d.ts +16 -2
  29. package/dist/components/CLIcon/CLIcon.css +1 -1
  30. package/dist/components/CLIcon/CLIcon.js +1 -1
  31. package/dist/components/CLIcon/utils.d.ts +3 -1
  32. package/dist/components/CLTable/CLTable.css +1 -1
  33. package/dist/components/CLTable/CLTable.js +113 -115
  34. package/dist/components/CLTable/utils.d.ts +5 -1
  35. package/dist/components/Containers/CLCard/CLCard.css +1 -1
  36. package/dist/components/Containers/CLCard/CLCard.js +1 -1
  37. package/dist/components/Containers/CLCarousel/CLCarousel.js +2 -2
  38. package/dist/components/Containers/CLDisclosure/CLDisclosure.css +1 -1
  39. package/dist/components/Containers/CLDisclosure/CLDisclosure.js +32 -31
  40. package/dist/components/Containers/utils.d.ts +15 -2
  41. package/dist/components/Form/CLCheckbox/CLCheckbox.css +1 -1
  42. package/dist/components/Form/CLCheckbox/CLCheckbox.js +33 -35
  43. package/dist/components/Form/CLCheckbox/CLCheckbox.vue.d.ts +2 -2
  44. package/dist/components/Form/CLInput/CLInput.css +1 -1
  45. package/dist/components/Form/CLInput/CLInput.js +31 -33
  46. package/dist/components/Form/CLInput/CLInput.vue.d.ts +3 -3
  47. package/dist/components/Form/CLRadioButton/CLRadioButton.css +1 -1
  48. package/dist/components/Form/CLRadioButton/CLRadioButton.js +35 -34
  49. package/dist/components/Form/CLSelect/CLSelect.css +1 -1
  50. package/dist/components/Form/CLSelect/CLSelect.js +32 -31
  51. package/dist/components/Form/CLTextArea/CLTextArea.css +1 -1
  52. package/dist/components/Form/CLTextArea/CLTextArea.js +21 -20
  53. package/dist/components/Form/utils.d.ts +51 -4
  54. package/dist/components/Indicators/CLBadge/CLBadge.css +1 -1
  55. package/dist/components/Indicators/CLBadge/CLBadge.js +12 -11
  56. package/dist/components/Indicators/CLBanner/CLBanner.css +1 -1
  57. package/dist/components/Indicators/CLBanner/CLBanner.js +27 -26
  58. package/dist/components/Indicators/CLPill/CLPill.css +1 -1
  59. package/dist/components/Indicators/CLPill/CLPill.js +1 -1
  60. package/dist/components/Indicators/CLProgress/CLProgress.css +1 -1
  61. package/dist/components/Indicators/CLProgress/CLProgress.js +1 -1
  62. package/dist/components/Indicators/utils.d.ts +31 -4
  63. package/dist/components/Loading/CLSkeleton/CLSkeleton.css +1 -1
  64. package/dist/components/Loading/CLSkeleton/CLSkeleton.js +1 -1
  65. package/dist/components/Loading/CLSpinner/CLSpinner.css +1 -1
  66. package/dist/components/Loading/CLSpinner/CLSpinner.js +1 -1
  67. package/dist/components/Loading/utils.d.ts +7 -2
  68. package/dist/components/Modals/CLModal/CLModal.css +1 -1
  69. package/dist/components/Modals/CLModal/CLModal.js +82 -78
  70. package/dist/components/Modals/utils.d.ts +5 -1
  71. package/dist/components/Navigation/CLLink/CLLink.css +1 -1
  72. package/dist/components/Navigation/CLLink/CLLink.js +1 -1
  73. package/dist/components/Navigation/CLNavLink/CLNavLink.js +1 -1
  74. package/dist/components/Navigation/CLNavSection/CLNavSection.js +2 -2
  75. package/dist/components/Navigation/utils.d.ts +8 -1
  76. package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.css +1 -1
  77. package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.js +6 -6
  78. package/dist/components/Popups/CLDropdownMenu/CLDropdownMenu.vue.d.ts +3 -3
  79. package/dist/components/Popups/CLToast/CLToast.css +1 -1
  80. package/dist/components/Popups/CLToast/CLToast.js +1 -1
  81. package/dist/components/Popups/utils.d.ts +8 -1
  82. package/dist/components/Providers/CLThemeProvider/utils.d.ts +0 -1
  83. package/dist/components/Providers/CLToastProvider/CLToastProvider.js +1 -1
  84. package/dist/components/Typography/CLHeading/CLHeading.css +1 -1
  85. package/dist/components/Typography/CLHeading/CLHeading.js +1 -1
  86. package/dist/components/Typography/CLText/CLText.css +1 -1
  87. package/dist/components/Typography/CLText/CLText.js +1 -1
  88. package/dist/components/Typography/utils.d.ts +3 -1
  89. package/dist/composables/useTheme.js +17 -16
  90. package/package.json +1 -4
  91. package/dist/chunks/CLIcon.vue_vue_type_style_index_0_lang-B_341q_b.js +0 -84
  92. package/dist/chunks/CLInputMessages.vue_vue_type_style_index_0_lang-DZEfoinY.js +0 -121
  93. package/dist/chunks/CLLink.vue_vue_type_style_index_0_lang-RAFpWIR2.js +0 -60
  94. package/dist/chunks/CLPill.vue_vue_type_style_index_0_lang-UKMQXfI-.js +0 -88
  95. package/dist/chunks/CLToast.vue_vue_type_style_index_0_lang-LiL8p_1M.js +0 -179
  96. package/dist/chunks/utils-B_htczw5.js +0 -30
  97. package/dist/chunks/utils-Bf54TEIp.js +0 -387
  98. package/dist/chunks/utils-CPp2QUlb.js +0 -15
  99. package/dist/chunks/utils-Cm9XP0Vu.js +0 -29
  100. package/dist/chunks/utils-DPwEOLZc.js +0 -26
  101. package/dist/chunks/utils-_aITYXfA.js +0 -73
@@ -0,0 +1,90 @@
1
+ import { defineComponent as y, computed as d, createElementBlock as i, openBlock as a, Fragment as h, createCommentVNode as o, createBlock as u, normalizeStyle as m, normalizeClass as c, unref as t, createElementVNode as s, toDisplayString as r, withCtx as z } from "vue";
2
+ import { _ as b } from "./CLButton.vue_vue_type_style_index_0_lang-B4xTt-xw.js";
3
+ import { _ as $ } from "./CLIcon.vue_vue_type_style_index_0_lang--1FTkRVd.js";
4
+ import { CLColorVariants as B, CLColors as L, CLIconSizes as f } from "../index.js";
5
+ import { p as C } from "./utils-Sqgt8Fa4.js";
6
+ const x = ["data-testid"], P = /* @__PURE__ */ y({
7
+ name: "CLPill",
8
+ __name: "CLPill",
9
+ props: {
10
+ color: { default: L.Neutral },
11
+ count: {},
12
+ elevated: { type: Boolean, default: !1 },
13
+ icon: {},
14
+ label: {},
15
+ onClick: {},
16
+ rounded: { type: Boolean, default: !0 },
17
+ testId: { default: "clll-pill" },
18
+ variant: { default: B.Soft }
19
+ },
20
+ setup(e) {
21
+ const n = e, l = "clll-pill", k = d(() => [
22
+ l,
23
+ `${l}--${n.color}--${n.variant}`,
24
+ n.count ? `${l}--has-count` : "",
25
+ n.elevated ? `${l}--elevated` : "",
26
+ n.icon ? `${l}--has-icon` : `${l}--has-noicon`,
27
+ n.rounded ? `${l}--rounded` : ""
28
+ ]), v = d(() => [
29
+ l,
30
+ `${l}--clickable`,
31
+ `${l}--${n.color}--${n.variant}`,
32
+ n.count ? `${l}--has-count` : "",
33
+ n.icon ? `${l}--has-icon` : `${l}--has-noicon`,
34
+ n.rounded ? `${l}--rounded` : ""
35
+ ]);
36
+ return (S, I) => (a(), i(h, null, [
37
+ e.onClick ? o("", !0) : (a(), i("div", {
38
+ key: 0,
39
+ class: c(t(k)),
40
+ "data-testid": e.testId,
41
+ style: m(t(C)({ color: e.color, variant: e.variant }))
42
+ }, [
43
+ e.icon ? (a(), u(t($), {
44
+ key: 0,
45
+ name: e.icon,
46
+ size: t(f).Tiny
47
+ }, null, 8, ["name", "size"])) : o("", !0),
48
+ s("span", {
49
+ class: c(`${l}__label`)
50
+ }, r(e.label), 3),
51
+ e.count ? (a(), i("span", {
52
+ key: 1,
53
+ class: c(`${l}__count`)
54
+ }, r(e.count), 3)) : o("", !0)
55
+ ], 14, x)),
56
+ e.onClick ? (a(), u(t(b), {
57
+ key: 1,
58
+ color: e.color,
59
+ "on-click": e.onClick,
60
+ variant: e.variant,
61
+ pill: "",
62
+ rounded: e.rounded
63
+ }, {
64
+ default: z(() => [
65
+ s("div", {
66
+ class: c(t(v)),
67
+ style: m(t(C)({ color: e.color, variant: e.variant }))
68
+ }, [
69
+ e.icon ? (a(), u(t($), {
70
+ key: 0,
71
+ name: e.icon,
72
+ size: t(f).Tiny
73
+ }, null, 8, ["name", "size"])) : o("", !0),
74
+ s("span", {
75
+ class: c(`${l}__label`)
76
+ }, r(e.label), 3),
77
+ e.count ? (a(), i("span", {
78
+ key: 1,
79
+ class: c(`${l}__count`)
80
+ }, r(e.count), 3)) : o("", !0)
81
+ ], 6)
82
+ ]),
83
+ _: 1
84
+ }, 8, ["color", "on-click", "variant", "rounded"])) : o("", !0)
85
+ ], 64));
86
+ }
87
+ });
88
+ export {
89
+ P as _
90
+ };
@@ -1,8 +1,8 @@
1
- import { defineComponent as p, mergeModels as _, useCssVars as $, useModel as C, computed as d, createElementBlock as n, openBlock as c, normalizeClass as s, unref as t, createCommentVNode as v, createElementVNode as a, createVNode as y, withCtx as g, createTextVNode as V, toDisplayString as x } from "vue";
2
- import { _ as N } from "./CLText.vue_vue_type_style_index_0_lang-CG6043pv.js";
1
+ import { defineComponent as p, mergeModels as _, useCssVars as y, useModel as $, computed as d, createElementBlock as n, openBlock as c, normalizeStyle as C, normalizeClass as s, unref as t, createCommentVNode as v, createElementVNode as a, createVNode as g, withCtx as V, createTextVNode as x, toDisplayString as N } from "vue";
2
+ import { _ as z } from "./CLText.vue_vue_type_style_index_0_lang-BJoS9z9q.js";
3
3
  import { CLTextTypes as B, CLColors as u, CLSizes as L } from "../index.js";
4
- import { a as b } from "./utils-_aITYXfA.js";
5
- const h = ["data-testid"], S = /* @__PURE__ */ p({
4
+ import { a as b } from "./utils-Sqgt8Fa4.js";
5
+ const h = ["data-testid"], E = /* @__PURE__ */ p({
6
6
  name: "CLProgress",
7
7
  __name: "CLProgress",
8
8
  props: /* @__PURE__ */ _({
@@ -18,19 +18,20 @@ const h = ["data-testid"], S = /* @__PURE__ */ p({
18
18
  }),
19
19
  emits: ["update:modelValue"],
20
20
  setup(o) {
21
- $((f) => ({
22
- v70fa21a0: l.value
21
+ y((f) => ({
22
+ v692adfe6: l.value
23
23
  }));
24
- const r = o, l = C(o, "modelValue"), e = "clll-progress", i = d(() => [
24
+ const r = o, l = $(o, "modelValue"), e = "clll-progress", i = d(() => [
25
25
  e,
26
26
  `${e}--${r.color}`,
27
27
  `${e}--${r.size}`,
28
28
  r.inverted ? `${e}--inverted` : "",
29
29
  r.rounded ? `${e}--rounded` : `${e}--not-rounded`
30
30
  ]), m = d(() => `${l.value}%`);
31
- return (f, z) => (c(), n("div", {
32
- class: s([t(i), t(b)({ color: o.color })]),
33
- "data-testid": o.testId
31
+ return (f, M) => (c(), n("div", {
32
+ class: s(t(i)),
33
+ "data-testid": o.testId,
34
+ style: C(t(b)({ color: o.color }))
34
35
  }, [
35
36
  o.status ? (c(), n("div", {
36
37
  key: 0,
@@ -39,12 +40,12 @@ const h = ["data-testid"], S = /* @__PURE__ */ p({
39
40
  a("div", {
40
41
  class: s(`${e}__status__label`)
41
42
  }, [
42
- y(t(N), {
43
+ g(t(z), {
43
44
  color: t(u).Neutral,
44
45
  type: t(B).Summary
45
46
  }, {
46
- default: g(() => [
47
- V(x(t(m)), 1)
47
+ default: V(() => [
48
+ x(N(t(m)), 1)
48
49
  ]),
49
50
  _: 1
50
51
  }, 8, ["color", "type"])
@@ -57,9 +58,9 @@ const h = ["data-testid"], S = /* @__PURE__ */ p({
57
58
  class: s(`${e}__bar`)
58
59
  }, null, 2)
59
60
  ], 2)
60
- ], 10, h));
61
+ ], 14, h));
61
62
  }
62
63
  });
63
64
  export {
64
- S as _
65
+ E as _
65
66
  };
@@ -1,6 +1,6 @@
1
- import { defineComponent as a, useCssVars as r, computed as i, createElementBlock as u, openBlock as c, normalizeClass as m, unref as n, createElementVNode as f } from "vue";
2
- import { s as p } from "./utils-DPwEOLZc.js";
3
- const k = ["data-testid"], _ = /* @__PURE__ */ a({
1
+ import { defineComponent as a, useCssVars as r, computed as i, createElementBlock as u, openBlock as m, normalizeStyle as c, normalizeClass as p, unref as n, createElementVNode as f } from "vue";
2
+ import { s as k } from "./utils-CAV1sBee.js";
3
+ const h = ["data-testid"], $ = /* @__PURE__ */ a({
4
4
  name: "CLSkeleton",
5
5
  __name: "CLSkeleton",
6
6
  props: {
@@ -12,22 +12,23 @@ const k = ["data-testid"], _ = /* @__PURE__ */ a({
12
12
  },
13
13
  setup(o) {
14
14
  r((s) => ({
15
- v168f558d: s.width,
16
- bce73b80: s.height
15
+ e132876a: s.width,
16
+ v43a1d342: s.height
17
17
  }));
18
18
  const t = o, e = "clll-skeleton", d = i(() => [
19
19
  e,
20
20
  t.borderRadius ? `${e}--${t.borderRadius}` : "",
21
21
  t.rounded ? `${e}--rounded` : `${e}--square`
22
22
  ]);
23
- return (s, l) => (c(), u("div", {
24
- class: m([n(d), n(p)()]),
25
- "data-testid": o.testId
23
+ return (s, l) => (m(), u("div", {
24
+ class: p(n(d)),
25
+ "data-testid": o.testId,
26
+ style: c(n(k)())
26
27
  }, [...l[0] || (l[0] = [
27
28
  f("div", { class: "clll-skeleton__animation" }, null, -1)
28
- ])], 10, k));
29
+ ])], 14, h));
29
30
  }
30
31
  });
31
32
  export {
32
- _
33
+ $ as _
33
34
  };
@@ -1,33 +1,34 @@
1
- import { defineComponent as m, computed as n, createElementBlock as r, openBlock as i, normalizeClass as c, unref as l, createElementVNode as a } from "vue";
2
- import { CLSizes as u, CLPosition as f, CLColors as C, CLAlign as $ } from "../index.js";
3
- import { a as z } from "./utils-DPwEOLZc.js";
4
- const L = ["data-testid"], h = /* @__PURE__ */ m({
1
+ import { defineComponent as d, computed as n, createElementBlock as r, openBlock as i, normalizeStyle as u, normalizeClass as c, unref as o, createElementVNode as a } from "vue";
2
+ import { CLSizes as f, CLPosition as C, CLColors as $, CLAlign as z } from "../index.js";
3
+ import { a as L } from "./utils-CAV1sBee.js";
4
+ const _ = ["data-testid"], h = /* @__PURE__ */ d({
5
5
  name: "CLSpinner",
6
6
  __name: "CLSpinner",
7
7
  props: {
8
- align: { default: $.Left },
9
- color: { default: C.Primary },
10
- position: { default: f.Absolute },
11
- size: { default: u.Medium },
8
+ align: { default: z.Left },
9
+ color: { default: $.Primary },
10
+ position: { default: C.Absolute },
11
+ size: { default: f.Medium },
12
12
  testId: { default: "clll-spinner" }
13
13
  },
14
- setup(o) {
15
- const t = o, e = "clll-spinner", p = n(() => [
14
+ setup(l) {
15
+ const t = l, e = "clll-spinner", m = n(() => [
16
16
  e,
17
17
  `${e}--${t.position}`,
18
18
  `${e}--${t.color}`,
19
19
  `${e}--${t.size}`,
20
20
  `${e}--${t.align}`
21
- ]), d = n(() => [
21
+ ]), p = n(() => [
22
22
  `${e}__circle`,
23
23
  `${e}__circle--${t.size}`
24
24
  ]);
25
- return (_, s) => (i(), r("div", {
26
- class: c([l(p), l(z)({ color: o.color })]),
27
- "data-testid": o.testId
25
+ return (g, s) => (i(), r("div", {
26
+ class: c(o(m)),
27
+ "data-testid": l.testId,
28
+ style: u(o(L)({ color: l.color }))
28
29
  }, [
29
30
  (i(), r("svg", {
30
- class: c(l(d)),
31
+ class: c(o(p)),
31
32
  xmlns: "http://www.w3.org/2000/svg",
32
33
  fill: "none",
33
34
  viewBox: "0 0 24 24"
@@ -45,7 +46,7 @@ const L = ["data-testid"], h = /* @__PURE__ */ m({
45
46
  d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
46
47
  }, null, -1)
47
48
  ])], 2))
48
- ], 10, L));
49
+ ], 14, _));
49
50
  }
50
51
  });
51
52
  export {
@@ -1,11 +1,11 @@
1
- import { defineComponent as s, computed as n, createBlock as r, openBlock as f, resolveDynamicComponent as c, normalizeClass as u, unref as o, withCtx as m, renderSlot as i } from "vue";
2
- import { CLTextTypes as p, CLColors as $, CLAlign as y } from "../index.js";
3
- import { t as C } from "./utils-CPp2QUlb.js";
4
- const h = /* @__PURE__ */ s({
1
+ import { defineComponent as d, computed as n, createBlock as r, openBlock as f, resolveDynamicComponent as c, normalizeStyle as m, normalizeClass as u, unref as o, withCtx as i, renderSlot as p } from "vue";
2
+ import { CLTextTypes as y, CLColors as $, CLAlign as C } from "../index.js";
3
+ import { t as x } from "./utils-C_e2F4X7.js";
4
+ const L = /* @__PURE__ */ d({
5
5
  name: "CLText",
6
6
  __name: "CLText",
7
7
  props: {
8
- align: { default: y.Left },
8
+ align: { default: C.Left },
9
9
  as: { default: "p" },
10
10
  bold: { type: Boolean, default: !1 },
11
11
  bolder: { type: Boolean, default: !1 },
@@ -14,7 +14,7 @@ const h = /* @__PURE__ */ s({
14
14
  medium: { type: Boolean, default: !1 },
15
15
  testId: { default: "clll-text" },
16
16
  truncate: { type: Boolean, default: !1 },
17
- type: { default: p.Body }
17
+ type: { default: y.Body }
18
18
  },
19
19
  setup(l) {
20
20
  const t = l, e = "clll-text", a = n(() => [
@@ -30,17 +30,18 @@ const h = /* @__PURE__ */ s({
30
30
  [`${e}--bolder`]: t.bolder
31
31
  }
32
32
  ]);
33
- return (d, x) => (f(), r(c(l.as), {
34
- class: u([o(a), o(C)({ color: l.color })]),
35
- "data-testid": l.testId
33
+ return (s, B) => (f(), r(c(l.as), {
34
+ class: u(o(a)),
35
+ "data-testid": l.testId,
36
+ style: m(o(x)({ color: l.color }))
36
37
  }, {
37
- default: m(() => [
38
- i(d.$slots, "default")
38
+ default: i(() => [
39
+ p(s.$slots, "default")
39
40
  ]),
40
41
  _: 3
41
- }, 8, ["class", "data-testid"]));
42
+ }, 8, ["class", "data-testid", "style"]));
42
43
  }
43
44
  });
44
45
  export {
45
- h as _
46
+ L as _
46
47
  };
@@ -0,0 +1,185 @@
1
+ import { defineComponent as _, useCssVars as U, ref as v, computed as p, watch as F, onMounted as P, onUnmounted as X, onBeforeUnmount as Z, createElementBlock as T, openBlock as m, normalizeStyle as j, normalizeClass as c, unref as a, createElementVNode as g, createBlock as x, createCommentVNode as b, createVNode as k, withCtx as L, createTextVNode as z, toDisplayString as S, isRef as q } from "vue";
2
+ import { _ as N } from "./CLButton.vue_vue_type_style_index_0_lang-B4xTt-xw.js";
3
+ import { _ as G } from "./CLIcon.vue_vue_type_style_index_0_lang--1FTkRVd.js";
4
+ import { _ as J } from "./CLProgress.vue_vue_type_style_index_0_lang-Mikbgpn2.js";
5
+ import { _ as K } from "./CLText.vue_vue_type_style_index_0_lang-BJoS9z9q.js";
6
+ import { _ as O } from "./CLHeading.vue_vue_type_style_index_0_lang-nUnSpm32.js";
7
+ import { CLMode as R, CLColorVariants as B, CLToastPosition as Q, CLIconSizes as I, CLColors as y, CLHeadingTypes as W, CLTextTypes as w, CLSizes as A, CLIconNames as Y } from "../index.js";
8
+ import { i as E, g as ee, a as te } from "./helper--hRjZVm6.js";
9
+ import { useEsc as oe } from "../composables/useEsc.js";
10
+ import { g as ae } from "./utils-CS9Gz4oX.js";
11
+ import { useTheme as se } from "../composables/useTheme.js";
12
+ const ie = ({ color: e, variant: t }) => {
13
+ const { borderRadius: $, colors: d, darkMode: n } = se(), s = n.value ? R.Dark : R.Light, r = ae({
14
+ color: e,
15
+ colors: d.value,
16
+ mode: s,
17
+ variant: t
18
+ });
19
+ return {
20
+ "--clll-toast-bg-color": n.value ? "black" : "white",
21
+ "--clll-toast-text-color": r?.text ?? "inherit",
22
+ "--clll-toast-icon-bg": r?.bg ?? "transparent",
23
+ "--clll-toast-icon-color": r?.text ?? "inherit",
24
+ "--clll-toast-timer-bg": r?.textDisabled ?? "transparent",
25
+ "--clll-toast-theme-radius": $.value ? `var(--clll-${$.value})` : void 0
26
+ };
27
+ }, le = ["data-testid"], u = 300, o = "clll-toast", ye = /* @__PURE__ */ _({
28
+ name: "CLToast",
29
+ __name: "CLToast",
30
+ props: {
31
+ actionLabel: {},
32
+ borderRadius: {},
33
+ color: { default: y.Secondary },
34
+ dismissTimer: { default: 5 },
35
+ icon: {},
36
+ iconSize: { default: I.Small },
37
+ message: {},
38
+ onAction: {},
39
+ onDismiss: {},
40
+ position: { default: Q.TopRight },
41
+ rounded: { type: Boolean, default: !0 },
42
+ testId: { default: "clll-toast" },
43
+ title: {},
44
+ variant: { default: B.Soft },
45
+ width: { default: "24rem" }
46
+ },
47
+ setup(e) {
48
+ U((i) => ({
49
+ v952305c6: i.width
50
+ }));
51
+ const t = e, $ = v(), d = v(100), n = v(!1), s = v(), r = v(0), D = p(() => [
52
+ o,
53
+ t.borderRadius ? `${o}--${t.borderRadius}` : "",
54
+ t.dismissTimer ? `${o}--has-timer` : "",
55
+ t.icon ? `${o}--has-icon` : "",
56
+ t.message && !t.title ? `${o}--has-messageonly` : "",
57
+ n.value ? `${o}--mounted` : "",
58
+ t.onAction && t.actionLabel ? `${o}--has-action` : "",
59
+ t.rounded ? `${o}--rounded` : `${o}--box`,
60
+ t.title && !t.message ? `${o}--has-titleonly` : "",
61
+ t.title && t.message ? `${o}--has-titleandmessage` : "",
62
+ `${o}--${t.position}`
63
+ ]), h = () => {
64
+ n.value = !1, s.value && (s.value.stop(), s.value.start(u, (i) => {
65
+ Math.min(i, u) === u && (s.value?.stop(), t.onDismiss?.());
66
+ })), M();
67
+ }, H = () => {
68
+ const i = t.dismissTimer * 1e3, l = i / 100;
69
+ s.value?.start(i, (f) => {
70
+ const C = Math.min(f / 100, l);
71
+ d.value = 100 - C / l * 100, C === l && h();
72
+ });
73
+ }, V = () => {
74
+ s.value || (s.value = te(), s.value.start(100, (i) => {
75
+ Math.min(i, 100) === 100 && (s.value?.stop(), n.value = !0, t?.dismissTimer && s.value?.start(u, (f) => {
76
+ Math.min(f, u) === u && (s.value?.stop(), H());
77
+ }));
78
+ }));
79
+ };
80
+ F(t, () => {
81
+ s.value && (s.value.stop(), s.value = void 0), t?.dismissTimer && V();
82
+ }), P(() => {
83
+ E && (r.value = ee() + 1, V());
84
+ }), X(() => {
85
+ E && t?.dismissTimer && s.value && (s.value.stop(), s.value = void 0), n.value = !1, t.onDismiss?.();
86
+ });
87
+ const { clearEventListeners: M } = oe({ escHandler: h });
88
+ return Z(() => {
89
+ M();
90
+ }), (i, l) => (m(), T("output", {
91
+ ref_key: "elem",
92
+ ref: $,
93
+ class: c(a(D)),
94
+ "data-testid": e.testId,
95
+ style: j({ zIndex: a(r), ...a(ie)({ color: e.color, variant: e.variant }) })
96
+ }, [
97
+ g("div", {
98
+ class: c(`${o}__body`)
99
+ }, [
100
+ g("div", {
101
+ class: c(`${o}__content`)
102
+ }, [
103
+ e.icon ? (m(), T("div", {
104
+ key: 0,
105
+ class: c(`${o}__icon`)
106
+ }, [
107
+ k(a(G), {
108
+ name: e.icon,
109
+ size: e.iconSize
110
+ }, null, 8, ["name", "size"])
111
+ ], 2)) : b("", !0),
112
+ g("div", {
113
+ class: c(`${o}__text`)
114
+ }, [
115
+ e.title ? (m(), x(a(O), {
116
+ key: 0,
117
+ color: a(y).Neutral,
118
+ "test-id": `${o}__title`,
119
+ type: a(W).Section
120
+ }, {
121
+ default: L(() => [
122
+ z(S(e.title), 1)
123
+ ]),
124
+ _: 1
125
+ }, 8, ["color", "test-id", "type"])) : b("", !0),
126
+ e.message ? (m(), x(a(K), {
127
+ key: 1,
128
+ color: a(y).Neutral,
129
+ "test-id": `${o}__message`,
130
+ type: e.title ? a(w).Medium : a(w).Body
131
+ }, {
132
+ default: L(() => [
133
+ z(S(e.message), 1)
134
+ ]),
135
+ _: 1
136
+ }, 8, ["color", "test-id", "type"])) : b("", !0)
137
+ ], 2),
138
+ e.onAction && e.actionLabel ? (m(), T("div", {
139
+ key: 1,
140
+ class: c(`${o}__action-button`)
141
+ }, [
142
+ k(a(N), {
143
+ color: e.color,
144
+ "border-radius": e.borderRadius,
145
+ "on-click": e.onAction,
146
+ "test-id": `${o}__action-button`,
147
+ variant: e.variant
148
+ }, {
149
+ default: L(() => [
150
+ z(S(e.actionLabel), 1)
151
+ ]),
152
+ _: 1
153
+ }, 8, ["color", "border-radius", "on-click", "test-id", "variant"])
154
+ ], 2)) : b("", !0)
155
+ ], 2),
156
+ g("div", {
157
+ class: c(`${o}__dismiss-button`)
158
+ }, [
159
+ k(a(N), {
160
+ "aria-label": "Dismiss toast",
161
+ color: a(y).Neutral,
162
+ "border-radius": e.borderRadius,
163
+ "icon-before": a(Y).Delete,
164
+ "icon-size": a(I).Tiny,
165
+ "on-click": h,
166
+ size: a(A).Tiny,
167
+ "test-id": `${o}__dismiss-button`,
168
+ variant: a(B).Text
169
+ }, null, 8, ["color", "border-radius", "icon-before", "icon-size", "size", "test-id", "variant"])
170
+ ], 2)
171
+ ], 2),
172
+ e.dismissTimer ? (m(), x(a(J), {
173
+ key: 0,
174
+ modelValue: a(d),
175
+ "onUpdate:modelValue": l[0] || (l[0] = (f) => q(d) ? d.value = f : null),
176
+ color: e.color,
177
+ rounded: !1,
178
+ size: a(A).Small
179
+ }, null, 8, ["modelValue", "color", "size"])) : b("", !0)
180
+ ], 14, le));
181
+ }
182
+ });
183
+ export {
184
+ ye as _
185
+ };
@@ -0,0 +1,24 @@
1
+ import { CLMode as l, CLColors as t, CLColorVariants as n } from "../index.js";
2
+ import { g as c } from "./utils-CS9Gz4oX.js";
3
+ import { useTheme as a } from "../composables/useTheme.js";
4
+ const g = () => {
5
+ const { borderRadius: o, darkMode: r } = a();
6
+ return {
7
+ "--clll-skeleton-bg-color": r.value ? "rgba(0 0 0 / 0.005)" : "rgba(0 0 0 / 0.075)",
8
+ "--clll-skeleton-theme-radius": o.value ? `var(--clll-${o.value})` : void 0
9
+ };
10
+ }, k = ({ color: o = t.Primary }) => {
11
+ const { colors: r, darkMode: e } = a(), s = e.value ? l.Dark : l.Light;
12
+ return {
13
+ "--clll-spinner-color": c({
14
+ color: o,
15
+ colors: r.value,
16
+ mode: s,
17
+ variant: n.Solid
18
+ })?.bg ?? "inherit"
19
+ };
20
+ };
21
+ export {
22
+ k as a,
23
+ g as s
24
+ };
@@ -0,0 +1,25 @@
1
+ import { C as v } from "./base-theme-Bg6XMoeN.js";
2
+ const b = ({
3
+ color: e,
4
+ colors: i,
5
+ mode: t,
6
+ variant: r
7
+ }) => {
8
+ const o = v[r][t], d = i[e];
9
+ if (d)
10
+ return {
11
+ bg: o.bg !== void 0 ? d[o.bg] : void 0,
12
+ border: o.border !== void 0 ? d[o.border] : void 0,
13
+ borderHover: o.borderHover !== void 0 ? d[o.borderHover] : void 0,
14
+ disabled: o.disabled !== void 0 ? d[o.disabled] : void 0,
15
+ focus: o.focus !== void 0 ? d[o.focus] : void 0,
16
+ hover: o.hover !== void 0 ? d[o.hover] : void 0,
17
+ shadow: o.shadow !== void 0 ? d[o.shadow] : void 0,
18
+ text: o.text !== void 0 ? d[o.text] : void 0,
19
+ textBody: o.textBody !== void 0 ? d[o.textBody] : void 0,
20
+ textDisabled: o.textDisabled !== void 0 ? d[o.textDisabled] : void 0
21
+ };
22
+ };
23
+ export {
24
+ b as g
25
+ };
@@ -0,0 +1,17 @@
1
+ import { CLMode as o, CLColors as s, CLColorVariants as a } from "../index.js";
2
+ import { g as c } from "./utils-CS9Gz4oX.js";
3
+ import { useTheme as m } from "../composables/useTheme.js";
4
+ const d = ({ color: t = s.Neutral }) => {
5
+ const { colors: r, darkMode: e } = m(), l = e.value ? o.Light : o.Dark;
6
+ return {
7
+ "--clll-text-color": c({
8
+ color: t,
9
+ colors: r.value,
10
+ mode: l,
11
+ variant: a.Text
12
+ })?.textBody ?? "inherit"
13
+ };
14
+ };
15
+ export {
16
+ d as t
17
+ };
@@ -0,0 +1,85 @@
1
+ import { CLMode as t, CLColorVariants as d, CLColors as b } from "../index.js";
2
+ import { g as p } from "./utils-CS9Gz4oX.js";
3
+ import { useTheme as u } from "../composables/useTheme.js";
4
+ const v = ({
5
+ color: a = b.Primary,
6
+ variant: r
7
+ }) => {
8
+ const { borderRadius: o, colors: e, darkMode: n } = u(), s = n.value ? t.Dark : t.Light, l = r === d.Outline, i = p({
9
+ color: a,
10
+ colors: e.value,
11
+ mode: s,
12
+ variant: r
13
+ });
14
+ return {
15
+ "--clll-badge-bg-color": i?.bg ?? "transparent",
16
+ "--clll-badge-border-color": l ? i?.border ?? "transparent" : "transparent",
17
+ "--clll-badge-border-style": l ? "solid" : "none",
18
+ "--clll-badge-border-width": l ? "1px" : "0",
19
+ "--clll-badge-text-color": i?.text ?? "inherit",
20
+ "--clll-badge-theme-radius": o.value ? `var(--clll-${o.value})` : void 0
21
+ };
22
+ }, x = ({
23
+ color: a = b.Primary,
24
+ variant: r
25
+ }) => {
26
+ const { borderRadius: o, colors: e, darkMode: n } = u(), s = n.value ? t.Dark : t.Light, l = p({
27
+ color: a,
28
+ colors: e.value,
29
+ mode: s,
30
+ variant: r
31
+ });
32
+ return {
33
+ "--clll-banner-bg-color": l?.bg ?? "transparent",
34
+ "--clll-banner-border-color": l?.focus ?? "transparent",
35
+ "--clll-banner-text-color": l?.text ?? "inherit",
36
+ "--clll-banner-theme-radius": o.value ? `var(--clll-${o.value})` : void 0
37
+ };
38
+ }, k = ({
39
+ color: a = b.Primary,
40
+ variant: r
41
+ }) => {
42
+ const { borderRadius: o, colors: e, darkMode: n } = u(), s = n.value ? t.Dark : t.Light, l = r === d.Outline, i = r === d.Ghost, c = p({
43
+ color: a,
44
+ colors: e.value,
45
+ mode: s,
46
+ variant: r
47
+ });
48
+ return {
49
+ "--clll-pill-bg-color": c?.bg ?? "transparent",
50
+ "--clll-pill-border-color": l ? c?.border ?? "transparent" : "transparent",
51
+ "--clll-pill-border-style": l ? "solid" : "none",
52
+ "--clll-pill-border-width": l ? "1px" : "0",
53
+ "--clll-pill-text-color": c?.text ?? "inherit",
54
+ "--clll-pill-hover-bg": c?.bg ?? "transparent",
55
+ "--clll-pill-count-bg": !l && !i ? c?.hover ?? "transparent" : "transparent",
56
+ "--clll-pill-count-border-style": l ? "solid" : "none",
57
+ "--clll-pill-count-border-color": l ? c?.border ?? "transparent" : "transparent",
58
+ "--clll-pill-count-border-width": l ? "1px" : "0",
59
+ "--clll-pill-theme-radius": o.value ? `var(--clll-${o.value})` : void 0
60
+ };
61
+ }, C = ({
62
+ color: a = b.Primary
63
+ }) => {
64
+ const { colors: r, darkMode: o } = u(), e = o.value ? t.Dark : t.Light, n = p({
65
+ color: a,
66
+ colors: r.value,
67
+ mode: e,
68
+ variant: d.Solid
69
+ });
70
+ return {
71
+ "--clll-progress-container-bg": p({
72
+ color: b.Neutral,
73
+ colors: r.value,
74
+ mode: e,
75
+ variant: d.Solid
76
+ })?.disabled ?? "transparent",
77
+ "--clll-progress-bar-bg": n?.bg ?? "transparent"
78
+ };
79
+ };
80
+ export {
81
+ C as a,
82
+ v as b,
83
+ x as c,
84
+ k as p
85
+ };