@indielayer/ui 1.6.1 → 1.6.3
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/toolbar/Toolbar.vue +4 -2
- package/docs/components/toolbar/ToolbarSearch.vue +256 -0
- package/docs/pages/component/button/usage.vue +1 -1
- package/docs/pages/component/checkbox/states.vue +1 -1
- package/docs/pages/component/checkbox/usage.vue +1 -8
- package/docs/pages/component/input/size.vue +3 -2
- package/docs/pages/component/input/states.vue +3 -3
- package/docs/pages/component/input/usage.vue +1 -1
- package/docs/pages/component/input/variants.vue +2 -2
- package/docs/pages/component/radio/usage.vue +6 -7
- package/docs/pages/component/table/usage.vue +35 -40
- package/docs/pages/component/textarea/states.vue +8 -9
- package/docs/pages/component/textarea/variants.vue +7 -8
- package/docs/search/components.json +1 -0
- package/lib/components/button/theme/Button.base.theme.js +1 -1
- package/lib/components/card/theme/Card.base.theme.js +3 -3
- package/lib/components/checkbox/Checkbox.vue.d.ts +13 -3
- package/lib/components/form/Form.vue.js +8 -8
- package/lib/components/formGroup/FormGroup.vue.d.ts +13 -3
- package/lib/components/input/Input.vue.d.ts +13 -3
- package/lib/components/input/Input.vue.js +15 -15
- package/lib/components/input/theme/Input.base.theme.js +1 -1
- package/lib/components/modal/Modal.vue.d.ts +30 -4
- package/lib/components/modal/Modal.vue.js +82 -68
- package/lib/components/modal/theme/Modal.base.theme.js +12 -8
- package/lib/components/notifications/theme/Notifications.base.theme.js +1 -1
- package/lib/components/radio/Radio.vue.d.ts +13 -3
- package/lib/components/select/Select.vue.d.ts +13 -3
- package/lib/components/select/theme/Select.base.theme.js +1 -1
- package/lib/components/slider/Slider.vue.d.ts +13 -3
- package/lib/components/table/Table.vue.js +101 -98
- package/lib/components/table/theme/TableCell.base.theme.js +1 -1
- package/lib/components/table/theme/TableHead.base.theme.js +5 -5
- package/lib/components/table/theme/TableHeader.base.theme.js +2 -2
- package/lib/components/table/theme/TableRow.base.theme.js +1 -1
- package/lib/components/textarea/Textarea.vue.d.ts +13 -3
- package/lib/components/textarea/Textarea.vue.js +9 -9
- package/lib/components/textarea/theme/Textarea.base.theme.js +1 -1
- package/lib/components/toggle/Toggle.vue.d.ts +13 -3
- package/lib/composables/useFocusTrap.js +23 -31
- package/lib/composables/useInputtable.d.ts +4 -1
- package/lib/composables/useInputtable.js +22 -19
- package/lib/index.js +1 -1
- package/lib/index.umd.js +4 -4
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +7 -5
- package/src/components/button/theme/Button.base.theme.ts +2 -2
- package/src/components/card/theme/Card.base.theme.ts +1 -1
- package/src/components/form/Form.vue +1 -1
- package/src/components/input/Input.vue +3 -4
- package/src/components/input/theme/Input.base.theme.ts +1 -1
- package/src/components/modal/Modal.vue +33 -18
- package/src/components/modal/theme/Modal.base.theme.ts +10 -0
- package/src/components/notifications/theme/Notifications.base.theme.ts +1 -1
- package/src/components/select/theme/Select.base.theme.ts +1 -1
- package/src/components/table/Table.vue +1 -1
- package/src/components/table/theme/TableCell.base.theme.ts +1 -1
- package/src/components/table/theme/TableHead.base.theme.ts +2 -2
- package/src/components/table/theme/TableHeader.base.theme.ts +2 -2
- package/src/components/table/theme/TableRow.base.theme.ts +1 -1
- package/src/components/textarea/Textarea.vue +1 -1
- package/src/components/textarea/theme/Textarea.base.theme.ts +1 -1
- package/src/composables/useFocusTrap.ts +0 -23
- package/src/composables/useInputtable.ts +5 -1
- package/src/version.ts +1 -1
|
@@ -3,7 +3,7 @@ const t = {
|
|
|
3
3
|
wrapper: "",
|
|
4
4
|
box: ({ props: e, data: s }) => {
|
|
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
|
-
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-
|
|
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
8
|
content: "p-1 max-h-72 overflow-y-auto",
|
|
9
9
|
iconWrapper: "pointer-events-none absolute inset-y-0 right-0 flex items-center px-2",
|
|
@@ -13,7 +13,10 @@ declare const sliderProps: {
|
|
|
13
13
|
type: (StringConstructor | NumberConstructor)[];
|
|
14
14
|
default: number;
|
|
15
15
|
};
|
|
16
|
-
modelValue:
|
|
16
|
+
modelValue: {
|
|
17
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
18
|
+
readonly default: undefined;
|
|
19
|
+
};
|
|
17
20
|
id: StringConstructor;
|
|
18
21
|
name: StringConstructor;
|
|
19
22
|
readonly: BooleanConstructor;
|
|
@@ -60,7 +63,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
60
63
|
type: (StringConstructor | NumberConstructor)[];
|
|
61
64
|
default: number;
|
|
62
65
|
};
|
|
63
|
-
modelValue:
|
|
66
|
+
modelValue: {
|
|
67
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
68
|
+
readonly default: undefined;
|
|
69
|
+
};
|
|
64
70
|
id: StringConstructor;
|
|
65
71
|
name: StringConstructor;
|
|
66
72
|
readonly: BooleanConstructor;
|
|
@@ -108,7 +114,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
108
114
|
type: (StringConstructor | NumberConstructor)[];
|
|
109
115
|
default: number;
|
|
110
116
|
};
|
|
111
|
-
modelValue:
|
|
117
|
+
modelValue: {
|
|
118
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
119
|
+
readonly default: undefined;
|
|
120
|
+
};
|
|
112
121
|
id: StringConstructor;
|
|
113
122
|
name: StringConstructor;
|
|
114
123
|
readonly: BooleanConstructor;
|
|
@@ -144,6 +153,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
144
153
|
color: string;
|
|
145
154
|
loading: boolean;
|
|
146
155
|
loadingStatus: import("../loader/Loader.vue").LoaderStatus;
|
|
156
|
+
modelValue: string | number | boolean | object | any[] | undefined;
|
|
147
157
|
readonly: boolean;
|
|
148
158
|
required: boolean;
|
|
149
159
|
validateOnInput: boolean;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useTheme as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { chevronDownIcon as
|
|
12
|
-
const
|
|
1
|
+
import { defineComponent as J, ref as X, watch as F, openBlock as n, createElementBlock as r, normalizeClass as c, unref as p, renderSlot as d, createElementVNode as m, normalizeStyle as O, createVNode as y, withCtx as u, createBlock as k, createCommentVNode as b, Fragment as g, renderList as v, createTextVNode as C, toDisplayString as N } from "vue";
|
|
2
|
+
import { useTheme as P } from "../../composables/useTheme.js";
|
|
3
|
+
import W from "./TableHead.vue.js";
|
|
4
|
+
import S from "./TableHeader.vue.js";
|
|
5
|
+
import q from "./TableBody.js";
|
|
6
|
+
import z from "./TableRow.vue.js";
|
|
7
|
+
import B from "./TableCell.vue.js";
|
|
8
|
+
import G from "../spinner/Spinner.vue.js";
|
|
9
|
+
import K from "../skeleton/Skeleton.vue.js";
|
|
10
|
+
import M from "../icon/Icon.vue.js";
|
|
11
|
+
import { chevronDownIcon as Q } from "../../common/icons.js";
|
|
12
|
+
const R = { key: 1 }, U = ["colspan"], Y = { key: 2 }, Z = ["colspan"], j = ["onClick"], x = { colspan: "999" }, ee = {
|
|
13
13
|
headers: {
|
|
14
14
|
type: Array,
|
|
15
15
|
default: () => []
|
|
@@ -42,7 +42,7 @@ const Q = { key: 1 }, R = ["colspan"], U = { key: 2 }, Y = ["colspan"], Z = ["on
|
|
|
42
42
|
default: !0
|
|
43
43
|
},
|
|
44
44
|
expandable: Boolean
|
|
45
|
-
}, te = { name: "XTable" }, fe = /* @__PURE__ */
|
|
45
|
+
}, te = { name: "XTable" }, fe = /* @__PURE__ */ J({
|
|
46
46
|
...te,
|
|
47
47
|
props: {
|
|
48
48
|
...ee,
|
|
@@ -52,21 +52,21 @@ const Q = { key: 1 }, R = ["colspan"], U = { key: 2 }, Y = ["colspan"], Z = ["on
|
|
|
52
52
|
}
|
|
53
53
|
},
|
|
54
54
|
emits: ["update:sort", "click-row"],
|
|
55
|
-
setup(h, { emit:
|
|
56
|
-
const
|
|
57
|
-
function
|
|
55
|
+
setup(h, { emit: A }) {
|
|
56
|
+
const $ = h;
|
|
57
|
+
function T(e) {
|
|
58
58
|
try {
|
|
59
59
|
return JSON.parse(JSON.stringify(e));
|
|
60
60
|
} catch {
|
|
61
61
|
return [];
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
|
-
const
|
|
65
|
-
|
|
66
|
-
|
|
64
|
+
const f = X([]);
|
|
65
|
+
F(() => $.items, (e) => {
|
|
66
|
+
$.expandable && (f.value = T(e));
|
|
67
67
|
}, { immediate: !0 });
|
|
68
|
-
const
|
|
69
|
-
function
|
|
68
|
+
const H = A;
|
|
69
|
+
function V(e, o) {
|
|
70
70
|
if (e)
|
|
71
71
|
for (let t = 0; t < o.length; t++) {
|
|
72
72
|
const { 0: l, 1: s } = o[t].split(",");
|
|
@@ -74,59 +74,59 @@ const Q = { key: 1 }, R = ["colspan"], U = { key: 2 }, Y = ["colspan"], Z = ["on
|
|
|
74
74
|
return parseInt(s) > 0 ? 1 : -1;
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
|
-
function
|
|
78
|
-
const o =
|
|
77
|
+
function I(e) {
|
|
78
|
+
const o = $.sort.slice(0);
|
|
79
79
|
let t = !1;
|
|
80
80
|
for (let l = 0; l < o.length; l++) {
|
|
81
|
-
const { 0: s, 1:
|
|
81
|
+
const { 0: s, 1: a } = o[l].split(",");
|
|
82
82
|
if (s === e.value) {
|
|
83
|
-
if (t = !0,
|
|
83
|
+
if (t = !0, a === "-1") {
|
|
84
84
|
o.splice(l, 1, `${e.value},1`);
|
|
85
85
|
break;
|
|
86
|
-
} else if (
|
|
86
|
+
} else if (a === "1") {
|
|
87
87
|
o.splice(l, 1);
|
|
88
88
|
break;
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
|
-
t || o.push(`${e.value},-1`),
|
|
92
|
+
t || o.push(`${e.value},-1`), H("update:sort", o);
|
|
93
93
|
}
|
|
94
|
-
function
|
|
94
|
+
function L(e, o) {
|
|
95
95
|
if (!o)
|
|
96
96
|
return "";
|
|
97
97
|
const t = Array.isArray(o) ? o : o.match(/([^[.\]])+/g);
|
|
98
|
-
return (t == null ? void 0 : t.reduce((s,
|
|
98
|
+
return (t == null ? void 0 : t.reduce((s, a) => s && s[a], e)) ?? "";
|
|
99
99
|
}
|
|
100
|
-
const { styles:
|
|
101
|
-
return (e, o) => (n(),
|
|
102
|
-
class: c([
|
|
100
|
+
const { styles: D, classes: w, className: E } = P("Table", {}, $);
|
|
101
|
+
return (e, o) => (n(), r("div", {
|
|
102
|
+
class: c([p(E), p(w).wrapper])
|
|
103
103
|
}, [
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
style:
|
|
108
|
-
class: c(
|
|
104
|
+
d(e.$slots, "title"),
|
|
105
|
+
d(e.$slots, "actions"),
|
|
106
|
+
m("table", {
|
|
107
|
+
style: O(p(D)),
|
|
108
|
+
class: c(p(w).table)
|
|
109
109
|
}, [
|
|
110
|
-
|
|
111
|
-
default:
|
|
112
|
-
e.expandable ? (n(),
|
|
110
|
+
y(W, null, {
|
|
111
|
+
default: u(() => [
|
|
112
|
+
e.expandable ? (n(), k(S, {
|
|
113
113
|
key: 0,
|
|
114
114
|
width: "48",
|
|
115
115
|
class: "!p-0",
|
|
116
116
|
"sticky-header": e.stickyHeader
|
|
117
|
-
}, null, 8, ["sticky-header"])) :
|
|
118
|
-
(n(!0),
|
|
117
|
+
}, null, 8, ["sticky-header"])) : b("", !0),
|
|
118
|
+
(n(!0), r(g, null, v(e.headers, (t, l) => (n(), k(S, {
|
|
119
119
|
key: l,
|
|
120
120
|
"sticky-header": e.stickyHeader,
|
|
121
121
|
"text-align": t.align,
|
|
122
|
-
sort:
|
|
122
|
+
sort: V(t.value, e.sort),
|
|
123
123
|
sortable: t.sortable,
|
|
124
124
|
width: t.width,
|
|
125
|
-
onClick: (s) => t.sortable ?
|
|
125
|
+
onClick: (s) => t.sortable ? I(t) : null
|
|
126
126
|
}, {
|
|
127
|
-
default:
|
|
128
|
-
|
|
129
|
-
|
|
127
|
+
default: u(() => [
|
|
128
|
+
d(e.$slots, `header-${t.value}`, { header: t }, () => [
|
|
129
|
+
C(N(t.text), 1)
|
|
130
130
|
])
|
|
131
131
|
]),
|
|
132
132
|
_: 2
|
|
@@ -134,23 +134,23 @@ const Q = { key: 1 }, R = ["colspan"], U = { key: 2 }, Y = ["colspan"], Z = ["on
|
|
|
134
134
|
]),
|
|
135
135
|
_: 3
|
|
136
136
|
}),
|
|
137
|
-
|
|
138
|
-
default:
|
|
139
|
-
e.loading ? (n(!0),
|
|
137
|
+
y(p(q), null, {
|
|
138
|
+
default: u(() => [
|
|
139
|
+
e.loading ? (n(!0), r(g, { key: 0 }, v(Number(e.loadingLines), (t, l) => (n(), k(z, {
|
|
140
140
|
key: l,
|
|
141
141
|
striped: e.striped
|
|
142
142
|
}, {
|
|
143
|
-
default:
|
|
144
|
-
(n(!0),
|
|
145
|
-
key:
|
|
143
|
+
default: u(() => [
|
|
144
|
+
(n(!0), r(g, null, v(e.headers, (s, a) => (n(), k(B, {
|
|
145
|
+
key: a,
|
|
146
146
|
"text-align": s.align,
|
|
147
147
|
width: s.width,
|
|
148
148
|
dense: e.dense,
|
|
149
149
|
fixed: e.fixed
|
|
150
150
|
}, {
|
|
151
|
-
default:
|
|
152
|
-
|
|
153
|
-
|
|
151
|
+
default: u(() => [
|
|
152
|
+
d(e.$slots, `loading-${s.value}`, { item: t }, () => [
|
|
153
|
+
y(K, {
|
|
154
154
|
class: c(["max-w-[60%]", {
|
|
155
155
|
"mx-auto": s.align === "center",
|
|
156
156
|
"ml-auto": s.align === "right"
|
|
@@ -163,63 +163,63 @@ const Q = { key: 1 }, R = ["colspan"], U = { key: 2 }, Y = ["colspan"], Z = ["on
|
|
|
163
163
|
}, 1032, ["text-align", "width", "dense", "fixed"]))), 128))
|
|
164
164
|
]),
|
|
165
165
|
_: 2
|
|
166
|
-
}, 1032, ["striped"]))), 128)) : e.error ? (n(),
|
|
167
|
-
|
|
166
|
+
}, 1032, ["striped"]))), 128)) : e.error ? (n(), r("tr", R, [
|
|
167
|
+
m("td", {
|
|
168
168
|
colspan: e.headers.length
|
|
169
169
|
}, [
|
|
170
|
-
|
|
171
|
-
], 8,
|
|
172
|
-
])) : !h.items || h.items.length === 0 ? (n(),
|
|
173
|
-
|
|
170
|
+
d(e.$slots, "error")
|
|
171
|
+
], 8, U)
|
|
172
|
+
])) : !h.items || h.items.length === 0 ? (n(), r("tr", Y, [
|
|
173
|
+
m("td", {
|
|
174
174
|
colspan: e.headers.length
|
|
175
175
|
}, [
|
|
176
|
-
|
|
177
|
-
], 8,
|
|
178
|
-
])) : (n(!0),
|
|
179
|
-
var s;
|
|
180
|
-
return n(),
|
|
181
|
-
|
|
176
|
+
d(e.$slots, "empty")
|
|
177
|
+
], 8, Z)
|
|
178
|
+
])) : (n(!0), r(g, { key: 3 }, v(h.items, (t, l) => {
|
|
179
|
+
var s, a;
|
|
180
|
+
return n(), r(g, { key: l }, [
|
|
181
|
+
y(z, {
|
|
182
182
|
pointer: e.pointer,
|
|
183
183
|
striped: e.striped,
|
|
184
|
-
onClick: (
|
|
184
|
+
onClick: (i) => e.$emit("click-row", t)
|
|
185
185
|
}, {
|
|
186
|
-
default:
|
|
187
|
-
e.expandable ? (n(),
|
|
186
|
+
default: u(() => [
|
|
187
|
+
e.expandable ? (n(), k(B, {
|
|
188
188
|
key: 0,
|
|
189
189
|
width: "48",
|
|
190
190
|
class: "!p-1"
|
|
191
191
|
}, {
|
|
192
|
-
default:
|
|
193
|
-
var
|
|
192
|
+
default: u(() => {
|
|
193
|
+
var i;
|
|
194
194
|
return [
|
|
195
|
-
|
|
195
|
+
m("button", {
|
|
196
196
|
type: "button",
|
|
197
197
|
class: "p-4",
|
|
198
|
-
onClick: (
|
|
198
|
+
onClick: (_) => f.value[l].__expanded = !f.value[l].__expanded
|
|
199
199
|
}, [
|
|
200
|
-
|
|
201
|
-
icon:
|
|
200
|
+
y(M, {
|
|
201
|
+
icon: p(Q),
|
|
202
202
|
size: e.dense ? "xs" : "md",
|
|
203
203
|
class: c(["transition-transform", {
|
|
204
|
-
"rotate-180": (
|
|
204
|
+
"rotate-180": (i = f.value[l]) == null ? void 0 : i.__expanded
|
|
205
205
|
}])
|
|
206
206
|
}, null, 8, ["icon", "size", "class"])
|
|
207
|
-
], 8,
|
|
207
|
+
], 8, j)
|
|
208
208
|
];
|
|
209
209
|
}),
|
|
210
210
|
_: 2
|
|
211
|
-
}, 1024)) :
|
|
212
|
-
(n(!0),
|
|
213
|
-
key:
|
|
214
|
-
"text-align":
|
|
215
|
-
truncate:
|
|
216
|
-
width:
|
|
211
|
+
}, 1024)) : b("", !0),
|
|
212
|
+
(n(!0), r(g, null, v(e.headers, (i, _) => (n(), k(B, {
|
|
213
|
+
key: _,
|
|
214
|
+
"text-align": i.align,
|
|
215
|
+
truncate: i.truncate,
|
|
216
|
+
width: i.width,
|
|
217
217
|
dense: e.dense,
|
|
218
218
|
fixed: e.fixed
|
|
219
219
|
}, {
|
|
220
|
-
default:
|
|
221
|
-
|
|
222
|
-
|
|
220
|
+
default: u(() => [
|
|
221
|
+
d(e.$slots, `item-${i.value}`, { item: t }, () => [
|
|
222
|
+
C(N(L(t, i.value)), 1)
|
|
223
223
|
])
|
|
224
224
|
]),
|
|
225
225
|
_: 2
|
|
@@ -227,26 +227,29 @@ const Q = { key: 1 }, R = ["colspan"], U = { key: 2 }, Y = ["colspan"], Z = ["on
|
|
|
227
227
|
]),
|
|
228
228
|
_: 2
|
|
229
229
|
}, 1032, ["pointer", "striped", "onClick"]),
|
|
230
|
-
e.expandable ? (n(),
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
230
|
+
e.expandable ? (n(), r("tr", {
|
|
231
|
+
key: 0,
|
|
232
|
+
class: c({ hidden: !((s = f.value[l]) != null && s.__expanded) })
|
|
233
|
+
}, [
|
|
234
|
+
m("td", x, [
|
|
235
|
+
m("div", {
|
|
236
|
+
class: c(["overflow-hidden transition-opacity", [(a = f.value[l]) != null && a.__expanded ? "" : "opacity-0 max-h-0"]])
|
|
234
237
|
}, [
|
|
235
|
-
|
|
238
|
+
d(e.$slots, "expanded-row", { item: t })
|
|
236
239
|
], 2)
|
|
237
240
|
])
|
|
238
|
-
])) :
|
|
241
|
+
], 2)) : b("", !0)
|
|
239
242
|
], 64);
|
|
240
243
|
}), 128))
|
|
241
244
|
]),
|
|
242
245
|
_: 3
|
|
243
246
|
}),
|
|
244
|
-
e.loading ? (n(),
|
|
247
|
+
e.loading ? (n(), r("div", {
|
|
245
248
|
key: 0,
|
|
246
|
-
class: c(
|
|
249
|
+
class: c(p(w).loadingWrapper)
|
|
247
250
|
}, [
|
|
248
|
-
|
|
249
|
-
], 2)) :
|
|
251
|
+
y(G, { size: "lg" })
|
|
252
|
+
], 2)) : b("", !0)
|
|
250
253
|
], 6)
|
|
251
254
|
], 2));
|
|
252
255
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
const i = {
|
|
2
2
|
classes: {
|
|
3
3
|
wrapper: ({ props: e }) => {
|
|
4
|
-
const t = ["
|
|
4
|
+
const t = ["px-3"];
|
|
5
5
|
return t.push(e.dense ? "py-2" : "py-4"), e.textAlign === "left" ? t.push("text-left") : e.textAlign === "center" ? t.push("text-center") : e.textAlign === "right" ? t.push("text-right") : e.textAlign === "justify" && t.push("text-justify"), e.verticalAlign === "baseline" ? t.push("align-baseline") : e.verticalAlign === "bottom" ? t.push("align-bottom") : e.verticalAlign === "middle" ? t.push("align-middle") : e.verticalAlign === "text-bottom" ? t.push("align-text-bottom") : e.verticalAlign === "text-top" ? t.push("align-text-top") : e.verticalAlign === "top" && t.push("align-top"), e.truncate && t.push("truncate"), t;
|
|
6
6
|
}
|
|
7
7
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const
|
|
1
|
+
const e = {
|
|
2
2
|
classes: {
|
|
3
|
-
thead: "align-bottom",
|
|
4
|
-
row: "text-sm text-secondary-600 dark:text-secondary-
|
|
3
|
+
thead: "align-bottom bg-secondary-50 dark:bg-secondary-700",
|
|
4
|
+
row: "text-sm text-secondary-600 dark:text-secondary-200 border-b"
|
|
5
5
|
}
|
|
6
|
-
},
|
|
6
|
+
}, t = e;
|
|
7
7
|
export {
|
|
8
|
-
|
|
8
|
+
t as default
|
|
9
9
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
const s = {
|
|
2
2
|
classes: {
|
|
3
3
|
th: ({ props: e }) => {
|
|
4
|
-
const t = ["relative py-
|
|
4
|
+
const t = ["relative py-3 font-semibold text-xs px-3"];
|
|
5
5
|
return e.sortable && t.push("cursor-pointer hover:text-secondary-800 dark:hover:text-secondary-300 transition-colors duration-150 ease-in-out"), e.stickyHeader && t.push("sticky top-0"), e.textAlign === "left" && t.push("text-left"), e.textAlign === "right" && t.push("text-right"), e.textAlign === "center" && t.push("text-center"), e.textAlign === "justify" && t.push("text-justify"), t;
|
|
6
6
|
},
|
|
7
|
-
sortIcon: ({ props: e }) => ["absolute stroke-2 w-3 h-3 top-
|
|
7
|
+
sortIcon: ({ props: e }) => ["absolute stroke-2 w-3 h-3 top-3.5 right-0.5"]
|
|
8
8
|
}
|
|
9
9
|
}, i = s;
|
|
10
10
|
export {
|
|
@@ -2,7 +2,7 @@ const s = {
|
|
|
2
2
|
classes: {
|
|
3
3
|
row: ({ props: r }) => {
|
|
4
4
|
const e = [];
|
|
5
|
-
return r.striped ? e.push("
|
|
5
|
+
return r.striped ? e.push("even:bg-secondary-50 dark:even:bg-secondary-700") : e.push("border-b border-secondary-200 dark:border-secondary-700"), r.pointer && e.push("hover:bg-secondary-50 dark:hover:bg-secondary-700 cursor-pointer"), e;
|
|
6
6
|
}
|
|
7
7
|
}
|
|
8
8
|
}, o = s;
|
|
@@ -18,7 +18,10 @@ declare const textareaProps: {
|
|
|
18
18
|
preventEnter: BooleanConstructor;
|
|
19
19
|
block: BooleanConstructor;
|
|
20
20
|
resizable: BooleanConstructor;
|
|
21
|
-
modelValue:
|
|
21
|
+
modelValue: {
|
|
22
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
23
|
+
readonly default: undefined;
|
|
24
|
+
};
|
|
22
25
|
id: StringConstructor;
|
|
23
26
|
name: StringConstructor;
|
|
24
27
|
readonly: BooleanConstructor;
|
|
@@ -74,7 +77,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
74
77
|
preventEnter: BooleanConstructor;
|
|
75
78
|
block: BooleanConstructor;
|
|
76
79
|
resizable: BooleanConstructor;
|
|
77
|
-
modelValue:
|
|
80
|
+
modelValue: {
|
|
81
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
82
|
+
readonly default: undefined;
|
|
83
|
+
};
|
|
78
84
|
id: StringConstructor;
|
|
79
85
|
name: StringConstructor;
|
|
80
86
|
readonly: BooleanConstructor;
|
|
@@ -128,7 +134,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
128
134
|
preventEnter: BooleanConstructor;
|
|
129
135
|
block: BooleanConstructor;
|
|
130
136
|
resizable: BooleanConstructor;
|
|
131
|
-
modelValue:
|
|
137
|
+
modelValue: {
|
|
138
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
139
|
+
readonly default: undefined;
|
|
140
|
+
};
|
|
132
141
|
id: StringConstructor;
|
|
133
142
|
name: StringConstructor;
|
|
134
143
|
readonly: BooleanConstructor;
|
|
@@ -166,6 +175,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
166
175
|
block: boolean;
|
|
167
176
|
loading: boolean;
|
|
168
177
|
loadingStatus: import("../loader/Loader.vue").LoaderStatus;
|
|
178
|
+
modelValue: string | number | boolean | object | any[] | undefined;
|
|
169
179
|
readonly: boolean;
|
|
170
180
|
required: boolean;
|
|
171
181
|
validateOnInput: boolean;
|
|
@@ -40,28 +40,28 @@ const U = ["id", "disabled", "max", "maxlength", "min", "dir", "rows", "minlengt
|
|
|
40
40
|
emits: s.emits(),
|
|
41
41
|
setup(f, { expose: c, emit: h }) {
|
|
42
42
|
const t = f, b = h, o = P(null);
|
|
43
|
-
O(o,
|
|
44
|
-
setTimeout(
|
|
43
|
+
O(o, n), typeof window < "u" && X(window, "resize", n), q([() => t.modelValue, () => t.size], () => {
|
|
44
|
+
setTimeout(n);
|
|
45
45
|
});
|
|
46
46
|
const g = A("textarea"), y = J().getPalette("primary"), v = g.get("border", y[400]);
|
|
47
47
|
function w() {
|
|
48
|
-
|
|
48
|
+
n();
|
|
49
49
|
}
|
|
50
50
|
function S(e) {
|
|
51
51
|
t.preventEnter && e.preventDefault(), e.stopPropagation();
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function n() {
|
|
54
54
|
t.adjustToText && o.value && (o.value.style.height = "1px", o.value.style.height = 2 + o.value.scrollHeight + "px");
|
|
55
55
|
}
|
|
56
56
|
const { focus: a, blur: k } = p(o), {
|
|
57
|
-
errorInternal:
|
|
57
|
+
errorInternal: l,
|
|
58
58
|
hideFooterInternal: N,
|
|
59
59
|
isInsideForm: T,
|
|
60
60
|
inputListeners: z,
|
|
61
61
|
reset: C,
|
|
62
62
|
validate: B,
|
|
63
63
|
setError: E
|
|
64
|
-
} = s(t, { focus: a, emit: b }), { styles: I, classes: i, className: V } = G("Textarea", {}, t, { errorInternal:
|
|
64
|
+
} = s(t, { focus: a, emit: b }), { styles: I, classes: i, className: V } = G("Textarea", {}, t, { errorInternal: l });
|
|
65
65
|
return c({ focus: a, blur: k, reset: C, validate: B, setError: E }), (e, _) => (m(), d(M, {
|
|
66
66
|
style: K(r(I)),
|
|
67
67
|
block: e.block,
|
|
@@ -82,7 +82,7 @@ const U = ["id", "disabled", "max", "maxlength", "min", "dir", "rows", "minlengt
|
|
|
82
82
|
ref: o,
|
|
83
83
|
class: ["", [
|
|
84
84
|
r(i).input,
|
|
85
|
-
r(
|
|
85
|
+
r(l) ? "border-error-500 dark:border-error-400 focus:outline-error-500" : "focus:outline-[color:var(--x-textarea-border)]"
|
|
86
86
|
]],
|
|
87
87
|
style: r(v),
|
|
88
88
|
disabled: e.disabled,
|
|
@@ -95,14 +95,14 @@ const U = ["id", "disabled", "max", "maxlength", "min", "dir", "rows", "minlengt
|
|
|
95
95
|
name: e.name,
|
|
96
96
|
placeholder: e.placeholder,
|
|
97
97
|
readonly: e.readonly,
|
|
98
|
-
value: e.modelValue ? String(e.modelValue) : ""
|
|
98
|
+
value: typeof e.modelValue < "u" ? String(e.modelValue) : ""
|
|
99
99
|
}, L(r(z), !0), {
|
|
100
100
|
onKeydown: $(S, ["enter"]),
|
|
101
101
|
onInput: w
|
|
102
102
|
}), null, 16, U),
|
|
103
103
|
r(N) ? D("", !0) : (m(), d(Q, {
|
|
104
104
|
key: 0,
|
|
105
|
-
error: r(
|
|
105
|
+
error: r(l),
|
|
106
106
|
helper: e.helper
|
|
107
107
|
}, null, 8, ["error", "helper"]))
|
|
108
108
|
]),
|
|
@@ -3,7 +3,7 @@ const a = {
|
|
|
3
3
|
wrapper: "",
|
|
4
4
|
input: ({ props: s, data: r }) => {
|
|
5
5
|
const e = ["appearance-none block w-full placeholder-secondary-400 dark:placeholder-secondary-500 outline-transparent outline outline-2 outline-offset-[-1px] transition duration-150 ease-in-out border-secondary-300 dark:border-secondary-700 border shadow-sm rounded-md"];
|
|
6
|
-
return s.resizable || e.push("resize-none"), !r.errorInternal && !s.disabled && e.push("hover:border-secondary-400 dark:hover:border-secondary-500"), s.size === "xs" ? e.push("px-2 py-1 text-xs") : s.size === "sm" ? e.push("px-2 py-
|
|
6
|
+
return s.resizable || e.push("resize-none"), !r.errorInternal && !s.disabled && e.push("hover:border-secondary-400 dark:hover:border-secondary-500"), s.size === "xs" ? e.push("px-2 py-1 text-xs") : s.size === "sm" ? e.push("px-2 py-1.5 text-sm") : s.size === "lg" ? e.push("px-4 py-3 text-lg") : s.size === "xl" ? e.push("px-5 py-4 text-xl") : e.push("px-3 py-2"), e.push(s.disabled ? "bg-secondary-100 dark:bg-secondary-700 text-secondary-400 dark:text-secondary-600 cursor-not-allowed" : "bg-white dark:bg-secondary-800 text-secondary-700 dark:text-secondary-200"), e;
|
|
7
7
|
}
|
|
8
8
|
}
|
|
9
9
|
}, t = a;
|
|
@@ -2,7 +2,10 @@ import { type ExtractPublicPropTypes } from 'vue';
|
|
|
2
2
|
import { type ThemeComponent } from '../../composables/useTheme';
|
|
3
3
|
declare const toggleProps: {
|
|
4
4
|
glow: BooleanConstructor;
|
|
5
|
-
modelValue:
|
|
5
|
+
modelValue: {
|
|
6
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
7
|
+
readonly default: undefined;
|
|
8
|
+
};
|
|
6
9
|
id: StringConstructor;
|
|
7
10
|
name: StringConstructor;
|
|
8
11
|
readonly: BooleanConstructor;
|
|
@@ -43,7 +46,10 @@ export interface ToggleTheme extends ThemeComponent<ToggleProps, InternalClasses
|
|
|
43
46
|
}
|
|
44
47
|
declare const _default: import("vue").DefineComponent<{
|
|
45
48
|
glow: BooleanConstructor;
|
|
46
|
-
modelValue:
|
|
49
|
+
modelValue: {
|
|
50
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
51
|
+
readonly default: undefined;
|
|
52
|
+
};
|
|
47
53
|
id: StringConstructor;
|
|
48
54
|
name: StringConstructor;
|
|
49
55
|
readonly: BooleanConstructor;
|
|
@@ -85,7 +91,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
85
91
|
setError: (val: string) => void;
|
|
86
92
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, string[], string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
87
93
|
glow: BooleanConstructor;
|
|
88
|
-
modelValue:
|
|
94
|
+
modelValue: {
|
|
95
|
+
readonly type: import("vue").PropType<string | number | boolean | object | any[] | undefined>;
|
|
96
|
+
readonly default: undefined;
|
|
97
|
+
};
|
|
89
98
|
id: StringConstructor;
|
|
90
99
|
name: StringConstructor;
|
|
91
100
|
readonly: BooleanConstructor;
|
|
@@ -128,6 +137,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
128
137
|
size: import("../../composables/useCommon").Size;
|
|
129
138
|
loading: boolean;
|
|
130
139
|
loadingStatus: import("../loader/Loader.vue").LoaderStatus;
|
|
140
|
+
modelValue: string | number | boolean | object | any[] | undefined;
|
|
131
141
|
readonly: boolean;
|
|
132
142
|
required: boolean;
|
|
133
143
|
validateOnInput: boolean;
|