@kong-ui-public/app-layout 4.4.4-pr.2098.c450e4c49.0 → 4.4.5

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.
Files changed (38) hide show
  1. package/dist/app-layout.es.js +2191 -0
  2. package/dist/app-layout.umd.js +11 -0
  3. package/dist/style.css +1 -0
  4. package/dist/types/components/AppLayout.vue.d.ts +103 -0
  5. package/dist/types/components/AppLayout.vue.d.ts.map +1 -0
  6. package/dist/types/components/aboutSection/AppAboutSection.vue.d.ts +44 -0
  7. package/dist/types/components/aboutSection/AppAboutSection.vue.d.ts.map +1 -0
  8. package/dist/types/components/errors/AppError.vue.d.ts +17 -0
  9. package/dist/types/components/errors/AppError.vue.d.ts.map +1 -0
  10. package/dist/types/components/icons/BananaSplit.vue.d.ts +3 -0
  11. package/dist/types/components/icons/BananaSplit.vue.d.ts.map +1 -0
  12. package/dist/types/components/navbar/AccountDropdown.vue.d.ts +53 -0
  13. package/dist/types/components/navbar/AccountDropdown.vue.d.ts.map +1 -0
  14. package/dist/types/components/navbar/AppNavbar.vue.d.ts +52 -0
  15. package/dist/types/components/navbar/AppNavbar.vue.d.ts.map +1 -0
  16. package/dist/types/components/pageHeader/AppPageHeader.vue.d.ts +43 -0
  17. package/dist/types/components/pageHeader/AppPageHeader.vue.d.ts.map +1 -0
  18. package/dist/types/components/pageInfoSection/AppPageInfoSection.vue.d.ts +62 -0
  19. package/dist/types/components/pageInfoSection/AppPageInfoSection.vue.d.ts.map +1 -0
  20. package/dist/types/components/sidebar/AppSidebar.vue.d.ts +260 -0
  21. package/dist/types/components/sidebar/AppSidebar.vue.d.ts.map +1 -0
  22. package/dist/types/components/sidebar/ItemBadge.vue.d.ts +17 -0
  23. package/dist/types/components/sidebar/ItemBadge.vue.d.ts.map +1 -0
  24. package/dist/types/components/sidebar/SidebarItem.vue.d.ts +43 -0
  25. package/dist/types/components/sidebar/SidebarItem.vue.d.ts.map +1 -0
  26. package/dist/types/components/sidebar/SidebarToggle.vue.d.ts +19 -0
  27. package/dist/types/components/sidebar/SidebarToggle.vue.d.ts.map +1 -0
  28. package/dist/types/composables/index.d.ts +2 -0
  29. package/dist/types/composables/index.d.ts.map +1 -0
  30. package/dist/types/composables/useDebounce.d.ts +4 -0
  31. package/dist/types/composables/useDebounce.d.ts.map +1 -0
  32. package/dist/types/index.d.ts +20 -0
  33. package/dist/types/index.d.ts.map +1 -0
  34. package/dist/types/types/index.d.ts +2 -0
  35. package/dist/types/types/index.d.ts.map +1 -0
  36. package/dist/types/types/sidebar.d.ts +29 -0
  37. package/dist/types/types/sidebar.d.ts.map +1 -0
  38. package/package.json +4 -4
