@kong-ui-public/entities-snis 3.3.16 → 3.3.17
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-snis.es.js +155 -159
- package/dist/entities-snis.umd.js +5 -5
- package/package.json +2 -2
package/dist/entities-snis.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as te, ref as
|
|
1
|
+
import { defineComponent as te, ref as F, computed as I, watch as me, renderSlot as oe, createCommentVNode as Q, unref as h, onBeforeMount as ct, resolveComponent as U, openBlock as k, createBlock as P, resolveDynamicComponent as Ce, withCtx as v, createElementVNode as L, toDisplayString as E, createElementBlock as q, withModifiers as it, createVNode as A, createTextVNode as G, createSlots as zt, withDirectives as fe, vShow as ge, renderList as ut, Fragment as Ht, normalizeClass as $e, withKeys as Yn, useSlots as Wn, useCssVars as Jn, inject as Zn, onMounted as Gn, onUnmounted as Qn, normalizeStyle as Ue, pushScopeId as Be, popScopeId as Ke, Teleport as Xn, reactive as vt } from "vue";
|
|
2
2
|
import { createI18n as Yt, i18nTComponent as Wt } from "@kong-ui-public/i18n";
|
|
3
3
|
import bt from "axios";
|
|
4
4
|
import "@kong/kongponents";
|
|
@@ -92,7 +92,7 @@ function li() {
|
|
|
92
92
|
}
|
|
93
93
|
const Zt = {
|
|
94
94
|
useI18n: li
|
|
95
|
-
}, je = "/v2/control-planes/{controlPlaneId}/core-entities", Oe = "/{workspace}",
|
|
95
|
+
}, je = "/v2/control-planes/{controlPlaneId}/core-entities", Oe = "/{workspace}", Me = {
|
|
96
96
|
list: {
|
|
97
97
|
konnect: {
|
|
98
98
|
all: `${je}/snis`
|
|
@@ -360,71 +360,67 @@ function Si(e, t, n, i = {
|
|
|
360
360
|
searchKeys: ["id"]
|
|
361
361
|
}) {
|
|
362
362
|
n || (n = "1000");
|
|
363
|
-
const { axiosInstance: r } = dt(e.axiosRequestConfig), { i18n: { t: o } } = Je(), { debounce: a } = ci(), l = a(async (
|
|
364
|
-
await y(
|
|
365
|
-
}, 200), s =
|
|
366
|
-
const
|
|
367
|
-
return e.app === "konnect" ?
|
|
368
|
-
}), { isValidUuid:
|
|
363
|
+
const { axiosInstance: r } = dt(e.axiosRequestConfig), { i18n: { t: o } } = Je(), { debounce: a } = ci(), l = a(async (N) => {
|
|
364
|
+
await y(N);
|
|
365
|
+
}, 200), s = F(!1), u = F(""), d = F(""), c = F([]), f = F([]), p = F(void 0), b = I(() => {
|
|
366
|
+
const N = `${e.apiBaseUrl}${h(t)}`;
|
|
367
|
+
return e.app === "konnect" ? N.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" ? N.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : "") : N;
|
|
368
|
+
}), { isValidUuid: _ } = Qt(), S = async () => {
|
|
369
369
|
try {
|
|
370
370
|
s.value = !0;
|
|
371
|
-
const { data:
|
|
372
|
-
|
|
371
|
+
const { data: N } = await r.get(`${b.value}?size=${n}`);
|
|
372
|
+
N != null && N.next || (p.value = i.fetchedItemsKey in N ? N[i.fetchedItemsKey] : []), f.value = i.fetchedItemsKey in N ? N[i.fetchedItemsKey] : [], c.value = f.value;
|
|
373
373
|
} catch {
|
|
374
374
|
c.value = [], u.value = o("debouncedFilter.errors.fetch");
|
|
375
375
|
} finally {
|
|
376
376
|
s.value = !1;
|
|
377
377
|
}
|
|
378
|
-
}, j =
|
|
378
|
+
}, j = F(""), y = async (N) => {
|
|
379
379
|
var C, O, g;
|
|
380
|
-
if (j.value !==
|
|
381
|
-
if (
|
|
380
|
+
if (j.value !== N) {
|
|
381
|
+
if (j.value = N ?? "", !N) {
|
|
382
382
|
c.value = f.value;
|
|
383
383
|
return;
|
|
384
|
-
}
|
|
385
|
-
j.value = _ || "";
|
|
384
|
+
}
|
|
386
385
|
if (p.value === void 0)
|
|
387
386
|
try {
|
|
388
387
|
if (s.value = !0, u.value = "", d.value = "", e.app === "konnect") {
|
|
389
|
-
|
|
390
|
-
_ && (m += `/${_}`);
|
|
391
|
-
const { data: R } = await r.get(`${m}?size=${n}`);
|
|
388
|
+
const m = `${b.value}/${N}`, { data: R } = await r.get(`${m}?size=${n}`);
|
|
392
389
|
i.fetchedItemsKey in R ? c.value = R[i.fetchedItemsKey] : R != null && R[i.exactMatchKey ?? "id"] ? c.value = [R] : c.value = [];
|
|
393
|
-
} else
|
|
390
|
+
} else {
|
|
394
391
|
const m = [];
|
|
395
|
-
N
|
|
396
|
-
const { data: B } = await r.get(`${b.value}/${
|
|
392
|
+
_(N) && i.searchKeys.includes("id") ? m.push((async () => {
|
|
393
|
+
const { data: B } = await r.get(`${b.value}/${N}`);
|
|
397
394
|
return [B[i.fetchedItemsKey] ?? B];
|
|
398
395
|
})()) : m.push(
|
|
399
396
|
...i.searchKeys.filter((B) => B !== "id").map(async (B) => {
|
|
400
|
-
const { data: Z } = await r.get(`${b.value}?${B}=${
|
|
397
|
+
const { data: Z } = await r.get(`${b.value}?${B}=${N}`);
|
|
401
398
|
return Z[i.fetchedItemsKey];
|
|
402
399
|
})
|
|
403
400
|
);
|
|
404
|
-
const R = await Promise.all(m),
|
|
401
|
+
const R = await Promise.all(m), M = /* @__PURE__ */ new Set();
|
|
405
402
|
c.value = [], (C = R == null ? void 0 : R.forEach) == null || C.call(R, (B) => {
|
|
406
403
|
var Z;
|
|
407
404
|
(Z = B == null ? void 0 : B.forEach) == null || Z.call(B, (K) => {
|
|
408
|
-
|
|
405
|
+
M.has(K.id) || (M.add(K.id), c.value.push(K));
|
|
409
406
|
});
|
|
410
407
|
});
|
|
411
|
-
}
|
|
412
|
-
c.value = f.value;
|
|
408
|
+
}
|
|
413
409
|
} catch (m) {
|
|
414
410
|
((O = m == null ? void 0 : m.response) == null ? void 0 : O.status) === 404 ? d.value = o("debouncedFilter.errors.invalid") : (c.value = [], u.value = o("debouncedFilter.errors.fetch"));
|
|
415
411
|
} finally {
|
|
416
412
|
s.value = !1;
|
|
417
413
|
}
|
|
418
414
|
else
|
|
419
|
-
s.value = !0, d.value = "",
|
|
415
|
+
s.value = !0, d.value = "", c.value = (g = p.value) == null ? void 0 : g.filter((m) => {
|
|
420
416
|
var R;
|
|
421
|
-
let
|
|
417
|
+
let M = !1;
|
|
422
418
|
for (const B of i.searchKeys) {
|
|
423
419
|
const Z = typeof m[B] == "string" ? (R = m[B]) == null ? void 0 : R.toLowerCase() : m[B];
|
|
424
|
-
Z != null && Z.includes(
|
|
420
|
+
Z != null && Z.includes(N.toLowerCase()) && (M = !0);
|
|
425
421
|
}
|
|
426
|
-
return
|
|
427
|
-
}), (!c.value || !c.value.length) && (d.value = o("debouncedFilter.errors.invalid"))
|
|
422
|
+
return M;
|
|
423
|
+
}), (!c.value || !c.value.length) && (d.value = o("debouncedFilter.errors.invalid")), s.value = !1;
|
|
428
424
|
}
|
|
429
425
|
};
|
|
430
426
|
return {
|
|
@@ -485,7 +481,7 @@ function Ai(e) {
|
|
|
485
481
|
}
|
|
486
482
|
}
|
|
487
483
|
function Xt(e, t) {
|
|
488
|
-
const n =
|
|
484
|
+
const n = F(h(e)), i = F(h(t)), r = I(
|
|
489
485
|
() => !!(n.value.app === "konnect" || n.value.isExactMatch)
|
|
490
486
|
), o = I(
|
|
491
487
|
() => i.value.startsWith("/") ? new URL(`${window.location.origin}${i.value}`) : new URL(i.value)
|
|
@@ -494,8 +490,8 @@ function Xt(e, t) {
|
|
|
494
490
|
const { page: l, pageSize: s, offset: u, sortColumnKey: d, sortColumnOrder: c, query: f } = a;
|
|
495
491
|
try {
|
|
496
492
|
let p = new URL(o.value.href);
|
|
497
|
-
return r.value && f ? (p.search = "", p = n.value.isExactMatch ? new URL(`${p.href}/${f}/`) : new URL(`${p.href}?filter[name][contains]=${f}`)) : (r.value || new URLSearchParams(f).forEach((b,
|
|
498
|
-
p.searchParams.append(
|
|
493
|
+
return r.value && f ? (p.search = "", p = n.value.isExactMatch ? new URL(`${p.href}/${f}/`) : new URL(`${p.href}?filter[name][contains]=${f}`)) : (r.value || new URLSearchParams(f).forEach((b, _) => {
|
|
494
|
+
p.searchParams.append(_, b);
|
|
499
495
|
}), d && p.searchParams.append("sort_by", d), c === "desc" && p.searchParams.append("sort_desc", "1"), p.searchParams.append("size", String(s))), u && l !== 1 && p.searchParams.append("offset", String(u)), p.href;
|
|
500
496
|
} catch (p) {
|
|
501
497
|
return console.error("RouteList(fetcher)", p), i.value;
|
|
@@ -503,7 +499,7 @@ function Xt(e, t) {
|
|
|
503
499
|
};
|
|
504
500
|
}
|
|
505
501
|
function _i(e, t, n = "data") {
|
|
506
|
-
const i = h(t), { axiosInstance: r } = dt(e.axiosRequestConfig), o = Xt(e, i), a =
|
|
502
|
+
const i = h(t), { axiosInstance: r } = dt(e.axiosRequestConfig), o = Xt(e, i), a = F({
|
|
507
503
|
status: be.Idle
|
|
508
504
|
});
|
|
509
505
|
return { fetcher: async (l) => {
|
|
@@ -581,7 +577,7 @@ const en = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
581
577
|
const n = wt(e), i = wt(t), r = n.pop(), o = i.pop(), a = St(n, i);
|
|
582
578
|
return a !== 0 ? a : r && o ? St(r.split("."), o.split(".")) : r || o ? r ? -1 : 1 : 0;
|
|
583
579
|
}, xt = (e, t, n) => {
|
|
584
|
-
|
|
580
|
+
Mi(n);
|
|
585
581
|
const i = Oi(e, t);
|
|
586
582
|
return tn[n].includes(i);
|
|
587
583
|
}, tn = {
|
|
@@ -591,18 +587,18 @@ const en = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
591
587
|
"<=": [-1, 0],
|
|
592
588
|
"<": [-1],
|
|
593
589
|
"!=": [-1, 1]
|
|
594
|
-
}, It = Object.keys(tn),
|
|
590
|
+
}, It = Object.keys(tn), Mi = (e) => {
|
|
595
591
|
if (typeof e != "string")
|
|
596
592
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
597
593
|
if (It.indexOf(e) === -1)
|
|
598
594
|
throw new Error(`Invalid operator, expected one of ${It.join("|")}`);
|
|
599
|
-
},
|
|
595
|
+
}, Fi = (e) => typeof e == "string" && /^[v\d]/.test(e) && en.test(e);
|
|
600
596
|
function $i(e) {
|
|
601
597
|
const { gatewayInfo: t, supportedRange: n } = e;
|
|
602
598
|
if (!t)
|
|
603
599
|
return !0;
|
|
604
600
|
const { edition: i, version: r } = t;
|
|
605
|
-
if (!
|
|
601
|
+
if (!Fi(r))
|
|
606
602
|
return console.error("Invalid version"), !1;
|
|
607
603
|
const o = n[i];
|
|
608
604
|
if (!o)
|
|
@@ -611,7 +607,7 @@ function $i(e) {
|
|
|
611
607
|
return !(a && xt(r, a, "<") || l && xt(r, l, ">"));
|
|
612
608
|
}
|
|
613
609
|
function Ei(e) {
|
|
614
|
-
const t =
|
|
610
|
+
const t = F(0), n = F(0), i = F(!1);
|
|
615
611
|
return me(e, (r) => {
|
|
616
612
|
r && !i.value && (t.value = r.offsetWidth, n.value = r.scrollWidth, i.value = !0);
|
|
617
613
|
}), {
|
|
@@ -1205,14 +1201,14 @@ var wn = new ee("tag:yaml.org,2002:binary", {
|
|
|
1205
1201
|
construct: Tr,
|
|
1206
1202
|
predicate: Or,
|
|
1207
1203
|
represent: jr
|
|
1208
|
-
}),
|
|
1204
|
+
}), Mr = Object.prototype.hasOwnProperty, Fr = Object.prototype.toString;
|
|
1209
1205
|
function $r(e) {
|
|
1210
1206
|
if (e === null) return !0;
|
|
1211
1207
|
var t = [], n, i, r, o, a, l = e;
|
|
1212
1208
|
for (n = 0, i = l.length; n < i; n += 1) {
|
|
1213
|
-
if (r = l[n], a = !1,
|
|
1209
|
+
if (r = l[n], a = !1, Fr.call(r) !== "[object Object]") return !1;
|
|
1214
1210
|
for (o in r)
|
|
1215
|
-
if (
|
|
1211
|
+
if (Mr.call(r, o))
|
|
1216
1212
|
if (!a) a = !0;
|
|
1217
1213
|
else return !1;
|
|
1218
1214
|
if (!a) return !1;
|
|
@@ -1478,7 +1474,7 @@ function Xr(e, t) {
|
|
|
1478
1474
|
w(e, "unexpected end of the stream within a double quoted scalar");
|
|
1479
1475
|
}
|
|
1480
1476
|
function ea(e, t) {
|
|
1481
|
-
var n = !0, i, r, o, a = e.tag, l, s = e.anchor, u, d, c, f, p, b = /* @__PURE__ */ Object.create(null),
|
|
1477
|
+
var n = !0, i, r, o, a = e.tag, l, s = e.anchor, u, d, c, f, p, b = /* @__PURE__ */ Object.create(null), _, S, j, y;
|
|
1482
1478
|
if (y = e.input.charCodeAt(e.position), y === 91)
|
|
1483
1479
|
d = 93, p = !1, l = [];
|
|
1484
1480
|
else if (y === 123)
|
|
@@ -1488,7 +1484,7 @@ function ea(e, t) {
|
|
|
1488
1484
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = l), y = e.input.charCodeAt(++e.position); y !== 0; ) {
|
|
1489
1485
|
if (Y(e, !0, t), y = e.input.charCodeAt(e.position), y === d)
|
|
1490
1486
|
return e.position++, e.tag = a, e.anchor = s, e.kind = p ? "mapping" : "sequence", e.result = l, !0;
|
|
1491
|
-
n ? y === 44 && w(e, "expected the node content, but found ','") : w(e, "missed comma between flow collection entries"), S =
|
|
1487
|
+
n ? y === 44 && w(e, "expected the node content, but found ','") : w(e, "missed comma between flow collection entries"), S = _ = j = null, c = f = !1, y === 63 && (u = e.input.charCodeAt(e.position + 1), ae(u) && (c = f = !0, e.position++, Y(e, !0, t))), i = e.line, r = e.lineStart, o = e.position, Ne(e, t, De, !1, !0), S = e.tag, _ = e.result, Y(e, !0, t), y = e.input.charCodeAt(e.position), (f || e.line === i) && y === 58 && (c = !0, y = e.input.charCodeAt(++e.position), Y(e, !0, t), Ne(e, t, De, !1, !0), j = e.result), p ? _e(e, l, b, S, _, j, i, r, o) : c ? l.push(_e(e, null, b, S, _, j, i, r, o)) : l.push(_), Y(e, !0, t), y = e.input.charCodeAt(e.position), y === 44 ? (n = !0, y = e.input.charCodeAt(++e.position)) : n = !1;
|
|
1492
1488
|
}
|
|
1493
1489
|
w(e, "unexpected end of the stream within a flow collection");
|
|
1494
1490
|
}
|
|
@@ -1539,7 +1535,7 @@ function ta(e, t) {
|
|
|
1539
1535
|
}
|
|
1540
1536
|
return !0;
|
|
1541
1537
|
}
|
|
1542
|
-
function
|
|
1538
|
+
function Mt(e, t) {
|
|
1543
1539
|
var n, i = e.tag, r = e.anchor, o = [], a, l = !1, s;
|
|
1544
1540
|
if (e.firstTabInLine !== -1) return !1;
|
|
1545
1541
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = o), s = e.input.charCodeAt(e.position); s !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, w(e, "tab characters must not be used in indentation")), !(s !== 45 || (a = e.input.charCodeAt(e.position + 1), !ae(a)))); ) {
|
|
@@ -1555,11 +1551,11 @@ function Ft(e, t) {
|
|
|
1555
1551
|
return l ? (e.tag = i, e.anchor = r, e.kind = "sequence", e.result = o, !0) : !1;
|
|
1556
1552
|
}
|
|
1557
1553
|
function na(e, t, n) {
|
|
1558
|
-
var i, r, o, a, l, s, u = e.tag, d = e.anchor, c = {}, f = /* @__PURE__ */ Object.create(null), p = null, b = null,
|
|
1554
|
+
var i, r, o, a, l, s, u = e.tag, d = e.anchor, c = {}, f = /* @__PURE__ */ Object.create(null), p = null, b = null, _ = null, S = !1, j = !1, y;
|
|
1559
1555
|
if (e.firstTabInLine !== -1) return !1;
|
|
1560
1556
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = c), y = e.input.charCodeAt(e.position); y !== 0; ) {
|
|
1561
1557
|
if (!S && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, w(e, "tab characters must not be used in indentation")), i = e.input.charCodeAt(e.position + 1), o = e.line, (y === 63 || y === 58) && ae(i))
|
|
1562
|
-
y === 63 ? (S && (_e(e, c, f, p, b, null, a, l, s), p = b =
|
|
1558
|
+
y === 63 ? (S && (_e(e, c, f, p, b, null, a, l, s), p = b = _ = null), j = !0, S = !0, r = !0) : S ? (S = !1, r = !0) : w(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, y = i;
|
|
1563
1559
|
else {
|
|
1564
1560
|
if (a = e.line, l = e.lineStart, s = e.position, !Ne(e, n, xn, !1, !0))
|
|
1565
1561
|
break;
|
|
@@ -1567,7 +1563,7 @@ function na(e, t, n) {
|
|
|
1567
1563
|
for (y = e.input.charCodeAt(e.position); ke(y); )
|
|
1568
1564
|
y = e.input.charCodeAt(++e.position);
|
|
1569
1565
|
if (y === 58)
|
|
1570
|
-
y = e.input.charCodeAt(++e.position), ae(y) || w(e, "a whitespace character is expected after the key-value separator within a block mapping"), S && (_e(e, c, f, p, b, null, a, l, s), p = b =
|
|
1566
|
+
y = e.input.charCodeAt(++e.position), ae(y) || w(e, "a whitespace character is expected after the key-value separator within a block mapping"), S && (_e(e, c, f, p, b, null, a, l, s), p = b = _ = null), j = !0, S = !1, r = !1, p = e.tag, b = e.result;
|
|
1571
1567
|
else if (j)
|
|
1572
1568
|
w(e, "can not read an implicit mapping pair; a colon is missed");
|
|
1573
1569
|
else
|
|
@@ -1577,7 +1573,7 @@ function na(e, t, n) {
|
|
|
1577
1573
|
else
|
|
1578
1574
|
return e.tag = u, e.anchor = d, !0;
|
|
1579
1575
|
}
|
|
1580
|
-
if ((e.line === o || e.lineIndent > t) && (S && (a = e.line, l = e.lineStart, s = e.position), Ne(e, t, ze, !0, r) && (S ? b = e.result :
|
|
1576
|
+
if ((e.line === o || e.lineIndent > t) && (S && (a = e.line, l = e.lineStart, s = e.position), Ne(e, t, ze, !0, r) && (S ? b = e.result : _ = e.result), S || (_e(e, c, f, p, b, _, a, l, s), p = b = _ = null), Y(e, !0, -1), y = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > t) && y !== 0)
|
|
1581
1577
|
w(e, "bad indentation of a mapping entry");
|
|
1582
1578
|
else if (e.lineIndent < t)
|
|
1583
1579
|
break;
|
|
@@ -1620,11 +1616,11 @@ function aa(e) {
|
|
|
1620
1616
|
return e.position === t && w(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position), ye.call(e.anchorMap, n) || w(e, 'unidentified alias "' + n + '"'), e.result = e.anchorMap[n], Y(e, !0, -1), !0;
|
|
1621
1617
|
}
|
|
1622
1618
|
function Ne(e, t, n, i, r) {
|
|
1623
|
-
var o, a, l, s = 1, u = !1, d = !1, c, f, p, b,
|
|
1619
|
+
var o, a, l, s = 1, u = !1, d = !1, c, f, p, b, _, S;
|
|
1624
1620
|
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = a = l = ze === n || In === n, i && Y(e, !0, -1) && (u = !0, e.lineIndent > t ? s = 1 : e.lineIndent === t ? s = 0 : e.lineIndent < t && (s = -1)), s === 1)
|
|
1625
1621
|
for (; ia(e) || ra(e); )
|
|
1626
1622
|
Y(e, !0, -1) ? (u = !0, l = o, e.lineIndent > t ? s = 1 : e.lineIndent === t ? s = 0 : e.lineIndent < t && (s = -1)) : l = !1;
|
|
1627
|
-
if (l && (l = u || r), (s === 1 || ze === n) && (De === n || xn === n ?
|
|
1623
|
+
if (l && (l = u || r), (s === 1 || ze === n) && (De === n || xn === n ? _ = t : _ = t + 1, S = e.position - e.lineStart, s === 1 ? l && (Mt(e, S) || na(e, S, _)) || ea(e, _) ? d = !0 : (a && ta(e, _) || Qr(e, _) || Xr(e, _) ? d = !0 : aa(e) ? (d = !0, (e.tag !== null || e.anchor !== null) && w(e, "alias node should not have any properties")) : Gr(e, _, De === n) && (d = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : s === 0 && (d = l && Mt(e, S))), e.tag === null)
|
|
1628
1624
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1629
1625
|
else if (e.tag === "?") {
|
|
1630
1626
|
for (e.result !== null && e.kind !== "scalar" && w(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), c = 0, f = e.implicitTypes.length; c < f; c += 1)
|
|
@@ -1701,10 +1697,10 @@ function sa(e, t) {
|
|
|
1701
1697
|
throw new re("expected a single document in the stream, but found more");
|
|
1702
1698
|
}
|
|
1703
1699
|
}
|
|
1704
|
-
var ca = la, ua = sa,
|
|
1700
|
+
var ca = la, ua = sa, Mn = {
|
|
1705
1701
|
loadAll: ca,
|
|
1706
1702
|
load: ua
|
|
1707
|
-
},
|
|
1703
|
+
}, Fn = Object.prototype.toString, $n = Object.prototype.hasOwnProperty, mt = 65279, da = 9, qe = 10, pa = 13, fa = 32, ga = 33, ha = 34, at = 35, ma = 37, ya = 38, va = 39, ba = 42, En = 44, wa = 45, Ye = 58, ka = 61, Ca = 62, Sa = 63, xa = 64, qn = 91, Ln = 93, Ia = 96, Rn = 123, Aa = 124, Un = 125, ne = {};
|
|
1708
1704
|
ne[0] = "\\0";
|
|
1709
1705
|
ne[7] = "\\a";
|
|
1710
1706
|
ne[8] = "\\b";
|
|
@@ -1758,10 +1754,10 @@ function ja(e) {
|
|
|
1758
1754
|
return "\\" + n + J.repeat("0", i - t.length) + t;
|
|
1759
1755
|
}
|
|
1760
1756
|
var Oa = 1, Le = 2;
|
|
1761
|
-
function
|
|
1757
|
+
function Ma(e) {
|
|
1762
1758
|
this.schema = e.schema || ft, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = J.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = Ta(this.schema, e.styles || null), this.sortKeys = e.sortKeys || !1, this.lineWidth = e.lineWidth || 80, this.noRefs = e.noRefs || !1, this.noCompatMode = e.noCompatMode || !1, this.condenseFlow = e.condenseFlow || !1, this.quotingType = e.quotingType === '"' ? Le : Oa, this.forceQuotes = e.forceQuotes || !1, this.replacer = typeof e.replacer == "function" ? e.replacer : null, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null;
|
|
1763
1759
|
}
|
|
1764
|
-
function
|
|
1760
|
+
function Ft(e, t) {
|
|
1765
1761
|
for (var n = J.repeat(" ", t), i = 0, r = -1, o = "", a, l = e.length; i < l; )
|
|
1766
1762
|
r = e.indexOf(`
|
|
1767
1763
|
`, i), r === -1 ? (a = e.slice(i), i = l) : (a = e.slice(i, r + 1), i = r + 1), a.length && a !== `
|
|
@@ -1772,7 +1768,7 @@ function ot(e, t) {
|
|
|
1772
1768
|
return `
|
|
1773
1769
|
` + J.repeat(" ", e.indent * t);
|
|
1774
1770
|
}
|
|
1775
|
-
function
|
|
1771
|
+
function Fa(e, t) {
|
|
1776
1772
|
var n, i, r;
|
|
1777
1773
|
for (n = 0, i = e.implicitTypes.length; n < i; n += 1)
|
|
1778
1774
|
if (r = e.implicitTypes[n], r.resolve(t))
|
|
@@ -1804,7 +1800,7 @@ function $a(e) {
|
|
|
1804
1800
|
function Ea(e) {
|
|
1805
1801
|
return !We(e) && e !== Ye;
|
|
1806
1802
|
}
|
|
1807
|
-
function
|
|
1803
|
+
function Fe(e, t) {
|
|
1808
1804
|
var n = e.charCodeAt(t), i;
|
|
1809
1805
|
return n >= 55296 && n <= 56319 && t + 1 < e.length && (i = e.charCodeAt(t + 1), i >= 56320 && i <= 57343) ? (n - 55296) * 1024 + i - 56320 + 65536 : n;
|
|
1810
1806
|
}
|
|
@@ -1814,25 +1810,25 @@ function Bn(e) {
|
|
|
1814
1810
|
}
|
|
1815
1811
|
var Kn = 1, lt = 2, Vn = 3, Pn = 4, Ie = 5;
|
|
1816
1812
|
function qa(e, t, n, i, r, o, a, l) {
|
|
1817
|
-
var s, u = 0, d = null, c = !1, f = !1, p = i !== -1, b = -1,
|
|
1813
|
+
var s, u = 0, d = null, c = !1, f = !1, p = i !== -1, b = -1, _ = $a(Fe(e, 0)) && Ea(Fe(e, e.length - 1));
|
|
1818
1814
|
if (t || a)
|
|
1819
1815
|
for (s = 0; s < e.length; u >= 65536 ? s += 2 : s++) {
|
|
1820
|
-
if (u =
|
|
1816
|
+
if (u = Fe(e, s), !Re(u))
|
|
1821
1817
|
return Ie;
|
|
1822
|
-
|
|
1818
|
+
_ = _ && Et(u, d, l), d = u;
|
|
1823
1819
|
}
|
|
1824
1820
|
else {
|
|
1825
1821
|
for (s = 0; s < e.length; u >= 65536 ? s += 2 : s++) {
|
|
1826
|
-
if (u =
|
|
1822
|
+
if (u = Fe(e, s), u === qe)
|
|
1827
1823
|
c = !0, p && (f = f || // Foldable line = too long, and not more-indented.
|
|
1828
1824
|
s - b - 1 > i && e[b + 1] !== " ", b = s);
|
|
1829
1825
|
else if (!Re(u))
|
|
1830
1826
|
return Ie;
|
|
1831
|
-
|
|
1827
|
+
_ = _ && Et(u, d, l), d = u;
|
|
1832
1828
|
}
|
|
1833
1829
|
f = f || p && s - b - 1 > i && e[b + 1] !== " ";
|
|
1834
1830
|
}
|
|
1835
|
-
return !c && !f ?
|
|
1831
|
+
return !c && !f ? _ && !a && !r(e) ? Kn : o === Le ? Ie : lt : n > 9 && Bn(e) ? Ie : a ? o === Le ? Ie : lt : f ? Pn : Vn;
|
|
1836
1832
|
}
|
|
1837
1833
|
function La(e, t, n, i, r) {
|
|
1838
1834
|
e.dump = function() {
|
|
@@ -1842,7 +1838,7 @@ function La(e, t, n, i, r) {
|
|
|
1842
1838
|
return e.quotingType === Le ? '"' + t + '"' : "'" + t + "'";
|
|
1843
1839
|
var o = e.indent * Math.max(1, n), a = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - o), l = i || e.flowLevel > -1 && n >= e.flowLevel;
|
|
1844
1840
|
function s(u) {
|
|
1845
|
-
return
|
|
1841
|
+
return Fa(e, u);
|
|
1846
1842
|
}
|
|
1847
1843
|
switch (qa(
|
|
1848
1844
|
t,
|
|
@@ -1859,9 +1855,9 @@ function La(e, t, n, i, r) {
|
|
|
1859
1855
|
case lt:
|
|
1860
1856
|
return "'" + t.replace(/'/g, "''") + "'";
|
|
1861
1857
|
case Vn:
|
|
1862
|
-
return "|" + qt(t, e.indent) + Lt(
|
|
1858
|
+
return "|" + qt(t, e.indent) + Lt(Ft(t, o));
|
|
1863
1859
|
case Pn:
|
|
1864
|
-
return ">" + qt(t, e.indent) + Lt(
|
|
1860
|
+
return ">" + qt(t, e.indent) + Lt(Ft(Ra(t, a), o));
|
|
1865
1861
|
case Ie:
|
|
1866
1862
|
return '"' + Ua(t) + '"';
|
|
1867
1863
|
default:
|
|
@@ -1905,7 +1901,7 @@ function Rt(e, t) {
|
|
|
1905
1901
|
}
|
|
1906
1902
|
function Ua(e) {
|
|
1907
1903
|
for (var t = "", n = 0, i, r = 0; r < e.length; n >= 65536 ? r += 2 : r++)
|
|
1908
|
-
n =
|
|
1904
|
+
n = Fe(e, r), i = ne[n], !i && Re(n) ? (t += e[r], n >= 65536 && (t += e[r + 1])) : t += i || ja(n);
|
|
1909
1905
|
return t;
|
|
1910
1906
|
}
|
|
1911
1907
|
function Ba(e, t, n) {
|
|
@@ -1943,7 +1939,7 @@ function Bt(e, t, n) {
|
|
|
1943
1939
|
for (r = n ? e.explicitTypes : e.implicitTypes, o = 0, a = r.length; o < a; o += 1)
|
|
1944
1940
|
if (l = r[o], (l.instanceOf || l.predicate) && (!l.instanceOf || typeof t == "object" && t instanceof l.instanceOf) && (!l.predicate || l.predicate(t))) {
|
|
1945
1941
|
if (n ? l.multi && l.representName ? e.tag = l.representName(t) : e.tag = l.tag : e.tag = "?", l.represent) {
|
|
1946
|
-
if (s = e.styleMap[l.tag] || l.defaultStyle,
|
|
1942
|
+
if (s = e.styleMap[l.tag] || l.defaultStyle, Fn.call(l.represent) === "[object Function]")
|
|
1947
1943
|
i = l.represent(t, s);
|
|
1948
1944
|
else if ($n.call(l.represent, s))
|
|
1949
1945
|
i = l.represent[s](t, s);
|
|
@@ -1957,7 +1953,7 @@ function Bt(e, t, n) {
|
|
|
1957
1953
|
}
|
|
1958
1954
|
function de(e, t, n, i, r, o, a) {
|
|
1959
1955
|
e.tag = null, e.dump = n, Bt(e, n, !1) || Bt(e, n, !0);
|
|
1960
|
-
var l =
|
|
1956
|
+
var l = Fn.call(e.dump), s = i, u;
|
|
1961
1957
|
i && (i = e.flowLevel < 0 || e.flowLevel > t);
|
|
1962
1958
|
var d = l === "[object Object]" || l === "[object Array]", c, f;
|
|
1963
1959
|
if (d && (c = e.duplicates.indexOf(n), f = c !== -1), (e.tag !== null && e.tag !== "?" || f || e.indent !== 2 && t > 0) && (r = !1), f && e.usedDuplicates[c])
|
|
@@ -1999,7 +1995,7 @@ function st(e, t, n) {
|
|
|
1999
1995
|
}
|
|
2000
1996
|
function Da(e, t) {
|
|
2001
1997
|
t = t || {};
|
|
2002
|
-
var n = new
|
|
1998
|
+
var n = new Ma(t);
|
|
2003
1999
|
n.noRefs || Pa(e, n);
|
|
2004
2000
|
var i = e;
|
|
2005
2001
|
return n.replacer && (i = n.replacer.call({ "": i }, "", i)), de(n, 0, i, !0, !0) ? n.dump + `
|
|
@@ -2013,7 +2009,7 @@ function yt(e, t) {
|
|
|
2013
2009
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.");
|
|
2014
2010
|
};
|
|
2015
2011
|
}
|
|
2016
|
-
var Ya = ee, Wa = an, Ja = cn, Za = gn, Ga = hn, Qa = ft, Xa =
|
|
2012
|
+
var Ya = ee, Wa = an, Ja = cn, Za = gn, Ga = hn, Qa = ft, Xa = Mn.load, eo = Mn.loadAll, to = Ha.dump, no = re, io = {
|
|
2017
2013
|
binary: wn,
|
|
2018
2014
|
float: fn,
|
|
2019
2015
|
map: sn,
|
|
@@ -2378,10 +2374,10 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2378
2374
|
}), No = /* @__PURE__ */ Ge(_o, [["__scopeId", "data-v-863d10eb"]]), To = (e) => (Be("data-v-d9894a05"), e = e(), Ke(), e), jo = ["aria-hidden"], Oo = {
|
|
2379
2375
|
key: 0,
|
|
2380
2376
|
"data-testid": "kui-icon-svg-title"
|
|
2381
|
-
},
|
|
2377
|
+
}, Mo = /* @__PURE__ */ To(() => /* @__PURE__ */ L("path", {
|
|
2382
2378
|
d: "M12 20C11.45 20 10.9792 19.8042 10.5875 19.4125C10.1958 19.0208 10 18.55 10 18C10 17.45 10.1958 16.9792 10.5875 16.5875C10.9792 16.1958 11.45 16 12 16C12.55 16 13.0208 16.1958 13.4125 16.5875C13.8042 16.9792 14 17.45 14 18C14 18.55 13.8042 19.0208 13.4125 19.4125C13.0208 19.8042 12.55 20 12 20ZM12 14C11.45 14 10.9792 13.8042 10.5875 13.4125C10.1958 13.0208 10 12.55 10 12C10 11.45 10.1958 10.9792 10.5875 10.5875C10.9792 10.1958 11.45 10 12 10C12.55 10 13.0208 10.1958 13.4125 10.5875C13.8042 10.9792 14 11.45 14 12C14 12.55 13.8042 13.0208 13.4125 13.4125C13.0208 13.8042 12.55 14 12 14ZM12 8C11.45 8 10.9792 7.80417 10.5875 7.4125C10.1958 7.02083 10 6.55 10 6C10 5.45 10.1958 4.97917 10.5875 4.5875C10.9792 4.19583 11.45 4 12 4C12.55 4 13.0208 4.19583 13.4125 4.5875C13.8042 4.97917 14 5.45 14 6C14 6.55 13.8042 7.02083 13.4125 7.4125C13.0208 7.80417 12.55 8 12 8Z",
|
|
2383
2379
|
fill: "currentColor"
|
|
2384
|
-
}, null, -1)),
|
|
2380
|
+
}, null, -1)), Fo = /* @__PURE__ */ te({
|
|
2385
2381
|
__name: "MoreIcon",
|
|
2386
2382
|
props: {
|
|
2387
2383
|
/** The accessibility text provided to screen readers */
|
|
@@ -2469,13 +2465,13 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2469
2465
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2470
2466
|
}, [
|
|
2471
2467
|
e.title ? (k(), q("title", Oo, E(e.title), 1)) : Q("", !0),
|
|
2472
|
-
|
|
2468
|
+
Mo
|
|
2473
2469
|
], 8, jo))
|
|
2474
2470
|
]),
|
|
2475
2471
|
_: 1
|
|
2476
2472
|
}, 8, ["aria-hidden", "style"]));
|
|
2477
2473
|
}
|
|
2478
|
-
}), $o = /* @__PURE__ */ Ge(
|
|
2474
|
+
}), $o = /* @__PURE__ */ Ge(Fo, [["__scopeId", "data-v-d9894a05"]]), Eo = ["novalidate"], qo = {
|
|
2479
2475
|
class: "form-actions",
|
|
2480
2476
|
"data-testid": "form-actions"
|
|
2481
2477
|
}, Lo = /* @__PURE__ */ te({
|
|
@@ -2547,11 +2543,11 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2547
2543
|
emits: ["loading", "fetch:success", "fetch:error", "submit", "cancel"],
|
|
2548
2544
|
setup(e, { emit: t }) {
|
|
2549
2545
|
var n;
|
|
2550
|
-
const i = t, r = e, o = Jt(), { i18n: { t: a } } = we.useI18n(), { getMessageFromError: l } = we.useErrors(), { axiosInstance: s } = we.useAxios((n = r.config) == null ? void 0 : n.axiosRequestConfig), u =
|
|
2546
|
+
const i = t, r = e, o = Jt(), { i18n: { t: a } } = we.useI18n(), { getMessageFromError: l } = we.useErrors(), { axiosInstance: s } = we.useAxios((n = r.config) == null ? void 0 : n.axiosRequestConfig), u = F(!1), d = F(!1), c = F(""), f = I(() => r.canSubmit === !1 || r.isReadonly), p = F(!1), b = I(() => {
|
|
2551
2547
|
var C, O;
|
|
2552
2548
|
let g = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
2553
2549
|
return r.config.app === "konnect" ? g = g.replace(/{controlPlaneId}/gi, ((C = r.config) == null ? void 0 : C.controlPlaneId) || "") : r.config.app === "kongManager" && (g = g.replace(/\/{workspace}/gi, (O = r.config) != null && O.workspace ? `/${r.config.workspace}` : "")), r.editId ? (g = g.replace(/{id}/gi, r.editId), g) : (g = g.replace(/\/{id}/gi, ""), g);
|
|
2554
|
-
}),
|
|
2550
|
+
}), _ = () => {
|
|
2555
2551
|
p.value = !p.value;
|
|
2556
2552
|
}, S = () => {
|
|
2557
2553
|
r.config.cancelRoute ? o.push(r.config.cancelRoute) : j();
|
|
@@ -2559,7 +2555,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2559
2555
|
i("cancel");
|
|
2560
2556
|
}, y = () => {
|
|
2561
2557
|
f.value || i("submit");
|
|
2562
|
-
},
|
|
2558
|
+
}, N = F([
|
|
2563
2559
|
{
|
|
2564
2560
|
title: a("baseForm.configuration.yaml"),
|
|
2565
2561
|
hash: "#yaml"
|
|
@@ -2584,7 +2580,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2584
2580
|
u.value = !1;
|
|
2585
2581
|
}
|
|
2586
2582
|
}), (C, O) => {
|
|
2587
|
-
const g = U("KSkeleton"), m = U("KEmptyState"), R = U("KAlert"),
|
|
2583
|
+
const g = U("KSkeleton"), m = U("KEmptyState"), R = U("KAlert"), M = U("KButton"), B = U("KTabs"), Z = U("KSlideout");
|
|
2588
2584
|
return k(), P(Ce(e.wrapperComponent), { class: "kong-ui-entity-base-form" }, {
|
|
2589
2585
|
default: v(() => [
|
|
2590
2586
|
u.value ? (k(), P(g, {
|
|
@@ -2617,17 +2613,17 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2617
2613
|
}, null, 8, ["message"])) : Q("", !0),
|
|
2618
2614
|
L("div", qo, [
|
|
2619
2615
|
oe(C.$slots, "form-actions", {}, () => [
|
|
2620
|
-
A(
|
|
2616
|
+
A(M, {
|
|
2621
2617
|
appearance: "tertiary",
|
|
2622
2618
|
"data-testid": "form-view-configuration",
|
|
2623
|
-
onClick: O[0] || (O[0] = (K) =>
|
|
2619
|
+
onClick: O[0] || (O[0] = (K) => _())
|
|
2624
2620
|
}, {
|
|
2625
2621
|
default: v(() => [
|
|
2626
2622
|
G(E(h(a)("baseForm.actions.viewConfiguration")), 1)
|
|
2627
2623
|
]),
|
|
2628
2624
|
_: 1
|
|
2629
2625
|
}),
|
|
2630
|
-
A(
|
|
2626
|
+
A(M, {
|
|
2631
2627
|
appearance: "secondary",
|
|
2632
2628
|
"data-testid": "form-cancel",
|
|
2633
2629
|
disabled: e.isReadonly,
|
|
@@ -2638,7 +2634,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2638
2634
|
]),
|
|
2639
2635
|
_: 1
|
|
2640
2636
|
}, 8, ["disabled"]),
|
|
2641
|
-
A(
|
|
2637
|
+
A(M, {
|
|
2642
2638
|
appearance: "primary",
|
|
2643
2639
|
"data-testid": "form-submit",
|
|
2644
2640
|
disabled: f.value,
|
|
@@ -2659,13 +2655,13 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2659
2655
|
"offset-top": 60,
|
|
2660
2656
|
title: h(a)("baseForm.configuration.title"),
|
|
2661
2657
|
visible: p.value,
|
|
2662
|
-
onClose: O[1] || (O[1] = (K) =>
|
|
2658
|
+
onClose: O[1] || (O[1] = (K) => _())
|
|
2663
2659
|
}, {
|
|
2664
2660
|
default: v(() => [
|
|
2665
2661
|
L("div", null, E(h(a)("baseForm.configuration.message")), 1),
|
|
2666
2662
|
A(B, {
|
|
2667
2663
|
"data-testid": "form-view-configuration-slideout-tabs",
|
|
2668
|
-
tabs:
|
|
2664
|
+
tabs: N.value
|
|
2669
2665
|
}, {
|
|
2670
2666
|
json: v(() => [
|
|
2671
2667
|
A(Ki, {
|
|
@@ -2723,13 +2719,13 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2723
2719
|
a && (a.disconnect(), a = void 0);
|
|
2724
2720
|
}, s = () => {
|
|
2725
2721
|
var S, j, y;
|
|
2726
|
-
let
|
|
2722
|
+
let N = ((S = n.value) == null ? void 0 : S.clientWidth) || 0;
|
|
2727
2723
|
if (n.value && "getComputedStyle" in window) {
|
|
2728
2724
|
const C = window.getComputedStyle(n.value);
|
|
2729
|
-
|
|
2725
|
+
N -= (parseFloat(C.paddingLeft) || 0) + (parseFloat(C.paddingRight) || 0);
|
|
2730
2726
|
}
|
|
2731
|
-
d.value = ((j = i.value) == null ? void 0 : j.getBoundingClientRect().width) || 0, c.value =
|
|
2732
|
-
}, u =
|
|
2727
|
+
d.value = ((j = i.value) == null ? void 0 : j.getBoundingClientRect().width) || 0, c.value = N, f.value = ((y = u.value) == null ? void 0 : y.innerText) || "";
|
|
2728
|
+
}, u = F({}), d = F(0), c = F(0), f = F(""), p = I(() => [i.value, n.value]), b = me(
|
|
2733
2729
|
p,
|
|
2734
2730
|
(S) => {
|
|
2735
2731
|
if (o.value && (l(), "ResizeObserver" in window && window)) {
|
|
@@ -2743,7 +2739,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2743
2739
|
}
|
|
2744
2740
|
},
|
|
2745
2741
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
2746
|
-
),
|
|
2742
|
+
), _ = I(() => o.value ? d.value > c.value : !1);
|
|
2747
2743
|
return Gn(() => {
|
|
2748
2744
|
s();
|
|
2749
2745
|
}), Qn(() => {
|
|
@@ -2762,7 +2758,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2762
2758
|
A(y, {
|
|
2763
2759
|
"max-width": "300",
|
|
2764
2760
|
placement: "bottom-start",
|
|
2765
|
-
text:
|
|
2761
|
+
text: _.value ? f.value : ""
|
|
2766
2762
|
}, {
|
|
2767
2763
|
default: v(() => [
|
|
2768
2764
|
oe(S.$slots, "default", {}, void 0, !0)
|
|
@@ -2923,7 +2919,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2923
2919
|
"data-rowid": g.id,
|
|
2924
2920
|
"data-testid": g.name,
|
|
2925
2921
|
...n.rowAttributes(g)
|
|
2926
|
-
}), d =
|
|
2922
|
+
}), d = F({}), c = (g) => {
|
|
2927
2923
|
var m;
|
|
2928
2924
|
return (m = d.value) == null ? void 0 : m.$el.querySelector(`[data-rowid="${g.id}"]`);
|
|
2929
2925
|
}, f = (g) => {
|
|
@@ -2940,23 +2936,23 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2940
2936
|
i("empty-state-cta-clicked"), b();
|
|
2941
2937
|
}, b = () => {
|
|
2942
2938
|
i("clear-search-input");
|
|
2943
|
-
},
|
|
2939
|
+
}, _ = I(() => n.disableRowClick ? void 0 : (g, m) => {
|
|
2944
2940
|
i("click:row", m);
|
|
2945
2941
|
}), S = (g) => {
|
|
2946
2942
|
i("sort", g);
|
|
2947
|
-
}, { setTablePreferences: j, getTablePreferences: y } = di(),
|
|
2943
|
+
}, { setTablePreferences: j, getTablePreferences: y } = di(), N = F(y(a.value)), C = I(() => {
|
|
2948
2944
|
const g = y(a.value);
|
|
2949
2945
|
return {
|
|
2950
2946
|
...n.initialFetcherParams,
|
|
2951
2947
|
...g
|
|
2952
2948
|
};
|
|
2953
2949
|
}), O = (g) => {
|
|
2954
|
-
|
|
2955
|
-
!("hidable" in m) || !
|
|
2950
|
+
N.value = g, s.value.forEach((m) => {
|
|
2951
|
+
!("hidable" in m) || !N.value.columnVisibility || m.hidable === !1 && (N.value.columnVisibility[m.key] = !0);
|
|
2956
2952
|
}), a.value && j(a.value, g);
|
|
2957
2953
|
};
|
|
2958
2954
|
return (g, m) => {
|
|
2959
|
-
const R = U("KButton"),
|
|
2955
|
+
const R = U("KButton"), M = U("KDropdown"), B = U("KTable"), Z = U("KCard");
|
|
2960
2956
|
return k(), P(Z, {
|
|
2961
2957
|
class: "kong-ui-entity-base-table",
|
|
2962
2958
|
title: e.title,
|
|
@@ -2990,9 +2986,9 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
2990
2986
|
"search-input": e.query,
|
|
2991
2987
|
"sort-handler-function": e.enableClientSort ? e.sortHandlerFunction : void 0,
|
|
2992
2988
|
sortable: !e.disableSorting,
|
|
2993
|
-
"table-preferences":
|
|
2989
|
+
"table-preferences": N.value,
|
|
2994
2990
|
onEmptyStateActionClick: p,
|
|
2995
|
-
"onRow:click":
|
|
2991
|
+
"onRow:click": _.value,
|
|
2996
2992
|
onSort: m[0] || (m[0] = (K) => S(K)),
|
|
2997
2993
|
"onUpdate:tablePreferences": O
|
|
2998
2994
|
}, zt({
|
|
@@ -3011,7 +3007,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3011
3007
|
class: "actions-container",
|
|
3012
3008
|
"data-testid": K.name
|
|
3013
3009
|
}, [
|
|
3014
|
-
A(
|
|
3010
|
+
A(M, {
|
|
3015
3011
|
"kpop-attributes": { placement: "bottom-end" },
|
|
3016
3012
|
width: e.dropdownMenuWidth
|
|
3017
3013
|
}, {
|
|
@@ -3238,7 +3234,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3238
3234
|
},
|
|
3239
3235
|
emits: ["update:modelValue"],
|
|
3240
3236
|
setup(e, { emit: t }) {
|
|
3241
|
-
const { i18n: { t: n } } = we.useI18n(), i = e, r = t, o =
|
|
3237
|
+
const { i18n: { t: n } } = we.useI18n(), i = e, r = t, o = F(!1), a = F({}), l = F(/* @__PURE__ */ new Set()), s = I(() => {
|
|
3242
3238
|
const C = [];
|
|
3243
3239
|
return new URLSearchParams(i.modelValue).forEach((O, g) => {
|
|
3244
3240
|
O !== "" && C.push(g);
|
|
@@ -3267,7 +3263,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3267
3263
|
r("update:modelValue", C);
|
|
3268
3264
|
}, p = () => {
|
|
3269
3265
|
f("");
|
|
3270
|
-
}, b = (C) => `filter-${C}`,
|
|
3266
|
+
}, b = (C) => `filter-${C}`, _ = (C) => {
|
|
3271
3267
|
var O, g;
|
|
3272
3268
|
return (((g = (O = i.config.schema) == null ? void 0 : O[C]) == null ? void 0 : g.values) ?? []).map((m) => ({
|
|
3273
3269
|
value: m,
|
|
@@ -3280,10 +3276,10 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3280
3276
|
a.value = {
|
|
3281
3277
|
...a.value,
|
|
3282
3278
|
[C]: ""
|
|
3283
|
-
},
|
|
3279
|
+
}, N();
|
|
3284
3280
|
}, y = () => {
|
|
3285
|
-
a.value = {},
|
|
3286
|
-
},
|
|
3281
|
+
a.value = {}, N(!0);
|
|
3282
|
+
}, N = (C = !1) => {
|
|
3287
3283
|
const O = Object.keys(a.value).reduce((g, m) => (a.value[m] && (g[m] = `${a.value[m]}`), g), {});
|
|
3288
3284
|
C && (o.value = !1), r("update:modelValue", new URLSearchParams(O).toString());
|
|
3289
3285
|
};
|
|
@@ -3329,59 +3325,59 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3329
3325
|
[ge, o.value]
|
|
3330
3326
|
]),
|
|
3331
3327
|
fe(L("div", il, [
|
|
3332
|
-
(k(!0), q(Ht, null, ut(u.value, (
|
|
3328
|
+
(k(!0), q(Ht, null, ut(u.value, (M) => {
|
|
3333
3329
|
var B, Z;
|
|
3334
3330
|
return k(), q("div", {
|
|
3335
|
-
key:
|
|
3331
|
+
key: M.value,
|
|
3336
3332
|
class: "kong-ui-entity-filter-menu-item",
|
|
3337
|
-
"data-testid":
|
|
3333
|
+
"data-testid": M.value
|
|
3338
3334
|
}, [
|
|
3339
3335
|
L("span", {
|
|
3340
|
-
class: $e(["menu-item-title", { expanded: l.value.has(
|
|
3336
|
+
class: $e(["menu-item-title", { expanded: l.value.has(M.value) }]),
|
|
3341
3337
|
role: "button",
|
|
3342
3338
|
tabindex: "0",
|
|
3343
|
-
onClick: (K) => c(
|
|
3344
|
-
onKeydown: Yn((K) => c(
|
|
3339
|
+
onClick: (K) => c(M.value),
|
|
3340
|
+
onKeydown: Yn((K) => c(M.value), ["enter"])
|
|
3345
3341
|
}, [
|
|
3346
|
-
G(E(
|
|
3342
|
+
G(E(M.label) + " ", 1),
|
|
3347
3343
|
fe(L("span", ol, null, 512), [
|
|
3348
|
-
[ge, s.value.includes(
|
|
3344
|
+
[ge, s.value.includes(M.value)]
|
|
3349
3345
|
]),
|
|
3350
3346
|
A(h(Co), {
|
|
3351
|
-
class: $e(["menu-item-expand-icon", { expanded: l.value.has(
|
|
3347
|
+
class: $e(["menu-item-expand-icon", { expanded: l.value.has(M.value) }]),
|
|
3352
3348
|
color: h(Ri)
|
|
3353
3349
|
}, null, 8, ["class", "color"])
|
|
3354
3350
|
], 42, al),
|
|
3355
3351
|
fe(L("div", ll, [
|
|
3356
3352
|
L("label", {
|
|
3357
3353
|
class: "menu-item-label",
|
|
3358
|
-
for: b(
|
|
3354
|
+
for: b(M.value)
|
|
3359
3355
|
}, E(h(n)("filter.fieldLabel")), 9, sl),
|
|
3360
|
-
((Z = (B = e.config.schema) == null ? void 0 : B[
|
|
3356
|
+
((Z = (B = e.config.schema) == null ? void 0 : B[M.value]) == null ? void 0 : Z.type) === "select" ? (k(), P(R, {
|
|
3361
3357
|
key: 0,
|
|
3362
|
-
id: b(
|
|
3363
|
-
modelValue: a.value[
|
|
3364
|
-
"onUpdate:modelValue": (K) => a.value[
|
|
3365
|
-
items:
|
|
3358
|
+
id: b(M.value),
|
|
3359
|
+
modelValue: a.value[M.value],
|
|
3360
|
+
"onUpdate:modelValue": (K) => a.value[M.value] = K,
|
|
3361
|
+
items: _(M.value),
|
|
3366
3362
|
placeholder: h(n)("filter.selectPlaceholder")
|
|
3367
3363
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (k(), P(g, {
|
|
3368
3364
|
key: 1,
|
|
3369
|
-
id: b(
|
|
3370
|
-
modelValue: a.value[
|
|
3371
|
-
"onUpdate:modelValue": (K) => a.value[
|
|
3365
|
+
id: b(M.value),
|
|
3366
|
+
modelValue: a.value[M.value],
|
|
3367
|
+
"onUpdate:modelValue": (K) => a.value[M.value] = K,
|
|
3372
3368
|
autocomplete: "off",
|
|
3373
3369
|
placeholder: h(n)("filter.inputPlaceholder"),
|
|
3374
|
-
type: S(
|
|
3370
|
+
type: S(M.value)
|
|
3375
3371
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3376
3372
|
], 512), [
|
|
3377
|
-
[ge, l.value.has(
|
|
3373
|
+
[ge, l.value.has(M.value)]
|
|
3378
3374
|
]),
|
|
3379
3375
|
fe(L("div", cl, [
|
|
3380
3376
|
A(m, {
|
|
3381
3377
|
appearance: "tertiary",
|
|
3382
3378
|
"data-testid": "apply-filter",
|
|
3383
3379
|
size: "small",
|
|
3384
|
-
onClick: O[0] || (O[0] = (K) =>
|
|
3380
|
+
onClick: O[0] || (O[0] = (K) => N(!0))
|
|
3385
3381
|
}, {
|
|
3386
3382
|
default: v(() => [
|
|
3387
3383
|
G(E(h(n)("filter.applyButtonText")), 1)
|
|
@@ -3392,7 +3388,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3392
3388
|
appearance: "tertiary",
|
|
3393
3389
|
"data-testid": "clear-filter",
|
|
3394
3390
|
size: "small",
|
|
3395
|
-
onClick: (K) => j(
|
|
3391
|
+
onClick: (K) => j(M.value)
|
|
3396
3392
|
}, {
|
|
3397
3393
|
default: v(() => [
|
|
3398
3394
|
G(E(h(n)("filter.clearButtonText")), 1)
|
|
@@ -3400,7 +3396,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3400
3396
|
_: 2
|
|
3401
3397
|
}, 1032, ["onClick"])
|
|
3402
3398
|
], 512), [
|
|
3403
|
-
[ge, l.value.has(
|
|
3399
|
+
[ge, l.value.has(M.value)]
|
|
3404
3400
|
])
|
|
3405
3401
|
], 8, rl);
|
|
3406
3402
|
}), 128)),
|
|
@@ -3444,7 +3440,7 @@ const so = { class: "yaml-config" }, co = /* @__PURE__ */ te({
|
|
|
3444
3440
|
}
|
|
3445
3441
|
},
|
|
3446
3442
|
setup(e) {
|
|
3447
|
-
const t = e, n =
|
|
3443
|
+
const t = e, n = F(void 0), i = I(() => n.value === !0 || n.value !== void 0 && t.forceShow === !0);
|
|
3448
3444
|
return me(() => t.authFunction, async () => {
|
|
3449
3445
|
n.value = await t.authFunction();
|
|
3450
3446
|
}, { immediate: !0 }), (r, o) => i.value ? oe(r.$slots, "default", {
|
|
@@ -3561,10 +3557,10 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3561
3557
|
}, Tl = (e) => (Be("data-v-c1f7c39c"), e = e(), Ke(), e), jl = ["aria-hidden"], Ol = {
|
|
3562
3558
|
key: 0,
|
|
3563
3559
|
"data-testid": "kui-icon-svg-title"
|
|
3564
|
-
},
|
|
3560
|
+
}, Ml = /* @__PURE__ */ Tl(() => /* @__PURE__ */ L("path", {
|
|
3565
3561
|
d: "M11 19V13H5V11H11V5H13V11H19V13H13V19H11Z",
|
|
3566
3562
|
fill: "currentColor"
|
|
3567
|
-
}, null, -1)),
|
|
3563
|
+
}, null, -1)), Fl = /* @__PURE__ */ te({
|
|
3568
3564
|
__name: "AddIcon",
|
|
3569
3565
|
props: {
|
|
3570
3566
|
/** The accessibility text provided to screen readers */
|
|
@@ -3652,13 +3648,13 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3652
3648
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3653
3649
|
}, [
|
|
3654
3650
|
e.title ? (k(), q("title", Ol, E(e.title), 1)) : Q("", !0),
|
|
3655
|
-
|
|
3651
|
+
Ml
|
|
3656
3652
|
], 8, jl))
|
|
3657
3653
|
]),
|
|
3658
3654
|
_: 1
|
|
3659
3655
|
}, 8, ["aria-hidden", "style"]));
|
|
3660
3656
|
}
|
|
3661
|
-
}), $l = /* @__PURE__ */ Nl(
|
|
3657
|
+
}), $l = /* @__PURE__ */ Nl(Fl, [["__scopeId", "data-v-c1f7c39c"]]), El = { class: "kong-ui-entities-snis-list" }, ql = { key: 1 }, Ll = { key: 1 }, Rl = /* @__PURE__ */ te({
|
|
3662
3658
|
__name: "SniList",
|
|
3663
3659
|
props: {
|
|
3664
3660
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3705,7 +3701,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3705
3701
|
emits: ["error", "copy:success", "copy:error", "delete:success"],
|
|
3706
3702
|
setup(e, { emit: t }) {
|
|
3707
3703
|
var ce;
|
|
3708
|
-
const n = t, i = e, { i18n: { t: r } } = Zt.useI18n(), { axiosInstance: o } = Dn((ce = i.config) == null ? void 0 : ce.axiosRequestConfig), a =
|
|
3704
|
+
const n = t, i = e, { i18n: { t: r } } = Zt.useI18n(), { axiosInstance: o } = Dn((ce = i.config) == null ? void 0 : ce.axiosRequestConfig), a = F(1), l = I(() => i.config.app !== "kongManager" || !!i.config.disableSorting), s = {
|
|
3709
3705
|
// the Name column is non-hidable
|
|
3710
3706
|
name: { label: r("snis.list.table_headers.name"), searchable: !0, sortable: !0, hidable: !1 },
|
|
3711
3707
|
certificate: { label: r("snis.list.table_headers.certificate_id"), sortable: !1 },
|
|
@@ -3716,9 +3712,9 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3716
3712
|
}
|
|
3717
3713
|
}), c = I(() => {
|
|
3718
3714
|
var z, W;
|
|
3719
|
-
let T = `${i.config.apiBaseUrl}${
|
|
3715
|
+
let T = `${i.config.apiBaseUrl}${Me.list[i.config.app].all}`;
|
|
3720
3716
|
return i.config.app === "konnect" ? T = T.replace(/{controlPlaneId}/gi, ((z = i.config) == null ? void 0 : z.controlPlaneId) || "") : i.config.app === "kongManager" && (T = T.replace(/\/{workspace}/gi, (W = i.config) != null && W.workspace ? `/${i.config.workspace}` : "")), T;
|
|
3721
|
-
}), f =
|
|
3717
|
+
}), f = F(""), p = I(() => {
|
|
3722
3718
|
const T = i.config.app === "konnect" || i.config.isExactMatch;
|
|
3723
3719
|
if (T)
|
|
3724
3720
|
return {
|
|
@@ -3731,11 +3727,11 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3731
3727
|
fields: { name: z },
|
|
3732
3728
|
schema: i.config.filterSchema
|
|
3733
3729
|
};
|
|
3734
|
-
}), { fetcher: b, fetcherState:
|
|
3730
|
+
}), { fetcher: b, fetcherState: _ } = Al(i.config, c.value), S = () => {
|
|
3735
3731
|
f.value = "";
|
|
3736
3732
|
}, j = () => {
|
|
3737
3733
|
a.value++;
|
|
3738
|
-
}, y =
|
|
3734
|
+
}, y = F(null), N = F({
|
|
3739
3735
|
ctaPath: i.config.createRoute,
|
|
3740
3736
|
ctaText: void 0,
|
|
3741
3737
|
message: `${r("snis.list.empty_state.description")}${i.config.additionMessageForEmptyState ? ` ${i.config.additionMessageForEmptyState}` : ""}`,
|
|
@@ -3771,24 +3767,24 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3771
3767
|
}, g = (T) => ({
|
|
3772
3768
|
label: r("actions.edit"),
|
|
3773
3769
|
to: i.config.getEditRoute(T)
|
|
3774
|
-
}), m =
|
|
3770
|
+
}), m = F(void 0), R = F(!1), M = F(!1), B = F(""), Z = xl(i.config, c.value), K = (T) => {
|
|
3775
3771
|
m.value = T, R.value = !0;
|
|
3776
3772
|
}, le = () => {
|
|
3777
3773
|
R.value = !1, m.value = void 0;
|
|
3778
3774
|
}, pe = async () => {
|
|
3779
3775
|
var T, z, W;
|
|
3780
3776
|
if ((T = m.value) != null && T.id) {
|
|
3781
|
-
|
|
3777
|
+
M.value = !0;
|
|
3782
3778
|
try {
|
|
3783
|
-
await o.delete(Z(m.value.id)), n("delete:success", m.value),
|
|
3779
|
+
await o.delete(Z(m.value.id)), n("delete:success", m.value), M.value = !1, le(), a.value++;
|
|
3784
3780
|
} catch (x) {
|
|
3785
3781
|
B.value = ((W = (z = x.response) == null ? void 0 : z.data) == null ? void 0 : W.message) || x.message || r("errors.delete"), n("error", x);
|
|
3786
3782
|
} finally {
|
|
3787
|
-
|
|
3783
|
+
M.value = !1;
|
|
3788
3784
|
}
|
|
3789
3785
|
}
|
|
3790
|
-
}, Se =
|
|
3791
|
-
return me(
|
|
3786
|
+
}, Se = F(!1);
|
|
3787
|
+
return me(_, (T) => {
|
|
3792
3788
|
var z, W, x, $;
|
|
3793
3789
|
if (Array.isArray((z = T == null ? void 0 : T.response) == null ? void 0 : z.data) && (Se.value = T.response.data.length > 0), T.status === be.Error) {
|
|
3794
3790
|
y.value = {
|
|
@@ -3798,7 +3794,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3798
3794
|
}
|
|
3799
3795
|
y.value = null;
|
|
3800
3796
|
}), ct(async () => {
|
|
3801
|
-
await i.canCreate() && (
|
|
3797
|
+
await i.canCreate() && (N.value.title = r("snis.list.empty_state.title"), N.value.ctaText = r("actions.create"));
|
|
3802
3798
|
}), (T, z) => {
|
|
3803
3799
|
const W = U("KButton"), x = U("KCopy"), $ = U("KBadge"), H = U("KTruncate"), ue = U("KDropdownItem"), ie = U("KClipboardProvider");
|
|
3804
3800
|
return k(), q("div", El, [
|
|
@@ -3808,7 +3804,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3808
3804
|
"disable-pagination-page-jump": "",
|
|
3809
3805
|
"disable-row-click": !0,
|
|
3810
3806
|
"disable-sorting": l.value,
|
|
3811
|
-
"empty-state-options":
|
|
3807
|
+
"empty-state-options": N.value,
|
|
3812
3808
|
"enable-entity-actions": "",
|
|
3813
3809
|
"error-message": y.value,
|
|
3814
3810
|
fetcher: h(b),
|
|
@@ -3947,7 +3943,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3947
3943
|
_: 1
|
|
3948
3944
|
}, 8, ["cache-identifier", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers", "use-action-outside"]),
|
|
3949
3945
|
A(h(Zo), {
|
|
3950
|
-
"action-pending":
|
|
3946
|
+
"action-pending": M.value,
|
|
3951
3947
|
description: h(r)("delete.description"),
|
|
3952
3948
|
"entity-name": m.value && (m.value.name || m.value.id),
|
|
3953
3949
|
"entity-type": h(Gt).SNI,
|
|
@@ -3989,7 +3985,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
3989
3985
|
emits: ["update", "error", "loading"],
|
|
3990
3986
|
setup(e, { emit: t }) {
|
|
3991
3987
|
var W;
|
|
3992
|
-
const n = t, i = e, r = Jt(), { i18n: { t: o } } = Zt.useI18n(), { getMessageFromError: a } = Il(), { axiosInstance: l } = Dn((W = i.config) == null ? void 0 : W.axiosRequestConfig), s = I(() =>
|
|
3988
|
+
const n = t, i = e, r = Jt(), { i18n: { t: o } } = Zt.useI18n(), { getMessageFromError: a } = Il(), { axiosInstance: l } = Dn((W = i.config) == null ? void 0 : W.axiosRequestConfig), s = I(() => Me.form[i.config.app].edit), u = I(() => i.sniId ? Pe.Edit : Pe.Create), d = I(() => i.config.certificateId && u.value === Pe.Create ? i.config.certificateId : ""), c = vt({
|
|
3993
3989
|
fields: {
|
|
3994
3990
|
name: "",
|
|
3995
3991
|
tags: "",
|
|
@@ -4004,15 +4000,15 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
4004
4000
|
}), p = I(() => JSON.stringify(c.fields) !== JSON.stringify(f) && !!c.fields.name && !!(c.fields.certificate_id || d.value)), b = (x) => {
|
|
4005
4001
|
var $, H;
|
|
4006
4002
|
c.fields.name = (x == null ? void 0 : x.name) || "", c.fields.tags = (($ = x == null ? void 0 : x.tags) == null ? void 0 : $.join(", ")) || "", c.fields.certificate_id = ((H = x == null ? void 0 : x.certificate) == null ? void 0 : H.id) || "", Object.assign(f, c.fields);
|
|
4007
|
-
},
|
|
4003
|
+
}, _ = () => {
|
|
4008
4004
|
r.push(i.config.cancelRoute);
|
|
4009
4005
|
}, S = I(() => {
|
|
4010
4006
|
var $, H;
|
|
4011
|
-
let x = `${i.config.apiBaseUrl}${
|
|
4007
|
+
let x = `${i.config.apiBaseUrl}${Me.form[i.config.app].validate}`;
|
|
4012
4008
|
return i.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, (($ = i.config) == null ? void 0 : $.controlPlaneId) || "") : i.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (H = i.config) != null && H.workspace ? `/${i.config.workspace}` : "")), x = x.replace(/{id}/gi, i.sniId), x;
|
|
4013
4009
|
}), j = I(() => {
|
|
4014
4010
|
var $, H;
|
|
4015
|
-
let x = `${i.config.apiBaseUrl}${
|
|
4011
|
+
let x = `${i.config.apiBaseUrl}${Me.form[i.config.app][u.value]}`;
|
|
4016
4012
|
return i.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, (($ = i.config) == null ? void 0 : $.controlPlaneId) || "") : i.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (H = i.config) != null && H.workspace ? `/${i.config.workspace}` : "")), x = x.replace(/{id}/gi, i.sniId), x;
|
|
4017
4013
|
}), y = I(() => {
|
|
4018
4014
|
var x, $;
|
|
@@ -4021,7 +4017,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
4021
4017
|
tags: ($ = (x = c.fields.tags.split(",")) == null ? void 0 : x.map((H) => String(H || "").trim())) == null ? void 0 : $.filter((H) => H !== ""),
|
|
4022
4018
|
certificate: { id: d.value || c.fields.certificate_id }
|
|
4023
4019
|
};
|
|
4024
|
-
}),
|
|
4020
|
+
}), N = async () => {
|
|
4025
4021
|
var x, $, H, ue, ie, D;
|
|
4026
4022
|
try {
|
|
4027
4023
|
c.isReadonly = !0;
|
|
@@ -4038,11 +4034,11 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
4038
4034
|
allRecords: g,
|
|
4039
4035
|
error: m,
|
|
4040
4036
|
validationError: R,
|
|
4041
|
-
loadItems:
|
|
4037
|
+
loadItems: M,
|
|
4042
4038
|
results: B
|
|
4043
|
-
} = _l(i.config,
|
|
4039
|
+
} = _l(i.config, Me.form[i.config.app].certificates), Z = (x) => {
|
|
4044
4040
|
C(x);
|
|
4045
|
-
}, K = I(() => m.value ? o("errors.certificates.fetch") : ""), le = I(() => R.value ? o("errors.certificates.invalid") : ""), pe =
|
|
4041
|
+
}, K = I(() => m.value ? o("errors.certificates.fetch") : ""), le = I(() => R.value ? o("errors.certificates.invalid") : ""), pe = F(0), Se = I(() => g.value === void 0), ce = F(/* @__PURE__ */ new Set()), T = I(() => Array.from(ce.value).map(($) => ({
|
|
4046
4042
|
label: $,
|
|
4047
4043
|
value: $,
|
|
4048
4044
|
selected: c.fields.certificate_id === $
|
|
@@ -4057,7 +4053,7 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
4057
4053
|
}, { immediate: !0, deep: !0 }), me(T, () => {
|
|
4058
4054
|
pe.value++;
|
|
4059
4055
|
}, { immediate: !0, deep: !0 }), ct(async () => {
|
|
4060
|
-
await
|
|
4056
|
+
await M();
|
|
4061
4057
|
}), (x, $) => {
|
|
4062
4058
|
const H = U("KInput"), ue = U("KSelect");
|
|
4063
4059
|
return k(), q("div", Ul, [
|
|
@@ -4069,11 +4065,11 @@ const vl = ["aria-labelledby"], bl = { class: "form-section-wrapper" }, wl = {
|
|
|
4069
4065
|
"fetch-url": s.value,
|
|
4070
4066
|
"form-fields": y.value,
|
|
4071
4067
|
"is-readonly": c.isReadonly,
|
|
4072
|
-
onCancel:
|
|
4068
|
+
onCancel: _,
|
|
4073
4069
|
"onFetch:error": $[3] || ($[3] = (ie) => x.$emit("error", ie)),
|
|
4074
4070
|
"onFetch:success": b,
|
|
4075
4071
|
onLoading: $[4] || ($[4] = (ie) => x.$emit("loading", ie)),
|
|
4076
|
-
onSubmit:
|
|
4072
|
+
onSubmit: N
|
|
4077
4073
|
}, {
|
|
4078
4074
|
default: v(() => [
|
|
4079
4075
|
A(h(Pt), {
|