@kong-ui-public/entities-upstreams-targets 2.1.17 → 2.1.18
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.
|
@@ -222,7 +222,7 @@ function cr(e, l, t, a = {
|
|
|
222
222
|
const { axiosInstance: s } = Kt({
|
|
223
223
|
headers: e.requestHeaders
|
|
224
224
|
}), { i18n: { t: i } } = Et(), { debounce: r } = Zs(), c = r(async ($) => {
|
|
225
|
-
await
|
|
225
|
+
await F($);
|
|
226
226
|
}, 200), o = P(!1), d = P(""), h = P(""), p = P([]), m = P([]), n = P(void 0), A = u(l);
|
|
227
227
|
let _ = `${e.apiBaseUrl}${A}`;
|
|
228
228
|
e.app === "konnect" ? _ = _.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" && (_ = _.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : ""));
|
|
@@ -236,7 +236,7 @@ function cr(e, l, t, a = {
|
|
|
236
236
|
} finally {
|
|
237
237
|
o.value = !1;
|
|
238
238
|
}
|
|
239
|
-
}, H = P(""),
|
|
239
|
+
}, H = P(""), F = async ($) => {
|
|
240
240
|
var B, T, D;
|
|
241
241
|
if (H.value !== $)
|
|
242
242
|
if (H.value = $ || "", n.value === void 0)
|
|
@@ -364,7 +364,9 @@ function fr(e, l, t = "data") {
|
|
|
364
364
|
return { fetcher: async (c) => {
|
|
365
365
|
try {
|
|
366
366
|
r.value = { status: Te.Loading };
|
|
367
|
-
|
|
367
|
+
let o = i(c);
|
|
368
|
+
o.includes("filter[name]") && (o = `${o}&page[size]=${c.pageSize}&page[number]=${c.page}`);
|
|
369
|
+
const { data: d } = await s.get(o), h = t && t.replace(/[^\w-_]/gi, "");
|
|
368
370
|
let p;
|
|
369
371
|
d[h] && Array.isArray(d[h]) ? p = d[h] : Array.isArray(d) ? p = d : p = Object.keys(d).length ? [d] : [];
|
|
370
372
|
const m = {
|
|
@@ -500,7 +502,7 @@ const he = {
|
|
|
500
502
|
}, qr = /* @__PURE__ */ Ar(() => /* @__PURE__ */ x("path", {
|
|
501
503
|
d: "M5 22C4.45 22 3.97917 21.8042 3.5875 21.4125C3.19583 21.0208 3 20.55 3 20V6H5V20H16V22H5ZM9 18C8.45 18 7.97917 17.8042 7.5875 17.4125C7.19583 17.0208 7 16.55 7 16V4C7 3.45 7.19583 2.97917 7.5875 2.5875C7.97917 2.19583 8.45 2 9 2H18C18.55 2 19.0208 2.19583 19.4125 2.5875C19.8042 2.97917 20 3.45 20 4V16C20 16.55 19.8042 17.0208 19.4125 17.4125C19.0208 17.8042 18.55 18 18 18H9ZM9 16H18V4H9V16Z",
|
|
502
504
|
fill: "currentColor"
|
|
503
|
-
}, null, -1)),
|
|
505
|
+
}, null, -1)), Ur = /* @__PURE__ */ le({
|
|
504
506
|
__name: "CopyIcon",
|
|
505
507
|
props: {
|
|
506
508
|
/** The accessibility text provided to screen readers */
|
|
@@ -593,7 +595,7 @@ const he = {
|
|
|
593
595
|
_: 1
|
|
594
596
|
}, 8, ["aria-hidden", "style"]));
|
|
595
597
|
}
|
|
596
|
-
}),
|
|
598
|
+
}), Fr = /* @__PURE__ */ Hr(Ur, [["__scopeId", "data-v-ac7fcfb4"]]), $r = "16px", Mr = { class: "kong-ui-copy-uuid" }, jr = ["onClick"], gl = 15, Nr = /* @__PURE__ */ le({
|
|
597
599
|
__name: "CopyUuid",
|
|
598
600
|
props: {
|
|
599
601
|
uuid: {
|
|
@@ -696,7 +698,7 @@ const he = {
|
|
|
696
698
|
tabindex: "0",
|
|
697
699
|
onClick: Ct((b) => m(g), ["stop"])
|
|
698
700
|
}, [
|
|
699
|
-
y(u(
|
|
701
|
+
y(u(Fr), {
|
|
700
702
|
class: "uuid-icon",
|
|
701
703
|
color: e.iconColor,
|
|
702
704
|
decorative: !!e.tooltip,
|
|
@@ -1018,15 +1020,15 @@ const he = {
|
|
|
1018
1020
|
key: 0,
|
|
1019
1021
|
"data-testid": `${e.item.key}-badge-tags`
|
|
1020
1022
|
}, [
|
|
1021
|
-
(k(!0), E(de, null, ve(e.item.value, (
|
|
1023
|
+
(k(!0), E(de, null, ve(e.item.value, (F, $) => (k(), L(b, {
|
|
1022
1024
|
key: `${e.item.key}-badge-tag-${$}`,
|
|
1023
1025
|
class: "config-badge",
|
|
1024
1026
|
"data-testid": `${e.item.key}-badge-tag-${$}`,
|
|
1025
|
-
tooltip:
|
|
1027
|
+
tooltip: F,
|
|
1026
1028
|
"truncation-tooltip": ""
|
|
1027
1029
|
}, {
|
|
1028
1030
|
default: f(() => [
|
|
1029
|
-
Y(S(
|
|
1031
|
+
Y(S(F), 1)
|
|
1030
1032
|
]),
|
|
1031
1033
|
_: 2
|
|
1032
1034
|
}, 1032, ["data-testid", "tooltip"]))), 128))
|
|
@@ -1036,24 +1038,24 @@ const he = {
|
|
|
1036
1038
|
class: "copy-uuid-array",
|
|
1037
1039
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
1038
1040
|
}, [
|
|
1039
|
-
(k(!0), E(de, null, ve(e.item.value, (
|
|
1041
|
+
(k(!0), E(de, null, ve(e.item.value, (F, $) => (k(), L(u(zl), _t(p.value.childAttrs, {
|
|
1040
1042
|
key: `${e.item.key}-copy-uuid-${$}`,
|
|
1041
1043
|
"data-testid": `${e.item.key}-copy-uuid-${$}`,
|
|
1042
|
-
uuid:
|
|
1044
|
+
uuid: F
|
|
1043
1045
|
}), null, 16, ["data-testid", "uuid"]))), 128))
|
|
1044
1046
|
], 8, ai)) : p.value.additionalComponent === "KMethodBadge" ? (k(), E("div", {
|
|
1045
1047
|
key: 2,
|
|
1046
1048
|
class: "method-badge-array",
|
|
1047
1049
|
"data-testid": `${e.item.key}-badge-methods`
|
|
1048
1050
|
}, [
|
|
1049
|
-
(k(!0), E(de, null, ve(e.item.value, (
|
|
1051
|
+
(k(!0), E(de, null, ve(e.item.value, (F, $) => (k(), L(b, {
|
|
1050
1052
|
key: `${e.item.key}-badge-method-${$}`,
|
|
1051
|
-
appearance: Object.values(u(Ys)).includes(
|
|
1053
|
+
appearance: Object.values(u(Ys)).includes(F.toLowerCase()) ? F.toLowerCase() : "custom",
|
|
1052
1054
|
class: "config-badge",
|
|
1053
1055
|
"data-testid": `${e.item.key}-badge-method-${$}`
|
|
1054
1056
|
}, {
|
|
1055
1057
|
default: f(() => [
|
|
1056
|
-
Y(S(
|
|
1058
|
+
Y(S(F), 1)
|
|
1057
1059
|
]),
|
|
1058
1060
|
_: 2
|
|
1059
1061
|
}, 1032, ["appearance", "data-testid"]))), 128))
|
|
@@ -1062,11 +1064,11 @@ const he = {
|
|
|
1062
1064
|
key: 3,
|
|
1063
1065
|
"data-testid": `${t.item.key}-json-array-content`
|
|
1064
1066
|
}, [
|
|
1065
|
-
(k(!0), E(de, null, ve(e.item.value, (
|
|
1067
|
+
(k(!0), E(de, null, ve(e.item.value, (F, $) => (k(), L(Jl, {
|
|
1066
1068
|
key: `json-array-item-${$}`,
|
|
1067
1069
|
index: $,
|
|
1068
1070
|
"is-array-item": "",
|
|
1069
|
-
item:
|
|
1071
|
+
item: F
|
|
1070
1072
|
}, null, 8, ["index", "item"]))), 128))
|
|
1071
1073
|
], 8, si)) : (k(), L(H, {
|
|
1072
1074
|
key: 4,
|
|
@@ -1367,10 +1369,10 @@ var as = new fe("tag:yaml.org,2002:bool", {
|
|
|
1367
1369
|
function qi(e) {
|
|
1368
1370
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1369
1371
|
}
|
|
1370
|
-
function
|
|
1372
|
+
function Ui(e) {
|
|
1371
1373
|
return 48 <= e && e <= 55;
|
|
1372
1374
|
}
|
|
1373
|
-
function
|
|
1375
|
+
function Fi(e) {
|
|
1374
1376
|
return 48 <= e && e <= 57;
|
|
1375
1377
|
}
|
|
1376
1378
|
function $i(e) {
|
|
@@ -1403,7 +1405,7 @@ function $i(e) {
|
|
|
1403
1405
|
if (s === "o") {
|
|
1404
1406
|
for (t++; t < l; t++)
|
|
1405
1407
|
if (s = e[t], s !== "_") {
|
|
1406
|
-
if (!
|
|
1408
|
+
if (!Ui(e.charCodeAt(t)))
|
|
1407
1409
|
return !1;
|
|
1408
1410
|
a = !0;
|
|
1409
1411
|
}
|
|
@@ -1414,7 +1416,7 @@ function $i(e) {
|
|
|
1414
1416
|
return !1;
|
|
1415
1417
|
for (; t < l; t++)
|
|
1416
1418
|
if (s = e[t], s !== "_") {
|
|
1417
|
-
if (!
|
|
1419
|
+
if (!Fi(e.charCodeAt(t)))
|
|
1418
1420
|
return !1;
|
|
1419
1421
|
a = !0;
|
|
1420
1422
|
}
|
|
@@ -1682,7 +1684,7 @@ var fs = new fe("tag:yaml.org,2002:set", {
|
|
|
1682
1684
|
ps,
|
|
1683
1685
|
fs
|
|
1684
1686
|
]
|
|
1685
|
-
}),
|
|
1687
|
+
}), Ue = Object.prototype.hasOwnProperty, rt = 1, ms = 2, gs = 3, it = 4, kt = 1, on = 2, vl = 3, un = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, cn = /[\x85\u2028\u2029]/, dn = /[,\[\]\{\}]/, ys = /^(?:!|!!|![a-z\-]+!)$/i, vs = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1686
1688
|
function bl(e) {
|
|
1687
1689
|
return Object.prototype.toString.call(e);
|
|
1688
1690
|
}
|
|
@@ -1748,7 +1750,7 @@ var Cl = {
|
|
|
1748
1750
|
},
|
|
1749
1751
|
TAG: function(e, l, t) {
|
|
1750
1752
|
var a, s;
|
|
1751
|
-
t.length !== 2 && R(e, "TAG directive accepts exactly two arguments"), a = t[0], s = t[1], ys.test(a) || R(e, "ill-formed tag handle (first argument) of the TAG directive"),
|
|
1753
|
+
t.length !== 2 && R(e, "TAG directive accepts exactly two arguments"), a = t[0], s = t[1], ys.test(a) || R(e, "ill-formed tag handle (first argument) of the TAG directive"), Ue.call(e.tagMap, a) && R(e, 'there is a previously declared suffix for "' + a + '" tag handle'), vs.test(s) || R(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1752
1754
|
try {
|
|
1753
1755
|
s = decodeURIComponent(s);
|
|
1754
1756
|
} catch {
|
|
@@ -1771,7 +1773,7 @@ function qe(e, l, t, a) {
|
|
|
1771
1773
|
function _l(e, l, t, a) {
|
|
1772
1774
|
var s, i, r, c;
|
|
1773
1775
|
for (ce.isObject(t) || R(e, "cannot merge mappings; the provided source object is unacceptable"), s = Object.keys(t), r = 0, c = s.length; r < c; r += 1)
|
|
1774
|
-
i = s[r],
|
|
1776
|
+
i = s[r], Ue.call(l, i) || (l[i] = t[i], a[i] = !0);
|
|
1775
1777
|
}
|
|
1776
1778
|
function Be(e, l, t, a, s, i, r, c, o) {
|
|
1777
1779
|
var d, h;
|
|
@@ -1785,7 +1787,7 @@ function Be(e, l, t, a, s, i, r, c, o) {
|
|
|
1785
1787
|
else
|
|
1786
1788
|
_l(e, l, i, t);
|
|
1787
1789
|
else
|
|
1788
|
-
!e.json && !
|
|
1790
|
+
!e.json && !Ue.call(t, s) && Ue.call(l, s) && (e.line = r || e.line, e.lineStart = c || e.lineStart, e.position = o || e.position, R(e, "duplicated mapping key")), s === "__proto__" ? Object.defineProperty(l, s, {
|
|
1789
1791
|
configurable: !0,
|
|
1790
1792
|
enumerable: !0,
|
|
1791
1793
|
writable: !0,
|
|
@@ -2015,7 +2017,7 @@ function wn(e) {
|
|
|
2015
2017
|
} catch {
|
|
2016
2018
|
R(e, "tag name is malformed: " + i);
|
|
2017
2019
|
}
|
|
2018
|
-
return t ? e.tag = i :
|
|
2020
|
+
return t ? e.tag = i : Ue.call(e.tagMap, s) ? e.tag = e.tagMap[s] + i : s === "!" ? e.tag = "!" + i : s === "!!" ? e.tag = "tag:yaml.org,2002:" + i : R(e, 'undeclared tag handle "' + s + '"'), !0;
|
|
2019
2021
|
}
|
|
2020
2022
|
function Sn(e) {
|
|
2021
2023
|
var l, t;
|
|
@@ -2031,7 +2033,7 @@ function In(e) {
|
|
|
2031
2033
|
return !1;
|
|
2032
2034
|
for (a = e.input.charCodeAt(++e.position), l = e.position; a !== 0 && !ke(a) && !Pe(a); )
|
|
2033
2035
|
a = e.input.charCodeAt(++e.position);
|
|
2034
|
-
return e.position === l && R(e, "name of an alias node must contain at least one character"), t = e.input.slice(l, e.position),
|
|
2036
|
+
return e.position === l && R(e, "name of an alias node must contain at least one character"), t = e.input.slice(l, e.position), Ue.call(e.anchorMap, t) || R(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], ue(e, !0, -1), !0;
|
|
2035
2037
|
}
|
|
2036
2038
|
function Je(e, l, t, a, s) {
|
|
2037
2039
|
var i, r, c, o = 1, d = !1, h = !1, p, m, n, A, _, g;
|
|
@@ -2047,7 +2049,7 @@ function Je(e, l, t, a, s) {
|
|
|
2047
2049
|
break;
|
|
2048
2050
|
}
|
|
2049
2051
|
} else if (e.tag !== "!") {
|
|
2050
|
-
if (
|
|
2052
|
+
if (Ue.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
2051
2053
|
A = e.typeMap[e.kind || "fallback"][e.tag];
|
|
2052
2054
|
else
|
|
2053
2055
|
for (A = null, n = e.typeMap.multi[e.kind || "fallback"], p = 0, m = n.length; p < m; p += 1)
|
|
@@ -2079,7 +2081,7 @@ function xn(e) {
|
|
|
2079
2081
|
r = e.input.charCodeAt(++e.position);
|
|
2080
2082
|
s.push(e.input.slice(t, e.position));
|
|
2081
2083
|
}
|
|
2082
|
-
r !== 0 && Lt(e),
|
|
2084
|
+
r !== 0 && Lt(e), Ue.call(Cl, a) ? Cl[a](e, a, s) : nt(e, 'unknown document directive "' + a + '"');
|
|
2083
2085
|
}
|
|
2084
2086
|
if (ue(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, ue(e, !0, -1)) : i && R(e, "directives end mark is expected"), Je(e, e.lineIndent - 1, it, !1, !0), ue(e, !0, -1), e.checkLineBreaks && cn.test(e.input.slice(l, e.position)) && nt(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && ht(e)) {
|
|
2085
2087
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, ue(e, !0, -1));
|
|
@@ -2119,7 +2121,7 @@ function An(e, l) {
|
|
|
2119
2121
|
var Tn = Hn, On = An, ws = {
|
|
2120
2122
|
loadAll: Tn,
|
|
2121
2123
|
load: On
|
|
2122
|
-
}, Ss = Object.prototype.toString, Is = Object.prototype.hasOwnProperty, Dt = 65279, qn = 9, Ze = 10,
|
|
2124
|
+
}, Ss = Object.prototype.toString, Is = Object.prototype.hasOwnProperty, Dt = 65279, qn = 9, Ze = 10, Un = 13, Fn = 32, $n = 33, Mn = 34, St = 35, jn = 37, Nn = 38, Kn = 39, En = 42, xs = 44, Pn = 45, ot = 58, Bn = 61, Vn = 62, Ln = 63, Rn = 64, Hs = 91, As = 93, Dn = 96, Ts = 123, zn = 124, Os = 125, ge = {};
|
|
2123
2125
|
ge[0] = "\\0";
|
|
2124
2126
|
ge[7] = "\\a";
|
|
2125
2127
|
ge[8] = "\\b";
|
|
@@ -2196,13 +2198,13 @@ function Xn(e, l) {
|
|
|
2196
2198
|
return !1;
|
|
2197
2199
|
}
|
|
2198
2200
|
function ut(e) {
|
|
2199
|
-
return e ===
|
|
2201
|
+
return e === Fn || e === qn;
|
|
2200
2202
|
}
|
|
2201
2203
|
function Xe(e) {
|
|
2202
2204
|
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== Dt || 65536 <= e && e <= 1114111;
|
|
2203
2205
|
}
|
|
2204
2206
|
function Il(e) {
|
|
2205
|
-
return Xe(e) && e !== Dt && e !==
|
|
2207
|
+
return Xe(e) && e !== Dt && e !== Un && e !== Ze;
|
|
2206
2208
|
}
|
|
2207
2209
|
function xl(e, l, t) {
|
|
2208
2210
|
var a = Il(e), s = a && !ut(e);
|
|
@@ -2228,7 +2230,7 @@ function qs(e) {
|
|
|
2228
2230
|
var l = /^\n* /;
|
|
2229
2231
|
return l.test(e);
|
|
2230
2232
|
}
|
|
2231
|
-
var
|
|
2233
|
+
var Us = 1, xt = 2, Fs = 3, $s = 4, Ee = 5;
|
|
2232
2234
|
function ao(e, l, t, a, s, i, r, c) {
|
|
2233
2235
|
var o, d = 0, h = null, p = !1, m = !1, n = a !== -1, A = -1, _ = eo(Qe(e, 0)) && to(Qe(e, e.length - 1));
|
|
2234
2236
|
if (l || r)
|
|
@@ -2248,7 +2250,7 @@ function ao(e, l, t, a, s, i, r, c) {
|
|
|
2248
2250
|
}
|
|
2249
2251
|
m = m || n && o - A - 1 > a && e[A + 1] !== " ";
|
|
2250
2252
|
}
|
|
2251
|
-
return !p && !m ? _ && !r && !s(e) ?
|
|
2253
|
+
return !p && !m ? _ && !r && !s(e) ? Us : i === Ge ? Ee : xt : t > 9 && qs(e) ? Ee : r ? i === Ge ? Ee : xt : m ? $s : Fs;
|
|
2252
2254
|
}
|
|
2253
2255
|
function lo(e, l, t, a, s) {
|
|
2254
2256
|
e.dump = function() {
|
|
@@ -2270,11 +2272,11 @@ function lo(e, l, t, a, s) {
|
|
|
2270
2272
|
e.forceQuotes && !a,
|
|
2271
2273
|
s
|
|
2272
2274
|
)) {
|
|
2273
|
-
case
|
|
2275
|
+
case Us:
|
|
2274
2276
|
return l;
|
|
2275
2277
|
case xt:
|
|
2276
2278
|
return "'" + l.replace(/'/g, "''") + "'";
|
|
2277
|
-
case
|
|
2279
|
+
case Fs:
|
|
2278
2280
|
return "|" + Hl(l, e.indent) + Al(Sl(l, i));
|
|
2279
2281
|
case $s:
|
|
2280
2282
|
return ">" + Hl(l, e.indent) + Al(Sl(so(l, r), i));
|
|
@@ -2467,10 +2469,10 @@ const To = {
|
|
|
2467
2469
|
}, Oo = ["data-testid"], qo = {
|
|
2468
2470
|
key: 0,
|
|
2469
2471
|
class: "config-card-prop-section-title"
|
|
2470
|
-
},
|
|
2472
|
+
}, Uo = {
|
|
2471
2473
|
key: 1,
|
|
2472
2474
|
class: "config-card-display-json"
|
|
2473
|
-
},
|
|
2475
|
+
}, Fo = {
|
|
2474
2476
|
key: 0,
|
|
2475
2477
|
class: "config-card-display-json-endpoint"
|
|
2476
2478
|
}, $o = {
|
|
@@ -2556,8 +2558,8 @@ const To = {
|
|
|
2556
2558
|
]), 1032, ["item"]))), 128))
|
|
2557
2559
|
], 10, Oo))), 128))
|
|
2558
2560
|
])) : Q("", !0),
|
|
2559
|
-
e.format === "json" ? (k(), E("div",
|
|
2560
|
-
l.fetcherUrl ? (k(), E("div",
|
|
2561
|
+
e.format === "json" ? (k(), E("div", Uo, [
|
|
2562
|
+
l.fetcherUrl ? (k(), E("div", Fo, [
|
|
2561
2563
|
y(h, { appearance: "get" }, {
|
|
2562
2564
|
default: f(() => [
|
|
2563
2565
|
Y(S(u(a)("baseConfigCard.endpoints.get")), 1)
|
|
@@ -2591,7 +2593,7 @@ const To = {
|
|
|
2591
2593
|
], 64);
|
|
2592
2594
|
};
|
|
2593
2595
|
}
|
|
2594
|
-
}), jo = /* @__PURE__ */ Ce(Mo, [["__scopeId", "data-v-27f85338"]]),
|
|
2596
|
+
}), jo = /* @__PURE__ */ Ce(Mo, [["__scopeId", "data-v-27f85338"]]), Ul = "24px", No = (e, l) => {
|
|
2595
2597
|
const t = e.__vccOpts || e;
|
|
2596
2598
|
for (const [a, s] of l)
|
|
2597
2599
|
t[a] = s;
|
|
@@ -2633,7 +2635,7 @@ const To = {
|
|
|
2633
2635
|
size: {
|
|
2634
2636
|
type: [Number, String],
|
|
2635
2637
|
required: !1,
|
|
2636
|
-
default:
|
|
2638
|
+
default: Ul,
|
|
2637
2639
|
// if setting to the imported const fails, just pass a number of 24 as the default.
|
|
2638
2640
|
validator: (e) => {
|
|
2639
2641
|
if (typeof e == "number" && e > 0)
|
|
@@ -2662,7 +2664,7 @@ const To = {
|
|
|
2662
2664
|
if (i && !isNaN(i) && Number.isInteger(i) && i > 0)
|
|
2663
2665
|
return `${i}px`;
|
|
2664
2666
|
}
|
|
2665
|
-
return
|
|
2667
|
+
return Ul;
|
|
2666
2668
|
}), a = q(() => ({
|
|
2667
2669
|
boxSizing: "border-box",
|
|
2668
2670
|
color: l.color,
|
|
@@ -2845,18 +2847,18 @@ const To = {
|
|
|
2845
2847
|
return Z[1] - J[1];
|
|
2846
2848
|
}), K.map((Z) => {
|
|
2847
2849
|
var J, z;
|
|
2848
|
-
const G = Z[0], X = (J = b.value) == null ? void 0 : J[G],
|
|
2850
|
+
const G = Z[0], X = (J = b.value) == null ? void 0 : J[G], U = ((z = s.configSchema) == null ? void 0 : z[G]) || {}, W = n[G];
|
|
2849
2851
|
return {
|
|
2850
2852
|
key: G,
|
|
2851
2853
|
value: X,
|
|
2852
|
-
hidden:
|
|
2853
|
-
type:
|
|
2854
|
-
label:
|
|
2855
|
-
tooltip:
|
|
2856
|
-
section:
|
|
2854
|
+
hidden: U.hidden || !1,
|
|
2855
|
+
type: U.type ?? ((W == null ? void 0 : W.type) || re.Text),
|
|
2856
|
+
label: U.label ?? ((W == null ? void 0 : W.label) || o(G)),
|
|
2857
|
+
tooltip: U.tooltip ?? ((W == null ? void 0 : W.tooltip) || void 0),
|
|
2858
|
+
section: U.section ?? ((W == null ? void 0 : W.section) || oe.Advanced)
|
|
2857
2859
|
};
|
|
2858
2860
|
}).filter((Z) => !Z.hidden && Z.key !== s.pluginConfigKey);
|
|
2859
|
-
}),
|
|
2861
|
+
}), F = q(() => {
|
|
2860
2862
|
var O, N;
|
|
2861
2863
|
if (!b.value || !s.pluginConfigKey)
|
|
2862
2864
|
return [];
|
|
@@ -2886,7 +2888,7 @@ const To = {
|
|
|
2886
2888
|
return {
|
|
2887
2889
|
basic: (O = H.value) == null ? void 0 : O.filter((V) => V.section === oe.Basic),
|
|
2888
2890
|
advanced: (N = H.value) == null ? void 0 : N.filter((V) => V.section === oe.Advanced),
|
|
2889
|
-
plugin: (K =
|
|
2891
|
+
plugin: (K = F.value) == null ? void 0 : K.concat((I = H.value) == null ? void 0 : I.filter((V) => V.section === oe.Plugin))
|
|
2890
2892
|
};
|
|
2891
2893
|
}), B = q(() => {
|
|
2892
2894
|
const O = [];
|
|
@@ -2966,7 +2968,7 @@ const To = {
|
|
|
2966
2968
|
key: 0,
|
|
2967
2969
|
appearance: "tertiary",
|
|
2968
2970
|
"data-testid": "json-copy-button",
|
|
2969
|
-
onClick: (
|
|
2971
|
+
onClick: (U) => j(X)
|
|
2970
2972
|
}, {
|
|
2971
2973
|
default: f(() => [
|
|
2972
2974
|
Y(S(u(r)("baseConfigCard.actions.copy")), 1)
|
|
@@ -3004,9 +3006,9 @@ const To = {
|
|
|
3004
3006
|
}, Oe({ _: 2 }, [
|
|
3005
3007
|
ve(Object.keys(O.$slots), (X) => ({
|
|
3006
3008
|
name: X,
|
|
3007
|
-
fn: f(({ row:
|
|
3009
|
+
fn: f(({ row: U, rowValue: W }) => [
|
|
3008
3010
|
ae(O.$slots, X, {
|
|
3009
|
-
row:
|
|
3011
|
+
row: U,
|
|
3010
3012
|
rowValue: W
|
|
3011
3013
|
}, void 0, !0)
|
|
3012
3014
|
])
|
|
@@ -3019,25 +3021,25 @@ const To = {
|
|
|
3019
3021
|
"data-testid": `config-card-details-${X}-props`
|
|
3020
3022
|
}, [
|
|
3021
3023
|
X !== "basic" ? (k(), E("div", Yo, S(X === "advanced" ? u(r)("baseConfigCard.sections.advanced") : u(r)("baseConfigCard.sections.plugin")), 1)) : Q("", !0),
|
|
3022
|
-
(k(!0), E(de, null, ve($.value[X], (
|
|
3023
|
-
key:
|
|
3024
|
-
item:
|
|
3024
|
+
(k(!0), E(de, null, ve($.value[X], (U) => (k(), L(Pt, {
|
|
3025
|
+
key: U.key,
|
|
3026
|
+
item: U
|
|
3025
3027
|
}, Oe({
|
|
3026
3028
|
label: f(() => [
|
|
3027
|
-
ae(O.$slots, `${
|
|
3029
|
+
ae(O.$slots, `${U.key}-label`, { row: U }, void 0, !0)
|
|
3028
3030
|
]),
|
|
3029
|
-
[
|
|
3030
|
-
ae(O.$slots,
|
|
3031
|
-
row:
|
|
3031
|
+
[U.key]: f(({ rowValue: W }) => [
|
|
3032
|
+
ae(O.$slots, U.key, {
|
|
3033
|
+
row: U,
|
|
3032
3034
|
rowValue: W
|
|
3033
3035
|
}, void 0, !0)
|
|
3034
3036
|
]),
|
|
3035
3037
|
_: 2
|
|
3036
3038
|
}, [
|
|
3037
|
-
T(
|
|
3039
|
+
T(U) ? {
|
|
3038
3040
|
name: "label-tooltip",
|
|
3039
3041
|
fn: f(() => [
|
|
3040
|
-
ae(O.$slots, `${
|
|
3042
|
+
ae(O.$slots, `${U.key}-label-tooltip`, { row: U }, void 0, !0)
|
|
3041
3043
|
]),
|
|
3042
3044
|
key: "0"
|
|
3043
3045
|
} : void 0
|
|
@@ -3120,8 +3122,8 @@ const To = {
|
|
|
3120
3122
|
var b, H;
|
|
3121
3123
|
if (!s.editId)
|
|
3122
3124
|
return "";
|
|
3123
|
-
let
|
|
3124
|
-
return s.config.app === "konnect" ?
|
|
3125
|
+
let F = `${s.config.apiBaseUrl}${s.fetchUrl}`;
|
|
3126
|
+
return s.config.app === "konnect" ? F = F.replace(/{controlPlaneId}/gi, ((b = s.config) == null ? void 0 : b.controlPlaneId) || "") : s.config.app === "kongManager" && (F = F.replace(/\/{workspace}/gi, (H = s.config) != null && H.workspace ? `/${s.config.workspace}` : "")), F = F.replace(/{id}/gi, s.editId), F;
|
|
3125
3127
|
}), A = () => {
|
|
3126
3128
|
s.config.cancelRoute ? i.push(s.config.cancelRoute) : _();
|
|
3127
3129
|
}, _ = () => {
|
|
@@ -3144,10 +3146,10 @@ const To = {
|
|
|
3144
3146
|
d.value = !1;
|
|
3145
3147
|
}
|
|
3146
3148
|
}), (b, H) => {
|
|
3147
|
-
const
|
|
3149
|
+
const F = M("KSkeleton"), $ = M("KEmptyState"), B = M("KAlert"), T = M("KButton"), D = M("KCard");
|
|
3148
3150
|
return k(), L(D, { class: "kong-ui-entity-base-form" }, {
|
|
3149
3151
|
default: f(() => [
|
|
3150
|
-
d.value ? (k(), L(
|
|
3152
|
+
d.value ? (k(), L(F, {
|
|
3151
3153
|
key: 0,
|
|
3152
3154
|
type: "form"
|
|
3153
3155
|
})) : h.value ? (k(), L($, {
|
|
@@ -3442,7 +3444,7 @@ const To = {
|
|
|
3442
3444
|
a("click:row", T);
|
|
3443
3445
|
}), g = (B) => {
|
|
3444
3446
|
a("sort", B);
|
|
3445
|
-
}, { setTablePreferences: b, getTablePreferences: H } = Xs(),
|
|
3447
|
+
}, { setTablePreferences: b, getTablePreferences: H } = Xs(), F = q(() => {
|
|
3446
3448
|
const B = H(t.preferencesStorageKey);
|
|
3447
3449
|
return {
|
|
3448
3450
|
...t.initialFetcherParams,
|
|
@@ -3480,7 +3482,7 @@ const To = {
|
|
|
3480
3482
|
"has-error": i.value.hasError,
|
|
3481
3483
|
headers: o.value,
|
|
3482
3484
|
"hide-pagination-when-optional": "",
|
|
3483
|
-
"initial-fetcher-params":
|
|
3485
|
+
"initial-fetcher-params": F.value,
|
|
3484
3486
|
"is-loading": e.isLoading,
|
|
3485
3487
|
"pagination-type": e.paginationType,
|
|
3486
3488
|
"row-attrs": d,
|
|
@@ -3678,7 +3680,7 @@ const To = {
|
|
|
3678
3680
|
width: "20",
|
|
3679
3681
|
x: "0",
|
|
3680
3682
|
y: "0"
|
|
3681
|
-
}, pu = ["fill"], fu = { mask: "url(#mask0_180_20349)" }, mu = ["fill"],
|
|
3683
|
+
}, pu = ["fill"], fu = { mask: "url(#mask0_180_20349)" }, mu = ["fill"], Fl = /* @__PURE__ */ le({
|
|
3682
3684
|
__name: "IconFilter",
|
|
3683
3685
|
props: {
|
|
3684
3686
|
color: {
|
|
@@ -3728,8 +3730,8 @@ const To = {
|
|
|
3728
3730
|
setup(e, { emit: l }) {
|
|
3729
3731
|
const { i18n: { t } } = he.useI18n(), a = e, s = l, i = P(!1), r = P({}), c = q(() => {
|
|
3730
3732
|
const b = [];
|
|
3731
|
-
return new URLSearchParams(a.modelValue).forEach((H,
|
|
3732
|
-
H !== "" && b.push(
|
|
3733
|
+
return new URLSearchParams(a.modelValue).forEach((H, F) => {
|
|
3734
|
+
H !== "" && b.push(F);
|
|
3733
3735
|
}), b;
|
|
3734
3736
|
}), o = q(() => {
|
|
3735
3737
|
const b = a.config.fields;
|
|
@@ -3739,8 +3741,8 @@ const To = {
|
|
|
3739
3741
|
}));
|
|
3740
3742
|
});
|
|
3741
3743
|
be(() => a.modelValue, (b) => {
|
|
3742
|
-
r.value = {}, new URLSearchParams(b).forEach((H,
|
|
3743
|
-
r.value[
|
|
3744
|
+
r.value = {}, new URLSearchParams(b).forEach((H, F) => {
|
|
3745
|
+
r.value[F] = H;
|
|
3744
3746
|
});
|
|
3745
3747
|
});
|
|
3746
3748
|
const d = () => {
|
|
@@ -3748,14 +3750,14 @@ const To = {
|
|
|
3748
3750
|
}, h = (b) => {
|
|
3749
3751
|
s("update:modelValue", b);
|
|
3750
3752
|
}, p = (b) => `filter-${b}`, m = (b) => {
|
|
3751
|
-
var H,
|
|
3752
|
-
return (((
|
|
3753
|
+
var H, F;
|
|
3754
|
+
return (((F = (H = a.config.schema) == null ? void 0 : H[b]) == null ? void 0 : F.values) ?? []).map(($) => ({
|
|
3753
3755
|
value: $,
|
|
3754
3756
|
label: $
|
|
3755
3757
|
}));
|
|
3756
3758
|
}, n = (b) => {
|
|
3757
|
-
var H,
|
|
3758
|
-
return ((
|
|
3759
|
+
var H, F;
|
|
3760
|
+
return ((F = (H = a.config.schema) == null ? void 0 : H[b]) == null ? void 0 : F.type) ?? "text";
|
|
3759
3761
|
}, A = (b) => {
|
|
3760
3762
|
r.value = {
|
|
3761
3763
|
...r.value,
|
|
@@ -3764,12 +3766,12 @@ const To = {
|
|
|
3764
3766
|
}, _ = () => {
|
|
3765
3767
|
r.value = {}, g(!0);
|
|
3766
3768
|
}, g = (b = !1) => {
|
|
3767
|
-
const H = Object.keys(r.value).reduce((
|
|
3769
|
+
const H = Object.keys(r.value).reduce((F, $) => (r.value[$] && (F[$] = `${r.value[$]}`), F), {});
|
|
3768
3770
|
b && (i.value = !1), s("update:modelValue", new URLSearchParams(H).toString());
|
|
3769
3771
|
};
|
|
3770
3772
|
return (b, H) => {
|
|
3771
|
-
const
|
|
3772
|
-
return e.config.isExactMatch ? (k(), L(
|
|
3773
|
+
const F = M("KInput"), $ = M("KButton"), B = M("KSelect"), T = M("KMenuItem"), D = M("KMenu");
|
|
3774
|
+
return e.config.isExactMatch ? (k(), L(F, {
|
|
3773
3775
|
key: 0,
|
|
3774
3776
|
autocomplete: "off",
|
|
3775
3777
|
class: "kong-ui-entity-filter-input",
|
|
@@ -3779,7 +3781,7 @@ const To = {
|
|
|
3779
3781
|
"onUpdate:modelValue": h
|
|
3780
3782
|
}, {
|
|
3781
3783
|
before: f(() => [
|
|
3782
|
-
y(
|
|
3784
|
+
y(Fl)
|
|
3783
3785
|
]),
|
|
3784
3786
|
_: 1
|
|
3785
3787
|
}, 8, ["model-value", "placeholder"])) : (k(), E("div", gu, [
|
|
@@ -3789,7 +3791,7 @@ const To = {
|
|
|
3789
3791
|
onClick: d
|
|
3790
3792
|
}, {
|
|
3791
3793
|
default: f(() => [
|
|
3792
|
-
y(
|
|
3794
|
+
y(Fl),
|
|
3793
3795
|
Y(" " + S(u(t)("filter.filterButtonText")) + " " + S(c.value.length > 0 ? `(${c.value.length})` : ""), 1)
|
|
3794
3796
|
]),
|
|
3795
3797
|
_: 1
|
|
@@ -3832,7 +3834,7 @@ const To = {
|
|
|
3832
3834
|
appearance: "select",
|
|
3833
3835
|
items: m(j.value),
|
|
3834
3836
|
placeholder: u(t)("filter.selectPlaceholder")
|
|
3835
|
-
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (k(), L(
|
|
3837
|
+
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (k(), L(F, {
|
|
3836
3838
|
key: 1,
|
|
3837
3839
|
id: p(j.value),
|
|
3838
3840
|
modelValue: r.value[j.value],
|
|
@@ -3981,7 +3983,7 @@ const To = {
|
|
|
3981
3983
|
])
|
|
3982
3984
|
], 2));
|
|
3983
3985
|
}
|
|
3984
|
-
}), at = /* @__PURE__ */ Ce(Ou, [["__scopeId", "data-v-3565daa7"]]), { useAxios: pt, useDeleteUrlBuilder: Ks, useErrors: Es, useExternalLinkCreator: Nc, useFetchUrlBuilder: Kc, useFetcher: Ps, useDebouncedFilter: $l, useStringHelpers: Ec, useHelpers: qu, useGatewayFeatureSupported: Pc, useTruncationDetector: Bc } = he,
|
|
3986
|
+
}), at = /* @__PURE__ */ Ce(Ou, [["__scopeId", "data-v-3565daa7"]]), { useAxios: pt, useDeleteUrlBuilder: Ks, useErrors: Es, useExternalLinkCreator: Nc, useFetchUrlBuilder: Kc, useFetcher: Ps, useDebouncedFilter: $l, useStringHelpers: Ec, useHelpers: qu, useGatewayFeatureSupported: Pc, useTruncationDetector: Bc } = he, Uu = {
|
|
3985
3987
|
list: {
|
|
3986
3988
|
table_headers: {
|
|
3987
3989
|
id: "ID",
|
|
@@ -4267,7 +4269,7 @@ const To = {
|
|
|
4267
4269
|
labels: {
|
|
4268
4270
|
created_at: "Created at"
|
|
4269
4271
|
}
|
|
4270
|
-
},
|
|
4272
|
+
}, Fu = {
|
|
4271
4273
|
list: {
|
|
4272
4274
|
table_headers: {
|
|
4273
4275
|
id: "ID",
|
|
@@ -4336,8 +4338,8 @@ const To = {
|
|
|
4336
4338
|
}
|
|
4337
4339
|
}
|
|
4338
4340
|
}, $u = {
|
|
4339
|
-
upstreams:
|
|
4340
|
-
targets:
|
|
4341
|
+
upstreams: Uu,
|
|
4342
|
+
targets: Fu
|
|
4341
4343
|
};
|
|
4342
4344
|
function Mu() {
|
|
4343
4345
|
const e = Mt("en-us", $u);
|
|
@@ -4729,7 +4731,7 @@ const ct = [
|
|
|
4729
4731
|
label: "599",
|
|
4730
4732
|
value: "599"
|
|
4731
4733
|
}
|
|
4732
|
-
], At = 10, Tt = 65536, ju = 0, Nu = 65535, Re = 0, De = 255, Bs = 0, Vs = 255, Ku = 0, Eu = 65535, Ml = 0, jl = 65535, Pu = 0, Bu = 2 ** 31, Ot = ["200", "302"], qt = ["200", "201", "202", "203", "204", "205", "206", "207", "208", "226", "300", "301", "302", "303", "304", "305", "306", "307", "308"],
|
|
4734
|
+
], At = 10, Tt = 65536, ju = 0, Nu = 65535, Re = 0, De = 255, Bs = 0, Vs = 255, Ku = 0, Eu = 65535, Ml = 0, jl = 65535, Pu = 0, Bu = 2 ** 31, Ot = ["200", "302"], qt = ["200", "201", "202", "203", "204", "205", "206", "207", "208", "226", "300", "301", "302", "303", "304", "305", "306", "307", "308"], Ut = ["429", "404", "500", "501", "502", "503", "504", "505"], Ft = ["429", "500", "503"];
|
|
4733
4735
|
function ft() {
|
|
4734
4736
|
const e = (o) => /^\d+$/.test(o), l = (o, d, h) => {
|
|
4735
4737
|
if (e(o)) {
|
|
@@ -4771,7 +4773,7 @@ function ft() {
|
|
|
4771
4773
|
unhealthyInterval: "0",
|
|
4772
4774
|
httpFailures: "5",
|
|
4773
4775
|
tcpFailures: "5",
|
|
4774
|
-
unhealthyHttpStatuses:
|
|
4776
|
+
unhealthyHttpStatuses: Ut,
|
|
4775
4777
|
unhealthyTimeouts: "0"
|
|
4776
4778
|
},
|
|
4777
4779
|
passiveHealthCheck: {
|
|
@@ -4780,7 +4782,7 @@ function ft() {
|
|
|
4780
4782
|
httpStatuses: qt,
|
|
4781
4783
|
timeouts: "0",
|
|
4782
4784
|
httpFailures: "5",
|
|
4783
|
-
unhealthyHttpStatuses:
|
|
4785
|
+
unhealthyHttpStatuses: Ft,
|
|
4784
4786
|
tcpFailures: "5"
|
|
4785
4787
|
}
|
|
4786
4788
|
});
|
|
@@ -4790,9 +4792,9 @@ function ft() {
|
|
|
4790
4792
|
stringToNumberArray: t,
|
|
4791
4793
|
numberToStringArray: a,
|
|
4792
4794
|
upstreamsResponseToFields: (o) => {
|
|
4793
|
-
var h, p, m, n, A, _, g, b, H,
|
|
4795
|
+
var h, p, m, n, A, _, g, b, H, F, $, B, T, D, j, O, N, I, K, V, Z, J, z, G, X, U, W, te, C, v, w, ie, ee, ne, pe, se, me, Fe, Me, Jt, Wt, Qt, Yt, Zt, Gt, Xt, ea, ta, aa, la, sa, ra, ia, na, oa, ua, ca, da, ha, pa, fa, ma, ga, ya, va, ba, ka, Ca, _a, wa, Sa, Ia, xa, Ha, Aa, Ta, Oa, qa, Ua, Fa, $a, Ma, ja, Na, Ka, Ea, Pa, Ba, Va, La, Ra, Da, za, Ja, Wa, Qa, Ya, Za, Ga, Xa, el, tl, al, ll, sl, rl, il, nl, ol;
|
|
4794
4796
|
const d = s();
|
|
4795
|
-
return d.name = o.name || "", d.algorithm = o.algorithm || "round-robin", d.hostHeader = o.host_header || "", d.clientCertificate = o.client_certificate ? (h = o.client_certificate) == null ? void 0 : h.id : "", d.tags = ((p = o.tags) == null ? void 0 : p.join(", ")) || "", d.slots = o.slots !== null && o.slots !== void 0 ? o.slots.toString() : "10000", d.hashOn = o.hash_on || "none", d.hashFallback = o.hash_fallback || "none", d.hashOnHeader = o.hash_on_header || "", d.hashOnCookie = o.hash_on_cookie || "", d.hashOnCookiePath = o.hash_on_cookie_path || "/", d.hashOnQueryArgument = o.hash_on_query_arg || "", d.hashOnUriCapture = o.hash_on_uri_capture || "", d.hashFallbackHeader = o.hash_fallback_header || "", d.hashFallbackQueryArgument = o.hash_fallback_query_arg || "", d.hashFallbackUriCapture = o.hash_fallback_uri_capture || "", d.healthchecksThreshold = o.healthchecks.threshold !== null && o.healthchecks.threshold !== void 0 ? o.healthchecks.threshold.toString() : "", d.activeHealthSwitch = ((n = (m = o.healthchecks.active) == null ? void 0 : m.healthy) == null ? void 0 : n.interval) !== 0 || ((_ = (A = o.healthchecks.active) == null ? void 0 : A.unhealthy) == null ? void 0 : _.interval) !== 0, d.activeHealthCheck.type = ((g = o.healthchecks.active) == null ? void 0 : g.type) || "http", d.activeHealthCheck.httpPath = ((b = o.healthchecks.active) == null ? void 0 : b.http_path) || "/", d.activeHealthCheck.timeout = ((H = o.healthchecks.active) == null ? void 0 : H.timeout) !== null && ((
|
|
4797
|
+
return d.name = o.name || "", d.algorithm = o.algorithm || "round-robin", d.hostHeader = o.host_header || "", d.clientCertificate = o.client_certificate ? (h = o.client_certificate) == null ? void 0 : h.id : "", d.tags = ((p = o.tags) == null ? void 0 : p.join(", ")) || "", d.slots = o.slots !== null && o.slots !== void 0 ? o.slots.toString() : "10000", d.hashOn = o.hash_on || "none", d.hashFallback = o.hash_fallback || "none", d.hashOnHeader = o.hash_on_header || "", d.hashOnCookie = o.hash_on_cookie || "", d.hashOnCookiePath = o.hash_on_cookie_path || "/", d.hashOnQueryArgument = o.hash_on_query_arg || "", d.hashOnUriCapture = o.hash_on_uri_capture || "", d.hashFallbackHeader = o.hash_fallback_header || "", d.hashFallbackQueryArgument = o.hash_fallback_query_arg || "", d.hashFallbackUriCapture = o.hash_fallback_uri_capture || "", d.healthchecksThreshold = o.healthchecks.threshold !== null && o.healthchecks.threshold !== void 0 ? o.healthchecks.threshold.toString() : "", d.activeHealthSwitch = ((n = (m = o.healthchecks.active) == null ? void 0 : m.healthy) == null ? void 0 : n.interval) !== 0 || ((_ = (A = o.healthchecks.active) == null ? void 0 : A.unhealthy) == null ? void 0 : _.interval) !== 0, d.activeHealthCheck.type = ((g = o.healthchecks.active) == null ? void 0 : g.type) || "http", d.activeHealthCheck.httpPath = ((b = o.healthchecks.active) == null ? void 0 : b.http_path) || "/", d.activeHealthCheck.timeout = ((H = o.healthchecks.active) == null ? void 0 : H.timeout) !== null && ((F = o.healthchecks.active) == null ? void 0 : F.timeout) !== void 0 ? (B = ($ = o.healthchecks.active) == null ? void 0 : $.timeout) == null ? void 0 : B.toString() : "", d.activeHealthCheck.concurrency = ((T = o.healthchecks.active) == null ? void 0 : T.concurrency) !== null && ((D = o.healthchecks.active) == null ? void 0 : D.concurrency) !== void 0 ? (O = (j = o.healthchecks.active) == null ? void 0 : j.concurrency) == null ? void 0 : O.toString() : "", d.activeHealthCheck.httpsSni = ((N = o.healthchecks.active) == null ? void 0 : N.https_sni) || "", d.activeHealthCheck.verifySsl = ((I = o.healthchecks.active) == null ? void 0 : I.https_verify_certificate) || !1, d.activeHealthCheck.headers = (K = o.healthchecks.active) != null && K.headers && Object.entries((V = o.healthchecks.active) == null ? void 0 : V.headers).length > 0 ? Object.entries((Z = o.healthchecks.active) == null ? void 0 : Z.headers).map(([Ls, gt]) => ({ key: Ls, values: gt == null ? void 0 : gt.join(", ") })) : [{ key: "", values: "" }], d.activeHealthCheck.interval = ((z = (J = o.healthchecks.active) == null ? void 0 : J.healthy) == null ? void 0 : z.interval) !== null && ((X = (G = o.healthchecks.active) == null ? void 0 : G.healthy) == null ? void 0 : X.interval) !== void 0 ? (te = (W = (U = o.healthchecks.active) == null ? void 0 : U.healthy) == null ? void 0 : W.interval) == null ? void 0 : te.toString() : "0", d.activeHealthCheck.interval = ((v = (C = o.healthchecks.active) == null ? void 0 : C.healthy) == null ? void 0 : v.interval) !== null && ((ie = (w = o.healthchecks.active) == null ? void 0 : w.healthy) == null ? void 0 : ie.interval) !== void 0 ? (pe = (ne = (ee = o.healthchecks.active) == null ? void 0 : ee.healthy) == null ? void 0 : ne.interval) == null ? void 0 : pe.toString() : "0", d.activeHealthCheck.successes = ((me = (se = o.healthchecks.active) == null ? void 0 : se.healthy) == null ? void 0 : me.successes) !== null && ((Me = (Fe = o.healthchecks.active) == null ? void 0 : Fe.healthy) == null ? void 0 : Me.successes) !== void 0 ? (Qt = (Wt = (Jt = o.healthchecks.active) == null ? void 0 : Jt.healthy) == null ? void 0 : Wt.successes) == null ? void 0 : Qt.toString() : "0", d.activeHealthCheck.httpStatuses = (Zt = (Yt = o.healthchecks.active) == null ? void 0 : Yt.healthy) != null && Zt.http_statuses ? a(((Xt = (Gt = o.healthchecks.active) == null ? void 0 : Gt.healthy) == null ? void 0 : Xt.http_statuses) || []) : Ot, d.activeHealthCheck.unhealthyInterval = ((ta = (ea = o.healthchecks.active) == null ? void 0 : ea.unhealthy) == null ? void 0 : ta.interval) !== null && ((la = (aa = o.healthchecks.active) == null ? void 0 : aa.unhealthy) == null ? void 0 : la.interval) !== void 0 ? (ia = (ra = (sa = o.healthchecks.active) == null ? void 0 : sa.unhealthy) == null ? void 0 : ra.interval) == null ? void 0 : ia.toString() : "0", d.activeHealthCheck.httpFailures = ((oa = (na = o.healthchecks.active) == null ? void 0 : na.unhealthy) == null ? void 0 : oa.http_failures) !== null && ((ca = (ua = o.healthchecks.active) == null ? void 0 : ua.unhealthy) == null ? void 0 : ca.http_failures) !== void 0 ? (pa = (ha = (da = o.healthchecks.active) == null ? void 0 : da.unhealthy) == null ? void 0 : ha.http_failures) == null ? void 0 : pa.toString() : "0", d.activeHealthCheck.unhealthyTimeouts = ((ma = (fa = o.healthchecks.active) == null ? void 0 : fa.unhealthy) == null ? void 0 : ma.timeouts) !== null && ((ya = (ga = o.healthchecks.active) == null ? void 0 : ga.unhealthy) == null ? void 0 : ya.timeouts) !== void 0 ? (ka = (ba = (va = o.healthchecks.active) == null ? void 0 : va.unhealthy) == null ? void 0 : ba.timeouts) == null ? void 0 : ka.toString() : "0", d.activeHealthCheck.unhealthyHttpStatuses = (_a = (Ca = o.healthchecks.active) == null ? void 0 : Ca.unhealthy) != null && _a.http_statuses ? a(((Sa = (wa = o.healthchecks.active) == null ? void 0 : wa.unhealthy) == null ? void 0 : Sa.http_statuses) || []) : Ut, d.passiveHealthSwitch = ((xa = (Ia = o.healthchecks.passive) == null ? void 0 : Ia.healthy) == null ? void 0 : xa.successes) !== 0 || ((Aa = (Ha = o.healthchecks.passive) == null ? void 0 : Ha.unhealthy) == null ? void 0 : Aa.timeouts) !== 0 || ((Oa = (Ta = o.healthchecks.passive) == null ? void 0 : Ta.unhealthy) == null ? void 0 : Oa.tcp_failures) !== 0 || ((Ua = (qa = o.healthchecks.passive) == null ? void 0 : qa.unhealthy) == null ? void 0 : Ua.http_failures) !== 0, d.passiveHealthCheck.type = ((Fa = o.healthchecks.passive) == null ? void 0 : Fa.type) || "http", d.passiveHealthCheck.successes = ((Ma = ($a = o.healthchecks.passive) == null ? void 0 : $a.healthy) == null ? void 0 : Ma.successes) !== null && ((Na = (ja = o.healthchecks.passive) == null ? void 0 : ja.healthy) == null ? void 0 : Na.successes) !== void 0 ? (Pa = (Ea = (Ka = o.healthchecks.passive) == null ? void 0 : Ka.healthy) == null ? void 0 : Ea.successes) == null ? void 0 : Pa.toString() : "0", d.passiveHealthCheck.httpStatuses = (Va = (Ba = o.healthchecks.passive) == null ? void 0 : Ba.healthy) != null && Va.http_statuses ? a(((Ra = (La = o.healthchecks.passive) == null ? void 0 : La.healthy) == null ? void 0 : Ra.http_statuses) || []) : qt, d.passiveHealthCheck.timeouts = ((za = (Da = o.healthchecks.passive) == null ? void 0 : Da.unhealthy) == null ? void 0 : za.timeouts) !== null && ((Wa = (Ja = o.healthchecks.passive) == null ? void 0 : Ja.unhealthy) == null ? void 0 : Wa.timeouts) !== void 0 ? (Za = (Ya = (Qa = o.healthchecks.passive) == null ? void 0 : Qa.unhealthy) == null ? void 0 : Ya.timeouts) == null ? void 0 : Za.toString() : "0", d.passiveHealthCheck.tcpFailures = ((Xa = (Ga = o.healthchecks.passive) == null ? void 0 : Ga.unhealthy) == null ? void 0 : Xa.tcp_failures) !== null && ((tl = (el = o.healthchecks.passive) == null ? void 0 : el.unhealthy) == null ? void 0 : tl.tcp_failures) !== void 0 ? (sl = (ll = (al = o.healthchecks.passive) == null ? void 0 : al.unhealthy) == null ? void 0 : ll.tcp_failures) == null ? void 0 : sl.toString() : "", d.passiveHealthCheck.unhealthyHttpStatuses = (il = (rl = o.healthchecks.passive) == null ? void 0 : rl.unhealthy) != null && il.http_statuses ? a(((ol = (nl = o.healthchecks.passive) == null ? void 0 : nl.unhealthy) == null ? void 0 : ol.http_statuses) || []) : Ft, d;
|
|
4796
4798
|
},
|
|
4797
4799
|
getDefaultUpstreamFields: s,
|
|
4798
4800
|
objectsAreEqual: (o, d) => {
|
|
@@ -4885,18 +4887,18 @@ const He = {
|
|
|
4885
4887
|
tags: { label: s("upstreams.list.table_headers.tags"), sortable: !1 }
|
|
4886
4888
|
}, h = d, p = q(() => {
|
|
4887
4889
|
var W, te;
|
|
4888
|
-
let
|
|
4889
|
-
return a.config.app === "konnect" ?
|
|
4890
|
+
let U = `${a.config.apiBaseUrl}${We.list[a.config.app]}`;
|
|
4891
|
+
return a.config.app === "konnect" ? U = U.replace(/{controlPlaneId}/gi, ((W = a.config) == null ? void 0 : W.controlPlaneId) || "") : a.config.app === "kongManager" && (U = U.replace(/\/{workspace}/gi, (te = a.config) != null && te.workspace ? `/${a.config.workspace}` : "")), U;
|
|
4890
4892
|
}), m = P(""), n = q(() => {
|
|
4891
|
-
const
|
|
4892
|
-
if (
|
|
4893
|
+
const U = a.config.app === "konnect" || a.config.isExactMatch;
|
|
4894
|
+
if (U)
|
|
4893
4895
|
return {
|
|
4894
|
-
isExactMatch:
|
|
4896
|
+
isExactMatch: U,
|
|
4895
4897
|
placeholder: s("upstreams.search.placeholder")
|
|
4896
4898
|
};
|
|
4897
4899
|
const { name: W, slots: te } = d;
|
|
4898
4900
|
return {
|
|
4899
|
-
isExactMatch:
|
|
4901
|
+
isExactMatch: U,
|
|
4900
4902
|
fields: { name: W, slots: te },
|
|
4901
4903
|
schema: a.config.filterSchema
|
|
4902
4904
|
};
|
|
@@ -4904,50 +4906,50 @@ const He = {
|
|
|
4904
4906
|
m.value = "";
|
|
4905
4907
|
}, b = () => {
|
|
4906
4908
|
c.value++;
|
|
4907
|
-
}, H = P(null),
|
|
4908
|
-
const te =
|
|
4909
|
+
}, H = P(null), F = (U, W) => {
|
|
4910
|
+
const te = U.id;
|
|
4909
4911
|
if (!W(te)) {
|
|
4910
4912
|
t("copy:error", {
|
|
4911
|
-
entity:
|
|
4913
|
+
entity: U,
|
|
4912
4914
|
field: "id",
|
|
4913
4915
|
message: s("upstreams.errors.copy")
|
|
4914
4916
|
});
|
|
4915
4917
|
return;
|
|
4916
4918
|
}
|
|
4917
4919
|
t("copy:success", {
|
|
4918
|
-
entity:
|
|
4920
|
+
entity: U,
|
|
4919
4921
|
field: "id",
|
|
4920
4922
|
message: s("upstreams.copy.success", { val: te })
|
|
4921
4923
|
});
|
|
4922
|
-
}, $ = (
|
|
4923
|
-
const te = JSON.stringify(
|
|
4924
|
+
}, $ = (U, W) => {
|
|
4925
|
+
const te = JSON.stringify(U);
|
|
4924
4926
|
if (!W(te)) {
|
|
4925
4927
|
t("copy:error", {
|
|
4926
|
-
entity:
|
|
4928
|
+
entity: U,
|
|
4927
4929
|
message: s("upstreams.errors.copy")
|
|
4928
4930
|
});
|
|
4929
4931
|
return;
|
|
4930
4932
|
}
|
|
4931
4933
|
t("copy:success", {
|
|
4932
|
-
entity:
|
|
4934
|
+
entity: U,
|
|
4933
4935
|
message: s("upstreams.copy.success_brief")
|
|
4934
4936
|
});
|
|
4935
|
-
}, B = async (
|
|
4937
|
+
}, B = async (U) => {
|
|
4936
4938
|
var te;
|
|
4937
|
-
await ((te = a.canRetrieve) == null ? void 0 : te.call(a,
|
|
4938
|
-
}, T = (
|
|
4939
|
+
await ((te = a.canRetrieve) == null ? void 0 : te.call(a, U)) && i.push(a.config.getViewRoute(U.id));
|
|
4940
|
+
}, T = (U) => ({
|
|
4939
4941
|
label: s("upstreams.actions.view"),
|
|
4940
|
-
to: a.config.getViewRoute(
|
|
4941
|
-
}), D = (
|
|
4942
|
+
to: a.config.getViewRoute(U)
|
|
4943
|
+
}), D = (U) => ({
|
|
4942
4944
|
label: s("upstreams.actions.edit"),
|
|
4943
|
-
to: a.config.getEditRoute(
|
|
4944
|
-
}), j = P(void 0), O = P(!1), N = P(!1), I = P(""), K = Ks(a.config, p.value), V = (
|
|
4945
|
-
j.value =
|
|
4945
|
+
to: a.config.getEditRoute(U)
|
|
4946
|
+
}), j = P(void 0), O = P(!1), N = P(!1), I = P(""), K = Ks(a.config, p.value), V = (U) => {
|
|
4947
|
+
j.value = U, O.value = !0;
|
|
4946
4948
|
}, Z = () => {
|
|
4947
4949
|
O.value = !1;
|
|
4948
4950
|
}, J = async () => {
|
|
4949
|
-
var
|
|
4950
|
-
if ((
|
|
4951
|
+
var U, W, te;
|
|
4952
|
+
if ((U = j.value) != null && U.id) {
|
|
4951
4953
|
N.value = !0;
|
|
4952
4954
|
try {
|
|
4953
4955
|
await r.delete(K(j.value.id)), N.value = !1, O.value = !1, c.value++, t("delete:success", j.value);
|
|
@@ -4958,12 +4960,12 @@ const He = {
|
|
|
4958
4960
|
}
|
|
4959
4961
|
}
|
|
4960
4962
|
}, z = P(!0);
|
|
4961
|
-
be(_, (
|
|
4963
|
+
be(_, (U) => {
|
|
4962
4964
|
var W, te, C, v;
|
|
4963
|
-
if (Array.isArray((W =
|
|
4965
|
+
if (Array.isArray((W = U == null ? void 0 : U.response) == null ? void 0 : W.data) && (z.value = U.response.data.length > 0), U.status === Te.Error) {
|
|
4964
4966
|
H.value = {
|
|
4965
4967
|
title: s("upstreams.errors.general")
|
|
4966
|
-
}, (v = (C = (te =
|
|
4968
|
+
}, (v = (C = (te = U.error) == null ? void 0 : te.response) == null ? void 0 : C.data) != null && v.message && (H.value.message = U.error.response.data.message), t("error", U.error);
|
|
4967
4969
|
return;
|
|
4968
4970
|
}
|
|
4969
4971
|
H.value = null;
|
|
@@ -4976,7 +4978,7 @@ const He = {
|
|
|
4976
4978
|
});
|
|
4977
4979
|
return tt(async () => {
|
|
4978
4980
|
await a.canCreate() && (G.value.title = s("upstreams.list.empty_state.title"), G.value.ctaText = s("upstreams.actions.create"));
|
|
4979
|
-
}), (
|
|
4981
|
+
}), (U, W) => {
|
|
4980
4982
|
const te = M("KButton"), C = M("KBadge"), v = M("KTruncate"), w = M("KDropdownItem"), ie = M("KClipboardProvider");
|
|
4981
4983
|
return k(), E("div", Vu, [
|
|
4982
4984
|
y(u(js), {
|
|
@@ -5055,7 +5057,7 @@ const He = {
|
|
|
5055
5057
|
default: f(({ copyToClipboard: ne }) => [
|
|
5056
5058
|
y(w, {
|
|
5057
5059
|
"data-testid": "action-entity-copy-id",
|
|
5058
|
-
onClick: (pe) =>
|
|
5060
|
+
onClick: (pe) => F(ee, ne)
|
|
5059
5061
|
}, {
|
|
5060
5062
|
default: f(() => [
|
|
5061
5063
|
Y(S(u(s)("upstreams.actions.copy_id")), 1)
|
|
@@ -5229,7 +5231,7 @@ const He = {
|
|
|
5229
5231
|
var D, j, O, N;
|
|
5230
5232
|
let T = `${a.config.apiBaseUrl}${lt.form[a.config.app][o.value]}`;
|
|
5231
5233
|
return a.config.app === "konnect" ? T = T.replace(/{controlPlaneId}/gi, ((D = a.config) == null ? void 0 : D.controlPlaneId) || "").replace(/{upstreamId}/gi, ((j = a.config) == null ? void 0 : j.upstreamId) || "") : a.config.app === "kongManager" && (T = T.replace(/\/{workspace}/gi, (O = a.config) != null && O.workspace ? `/${a.config.workspace}` : "").replace(/{upstreamId}/gi, ((N = a.config) == null ? void 0 : N.upstreamId) || "")), T = T.replace(/{id}/gi, a.targetId), T;
|
|
5232
|
-
}),
|
|
5234
|
+
}), F = async () => {
|
|
5233
5235
|
var T, D, j, O, N;
|
|
5234
5236
|
try {
|
|
5235
5237
|
h.isReadonly = !0, h.errorMessage = "";
|
|
@@ -5261,7 +5263,7 @@ const He = {
|
|
|
5261
5263
|
"is-visible": e.isVisible,
|
|
5262
5264
|
title: d.value,
|
|
5263
5265
|
onCanceled: g,
|
|
5264
|
-
onProceed:
|
|
5266
|
+
onProceed: F
|
|
5265
5267
|
}, {
|
|
5266
5268
|
"body-content": f(() => [
|
|
5267
5269
|
x("div", Du, [
|
|
@@ -5419,7 +5421,7 @@ const He = {
|
|
|
5419
5421
|
});
|
|
5420
5422
|
}, H = (C) => {
|
|
5421
5423
|
z.value = C, G.value = !0;
|
|
5422
|
-
},
|
|
5424
|
+
}, F = (C) => a.config.app === "konnect" ? !1 : a.config.canMarkHealthy(C), $ = (C) => a.config.app === "konnect" ? !1 : a.config.canMarkUnhealthy(C), B = P(void 0), T = P(!1), D = P(!1), j = P(""), O = Ks(a.config, h.value), N = (C) => {
|
|
5423
5425
|
B.value = C, T.value = !0;
|
|
5424
5426
|
}, I = () => {
|
|
5425
5427
|
T.value = !1;
|
|
@@ -5472,8 +5474,8 @@ const He = {
|
|
|
5472
5474
|
requestHeaders: a.config.requestHeaders
|
|
5473
5475
|
}
|
|
5474
5476
|
})), z = P(""), G = P(!1), X = (C) => {
|
|
5475
|
-
z.value ? t("update:target", C) : t("create:target", C),
|
|
5476
|
-
},
|
|
5477
|
+
z.value ? t("update:target", C) : t("create:target", C), U();
|
|
5478
|
+
}, U = () => {
|
|
5477
5479
|
W(), r.value++;
|
|
5478
5480
|
}, W = () => {
|
|
5479
5481
|
G.value = !1, z.value = "";
|
|
@@ -5549,7 +5551,7 @@ const He = {
|
|
|
5549
5551
|
default: f(({ copyToClipboard: me }) => [
|
|
5550
5552
|
y(ne, {
|
|
5551
5553
|
"data-testid": "action-entity-copy-id",
|
|
5552
|
-
onClick: (
|
|
5554
|
+
onClick: (Fe) => g(se, me)
|
|
5553
5555
|
}, {
|
|
5554
5556
|
default: f(() => [
|
|
5555
5557
|
Y(S(u(s)("targets.actions.copy_id")), 1)
|
|
@@ -5563,7 +5565,7 @@ const He = {
|
|
|
5563
5565
|
default: f(({ copyToClipboard: me }) => [
|
|
5564
5566
|
y(ne, {
|
|
5565
5567
|
"data-testid": "action-entity-copy-json",
|
|
5566
|
-
onClick: (
|
|
5568
|
+
onClick: (Fe) => b(se, me)
|
|
5567
5569
|
}, {
|
|
5568
5570
|
default: f(() => [
|
|
5569
5571
|
Y(S(u(s)("targets.actions.copy_json")), 1)
|
|
@@ -5591,7 +5593,7 @@ const He = {
|
|
|
5591
5593
|
_: 2
|
|
5592
5594
|
}, 1032, ["auth-function"]),
|
|
5593
5595
|
y(u(Se), {
|
|
5594
|
-
"auth-function": () =>
|
|
5596
|
+
"auth-function": () => F(se)
|
|
5595
5597
|
}, {
|
|
5596
5598
|
default: f(() => [
|
|
5597
5599
|
y(ne, {
|
|
@@ -5724,15 +5726,15 @@ const He = {
|
|
|
5724
5726
|
}), b = q(() => {
|
|
5725
5727
|
var z, G, X;
|
|
5726
5728
|
const J = g.value && s.name.includes((z = _.value) == null ? void 0 : z.toLowerCase());
|
|
5727
|
-
return (X = d.value) == null ? void 0 : X.map((
|
|
5729
|
+
return (X = d.value) == null ? void 0 : X.map((U) => ({ label: U.host, value: U.id })).concat(
|
|
5728
5730
|
J ? [{ label: s.name, value: ((G = $.value) == null ? void 0 : G.value) || s.name }] : []
|
|
5729
5731
|
);
|
|
5730
5732
|
}), H = q(() => {
|
|
5731
5733
|
var J;
|
|
5732
5734
|
return (J = A.value) == null ? void 0 : J.map((z) => ({ label: z.id, value: z.id }));
|
|
5733
|
-
}),
|
|
5735
|
+
}), F = P(""), $ = P({ value: "", label: "" }), B = q(() => {
|
|
5734
5736
|
var J, z;
|
|
5735
|
-
return ((J = b.value.find((G) => G.value ===
|
|
5737
|
+
return ((J = b.value.find((G) => G.value === F.value)) == null ? void 0 : J.label) || ((z = $.value) == null ? void 0 : z.label);
|
|
5736
5738
|
}), T = (J) => {
|
|
5737
5739
|
_.value = J, r(J);
|
|
5738
5740
|
}, D = (J) => {
|
|
@@ -5740,17 +5742,17 @@ const He = {
|
|
|
5740
5742
|
}, j = () => {
|
|
5741
5743
|
$.value = { value: "", label: "" };
|
|
5742
5744
|
}, O = (J) => {
|
|
5743
|
-
|
|
5745
|
+
F.value = J, i("update:name", B.value);
|
|
5744
5746
|
}, N = P(!1);
|
|
5745
5747
|
return tt(async () => {
|
|
5746
5748
|
var J, z;
|
|
5747
5749
|
try {
|
|
5748
|
-
N.value = !0, await o(), s.name && (
|
|
5750
|
+
N.value = !0, await o(), s.name && (F.value = ((z = (J = b.value.find((G) => G.label === s.name)) == null ? void 0 : J.value) == null ? void 0 : z.toString()) || s.name), await n();
|
|
5749
5751
|
} finally {
|
|
5750
5752
|
N.value = !1;
|
|
5751
5753
|
}
|
|
5752
5754
|
}), (J, z) => {
|
|
5753
|
-
const G = M("KSkeleton"), X = M("KSelect"),
|
|
5755
|
+
const G = M("KSkeleton"), X = M("KSelect"), U = M("KInput");
|
|
5754
5756
|
return k(), L(u(at), {
|
|
5755
5757
|
class: "kong-ui-entities-upstreams-general-info",
|
|
5756
5758
|
description: u(a)("upstreams.form.general_info.help"),
|
|
@@ -5773,7 +5775,7 @@ const He = {
|
|
|
5773
5775
|
label: u(a)("upstreams.form.fields.name.label"),
|
|
5774
5776
|
"label-attributes": { tooltipAttributes: { "max-width": "250px" } },
|
|
5775
5777
|
loading: u(c),
|
|
5776
|
-
"model-value":
|
|
5778
|
+
"model-value": F.value,
|
|
5777
5779
|
placeholder: u(a)("upstreams.form.fields.name.placeholder"),
|
|
5778
5780
|
readonly: e.readonly,
|
|
5779
5781
|
required: "",
|
|
@@ -5796,7 +5798,7 @@ const He = {
|
|
|
5796
5798
|
]),
|
|
5797
5799
|
_: 1
|
|
5798
5800
|
}, 8, ["items", "label", "loading", "model-value", "placeholder", "readonly", "onUpdate:modelValue"]),
|
|
5799
|
-
y(
|
|
5801
|
+
y(U, {
|
|
5800
5802
|
autocomplete: "off",
|
|
5801
5803
|
class: "margin-bottom-6",
|
|
5802
5804
|
"data-testid": "upstreams-form-host-header",
|
|
@@ -5824,7 +5826,7 @@ const He = {
|
|
|
5824
5826
|
onQueryChange: u(p),
|
|
5825
5827
|
"onUpdate:modelValue": z[1] || (z[1] = (W) => i("update:client-certificate", W))
|
|
5826
5828
|
}, null, 8, ["items", "label", "label-attributes", "loading", "model-value", "placeholder", "readonly", "onQueryChange"]),
|
|
5827
|
-
y(
|
|
5829
|
+
y(U, {
|
|
5828
5830
|
autocomplete: "off",
|
|
5829
5831
|
"data-testid": "upstreams-form-tags",
|
|
5830
5832
|
help: u(a)("upstreams.form.fields.tags.help"),
|
|
@@ -6391,7 +6393,7 @@ const He = {
|
|
|
6391
6393
|
trackNewItems: h
|
|
6392
6394
|
} = et({ replaceId: !0 });
|
|
6393
6395
|
be(() => s.type, (_, g) => {
|
|
6394
|
-
g === "tcp" && _ !== g && i("update:tcp-failures", "5"), (g === "https" || g === "grpcs") && _ !== g && (i("update:https-sni", ""), i("update:verify-ssl", !1)), g !== "tcp" && _ === "tcp" && (i("update:http-path", "/"), i("update:http-statuses", Ot), i("update:unhealthy-http-statuses",
|
|
6396
|
+
g === "tcp" && _ !== g && i("update:tcp-failures", "5"), (g === "https" || g === "grpcs") && _ !== g && (i("update:https-sni", ""), i("update:verify-ssl", !1)), g !== "tcp" && _ === "tcp" && (i("update:http-path", "/"), i("update:http-statuses", Ot), i("update:unhealthy-http-statuses", Ut));
|
|
6395
6397
|
});
|
|
6396
6398
|
const p = P([{ key: "", values: "" }]);
|
|
6397
6399
|
be(() => s.headers, (_) => {
|
|
@@ -6408,7 +6410,7 @@ const He = {
|
|
|
6408
6410
|
_ === 0 && p.value.length === 1 ? p.value[0] = { key: "", values: "" } : p.value.splice(_, 1), m();
|
|
6409
6411
|
};
|
|
6410
6412
|
return (_, g) => {
|
|
6411
|
-
const b = M("KExternalLink"), H = M("KSelect"),
|
|
6413
|
+
const b = M("KExternalLink"), H = M("KSelect"), F = M("KInput"), $ = M("KCheckbox"), B = M("KLabel"), T = M("KIcon"), D = M("KButton"), j = M("KMultiselect"), O = M("KCard");
|
|
6412
6414
|
return k(), L(u(at), {
|
|
6413
6415
|
class: "kong-ui-entities-upstreams-active-healthcheck",
|
|
6414
6416
|
title: u(t)("upstreams.form.active_health_check.title")
|
|
@@ -6440,7 +6442,7 @@ const He = {
|
|
|
6440
6442
|
width: "100%",
|
|
6441
6443
|
"onUpdate:modelValue": g[0] || (g[0] = (I) => i("update:type", I))
|
|
6442
6444
|
}, null, 8, ["items", "label", "model-value", "readonly"]),
|
|
6443
|
-
o.value ? Q("", !0) : (k(), L(
|
|
6445
|
+
o.value ? Q("", !0) : (k(), L(F, {
|
|
6444
6446
|
key: 0,
|
|
6445
6447
|
autocomplete: "off",
|
|
6446
6448
|
"data-testid": "active-healthcheck-http-path",
|
|
@@ -6450,7 +6452,7 @@ const He = {
|
|
|
6450
6452
|
type: "text",
|
|
6451
6453
|
"onUpdate:modelValue": g[1] || (g[1] = (I) => i("update:http-path", I))
|
|
6452
6454
|
}, null, 8, ["label", "model-value", "readonly"])),
|
|
6453
|
-
y(
|
|
6455
|
+
y(F, {
|
|
6454
6456
|
autocomplete: "off",
|
|
6455
6457
|
"data-testid": "active-healthcheck-timeout",
|
|
6456
6458
|
label: u(t)("upstreams.form.fields.timeout.label"),
|
|
@@ -6461,7 +6463,7 @@ const He = {
|
|
|
6461
6463
|
type: "number",
|
|
6462
6464
|
"onUpdate:modelValue": g[2] || (g[2] = (I) => i("update:timeout", I))
|
|
6463
6465
|
}, null, 8, ["label", "max", "min", "model-value", "readonly"]),
|
|
6464
|
-
y(
|
|
6466
|
+
y(F, {
|
|
6465
6467
|
autocomplete: "off",
|
|
6466
6468
|
"data-testid": "active-healthcheck-concurrency",
|
|
6467
6469
|
label: u(t)("upstreams.form.fields.concurrency.label"),
|
|
@@ -6473,7 +6475,7 @@ const He = {
|
|
|
6473
6475
|
"onUpdate:modelValue": g[3] || (g[3] = (I) => i("update:concurrency", I))
|
|
6474
6476
|
}, null, 8, ["label", "max", "min", "model-value", "readonly"]),
|
|
6475
6477
|
c.value ? (k(), E(de, { key: 1 }, [
|
|
6476
|
-
y(
|
|
6478
|
+
y(F, {
|
|
6477
6479
|
autocomplete: "off",
|
|
6478
6480
|
class: "margin-bottom-6",
|
|
6479
6481
|
"data-testid": "active-healthcheck-https-sni",
|
|
@@ -6506,7 +6508,7 @@ const He = {
|
|
|
6506
6508
|
key: `${I.header}_${K}`,
|
|
6507
6509
|
class: Ie(["headers-row", { "margin-top-6": K > 0 }])
|
|
6508
6510
|
}, [
|
|
6509
|
-
y(
|
|
6511
|
+
y(F, {
|
|
6510
6512
|
modelValue: p.value[K].key,
|
|
6511
6513
|
"onUpdate:modelValue": (V) => p.value[K].key = V,
|
|
6512
6514
|
autocomplete: "off",
|
|
@@ -6515,7 +6517,7 @@ const He = {
|
|
|
6515
6517
|
type: "text",
|
|
6516
6518
|
onBlur: m
|
|
6517
6519
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "data-testid", "readonly"]),
|
|
6518
|
-
y(
|
|
6520
|
+
y(F, {
|
|
6519
6521
|
modelValue: p.value[K].values,
|
|
6520
6522
|
"onUpdate:modelValue": (V) => p.value[K].values = V,
|
|
6521
6523
|
autocomplete: "off",
|
|
@@ -6561,7 +6563,7 @@ const He = {
|
|
|
6561
6563
|
default: f(() => [
|
|
6562
6564
|
x("h5", mc, S(u(t)("upstreams.form.healthy.label")), 1),
|
|
6563
6565
|
x("p", gc, S(u(t)("upstreams.form.healthy.help")), 1),
|
|
6564
|
-
y(
|
|
6566
|
+
y(F, {
|
|
6565
6567
|
autocomplete: "off",
|
|
6566
6568
|
class: "margin-bottom-6",
|
|
6567
6569
|
"data-testid": "active-healthcheck-interval",
|
|
@@ -6574,7 +6576,7 @@ const He = {
|
|
|
6574
6576
|
type: "number",
|
|
6575
6577
|
"onUpdate:modelValue": g[6] || (g[6] = (I) => i("update:interval", I))
|
|
6576
6578
|
}, null, 8, ["help", "label", "max", "min", "model-value", "readonly"]),
|
|
6577
|
-
y(
|
|
6579
|
+
y(F, {
|
|
6578
6580
|
autocomplete: "off",
|
|
6579
6581
|
"data-testid": "active-healthcheck-successes",
|
|
6580
6582
|
label: u(t)("upstreams.form.fields.successes.label"),
|
|
@@ -6606,7 +6608,7 @@ const He = {
|
|
|
6606
6608
|
default: f(() => [
|
|
6607
6609
|
x("h5", yc, S(u(t)("upstreams.form.unhealthy.label")), 1),
|
|
6608
6610
|
x("p", vc, S(u(t)("upstreams.form.unhealthy.help")), 1),
|
|
6609
|
-
y(
|
|
6611
|
+
y(F, {
|
|
6610
6612
|
autocomplete: "off",
|
|
6611
6613
|
class: "margin-bottom-6",
|
|
6612
6614
|
"data-testid": "active-healthcheck-unhealthy-interval",
|
|
@@ -6619,7 +6621,7 @@ const He = {
|
|
|
6619
6621
|
type: "number",
|
|
6620
6622
|
"onUpdate:modelValue": g[11] || (g[11] = (I) => i("update:unhealthy-interval", I))
|
|
6621
6623
|
}, null, 8, ["help", "label", "max", "min", "model-value", "readonly"]),
|
|
6622
|
-
o.value ? (k(), L(
|
|
6624
|
+
o.value ? (k(), L(F, {
|
|
6623
6625
|
key: 0,
|
|
6624
6626
|
autocomplete: "off",
|
|
6625
6627
|
class: "margin-bottom-6",
|
|
@@ -6632,7 +6634,7 @@ const He = {
|
|
|
6632
6634
|
type: "number",
|
|
6633
6635
|
"onUpdate:modelValue": g[12] || (g[12] = (I) => i("update:tcp-failures", I))
|
|
6634
6636
|
}, null, 8, ["label", "max", "min", "model-value", "readonly"])) : (k(), E(de, { key: 1 }, [
|
|
6635
|
-
y(
|
|
6637
|
+
y(F, {
|
|
6636
6638
|
autocomplete: "off",
|
|
6637
6639
|
class: "margin-bottom-6",
|
|
6638
6640
|
"data-testid": "active-healthcheck-http-failures",
|
|
@@ -6658,7 +6660,7 @@ const He = {
|
|
|
6658
6660
|
"onUpdate:modelValue": g[16] || (g[16] = (I) => i("update:unhealthy-http-statuses", I))
|
|
6659
6661
|
}, null, 8, ["items", "label", "model-value", "readonly"])
|
|
6660
6662
|
], 64)),
|
|
6661
|
-
y(
|
|
6663
|
+
y(F, {
|
|
6662
6664
|
autocomplete: "off",
|
|
6663
6665
|
"data-testid": "active-healthcheck-unhealthy-timeouts",
|
|
6664
6666
|
label: u(t)("upstreams.form.fields.timeouts.label"),
|
|
@@ -6749,7 +6751,7 @@ const He = {
|
|
|
6749
6751
|
trackNewItems: o
|
|
6750
6752
|
} = et({ replaceId: !0 });
|
|
6751
6753
|
return be(() => a.type, (d, h) => {
|
|
6752
|
-
h === "tcp" && d !== h && s("update:tcp-failures", "5"), h !== "tcp" && d === "tcp" && (s("update:http-statuses", qt), s("update:unhealthy-http-statuses",
|
|
6754
|
+
h === "tcp" && d !== h && s("update:tcp-failures", "5"), h !== "tcp" && d === "tcp" && (s("update:http-statuses", qt), s("update:unhealthy-http-statuses", Ft));
|
|
6753
6755
|
}), (d, h) => {
|
|
6754
6756
|
const p = M("KExternalLink"), m = M("KSelect"), n = M("KInput"), A = M("KMultiselect"), _ = M("KCard");
|
|
6755
6757
|
return k(), L(u(at), {
|
|
@@ -6903,7 +6905,7 @@ const He = {
|
|
|
6903
6905
|
n.fields.activeHealthCheck.interval = C ? "5" : "0", n.fields.activeHealthCheck.successes = C ? "5" : "0", n.fields.activeHealthCheck.httpFailures = C ? "5" : "0", n.fields.activeHealthCheck.unhealthyInterval = C ? "5" : "0";
|
|
6904
6906
|
}, b = (C) => {
|
|
6905
6907
|
n.fields.passiveHealthCheck.timeouts = C ? "5" : "0", n.fields.passiveHealthCheck.successes = C ? "80" : "0";
|
|
6906
|
-
}, H = q(() => n.fields.slots ? s(n.fields.slots, At, Tt) : !0),
|
|
6908
|
+
}, H = q(() => n.fields.slots ? s(n.fields.slots, At, Tt) : !0), F = q(() => n.fields.hashOn === "header" ? !!n.fields.hashOnHeader : !0), $ = q(() => n.fields.hashOn === "cookie" || n.fields.hashFallback === "cookie" ? !!n.fields.hashOnCookie : !0), B = q(() => n.fields.hashOn === "cookie" || n.fields.hashFallback === "cookie" ? !!n.fields.hashOnCookiePath : !0), T = q(() => n.fields.hashOn === "query_arg" ? !!n.fields.hashOnQueryArgument : !0), D = q(() => n.fields.hashOn === "uri_capture" ? !!n.fields.hashOnUriCapture : !0), j = q(() => n.fields.hashFallback === "header" ? !!n.fields.hashFallbackHeader : !0), O = q(() => n.fields.hashFallback === "query_arg" ? !!n.fields.hashFallbackQueryArgument : !0), N = q(() => n.fields.hashFallback === "uri_capture" ? !!n.fields.hashFallbackUriCapture : !0), I = q(() => !!n.fields.name && H.value && F.value && $.value && B.value && T.value && D.value && j.value && O.value && N.value), K = q(() => t.upstreamId ? _e.Edit : _e.Create), V = q(() => {
|
|
6907
6909
|
var C, v;
|
|
6908
6910
|
return (v = We.form[(C = t.config) == null ? void 0 : C.app]) == null ? void 0 : v.edit;
|
|
6909
6911
|
}), Z = (C) => {
|
|
@@ -6930,10 +6932,10 @@ const He = {
|
|
|
6930
6932
|
healthy: {},
|
|
6931
6933
|
unhealthy: {}
|
|
6932
6934
|
}, n.fields.activeHealthCheck.timeout && (C.healthchecks.active.timeout = Number(n.fields.activeHealthCheck.timeout)), n.fields.activeHealthCheck.concurrency && (C.healthchecks.active.concurrency = Number(n.fields.activeHealthCheck.concurrency)), n.fields.activeHealthCheck.type !== "tcp" && n.fields.activeHealthCheck.httpPath && (C.healthchecks.active.http_path = n.fields.activeHealthCheck.httpPath), ((ie = t.config) == null ? void 0 : ie.app) === "kongManager" && (n.fields.activeHealthCheck.headers.length === 0 ? C.healthchecks.active.headers = [] : C.healthchecks.active.headers = n.fields.activeHealthCheck.headers.reduce((pe, se) => {
|
|
6933
|
-
var me,
|
|
6935
|
+
var me, Fe;
|
|
6934
6936
|
return se.key ? {
|
|
6935
6937
|
...pe,
|
|
6936
|
-
[se.key]: (
|
|
6938
|
+
[se.key]: (Fe = (me = se.values.split(",")) == null ? void 0 : me.map((Me) => String(Me || "").trim())) == null ? void 0 : Fe.filter((Me) => Me !== "")
|
|
6937
6939
|
} : {
|
|
6938
6940
|
...pe
|
|
6939
6941
|
};
|
|
@@ -6961,16 +6963,16 @@ const He = {
|
|
|
6961
6963
|
http_failures: 0
|
|
6962
6964
|
}
|
|
6963
6965
|
}), C;
|
|
6964
|
-
},
|
|
6966
|
+
}, U = (C) => {
|
|
6965
6967
|
var w, ie, ee, ne, pe, se;
|
|
6966
6968
|
let v = `${(w = t.config) == null ? void 0 : w.apiBaseUrl}${We.form[(ie = t.config) == null ? void 0 : ie.app][C]}`;
|
|
6967
6969
|
return ((ee = t.config) == null ? void 0 : ee.app) === "konnect" ? v = v.replace(/{controlPlaneId}/gi, ((ne = t.config) == null ? void 0 : ne.controlPlaneId) || "") : ((pe = t.config) == null ? void 0 : pe.app) === "kongManager" && (v = v.replace(/\/{workspace}/gi, (se = t.config) != null && se.workspace ? `/${t.config.workspace}` : "")), v = v.replace(/{id}/gi, t.upstreamId), v;
|
|
6968
6970
|
}, W = async () => {
|
|
6969
6971
|
var C;
|
|
6970
6972
|
try {
|
|
6971
|
-
n.readonly = !0, await h.post(
|
|
6973
|
+
n.readonly = !0, await h.post(U("validate"), X());
|
|
6972
6974
|
let v;
|
|
6973
|
-
K.value === _e.Create ? v = await h.post(
|
|
6975
|
+
K.value === _e.Create ? v = await h.post(U("create"), X()) : K.value === _e.Edit && (v = ((C = t.config) == null ? void 0 : C.app) === "konnect" ? await h.put(U("edit"), X()) : await h.patch(U("edit"), X())), a("update", v == null ? void 0 : v.data);
|
|
6974
6976
|
} catch (v) {
|
|
6975
6977
|
n.errorMessage = p(v), a("error", v);
|
|
6976
6978
|
} finally {
|