@pgcorp/ui-kit 0.11.0 → 0.13.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/README.md +198 -11
- package/dist/assets/src/components/shared/_internal/SDialogSurface.css_vue_type_style_index_0_src_d1b65adf_scoped_d1b65adf_lang.css +1 -1
- package/dist/assets/src/components/shared/_internal/SMenuItem.css_vue_type_style_index_0_src_af485607_scoped_af485607_lang.css +2 -0
- package/dist/assets/src/components/shared/containers/{SCollapsiblePanel.css_vue_type_style_index_0_src_4882f962_scoped_4882f962_lang.css → SCollapsiblePanel.css_vue_type_style_index_0_src_71824088_scoped_71824088_lang.css} +1 -1
- package/dist/assets/src/components/shared/containers/{SModal.css_vue_type_style_index_0_src_23373daf_scoped_23373daf_lang.css → SModal.css_vue_type_style_index_0_src_0dc51b74_scoped_0dc51b74_lang.css} +1 -1
- package/dist/assets/src/components/shared/controls/SButton.css_vue_type_style_index_0_src_a5d8f7e0_scoped_a5d8f7e0_lang.css +2 -0
- package/dist/assets/src/components/shared/controls/SChoiceCards.css_vue_type_style_index_0_src_af9fa9d1_scoped_af9fa9d1_lang.css +2 -0
- package/dist/assets/src/components/shared/controls/{SDropdownMenu.css_vue_type_style_index_0_src_b854a89e_scoped_b854a89e_lang.css → SDropdownMenu.css_vue_type_style_index_0_src_1ccb9efc_scoped_1ccb9efc_lang.css} +1 -1
- package/dist/assets/src/components/shared/controls/{SInputText.css_vue_type_style_index_0_src_a9c5f1aa_scoped_a9c5f1aa_lang.css → SInputText.css_vue_type_style_index_0_src_023c25d0_scoped_023c25d0_lang.css} +1 -1
- package/dist/assets/src/components/shared/controls/SMenuSurface.css_vue_type_style_index_0_src_ddcc5fbb_scoped_ddcc5fbb_lang.css +2 -0
- package/dist/assets/src/components/shared/data-display/{SCodeEditor.css_vue_type_style_index_0_src_124ca461_scoped_124ca461_lang.css → SCodeEditor.css_vue_type_style_index_0_src_3ad533d9_scoped_3ad533d9_lang.css} +1 -1
- package/dist/assets/src/components/shared/data-display/SStatus.css_vue_type_style_index_0_src_3ce41a12_scoped_3ce41a12_lang.css +2 -0
- package/dist/assets/src/components/shared/data-display/SVirtualList.css_vue_type_style_index_0_src_cee8c247_scoped_cee8c247_lang.css +2 -0
- package/dist/src/components/layout/SSideMenuButton.vue.d.ts +1 -1
- package/dist/src/components/shared/_internal/SMenuItem.vue.js +2 -2
- package/dist/src/components/shared/_internal/SMenuItem.vue_vue_type_script_setup_true_lang.js +88 -76
- package/dist/src/components/shared/_internal/dialogSurface.d.ts +1 -1
- package/dist/src/components/shared/_internal/dialogSurface.js +1 -0
- package/dist/src/components/shared/containers/SCollapsiblePanel.vue.d.ts +1 -1
- package/dist/src/components/shared/containers/SCollapsiblePanel.vue.js +2 -2
- package/dist/src/components/shared/containers/SCollapsiblePanel.vue_vue_type_script_setup_true_lang.js +60 -58
- package/dist/src/components/shared/containers/SModal.vue.js +2 -2
- package/dist/src/components/shared/containers/SModal.vue_vue_type_script_setup_true_lang.js +43 -37
- package/dist/src/components/shared/controls/SButton.vue.d.ts +3 -0
- package/dist/src/components/shared/controls/SButton.vue.js +2 -2
- package/dist/src/components/shared/controls/SButton.vue_vue_type_script_setup_true_lang.js +103 -99
- package/dist/src/components/shared/controls/SChoiceCards.vue.d.ts +1 -0
- package/dist/src/components/shared/controls/SChoiceCards.vue.js +2 -2
- package/dist/src/components/shared/controls/SChoiceCards.vue_vue_type_script_setup_true_lang.js +53 -49
- package/dist/src/components/shared/controls/SDropdownMenu.vue.d.ts +15 -4
- package/dist/src/components/shared/controls/SDropdownMenu.vue.js +2 -2
- package/dist/src/components/shared/controls/SDropdownMenu.vue_vue_type_script_setup_true_lang.js +98 -62
- package/dist/src/components/shared/controls/SInputText.vue.d.ts +2 -2
- package/dist/src/components/shared/controls/SInputText.vue.js +2 -2
- package/dist/src/components/shared/controls/SInputText.vue_vue_type_script_setup_true_lang.js +16 -25
- package/dist/src/components/shared/controls/SMenuSurface.vue.d.ts +2 -2
- package/dist/src/components/shared/controls/SMenuSurface.vue.js +2 -2
- package/dist/src/components/shared/controls/SMenuSurface.vue_vue_type_script_setup_true_lang.js +132 -110
- package/dist/src/components/shared/controls/STextarea.vue.d.ts +8 -0
- package/dist/src/components/shared/controls/STextarea.vue_vue_type_script_setup_true_lang.js +156 -145
- package/dist/src/components/shared/controls/menu.d.ts +9 -1
- package/dist/src/components/shared/controls/menu.js +43 -28
- package/dist/src/components/shared/data-display/SCodeEditor.vue.d.ts +90 -7
- package/dist/src/components/shared/data-display/SCodeEditor.vue.js +2 -2
- package/dist/src/components/shared/data-display/SStatus.vue.d.ts +7 -0
- package/dist/src/components/shared/data-display/SStatus.vue.js +2 -2
- package/dist/src/components/shared/data-display/SStatus.vue_vue_type_script_setup_true_lang.js +28 -21
- package/dist/src/components/shared/data-display/SVirtualList.vue.d.ts +2 -0
- package/dist/src/components/shared/data-display/SVirtualList.vue.js +2 -2
- package/dist/src/components/shared/data-display/SVirtualList.vue_vue_type_script_setup_true_lang.js +317 -210
- package/dist/src/composables/useDialogOverlay.d.ts +1 -0
- package/dist/src/composables/useDialogOverlay.js +5 -2
- package/dist/src/internal/textLengthConstraints.d.ts +9 -0
- package/dist/src/internal/textLengthConstraints.js +18 -0
- package/dist/src/internal/useBinaryInput.js +3 -2
- package/dist/src/internal/useMenuLayer.d.ts +2 -1
- package/dist/src/internal/useMenuLayer.js +20 -14
- package/docs/public-api.md +14 -2
- package/package.json +1 -1
- package/src/components/shared/_internal/SDialogSurface.css +4 -0
- package/src/components/shared/_internal/SMenuItem.css +22 -1
- package/src/components/shared/controls/SButton.css +28 -0
- package/src/components/shared/controls/SChoiceCards.css +10 -3
- package/src/components/shared/controls/SMenuSurface.css +20 -0
- package/src/components/shared/data-display/SStatus.css +4 -0
- package/src/components/shared/data-display/SVirtualList.css +12 -0
- package/dist/assets/src/components/shared/_internal/SMenuItem.css_vue_type_style_index_0_src_e5bd192e_scoped_e5bd192e_lang.css +0 -2
- package/dist/assets/src/components/shared/controls/SButton.css_vue_type_style_index_0_src_52ad38b1_scoped_52ad38b1_lang.css +0 -2
- package/dist/assets/src/components/shared/controls/SChoiceCards.css_vue_type_style_index_0_src_627a8628_scoped_627a8628_lang.css +0 -2
- package/dist/assets/src/components/shared/controls/SMenuSurface.css_vue_type_style_index_0_src_bc7c7be4_scoped_bc7c7be4_lang.css +0 -2
- package/dist/assets/src/components/shared/data-display/SStatus.css_vue_type_style_index_0_src_c76fa058_scoped_c76fa058_lang.css +0 -2
- package/dist/assets/src/components/shared/data-display/SVirtualList.css_vue_type_style_index_0_src_1717877d_scoped_1717877d_lang.css +0 -2
package/dist/src/components/shared/controls/SMenuSurface.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -3,17 +3,20 @@ import { useInteractiveLeafRegistration as t } from "../../../internal/passiveCo
|
|
|
3
3
|
import { useMenuLayer as n } from "../../../internal/useMenuLayer.js";
|
|
4
4
|
import r from "../_internal/SMenuLayer.vue.js";
|
|
5
5
|
import { menuContextKey as i, menuDepthKey as a } from "../_internal/menuContext.js";
|
|
6
|
-
import
|
|
7
|
-
import
|
|
6
|
+
import o from "../_internal/SMenuItem.vue.js";
|
|
7
|
+
import ee from "../_internal/SMenuSeparator.vue.js";
|
|
8
8
|
import { validateSMenuEntries as s } from "./menu.js";
|
|
9
|
-
import { Fragment as c, Teleport as
|
|
9
|
+
import { Fragment as c, Teleport as te, computed as l, createBlock as u, createCommentVNode as ne, createElementBlock as d, createElementVNode as f, createVNode as re, defineComponent as p, inject as ie, mergeProps as m, nextTick as h, onBeforeUnmount as ae, onMounted as oe, openBlock as g, provide as _, ref as v, renderList as y, resolveComponent as se, toDisplayString as ce, toRef as le, unref as b, watch as x, withCtx as S } from "vue";
|
|
10
10
|
//#region src/components/shared/controls/SMenuSurface.vue?vue&type=script&setup=true&lang.ts
|
|
11
|
-
var
|
|
11
|
+
var C = [
|
|
12
12
|
"data-density",
|
|
13
13
|
"data-orientation",
|
|
14
14
|
"aria-label",
|
|
15
15
|
"aria-orientation"
|
|
16
|
-
],
|
|
16
|
+
], ue = ["aria-label", "data-menu-group-id"], de = {
|
|
17
|
+
class: "s-menu-group__label",
|
|
18
|
+
"aria-hidden": "true"
|
|
19
|
+
}, w = /*@__PURE__*/ p({
|
|
17
20
|
inheritAttrs: !1,
|
|
18
21
|
__name: "SMenuSurface",
|
|
19
22
|
props: {
|
|
@@ -35,116 +38,116 @@ var E = [
|
|
|
35
38
|
"submenu-back",
|
|
36
39
|
"dismiss-tree"
|
|
37
40
|
],
|
|
38
|
-
setup(
|
|
39
|
-
let
|
|
41
|
+
setup(p, { expose: w, emit: T }) {
|
|
42
|
+
let E = p, D = T, fe = e({
|
|
40
43
|
component: "SMenuSurface",
|
|
41
44
|
owner: "menu root"
|
|
42
45
|
});
|
|
43
46
|
t({ owner: "SMenuSurface" });
|
|
44
|
-
let
|
|
45
|
-
|
|
46
|
-
let
|
|
47
|
-
|
|
48
|
-
density:
|
|
47
|
+
let O = ie(a, -1) + 1;
|
|
48
|
+
_(a, O);
|
|
49
|
+
let k = v(null), A = /* @__PURE__ */ new Map();
|
|
50
|
+
_(i, {
|
|
51
|
+
density: le(E, "density"),
|
|
49
52
|
register: (e) => {
|
|
50
|
-
if (
|
|
51
|
-
return
|
|
53
|
+
if (A.has(e.entryId)) throw Error(`SMenuSurface: duplicate mounted entry id '${e.entryId}'`);
|
|
54
|
+
return A.set(e.entryId, e), () => A.delete(e.entryId);
|
|
52
55
|
}
|
|
53
56
|
});
|
|
54
|
-
let
|
|
55
|
-
|
|
56
|
-
} }),
|
|
57
|
-
let e =
|
|
57
|
+
let j = v(null), M = v(!0), N = v(null), P = v(null), F = l(() => N.value?.getElement() ?? null), { position: I, zIndex: L, open: R, close: z } = n(F, { onDismiss: (e) => {
|
|
58
|
+
j.value = null, e === "outside" && D("dismiss-tree");
|
|
59
|
+
} }), B = (e) => e.flatMap((e) => e.kind === "group" ? [...e.children] : e.kind === "separator" ? [] : [e]), V = (e) => B(E.items).find((t) => t.id === e), H = l(() => {
|
|
60
|
+
let e = j.value ? V(j.value) : void 0;
|
|
58
61
|
return e?.kind === "submenu" ? e : null;
|
|
59
|
-
}),
|
|
62
|
+
}), U = "", W = null, G = () => [...A.values()].filter((e) => e.element().isConnected).sort((e, t) => {
|
|
60
63
|
let n = e.element().compareDocumentPosition(t.element());
|
|
61
64
|
return n & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : n & Node.DOCUMENT_POSITION_PRECEDING ? 1 : 0;
|
|
62
|
-
}),
|
|
65
|
+
}), K = (e, t) => {
|
|
63
66
|
for (let t of e) t.setTabStop(!1);
|
|
64
67
|
let n = e[t];
|
|
65
68
|
n && (n.setTabStop(!0), n.focus());
|
|
66
|
-
},
|
|
67
|
-
let e =
|
|
68
|
-
e.length > 0 &&
|
|
69
|
-
},
|
|
70
|
-
let e =
|
|
71
|
-
e.length > 0 &&
|
|
72
|
-
},
|
|
73
|
-
if (typeof
|
|
74
|
-
s(
|
|
75
|
-
},
|
|
76
|
-
let t =
|
|
69
|
+
}, q = () => {
|
|
70
|
+
let e = G();
|
|
71
|
+
e.length > 0 && K(e, 0);
|
|
72
|
+
}, J = () => {
|
|
73
|
+
let e = G();
|
|
74
|
+
e.length > 0 && K(e, e.length - 1);
|
|
75
|
+
}, pe = () => {
|
|
76
|
+
if (typeof E.label != "string" || !E.label.trim()) throw TypeError("SMenuSurface: label must be a non-empty string");
|
|
77
|
+
s(E.items);
|
|
78
|
+
}, me = (e) => {
|
|
79
|
+
let t = G();
|
|
77
80
|
if (t.length === 0) return;
|
|
78
81
|
let n = t.findIndex((e) => e.isFocused());
|
|
79
|
-
|
|
80
|
-
},
|
|
82
|
+
K(t, ((n < 0 ? e === 1 ? -1 : 0 : n) + e + t.length) % t.length);
|
|
83
|
+
}, he = (e) => {
|
|
81
84
|
let t = e.toLocaleLowerCase();
|
|
82
|
-
|
|
83
|
-
|
|
85
|
+
U += t, W && clearTimeout(W), W = setTimeout(() => {
|
|
86
|
+
U = "", W = null;
|
|
84
87
|
}, 500);
|
|
85
|
-
let n = [...
|
|
88
|
+
let n = [...U].every((e) => e === t) ? t : U, r = G();
|
|
86
89
|
if (r.length === 0) return;
|
|
87
90
|
let i = r.findIndex((e) => e.isFocused()), a = [...r.slice(i + 1), ...r.slice(0, i + 1)].find((e) => e.label().trim().toLocaleLowerCase().startsWith(n));
|
|
88
|
-
a &&
|
|
91
|
+
a && K(r, r.indexOf(a));
|
|
89
92
|
};
|
|
90
|
-
async function
|
|
91
|
-
let n =
|
|
93
|
+
async function Y(e, t) {
|
|
94
|
+
let n = V(e), r = A.get(e);
|
|
92
95
|
if (n?.kind === "submenu" && !n.disabled && r) {
|
|
93
|
-
if (
|
|
94
|
-
t && await
|
|
96
|
+
if (j.value === e) {
|
|
97
|
+
t && await h(() => P.value?.focusFirst());
|
|
95
98
|
return;
|
|
96
99
|
}
|
|
97
|
-
|
|
100
|
+
j.value && z("outside"), M.value = t, j.value = e, await R({
|
|
98
101
|
type: "element",
|
|
99
102
|
element: r.element(),
|
|
100
103
|
align: "left",
|
|
101
104
|
placement: "inline"
|
|
102
|
-
}, r.element()), t && await
|
|
105
|
+
}, r.element()), t && await h(() => P.value?.focusFirst());
|
|
103
106
|
}
|
|
104
107
|
}
|
|
105
|
-
function
|
|
106
|
-
|
|
108
|
+
function X(e) {
|
|
109
|
+
j.value &&= (z(e), null);
|
|
107
110
|
}
|
|
108
|
-
function
|
|
109
|
-
e.kind === "submenu" && !e.disabled ?
|
|
111
|
+
function Z(e) {
|
|
112
|
+
e.kind === "submenu" && !e.disabled ? Y(e.id, !1) : j.value && X("outside");
|
|
110
113
|
}
|
|
111
|
-
function
|
|
112
|
-
e.kind === "submenu" || e.disabled ||
|
|
114
|
+
function Q(e, t) {
|
|
115
|
+
e.kind === "submenu" || e.disabled || D("select", e, t);
|
|
113
116
|
}
|
|
114
|
-
function
|
|
115
|
-
|
|
117
|
+
function ge(e, t) {
|
|
118
|
+
D("select", e, t);
|
|
116
119
|
}
|
|
117
120
|
function $() {
|
|
118
|
-
return
|
|
121
|
+
return G().find((e) => e.isFocused());
|
|
119
122
|
}
|
|
120
|
-
let
|
|
123
|
+
let _e = (e) => {
|
|
121
124
|
let t = e.target;
|
|
122
|
-
if (e.currentTarget !== t && !
|
|
125
|
+
if (e.currentTarget !== t && !G().some((e) => e.ownsEventTarget(t))) return;
|
|
123
126
|
if (e.key === "Tab") {
|
|
124
|
-
|
|
127
|
+
D("tab", e);
|
|
125
128
|
return;
|
|
126
129
|
}
|
|
127
130
|
if (e.key === "Escape") {
|
|
128
|
-
e.preventDefault(),
|
|
131
|
+
e.preventDefault(), D("escape");
|
|
129
132
|
return;
|
|
130
133
|
}
|
|
131
|
-
let n =
|
|
132
|
-
if (
|
|
134
|
+
let n = E.orientation === "horizontal" ? "ArrowRight" : "ArrowDown", r = E.orientation === "horizontal" ? "ArrowLeft" : "ArrowUp";
|
|
135
|
+
if (E.orientation === "vertical" && (e.key === "ArrowRight" || e.key === "ArrowLeft")) {
|
|
133
136
|
let t = $();
|
|
134
|
-
e.preventDefault(), e.key === "ArrowRight" && t?.hasSubmenu() ?
|
|
137
|
+
e.preventDefault(), e.key === "ArrowRight" && t?.hasSubmenu() ? Y(t.entryId, !0) : e.key === "ArrowLeft" && O > 0 && D("submenu-back");
|
|
135
138
|
return;
|
|
136
139
|
}
|
|
137
140
|
if (e.key === n || e.key === r) {
|
|
138
|
-
e.preventDefault(),
|
|
141
|
+
e.preventDefault(), me(e.key === n ? 1 : -1);
|
|
139
142
|
return;
|
|
140
143
|
}
|
|
141
|
-
if (
|
|
144
|
+
if (E.orientation === "horizontal" && e.key === "ArrowDown") {
|
|
142
145
|
let t = $();
|
|
143
|
-
t?.hasSubmenu() && (e.preventDefault(),
|
|
146
|
+
t?.hasSubmenu() && (e.preventDefault(), Y(t.entryId, !0));
|
|
144
147
|
return;
|
|
145
148
|
}
|
|
146
149
|
if (e.key === "Home" || e.key === "End") {
|
|
147
|
-
e.preventDefault(), e.key === "Home" ?
|
|
150
|
+
e.preventDefault(), e.key === "Home" ? q() : J();
|
|
148
151
|
return;
|
|
149
152
|
}
|
|
150
153
|
if (e.key === "Enter" || e.key === " ") {
|
|
@@ -152,76 +155,95 @@ var E = [
|
|
|
152
155
|
t && t.activate(e);
|
|
153
156
|
return;
|
|
154
157
|
}
|
|
155
|
-
e.key.length === 1 && !e.altKey && !e.ctrlKey && !e.metaKey &&
|
|
156
|
-
},
|
|
158
|
+
e.key.length === 1 && !e.altKey && !e.ctrlKey && !e.metaKey && he(e.key);
|
|
159
|
+
}, ve = (e) => {
|
|
157
160
|
let t = e.relatedTarget;
|
|
158
|
-
t instanceof Node && (
|
|
161
|
+
t instanceof Node && (k.value?.contains(t) || F.value?.contains(t)) || D("focus-exit", e);
|
|
159
162
|
};
|
|
160
|
-
return
|
|
161
|
-
|
|
162
|
-
}),
|
|
163
|
-
|
|
163
|
+
return oe(() => {
|
|
164
|
+
E.autofocus && h(E.initialFocus === "last" ? J : q);
|
|
165
|
+
}), x(() => [E.label, E.items], () => {
|
|
166
|
+
pe(), j.value && !H.value && X("outside");
|
|
164
167
|
}, {
|
|
165
168
|
immediate: !0,
|
|
166
169
|
deep: !0
|
|
167
|
-
}),
|
|
168
|
-
|
|
169
|
-
}),
|
|
170
|
-
focusFirst:
|
|
171
|
-
focusLast:
|
|
170
|
+
}), ae(() => {
|
|
171
|
+
W && clearTimeout(W);
|
|
172
|
+
}), w({
|
|
173
|
+
focusFirst: q,
|
|
174
|
+
focusLast: J
|
|
172
175
|
}), (e, t) => {
|
|
173
|
-
let n =
|
|
174
|
-
return
|
|
176
|
+
let n = se("SMenuSurface", !0);
|
|
177
|
+
return g(), d("div", m({
|
|
175
178
|
ref_key: "surfaceRef",
|
|
176
|
-
ref:
|
|
177
|
-
},
|
|
179
|
+
ref: k
|
|
180
|
+
}, b(fe).bindings(), {
|
|
178
181
|
class: "s-menu-surface",
|
|
179
|
-
"data-density":
|
|
180
|
-
"data-orientation":
|
|
181
|
-
"data-menu-depth":
|
|
182
|
+
"data-density": p.density,
|
|
183
|
+
"data-orientation": p.orientation,
|
|
184
|
+
"data-menu-depth": O,
|
|
182
185
|
role: "menu",
|
|
183
|
-
"aria-label":
|
|
184
|
-
"aria-orientation":
|
|
185
|
-
onKeydown:
|
|
186
|
-
onFocusout:
|
|
187
|
-
}), [(
|
|
186
|
+
"aria-label": p.label,
|
|
187
|
+
"aria-orientation": p.orientation,
|
|
188
|
+
onKeydown: _e,
|
|
189
|
+
onFocusout: ve
|
|
190
|
+
}), [(g(!0), d(c, null, y(p.items, (e) => (g(), d(c, { key: e.id }, [e.kind === "separator" ? (g(), u(ee, {
|
|
188
191
|
key: 0,
|
|
189
192
|
"entry-id": e.id
|
|
190
|
-
}, null, 8, ["entry-id"])) : (
|
|
193
|
+
}, null, 8, ["entry-id"])) : e.kind === "group" ? (g(), d("div", {
|
|
191
194
|
key: 1,
|
|
195
|
+
class: "s-menu-group",
|
|
196
|
+
role: "group",
|
|
197
|
+
"aria-label": e.label,
|
|
198
|
+
"data-menu-group-id": e.id
|
|
199
|
+
}, [f("div", de, ce(e.label), 1), (g(!0), d(c, null, y(e.children, (e) => (g(), u(o, {
|
|
200
|
+
key: e.id,
|
|
192
201
|
entry: e,
|
|
193
|
-
"submenu-open":
|
|
194
|
-
onSelect: (t) =>
|
|
195
|
-
onOpenSubmenu: (t) =>
|
|
196
|
-
onPointerIntent: (t) =>
|
|
202
|
+
"submenu-open": H.value?.id === e.id,
|
|
203
|
+
onSelect: (t) => Q(e, t),
|
|
204
|
+
onOpenSubmenu: (t) => Y(e.id, !0),
|
|
205
|
+
onPointerIntent: (t) => Z(e)
|
|
197
206
|
}, null, 8, [
|
|
198
207
|
"entry",
|
|
199
208
|
"submenu-open",
|
|
200
209
|
"onSelect",
|
|
201
210
|
"onOpenSubmenu",
|
|
202
211
|
"onPointerIntent"
|
|
203
|
-
]))
|
|
212
|
+
]))), 128))], 8, ue)) : (g(), u(o, {
|
|
213
|
+
key: 2,
|
|
214
|
+
entry: e,
|
|
215
|
+
"submenu-open": H.value?.id === e.id,
|
|
216
|
+
onSelect: (t) => Q(e, t),
|
|
217
|
+
onOpenSubmenu: (t) => Y(e.id, !0),
|
|
218
|
+
onPointerIntent: (t) => Z(e)
|
|
219
|
+
}, null, 8, [
|
|
220
|
+
"entry",
|
|
221
|
+
"submenu-open",
|
|
222
|
+
"onSelect",
|
|
223
|
+
"onOpenSubmenu",
|
|
224
|
+
"onPointerIntent"
|
|
225
|
+
]))], 64))), 128)), (g(), u(te, { to: "body" }, [H.value ? (g(), u(r, {
|
|
204
226
|
key: 0,
|
|
205
227
|
ref_key: "submenuLayerRef",
|
|
206
|
-
ref:
|
|
228
|
+
ref: N,
|
|
207
229
|
kind: "submenu",
|
|
208
|
-
"landmark-label": `${
|
|
209
|
-
position:
|
|
210
|
-
"z-index":
|
|
230
|
+
"landmark-label": `${p.label}: ${H.value.label}`,
|
|
231
|
+
position: b(I),
|
|
232
|
+
"z-index": b(L)
|
|
211
233
|
}, {
|
|
212
|
-
default:
|
|
234
|
+
default: S(() => [re(n, {
|
|
213
235
|
ref_key: "submenuSurfaceRef",
|
|
214
|
-
ref:
|
|
215
|
-
label: `${
|
|
216
|
-
items:
|
|
217
|
-
density:
|
|
236
|
+
ref: P,
|
|
237
|
+
label: `${p.label}: ${H.value.label}`,
|
|
238
|
+
items: H.value.children,
|
|
239
|
+
density: p.density,
|
|
218
240
|
orientation: "vertical",
|
|
219
|
-
autofocus:
|
|
220
|
-
onEscape: t[0] ||= (e) =>
|
|
221
|
-
onSubmenuBack: t[1] ||= (e) =>
|
|
222
|
-
onDismissTree: t[2] ||= (e) =>
|
|
223
|
-
onSelect:
|
|
224
|
-
onTab: t[3] ||= (e) =>
|
|
241
|
+
autofocus: M.value,
|
|
242
|
+
onEscape: t[0] ||= (e) => X("escape"),
|
|
243
|
+
onSubmenuBack: t[1] ||= (e) => X("escape"),
|
|
244
|
+
onDismissTree: t[2] ||= (e) => D("dismiss-tree"),
|
|
245
|
+
onSelect: ge,
|
|
246
|
+
onTab: t[3] ||= (e) => D("tab", e)
|
|
225
247
|
}, null, 8, [
|
|
226
248
|
"label",
|
|
227
249
|
"items",
|
|
@@ -233,9 +255,9 @@ var E = [
|
|
|
233
255
|
"landmark-label",
|
|
234
256
|
"position",
|
|
235
257
|
"z-index"
|
|
236
|
-
])) :
|
|
258
|
+
])) : ne("", !0)]))], 16, C);
|
|
237
259
|
};
|
|
238
260
|
}
|
|
239
261
|
});
|
|
240
262
|
//#endregion
|
|
241
|
-
export {
|
|
263
|
+
export { w as default };
|
|
@@ -65,6 +65,8 @@ export interface Props {
|
|
|
65
65
|
helpText?: string;
|
|
66
66
|
id?: string;
|
|
67
67
|
rows?: number;
|
|
68
|
+
minLength?: number;
|
|
69
|
+
maxLength?: number;
|
|
68
70
|
size?: STextareaSize;
|
|
69
71
|
autoResize?: boolean;
|
|
70
72
|
maxRows?: number;
|
|
@@ -75,10 +77,12 @@ export interface Props {
|
|
|
75
77
|
monospace?: boolean;
|
|
76
78
|
}
|
|
77
79
|
declare const __VLS_export: import('vue').DefineComponent<Props, STextareaApi, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
80
|
+
blur: (focusEvent: FocusEvent) => any;
|
|
78
81
|
click: (mouseEvent: MouseEvent) => any;
|
|
79
82
|
compositionend: (compositionEvent: CompositionEvent) => any;
|
|
80
83
|
compositionstart: (compositionEvent: CompositionEvent) => any;
|
|
81
84
|
compositionupdate: (compositionEvent: CompositionEvent) => any;
|
|
85
|
+
focus: (focusEvent: FocusEvent) => any;
|
|
82
86
|
keydown: (keyboardEvent: KeyboardEvent) => any;
|
|
83
87
|
keyup: (keyboardEvent: KeyboardEvent) => any;
|
|
84
88
|
paste: (clipboardEvent: ClipboardEvent) => any;
|
|
@@ -86,10 +90,12 @@ declare const __VLS_export: import('vue').DefineComponent<Props, STextareaApi, {
|
|
|
86
90
|
"selection-change": (selection: STextareaSelection) => any;
|
|
87
91
|
"state-change": (state: STextareaState) => any;
|
|
88
92
|
}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
|
|
93
|
+
onBlur?: ((focusEvent: FocusEvent) => any) | undefined;
|
|
89
94
|
onClick?: ((mouseEvent: MouseEvent) => any) | undefined;
|
|
90
95
|
onCompositionend?: ((compositionEvent: CompositionEvent) => any) | undefined;
|
|
91
96
|
onCompositionstart?: ((compositionEvent: CompositionEvent) => any) | undefined;
|
|
92
97
|
onCompositionupdate?: ((compositionEvent: CompositionEvent) => any) | undefined;
|
|
98
|
+
onFocus?: ((focusEvent: FocusEvent) => any) | undefined;
|
|
93
99
|
onKeydown?: ((keyboardEvent: KeyboardEvent) => any) | undefined;
|
|
94
100
|
onKeyup?: ((keyboardEvent: KeyboardEvent) => any) | undefined;
|
|
95
101
|
onPaste?: ((clipboardEvent: ClipboardEvent) => any) | undefined;
|
|
@@ -111,6 +117,8 @@ declare const __VLS_export: import('vue').DefineComponent<Props, STextareaApi, {
|
|
|
111
117
|
errorMessage: string;
|
|
112
118
|
modelValue: string | null;
|
|
113
119
|
appearance: STextareaAppearance;
|
|
120
|
+
minLength: number;
|
|
121
|
+
maxLength: number;
|
|
114
122
|
autoResize: boolean;
|
|
115
123
|
maxRows: number;
|
|
116
124
|
minHeight: number;
|