@indielayer/ui 1.9.2 → 1.10.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/docs/components/menu/DocsMenu.vue +1 -0
- package/docs/pages/component/form/usage.vue +2 -0
- package/docs/pages/component/menu/usage.vue +2 -0
- package/docs/pages/component/select/index.vue +7 -0
- package/docs/pages/component/select/multiple.vue +42 -0
- package/docs/pages/component/select/usage.vue +8 -12
- package/docs/pages/component/table/virtual.vue +19 -6
- package/docs/pages/component/toggle/index.vue +1 -1
- package/docs/pages/component/tooltip/index.vue +1 -1
- package/docs/pages/component/upload/index.vue +29 -0
- package/docs/pages/component/upload/usage.vue +115 -0
- package/docs/search/components.json +1 -1
- package/lib/common/icons.d.ts +2 -0
- package/lib/common/icons.js +17 -15
- package/lib/components/checkbox/Checkbox.vue2.js +9 -9
- package/lib/components/datepicker/Datepicker.vue.d.ts +4 -4
- package/lib/components/datepicker/Datepicker.vue.js +1 -1
- package/lib/components/drawer/Drawer.vue.js +1 -17
- package/lib/components/form/Form.vue.d.ts +4 -4
- package/lib/components/form/Form.vue.js +34 -34
- package/lib/components/formGroup/FormGroup.vue.d.ts +1 -1
- package/lib/components/formGroup/FormGroup.vue.js +39 -37
- package/lib/components/index.d.ts +1 -0
- package/lib/components/index.js +68 -66
- package/lib/components/label/theme/Label.base.theme.js +7 -7
- package/lib/components/menu/Menu.vue.d.ts +2 -0
- package/lib/components/menu/MenuItem.vue.d.ts +15 -3
- package/lib/components/menu/MenuItem.vue.js +1 -1
- package/lib/components/menu/MenuItem.vue2.js +43 -37
- package/lib/components/modal/Modal.vue.d.ts +4 -4
- package/lib/components/modal/Modal.vue.js +38 -34
- package/lib/components/notifications/Notifications.vue.d.ts +15 -0
- package/lib/components/notifications/Notifications.vue.js +149 -127
- package/lib/components/progress/Progress.vue.d.ts +4 -4
- package/lib/components/progress/Progress.vue.js +7 -7
- package/lib/components/scroll/Scroll.vue2.js +1 -1
- package/lib/components/select/Select.vue.d.ts +43 -1
- package/lib/components/select/Select.vue.js +358 -258
- package/lib/components/select/theme/Select.base.theme.js +1 -0
- package/lib/components/tab/Tab.vue.js +1 -1
- package/lib/components/tab/TabGroup.vue.js +2 -2
- package/lib/components/table/Table.vue.d.ts +4 -4
- package/lib/components/table/Table.vue.js +37 -37
- package/lib/components/table/TableCell.vue.d.ts +1 -1
- package/lib/components/tag/Tag.vue.js +23 -21
- package/lib/components/textarea/Textarea.vue.js +1 -1
- package/lib/components/upload/Upload.vue.d.ts +195 -0
- package/lib/components/upload/Upload.vue.js +264 -0
- package/lib/components/upload/Upload.vue2.js +4 -0
- package/lib/components/upload/__tests__/Upload.spec.d.ts +1 -0
- package/lib/components/upload/index.d.ts +2 -0
- package/lib/components/upload/theme/Upload.base.theme.d.ts +3 -0
- package/lib/components/upload/theme/Upload.base.theme.js +8 -0
- package/lib/components/upload/theme/Upload.carbon.theme.d.ts +3 -0
- package/lib/components/upload/theme/Upload.carbon.theme.js +5 -0
- package/lib/composables/useVirtualList.js +56 -53
- package/lib/index.js +43 -41
- package/lib/index.umd.js +4 -4
- package/lib/node_modules/.pnpm/@vueuse_core@11.1.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/core/index.js +501 -0
- package/lib/node_modules/.pnpm/@vueuse_shared@11.1.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/shared/index.js +96 -0
- package/lib/theme.d.ts +2 -1
- package/lib/themes/base/components.d.ts +1 -0
- package/lib/themes/base/components.js +23 -21
- package/lib/themes/carbon/components.d.ts +1 -0
- package/lib/themes/carbon/components.js +23 -21
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +3 -3
- package/src/common/icons.ts +2 -0
- package/src/components/checkbox/Checkbox.vue +5 -5
- package/src/components/drawer/Drawer.vue +0 -16
- package/src/components/form/Form.vue +10 -4
- package/src/components/formGroup/FormGroup.vue +2 -0
- package/src/components/index.ts +1 -0
- package/src/components/label/theme/Label.base.theme.ts +7 -5
- package/src/components/menu/Menu.vue +2 -0
- package/src/components/menu/MenuItem.vue +8 -6
- package/src/components/modal/Modal.vue +6 -1
- package/src/components/notifications/Notifications.vue +34 -4
- package/src/components/progress/Progress.vue +2 -2
- package/src/components/select/Select.vue +165 -67
- package/src/components/select/theme/Select.base.theme.ts +2 -0
- package/src/components/table/Table.vue +2 -3
- package/src/components/tag/Tag.vue +11 -9
- package/src/components/upload/Upload.vue +365 -0
- package/src/components/upload/__tests__/Upload.spec.ts +11 -0
- package/src/components/upload/index.ts +2 -0
- package/src/components/upload/theme/Upload.base.theme.ts +9 -0
- package/src/components/upload/theme/Upload.carbon.theme.ts +7 -0
- package/src/composables/useInputtable.ts +1 -1
- package/src/composables/useVirtualList.ts +8 -5
- package/src/theme.ts +2 -0
- package/src/themes/base/components.ts +1 -0
- package/src/themes/carbon/components.ts +1 -0
- package/src/version.ts +1 -1
- package/volar.d.ts +1 -0
- package/lib/node_modules/.pnpm/@vueuse_core@10.2.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/core/index.js +0 -412
- package/lib/node_modules/.pnpm/@vueuse_shared@10.2.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/shared/index.js +0 -90
|
@@ -5,6 +5,7 @@ const t = {
|
|
|
5
5
|
const r = ["w-full border border-secondary-300 dark:border-secondary-700 pr-8 outline-transparent outline outline-2 outline-offset-[-1px] transition-all duration-150 ease-in-out rounded-md shadow-sm"];
|
|
6
6
|
return !s.errorInternal && !e.disabled && r.push("hover:border-secondary-400 dark:hover:border-secondary-500"), e.size === "xs" ? r.push("px-2 py-1 text-xs") : e.size === "sm" ? r.push("px-2 py-1.5 text-sm") : e.size === "lg" ? r.push("px-4 py-3 text-lg") : e.size === "xl" ? r.push("px-5 py-4 text-xl") : r.push("px-3 py-2"), e.disabled ? r.push("bg-secondary-100 dark:bg-secondary-700 text-secondary-400 dark:text-secondary-600 cursor-not-allowed") : r.push("bg-white dark:bg-secondary-800 text-secondary-700 dark:text-secondary-200"), s.errorInternal ? r.push("border-error-500 dark:border-error-400 group-focus:outline-error-500") : e.disabled || r.push("group-focus:outline-[color:var(--x-select-border)]"), r;
|
|
7
7
|
},
|
|
8
|
+
truncateCounter: "absolute right-0 cursor-pointer hover:bg-secondary-200 bg-secondary-100 text-secondary-800 rounded px-1 py-0.5 text-xs",
|
|
8
9
|
content: "p-1",
|
|
9
10
|
search: "p-1 mb-0.5",
|
|
10
11
|
contentBody: "overflow-y-auto max-h-64 min-w-[280px]",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as R, computed as s, ref as d, inject as j, reactive as D, onMounted as E, openBlock as c, createBlock as m, resolveDynamicComponent as L, normalizeStyle as V, unref as o, normalizeClass as v, withCtx as M, renderSlot as g, createElementVNode as z, createCommentVNode as p, toDisplayString as O, Teleport as P, createElementBlock as X } from "vue";
|
|
2
|
-
import { useMutationObserver as F } from "../../node_modules/.pnpm/@vueuse_core@
|
|
2
|
+
import { useMutationObserver as F } from "../../node_modules/.pnpm/@vueuse_core@11.1.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/core/index.js";
|
|
3
3
|
import { injectTabGroupKey as G } from "../../composables/keys.js";
|
|
4
4
|
import { useCommon as T } from "../../composables/useCommon.js";
|
|
5
5
|
import { useTheme as I } from "../../composables/useTheme.js";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { defineComponent as B, ref as r, watchEffect as z, reactive as E, computed as o, provide as V, watch as G, onMounted as N, openBlock as $, createElementBlock as q, createElementVNode as f, normalizeClass as v, unref as n, normalizeStyle as F, createVNode as L, withCtx as M, renderSlot as O, withDirectives as W, vShow as X, nextTick as j } from "vue";
|
|
2
|
-
import { useMutationObserver as D, useResizeObserver as K } from "../../node_modules/.pnpm/@vueuse_core@
|
|
2
|
+
import { useMutationObserver as D, useResizeObserver as K } from "../../node_modules/.pnpm/@vueuse_core@11.1.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/core/index.js";
|
|
3
3
|
import { injectTabGroupKey as P } from "../../composables/keys.js";
|
|
4
4
|
import { useCommon as b } from "../../composables/useCommon.js";
|
|
5
5
|
import { useColors as A } from "../../composables/useColors.js";
|
|
6
6
|
import { useTheme as H } from "../../composables/useTheme.js";
|
|
7
7
|
import I from "../scroll/Scroll.vue.js";
|
|
8
|
-
import { useThrottleFn as J } from "../../node_modules/.pnpm/@vueuse_shared@
|
|
8
|
+
import { useThrottleFn as J } from "../../node_modules/.pnpm/@vueuse_shared@11.1.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/shared/index.js";
|
|
9
9
|
const Q = {
|
|
10
10
|
...b.validators(),
|
|
11
11
|
variant: ["line", "block"],
|
|
@@ -152,7 +152,7 @@ declare const _default: <T>(__VLS_props: Partial<{
|
|
|
152
152
|
"onUpdate:sort"?: ((...args: any[]) => any) | undefined;
|
|
153
153
|
"onClick-row"?: ((...args: any[]) => any) | undefined;
|
|
154
154
|
}>, "error" | "sort" | "items" | "loading" | "fixed" | "virtualList" | "virtualListItemHeight" | "virtualListOverscan" | "headers" | "loadingSkeleton" | "loadingLines" | "dense" | "striped" | "pointer" | "scrollable" | "stickyHeader" | "expandable"> & {
|
|
155
|
-
selected?:
|
|
155
|
+
selected?: string | number | undefined;
|
|
156
156
|
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, __VLS_ctx?: Pick<{
|
|
157
157
|
props: Partial<{
|
|
158
158
|
error: boolean;
|
|
@@ -244,7 +244,7 @@ declare const _default: <T>(__VLS_props: Partial<{
|
|
|
244
244
|
"onUpdate:sort"?: ((...args: any[]) => any) | undefined;
|
|
245
245
|
"onClick-row"?: ((...args: any[]) => any) | undefined;
|
|
246
246
|
}>, "error" | "sort" | "items" | "loading" | "fixed" | "virtualList" | "virtualListItemHeight" | "virtualListOverscan" | "headers" | "loadingSkeleton" | "loadingLines" | "dense" | "striped" | "pointer" | "scrollable" | "stickyHeader" | "expandable"> & {
|
|
247
|
-
selected?:
|
|
247
|
+
selected?: string | number | undefined;
|
|
248
248
|
};
|
|
249
249
|
expose(exposed: {}): void;
|
|
250
250
|
attrs: any;
|
|
@@ -355,7 +355,7 @@ declare const _default: <T>(__VLS_props: Partial<{
|
|
|
355
355
|
"onUpdate:sort"?: ((...args: any[]) => any) | undefined;
|
|
356
356
|
"onClick-row"?: ((...args: any[]) => any) | undefined;
|
|
357
357
|
}>, "error" | "sort" | "items" | "loading" | "fixed" | "virtualList" | "virtualListItemHeight" | "virtualListOverscan" | "headers" | "loadingSkeleton" | "loadingLines" | "dense" | "striped" | "pointer" | "scrollable" | "stickyHeader" | "expandable"> & {
|
|
358
|
-
selected?:
|
|
358
|
+
selected?: string | number | undefined;
|
|
359
359
|
};
|
|
360
360
|
expose(exposed: {}): void;
|
|
361
361
|
attrs: any;
|
|
@@ -469,7 +469,7 @@ declare const _default: <T>(__VLS_props: Partial<{
|
|
|
469
469
|
"onUpdate:sort"?: ((...args: any[]) => any) | undefined;
|
|
470
470
|
"onClick-row"?: ((...args: any[]) => any) | undefined;
|
|
471
471
|
}>, "error" | "sort" | "items" | "loading" | "fixed" | "virtualList" | "virtualListItemHeight" | "virtualListOverscan" | "headers" | "loadingSkeleton" | "loadingLines" | "dense" | "striped" | "pointer" | "scrollable" | "stickyHeader" | "expandable"> & {
|
|
472
|
-
selected?:
|
|
472
|
+
selected?: string | number | undefined;
|
|
473
473
|
};
|
|
474
474
|
expose(exposed: {}): void;
|
|
475
475
|
attrs: any;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as K, mergeModels as S, useModel as Q, computed as x, ref as R, watch as U, openBlock as l, createElementBlock as
|
|
1
|
+
import { defineComponent as K, mergeModels as S, useModel as Q, computed as x, ref as R, watch as U, openBlock as l, createElementBlock as r, mergeProps as C, unref as n, renderSlot as p, createElementVNode as f, normalizeStyle as H, normalizeClass as m, createVNode as v, withCtx as c, createBlock as g, createCommentVNode as $, Fragment as k, renderList as h, createTextVNode as O, toDisplayString as P } from "vue";
|
|
2
2
|
import { useTheme as Y } from "../../composables/useTheme.js";
|
|
3
3
|
import { useVirtualList as Z } from "../../composables/useVirtualList.js";
|
|
4
4
|
import j from "./TableHead.vue.js";
|
|
@@ -10,7 +10,7 @@ import te from "../spinner/Spinner.vue.js";
|
|
|
10
10
|
import se from "../skeleton/Skeleton.vue.js";
|
|
11
11
|
import le from "../icon/Icon.vue.js";
|
|
12
12
|
import { chevronDownIcon as oe } from "../../common/icons.js";
|
|
13
|
-
const
|
|
13
|
+
const ae = { key: 1 }, ie = { colspan: "999" }, re = { key: 2 }, ne = { colspan: "999" }, de = ["onClick"], ue = { colspan: "999" }, pe = {
|
|
14
14
|
headers: {
|
|
15
15
|
type: Array,
|
|
16
16
|
default: () => []
|
|
@@ -69,7 +69,7 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
69
69
|
}),
|
|
70
70
|
emits: /* @__PURE__ */ S(["update:sort", "click-row"], ["update:selected"]),
|
|
71
71
|
setup(B, { emit: z }) {
|
|
72
|
-
const
|
|
72
|
+
const i = B, L = Q(B, "selected"), A = x(() => typeof L.value < "u");
|
|
73
73
|
function V(e) {
|
|
74
74
|
try {
|
|
75
75
|
return JSON.parse(JSON.stringify(e));
|
|
@@ -77,39 +77,39 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
77
77
|
return [];
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
|
-
const b = x(() =>
|
|
80
|
+
const b = x(() => i.items), { list: M, containerProps: D, wrapperProps: E } = Z(
|
|
81
81
|
b,
|
|
82
82
|
{
|
|
83
|
-
disabled: !
|
|
84
|
-
itemHeight:
|
|
85
|
-
topOffset:
|
|
86
|
-
bottomOffset:
|
|
87
|
-
overscan:
|
|
83
|
+
disabled: !i.virtualList,
|
|
84
|
+
itemHeight: i.virtualListItemHeight || 54,
|
|
85
|
+
topOffset: i.virtualListOffsetTop || 0,
|
|
86
|
+
bottomOffset: i.virtualListOffsetBottom || 0,
|
|
87
|
+
overscan: i.virtualListOverscan
|
|
88
88
|
}
|
|
89
89
|
), y = R([]);
|
|
90
90
|
U(b, (e) => {
|
|
91
|
-
|
|
91
|
+
i.expandable && (y.value = V(e));
|
|
92
92
|
}, { immediate: !0 });
|
|
93
93
|
const J = z;
|
|
94
94
|
function X(e, o) {
|
|
95
95
|
if (e)
|
|
96
96
|
for (let t = 0; t < o.length; t++) {
|
|
97
|
-
const { 0:
|
|
98
|
-
if (e ===
|
|
97
|
+
const { 0: a, 1: s } = o[t].split(",");
|
|
98
|
+
if (e === a)
|
|
99
99
|
return parseInt(s) > 0 ? 1 : -1;
|
|
100
100
|
}
|
|
101
101
|
}
|
|
102
102
|
function F(e) {
|
|
103
|
-
const o =
|
|
103
|
+
const o = i.sort.slice(0);
|
|
104
104
|
let t = !1;
|
|
105
|
-
for (let
|
|
106
|
-
const { 0: s, 1: d } = o[
|
|
105
|
+
for (let a = 0; a < o.length; a++) {
|
|
106
|
+
const { 0: s, 1: d } = o[a].split(",");
|
|
107
107
|
if (s === e.value) {
|
|
108
108
|
if (t = !0, d === "-1") {
|
|
109
|
-
o.splice(
|
|
109
|
+
o.splice(a, 1, `${e.value},1`);
|
|
110
110
|
break;
|
|
111
111
|
} else if (d === "1") {
|
|
112
|
-
o.splice(
|
|
112
|
+
o.splice(a, 1);
|
|
113
113
|
break;
|
|
114
114
|
}
|
|
115
115
|
}
|
|
@@ -122,15 +122,15 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
122
122
|
const t = Array.isArray(o) ? o : o.match(/([^[.\]])+/g);
|
|
123
123
|
return (t == null ? void 0 : t.reduce((s, d) => s && s[d], e)) ?? "";
|
|
124
124
|
}
|
|
125
|
-
const { styles: q, classes: w, className: G } = Y("Table", {},
|
|
126
|
-
return (e, o) => (l(),
|
|
125
|
+
const { styles: q, classes: w, className: G } = Y("Table", {}, i);
|
|
126
|
+
return (e, o) => (l(), r("div", C({
|
|
127
127
|
class: [n(G), n(w).wrapper]
|
|
128
128
|
}, n(D)), [
|
|
129
129
|
p(e.$slots, "title"),
|
|
130
130
|
p(e.$slots, "actions"),
|
|
131
131
|
f("div", C(n(E), {
|
|
132
132
|
class: {
|
|
133
|
-
"!h-auto":
|
|
133
|
+
"!h-auto": i.loading
|
|
134
134
|
}
|
|
135
135
|
}), [
|
|
136
136
|
f("table", {
|
|
@@ -144,8 +144,8 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
144
144
|
width: "48",
|
|
145
145
|
class: "!p-0"
|
|
146
146
|
})) : $("", !0),
|
|
147
|
-
(l(!0),
|
|
148
|
-
key:
|
|
147
|
+
(l(!0), r(k, null, h(e.headers, (t, a) => (l(), g(I, {
|
|
148
|
+
key: a,
|
|
149
149
|
"text-align": t.align,
|
|
150
150
|
sort: X(t.value, e.sort),
|
|
151
151
|
sortable: t.sortable,
|
|
@@ -164,12 +164,12 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
164
164
|
}, 8, ["sticky-header"]),
|
|
165
165
|
v(n(ee), null, {
|
|
166
166
|
default: c(() => [
|
|
167
|
-
e.loading ? (l(!0),
|
|
168
|
-
key:
|
|
167
|
+
e.loading ? (l(!0), r(k, { key: 0 }, h(Number(e.loadingLines), (t, a) => (l(), g(T, {
|
|
168
|
+
key: a,
|
|
169
169
|
striped: e.striped
|
|
170
170
|
}, {
|
|
171
171
|
default: c(() => [
|
|
172
|
-
(l(!0),
|
|
172
|
+
(l(!0), r(k, null, h(e.headers, (s, d) => (l(), g(_, {
|
|
173
173
|
key: d,
|
|
174
174
|
"text-align": s.align,
|
|
175
175
|
width: s.width,
|
|
@@ -191,18 +191,18 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
191
191
|
}, 1032, ["text-align", "width", "dense", "fixed"]))), 128))
|
|
192
192
|
]),
|
|
193
193
|
_: 2
|
|
194
|
-
}, 1032, ["striped"]))), 128)) : e.error ? (l(),
|
|
195
|
-
f("td",
|
|
194
|
+
}, 1032, ["striped"]))), 128)) : e.error ? (l(), r("tr", ae, [
|
|
195
|
+
f("td", ie, [
|
|
196
196
|
p(e.$slots, "error")
|
|
197
197
|
])
|
|
198
|
-
])) : !b.value || b.value.length === 0 ? (l(),
|
|
198
|
+
])) : !b.value || b.value.length === 0 ? (l(), r("tr", re, [
|
|
199
199
|
f("td", ne, [
|
|
200
200
|
p(e.$slots, "empty")
|
|
201
201
|
])
|
|
202
|
-
])) : (l(!0),
|
|
202
|
+
])) : (l(!0), r(k, { key: 3 }, h(n(M), (t, a) => {
|
|
203
203
|
var s, d;
|
|
204
|
-
return l(),
|
|
205
|
-
key: e.keyProp ??
|
|
204
|
+
return l(), r(k, {
|
|
205
|
+
key: e.keyProp ?? a
|
|
206
206
|
}, [
|
|
207
207
|
v(T, {
|
|
208
208
|
pointer: e.pointer,
|
|
@@ -236,15 +236,15 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
236
236
|
}),
|
|
237
237
|
_: 2
|
|
238
238
|
}, 1024)) : $("", !0),
|
|
239
|
-
(l(!0),
|
|
239
|
+
(l(!0), r(k, null, h(e.headers, (u, N) => (l(), g(_, {
|
|
240
240
|
key: N,
|
|
241
241
|
"text-align": u.align,
|
|
242
242
|
truncate: u.truncate,
|
|
243
243
|
width: u.width,
|
|
244
244
|
dense: e.dense,
|
|
245
|
-
style: H([
|
|
246
|
-
height: `${
|
|
247
|
-
maxHeight: `${
|
|
245
|
+
style: H([i.virtualList ? {
|
|
246
|
+
height: `${i.virtualListItemHeight}px`,
|
|
247
|
+
maxHeight: `${i.virtualListItemHeight}px`,
|
|
248
248
|
overflow: "hidden",
|
|
249
249
|
whiteSpace: "nowrap"
|
|
250
250
|
} : {}])
|
|
@@ -261,7 +261,7 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
261
261
|
]),
|
|
262
262
|
_: 2
|
|
263
263
|
}, 1032, ["pointer", "striped", "selected", "onClick"]),
|
|
264
|
-
e.expandable ? (l(),
|
|
264
|
+
e.expandable ? (l(), r("tr", {
|
|
265
265
|
key: 0,
|
|
266
266
|
class: m({ hidden: !((s = y.value[t.index]) != null && s.__expanded) })
|
|
267
267
|
}, [
|
|
@@ -280,7 +280,7 @@ const re = { key: 1 }, ae = { colspan: "999" }, ie = { key: 2 }, ne = { colspan:
|
|
|
280
280
|
]),
|
|
281
281
|
_: 3
|
|
282
282
|
}),
|
|
283
|
-
e.loading ? (l(),
|
|
283
|
+
e.loading ? (l(), r("div", {
|
|
284
284
|
key: 0,
|
|
285
285
|
class: m(n(w).loadingWrapper)
|
|
286
286
|
}, [
|
|
@@ -51,8 +51,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<im
|
|
|
51
51
|
validator: (value: string) => boolean;
|
|
52
52
|
};
|
|
53
53
|
}>> & Readonly<{}>, {
|
|
54
|
-
dense: boolean;
|
|
55
54
|
truncate: boolean;
|
|
55
|
+
dense: boolean;
|
|
56
56
|
verticalAlign: "top" | "bottom" | "baseline" | "middle" | "text-bottom" | "text-top" | null;
|
|
57
57
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>, {
|
|
58
58
|
default?(_: {}): any;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent as f, computed as g, openBlock as
|
|
2
|
-
import { useColors as
|
|
1
|
+
import { defineComponent as f, computed as g, openBlock as s, createBlock as v, resolveDynamicComponent as b, normalizeClass as a, unref as r, normalizeStyle as k, withCtx as x, createElementBlock as y, renderSlot as l, createElementVNode as z, createVNode as B } from "vue";
|
|
2
|
+
import { useColors as C } from "../../composables/useColors.js";
|
|
3
3
|
import { useCommon as n } from "../../composables/useCommon.js";
|
|
4
|
-
import { useTheme as
|
|
4
|
+
import { useTheme as h } from "../../composables/useTheme.js";
|
|
5
5
|
import { closeIcon as S } from "../../common/icons.js";
|
|
6
|
-
import
|
|
7
|
-
const
|
|
6
|
+
import _ from "../icon/Icon.vue.js";
|
|
7
|
+
const $ = {
|
|
8
8
|
key: 0,
|
|
9
|
-
class: "max-w-full truncate"
|
|
10
|
-
}, w = {
|
|
9
|
+
class: "max-w-full truncate pr-4"
|
|
10
|
+
}, w = { class: "absolute right-1.5 top-0 h-full flex items-center" }, N = {
|
|
11
11
|
...n.props(),
|
|
12
|
-
...
|
|
12
|
+
...C.props("slate"),
|
|
13
13
|
tag: {
|
|
14
14
|
type: String,
|
|
15
15
|
default: "span"
|
|
@@ -23,15 +23,15 @@ const h = {
|
|
|
23
23
|
validators: {
|
|
24
24
|
...n.validators()
|
|
25
25
|
}
|
|
26
|
-
},
|
|
26
|
+
}, j = /* @__PURE__ */ f({
|
|
27
27
|
...T,
|
|
28
|
-
props:
|
|
28
|
+
props: N,
|
|
29
29
|
emits: ["remove"],
|
|
30
30
|
setup(d) {
|
|
31
|
-
const o = d, i = g(() => o.size === "xs" ? "xs" : o.size === "sm" ? "sm" : o.size === "lg" ? "md" : o.size === "xl" ? "lg" : "sm"), { styles: m, classes: c, className: u } =
|
|
32
|
-
return (e,
|
|
31
|
+
const o = d, i = g(() => o.size === "xs" ? "xs" : o.size === "sm" ? "sm" : o.size === "lg" ? "md" : o.size === "xl" ? "lg" : "sm"), { styles: m, classes: c, className: u } = h("Tag", {}, o);
|
|
32
|
+
return (e, t) => (s(), v(b(e.tag), {
|
|
33
33
|
class: a([
|
|
34
|
-
"text-[color:var(--x-tag-text)] dark:text-[color:var(--x-tag-dark-text)] border",
|
|
34
|
+
"text-[color:var(--x-tag-text)] dark:text-[color:var(--x-tag-dark-text)] border relative",
|
|
35
35
|
[
|
|
36
36
|
r(u),
|
|
37
37
|
r(c).wrapper,
|
|
@@ -42,14 +42,16 @@ const h = {
|
|
|
42
42
|
style: k(r(m))
|
|
43
43
|
}, {
|
|
44
44
|
default: x(() => [
|
|
45
|
-
e.removable ? (
|
|
45
|
+
e.removable ? (s(), y("span", $, [
|
|
46
46
|
l(e.$slots, "default"),
|
|
47
|
-
z(
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
47
|
+
z("div", w, [
|
|
48
|
+
B(_, {
|
|
49
|
+
size: i.value,
|
|
50
|
+
icon: r(S),
|
|
51
|
+
class: a(["cursor-pointer transition-colors duration-150", [e.disabled ? "text-secondary-400" : "hover:text-secondary-500"]]),
|
|
52
|
+
onClick: t[0] || (t[0] = (p) => !e.disabled && e.$emit("remove", p))
|
|
53
|
+
}, null, 8, ["size", "icon", "class"])
|
|
54
|
+
])
|
|
53
55
|
])) : l(e.$slots, "default", { key: 1 })
|
|
54
56
|
]),
|
|
55
57
|
_: 3
|
|
@@ -57,5 +59,5 @@ const h = {
|
|
|
57
59
|
}
|
|
58
60
|
});
|
|
59
61
|
export {
|
|
60
|
-
|
|
62
|
+
j as default
|
|
61
63
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as q, useAttrs as R, computed as A, ref as F, watch as H, openBlock as u, createBlock as p, normalizeStyle as K, unref as r, normalizeClass as L, withCtx as O, createElementVNode as $, mergeProps as D, toHandlers as W, withKeys as X, createCommentVNode as G } from "vue";
|
|
2
|
-
import { useResizeObserver as J, useEventListener as M } from "../../node_modules/.pnpm/@vueuse_core@
|
|
2
|
+
import { useResizeObserver as J, useEventListener as M } from "../../node_modules/.pnpm/@vueuse_core@11.1.0_vue@3.5.10_typescript@5.2.2_/node_modules/@vueuse/core/index.js";
|
|
3
3
|
import { useCSS as Q } from "../../composables/useCSS.js";
|
|
4
4
|
import { useTheme as U } from "../../composables/useTheme.js";
|
|
5
5
|
import { useCommon as f } from "../../composables/useCommon.js";
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { type ExtractPublicPropTypes, type PropType } from 'vue';
|
|
2
|
+
import { type ThemeComponent } from '../../composables/useTheme';
|
|
3
|
+
declare const validators: {
|
|
4
|
+
variant: readonly ["box"];
|
|
5
|
+
size: string[];
|
|
6
|
+
};
|
|
7
|
+
declare const uploadProps: {
|
|
8
|
+
placeholder: StringConstructor;
|
|
9
|
+
accept: StringConstructor;
|
|
10
|
+
multiple: BooleanConstructor;
|
|
11
|
+
maxFiles: (StringConstructor | NumberConstructor)[];
|
|
12
|
+
maxFileSize: (StringConstructor | NumberConstructor)[];
|
|
13
|
+
variant: {
|
|
14
|
+
type: PropType<"box">;
|
|
15
|
+
default: string;
|
|
16
|
+
};
|
|
17
|
+
action: StringConstructor;
|
|
18
|
+
headers: PropType<Record<string, string>>;
|
|
19
|
+
method: {
|
|
20
|
+
type: PropType<"POST" | "PUT">;
|
|
21
|
+
default: string;
|
|
22
|
+
};
|
|
23
|
+
withCredentials: BooleanConstructor;
|
|
24
|
+
modelValue: {
|
|
25
|
+
readonly type: PropType<string | number | boolean | object | any[] | undefined>;
|
|
26
|
+
readonly default: undefined;
|
|
27
|
+
};
|
|
28
|
+
id: StringConstructor;
|
|
29
|
+
name: StringConstructor;
|
|
30
|
+
readonly: BooleanConstructor;
|
|
31
|
+
required: BooleanConstructor;
|
|
32
|
+
validateOnInput: {
|
|
33
|
+
readonly type: BooleanConstructor;
|
|
34
|
+
readonly default: true;
|
|
35
|
+
};
|
|
36
|
+
label: StringConstructor;
|
|
37
|
+
helper: StringConstructor;
|
|
38
|
+
error: StringConstructor;
|
|
39
|
+
hideFooter: BooleanConstructor;
|
|
40
|
+
rules: {
|
|
41
|
+
readonly type: ArrayConstructor;
|
|
42
|
+
readonly default: () => never[];
|
|
43
|
+
};
|
|
44
|
+
tooltip: StringConstructor;
|
|
45
|
+
skipFormRegistry: BooleanConstructor;
|
|
46
|
+
disabled: BooleanConstructor;
|
|
47
|
+
loading: BooleanConstructor;
|
|
48
|
+
loadingLabel: StringConstructor;
|
|
49
|
+
loadingStatus: {
|
|
50
|
+
readonly type: PropType<import("../loader/Loader.vue").LoaderStatus>;
|
|
51
|
+
readonly default: "active";
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
export type UploadFile = {
|
|
55
|
+
file: File;
|
|
56
|
+
completed: boolean;
|
|
57
|
+
response?: any;
|
|
58
|
+
progress: number;
|
|
59
|
+
error: string;
|
|
60
|
+
};
|
|
61
|
+
export type UploadVariant = typeof validators.variant[number];
|
|
62
|
+
export type UploadProps = ExtractPublicPropTypes<typeof uploadProps>;
|
|
63
|
+
type InternalClasses = 'wrapper' | 'input';
|
|
64
|
+
export interface UploadTheme extends ThemeComponent<UploadProps, InternalClasses> {
|
|
65
|
+
}
|
|
66
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
67
|
+
placeholder: StringConstructor;
|
|
68
|
+
accept: StringConstructor;
|
|
69
|
+
multiple: BooleanConstructor;
|
|
70
|
+
maxFiles: (StringConstructor | NumberConstructor)[];
|
|
71
|
+
maxFileSize: (StringConstructor | NumberConstructor)[];
|
|
72
|
+
variant: {
|
|
73
|
+
type: PropType<"box">;
|
|
74
|
+
default: string;
|
|
75
|
+
};
|
|
76
|
+
action: StringConstructor;
|
|
77
|
+
headers: PropType<Record<string, string>>;
|
|
78
|
+
method: {
|
|
79
|
+
type: PropType<"POST" | "PUT">;
|
|
80
|
+
default: string;
|
|
81
|
+
};
|
|
82
|
+
withCredentials: BooleanConstructor;
|
|
83
|
+
modelValue: {
|
|
84
|
+
readonly type: PropType<string | number | boolean | object | any[] | undefined>;
|
|
85
|
+
readonly default: undefined;
|
|
86
|
+
};
|
|
87
|
+
id: StringConstructor;
|
|
88
|
+
name: StringConstructor;
|
|
89
|
+
readonly: BooleanConstructor;
|
|
90
|
+
required: BooleanConstructor;
|
|
91
|
+
validateOnInput: {
|
|
92
|
+
readonly type: BooleanConstructor;
|
|
93
|
+
readonly default: true;
|
|
94
|
+
};
|
|
95
|
+
label: StringConstructor;
|
|
96
|
+
helper: StringConstructor;
|
|
97
|
+
error: StringConstructor;
|
|
98
|
+
hideFooter: BooleanConstructor;
|
|
99
|
+
rules: {
|
|
100
|
+
readonly type: ArrayConstructor;
|
|
101
|
+
readonly default: () => never[];
|
|
102
|
+
};
|
|
103
|
+
tooltip: StringConstructor;
|
|
104
|
+
skipFormRegistry: BooleanConstructor;
|
|
105
|
+
disabled: BooleanConstructor;
|
|
106
|
+
loading: BooleanConstructor;
|
|
107
|
+
loadingLabel: StringConstructor;
|
|
108
|
+
loadingStatus: {
|
|
109
|
+
readonly type: PropType<import("../loader/Loader.vue").LoaderStatus>;
|
|
110
|
+
readonly default: "active";
|
|
111
|
+
};
|
|
112
|
+
}>, {
|
|
113
|
+
focus: () => void | undefined;
|
|
114
|
+
blur: () => void | undefined;
|
|
115
|
+
reset: () => void;
|
|
116
|
+
validate: (val?: any) => boolean;
|
|
117
|
+
setError: (val: string) => void;
|
|
118
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, string[], string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
119
|
+
placeholder: StringConstructor;
|
|
120
|
+
accept: StringConstructor;
|
|
121
|
+
multiple: BooleanConstructor;
|
|
122
|
+
maxFiles: (StringConstructor | NumberConstructor)[];
|
|
123
|
+
maxFileSize: (StringConstructor | NumberConstructor)[];
|
|
124
|
+
variant: {
|
|
125
|
+
type: PropType<"box">;
|
|
126
|
+
default: string;
|
|
127
|
+
};
|
|
128
|
+
action: StringConstructor;
|
|
129
|
+
headers: PropType<Record<string, string>>;
|
|
130
|
+
method: {
|
|
131
|
+
type: PropType<"POST" | "PUT">;
|
|
132
|
+
default: string;
|
|
133
|
+
};
|
|
134
|
+
withCredentials: BooleanConstructor;
|
|
135
|
+
modelValue: {
|
|
136
|
+
readonly type: PropType<string | number | boolean | object | any[] | undefined>;
|
|
137
|
+
readonly default: undefined;
|
|
138
|
+
};
|
|
139
|
+
id: StringConstructor;
|
|
140
|
+
name: StringConstructor;
|
|
141
|
+
readonly: BooleanConstructor;
|
|
142
|
+
required: BooleanConstructor;
|
|
143
|
+
validateOnInput: {
|
|
144
|
+
readonly type: BooleanConstructor;
|
|
145
|
+
readonly default: true;
|
|
146
|
+
};
|
|
147
|
+
label: StringConstructor;
|
|
148
|
+
helper: StringConstructor;
|
|
149
|
+
error: StringConstructor;
|
|
150
|
+
hideFooter: BooleanConstructor;
|
|
151
|
+
rules: {
|
|
152
|
+
readonly type: ArrayConstructor;
|
|
153
|
+
readonly default: () => never[];
|
|
154
|
+
};
|
|
155
|
+
tooltip: StringConstructor;
|
|
156
|
+
skipFormRegistry: BooleanConstructor;
|
|
157
|
+
disabled: BooleanConstructor;
|
|
158
|
+
loading: BooleanConstructor;
|
|
159
|
+
loadingLabel: StringConstructor;
|
|
160
|
+
loadingStatus: {
|
|
161
|
+
readonly type: PropType<import("../loader/Loader.vue").LoaderStatus>;
|
|
162
|
+
readonly default: "active";
|
|
163
|
+
};
|
|
164
|
+
}>> & Readonly<{
|
|
165
|
+
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
166
|
+
}>, {
|
|
167
|
+
disabled: boolean;
|
|
168
|
+
loading: boolean;
|
|
169
|
+
loadingStatus: import("../loader/Loader.vue").LoaderStatus;
|
|
170
|
+
modelValue: string | number | boolean | object | any[] | undefined;
|
|
171
|
+
readonly: boolean;
|
|
172
|
+
required: boolean;
|
|
173
|
+
validateOnInput: boolean;
|
|
174
|
+
hideFooter: boolean;
|
|
175
|
+
rules: unknown[];
|
|
176
|
+
skipFormRegistry: boolean;
|
|
177
|
+
variant: "box";
|
|
178
|
+
multiple: boolean;
|
|
179
|
+
method: "POST" | "PUT";
|
|
180
|
+
withCredentials: boolean;
|
|
181
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>, {
|
|
182
|
+
box?(_: {
|
|
183
|
+
isOver: boolean;
|
|
184
|
+
}): any;
|
|
185
|
+
files?(_: {
|
|
186
|
+
files: (string | number | boolean | object | any[] | undefined) & UploadFile[];
|
|
187
|
+
}): any;
|
|
188
|
+
removeIcon?(_: {}): any;
|
|
189
|
+
}>;
|
|
190
|
+
export default _default;
|
|
191
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
192
|
+
new (): {
|
|
193
|
+
$slots: S;
|
|
194
|
+
};
|
|
195
|
+
};
|