vlite3 1.4.27 → 1.4.28
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/components/CategoryManager/CategoryManager.vue2.js +1 -1
- package/components/ColorPicker/ColorIro.vue3.js +2 -2
- package/components/ColorPicker/ColorPicker.vue.d.ts +2 -2
- package/components/ColorPicker/ColorPicker.vue.js +77 -64
- package/components/CommandPalette/CommandPaletteContent.vue2.js +1 -1
- package/components/CommandPalette/{CommandPaletteItem.vue.js → CommandPaletteItem.vue2.js} +1 -1
- package/components/Dropdown/DropdownMenu.vue.js +1 -1
- package/components/FilePicker/index.vue.js +1 -1
- package/components/Form/FormField.vue.js +73 -70
- package/components/Form/TableRow.vue.js +55 -40
- package/components/Form/TableView.vue.js +36 -31
- package/components/NavbarCommandPalette.vue.js +1 -1
- package/components/Screen/ScreenFilter.vue.js +1 -1
- package/components/Stats/StatItem.vue.js +127 -123
- package/package.json +1 -1
- /package/components/ColorPicker/{ColorIro.vue.js → ColorIro.vue2.js} +0 -0
- /package/components/Dropdown/{DropdownMenu.vue3.js → DropdownMenu.vue2.js} +0 -0
|
@@ -9,7 +9,7 @@ interface Props {
|
|
|
9
9
|
position?: TooltTipPlacement;
|
|
10
10
|
btnProps?: ButtonProps;
|
|
11
11
|
showInput?: boolean;
|
|
12
|
-
trigger?: 'input' | 'button';
|
|
12
|
+
trigger?: 'input' | 'button' | 'swatch';
|
|
13
13
|
}
|
|
14
14
|
declare function __VLS_template(): {
|
|
15
15
|
attrs: Partial<{}>;
|
|
@@ -34,7 +34,7 @@ declare const __VLS_component: import('vue').DefineComponent<Props, {}, {}, {},
|
|
|
34
34
|
rounded: InputRounded;
|
|
35
35
|
disabled: boolean;
|
|
36
36
|
modelValue: string;
|
|
37
|
-
trigger: "input" | "button";
|
|
37
|
+
trigger: "input" | "button" | "swatch";
|
|
38
38
|
position: TooltTipPlacement;
|
|
39
39
|
showInput: boolean;
|
|
40
40
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
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
3
|
import "@iconify/vue";
|
|
4
|
-
import
|
|
4
|
+
import y from "../Input.vue.js";
|
|
5
5
|
/* empty css */
|
|
6
6
|
import "../../core/config.js";
|
|
7
7
|
/* empty css */
|
|
8
8
|
/* empty css */
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
/* empty css
|
|
9
|
+
import k from "../Button.vue.js";
|
|
10
|
+
import N from "./ColorIro.vue2.js";
|
|
11
|
+
/* empty css */
|
|
12
12
|
import { useEyeDropper as j } from "@vueuse/core";
|
|
13
|
-
const
|
|
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 = {
|
|
14
14
|
key: 0,
|
|
15
15
|
class: "p-1 w-max flex flex-col justify-center"
|
|
16
|
-
},
|
|
16
|
+
}, G = {
|
|
17
17
|
key: 0,
|
|
18
18
|
class: "flex items-center gap-1.5 w-full"
|
|
19
|
-
},
|
|
19
|
+
}, R = { class: "flex-1 w-0 min-w-0" }, _ = /* @__PURE__ */ B({
|
|
20
20
|
__name: "ColorPicker",
|
|
21
21
|
props: {
|
|
22
22
|
modelValue: { default: "#000000" },
|
|
@@ -30,95 +30,108 @@ const D = { class: "absolute left-2.5 top-1/2 -translate-y-1/2 flex items-center
|
|
|
30
30
|
trigger: { default: "input" }
|
|
31
31
|
},
|
|
32
32
|
emits: ["update:modelValue", "change"],
|
|
33
|
-
setup(
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
|
|
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
37
|
});
|
|
38
|
-
const
|
|
38
|
+
const C = async () => {
|
|
39
39
|
try {
|
|
40
|
-
await
|
|
41
|
-
} catch (
|
|
42
|
-
console.error("Error opening eyedropper:",
|
|
40
|
+
await V();
|
|
41
|
+
} catch (o) {
|
|
42
|
+
console.error("Error opening eyedropper:", o);
|
|
43
43
|
}
|
|
44
44
|
};
|
|
45
|
-
|
|
46
|
-
() =>
|
|
47
|
-
(
|
|
48
|
-
|
|
45
|
+
u(
|
|
46
|
+
() => r.modelValue,
|
|
47
|
+
(o) => {
|
|
48
|
+
o && o !== l.value && (l.value = o);
|
|
49
49
|
}
|
|
50
|
-
),
|
|
51
|
-
/^#([0-9A-F]{3,8})$/i.test(
|
|
50
|
+
), u(l, (o) => {
|
|
51
|
+
/^#([0-9A-F]{3,8})$/i.test(o) && o !== r.modelValue && (b("update:modelValue", o), b("change", o));
|
|
52
52
|
});
|
|
53
|
-
const
|
|
54
|
-
|
|
53
|
+
const $ = (o) => {
|
|
54
|
+
l.value = o;
|
|
55
55
|
};
|
|
56
|
-
return (
|
|
57
|
-
disabled:
|
|
56
|
+
return (o, a) => (t(), c(g(D), {
|
|
57
|
+
disabled: e.disabled,
|
|
58
58
|
class: "w-full",
|
|
59
|
-
position:
|
|
59
|
+
position: e.position,
|
|
60
60
|
offset: [0, 8],
|
|
61
61
|
searchable: !1,
|
|
62
62
|
"close-on-select": !1,
|
|
63
|
-
onOnOpen:
|
|
64
|
-
onOnClose:
|
|
63
|
+
onOnOpen: a[1] || (a[1] = (s) => d.value = !0),
|
|
64
|
+
onOnClose: a[2] || (a[2] = (s) => d.value = !1)
|
|
65
65
|
}, {
|
|
66
|
-
trigger:
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
trigger: m(({ isOpen: s }) => [
|
|
67
|
+
O(o.$slots, "trigger", { isOpen: s }, () => [
|
|
68
|
+
e.trigger === "button" ? (t(), c(k, E({
|
|
69
69
|
key: 0,
|
|
70
|
-
style: { backgroundColor:
|
|
70
|
+
style: { backgroundColor: e.modelValue }
|
|
71
71
|
}, {
|
|
72
72
|
rounded: "full",
|
|
73
73
|
size: "xs",
|
|
74
74
|
icon: " ",
|
|
75
75
|
variant: "outline",
|
|
76
|
-
...
|
|
77
|
-
}), null, 16, ["style"])) : (
|
|
76
|
+
...e.btnProps || {}
|
|
77
|
+
}), null, 16, ["style"])) : e.trigger === "swatch" ? (t(), i("button", {
|
|
78
78
|
key: 1,
|
|
79
|
-
|
|
79
|
+
type: "button",
|
|
80
|
+
disabled: e.disabled,
|
|
81
|
+
"aria-label": `Choose color ${e.modelValue}`,
|
|
82
|
+
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"
|
|
80
83
|
}, [
|
|
81
|
-
|
|
82
|
-
"
|
|
84
|
+
n("span", {
|
|
85
|
+
"aria-hidden": "true",
|
|
86
|
+
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 })
|
|
88
|
+
}, null, 4),
|
|
89
|
+
n("span", U, P(e.modelValue), 1)
|
|
90
|
+
], 8, I)) : (t(), i("div", {
|
|
91
|
+
key: 2,
|
|
92
|
+
class: S(["w-full relative cursor-pointer", [e.disabled ? "opacity-50 pointer-events-none" : ""]])
|
|
93
|
+
}, [
|
|
94
|
+
f(y, {
|
|
95
|
+
"model-value": e.modelValue,
|
|
83
96
|
readonly: "",
|
|
84
|
-
disabled:
|
|
85
|
-
size:
|
|
86
|
-
variant:
|
|
87
|
-
rounded:
|
|
97
|
+
disabled: e.disabled,
|
|
98
|
+
size: e.size,
|
|
99
|
+
variant: e.variant,
|
|
100
|
+
rounded: e.rounded,
|
|
88
101
|
class: "pointer-events-none",
|
|
89
102
|
"input-class": "pl-9 font-mono uppercase cursor-pointer"
|
|
90
103
|
}, null, 8, ["model-value", "disabled", "size", "variant", "rounded"]),
|
|
91
|
-
|
|
92
|
-
|
|
104
|
+
n("div", A, [
|
|
105
|
+
n("div", {
|
|
93
106
|
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)]",
|
|
94
|
-
style:
|
|
107
|
+
style: h({ backgroundColor: e.modelValue })
|
|
95
108
|
}, null, 4)
|
|
96
109
|
])
|
|
97
110
|
], 2))
|
|
98
111
|
])
|
|
99
112
|
]),
|
|
100
|
-
default:
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
color:
|
|
113
|
+
default: m(() => [
|
|
114
|
+
d.value ? (t(), i("div", F, [
|
|
115
|
+
f(N, {
|
|
116
|
+
color: e.modelValue,
|
|
104
117
|
"show-header": !1,
|
|
105
|
-
size:
|
|
106
|
-
"onUpdate:color":
|
|
118
|
+
size: e.size,
|
|
119
|
+
"onUpdate:color": $
|
|
107
120
|
}, {
|
|
108
|
-
bottom:
|
|
109
|
-
|
|
110
|
-
|
|
121
|
+
bottom: m(() => [
|
|
122
|
+
e.showInput ? (t(), i("div", G, [
|
|
123
|
+
g(w) ? (t(), c(k, {
|
|
111
124
|
key: 0,
|
|
112
|
-
onClick:
|
|
125
|
+
onClick: C,
|
|
113
126
|
icon: "pepicons-pop:color-picker",
|
|
114
127
|
variant: "outline",
|
|
115
128
|
size: "sm",
|
|
116
129
|
class: "px-2 shrink-0"
|
|
117
|
-
})) :
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
modelValue:
|
|
121
|
-
"onUpdate:modelValue":
|
|
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),
|
|
122
135
|
size: "sm",
|
|
123
136
|
"show-clear-button": !1,
|
|
124
137
|
placeholder: "#000000",
|
|
@@ -126,16 +139,16 @@ const D = { class: "absolute left-2.5 top-1/2 -translate-y-1/2 flex items-center
|
|
|
126
139
|
"input-class": "font-mono text-xs uppercase "
|
|
127
140
|
}, null, 8, ["modelValue"])
|
|
128
141
|
])
|
|
129
|
-
])) :
|
|
142
|
+
])) : p("", !0)
|
|
130
143
|
]),
|
|
131
144
|
_: 1
|
|
132
145
|
}, 8, ["color", "size"])
|
|
133
|
-
])) :
|
|
146
|
+
])) : p("", !0)
|
|
134
147
|
]),
|
|
135
148
|
_: 3
|
|
136
149
|
}, 8, ["disabled", "position"]));
|
|
137
150
|
}
|
|
138
151
|
});
|
|
139
152
|
export {
|
|
140
|
-
|
|
153
|
+
_ as default
|
|
141
154
|
};
|
|
@@ -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.
|
|
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",
|
|
@@ -63,7 +63,7 @@ const j = ["multiple", "accept", "data-testid"], O = /* @__PURE__ */ V({
|
|
|
63
63
|
return a["data-testid"] ? `${a["data-testid"]}-input` : a.name ? `filepicker-input-${a.name}` : "filepicker-input";
|
|
64
64
|
}), o = () => e.triggerInput(p.value), T = n(() => e.acceptAttribute.value);
|
|
65
65
|
return (a, r) => (u(), N("div", {
|
|
66
|
-
class: C(["vl-file-picker w-full min-w-0", { "vl-file-picker--input": l.variant === "input" }])
|
|
66
|
+
class: C(["vl-file-picker mb-4! w-full min-w-0", { "vl-file-picker--input": l.variant === "input" }])
|
|
67
67
|
}, [
|
|
68
68
|
E("input", {
|
|
69
69
|
ref_key: "fileInput",
|