adverich-kun-ui 0.1.283 → 0.1.284
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.
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as x, watch as C, onMounted as f, onBeforeUnmount as S, onUnmounted as k, createBlock as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
const
|
|
1
|
+
import { defineComponent as x, watch as C, onMounted as f, onBeforeUnmount as S, onUnmounted as k, createBlock as m, openBlock as a, Teleport as P, createVNode as o, Transition as u, withCtx as n, createElementBlock as B, createCommentVNode as h, mergeProps as V, renderSlot as E } from "vue";
|
|
2
|
+
import H from "./KunDialogOverlay.vue.js";
|
|
3
|
+
import W from "./KunDialogContent.vue.js";
|
|
4
|
+
const $ = "fixed inset-0 z-250 flex", T = /* @__PURE__ */ x({
|
|
5
5
|
__name: "KunDialog",
|
|
6
6
|
props: {
|
|
7
7
|
modelValue: Boolean,
|
|
@@ -24,6 +24,7 @@ const D = "fixed inset-0 z-250 flex", T = /* @__PURE__ */ x({
|
|
|
24
24
|
},
|
|
25
25
|
contentClass: { type: String, default: "" },
|
|
26
26
|
bgColor: { type: String, default: "bg-slate-100 dark:bg-slate-900" },
|
|
27
|
+
minHeigh: { type: String, default: "h-fit" },
|
|
27
28
|
height: { type: String, default: "h-fit" },
|
|
28
29
|
maxHeigh: { type: String, default: "max-h-[100vh]" },
|
|
29
30
|
minWidth: { type: String, default: "min-w-1/3" },
|
|
@@ -31,8 +32,8 @@ const D = "fixed inset-0 z-250 flex", T = /* @__PURE__ */ x({
|
|
|
31
32
|
maxWidth: { type: String, default: "max-w-full" }
|
|
32
33
|
},
|
|
33
34
|
emits: ["update:modelValue"],
|
|
34
|
-
setup(e, { emit:
|
|
35
|
-
const t = e, i =
|
|
35
|
+
setup(e, { emit: y }) {
|
|
36
|
+
const t = e, i = y, g = "justify-" + t.xPosition, p = "items-" + t.yPosition, w = t.yPosition === "top" ? "pt-15" : t.yPosition === "bottom" ? "pb-15" : "", b = [$, t.dialogClass, g, p, w], s = () => {
|
|
36
37
|
t.persistent || i("update:modelValue", !1);
|
|
37
38
|
}, v = () => {
|
|
38
39
|
s();
|
|
@@ -55,22 +56,22 @@ const D = "fixed inset-0 z-250 flex", T = /* @__PURE__ */ x({
|
|
|
55
56
|
window.addEventListener("keydown", c);
|
|
56
57
|
}), k(() => {
|
|
57
58
|
window.removeEventListener("keydown", c);
|
|
58
|
-
}), (l,
|
|
59
|
-
|
|
59
|
+
}), (l, D) => (a(), m(P, { to: "body" }, [
|
|
60
|
+
o(u, {
|
|
60
61
|
name: "fade",
|
|
61
62
|
appear: ""
|
|
62
63
|
}, {
|
|
63
64
|
default: n(() => [
|
|
64
|
-
e.modelValue ? (
|
|
65
|
+
e.modelValue ? (a(), B("div", V({
|
|
65
66
|
key: 0,
|
|
66
67
|
class: b
|
|
67
68
|
}, l.$attrs), [
|
|
68
|
-
e.overlay ? (
|
|
69
|
+
e.overlay ? (a(), m(H, {
|
|
69
70
|
key: 0,
|
|
70
71
|
persistent: e.persistent,
|
|
71
72
|
onClick: v
|
|
72
|
-
}, null, 8, ["persistent"])) :
|
|
73
|
-
|
|
73
|
+
}, null, 8, ["persistent"])) : h("", !0),
|
|
74
|
+
o(u, {
|
|
74
75
|
name: "scale",
|
|
75
76
|
"enter-active-class": "transition transform ease-out duration-300",
|
|
76
77
|
"enter-from-class": "opacity-0 scale-95",
|
|
@@ -80,12 +81,13 @@ const D = "fixed inset-0 z-250 flex", T = /* @__PURE__ */ x({
|
|
|
80
81
|
"leave-to-class": "opacity-0 scale-95"
|
|
81
82
|
}, {
|
|
82
83
|
default: n(() => [
|
|
83
|
-
|
|
84
|
+
o(W, {
|
|
84
85
|
fullscreen: e.fullscreen,
|
|
85
86
|
scrollable: e.scrollable,
|
|
86
87
|
"min-width": e.minWidth,
|
|
87
88
|
width: e.width,
|
|
88
89
|
"max-width": e.maxWidth,
|
|
90
|
+
"min-height": e.minHeigh,
|
|
89
91
|
height: e.height,
|
|
90
92
|
"max-height": e.maxHeigh,
|
|
91
93
|
"bg-color": e.bgColor,
|
|
@@ -96,11 +98,11 @@ const D = "fixed inset-0 z-250 flex", T = /* @__PURE__ */ x({
|
|
|
96
98
|
E(l.$slots, "default")
|
|
97
99
|
]),
|
|
98
100
|
_: 3
|
|
99
|
-
}, 8, ["fullscreen", "scrollable", "min-width", "width", "max-width", "height", "max-height", "bg-color", "content-class"])
|
|
101
|
+
}, 8, ["fullscreen", "scrollable", "min-width", "width", "max-width", "min-height", "height", "max-height", "bg-color", "content-class"])
|
|
100
102
|
]),
|
|
101
103
|
_: 3
|
|
102
104
|
})
|
|
103
|
-
], 16)) :
|
|
105
|
+
], 16)) : h("", !0)
|
|
104
106
|
]),
|
|
105
107
|
_: 3
|
|
106
108
|
})
|