@kong-ui-public/entities-consumer-groups 2.1.17 → 2.1.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as oe, ref as E, computed as A, watch as Ae, renderSlot as X, createCommentVNode as J, unref as m, useSlots as ut, onBeforeMount as ct, resolveComponent as U, openBlock as f, createBlock as V, createSlots as je, withCtx as h, createElementVNode as D, createTextVNode as Q, toDisplayString as
|
|
1
|
+
import { defineComponent as oe, ref as E, computed as A, watch as Ae, renderSlot as X, createCommentVNode as J, unref as m, useSlots as ut, onBeforeMount as ct, resolveComponent as U, openBlock as f, createBlock as V, createSlots as je, withCtx as h, createElementVNode as D, createTextVNode as Q, toDisplayString as B, createVNode as K, createElementBlock as $, renderList as ve, Fragment as Ce, normalizeClass as Oe, withModifiers as rt, withDirectives as We, vShow as Ye, useCssVars as mn, resolveDynamicComponent as Ve, normalizeProps as hr, guardReactiveProps as vr, mergeProps as vt, onMounted as br, onUnmounted as Cr, normalizeStyle as gn, inject as kr, pushScopeId as yn, popScopeId as hn, Teleport as wr, reactive as Ut } from "vue";
|
|
2
2
|
import { useRouter as It } from "vue-router";
|
|
3
3
|
import { createI18n as St, i18nTComponent as vn } from "@kong-ui-public/i18n";
|
|
4
4
|
import _r from "axios";
|
|
@@ -108,7 +108,7 @@ function xr() {
|
|
|
108
108
|
}
|
|
109
109
|
const dt = {
|
|
110
110
|
useI18n: xr
|
|
111
|
-
}, xe = "/api/runtime_groups/{controlPlaneId}",
|
|
111
|
+
}, xe = "/api/runtime_groups/{controlPlaneId}", $e = "/{workspace}", Me = {
|
|
112
112
|
list: {
|
|
113
113
|
konnect: {
|
|
114
114
|
all: `${xe}/consumer_groups`,
|
|
@@ -116,9 +116,9 @@ const dt = {
|
|
|
116
116
|
oneForConsumer: `${xe}/consumers/{consumerId}/consumer_groups/{consumerGroupId}`
|
|
117
117
|
},
|
|
118
118
|
kongManager: {
|
|
119
|
-
all: `${
|
|
120
|
-
forConsumer: `${
|
|
121
|
-
oneForConsumer: `${
|
|
119
|
+
all: `${$e}/consumer_groups?counter=true`,
|
|
120
|
+
forConsumer: `${$e}/consumers/{consumerId}/consumer_groups`,
|
|
121
|
+
oneForConsumer: `${$e}/consumers/{consumerId}/consumer_groups/{consumerGroupId}`
|
|
122
122
|
}
|
|
123
123
|
},
|
|
124
124
|
form: {
|
|
@@ -131,16 +131,16 @@ const dt = {
|
|
|
131
131
|
getConsumers: `${xe}/consumer_groups/{id}/consumers`
|
|
132
132
|
},
|
|
133
133
|
kongManager: {
|
|
134
|
-
consumersList: `${
|
|
135
|
-
create: `${
|
|
136
|
-
edit: `${
|
|
137
|
-
addConsumer: `${
|
|
138
|
-
removeConsumer: `${
|
|
139
|
-
getConsumers: `${
|
|
134
|
+
consumersList: `${$e}/consumers`,
|
|
135
|
+
create: `${$e}/consumer_groups`,
|
|
136
|
+
edit: `${$e}/consumer_groups/{id}`,
|
|
137
|
+
addConsumer: `${$e}/consumer_groups/{id}/consumers`,
|
|
138
|
+
removeConsumer: `${$e}/consumer_groups/{id}/consumers/{consumerId}`,
|
|
139
|
+
getConsumers: `${$e}/consumer_groups/{id}/consumers`
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
};
|
|
143
|
-
var bn = /* @__PURE__ */ ((e) => (e.GatewayService = "service", e.Route = "route", e.Consumer = "consumer", e.ConsumerGroup = "consumer group", e.Plugin = "plugin", e.Upstream = "upstream", e.Certificate = "certificate", e.CACertificate = "ca certificate", e.SNI = "SNI", e.Key = "key", e.KeySet = "key set", e.Vault = "vault", e.Application = "application", e.Developer = "developer", e.acls = "ACL Credential", e["basic-auth"] = "Basic Auth Credential", e["key-auth"] = "Key Auth Credential", e["key-auth-enc"] = "Key Auth Encrypted Credential", e.oauth2 = "OAuth 2.0 Credential", e["hmac-auth"] = "HMAC Credential", e.jwt = "JWT Credential", e.Target = "target", e.Policy = "policy", e))(bn || {}), nt = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(nt || {}),
|
|
143
|
+
var bn = /* @__PURE__ */ ((e) => (e.GatewayService = "service", e.Route = "route", e.Consumer = "consumer", e.ConsumerGroup = "consumer group", e.Plugin = "plugin", e.Upstream = "upstream", e.Certificate = "certificate", e.CACertificate = "ca certificate", e.SNI = "SNI", e.Key = "key", e.KeySet = "key set", e.Vault = "vault", e.Application = "application", e.Developer = "developer", e.acls = "ACL Credential", e["basic-auth"] = "Basic Auth Credential", e["key-auth"] = "Key Auth Credential", e["key-auth-enc"] = "Key Auth Encrypted Credential", e.oauth2 = "OAuth 2.0 Credential", e["hmac-auth"] = "HMAC Credential", e.jwt = "JWT Credential", e.Target = "target", e.Policy = "policy", e))(bn || {}), nt = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(nt || {}), Ke = /* @__PURE__ */ ((e) => (e[e.Loading = 0] = "Loading", e[e.Idle = 1] = "Idle", e[e.NoResults = 2] = "NoResults", e[e.Error = 3] = "Error", e))(Ke || {}), re = /* @__PURE__ */ ((e) => (e.ID = "id", e.IdArray = "id-array", e.Text = "plain-text", e.Date = "date", e.Redacted = "redacted", e.RedactedArray = "redacted-array", e.Json = "json", e.JsonArray = "json-array", e.BadgeTag = "badge-tag", e.BadgeStatus = "badge-status", e.BadgeMethod = "badge-method", e.LinkInternal = "link-internal", e.LinkExternal = "link-external", e))(re || {}), ke = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e))(ke || {});
|
|
144
144
|
function At(e = {}) {
|
|
145
145
|
return {
|
|
146
146
|
axiosInstance: _r.create({
|
|
@@ -150,7 +150,7 @@ function At(e = {}) {
|
|
|
150
150
|
})
|
|
151
151
|
};
|
|
152
152
|
}
|
|
153
|
-
function
|
|
153
|
+
function $r() {
|
|
154
154
|
return {
|
|
155
155
|
debounce: (e, n) => {
|
|
156
156
|
let t;
|
|
@@ -162,7 +162,7 @@ function Tr() {
|
|
|
162
162
|
}
|
|
163
163
|
};
|
|
164
164
|
}
|
|
165
|
-
const mt = "khcp-user-table-preferences",
|
|
165
|
+
const mt = "khcp-user-table-preferences", Tr = {
|
|
166
166
|
pageSize: 30,
|
|
167
167
|
sortColumnKey: void 0,
|
|
168
168
|
sortColumnOrder: void 0
|
|
@@ -191,7 +191,7 @@ function jr() {
|
|
|
191
191
|
},
|
|
192
192
|
getTablePreferences: (t) => {
|
|
193
193
|
const r = n();
|
|
194
|
-
return (r == null ? void 0 : r.get(t)) || void 0 ||
|
|
194
|
+
return (r == null ? void 0 : r.get(t)) || void 0 || Tr;
|
|
195
195
|
},
|
|
196
196
|
deleteAllTablePreferences: () => {
|
|
197
197
|
localStorage.removeItem(mt);
|
|
@@ -217,13 +217,13 @@ const Mr = {
|
|
|
217
217
|
errors: {
|
|
218
218
|
edit: "The entity could not be edited at this time."
|
|
219
219
|
}
|
|
220
|
-
},
|
|
220
|
+
}, Nr = {
|
|
221
221
|
emptyState: {
|
|
222
222
|
noSearchResultsTitle: "No results found",
|
|
223
223
|
noSearchResultsMessage: "Please adjust the criteria and try again.",
|
|
224
224
|
noSearchResultsCtaText: "Clear"
|
|
225
225
|
}
|
|
226
|
-
},
|
|
226
|
+
}, Kr = {
|
|
227
227
|
title: "Configuration",
|
|
228
228
|
actions: {
|
|
229
229
|
copy: "Copy JSON"
|
|
@@ -261,7 +261,7 @@ const Mr = {
|
|
|
261
261
|
entryTitle: "Entry {index}",
|
|
262
262
|
structuredFormat: "Structured"
|
|
263
263
|
}
|
|
264
|
-
},
|
|
264
|
+
}, Br = {
|
|
265
265
|
filterButtonText: "Filter",
|
|
266
266
|
fieldLabel: "Filter by:",
|
|
267
267
|
inputPlaceholder: "Enter a value",
|
|
@@ -269,7 +269,7 @@ const Mr = {
|
|
|
269
269
|
applyButtonText: "Apply",
|
|
270
270
|
clearButtonText: "Clear",
|
|
271
271
|
clearAllButtonText: "Clear all filters"
|
|
272
|
-
},
|
|
272
|
+
}, Fr = {
|
|
273
273
|
errors: {
|
|
274
274
|
fetch: "Could not fetch available items",
|
|
275
275
|
invalid: "Please select a valid value"
|
|
@@ -292,10 +292,10 @@ const Mr = {
|
|
|
292
292
|
global: Mr,
|
|
293
293
|
deleteModal: Er,
|
|
294
294
|
baseForm: Or,
|
|
295
|
-
baseTable:
|
|
296
|
-
baseConfigCard:
|
|
297
|
-
filter:
|
|
298
|
-
debouncedFilter:
|
|
295
|
+
baseTable: Nr,
|
|
296
|
+
baseConfigCard: Kr,
|
|
297
|
+
filter: Br,
|
|
298
|
+
debouncedFilter: Fr,
|
|
299
299
|
errors: qr,
|
|
300
300
|
toggleModal: Lr
|
|
301
301
|
};
|
|
@@ -358,7 +358,7 @@ function Pr(e, n, t, r = {
|
|
|
358
358
|
t || (t = "100");
|
|
359
359
|
const { axiosInstance: a } = At({
|
|
360
360
|
headers: e.requestHeaders
|
|
361
|
-
}), { i18n: { t: i } } = xt(), { debounce: o } =
|
|
361
|
+
}), { i18n: { t: i } } = xt(), { debounce: o } = $r(), s = o(async (I) => {
|
|
362
362
|
await O(I);
|
|
363
363
|
}, 200), l = E(!1), u = E(""), p = E(""), c = E([]), g = E([]), d = E(void 0), _ = m(n);
|
|
364
364
|
let v = `${e.apiBaseUrl}${_}`;
|
|
@@ -374,7 +374,7 @@ function Pr(e, n, t, r = {
|
|
|
374
374
|
l.value = !1;
|
|
375
375
|
}
|
|
376
376
|
}, b = E(""), O = async (I) => {
|
|
377
|
-
var
|
|
377
|
+
var N, z, ie;
|
|
378
378
|
if (b.value !== I)
|
|
379
379
|
if (b.value = I || "", d.value === void 0)
|
|
380
380
|
try {
|
|
@@ -386,25 +386,25 @@ function Pr(e, n, t, r = {
|
|
|
386
386
|
} else if (I) {
|
|
387
387
|
const R = [];
|
|
388
388
|
S(I) && r.searchKeys.includes("id") ? R.push((async () => {
|
|
389
|
-
const { data:
|
|
390
|
-
return [
|
|
389
|
+
const { data: F } = await a.get(`${v}/${I}`);
|
|
390
|
+
return [F[r.fetchedItemsKey] ?? F];
|
|
391
391
|
})()) : R.push(
|
|
392
|
-
...r.searchKeys.filter((
|
|
393
|
-
const { data: w } = await a.get(`${v}?${
|
|
392
|
+
...r.searchKeys.filter((F) => F !== "id").map(async (F) => {
|
|
393
|
+
const { data: w } = await a.get(`${v}?${F}=${I}`);
|
|
394
394
|
return w[r.fetchedItemsKey];
|
|
395
395
|
})
|
|
396
396
|
);
|
|
397
397
|
const k = await Promise.all(R), G = /* @__PURE__ */ new Set();
|
|
398
|
-
c.value = [], (
|
|
398
|
+
c.value = [], (N = k == null ? void 0 : k.forEach) == null || N.call(k, (F) => {
|
|
399
399
|
var w;
|
|
400
|
-
(w =
|
|
400
|
+
(w = F == null ? void 0 : F.forEach) == null || w.call(F, (j) => {
|
|
401
401
|
G.has(j.id) || (G.add(j.id), c.value.push(j));
|
|
402
402
|
});
|
|
403
403
|
});
|
|
404
404
|
} else
|
|
405
405
|
c.value = g.value;
|
|
406
406
|
} catch (R) {
|
|
407
|
-
((
|
|
407
|
+
((z = R == null ? void 0 : R.response) == null ? void 0 : z.status) === 404 ? p.value = i("debouncedFilter.errors.invalid") : (c.value = [], u.value = i("debouncedFilter.errors.fetch"));
|
|
408
408
|
} finally {
|
|
409
409
|
l.value = !1;
|
|
410
410
|
}
|
|
@@ -412,8 +412,8 @@ function Pr(e, n, t, r = {
|
|
|
412
412
|
l.value = !0, p.value = "", I ? (c.value = (ie = d.value) == null ? void 0 : ie.filter((R) => {
|
|
413
413
|
var k;
|
|
414
414
|
let G = !1;
|
|
415
|
-
for (const
|
|
416
|
-
const w = typeof R[
|
|
415
|
+
for (const F of r.searchKeys) {
|
|
416
|
+
const w = typeof R[F] == "string" ? (k = R[F]) == null ? void 0 : k.toLowerCase() : R[F];
|
|
417
417
|
w != null && w.includes(I.toLowerCase()) && (G = !0);
|
|
418
418
|
}
|
|
419
419
|
return G;
|
|
@@ -496,12 +496,14 @@ function Gr(e, n, t = "data") {
|
|
|
496
496
|
const r = m(n), { axiosInstance: a } = At({
|
|
497
497
|
headers: e.requestHeaders
|
|
498
498
|
}), i = kn(e, r), o = E({
|
|
499
|
-
status:
|
|
499
|
+
status: Ke.Idle
|
|
500
500
|
});
|
|
501
501
|
return { fetcher: async (s) => {
|
|
502
502
|
try {
|
|
503
|
-
o.value = { status:
|
|
504
|
-
|
|
503
|
+
o.value = { status: Ke.Loading };
|
|
504
|
+
let l = i(s);
|
|
505
|
+
l.includes("filter[name]") && (l = `${l}&page[size]=${s.pageSize}&page[number]=${s.page}`);
|
|
506
|
+
const { data: u } = await a.get(l), p = t && t.replace(/[^\w-_]/gi, "");
|
|
505
507
|
let c;
|
|
506
508
|
u[p] && Array.isArray(u[p]) ? c = u[p] : Array.isArray(u) ? c = u : c = Object.keys(u).length ? [u] : [];
|
|
507
509
|
const g = {
|
|
@@ -514,7 +516,7 @@ function Gr(e, n, t = "data") {
|
|
|
514
516
|
} : null
|
|
515
517
|
};
|
|
516
518
|
return o.value = {
|
|
517
|
-
status:
|
|
519
|
+
status: Ke.Idle,
|
|
518
520
|
response: g
|
|
519
521
|
}, g;
|
|
520
522
|
} catch (l) {
|
|
@@ -523,18 +525,18 @@ function Gr(e, n, t = "data") {
|
|
|
523
525
|
total: 0
|
|
524
526
|
};
|
|
525
527
|
return s.query && l.response.status === 404 ? (o.value = {
|
|
526
|
-
status:
|
|
528
|
+
status: Ke.NoResults,
|
|
527
529
|
response: u,
|
|
528
530
|
error: l
|
|
529
531
|
}, u) : (o.value = {
|
|
530
|
-
status:
|
|
532
|
+
status: Ke.Error,
|
|
531
533
|
response: u,
|
|
532
534
|
error: l
|
|
533
535
|
}, u);
|
|
534
536
|
}
|
|
535
537
|
}, fetcherState: o };
|
|
536
538
|
}
|
|
537
|
-
function
|
|
539
|
+
function zr() {
|
|
538
540
|
const e = (t, r = "_") => t ? t.split(r).map((a) => a.toLowerCase() === "id" ? a.toUpperCase() : a.charAt(0).toUpperCase() + a.substring(1)).join(" ") : "", n = /(?:^|[\s-:'"])\w/g;
|
|
539
541
|
return {
|
|
540
542
|
capitalize: (t) => t ? t.replace(n, (r) => r.toUpperCase()) : "",
|
|
@@ -551,10 +553,10 @@ const wn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
551
553
|
}, Dt = (e) => e === "*" || e === "x" || e === "X", Vt = (e) => {
|
|
552
554
|
const n = parseInt(e, 10);
|
|
553
555
|
return isNaN(n) ? e : n;
|
|
554
|
-
},
|
|
556
|
+
}, Hr = (e, n) => typeof e != typeof n ? [String(e), String(n)] : [e, n], Jr = (e, n) => {
|
|
555
557
|
if (Dt(e) || Dt(n))
|
|
556
558
|
return 0;
|
|
557
|
-
const [t, r] =
|
|
559
|
+
const [t, r] = Hr(Vt(e), Vt(n));
|
|
558
560
|
return t > r ? 1 : t < r ? -1 : 0;
|
|
559
561
|
}, Rt = (e, n) => {
|
|
560
562
|
for (let t = 0; t < Math.max(e.length, n.length); t++) {
|
|
@@ -577,11 +579,11 @@ const wn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
577
579
|
"<=": [-1, 0],
|
|
578
580
|
"<": [-1],
|
|
579
581
|
"!=": [-1, 1]
|
|
580
|
-
},
|
|
582
|
+
}, zt = Object.keys(_n), Yr = (e) => {
|
|
581
583
|
if (typeof e != "string")
|
|
582
584
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
583
|
-
if (
|
|
584
|
-
throw new Error(`Invalid operator, expected one of ${
|
|
585
|
+
if (zt.indexOf(e) === -1)
|
|
586
|
+
throw new Error(`Invalid operator, expected one of ${zt.join("|")}`);
|
|
585
587
|
}, Zr = (e) => typeof e == "string" && /^[v\d]/.test(e) && wn.test(e);
|
|
586
588
|
function Qr(e) {
|
|
587
589
|
const { gatewayInfo: n, supportedRange: t } = e;
|
|
@@ -613,7 +615,7 @@ const de = {
|
|
|
613
615
|
useFetcher: Gr,
|
|
614
616
|
useFetchUrlBuilder: kn,
|
|
615
617
|
useHelpers: Cn,
|
|
616
|
-
useStringHelpers:
|
|
618
|
+
useStringHelpers: zr,
|
|
617
619
|
useI18n: xt,
|
|
618
620
|
useGatewayFeatureSupported: Qr,
|
|
619
621
|
useTruncationDetector: Xr
|
|
@@ -626,7 +628,7 @@ const de = {
|
|
|
626
628
|
}, ta = "Copy to clipboard", na = {
|
|
627
629
|
message: ea,
|
|
628
630
|
iconTitle: ta
|
|
629
|
-
}, ra = "kong-ui-copy-uuid-notify",
|
|
631
|
+
}, ra = "kong-ui-copy-uuid-notify", Ht = "24px", aa = (e, n) => {
|
|
630
632
|
const t = e.__vccOpts || e;
|
|
631
633
|
for (const [r, a] of n)
|
|
632
634
|
t[r] = a;
|
|
@@ -668,7 +670,7 @@ const de = {
|
|
|
668
670
|
size: {
|
|
669
671
|
type: [Number, String],
|
|
670
672
|
required: !1,
|
|
671
|
-
default:
|
|
673
|
+
default: Ht,
|
|
672
674
|
// if setting to the imported const fails, just pass a number of 24 as the default.
|
|
673
675
|
validator: (e) => {
|
|
674
676
|
if (typeof e == "number" && e > 0)
|
|
@@ -697,7 +699,7 @@ const de = {
|
|
|
697
699
|
if (i && !isNaN(i) && Number.isInteger(i) && i > 0)
|
|
698
700
|
return `${i}px`;
|
|
699
701
|
}
|
|
700
|
-
return
|
|
702
|
+
return Ht;
|
|
701
703
|
}), r = A(() => ({
|
|
702
704
|
boxSizing: "border-box",
|
|
703
705
|
color: n.color,
|
|
@@ -713,7 +715,7 @@ const de = {
|
|
|
713
715
|
style: gn(r.value)
|
|
714
716
|
}, {
|
|
715
717
|
default: h(() => [
|
|
716
|
-
(f(),
|
|
718
|
+
(f(), $("svg", {
|
|
717
719
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
718
720
|
"data-testid": "kui-icon-svg-copy-icon",
|
|
719
721
|
fill: "none",
|
|
@@ -723,7 +725,7 @@ const de = {
|
|
|
723
725
|
width: "100%",
|
|
724
726
|
xmlns: "http://www.w3.org/2000/svg"
|
|
725
727
|
}, [
|
|
726
|
-
e.title ? (f(),
|
|
728
|
+
e.title ? (f(), $("title", sa, B(e.title), 1)) : J("", !0),
|
|
727
729
|
la
|
|
728
730
|
], 8, ia))
|
|
729
731
|
]),
|
|
@@ -810,7 +812,7 @@ const de = {
|
|
|
810
812
|
};
|
|
811
813
|
return (d, _) => {
|
|
812
814
|
const v = U("KClipboardProvider");
|
|
813
|
-
return f(),
|
|
815
|
+
return f(), $("div", pa, [
|
|
814
816
|
e.format !== "hidden" ? (f(), V(Ve(e.idTooltip ? "KTooltip" : "div"), vt({ key: 0 }, o.value, { "data-testid": "copy-id" }), {
|
|
815
817
|
default: h(() => [
|
|
816
818
|
D("div", {
|
|
@@ -819,13 +821,13 @@ const de = {
|
|
|
819
821
|
e.truncated ? "truncated-uuid" : null,
|
|
820
822
|
e.useMono ? "mono" : null
|
|
821
823
|
])
|
|
822
|
-
},
|
|
824
|
+
}, B(p.value), 3)
|
|
823
825
|
]),
|
|
824
826
|
_: 1
|
|
825
827
|
}, 16)) : J("", !0),
|
|
826
828
|
(f(), V(Ve(e.tooltip ? "KTooltip" : "div"), vt(u.value, { class: "uuid-icon-wrapper" }), {
|
|
827
829
|
default: h(() => [
|
|
828
|
-
|
|
830
|
+
K(v, null, {
|
|
829
831
|
default: h(({ copyToClipboard: S }) => [
|
|
830
832
|
D("span", {
|
|
831
833
|
"data-testid": "copy-to-clipboard",
|
|
@@ -833,7 +835,7 @@ const de = {
|
|
|
833
835
|
tabindex: "0",
|
|
834
836
|
onClick: rt((y) => g(S), ["stop"])
|
|
835
837
|
}, [
|
|
836
|
-
|
|
838
|
+
K(m(ca), {
|
|
837
839
|
class: "uuid-icon",
|
|
838
840
|
color: e.iconColor,
|
|
839
841
|
decorative: !!e.tooltip,
|
|
@@ -886,10 +888,10 @@ const de = {
|
|
|
886
888
|
class: Oe(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
887
889
|
}, {
|
|
888
890
|
default: h(() => [
|
|
889
|
-
e.isArrayItem ? (f(),
|
|
890
|
-
D("b", null,
|
|
891
|
+
e.isArrayItem ? (f(), $("legend", ya, [
|
|
892
|
+
D("b", null, B(s.value), 1)
|
|
891
893
|
])) : J("", !0),
|
|
892
|
-
(f(!0),
|
|
894
|
+
(f(!0), $(Ce, null, ve(Object.keys(o.value), (p, c) => (f(), V($t, {
|
|
893
895
|
key: `${a.value}-property-${c}`,
|
|
894
896
|
item: {
|
|
895
897
|
key: p,
|
|
@@ -919,14 +921,14 @@ const de = {
|
|
|
919
921
|
const { i18n: { t: n } } = de.useI18n();
|
|
920
922
|
return (t, r) => {
|
|
921
923
|
const a = U("KButton");
|
|
922
|
-
return f(),
|
|
923
|
-
|
|
924
|
+
return f(), $("div", null, [
|
|
925
|
+
K(a, {
|
|
924
926
|
appearance: "tertiary",
|
|
925
927
|
class: "navigation-button",
|
|
926
928
|
onClick: r[0] || (r[0] = (i) => t.$emit("navigation-click", e.item))
|
|
927
929
|
}, {
|
|
928
930
|
default: h(() => [
|
|
929
|
-
Q(
|
|
931
|
+
Q(B(e.item.value || m(n)("baseConfigCard.commonFields.link")), 1)
|
|
930
932
|
]),
|
|
931
933
|
_: 1
|
|
932
934
|
})
|
|
@@ -949,17 +951,17 @@ const de = {
|
|
|
949
951
|
appearance: e.status ? "success" : "neutral"
|
|
950
952
|
}, {
|
|
951
953
|
default: h(() => [
|
|
952
|
-
Q(
|
|
954
|
+
Q(B(e.status ? m(n)("baseConfigCard.statusBadge.enabledLabel") : m(n)("baseConfigCard.statusBadge.disabledLabel")), 1)
|
|
953
955
|
]),
|
|
954
956
|
_: 1
|
|
955
957
|
}, 8, ["appearance"]);
|
|
956
958
|
};
|
|
957
959
|
}
|
|
958
|
-
}), ka = "#0044f4", wa = "#e0e4ea", _a = "#3a3f51", Ia = "1px", Sa = "20px", Aa = { class: "config-card-details-row" }, xa = ["data-testid"],
|
|
960
|
+
}), ka = "#0044f4", wa = "#e0e4ea", _a = "#3a3f51", Ia = "1px", Sa = "20px", Aa = { class: "config-card-details-row" }, xa = ["data-testid"], $a = ["data-testid"], Ta = ["data-testid"], ja = ["data-testid"], Ma = { key: 1 }, Ea = ["data-testid"], Oa = ["data-testid"], Na = ["data-testid"], Ka = ["data-testid"], Ba = {
|
|
959
961
|
name: "ConfigCardItem",
|
|
960
962
|
components: { CopyUuid: In, JsonCardItem: Sn, StatusBadge: Ca, InternalLinkItem: ba }
|
|
961
|
-
},
|
|
962
|
-
...
|
|
963
|
+
}, Fa = /* @__PURE__ */ oe({
|
|
964
|
+
...Ba,
|
|
963
965
|
props: {
|
|
964
966
|
item: {
|
|
965
967
|
type: Object,
|
|
@@ -1113,15 +1115,15 @@ const de = {
|
|
|
1113
1115
|
}), g = E(), { isTruncated: d } = de.useTruncationDetector(g);
|
|
1114
1116
|
return (_, v) => {
|
|
1115
1117
|
const S = U("KLabel"), y = U("KBadge"), b = U("KTooltip");
|
|
1116
|
-
return f(),
|
|
1118
|
+
return f(), $("div", Aa, [
|
|
1117
1119
|
D("div", {
|
|
1118
1120
|
class: "config-card-details-label",
|
|
1119
1121
|
"data-testid": `${e.item.key}-label`
|
|
1120
1122
|
}, [
|
|
1121
1123
|
X(_.$slots, "label", { item: e.item }, () => [
|
|
1122
|
-
|
|
1124
|
+
K(S, { "tooltip-attributes": { maxWidth: "500px" } }, je({
|
|
1123
1125
|
default: h(() => [
|
|
1124
|
-
Q(
|
|
1126
|
+
Q(B(e.item.label) + " ", 1)
|
|
1125
1127
|
]),
|
|
1126
1128
|
_: 2
|
|
1127
1129
|
}, [
|
|
@@ -1132,9 +1134,9 @@ const de = {
|
|
|
1132
1134
|
"data-testid": `${e.item.key}-label-tooltip`
|
|
1133
1135
|
}, [
|
|
1134
1136
|
X(_.$slots, "label-tooltip", {}, () => [
|
|
1135
|
-
Q(
|
|
1137
|
+
Q(B(e.item.tooltip), 1)
|
|
1136
1138
|
], !0)
|
|
1137
|
-
], 8,
|
|
1139
|
+
], 8, $a)
|
|
1138
1140
|
]),
|
|
1139
1141
|
key: "0"
|
|
1140
1142
|
} : void 0
|
|
@@ -1148,14 +1150,14 @@ const de = {
|
|
|
1148
1150
|
X(_.$slots, e.item.key, {
|
|
1149
1151
|
rowValue: e.item.value
|
|
1150
1152
|
}, () => [
|
|
1151
|
-
s.value ? (f(),
|
|
1153
|
+
s.value ? (f(), $("div", Ma, [
|
|
1152
1154
|
(f(), V(Ve(c.value.tag), hr(vr(c.value.attrs)), {
|
|
1153
1155
|
default: h(() => [
|
|
1154
|
-
c.value.additionalComponent === "KBadge" ? (f(),
|
|
1156
|
+
c.value.additionalComponent === "KBadge" ? (f(), $("div", {
|
|
1155
1157
|
key: 0,
|
|
1156
1158
|
"data-testid": `${e.item.key}-badge-tags`
|
|
1157
1159
|
}, [
|
|
1158
|
-
(f(!0),
|
|
1160
|
+
(f(!0), $(Ce, null, ve(e.item.value, (O, I) => (f(), V(y, {
|
|
1159
1161
|
key: `${e.item.key}-badge-tag-${I}`,
|
|
1160
1162
|
class: "config-badge",
|
|
1161
1163
|
"data-testid": `${e.item.key}-badge-tag-${I}`,
|
|
@@ -1163,49 +1165,49 @@ const de = {
|
|
|
1163
1165
|
"truncation-tooltip": ""
|
|
1164
1166
|
}, {
|
|
1165
1167
|
default: h(() => [
|
|
1166
|
-
Q(
|
|
1168
|
+
Q(B(O), 1)
|
|
1167
1169
|
]),
|
|
1168
1170
|
_: 2
|
|
1169
1171
|
}, 1032, ["data-testid", "tooltip"]))), 128))
|
|
1170
1172
|
], 8, Ea)) : J("", !0),
|
|
1171
|
-
c.value.additionalComponent === "CopyUuid" ? (f(),
|
|
1173
|
+
c.value.additionalComponent === "CopyUuid" ? (f(), $("div", {
|
|
1172
1174
|
key: 1,
|
|
1173
1175
|
class: "copy-uuid-array",
|
|
1174
1176
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
1175
1177
|
}, [
|
|
1176
|
-
(f(!0),
|
|
1178
|
+
(f(!0), $(Ce, null, ve(e.item.value, (O, I) => (f(), V(m(In), vt(c.value.childAttrs, {
|
|
1177
1179
|
key: `${e.item.key}-copy-uuid-${I}`,
|
|
1178
1180
|
"data-testid": `${e.item.key}-copy-uuid-${I}`,
|
|
1179
1181
|
uuid: O
|
|
1180
1182
|
}), null, 16, ["data-testid", "uuid"]))), 128))
|
|
1181
|
-
], 8, Oa)) : c.value.additionalComponent === "KMethodBadge" ? (f(),
|
|
1183
|
+
], 8, Oa)) : c.value.additionalComponent === "KMethodBadge" ? (f(), $("div", {
|
|
1182
1184
|
key: 2,
|
|
1183
1185
|
class: "method-badge-array",
|
|
1184
1186
|
"data-testid": `${e.item.key}-badge-methods`
|
|
1185
1187
|
}, [
|
|
1186
|
-
(f(!0),
|
|
1188
|
+
(f(!0), $(Ce, null, ve(e.item.value, (O, I) => (f(), V(y, {
|
|
1187
1189
|
key: `${e.item.key}-badge-method-${I}`,
|
|
1188
1190
|
appearance: Object.values(m(Ir)).includes(O.toLowerCase()) ? O.toLowerCase() : "custom",
|
|
1189
1191
|
class: "config-badge",
|
|
1190
1192
|
"data-testid": `${e.item.key}-badge-method-${I}`
|
|
1191
1193
|
}, {
|
|
1192
1194
|
default: h(() => [
|
|
1193
|
-
Q(
|
|
1195
|
+
Q(B(O), 1)
|
|
1194
1196
|
]),
|
|
1195
1197
|
_: 2
|
|
1196
1198
|
}, 1032, ["appearance", "data-testid"]))), 128))
|
|
1197
|
-
], 8,
|
|
1198
|
-
c.value.additionalComponent === "JsonCardItem" ? (f(),
|
|
1199
|
+
], 8, Na)) : J("", !0),
|
|
1200
|
+
c.value.additionalComponent === "JsonCardItem" ? (f(), $("div", {
|
|
1199
1201
|
key: 3,
|
|
1200
1202
|
"data-testid": `${t.item.key}-json-array-content`
|
|
1201
1203
|
}, [
|
|
1202
|
-
(f(!0),
|
|
1204
|
+
(f(!0), $(Ce, null, ve(e.item.value, (O, I) => (f(), V(Sn, {
|
|
1203
1205
|
key: `json-array-item-${I}`,
|
|
1204
1206
|
index: I,
|
|
1205
1207
|
"is-array-item": "",
|
|
1206
1208
|
item: O
|
|
1207
1209
|
}, null, 8, ["index", "item"]))), 128))
|
|
1208
|
-
], 8,
|
|
1210
|
+
], 8, Ka)) : (f(), V(b, {
|
|
1209
1211
|
key: 4,
|
|
1210
1212
|
label: m(d) ? e.item.value : ""
|
|
1211
1213
|
}, {
|
|
@@ -1214,23 +1216,23 @@ const de = {
|
|
|
1214
1216
|
ref_key: "textContent",
|
|
1215
1217
|
ref: g,
|
|
1216
1218
|
class: Oe(["attrs-data-text", { truncated: e.truncated }])
|
|
1217
|
-
},
|
|
1219
|
+
}, B(c.value.text), 3)
|
|
1218
1220
|
]),
|
|
1219
1221
|
_: 1
|
|
1220
1222
|
}, 8, ["label"]))
|
|
1221
1223
|
]),
|
|
1222
1224
|
_: 1
|
|
1223
1225
|
}, 16))
|
|
1224
|
-
])) : (f(),
|
|
1226
|
+
])) : (f(), $("div", {
|
|
1225
1227
|
key: 0,
|
|
1226
1228
|
"data-testid": `${e.item.key}-no-value`
|
|
1227
1229
|
}, " – ", 8, ja))
|
|
1228
1230
|
], !0)
|
|
1229
|
-
], 8,
|
|
1231
|
+
], 8, Ta)
|
|
1230
1232
|
]);
|
|
1231
1233
|
};
|
|
1232
1234
|
}
|
|
1233
|
-
}),
|
|
1235
|
+
}), $t = /* @__PURE__ */ we(Fa, [["__scopeId", "data-v-9c87856b"]]);
|
|
1234
1236
|
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
|
|
1235
1237
|
function An(e) {
|
|
1236
1238
|
return typeof e > "u" || e === null;
|
|
@@ -1257,12 +1259,12 @@ function Pa(e, n) {
|
|
|
1257
1259
|
function Da(e) {
|
|
1258
1260
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1259
1261
|
}
|
|
1260
|
-
var Va = An, Ra = qa, Ga = La,
|
|
1262
|
+
var Va = An, Ra = qa, Ga = La, za = Pa, Ha = Da, Ja = Ua, ce = {
|
|
1261
1263
|
isNothing: Va,
|
|
1262
1264
|
isObject: Ra,
|
|
1263
1265
|
toArray: Ga,
|
|
1264
|
-
repeat:
|
|
1265
|
-
isNegativeZero:
|
|
1266
|
+
repeat: za,
|
|
1267
|
+
isNegativeZero: Ha,
|
|
1266
1268
|
extend: Ja
|
|
1267
1269
|
};
|
|
1268
1270
|
function xn(e, n) {
|
|
@@ -1413,7 +1415,7 @@ bt.prototype.extend = function(e) {
|
|
|
1413
1415
|
var r = Object.create(bt.prototype);
|
|
1414
1416
|
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(t), r.compiledImplicit = Wt(r, "implicit"), r.compiledExplicit = Wt(r, "explicit"), r.compiledTypeMap = to(r.compiledImplicit, r.compiledExplicit), r;
|
|
1415
1417
|
};
|
|
1416
|
-
var
|
|
1418
|
+
var $n = bt, Tn = new fe("tag:yaml.org,2002:str", {
|
|
1417
1419
|
kind: "scalar",
|
|
1418
1420
|
construct: function(e) {
|
|
1419
1421
|
return e !== null ? e : "";
|
|
@@ -1428,9 +1430,9 @@ var Tn = bt, $n = new fe("tag:yaml.org,2002:str", {
|
|
|
1428
1430
|
construct: function(e) {
|
|
1429
1431
|
return e !== null ? e : {};
|
|
1430
1432
|
}
|
|
1431
|
-
}), En = new
|
|
1433
|
+
}), En = new $n({
|
|
1432
1434
|
explicit: [
|
|
1433
|
-
|
|
1435
|
+
Tn,
|
|
1434
1436
|
jn,
|
|
1435
1437
|
Mn
|
|
1436
1438
|
]
|
|
@@ -1483,7 +1485,7 @@ function io(e) {
|
|
|
1483
1485
|
function so(e) {
|
|
1484
1486
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1485
1487
|
}
|
|
1486
|
-
var
|
|
1488
|
+
var Nn = new fe("tag:yaml.org,2002:bool", {
|
|
1487
1489
|
kind: "scalar",
|
|
1488
1490
|
resolve: oo,
|
|
1489
1491
|
construct: io,
|
|
@@ -1574,7 +1576,7 @@ function fo(e) {
|
|
|
1574
1576
|
function mo(e) {
|
|
1575
1577
|
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 === 0 && !ce.isNegativeZero(e);
|
|
1576
1578
|
}
|
|
1577
|
-
var
|
|
1579
|
+
var Kn = new fe("tag:yaml.org,2002:int", {
|
|
1578
1580
|
kind: "scalar",
|
|
1579
1581
|
resolve: po,
|
|
1580
1582
|
construct: fo,
|
|
@@ -1651,21 +1653,21 @@ function bo(e, n) {
|
|
|
1651
1653
|
function Co(e) {
|
|
1652
1654
|
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 !== 0 || ce.isNegativeZero(e));
|
|
1653
1655
|
}
|
|
1654
|
-
var
|
|
1656
|
+
var Bn = new fe("tag:yaml.org,2002:float", {
|
|
1655
1657
|
kind: "scalar",
|
|
1656
1658
|
resolve: yo,
|
|
1657
1659
|
construct: ho,
|
|
1658
1660
|
predicate: Co,
|
|
1659
1661
|
represent: bo,
|
|
1660
1662
|
defaultStyle: "lowercase"
|
|
1661
|
-
}),
|
|
1663
|
+
}), Fn = En.extend({
|
|
1662
1664
|
implicit: [
|
|
1663
1665
|
On,
|
|
1664
|
-
Fn,
|
|
1665
1666
|
Nn,
|
|
1666
|
-
Kn
|
|
1667
|
+
Kn,
|
|
1668
|
+
Bn
|
|
1667
1669
|
]
|
|
1668
|
-
}), qn =
|
|
1670
|
+
}), qn = Fn, Ln = new RegExp(
|
|
1669
1671
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1670
1672
|
), Un = new RegExp(
|
|
1671
1673
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"
|
|
@@ -1702,12 +1704,12 @@ function Io(e) {
|
|
|
1702
1704
|
var Dn = new fe("tag:yaml.org,2002:merge", {
|
|
1703
1705
|
kind: "scalar",
|
|
1704
1706
|
resolve: Io
|
|
1705
|
-
}),
|
|
1707
|
+
}), Tt = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
1706
1708
|
\r`;
|
|
1707
1709
|
function So(e) {
|
|
1708
1710
|
if (e === null)
|
|
1709
1711
|
return !1;
|
|
1710
|
-
var n, t, r = 0, a = e.length, i =
|
|
1712
|
+
var n, t, r = 0, a = e.length, i = Tt;
|
|
1711
1713
|
for (t = 0; t < a; t++)
|
|
1712
1714
|
if (n = i.indexOf(e.charAt(t)), !(n > 64)) {
|
|
1713
1715
|
if (n < 0)
|
|
@@ -1717,27 +1719,27 @@ function So(e) {
|
|
|
1717
1719
|
return r % 8 === 0;
|
|
1718
1720
|
}
|
|
1719
1721
|
function Ao(e) {
|
|
1720
|
-
var n, t, r = e.replace(/[\r\n=]/g, ""), a = r.length, i =
|
|
1722
|
+
var n, t, r = e.replace(/[\r\n=]/g, ""), a = r.length, i = Tt, o = 0, s = [];
|
|
1721
1723
|
for (n = 0; n < a; n++)
|
|
1722
1724
|
n % 4 === 0 && n && (s.push(o >> 16 & 255), s.push(o >> 8 & 255), s.push(o & 255)), o = o << 6 | i.indexOf(r.charAt(n));
|
|
1723
1725
|
return t = a % 4 * 6, t === 0 ? (s.push(o >> 16 & 255), s.push(o >> 8 & 255), s.push(o & 255)) : t === 18 ? (s.push(o >> 10 & 255), s.push(o >> 2 & 255)) : t === 12 && s.push(o >> 4 & 255), new Uint8Array(s);
|
|
1724
1726
|
}
|
|
1725
1727
|
function xo(e) {
|
|
1726
|
-
var n = "", t = 0, r, a, i = e.length, o =
|
|
1728
|
+
var n = "", t = 0, r, a, i = e.length, o = Tt;
|
|
1727
1729
|
for (r = 0; r < i; r++)
|
|
1728
1730
|
r % 3 === 0 && r && (n += o[t >> 18 & 63], n += o[t >> 12 & 63], n += o[t >> 6 & 63], n += o[t & 63]), t = (t << 8) + e[r];
|
|
1729
1731
|
return a = i % 3, a === 0 ? (n += o[t >> 18 & 63], n += o[t >> 12 & 63], n += o[t >> 6 & 63], n += o[t & 63]) : a === 2 ? (n += o[t >> 10 & 63], n += o[t >> 4 & 63], n += o[t << 2 & 63], n += o[64]) : a === 1 && (n += o[t >> 2 & 63], n += o[t << 4 & 63], n += o[64], n += o[64]), n;
|
|
1730
1732
|
}
|
|
1731
|
-
function
|
|
1733
|
+
function $o(e) {
|
|
1732
1734
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1733
1735
|
}
|
|
1734
1736
|
var Vn = new fe("tag:yaml.org,2002:binary", {
|
|
1735
1737
|
kind: "scalar",
|
|
1736
1738
|
resolve: So,
|
|
1737
1739
|
construct: Ao,
|
|
1738
|
-
predicate:
|
|
1740
|
+
predicate: $o,
|
|
1739
1741
|
represent: xo
|
|
1740
|
-
}),
|
|
1742
|
+
}), To = Object.prototype.hasOwnProperty, jo = Object.prototype.toString;
|
|
1741
1743
|
function Mo(e) {
|
|
1742
1744
|
if (e === null)
|
|
1743
1745
|
return !0;
|
|
@@ -1746,7 +1748,7 @@ function Mo(e) {
|
|
|
1746
1748
|
if (a = s[t], o = !1, jo.call(a) !== "[object Object]")
|
|
1747
1749
|
return !1;
|
|
1748
1750
|
for (i in a)
|
|
1749
|
-
if (
|
|
1751
|
+
if (To.call(a, i))
|
|
1750
1752
|
if (!o)
|
|
1751
1753
|
o = !0;
|
|
1752
1754
|
else
|
|
@@ -1768,7 +1770,7 @@ var Rn = new fe("tag:yaml.org,2002:omap", {
|
|
|
1768
1770
|
resolve: Mo,
|
|
1769
1771
|
construct: Eo
|
|
1770
1772
|
}), Oo = Object.prototype.toString;
|
|
1771
|
-
function
|
|
1773
|
+
function No(e) {
|
|
1772
1774
|
if (e === null)
|
|
1773
1775
|
return !0;
|
|
1774
1776
|
var n, t, r, a, i, o = e;
|
|
@@ -1779,7 +1781,7 @@ function Fo(e) {
|
|
|
1779
1781
|
}
|
|
1780
1782
|
return !0;
|
|
1781
1783
|
}
|
|
1782
|
-
function
|
|
1784
|
+
function Ko(e) {
|
|
1783
1785
|
if (e === null)
|
|
1784
1786
|
return [];
|
|
1785
1787
|
var n, t, r, a, i, o = e;
|
|
@@ -1789,24 +1791,24 @@ function No(e) {
|
|
|
1789
1791
|
}
|
|
1790
1792
|
var Gn = new fe("tag:yaml.org,2002:pairs", {
|
|
1791
1793
|
kind: "sequence",
|
|
1792
|
-
resolve:
|
|
1793
|
-
construct:
|
|
1794
|
-
}),
|
|
1795
|
-
function
|
|
1794
|
+
resolve: No,
|
|
1795
|
+
construct: Ko
|
|
1796
|
+
}), Bo = Object.prototype.hasOwnProperty;
|
|
1797
|
+
function Fo(e) {
|
|
1796
1798
|
if (e === null)
|
|
1797
1799
|
return !0;
|
|
1798
1800
|
var n, t = e;
|
|
1799
1801
|
for (n in t)
|
|
1800
|
-
if (
|
|
1802
|
+
if (Bo.call(t, n) && t[n] !== null)
|
|
1801
1803
|
return !1;
|
|
1802
1804
|
return !0;
|
|
1803
1805
|
}
|
|
1804
1806
|
function qo(e) {
|
|
1805
1807
|
return e !== null ? e : {};
|
|
1806
1808
|
}
|
|
1807
|
-
var
|
|
1809
|
+
var zn = new fe("tag:yaml.org,2002:set", {
|
|
1808
1810
|
kind: "mapping",
|
|
1809
|
-
resolve:
|
|
1811
|
+
resolve: Fo,
|
|
1810
1812
|
construct: qo
|
|
1811
1813
|
}), jt = qn.extend({
|
|
1812
1814
|
implicit: [
|
|
@@ -1817,16 +1819,16 @@ var Hn = new fe("tag:yaml.org,2002:set", {
|
|
|
1817
1819
|
Vn,
|
|
1818
1820
|
Rn,
|
|
1819
1821
|
Gn,
|
|
1820
|
-
|
|
1822
|
+
zn
|
|
1821
1823
|
]
|
|
1822
|
-
}),
|
|
1824
|
+
}), Ne = Object.prototype.hasOwnProperty, at = 1, Hn = 2, Jn = 3, ot = 4, ht = 1, Lo = 2, Yt = 3, Uo = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Po = /[\x85\u2028\u2029]/, Do = /[,\[\]\{\}]/, Wn = /^(?:!|!!|![a-z\-]+!)$/i, Yn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1823
1825
|
function Zt(e) {
|
|
1824
1826
|
return Object.prototype.toString.call(e);
|
|
1825
1827
|
}
|
|
1826
1828
|
function Se(e) {
|
|
1827
1829
|
return e === 10 || e === 13;
|
|
1828
1830
|
}
|
|
1829
|
-
function
|
|
1831
|
+
function Be(e) {
|
|
1830
1832
|
return e === 9 || e === 32;
|
|
1831
1833
|
}
|
|
1832
1834
|
function be(e) {
|
|
@@ -1849,7 +1851,7 @@ function Qt(e) {
|
|
|
1849
1851
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? `
|
|
1850
1852
|
` : e === 118 ? "\v" : e === 102 ? "\f" : e === 114 ? "\r" : e === 101 ? "\x1B" : e === 32 ? " " : e === 34 ? '"' : e === 47 ? "/" : e === 92 ? "\\" : e === 78 ? "
" : e === 95 ? " " : e === 76 ? "\u2028" : e === 80 ? "\u2029" : "";
|
|
1851
1853
|
}
|
|
1852
|
-
function
|
|
1854
|
+
function zo(e) {
|
|
1853
1855
|
return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(
|
|
1854
1856
|
(e - 65536 >> 10) + 55296,
|
|
1855
1857
|
(e - 65536 & 1023) + 56320
|
|
@@ -1858,7 +1860,7 @@ function Ho(e) {
|
|
|
1858
1860
|
var Zn = new Array(256), Qn = new Array(256);
|
|
1859
1861
|
for (var Le = 0; Le < 256; Le++)
|
|
1860
1862
|
Zn[Le] = Qt(Le) ? 1 : 0, Qn[Le] = Qt(Le);
|
|
1861
|
-
function
|
|
1863
|
+
function Ho(e, n) {
|
|
1862
1864
|
this.input = e, this.filename = n.filename || null, this.schema = n.schema || jt, this.onWarning = n.onWarning || null, this.legacy = n.legacy || !1, this.json = n.json || !1, this.listener = n.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.firstTabInLine = -1, this.documents = [];
|
|
1863
1865
|
}
|
|
1864
1866
|
function Xn(e, n) {
|
|
@@ -1872,7 +1874,7 @@ function Xn(e, n) {
|
|
|
1872
1874
|
};
|
|
1873
1875
|
return t.snippet = Ya(t), new ge(n, t);
|
|
1874
1876
|
}
|
|
1875
|
-
function
|
|
1877
|
+
function T(e, n) {
|
|
1876
1878
|
throw Xn(e, n);
|
|
1877
1879
|
}
|
|
1878
1880
|
function it(e, n) {
|
|
@@ -1881,15 +1883,15 @@ function it(e, n) {
|
|
|
1881
1883
|
var Xt = {
|
|
1882
1884
|
YAML: function(e, n, t) {
|
|
1883
1885
|
var r, a, i;
|
|
1884
|
-
e.version !== null &&
|
|
1886
|
+
e.version !== null && T(e, "duplication of %YAML directive"), t.length !== 1 && T(e, "YAML directive accepts exactly one argument"), r = /^([0-9]+)\.([0-9]+)$/.exec(t[0]), r === null && T(e, "ill-formed argument of the YAML directive"), a = parseInt(r[1], 10), i = parseInt(r[2], 10), a !== 1 && T(e, "unacceptable YAML version of the document"), e.version = t[0], e.checkLineBreaks = i < 2, i !== 1 && i !== 2 && it(e, "unsupported YAML version of the document");
|
|
1885
1887
|
},
|
|
1886
1888
|
TAG: function(e, n, t) {
|
|
1887
1889
|
var r, a;
|
|
1888
|
-
t.length !== 2 &&
|
|
1890
|
+
t.length !== 2 && T(e, "TAG directive accepts exactly two arguments"), r = t[0], a = t[1], Wn.test(r) || T(e, "ill-formed tag handle (first argument) of the TAG directive"), Ne.call(e.tagMap, r) && T(e, 'there is a previously declared suffix for "' + r + '" tag handle'), Yn.test(a) || T(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1889
1891
|
try {
|
|
1890
1892
|
a = decodeURIComponent(a);
|
|
1891
1893
|
} catch {
|
|
1892
|
-
|
|
1894
|
+
T(e, "tag prefix is malformed: " + a);
|
|
1893
1895
|
}
|
|
1894
1896
|
e.tagMap[r] = a;
|
|
1895
1897
|
}
|
|
@@ -1899,22 +1901,22 @@ function Ee(e, n, t, r) {
|
|
|
1899
1901
|
if (n < t) {
|
|
1900
1902
|
if (s = e.input.slice(n, t), r)
|
|
1901
1903
|
for (a = 0, i = s.length; a < i; a += 1)
|
|
1902
|
-
o = s.charCodeAt(a), o === 9 || 32 <= o && o <= 1114111 ||
|
|
1904
|
+
o = s.charCodeAt(a), o === 9 || 32 <= o && o <= 1114111 || T(e, "expected valid JSON character");
|
|
1903
1905
|
else
|
|
1904
|
-
Uo.test(s) &&
|
|
1906
|
+
Uo.test(s) && T(e, "the stream contains non-printable characters");
|
|
1905
1907
|
e.result += s;
|
|
1906
1908
|
}
|
|
1907
1909
|
}
|
|
1908
1910
|
function en(e, n, t, r) {
|
|
1909
1911
|
var a, i, o, s;
|
|
1910
|
-
for (ce.isObject(t) ||
|
|
1911
|
-
i = a[o],
|
|
1912
|
+
for (ce.isObject(t) || T(e, "cannot merge mappings; the provided source object is unacceptable"), a = Object.keys(t), o = 0, s = a.length; o < s; o += 1)
|
|
1913
|
+
i = a[o], Ne.call(n, i) || (n[i] = t[i], r[i] = !0);
|
|
1912
1914
|
}
|
|
1913
1915
|
function De(e, n, t, r, a, i, o, s, l) {
|
|
1914
1916
|
var u, p;
|
|
1915
1917
|
if (Array.isArray(a))
|
|
1916
1918
|
for (a = Array.prototype.slice.call(a), u = 0, p = a.length; u < p; u += 1)
|
|
1917
|
-
Array.isArray(a[u]) &&
|
|
1919
|
+
Array.isArray(a[u]) && T(e, "nested arrays are not supported inside keys"), typeof a == "object" && Zt(a[u]) === "[object Object]" && (a[u] = "[object Object]");
|
|
1918
1920
|
if (typeof a == "object" && Zt(a) === "[object Object]" && (a = "[object Object]"), a = String(a), n === null && (n = {}), r === "tag:yaml.org,2002:merge")
|
|
1919
1921
|
if (Array.isArray(i))
|
|
1920
1922
|
for (u = 0, p = i.length; u < p; u += 1)
|
|
@@ -1922,7 +1924,7 @@ function De(e, n, t, r, a, i, o, s, l) {
|
|
|
1922
1924
|
else
|
|
1923
1925
|
en(e, n, i, t);
|
|
1924
1926
|
else
|
|
1925
|
-
!e.json && !
|
|
1927
|
+
!e.json && !Ne.call(t, a) && Ne.call(n, a) && (e.line = o || e.line, e.lineStart = s || e.lineStart, e.position = l || e.position, T(e, "duplicated mapping key")), a === "__proto__" ? Object.defineProperty(n, a, {
|
|
1926
1928
|
configurable: !0,
|
|
1927
1929
|
enumerable: !0,
|
|
1928
1930
|
writable: !0,
|
|
@@ -1932,11 +1934,11 @@ function De(e, n, t, r, a, i, o, s, l) {
|
|
|
1932
1934
|
}
|
|
1933
1935
|
function Mt(e) {
|
|
1934
1936
|
var n;
|
|
1935
|
-
n = e.input.charCodeAt(e.position), n === 10 ? e.position++ : n === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) :
|
|
1937
|
+
n = e.input.charCodeAt(e.position), n === 10 ? e.position++ : n === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : T(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1;
|
|
1936
1938
|
}
|
|
1937
1939
|
function le(e, n, t) {
|
|
1938
1940
|
for (var r = 0, a = e.input.charCodeAt(e.position); a !== 0; ) {
|
|
1939
|
-
for (;
|
|
1941
|
+
for (; Be(a); )
|
|
1940
1942
|
a === 9 && e.firstTabInLine === -1 && (e.firstTabInLine = e.position), a = e.input.charCodeAt(++e.position);
|
|
1941
1943
|
if (n && a === 35)
|
|
1942
1944
|
do
|
|
@@ -1981,7 +1983,7 @@ function Jo(e, n, t) {
|
|
|
1981
1983
|
break;
|
|
1982
1984
|
}
|
|
1983
1985
|
}
|
|
1984
|
-
s && (Ee(e, i, o, !1), Et(e, e.line - l), i = o = e.position, s = !1),
|
|
1986
|
+
s && (Ee(e, i, o, !1), Et(e, e.line - l), i = o = e.position, s = !1), Be(d) || (o = e.position + 1), d = e.input.charCodeAt(++e.position);
|
|
1985
1987
|
}
|
|
1986
1988
|
return Ee(e, i, o, !1), e.result ? !0 : (e.kind = c, e.result = g, !1);
|
|
1987
1989
|
}
|
|
@@ -1996,8 +1998,8 @@ function Wo(e, n) {
|
|
|
1996
1998
|
else
|
|
1997
1999
|
return !0;
|
|
1998
2000
|
else
|
|
1999
|
-
Se(t) ? (Ee(e, r, a, !0), Et(e, le(e, !1, n)), r = a = e.position) : e.position === e.lineStart && pt(e) ?
|
|
2000
|
-
|
|
2001
|
+
Se(t) ? (Ee(e, r, a, !0), Et(e, le(e, !1, n)), r = a = e.position) : e.position === e.lineStart && pt(e) ? T(e, "unexpected end of the document within a single quoted scalar") : (e.position++, a = e.position);
|
|
2002
|
+
T(e, "unexpected end of the stream within a single quoted scalar");
|
|
2001
2003
|
}
|
|
2002
2004
|
function Yo(e, n) {
|
|
2003
2005
|
var t, r, a, i, o, s;
|
|
@@ -2013,15 +2015,15 @@ function Yo(e, n) {
|
|
|
2013
2015
|
e.result += Qn[s], e.position++;
|
|
2014
2016
|
else if ((o = Ro(s)) > 0) {
|
|
2015
2017
|
for (a = o, i = 0; a > 0; a--)
|
|
2016
|
-
s = e.input.charCodeAt(++e.position), (o = Vo(s)) >= 0 ? i = (i << 4) + o :
|
|
2017
|
-
e.result +=
|
|
2018
|
+
s = e.input.charCodeAt(++e.position), (o = Vo(s)) >= 0 ? i = (i << 4) + o : T(e, "expected hexadecimal character");
|
|
2019
|
+
e.result += zo(i), e.position++;
|
|
2018
2020
|
} else
|
|
2019
|
-
|
|
2021
|
+
T(e, "unknown escape sequence");
|
|
2020
2022
|
t = r = e.position;
|
|
2021
2023
|
} else
|
|
2022
|
-
Se(s) ? (Ee(e, t, r, !0), Et(e, le(e, !1, n)), t = r = e.position) : e.position === e.lineStart && pt(e) ?
|
|
2024
|
+
Se(s) ? (Ee(e, t, r, !0), Et(e, le(e, !1, n)), t = r = e.position) : e.position === e.lineStart && pt(e) ? T(e, "unexpected end of the document within a double quoted scalar") : (e.position++, r = e.position);
|
|
2023
2025
|
}
|
|
2024
|
-
|
|
2026
|
+
T(e, "unexpected end of the stream within a double quoted scalar");
|
|
2025
2027
|
}
|
|
2026
2028
|
function Zo(e, n) {
|
|
2027
2029
|
var t = !0, r, a, i, o = e.tag, s, l = e.anchor, u, p, c, g, d, _ = /* @__PURE__ */ Object.create(null), v, S, y, b;
|
|
@@ -2034,9 +2036,9 @@ function Zo(e, n) {
|
|
|
2034
2036
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), b = e.input.charCodeAt(++e.position); b !== 0; ) {
|
|
2035
2037
|
if (le(e, !0, n), b = e.input.charCodeAt(e.position), b === p)
|
|
2036
2038
|
return e.position++, e.tag = o, e.anchor = l, e.kind = d ? "mapping" : "sequence", e.result = s, !0;
|
|
2037
|
-
t ? b === 44 &&
|
|
2039
|
+
t ? b === 44 && T(e, "expected the node content, but found ','") : T(e, "missed comma between flow collection entries"), S = v = y = null, c = g = !1, b === 63 && (u = e.input.charCodeAt(e.position + 1), be(u) && (c = g = !0, e.position++, le(e, !0, n))), r = e.line, a = e.lineStart, i = e.position, Re(e, n, at, !1, !0), S = e.tag, v = e.result, le(e, !0, n), b = e.input.charCodeAt(e.position), (g || e.line === r) && b === 58 && (c = !0, b = e.input.charCodeAt(++e.position), le(e, !0, n), Re(e, n, at, !1, !0), y = e.result), d ? De(e, s, _, S, v, y, r, a, i) : c ? s.push(De(e, null, _, S, v, y, r, a, i)) : s.push(v), le(e, !0, n), b = e.input.charCodeAt(e.position), b === 44 ? (t = !0, b = e.input.charCodeAt(++e.position)) : t = !1;
|
|
2038
2040
|
}
|
|
2039
|
-
|
|
2041
|
+
T(e, "unexpected end of the stream within a flow collection");
|
|
2040
2042
|
}
|
|
2041
2043
|
function Qo(e, n) {
|
|
2042
2044
|
var t, r, a = ht, i = !1, o = !1, s = n, l = 0, u = !1, p, c;
|
|
@@ -2048,15 +2050,15 @@ function Qo(e, n) {
|
|
|
2048
2050
|
return !1;
|
|
2049
2051
|
for (e.kind = "scalar", e.result = ""; c !== 0; )
|
|
2050
2052
|
if (c = e.input.charCodeAt(++e.position), c === 43 || c === 45)
|
|
2051
|
-
ht === a ? a = c === 43 ? Yt : Lo :
|
|
2053
|
+
ht === a ? a = c === 43 ? Yt : Lo : T(e, "repeat of a chomping mode identifier");
|
|
2052
2054
|
else if ((p = Go(c)) >= 0)
|
|
2053
|
-
p === 0 ?
|
|
2055
|
+
p === 0 ? T(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : o ? T(e, "repeat of an indentation width identifier") : (s = n + p - 1, o = !0);
|
|
2054
2056
|
else
|
|
2055
2057
|
break;
|
|
2056
|
-
if (
|
|
2058
|
+
if (Be(c)) {
|
|
2057
2059
|
do
|
|
2058
2060
|
c = e.input.charCodeAt(++e.position);
|
|
2059
|
-
while (
|
|
2061
|
+
while (Be(c));
|
|
2060
2062
|
if (c === 35)
|
|
2061
2063
|
do
|
|
2062
2064
|
c = e.input.charCodeAt(++e.position);
|
|
@@ -2075,7 +2077,7 @@ function Qo(e, n) {
|
|
|
2075
2077
|
`);
|
|
2076
2078
|
break;
|
|
2077
2079
|
}
|
|
2078
|
-
for (r ?
|
|
2080
|
+
for (r ? Be(c) ? (u = !0, e.result += ce.repeat(`
|
|
2079
2081
|
`, i ? 1 + l : l)) : u ? (u = !1, e.result += ce.repeat(`
|
|
2080
2082
|
`, l + 1)) : l === 0 ? i && (e.result += " ") : e.result += ce.repeat(`
|
|
2081
2083
|
`, l) : e.result += ce.repeat(`
|
|
@@ -2089,13 +2091,13 @@ function tn(e, n) {
|
|
|
2089
2091
|
var t, r = e.tag, a = e.anchor, i = [], o, s = !1, l;
|
|
2090
2092
|
if (e.firstTabInLine !== -1)
|
|
2091
2093
|
return !1;
|
|
2092
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = i), l = e.input.charCodeAt(e.position); l !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine,
|
|
2094
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = i), l = e.input.charCodeAt(e.position); l !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, T(e, "tab characters must not be used in indentation")), !(l !== 45 || (o = e.input.charCodeAt(e.position + 1), !be(o)))); ) {
|
|
2093
2095
|
if (s = !0, e.position++, le(e, !0, -1) && e.lineIndent <= n) {
|
|
2094
2096
|
i.push(null), l = e.input.charCodeAt(e.position);
|
|
2095
2097
|
continue;
|
|
2096
2098
|
}
|
|
2097
2099
|
if (t = e.line, Re(e, n, Jn, !1, !0), i.push(e.result), le(e, !0, -1), l = e.input.charCodeAt(e.position), (e.line === t || e.lineIndent > n) && l !== 0)
|
|
2098
|
-
|
|
2100
|
+
T(e, "bad indentation of a sequence entry");
|
|
2099
2101
|
else if (e.lineIndent < n)
|
|
2100
2102
|
break;
|
|
2101
2103
|
}
|
|
@@ -2106,27 +2108,27 @@ function Xo(e, n, t) {
|
|
|
2106
2108
|
if (e.firstTabInLine !== -1)
|
|
2107
2109
|
return !1;
|
|
2108
2110
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = c), b = e.input.charCodeAt(e.position); b !== 0; ) {
|
|
2109
|
-
if (!S && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine,
|
|
2110
|
-
b === 63 ? (S && (De(e, c, g, d, _, null, o, s, l), d = _ = v = null), y = !0, S = !0, a = !0) : S ? (S = !1, a = !0) :
|
|
2111
|
+
if (!S && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, T(e, "tab characters must not be used in indentation")), r = e.input.charCodeAt(e.position + 1), i = e.line, (b === 63 || b === 58) && be(r))
|
|
2112
|
+
b === 63 ? (S && (De(e, c, g, d, _, null, o, s, l), d = _ = v = null), y = !0, S = !0, a = !0) : S ? (S = !1, a = !0) : T(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, b = r;
|
|
2111
2113
|
else {
|
|
2112
|
-
if (o = e.line, s = e.lineStart, l = e.position, !Re(e, t,
|
|
2114
|
+
if (o = e.line, s = e.lineStart, l = e.position, !Re(e, t, Hn, !1, !0))
|
|
2113
2115
|
break;
|
|
2114
2116
|
if (e.line === i) {
|
|
2115
|
-
for (b = e.input.charCodeAt(e.position);
|
|
2117
|
+
for (b = e.input.charCodeAt(e.position); Be(b); )
|
|
2116
2118
|
b = e.input.charCodeAt(++e.position);
|
|
2117
2119
|
if (b === 58)
|
|
2118
|
-
b = e.input.charCodeAt(++e.position), be(b) ||
|
|
2120
|
+
b = e.input.charCodeAt(++e.position), be(b) || T(e, "a whitespace character is expected after the key-value separator within a block mapping"), S && (De(e, c, g, d, _, null, o, s, l), d = _ = v = null), y = !0, S = !1, a = !1, d = e.tag, _ = e.result;
|
|
2119
2121
|
else if (y)
|
|
2120
|
-
|
|
2122
|
+
T(e, "can not read an implicit mapping pair; a colon is missed");
|
|
2121
2123
|
else
|
|
2122
2124
|
return e.tag = u, e.anchor = p, !0;
|
|
2123
2125
|
} else if (y)
|
|
2124
|
-
|
|
2126
|
+
T(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
2125
2127
|
else
|
|
2126
2128
|
return e.tag = u, e.anchor = p, !0;
|
|
2127
2129
|
}
|
|
2128
2130
|
if ((e.line === i || e.lineIndent > n) && (S && (o = e.line, s = e.lineStart, l = e.position), Re(e, n, ot, !0, a) && (S ? _ = e.result : v = e.result), S || (De(e, c, g, d, _, v, o, s, l), d = _ = v = null), le(e, !0, -1), b = e.input.charCodeAt(e.position)), (e.line === i || e.lineIndent > n) && b !== 0)
|
|
2129
|
-
|
|
2131
|
+
T(e, "bad indentation of a mapping entry");
|
|
2130
2132
|
else if (e.lineIndent < n)
|
|
2131
2133
|
break;
|
|
2132
2134
|
}
|
|
@@ -2136,31 +2138,31 @@ function ei(e) {
|
|
|
2136
2138
|
var n, t = !1, r = !1, a, i, o;
|
|
2137
2139
|
if (o = e.input.charCodeAt(e.position), o !== 33)
|
|
2138
2140
|
return !1;
|
|
2139
|
-
if (e.tag !== null &&
|
|
2141
|
+
if (e.tag !== null && T(e, "duplication of a tag property"), o = e.input.charCodeAt(++e.position), o === 60 ? (t = !0, o = e.input.charCodeAt(++e.position)) : o === 33 ? (r = !0, a = "!!", o = e.input.charCodeAt(++e.position)) : a = "!", n = e.position, t) {
|
|
2140
2142
|
do
|
|
2141
2143
|
o = e.input.charCodeAt(++e.position);
|
|
2142
2144
|
while (o !== 0 && o !== 62);
|
|
2143
|
-
e.position < e.length ? (i = e.input.slice(n, e.position), o = e.input.charCodeAt(++e.position)) :
|
|
2145
|
+
e.position < e.length ? (i = e.input.slice(n, e.position), o = e.input.charCodeAt(++e.position)) : T(e, "unexpected end of the stream within a verbatim tag");
|
|
2144
2146
|
} else {
|
|
2145
2147
|
for (; o !== 0 && !be(o); )
|
|
2146
|
-
o === 33 && (r ?
|
|
2147
|
-
i = e.input.slice(n, e.position), Do.test(i) &&
|
|
2148
|
+
o === 33 && (r ? T(e, "tag suffix cannot contain exclamation marks") : (a = e.input.slice(n - 1, e.position + 1), Wn.test(a) || T(e, "named tag handle cannot contain such characters"), r = !0, n = e.position + 1)), o = e.input.charCodeAt(++e.position);
|
|
2149
|
+
i = e.input.slice(n, e.position), Do.test(i) && T(e, "tag suffix cannot contain flow indicator characters");
|
|
2148
2150
|
}
|
|
2149
|
-
i && !Yn.test(i) &&
|
|
2151
|
+
i && !Yn.test(i) && T(e, "tag name cannot contain such characters: " + i);
|
|
2150
2152
|
try {
|
|
2151
2153
|
i = decodeURIComponent(i);
|
|
2152
2154
|
} catch {
|
|
2153
|
-
|
|
2155
|
+
T(e, "tag name is malformed: " + i);
|
|
2154
2156
|
}
|
|
2155
|
-
return t ? e.tag = i :
|
|
2157
|
+
return t ? e.tag = i : Ne.call(e.tagMap, a) ? e.tag = e.tagMap[a] + i : a === "!" ? e.tag = "!" + i : a === "!!" ? e.tag = "tag:yaml.org,2002:" + i : T(e, 'undeclared tag handle "' + a + '"'), !0;
|
|
2156
2158
|
}
|
|
2157
2159
|
function ti(e) {
|
|
2158
2160
|
var n, t;
|
|
2159
2161
|
if (t = e.input.charCodeAt(e.position), t !== 38)
|
|
2160
2162
|
return !1;
|
|
2161
|
-
for (e.anchor !== null &&
|
|
2163
|
+
for (e.anchor !== null && T(e, "duplication of an anchor property"), t = e.input.charCodeAt(++e.position), n = e.position; t !== 0 && !be(t) && !Pe(t); )
|
|
2162
2164
|
t = e.input.charCodeAt(++e.position);
|
|
2163
|
-
return e.position === n &&
|
|
2165
|
+
return e.position === n && T(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(n, e.position), !0;
|
|
2164
2166
|
}
|
|
2165
2167
|
function ni(e) {
|
|
2166
2168
|
var n, t, r;
|
|
@@ -2168,23 +2170,23 @@ function ni(e) {
|
|
|
2168
2170
|
return !1;
|
|
2169
2171
|
for (r = e.input.charCodeAt(++e.position), n = e.position; r !== 0 && !be(r) && !Pe(r); )
|
|
2170
2172
|
r = e.input.charCodeAt(++e.position);
|
|
2171
|
-
return e.position === n &&
|
|
2173
|
+
return e.position === n && T(e, "name of an alias node must contain at least one character"), t = e.input.slice(n, e.position), Ne.call(e.anchorMap, t) || T(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], le(e, !0, -1), !0;
|
|
2172
2174
|
}
|
|
2173
2175
|
function Re(e, n, t, r, a) {
|
|
2174
2176
|
var i, o, s, l = 1, u = !1, p = !1, c, g, d, _, v, S;
|
|
2175
2177
|
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, i = o = s = ot === t || Jn === t, r && le(e, !0, -1) && (u = !0, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)), l === 1)
|
|
2176
2178
|
for (; ei(e) || ti(e); )
|
|
2177
2179
|
le(e, !0, -1) ? (u = !0, s = i, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)) : s = !1;
|
|
2178
|
-
if (s && (s = u || a), (l === 1 || ot === t) && (at === t ||
|
|
2180
|
+
if (s && (s = u || a), (l === 1 || ot === t) && (at === t || Hn === t ? v = n : v = n + 1, S = e.position - e.lineStart, l === 1 ? s && (tn(e, S) || Xo(e, S, v)) || Zo(e, v) ? p = !0 : (o && Qo(e, v) || Wo(e, v) || Yo(e, v) ? p = !0 : ni(e) ? (p = !0, (e.tag !== null || e.anchor !== null) && T(e, "alias node should not have any properties")) : Jo(e, v, at === t) && (p = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : l === 0 && (p = s && tn(e, S))), e.tag === null)
|
|
2179
2181
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2180
2182
|
else if (e.tag === "?") {
|
|
2181
|
-
for (e.result !== null && e.kind !== "scalar" &&
|
|
2183
|
+
for (e.result !== null && e.kind !== "scalar" && T(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), c = 0, g = e.implicitTypes.length; c < g; c += 1)
|
|
2182
2184
|
if (_ = e.implicitTypes[c], _.resolve(e.result)) {
|
|
2183
2185
|
e.result = _.construct(e.result), e.tag = _.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2184
2186
|
break;
|
|
2185
2187
|
}
|
|
2186
2188
|
} else if (e.tag !== "!") {
|
|
2187
|
-
if (
|
|
2189
|
+
if (Ne.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
2188
2190
|
_ = e.typeMap[e.kind || "fallback"][e.tag];
|
|
2189
2191
|
else
|
|
2190
2192
|
for (_ = null, d = e.typeMap.multi[e.kind || "fallback"], c = 0, g = d.length; c < g; c += 1)
|
|
@@ -2192,7 +2194,7 @@ function Re(e, n, t, r, a) {
|
|
|
2192
2194
|
_ = d[c];
|
|
2193
2195
|
break;
|
|
2194
2196
|
}
|
|
2195
|
-
_ ||
|
|
2197
|
+
_ || T(e, "unknown tag !<" + e.tag + ">"), e.result !== null && _.kind !== e.kind && T(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + _.kind + '", not "' + e.kind + '"'), _.resolve(e.result, e.tag) ? (e.result = _.construct(e.result, e.tag), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : T(e, "cannot resolve a node with !<" + e.tag + "> explicit tag");
|
|
2196
2198
|
}
|
|
2197
2199
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || p;
|
|
2198
2200
|
}
|
|
@@ -2201,8 +2203,8 @@ function ri(e) {
|
|
|
2201
2203
|
for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = /* @__PURE__ */ Object.create(null), e.anchorMap = /* @__PURE__ */ Object.create(null); (o = e.input.charCodeAt(e.position)) !== 0 && (le(e, !0, -1), o = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || o !== 37)); ) {
|
|
2202
2204
|
for (i = !0, o = e.input.charCodeAt(++e.position), t = e.position; o !== 0 && !be(o); )
|
|
2203
2205
|
o = e.input.charCodeAt(++e.position);
|
|
2204
|
-
for (r = e.input.slice(t, e.position), a = [], r.length < 1 &&
|
|
2205
|
-
for (;
|
|
2206
|
+
for (r = e.input.slice(t, e.position), a = [], r.length < 1 && T(e, "directive name must not be less than one character in length"); o !== 0; ) {
|
|
2207
|
+
for (; Be(o); )
|
|
2206
2208
|
o = e.input.charCodeAt(++e.position);
|
|
2207
2209
|
if (o === 35) {
|
|
2208
2210
|
do
|
|
@@ -2216,22 +2218,22 @@ function ri(e) {
|
|
|
2216
2218
|
o = e.input.charCodeAt(++e.position);
|
|
2217
2219
|
a.push(e.input.slice(t, e.position));
|
|
2218
2220
|
}
|
|
2219
|
-
o !== 0 && Mt(e),
|
|
2221
|
+
o !== 0 && Mt(e), Ne.call(Xt, r) ? Xt[r](e, r, a) : it(e, 'unknown document directive "' + r + '"');
|
|
2220
2222
|
}
|
|
2221
|
-
if (le(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, le(e, !0, -1)) : i &&
|
|
2223
|
+
if (le(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, le(e, !0, -1)) : i && T(e, "directives end mark is expected"), Re(e, e.lineIndent - 1, ot, !1, !0), le(e, !0, -1), e.checkLineBreaks && Po.test(e.input.slice(n, e.position)) && it(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && pt(e)) {
|
|
2222
2224
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, le(e, !0, -1));
|
|
2223
2225
|
return;
|
|
2224
2226
|
}
|
|
2225
2227
|
if (e.position < e.length - 1)
|
|
2226
|
-
|
|
2228
|
+
T(e, "end of the stream or a document separator is expected");
|
|
2227
2229
|
else
|
|
2228
2230
|
return;
|
|
2229
2231
|
}
|
|
2230
2232
|
function er(e, n) {
|
|
2231
2233
|
e = String(e), n = n || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2232
2234
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2233
|
-
var t = new
|
|
2234
|
-
for (r !== -1 && (t.position = r,
|
|
2235
|
+
var t = new Ho(e, n), r = e.indexOf("\0");
|
|
2236
|
+
for (r !== -1 && (t.position = r, T(t, "null byte is not allowed in input")), t.input += "\0"; t.input.charCodeAt(t.position) === 32; )
|
|
2235
2237
|
t.lineIndent += 1, t.position += 1;
|
|
2236
2238
|
for (; t.position < t.length - 1; )
|
|
2237
2239
|
ri(t);
|
|
@@ -2310,9 +2312,9 @@ function xi(e) {
|
|
|
2310
2312
|
throw new ge("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2311
2313
|
return "\\" + t + ce.repeat("0", r - n.length) + n;
|
|
2312
2314
|
}
|
|
2313
|
-
var
|
|
2314
|
-
function
|
|
2315
|
-
this.schema = e.schema || jt, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = ce.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = Ai(this.schema, e.styles || null), this.sortKeys = e.sortKeys || !1, this.lineWidth = e.lineWidth || 80, this.noRefs = e.noRefs || !1, this.noCompatMode = e.noCompatMode || !1, this.condenseFlow = e.condenseFlow || !1, this.quotingType = e.quotingType === '"' ? Xe :
|
|
2315
|
+
var $i = 1, Xe = 2;
|
|
2316
|
+
function Ti(e) {
|
|
2317
|
+
this.schema = e.schema || jt, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = ce.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = Ai(this.schema, e.styles || null), this.sortKeys = e.sortKeys || !1, this.lineWidth = e.lineWidth || 80, this.noRefs = e.noRefs || !1, this.noCompatMode = e.noCompatMode || !1, this.condenseFlow = e.condenseFlow || !1, this.quotingType = e.quotingType === '"' ? Xe : $i, this.forceQuotes = e.forceQuotes || !1, this.replacer = typeof e.replacer == "function" ? e.replacer : null, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null;
|
|
2316
2318
|
}
|
|
2317
2319
|
function nn(e, n) {
|
|
2318
2320
|
for (var t = ce.repeat(" ", n), r = 0, a = -1, i = "", o, s = e.length; r < s; )
|
|
@@ -2387,7 +2389,7 @@ function Oi(e, n, t, r, a, i, o, s) {
|
|
|
2387
2389
|
}
|
|
2388
2390
|
return !c && !g ? v && !o && !a(e) ? cr : i === Xe ? Ue : wt : t > 9 && ur(e) ? Ue : o ? i === Xe ? Ue : wt : g ? pr : dr;
|
|
2389
2391
|
}
|
|
2390
|
-
function
|
|
2392
|
+
function Ni(e, n, t, r, a) {
|
|
2391
2393
|
e.dump = function() {
|
|
2392
2394
|
if (n.length === 0)
|
|
2393
2395
|
return e.quotingType === Xe ? '""' : "''";
|
|
@@ -2414,9 +2416,9 @@ function Fi(e, n, t, r, a) {
|
|
|
2414
2416
|
case dr:
|
|
2415
2417
|
return "|" + on(n, e.indent) + sn(nn(n, i));
|
|
2416
2418
|
case pr:
|
|
2417
|
-
return ">" + on(n, e.indent) + sn(nn(
|
|
2419
|
+
return ">" + on(n, e.indent) + sn(nn(Ki(n, o), i));
|
|
2418
2420
|
case Ue:
|
|
2419
|
-
return '"' +
|
|
2421
|
+
return '"' + Bi(n) + '"';
|
|
2420
2422
|
default:
|
|
2421
2423
|
throw new ge("impossible error: invalid scalar style");
|
|
2422
2424
|
}
|
|
@@ -2434,7 +2436,7 @@ function sn(e) {
|
|
|
2434
2436
|
return e[e.length - 1] === `
|
|
2435
2437
|
` ? e.slice(0, -1) : e;
|
|
2436
2438
|
}
|
|
2437
|
-
function
|
|
2439
|
+
function Ki(e, n) {
|
|
2438
2440
|
for (var t = /(\n+)([^\n]*)/g, r = function() {
|
|
2439
2441
|
var u = e.indexOf(`
|
|
2440
2442
|
`);
|
|
@@ -2457,27 +2459,27 @@ function ln(e, n) {
|
|
|
2457
2459
|
`, e.length - a > n && o > a ? l += e.slice(a, o) + `
|
|
2458
2460
|
` + e.slice(o + 1) : l += e.slice(a), l.slice(1);
|
|
2459
2461
|
}
|
|
2460
|
-
function
|
|
2462
|
+
function Bi(e) {
|
|
2461
2463
|
for (var n = "", t = 0, r, a = 0; a < e.length; t >= 65536 ? a += 2 : a++)
|
|
2462
2464
|
t = Je(e, a), r = me[t], !r && et(t) ? (n += e[a], t >= 65536 && (n += e[a + 1])) : n += r || xi(t);
|
|
2463
2465
|
return n;
|
|
2464
2466
|
}
|
|
2465
|
-
function
|
|
2467
|
+
function Fi(e, n, t) {
|
|
2466
2468
|
var r = "", a = e.tag, i, o, s;
|
|
2467
2469
|
for (i = 0, o = t.length; i < o; i += 1)
|
|
2468
|
-
s = t[i], e.replacer && (s = e.replacer.call(t, String(i), s)), (
|
|
2470
|
+
s = t[i], e.replacer && (s = e.replacer.call(t, String(i), s)), (Te(e, n, s, !1, !1) || typeof s > "u" && Te(e, n, null, !1, !1)) && (r !== "" && (r += "," + (e.condenseFlow ? "" : " ")), r += e.dump);
|
|
2469
2471
|
e.tag = a, e.dump = "[" + r + "]";
|
|
2470
2472
|
}
|
|
2471
2473
|
function un(e, n, t, r) {
|
|
2472
2474
|
var a = "", i = e.tag, o, s, l;
|
|
2473
2475
|
for (o = 0, s = t.length; o < s; o += 1)
|
|
2474
|
-
l = t[o], e.replacer && (l = e.replacer.call(t, String(o), l)), (
|
|
2476
|
+
l = t[o], e.replacer && (l = e.replacer.call(t, String(o), l)), (Te(e, n + 1, l, !0, !0, !1, !0) || typeof l > "u" && Te(e, n + 1, null, !0, !0, !1, !0)) && ((!r || a !== "") && (a += kt(e, n)), e.dump && Qe === e.dump.charCodeAt(0) ? a += "-" : a += "- ", a += e.dump);
|
|
2475
2477
|
e.tag = i, e.dump = a || "[]";
|
|
2476
2478
|
}
|
|
2477
2479
|
function qi(e, n, t) {
|
|
2478
2480
|
var r = "", a = e.tag, i = Object.keys(t), o, s, l, u, p;
|
|
2479
2481
|
for (o = 0, s = i.length; o < s; o += 1)
|
|
2480
|
-
p = "", r !== "" && (p += ", "), e.condenseFlow && (p += '"'), l = i[o], u = t[l], e.replacer && (u = e.replacer.call(t, l, u)),
|
|
2482
|
+
p = "", r !== "" && (p += ", "), e.condenseFlow && (p += '"'), l = i[o], u = t[l], e.replacer && (u = e.replacer.call(t, l, u)), Te(e, n, l, !1, !1) && (e.dump.length > 1024 && (p += "? "), p += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Te(e, n, u, !1, !1) && (p += e.dump, r += p));
|
|
2481
2483
|
e.tag = a, e.dump = "{" + r + "}";
|
|
2482
2484
|
}
|
|
2483
2485
|
function Li(e, n, t, r) {
|
|
@@ -2489,7 +2491,7 @@ function Li(e, n, t, r) {
|
|
|
2489
2491
|
else if (e.sortKeys)
|
|
2490
2492
|
throw new ge("sortKeys must be a boolean or a function");
|
|
2491
2493
|
for (s = 0, l = o.length; s < l; s += 1)
|
|
2492
|
-
g = "", (!r || a !== "") && (g += kt(e, n)), u = o[s], p = t[u], e.replacer && (p = e.replacer.call(t, u, p)),
|
|
2494
|
+
g = "", (!r || a !== "") && (g += kt(e, n)), u = o[s], p = t[u], e.replacer && (p = e.replacer.call(t, u, p)), Te(e, n + 1, u, !0, !0, !0) && (c = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, c && (e.dump && Qe === e.dump.charCodeAt(0) ? g += "?" : g += "? "), g += e.dump, c && (g += kt(e, n)), Te(e, n + 1, p, !0, c) && (e.dump && Qe === e.dump.charCodeAt(0) ? g += ":" : g += ": ", g += e.dump, a += g));
|
|
2493
2495
|
e.tag = i, e.dump = a || "{}";
|
|
2494
2496
|
}
|
|
2495
2497
|
function cn(e, n, t) {
|
|
@@ -2509,7 +2511,7 @@ function cn(e, n, t) {
|
|
|
2509
2511
|
}
|
|
2510
2512
|
return !1;
|
|
2511
2513
|
}
|
|
2512
|
-
function
|
|
2514
|
+
function Te(e, n, t, r, a, i, o) {
|
|
2513
2515
|
e.tag = null, e.dump = t, cn(e, t, !1) || cn(e, t, !0);
|
|
2514
2516
|
var s = nr.call(e.dump), l = r, u;
|
|
2515
2517
|
r && (r = e.flowLevel < 0 || e.flowLevel > n);
|
|
@@ -2520,9 +2522,9 @@ function $e(e, n, t, r, a, i, o) {
|
|
|
2520
2522
|
if (p && g && !e.usedDuplicates[c] && (e.usedDuplicates[c] = !0), s === "[object Object]")
|
|
2521
2523
|
r && Object.keys(e.dump).length !== 0 ? (Li(e, n, e.dump, a), g && (e.dump = "&ref_" + c + e.dump)) : (qi(e, n, e.dump), g && (e.dump = "&ref_" + c + " " + e.dump));
|
|
2522
2524
|
else if (s === "[object Array]")
|
|
2523
|
-
r && e.dump.length !== 0 ? (e.noArrayIndent && !o && n > 0 ? un(e, n - 1, e.dump, a) : un(e, n, e.dump, a), g && (e.dump = "&ref_" + c + e.dump)) : (
|
|
2525
|
+
r && e.dump.length !== 0 ? (e.noArrayIndent && !o && n > 0 ? un(e, n - 1, e.dump, a) : un(e, n, e.dump, a), g && (e.dump = "&ref_" + c + e.dump)) : (Fi(e, n, e.dump), g && (e.dump = "&ref_" + c + " " + e.dump));
|
|
2524
2526
|
else if (s === "[object String]")
|
|
2525
|
-
e.tag !== "?" &&
|
|
2527
|
+
e.tag !== "?" && Ni(e, e.dump, n, i, l);
|
|
2526
2528
|
else {
|
|
2527
2529
|
if (s === "[object Undefined]" || e.skipInvalid)
|
|
2528
2530
|
return !1;
|
|
@@ -2554,39 +2556,39 @@ function _t(e, n, t) {
|
|
|
2554
2556
|
}
|
|
2555
2557
|
function Pi(e, n) {
|
|
2556
2558
|
n = n || {};
|
|
2557
|
-
var t = new
|
|
2559
|
+
var t = new Ti(n);
|
|
2558
2560
|
t.noRefs || Ui(e, t);
|
|
2559
2561
|
var r = e;
|
|
2560
|
-
return t.replacer && (r = t.replacer.call({ "": r }, "", r)),
|
|
2562
|
+
return t.replacer && (r = t.replacer.call({ "": r }, "", r)), Te(t, 0, r, !0, !0) ? t.dump + `
|
|
2561
2563
|
` : "";
|
|
2562
2564
|
}
|
|
2563
2565
|
var Di = Pi, Vi = {
|
|
2564
2566
|
dump: Di
|
|
2565
2567
|
};
|
|
2566
|
-
function
|
|
2568
|
+
function Nt(e, n) {
|
|
2567
2569
|
return function() {
|
|
2568
2570
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + n + " instead, which is now safe by default.");
|
|
2569
2571
|
};
|
|
2570
2572
|
}
|
|
2571
|
-
var Ri = fe, Gi =
|
|
2573
|
+
var Ri = fe, Gi = $n, zi = En, Hi = Fn, Ji = qn, Wi = jt, Yi = tr.load, Zi = tr.loadAll, Qi = Vi.dump, Xi = ge, es = {
|
|
2572
2574
|
binary: Vn,
|
|
2573
|
-
float:
|
|
2575
|
+
float: Bn,
|
|
2574
2576
|
map: Mn,
|
|
2575
2577
|
null: On,
|
|
2576
2578
|
pairs: Gn,
|
|
2577
|
-
set:
|
|
2579
|
+
set: zn,
|
|
2578
2580
|
timestamp: Pn,
|
|
2579
|
-
bool:
|
|
2580
|
-
int:
|
|
2581
|
+
bool: Nn,
|
|
2582
|
+
int: Kn,
|
|
2581
2583
|
merge: Dn,
|
|
2582
2584
|
omap: Rn,
|
|
2583
2585
|
seq: jn,
|
|
2584
|
-
str:
|
|
2585
|
-
}, ts =
|
|
2586
|
+
str: Tn
|
|
2587
|
+
}, ts = Nt("safeLoad", "load"), ns = Nt("safeLoadAll", "loadAll"), rs = Nt("safeDump", "dump"), as = {
|
|
2586
2588
|
Type: Ri,
|
|
2587
2589
|
Schema: Gi,
|
|
2588
|
-
FAILSAFE_SCHEMA:
|
|
2589
|
-
JSON_SCHEMA:
|
|
2590
|
+
FAILSAFE_SCHEMA: zi,
|
|
2591
|
+
JSON_SCHEMA: Hi,
|
|
2590
2592
|
CORE_SCHEMA: Ji,
|
|
2591
2593
|
DEFAULT_SCHEMA: Wi,
|
|
2592
2594
|
load: Yi,
|
|
@@ -2660,15 +2662,15 @@ const os = {
|
|
|
2660
2662
|
}
|
|
2661
2663
|
}, { immediate: !0 }), (l, u) => {
|
|
2662
2664
|
const p = U("KBadge"), c = U("KCodeBlock");
|
|
2663
|
-
return f(),
|
|
2664
|
-
e.format === "structured" ? (f(),
|
|
2665
|
-
(f(!0),
|
|
2665
|
+
return f(), $(Ce, null, [
|
|
2666
|
+
e.format === "structured" ? (f(), $("div", os, [
|
|
2667
|
+
(f(!0), $(Ce, null, ve(e.propListTypes, (g) => (f(), $("div", {
|
|
2666
2668
|
key: `config-card-details-${g}-props`,
|
|
2667
2669
|
class: Oe(`config-card-details-${g}-props`),
|
|
2668
2670
|
"data-testid": `config-card-details-${g}-props`
|
|
2669
2671
|
}, [
|
|
2670
|
-
g !== "basic" ? (f(),
|
|
2671
|
-
(f(!0),
|
|
2672
|
+
g !== "basic" ? (f(), $("div", ss, B(g === "advanced" ? m(r)("baseConfigCard.sections.advanced") : m(r)("baseConfigCard.sections.plugin")), 1)) : J("", !0),
|
|
2673
|
+
(f(!0), $(Ce, null, ve(e.propertyCollections[g], (d) => (f(), V($t, {
|
|
2672
2674
|
key: d.key,
|
|
2673
2675
|
item: d
|
|
2674
2676
|
}, je({
|
|
@@ -2693,15 +2695,15 @@ const os = {
|
|
|
2693
2695
|
]), 1032, ["item"]))), 128))
|
|
2694
2696
|
], 10, is))), 128))
|
|
2695
2697
|
])) : J("", !0),
|
|
2696
|
-
e.format === "json" ? (f(),
|
|
2697
|
-
n.fetcherUrl ? (f(),
|
|
2698
|
-
|
|
2698
|
+
e.format === "json" ? (f(), $("div", ls, [
|
|
2699
|
+
n.fetcherUrl ? (f(), $("div", us, [
|
|
2700
|
+
K(p, { appearance: "get" }, {
|
|
2699
2701
|
default: h(() => [
|
|
2700
|
-
Q(
|
|
2702
|
+
Q(B(m(r)("baseConfigCard.endpoints.get")), 1)
|
|
2701
2703
|
]),
|
|
2702
2704
|
_: 1
|
|
2703
2705
|
}),
|
|
2704
|
-
|
|
2706
|
+
K(c, {
|
|
2705
2707
|
id: "config-card-endpoint-codeblock",
|
|
2706
2708
|
code: n.fetcherUrl,
|
|
2707
2709
|
"is-single-line": "",
|
|
@@ -2709,7 +2711,7 @@ const os = {
|
|
|
2709
2711
|
theme: "dark"
|
|
2710
2712
|
}, null, 8, ["code"])
|
|
2711
2713
|
])) : J("", !0),
|
|
2712
|
-
|
|
2714
|
+
K(c, {
|
|
2713
2715
|
id: "config-card-codeblock",
|
|
2714
2716
|
class: Oe({ "config-card-display-json-content": n.fetcherUrl }),
|
|
2715
2717
|
code: i.value,
|
|
@@ -2717,8 +2719,8 @@ const os = {
|
|
|
2717
2719
|
theme: "dark"
|
|
2718
2720
|
}, null, 8, ["class", "code"])
|
|
2719
2721
|
])) : J("", !0),
|
|
2720
|
-
e.format === "yaml" ? (f(),
|
|
2721
|
-
|
|
2722
|
+
e.format === "yaml" ? (f(), $("div", cs, [
|
|
2723
|
+
K(c, {
|
|
2722
2724
|
id: "config-card-codeblock",
|
|
2723
2725
|
code: o.value,
|
|
2724
2726
|
language: "yaml",
|
|
@@ -2815,7 +2817,7 @@ const os = {
|
|
|
2815
2817
|
style: gn(r.value)
|
|
2816
2818
|
}, {
|
|
2817
2819
|
default: h(() => [
|
|
2818
|
-
(f(),
|
|
2820
|
+
(f(), $("svg", {
|
|
2819
2821
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2820
2822
|
"data-testid": "kui-icon-svg-book-icon",
|
|
2821
2823
|
fill: "none",
|
|
@@ -2825,7 +2827,7 @@ const os = {
|
|
|
2825
2827
|
width: "100%",
|
|
2826
2828
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2827
2829
|
}, [
|
|
2828
|
-
e.title ? (f(),
|
|
2830
|
+
e.title ? (f(), $("title", ys, B(e.title), 1)) : J("", !0),
|
|
2829
2831
|
hs
|
|
2830
2832
|
], 8, gs))
|
|
2831
2833
|
]),
|
|
@@ -2969,12 +2971,12 @@ const os = {
|
|
|
2969
2971
|
section: ke.Basic
|
|
2970
2972
|
}
|
|
2971
2973
|
}, _ = E(!1), v = E(!1), S = E(""), y = E(), b = A(() => {
|
|
2972
|
-
var k, G,
|
|
2974
|
+
var k, G, F;
|
|
2973
2975
|
if (!y.value)
|
|
2974
2976
|
return [];
|
|
2975
2977
|
const w = [], j = Object.keys(y.value).length;
|
|
2976
2978
|
for (const M in y.value) {
|
|
2977
|
-
const L = (G = (k = a.configSchema) == null ? void 0 : k[M]) == null ? void 0 : G.order, Y = (
|
|
2979
|
+
const L = (G = (k = a.configSchema) == null ? void 0 : k[M]) == null ? void 0 : G.order, Y = (F = d[M]) == null ? void 0 : F.order;
|
|
2978
2980
|
let ee = j;
|
|
2979
2981
|
(Y || Y === 0) && (ee = Y === -1 ? j + 1 : Y), L && (ee = L === -1 ? j + 1 : L), w.push([M, ee]);
|
|
2980
2982
|
}
|
|
@@ -2997,9 +2999,9 @@ const os = {
|
|
|
2997
2999
|
var k, G;
|
|
2998
3000
|
if (!y.value || !a.pluginConfigKey)
|
|
2999
3001
|
return [];
|
|
3000
|
-
const
|
|
3001
|
-
for (const M in
|
|
3002
|
-
const L = (G = (k = a.pluginConfigSchema) == null ? void 0 : k[M]) == null ? void 0 : G.order, Y =
|
|
3002
|
+
const F = y.value[a.pluginConfigKey] || {}, w = Object.keys(F).length, j = [];
|
|
3003
|
+
for (const M in F) {
|
|
3004
|
+
const L = (G = (k = a.pluginConfigSchema) == null ? void 0 : k[M]) == null ? void 0 : G.order, Y = F[M];
|
|
3003
3005
|
let ee = Y != null && Y !== "" ? w - 1 : w;
|
|
3004
3006
|
L && (ee = L === -1 ? w + 1 : L), j.push([M, ee]);
|
|
3005
3007
|
}
|
|
@@ -3007,7 +3009,7 @@ const os = {
|
|
|
3007
3009
|
return M[1] - L[1];
|
|
3008
3010
|
}), j.map((M) => {
|
|
3009
3011
|
var L;
|
|
3010
|
-
const Y = M[0], ee =
|
|
3012
|
+
const Y = M[0], ee = F[Y], te = ((L = a.pluginConfigSchema) == null ? void 0 : L[Y]) || {};
|
|
3011
3013
|
return {
|
|
3012
3014
|
key: Y,
|
|
3013
3015
|
value: ee,
|
|
@@ -3019,19 +3021,19 @@ const os = {
|
|
|
3019
3021
|
};
|
|
3020
3022
|
}).filter((M) => !M.hidden);
|
|
3021
3023
|
}), I = A(() => {
|
|
3022
|
-
var k, G,
|
|
3024
|
+
var k, G, F, w;
|
|
3023
3025
|
return {
|
|
3024
3026
|
basic: (k = b.value) == null ? void 0 : k.filter((j) => j.section === ke.Basic),
|
|
3025
3027
|
advanced: (G = b.value) == null ? void 0 : G.filter((j) => j.section === ke.Advanced),
|
|
3026
|
-
plugin: (w = O.value) == null ? void 0 : w.concat((
|
|
3028
|
+
plugin: (w = O.value) == null ? void 0 : w.concat((F = b.value) == null ? void 0 : F.filter((j) => j.section === ke.Plugin))
|
|
3027
3029
|
};
|
|
3028
|
-
}),
|
|
3030
|
+
}), N = A(() => {
|
|
3029
3031
|
const k = [];
|
|
3030
3032
|
return I.value.basic.length && k.push("basic"), I.value.advanced.length && k.push("advanced"), I.value.plugin.length && k.push("plugin"), k;
|
|
3031
|
-
}),
|
|
3033
|
+
}), z = (k) => !!(k.tooltip || i[`${k.key}-label-tooltip`]), ie = A(() => {
|
|
3032
3034
|
var k, G;
|
|
3033
|
-
let
|
|
3034
|
-
return a.config.app === "konnect" ?
|
|
3035
|
+
let F = `${a.config.apiBaseUrl}${a.fetchUrl}`;
|
|
3036
|
+
return a.config.app === "konnect" ? F = F.replace(/{controlPlaneId}/gi, ((k = a.config) == null ? void 0 : k.controlPlaneId) || "") : a.config.app === "kongManager" && (F = F.replace(/\/{workspace}/gi, (G = a.config) != null && G.workspace ? `/${a.config.workspace}` : "")), F = F.replace(/{id}/gi, a.config.entityId), F;
|
|
3035
3037
|
}), R = (k) => {
|
|
3036
3038
|
y.value && k(JSON.stringify(y.value)) ? r("copy:success", y.value) : r("copy:error");
|
|
3037
3039
|
};
|
|
@@ -3058,18 +3060,18 @@ const os = {
|
|
|
3058
3060
|
_.value = !1;
|
|
3059
3061
|
}
|
|
3060
3062
|
}), (k, G) => {
|
|
3061
|
-
const
|
|
3063
|
+
const F = U("KLabel"), w = U("KSelect"), j = U("KButton"), M = U("KClipboardProvider"), L = U("KSkeleton"), Y = U("KEmptyState"), ee = U("KCard");
|
|
3062
3064
|
return f(), V(ee, { class: "kong-ui-entity-base-config-card" }, je({
|
|
3063
3065
|
actions: h(() => [
|
|
3064
3066
|
D("div", ks, [
|
|
3065
3067
|
X(k.$slots, "actions", {}, void 0, !0),
|
|
3066
|
-
e.config.jsonYamlEnabled ? (f(), V(
|
|
3068
|
+
e.config.jsonYamlEnabled ? (f(), V(F, {
|
|
3067
3069
|
key: 0,
|
|
3068
3070
|
class: "config-format-select-label",
|
|
3069
3071
|
"data-testid": "config-format-select-label"
|
|
3070
3072
|
}, {
|
|
3071
3073
|
default: h(() => [
|
|
3072
|
-
Q(
|
|
3074
|
+
Q(B(e.label), 1)
|
|
3073
3075
|
]),
|
|
3074
3076
|
_: 1
|
|
3075
3077
|
})) : J("", !0),
|
|
@@ -3092,7 +3094,7 @@ const os = {
|
|
|
3092
3094
|
rel: "noopener",
|
|
3093
3095
|
target: "_blank"
|
|
3094
3096
|
}, [
|
|
3095
|
-
|
|
3097
|
+
K(m(bs), { size: m(Sa) }, null, 8, ["size"])
|
|
3096
3098
|
], 8, ws)
|
|
3097
3099
|
]),
|
|
3098
3100
|
_: 1
|
|
@@ -3106,7 +3108,7 @@ const os = {
|
|
|
3106
3108
|
onClick: (ne) => R(te)
|
|
3107
3109
|
}, {
|
|
3108
3110
|
default: h(() => [
|
|
3109
|
-
Q(
|
|
3111
|
+
Q(B(m(o)("baseConfigCard.actions.copy")), 1)
|
|
3110
3112
|
]),
|
|
3111
3113
|
_: 2
|
|
3112
3114
|
}, 1032, ["onClick"])) : J("", !0)
|
|
@@ -3127,15 +3129,15 @@ const os = {
|
|
|
3127
3129
|
"is-error": ""
|
|
3128
3130
|
}, {
|
|
3129
3131
|
message: h(() => [
|
|
3130
|
-
D("h3", null,
|
|
3132
|
+
D("h3", null, B(S.value), 1)
|
|
3131
3133
|
]),
|
|
3132
3134
|
_: 1
|
|
3133
3135
|
})) : J("", !0),
|
|
3134
|
-
e.config.jsonYamlEnabled ? (f(),
|
|
3135
|
-
|
|
3136
|
+
e.config.jsonYamlEnabled ? (f(), $("div", _s, [
|
|
3137
|
+
K(ps, {
|
|
3136
3138
|
"fetcher-url": ie.value,
|
|
3137
3139
|
format: c.value,
|
|
3138
|
-
"prop-list-types":
|
|
3140
|
+
"prop-list-types": N.value,
|
|
3139
3141
|
"property-collections": I.value,
|
|
3140
3142
|
record: y.value
|
|
3141
3143
|
}, je({ _: 2 }, [
|
|
@@ -3149,14 +3151,14 @@ const os = {
|
|
|
3149
3151
|
])
|
|
3150
3152
|
}))
|
|
3151
3153
|
]), 1032, ["fetcher-url", "format", "prop-list-types", "property-collections", "record"])
|
|
3152
|
-
])) : (f(),
|
|
3153
|
-
(f(!0),
|
|
3154
|
+
])) : (f(), $("div", Is, [
|
|
3155
|
+
(f(!0), $(Ce, null, ve(N.value, (te) => (f(), $("div", {
|
|
3154
3156
|
key: `config-card-details-${te}-props`,
|
|
3155
3157
|
class: Oe(`config-card-details-${te}-props`),
|
|
3156
3158
|
"data-testid": `config-card-details-${te}-props`
|
|
3157
3159
|
}, [
|
|
3158
|
-
te !== "basic" ? (f(),
|
|
3159
|
-
(f(!0),
|
|
3160
|
+
te !== "basic" ? (f(), $("div", As, B(te === "advanced" ? m(o)("baseConfigCard.sections.advanced") : m(o)("baseConfigCard.sections.plugin")), 1)) : J("", !0),
|
|
3161
|
+
(f(!0), $(Ce, null, ve(I.value[te], (ne) => (f(), V($t, {
|
|
3160
3162
|
key: ne.key,
|
|
3161
3163
|
item: ne
|
|
3162
3164
|
}, je({
|
|
@@ -3171,7 +3173,7 @@ const os = {
|
|
|
3171
3173
|
]),
|
|
3172
3174
|
_: 2
|
|
3173
3175
|
}, [
|
|
3174
|
-
|
|
3176
|
+
z(ne) ? {
|
|
3175
3177
|
name: "label-tooltip",
|
|
3176
3178
|
fn: h(() => [
|
|
3177
3179
|
X(k.$slots, `${ne.key}-label-tooltip`, { row: ne }, void 0, !0)
|
|
@@ -3189,7 +3191,7 @@ const os = {
|
|
|
3189
3191
|
fn: h(() => [
|
|
3190
3192
|
D("div", Cs, [
|
|
3191
3193
|
X(k.$slots, "title", {}, () => [
|
|
3192
|
-
Q(
|
|
3194
|
+
Q(B(m(o)("baseConfigCard.title")), 1)
|
|
3193
3195
|
], !0)
|
|
3194
3196
|
])
|
|
3195
3197
|
]),
|
|
@@ -3198,7 +3200,7 @@ const os = {
|
|
|
3198
3200
|
]), 1024);
|
|
3199
3201
|
};
|
|
3200
3202
|
}
|
|
3201
|
-
}),
|
|
3203
|
+
}), $s = /* @__PURE__ */ we(xs, [["__scopeId", "data-v-4f47d6ad"]]), Ts = {
|
|
3202
3204
|
class: "form-actions",
|
|
3203
3205
|
"data-testid": "form-actions"
|
|
3204
3206
|
}, js = /* @__PURE__ */ oe({
|
|
@@ -3281,7 +3283,7 @@ const os = {
|
|
|
3281
3283
|
u.value = !1;
|
|
3282
3284
|
}
|
|
3283
3285
|
}), (y, b) => {
|
|
3284
|
-
const O = U("KSkeleton"), I = U("KEmptyState"),
|
|
3286
|
+
const O = U("KSkeleton"), I = U("KEmptyState"), N = U("KAlert"), z = U("KButton"), ie = U("KCard");
|
|
3285
3287
|
return f(), V(ie, { class: "kong-ui-entity-base-form" }, {
|
|
3286
3288
|
default: h(() => [
|
|
3287
3289
|
u.value ? (f(), V(O, {
|
|
@@ -3295,43 +3297,43 @@ const os = {
|
|
|
3295
3297
|
"is-error": !0
|
|
3296
3298
|
}, {
|
|
3297
3299
|
message: h(() => [
|
|
3298
|
-
D("h3", null,
|
|
3300
|
+
D("h3", null, B(c.value), 1)
|
|
3299
3301
|
]),
|
|
3300
3302
|
_: 1
|
|
3301
|
-
}, 8, ["cta-text"])) : (f(),
|
|
3303
|
+
}, 8, ["cta-text"])) : (f(), $("form", {
|
|
3302
3304
|
key: 2,
|
|
3303
3305
|
"data-testid": "form-content",
|
|
3304
3306
|
onReset: rt(v, ["prevent"]),
|
|
3305
3307
|
onSubmit: rt(S, ["prevent"])
|
|
3306
3308
|
}, [
|
|
3307
3309
|
X(y.$slots, "default", {}, void 0, !0),
|
|
3308
|
-
e.errorMessage ? (f(), V(
|
|
3310
|
+
e.errorMessage ? (f(), V(N, {
|
|
3309
3311
|
key: 0,
|
|
3310
3312
|
"alert-message": e.errorMessage,
|
|
3311
3313
|
appearance: "danger",
|
|
3312
3314
|
"data-testid": "form-error"
|
|
3313
3315
|
}, null, 8, ["alert-message"])) : J("", !0),
|
|
3314
|
-
D("div",
|
|
3316
|
+
D("div", Ts, [
|
|
3315
3317
|
X(y.$slots, "form-actions", {}, () => [
|
|
3316
|
-
|
|
3318
|
+
K(z, {
|
|
3317
3319
|
appearance: "secondary",
|
|
3318
3320
|
"data-testid": "form-cancel",
|
|
3319
3321
|
disabled: e.isReadonly,
|
|
3320
3322
|
type: "reset"
|
|
3321
3323
|
}, {
|
|
3322
3324
|
default: h(() => [
|
|
3323
|
-
Q(
|
|
3325
|
+
Q(B(m(o)("baseForm.actions.cancel")), 1)
|
|
3324
3326
|
]),
|
|
3325
3327
|
_: 1
|
|
3326
3328
|
}, 8, ["disabled"]),
|
|
3327
|
-
|
|
3329
|
+
K(z, {
|
|
3328
3330
|
appearance: "primary",
|
|
3329
3331
|
"data-testid": "form-submit",
|
|
3330
3332
|
disabled: g.value,
|
|
3331
3333
|
type: "submit"
|
|
3332
3334
|
}, {
|
|
3333
3335
|
default: h(() => [
|
|
3334
|
-
Q(
|
|
3336
|
+
Q(B(m(o)("baseForm.actions.save")), 1)
|
|
3335
3337
|
]),
|
|
3336
3338
|
_: 1
|
|
3337
3339
|
}, 8, ["disabled"])
|
|
@@ -3397,13 +3399,13 @@ const os = {
|
|
|
3397
3399
|
d();
|
|
3398
3400
|
}), (v, S) => {
|
|
3399
3401
|
const y = U("KTooltip");
|
|
3400
|
-
return f(),
|
|
3402
|
+
return f(), $("span", {
|
|
3401
3403
|
ref_key: "contentRef",
|
|
3402
3404
|
ref: l,
|
|
3403
3405
|
class: "content-wrapper"
|
|
3404
3406
|
}, [
|
|
3405
|
-
a.value ? (f(),
|
|
3406
|
-
|
|
3407
|
+
a.value ? (f(), $("span", Es, [
|
|
3408
|
+
K(y, {
|
|
3407
3409
|
label: _.value ? c.value : "",
|
|
3408
3410
|
"max-width": "300",
|
|
3409
3411
|
placement: "bottomStart"
|
|
@@ -3417,10 +3419,10 @@ const os = {
|
|
|
3417
3419
|
], 512);
|
|
3418
3420
|
};
|
|
3419
3421
|
}
|
|
3420
|
-
}),
|
|
3422
|
+
}), Ns = /* @__PURE__ */ we(Os, [["__scopeId", "data-v-e42a20c9"]]), Ks = { class: "toolbar-container" }, Bs = {
|
|
3421
3423
|
key: 0,
|
|
3422
3424
|
class: "toolbar-button-container"
|
|
3423
|
-
},
|
|
3425
|
+
}, Fs = ["data-testid"], qs = /* @__PURE__ */ oe({
|
|
3424
3426
|
__name: "EntityBaseTable",
|
|
3425
3427
|
props: {
|
|
3426
3428
|
// table header configuration
|
|
@@ -3531,71 +3533,71 @@ const os = {
|
|
|
3531
3533
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked"],
|
|
3532
3534
|
setup(e, { emit: n }) {
|
|
3533
3535
|
const t = e, r = n, { i18n: { t: a } } = de.useI18n(), i = A(() => {
|
|
3534
|
-
var
|
|
3536
|
+
var N, z;
|
|
3535
3537
|
return typeof t.errorMessage == "string" ? {
|
|
3536
3538
|
hasError: !!t.errorMessage,
|
|
3537
3539
|
title: t.errorMessage,
|
|
3538
3540
|
message: void 0
|
|
3539
3541
|
} : {
|
|
3540
3542
|
hasError: !!t.errorMessage,
|
|
3541
|
-
title: (
|
|
3542
|
-
message: (
|
|
3543
|
+
title: (N = t.errorMessage) == null ? void 0 : N.title,
|
|
3544
|
+
message: (z = t.errorMessage) == null ? void 0 : z.message
|
|
3543
3545
|
};
|
|
3544
|
-
}), o = A(() => t.cacheIdentifier || t.preferencesStorageKey), s = (
|
|
3545
|
-
const
|
|
3546
|
-
return Object.keys(t.tableHeaders).forEach((
|
|
3547
|
-
const ie = t.tableHeaders[
|
|
3548
|
-
|
|
3549
|
-
label: ie.label ??
|
|
3550
|
-
key:
|
|
3546
|
+
}), o = A(() => t.cacheIdentifier || t.preferencesStorageKey), s = (N) => N.hasData || !!t.query, l = A(() => {
|
|
3547
|
+
const N = [];
|
|
3548
|
+
return Object.keys(t.tableHeaders).forEach((z) => {
|
|
3549
|
+
const ie = t.tableHeaders[z];
|
|
3550
|
+
N.push({
|
|
3551
|
+
label: ie.label ?? z,
|
|
3552
|
+
key: z,
|
|
3551
3553
|
sortable: ie.sortable ?? !1
|
|
3552
3554
|
});
|
|
3553
|
-
}), t.enableEntityActions &&
|
|
3555
|
+
}), t.enableEntityActions && N.push({
|
|
3554
3556
|
key: "actions",
|
|
3555
3557
|
hideLabel: !0
|
|
3556
|
-
}),
|
|
3557
|
-
}), u = (
|
|
3558
|
-
"data-rowid":
|
|
3559
|
-
"data-testid":
|
|
3560
|
-
...t.rowAttributes(
|
|
3561
|
-
}), p = E({}), c = (
|
|
3562
|
-
var
|
|
3563
|
-
return (
|
|
3564
|
-
}, g = (
|
|
3565
|
-
const
|
|
3566
|
-
"data-testid":
|
|
3567
|
-
...t.cellAttributes(
|
|
3558
|
+
}), N;
|
|
3559
|
+
}), u = (N) => ({
|
|
3560
|
+
"data-rowid": N.id,
|
|
3561
|
+
"data-testid": N.name,
|
|
3562
|
+
...t.rowAttributes(N)
|
|
3563
|
+
}), p = E({}), c = (N) => {
|
|
3564
|
+
var z;
|
|
3565
|
+
return (z = p.value) == null ? void 0 : z.$el.querySelector(`[data-rowid="${N.id}"]`);
|
|
3566
|
+
}, g = (N) => {
|
|
3567
|
+
const z = {
|
|
3568
|
+
"data-testid": N.headerKey,
|
|
3569
|
+
...t.cellAttributes(N)
|
|
3568
3570
|
};
|
|
3569
|
-
return
|
|
3571
|
+
return N.colIndex === 0 && (z.style = {
|
|
3570
3572
|
maxWidth: "250px",
|
|
3571
3573
|
overflowX: "hidden",
|
|
3572
3574
|
textOverflow: "ellipsis"
|
|
3573
|
-
}),
|
|
3575
|
+
}), z;
|
|
3574
3576
|
}, d = () => {
|
|
3575
3577
|
r("empty-state-cta-clicked"), _();
|
|
3576
3578
|
}, _ = () => {
|
|
3577
3579
|
r("clear-search-input");
|
|
3578
|
-
}, v = A(() => t.disableRowClick ? void 0 : (
|
|
3579
|
-
r("click:row",
|
|
3580
|
-
}), S = (
|
|
3581
|
-
r("sort",
|
|
3580
|
+
}, v = A(() => t.disableRowClick ? void 0 : (N, z) => {
|
|
3581
|
+
r("click:row", z);
|
|
3582
|
+
}), S = (N) => {
|
|
3583
|
+
r("sort", N);
|
|
3582
3584
|
}, { setTablePreferences: y, getTablePreferences: b } = jr(), O = A(() => {
|
|
3583
|
-
const
|
|
3585
|
+
const N = b(t.preferencesStorageKey);
|
|
3584
3586
|
return {
|
|
3585
3587
|
...t.initialFetcherParams,
|
|
3586
|
-
...
|
|
3588
|
+
...N
|
|
3587
3589
|
};
|
|
3588
|
-
}), I = (
|
|
3589
|
-
t.preferencesStorageKey && y(t.preferencesStorageKey,
|
|
3590
|
+
}), I = (N) => {
|
|
3591
|
+
t.preferencesStorageKey && y(t.preferencesStorageKey, N);
|
|
3590
3592
|
};
|
|
3591
|
-
return (
|
|
3592
|
-
const ie = U("KIcon"), R = U("KButton"), k = U("KDropdown"), G = U("KTable"),
|
|
3593
|
-
return f(), V(
|
|
3593
|
+
return (N, z) => {
|
|
3594
|
+
const ie = U("KIcon"), R = U("KButton"), k = U("KDropdown"), G = U("KTable"), F = U("KCard");
|
|
3595
|
+
return f(), V(F, {
|
|
3594
3596
|
class: "kong-ui-entity-base-table",
|
|
3595
3597
|
title: e.title
|
|
3596
3598
|
}, {
|
|
3597
3599
|
default: h(() => [
|
|
3598
|
-
|
|
3600
|
+
K(G, {
|
|
3599
3601
|
ref_key: "tableRefs",
|
|
3600
3602
|
ref: p,
|
|
3601
3603
|
"cache-identifier": o.value,
|
|
@@ -3624,14 +3626,14 @@ const os = {
|
|
|
3624
3626
|
"search-input": e.query,
|
|
3625
3627
|
onKtableEmptyStateCtaClicked: d,
|
|
3626
3628
|
"onRow:click": v.value,
|
|
3627
|
-
onSort:
|
|
3629
|
+
onSort: z[0] || (z[0] = (w) => S(w)),
|
|
3628
3630
|
"onUpdate:tablePreferences": I
|
|
3629
3631
|
}, je({
|
|
3630
3632
|
toolbar: h(({ state: w }) => [
|
|
3631
|
-
We(D("div",
|
|
3632
|
-
X(
|
|
3633
|
-
|
|
3634
|
-
X(
|
|
3633
|
+
We(D("div", Ks, [
|
|
3634
|
+
X(N.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3635
|
+
N.$slots["toolbar-button"] ? (f(), $("div", Bs, [
|
|
3636
|
+
X(N.$slots, "toolbar-button", {}, void 0, !0)
|
|
3635
3637
|
])) : J("", !0)
|
|
3636
3638
|
], 512), [
|
|
3637
3639
|
[Ye, s(w)]
|
|
@@ -3642,25 +3644,25 @@ const os = {
|
|
|
3642
3644
|
class: "actions-container",
|
|
3643
3645
|
"data-testid": w.name
|
|
3644
3646
|
}, [
|
|
3645
|
-
|
|
3647
|
+
K(k, {
|
|
3646
3648
|
"kpop-attributes": { placement: "bottomEnd" },
|
|
3647
3649
|
width: e.dropdownMenuWidth
|
|
3648
3650
|
}, {
|
|
3649
3651
|
items: h(() => [
|
|
3650
|
-
X(
|
|
3652
|
+
X(N.$slots, "actions", {
|
|
3651
3653
|
row: w,
|
|
3652
3654
|
rowKey: j,
|
|
3653
3655
|
rowValue: M
|
|
3654
3656
|
}, void 0, !0)
|
|
3655
3657
|
]),
|
|
3656
3658
|
default: h(() => [
|
|
3657
|
-
|
|
3659
|
+
K(R, {
|
|
3658
3660
|
class: "actions-trigger",
|
|
3659
3661
|
"data-testid": "overflow-actions-button",
|
|
3660
3662
|
size: "small"
|
|
3661
3663
|
}, {
|
|
3662
3664
|
icon: h(() => [
|
|
3663
|
-
|
|
3665
|
+
K(ie, {
|
|
3664
3666
|
color: m(_a),
|
|
3665
3667
|
icon: "more",
|
|
3666
3668
|
size: "16"
|
|
@@ -3671,24 +3673,24 @@ const os = {
|
|
|
3671
3673
|
]),
|
|
3672
3674
|
_: 2
|
|
3673
3675
|
}, 1032, ["width"])
|
|
3674
|
-
], 8,
|
|
3676
|
+
], 8, Fs)
|
|
3675
3677
|
]),
|
|
3676
3678
|
_: 2
|
|
3677
3679
|
}, [
|
|
3678
3680
|
ve(e.tableHeaders, (w, j) => ({
|
|
3679
3681
|
name: j,
|
|
3680
3682
|
fn: h(({ row: M, rowKey: L, rowValue: Y }) => [
|
|
3681
|
-
|
|
3683
|
+
K(Ns, {
|
|
3682
3684
|
"key-name": String(j),
|
|
3683
3685
|
"row-el": c(M)
|
|
3684
3686
|
}, {
|
|
3685
3687
|
default: h(() => [
|
|
3686
|
-
X(
|
|
3688
|
+
X(N.$slots, j, {
|
|
3687
3689
|
row: M,
|
|
3688
3690
|
rowKey: L,
|
|
3689
3691
|
rowValue: Y
|
|
3690
3692
|
}, () => [
|
|
3691
|
-
Q(
|
|
3693
|
+
Q(B(Y), 1)
|
|
3692
3694
|
], !0)
|
|
3693
3695
|
]),
|
|
3694
3696
|
_: 2
|
|
@@ -3765,35 +3767,35 @@ const os = {
|
|
|
3765
3767
|
onProceed: s
|
|
3766
3768
|
}, {
|
|
3767
3769
|
"body-content": h(() => [
|
|
3768
|
-
e.error ? (f(),
|
|
3769
|
-
|
|
3770
|
+
e.error ? (f(), $("div", Us, [
|
|
3771
|
+
K(p, { appearance: "danger" }, {
|
|
3770
3772
|
alertMessage: h(() => [
|
|
3771
|
-
Q(
|
|
3773
|
+
Q(B(e.error), 1)
|
|
3772
3774
|
]),
|
|
3773
3775
|
_: 1
|
|
3774
3776
|
})
|
|
3775
3777
|
])) : J("", !0),
|
|
3776
|
-
|
|
3778
|
+
K(m(t), {
|
|
3777
3779
|
class: "message",
|
|
3778
3780
|
keypath: r.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
3779
3781
|
tag: "p"
|
|
3780
3782
|
}, je({
|
|
3781
3783
|
entityType: h(() => [
|
|
3782
|
-
Q(
|
|
3784
|
+
Q(B(r.entityType), 1)
|
|
3783
3785
|
]),
|
|
3784
3786
|
_: 2
|
|
3785
3787
|
}, [
|
|
3786
3788
|
r.entityName ? {
|
|
3787
3789
|
name: "entityName",
|
|
3788
3790
|
fn: h(() => [
|
|
3789
|
-
D("strong", null,
|
|
3791
|
+
D("strong", null, B(r.entityName), 1)
|
|
3790
3792
|
]),
|
|
3791
3793
|
key: "0"
|
|
3792
3794
|
} : void 0
|
|
3793
3795
|
]), 1032, ["keypath"]),
|
|
3794
|
-
r.description || l.$slots.description ? (f(),
|
|
3796
|
+
r.description || l.$slots.description ? (f(), $("div", Ps, [
|
|
3795
3797
|
X(l.$slots, "description", {}, () => [
|
|
3796
|
-
D("p", null,
|
|
3798
|
+
D("p", null, B(r.description), 1)
|
|
3797
3799
|
], !0)
|
|
3798
3800
|
])) : J("", !0)
|
|
3799
3801
|
]),
|
|
@@ -3815,7 +3817,7 @@ const os = {
|
|
|
3815
3817
|
width: "20",
|
|
3816
3818
|
x: "0",
|
|
3817
3819
|
y: "0"
|
|
3818
|
-
},
|
|
3820
|
+
}, zs = ["fill"], Hs = { mask: "url(#mask0_180_20349)" }, Js = ["fill"], pn = /* @__PURE__ */ oe({
|
|
3819
3821
|
__name: "IconFilter",
|
|
3820
3822
|
props: {
|
|
3821
3823
|
color: {
|
|
@@ -3824,15 +3826,15 @@ const os = {
|
|
|
3824
3826
|
}
|
|
3825
3827
|
},
|
|
3826
3828
|
setup(e) {
|
|
3827
|
-
return (n, t) => (f(),
|
|
3829
|
+
return (n, t) => (f(), $("svg", Rs, [
|
|
3828
3830
|
D("mask", Gs, [
|
|
3829
3831
|
D("rect", {
|
|
3830
3832
|
fill: e.color,
|
|
3831
3833
|
height: "20",
|
|
3832
3834
|
width: "20"
|
|
3833
|
-
}, null, 8,
|
|
3835
|
+
}, null, 8, zs)
|
|
3834
3836
|
]),
|
|
3835
|
-
D("g",
|
|
3837
|
+
D("g", Hs, [
|
|
3836
3838
|
D("path", {
|
|
3837
3839
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3838
3840
|
fill: e.color
|
|
@@ -3905,7 +3907,7 @@ const os = {
|
|
|
3905
3907
|
y && (i.value = !1), a("update:modelValue", new URLSearchParams(b).toString());
|
|
3906
3908
|
};
|
|
3907
3909
|
return (y, b) => {
|
|
3908
|
-
const O = U("KInput"), I = U("KButton"),
|
|
3910
|
+
const O = U("KInput"), I = U("KButton"), N = U("KSelect"), z = U("KMenuItem"), ie = U("KMenu");
|
|
3909
3911
|
return e.config.isExactMatch ? (f(), V(O, {
|
|
3910
3912
|
key: 0,
|
|
3911
3913
|
autocomplete: "off",
|
|
@@ -3916,18 +3918,18 @@ const os = {
|
|
|
3916
3918
|
"onUpdate:modelValue": p
|
|
3917
3919
|
}, {
|
|
3918
3920
|
before: h(() => [
|
|
3919
|
-
|
|
3921
|
+
K(pn)
|
|
3920
3922
|
]),
|
|
3921
3923
|
_: 1
|
|
3922
|
-
}, 8, ["model-value", "placeholder"])) : (f(),
|
|
3923
|
-
|
|
3924
|
+
}, 8, ["model-value", "placeholder"])) : (f(), $("div", Ws, [
|
|
3925
|
+
K(I, {
|
|
3924
3926
|
appearance: "tertiary",
|
|
3925
3927
|
"data-testid": "filter-button",
|
|
3926
3928
|
onClick: u
|
|
3927
3929
|
}, {
|
|
3928
3930
|
default: h(() => [
|
|
3929
|
-
|
|
3930
|
-
Q(" " +
|
|
3931
|
+
K(pn),
|
|
3932
|
+
Q(" " + B(m(t)("filter.filterButtonText")) + " " + B(s.value.length > 0 ? `(${s.value.length})` : ""), 1)
|
|
3931
3933
|
]),
|
|
3932
3934
|
_: 1
|
|
3933
3935
|
}),
|
|
@@ -3937,9 +3939,9 @@ const os = {
|
|
|
3937
3939
|
}, null, 512), [
|
|
3938
3940
|
[Ye, i.value]
|
|
3939
3941
|
]),
|
|
3940
|
-
We(
|
|
3942
|
+
We(K(ie, { class: "kong-ui-entity-filter-menu" }, {
|
|
3941
3943
|
body: h(() => [
|
|
3942
|
-
(f(!0),
|
|
3944
|
+
(f(!0), $(Ce, null, ve(l.value, (R, k) => (f(), V(z, {
|
|
3943
3945
|
key: R.value,
|
|
3944
3946
|
"data-testid": R.value,
|
|
3945
3947
|
expandable: "",
|
|
@@ -3947,21 +3949,21 @@ const os = {
|
|
|
3947
3949
|
}, {
|
|
3948
3950
|
itemTitle: h(() => [
|
|
3949
3951
|
D("span", Ys, [
|
|
3950
|
-
Q(
|
|
3952
|
+
Q(B(R.label) + " ", 1),
|
|
3951
3953
|
We(D("span", Zs, null, 512), [
|
|
3952
3954
|
[Ye, s.value.includes(R.value)]
|
|
3953
3955
|
])
|
|
3954
3956
|
])
|
|
3955
3957
|
]),
|
|
3956
3958
|
itemBody: h(() => {
|
|
3957
|
-
var G,
|
|
3959
|
+
var G, F;
|
|
3958
3960
|
return [
|
|
3959
3961
|
D("div", Qs, [
|
|
3960
3962
|
D("label", {
|
|
3961
3963
|
class: "menu-item-label",
|
|
3962
3964
|
for: c(R.value)
|
|
3963
|
-
},
|
|
3964
|
-
((
|
|
3965
|
+
}, B(m(t)("filter.fieldLabel")), 9, Xs),
|
|
3966
|
+
((F = (G = e.config.schema) == null ? void 0 : G[R.value]) == null ? void 0 : F.type) === "select" ? (f(), V(N, {
|
|
3965
3967
|
key: 0,
|
|
3966
3968
|
id: c(R.value),
|
|
3967
3969
|
modelValue: o.value[R.value],
|
|
@@ -3980,25 +3982,25 @@ const os = {
|
|
|
3980
3982
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3981
3983
|
]),
|
|
3982
3984
|
D("div", el, [
|
|
3983
|
-
|
|
3985
|
+
K(I, {
|
|
3984
3986
|
appearance: "tertiary",
|
|
3985
3987
|
"data-testid": "apply-filter",
|
|
3986
3988
|
size: "small",
|
|
3987
3989
|
onClick: b[0] || (b[0] = (w) => S(!0))
|
|
3988
3990
|
}, {
|
|
3989
3991
|
default: h(() => [
|
|
3990
|
-
Q(
|
|
3992
|
+
Q(B(m(t)("filter.applyButtonText")), 1)
|
|
3991
3993
|
]),
|
|
3992
3994
|
_: 1
|
|
3993
3995
|
}),
|
|
3994
|
-
|
|
3996
|
+
K(I, {
|
|
3995
3997
|
appearance: "tertiary",
|
|
3996
3998
|
"data-testid": "clear-filter",
|
|
3997
3999
|
size: "small",
|
|
3998
4000
|
onClick: (w) => _(R.value)
|
|
3999
4001
|
}, {
|
|
4000
4002
|
default: h(() => [
|
|
4001
|
-
Q(
|
|
4003
|
+
Q(B(m(t)("filter.clearButtonText")), 1)
|
|
4002
4004
|
]),
|
|
4003
4005
|
_: 2
|
|
4004
4006
|
}, 1032, ["onClick"])
|
|
@@ -4010,13 +4012,13 @@ const os = {
|
|
|
4010
4012
|
]),
|
|
4011
4013
|
actionButton: h(() => [
|
|
4012
4014
|
D("div", tl, [
|
|
4013
|
-
|
|
4015
|
+
K(I, {
|
|
4014
4016
|
appearance: "tertiary",
|
|
4015
4017
|
size: "small",
|
|
4016
4018
|
onClick: v
|
|
4017
4019
|
}, {
|
|
4018
4020
|
default: h(() => [
|
|
4019
|
-
Q(
|
|
4021
|
+
Q(B(m(t)("filter.clearAllButtonText")), 1)
|
|
4020
4022
|
]),
|
|
4021
4023
|
_: 1
|
|
4022
4024
|
})
|
|
@@ -4094,21 +4096,21 @@ const os = {
|
|
|
4094
4096
|
},
|
|
4095
4097
|
setup(e) {
|
|
4096
4098
|
const n = ut();
|
|
4097
|
-
return (t, r) => (f(),
|
|
4099
|
+
return (t, r) => (f(), $("fieldset", {
|
|
4098
4100
|
class: Oe(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }])
|
|
4099
4101
|
}, [
|
|
4100
4102
|
D("div", al, [
|
|
4101
|
-
e.hideInfoHeader ? J("", !0) : (f(),
|
|
4103
|
+
e.hideInfoHeader ? J("", !0) : (f(), $("div", {
|
|
4102
4104
|
key: 0,
|
|
4103
4105
|
class: Oe(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
4104
4106
|
}, [
|
|
4105
|
-
e.title ? (f(),
|
|
4106
|
-
e.description || m(n).description ? (f(),
|
|
4107
|
+
e.title ? (f(), $("h4", ol, B(e.title), 1)) : J("", !0),
|
|
4108
|
+
e.description || m(n).description ? (f(), $("div", il, [
|
|
4107
4109
|
X(t.$slots, "description", {}, () => [
|
|
4108
|
-
D("p", null,
|
|
4110
|
+
D("p", null, B(e.description), 1)
|
|
4109
4111
|
], !0)
|
|
4110
4112
|
])) : J("", !0),
|
|
4111
|
-
m(n).footer ? (f(),
|
|
4113
|
+
m(n).footer ? (f(), $("div", sl, [
|
|
4112
4114
|
X(t.$slots, "footer", {}, void 0, !0)
|
|
4113
4115
|
])) : J("", !0)
|
|
4114
4116
|
], 2)),
|
|
@@ -4118,7 +4120,7 @@ const os = {
|
|
|
4118
4120
|
])
|
|
4119
4121
|
], 2));
|
|
4120
4122
|
}
|
|
4121
|
-
}), fn = /* @__PURE__ */ we(ul, [["__scopeId", "data-v-3565daa7"]]), { useAxios:
|
|
4123
|
+
}), fn = /* @__PURE__ */ we(ul, [["__scopeId", "data-v-3565daa7"]]), { useAxios: Kt, useDeleteUrlBuilder: cl, useErrors: dl, useExternalLinkCreator: El, useFetchUrlBuilder: Ol, useFetcher: pl, useDebouncedFilter: fr, useStringHelpers: Nl, useHelpers: Kl, useGatewayFeatureSupported: Bl, useTruncationDetector: Fl } = de, fl = { class: "add-to-group-form-container" }, ml = { class: "add-to-group-cta-text" }, gl = {
|
|
4122
4124
|
key: 0,
|
|
4123
4125
|
class: "kong-ui-entity-add-to-groups-error"
|
|
4124
4126
|
}, yl = { key: 0 }, hl = /* @__PURE__ */ oe({
|
|
@@ -4138,9 +4140,9 @@ const os = {
|
|
|
4138
4140
|
},
|
|
4139
4141
|
emits: ["cancel", "add:success", "add:partial-success", "error"],
|
|
4140
4142
|
setup(e, { emit: n }) {
|
|
4141
|
-
var
|
|
4142
|
-
const { i18n: { t } } = dt.useI18n(), r = e, a = n, { axiosInstance: i } =
|
|
4143
|
-
headers: (
|
|
4143
|
+
var F;
|
|
4144
|
+
const { i18n: { t } } = dt.useI18n(), r = e, a = n, { axiosInstance: i } = Kt({
|
|
4145
|
+
headers: (F = r.config) == null ? void 0 : F.requestHeaders
|
|
4144
4146
|
}), o = E([]), {
|
|
4145
4147
|
debouncedQueryChange: s,
|
|
4146
4148
|
loading: l,
|
|
@@ -4167,13 +4169,13 @@ const os = {
|
|
|
4167
4169
|
const j = v.value ? g.value.find((L) => L.id === w) : (M = u.value) == null ? void 0 : M.find((L) => L.id === w);
|
|
4168
4170
|
return j ? j.name : w;
|
|
4169
4171
|
}, b = () => {
|
|
4170
|
-
|
|
4171
|
-
}, O = E([]), I = E(!1),
|
|
4172
|
+
N.value = "", O.value = [], k.value = [], a("cancel");
|
|
4173
|
+
}, O = E([]), I = E(!1), N = E(""), z = async () => {
|
|
4172
4174
|
if (!o.value.length) {
|
|
4173
|
-
|
|
4175
|
+
N.value = "", k.value = [], a("cancel");
|
|
4174
4176
|
return;
|
|
4175
4177
|
}
|
|
4176
|
-
I.value = !0,
|
|
4178
|
+
I.value = !0, N.value = "", O.value = [], k.value = [];
|
|
4177
4179
|
try {
|
|
4178
4180
|
const w = o.value.map((L) => R(L)), j = await Promise.allSettled(w);
|
|
4179
4181
|
let M = !0;
|
|
@@ -4181,7 +4183,7 @@ const os = {
|
|
|
4181
4183
|
L.status !== "fulfilled" && (M = !1);
|
|
4182
4184
|
}), M ? (O.value = [], k.value = [], a("add:success", o.value), o.value = []) : (O.value.length && a("add:partial-success", O.value), o.value = [], G(j));
|
|
4183
4185
|
} catch {
|
|
4184
|
-
|
|
4186
|
+
N.value = t("consumer_groups.errors.add"), a("error", N.value);
|
|
4185
4187
|
} finally {
|
|
4186
4188
|
I.value = !1;
|
|
4187
4189
|
}
|
|
@@ -4219,12 +4221,12 @@ const os = {
|
|
|
4219
4221
|
"is-visible": e.visible,
|
|
4220
4222
|
title: m(t)("consumer_groups.consumers.add.title"),
|
|
4221
4223
|
onCanceled: b,
|
|
4222
|
-
onProceed:
|
|
4224
|
+
onProceed: z
|
|
4223
4225
|
}, {
|
|
4224
4226
|
"body-content": h(() => [
|
|
4225
4227
|
D("div", fl, [
|
|
4226
|
-
D("p", ml,
|
|
4227
|
-
|
|
4228
|
+
D("p", ml, B(m(t)("consumer_groups.consumers.add.ctaText")), 1),
|
|
4229
|
+
K(M, {
|
|
4228
4230
|
modelValue: o.value,
|
|
4229
4231
|
"onUpdate:modelValue": j[0] || (j[0] = (ee) => o.value = ee),
|
|
4230
4232
|
autosuggest: "",
|
|
@@ -4239,14 +4241,14 @@ const os = {
|
|
|
4239
4241
|
width: "100%",
|
|
4240
4242
|
onQueryChange: m(s)
|
|
4241
4243
|
}, null, 8, ["modelValue", "dropdown-footer-text", "items", "label", "loading", "placeholder", "readonly", "onQueryChange"]),
|
|
4242
|
-
|
|
4243
|
-
|
|
4244
|
+
N.value || d.value || k.value.length ? (f(), $("div", gl, [
|
|
4245
|
+
K(L, { appearance: "danger" }, {
|
|
4244
4246
|
alertMessage: h(() => [
|
|
4245
|
-
D("p", null,
|
|
4246
|
-
k.value.length ? (f(),
|
|
4247
|
-
(f(!0),
|
|
4247
|
+
D("p", null, B(m(t)("consumer_groups.errors.add")), 1),
|
|
4248
|
+
k.value.length ? (f(), $("ul", yl, [
|
|
4249
|
+
(f(!0), $(Ce, null, ve(k.value, (ee, te) => (f(), $("li", { key: te }, B(ee), 1))), 128))
|
|
4248
4250
|
])) : J("", !0),
|
|
4249
|
-
D("div", null,
|
|
4251
|
+
D("div", null, B(N.value || d.value), 1)
|
|
4250
4252
|
]),
|
|
4251
4253
|
_: 1
|
|
4252
4254
|
})
|
|
@@ -4257,12 +4259,12 @@ const os = {
|
|
|
4257
4259
|
}, 8, ["action-pending", "is-visible", "title"]);
|
|
4258
4260
|
};
|
|
4259
4261
|
}
|
|
4260
|
-
}),
|
|
4262
|
+
}), Bt = (e, n) => {
|
|
4261
4263
|
const t = e.__vccOpts || e;
|
|
4262
4264
|
for (const [r, a] of n)
|
|
4263
4265
|
t[r] = a;
|
|
4264
4266
|
return t;
|
|
4265
|
-
}, vl = /* @__PURE__ */
|
|
4267
|
+
}, vl = /* @__PURE__ */ Bt(hl, [["__scopeId", "data-v-3808b4c0"]]), bl = { class: "kong-ui-entities-consumer-groups-list" }, Cl = { key: 1 }, kl = /* @__PURE__ */ oe({
|
|
4266
4268
|
__name: "ConsumerGroupList",
|
|
4267
4269
|
props: {
|
|
4268
4270
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4309,7 +4311,7 @@ const os = {
|
|
|
4309
4311
|
emits: ["error", "copy:success", "copy:error", "delete:success", "add:success", "remove:success"],
|
|
4310
4312
|
setup(e, { emit: n }) {
|
|
4311
4313
|
var qt;
|
|
4312
|
-
const t = n, r = e, { i18nT: a, i18n: { t: i } } = dt.useI18n(), o = It(), { axiosInstance: s } =
|
|
4314
|
+
const t = n, r = e, { i18nT: a, i18n: { t: i } } = dt.useI18n(), o = It(), { axiosInstance: s } = Kt({
|
|
4313
4315
|
headers: (qt = r.config) == null ? void 0 : qt.requestHeaders
|
|
4314
4316
|
}), l = E(1), u = A(() => !!r.config.consumerId), p = A(() => r.config.app !== "kongManager" || !!r.config.disableSorting), c = {
|
|
4315
4317
|
name: { label: i("consumer_groups.list.table_headers.name"), searchable: !0, sortable: !0 }
|
|
@@ -4339,9 +4341,9 @@ const os = {
|
|
|
4339
4341
|
};
|
|
4340
4342
|
}), y = A(() => u.value ? "consumer_groups" : void 0), { fetcher: b, fetcherState: O } = pl(r.config, _.value, y.value), I = () => {
|
|
4341
4343
|
v.value = "";
|
|
4342
|
-
},
|
|
4344
|
+
}, N = () => {
|
|
4343
4345
|
l.value++;
|
|
4344
|
-
},
|
|
4346
|
+
}, z = E(null), ie = (x, W) => {
|
|
4345
4347
|
const ae = x.id;
|
|
4346
4348
|
if (!W(ae)) {
|
|
4347
4349
|
t("copy:error", {
|
|
@@ -4375,7 +4377,7 @@ const os = {
|
|
|
4375
4377
|
}, G = (x) => ({
|
|
4376
4378
|
label: i("consumer_groups.actions.view"),
|
|
4377
4379
|
to: r.config.getViewRoute(x)
|
|
4378
|
-
}),
|
|
4380
|
+
}), F = (x) => ({
|
|
4379
4381
|
label: i("consumer_groups.actions.edit"),
|
|
4380
4382
|
to: r.config.getEditRoute(x)
|
|
4381
4383
|
}), w = E(void 0), j = E(!1), M = E(!1), L = E(""), Y = cl(r.config, _.value), ee = (x) => {
|
|
@@ -4402,36 +4404,36 @@ const os = {
|
|
|
4402
4404
|
W || C(), l.value++, t("add:success", x);
|
|
4403
4405
|
}, se = () => {
|
|
4404
4406
|
u.value && Ge();
|
|
4405
|
-
}, P = E(void 0),
|
|
4406
|
-
P.value = x,
|
|
4407
|
+
}, P = E(void 0), H = E(!1), ye = E(""), _e = (x) => {
|
|
4408
|
+
P.value = x, H.value = !0;
|
|
4407
4409
|
}, pe = () => {
|
|
4408
|
-
|
|
4409
|
-
},
|
|
4410
|
+
H.value = !1, P.value = void 0;
|
|
4411
|
+
}, Fe = A(() => {
|
|
4410
4412
|
var W, ae, he, Ie;
|
|
4411
4413
|
let x = `${r.config.apiBaseUrl}${Me.list[r.config.app].oneForConsumer}`;
|
|
4412
4414
|
return r.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((W = r.config) == null ? void 0 : W.controlPlaneId) || "").replace(/{consumerId}/gi, ((ae = r.config) == null ? void 0 : ae.consumerId) || "") : r.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (he = r.config) != null && he.workspace ? `/${r.config.workspace}` : "").replace(/{consumerId}/gi, ((Ie = r.config) == null ? void 0 : Ie.consumerId) || "")), x;
|
|
4413
|
-
}),
|
|
4415
|
+
}), ze = E(!1), mr = async () => {
|
|
4414
4416
|
if (P.value) {
|
|
4415
|
-
|
|
4417
|
+
ze.value = !0;
|
|
4416
4418
|
try {
|
|
4417
|
-
const x =
|
|
4419
|
+
const x = Fe.value.replace(/{consumerGroupId}/gi, P.value.id);
|
|
4418
4420
|
await s.delete(x), t("remove:success", P.value), pe(), l.value++;
|
|
4419
4421
|
} catch (x) {
|
|
4420
4422
|
ye.value = x.message || i("consumer_groups.errors.delete"), t("error", x);
|
|
4421
4423
|
} finally {
|
|
4422
|
-
|
|
4424
|
+
ze.value = !1;
|
|
4423
4425
|
}
|
|
4424
4426
|
}
|
|
4425
|
-
},
|
|
4427
|
+
}, Ft = E(!0);
|
|
4426
4428
|
Ae(O, (x) => {
|
|
4427
4429
|
var W, ae, he, Ie;
|
|
4428
|
-
if (Array.isArray((W = x == null ? void 0 : x.response) == null ? void 0 : W.data) && (
|
|
4429
|
-
|
|
4430
|
+
if (Array.isArray((W = x == null ? void 0 : x.response) == null ? void 0 : W.data) && (Ft.value = x.response.data.length > 0), x.status === Ke.Error) {
|
|
4431
|
+
z.value = {
|
|
4430
4432
|
title: i("consumer_groups.errors.general")
|
|
4431
|
-
}, (Ie = (he = (ae = x.error) == null ? void 0 : ae.response) == null ? void 0 : he.data) != null && Ie.message && (
|
|
4433
|
+
}, (Ie = (he = (ae = x.error) == null ? void 0 : ae.response) == null ? void 0 : he.data) != null && Ie.message && (z.value.message = x.error.response.data.message), t("error", x.error);
|
|
4432
4434
|
return;
|
|
4433
4435
|
}
|
|
4434
|
-
|
|
4436
|
+
z.value = null;
|
|
4435
4437
|
});
|
|
4436
4438
|
const ft = E({
|
|
4437
4439
|
ctaPath: u.value ? void 0 : r.config.createRoute,
|
|
@@ -4442,16 +4444,16 @@ const os = {
|
|
|
4442
4444
|
return ct(async () => {
|
|
4443
4445
|
await r.canCreate() && (ft.value.title = u.value ? i("consumer_groups.list.empty_state.title_for_consumer") : i("consumer_groups.list.empty_state.title"), ft.value.ctaText = u.value ? i("consumer_groups.actions.add_to_group") : i("consumer_groups.actions.create"));
|
|
4444
4446
|
}), (x, W) => {
|
|
4445
|
-
const ae = U("KButton"), he = U("KBadge"), Ie = U("KTruncate"),
|
|
4446
|
-
return f(),
|
|
4447
|
-
|
|
4447
|
+
const ae = U("KButton"), he = U("KBadge"), Ie = U("KTruncate"), He = U("KDropdownItem"), Lt = U("KClipboardProvider"), gr = U("KPrompt");
|
|
4448
|
+
return f(), $("div", bl, [
|
|
4449
|
+
K(m(Ls), {
|
|
4448
4450
|
"cache-identifier": e.cacheIdentifier,
|
|
4449
4451
|
"disable-pagination": u.value,
|
|
4450
4452
|
"disable-pagination-page-jump": "",
|
|
4451
4453
|
"disable-sorting": p.value,
|
|
4452
4454
|
"empty-state-options": ft.value,
|
|
4453
4455
|
"enable-entity-actions": "",
|
|
4454
|
-
"error-message":
|
|
4456
|
+
"error-message": z.value,
|
|
4455
4457
|
fetcher: m(b),
|
|
4456
4458
|
"fetcher-cache-key": l.value,
|
|
4457
4459
|
"pagination-type": "offset",
|
|
@@ -4463,7 +4465,7 @@ const os = {
|
|
|
4463
4465
|
onClearSearchInput: I,
|
|
4464
4466
|
"onClick:row": W[3] || (W[3] = (Z) => k(Z)),
|
|
4465
4467
|
onEmptyStateCtaClicked: se,
|
|
4466
|
-
onSort:
|
|
4468
|
+
onSort: N
|
|
4467
4469
|
}, {
|
|
4468
4470
|
"toolbar-filter": h(() => [
|
|
4469
4471
|
u.value ? J("", !0) : (f(), V(m(rl), {
|
|
@@ -4478,11 +4480,11 @@ const os = {
|
|
|
4478
4480
|
disabled: !e.useActionOutside,
|
|
4479
4481
|
to: "#kong-ui-app-page-header-action-button"
|
|
4480
4482
|
}, [
|
|
4481
|
-
|
|
4483
|
+
K(m(tt), {
|
|
4482
4484
|
"auth-function": () => e.canCreate()
|
|
4483
4485
|
}, {
|
|
4484
4486
|
default: h(() => [
|
|
4485
|
-
We(
|
|
4487
|
+
We(K(ae, {
|
|
4486
4488
|
appearance: "primary",
|
|
4487
4489
|
"data-testid": "toolbar-add-consumer-group",
|
|
4488
4490
|
icon: "plus",
|
|
@@ -4490,11 +4492,11 @@ const os = {
|
|
|
4490
4492
|
onClick: W[1] || (W[1] = () => e.config.consumerId ? Ge() : void 0)
|
|
4491
4493
|
}, {
|
|
4492
4494
|
default: h(() => [
|
|
4493
|
-
Q(
|
|
4495
|
+
Q(B(e.config.consumerId ? m(i)("consumer_groups.actions.add_to_group") : m(i)("consumer_groups.list.toolbar_actions.new_consumer_group")), 1)
|
|
4494
4496
|
]),
|
|
4495
4497
|
_: 1
|
|
4496
4498
|
}, 8, ["to"]), [
|
|
4497
|
-
[Ye,
|
|
4499
|
+
[Ye, Ft.value]
|
|
4498
4500
|
])
|
|
4499
4501
|
]),
|
|
4500
4502
|
_: 1
|
|
@@ -4502,62 +4504,62 @@ const os = {
|
|
|
4502
4504
|
], 8, ["disabled"]))
|
|
4503
4505
|
]),
|
|
4504
4506
|
name: h(({ rowValue: Z }) => [
|
|
4505
|
-
D("b", null,
|
|
4507
|
+
D("b", null, B(Z ?? "-"), 1)
|
|
4506
4508
|
]),
|
|
4507
4509
|
consumers_count: h(({ rowValue: Z }) => [
|
|
4508
|
-
Q(
|
|
4510
|
+
Q(B(Z ?? "-"), 1)
|
|
4509
4511
|
]),
|
|
4510
4512
|
tags: h(({ rowValue: Z }) => [
|
|
4511
4513
|
(Z == null ? void 0 : Z.length) > 0 ? (f(), V(Ie, { key: 0 }, {
|
|
4512
4514
|
default: h(() => [
|
|
4513
|
-
(f(!0),
|
|
4515
|
+
(f(!0), $(Ce, null, ve(Z, (qe) => (f(), V(he, {
|
|
4514
4516
|
key: qe,
|
|
4515
4517
|
onClick: W[2] || (W[2] = rt(() => {
|
|
4516
4518
|
}, ["stop"]))
|
|
4517
4519
|
}, {
|
|
4518
4520
|
default: h(() => [
|
|
4519
|
-
Q(
|
|
4521
|
+
Q(B(qe), 1)
|
|
4520
4522
|
]),
|
|
4521
4523
|
_: 2
|
|
4522
4524
|
}, 1024))), 128))
|
|
4523
4525
|
]),
|
|
4524
4526
|
_: 2
|
|
4525
|
-
}, 1024)) : (f(),
|
|
4527
|
+
}, 1024)) : (f(), $("span", Cl, "-"))
|
|
4526
4528
|
]),
|
|
4527
4529
|
actions: h(({ row: Z }) => [
|
|
4528
|
-
|
|
4530
|
+
K(Lt, null, {
|
|
4529
4531
|
default: h(({ copyToClipboard: qe }) => [
|
|
4530
|
-
|
|
4532
|
+
K(He, {
|
|
4531
4533
|
"data-testid": "action-entity-copy-id",
|
|
4532
4534
|
onClick: (yr) => ie(Z, qe)
|
|
4533
4535
|
}, {
|
|
4534
4536
|
default: h(() => [
|
|
4535
|
-
Q(
|
|
4537
|
+
Q(B(m(i)("consumer_groups.actions.copy_id")), 1)
|
|
4536
4538
|
]),
|
|
4537
4539
|
_: 2
|
|
4538
4540
|
}, 1032, ["onClick"])
|
|
4539
4541
|
]),
|
|
4540
4542
|
_: 2
|
|
4541
4543
|
}, 1024),
|
|
4542
|
-
|
|
4544
|
+
K(Lt, null, {
|
|
4543
4545
|
default: h(({ copyToClipboard: qe }) => [
|
|
4544
|
-
|
|
4546
|
+
K(He, {
|
|
4545
4547
|
"data-testid": "action-entity-copy-json",
|
|
4546
4548
|
onClick: (yr) => R(Z, qe)
|
|
4547
4549
|
}, {
|
|
4548
4550
|
default: h(() => [
|
|
4549
|
-
Q(
|
|
4551
|
+
Q(B(m(i)("consumer_groups.actions.copy_json")), 1)
|
|
4550
4552
|
]),
|
|
4551
4553
|
_: 2
|
|
4552
4554
|
}, 1032, ["onClick"])
|
|
4553
4555
|
]),
|
|
4554
4556
|
_: 2
|
|
4555
4557
|
}, 1024),
|
|
4556
|
-
|
|
4558
|
+
K(m(tt), {
|
|
4557
4559
|
"auth-function": () => e.canRetrieve(Z)
|
|
4558
4560
|
}, {
|
|
4559
4561
|
default: h(() => [
|
|
4560
|
-
|
|
4562
|
+
K(He, {
|
|
4561
4563
|
"data-testid": "action-entity-view",
|
|
4562
4564
|
"has-divider": "",
|
|
4563
4565
|
item: G(Z.id)
|
|
@@ -4565,29 +4567,29 @@ const os = {
|
|
|
4565
4567
|
]),
|
|
4566
4568
|
_: 2
|
|
4567
4569
|
}, 1032, ["auth-function"]),
|
|
4568
|
-
|
|
4570
|
+
K(m(tt), {
|
|
4569
4571
|
"auth-function": () => e.canEdit(Z)
|
|
4570
4572
|
}, {
|
|
4571
4573
|
default: h(() => [
|
|
4572
|
-
|
|
4574
|
+
K(He, {
|
|
4573
4575
|
"data-testid": "action-entity-edit",
|
|
4574
|
-
item:
|
|
4576
|
+
item: F(Z.id)
|
|
4575
4577
|
}, null, 8, ["item"])
|
|
4576
4578
|
]),
|
|
4577
4579
|
_: 2
|
|
4578
4580
|
}, 1032, ["auth-function"]),
|
|
4579
|
-
|
|
4581
|
+
K(m(tt), {
|
|
4580
4582
|
"auth-function": () => e.canDelete(Z)
|
|
4581
4583
|
}, {
|
|
4582
4584
|
default: h(() => [
|
|
4583
|
-
|
|
4585
|
+
K(He, {
|
|
4584
4586
|
danger: "",
|
|
4585
4587
|
"data-testid": "action-entity-delete",
|
|
4586
4588
|
"has-divider": "",
|
|
4587
4589
|
onClick: () => e.config.consumerId ? _e(Z) : ee(Z)
|
|
4588
4590
|
}, {
|
|
4589
4591
|
default: h(() => [
|
|
4590
|
-
Q(
|
|
4592
|
+
Q(B(e.config.consumerId ? m(i)("consumer_groups.actions.exit") : m(i)("consumer_groups.actions.delete")), 1)
|
|
4591
4593
|
]),
|
|
4592
4594
|
_: 2
|
|
4593
4595
|
}, 1032, ["onClick"])
|
|
@@ -4597,7 +4599,7 @@ const os = {
|
|
|
4597
4599
|
]),
|
|
4598
4600
|
_: 1
|
|
4599
4601
|
}, 8, ["cache-identifier", "disable-pagination", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers", "use-action-outside"]),
|
|
4600
|
-
|
|
4602
|
+
K(m(Vs), {
|
|
4601
4603
|
"action-pending": M.value,
|
|
4602
4604
|
"data-testid": "delete-consumer-group-modal",
|
|
4603
4605
|
description: m(i)("consumer_groups.delete.description"),
|
|
@@ -4621,39 +4623,39 @@ const os = {
|
|
|
4621
4623
|
e.config.consumerId && P.value ? (f(), V(gr, {
|
|
4622
4624
|
key: 1,
|
|
4623
4625
|
"data-testid": "exit-group-modal",
|
|
4624
|
-
"is-visible":
|
|
4626
|
+
"is-visible": H.value,
|
|
4625
4627
|
title: m(i)("consumer_groups.consumers.exit.title"),
|
|
4626
4628
|
type: "danger",
|
|
4627
4629
|
onCanceled: pe,
|
|
4628
4630
|
onProceed: mr
|
|
4629
4631
|
}, {
|
|
4630
4632
|
"body-content": h(() => [
|
|
4631
|
-
|
|
4633
|
+
K(m(a), {
|
|
4632
4634
|
class: "exit-modal-message",
|
|
4633
4635
|
keypath: e.config.consumerUsername ? "consumer_groups.consumers.exit.confirmation" : "consumer_groups.consumers.exit.confirmationNoUsername",
|
|
4634
4636
|
tag: "p"
|
|
4635
4637
|
}, je({
|
|
4636
4638
|
consumerGroup: h(() => [
|
|
4637
|
-
D("strong", null,
|
|
4639
|
+
D("strong", null, B(P.value.name || P.value.id), 1)
|
|
4638
4640
|
]),
|
|
4639
4641
|
_: 2
|
|
4640
4642
|
}, [
|
|
4641
4643
|
e.config.consumerUsername ? {
|
|
4642
4644
|
name: "consumer",
|
|
4643
4645
|
fn: h(() => [
|
|
4644
|
-
D("strong", null,
|
|
4646
|
+
D("strong", null, B(e.config.consumerUsername), 1)
|
|
4645
4647
|
]),
|
|
4646
4648
|
key: "0"
|
|
4647
4649
|
} : void 0
|
|
4648
4650
|
]), 1032, ["keypath"]),
|
|
4649
|
-
D("p", null,
|
|
4651
|
+
D("p", null, B(m(i)("consumer_groups.consumers.exit.description")), 1)
|
|
4650
4652
|
]),
|
|
4651
4653
|
_: 1
|
|
4652
4654
|
}, 8, ["is-visible", "title"])) : J("", !0)
|
|
4653
4655
|
]);
|
|
4654
4656
|
};
|
|
4655
4657
|
}
|
|
4656
|
-
}), ql = /* @__PURE__ */
|
|
4658
|
+
}), ql = /* @__PURE__ */ Bt(kl, [["__scopeId", "data-v-12149d54"]]), wl = { class: "kong-ui-entities-consumer-group-form" }, _l = { class: "select-item-label" }, Il = {
|
|
4657
4659
|
key: 0,
|
|
4658
4660
|
class: "select-item-desc"
|
|
4659
4661
|
}, Sl = /* @__PURE__ */ oe({
|
|
@@ -4696,7 +4698,7 @@ const os = {
|
|
|
4696
4698
|
} = fr(t.config, (ue = Me.form[(ne = t.config) == null ? void 0 : ne.app]) == null ? void 0 : ue.consumersList, "", {
|
|
4697
4699
|
fetchedItemsKey: "data",
|
|
4698
4700
|
searchKeys: ["username", "custom_id", "id"]
|
|
4699
|
-
}), { axiosInstance: d } =
|
|
4701
|
+
}), { axiosInstance: d } = Kt({
|
|
4700
4702
|
headers: (Ge = t.config) == null ? void 0 : Ge.requestHeaders
|
|
4701
4703
|
}), { getMessageFromError: _ } = dl(), v = A(() => g.value.map((C) => ({
|
|
4702
4704
|
label: C.username || C.custom_id,
|
|
@@ -4708,26 +4710,26 @@ const os = {
|
|
|
4708
4710
|
var C, q;
|
|
4709
4711
|
return (q = Me.form[(C = t.config) == null ? void 0 : C.app]) == null ? void 0 : q.edit;
|
|
4710
4712
|
}), y = A(() => t.consumerGroupId ? nt.Edit : nt.Create), b = A(() => !!o.fields.name && !k.value), O = A(() => JSON.stringify(o.fields) !== JSON.stringify(s)), I = (C, q = "", se = "") => {
|
|
4711
|
-
var
|
|
4712
|
-
let P = `${(
|
|
4713
|
-
return ((_e = t.config) == null ? void 0 : _e.app) === "konnect" ? P = P.replace(/{controlPlaneId}/gi, ((pe = t.config) == null ? void 0 : pe.controlPlaneId) || "") : ((
|
|
4714
|
-
},
|
|
4713
|
+
var H, ye, _e, pe, Fe, ze;
|
|
4714
|
+
let P = `${(H = t.config) == null ? void 0 : H.apiBaseUrl}${Me.form[(ye = t.config) == null ? void 0 : ye.app][C]}`;
|
|
4715
|
+
return ((_e = t.config) == null ? void 0 : _e.app) === "konnect" ? P = P.replace(/{controlPlaneId}/gi, ((pe = t.config) == null ? void 0 : pe.controlPlaneId) || "") : ((Fe = t.config) == null ? void 0 : Fe.app) === "kongManager" && (P = P.replace(/\/{workspace}/gi, (ze = t.config) != null && ze.workspace ? `/${t.config.workspace}` : "")), P = P.replace(/{id}/gi, q || t.consumerGroupId), (C === "addConsumer" || C === "removeConsumer") && (P = P.replace(/{consumerId}/gi, se)), P;
|
|
4716
|
+
}, N = () => {
|
|
4715
4717
|
var C;
|
|
4716
4718
|
i.push(((C = t.config) == null ? void 0 : C.cancelRoute) || { name: "consumer-group-list" });
|
|
4717
|
-
},
|
|
4719
|
+
}, z = (C) => {
|
|
4718
4720
|
r("error", C);
|
|
4719
4721
|
}, ie = (C) => {
|
|
4720
4722
|
r("loading", C);
|
|
4721
4723
|
}, R = async (C) => {
|
|
4722
|
-
var se, P,
|
|
4724
|
+
var se, P, H, ye, _e;
|
|
4723
4725
|
o.fields.name = ((se = C == null ? void 0 : C.item) == null ? void 0 : se.name) || ((P = C == null ? void 0 : C.consumer_group) == null ? void 0 : P.name) || (C == null ? void 0 : C.name) || "";
|
|
4724
|
-
const q = ((
|
|
4726
|
+
const q = ((H = C == null ? void 0 : C.item) == null ? void 0 : H.tags) || (C == null ? void 0 : C.consumer_group.tags) || (C == null ? void 0 : C.tags) || [];
|
|
4725
4727
|
if (o.fields.tags = (q == null ? void 0 : q.join(", ")) || "", "consumers" in C)
|
|
4726
4728
|
o.fields.consumers = ((ye = C == null ? void 0 : C.consumers) == null ? void 0 : ye.map((pe) => pe.id)) || [];
|
|
4727
4729
|
else
|
|
4728
4730
|
try {
|
|
4729
4731
|
const { data: pe } = await d.get(I("getConsumers"));
|
|
4730
|
-
o.fields.consumers = "consumers" in pe ? (_e = pe == null ? void 0 : pe.consumers) == null ? void 0 : _e.map((
|
|
4732
|
+
o.fields.consumers = "consumers" in pe ? (_e = pe == null ? void 0 : pe.consumers) == null ? void 0 : _e.map((Fe) => Fe.id) : [];
|
|
4731
4733
|
} catch (pe) {
|
|
4732
4734
|
j(pe);
|
|
4733
4735
|
}
|
|
@@ -4738,12 +4740,12 @@ const os = {
|
|
|
4738
4740
|
name: o.fields.name,
|
|
4739
4741
|
tags: (q = (C = o.fields.tags.split(",")) == null ? void 0 : C.map((se) => String(se || "").trim())) == null ? void 0 : q.filter((se) => se !== "")
|
|
4740
4742
|
};
|
|
4741
|
-
},
|
|
4743
|
+
}, F = async (C, q = "") => await d.post(I("addConsumer", q, C), { consumer: C }), w = async (C, q = "") => await d.delete(I("removeConsumer", q, C)), j = (C) => {
|
|
4742
4744
|
o.errorMessage = _(C), r("error", C);
|
|
4743
4745
|
}, M = (C = t.consumerGroupId) => {
|
|
4744
4746
|
Object.assign(s, o.fields), r("update", { ...o.fields, id: C });
|
|
4745
4747
|
}, L = (C, q, se = t.consumerGroupId) => {
|
|
4746
|
-
const P = C == null ? void 0 : C.find((
|
|
4748
|
+
const P = C == null ? void 0 : C.find((H) => H.status !== "fulfilled");
|
|
4747
4749
|
P ? j({
|
|
4748
4750
|
code: P.status,
|
|
4749
4751
|
message: q
|
|
@@ -4758,7 +4760,7 @@ const os = {
|
|
|
4758
4760
|
}
|
|
4759
4761
|
if (o.fields.consumers.length > 0 && C)
|
|
4760
4762
|
try {
|
|
4761
|
-
const q = o.fields.consumers.map((P) =>
|
|
4763
|
+
const q = o.fields.consumers.map((P) => F(P, C)), se = await Promise.allSettled(q);
|
|
4762
4764
|
L(se, a("consumer_groups.errors.add_consumer"), C);
|
|
4763
4765
|
} catch (q) {
|
|
4764
4766
|
j(q);
|
|
@@ -4778,15 +4780,15 @@ const os = {
|
|
|
4778
4780
|
else {
|
|
4779
4781
|
if (q.length > 0)
|
|
4780
4782
|
try {
|
|
4781
|
-
const P = q.map((ye) => w(ye)),
|
|
4782
|
-
L(
|
|
4783
|
+
const P = q.map((ye) => w(ye)), H = await Promise.allSettled(P);
|
|
4784
|
+
L(H, a("consumer_groups.errors.remove_consumer"));
|
|
4783
4785
|
} catch (P) {
|
|
4784
4786
|
j(P);
|
|
4785
4787
|
}
|
|
4786
4788
|
if (C.length > 0)
|
|
4787
4789
|
try {
|
|
4788
|
-
const P = C.map((ye) =>
|
|
4789
|
-
L(
|
|
4790
|
+
const P = C.map((ye) => F(ye)), H = await Promise.allSettled(P);
|
|
4791
|
+
L(H, a("consumer_groups.errors.add_consumer"));
|
|
4790
4792
|
} catch (P) {
|
|
4791
4793
|
j(P);
|
|
4792
4794
|
}
|
|
@@ -4802,29 +4804,29 @@ const os = {
|
|
|
4802
4804
|
await c();
|
|
4803
4805
|
}), (C, q) => {
|
|
4804
4806
|
const se = U("KInput"), P = U("KMultiselect");
|
|
4805
|
-
return f(),
|
|
4806
|
-
|
|
4807
|
+
return f(), $("div", wl, [
|
|
4808
|
+
K(m(Ms), {
|
|
4807
4809
|
"can-submit": b.value && O.value,
|
|
4808
4810
|
config: e.config,
|
|
4809
4811
|
"edit-id": e.consumerGroupId,
|
|
4810
4812
|
"error-message": o.errorMessage || m(p) || k.value,
|
|
4811
4813
|
"fetch-url": S.value,
|
|
4812
4814
|
"is-readonly": o.readonly,
|
|
4813
|
-
onCancel:
|
|
4814
|
-
"onFetch:error": q[3] || (q[3] = (
|
|
4815
|
+
onCancel: N,
|
|
4816
|
+
"onFetch:error": q[3] || (q[3] = (H) => z(H)),
|
|
4815
4817
|
"onFetch:success": R,
|
|
4816
|
-
onLoading: q[4] || (q[4] = (
|
|
4818
|
+
onLoading: q[4] || (q[4] = (H) => ie(H)),
|
|
4817
4819
|
onSubmit: te
|
|
4818
4820
|
}, {
|
|
4819
4821
|
default: h(() => [
|
|
4820
|
-
|
|
4822
|
+
K(m(fn), {
|
|
4821
4823
|
description: m(a)("consumer_groups.form.general_info.description"),
|
|
4822
4824
|
title: m(a)("consumer_groups.form.general_info.title")
|
|
4823
4825
|
}, {
|
|
4824
4826
|
default: h(() => [
|
|
4825
|
-
|
|
4827
|
+
K(se, {
|
|
4826
4828
|
modelValue: o.fields.name,
|
|
4827
|
-
"onUpdate:modelValue": q[0] || (q[0] = (
|
|
4829
|
+
"onUpdate:modelValue": q[0] || (q[0] = (H) => o.fields.name = H),
|
|
4828
4830
|
modelModifiers: { trim: !0 },
|
|
4829
4831
|
autocomplete: "off",
|
|
4830
4832
|
"data-testid": "consumer-group-form-name",
|
|
@@ -4833,9 +4835,9 @@ const os = {
|
|
|
4833
4835
|
required: "",
|
|
4834
4836
|
type: "text"
|
|
4835
4837
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
4836
|
-
|
|
4838
|
+
K(se, {
|
|
4837
4839
|
modelValue: o.fields.tags,
|
|
4838
|
-
"onUpdate:modelValue": q[1] || (q[1] = (
|
|
4840
|
+
"onUpdate:modelValue": q[1] || (q[1] = (H) => o.fields.tags = H),
|
|
4839
4841
|
modelModifiers: { trim: !0 },
|
|
4840
4842
|
autocomplete: "off",
|
|
4841
4843
|
"data-testid": "consumer-group-form-tags",
|
|
@@ -4851,15 +4853,15 @@ const os = {
|
|
|
4851
4853
|
]),
|
|
4852
4854
|
_: 1
|
|
4853
4855
|
}, 8, ["description", "title"]),
|
|
4854
|
-
|
|
4856
|
+
K(m(fn), {
|
|
4855
4857
|
description: m(a)("consumer_groups.form.consumers.description"),
|
|
4856
4858
|
"has-divider": "",
|
|
4857
4859
|
title: m(a)("consumer_groups.form.consumers.title")
|
|
4858
4860
|
}, {
|
|
4859
4861
|
default: h(() => [
|
|
4860
|
-
|
|
4862
|
+
K(P, {
|
|
4861
4863
|
modelValue: o.fields.consumers,
|
|
4862
|
-
"onUpdate:modelValue": q[2] || (q[2] = (
|
|
4864
|
+
"onUpdate:modelValue": q[2] || (q[2] = (H) => o.fields.consumers = H),
|
|
4863
4865
|
appearance: "select",
|
|
4864
4866
|
autosuggest: "",
|
|
4865
4867
|
"expand-selected": "",
|
|
@@ -4870,11 +4872,11 @@ const os = {
|
|
|
4870
4872
|
width: "auto",
|
|
4871
4873
|
onQueryChange: m(l)
|
|
4872
4874
|
}, {
|
|
4873
|
-
"item-template": h(({ item:
|
|
4875
|
+
"item-template": h(({ item: H }) => {
|
|
4874
4876
|
var ye, _e, pe;
|
|
4875
4877
|
return [
|
|
4876
|
-
D("div", _l,
|
|
4877
|
-
(ye =
|
|
4878
|
+
D("div", _l, B(H.label), 1),
|
|
4879
|
+
(ye = H == null ? void 0 : H.data) != null && ye.username && ((_e = H == null ? void 0 : H.data) != null && _e.custom_id) ? (f(), $("div", Il, B((pe = H == null ? void 0 : H.data) == null ? void 0 : pe.custom_id), 1)) : J("", !0)
|
|
4878
4880
|
];
|
|
4879
4881
|
}),
|
|
4880
4882
|
_: 1
|
|
@@ -4888,7 +4890,7 @@ const os = {
|
|
|
4888
4890
|
]);
|
|
4889
4891
|
};
|
|
4890
4892
|
}
|
|
4891
|
-
}), Ll = /* @__PURE__ */
|
|
4893
|
+
}), Ll = /* @__PURE__ */ Bt(Sl, [["__scopeId", "data-v-102d40d2"]]), Al = { class: "kong-ui-consumer-group-entity-config-card" }, Ul = /* @__PURE__ */ oe({
|
|
4892
4894
|
__name: "ConsumerGroupConfigCard",
|
|
4893
4895
|
props: {
|
|
4894
4896
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4924,8 +4926,8 @@ const os = {
|
|
|
4924
4926
|
tooltip: t("consumer_groups.form.fields.tags.tooltip")
|
|
4925
4927
|
}
|
|
4926
4928
|
});
|
|
4927
|
-
return (i, o) => (f(),
|
|
4928
|
-
|
|
4929
|
+
return (i, o) => (f(), $("div", Al, [
|
|
4930
|
+
K(m($s), {
|
|
4929
4931
|
config: e.config,
|
|
4930
4932
|
"config-card-doc": e.configCardDoc,
|
|
4931
4933
|
"config-schema": a.value,
|