vlite3 1.4.32 → 1.4.33

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 (43) hide show
  1. package/components/CategoryManager/CategoryManager.vue2.js +1 -1
  2. package/components/CategoryManager/CategoryNode.vue.js +30 -30
  3. package/components/CategoryMenu/CategoryMenu.vue.js +9 -11
  4. package/components/Chart/GanttChart.vue.d.ts +5 -1
  5. package/components/Chart/GanttChart.vue.js +2 -2
  6. package/components/Chart/GanttChart.vue2.js +977 -812
  7. package/components/Chart/GanttChartConnectorRouting.d.ts +83 -0
  8. package/components/Chart/GanttChartConnectorRouting.js +405 -0
  9. package/components/Chart/GanttChartDependencyUtils.js +43 -47
  10. package/components/Chart/types.d.ts +16 -1
  11. package/components/ColorPicker/ColorIro.vue2.js +78 -64
  12. package/components/ColorPicker/ColorPicker.vue.d.ts +5 -0
  13. package/components/ColorPicker/ColorPicker.vue.js +110 -64
  14. package/components/ColorPicker/constants.d.ts +2 -0
  15. package/components/ColorPicker/constants.js +4 -0
  16. package/components/ColorPicker/index.d.ts +1 -0
  17. package/components/CommandPalette/CommandPaletteContent.vue2.js +1 -1
  18. package/components/CommandPalette/{CommandPaletteItem.vue.js → CommandPaletteItem.vue2.js} +1 -1
  19. package/components/Dropdown/Dropdown.vue.js +100 -97
  20. package/components/Dropdown/DropdownMenu.vue.js +1 -1
  21. package/components/Form/{AccordionView.vue2.js → AccordionView.vue.js} +1 -1
  22. package/components/Form/FormField.vue.js +9 -8
  23. package/components/Form/index.vue2.js +1 -1
  24. package/components/Kanban/Kanban.vue.d.ts +16 -2
  25. package/components/Kanban/Kanban.vue.js +2 -2
  26. package/components/Kanban/Kanban.vue2.js +150 -86
  27. package/components/Kanban/types.d.ts +37 -0
  28. package/components/NavbarCommandPalette.vue.js +1 -1
  29. package/components/Screen/ScreenFilter.vue.js +1 -1
  30. package/components/ToastNotification.vue.js +1 -1
  31. package/components/ToastNotification.vue2.js +3 -3
  32. package/components/index.d.ts +1 -1
  33. package/composables/useKeyStroke.d.ts +18 -0
  34. package/composables/useKeyStroke.js +103 -77
  35. package/composables/useTheme.js +1 -1
  36. package/index.d.ts +1 -0
  37. package/index.js +235 -233
  38. package/package.json +10 -3
  39. package/style.css +1 -1
  40. package/utils/environment.d.ts +29 -0
  41. package/utils/environment.js +4 -0
  42. package/utils/functions.js +14 -13
  43. /package/components/Dropdown/{DropdownMenu.vue2.js → DropdownMenu.vue3.js} +0 -0
