@kong-ui-public/entities-gateway-services 1.3.0 → 1.3.1
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.
|
@@ -542,7 +542,7 @@ function Oa(e, i, t = "data") {
|
|
|
542
542
|
}
|
|
543
543
|
function Ea() {
|
|
544
544
|
return {
|
|
545
|
-
getPropValue: (e, i) => (i == null ? void 0 : i[e])
|
|
545
|
+
getPropValue: (e, i) => (i == null ? void 0 : i[e]) ?? void 0
|
|
546
546
|
};
|
|
547
547
|
}
|
|
548
548
|
function Va() {
|
|
@@ -576,7 +576,7 @@ const ai = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
576
576
|
const t = $t(e), a = $t(i), o = t.pop(), r = a.pop(), l = Et(t, a);
|
|
577
577
|
return l !== 0 ? l : o && r ? Et(o.split("."), r.split(".")) : o || r ? o ? -1 : 1 : 0;
|
|
578
578
|
}, Vt = (e, i, t) => {
|
|
579
|
-
|
|
579
|
+
Pa(t);
|
|
580
580
|
const a = La(e, i);
|
|
581
581
|
return oi[t].includes(a);
|
|
582
582
|
}, oi = {
|
|
@@ -586,18 +586,18 @@ const ai = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
586
586
|
"<=": [-1, 0],
|
|
587
587
|
"<": [-1],
|
|
588
588
|
"!=": [-1, 1]
|
|
589
|
-
}, jt = Object.keys(oi),
|
|
589
|
+
}, jt = Object.keys(oi), Pa = (e) => {
|
|
590
590
|
if (typeof e != "string")
|
|
591
591
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
592
592
|
if (jt.indexOf(e) === -1)
|
|
593
593
|
throw new Error(`Invalid operator, expected one of ${jt.join("|")}`);
|
|
594
|
-
},
|
|
594
|
+
}, Ba = (e) => typeof e == "string" && /^[v\d]/.test(e) && ai.test(e);
|
|
595
595
|
function Na(e) {
|
|
596
596
|
const { gatewayInfo: i, supportedRange: t } = e;
|
|
597
597
|
if (!i)
|
|
598
598
|
return !0;
|
|
599
599
|
const { edition: a, version: o } = i;
|
|
600
|
-
if (!
|
|
600
|
+
if (!Ba(o))
|
|
601
601
|
return console.error("Invalid version"), !1;
|
|
602
602
|
const r = t[a];
|
|
603
603
|
if (!r)
|
|
@@ -1327,17 +1327,17 @@ function Lo(e) {
|
|
|
1327
1327
|
var i = e.length;
|
|
1328
1328
|
return i === 1 && e === "~" || i === 4 && (e === "null" || e === "Null" || e === "NULL");
|
|
1329
1329
|
}
|
|
1330
|
-
function
|
|
1330
|
+
function Po() {
|
|
1331
1331
|
return null;
|
|
1332
1332
|
}
|
|
1333
|
-
function
|
|
1333
|
+
function Bo(e) {
|
|
1334
1334
|
return e === null;
|
|
1335
1335
|
}
|
|
1336
1336
|
var mi = new pe("tag:yaml.org,2002:null", {
|
|
1337
1337
|
kind: "scalar",
|
|
1338
1338
|
resolve: Lo,
|
|
1339
|
-
construct:
|
|
1340
|
-
predicate:
|
|
1339
|
+
construct: Po,
|
|
1340
|
+
predicate: Bo,
|
|
1341
1341
|
represent: {
|
|
1342
1342
|
canonical: function() {
|
|
1343
1343
|
return "~";
|
|
@@ -1705,8 +1705,8 @@ var Ai = new pe("tag:yaml.org,2002:set", {
|
|
|
1705
1705
|
xi,
|
|
1706
1706
|
Ai
|
|
1707
1707
|
]
|
|
1708
|
-
}), Ie = Object.prototype.hasOwnProperty, We = 1, Ti = 2, $i = 3, Ze = 4, st = 1, hr = 2,
|
|
1709
|
-
function
|
|
1708
|
+
}), Ie = Object.prototype.hasOwnProperty, We = 1, Ti = 2, $i = 3, Ze = 4, st = 1, hr = 2, Pt = 3, br = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, _r = /[\x85\u2028\u2029]/, wr = /[,\[\]\{\}]/, Mi = /^(?:!|!!|![a-z\-]+!)$/i, Oi = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1709
|
+
function Bt(e) {
|
|
1710
1710
|
return Object.prototype.toString.call(e);
|
|
1711
1711
|
}
|
|
1712
1712
|
function _e(e) {
|
|
@@ -1800,8 +1800,8 @@ function Fe(e, i, t, a, o, r, l, n, c) {
|
|
|
1800
1800
|
var d, f;
|
|
1801
1801
|
if (Array.isArray(o))
|
|
1802
1802
|
for (o = Array.prototype.slice.call(o), d = 0, f = o.length; d < f; d += 1)
|
|
1803
|
-
Array.isArray(o[d]) && M(e, "nested arrays are not supported inside keys"), typeof o == "object" &&
|
|
1804
|
-
if (typeof o == "object" &&
|
|
1803
|
+
Array.isArray(o[d]) && M(e, "nested arrays are not supported inside keys"), typeof o == "object" && Bt(o[d]) === "[object Object]" && (o[d] = "[object Object]");
|
|
1804
|
+
if (typeof o == "object" && Bt(o) === "[object Object]" && (o = "[object Object]"), o = String(o), i === null && (i = {}), a === "tag:yaml.org,2002:merge")
|
|
1805
1805
|
if (Array.isArray(r))
|
|
1806
1806
|
for (d = 0, f = r.length; d < f; d += 1)
|
|
1807
1807
|
qt(e, i, r[d], t);
|
|
@@ -1920,7 +1920,7 @@ function Mr(e, i) {
|
|
|
1920
1920
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = n), s = e.input.charCodeAt(++e.position); s !== 0; ) {
|
|
1921
1921
|
if (ne(e, !0, i), s = e.input.charCodeAt(e.position), s === f)
|
|
1922
1922
|
return e.position++, e.tag = l, e.anchor = c, e.kind = _ ? "mapping" : "sequence", e.result = n, !0;
|
|
1923
|
-
t ? s === 44 && M(e, "expected the node content, but found ','") : M(e, "missed comma between flow collection entries"), y = x = S = null, p = b = !1, s === 63 && (d = e.input.charCodeAt(e.position + 1), ge(d) && (p = b = !0, e.position++, ne(e, !0, i))), a = e.line, o = e.lineStart, r = e.position,
|
|
1923
|
+
t ? s === 44 && M(e, "expected the node content, but found ','") : M(e, "missed comma between flow collection entries"), y = x = S = null, p = b = !1, s === 63 && (d = e.input.charCodeAt(e.position + 1), ge(d) && (p = b = !0, e.position++, ne(e, !0, i))), a = e.line, o = e.lineStart, r = e.position, Pe(e, i, We, !1, !0), y = e.tag, x = e.result, ne(e, !0, i), s = e.input.charCodeAt(e.position), (b || e.line === a) && s === 58 && (p = !0, s = e.input.charCodeAt(++e.position), ne(e, !0, i), Pe(e, i, We, !1, !0), S = e.result), _ ? Fe(e, n, w, y, x, S, a, o, r) : p ? n.push(Fe(e, null, w, y, x, S, a, o, r)) : n.push(x), ne(e, !0, i), s = e.input.charCodeAt(e.position), s === 44 ? (t = !0, s = e.input.charCodeAt(++e.position)) : t = !1;
|
|
1924
1924
|
}
|
|
1925
1925
|
M(e, "unexpected end of the stream within a flow collection");
|
|
1926
1926
|
}
|
|
@@ -1934,7 +1934,7 @@ function Or(e, i) {
|
|
|
1934
1934
|
return !1;
|
|
1935
1935
|
for (e.kind = "scalar", e.result = ""; p !== 0; )
|
|
1936
1936
|
if (p = e.input.charCodeAt(++e.position), p === 43 || p === 45)
|
|
1937
|
-
st === o ? o = p === 43 ?
|
|
1937
|
+
st === o ? o = p === 43 ? Pt : hr : M(e, "repeat of a chomping mode identifier");
|
|
1938
1938
|
else if ((f = Sr(p)) >= 0)
|
|
1939
1939
|
f === 0 ? M(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : l ? M(e, "repeat of an indentation width identifier") : (n = i + f - 1, l = !0);
|
|
1940
1940
|
else
|
|
@@ -1956,7 +1956,7 @@ function Or(e, i) {
|
|
|
1956
1956
|
continue;
|
|
1957
1957
|
}
|
|
1958
1958
|
if (e.lineIndent < n) {
|
|
1959
|
-
o ===
|
|
1959
|
+
o === Pt ? e.result += se.repeat(`
|
|
1960
1960
|
`, r ? 1 + c : c) : o === st && r && (e.result += `
|
|
1961
1961
|
`);
|
|
1962
1962
|
break;
|
|
@@ -1980,7 +1980,7 @@ function Ut(e, i) {
|
|
|
1980
1980
|
r.push(null), c = e.input.charCodeAt(e.position);
|
|
1981
1981
|
continue;
|
|
1982
1982
|
}
|
|
1983
|
-
if (t = e.line,
|
|
1983
|
+
if (t = e.line, Pe(e, i, $i, !1, !0), r.push(e.result), ne(e, !0, -1), c = e.input.charCodeAt(e.position), (e.line === t || e.lineIndent > i) && c !== 0)
|
|
1984
1984
|
M(e, "bad indentation of a sequence entry");
|
|
1985
1985
|
else if (e.lineIndent < i)
|
|
1986
1986
|
break;
|
|
@@ -1995,7 +1995,7 @@ function Er(e, i, t) {
|
|
|
1995
1995
|
if (!y && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, M(e, "tab characters must not be used in indentation")), a = e.input.charCodeAt(e.position + 1), r = e.line, (s === 63 || s === 58) && ge(a))
|
|
1996
1996
|
s === 63 ? (y && (Fe(e, p, b, _, w, null, l, n, c), _ = w = x = null), S = !0, y = !0, o = !0) : y ? (y = !1, o = !0) : M(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, s = a;
|
|
1997
1997
|
else {
|
|
1998
|
-
if (l = e.line, n = e.lineStart, c = e.position, !
|
|
1998
|
+
if (l = e.line, n = e.lineStart, c = e.position, !Pe(e, t, Ti, !1, !0))
|
|
1999
1999
|
break;
|
|
2000
2000
|
if (e.line === r) {
|
|
2001
2001
|
for (s = e.input.charCodeAt(e.position); Te(s); )
|
|
@@ -2011,7 +2011,7 @@ function Er(e, i, t) {
|
|
|
2011
2011
|
else
|
|
2012
2012
|
return e.tag = d, e.anchor = f, !0;
|
|
2013
2013
|
}
|
|
2014
|
-
if ((e.line === r || e.lineIndent > i) && (y && (l = e.line, n = e.lineStart, c = e.position),
|
|
2014
|
+
if ((e.line === r || e.lineIndent > i) && (y && (l = e.line, n = e.lineStart, c = e.position), Pe(e, i, Ze, !0, o) && (y ? w = e.result : x = e.result), y || (Fe(e, p, b, _, w, x, l, n, c), _ = w = x = null), ne(e, !0, -1), s = e.input.charCodeAt(e.position)), (e.line === r || e.lineIndent > i) && s !== 0)
|
|
2015
2015
|
M(e, "bad indentation of a mapping entry");
|
|
2016
2016
|
else if (e.lineIndent < i)
|
|
2017
2017
|
break;
|
|
@@ -2056,7 +2056,7 @@ function Fr(e) {
|
|
|
2056
2056
|
a = e.input.charCodeAt(++e.position);
|
|
2057
2057
|
return e.position === i && M(e, "name of an alias node must contain at least one character"), t = e.input.slice(i, e.position), Ie.call(e.anchorMap, t) || M(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], ne(e, !0, -1), !0;
|
|
2058
2058
|
}
|
|
2059
|
-
function
|
|
2059
|
+
function Pe(e, i, t, a, o) {
|
|
2060
2060
|
var r, l, n, c = 1, d = !1, f = !1, p, b, _, w, x, y;
|
|
2061
2061
|
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, r = l = n = Ze === t || $i === t, a && ne(e, !0, -1) && (d = !0, e.lineIndent > i ? c = 1 : e.lineIndent === i ? c = 0 : e.lineIndent < i && (c = -1)), c === 1)
|
|
2062
2062
|
for (; Vr(e) || jr(e); )
|
|
@@ -2104,7 +2104,7 @@ function Lr(e) {
|
|
|
2104
2104
|
}
|
|
2105
2105
|
l !== 0 && St(e), Ie.call(Kt, a) ? Kt[a](e, a, o) : Qe(e, 'unknown document directive "' + a + '"');
|
|
2106
2106
|
}
|
|
2107
|
-
if (ne(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, ne(e, !0, -1)) : r && M(e, "directives end mark is expected"),
|
|
2107
|
+
if (ne(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, ne(e, !0, -1)) : r && M(e, "directives end mark is expected"), Pe(e, e.lineIndent - 1, Ze, !1, !0), ne(e, !0, -1), e.checkLineBreaks && _r.test(e.input.slice(i, e.position)) && Qe(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && it(e)) {
|
|
2108
2108
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, ne(e, !0, -1));
|
|
2109
2109
|
return;
|
|
2110
2110
|
}
|
|
@@ -2123,7 +2123,7 @@ function Fi(e, i) {
|
|
|
2123
2123
|
Lr(t);
|
|
2124
2124
|
return t.documents;
|
|
2125
2125
|
}
|
|
2126
|
-
function
|
|
2126
|
+
function Pr(e, i, t) {
|
|
2127
2127
|
i !== null && typeof i == "object" && typeof t > "u" && (t = i, i = null);
|
|
2128
2128
|
var a = Fi(e, t);
|
|
2129
2129
|
if (typeof i != "function")
|
|
@@ -2131,7 +2131,7 @@ function Br(e, i, t) {
|
|
|
2131
2131
|
for (var o = 0, r = a.length; o < r; o += 1)
|
|
2132
2132
|
i(a[o]);
|
|
2133
2133
|
}
|
|
2134
|
-
function
|
|
2134
|
+
function Br(e, i) {
|
|
2135
2135
|
var t = Fi(e, i);
|
|
2136
2136
|
if (t.length !== 0) {
|
|
2137
2137
|
if (t.length === 1)
|
|
@@ -2139,10 +2139,10 @@ function Pr(e, i) {
|
|
|
2139
2139
|
throw new ye("expected a single document in the stream, but found more");
|
|
2140
2140
|
}
|
|
2141
2141
|
}
|
|
2142
|
-
var Nr =
|
|
2142
|
+
var Nr = Pr, Kr = Br, Li = {
|
|
2143
2143
|
loadAll: Nr,
|
|
2144
2144
|
load: Kr
|
|
2145
|
-
},
|
|
2145
|
+
}, Pi = Object.prototype.toString, Bi = Object.prototype.hasOwnProperty, xt = 65279, qr = 9, Re = 10, Ur = 13, Rr = 32, Dr = 33, Gr = 34, pt = 35, Hr = 37, zr = 38, Yr = 39, Jr = 42, Ni = 44, Wr = 45, Xe = 58, Zr = 61, Qr = 62, Xr = 63, en = 64, Ki = 91, qi = 93, tn = 96, Ui = 123, an = 124, Ri = 125, me = {};
|
|
2146
2146
|
me[0] = "\\0";
|
|
2147
2147
|
me[7] = "\\a";
|
|
2148
2148
|
me[8] = "\\b";
|
|
@@ -2181,7 +2181,7 @@ function nn(e, i) {
|
|
|
2181
2181
|
if (i === null)
|
|
2182
2182
|
return {};
|
|
2183
2183
|
for (t = {}, a = Object.keys(i), o = 0, r = a.length; o < r; o += 1)
|
|
2184
|
-
l = a[o], n = String(i[l]), l.slice(0, 2) === "!!" && (l = "tag:yaml.org,2002:" + l.slice(2)), c = e.compiledTypeMap.fallback[l], c &&
|
|
2184
|
+
l = a[o], n = String(i[l]), l.slice(0, 2) === "!!" && (l = "tag:yaml.org,2002:" + l.slice(2)), c = e.compiledTypeMap.fallback[l], c && Bi.call(c.styleAliases, n) && (n = c.styleAliases[n]), t[l] = n;
|
|
2185
2185
|
return t;
|
|
2186
2186
|
}
|
|
2187
2187
|
function ln(e) {
|
|
@@ -2383,9 +2383,9 @@ function Wt(e, i, t) {
|
|
|
2383
2383
|
for (o = t ? e.explicitTypes : e.implicitTypes, r = 0, l = o.length; r < l; r += 1)
|
|
2384
2384
|
if (n = o[r], (n.instanceOf || n.predicate) && (!n.instanceOf || typeof i == "object" && i instanceof n.instanceOf) && (!n.predicate || n.predicate(i))) {
|
|
2385
2385
|
if (t ? n.multi && n.representName ? e.tag = n.representName(i) : e.tag = n.tag : e.tag = "?", n.represent) {
|
|
2386
|
-
if (c = e.styleMap[n.tag] || n.defaultStyle,
|
|
2386
|
+
if (c = e.styleMap[n.tag] || n.defaultStyle, Pi.call(n.represent) === "[object Function]")
|
|
2387
2387
|
a = n.represent(i, c);
|
|
2388
|
-
else if (
|
|
2388
|
+
else if (Bi.call(n.represent, c))
|
|
2389
2389
|
a = n.represent[c](i, c);
|
|
2390
2390
|
else
|
|
2391
2391
|
throw new ye("!<" + n.tag + '> tag resolver accepts not "' + c + '" style');
|
|
@@ -2397,7 +2397,7 @@ function Wt(e, i, t) {
|
|
|
2397
2397
|
}
|
|
2398
2398
|
function ke(e, i, t, a, o, r, l) {
|
|
2399
2399
|
e.tag = null, e.dump = t, Wt(e, t, !1) || Wt(e, t, !0);
|
|
2400
|
-
var n =
|
|
2400
|
+
var n = Pi.call(e.dump), c = a, d;
|
|
2401
2401
|
a && (a = e.flowLevel < 0 || e.flowLevel > i);
|
|
2402
2402
|
var f = n === "[object Object]" || n === "[object Array]", p, b;
|
|
2403
2403
|
if (f && (p = e.duplicates.indexOf(t), b = p !== -1), (e.tag !== null && e.tag !== "?" || b || e.indent !== 2 && i > 0) && (o = !1), b && e.usedDuplicates[p])
|
|
@@ -2468,7 +2468,7 @@ var Sn = pe, In = ci, xn = fi, An = hi, Tn = bi, $n = Ct, Mn = Li.load, On = Li.
|
|
|
2468
2468
|
omap: Ii,
|
|
2469
2469
|
seq: di,
|
|
2470
2470
|
str: ui
|
|
2471
|
-
}, Fn = At("safeLoad", "load"), Ln = At("safeLoadAll", "loadAll"),
|
|
2471
|
+
}, Fn = At("safeLoad", "load"), Ln = At("safeLoadAll", "loadAll"), Pn = At("safeDump", "dump"), Bn = {
|
|
2472
2472
|
Type: Sn,
|
|
2473
2473
|
Schema: In,
|
|
2474
2474
|
FAILSAFE_SCHEMA: xn,
|
|
@@ -2482,7 +2482,7 @@ var Sn = pe, In = ci, xn = fi, An = hi, Tn = bi, $n = Ct, Mn = Li.load, On = Li.
|
|
|
2482
2482
|
types: jn,
|
|
2483
2483
|
safeLoad: Fn,
|
|
2484
2484
|
safeLoadAll: Ln,
|
|
2485
|
-
safeDump:
|
|
2485
|
+
safeDump: Pn
|
|
2486
2486
|
};
|
|
2487
2487
|
const Nn = {
|
|
2488
2488
|
key: 0,
|
|
@@ -2524,7 +2524,7 @@ const Nn = {
|
|
|
2524
2524
|
setup(e) {
|
|
2525
2525
|
const i = e, t = tt(), { i18n: { t: a } } = ue.useI18n(), o = (n) => !!(n.tooltip || t[`${n.key}-label-tooltip`]), r = L(""), l = L("");
|
|
2526
2526
|
return we(() => i.format, (n) => {
|
|
2527
|
-
n === "json" ? r.value = JSON.stringify(i.record, null, 2) : n === "yaml" && (l.value =
|
|
2527
|
+
n === "json" ? r.value = JSON.stringify(i.record, null, 2) : n === "yaml" && (l.value = Bn.dump(i.record));
|
|
2528
2528
|
}, { immediate: !0 }), (n, c) => {
|
|
2529
2529
|
const d = j("KCodeBlock");
|
|
2530
2530
|
return h(), A(he, null, [
|
|
@@ -2821,12 +2821,12 @@ const Nn = {
|
|
|
2821
2821
|
section: fe.Basic
|
|
2822
2822
|
}
|
|
2823
2823
|
}, _ = L(!1), w = L(!1), x = L(""), y = L(), S = $(() => {
|
|
2824
|
-
var T, U,
|
|
2824
|
+
var T, U, B;
|
|
2825
2825
|
if (!y.value)
|
|
2826
2826
|
return [];
|
|
2827
2827
|
const G = [], X = Object.keys(y.value).length;
|
|
2828
2828
|
for (const H in y.value) {
|
|
2829
|
-
const W = (U = (T = a.configSchema) == null ? void 0 : T[H]) == null ? void 0 : U.order, z = (
|
|
2829
|
+
const W = (U = (T = a.configSchema) == null ? void 0 : T[H]) == null ? void 0 : U.order, z = (B = b[H]) == null ? void 0 : B.order;
|
|
2830
2830
|
let ae = X;
|
|
2831
2831
|
(z || z === 0) && (ae = z === -1 ? X + 1 : z), W && (ae = W === -1 ? X + 1 : W), G.push([H, ae]);
|
|
2832
2832
|
}
|
|
@@ -2849,9 +2849,9 @@ const Nn = {
|
|
|
2849
2849
|
var T, U;
|
|
2850
2850
|
if (!y.value || !a.pluginConfigKey)
|
|
2851
2851
|
return [];
|
|
2852
|
-
const
|
|
2853
|
-
for (const H in
|
|
2854
|
-
const W = (U = (T = a.pluginConfigSchema) == null ? void 0 : T[H]) == null ? void 0 : U.order, z =
|
|
2852
|
+
const B = y.value[a.pluginConfigKey] || {}, G = Object.keys(B).length, X = [];
|
|
2853
|
+
for (const H in B) {
|
|
2854
|
+
const W = (U = (T = a.pluginConfigSchema) == null ? void 0 : T[H]) == null ? void 0 : U.order, z = B[H];
|
|
2855
2855
|
let ae = z != null && z !== "" ? G - 1 : G;
|
|
2856
2856
|
W && (ae = W === -1 ? G + 1 : W), X.push([H, ae]);
|
|
2857
2857
|
}
|
|
@@ -2859,7 +2859,7 @@ const Nn = {
|
|
|
2859
2859
|
return H[1] - W[1];
|
|
2860
2860
|
}), X.map((H) => {
|
|
2861
2861
|
var W;
|
|
2862
|
-
const z = H[0], ae =
|
|
2862
|
+
const z = H[0], ae = B[z], Z = ((W = a.pluginConfigSchema) == null ? void 0 : W[z]) || {};
|
|
2863
2863
|
return {
|
|
2864
2864
|
key: z,
|
|
2865
2865
|
value: ae,
|
|
@@ -2871,19 +2871,19 @@ const Nn = {
|
|
|
2871
2871
|
};
|
|
2872
2872
|
}).filter((H) => !H.hidden);
|
|
2873
2873
|
}), I = $(() => {
|
|
2874
|
-
var T, U,
|
|
2874
|
+
var T, U, B, G;
|
|
2875
2875
|
return {
|
|
2876
2876
|
basic: (T = S.value) == null ? void 0 : T.filter((X) => X.section === fe.Basic),
|
|
2877
2877
|
advanced: (U = S.value) == null ? void 0 : U.filter((X) => X.section === fe.Advanced),
|
|
2878
|
-
plugin: (G = s.value) == null ? void 0 : G.concat((
|
|
2878
|
+
plugin: (G = s.value) == null ? void 0 : G.concat((B = S.value) == null ? void 0 : B.filter((X) => X.section === fe.Plugin))
|
|
2879
2879
|
};
|
|
2880
2880
|
}), R = $(() => {
|
|
2881
2881
|
const T = [];
|
|
2882
2882
|
return I.value.basic.length && T.push("basic"), I.value.advanced.length && T.push("advanced"), I.value.plugin.length && T.push("plugin"), T;
|
|
2883
2883
|
}), N = (T) => !!(T.tooltip || o[`${T.key}-label-tooltip`]), ie = $(() => {
|
|
2884
2884
|
var T, U;
|
|
2885
|
-
let
|
|
2886
|
-
return a.config.app === "konnect" ?
|
|
2885
|
+
let B = `${a.config.apiBaseUrl}${a.fetchUrl}`;
|
|
2886
|
+
return a.config.app === "konnect" ? B = B.replace(/{controlPlaneId}/gi, ((T = a.config) == null ? void 0 : T.controlPlaneId) || "") : a.config.app === "kongManager" && (B = B.replace(/\/{workspace}/gi, (U = a.config) != null && U.workspace ? `/${a.config.workspace}` : "")), B = B.replace(/{id}/gi, a.config.entityId), B;
|
|
2887
2887
|
}), J = (T) => {
|
|
2888
2888
|
y.value && T(JSON.stringify(y.value)) ? i("copy:success", y.value) : i("copy:error");
|
|
2889
2889
|
};
|
|
@@ -2910,12 +2910,12 @@ const Nn = {
|
|
|
2910
2910
|
_.value = !1;
|
|
2911
2911
|
}
|
|
2912
2912
|
}), (T, U) => {
|
|
2913
|
-
const
|
|
2913
|
+
const B = j("KLabel"), G = j("KSelect"), X = j("KButton"), H = j("KClipboardProvider"), W = j("KSkeleton"), z = j("KEmptyState"), ae = j("KCard");
|
|
2914
2914
|
return h(), K(ae, { class: "kong-ui-entity-base-config-card" }, Ae({
|
|
2915
2915
|
actions: v(() => [
|
|
2916
2916
|
V("div", el, [
|
|
2917
2917
|
Q(T.$slots, "actions", {}, void 0, !0),
|
|
2918
|
-
e.config.jsonYamlEnabled ? (h(), K(
|
|
2918
|
+
e.config.jsonYamlEnabled ? (h(), K(B, {
|
|
2919
2919
|
key: 0,
|
|
2920
2920
|
class: "config-format-select-label",
|
|
2921
2921
|
"data-testid": "config-format-select-label"
|
|
@@ -3455,23 +3455,23 @@ const Nn = {
|
|
|
3455
3455
|
"search-input": e.query,
|
|
3456
3456
|
onKtableEmptyStateCtaClicked: p,
|
|
3457
3457
|
"onRow:click": _,
|
|
3458
|
-
onSort: R[0] || (R[0] = (
|
|
3458
|
+
onSort: R[0] || (R[0] = (B) => w(B)),
|
|
3459
3459
|
"onUpdate:tablePreferences": s
|
|
3460
3460
|
}, Ae({
|
|
3461
|
-
toolbar: v(({ state:
|
|
3461
|
+
toolbar: v(({ state: B }) => [
|
|
3462
3462
|
ze(V("div", yl, [
|
|
3463
3463
|
Q(I.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3464
3464
|
I.$slots["toolbar-button"] ? (h(), A("div", gl, [
|
|
3465
3465
|
Q(I.$slots, "toolbar-button", {}, void 0, !0)
|
|
3466
3466
|
])) : q("", !0)
|
|
3467
3467
|
], 512), [
|
|
3468
|
-
[Ye, r(
|
|
3468
|
+
[Ye, r(B)]
|
|
3469
3469
|
])
|
|
3470
3470
|
]),
|
|
3471
|
-
actions: v(({ row:
|
|
3471
|
+
actions: v(({ row: B, rowKey: G, rowValue: X }) => [
|
|
3472
3472
|
V("div", {
|
|
3473
3473
|
class: "actions-container",
|
|
3474
|
-
"data-testid":
|
|
3474
|
+
"data-testid": B.name
|
|
3475
3475
|
}, [
|
|
3476
3476
|
k(J, {
|
|
3477
3477
|
"kpop-attributes": { placement: "bottomEnd" },
|
|
@@ -3479,7 +3479,7 @@ const Nn = {
|
|
|
3479
3479
|
}, {
|
|
3480
3480
|
items: v(() => [
|
|
3481
3481
|
Q(I.$slots, "actions", {
|
|
3482
|
-
row:
|
|
3482
|
+
row: B,
|
|
3483
3483
|
rowKey: G,
|
|
3484
3484
|
rowValue: X
|
|
3485
3485
|
}, void 0, !0)
|
|
@@ -3506,7 +3506,7 @@ const Nn = {
|
|
|
3506
3506
|
]),
|
|
3507
3507
|
_: 2
|
|
3508
3508
|
}, [
|
|
3509
|
-
ve(e.tableHeaders, (
|
|
3509
|
+
ve(e.tableHeaders, (B, G) => ({
|
|
3510
3510
|
name: G,
|
|
3511
3511
|
fn: v(({ row: X, rowKey: H, rowValue: W }) => [
|
|
3512
3512
|
k(ml, {
|
|
@@ -3785,14 +3785,14 @@ const Nn = {
|
|
|
3785
3785
|
])
|
|
3786
3786
|
]),
|
|
3787
3787
|
itemBody: v(() => {
|
|
3788
|
-
var U,
|
|
3788
|
+
var U, B;
|
|
3789
3789
|
return [
|
|
3790
3790
|
V("div", Vl, [
|
|
3791
3791
|
V("label", {
|
|
3792
3792
|
class: "menu-item-label",
|
|
3793
3793
|
for: f(J.value)
|
|
3794
3794
|
}, O(m(a)("filter.fieldLabel")), 9, jl),
|
|
3795
|
-
((
|
|
3795
|
+
((B = (U = e.config.schema) == null ? void 0 : U[J.value]) == null ? void 0 : B.type) === "select" ? (h(), K(R, {
|
|
3796
3796
|
key: 0,
|
|
3797
3797
|
id: f(J.value),
|
|
3798
3798
|
modelValue: r.value[J.value],
|
|
@@ -3855,7 +3855,7 @@ const Nn = {
|
|
|
3855
3855
|
]));
|
|
3856
3856
|
};
|
|
3857
3857
|
}
|
|
3858
|
-
}),
|
|
3858
|
+
}), Pl = /* @__PURE__ */ be(Ll, [["__scopeId", "data-v-745f38c0"]]), Bl = /* @__PURE__ */ le({
|
|
3859
3859
|
__name: "EntityToggleModal",
|
|
3860
3860
|
props: {
|
|
3861
3861
|
visible: {
|
|
@@ -3935,7 +3935,7 @@ const Nn = {
|
|
|
3935
3935
|
]);
|
|
3936
3936
|
};
|
|
3937
3937
|
}
|
|
3938
|
-
}),
|
|
3938
|
+
}), Be = /* @__PURE__ */ le({
|
|
3939
3939
|
__name: "PermissionsWrapper",
|
|
3940
3940
|
props: {
|
|
3941
3941
|
/**
|
|
@@ -4088,10 +4088,10 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4088
4088
|
isExactMatch: F,
|
|
4089
4089
|
placeholder: a("search.placeholder")
|
|
4090
4090
|
};
|
|
4091
|
-
const { name: u, enabled: g, protocol:
|
|
4091
|
+
const { name: u, enabled: g, protocol: P, host: re, port: oe, path: ce } = c;
|
|
4092
4092
|
return {
|
|
4093
4093
|
isExactMatch: F,
|
|
4094
|
-
fields: { name: u, enabled: g, protocol:
|
|
4094
|
+
fields: { name: u, enabled: g, protocol: P, host: re, port: oe, path: ce },
|
|
4095
4095
|
schema: t.config.filterSchema
|
|
4096
4096
|
};
|
|
4097
4097
|
}), { fetcher: w, fetcherState: x } = zl(t.config, f.value), y = () => {
|
|
@@ -4110,8 +4110,8 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4110
4110
|
name: ""
|
|
4111
4111
|
};
|
|
4112
4112
|
if (N.value) {
|
|
4113
|
-
const { enabled: u, id: g, name:
|
|
4114
|
-
F.action = u ? "disable" : "enable", F.id = g, F.name =
|
|
4113
|
+
const { enabled: u, id: g, name: P } = N.value;
|
|
4114
|
+
F.action = u ? "disable" : "enable", F.id = g, F.name = P || g;
|
|
4115
4115
|
}
|
|
4116
4116
|
return F;
|
|
4117
4117
|
}), J = (F) => {
|
|
@@ -4119,8 +4119,8 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4119
4119
|
}, T = () => {
|
|
4120
4120
|
R.value = !1, N.value = null;
|
|
4121
4121
|
}, U = async () => {
|
|
4122
|
-
var
|
|
4123
|
-
if (!await ((
|
|
4122
|
+
var P, re;
|
|
4123
|
+
if (!await ((P = t.canEdit) == null ? void 0 : P.call(t, N.value)) || !N.value)
|
|
4124
4124
|
return;
|
|
4125
4125
|
const u = `${p.value.href}/${N.value.id}`, g = !N.value.enabled;
|
|
4126
4126
|
try {
|
|
@@ -4130,7 +4130,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4130
4130
|
i("error", oe);
|
|
4131
4131
|
}
|
|
4132
4132
|
N.value.enabled = g;
|
|
4133
|
-
},
|
|
4133
|
+
}, B = (F, u) => {
|
|
4134
4134
|
const g = F.id;
|
|
4135
4135
|
if (!u(g)) {
|
|
4136
4136
|
i("copy:error", {
|
|
@@ -4177,8 +4177,8 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4177
4177
|
Z.value = !0;
|
|
4178
4178
|
try {
|
|
4179
4179
|
await r.delete(de(z.value.id)), i("delete:success", z.value), Me(), l.value++;
|
|
4180
|
-
} catch (
|
|
4181
|
-
ee.value = ((g = (u =
|
|
4180
|
+
} catch (P) {
|
|
4181
|
+
ee.value = ((g = (u = P.response) == null ? void 0 : u.data) == null ? void 0 : g.message) || P.message || a("errors.delete"), i("error", P);
|
|
4182
4182
|
} finally {
|
|
4183
4183
|
Z.value = !1;
|
|
4184
4184
|
}
|
|
@@ -4195,7 +4195,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4195
4195
|
return gt(async () => {
|
|
4196
4196
|
Ce.value = await t.canCreate();
|
|
4197
4197
|
}), (F, u) => {
|
|
4198
|
-
const g = j("KButton"),
|
|
4198
|
+
const g = j("KButton"), P = j("KInputSwitch"), re = j("KBadge"), oe = j("KTruncate"), ce = j("KDropdownItem"), C = j("KClipboardProvider");
|
|
4199
4199
|
return h(), A("div", Wl, [
|
|
4200
4200
|
k(m(bl), {
|
|
4201
4201
|
"cache-identifier": e.cacheIdentifier,
|
|
@@ -4215,14 +4215,14 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4215
4215
|
onSort: S
|
|
4216
4216
|
}, {
|
|
4217
4217
|
"toolbar-filter": v(() => [
|
|
4218
|
-
k(m(
|
|
4218
|
+
k(m(Pl), {
|
|
4219
4219
|
modelValue: b.value,
|
|
4220
4220
|
"onUpdate:modelValue": u[0] || (u[0] = (Y) => b.value = Y),
|
|
4221
4221
|
config: _.value
|
|
4222
4222
|
}, null, 8, ["modelValue", "config"])
|
|
4223
4223
|
]),
|
|
4224
4224
|
"toolbar-button": v(() => [
|
|
4225
|
-
k(m(
|
|
4225
|
+
k(m(Be), {
|
|
4226
4226
|
"auth-function": () => e.canCreate()
|
|
4227
4227
|
}, {
|
|
4228
4228
|
default: v(() => [
|
|
@@ -4244,7 +4244,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4244
4244
|
V("b", null, O(Y ?? "-"), 1)
|
|
4245
4245
|
]),
|
|
4246
4246
|
enabled: v(({ row: Y }) => [
|
|
4247
|
-
k(m(
|
|
4247
|
+
k(m(Be), {
|
|
4248
4248
|
"auth-function": () => e.canEdit(Y),
|
|
4249
4249
|
"force-show": ""
|
|
4250
4250
|
}, {
|
|
@@ -4253,7 +4253,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4253
4253
|
onClick: u[1] || (u[1] = Le(() => {
|
|
4254
4254
|
}, ["stop"]))
|
|
4255
4255
|
}, [
|
|
4256
|
-
k(
|
|
4256
|
+
k(P, {
|
|
4257
4257
|
modelValue: Y.enabled,
|
|
4258
4258
|
"onUpdate:modelValue": (He) => Y.enabled = He,
|
|
4259
4259
|
"data-testid": `row-${Y.id}-toggle-input`,
|
|
@@ -4288,7 +4288,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4288
4288
|
default: v(({ copyToClipboard: E }) => [
|
|
4289
4289
|
k(ce, {
|
|
4290
4290
|
"data-testid": "action-entity-copy-id",
|
|
4291
|
-
onClick: (He) =>
|
|
4291
|
+
onClick: (He) => B(Y, E)
|
|
4292
4292
|
}, {
|
|
4293
4293
|
default: v(() => [
|
|
4294
4294
|
D(O(m(a)("actions.copy_id")), 1)
|
|
@@ -4312,7 +4312,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4312
4312
|
]),
|
|
4313
4313
|
_: 2
|
|
4314
4314
|
}, 1024),
|
|
4315
|
-
k(m(
|
|
4315
|
+
k(m(Be), {
|
|
4316
4316
|
"auth-function": () => e.canRetrieve(Y)
|
|
4317
4317
|
}, {
|
|
4318
4318
|
default: v(() => [
|
|
@@ -4324,7 +4324,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4324
4324
|
]),
|
|
4325
4325
|
_: 2
|
|
4326
4326
|
}, 1032, ["auth-function"]),
|
|
4327
|
-
k(m(
|
|
4327
|
+
k(m(Be), {
|
|
4328
4328
|
"auth-function": () => e.canEdit(Y)
|
|
4329
4329
|
}, {
|
|
4330
4330
|
default: v(() => [
|
|
@@ -4335,7 +4335,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4335
4335
|
]),
|
|
4336
4336
|
_: 2
|
|
4337
4337
|
}, 1032, ["auth-function"]),
|
|
4338
|
-
k(m(
|
|
4338
|
+
k(m(Be), {
|
|
4339
4339
|
"auth-function": () => e.canDelete(Y)
|
|
4340
4340
|
}, {
|
|
4341
4341
|
default: v(() => [
|
|
@@ -4356,7 +4356,7 @@ const Wl = { class: "kong-ui-entities-gateway-services-list" }, Zl = { key: 1 },
|
|
|
4356
4356
|
]),
|
|
4357
4357
|
_: 1
|
|
4358
4358
|
}, 8, ["cache-identifier", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers"]),
|
|
4359
|
-
k(m(
|
|
4359
|
+
k(m(Bl), {
|
|
4360
4360
|
action: ie.value.action,
|
|
4361
4361
|
"entity-id": ie.value.id,
|
|
4362
4362
|
"entity-name": ie.value.name,
|
|
@@ -4527,7 +4527,7 @@ const Ji = (e, i) => {
|
|
|
4527
4527
|
g.value;
|
|
4528
4528
|
}, T = (u) => u ? parseFloat(u) : 0, U = () => {
|
|
4529
4529
|
o.value = !0, s.errorMessage = "", s.fields.host = I.host, s.fields.path = I.path, s.fields.port = I.port, s.fields.protocol = I.protocol, s.fields.url = I.url, s.fields.retries = I.retries, s.fields.connect_timeout = I.connect_timeout, s.fields.write_timeout = I.write_timeout, s.fields.read_timeout = I.read_timeout, s.fields.client_certificate = I.client_certificate, s.fields.ca_certificates = I.ca_certificates, s.fields.tls_verify_enabled = I.tls_verify_enabled, s.fields.tls_verify_value = I.tls_verify_value;
|
|
4530
|
-
},
|
|
4530
|
+
}, B = () => {
|
|
4531
4531
|
if (s.fields.url && w.value === "url")
|
|
4532
4532
|
try {
|
|
4533
4533
|
const u = new URL(s.fields.url);
|
|
@@ -4557,23 +4557,23 @@ const Ji = (e, i) => {
|
|
|
4557
4557
|
}), z = (u) => new RegExp("^[0-9a-zA-Z.\\-_~]*$").test(u) ? "" : n("errors.validationNameError"), ae = (u) => {
|
|
4558
4558
|
y.value = z(u);
|
|
4559
4559
|
}, Z = $(() => _.value && JSON.stringify(s.fields) !== JSON.stringify(I) || w.value === "url" && !!s.fields.url || w.value === "protocol" && !!s.fields.host), ee = (u) => {
|
|
4560
|
-
var g,
|
|
4561
|
-
s.fields.name = (u == null ? void 0 : u.name) || "", s.fields.tags = ((g = u == null ? void 0 : u.tags) == null ? void 0 : g.join(",")) || "", s.fields.protocol = (u == null ? void 0 : u.protocol) || "http", s.fields.path = (u == null ? void 0 : u.path) || "", s.fields.read_timeout = ((u == null ? void 0 : u.read_timeout) || (u == null ? void 0 : u.read_timeout) === 0) ?? 6e4, s.fields.retries = ((u == null ? void 0 : u.retries) || (u == null ? void 0 : u.retries) === 0) ?? 5, s.fields.host = (u == null ? void 0 : u.host) || "", s.fields.connect_timeout = ((u == null ? void 0 : u.connect_timeout) || (u == null ? void 0 : u.connect_timeout) === 0) ?? 6e4, s.fields.tls_verify_enabled = (u == null ? void 0 : u.tls_verify) !== "" && (u == null ? void 0 : u.tls_verify) !== null && (u == null ? void 0 : u.tls_verify) !== void 0, s.fields.tls_verify_value = u != null && u.tls_verify ? u == null ? void 0 : u.tls_verify : !1, s.fields.ca_certificates = ((
|
|
4560
|
+
var g, P, re;
|
|
4561
|
+
s.fields.name = (u == null ? void 0 : u.name) || "", s.fields.tags = ((g = u == null ? void 0 : u.tags) == null ? void 0 : g.join(",")) || "", s.fields.protocol = (u == null ? void 0 : u.protocol) || "http", s.fields.path = (u == null ? void 0 : u.path) || "", s.fields.read_timeout = ((u == null ? void 0 : u.read_timeout) || (u == null ? void 0 : u.read_timeout) === 0) ?? 6e4, s.fields.retries = ((u == null ? void 0 : u.retries) || (u == null ? void 0 : u.retries) === 0) ?? 5, s.fields.host = (u == null ? void 0 : u.host) || "", s.fields.connect_timeout = ((u == null ? void 0 : u.connect_timeout) || (u == null ? void 0 : u.connect_timeout) === 0) ?? 6e4, s.fields.tls_verify_enabled = (u == null ? void 0 : u.tls_verify) !== "" && (u == null ? void 0 : u.tls_verify) !== null && (u == null ? void 0 : u.tls_verify) !== void 0, s.fields.tls_verify_value = u != null && u.tls_verify ? u == null ? void 0 : u.tls_verify : !1, s.fields.ca_certificates = ((P = u == null ? void 0 : u.ca_certificates) == null ? void 0 : P.join(",")) || "", s.fields.client_certificate = ((re = u == null ? void 0 : u.client_certificate) == null ? void 0 : re.id) || "", s.fields.write_timeout = ((u == null ? void 0 : u.write_timeout) || (u == null ? void 0 : u.write_timeout) === 0) ?? 6e4, s.fields.port = ((u == null ? void 0 : u.port) || (u == null ? void 0 : u.port) === 0) ?? 80, Object.assign(I, s.fields);
|
|
4562
4562
|
}, de = () => {
|
|
4563
4563
|
r.push(a.config.cancelRoute);
|
|
4564
4564
|
}, at = $(() => {
|
|
4565
|
-
var g,
|
|
4565
|
+
var g, P;
|
|
4566
4566
|
let u = `${a.config.apiBaseUrl}${Ke.form[a.config.app].validate}`;
|
|
4567
|
-
return a.config.app === "konnect" ? u = u.replace(/{controlPlaneId}/gi, ((g = a.config) == null ? void 0 : g.controlPlaneId) || "") : a.config.app === "kongManager" && (u = u.replace(/\/{workspace}/gi, (
|
|
4567
|
+
return a.config.app === "konnect" ? u = u.replace(/{controlPlaneId}/gi, ((g = a.config) == null ? void 0 : g.controlPlaneId) || "") : a.config.app === "kongManager" && (u = u.replace(/\/{workspace}/gi, (P = a.config) != null && P.workspace ? `/${a.config.workspace}` : "")), u = u.replace(/{id}/gi, a.gatewayServiceId), u;
|
|
4568
4568
|
}), Me = $(() => {
|
|
4569
|
-
var g,
|
|
4569
|
+
var g, P;
|
|
4570
4570
|
let u = `${a.config.apiBaseUrl}${Ke.form[a.config.app][p.value]}`;
|
|
4571
|
-
return a.config.app === "konnect" ? u = u.replace(/{controlPlaneId}/gi, ((g = a.config) == null ? void 0 : g.controlPlaneId) || "") : a.config.app === "kongManager" && (u = u.replace(/\/{workspace}/gi, (
|
|
4571
|
+
return a.config.app === "konnect" ? u = u.replace(/{controlPlaneId}/gi, ((g = a.config) == null ? void 0 : g.controlPlaneId) || "") : a.config.app === "kongManager" && (u = u.replace(/\/{workspace}/gi, (P = a.config) != null && P.workspace ? `/${a.config.workspace}` : "")), u = u.replace(/{id}/gi, a.gatewayServiceId), u;
|
|
4572
4572
|
}), ot = (u) => {
|
|
4573
4573
|
let g = "";
|
|
4574
4574
|
u.url && (g = new URL(u.url).protocol), (["https", "wss", "tls"].includes(u.protocol) || ["https", "wss", "tls"].includes(g)) && (u.tls_verify = u.tls_verify_enabled ? u.tls_verify_value : null), delete u.tls_verify_enabled, delete u.tls_verify_value;
|
|
4575
4575
|
}, Ce = () => {
|
|
4576
|
-
var g,
|
|
4576
|
+
var g, P;
|
|
4577
4577
|
const u = {
|
|
4578
4578
|
name: s.fields.name || null,
|
|
4579
4579
|
tags: s.fields.tags ? (g = s.fields.tags) == null ? void 0 : g.split(",").filter((re) => re !== "") : null,
|
|
@@ -4585,7 +4585,7 @@ const Ji = (e, i) => {
|
|
|
4585
4585
|
connect_timeout: s.fields.connect_timeout,
|
|
4586
4586
|
tls_verify_value: s.fields.tls_verify_value,
|
|
4587
4587
|
tls_verify_enabled: s.fields.tls_verify_enabled,
|
|
4588
|
-
ca_certificates: s.fields.ca_certificates ? (
|
|
4588
|
+
ca_certificates: s.fields.ca_certificates ? (P = s.fields.ca_certificates) == null ? void 0 : P.split(",").filter((re) => re !== "") : null,
|
|
4589
4589
|
client_certificate: s.fields.client_certificate ? { id: s.fields.client_certificate } : null,
|
|
4590
4590
|
write_timeout: s.fields.write_timeout,
|
|
4591
4591
|
port: s.fields.port,
|
|
@@ -4593,14 +4593,14 @@ const Ji = (e, i) => {
|
|
|
4593
4593
|
};
|
|
4594
4594
|
return s.fields.client_certificate && ["https", "wss", "tls"].includes(s.fields.protocol) && (u.client_certificate = { id: s.fields.client_certificate }), s.fields.tls_verify_enabled && ["https", "wss", "tls"].includes(s.fields.protocol) && (u.tls_verify = s.fields.tls_verify_value), G.value || (u.path = null), p.value === "create" ? w.value === "url" ? (delete u.protocol, delete u.host, delete u.path, a.config.app === "konnect" && delete u.port) : delete u.url : p.value === "edit" && delete u.url, u;
|
|
4595
4595
|
}, Oe = async () => {
|
|
4596
|
-
var u, g,
|
|
4596
|
+
var u, g, P, re;
|
|
4597
4597
|
try {
|
|
4598
|
-
s.isReadonly = !0,
|
|
4598
|
+
s.isReadonly = !0, B();
|
|
4599
4599
|
const oe = Ce();
|
|
4600
4600
|
let ce;
|
|
4601
4601
|
if (ot(oe), await d.post(at.value, oe), p.value === "create" ? ce = await d.post(Me.value, oe) : p.value === "edit" && (ce = ((u = a.config) == null ? void 0 : u.app) === "konnect" ? await d.put(Me.value, oe) : await d.patch(Me.value, oe)), ce) {
|
|
4602
4602
|
const { data: C } = ce;
|
|
4603
|
-
s.fields.name = (C == null ? void 0 : C.name) || "", s.fields.port = C.port || x.getPortFromProtocol(C.protocol), s.fields.protocol = (C == null ? void 0 : C.protocol) || "http", s.fields.host = (C == null ? void 0 : C.host) || "", s.fields.path = (C == null ? void 0 : C.path) || "", s.fields.url = (C == null ? void 0 : C.url) || "", s.fields.retries = ((C == null ? void 0 : C.retries) || (C == null ? void 0 : C.retries) === 0) ?? 5, s.fields.connect_timeout = ((C == null ? void 0 : C.connect_timeout) || (C == null ? void 0 : C.connect_timeout) === 0) ?? 6e4, s.fields.write_timeout = ((C == null ? void 0 : C.write_timeout) || (C == null ? void 0 : C.write_timeout) === 0) ?? 6e4, s.fields.read_timeout = ((C == null ? void 0 : C.read_timeout) || (C == null ? void 0 : C.read_timeout) === 0) ?? 6e4, s.fields.client_certificate = ((g = C == null ? void 0 : C.client_certificate) == null ? void 0 : g.id) || "", s.fields.ca_certificates = (
|
|
4603
|
+
s.fields.name = (C == null ? void 0 : C.name) || "", s.fields.port = C.port || x.getPortFromProtocol(C.protocol), s.fields.protocol = (C == null ? void 0 : C.protocol) || "http", s.fields.host = (C == null ? void 0 : C.host) || "", s.fields.path = (C == null ? void 0 : C.path) || "", s.fields.url = (C == null ? void 0 : C.url) || "", s.fields.retries = ((C == null ? void 0 : C.retries) || (C == null ? void 0 : C.retries) === 0) ?? 5, s.fields.connect_timeout = ((C == null ? void 0 : C.connect_timeout) || (C == null ? void 0 : C.connect_timeout) === 0) ?? 6e4, s.fields.write_timeout = ((C == null ? void 0 : C.write_timeout) || (C == null ? void 0 : C.write_timeout) === 0) ?? 6e4, s.fields.read_timeout = ((C == null ? void 0 : C.read_timeout) || (C == null ? void 0 : C.read_timeout) === 0) ?? 6e4, s.fields.client_certificate = ((g = C == null ? void 0 : C.client_certificate) == null ? void 0 : g.id) || "", s.fields.ca_certificates = (P = C == null ? void 0 : C.ca_certificates) != null && P.length ? C == null ? void 0 : C.ca_certificates.join(",") : "", s.fields.tls_verify_enabled = (C == null ? void 0 : C.tls_verify) !== "" && (C == null ? void 0 : C.tls_verify) !== null && (C == null ? void 0 : C.tls_verify) !== void 0, s.fields.tls_verify_value = s.fields.tls_verify_enabled && (C == null ? void 0 : C.tls_verify), s.fields.tags = (re = C == null ? void 0 : C.tags) != null && re.length ? C == null ? void 0 : C.tags.join(",") : "", Object.assign(I, s.fields), t("update", ce == null ? void 0 : ce.data);
|
|
4604
4604
|
}
|
|
4605
4605
|
return ce;
|
|
4606
4606
|
} catch (oe) {
|
|
@@ -4616,12 +4616,12 @@ const Ji = (e, i) => {
|
|
|
4616
4616
|
}), Xt(() => {
|
|
4617
4617
|
t("model-updated", Ce());
|
|
4618
4618
|
}), i({
|
|
4619
|
-
validateUrl:
|
|
4619
|
+
validateUrl: B,
|
|
4620
4620
|
getPayload: Ce,
|
|
4621
4621
|
saveFormData: Oe,
|
|
4622
4622
|
canSubmit: Z
|
|
4623
4623
|
}), (u, g) => {
|
|
4624
|
-
const
|
|
4624
|
+
const P = j("KInput"), re = j("KLabel"), oe = j("KRadio"), ce = j("KSelect"), C = j("KCheckbox"), Y = j("KCollapse");
|
|
4625
4625
|
return h(), A("div", Xl, [
|
|
4626
4626
|
k(m(dl), {
|
|
4627
4627
|
"can-submit": Z.value,
|
|
@@ -4650,7 +4650,7 @@ const Ji = (e, i) => {
|
|
|
4650
4650
|
title: m(n)("gateway_services.form.sections.general.title")
|
|
4651
4651
|
}, {
|
|
4652
4652
|
default: v(() => [
|
|
4653
|
-
k(
|
|
4653
|
+
k(P, {
|
|
4654
4654
|
modelValue: s.fields.name,
|
|
4655
4655
|
"onUpdate:modelValue": g[0] || (g[0] = (E) => s.fields.name = E),
|
|
4656
4656
|
modelModifiers: { trim: !0 },
|
|
@@ -4666,7 +4666,7 @@ const Ji = (e, i) => {
|
|
|
4666
4666
|
type: "text",
|
|
4667
4667
|
onInput: ae
|
|
4668
4668
|
}, null, 8, ["modelValue", "error-message", "has-error", "label", "label-attributes", "placeholder", "readonly"]),
|
|
4669
|
-
k(
|
|
4669
|
+
k(P, {
|
|
4670
4670
|
modelValue: s.fields.tags,
|
|
4671
4671
|
"onUpdate:modelValue": g[1] || (g[1] = (E) => s.fields.tags = E),
|
|
4672
4672
|
modelModifiers: { trim: !0 },
|
|
@@ -4722,7 +4722,7 @@ const Ji = (e, i) => {
|
|
|
4722
4722
|
}, 8, ["modelValue", "selected-value"])
|
|
4723
4723
|
]),
|
|
4724
4724
|
w.value === "url" ? (h(), A("div", as, [
|
|
4725
|
-
k(
|
|
4725
|
+
k(P, {
|
|
4726
4726
|
modelValue: s.fields.url,
|
|
4727
4727
|
"onUpdate:modelValue": g[3] || (g[3] = (E) => s.fields.url = E),
|
|
4728
4728
|
modelModifiers: { trim: !0 },
|
|
@@ -4769,7 +4769,7 @@ const Ji = (e, i) => {
|
|
|
4769
4769
|
width: "100%",
|
|
4770
4770
|
onSelected: g[6] || (g[6] = (E) => J(s.fields.protocol, E))
|
|
4771
4771
|
}, null, 8, ["modelValue", "label", "label-attributes", "readonly"]),
|
|
4772
|
-
k(
|
|
4772
|
+
k(P, {
|
|
4773
4773
|
modelValue: s.fields.host,
|
|
4774
4774
|
"onUpdate:modelValue": g[7] || (g[7] = (E) => s.fields.host = E),
|
|
4775
4775
|
modelModifiers: { trim: !0 },
|
|
@@ -4784,7 +4784,7 @@ const Ji = (e, i) => {
|
|
|
4784
4784
|
required: ""
|
|
4785
4785
|
}, null, 8, ["modelValue", "label", "label-attributes", "placeholder"]),
|
|
4786
4786
|
G.value ? (h(), A("div", rs, [
|
|
4787
|
-
k(
|
|
4787
|
+
k(P, {
|
|
4788
4788
|
modelValue: s.fields.path,
|
|
4789
4789
|
"onUpdate:modelValue": g[8] || (g[8] = (E) => s.fields.path = E),
|
|
4790
4790
|
modelModifiers: { trim: !0 },
|
|
@@ -4798,7 +4798,7 @@ const Ji = (e, i) => {
|
|
|
4798
4798
|
placeholder: m(n)("gateway_services.form.fields.path.placeholder")
|
|
4799
4799
|
}, null, 8, ["modelValue", "label", "label-attributes", "placeholder"])
|
|
4800
4800
|
])) : q("", !0),
|
|
4801
|
-
k(
|
|
4801
|
+
k(P, {
|
|
4802
4802
|
modelValue: s.fields.port,
|
|
4803
4803
|
"onUpdate:modelValue": [
|
|
4804
4804
|
g[9] || (g[9] = (E) => s.fields.port = E),
|
|
@@ -4827,7 +4827,7 @@ const Ji = (e, i) => {
|
|
|
4827
4827
|
default: v(() => [
|
|
4828
4828
|
V("div", ns, [
|
|
4829
4829
|
V("div", ls, [
|
|
4830
|
-
k(
|
|
4830
|
+
k(P, {
|
|
4831
4831
|
modelValue: s.fields.retries,
|
|
4832
4832
|
"onUpdate:modelValue": [
|
|
4833
4833
|
g[11] || (g[11] = (E) => s.fields.retries = E),
|
|
@@ -4845,7 +4845,7 @@ const Ji = (e, i) => {
|
|
|
4845
4845
|
}, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
|
|
4846
4846
|
]),
|
|
4847
4847
|
V("div", ss, [
|
|
4848
|
-
k(
|
|
4848
|
+
k(P, {
|
|
4849
4849
|
modelValue: s.fields.connect_timeout,
|
|
4850
4850
|
"onUpdate:modelValue": [
|
|
4851
4851
|
g[13] || (g[13] = (E) => s.fields.connect_timeout = E),
|
|
@@ -4863,7 +4863,7 @@ const Ji = (e, i) => {
|
|
|
4863
4863
|
}, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
|
|
4864
4864
|
]),
|
|
4865
4865
|
V("div", cs, [
|
|
4866
|
-
k(
|
|
4866
|
+
k(P, {
|
|
4867
4867
|
modelValue: s.fields.write_timeout,
|
|
4868
4868
|
"onUpdate:modelValue": [
|
|
4869
4869
|
g[15] || (g[15] = (E) => s.fields.write_timeout = E),
|
|
@@ -4881,7 +4881,7 @@ const Ji = (e, i) => {
|
|
|
4881
4881
|
}, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
|
|
4882
4882
|
]),
|
|
4883
4883
|
V("div", us, [
|
|
4884
|
-
k(
|
|
4884
|
+
k(P, {
|
|
4885
4885
|
modelValue: s.fields.read_timeout,
|
|
4886
4886
|
"onUpdate:modelValue": [
|
|
4887
4887
|
g[17] || (g[17] = (E) => s.fields.read_timeout = E),
|
|
@@ -4899,7 +4899,7 @@ const Ji = (e, i) => {
|
|
|
4899
4899
|
}, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
|
|
4900
4900
|
]),
|
|
4901
4901
|
X.value ? (h(), A("div", ds, [
|
|
4902
|
-
k(
|
|
4902
|
+
k(P, {
|
|
4903
4903
|
modelValue: s.fields.client_certificate,
|
|
4904
4904
|
"onUpdate:modelValue": g[19] || (g[19] = (E) => s.fields.client_certificate = E),
|
|
4905
4905
|
modelModifiers: { trim: !0 },
|
|
@@ -4914,7 +4914,7 @@ const Ji = (e, i) => {
|
|
|
4914
4914
|
}, null, 8, ["modelValue", "label", "label-attributes", "placeholder", "readonly"])
|
|
4915
4915
|
])) : q("", !0),
|
|
4916
4916
|
H.value ? (h(), A("div", ps, [
|
|
4917
|
-
k(
|
|
4917
|
+
k(P, {
|
|
4918
4918
|
modelValue: s.fields.ca_certificates,
|
|
4919
4919
|
"onUpdate:modelValue": g[20] || (g[20] = (E) => s.fields.ca_certificates = E),
|
|
4920
4920
|
modelModifiers: { trim: !0 },
|
|
@@ -5135,7 +5135,7 @@ const As = /* @__PURE__ */ Ji(gs, [["__scopeId", "data-v-02a1f1c7"]]), vs = { cl
|
|
|
5135
5135
|
})
|
|
5136
5136
|
]),
|
|
5137
5137
|
tls_verify: v((f) => [
|
|
5138
|
-
D(O(m(r)("rowValue", f)
|
|
5138
|
+
D(O(typeof m(r)("rowValue", f) == "boolean" ? l("rowValue", f) : m(t)("gateway_services.form.fields.tls_verify_option.unset.display")), 1)
|
|
5139
5139
|
]),
|
|
5140
5140
|
client_certificate: v((f) => [
|
|
5141
5141
|
D(O(m(r)("rowValue", f) ? m(r)("rowValue", f).id : "–"), 1)
|