@nightshadeui/core 2.7.0 → 2.8.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/dist/components/BaseMenu.vue.d.ts +280 -0
- package/dist/components/Bubble.vue.d.ts +32 -0
- package/dist/components/ContextMenu.vue.d.ts +391 -0
- package/dist/components/ContextPopup.vue.d.ts +96 -0
- package/dist/components/InputBase.vue.d.ts +28 -1
- package/dist/components/InputText.vue.d.ts +191 -2
- package/dist/components/InputTextarea.vue.d.ts +191 -2
- package/dist/components/Tab.vue.d.ts +19 -1
- package/dist/components/ToolPanel.vue.d.ts +41 -0
- package/dist/components/index.d.ts +6 -2
- package/dist/core.css +1 -1
- package/dist/core.mjs +638 -388
- package/dist/index.d.ts +1 -0
- package/dist/types/MenuItem.d.ts +13 -0
- package/dist/utils/props.d.ts +1 -0
- package/package.json +1 -1
- package/dist/components/InputSelect.vue.d.ts +0 -20
package/dist/core.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
const
|
|
3
|
-
const e =
|
|
4
|
-
for (const [
|
|
5
|
-
e[
|
|
1
|
+
import { openBlock as r, createBlock as y, resolveDynamicComponent as S, normalizeClass as h, withCtx as v, renderSlot as d, createElementBlock as f, createCommentVNode as p, toDisplayString as k, resolveComponent as m, Fragment as T, renderList as A, createElementVNode as b, Transition as V, Teleport as H, withModifiers as z, normalizeStyle as M, mergeProps as x, createVNode as O } from "vue";
|
|
2
|
+
const c = (n, t) => {
|
|
3
|
+
const e = n.__vccOpts || n;
|
|
4
|
+
for (const [l, o] of t)
|
|
5
|
+
e[l] = o;
|
|
6
6
|
return e;
|
|
7
|
-
},
|
|
7
|
+
}, E = {
|
|
8
8
|
props: {
|
|
9
9
|
tagName: { type: String, default: "button" },
|
|
10
10
|
href: { type: String },
|
|
@@ -49,80 +49,240 @@ const d = (t, n) => {
|
|
|
49
49
|
},
|
|
50
50
|
effectiveStyle() {
|
|
51
51
|
const {
|
|
52
|
-
baseStyle:
|
|
53
|
-
hoverOverrides:
|
|
52
|
+
baseStyle: n,
|
|
53
|
+
hoverOverrides: t = {},
|
|
54
54
|
activeOverrides: e = {},
|
|
55
|
-
focusOverrides:
|
|
56
|
-
active:
|
|
57
|
-
hover:
|
|
58
|
-
focus:
|
|
59
|
-
forceActive:
|
|
60
|
-
forceHover:
|
|
61
|
-
forceFocus:
|
|
62
|
-
} = this,
|
|
63
|
-
return (
|
|
55
|
+
focusOverrides: l = {},
|
|
56
|
+
active: o,
|
|
57
|
+
hover: s,
|
|
58
|
+
focus: a,
|
|
59
|
+
forceActive: i,
|
|
60
|
+
forceHover: u,
|
|
61
|
+
forceFocus: B
|
|
62
|
+
} = this, g = Object.assign({}, n);
|
|
63
|
+
return (o || i) && Object.assign(g, e), (s || u) && Object.assign(g, t), (a || B) && Object.assign(g, l), g;
|
|
64
64
|
}
|
|
65
65
|
},
|
|
66
66
|
methods: {
|
|
67
67
|
// TODO add debounce
|
|
68
68
|
}
|
|
69
|
-
},
|
|
69
|
+
}, D = {
|
|
70
70
|
key: 0,
|
|
71
71
|
class: "Label"
|
|
72
72
|
};
|
|
73
|
-
function
|
|
74
|
-
return
|
|
73
|
+
function N(n, t, e, l, o, s) {
|
|
74
|
+
return r(), y(S(e.tagName), {
|
|
75
75
|
ref: "button",
|
|
76
|
-
class:
|
|
77
|
-
`
|
|
78
|
-
`
|
|
79
|
-
`input-size-${o.effectiveStyle.size}`,
|
|
76
|
+
class: h(["Btn InputElement", [
|
|
77
|
+
`ui-${s.effectiveStyle.kind}`,
|
|
78
|
+
`input-size-${s.effectiveStyle.size}`,
|
|
80
79
|
`Btn-iconPos-${e.iconPos}`,
|
|
81
80
|
{
|
|
82
|
-
"Btn-ghost":
|
|
83
|
-
"Btn-round":
|
|
84
|
-
"Btn-outline":
|
|
85
|
-
"Btn-flat":
|
|
81
|
+
"Btn-ghost": s.effectiveStyle.ghost,
|
|
82
|
+
"Btn-round": s.effectiveStyle.round,
|
|
83
|
+
"Btn-outline": s.effectiveStyle.outline,
|
|
84
|
+
"Btn-flat": s.effectiveStyle.flat,
|
|
86
85
|
"Btn-square": e.square,
|
|
87
86
|
"Btn-block": e.block,
|
|
88
|
-
"Btn-disabled": e.disabled ||
|
|
87
|
+
"Btn-disabled": e.disabled || o.blocked,
|
|
89
88
|
"Btn-forceFocus": e.forceFocus,
|
|
90
89
|
"Btn-forceHover": e.forceHover,
|
|
91
90
|
"Btn-forceActive": e.forceActive
|
|
92
91
|
}
|
|
93
92
|
]]),
|
|
94
|
-
disabled: e.disabled ||
|
|
93
|
+
disabled: e.disabled || o.blocked,
|
|
95
94
|
title: e.title ?? e.label,
|
|
96
95
|
href: e.href,
|
|
97
|
-
onMouseenter:
|
|
98
|
-
onMouseleave:
|
|
99
|
-
onMousedown:
|
|
100
|
-
onMouseup:
|
|
101
|
-
onMouseout:
|
|
102
|
-
onFocusin:
|
|
103
|
-
onFocusout:
|
|
96
|
+
onMouseenter: t[0] || (t[0] = (a) => o.hover = !0),
|
|
97
|
+
onMouseleave: t[1] || (t[1] = (a) => o.hover = !1),
|
|
98
|
+
onMousedown: t[2] || (t[2] = (a) => o.active = !0),
|
|
99
|
+
onMouseup: t[3] || (t[3] = (a) => o.active = !1),
|
|
100
|
+
onMouseout: t[4] || (t[4] = (a) => o.active = !1),
|
|
101
|
+
onFocusin: t[5] || (t[5] = (a) => o.focus = !0),
|
|
102
|
+
onFocusout: t[6] || (t[6] = (a) => o.focus = !1)
|
|
104
103
|
}, {
|
|
105
|
-
default:
|
|
106
|
-
|
|
107
|
-
hover:
|
|
108
|
-
|
|
104
|
+
default: v(() => [
|
|
105
|
+
d(n.$slots, "before", {
|
|
106
|
+
hover: o.hover,
|
|
107
|
+
active: o.active,
|
|
108
|
+
focus: o.focus,
|
|
109
|
+
blocked: o.blocked
|
|
110
|
+
}, void 0, !0),
|
|
111
|
+
d(n.$slots, "default", {
|
|
112
|
+
hover: o.hover,
|
|
113
|
+
active: o.active,
|
|
114
|
+
focus: o.focus,
|
|
115
|
+
blocked: o.blocked
|
|
109
116
|
}, () => [
|
|
110
|
-
e.icon ? (
|
|
117
|
+
e.icon ? (r(), f("i", {
|
|
111
118
|
key: 0,
|
|
112
|
-
class:
|
|
113
|
-
}, null, 2)) :
|
|
119
|
+
class: h([e.icon, "Icon"])
|
|
120
|
+
}, null, 2)) : p("", !0),
|
|
121
|
+
d(n.$slots, "label", {
|
|
122
|
+
hover: o.hover,
|
|
123
|
+
active: o.active,
|
|
124
|
+
focus: o.focus,
|
|
125
|
+
blocked: o.blocked
|
|
126
|
+
}, () => [
|
|
127
|
+
e.label ? (r(), f("span", D, k(e.label), 1)) : p("", !0)
|
|
128
|
+
], !0)
|
|
114
129
|
], !0),
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
blocked:
|
|
130
|
+
d(n.$slots, "after", {
|
|
131
|
+
hover: o.hover,
|
|
132
|
+
active: o.active,
|
|
133
|
+
focus: o.focus,
|
|
134
|
+
blocked: o.blocked
|
|
120
135
|
}, void 0, !0)
|
|
121
136
|
]),
|
|
122
137
|
_: 3
|
|
123
138
|
}, 40, ["class", "disabled", "title", "href"]);
|
|
124
139
|
}
|
|
125
|
-
const
|
|
140
|
+
const $ = /* @__PURE__ */ c(E, [["render", N], ["__scopeId", "data-v-144a5c7b"]]), L = {
|
|
141
|
+
props: {
|
|
142
|
+
tagName: { type: String, default: "div" },
|
|
143
|
+
align: { type: String, default: "stretch" },
|
|
144
|
+
justify: { type: String },
|
|
145
|
+
gap: { type: String, default: "m" }
|
|
146
|
+
}
|
|
147
|
+
};
|
|
148
|
+
function G(n, t, e, l, o, s) {
|
|
149
|
+
return r(), y(S(e.tagName), {
|
|
150
|
+
class: h(["VGroup", [
|
|
151
|
+
`VGroup-align-${e.align}`,
|
|
152
|
+
`VGroup-justify-${e.justify}`,
|
|
153
|
+
`VGroup-gap-${e.gap}`
|
|
154
|
+
]])
|
|
155
|
+
}, {
|
|
156
|
+
default: v(() => [
|
|
157
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
158
|
+
]),
|
|
159
|
+
_: 3
|
|
160
|
+
}, 8, ["class"]);
|
|
161
|
+
}
|
|
162
|
+
const P = /* @__PURE__ */ c(L, [["render", G], ["__scopeId", "data-v-044d3ec4"]]), R = {
|
|
163
|
+
components: {
|
|
164
|
+
Btn: $,
|
|
165
|
+
VGroup: P
|
|
166
|
+
},
|
|
167
|
+
props: {
|
|
168
|
+
items: { type: Array, default: () => [] },
|
|
169
|
+
size: { type: String, default: "m" },
|
|
170
|
+
round: { type: Boolean, default: !1 },
|
|
171
|
+
autoFocus: { type: Boolean, default: !1 }
|
|
172
|
+
},
|
|
173
|
+
emits: [
|
|
174
|
+
"activate"
|
|
175
|
+
],
|
|
176
|
+
mounted() {
|
|
177
|
+
this.autoFocus && this.$nextTick(() => {
|
|
178
|
+
const n = this.getFocusableEls()[0];
|
|
179
|
+
n && n.focus();
|
|
180
|
+
});
|
|
181
|
+
},
|
|
182
|
+
methods: {
|
|
183
|
+
getItemType(n) {
|
|
184
|
+
return n.type || "normal";
|
|
185
|
+
},
|
|
186
|
+
getFocusableEls() {
|
|
187
|
+
return Array.from(this.$el.querySelectorAll(".Item:not(:disabled)"));
|
|
188
|
+
},
|
|
189
|
+
onKeyDown(n) {
|
|
190
|
+
if (n.key === "ArrowUp" || n.key === "ArrowDown") {
|
|
191
|
+
n.preventDefault();
|
|
192
|
+
const t = this.getFocusableEls();
|
|
193
|
+
if (!t.length)
|
|
194
|
+
return;
|
|
195
|
+
const e = document.activeElement;
|
|
196
|
+
let l = t.findIndex((o) => o === e || o.contains(e));
|
|
197
|
+
n.key === "ArrowDown" ? l = (l + 1) % t.length : l = (l + t.length - 1) % t.length, t[l]?.focus();
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
onItemClick(n, t) {
|
|
201
|
+
n.disabled || (typeof n.activate == "function" && n.activate(), this.$emit("activate", n, t));
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}, K = {
|
|
205
|
+
key: 0,
|
|
206
|
+
class: "Header"
|
|
207
|
+
}, q = {
|
|
208
|
+
key: 1,
|
|
209
|
+
class: "Separator"
|
|
210
|
+
}, U = { class: "Title" }, W = {
|
|
211
|
+
key: 0,
|
|
212
|
+
class: "CheckIcon"
|
|
213
|
+
};
|
|
214
|
+
function Y(n, t, e, l, o, s) {
|
|
215
|
+
const a = m("Btn"), i = m("VGroup");
|
|
216
|
+
return r(), y(i, {
|
|
217
|
+
class: h(["BaseMenu", [
|
|
218
|
+
`input-size-${e.size}`
|
|
219
|
+
]]),
|
|
220
|
+
onKeydown: s.onKeyDown
|
|
221
|
+
}, {
|
|
222
|
+
default: v(() => [
|
|
223
|
+
(r(!0), f(T, null, A(e.items, (u, B) => (r(), f(T, { key: B }, [
|
|
224
|
+
s.getItemType(u) === "header" ? (r(), f("div", K, k(u.title), 1)) : p("", !0),
|
|
225
|
+
s.getItemType(u) === "separator" ? (r(), f("div", q)) : p("", !0),
|
|
226
|
+
s.getItemType(u) === "normal" ? (r(), y(a, {
|
|
227
|
+
key: 2,
|
|
228
|
+
class: h(["Item", {
|
|
229
|
+
"Item-checked": u.checked
|
|
230
|
+
}]),
|
|
231
|
+
kind: u.kind || "base",
|
|
232
|
+
size: e.size,
|
|
233
|
+
round: e.round,
|
|
234
|
+
flat: !0,
|
|
235
|
+
ghost: u.ghost ?? !0,
|
|
236
|
+
outline: u.outline,
|
|
237
|
+
disabled: u.disabled,
|
|
238
|
+
icon: u.icon,
|
|
239
|
+
onClick: (g) => s.onItemClick(u, g)
|
|
240
|
+
}, {
|
|
241
|
+
label: v(() => [
|
|
242
|
+
b("div", U, k(u.title), 1)
|
|
243
|
+
]),
|
|
244
|
+
after: v(() => [
|
|
245
|
+
u.checked ? (r(), f("span", W, " ✓ ")) : p("", !0)
|
|
246
|
+
]),
|
|
247
|
+
_: 2
|
|
248
|
+
}, 1032, ["class", "kind", "size", "round", "ghost", "outline", "disabled", "icon", "onClick"])) : p("", !0)
|
|
249
|
+
], 64))), 128))
|
|
250
|
+
]),
|
|
251
|
+
_: 1
|
|
252
|
+
}, 8, ["class", "onKeydown"]);
|
|
253
|
+
}
|
|
254
|
+
const I = /* @__PURE__ */ c(R, [["render", Y], ["__scopeId", "data-v-c6736688"]]), J = {
|
|
255
|
+
props: {
|
|
256
|
+
dir: { type: String, default: "bottom" },
|
|
257
|
+
align: { type: String, default: "start" },
|
|
258
|
+
arrowShown: { type: Boolean, default: !0 }
|
|
259
|
+
}
|
|
260
|
+
}, Q = {
|
|
261
|
+
key: 0,
|
|
262
|
+
class: "Arrow"
|
|
263
|
+
}, X = { class: "Body" };
|
|
264
|
+
function Z(n, t, e, l, o, s) {
|
|
265
|
+
return r(), y(V, {
|
|
266
|
+
name: "fade-" + e.dir,
|
|
267
|
+
appear: ""
|
|
268
|
+
}, {
|
|
269
|
+
default: v(() => [
|
|
270
|
+
b("div", {
|
|
271
|
+
class: h(["Bubble", [
|
|
272
|
+
`Bubble-${e.dir}`,
|
|
273
|
+
`Bubble-${e.align}`
|
|
274
|
+
]])
|
|
275
|
+
}, [
|
|
276
|
+
e.arrowShown ? (r(), f("div", Q)) : p("", !0),
|
|
277
|
+
b("div", X, [
|
|
278
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
279
|
+
])
|
|
280
|
+
], 2)
|
|
281
|
+
]),
|
|
282
|
+
_: 3
|
|
283
|
+
}, 8, ["name"]);
|
|
284
|
+
}
|
|
285
|
+
const ee = /* @__PURE__ */ c(J, [["render", Z], ["__scopeId", "data-v-0840cacf"]]), te = {
|
|
126
286
|
props: {
|
|
127
287
|
mark: { type: String, default: "check" },
|
|
128
288
|
modelValue: { type: Boolean },
|
|
@@ -162,67 +322,241 @@ const C = /* @__PURE__ */ d(j, [["render", $], ["__scopeId", "data-v-05f8e48e"]]
|
|
|
162
322
|
},
|
|
163
323
|
effectiveStyle() {
|
|
164
324
|
const {
|
|
165
|
-
baseStyle:
|
|
166
|
-
hoverOverrides:
|
|
325
|
+
baseStyle: n,
|
|
326
|
+
hoverOverrides: t = {},
|
|
167
327
|
focusOverrides: e = {},
|
|
168
|
-
hover:
|
|
169
|
-
focus:
|
|
170
|
-
forceHover:
|
|
171
|
-
forceFocus:
|
|
172
|
-
} = this,
|
|
173
|
-
return (
|
|
328
|
+
hover: l,
|
|
329
|
+
focus: o,
|
|
330
|
+
forceHover: s,
|
|
331
|
+
forceFocus: a
|
|
332
|
+
} = this, i = Object.assign({}, n);
|
|
333
|
+
return (l || s) && Object.assign(i, t), (o || a) && Object.assign(i, e), i;
|
|
174
334
|
}
|
|
175
335
|
},
|
|
176
336
|
methods: {
|
|
177
|
-
onChange(
|
|
178
|
-
this.$emit("update:modelValue",
|
|
337
|
+
onChange(n) {
|
|
338
|
+
this.$emit("update:modelValue", n.target.checked);
|
|
179
339
|
}
|
|
180
340
|
}
|
|
181
|
-
},
|
|
182
|
-
function
|
|
183
|
-
return
|
|
184
|
-
class:
|
|
185
|
-
`
|
|
186
|
-
`
|
|
187
|
-
`input-size-${o.effectiveStyle.size}`,
|
|
341
|
+
}, ne = ["checked", "disabled"];
|
|
342
|
+
function oe(n, t, e, l, o, s) {
|
|
343
|
+
return r(), f("label", {
|
|
344
|
+
class: h(["Checkbox InputElement", [
|
|
345
|
+
`ui-${s.effectiveStyle.kind}`,
|
|
346
|
+
`input-size-${s.effectiveStyle.size}`,
|
|
188
347
|
`Checkbox-mark-${e.mark}`,
|
|
189
348
|
{
|
|
190
349
|
"Checkbox-active": !!e.modelValue,
|
|
191
|
-
"Checkbox-outline":
|
|
192
|
-
"Checkbox-round":
|
|
193
|
-
"Checkbox-flat":
|
|
350
|
+
"Checkbox-outline": s.effectiveStyle.outline,
|
|
351
|
+
"Checkbox-round": s.effectiveStyle.round,
|
|
352
|
+
"Checkbox-flat": s.effectiveStyle.flat,
|
|
194
353
|
"Checkbox-disabled": e.disabled,
|
|
195
354
|
"Checkbox-force-focus": e.forceFocus,
|
|
196
355
|
"Checkbox-force-hover": e.forceHover
|
|
197
356
|
}
|
|
198
357
|
]]),
|
|
199
358
|
tabindex: "0",
|
|
200
|
-
onMouseenter:
|
|
201
|
-
onMouseleave:
|
|
202
|
-
onFocusin:
|
|
203
|
-
onFocusout:
|
|
359
|
+
onMouseenter: t[1] || (t[1] = (a) => o.hover = !0),
|
|
360
|
+
onMouseleave: t[2] || (t[2] = (a) => o.hover = !1),
|
|
361
|
+
onFocusin: t[3] || (t[3] = (a) => o.focus = !0),
|
|
362
|
+
onFocusout: t[4] || (t[4] = (a) => o.focus = !1)
|
|
204
363
|
}, [
|
|
205
|
-
|
|
364
|
+
e.modelValue ? d(n.$slots, "active", { key: 0 }, () => [
|
|
365
|
+
t[5] || (t[5] = b("div", { class: "Mark" }, null, -1))
|
|
366
|
+
], !0) : p("", !0),
|
|
367
|
+
e.modelValue ? p("", !0) : d(n.$slots, "inactive", { key: 1 }, void 0, !0),
|
|
368
|
+
b("input", {
|
|
206
369
|
type: "checkbox",
|
|
207
370
|
checked: e.modelValue,
|
|
208
371
|
disabled: e.disabled,
|
|
209
|
-
onChange:
|
|
210
|
-
}, null, 40,
|
|
372
|
+
onChange: t[0] || (t[0] = (...a) => s.onChange && s.onChange(...a))
|
|
373
|
+
}, null, 40, ne)
|
|
211
374
|
], 34);
|
|
212
375
|
}
|
|
213
|
-
const
|
|
376
|
+
const se = /* @__PURE__ */ c(te, [["render", oe], ["__scopeId", "data-v-24a3751b"]]);
|
|
377
|
+
function C(n, t) {
|
|
378
|
+
const e = {}, l = Object.keys(t.props || {});
|
|
379
|
+
for (const o of l)
|
|
380
|
+
e[o] = n.$props[o];
|
|
381
|
+
return e;
|
|
382
|
+
}
|
|
383
|
+
const le = {
|
|
384
|
+
props: {
|
|
385
|
+
dir: { type: String, default: "v" },
|
|
386
|
+
align: { type: String, default: "auto" },
|
|
387
|
+
anchorRef: { type: String },
|
|
388
|
+
anchorDir: { type: String, default: "middle" },
|
|
389
|
+
overlayEnabled: { type: Boolean, default: !0 },
|
|
390
|
+
overlayShown: { type: Boolean, default: !0 },
|
|
391
|
+
arrowShown: { type: Boolean, default: !0 }
|
|
392
|
+
},
|
|
393
|
+
emits: ["hide", "mouseenter", "mouseleave", "ready"],
|
|
394
|
+
data() {
|
|
395
|
+
return {
|
|
396
|
+
pos: { x: 0, y: 0 },
|
|
397
|
+
actualDir: "bottom",
|
|
398
|
+
actualAlign: "start",
|
|
399
|
+
ready: !1
|
|
400
|
+
};
|
|
401
|
+
},
|
|
402
|
+
computed: {
|
|
403
|
+
bubbleStyle() {
|
|
404
|
+
const { x: n, y: t } = this.pos;
|
|
405
|
+
return {
|
|
406
|
+
left: `${n}px`,
|
|
407
|
+
top: `${t}px`,
|
|
408
|
+
"pointer-events": "auto"
|
|
409
|
+
};
|
|
410
|
+
}
|
|
411
|
+
},
|
|
412
|
+
mounted() {
|
|
413
|
+
this.$nextTick(() => this.calcPos()), window.addEventListener("resize", this.onResize), window.addEventListener("keydown", this.onKeyDown);
|
|
414
|
+
},
|
|
415
|
+
beforeUnmount() {
|
|
416
|
+
window.removeEventListener("resize", this.onResize), window.removeEventListener("keydown", this.onKeyDown);
|
|
417
|
+
},
|
|
418
|
+
methods: {
|
|
419
|
+
hide() {
|
|
420
|
+
this.$emit("hide");
|
|
421
|
+
},
|
|
422
|
+
calcPos() {
|
|
423
|
+
const n = this.getAnchorEl();
|
|
424
|
+
n && (this.pos = this.getAnchorPoint(n, this.anchorDir), this.calcDirAlign(), this.ready = !0, this.$nextTick(() => this.$emit("ready")));
|
|
425
|
+
},
|
|
426
|
+
calcDirAlign() {
|
|
427
|
+
const n = this.pos.y < window.innerHeight * 0.5, t = this.pos.x < window.innerWidth * 0.5;
|
|
428
|
+
this.align === "auto" ? ["top", "bottom", "v"].includes(this.dir) ? this.actualAlign = t ? "start" : "end" : this.actualAlign = n ? "start" : "end" : this.actualAlign = this.align, this.dir === "v" ? this.actualDir = n ? "bottom" : "top" : this.dir === "h" ? this.actualDir = t ? "right" : "left" : this.actualDir = this.dir;
|
|
429
|
+
},
|
|
430
|
+
getAnchorEl() {
|
|
431
|
+
if (this.anchorRef) {
|
|
432
|
+
const n = this.findRef(this.$parent, this.anchorRef);
|
|
433
|
+
if (n)
|
|
434
|
+
return n;
|
|
435
|
+
}
|
|
436
|
+
return this.$el.parentElement;
|
|
437
|
+
},
|
|
438
|
+
findRef(n, t) {
|
|
439
|
+
if (!n)
|
|
440
|
+
return null;
|
|
441
|
+
const e = n.$refs[t];
|
|
442
|
+
if (e) {
|
|
443
|
+
const l = e.$el ?? e;
|
|
444
|
+
if (l instanceof HTMLElement)
|
|
445
|
+
return l;
|
|
446
|
+
}
|
|
447
|
+
return n.$parent ? this.findRef(n.$parent, t) : null;
|
|
448
|
+
},
|
|
449
|
+
getAnchorPoint(n, t) {
|
|
450
|
+
const { top: e, left: l, width: o, height: s } = n.getBoundingClientRect();
|
|
451
|
+
switch (t) {
|
|
452
|
+
case "left":
|
|
453
|
+
return { x: l, y: e + s * 0.5 };
|
|
454
|
+
case "right":
|
|
455
|
+
return { x: l + o, y: e + s * 0.5 };
|
|
456
|
+
case "top":
|
|
457
|
+
return { x: l + o * 0.5, y: e };
|
|
458
|
+
case "bottom":
|
|
459
|
+
return { x: l + o * 0.5, y: e + s };
|
|
460
|
+
case "middle":
|
|
461
|
+
default:
|
|
462
|
+
return { x: l + o * 0.5, y: e + s * 0.5 };
|
|
463
|
+
}
|
|
464
|
+
},
|
|
465
|
+
onResize() {
|
|
466
|
+
this.calcPos();
|
|
467
|
+
},
|
|
468
|
+
onKeyDown(n) {
|
|
469
|
+
n.key === "Escape" && (n.preventDefault(), this.hide());
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
};
|
|
473
|
+
function ae(n, t, e, l, o, s) {
|
|
474
|
+
const a = m("Bubble");
|
|
475
|
+
return r(), y(H, { to: "#overlays" }, [
|
|
476
|
+
b("div", {
|
|
477
|
+
class: h(["Overlay", {
|
|
478
|
+
"Overlay-enabled": e.overlayEnabled,
|
|
479
|
+
"Overlay-shown": e.overlayShown
|
|
480
|
+
}]),
|
|
481
|
+
onClick: t[3] || (t[3] = z((i) => s.hide(), ["stop"]))
|
|
482
|
+
}, [
|
|
483
|
+
o.ready ? (r(), y(a, {
|
|
484
|
+
key: 0,
|
|
485
|
+
dir: o.actualDir,
|
|
486
|
+
align: o.actualAlign,
|
|
487
|
+
style: M(s.bubbleStyle),
|
|
488
|
+
arrowShown: e.arrowShown,
|
|
489
|
+
onMouseenter: t[0] || (t[0] = (i) => n.$emit("mouseenter")),
|
|
490
|
+
onMouseleave: t[1] || (t[1] = (i) => n.$emit("mouseleave")),
|
|
491
|
+
onClick: t[2] || (t[2] = z(() => {
|
|
492
|
+
}, ["stop"]))
|
|
493
|
+
}, {
|
|
494
|
+
default: v(() => [
|
|
495
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
496
|
+
]),
|
|
497
|
+
_: 3
|
|
498
|
+
}, 8, ["dir", "align", "style", "arrowShown"])) : p("", !0)
|
|
499
|
+
], 2)
|
|
500
|
+
]);
|
|
501
|
+
}
|
|
502
|
+
const w = /* @__PURE__ */ c(le, [["render", ae], ["__scopeId", "data-v-8d924b35"]]), ie = {
|
|
503
|
+
components: {
|
|
504
|
+
ContextPopup: w,
|
|
505
|
+
BaseMenu: I
|
|
506
|
+
},
|
|
507
|
+
inheritAttrs: !1,
|
|
508
|
+
props: {
|
|
509
|
+
...w.props,
|
|
510
|
+
...I.props
|
|
511
|
+
},
|
|
512
|
+
emits: [
|
|
513
|
+
...w.emits || [],
|
|
514
|
+
...I.emits || []
|
|
515
|
+
],
|
|
516
|
+
computed: {
|
|
517
|
+
contextPopupProps() {
|
|
518
|
+
return C(this, w);
|
|
519
|
+
},
|
|
520
|
+
baseMenuProps() {
|
|
521
|
+
return C(this, I);
|
|
522
|
+
}
|
|
523
|
+
},
|
|
524
|
+
methods: {
|
|
525
|
+
hide() {
|
|
526
|
+
this.$refs.popup?.hide();
|
|
527
|
+
},
|
|
528
|
+
onActivate(n, t) {
|
|
529
|
+
this.$emit("activate", n, t);
|
|
530
|
+
}
|
|
531
|
+
}
|
|
532
|
+
};
|
|
533
|
+
function re(n, t, e, l, o, s) {
|
|
534
|
+
const a = m("BaseMenu"), i = m("ContextPopup");
|
|
535
|
+
return r(), y(i, x({ ref: "popup" }, s.contextPopupProps, {
|
|
536
|
+
onHide: t[0] || (t[0] = (u) => n.$emit("hide")),
|
|
537
|
+
onMouseenter: t[1] || (t[1] = (u) => n.$emit("mouseenter")),
|
|
538
|
+
onMouseleave: t[2] || (t[2] = (u) => n.$emit("mouseleave")),
|
|
539
|
+
onReady: t[3] || (t[3] = (u) => n.$emit("ready"))
|
|
540
|
+
}), {
|
|
541
|
+
default: v(() => [
|
|
542
|
+
O(a, x({ class: "ContextMenu" }, { ...s.baseMenuProps, ...n.$attrs }, { onActivate: s.onActivate }), null, 16, ["onActivate"])
|
|
543
|
+
]),
|
|
544
|
+
_: 1
|
|
545
|
+
}, 16);
|
|
546
|
+
}
|
|
547
|
+
const ue = /* @__PURE__ */ c(ie, [["render", re]]), de = {
|
|
214
548
|
props: {
|
|
215
549
|
fill: { type: String, default: "none" }
|
|
216
550
|
}
|
|
217
551
|
};
|
|
218
|
-
function
|
|
219
|
-
return
|
|
220
|
-
class:
|
|
552
|
+
function ce(n, t, e, l, o, s) {
|
|
553
|
+
return r(), f("div", {
|
|
554
|
+
class: h(["Filler", [
|
|
221
555
|
`Filler-${e.fill}`
|
|
222
556
|
]])
|
|
223
557
|
}, null, 2);
|
|
224
558
|
}
|
|
225
|
-
const
|
|
559
|
+
const fe = /* @__PURE__ */ c(de, [["render", ce], ["__scopeId", "data-v-448176c1"]]), ye = {
|
|
226
560
|
props: {
|
|
227
561
|
tagName: { type: String, default: "div" },
|
|
228
562
|
align: { type: String, default: "center" },
|
|
@@ -231,9 +565,9 @@ const G = /* @__PURE__ */ d(M, [["render", P], ["__scopeId", "data-v-448176c1"]]
|
|
|
231
565
|
wrap: { type: Boolean, default: !1 }
|
|
232
566
|
}
|
|
233
567
|
};
|
|
234
|
-
function
|
|
235
|
-
return
|
|
236
|
-
class:
|
|
568
|
+
function pe(n, t, e, l, o, s) {
|
|
569
|
+
return r(), y(S(e.tagName), {
|
|
570
|
+
class: h(["HGroup", [
|
|
237
571
|
`HGroup-align-${e.align}`,
|
|
238
572
|
`HGroup-justify-${e.justify}`,
|
|
239
573
|
`HGroup-gap-${e.gap}`,
|
|
@@ -242,48 +576,52 @@ function L(t, n, e, u, l, o) {
|
|
|
242
576
|
}
|
|
243
577
|
]])
|
|
244
578
|
}, {
|
|
245
|
-
default:
|
|
246
|
-
|
|
579
|
+
default: v(() => [
|
|
580
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
247
581
|
]),
|
|
248
582
|
_: 3
|
|
249
583
|
}, 8, ["class"]);
|
|
250
584
|
}
|
|
251
|
-
const
|
|
585
|
+
const ve = /* @__PURE__ */ c(ye, [["render", pe], ["__scopeId", "data-v-5b190da7"]]), he = {
|
|
252
586
|
props: {
|
|
253
587
|
tagName: { type: String, default: "div" },
|
|
254
588
|
dir: { type: String, default: "top" },
|
|
255
|
-
label: { type: String }
|
|
589
|
+
label: { type: String },
|
|
590
|
+
size: { type: String, default: "m" },
|
|
591
|
+
kind: { type: String, default: "base" }
|
|
256
592
|
},
|
|
257
593
|
computed: {
|
|
258
594
|
orientation() {
|
|
259
595
|
return this.dir === "top" || this.dir === "bottom" ? "h" : "v";
|
|
260
596
|
}
|
|
261
597
|
}
|
|
262
|
-
},
|
|
263
|
-
function
|
|
264
|
-
const
|
|
265
|
-
return
|
|
266
|
-
class:
|
|
598
|
+
}, be = { class: "Content" }, me = ["title"];
|
|
599
|
+
function ge(n, t, e, l, o, s) {
|
|
600
|
+
const a = m("TabCap");
|
|
601
|
+
return r(), y(S(e.tagName), {
|
|
602
|
+
class: h(["Tab", [
|
|
603
|
+
`ui-${e.kind}`,
|
|
604
|
+
`input-size-${e.size}`,
|
|
267
605
|
`Tab-${e.dir}`,
|
|
268
|
-
`Tab-${
|
|
606
|
+
`Tab-${s.orientation}`
|
|
269
607
|
]])
|
|
270
608
|
}, {
|
|
271
|
-
default:
|
|
272
|
-
O(
|
|
609
|
+
default: v(() => [
|
|
610
|
+
O(a, {
|
|
273
611
|
class: "TabCap",
|
|
274
612
|
dir: e.dir,
|
|
275
613
|
type: "start"
|
|
276
614
|
}, null, 8, ["dir"]),
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
e.label ? (
|
|
615
|
+
b("div", be, [
|
|
616
|
+
d(n.$slots, "default", {}, () => [
|
|
617
|
+
e.label ? (r(), f("div", {
|
|
280
618
|
key: 0,
|
|
281
619
|
class: "TabLabel",
|
|
282
620
|
title: e.label
|
|
283
|
-
},
|
|
621
|
+
}, k(e.label), 9, me)) : p("", !0)
|
|
284
622
|
], !0)
|
|
285
623
|
]),
|
|
286
|
-
O(
|
|
624
|
+
O(a, {
|
|
287
625
|
class: "TabCap",
|
|
288
626
|
dir: e.dir,
|
|
289
627
|
type: "end"
|
|
@@ -292,9 +630,9 @@ function K(t, n, e, u, l, o) {
|
|
|
292
630
|
_: 3
|
|
293
631
|
}, 8, ["class"]);
|
|
294
632
|
}
|
|
295
|
-
const
|
|
633
|
+
const F = /* @__PURE__ */ c(he, [["render", ge], ["__scopeId", "data-v-2d5bc4a5"]]), _e = {
|
|
296
634
|
components: {
|
|
297
|
-
Tab:
|
|
635
|
+
Tab: F
|
|
298
636
|
},
|
|
299
637
|
props: {
|
|
300
638
|
tagName: { default: "label" },
|
|
@@ -305,6 +643,7 @@ const V = /* @__PURE__ */ d(E, [["render", K], ["__scopeId", "data-v-d854a1ad"]]
|
|
|
305
643
|
fixedHeight: { type: Boolean, default: !0 },
|
|
306
644
|
flat: { type: Boolean, default: !1 },
|
|
307
645
|
round: { type: Boolean, default: !1 },
|
|
646
|
+
outline: { type: Boolean, default: !1 },
|
|
308
647
|
disabled: { type: Boolean, default: !1 },
|
|
309
648
|
forceFocus: { type: Boolean, default: !1 },
|
|
310
649
|
forceHover: { type: Boolean, default: !1 },
|
|
@@ -329,187 +668,81 @@ const V = /* @__PURE__ */ d(E, [["render", K], ["__scopeId", "data-v-d854a1ad"]]
|
|
|
329
668
|
},
|
|
330
669
|
effectiveStyle() {
|
|
331
670
|
const {
|
|
332
|
-
baseStyle:
|
|
333
|
-
hoverOverrides:
|
|
671
|
+
baseStyle: n,
|
|
672
|
+
hoverOverrides: t = {},
|
|
334
673
|
focusOverrides: e = {},
|
|
335
|
-
hover:
|
|
336
|
-
focus:
|
|
337
|
-
forceHover:
|
|
338
|
-
forceFocus:
|
|
339
|
-
} = this,
|
|
340
|
-
return (
|
|
674
|
+
hover: l,
|
|
675
|
+
focus: o,
|
|
676
|
+
forceHover: s,
|
|
677
|
+
forceFocus: a
|
|
678
|
+
} = this, i = Object.assign({}, n);
|
|
679
|
+
return (l || s) && Object.assign(i, t), (o || a) && Object.assign(i, e), i;
|
|
341
680
|
}
|
|
342
681
|
}
|
|
343
|
-
},
|
|
682
|
+
}, ke = {
|
|
344
683
|
key: 1,
|
|
345
684
|
class: "Label TextLabel"
|
|
346
|
-
},
|
|
685
|
+
}, Se = {
|
|
347
686
|
key: 2,
|
|
348
687
|
class: "Label InlineLabel"
|
|
349
|
-
},
|
|
350
|
-
function
|
|
351
|
-
const
|
|
352
|
-
return
|
|
353
|
-
class:
|
|
354
|
-
`
|
|
355
|
-
`
|
|
356
|
-
`input-size-${o.effectiveStyle.size}`,
|
|
688
|
+
}, Be = { class: "InputElement Container" };
|
|
689
|
+
function Ie(n, t, e, l, o, s) {
|
|
690
|
+
const a = m("Tab");
|
|
691
|
+
return r(), y(S(e.tagName), {
|
|
692
|
+
class: h(["InputBase", [
|
|
693
|
+
`ui-${s.effectiveStyle.kind}`,
|
|
694
|
+
`input-size-${s.effectiveStyle.size}`,
|
|
357
695
|
{
|
|
358
696
|
"InputBase-fixedHeight": e.fixedHeight,
|
|
359
|
-
"InputBase-flat":
|
|
360
|
-
"InputBase-round":
|
|
697
|
+
"InputBase-flat": s.effectiveStyle.flat,
|
|
698
|
+
"InputBase-round": s.effectiveStyle.round,
|
|
361
699
|
"InputBase-disabled": e.disabled,
|
|
362
700
|
"InputBase-forceFocus": e.forceFocus,
|
|
363
701
|
"InputBase-forceHover": e.forceHover
|
|
364
702
|
}
|
|
365
703
|
]]),
|
|
366
|
-
onMouseenter:
|
|
367
|
-
onMouseleave:
|
|
368
|
-
onFocusin:
|
|
369
|
-
onFocusout:
|
|
704
|
+
onMouseenter: t[0] || (t[0] = (i) => o.hover = !0),
|
|
705
|
+
onMouseleave: t[1] || (t[1] = (i) => o.hover = !1),
|
|
706
|
+
onFocusin: t[2] || (t[2] = (i) => o.focus = !0),
|
|
707
|
+
onFocusout: t[3] || (t[3] = (i) => o.focus = !1)
|
|
370
708
|
}, {
|
|
371
|
-
default:
|
|
372
|
-
e.label ? (
|
|
373
|
-
e.labelStyle === "tab" ? (
|
|
709
|
+
default: v(() => [
|
|
710
|
+
e.label ? (r(), f(T, { key: 0 }, [
|
|
711
|
+
e.labelStyle === "tab" ? (r(), y(a, {
|
|
374
712
|
key: 0,
|
|
375
713
|
class: "Label TabLabel",
|
|
376
|
-
label: e.label
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
e.labelStyle === "
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
r(t.$slots, "default", {}, void 0, !0)
|
|
714
|
+
label: e.label,
|
|
715
|
+
kind: e.kind
|
|
716
|
+
}, null, 8, ["label", "kind"])) : p("", !0),
|
|
717
|
+
e.labelStyle === "text" ? (r(), f("div", ke, k(e.label), 1)) : p("", !0),
|
|
718
|
+
e.labelStyle === "inline" ? (r(), f("div", Se, k(e.label), 1)) : p("", !0)
|
|
719
|
+
], 64)) : p("", !0),
|
|
720
|
+
b("div", Be, [
|
|
721
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
385
722
|
])
|
|
386
723
|
]),
|
|
387
724
|
_: 3
|
|
388
725
|
}, 40, ["class"]);
|
|
389
726
|
}
|
|
390
|
-
const
|
|
727
|
+
const _ = /* @__PURE__ */ c(_e, [["render", Ie], ["__scopeId", "data-v-911102ad"]]), we = {
|
|
391
728
|
props: {
|
|
392
729
|
tagName: { type: String, default: "div" }
|
|
393
730
|
}
|
|
394
731
|
};
|
|
395
|
-
function
|
|
396
|
-
return
|
|
397
|
-
default:
|
|
398
|
-
|
|
732
|
+
function $e(n, t, e, l, o, s) {
|
|
733
|
+
return r(), y(S(e.tagName), { class: "InputGroup" }, {
|
|
734
|
+
default: v(() => [
|
|
735
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
399
736
|
]),
|
|
400
737
|
_: 3
|
|
401
738
|
});
|
|
402
739
|
}
|
|
403
|
-
const
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
modelValue: {},
|
|
407
|
-
items: { type: Array, default: () => [] },
|
|
408
|
-
placeholder: { type: String },
|
|
409
|
-
readonly: { type: Boolean },
|
|
410
|
-
search: { type: Boolean, default: !1 }
|
|
411
|
-
},
|
|
412
|
-
emits: [
|
|
413
|
-
"focus",
|
|
414
|
-
"blur",
|
|
415
|
-
"update:modelValue"
|
|
416
|
-
],
|
|
417
|
-
data() {
|
|
418
|
-
return {
|
|
419
|
-
menuShown: !1
|
|
420
|
-
};
|
|
421
|
-
},
|
|
422
|
-
computed: {
|
|
423
|
-
selectedItem() {
|
|
424
|
-
return this.items.find((t) => (t.value ?? t) === this.modelValue);
|
|
425
|
-
},
|
|
426
|
-
itemTitle() {
|
|
427
|
-
const { selectedItem: t } = this;
|
|
428
|
-
return t?.title ?? t;
|
|
429
|
-
},
|
|
430
|
-
itemIcon() {
|
|
431
|
-
const { selectedItem: t } = this;
|
|
432
|
-
return t?.icon;
|
|
433
|
-
},
|
|
434
|
-
iconDropdown() {
|
|
435
|
-
return this.$nightshadeIcons?.dropdown ?? "fas fa-angle-down";
|
|
436
|
-
}
|
|
740
|
+
const xe = /* @__PURE__ */ c(we, [["render", $e], ["__scopeId", "data-v-ca03932d"]]), Ce = {
|
|
741
|
+
components: {
|
|
742
|
+
InputBase: _
|
|
437
743
|
},
|
|
438
|
-
methods: {
|
|
439
|
-
onInput(t) {
|
|
440
|
-
this.$emit("update:modelValue", t.target.value);
|
|
441
|
-
},
|
|
442
|
-
selectValue(t) {
|
|
443
|
-
this.$emit("update:modelValue", t), this.menuShown = !1;
|
|
444
|
-
},
|
|
445
|
-
getMenuItems() {
|
|
446
|
-
return this.items.map((t) => {
|
|
447
|
-
const n = typeof t == "string" ? t : t.title, e = typeof t == "string" ? t : t.value;
|
|
448
|
-
return {
|
|
449
|
-
title: n,
|
|
450
|
-
checked: e === this.modelValue,
|
|
451
|
-
disabled: t.disabled,
|
|
452
|
-
description: t.description,
|
|
453
|
-
icon: t.icon ?? void 0,
|
|
454
|
-
activate: () => {
|
|
455
|
-
this.disabled || this.selectValue(e);
|
|
456
|
-
}
|
|
457
|
-
};
|
|
458
|
-
});
|
|
459
|
-
},
|
|
460
|
-
show() {
|
|
461
|
-
this.disabled || (this.menuShown = !0);
|
|
462
|
-
}
|
|
463
|
-
}
|
|
464
|
-
}, oe = {
|
|
465
|
-
key: 1,
|
|
466
|
-
class: "Value"
|
|
467
|
-
}, le = {
|
|
468
|
-
key: 2,
|
|
469
|
-
class: "Placeholder"
|
|
470
|
-
}, se = {
|
|
471
|
-
ref: "icon",
|
|
472
|
-
class: "DropdownIcon"
|
|
473
|
-
};
|
|
474
|
-
function ae(t, n, e, u, l, o) {
|
|
475
|
-
const s = h("ContextMenu"), a = h("InputBase");
|
|
476
|
-
return i(), c(a, k({ class: "InputSelect" }, {
|
|
477
|
-
...t.$props
|
|
478
|
-
}, {
|
|
479
|
-
tabindex: "0",
|
|
480
|
-
onClick: n[1] || (n[1] = (_) => o.show())
|
|
481
|
-
}), {
|
|
482
|
-
default: b(() => [
|
|
483
|
-
r(t.$slots, "before", {}, void 0, !0),
|
|
484
|
-
o.itemIcon ? (i(), f("i", {
|
|
485
|
-
key: 0,
|
|
486
|
-
class: p(["Icon", o.itemIcon])
|
|
487
|
-
}, null, 2)) : y("", !0),
|
|
488
|
-
o.selectedItem ? (i(), f("span", oe, g(o.itemTitle), 1)) : y("", !0),
|
|
489
|
-
o.selectedItem ? y("", !0) : (i(), f("span", le, g(e.placeholder), 1)),
|
|
490
|
-
v("div", se, [
|
|
491
|
-
r(t.$slots, "iconDropdown", {}, () => [
|
|
492
|
-
v("i", {
|
|
493
|
-
class: p(o.iconDropdown)
|
|
494
|
-
}, null, 2)
|
|
495
|
-
], !0)
|
|
496
|
-
], 512),
|
|
497
|
-
!t.disabled && l.menuShown ? (i(), c(s, {
|
|
498
|
-
key: 3,
|
|
499
|
-
anchorRef: "icon",
|
|
500
|
-
items: o.getMenuItems(),
|
|
501
|
-
search: e.search,
|
|
502
|
-
overlayShown: !1,
|
|
503
|
-
onHide: n[0] || (n[0] = (_) => l.menuShown = !1)
|
|
504
|
-
}, null, 8, ["items", "search"])) : y("", !0),
|
|
505
|
-
r(t.$slots, "after", {}, void 0, !0)
|
|
506
|
-
]),
|
|
507
|
-
_: 3
|
|
508
|
-
}, 16);
|
|
509
|
-
}
|
|
510
|
-
const ie = /* @__PURE__ */ d(ne, [["render", ae], ["__scopeId", "data-v-3adb595b"]]), ue = {
|
|
511
744
|
props: {
|
|
512
|
-
...
|
|
745
|
+
..._.props,
|
|
513
746
|
modelValue: { type: [String, Number] },
|
|
514
747
|
type: { type: String },
|
|
515
748
|
placeholder: { type: String },
|
|
@@ -525,45 +758,51 @@ const ie = /* @__PURE__ */ d(ne, [["render", ae], ["__scopeId", "data-v-3adb595b
|
|
|
525
758
|
"input",
|
|
526
759
|
"update:modelValue"
|
|
527
760
|
],
|
|
761
|
+
computed: {
|
|
762
|
+
inputBaseProps() {
|
|
763
|
+
return C(this, _);
|
|
764
|
+
}
|
|
765
|
+
},
|
|
528
766
|
mounted() {
|
|
529
767
|
this.autoFocus && this.$refs.input?.focus();
|
|
530
768
|
},
|
|
531
769
|
methods: {
|
|
532
|
-
onInput(
|
|
533
|
-
this.$emit("update:modelValue",
|
|
770
|
+
onInput(n) {
|
|
771
|
+
this.$emit("update:modelValue", n.target.value);
|
|
534
772
|
}
|
|
535
773
|
}
|
|
536
|
-
},
|
|
537
|
-
function
|
|
538
|
-
const
|
|
539
|
-
return
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
r(t.$slots, "before", {}, void 0, !0),
|
|
544
|
-
v("input", {
|
|
774
|
+
}, Oe = ["value", "type", "placeholder", "readonly", "disabled", "min", "max", "step"];
|
|
775
|
+
function Te(n, t, e, l, o, s) {
|
|
776
|
+
const a = m("InputBase");
|
|
777
|
+
return r(), y(a, x({ class: "InputText" }, s.inputBaseProps), {
|
|
778
|
+
default: v(() => [
|
|
779
|
+
d(n.$slots, "before", {}, void 0, !0),
|
|
780
|
+
b("input", {
|
|
545
781
|
ref: "input",
|
|
546
782
|
value: e.modelValue,
|
|
547
783
|
type: e.type,
|
|
548
784
|
placeholder: e.placeholder,
|
|
549
785
|
readonly: e.readonly,
|
|
550
|
-
disabled:
|
|
786
|
+
disabled: n.disabled,
|
|
551
787
|
min: e.min,
|
|
552
788
|
max: e.max,
|
|
553
789
|
step: e.step,
|
|
554
790
|
autocomplete: "off",
|
|
555
|
-
onInput:
|
|
556
|
-
onFocus:
|
|
557
|
-
onBlur:
|
|
558
|
-
}, null, 40,
|
|
559
|
-
|
|
791
|
+
onInput: t[0] || (t[0] = (i) => s.onInput(i)),
|
|
792
|
+
onFocus: t[1] || (t[1] = (i) => n.$emit("focus", i)),
|
|
793
|
+
onBlur: t[2] || (t[2] = (i) => n.$emit("blur", i))
|
|
794
|
+
}, null, 40, Oe),
|
|
795
|
+
d(n.$slots, "after", {}, void 0, !0)
|
|
560
796
|
]),
|
|
561
797
|
_: 3
|
|
562
798
|
}, 16);
|
|
563
799
|
}
|
|
564
|
-
const
|
|
800
|
+
const ze = /* @__PURE__ */ c(Ce, [["render", Te], ["__scopeId", "data-v-a7cbc67d"]]), Pe = {
|
|
801
|
+
components: {
|
|
802
|
+
InputBase: _
|
|
803
|
+
},
|
|
565
804
|
props: {
|
|
566
|
-
...
|
|
805
|
+
..._.props,
|
|
567
806
|
modelValue: { type: String },
|
|
568
807
|
placeholder: { type: String },
|
|
569
808
|
rows: { type: Number },
|
|
@@ -577,107 +816,110 @@ const fe = /* @__PURE__ */ d(ue, [["render", de], ["__scopeId", "data-v-f645b756
|
|
|
577
816
|
"input",
|
|
578
817
|
"update:modelValue"
|
|
579
818
|
],
|
|
819
|
+
computed: {
|
|
820
|
+
inputBaseProps() {
|
|
821
|
+
return C(this, _);
|
|
822
|
+
}
|
|
823
|
+
},
|
|
580
824
|
watch: {
|
|
581
825
|
modelValue: {
|
|
582
826
|
handler() {
|
|
583
|
-
const
|
|
584
|
-
this.autoSize &&
|
|
827
|
+
const n = this.$refs.input;
|
|
828
|
+
this.autoSize && n && (n.style.height = "auto", n.style.height = n.scrollHeight + "px");
|
|
585
829
|
}
|
|
586
830
|
}
|
|
587
831
|
},
|
|
588
832
|
mounted() {
|
|
589
833
|
this.$nextTick(() => {
|
|
590
|
-
const
|
|
591
|
-
this.autoFocus &&
|
|
834
|
+
const n = this.$refs.input;
|
|
835
|
+
this.autoFocus && n.focus(), this.autoSize && (n.style.height = n.scrollHeight + "px", n.style.overflowY = "hidden");
|
|
592
836
|
});
|
|
593
837
|
},
|
|
594
838
|
methods: {
|
|
595
|
-
onInput(
|
|
596
|
-
this.$emit("update:modelValue",
|
|
839
|
+
onInput(n) {
|
|
840
|
+
this.$emit("update:modelValue", n.target.value);
|
|
597
841
|
}
|
|
598
842
|
}
|
|
599
|
-
},
|
|
600
|
-
function
|
|
601
|
-
const
|
|
602
|
-
return
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
r(t.$slots, "before", {}, void 0, !0),
|
|
607
|
-
v("textarea", {
|
|
843
|
+
}, Fe = ["value", "placeholder", "readonly", "disabled", "rows"];
|
|
844
|
+
function je(n, t, e, l, o, s) {
|
|
845
|
+
const a = m("InputBase");
|
|
846
|
+
return r(), y(a, x({ class: "InputTextarea" }, s.inputBaseProps, { fixedHeight: !1 }), {
|
|
847
|
+
default: v(() => [
|
|
848
|
+
d(n.$slots, "before", {}, void 0, !0),
|
|
849
|
+
b("textarea", {
|
|
608
850
|
ref: "input",
|
|
609
851
|
value: e.modelValue,
|
|
610
852
|
placeholder: e.placeholder,
|
|
611
853
|
readonly: e.readonly,
|
|
612
|
-
disabled:
|
|
854
|
+
disabled: n.disabled,
|
|
613
855
|
rows: e.rows,
|
|
614
856
|
resize: "none",
|
|
615
857
|
autocomplete: "off",
|
|
616
|
-
onInput:
|
|
617
|
-
onFocus:
|
|
618
|
-
onBlur:
|
|
619
|
-
}, null, 40,
|
|
620
|
-
|
|
858
|
+
onInput: t[0] || (t[0] = (i) => s.onInput(i)),
|
|
859
|
+
onFocus: t[1] || (t[1] = (i) => n.$emit("focus", i)),
|
|
860
|
+
onBlur: t[2] || (t[2] = (i) => n.$emit("blur", i))
|
|
861
|
+
}, null, 40, Fe),
|
|
862
|
+
d(n.$slots, "after", {}, void 0, !0)
|
|
621
863
|
]),
|
|
622
864
|
_: 3
|
|
623
865
|
}, 16);
|
|
624
866
|
}
|
|
625
|
-
const
|
|
867
|
+
const Ae = /* @__PURE__ */ c(Pe, [["render", je], ["__scopeId", "data-v-3967e87e"]]), Ve = {
|
|
626
868
|
components: {
|
|
627
|
-
Btn:
|
|
869
|
+
Btn: $
|
|
628
870
|
},
|
|
629
871
|
props: {
|
|
630
|
-
|
|
872
|
+
...$.props,
|
|
631
873
|
to: { required: !0 },
|
|
632
874
|
baseProps: { type: Object },
|
|
633
875
|
activeProps: { type: Object },
|
|
634
876
|
exactActiveProps: { type: Object }
|
|
635
877
|
},
|
|
636
878
|
methods: {
|
|
637
|
-
actualProps(
|
|
879
|
+
actualProps(n, t) {
|
|
638
880
|
return {
|
|
639
|
-
...this
|
|
881
|
+
...C(this, $),
|
|
640
882
|
...this.baseProps,
|
|
641
|
-
...
|
|
642
|
-
...
|
|
883
|
+
...n ? this.activeProps : {},
|
|
884
|
+
...t ? this.exactActiveProps : {}
|
|
643
885
|
};
|
|
644
886
|
}
|
|
645
887
|
}
|
|
646
888
|
};
|
|
647
|
-
function
|
|
648
|
-
const
|
|
649
|
-
return
|
|
889
|
+
function He(n, t, e, l, o, s) {
|
|
890
|
+
const a = m("Btn"), i = m("RouterLink");
|
|
891
|
+
return r(), y(i, {
|
|
650
892
|
to: e.to,
|
|
651
893
|
custom: ""
|
|
652
894
|
}, {
|
|
653
|
-
default:
|
|
654
|
-
O(
|
|
895
|
+
default: v(({ href: u, navigate: B, isActive: g, isExactActive: j }) => [
|
|
896
|
+
O(a, x({
|
|
655
897
|
tagName: "a",
|
|
656
|
-
href:
|
|
657
|
-
},
|
|
898
|
+
href: u
|
|
899
|
+
}, s.actualProps(g, j), { onClick: B }), null, 16, ["href", "onClick"])
|
|
658
900
|
]),
|
|
659
901
|
_: 1
|
|
660
902
|
}, 8, ["to"]);
|
|
661
903
|
}
|
|
662
|
-
const
|
|
904
|
+
const Me = /* @__PURE__ */ c(Ve, [["render", He]]), Ee = {
|
|
663
905
|
props: {
|
|
664
906
|
dir: { type: String, default: "top" },
|
|
665
907
|
type: { type: String, default: "start" }
|
|
666
908
|
}
|
|
667
909
|
};
|
|
668
|
-
function
|
|
669
|
-
return
|
|
670
|
-
class:
|
|
910
|
+
function De(n, t, e, l, o, s) {
|
|
911
|
+
return r(), f("svg", {
|
|
912
|
+
class: h(["TabCap", [
|
|
671
913
|
`TabCap-${e.dir}`,
|
|
672
914
|
`TabCap-${e.type}`
|
|
673
915
|
]]),
|
|
674
916
|
viewBox: "0 0 32 32",
|
|
675
917
|
preserveAspectRatio: "none"
|
|
676
|
-
}, [...
|
|
677
|
-
|
|
918
|
+
}, [...t[0] || (t[0] = [
|
|
919
|
+
b("path", { d: "M0 32 C 16 32 16 0 32 0 L 32 32 z" }, null, -1)
|
|
678
920
|
])], 2);
|
|
679
921
|
}
|
|
680
|
-
const
|
|
922
|
+
const Ne = /* @__PURE__ */ c(Ee, [["render", De], ["__scopeId", "data-v-703bfafd"]]), Le = {
|
|
681
923
|
props: {
|
|
682
924
|
modelValue: { type: Boolean },
|
|
683
925
|
disabled: { type: Boolean },
|
|
@@ -716,106 +958,114 @@ const _e = /* @__PURE__ */ d(ge, [["render", Se], ["__scopeId", "data-v-703bfafd
|
|
|
716
958
|
},
|
|
717
959
|
effectiveStyle() {
|
|
718
960
|
const {
|
|
719
|
-
baseStyle:
|
|
720
|
-
hoverOverrides:
|
|
961
|
+
baseStyle: n,
|
|
962
|
+
hoverOverrides: t = {},
|
|
721
963
|
focusOverrides: e = {},
|
|
722
|
-
hover:
|
|
723
|
-
focus:
|
|
724
|
-
forceHover:
|
|
725
|
-
forceFocus:
|
|
726
|
-
} = this,
|
|
727
|
-
return (
|
|
964
|
+
hover: l,
|
|
965
|
+
focus: o,
|
|
966
|
+
forceHover: s,
|
|
967
|
+
forceFocus: a
|
|
968
|
+
} = this, i = Object.assign({}, n);
|
|
969
|
+
return (l || s) && Object.assign(i, t), (o || a) && Object.assign(i, e), i;
|
|
728
970
|
}
|
|
729
971
|
},
|
|
730
972
|
methods: {
|
|
731
|
-
onChange(
|
|
732
|
-
this.$emit("update:modelValue",
|
|
973
|
+
onChange(n) {
|
|
974
|
+
this.$emit("update:modelValue", n.target.checked);
|
|
733
975
|
}
|
|
734
976
|
}
|
|
735
|
-
},
|
|
736
|
-
function
|
|
737
|
-
return
|
|
738
|
-
class:
|
|
739
|
-
`
|
|
740
|
-
`
|
|
741
|
-
`input-size-${o.effectiveStyle.size}`,
|
|
977
|
+
}, Ge = ["checked", "disabled"];
|
|
978
|
+
function Re(n, t, e, l, o, s) {
|
|
979
|
+
return r(), f("label", {
|
|
980
|
+
class: h(["Toggle InputElement", [
|
|
981
|
+
`ui-${s.effectiveStyle.kind}`,
|
|
982
|
+
`input-size-${s.effectiveStyle.size}`,
|
|
742
983
|
{
|
|
743
984
|
"Toggle-active": !!e.modelValue,
|
|
744
|
-
"Toggle-outline":
|
|
745
|
-
"Toggle-round":
|
|
746
|
-
"Toggle-flat":
|
|
985
|
+
"Toggle-outline": s.effectiveStyle.outline,
|
|
986
|
+
"Toggle-round": s.effectiveStyle.round,
|
|
987
|
+
"Toggle-flat": s.effectiveStyle.flat,
|
|
747
988
|
"Toggle-disabled": e.disabled,
|
|
748
989
|
"Toggle-force-focus": e.forceFocus,
|
|
749
990
|
"Toggle-force-hover": e.forceHover
|
|
750
991
|
}
|
|
751
992
|
]]),
|
|
752
993
|
tabindex: "0",
|
|
753
|
-
onMouseenter:
|
|
754
|
-
onMouseleave:
|
|
755
|
-
onFocusin:
|
|
756
|
-
onFocusout:
|
|
994
|
+
onMouseenter: t[1] || (t[1] = (a) => o.hover = !0),
|
|
995
|
+
onMouseleave: t[2] || (t[2] = (a) => o.hover = !1),
|
|
996
|
+
onFocusin: t[3] || (t[3] = (a) => o.focus = !0),
|
|
997
|
+
onFocusout: t[4] || (t[4] = (a) => o.focus = !1)
|
|
757
998
|
}, [
|
|
758
|
-
|
|
999
|
+
b("input", {
|
|
759
1000
|
type: "checkbox",
|
|
760
1001
|
checked: e.modelValue,
|
|
761
1002
|
disabled: e.disabled,
|
|
762
|
-
onChange:
|
|
763
|
-
}, null, 40,
|
|
1003
|
+
onChange: t[0] || (t[0] = (...a) => s.onChange && s.onChange(...a))
|
|
1004
|
+
}, null, 40, Ge)
|
|
764
1005
|
], 34);
|
|
765
1006
|
}
|
|
766
|
-
const
|
|
1007
|
+
const Ke = /* @__PURE__ */ c(Le, [["render", Re], ["__scopeId", "data-v-7086db27"]]), qe = {
|
|
767
1008
|
props: {
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
1009
|
+
size: { type: String, default: "m" },
|
|
1010
|
+
flat: { type: Boolean, default: !1 },
|
|
1011
|
+
outline: { type: Boolean, default: !1 },
|
|
1012
|
+
round: { type: Boolean, default: !1 }
|
|
772
1013
|
}
|
|
773
1014
|
};
|
|
774
|
-
function
|
|
775
|
-
return
|
|
776
|
-
class:
|
|
777
|
-
`
|
|
778
|
-
`
|
|
779
|
-
|
|
1015
|
+
function Ue(n, t, e, l, o, s) {
|
|
1016
|
+
return r(), f("div", {
|
|
1017
|
+
class: h(["ToolPanel", [
|
|
1018
|
+
`ToolPanel-size-${e.size}`,
|
|
1019
|
+
`input-size-${e.size}`,
|
|
1020
|
+
{
|
|
1021
|
+
"ToolPanel-flat": e.flat,
|
|
1022
|
+
"ToolPanel-outline": e.outline,
|
|
1023
|
+
"ToolPanel-round": e.round
|
|
1024
|
+
}
|
|
780
1025
|
]])
|
|
781
|
-
},
|
|
782
|
-
default
|
|
783
|
-
|
|
784
|
-
]),
|
|
785
|
-
_: 3
|
|
786
|
-
}, 8, ["class"]);
|
|
1026
|
+
}, [
|
|
1027
|
+
d(n.$slots, "default", {}, void 0, !0)
|
|
1028
|
+
], 2);
|
|
787
1029
|
}
|
|
788
|
-
const
|
|
1030
|
+
const We = /* @__PURE__ */ c(qe, [["render", Ue], ["__scopeId", "data-v-5ab32096"]]), Je = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
789
1031
|
__proto__: null,
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
1032
|
+
BaseMenu: I,
|
|
1033
|
+
Btn: $,
|
|
1034
|
+
Bubble: ee,
|
|
1035
|
+
Checkbox: se,
|
|
1036
|
+
ContextMenu: ue,
|
|
1037
|
+
ContextPopup: w,
|
|
1038
|
+
Filler: fe,
|
|
1039
|
+
HGroup: ve,
|
|
1040
|
+
InputBase: _,
|
|
1041
|
+
InputGroup: xe,
|
|
1042
|
+
InputText: ze,
|
|
1043
|
+
InputTextarea: Ae,
|
|
1044
|
+
RouterBtn: Me,
|
|
1045
|
+
Tab: F,
|
|
1046
|
+
TabCap: Ne,
|
|
1047
|
+
Toggle: Ke,
|
|
1048
|
+
ToolPanel: We,
|
|
1049
|
+
VGroup: P
|
|
804
1050
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
805
1051
|
export {
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
1052
|
+
I as BaseMenu,
|
|
1053
|
+
$ as Btn,
|
|
1054
|
+
ee as Bubble,
|
|
1055
|
+
se as Checkbox,
|
|
1056
|
+
ue as ContextMenu,
|
|
1057
|
+
w as ContextPopup,
|
|
1058
|
+
fe as Filler,
|
|
1059
|
+
ve as HGroup,
|
|
1060
|
+
_ as InputBase,
|
|
1061
|
+
xe as InputGroup,
|
|
1062
|
+
ze as InputText,
|
|
1063
|
+
Ae as InputTextarea,
|
|
1064
|
+
Me as RouterBtn,
|
|
1065
|
+
F as Tab,
|
|
1066
|
+
Ne as TabCap,
|
|
1067
|
+
Ke as Toggle,
|
|
1068
|
+
We as ToolPanel,
|
|
1069
|
+
P as VGroup,
|
|
1070
|
+
Je as coreComponents
|
|
821
1071
|
};
|