@kong-ui-public/entities-shared 3.33.3-pr.2665.4dd2b8e16.0 → 3.33.3-pr.2665.689af0ebe.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.
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { inject as Ut, ref as N, computed as T, unref as _, toValue as
|
|
1
|
+
import { inject as Ut, ref as N, computed as T, unref as _, toValue as ye, watch as be, toRef as Gn, provide as qt, defineComponent as z, createBlock as M, openBlock as p, resolveDynamicComponent as De, normalizeClass as fe, withCtx as k, createElementBlock as $, createCommentVNode as j, createElementVNode as B, toDisplayString as L, Fragment as ue, renderList as ce, resolveComponent as D, createVNode as R, createTextVNode as U, useCssVars as Ht, useId as zn, useSlots as Pe, renderSlot as P, createSlots as $e, normalizeProps as Qn, guardReactiveProps as Zn, mergeProps as Vt, onMounted as nt, onBeforeMount as it, withModifiers as Be, Teleport as Yt, onUnmounted as Xn, withDirectives as xe, vShow as Ce, withKeys as ei, warn as ti } from "vue";
|
|
2
2
|
import pt from "axios";
|
|
3
3
|
import { createI18n as ni, i18nTComponent as ii } from "@kong-ui-public/i18n";
|
|
4
4
|
import { BadgeMethodAppearances as ri, KExternalLink as ai, KButton as mt, KTruncate as oi, KBadge as li } from "@kong/kongponents";
|
|
5
|
-
import { BookIcon as Wt, LanguageShellIcon as
|
|
5
|
+
import { BookIcon as Wt, LanguageShellIcon as yt, LanguageBashIcon as gt, AddIcon as Jt, CloseIcon as si, ChevronDownIcon as ci, CopyIcon as ui } from "@kong/icons";
|
|
6
6
|
import { useRouter as di } from "vue-router";
|
|
7
|
-
var fi = /* @__PURE__ */ ((e) => (e.GatewayService = "service", e.Route = "route", e.Consumer = "consumer", e.ConsumerGroup = "consumer group", e.Plugin = "plugin", e.Upstream = "upstream", e.Certificate = "certificate", e.CACertificate = "ca certificate", e.SNI = "SNI", e.Key = "key", e.KeySet = "key set", e.Vault = "vault", e.Application = "application", e.Developer = "developer", e.acls = "ACL Credential", e["basic-auth"] = "Basic Auth Credential", e["key-auth"] = "Key Auth Credential", e["key-auth-enc"] = "Key Auth Encrypted Credential", e.oauth2 = "OAuth 2.0 Credential", e["hmac-auth"] = "HMAC Credential", e.jwt = "JWT Credential", e.Target = "target", e.Policy = "policy", e.Secret = "secret", e.RedisConfiguration = "redis configuration", e))(fi || {}), pi = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(pi || {}), me = /* @__PURE__ */ ((e) => (e[e.InitialLoad = 0] = "InitialLoad", e[e.Loading = 1] = "Loading", e[e.Idle = 2] = "Idle", e[e.NoResults = 3] = "NoResults", e[e.NoRecords = 4] = "NoRecords", e[e.Error = 5] = "Error", e))(me || {}),
|
|
8
|
-
const Ue = Object.values(
|
|
7
|
+
var fi = /* @__PURE__ */ ((e) => (e.GatewayService = "service", e.Route = "route", e.Consumer = "consumer", e.ConsumerGroup = "consumer group", e.Plugin = "plugin", e.Upstream = "upstream", e.Certificate = "certificate", e.CACertificate = "ca certificate", e.SNI = "SNI", e.Key = "key", e.KeySet = "key set", e.Vault = "vault", e.Application = "application", e.Developer = "developer", e.acls = "ACL Credential", e["basic-auth"] = "Basic Auth Credential", e["key-auth"] = "Key Auth Credential", e["key-auth-enc"] = "Key Auth Encrypted Credential", e.oauth2 = "OAuth 2.0 Credential", e["hmac-auth"] = "HMAC Credential", e.jwt = "JWT Credential", e.Target = "target", e.Policy = "policy", e.Secret = "secret", e.RedisConfiguration = "redis configuration", e))(fi || {}), pi = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(pi || {}), me = /* @__PURE__ */ ((e) => (e[e.InitialLoad = 0] = "InitialLoad", e[e.Loading = 1] = "Loading", e[e.Idle = 2] = "Idle", e[e.NoResults = 3] = "NoResults", e[e.NoRecords = 4] = "NoRecords", e[e.Error = 5] = "Error", e))(me || {}), Se = /* @__PURE__ */ ((e) => (e.CaCertificate = "ca_certificate", e.Certificate = "certificate", e.Consumer = "consumer", e.ConsumerGroup = "consumer_group", e.GatewayService = "service", e.Key = "key", e.KeySet = "set", e.Plugin = "plugin", e.Route = "route", e.SNI = "sni", e.Upstream = "upstream", e.Target = "target", e.Vault = "vault", e.Partial = "partial", e.BackendCluster = "backend_cluster", e.VirtualCluster = "virtual_cluster", e.Listener = "listener", e.ProducePolicy = "produce_policy", e.ConsumePolicy = "consume_policy", e.ClusterPolicy = "cluster_policy", e.ListenerPolicy = "listener_policy", e.SchemaRegistry = "schema_registry", e.StaticKey = "static_key", e.Other = "other", e))(Se || {});
|
|
8
|
+
const Ue = Object.values(Se), mi = [
|
|
9
9
|
"ca_certificate",
|
|
10
10
|
"certificate",
|
|
11
11
|
"consumer",
|
|
@@ -20,13 +20,13 @@ const Ue = Object.values(Ee), mi = [
|
|
|
20
20
|
"vault",
|
|
21
21
|
"partial"
|
|
22
22
|
/* Partial */
|
|
23
|
-
],
|
|
23
|
+
], yi = ["backend_cluster", "virtual_cluster", "listener", "produce_policy", "consume_policy", "cluster_policy", "listener_policy", "schema_registry", "static_key"];
|
|
24
24
|
var V = /* @__PURE__ */ ((e) => (e.ID = "id", e.IdArray = "id-array", e.Text = "plain-text", e.Date = "date", e.Redacted = "redacted", e.RedactedArray = "redacted-array", e.Json = "json", e.JsonArray = "json-array", e.BadgeTag = "badge-tag", e.CopyBadge = "copy-badge", e.BadgeStatus = "badge-status", e.BadgeMethod = "badge-method", e.LinkInternal = "link-internal", e.LinkExternal = "link-external", e))(V || {}), ae = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e.Policy = "policy", e))(ae || {});
|
|
25
|
-
const
|
|
25
|
+
const ht = [
|
|
26
26
|
"primary",
|
|
27
27
|
"secondary"
|
|
28
28
|
];
|
|
29
|
-
function
|
|
29
|
+
function gi() {
|
|
30
30
|
return {
|
|
31
31
|
getAxiosInstance: (e = {}) => {
|
|
32
32
|
try {
|
|
@@ -50,7 +50,7 @@ function hi() {
|
|
|
50
50
|
}
|
|
51
51
|
};
|
|
52
52
|
}
|
|
53
|
-
function
|
|
53
|
+
function hi() {
|
|
54
54
|
return {
|
|
55
55
|
debounce: (e, t) => {
|
|
56
56
|
let n;
|
|
@@ -100,7 +100,7 @@ function bi() {
|
|
|
100
100
|
};
|
|
101
101
|
}
|
|
102
102
|
function rt(e = {}) {
|
|
103
|
-
const { getAxiosInstance: t } =
|
|
103
|
+
const { getAxiosInstance: t } = gi();
|
|
104
104
|
return {
|
|
105
105
|
axiosInstance: t(e)
|
|
106
106
|
};
|
|
@@ -280,41 +280,41 @@ function Li(e, t, n, i = {
|
|
|
280
280
|
searchKeys: ["id"]
|
|
281
281
|
}) {
|
|
282
282
|
n || (n = "1000");
|
|
283
|
-
const { axiosInstance: r } = rt(e.axiosRequestConfig), { i18n: { t: o } } = qe(), { debounce: a } =
|
|
284
|
-
await
|
|
285
|
-
}, 200), l = N(!1), c = N(""), d = N(""), u = N([]),
|
|
283
|
+
const { axiosInstance: r } = rt(e.axiosRequestConfig), { i18n: { t: o } } = qe(), { debounce: a } = hi(), s = a(async (E) => {
|
|
284
|
+
await C(E);
|
|
285
|
+
}, 200), l = N(!1), c = N(""), d = N(""), u = N([]), m = N([]), g = N(void 0), y = T(() => {
|
|
286
286
|
const E = `${e.apiBaseUrl}${_(t)}`;
|
|
287
287
|
return e.app === "konnect" ? E.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" ? E.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : "") : E;
|
|
288
|
-
}), { isValidUuid: v } = Gt(),
|
|
288
|
+
}), { isValidUuid: v } = Gt(), h = async () => {
|
|
289
289
|
try {
|
|
290
290
|
l.value = !0;
|
|
291
|
-
const { data: E } = await r.get(`${
|
|
292
|
-
E != null && E.next || (
|
|
291
|
+
const { data: E } = await r.get(`${y.value}?size=${n}`);
|
|
292
|
+
E != null && E.next || (g.value = i.fetchedItemsKey in E ? E[i.fetchedItemsKey] : []), m.value = i.fetchedItemsKey in E ? E[i.fetchedItemsKey] : [], u.value = m.value;
|
|
293
293
|
} catch {
|
|
294
294
|
u.value = [], c.value = o("debouncedFilter.errors.fetch");
|
|
295
295
|
} finally {
|
|
296
296
|
l.value = !1;
|
|
297
297
|
}
|
|
298
|
-
},
|
|
298
|
+
}, A = N(""), C = async (E) => {
|
|
299
299
|
var W, X, S;
|
|
300
|
-
if (
|
|
301
|
-
if (
|
|
302
|
-
u.value =
|
|
300
|
+
if (A.value !== E) {
|
|
301
|
+
if (A.value = E ?? "", !E) {
|
|
302
|
+
u.value = m.value;
|
|
303
303
|
return;
|
|
304
304
|
}
|
|
305
|
-
if (
|
|
305
|
+
if (g.value === void 0)
|
|
306
306
|
try {
|
|
307
307
|
if (l.value = !0, c.value = "", d.value = "", e.app === "konnect") {
|
|
308
|
-
const w = `${
|
|
308
|
+
const w = `${y.value}/${E}`, { data: O } = await r.get(`${w}?size=${n}`);
|
|
309
309
|
i.fetchedItemsKey in O ? u.value = O[i.fetchedItemsKey] : O != null && O[i.exactMatchKey ?? "id"] ? u.value = [O] : u.value = [];
|
|
310
310
|
} else {
|
|
311
311
|
const w = [];
|
|
312
312
|
v(E) && i.searchKeys.includes("id") ? w.push((async () => {
|
|
313
|
-
const { data: b } = await r.get(`${
|
|
313
|
+
const { data: b } = await r.get(`${y.value}/${E}`);
|
|
314
314
|
return [b[i.fetchedItemsKey] ?? b];
|
|
315
315
|
})()) : w.push(
|
|
316
316
|
...i.searchKeys.filter((b) => b !== "id").map(async (b) => {
|
|
317
|
-
const { data: x } = await r.get(`${
|
|
317
|
+
const { data: x } = await r.get(`${y.value}?${b}=${E}`);
|
|
318
318
|
return x[i.fetchedItemsKey];
|
|
319
319
|
})
|
|
320
320
|
);
|
|
@@ -332,7 +332,7 @@ function Li(e, t, n, i = {
|
|
|
332
332
|
l.value = !1;
|
|
333
333
|
}
|
|
334
334
|
else
|
|
335
|
-
l.value = !0, d.value = "", u.value = (S =
|
|
335
|
+
l.value = !0, d.value = "", u.value = (S = g.value) == null ? void 0 : S.filter((w) => {
|
|
336
336
|
var f;
|
|
337
337
|
let O = !1;
|
|
338
338
|
for (const b of i.searchKeys) {
|
|
@@ -348,8 +348,8 @@ function Li(e, t, n, i = {
|
|
|
348
348
|
error: c,
|
|
349
349
|
validationError: d,
|
|
350
350
|
results: u,
|
|
351
|
-
allRecords:
|
|
352
|
-
loadItems:
|
|
351
|
+
allRecords: g,
|
|
352
|
+
loadItems: h,
|
|
353
353
|
debouncedQueryChange: s
|
|
354
354
|
};
|
|
355
355
|
}
|
|
@@ -444,47 +444,47 @@ function Ri(e) {
|
|
|
444
444
|
}
|
|
445
445
|
function zt(e, t) {
|
|
446
446
|
const n = T(() => {
|
|
447
|
-
const r =
|
|
447
|
+
const r = ye(e);
|
|
448
448
|
return r.app === "konnect" || !!r.isExactMatch;
|
|
449
449
|
}), i = T(() => {
|
|
450
|
-
const r =
|
|
450
|
+
const r = ye(t);
|
|
451
451
|
return r.startsWith("/") ? new URL(`${window.location.origin}${r}`) : new URL(r);
|
|
452
452
|
});
|
|
453
453
|
return (r) => {
|
|
454
454
|
const { page: o, pageSize: a, offset: s, sortColumnKey: l, sortColumnOrder: c, query: d } = r;
|
|
455
455
|
try {
|
|
456
456
|
let u = new URL(i.value.href);
|
|
457
|
-
return n.value && d ? (u.search = "", u =
|
|
458
|
-
u.searchParams.append(
|
|
457
|
+
return n.value && d ? (u.search = "", u = ye(e).isExactMatch ? new URL(`${u.href}/${d}`) : new URL(`${u.href}?filter[name][contains]=${d}`)) : (n.value || new URLSearchParams(d).forEach((m, g) => {
|
|
458
|
+
u.searchParams.append(g, m);
|
|
459
459
|
}), l && u.searchParams.append("sort_by", l), c === "desc" && u.searchParams.append("sort_desc", "1"), u.searchParams.append("size", String(a))), s && o !== 1 && u.searchParams.append("offset", String(s)), u.href;
|
|
460
460
|
} catch (u) {
|
|
461
|
-
return console.error("RouteList(fetcher)", u),
|
|
461
|
+
return console.error("RouteList(fetcher)", u), ye(t);
|
|
462
462
|
}
|
|
463
463
|
};
|
|
464
464
|
}
|
|
465
465
|
const vt = /* @__PURE__ */ new Map();
|
|
466
466
|
function Ni(e, t, n) {
|
|
467
|
-
const i = N(!0), r =
|
|
467
|
+
const i = N(!0), r = ye(e), { axiosInstance: o } = rt(r.axiosRequestConfig), a = zt(e, t), s = N({
|
|
468
468
|
status: me.Idle
|
|
469
469
|
}), l = async (u) => {
|
|
470
|
-
var
|
|
471
|
-
const
|
|
470
|
+
var g;
|
|
471
|
+
const m = ye(n) || "data";
|
|
472
472
|
try {
|
|
473
473
|
s.value = i.value ? { status: me.InitialLoad } : { status: me.Loading }, i.value = !1;
|
|
474
|
-
let
|
|
475
|
-
|
|
476
|
-
const v = await o.get(
|
|
474
|
+
let y = a(u);
|
|
475
|
+
y.includes("filter[name]") && (y = `${y}&page[size]=${u.pageSize}&page[number]=${u.page}`);
|
|
476
|
+
const v = await o.get(y);
|
|
477
477
|
if (v.status >= 400)
|
|
478
478
|
throw v;
|
|
479
|
-
const
|
|
480
|
-
let
|
|
481
|
-
|
|
479
|
+
const h = v.data, A = m && m.replace(/[^\w-_]/gi, "");
|
|
480
|
+
let C;
|
|
481
|
+
h[A] ? C = Array.isArray(h[A]) ? h[A] : [h[A]] : Array.isArray(h) ? C = h : C = Object.keys(h).length ? [h] : [];
|
|
482
482
|
const E = {
|
|
483
|
-
data:
|
|
484
|
-
total:
|
|
485
|
-
...
|
|
483
|
+
data: C,
|
|
484
|
+
total: C.length,
|
|
485
|
+
...h.offset ? {
|
|
486
486
|
pagination: {
|
|
487
|
-
offset:
|
|
487
|
+
offset: h.offset
|
|
488
488
|
}
|
|
489
489
|
} : null
|
|
490
490
|
};
|
|
@@ -495,19 +495,19 @@ function Ni(e, t, n) {
|
|
|
495
495
|
status: me.Idle,
|
|
496
496
|
response: E
|
|
497
497
|
}, E;
|
|
498
|
-
} catch (
|
|
498
|
+
} catch (y) {
|
|
499
499
|
const v = {
|
|
500
500
|
data: [],
|
|
501
501
|
total: 0
|
|
502
502
|
};
|
|
503
|
-
return u.query && (((
|
|
503
|
+
return u.query && (((g = y.response) == null ? void 0 : g.status) === 404 || y.status === 404) ? (s.value = {
|
|
504
504
|
status: me.NoResults,
|
|
505
505
|
response: v,
|
|
506
|
-
error:
|
|
506
|
+
error: y.response ? y : { response: y }
|
|
507
507
|
}, v) : (s.value = {
|
|
508
508
|
status: me.Error,
|
|
509
509
|
response: v,
|
|
510
|
-
error:
|
|
510
|
+
error: y.response ? y : { response: y }
|
|
511
511
|
}, v);
|
|
512
512
|
}
|
|
513
513
|
}, c = r.cacheIdentifier, d = Qt(c);
|
|
@@ -607,14 +607,14 @@ function Gi(e) {
|
|
|
607
607
|
let t = "";
|
|
608
608
|
const n = N(!1), i = N(null), r = T(() => {
|
|
609
609
|
let a;
|
|
610
|
-
return n.value ? a = !0 : i.value ? a = i.value.hasData || e &&
|
|
610
|
+
return n.value ? a = !0 : i.value ? a = i.value.hasData || e && ye(e) : a = !1, !a;
|
|
611
611
|
});
|
|
612
612
|
return {
|
|
613
613
|
tableState: i,
|
|
614
614
|
hasRecords: n,
|
|
615
615
|
hideTableToolbar: r,
|
|
616
616
|
handleStateChange: (a) => {
|
|
617
|
-
a.hasData ? n.value = !0 : a.state === "success" && !a.hasData && (!e || !t) && (n.value = !1), e && (t =
|
|
617
|
+
a.hasData ? n.value = !0 : a.state === "success" && !a.hasData && (!e || !t) && (n.value = !1), e && (t = ye(e)), i.value = { ...a };
|
|
618
618
|
}
|
|
619
619
|
};
|
|
620
620
|
}
|
|
@@ -663,14 +663,14 @@ const Y = {
|
|
|
663
663
|
var l;
|
|
664
664
|
return t.isArrayItem ? (l = o.value) != null && l.name ? i(o.value.name, "_") : n("baseConfigCard.general.entryTitle", { index: t.index }) : "";
|
|
665
665
|
});
|
|
666
|
-
return (l, c) => (
|
|
666
|
+
return (l, c) => (p(), M(De(e.isArrayItem ? "fieldset" : "div"), {
|
|
667
667
|
class: fe(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
668
668
|
}, {
|
|
669
|
-
default:
|
|
670
|
-
e.isArrayItem ? (
|
|
669
|
+
default: k(() => [
|
|
670
|
+
e.isArrayItem ? (p(), $("legend", zi, [
|
|
671
671
|
B("b", null, L(s.value), 1)
|
|
672
672
|
])) : j("", !0),
|
|
673
|
-
(
|
|
673
|
+
(p(!0), $(ue, null, ce(Object.keys(a.value), (d, u) => (p(), M(tn, {
|
|
674
674
|
key: `${r.value}-property-${u}`,
|
|
675
675
|
item: {
|
|
676
676
|
key: d,
|
|
@@ -700,13 +700,13 @@ const Y = {
|
|
|
700
700
|
const { i18n: { t } } = Y.useI18n();
|
|
701
701
|
return (n, i) => {
|
|
702
702
|
const r = D("KButton");
|
|
703
|
-
return
|
|
703
|
+
return p(), $("div", null, [
|
|
704
704
|
R(r, {
|
|
705
705
|
appearance: "tertiary",
|
|
706
706
|
class: "navigation-button",
|
|
707
707
|
onClick: i[0] || (i[0] = (o) => n.$emit("navigation-click", e.item))
|
|
708
708
|
}, {
|
|
709
|
-
default:
|
|
709
|
+
default: k(() => [
|
|
710
710
|
U(L(e.item.value || _(t)("baseConfigCard.commonFields.link")), 1)
|
|
711
711
|
]),
|
|
712
712
|
_: 1
|
|
@@ -726,17 +726,17 @@ const Y = {
|
|
|
726
726
|
const { i18n: { t } } = Y.useI18n();
|
|
727
727
|
return (n, i) => {
|
|
728
728
|
const r = D("KBadge");
|
|
729
|
-
return
|
|
729
|
+
return p(), M(r, {
|
|
730
730
|
appearance: e.status ? "success" : "neutral"
|
|
731
731
|
}, {
|
|
732
|
-
default:
|
|
732
|
+
default: k(() => [
|
|
733
733
|
U(L(e.status ? _(t)("baseConfigCard.statusBadge.enabledLabel") : _(t)("baseConfigCard.statusBadge.disabledLabel")), 1)
|
|
734
734
|
]),
|
|
735
735
|
_: 1
|
|
736
736
|
}, 8, ["appearance"]);
|
|
737
737
|
};
|
|
738
738
|
}
|
|
739
|
-
}), tr = "#0044f4", nr = "#e0e4ea", ir = "#afb7c5", rr = "#0044f4", ar = "1px", or = "16px", lr = "20px", sr = { class: "config-card-details-row" }, cr = ["data-testid"], ur = ["data-testid"], dr = ["data-testid"], fr = ["data-testid"], pr = { key: 1 }, mr = ["data-testid"],
|
|
739
|
+
}), tr = "#0044f4", nr = "#e0e4ea", ir = "#afb7c5", rr = "#0044f4", ar = "1px", or = "16px", lr = "20px", sr = { class: "config-card-details-row" }, cr = ["data-testid"], ur = ["data-testid"], dr = ["data-testid"], fr = ["data-testid"], pr = { key: 1 }, mr = ["data-testid"], yr = ["data-testid"], gr = ["data-testid"], hr = ["data-testid"], vr = {
|
|
740
740
|
name: "ConfigCardItem",
|
|
741
741
|
components: { JsonCardItem: en, StatusBadge: er, InternalLinkItem: Xi }
|
|
742
742
|
}, br = /* @__PURE__ */ z({
|
|
@@ -760,16 +760,16 @@ const Y = {
|
|
|
760
760
|
emits: ["navigation-click"],
|
|
761
761
|
setup(e, { emit: t }) {
|
|
762
762
|
Ht((W) => ({
|
|
763
|
-
v70f369b3:
|
|
763
|
+
v70f369b3: m.value ? "none" : `solid ${_(ar)} ${_(nr)}`,
|
|
764
764
|
v67c2fae6: u.value && c.value ? "block" : "flex",
|
|
765
765
|
v847b138c: u.value && c.value ? "100%" : n.slim ? "50%" : "25%",
|
|
766
766
|
v847687d6: u.value && c.value ? "100%" : n.slim ? "50%" : "75%"
|
|
767
767
|
}));
|
|
768
|
-
const n = e, i = t, r = zn(), o = Pe(), { i18n: { t: a, formatIsoDate: s, formatUnixTimeStamp: l } } = Y.useI18n(), c = T(() => n.item.value !== void 0 && n.item.value !== null && n.item.value !== ""), d = T(() => !!(n.item.tooltip || o["label-tooltip"])), u = T(() => n.item.type === V.Json || n.item.type === V.JsonArray),
|
|
768
|
+
const n = e, i = t, r = zn(), o = Pe(), { i18n: { t: a, formatIsoDate: s, formatUnixTimeStamp: l } } = Y.useI18n(), c = T(() => n.item.value !== void 0 && n.item.value !== null && n.item.value !== ""), d = T(() => !!(n.item.tooltip || o["label-tooltip"])), u = T(() => n.item.type === V.Json || n.item.type === V.JsonArray), m = T(() => n.item.type === V.JsonArray), g = Y.useSubSchema(n.item.key), y = T(() => {
|
|
769
769
|
var W;
|
|
770
|
-
return n.item.type ? n.item.type : (W =
|
|
770
|
+
return n.item.type ? n.item.type : (W = g == null ? void 0 : g.value) != null && W.encrypted ? V.Redacted : void 0;
|
|
771
771
|
}), v = T(() => {
|
|
772
|
-
switch (
|
|
772
|
+
switch (y.value) {
|
|
773
773
|
case V.ID:
|
|
774
774
|
return {
|
|
775
775
|
tag: "KCopy",
|
|
@@ -899,24 +899,24 @@ const Y = {
|
|
|
899
899
|
text: n.item.value
|
|
900
900
|
};
|
|
901
901
|
}
|
|
902
|
-
}),
|
|
902
|
+
}), h = N(), A = N(), { isTruncated: C } = Y.useTruncationDetector(h), { isTruncated: E } = Y.useTruncationDetector(A);
|
|
903
903
|
return (W, X) => {
|
|
904
904
|
const S = D("KTooltip"), w = D("KLabel"), O = D("KBadge"), f = D("KCopy");
|
|
905
|
-
return
|
|
905
|
+
return p(), $("div", sr, [
|
|
906
906
|
B("div", {
|
|
907
907
|
class: "config-card-details-label",
|
|
908
908
|
"data-testid": `${e.item.key}-label`
|
|
909
909
|
}, [
|
|
910
910
|
P(W.$slots, "label", { item: e.item }, () => [
|
|
911
|
-
R(w, { "tooltip-attributes": { maxWidth: "500px" } },
|
|
912
|
-
default:
|
|
911
|
+
R(w, { "tooltip-attributes": { maxWidth: "500px" } }, $e({
|
|
912
|
+
default: k(() => [
|
|
913
913
|
R(S, {
|
|
914
|
-
text: _(
|
|
914
|
+
text: _(C) ? e.item.label : ""
|
|
915
915
|
}, {
|
|
916
|
-
default:
|
|
916
|
+
default: k(() => [
|
|
917
917
|
B("span", {
|
|
918
918
|
ref_key: "labelContent",
|
|
919
|
-
ref:
|
|
919
|
+
ref: h,
|
|
920
920
|
class: "label-content"
|
|
921
921
|
}, L(e.item.label), 513)
|
|
922
922
|
]),
|
|
@@ -927,7 +927,7 @@ const Y = {
|
|
|
927
927
|
}, [
|
|
928
928
|
d.value ? {
|
|
929
929
|
name: "tooltip",
|
|
930
|
-
fn:
|
|
930
|
+
fn: k(() => [
|
|
931
931
|
B("div", {
|
|
932
932
|
"data-testid": `${e.item.key}-label-tooltip`
|
|
933
933
|
}, [
|
|
@@ -948,69 +948,69 @@ const Y = {
|
|
|
948
948
|
P(W.$slots, e.item.key, {
|
|
949
949
|
rowValue: e.item.value
|
|
950
950
|
}, () => [
|
|
951
|
-
c.value ? (
|
|
952
|
-
(
|
|
953
|
-
default:
|
|
954
|
-
v.value.additionalComponent === "KBadge" ? (
|
|
951
|
+
c.value ? (p(), $("div", pr, [
|
|
952
|
+
(p(), M(De(v.value.tag), Qn(Zn(v.value.attrs)), {
|
|
953
|
+
default: k(() => [
|
|
954
|
+
v.value.additionalComponent === "KBadge" ? (p(), $("div", {
|
|
955
955
|
key: 0,
|
|
956
956
|
"data-testid": `${e.item.key}-badge-tags`
|
|
957
957
|
}, [
|
|
958
|
-
(
|
|
958
|
+
(p(!0), $(ue, null, ce(e.item.value, (b, x) => (p(), M(O, {
|
|
959
959
|
key: `${e.item.key}-badge-tag-${x}`,
|
|
960
960
|
class: "config-badge",
|
|
961
961
|
"data-testid": `${e.item.key}-badge-tag-${x}`,
|
|
962
962
|
tooltip: b,
|
|
963
963
|
"truncation-tooltip": ""
|
|
964
964
|
}, {
|
|
965
|
-
default:
|
|
965
|
+
default: k(() => [
|
|
966
966
|
U(L(b), 1)
|
|
967
967
|
]),
|
|
968
968
|
_: 2
|
|
969
969
|
}, 1032, ["data-testid", "tooltip"]))), 128))
|
|
970
|
-
], 8, mr)) : v.value.additionalComponent === "KCopy" ? (
|
|
970
|
+
], 8, mr)) : v.value.additionalComponent === "KCopy" ? (p(), $("div", {
|
|
971
971
|
key: 1,
|
|
972
972
|
class: "copy-uuid-array",
|
|
973
973
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
974
974
|
}, [
|
|
975
|
-
(
|
|
975
|
+
(p(!0), $(ue, null, ce(e.item.value, (b, x) => (p(), M(f, Vt({ ref_for: !0 }, v.value.childAttrs, {
|
|
976
976
|
key: `${e.item.key}-copy-uuid-${x}`,
|
|
977
977
|
"data-testid": `${e.item.key}-copy-uuid-${x}`,
|
|
978
978
|
text: b
|
|
979
979
|
}), null, 16, ["data-testid", "text"]))), 128))
|
|
980
|
-
], 8,
|
|
980
|
+
], 8, yr)) : v.value.additionalComponent === "KMethodBadge" ? (p(), $("div", {
|
|
981
981
|
key: 2,
|
|
982
982
|
class: "method-badge-array",
|
|
983
983
|
"data-testid": `${e.item.key}-badge-methods`
|
|
984
984
|
}, [
|
|
985
|
-
(
|
|
985
|
+
(p(!0), $(ue, null, ce(e.item.value, (b, x) => (p(), M(O, {
|
|
986
986
|
key: `${e.item.key}-badge-method-${x}`,
|
|
987
987
|
appearance: Object.values(_(ri)).includes(b.toLowerCase()) ? b.toLowerCase() : "custom",
|
|
988
988
|
class: "config-badge",
|
|
989
989
|
"data-testid": `${e.item.key}-badge-method-${x}`
|
|
990
990
|
}, {
|
|
991
|
-
default:
|
|
991
|
+
default: k(() => [
|
|
992
992
|
U(L(b), 1)
|
|
993
993
|
]),
|
|
994
994
|
_: 2
|
|
995
995
|
}, 1032, ["appearance", "data-testid"]))), 128))
|
|
996
|
-
], 8,
|
|
996
|
+
], 8, gr)) : v.value.additionalComponent === "JsonCardItem" ? (p(), $("div", {
|
|
997
997
|
key: 3,
|
|
998
998
|
"data-testid": `${n.item.key}-json-array-content`
|
|
999
999
|
}, [
|
|
1000
|
-
(
|
|
1000
|
+
(p(!0), $(ue, null, ce(e.item.value, (b, x) => (p(), M(en, {
|
|
1001
1001
|
key: `json-array-item-${x}`,
|
|
1002
1002
|
index: x,
|
|
1003
1003
|
"is-array-item": "",
|
|
1004
1004
|
item: b
|
|
1005
1005
|
}, null, 8, ["index", "item"]))), 128))
|
|
1006
|
-
], 8,
|
|
1006
|
+
], 8, hr)) : (p(), M(S, {
|
|
1007
1007
|
key: 4,
|
|
1008
1008
|
text: _(E) ? e.item.value : ""
|
|
1009
1009
|
}, {
|
|
1010
|
-
default:
|
|
1010
|
+
default: k(() => [
|
|
1011
1011
|
B("span", {
|
|
1012
1012
|
ref_key: "textContent",
|
|
1013
|
-
ref:
|
|
1013
|
+
ref: A,
|
|
1014
1014
|
class: fe(["attrs-data-text", { truncated: e.truncated }])
|
|
1015
1015
|
}, L(v.value.text), 3)
|
|
1016
1016
|
]),
|
|
@@ -1019,7 +1019,7 @@ const Y = {
|
|
|
1019
1019
|
]),
|
|
1020
1020
|
_: 1
|
|
1021
1021
|
}, 16))
|
|
1022
|
-
])) : (
|
|
1022
|
+
])) : (p(), $("div", {
|
|
1023
1023
|
key: 0,
|
|
1024
1024
|
"data-testid": `${e.item.key}-no-value`
|
|
1025
1025
|
}, " – ", 8, fr))
|
|
@@ -1071,12 +1071,12 @@ const Y = {
|
|
|
1071
1071
|
});
|
|
1072
1072
|
return (r, o) => {
|
|
1073
1073
|
const a = D("KBadge"), s = D("KCodeBlock");
|
|
1074
|
-
return
|
|
1075
|
-
t.fetcherUrl ? (
|
|
1074
|
+
return p(), $("div", xr, [
|
|
1075
|
+
t.fetcherUrl ? (p(), $("div", Cr, [
|
|
1076
1076
|
R(a, {
|
|
1077
1077
|
appearance: t.requestMethod
|
|
1078
1078
|
}, {
|
|
1079
|
-
default:
|
|
1079
|
+
default: k(() => [
|
|
1080
1080
|
U(L(t.requestMethod), 1)
|
|
1081
1081
|
]),
|
|
1082
1082
|
_: 1
|
|
@@ -1089,7 +1089,7 @@ const Y = {
|
|
|
1089
1089
|
theme: "dark"
|
|
1090
1090
|
}, null, 8, ["code"])
|
|
1091
1091
|
])) : j("", !0),
|
|
1092
|
-
t.entityRecord ? (
|
|
1092
|
+
t.entityRecord ? (p(), M(s, {
|
|
1093
1093
|
key: 1,
|
|
1094
1094
|
id: "json-codeblock",
|
|
1095
1095
|
class: fe({ "json-content": t.fetcherUrl }),
|
|
@@ -1514,24 +1514,24 @@ var mn = new ne("tag:yaml.org,2002:float", {
|
|
|
1514
1514
|
predicate: ia,
|
|
1515
1515
|
represent: na,
|
|
1516
1516
|
defaultStyle: "lowercase"
|
|
1517
|
-
}),
|
|
1517
|
+
}), yn = un.extend({
|
|
1518
1518
|
implicit: [
|
|
1519
1519
|
dn,
|
|
1520
1520
|
fn,
|
|
1521
1521
|
pn,
|
|
1522
1522
|
mn
|
|
1523
1523
|
]
|
|
1524
|
-
}),
|
|
1524
|
+
}), gn = yn, hn = new RegExp(
|
|
1525
1525
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1526
1526
|
), vn = new RegExp(
|
|
1527
1527
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"
|
|
1528
1528
|
);
|
|
1529
1529
|
function ra(e) {
|
|
1530
|
-
return e === null ? !1 :
|
|
1530
|
+
return e === null ? !1 : hn.exec(e) !== null || vn.exec(e) !== null;
|
|
1531
1531
|
}
|
|
1532
1532
|
function aa(e) {
|
|
1533
|
-
var t, n, i, r, o, a, s, l = 0, c = null, d, u,
|
|
1534
|
-
if (t =
|
|
1533
|
+
var t, n, i, r, o, a, s, l = 0, c = null, d, u, m;
|
|
1534
|
+
if (t = hn.exec(e), t === null && (t = vn.exec(e)), t === null) throw new Error("Date resolve error");
|
|
1535
1535
|
if (n = +t[1], i = +t[2] - 1, r = +t[3], !t[4])
|
|
1536
1536
|
return new Date(Date.UTC(n, i, r));
|
|
1537
1537
|
if (o = +t[4], a = +t[5], s = +t[6], t[7]) {
|
|
@@ -1539,7 +1539,7 @@ function aa(e) {
|
|
|
1539
1539
|
l += "0";
|
|
1540
1540
|
l = +l;
|
|
1541
1541
|
}
|
|
1542
|
-
return t[9] && (d = +t[10], u = +(t[11] || 0), c = (d * 60 + u) * 6e4, t[9] === "-" && (c = -c)),
|
|
1542
|
+
return t[9] && (d = +t[10], u = +(t[11] || 0), c = (d * 60 + u) * 6e4, t[9] === "-" && (c = -c)), m = new Date(Date.UTC(n, i, r, o, a, s, l)), c && m.setTime(m.getTime() - c), m;
|
|
1543
1543
|
}
|
|
1544
1544
|
function oa(e) {
|
|
1545
1545
|
return e.toISOString();
|
|
@@ -1606,19 +1606,19 @@ function ma(e) {
|
|
|
1606
1606
|
}
|
|
1607
1607
|
return !0;
|
|
1608
1608
|
}
|
|
1609
|
-
function
|
|
1609
|
+
function ya(e) {
|
|
1610
1610
|
return e !== null ? e : [];
|
|
1611
1611
|
}
|
|
1612
1612
|
var kn = new ne("tag:yaml.org,2002:omap", {
|
|
1613
1613
|
kind: "sequence",
|
|
1614
1614
|
resolve: ma,
|
|
1615
|
-
construct:
|
|
1616
|
-
}),
|
|
1617
|
-
function
|
|
1615
|
+
construct: ya
|
|
1616
|
+
}), ga = Object.prototype.toString;
|
|
1617
|
+
function ha(e) {
|
|
1618
1618
|
if (e === null) return !0;
|
|
1619
1619
|
var t, n, i, r, o, a = e;
|
|
1620
1620
|
for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1) {
|
|
1621
|
-
if (i = a[t],
|
|
1621
|
+
if (i = a[t], ga.call(i) !== "[object Object]" || (r = Object.keys(i), r.length !== 1)) return !1;
|
|
1622
1622
|
o[t] = [r[0], i[r[0]]];
|
|
1623
1623
|
}
|
|
1624
1624
|
return !0;
|
|
@@ -1632,7 +1632,7 @@ function va(e) {
|
|
|
1632
1632
|
}
|
|
1633
1633
|
var An = new ne("tag:yaml.org,2002:pairs", {
|
|
1634
1634
|
kind: "sequence",
|
|
1635
|
-
resolve:
|
|
1635
|
+
resolve: ha,
|
|
1636
1636
|
construct: va
|
|
1637
1637
|
}), ba = Object.prototype.hasOwnProperty;
|
|
1638
1638
|
function xa(e) {
|
|
@@ -1650,7 +1650,7 @@ var _n = new ne("tag:yaml.org,2002:set", {
|
|
|
1650
1650
|
kind: "mapping",
|
|
1651
1651
|
resolve: xa,
|
|
1652
1652
|
construct: Ca
|
|
1653
|
-
}), ot =
|
|
1653
|
+
}), ot = gn.extend({
|
|
1654
1654
|
implicit: [
|
|
1655
1655
|
bn,
|
|
1656
1656
|
xn
|
|
@@ -1661,7 +1661,7 @@ var _n = new ne("tag:yaml.org,2002:set", {
|
|
|
1661
1661
|
An,
|
|
1662
1662
|
_n
|
|
1663
1663
|
]
|
|
1664
|
-
}),
|
|
1664
|
+
}), he = Object.prototype.hasOwnProperty, Ke = 1, wn = 2, Sn = 3, Re = 4, Je = 1, ka = 2, St = 3, Aa = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, _a = /[\x85\u2028\u2029]/, wa = /[,\[\]\{\}]/, $n = /^(?:!|!!|![a-z\-]+!)$/i, Tn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1665
1665
|
function $t(e) {
|
|
1666
1666
|
return Object.prototype.toString.call(e);
|
|
1667
1667
|
}
|
|
@@ -1735,7 +1735,7 @@ var Et = {
|
|
|
1735
1735
|
},
|
|
1736
1736
|
TAG: function(t, n, i) {
|
|
1737
1737
|
var r, o;
|
|
1738
|
-
i.length !== 2 && F(t, "TAG directive accepts exactly two arguments"), r = i[0], o = i[1], $n.test(r) || F(t, "ill-formed tag handle (first argument) of the TAG directive"),
|
|
1738
|
+
i.length !== 2 && F(t, "TAG directive accepts exactly two arguments"), r = i[0], o = i[1], $n.test(r) || F(t, "ill-formed tag handle (first argument) of the TAG directive"), he.call(t.tagMap, r) && F(t, 'there is a previously declared suffix for "' + r + '" tag handle'), Tn.test(o) || F(t, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1739
1739
|
try {
|
|
1740
1740
|
o = decodeURIComponent(o);
|
|
1741
1741
|
} catch {
|
|
@@ -1744,7 +1744,7 @@ var Et = {
|
|
|
1744
1744
|
t.tagMap[r] = o;
|
|
1745
1745
|
}
|
|
1746
1746
|
};
|
|
1747
|
-
function
|
|
1747
|
+
function ge(e, t, n, i) {
|
|
1748
1748
|
var r, o, a, s;
|
|
1749
1749
|
if (t < n) {
|
|
1750
1750
|
if (s = e.input.slice(t, n), i)
|
|
@@ -1757,7 +1757,7 @@ function he(e, t, n, i) {
|
|
|
1757
1757
|
function It(e, t, n, i) {
|
|
1758
1758
|
var r, o, a, s;
|
|
1759
1759
|
for (ee.isObject(n) || F(e, "cannot merge mappings; the provided source object is unacceptable"), r = Object.keys(n), a = 0, s = r.length; a < s; a += 1)
|
|
1760
|
-
o = r[a],
|
|
1760
|
+
o = r[a], he.call(t, o) || (En(t, o, n[o]), i[o] = !0);
|
|
1761
1761
|
}
|
|
1762
1762
|
function we(e, t, n, i, r, o, a, s, l) {
|
|
1763
1763
|
var c, d;
|
|
@@ -1771,7 +1771,7 @@ function we(e, t, n, i, r, o, a, s, l) {
|
|
|
1771
1771
|
else
|
|
1772
1772
|
It(e, t, o, n);
|
|
1773
1773
|
else
|
|
1774
|
-
!e.json && !
|
|
1774
|
+
!e.json && !he.call(n, r) && he.call(t, r) && (e.line = a || e.line, e.lineStart = s || e.lineStart, e.position = l || e.position, F(e, "duplicated mapping key")), En(t, r, o), delete n[r];
|
|
1775
1775
|
return t;
|
|
1776
1776
|
}
|
|
1777
1777
|
function lt(e) {
|
|
@@ -1803,31 +1803,31 @@ function st(e, t) {
|
|
|
1803
1803
|
`, t - 1));
|
|
1804
1804
|
}
|
|
1805
1805
|
function Fa(e, t, n) {
|
|
1806
|
-
var i, r, o, a, s, l, c, d, u = e.kind,
|
|
1807
|
-
if (
|
|
1806
|
+
var i, r, o, a, s, l, c, d, u = e.kind, m = e.result, g;
|
|
1807
|
+
if (g = e.input.charCodeAt(e.position), se(g) || _e(g) || g === 35 || g === 38 || g === 42 || g === 33 || g === 124 || g === 62 || g === 39 || g === 34 || g === 37 || g === 64 || g === 96 || (g === 63 || g === 45) && (r = e.input.charCodeAt(e.position + 1), se(r) || n && _e(r)))
|
|
1808
1808
|
return !1;
|
|
1809
|
-
for (e.kind = "scalar", e.result = "", o = a = e.position, s = !1;
|
|
1810
|
-
if (
|
|
1809
|
+
for (e.kind = "scalar", e.result = "", o = a = e.position, s = !1; g !== 0; ) {
|
|
1810
|
+
if (g === 58) {
|
|
1811
1811
|
if (r = e.input.charCodeAt(e.position + 1), se(r) || n && _e(r))
|
|
1812
1812
|
break;
|
|
1813
|
-
} else if (
|
|
1813
|
+
} else if (g === 35) {
|
|
1814
1814
|
if (i = e.input.charCodeAt(e.position - 1), se(i))
|
|
1815
1815
|
break;
|
|
1816
1816
|
} else {
|
|
1817
|
-
if (e.position === e.lineStart && He(e) || n && _e(
|
|
1817
|
+
if (e.position === e.lineStart && He(e) || n && _e(g))
|
|
1818
1818
|
break;
|
|
1819
|
-
if (de(
|
|
1819
|
+
if (de(g))
|
|
1820
1820
|
if (l = e.line, c = e.lineStart, d = e.lineIndent, Z(e, !1, -1), e.lineIndent >= t) {
|
|
1821
|
-
s = !0,
|
|
1821
|
+
s = !0, g = e.input.charCodeAt(e.position);
|
|
1822
1822
|
continue;
|
|
1823
1823
|
} else {
|
|
1824
1824
|
e.position = a, e.line = l, e.lineStart = c, e.lineIndent = d;
|
|
1825
1825
|
break;
|
|
1826
1826
|
}
|
|
1827
1827
|
}
|
|
1828
|
-
s && (
|
|
1828
|
+
s && (ge(e, o, a, !1), st(e, e.line - l), o = a = e.position, s = !1), ve(g) || (a = e.position + 1), g = e.input.charCodeAt(++e.position);
|
|
1829
1829
|
}
|
|
1830
|
-
return
|
|
1830
|
+
return ge(e, o, a, !1), e.result ? !0 : (e.kind = u, e.result = m, !1);
|
|
1831
1831
|
}
|
|
1832
1832
|
function Oa(e, t) {
|
|
1833
1833
|
var n, i, r;
|
|
@@ -1835,11 +1835,11 @@ function Oa(e, t) {
|
|
|
1835
1835
|
return !1;
|
|
1836
1836
|
for (e.kind = "scalar", e.result = "", e.position++, i = r = e.position; (n = e.input.charCodeAt(e.position)) !== 0; )
|
|
1837
1837
|
if (n === 39)
|
|
1838
|
-
if (
|
|
1838
|
+
if (ge(e, i, e.position, !0), n = e.input.charCodeAt(++e.position), n === 39)
|
|
1839
1839
|
i = e.position, e.position++, r = e.position;
|
|
1840
1840
|
else
|
|
1841
1841
|
return !0;
|
|
1842
|
-
else de(n) ? (
|
|
1842
|
+
else de(n) ? (ge(e, i, r, !0), st(e, Z(e, !1, t)), i = r = e.position) : e.position === e.lineStart && He(e) ? F(e, "unexpected end of the document within a single quoted scalar") : (e.position++, r = e.position);
|
|
1843
1843
|
F(e, "unexpected end of the stream within a single quoted scalar");
|
|
1844
1844
|
}
|
|
1845
1845
|
function La(e, t) {
|
|
@@ -1848,9 +1848,9 @@ function La(e, t) {
|
|
|
1848
1848
|
return !1;
|
|
1849
1849
|
for (e.kind = "scalar", e.result = "", e.position++, n = i = e.position; (s = e.input.charCodeAt(e.position)) !== 0; ) {
|
|
1850
1850
|
if (s === 34)
|
|
1851
|
-
return
|
|
1851
|
+
return ge(e, n, e.position, !0), e.position++, !0;
|
|
1852
1852
|
if (s === 92) {
|
|
1853
|
-
if (
|
|
1853
|
+
if (ge(e, n, e.position, !0), s = e.input.charCodeAt(++e.position), de(s))
|
|
1854
1854
|
Z(e, !1, t);
|
|
1855
1855
|
else if (s < 256 && In[s])
|
|
1856
1856
|
e.result += Fn[s], e.position++;
|
|
@@ -1861,22 +1861,22 @@ function La(e, t) {
|
|
|
1861
1861
|
} else
|
|
1862
1862
|
F(e, "unknown escape sequence");
|
|
1863
1863
|
n = i = e.position;
|
|
1864
|
-
} else de(s) ? (
|
|
1864
|
+
} else de(s) ? (ge(e, n, i, !0), st(e, Z(e, !1, t)), n = i = e.position) : e.position === e.lineStart && He(e) ? F(e, "unexpected end of the document within a double quoted scalar") : (e.position++, i = e.position);
|
|
1865
1865
|
}
|
|
1866
1866
|
F(e, "unexpected end of the stream within a double quoted scalar");
|
|
1867
1867
|
}
|
|
1868
1868
|
function Ba(e, t) {
|
|
1869
|
-
var n = !0, i, r, o, a = e.tag, s, l = e.anchor, c, d, u,
|
|
1870
|
-
if (
|
|
1871
|
-
d = 93,
|
|
1872
|
-
else if (
|
|
1873
|
-
d = 125,
|
|
1869
|
+
var n = !0, i, r, o, a = e.tag, s, l = e.anchor, c, d, u, m, g, y = /* @__PURE__ */ Object.create(null), v, h, A, C;
|
|
1870
|
+
if (C = e.input.charCodeAt(e.position), C === 91)
|
|
1871
|
+
d = 93, g = !1, s = [];
|
|
1872
|
+
else if (C === 123)
|
|
1873
|
+
d = 125, g = !0, s = {};
|
|
1874
1874
|
else
|
|
1875
1875
|
return !1;
|
|
1876
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = s),
|
|
1877
|
-
if (Z(e, !0, t),
|
|
1878
|
-
return e.position++, e.tag = a, e.anchor = l, e.kind =
|
|
1879
|
-
n ?
|
|
1876
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), C = e.input.charCodeAt(++e.position); C !== 0; ) {
|
|
1877
|
+
if (Z(e, !0, t), C = e.input.charCodeAt(e.position), C === d)
|
|
1878
|
+
return e.position++, e.tag = a, e.anchor = l, e.kind = g ? "mapping" : "sequence", e.result = s, !0;
|
|
1879
|
+
n ? C === 44 && F(e, "expected the node content, but found ','") : F(e, "missed comma between flow collection entries"), h = v = A = null, u = m = !1, C === 63 && (c = e.input.charCodeAt(e.position + 1), se(c) && (u = m = !0, e.position++, Z(e, !0, t))), i = e.line, r = e.lineStart, o = e.position, Te(e, t, Ke, !1, !0), h = e.tag, v = e.result, Z(e, !0, t), C = e.input.charCodeAt(e.position), (m || e.line === i) && C === 58 && (u = !0, C = e.input.charCodeAt(++e.position), Z(e, !0, t), Te(e, t, Ke, !1, !0), A = e.result), g ? we(e, s, y, h, v, A, i, r, o) : u ? s.push(we(e, null, y, h, v, A, i, r, o)) : s.push(v), Z(e, !0, t), C = e.input.charCodeAt(e.position), C === 44 ? (n = !0, C = e.input.charCodeAt(++e.position)) : n = !1;
|
|
1880
1880
|
}
|
|
1881
1881
|
F(e, "unexpected end of the stream within a flow collection");
|
|
1882
1882
|
}
|
|
@@ -1923,7 +1923,7 @@ function Ka(e, t) {
|
|
|
1923
1923
|
`, l) : e.result += ee.repeat(`
|
|
1924
1924
|
`, o ? 1 + l : l), o = !0, a = !0, l = 0, n = e.position; !de(u) && u !== 0; )
|
|
1925
1925
|
u = e.input.charCodeAt(++e.position);
|
|
1926
|
-
|
|
1926
|
+
ge(e, n, e.position, !1);
|
|
1927
1927
|
}
|
|
1928
1928
|
return !0;
|
|
1929
1929
|
}
|
|
@@ -1935,7 +1935,7 @@ function Ft(e, t) {
|
|
|
1935
1935
|
o.push(null), l = e.input.charCodeAt(e.position);
|
|
1936
1936
|
continue;
|
|
1937
1937
|
}
|
|
1938
|
-
if (n = e.line,
|
|
1938
|
+
if (n = e.line, Te(e, t, Sn, !1, !0), o.push(e.result), Z(e, !0, -1), l = e.input.charCodeAt(e.position), (e.line === n || e.lineIndent > t) && l !== 0)
|
|
1939
1939
|
F(e, "bad indentation of a sequence entry");
|
|
1940
1940
|
else if (e.lineIndent < t)
|
|
1941
1941
|
break;
|
|
@@ -1943,34 +1943,34 @@ function Ft(e, t) {
|
|
|
1943
1943
|
return s ? (e.tag = i, e.anchor = r, e.kind = "sequence", e.result = o, !0) : !1;
|
|
1944
1944
|
}
|
|
1945
1945
|
function Ra(e, t, n) {
|
|
1946
|
-
var i, r, o, a, s, l, c = e.tag, d = e.anchor, u = {},
|
|
1946
|
+
var i, r, o, a, s, l, c = e.tag, d = e.anchor, u = {}, m = /* @__PURE__ */ Object.create(null), g = null, y = null, v = null, h = !1, A = !1, C;
|
|
1947
1947
|
if (e.firstTabInLine !== -1) return !1;
|
|
1948
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = u),
|
|
1949
|
-
if (!
|
|
1950
|
-
|
|
1948
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = u), C = e.input.charCodeAt(e.position); C !== 0; ) {
|
|
1949
|
+
if (!h && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, F(e, "tab characters must not be used in indentation")), i = e.input.charCodeAt(e.position + 1), o = e.line, (C === 63 || C === 58) && se(i))
|
|
1950
|
+
C === 63 ? (h && (we(e, u, m, g, y, null, a, s, l), g = y = v = null), A = !0, h = !0, r = !0) : h ? (h = !1, r = !0) : F(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, C = i;
|
|
1951
1951
|
else {
|
|
1952
|
-
if (a = e.line, s = e.lineStart, l = e.position,
|
|
1952
|
+
if (a = e.line, s = e.lineStart, l = e.position, !Te(e, n, wn, !1, !0))
|
|
1953
1953
|
break;
|
|
1954
1954
|
if (e.line === o) {
|
|
1955
|
-
for (
|
|
1956
|
-
|
|
1957
|
-
if (
|
|
1958
|
-
|
|
1959
|
-
else if (
|
|
1955
|
+
for (C = e.input.charCodeAt(e.position); ve(C); )
|
|
1956
|
+
C = e.input.charCodeAt(++e.position);
|
|
1957
|
+
if (C === 58)
|
|
1958
|
+
C = e.input.charCodeAt(++e.position), se(C) || F(e, "a whitespace character is expected after the key-value separator within a block mapping"), h && (we(e, u, m, g, y, null, a, s, l), g = y = v = null), A = !0, h = !1, r = !1, g = e.tag, y = e.result;
|
|
1959
|
+
else if (A)
|
|
1960
1960
|
F(e, "can not read an implicit mapping pair; a colon is missed");
|
|
1961
1961
|
else
|
|
1962
1962
|
return e.tag = c, e.anchor = d, !0;
|
|
1963
|
-
} else if (
|
|
1963
|
+
} else if (A)
|
|
1964
1964
|
F(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
1965
1965
|
else
|
|
1966
1966
|
return e.tag = c, e.anchor = d, !0;
|
|
1967
1967
|
}
|
|
1968
|
-
if ((e.line === o || e.lineIndent > t) && (
|
|
1968
|
+
if ((e.line === o || e.lineIndent > t) && (h && (a = e.line, s = e.lineStart, l = e.position), Te(e, t, Re, !0, r) && (h ? y = e.result : v = e.result), h || (we(e, u, m, g, y, v, a, s, l), g = y = v = null), Z(e, !0, -1), C = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > t) && C !== 0)
|
|
1969
1969
|
F(e, "bad indentation of a mapping entry");
|
|
1970
1970
|
else if (e.lineIndent < t)
|
|
1971
1971
|
break;
|
|
1972
1972
|
}
|
|
1973
|
-
return
|
|
1973
|
+
return h && we(e, u, m, g, y, null, a, s, l), A && (e.tag = c, e.anchor = d, e.kind = "mapping", e.result = u), A;
|
|
1974
1974
|
}
|
|
1975
1975
|
function Na(e) {
|
|
1976
1976
|
var t, n = !1, i = !1, r, o, a;
|
|
@@ -1991,7 +1991,7 @@ function Na(e) {
|
|
|
1991
1991
|
} catch {
|
|
1992
1992
|
F(e, "tag name is malformed: " + o);
|
|
1993
1993
|
}
|
|
1994
|
-
return n ? e.tag = o :
|
|
1994
|
+
return n ? e.tag = o : he.call(e.tagMap, r) ? e.tag = e.tagMap[r] + o : r === "!" ? e.tag = "!" + o : r === "!!" ? e.tag = "tag:yaml.org,2002:" + o : F(e, 'undeclared tag handle "' + r + '"'), !0;
|
|
1995
1995
|
}
|
|
1996
1996
|
function Ma(e) {
|
|
1997
1997
|
var t, n;
|
|
@@ -2005,31 +2005,31 @@ function ja(e) {
|
|
|
2005
2005
|
if (i = e.input.charCodeAt(e.position), i !== 42) return !1;
|
|
2006
2006
|
for (i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !se(i) && !_e(i); )
|
|
2007
2007
|
i = e.input.charCodeAt(++e.position);
|
|
2008
|
-
return e.position === t && F(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position),
|
|
2008
|
+
return e.position === t && F(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position), he.call(e.anchorMap, n) || F(e, 'unidentified alias "' + n + '"'), e.result = e.anchorMap[n], Z(e, !0, -1), !0;
|
|
2009
2009
|
}
|
|
2010
|
-
function
|
|
2011
|
-
var o, a, s, l = 1, c = !1, d = !1, u,
|
|
2010
|
+
function Te(e, t, n, i, r) {
|
|
2011
|
+
var o, a, s, l = 1, c = !1, d = !1, u, m, g, y, v, h;
|
|
2012
2012
|
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = a = s = Re === n || Sn === n, i && Z(e, !0, -1) && (c = !0, e.lineIndent > t ? l = 1 : e.lineIndent === t ? l = 0 : e.lineIndent < t && (l = -1)), l === 1)
|
|
2013
2013
|
for (; Na(e) || Ma(e); )
|
|
2014
2014
|
Z(e, !0, -1) ? (c = !0, s = o, e.lineIndent > t ? l = 1 : e.lineIndent === t ? l = 0 : e.lineIndent < t && (l = -1)) : s = !1;
|
|
2015
|
-
if (s && (s = c || r), (l === 1 || Re === n) && (Ke === n || wn === n ? v = t : v = t + 1,
|
|
2015
|
+
if (s && (s = c || r), (l === 1 || Re === n) && (Ke === n || wn === n ? v = t : v = t + 1, h = e.position - e.lineStart, l === 1 ? s && (Ft(e, h) || Ra(e, h, v)) || Ba(e, v) ? d = !0 : (a && Ka(e, v) || Oa(e, v) || La(e, v) ? d = !0 : ja(e) ? (d = !0, (e.tag !== null || e.anchor !== null) && F(e, "alias node should not have any properties")) : Fa(e, v, Ke === n) && (d = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : l === 0 && (d = s && Ft(e, h))), e.tag === null)
|
|
2016
2016
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2017
2017
|
else if (e.tag === "?") {
|
|
2018
|
-
for (e.result !== null && e.kind !== "scalar" && F(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0,
|
|
2019
|
-
if (
|
|
2020
|
-
e.result =
|
|
2018
|
+
for (e.result !== null && e.kind !== "scalar" && F(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0, m = e.implicitTypes.length; u < m; u += 1)
|
|
2019
|
+
if (y = e.implicitTypes[u], y.resolve(e.result)) {
|
|
2020
|
+
e.result = y.construct(e.result), e.tag = y.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2021
2021
|
break;
|
|
2022
2022
|
}
|
|
2023
2023
|
} else if (e.tag !== "!") {
|
|
2024
|
-
if (
|
|
2025
|
-
|
|
2024
|
+
if (he.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
2025
|
+
y = e.typeMap[e.kind || "fallback"][e.tag];
|
|
2026
2026
|
else
|
|
2027
|
-
for (
|
|
2028
|
-
if (e.tag.slice(0,
|
|
2029
|
-
|
|
2027
|
+
for (y = null, g = e.typeMap.multi[e.kind || "fallback"], u = 0, m = g.length; u < m; u += 1)
|
|
2028
|
+
if (e.tag.slice(0, g[u].tag.length) === g[u].tag) {
|
|
2029
|
+
y = g[u];
|
|
2030
2030
|
break;
|
|
2031
2031
|
}
|
|
2032
|
-
|
|
2032
|
+
y || F(e, "unknown tag !<" + e.tag + ">"), e.result !== null && y.kind !== e.kind && F(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + y.kind + '", not "' + e.kind + '"'), y.resolve(e.result, e.tag) ? (e.result = y.construct(e.result, e.tag), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : F(e, "cannot resolve a node with !<" + e.tag + "> explicit tag");
|
|
2033
2033
|
}
|
|
2034
2034
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || d;
|
|
2035
2035
|
}
|
|
@@ -2052,9 +2052,9 @@ function Da(e) {
|
|
|
2052
2052
|
a = e.input.charCodeAt(++e.position);
|
|
2053
2053
|
r.push(e.input.slice(n, e.position));
|
|
2054
2054
|
}
|
|
2055
|
-
a !== 0 && lt(e),
|
|
2055
|
+
a !== 0 && lt(e), he.call(Et, i) ? Et[i](e, i, r) : Ne(e, 'unknown document directive "' + i + '"');
|
|
2056
2056
|
}
|
|
2057
|
-
if (Z(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, Z(e, !0, -1)) : o && F(e, "directives end mark is expected"),
|
|
2057
|
+
if (Z(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, Z(e, !0, -1)) : o && F(e, "directives end mark is expected"), Te(e, e.lineIndent - 1, Re, !1, !0), Z(e, !0, -1), e.checkLineBreaks && _a.test(e.input.slice(t, e.position)) && Ne(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && He(e)) {
|
|
2058
2058
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, Z(e, !0, -1));
|
|
2059
2059
|
return;
|
|
2060
2060
|
}
|
|
@@ -2186,13 +2186,13 @@ function Bt(e, t, n) {
|
|
|
2186
2186
|
) : i && e !== Nn && e !== Mn && e !== jn && e !== Dn && e !== Pn) && e !== Ze && !(t === Me && !r) || Lt(t) && !je(t) && e === Ze || t === Me && r
|
|
2187
2187
|
);
|
|
2188
2188
|
}
|
|
2189
|
-
function
|
|
2189
|
+
function yo(e) {
|
|
2190
2190
|
return Le(e) && e !== ct && !je(e) && e !== eo && e !== io && e !== Me && e !== Nn && e !== Mn && e !== jn && e !== Dn && e !== Pn && e !== Ze && e !== Qa && e !== Xa && e !== Ja && e !== oo && e !== to && e !== no && e !== Za && e !== Ga && e !== za && e !== ro && e !== ao;
|
|
2191
2191
|
}
|
|
2192
|
-
function
|
|
2192
|
+
function go(e) {
|
|
2193
2193
|
return !je(e) && e !== Me;
|
|
2194
2194
|
}
|
|
2195
|
-
function
|
|
2195
|
+
function Ee(e, t) {
|
|
2196
2196
|
var n = e.charCodeAt(t), i;
|
|
2197
2197
|
return n >= 55296 && n <= 56319 && t + 1 < e.length && (i = e.charCodeAt(t + 1), i >= 56320 && i <= 57343) ? (n - 55296) * 1024 + i - 56320 + 65536 : n;
|
|
2198
2198
|
}
|
|
@@ -2201,26 +2201,26 @@ function Un(e) {
|
|
|
2201
2201
|
return t.test(e);
|
|
2202
2202
|
}
|
|
2203
2203
|
var qn = 1, et = 2, Hn = 3, Vn = 4, Ae = 5;
|
|
2204
|
-
function
|
|
2205
|
-
var l, c = 0, d = null, u = !1,
|
|
2204
|
+
function ho(e, t, n, i, r, o, a, s) {
|
|
2205
|
+
var l, c = 0, d = null, u = !1, m = !1, g = i !== -1, y = -1, v = yo(Ee(e, 0)) && go(Ee(e, e.length - 1));
|
|
2206
2206
|
if (t || a)
|
|
2207
2207
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2208
|
-
if (c =
|
|
2208
|
+
if (c = Ee(e, l), !Le(c))
|
|
2209
2209
|
return Ae;
|
|
2210
2210
|
v = v && Bt(c, d, s), d = c;
|
|
2211
2211
|
}
|
|
2212
2212
|
else {
|
|
2213
2213
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2214
|
-
if (c =
|
|
2215
|
-
u = !0,
|
|
2216
|
-
l -
|
|
2214
|
+
if (c = Ee(e, l), c === Fe)
|
|
2215
|
+
u = !0, g && (m = m || // Foldable line = too long, and not more-indented.
|
|
2216
|
+
l - y - 1 > i && e[y + 1] !== " ", y = l);
|
|
2217
2217
|
else if (!Le(c))
|
|
2218
2218
|
return Ae;
|
|
2219
2219
|
v = v && Bt(c, d, s), d = c;
|
|
2220
2220
|
}
|
|
2221
|
-
|
|
2221
|
+
m = m || g && l - y - 1 > i && e[y + 1] !== " ";
|
|
2222
2222
|
}
|
|
2223
|
-
return !u && !
|
|
2223
|
+
return !u && !m ? v && !a && !r(e) ? qn : o === Oe ? Ae : et : n > 9 && Un(e) ? Ae : a ? o === Oe ? Ae : et : m ? Vn : Hn;
|
|
2224
2224
|
}
|
|
2225
2225
|
function vo(e, t, n, i, r) {
|
|
2226
2226
|
e.dump = function() {
|
|
@@ -2232,7 +2232,7 @@ function vo(e, t, n, i, r) {
|
|
|
2232
2232
|
function l(c) {
|
|
2233
2233
|
return mo(e, c);
|
|
2234
2234
|
}
|
|
2235
|
-
switch (
|
|
2235
|
+
switch (ho(
|
|
2236
2236
|
t,
|
|
2237
2237
|
s,
|
|
2238
2238
|
e.indent,
|
|
@@ -2293,7 +2293,7 @@ function Nt(e, t) {
|
|
|
2293
2293
|
}
|
|
2294
2294
|
function xo(e) {
|
|
2295
2295
|
for (var t = "", n = 0, i, r = 0; r < e.length; n >= 65536 ? r += 2 : r++)
|
|
2296
|
-
n =
|
|
2296
|
+
n = Ee(e, r), i = re[n], !i && Le(n) ? (t += e[r], n >= 65536 && (t += e[r + 1])) : t += i || uo(n);
|
|
2297
2297
|
return t;
|
|
2298
2298
|
}
|
|
2299
2299
|
function Co(e, t, n) {
|
|
@@ -2315,7 +2315,7 @@ function ko(e, t, n) {
|
|
|
2315
2315
|
e.tag = r, e.dump = "{" + i + "}";
|
|
2316
2316
|
}
|
|
2317
2317
|
function Ao(e, t, n, i) {
|
|
2318
|
-
var r = "", o = e.tag, a = Object.keys(n), s, l, c, d, u,
|
|
2318
|
+
var r = "", o = e.tag, a = Object.keys(n), s, l, c, d, u, m;
|
|
2319
2319
|
if (e.sortKeys === !0)
|
|
2320
2320
|
a.sort();
|
|
2321
2321
|
else if (typeof e.sortKeys == "function")
|
|
@@ -2323,7 +2323,7 @@ function Ao(e, t, n, i) {
|
|
|
2323
2323
|
else if (e.sortKeys)
|
|
2324
2324
|
throw new oe("sortKeys must be a boolean or a function");
|
|
2325
2325
|
for (s = 0, l = a.length; s < l; s += 1)
|
|
2326
|
-
|
|
2326
|
+
m = "", (!i || r !== "") && (m += Xe(e, t)), c = a[s], d = n[c], e.replacer && (d = e.replacer.call(n, c, d)), pe(e, t + 1, c, !0, !0, !0) && (u = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, u && (e.dump && Fe === e.dump.charCodeAt(0) ? m += "?" : m += "? "), m += e.dump, u && (m += Xe(e, t)), pe(e, t + 1, d, !0, u) && (e.dump && Fe === e.dump.charCodeAt(0) ? m += ":" : m += ": ", m += e.dump, r += m));
|
|
2327
2327
|
e.tag = o, e.dump = r || "{}";
|
|
2328
2328
|
}
|
|
2329
2329
|
function jt(e, t, n) {
|
|
@@ -2347,14 +2347,14 @@ function pe(e, t, n, i, r, o, a) {
|
|
|
2347
2347
|
e.tag = null, e.dump = n, jt(e, n, !1) || jt(e, n, !0);
|
|
2348
2348
|
var s = Kn.call(e.dump), l = i, c;
|
|
2349
2349
|
i && (i = e.flowLevel < 0 || e.flowLevel > t);
|
|
2350
|
-
var d = s === "[object Object]" || s === "[object Array]", u,
|
|
2351
|
-
if (d && (u = e.duplicates.indexOf(n),
|
|
2350
|
+
var d = s === "[object Object]" || s === "[object Array]", u, m;
|
|
2351
|
+
if (d && (u = e.duplicates.indexOf(n), m = u !== -1), (e.tag !== null && e.tag !== "?" || m || e.indent !== 2 && t > 0) && (r = !1), m && e.usedDuplicates[u])
|
|
2352
2352
|
e.dump = "*ref_" + u;
|
|
2353
2353
|
else {
|
|
2354
|
-
if (d &&
|
|
2355
|
-
i && Object.keys(e.dump).length !== 0 ? (Ao(e, t, e.dump, r),
|
|
2354
|
+
if (d && m && !e.usedDuplicates[u] && (e.usedDuplicates[u] = !0), s === "[object Object]")
|
|
2355
|
+
i && Object.keys(e.dump).length !== 0 ? (Ao(e, t, e.dump, r), m && (e.dump = "&ref_" + u + e.dump)) : (ko(e, t, e.dump), m && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2356
2356
|
else if (s === "[object Array]")
|
|
2357
|
-
i && e.dump.length !== 0 ? (e.noArrayIndent && !a && t > 0 ? Mt(e, t - 1, e.dump, r) : Mt(e, t, e.dump, r),
|
|
2357
|
+
i && e.dump.length !== 0 ? (e.noArrayIndent && !a && t > 0 ? Mt(e, t - 1, e.dump, r) : Mt(e, t, e.dump, r), m && (e.dump = "&ref_" + u + e.dump)) : (Co(e, t, e.dump), m && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2358
2358
|
else if (s === "[object String]")
|
|
2359
2359
|
e.tag !== "?" && vo(e, e.dump, t, o, l);
|
|
2360
2360
|
else {
|
|
@@ -2403,7 +2403,7 @@ function ut(e, t) {
|
|
|
2403
2403
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.");
|
|
2404
2404
|
};
|
|
2405
2405
|
}
|
|
2406
|
-
var To = ne, Eo = on, Io = un, Fo =
|
|
2406
|
+
var To = ne, Eo = on, Io = un, Fo = yn, Oo = gn, Lo = ot, Bo = Bn.load, Ko = Bn.loadAll, Ro = $o.dump, No = oe, Mo = {
|
|
2407
2407
|
binary: Cn,
|
|
2408
2408
|
float: mn,
|
|
2409
2409
|
map: cn,
|
|
@@ -2449,8 +2449,8 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2449
2449
|
});
|
|
2450
2450
|
return (i, r) => {
|
|
2451
2451
|
const o = D("KCodeBlock");
|
|
2452
|
-
return
|
|
2453
|
-
t.entityRecord ? (
|
|
2452
|
+
return p(), $("div", Uo, [
|
|
2453
|
+
t.entityRecord ? (p(), M(o, {
|
|
2454
2454
|
key: 0,
|
|
2455
2455
|
id: "yaml-codeblock",
|
|
2456
2456
|
code: n.value,
|
|
@@ -2484,7 +2484,7 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2484
2484
|
}
|
|
2485
2485
|
},
|
|
2486
2486
|
setup(e) {
|
|
2487
|
-
const t = e, n = T(() =>
|
|
2487
|
+
const t = e, n = T(() => yi.includes(t.entityType)), i = (l, c) => {
|
|
2488
2488
|
const d = ie;
|
|
2489
2489
|
let u = "";
|
|
2490
2490
|
return typeof l == "string" ? u += `${d}${c} = "${l}"
|
|
@@ -2494,48 +2494,48 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2494
2494
|
if (typeof l != "object")
|
|
2495
2495
|
return "Invalid object";
|
|
2496
2496
|
const u = ie + d;
|
|
2497
|
-
let
|
|
2498
|
-
if (c && (
|
|
2497
|
+
let m = "";
|
|
2498
|
+
if (c && (m += `${u}${c} = {
|
|
2499
2499
|
`), l === null)
|
|
2500
|
-
return c ?
|
|
2501
|
-
const
|
|
2502
|
-
let
|
|
2503
|
-
for (const [v,
|
|
2504
|
-
Array.isArray(
|
|
2505
|
-
`,
|
|
2506
|
-
`,
|
|
2500
|
+
return c ? m += `${u}}` : m = "{}", m;
|
|
2501
|
+
const g = Object.fromEntries(Object.entries(l).filter(([, v]) => v !== null));
|
|
2502
|
+
let y = "";
|
|
2503
|
+
for (const [v, h] of Object.entries(g))
|
|
2504
|
+
Array.isArray(h) ? h.length === 0 ? y = "[]" : (y = `[
|
|
2505
|
+
`, y += o(h, void 0, u), y += `${u}${ie}]`) : h && typeof h == "object" ? (y = `{
|
|
2506
|
+
`, y += r(h, void 0, u), y += `${u}${ie}}`) : y = String(h ?? ""), typeof h == "string" && (y = `"${y}"`), m += `${u}${ie}${v} = ${y}
|
|
2507
2507
|
`;
|
|
2508
|
-
return c ?
|
|
2509
|
-
` :
|
|
2508
|
+
return c ? m += `${u}}
|
|
2509
|
+
` : m;
|
|
2510
2510
|
}, o = (l, c, d = "") => {
|
|
2511
2511
|
if (!Array.isArray(l))
|
|
2512
2512
|
return "Invalid array";
|
|
2513
2513
|
const u = ie + d;
|
|
2514
|
-
let
|
|
2515
|
-
c && (l.length === 0 ?
|
|
2514
|
+
let m = "";
|
|
2515
|
+
c && (l.length === 0 ? m += `${u}${c} = [` : m += `${u}${c} = [
|
|
2516
2516
|
`);
|
|
2517
|
-
for (let
|
|
2518
|
-
const
|
|
2519
|
-
typeof
|
|
2520
|
-
`,
|
|
2517
|
+
for (let g = 0; g < l.length; g++) {
|
|
2518
|
+
const y = l[g];
|
|
2519
|
+
typeof y == "object" ? (m += `${u}${ie}{
|
|
2520
|
+
`, m += r(y, void 0, u), m += `${u}${ie}}`) : typeof y == "string" ? m += `${u}${ie}"${y}"` : m += `${u}${ie}${String(y ?? "")}`, g < l.length - 1 && (m += ","), m += `
|
|
2521
2521
|
`;
|
|
2522
2522
|
}
|
|
2523
|
-
return c && (l.length === 0 ?
|
|
2524
|
-
` :
|
|
2525
|
-
`),
|
|
2523
|
+
return c && (l.length === 0 ? m += `]
|
|
2524
|
+
` : m += `${u}]
|
|
2525
|
+
`), m;
|
|
2526
2526
|
}, a = (l) => {
|
|
2527
2527
|
let c = "";
|
|
2528
2528
|
for (const [d, u] of Object.entries(l))
|
|
2529
2529
|
Array.isArray(u) ? c += o(u, d) : typeof u == "object" ? c += r(u, d) : c += i(u, d);
|
|
2530
2530
|
return c;
|
|
2531
2531
|
}, s = T(() => {
|
|
2532
|
-
var
|
|
2533
|
-
const l = Object.fromEntries(Object.entries(t.entityRecord).filter(([, E]) => E != null)), c = t.entityRecord.config ? Object.fromEntries(Object.entries((
|
|
2532
|
+
var m, g, y, v, h, A, C;
|
|
2533
|
+
const l = Object.fromEntries(Object.entries(t.entityRecord).filter(([, E]) => E != null)), c = t.entityRecord.config ? Object.fromEntries(Object.entries((m = t.entityRecord) == null ? void 0 : m.config).filter(([, E]) => E != null)) : void 0;
|
|
2534
2534
|
if (c && (l.config = c), Object.keys(l).length === 0)
|
|
2535
2535
|
return "";
|
|
2536
2536
|
delete l.id;
|
|
2537
2537
|
let d = "", u = "";
|
|
2538
|
-
if ((
|
|
2538
|
+
if ((g = l.service) != null && g.id ? (u = "service", delete l.service) : (y = l.route) != null && y.id ? (u = "route", delete l.route) : (v = l.consumer) != null && v.id ? (u = "consumer", delete l.consumer) : (h = l.consumer_group) != null && h.id ? (u = "consumer_group", delete l.consumer_group) : (A = l.certificate) != null && A.id ? (u = "certificate", delete l.certificate) : (C = l.set) != null && C.id && (u = "set", delete l.set), n.value) {
|
|
2539
2539
|
const E = t.subEntityType ? `${t.entityType}_${t.subEntityType}` : t.entityType;
|
|
2540
2540
|
d += `resource "konnect_event_gateway_${E}" "my_eventgateway${E.replaceAll("_", "")}" {
|
|
2541
2541
|
`, d += `${ie}provider = konnect-beta
|
|
@@ -2556,8 +2556,8 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2556
2556
|
});
|
|
2557
2557
|
return (l, c) => {
|
|
2558
2558
|
const d = D("KCodeBlock");
|
|
2559
|
-
return
|
|
2560
|
-
t.entityRecord ? (
|
|
2559
|
+
return p(), $("div", qo, [
|
|
2560
|
+
t.entityRecord ? (p(), M(d, {
|
|
2561
2561
|
key: 0,
|
|
2562
2562
|
id: "terraform-codeblock",
|
|
2563
2563
|
code: s.value,
|
|
@@ -2638,23 +2638,23 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2638
2638
|
const l = JSON.parse(JSON.stringify(s));
|
|
2639
2639
|
return delete l.created_at, delete l.updated_at, l;
|
|
2640
2640
|
}), a = T(() => t.fetcherUrl.replace(/(\?|&)__ui_data=true/, ""));
|
|
2641
|
-
return (s, l) => (
|
|
2642
|
-
e.format === "structured" ? (
|
|
2643
|
-
(
|
|
2641
|
+
return (s, l) => (p(), $(ue, null, [
|
|
2642
|
+
e.format === "structured" ? (p(), $("div", Ho, [
|
|
2643
|
+
(p(!0), $(ue, null, ce(e.propListTypes, (c) => (p(), $("div", {
|
|
2644
2644
|
key: `config-card-details-${c}-props`,
|
|
2645
2645
|
class: fe(`config-card-details-${c}-props`),
|
|
2646
2646
|
"data-testid": `config-card-details-${c}-props`
|
|
2647
2647
|
}, [
|
|
2648
|
-
c !== "basic" ? (
|
|
2649
|
-
(
|
|
2648
|
+
c !== "basic" ? (p(), $("div", Yo, L(c === "advanced" ? _(i)("baseConfigCard.sections.advanced") : c === "plugin" ? _(i)("baseConfigCard.sections.plugin") : _(i)("baseConfigCard.sections.policy")), 1)) : j("", !0),
|
|
2649
|
+
(p(!0), $(ue, null, ce(e.propertyCollections[c], (d) => P(s.$slots, `config-card-item-${d.key}`, {
|
|
2650
2650
|
key: d.key,
|
|
2651
2651
|
item: d
|
|
2652
2652
|
}, () => [
|
|
2653
|
-
R(tn, { item: d },
|
|
2654
|
-
label:
|
|
2653
|
+
R(tn, { item: d }, $e({
|
|
2654
|
+
label: k(() => [
|
|
2655
2655
|
P(s.$slots, `${d.key}-label`, { row: d }, void 0, !0)
|
|
2656
2656
|
]),
|
|
2657
|
-
[d.key]:
|
|
2657
|
+
[d.key]: k(({ rowValue: u }) => [
|
|
2658
2658
|
P(s.$slots, d.key, {
|
|
2659
2659
|
row: d,
|
|
2660
2660
|
rowValue: u
|
|
@@ -2664,7 +2664,7 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2664
2664
|
}, [
|
|
2665
2665
|
r(d) ? {
|
|
2666
2666
|
name: "label-tooltip",
|
|
2667
|
-
fn:
|
|
2667
|
+
fn: k(() => [
|
|
2668
2668
|
P(s.$slots, `${d.key}-label-tooltip`, { row: d }, void 0, !0)
|
|
2669
2669
|
]),
|
|
2670
2670
|
key: "0"
|
|
@@ -2673,18 +2673,18 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2673
2673
|
], !0)), 128))
|
|
2674
2674
|
], 10, Vo))), 128))
|
|
2675
2675
|
])) : j("", !0),
|
|
2676
|
-
e.format === "json" && o.value ? (
|
|
2676
|
+
e.format === "json" && o.value ? (p(), M(nn, {
|
|
2677
2677
|
key: 1,
|
|
2678
2678
|
config: t.config,
|
|
2679
2679
|
"entity-record": o.value,
|
|
2680
2680
|
"fetcher-url": a.value,
|
|
2681
2681
|
"request-method": "get"
|
|
2682
2682
|
}, null, 8, ["config", "entity-record", "fetcher-url"])) : j("", !0),
|
|
2683
|
-
e.format === "yaml" && o.value ? (
|
|
2683
|
+
e.format === "yaml" && o.value ? (p(), M(Wn, {
|
|
2684
2684
|
key: 2,
|
|
2685
2685
|
"entity-record": o.value
|
|
2686
2686
|
}, null, 8, ["entity-record"])) : j("", !0),
|
|
2687
|
-
e.format === "terraform" && o.value ? (
|
|
2687
|
+
e.format === "terraform" && o.value ? (p(), M(Jn, {
|
|
2688
2688
|
key: 3,
|
|
2689
2689
|
"entity-record": o.value,
|
|
2690
2690
|
"entity-type": t.entityType,
|
|
@@ -2841,18 +2841,18 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2841
2841
|
});
|
|
2842
2842
|
const c = l[0].value, d = N(c), u = (f) => {
|
|
2843
2843
|
d.value = f == null ? void 0 : f.value, n("configFormatChange", d.value);
|
|
2844
|
-
},
|
|
2844
|
+
}, m = (f, b) => {
|
|
2845
2845
|
localStorage.setItem(f, b);
|
|
2846
2846
|
};
|
|
2847
2847
|
be(d, (f) => {
|
|
2848
|
-
i.config.formatPreferenceKey &&
|
|
2848
|
+
i.config.formatPreferenceKey && m(i.config.formatPreferenceKey, f);
|
|
2849
2849
|
}), nt(() => {
|
|
2850
2850
|
if (i.config.formatPreferenceKey) {
|
|
2851
2851
|
const f = localStorage.getItem(i.config.formatPreferenceKey);
|
|
2852
|
-
f && l.some((b) => b.value === f) ? d.value = f : d.value = c,
|
|
2852
|
+
f && l.some((b) => b.value === f) ? d.value = f : d.value = c, m(i.config.formatPreferenceKey, d.value);
|
|
2853
2853
|
}
|
|
2854
2854
|
});
|
|
2855
|
-
const
|
|
2855
|
+
const g = {
|
|
2856
2856
|
id: {
|
|
2857
2857
|
type: V.ID,
|
|
2858
2858
|
label: r("baseConfigCard.commonFields.id_label"),
|
|
@@ -2893,14 +2893,14 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2893
2893
|
// the last property displayed
|
|
2894
2894
|
section: ae.Basic
|
|
2895
2895
|
}
|
|
2896
|
-
},
|
|
2896
|
+
}, y = N(!1), v = N(!1), h = N(""), A = N({}), C = T(() => {
|
|
2897
2897
|
var x, H, J;
|
|
2898
|
-
if (!
|
|
2898
|
+
if (!A.value)
|
|
2899
2899
|
return [];
|
|
2900
|
-
const f = [], b = Object.keys(
|
|
2901
|
-
for (const I in
|
|
2900
|
+
const f = [], b = Object.keys(A.value).length;
|
|
2901
|
+
for (const I in A.value) {
|
|
2902
2902
|
if (I === "__ui_data") continue;
|
|
2903
|
-
const K = (H = (x = i.configSchema) == null ? void 0 : x[I]) == null ? void 0 : H.order, G = (J =
|
|
2903
|
+
const K = (H = (x = i.configSchema) == null ? void 0 : x[I]) == null ? void 0 : H.order, G = (J = g[I]) == null ? void 0 : J.order;
|
|
2904
2904
|
let q = b;
|
|
2905
2905
|
(G || G === 0) && (q = G === -1 ? b + 1 : G), K && (q = K === -1 ? b + 1 : K), f.push([I, q]);
|
|
2906
2906
|
}
|
|
@@ -2908,7 +2908,7 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2908
2908
|
return I[1] - K[1];
|
|
2909
2909
|
}), f.map((I) => {
|
|
2910
2910
|
var dt, ft;
|
|
2911
|
-
const K = I[0], G = (dt =
|
|
2911
|
+
const K = I[0], G = (dt = A.value) == null ? void 0 : dt[K], q = ((ft = i.configSchema) == null ? void 0 : ft[K]) || {}, Q = g[K];
|
|
2912
2912
|
return {
|
|
2913
2913
|
key: K,
|
|
2914
2914
|
value: G,
|
|
@@ -2921,9 +2921,9 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2921
2921
|
}).filter((I) => !I.hidden && I.key !== i.pluginConfigKey);
|
|
2922
2922
|
}), E = T(() => {
|
|
2923
2923
|
var H, J;
|
|
2924
|
-
if (!
|
|
2924
|
+
if (!A.value || !i.pluginConfigKey)
|
|
2925
2925
|
return [];
|
|
2926
|
-
const f =
|
|
2926
|
+
const f = A.value[i.pluginConfigKey] || {}, b = Object.keys(f).length, x = [];
|
|
2927
2927
|
for (const I in f) {
|
|
2928
2928
|
const K = (J = (H = i.pluginConfigSchema) == null ? void 0 : H[I]) == null ? void 0 : J.order, G = f[I];
|
|
2929
2929
|
let q = G != null && G !== "" ? b - 1 : b;
|
|
@@ -2946,9 +2946,9 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2946
2946
|
}).filter((I) => !I.hidden);
|
|
2947
2947
|
}), W = T(() => {
|
|
2948
2948
|
var H, J;
|
|
2949
|
-
if (!
|
|
2949
|
+
if (!A.value || !i.policyConfigKey)
|
|
2950
2950
|
return [];
|
|
2951
|
-
const f =
|
|
2951
|
+
const f = A.value[i.policyConfigKey] || {}, b = Object.keys(f).length, x = [];
|
|
2952
2952
|
for (const I in f) {
|
|
2953
2953
|
const K = (J = (H = i.policyConfigSchema) == null ? void 0 : H[I]) == null ? void 0 : J.order, G = f[I];
|
|
2954
2954
|
let q = G != null && G !== "" ? b - 1 : b;
|
|
@@ -2972,10 +2972,10 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2972
2972
|
}), X = T(() => {
|
|
2973
2973
|
var f, b, x, H, J, I;
|
|
2974
2974
|
return {
|
|
2975
|
-
basic: (f =
|
|
2976
|
-
advanced: (b =
|
|
2977
|
-
plugin: (H = E.value) == null ? void 0 : H.concat((x =
|
|
2978
|
-
policy: (I = W.value) == null ? void 0 : I.concat((J =
|
|
2975
|
+
basic: (f = C.value) == null ? void 0 : f.filter((K) => K.section === ae.Basic),
|
|
2976
|
+
advanced: (b = C.value) == null ? void 0 : b.filter((K) => K.section === ae.Advanced),
|
|
2977
|
+
plugin: (H = E.value) == null ? void 0 : H.concat((x = C.value) == null ? void 0 : x.filter((K) => K.section === ae.Plugin)),
|
|
2978
|
+
policy: (I = W.value) == null ? void 0 : I.concat((J = C.value) == null ? void 0 : J.filter((K) => K.section === ae.Policy))
|
|
2979
2979
|
};
|
|
2980
2980
|
}), S = T(() => {
|
|
2981
2981
|
const f = [];
|
|
@@ -2985,41 +2985,41 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
2985
2985
|
let f = `${i.config.apiBaseUrl}${i.fetchUrl}`;
|
|
2986
2986
|
return i.config.app === "konnect" ? f = f.replace(/{controlPlaneId}/gi, ((b = i.config) == null ? void 0 : b.controlPlaneId) || "") : i.config.app === "kongManager" && (f = f.replace(/\/{workspace}/gi, (x = i.config) != null && x.workspace ? `/${i.config.workspace}` : "")), f = f.replace(/{id}/gi, i.config.entityId), f;
|
|
2987
2987
|
});
|
|
2988
|
-
return be(
|
|
2988
|
+
return be(y, (f) => {
|
|
2989
2989
|
n("loading", f);
|
|
2990
2990
|
}, { immediate: !0 }), it(async () => {
|
|
2991
|
-
v.value = !1,
|
|
2991
|
+
v.value = !1, y.value = !0;
|
|
2992
2992
|
try {
|
|
2993
2993
|
const { data: f } = await s.get(w.value);
|
|
2994
2994
|
if (i.dataKey)
|
|
2995
2995
|
if (typeof f[i.dataKey] < "u")
|
|
2996
|
-
|
|
2996
|
+
A.value = { ...f[i.dataKey] };
|
|
2997
2997
|
else
|
|
2998
2998
|
throw new Error(r("errors.dataKeyUndefined", { dataKey: i.dataKey }));
|
|
2999
|
-
else i.recordResolver ?
|
|
2999
|
+
else i.recordResolver ? A.value = { ...i.recordResolver(f) } : A.value = { ...f };
|
|
3000
3000
|
Object.keys(i.configSchema).filter((x) => i.configSchema[x].forceShow).forEach((x) => {
|
|
3001
|
-
|
|
3001
|
+
A.value && typeof A.value[x] > "u" && (A.value[x] = null);
|
|
3002
3002
|
}), n("fetch:success", f);
|
|
3003
3003
|
} catch (f) {
|
|
3004
3004
|
const b = o(f);
|
|
3005
|
-
|
|
3005
|
+
h.value = b.startsWith("code") ? r("baseConfigCard.errors.load") : b, v.value = !0, n("fetch:error", f);
|
|
3006
3006
|
} finally {
|
|
3007
|
-
|
|
3007
|
+
y.value = !1;
|
|
3008
3008
|
}
|
|
3009
3009
|
}), (f, b) => {
|
|
3010
3010
|
const x = D("KLabel"), H = D("KSelect"), J = D("KButton"), I = D("KSkeleton"), K = D("KEmptyState"), G = D("KCard");
|
|
3011
|
-
return
|
|
3011
|
+
return p(), M(G, {
|
|
3012
3012
|
class: "kong-ui-entity-base-config-card",
|
|
3013
3013
|
"title-tag": e.titleTag
|
|
3014
|
-
},
|
|
3015
|
-
actions:
|
|
3014
|
+
}, $e({
|
|
3015
|
+
actions: k(() => [
|
|
3016
3016
|
B("div", zo, [
|
|
3017
3017
|
P(f.$slots, "actions", {}, void 0, !0),
|
|
3018
3018
|
R(x, {
|
|
3019
3019
|
class: "config-format-select-label",
|
|
3020
3020
|
"data-testid": "config-format-select-label"
|
|
3021
3021
|
}, {
|
|
3022
|
-
default:
|
|
3022
|
+
default: k(() => [
|
|
3023
3023
|
U(L(e.label), 1)
|
|
3024
3024
|
]),
|
|
3025
3025
|
_: 1
|
|
@@ -3031,13 +3031,13 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
3031
3031
|
items: l,
|
|
3032
3032
|
onChange: u
|
|
3033
3033
|
}, null, 8, ["modelValue"]),
|
|
3034
|
-
e.configCardDoc ? (
|
|
3034
|
+
e.configCardDoc ? (p(), M(J, {
|
|
3035
3035
|
key: 0,
|
|
3036
3036
|
appearance: "tertiary",
|
|
3037
3037
|
class: "book-icon",
|
|
3038
3038
|
"data-testid": "book-icon"
|
|
3039
3039
|
}, {
|
|
3040
|
-
default:
|
|
3040
|
+
default: k(() => [
|
|
3041
3041
|
B("a", {
|
|
3042
3042
|
href: e.configCardDoc,
|
|
3043
3043
|
rel: "noopener",
|
|
@@ -3050,19 +3050,19 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
3050
3050
|
})) : j("", !0)
|
|
3051
3051
|
])
|
|
3052
3052
|
]),
|
|
3053
|
-
default:
|
|
3054
|
-
|
|
3053
|
+
default: k(() => [
|
|
3054
|
+
y.value ? (p(), M(I, {
|
|
3055
3055
|
key: 0,
|
|
3056
3056
|
"data-testid": "config-card-loader",
|
|
3057
3057
|
"table-columns": 2,
|
|
3058
3058
|
type: "table"
|
|
3059
|
-
})) : v.value ? (
|
|
3059
|
+
})) : v.value ? (p(), M(K, {
|
|
3060
3060
|
key: 1,
|
|
3061
3061
|
"data-testid": "config-card-fetch-error",
|
|
3062
3062
|
"icon-variant": "error"
|
|
3063
3063
|
}, {
|
|
3064
|
-
default:
|
|
3065
|
-
B("h3", null, L(
|
|
3064
|
+
default: k(() => [
|
|
3065
|
+
B("h3", null, L(h.value), 1)
|
|
3066
3066
|
]),
|
|
3067
3067
|
_: 1
|
|
3068
3068
|
})) : j("", !0),
|
|
@@ -3075,13 +3075,13 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
3075
3075
|
format: d.value,
|
|
3076
3076
|
"prop-list-types": S.value,
|
|
3077
3077
|
"property-collections": X.value,
|
|
3078
|
-
record:
|
|
3078
|
+
record: A.value,
|
|
3079
3079
|
"sub-entity-type": e.subEntityType
|
|
3080
|
-
},
|
|
3080
|
+
}, $e({ _: 2 }, [
|
|
3081
3081
|
ce(Object.keys(f.$slots), (q) => ({
|
|
3082
3082
|
name: q,
|
|
3083
|
-
fn:
|
|
3084
|
-
P(f.$slots, q, Vt({ record:
|
|
3083
|
+
fn: k((Q) => [
|
|
3084
|
+
P(f.$slots, q, Vt({ record: A.value }, Q), void 0, !0)
|
|
3085
3085
|
])
|
|
3086
3086
|
}))
|
|
3087
3087
|
]), 1032, ["code-block-record-formatter", "config", "entity-type", "fetcher-url", "format", "prop-list-types", "property-collections", "record", "sub-entity-type"])
|
|
@@ -3091,7 +3091,7 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
3091
3091
|
}, [
|
|
3092
3092
|
e.hideTitle ? void 0 : {
|
|
3093
3093
|
name: "title",
|
|
3094
|
-
fn:
|
|
3094
|
+
fn: k(() => [
|
|
3095
3095
|
B("span", Go, [
|
|
3096
3096
|
P(f.$slots, "title", {}, () => [
|
|
3097
3097
|
U(L(_(r)("baseConfigCard.title")), 1)
|
|
@@ -3123,14 +3123,14 @@ const Uo = { class: "yaml-config config-card-code-block" }, Wn = /* @__PURE__ */
|
|
|
3123
3123
|
control_plane_name: t.controlPlaneName
|
|
3124
3124
|
}), d;
|
|
3125
3125
|
}), s = T(() => {
|
|
3126
|
-
var
|
|
3127
|
-
const d = Object.fromEntries(Object.entries(t.entityRecord).filter(([,
|
|
3128
|
-
t.entityType ===
|
|
3129
|
-
const u = {
|
|
3126
|
+
var g, y, v, h, A;
|
|
3127
|
+
const d = Object.fromEntries(Object.entries(t.entityRecord).filter(([, C]) => C !== null && C !== "" && (Array.isArray(C) ? C.length !== 0 : !0)));
|
|
3128
|
+
t.entityType === Se.Plugin ? ((g = d.service) != null && g.id && (d.service = d.service.id), (y = d.route) != null && y.id && (d.route = d.route.id), (v = d.consumer) != null && v.id && (d.consumer = d.consumer.id), (h = d.consumer_group) != null && h.id && (d.consumer_group = d.consumer_group.id)) : t.entityType === Se.Key && (A = d.key_set) != null && A.id && (d.key_set = d.key_set.id);
|
|
3129
|
+
const u = t.entityType === Se.KeySet ? "key_sets" : t.entityType + "s", m = {
|
|
3130
3130
|
...a.value,
|
|
3131
|
-
[
|
|
3131
|
+
[u]: [d]
|
|
3132
3132
|
};
|
|
3133
|
-
return Yn.dump(
|
|
3133
|
+
return Yn.dump(m, { quotingType: '"' }).trim();
|
|
3134
3134
|
}), l = T(() => o.value === "bash" ? "export DECK_KONNECT_TOKEN='YOUR_KONNECT_PAT'" : '$env:DECK_KONNECT_TOKEN = "YOUR_KONNECT_PAT"'), c = T(() => {
|
|
3135
3135
|
let d = "deck gateway apply -";
|
|
3136
3136
|
return t.geoApiServerUrl && (d += ` --konnect-addr ${t.geoApiServerUrl}`), o.value === "bash" ? `echo '${s.value}
|
|
@@ -3139,36 +3139,36 @@ ${s.value}
|
|
|
3139
3139
|
'@ | ${d}`;
|
|
3140
3140
|
});
|
|
3141
3141
|
return (d, u) => {
|
|
3142
|
-
const
|
|
3143
|
-
return
|
|
3144
|
-
R(
|
|
3142
|
+
const m = D("KSelect"), g = D("KBadge"), y = D("KCodeBlock");
|
|
3143
|
+
return p(), $("div", el, [
|
|
3144
|
+
R(m, {
|
|
3145
3145
|
modelValue: o.value,
|
|
3146
3146
|
"onUpdate:modelValue": u[0] || (u[0] = (v) => o.value = v),
|
|
3147
3147
|
items: r
|
|
3148
3148
|
}, {
|
|
3149
|
-
"item-template":
|
|
3150
|
-
v.value === "pwsh" ? (
|
|
3149
|
+
"item-template": k(({ item: v }) => [
|
|
3150
|
+
v.value === "pwsh" ? (p(), M(_(yt), { key: 0 })) : (p(), M(_(gt), { key: 1 })),
|
|
3151
3151
|
U(" " + L(v.label), 1)
|
|
3152
3152
|
]),
|
|
3153
|
-
"selected-item-template":
|
|
3154
|
-
v.value === "pwsh" ? (
|
|
3153
|
+
"selected-item-template": k(({ item: v }) => [
|
|
3154
|
+
v.value === "pwsh" ? (p(), M(_(yt), { key: 0 })) : (p(), M(_(gt), { key: 1 })),
|
|
3155
3155
|
U(" " + L(v.label), 1)
|
|
3156
3156
|
]),
|
|
3157
3157
|
_: 1
|
|
3158
3158
|
}, 8, ["modelValue"]),
|
|
3159
3159
|
B("p", null, [
|
|
3160
3160
|
R(_(i), { keypath: "deckCodeBlock.hint" }, {
|
|
3161
|
-
token:
|
|
3162
|
-
R(
|
|
3163
|
-
default:
|
|
3161
|
+
token: k(() => [
|
|
3162
|
+
R(g, null, {
|
|
3163
|
+
default: k(() => [...u[1] || (u[1] = [
|
|
3164
3164
|
U("DECK_KONNECT_TOKEN", -1)
|
|
3165
3165
|
])]),
|
|
3166
3166
|
_: 1
|
|
3167
3167
|
})
|
|
3168
3168
|
]),
|
|
3169
|
-
link:
|
|
3169
|
+
link: k(() => [
|
|
3170
3170
|
R(_(ai), { href: "https://developer.konghq.com/deck/get-started/" }, {
|
|
3171
|
-
default:
|
|
3171
|
+
default: k(() => [
|
|
3172
3172
|
U(L(_(n).t("deckCodeBlock.documentation")), 1)
|
|
3173
3173
|
]),
|
|
3174
3174
|
_: 1
|
|
@@ -3177,14 +3177,14 @@ ${s.value}
|
|
|
3177
3177
|
_: 1
|
|
3178
3178
|
})
|
|
3179
3179
|
]),
|
|
3180
|
-
R(
|
|
3180
|
+
R(y, {
|
|
3181
3181
|
id: "deck-env-codeblock",
|
|
3182
3182
|
code: l.value,
|
|
3183
3183
|
language: "shell",
|
|
3184
3184
|
"single-line": "",
|
|
3185
3185
|
theme: "dark"
|
|
3186
3186
|
}, null, 8, ["code"]),
|
|
3187
|
-
t.entityRecord ? (
|
|
3187
|
+
t.entityRecord ? (p(), M(y, {
|
|
3188
3188
|
key: 0,
|
|
3189
3189
|
id: "deck-codeblock",
|
|
3190
3190
|
code: c.value,
|
|
@@ -3194,7 +3194,7 @@ ${s.value}
|
|
|
3194
3194
|
]);
|
|
3195
3195
|
};
|
|
3196
3196
|
}
|
|
3197
|
-
}), nl = /* @__PURE__ */ le(tl, [["__scopeId", "data-v-
|
|
3197
|
+
}), nl = /* @__PURE__ */ le(tl, [["__scopeId", "data-v-b0f5656a"]]), il = ["novalidate"], rl = /* @__PURE__ */ z({
|
|
3198
3198
|
__name: "EntityBaseForm",
|
|
3199
3199
|
props: {
|
|
3200
3200
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3318,18 +3318,18 @@ ${s.value}
|
|
|
3318
3318
|
emits: ["loading", "fetch:success", "fetch:error", "submit", "cancel", "codeBlockTabChange"],
|
|
3319
3319
|
setup(e, { expose: t, emit: n }) {
|
|
3320
3320
|
var X;
|
|
3321
|
-
const i = n, r = e, o = di(), { i18n: { t: a } } = Y.useI18n(), { getMessageFromError: s } = Y.useErrors(), { axiosInstance: l } = Y.useAxios((X = r.config) == null ? void 0 : X.axiosRequestConfig), c = N(!1), d = T(() => !!r.editId), u = N(!1),
|
|
3321
|
+
const i = n, r = e, o = di(), { i18n: { t: a } } = Y.useI18n(), { getMessageFromError: s } = Y.useErrors(), { axiosInstance: l } = Y.useAxios((X = r.config) == null ? void 0 : X.axiosRequestConfig), c = N(!1), d = T(() => !!r.editId), u = N(!1), m = N(""), g = T(() => r.canSubmit === !1 || r.isReadonly), y = N(!1), v = T(() => {
|
|
3322
3322
|
var w, O;
|
|
3323
3323
|
let S = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3324
3324
|
return r.config.app === "konnect" ? S = S.replace(/{controlPlaneId}/gi, ((w = r.config) == null ? void 0 : w.controlPlaneId) || "") : r.config.app === "kongManager" && (S = S.replace(/\/{workspace}/gi, (O = r.config) != null && O.workspace ? `/${r.config.workspace}` : "")), r.editId ? (S = S.replace(/{id}/gi, r.editId), S) : (S = S.replace(/\/{id}/gi, ""), S);
|
|
3325
|
-
}),
|
|
3326
|
-
|
|
3327
|
-
}, k = () => {
|
|
3328
|
-
r.config.cancelRoute ? o.push(r.config.cancelRoute) : A();
|
|
3325
|
+
}), h = () => {
|
|
3326
|
+
y.value = !y.value;
|
|
3329
3327
|
}, A = () => {
|
|
3328
|
+
r.config.cancelRoute ? o.push(r.config.cancelRoute) : C();
|
|
3329
|
+
}, C = () => {
|
|
3330
3330
|
i("cancel");
|
|
3331
3331
|
}, E = () => {
|
|
3332
|
-
|
|
3332
|
+
g.value || i("submit");
|
|
3333
3333
|
}, W = N([
|
|
3334
3334
|
{
|
|
3335
3335
|
title: a("baseForm.configuration.json"),
|
|
@@ -3340,7 +3340,7 @@ ${s.value}
|
|
|
3340
3340
|
hash: "#yaml"
|
|
3341
3341
|
}
|
|
3342
3342
|
]);
|
|
3343
|
-
return r.config.app === "konnect" && r.entityType !==
|
|
3343
|
+
return r.config.app === "konnect" && r.entityType !== Se.Other && W.value.splice(1, 0, {
|
|
3344
3344
|
title: a("baseForm.configuration.terraform"),
|
|
3345
3345
|
hash: "#terraform"
|
|
3346
3346
|
}), r.config.app === "konnect" && r.config.enableDeckTab && mi.includes(r.entityType) && W.value.push({
|
|
@@ -3356,47 +3356,47 @@ ${s.value}
|
|
|
3356
3356
|
i("fetch:success", S);
|
|
3357
3357
|
} catch (S) {
|
|
3358
3358
|
const w = s(S);
|
|
3359
|
-
|
|
3359
|
+
m.value = w.startsWith("code") ? a("baseForm.errors.edit") : w, u.value = !0, i("fetch:error", S);
|
|
3360
3360
|
} finally {
|
|
3361
3361
|
c.value = !1;
|
|
3362
3362
|
}
|
|
3363
3363
|
}), t({
|
|
3364
|
-
viewConfig:
|
|
3365
|
-
formCancel:
|
|
3364
|
+
viewConfig: h,
|
|
3365
|
+
formCancel: C,
|
|
3366
3366
|
formSubmit: E
|
|
3367
3367
|
}), (S, w) => {
|
|
3368
3368
|
const O = D("KSkeleton"), f = D("KEmptyState"), b = D("KAlert"), x = D("KButton"), H = D("KTabs"), J = D("KSlideout");
|
|
3369
|
-
return
|
|
3370
|
-
default:
|
|
3371
|
-
c.value ? (
|
|
3369
|
+
return p(), M(De(e.wrapperComponent), { class: "kong-ui-entity-base-form" }, {
|
|
3370
|
+
default: k(() => [
|
|
3371
|
+
c.value ? (p(), M(O, {
|
|
3372
3372
|
key: 0,
|
|
3373
3373
|
type: "form"
|
|
3374
|
-
})) : u.value ? (
|
|
3374
|
+
})) : u.value ? (p(), M(f, {
|
|
3375
3375
|
key: 1,
|
|
3376
3376
|
"action-button-text": _(a)("baseForm.actions.back"),
|
|
3377
3377
|
"data-testid": "form-fetch-error",
|
|
3378
3378
|
"icon-variant": "error",
|
|
3379
|
-
onClickAction:
|
|
3379
|
+
onClickAction: A
|
|
3380
3380
|
}, {
|
|
3381
|
-
default:
|
|
3382
|
-
B("h3", null, L(
|
|
3381
|
+
default: k(() => [
|
|
3382
|
+
B("h3", null, L(m.value), 1)
|
|
3383
3383
|
]),
|
|
3384
3384
|
_: 1
|
|
3385
|
-
}, 8, ["action-button-text"])) : (
|
|
3385
|
+
}, 8, ["action-button-text"])) : (p(), $("form", {
|
|
3386
3386
|
key: 2,
|
|
3387
3387
|
"data-testid": "form-content",
|
|
3388
3388
|
novalidate: r.noValidate,
|
|
3389
|
-
onReset: Be(
|
|
3389
|
+
onReset: Be(C, ["prevent"]),
|
|
3390
3390
|
onSubmit: Be(E, ["prevent"])
|
|
3391
3391
|
}, [
|
|
3392
3392
|
P(S.$slots, "default", {}, void 0, !0),
|
|
3393
|
-
e.errorMessage ? (
|
|
3393
|
+
e.errorMessage ? (p(), M(b, {
|
|
3394
3394
|
key: 0,
|
|
3395
3395
|
appearance: "danger",
|
|
3396
3396
|
"data-testid": "form-error",
|
|
3397
3397
|
message: e.errorMessage
|
|
3398
3398
|
}, null, 8, ["message"])) : j("", !0),
|
|
3399
|
-
e.hideActions ? j("", !0) : (
|
|
3399
|
+
e.hideActions ? j("", !0) : (p(), M(Yt, {
|
|
3400
3400
|
key: 1,
|
|
3401
3401
|
disabled: !e.actionTeleportTarget,
|
|
3402
3402
|
to: e.actionTeleportTarget
|
|
@@ -3409,9 +3409,9 @@ ${s.value}
|
|
|
3409
3409
|
R(x, {
|
|
3410
3410
|
appearance: "tertiary",
|
|
3411
3411
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-view-configuration`,
|
|
3412
|
-
onClick: w[0] || (w[0] = (I) =>
|
|
3412
|
+
onClick: w[0] || (w[0] = (I) => h())
|
|
3413
3413
|
}, {
|
|
3414
|
-
default:
|
|
3414
|
+
default: k(() => [
|
|
3415
3415
|
U(L(_(a)("baseForm.actions.viewConfiguration")), 1)
|
|
3416
3416
|
]),
|
|
3417
3417
|
_: 1
|
|
@@ -3421,9 +3421,9 @@ ${s.value}
|
|
|
3421
3421
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-cancel`,
|
|
3422
3422
|
disabled: e.isReadonly,
|
|
3423
3423
|
type: "reset",
|
|
3424
|
-
onClick: w[1] || (w[1] = (I) => !!e.actionTeleportTarget &&
|
|
3424
|
+
onClick: w[1] || (w[1] = (I) => !!e.actionTeleportTarget && C())
|
|
3425
3425
|
}, {
|
|
3426
|
-
default:
|
|
3426
|
+
default: k(() => [
|
|
3427
3427
|
U(L(e.cancelButtonText ?? _(a)("baseForm.actions.cancel")), 1)
|
|
3428
3428
|
]),
|
|
3429
3429
|
_: 1
|
|
@@ -3431,11 +3431,11 @@ ${s.value}
|
|
|
3431
3431
|
R(x, {
|
|
3432
3432
|
appearance: "primary",
|
|
3433
3433
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-submit`,
|
|
3434
|
-
disabled:
|
|
3434
|
+
disabled: g.value,
|
|
3435
3435
|
type: "submit",
|
|
3436
3436
|
onClick: w[2] || (w[2] = (I) => !!e.actionTeleportTarget && E())
|
|
3437
3437
|
}, {
|
|
3438
|
-
default:
|
|
3438
|
+
default: k(() => [
|
|
3439
3439
|
U(L(e.saveButtonText ?? _(a)("baseForm.actions.save")), 1)
|
|
3440
3440
|
]),
|
|
3441
3441
|
_: 1
|
|
@@ -3450,17 +3450,17 @@ ${s.value}
|
|
|
3450
3450
|
"has-overlay": !1,
|
|
3451
3451
|
"offset-top": e.slidoutTopOffset,
|
|
3452
3452
|
title: _(a)("baseForm.configuration.title"),
|
|
3453
|
-
visible:
|
|
3454
|
-
onClose: w[4] || (w[4] = (I) =>
|
|
3453
|
+
visible: y.value,
|
|
3454
|
+
onClose: w[4] || (w[4] = (I) => h())
|
|
3455
3455
|
}, {
|
|
3456
|
-
default:
|
|
3456
|
+
default: k(() => [
|
|
3457
3457
|
B("div", null, L(_(a)("baseForm.configuration.message")), 1),
|
|
3458
3458
|
R(H, {
|
|
3459
3459
|
"data-testid": "form-view-configuration-slideout-tabs",
|
|
3460
3460
|
tabs: W.value,
|
|
3461
3461
|
onChange: w[3] || (w[3] = (I) => i("codeBlockTabChange", I.replace("#", "")))
|
|
3462
3462
|
}, {
|
|
3463
|
-
json:
|
|
3463
|
+
json: k(() => [
|
|
3464
3464
|
R(nn, {
|
|
3465
3465
|
config: e.config,
|
|
3466
3466
|
"entity-record": r.formFields,
|
|
@@ -3468,19 +3468,19 @@ ${s.value}
|
|
|
3468
3468
|
"request-method": r.editId ? "put" : "post"
|
|
3469
3469
|
}, null, 8, ["config", "entity-record", "fetcher-url", "request-method"])
|
|
3470
3470
|
]),
|
|
3471
|
-
yaml:
|
|
3471
|
+
yaml: k(() => [
|
|
3472
3472
|
R(Wn, {
|
|
3473
3473
|
"entity-record": r.formFields
|
|
3474
3474
|
}, null, 8, ["entity-record"])
|
|
3475
3475
|
]),
|
|
3476
|
-
terraform:
|
|
3476
|
+
terraform: k(() => [
|
|
3477
3477
|
R(Jn, {
|
|
3478
3478
|
"entity-record": r.formFields,
|
|
3479
3479
|
"entity-type": e.entityType,
|
|
3480
3480
|
"sub-entity-type": e.subEntityType
|
|
3481
3481
|
}, null, 8, ["entity-record", "entity-type", "sub-entity-type"])
|
|
3482
3482
|
]),
|
|
3483
|
-
deck:
|
|
3483
|
+
deck: k(() => [
|
|
3484
3484
|
R(nl, {
|
|
3485
3485
|
"control-plane-name": e.config.app === "konnect" ? e.config.controlPlaneName : void 0,
|
|
3486
3486
|
"entity-record": r.formFields,
|
|
@@ -3516,38 +3516,38 @@ ${s.value}
|
|
|
3516
3516
|
},
|
|
3517
3517
|
setup(e) {
|
|
3518
3518
|
const t = e, n = T(() => {
|
|
3519
|
-
var
|
|
3520
|
-
return ((
|
|
3519
|
+
var h;
|
|
3520
|
+
return ((h = t.rowEl) == null ? void 0 : h.querySelector(`[data-testid="${t.keyName}"]`)) || null;
|
|
3521
3521
|
}), i = T(() => {
|
|
3522
|
-
var
|
|
3523
|
-
return ((
|
|
3522
|
+
var h;
|
|
3523
|
+
return ((h = n.value) == null ? void 0 : h.querySelector('[data-truncate="true"]')) || null;
|
|
3524
3524
|
}), r = T(() => {
|
|
3525
|
-
var
|
|
3526
|
-
const
|
|
3527
|
-
return
|
|
3525
|
+
var A, C;
|
|
3526
|
+
const h = (A = t.rowEl) == null ? void 0 : A.querySelectorAll("td");
|
|
3527
|
+
return h ? ((C = h[0]) == null ? void 0 : C.getAttribute("data-testid")) === t.keyName : !0;
|
|
3528
3528
|
}), o = T(() => r.value || t.tooltip);
|
|
3529
3529
|
let a;
|
|
3530
3530
|
const s = () => {
|
|
3531
3531
|
a && (a.disconnect(), a = void 0);
|
|
3532
3532
|
}, l = () => {
|
|
3533
|
-
var
|
|
3534
|
-
let
|
|
3533
|
+
var A, C, E;
|
|
3534
|
+
let h = ((A = n.value) == null ? void 0 : A.clientWidth) || 0;
|
|
3535
3535
|
if (n.value && "getComputedStyle" in window) {
|
|
3536
3536
|
const W = window.getComputedStyle(n.value);
|
|
3537
|
-
|
|
3537
|
+
h -= (parseFloat(W.paddingLeft) || 0) + (parseFloat(W.paddingRight) || 0);
|
|
3538
3538
|
}
|
|
3539
|
-
d.value = ((
|
|
3540
|
-
}, c = N({}), d = N(0), u = N(0),
|
|
3541
|
-
|
|
3542
|
-
(
|
|
3539
|
+
d.value = ((C = i.value) == null ? void 0 : C.getBoundingClientRect().width) || 0, u.value = h, m.value = ((E = c.value) == null ? void 0 : E.innerText) || "";
|
|
3540
|
+
}, c = N({}), d = N(0), u = N(0), m = N(""), g = T(() => [i.value, n.value]), y = be(
|
|
3541
|
+
g,
|
|
3542
|
+
(h) => {
|
|
3543
3543
|
if (o.value && (s(), "ResizeObserver" in window && window)) {
|
|
3544
|
-
a = new ResizeObserver((
|
|
3544
|
+
a = new ResizeObserver((A) => {
|
|
3545
3545
|
window.requestAnimationFrame(() => {
|
|
3546
|
-
!Array.isArray(
|
|
3546
|
+
!Array.isArray(A) || !A.length || l();
|
|
3547
3547
|
});
|
|
3548
3548
|
});
|
|
3549
|
-
for (const
|
|
3550
|
-
|
|
3549
|
+
for (const A of h)
|
|
3550
|
+
A && a.observe(A);
|
|
3551
3551
|
}
|
|
3552
3552
|
},
|
|
3553
3553
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
@@ -3555,29 +3555,29 @@ ${s.value}
|
|
|
3555
3555
|
return nt(() => {
|
|
3556
3556
|
l();
|
|
3557
3557
|
}), Xn(() => {
|
|
3558
|
-
|
|
3559
|
-
}), (
|
|
3560
|
-
const
|
|
3561
|
-
return
|
|
3558
|
+
y();
|
|
3559
|
+
}), (h, A) => {
|
|
3560
|
+
const C = D("KTooltip");
|
|
3561
|
+
return p(), $("span", {
|
|
3562
3562
|
ref_key: "contentRef",
|
|
3563
3563
|
ref: c,
|
|
3564
3564
|
class: "content-wrapper"
|
|
3565
3565
|
}, [
|
|
3566
|
-
o.value ? (
|
|
3566
|
+
o.value ? (p(), $("span", {
|
|
3567
3567
|
key: 0,
|
|
3568
3568
|
"data-truncate": o.value || void 0
|
|
3569
3569
|
}, [
|
|
3570
|
-
R(
|
|
3570
|
+
R(C, {
|
|
3571
3571
|
"max-width": "300",
|
|
3572
3572
|
placement: "bottom-start",
|
|
3573
|
-
text: v.value ?
|
|
3573
|
+
text: v.value ? m.value : ""
|
|
3574
3574
|
}, {
|
|
3575
|
-
default:
|
|
3576
|
-
P(
|
|
3575
|
+
default: k(() => [
|
|
3576
|
+
P(h.$slots, "default", {}, void 0, !0)
|
|
3577
3577
|
]),
|
|
3578
3578
|
_: 3
|
|
3579
3579
|
}, 8, ["text"])
|
|
3580
|
-
], 8, al)) : P(
|
|
3580
|
+
], 8, al)) : P(h.$slots, "default", { key: 1 }, void 0, !0)
|
|
3581
3581
|
], 512);
|
|
3582
3582
|
};
|
|
3583
3583
|
}
|
|
@@ -3774,17 +3774,17 @@ ${s.value}
|
|
|
3774
3774
|
overflowX: "hidden",
|
|
3775
3775
|
textOverflow: "ellipsis"
|
|
3776
3776
|
}), b;
|
|
3777
|
-
},
|
|
3778
|
-
|
|
3779
|
-
}, h = () => {
|
|
3780
|
-
i("empty-state-cta-clicked"), g();
|
|
3777
|
+
}, m = (f) => {
|
|
3778
|
+
C(f), i("state", f);
|
|
3781
3779
|
}, g = () => {
|
|
3780
|
+
i("empty-state-cta-clicked"), y();
|
|
3781
|
+
}, y = () => {
|
|
3782
3782
|
i("clear-search-input");
|
|
3783
3783
|
}, v = T(() => n.disableRowClick ? void 0 : (f, b) => {
|
|
3784
3784
|
i("click:row", b);
|
|
3785
|
-
}),
|
|
3785
|
+
}), h = (f) => {
|
|
3786
3786
|
i("sort", f);
|
|
3787
|
-
}, { hideTableToolbar:
|
|
3787
|
+
}, { hideTableToolbar: A, handleStateChange: C } = Y.useTableState(() => n.query), { setTablePreferences: E, getTablePreferences: W } = bi(), X = N(W(a.value, n.defaultTablePreferences)), S = T(() => {
|
|
3788
3788
|
const f = W(a.value);
|
|
3789
3789
|
return {
|
|
3790
3790
|
...n.initialFetcherParams,
|
|
@@ -3801,12 +3801,12 @@ ${s.value}
|
|
|
3801
3801
|
}));
|
|
3802
3802
|
return (f, b) => {
|
|
3803
3803
|
const x = D("KTableData"), H = D("KCard");
|
|
3804
|
-
return
|
|
3804
|
+
return p(), M(H, {
|
|
3805
3805
|
class: "kong-ui-entity-base-table",
|
|
3806
3806
|
title: e.title,
|
|
3807
3807
|
"title-tag": e.titleTag
|
|
3808
3808
|
}, {
|
|
3809
|
-
default:
|
|
3809
|
+
default: k(() => [
|
|
3810
3810
|
R(x, {
|
|
3811
3811
|
ref_key: "tableRefs",
|
|
3812
3812
|
ref: c,
|
|
@@ -3826,7 +3826,7 @@ ${s.value}
|
|
|
3826
3826
|
headers: s.value,
|
|
3827
3827
|
"hide-pagination": e.hidePagination,
|
|
3828
3828
|
"hide-pagination-when-optional": e.hidePaginationWhenOptional,
|
|
3829
|
-
"hide-toolbar": e.hideToolbar ?? _(
|
|
3829
|
+
"hide-toolbar": e.hideToolbar ?? _(A),
|
|
3830
3830
|
"initial-fetcher-params": S.value,
|
|
3831
3831
|
loading: e.isLoading,
|
|
3832
3832
|
"pagination-attributes": O.value,
|
|
@@ -3837,41 +3837,41 @@ ${s.value}
|
|
|
3837
3837
|
"sort-handler-function": e.enableClientSort ? e.sortHandlerFunction : void 0,
|
|
3838
3838
|
sortable: !e.disableSorting,
|
|
3839
3839
|
"table-preferences": X.value,
|
|
3840
|
-
onEmptyStateActionClick:
|
|
3840
|
+
onEmptyStateActionClick: g,
|
|
3841
3841
|
"onRow:click": v.value,
|
|
3842
|
-
onSort: b[0] || (b[0] = (J) =>
|
|
3843
|
-
onState:
|
|
3842
|
+
onSort: b[0] || (b[0] = (J) => h(J)),
|
|
3843
|
+
onState: m,
|
|
3844
3844
|
"onUpdate:tablePreferences": w
|
|
3845
|
-
},
|
|
3846
|
-
toolbar:
|
|
3845
|
+
}, $e({
|
|
3846
|
+
toolbar: k(() => [
|
|
3847
3847
|
B("div", sl, [
|
|
3848
3848
|
P(f.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3849
|
-
f.$slots["toolbar-button"] ? (
|
|
3849
|
+
f.$slots["toolbar-button"] ? (p(), $("div", cl, [
|
|
3850
3850
|
P(f.$slots, "toolbar-button", {}, void 0, !0)
|
|
3851
3851
|
])) : j("", !0)
|
|
3852
3852
|
])
|
|
3853
3853
|
]),
|
|
3854
|
-
"action-items":
|
|
3854
|
+
"action-items": k(({ row: J }) => [
|
|
3855
3855
|
P(f.$slots, "actions", { row: J }, void 0, !0)
|
|
3856
3856
|
]),
|
|
3857
3857
|
_: 2
|
|
3858
3858
|
}, [
|
|
3859
3859
|
f.$slots["empty-state"] ? {
|
|
3860
3860
|
name: "empty-state",
|
|
3861
|
-
fn:
|
|
3861
|
+
fn: k(() => [
|
|
3862
3862
|
P(f.$slots, "empty-state", {}, void 0, !0)
|
|
3863
3863
|
]),
|
|
3864
3864
|
key: "0"
|
|
3865
3865
|
} : void 0,
|
|
3866
3866
|
ce(e.tableHeaders, (J, I) => ({
|
|
3867
3867
|
name: I,
|
|
3868
|
-
fn:
|
|
3868
|
+
fn: k(({ row: K, rowValue: G }) => [
|
|
3869
3869
|
R(ll, {
|
|
3870
3870
|
"key-name": String(I),
|
|
3871
3871
|
"row-el": d(K),
|
|
3872
3872
|
tooltip: J.tooltip
|
|
3873
3873
|
}, {
|
|
3874
|
-
default:
|
|
3874
|
+
default: k(() => [
|
|
3875
3875
|
P(f.$slots, I, {
|
|
3876
3876
|
row: K,
|
|
3877
3877
|
rowKey: e.rowKey,
|
|
@@ -3886,13 +3886,13 @@ ${s.value}
|
|
|
3886
3886
|
})),
|
|
3887
3887
|
e.query ? void 0 : {
|
|
3888
3888
|
name: "empty-state-action-icon",
|
|
3889
|
-
fn:
|
|
3889
|
+
fn: k(() => [
|
|
3890
3890
|
R(_(Jt))
|
|
3891
3891
|
]),
|
|
3892
3892
|
key: "1"
|
|
3893
3893
|
}
|
|
3894
3894
|
]), 1032, ["cache-identifier", "client-sort", "empty-state-action-message", "empty-state-action-route", "empty-state-icon-variant", "empty-state-message", "empty-state-title", "error", "error-state-message", "error-state-title", "fetcher", "fetcher-cache-key", "headers", "hide-pagination", "hide-pagination-when-optional", "hide-toolbar", "initial-fetcher-params", "loading", "pagination-attributes", "row-key", "search-input", "sort-handler-function", "sortable", "table-preferences", "onRow:click"]),
|
|
3895
|
-
f.$slots["outside-actions"] && _(
|
|
3895
|
+
f.$slots["outside-actions"] && _(A) ? (p(), $("div", ul, [
|
|
3896
3896
|
P(f.$slots, "outside-actions", {}, void 0, !0)
|
|
3897
3897
|
])) : j("", !0)
|
|
3898
3898
|
]),
|
|
@@ -3952,7 +3952,7 @@ ${s.value}
|
|
|
3952
3952
|
};
|
|
3953
3953
|
return (l, c) => {
|
|
3954
3954
|
const d = D("KAlert"), u = D("KPrompt");
|
|
3955
|
-
return
|
|
3955
|
+
return p(), M(u, {
|
|
3956
3956
|
"action-button-appearance": "danger",
|
|
3957
3957
|
"action-button-disabled": e.actionPending,
|
|
3958
3958
|
"action-button-text": "Yes, delete",
|
|
@@ -3963,10 +3963,10 @@ ${s.value}
|
|
|
3963
3963
|
onCancel: a,
|
|
3964
3964
|
onProceed: s
|
|
3965
3965
|
}, {
|
|
3966
|
-
default:
|
|
3967
|
-
e.error ? (
|
|
3966
|
+
default: k(() => [
|
|
3967
|
+
e.error ? (p(), $("div", fl, [
|
|
3968
3968
|
R(d, { appearance: "danger" }, {
|
|
3969
|
-
default:
|
|
3969
|
+
default: k(() => [
|
|
3970
3970
|
U(L(e.error), 1)
|
|
3971
3971
|
]),
|
|
3972
3972
|
_: 1
|
|
@@ -3976,21 +3976,21 @@ ${s.value}
|
|
|
3976
3976
|
class: "message",
|
|
3977
3977
|
keypath: i.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
3978
3978
|
tag: "p"
|
|
3979
|
-
},
|
|
3980
|
-
entityType:
|
|
3979
|
+
}, $e({
|
|
3980
|
+
entityType: k(() => [
|
|
3981
3981
|
U(L(i.entityType), 1)
|
|
3982
3982
|
]),
|
|
3983
3983
|
_: 2
|
|
3984
3984
|
}, [
|
|
3985
3985
|
i.entityName ? {
|
|
3986
3986
|
name: "entityName",
|
|
3987
|
-
fn:
|
|
3987
|
+
fn: k(() => [
|
|
3988
3988
|
B("strong", null, L(i.entityName), 1)
|
|
3989
3989
|
]),
|
|
3990
3990
|
key: "0"
|
|
3991
3991
|
} : void 0
|
|
3992
3992
|
]), 1032, ["keypath"]),
|
|
3993
|
-
i.description || l.$slots.description ? (
|
|
3993
|
+
i.description || l.$slots.description ? (p(), $("div", pl, [
|
|
3994
3994
|
P(l.$slots, "description", {}, () => [
|
|
3995
3995
|
B("p", null, L(i.description), 1)
|
|
3996
3996
|
], !0)
|
|
@@ -4000,13 +4000,13 @@ ${s.value}
|
|
|
4000
4000
|
}, 8, ["action-button-disabled", "confirmation-text", "title", "visible"]);
|
|
4001
4001
|
};
|
|
4002
4002
|
}
|
|
4003
|
-
}), ws = /* @__PURE__ */ le(ml, [["__scopeId", "data-v-4361d622"]]),
|
|
4003
|
+
}), ws = /* @__PURE__ */ le(ml, [["__scopeId", "data-v-4361d622"]]), yl = {
|
|
4004
4004
|
fill: "none",
|
|
4005
4005
|
height: "20",
|
|
4006
4006
|
viewBox: "0 0 20 20",
|
|
4007
4007
|
width: "20",
|
|
4008
4008
|
xmlns: "http://www.w3.org/2000/svg"
|
|
4009
|
-
},
|
|
4009
|
+
}, gl = {
|
|
4010
4010
|
id: "mask0_180_20349",
|
|
4011
4011
|
height: "20",
|
|
4012
4012
|
maskUnits: "userSpaceOnUse",
|
|
@@ -4014,7 +4014,7 @@ ${s.value}
|
|
|
4014
4014
|
width: "20",
|
|
4015
4015
|
x: "0",
|
|
4016
4016
|
y: "0"
|
|
4017
|
-
},
|
|
4017
|
+
}, hl = ["fill"], vl = { mask: "url(#mask0_180_20349)" }, bl = ["fill"], Dt = /* @__PURE__ */ z({
|
|
4018
4018
|
__name: "IconFilter",
|
|
4019
4019
|
props: {
|
|
4020
4020
|
color: {
|
|
@@ -4023,13 +4023,13 @@ ${s.value}
|
|
|
4023
4023
|
}
|
|
4024
4024
|
},
|
|
4025
4025
|
setup(e) {
|
|
4026
|
-
return (t, n) => (
|
|
4027
|
-
B("mask",
|
|
4026
|
+
return (t, n) => (p(), $("svg", yl, [
|
|
4027
|
+
B("mask", gl, [
|
|
4028
4028
|
B("rect", {
|
|
4029
4029
|
fill: e.color,
|
|
4030
4030
|
height: "20",
|
|
4031
4031
|
width: "20"
|
|
4032
|
-
}, null, 8,
|
|
4032
|
+
}, null, 8, hl)
|
|
4033
4033
|
]),
|
|
4034
4034
|
B("g", vl, [
|
|
4035
4035
|
B("path", {
|
|
@@ -4087,22 +4087,22 @@ ${s.value}
|
|
|
4087
4087
|
o.value = !o.value;
|
|
4088
4088
|
}, u = (S) => {
|
|
4089
4089
|
s.value.has(S) ? s.value.delete(S) : s.value.add(S);
|
|
4090
|
-
},
|
|
4090
|
+
}, m = (S) => {
|
|
4091
4091
|
r("update:modelValue", S);
|
|
4092
|
-
},
|
|
4093
|
-
|
|
4094
|
-
},
|
|
4092
|
+
}, g = () => {
|
|
4093
|
+
m("");
|
|
4094
|
+
}, y = (S) => `filter-${S}`, v = (S) => {
|
|
4095
4095
|
var w, O;
|
|
4096
4096
|
return (((O = (w = i.config.schema) == null ? void 0 : w[S]) == null ? void 0 : O.values) ?? []).map((f) => typeof f == "string" ? { value: f, label: f } : f);
|
|
4097
|
-
},
|
|
4097
|
+
}, h = (S) => {
|
|
4098
4098
|
var w, O;
|
|
4099
4099
|
return ((O = (w = i.config.schema) == null ? void 0 : w[S]) == null ? void 0 : O.type) ?? "text";
|
|
4100
|
-
},
|
|
4100
|
+
}, A = (S) => {
|
|
4101
4101
|
a.value = {
|
|
4102
4102
|
...a.value,
|
|
4103
4103
|
[S]: ""
|
|
4104
4104
|
}, E();
|
|
4105
|
-
},
|
|
4105
|
+
}, C = () => {
|
|
4106
4106
|
a.value = {}, E(!0);
|
|
4107
4107
|
}, E = (S = !1) => {
|
|
4108
4108
|
const w = Object.keys(a.value).reduce((O, f) => (a.value[f] && (O[f] = `${a.value[f]}`), O), {});
|
|
@@ -4117,36 +4117,36 @@ ${s.value}
|
|
|
4117
4117
|
};
|
|
4118
4118
|
return (S, w) => {
|
|
4119
4119
|
const O = D("KInput"), f = D("KButton"), b = D("KSelect");
|
|
4120
|
-
return e.config.isExactMatch ? (
|
|
4120
|
+
return e.config.isExactMatch ? (p(), M(O, {
|
|
4121
4121
|
key: 0,
|
|
4122
4122
|
autocomplete: "off",
|
|
4123
4123
|
class: "kong-ui-entity-filter-input",
|
|
4124
4124
|
"data-testid": "search-input",
|
|
4125
4125
|
"model-value": e.modelValue,
|
|
4126
4126
|
placeholder: e.config.placeholder,
|
|
4127
|
-
"onUpdate:modelValue":
|
|
4127
|
+
"onUpdate:modelValue": m
|
|
4128
4128
|
}, {
|
|
4129
|
-
before:
|
|
4129
|
+
before: k(() => [
|
|
4130
4130
|
R(Dt)
|
|
4131
4131
|
]),
|
|
4132
|
-
after:
|
|
4132
|
+
after: k(() => [
|
|
4133
4133
|
xe(R(_(si), {
|
|
4134
4134
|
class: "kong-ui-entity-filter-clear",
|
|
4135
4135
|
role: "button",
|
|
4136
4136
|
tabindex: "0",
|
|
4137
|
-
onClick:
|
|
4137
|
+
onClick: g
|
|
4138
4138
|
}, null, 512), [
|
|
4139
4139
|
[Ce, e.modelValue !== ""]
|
|
4140
4140
|
])
|
|
4141
4141
|
]),
|
|
4142
4142
|
_: 1
|
|
4143
|
-
}, 8, ["model-value", "placeholder"])) : (
|
|
4143
|
+
}, 8, ["model-value", "placeholder"])) : (p(), $("div", xl, [
|
|
4144
4144
|
R(f, {
|
|
4145
4145
|
appearance: "tertiary",
|
|
4146
4146
|
"data-testid": "filter-button",
|
|
4147
4147
|
onClick: d
|
|
4148
4148
|
}, {
|
|
4149
|
-
default:
|
|
4149
|
+
default: k(() => [
|
|
4150
4150
|
R(Dt),
|
|
4151
4151
|
U(" " + L(_(n)("filter.filterButtonText")) + " " + L(l.value.length > 0 ? `(${l.value.length})` : ""), 1)
|
|
4152
4152
|
]),
|
|
@@ -4159,9 +4159,9 @@ ${s.value}
|
|
|
4159
4159
|
[Ce, o.value]
|
|
4160
4160
|
]),
|
|
4161
4161
|
xe(B("div", Cl, [
|
|
4162
|
-
(
|
|
4162
|
+
(p(!0), $(ue, null, ce(c.value, (x) => {
|
|
4163
4163
|
var H, J;
|
|
4164
|
-
return
|
|
4164
|
+
return p(), $("div", {
|
|
4165
4165
|
key: x.value,
|
|
4166
4166
|
class: "kong-ui-entity-filter-menu-item",
|
|
4167
4167
|
"data-testid": x.value
|
|
@@ -4185,25 +4185,25 @@ ${s.value}
|
|
|
4185
4185
|
xe(B("div", wl, [
|
|
4186
4186
|
B("label", {
|
|
4187
4187
|
class: "menu-item-label",
|
|
4188
|
-
for:
|
|
4188
|
+
for: y(x.value)
|
|
4189
4189
|
}, L(_(n)("filter.fieldLabel")), 9, Sl),
|
|
4190
|
-
((J = (H = e.config.schema) == null ? void 0 : H[x.value]) == null ? void 0 : J.type) === "select" ? (
|
|
4190
|
+
((J = (H = e.config.schema) == null ? void 0 : H[x.value]) == null ? void 0 : J.type) === "select" ? (p(), M(b, {
|
|
4191
4191
|
key: 0,
|
|
4192
|
-
id:
|
|
4192
|
+
id: y(x.value),
|
|
4193
4193
|
modelValue: a.value[x.value],
|
|
4194
4194
|
"onUpdate:modelValue": (I) => a.value[x.value] = I,
|
|
4195
4195
|
"enable-filtering": W(x.value),
|
|
4196
4196
|
"filter-function": (I) => X(x.value, I),
|
|
4197
4197
|
items: v(x.value),
|
|
4198
4198
|
placeholder: _(n)("filter.selectPlaceholder")
|
|
4199
|
-
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "enable-filtering", "filter-function", "items", "placeholder"])) : (
|
|
4199
|
+
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "enable-filtering", "filter-function", "items", "placeholder"])) : (p(), M(O, {
|
|
4200
4200
|
key: 1,
|
|
4201
|
-
id:
|
|
4201
|
+
id: y(x.value),
|
|
4202
4202
|
modelValue: a.value[x.value],
|
|
4203
4203
|
"onUpdate:modelValue": (I) => a.value[x.value] = I,
|
|
4204
4204
|
autocomplete: "off",
|
|
4205
4205
|
placeholder: _(n)("filter.inputPlaceholder"),
|
|
4206
|
-
type:
|
|
4206
|
+
type: h(x.value)
|
|
4207
4207
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
4208
4208
|
], 512), [
|
|
4209
4209
|
[Ce, s.value.has(x.value)]
|
|
@@ -4215,7 +4215,7 @@ ${s.value}
|
|
|
4215
4215
|
size: "small",
|
|
4216
4216
|
onClick: w[0] || (w[0] = (I) => E(!0))
|
|
4217
4217
|
}, {
|
|
4218
|
-
default:
|
|
4218
|
+
default: k(() => [
|
|
4219
4219
|
U(L(_(n)("filter.applyButtonText")), 1)
|
|
4220
4220
|
]),
|
|
4221
4221
|
_: 1
|
|
@@ -4224,9 +4224,9 @@ ${s.value}
|
|
|
4224
4224
|
appearance: "tertiary",
|
|
4225
4225
|
"data-testid": "clear-filter",
|
|
4226
4226
|
size: "small",
|
|
4227
|
-
onClick: (I) =>
|
|
4227
|
+
onClick: (I) => A(x.value)
|
|
4228
4228
|
}, {
|
|
4229
|
-
default:
|
|
4229
|
+
default: k(() => [
|
|
4230
4230
|
U(L(_(n)("filter.clearButtonText")), 1)
|
|
4231
4231
|
]),
|
|
4232
4232
|
_: 1
|
|
@@ -4240,9 +4240,9 @@ ${s.value}
|
|
|
4240
4240
|
R(f, {
|
|
4241
4241
|
appearance: "tertiary",
|
|
4242
4242
|
size: "small",
|
|
4243
|
-
onClick:
|
|
4243
|
+
onClick: C
|
|
4244
4244
|
}, {
|
|
4245
|
-
default:
|
|
4245
|
+
default: k(() => [
|
|
4246
4246
|
U(L(_(n)("filter.clearAllButtonText")), 1)
|
|
4247
4247
|
]),
|
|
4248
4248
|
_: 1
|
|
@@ -4302,10 +4302,10 @@ ${s.value}
|
|
|
4302
4302
|
}
|
|
4303
4303
|
}
|
|
4304
4304
|
};
|
|
4305
|
-
return (u,
|
|
4306
|
-
const
|
|
4307
|
-
return
|
|
4308
|
-
R(
|
|
4305
|
+
return (u, m) => {
|
|
4306
|
+
const g = D("KPrompt");
|
|
4307
|
+
return p(), M(Yt, { to: "body" }, [
|
|
4308
|
+
R(g, {
|
|
4309
4309
|
"action-button-disabled": a.value,
|
|
4310
4310
|
"action-button-text": l.value,
|
|
4311
4311
|
"data-testid": `${e.entityType}-${e.entityId}-toggle-prompt`,
|
|
@@ -4314,15 +4314,15 @@ ${s.value}
|
|
|
4314
4314
|
onCancel: c,
|
|
4315
4315
|
onProceed: d
|
|
4316
4316
|
}, {
|
|
4317
|
-
default:
|
|
4317
|
+
default: k(() => [
|
|
4318
4318
|
R(_(i), {
|
|
4319
4319
|
keypath: `toggleModal.${r.action}.message`,
|
|
4320
4320
|
scope: "global"
|
|
4321
4321
|
}, {
|
|
4322
|
-
entityType:
|
|
4322
|
+
entityType: k(() => [
|
|
4323
4323
|
U(L(e.entityType), 1)
|
|
4324
4324
|
]),
|
|
4325
|
-
entityName:
|
|
4325
|
+
entityName: k(() => [
|
|
4326
4326
|
B("strong", null, L(e.entityName), 1)
|
|
4327
4327
|
]),
|
|
4328
4328
|
_: 1
|
|
@@ -4426,32 +4426,32 @@ const Kl = ["aria-labelledby"], Rl = { class: "form-section-wrapper" }, Nl = {
|
|
|
4426
4426
|
},
|
|
4427
4427
|
setup(e) {
|
|
4428
4428
|
const t = Pe(), n = Bl();
|
|
4429
|
-
return (i, r) => (
|
|
4429
|
+
return (i, r) => (p(), $("div", {
|
|
4430
4430
|
"aria-labelledby": e.title ? _(n) : void 0,
|
|
4431
4431
|
class: fe(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }]),
|
|
4432
4432
|
role: "group"
|
|
4433
4433
|
}, [
|
|
4434
4434
|
B("div", Rl, [
|
|
4435
|
-
e.hideInfoHeader ? j("", !0) : (
|
|
4435
|
+
e.hideInfoHeader ? j("", !0) : (p(), $("div", {
|
|
4436
4436
|
key: 0,
|
|
4437
4437
|
class: fe(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
4438
4438
|
}, [
|
|
4439
|
-
e.title ? (
|
|
4439
|
+
e.title ? (p(), M(De(e.titleTag), {
|
|
4440
4440
|
key: 0,
|
|
4441
4441
|
id: _(n),
|
|
4442
4442
|
class: "form-section-title"
|
|
4443
4443
|
}, {
|
|
4444
|
-
default:
|
|
4444
|
+
default: k(() => [
|
|
4445
4445
|
U(L(e.title), 1)
|
|
4446
4446
|
]),
|
|
4447
4447
|
_: 1
|
|
4448
4448
|
}, 8, ["id"])) : j("", !0),
|
|
4449
|
-
e.description || _(t).description ? (
|
|
4449
|
+
e.description || _(t).description ? (p(), $("div", Nl, [
|
|
4450
4450
|
P(i.$slots, "description", {}, () => [
|
|
4451
4451
|
B("p", null, L(e.description), 1)
|
|
4452
4452
|
], !0)
|
|
4453
4453
|
])) : j("", !0),
|
|
4454
|
-
_(t).footer ? (
|
|
4454
|
+
_(t).footer ? (p(), $("div", Ml, [
|
|
4455
4455
|
P(i.$slots, "footer", {}, void 0, !0)
|
|
4456
4456
|
])) : j("", !0)
|
|
4457
4457
|
], 2)),
|
|
@@ -4479,22 +4479,22 @@ const Kl = ["aria-labelledby"], Rl = { class: "form-section-wrapper" }, Nl = {
|
|
|
4479
4479
|
},
|
|
4480
4480
|
setup(e) {
|
|
4481
4481
|
const t = Pe();
|
|
4482
|
-
return (n, i) => (
|
|
4482
|
+
return (n, i) => (p(), $("div", Pl, [
|
|
4483
4483
|
B("header", Ul, [
|
|
4484
|
-
e.step != null ? (
|
|
4484
|
+
e.step != null ? (p(), $("div", ql, L(e.step), 1)) : j("", !0),
|
|
4485
4485
|
B("div", Hl, [
|
|
4486
4486
|
B("h2", Vl, [
|
|
4487
4487
|
P(n.$slots, "title", {}, () => [
|
|
4488
4488
|
U(L(e.title), 1)
|
|
4489
4489
|
], !0)
|
|
4490
4490
|
]),
|
|
4491
|
-
e.description || t.description ? (
|
|
4491
|
+
e.description || t.description ? (p(), $("div", Yl, [
|
|
4492
4492
|
P(n.$slots, "description", {}, () => [
|
|
4493
4493
|
U(L(e.description), 1)
|
|
4494
4494
|
], !0)
|
|
4495
4495
|
])) : j("", !0)
|
|
4496
4496
|
]),
|
|
4497
|
-
t.extra ? (
|
|
4497
|
+
t.extra ? (p(), $("div", Wl, [
|
|
4498
4498
|
P(n.$slots, "extra", {}, void 0, !0)
|
|
4499
4499
|
])) : j("", !0)
|
|
4500
4500
|
]),
|
|
@@ -4544,21 +4544,21 @@ const Kl = ["aria-labelledby"], Rl = { class: "form-section-wrapper" }, Nl = {
|
|
|
4544
4544
|
a.value = o;
|
|
4545
4545
|
}, 1800));
|
|
4546
4546
|
};
|
|
4547
|
-
return (u,
|
|
4548
|
-
const
|
|
4549
|
-
return
|
|
4550
|
-
s.value ? (
|
|
4547
|
+
return (u, m) => {
|
|
4548
|
+
const g = D("KTooltip"), y = D("KExternalLink"), v = D("KClipboardProvider");
|
|
4549
|
+
return p(), $("div", zl, [
|
|
4550
|
+
s.value ? (p(), $("div", Ql, L(c.value), 1)) : l.value ? l.value ? (p(), M(y, {
|
|
4551
4551
|
key: 2,
|
|
4552
4552
|
class: "entity-link",
|
|
4553
4553
|
"hide-icon": !e.newWindow,
|
|
4554
4554
|
href: e.externalLink,
|
|
4555
4555
|
target: e.newWindow ? "_blank" : "_self"
|
|
4556
4556
|
}, {
|
|
4557
|
-
default:
|
|
4558
|
-
R(
|
|
4557
|
+
default: k(() => [
|
|
4558
|
+
R(g, {
|
|
4559
4559
|
text: _(i) && e.entityLinkData.label || ""
|
|
4560
4560
|
}, {
|
|
4561
|
-
default:
|
|
4561
|
+
default: k(() => [
|
|
4562
4562
|
B("span", {
|
|
4563
4563
|
ref_key: "textContent",
|
|
4564
4564
|
ref: n,
|
|
@@ -4569,20 +4569,20 @@ const Kl = ["aria-labelledby"], Rl = { class: "form-section-wrapper" }, Nl = {
|
|
|
4569
4569
|
}, 8, ["text"])
|
|
4570
4570
|
]),
|
|
4571
4571
|
_: 1
|
|
4572
|
-
}, 8, ["hide-icon", "href", "target"])) : j("", !0) : (
|
|
4573
|
-
l.value && e.allowCopy ? (
|
|
4572
|
+
}, 8, ["hide-icon", "href", "target"])) : j("", !0) : (p(), $("div", Zl, L(" – "))),
|
|
4573
|
+
l.value && e.allowCopy ? (p(), M(g, {
|
|
4574
4574
|
key: a.value,
|
|
4575
4575
|
class: "copy-uuid-tooltip",
|
|
4576
4576
|
"max-width": "160",
|
|
4577
4577
|
placement: "bottom-end",
|
|
4578
4578
|
text: a.value
|
|
4579
4579
|
}, {
|
|
4580
|
-
default:
|
|
4580
|
+
default: k(() => [
|
|
4581
4581
|
R(v, null, {
|
|
4582
|
-
default:
|
|
4582
|
+
default: k(({ copyToClipboard: h }) => [
|
|
4583
4583
|
B("span", {
|
|
4584
4584
|
class: "entity-link-copy-id",
|
|
4585
|
-
onClick: Be((
|
|
4585
|
+
onClick: Be((A) => d(h), ["stop"])
|
|
4586
4586
|
}, [
|
|
4587
4587
|
R(_(ui), {
|
|
4588
4588
|
class: "copy-icon",
|
|
@@ -4633,7 +4633,7 @@ const Kl = ["aria-labelledby"], Rl = { class: "form-section-wrapper" }, Nl = {
|
|
|
4633
4633
|
appearance: {
|
|
4634
4634
|
type: String,
|
|
4635
4635
|
default: () => "primary",
|
|
4636
|
-
validator: (e) =>
|
|
4636
|
+
validator: (e) => ht.includes(e)
|
|
4637
4637
|
},
|
|
4638
4638
|
title: {
|
|
4639
4639
|
type: String,
|
|
@@ -4668,18 +4668,18 @@ const Kl = ["aria-labelledby"], Rl = { class: "form-section-wrapper" }, Nl = {
|
|
|
4668
4668
|
},
|
|
4669
4669
|
emits: ["click:create", "click:learn-more"],
|
|
4670
4670
|
setup(e) {
|
|
4671
|
-
const t = e, { i18n: { t: n } } = Y.useI18n(), i = N(!1), r = T(() => i.value && !!t.actionButtonText), o = T(() =>
|
|
4671
|
+
const t = e, { i18n: { t: n } } = Y.useI18n(), i = N(!1), r = T(() => i.value && !!t.actionButtonText), o = T(() => ht.includes(t.appearance) ? t.appearance : ["primary", t.appearance]);
|
|
4672
4672
|
return it(async () => {
|
|
4673
4673
|
i.value = await t.canCreate();
|
|
4674
4674
|
}), nt(() => ti(`EntityEmptyState is deprecated and will be removed in future releases. Please use the KEmptyState component instead.
|
|
4675
4675
|
Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) => {
|
|
4676
4676
|
const l = D("KCard");
|
|
4677
|
-
return
|
|
4677
|
+
return p(), $("div", ts, [
|
|
4678
4678
|
B("div", ns, [
|
|
4679
|
-
a.$slots.image ? (
|
|
4679
|
+
a.$slots.image ? (p(), $("div", is, [
|
|
4680
4680
|
P(a.$slots, "image", {}, void 0, !0)
|
|
4681
4681
|
])) : j("", !0),
|
|
4682
|
-
e.title || a.$slots.title ? (
|
|
4682
|
+
e.title || a.$slots.title ? (p(), $("div", rs, [
|
|
4683
4683
|
B("h1", {
|
|
4684
4684
|
class: fe(o.value)
|
|
4685
4685
|
}, [
|
|
@@ -4688,12 +4688,12 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4688
4688
|
], !0)
|
|
4689
4689
|
], 2)
|
|
4690
4690
|
])) : j("", !0),
|
|
4691
|
-
e.description || a.$slots.default ? (
|
|
4691
|
+
e.description || a.$slots.default ? (p(), $("div", as, [
|
|
4692
4692
|
P(a.$slots, "default", {}, () => [
|
|
4693
4693
|
B("p", null, L(e.description), 1)
|
|
4694
4694
|
], !0)
|
|
4695
4695
|
])) : j("", !0),
|
|
4696
|
-
e.pricing || a.$slots.pricing ? (
|
|
4696
|
+
e.pricing || a.$slots.pricing ? (p(), $("div", os, [
|
|
4697
4697
|
B("p", null, [
|
|
4698
4698
|
B("b", null, L(_(n)("emptyState.pricingTitle")), 1),
|
|
4699
4699
|
s[2] || (s[2] = U()),
|
|
@@ -4703,32 +4703,32 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4703
4703
|
])
|
|
4704
4704
|
])) : j("", !0)
|
|
4705
4705
|
]),
|
|
4706
|
-
a.$slots.message ? (
|
|
4706
|
+
a.$slots.message ? (p(), $("div", ls, [
|
|
4707
4707
|
P(a.$slots, "message", {}, void 0, !0)
|
|
4708
4708
|
])) : j("", !0),
|
|
4709
|
-
r.value || e.learnMore || a.$slots.actions ? (
|
|
4709
|
+
r.value || e.learnMore || a.$slots.actions ? (p(), $("div", ss, [
|
|
4710
4710
|
P(a.$slots, "actions", {}, () => [
|
|
4711
|
-
r.value ? (
|
|
4711
|
+
r.value ? (p(), M(_(mt), {
|
|
4712
4712
|
key: 0,
|
|
4713
4713
|
appearance: "primary",
|
|
4714
4714
|
"data-testid": "entity-create-button",
|
|
4715
4715
|
size: e.appearance === "secondary" ? "medium" : "large",
|
|
4716
4716
|
onClick: s[0] || (s[0] = (c) => a.$emit("click:create"))
|
|
4717
4717
|
}, {
|
|
4718
|
-
default:
|
|
4718
|
+
default: k(() => [
|
|
4719
4719
|
R(_(Jt)),
|
|
4720
4720
|
U(" " + L(e.actionButtonText), 1)
|
|
4721
4721
|
]),
|
|
4722
4722
|
_: 1
|
|
4723
4723
|
}, 8, ["size"])) : j("", !0),
|
|
4724
|
-
e.learnMore ? (
|
|
4724
|
+
e.learnMore ? (p(), M(_(mt), {
|
|
4725
4725
|
key: 1,
|
|
4726
4726
|
appearance: "secondary",
|
|
4727
4727
|
"data-testid": "entity-learn-more-button",
|
|
4728
4728
|
size: e.appearance === "secondary" ? "medium" : "large",
|
|
4729
4729
|
onClick: s[1] || (s[1] = (c) => a.$emit("click:learn-more"))
|
|
4730
4730
|
}, {
|
|
4731
|
-
default:
|
|
4731
|
+
default: k(() => [
|
|
4732
4732
|
R(_(Wt), { decorative: "" }),
|
|
4733
4733
|
U(" " + L(_(n)("emptyState.learnMore")), 1)
|
|
4734
4734
|
]),
|
|
@@ -4736,18 +4736,18 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4736
4736
|
}, 8, ["size"])) : j("", !0)
|
|
4737
4737
|
], !0)
|
|
4738
4738
|
])) : j("", !0),
|
|
4739
|
-
e.features.length ? (
|
|
4740
|
-
(
|
|
4739
|
+
e.features.length ? (p(), $("div", cs, [
|
|
4740
|
+
(p(!0), $(ue, null, ce(e.features, (c, d) => (p(), M(l, {
|
|
4741
4741
|
key: c,
|
|
4742
4742
|
class: "entity-empty-state-card"
|
|
4743
4743
|
}, {
|
|
4744
|
-
title:
|
|
4745
|
-
a.$slots[`feature-${d}-icon`] ? (
|
|
4744
|
+
title: k(() => [
|
|
4745
|
+
a.$slots[`feature-${d}-icon`] ? (p(), $("div", us, [
|
|
4746
4746
|
P(a.$slots, `feature-${d}-icon`, {}, void 0, !0)
|
|
4747
4747
|
])) : j("", !0),
|
|
4748
4748
|
B("div", ds, L(c.title), 1)
|
|
4749
4749
|
]),
|
|
4750
|
-
default:
|
|
4750
|
+
default: k(() => [
|
|
4751
4751
|
B("div", {
|
|
4752
4752
|
title: c.description
|
|
4753
4753
|
}, L(c.description), 9, fs)
|
|
@@ -4755,13 +4755,13 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4755
4755
|
_: 2
|
|
4756
4756
|
}, 1024))), 128))
|
|
4757
4757
|
])) : j("", !0),
|
|
4758
|
-
a.$slots.bottom ? (
|
|
4758
|
+
a.$slots.bottom ? (p(), $("div", ps, [
|
|
4759
4759
|
P(a.$slots, "bottom", {}, void 0, !0)
|
|
4760
4760
|
])) : j("", !0)
|
|
4761
4761
|
]);
|
|
4762
4762
|
};
|
|
4763
4763
|
}
|
|
4764
|
-
}), Os = /* @__PURE__ */ le(ms, [["__scopeId", "data-v-645aae54"]]),
|
|
4764
|
+
}), Os = /* @__PURE__ */ le(ms, [["__scopeId", "data-v-645aae54"]]), ys = { key: 1 }, Ls = /* @__PURE__ */ z({
|
|
4765
4765
|
__name: "TableTags",
|
|
4766
4766
|
props: {
|
|
4767
4767
|
/** The tags to display in the table */
|
|
@@ -4789,27 +4789,27 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4789
4789
|
});
|
|
4790
4790
|
return (i, r) => {
|
|
4791
4791
|
var o;
|
|
4792
|
-
return ((o = n.value) == null ? void 0 : o.length) > 0 ? (
|
|
4793
|
-
default:
|
|
4794
|
-
(
|
|
4792
|
+
return ((o = n.value) == null ? void 0 : o.length) > 0 ? (p(), M(_(oi), { key: 0 }, {
|
|
4793
|
+
default: k(() => [
|
|
4794
|
+
(p(!0), $(ue, null, ce(n.value, (a) => (p(), M(_(li), {
|
|
4795
4795
|
key: a,
|
|
4796
4796
|
"max-width": e.tagMaxWidth,
|
|
4797
4797
|
onClick: r[0] || (r[0] = Be(() => {
|
|
4798
4798
|
}, ["stop"]))
|
|
4799
4799
|
}, {
|
|
4800
|
-
default:
|
|
4800
|
+
default: k(() => [
|
|
4801
4801
|
U(L(a), 1)
|
|
4802
4802
|
]),
|
|
4803
4803
|
_: 2
|
|
4804
4804
|
}, 1032, ["max-width"]))), 128))
|
|
4805
4805
|
]),
|
|
4806
4806
|
_: 1
|
|
4807
|
-
})) : (
|
|
4807
|
+
})) : (p(), $("span", ys, "-"));
|
|
4808
4808
|
};
|
|
4809
4809
|
}
|
|
4810
4810
|
}), { useAxios: Bs, useDeleteUrlBuilder: Ks, useErrors: Rs, useExternalLinkCreator: Ns, useFetchUrlBuilder: Ms, useFetcher: js, useFetcherCacheKey: Ds, useDebouncedFilter: Ps, useStringHelpers: Us, useHelpers: qs, useGatewayFeatureSupported: Hs, useTruncationDetector: Vs, useValidators: Ys, useSchemaProvider: Ws, useTableState: Js } = Y;
|
|
4811
4811
|
export {
|
|
4812
|
-
|
|
4812
|
+
ht as Appearances,
|
|
4813
4813
|
Jo as ConfigCardDisplay,
|
|
4814
4814
|
tn as ConfigCardItem,
|
|
4815
4815
|
ae as ConfigurationSchemaSection,
|
|
@@ -4827,13 +4827,13 @@ export {
|
|
|
4827
4827
|
Fs as EntityLink,
|
|
4828
4828
|
$s as EntityToggleModal,
|
|
4829
4829
|
fi as EntityTypes,
|
|
4830
|
-
|
|
4830
|
+
yi as EventGatewayTypesArray,
|
|
4831
4831
|
me as FetcherStatus,
|
|
4832
4832
|
Xi as InternalLinkItem,
|
|
4833
4833
|
nn as JsonCodeBlock,
|
|
4834
4834
|
Ts as PermissionsWrapper,
|
|
4835
4835
|
mi as SupportedEntityDeckArray,
|
|
4836
|
-
|
|
4836
|
+
Se as SupportedEntityType,
|
|
4837
4837
|
Ue as SupportedEntityTypesArray,
|
|
4838
4838
|
Ls as TableTags,
|
|
4839
4839
|
Jn as TerraformCodeBlock,
|