@kong-ui-public/entities-consumers 2.2.13 → 2.2.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities-consumers.es.js +360 -358
- package/dist/entities-consumers.umd.js +1 -1
- package/package.json +6 -6
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as ne, ref as E, computed as $, watch as ve, renderSlot as Z, createCommentVNode as
|
|
1
|
+
import { defineComponent as ne, ref as E, computed as $, watch as ve, renderSlot as Z, createCommentVNode as z, unref as m, useSlots as Ze, onBeforeMount as gt, resolveComponent as D, openBlock as f, createBlock as R, createSlots as ke, withCtx as g, createElementVNode as F, createTextVNode as W, toDisplayString as j, createVNode as O, createElementBlock as T, renderList as pe, Fragment as me, normalizeClass as Ie, withModifiers as Ge, withDirectives as Fe, vShow as Le, useCssVars as cn, resolveDynamicComponent as Ne, normalizeProps as ya, guardReactiveProps as ha, mergeProps as st, onMounted as va, onUnmounted as ba, normalizeStyle as dn, inject as Ca, pushScopeId as pn, popScopeId as fn, Teleport as ka, reactive as Bt } from "vue";
|
|
2
2
|
import { useRouter as yt } from "vue-router";
|
|
3
3
|
import { createI18n as ht, i18nTComponent as mn } from "@kong-ui-public/i18n";
|
|
4
4
|
import wa from "axios";
|
|
@@ -220,7 +220,7 @@ const ja = {
|
|
|
220
220
|
noSearchResultsMessage: "Please adjust the criteria and try again.",
|
|
221
221
|
noSearchResultsCtaText: "Clear"
|
|
222
222
|
}
|
|
223
|
-
},
|
|
223
|
+
}, Na = {
|
|
224
224
|
title: "Configuration",
|
|
225
225
|
actions: {
|
|
226
226
|
copy: "Copy JSON"
|
|
@@ -258,7 +258,7 @@ const ja = {
|
|
|
258
258
|
entryTitle: "Entry {index}",
|
|
259
259
|
structuredFormat: "Structured"
|
|
260
260
|
}
|
|
261
|
-
},
|
|
261
|
+
}, Ka = {
|
|
262
262
|
filterButtonText: "Filter",
|
|
263
263
|
fieldLabel: "Filter by:",
|
|
264
264
|
inputPlaceholder: "Enter a value",
|
|
@@ -266,15 +266,15 @@ const ja = {
|
|
|
266
266
|
applyButtonText: "Apply",
|
|
267
267
|
clearButtonText: "Clear",
|
|
268
268
|
clearAllButtonText: "Clear all filters"
|
|
269
|
-
},
|
|
269
|
+
}, qa = {
|
|
270
270
|
errors: {
|
|
271
271
|
fetch: "Could not fetch available items",
|
|
272
272
|
invalid: "Please select a valid value"
|
|
273
273
|
}
|
|
274
|
-
},
|
|
274
|
+
}, Ba = {
|
|
275
275
|
unexpected: "An unexpected error has occurred",
|
|
276
276
|
dataKeyUndefined: 'The data key "{dataKey}" does not exist in the response.'
|
|
277
|
-
},
|
|
277
|
+
}, Fa = {
|
|
278
278
|
enable: {
|
|
279
279
|
title: "Enable {entityType}",
|
|
280
280
|
message: "Are you sure you want to enable the {entityType} {entityName}?",
|
|
@@ -290,11 +290,11 @@ const ja = {
|
|
|
290
290
|
deleteModal: Ma,
|
|
291
291
|
baseForm: Oa,
|
|
292
292
|
baseTable: Ea,
|
|
293
|
-
baseConfigCard:
|
|
294
|
-
filter:
|
|
295
|
-
debouncedFilter:
|
|
296
|
-
errors:
|
|
297
|
-
toggleModal:
|
|
293
|
+
baseConfigCard: Na,
|
|
294
|
+
filter: Ka,
|
|
295
|
+
debouncedFilter: qa,
|
|
296
|
+
errors: Ba,
|
|
297
|
+
toggleModal: Fa
|
|
298
298
|
};
|
|
299
299
|
function bt() {
|
|
300
300
|
const e = ht("en-us", La);
|
|
@@ -371,46 +371,46 @@ function Ua(e, n, t, a = {
|
|
|
371
371
|
s.value = !1;
|
|
372
372
|
}
|
|
373
373
|
}, C = E(""), U = async (S) => {
|
|
374
|
-
var
|
|
374
|
+
var N, k, q;
|
|
375
375
|
if (C.value !== S)
|
|
376
376
|
if (C.value = S || "", d.value === void 0)
|
|
377
377
|
try {
|
|
378
378
|
if (s.value = !0, u.value = "", p.value = "", e.app === "konnect") {
|
|
379
|
-
let
|
|
380
|
-
S && (
|
|
381
|
-
const { data: b } = await r.get(`${
|
|
379
|
+
let B = v + "";
|
|
380
|
+
S && (B += `/${S}`);
|
|
381
|
+
const { data: b } = await r.get(`${B}?size=${t}`);
|
|
382
382
|
a.fetchedItemsKey in b ? c.value = b[a.fetchedItemsKey] : b != null && b.id ? c.value = [b] : c.value = [];
|
|
383
383
|
} else if (S) {
|
|
384
|
-
const
|
|
385
|
-
A(S) && a.searchKeys.includes("id") ?
|
|
386
|
-
const { data:
|
|
387
|
-
return [
|
|
388
|
-
})()) :
|
|
389
|
-
...a.searchKeys.filter((
|
|
390
|
-
const { data: V } = await r.get(`${v}?${
|
|
384
|
+
const B = [];
|
|
385
|
+
A(S) && a.searchKeys.includes("id") ? B.push((async () => {
|
|
386
|
+
const { data: K } = await r.get(`${v}/${S}`);
|
|
387
|
+
return [K[a.fetchedItemsKey] ?? K];
|
|
388
|
+
})()) : B.push(
|
|
389
|
+
...a.searchKeys.filter((K) => K !== "id").map(async (K) => {
|
|
390
|
+
const { data: V } = await r.get(`${v}?${K}=${S}`);
|
|
391
391
|
return V[a.fetchedItemsKey];
|
|
392
392
|
})
|
|
393
393
|
);
|
|
394
|
-
const b = await Promise.all(
|
|
395
|
-
c.value = [], (
|
|
394
|
+
const b = await Promise.all(B), I = /* @__PURE__ */ new Set();
|
|
395
|
+
c.value = [], (N = b == null ? void 0 : b.forEach) == null || N.call(b, (K) => {
|
|
396
396
|
var V;
|
|
397
|
-
(V =
|
|
397
|
+
(V = K == null ? void 0 : K.forEach) == null || V.call(K, (_) => {
|
|
398
398
|
I.has(_.id) || (I.add(_.id), c.value.push(_));
|
|
399
399
|
});
|
|
400
400
|
});
|
|
401
401
|
} else
|
|
402
402
|
c.value = h.value;
|
|
403
|
-
} catch (
|
|
404
|
-
((k =
|
|
403
|
+
} catch (B) {
|
|
404
|
+
((k = B == null ? void 0 : B.response) == null ? void 0 : k.status) === 404 ? p.value = o("debouncedFilter.errors.invalid") : (c.value = [], u.value = o("debouncedFilter.errors.fetch"));
|
|
405
405
|
} finally {
|
|
406
406
|
s.value = !1;
|
|
407
407
|
}
|
|
408
408
|
else
|
|
409
|
-
s.value = !0, p.value = "", S ? (c.value = (
|
|
409
|
+
s.value = !0, p.value = "", S ? (c.value = (q = d.value) == null ? void 0 : q.filter((B) => {
|
|
410
410
|
var b;
|
|
411
411
|
let I = !1;
|
|
412
|
-
for (const
|
|
413
|
-
const V = typeof
|
|
412
|
+
for (const K of a.searchKeys) {
|
|
413
|
+
const V = typeof B[K] == "string" ? (b = B[K]) == null ? void 0 : b.toLowerCase() : B[K];
|
|
414
414
|
V != null && V.includes(S.toLowerCase()) && (I = !0);
|
|
415
415
|
}
|
|
416
416
|
return I;
|
|
@@ -498,7 +498,9 @@ function Ra(e, n, t = "data") {
|
|
|
498
498
|
return { fetcher: async (l) => {
|
|
499
499
|
try {
|
|
500
500
|
i.value = { status: Se.Loading };
|
|
501
|
-
|
|
501
|
+
let s = o(l);
|
|
502
|
+
s.includes("filter[name]") && (s = `${s}&page[size]=${l.pageSize}&page[number]=${l.page}`);
|
|
503
|
+
const { data: u } = await r.get(s), p = t && t.replace(/[^\w-_]/gi, "");
|
|
502
504
|
let c;
|
|
503
505
|
u[p] && Array.isArray(u[p]) ? c = u[p] : Array.isArray(u) ? c = u : c = Object.keys(u).length ? [u] : [];
|
|
504
506
|
const h = {
|
|
@@ -538,7 +540,7 @@ function Ga() {
|
|
|
538
540
|
convertKeyToTitle: e
|
|
539
541
|
};
|
|
540
542
|
}
|
|
541
|
-
const vn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,
|
|
543
|
+
const vn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, Ft = (e) => {
|
|
542
544
|
if (typeof e != "string")
|
|
543
545
|
throw new TypeError("Invalid argument expected string");
|
|
544
546
|
const n = e.match(vn);
|
|
@@ -548,20 +550,20 @@ const vn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
548
550
|
}, Lt = (e) => e === "*" || e === "x" || e === "X", Ut = (e) => {
|
|
549
551
|
const n = parseInt(e, 10);
|
|
550
552
|
return isNaN(n) ? e : n;
|
|
551
|
-
},
|
|
553
|
+
}, za = (e, n) => typeof e != typeof n ? [String(e), String(n)] : [e, n], Ha = (e, n) => {
|
|
552
554
|
if (Lt(e) || Lt(n))
|
|
553
555
|
return 0;
|
|
554
|
-
const [t, a] =
|
|
556
|
+
const [t, a] = za(Ut(e), Ut(n));
|
|
555
557
|
return t > a ? 1 : t < a ? -1 : 0;
|
|
556
558
|
}, Pt = (e, n) => {
|
|
557
559
|
for (let t = 0; t < Math.max(e.length, n.length); t++) {
|
|
558
|
-
const a =
|
|
560
|
+
const a = Ha(e[t] || "0", n[t] || "0");
|
|
559
561
|
if (a !== 0)
|
|
560
562
|
return a;
|
|
561
563
|
}
|
|
562
564
|
return 0;
|
|
563
565
|
}, Ja = (e, n) => {
|
|
564
|
-
const t =
|
|
566
|
+
const t = Ft(e), a = Ft(n), r = t.pop(), o = a.pop(), i = Pt(t, a);
|
|
565
567
|
return i !== 0 ? i : r && o ? Pt(r.split("."), o.split(".")) : r || o ? r ? -1 : 1 : 0;
|
|
566
568
|
}, Dt = (e, n, t) => {
|
|
567
569
|
Wa(t);
|
|
@@ -631,7 +633,7 @@ const oe = {
|
|
|
631
633
|
}, rr = (e) => (pn("data-v-ac7fcfb4"), e = e(), fn(), e), or = ["aria-hidden"], ir = {
|
|
632
634
|
key: 0,
|
|
633
635
|
"data-testid": "kui-icon-svg-title"
|
|
634
|
-
}, lr = /* @__PURE__ */ rr(() => /* @__PURE__ */
|
|
636
|
+
}, lr = /* @__PURE__ */ rr(() => /* @__PURE__ */ F("path", {
|
|
635
637
|
d: "M5 22C4.45 22 3.97917 21.8042 3.5875 21.4125C3.19583 21.0208 3 20.55 3 20V6H5V20H16V22H5ZM9 18C8.45 18 7.97917 17.8042 7.5875 17.4125C7.19583 17.0208 7 16.55 7 16V4C7 3.45 7.19583 2.97917 7.5875 2.5875C7.97917 2.19583 8.45 2 9 2H18C18.55 2 19.0208 2.19583 19.4125 2.5875C19.8042 2.97917 20 3.45 20 4V16C20 16.55 19.8042 17.0208 19.4125 17.4125C19.0208 17.8042 18.55 18 18 18H9ZM9 16H18V4H9V16Z",
|
|
636
638
|
fill: "currentColor"
|
|
637
639
|
}, null, -1)), sr = /* @__PURE__ */ ne({
|
|
@@ -703,7 +705,7 @@ const oe = {
|
|
|
703
705
|
lineHeight: "0",
|
|
704
706
|
width: t.value
|
|
705
707
|
}));
|
|
706
|
-
return (r, o) => (f(), R(
|
|
708
|
+
return (r, o) => (f(), R(Ne(e.as), {
|
|
707
709
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
708
710
|
class: "kui-icon copy-icon",
|
|
709
711
|
"data-testid": "kui-icon-wrapper-copy-icon",
|
|
@@ -720,7 +722,7 @@ const oe = {
|
|
|
720
722
|
width: "100%",
|
|
721
723
|
xmlns: "http://www.w3.org/2000/svg"
|
|
722
724
|
}, [
|
|
723
|
-
e.title ? (f(), T("title", ir, j(e.title), 1)) :
|
|
725
|
+
e.title ? (f(), T("title", ir, j(e.title), 1)) : z("", !0),
|
|
724
726
|
lr
|
|
725
727
|
], 8, or))
|
|
726
728
|
]),
|
|
@@ -808,9 +810,9 @@ const oe = {
|
|
|
808
810
|
return (d, w) => {
|
|
809
811
|
const v = D("KClipboardProvider");
|
|
810
812
|
return f(), T("div", dr, [
|
|
811
|
-
e.format !== "hidden" ? (f(), R(
|
|
813
|
+
e.format !== "hidden" ? (f(), R(Ne(e.idTooltip ? "KTooltip" : "div"), st({ key: 0 }, i.value, { "data-testid": "copy-id" }), {
|
|
812
814
|
default: g(() => [
|
|
813
|
-
|
|
815
|
+
F("div", {
|
|
814
816
|
class: Ie([
|
|
815
817
|
"uuid-container",
|
|
816
818
|
e.truncated ? "truncated-uuid" : null,
|
|
@@ -819,12 +821,12 @@ const oe = {
|
|
|
819
821
|
}, j(p.value), 3)
|
|
820
822
|
]),
|
|
821
823
|
_: 1
|
|
822
|
-
}, 16)) :
|
|
823
|
-
(f(), R(
|
|
824
|
+
}, 16)) : z("", !0),
|
|
825
|
+
(f(), R(Ne(e.tooltip ? "KTooltip" : "div"), st(u.value, { class: "uuid-icon-wrapper" }), {
|
|
824
826
|
default: g(() => [
|
|
825
827
|
O(v, null, {
|
|
826
828
|
default: g(({ copyToClipboard: A }) => [
|
|
827
|
-
|
|
829
|
+
F("span", {
|
|
828
830
|
"data-testid": "copy-to-clipboard",
|
|
829
831
|
role: "button",
|
|
830
832
|
tabindex: "0",
|
|
@@ -879,13 +881,13 @@ const oe = {
|
|
|
879
881
|
var s;
|
|
880
882
|
return n.isArrayItem ? (s = o.value) != null && s.name ? a(o.value.name, "_") : t("baseConfigCard.general.entryTitle", { index: n.index }) : "";
|
|
881
883
|
});
|
|
882
|
-
return (s, u) => (f(), R(
|
|
884
|
+
return (s, u) => (f(), R(Ne(e.isArrayItem ? "fieldset" : "div"), {
|
|
883
885
|
class: Ie(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
884
886
|
}, {
|
|
885
887
|
default: g(() => [
|
|
886
888
|
e.isArrayItem ? (f(), T("legend", gr, [
|
|
887
|
-
|
|
888
|
-
])) :
|
|
889
|
+
F("b", null, j(l.value), 1)
|
|
890
|
+
])) : z("", !0),
|
|
889
891
|
(f(!0), T(me, null, pe(Object.keys(i.value), (p, c) => (f(), R(Ct, {
|
|
890
892
|
key: `${r.value}-property-${c}`,
|
|
891
893
|
item: {
|
|
@@ -952,11 +954,11 @@ const oe = {
|
|
|
952
954
|
}, 8, ["appearance"]);
|
|
953
955
|
};
|
|
954
956
|
}
|
|
955
|
-
}), Cr = "#0044f4", kr = "#e0e4ea", wr = "#3a3f51", Ir = "1px", _r = "20px", Sr = { class: "config-card-details-row" }, Ar = ["data-testid"], xr = ["data-testid"], Tr = ["data-testid"], $r = ["data-testid"], jr = { key: 1 }, Mr = ["data-testid"], Or = ["data-testid"], Er = ["data-testid"],
|
|
957
|
+
}), Cr = "#0044f4", kr = "#e0e4ea", wr = "#3a3f51", Ir = "1px", _r = "20px", Sr = { class: "config-card-details-row" }, Ar = ["data-testid"], xr = ["data-testid"], Tr = ["data-testid"], $r = ["data-testid"], jr = { key: 1 }, Mr = ["data-testid"], Or = ["data-testid"], Er = ["data-testid"], Nr = ["data-testid"], Kr = {
|
|
956
958
|
name: "ConfigCardItem",
|
|
957
959
|
components: { CopyUuid: Cn, JsonCardItem: kn, StatusBadge: br, InternalLinkItem: vr }
|
|
958
|
-
},
|
|
959
|
-
...
|
|
960
|
+
}, qr = /* @__PURE__ */ ne({
|
|
961
|
+
...Kr,
|
|
960
962
|
props: {
|
|
961
963
|
item: {
|
|
962
964
|
type: Object,
|
|
@@ -1111,7 +1113,7 @@ const oe = {
|
|
|
1111
1113
|
return (w, v) => {
|
|
1112
1114
|
const A = D("KLabel"), y = D("KBadge"), C = D("KTooltip");
|
|
1113
1115
|
return f(), T("div", Sr, [
|
|
1114
|
-
|
|
1116
|
+
F("div", {
|
|
1115
1117
|
class: "config-card-details-label",
|
|
1116
1118
|
"data-testid": `${e.item.key}-label`
|
|
1117
1119
|
}, [
|
|
@@ -1125,7 +1127,7 @@ const oe = {
|
|
|
1125
1127
|
s.value ? {
|
|
1126
1128
|
name: "tooltip",
|
|
1127
1129
|
fn: g(() => [
|
|
1128
|
-
|
|
1130
|
+
F("div", {
|
|
1129
1131
|
"data-testid": `${e.item.key}-label-tooltip`
|
|
1130
1132
|
}, [
|
|
1131
1133
|
Z(w.$slots, "label-tooltip", {}, () => [
|
|
@@ -1138,7 +1140,7 @@ const oe = {
|
|
|
1138
1140
|
]), 1024)
|
|
1139
1141
|
], !0)
|
|
1140
1142
|
], 8, Ar),
|
|
1141
|
-
|
|
1143
|
+
F("div", {
|
|
1142
1144
|
class: "config-card-details-value",
|
|
1143
1145
|
"data-testid": `${e.item.key}-property-value`
|
|
1144
1146
|
}, [
|
|
@@ -1146,7 +1148,7 @@ const oe = {
|
|
|
1146
1148
|
rowValue: e.item.value
|
|
1147
1149
|
}, () => [
|
|
1148
1150
|
l.value ? (f(), T("div", jr, [
|
|
1149
|
-
(f(), R(
|
|
1151
|
+
(f(), R(Ne(c.value.tag), ya(ha(c.value.attrs)), {
|
|
1150
1152
|
default: g(() => [
|
|
1151
1153
|
c.value.additionalComponent === "KBadge" ? (f(), T("div", {
|
|
1152
1154
|
key: 0,
|
|
@@ -1164,7 +1166,7 @@ const oe = {
|
|
|
1164
1166
|
]),
|
|
1165
1167
|
_: 2
|
|
1166
1168
|
}, 1032, ["data-testid", "tooltip"]))), 128))
|
|
1167
|
-
], 8, Mr)) :
|
|
1169
|
+
], 8, Mr)) : z("", !0),
|
|
1168
1170
|
c.value.additionalComponent === "CopyUuid" ? (f(), T("div", {
|
|
1169
1171
|
key: 1,
|
|
1170
1172
|
class: "copy-uuid-array",
|
|
@@ -1191,7 +1193,7 @@ const oe = {
|
|
|
1191
1193
|
]),
|
|
1192
1194
|
_: 2
|
|
1193
1195
|
}, 1032, ["appearance", "data-testid"]))), 128))
|
|
1194
|
-
], 8, Er)) :
|
|
1196
|
+
], 8, Er)) : z("", !0),
|
|
1195
1197
|
c.value.additionalComponent === "JsonCardItem" ? (f(), T("div", {
|
|
1196
1198
|
key: 3,
|
|
1197
1199
|
"data-testid": `${t.item.key}-json-array-content`
|
|
@@ -1202,12 +1204,12 @@ const oe = {
|
|
|
1202
1204
|
"is-array-item": "",
|
|
1203
1205
|
item: U
|
|
1204
1206
|
}, null, 8, ["index", "item"]))), 128))
|
|
1205
|
-
], 8,
|
|
1207
|
+
], 8, Nr)) : (f(), R(C, {
|
|
1206
1208
|
key: 4,
|
|
1207
1209
|
label: m(d) ? e.item.value : ""
|
|
1208
1210
|
}, {
|
|
1209
1211
|
default: g(() => [
|
|
1210
|
-
|
|
1212
|
+
F("span", {
|
|
1211
1213
|
ref_key: "textContent",
|
|
1212
1214
|
ref: h,
|
|
1213
1215
|
class: Ie(["attrs-data-text", { truncated: e.truncated }])
|
|
@@ -1227,15 +1229,15 @@ const oe = {
|
|
|
1227
1229
|
]);
|
|
1228
1230
|
};
|
|
1229
1231
|
}
|
|
1230
|
-
}), Ct = /* @__PURE__ */ ge(
|
|
1232
|
+
}), Ct = /* @__PURE__ */ ge(qr, [["__scopeId", "data-v-9c87856b"]]);
|
|
1231
1233
|
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
|
|
1232
1234
|
function wn(e) {
|
|
1233
1235
|
return typeof e > "u" || e === null;
|
|
1234
1236
|
}
|
|
1235
|
-
function
|
|
1237
|
+
function Br(e) {
|
|
1236
1238
|
return typeof e == "object" && e !== null;
|
|
1237
1239
|
}
|
|
1238
|
-
function
|
|
1240
|
+
function Fr(e) {
|
|
1239
1241
|
return Array.isArray(e) ? e : wn(e) ? [] : [e];
|
|
1240
1242
|
}
|
|
1241
1243
|
function Lr(e, n) {
|
|
@@ -1254,13 +1256,13 @@ function Ur(e, n) {
|
|
|
1254
1256
|
function Pr(e) {
|
|
1255
1257
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1256
1258
|
}
|
|
1257
|
-
var Dr = wn, Vr =
|
|
1259
|
+
var Dr = wn, Vr = Br, Rr = Fr, Gr = Ur, zr = Pr, Hr = Lr, re = {
|
|
1258
1260
|
isNothing: Dr,
|
|
1259
1261
|
isObject: Vr,
|
|
1260
1262
|
toArray: Rr,
|
|
1261
1263
|
repeat: Gr,
|
|
1262
|
-
isNegativeZero:
|
|
1263
|
-
extend:
|
|
1264
|
+
isNegativeZero: zr,
|
|
1265
|
+
extend: Hr
|
|
1264
1266
|
};
|
|
1265
1267
|
function In(e, n) {
|
|
1266
1268
|
var t = "", a = e.reason || "(unknown reason)";
|
|
@@ -1354,7 +1356,7 @@ function Xr(e, n) {
|
|
|
1354
1356
|
throw new se('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.');
|
|
1355
1357
|
}
|
|
1356
1358
|
var ie = Xr;
|
|
1357
|
-
function
|
|
1359
|
+
function zt(e, n) {
|
|
1358
1360
|
var t = [];
|
|
1359
1361
|
return e[n].forEach(function(a) {
|
|
1360
1362
|
var r = t.length;
|
|
@@ -1408,7 +1410,7 @@ ct.prototype.extend = function(e) {
|
|
|
1408
1410
|
throw new se("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1409
1411
|
});
|
|
1410
1412
|
var a = Object.create(ct.prototype);
|
|
1411
|
-
return a.implicit = (this.implicit || []).concat(n), a.explicit = (this.explicit || []).concat(t), a.compiledImplicit =
|
|
1413
|
+
return a.implicit = (this.implicit || []).concat(n), a.explicit = (this.explicit || []).concat(t), a.compiledImplicit = zt(a, "implicit"), a.compiledExplicit = zt(a, "explicit"), a.compiledTypeMap = eo(a.compiledImplicit, a.compiledExplicit), a;
|
|
1412
1414
|
};
|
|
1413
1415
|
var _n = ct, Sn = new ie("tag:yaml.org,2002:str", {
|
|
1414
1416
|
kind: "scalar",
|
|
@@ -1662,17 +1664,17 @@ var On = new ie("tag:yaml.org,2002:float", {
|
|
|
1662
1664
|
Mn,
|
|
1663
1665
|
On
|
|
1664
1666
|
]
|
|
1665
|
-
}),
|
|
1667
|
+
}), Nn = En, Kn = new RegExp(
|
|
1666
1668
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1667
|
-
),
|
|
1669
|
+
), qn = new RegExp(
|
|
1668
1670
|
"^([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]))?))?$"
|
|
1669
1671
|
);
|
|
1670
1672
|
function Co(e) {
|
|
1671
|
-
return e === null ? !1 :
|
|
1673
|
+
return e === null ? !1 : Kn.exec(e) !== null || qn.exec(e) !== null;
|
|
1672
1674
|
}
|
|
1673
1675
|
function ko(e) {
|
|
1674
1676
|
var n, t, a, r, o, i, l, s = 0, u = null, p, c, h;
|
|
1675
|
-
if (n =
|
|
1677
|
+
if (n = Kn.exec(e), n === null && (n = qn.exec(e)), n === null)
|
|
1676
1678
|
throw new Error("Date resolve error");
|
|
1677
1679
|
if (t = +n[1], a = +n[2] - 1, r = +n[3], !n[4])
|
|
1678
1680
|
return new Date(Date.UTC(t, a, r));
|
|
@@ -1686,7 +1688,7 @@ function ko(e) {
|
|
|
1686
1688
|
function wo(e) {
|
|
1687
1689
|
return e.toISOString();
|
|
1688
1690
|
}
|
|
1689
|
-
var
|
|
1691
|
+
var Bn = new ie("tag:yaml.org,2002:timestamp", {
|
|
1690
1692
|
kind: "scalar",
|
|
1691
1693
|
resolve: Co,
|
|
1692
1694
|
construct: ko,
|
|
@@ -1696,7 +1698,7 @@ var qn = new ie("tag:yaml.org,2002:timestamp", {
|
|
|
1696
1698
|
function Io(e) {
|
|
1697
1699
|
return e === "<<" || e === null;
|
|
1698
1700
|
}
|
|
1699
|
-
var
|
|
1701
|
+
var Fn = new ie("tag:yaml.org,2002:merge", {
|
|
1700
1702
|
kind: "scalar",
|
|
1701
1703
|
resolve: Io
|
|
1702
1704
|
}), kt = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
@@ -1776,7 +1778,7 @@ function Eo(e) {
|
|
|
1776
1778
|
}
|
|
1777
1779
|
return !0;
|
|
1778
1780
|
}
|
|
1779
|
-
function
|
|
1781
|
+
function No(e) {
|
|
1780
1782
|
if (e === null)
|
|
1781
1783
|
return [];
|
|
1782
1784
|
var n, t, a, r, o, i = e;
|
|
@@ -1787,28 +1789,28 @@ function Fo(e) {
|
|
|
1787
1789
|
var Pn = new ie("tag:yaml.org,2002:pairs", {
|
|
1788
1790
|
kind: "sequence",
|
|
1789
1791
|
resolve: Eo,
|
|
1790
|
-
construct:
|
|
1791
|
-
}),
|
|
1792
|
-
function
|
|
1792
|
+
construct: No
|
|
1793
|
+
}), Ko = Object.prototype.hasOwnProperty;
|
|
1794
|
+
function qo(e) {
|
|
1793
1795
|
if (e === null)
|
|
1794
1796
|
return !0;
|
|
1795
1797
|
var n, t = e;
|
|
1796
1798
|
for (n in t)
|
|
1797
|
-
if (
|
|
1799
|
+
if (Ko.call(t, n) && t[n] !== null)
|
|
1798
1800
|
return !1;
|
|
1799
1801
|
return !0;
|
|
1800
1802
|
}
|
|
1801
|
-
function
|
|
1803
|
+
function Bo(e) {
|
|
1802
1804
|
return e !== null ? e : {};
|
|
1803
1805
|
}
|
|
1804
1806
|
var Dn = new ie("tag:yaml.org,2002:set", {
|
|
1805
1807
|
kind: "mapping",
|
|
1806
|
-
resolve:
|
|
1807
|
-
construct:
|
|
1808
|
-
}), wt =
|
|
1808
|
+
resolve: qo,
|
|
1809
|
+
construct: Bo
|
|
1810
|
+
}), wt = Nn.extend({
|
|
1809
1811
|
implicit: [
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
+
Bn,
|
|
1813
|
+
Fn
|
|
1812
1814
|
],
|
|
1813
1815
|
explicit: [
|
|
1814
1816
|
Ln,
|
|
@@ -1816,7 +1818,7 @@ var Dn = new ie("tag:yaml.org,2002:set", {
|
|
|
1816
1818
|
Pn,
|
|
1817
1819
|
Dn
|
|
1818
1820
|
]
|
|
1819
|
-
}), _e = Object.prototype.hasOwnProperty,
|
|
1821
|
+
}), _e = Object.prototype.hasOwnProperty, ze = 1, Vn = 2, Rn = 3, He = 4, lt = 1, Fo = 2, Ht = 3, Lo = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Uo = /[\x85\u2028\u2029]/, Po = /[,\[\]\{\}]/, Gn = /^(?:!|!!|![a-z\-]+!)$/i, zn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1820
1822
|
function Jt(e) {
|
|
1821
1823
|
return Object.prototype.toString.call(e);
|
|
1822
1824
|
}
|
|
@@ -1852,10 +1854,10 @@ function Go(e) {
|
|
|
1852
1854
|
(e - 65536 & 1023) + 56320
|
|
1853
1855
|
);
|
|
1854
1856
|
}
|
|
1855
|
-
var
|
|
1857
|
+
var Hn = new Array(256), Jn = new Array(256);
|
|
1856
1858
|
for (var je = 0; je < 256; je++)
|
|
1857
|
-
|
|
1858
|
-
function
|
|
1859
|
+
Hn[je] = Wt(je) ? 1 : 0, Jn[je] = Wt(je);
|
|
1860
|
+
function zo(e, n) {
|
|
1859
1861
|
this.input = e, this.filename = n.filename || null, this.schema = n.schema || wt, this.onWarning = n.onWarning || null, this.legacy = n.legacy || !1, this.json = n.json || !1, this.listener = n.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.firstTabInLine = -1, this.documents = [];
|
|
1860
1862
|
}
|
|
1861
1863
|
function Wn(e, n) {
|
|
@@ -1882,7 +1884,7 @@ var Yt = {
|
|
|
1882
1884
|
},
|
|
1883
1885
|
TAG: function(e, n, t) {
|
|
1884
1886
|
var a, r;
|
|
1885
|
-
t.length !== 2 && M(e, "TAG directive accepts exactly two arguments"), a = t[0], r = t[1], Gn.test(a) || M(e, "ill-formed tag handle (first argument) of the TAG directive"), _e.call(e.tagMap, a) && M(e, 'there is a previously declared suffix for "' + a + '" tag handle'),
|
|
1887
|
+
t.length !== 2 && M(e, "TAG directive accepts exactly two arguments"), a = t[0], r = t[1], Gn.test(a) || M(e, "ill-formed tag handle (first argument) of the TAG directive"), _e.call(e.tagMap, a) && M(e, 'there is a previously declared suffix for "' + a + '" tag handle'), zn.test(r) || M(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1886
1888
|
try {
|
|
1887
1889
|
r = decodeURIComponent(r);
|
|
1888
1890
|
} catch {
|
|
@@ -1955,7 +1957,7 @@ function _t(e, n) {
|
|
|
1955
1957
|
n === 1 ? e.result += " " : n > 1 && (e.result += re.repeat(`
|
|
1956
1958
|
`, n - 1));
|
|
1957
1959
|
}
|
|
1958
|
-
function
|
|
1960
|
+
function Ho(e, n, t) {
|
|
1959
1961
|
var a, r, o, i, l, s, u, p, c = e.kind, h = e.result, d;
|
|
1960
1962
|
if (d = e.input.charCodeAt(e.position), fe(d) || Oe(d) || d === 35 || d === 38 || d === 42 || d === 33 || d === 124 || d === 62 || d === 39 || d === 34 || d === 37 || d === 64 || d === 96 || (d === 63 || d === 45) && (r = e.input.charCodeAt(e.position + 1), fe(r) || t && Oe(r)))
|
|
1961
1963
|
return !1;
|
|
@@ -2006,7 +2008,7 @@ function Wo(e, n) {
|
|
|
2006
2008
|
if (l === 92) {
|
|
2007
2009
|
if (we(e, t, e.position, !0), l = e.input.charCodeAt(++e.position), he(l))
|
|
2008
2010
|
ae(e, !1, n);
|
|
2009
|
-
else if (l < 256 &&
|
|
2011
|
+
else if (l < 256 && Hn[l])
|
|
2010
2012
|
e.result += Jn[l], e.position++;
|
|
2011
2013
|
else if ((i = Vo(l)) > 0) {
|
|
2012
2014
|
for (r = i, o = 0; r > 0; r--)
|
|
@@ -2031,7 +2033,7 @@ function Yo(e, n) {
|
|
|
2031
2033
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = l), C = e.input.charCodeAt(++e.position); C !== 0; ) {
|
|
2032
2034
|
if (ae(e, !0, n), C = e.input.charCodeAt(e.position), C === p)
|
|
2033
2035
|
return e.position++, e.tag = i, e.anchor = s, e.kind = d ? "mapping" : "sequence", e.result = l, !0;
|
|
2034
|
-
t ? C === 44 && M(e, "expected the node content, but found ','") : M(e, "missed comma between flow collection entries"), A = v = y = null, c = h = !1, C === 63 && (u = e.input.charCodeAt(e.position + 1), fe(u) && (c = h = !0, e.position++, ae(e, !0, n))), a = e.line, r = e.lineStart, o = e.position,
|
|
2036
|
+
t ? C === 44 && M(e, "expected the node content, but found ','") : M(e, "missed comma between flow collection entries"), A = v = y = null, c = h = !1, C === 63 && (u = e.input.charCodeAt(e.position + 1), fe(u) && (c = h = !0, e.position++, ae(e, !0, n))), a = e.line, r = e.lineStart, o = e.position, Ke(e, n, ze, !1, !0), A = e.tag, v = e.result, ae(e, !0, n), C = e.input.charCodeAt(e.position), (h || e.line === a) && C === 58 && (c = !0, C = e.input.charCodeAt(++e.position), ae(e, !0, n), Ke(e, n, ze, !1, !0), y = e.result), d ? Ee(e, l, w, A, v, y, a, r, o) : c ? l.push(Ee(e, null, w, A, v, y, a, r, o)) : l.push(v), ae(e, !0, n), C = e.input.charCodeAt(e.position), C === 44 ? (t = !0, C = e.input.charCodeAt(++e.position)) : t = !1;
|
|
2035
2037
|
}
|
|
2036
2038
|
M(e, "unexpected end of the stream within a flow collection");
|
|
2037
2039
|
}
|
|
@@ -2045,7 +2047,7 @@ function Zo(e, n) {
|
|
|
2045
2047
|
return !1;
|
|
2046
2048
|
for (e.kind = "scalar", e.result = ""; c !== 0; )
|
|
2047
2049
|
if (c = e.input.charCodeAt(++e.position), c === 43 || c === 45)
|
|
2048
|
-
lt === r ? r = c === 43 ?
|
|
2050
|
+
lt === r ? r = c === 43 ? Ht : Fo : M(e, "repeat of a chomping mode identifier");
|
|
2049
2051
|
else if ((p = Ro(c)) >= 0)
|
|
2050
2052
|
p === 0 ? M(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : i ? M(e, "repeat of an indentation width identifier") : (l = n + p - 1, i = !0);
|
|
2051
2053
|
else
|
|
@@ -2067,7 +2069,7 @@ function Zo(e, n) {
|
|
|
2067
2069
|
continue;
|
|
2068
2070
|
}
|
|
2069
2071
|
if (e.lineIndent < l) {
|
|
2070
|
-
r ===
|
|
2072
|
+
r === Ht ? e.result += re.repeat(`
|
|
2071
2073
|
`, o ? 1 + s : s) : r === lt && o && (e.result += `
|
|
2072
2074
|
`);
|
|
2073
2075
|
break;
|
|
@@ -2091,7 +2093,7 @@ function Qt(e, n) {
|
|
|
2091
2093
|
o.push(null), s = e.input.charCodeAt(e.position);
|
|
2092
2094
|
continue;
|
|
2093
2095
|
}
|
|
2094
|
-
if (t = e.line,
|
|
2096
|
+
if (t = e.line, Ke(e, n, Rn, !1, !0), o.push(e.result), ae(e, !0, -1), s = e.input.charCodeAt(e.position), (e.line === t || e.lineIndent > n) && s !== 0)
|
|
2095
2097
|
M(e, "bad indentation of a sequence entry");
|
|
2096
2098
|
else if (e.lineIndent < n)
|
|
2097
2099
|
break;
|
|
@@ -2106,7 +2108,7 @@ function Qo(e, n, t) {
|
|
|
2106
2108
|
if (!A && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, M(e, "tab characters must not be used in indentation")), a = e.input.charCodeAt(e.position + 1), o = e.line, (C === 63 || C === 58) && fe(a))
|
|
2107
2109
|
C === 63 ? (A && (Ee(e, c, h, d, w, null, i, l, s), d = w = v = null), y = !0, A = !0, r = !0) : A ? (A = !1, r = !0) : M(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, C = a;
|
|
2108
2110
|
else {
|
|
2109
|
-
if (i = e.line, l = e.lineStart, s = e.position, !
|
|
2111
|
+
if (i = e.line, l = e.lineStart, s = e.position, !Ke(e, t, Vn, !1, !0))
|
|
2110
2112
|
break;
|
|
2111
2113
|
if (e.line === o) {
|
|
2112
2114
|
for (C = e.input.charCodeAt(e.position); Ae(C); )
|
|
@@ -2122,7 +2124,7 @@ function Qo(e, n, t) {
|
|
|
2122
2124
|
else
|
|
2123
2125
|
return e.tag = u, e.anchor = p, !0;
|
|
2124
2126
|
}
|
|
2125
|
-
if ((e.line === o || e.lineIndent > n) && (A && (i = e.line, l = e.lineStart, s = e.position),
|
|
2127
|
+
if ((e.line === o || e.lineIndent > n) && (A && (i = e.line, l = e.lineStart, s = e.position), Ke(e, n, He, !0, r) && (A ? w = e.result : v = e.result), A || (Ee(e, c, h, d, w, v, i, l, s), d = w = v = null), ae(e, !0, -1), C = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > n) && C !== 0)
|
|
2126
2128
|
M(e, "bad indentation of a mapping entry");
|
|
2127
2129
|
else if (e.lineIndent < n)
|
|
2128
2130
|
break;
|
|
@@ -2143,7 +2145,7 @@ function Xo(e) {
|
|
|
2143
2145
|
i === 33 && (a ? M(e, "tag suffix cannot contain exclamation marks") : (r = e.input.slice(n - 1, e.position + 1), Gn.test(r) || M(e, "named tag handle cannot contain such characters"), a = !0, n = e.position + 1)), i = e.input.charCodeAt(++e.position);
|
|
2144
2146
|
o = e.input.slice(n, e.position), Po.test(o) && M(e, "tag suffix cannot contain flow indicator characters");
|
|
2145
2147
|
}
|
|
2146
|
-
o && !
|
|
2148
|
+
o && !zn.test(o) && M(e, "tag name cannot contain such characters: " + o);
|
|
2147
2149
|
try {
|
|
2148
2150
|
o = decodeURIComponent(o);
|
|
2149
2151
|
} catch {
|
|
@@ -2167,12 +2169,12 @@ function ti(e) {
|
|
|
2167
2169
|
a = e.input.charCodeAt(++e.position);
|
|
2168
2170
|
return e.position === n && M(e, "name of an alias node must contain at least one character"), t = e.input.slice(n, e.position), _e.call(e.anchorMap, t) || M(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], ae(e, !0, -1), !0;
|
|
2169
2171
|
}
|
|
2170
|
-
function
|
|
2172
|
+
function Ke(e, n, t, a, r) {
|
|
2171
2173
|
var o, i, l, s = 1, u = !1, p = !1, c, h, d, w, v, A;
|
|
2172
|
-
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = i = l =
|
|
2174
|
+
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = i = l = He === t || Rn === t, a && ae(e, !0, -1) && (u = !0, e.lineIndent > n ? s = 1 : e.lineIndent === n ? s = 0 : e.lineIndent < n && (s = -1)), s === 1)
|
|
2173
2175
|
for (; Xo(e) || ei(e); )
|
|
2174
2176
|
ae(e, !0, -1) ? (u = !0, l = o, e.lineIndent > n ? s = 1 : e.lineIndent === n ? s = 0 : e.lineIndent < n && (s = -1)) : l = !1;
|
|
2175
|
-
if (l && (l = u || r), (s === 1 ||
|
|
2177
|
+
if (l && (l = u || r), (s === 1 || He === t) && (ze === t || Vn === t ? v = n : v = n + 1, A = e.position - e.lineStart, s === 1 ? l && (Qt(e, A) || Qo(e, A, v)) || Yo(e, v) ? p = !0 : (i && Zo(e, v) || Jo(e, v) || Wo(e, v) ? p = !0 : ti(e) ? (p = !0, (e.tag !== null || e.anchor !== null) && M(e, "alias node should not have any properties")) : Ho(e, v, ze === t) && (p = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : s === 0 && (p = l && Qt(e, A))), e.tag === null)
|
|
2176
2178
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2177
2179
|
else if (e.tag === "?") {
|
|
2178
2180
|
for (e.result !== null && e.kind !== "scalar" && M(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), c = 0, h = e.implicitTypes.length; c < h; c += 1)
|
|
@@ -2215,7 +2217,7 @@ function ni(e) {
|
|
|
2215
2217
|
}
|
|
2216
2218
|
i !== 0 && It(e), _e.call(Yt, a) ? Yt[a](e, a, r) : Je(e, 'unknown document directive "' + a + '"');
|
|
2217
2219
|
}
|
|
2218
|
-
if (ae(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, ae(e, !0, -1)) : o && M(e, "directives end mark is expected"),
|
|
2220
|
+
if (ae(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, ae(e, !0, -1)) : o && M(e, "directives end mark is expected"), Ke(e, e.lineIndent - 1, He, !1, !0), ae(e, !0, -1), e.checkLineBreaks && Uo.test(e.input.slice(n, e.position)) && Je(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && Xe(e)) {
|
|
2219
2221
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, ae(e, !0, -1));
|
|
2220
2222
|
return;
|
|
2221
2223
|
}
|
|
@@ -2227,7 +2229,7 @@ function ni(e) {
|
|
|
2227
2229
|
function Yn(e, n) {
|
|
2228
2230
|
e = String(e), n = n || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2229
2231
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2230
|
-
var t = new
|
|
2232
|
+
var t = new zo(e, n), a = e.indexOf("\0");
|
|
2231
2233
|
for (a !== -1 && (t.position = a, M(t, "null byte is not allowed in input")), t.input += "\0"; t.input.charCodeAt(t.position) === 32; )
|
|
2232
2234
|
t.lineIndent += 1, t.position += 1;
|
|
2233
2235
|
for (; t.position < t.length - 1; )
|
|
@@ -2354,7 +2356,7 @@ function ji(e) {
|
|
|
2354
2356
|
function Mi(e) {
|
|
2355
2357
|
return !Ye(e) && e !== We;
|
|
2356
2358
|
}
|
|
2357
|
-
function
|
|
2359
|
+
function Be(e, n) {
|
|
2358
2360
|
var t = e.charCodeAt(n), a;
|
|
2359
2361
|
return t >= 55296 && t <= 56319 && n + 1 < e.length && (a = e.charCodeAt(n + 1), a >= 56320 && a <= 57343) ? (t - 55296) * 1024 + a - 56320 + 65536 : t;
|
|
2360
2362
|
}
|
|
@@ -2364,16 +2366,16 @@ function oa(e) {
|
|
|
2364
2366
|
}
|
|
2365
2367
|
var ia = 1, ft = 2, la = 3, sa = 4, Me = 5;
|
|
2366
2368
|
function Oi(e, n, t, a, r, o, i, l) {
|
|
2367
|
-
var s, u = 0, p = null, c = !1, h = !1, d = a !== -1, w = -1, v = ji(
|
|
2369
|
+
var s, u = 0, p = null, c = !1, h = !1, d = a !== -1, w = -1, v = ji(Be(e, 0)) && Mi(Be(e, e.length - 1));
|
|
2368
2370
|
if (n || i)
|
|
2369
2371
|
for (s = 0; s < e.length; u >= 65536 ? s += 2 : s++) {
|
|
2370
|
-
if (u =
|
|
2372
|
+
if (u = Be(e, s), !Ve(u))
|
|
2371
2373
|
return Me;
|
|
2372
2374
|
v = v && tn(u, p, l), p = u;
|
|
2373
2375
|
}
|
|
2374
2376
|
else {
|
|
2375
2377
|
for (s = 0; s < e.length; u >= 65536 ? s += 2 : s++) {
|
|
2376
|
-
if (u =
|
|
2378
|
+
if (u = Be(e, s), u === Pe)
|
|
2377
2379
|
c = !0, d && (h = h || // Foldable line = too long, and not more-indented.
|
|
2378
2380
|
s - w - 1 > a && e[w + 1] !== " ", w = s);
|
|
2379
2381
|
else if (!Ve(u))
|
|
@@ -2411,9 +2413,9 @@ function Ei(e, n, t, a, r) {
|
|
|
2411
2413
|
case la:
|
|
2412
2414
|
return "|" + nn(n, e.indent) + an(Xt(n, o));
|
|
2413
2415
|
case sa:
|
|
2414
|
-
return ">" + nn(n, e.indent) + an(Xt(
|
|
2416
|
+
return ">" + nn(n, e.indent) + an(Xt(Ni(n, i), o));
|
|
2415
2417
|
case Me:
|
|
2416
|
-
return '"' +
|
|
2418
|
+
return '"' + Ki(n) + '"';
|
|
2417
2419
|
default:
|
|
2418
2420
|
throw new se("impossible error: invalid scalar style");
|
|
2419
2421
|
}
|
|
@@ -2431,7 +2433,7 @@ function an(e) {
|
|
|
2431
2433
|
return e[e.length - 1] === `
|
|
2432
2434
|
` ? e.slice(0, -1) : e;
|
|
2433
2435
|
}
|
|
2434
|
-
function
|
|
2436
|
+
function Ni(e, n) {
|
|
2435
2437
|
for (var t = /(\n+)([^\n]*)/g, a = function() {
|
|
2436
2438
|
var u = e.indexOf(`
|
|
2437
2439
|
`);
|
|
@@ -2454,12 +2456,12 @@ function rn(e, n) {
|
|
|
2454
2456
|
`, e.length - r > n && i > r ? s += e.slice(r, i) + `
|
|
2455
2457
|
` + e.slice(i + 1) : s += e.slice(r), s.slice(1);
|
|
2456
2458
|
}
|
|
2457
|
-
function
|
|
2459
|
+
function Ki(e) {
|
|
2458
2460
|
for (var n = "", t = 0, a, r = 0; r < e.length; t >= 65536 ? r += 2 : r++)
|
|
2459
|
-
t =
|
|
2461
|
+
t = Be(e, r), a = le[t], !a && Ve(t) ? (n += e[r], t >= 65536 && (n += e[r + 1])) : n += a || Ai(t);
|
|
2460
2462
|
return n;
|
|
2461
2463
|
}
|
|
2462
|
-
function
|
|
2464
|
+
function qi(e, n, t) {
|
|
2463
2465
|
var a = "", r = e.tag, o, i, l;
|
|
2464
2466
|
for (o = 0, i = t.length; o < i; o += 1)
|
|
2465
2467
|
l = t[o], e.replacer && (l = e.replacer.call(t, String(o), l)), (Ce(e, n, l, !1, !1) || typeof l > "u" && Ce(e, n, null, !1, !1)) && (a !== "" && (a += "," + (e.condenseFlow ? "" : " ")), a += e.dump);
|
|
@@ -2471,13 +2473,13 @@ function on(e, n, t, a) {
|
|
|
2471
2473
|
s = t[i], e.replacer && (s = e.replacer.call(t, String(i), s)), (Ce(e, n + 1, s, !0, !0, !1, !0) || typeof s > "u" && Ce(e, n + 1, null, !0, !0, !1, !0)) && ((!a || r !== "") && (r += pt(e, n)), e.dump && Pe === e.dump.charCodeAt(0) ? r += "-" : r += "- ", r += e.dump);
|
|
2472
2474
|
e.tag = o, e.dump = r || "[]";
|
|
2473
2475
|
}
|
|
2474
|
-
function
|
|
2476
|
+
function Bi(e, n, t) {
|
|
2475
2477
|
var a = "", r = e.tag, o = Object.keys(t), i, l, s, u, p;
|
|
2476
2478
|
for (i = 0, l = o.length; i < l; i += 1)
|
|
2477
2479
|
p = "", a !== "" && (p += ", "), e.condenseFlow && (p += '"'), s = o[i], u = t[s], e.replacer && (u = e.replacer.call(t, s, u)), Ce(e, n, s, !1, !1) && (e.dump.length > 1024 && (p += "? "), p += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Ce(e, n, u, !1, !1) && (p += e.dump, a += p));
|
|
2478
2480
|
e.tag = r, e.dump = "{" + a + "}";
|
|
2479
2481
|
}
|
|
2480
|
-
function
|
|
2482
|
+
function Fi(e, n, t, a) {
|
|
2481
2483
|
var r = "", o = e.tag, i = Object.keys(t), l, s, u, p, c, h;
|
|
2482
2484
|
if (e.sortKeys === !0)
|
|
2483
2485
|
i.sort();
|
|
@@ -2515,9 +2517,9 @@ function Ce(e, n, t, a, r, o, i) {
|
|
|
2515
2517
|
e.dump = "*ref_" + c;
|
|
2516
2518
|
else {
|
|
2517
2519
|
if (p && h && !e.usedDuplicates[c] && (e.usedDuplicates[c] = !0), l === "[object Object]")
|
|
2518
|
-
a && Object.keys(e.dump).length !== 0 ? (
|
|
2520
|
+
a && Object.keys(e.dump).length !== 0 ? (Fi(e, n, e.dump, r), h && (e.dump = "&ref_" + c + e.dump)) : (Bi(e, n, e.dump), h && (e.dump = "&ref_" + c + " " + e.dump));
|
|
2519
2521
|
else if (l === "[object Array]")
|
|
2520
|
-
a && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? on(e, n - 1, e.dump, r) : on(e, n, e.dump, r), h && (e.dump = "&ref_" + c + e.dump)) : (
|
|
2522
|
+
a && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? on(e, n - 1, e.dump, r) : on(e, n, e.dump, r), h && (e.dump = "&ref_" + c + e.dump)) : (qi(e, n, e.dump), h && (e.dump = "&ref_" + c + " " + e.dump));
|
|
2521
2523
|
else if (l === "[object String]")
|
|
2522
2524
|
e.tag !== "?" && Ei(e, e.dump, n, o, s);
|
|
2523
2525
|
else {
|
|
@@ -2565,17 +2567,17 @@ function At(e, n) {
|
|
|
2565
2567
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + n + " instead, which is now safe by default.");
|
|
2566
2568
|
};
|
|
2567
2569
|
}
|
|
2568
|
-
var Vi = ie, Ri = _n, Gi = Tn,
|
|
2570
|
+
var Vi = ie, Ri = _n, Gi = Tn, zi = En, Hi = Nn, Ji = wt, Wi = Zn.load, Yi = Zn.loadAll, Zi = Di.dump, Qi = se, Xi = {
|
|
2569
2571
|
binary: Ln,
|
|
2570
2572
|
float: On,
|
|
2571
2573
|
map: xn,
|
|
2572
2574
|
null: $n,
|
|
2573
2575
|
pairs: Pn,
|
|
2574
2576
|
set: Dn,
|
|
2575
|
-
timestamp:
|
|
2577
|
+
timestamp: Bn,
|
|
2576
2578
|
bool: jn,
|
|
2577
2579
|
int: Mn,
|
|
2578
|
-
merge:
|
|
2580
|
+
merge: Fn,
|
|
2579
2581
|
omap: Un,
|
|
2580
2582
|
seq: An,
|
|
2581
2583
|
str: Sn
|
|
@@ -2583,8 +2585,8 @@ var Vi = ie, Ri = _n, Gi = Tn, Hi = En, zi = Fn, Ji = wt, Wi = Zn.load, Yi = Zn.
|
|
|
2583
2585
|
Type: Vi,
|
|
2584
2586
|
Schema: Ri,
|
|
2585
2587
|
FAILSAFE_SCHEMA: Gi,
|
|
2586
|
-
JSON_SCHEMA:
|
|
2587
|
-
CORE_SCHEMA:
|
|
2588
|
+
JSON_SCHEMA: zi,
|
|
2589
|
+
CORE_SCHEMA: Hi,
|
|
2588
2590
|
DEFAULT_SCHEMA: Ji,
|
|
2589
2591
|
load: Wi,
|
|
2590
2592
|
loadAll: Yi,
|
|
@@ -2664,7 +2666,7 @@ const rl = {
|
|
|
2664
2666
|
class: Ie(`config-card-details-${h}-props`),
|
|
2665
2667
|
"data-testid": `config-card-details-${h}-props`
|
|
2666
2668
|
}, [
|
|
2667
|
-
h !== "basic" ? (f(), T("div", il, j(h === "advanced" ? m(a)("baseConfigCard.sections.advanced") : m(a)("baseConfigCard.sections.plugin")), 1)) :
|
|
2669
|
+
h !== "basic" ? (f(), T("div", il, j(h === "advanced" ? m(a)("baseConfigCard.sections.advanced") : m(a)("baseConfigCard.sections.plugin")), 1)) : z("", !0),
|
|
2668
2670
|
(f(!0), T(me, null, pe(e.propertyCollections[h], (d) => (f(), R(Ct, {
|
|
2669
2671
|
key: d.key,
|
|
2670
2672
|
item: d
|
|
@@ -2689,7 +2691,7 @@ const rl = {
|
|
|
2689
2691
|
} : void 0
|
|
2690
2692
|
]), 1032, ["item"]))), 128))
|
|
2691
2693
|
], 10, ol))), 128))
|
|
2692
|
-
])) :
|
|
2694
|
+
])) : z("", !0),
|
|
2693
2695
|
e.format === "json" ? (f(), T("div", ll, [
|
|
2694
2696
|
n.fetcherUrl ? (f(), T("div", sl, [
|
|
2695
2697
|
O(p, { appearance: "get" }, {
|
|
@@ -2705,7 +2707,7 @@ const rl = {
|
|
|
2705
2707
|
language: "json",
|
|
2706
2708
|
theme: "dark"
|
|
2707
2709
|
}, null, 8, ["code"])
|
|
2708
|
-
])) :
|
|
2710
|
+
])) : z("", !0),
|
|
2709
2711
|
O(c, {
|
|
2710
2712
|
id: "config-card-codeblock",
|
|
2711
2713
|
class: Ie({ "config-card-display-json-content": n.fetcherUrl }),
|
|
@@ -2713,7 +2715,7 @@ const rl = {
|
|
|
2713
2715
|
language: "json",
|
|
2714
2716
|
theme: "dark"
|
|
2715
2717
|
}, null, 8, ["class", "code"])
|
|
2716
|
-
])) :
|
|
2718
|
+
])) : z("", !0),
|
|
2717
2719
|
e.format === "yaml" ? (f(), T("div", ul, [
|
|
2718
2720
|
O(c, {
|
|
2719
2721
|
id: "config-card-codeblock",
|
|
@@ -2721,7 +2723,7 @@ const rl = {
|
|
|
2721
2723
|
language: "yaml",
|
|
2722
2724
|
theme: "dark"
|
|
2723
2725
|
}, null, 8, ["code"])
|
|
2724
|
-
])) :
|
|
2726
|
+
])) : z("", !0)
|
|
2725
2727
|
], 64);
|
|
2726
2728
|
};
|
|
2727
2729
|
}
|
|
@@ -2733,7 +2735,7 @@ const rl = {
|
|
|
2733
2735
|
}, fl = (e) => (pn("data-v-84d5ee61"), e = e(), fn(), e), ml = ["aria-hidden"], gl = {
|
|
2734
2736
|
key: 0,
|
|
2735
2737
|
"data-testid": "kui-icon-svg-title"
|
|
2736
|
-
}, yl = /* @__PURE__ */ fl(() => /* @__PURE__ */
|
|
2738
|
+
}, yl = /* @__PURE__ */ fl(() => /* @__PURE__ */ F("path", {
|
|
2737
2739
|
d: "M14 9.9V8.2C14.55 7.96667 15.1125 7.79167 15.6875 7.675C16.2625 7.55833 16.8667 7.5 17.5 7.5C17.9333 7.5 18.3583 7.53333 18.775 7.6C19.1917 7.66667 19.6 7.75 20 7.85V9.45C19.6 9.3 19.1958 9.1875 18.7875 9.1125C18.3792 9.0375 17.95 9 17.5 9C16.8667 9 16.2583 9.07917 15.675 9.2375C15.0917 9.39583 14.5333 9.61667 14 9.9ZM14 15.4V13.7C14.55 13.4667 15.1125 13.2917 15.6875 13.175C16.2625 13.0583 16.8667 13 17.5 13C17.9333 13 18.3583 13.0333 18.775 13.1C19.1917 13.1667 19.6 13.25 20 13.35V14.95C19.6 14.8 19.1958 14.6875 18.7875 14.6125C18.3792 14.5375 17.95 14.5 17.5 14.5C16.8667 14.5 16.2583 14.575 15.675 14.725C15.0917 14.875 14.5333 15.1 14 15.4ZM14 12.65V10.95C14.55 10.7167 15.1125 10.5417 15.6875 10.425C16.2625 10.3083 16.8667 10.25 17.5 10.25C17.9333 10.25 18.3583 10.2833 18.775 10.35C19.1917 10.4167 19.6 10.5 20 10.6V12.2C19.6 12.05 19.1958 11.9375 18.7875 11.8625C18.3792 11.7875 17.95 11.75 17.5 11.75C16.8667 11.75 16.2583 11.8292 15.675 11.9875C15.0917 12.1458 14.5333 12.3667 14 12.65ZM6.5 16C7.28333 16 8.04583 16.0875 8.7875 16.2625C9.52917 16.4375 10.2667 16.7 11 17.05V7.2C10.3167 6.8 9.59167 6.5 8.825 6.3C8.05833 6.1 7.28333 6 6.5 6C5.9 6 5.30417 6.05833 4.7125 6.175C4.12083 6.29167 3.55 6.46667 3 6.7V16.6C3.58333 16.4 4.1625 16.25 4.7375 16.15C5.3125 16.05 5.9 16 6.5 16ZM13 17.05C13.7333 16.7 14.4708 16.4375 15.2125 16.2625C15.9542 16.0875 16.7167 16 17.5 16C18.1 16 18.6875 16.05 19.2625 16.15C19.8375 16.25 20.4167 16.4 21 16.6V6.7C20.45 6.46667 19.8792 6.29167 19.2875 6.175C18.6958 6.05833 18.1 6 17.5 6C16.7167 6 15.9417 6.1 15.175 6.3C14.4083 6.5 13.6833 6.8 13 7.2V17.05ZM12 20C11.2 19.3667 10.3333 18.875 9.4 18.525C8.46667 18.175 7.5 18 6.5 18C5.8 18 5.1125 18.0917 4.4375 18.275C3.7625 18.4583 3.11667 18.7167 2.5 19.05C2.15 19.2333 1.8125 19.225 1.4875 19.025C1.1625 18.825 1 18.5333 1 18.15V6.1C1 5.91667 1.04583 5.74167 1.1375 5.575C1.22917 5.40833 1.36667 5.28333 1.55 5.2C2.31667 4.8 3.11667 4.5 3.95 4.3C4.78333 4.1 5.63333 4 6.5 4C7.46667 4 8.4125 4.125 9.3375 4.375C10.2625 4.625 11.15 5 12 5.5C12.85 5 13.7375 4.625 14.6625 4.375C15.5875 4.125 16.5333 4 17.5 4C18.3667 4 19.2167 4.1 20.05 4.3C20.8833 4.5 21.6833 4.8 22.45 5.2C22.6333 5.28333 22.7708 5.40833 22.8625 5.575C22.9542 5.74167 23 5.91667 23 6.1V18.15C23 18.5333 22.8375 18.825 22.5125 19.025C22.1875 19.225 21.85 19.2333 21.5 19.05C20.8833 18.7167 20.2375 18.4583 19.5625 18.275C18.8875 18.0917 18.2 18 17.5 18C16.5 18 15.5333 18.175 14.6 18.525C13.6667 18.875 12.8 19.3667 12 20Z",
|
|
2738
2740
|
fill: "currentColor"
|
|
2739
2741
|
}, null, -1)), hl = /* @__PURE__ */ ne({
|
|
@@ -2805,7 +2807,7 @@ const rl = {
|
|
|
2805
2807
|
lineHeight: "0",
|
|
2806
2808
|
width: t.value
|
|
2807
2809
|
}));
|
|
2808
|
-
return (r, o) => (f(), R(
|
|
2810
|
+
return (r, o) => (f(), R(Ne(e.as), {
|
|
2809
2811
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2810
2812
|
class: "kui-icon book-icon",
|
|
2811
2813
|
"data-testid": "kui-icon-wrapper-book-icon",
|
|
@@ -2822,7 +2824,7 @@ const rl = {
|
|
|
2822
2824
|
width: "100%",
|
|
2823
2825
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2824
2826
|
}, [
|
|
2825
|
-
e.title ? (f(), T("title", gl, j(e.title), 1)) :
|
|
2827
|
+
e.title ? (f(), T("title", gl, j(e.title), 1)) : z("", !0),
|
|
2826
2828
|
yl
|
|
2827
2829
|
], 8, ml))
|
|
2828
2830
|
]),
|
|
@@ -2966,12 +2968,12 @@ const rl = {
|
|
|
2966
2968
|
section: de.Basic
|
|
2967
2969
|
}
|
|
2968
2970
|
}, w = E(!1), v = E(!1), A = E(""), y = E(), C = $(() => {
|
|
2969
|
-
var b, I,
|
|
2971
|
+
var b, I, K;
|
|
2970
2972
|
if (!y.value)
|
|
2971
2973
|
return [];
|
|
2972
2974
|
const V = [], _ = Object.keys(y.value).length;
|
|
2973
2975
|
for (const L in y.value) {
|
|
2974
|
-
const P = (I = (b = r.configSchema) == null ? void 0 : b[L]) == null ? void 0 : I.order, G = (
|
|
2976
|
+
const P = (I = (b = r.configSchema) == null ? void 0 : b[L]) == null ? void 0 : I.order, G = (K = d[L]) == null ? void 0 : K.order;
|
|
2975
2977
|
let Q = _;
|
|
2976
2978
|
(G || G === 0) && (Q = G === -1 ? _ + 1 : G), P && (Q = P === -1 ? _ + 1 : P), V.push([L, Q]);
|
|
2977
2979
|
}
|
|
@@ -2994,9 +2996,9 @@ const rl = {
|
|
|
2994
2996
|
var b, I;
|
|
2995
2997
|
if (!y.value || !r.pluginConfigKey)
|
|
2996
2998
|
return [];
|
|
2997
|
-
const
|
|
2998
|
-
for (const L in
|
|
2999
|
-
const P = (I = (b = r.pluginConfigSchema) == null ? void 0 : b[L]) == null ? void 0 : I.order, G =
|
|
2999
|
+
const K = y.value[r.pluginConfigKey] || {}, V = Object.keys(K).length, _ = [];
|
|
3000
|
+
for (const L in K) {
|
|
3001
|
+
const P = (I = (b = r.pluginConfigSchema) == null ? void 0 : b[L]) == null ? void 0 : I.order, G = K[L];
|
|
3000
3002
|
let Q = G != null && G !== "" ? V - 1 : V;
|
|
3001
3003
|
P && (Q = P === -1 ? V + 1 : P), _.push([L, Q]);
|
|
3002
3004
|
}
|
|
@@ -3004,7 +3006,7 @@ const rl = {
|
|
|
3004
3006
|
return L[1] - P[1];
|
|
3005
3007
|
}), _.map((L) => {
|
|
3006
3008
|
var P;
|
|
3007
|
-
const G = L[0], Q =
|
|
3009
|
+
const G = L[0], Q = K[G], J = ((P = r.pluginConfigSchema) == null ? void 0 : P[G]) || {};
|
|
3008
3010
|
return {
|
|
3009
3011
|
key: G,
|
|
3010
3012
|
value: Q,
|
|
@@ -3016,20 +3018,20 @@ const rl = {
|
|
|
3016
3018
|
};
|
|
3017
3019
|
}).filter((L) => !L.hidden);
|
|
3018
3020
|
}), S = $(() => {
|
|
3019
|
-
var b, I,
|
|
3021
|
+
var b, I, K, V;
|
|
3020
3022
|
return {
|
|
3021
3023
|
basic: (b = C.value) == null ? void 0 : b.filter((_) => _.section === de.Basic),
|
|
3022
3024
|
advanced: (I = C.value) == null ? void 0 : I.filter((_) => _.section === de.Advanced),
|
|
3023
|
-
plugin: (V = U.value) == null ? void 0 : V.concat((
|
|
3025
|
+
plugin: (V = U.value) == null ? void 0 : V.concat((K = C.value) == null ? void 0 : K.filter((_) => _.section === de.Plugin))
|
|
3024
3026
|
};
|
|
3025
|
-
}),
|
|
3027
|
+
}), N = $(() => {
|
|
3026
3028
|
const b = [];
|
|
3027
3029
|
return S.value.basic.length && b.push("basic"), S.value.advanced.length && b.push("advanced"), S.value.plugin.length && b.push("plugin"), b;
|
|
3028
|
-
}), k = (b) => !!(b.tooltip || o[`${b.key}-label-tooltip`]),
|
|
3030
|
+
}), k = (b) => !!(b.tooltip || o[`${b.key}-label-tooltip`]), q = $(() => {
|
|
3029
3031
|
var b, I;
|
|
3030
|
-
let
|
|
3031
|
-
return r.config.app === "konnect" ?
|
|
3032
|
-
}),
|
|
3032
|
+
let K = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3033
|
+
return r.config.app === "konnect" ? K = K.replace(/{controlPlaneId}/gi, ((b = r.config) == null ? void 0 : b.controlPlaneId) || "") : r.config.app === "kongManager" && (K = K.replace(/\/{workspace}/gi, (I = r.config) != null && I.workspace ? `/${r.config.workspace}` : "")), K = K.replace(/{id}/gi, r.config.entityId), K;
|
|
3034
|
+
}), B = (b) => {
|
|
3033
3035
|
y.value && b(JSON.stringify(y.value)) ? a("copy:success", y.value) : a("copy:error");
|
|
3034
3036
|
};
|
|
3035
3037
|
return ve(w, (b) => {
|
|
@@ -3037,7 +3039,7 @@ const rl = {
|
|
|
3037
3039
|
}, { immediate: !0 }), gt(async () => {
|
|
3038
3040
|
v.value = !1, w.value = !0;
|
|
3039
3041
|
try {
|
|
3040
|
-
const { data: b } = await u.get(
|
|
3042
|
+
const { data: b } = await u.get(q.value);
|
|
3041
3043
|
if (r.dataKey)
|
|
3042
3044
|
if (typeof b[r.dataKey] < "u")
|
|
3043
3045
|
y.value = { ...b[r.dataKey] };
|
|
@@ -3055,12 +3057,12 @@ const rl = {
|
|
|
3055
3057
|
w.value = !1;
|
|
3056
3058
|
}
|
|
3057
3059
|
}), (b, I) => {
|
|
3058
|
-
const
|
|
3060
|
+
const K = D("KLabel"), V = D("KSelect"), _ = D("KButton"), L = D("KClipboardProvider"), P = D("KSkeleton"), G = D("KEmptyState"), Q = D("KCard");
|
|
3059
3061
|
return f(), R(Q, { class: "kong-ui-entity-base-config-card" }, ke({
|
|
3060
3062
|
actions: g(() => [
|
|
3061
|
-
|
|
3063
|
+
F("div", Cl, [
|
|
3062
3064
|
Z(b.$slots, "actions", {}, void 0, !0),
|
|
3063
|
-
e.config.jsonYamlEnabled ? (f(), R(
|
|
3065
|
+
e.config.jsonYamlEnabled ? (f(), R(K, {
|
|
3064
3066
|
key: 0,
|
|
3065
3067
|
class: "config-format-select-label",
|
|
3066
3068
|
"data-testid": "config-format-select-label"
|
|
@@ -3069,14 +3071,14 @@ const rl = {
|
|
|
3069
3071
|
W(j(e.label), 1)
|
|
3070
3072
|
]),
|
|
3071
3073
|
_: 1
|
|
3072
|
-
})) :
|
|
3074
|
+
})) : z("", !0),
|
|
3073
3075
|
e.config.jsonYamlEnabled ? (f(), R(V, {
|
|
3074
3076
|
key: 1,
|
|
3075
3077
|
appearance: "select",
|
|
3076
3078
|
"data-testid": "select-config-format",
|
|
3077
3079
|
items: p,
|
|
3078
3080
|
onChange: h
|
|
3079
|
-
})) :
|
|
3081
|
+
})) : z("", !0),
|
|
3080
3082
|
r.config.jsonYamlEnabled && e.configCardDoc ? (f(), R(_, {
|
|
3081
3083
|
key: 2,
|
|
3082
3084
|
appearance: "tertiary",
|
|
@@ -3084,7 +3086,7 @@ const rl = {
|
|
|
3084
3086
|
"data-testid": "book-icon"
|
|
3085
3087
|
}, {
|
|
3086
3088
|
default: g(() => [
|
|
3087
|
-
|
|
3089
|
+
F("a", {
|
|
3088
3090
|
href: e.configCardDoc,
|
|
3089
3091
|
rel: "noopener",
|
|
3090
3092
|
target: "_blank"
|
|
@@ -3093,20 +3095,20 @@ const rl = {
|
|
|
3093
3095
|
], 8, kl)
|
|
3094
3096
|
]),
|
|
3095
3097
|
_: 1
|
|
3096
|
-
})) :
|
|
3097
|
-
e.config.jsonYamlEnabled ?
|
|
3098
|
+
})) : z("", !0),
|
|
3099
|
+
e.config.jsonYamlEnabled ? z("", !0) : (f(), R(L, { key: 3 }, {
|
|
3098
3100
|
default: g(({ copyToClipboard: J }) => [
|
|
3099
3101
|
!w.value && !v.value ? (f(), R(_, {
|
|
3100
3102
|
key: 0,
|
|
3101
3103
|
appearance: "tertiary",
|
|
3102
3104
|
"data-testid": "json-copy-button",
|
|
3103
|
-
onClick: (X) =>
|
|
3105
|
+
onClick: (X) => B(J)
|
|
3104
3106
|
}, {
|
|
3105
3107
|
default: g(() => [
|
|
3106
3108
|
W(j(m(i)("baseConfigCard.actions.copy")), 1)
|
|
3107
3109
|
]),
|
|
3108
3110
|
_: 2
|
|
3109
|
-
}, 1032, ["onClick"])) :
|
|
3111
|
+
}, 1032, ["onClick"])) : z("", !0)
|
|
3110
3112
|
]),
|
|
3111
3113
|
_: 1
|
|
3112
3114
|
}))
|
|
@@ -3124,15 +3126,15 @@ const rl = {
|
|
|
3124
3126
|
"is-error": ""
|
|
3125
3127
|
}, {
|
|
3126
3128
|
message: g(() => [
|
|
3127
|
-
|
|
3129
|
+
F("h3", null, j(A.value), 1)
|
|
3128
3130
|
]),
|
|
3129
3131
|
_: 1
|
|
3130
|
-
})) :
|
|
3132
|
+
})) : z("", !0),
|
|
3131
3133
|
e.config.jsonYamlEnabled ? (f(), T("div", wl, [
|
|
3132
3134
|
O(dl, {
|
|
3133
|
-
"fetcher-url":
|
|
3135
|
+
"fetcher-url": q.value,
|
|
3134
3136
|
format: c.value,
|
|
3135
|
-
"prop-list-types":
|
|
3137
|
+
"prop-list-types": N.value,
|
|
3136
3138
|
"property-collections": S.value,
|
|
3137
3139
|
record: y.value
|
|
3138
3140
|
}, ke({ _: 2 }, [
|
|
@@ -3147,12 +3149,12 @@ const rl = {
|
|
|
3147
3149
|
}))
|
|
3148
3150
|
]), 1032, ["fetcher-url", "format", "prop-list-types", "property-collections", "record"])
|
|
3149
3151
|
])) : (f(), T("div", Il, [
|
|
3150
|
-
(f(!0), T(me, null, pe(
|
|
3152
|
+
(f(!0), T(me, null, pe(N.value, (J) => (f(), T("div", {
|
|
3151
3153
|
key: `config-card-details-${J}-props`,
|
|
3152
3154
|
class: Ie(`config-card-details-${J}-props`),
|
|
3153
3155
|
"data-testid": `config-card-details-${J}-props`
|
|
3154
3156
|
}, [
|
|
3155
|
-
J !== "basic" ? (f(), T("div", Sl, j(J === "advanced" ? m(i)("baseConfigCard.sections.advanced") : m(i)("baseConfigCard.sections.plugin")), 1)) :
|
|
3157
|
+
J !== "basic" ? (f(), T("div", Sl, j(J === "advanced" ? m(i)("baseConfigCard.sections.advanced") : m(i)("baseConfigCard.sections.plugin")), 1)) : z("", !0),
|
|
3156
3158
|
(f(!0), T(me, null, pe(S.value[J], (X) => (f(), R(Ct, {
|
|
3157
3159
|
key: X.key,
|
|
3158
3160
|
item: X
|
|
@@ -3184,7 +3186,7 @@ const rl = {
|
|
|
3184
3186
|
e.hideTitle ? void 0 : {
|
|
3185
3187
|
name: "title",
|
|
3186
3188
|
fn: g(() => [
|
|
3187
|
-
|
|
3189
|
+
F("div", bl, [
|
|
3188
3190
|
Z(b.$slots, "title", {}, () => [
|
|
3189
3191
|
W(j(m(i)("baseConfigCard.title")), 1)
|
|
3190
3192
|
], !0)
|
|
@@ -3278,8 +3280,8 @@ const rl = {
|
|
|
3278
3280
|
u.value = !1;
|
|
3279
3281
|
}
|
|
3280
3282
|
}), (y, C) => {
|
|
3281
|
-
const U = D("KSkeleton"), S = D("KEmptyState"),
|
|
3282
|
-
return f(), R(
|
|
3283
|
+
const U = D("KSkeleton"), S = D("KEmptyState"), N = D("KAlert"), k = D("KButton"), q = D("KCard");
|
|
3284
|
+
return f(), R(q, { class: "kong-ui-entity-base-form" }, {
|
|
3283
3285
|
default: g(() => [
|
|
3284
3286
|
u.value ? (f(), R(U, {
|
|
3285
3287
|
key: 0,
|
|
@@ -3292,7 +3294,7 @@ const rl = {
|
|
|
3292
3294
|
"is-error": !0
|
|
3293
3295
|
}, {
|
|
3294
3296
|
message: g(() => [
|
|
3295
|
-
|
|
3297
|
+
F("h3", null, j(c.value), 1)
|
|
3296
3298
|
]),
|
|
3297
3299
|
_: 1
|
|
3298
3300
|
}, 8, ["cta-text"])) : (f(), T("form", {
|
|
@@ -3302,13 +3304,13 @@ const rl = {
|
|
|
3302
3304
|
onSubmit: Ge(A, ["prevent"])
|
|
3303
3305
|
}, [
|
|
3304
3306
|
Z(y.$slots, "default", {}, void 0, !0),
|
|
3305
|
-
e.errorMessage ? (f(), R(
|
|
3307
|
+
e.errorMessage ? (f(), R(N, {
|
|
3306
3308
|
key: 0,
|
|
3307
3309
|
"alert-message": e.errorMessage,
|
|
3308
3310
|
appearance: "danger",
|
|
3309
3311
|
"data-testid": "form-error"
|
|
3310
|
-
}, null, 8, ["alert-message"])) :
|
|
3311
|
-
|
|
3312
|
+
}, null, 8, ["alert-message"])) : z("", !0),
|
|
3313
|
+
F("div", Tl, [
|
|
3312
3314
|
Z(y.$slots, "form-actions", {}, () => [
|
|
3313
3315
|
O(k, {
|
|
3314
3316
|
appearance: "secondary",
|
|
@@ -3414,10 +3416,10 @@ const rl = {
|
|
|
3414
3416
|
], 512);
|
|
3415
3417
|
};
|
|
3416
3418
|
}
|
|
3417
|
-
}), El = /* @__PURE__ */ ge(Ol, [["__scopeId", "data-v-e42a20c9"]]),
|
|
3419
|
+
}), El = /* @__PURE__ */ ge(Ol, [["__scopeId", "data-v-e42a20c9"]]), Nl = { class: "toolbar-container" }, Kl = {
|
|
3418
3420
|
key: 0,
|
|
3419
3421
|
class: "toolbar-button-container"
|
|
3420
|
-
},
|
|
3422
|
+
}, ql = ["data-testid"], Bl = /* @__PURE__ */ ne({
|
|
3421
3423
|
__name: "EntityBaseTable",
|
|
3422
3424
|
props: {
|
|
3423
3425
|
// table header configuration
|
|
@@ -3528,42 +3530,42 @@ const rl = {
|
|
|
3528
3530
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked"],
|
|
3529
3531
|
setup(e, { emit: n }) {
|
|
3530
3532
|
const t = e, a = n, { i18n: { t: r } } = oe.useI18n(), o = $(() => {
|
|
3531
|
-
var
|
|
3533
|
+
var N, k;
|
|
3532
3534
|
return typeof t.errorMessage == "string" ? {
|
|
3533
3535
|
hasError: !!t.errorMessage,
|
|
3534
3536
|
title: t.errorMessage,
|
|
3535
3537
|
message: void 0
|
|
3536
3538
|
} : {
|
|
3537
3539
|
hasError: !!t.errorMessage,
|
|
3538
|
-
title: (
|
|
3540
|
+
title: (N = t.errorMessage) == null ? void 0 : N.title,
|
|
3539
3541
|
message: (k = t.errorMessage) == null ? void 0 : k.message
|
|
3540
3542
|
};
|
|
3541
|
-
}), i = $(() => t.cacheIdentifier || t.preferencesStorageKey), l = (
|
|
3542
|
-
const
|
|
3543
|
+
}), i = $(() => t.cacheIdentifier || t.preferencesStorageKey), l = (N) => N.hasData || !!t.query, s = $(() => {
|
|
3544
|
+
const N = [];
|
|
3543
3545
|
return Object.keys(t.tableHeaders).forEach((k) => {
|
|
3544
|
-
const
|
|
3545
|
-
|
|
3546
|
-
label:
|
|
3546
|
+
const q = t.tableHeaders[k];
|
|
3547
|
+
N.push({
|
|
3548
|
+
label: q.label ?? k,
|
|
3547
3549
|
key: k,
|
|
3548
|
-
sortable:
|
|
3550
|
+
sortable: q.sortable ?? !1
|
|
3549
3551
|
});
|
|
3550
|
-
}), t.enableEntityActions &&
|
|
3552
|
+
}), t.enableEntityActions && N.push({
|
|
3551
3553
|
key: "actions",
|
|
3552
3554
|
hideLabel: !0
|
|
3553
|
-
}),
|
|
3554
|
-
}), u = (
|
|
3555
|
-
"data-rowid":
|
|
3556
|
-
"data-testid":
|
|
3557
|
-
...t.rowAttributes(
|
|
3558
|
-
}), p = E({}), c = (
|
|
3555
|
+
}), N;
|
|
3556
|
+
}), u = (N) => ({
|
|
3557
|
+
"data-rowid": N.id,
|
|
3558
|
+
"data-testid": N.name,
|
|
3559
|
+
...t.rowAttributes(N)
|
|
3560
|
+
}), p = E({}), c = (N) => {
|
|
3559
3561
|
var k;
|
|
3560
|
-
return (k = p.value) == null ? void 0 : k.$el.querySelector(`[data-rowid="${
|
|
3561
|
-
}, h = (
|
|
3562
|
+
return (k = p.value) == null ? void 0 : k.$el.querySelector(`[data-rowid="${N.id}"]`);
|
|
3563
|
+
}, h = (N) => {
|
|
3562
3564
|
const k = {
|
|
3563
|
-
"data-testid":
|
|
3564
|
-
...t.cellAttributes(
|
|
3565
|
+
"data-testid": N.headerKey,
|
|
3566
|
+
...t.cellAttributes(N)
|
|
3565
3567
|
};
|
|
3566
|
-
return
|
|
3568
|
+
return N.colIndex === 0 && (k.style = {
|
|
3567
3569
|
maxWidth: "250px",
|
|
3568
3570
|
overflowX: "hidden",
|
|
3569
3571
|
textOverflow: "ellipsis"
|
|
@@ -3572,22 +3574,22 @@ const rl = {
|
|
|
3572
3574
|
a("empty-state-cta-clicked"), w();
|
|
3573
3575
|
}, w = () => {
|
|
3574
3576
|
a("clear-search-input");
|
|
3575
|
-
}, v = $(() => t.disableRowClick ? void 0 : (
|
|
3577
|
+
}, v = $(() => t.disableRowClick ? void 0 : (N, k) => {
|
|
3576
3578
|
a("click:row", k);
|
|
3577
|
-
}), A = (
|
|
3578
|
-
a("sort",
|
|
3579
|
+
}), A = (N) => {
|
|
3580
|
+
a("sort", N);
|
|
3579
3581
|
}, { setTablePreferences: y, getTablePreferences: C } = $a(), U = $(() => {
|
|
3580
|
-
const
|
|
3582
|
+
const N = C(t.preferencesStorageKey);
|
|
3581
3583
|
return {
|
|
3582
3584
|
...t.initialFetcherParams,
|
|
3583
|
-
...
|
|
3585
|
+
...N
|
|
3584
3586
|
};
|
|
3585
|
-
}), S = (
|
|
3586
|
-
t.preferencesStorageKey && y(t.preferencesStorageKey,
|
|
3587
|
+
}), S = (N) => {
|
|
3588
|
+
t.preferencesStorageKey && y(t.preferencesStorageKey, N);
|
|
3587
3589
|
};
|
|
3588
|
-
return (
|
|
3589
|
-
const
|
|
3590
|
-
return f(), R(
|
|
3590
|
+
return (N, k) => {
|
|
3591
|
+
const q = D("KIcon"), B = D("KButton"), b = D("KDropdown"), I = D("KTable"), K = D("KCard");
|
|
3592
|
+
return f(), R(K, {
|
|
3591
3593
|
class: "kong-ui-entity-base-table",
|
|
3592
3594
|
title: e.title
|
|
3593
3595
|
}, {
|
|
@@ -3625,17 +3627,17 @@ const rl = {
|
|
|
3625
3627
|
"onUpdate:tablePreferences": S
|
|
3626
3628
|
}, ke({
|
|
3627
3629
|
toolbar: g(({ state: V }) => [
|
|
3628
|
-
|
|
3629
|
-
Z(
|
|
3630
|
-
|
|
3631
|
-
Z(
|
|
3632
|
-
])) :
|
|
3630
|
+
Fe(F("div", Nl, [
|
|
3631
|
+
Z(N.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3632
|
+
N.$slots["toolbar-button"] ? (f(), T("div", Kl, [
|
|
3633
|
+
Z(N.$slots, "toolbar-button", {}, void 0, !0)
|
|
3634
|
+
])) : z("", !0)
|
|
3633
3635
|
], 512), [
|
|
3634
3636
|
[Le, l(V)]
|
|
3635
3637
|
])
|
|
3636
3638
|
]),
|
|
3637
3639
|
actions: g(({ row: V, rowKey: _, rowValue: L }) => [
|
|
3638
|
-
|
|
3640
|
+
F("div", {
|
|
3639
3641
|
class: "actions-container",
|
|
3640
3642
|
"data-testid": V.name
|
|
3641
3643
|
}, [
|
|
@@ -3644,20 +3646,20 @@ const rl = {
|
|
|
3644
3646
|
width: e.dropdownMenuWidth
|
|
3645
3647
|
}, {
|
|
3646
3648
|
items: g(() => [
|
|
3647
|
-
Z(
|
|
3649
|
+
Z(N.$slots, "actions", {
|
|
3648
3650
|
row: V,
|
|
3649
3651
|
rowKey: _,
|
|
3650
3652
|
rowValue: L
|
|
3651
3653
|
}, void 0, !0)
|
|
3652
3654
|
]),
|
|
3653
3655
|
default: g(() => [
|
|
3654
|
-
O(
|
|
3656
|
+
O(B, {
|
|
3655
3657
|
class: "actions-trigger",
|
|
3656
3658
|
"data-testid": "overflow-actions-button",
|
|
3657
3659
|
size: "small"
|
|
3658
3660
|
}, {
|
|
3659
3661
|
icon: g(() => [
|
|
3660
|
-
O(
|
|
3662
|
+
O(q, {
|
|
3661
3663
|
color: m(wr),
|
|
3662
3664
|
icon: "more",
|
|
3663
3665
|
size: "16"
|
|
@@ -3668,7 +3670,7 @@ const rl = {
|
|
|
3668
3670
|
]),
|
|
3669
3671
|
_: 2
|
|
3670
3672
|
}, 1032, ["width"])
|
|
3671
|
-
], 8,
|
|
3673
|
+
], 8, ql)
|
|
3672
3674
|
]),
|
|
3673
3675
|
_: 2
|
|
3674
3676
|
}, [
|
|
@@ -3680,7 +3682,7 @@ const rl = {
|
|
|
3680
3682
|
"row-el": c(L)
|
|
3681
3683
|
}, {
|
|
3682
3684
|
default: g(() => [
|
|
3683
|
-
Z(
|
|
3685
|
+
Z(N.$slots, _, {
|
|
3684
3686
|
row: L,
|
|
3685
3687
|
rowKey: P,
|
|
3686
3688
|
rowValue: G
|
|
@@ -3698,7 +3700,7 @@ const rl = {
|
|
|
3698
3700
|
}, 8, ["title"]);
|
|
3699
3701
|
};
|
|
3700
3702
|
}
|
|
3701
|
-
}),
|
|
3703
|
+
}), Fl = /* @__PURE__ */ ge(Bl, [["__scopeId", "data-v-57b5a97b"]]), Ll = {
|
|
3702
3704
|
key: 0,
|
|
3703
3705
|
class: "kong-ui-entity-delete-error"
|
|
3704
3706
|
}, Ul = {
|
|
@@ -3769,7 +3771,7 @@ const rl = {
|
|
|
3769
3771
|
]),
|
|
3770
3772
|
_: 1
|
|
3771
3773
|
})
|
|
3772
|
-
])) :
|
|
3774
|
+
])) : z("", !0),
|
|
3773
3775
|
O(m(t), {
|
|
3774
3776
|
class: "message",
|
|
3775
3777
|
keypath: a.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
@@ -3783,16 +3785,16 @@ const rl = {
|
|
|
3783
3785
|
a.entityName ? {
|
|
3784
3786
|
name: "entityName",
|
|
3785
3787
|
fn: g(() => [
|
|
3786
|
-
|
|
3788
|
+
F("strong", null, j(a.entityName), 1)
|
|
3787
3789
|
]),
|
|
3788
3790
|
key: "0"
|
|
3789
3791
|
} : void 0
|
|
3790
3792
|
]), 1032, ["keypath"]),
|
|
3791
3793
|
a.description || s.$slots.description ? (f(), T("div", Ul, [
|
|
3792
3794
|
Z(s.$slots, "description", {}, () => [
|
|
3793
|
-
|
|
3795
|
+
F("p", null, j(a.description), 1)
|
|
3794
3796
|
], !0)
|
|
3795
|
-
])) :
|
|
3797
|
+
])) : z("", !0)
|
|
3796
3798
|
]),
|
|
3797
3799
|
_: 3
|
|
3798
3800
|
}, 8, ["action-pending", "confirmation-text", "is-visible", "title"]);
|
|
@@ -3812,7 +3814,7 @@ const rl = {
|
|
|
3812
3814
|
width: "20",
|
|
3813
3815
|
x: "0",
|
|
3814
3816
|
y: "0"
|
|
3815
|
-
}, Gl = ["fill"],
|
|
3817
|
+
}, Gl = ["fill"], zl = { mask: "url(#mask0_180_20349)" }, Hl = ["fill"], un = /* @__PURE__ */ ne({
|
|
3816
3818
|
__name: "IconFilter",
|
|
3817
3819
|
props: {
|
|
3818
3820
|
color: {
|
|
@@ -3822,18 +3824,18 @@ const rl = {
|
|
|
3822
3824
|
},
|
|
3823
3825
|
setup(e) {
|
|
3824
3826
|
return (n, t) => (f(), T("svg", Vl, [
|
|
3825
|
-
|
|
3826
|
-
|
|
3827
|
+
F("mask", Rl, [
|
|
3828
|
+
F("rect", {
|
|
3827
3829
|
fill: e.color,
|
|
3828
3830
|
height: "20",
|
|
3829
3831
|
width: "20"
|
|
3830
3832
|
}, null, 8, Gl)
|
|
3831
3833
|
]),
|
|
3832
|
-
|
|
3833
|
-
|
|
3834
|
+
F("g", zl, [
|
|
3835
|
+
F("path", {
|
|
3834
3836
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3835
3837
|
fill: e.color
|
|
3836
|
-
}, null, 8,
|
|
3838
|
+
}, null, 8, Hl)
|
|
3837
3839
|
])
|
|
3838
3840
|
]));
|
|
3839
3841
|
}
|
|
@@ -3902,7 +3904,7 @@ const rl = {
|
|
|
3902
3904
|
y && (o.value = !1), r("update:modelValue", new URLSearchParams(C).toString());
|
|
3903
3905
|
};
|
|
3904
3906
|
return (y, C) => {
|
|
3905
|
-
const U = D("KInput"), S = D("KButton"),
|
|
3907
|
+
const U = D("KInput"), S = D("KButton"), N = D("KSelect"), k = D("KMenuItem"), q = D("KMenu");
|
|
3906
3908
|
return e.config.isExactMatch ? (f(), R(U, {
|
|
3907
3909
|
key: 0,
|
|
3908
3910
|
autocomplete: "off",
|
|
@@ -3928,55 +3930,55 @@ const rl = {
|
|
|
3928
3930
|
]),
|
|
3929
3931
|
_: 1
|
|
3930
3932
|
}),
|
|
3931
|
-
|
|
3933
|
+
Fe(F("div", {
|
|
3932
3934
|
class: "kong-ui-entity-filter-backdrop",
|
|
3933
3935
|
onClick: u
|
|
3934
3936
|
}, null, 512), [
|
|
3935
3937
|
[Le, o.value]
|
|
3936
3938
|
]),
|
|
3937
|
-
|
|
3939
|
+
Fe(O(q, { class: "kong-ui-entity-filter-menu" }, {
|
|
3938
3940
|
body: g(() => [
|
|
3939
|
-
(f(!0), T(me, null, pe(s.value, (
|
|
3940
|
-
key:
|
|
3941
|
-
"data-testid":
|
|
3941
|
+
(f(!0), T(me, null, pe(s.value, (B, b) => (f(), R(k, {
|
|
3942
|
+
key: B.value,
|
|
3943
|
+
"data-testid": B.value,
|
|
3942
3944
|
expandable: "",
|
|
3943
3945
|
"last-menu-item": b === s.value.length - 1
|
|
3944
3946
|
}, {
|
|
3945
3947
|
itemTitle: g(() => [
|
|
3946
|
-
|
|
3947
|
-
W(j(
|
|
3948
|
-
|
|
3949
|
-
[Le, l.value.includes(
|
|
3948
|
+
F("span", Wl, [
|
|
3949
|
+
W(j(B.label) + " ", 1),
|
|
3950
|
+
Fe(F("span", Yl, null, 512), [
|
|
3951
|
+
[Le, l.value.includes(B.value)]
|
|
3950
3952
|
])
|
|
3951
3953
|
])
|
|
3952
3954
|
]),
|
|
3953
3955
|
itemBody: g(() => {
|
|
3954
|
-
var I,
|
|
3956
|
+
var I, K;
|
|
3955
3957
|
return [
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
+
F("div", Zl, [
|
|
3959
|
+
F("label", {
|
|
3958
3960
|
class: "menu-item-label",
|
|
3959
|
-
for: c(
|
|
3961
|
+
for: c(B.value)
|
|
3960
3962
|
}, j(m(t)("filter.fieldLabel")), 9, Ql),
|
|
3961
|
-
((
|
|
3963
|
+
((K = (I = e.config.schema) == null ? void 0 : I[B.value]) == null ? void 0 : K.type) === "select" ? (f(), R(N, {
|
|
3962
3964
|
key: 0,
|
|
3963
|
-
id: c(
|
|
3964
|
-
modelValue: i.value[
|
|
3965
|
-
"onUpdate:modelValue": (V) => i.value[
|
|
3965
|
+
id: c(B.value),
|
|
3966
|
+
modelValue: i.value[B.value],
|
|
3967
|
+
"onUpdate:modelValue": (V) => i.value[B.value] = V,
|
|
3966
3968
|
appearance: "select",
|
|
3967
|
-
items: h(
|
|
3969
|
+
items: h(B.value),
|
|
3968
3970
|
placeholder: m(t)("filter.selectPlaceholder")
|
|
3969
3971
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (f(), R(U, {
|
|
3970
3972
|
key: 1,
|
|
3971
|
-
id: c(
|
|
3972
|
-
modelValue: i.value[
|
|
3973
|
-
"onUpdate:modelValue": (V) => i.value[
|
|
3973
|
+
id: c(B.value),
|
|
3974
|
+
modelValue: i.value[B.value],
|
|
3975
|
+
"onUpdate:modelValue": (V) => i.value[B.value] = V,
|
|
3974
3976
|
autocomplete: "off",
|
|
3975
3977
|
placeholder: m(t)("filter.inputPlaceholder"),
|
|
3976
|
-
type: d(
|
|
3978
|
+
type: d(B.value)
|
|
3977
3979
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3978
3980
|
]),
|
|
3979
|
-
|
|
3981
|
+
F("div", Xl, [
|
|
3980
3982
|
O(S, {
|
|
3981
3983
|
appearance: "tertiary",
|
|
3982
3984
|
"data-testid": "apply-filter",
|
|
@@ -3992,7 +3994,7 @@ const rl = {
|
|
|
3992
3994
|
appearance: "tertiary",
|
|
3993
3995
|
"data-testid": "clear-filter",
|
|
3994
3996
|
size: "small",
|
|
3995
|
-
onClick: (V) => w(
|
|
3997
|
+
onClick: (V) => w(B.value)
|
|
3996
3998
|
}, {
|
|
3997
3999
|
default: g(() => [
|
|
3998
4000
|
W(j(m(t)("filter.clearButtonText")), 1)
|
|
@@ -4006,7 +4008,7 @@ const rl = {
|
|
|
4006
4008
|
}, 1032, ["data-testid", "last-menu-item"]))), 128))
|
|
4007
4009
|
]),
|
|
4008
4010
|
actionButton: g(() => [
|
|
4009
|
-
|
|
4011
|
+
F("div", es, [
|
|
4010
4012
|
O(S, {
|
|
4011
4013
|
appearance: "tertiary",
|
|
4012
4014
|
size: "small",
|
|
@@ -4054,7 +4056,7 @@ const rl = {
|
|
|
4054
4056
|
}, { immediate: !0 }), (r, o) => a.value ? Z(r.$slots, "default", {
|
|
4055
4057
|
key: 0,
|
|
4056
4058
|
isAllowed: t.value
|
|
4057
|
-
}) :
|
|
4059
|
+
}) : z("", !0);
|
|
4058
4060
|
}
|
|
4059
4061
|
}), as = { class: "form-section-wrapper" }, rs = {
|
|
4060
4062
|
key: 0,
|
|
@@ -4094,28 +4096,28 @@ const rl = {
|
|
|
4094
4096
|
return (t, a) => (f(), T("fieldset", {
|
|
4095
4097
|
class: Ie(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }])
|
|
4096
4098
|
}, [
|
|
4097
|
-
|
|
4098
|
-
e.hideInfoHeader ?
|
|
4099
|
+
F("div", as, [
|
|
4100
|
+
e.hideInfoHeader ? z("", !0) : (f(), T("div", {
|
|
4099
4101
|
key: 0,
|
|
4100
4102
|
class: Ie(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
4101
4103
|
}, [
|
|
4102
|
-
e.title ? (f(), T("h4", rs, j(e.title), 1)) :
|
|
4104
|
+
e.title ? (f(), T("h4", rs, j(e.title), 1)) : z("", !0),
|
|
4103
4105
|
e.description || m(n).description ? (f(), T("div", os, [
|
|
4104
4106
|
Z(t.$slots, "description", {}, () => [
|
|
4105
|
-
|
|
4107
|
+
F("p", null, j(e.description), 1)
|
|
4106
4108
|
], !0)
|
|
4107
|
-
])) :
|
|
4109
|
+
])) : z("", !0),
|
|
4108
4110
|
m(n).footer ? (f(), T("div", is, [
|
|
4109
4111
|
Z(t.$slots, "footer", {}, void 0, !0)
|
|
4110
|
-
])) :
|
|
4112
|
+
])) : z("", !0)
|
|
4111
4113
|
], 2)),
|
|
4112
|
-
|
|
4114
|
+
F("div", ls, [
|
|
4113
4115
|
Z(t.$slots, "default", {}, void 0, !0)
|
|
4114
4116
|
])
|
|
4115
4117
|
])
|
|
4116
4118
|
], 2));
|
|
4117
4119
|
}
|
|
4118
|
-
}), us = /* @__PURE__ */ ge(ss, [["__scopeId", "data-v-3565daa7"]]), { useAxios: xt, useDeleteUrlBuilder: cs, useErrors: ds, useExternalLinkCreator:
|
|
4120
|
+
}), us = /* @__PURE__ */ ge(ss, [["__scopeId", "data-v-3565daa7"]]), { useAxios: xt, useDeleteUrlBuilder: cs, useErrors: ds, useExternalLinkCreator: Ks, useFetchUrlBuilder: qs, useFetcher: ps, useDebouncedFilter: fs, useStringHelpers: Bs, useHelpers: Fs, useGatewayFeatureSupported: Ls, useTruncationDetector: Us } = oe, ms = { class: "add-consumer-form-container" }, gs = { class: "add-consumer-form-cta" }, ys = { class: "select-item-label" }, hs = {
|
|
4119
4121
|
key: 0,
|
|
4120
4122
|
class: "select-item-desc"
|
|
4121
4123
|
}, vs = {
|
|
@@ -4168,24 +4170,24 @@ const rl = {
|
|
|
4168
4170
|
return L ? L.username || L.custom_id : _;
|
|
4169
4171
|
}, U = () => {
|
|
4170
4172
|
k.value = "", S.value = [], I.value = [], r("cancel");
|
|
4171
|
-
}, S = E([]),
|
|
4173
|
+
}, S = E([]), N = E(!1), k = E(""), q = async () => {
|
|
4172
4174
|
if (!i.value.length) {
|
|
4173
4175
|
k.value = "", I.value = [], r("cancel");
|
|
4174
4176
|
return;
|
|
4175
4177
|
}
|
|
4176
|
-
|
|
4178
|
+
N.value = !0, k.value = "", S.value = [], I.value = [];
|
|
4177
4179
|
try {
|
|
4178
4180
|
const _ = i.value.map((G) => b(G)), L = await Promise.allSettled(_);
|
|
4179
4181
|
let P = !0;
|
|
4180
4182
|
L.forEach((G) => {
|
|
4181
4183
|
G.status !== "fulfilled" && (P = !1);
|
|
4182
|
-
}), P ? (S.value = [], I.value = [], r("add:success", i.value), i.value = []) : (S.value.length && r("add:partial-success", S.value), i.value = [],
|
|
4184
|
+
}), P ? (S.value = [], I.value = [], r("add:success", i.value), i.value = []) : (S.value.length && r("add:partial-success", S.value), i.value = [], K(L));
|
|
4183
4185
|
} catch {
|
|
4184
4186
|
k.value = t("consumers.errors.add"), r("error", k.value);
|
|
4185
4187
|
} finally {
|
|
4186
|
-
|
|
4188
|
+
N.value = !1;
|
|
4187
4189
|
}
|
|
4188
|
-
},
|
|
4190
|
+
}, B = $(() => {
|
|
4189
4191
|
var L, P, G, Q;
|
|
4190
4192
|
let _ = `${a.config.apiBaseUrl}${xe.list[a.config.app].forConsumerGroup}`;
|
|
4191
4193
|
return a.config.app === "konnect" ? _ = _.replace(/{controlPlaneId}/gi, ((L = a.config) == null ? void 0 : L.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((P = a.config) == null ? void 0 : P.consumerGroupId) || "") : a.config.app === "kongManager" && (_ = _.replace(/\/{workspace}/gi, (G = a.config) != null && G.workspace ? `/${a.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((Q = a.config) == null ? void 0 : Q.consumerGroupId) || "")), _;
|
|
@@ -4194,13 +4196,13 @@ const rl = {
|
|
|
4194
4196
|
consumer: _
|
|
4195
4197
|
};
|
|
4196
4198
|
try {
|
|
4197
|
-
const P = await o.post(
|
|
4199
|
+
const P = await o.post(B.value, L);
|
|
4198
4200
|
return S.value.push(_), P;
|
|
4199
4201
|
} catch (P) {
|
|
4200
4202
|
let G = `${C(_)} - ${P.message}`;
|
|
4201
4203
|
return P.response.status === 409 && (G = `${C(_)} - ${t("consumers.errors.already_added")}`), Promise.reject(Error(G));
|
|
4202
4204
|
}
|
|
4203
|
-
}, I = E([]),
|
|
4205
|
+
}, I = E([]), K = (_) => {
|
|
4204
4206
|
I.value = _.map((L) => {
|
|
4205
4207
|
var P;
|
|
4206
4208
|
return (P = L.reason) == null ? void 0 : P.message;
|
|
@@ -4213,17 +4215,17 @@ const rl = {
|
|
|
4213
4215
|
}, { immediate: !0 }), (_, L) => {
|
|
4214
4216
|
const P = D("KMultiselect"), G = D("KAlert"), Q = D("KPrompt");
|
|
4215
4217
|
return f(), R(Q, {
|
|
4216
|
-
"action-pending":
|
|
4218
|
+
"action-pending": N.value,
|
|
4217
4219
|
class: "kong-ui-entities-add-consumers-modal",
|
|
4218
4220
|
"data-testid": "add-consumer-modal",
|
|
4219
4221
|
"is-visible": e.visible,
|
|
4220
4222
|
title: m(t)("consumers.consumer_groups.add.title"),
|
|
4221
4223
|
onCanceled: U,
|
|
4222
|
-
onProceed:
|
|
4224
|
+
onProceed: q
|
|
4223
4225
|
}, {
|
|
4224
4226
|
"body-content": g(() => [
|
|
4225
|
-
|
|
4226
|
-
|
|
4227
|
+
F("div", ms, [
|
|
4228
|
+
F("p", gs, j(m(t)("consumers.consumer_groups.add.ctaText")), 1),
|
|
4227
4229
|
O(P, {
|
|
4228
4230
|
modelValue: i.value,
|
|
4229
4231
|
"onUpdate:modelValue": L[0] || (L[0] = (J) => i.value = J),
|
|
@@ -4234,29 +4236,29 @@ const rl = {
|
|
|
4234
4236
|
label: m(t)("consumers.consumer_groups.add.consumers_label"),
|
|
4235
4237
|
loading: m(s),
|
|
4236
4238
|
placeholder: m(t)("consumers.consumer_groups.add.consumer_placeholder"),
|
|
4237
|
-
readonly:
|
|
4239
|
+
readonly: N.value,
|
|
4238
4240
|
required: "",
|
|
4239
4241
|
width: "100%",
|
|
4240
4242
|
onQueryChange: m(l)
|
|
4241
4243
|
}, {
|
|
4242
4244
|
"item-template": g(({ item: J }) => [
|
|
4243
|
-
|
|
4244
|
-
d(J).data.username && d(J).data.custom_id ? (f(), T("div", hs, j(d(J).data.custom_id), 1)) :
|
|
4245
|
+
F("div", ys, j(J.label), 1),
|
|
4246
|
+
d(J).data.username && d(J).data.custom_id ? (f(), T("div", hs, j(d(J).data.custom_id), 1)) : z("", !0)
|
|
4245
4247
|
]),
|
|
4246
4248
|
_: 1
|
|
4247
4249
|
}, 8, ["modelValue", "dropdown-footer-text", "items", "label", "loading", "placeholder", "readonly", "onQueryChange"]),
|
|
4248
4250
|
k.value || w.value || I.value.length ? (f(), T("div", vs, [
|
|
4249
4251
|
O(G, { appearance: "danger" }, {
|
|
4250
4252
|
alertMessage: g(() => [
|
|
4251
|
-
|
|
4253
|
+
F("p", null, j(m(t)("consumers.errors.add")), 1),
|
|
4252
4254
|
I.value.length ? (f(), T("ul", bs, [
|
|
4253
4255
|
(f(!0), T(me, null, pe(I.value, (J, X) => (f(), T("li", { key: X }, j(J), 1))), 128))
|
|
4254
|
-
])) :
|
|
4255
|
-
|
|
4256
|
+
])) : z("", !0),
|
|
4257
|
+
F("div", null, j(k.value || w.value), 1)
|
|
4256
4258
|
]),
|
|
4257
4259
|
_: 1
|
|
4258
4260
|
})
|
|
4259
|
-
])) :
|
|
4261
|
+
])) : z("", !0)
|
|
4260
4262
|
])
|
|
4261
4263
|
]),
|
|
4262
4264
|
_: 1
|
|
@@ -4314,9 +4316,9 @@ const rl = {
|
|
|
4314
4316
|
},
|
|
4315
4317
|
emits: ["error", "copy:success", "copy:error", "delete:success", "add:success", "remove:success"],
|
|
4316
4318
|
setup(e, { emit: n }) {
|
|
4317
|
-
var
|
|
4319
|
+
var Kt;
|
|
4318
4320
|
const t = n, a = e, { i18nT: r, i18n: { t: o } } = Qe.useI18n(), i = yt(), { axiosInstance: l } = xt({
|
|
4319
|
-
headers: (
|
|
4321
|
+
headers: (Kt = a.config) == null ? void 0 : Kt.requestHeaders
|
|
4320
4322
|
}), s = E(1), u = $(() => !!a.config.consumerGroupId), p = $(() => a.config.app !== "kongManager" || !!a.config.disableSorting), c = {
|
|
4321
4323
|
username: { label: o("consumers.list.table_headers.username"), searchable: !0, sortable: !0 },
|
|
4322
4324
|
custom_id: { label: o("consumers.list.table_headers.custom_id"), searchable: !0, sortable: !0 },
|
|
@@ -4324,9 +4326,9 @@ const rl = {
|
|
|
4324
4326
|
}, h = c, d = (x) => ({
|
|
4325
4327
|
"data-testid": x.username ?? x.custom_id ?? x.id
|
|
4326
4328
|
}), w = $(() => {
|
|
4327
|
-
var
|
|
4329
|
+
var H, te, ce, ye;
|
|
4328
4330
|
let x = `${a.config.apiBaseUrl}${xe.list[a.config.app][u.value ? "forConsumerGroup" : "all"]}`;
|
|
4329
|
-
return a.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((
|
|
4331
|
+
return a.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((H = a.config) == null ? void 0 : H.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((te = a.config) == null ? void 0 : te.consumerGroupId) || "") : a.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (ce = a.config) != null && ce.workspace ? `/${a.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((ye = a.config) == null ? void 0 : ye.consumerGroupId) || "")), x;
|
|
4330
4332
|
}), v = E(""), A = $(() => {
|
|
4331
4333
|
const x = a.config.app === "konnect" || a.config.isExactMatch;
|
|
4332
4334
|
return x ? {
|
|
@@ -4342,11 +4344,11 @@ const rl = {
|
|
|
4342
4344
|
};
|
|
4343
4345
|
}), y = $(() => u.value ? "consumers" : void 0), { fetcher: C, fetcherState: U } = ps(a.config, w.value, y.value), S = () => {
|
|
4344
4346
|
v.value = "";
|
|
4345
|
-
},
|
|
4347
|
+
}, N = () => {
|
|
4346
4348
|
s.value++;
|
|
4347
|
-
}, k = (x) => x ?? "-",
|
|
4349
|
+
}, k = (x) => x ?? "-", q = E(null), B = (x, H) => {
|
|
4348
4350
|
const te = x.id;
|
|
4349
|
-
if (!
|
|
4351
|
+
if (!H(te)) {
|
|
4350
4352
|
t("copy:error", {
|
|
4351
4353
|
entity: x,
|
|
4352
4354
|
field: "id",
|
|
@@ -4359,9 +4361,9 @@ const rl = {
|
|
|
4359
4361
|
field: "id",
|
|
4360
4362
|
message: o("consumers.copy.success", { val: te })
|
|
4361
4363
|
});
|
|
4362
|
-
}, b = (x,
|
|
4364
|
+
}, b = (x, H) => {
|
|
4363
4365
|
const te = JSON.stringify(x);
|
|
4364
|
-
if (!
|
|
4366
|
+
if (!H(te)) {
|
|
4365
4367
|
t("copy:error", {
|
|
4366
4368
|
entity: x,
|
|
4367
4369
|
message: o("consumers.errors.copy")
|
|
@@ -4375,7 +4377,7 @@ const rl = {
|
|
|
4375
4377
|
}, I = async (x) => {
|
|
4376
4378
|
var te;
|
|
4377
4379
|
await ((te = a.canRetrieve) == null ? void 0 : te.call(a, x)) && i.push(a.config.getViewRoute(x.id));
|
|
4378
|
-
},
|
|
4380
|
+
}, K = (x) => ({
|
|
4379
4381
|
label: o("consumers.actions.view"),
|
|
4380
4382
|
to: a.config.getViewRoute(x)
|
|
4381
4383
|
}), V = (x) => ({
|
|
@@ -4386,13 +4388,13 @@ const rl = {
|
|
|
4386
4388
|
}, X = () => {
|
|
4387
4389
|
L.value = !1;
|
|
4388
4390
|
}, ue = async () => {
|
|
4389
|
-
var x,
|
|
4391
|
+
var x, H, te;
|
|
4390
4392
|
if ((x = _.value) != null && x.id) {
|
|
4391
4393
|
P.value = !0;
|
|
4392
4394
|
try {
|
|
4393
4395
|
await l.delete(Q(_.value.id)), P.value = !1, L.value = !1, s.value++, t("delete:success", _.value);
|
|
4394
4396
|
} catch (ce) {
|
|
4395
|
-
G.value = ((te = (
|
|
4397
|
+
G.value = ((te = (H = ce.response) == null ? void 0 : H.data) == null ? void 0 : te.message) || ce.message || o("consumers.errors.delete"), t("error", ce);
|
|
4396
4398
|
} finally {
|
|
4397
4399
|
P.value = !1;
|
|
4398
4400
|
}
|
|
@@ -4401,8 +4403,8 @@ const rl = {
|
|
|
4401
4403
|
et.value = !0;
|
|
4402
4404
|
}, jt = () => {
|
|
4403
4405
|
et.value = !1;
|
|
4404
|
-
}, Mt = (x,
|
|
4405
|
-
|
|
4406
|
+
}, Mt = (x, H) => {
|
|
4407
|
+
H || jt(), s.value++, t("add:success", x);
|
|
4406
4408
|
}, ua = () => {
|
|
4407
4409
|
u.value && $t();
|
|
4408
4410
|
}, be = E(void 0), tt = E(!1), ca = E(""), da = (x) => {
|
|
@@ -4410,9 +4412,9 @@ const rl = {
|
|
|
4410
4412
|
}, Ot = () => {
|
|
4411
4413
|
tt.value = !1, be.value = void 0;
|
|
4412
4414
|
}, pa = $(() => {
|
|
4413
|
-
var
|
|
4415
|
+
var H, te, ce, ye;
|
|
4414
4416
|
let x = `${a.config.apiBaseUrl}${xe.list[a.config.app].oneForConsumerGroup}`;
|
|
4415
|
-
return a.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((
|
|
4417
|
+
return a.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((H = a.config) == null ? void 0 : H.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((te = a.config) == null ? void 0 : te.consumerGroupId) || "") : a.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (ce = a.config) != null && ce.workspace ? `/${a.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((ye = a.config) == null ? void 0 : ye.consumerGroupId) || "")), x;
|
|
4416
4418
|
}), Et = E(!1), fa = async () => {
|
|
4417
4419
|
if (be.value) {
|
|
4418
4420
|
Et.value = !0;
|
|
@@ -4425,16 +4427,16 @@ const rl = {
|
|
|
4425
4427
|
Et.value = !1;
|
|
4426
4428
|
}
|
|
4427
4429
|
}
|
|
4428
|
-
},
|
|
4430
|
+
}, Nt = E(!0);
|
|
4429
4431
|
ve(U, (x) => {
|
|
4430
|
-
var
|
|
4431
|
-
if (Array.isArray((
|
|
4432
|
-
|
|
4432
|
+
var H, te, ce, ye;
|
|
4433
|
+
if (Array.isArray((H = x == null ? void 0 : x.response) == null ? void 0 : H.data) && (Nt.value = x.response.data.length > 0), x.status === Se.Error) {
|
|
4434
|
+
q.value = {
|
|
4433
4435
|
title: o("consumers.errors.general")
|
|
4434
|
-
}, (ye = (ce = (te = x.error) == null ? void 0 : te.response) == null ? void 0 : ce.data) != null && ye.message && (
|
|
4436
|
+
}, (ye = (ce = (te = x.error) == null ? void 0 : te.response) == null ? void 0 : ce.data) != null && ye.message && (q.value.message = x.error.response.data.message), t("error", x.error);
|
|
4435
4437
|
return;
|
|
4436
4438
|
}
|
|
4437
|
-
|
|
4439
|
+
q.value = null;
|
|
4438
4440
|
});
|
|
4439
4441
|
const nt = E({
|
|
4440
4442
|
ctaPath: u.value ? void 0 : a.config.createRoute,
|
|
@@ -4444,17 +4446,17 @@ const rl = {
|
|
|
4444
4446
|
});
|
|
4445
4447
|
return gt(async () => {
|
|
4446
4448
|
await a.canCreate() && (nt.value.title = u.value ? o("consumers.list.empty_state.title_for_consumer_group") : o("consumers.list.empty_state.title"), nt.value.ctaText = u.value ? o("consumers.actions.add_consumer") : o("consumers.actions.create"));
|
|
4447
|
-
}), (x,
|
|
4448
|
-
const te = D("KButton"), ce = D("KBadge"), ye = D("KTruncate"),
|
|
4449
|
+
}), (x, H) => {
|
|
4450
|
+
const te = D("KButton"), ce = D("KBadge"), ye = D("KTruncate"), qe = D("KDropdownItem"), qt = D("KClipboardProvider"), ma = D("KPrompt");
|
|
4449
4451
|
return f(), T("div", ws, [
|
|
4450
|
-
O(m(
|
|
4452
|
+
O(m(Fl), {
|
|
4451
4453
|
"cache-identifier": e.cacheIdentifier,
|
|
4452
4454
|
"disable-pagination": u.value,
|
|
4453
4455
|
"disable-pagination-page-jump": "",
|
|
4454
4456
|
"disable-sorting": p.value,
|
|
4455
4457
|
"empty-state-options": nt.value,
|
|
4456
4458
|
"enable-entity-actions": "",
|
|
4457
|
-
"error-message":
|
|
4459
|
+
"error-message": q.value,
|
|
4458
4460
|
fetcher: m(C),
|
|
4459
4461
|
"fetcher-cache-key": s.value,
|
|
4460
4462
|
"pagination-type": "offset",
|
|
@@ -4464,15 +4466,15 @@ const rl = {
|
|
|
4464
4466
|
"table-headers": m(h),
|
|
4465
4467
|
"use-action-outside": e.useActionOutside,
|
|
4466
4468
|
onClearSearchInput: S,
|
|
4467
|
-
"onClick:row":
|
|
4469
|
+
"onClick:row": H[3] || (H[3] = (Y) => I(Y)),
|
|
4468
4470
|
onEmptyStateCtaClicked: ua,
|
|
4469
|
-
onSort:
|
|
4471
|
+
onSort: N
|
|
4470
4472
|
}, {
|
|
4471
4473
|
"toolbar-filter": g(() => [
|
|
4472
|
-
u.value ?
|
|
4474
|
+
u.value ? z("", !0) : (f(), R(m(ns), {
|
|
4473
4475
|
key: 0,
|
|
4474
4476
|
modelValue: v.value,
|
|
4475
|
-
"onUpdate:modelValue":
|
|
4477
|
+
"onUpdate:modelValue": H[0] || (H[0] = (Y) => v.value = Y),
|
|
4476
4478
|
config: A.value
|
|
4477
4479
|
}, null, 8, ["modelValue", "config"]))
|
|
4478
4480
|
]),
|
|
@@ -4485,19 +4487,19 @@ const rl = {
|
|
|
4485
4487
|
"auth-function": () => e.canCreate()
|
|
4486
4488
|
}, {
|
|
4487
4489
|
default: g(() => [
|
|
4488
|
-
|
|
4490
|
+
Fe(O(te, {
|
|
4489
4491
|
appearance: "primary",
|
|
4490
4492
|
"data-testid": "toolbar-add-consumer",
|
|
4491
4493
|
icon: "plus",
|
|
4492
4494
|
to: e.config.consumerGroupId ? void 0 : e.config.createRoute,
|
|
4493
|
-
onClick:
|
|
4495
|
+
onClick: H[1] || (H[1] = () => e.config.consumerGroupId ? $t() : void 0)
|
|
4494
4496
|
}, {
|
|
4495
4497
|
default: g(() => [
|
|
4496
4498
|
W(j(e.config.consumerGroupId ? m(o)("consumers.actions.add_consumer") : m(o)("consumers.list.toolbar_actions.new_consumer")), 1)
|
|
4497
4499
|
]),
|
|
4498
4500
|
_: 1
|
|
4499
4501
|
}, 8, ["to"]), [
|
|
4500
|
-
[Le,
|
|
4502
|
+
[Le, Nt.value]
|
|
4501
4503
|
])
|
|
4502
4504
|
]),
|
|
4503
4505
|
_: 1
|
|
@@ -4505,7 +4507,7 @@ const rl = {
|
|
|
4505
4507
|
], 8, ["disabled"]))
|
|
4506
4508
|
]),
|
|
4507
4509
|
username: g(({ rowValue: Y }) => [
|
|
4508
|
-
|
|
4510
|
+
F("b", null, j(k(Y)), 1)
|
|
4509
4511
|
]),
|
|
4510
4512
|
custom_id: g(({ rowValue: Y }) => [
|
|
4511
4513
|
W(j(k(Y)), 1)
|
|
@@ -4515,7 +4517,7 @@ const rl = {
|
|
|
4515
4517
|
default: g(() => [
|
|
4516
4518
|
(f(!0), T(me, null, pe(Y, (Te) => (f(), R(ce, {
|
|
4517
4519
|
key: Te,
|
|
4518
|
-
onClick:
|
|
4520
|
+
onClick: H[2] || (H[2] = Ge(() => {
|
|
4519
4521
|
}, ["stop"]))
|
|
4520
4522
|
}, {
|
|
4521
4523
|
default: g(() => [
|
|
@@ -4528,11 +4530,11 @@ const rl = {
|
|
|
4528
4530
|
}, 1024)) : (f(), T("span", Is, "-"))
|
|
4529
4531
|
]),
|
|
4530
4532
|
actions: g(({ row: Y }) => [
|
|
4531
|
-
O(
|
|
4533
|
+
O(qt, null, {
|
|
4532
4534
|
default: g(({ copyToClipboard: Te }) => [
|
|
4533
|
-
O(
|
|
4535
|
+
O(qe, {
|
|
4534
4536
|
"data-testid": "action-entity-copy-id",
|
|
4535
|
-
onClick: (ga) =>
|
|
4537
|
+
onClick: (ga) => B(Y, Te)
|
|
4536
4538
|
}, {
|
|
4537
4539
|
default: g(() => [
|
|
4538
4540
|
W(j(m(o)("consumers.actions.copy_id")), 1)
|
|
@@ -4542,9 +4544,9 @@ const rl = {
|
|
|
4542
4544
|
]),
|
|
4543
4545
|
_: 2
|
|
4544
4546
|
}, 1024),
|
|
4545
|
-
O(
|
|
4547
|
+
O(qt, null, {
|
|
4546
4548
|
default: g(({ copyToClipboard: Te }) => [
|
|
4547
|
-
O(
|
|
4549
|
+
O(qe, {
|
|
4548
4550
|
"data-testid": "action-entity-copy-json",
|
|
4549
4551
|
onClick: (ga) => b(Y, Te)
|
|
4550
4552
|
}, {
|
|
@@ -4560,10 +4562,10 @@ const rl = {
|
|
|
4560
4562
|
"auth-function": () => e.canRetrieve(Y)
|
|
4561
4563
|
}, {
|
|
4562
4564
|
default: g(() => [
|
|
4563
|
-
O(
|
|
4565
|
+
O(qe, {
|
|
4564
4566
|
"data-testid": "action-entity-view",
|
|
4565
4567
|
"has-divider": "",
|
|
4566
|
-
item:
|
|
4568
|
+
item: K(Y.id)
|
|
4567
4569
|
}, null, 8, ["item"])
|
|
4568
4570
|
]),
|
|
4569
4571
|
_: 2
|
|
@@ -4572,7 +4574,7 @@ const rl = {
|
|
|
4572
4574
|
"auth-function": () => e.canEdit(Y)
|
|
4573
4575
|
}, {
|
|
4574
4576
|
default: g(() => [
|
|
4575
|
-
O(
|
|
4577
|
+
O(qe, {
|
|
4576
4578
|
"data-testid": "action-entity-edit",
|
|
4577
4579
|
item: V(Y.id)
|
|
4578
4580
|
}, null, 8, ["item"])
|
|
@@ -4583,7 +4585,7 @@ const rl = {
|
|
|
4583
4585
|
"auth-function": () => e.canDelete(Y)
|
|
4584
4586
|
}, {
|
|
4585
4587
|
default: g(() => [
|
|
4586
|
-
O(
|
|
4588
|
+
O(qe, {
|
|
4587
4589
|
danger: "",
|
|
4588
4590
|
"data-testid": "action-entity-delete",
|
|
4589
4591
|
"has-divider": "",
|
|
@@ -4617,10 +4619,10 @@ const rl = {
|
|
|
4617
4619
|
config: e.config,
|
|
4618
4620
|
"data-testid": "add-consumer-modal",
|
|
4619
4621
|
visible: et.value,
|
|
4620
|
-
"onAdd:partialSuccess":
|
|
4621
|
-
"onAdd:success":
|
|
4622
|
+
"onAdd:partialSuccess": H[4] || (H[4] = (Y) => Mt(Y, !0)),
|
|
4623
|
+
"onAdd:success": H[5] || (H[5] = (Y) => Mt(Y)),
|
|
4622
4624
|
onCancel: jt
|
|
4623
|
-
}, null, 8, ["config", "visible"])) :
|
|
4625
|
+
}, null, 8, ["config", "visible"])) : z("", !0),
|
|
4624
4626
|
e.config.consumerGroupId && be.value ? (f(), R(ma, {
|
|
4625
4627
|
key: 1,
|
|
4626
4628
|
"data-testid": "remove-consumer-modal",
|
|
@@ -4637,22 +4639,22 @@ const rl = {
|
|
|
4637
4639
|
tag: "p"
|
|
4638
4640
|
}, ke({
|
|
4639
4641
|
consumer: g(() => [
|
|
4640
|
-
|
|
4642
|
+
F("strong", null, j(be.value.username || be.value.custom_id || be.value.id), 1)
|
|
4641
4643
|
]),
|
|
4642
4644
|
_: 2
|
|
4643
4645
|
}, [
|
|
4644
4646
|
e.config.consumerGroupName ? {
|
|
4645
4647
|
name: "consumerGroup",
|
|
4646
4648
|
fn: g(() => [
|
|
4647
|
-
|
|
4649
|
+
F("strong", null, j(e.config.consumerGroupName), 1)
|
|
4648
4650
|
]),
|
|
4649
4651
|
key: "0"
|
|
4650
4652
|
} : void 0
|
|
4651
4653
|
]), 1032, ["keypath"]),
|
|
4652
|
-
|
|
4654
|
+
F("p", null, j(m(o)("consumers.consumer_groups.remove.description")), 1)
|
|
4653
4655
|
]),
|
|
4654
4656
|
_: 1
|
|
4655
|
-
}, 8, ["is-visible", "title"])) :
|
|
4657
|
+
}, 8, ["is-visible", "title"])) : z("", !0)
|
|
4656
4658
|
]);
|
|
4657
4659
|
};
|
|
4658
4660
|
}
|
|
@@ -4674,10 +4676,10 @@ const rl = {
|
|
|
4674
4676
|
},
|
|
4675
4677
|
emits: ["update", "error", "loading"],
|
|
4676
4678
|
setup(e, { emit: n }) {
|
|
4677
|
-
var
|
|
4679
|
+
var N;
|
|
4678
4680
|
const t = e, a = n, { i18nT: r, i18n: { t: o } } = Qe.useI18n(), i = yt(), { axiosInstance: l } = xt({
|
|
4679
|
-
headers: (
|
|
4680
|
-
}), { getMessageFromError: s } = ds(), u =
|
|
4681
|
+
headers: (N = t.config) == null ? void 0 : N.requestHeaders
|
|
4682
|
+
}), { getMessageFromError: s } = ds(), u = Bt({
|
|
4681
4683
|
fields: {
|
|
4682
4684
|
username: "",
|
|
4683
4685
|
customId: "",
|
|
@@ -4685,13 +4687,13 @@ const rl = {
|
|
|
4685
4687
|
},
|
|
4686
4688
|
readonly: !1,
|
|
4687
4689
|
errorMessage: ""
|
|
4688
|
-
}), p =
|
|
4690
|
+
}), p = Bt({
|
|
4689
4691
|
username: "",
|
|
4690
4692
|
customId: "",
|
|
4691
4693
|
tags: ""
|
|
4692
4694
|
}), c = $(() => {
|
|
4693
|
-
var k,
|
|
4694
|
-
return (
|
|
4695
|
+
var k, q;
|
|
4696
|
+
return (q = xe.form[(k = t.config) == null ? void 0 : k.app]) == null ? void 0 : q.edit;
|
|
4695
4697
|
}), h = () => {
|
|
4696
4698
|
var k;
|
|
4697
4699
|
i.push(((k = t.config) == null ? void 0 : k.cancelRoute) || { name: "consumer-list" });
|
|
@@ -4700,33 +4702,33 @@ const rl = {
|
|
|
4700
4702
|
}, w = (k) => {
|
|
4701
4703
|
a("error", k);
|
|
4702
4704
|
}, v = (k) => {
|
|
4703
|
-
var
|
|
4704
|
-
u.fields.username = ((
|
|
4705
|
-
const
|
|
4706
|
-
u.fields.tags = (
|
|
4705
|
+
var B, b, I;
|
|
4706
|
+
u.fields.username = ((B = k == null ? void 0 : k.item) == null ? void 0 : B.username) || (k == null ? void 0 : k.username) || "", u.fields.customId = ((b = k == null ? void 0 : k.item) == null ? void 0 : b.custom_id) || (k == null ? void 0 : k.custom_id) || "";
|
|
4707
|
+
const q = ((I = k == null ? void 0 : k.item) == null ? void 0 : I.tags) || (k == null ? void 0 : k.tags) || [];
|
|
4708
|
+
u.fields.tags = (q == null ? void 0 : q.join(", ")) || "", Object.assign(p, u.fields);
|
|
4707
4709
|
}, A = $(() => t.consumerId ? ut.Edit : ut.Create), y = (k) => {
|
|
4708
|
-
var
|
|
4709
|
-
let
|
|
4710
|
-
return ((I = t.config) == null ? void 0 : I.app) === "konnect" ?
|
|
4710
|
+
var B, b, I, K, V, _;
|
|
4711
|
+
let q = `${(B = t.config) == null ? void 0 : B.apiBaseUrl}${xe.form[(b = t.config) == null ? void 0 : b.app][k]}`;
|
|
4712
|
+
return ((I = t.config) == null ? void 0 : I.app) === "konnect" ? q = q.replace(/{controlPlaneId}/gi, ((K = t.config) == null ? void 0 : K.controlPlaneId) || "") : ((V = t.config) == null ? void 0 : V.app) === "kongManager" && (q = q.replace(/\/{workspace}/gi, (_ = t.config) != null && _.workspace ? `/${t.config.workspace}` : "")), q = q.replace(/{id}/gi, t.consumerId), q;
|
|
4711
4713
|
}, C = $(() => !!u.fields.username || !!u.fields.customId), U = $(() => JSON.stringify(u.fields) !== JSON.stringify(p)), S = async () => {
|
|
4712
|
-
var k,
|
|
4714
|
+
var k, q, B;
|
|
4713
4715
|
try {
|
|
4714
4716
|
u.readonly = !0;
|
|
4715
4717
|
const b = {
|
|
4716
4718
|
username: u.fields.username || null,
|
|
4717
4719
|
custom_id: u.fields.customId || null,
|
|
4718
|
-
tags: (
|
|
4720
|
+
tags: (q = (k = u.fields.tags.split(",")) == null ? void 0 : k.map((K) => String(K || "").trim())) == null ? void 0 : q.filter((K) => K !== "")
|
|
4719
4721
|
};
|
|
4720
4722
|
let I;
|
|
4721
|
-
await l.post(y("validate"), b), A.value === "create" ? I = await l.post(y("create"), b) : A.value === "edit" && (I = ((
|
|
4723
|
+
await l.post(y("validate"), b), A.value === "create" ? I = await l.post(y("create"), b) : A.value === "edit" && (I = ((B = t.config) == null ? void 0 : B.app) === "konnect" ? await l.put(y("edit"), b) : await l.patch(y("edit"), b)), v(I == null ? void 0 : I.data), a("update", I == null ? void 0 : I.data);
|
|
4722
4724
|
} catch (b) {
|
|
4723
4725
|
u.errorMessage = s(b), a("error", b);
|
|
4724
4726
|
} finally {
|
|
4725
4727
|
u.readonly = !1;
|
|
4726
4728
|
}
|
|
4727
4729
|
};
|
|
4728
|
-
return (k,
|
|
4729
|
-
const
|
|
4730
|
+
return (k, q) => {
|
|
4731
|
+
const B = D("KInput"), b = D("KCard");
|
|
4730
4732
|
return f(), T("div", Ss, [
|
|
4731
4733
|
O(m(jl), {
|
|
4732
4734
|
"can-submit": C.value && U.value,
|
|
@@ -4736,28 +4738,28 @@ const rl = {
|
|
|
4736
4738
|
"fetch-url": c.value,
|
|
4737
4739
|
"is-readonly": u.readonly,
|
|
4738
4740
|
onCancel: h,
|
|
4739
|
-
"onFetch:error":
|
|
4741
|
+
"onFetch:error": q[3] || (q[3] = (I) => w(I)),
|
|
4740
4742
|
"onFetch:success": v,
|
|
4741
|
-
onLoading:
|
|
4743
|
+
onLoading: q[4] || (q[4] = (I) => d(I)),
|
|
4742
4744
|
onSubmit: S
|
|
4743
4745
|
}, {
|
|
4744
4746
|
default: g(() => [
|
|
4745
|
-
|
|
4747
|
+
F("div", null, [
|
|
4746
4748
|
O(m(us), {
|
|
4747
4749
|
description: m(o)("consumers.form.info.description"),
|
|
4748
4750
|
"has-divider": "",
|
|
4749
4751
|
title: m(o)("consumers.form.info.title")
|
|
4750
4752
|
}, {
|
|
4751
4753
|
default: g(() => [
|
|
4752
|
-
|
|
4753
|
-
|
|
4754
|
-
|
|
4754
|
+
F("div", null, [
|
|
4755
|
+
F("h5", As, j(m(o)("consumers.form.consumer_identification.title")) + "* ", 1),
|
|
4756
|
+
F("p", xs, j(m(o)("consumers.form.consumer_identification.description")), 1)
|
|
4755
4757
|
]),
|
|
4756
4758
|
O(b, null, {
|
|
4757
4759
|
default: g(() => [
|
|
4758
|
-
O(
|
|
4760
|
+
O(B, {
|
|
4759
4761
|
modelValue: u.fields.username,
|
|
4760
|
-
"onUpdate:modelValue":
|
|
4762
|
+
"onUpdate:modelValue": q[0] || (q[0] = (I) => u.fields.username = I),
|
|
4761
4763
|
modelModifiers: { trim: !0 },
|
|
4762
4764
|
autocomplete: "off",
|
|
4763
4765
|
class: "username-field",
|
|
@@ -4776,16 +4778,16 @@ const rl = {
|
|
|
4776
4778
|
scope: "global"
|
|
4777
4779
|
}, {
|
|
4778
4780
|
custom_id: g(() => [
|
|
4779
|
-
|
|
4781
|
+
F("code", null, j(m(o)("consumers.fields.username.custom_id")), 1)
|
|
4780
4782
|
]),
|
|
4781
4783
|
_: 1
|
|
4782
4784
|
})
|
|
4783
4785
|
]),
|
|
4784
4786
|
_: 1
|
|
4785
4787
|
}, 8, ["modelValue", "label", "placeholder", "readonly"]),
|
|
4786
|
-
O(
|
|
4788
|
+
O(B, {
|
|
4787
4789
|
modelValue: u.fields.customId,
|
|
4788
|
-
"onUpdate:modelValue":
|
|
4790
|
+
"onUpdate:modelValue": q[1] || (q[1] = (I) => u.fields.customId = I),
|
|
4789
4791
|
modelModifiers: { trim: !0 },
|
|
4790
4792
|
autocomplete: "off",
|
|
4791
4793
|
"data-testid": "consumer-form-custom-id",
|
|
@@ -4803,7 +4805,7 @@ const rl = {
|
|
|
4803
4805
|
scope: "global"
|
|
4804
4806
|
}, {
|
|
4805
4807
|
username: g(() => [
|
|
4806
|
-
|
|
4808
|
+
F("code", null, j(m(o)("consumers.fields.custom_id.username")), 1)
|
|
4807
4809
|
]),
|
|
4808
4810
|
_: 1
|
|
4809
4811
|
})
|
|
@@ -4813,9 +4815,9 @@ const rl = {
|
|
|
4813
4815
|
]),
|
|
4814
4816
|
_: 1
|
|
4815
4817
|
}),
|
|
4816
|
-
O(
|
|
4818
|
+
O(B, {
|
|
4817
4819
|
modelValue: u.fields.tags,
|
|
4818
|
-
"onUpdate:modelValue":
|
|
4820
|
+
"onUpdate:modelValue": q[2] || (q[2] = (I) => u.fields.tags = I),
|
|
4819
4821
|
modelModifiers: { trim: !0 },
|
|
4820
4822
|
autocomplete: "off",
|
|
4821
4823
|
"data-testid": "consumer-form-tags",
|
|
@@ -4909,7 +4911,7 @@ const rl = {
|
|
|
4909
4911
|
scope: "global"
|
|
4910
4912
|
}, {
|
|
4911
4913
|
custom_id: g(() => [
|
|
4912
|
-
|
|
4914
|
+
F("code", null, j(m(t)("consumers.fields.username.custom_id")), 1)
|
|
4913
4915
|
]),
|
|
4914
4916
|
_: 1
|
|
4915
4917
|
})
|
|
@@ -4920,7 +4922,7 @@ const rl = {
|
|
|
4920
4922
|
scope: "global"
|
|
4921
4923
|
}, {
|
|
4922
4924
|
username: g(() => [
|
|
4923
|
-
|
|
4925
|
+
F("code", null, j(m(t)("consumers.fields.custom_id.username")), 1)
|
|
4924
4926
|
]),
|
|
4925
4927
|
_: 1
|
|
4926
4928
|
})
|