adverich-kun-ui 0.1.79 → 0.1.80
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/dist/adverich-kun-ui.css +1 -1
- package/dist/components/KunAlert/src/components/KunAlert.vue.js +18 -18
- package/dist/components/KunAppbar/src/components/KunAppbar.vue.js +37 -33
- package/dist/components/KunAppbarTitle/src/components/KunAppbarTitle.vue.js +9 -9
- package/dist/components/KunBudge/src/components/KunBudge.vue.js +19 -14
- package/dist/components/KunCard/src/components/KunCard.vue.js +35 -41
- package/dist/components/KunCardActions/src/components/KunCardActions.vue.js +13 -14
- package/dist/components/KunCardItem/src/components/KunCardItem.vue.js +13 -14
- package/dist/components/KunCardSubtitle/src/components/KunCardSubtitle.vue.js +12 -15
- package/dist/components/KunCardText/src/components/KunCardText.vue.js +14 -15
- package/dist/components/KunCardTitle/src/components/KunCardTitle.vue.js +40 -44
- package/dist/components/KunChip/src/components/KunChip.vue.js +35 -35
- package/dist/components/KunChip/src/composables/useChip.js +5 -5
- package/dist/components/KunCol/src/components/KunCol.vue.js +9 -11
- package/dist/components/KunContainer/src/components/KunContainer.vue.js +14 -25
- package/dist/components/KunDivider/src/components/KunDivider.vue.js +11 -11
- package/dist/components/KunForm/src/components/KunForm.vue.js +17 -17
- package/dist/components/KunIcon/src/components/KunIcon.vue.js +19 -19
- package/dist/components/KunList/src/components/KunList.vue.js +36 -31
- package/dist/components/KunListGroup/src/components/KunListGroup.vue.js +75 -23
- package/dist/components/KunListImg/src/components/KunListImg.vue.js +17 -17
- package/dist/components/KunListItem/src/components/KunListItem.vue.js +37 -29
- package/dist/components/KunListItemAction/src/components/KunListItemAction.vue.js +25 -18
- package/dist/components/KunListItemAvatar/src/components/KunListItemAvatar.vue.js +42 -20
- package/dist/components/KunListItemSubtitle/src/components/KunListItemSubtitle.vue.js +26 -17
- package/dist/components/KunListItemText/src/components/KunListItemText.vue.js +18 -19
- package/dist/components/KunListItemTitle/src/components/KunListItemTitle.vue.js +17 -18
- package/dist/components/KunListSubheader/src/components/KunListSubheader.vue.js +25 -17
- package/dist/components/KunLoaderCircular/src/components/KunLoaderCircular.vue.js +4 -4
- package/dist/components/KunRow/src/components/KunRow.vue.js +8 -10
- package/dist/components/KunSlider/src/components/KunSlider.vue.js +22 -23
- package/dist/components/KunSpacer/src/components/KunSpacer.vue.js +5 -5
- package/dist/components/KunSwitch/src/components/KunSwitch.vue.js +25 -25
- package/dist/components/KunTooltip/src/components/KunTooltip.vue.js +26 -26
- package/dist/index.js +24 -24
- package/package.json +1 -1
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { kunCardItemProps as
|
|
3
|
-
const
|
|
1
|
+
import { computed as s, createElementBlock as l, openBlock as n, mergeProps as p, renderSlot as a } from "vue";
|
|
2
|
+
import { kunCardItemProps as c } from "../composables/kunCardItemProps.js";
|
|
3
|
+
const d = {
|
|
4
4
|
__name: "KunCardItem",
|
|
5
|
-
props:
|
|
6
|
-
setup(
|
|
7
|
-
const e =
|
|
5
|
+
props: c,
|
|
6
|
+
setup(o) {
|
|
7
|
+
const e = o, t = s(() => [
|
|
8
8
|
"flex",
|
|
9
9
|
"flex-col",
|
|
10
10
|
e.dense ? "py-1 px-2" : "py-3 px-4",
|
|
11
|
-
e.gap
|
|
12
|
-
r.class
|
|
11
|
+
e.gap
|
|
13
12
|
].filter(Boolean));
|
|
14
|
-
return (
|
|
15
|
-
class:
|
|
16
|
-
}, [
|
|
17
|
-
|
|
18
|
-
],
|
|
13
|
+
return (r, m) => (n(), l("div", p({
|
|
14
|
+
class: ["w-full", t.value]
|
|
15
|
+
}, r.$attrs), [
|
|
16
|
+
a(r.$slots, "default")
|
|
17
|
+
], 16));
|
|
19
18
|
}
|
|
20
19
|
};
|
|
21
20
|
export {
|
|
22
|
-
|
|
21
|
+
d as default
|
|
23
22
|
};
|
|
@@ -1,22 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { kunCardSubtitleProps as
|
|
1
|
+
import { computed as s, createElementBlock as l, openBlock as n, mergeProps as a, renderSlot as p, createTextVNode as u, toDisplayString as c } from "vue";
|
|
2
|
+
import { kunCardSubtitleProps as i } from "../composables/kunCardSubtitleProps.js";
|
|
3
3
|
const S = {
|
|
4
4
|
__name: "KunCardSubtitle",
|
|
5
|
-
props:
|
|
6
|
-
setup(
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
o.class
|
|
5
|
+
props: i,
|
|
6
|
+
setup(o) {
|
|
7
|
+
const e = o, r = s(() => [
|
|
8
|
+
e.color,
|
|
9
|
+
e.dense ? "text-xs" : "text-sm",
|
|
10
|
+
e.fontWeight
|
|
12
11
|
].filter(Boolean));
|
|
13
|
-
return (
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
p(e.$slots, "default", {}, () => [
|
|
17
|
-
i(m(e.subtitle), 1)
|
|
12
|
+
return (t, m) => (n(), l("div", a({ class: r.value }, t.$attrs), [
|
|
13
|
+
p(t.$slots, "default", {}, () => [
|
|
14
|
+
u(c(t.subtitle), 1)
|
|
18
15
|
])
|
|
19
|
-
],
|
|
16
|
+
], 16));
|
|
20
17
|
}
|
|
21
18
|
};
|
|
22
19
|
export {
|
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { kunCardTextProps as
|
|
3
|
-
const
|
|
1
|
+
import { computed as s, createElementBlock as a, openBlock as n, mergeProps as l, renderSlot as p, createTextVNode as c, toDisplayString as m } from "vue";
|
|
2
|
+
import { kunCardTextProps as u } from "../composables/kunCardTextProps.js";
|
|
3
|
+
const f = {
|
|
4
4
|
__name: "KunCardText",
|
|
5
|
-
props:
|
|
6
|
-
setup(
|
|
7
|
-
const t =
|
|
5
|
+
props: u,
|
|
6
|
+
setup(r) {
|
|
7
|
+
const t = r, o = s(() => [
|
|
8
8
|
t.color,
|
|
9
|
-
t.dense ? "text-xs" : "text-sm"
|
|
10
|
-
o.class
|
|
9
|
+
t.dense ? "text-xs" : "text-sm"
|
|
11
10
|
].filter(Boolean));
|
|
12
|
-
return (e,
|
|
13
|
-
class:
|
|
14
|
-
}, [
|
|
15
|
-
|
|
16
|
-
m(
|
|
11
|
+
return (e, d) => (n(), a("div", l({
|
|
12
|
+
class: ["block", o.value]
|
|
13
|
+
}, e.$attrs), [
|
|
14
|
+
p(e.$slots, "default", {}, () => [
|
|
15
|
+
c(m(e.text), 1)
|
|
17
16
|
])
|
|
18
|
-
],
|
|
17
|
+
], 16));
|
|
19
18
|
}
|
|
20
19
|
};
|
|
21
20
|
export {
|
|
22
|
-
|
|
21
|
+
f as default
|
|
23
22
|
};
|
|
@@ -1,73 +1,69 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { kunCardTitleProps as
|
|
1
|
+
import { computed as n, createElementBlock as r, openBlock as o, mergeProps as $, createCommentVNode as s, createElementVNode as l, renderSlot as d, createBlock as p, normalizeClass as a, createTextVNode as i, toDisplayString as u } from "vue";
|
|
2
|
+
import { kunCardTitleProps as b } from "../composables/kunCardTitleProps.js";
|
|
3
3
|
import m from "../../../KunIcon/src/components/KunIcon.vue.js";
|
|
4
4
|
/* empty css */
|
|
5
|
-
import
|
|
6
|
-
const
|
|
5
|
+
import v from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
6
|
+
const C = {
|
|
7
7
|
key: 0,
|
|
8
8
|
class: "kun-card-title__prepend"
|
|
9
|
-
},
|
|
9
|
+
}, g = { class: "kun-card-title__content" }, _ = {
|
|
10
10
|
key: 1,
|
|
11
11
|
class: "kun-card-title__append"
|
|
12
|
-
},
|
|
12
|
+
}, w = {
|
|
13
13
|
__name: "KunCardTitle",
|
|
14
|
-
props:
|
|
15
|
-
setup(
|
|
16
|
-
const
|
|
14
|
+
props: b,
|
|
15
|
+
setup(c) {
|
|
16
|
+
const t = c, h = n(() => [
|
|
17
17
|
"kun-card-title",
|
|
18
18
|
t.dense ? "py-1 px-2 text-sm" : "py-3 px-4 text-base",
|
|
19
19
|
t.flat ? "shadow-none" : "shadow",
|
|
20
20
|
t.rounded === !0 ? "rounded-md" : t.rounded ? `rounded-${t.rounded}` : "",
|
|
21
21
|
t.bgColor,
|
|
22
|
-
t.textColor
|
|
23
|
-
|
|
24
|
-
// External class
|
|
25
|
-
].filter(Boolean)), y = n(() => ({
|
|
22
|
+
t.textColor
|
|
23
|
+
].filter(Boolean)), f = n(() => ({
|
|
26
24
|
height: typeof t.height == "number" ? `${t.height}px` : t.height,
|
|
27
|
-
width: typeof t.width == "number" ? `${t.width}px` : t.width
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
l(e.$slots, "prepend", {}, () => [
|
|
37
|
-
e.prepend ? (s(), p(m, {
|
|
25
|
+
width: typeof t.width == "number" ? `${t.width}px` : t.width
|
|
26
|
+
})), k = n(() => t.dense ? "font-medium" : "font-semibold"), y = n(() => "text-xs opacity-75 mt-1");
|
|
27
|
+
return (e, B) => (o(), r("div", $({
|
|
28
|
+
class: h.value,
|
|
29
|
+
style: f.value
|
|
30
|
+
}, e.$attrs), [
|
|
31
|
+
e.$slots.prepend || e.prepend ? (o(), r("div", C, [
|
|
32
|
+
d(e.$slots, "prepend", {}, () => [
|
|
33
|
+
e.prepend ? (o(), p(m, {
|
|
38
34
|
key: 0,
|
|
39
35
|
icon: e.prepend
|
|
40
|
-
}, null, 8, ["icon"])) :
|
|
36
|
+
}, null, 8, ["icon"])) : s("", !0)
|
|
41
37
|
], !0)
|
|
42
|
-
])) :
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
class:
|
|
38
|
+
])) : s("", !0),
|
|
39
|
+
l("div", g, [
|
|
40
|
+
l("h3", {
|
|
41
|
+
class: a(k.value)
|
|
46
42
|
}, [
|
|
47
|
-
|
|
48
|
-
u(
|
|
43
|
+
d(e.$slots, "default", {}, () => [
|
|
44
|
+
i(u(e.title), 1)
|
|
49
45
|
], !0)
|
|
50
46
|
], 2),
|
|
51
|
-
e.$slots.subtitle || e.subtitle ? (
|
|
47
|
+
e.$slots.subtitle || e.subtitle ? (o(), r("div", {
|
|
52
48
|
key: 0,
|
|
53
|
-
class:
|
|
49
|
+
class: a(y.value)
|
|
54
50
|
}, [
|
|
55
|
-
|
|
56
|
-
u(
|
|
51
|
+
d(e.$slots, "subtitle", {}, () => [
|
|
52
|
+
i(u(e.subtitle), 1)
|
|
57
53
|
], !0)
|
|
58
|
-
], 2)) :
|
|
54
|
+
], 2)) : s("", !0)
|
|
59
55
|
]),
|
|
60
|
-
e.$slots.append || e.append ? (
|
|
61
|
-
|
|
62
|
-
e.append ? (
|
|
56
|
+
e.$slots.append || e.append ? (o(), r("div", _, [
|
|
57
|
+
d(e.$slots, "append", {}, () => [
|
|
58
|
+
e.append ? (o(), p(m, {
|
|
63
59
|
key: 0,
|
|
64
60
|
icon: e.append
|
|
65
|
-
}, null, 8, ["icon"])) :
|
|
61
|
+
}, null, 8, ["icon"])) : s("", !0)
|
|
66
62
|
], !0)
|
|
67
|
-
])) :
|
|
68
|
-
],
|
|
63
|
+
])) : s("", !0)
|
|
64
|
+
], 16));
|
|
69
65
|
}
|
|
70
|
-
},
|
|
66
|
+
}, K = /* @__PURE__ */ v(w, [["__scopeId", "data-v-31498302"]]);
|
|
71
67
|
export {
|
|
72
|
-
|
|
68
|
+
K as default
|
|
73
69
|
};
|
|
@@ -1,76 +1,76 @@
|
|
|
1
|
-
import { useAttrs as
|
|
2
|
-
import { kunChipProps as
|
|
3
|
-
import { useChip as
|
|
1
|
+
import { useAttrs as _, computed as d, createBlock as r, openBlock as o, resolveDynamicComponent as g, unref as s, mergeProps as B, withModifiers as u, withCtx as N, createElementBlock as p, createCommentVNode as t, createElementVNode as A, renderSlot as l, createTextVNode as w, toDisplayString as D, createVNode as E } from "vue";
|
|
2
|
+
import { kunChipProps as K } from "../composables/kunChipProps.js";
|
|
3
|
+
import { useChip as L } from "../composables/useChip.js";
|
|
4
4
|
import a from "../../../KunIcon/src/components/KunIcon.vue.js";
|
|
5
5
|
/* empty css */
|
|
6
|
-
import
|
|
7
|
-
const
|
|
6
|
+
import P from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
7
|
+
const S = {
|
|
8
8
|
key: 0,
|
|
9
9
|
class: "kun-chip__prepend mr-1"
|
|
10
|
-
},
|
|
10
|
+
}, T = { class: "kun-chip__content truncate" }, M = {
|
|
11
11
|
key: 1,
|
|
12
12
|
class: "kun-chip__append ml-1"
|
|
13
|
-
},
|
|
13
|
+
}, j = ["aria-label"], q = {
|
|
14
14
|
__name: "KunChip",
|
|
15
|
-
props:
|
|
15
|
+
props: K,
|
|
16
16
|
emits: ["update:modelValue", "click:close"],
|
|
17
17
|
setup(c, { emit: m }) {
|
|
18
|
-
const k = c, f = m,
|
|
19
|
-
componentTag:
|
|
20
|
-
componentAttrs:
|
|
21
|
-
computedClass:
|
|
22
|
-
isLink:
|
|
23
|
-
handleClose:
|
|
24
|
-
} =
|
|
18
|
+
const k = c, f = m, h = _(), {
|
|
19
|
+
componentTag: b,
|
|
20
|
+
componentAttrs: C,
|
|
21
|
+
computedClass: v,
|
|
22
|
+
isLink: y,
|
|
23
|
+
handleClose: i
|
|
24
|
+
} = L(k, f), $ = d(() => [
|
|
25
25
|
"kun-chip",
|
|
26
|
-
...
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
disabled: !s(
|
|
26
|
+
...v.value
|
|
27
|
+
].filter(Boolean)), I = d(() => ({
|
|
28
|
+
...h,
|
|
29
|
+
...C.value
|
|
30
|
+
}));
|
|
31
|
+
return (e, n) => (o(), r(g(s(b)), B({ class: $.value }, I.value, {
|
|
32
|
+
disabled: !s(y) && e.disabled ? !0 : void 0,
|
|
33
33
|
onClick: n[1] || (n[1] = u(() => {
|
|
34
34
|
}, ["stop"]))
|
|
35
35
|
}), {
|
|
36
36
|
default: N(() => [
|
|
37
|
-
e.$slots.prepend || e.prependIcon ? (o(),
|
|
37
|
+
e.$slots.prepend || e.prependIcon ? (o(), p("div", S, [
|
|
38
38
|
l(e.$slots, "prepend", {}, () => [
|
|
39
|
-
e.prependIcon ? (o(),
|
|
39
|
+
e.prependIcon ? (o(), r(a, {
|
|
40
40
|
key: 0,
|
|
41
41
|
icon: e.prependIcon
|
|
42
42
|
}, null, 8, ["icon"])) : t("", !0)
|
|
43
43
|
], !0)
|
|
44
44
|
])) : t("", !0),
|
|
45
|
-
|
|
45
|
+
A("div", T, [
|
|
46
46
|
e.$slots.default ? l(e.$slots, "default", { key: 0 }, () => [
|
|
47
|
-
w(
|
|
47
|
+
w(D(e.label || e.text), 1)
|
|
48
48
|
], !0) : t("", !0)
|
|
49
49
|
]),
|
|
50
|
-
e.$slots.append || e.appendIcon ? (o(),
|
|
50
|
+
e.$slots.append || e.appendIcon ? (o(), p("div", M, [
|
|
51
51
|
l(e.$slots, "append", {}, () => [
|
|
52
|
-
e.appendIcon ? (o(),
|
|
52
|
+
e.appendIcon ? (o(), r(a, {
|
|
53
53
|
key: 0,
|
|
54
54
|
icon: e.appendIcon
|
|
55
55
|
}, null, 8, ["icon"])) : t("", !0)
|
|
56
56
|
], !0)
|
|
57
57
|
])) : t("", !0),
|
|
58
|
-
e.closable && e.modelValue ? (o(),
|
|
58
|
+
e.closable && e.modelValue ? (o(), p("button", {
|
|
59
59
|
key: 2,
|
|
60
60
|
type: "button",
|
|
61
61
|
class: "kun-chip__close ml-1",
|
|
62
62
|
"aria-label": e.closeLabel,
|
|
63
|
-
onClick: n[0] || (n[0] = u((...
|
|
63
|
+
onClick: n[0] || (n[0] = u((...V) => s(i) && s(i)(...V), ["stop", "prevent"]))
|
|
64
64
|
}, [
|
|
65
65
|
l(e.$slots, "close", {}, () => [
|
|
66
|
-
|
|
66
|
+
E(a, { icon: "$mdi-close" })
|
|
67
67
|
], !0)
|
|
68
|
-
], 8,
|
|
68
|
+
], 8, j)) : t("", !0)
|
|
69
69
|
]),
|
|
70
70
|
_: 3
|
|
71
|
-
}, 16, ["class", "
|
|
71
|
+
}, 16, ["class", "disabled"]));
|
|
72
72
|
}
|
|
73
|
-
},
|
|
73
|
+
}, Q = /* @__PURE__ */ P(q, [["__scopeId", "data-v-b85baefa"]]);
|
|
74
74
|
export {
|
|
75
|
-
|
|
75
|
+
Q as default
|
|
76
76
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { computed as r } from "vue";
|
|
2
|
-
function
|
|
3
|
-
const n = r(() => !!e.to || !!e.href),
|
|
2
|
+
function d(e, l) {
|
|
3
|
+
const n = r(() => !!e.to || !!e.href), o = r(() => e.href ? "a" : e.to ? "router-link" : "div"), a = r(() => e.href ? {
|
|
4
4
|
href: e.href,
|
|
5
5
|
target: e.target ?? "_self",
|
|
6
6
|
rel: e.target === "_blank" ? "noopener noreferrer" : null
|
|
@@ -26,8 +26,8 @@ function s(e, l, c) {
|
|
|
26
26
|
});
|
|
27
27
|
return {
|
|
28
28
|
isLink: n,
|
|
29
|
-
componentTag:
|
|
30
|
-
componentAttrs:
|
|
29
|
+
componentTag: o,
|
|
30
|
+
componentAttrs: a,
|
|
31
31
|
computedClass: u,
|
|
32
32
|
handleClose: (t) => {
|
|
33
33
|
e.disabled || (l("update:modelValue", !1), l("click:close", t));
|
|
@@ -35,5 +35,5 @@ function s(e, l, c) {
|
|
|
35
35
|
};
|
|
36
36
|
}
|
|
37
37
|
export {
|
|
38
|
-
|
|
38
|
+
d as useChip
|
|
39
39
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { inject as
|
|
1
|
+
import { inject as p, computed as d, createElementBlock as g, openBlock as x, mergeProps as $, renderSlot as S } from "vue";
|
|
2
2
|
const v = {
|
|
3
3
|
__name: "KunCol",
|
|
4
4
|
props: {
|
|
@@ -8,11 +8,11 @@ const v = {
|
|
|
8
8
|
lg: String,
|
|
9
9
|
xl: String
|
|
10
10
|
},
|
|
11
|
-
setup(
|
|
12
|
-
const i =
|
|
11
|
+
setup(a) {
|
|
12
|
+
const i = a, m = p("noGutters", !1), u = p("dense", !1), f = d(() => {
|
|
13
13
|
const s = [];
|
|
14
14
|
m || s.push(u ? "p-1" : "p-2");
|
|
15
|
-
const
|
|
15
|
+
const l = ["cols", "sm", "md", "lg", "xl"], c = {
|
|
16
16
|
cols: "",
|
|
17
17
|
sm: "sm",
|
|
18
18
|
md: "md",
|
|
@@ -20,10 +20,10 @@ const v = {
|
|
|
20
20
|
xl: "xl"
|
|
21
21
|
};
|
|
22
22
|
let r = "0";
|
|
23
|
-
return
|
|
23
|
+
return l.forEach((t) => {
|
|
24
24
|
const e = i[t];
|
|
25
25
|
if (e) {
|
|
26
|
-
const
|
|
26
|
+
const o = c[t], n = o ? `${o}:col-span-${e}` : `col-span-${e}`;
|
|
27
27
|
s.push(n), r = e;
|
|
28
28
|
} else {
|
|
29
29
|
const n = `${c[t]}:col-span-${r}`;
|
|
@@ -31,11 +31,9 @@ const v = {
|
|
|
31
31
|
}
|
|
32
32
|
}), [...s].join(" ");
|
|
33
33
|
});
|
|
34
|
-
return (s,
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
$(s.$slots, "default")
|
|
38
|
-
], 2));
|
|
34
|
+
return (s, l) => (x(), g("div", $({ class: f.value }, s.$attrs), [
|
|
35
|
+
S(s.$slots, "default")
|
|
36
|
+
], 16));
|
|
39
37
|
}
|
|
40
38
|
};
|
|
41
39
|
export {
|
|
@@ -1,41 +1,30 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
const
|
|
1
|
+
import { computed as c, createElementBlock as n, openBlock as o, mergeProps as p, renderSlot as f } from "vue";
|
|
2
|
+
const u = {
|
|
3
3
|
__name: "KunContainer",
|
|
4
4
|
props: {
|
|
5
5
|
fluid: {
|
|
6
6
|
type: Boolean,
|
|
7
7
|
default: !1
|
|
8
|
-
},
|
|
9
|
-
class: {
|
|
10
|
-
type: [String, Array, Object],
|
|
11
|
-
default: null
|
|
12
|
-
},
|
|
13
|
-
style: {
|
|
14
|
-
type: Object,
|
|
15
|
-
default: null
|
|
16
8
|
}
|
|
17
9
|
},
|
|
18
|
-
setup(
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
return
|
|
10
|
+
setup(l) {
|
|
11
|
+
const s = l, r = c(() => {
|
|
12
|
+
const e = ["w-full", "mx-auto", "px-4", "sm:px-6", "lg:px-8"];
|
|
13
|
+
return s.fluid || e.push(
|
|
22
14
|
"max-w-screen-sm",
|
|
23
15
|
"sm:max-w-screen-md",
|
|
24
16
|
"md:max-w-screen-lg",
|
|
25
17
|
"lg:max-w-screen-xl",
|
|
26
18
|
"xl:max-w-screen-2xl"
|
|
27
|
-
),
|
|
28
|
-
|
|
29
|
-
})),
|
|
30
|
-
})
|
|
31
|
-
return (
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
}, [
|
|
35
|
-
i(s.$slots, "default")
|
|
36
|
-
], 6));
|
|
19
|
+
), s.class && (Array.isArray(s.class) ? e.push(...s.class) : typeof s.class == "string" ? e.push(...s.class.split(" ")) : typeof s.class == "object" && Object.entries(s.class).forEach(([a, t]) => {
|
|
20
|
+
t && e.push(a);
|
|
21
|
+
})), e;
|
|
22
|
+
});
|
|
23
|
+
return (e, a) => (o(), n("div", p({ class: r.value }, e.$attrs), [
|
|
24
|
+
f(e.$slots, "default")
|
|
25
|
+
], 16));
|
|
37
26
|
}
|
|
38
27
|
};
|
|
39
28
|
export {
|
|
40
|
-
|
|
29
|
+
u as default
|
|
41
30
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
const
|
|
1
|
+
import { computed as l, createElementBlock as o, openBlock as a, mergeProps as c } from "vue";
|
|
2
|
+
const i = {
|
|
3
3
|
__name: "KunDivider",
|
|
4
4
|
props: {
|
|
5
5
|
vertical: Boolean,
|
|
@@ -12,23 +12,23 @@ const s = {
|
|
|
12
12
|
}
|
|
13
13
|
},
|
|
14
14
|
setup(e) {
|
|
15
|
-
const t = e, n =
|
|
16
|
-
const
|
|
17
|
-
return t.vertical ? { height:
|
|
15
|
+
const t = e, n = l(() => {
|
|
16
|
+
const r = t.length != null ? typeof t.length == "number" ? `${t.length}px` : t.length : void 0;
|
|
17
|
+
return t.vertical ? { height: r } : { width: r };
|
|
18
18
|
});
|
|
19
|
-
return (
|
|
19
|
+
return (r, u) => (a(), o("div", c({
|
|
20
20
|
role: "separator",
|
|
21
|
-
class:
|
|
21
|
+
class: [
|
|
22
22
|
"shrink-0",
|
|
23
23
|
e.vertical ? "w-px h-full" : "h-px w-full",
|
|
24
24
|
e.dashed ? "border border-dashed border-current bg-transparent" : "bg-current",
|
|
25
25
|
e.inset ? e.vertical ? "ml-4" : "mx-4" : "",
|
|
26
26
|
e.color
|
|
27
|
-
]
|
|
28
|
-
style:
|
|
29
|
-
}, null,
|
|
27
|
+
],
|
|
28
|
+
style: n.value
|
|
29
|
+
}, r.$attrs), null, 16));
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
export {
|
|
33
|
-
|
|
33
|
+
i as default
|
|
34
34
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ref as
|
|
2
|
-
const
|
|
1
|
+
import { ref as l, provide as s, createElementBlock as v, openBlock as g, mergeProps as h, withModifiers as y, renderSlot as x } from "vue";
|
|
2
|
+
const w = {
|
|
3
3
|
__name: "KunForm",
|
|
4
4
|
props: {
|
|
5
5
|
gap: {
|
|
@@ -16,20 +16,20 @@ const F = {
|
|
|
16
16
|
}
|
|
17
17
|
},
|
|
18
18
|
setup(o, { expose: u }) {
|
|
19
|
-
const i = o, t =
|
|
19
|
+
const i = o, t = l([]), r = l(!0);
|
|
20
20
|
function d(e) {
|
|
21
21
|
t.value.push(e);
|
|
22
22
|
}
|
|
23
|
-
function
|
|
23
|
+
function f(e) {
|
|
24
24
|
t.value = t.value.filter((a) => a !== e);
|
|
25
25
|
}
|
|
26
|
-
async function
|
|
26
|
+
async function n() {
|
|
27
27
|
const e = await Promise.all(
|
|
28
28
|
t.value.map(async (a) => await a.validate())
|
|
29
29
|
);
|
|
30
30
|
return r.value = e.every((a) => a === !0), { valid: r.value };
|
|
31
31
|
}
|
|
32
|
-
function
|
|
32
|
+
function c() {
|
|
33
33
|
t.value.forEach((e) => {
|
|
34
34
|
e.reset && e.reset();
|
|
35
35
|
});
|
|
@@ -40,23 +40,23 @@ const F = {
|
|
|
40
40
|
});
|
|
41
41
|
}
|
|
42
42
|
function m() {
|
|
43
|
-
|
|
43
|
+
n().then(({ valid: e }) => {
|
|
44
44
|
e && $emit("submit");
|
|
45
45
|
});
|
|
46
46
|
}
|
|
47
|
-
return s("registerField", d), s("unregisterField",
|
|
48
|
-
validate:
|
|
49
|
-
reset:
|
|
47
|
+
return s("registerField", d), s("unregisterField", f), u({
|
|
48
|
+
validate: n,
|
|
49
|
+
reset: c,
|
|
50
50
|
resetValidation: p
|
|
51
|
-
}), (e, a) => (g(), v("form", {
|
|
52
|
-
onSubmit:
|
|
51
|
+
}), (e, a) => (g(), v("form", h({
|
|
52
|
+
onSubmit: y(m, ["prevent"]),
|
|
53
53
|
novalidate: "",
|
|
54
|
-
class:
|
|
55
|
-
}, [
|
|
56
|
-
|
|
57
|
-
],
|
|
54
|
+
class: `flex flex-col w-full ${i.gap} ${i.padding} ${i.maxWidth}`
|
|
55
|
+
}, e.$attrs), [
|
|
56
|
+
x(e.$slots, "default")
|
|
57
|
+
], 16));
|
|
58
58
|
}
|
|
59
59
|
};
|
|
60
60
|
export {
|
|
61
|
-
|
|
61
|
+
w as default
|
|
62
62
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { computed as o, createElementBlock as
|
|
2
|
-
const
|
|
1
|
+
import { computed as o, createElementBlock as c, openBlock as s, mergeProps as m, renderSlot as y, createBlock as v, resolveDynamicComponent as k, normalizeClass as i } from "vue";
|
|
2
|
+
const g = ["innerHTML"], p = {
|
|
3
3
|
__name: "KunIcon",
|
|
4
4
|
props: {
|
|
5
5
|
icon: {
|
|
@@ -26,34 +26,34 @@ const k = ["innerHTML"], b = {
|
|
|
26
26
|
},
|
|
27
27
|
emits: ["click"],
|
|
28
28
|
setup(e, { emit: r }) {
|
|
29
|
-
const
|
|
30
|
-
function d(
|
|
31
|
-
|
|
29
|
+
const l = e, u = r;
|
|
30
|
+
function d(n) {
|
|
31
|
+
l.disabled || u("click", n);
|
|
32
32
|
}
|
|
33
33
|
const a = o(() => typeof t.value == "string" && t.value.trim().startsWith("<svg")), t = o(() => {
|
|
34
|
-
if (typeof
|
|
35
|
-
const
|
|
36
|
-
return
|
|
34
|
+
if (typeof l.icon == "string" && l.icon.startsWith("$")) {
|
|
35
|
+
const n = l.icon.slice(1);
|
|
36
|
+
return l.aliases[n] || "";
|
|
37
37
|
}
|
|
38
|
-
return
|
|
38
|
+
return l.icon;
|
|
39
39
|
}), f = o(
|
|
40
40
|
() => typeof t.value == "function" || typeof t.value == "object" && t.value !== null
|
|
41
41
|
);
|
|
42
|
-
return (
|
|
43
|
-
class:
|
|
42
|
+
return (n, C) => (s(), c("span", m({
|
|
43
|
+
class: ["flex items-center", [e.color, e.size, e.disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer"]],
|
|
44
44
|
onClick: d
|
|
45
|
-
}, [
|
|
46
|
-
|
|
45
|
+
}, n.$attrs), [
|
|
46
|
+
n.$slots.default ? y(n.$slots, "default", { key: 0 }) : f.value ? (s(), v(k(t.value), {
|
|
47
47
|
key: 1,
|
|
48
|
-
class:
|
|
49
|
-
}, null, 8, ["class"])) : (s(),
|
|
48
|
+
class: i([e.color, e.size, e.contentClass])
|
|
49
|
+
}, null, 8, ["class"])) : (s(), c("span", {
|
|
50
50
|
key: 2,
|
|
51
|
-
class:
|
|
51
|
+
class: i([a.value ? "" : t.value, e.color, e.size, e.contentClass]),
|
|
52
52
|
innerHTML: [a.value ? t.value : ""]
|
|
53
|
-
}, null, 10,
|
|
54
|
-
],
|
|
53
|
+
}, null, 10, g))
|
|
54
|
+
], 16));
|
|
55
55
|
}
|
|
56
56
|
};
|
|
57
57
|
export {
|
|
58
|
-
|
|
58
|
+
p as default
|
|
59
59
|
};
|