@illinois-grad/grad-vue 2.5.4 → 3.0.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/custom-elements.json +129 -10
- package/dist/components/GCurrencyInput.vue.d.ts +11 -0
- package/dist/components/GDateInput.vue.d.ts +11 -0
- package/dist/components/GDateRangeInput.vue.d.ts +11 -0
- package/dist/components/GEmailInput.vue.d.ts +11 -0
- package/dist/components/GMultiSelect.vue.d.ts +11 -0
- package/dist/components/GSelect.vue.d.ts +11 -0
- package/dist/components/GSelectButton.vue.d.ts +11 -0
- package/dist/components/GTextInput.vue.d.ts +11 -0
- package/dist/components/GTreeMenu.vue.d.ts +47 -19
- package/dist/components/tree-menu/GTreeMenuItem.vue.d.ts +52 -0
- package/dist/components/tree-menu/GTreeMenuList.vue.d.ts +25 -20
- package/dist/{grad-vue-CpBeCe-d.js → grad-vue-DCHrrEXb.js} +801 -769
- package/dist/grad-vue-DCHrrEXb.js.map +1 -0
- package/dist/grad-vue-elements.d.ts +6 -0
- package/dist/grad-vue-elements.js +2249 -2037
- package/dist/grad-vue-elements.js.map +1 -1
- package/dist/grad-vue.css +1 -1
- package/dist/grad-vue.d.ts +3 -2
- package/dist/grad-vue.js +2 -2
- package/dist/plugin.d.ts +3 -1
- package/dist/plugin.js +4 -4
- package/dist/plugin.js.map +1 -1
- package/package.json +1 -1
- package/dist/grad-vue-CpBeCe-d.js.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { Fragment as e, Teleport as t, Transition as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createTextVNode as c, createVNode as l, defineComponent as u, getCurrentInstance as d, guardReactiveProps as f, inject as p, mergeModels as m, mergeProps as h, nextTick as g, normalizeClass as _, normalizeProps as v, normalizeStyle as y, onBeforeMount as b, onBeforeUnmount as x, onMounted as S, openBlock as C, provide as w, reactive as T, ref as E, renderList as D, renderSlot as O,
|
|
2
|
-
import { createEventHook as
|
|
1
|
+
import { Fragment as e, Teleport as t, Transition as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createTextVNode as c, createVNode as l, defineComponent as u, getCurrentInstance as d, guardReactiveProps as f, inject as p, mergeModels as m, mergeProps as h, nextTick as g, normalizeClass as _, normalizeProps as v, normalizeStyle as y, onBeforeMount as b, onBeforeUnmount as x, onMounted as S, openBlock as C, provide as w, reactive as T, ref as E, renderList as D, renderSlot as O, resolveDynamicComponent as k, shallowReactive as A, shallowRef as j, toDisplayString as M, toRaw as N, toRef as P, toValue as F, unref as I, useAttrs as L, useId as R, useModel as z, useSlots as B, useTemplateRef as V, vModelCheckbox as H, vShow as ee, watch as U, watchEffect as W, withCtx as G, withDirectives as K, withModifiers as q } from "vue";
|
|
2
|
+
import { createEventHook as J, toArray as Y, tryOnScopeDispose as te, unrefElement as X, useClipboard as ne, useDebounceFn as re, useFocusWithin as ie, useIntersectionObserver as ae, useMediaQuery as oe, useMutationObserver as se, useResizeObserver as ce, useSessionStorage as le } from "@vueuse/core";
|
|
3
3
|
import { createFocusTrap as ue } from "focus-trap";
|
|
4
4
|
//#region src/compose/useCustomElementAttrs.ts
|
|
5
5
|
function de() {
|
|
6
6
|
return globalThis.__GRAD_VUE_IS_WEB_COMPONENTS_BUILD__ === !0;
|
|
7
7
|
}
|
|
8
8
|
function fe(e = {}) {
|
|
9
|
-
let t =
|
|
9
|
+
let t = L(), n = globalThis.__GRAD_VUE_IS_WEB_COMPONENTS_BUILD__ === !0, i = e.omitInCustomElement ?? [];
|
|
10
10
|
return {
|
|
11
11
|
attrs: t,
|
|
12
12
|
isCustomElement: n,
|
|
@@ -51,7 +51,7 @@ var pe = { class: "g-btn--icon" }, me = { class: "g-btn--label" }, Z = /* @__PUR
|
|
|
51
51
|
"mouseleave"
|
|
52
52
|
],
|
|
53
53
|
setup(t) {
|
|
54
|
-
let n = t, a =
|
|
54
|
+
let n = t, a = B(), { forwardedAttrs: c } = fe({ omitInCustomElement: ["id"] }), l = r(() => [
|
|
55
55
|
"g-btn",
|
|
56
56
|
`g-btn--${n.size}`,
|
|
57
57
|
`g-btn--${n.theme}`,
|
|
@@ -65,7 +65,7 @@ var pe = { class: "g-btn--icon" }, me = { class: "g-btn--label" }, Z = /* @__PUR
|
|
|
65
65
|
"g-btn-has-icon-svg": !!a.icon
|
|
66
66
|
}
|
|
67
67
|
]);
|
|
68
|
-
return (r, u) => (C(), i(
|
|
68
|
+
return (r, u) => (C(), i(k(n.component ? n.component : "button"), h(I(c), {
|
|
69
69
|
to: n.to,
|
|
70
70
|
class: l.value,
|
|
71
71
|
type: n.to ? void 0 : n.type,
|
|
@@ -79,7 +79,7 @@ var pe = { class: "g-btn--icon" }, me = { class: "g-btn--label" }, Z = /* @__PUR
|
|
|
79
79
|
onMouseenter: u[7] ||= (e) => r.$emit("mouseenter", e),
|
|
80
80
|
onMouseleave: u[8] ||= (e) => r.$emit("mouseleave", e)
|
|
81
81
|
}), {
|
|
82
|
-
default:
|
|
82
|
+
default: G(() => [t.icon || a.icon ? (C(), o(e, { key: 0 }, [s("span", pe, [a.icon ? O(r.$slots, "icon", { key: 0 }) : (C(), o("span", {
|
|
83
83
|
key: 1,
|
|
84
84
|
class: _(t.icon + " g-btn--icon-span"),
|
|
85
85
|
"aria-hidden": "true"
|
|
@@ -91,147 +91,24 @@ var pe = { class: "g-btn--icon" }, me = { class: "g-btn--label" }, Z = /* @__PUR
|
|
|
91
91
|
"type"
|
|
92
92
|
]));
|
|
93
93
|
}
|
|
94
|
-
}), he = ["
|
|
95
|
-
key: 1,
|
|
96
|
-
class: "g-tree-menu__row"
|
|
97
|
-
}, ve = [
|
|
98
|
-
"aria-expanded",
|
|
99
|
-
"aria-label",
|
|
100
|
-
"onClick"
|
|
101
|
-
], ye = ["aria-expanded", "href"], be = {
|
|
102
|
-
key: 2,
|
|
103
|
-
class: "g-tree-menu__row g-tree-menu__row--leaf"
|
|
104
|
-
}, xe = ["href"], Se = {
|
|
105
|
-
key: 2,
|
|
106
|
-
class: "g-tree-menu__label"
|
|
107
|
-
}, Ce = /* @__PURE__ */ u({
|
|
108
|
-
name: "GTreeMenuList",
|
|
109
|
-
props: {
|
|
110
|
-
items: {},
|
|
111
|
-
listType: {},
|
|
112
|
-
expandedItems: {},
|
|
113
|
-
keyPrefix: {}
|
|
114
|
-
},
|
|
115
|
-
emits: ["toggle"],
|
|
116
|
-
setup(t, { emit: n }) {
|
|
117
|
-
let l = t, u = n, f = d(), p = r(() => f?.appContext?.components?.RouterLink ?? null);
|
|
118
|
-
function m(e) {
|
|
119
|
-
return `${l.keyPrefix}${e}`;
|
|
120
|
-
}
|
|
121
|
-
function h(e) {
|
|
122
|
-
return l.expandedItems.has(m(e));
|
|
123
|
-
}
|
|
124
|
-
function g(e) {
|
|
125
|
-
u("toggle", m(e));
|
|
126
|
-
}
|
|
127
|
-
return (n, r) => {
|
|
128
|
-
let l = k("GTreeMenuList", !0);
|
|
129
|
-
return C(), i(A(t.listType), { class: "g-tree-menu__list" }, {
|
|
130
|
-
default: K(() => [(C(!0), o(e, null, D(t.items, (e, n) => (C(), o("li", {
|
|
131
|
-
key: n,
|
|
132
|
-
class: "g-tree-menu__item",
|
|
133
|
-
"data-tree-item-key": m(n),
|
|
134
|
-
"data-tree-expandable": e.children ? "true" : void 0
|
|
135
|
-
}, [e.children && !e.href && !e.to ? (C(), o("button", {
|
|
136
|
-
key: 0,
|
|
137
|
-
class: "g-tree-menu__row g-tree-menu__row--toggle",
|
|
138
|
-
"aria-expanded": h(n) ? "true" : "false",
|
|
139
|
-
"data-tree-primary": "",
|
|
140
|
-
onClick: (e) => g(n)
|
|
141
|
-
}, [(C(), o("svg", {
|
|
142
|
-
class: _(["g-tree-menu__chevron", { "g-tree-menu__chevron--expanded": h(n) }]),
|
|
143
|
-
role: "none presentation",
|
|
144
|
-
viewBox: "0 0 24 24",
|
|
145
|
-
fill: "none",
|
|
146
|
-
stroke: "currentColor",
|
|
147
|
-
"stroke-width": "2.5",
|
|
148
|
-
"stroke-linecap": "round",
|
|
149
|
-
"stroke-linejoin": "round"
|
|
150
|
-
}, [...r[1] ||= [s("polyline", { points: "9 18 15 12 9 6" }, null, -1)]], 2)), s("span", null, N(e.label), 1)], 8, ge)) : e.children ? (C(), o("div", _e, [s("button", {
|
|
151
|
-
class: "g-tree-menu__toggle-btn",
|
|
152
|
-
"aria-expanded": h(n) ? "true" : "false",
|
|
153
|
-
"aria-label": `${e.label} sub-menu`,
|
|
154
|
-
onClick: (e) => g(n),
|
|
155
|
-
tabindex: "-1"
|
|
156
|
-
}, [(C(), o("svg", {
|
|
157
|
-
class: _(["g-tree-menu__chevron", { "g-tree-menu__chevron--expanded": h(n) }]),
|
|
158
|
-
role: "none presentation",
|
|
159
|
-
viewBox: "0 0 24 24",
|
|
160
|
-
fill: "none",
|
|
161
|
-
stroke: "currentColor",
|
|
162
|
-
"stroke-width": "2.5",
|
|
163
|
-
"stroke-linecap": "round",
|
|
164
|
-
"stroke-linejoin": "round"
|
|
165
|
-
}, [...r[2] ||= [s("polyline", { points: "9 18 15 12 9 6" }, null, -1)]], 2))], 8, ve), e.to && p.value ? (C(), i(A(p.value), {
|
|
166
|
-
key: 0,
|
|
167
|
-
class: "g-tree-menu__link",
|
|
168
|
-
"aria-expanded": h(n) ? "true" : "false",
|
|
169
|
-
to: e.to,
|
|
170
|
-
"data-tree-primary": ""
|
|
171
|
-
}, {
|
|
172
|
-
default: K(() => [c(N(e.label), 1)]),
|
|
173
|
-
_: 2
|
|
174
|
-
}, 1032, ["aria-expanded", "to"])) : (C(), o("a", {
|
|
175
|
-
key: 1,
|
|
176
|
-
class: "g-tree-menu__link",
|
|
177
|
-
"aria-expanded": h(n) ? "true" : "false",
|
|
178
|
-
href: e.href,
|
|
179
|
-
"data-tree-primary": ""
|
|
180
|
-
}, N(e.label), 9, ye))])) : (C(), o("div", be, [e.to && p.value ? (C(), i(A(p.value), {
|
|
181
|
-
key: 0,
|
|
182
|
-
class: "g-tree-menu__link",
|
|
183
|
-
to: e.to,
|
|
184
|
-
"data-tree-primary": ""
|
|
185
|
-
}, {
|
|
186
|
-
default: K(() => [r[3] ||= s("span", { class: "g-tree-menu__spacer" }, null, -1), c(N(e.label), 1)]),
|
|
187
|
-
_: 2
|
|
188
|
-
}, 1032, ["to"])) : e.href ? (C(), o("a", {
|
|
189
|
-
key: 1,
|
|
190
|
-
class: "g-tree-menu__link",
|
|
191
|
-
href: e.href,
|
|
192
|
-
"data-tree-primary": ""
|
|
193
|
-
}, [r[4] ||= s("span", { class: "g-tree-menu__spacer" }, null, -1), c(N(e.label), 1)], 8, xe)) : (C(), o("span", Se, N(e.label), 1))])), e.children && h(n) ? (C(), i(l, {
|
|
194
|
-
key: 3,
|
|
195
|
-
items: e.children,
|
|
196
|
-
"list-type": t.listType,
|
|
197
|
-
"expanded-items": t.expandedItems,
|
|
198
|
-
"key-prefix": m(n) + "-",
|
|
199
|
-
onToggle: r[0] ||= (e) => u("toggle", e)
|
|
200
|
-
}, null, 8, [
|
|
201
|
-
"items",
|
|
202
|
-
"list-type",
|
|
203
|
-
"expanded-items",
|
|
204
|
-
"key-prefix"
|
|
205
|
-
])) : a("", !0)], 8, he))), 128))]),
|
|
206
|
-
_: 1
|
|
207
|
-
});
|
|
208
|
-
};
|
|
209
|
-
}
|
|
210
|
-
}), Q = (e, t) => {
|
|
211
|
-
let n = e.__vccOpts || e;
|
|
212
|
-
for (let [e, r] of t) n[e] = r;
|
|
213
|
-
return n;
|
|
214
|
-
}, we = /* @__PURE__ */ Q(Ce, [["__scopeId", "data-v-657b989c"]]), Te = ["id"], Ee = { class: "g-tree-menu__content" }, De = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
94
|
+
}), he = ["id"], ge = { class: "g-tree-menu__content" }, _e = /* @__PURE__ */ u({
|
|
215
95
|
__name: "GTreeMenu",
|
|
216
96
|
props: {
|
|
217
97
|
title: {},
|
|
218
|
-
items: {},
|
|
219
98
|
listType: { default: "ul" },
|
|
220
|
-
theme: { default: "light" }
|
|
99
|
+
theme: { default: "light" },
|
|
100
|
+
storageKey: {}
|
|
221
101
|
},
|
|
222
102
|
setup(e) {
|
|
223
|
-
let t = e, n =
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
function c(e) {
|
|
228
|
-
let t = e.lastIndexOf("-");
|
|
229
|
-
return t === -1 ? null : e.substring(0, t);
|
|
103
|
+
let t = e, n = R();
|
|
104
|
+
w("g-tree-menu-list-type", t.listType), w("g-tree-menu-expanded-storage", t.storageKey ? le(t.storageKey, {}) : null);
|
|
105
|
+
function r(e) {
|
|
106
|
+
return e.querySelector("a") || e;
|
|
230
107
|
}
|
|
231
|
-
function
|
|
108
|
+
function i(e) {
|
|
232
109
|
return Array.from(e.querySelectorAll("[data-tree-primary]"));
|
|
233
110
|
}
|
|
234
|
-
function
|
|
111
|
+
function c(e) {
|
|
235
112
|
let t = e.currentTarget, n = document.activeElement;
|
|
236
113
|
if (!t.contains(n) || ![
|
|
237
114
|
"ArrowUp",
|
|
@@ -241,74 +118,154 @@ var pe = { class: "g-btn--icon" }, me = { class: "g-btn--label" }, Z = /* @__PUR
|
|
|
241
118
|
"Home",
|
|
242
119
|
"End"
|
|
243
120
|
].includes(e.key)) return;
|
|
244
|
-
let a = n.closest("
|
|
121
|
+
let a = n.closest(".g-tree-menu__item"), o = a?.querySelector("[data-tree-primary]") ?? null, s = i(t), c = o ? s.indexOf(o) : -1;
|
|
245
122
|
switch (e.key) {
|
|
246
123
|
case "ArrowDown": {
|
|
247
|
-
let e =
|
|
248
|
-
e && e.focus();
|
|
124
|
+
let e = s[c + 1];
|
|
125
|
+
e && r(e).focus();
|
|
249
126
|
break;
|
|
250
127
|
}
|
|
251
128
|
case "ArrowUp": {
|
|
252
|
-
let e =
|
|
253
|
-
e && e.focus();
|
|
129
|
+
let e = s[c - 1];
|
|
130
|
+
e && r(e).focus();
|
|
254
131
|
break;
|
|
255
132
|
}
|
|
256
133
|
case "ArrowRight":
|
|
257
|
-
if (!
|
|
258
|
-
if (
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
134
|
+
if (!a || a.dataset.treeExpandable !== "true") break;
|
|
135
|
+
if (a.querySelector("[aria-expanded='true']") === null) {
|
|
136
|
+
let e = a.querySelector(".g-tree-menu__toggle-btn");
|
|
137
|
+
e && e.click();
|
|
138
|
+
} else {
|
|
139
|
+
let e = s[c + 1];
|
|
140
|
+
e && r(e).focus();
|
|
262
141
|
}
|
|
263
142
|
break;
|
|
264
143
|
case "ArrowLeft":
|
|
265
|
-
if (!
|
|
266
|
-
if (
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
144
|
+
if (!a) break;
|
|
145
|
+
if (a.querySelector("[aria-expanded='true']") !== null) {
|
|
146
|
+
let e = a.querySelector(".g-tree-menu__toggle-btn");
|
|
147
|
+
e && e.click(), o && g(() => r(o).focus());
|
|
148
|
+
} else {
|
|
149
|
+
let e = a.parentElement?.closest(".g-tree-menu__item");
|
|
150
|
+
if (e) {
|
|
151
|
+
let t = e.querySelector("[data-tree-primary]");
|
|
152
|
+
t && r(t).focus();
|
|
272
153
|
}
|
|
273
154
|
}
|
|
274
155
|
break;
|
|
275
156
|
case "Home":
|
|
276
|
-
|
|
157
|
+
s.length > 0 && r(s[0]).focus();
|
|
277
158
|
break;
|
|
278
159
|
case "End":
|
|
279
|
-
|
|
160
|
+
s.length > 0 && r(s[s.length - 1]).focus();
|
|
280
161
|
break;
|
|
281
162
|
}
|
|
282
163
|
e.preventDefault();
|
|
283
164
|
}
|
|
284
|
-
return (
|
|
285
|
-
"aria-labelledby": e.title ?
|
|
165
|
+
return (r, i) => (C(), o("nav", h({ class: ["g-tree-menu", `g-tree-menu--${t.theme}`] }, {
|
|
166
|
+
"aria-labelledby": e.title ? I(n) : void 0,
|
|
286
167
|
"aria-label": e.title ? void 0 : "Tree Menu"
|
|
287
|
-
}, { onKeydown:
|
|
168
|
+
}, { onKeydown: c }), [
|
|
288
169
|
e.title ? (C(), o("h2", {
|
|
289
170
|
key: 0,
|
|
290
|
-
id:
|
|
171
|
+
id: I(n),
|
|
291
172
|
class: "g-tree-menu__title"
|
|
292
|
-
},
|
|
293
|
-
|
|
294
|
-
s("div",
|
|
295
|
-
items: e.items,
|
|
296
|
-
"list-type": e.listType || "ul",
|
|
297
|
-
"expanded-items": r.value,
|
|
298
|
-
"key-prefix": "",
|
|
299
|
-
onToggle: i
|
|
300
|
-
}, null, 8, [
|
|
301
|
-
"items",
|
|
302
|
-
"list-type",
|
|
303
|
-
"expanded-items"
|
|
304
|
-
])])
|
|
173
|
+
}, M(e.title), 9, he)) : a("", !0),
|
|
174
|
+
i[0] ||= s("div", { class: "g-tree-menu__divider" }, null, -1),
|
|
175
|
+
s("div", ge, [O(r.$slots, "default", {}, void 0, !0)])
|
|
305
176
|
], 16));
|
|
306
177
|
}
|
|
307
|
-
}),
|
|
178
|
+
}), Q = (e, t) => {
|
|
179
|
+
let n = e.__vccOpts || e;
|
|
180
|
+
for (let [e, r] of t) n[e] = r;
|
|
181
|
+
return n;
|
|
182
|
+
}, ve = /* @__PURE__ */ Q(_e, [["__scopeId", "data-v-80057f6b"]]), ye = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
183
|
+
name: "GTreeMenuList",
|
|
184
|
+
props: { listType: { default: void 0 } },
|
|
185
|
+
setup(e) {
|
|
186
|
+
let t = e, n = p("g-tree-menu-list-type", "ul"), a = r(() => t.listType ?? n ?? "ul");
|
|
187
|
+
return (e, t) => (C(), i(k(a.value), { class: "g-tree-menu__list" }, {
|
|
188
|
+
default: G(() => [O(e.$slots, "default", {}, void 0, !0)]),
|
|
189
|
+
_: 3
|
|
190
|
+
}));
|
|
191
|
+
}
|
|
192
|
+
}), [["__scopeId", "data-v-be725ca0"]]), be = ["data-tree-expandable"], xe = {
|
|
193
|
+
key: 0,
|
|
194
|
+
class: "g-tree-menu__row"
|
|
195
|
+
}, Se = ["aria-expanded", "aria-label"], Ce = { class: "g-tree-menu__row-content-text" }, we = {
|
|
196
|
+
key: 1,
|
|
197
|
+
class: "g-tree-menu__row g-tree-menu__row--leaf"
|
|
198
|
+
}, Te = {
|
|
199
|
+
class: "g-tree-menu__row-content",
|
|
200
|
+
tabindex: "-1",
|
|
201
|
+
"data-tree-primary": ""
|
|
202
|
+
}, Ee = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
203
|
+
name: "GTreeMenuItem",
|
|
204
|
+
props: {
|
|
205
|
+
label: {},
|
|
206
|
+
expanded: {
|
|
207
|
+
type: Boolean,
|
|
208
|
+
default: !1
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
emits: ["expand", "collapse"],
|
|
212
|
+
setup(e, { emit: t }) {
|
|
213
|
+
let n = e, c = t, l = B(), u = (d()?.ce)?._slots?.children?.length > 0, f = r(() => !!l.children || u), m = p("g-tree-menu-expanded-storage", null);
|
|
214
|
+
function h() {
|
|
215
|
+
if (m && n.label !== void 0) {
|
|
216
|
+
let e = m.value[n.label];
|
|
217
|
+
if (e !== void 0) return e;
|
|
218
|
+
}
|
|
219
|
+
return n.expanded;
|
|
220
|
+
}
|
|
221
|
+
let g = E(h());
|
|
222
|
+
U(() => n.expanded, (e) => {
|
|
223
|
+
m && n.label !== void 0 || (g.value = e);
|
|
224
|
+
}), U(g, (e) => {
|
|
225
|
+
m && n.label !== void 0 && (m.value[n.label] = e);
|
|
226
|
+
});
|
|
227
|
+
function v() {
|
|
228
|
+
g.value = !g.value, g.value ? c("expand") : c("collapse");
|
|
229
|
+
}
|
|
230
|
+
function y(e) {
|
|
231
|
+
e.target.closest("a") || v();
|
|
232
|
+
}
|
|
233
|
+
function b(e) {
|
|
234
|
+
(e.key === "Enter" || e.key === " ") && (v(), e.preventDefault());
|
|
235
|
+
}
|
|
236
|
+
return (t, n) => (C(), o("li", {
|
|
237
|
+
class: "g-tree-menu__item",
|
|
238
|
+
"data-tree-expandable": f.value ? "true" : void 0
|
|
239
|
+
}, [f.value ? (C(), o("div", xe, [s("button", {
|
|
240
|
+
class: "g-tree-menu__toggle-btn",
|
|
241
|
+
"aria-expanded": g.value ? "true" : "false",
|
|
242
|
+
"aria-label": e.label ? `${e.label} sub-menu` : "Sub-menu",
|
|
243
|
+
onClick: v
|
|
244
|
+
}, [(C(), o("svg", {
|
|
245
|
+
class: _(["g-tree-menu__chevron", { "g-tree-menu__chevron--expanded": g.value }]),
|
|
246
|
+
role: "none presentation",
|
|
247
|
+
viewBox: "0 0 24 24",
|
|
248
|
+
fill: "none",
|
|
249
|
+
stroke: "currentColor",
|
|
250
|
+
"stroke-width": "2.5",
|
|
251
|
+
"stroke-linecap": "round",
|
|
252
|
+
"stroke-linejoin": "round"
|
|
253
|
+
}, [...n[0] ||= [s("polyline", { points: "9 18 15 12 9 6" }, null, -1)]], 2))], 8, Se), s("span", {
|
|
254
|
+
class: "g-tree-menu__row-content",
|
|
255
|
+
tabindex: "-1",
|
|
256
|
+
"data-tree-primary": "",
|
|
257
|
+
onClick: y,
|
|
258
|
+
onKeydown: b
|
|
259
|
+
}, [s("span", Ce, [O(t.$slots, "default", {}, void 0, !0)])], 32)])) : (C(), o("div", we, [n[1] ||= s("span", { class: "g-tree-menu__spacer" }, null, -1), s("span", Te, [O(t.$slots, "default", {}, void 0, !0)])])), f.value && g.value ? (C(), i(ye, { key: 2 }, {
|
|
260
|
+
default: G(() => [O(t.$slots, "children", {}, void 0, !0)]),
|
|
261
|
+
_: 3
|
|
262
|
+
})) : a("", !0)], 8, be));
|
|
263
|
+
}
|
|
264
|
+
}), [["__scopeId", "data-v-c264ceb8"]]);
|
|
308
265
|
//#endregion
|
|
309
266
|
//#region src/compose/useForm.ts
|
|
310
|
-
function
|
|
311
|
-
let e =
|
|
267
|
+
function De() {
|
|
268
|
+
let e = A({}), t = E(!1), n = r(() => {
|
|
312
269
|
let t = {};
|
|
313
270
|
return Object.entries(e).forEach(([e, n]) => {
|
|
314
271
|
n && n.value && (t[e] = n.value.value);
|
|
@@ -349,18 +306,18 @@ function Oe() {
|
|
|
349
306
|
}
|
|
350
307
|
//#endregion
|
|
351
308
|
//#region src/compose/useWebComponentForm.ts
|
|
352
|
-
function
|
|
309
|
+
function Oe() {
|
|
353
310
|
let e = globalThis;
|
|
354
311
|
return e.__GRAD_VUE_WC_FORMS__ ||= /* @__PURE__ */ new Map(), e.__GRAD_VUE_WC_FORMS__;
|
|
355
312
|
}
|
|
356
|
-
function
|
|
357
|
-
let t =
|
|
358
|
-
return t.has(n) || t.set(n,
|
|
313
|
+
function ke(e = "default") {
|
|
314
|
+
let t = Oe(), n = e || "default";
|
|
315
|
+
return t.has(n) || t.set(n, De()), t.get(n);
|
|
359
316
|
}
|
|
360
317
|
//#endregion
|
|
361
318
|
//#region src/compose/useFormField.ts
|
|
362
319
|
function $(e) {
|
|
363
|
-
let t =
|
|
320
|
+
let t = L(), n = typeof t["form-key"] == "string" ? t["form-key"] : void 0, i = e.formKey ?? n ?? "default", a = p("form", null) ?? (de() ? ke(i) : null), o = r(() => {
|
|
364
321
|
let t = [];
|
|
365
322
|
return e.errors && t.push(...e.errors.value.filter(Boolean)), t;
|
|
366
323
|
}), s = r(() => o.value.length > 0), c = e.name;
|
|
@@ -379,7 +336,7 @@ function $(e) {
|
|
|
379
336
|
}
|
|
380
337
|
//#endregion
|
|
381
338
|
//#region src/components/form/GFormErrorMessages.vue?vue&type=script&setup=true&lang.ts
|
|
382
|
-
var
|
|
339
|
+
var Ae = ["id"], je = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
383
340
|
__name: "GFormErrorMessages",
|
|
384
341
|
props: {
|
|
385
342
|
errors: {},
|
|
@@ -401,15 +358,20 @@ var je = ["id"], Me = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
401
358
|
}, [s("path", {
|
|
402
359
|
fill: "currentColor",
|
|
403
360
|
d: "M320 64C334.7 64 348.2 72.1 355.2 85L571.2 485C577.9 497.4 577.6 512.4 570.4 524.5C563.2 536.6 550.1 544 536 544L104 544C89.9 544 76.8 536.6 69.6 524.5C62.4 512.4 62.1 497.4 68.8 485L284.8 85C291.8 72.1 305.3 64 320 64zM320 416C302.3 416 288 430.3 288 448C288 465.7 302.3 480 320 480C337.7 480 352 465.7 352 448C352 430.3 337.7 416 320 416zM320 224C301.8 224 287.3 239.5 288.6 257.7L296 361.7C296.9 374.2 307.4 384 319.9 384C332.5 384 342.9 374.3 343.8 361.7L351.2 257.7C352.5 239.5 338.1 224 319.8 224z"
|
|
404
|
-
})], -1), c(" " +
|
|
361
|
+
})], -1), c(" " + M(e), 1)]))), 128))], 8, Ae)) : a("", !0);
|
|
405
362
|
}
|
|
406
|
-
}), [["__scopeId", "data-v-8d738358"]]),
|
|
363
|
+
}), [["__scopeId", "data-v-8d738358"]]), Me = ["for"], Ne = {
|
|
364
|
+
key: 0,
|
|
365
|
+
class: "g-text-input-required",
|
|
366
|
+
"aria-hidden": "true"
|
|
367
|
+
}, Pe = ["id"], Fe = {
|
|
407
368
|
key: 0,
|
|
408
369
|
class: "g-text-input-prefix"
|
|
409
370
|
}, Ie = [
|
|
410
371
|
"value",
|
|
411
372
|
"placeholder",
|
|
412
373
|
"disabled",
|
|
374
|
+
"required",
|
|
413
375
|
"aria-invalid"
|
|
414
376
|
], Le = {
|
|
415
377
|
key: 1,
|
|
@@ -424,6 +386,10 @@ var je = ["id"], Me = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
424
386
|
type: Boolean,
|
|
425
387
|
default: !1
|
|
426
388
|
},
|
|
389
|
+
required: {
|
|
390
|
+
type: Boolean,
|
|
391
|
+
default: !1
|
|
392
|
+
},
|
|
427
393
|
errors: { default: () => [] },
|
|
428
394
|
instructions: { default: "" },
|
|
429
395
|
prefix: { default: "" },
|
|
@@ -437,10 +403,10 @@ var je = ["id"], Me = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
437
403
|
}),
|
|
438
404
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
439
405
|
setup(e, { emit: t }) {
|
|
440
|
-
let n = e, i =
|
|
406
|
+
let n = e, i = z(e, "modelValue"), u = R(), { attrs: d, isCustomElement: f, forwardedAttrs: p } = fe({ omitInCustomElement: ["id"] }), m = r(() => f ? u : d.id || u), { displayErrors: g, hasErrors: v } = $({
|
|
441
407
|
name: n.name,
|
|
442
408
|
value: i,
|
|
443
|
-
errors:
|
|
409
|
+
errors: P(n, "errors"),
|
|
444
410
|
formKey: n.formKey
|
|
445
411
|
}), y = t, b = E(i.value ?? ""), x = null;
|
|
446
412
|
function S(e) {
|
|
@@ -469,23 +435,24 @@ var je = ["id"], Me = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
469
435
|
function k(e) {
|
|
470
436
|
(e.key === "PageUp" || e.key === "PageDown") && (x &&= (clearTimeout(x), null), S(e.target.value)), e.key === "Enter" && S(e.target.value);
|
|
471
437
|
}
|
|
472
|
-
return (t, r) => (C(), o("div", { class: _(["g-text-input-wrap", { "g-text-input-has-error":
|
|
438
|
+
return (t, r) => (C(), o("div", { class: _(["g-text-input-wrap", { "g-text-input-has-error": I(v) }]) }, [
|
|
473
439
|
n.label ? (C(), o("label", {
|
|
474
440
|
key: 0,
|
|
475
441
|
for: m.value,
|
|
476
442
|
class: "g-text-input-label"
|
|
477
|
-
},
|
|
443
|
+
}, [c(M(n.label), 1), n.required ? (C(), o("span", Ne, " *")) : a("", !0)], 8, Me)) : a("", !0),
|
|
478
444
|
t.$slots.instructions || e.instructions ? (C(), o("div", {
|
|
479
445
|
key: 1,
|
|
480
|
-
id: "instructions-" +
|
|
446
|
+
id: "instructions-" + I(u),
|
|
481
447
|
class: "g-text-input-instructions"
|
|
482
|
-
}, [O(t.$slots, "instructions", {}, () => [c(
|
|
448
|
+
}, [O(t.$slots, "instructions", {}, () => [c(M(e.instructions), 1)], !0)], 8, Pe)) : a("", !0),
|
|
483
449
|
s("div", { class: _([{ "g-text-input-field-wrapper": !0 }, `g-text-input-field-wrapper--${e.name || "nameless"}`]) }, [
|
|
484
|
-
n.prefix ? (C(), o("span", Fe,
|
|
450
|
+
n.prefix ? (C(), o("span", Fe, M(n.prefix), 1)) : a("", !0),
|
|
485
451
|
s("input", h({
|
|
486
452
|
value: i.value,
|
|
487
453
|
placeholder: n.placeholder,
|
|
488
454
|
disabled: n.disabled,
|
|
455
|
+
required: n.required,
|
|
489
456
|
onInput: w,
|
|
490
457
|
onBlur: T,
|
|
491
458
|
onPaste: D,
|
|
@@ -493,20 +460,20 @@ var je = ["id"], Me = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
493
460
|
type: "text",
|
|
494
461
|
class: "g-text-input"
|
|
495
462
|
}, {
|
|
496
|
-
...
|
|
463
|
+
...I(p),
|
|
497
464
|
id: m.value,
|
|
498
|
-
"aria-describedby": t.$slots.instructions || e.instructions ? "instructions-" +
|
|
499
|
-
"aria-errormessage":
|
|
500
|
-
}, { "aria-invalid":
|
|
501
|
-
n.suffix ? (C(), o("span", Le,
|
|
465
|
+
"aria-describedby": t.$slots.instructions || e.instructions ? "instructions-" + I(u) : void 0,
|
|
466
|
+
"aria-errormessage": I(v) ? "error-message-" + I(u) : void 0
|
|
467
|
+
}, { "aria-invalid": I(v) ? "true" : "false" }), null, 16, Ie),
|
|
468
|
+
n.suffix ? (C(), o("span", Le, M(n.suffix), 1)) : a("", !0)
|
|
502
469
|
], 2),
|
|
503
|
-
l(
|
|
504
|
-
errors:
|
|
505
|
-
id: "error-message-" +
|
|
470
|
+
l(je, {
|
|
471
|
+
errors: I(g),
|
|
472
|
+
id: "error-message-" + I(u)
|
|
506
473
|
}, null, 8, ["errors", "id"])
|
|
507
474
|
], 2));
|
|
508
475
|
}
|
|
509
|
-
}), [["__scopeId", "data-v-
|
|
476
|
+
}), [["__scopeId", "data-v-a769f5df"]]), ze = 100, Be = 200, Ve = 102, He = E([]), Ue = E([]), We = E([]);
|
|
510
477
|
function Ge() {
|
|
511
478
|
if (!(typeof document > "u")) if (We.value.length > 0) {
|
|
512
479
|
let e = window.innerWidth - document.documentElement.clientWidth;
|
|
@@ -556,10 +523,10 @@ var Ye = (e) => e != null;
|
|
|
556
523
|
//#endregion
|
|
557
524
|
//#region ../../node_modules/@vueuse/integrations/dist/useFocusTrap-lXZ_YG-8.js
|
|
558
525
|
function Xe(e, t = {}) {
|
|
559
|
-
let n, { immediate: i, ...a } = t, o =
|
|
560
|
-
return
|
|
561
|
-
let t =
|
|
562
|
-
return typeof t == "string" ? t :
|
|
526
|
+
let n, { immediate: i, ...a } = t, o = j(!1), s = j(!1), c = (e) => n && n.activate(e), l = (e) => n && n.deactivate(e);
|
|
527
|
+
return U(r(() => Y(F(e)).map((e) => {
|
|
528
|
+
let t = F(e);
|
|
529
|
+
return typeof t == "string" ? t : X(t);
|
|
563
530
|
}).filter(Ye)), (e) => {
|
|
564
531
|
if (e.length) if (!n) n = ue(e, {
|
|
565
532
|
...a,
|
|
@@ -574,7 +541,7 @@ function Xe(e, t = {}) {
|
|
|
574
541
|
let t = n?.active;
|
|
575
542
|
n?.updateContainerElements(e), !t && i && c();
|
|
576
543
|
}
|
|
577
|
-
}, { flush: "post" }),
|
|
544
|
+
}, { flush: "post" }), te(() => l()), {
|
|
578
545
|
hasFocus: o,
|
|
579
546
|
isPaused: s,
|
|
580
547
|
activate: c,
|
|
@@ -620,7 +587,7 @@ function Qe(e, t, n = !1) {
|
|
|
620
587
|
});
|
|
621
588
|
}
|
|
622
589
|
});
|
|
623
|
-
return
|
|
590
|
+
return U(t, (e) => {
|
|
624
591
|
e ? g(() => {
|
|
625
592
|
i() && c();
|
|
626
593
|
}).catch((e) => {
|
|
@@ -698,28 +665,28 @@ var tt = { class: "g-popover-wrap" }, nt = ["id"], rt = ["aria-labelledby", "ari
|
|
|
698
665
|
],
|
|
699
666
|
setup(e, { expose: c, emit: u }) {
|
|
700
667
|
let d = e, f = u, p = E(d.modelValue);
|
|
701
|
-
|
|
668
|
+
U(P(d, "modelValue"), (e) => {
|
|
702
669
|
p.value = e;
|
|
703
670
|
});
|
|
704
|
-
let m =
|
|
705
|
-
$e([b, v], A, p,
|
|
671
|
+
let m = B(), h = r(() => !!m.trigger), v = V("triggerRef"), b = V("popoverRef"), { isCustomElement: S } = fe(), w = S, T = R(), { push: D, pop: k, isTop: A, zIndex: j } = Ke(T, !0), { activate: M, deactivate: N } = Qe(b, A, !0);
|
|
672
|
+
$e([b, v], A, p, L, k), U(p, (e) => {
|
|
706
673
|
e ? (g(() => {
|
|
707
674
|
g(() => M());
|
|
708
675
|
}), D(), f("show")) : (N(), k(), f("hide"));
|
|
709
676
|
});
|
|
710
|
-
function
|
|
677
|
+
function F() {
|
|
711
678
|
p.value = !0, f("update:modelValue", !0);
|
|
712
679
|
}
|
|
713
|
-
function
|
|
680
|
+
function L() {
|
|
714
681
|
p.value = !1, f("update:modelValue", !1);
|
|
715
682
|
}
|
|
716
|
-
function
|
|
683
|
+
function z() {
|
|
717
684
|
p.value = !p.value, f("update:modelValue", p.value);
|
|
718
685
|
}
|
|
719
|
-
let
|
|
686
|
+
let H = E({
|
|
720
687
|
top: 0,
|
|
721
688
|
left: 0
|
|
722
|
-
}),
|
|
689
|
+
}), W = E({ left: "50%" }), q = E(!1), J = E(!1), Y = null;
|
|
723
690
|
function te() {
|
|
724
691
|
if (v.value) return v.value;
|
|
725
692
|
let e = b.value?.parentElement ?? null;
|
|
@@ -731,69 +698,69 @@ var tt = { class: "g-popover-wrap" }, nt = ["id"], rt = ["aria-labelledby", "ari
|
|
|
731
698
|
if (!b.value) return;
|
|
732
699
|
let e = new DOMRect(0, 0, b.value.offsetWidth, b.value.offsetHeight), t = new DOMRect(0, 0, window.innerWidth, window.innerHeight), n = te();
|
|
733
700
|
if (!n) {
|
|
734
|
-
|
|
701
|
+
H.value = {
|
|
735
702
|
top: Math.max((t.height - e.height) / 2, 8),
|
|
736
703
|
left: Math.max((t.width - e.width) / 2, 8)
|
|
737
|
-
}, J.value = !1,
|
|
704
|
+
}, J.value = !1, q.value = !1, W.value = { left: "50%" };
|
|
738
705
|
return;
|
|
739
706
|
}
|
|
740
707
|
let { top: r, left: i, xOffset: a, placedAbove: o, overlay: s } = et(n.getBoundingClientRect(), e, t, { gap: d.minimal ? 0 : 8 });
|
|
741
|
-
|
|
708
|
+
H.value = {
|
|
742
709
|
top: r,
|
|
743
710
|
left: i
|
|
744
|
-
},
|
|
711
|
+
}, W.value = {
|
|
745
712
|
left: `${e.width / 2 - a}px`,
|
|
746
713
|
top: o ? "auto" : void 0,
|
|
747
714
|
bottom: o ? "-8px" : void 0
|
|
748
|
-
},
|
|
715
|
+
}, q.value = o, J.value = s;
|
|
749
716
|
}
|
|
750
|
-
return
|
|
717
|
+
return U(p, (e) => {
|
|
751
718
|
e ? g(() => {
|
|
752
719
|
X(), window.addEventListener("resize", X), window.addEventListener("scroll", X, { capture: !0 }), b.value && (Y && Y.disconnect(), Y = new ResizeObserver(() => X()), Y.observe(b.value));
|
|
753
720
|
}) : (window.removeEventListener("resize", X), window.removeEventListener("scroll", X, { capture: !0 }), Y && Y.disconnect());
|
|
754
721
|
}), x(() => {
|
|
755
722
|
window.removeEventListener("resize", X), window.removeEventListener("scroll", X, { capture: !0 }), Y && Y.disconnect();
|
|
756
723
|
}), c({
|
|
757
|
-
show:
|
|
758
|
-
hide:
|
|
759
|
-
toggle:
|
|
724
|
+
show: F,
|
|
725
|
+
hide: L,
|
|
726
|
+
toggle: z
|
|
760
727
|
}), (r, c) => (C(), o("div", tt, [h.value ? (C(), o("div", {
|
|
761
728
|
key: 0,
|
|
762
729
|
ref_key: "triggerRef",
|
|
763
730
|
ref: v,
|
|
764
731
|
class: "g-popover-trigger",
|
|
765
|
-
id: `${
|
|
766
|
-
}, [O(r.$slots, "trigger", { toggle:
|
|
732
|
+
id: `${I(T)}-trigger`
|
|
733
|
+
}, [O(r.$slots, "trigger", { toggle: z }, void 0, !0)], 8, nt)) : a("", !0), (C(), i(t, {
|
|
767
734
|
to: "#modal-root",
|
|
768
|
-
disabled:
|
|
735
|
+
disabled: I(w)
|
|
769
736
|
}, [l(n, {
|
|
770
737
|
name: "g-popover-expand",
|
|
771
738
|
appear: ""
|
|
772
739
|
}, {
|
|
773
|
-
default:
|
|
740
|
+
default: G(() => [I(S) || p.value ? K((C(), o("div", {
|
|
774
741
|
key: 0,
|
|
775
742
|
ref_key: "popoverRef",
|
|
776
743
|
ref: b,
|
|
777
744
|
class: _({
|
|
778
745
|
"g-popover": !0,
|
|
779
|
-
"g-popover-above":
|
|
780
|
-
"g-popover-below": !
|
|
746
|
+
"g-popover-above": q.value,
|
|
747
|
+
"g-popover-below": !q.value,
|
|
781
748
|
"g-popover-minimal": e.minimal
|
|
782
749
|
}),
|
|
783
750
|
role: "dialog",
|
|
784
751
|
"aria-modal": "true",
|
|
785
|
-
"aria-labelledby": h.value ? `${
|
|
752
|
+
"aria-labelledby": h.value ? `${I(T)}-trigger` : void 0,
|
|
786
753
|
"aria-label": h.value ? void 0 : "Popover",
|
|
787
754
|
style: y({
|
|
788
|
-
top:
|
|
789
|
-
left:
|
|
790
|
-
zIndex:
|
|
755
|
+
top: H.value.top + "px",
|
|
756
|
+
left: H.value.left + "px",
|
|
757
|
+
zIndex: I(j)
|
|
791
758
|
})
|
|
792
759
|
}, [
|
|
793
760
|
!J.value && !e.minimal ? (C(), o("div", {
|
|
794
761
|
key: 0,
|
|
795
|
-
class: _(["g-popover-arrow", { "g-popover-arrow-above":
|
|
796
|
-
style: y(
|
|
762
|
+
class: _(["g-popover-arrow", { "g-popover-arrow-above": q.value }]),
|
|
763
|
+
style: y(W.value),
|
|
797
764
|
"aria-hidden": "true"
|
|
798
765
|
}, null, 6)) : a("", !0),
|
|
799
766
|
O(r.$slots, "default", {}, void 0, !0),
|
|
@@ -802,7 +769,7 @@ var tt = { class: "g-popover-wrap" }, nt = ["id"], rt = ["aria-labelledby", "ari
|
|
|
802
769
|
class: "g-popover-close",
|
|
803
770
|
type: "button",
|
|
804
771
|
"aria-label": "Close popover",
|
|
805
|
-
onClick:
|
|
772
|
+
onClick: L
|
|
806
773
|
}, [...c[0] ||= [s("svg", {
|
|
807
774
|
class: "g-popover-close-icon",
|
|
808
775
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -851,7 +818,7 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
851
818
|
props: { text: {} },
|
|
852
819
|
emits: ["tooltip-hide"],
|
|
853
820
|
setup(e, { expose: t, emit: n }) {
|
|
854
|
-
let i = e, s = n, c =
|
|
821
|
+
let i = e, s = n, c = B(), l = r(() => !!c.trigger), u = V("hostRef"), d = V("triggerRef"), f = E(null), p = E(!1), m = E(!1), h = null, g = !1, _ = null, v = null, y = null;
|
|
855
822
|
function b() {
|
|
856
823
|
if (l.value && d.value) {
|
|
857
824
|
let e = d.value.firstElementChild;
|
|
@@ -902,15 +869,15 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
902
869
|
function I(e) {
|
|
903
870
|
(e.key === "Escape" || e.key === "Esc") && (p.value = !1, m.value = !1);
|
|
904
871
|
}
|
|
905
|
-
return
|
|
872
|
+
return U(() => [
|
|
906
873
|
u.value,
|
|
907
874
|
d.value,
|
|
908
875
|
l.value
|
|
909
876
|
], () => {
|
|
910
877
|
A(b()), S();
|
|
911
|
-
}, { immediate: !0 }),
|
|
878
|
+
}, { immediate: !0 }), U(() => i.text, (e) => {
|
|
912
879
|
f.value && (f.value.textContent = e);
|
|
913
|
-
}),
|
|
880
|
+
}), U(() => p.value || m.value, (e) => {
|
|
914
881
|
if (e) {
|
|
915
882
|
S(), f.value && y && ut(y, f.value), g ||= (window.addEventListener("scroll", w, { capture: !0 }), !0);
|
|
916
883
|
return;
|
|
@@ -935,14 +902,19 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
935
902
|
class: "g-tooltip-trigger"
|
|
936
903
|
}, [O(e.$slots, "trigger", {}, void 0, !0)], 512)) : a("", !0)], 512));
|
|
937
904
|
}
|
|
938
|
-
}), [["__scopeId", "data-v-003155b3"]]), pt = ["disabled"], mt = { class: "g-select-btn-legend" }, ht = {
|
|
905
|
+
}), [["__scopeId", "data-v-003155b3"]]), pt = ["disabled"], mt = { class: "g-select-btn-legend" }, ht = {
|
|
906
|
+
key: 0,
|
|
907
|
+
class: "g-select-btn-required",
|
|
908
|
+
"aria-hidden": "true"
|
|
909
|
+
}, gt = { class: "g-select-btn-row" }, _t = [
|
|
939
910
|
"id",
|
|
940
911
|
"name",
|
|
941
912
|
"value",
|
|
942
913
|
"checked",
|
|
943
914
|
"disabled",
|
|
915
|
+
"required",
|
|
944
916
|
"onChange"
|
|
945
|
-
],
|
|
917
|
+
], vt = ["for"], yt = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
946
918
|
__name: "GSelectButton",
|
|
947
919
|
props: /* @__PURE__ */ m({
|
|
948
920
|
options: {},
|
|
@@ -953,6 +925,10 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
953
925
|
type: Boolean,
|
|
954
926
|
default: !1
|
|
955
927
|
},
|
|
928
|
+
required: {
|
|
929
|
+
type: Boolean,
|
|
930
|
+
default: !1
|
|
931
|
+
},
|
|
956
932
|
errors: { default: () => [] },
|
|
957
933
|
formKey: { default: void 0 }
|
|
958
934
|
}, {
|
|
@@ -961,57 +937,58 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
961
937
|
}),
|
|
962
938
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
963
939
|
setup(t, { emit: n }) {
|
|
964
|
-
let i = t,
|
|
940
|
+
let i = t, u = n, d = z(t, "modelValue"), f = R(), { displayErrors: p, hasErrors: m } = $({
|
|
965
941
|
name: i.name,
|
|
966
|
-
value:
|
|
967
|
-
errors:
|
|
942
|
+
value: d,
|
|
943
|
+
errors: P(i, "errors"),
|
|
968
944
|
formKey: i.formKey
|
|
969
|
-
}),
|
|
945
|
+
}), h = r(() => i.options.map((e) => typeof e == "string" ? {
|
|
970
946
|
label: e,
|
|
971
947
|
value: e
|
|
972
|
-
} : e)),
|
|
948
|
+
} : e)), g = r(() => ["g-select-btn-group", `g-select-btn-group--${i.size}`]), v = (e) => [
|
|
973
949
|
"g-select-btn",
|
|
974
950
|
e ? "g-select-btn--selected" : "",
|
|
975
951
|
{ "g-select-btn--disabled": i.disabled }
|
|
976
952
|
];
|
|
977
|
-
function
|
|
978
|
-
!i.disabled && e !==
|
|
953
|
+
function y(e) {
|
|
954
|
+
!i.disabled && e !== d.value && (d.value = e, u("change", e));
|
|
979
955
|
}
|
|
980
956
|
return (t, n) => (C(), o("fieldset", {
|
|
981
|
-
class: _(
|
|
957
|
+
class: _(g.value),
|
|
982
958
|
disabled: i.disabled
|
|
983
|
-
}, [s("legend", mt,
|
|
959
|
+
}, [s("legend", mt, [c(M(i.label), 1), i.required ? (C(), o("span", ht, " *")) : a("", !0)]), s("div", { class: _(["g-select-btn-wrapper", { "g-select-btn-has-error": I(m) }]) }, [s("div", gt, [(C(!0), o(e, null, D(h.value, (t, n) => (C(), o(e, { key: t.value }, [s("input", {
|
|
984
960
|
class: "g-select-btn-radio",
|
|
985
961
|
type: "radio",
|
|
986
|
-
id: `${
|
|
987
|
-
name: i.name ||
|
|
962
|
+
id: `${I(f)}-${t.value}`,
|
|
963
|
+
name: i.name || I(f),
|
|
988
964
|
value: t.value,
|
|
989
|
-
checked: t.value ===
|
|
965
|
+
checked: t.value === d.value,
|
|
990
966
|
disabled: i.disabled,
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
967
|
+
required: i.required && n === 0,
|
|
968
|
+
onChange: (e) => y(t.value)
|
|
969
|
+
}, null, 40, _t), s("label", {
|
|
970
|
+
for: `${I(f)}-${t.value}`,
|
|
971
|
+
class: _(v(t.value === d.value))
|
|
972
|
+
}, M(t.label), 11, vt)], 64))), 128))]), l(je, {
|
|
973
|
+
errors: I(p),
|
|
974
|
+
id: "error-message-" + I(f)
|
|
998
975
|
}, null, 8, ["errors", "id"])], 2)], 10, pt));
|
|
999
976
|
}
|
|
1000
|
-
}), [["__scopeId", "data-v-
|
|
977
|
+
}), [["__scopeId", "data-v-01874343"]]), bt = ["width", "height"], xt = [
|
|
1001
978
|
"cx",
|
|
1002
979
|
"cy",
|
|
1003
980
|
"r"
|
|
1004
|
-
],
|
|
981
|
+
], St = [
|
|
1005
982
|
"cx",
|
|
1006
983
|
"cy",
|
|
1007
984
|
"r",
|
|
1008
985
|
"stroke-dasharray",
|
|
1009
986
|
"stroke-dashoffset"
|
|
1010
|
-
],
|
|
987
|
+
], Ct = [
|
|
1011
988
|
"cx",
|
|
1012
989
|
"cy",
|
|
1013
990
|
"r"
|
|
1014
|
-
],
|
|
991
|
+
], wt = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1015
992
|
__name: "GProgress",
|
|
1016
993
|
props: {
|
|
1017
994
|
label: { default: "Loading" },
|
|
@@ -1052,7 +1029,7 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1052
1029
|
r: i.value,
|
|
1053
1030
|
"stroke-width": 4,
|
|
1054
1031
|
fill: "none"
|
|
1055
|
-
}, null, 8,
|
|
1032
|
+
}, null, 8, xt), n.value ? (C(), o("circle", {
|
|
1056
1033
|
key: 0,
|
|
1057
1034
|
class: "g-progress__value",
|
|
1058
1035
|
cx: i.value + 4 / 2,
|
|
@@ -1066,7 +1043,7 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1066
1043
|
transform: "rotate(-90deg)",
|
|
1067
1044
|
"transform-origin": "center"
|
|
1068
1045
|
}
|
|
1069
|
-
}, null, 8,
|
|
1046
|
+
}, null, 8, St)) : (C(), o("circle", {
|
|
1070
1047
|
key: 1,
|
|
1071
1048
|
class: "g-progress__spinner",
|
|
1072
1049
|
cx: i.value + 4 / 2,
|
|
@@ -1074,13 +1051,13 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1074
1051
|
r: i.value,
|
|
1075
1052
|
"stroke-width": 4,
|
|
1076
1053
|
fill: "none"
|
|
1077
|
-
}, null, 8,
|
|
1054
|
+
}, null, 8, Ct))], 10, bt))], 16));
|
|
1078
1055
|
}
|
|
1079
|
-
}), [["__scopeId", "data-v-c010c3b0"]]),
|
|
1056
|
+
}), [["__scopeId", "data-v-c010c3b0"]]), Tt = [
|
|
1080
1057
|
"id",
|
|
1081
1058
|
"aria-labelledby",
|
|
1082
1059
|
"aria-describedby"
|
|
1083
|
-
],
|
|
1060
|
+
], Et = { class: "g-alertdialog-inner" }, Dt = ["id"], Ot = ["id"], kt = { class: "g-alertdialog-actions" }, At = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1084
1061
|
__name: "GAlertDialog",
|
|
1085
1062
|
props: {
|
|
1086
1063
|
label: { default: "Confirmation" },
|
|
@@ -1089,7 +1066,7 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1089
1066
|
},
|
|
1090
1067
|
emits: ["cancel", "confirm"],
|
|
1091
1068
|
setup(e, { emit: r }) {
|
|
1092
|
-
let a = e, o = r, u = E(null), d = E(!0), f =
|
|
1069
|
+
let a = e, o = r, u = E(null), d = E(!0), f = R(), { pop: p, push: m, isTop: h, zIndex: g } = Ke(f, !0, !0), { deactivate: _, activate: v } = Qe(u, h);
|
|
1093
1070
|
function x() {
|
|
1094
1071
|
o("cancel");
|
|
1095
1072
|
}
|
|
@@ -1101,52 +1078,52 @@ var ft = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1101
1078
|
name: "g-fade",
|
|
1102
1079
|
appear: ""
|
|
1103
1080
|
}, {
|
|
1104
|
-
default:
|
|
1105
|
-
id: "alertdialog-" +
|
|
1081
|
+
default: G(() => [s("div", {
|
|
1082
|
+
id: "alertdialog-" + I(f),
|
|
1106
1083
|
class: "g-alertdialog",
|
|
1107
1084
|
role: "alertdialog",
|
|
1108
1085
|
"aria-modal": "true",
|
|
1109
|
-
"aria-labelledby": "alertdialog-label-" +
|
|
1110
|
-
"aria-describedby": "alertdialog-description-" +
|
|
1086
|
+
"aria-labelledby": "alertdialog-label-" + I(f),
|
|
1087
|
+
"aria-describedby": "alertdialog-description-" + I(f),
|
|
1111
1088
|
ref_key: "dialog",
|
|
1112
1089
|
ref: u,
|
|
1113
|
-
style: y({ zIndex:
|
|
1114
|
-
}, [s("div",
|
|
1090
|
+
style: y({ zIndex: I(g) })
|
|
1091
|
+
}, [s("div", Et, [
|
|
1115
1092
|
s("h2", {
|
|
1116
|
-
id: "alertdialog-label-" +
|
|
1093
|
+
id: "alertdialog-label-" + I(f),
|
|
1117
1094
|
class: "g-alertdialog-label"
|
|
1118
|
-
},
|
|
1095
|
+
}, M(a.label), 9, Dt),
|
|
1119
1096
|
s("div", {
|
|
1120
|
-
id: "alertdialog-description-" +
|
|
1097
|
+
id: "alertdialog-description-" + I(f),
|
|
1121
1098
|
class: "g-alertdialog-content"
|
|
1122
|
-
}, [O(e.$slots, "default", {}, void 0, !0)], 8,
|
|
1123
|
-
s("div",
|
|
1099
|
+
}, [O(e.$slots, "default", {}, void 0, !0)], 8, Ot),
|
|
1100
|
+
s("div", kt, [l(Z, {
|
|
1124
1101
|
outlined: "",
|
|
1125
1102
|
onClick: r[0] ||= (e) => o("cancel")
|
|
1126
1103
|
}, {
|
|
1127
|
-
default:
|
|
1104
|
+
default: G(() => [...r[2] ||= [c("Cancel", -1)]]),
|
|
1128
1105
|
_: 1
|
|
1129
1106
|
}), l(Z, {
|
|
1130
1107
|
theme: a.buttonColor,
|
|
1131
1108
|
onClick: r[1] ||= (e) => o("confirm")
|
|
1132
1109
|
}, {
|
|
1133
|
-
default:
|
|
1110
|
+
default: G(() => [c(M(a.buttonText), 1)]),
|
|
1134
1111
|
_: 1
|
|
1135
1112
|
}, 8, ["theme"])])
|
|
1136
|
-
])], 12,
|
|
1113
|
+
])], 12, Tt)]),
|
|
1137
1114
|
_: 3
|
|
1138
1115
|
})]));
|
|
1139
1116
|
}
|
|
1140
1117
|
}), [["__scopeId", "data-v-144faf08"]]);
|
|
1141
1118
|
//#endregion
|
|
1142
1119
|
//#region src/compose/useSelectDropdown.ts
|
|
1143
|
-
function
|
|
1120
|
+
function jt(e) {
|
|
1144
1121
|
return e.map((e) => typeof e == "string" ? {
|
|
1145
1122
|
label: e,
|
|
1146
1123
|
value: e
|
|
1147
1124
|
} : e);
|
|
1148
1125
|
}
|
|
1149
|
-
function
|
|
1126
|
+
function Mt({ open: e, anchorRef: t, listboxRef: n, baseId: i, activeIndex: a }) {
|
|
1150
1127
|
let { push: o, pop: s, isTop: c } = Ke(i), l = E("below"), u = E(null), d = r(() => {
|
|
1151
1128
|
let e = {};
|
|
1152
1129
|
return u.value !== null && (e.maxHeight = `${u.value}px`), l.value === "above" ? (e.top = "auto", e.bottom = "100%") : (e.top = "100%", e.bottom = "auto"), e;
|
|
@@ -1170,7 +1147,7 @@ function jt({ open: e, anchorRef: t, listboxRef: n, baseId: i, activeIndex: a })
|
|
|
1170
1147
|
function h() {
|
|
1171
1148
|
p && p();
|
|
1172
1149
|
}
|
|
1173
|
-
|
|
1150
|
+
U(e, (e) => {
|
|
1174
1151
|
e ? (o(), m(), g(() => f())) : (s(), h(), l.value = "below", u.value = null);
|
|
1175
1152
|
}), x(() => {
|
|
1176
1153
|
h();
|
|
@@ -1190,27 +1167,33 @@ function jt({ open: e, anchorRef: t, listboxRef: n, baseId: i, activeIndex: a })
|
|
|
1190
1167
|
}
|
|
1191
1168
|
//#endregion
|
|
1192
1169
|
//#region src/components/GSelect.vue?vue&type=script&setup=true&lang.ts
|
|
1193
|
-
var
|
|
1170
|
+
var Nt = ["id"], Pt = {
|
|
1171
|
+
key: 0,
|
|
1172
|
+
class: "g-select-required",
|
|
1173
|
+
"aria-hidden": "true"
|
|
1174
|
+
}, Ft = { class: "g-select-input-wrap" }, It = ["id"], Lt = [
|
|
1194
1175
|
"value",
|
|
1195
1176
|
"placeholder",
|
|
1196
1177
|
"disabled",
|
|
1197
1178
|
"aria-controls",
|
|
1198
1179
|
"aria-expanded",
|
|
1180
|
+
"aria-required",
|
|
1199
1181
|
"aria-activedescendant"
|
|
1200
|
-
],
|
|
1182
|
+
], Rt = [
|
|
1201
1183
|
"id",
|
|
1202
1184
|
"aria-controls",
|
|
1203
1185
|
"aria-expanded",
|
|
1186
|
+
"aria-required",
|
|
1204
1187
|
"aria-activedescendant"
|
|
1205
|
-
],
|
|
1188
|
+
], zt = ["id"], Bt = [
|
|
1206
1189
|
"id",
|
|
1207
1190
|
"aria-selected",
|
|
1208
1191
|
"onClick"
|
|
1209
|
-
],
|
|
1192
|
+
], Vt = {
|
|
1210
1193
|
key: 1,
|
|
1211
1194
|
"aria-live": "polite",
|
|
1212
1195
|
class: "g-select-combo-option g-select-option g-select-no-results"
|
|
1213
|
-
},
|
|
1196
|
+
}, Ht = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1214
1197
|
__name: "GSelect",
|
|
1215
1198
|
props: /* @__PURE__ */ m({
|
|
1216
1199
|
options: {},
|
|
@@ -1221,6 +1204,10 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1221
1204
|
type: Boolean,
|
|
1222
1205
|
default: !1
|
|
1223
1206
|
},
|
|
1207
|
+
required: {
|
|
1208
|
+
type: Boolean,
|
|
1209
|
+
default: !1
|
|
1210
|
+
},
|
|
1224
1211
|
name: {},
|
|
1225
1212
|
searchable: {
|
|
1226
1213
|
type: Boolean,
|
|
@@ -1239,37 +1226,37 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1239
1226
|
}),
|
|
1240
1227
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
1241
1228
|
setup(t, { emit: n }) {
|
|
1242
|
-
let i = t, u = n, d =
|
|
1229
|
+
let i = t, u = n, d = z(t, "modelValue"), f = R(), p = E(null), m = E(null), v = E(null), y = E(!1), b = E(0), x = E(!1), S = E(!1), { displayErrors: w, hasErrors: T } = $({
|
|
1243
1230
|
name: i.name,
|
|
1244
1231
|
value: d,
|
|
1245
|
-
errors:
|
|
1232
|
+
errors: P(i, "errors"),
|
|
1246
1233
|
formKey: i.formKey
|
|
1247
|
-
}), { menuPlacement: k, menuStyle: A, isTop: j, scrollOptionIntoView:
|
|
1234
|
+
}), { menuPlacement: k, menuStyle: A, isTop: j, scrollOptionIntoView: N } = Mt({
|
|
1248
1235
|
open: y,
|
|
1249
1236
|
anchorRef: p,
|
|
1250
1237
|
listboxRef: m,
|
|
1251
1238
|
baseId: f,
|
|
1252
1239
|
activeIndex: b
|
|
1253
|
-
}),
|
|
1254
|
-
if (!i.searchable || !y.value || !
|
|
1255
|
-
let e =
|
|
1256
|
-
return
|
|
1257
|
-
}), V = r(() =>
|
|
1258
|
-
|
|
1259
|
-
let t =
|
|
1240
|
+
}), F = r(() => jt(i.options)), L = E(""), B = r(() => {
|
|
1241
|
+
if (!i.searchable || !y.value || !L.value) return F.value;
|
|
1242
|
+
let e = L.value.toLowerCase();
|
|
1243
|
+
return F.value.filter((t) => t.label.toLowerCase().includes(e));
|
|
1244
|
+
}), V = r(() => B.value.findIndex((e) => e.value === d.value));
|
|
1245
|
+
U(() => d.value, (e) => {
|
|
1246
|
+
let t = B.value.findIndex((t) => t.value === e);
|
|
1260
1247
|
t !== -1 && (b.value = t);
|
|
1261
1248
|
});
|
|
1262
1249
|
function H() {
|
|
1263
1250
|
if (!i.disabled && (y.value = !0, i.searchable)) {
|
|
1264
|
-
|
|
1265
|
-
let e =
|
|
1251
|
+
L.value = "";
|
|
1252
|
+
let e = B.value.findIndex((e) => e.value === d.value);
|
|
1266
1253
|
b.value = e === -1 ? 0 : e, g(() => {
|
|
1267
1254
|
v.value && v.value.focus();
|
|
1268
1255
|
});
|
|
1269
1256
|
}
|
|
1270
1257
|
}
|
|
1271
|
-
function
|
|
1272
|
-
y.value = !1, i.searchable && (
|
|
1258
|
+
function W() {
|
|
1259
|
+
y.value = !1, i.searchable && (L.value = "");
|
|
1273
1260
|
}
|
|
1274
1261
|
function G(e) {
|
|
1275
1262
|
if (!i.disabled && i.searchable) {
|
|
@@ -1280,10 +1267,10 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1280
1267
|
H();
|
|
1281
1268
|
}
|
|
1282
1269
|
}
|
|
1283
|
-
function
|
|
1270
|
+
function J(e) {
|
|
1284
1271
|
if (!i.searchable) return;
|
|
1285
|
-
y.value || H(),
|
|
1286
|
-
let t =
|
|
1272
|
+
y.value || H(), L.value = e.target.value;
|
|
1273
|
+
let t = B.value.findIndex((e) => e.value === d.value);
|
|
1287
1274
|
b.value = t === -1 ? 0 : t;
|
|
1288
1275
|
}
|
|
1289
1276
|
function Y(e) {
|
|
@@ -1292,20 +1279,20 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1292
1279
|
x.value = !1;
|
|
1293
1280
|
return;
|
|
1294
1281
|
}
|
|
1295
|
-
t && m.value && m.value.contains(t) || (i.searchable && (
|
|
1282
|
+
t && m.value && m.value.contains(t) || (i.searchable && (L.value = ""), W());
|
|
1296
1283
|
}
|
|
1297
1284
|
function te(e) {
|
|
1298
|
-
let t =
|
|
1299
|
-
t && t.value !== d.value && (d.value = t.value, u("change", t.value)), S.value = !0,
|
|
1285
|
+
let t = B.value[e];
|
|
1286
|
+
t && t.value !== d.value && (d.value = t.value, u("change", t.value)), S.value = !0, W(), setTimeout(() => {
|
|
1300
1287
|
S.value = !1;
|
|
1301
1288
|
}, 100);
|
|
1302
1289
|
}
|
|
1303
1290
|
function X() {
|
|
1304
|
-
i.disabled || (y.value ?
|
|
1291
|
+
i.disabled || (y.value ? W() : H());
|
|
1305
1292
|
}
|
|
1306
1293
|
function ne(e) {
|
|
1307
1294
|
if (i.disabled) return;
|
|
1308
|
-
let t =
|
|
1295
|
+
let t = B.value.length - 1;
|
|
1309
1296
|
if (!y.value && [
|
|
1310
1297
|
"ArrowDown",
|
|
1311
1298
|
"ArrowUp",
|
|
@@ -1317,16 +1304,16 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1317
1304
|
}
|
|
1318
1305
|
switch (e.key) {
|
|
1319
1306
|
case "ArrowDown":
|
|
1320
|
-
e.preventDefault(), y.value ? (b.value = Math.min(t, b.value + 1),
|
|
1307
|
+
e.preventDefault(), y.value ? (b.value = Math.min(t, b.value + 1), N()) : H();
|
|
1321
1308
|
break;
|
|
1322
1309
|
case "ArrowUp":
|
|
1323
|
-
e.preventDefault(), y.value ? (b.value = Math.max(0, b.value - 1),
|
|
1310
|
+
e.preventDefault(), y.value ? (b.value = Math.max(0, b.value - 1), N()) : H();
|
|
1324
1311
|
break;
|
|
1325
1312
|
case "Home":
|
|
1326
|
-
e.preventDefault(), b.value = 0,
|
|
1313
|
+
e.preventDefault(), b.value = 0, N();
|
|
1327
1314
|
break;
|
|
1328
1315
|
case "End":
|
|
1329
|
-
e.preventDefault(), b.value = t,
|
|
1316
|
+
e.preventDefault(), b.value = t, N();
|
|
1330
1317
|
break;
|
|
1331
1318
|
case "Enter":
|
|
1332
1319
|
case " ":
|
|
@@ -1334,7 +1321,7 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1334
1321
|
break;
|
|
1335
1322
|
case "Escape":
|
|
1336
1323
|
j.value && (e.preventDefault(), setTimeout(() => {
|
|
1337
|
-
|
|
1324
|
+
W();
|
|
1338
1325
|
}, 0));
|
|
1339
1326
|
break;
|
|
1340
1327
|
}
|
|
@@ -1347,22 +1334,22 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1347
1334
|
}
|
|
1348
1335
|
let ae = r(() => i.clearButton && d.value !== null && d.value !== void 0 && !i.disabled);
|
|
1349
1336
|
function oe() {
|
|
1350
|
-
i.disabled || (d.value = null, u("change", null), i.searchable && (
|
|
1337
|
+
i.disabled || (d.value = null, u("change", null), i.searchable && (L.value = ""));
|
|
1351
1338
|
}
|
|
1352
1339
|
return (n, r) => (C(), o("div", { class: _(["g-select-root g-select-combo", {
|
|
1353
1340
|
"g-select-open": y.value,
|
|
1354
1341
|
"g-select-compact": t.compact,
|
|
1355
|
-
"g-select-has-error":
|
|
1342
|
+
"g-select-has-error": I(T)
|
|
1356
1343
|
}]) }, [
|
|
1357
1344
|
t.hiddenLabel ? a("", !0) : (C(), o("div", {
|
|
1358
1345
|
key: 0,
|
|
1359
|
-
id:
|
|
1346
|
+
id: I(f) + "-label",
|
|
1360
1347
|
class: "g-select-combo-label g-select-label"
|
|
1361
|
-
},
|
|
1362
|
-
s("div",
|
|
1348
|
+
}, [c(M(i.label), 1), i.required ? (C(), o("span", Pt, " *")) : a("", !0)], 8, Nt)),
|
|
1349
|
+
s("div", Ft, [i.searchable ? (C(), o("div", {
|
|
1363
1350
|
key: 0,
|
|
1364
1351
|
class: "g-select-combo-input g-select-control",
|
|
1365
|
-
id:
|
|
1352
|
+
id: I(f)
|
|
1366
1353
|
}, [
|
|
1367
1354
|
s("input", h({
|
|
1368
1355
|
ref_key: "comboRef",
|
|
@@ -1370,22 +1357,23 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1370
1357
|
type: "text",
|
|
1371
1358
|
name: "comboInput",
|
|
1372
1359
|
class: ["g-select-search-input", { "g-select-clearable": t.clearButton }],
|
|
1373
|
-
value: y.value ?
|
|
1360
|
+
value: y.value ? L.value : F.value[V.value] ? F.value[V.value].label : "",
|
|
1374
1361
|
placeholder: y.value ? "" : t.placeholder,
|
|
1375
1362
|
disabled: i.disabled,
|
|
1376
1363
|
onFocus: G,
|
|
1377
|
-
onInput:
|
|
1364
|
+
onInput: J,
|
|
1378
1365
|
onKeydown: ne,
|
|
1379
1366
|
onBlur: Y,
|
|
1380
1367
|
"aria-autocomplete": "list",
|
|
1381
|
-
"aria-controls":
|
|
1368
|
+
"aria-controls": I(f) + "-listbox",
|
|
1382
1369
|
"aria-expanded": y.value ? "true" : "false",
|
|
1370
|
+
"aria-required": i.required ? "true" : void 0,
|
|
1383
1371
|
"aria-haspopup": "listbox",
|
|
1384
|
-
"aria-activedescendant": y.value ?
|
|
1385
|
-
}, t.hiddenLabel ? { "aria-label": i.label } : { "aria-labelledby":
|
|
1372
|
+
"aria-activedescendant": y.value ? I(f) + "-option-" + b.value : void 0
|
|
1373
|
+
}, t.hiddenLabel ? { "aria-label": i.label } : { "aria-labelledby": I(f) + "-label" }, {
|
|
1386
1374
|
role: "combobox",
|
|
1387
1375
|
autocomplete: "off"
|
|
1388
|
-
}), null, 16,
|
|
1376
|
+
}), null, 16, Lt),
|
|
1389
1377
|
ae.value ? (C(), o("button", {
|
|
1390
1378
|
key: 0,
|
|
1391
1379
|
type: "button",
|
|
@@ -1411,30 +1399,31 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1411
1399
|
fill: "currentColor",
|
|
1412
1400
|
d: "M38.75 24.13a1.36 1.36 0 0 1 0 2.36l-12.44 7.18-12.43 7.18a1.36 1.36 0 0 1-2.05-1.18V11a1.36 1.36 0 0 1 2.05-1.18L26.31 17Z"
|
|
1413
1401
|
})], -1)
|
|
1414
|
-
], 8,
|
|
1402
|
+
], 8, It)) : (C(), o("div", h({
|
|
1415
1403
|
key: 1,
|
|
1416
1404
|
ref_key: "comboRef",
|
|
1417
1405
|
ref: p,
|
|
1418
|
-
id:
|
|
1406
|
+
id: I(f),
|
|
1419
1407
|
class: ["g-select-combo-button g-select-control", { "g-select-clearable": t.clearButton }],
|
|
1420
1408
|
role: "combobox",
|
|
1421
|
-
"aria-controls":
|
|
1409
|
+
"aria-controls": I(f) + "-listbox",
|
|
1422
1410
|
"aria-expanded": y.value ? "true" : "false",
|
|
1411
|
+
"aria-required": i.required ? "true" : void 0,
|
|
1423
1412
|
"aria-haspopup": "listbox"
|
|
1424
|
-
}, t.hiddenLabel ? { "aria-label": i.label } : { "aria-labelledby":
|
|
1425
|
-
"aria-activedescendant": y.value ?
|
|
1413
|
+
}, t.hiddenLabel ? { "aria-label": i.label } : { "aria-labelledby": I(f) + "-label" }, {
|
|
1414
|
+
"aria-activedescendant": y.value ? I(f) + "-option-" + b.value : void 0,
|
|
1426
1415
|
tabindex: "0",
|
|
1427
1416
|
onClick: X,
|
|
1428
1417
|
onKeydown: ne,
|
|
1429
1418
|
onFocus: G,
|
|
1430
1419
|
onBlur: Y
|
|
1431
1420
|
}), [
|
|
1432
|
-
c(
|
|
1421
|
+
c(M(F.value[V.value] ? F.value[V.value].label : "") + " ", 1),
|
|
1433
1422
|
ae.value ? (C(), o("button", {
|
|
1434
1423
|
key: 0,
|
|
1435
1424
|
type: "button",
|
|
1436
1425
|
class: "g-select-clear-btn",
|
|
1437
|
-
onClick:
|
|
1426
|
+
onClick: q(oe, ["stop"])
|
|
1438
1427
|
}, [...r[2] ||= [s("svg", {
|
|
1439
1428
|
role: "img",
|
|
1440
1429
|
"aria-label": "Clear Selection",
|
|
@@ -1455,16 +1444,16 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1455
1444
|
fill: "currentColor",
|
|
1456
1445
|
d: "M38.75 24.13a1.36 1.36 0 0 1 0 2.36l-12.44 7.18-12.43 7.18a1.36 1.36 0 0 1-2.05-1.18V11a1.36 1.36 0 0 1 2.05-1.18L26.31 17Z"
|
|
1457
1446
|
})], -1)
|
|
1458
|
-
], 16,
|
|
1447
|
+
], 16, Rt)), K(s("div", h({
|
|
1459
1448
|
ref_key: "listboxRef",
|
|
1460
1449
|
ref: m,
|
|
1461
|
-
class: ["g-select-combo-menu g-select-list", { "g-select-combo-menu--above":
|
|
1462
|
-
style:
|
|
1450
|
+
class: ["g-select-combo-menu g-select-list", { "g-select-combo-menu--above": I(k) === "above" }],
|
|
1451
|
+
style: I(A),
|
|
1463
1452
|
role: "listbox",
|
|
1464
|
-
id:
|
|
1465
|
-
}, t.hiddenLabel ? { "aria-label": i.label } : { "aria-labelledby":
|
|
1453
|
+
id: I(f) + "-listbox"
|
|
1454
|
+
}, t.hiddenLabel ? { "aria-label": i.label } : { "aria-labelledby": I(f) + "-label" }, { tabindex: "-1" }), [B.value.length > 0 ? (C(!0), o(e, { key: 0 }, D(B.value, (e, t) => (C(), o("div", {
|
|
1466
1455
|
key: e.value,
|
|
1467
|
-
id:
|
|
1456
|
+
id: I(f) + "-option-" + t,
|
|
1468
1457
|
class: _(["g-select-combo-option g-select-option", {
|
|
1469
1458
|
"g-select-option-current": t === b.value,
|
|
1470
1459
|
"ilw-theme-blue": e.value === d.value
|
|
@@ -1477,34 +1466,34 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1477
1466
|
option: e,
|
|
1478
1467
|
selected: e.value === d.value,
|
|
1479
1468
|
index: t
|
|
1480
|
-
}, () => [c(
|
|
1481
|
-
l(
|
|
1482
|
-
errors:
|
|
1483
|
-
id: "error-message-" +
|
|
1469
|
+
}, () => [c(M(e.label), 1)], !0)], 42, Bt))), 128)) : (C(), o("div", Vt, " No results found. "))], 16, zt), [[ee, y.value]])]),
|
|
1470
|
+
l(je, {
|
|
1471
|
+
errors: I(w),
|
|
1472
|
+
id: "error-message-" + I(f)
|
|
1484
1473
|
}, null, 8, ["errors", "id"])
|
|
1485
1474
|
], 2));
|
|
1486
1475
|
}
|
|
1487
|
-
}), [["__scopeId", "data-v-
|
|
1476
|
+
}), [["__scopeId", "data-v-ec0d90d9"]]), Ut = ["aria-label"], Wt = [
|
|
1488
1477
|
"placeholder",
|
|
1489
1478
|
"value",
|
|
1490
1479
|
"aria-expanded",
|
|
1491
1480
|
"aria-controls",
|
|
1492
1481
|
"aria-activedescendant"
|
|
1493
|
-
],
|
|
1482
|
+
], Gt = {
|
|
1494
1483
|
key: 0,
|
|
1495
1484
|
class: "g-search-dropdown"
|
|
1496
|
-
},
|
|
1485
|
+
}, Kt = {
|
|
1497
1486
|
"aria-live": "polite",
|
|
1498
1487
|
class: "g-search-result-count"
|
|
1499
|
-
},
|
|
1488
|
+
}, qt = ["id"], Jt = ["aria-label"], Yt = { class: "g-search-group-label" }, Xt = [
|
|
1500
1489
|
"id",
|
|
1501
1490
|
"onMousedown",
|
|
1502
1491
|
"aria-selected"
|
|
1503
|
-
],
|
|
1492
|
+
], Zt = [
|
|
1504
1493
|
"id",
|
|
1505
1494
|
"onMousedown",
|
|
1506
1495
|
"aria-selected"
|
|
1507
|
-
],
|
|
1496
|
+
], Qt = /* @__PURE__ */ u({
|
|
1508
1497
|
__name: "GSearch",
|
|
1509
1498
|
props: /* @__PURE__ */ m({
|
|
1510
1499
|
results: {},
|
|
@@ -1521,7 +1510,7 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1521
1510
|
}),
|
|
1522
1511
|
emits: /* @__PURE__ */ m(["select", "submit"], ["update:modelValue"]),
|
|
1523
1512
|
setup(t, { emit: n }) {
|
|
1524
|
-
let l =
|
|
1513
|
+
let l = z(t, "modelValue"), u = t, d = n, f = E(null), p = E(null), m = E(!0), h = E(-1), v = r(() => Array.isArray(u.results) && u.results.length && "items" in u.results[0] ? u.results.flatMap((e) => e.items) : u.results), y = r(() => v.value.length);
|
|
1525
1514
|
function b(e) {
|
|
1526
1515
|
let t = e.target.value;
|
|
1527
1516
|
l.value = t, u.auto && t.length > 1 && (m.value = !1);
|
|
@@ -1532,7 +1521,7 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1532
1521
|
e && e.scrollIntoView({ block: "nearest" });
|
|
1533
1522
|
});
|
|
1534
1523
|
}
|
|
1535
|
-
let { focused: S } =
|
|
1524
|
+
let { focused: S } = ie(f);
|
|
1536
1525
|
function w(e) {
|
|
1537
1526
|
let t = e.altKey;
|
|
1538
1527
|
if (e.key === "ArrowDown") {
|
|
@@ -1556,20 +1545,20 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1556
1545
|
function T(e) {
|
|
1557
1546
|
d("select", e), l.value = "", m.value = !0, h.value = -1;
|
|
1558
1547
|
}
|
|
1559
|
-
let k = r(() => !!u.loading), A = r(() => S.value && !m.value), j =
|
|
1548
|
+
let k = r(() => !!u.loading), A = r(() => S.value && !m.value), j = re(() => {
|
|
1560
1549
|
d("submit", l.value);
|
|
1561
1550
|
}, 300);
|
|
1562
|
-
|
|
1551
|
+
U(() => l.value, (e) => {
|
|
1563
1552
|
e ? u.auto && j() : h.value = -1;
|
|
1564
1553
|
});
|
|
1565
|
-
let
|
|
1554
|
+
let N = R();
|
|
1566
1555
|
return (t, n) => (C(), o("div", {
|
|
1567
1556
|
class: "g-search",
|
|
1568
1557
|
role: "search",
|
|
1569
1558
|
"aria-label": u.label
|
|
1570
1559
|
}, [s("form", {
|
|
1571
1560
|
class: "g-search-form",
|
|
1572
|
-
onSubmit: n[0] ||=
|
|
1561
|
+
onSubmit: n[0] ||= q((e) => T(null), ["prevent"])
|
|
1573
1562
|
}, [s("input", {
|
|
1574
1563
|
ref_key: "inputRef",
|
|
1575
1564
|
ref: f,
|
|
@@ -1583,14 +1572,14 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1583
1572
|
role: "combobox",
|
|
1584
1573
|
"aria-expanded": A.value,
|
|
1585
1574
|
"aria-autocomplete": "list",
|
|
1586
|
-
"aria-controls": `${
|
|
1575
|
+
"aria-controls": `${I(N)}-list`,
|
|
1587
1576
|
"aria-activedescendant": h.value >= 0 ? "g-search-option-" + v.value[h.value].id : void 0
|
|
1588
|
-
}, null, 40,
|
|
1577
|
+
}, null, 40, Wt), s("button", {
|
|
1589
1578
|
type: "submit",
|
|
1590
1579
|
class: "g-search-submit",
|
|
1591
1580
|
"aria-label": "Submit search",
|
|
1592
1581
|
onKeydown: w
|
|
1593
|
-
}, [k.value ? (C(), i(
|
|
1582
|
+
}, [k.value ? (C(), i(wt, {
|
|
1594
1583
|
key: 0,
|
|
1595
1584
|
size: "tiny"
|
|
1596
1585
|
})) : a("", !0), n[1] ||= s("svg", {
|
|
@@ -1601,9 +1590,9 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1601
1590
|
}, [s("path", {
|
|
1602
1591
|
fill: "currentColor",
|
|
1603
1592
|
d: "M30 9.76A14.05 14.05 0 1 0 28.3 31l11.3 13a3.34 3.34 0 0 0 4.72-4.72L31.44 27.86A14.05 14.05 0 0 0 30 9.76ZM27.27 27a10.26 10.26 0 1 1 0-14.5 10.25 10.25 0 0 1 0 14.5Z"
|
|
1604
|
-
})], -1)], 32)], 32), A.value ? (C(), o("div",
|
|
1593
|
+
})], -1)], 32)], 32), A.value ? (C(), o("div", Gt, [s("div", Kt, [k.value ? a("", !0) : (C(), o(e, { key: 0 }, [c(M(y.value) + " result" + M(y.value === 1 ? "" : "s"), 1)], 64))]), s("div", {
|
|
1605
1594
|
role: "listbox",
|
|
1606
|
-
id: `${
|
|
1595
|
+
id: `${I(N)}-list`,
|
|
1607
1596
|
ref_key: "listboxRef",
|
|
1608
1597
|
ref: p,
|
|
1609
1598
|
"aria-label": "Search results"
|
|
@@ -1612,29 +1601,29 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1612
1601
|
class: "g-search-group",
|
|
1613
1602
|
role: "group",
|
|
1614
1603
|
"aria-label": n.label
|
|
1615
|
-
}, [O(t.$slots, "group", { group: n }, () => [s("div",
|
|
1604
|
+
}, [O(t.$slots, "group", { group: n }, () => [s("div", Yt, M(n.label), 1)]), (C(!0), o(e, null, D(n.items, (e, n) => (C(), o("div", {
|
|
1616
1605
|
key: e.id,
|
|
1617
1606
|
id: "g-search-option-" + e.id,
|
|
1618
1607
|
class: _(["g-search-option", { "g-search-option-active": v.value[h.value] && v.value[h.value].id === e.id }]),
|
|
1619
1608
|
role: "option",
|
|
1620
|
-
onMousedown:
|
|
1609
|
+
onMousedown: q((t) => T(e), ["prevent"]),
|
|
1621
1610
|
"aria-selected": v.value[h.value] && v.value[h.value].id === e.id
|
|
1622
|
-
}, [O(t.$slots, "option", { option: e }, () => [c(
|
|
1611
|
+
}, [O(t.$slots, "option", { option: e }, () => [c(M(e.title), 1)])], 42, Xt))), 128))], 8, Jt))), 128)) : y.value > 0 ? (C(!0), o(e, { key: 1 }, D(v.value, (e, n) => (C(), o("div", {
|
|
1623
1612
|
key: e.id,
|
|
1624
1613
|
id: "g-search-option-" + e.id,
|
|
1625
1614
|
class: _(["g-search-option", { "g-search-option-active": h.value === n }]),
|
|
1626
1615
|
role: "option",
|
|
1627
|
-
onMousedown:
|
|
1616
|
+
onMousedown: q((t) => T(e), ["prevent"]),
|
|
1628
1617
|
"aria-selected": h.value === n
|
|
1629
|
-
}, [O(t.$slots, "option", { option: e }, () => [c(
|
|
1618
|
+
}, [O(t.$slots, "option", { option: e }, () => [c(M(e.title), 1)])], 42, Zt))), 128)) : a("", !0)], 8, qt)])) : a("", !0)], 8, Ut));
|
|
1630
1619
|
}
|
|
1631
|
-
}),
|
|
1620
|
+
}), $t = { class: /* @__PURE__ */ _({ "g-app-header": !0 }) }, en = { class: "g-app-header__brand" }, tn = {
|
|
1632
1621
|
class: "g-app-header__brand-text",
|
|
1633
1622
|
href: "/"
|
|
1634
|
-
},
|
|
1623
|
+
}, nn = {
|
|
1635
1624
|
key: 0,
|
|
1636
1625
|
class: "g-app-header__block-i-container"
|
|
1637
|
-
},
|
|
1626
|
+
}, rn = { class: "g-app-header__title" }, an = { class: "g-app-header__app-controls-wrap" }, on = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1638
1627
|
__name: "GAppHeader",
|
|
1639
1628
|
props: {
|
|
1640
1629
|
illinois: {
|
|
@@ -1644,10 +1633,10 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1644
1633
|
brand: { default: "GRAD" }
|
|
1645
1634
|
},
|
|
1646
1635
|
setup(e) {
|
|
1647
|
-
return (t, n) => (C(), o("header",
|
|
1636
|
+
return (t, n) => (C(), o("header", $t, [
|
|
1648
1637
|
n[1] ||= s("div", { class: "g-app-header__background" }, [s("div", { class: "g-app-header__background-pattern" }), s("div", { class: "g-app-header__background-gradient" })], -1),
|
|
1649
|
-
s("div",
|
|
1650
|
-
e.illinois ? (C(), o("div",
|
|
1638
|
+
s("div", en, [O(t.$slots, "left", {}, () => [s("a", tn, M(e.brand), 1)], !0)]),
|
|
1639
|
+
e.illinois ? (C(), o("div", nn, [...n[0] ||= [s("svg", {
|
|
1651
1640
|
class: "g-app-header__block-i",
|
|
1652
1641
|
role: "img",
|
|
1653
1642
|
width: "55",
|
|
@@ -1664,28 +1653,28 @@ var Mt = ["id"], Nt = { class: "g-select-input-wrap" }, Pt = ["id"], Ft = [
|
|
|
1664
1653
|
d: "M42.1 18.1h9V3H3v15h9c1.7 0 3 1.3 3 3v36.1c0 1.7-1.3 3-3 3H3v15h48.1v-15h-9c-1.7 0-3-1.3-3-3v-36c0-1.7 1.4-3 3-3z"
|
|
1665
1654
|
})
|
|
1666
1655
|
], -1)]])) : O(t.$slots, "icon", { key: 1 }, void 0, !0),
|
|
1667
|
-
s("div",
|
|
1668
|
-
s("div",
|
|
1656
|
+
s("div", rn, [O(t.$slots, "title", {}, void 0, !0)]),
|
|
1657
|
+
s("div", an, [O(t.$slots, "app-controls", { class: "g-app-header__app-controls" }, void 0, !0)])
|
|
1669
1658
|
]));
|
|
1670
1659
|
}
|
|
1671
1660
|
}), [["__scopeId", "data-v-a83cd06a"]]);
|
|
1672
1661
|
//#endregion
|
|
1673
1662
|
//#region src/compose/useWebComponentSidebar.ts
|
|
1674
|
-
function
|
|
1663
|
+
function sn(e) {
|
|
1675
1664
|
return e.replace(/[^a-zA-Z0-9_-]/g, "-");
|
|
1676
1665
|
}
|
|
1677
|
-
function
|
|
1666
|
+
function cn() {
|
|
1678
1667
|
let e = globalThis;
|
|
1679
1668
|
return e.__GRAD_VUE_WC_SIDEBAR_CHANNELS__ ||= /* @__PURE__ */ new Map(), e.__GRAD_VUE_WC_SIDEBAR_CHANNELS__;
|
|
1680
1669
|
}
|
|
1681
|
-
function
|
|
1682
|
-
let n =
|
|
1670
|
+
function ln(e = "default", t = "(max-width: 800px)") {
|
|
1671
|
+
let n = cn(), r = e || "default";
|
|
1683
1672
|
if (!n.has(r)) {
|
|
1684
|
-
let e =
|
|
1673
|
+
let e = sn(r);
|
|
1685
1674
|
n.set(r, {
|
|
1686
1675
|
id: `g-wc-sidebar-${e}`,
|
|
1687
1676
|
open: E(!1),
|
|
1688
|
-
isCollapsible:
|
|
1677
|
+
isCollapsible: oe(t, { ssrWidth: 1e3 }),
|
|
1689
1678
|
toggle: () => void 0
|
|
1690
1679
|
});
|
|
1691
1680
|
}
|
|
@@ -1706,7 +1695,7 @@ function sn(e = "default", t = "(max-width: 800px)") {
|
|
|
1706
1695
|
}, 5));
|
|
1707
1696
|
}
|
|
1708
1697
|
return S(() => {
|
|
1709
|
-
|
|
1698
|
+
U(i.isCollapsible, (e) => {
|
|
1710
1699
|
e ? (document.addEventListener("mousedown", a), document.addEventListener("focusin", o)) : (document.removeEventListener("mousedown", a), document.removeEventListener("focusin", o));
|
|
1711
1700
|
}, { immediate: !0 });
|
|
1712
1701
|
}), x(() => {
|
|
@@ -1715,7 +1704,7 @@ function sn(e = "default", t = "(max-width: 800px)") {
|
|
|
1715
1704
|
}
|
|
1716
1705
|
//#endregion
|
|
1717
1706
|
//#region src/components/GSidebar.vue?vue&type=script&setup=true&lang.ts
|
|
1718
|
-
var
|
|
1707
|
+
var un = ["id"], dn = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1719
1708
|
__name: "GSidebar",
|
|
1720
1709
|
props: {
|
|
1721
1710
|
backgroundColor: { default: "" },
|
|
@@ -1727,17 +1716,17 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1727
1716
|
sidebarKey: { default: "default" }
|
|
1728
1717
|
},
|
|
1729
1718
|
setup(e) {
|
|
1730
|
-
let t = e, n = p("sidebar", () => void 0, !0) ?? (de() ?
|
|
1719
|
+
let t = e, n = p("sidebar", () => void 0, !0) ?? (de() ? ln(t.sidebarKey) : void 0), i = r(() => t.backgroundImage ? t.backgroundImage : t.theme === "light" ? "none" : "url('https://gradcdn.blob.core.windows.net/public/sidebar-bg2.jpg')"), a = r(() => t.backgroundColor ? t.backgroundColor : t.theme === "light" ? "#f9f9f9" : "#030913"), s = r(() => t.topOffsetVar ? `var(${t.topOffsetVar})` : t.topOffset ? t.topOffset : "var(--g-toolbar-height)"), c = R();
|
|
1731
1720
|
function l(e) {
|
|
1732
1721
|
e.key === "Escape" && n?.isCollapsible?.value && n?.open?.value && (n.open.value = !1, document.getElementById(`${n.id}-hamburger`)?.focus());
|
|
1733
1722
|
}
|
|
1734
1723
|
return (t, r) => (C(), o("div", {
|
|
1735
1724
|
ref: "sidebar-ref",
|
|
1736
|
-
id: `${
|
|
1725
|
+
id: `${I(n)?.id ?? I(c)}-sidebar`,
|
|
1737
1726
|
class: _(["g-sidebar", [`g-sidebar__${e.theme}`, {
|
|
1738
|
-
"g-sidebar--collapsible":
|
|
1739
|
-
"g-sidebar--closed": !
|
|
1740
|
-
"g-sidebar--open":
|
|
1727
|
+
"g-sidebar--collapsible": I(n)?.isCollapsible?.value,
|
|
1728
|
+
"g-sidebar--closed": !I(n)?.open?.value && I(n)?.isCollapsible?.value,
|
|
1729
|
+
"g-sidebar--open": I(n)?.open?.value && I(n)?.isCollapsible?.value
|
|
1741
1730
|
}]]),
|
|
1742
1731
|
style: y({
|
|
1743
1732
|
backgroundImage: i.value,
|
|
@@ -1747,13 +1736,13 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1747
1736
|
width: "var(--g-sidebar-width)"
|
|
1748
1737
|
}),
|
|
1749
1738
|
onKeydown: l
|
|
1750
|
-
}, [O(t.$slots, "default", {}, void 0, !0)], 46,
|
|
1739
|
+
}, [O(t.$slots, "default", {}, void 0, !0)], 46, un));
|
|
1751
1740
|
}
|
|
1752
|
-
}), [["__scopeId", "data-v-88c7169f"]]),
|
|
1741
|
+
}), [["__scopeId", "data-v-88c7169f"]]), fn = ["id"], pn = { class: "g-sidebar-menu__list" }, mn = [
|
|
1753
1742
|
"href",
|
|
1754
1743
|
"aria-current",
|
|
1755
1744
|
"onClick"
|
|
1756
|
-
],
|
|
1745
|
+
], hn = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1757
1746
|
__name: "GSidebarMenu",
|
|
1758
1747
|
props: /* @__PURE__ */ m({
|
|
1759
1748
|
title: {},
|
|
@@ -1777,9 +1766,9 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1777
1766
|
}),
|
|
1778
1767
|
emits: ["update:modelValue"],
|
|
1779
1768
|
setup(t) {
|
|
1780
|
-
let n = t, l =
|
|
1769
|
+
let n = t, l = z(t, "modelValue"), u = r(() => n.spy && l.value ? "#" + l.value : null), f = V("content");
|
|
1781
1770
|
S(() => {
|
|
1782
|
-
|
|
1771
|
+
U(l, () => {
|
|
1783
1772
|
g(() => {
|
|
1784
1773
|
let e = f.value?.querySelector(".g-sidebar-menu__is-active");
|
|
1785
1774
|
e && e.scrollIntoView({ block: "nearest" });
|
|
@@ -1792,32 +1781,32 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1792
1781
|
let n = t.href.slice(1), r = document.getElementById(n)?.querySelector("h2, h3, h4, h5");
|
|
1793
1782
|
r && (e.preventDefault(), r.setAttribute("tabindex", "-1"), r.focus(), r.scrollIntoView({ block: "start" }), history.replaceState(null, "", t.href));
|
|
1794
1783
|
}
|
|
1795
|
-
let y =
|
|
1784
|
+
let y = R();
|
|
1796
1785
|
return (r, l) => (C(), o("nav", h({ class: ["g-sidebar-menu", [`g-sidebar-menu__${n.theme}`, { "g-sidebar-menu--compact": n.compact }]] }, {
|
|
1797
|
-
"aria-labelledby": t.title ?
|
|
1786
|
+
"aria-labelledby": t.title ? I(y) : void 0,
|
|
1798
1787
|
"aria-label": t.title ? void 0 : "Sidebar Menu"
|
|
1799
1788
|
}), [
|
|
1800
1789
|
t.title ? (C(), o("h2", {
|
|
1801
1790
|
key: 0,
|
|
1802
|
-
id:
|
|
1791
|
+
id: I(y),
|
|
1803
1792
|
class: "g-sidebar-menu__title"
|
|
1804
|
-
},
|
|
1793
|
+
}, M(t.title), 9, fn)) : a("", !0),
|
|
1805
1794
|
l[0] ||= s("div", { class: "g-sidebar-menu__divider" }, null, -1),
|
|
1806
1795
|
s("div", {
|
|
1807
1796
|
class: "g-sidebar-menu__content",
|
|
1808
1797
|
ref_key: "content",
|
|
1809
1798
|
ref: f
|
|
1810
|
-
}, [s("ul",
|
|
1799
|
+
}, [s("ul", pn, [(C(!0), o(e, null, D(t.items, (e) => (C(), o("li", {
|
|
1811
1800
|
key: e.href || e.to,
|
|
1812
1801
|
class: "g-sidebar-menu__item",
|
|
1813
1802
|
ref_for: !0,
|
|
1814
1803
|
ref: "listItems"
|
|
1815
|
-
}, [e.to && m.value ? (C(), i(
|
|
1804
|
+
}, [e.to && m.value ? (C(), i(k(m.value), {
|
|
1816
1805
|
key: 0,
|
|
1817
1806
|
class: "g-sidebar-menu__link",
|
|
1818
1807
|
to: e.to
|
|
1819
1808
|
}, {
|
|
1820
|
-
default:
|
|
1809
|
+
default: G(() => [c(M(e.label), 1)]),
|
|
1821
1810
|
_: 2
|
|
1822
1811
|
}, 1032, ["to"])) : (C(), o("a", {
|
|
1823
1812
|
key: 1,
|
|
@@ -1825,23 +1814,23 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1825
1814
|
href: e.href || e.to || "#",
|
|
1826
1815
|
"aria-current": u.value === (e.href || "") ? "location" : void 0,
|
|
1827
1816
|
onClick: (t) => v(t, e)
|
|
1828
|
-
},
|
|
1817
|
+
}, M(e.label), 11, mn))]))), 128))])], 512)
|
|
1829
1818
|
], 16));
|
|
1830
1819
|
}
|
|
1831
|
-
}), [["__scopeId", "data-v-330a0664"]]),
|
|
1820
|
+
}), [["__scopeId", "data-v-330a0664"]]), gn = {
|
|
1832
1821
|
mounted(e, t) {
|
|
1833
1822
|
let n = E(null), r = E(!1), i = E(!1), a = E(t.value), o = null, s = !1, c = st(e), l = () => {
|
|
1834
1823
|
n.value || (n.value = ct(a.value, c), lt(n.value), o = new ResizeObserver(() => {
|
|
1835
1824
|
n.value && (r.value || i.value) && ut(e, n.value);
|
|
1836
1825
|
}), o.observe(n.value));
|
|
1837
1826
|
};
|
|
1838
|
-
|
|
1827
|
+
W(() => {
|
|
1839
1828
|
n.value && (n.value.textContent = a.value);
|
|
1840
1829
|
});
|
|
1841
1830
|
let u = () => {
|
|
1842
1831
|
n.value && (r.value || i.value) && ut(e, n.value);
|
|
1843
1832
|
};
|
|
1844
|
-
|
|
1833
|
+
W(() => {
|
|
1845
1834
|
r.value || i.value ? (l(), n.value && ut(e, n.value), s ||= (window.addEventListener("scroll", u, { capture: !0 }), !0)) : (s &&= (window.removeEventListener("scroll", u, { capture: !0 }), !1), n.value && (dt(n.value), setTimeout(() => {
|
|
1846
1835
|
e.dispatchEvent(new CustomEvent("tooltip-hide"));
|
|
1847
1836
|
}, 150)));
|
|
@@ -1880,7 +1869,7 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1880
1869
|
let t = e._v_gtooltip;
|
|
1881
1870
|
t && t.tooltip && t.tooltip.value && (t.resizeObserver && t.resizeObserver.disconnect(), t.tooltip.value.remove(), t.tooltip.value = null), t && t.onScroll && window.removeEventListener("scroll", t.onScroll, { capture: !0 }), e.removeEventListener("mouseenter", t.onMouseEnter), e.removeEventListener("mouseleave", t.onMouseLeave), e.removeEventListener("focus", t.onFocus), e.removeEventListener("blur", t.onBlur), e.removeEventListener("keydown", t.onKeyDown), e.removeAttribute("aria-describedby");
|
|
1882
1871
|
}
|
|
1883
|
-
},
|
|
1872
|
+
}, _n = { class: "g-clipboard-text" }, vn = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1884
1873
|
__name: "GClipboard",
|
|
1885
1874
|
props: {
|
|
1886
1875
|
text: {},
|
|
@@ -1888,12 +1877,12 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1888
1877
|
copyLabel: {}
|
|
1889
1878
|
},
|
|
1890
1879
|
setup(t) {
|
|
1891
|
-
let n = t, r =
|
|
1880
|
+
let n = t, r = gn, { text: i, copy: l, copied: u, isSupported: d } = ne({ source: n.text }), f = E(n.copyLabel ?? "Copy to clipboard"), p = () => {
|
|
1892
1881
|
d.value ? (l(), f.value = "Copied") : f.value = "Copy not supported";
|
|
1893
1882
|
}, m = () => {
|
|
1894
1883
|
f.value = n.copyLabel ?? "Copy to clipboard";
|
|
1895
1884
|
};
|
|
1896
|
-
return (i, l) => (C(), o("div",
|
|
1885
|
+
return (i, l) => (C(), o("div", _n, [t.hideText ? a("", !0) : (C(), o(e, { key: 0 }, [c(M(n.text), 1)], 64)), K((C(), o("button", {
|
|
1897
1886
|
type: "button",
|
|
1898
1887
|
"aria-label": "Copy",
|
|
1899
1888
|
onClick: p,
|
|
@@ -1908,17 +1897,17 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1908
1897
|
}, [s("path", {
|
|
1909
1898
|
fill: "currentColor",
|
|
1910
1899
|
d: "M480 400L288 400C279.2 400 272 392.8 272 384L272 128C272 119.2 279.2 112 288 112L421.5 112C425.7 112 429.8 113.7 432.8 116.7L491.3 175.2C494.3 178.2 496 182.3 496 186.5L496 384C496 392.8 488.8 400 480 400zM288 448L480 448C515.3 448 544 419.3 544 384L544 186.5C544 169.5 537.3 153.2 525.3 141.2L466.7 82.7C454.7 70.7 438.5 64 421.5 64L288 64C252.7 64 224 92.7 224 128L224 384C224 419.3 252.7 448 288 448zM160 192C124.7 192 96 220.7 96 256L96 512C96 547.3 124.7 576 160 576L352 576C387.3 576 416 547.3 416 512L416 496L368 496L368 512C368 520.8 360.8 528 352 528L160 528C151.2 528 144 520.8 144 512L144 256C144 247.2 151.2 240 160 240L176 240L176 192L160 192z"
|
|
1911
|
-
})], -1)]], 32)), [[
|
|
1900
|
+
})], -1)]], 32)), [[I(r), f.value]])]));
|
|
1912
1901
|
}
|
|
1913
|
-
}), [["__scopeId", "data-v-bd5d31d2"]]),
|
|
1902
|
+
}), [["__scopeId", "data-v-bd5d31d2"]]), yn = { class: "g-history-scroller-wrapper" }, bn = {
|
|
1914
1903
|
key: 0,
|
|
1915
1904
|
class: "g-history-shadow g-history-shadow--top",
|
|
1916
1905
|
"aria-hidden": "true"
|
|
1917
|
-
},
|
|
1906
|
+
}, xn = {
|
|
1918
1907
|
key: 1,
|
|
1919
1908
|
class: "g-history-shadow g-history-shadow--bottom",
|
|
1920
1909
|
"aria-hidden": "true"
|
|
1921
|
-
},
|
|
1910
|
+
}, Sn = ["role", "aria-label"], Cn = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
1922
1911
|
__name: "GHistoryScroller",
|
|
1923
1912
|
props: {
|
|
1924
1913
|
label: {},
|
|
@@ -1942,17 +1931,17 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1942
1931
|
}
|
|
1943
1932
|
S(() => {
|
|
1944
1933
|
g(f);
|
|
1945
|
-
}),
|
|
1934
|
+
}), ce(i, () => {
|
|
1946
1935
|
u.value && f();
|
|
1947
|
-
}),
|
|
1936
|
+
}), ce(c, () => {
|
|
1948
1937
|
u.value && f();
|
|
1949
|
-
}),
|
|
1938
|
+
}), U(() => n.entries, async () => {
|
|
1950
1939
|
u.value && (await g(), f());
|
|
1951
1940
|
});
|
|
1952
1941
|
let m = r(() => [...n.entries].reverse());
|
|
1953
|
-
return (n, r) => (C(), o("div",
|
|
1954
|
-
d.value ? a("", !0) : (C(), o("div",
|
|
1955
|
-
u.value ? a("", !0) : (C(), o("div",
|
|
1942
|
+
return (n, r) => (C(), o("div", yn, [
|
|
1943
|
+
d.value ? a("", !0) : (C(), o("div", bn)),
|
|
1944
|
+
u.value ? a("", !0) : (C(), o("div", xn)),
|
|
1956
1945
|
s("div", {
|
|
1957
1946
|
ref_key: "scrollerRef",
|
|
1958
1947
|
ref: i,
|
|
@@ -1967,7 +1956,7 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1967
1956
|
onClick: r[0] ||= () => f({ focusLast: !0 }),
|
|
1968
1957
|
"aria-label": "Jump to Latest"
|
|
1969
1958
|
}, {
|
|
1970
|
-
default:
|
|
1959
|
+
default: G(() => [...r[1] ||= [s("svg", {
|
|
1971
1960
|
"aria-hidden": "true",
|
|
1972
1961
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1973
1962
|
viewBox: "0 0 640 640",
|
|
@@ -1987,31 +1976,31 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
1987
1976
|
key: e.id,
|
|
1988
1977
|
class: "g-history-entry",
|
|
1989
1978
|
tabindex: "-1"
|
|
1990
|
-
}, [O(n.$slots, "default", { entry: e }, void 0, !0)]))), 128))], 512)], 40,
|
|
1979
|
+
}, [O(n.$slots, "default", { entry: e }, void 0, !0)]))), 128))], 512)], 40, Sn)
|
|
1991
1980
|
]));
|
|
1992
1981
|
}
|
|
1993
|
-
}), [["__scopeId", "data-v-dde35ac8"]]),
|
|
1982
|
+
}), [["__scopeId", "data-v-dde35ac8"]]), wn = { class: "g-three-way-toggle-wrapper" }, Tn = { class: "g-three-way-toggle-control" }, En = ["id"], Dn = [
|
|
1994
1983
|
"aria-labelledby",
|
|
1995
1984
|
"aria-describedby",
|
|
1996
1985
|
"disabled",
|
|
1997
1986
|
"aria-invalid",
|
|
1998
1987
|
"aria-errormessage"
|
|
1999
|
-
],
|
|
1988
|
+
], On = { key: 0 }, kn = { key: 1 }, An = { key: 2 }, jn = ["for"], Mn = [
|
|
2000
1989
|
"id",
|
|
2001
1990
|
"name",
|
|
2002
1991
|
"checked",
|
|
2003
1992
|
"disabled"
|
|
2004
|
-
],
|
|
1993
|
+
], Nn = ["for"], Pn = [
|
|
2005
1994
|
"id",
|
|
2006
1995
|
"name",
|
|
2007
1996
|
"checked",
|
|
2008
1997
|
"disabled"
|
|
2009
|
-
],
|
|
1998
|
+
], Fn = ["for"], In = [
|
|
2010
1999
|
"id",
|
|
2011
2000
|
"name",
|
|
2012
2001
|
"checked",
|
|
2013
2002
|
"disabled"
|
|
2014
|
-
],
|
|
2003
|
+
], Ln = ["id"], Rn = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2015
2004
|
__name: "GThreeWayToggle",
|
|
2016
2005
|
props: /* @__PURE__ */ m({
|
|
2017
2006
|
label: {},
|
|
@@ -2027,7 +2016,7 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2027
2016
|
}),
|
|
2028
2017
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
2029
2018
|
setup(e, { emit: t }) {
|
|
2030
|
-
let n = e, i =
|
|
2019
|
+
let n = e, i = z(e, "modelValue"), l = t;
|
|
2031
2020
|
function u(e) {
|
|
2032
2021
|
let t = i.value;
|
|
2033
2022
|
i.value = e, e !== t && l("change", {
|
|
@@ -2041,112 +2030,112 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2041
2030
|
function f(e) {
|
|
2042
2031
|
n.disabled || i.value === e && u(null);
|
|
2043
2032
|
}
|
|
2044
|
-
let p =
|
|
2033
|
+
let p = R(), m = r(() => `g-three-way-toggle-${p}`), h = R(), g = R(), v = R(), y = r(() => i.value === !1 ? "g-left" : i.value === !0 ? "g-right" : "g-center");
|
|
2045
2034
|
function b(e) {
|
|
2046
2035
|
n.disabled || (e.key === "n" || e.key === "N" ? (u(!1), e.preventDefault()) : (e.key === "y" || e.key === "Y") && (u(!0), e.preventDefault()));
|
|
2047
2036
|
}
|
|
2048
|
-
return (t, n) => (C(), o("div",
|
|
2037
|
+
return (t, n) => (C(), o("div", wn, [s("div", Tn, [s("span", {
|
|
2049
2038
|
class: "g-label",
|
|
2050
|
-
id:
|
|
2051
|
-
}, [O(t.$slots, "label", {}, () => [c(
|
|
2039
|
+
id: I(p)
|
|
2040
|
+
}, [O(t.$slots, "label", {}, () => [c(M(e.label), 1)], !0)], 8, En), s("fieldset", {
|
|
2052
2041
|
class: _(["g-three-way-toggle", { "g-has-error": e.error }]),
|
|
2053
2042
|
role: "radiogroup",
|
|
2054
|
-
"aria-labelledby":
|
|
2043
|
+
"aria-labelledby": I(p),
|
|
2055
2044
|
"aria-describedby": e.describedby,
|
|
2056
2045
|
disabled: e.disabled,
|
|
2057
2046
|
"aria-invalid": e.error ? "true" : void 0,
|
|
2058
|
-
"aria-errormessage": e.error ?
|
|
2047
|
+
"aria-errormessage": e.error ? I(p) + "-error" : void 0
|
|
2059
2048
|
}, [s("div", { class: _(["g-toggle-track", [y.value, { "g-disabled": e.disabled }]]) }, [
|
|
2060
2049
|
s("span", {
|
|
2061
2050
|
class: _(["g-toggle-thumb", y.value]),
|
|
2062
2051
|
"aria-hidden": "true"
|
|
2063
|
-
}, [i.value === !1 ? (C(), o("span",
|
|
2052
|
+
}, [i.value === !1 ? (C(), o("span", On, "NO")) : i.value === !0 ? (C(), o("span", kn, "YES")) : (C(), o("span", An))], 2),
|
|
2064
2053
|
s("label", {
|
|
2065
|
-
for:
|
|
2054
|
+
for: I(h),
|
|
2066
2055
|
class: "g-toggle-option g-left",
|
|
2067
2056
|
onClick: n[1] ||= (e) => f(!1),
|
|
2068
2057
|
onKeydown: b
|
|
2069
2058
|
}, [s("input", {
|
|
2070
2059
|
type: "radio",
|
|
2071
|
-
id:
|
|
2060
|
+
id: I(h),
|
|
2072
2061
|
name: m.value,
|
|
2073
2062
|
checked: i.value === !1,
|
|
2074
2063
|
value: "false",
|
|
2075
2064
|
disabled: e.disabled,
|
|
2076
2065
|
onChange: n[0] ||= (e) => d(!1)
|
|
2077
|
-
}, null, 40,
|
|
2066
|
+
}, null, 40, Mn), n[5] ||= s("span", { class: "ilw-sr-only" }, "No", -1)], 40, jn),
|
|
2078
2067
|
s("label", {
|
|
2079
|
-
for:
|
|
2068
|
+
for: I(g),
|
|
2080
2069
|
class: "g-toggle-option g-center",
|
|
2081
2070
|
onKeydown: b
|
|
2082
2071
|
}, [s("input", {
|
|
2083
2072
|
type: "radio",
|
|
2084
|
-
id:
|
|
2073
|
+
id: I(g),
|
|
2085
2074
|
name: m.value,
|
|
2086
2075
|
checked: i.value === null,
|
|
2087
2076
|
disabled: e.disabled,
|
|
2088
2077
|
onChange: n[2] ||= (e) => d(null)
|
|
2089
|
-
}, null, 40,
|
|
2078
|
+
}, null, 40, Pn), n[6] ||= s("span", { class: "ilw-sr-only" }, "Unset", -1)], 40, Nn),
|
|
2090
2079
|
s("label", {
|
|
2091
|
-
for:
|
|
2080
|
+
for: I(v),
|
|
2092
2081
|
class: "g-toggle-option g-right",
|
|
2093
2082
|
onClick: n[4] ||= (e) => f(!0),
|
|
2094
2083
|
onKeydown: b
|
|
2095
2084
|
}, [s("input", {
|
|
2096
2085
|
type: "radio",
|
|
2097
|
-
id:
|
|
2086
|
+
id: I(v),
|
|
2098
2087
|
name: m.value,
|
|
2099
2088
|
value: "true",
|
|
2100
2089
|
checked: i.value === !0,
|
|
2101
2090
|
disabled: e.disabled,
|
|
2102
2091
|
onChange: n[3] ||= (e) => d(!0)
|
|
2103
|
-
}, null, 40,
|
|
2104
|
-
], 2)], 10,
|
|
2092
|
+
}, null, 40, In), n[7] ||= s("span", { class: "ilw-sr-only" }, "Yes", -1)], 40, Fn)
|
|
2093
|
+
], 2)], 10, Dn)]), e.error ? (C(), o("div", {
|
|
2105
2094
|
key: 0,
|
|
2106
|
-
id: `${
|
|
2095
|
+
id: `${I(p)}-error`,
|
|
2107
2096
|
class: "g-form-error",
|
|
2108
2097
|
role: "alert",
|
|
2109
2098
|
"aria-atomic": "true"
|
|
2110
|
-
},
|
|
2099
|
+
}, M(e.error), 9, Ln)) : a("", !0)]));
|
|
2111
2100
|
}
|
|
2112
|
-
}), [["__scopeId", "data-v-b5b2babc"]]),
|
|
2101
|
+
}), [["__scopeId", "data-v-b5b2babc"]]), zn = {
|
|
2113
2102
|
ref: "tableBodyRef",
|
|
2114
2103
|
class: "efficient-table-body"
|
|
2115
|
-
},
|
|
2104
|
+
}, Bn = ["aria-rowindex"], Vn = {
|
|
2116
2105
|
key: 0,
|
|
2117
2106
|
class: "table-group-checkbox"
|
|
2118
|
-
},
|
|
2107
|
+
}, Hn = ["colspan"], Un = [
|
|
2119
2108
|
"aria-rowindex",
|
|
2120
2109
|
"onMousedown",
|
|
2121
2110
|
"onClick"
|
|
2122
|
-
],
|
|
2111
|
+
], Wn = [
|
|
2123
2112
|
"checked",
|
|
2124
2113
|
"onClick",
|
|
2125
2114
|
"aria-label",
|
|
2126
2115
|
"name"
|
|
2127
|
-
],
|
|
2116
|
+
], Gn = ["id"], Kn = {
|
|
2128
2117
|
key: 0,
|
|
2129
2118
|
class: "editable-cell"
|
|
2130
|
-
},
|
|
2119
|
+
}, qn = {
|
|
2131
2120
|
key: 0,
|
|
2132
2121
|
class: "cell-prefix"
|
|
2133
|
-
},
|
|
2122
|
+
}, Jn = [
|
|
2134
2123
|
"value",
|
|
2135
2124
|
"onChange",
|
|
2136
2125
|
"aria-labelledby",
|
|
2137
2126
|
"aria-invalid",
|
|
2138
2127
|
"name"
|
|
2139
|
-
],
|
|
2128
|
+
], Yn = ["value"], Xn = [
|
|
2140
2129
|
"value",
|
|
2141
2130
|
"onInput",
|
|
2142
2131
|
"aria-labelledby",
|
|
2143
2132
|
"aria-invalid",
|
|
2144
2133
|
"aria-errormessage",
|
|
2145
2134
|
"name"
|
|
2146
|
-
],
|
|
2135
|
+
], Zn = {
|
|
2147
2136
|
key: 3,
|
|
2148
2137
|
class: "cell-suffix"
|
|
2149
|
-
},
|
|
2138
|
+
}, Qn = ["id"], $n = /* @__PURE__ */ u({
|
|
2150
2139
|
__name: "GTableBody",
|
|
2151
2140
|
props: {
|
|
2152
2141
|
data: {},
|
|
@@ -2215,13 +2204,13 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2215
2204
|
function w(e, t) {
|
|
2216
2205
|
if (l.changeTracker) return l.changeTracker.getError(e.key, t.key);
|
|
2217
2206
|
}
|
|
2218
|
-
return (n, r) => (C(), o("tbody",
|
|
2207
|
+
return (n, r) => (C(), o("tbody", zn, [(C(!0), o(e, null, D(t.data, (n, l) => (C(), o(e, { key: n.key }, [t.groupBy && (l === 0 || n[t.groupBy] !== t.data[l - 1][t.groupBy]) ? (C(), o("tr", {
|
|
2219
2208
|
key: 0,
|
|
2220
2209
|
"aria-rowindex": t.startIndex + l + 2
|
|
2221
|
-
}, [t.bulkSelectionEnabled ? (C(), o("td",
|
|
2210
|
+
}, [t.bulkSelectionEnabled ? (C(), o("td", Vn)) : a("", !0), s("td", {
|
|
2222
2211
|
colspan: t.columns.length,
|
|
2223
2212
|
class: "table-group-row"
|
|
2224
|
-
}, [t.groupRender ? (C(), i(
|
|
2213
|
+
}, [t.groupRender ? (C(), i(k(t.groupRender(n[t.groupBy], n)), { key: 0 })) : (C(), o(e, { key: 1 }, [c(M(n[t.groupBy]), 1)], 64))], 8, Hn)], 8, Bn)) : a("", !0), s("tr", {
|
|
2225
2214
|
class: _([
|
|
2226
2215
|
"efficient-table-row",
|
|
2227
2216
|
{
|
|
@@ -2236,7 +2225,7 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2236
2225
|
}, [t.bulkSelectionEnabled ? (C(), o("td", {
|
|
2237
2226
|
key: 0,
|
|
2238
2227
|
class: "td-checkbox",
|
|
2239
|
-
onClick: r[0] ||=
|
|
2228
|
+
onClick: r[0] ||= q(() => {}, ["stop"])
|
|
2240
2229
|
}, [s("input", {
|
|
2241
2230
|
type: "checkbox",
|
|
2242
2231
|
checked: p(n.key),
|
|
@@ -2244,7 +2233,7 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2244
2233
|
"aria-label": `Select row ${n.key}`,
|
|
2245
2234
|
name: `row-${n.key}-checkbox`,
|
|
2246
2235
|
class: "g-bulk-select-checkbox"
|
|
2247
|
-
}, null, 8,
|
|
2236
|
+
}, null, 8, Wn)])) : a("", !0), (C(!0), o(e, null, D(t.columns, (r) => (C(), o("td", {
|
|
2248
2237
|
key: r.key,
|
|
2249
2238
|
id: b(r) ? `${t.tableId}-td-${n.key}-${String(r.key)}` : void 0,
|
|
2250
2239
|
class: _([
|
|
@@ -2253,8 +2242,8 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2253
2242
|
S(n, r) ? "g-cell-error" : "",
|
|
2254
2243
|
typeof r.tdClass == "function" ? r.tdClass(n) : r.tdClass
|
|
2255
2244
|
])
|
|
2256
|
-
}, [r.editable ? (C(), o("div",
|
|
2257
|
-
r.editable.prefix ? (C(), o("span",
|
|
2245
|
+
}, [r.editable ? (C(), o("div", Kn, [
|
|
2246
|
+
r.editable.prefix ? (C(), o("span", qn, M(r.editable.prefix), 1)) : a("", !0),
|
|
2258
2247
|
r.editable.type === "select" ? (C(), o("select", {
|
|
2259
2248
|
key: 1,
|
|
2260
2249
|
value: n[r.key],
|
|
@@ -2266,7 +2255,7 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2266
2255
|
}, [(C(!0), o(e, null, D(r.editable.options, (e) => (C(), o("option", {
|
|
2267
2256
|
key: e.value,
|
|
2268
2257
|
value: e.value
|
|
2269
|
-
},
|
|
2258
|
+
}, M(e.label), 9, Yn))), 128))], 40, Jn)) : (C(), o("input", h({
|
|
2270
2259
|
key: 2,
|
|
2271
2260
|
value: n[r.key]
|
|
2272
2261
|
}, { ref_for: !0 }, r.editable.inputAttributes, {
|
|
@@ -2280,44 +2269,44 @@ var cn = ["id"], ln = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
|
2280
2269
|
paddingLeft: r.editable.prefix ? "1.5rem" : void 0,
|
|
2281
2270
|
paddingRight: r.editable.suffix ? "2rem" : void 0
|
|
2282
2271
|
}
|
|
2283
|
-
}), null, 16,
|
|
2284
|
-
r.editable.suffix ? (C(), o("span",
|
|
2285
|
-
])) : r.display ? (C(), i(
|
|
2272
|
+
}), null, 16, Xn)),
|
|
2273
|
+
r.editable.suffix ? (C(), o("span", Zn, M(r.editable.suffix), 1)) : a("", !0)
|
|
2274
|
+
])) : r.display ? (C(), i(k(r.display(n)), { key: 1 })) : (C(), o(e, { key: 2 }, [c(M(n[r.key]), 1)], 64)), S(n, r) ? (C(), o("div", {
|
|
2286
2275
|
key: 3,
|
|
2287
2276
|
role: "alert",
|
|
2288
2277
|
class: "g-cell-error-message",
|
|
2289
2278
|
id: `${t.tableId}-error-${n.key}-${String(r.key)}`
|
|
2290
|
-
},
|
|
2279
|
+
}, M(w(n, r)), 9, Qn)) : a("", !0)], 10, Gn))), 128))], 42, Un)], 64))), 128))], 512));
|
|
2291
2280
|
}
|
|
2292
2281
|
});
|
|
2293
2282
|
//#endregion
|
|
2294
2283
|
//#region src/compose/useFiltering.ts
|
|
2295
|
-
function
|
|
2284
|
+
function er(e) {
|
|
2296
2285
|
if (!(Array.isArray(e) && e.length === 0) && !(e === null || e === !1 || e === "")) return e;
|
|
2297
2286
|
}
|
|
2298
|
-
function
|
|
2287
|
+
function tr(e) {
|
|
2299
2288
|
return Object.fromEntries(Object.entries(e).filter(([e, t]) => t && (!Array.isArray(t) || t.length > 0)));
|
|
2300
2289
|
}
|
|
2301
|
-
function
|
|
2290
|
+
function nr(e) {
|
|
2302
2291
|
if (e != null) return Array.isArray(e) ? e.filter((e) => e != null) : [e];
|
|
2303
2292
|
}
|
|
2304
|
-
function
|
|
2293
|
+
function rr(e) {
|
|
2305
2294
|
let t = {};
|
|
2306
|
-
for (let [n, r] of Object.entries(
|
|
2295
|
+
for (let [n, r] of Object.entries(N(e))) Array.isArray(r) ? r.length > 0 && (t[n] = r) : r === !0 ? t[n] = "true" : t[n] = r || void 0;
|
|
2307
2296
|
return t;
|
|
2308
2297
|
}
|
|
2309
|
-
function
|
|
2298
|
+
function ir(e) {
|
|
2310
2299
|
let t = {};
|
|
2311
2300
|
return Object.keys(e).forEach((n) => {
|
|
2312
2301
|
let r = e[n];
|
|
2313
2302
|
r != null && r !== "" && r !== !1 && (Array.isArray(r) ? r.length > 0 && (t[n] = r.map((e) => String(e))) : t[n] = String(r));
|
|
2314
2303
|
}), t;
|
|
2315
2304
|
}
|
|
2316
|
-
function
|
|
2305
|
+
function ar(e, t = {}) {
|
|
2317
2306
|
let n = T(Object.fromEntries(Object.entries(e).map(([e, t]) => [e, t]))), i = t.syncWith;
|
|
2318
2307
|
if (i) {
|
|
2319
2308
|
if (i.value) {
|
|
2320
|
-
let t =
|
|
2309
|
+
let t = F(i);
|
|
2321
2310
|
Object.keys(e).forEach((e) => {
|
|
2322
2311
|
if (t[e] !== void 0) {
|
|
2323
2312
|
let r = t[e];
|
|
@@ -2325,14 +2314,14 @@ function rr(e, t = {}) {
|
|
|
2325
2314
|
}
|
|
2326
2315
|
});
|
|
2327
2316
|
}
|
|
2328
|
-
|
|
2329
|
-
i.value =
|
|
2317
|
+
U(n, (e) => {
|
|
2318
|
+
i.value = ir(e);
|
|
2330
2319
|
}, { deep: !0 });
|
|
2331
2320
|
}
|
|
2332
2321
|
return {
|
|
2333
2322
|
filters: n,
|
|
2334
2323
|
isFiltered: r(() => {
|
|
2335
|
-
for (let t of Object.keys(e)) if (
|
|
2324
|
+
for (let t of Object.keys(e)) if (er(n[t])) return !0;
|
|
2336
2325
|
return !1;
|
|
2337
2326
|
}),
|
|
2338
2327
|
clearFilters: () => {
|
|
@@ -2342,48 +2331,48 @@ function rr(e, t = {}) {
|
|
|
2342
2331
|
},
|
|
2343
2332
|
filteredColumns: r(() => {
|
|
2344
2333
|
let t = {};
|
|
2345
|
-
for (let r of Object.keys(e)) t[r] = !!
|
|
2334
|
+
for (let r of Object.keys(e)) t[r] = !!er(n[r]);
|
|
2346
2335
|
return t;
|
|
2347
2336
|
})
|
|
2348
2337
|
};
|
|
2349
2338
|
}
|
|
2350
2339
|
//#endregion
|
|
2351
2340
|
//#region src/components/GTable.vue?vue&type=script&setup=true&lang.ts
|
|
2352
|
-
var
|
|
2341
|
+
var or = { class: "g-table-outer-wrap" }, sr = {
|
|
2353
2342
|
key: 0,
|
|
2354
2343
|
class: "g-table-controls"
|
|
2355
|
-
},
|
|
2344
|
+
}, cr = { class: "g-clear-filters-wrap" }, lr = {
|
|
2356
2345
|
key: 0,
|
|
2357
2346
|
class: "pagination"
|
|
2358
|
-
},
|
|
2347
|
+
}, ur = { class: "g-result-count" }, dr = ["aria-label", "aria-rowcount"], fr = { class: "g-table-head" }, pr = { "aria-rowindex": "1" }, mr = {
|
|
2359
2348
|
key: 0,
|
|
2360
2349
|
scope: "col",
|
|
2361
2350
|
class: "g-th g-th-checkbox"
|
|
2362
|
-
},
|
|
2351
|
+
}, hr = [
|
|
2363
2352
|
"checked",
|
|
2364
2353
|
"indeterminate",
|
|
2365
2354
|
"aria-label"
|
|
2366
|
-
],
|
|
2355
|
+
], gr = ["id", "aria-sort"], _r = { class: "th-inner" }, vr = ["onClick"], yr = {
|
|
2367
2356
|
key: 0,
|
|
2368
2357
|
class: "sort-indicator"
|
|
2369
|
-
},
|
|
2358
|
+
}, br = ["aria-label"], xr = {
|
|
2370
2359
|
key: 1,
|
|
2371
2360
|
class: "g-column-head"
|
|
2372
|
-
},
|
|
2361
|
+
}, Sr = ["onClick", "aria-label"], Cr = { key: 1 }, wr = { class: "g-filter-toggle" }, Tr = [
|
|
2373
2362
|
"onUpdate:modelValue",
|
|
2374
2363
|
"id",
|
|
2375
2364
|
"aria-describedby"
|
|
2376
|
-
],
|
|
2365
|
+
], Er = ["for"], Dr = ["id"], Or = {
|
|
2377
2366
|
key: 2,
|
|
2378
2367
|
class: "g-multi-select"
|
|
2379
|
-
},
|
|
2368
|
+
}, kr = [
|
|
2380
2369
|
"onUpdate:modelValue",
|
|
2381
2370
|
"id",
|
|
2382
2371
|
"value"
|
|
2383
|
-
],
|
|
2372
|
+
], Ar = ["for"], jr = {
|
|
2384
2373
|
key: 1,
|
|
2385
2374
|
class: "g-bulk-actions-toolbar"
|
|
2386
|
-
},
|
|
2375
|
+
}, Mr = { class: "g-selected-count" }, Nr = { class: "g-bulk-actions" }, Pr = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2387
2376
|
__name: "GTable",
|
|
2388
2377
|
props: /* @__PURE__ */ m({
|
|
2389
2378
|
label: {},
|
|
@@ -2427,21 +2416,21 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2427
2416
|
"update:selectedRows"
|
|
2428
2417
|
]),
|
|
2429
2418
|
setup(t, { emit: n }) {
|
|
2430
|
-
let u =
|
|
2419
|
+
let u = z(t, "sortField"), d = z(t, "sortOrder"), f = z(t, "filter"), p = z(t, "selectedRows"), m = t, h = n;
|
|
2431
2420
|
function g(e) {
|
|
2432
2421
|
e.sortable && (u.value === e.key ? d.value === 1 ? d.value = -1 : d.value === -1 && (u.value = void 0, d.value = 1) : (u.value = e.key, d.value = 1));
|
|
2433
2422
|
}
|
|
2434
2423
|
let v = m.filtering;
|
|
2435
|
-
v ||=
|
|
2436
|
-
let { filters: b, filteredColumns: x, isFiltered: w, clearFilters: T } = v, k = r(() => m.data.map((e) => e.key)), A = r(() => p.value.filter((e) => k.value.includes(e))), j = r(() => !m.bulkSelectionEnabled || m.data.length === 0 ? !1 : A.value.length === k.value.length),
|
|
2437
|
-
function
|
|
2424
|
+
v ||= ar({});
|
|
2425
|
+
let { filters: b, filteredColumns: x, isFiltered: w, clearFilters: T } = v, k = r(() => m.data.map((e) => e.key)), A = r(() => p.value.filter((e) => k.value.includes(e))), j = r(() => !m.bulkSelectionEnabled || m.data.length === 0 ? !1 : A.value.length === k.value.length), P = r(() => !m.bulkSelectionEnabled || m.data.length === 0 ? !1 : A.value.length > 0 && A.value.length < k.value.length), F = E(null);
|
|
2426
|
+
function L() {
|
|
2438
2427
|
if (j.value) p.value = p.value.filter((e) => !k.value.includes(e));
|
|
2439
2428
|
else {
|
|
2440
2429
|
let e = new Set(p.value);
|
|
2441
2430
|
k.value.forEach((t) => e.add(t)), p.value = Array.from(e);
|
|
2442
2431
|
}
|
|
2443
2432
|
}
|
|
2444
|
-
function
|
|
2433
|
+
function V(e, t = !1) {
|
|
2445
2434
|
if (t && F.value) {
|
|
2446
2435
|
let t = k.value.indexOf(F.value), n = k.value.indexOf(e);
|
|
2447
2436
|
if (t !== -1 && n !== -1) {
|
|
@@ -2451,14 +2440,14 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2451
2440
|
} else p.value.includes(e) ? p.value = p.value.filter((t) => t !== e) : p.value = [...p.value, e];
|
|
2452
2441
|
F.value = e;
|
|
2453
2442
|
}
|
|
2454
|
-
function
|
|
2443
|
+
function ee(e) {
|
|
2455
2444
|
h("row-click", e);
|
|
2456
2445
|
}
|
|
2457
|
-
function
|
|
2446
|
+
function W(e) {
|
|
2458
2447
|
h("bulk-action", e, p.value);
|
|
2459
2448
|
}
|
|
2460
|
-
function
|
|
2461
|
-
let t = e.value, n = e.column.key, r =
|
|
2449
|
+
function J(e) {
|
|
2450
|
+
let t = e.value, n = e.column.key, r = N(e.row[n]);
|
|
2462
2451
|
e.column.editable?.inputAttributes?.type === "number" && (t = e.value === "" ? null : Number(e.value)), e.row[n] = t, h("cell-change", {
|
|
2463
2452
|
row: e.row,
|
|
2464
2453
|
column: e.column,
|
|
@@ -2466,28 +2455,28 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2466
2455
|
previousValue: r
|
|
2467
2456
|
});
|
|
2468
2457
|
}
|
|
2469
|
-
let Y =
|
|
2458
|
+
let Y = R(), te = B(), X = r(() => m.showPagination ? !0 : !!te.pagination), ne = r(() => !!(w.value || X.value));
|
|
2470
2459
|
return S(() => {
|
|
2471
2460
|
m.rowClickable && m.bulkSelectionEnabled && console.warn("GTable: rowClickable and bulkSelectionEnabled cannot be used together. rowClickable will be ignored.");
|
|
2472
2461
|
for (let e of m.columns) if (e.editable && e.display && console.warn(`GTable: Column "${String(e.key)}" has both 'editable' and 'display' configured. 'display' will be ignored.`), e.filter && e.filter.type === "multi-select" && !Array.isArray(f.value[e.key])) {
|
|
2473
2462
|
let t = f.value[e.key];
|
|
2474
2463
|
f.value[e.key] = t ? [t] : [];
|
|
2475
2464
|
}
|
|
2476
|
-
}),
|
|
2465
|
+
}), U(() => m.columns, (e) => {
|
|
2477
2466
|
for (let t of e) if (t.filter && t.filter.type === "multi-select" && !Array.isArray(f.value[t.key])) {
|
|
2478
2467
|
let e = f.value[t.key];
|
|
2479
2468
|
f.value[t.key] = e ? [e] : [];
|
|
2480
2469
|
}
|
|
2481
|
-
}, { immediate: !0 }), (n, r) => (C(), o("div",
|
|
2482
|
-
ne.value ? (C(), o("div",
|
|
2483
|
-
s("div",
|
|
2470
|
+
}, { immediate: !0 }), (n, r) => (C(), o("div", or, [
|
|
2471
|
+
ne.value ? (C(), o("div", sr, [
|
|
2472
|
+
s("div", cr, [I(w) ? (C(), i(Z, {
|
|
2484
2473
|
key: 0,
|
|
2485
2474
|
outlined: "",
|
|
2486
2475
|
size: "small",
|
|
2487
2476
|
class: "clear-filters",
|
|
2488
|
-
onClick:
|
|
2477
|
+
onClick: I(T)
|
|
2489
2478
|
}, {
|
|
2490
|
-
default:
|
|
2479
|
+
default: G(() => [...r[0] ||= [s("svg", {
|
|
2491
2480
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2492
2481
|
viewBox: "0 0 51.26 51.26",
|
|
2493
2482
|
height: "1em",
|
|
@@ -2498,37 +2487,37 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2498
2487
|
})], -1), s("span", { class: "g-clear-filters-text" }, " Clear Filters ", -1)]]),
|
|
2499
2488
|
_: 1
|
|
2500
2489
|
}, 8, ["onClick"])) : a("", !0)]),
|
|
2501
|
-
X.value ? (C(), o("div",
|
|
2502
|
-
s("span",
|
|
2490
|
+
X.value ? (C(), o("div", lr, [O(n.$slots, "pagination", {}, void 0, !0)])) : a("", !0),
|
|
2491
|
+
s("span", ur, M(m.resultCount || t.data.length) + " results", 1)
|
|
2503
2492
|
])) : a("", !0),
|
|
2504
2493
|
s("table", {
|
|
2505
2494
|
class: "g-table",
|
|
2506
2495
|
ref: "tableRef",
|
|
2507
2496
|
"aria-label": t.label,
|
|
2508
2497
|
"aria-rowcount": m.resultCount || t.data.length
|
|
2509
|
-
}, [s("thead",
|
|
2498
|
+
}, [s("thead", fr, [s("tr", pr, [t.bulkSelectionEnabled ? (C(), o("th", mr, [s("input", {
|
|
2510
2499
|
type: "checkbox",
|
|
2511
2500
|
checked: j.value,
|
|
2512
|
-
indeterminate:
|
|
2513
|
-
onChange:
|
|
2501
|
+
indeterminate: P.value,
|
|
2502
|
+
onChange: L,
|
|
2514
2503
|
"aria-label": j.value ? "Deselect all rows" : "Select all rows",
|
|
2515
2504
|
class: "g-bulk-select-checkbox"
|
|
2516
|
-
}, null, 40,
|
|
2505
|
+
}, null, 40, hr)])) : a("", !0), (C(!0), o(e, null, D(t.columns, (t) => (C(), o("th", {
|
|
2517
2506
|
key: t.key,
|
|
2518
|
-
id: `${
|
|
2507
|
+
id: `${I(Y)}-th-${String(t.key)}`,
|
|
2519
2508
|
"aria-sort": u.value === t.key ? d.value === 1 ? "ascending" : "descending" : "none",
|
|
2520
2509
|
class: _([
|
|
2521
2510
|
"g-th",
|
|
2522
2511
|
{ sorted: u.value === t.key },
|
|
2523
|
-
{ filtered:
|
|
2512
|
+
{ filtered: I(x)[t.key] }
|
|
2524
2513
|
]),
|
|
2525
2514
|
scope: "col"
|
|
2526
|
-
}, [s("div",
|
|
2515
|
+
}, [s("div", _r, [t.sortable ? (C(), o("button", {
|
|
2527
2516
|
key: 0,
|
|
2528
2517
|
type: "button",
|
|
2529
2518
|
class: "g-column-head",
|
|
2530
2519
|
onClick: (e) => g(t)
|
|
2531
|
-
}, [c(
|
|
2520
|
+
}, [c(M(t.label) + " ", 1), u.value === t.key ? (C(), o("span", yr, [(C(), o("svg", {
|
|
2532
2521
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2533
2522
|
viewBox: "0 0 640 640",
|
|
2534
2523
|
height: "1.5em",
|
|
@@ -2538,11 +2527,11 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2538
2527
|
}, [...r[1] ||= [s("path", {
|
|
2539
2528
|
fill: "currentColor",
|
|
2540
2529
|
d: "M300.3 199.2C312.9 188.9 331.4 189.7 343.1 201.4L471.1 329.4C480.3 338.6 483 352.3 478 364.3C473 376.3 461.4 384 448.5 384L192.5 384C179.6 384 167.9 376.2 162.9 364.2C157.9 352.2 160.7 338.5 169.9 329.4L297.9 201.4L300.3 199.2z"
|
|
2541
|
-
}, null, -1)]], 12,
|
|
2542
|
-
trigger:
|
|
2543
|
-
onClick:
|
|
2544
|
-
"aria-label":
|
|
2545
|
-
class: _(["g-filter-btn", { "g-active":
|
|
2530
|
+
}, null, -1)]], 12, br))])) : a("", !0)], 8, vr)) : (C(), o("span", xr, M(t.label), 1)), t.filter ? (C(), i(it, { key: 2 }, {
|
|
2531
|
+
trigger: G(({ toggle: e }) => [s("button", {
|
|
2532
|
+
onClick: q(e, ["stop"]),
|
|
2533
|
+
"aria-label": I(x)[t.key] ? "Column Filtered" : "Filter Column",
|
|
2534
|
+
class: _(["g-filter-btn", { "g-active": I(x)[t.key] }]),
|
|
2546
2535
|
type: "button"
|
|
2547
2536
|
}, [...r[2] ||= [s("svg", {
|
|
2548
2537
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -2552,8 +2541,8 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2552
2541
|
}, [s("path", {
|
|
2553
2542
|
fill: "currentColor",
|
|
2554
2543
|
d: "M96 128C83.1 128 71.4 135.8 66.4 147.8C61.4 159.8 64.2 173.5 73.4 182.6L256 365.3L256 480C256 488.5 259.4 496.6 265.4 502.6L329.4 566.6C338.6 575.8 352.3 578.5 364.3 573.5C376.3 568.5 384 556.9 384 544L384 365.3L566.6 182.7C575.8 173.5 578.5 159.8 573.5 147.8C568.5 135.8 556.9 128 544 128L96 128z"
|
|
2555
|
-
})], -1)]], 10,
|
|
2556
|
-
default:
|
|
2544
|
+
})], -1)]], 10, Sr)]),
|
|
2545
|
+
default: G(() => [t.filter.type === "select" ? (C(), i(Ht, {
|
|
2557
2546
|
key: 0,
|
|
2558
2547
|
modelValue: f.value[t.key],
|
|
2559
2548
|
"onUpdate:modelValue": (e) => f.value[t.key] = e,
|
|
@@ -2566,28 +2555,28 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2566
2555
|
"modelValue",
|
|
2567
2556
|
"onUpdate:modelValue",
|
|
2568
2557
|
"options"
|
|
2569
|
-
])) : t.filter.type === "toggle" ? (C(), o("div",
|
|
2570
|
-
|
|
2558
|
+
])) : t.filter.type === "toggle" ? (C(), o("div", Cr, [s("div", wr, [
|
|
2559
|
+
K(s("input", {
|
|
2571
2560
|
type: "checkbox",
|
|
2572
2561
|
"onUpdate:modelValue": (e) => f.value[t.key] = e,
|
|
2573
|
-
id: `${
|
|
2574
|
-
"aria-describedby": t.filter.description ? `${
|
|
2575
|
-
}, null, 8,
|
|
2576
|
-
s("label", { for: `${
|
|
2562
|
+
id: `${I(Y)}-filter-${String(t.key)}`,
|
|
2563
|
+
"aria-describedby": t.filter.description ? `${I(Y)}-filter-description-${String(t.key)}` : void 0
|
|
2564
|
+
}, null, 8, Tr), [[H, f.value[t.key]]]),
|
|
2565
|
+
s("label", { for: `${I(Y)}-filter-${String(t.key)}` }, M(t.filter.label), 9, Er),
|
|
2577
2566
|
t.filter.description ? (C(), o("span", {
|
|
2578
2567
|
key: 0,
|
|
2579
2568
|
class: "g-filter-description",
|
|
2580
|
-
id: `${
|
|
2581
|
-
},
|
|
2582
|
-
])])) : t.filter.type === "multi-select" ? (C(), o("fieldset",
|
|
2569
|
+
id: `${I(Y)}-filter-description-${String(t.key)}`
|
|
2570
|
+
}, M(t.filter.description), 9, Dr)) : a("", !0)
|
|
2571
|
+
])])) : t.filter.type === "multi-select" ? (C(), o("fieldset", Or, [
|
|
2583
2572
|
r[4] ||= s("legend", { class: "g-multi-select-legend" }, " Include values ", -1),
|
|
2584
|
-
(C(!0), o(e, null, D(t.filter.options, (e) => (C(), o("div", { key: e.value }, [
|
|
2573
|
+
(C(!0), o(e, null, D(t.filter.options, (e) => (C(), o("div", { key: e.value }, [K(s("input", {
|
|
2585
2574
|
type: "checkbox",
|
|
2586
2575
|
"onUpdate:modelValue": (e) => f.value[t.key] = e,
|
|
2587
2576
|
id: `filter-${String(t.key)}-${e.value}`,
|
|
2588
2577
|
value: e.value,
|
|
2589
2578
|
name: "filter-multiselect"
|
|
2590
|
-
}, null, 8,
|
|
2579
|
+
}, null, 8, kr), [[H, f.value[t.key]]]), s("label", { for: `filter-${String(t.key)}-${e.value}` }, M(e.label), 9, Ar)]))), 128)),
|
|
2591
2580
|
f.value[t.key] && f.value[t.key].length ? (C(), i(Z, {
|
|
2592
2581
|
key: 0,
|
|
2593
2582
|
class: "clear-multiselect-btn",
|
|
@@ -2595,12 +2584,12 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2595
2584
|
size: "small",
|
|
2596
2585
|
onClick: (e) => f.value[t.key] = []
|
|
2597
2586
|
}, {
|
|
2598
|
-
default:
|
|
2587
|
+
default: G(() => [...r[3] ||= [c(" Clear ", -1)]]),
|
|
2599
2588
|
_: 1
|
|
2600
2589
|
}, 8, ["onClick"])) : a("", !0)
|
|
2601
2590
|
])) : a("", !0)]),
|
|
2602
2591
|
_: 2
|
|
2603
|
-
}, 1024)) : a("", !0)])], 10,
|
|
2592
|
+
}, 1024)) : a("", !0)])], 10, gr))), 128))])]), l($n, {
|
|
2604
2593
|
data: t.data,
|
|
2605
2594
|
columns: t.columns,
|
|
2606
2595
|
"group-by": t.groupBy,
|
|
@@ -2610,11 +2599,11 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2610
2599
|
"start-index": t.startIndex,
|
|
2611
2600
|
"bulk-selection-enabled": t.bulkSelectionEnabled,
|
|
2612
2601
|
"selected-rows": p.value,
|
|
2613
|
-
"table-id":
|
|
2602
|
+
"table-id": I(Y),
|
|
2614
2603
|
"change-tracker": t.changeTracker,
|
|
2615
|
-
onRowClick:
|
|
2616
|
-
onToggleRow:
|
|
2617
|
-
onCellChange:
|
|
2604
|
+
onRowClick: ee,
|
|
2605
|
+
onToggleRow: V,
|
|
2606
|
+
onCellChange: J
|
|
2618
2607
|
}, null, 8, [
|
|
2619
2608
|
"data",
|
|
2620
2609
|
"columns",
|
|
@@ -2627,21 +2616,21 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2627
2616
|
"selected-rows",
|
|
2628
2617
|
"table-id",
|
|
2629
2618
|
"change-tracker"
|
|
2630
|
-
])], 8,
|
|
2631
|
-
t.bulkSelectionEnabled && p.value.length > 0 ? (C(), o("div",
|
|
2619
|
+
])], 8, dr),
|
|
2620
|
+
t.bulkSelectionEnabled && p.value.length > 0 ? (C(), o("div", jr, [s("span", Mr, M(p.value.length) + " row" + M(p.value.length === 1 ? "" : "s") + " selected", 1), s("ul", Nr, [(C(!0), o(e, null, D(t.bulkActions, (e) => (C(), o("li", { key: e.id }, [l(Z, {
|
|
2632
2621
|
theme: e.theme || "accent",
|
|
2633
|
-
onClick: (t) =>
|
|
2622
|
+
onClick: (t) => W(e.id),
|
|
2634
2623
|
size: "small"
|
|
2635
2624
|
}, {
|
|
2636
|
-
default:
|
|
2625
|
+
default: G(() => [c(M(e.label) + " " + M(p.value.length) + " row" + M(p.value.length === 1 ? "" : "s"), 1)]),
|
|
2637
2626
|
_: 2
|
|
2638
2627
|
}, 1032, ["theme", "onClick"])]))), 128))])])) : a("", !0)
|
|
2639
2628
|
]));
|
|
2640
2629
|
}
|
|
2641
|
-
}), [["__scopeId", "data-v-32760cb5"]]),
|
|
2630
|
+
}), [["__scopeId", "data-v-32760cb5"]]), Fr = {
|
|
2642
2631
|
class: "g-pagination",
|
|
2643
2632
|
"aria-label": "Pagination"
|
|
2644
|
-
},
|
|
2633
|
+
}, Ir = ["disabled"], Lr = ["disabled"], Rr = { class: "page-range" }, zr = ["disabled"], Br = ["disabled"], Vr = ["value"], Hr = ["value"], Ur = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2645
2634
|
__name: "GTablePagination",
|
|
2646
2635
|
props: /* @__PURE__ */ m({
|
|
2647
2636
|
start: {},
|
|
@@ -2656,14 +2645,14 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2656
2645
|
}),
|
|
2657
2646
|
emits: ["update:start", "update:pageSize"],
|
|
2658
2647
|
setup(t) {
|
|
2659
|
-
let n = t, i = r(() => Math.max(1, Math.ceil(n.total / n.pageSize))), a =
|
|
2648
|
+
let n = t, i = r(() => Math.max(1, Math.ceil(n.total / n.pageSize))), a = z(t, "start"), c = z(t, "pageSize"), l = r(() => a.value ?? n.start), u = r(() => c.value ?? n.pageSize), d = r(() => n.total === 0 ? 0 : l.value + 1), f = r(() => n.total === 0 ? 0 : Math.min(l.value + u.value, n.total)), p = r(() => Math.floor(l.value / u.value) + 1);
|
|
2660
2649
|
function m(e) {
|
|
2661
2650
|
e < 1 || e > i.value || (a.value = (e - 1) * u.value);
|
|
2662
2651
|
}
|
|
2663
2652
|
function h(e) {
|
|
2664
2653
|
c.value = parseInt(e.target.value, 10);
|
|
2665
2654
|
}
|
|
2666
|
-
return (t, r) => (C(), o("nav",
|
|
2655
|
+
return (t, r) => (C(), o("nav", Fr, [
|
|
2667
2656
|
s("button", {
|
|
2668
2657
|
class: "first-page g-pagination-button",
|
|
2669
2658
|
disabled: p.value === 1,
|
|
@@ -2688,7 +2677,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2688
2677
|
}),
|
|
2689
2678
|
s("path", { d: "M11 7l-5 5l5 5" }),
|
|
2690
2679
|
s("path", { d: "M17 7l-5 5l5 5" })
|
|
2691
|
-
], -1)]], 8,
|
|
2680
|
+
], -1)]], 8, Ir),
|
|
2692
2681
|
s("button", {
|
|
2693
2682
|
class: "prev-page g-pagination-button",
|
|
2694
2683
|
disabled: p.value === 1,
|
|
@@ -2709,8 +2698,8 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2709
2698
|
stroke: "none",
|
|
2710
2699
|
d: "M0 0h24v24H0z",
|
|
2711
2700
|
fill: "none"
|
|
2712
|
-
}), s("path", { d: "M15 6l-6 6l6 6" })], -1)]], 8,
|
|
2713
|
-
s("span",
|
|
2701
|
+
}), s("path", { d: "M15 6l-6 6l6 6" })], -1)]], 8, Lr),
|
|
2702
|
+
s("span", Rr, M(d.value) + " to " + M(f.value), 1),
|
|
2714
2703
|
s("button", {
|
|
2715
2704
|
class: "next-page g-pagination-button",
|
|
2716
2705
|
disabled: p.value === i.value,
|
|
@@ -2731,7 +2720,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2731
2720
|
stroke: "none",
|
|
2732
2721
|
d: "M0 0h24v24H0z",
|
|
2733
2722
|
fill: "none"
|
|
2734
|
-
}), s("path", { d: "M9 6l6 6l-6 6" })], -1)]], 8,
|
|
2723
|
+
}), s("path", { d: "M9 6l6 6l-6 6" })], -1)]], 8, zr),
|
|
2735
2724
|
s("button", {
|
|
2736
2725
|
class: "last-page g-pagination-button",
|
|
2737
2726
|
disabled: p.value === i.value,
|
|
@@ -2756,7 +2745,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2756
2745
|
}),
|
|
2757
2746
|
s("path", { d: "M7 7l5 5l-5 5" }),
|
|
2758
2747
|
s("path", { d: "M13 7l5 5l-5 5" })
|
|
2759
|
-
], -1)]], 8,
|
|
2748
|
+
], -1)]], 8, Br),
|
|
2760
2749
|
s("select", {
|
|
2761
2750
|
id: "page-size-select",
|
|
2762
2751
|
class: "page-size-select",
|
|
@@ -2770,14 +2759,14 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2770
2759
|
], (e) => (C(), o("option", {
|
|
2771
2760
|
key: e,
|
|
2772
2761
|
value: e
|
|
2773
|
-
},
|
|
2762
|
+
}, M(e), 9, Hr))), 128))], 40, Vr),
|
|
2774
2763
|
r[8] ||= s("label", {
|
|
2775
2764
|
class: "page-size-label",
|
|
2776
2765
|
for: "page-size-select"
|
|
2777
2766
|
}, "per page", -1)
|
|
2778
2767
|
]));
|
|
2779
2768
|
}
|
|
2780
|
-
}), [["__scopeId", "data-v-ae2bd887"]]),
|
|
2769
|
+
}), [["__scopeId", "data-v-ae2bd887"]]), Wr = ["id"], Gr = { class: "g-modal-inner" }, Kr = { class: "g-modal-header" }, qr = ["id"], Jr = ["id"], Yr = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2781
2770
|
__name: "GModal",
|
|
2782
2771
|
props: {
|
|
2783
2772
|
label: {},
|
|
@@ -2791,7 +2780,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2791
2780
|
},
|
|
2792
2781
|
emits: ["close"],
|
|
2793
2782
|
setup(e, { emit: c }) {
|
|
2794
|
-
let u = e, d = c, f =
|
|
2783
|
+
let u = e, d = c, f = V("dialog"), p = E(!0), m = R(), { pop: g, push: _, isTop: v, zIndex: y } = Ke(m, !0, !0), { deactivate: x, activate: w } = Qe(f, v);
|
|
2795
2784
|
function T() {
|
|
2796
2785
|
d("close");
|
|
2797
2786
|
}
|
|
@@ -2808,25 +2797,25 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2808
2797
|
name: "g-fade",
|
|
2809
2798
|
appear: ""
|
|
2810
2799
|
}, {
|
|
2811
|
-
default:
|
|
2812
|
-
id: "modal-" +
|
|
2800
|
+
default: G(() => [s("div", h({
|
|
2801
|
+
id: "modal-" + I(m),
|
|
2813
2802
|
class: ["g-modal", D.value],
|
|
2814
2803
|
role: "dialog",
|
|
2815
2804
|
"aria-modal": "true"
|
|
2816
2805
|
}, {
|
|
2817
|
-
"aria-labelledby": e.hiddenLabel ? void 0 : "modal-label-" +
|
|
2806
|
+
"aria-labelledby": e.hiddenLabel ? void 0 : "modal-label-" + I(m),
|
|
2818
2807
|
"aria-label": e.hiddenLabel ? e.label : void 0,
|
|
2819
2808
|
"aria-describedby": e.describedby ? e.describedby : void 0
|
|
2820
2809
|
}, {
|
|
2821
2810
|
ref_key: "dialog",
|
|
2822
2811
|
ref: f,
|
|
2823
|
-
style: { zIndex:
|
|
2824
|
-
}), [s("div",
|
|
2812
|
+
style: { zIndex: I(y) }
|
|
2813
|
+
}), [s("div", Gr, [s("div", Kr, [e.hiddenLabel ? a("", !0) : (C(), o("h2", {
|
|
2825
2814
|
key: 0,
|
|
2826
|
-
id: "modal-label-" +
|
|
2815
|
+
id: "modal-label-" + I(m),
|
|
2827
2816
|
class: "g-modal-label",
|
|
2828
2817
|
tabindex: "-1"
|
|
2829
|
-
},
|
|
2818
|
+
}, M(e.label), 9, qr)), s("button", {
|
|
2830
2819
|
class: "g-modal-close",
|
|
2831
2820
|
onClick: T,
|
|
2832
2821
|
"aria-label": "Close"
|
|
@@ -2839,18 +2828,18 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2839
2828
|
fill: "currentColor",
|
|
2840
2829
|
d: "M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z"
|
|
2841
2830
|
})], -1)]])]), s("div", {
|
|
2842
|
-
id: "modal-description-" +
|
|
2831
|
+
id: "modal-description-" + I(m),
|
|
2843
2832
|
class: "g-modal-content"
|
|
2844
|
-
}, [O(r.$slots, "default", {}, void 0, !0)], 8,
|
|
2833
|
+
}, [O(r.$slots, "default", {}, void 0, !0)], 8, Jr)])], 16, Wr)]),
|
|
2845
2834
|
_: 3
|
|
2846
2835
|
})]));
|
|
2847
2836
|
}
|
|
2848
|
-
}), [["__scopeId", "data-v-1b1aed31"]]),
|
|
2837
|
+
}), [["__scopeId", "data-v-1b1aed31"]]), Xr = [
|
|
2849
2838
|
"id",
|
|
2850
2839
|
"aria-expanded",
|
|
2851
2840
|
"aria-label",
|
|
2852
2841
|
"aria-controls"
|
|
2853
|
-
],
|
|
2842
|
+
], Zr = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2854
2843
|
__name: "GHamburgerMenu",
|
|
2855
2844
|
props: {
|
|
2856
2845
|
label: { default: "Main Navigation" },
|
|
@@ -2858,56 +2847,56 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2858
2847
|
},
|
|
2859
2848
|
emits: ["toggle"],
|
|
2860
2849
|
setup(e, { emit: t }) {
|
|
2861
|
-
let n = e, r = p("sidebar") ?? (de() ?
|
|
2850
|
+
let n = e, r = p("sidebar") ?? (de() ? ln(n.sidebarKey) : void 0), i = t;
|
|
2862
2851
|
function a() {
|
|
2863
2852
|
i("toggle"), r?.toggle();
|
|
2864
2853
|
}
|
|
2865
2854
|
function c(e) {
|
|
2866
2855
|
e.key === "Escape" && r?.open?.value && (r.open.value = !1);
|
|
2867
2856
|
}
|
|
2868
|
-
let l =
|
|
2857
|
+
let l = R();
|
|
2869
2858
|
return (t, n) => (C(), o("button", {
|
|
2870
|
-
id: `${
|
|
2859
|
+
id: `${I(r)?.id ?? I(l)}-hamburger`,
|
|
2871
2860
|
class: _(["g-hamburger-button", {
|
|
2872
|
-
"g-hamburger-button--open":
|
|
2873
|
-
"g-hamburger-button--collapsible":
|
|
2861
|
+
"g-hamburger-button--open": I(r)?.open?.value,
|
|
2862
|
+
"g-hamburger-button--collapsible": I(r)?.isCollapsible?.value
|
|
2874
2863
|
}]),
|
|
2875
2864
|
onClick: a,
|
|
2876
2865
|
onKeydown: c,
|
|
2877
|
-
"aria-expanded":
|
|
2866
|
+
"aria-expanded": I(r)?.open?.value ? "true" : "false",
|
|
2878
2867
|
"aria-label": e.label,
|
|
2879
|
-
"aria-controls":
|
|
2868
|
+
"aria-controls": I(r) ? `${I(r).id}-sidebar` : void 0
|
|
2880
2869
|
}, [...n[0] ||= [s("svg", {
|
|
2881
2870
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2882
2871
|
viewBox: "0 0 51.26 51.26"
|
|
2883
|
-
}, [s("g", { fill: "currentColor" }, [s("path", { d: "M11.6 16.52h28.06a3.24 3.24 0 1 0 0-6.48H11.6a3.24 3.24 0 0 0 0 6.48ZM39.66 22.07H11.6a3.24 3.24 0 0 0 0 6.48h28.06a3.24 3.24 0 1 0 0-6.48ZM39.66 34.1H11.6a3.24 3.24 0 0 0 0 6.48h28.06a3.24 3.24 0 1 0 0-6.48Z" })])], -1)]], 42,
|
|
2872
|
+
}, [s("g", { fill: "currentColor" }, [s("path", { d: "M11.6 16.52h28.06a3.24 3.24 0 1 0 0-6.48H11.6a3.24 3.24 0 0 0 0 6.48ZM39.66 22.07H11.6a3.24 3.24 0 0 0 0 6.48h28.06a3.24 3.24 0 1 0 0-6.48ZM39.66 34.1H11.6a3.24 3.24 0 0 0 0 6.48h28.06a3.24 3.24 0 1 0 0-6.48Z" })])], -1)]], 42, Xr));
|
|
2884
2873
|
}
|
|
2885
|
-
}), [["__scopeId", "data-v-2ff52853"]]),
|
|
2874
|
+
}), [["__scopeId", "data-v-2ff52853"]]), Qr = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2886
2875
|
__name: "GDetailList",
|
|
2887
2876
|
props: { variant: { default: "grid" } },
|
|
2888
2877
|
setup(e) {
|
|
2889
2878
|
let t = e;
|
|
2890
2879
|
return (e, n) => (C(), o("dl", { class: _(["g-detail-list", `g-detail-list--${t.variant}`]) }, [O(e.$slots, "default", {}, void 0, !0)], 2));
|
|
2891
2880
|
}
|
|
2892
|
-
}), [["__scopeId", "data-v-b851df7b"]]),
|
|
2881
|
+
}), [["__scopeId", "data-v-b851df7b"]]), $r = { class: "g-detail-list-item" }, ei = { class: "g-detail-list-item__label" }, ti = { class: "g-detail-list-item__value" }, ni = /* @__PURE__ */ u({
|
|
2893
2882
|
__name: "GDetailListItem",
|
|
2894
2883
|
props: { label: {} },
|
|
2895
2884
|
setup(e) {
|
|
2896
|
-
return (t, n) => (C(), o("div",
|
|
2885
|
+
return (t, n) => (C(), o("div", $r, [s("dt", ei, [O(t.$slots, "label", {}, () => [c(M(e.label), 1)])]), s("dd", ti, [O(t.$slots, "default")])]));
|
|
2897
2886
|
}
|
|
2898
|
-
}),
|
|
2887
|
+
}), ri = {
|
|
2899
2888
|
key: 0,
|
|
2900
2889
|
class: "g-scroll-lock-overlay"
|
|
2901
|
-
},
|
|
2890
|
+
}, ii = /* @__PURE__ */ u({
|
|
2902
2891
|
__name: "GOverlay",
|
|
2903
2892
|
setup(e) {
|
|
2904
2893
|
let { hasScrollLock: t } = qe();
|
|
2905
2894
|
return (e, r) => (C(), i(n, { name: "g-fade" }, {
|
|
2906
|
-
default:
|
|
2895
|
+
default: G(() => [I(t) ? (C(), o("div", ri)) : a("", !0)]),
|
|
2907
2896
|
_: 1
|
|
2908
2897
|
}));
|
|
2909
2898
|
}
|
|
2910
|
-
}),
|
|
2899
|
+
}), ai = { class: "popover-content" }, oi = { class: "year-dropdown" }, si = { class: "month-selector" }, ci = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2911
2900
|
__name: "GTermSelectorControl",
|
|
2912
2901
|
props: /* @__PURE__ */ m({
|
|
2913
2902
|
termYears: { default: () => ["2026"] },
|
|
@@ -2927,8 +2916,8 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2927
2916
|
}),
|
|
2928
2917
|
emits: ["update:modelValue"],
|
|
2929
2918
|
setup(e) {
|
|
2930
|
-
let t =
|
|
2931
|
-
return (n, r) => (C(), o("div",
|
|
2919
|
+
let t = z(e, "modelValue");
|
|
2920
|
+
return (n, r) => (C(), o("div", ai, [s("div", oi, [l(Ht, {
|
|
2932
2921
|
modelValue: t.value.year,
|
|
2933
2922
|
"onUpdate:modelValue": r[0] ||= (e) => t.value.year = e,
|
|
2934
2923
|
options: e.termYears,
|
|
@@ -2937,7 +2926,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2937
2926
|
"modelValue",
|
|
2938
2927
|
"options",
|
|
2939
2928
|
"label"
|
|
2940
|
-
])]), s("div",
|
|
2929
|
+
])]), s("div", si, [l(yt, {
|
|
2941
2930
|
modelValue: t.value.name,
|
|
2942
2931
|
"onUpdate:modelValue": r[1] ||= (e) => t.value.name = e,
|
|
2943
2932
|
options: e.termNames,
|
|
@@ -2949,10 +2938,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2949
2938
|
"label"
|
|
2950
2939
|
])])]));
|
|
2951
2940
|
}
|
|
2952
|
-
}), [["__scopeId", "data-v-43c70980"]]),
|
|
2941
|
+
}), [["__scopeId", "data-v-43c70980"]]), li = { class: "g-term-selector" }, ui = { class: "g-term-label" }, di = {
|
|
2953
2942
|
class: "popover-title",
|
|
2954
2943
|
tabindex: "-1"
|
|
2955
|
-
},
|
|
2944
|
+
}, fi = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
2956
2945
|
__name: "GTermSelector",
|
|
2957
2946
|
props: /* @__PURE__ */ m({
|
|
2958
2947
|
title: { default: "Period Selection" },
|
|
@@ -2973,21 +2962,21 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2973
2962
|
}),
|
|
2974
2963
|
emits: ["update:modelValue"],
|
|
2975
2964
|
setup(e) {
|
|
2976
|
-
let t =
|
|
2977
|
-
return (n, r) => (C(), o("div",
|
|
2978
|
-
trigger:
|
|
2965
|
+
let t = z(e, "modelValue");
|
|
2966
|
+
return (n, r) => (C(), o("div", li, [l(it, null, {
|
|
2967
|
+
trigger: G(({ toggle: e }) => [l(Z, {
|
|
2979
2968
|
class: "g-term-selector-button",
|
|
2980
2969
|
theme: "none",
|
|
2981
2970
|
outlined: "",
|
|
2982
2971
|
onClick: e
|
|
2983
2972
|
}, {
|
|
2984
|
-
default:
|
|
2973
|
+
default: G(() => [
|
|
2985
2974
|
r[0] ||= s("span", { class: "g-calendar-icon" }, [s("svg", {
|
|
2986
2975
|
role: "none presentation",
|
|
2987
2976
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2988
2977
|
viewBox: "0 0 640 640"
|
|
2989
2978
|
}, [s("path", { d: "M224 64C206.3 64 192 78.3 192 96L192 128L160 128C124.7 128 96 156.7 96 192L96 240L544 240L544 192C544 156.7 515.3 128 480 128L448 128L448 96C448 78.3 433.7 64 416 64C398.3 64 384 78.3 384 96L384 128L256 128L256 96C256 78.3 241.7 64 224 64zM96 288L96 480C96 515.3 124.7 544 160 544L480 544C515.3 544 544 515.3 544 480L544 288L96 288z" })])], -1),
|
|
2990
|
-
s("span",
|
|
2979
|
+
s("span", ui, M(t.value?.name) + " " + M(t.value?.year), 1),
|
|
2991
2980
|
r[1] ||= s("span", { class: "g-caret" }, [s("svg", {
|
|
2992
2981
|
role: "none presentation",
|
|
2993
2982
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -2996,15 +2985,15 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
2996
2985
|
]),
|
|
2997
2986
|
_: 1
|
|
2998
2987
|
}, 8, ["onClick"])]),
|
|
2999
|
-
default:
|
|
2988
|
+
default: G(() => [s("h2", di, M(e.title), 1), l(ci, v(f(n.$props)), null, 16)]),
|
|
3000
2989
|
_: 1
|
|
3001
2990
|
})]));
|
|
3002
2991
|
}
|
|
3003
|
-
}), [["__scopeId", "data-v-47e0fca1"]]),
|
|
2992
|
+
}), [["__scopeId", "data-v-47e0fca1"]]), pi = { class: "g-user-menu" }, mi = [
|
|
3004
2993
|
"aria-label",
|
|
3005
2994
|
"aria-expanded",
|
|
3006
2995
|
"onClick"
|
|
3007
|
-
],
|
|
2996
|
+
], hi = { class: "g-user-menu__popover" }, gi = { class: "g-user-menu__list" }, _i = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3008
2997
|
__name: "GUserMenu",
|
|
3009
2998
|
props: {
|
|
3010
2999
|
initials: {},
|
|
@@ -3013,36 +3002,36 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3013
3002
|
label: { default: "User menu" }
|
|
3014
3003
|
},
|
|
3015
3004
|
setup(t) {
|
|
3016
|
-
let n = `${
|
|
3005
|
+
let n = `${R()}-email`, r = E(!1), a = V("emailHeading");
|
|
3017
3006
|
d()?.appContext?.components?.RouterLink;
|
|
3018
|
-
let c =
|
|
3019
|
-
return (u, d) => (C(), o("div",
|
|
3007
|
+
let c = B();
|
|
3008
|
+
return (u, d) => (C(), o("div", pi, [l(it, {
|
|
3020
3009
|
modelValue: r.value,
|
|
3021
3010
|
"onUpdate:modelValue": d[0] ||= (e) => r.value = e,
|
|
3022
3011
|
minimal: ""
|
|
3023
3012
|
}, {
|
|
3024
|
-
trigger:
|
|
3013
|
+
trigger: G(({ toggle: e }) => [s("button", {
|
|
3025
3014
|
class: "g-user-menu__avatar",
|
|
3026
3015
|
style: y({ backgroundColor: t.color }),
|
|
3027
3016
|
"aria-label": t.initials + " - " + t.label,
|
|
3028
3017
|
"aria-expanded": r.value,
|
|
3029
3018
|
"aria-haspopup": "menu",
|
|
3030
3019
|
onClick: e
|
|
3031
|
-
},
|
|
3032
|
-
default:
|
|
3020
|
+
}, M(t.initials), 13, mi)]),
|
|
3021
|
+
default: G(() => [s("div", hi, [s("h2", {
|
|
3033
3022
|
id: n,
|
|
3034
3023
|
ref_key: "emailHeading",
|
|
3035
3024
|
ref: a,
|
|
3036
3025
|
class: "g-user-menu__email",
|
|
3037
3026
|
tabindex: "-1"
|
|
3038
|
-
},
|
|
3027
|
+
}, M(t.email), 513), s("nav", {
|
|
3039
3028
|
class: "g-user-menu__nav",
|
|
3040
3029
|
"aria-labelledby": n
|
|
3041
|
-
}, [s("ul",
|
|
3030
|
+
}, [s("ul", gi, [(C(!0), o(e, null, D(c.default(), (e, t) => (C(), o("li", { key: t }, [(C(), i(k(e)))]))), 128))])])])]),
|
|
3042
3031
|
_: 1
|
|
3043
3032
|
}, 8, ["modelValue"])]));
|
|
3044
3033
|
}
|
|
3045
|
-
}), [["__scopeId", "data-v-cedd2d44"]]),
|
|
3034
|
+
}), [["__scopeId", "data-v-cedd2d44"]]), vi = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3046
3035
|
__name: "GCurrencyInput",
|
|
3047
3036
|
props: /* @__PURE__ */ m({
|
|
3048
3037
|
label: { default: void 0 },
|
|
@@ -3051,6 +3040,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3051
3040
|
type: Boolean,
|
|
3052
3041
|
default: !1
|
|
3053
3042
|
},
|
|
3043
|
+
required: {
|
|
3044
|
+
type: Boolean,
|
|
3045
|
+
default: !1
|
|
3046
|
+
},
|
|
3054
3047
|
errors: { default: () => [] },
|
|
3055
3048
|
instructions: { default: "" },
|
|
3056
3049
|
name: { default: void 0 },
|
|
@@ -3061,7 +3054,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3061
3054
|
}),
|
|
3062
3055
|
emits: ["update:modelValue"],
|
|
3063
3056
|
setup(e) {
|
|
3064
|
-
let t = e, n =
|
|
3057
|
+
let t = e, n = z(e, "modelValue");
|
|
3065
3058
|
return (e, r) => (C(), i(Re, h({
|
|
3066
3059
|
modelValue: n.value,
|
|
3067
3060
|
"onUpdate:modelValue": r[0] ||= (e) => n.value = e,
|
|
@@ -3069,6 +3062,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3069
3062
|
label: t.label,
|
|
3070
3063
|
placeholder: t.placeholder,
|
|
3071
3064
|
disabled: t.disabled,
|
|
3065
|
+
required: t.required,
|
|
3072
3066
|
errors: t.errors,
|
|
3073
3067
|
instructions: t.instructions,
|
|
3074
3068
|
"form-key": t.formKey,
|
|
@@ -3082,12 +3076,13 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3082
3076
|
"label",
|
|
3083
3077
|
"placeholder",
|
|
3084
3078
|
"disabled",
|
|
3079
|
+
"required",
|
|
3085
3080
|
"errors",
|
|
3086
3081
|
"instructions",
|
|
3087
3082
|
"form-key"
|
|
3088
3083
|
]));
|
|
3089
3084
|
}
|
|
3090
|
-
}), [["__scopeId", "data-v-
|
|
3085
|
+
}), [["__scopeId", "data-v-6ad6135a"]]), yi = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3091
3086
|
__name: "GEmailInput",
|
|
3092
3087
|
props: /* @__PURE__ */ m({
|
|
3093
3088
|
label: { default: void 0 },
|
|
@@ -3096,6 +3091,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3096
3091
|
type: Boolean,
|
|
3097
3092
|
default: !1
|
|
3098
3093
|
},
|
|
3094
|
+
required: {
|
|
3095
|
+
type: Boolean,
|
|
3096
|
+
default: !1
|
|
3097
|
+
},
|
|
3099
3098
|
errors: { default: () => [] },
|
|
3100
3099
|
instructions: { default: "" },
|
|
3101
3100
|
name: { default: void 0 }
|
|
@@ -3105,7 +3104,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3105
3104
|
}),
|
|
3106
3105
|
emits: ["update:modelValue"],
|
|
3107
3106
|
setup(e) {
|
|
3108
|
-
let t =
|
|
3107
|
+
let t = z(e, "modelValue");
|
|
3109
3108
|
return (n, r) => (C(), i(Re, h({
|
|
3110
3109
|
modelValue: t.value,
|
|
3111
3110
|
"onUpdate:modelValue": r[0] ||= (e) => t.value = e,
|
|
@@ -3113,6 +3112,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3113
3112
|
label: e.label,
|
|
3114
3113
|
placeholder: e.placeholder,
|
|
3115
3114
|
disabled: e.disabled,
|
|
3115
|
+
required: e.required,
|
|
3116
3116
|
errors: e.errors,
|
|
3117
3117
|
instructions: e.instructions,
|
|
3118
3118
|
type: "email"
|
|
@@ -3122,17 +3122,18 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3122
3122
|
"label",
|
|
3123
3123
|
"placeholder",
|
|
3124
3124
|
"disabled",
|
|
3125
|
+
"required",
|
|
3125
3126
|
"errors",
|
|
3126
3127
|
"instructions"
|
|
3127
3128
|
]));
|
|
3128
3129
|
}
|
|
3129
|
-
}), [["__scopeId", "data-v-
|
|
3130
|
+
}), [["__scopeId", "data-v-d6d4df0c"]]), bi = ["for"], xi = {
|
|
3130
3131
|
key: 0,
|
|
3131
3132
|
class: "g-file-input-required"
|
|
3132
|
-
},
|
|
3133
|
+
}, Si = {
|
|
3133
3134
|
key: 0,
|
|
3134
3135
|
class: "g-file-input-box-header"
|
|
3135
|
-
},
|
|
3136
|
+
}, Ci = ["id"], wi = [
|
|
3136
3137
|
"id",
|
|
3137
3138
|
"disabled",
|
|
3138
3139
|
"required",
|
|
@@ -3141,11 +3142,11 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3141
3142
|
"aria-invalid",
|
|
3142
3143
|
"aria-describedby",
|
|
3143
3144
|
"aria-errormessage"
|
|
3144
|
-
],
|
|
3145
|
+
], Ti = {
|
|
3145
3146
|
key: 1,
|
|
3146
3147
|
class: "g-file-input-pills",
|
|
3147
3148
|
"aria-label": "Selected files"
|
|
3148
|
-
},
|
|
3149
|
+
}, Ei = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3149
3150
|
inheritAttrs: !1,
|
|
3150
3151
|
__name: "GFileInput",
|
|
3151
3152
|
props: /* @__PURE__ */ m({
|
|
@@ -3175,10 +3176,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3175
3176
|
}),
|
|
3176
3177
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
3177
3178
|
setup(t, { emit: n }) {
|
|
3178
|
-
let i = t, u =
|
|
3179
|
+
let i = t, u = z(t, "modelValue"), d = R(), { displayErrors: f } = $({
|
|
3179
3180
|
name: i.name,
|
|
3180
3181
|
value: u,
|
|
3181
|
-
errors:
|
|
3182
|
+
errors: P(i, "errors"),
|
|
3182
3183
|
formKey: i.formKey
|
|
3183
3184
|
}), p = n, m = E([]);
|
|
3184
3185
|
function h(e) {
|
|
@@ -3200,16 +3201,16 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3200
3201
|
return (n, r) => (C(), o("div", { class: _(["g-file-input-wrap", { "g-file-input-has-error": y.value }]) }, [
|
|
3201
3202
|
t.label ? (C(), o("label", {
|
|
3202
3203
|
key: 0,
|
|
3203
|
-
for:
|
|
3204
|
+
for: I(d),
|
|
3204
3205
|
class: "g-file-input-label"
|
|
3205
|
-
}, [c(
|
|
3206
|
+
}, [c(M(t.label) + " ", 1), t.required ? (C(), o("span", xi, "*")) : a("", !0)], 8, bi)) : a("", !0),
|
|
3206
3207
|
s("div", { class: _(["g-file-input-box", { "g-file-input-box--disabled": t.disabled }]) }, [
|
|
3207
|
-
t.instructions ? (C(), o("div",
|
|
3208
|
-
id: "instructions-" +
|
|
3208
|
+
t.instructions ? (C(), o("div", Si, [s("span", {
|
|
3209
|
+
id: "instructions-" + I(d),
|
|
3209
3210
|
class: "g-file-input-instructions"
|
|
3210
|
-
},
|
|
3211
|
+
}, M(t.instructions), 9, Ci)])) : a("", !0),
|
|
3211
3212
|
s("input", {
|
|
3212
|
-
id:
|
|
3213
|
+
id: I(d),
|
|
3213
3214
|
type: "file",
|
|
3214
3215
|
class: "g-file-input",
|
|
3215
3216
|
disabled: t.disabled,
|
|
@@ -3217,11 +3218,11 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3217
3218
|
accept: t.accept || void 0,
|
|
3218
3219
|
multiple: t.multiple,
|
|
3219
3220
|
"aria-invalid": y.value ? "true" : "false",
|
|
3220
|
-
"aria-describedby": t.instructions ? "instructions-" +
|
|
3221
|
-
"aria-errormessage": y.value ? "error-message-" +
|
|
3221
|
+
"aria-describedby": t.instructions ? "instructions-" + I(d) : void 0,
|
|
3222
|
+
"aria-errormessage": y.value ? "error-message-" + I(d) : void 0,
|
|
3222
3223
|
onChange: g
|
|
3223
|
-
}, null, 40,
|
|
3224
|
-
t.multiple && b.value.length > 0 ? (C(), o("ul",
|
|
3224
|
+
}, null, 40, wi),
|
|
3225
|
+
t.multiple && b.value.length > 0 ? (C(), o("ul", Ti, [(C(!0), o(e, null, D(b.value, (e) => (C(), o("li", {
|
|
3225
3226
|
key: e,
|
|
3226
3227
|
class: "g-file-input-pill"
|
|
3227
3228
|
}, [r[0] ||= s("svg", {
|
|
@@ -3229,15 +3230,15 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3229
3230
|
role: "none presentation",
|
|
3230
3231
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3231
3232
|
viewBox: "0 0 640 640"
|
|
3232
|
-
}, [s("path", { d: "M192 64C156.7 64 128 92.7 128 128L128 512C128 547.3 156.7 576 192 576L448 576C483.3 576 512 547.3 512 512L512 234.5C512 217.5 505.3 201.2 493.3 189.2L386.7 82.7C374.7 70.7 358.5 64 341.5 64L192 64zM453.5 240L360 240C346.7 240 336 229.3 336 216L336 122.5L453.5 240z" })], -1), c(" " +
|
|
3233
|
+
}, [s("path", { d: "M192 64C156.7 64 128 92.7 128 128L128 512C128 547.3 156.7 576 192 576L448 576C483.3 576 512 547.3 512 512L512 234.5C512 217.5 505.3 201.2 493.3 189.2L386.7 82.7C374.7 70.7 358.5 64 341.5 64L192 64zM453.5 240L360 240C346.7 240 336 229.3 336 216L336 122.5L453.5 240z" })], -1), c(" " + M(e), 1)]))), 128))])) : a("", !0)
|
|
3233
3234
|
], 2),
|
|
3234
|
-
l(
|
|
3235
|
+
l(je, {
|
|
3235
3236
|
errors: v.value,
|
|
3236
|
-
id: "error-message-" +
|
|
3237
|
+
id: "error-message-" + I(d)
|
|
3237
3238
|
}, null, 8, ["errors", "id"])
|
|
3238
3239
|
], 2));
|
|
3239
3240
|
}
|
|
3240
|
-
}), [["__scopeId", "data-v-0c8c7f65"]]),
|
|
3241
|
+
}), [["__scopeId", "data-v-0c8c7f65"]]), Di = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3241
3242
|
__name: "GDateInput",
|
|
3242
3243
|
props: /* @__PURE__ */ m({
|
|
3243
3244
|
label: { default: void 0 },
|
|
@@ -3246,6 +3247,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3246
3247
|
type: Boolean,
|
|
3247
3248
|
default: !1
|
|
3248
3249
|
},
|
|
3250
|
+
required: {
|
|
3251
|
+
type: Boolean,
|
|
3252
|
+
default: !1
|
|
3253
|
+
},
|
|
3249
3254
|
errors: { default: () => [] },
|
|
3250
3255
|
instructions: { default: "" },
|
|
3251
3256
|
name: { default: void 0 },
|
|
@@ -3256,7 +3261,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3256
3261
|
}),
|
|
3257
3262
|
emits: ["update:modelValue"],
|
|
3258
3263
|
setup(e) {
|
|
3259
|
-
let t = e, n =
|
|
3264
|
+
let t = e, n = z(e, "modelValue");
|
|
3260
3265
|
return (e, r) => (C(), i(Re, h({
|
|
3261
3266
|
modelValue: n.value,
|
|
3262
3267
|
"onUpdate:modelValue": r[0] ||= (e) => n.value = e,
|
|
@@ -3264,6 +3269,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3264
3269
|
label: t.label,
|
|
3265
3270
|
placeholder: t.placeholder,
|
|
3266
3271
|
disabled: t.disabled,
|
|
3272
|
+
required: t.required,
|
|
3267
3273
|
errors: t.errors,
|
|
3268
3274
|
instructions: t.instructions,
|
|
3269
3275
|
"form-key": t.formKey,
|
|
@@ -3274,22 +3280,27 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3274
3280
|
"label",
|
|
3275
3281
|
"placeholder",
|
|
3276
3282
|
"disabled",
|
|
3283
|
+
"required",
|
|
3277
3284
|
"errors",
|
|
3278
3285
|
"instructions",
|
|
3279
3286
|
"form-key"
|
|
3280
3287
|
]));
|
|
3281
3288
|
}
|
|
3282
|
-
}), [["__scopeId", "data-v-
|
|
3289
|
+
}), [["__scopeId", "data-v-da47b274"]]), Oi = { class: "g-date-range-input" }, ki = {
|
|
3283
3290
|
key: 0,
|
|
3284
3291
|
class: "g-date-range-input__label"
|
|
3285
|
-
},
|
|
3292
|
+
}, Ai = {
|
|
3293
|
+
key: 0,
|
|
3294
|
+
class: "g-date-range-input__required",
|
|
3295
|
+
"aria-hidden": "true"
|
|
3296
|
+
}, ji = {
|
|
3286
3297
|
key: 1,
|
|
3287
3298
|
class: "g-date-range-input__instructions"
|
|
3288
|
-
},
|
|
3299
|
+
}, Mi = { class: "g-date-range-input__fields" }, Ni = {
|
|
3289
3300
|
key: 2,
|
|
3290
3301
|
class: "g-date-range-input__errors",
|
|
3291
3302
|
role: "alert"
|
|
3292
|
-
},
|
|
3303
|
+
}, Pi = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3293
3304
|
__name: "GDateRangeInput",
|
|
3294
3305
|
props: /* @__PURE__ */ m({
|
|
3295
3306
|
label: { default: void 0 },
|
|
@@ -3299,6 +3310,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3299
3310
|
type: Boolean,
|
|
3300
3311
|
default: !1
|
|
3301
3312
|
},
|
|
3313
|
+
required: {
|
|
3314
|
+
type: Boolean,
|
|
3315
|
+
default: !1
|
|
3316
|
+
},
|
|
3302
3317
|
errors: { default: () => [] },
|
|
3303
3318
|
instructions: { default: "" },
|
|
3304
3319
|
name: { default: void 0 },
|
|
@@ -3312,50 +3327,54 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3312
3327
|
}),
|
|
3313
3328
|
emits: ["update:modelValue"],
|
|
3314
3329
|
setup(t) {
|
|
3315
|
-
let n = t, r =
|
|
3330
|
+
let n = t, r = z(t, "modelValue"), i = E(r.value.start || null), u = E(r.value.end || null), { displayErrors: d } = $({
|
|
3316
3331
|
name: n.name,
|
|
3317
3332
|
value: r,
|
|
3318
|
-
errors:
|
|
3333
|
+
errors: P(n, "errors"),
|
|
3319
3334
|
formKey: n.formKey
|
|
3320
3335
|
});
|
|
3321
|
-
return
|
|
3336
|
+
return U([i, u], () => {
|
|
3322
3337
|
r.value = {
|
|
3323
3338
|
start: i.value,
|
|
3324
|
-
end:
|
|
3339
|
+
end: u.value
|
|
3325
3340
|
};
|
|
3326
|
-
}),
|
|
3327
|
-
e.start !== i.value && (i.value = e.start), e.end !==
|
|
3328
|
-
}, { deep: !0 }), (t, r) => (C(), o("div",
|
|
3329
|
-
n.label ? (C(), o("div",
|
|
3330
|
-
n.instructions ? (C(), o("div",
|
|
3331
|
-
s("div",
|
|
3341
|
+
}), U(r, (e) => {
|
|
3342
|
+
e.start !== i.value && (i.value = e.start), e.end !== u.value && (u.value = e.end);
|
|
3343
|
+
}, { deep: !0 }), (t, r) => (C(), o("div", Oi, [
|
|
3344
|
+
n.label ? (C(), o("div", ki, [c(M(n.label), 1), n.required ? (C(), o("span", Ai, " *")) : a("", !0)])) : a("", !0),
|
|
3345
|
+
n.instructions ? (C(), o("div", ji, M(n.instructions), 1)) : a("", !0),
|
|
3346
|
+
s("div", Mi, [l(Di, {
|
|
3332
3347
|
modelValue: i.value,
|
|
3333
3348
|
"onUpdate:modelValue": r[0] ||= (e) => i.value = e,
|
|
3334
3349
|
label: n.startLabel,
|
|
3335
3350
|
disabled: n.disabled,
|
|
3351
|
+
required: n.required,
|
|
3336
3352
|
class: "g-date-range-input__field"
|
|
3337
3353
|
}, null, 8, [
|
|
3338
3354
|
"modelValue",
|
|
3339
3355
|
"label",
|
|
3340
|
-
"disabled"
|
|
3341
|
-
|
|
3342
|
-
|
|
3343
|
-
|
|
3356
|
+
"disabled",
|
|
3357
|
+
"required"
|
|
3358
|
+
]), l(Di, {
|
|
3359
|
+
modelValue: u.value,
|
|
3360
|
+
"onUpdate:modelValue": r[1] ||= (e) => u.value = e,
|
|
3344
3361
|
label: n.endLabel,
|
|
3345
3362
|
disabled: n.disabled,
|
|
3363
|
+
required: n.required,
|
|
3346
3364
|
class: "g-date-range-input__field"
|
|
3347
3365
|
}, null, 8, [
|
|
3348
3366
|
"modelValue",
|
|
3349
3367
|
"label",
|
|
3350
|
-
"disabled"
|
|
3368
|
+
"disabled",
|
|
3369
|
+
"required"
|
|
3351
3370
|
])]),
|
|
3352
|
-
|
|
3371
|
+
I(d).length > 0 ? (C(), o("div", Ni, [(C(!0), o(e, null, D(I(d), (e, t) => (C(), o("div", {
|
|
3353
3372
|
key: t,
|
|
3354
3373
|
class: "g-date-range-input__error"
|
|
3355
|
-
},
|
|
3374
|
+
}, M(e), 1))), 128))])) : a("", !0)
|
|
3356
3375
|
]));
|
|
3357
3376
|
}
|
|
3358
|
-
}), [["__scopeId", "data-v-
|
|
3377
|
+
}), [["__scopeId", "data-v-e61c209b"]]), Fi = ["action", "method"], Ii = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3359
3378
|
__name: "GForm",
|
|
3360
3379
|
props: /* @__PURE__ */ m({
|
|
3361
3380
|
action: { default: void 0 },
|
|
@@ -3367,10 +3386,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3367
3386
|
}),
|
|
3368
3387
|
emits: /* @__PURE__ */ m(["submit"], ["update:modelValue"]),
|
|
3369
3388
|
setup(e, { emit: t }) {
|
|
3370
|
-
let n = e, r =
|
|
3371
|
-
a || w("form", s),
|
|
3389
|
+
let n = e, r = z(e, "modelValue"), i = t, a = p("form", null), s = a ?? (de() ? ke(n.formKey) : De());
|
|
3390
|
+
a || w("form", s), U(() => s.values.value, (e) => {
|
|
3372
3391
|
r.value = { ...e };
|
|
3373
|
-
}, { deep: !0 }),
|
|
3392
|
+
}, { deep: !0 }), U(() => r.value, (e) => {
|
|
3374
3393
|
e && Object.entries(e).forEach(([e, t]) => {
|
|
3375
3394
|
let n = s.fields[e];
|
|
3376
3395
|
n && n.value.value !== t && (n.value.value = t);
|
|
@@ -3391,13 +3410,13 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3391
3410
|
class: "g-form",
|
|
3392
3411
|
novalidate: ""
|
|
3393
3412
|
}, [O(e.$slots, "default", {
|
|
3394
|
-
isSubmitting:
|
|
3395
|
-
hasErrors:
|
|
3396
|
-
values:
|
|
3397
|
-
errors:
|
|
3398
|
-
}, void 0, !0)], 40,
|
|
3413
|
+
isSubmitting: I(s).isSubmitting.value,
|
|
3414
|
+
hasErrors: I(s).hasErrors.value,
|
|
3415
|
+
values: I(s).values.value,
|
|
3416
|
+
errors: I(s).errors.value
|
|
3417
|
+
}, void 0, !0)], 40, Fi));
|
|
3399
3418
|
}
|
|
3400
|
-
}), [["__scopeId", "data-v-3f5a6392"]]),
|
|
3419
|
+
}), [["__scopeId", "data-v-3f5a6392"]]), Li = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3401
3420
|
__name: "GSubmitButton",
|
|
3402
3421
|
props: {
|
|
3403
3422
|
disabled: {
|
|
@@ -3409,40 +3428,41 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3409
3428
|
formKey: { default: "default" }
|
|
3410
3429
|
},
|
|
3411
3430
|
setup(e) {
|
|
3412
|
-
let t = e, n =
|
|
3431
|
+
let t = e, n = L(), a = typeof n["form-key"] == "string" ? n["form-key"] : void 0, o = t.formKey || a || "default", l = p("form", null) ?? (de() ? ke(o) : null), u = r(() => t.disabled || (l?.isSubmitting.value ?? !1)), d = r(() => l?.isSubmitting.value ?? !1);
|
|
3413
3432
|
return (e, n) => (C(), i(Z, {
|
|
3414
3433
|
type: "submit",
|
|
3415
3434
|
disabled: u.value,
|
|
3416
3435
|
variant: t.variant,
|
|
3417
3436
|
class: "g-submit-button"
|
|
3418
3437
|
}, {
|
|
3419
|
-
default:
|
|
3438
|
+
default: G(() => [K(s("span", null, M(t.loadingText), 513), [[ee, d.value]]), K(s("span", null, [O(e.$slots, "default", {}, () => [n[0] ||= c("Submit", -1)], !0)], 512), [[ee, !d.value]])]),
|
|
3420
3439
|
_: 3
|
|
3421
3440
|
}, 8, ["disabled", "variant"]));
|
|
3422
3441
|
}
|
|
3423
|
-
}), [["__scopeId", "data-v-053621d8"]]),
|
|
3442
|
+
}), [["__scopeId", "data-v-053621d8"]]), Ri = {
|
|
3424
3443
|
key: 0,
|
|
3425
3444
|
class: "g-checkbox-group__legend"
|
|
3426
|
-
},
|
|
3445
|
+
}, zi = {
|
|
3427
3446
|
key: 0,
|
|
3428
3447
|
class: "g-checkbox-group__required",
|
|
3429
3448
|
"aria-hidden": "true"
|
|
3430
|
-
},
|
|
3449
|
+
}, Bi = {
|
|
3431
3450
|
key: 1,
|
|
3432
3451
|
class: "g-checkbox-group__label"
|
|
3433
|
-
},
|
|
3452
|
+
}, Vi = {
|
|
3434
3453
|
key: 0,
|
|
3435
3454
|
class: "g-checkbox-group__required",
|
|
3436
3455
|
"aria-hidden": "true"
|
|
3437
|
-
},
|
|
3456
|
+
}, Hi = ["id"], Ui = { class: "g-checkbox-group__options" }, Wi = ["for"], Gi = [
|
|
3438
3457
|
"id",
|
|
3439
3458
|
"type",
|
|
3440
3459
|
"name",
|
|
3441
3460
|
"value",
|
|
3442
3461
|
"checked",
|
|
3443
3462
|
"disabled",
|
|
3463
|
+
"required",
|
|
3444
3464
|
"onChange"
|
|
3445
|
-
],
|
|
3465
|
+
], Ki = { class: "g-checkbox-group__label-text" }, qi = ["id"], Ji = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3446
3466
|
__name: "GCheckboxGroup",
|
|
3447
3467
|
props: /* @__PURE__ */ m({
|
|
3448
3468
|
label: { default: void 0 },
|
|
@@ -3465,10 +3485,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3465
3485
|
}),
|
|
3466
3486
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
3467
3487
|
setup(t, { emit: n }) {
|
|
3468
|
-
let u = t, d =
|
|
3488
|
+
let u = t, d = z(t, "modelValue"), f = R(), { displayErrors: p, hasErrors: m } = $({
|
|
3469
3489
|
name: u.name,
|
|
3470
3490
|
value: d,
|
|
3471
|
-
errors:
|
|
3491
|
+
errors: P(u, "errors"),
|
|
3472
3492
|
formKey: u.formKey
|
|
3473
3493
|
}), g = n;
|
|
3474
3494
|
function v(e) {
|
|
@@ -3479,14 +3499,13 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3479
3499
|
n = u.radio ? t ? [e] : [] : t ? d.value.includes(e) ? d.value : [...d.value, e] : d.value.filter((t) => t !== e), d.value = n, g("change", n);
|
|
3480
3500
|
}
|
|
3481
3501
|
let b = r(() => u.radio ? "radio" : "checkbox"), x = r(() => `error-message-${f}`), S = r(() => `instructions-${f}`), w = r(() => u.radio || u.options.length > 1), T = r(() => {
|
|
3482
|
-
if (!u.radio) return {};
|
|
3483
3502
|
let e = [];
|
|
3484
|
-
return u.instructions && e.push(S.value), {
|
|
3503
|
+
return u.instructions && e.push(S.value), u.radio ? {
|
|
3485
3504
|
role: "radiogroup",
|
|
3486
3505
|
"aria-invalid": m.value ? "true" : void 0,
|
|
3487
3506
|
"aria-errormessage": m.value ? x.value : void 0,
|
|
3488
3507
|
"aria-describedby": e.length ? e.join(" ") : void 0
|
|
3489
|
-
};
|
|
3508
|
+
} : { "aria-describedby": e.length ? e.join(" ") : void 0 };
|
|
3490
3509
|
});
|
|
3491
3510
|
function E(e) {
|
|
3492
3511
|
return `${f}-hint-${e}`;
|
|
@@ -3494,23 +3513,24 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3494
3513
|
function O(e) {
|
|
3495
3514
|
return `${f}-input-${e}`;
|
|
3496
3515
|
}
|
|
3497
|
-
function
|
|
3516
|
+
function A(e, t) {
|
|
3498
3517
|
let n = [];
|
|
3499
3518
|
return !u.radio && u.instructions && n.push(S.value), e.hint && n.push(E(t)), u.radio ? { "aria-describedby": n.length ? n.join(" ") : void 0 } : {
|
|
3500
3519
|
"aria-describedby": n.length ? n.join(" ") : void 0,
|
|
3520
|
+
"aria-required": u.required && u.options.length > 1 ? "true" : void 0,
|
|
3501
3521
|
"aria-invalid": m.value ? "true" : "false",
|
|
3502
3522
|
"aria-errormessage": m.value ? x.value : void 0
|
|
3503
3523
|
};
|
|
3504
3524
|
}
|
|
3505
|
-
return (n, r) => (C(), i(
|
|
3506
|
-
default:
|
|
3507
|
-
w.value && t.label ? (C(), o("legend",
|
|
3525
|
+
return (n, r) => (C(), i(k(w.value ? "fieldset" : "div"), h({ class: ["g-checkbox-group", { "g-checkbox-group--error": I(m) }] }, T.value), {
|
|
3526
|
+
default: G(() => [
|
|
3527
|
+
w.value && t.label ? (C(), o("legend", Ri, [c(M(t.label), 1), t.required ? (C(), o("span", zi, "\xA0*")) : a("", !0)])) : !w.value && t.label ? (C(), o("div", Bi, [c(M(t.label), 1), t.required ? (C(), o("span", Vi, "\xA0*")) : a("", !0)])) : a("", !0),
|
|
3508
3528
|
t.instructions ? (C(), o("div", {
|
|
3509
3529
|
key: 2,
|
|
3510
3530
|
id: S.value,
|
|
3511
3531
|
class: "g-checkbox-group__instructions"
|
|
3512
|
-
},
|
|
3513
|
-
s("div",
|
|
3532
|
+
}, M(t.instructions), 9, Hi)) : a("", !0),
|
|
3533
|
+
s("div", Ui, [(C(!0), o(e, null, D(t.options, (e, n) => (C(), o("div", {
|
|
3514
3534
|
key: e.value,
|
|
3515
3535
|
class: _(["g-checkbox-group__option-wrapper", { "g-checkbox-group__option-wrapper--disabled": e.disabled }])
|
|
3516
3536
|
}, [s("label", {
|
|
@@ -3519,41 +3539,43 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3519
3539
|
}, [s("input", h({
|
|
3520
3540
|
id: O(n),
|
|
3521
3541
|
type: b.value,
|
|
3522
|
-
name: t.name ||
|
|
3542
|
+
name: t.name || I(f),
|
|
3523
3543
|
value: e.value,
|
|
3524
3544
|
checked: v(e.value),
|
|
3525
3545
|
disabled: e.disabled,
|
|
3546
|
+
required: t.required && (t.radio && n === 0 || !t.radio && t.options.length === 1),
|
|
3526
3547
|
class: "g-checkbox-group__input"
|
|
3527
|
-
}, { ref_for: !0 },
|
|
3548
|
+
}, { ref_for: !0 }, A(e, n), { onChange: (t) => y(e.value, t.target.checked) }), null, 16, Gi), s("span", Ki, M(e.label), 1)], 10, Wi), e.hint ? (C(), o("div", {
|
|
3528
3549
|
key: 0,
|
|
3529
3550
|
id: E(n),
|
|
3530
3551
|
class: "g-checkbox-group__hint"
|
|
3531
|
-
},
|
|
3532
|
-
l(
|
|
3533
|
-
errors:
|
|
3552
|
+
}, M(e.hint), 9, qi)) : a("", !0)], 2))), 128))]),
|
|
3553
|
+
l(je, {
|
|
3554
|
+
errors: I(p),
|
|
3534
3555
|
id: x.value
|
|
3535
3556
|
}, null, 8, ["errors", "id"])
|
|
3536
3557
|
]),
|
|
3537
3558
|
_: 1
|
|
3538
3559
|
}, 16, ["class"]));
|
|
3539
3560
|
}
|
|
3540
|
-
}), [["__scopeId", "data-v-
|
|
3561
|
+
}), [["__scopeId", "data-v-962dc60c"]]), Yi = ["for"], Xi = {
|
|
3541
3562
|
key: 0,
|
|
3542
3563
|
class: "g-textarea-required",
|
|
3543
3564
|
"aria-hidden": "true"
|
|
3544
|
-
},
|
|
3565
|
+
}, Zi = ["id"], Qi = [
|
|
3545
3566
|
"value",
|
|
3546
3567
|
"placeholder",
|
|
3547
3568
|
"disabled",
|
|
3548
3569
|
"readonly",
|
|
3570
|
+
"required",
|
|
3549
3571
|
"rows",
|
|
3550
3572
|
"maxlength",
|
|
3551
3573
|
"aria-invalid"
|
|
3552
|
-
],
|
|
3574
|
+
], $i = {
|
|
3553
3575
|
key: 2,
|
|
3554
3576
|
class: "g-textarea-char-count",
|
|
3555
3577
|
"aria-live": "polite"
|
|
3556
|
-
},
|
|
3578
|
+
}, ea = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3557
3579
|
inheritAttrs: !1,
|
|
3558
3580
|
__name: "GTextarea",
|
|
3559
3581
|
props: /* @__PURE__ */ m({
|
|
@@ -3587,17 +3609,17 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3587
3609
|
}),
|
|
3588
3610
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
3589
3611
|
setup(e, { emit: t }) {
|
|
3590
|
-
let n = e, i =
|
|
3612
|
+
let n = e, i = z(e, "modelValue"), u = R(), { attrs: d, isCustomElement: f, forwardedAttrs: p } = fe({ omitInCustomElement: ["id"] }), m = r(() => f ? u : d.id || u), { displayErrors: v, hasErrors: y } = $({
|
|
3591
3613
|
name: n.name,
|
|
3592
3614
|
value: i,
|
|
3593
|
-
errors:
|
|
3615
|
+
errors: P(n, "errors"),
|
|
3594
3616
|
formKey: n.formKey
|
|
3595
|
-
}), b = t, x =
|
|
3617
|
+
}), b = t, x = V("textareaEl");
|
|
3596
3618
|
function S() {
|
|
3597
3619
|
let e = x.value;
|
|
3598
3620
|
e && (e.style.height = "auto", e.style.height = `${e.scrollHeight}px`);
|
|
3599
3621
|
}
|
|
3600
|
-
|
|
3622
|
+
U(() => i.value, () => {
|
|
3601
3623
|
n.autoGrow && g(S);
|
|
3602
3624
|
});
|
|
3603
3625
|
function w(e) {
|
|
@@ -3621,50 +3643,54 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3621
3643
|
w(t), n.autoGrow && S();
|
|
3622
3644
|
}, 0);
|
|
3623
3645
|
}
|
|
3624
|
-
return (t, r) => (C(), o("div", { class: _(["g-textarea-wrap", { "g-textarea-has-error":
|
|
3646
|
+
return (t, r) => (C(), o("div", { class: _(["g-textarea-wrap", { "g-textarea-has-error": I(y) }]) }, [
|
|
3625
3647
|
n.label ? (C(), o("label", {
|
|
3626
3648
|
key: 0,
|
|
3627
3649
|
for: m.value,
|
|
3628
3650
|
class: "g-textarea-label"
|
|
3629
|
-
}, [c(
|
|
3651
|
+
}, [c(M(n.label), 1), n.required ? (C(), o("span", Xi, " *")) : a("", !0)], 8, Yi)) : a("", !0),
|
|
3630
3652
|
t.$slots.instructions || e.instructions ? (C(), o("div", {
|
|
3631
3653
|
key: 1,
|
|
3632
|
-
id: "instructions-" +
|
|
3654
|
+
id: "instructions-" + I(u),
|
|
3633
3655
|
class: "g-textarea-instructions"
|
|
3634
|
-
}, [O(t.$slots, "instructions", {}, () => [c(
|
|
3656
|
+
}, [O(t.$slots, "instructions", {}, () => [c(M(e.instructions), 1)], !0)], 8, Zi)) : a("", !0),
|
|
3635
3657
|
s("textarea", h({
|
|
3636
3658
|
ref: "textareaEl",
|
|
3637
3659
|
value: i.value ?? "",
|
|
3638
3660
|
placeholder: n.placeholder,
|
|
3639
3661
|
disabled: n.disabled,
|
|
3640
3662
|
readonly: n.readonly,
|
|
3663
|
+
required: n.required,
|
|
3641
3664
|
rows: n.rows,
|
|
3642
3665
|
maxlength: n.maxlength ?? void 0,
|
|
3643
3666
|
class: "g-textarea"
|
|
3644
3667
|
}, {
|
|
3645
|
-
...
|
|
3668
|
+
...I(p),
|
|
3646
3669
|
id: m.value,
|
|
3647
|
-
"aria-
|
|
3648
|
-
"aria-
|
|
3649
|
-
"aria-errormessage": L(y) ? "error-message-" + L(u) : void 0
|
|
3670
|
+
"aria-describedby": t.$slots.instructions || e.instructions ? "instructions-" + I(u) : void 0,
|
|
3671
|
+
"aria-errormessage": I(y) ? "error-message-" + I(u) : void 0
|
|
3650
3672
|
}, {
|
|
3651
|
-
"aria-invalid":
|
|
3673
|
+
"aria-invalid": I(y) ? "true" : "false",
|
|
3652
3674
|
onInput: T,
|
|
3653
3675
|
onBlur: E,
|
|
3654
3676
|
onPaste: D
|
|
3655
|
-
}), null, 16,
|
|
3656
|
-
n.maxlength === void 0 ? a("", !0) : (C(), o("div",
|
|
3657
|
-
l(
|
|
3658
|
-
errors:
|
|
3659
|
-
id: "error-message-" +
|
|
3677
|
+
}), null, 16, Qi),
|
|
3678
|
+
n.maxlength === void 0 ? a("", !0) : (C(), o("div", $i, M((i.value ?? "").length) + " / " + M(n.maxlength), 1)),
|
|
3679
|
+
l(je, {
|
|
3680
|
+
errors: I(v),
|
|
3681
|
+
id: "error-message-" + I(u)
|
|
3660
3682
|
}, null, 8, ["errors", "id"])
|
|
3661
3683
|
], 2));
|
|
3662
3684
|
}
|
|
3663
|
-
}), [["__scopeId", "data-v-
|
|
3685
|
+
}), [["__scopeId", "data-v-8b09bb96"]]), ta = ["id", "for"], na = {
|
|
3686
|
+
key: 0,
|
|
3687
|
+
class: "g-multiselect-required",
|
|
3688
|
+
"aria-hidden": "true"
|
|
3689
|
+
}, ra = ["id"], ia = ["aria-labelledby"], aa = { class: "g-multiselect-chip-label" }, oa = [
|
|
3664
3690
|
"aria-label",
|
|
3665
3691
|
"disabled",
|
|
3666
3692
|
"onClick"
|
|
3667
|
-
],
|
|
3693
|
+
], sa = [
|
|
3668
3694
|
"id",
|
|
3669
3695
|
"value",
|
|
3670
3696
|
"placeholder",
|
|
@@ -3672,24 +3698,25 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3672
3698
|
"aria-expanded",
|
|
3673
3699
|
"aria-controls",
|
|
3674
3700
|
"aria-activedescendant",
|
|
3675
|
-
"aria-describedby"
|
|
3676
|
-
|
|
3701
|
+
"aria-describedby",
|
|
3702
|
+
"aria-required"
|
|
3703
|
+
], ca = ["id"], la = [
|
|
3677
3704
|
"id",
|
|
3678
3705
|
"aria-selected",
|
|
3679
3706
|
"onClick"
|
|
3680
|
-
],
|
|
3707
|
+
], ua = {
|
|
3681
3708
|
class: "g-multiselect-option-check",
|
|
3682
3709
|
"aria-hidden": "true"
|
|
3683
|
-
},
|
|
3710
|
+
}, da = {
|
|
3684
3711
|
key: 0,
|
|
3685
3712
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3686
3713
|
viewBox: "0 0 640 640",
|
|
3687
3714
|
width: "1.25em"
|
|
3688
|
-
},
|
|
3715
|
+
}, fa = {
|
|
3689
3716
|
key: 1,
|
|
3690
3717
|
"aria-live": "polite",
|
|
3691
3718
|
class: "g-multiselect-option g-multiselect-no-results"
|
|
3692
|
-
},
|
|
3719
|
+
}, pa = /* @__PURE__ */ Q(/* @__PURE__ */ u({
|
|
3693
3720
|
__name: "GMultiSelect",
|
|
3694
3721
|
props: /* @__PURE__ */ m({
|
|
3695
3722
|
options: {},
|
|
@@ -3703,6 +3730,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3703
3730
|
type: Boolean,
|
|
3704
3731
|
default: !1
|
|
3705
3732
|
},
|
|
3733
|
+
required: {
|
|
3734
|
+
type: Boolean,
|
|
3735
|
+
default: !1
|
|
3736
|
+
},
|
|
3706
3737
|
name: {},
|
|
3707
3738
|
errors: { default: () => [] },
|
|
3708
3739
|
instructions: {},
|
|
@@ -3713,27 +3744,27 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3713
3744
|
}),
|
|
3714
3745
|
emits: /* @__PURE__ */ m(["change"], ["update:modelValue"]),
|
|
3715
3746
|
setup(t, { emit: n }) {
|
|
3716
|
-
let i = t, u = n, d =
|
|
3747
|
+
let i = t, u = n, d = z(t, "modelValue"), f = R(), p = E(null), m = E(null), v = E(null), y = E(!1), b = E(0), x = E(""), S = E(!1), { displayErrors: w, hasErrors: T } = $({
|
|
3717
3748
|
name: i.name,
|
|
3718
3749
|
value: d,
|
|
3719
|
-
errors:
|
|
3750
|
+
errors: P(i, "errors"),
|
|
3720
3751
|
formKey: i.formKey
|
|
3721
|
-
}), { menuPlacement: O, menuStyle: k, isTop: A, scrollOptionIntoView: j } =
|
|
3752
|
+
}), { menuPlacement: O, menuStyle: k, isTop: A, scrollOptionIntoView: j } = Mt({
|
|
3722
3753
|
open: y,
|
|
3723
3754
|
anchorRef: m,
|
|
3724
3755
|
listboxRef: v,
|
|
3725
3756
|
baseId: f,
|
|
3726
3757
|
activeIndex: b
|
|
3727
|
-
}),
|
|
3728
|
-
if (!x.value) return
|
|
3758
|
+
}), N = r(() => jt(i.options)), F = r(() => {
|
|
3759
|
+
if (!x.value) return N.value;
|
|
3729
3760
|
let e = x.value.toLowerCase();
|
|
3730
|
-
return
|
|
3761
|
+
return N.value.filter((t) => t.label.toLowerCase().includes(e));
|
|
3731
3762
|
});
|
|
3732
|
-
function
|
|
3763
|
+
function L(e) {
|
|
3733
3764
|
return d.value.includes(e);
|
|
3734
3765
|
}
|
|
3735
|
-
function
|
|
3736
|
-
let t =
|
|
3766
|
+
function B(e) {
|
|
3767
|
+
let t = N.value.find((t) => t.value === e);
|
|
3737
3768
|
return t ? t.label : String(e);
|
|
3738
3769
|
}
|
|
3739
3770
|
function V() {
|
|
@@ -3743,9 +3774,9 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3743
3774
|
y.value = !1, x.value = "";
|
|
3744
3775
|
}
|
|
3745
3776
|
function U(e) {
|
|
3746
|
-
let t =
|
|
3777
|
+
let t = F.value[e];
|
|
3747
3778
|
if (!t) return;
|
|
3748
|
-
let n = d.value, r =
|
|
3779
|
+
let n = d.value, r = L(t.value) ? n.filter((e) => e !== t.value) : [...n, t.value];
|
|
3749
3780
|
d.value = r, u("change", r), g(() => p.value?.focus());
|
|
3750
3781
|
}
|
|
3751
3782
|
function W(e) {
|
|
@@ -3756,7 +3787,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3756
3787
|
function G() {
|
|
3757
3788
|
i.disabled || (p.value?.focus(), y.value || V());
|
|
3758
3789
|
}
|
|
3759
|
-
function
|
|
3790
|
+
function J(e) {
|
|
3760
3791
|
x.value = e.target.value, b.value = 0, y.value || V();
|
|
3761
3792
|
}
|
|
3762
3793
|
function Y() {
|
|
@@ -3778,7 +3809,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3778
3809
|
}
|
|
3779
3810
|
function re(e) {
|
|
3780
3811
|
if (i.disabled) return;
|
|
3781
|
-
let t =
|
|
3812
|
+
let t = F.value.length - 1;
|
|
3782
3813
|
switch (e.key) {
|
|
3783
3814
|
case "ArrowDown":
|
|
3784
3815
|
e.preventDefault(), y.value ? (b.value = Math.min(t, b.value + 1), j()) : V();
|
|
@@ -3793,10 +3824,10 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3793
3824
|
e.preventDefault(), b.value = t, j();
|
|
3794
3825
|
break;
|
|
3795
3826
|
case "Enter":
|
|
3796
|
-
e.preventDefault(), y.value &&
|
|
3827
|
+
e.preventDefault(), y.value && F.value.length > 0 ? U(b.value) : y.value || V();
|
|
3797
3828
|
break;
|
|
3798
3829
|
case " ":
|
|
3799
|
-
y.value && !x.value && (e.preventDefault(),
|
|
3830
|
+
y.value && !x.value && (e.preventDefault(), F.value.length > 0 && U(b.value));
|
|
3800
3831
|
break;
|
|
3801
3832
|
case "Escape":
|
|
3802
3833
|
A.value && (e.preventDefault(), setTimeout(() => H(), 0));
|
|
@@ -3812,19 +3843,19 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3812
3843
|
});
|
|
3813
3844
|
return (n, r) => (C(), o("div", { class: _(["g-multiselect-root", {
|
|
3814
3845
|
"g-multiselect-open": y.value,
|
|
3815
|
-
"g-multiselect-has-error":
|
|
3846
|
+
"g-multiselect-has-error": I(T)
|
|
3816
3847
|
}]) }, [
|
|
3817
3848
|
t.hiddenLabel ? a("", !0) : (C(), o("label", {
|
|
3818
3849
|
key: 0,
|
|
3819
3850
|
id: ae.value,
|
|
3820
3851
|
for: ie.value,
|
|
3821
3852
|
class: "g-multiselect-label"
|
|
3822
|
-
},
|
|
3853
|
+
}, [c(M(t.label), 1), t.required ? (C(), o("span", na, " *")) : a("", !0)], 8, ta)),
|
|
3823
3854
|
t.instructions ? (C(), o("div", {
|
|
3824
3855
|
key: 1,
|
|
3825
3856
|
id: oe.value,
|
|
3826
3857
|
class: "g-multiselect-instructions"
|
|
3827
|
-
},
|
|
3858
|
+
}, M(t.instructions), 9, ra)) : a("", !0),
|
|
3828
3859
|
s("div", {
|
|
3829
3860
|
ref_key: "controlRef",
|
|
3830
3861
|
ref: m,
|
|
@@ -3837,13 +3868,13 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3837
3868
|
}, [(C(!0), o(e, null, D(d.value, (e) => (C(), o("li", {
|
|
3838
3869
|
key: e,
|
|
3839
3870
|
class: "g-multiselect-chip"
|
|
3840
|
-
}, [s("span",
|
|
3871
|
+
}, [s("span", aa, M(B(e)), 1), s("button", {
|
|
3841
3872
|
type: "button",
|
|
3842
3873
|
class: "g-multiselect-chip-remove",
|
|
3843
|
-
"aria-label": `Remove ${
|
|
3874
|
+
"aria-label": `Remove ${B(e)}`,
|
|
3844
3875
|
disabled: t.disabled,
|
|
3845
3876
|
onMousedown: ne,
|
|
3846
|
-
onClick:
|
|
3877
|
+
onClick: q((t) => W(e), ["stop"])
|
|
3847
3878
|
}, [...r[0] ||= [s("svg", {
|
|
3848
3879
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3849
3880
|
viewBox: "0 0 51.26 51.26",
|
|
@@ -3852,7 +3883,7 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3852
3883
|
}, [s("path", {
|
|
3853
3884
|
fill: "currentColor",
|
|
3854
3885
|
d: "m37.84 32.94-7.63-7.63 7.63-7.63a3.24 3.24 0 0 0-4.58-4.58l-7.63 7.63L18 13.1a3.24 3.24 0 0 0-4.58 4.58L21 25.31l-7.62 7.63A3.24 3.24 0 1 0 18 37.52l7.63-7.63 7.63 7.63a3.24 3.24 0 0 0 4.58-4.58Z"
|
|
3855
|
-
})], -1)]], 40,
|
|
3886
|
+
})], -1)]], 40, oa)]))), 128))], 8, ia),
|
|
3856
3887
|
s("input", h({
|
|
3857
3888
|
ref_key: "inputRef",
|
|
3858
3889
|
ref: p,
|
|
@@ -3867,15 +3898,16 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3867
3898
|
"aria-autocomplete": "list",
|
|
3868
3899
|
"aria-expanded": y.value ? "true" : "false",
|
|
3869
3900
|
"aria-haspopup": "listbox",
|
|
3870
|
-
"aria-controls":
|
|
3871
|
-
"aria-activedescendant": y.value &&
|
|
3901
|
+
"aria-controls": I(f) + "-listbox",
|
|
3902
|
+
"aria-activedescendant": y.value && F.value.length > 0 ? I(f) + "-option-" + b.value : void 0
|
|
3872
3903
|
}, t.hiddenLabel ? { "aria-label": t.label } : void 0, {
|
|
3873
3904
|
"aria-describedby": ce.value,
|
|
3874
|
-
|
|
3905
|
+
"aria-required": t.required ? "true" : void 0,
|
|
3906
|
+
onInput: J,
|
|
3875
3907
|
onKeydown: re,
|
|
3876
3908
|
onFocus: Y,
|
|
3877
3909
|
onBlur: te
|
|
3878
|
-
}), null, 16,
|
|
3910
|
+
}), null, 16, sa),
|
|
3879
3911
|
r[2] ||= s("svg", {
|
|
3880
3912
|
class: "g-multiselect-caret",
|
|
3881
3913
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -3886,50 +3918,50 @@ var ir = { class: "g-table-outer-wrap" }, ar = {
|
|
|
3886
3918
|
fill: "currentColor",
|
|
3887
3919
|
d: "M38.75 24.13a1.36 1.36 0 0 1 0 2.36l-12.44 7.18-12.43 7.18a1.36 1.36 0 0 1-2.05-1.18V11a1.36 1.36 0 0 1 2.05-1.18L26.31 17Z"
|
|
3888
3920
|
})], -1),
|
|
3889
|
-
|
|
3921
|
+
K(s("div", h({
|
|
3890
3922
|
ref_key: "listboxRef",
|
|
3891
3923
|
ref: v,
|
|
3892
|
-
id:
|
|
3924
|
+
id: I(f) + "-listbox",
|
|
3893
3925
|
role: "listbox",
|
|
3894
3926
|
"aria-multiselectable": "true"
|
|
3895
3927
|
}, t.hiddenLabel ? { "aria-label": t.label } : { "aria-labelledby": ae.value }, {
|
|
3896
|
-
class: ["g-multiselect-listbox", { "g-multiselect-listbox--above":
|
|
3897
|
-
style:
|
|
3928
|
+
class: ["g-multiselect-listbox", { "g-multiselect-listbox--above": I(O) === "above" }],
|
|
3929
|
+
style: I(k),
|
|
3898
3930
|
tabindex: "-1"
|
|
3899
|
-
}), [
|
|
3931
|
+
}), [F.value.length > 0 ? (C(!0), o(e, { key: 0 }, D(F.value, (e, t) => (C(), o("div", {
|
|
3900
3932
|
key: e.value,
|
|
3901
|
-
id:
|
|
3933
|
+
id: I(f) + "-option-" + t,
|
|
3902
3934
|
role: "option",
|
|
3903
3935
|
class: _(["g-multiselect-option", {
|
|
3904
3936
|
"g-multiselect-option--active": t === b.value,
|
|
3905
|
-
"g-multiselect-option--selected":
|
|
3937
|
+
"g-multiselect-option--selected": L(e.value)
|
|
3906
3938
|
}]),
|
|
3907
|
-
"aria-selected":
|
|
3939
|
+
"aria-selected": L(e.value) ? "true" : "false",
|
|
3908
3940
|
onMousedown: X,
|
|
3909
3941
|
onClick: (e) => U(t)
|
|
3910
|
-
}, [s("span",
|
|
3942
|
+
}, [s("span", ua, [L(e.value) ? (C(), o("svg", da, [...r[1] ||= [s("path", { d: "M530.8 134.1C545.1 144.5 548.3 164.5 537.9 178.8L281.9 530.8C276.4 538.4 267.9 543.1 258.5 543.9C249.1 544.7 240 541.2 233.4 534.6L105.4 406.6C92.9 394.1 92.9 373.8 105.4 361.3C117.9 348.8 138.2 348.8 150.7 361.3L252.2 462.8L486.2 141.1C496.6 126.8 516.6 123.6 530.9 134z" }, null, -1)]])) : a("", !0)]), c(" " + M(e.label), 1)], 42, la))), 128)) : (C(), o("div", fa, " No results found. "))], 16, ca), [[ee, y.value]])
|
|
3911
3943
|
], 2),
|
|
3912
|
-
l(
|
|
3913
|
-
errors:
|
|
3944
|
+
l(je, {
|
|
3945
|
+
errors: I(w),
|
|
3914
3946
|
id: se.value
|
|
3915
3947
|
}, null, 8, ["errors", "id"])
|
|
3916
3948
|
], 2));
|
|
3917
3949
|
}
|
|
3918
|
-
}), [["__scopeId", "data-v-
|
|
3950
|
+
}), [["__scopeId", "data-v-70907e93"]]);
|
|
3919
3951
|
//#endregion
|
|
3920
3952
|
//#region src/compose/useActiveLink.ts
|
|
3921
|
-
function
|
|
3953
|
+
function ma(e, t, n) {
|
|
3922
3954
|
let r = [
|
|
3923
3955
|
0,
|
|
3924
3956
|
.25,
|
|
3925
3957
|
.5,
|
|
3926
3958
|
.75,
|
|
3927
3959
|
1
|
|
3928
|
-
], i = `${-t}px 0px 0px 0px`, a = /* @__PURE__ */ new Map(), o = E(Array.from(
|
|
3929
|
-
|
|
3930
|
-
o.value = Array.from(
|
|
3960
|
+
], i = `${-t}px 0px 0px 0px`, a = /* @__PURE__ */ new Map(), o = E(Array.from(X(e)?.children || []));
|
|
3961
|
+
se(e, () => {
|
|
3962
|
+
o.value = Array.from(X(e)?.children || []);
|
|
3931
3963
|
}, { childList: !0 });
|
|
3932
|
-
let { stop: s } =
|
|
3964
|
+
let { stop: s } = ae(o, (e) => {
|
|
3933
3965
|
let t = o.value[o.value.length - 1];
|
|
3934
3966
|
for (let n of e) a.set(n.target, n.isIntersecting ? Math.ceil(100 * n.intersectionRatio) / 100 : 0), n.target === t && n.intersectionRatio === 1 && a.set(n.target, Infinity);
|
|
3935
3967
|
let r = null, i = 0;
|
|
@@ -3948,8 +3980,8 @@ function ua(e, t, n) {
|
|
|
3948
3980
|
}
|
|
3949
3981
|
//#endregion
|
|
3950
3982
|
//#region src/compose/useSidebar.ts
|
|
3951
|
-
function
|
|
3952
|
-
let t =
|
|
3983
|
+
function ha(e = "(max-width: 800px)") {
|
|
3984
|
+
let t = R(), n = E(!1), r = oe(e, { ssrWidth: 1e3 });
|
|
3953
3985
|
function i(e) {
|
|
3954
3986
|
if (!r.value || !n.value) return;
|
|
3955
3987
|
let i = e.target, a = document.getElementById(`${t}-sidebar`);
|
|
@@ -3965,7 +3997,7 @@ function da(e = "(max-width: 800px)") {
|
|
|
3965
3997
|
}, 5));
|
|
3966
3998
|
}
|
|
3967
3999
|
return S(() => {
|
|
3968
|
-
|
|
4000
|
+
U(r, (e) => {
|
|
3969
4001
|
e ? (document.addEventListener("mousedown", i), document.addEventListener("focusin", a)) : (document.removeEventListener("mousedown", i), document.removeEventListener("focusin", a));
|
|
3970
4002
|
}, { immediate: !0 });
|
|
3971
4003
|
}), x(() => {
|
|
@@ -3979,10 +4011,10 @@ function da(e = "(max-width: 800px)") {
|
|
|
3979
4011
|
}
|
|
3980
4012
|
//#endregion
|
|
3981
4013
|
//#region src/compose/useTableChanges.ts
|
|
3982
|
-
function
|
|
3983
|
-
let e =
|
|
4014
|
+
function ga() {
|
|
4015
|
+
let e = A(/* @__PURE__ */ new Map()), t = J(), n = (n) => {
|
|
3984
4016
|
let r = n.column.key, i = n.row.key, a = n.value, o = n.previousValue;
|
|
3985
|
-
e.has(i) || e.set(i,
|
|
4017
|
+
e.has(i) || e.set(i, A(/* @__PURE__ */ new Map()));
|
|
3986
4018
|
let s = e.get(i), c = s.get(r), l = c ? c.previousValue : o, u = c?.error;
|
|
3987
4019
|
if (a === l) s.delete(r), s.size === 0 && e.delete(i), t.trigger({
|
|
3988
4020
|
rowKey: i,
|
|
@@ -4082,6 +4114,6 @@ function fa() {
|
|
|
4082
4114
|
};
|
|
4083
4115
|
}
|
|
4084
4116
|
//#endregion
|
|
4085
|
-
export {
|
|
4117
|
+
export { ke as $, $n as A, Ht as B, Pr as C, tr as D, rr as E, hn as F, it as G, wt as H, dn as I, Qe as J, et as K, ln as L, Cn as M, vn as N, ir as O, gn as P, $ as Q, on as R, Ur as S, er as T, yt as U, At as V, ft as W, qe as X, Ke as Y, Re as Z, ii as _, ea as a, Zr as b, Ii as c, Ei as d, De as et, yi as f, ci as g, fi as h, pa as i, Z as it, Rn as j, ar as k, Pi as l, _i as m, ha as n, ye as nt, Ji as o, vi as p, $e as q, ma as r, ve as rt, Li as s, ga as t, Ee as tt, Di as u, ni as v, nr as w, Yr as x, Qr as y, Qt as z };
|
|
4086
4118
|
|
|
4087
|
-
//# sourceMappingURL=grad-vue-
|
|
4119
|
+
//# sourceMappingURL=grad-vue-DCHrrEXb.js.map
|