@@ -0,0 +1,2191 @@
1
+ import { defineComponent as J, resolveComponent as pe, openBlock as p, createBlock as K, withCtx as D, renderSlot as T, createElementBlock as y, Fragment as Ce, renderList as Te, normalizeClass as ie, createTextVNode as Ne, toDisplayString as q, computed as k, createSlots as Ue, createVNode as Ae, createCommentVNode as S, createElementVNode as I, createStaticVNode as pn, useCssVars as ft, useSlots as Xe, reactive as Ke, onMounted as Ye, resolveDynamicComponent as He, withKeys as hn, ref as G, watch as Fe, onUnmounted as mn, Comment as gn, cloneVNode as yn, nextTick as Bt, onBeforeUnmount as Ut, unref as Wt, withModifiers as wn, watchEffect as kn, toRef as Tn } from "vue";
2
+ import { ChevronRightIcon as _n } from "@kong/icons";
3
+ import { HeaderTags as Sn } from "@kong/kongponents";
4
+ const In = /* @__PURE__ */ J({
5
+ __name: "AccountDropdown",
6
+ props: {
7
+ options: {
8
+ type: Array,
9
+ required: !0
10
+ },
11
+ width: {
12
+ type: String,
13
+ default: "240"
14
+ },
15
+ userInitials: {
16
+ type: String,
17
+ required: !0,
18
+ // Important: default to a string with a single empty space to force the dropdown to always be visible
19
+ default: " "
20
+ }
21
+ },
22
+ setup(n) {
23
+ return (t, i) => {
24
+ const a = pe("KDropdownItem"), c = pe("KDropdown");
25
+ return p(), K(c, {
26
+ class: "account-dropdown",
27
+ "kpop-attributes": { placement: "bottom-end" },
28
+ "trigger-text": n.userInitials,
29
+ width: n.width
30
+ }, {
31
+ items: D(({ handleSelection: u }) => [
32
+ T(t.$slots, "default", {}, () => [
33
+ (p(!0), y(Ce, null, Te(n.options, (o) => (p(), K(a, {
34
+ key: o.value,
35
+ class: ie({ "has-divider": o.hasDivider }),
36
+ "data-testid": "select-" + o.value,
37
+ "has-divider": o.hasDivider,
38
+ onClick: (v) => u(o)
39
+ }, {
40
+ default: D(() => [
41
+ T(t.$slots, "default", { option: o }, () => [
42
+ Ne(q(o.label), 1)
43
+ ], !0)
44
+ ]),
45
+ _: 2
46
+ }, 1032, ["class", "data-testid", "has-divider", "onClick"]))), 128))
47
+ ], !0)
48
+ ]),
49
+ _: 3
50
+ }, 8, ["trigger-text", "width"]);
51
+ };
52
+ }
53
+ }), Q = (n, t) => {
54
+ const i = n.__vccOpts || n;
55
+ for (const [a, c] of t)
56
+ i[a] = c;
57
+ return i;
58
+ }, xr = /* @__PURE__ */ Q(In, [["__scopeId", "data-v-b33191a2"]]), On = {
59
+ class: "about-section-title",
60
+ "data-testid": "about-section-title"
61
+ }, $n = { class: "about-section-header-end" }, Cn = {
62
+ key: 0,
63
+ class: "about-section-timestamps-created",
64
+ "data-testid": "about-section-timestamps-created"
65
+ }, En = {
66
+ key: 1,
67
+ class: "about-section-timestamps-arrow"
68
+ }, Nn = {
69
+ key: 2,
70
+ class: "about-section-timestamps-modified",
71
+ "data-testid": "about-section-timestamps-modified"
72
+ }, An = {
73
+ key: 1,
74
+ class: "about-section-actions",
75
+ "data-testid": "about-section-actions"
76
+ }, Fn = {
77
+ key: 0,
78
+ "data-testid": "about-section-loading-skeleton"
79
+ }, Dn = { key: 1 }, Rn = {
80
+ key: 0,
81
+ class: "about-section-description",
82
+ "data-testid": "about-section-description"
83
+ }, xn = {
84
+ key: 1,
85
+ class: "about-section-content",
86
+ "data-testid": "about-section-content"
87
+ }, Bn = {
88
+ key: 2,
89
+ "data-testid": "about-divider-section-separator"
90
+ }, Ln = {
91
+ key: 3,
92
+ class: "about-divider-section",
93
+ "data-testid": "about-divider-section"
94
+ }, Pn = /* @__PURE__ */ J({
95
+ __name: "AppAboutSection",
96
+ props: {
97
+ title: { default: "" },
98
+ description: { default: "" },
99
+ created: { default: "" },
100
+ createdLabel: { default: "Created" },
101
+ modified: { default: "" },
102
+ modifiedLabel: { default: "Modified" },
103
+ isLoading: { type: Boolean, default: !1 }
104
+ },
105
+ setup(n) {
106
+ const t = n, i = k(() => !!t.modified && t.modified !== t.created);
107
+ return (a, c) => {
108
+ const u = pe("KSkeletonBox"), o = pe("KCard");
109
+ return p(), K(o, {
110
+ class: "kong-ui-app-about-section",
111
+ "title-tag": "h2"
112
+ }, Ue({
113
+ default: D(() => [
114
+ a.isLoading ? (p(), y("div", Fn, [
115
+ Ae(u, {
116
+ height: "2",
117
+ width: "100"
118
+ }),
119
+ Ae(u, {
120
+ height: "2",
121
+ width: "100"
122
+ })
123
+ ])) : (p(), y("div", Dn, [
124
+ a.description ? (p(), y("p", Rn, q(a.description), 1)) : S("", !0),
125
+ a.$slots.default ? (p(), y("div", xn, [
126
+ T(a.$slots, "default", {}, void 0, !0)
127
+ ])) : S("", !0),
128
+ a.$slots["divider-section"] ? (p(), y("hr", Bn)) : S("", !0),
129
+ a.$slots["divider-section"] ? (p(), y("div", Ln, [
130
+ T(a.$slots, "divider-section", {}, void 0, !0)
131
+ ])) : S("", !0)
132
+ ]))
133
+ ]),
134
+ _: 2
135
+ }, [
136
+ a.$slots.title || a.title ? {
137
+ name: "title",
138
+ fn: D(() => [
139
+ I("span", On, [
140
+ T(a.$slots, "title", {}, () => [
141
+ Ne(q(a.title), 1)
142
+ ], !0)
143
+ ])
144
+ ]),
145
+ key: "0"
146
+ } : void 0,
147
+ a.$slots.actions || a.created || a.modified ? {
148
+ name: "actions",
149
+ fn: D(() => [
150
+ I("div", $n, [
151
+ a.created || a.modified ? (p(), y("div", {
152
+ key: 0,
153
+ class: ie(["about-section-timestamps", { "has-actions": a.$slots.actions }])
154
+ }, [
155
+ a.created ? (p(), y("span", Cn, q(a.createdLabel) + ": " + q(a.created), 1)) : S("", !0),
156
+ a.created && i.value ? (p(), y("span", En, "->")) : S("", !0),
157
+ i.value ? (p(), y("span", Nn, q(a.modifiedLabel) + ": " + q(a.modified), 1)) : S("", !0)
158
+ ], 2)) : S("", !0),
159
+ a.$slots.actions ? (p(), y("div", An, [
160
+ T(a.$slots, "actions", {}, void 0, !0)
161
+ ])) : S("", !0)
162
+ ])
163
+ ]),
164
+ key: "1"
165
+ } : void 0
166
+ ]), 1024);
167
+ };
168
+ }
169
+ }), Br = /* @__PURE__ */ Q(Pn, [["__scopeId", "data-v-f5864a9c"]]), Mn = {}, jn = {
170
+ fill: "none",
171
+ height: "130",
172
+ width: "130",
173
+ xmlns: "http://www.w3.org/2000/svg"
174
+ };
175
+ function Zn(n, t) {
176
+ return p(), y("svg", jn, t[0] || (t[0] = [
177
+ pn('<path clip-rule="evenodd" d="M19.111 120.198c-.226 0-.409-.164-.409-.368v-4.812c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.812c0 .204-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.368v-4.813c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.368v-4.813c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.226 0-.409-.165-.409-.368v-4.812c0-.204.183-.368.409-.368.226 0 .409.164.409.368v4.812c0 .204-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.368v-4.813c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.226 0-.409-.164-.409-.367V66.89c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.368v-4.813c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.368V47.64c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.226 0-.409-.164-.409-.368v-4.812c0-.204.183-.368.409-.368.226 0 .409.164.409.368v4.812c0 .204-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.368v-4.813c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.226 0-.409-.165-.409-.369v-4.812c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.226 0-.409-.165-.409-.368V9.138c0-.203.183-.368.409-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368ZM110.889 120.198c-.225 0-.408-.164-.408-.368v-4.812c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.812c0 .204-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.368v-4.813c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.368v-4.813c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.225 0-.408-.165-.408-.368v-4.812c0-.204.183-.368.408-.368.226 0 .409.164.409.368v4.812c0 .204-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.368v-4.813c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.225 0-.408-.164-.408-.367V66.89c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.368v-4.813c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.368V47.64c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.225 0-.408-.164-.408-.368v-4.812c0-.204.183-.368.408-.368.226 0 .409.164.409.368v4.812c0 .204-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.368v-4.813c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.625c-.225 0-.408-.165-.408-.369v-4.812c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Zm0-9.626c-.225 0-.408-.165-.408-.368V9.138c0-.203.183-.368.408-.368.226 0 .409.165.409.368v4.813c0 .203-.183.368-.409.368Z" fill="#D6D6D6" fill-rule="evenodd"></path><path clip-rule="evenodd" d="M123.553 107.758a.399.399 0 0 1-.388.408h-5.068a.398.398 0 0 1-.387-.408c0-.226.173-.409.387-.409h5.068c.214 0 .388.183.388.409Zm-10.136 0a.398.398 0 0 1-.387.408h-5.068a.399.399 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .387.183.387.409Zm-10.136 0a.398.398 0 0 1-.387.408h-5.068a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .387.183.387.409Zm-10.136 0a.398.398 0 0 1-.387.408H87.69a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .387.183.387.409Zm-10.136 0a.398.398 0 0 1-.387.408h-5.068a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .387.183.387.409Zm-10.135 0a.398.398 0 0 1-.388.408h-5.068a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .388.183.388.409Zm-10.136 0a.398.398 0 0 1-.388.408h-5.068a.398.398 0 0 1-.387-.408c0-.226.173-.409.387-.409h5.068c.214 0 .388.183.388.409Zm-10.136 0a.398.398 0 0 1-.388.408h-5.068a.398.398 0 0 1-.387-.408c0-.226.173-.409.387-.409h5.068c.214 0 .388.183.388.409Zm-10.136 0a.398.398 0 0 1-.388.408H37.01a.398.398 0 0 1-.387-.408c0-.226.173-.409.387-.409h5.068c.214 0 .388.183.388.409Zm-10.136 0a.398.398 0 0 1-.388.408h-5.067a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.067c.215 0 .388.183.388.409Zm-10.136 0a.398.398 0 0 1-.387.408h-5.068a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .387.183.387.409Zm-10.136 0a.398.398 0 0 1-.387.408H6.603a.398.398 0 0 1-.388-.408c0-.226.174-.409.388-.409h5.068c.214 0 .387.183.387.409ZM123.553 21.434a.399.399 0 0 1-.388.409h-5.068a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.399.399 0 0 1-.388.409h-5.068a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.398.398 0 0 1-.387.409h-5.068a.399.399 0 0 1-.388-.409c0-.226.174-.408.388-.408h5.068c.214 0 .387.183.387.408Zm-10.136 0a.398.398 0 0 1-.387.409H87.69a.398.398 0 0 1-.388-.409c0-.226.174-.408.388-.408h5.068c.214 0 .387.183.387.408Zm-10.136 0a.398.398 0 0 1-.387.409h-5.068a.398.398 0 0 1-.388-.409c0-.226.174-.408.388-.408h5.068c.214 0 .387.183.387.408Zm-10.136 0a.398.398 0 0 1-.387.409h-5.068a.398.398 0 0 1-.388-.409c0-.226.174-.408.388-.408h5.068c.214 0 .387.183.387.408Zm-10.135 0a.399.399 0 0 1-.388.409h-5.068a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.398.398 0 0 1-.388.409h-5.068a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.398.398 0 0 1-.388.409H37.01a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.398.398 0 0 1-.388.409h-5.068a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.398.398 0 0 1-.388.409h-5.068a.398.398 0 0 1-.387-.409c0-.226.173-.408.387-.408h5.068c.214 0 .388.183.388.408Zm-10.136 0a.398.398 0 0 1-.387.409H6.603a.398.398 0 0 1-.388-.409c0-.226.174-.408.388-.408h5.068c.214 0 .387.183.387.408Z" fill="#D6D6D6" fill-rule="evenodd"></path><circle cx="65" cy="65" opacity=".5" r="64" stroke="#B6B6BD" stroke-dasharray="5.69 5.69" stroke-linecap="round" stroke-width=".854"></circle><g clip-path="url(#a)" stroke="#169FCC" stroke-miterlimit="10" stroke-width="1.42"><path d="m33.523 104.868-5.72-.695a1.214 1.214 0 0 1-.766-.386 1.182 1.182 0 0 1-.312-.788v-7.448c0-.095.038-.186.106-.253a.365.365 0 0 1 .256-.104l5.254-.263M61.471 22.733a1.761 1.761 0 0 1 1.45.235 49.628 49.628 0 0 1 15.613 17.6 48.797 48.797 0 0 1 5.65 22.702 47.236 47.236 0 0 1-.333 5.325 41.34 41.34 0 0 0-12.501-.441 48.503 48.503 0 0 0-1.813-23.734 49.117 49.117 0 0 0-12.91-20.119c1.602-.591 3.223-1.136 4.844-1.568Z"></path><path d="M71.35 68.154a39.493 39.493 0 0 0-10.813 3.757 51.298 51.298 0 0 0 3.251-18.062c0-9.392-4.939-19.179-9.783-27.237-.257-.432 0-1.616 2.642-2.32"></path><path d="M56.236 78.58a13.605 13.605 0 0 0-4.29-9.289 14.017 14.017 0 0 0-9.622-3.786 9.617 9.617 0 0 1-6.456-2.446 9.341 9.341 0 0 1-3.079-6.1l-.286-4.256c3.09 0 9.46 4.105 13.216 4.866 3.757.76 8.21.253 11.862 3.437a13.303 13.303 0 0 1 4.357 6.575"></path><path d="M68.594 75.442c-3.432 6.95-7.914 11.59-14.303 16.033a47.076 47.076 0 0 1-21.702 8.058v-4.696c11.642-4.809 22.208-11.806 27.948-22.88"></path><path d="M76.499 84.815a46.939 46.939 0 0 1-17.392 14.511 50.925 50.925 0 0 1-22.885 5.457c-2.317 0-3.662.47-3.662-.695v-4.555"></path><path d="M83.85 68.595c22.304 16.22 4.044 39.25-19.652 37.663.954-.939 29.95-22.222-3.661-34.3"></path><path d="M84.184 58.47c13.607 0 25.746 26.242 17.383 30.995-1.182-17.508-17.716-20.87-17.716-20.87"></path></g><defs><clipPath id="a"><path d="M0 0h79v85H0z" fill="#fff" transform="translate(26 22)"></path></clipPath></defs>', 5)
178
+ ]));
179
+ }
180
+ const Kn = /* @__PURE__ */ Q(Mn, [["render", Zn]]), Hn = { class: "kong-ui-app-error" }, Un = { class: "banana-icon" }, Wn = { class: "kong-ui-app-error-content" }, zn = /* @__PURE__ */ J({
181
+ __name: "AppError",
182
+ setup(n) {
183
+ return (t, i) => (p(), y("section", Hn, [
184
+ I("div", Un, [
185
+ Ae(Kn)
186
+ ]),
187
+ I("div", Wn, [
188
+ T(t.$slots, "default", {}, () => [
189
+ i[0] || (i[0] = I("h2", null, "An unexpected error has occurred", -1)),
190
+ i[1] || (i[1] = I("p", null, [
191
+ Ne("Go back to the previous page or "),
192
+ I("a", { href: "/" }, "return home"),
193
+ Ne(".")
194
+ ], -1))
195
+ ], !0)
196
+ ])
197
+ ]));
198
+ }
199
+ }), Lr = /* @__PURE__ */ Q(zn, [["__scopeId", "data-v-b6d8dc55"]]), Vn = { class: "kong-ui-app-navbar" }, Gn = { class: "header-content" }, qn = { class: "mobile-header-left" }, Xn = {
200
+ key: 0,
201
+ class: "app-navbar-logo"
202
+ }, Yn = { class: "navbar-content" }, Jn = { class: "navbar-content-left" }, Qn = { class: "navbar-content-center" }, ei = { class: "navbar-content-right" }, ti = /* @__PURE__ */ J({
203
+ __name: "AppNavbar",
204
+ props: {
205
+ topOffset: {
206
+ type: Number,
207
+ default: 0
208
+ },
209
+ leftOffset: {
210
+ type: Number,
211
+ default: 240
212
+ // Defaults to the width of AppSidebar.vue
213
+ },
214
+ zIndex: {
215
+ type: Number,
216
+ default: 3
217
+ }
218
+ },
219
+ setup(n) {
220
+ ft((o) => ({
221
+ "27c93a10": u.value.top,
222
+ "0f284bf5": u.value.zIndex,
223
+ d1659a78: u.value.left,
224
+ "3d9232e8": c.marginRight,
225
+ "038c3c78": c.width
226
+ }));
227
+ const t = n, i = Xe(), a = k(() => !!i.logo), c = Ke({
228
+ marginRight: "0",
229
+ width: "0"
230
+ });
231
+ Ye(() => {
232
+ var o, v;
233
+ (v = (o = document == null ? void 0 : document.querySelector(".kong-ui-app-navbar .app-navbar-logo")) == null ? void 0 : o.children) != null && v.length ? (c.marginRight = "32px", c.width = "calc(240px - 32px)") : (c.marginRight = "0", c.width = "0");
234
+ });
235
+ const u = k(() => ({
236
+ top: t.topOffset ? `${t.topOffset}px` : "0",
237
+ left: t.leftOffset ? `${t.leftOffset}px` : "0",
238
+ zIndex: t.zIndex
239
+ }));
240
+ return (o, v) => (p(), y("header", Vn, [
241
+ I("div", Gn, [
242
+ I("div", qn, [
243
+ T(o.$slots, "mobile-sidebar-toggle"),
244
+ T(o.$slots, "mobile-logo")
245
+ ]),
246
+ a.value ? (p(), y("div", Xn, [
247
+ T(o.$slots, "logo")
248
+ ])) : S("", !0),
249
+ I("div", Yn, [
250
+ I("div", Jn, [
251
+ T(o.$slots, "left")
252
+ ]),
253
+ I("div", Qn, [
254
+ T(o.$slots, "center")
255
+ ]),
256
+ I("div", ei, [
257
+ T(o.$slots, "right")
258
+ ])
259
+ ])
260
+ ])
261
+ ]));
262
+ }
263
+ }), ai = /* @__PURE__ */ Q(ti, [["__scopeId", "data-v-2f6fc50f"]]), ni = ["title"], lt = 99, ii = /* @__PURE__ */ J({
264
+ __name: "ItemBadge",
265
+ props: {
266
+ count: {
267
+ type: Number,
268
+ required: !0,
269
+ default: void 0
270
+ }
271
+ },
272
+ setup(n) {
273
+ const t = n, i = k(() => t.count ? t.count > lt ? `${lt}+` : t.count.toString() : "");
274
+ return (a, c) => i.value ? (p(), y("div", {
275
+ key: 0,
276
+ class: "item-badge",
277
+ title: (n.count || 0) > lt ? String(n.count) : void 0
278
+ }, q(i.value), 9, ni)) : S("", !0);
279
+ }
280
+ }), ri = /* @__PURE__ */ Q(ii, [["__scopeId", "data-v-afb0d903"]]), oi = ["data-testid"], si = ["aria-controls", "aria-current", "aria-expanded", "href", "target", "onClick", "onKeypress"], ci = {
281
+ key: 0,
282
+ class: "sidebar-item-icon"
283
+ }, li = { class: "sidebar-item-name-container" }, ui = { class: "sidebar-item-name has-tooltip" }, di = {
284
+ key: 2,
285
+ class: "sidebar-item-label truncate-text truncate-18"
286
+ }, fi = ["id"], vi = /* @__PURE__ */ J({
287
+ __name: "SidebarItem",
288
+ props: {
289
+ item: {
290
+ type: Object,
291
+ required: !0
292
+ },
293
+ /** True if the item is not an L1 primary sidebar item */
294
+ subnavItem: {
295
+ type: Boolean,
296
+ default: !1
297
+ }
298
+ },
299
+ emits: ["click"],
300
+ setup(n, { emit: t }) {
301
+ const i = t, a = n, c = k(() => typeof a.item.to != "string" ? !1 : !!a.item.newWindow || !!a.item.external || a.item.to.startsWith("http")), u = k(() => !a.item.to || typeof a.item.to != "string" || !a.item.newWindow ? !1 : a.item.newWindow && (a.item.to.startsWith("http") || a.item.to.startsWith("/"))), o = k(() => a.subnavItem && a.item.badgeCount !== void 0 && a.item.badgeCount !== 0), v = (O) => {
302
+ i("click", O);
303
+ }, m = (O, A, N) => {
304
+ v(A), typeof N == "function" && (O.preventDefault(), N());
305
+ };
306
+ return (O, A) => {
307
+ var x;
308
+ const N = pe("KTooltip"), R = pe("SidebarItem", !0);
309
+ return p(), y("li", {
310
+ class: ie([n.subnavItem ? "sidebar-item-secondary" : "sidebar-item-primary", { expanded: n.item.expanded }, { active: n.item.active }]),
311
+ "data-testid": n.item.testId ? `sidebar-item-${n.item.testId}` : void 0
312
+ }, [
313
+ (p(), K(He(c.value ? "div" : "router-link"), {
314
+ custom: c.value ? void 0 : !0,
315
+ to: !c.value && !u.value ? n.item.to : void 0
316
+ }, {
317
+ default: D((w) => {
318
+ var P, Y;
319
+ return [
320
+ I("a", {
321
+ "aria-controls": (P = n.item.items) != null && P.length && n.item.expanded ? `subnav-${n.item.key}` : void 0,
322
+ "aria-current": n.item.active ? "page" : void 0,
323
+ "aria-expanded": (Y = n.item.items) != null && Y.length && n.item.expanded ? !0 : void 0,
324
+ class: ie(["sidebar-item-link", { "sidebar-item-external-link": u.value, "router-link": !c.value }]),
325
+ href: c.value ? String(n.item.to || "#") : w == null ? void 0 : w.href,
326
+ target: u.value ? "_blank" : void 0,
327
+ onClick: (B) => m(B, n.item, w == null ? void 0 : w.navigate),
328
+ onKeypress: hn((B) => m(B, n.item, w == null ? void 0 : w.navigate), ["enter"])
329
+ }, [
330
+ I("div", {
331
+ class: ie(["sidebar-item-display", { "has-label": !!n.item.label && n.item.expanded, "has-badge": o.value }])
332
+ }, [
333
+ O.$slots[`sidebar-icon-${n.item.key}`] ? (p(), y("div", ci, [
334
+ n.subnavItem ? S("", !0) : T(O.$slots, `sidebar-icon-${n.item.key}`, { key: 0 }, void 0, !0)
335
+ ])) : S("", !0),
336
+ I("div", li, [
337
+ (n.subnavItem && !o.value ? n.item.name.length < 25 : n.item.name.length < 18) ? (p(), y("div", {
338
+ key: 0,
339
+ class: ie(["sidebar-item-name truncate-text", [n.subnavItem ? "has-badge-max-width truncate-24" : "truncate-17"]])
340
+ }, q(n.item.name), 3)) : (p(), K(N, {
341
+ key: 1,
342
+ class: "sidebar-item-tooltip",
343
+ placement: "right",
344
+ "position-fixed": "",
345
+ text: n.item.name
346
+ }, {
347
+ default: D(() => [
348
+ I("div", ui, [
349
+ I("span", {
350
+ class: ie(["truncate-text", [n.subnavItem ? "truncate-18" : "truncate-17", { "has-badge-max-width": o.value }]])
351
+ }, q(n.item.name), 3)
352
+ ])
353
+ ]),
354
+ _: 1
355
+ }, 8, ["text"])),
356
+ n.item.label && n.item.expanded ? (p(), y("div", di, q(n.item.label), 1)) : S("", !0)
357
+ ]),
358
+ o.value ? (p(), K(ri, {
359
+ key: 1,
360
+ count: n.item.badgeCount
361
+ }, null, 8, ["count"])) : S("", !0)
362
+ ], 2)
363
+ ], 42, si)
364
+ ];
365
+ }),
366
+ _: 3
367
+ }, 8, ["custom", "to"])),
368
+ (x = n.item.items) != null && x.length && n.item.expanded ? (p(), y("ul", {
369
+ key: 0,
370
+ id: `subnav-${n.item.key}`,
371
+ class: "level-secondary"
372
+ }, [
373
+ (p(!0), y(Ce, null, Te(n.item.items, (w) => (p(), K(R, {
374
+ key: w.name,
375
+ item: w,
376
+ "subnav-item": !0,
377
+ onClick: (P) => v(w)
378
+ }, null, 8, ["item", "onClick"]))), 128))
379
+ ], 8, fi)) : S("", !0)
380
+ ], 10, oi);
381
+ };
382
+ }
383
+ }), Lt = /* @__PURE__ */ Q(vi, [["__scopeId", "data-v-d0b5bc3d"]]);
384
+ /*!
385
+ * tabbable 6.2.0
386
+ * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
387
+ */
388
+ var zt = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])", "a[href]:not([inert])", "button:not([inert])", "[tabindex]:not(slot):not([inert])", "audio[controls]:not([inert])", "video[controls]:not([inert])", '[contenteditable]:not([contenteditable="false"]):not([inert])', "details>summary:first-of-type:not([inert])", "details:not([inert])"], We = /* @__PURE__ */ zt.join(","), Vt = typeof Element > "u", he = Vt ? function() {
389
+ } : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector, ze = !Vt && Element.prototype.getRootNode ? function(n) {
390
+ var t;
391
+ return n == null || (t = n.getRootNode) === null || t === void 0 ? void 0 : t.call(n);
392
+ } : function(n) {
393
+ return n == null ? void 0 : n.ownerDocument;
394
+ }, Ve = function n(t, i) {
395
+ var a;
396
+ i === void 0 && (i = !0);
397
+ var c = t == null || (a = t.getAttribute) === null || a === void 0 ? void 0 : a.call(t, "inert"), u = c === "" || c === "true", o = u || i && t && n(t.parentNode);
398
+ return o;
399
+ }, bi = function(t) {
400
+ var i, a = t == null || (i = t.getAttribute) === null || i === void 0 ? void 0 : i.call(t, "contenteditable");
401
+ return a === "" || a === "true";
402
+ }, Gt = function(t, i, a) {
403
+ if (Ve(t))
404
+ return [];
405
+ var c = Array.prototype.slice.apply(t.querySelectorAll(We));
406
+ return i && he.call(t, We) && c.unshift(t), c = c.filter(a), c;
407
+ }, qt = function n(t, i, a) {
408
+ for (var c = [], u = Array.from(t); u.length; ) {
409
+ var o = u.shift();
410
+ if (!Ve(o, !1))
411
+ if (o.tagName === "SLOT") {
412
+ var v = o.assignedElements(), m = v.length ? v : o.children, O = n(m, !0, a);
413
+ a.flatten ? c.push.apply(c, O) : c.push({
414
+ scopeParent: o,
415
+ candidates: O
416
+ });
417
+ } else {
418
+ var A = he.call(o, We);
419
+ A && a.filter(o) && (i || !t.includes(o)) && c.push(o);
420
+ var N = o.shadowRoot || // check for an undisclosed shadow
421
+ typeof a.getShadowRoot == "function" && a.getShadowRoot(o), R = !Ve(N, !1) && (!a.shadowRootFilter || a.shadowRootFilter(o));
422
+ if (N && R) {
423
+ var x = n(N === !0 ? o.children : N.children, !0, a);
424
+ a.flatten ? c.push.apply(c, x) : c.push({
425
+ scopeParent: o,
426
+ candidates: x
427
+ });
428
+ } else
429
+ u.unshift.apply(u, o.children);
430
+ }
431
+ }
432
+ return c;
433
+ }, Xt = function(t) {
434
+ return !isNaN(parseInt(t.getAttribute("tabindex"), 10));
435
+ }, be = function(t) {
436
+ if (!t)
437
+ throw new Error("No node provided");
438
+ return t.tabIndex < 0 && (/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName) || bi(t)) && !Xt(t) ? 0 : t.tabIndex;
439
+ }, pi = function(t, i) {
440
+ var a = be(t);
441
+ return a < 0 && i && !Xt(t) ? 0 : a;
442
+ }, hi = function(t, i) {
443
+ return t.tabIndex === i.tabIndex ? t.documentOrder - i.documentOrder : t.tabIndex - i.tabIndex;
444
+ }, Yt = function(t) {
445
+ return t.tagName === "INPUT";
446
+ }, mi = function(t) {
447
+ return Yt(t) && t.type === "hidden";
448
+ }, gi = function(t) {
449
+ var i = t.tagName === "DETAILS" && Array.prototype.slice.apply(t.children).some(function(a) {
450
+ return a.tagName === "SUMMARY";
451
+ });
452
+ return i;
453
+ }, yi = function(t, i) {
454
+ for (var a = 0; a < t.length; a++)
455
+ if (t[a].checked && t[a].form === i)
456
+ return t[a];
457
+ }, wi = function(t) {
458
+ if (!t.name)
459
+ return !0;
460
+ var i = t.form || ze(t), a = function(v) {
461
+ return i.querySelectorAll('input[type="radio"][name="' + v + '"]');
462
+ }, c;
463
+ if (typeof window < "u" && typeof window.CSS < "u" && typeof window.CSS.escape == "function")
464
+ c = a(window.CSS.escape(t.name));
465
+ else
466
+ try {
467
+ c = a(t.name);
468
+ } catch (o) {
469
+ return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s", o.message), !1;
470
+ }
471
+ var u = yi(c, t.form);
472
+ return !u || u === t;
473
+ }, ki = function(t) {
474
+ return Yt(t) && t.type === "radio";
475
+ }, Ti = function(t) {
476
+ return ki(t) && !wi(t);
477
+ }, _i = function(t) {
478
+ var i, a = t && ze(t), c = (i = a) === null || i === void 0 ? void 0 : i.host, u = !1;
479
+ if (a && a !== t) {
480
+ var o, v, m;
481
+ for (u = !!((o = c) !== null && o !== void 0 && (v = o.ownerDocument) !== null && v !== void 0 && v.contains(c) || t != null && (m = t.ownerDocument) !== null && m !== void 0 && m.contains(t)); !u && c; ) {
482
+ var O, A, N;
483
+ a = ze(c), c = (O = a) === null || O === void 0 ? void 0 : O.host, u = !!((A = c) !== null && A !== void 0 && (N = A.ownerDocument) !== null && N !== void 0 && N.contains(c));
484
+ }
485
+ }
486
+ return u;
487
+ }, Pt = function(t) {
488
+ var i = t.getBoundingClientRect(), a = i.width, c = i.height;
489
+ return a === 0 && c === 0;
490
+ }, Si = function(t, i) {
491
+ var a = i.displayCheck, c = i.getShadowRoot;
492
+ if (getComputedStyle(t).visibility === "hidden")
493
+ return !0;
494
+ var u = he.call(t, "details>summary:first-of-type"), o = u ? t.parentElement : t;
495
+ if (he.call(o, "details:not([open]) *"))
496
+ return !0;
497
+ if (!a || a === "full" || a === "legacy-full") {
498
+ if (typeof c == "function") {
499
+ for (var v = t; t; ) {
500
+ var m = t.parentElement, O = ze(t);
501
+ if (m && !m.shadowRoot && c(m) === !0)
502
+ return Pt(t);
503
+ t.assignedSlot ? t = t.assignedSlot : !m && O !== t.ownerDocument ? t = O.host : t = m;
504
+ }
505
+ t = v;
506
+ }
507
+ if (_i(t))
508
+ return !t.getClientRects().length;
509
+ if (a !== "legacy-full")
510
+ return !0;
511
+ } else if (a === "non-zero-area")
512
+ return Pt(t);
513
+ return !1;
514
+ }, Ii = function(t) {
515
+ if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))
516
+ for (var i = t.parentElement; i; ) {
517
+ if (i.tagName === "FIELDSET" && i.disabled) {
518
+ for (var a = 0; a < i.children.length; a++) {
519
+ var c = i.children.item(a);
520
+ if (c.tagName === "LEGEND")
521
+ return he.call(i, "fieldset[disabled] *") ? !0 : !c.contains(t);
522
+ }
523
+ return !0;
524
+ }
525
+ i = i.parentElement;
526
+ }
527
+ return !1;
528
+ }, Ge = function(t, i) {
529
+ return !(i.disabled || // we must do an inert look up to filter out any elements inside an inert ancestor
530
+ // because we're limited in the type of selectors we can use in JSDom (see related
531
+ // note related to `candidateSelectors`)
532
+ Ve(i) || mi(i) || Si(i, t) || // For a details element with a summary, the summary element gets the focus
533
+ gi(i) || Ii(i));
534
+ }, dt = function(t, i) {
535
+ return !(Ti(i) || be(i) < 0 || !Ge(t, i));
536
+ }, Oi = function(t) {
537
+ var i = parseInt(t.getAttribute("tabindex"), 10);
538
+ return !!(isNaN(i) || i >= 0);
539
+ }, $i = function n(t) {
540
+ var i = [], a = [];
541
+ return t.forEach(function(c, u) {
542
+ var o = !!c.scopeParent, v = o ? c.scopeParent : c, m = pi(v, o), O = o ? n(c.candidates) : v;
543
+ m === 0 ? o ? i.push.apply(i, O) : i.push(v) : a.push({
544
+ documentOrder: u,
545
+ tabIndex: m,
546
+ item: c,
547
+ isScope: o,
548
+ content: O
549
+ });
550
+ }), a.sort(hi).reduce(function(c, u) {
551
+ return u.isScope ? c.push.apply(c, u.content) : c.push(u.content), c;
552
+ }, []).concat(i);
553
+ }, Ci = function(t, i) {
554
+ i = i || {};
555
+ var a;
556
+ return i.getShadowRoot ? a = qt([t], i.includeContainer, {
557
+ filter: dt.bind(null, i),
558
+ flatten: !1,
559
+ getShadowRoot: i.getShadowRoot,
560
+ shadowRootFilter: Oi
561
+ }) : a = Gt(t, i.includeContainer, dt.bind(null, i)), $i(a);
562
+ }, Ei = function(t, i) {
563
+ i = i || {};
564
+ var a;
565
+ return i.getShadowRoot ? a = qt([t], i.includeContainer, {
566
+ filter: Ge.bind(null, i),
567
+ flatten: !0,
568
+ getShadowRoot: i.getShadowRoot
569
+ }) : a = Gt(t, i.includeContainer, Ge.bind(null, i)), a;
570
+ }, ke = function(t, i) {
571
+ if (i = i || {}, !t)
572
+ throw new Error("No node provided");
573
+ return he.call(t, We) === !1 ? !1 : dt(i, t);
574
+ }, Ni = /* @__PURE__ */ zt.concat("iframe").join(","), ut = function(t, i) {
575
+ if (i = i || {}, !t)
576
+ throw new Error("No node provided");
577
+ return he.call(t, Ni) === !1 ? !1 : Ge(i, t);
578
+ };
579
+ /*!
580
+ * focus-trap 7.6.0
581
+ * @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
582
+ */
583
+ function Ai(n, t, i) {
584
+ return (t = Di(t)) in n ? Object.defineProperty(n, t, {
585
+ value: i,
586
+ enumerable: !0,
587
+ configurable: !0,
588
+ writable: !0
589
+ }) : n[t] = i, n;
590
+ }
591
+ function Mt(n, t) {
592
+ var i = Object.keys(n);
593
+ if (Object.getOwnPropertySymbols) {
594
+ var a = Object.getOwnPropertySymbols(n);
595
+ t && (a = a.filter(function(c) {
596
+ return Object.getOwnPropertyDescriptor(n, c).enumerable;
597
+ })), i.push.apply(i, a);
598
+ }
599
+ return i;
600
+ }
601
+ function jt(n) {
602
+ for (var t = 1; t < arguments.length; t++) {
603
+ var i = arguments[t] != null ? arguments[t] : {};
604
+ t % 2 ? Mt(Object(i), !0).forEach(function(a) {
605
+ Ai(n, a, i[a]);
606
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(i)) : Mt(Object(i)).forEach(function(a) {
607
+ Object.defineProperty(n, a, Object.getOwnPropertyDescriptor(i, a));
608
+ });
609
+ }
610
+ return n;
611
+ }
612
+ function Fi(n, t) {
613
+ if (typeof n != "object" || !n) return n;
614
+ var i = n[Symbol.toPrimitive];
615
+ if (i !== void 0) {
616
+ var a = i.call(n, t || "default");
617
+ if (typeof a != "object") return a;
618
+ throw new TypeError("@@toPrimitive must return a primitive value.");
619
+ }
620
+ return (t === "string" ? String : Number)(n);
621
+ }
622
+ function Di(n) {
623
+ var t = Fi(n, "string");
624
+ return typeof t == "symbol" ? t : t + "";
625
+ }
626
+ var Zt = {
627
+ activateTrap: function(t, i) {
628
+ if (t.length > 0) {
629
+ var a = t[t.length - 1];
630
+ a !== i && a.pause();
631
+ }
632
+ var c = t.indexOf(i);
633
+ c === -1 || t.splice(c, 1), t.push(i);
634
+ },
635
+ deactivateTrap: function(t, i) {
636
+ var a = t.indexOf(i);
637
+ a !== -1 && t.splice(a, 1), t.length > 0 && t[t.length - 1].unpause();
638
+ }
639
+ }, Ri = function(t) {
640
+ return t.tagName && t.tagName.toLowerCase() === "input" && typeof t.select == "function";
641
+ }, xi = function(t) {
642
+ return (t == null ? void 0 : t.key) === "Escape" || (t == null ? void 0 : t.key) === "Esc" || (t == null ? void 0 : t.keyCode) === 27;
643
+ }, Ee = function(t) {
644
+ return (t == null ? void 0 : t.key) === "Tab" || (t == null ? void 0 : t.keyCode) === 9;
645
+ }, Bi = function(t) {
646
+ return Ee(t) && !t.shiftKey;
647
+ }, Li = function(t) {
648
+ return Ee(t) && t.shiftKey;
649
+ }, Kt = function(t) {
650
+ return setTimeout(t, 0);
651
+ }, Ht = function(t, i) {
652
+ var a = -1;
653
+ return t.every(function(c, u) {
654
+ return i(c) ? (a = u, !1) : !0;
655
+ }), a;
656
+ }, $e = function(t) {
657
+ for (var i = arguments.length, a = new Array(i > 1 ? i - 1 : 0), c = 1; c < i; c++)
658
+ a[c - 1] = arguments[c];
659
+ return typeof t == "function" ? t.apply(void 0, a) : t;
660
+ }, je = function(t) {
661
+ return t.target.shadowRoot && typeof t.composedPath == "function" ? t.composedPath()[0] : t.target;
662
+ }, Pi = [], Mi = function(t, i) {
663
+ var a = (i == null ? void 0 : i.document) || document, c = (i == null ? void 0 : i.trapStack) || Pi, u = jt({
664
+ returnFocusOnDeactivate: !0,
665
+ escapeDeactivates: !0,
666
+ delayInitialFocus: !0,
667
+ isKeyForward: Bi,
668
+ isKeyBackward: Li
669
+ }, i), o = {
670
+ // containers given to createFocusTrap()
671
+ // @type {Array<HTMLElement>}
672
+ containers: [],
673
+ // list of objects identifying tabbable nodes in `containers` in the trap
674
+ // NOTE: it's possible that a group has no tabbable nodes if nodes get removed while the trap
675
+ // is active, but the trap should never get to a state where there isn't at least one group
676
+ // with at least one tabbable node in it (that would lead to an error condition that would
677
+ // result in an error being thrown)
678
+ // @type {Array<{
679
+ // container: HTMLElement,
680
+ // tabbableNodes: Array<HTMLElement>, // empty if none
681
+ // focusableNodes: Array<HTMLElement>, // empty if none
682
+ // posTabIndexesFound: boolean,
683
+ // firstTabbableNode: HTMLElement|undefined,
684
+ // lastTabbableNode: HTMLElement|undefined,
685
+ // firstDomTabbableNode: HTMLElement|undefined,
686
+ // lastDomTabbableNode: HTMLElement|undefined,
687
+ // nextTabbableNode: (node: HTMLElement, forward: boolean) => HTMLElement|undefined
688
+ // }>}
689
+ containerGroups: [],
690
+ // same order/length as `containers` list
691
+ // references to objects in `containerGroups`, but only those that actually have
692
+ // tabbable nodes in them
693
+ // NOTE: same order as `containers` and `containerGroups`, but __not necessarily__
694
+ // the same length
695
+ tabbableGroups: [],
696
+ nodeFocusedBeforeActivation: null,
697
+ mostRecentlyFocusedNode: null,
698
+ active: !1,
699
+ paused: !1,
700
+ // timer ID for when delayInitialFocus is true and initial focus in this trap
701
+ // has been delayed during activation
702
+ delayInitialFocusTimer: void 0,
703
+ // the most recent KeyboardEvent for the configured nav key (typically [SHIFT+]TAB), if any
704
+ recentNavEvent: void 0
705
+ }, v, m = function(d, s, f) {
706
+ return d && d[s] !== void 0 ? d[s] : u[f || s];
707
+ }, O = function(d, s) {
708
+ var f = typeof (s == null ? void 0 : s.composedPath) == "function" ? s.composedPath() : void 0;
709
+ return o.containerGroups.findIndex(function(b) {
710
+ var _ = b.container, E = b.tabbableNodes;
711
+ return _.contains(d) || // fall back to explicit tabbable search which will take into consideration any
712
+ // web components if the `tabbableOptions.getShadowRoot` option was used for
713
+ // the trap, enabling shadow DOM support in tabbable (`Node.contains()` doesn't
714
+ // look inside web components even if open)
715
+ (f == null ? void 0 : f.includes(_)) || E.find(function(F) {
716
+ return F === d;
717
+ });
718
+ });
719
+ }, A = function(d) {
720
+ var s = u[d];
721
+ if (typeof s == "function") {
722
+ for (var f = arguments.length, b = new Array(f > 1 ? f - 1 : 0), _ = 1; _ < f; _++)
723
+ b[_ - 1] = arguments[_];
724
+ s = s.apply(void 0, b);
725
+ }
726
+ if (s === !0 && (s = void 0), !s) {
727
+ if (s === void 0 || s === !1)
728
+ return s;
729
+ throw new Error("`".concat(d, "` was specified but was not a node, or did not return a node"));
730
+ }
731
+ var E = s;
732
+ if (typeof s == "string" && (E = a.querySelector(s), !E))
733
+ throw new Error("`".concat(d, "` as selector refers to no known node"));
734
+ return E;
735
+ }, N = function() {
736
+ var d = A("initialFocus");
737
+ if (d === !1)
738
+ return !1;
739
+ if (d === void 0 || !ut(d, u.tabbableOptions))
740
+ if (O(a.activeElement) >= 0)
741
+ d = a.activeElement;
742
+ else {
743
+ var s = o.tabbableGroups[0], f = s && s.firstTabbableNode;
744
+ d = f || A("fallbackFocus");
745
+ }
746
+ if (!d)
747
+ throw new Error("Your focus-trap needs to have at least one focusable element");
748
+ return d;
749
+ }, R = function() {
750
+ if (o.containerGroups = o.containers.map(function(d) {
751
+ var s = Ci(d, u.tabbableOptions), f = Ei(d, u.tabbableOptions), b = s.length > 0 ? s[0] : void 0, _ = s.length > 0 ? s[s.length - 1] : void 0, E = f.find(function(L) {
752
+ return ke(L);
753
+ }), F = f.slice().reverse().find(function(L) {
754
+ return ke(L);
755
+ }), g = !!s.find(function(L) {
756
+ return be(L) > 0;
757
+ });
758
+ return {
759
+ container: d,
760
+ tabbableNodes: s,
761
+ focusableNodes: f,
762
+ /** True if at least one node with positive `tabindex` was found in this container. */
763
+ posTabIndexesFound: g,
764
+ /** First tabbable node in container, __tabindex__ order; `undefined` if none. */
765
+ firstTabbableNode: b,
766
+ /** Last tabbable node in container, __tabindex__ order; `undefined` if none. */
767
+ lastTabbableNode: _,
768
+ // NOTE: DOM order is NOT NECESSARILY "document position" order, but figuring that out
769
+ // would require more than just https://developer.mozilla.org/en-US/docs/Web/API/Node/compareDocumentPosition
770
+ // because that API doesn't work with Shadow DOM as well as it should (@see
771
+ // https://github.com/whatwg/dom/issues/320) and since this first/last is only needed, so far,
772
+ // to address an edge case related to positive tabindex support, this seems like a much easier,
773
+ // "close enough most of the time" alternative for positive tabindexes which should generally
774
+ // be avoided anyway...
775
+ /** First tabbable node in container, __DOM__ order; `undefined` if none. */
776
+ firstDomTabbableNode: E,
777
+ /** Last tabbable node in container, __DOM__ order; `undefined` if none. */
778
+ lastDomTabbableNode: F,
779
+ /**
780
+ * Finds the __tabbable__ node that follows the given node in the specified direction,
781
+ * in this container, if any.
782
+ * @param {HTMLElement} node
783
+ * @param {boolean} [forward] True if going in forward tab order; false if going
784
+ * in reverse.
785
+ * @returns {HTMLElement|undefined} The next tabbable node, if any.
786
+ */
787
+ nextTabbableNode: function(re) {
788
+ var U = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, ae = s.indexOf(re);
789
+ return ae < 0 ? U ? f.slice(f.indexOf(re) + 1).find(function(le) {
790
+ return ke(le);
791
+ }) : f.slice(0, f.indexOf(re)).reverse().find(function(le) {
792
+ return ke(le);
793
+ }) : s[ae + (U ? 1 : -1)];
794
+ }
795
+ };
796
+ }), o.tabbableGroups = o.containerGroups.filter(function(d) {
797
+ return d.tabbableNodes.length > 0;
798
+ }), o.tabbableGroups.length <= 0 && !A("fallbackFocus"))
799
+ throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");
800
+ if (o.containerGroups.find(function(d) {
801
+ return d.posTabIndexesFound;
802
+ }) && o.containerGroups.length > 1)
803
+ throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.");
804
+ }, x = function(d) {
805
+ var s = d.activeElement;
806
+ if (s)
807
+ return s.shadowRoot && s.shadowRoot.activeElement !== null ? x(s.shadowRoot) : s;
808
+ }, w = function(d) {
809
+ if (d !== !1 && d !== x(document)) {
810
+ if (!d || !d.focus) {
811
+ w(N());
812
+ return;
813
+ }
814
+ d.focus({
815
+ preventScroll: !!u.preventScroll
816
+ }), o.mostRecentlyFocusedNode = d, Ri(d) && d.select();
817
+ }
818
+ }, P = function(d) {
819
+ var s = A("setReturnFocus", d);
820
+ return s || (s === !1 ? !1 : d);
821
+ }, Y = function(d) {
822
+ var s = d.target, f = d.event, b = d.isBackward, _ = b === void 0 ? !1 : b;
823
+ s = s || je(f), R();
824
+ var E = null;
825
+ if (o.tabbableGroups.length > 0) {
826
+ var F = O(s, f), g = F >= 0 ? o.containerGroups[F] : void 0;
827
+ if (F < 0)
828
+ _ ? E = o.tabbableGroups[o.tabbableGroups.length - 1].lastTabbableNode : E = o.tabbableGroups[0].firstTabbableNode;
829
+ else if (_) {
830
+ var L = Ht(o.tabbableGroups, function(_e) {
831
+ var Se = _e.firstTabbableNode;
832
+ return s === Se;
833
+ });
834
+ if (L < 0 && (g.container === s || ut(s, u.tabbableOptions) && !ke(s, u.tabbableOptions) && !g.nextTabbableNode(s, !1)) && (L = F), L >= 0) {
835
+ var re = L === 0 ? o.tabbableGroups.length - 1 : L - 1, U = o.tabbableGroups[re];
836
+ E = be(s) >= 0 ? U.lastTabbableNode : U.lastDomTabbableNode;
837
+ } else Ee(f) || (E = g.nextTabbableNode(s, !1));
838
+ } else {
839
+ var ae = Ht(o.tabbableGroups, function(_e) {
840
+ var Se = _e.lastTabbableNode;
841
+ return s === Se;
842
+ });
843
+ if (ae < 0 && (g.container === s || ut(s, u.tabbableOptions) && !ke(s, u.tabbableOptions) && !g.nextTabbableNode(s)) && (ae = F), ae >= 0) {
844
+ var le = ae === o.tabbableGroups.length - 1 ? 0 : ae + 1, De = o.tabbableGroups[le];
845
+ E = be(s) >= 0 ? De.firstTabbableNode : De.firstDomTabbableNode;
846
+ } else Ee(f) || (E = g.nextTabbableNode(s));
847
+ }
848
+ } else
849
+ E = A("fallbackFocus");
850
+ return E;
851
+ }, B = function(d) {
852
+ var s = je(d);
853
+ if (!(O(s, d) >= 0)) {
854
+ if ($e(u.clickOutsideDeactivates, d)) {
855
+ v.deactivate({
856
+ // NOTE: by setting `returnFocus: false`, deactivate() will do nothing,
857
+ // which will result in the outside click setting focus to the node
858
+ // that was clicked (and if not focusable, to "nothing"); by setting
859
+ // `returnFocus: true`, we'll attempt to re-focus the node originally-focused
860
+ // on activation (or the configured `setReturnFocus` node), whether the
861
+ // outside click was on a focusable node or not
862
+ returnFocus: u.returnFocusOnDeactivate
863
+ });
864
+ return;
865
+ }
866
+ $e(u.allowOutsideClick, d) || d.preventDefault();
867
+ }
868
+ }, ne = function(d) {
869
+ var s = je(d), f = O(s, d) >= 0;
870
+ if (f || s instanceof Document)
871
+ f && (o.mostRecentlyFocusedNode = s);
872
+ else {
873
+ d.stopImmediatePropagation();
874
+ var b, _ = !0;
875
+ if (o.mostRecentlyFocusedNode)
876
+ if (be(o.mostRecentlyFocusedNode) > 0) {
877
+ var E = O(o.mostRecentlyFocusedNode), F = o.containerGroups[E].tabbableNodes;
878
+ if (F.length > 0) {
879
+ var g = F.findIndex(function(L) {
880
+ return L === o.mostRecentlyFocusedNode;
881
+ });
882
+ g >= 0 && (u.isKeyForward(o.recentNavEvent) ? g + 1 < F.length && (b = F[g + 1], _ = !1) : g - 1 >= 0 && (b = F[g - 1], _ = !1));
883
+ }
884
+ } else
885
+ o.containerGroups.some(function(L) {
886
+ return L.tabbableNodes.some(function(re) {
887
+ return be(re) > 0;
888
+ });
889
+ }) || (_ = !1);
890
+ else
891
+ _ = !1;
892
+ _ && (b = Y({
893
+ // move FROM the MRU node, not event-related node (which will be the node that is
894
+ // outside the trap causing the focus escape we're trying to fix)
895
+ target: o.mostRecentlyFocusedNode,
896
+ isBackward: u.isKeyBackward(o.recentNavEvent)
897
+ })), w(b || o.mostRecentlyFocusedNode || N());
898
+ }
899
+ o.recentNavEvent = void 0;
900
+ }, ce = function(d) {
901
+ var s = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
902
+ o.recentNavEvent = d;
903
+ var f = Y({
904
+ event: d,
905
+ isBackward: s
906
+ });
907
+ f && (Ee(d) && d.preventDefault(), w(f));
908
+ }, ee = function(d) {
909
+ (u.isKeyForward(d) || u.isKeyBackward(d)) && ce(d, u.isKeyBackward(d));
910
+ }, te = function(d) {
911
+ xi(d) && $e(u.escapeDeactivates, d) !== !1 && (d.preventDefault(), v.deactivate());
912
+ }, Z = function(d) {
913
+ var s = je(d);
914
+ O(s, d) >= 0 || $e(u.clickOutsideDeactivates, d) || $e(u.allowOutsideClick, d) || (d.preventDefault(), d.stopImmediatePropagation());
915
+ }, X = function() {
916
+ if (o.active)
917
+ return Zt.activateTrap(c, v), o.delayInitialFocusTimer = u.delayInitialFocus ? Kt(function() {
918
+ w(N());
919
+ }) : w(N()), a.addEventListener("focusin", ne, !0), a.addEventListener("mousedown", B, {
920
+ capture: !0,
921
+ passive: !1
922
+ }), a.addEventListener("touchstart", B, {
923
+ capture: !0,
924
+ passive: !1
925
+ }), a.addEventListener("click", Z, {
926
+ capture: !0,
927
+ passive: !1
928
+ }), a.addEventListener("keydown", ee, {
929
+ capture: !0,
930
+ passive: !1
931
+ }), a.addEventListener("keydown", te), v;
932
+ }, $ = function() {
933
+ if (o.active)
934
+ return a.removeEventListener("focusin", ne, !0), a.removeEventListener("mousedown", B, !0), a.removeEventListener("touchstart", B, !0), a.removeEventListener("click", Z, !0), a.removeEventListener("keydown", ee, !0), a.removeEventListener("keydown", te), v;
935
+ }, M = function(d) {
936
+ var s = d.some(function(f) {
937
+ var b = Array.from(f.removedNodes);
938
+ return b.some(function(_) {
939
+ return _ === o.mostRecentlyFocusedNode;
940
+ });
941
+ });
942
+ s && w(N());
943
+ }, W = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(M) : void 0, H = function() {
944
+ W && (W.disconnect(), o.active && !o.paused && o.containers.map(function(d) {
945
+ W.observe(d, {
946
+ subtree: !0,
947
+ childList: !0
948
+ });
949
+ }));
950
+ };
951
+ return v = {
952
+ get active() {
953
+ return o.active;
954
+ },
955
+ get paused() {
956
+ return o.paused;
957
+ },
958
+ activate: function(d) {
959
+ if (o.active)
960
+ return this;
961
+ var s = m(d, "onActivate"), f = m(d, "onPostActivate"), b = m(d, "checkCanFocusTrap");
962
+ b || R(), o.active = !0, o.paused = !1, o.nodeFocusedBeforeActivation = a.activeElement, s == null || s();
963
+ var _ = function() {
964
+ b && R(), X(), H(), f == null || f();
965
+ };
966
+ return b ? (b(o.containers.concat()).then(_, _), this) : (_(), this);
967
+ },
968
+ deactivate: function(d) {
969
+ if (!o.active)
970
+ return this;
971
+ var s = jt({
972
+ onDeactivate: u.onDeactivate,
973
+ onPostDeactivate: u.onPostDeactivate,
974
+ checkCanReturnFocus: u.checkCanReturnFocus
975
+ }, d);
976
+ clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, $(), o.active = !1, o.paused = !1, H(), Zt.deactivateTrap(c, v);
977
+ var f = m(s, "onDeactivate"), b = m(s, "onPostDeactivate"), _ = m(s, "checkCanReturnFocus"), E = m(s, "returnFocus", "returnFocusOnDeactivate");
978
+ f == null || f();
979
+ var F = function() {
980
+ Kt(function() {
981
+ E && w(P(o.nodeFocusedBeforeActivation)), b == null || b();
982
+ });
983
+ };
984
+ return E && _ ? (_(P(o.nodeFocusedBeforeActivation)).then(F, F), this) : (F(), this);
985
+ },
986
+ pause: function(d) {
987
+ if (o.paused || !o.active)
988
+ return this;
989
+ var s = m(d, "onPause"), f = m(d, "onPostPause");
990
+ return o.paused = !0, s == null || s(), $(), H(), f == null || f(), this;
991
+ },
992
+ unpause: function(d) {
993
+ if (!o.paused || !o.active)
994
+ return this;
995
+ var s = m(d, "onUnpause"), f = m(d, "onPostUnpause");
996
+ return o.paused = !1, s == null || s(), R(), X(), H(), f == null || f(), this;
997
+ },
998
+ updateContainerElements: function(d) {
999
+ var s = [].concat(d).filter(Boolean);
1000
+ return o.containers = s.map(function(f) {
1001
+ return typeof f == "string" ? a.querySelector(f) : f;
1002
+ }), o.active && R(), H(), this;
1003
+ }
1004
+ }, v.updateContainerElements(t), v;
1005
+ };
1006
+ /*!
1007
+ * focus-trap-vue v4.0.2
1008
+ * (c) 2023 Eduardo San Martin Morote
1009
+ * @license MIT
1010
+ */
1011
+ const ji = {
1012
+ escapeDeactivates: {
1013
+ type: Boolean,
1014
+ default: !0
1015
+ },
1016
+ returnFocusOnDeactivate: {
1017
+ type: Boolean,
1018
+ default: !0
1019
+ },
1020
+ allowOutsideClick: {
1021
+ type: [Boolean, Function],
1022
+ default: !0
1023
+ },
1024
+ clickOutsideDeactivates: [Boolean, Function],
1025
+ initialFocus: [String, Function, Boolean],
1026
+ fallbackFocus: [String, Function],
1027
+ checkCanFocusTrap: Function,
1028
+ checkCanReturnFocus: Function,
1029
+ delayInitialFocus: {
1030
+ type: Boolean,
1031
+ default: !0
1032
+ },
1033
+ document: Object,
1034
+ preventScroll: Boolean,
1035
+ setReturnFocus: [Object, String, Boolean, Function],
1036
+ tabbableOptions: Object
1037
+ }, Zi = J({
1038
+ props: Object.assign({
1039
+ active: {
1040
+ // TODO: could be options for activate but what about the options for deactivating?
1041
+ type: Boolean,
1042
+ default: !0
1043
+ }
1044
+ }, ji),
1045
+ emits: [
1046
+ "update:active",
1047
+ "activate",
1048
+ "postActivate",
1049
+ "deactivate",
1050
+ "postDeactivate"
1051
+ ],
1052
+ render() {
1053
+ return this.renderImpl();
1054
+ },
1055
+ setup(n, { slots: t, emit: i }) {
1056
+ let a;
1057
+ const c = G(null), u = k(() => {
1058
+ const v = c.value;
1059
+ return v && (v instanceof HTMLElement ? v : v.$el);
1060
+ });
1061
+ function o() {
1062
+ return a || (a = Mi(u.value, {
1063
+ escapeDeactivates: n.escapeDeactivates,
1064
+ allowOutsideClick: n.allowOutsideClick,
1065
+ returnFocusOnDeactivate: n.returnFocusOnDeactivate,
1066
+ clickOutsideDeactivates: n.clickOutsideDeactivates,
1067
+ onActivate: () => {
1068
+ i("update:active", !0), i("activate");
1069
+ },
1070
+ onDeactivate: () => {
1071
+ i("update:active", !1), i("deactivate");
1072
+ },
1073
+ onPostActivate: () => i("postActivate"),
1074
+ onPostDeactivate: () => i("postDeactivate"),
1075
+ initialFocus: n.initialFocus,
1076
+ fallbackFocus: n.fallbackFocus,
1077
+ tabbableOptions: n.tabbableOptions,
1078
+ delayInitialFocus: n.delayInitialFocus,
1079
+ preventScroll: n.preventScroll
1080
+ }));
1081
+ }
1082
+ return Ye(() => {
1083
+ Fe(() => n.active, (v) => {
1084
+ v && u.value ? o().activate() : a && (a.deactivate(), (!u.value || u.value.nodeType === Node.COMMENT_NODE) && (a = null));
1085
+ }, { immediate: !0, flush: "post" });
1086
+ }), mn(() => {
1087
+ a && a.deactivate(), a = null;
1088
+ }), {
1089
+ activate() {
1090
+ o().activate();
1091
+ },
1092
+ deactivate() {
1093
+ a && a.deactivate();
1094
+ },
1095
+ renderImpl() {
1096
+ if (!t.default)
1097
+ return null;
1098
+ const v = t.default().filter((O) => O.type !== gn);
1099
+ return !v || !v.length || v.length > 1 ? (console.error("[focus-trap-vue]: FocusTrap requires exactly one child."), v) : yn(v[0], { ref: c });
1100
+ }
1101
+ };
1102
+ }
1103
+ });
1104
+ function Jt() {
1105
+ return {
1106
+ debounce: (t, i) => {
1107
+ let a;
1108
+ return (...c) => {
1109
+ clearTimeout(a), a = window == null ? void 0 : window.setTimeout(() => {
1110
+ t(...c);
1111
+ }, i);
1112
+ };
1113
+ }
1114
+ };
1115
+ }
1116
+ var Ze = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
1117
+ function Ki(n) {
1118
+ return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
1119
+ }
1120
+ var qe = { exports: {} };
1121
+ qe.exports;
1122
+ (function(n, t) {
1123
+ var i = 200, a = "__lodash_hash_undefined__", c = 9007199254740991, u = "[object Arguments]", o = "[object Array]", v = "[object Boolean]", m = "[object Date]", O = "[object Error]", A = "[object Function]", N = "[object GeneratorFunction]", R = "[object Map]", x = "[object Number]", w = "[object Object]", P = "[object Promise]", Y = "[object RegExp]", B = "[object Set]", ne = "[object String]", ce = "[object Symbol]", ee = "[object WeakMap]", te = "[object ArrayBuffer]", Z = "[object DataView]", X = "[object Float32Array]", $ = "[object Float64Array]", M = "[object Int8Array]", W = "[object Int16Array]", H = "[object Int32Array]", C = "[object Uint8Array]", d = "[object Uint8ClampedArray]", s = "[object Uint16Array]", f = "[object Uint32Array]", b = /[\\^$.*+?()[\]{}|]/g, _ = /\w*$/, E = /^\[object .+?Constructor\]$/, F = /^(?:0|[1-9]\d*)$/, g = {};
1124
+ g[u] = g[o] = g[te] = g[Z] = g[v] = g[m] = g[X] = g[$] = g[M] = g[W] = g[H] = g[R] = g[x] = g[w] = g[Y] = g[B] = g[ne] = g[ce] = g[C] = g[d] = g[s] = g[f] = !0, g[O] = g[A] = g[ee] = !1;
1125
+ var L = typeof Ze == "object" && Ze && Ze.Object === Object && Ze, re = typeof self == "object" && self && self.Object === Object && self, U = L || re || Function("return this")(), ae = t && !t.nodeType && t, le = ae && !0 && n && !n.nodeType && n, De = le && le.exports === ae;
1126
+ function _e(e, r) {
1127
+ return e.set(r[0], r[1]), e;
1128
+ }
1129
+ function Se(e, r) {
1130
+ return e.add(r), e;
1131
+ }
1132
+ function Qt(e, r) {
1133
+ for (var l = -1, h = e ? e.length : 0; ++l < h && r(e[l], l, e) !== !1; )
1134
+ ;
1135
+ return e;
1136
+ }
1137
+ function ea(e, r) {
1138
+ for (var l = -1, h = r.length, j = e.length; ++l < h; )
1139
+ e[j + l] = r[l];
1140
+ return e;
1141
+ }
1142
+ function vt(e, r, l, h) {
1143
+ for (var j = -1, z = e ? e.length : 0; ++j < z; )
1144
+ l = r(l, e[j], j, e);
1145
+ return l;
1146
+ }
1147
+ function ta(e, r) {
1148
+ for (var l = -1, h = Array(e); ++l < e; )
1149
+ h[l] = r(l);
1150
+ return h;
1151
+ }
1152
+ function aa(e, r) {
1153
+ return e == null ? void 0 : e[r];
1154
+ }
1155
+ function bt(e) {
1156
+ var r = !1;
1157
+ if (e != null && typeof e.toString != "function")
1158
+ try {
1159
+ r = !!(e + "");
1160
+ } catch {
1161
+ }
1162
+ return r;
1163
+ }
1164
+ function pt(e) {
1165
+ var r = -1, l = Array(e.size);
1166
+ return e.forEach(function(h, j) {
1167
+ l[++r] = [j, h];
1168
+ }), l;
1169
+ }
1170
+ function Je(e, r) {
1171
+ return function(l) {
1172
+ return e(r(l));
1173
+ };
1174
+ }
1175
+ function ht(e) {
1176
+ var r = -1, l = Array(e.size);
1177
+ return e.forEach(function(h) {
1178
+ l[++r] = h;
1179
+ }), l;
1180
+ }
1181
+ var na = Array.prototype, ia = Function.prototype, Re = Object.prototype, Qe = U["__core-js_shared__"], mt = function() {
1182
+ var e = /[^.]+$/.exec(Qe && Qe.keys && Qe.keys.IE_PROTO || "");
1183
+ return e ? "Symbol(src)_1." + e : "";
1184
+ }(), gt = ia.toString, ue = Re.hasOwnProperty, xe = Re.toString, ra = RegExp(
1185
+ "^" + gt.call(ue).replace(b, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
1186
+ ), yt = De ? U.Buffer : void 0, wt = U.Symbol, kt = U.Uint8Array, oa = Je(Object.getPrototypeOf, Object), sa = Object.create, ca = Re.propertyIsEnumerable, la = na.splice, Tt = Object.getOwnPropertySymbols, ua = yt ? yt.isBuffer : void 0, da = Je(Object.keys, Object), et = ye(U, "DataView"), Ie = ye(U, "Map"), tt = ye(U, "Promise"), at = ye(U, "Set"), nt = ye(U, "WeakMap"), Oe = ye(Object, "create"), fa = ve(et), va = ve(Ie), ba = ve(tt), pa = ve(at), ha = ve(nt), _t = wt ? wt.prototype : void 0, St = _t ? _t.valueOf : void 0;
1187
+ function de(e) {
1188
+ var r = -1, l = e ? e.length : 0;
1189
+ for (this.clear(); ++r < l; ) {
1190
+ var h = e[r];
1191
+ this.set(h[0], h[1]);
1192
+ }
1193
+ }
1194
+ function ma() {
1195
+ this.__data__ = Oe ? Oe(null) : {};
1196
+ }
1197
+ function ga(e) {
1198
+ return this.has(e) && delete this.__data__[e];
1199
+ }
1200
+ function ya(e) {
1201
+ var r = this.__data__;
1202
+ if (Oe) {
1203
+ var l = r[e];
1204
+ return l === a ? void 0 : l;
1205
+ }
1206
+ return ue.call(r, e) ? r[e] : void 0;
1207
+ }
1208
+ function wa(e) {
1209
+ var r = this.__data__;
1210
+ return Oe ? r[e] !== void 0 : ue.call(r, e);
1211
+ }
1212
+ function ka(e, r) {
1213
+ var l = this.__data__;
1214
+ return l[e] = Oe && r === void 0 ? a : r, this;
1215
+ }
1216
+ de.prototype.clear = ma, de.prototype.delete = ga, de.prototype.get = ya, de.prototype.has = wa, de.prototype.set = ka;
1217
+ function oe(e) {
1218
+ var r = -1, l = e ? e.length : 0;
1219
+ for (this.clear(); ++r < l; ) {
1220
+ var h = e[r];
1221
+ this.set(h[0], h[1]);
1222
+ }
1223
+ }
1224
+ function Ta() {
1225
+ this.__data__ = [];
1226
+ }
1227
+ function _a(e) {
1228
+ var r = this.__data__, l = Be(r, e);
1229
+ if (l < 0)
1230
+ return !1;
1231
+ var h = r.length - 1;
1232
+ return l == h ? r.pop() : la.call(r, l, 1), !0;
1233
+ }
1234
+ function Sa(e) {
1235
+ var r = this.__data__, l = Be(r, e);
1236
+ return l < 0 ? void 0 : r[l][1];
1237
+ }
1238
+ function Ia(e) {
1239
+ return Be(this.__data__, e) > -1;
1240
+ }
1241
+ function Oa(e, r) {
1242
+ var l = this.__data__, h = Be(l, e);
1243
+ return h < 0 ? l.push([e, r]) : l[h][1] = r, this;
1244
+ }
1245
+ oe.prototype.clear = Ta, oe.prototype.delete = _a, oe.prototype.get = Sa, oe.prototype.has = Ia, oe.prototype.set = Oa;
1246
+ function me(e) {
1247
+ var r = -1, l = e ? e.length : 0;
1248
+ for (this.clear(); ++r < l; ) {
1249
+ var h = e[r];
1250
+ this.set(h[0], h[1]);
1251
+ }
1252
+ }
1253
+ function $a() {
1254
+ this.__data__ = {
1255
+ hash: new de(),
1256
+ map: new (Ie || oe)(),
1257
+ string: new de()
1258
+ };
1259
+ }
1260
+ function Ca(e) {
1261
+ return Le(this, e).delete(e);
1262
+ }
1263
+ function Ea(e) {
1264
+ return Le(this, e).get(e);
1265
+ }
1266
+ function Na(e) {
1267
+ return Le(this, e).has(e);
1268
+ }
1269
+ function Aa(e, r) {
1270
+ return Le(this, e).set(e, r), this;
1271
+ }
1272
+ me.prototype.clear = $a, me.prototype.delete = Ca, me.prototype.get = Ea, me.prototype.has = Na, me.prototype.set = Aa;
1273
+ function ge(e) {
1274
+ this.__data__ = new oe(e);
1275
+ }
1276
+ function Fa() {
1277
+ this.__data__ = new oe();
1278
+ }
1279
+ function Da(e) {
1280
+ return this.__data__.delete(e);
1281
+ }
1282
+ function Ra(e) {
1283
+ return this.__data__.get(e);
1284
+ }
1285
+ function xa(e) {
1286
+ return this.__data__.has(e);
1287
+ }
1288
+ function Ba(e, r) {
1289
+ var l = this.__data__;
1290
+ if (l instanceof oe) {
1291
+ var h = l.__data__;
1292
+ if (!Ie || h.length < i - 1)
1293
+ return h.push([e, r]), this;
1294
+ l = this.__data__ = new me(h);
1295
+ }
1296
+ return l.set(e, r), this;
1297
+ }
1298
+ ge.prototype.clear = Fa, ge.prototype.delete = Da, ge.prototype.get = Ra, ge.prototype.has = xa, ge.prototype.set = Ba;
1299
+ function La(e, r) {
1300
+ var l = ot(e) || cn(e) ? ta(e.length, String) : [], h = l.length, j = !!h;
1301
+ for (var z in e)
1302
+ ue.call(e, z) && !(j && (z == "length" || nn(z, h))) && l.push(z);
1303
+ return l;
1304
+ }
1305
+ function It(e, r, l) {
1306
+ var h = e[r];
1307
+ (!(ue.call(e, r) && Et(h, l)) || l === void 0 && !(r in e)) && (e[r] = l);
1308
+ }
1309
+ function Be(e, r) {
1310
+ for (var l = e.length; l--; )
1311
+ if (Et(e[l][0], r))
1312
+ return l;
1313
+ return -1;
1314
+ }
1315
+ function Pa(e, r) {
1316
+ return e && Ot(r, st(r), e);
1317
+ }
1318
+ function it(e, r, l, h, j, z, se) {
1319
+ var V;
1320
+ if (h && (V = z ? h(e, j, z, se) : h(e)), V !== void 0)
1321
+ return V;
1322
+ if (!Pe(e))
1323
+ return e;
1324
+ var Ft = ot(e);
1325
+ if (Ft) {
1326
+ if (V = en(e), !r)
1327
+ return Ya(e, V);
1328
+ } else {
1329
+ var we = fe(e), Dt = we == A || we == N;
1330
+ if (un(e))
1331
+ return Ua(e, r);
1332
+ if (we == w || we == u || Dt && !z) {
1333
+ if (bt(e))
1334
+ return z ? e : {};
1335
+ if (V = tn(Dt ? {} : e), !r)
1336
+ return Ja(e, Pa(V, e));
1337
+ } else {
1338
+ if (!g[we])
1339
+ return z ? e : {};
1340
+ V = an(e, we, it, r);
1341
+ }
1342
+ }
1343
+ se || (se = new ge());
1344
+ var Rt = se.get(e);
1345
+ if (Rt)
1346
+ return Rt;
1347
+ if (se.set(e, V), !Ft)
1348
+ var xt = l ? Qa(e) : st(e);
1349
+ return Qt(xt || e, function(ct, Me) {
1350
+ xt && (Me = ct, ct = e[Me]), It(V, Me, it(ct, r, l, h, Me, e, se));
1351
+ }), V;
1352
+ }
1353
+ function Ma(e) {
1354
+ return Pe(e) ? sa(e) : {};
1355
+ }
1356
+ function ja(e, r, l) {
1357
+ var h = r(e);
1358
+ return ot(e) ? h : ea(h, l(e));
1359
+ }
1360
+ function Za(e) {
1361
+ return xe.call(e);
1362
+ }
1363
+ function Ka(e) {
1364
+ if (!Pe(e) || on(e))
1365
+ return !1;
1366
+ var r = At(e) || bt(e) ? ra : E;
1367
+ return r.test(ve(e));
1368
+ }
1369
+ function Ha(e) {
1370
+ if (!Ct(e))
1371
+ return da(e);
1372
+ var r = [];
1373
+ for (var l in Object(e))
1374
+ ue.call(e, l) && l != "constructor" && r.push(l);
1375
+ return r;
1376
+ }
1377
+ function Ua(e, r) {
1378
+ if (r)
1379
+ return e.slice();
1380
+ var l = new e.constructor(e.length);
1381
+ return e.copy(l), l;
1382
+ }
1383
+ function rt(e) {
1384
+ var r = new e.constructor(e.byteLength);
1385
+ return new kt(r).set(new kt(e)), r;
1386
+ }
1387
+ function Wa(e, r) {
1388
+ var l = r ? rt(e.buffer) : e.buffer;
1389
+ return new e.constructor(l, e.byteOffset, e.byteLength);
1390
+ }
1391
+ function za(e, r, l) {
1392
+ var h = r ? l(pt(e), !0) : pt(e);
1393
+ return vt(h, _e, new e.constructor());
1394
+ }
1395
+ function Va(e) {
1396
+ var r = new e.constructor(e.source, _.exec(e));
1397
+ return r.lastIndex = e.lastIndex, r;
1398
+ }
1399
+ function Ga(e, r, l) {
1400
+ var h = r ? l(ht(e), !0) : ht(e);
1401
+ return vt(h, Se, new e.constructor());
1402
+ }
1403
+ function qa(e) {
1404
+ return St ? Object(St.call(e)) : {};
1405
+ }
1406
+ function Xa(e, r) {
1407
+ var l = r ? rt(e.buffer) : e.buffer;
1408
+ return new e.constructor(l, e.byteOffset, e.length);
1409
+ }
1410
+ function Ya(e, r) {
1411
+ var l = -1, h = e.length;
1412
+ for (r || (r = Array(h)); ++l < h; )
1413
+ r[l] = e[l];
1414
+ return r;
1415
+ }
1416
+ function Ot(e, r, l, h) {
1417
+ l || (l = {});
1418
+ for (var j = -1, z = r.length; ++j < z; ) {
1419
+ var se = r[j], V = void 0;
1420
+ It(l, se, V === void 0 ? e[se] : V);
1421
+ }
1422
+ return l;
1423
+ }
1424
+ function Ja(e, r) {
1425
+ return Ot(e, $t(e), r);
1426
+ }
1427
+ function Qa(e) {
1428
+ return ja(e, st, $t);
1429
+ }
1430
+ function Le(e, r) {
1431
+ var l = e.__data__;
1432
+ return rn(r) ? l[typeof r == "string" ? "string" : "hash"] : l.map;
1433
+ }
1434
+ function ye(e, r) {
1435
+ var l = aa(e, r);
1436
+ return Ka(l) ? l : void 0;
1437
+ }
1438
+ var $t = Tt ? Je(Tt, Object) : vn, fe = Za;
1439
+ (et && fe(new et(new ArrayBuffer(1))) != Z || Ie && fe(new Ie()) != R || tt && fe(tt.resolve()) != P || at && fe(new at()) != B || nt && fe(new nt()) != ee) && (fe = function(e) {
1440
+ var r = xe.call(e), l = r == w ? e.constructor : void 0, h = l ? ve(l) : void 0;
1441
+ if (h)
1442
+ switch (h) {
1443
+ case fa:
1444
+ return Z;
1445
+ case va:
1446
+ return R;
1447
+ case ba:
1448
+ return P;
1449
+ case pa:
1450
+ return B;
1451
+ case ha:
1452
+ return ee;
1453
+ }
1454
+ return r;
1455
+ });
1456
+ function en(e) {
1457
+ var r = e.length, l = e.constructor(r);
1458
+ return r && typeof e[0] == "string" && ue.call(e, "index") && (l.index = e.index, l.input = e.input), l;
1459
+ }
1460
+ function tn(e) {
1461
+ return typeof e.constructor == "function" && !Ct(e) ? Ma(oa(e)) : {};
1462
+ }
1463
+ function an(e, r, l, h) {
1464
+ var j = e.constructor;
1465
+ switch (r) {
1466
+ case te:
1467
+ return rt(e);
1468
+ case v:
1469
+ case m:
1470
+ return new j(+e);
1471
+ case Z:
1472
+ return Wa(e, h);
1473
+ case X:
1474
+ case $:
1475
+ case M:
1476
+ case W:
1477
+ case H:
1478
+ case C:
1479
+ case d:
1480
+ case s:
1481
+ case f:
1482
+ return Xa(e, h);
1483
+ case R:
1484
+ return za(e, h, l);
1485
+ case x:
1486
+ case ne:
1487
+ return new j(e);
1488
+ case Y:
1489
+ return Va(e);
1490
+ case B:
1491
+ return Ga(e, h, l);
1492
+ case ce:
1493
+ return qa(e);
1494
+ }
1495
+ }
1496
+ function nn(e, r) {
1497
+ return r = r ?? c, !!r && (typeof e == "number" || F.test(e)) && e > -1 && e % 1 == 0 && e < r;
1498
+ }
1499
+ function rn(e) {
1500
+ var r = typeof e;
1501
+ return r == "string" || r == "number" || r == "symbol" || r == "boolean" ? e !== "__proto__" : e === null;
1502
+ }
1503
+ function on(e) {
1504
+ return !!mt && mt in e;
1505
+ }
1506
+ function Ct(e) {
1507
+ var r = e && e.constructor, l = typeof r == "function" && r.prototype || Re;
1508
+ return e === l;
1509
+ }
1510
+ function ve(e) {
1511
+ if (e != null) {
1512
+ try {
1513
+ return gt.call(e);
1514
+ } catch {
1515
+ }
1516
+ try {
1517
+ return e + "";
1518
+ } catch {
1519
+ }
1520
+ }
1521
+ return "";
1522
+ }
1523
+ function sn(e) {
1524
+ return it(e, !0, !0);
1525
+ }
1526
+ function Et(e, r) {
1527
+ return e === r || e !== e && r !== r;
1528
+ }
1529
+ function cn(e) {
1530
+ return ln(e) && ue.call(e, "callee") && (!ca.call(e, "callee") || xe.call(e) == u);
1531
+ }
1532
+ var ot = Array.isArray;
1533
+ function Nt(e) {
1534
+ return e != null && dn(e.length) && !At(e);
1535
+ }
1536
+ function ln(e) {
1537
+ return fn(e) && Nt(e);
1538
+ }
1539
+ var un = ua || bn;
1540
+ function At(e) {
1541
+ var r = Pe(e) ? xe.call(e) : "";
1542
+ return r == A || r == N;
1543
+ }
1544
+ function dn(e) {
1545
+ return typeof e == "number" && e > -1 && e % 1 == 0 && e <= c;
1546
+ }
1547
+ function Pe(e) {
1548
+ var r = typeof e;
1549
+ return !!e && (r == "object" || r == "function");
1550
+ }
1551
+ function fn(e) {
1552
+ return !!e && typeof e == "object";
1553
+ }
1554
+ function st(e) {
1555
+ return Nt(e) ? La(e) : Ha(e);
1556
+ }
1557
+ function vn() {
1558
+ return [];
1559
+ }
1560
+ function bn() {
1561
+ return !1;
1562
+ }
1563
+ n.exports = sn;
1564
+ })(qe, qe.exports);
1565
+ var Hi = qe.exports;
1566
+ const Ui = /* @__PURE__ */ Ki(Hi), Wi = {
1567
+ key: 0,
1568
+ class: "sidebar-header"
1569
+ }, zi = { class: "sidebar-content-container" }, Vi = {
1570
+ key: 0,
1571
+ class: "sidebar-top"
1572
+ }, Gi = { "aria-label": "Main menu" }, qi = {
1573
+ key: 0,
1574
+ class: "level-primary top-items"
1575
+ }, Xi = {
1576
+ key: 1,
1577
+ class: "sidebar-level-divider",
1578
+ role: "separator"
1579
+ }, Yi = {
1580
+ key: 2,
1581
+ class: "level-primary bottom-items"
1582
+ }, Ji = { class: "sidebar-footer" }, Qi = /* @__PURE__ */ J({
1583
+ __name: "AppSidebar",
1584
+ props: {
1585
+ topItems: {
1586
+ type: Array,
1587
+ default: () => []
1588
+ },
1589
+ bottomItems: {
1590
+ type: Array,
1591
+ default: () => []
1592
+ },
1593
+ headerHeight: {
1594
+ type: Number,
1595
+ default: 60
1596
+ },
1597
+ topOffset: {
1598
+ type: Number,
1599
+ default: 0
1600
+ },
1601
+ zIndex: {
1602
+ type: Number,
1603
+ default: 3
1604
+ },
1605
+ // Props that only impact mobile
1606
+ open: {
1607
+ type: Boolean,
1608
+ default: !1
1609
+ },
1610
+ mobileEnabled: {
1611
+ type: Boolean,
1612
+ default: !1
1613
+ },
1614
+ mobileTopOffset: {
1615
+ type: Number,
1616
+ default: 0
1617
+ },
1618
+ mobileHeaderVisible: {
1619
+ type: Boolean,
1620
+ default: !1
1621
+ },
1622
+ mobileCloseDelay: {
1623
+ type: Number,
1624
+ default: 350
1625
+ },
1626
+ mobileOverlay: {
1627
+ type: Boolean,
1628
+ default: !0
1629
+ },
1630
+ mobileOverlayZIndex: {
1631
+ type: Number,
1632
+ default: null
1633
+ },
1634
+ mobileOverlayCloseOnClick: {
1635
+ type: Boolean,
1636
+ default: !0
1637
+ }
1638
+ },
1639
+ emits: ["click", "toggle"],
1640
+ setup(n, { emit: t }) {
1641
+ ft((s) => ({
1642
+ 57550566: v.value.mobileHeight,
1643
+ "1408cd76": v.value.mobileTop,
1644
+ "05d6fefc": n.zIndex,
1645
+ "6f79cbe4": v.value.height,
1646
+ "4e307090": v.value.top,
1647
+ "088b480c": O.value.marginTop,
1648
+ "031dfddd": C.value,
1649
+ "0cf3d200": m.value.display,
1650
+ eee20052: m.value.minHeight,
1651
+ "52d49772": A.value.top,
1652
+ "7f644446": A.value.zIndex
1653
+ }));
1654
+ const i = t, a = n, c = Xe(), u = k(() => !!c.header), o = k(() => !!c.top), v = k(() => ({
1655
+ mobileTop: a.mobileTopOffset && a.mobileEnabled ? `${a.mobileTopOffset}px` : a.topOffset ? `${a.topOffset}px` : "0",
1656
+ top: a.topOffset ? `${a.topOffset}px` : "0",
1657
+ mobileHeight: a.mobileTopOffset && a.mobileEnabled ? `calc(100% - ${a.mobileTopOffset}px)` : "100%",
1658
+ height: a.topOffset ? `calc(100% - ${a.topOffset}px)` : "100%"
1659
+ })), m = k(() => ({
1660
+ display: !a.mobileHeaderVisible && a.mobileEnabled ? "none" : "flex",
1661
+ minHeight: `${a.headerHeight}px`
1662
+ })), O = k(() => ({
1663
+ marginTop: u.value ? `${a.headerHeight}px` : "0"
1664
+ })), A = k(() => ({
1665
+ top: a.mobileTopOffset && a.mobileEnabled ? `${a.mobileTopOffset}px` : "0",
1666
+ zIndex: a.mobileOverlayZIndex !== null ? a.mobileOverlayZIndex : a.zIndex > 1 ? a.zIndex - 1 : 1
1667
+ })), N = (s) => Ui(s).map((b) => {
1668
+ var _, E, F;
1669
+ if (b) {
1670
+ (!b.key || !((_ = b.key) != null && _.trim())) && (b.key = String(b.name || "").trim().toLowerCase().replace(/[^[a-z]/gi, "-")), (!b.testId || !((E = b.testId) != null && E.trim())) && (b.testId = String(b.name || "").trim().toLowerCase().replace(/[^[a-z]/gi, "-"));
1671
+ for (const g of b.items || [])
1672
+ g.parentKey = b.key, (!g.testId || !((F = g.testId) != null && F.trim())) && (g.testId = String(g.name || "").trim().toLowerCase().replace(/[^[a-z]/gi, "-"));
1673
+ }
1674
+ return b;
1675
+ }), R = k(() => a.topItems.length ? N(a.topItems) : []), x = k(() => a.bottomItems.length ? N(a.bottomItems) : []), w = G(a.open), P = (s) => {
1676
+ var f, b;
1677
+ w.value !== s && (w.value = s, i("toggle", s)), s ? (f = document == null ? void 0 : document.body) == null || f.classList.add("kong-ui-app-sidebar-open") : (b = document == null ? void 0 : document.body) == null || b.classList.remove("kong-ui-app-sidebar-open"), B.value = !1;
1678
+ }, Y = () => {
1679
+ a.mobileOverlayCloseOnClick && P(!1);
1680
+ }, B = G(!1), ne = (s) => {
1681
+ B.value = !0, i("click", s), setTimeout(() => {
1682
+ P(!1);
1683
+ }, a.mobileCloseDelay);
1684
+ };
1685
+ Fe(() => a.open, (s) => {
1686
+ P(s);
1687
+ });
1688
+ const { debounce: ce } = Jt(), ee = ce(() => {
1689
+ w.value && te.value !== (window == null ? void 0 : window.innerWidth) && (te.value = window == null ? void 0 : window.innerWidth, P(!1));
1690
+ }, 200), te = G(), Z = G(!1), X = G(), $ = () => {
1691
+ Z.value || (Z.value = !0, clearTimeout(X.value), X.value = setTimeout(() => Z.value = !1, 1300));
1692
+ }, M = G(null), W = k(() => w.value && a.mobileEnabled), H = async (s) => {
1693
+ var f, b;
1694
+ s ? (await Bt(), await new Promise((_) => setTimeout(_, 300)), (f = M.value) == null || f.activate()) : (b = M.value) == null || b.deactivate();
1695
+ };
1696
+ Fe(W, async (s) => {
1697
+ s ? await H(!0) : await H(!1);
1698
+ }, { immediate: !0 });
1699
+ const C = G("0px"), d = () => {
1700
+ var g;
1701
+ if (!(/Mac|iPhone|iPod|iPad/i.test(navigator == null ? void 0 : navigator.platform) || /macOS|Mac|iPhone|iPod|iPad/i.test((g = navigator == null ? void 0 : navigator.userAgentData) == null ? void 0 : g.platform)))
1702
+ return;
1703
+ const f = document.createElement("div");
1704
+ f.style.visibility = "hidden", f.style.width = "100px", document.body.appendChild(f);
1705
+ const b = f.offsetWidth;
1706
+ f.style.overflow = "scroll";
1707
+ const _ = document.createElement("div");
1708
+ _.style.width = "100%", f.appendChild(_);
1709
+ const E = _.offsetWidth;
1710
+ f.parentNode && f.parentNode.removeChild(f), b - E === 0 && (C.value = "8px");
1711
+ };
1712
+ return Ye(async () => {
1713
+ te.value = window == null ? void 0 : window.innerWidth, window.addEventListener("resize", ee), window.addEventListener("resize", $), await Bt(), d();
1714
+ }), Ut(() => {
1715
+ window.removeEventListener("resize", ee), window.removeEventListener("resize", $);
1716
+ }), (s, f) => (p(), y(Ce, null, [
1717
+ w.value && n.mobileOverlay && n.mobileEnabled ? (p(), y("div", {
1718
+ key: 0,
1719
+ class: "kong-ui-app-sidebar-overlay",
1720
+ onClick: Y
1721
+ })) : S("", !0),
1722
+ Ae(Wt(Zi), {
1723
+ ref_key: "focusTrap",
1724
+ ref: M,
1725
+ active: !1,
1726
+ "allow-outside-click": "",
1727
+ "fallback-focus": ".kong-ui-app-sidebar"
1728
+ }, {
1729
+ default: D(() => [
1730
+ I("aside", {
1731
+ class: ie(["kong-ui-app-sidebar", {
1732
+ "sidebar-open": w.value,
1733
+ "no-sidebar-header": !u.value,
1734
+ "mobile-header-hidden": n.mobileEnabled && (!u.value || !n.mobileHeaderVisible),
1735
+ "mobile-disabled": !n.mobileEnabled,
1736
+ "disable-transitions": Z.value
1737
+ }]),
1738
+ tabindex: "-1"
1739
+ }, [
1740
+ u.value ? (p(), y("div", Wi, [
1741
+ T(s.$slots, "header", {}, void 0, !0)
1742
+ ])) : S("", !0),
1743
+ I("div", zi, [
1744
+ o.value ? (p(), y("div", Vi, [
1745
+ T(s.$slots, "top", {}, void 0, !0)
1746
+ ])) : S("", !0),
1747
+ I("nav", Gi, [
1748
+ R.value.length ? (p(), y("ul", qi, [
1749
+ (p(!0), y(Ce, null, Te(R.value, (b) => (p(), K(Lt, {
1750
+ key: b.name,
1751
+ item: b,
1752
+ onClick: ne
1753
+ }, {
1754
+ [`sidebar-icon-${b.key}`]: D(() => [
1755
+ T(s.$slots, `sidebar-icon-${b.key}`, {}, void 0, !0)
1756
+ ]),
1757
+ _: 2
1758
+ }, 1032, ["item"]))), 128))
1759
+ ])) : S("", !0),
1760
+ R.value.length && x.value.length ? (p(), y("div", Xi)) : S("", !0),
1761
+ x.value.length ? (p(), y("ul", Yi, [
1762
+ (p(!0), y(Ce, null, Te(x.value, (b) => (p(), K(Lt, {
1763
+ key: b.name,
1764
+ item: b,
1765
+ onClick: ne
1766
+ }, {
1767
+ [`sidebar-icon-${b.key}`]: D(() => [
1768
+ T(s.$slots, `sidebar-icon-${b.key}`, {}, void 0, !0)
1769
+ ]),
1770
+ _: 2
1771
+ }, 1032, ["item"]))), 128))
1772
+ ])) : S("", !0)
1773
+ ])
1774
+ ]),
1775
+ I("div", Ji, [
1776
+ T(s.$slots, "footer", {}, void 0, !0)
1777
+ ])
1778
+ ], 2)
1779
+ ]),
1780
+ _: 3
1781
+ }, 512)
1782
+ ], 64));
1783
+ }
1784
+ }), er = /* @__PURE__ */ Q(Qi, [["__scopeId", "data-v-54b44ba6"]]), tr = ["aria-label"], ar = /* @__PURE__ */ J({
1785
+ __name: "SidebarToggle",
1786
+ props: {
1787
+ active: {
1788
+ type: Boolean,
1789
+ default: !1
1790
+ }
1791
+ },
1792
+ emits: ["toggle"],
1793
+ setup(n, { emit: t }) {
1794
+ const i = t, a = n, c = G(a.active || !1), u = (o) => {
1795
+ o.preventDefault(), c.value = !c.value, i("toggle", c.value);
1796
+ };
1797
+ return Fe(() => a.active, (o) => {
1798
+ c.value = o;
1799
+ }), (o, v) => (p(), y("a", {
1800
+ "aria-haspopup": "true",
1801
+ "aria-label": c.value ? "Close Main Menu" : "Open Main Menu",
1802
+ class: ie(["sidebar-menu-toggle", { active: c.value }]),
1803
+ href: "#",
1804
+ role: "button",
1805
+ onClick: wn(u, ["prevent"])
1806
+ }, v[0] || (v[0] = [
1807
+ I("span", { class: "line" }, null, -1),
1808
+ I("span", { class: "line" }, null, -1),
1809
+ I("span", { class: "line" }, null, -1)
1810
+ ]), 10, tr));
1811
+ }
1812
+ }), nr = /* @__PURE__ */ Q(ar, [["__scopeId", "data-v-cbb41bbd"]]), ir = "#ffffff", rr = "#000933", or = "#000933", sr = "#ffffff", cr = "0px", lr = "4px", ur = { id: "kong-ui-app-layout-notification" }, dr = { class: "mobile-logo" }, fr = {
1813
+ key: 0,
1814
+ class: "navbar-logo"
1815
+ }, vr = {
1816
+ class: "kong-ui-app-layout-main",
1817
+ "data-testid": "kong-ui-app-layout-main"
1818
+ }, br = { class: "kong-ui-app-layout-content" }, pr = { class: "kong-ui-app-layout-content-inner" }, hr = /* @__PURE__ */ J({
1819
+ __name: "AppLayout",
1820
+ props: {
1821
+ hideDefaultSlot: {
1822
+ type: Boolean,
1823
+ default: !1
1824
+ },
1825
+ // Navbar props
1826
+ navbarHidden: {
1827
+ type: Boolean,
1828
+ default: !1
1829
+ },
1830
+ // Sidebar props
1831
+ sidebarHidden: {
1832
+ type: Boolean,
1833
+ default: !1
1834
+ },
1835
+ sidebarOpen: {
1836
+ type: Boolean,
1837
+ default: !1
1838
+ },
1839
+ sidebarTopItems: {
1840
+ type: Array,
1841
+ default: () => []
1842
+ },
1843
+ sidebarBottomItems: {
1844
+ type: Array,
1845
+ default: () => []
1846
+ },
1847
+ theme: {
1848
+ type: String,
1849
+ default: "light",
1850
+ validator: (n) => ["light", "dark"].includes(n)
1851
+ }
1852
+ },
1853
+ emits: ["sidebar-click", "update:topOffset"],
1854
+ setup(n, { emit: t }) {
1855
+ ft(($) => ({
1856
+ "2235c6e4": B.value,
1857
+ "29d04344": ne.value,
1858
+ "3d470f48": Y.value,
1859
+ "81803d80": ce.value,
1860
+ "64da7a33": ee.value
1861
+ }));
1862
+ const i = n, a = t, c = Xe(), u = Ke({
1863
+ navbarLeft: k(() => !!c["navbar-left"]),
1864
+ navbarCenter: k(() => !!c["navbar-center"]),
1865
+ navbarRight: k(() => !!c["navbar-right"]),
1866
+ navbarLogo: k(() => !!c["navbar-logo"]),
1867
+ navbarMobileLogo: k(() => !!c["navbar-mobile-logo"]),
1868
+ sidebarHeader: k(() => !!c["sidebar-header"]),
1869
+ sidebarTop: k(() => !!c["sidebar-top"]),
1870
+ sidebarFooter: k(() => !!c["sidebar-footer"])
1871
+ }), o = k(() => i.hideDefaultSlot), v = Ke({
1872
+ hidden: k(() => i.navbarHidden)
1873
+ }), m = Ke({
1874
+ topItems: k(() => i.sidebarTopItems),
1875
+ bottomItems: k(() => i.sidebarBottomItems),
1876
+ open: k(() => i.sidebarOpen),
1877
+ hidden: k(() => i.sidebarHidden)
1878
+ }), O = ($) => {
1879
+ a("sidebar-click", $);
1880
+ }, A = G(!1), N = ($) => {
1881
+ A.value = $;
1882
+ };
1883
+ kn(() => {
1884
+ A.value = Tn(m, "open").value || !1;
1885
+ });
1886
+ const R = G(0), x = G(60), w = G(0), P = k(() => v.hidden ? w.value : x.value + w.value), Y = k(() => i.theme === "light" ? or : sr), B = k(() => i.theme === "light" ? ir : rr), ne = k(() => i.theme === "light" ? "var(--kong-ui-app-layout-main-box-shadow, -30px 174px 250px #0023db)" : "none"), ce = k(() => `${P.value}px`), ee = k(() => m.hidden || v.hidden ? cr : lr), { debounce: te } = Jt(), Z = te(($ = !1) => {
1887
+ if ($ || R.value !== (window == null ? void 0 : window.innerWidth)) {
1888
+ R.value = window == null ? void 0 : window.innerWidth;
1889
+ const M = document == null ? void 0 : document.querySelector(".kong-ui-app-layout #kong-ui-app-layout-notification");
1890
+ M && (w.value = M.offsetHeight);
1891
+ }
1892
+ }, 200), X = G();
1893
+ return Fe(w, ($) => {
1894
+ a("update:topOffset", $ || 0);
1895
+ }, { immediate: !0 }), Ye(() => {
1896
+ var M, W;
1897
+ (M = document == null ? void 0 : document.body) == null || M.classList.add("kong-ui-app-layout-body"), (W = document == null ? void 0 : document.documentElement) == null || W.classList.add("kong-ui-app-layout-html"), R.value = window == null ? void 0 : window.innerWidth, Z(!0);
1898
+ const $ = document == null ? void 0 : document.querySelector(".kong-ui-app-layout #kong-ui-app-layout-notification");
1899
+ $ && (X.value = new ResizeObserver((H) => {
1900
+ window.requestAnimationFrame(() => {
1901
+ if (!(!Array.isArray(H) || !H.length))
1902
+ for (const C of H) {
1903
+ const d = C.contentRect.height;
1904
+ w.value !== d && (w.value = d);
1905
+ }
1906
+ });
1907
+ }), X.value.observe($)), window.addEventListener("resize", Z);
1908
+ }), Ut(() => {
1909
+ X.value && X.value.disconnect(), window.removeEventListener("resize", Z);
1910
+ }), ($, M) => (p(), y("div", {
1911
+ class: ie(["kong-ui-app-layout", [
1912
+ { "navbar-hidden": v.hidden },
1913
+ { "sidebar-hidden": m.hidden }
1914
+ ]])
1915
+ }, [
1916
+ I("div", ur, [
1917
+ T($.$slots, "notification", {}, void 0, !0)
1918
+ ]),
1919
+ v.hidden ? S("", !0) : (p(), K(ai, {
1920
+ key: String(m.hidden),
1921
+ "left-offset": m.hidden ? 0 : void 0,
1922
+ "top-offset": w.value
1923
+ }, Ue({
1924
+ "mobile-sidebar-toggle": D(() => [
1925
+ m.hidden ? S("", !0) : (p(), K(nr, {
1926
+ key: 0,
1927
+ active: A.value,
1928
+ onToggle: N
1929
+ }, null, 8, ["active"]))
1930
+ ]),
1931
+ _: 2
1932
+ }, [
1933
+ u.navbarMobileLogo ? {
1934
+ name: "mobile-logo",
1935
+ fn: D(() => [
1936
+ I("div", dr, [
1937
+ T($.$slots, "navbar-mobile-logo", {}, void 0, !0)
1938
+ ])
1939
+ ]),
1940
+ key: "0"
1941
+ } : void 0,
1942
+ u.navbarLogo ? {
1943
+ name: "logo",
1944
+ fn: D(() => [
1945
+ m.hidden ? (p(), y("div", fr, [
1946
+ T($.$slots, "navbar-logo", {}, void 0, !0)
1947
+ ])) : S("", !0)
1948
+ ]),
1949
+ key: "1"
1950
+ } : void 0,
1951
+ u.navbarLeft ? {
1952
+ name: "left",
1953
+ fn: D(() => [
1954
+ T($.$slots, "navbar-left", {}, void 0, !0)
1955
+ ]),
1956
+ key: "2"
1957
+ } : void 0,
1958
+ u.navbarCenter ? {
1959
+ name: "center",
1960
+ fn: D(() => [
1961
+ T($.$slots, "navbar-center", {}, void 0, !0)
1962
+ ]),
1963
+ key: "3"
1964
+ } : void 0,
1965
+ u.navbarRight ? {
1966
+ name: "right",
1967
+ fn: D(() => [
1968
+ T($.$slots, "navbar-right", {}, void 0, !0)
1969
+ ]),
1970
+ key: "4"
1971
+ } : void 0
1972
+ ]), 1032, ["left-offset", "top-offset"])),
1973
+ m.hidden ? S("", !0) : (p(), K(er, {
1974
+ key: 1,
1975
+ "bottom-items": m.bottomItems,
1976
+ "header-height": x.value,
1977
+ "mobile-enabled": "",
1978
+ "mobile-header-visible": !1,
1979
+ "mobile-top-offset": P.value,
1980
+ open: A.value,
1981
+ "top-items": m.topItems,
1982
+ "top-offset": w.value,
1983
+ onClick: O,
1984
+ onToggle: N
1985
+ }, Ue({ _: 2 }, [
1986
+ u.sidebarHeader ? {
1987
+ name: "header",
1988
+ fn: D(() => [
1989
+ T($.$slots, "sidebar-header", {}, void 0, !0)
1990
+ ]),
1991
+ key: "0"
1992
+ } : void 0,
1993
+ u.sidebarTop ? {
1994
+ name: "top",
1995
+ fn: D(() => [
1996
+ T($.$slots, "sidebar-top", {}, void 0, !0)
1997
+ ]),
1998
+ key: "1"
1999
+ } : void 0,
2000
+ u.sidebarFooter ? {
2001
+ name: "footer",
2002
+ fn: D(() => [
2003
+ T($.$slots, "sidebar-footer", {}, void 0, !0)
2004
+ ]),
2005
+ key: "2"
2006
+ } : void 0,
2007
+ Te([...m.topItems || [], ...m.bottomItems || []], (W) => ({
2008
+ name: `sidebar-icon-${W.key}`,
2009
+ fn: D(() => [
2010
+ T($.$slots, `sidebar-icon-${W.key}`, {}, void 0, !0)
2011
+ ])
2012
+ }))
2013
+ ]), 1032, ["bottom-items", "header-height", "mobile-top-offset", "open", "top-items", "top-offset"])),
2014
+ I("main", vr, [
2015
+ I("div", br, [
2016
+ I("div", pr, [
2017
+ M[0] || (M[0] = I("div", { id: "kong-ui-app-layout-teleport-default-slot" }, null, -1)),
2018
+ T($.$slots, "app-error", {}, void 0, !0),
2019
+ o.value ? S("", !0) : T($.$slots, "default", { key: 0 }, void 0, !0)
2020
+ ])
2021
+ ])
2022
+ ])
2023
+ ], 2));
2024
+ }
2025
+ }), mr = /* @__PURE__ */ Q(hr, [["__scopeId", "data-v-8e8c270a"]]), gr = { class: "kong-ui-app-page-header" }, yr = {
2026
+ key: 0,
2027
+ class: "page-header-breadcrumbs",
2028
+ "data-testid": "page-header-breadcrumbs"
2029
+ }, wr = { class: "page-header-title-section" }, kr = { class: "page-header-title-wrapper" }, Tr = {
2030
+ key: 0,
2031
+ class: "page-header-title-before",
2032
+ "data-testid": "page-header-title-before"
2033
+ }, _r = ["title"], Sr = {
2034
+ key: 1,
2035
+ class: "page-header-title-after",
2036
+ "data-testid": "page-header-title-after"
2037
+ }, Ir = {
2038
+ key: 0,
2039
+ class: "page-header-actions",
2040
+ "data-testid": "page-header-actions"
2041
+ }, Or = {
2042
+ key: 1,
2043
+ class: "page-header-section-below",
2044
+ "data-testid": "page-header-section-below"
2045
+ }, $r = /* @__PURE__ */ J({
2046
+ __name: "AppPageHeader",
2047
+ props: {
2048
+ title: {
2049
+ type: String,
2050
+ default: ""
2051
+ // Provide a fallback string to prevent the component unmounting from throwing an error
2052
+ },
2053
+ breadcrumbs: {
2054
+ type: Array,
2055
+ default: () => []
2056
+ }
2057
+ },
2058
+ setup(n) {
2059
+ const t = n, i = Xe(), a = k(() => {
2060
+ var u;
2061
+ return !!((u = t.breadcrumbs) != null && u.length);
2062
+ }), c = k(() => Object.keys(i).filter((u) => u.startsWith("icon-")));
2063
+ return (u, o) => {
2064
+ const v = pe("KBreadcrumbs");
2065
+ return p(), y("div", gr, [
2066
+ a.value ? (p(), y("div", yr, [
2067
+ Ae(v, {
2068
+ "item-max-width": "150",
2069
+ items: n.breadcrumbs
2070
+ }, Ue({ _: 2 }, [
2071
+ Te(c.value, (m) => ({
2072
+ name: m,
2073
+ fn: D(() => [
2074
+ T(u.$slots, m, {}, void 0, !0)
2075
+ ])
2076
+ }))
2077
+ ]), 1032, ["items"])
2078
+ ])) : S("", !0),
2079
+ I("div", wr, [
2080
+ I("div", kr, [
2081
+ u.$slots["title-before"] ? (p(), y("div", Tr, [
2082
+ T(u.$slots, "title-before", {}, void 0, !0)
2083
+ ])) : S("", !0),
2084
+ I("h1", {
2085
+ class: "page-header-title",
2086
+ "data-testid": "page-header-title",
2087
+ title: n.title
2088
+ }, q(n.title), 9, _r),
2089
+ u.$slots["title-after"] ? (p(), y("div", Sr, [
2090
+ T(u.$slots, "title-after", {}, void 0, !0)
2091
+ ])) : S("", !0)
2092
+ ]),
2093
+ u.$slots.actions ? (p(), y("div", Ir, [
2094
+ T(u.$slots, "actions", {}, void 0, !0)
2095
+ ])) : S("", !0)
2096
+ ]),
2097
+ u.$slots.below ? (p(), y("div", Or, [
2098
+ T(u.$slots, "below", {}, void 0, !0)
2099
+ ])) : S("", !0)
2100
+ ]);
2101
+ };
2102
+ }
2103
+ }), Pr = /* @__PURE__ */ Q($r, [["__scopeId", "data-v-204b7f98"]]), Cr = { class: "app-page-info-section-default-header" }, Er = {
2104
+ key: 1,
2105
+ class: "app-page-info-section-description",
2106
+ "data-testid": "app-page-info-section-description"
2107
+ }, Nr = {
2108
+ key: 0,
2109
+ class: "app-page-info-section-content",
2110
+ "data-testid": "app-page-info-section-content"
2111
+ }, Ar = /* @__PURE__ */ J({
2112
+ __name: "AppPageInfoSection",
2113
+ props: {
2114
+ collapsible: {
2115
+ type: Boolean,
2116
+ default: !0
2117
+ },
2118
+ title: {
2119
+ type: String,
2120
+ default: ""
2121
+ },
2122
+ description: {
2123
+ type: String,
2124
+ default: ""
2125
+ },
2126
+ titleTag: {
2127
+ type: String,
2128
+ default: "div",
2129
+ validator: (n) => Sn.includes(n)
2130
+ }
2131
+ },
2132
+ setup(n) {
2133
+ return (t, i) => (p(), K(He(n.collapsible ? "details" : "div"), {
2134
+ class: "app-page-info-section",
2135
+ "data-testid": "app-page-info-section"
2136
+ }, {
2137
+ default: D(() => [
2138
+ (p(), K(He(n.collapsible ? "summary" : "div"), {
2139
+ class: "app-page-info-section-header",
2140
+ "data-testid": "app-page-info-section-header"
2141
+ }, {
2142
+ default: D(() => [
2143
+ T(t.$slots, "header", {}, () => [
2144
+ I("div", Cr, [
2145
+ n.title ? (p(), K(He(n.titleTag), {
2146
+ key: 0,
2147
+ class: "app-page-info-section-title",
2148
+ "data-testid": "app-page-info-section-title"
2149
+ }, {
2150
+ default: D(() => [
2151
+ Ne(q(n.title), 1)
2152
+ ]),
2153
+ _: 1
2154
+ })) : S("", !0),
2155
+ n.description ? (p(), y("div", Er, q(n.description), 1)) : S("", !0)
2156
+ ])
2157
+ ]),
2158
+ n.collapsible ? (p(), K(Wt(_n), {
2159
+ key: 0,
2160
+ class: "app-page-info-section-chevron-icon",
2161
+ decorative: ""
2162
+ })) : t.$slots.actions ? T(t.$slots, "actions", { key: 1 }) : S("", !0)
2163
+ ]),
2164
+ _: 3
2165
+ })),
2166
+ t.$slots.default ? (p(), y("div", Nr, [
2167
+ T(t.$slots, "default")
2168
+ ])) : S("", !0)
2169
+ ]),
2170
+ _: 3
2171
+ }));
2172
+ }
2173
+ }), Mr = /* @__PURE__ */ Q(Ar, [["__scopeId", "data-v-21cd75da"]]), jr = {
2174
+ // Customize Vue plugin options as desired
2175
+ // Providing a `name` property allows for customizing the registered name of your component (useful if exporting a single component).
2176
+ install: (n, t = {}) => {
2177
+ n.component(t.name || "AppLayout", mr);
2178
+ }
2179
+ };
2180
+ export {
2181
+ xr as AccountDropdown,
2182
+ Br as AppAboutSection,
2183
+ Lr as AppError,
2184
+ mr as AppLayout,
2185
+ ai as AppNavbar,
2186
+ Pr as AppPageHeader,
2187
+ Mr as AppPageInfoSection,
2188
+ er as AppSidebar,
2189
+ nr as SidebarToggle,
2190
+ jr as default
2191
+ };