@robuust-digital/vue-components 2.0.0 → 2.2.0-rc.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/CHANGELOG.md +25 -0
- package/dist/_shared/ButtonBase.vue_vue_type_script_setup_true_lang-B0YsKehI.js +60 -0
- package/dist/_shared/ChevronDownIcon-DaaXfD3C.js +41 -0
- package/dist/_shared/Combobox.vue_vue_type_script_setup_true_lang-D1vKMJok.js +266 -0
- package/dist/_shared/Drawer.vue_vue_type_script_setup_true_lang-DT6tBBZ7.js +186 -0
- package/dist/_shared/Dropdown.vue_vue_type_script_setup_true_lang-D5vTFLkq.js +115 -0
- package/dist/_shared/FormInput.vue_vue_type_script_setup_true_lang-BhJpG-Fw.js +75 -0
- package/dist/_shared/Lightswitch.vue_vue_type_script_setup_true_lang-CvN-2WJt.js +44 -0
- package/dist/_shared/Modal.vue_vue_type_script_setup_true_lang-DBEOIZnO.js +187 -0
- package/dist/_shared/RichTextEditor.vue_vue_type_script_setup_true_lang-Bs4WdJhA.js +274 -0
- package/dist/_shared/Tabs.vue_vue_type_script_setup_true_lang-CsGx6wBK.js +676 -0
- package/dist/_shared/Toast.vue_vue_type_script_setup_true_lang-FEeRXoIx.js +75 -0
- package/dist/_shared/Tooltip.vue_vue_type_script_setup_true_lang-CoydN9sS.js +96 -0
- package/dist/combobox/index.js +3 -347
- package/dist/combobox.d.ts +4 -0
- package/dist/components/Accordion.vue.d.ts +37 -0
- package/dist/components/Alert.vue.d.ts +39 -0
- package/dist/components/Badge.vue.d.ts +32 -0
- package/dist/components/ButtonBase.vue.d.ts +50 -0
- package/dist/components/Checkbox.vue.d.ts +39 -0
- package/dist/components/Combobox.vue.d.ts +112 -0
- package/dist/components/DataTable.vue.d.ts +122 -0
- package/dist/components/Drawer.vue.d.ts +103 -0
- package/dist/components/Dropdown.vue.d.ts +120 -0
- package/dist/components/EmptyState.vue.d.ts +23 -0
- package/dist/components/FormInput.vue.d.ts +49 -0
- package/dist/components/FormSelect.vue.d.ts +58 -0
- package/dist/components/FormTextarea.vue.d.ts +16 -0
- package/dist/components/Lightswitch.vue.d.ts +26 -0
- package/dist/components/Modal.vue.d.ts +98 -0
- package/dist/components/Pagination.vue.d.ts +60 -0
- package/dist/components/Radio.vue.d.ts +34 -0
- package/dist/components/RichTextEditor.vue.d.ts +71 -0
- package/dist/components/Tabs.vue.d.ts +26 -0
- package/dist/components/Toast.vue.d.ts +46 -0
- package/dist/components/Tooltip.vue.d.ts +45 -0
- package/dist/composables/useDialogContext.d.ts +18 -0
- package/dist/composables/useForm.d.ts +6 -0
- package/dist/core/button.css +1 -9
- package/dist/core/checkbox.css +6 -9
- package/dist/core/index.js +17 -799
- package/dist/core/input.css +8 -7
- package/dist/core/radio.css +6 -9
- package/dist/core/utilities.css +12 -0
- package/dist/core.d.ts +27 -0
- package/dist/dialogs/index.js +4 -206
- package/dist/dialogs.d.ts +5 -0
- package/dist/dropdown/index.js +3 -131
- package/dist/dropdown.d.ts +4 -0
- package/dist/index/index.js +35 -0
- package/dist/index.d.ts +8 -0
- package/dist/lightswitch/index.js +3 -47
- package/dist/lightswitch.d.ts +4 -0
- package/dist/rich-text-editor/index.js +3 -263
- package/dist/rich-text-editor.d.ts +4 -0
- package/dist/toast/index.js +3 -99
- package/dist/toast.d.ts +4 -0
- package/dist/tooltip/index.js +1 -1
- package/dist/tooltip.d.ts +4 -0
- package/dist/types/shared.d.ts +3 -0
- package/package.json +55 -24
- package/dist/_shared/ButtonBase-DfkwHIhN.js +0 -87
- package/dist/_shared/ChevronDownIcon-z-5U4fIb.js +0 -55
- package/dist/_shared/FormInput-C5LjZViC.js +0 -85
- package/dist/_shared/Modal-dqDGKVw5.js +0 -201
- package/dist/_shared/Tooltip-B93ZF7IF.js +0 -126
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { createElementBlock as v, openBlock as n, createElementVNode as _, defineComponent as B, createBlock as a, unref as t, normalizeClass as c, withCtx as r, renderSlot as s, createVNode as l, mergeProps as u, Transition as M, Fragment as $, renderList as y, resolveDynamicComponent as f, createCommentVNode as A, createTextVNode as L, toDisplayString as N } from "vue";
|
|
2
|
+
import { Menu as V, MenuButton as p, MenuItems as D, MenuItem as m } from "@headlessui/vue";
|
|
3
|
+
import { _ as I } from "./ButtonBase.vue_vue_type_script_setup_true_lang-B0YsKehI.js";
|
|
4
|
+
function Z(w, i) {
|
|
5
|
+
return n(), v("svg", {
|
|
6
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
7
|
+
viewBox: "0 0 20 20",
|
|
8
|
+
fill: "currentColor",
|
|
9
|
+
"aria-hidden": "true",
|
|
10
|
+
"data-slot": "icon"
|
|
11
|
+
}, [
|
|
12
|
+
_("path", { d: "M10 3a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3ZM10 8.5a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3ZM11.5 15.5a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0Z" })
|
|
13
|
+
]);
|
|
14
|
+
}
|
|
15
|
+
const z = /* @__PURE__ */ B({
|
|
16
|
+
inheritAttrs: !1,
|
|
17
|
+
__name: "Dropdown",
|
|
18
|
+
props: {
|
|
19
|
+
items: {},
|
|
20
|
+
alignLeft: { type: Boolean, default: !1 },
|
|
21
|
+
fullWidth: { type: Boolean, default: !1 },
|
|
22
|
+
label: { default: "Options" },
|
|
23
|
+
rootClass: { default: "" }
|
|
24
|
+
},
|
|
25
|
+
emits: ["dropdown:click"],
|
|
26
|
+
setup(w, { emit: i }) {
|
|
27
|
+
const b = i, g = (e) => {
|
|
28
|
+
const {
|
|
29
|
+
as: h,
|
|
30
|
+
bindAs: o,
|
|
31
|
+
event: d,
|
|
32
|
+
icon: C,
|
|
33
|
+
name: E,
|
|
34
|
+
...k
|
|
35
|
+
} = e;
|
|
36
|
+
return k;
|
|
37
|
+
};
|
|
38
|
+
return (e, h) => (n(), a(t(V), {
|
|
39
|
+
as: "div",
|
|
40
|
+
class: c(["rvc-dropdown", e.rootClass])
|
|
41
|
+
}, {
|
|
42
|
+
default: r(() => [
|
|
43
|
+
s(e.$slots, "button", {
|
|
44
|
+
label: e.label,
|
|
45
|
+
button: t(p)
|
|
46
|
+
}, () => [
|
|
47
|
+
l(t(p), u({
|
|
48
|
+
as: I,
|
|
49
|
+
label: e.label,
|
|
50
|
+
color: "light",
|
|
51
|
+
icon: t(Z),
|
|
52
|
+
"icon-left": e.alignLeft
|
|
53
|
+
}, e.$attrs), null, 16, ["label", "icon", "icon-left"])
|
|
54
|
+
]),
|
|
55
|
+
l(M, {
|
|
56
|
+
"enter-active-class": "rvc-dropdown-transition-enter",
|
|
57
|
+
"enter-from-class": "rvc-dropdown-transition-enter-from",
|
|
58
|
+
"enter-to-class": "rvc-dropdown-transition-enter-to",
|
|
59
|
+
"leave-active-class": "rvc-dropdown-transition-leave",
|
|
60
|
+
"leave-from-class": "rvc-dropdown-transition-leave-from",
|
|
61
|
+
"leave-to-class": "rvc-dropdown-transition-leave-to"
|
|
62
|
+
}, {
|
|
63
|
+
default: r(() => [
|
|
64
|
+
l(t(D), {
|
|
65
|
+
class: c([
|
|
66
|
+
"rvc-dropdown-items",
|
|
67
|
+
{
|
|
68
|
+
"rvc-dropdown-items-left": e.alignLeft,
|
|
69
|
+
"rvc-dropdown-items-full": e.fullWidth
|
|
70
|
+
}
|
|
71
|
+
])
|
|
72
|
+
}, {
|
|
73
|
+
default: r(() => [
|
|
74
|
+
s(e.$slots, "items", {
|
|
75
|
+
items: e.items,
|
|
76
|
+
menuItem: t(m)
|
|
77
|
+
}, () => [
|
|
78
|
+
(n(!0), v($, null, y(e.items, (o, d) => (n(), a(t(m), {
|
|
79
|
+
key: `${d}-dropdown-item`,
|
|
80
|
+
as: "template"
|
|
81
|
+
}, {
|
|
82
|
+
default: r(() => [
|
|
83
|
+
s(e.$slots, "item", { item: o }, () => [
|
|
84
|
+
(n(), a(f(o.as ? o.as : "button"), u({ class: "rvc-dropdown-item" }, { ref_for: !0 }, g(o), {
|
|
85
|
+
as: o.bindAs ? o.bindAs : void 0,
|
|
86
|
+
onClick: (C) => (b("dropdown:click", o), o.event ? o.event() : null)
|
|
87
|
+
}), {
|
|
88
|
+
default: r(() => [
|
|
89
|
+
o.icon ? (n(), a(f(o.icon), {
|
|
90
|
+
key: 0,
|
|
91
|
+
class: "rvc-dropdown-item-icon"
|
|
92
|
+
})) : A("", !0),
|
|
93
|
+
L(" " + N(o.name), 1)
|
|
94
|
+
]),
|
|
95
|
+
_: 2
|
|
96
|
+
}, 1040, ["as", "onClick"]))
|
|
97
|
+
])
|
|
98
|
+
]),
|
|
99
|
+
_: 2
|
|
100
|
+
}, 1024))), 128))
|
|
101
|
+
])
|
|
102
|
+
]),
|
|
103
|
+
_: 3
|
|
104
|
+
}, 8, ["class"])
|
|
105
|
+
]),
|
|
106
|
+
_: 3
|
|
107
|
+
})
|
|
108
|
+
]),
|
|
109
|
+
_: 3
|
|
110
|
+
}, 8, ["class"]));
|
|
111
|
+
}
|
|
112
|
+
});
|
|
113
|
+
export {
|
|
114
|
+
z as _
|
|
115
|
+
};
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { computed as v, getCurrentInstance as I, defineComponent as g, useSlots as B, ref as C, createElementBlock as n, openBlock as o, normalizeClass as V, createCommentVNode as p, renderSlot as s, unref as r, createBlock as f, resolveDynamicComponent as m, normalizeProps as b, guardReactiveProps as z, withDirectives as F, mergeProps as y, vModelDynamic as M } from "vue";
|
|
2
|
+
const O = () => ({ hasModelBinding: v(() => {
|
|
3
|
+
var i;
|
|
4
|
+
const t = I();
|
|
5
|
+
return !!((i = t == null ? void 0 : t.vnode) != null && i.props && Object.prototype.hasOwnProperty.call(t.vnode.props, "onUpdate:modelValue"));
|
|
6
|
+
}) }), P = {
|
|
7
|
+
key: 0,
|
|
8
|
+
class: "rvc-input-prefix"
|
|
9
|
+
}, j = ["type"], D = ["type"], w = {
|
|
10
|
+
key: 1,
|
|
11
|
+
class: "rvc-input-suffix"
|
|
12
|
+
}, U = /* @__PURE__ */ g({
|
|
13
|
+
inheritAttrs: !1,
|
|
14
|
+
__name: "FormInput",
|
|
15
|
+
props: {
|
|
16
|
+
modelValue: { default: void 0 },
|
|
17
|
+
rootClass: { default: "" },
|
|
18
|
+
prefixIcon: { type: [Function, Object, null], default: null },
|
|
19
|
+
icon: { type: [Function, Object, null], default: null },
|
|
20
|
+
size: { default: "base" }
|
|
21
|
+
},
|
|
22
|
+
emits: ["update:modelValue"],
|
|
23
|
+
setup(u, { emit: t }) {
|
|
24
|
+
const i = u, h = t, { hasModelBinding: k } = O(), l = B(), a = C(null), d = v({
|
|
25
|
+
get: () => i.modelValue,
|
|
26
|
+
set: (e) => h("update:modelValue", e)
|
|
27
|
+
});
|
|
28
|
+
return (e, c) => (o(), n("div", {
|
|
29
|
+
class: V([
|
|
30
|
+
"rvc-input",
|
|
31
|
+
`rvc-input-${e.size}`,
|
|
32
|
+
e.rootClass
|
|
33
|
+
])
|
|
34
|
+
}, [
|
|
35
|
+
r(l).prefix || r(l).prefixIcon || e.prefixIcon ? (o(), n("span", P, [
|
|
36
|
+
s(e.$slots, "prefix", {}, () => [
|
|
37
|
+
s(e.$slots, "prefixIcon", { icon: e.prefixIcon }, () => [
|
|
38
|
+
e.prefixIcon ? (o(), f(m(e.prefixIcon), {
|
|
39
|
+
key: 0,
|
|
40
|
+
"aria-hidden": "true"
|
|
41
|
+
})) : p("", !0)
|
|
42
|
+
])
|
|
43
|
+
])
|
|
44
|
+
])) : p("", !0),
|
|
45
|
+
s(e.$slots, "input", b(z(e.$attrs)), () => [
|
|
46
|
+
r(k) ? F((o(), n("input", y({ key: 0 }, e.$attrs, {
|
|
47
|
+
ref_key: "input",
|
|
48
|
+
ref: a,
|
|
49
|
+
"onUpdate:modelValue": c[0] || (c[0] = ($) => d.value = $),
|
|
50
|
+
type: e.$attrs.type || "text"
|
|
51
|
+
}), null, 16, j)), [
|
|
52
|
+
[M, d.value]
|
|
53
|
+
]) : (o(), n("input", y({ key: 1 }, e.$attrs, {
|
|
54
|
+
ref_key: "input",
|
|
55
|
+
ref: a,
|
|
56
|
+
type: e.$attrs.type || "text"
|
|
57
|
+
}), null, 16, D))
|
|
58
|
+
]),
|
|
59
|
+
r(l).suffix || r(l).icon || e.icon ? (o(), n("span", w, [
|
|
60
|
+
s(e.$slots, "suffix", {}, () => [
|
|
61
|
+
s(e.$slots, "icon", { icon: e.icon }, () => [
|
|
62
|
+
e.icon ? (o(), f(m(e.icon), {
|
|
63
|
+
key: 0,
|
|
64
|
+
"aria-hidden": "true"
|
|
65
|
+
})) : p("", !0)
|
|
66
|
+
])
|
|
67
|
+
])
|
|
68
|
+
])) : p("", !0)
|
|
69
|
+
], 2));
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
export {
|
|
73
|
+
U as _,
|
|
74
|
+
O as u
|
|
75
|
+
};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { defineComponent as c, computed as p, createBlock as s, openBlock as r, unref as o, withCtx as a, createVNode as f, createCommentVNode as h, mergeProps as g, createElementVNode as V, renderSlot as w } from "vue";
|
|
2
|
+
import { SwitchGroup as v, Switch as _, SwitchLabel as S } from "@headlessui/vue";
|
|
3
|
+
const B = /* @__PURE__ */ c({
|
|
4
|
+
inheritAttrs: !1,
|
|
5
|
+
__name: "Lightswitch",
|
|
6
|
+
props: {
|
|
7
|
+
modelValue: { type: Boolean, default: !1 }
|
|
8
|
+
},
|
|
9
|
+
emits: ["update:modelValue"],
|
|
10
|
+
setup(u, { emit: d }) {
|
|
11
|
+
const i = u, n = d, l = p({
|
|
12
|
+
get: () => i.modelValue,
|
|
13
|
+
set: (e) => n("update:modelValue", e)
|
|
14
|
+
});
|
|
15
|
+
return (e, t) => (r(), s(o(v), {
|
|
16
|
+
as: "div",
|
|
17
|
+
class: "rvc-lightswitch-group"
|
|
18
|
+
}, {
|
|
19
|
+
default: a(() => [
|
|
20
|
+
f(o(_), g({
|
|
21
|
+
modelValue: l.value,
|
|
22
|
+
"onUpdate:modelValue": t[0] || (t[0] = (m) => l.value = m),
|
|
23
|
+
class: [{ "rvc-lightswitch-enabled": l.value }, "rvc-lightswitch"]
|
|
24
|
+
}, e.$attrs), {
|
|
25
|
+
default: a(() => t[1] || (t[1] = [
|
|
26
|
+
V("span", { class: "rvc-lightswitch-toggle" }, null, -1)
|
|
27
|
+
])),
|
|
28
|
+
_: 1,
|
|
29
|
+
__: [1]
|
|
30
|
+
}, 16, ["modelValue", "class"]),
|
|
31
|
+
e.$slots.default ? (r(), s(o(S), { key: 0 }, {
|
|
32
|
+
default: a(() => [
|
|
33
|
+
w(e.$slots, "default")
|
|
34
|
+
]),
|
|
35
|
+
_: 3
|
|
36
|
+
})) : h("", !0)
|
|
37
|
+
]),
|
|
38
|
+
_: 3
|
|
39
|
+
}));
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
export {
|
|
43
|
+
B as _
|
|
44
|
+
};
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import { ref as C, computed as u, defineComponent as D, createBlock as L, openBlock as y, unref as t, withCtx as d, createVNode as n, withModifiers as T, createElementVNode as r, normalizeClass as I, createElementBlock as $, renderSlot as s, createCommentVNode as N, createTextVNode as R, toDisplayString as S } from "vue";
|
|
2
|
+
import { TransitionRoot as V, Dialog as h, TransitionChild as g, DialogPanel as A, DialogTitle as B } from "@headlessui/vue";
|
|
3
|
+
import { _ as E } from "./ButtonBase.vue_vue_type_script_setup_true_lang-B0YsKehI.js";
|
|
4
|
+
import { r as w } from "./XMarkIcon-90mcPzBs.js";
|
|
5
|
+
function H(m) {
|
|
6
|
+
const f = C(null), p = C(!1), l = u(() => m.as === "form"), b = u(() => `${m.id}-title`), v = u(() => `${m.id}-content`), c = u(() => {
|
|
7
|
+
var i;
|
|
8
|
+
return (i = f.value) == null ? void 0 : i.querySelector('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');
|
|
9
|
+
});
|
|
10
|
+
return {
|
|
11
|
+
contentRef: f,
|
|
12
|
+
ready: p,
|
|
13
|
+
isForm: l,
|
|
14
|
+
titleId: b,
|
|
15
|
+
descriptionId: v,
|
|
16
|
+
initialFocusElement: c
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
const M = {
|
|
20
|
+
role: "presentation",
|
|
21
|
+
class: "rvc-modal-presentation"
|
|
22
|
+
}, q = { class: "rvc-modal-container" }, z = {
|
|
23
|
+
key: 0,
|
|
24
|
+
class: "rvc-modal-header"
|
|
25
|
+
}, P = { class: "rvc-modal-header-inner" }, j = { class: "rvc-modal-close-wrapper" }, G = ["id"], J = {
|
|
26
|
+
key: 2,
|
|
27
|
+
class: "rvc-modal-footer"
|
|
28
|
+
}, W = /* @__PURE__ */ D({
|
|
29
|
+
__name: "Modal",
|
|
30
|
+
props: {
|
|
31
|
+
as: { default: "div" },
|
|
32
|
+
id: {},
|
|
33
|
+
title: {},
|
|
34
|
+
showClose: { type: Boolean, default: !1 },
|
|
35
|
+
spinning: { type: Boolean, default: !1 },
|
|
36
|
+
submitLabel: { default: "Confirm" },
|
|
37
|
+
cancelLabel: { default: "Cancel" },
|
|
38
|
+
panelClass: { default: "rvc-modal-panel-max-width" },
|
|
39
|
+
resetHeader: { type: Boolean, default: !1 },
|
|
40
|
+
resetFooter: { type: Boolean, default: !1 }
|
|
41
|
+
},
|
|
42
|
+
emits: ["modal:open", "modal:opened", "modal:close", "modal:save", "modal:closed"],
|
|
43
|
+
setup(m, { emit: f }) {
|
|
44
|
+
const p = m, l = f, {
|
|
45
|
+
contentRef: b,
|
|
46
|
+
ready: v,
|
|
47
|
+
isForm: c,
|
|
48
|
+
titleId: i,
|
|
49
|
+
descriptionId: k,
|
|
50
|
+
initialFocusElement: F
|
|
51
|
+
} = H(p);
|
|
52
|
+
return (e, o) => (y(), L(t(V), { as: "template" }, {
|
|
53
|
+
default: d(() => [
|
|
54
|
+
n(t(h), {
|
|
55
|
+
as: e.as,
|
|
56
|
+
class: "rvc-modal",
|
|
57
|
+
static: "",
|
|
58
|
+
"aria-modal": "true",
|
|
59
|
+
role: "dialog",
|
|
60
|
+
"initial-focus": t(F),
|
|
61
|
+
"aria-labelledby": t(i),
|
|
62
|
+
onClose: o[7] || (o[7] = (a) => l("modal:close")),
|
|
63
|
+
onSubmit: o[8] || (o[8] = T((a) => l("modal:save", a), ["prevent"]))
|
|
64
|
+
}, {
|
|
65
|
+
default: d(() => [
|
|
66
|
+
n(t(g), {
|
|
67
|
+
as: "template",
|
|
68
|
+
enter: "rvc-modal-backdrop-transition-enter",
|
|
69
|
+
"enter-from": "rvc-modal-backdrop-transition-enter-from",
|
|
70
|
+
"enter-to": "rvc-modal-backdrop-transition-enter-to",
|
|
71
|
+
leave: "rvc-modal-backdrop-transition-leave",
|
|
72
|
+
"leave-from": "rvc-modal-backdrop-transition-leave-from",
|
|
73
|
+
"leave-to": "rvc-modal-backdrop-transition-leave-to",
|
|
74
|
+
onBeforeEnter: o[0] || (o[0] = (a) => l("modal:open")),
|
|
75
|
+
onAfterEnter: o[1] || (o[1] = (a) => l("modal:opened"))
|
|
76
|
+
}, {
|
|
77
|
+
default: d(() => o[9] || (o[9] = [
|
|
78
|
+
r("div", {
|
|
79
|
+
"aria-hidden": "true",
|
|
80
|
+
class: "rvc-modal-backdrop"
|
|
81
|
+
}, null, -1)
|
|
82
|
+
])),
|
|
83
|
+
_: 1,
|
|
84
|
+
__: [9]
|
|
85
|
+
}),
|
|
86
|
+
r("div", M, [
|
|
87
|
+
r("div", q, [
|
|
88
|
+
n(t(g), {
|
|
89
|
+
as: "template",
|
|
90
|
+
enter: "rvc-modal-transition-enter",
|
|
91
|
+
"enter-from": "rvc-modal-transition-enter-from",
|
|
92
|
+
"enter-to": "rvc-modal-transition-enter-to",
|
|
93
|
+
leave: "rvc-modal-transition-leave",
|
|
94
|
+
"leave-from": "rvc-modal-transition-leave-from",
|
|
95
|
+
"leave-to": "rvc-modal-transition-leave-to",
|
|
96
|
+
onBeforeEnter: o[5] || (o[5] = (a) => v.value = !0),
|
|
97
|
+
onAfterLeave: o[6] || (o[6] = (a) => (v.value = !1, l("modal:closed")))
|
|
98
|
+
}, {
|
|
99
|
+
default: d(() => [
|
|
100
|
+
n(t(A), {
|
|
101
|
+
class: I(["rvc-modal-panel", e.panelClass]),
|
|
102
|
+
"aria-busy": e.spinning,
|
|
103
|
+
"aria-describedby": t(k)
|
|
104
|
+
}, {
|
|
105
|
+
default: d(() => [
|
|
106
|
+
e.resetHeader ? s(e.$slots, "header", { key: 1 }) : (y(), $("header", z, [
|
|
107
|
+
s(e.$slots, "header", { title: e.title }, () => [
|
|
108
|
+
r("div", P, [
|
|
109
|
+
s(e.$slots, "title", {
|
|
110
|
+
id: t(i),
|
|
111
|
+
dialogTitle: t(B),
|
|
112
|
+
title: e.title
|
|
113
|
+
}, () => [
|
|
114
|
+
n(t(B), {
|
|
115
|
+
id: t(i),
|
|
116
|
+
class: "rvc-modal-title"
|
|
117
|
+
}, {
|
|
118
|
+
default: d(() => [
|
|
119
|
+
R(S(e.title), 1)
|
|
120
|
+
]),
|
|
121
|
+
_: 1
|
|
122
|
+
}, 8, ["id"])
|
|
123
|
+
]),
|
|
124
|
+
e.showClose ? s(e.$slots, "close", {
|
|
125
|
+
key: 0,
|
|
126
|
+
icon: t(w),
|
|
127
|
+
emitClose: () => l("modal:close")
|
|
128
|
+
}, () => [
|
|
129
|
+
r("div", j, [
|
|
130
|
+
r("button", {
|
|
131
|
+
type: "button",
|
|
132
|
+
class: "rvc-modal-close",
|
|
133
|
+
"aria-label": "Close panel",
|
|
134
|
+
onClick: o[2] || (o[2] = (a) => l("modal:close"))
|
|
135
|
+
}, [
|
|
136
|
+
n(t(w), { "aria-hidden": "true" })
|
|
137
|
+
])
|
|
138
|
+
])
|
|
139
|
+
]) : N("", !0)
|
|
140
|
+
])
|
|
141
|
+
])
|
|
142
|
+
])),
|
|
143
|
+
r("div", {
|
|
144
|
+
id: t(k),
|
|
145
|
+
ref_key: "contentRef",
|
|
146
|
+
ref: b,
|
|
147
|
+
class: "rvc-modal-content"
|
|
148
|
+
}, [
|
|
149
|
+
s(e.$slots, "default", { ready: t(v) })
|
|
150
|
+
], 8, G),
|
|
151
|
+
e.resetFooter ? s(e.$slots, "footer", { key: 3 }) : (y(), $("footer", J, [
|
|
152
|
+
s(e.$slots, "footer", { loading: e.spinning }, () => [
|
|
153
|
+
n(E, {
|
|
154
|
+
type: t(c) ? "submit" : "button",
|
|
155
|
+
label: e.submitLabel,
|
|
156
|
+
spinning: e.spinning,
|
|
157
|
+
disabled: e.spinning,
|
|
158
|
+
onClick: o[3] || (o[3] = (a) => !t(c) && l("modal:save"))
|
|
159
|
+
}, null, 8, ["type", "label", "spinning", "disabled"]),
|
|
160
|
+
n(E, {
|
|
161
|
+
type: "button",
|
|
162
|
+
color: "light",
|
|
163
|
+
label: e.cancelLabel,
|
|
164
|
+
onClick: o[4] || (o[4] = (a) => l("modal:close"))
|
|
165
|
+
}, null, 8, ["label"])
|
|
166
|
+
])
|
|
167
|
+
]))
|
|
168
|
+
]),
|
|
169
|
+
_: 3
|
|
170
|
+
}, 8, ["class", "aria-busy", "aria-describedby"])
|
|
171
|
+
]),
|
|
172
|
+
_: 3
|
|
173
|
+
})
|
|
174
|
+
])
|
|
175
|
+
])
|
|
176
|
+
]),
|
|
177
|
+
_: 3
|
|
178
|
+
}, 8, ["as", "initial-focus", "aria-labelledby"])
|
|
179
|
+
]),
|
|
180
|
+
_: 3
|
|
181
|
+
}));
|
|
182
|
+
}
|
|
183
|
+
});
|
|
184
|
+
export {
|
|
185
|
+
W as _,
|
|
186
|
+
H as u
|
|
187
|
+
};
|