@@ -1,11 +1,12 @@
1
- import { defineComponent as H, ref as k, computed as E, watch as s, onMounted as B, onUnmounted as T, openBlock as l, createElementBlock as g, createVNode as C, unref as x, createBlock as b, createCommentVNode as u, createElementVNode as P, normalizeStyle as _, renderSlot as M, nextTick as N } from "vue";
2
- import i from "@jaames/iro";
3
- import { useEyeDropper as R } from "@vueuse/core";
4
- import p from "../Button.vue.js";
5
- const V = { class: "space-y-3 w-max" }, $ = {
1
+ import { defineComponent as T, ref as x, computed as _, watch as u, onMounted as B, onUnmounted as P, openBlock as a, createElementBlock as b, createVNode as R, unref as S, createBlock as z, createCommentVNode as p, createElementVNode as L, normalizeStyle as V, renderSlot as I, nextTick as M } from "vue";
2
+ import c from "@jaames/iro";
3
+ import { useEyeDropper as N } from "@vueuse/core";
4
+ import d from "../Button.vue.js";
5
+ import { COLOR_PICKER_RESET_VALUE as $ } from "./constants.js";
6
+ const D = { class: "space-y-3 w-max" }, F = {
6
7
  key: 0,
7
8
  class: "flex gap-2 mb-2.5 -text-fs-3 pr-0.5"
8
- }, U = /* @__PURE__ */ H({
9
+ }, j = /* @__PURE__ */ T({
9
10
  __name: "ColorIro",
10
11
  props: {
11
12
  color: {},
@@ -13,9 +14,14 @@ const V = { class: "space-y-3 w-max" }, $ = {
13
14
  size: { default: "md" }
14
15
  },
15
16
  emits: ["update:color", "close"],
16
- setup(n, { emit: S }) {
17
- const c = n, a = S, r = k(), e = k(null), { isSupported: d, open: z, sRGBHex: w } = R(), m = E(() => {
18
- switch (c.size) {
17
+ setup(l, { emit: E }) {
18
+ const n = l, s = E, t = x(), o = x(null);
19
+ let i = !1;
20
+ const { isSupported: f, open: w, sRGBHex: H } = N(), m = (e) => {
21
+ const r = (e || "").toLowerCase();
22
+ return r === $ || r === "#00000000";
23
+ }, C = (e) => m(e) || !e ? "#000000" : e, v = _(() => {
24
+ switch (n.size) {
19
25
  case "sm":
20
26
  return 140;
21
27
  case "lg":
@@ -23,119 +29,127 @@ const V = { class: "space-y-3 w-max" }, $ = {
23
29
  default:
24
30
  return 162;
25
31
  }
26
- }), f = {
32
+ }), y = {
27
33
  sm: 120,
28
34
  md: 140,
29
35
  lg: 150
30
- }, v = async () => {
31
- if (!(!r.value || e.value)) {
32
- await N();
36
+ }, h = async () => {
37
+ if (!(!t.value || o.value)) {
38
+ await M();
33
39
  try {
34
- e.value && (e.value.off("color:change"), e.value = null), r.value && (r.value.innerHTML = ""), e.value = i.ColorPicker(r.value, {
35
- width: m.value,
36
- color: c.color,
40
+ o.value && (o.value.off("color:change"), o.value = null), t.value && (t.value.innerHTML = ""), o.value = c.ColorPicker(t.value, {
41
+ width: v.value,
42
+ color: C(n.color),
37
43
  margin: 9,
38
- boxHeight: f[c.size],
44
+ boxHeight: y[n.size],
39
45
  sliderSize: 14,
40
46
  layout: [
41
47
  {
42
- component: i.ui.Box
48
+ component: c.ui.Box
43
49
  },
44
50
  {
45
- component: i.ui.Slider,
51
+ component: c.ui.Slider,
46
52
  options: {
47
53
  sliderType: "hue"
48
54
  }
49
55
  },
50
56
  {
51
- component: i.ui.Slider,
57
+ component: c.ui.Slider,
52
58
  options: {
53
59
  sliderType: "saturation"
54
60
  }
55
61
  },
56
62
  {
57
- component: i.ui.Slider,
63
+ component: c.ui.Slider,
58
64
  options: {
59
65
  sliderType: "value"
60
66
  }
61
67
  }
62
68
  ]
63
- }), e.value.on("color:change", (o) => {
64
- a("update:color", o.hexString);
69
+ }), o.value.on("color:change", (e) => {
70
+ i || s("update:color", e.hexString);
65
71
  });
66
- } catch (o) {
67
- console.error("Failed to initialize color picker:", o);
72
+ } catch (e) {
73
+ console.error("Failed to initialize color picker:", e);
68
74
  }
69
75
  }
70
- }, h = () => {
71
- e.value && (e.value.off("color:change"), e.value = null), r.value && (r.value.innerHTML = "");
76
+ }, k = () => {
77
+ o.value && (o.value.off("color:change"), o.value = null), t.value && (t.value.innerHTML = "");
72
78
  };
73
- s(
74
- () => c.color,
75
- (o) => {
76
- if (e.value && e.value.color.hexString !== o)
79
+ u(
80
+ () => n.color,
81
+ (e) => {
82
+ if (o.value && !m(e) && o.value.color.hexString !== e) {
83
+ i = !0;
77
84
  try {
78
- e.value.color.hexString = o;
79
- } catch (t) {
80
- console.error("Error updating color:", t);
85
+ o.value.color.hexString = e;
86
+ } catch (r) {
87
+ console.error("Error updating color:", r);
88
+ } finally {
89
+ i = !1;
81
90
  }
91
+ }
82
92
  }
83
- ), s(
84
- () => c.size,
93
+ ), u(
94
+ () => n.size,
85
95
  () => {
86
- h(), v();
96
+ k(), h();
87
97
  }
88
- ), s(w, (o) => {
89
- if (o && (a("update:color", o), e.value))
98
+ ), u(H, (e) => {
99
+ if (e && (s("update:color", e), o.value)) {
100
+ i = !0;
90
101
  try {
91
- e.value.color.hexString = o;
92
- } catch (t) {
93
- console.error("Error updating color from eyedropper:", t);
102
+ o.value.color.hexString = e;
103
+ } catch (r) {
104
+ console.error("Error updating color from eyedropper:", r);
105
+ } finally {
106
+ i = !1;
94
107
  }
108
+ }
95
109
  });
96
- const y = async () => {
110
+ const g = async () => {
97
111
  try {
98
- await z();
99
- } catch (o) {
100
- console.error("Error opening eyedropper:", o);
112
+ await w();
113
+ } catch (e) {
114
+ console.error("Error opening eyedropper:", e);
101
115
  }
102
116
  };
103
117
  return B(() => {
104
- v();
105
- }), T(() => {
106
118
  h();
107
- }), (o, t) => (l(), g("div", V, [
108
- n.showHeader ? (l(), g("div", $, [
109
- C(p, {
119
+ }), P(() => {
120
+ k();
121
+ }), (e, r) => (a(), b("div", D, [
122
+ l.showHeader ? (a(), b("div", F, [
123
+ R(d, {
110
124
  icon: "typcn:arrow-back",
111
- onClick: t[0] || (t[0] = (D) => a("close")),
125
+ onClick: r[0] || (r[0] = (O) => s("close")),
112
126
  class: "flex-1 px-2 py-1 bg-background hover:bg-accent rounded text-xs border border-border transition-colors"
113
127
  }),
114
- x(d) ? (l(), b(p, {
128
+ S(f) ? (a(), z(d, {
115
129
  key: 0,
116
- onClick: y,
130
+ onClick: g,
117
131
  icon: "pepicons-pop:color-picker",
118
132
  class: "flex-1 px-2 py-1 bg-background hover:bg-accent rounded text-xs border border-border transition-colors"
119
- })) : u("", !0)
120
- ])) : u("", !0),
121
- P("div", {
133
+ })) : p("", !0)
134
+ ])) : p("", !0),
135
+ L("div", {
122
136
  ref_key: "pickerRef",
123
- ref: r,
124
- style: _({ width: m.value + "px", minHeight: f[n.size] + "px" })
137
+ ref: t,
138
+ style: V({ width: v.value + "px", minHeight: y[l.size] + "px" })
125
139
  }, null, 4),
126
- M(o.$slots, "bottom", {}, () => [
127
- x(d) && !n.showHeader ? (l(), b(p, {
140
+ I(e.$slots, "bottom", {}, () => [
141
+ S(f) && !l.showHeader ? (a(), z(d, {
128
142
  key: 0,
129
- onClick: y,
143
+ onClick: g,
130
144
  icon: "pepicons-pop:color-picker",
131
145
  variant: "outline",
132
146
  size: "sm",
133
147
  class: "w-full"
134
- })) : u("", !0)
148
+ })) : p("", !0)
135
149
  ])
136
150
  ]));
137
151
  }
138
152
  });
139
153
  export {
140
- U as default
154
+ j as default
141
155
  };
@@ -10,6 +10,8 @@ interface Props {
10
10
  btnProps?: ButtonProps;
11
11
  showInput?: boolean;
12
12
  trigger?: 'input' | 'button' | 'swatch';
13
+ /** When true, shows a reset control that sets the value to `#0000` (transparent). */
14
+ allowReset?: boolean;
13
15
  }
14
16
  declare function __VLS_template(): {
15
17
  attrs: Partial<{}>;
@@ -23,9 +25,11 @@ declare function __VLS_template(): {
23
25
  };
24
26
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
25
27
  declare const __VLS_component: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
28
+ reset: (value: string) => any;
26
29
  change: (value: string) => any;
27
30
  "update:modelValue": (value: string) => any;
28
31
  }, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
32
+ onReset?: (value: string) => any;
29
33
  onChange?: (value: string) => any;
30
34
  "onUpdate:modelValue"?: (value: string) => any;
31
35
  }>, {
@@ -37,6 +41,7 @@ declare const __VLS_component: import('vue').DefineComponent<Props, {}, {}, {},
37
41
  trigger: "input" | "button" | "swatch";
38
42
  position: TooltTipPlacement;
39
43
  showInput: boolean;
44
+ allowReset: boolean;
40
45
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
41
46
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
42
47
  export default _default;
@@ -1,22 +1,26 @@
1
- import { defineComponent as B, ref as v, watch as u, openBlock as t, createBlock as c, unref as g, withCtx as m, createElementBlock as i, createVNode as f, createCommentVNode as p, createElementVNode as n, renderSlot as O, mergeProps as E, normalizeStyle as h, toDisplayString as P, normalizeClass as S } from "vue";
2
- import D from "../Dropdown/Dropdown.vue.js";
3
- import "@iconify/vue";
4
- import y from "../Input.vue.js";
1
+ import { defineComponent as S, ref as k, computed as w, watch as v, openBlock as o, createBlock as c, unref as V, withCtx as h, createElementBlock as s, createVNode as u, createCommentVNode as n, renderSlot as j, mergeProps as D, createElementVNode as m, normalizeStyle as C, toDisplayString as L, normalizeClass as N } from "vue";
2
+ import U from "../Dropdown/Dropdown.vue.js";
3
+ import z from "../Icon.vue.js";
4
+ import R from "../Input.vue.js";
5
5
  /* empty css */
6
6
  import "../../core/config.js";
7
7
  /* empty css */
8
8
  /* empty css */
9
- import k from "../Button.vue.js";
10
- import N from "./ColorIro.vue2.js";
9
+ import y from "../Button.vue.js";
10
+ import A from "./ColorIro.vue2.js";
11
11
  /* empty css */
12
- import { useEyeDropper as j } from "@vueuse/core";
13
- const I = ["disabled", "aria-label"], U = { class: "min-w-0 truncate text-foreground" }, A = { class: "absolute left-2.5 top-1/2 -translate-y-1/2 flex items-center justify-center z-20 pointer-events-none" }, F = {
12
+ import { useEyeDropper as T } from "@vueuse/core";
13
+ import { COLOR_PICKER_RESET_VALUE as g } from "./constants.js";
14
+ const F = ["disabled", "aria-label"], G = { class: "min-w-0 flex-1 truncate text-foreground" }, K = { class: "absolute left-2.5 top-1/2 -translate-y-1/2 flex items-center justify-center z-20 pointer-events-none" }, q = {
14
15
  key: 0,
15
16
  class: "p-1 w-max flex flex-col justify-center"
16
- }, G = {
17
+ }, J = {
17
18
  key: 0,
18
19
  class: "flex items-center gap-1.5 w-full"
19
- }, R = { class: "flex-1 w-0 min-w-0" }, _ = /* @__PURE__ */ B({
20
+ }, M = {
21
+ key: 1,
22
+ class: "flex-1 w-0 min-w-0"
23
+ }, ne = /* @__PURE__ */ S({
20
24
  __name: "ColorPicker",
21
25
  props: {
22
26
  modelValue: { default: "#000000" },
@@ -27,45 +31,51 @@ const I = ["disabled", "aria-label"], U = { class: "min-w-0 truncate text-foregr
27
31
  position: { default: "bottom" },
28
32
  btnProps: {},
29
33
  showInput: { type: Boolean, default: !0 },
30
- trigger: { default: "input" }
34
+ trigger: { default: "input" },
35
+ allowReset: { type: Boolean, default: !1 }
31
36
  },
32
- emits: ["update:modelValue", "change"],
33
- setup(e, { emit: x }) {
34
- const r = e, b = x, d = v(!1), l = v(r.modelValue || "#000000"), { isSupported: w, open: V, sRGBHex: z } = j();
35
- u(z, (o) => {
36
- o && (l.value = o);
37
+ emits: ["update:modelValue", "change", "reset"],
38
+ setup(e, { emit: $ }) {
39
+ const l = e, f = $, p = k(!1), a = k(l.modelValue || "#000000"), x = w(() => {
40
+ const t = (l.modelValue || "").toLowerCase();
41
+ return !t || t === g;
42
+ }), d = w(() => l.allowReset && !l.disabled && !x.value), { isSupported: E, open: O, sRGBHex: B } = T();
43
+ v(B, (t) => {
44
+ t && (a.value = t);
37
45
  });
38
- const C = async () => {
46
+ const P = async () => {
39
47
  try {
40
- await V();
41
- } catch (o) {
42
- console.error("Error opening eyedropper:", o);
48
+ await O();
49
+ } catch (t) {
50
+ console.error("Error opening eyedropper:", t);
43
51
  }
44
52
  };
45
- u(
46
- () => r.modelValue,
47
- (o) => {
48
- o && o !== l.value && (l.value = o);
53
+ v(
54
+ () => l.modelValue,
55
+ (t) => {
56
+ t && t !== a.value && (a.value = t);
49
57
  }
50
- ), u(l, (o) => {
51
- /^#([0-9A-F]{3,8})$/i.test(o) && o !== r.modelValue && (b("update:modelValue", o), b("change", o));
58
+ ), v(a, (t) => {
59
+ /^#([0-9A-F]{3,8})$/i.test(t) && t !== l.modelValue && (f("update:modelValue", t), f("change", t));
52
60
  });
53
- const $ = (o) => {
54
- l.value = o;
61
+ const I = (t) => {
62
+ a.value = t;
63
+ }, b = (t) => {
64
+ t?.stopPropagation(), t?.preventDefault(), !(!l.allowReset || l.disabled) && (x.value || (a.value = g, f("reset", g)));
55
65
  };
56
- return (o, a) => (t(), c(g(D), {
66
+ return (t, r) => (o(), c(V(U), {
57
67
  disabled: e.disabled,
58
68
  class: "w-full",
59
69
  position: e.position,
60
70
  offset: [0, 8],
61
71
  searchable: !1,
62
72
  "close-on-select": !1,
63
- onOnOpen: a[1] || (a[1] = (s) => d.value = !0),
64
- onOnClose: a[2] || (a[2] = (s) => d.value = !1)
73
+ onOnOpen: r[1] || (r[1] = (i) => p.value = !0),
74
+ onOnClose: r[2] || (r[2] = (i) => p.value = !1)
65
75
  }, {
66
- trigger: m(({ isOpen: s }) => [
67
- O(o.$slots, "trigger", { isOpen: s }, () => [
68
- e.trigger === "button" ? (t(), c(k, E({
76
+ trigger: h(({ isOpen: i }) => [
77
+ j(t.$slots, "trigger", { isOpen: i }, () => [
78
+ e.trigger === "button" ? (o(), c(y, D({
69
79
  key: 0,
70
80
  style: { backgroundColor: e.modelValue }
71
81
  }, {
@@ -74,24 +84,37 @@ const I = ["disabled", "aria-label"], U = { class: "min-w-0 truncate text-foregr
74
84
  icon: " ",
75
85
  variant: "outline",
76
86
  ...e.btnProps || {}
77
- }), null, 16, ["style"])) : e.trigger === "swatch" ? (t(), i("button", {
87
+ }), null, 16, ["style"])) : e.trigger === "swatch" ? (o(), s("button", {
78
88
  key: 1,
79
89
  type: "button",
80
90
  disabled: e.disabled,
81
91
  "aria-label": `Choose color ${e.modelValue}`,
82
92
  class: "flex min-h-10 w-full items-center gap-2.5 px-3 text-left font-mono text-xs uppercase transition-colors hover:bg-muted/40 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-primary disabled:cursor-not-allowed disabled:opacity-50"
83
93
  }, [
84
- n("span", {
94
+ m("span", {
85
95
  "aria-hidden": "true",
86
96
  class: "h-5 w-5 shrink-0 rounded-full border border-black/10 shadow-sm dark:border-white/15",
87
- style: h({ backgroundColor: e.modelValue })
97
+ style: C({ backgroundColor: e.modelValue })
88
98
  }, null, 4),
89
- n("span", U, P(e.modelValue), 1)
90
- ], 8, I)) : (t(), i("div", {
99
+ m("span", G, L(e.modelValue), 1),
100
+ d.value ? (o(), s("span", {
101
+ key: 0,
102
+ role: "button",
103
+ tabindex: "-1",
104
+ "aria-label": "Reset color",
105
+ class: "shrink-0 flex items-center justify-center text-muted-foreground hover:text-foreground focus:outline-none",
106
+ onClick: b
107
+ }, [
108
+ u(z, {
109
+ icon: "lucide:x-circle",
110
+ class: "h-4 w-4"
111
+ })
112
+ ])) : n("", !0)
113
+ ], 8, F)) : (o(), s("div", {
91
114
  key: 2,
92
- class: S(["w-full relative cursor-pointer", [e.disabled ? "opacity-50 pointer-events-none" : ""]])
115
+ class: N(["w-full relative cursor-pointer", [e.disabled ? "opacity-50 pointer-events-none" : ""]])
93
116
  }, [
94
- f(y, {
117
+ u(R, {
95
118
  "model-value": e.modelValue,
96
119
  readonly: "",
97
120
  disabled: e.disabled,
@@ -99,56 +122,79 @@ const I = ["disabled", "aria-label"], U = { class: "min-w-0 truncate text-foregr
99
122
  variant: e.variant,
100
123
  rounded: e.rounded,
101
124
  class: "pointer-events-none",
102
- "input-class": "pl-9 font-mono uppercase cursor-pointer"
103
- }, null, 8, ["model-value", "disabled", "size", "variant", "rounded"]),
104
- n("div", A, [
105
- n("div", {
125
+ "input-class": d.value ? "pl-9 pr-9 font-mono uppercase cursor-pointer" : "pl-9 font-mono uppercase cursor-pointer"
126
+ }, null, 8, ["model-value", "disabled", "size", "variant", "rounded", "input-class"]),
127
+ m("div", K, [
128
+ m("div", {
106
129
  class: "w-4 h-4 rounded-full shadow-[inset_0_0_0_1px_rgba(0,0,0,0.1)] dark:shadow-[inset_0_0_0_1px_rgba(255,255,255,0.1)]",
107
- style: h({ backgroundColor: e.modelValue })
130
+ style: C({ backgroundColor: e.modelValue })
108
131
  }, null, 4)
109
- ])
132
+ ]),
133
+ d.value ? (o(), s("button", {
134
+ key: 0,
135
+ type: "button",
136
+ tabindex: "-1",
137
+ "aria-label": "Reset color",
138
+ class: "absolute right-2.5 top-1/2 -translate-y-1/2 z-20 flex items-center justify-center text-muted-foreground hover:text-foreground focus:outline-none pointer-events-auto",
139
+ onClick: b
140
+ }, [
141
+ u(z, {
142
+ icon: "lucide:x-circle",
143
+ class: "h-4 w-4"
144
+ })
145
+ ])) : n("", !0)
110
146
  ], 2))
111
147
  ])
112
148
  ]),
113
- default: m(() => [
114
- d.value ? (t(), i("div", F, [
115
- f(N, {
149
+ default: h(() => [
150
+ p.value ? (o(), s("div", q, [
151
+ u(A, {
116
152
  color: e.modelValue,
117
153
  "show-header": !1,
118
154
  size: e.size,
119
- "onUpdate:color": $
155
+ "onUpdate:color": I
120
156
  }, {
121
- bottom: m(() => [
122
- e.showInput ? (t(), i("div", G, [
123
- g(w) ? (t(), c(k, {
157
+ bottom: h(() => [
158
+ e.showInput || e.allowReset ? (o(), s("div", J, [
159
+ e.showInput && V(E) ? (o(), c(y, {
124
160
  key: 0,
125
- onClick: C,
161
+ onClick: P,
126
162
  icon: "pepicons-pop:color-picker",
127
163
  variant: "outline",
128
164
  size: "sm",
129
165
  class: "px-2 shrink-0"
130
- })) : p("", !0),
131
- n("div", R, [
132
- f(y, {
133
- modelValue: l.value,
134
- "onUpdate:modelValue": a[0] || (a[0] = (s) => l.value = s),
166
+ })) : n("", !0),
167
+ e.showInput ? (o(), s("div", M, [
168
+ u(R, {
169
+ modelValue: a.value,
170
+ "onUpdate:modelValue": r[0] || (r[0] = (i) => a.value = i),
135
171
  size: "sm",
136
172
  "show-clear-button": !1,
137
173
  placeholder: "#000000",
138
174
  class: "w-full",
139
175
  "input-class": "font-mono text-xs uppercase "
140
176
  }, null, 8, ["modelValue"])
141
- ])
142
- ])) : p("", !0)
177
+ ])) : n("", !0),
178
+ d.value ? (o(), c(y, {
179
+ key: 2,
180
+ onClick: b,
181
+ icon: "lucide:rotate-ccw",
182
+ variant: "outline",
183
+ size: "sm",
184
+ class: "px-2 shrink-0",
185
+ "aria-label": "Reset color",
186
+ title: "Reset to transparent"
187
+ })) : n("", !0)
188
+ ])) : n("", !0)
143
189
  ]),
144
190
  _: 1
145
191
  }, 8, ["color", "size"])
146
- ])) : p("", !0)
192
+ ])) : n("", !0)
147
193
  ]),
148
194
  _: 3
149
195
  }, 8, ["disabled", "position"]));
150
196
  }
151
197
  });
152
198
  export {
153
- _ as default
199
+ ne as default
154
200
  };
@@ -0,0 +1,2 @@
1
+ /** Transparent hex written on reset (`#RGBA` with zero alpha). */
2
+ export declare const COLOR_PICKER_RESET_VALUE = "#0000";
@@ -0,0 +1,4 @@
1
+ const E = "#0000";
2
+ export {
3
+ E as COLOR_PICKER_RESET_VALUE
4
+ };
@@ -1 +1,2 @@
1
1
  export { default as ColorPicker } from './ColorPicker.vue';
2
+ export { COLOR_PICKER_RESET_VALUE } from './constants';
@@ -4,7 +4,7 @@ import k from "../Icon.vue.js";
4
4
  import { $t as E } from "../../utils/i18n.js";
5
5
  import { useCommandPaletteItems as Y } from "./useCommandPaletteItems.js";
6
6
  import { useCommandPaletteNav as Z } from "./useCommandPaletteNav.js";
7
- import ee from "./CommandPaletteItem.vue.js";
7
+ import ee from "./CommandPaletteItem.vue2.js";
8
8
  const te = { class: "command-palette-content flex flex-col w-full h-full max-h-[70vh]" }, oe = { class: "flex items-center gap-3 px-4 py-3 border-b border-border/80 shrink-0" }, se = ["placeholder"], ne = ["aria-label"], re = {
9
9
  key: 0,
10
10
  class: "flex flex-col items-center justify-center py-14 px-6 text-center select-none",
@@ -1,5 +1,5 @@
1
1
  import t from "./CommandPaletteItem.vue3.js";
2
- /* empty css */
2
+ /* empty css */
3
3
  import o from "../../_virtual/_plugin-vue_export-helper.js";
4
4
  const r = /* @__PURE__ */ o(t, [["__scopeId", "data-v-66b1ae06"]]);
5
5
  export {