@kong-ui-public/entities-consumer-groups 1.2.6-pr.852.6f8ea106.0 → 1.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities-consumer-groups.es.js +962 -974
- package/dist/entities-consumer-groups.umd.js +14 -14
- package/dist/style.css +1 -1
- package/package.json +6 -6
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as ie, ref as
|
|
1
|
+
import { defineComponent as ie, ref as F, computed as T, watch as Oe, renderSlot as Z, createCommentVNode as G, unref as h, useSlots as ut, onBeforeMount as Qe, resolveComponent as N, openBlock as f, createBlock as U, createSlots as Se, withCtx as v, createElementVNode as P, createTextVNode as Q, toDisplayString as E, createVNode as j, createElementBlock as A, renderList as ye, Fragment as ve, normalizeClass as Ke, withModifiers as rt, withDirectives as et, vShow as tt, useCssVars as lr, resolveDynamicComponent as ze, normalizeProps as ur, guardReactiveProps as cr, mergeProps as ht, onMounted as dr, onUnmounted as pr, normalizeStyle as fr, inject as mr, pushScopeId as gr, popScopeId as yr, reactive as Lt } from "vue";
|
|
2
2
|
import { useRouter as wt } from "vue-router";
|
|
3
3
|
import { createI18n as It, i18nTComponent as cn } from "@kong-ui-public/i18n";
|
|
4
4
|
import hr from "axios";
|
|
@@ -140,7 +140,7 @@ const ct = {
|
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
};
|
|
143
|
-
var dn = /* @__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))(dn || {}), nt = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(nt || {}),
|
|
143
|
+
var dn = /* @__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))(dn || {}), nt = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(nt || {}), je = /* @__PURE__ */ ((e) => (e[e.Loading = 0] = "Loading", e[e.Idle = 1] = "Idle", e[e.NoResults = 2] = "NoResults", e[e.Error = 3] = "Error", e))(je || {}), ne = /* @__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))(ne || {}), be = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e))(be || {});
|
|
144
144
|
function xt(e = {}) {
|
|
145
145
|
return {
|
|
146
146
|
axiosInstance: hr.create({
|
|
@@ -259,12 +259,12 @@ const xr = {
|
|
|
259
259
|
applyButtonText: "Apply",
|
|
260
260
|
clearButtonText: "Clear",
|
|
261
261
|
clearAllButtonText: "Clear all filters"
|
|
262
|
-
},
|
|
262
|
+
}, Mr = {
|
|
263
263
|
errors: {
|
|
264
264
|
fetch: "Could not fetch available items",
|
|
265
265
|
invalid: "Please select a valid value"
|
|
266
266
|
}
|
|
267
|
-
},
|
|
267
|
+
}, Or = {
|
|
268
268
|
unexpected: "An unexpected error has occurred",
|
|
269
269
|
dataKeyUndefined: 'The data key "{dataKey}" does not exist in the response.'
|
|
270
270
|
}, Er = {
|
|
@@ -278,18 +278,18 @@ const xr = {
|
|
|
278
278
|
message: "Are you sure you want to disable the {entityType} {entityName}?",
|
|
279
279
|
confirmText: "Yes, disable"
|
|
280
280
|
}
|
|
281
|
-
},
|
|
281
|
+
}, jr = {
|
|
282
282
|
deleteModal: xr,
|
|
283
283
|
baseForm: Ar,
|
|
284
284
|
baseTable: Sr,
|
|
285
285
|
baseConfigCard: Tr,
|
|
286
286
|
filter: $r,
|
|
287
|
-
debouncedFilter:
|
|
288
|
-
errors:
|
|
287
|
+
debouncedFilter: Mr,
|
|
288
|
+
errors: Or,
|
|
289
289
|
toggleModal: Er
|
|
290
290
|
};
|
|
291
291
|
function At() {
|
|
292
|
-
const e = It("en-us",
|
|
292
|
+
const e = It("en-us", jr);
|
|
293
293
|
return {
|
|
294
294
|
i18n: e,
|
|
295
295
|
i18nT: cn(e)
|
|
@@ -304,24 +304,24 @@ function Fr(e, n, t, r = {
|
|
|
304
304
|
const { axiosInstance: o } = xt({
|
|
305
305
|
headers: e.requestHeaders
|
|
306
306
|
}), { i18n: { t: a } } = At(), { debounce: i } = _r(), s = i(async (y) => {
|
|
307
|
-
await
|
|
308
|
-
}, 200), l =
|
|
309
|
-
let k = `${e.apiBaseUrl}${
|
|
307
|
+
await C(y);
|
|
308
|
+
}, 200), l = F(!1), c = F(""), d = F(""), u = F([]), m = F(void 0), g = h(n);
|
|
309
|
+
let k = `${e.apiBaseUrl}${g}`;
|
|
310
310
|
e.app === "konnect" ? k = k.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" && (k = k.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : ""));
|
|
311
311
|
const _ = async () => {
|
|
312
312
|
try {
|
|
313
313
|
l.value = !0;
|
|
314
314
|
const { data: y } = await o.get(`${k}?size=${t}`);
|
|
315
|
-
y != null && y.next || (
|
|
315
|
+
y != null && y.next || (m.value = r.fetchedItemsKey in y ? y[r.fetchedItemsKey] : []), u.value = r.fetchedItemsKey in y ? y[r.fetchedItemsKey] : [];
|
|
316
316
|
} catch {
|
|
317
317
|
u.value = [], c.value = a("debouncedFilter.errors.fetch");
|
|
318
318
|
} finally {
|
|
319
319
|
l.value = !1;
|
|
320
320
|
}
|
|
321
|
-
}, p =
|
|
322
|
-
var
|
|
321
|
+
}, p = F(""), C = async (y) => {
|
|
322
|
+
var w, R;
|
|
323
323
|
if (p.value !== y)
|
|
324
|
-
if (p.value = y || "",
|
|
324
|
+
if (p.value = y || "", m.value === void 0)
|
|
325
325
|
try {
|
|
326
326
|
l.value = !0, c.value = "", d.value = "";
|
|
327
327
|
let H = k + "";
|
|
@@ -329,38 +329,38 @@ function Fr(e, n, t, r = {
|
|
|
329
329
|
const { data: re } = await o.get(`${H}?size=${t}`);
|
|
330
330
|
r.fetchedItemsKey in re ? u.value = re[r.fetchedItemsKey] : re != null && re.id ? u.value = [re] : u.value = [];
|
|
331
331
|
} catch (H) {
|
|
332
|
-
((
|
|
332
|
+
((w = H == null ? void 0 : H.response) == null ? void 0 : w.status) === 404 ? d.value = a("debouncedFilter.errors.invalid") : (u.value = [], c.value = a("debouncedFilter.errors.fetch"));
|
|
333
333
|
} finally {
|
|
334
334
|
l.value = !1;
|
|
335
335
|
}
|
|
336
336
|
else
|
|
337
|
-
l.value = !0, d.value = "", y ? (u.value = (
|
|
337
|
+
l.value = !0, d.value = "", y ? (u.value = (R = m.value) == null ? void 0 : R.filter((H) => {
|
|
338
338
|
var re;
|
|
339
339
|
let z = !1;
|
|
340
340
|
for (const I of r.searchKeys) {
|
|
341
|
-
const
|
|
342
|
-
|
|
341
|
+
const V = typeof H[I] == "string" ? (re = H[I]) == null ? void 0 : re.toLowerCase() : H[I];
|
|
342
|
+
V != null && V.includes(y.toLowerCase()) && (z = !0);
|
|
343
343
|
}
|
|
344
344
|
return z;
|
|
345
|
-
}), (!u.value || !u.value.length) && (d.value = a("debouncedFilter.errors.invalid"))) : u.value =
|
|
345
|
+
}), (!u.value || !u.value.length) && (d.value = a("debouncedFilter.errors.invalid"))) : u.value = m.value, l.value = !1;
|
|
346
346
|
};
|
|
347
347
|
return {
|
|
348
348
|
loading: l,
|
|
349
349
|
error: c,
|
|
350
350
|
validationError: d,
|
|
351
351
|
results: u,
|
|
352
|
-
allRecords:
|
|
352
|
+
allRecords: m,
|
|
353
353
|
loadItems: _,
|
|
354
354
|
debouncedQueryChange: s
|
|
355
355
|
};
|
|
356
356
|
}
|
|
357
|
-
function
|
|
357
|
+
function Kr(e, n) {
|
|
358
358
|
const t = h(n), r = T(
|
|
359
359
|
() => e.apiBaseUrl.startsWith("/") ? new URL(`${window.location.origin}${t}`) : new URL(t)
|
|
360
360
|
);
|
|
361
361
|
return r.value.search = "", (o) => `${r.value.href}/${o}`;
|
|
362
362
|
}
|
|
363
|
-
function
|
|
363
|
+
function Br() {
|
|
364
364
|
const { i18n: { t: e } } = At();
|
|
365
365
|
return {
|
|
366
366
|
getMessageFromError: (n) => {
|
|
@@ -389,36 +389,36 @@ function Kr() {
|
|
|
389
389
|
};
|
|
390
390
|
}
|
|
391
391
|
function pn(e, n) {
|
|
392
|
-
const t =
|
|
392
|
+
const t = F(h(e)), r = F(h(n)), o = T(
|
|
393
393
|
() => !!(t.value.app === "konnect" || t.value.isExactMatch)
|
|
394
394
|
), a = T(
|
|
395
395
|
() => r.value.startsWith("/") ? new URL(`${window.location.origin}${r.value}`) : new URL(r.value)
|
|
396
396
|
);
|
|
397
397
|
return (i) => {
|
|
398
|
-
const { page: s, pageSize: l, offset: c, sortColumnKey: d, sortColumnOrder: u, query:
|
|
398
|
+
const { page: s, pageSize: l, offset: c, sortColumnKey: d, sortColumnOrder: u, query: m } = i;
|
|
399
399
|
try {
|
|
400
|
-
let
|
|
401
|
-
return o.value &&
|
|
402
|
-
|
|
403
|
-
}), d &&
|
|
404
|
-
} catch (
|
|
405
|
-
return console.error("RouteList(fetcher)",
|
|
400
|
+
let g = new URL(a.value.href);
|
|
401
|
+
return o.value && m ? (g.search = "", g = new URL(`${g.href}/${m}/`)) : (o.value || new URLSearchParams(m).forEach((k, _) => {
|
|
402
|
+
g.searchParams.append(_, k);
|
|
403
|
+
}), d && g.searchParams.append("sort_by", d), u === "desc" && g.searchParams.append("sort_desc", "1"), g.searchParams.append("size", String(l))), c && s !== 1 && g.searchParams.append("offset", String(c)), g.href;
|
|
404
|
+
} catch (g) {
|
|
405
|
+
return console.error("RouteList(fetcher)", g), r.value;
|
|
406
406
|
}
|
|
407
407
|
};
|
|
408
408
|
}
|
|
409
409
|
function Nr(e, n, t = "data") {
|
|
410
410
|
const r = h(n), { axiosInstance: o } = xt({
|
|
411
411
|
headers: e.requestHeaders
|
|
412
|
-
}), a = pn(e, r), i =
|
|
413
|
-
status:
|
|
412
|
+
}), a = pn(e, r), i = F({
|
|
413
|
+
status: je.Idle
|
|
414
414
|
});
|
|
415
415
|
return { fetcher: async (s) => {
|
|
416
416
|
try {
|
|
417
|
-
i.value = { status:
|
|
417
|
+
i.value = { status: je.Loading };
|
|
418
418
|
const l = a(s), { data: c } = await o.get(l), d = t && t.replace(/[^\w-_]/gi, "");
|
|
419
419
|
let u;
|
|
420
420
|
c[d] && Array.isArray(c[d]) ? u = c[d] : u = Object.keys(c).length ? [c] : [];
|
|
421
|
-
const
|
|
421
|
+
const m = {
|
|
422
422
|
data: u,
|
|
423
423
|
total: u.length,
|
|
424
424
|
...c.offset ? {
|
|
@@ -428,27 +428,27 @@ function Nr(e, n, t = "data") {
|
|
|
428
428
|
} : null
|
|
429
429
|
};
|
|
430
430
|
return i.value = {
|
|
431
|
-
status:
|
|
432
|
-
response:
|
|
433
|
-
},
|
|
431
|
+
status: je.Idle,
|
|
432
|
+
response: m
|
|
433
|
+
}, m;
|
|
434
434
|
} catch (l) {
|
|
435
435
|
const c = {
|
|
436
436
|
data: [],
|
|
437
437
|
total: 0
|
|
438
438
|
};
|
|
439
439
|
return s.query && l.response.status === 404 ? (i.value = {
|
|
440
|
-
status:
|
|
440
|
+
status: je.NoResults,
|
|
441
441
|
response: c,
|
|
442
442
|
error: l
|
|
443
443
|
}, c) : (i.value = {
|
|
444
|
-
status:
|
|
444
|
+
status: je.Error,
|
|
445
445
|
response: c,
|
|
446
446
|
error: l
|
|
447
447
|
}, c);
|
|
448
448
|
}
|
|
449
449
|
}, fetcherState: i };
|
|
450
450
|
}
|
|
451
|
-
function
|
|
451
|
+
function Lr() {
|
|
452
452
|
return {
|
|
453
453
|
getPropValue: (e, n) => (n == null ? void 0 : n[e]) ?? void 0
|
|
454
454
|
};
|
|
@@ -465,27 +465,27 @@ const fn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
465
465
|
if (!n)
|
|
466
466
|
throw new Error(`Invalid argument not valid semver ('${e}' received)`);
|
|
467
467
|
return n.shift(), n;
|
|
468
|
-
},
|
|
468
|
+
}, Pt = (e) => e === "*" || e === "x" || e === "X", Ut = (e) => {
|
|
469
469
|
const n = parseInt(e, 10);
|
|
470
470
|
return isNaN(n) ? e : n;
|
|
471
|
-
},
|
|
472
|
-
if (
|
|
471
|
+
}, Pr = (e, n) => typeof e != typeof n ? [String(e), String(n)] : [e, n], Ur = (e, n) => {
|
|
472
|
+
if (Pt(e) || Pt(n))
|
|
473
473
|
return 0;
|
|
474
|
-
const [t, r] =
|
|
474
|
+
const [t, r] = Pr(Ut(e), Ut(n));
|
|
475
475
|
return t > r ? 1 : t < r ? -1 : 0;
|
|
476
|
-
},
|
|
476
|
+
}, Rt = (e, n) => {
|
|
477
477
|
for (let t = 0; t < Math.max(e.length, n.length); t++) {
|
|
478
|
-
const r =
|
|
478
|
+
const r = Ur(e[t] || "0", n[t] || "0");
|
|
479
479
|
if (r !== 0)
|
|
480
480
|
return r;
|
|
481
481
|
}
|
|
482
482
|
return 0;
|
|
483
|
-
},
|
|
484
|
-
const t = qt(e), r = qt(n), o = t.pop(), a = r.pop(), i =
|
|
485
|
-
return i !== 0 ? i : o && a ?
|
|
486
|
-
},
|
|
487
|
-
|
|
488
|
-
const r =
|
|
483
|
+
}, Rr = (e, n) => {
|
|
484
|
+
const t = qt(e), r = qt(n), o = t.pop(), a = r.pop(), i = Rt(t, r);
|
|
485
|
+
return i !== 0 ? i : o && a ? Rt(o.split("."), a.split(".")) : o || a ? o ? -1 : 1 : 0;
|
|
486
|
+
}, Vt = (e, n, t) => {
|
|
487
|
+
Vr(t);
|
|
488
|
+
const r = Rr(e, n);
|
|
489
489
|
return mn[t].includes(r);
|
|
490
490
|
}, mn = {
|
|
491
491
|
">": [1],
|
|
@@ -494,7 +494,7 @@ const fn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
494
494
|
"<=": [-1, 0],
|
|
495
495
|
"<": [-1],
|
|
496
496
|
"!=": [-1, 1]
|
|
497
|
-
}, Dt = Object.keys(mn),
|
|
497
|
+
}, Dt = Object.keys(mn), Vr = (e) => {
|
|
498
498
|
if (typeof e != "string")
|
|
499
499
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
500
500
|
if (Dt.indexOf(e) === -1)
|
|
@@ -511,16 +511,16 @@ function Gr(e) {
|
|
|
511
511
|
if (!a)
|
|
512
512
|
return !1;
|
|
513
513
|
const [i, s] = a;
|
|
514
|
-
return !(i &&
|
|
514
|
+
return !(i && Vt(o, i, "<") || s && Vt(o, s, ">"));
|
|
515
515
|
}
|
|
516
516
|
const de = {
|
|
517
517
|
useAxios: xt,
|
|
518
518
|
useDebouncedFilter: Fr,
|
|
519
|
-
useDeleteUrlBuilder:
|
|
520
|
-
useErrors:
|
|
519
|
+
useDeleteUrlBuilder: Kr,
|
|
520
|
+
useErrors: Br,
|
|
521
521
|
useFetcher: Nr,
|
|
522
522
|
useFetchUrlBuilder: pn,
|
|
523
|
-
useHelpers:
|
|
523
|
+
useHelpers: Lr,
|
|
524
524
|
useStringHelpers: qr,
|
|
525
525
|
useI18n: At,
|
|
526
526
|
useGatewayFeatureSupported: Gr
|
|
@@ -530,10 +530,10 @@ const de = {
|
|
|
530
530
|
prefix: "Successfully",
|
|
531
531
|
content: " copied to clipboard"
|
|
532
532
|
}
|
|
533
|
-
}, zr = "Copy to clipboard",
|
|
533
|
+
}, zr = "Copy to clipboard", Yr = {
|
|
534
534
|
message: Hr,
|
|
535
535
|
iconTitle: zr
|
|
536
|
-
},
|
|
536
|
+
}, Jr = "kong-ui-copy-uuid-notify", Wr = { class: "kong-ui-copy-uuid" }, Zr = ["onClick"], Gt = 15, Qr = /* @__PURE__ */ ie({
|
|
537
537
|
__name: "CopyUuid",
|
|
538
538
|
props: {
|
|
539
539
|
uuid: {
|
|
@@ -577,62 +577,62 @@ const de = {
|
|
|
577
577
|
},
|
|
578
578
|
emits: ["success", "error"],
|
|
579
579
|
setup(e, { emit: n }) {
|
|
580
|
-
const t = e, { t: r } = It("en-us",
|
|
580
|
+
const t = e, { t: r } = It("en-us", Yr), o = t.notify || mr(Jr, () => {
|
|
581
581
|
}), a = T(() => t.idTooltip ? {
|
|
582
582
|
label: t.idTooltip,
|
|
583
583
|
positionFixed: !0,
|
|
584
584
|
placement: "bottomStart"
|
|
585
585
|
} : {
|
|
586
586
|
title: t.uuid
|
|
587
|
-
}), i = T(() => !!(t.tooltip && t.successTooltip)), s =
|
|
587
|
+
}), i = T(() => !!(t.tooltip && t.successTooltip)), s = F(t.tooltip), l = T(() => t.tooltip ? {
|
|
588
588
|
label: s.value,
|
|
589
589
|
positionFixed: !0,
|
|
590
590
|
maxWidth: "500px",
|
|
591
591
|
placement: "bottomStart"
|
|
592
|
-
} : {}), c = T(() => t.format === "redacted" ? "*****" : t.format === "deleted" ? `*${t.uuid.substring(0, 5)}` : t.uuid), d = (
|
|
593
|
-
s.value =
|
|
592
|
+
} : {}), c = T(() => t.format === "redacted" ? "*****" : t.format === "deleted" ? `*${t.uuid.substring(0, 5)}` : t.uuid), d = (m) => {
|
|
593
|
+
s.value = m, setTimeout(() => {
|
|
594
594
|
s.value = t.tooltip;
|
|
595
595
|
}, 1800);
|
|
596
|
-
}, u = (
|
|
597
|
-
if (!
|
|
596
|
+
}, u = (m) => {
|
|
597
|
+
if (!m(t.uuid)) {
|
|
598
598
|
typeof o == "function" && o({
|
|
599
599
|
type: "error",
|
|
600
600
|
message: r("message.fail")
|
|
601
601
|
}), i.value ? d(r("message.fail")) : n("error", t.uuid);
|
|
602
602
|
return;
|
|
603
603
|
}
|
|
604
|
-
const
|
|
604
|
+
const g = t.uuid.length > Gt, k = t.format === "hidden" || t.format === "redacted" ? r("message.success.prefix") : `"${t.uuid.substring(0, Gt) + (g ? "..." : "")}"`;
|
|
605
605
|
typeof o == "function" && o({
|
|
606
606
|
type: "success",
|
|
607
607
|
message: `${k}${r("message.success.content")}`
|
|
608
608
|
}), i.value ? d(t.successTooltip) : n("success", t.uuid);
|
|
609
609
|
};
|
|
610
|
-
return (
|
|
611
|
-
const k =
|
|
610
|
+
return (m, g) => {
|
|
611
|
+
const k = N("KIcon"), _ = N("KClipboardProvider");
|
|
612
612
|
return f(), A("div", Wr, [
|
|
613
613
|
e.format !== "hidden" ? (f(), U(ze(e.idTooltip ? "KTooltip" : "div"), ht({ key: 0 }, a.value, { "data-testid": "copy-id" }), {
|
|
614
614
|
default: v(() => [
|
|
615
|
-
|
|
616
|
-
class:
|
|
615
|
+
P("div", {
|
|
616
|
+
class: Ke([
|
|
617
617
|
"uuid-container",
|
|
618
618
|
e.truncated ? "truncated-uuid" : null,
|
|
619
619
|
e.useMono ? "mono" : null
|
|
620
620
|
])
|
|
621
|
-
},
|
|
621
|
+
}, E(c.value), 3)
|
|
622
622
|
]),
|
|
623
623
|
_: 1
|
|
624
624
|
}, 16)) : G("", !0),
|
|
625
625
|
(f(), U(ze(e.tooltip ? "KTooltip" : "div"), ht(l.value, { class: "uuid-icon-wrapper" }), {
|
|
626
626
|
default: v(() => [
|
|
627
|
-
|
|
627
|
+
j(_, null, {
|
|
628
628
|
default: v(({ copyToClipboard: p }) => [
|
|
629
|
-
|
|
629
|
+
P("span", {
|
|
630
630
|
"data-testid": "copy-to-clipboard",
|
|
631
631
|
role: "button",
|
|
632
632
|
tabindex: "0",
|
|
633
|
-
onClick: rt((
|
|
633
|
+
onClick: rt((C) => u(p), ["stop"])
|
|
634
634
|
}, [
|
|
635
|
-
|
|
635
|
+
j(k, {
|
|
636
636
|
class: "uuid-icon",
|
|
637
637
|
color: e.iconColor,
|
|
638
638
|
"hide-title": !!e.tooltip || void 0,
|
|
@@ -683,11 +683,11 @@ const de = {
|
|
|
683
683
|
return n.isArrayItem ? (l = a.value) != null && l.name ? r(a.value.name, "_") : t("baseConfigCard.general.entryTitle", { index: n.index }) : "";
|
|
684
684
|
});
|
|
685
685
|
return (l, c) => (f(), U(ze(e.isArrayItem ? "fieldset" : "div"), {
|
|
686
|
-
class:
|
|
686
|
+
class: Ke(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
687
687
|
}, {
|
|
688
688
|
default: v(() => [
|
|
689
689
|
e.isArrayItem ? (f(), A("legend", eo, [
|
|
690
|
-
|
|
690
|
+
P("b", null, E(s.value), 1)
|
|
691
691
|
])) : G("", !0),
|
|
692
692
|
(f(!0), A(ve, null, ye(Object.keys(i.value), (d, u) => (f(), U(St, {
|
|
693
693
|
key: `${o.value}-property-${u}`,
|
|
@@ -718,15 +718,15 @@ const de = {
|
|
|
718
718
|
setup(e) {
|
|
719
719
|
const { i18n: { t: n } } = de.useI18n();
|
|
720
720
|
return (t, r) => {
|
|
721
|
-
const o =
|
|
721
|
+
const o = N("KButton");
|
|
722
722
|
return f(), A("div", null, [
|
|
723
|
-
|
|
723
|
+
j(o, {
|
|
724
724
|
appearance: "btn-link",
|
|
725
725
|
class: "navigation-button",
|
|
726
726
|
onClick: r[0] || (r[0] = (a) => t.$emit("navigation-click", e.item))
|
|
727
727
|
}, {
|
|
728
728
|
default: v(() => [
|
|
729
|
-
|
|
729
|
+
Q(E(e.item.value || h(n)("baseConfigCard.commonFields.link")), 1)
|
|
730
730
|
]),
|
|
731
731
|
_: 1
|
|
732
732
|
})
|
|
@@ -744,25 +744,22 @@ const de = {
|
|
|
744
744
|
setup(e) {
|
|
745
745
|
const { i18n: { t: n } } = de.useI18n();
|
|
746
746
|
return (t, r) => {
|
|
747
|
-
const o =
|
|
747
|
+
const o = N("KBadge");
|
|
748
748
|
return f(), U(o, {
|
|
749
749
|
appearance: e.status ? "success" : "neutral"
|
|
750
750
|
}, {
|
|
751
751
|
default: v(() => [
|
|
752
|
-
|
|
752
|
+
Q(E(e.status ? h(n)("baseConfigCard.statusBadge.enabledLabel") : h(n)("baseConfigCard.statusBadge.disabledLabel")), 1)
|
|
753
753
|
]),
|
|
754
754
|
_: 1
|
|
755
755
|
}, 8, ["appearance"]);
|
|
756
756
|
};
|
|
757
757
|
}
|
|
758
|
-
}), ao = "#0044f4", io = "#e0e4ea", so = "#3a3f51", lo = "1px", uo = "20px", co = { class: "config-card-details-row" }, po = ["data-testid"], fo = ["data-testid"], mo = ["data-testid"], go = ["data-testid"], yo = { key: 1 }, ho = ["data-testid"], vo = ["data-testid"], bo = ["data-testid"], Co = ["data-testid"], ko =
|
|
759
|
-
key: 1,
|
|
760
|
-
class: "attrs-data-text"
|
|
761
|
-
}, Io = {
|
|
758
|
+
}), ao = "#0044f4", io = "#e0e4ea", so = "#3a3f51", lo = "1px", uo = "20px", co = { class: "config-card-details-row" }, po = ["data-testid"], fo = ["data-testid"], mo = ["data-testid"], go = ["data-testid"], yo = { key: 1 }, ho = ["data-testid"], vo = ["data-testid"], bo = ["data-testid"], Co = ["data-testid"], ko = ["title"], _o = {
|
|
762
759
|
name: "ConfigCardItem",
|
|
763
760
|
components: { CopyUuid: gn, JsonCardItem: yn, StatusBadge: oo, InternalLinkItem: ro }
|
|
764
|
-
},
|
|
765
|
-
...
|
|
761
|
+
}, wo = /* @__PURE__ */ ie({
|
|
762
|
+
..._o,
|
|
766
763
|
props: {
|
|
767
764
|
item: {
|
|
768
765
|
type: Object,
|
|
@@ -782,21 +779,21 @@ const de = {
|
|
|
782
779
|
emits: ["navigation-click"],
|
|
783
780
|
setup(e, { emit: n }) {
|
|
784
781
|
const t = e;
|
|
785
|
-
lr((
|
|
786
|
-
"
|
|
787
|
-
|
|
788
|
-
"
|
|
789
|
-
"
|
|
782
|
+
lr((u) => ({
|
|
783
|
+
"2c6ac268": c.value ? "none" : `solid ${h(lo)} ${h(io)}`,
|
|
784
|
+
c7a65802: l.value && i.value ? "block" : "flex",
|
|
785
|
+
"778426fe": l.value && i.value ? "100%" : t.slim ? "50%" : "25%",
|
|
786
|
+
"777f9b48": l.value && i.value ? "100%" : t.slim ? "50%" : "75%"
|
|
790
787
|
}));
|
|
791
|
-
const r =
|
|
788
|
+
const r = ut(), { i18n: { t: o, formatUnixTimeStamp: a } } = de.useI18n(), i = T(() => t.item.value !== void 0 && t.item.value !== null && t.item.value !== ""), s = T(() => !!(t.item.tooltip || r["label-tooltip"])), l = T(() => t.item.type === ne.Json || t.item.type === ne.JsonArray), c = T(() => t.item.type === ne.JsonArray), d = T(() => {
|
|
792
789
|
switch (t.item.type) {
|
|
793
790
|
case ne.ID:
|
|
794
791
|
return {
|
|
795
792
|
tag: "CopyUuid",
|
|
796
793
|
attrs: {
|
|
797
794
|
"data-testid": `${t.item.key}-copy-uuid`,
|
|
798
|
-
"success-tooltip":
|
|
799
|
-
tooltip:
|
|
795
|
+
"success-tooltip": o("baseConfigCard.copy.success"),
|
|
796
|
+
tooltip: o("baseConfigCard.copy.tooltip", { label: t.item.label }),
|
|
800
797
|
truncated: !1,
|
|
801
798
|
uuid: t.item.value,
|
|
802
799
|
notify: () => {
|
|
@@ -808,8 +805,8 @@ const de = {
|
|
|
808
805
|
tag: "div",
|
|
809
806
|
additionalComponent: "CopyUuid",
|
|
810
807
|
childAttrs: {
|
|
811
|
-
"success-tooltip":
|
|
812
|
-
tooltip:
|
|
808
|
+
"success-tooltip": o("baseConfigCard.copy.success"),
|
|
809
|
+
tooltip: o("baseConfigCard.copy.tooltip", { label: t.item.label }),
|
|
813
810
|
truncated: !1,
|
|
814
811
|
notify: () => {
|
|
815
812
|
}
|
|
@@ -821,8 +818,8 @@ const de = {
|
|
|
821
818
|
attrs: {
|
|
822
819
|
"data-testid": `${t.item.key}-copy-uuid-redacted`,
|
|
823
820
|
format: "redacted",
|
|
824
|
-
"success-tooltip":
|
|
825
|
-
tooltip:
|
|
821
|
+
"success-tooltip": o("baseConfigCard.copy.success"),
|
|
822
|
+
tooltip: o("baseConfigCard.copy.tooltip", { label: t.item.label }),
|
|
826
823
|
truncated: !1,
|
|
827
824
|
uuid: t.item.value,
|
|
828
825
|
notify: () => {
|
|
@@ -835,8 +832,8 @@ const de = {
|
|
|
835
832
|
additionalComponent: "CopyUuid",
|
|
836
833
|
childAttrs: {
|
|
837
834
|
format: "redacted",
|
|
838
|
-
"success-tooltip":
|
|
839
|
-
tooltip:
|
|
835
|
+
"success-tooltip": o("baseConfigCard.copy.success"),
|
|
836
|
+
tooltip: o("baseConfigCard.copy.tooltip", { label: t.item.label }),
|
|
840
837
|
truncated: !1,
|
|
841
838
|
notify: () => {
|
|
842
839
|
}
|
|
@@ -848,7 +845,7 @@ const de = {
|
|
|
848
845
|
attrs: {
|
|
849
846
|
"data-testid": `${t.item.key}-date`
|
|
850
847
|
},
|
|
851
|
-
text:
|
|
848
|
+
text: a(t.item.value)
|
|
852
849
|
};
|
|
853
850
|
case ne.BadgeStatus:
|
|
854
851
|
return {
|
|
@@ -874,8 +871,8 @@ const de = {
|
|
|
874
871
|
attrs: {
|
|
875
872
|
"data-testid": `${t.item.key}-internal-link`,
|
|
876
873
|
item: t.item,
|
|
877
|
-
onNavigationClick: (
|
|
878
|
-
n("navigation-click",
|
|
874
|
+
onNavigationClick: (u) => {
|
|
875
|
+
n("navigation-click", u);
|
|
879
876
|
}
|
|
880
877
|
}
|
|
881
878
|
};
|
|
@@ -914,29 +911,29 @@ const de = {
|
|
|
914
911
|
text: t.item.value
|
|
915
912
|
};
|
|
916
913
|
}
|
|
917
|
-
})
|
|
918
|
-
return (
|
|
919
|
-
const
|
|
914
|
+
});
|
|
915
|
+
return (u, m) => {
|
|
916
|
+
const g = N("KLabel"), k = N("KBadge"), _ = N("KMethodBadge");
|
|
920
917
|
return f(), A("div", co, [
|
|
921
|
-
|
|
918
|
+
P("div", {
|
|
922
919
|
class: "config-card-details-label",
|
|
923
920
|
"data-testid": `${e.item.key}-label`
|
|
924
921
|
}, [
|
|
925
|
-
|
|
926
|
-
|
|
922
|
+
Z(u.$slots, "label", { item: e.item }, () => [
|
|
923
|
+
j(g, { "tooltip-attributes": { maxWidth: "500px" } }, Se({
|
|
927
924
|
default: v(() => [
|
|
928
|
-
|
|
925
|
+
Q(E(e.item.label) + " ", 1)
|
|
929
926
|
]),
|
|
930
927
|
_: 2
|
|
931
928
|
}, [
|
|
932
|
-
|
|
929
|
+
s.value ? {
|
|
933
930
|
name: "tooltip",
|
|
934
931
|
fn: v(() => [
|
|
935
|
-
|
|
932
|
+
P("div", {
|
|
936
933
|
"data-testid": `${e.item.key}-label-tooltip`
|
|
937
934
|
}, [
|
|
938
|
-
|
|
939
|
-
|
|
935
|
+
Z(u.$slots, "label-tooltip", {}, () => [
|
|
936
|
+
Q(E(e.item.tooltip), 1)
|
|
940
937
|
], !0)
|
|
941
938
|
], 8, fo)
|
|
942
939
|
]),
|
|
@@ -945,85 +942,76 @@ const de = {
|
|
|
945
942
|
]), 1024)
|
|
946
943
|
], !0)
|
|
947
944
|
], 8, po),
|
|
948
|
-
|
|
945
|
+
P("div", {
|
|
949
946
|
class: "config-card-details-value",
|
|
950
947
|
"data-testid": `${e.item.key}-property-value`
|
|
951
948
|
}, [
|
|
952
|
-
|
|
949
|
+
Z(u.$slots, e.item.key, {
|
|
953
950
|
rowValue: e.item.value
|
|
954
951
|
}, () => [
|
|
955
|
-
|
|
956
|
-
(f(), U(ze(
|
|
952
|
+
i.value ? (f(), A("div", yo, [
|
|
953
|
+
(f(), U(ze(d.value.tag), ur(cr(d.value.attrs)), {
|
|
957
954
|
default: v(() => [
|
|
958
|
-
|
|
955
|
+
d.value.additionalComponent === "KBadge" ? (f(), A("div", {
|
|
959
956
|
key: 0,
|
|
960
957
|
"data-testid": `${e.item.key}-badge-tags`
|
|
961
958
|
}, [
|
|
962
|
-
(f(!0), A(ve, null, ye(e.item.value, (
|
|
963
|
-
key: `${e.item.key}-badge-tag-${
|
|
959
|
+
(f(!0), A(ve, null, ye(e.item.value, (p, C) => (f(), U(k, {
|
|
960
|
+
key: `${e.item.key}-badge-tag-${C}`,
|
|
964
961
|
class: "config-badge",
|
|
965
|
-
"data-testid": `${e.item.key}-badge-tag-${
|
|
966
|
-
"truncation-tooltip":
|
|
962
|
+
"data-testid": `${e.item.key}-badge-tag-${C}`,
|
|
963
|
+
"truncation-tooltip": p
|
|
967
964
|
}, {
|
|
968
965
|
default: v(() => [
|
|
969
|
-
|
|
966
|
+
Q(E(p), 1)
|
|
970
967
|
]),
|
|
971
968
|
_: 2
|
|
972
969
|
}, 1032, ["data-testid", "truncation-tooltip"]))), 128))
|
|
973
970
|
], 8, ho)) : G("", !0),
|
|
974
|
-
|
|
971
|
+
d.value.additionalComponent === "CopyUuid" ? (f(), A("div", {
|
|
975
972
|
key: 1,
|
|
976
973
|
class: "copy-uuid-array",
|
|
977
974
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
978
975
|
}, [
|
|
979
|
-
(f(!0), A(ve, null, ye(e.item.value, (
|
|
980
|
-
key: `${e.item.key}-copy-uuid-${
|
|
981
|
-
"data-testid": `${e.item.key}-copy-uuid-${
|
|
982
|
-
uuid:
|
|
976
|
+
(f(!0), A(ve, null, ye(e.item.value, (p, C) => (f(), U(h(gn), ht(d.value.childAttrs, {
|
|
977
|
+
key: `${e.item.key}-copy-uuid-${C}`,
|
|
978
|
+
"data-testid": `${e.item.key}-copy-uuid-${C}`,
|
|
979
|
+
uuid: p
|
|
983
980
|
}), null, 16, ["data-testid", "uuid"]))), 128))
|
|
984
|
-
], 8, vo)) :
|
|
981
|
+
], 8, vo)) : d.value.additionalComponent === "KMethodBadge" ? (f(), A("div", {
|
|
985
982
|
key: 2,
|
|
986
983
|
class: "method-badge-array",
|
|
987
984
|
"data-testid": `${e.item.key}-badge-methods`
|
|
988
985
|
}, [
|
|
989
|
-
(f(!0), A(ve, null, ye(e.item.value, (
|
|
990
|
-
key: `${e.item.key}-badge-method-${
|
|
986
|
+
(f(!0), A(ve, null, ye(e.item.value, (p, C) => (f(), U(_, {
|
|
987
|
+
key: `${e.item.key}-badge-method-${C}`,
|
|
991
988
|
class: "config-badge",
|
|
992
|
-
"data-testid": `${e.item.key}-badge-method-${
|
|
989
|
+
"data-testid": `${e.item.key}-badge-method-${C}`,
|
|
993
990
|
"is-rounded": "",
|
|
994
|
-
label:
|
|
995
|
-
method: h(vr).includes(
|
|
991
|
+
label: p,
|
|
992
|
+
method: h(vr).includes(p.toLowerCase()) ? p.toLowerCase() : "custom"
|
|
996
993
|
}, {
|
|
997
994
|
default: v(() => [
|
|
998
|
-
|
|
995
|
+
Q(E(p), 1)
|
|
999
996
|
]),
|
|
1000
997
|
_: 2
|
|
1001
998
|
}, 1032, ["data-testid", "label", "method"]))), 128))
|
|
1002
999
|
], 8, bo)) : G("", !0),
|
|
1003
|
-
|
|
1000
|
+
d.value.additionalComponent === "JsonCardItem" ? (f(), A("div", {
|
|
1004
1001
|
key: 3,
|
|
1005
1002
|
"data-testid": `${t.item.key}-json-array-content`
|
|
1006
1003
|
}, [
|
|
1007
|
-
(f(!0), A(ve, null, ye(e.item.value, (
|
|
1008
|
-
key: `json-array-item-${
|
|
1009
|
-
index:
|
|
1004
|
+
(f(!0), A(ve, null, ye(e.item.value, (p, C) => (f(), U(yn, {
|
|
1005
|
+
key: `json-array-item-${C}`,
|
|
1006
|
+
index: C,
|
|
1010
1007
|
"is-array-item": "",
|
|
1011
|
-
item:
|
|
1008
|
+
item: p
|
|
1012
1009
|
}, null, 8, ["index", "item"]))), 128))
|
|
1013
|
-
], 8, Co)) : (f(), A("
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
content: v(() => [
|
|
1019
|
-
Z(M(e.item.value), 1)
|
|
1020
|
-
]),
|
|
1021
|
-
default: v(() => [
|
|
1022
|
-
L("span", _o, M(u.value.text), 1)
|
|
1023
|
-
]),
|
|
1024
|
-
_: 1
|
|
1025
|
-
}, 8, ["label"])) : (f(), A("span", wo, M(u.value.text), 1))
|
|
1026
|
-
]))
|
|
1010
|
+
], 8, Co)) : (f(), A("span", {
|
|
1011
|
+
key: 4,
|
|
1012
|
+
class: Ke(["attrs-data-text", { truncated: e.truncated }]),
|
|
1013
|
+
title: e.truncated ? e.item.value : void 0
|
|
1014
|
+
}, E(d.value.text), 11, ko))
|
|
1027
1015
|
]),
|
|
1028
1016
|
_: 1
|
|
1029
1017
|
}, 16))
|
|
@@ -1036,40 +1024,40 @@ const de = {
|
|
|
1036
1024
|
]);
|
|
1037
1025
|
};
|
|
1038
1026
|
}
|
|
1039
|
-
}), St = /* @__PURE__ */ ke(
|
|
1027
|
+
}), St = /* @__PURE__ */ ke(wo, [["__scopeId", "data-v-a3c5ab01"]]);
|
|
1040
1028
|
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
|
|
1041
1029
|
function hn(e) {
|
|
1042
1030
|
return typeof e > "u" || e === null;
|
|
1043
1031
|
}
|
|
1044
|
-
function
|
|
1032
|
+
function Io(e) {
|
|
1045
1033
|
return typeof e == "object" && e !== null;
|
|
1046
1034
|
}
|
|
1047
|
-
function
|
|
1035
|
+
function xo(e) {
|
|
1048
1036
|
return Array.isArray(e) ? e : hn(e) ? [] : [e];
|
|
1049
1037
|
}
|
|
1050
|
-
function
|
|
1038
|
+
function Ao(e, n) {
|
|
1051
1039
|
var t, r, o, a;
|
|
1052
1040
|
if (n)
|
|
1053
1041
|
for (a = Object.keys(n), t = 0, r = a.length; t < r; t += 1)
|
|
1054
1042
|
o = a[t], e[o] = n[o];
|
|
1055
1043
|
return e;
|
|
1056
1044
|
}
|
|
1057
|
-
function
|
|
1045
|
+
function So(e, n) {
|
|
1058
1046
|
var t = "", r;
|
|
1059
1047
|
for (r = 0; r < n; r += 1)
|
|
1060
1048
|
t += e;
|
|
1061
1049
|
return t;
|
|
1062
1050
|
}
|
|
1063
|
-
function
|
|
1051
|
+
function To(e) {
|
|
1064
1052
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1065
1053
|
}
|
|
1066
|
-
var
|
|
1067
|
-
isNothing:
|
|
1068
|
-
isObject:
|
|
1054
|
+
var $o = hn, Mo = Io, Oo = xo, Eo = So, jo = To, Fo = Ao, le = {
|
|
1055
|
+
isNothing: $o,
|
|
1056
|
+
isObject: Mo,
|
|
1069
1057
|
toArray: Oo,
|
|
1070
|
-
repeat:
|
|
1071
|
-
isNegativeZero:
|
|
1072
|
-
extend:
|
|
1058
|
+
repeat: Eo,
|
|
1059
|
+
isNegativeZero: jo,
|
|
1060
|
+
extend: Fo
|
|
1073
1061
|
};
|
|
1074
1062
|
function vn(e, n) {
|
|
1075
1063
|
var t = "", r = e.reason || "(unknown reason)";
|
|
@@ -1077,15 +1065,15 @@ function vn(e, n) {
|
|
|
1077
1065
|
|
|
1078
1066
|
` + e.mark.snippet), r + " " + t) : r;
|
|
1079
1067
|
}
|
|
1080
|
-
function
|
|
1068
|
+
function Ye(e, n) {
|
|
1081
1069
|
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = n, this.message = vn(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack || "";
|
|
1082
1070
|
}
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1071
|
+
Ye.prototype = Object.create(Error.prototype);
|
|
1072
|
+
Ye.prototype.constructor = Ye;
|
|
1073
|
+
Ye.prototype.toString = function(e) {
|
|
1086
1074
|
return this.name + ": " + vn(this, e);
|
|
1087
1075
|
};
|
|
1088
|
-
var me =
|
|
1076
|
+
var me = Ye;
|
|
1089
1077
|
function mt(e, n, t, r, o) {
|
|
1090
1078
|
var a = "", i = "", s = Math.floor(o / 2) - 1;
|
|
1091
1079
|
return r - n > s && (a = " ... ", n = r - s + a.length), t - r > s && (i = " ...", t = r + s - i.length), {
|
|
@@ -1097,7 +1085,7 @@ function mt(e, n, t, r, o) {
|
|
|
1097
1085
|
function gt(e, n) {
|
|
1098
1086
|
return le.repeat(" ", n - e.length) + e;
|
|
1099
1087
|
}
|
|
1100
|
-
function
|
|
1088
|
+
function Ko(e, n) {
|
|
1101
1089
|
if (n = Object.create(n || null), !e.buffer)
|
|
1102
1090
|
return null;
|
|
1103
1091
|
n.maxLength || (n.maxLength = 79), typeof n.indent != "number" && (n.indent = 1), typeof n.linesBefore != "number" && (n.linesBefore = 3), typeof n.linesAfter != "number" && (n.linesAfter = 2);
|
|
@@ -1127,7 +1115,7 @@ function No(e, n) {
|
|
|
1127
1115
|
`;
|
|
1128
1116
|
return s.replace(/\n$/, "");
|
|
1129
1117
|
}
|
|
1130
|
-
var
|
|
1118
|
+
var Bo = Ko, No = [
|
|
1131
1119
|
"kind",
|
|
1132
1120
|
"multi",
|
|
1133
1121
|
"resolve",
|
|
@@ -1143,7 +1131,7 @@ var Po = No, qo = [
|
|
|
1143
1131
|
"sequence",
|
|
1144
1132
|
"mapping"
|
|
1145
1133
|
];
|
|
1146
|
-
function
|
|
1134
|
+
function qo(e) {
|
|
1147
1135
|
var n = {};
|
|
1148
1136
|
return e !== null && Object.keys(e).forEach(function(t) {
|
|
1149
1137
|
e[t].forEach(function(r) {
|
|
@@ -1151,18 +1139,18 @@ function Vo(e) {
|
|
|
1151
1139
|
});
|
|
1152
1140
|
}), n;
|
|
1153
1141
|
}
|
|
1154
|
-
function
|
|
1142
|
+
function Po(e, n) {
|
|
1155
1143
|
if (n = n || {}, Object.keys(n).forEach(function(t) {
|
|
1156
|
-
if (
|
|
1144
|
+
if (No.indexOf(t) === -1)
|
|
1157
1145
|
throw new me('Unknown option "' + t + '" is met in definition of "' + e + '" YAML type.');
|
|
1158
1146
|
}), this.options = n, this.tag = e, this.kind = n.kind || null, this.resolve = n.resolve || function() {
|
|
1159
1147
|
return !0;
|
|
1160
1148
|
}, this.construct = n.construct || function(t) {
|
|
1161
1149
|
return t;
|
|
1162
|
-
}, this.instanceOf = n.instanceOf || null, this.predicate = n.predicate || null, this.represent = n.represent || null, this.representName = n.representName || null, this.defaultStyle = n.defaultStyle || null, this.multi = n.multi || !1, this.styleAliases =
|
|
1150
|
+
}, this.instanceOf = n.instanceOf || null, this.predicate = n.predicate || null, this.represent = n.represent || null, this.representName = n.representName || null, this.defaultStyle = n.defaultStyle || null, this.multi = n.multi || !1, this.styleAliases = qo(n.styleAliases || null), Lo.indexOf(this.kind) === -1)
|
|
1163
1151
|
throw new me('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.');
|
|
1164
1152
|
}
|
|
1165
|
-
var pe =
|
|
1153
|
+
var pe = Po;
|
|
1166
1154
|
function Ht(e, n) {
|
|
1167
1155
|
var t = [];
|
|
1168
1156
|
return e[n].forEach(function(r) {
|
|
@@ -1172,7 +1160,7 @@ function Ht(e, n) {
|
|
|
1172
1160
|
}), t[o] = r;
|
|
1173
1161
|
}), t;
|
|
1174
1162
|
}
|
|
1175
|
-
function
|
|
1163
|
+
function Uo() {
|
|
1176
1164
|
var e = {
|
|
1177
1165
|
scalar: {},
|
|
1178
1166
|
sequence: {},
|
|
@@ -1217,7 +1205,7 @@ vt.prototype.extend = function(e) {
|
|
|
1217
1205
|
throw new me("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1218
1206
|
});
|
|
1219
1207
|
var r = Object.create(vt.prototype);
|
|
1220
|
-
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(t), r.compiledImplicit = Ht(r, "implicit"), r.compiledExplicit = Ht(r, "explicit"), r.compiledTypeMap =
|
|
1208
|
+
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(t), r.compiledImplicit = Ht(r, "implicit"), r.compiledExplicit = Ht(r, "explicit"), r.compiledTypeMap = Uo(r.compiledImplicit, r.compiledExplicit), r;
|
|
1221
1209
|
};
|
|
1222
1210
|
var bn = vt, Cn = new pe("tag:yaml.org,2002:str", {
|
|
1223
1211
|
kind: "scalar",
|
|
@@ -1241,23 +1229,23 @@ var bn = vt, Cn = new pe("tag:yaml.org,2002:str", {
|
|
|
1241
1229
|
_n
|
|
1242
1230
|
]
|
|
1243
1231
|
});
|
|
1244
|
-
function
|
|
1232
|
+
function Ro(e) {
|
|
1245
1233
|
if (e === null)
|
|
1246
1234
|
return !0;
|
|
1247
1235
|
var n = e.length;
|
|
1248
1236
|
return n === 1 && e === "~" || n === 4 && (e === "null" || e === "Null" || e === "NULL");
|
|
1249
1237
|
}
|
|
1250
|
-
function
|
|
1238
|
+
function Vo() {
|
|
1251
1239
|
return null;
|
|
1252
1240
|
}
|
|
1253
|
-
function
|
|
1241
|
+
function Do(e) {
|
|
1254
1242
|
return e === null;
|
|
1255
1243
|
}
|
|
1256
1244
|
var In = new pe("tag:yaml.org,2002:null", {
|
|
1257
1245
|
kind: "scalar",
|
|
1258
|
-
resolve:
|
|
1259
|
-
construct:
|
|
1260
|
-
predicate:
|
|
1246
|
+
resolve: Ro,
|
|
1247
|
+
construct: Vo,
|
|
1248
|
+
predicate: Do,
|
|
1261
1249
|
represent: {
|
|
1262
1250
|
canonical: function() {
|
|
1263
1251
|
return "~";
|
|
@@ -1277,23 +1265,23 @@ var In = new pe("tag:yaml.org,2002:null", {
|
|
|
1277
1265
|
},
|
|
1278
1266
|
defaultStyle: "lowercase"
|
|
1279
1267
|
});
|
|
1280
|
-
function
|
|
1268
|
+
function Go(e) {
|
|
1281
1269
|
if (e === null)
|
|
1282
1270
|
return !1;
|
|
1283
1271
|
var n = e.length;
|
|
1284
1272
|
return n === 4 && (e === "true" || e === "True" || e === "TRUE") || n === 5 && (e === "false" || e === "False" || e === "FALSE");
|
|
1285
1273
|
}
|
|
1286
|
-
function
|
|
1274
|
+
function Ho(e) {
|
|
1287
1275
|
return e === "true" || e === "True" || e === "TRUE";
|
|
1288
1276
|
}
|
|
1289
|
-
function
|
|
1277
|
+
function zo(e) {
|
|
1290
1278
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1291
1279
|
}
|
|
1292
1280
|
var xn = new pe("tag:yaml.org,2002:bool", {
|
|
1293
1281
|
kind: "scalar",
|
|
1294
|
-
resolve:
|
|
1295
|
-
construct:
|
|
1296
|
-
predicate:
|
|
1282
|
+
resolve: Go,
|
|
1283
|
+
construct: Ho,
|
|
1284
|
+
predicate: zo,
|
|
1297
1285
|
represent: {
|
|
1298
1286
|
lowercase: function(e) {
|
|
1299
1287
|
return e ? "true" : "false";
|
|
@@ -1307,16 +1295,16 @@ var xn = new pe("tag:yaml.org,2002:bool", {
|
|
|
1307
1295
|
},
|
|
1308
1296
|
defaultStyle: "lowercase"
|
|
1309
1297
|
});
|
|
1310
|
-
function
|
|
1298
|
+
function Yo(e) {
|
|
1311
1299
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1312
1300
|
}
|
|
1313
|
-
function
|
|
1301
|
+
function Jo(e) {
|
|
1314
1302
|
return 48 <= e && e <= 55;
|
|
1315
1303
|
}
|
|
1316
|
-
function
|
|
1304
|
+
function Wo(e) {
|
|
1317
1305
|
return 48 <= e && e <= 57;
|
|
1318
1306
|
}
|
|
1319
|
-
function
|
|
1307
|
+
function Zo(e) {
|
|
1320
1308
|
if (e === null)
|
|
1321
1309
|
return !1;
|
|
1322
1310
|
var n = e.length, t = 0, r = !1, o;
|
|
@@ -1337,7 +1325,7 @@ function Xo(e) {
|
|
|
1337
1325
|
if (o === "x") {
|
|
1338
1326
|
for (t++; t < n; t++)
|
|
1339
1327
|
if (o = e[t], o !== "_") {
|
|
1340
|
-
if (!
|
|
1328
|
+
if (!Yo(e.charCodeAt(t)))
|
|
1341
1329
|
return !1;
|
|
1342
1330
|
r = !0;
|
|
1343
1331
|
}
|
|
@@ -1346,7 +1334,7 @@ function Xo(e) {
|
|
|
1346
1334
|
if (o === "o") {
|
|
1347
1335
|
for (t++; t < n; t++)
|
|
1348
1336
|
if (o = e[t], o !== "_") {
|
|
1349
|
-
if (!
|
|
1337
|
+
if (!Jo(e.charCodeAt(t)))
|
|
1350
1338
|
return !1;
|
|
1351
1339
|
r = !0;
|
|
1352
1340
|
}
|
|
@@ -1357,13 +1345,13 @@ function Xo(e) {
|
|
|
1357
1345
|
return !1;
|
|
1358
1346
|
for (; t < n; t++)
|
|
1359
1347
|
if (o = e[t], o !== "_") {
|
|
1360
|
-
if (!
|
|
1348
|
+
if (!Wo(e.charCodeAt(t)))
|
|
1361
1349
|
return !1;
|
|
1362
1350
|
r = !0;
|
|
1363
1351
|
}
|
|
1364
1352
|
return !(!r || o === "_");
|
|
1365
1353
|
}
|
|
1366
|
-
function
|
|
1354
|
+
function Qo(e) {
|
|
1367
1355
|
var n = e, t = 1, r;
|
|
1368
1356
|
if (n.indexOf("_") !== -1 && (n = n.replace(/_/g, "")), r = n[0], (r === "-" || r === "+") && (r === "-" && (t = -1), n = n.slice(1), r = n[0]), n === "0")
|
|
1369
1357
|
return 0;
|
|
@@ -1377,14 +1365,14 @@ function ea(e) {
|
|
|
1377
1365
|
}
|
|
1378
1366
|
return t * parseInt(n, 10);
|
|
1379
1367
|
}
|
|
1380
|
-
function
|
|
1368
|
+
function Xo(e) {
|
|
1381
1369
|
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 === 0 && !le.isNegativeZero(e);
|
|
1382
1370
|
}
|
|
1383
1371
|
var An = new pe("tag:yaml.org,2002:int", {
|
|
1384
1372
|
kind: "scalar",
|
|
1385
|
-
resolve:
|
|
1386
|
-
construct:
|
|
1387
|
-
predicate:
|
|
1373
|
+
resolve: Zo,
|
|
1374
|
+
construct: Qo,
|
|
1375
|
+
predicate: Xo,
|
|
1388
1376
|
represent: {
|
|
1389
1377
|
binary: function(e) {
|
|
1390
1378
|
return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1);
|
|
@@ -1407,21 +1395,21 @@ var An = new pe("tag:yaml.org,2002:int", {
|
|
|
1407
1395
|
decimal: [10, "dec"],
|
|
1408
1396
|
hexadecimal: [16, "hex"]
|
|
1409
1397
|
}
|
|
1410
|
-
}),
|
|
1398
|
+
}), ea = new RegExp(
|
|
1411
1399
|
// 2.5e4, 2.5 and integers
|
|
1412
1400
|
"^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"
|
|
1413
1401
|
);
|
|
1414
|
-
function
|
|
1415
|
-
return !(e === null || !
|
|
1402
|
+
function ta(e) {
|
|
1403
|
+
return !(e === null || !ea.test(e) || // Quick hack to not allow integers end with `_`
|
|
1416
1404
|
// Probably should update regexp & check speed
|
|
1417
1405
|
e[e.length - 1] === "_");
|
|
1418
1406
|
}
|
|
1419
|
-
function
|
|
1407
|
+
function na(e) {
|
|
1420
1408
|
var n, t;
|
|
1421
1409
|
return n = e.replace(/_/g, "").toLowerCase(), t = n[0] === "-" ? -1 : 1, "+-".indexOf(n[0]) >= 0 && (n = n.slice(1)), n === ".inf" ? t === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : n === ".nan" ? NaN : t * parseFloat(n, 10);
|
|
1422
1410
|
}
|
|
1423
|
-
var
|
|
1424
|
-
function
|
|
1411
|
+
var ra = /^[-+]?[0-9]+e/;
|
|
1412
|
+
function oa(e, n) {
|
|
1425
1413
|
var t;
|
|
1426
1414
|
if (isNaN(e))
|
|
1427
1415
|
switch (n) {
|
|
@@ -1452,17 +1440,17 @@ function ia(e, n) {
|
|
|
1452
1440
|
}
|
|
1453
1441
|
else if (le.isNegativeZero(e))
|
|
1454
1442
|
return "-0.0";
|
|
1455
|
-
return t = e.toString(10),
|
|
1443
|
+
return t = e.toString(10), ra.test(t) ? t.replace("e", ".e") : t;
|
|
1456
1444
|
}
|
|
1457
|
-
function
|
|
1445
|
+
function aa(e) {
|
|
1458
1446
|
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 !== 0 || le.isNegativeZero(e));
|
|
1459
1447
|
}
|
|
1460
1448
|
var Sn = new pe("tag:yaml.org,2002:float", {
|
|
1461
1449
|
kind: "scalar",
|
|
1462
|
-
resolve:
|
|
1463
|
-
construct:
|
|
1464
|
-
predicate:
|
|
1465
|
-
represent:
|
|
1450
|
+
resolve: ta,
|
|
1451
|
+
construct: na,
|
|
1452
|
+
predicate: aa,
|
|
1453
|
+
represent: oa,
|
|
1466
1454
|
defaultStyle: "lowercase"
|
|
1467
1455
|
}), Tn = wn.extend({
|
|
1468
1456
|
implicit: [
|
|
@@ -1471,17 +1459,17 @@ var Sn = new pe("tag:yaml.org,2002:float", {
|
|
|
1471
1459
|
An,
|
|
1472
1460
|
Sn
|
|
1473
1461
|
]
|
|
1474
|
-
}), $n = Tn,
|
|
1462
|
+
}), $n = Tn, Mn = new RegExp(
|
|
1475
1463
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1476
|
-
),
|
|
1464
|
+
), On = new RegExp(
|
|
1477
1465
|
"^([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]))?))?$"
|
|
1478
1466
|
);
|
|
1479
|
-
function
|
|
1480
|
-
return e === null ? !1 :
|
|
1467
|
+
function ia(e) {
|
|
1468
|
+
return e === null ? !1 : Mn.exec(e) !== null || On.exec(e) !== null;
|
|
1481
1469
|
}
|
|
1482
|
-
function
|
|
1483
|
-
var n, t, r, o, a, i, s, l = 0, c = null, d, u,
|
|
1484
|
-
if (n =
|
|
1470
|
+
function sa(e) {
|
|
1471
|
+
var n, t, r, o, a, i, s, l = 0, c = null, d, u, m;
|
|
1472
|
+
if (n = Mn.exec(e), n === null && (n = On.exec(e)), n === null)
|
|
1485
1473
|
throw new Error("Date resolve error");
|
|
1486
1474
|
if (t = +n[1], r = +n[2] - 1, o = +n[3], !n[4])
|
|
1487
1475
|
return new Date(Date.UTC(t, r, o));
|
|
@@ -1490,27 +1478,27 @@ function ua(e) {
|
|
|
1490
1478
|
l += "0";
|
|
1491
1479
|
l = +l;
|
|
1492
1480
|
}
|
|
1493
|
-
return n[9] && (d = +n[10], u = +(n[11] || 0), c = (d * 60 + u) * 6e4, n[9] === "-" && (c = -c)),
|
|
1481
|
+
return n[9] && (d = +n[10], u = +(n[11] || 0), c = (d * 60 + u) * 6e4, n[9] === "-" && (c = -c)), m = new Date(Date.UTC(t, r, o, a, i, s, l)), c && m.setTime(m.getTime() - c), m;
|
|
1494
1482
|
}
|
|
1495
|
-
function
|
|
1483
|
+
function la(e) {
|
|
1496
1484
|
return e.toISOString();
|
|
1497
1485
|
}
|
|
1498
1486
|
var En = new pe("tag:yaml.org,2002:timestamp", {
|
|
1499
1487
|
kind: "scalar",
|
|
1500
|
-
resolve:
|
|
1501
|
-
construct:
|
|
1488
|
+
resolve: ia,
|
|
1489
|
+
construct: sa,
|
|
1502
1490
|
instanceOf: Date,
|
|
1503
|
-
represent:
|
|
1491
|
+
represent: la
|
|
1504
1492
|
});
|
|
1505
|
-
function
|
|
1493
|
+
function ua(e) {
|
|
1506
1494
|
return e === "<<" || e === null;
|
|
1507
1495
|
}
|
|
1508
|
-
var
|
|
1496
|
+
var jn = new pe("tag:yaml.org,2002:merge", {
|
|
1509
1497
|
kind: "scalar",
|
|
1510
|
-
resolve:
|
|
1498
|
+
resolve: ua
|
|
1511
1499
|
}), Tt = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
1512
1500
|
\r`;
|
|
1513
|
-
function
|
|
1501
|
+
function ca(e) {
|
|
1514
1502
|
if (e === null)
|
|
1515
1503
|
return !1;
|
|
1516
1504
|
var n, t, r = 0, o = e.length, a = Tt;
|
|
@@ -1522,37 +1510,37 @@ function pa(e) {
|
|
|
1522
1510
|
}
|
|
1523
1511
|
return r % 8 === 0;
|
|
1524
1512
|
}
|
|
1525
|
-
function
|
|
1513
|
+
function da(e) {
|
|
1526
1514
|
var n, t, r = e.replace(/[\r\n=]/g, ""), o = r.length, a = Tt, i = 0, s = [];
|
|
1527
1515
|
for (n = 0; n < o; n++)
|
|
1528
1516
|
n % 4 === 0 && n && (s.push(i >> 16 & 255), s.push(i >> 8 & 255), s.push(i & 255)), i = i << 6 | a.indexOf(r.charAt(n));
|
|
1529
1517
|
return t = o % 4 * 6, t === 0 ? (s.push(i >> 16 & 255), s.push(i >> 8 & 255), s.push(i & 255)) : t === 18 ? (s.push(i >> 10 & 255), s.push(i >> 2 & 255)) : t === 12 && s.push(i >> 4 & 255), new Uint8Array(s);
|
|
1530
1518
|
}
|
|
1531
|
-
function
|
|
1519
|
+
function pa(e) {
|
|
1532
1520
|
var n = "", t = 0, r, o, a = e.length, i = Tt;
|
|
1533
1521
|
for (r = 0; r < a; r++)
|
|
1534
1522
|
r % 3 === 0 && r && (n += i[t >> 18 & 63], n += i[t >> 12 & 63], n += i[t >> 6 & 63], n += i[t & 63]), t = (t << 8) + e[r];
|
|
1535
1523
|
return o = a % 3, o === 0 ? (n += i[t >> 18 & 63], n += i[t >> 12 & 63], n += i[t >> 6 & 63], n += i[t & 63]) : o === 2 ? (n += i[t >> 10 & 63], n += i[t >> 4 & 63], n += i[t << 2 & 63], n += i[64]) : o === 1 && (n += i[t >> 2 & 63], n += i[t << 4 & 63], n += i[64], n += i[64]), n;
|
|
1536
1524
|
}
|
|
1537
|
-
function
|
|
1525
|
+
function fa(e) {
|
|
1538
1526
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1539
1527
|
}
|
|
1540
1528
|
var Fn = new pe("tag:yaml.org,2002:binary", {
|
|
1541
1529
|
kind: "scalar",
|
|
1542
|
-
resolve:
|
|
1543
|
-
construct:
|
|
1544
|
-
predicate:
|
|
1545
|
-
represent:
|
|
1546
|
-
}),
|
|
1547
|
-
function
|
|
1530
|
+
resolve: ca,
|
|
1531
|
+
construct: da,
|
|
1532
|
+
predicate: fa,
|
|
1533
|
+
represent: pa
|
|
1534
|
+
}), ma = Object.prototype.hasOwnProperty, ga = Object.prototype.toString;
|
|
1535
|
+
function ya(e) {
|
|
1548
1536
|
if (e === null)
|
|
1549
1537
|
return !0;
|
|
1550
1538
|
var n = [], t, r, o, a, i, s = e;
|
|
1551
1539
|
for (t = 0, r = s.length; t < r; t += 1) {
|
|
1552
|
-
if (o = s[t], i = !1,
|
|
1540
|
+
if (o = s[t], i = !1, ga.call(o) !== "[object Object]")
|
|
1553
1541
|
return !1;
|
|
1554
1542
|
for (a in o)
|
|
1555
|
-
if (
|
|
1543
|
+
if (ma.call(o, a))
|
|
1556
1544
|
if (!i)
|
|
1557
1545
|
i = !0;
|
|
1558
1546
|
else
|
|
@@ -1566,26 +1554,26 @@ function va(e) {
|
|
|
1566
1554
|
}
|
|
1567
1555
|
return !0;
|
|
1568
1556
|
}
|
|
1569
|
-
function
|
|
1557
|
+
function ha(e) {
|
|
1570
1558
|
return e !== null ? e : [];
|
|
1571
1559
|
}
|
|
1572
|
-
var
|
|
1560
|
+
var Kn = new pe("tag:yaml.org,2002:omap", {
|
|
1573
1561
|
kind: "sequence",
|
|
1574
|
-
resolve:
|
|
1575
|
-
construct:
|
|
1576
|
-
}),
|
|
1577
|
-
function
|
|
1562
|
+
resolve: ya,
|
|
1563
|
+
construct: ha
|
|
1564
|
+
}), va = Object.prototype.toString;
|
|
1565
|
+
function ba(e) {
|
|
1578
1566
|
if (e === null)
|
|
1579
1567
|
return !0;
|
|
1580
1568
|
var n, t, r, o, a, i = e;
|
|
1581
1569
|
for (a = new Array(i.length), n = 0, t = i.length; n < t; n += 1) {
|
|
1582
|
-
if (r = i[n],
|
|
1570
|
+
if (r = i[n], va.call(r) !== "[object Object]" || (o = Object.keys(r), o.length !== 1))
|
|
1583
1571
|
return !1;
|
|
1584
1572
|
a[n] = [o[0], r[o[0]]];
|
|
1585
1573
|
}
|
|
1586
1574
|
return !0;
|
|
1587
1575
|
}
|
|
1588
|
-
function
|
|
1576
|
+
function Ca(e) {
|
|
1589
1577
|
if (e === null)
|
|
1590
1578
|
return [];
|
|
1591
1579
|
var n, t, r, o, a, i = e;
|
|
@@ -1593,40 +1581,40 @@ function _a(e) {
|
|
|
1593
1581
|
r = i[n], o = Object.keys(r), a[n] = [o[0], r[o[0]]];
|
|
1594
1582
|
return a;
|
|
1595
1583
|
}
|
|
1596
|
-
var
|
|
1584
|
+
var Bn = new pe("tag:yaml.org,2002:pairs", {
|
|
1597
1585
|
kind: "sequence",
|
|
1598
|
-
resolve:
|
|
1599
|
-
construct:
|
|
1600
|
-
}),
|
|
1601
|
-
function
|
|
1586
|
+
resolve: ba,
|
|
1587
|
+
construct: Ca
|
|
1588
|
+
}), ka = Object.prototype.hasOwnProperty;
|
|
1589
|
+
function _a(e) {
|
|
1602
1590
|
if (e === null)
|
|
1603
1591
|
return !0;
|
|
1604
1592
|
var n, t = e;
|
|
1605
1593
|
for (n in t)
|
|
1606
|
-
if (
|
|
1594
|
+
if (ka.call(t, n) && t[n] !== null)
|
|
1607
1595
|
return !1;
|
|
1608
1596
|
return !0;
|
|
1609
1597
|
}
|
|
1610
|
-
function
|
|
1598
|
+
function wa(e) {
|
|
1611
1599
|
return e !== null ? e : {};
|
|
1612
1600
|
}
|
|
1613
1601
|
var Nn = new pe("tag:yaml.org,2002:set", {
|
|
1614
1602
|
kind: "mapping",
|
|
1615
|
-
resolve:
|
|
1616
|
-
construct:
|
|
1603
|
+
resolve: _a,
|
|
1604
|
+
construct: wa
|
|
1617
1605
|
}), $t = $n.extend({
|
|
1618
1606
|
implicit: [
|
|
1619
1607
|
En,
|
|
1620
|
-
|
|
1608
|
+
jn
|
|
1621
1609
|
],
|
|
1622
1610
|
explicit: [
|
|
1623
1611
|
Fn,
|
|
1624
|
-
Bn,
|
|
1625
1612
|
Kn,
|
|
1613
|
+
Bn,
|
|
1626
1614
|
Nn
|
|
1627
1615
|
]
|
|
1628
|
-
}),
|
|
1629
|
-
function
|
|
1616
|
+
}), Me = Object.prototype.hasOwnProperty, ot = 1, Ln = 2, qn = 3, at = 4, yt = 1, Ia = 2, zt = 3, xa = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Aa = /[\x85\u2028\u2029]/, Sa = /[,\[\]\{\}]/, Pn = /^(?:!|!!|![a-z\-]+!)$/i, Un = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1617
|
+
function Yt(e) {
|
|
1630
1618
|
return Object.prototype.toString.call(e);
|
|
1631
1619
|
}
|
|
1632
1620
|
function we(e) {
|
|
@@ -1638,20 +1626,20 @@ function Fe(e) {
|
|
|
1638
1626
|
function he(e) {
|
|
1639
1627
|
return e === 9 || e === 32 || e === 10 || e === 13;
|
|
1640
1628
|
}
|
|
1641
|
-
function
|
|
1629
|
+
function Pe(e) {
|
|
1642
1630
|
return e === 44 || e === 91 || e === 93 || e === 123 || e === 125;
|
|
1643
1631
|
}
|
|
1644
|
-
function
|
|
1632
|
+
function Ta(e) {
|
|
1645
1633
|
var n;
|
|
1646
1634
|
return 48 <= e && e <= 57 ? e - 48 : (n = e | 32, 97 <= n && n <= 102 ? n - 97 + 10 : -1);
|
|
1647
1635
|
}
|
|
1648
|
-
function
|
|
1636
|
+
function $a(e) {
|
|
1649
1637
|
return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0;
|
|
1650
1638
|
}
|
|
1651
|
-
function
|
|
1639
|
+
function Ma(e) {
|
|
1652
1640
|
return 48 <= e && e <= 57 ? e - 48 : -1;
|
|
1653
1641
|
}
|
|
1654
|
-
function
|
|
1642
|
+
function Jt(e) {
|
|
1655
1643
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? `
|
|
1656
1644
|
` : 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" : "";
|
|
1657
1645
|
}
|
|
@@ -1661,10 +1649,10 @@ function Oa(e) {
|
|
|
1661
1649
|
(e - 65536 & 1023) + 56320
|
|
1662
1650
|
);
|
|
1663
1651
|
}
|
|
1664
|
-
var
|
|
1665
|
-
for (var
|
|
1666
|
-
|
|
1667
|
-
function
|
|
1652
|
+
var Rn = new Array(256), Vn = new Array(256);
|
|
1653
|
+
for (var Le = 0; Le < 256; Le++)
|
|
1654
|
+
Rn[Le] = Jt(Le) ? 1 : 0, Vn[Le] = Jt(Le);
|
|
1655
|
+
function Ea(e, n) {
|
|
1668
1656
|
this.input = e, this.filename = n.filename || null, this.schema = n.schema || $t, 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 = [];
|
|
1669
1657
|
}
|
|
1670
1658
|
function Dn(e, n) {
|
|
@@ -1676,7 +1664,7 @@ function Dn(e, n) {
|
|
|
1676
1664
|
line: e.line,
|
|
1677
1665
|
column: e.position - e.lineStart
|
|
1678
1666
|
};
|
|
1679
|
-
return t.snippet =
|
|
1667
|
+
return t.snippet = Bo(t), new me(n, t);
|
|
1680
1668
|
}
|
|
1681
1669
|
function S(e, n) {
|
|
1682
1670
|
throw Dn(e, n);
|
|
@@ -1691,7 +1679,7 @@ var Wt = {
|
|
|
1691
1679
|
},
|
|
1692
1680
|
TAG: function(e, n, t) {
|
|
1693
1681
|
var r, o;
|
|
1694
|
-
t.length !== 2 && S(e, "TAG directive accepts exactly two arguments"), r = t[0], o = t[1],
|
|
1682
|
+
t.length !== 2 && S(e, "TAG directive accepts exactly two arguments"), r = t[0], o = t[1], Pn.test(r) || S(e, "ill-formed tag handle (first argument) of the TAG directive"), Me.call(e.tagMap, r) && S(e, 'there is a previously declared suffix for "' + r + '" tag handle'), Un.test(o) || S(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1695
1683
|
try {
|
|
1696
1684
|
o = decodeURIComponent(o);
|
|
1697
1685
|
} catch {
|
|
@@ -1707,28 +1695,28 @@ function $e(e, n, t, r) {
|
|
|
1707
1695
|
for (o = 0, a = s.length; o < a; o += 1)
|
|
1708
1696
|
i = s.charCodeAt(o), i === 9 || 32 <= i && i <= 1114111 || S(e, "expected valid JSON character");
|
|
1709
1697
|
else
|
|
1710
|
-
|
|
1698
|
+
xa.test(s) && S(e, "the stream contains non-printable characters");
|
|
1711
1699
|
e.result += s;
|
|
1712
1700
|
}
|
|
1713
1701
|
}
|
|
1714
1702
|
function Zt(e, n, t, r) {
|
|
1715
1703
|
var o, a, i, s;
|
|
1716
1704
|
for (le.isObject(t) || S(e, "cannot merge mappings; the provided source object is unacceptable"), o = Object.keys(t), i = 0, s = o.length; i < s; i += 1)
|
|
1717
|
-
a = o[i],
|
|
1705
|
+
a = o[i], Me.call(n, a) || (n[a] = t[a], r[a] = !0);
|
|
1718
1706
|
}
|
|
1719
|
-
function
|
|
1707
|
+
function Ue(e, n, t, r, o, a, i, s, l) {
|
|
1720
1708
|
var c, d;
|
|
1721
1709
|
if (Array.isArray(o))
|
|
1722
1710
|
for (o = Array.prototype.slice.call(o), c = 0, d = o.length; c < d; c += 1)
|
|
1723
|
-
Array.isArray(o[c]) && S(e, "nested arrays are not supported inside keys"), typeof o == "object" &&
|
|
1724
|
-
if (typeof o == "object" &&
|
|
1711
|
+
Array.isArray(o[c]) && S(e, "nested arrays are not supported inside keys"), typeof o == "object" && Yt(o[c]) === "[object Object]" && (o[c] = "[object Object]");
|
|
1712
|
+
if (typeof o == "object" && Yt(o) === "[object Object]" && (o = "[object Object]"), o = String(o), n === null && (n = {}), r === "tag:yaml.org,2002:merge")
|
|
1725
1713
|
if (Array.isArray(a))
|
|
1726
1714
|
for (c = 0, d = a.length; c < d; c += 1)
|
|
1727
1715
|
Zt(e, n, a[c], t);
|
|
1728
1716
|
else
|
|
1729
1717
|
Zt(e, n, a, t);
|
|
1730
1718
|
else
|
|
1731
|
-
!e.json && !
|
|
1719
|
+
!e.json && !Me.call(t, o) && Me.call(n, o) && (e.line = i || e.line, e.lineStart = s || e.lineStart, e.position = l || e.position, S(e, "duplicated mapping key")), o === "__proto__" ? Object.defineProperty(n, o, {
|
|
1732
1720
|
configurable: !0,
|
|
1733
1721
|
enumerable: !0,
|
|
1734
1722
|
writable: !0,
|
|
@@ -1736,7 +1724,7 @@ function Le(e, n, t, r, o, a, i, s, l) {
|
|
|
1736
1724
|
}) : n[o] = a, delete t[o];
|
|
1737
1725
|
return n;
|
|
1738
1726
|
}
|
|
1739
|
-
function
|
|
1727
|
+
function Mt(e) {
|
|
1740
1728
|
var n;
|
|
1741
1729
|
n = e.input.charCodeAt(e.position), n === 10 ? e.position++ : n === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : S(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1;
|
|
1742
1730
|
}
|
|
@@ -1749,7 +1737,7 @@ function ae(e, n, t) {
|
|
|
1749
1737
|
o = e.input.charCodeAt(++e.position);
|
|
1750
1738
|
while (o !== 10 && o !== 13 && o !== 0);
|
|
1751
1739
|
if (we(o))
|
|
1752
|
-
for (
|
|
1740
|
+
for (Mt(e), o = e.input.charCodeAt(e.position), r++, e.lineIndent = 0; o === 32; )
|
|
1753
1741
|
e.lineIndent++, o = e.input.charCodeAt(++e.position);
|
|
1754
1742
|
else
|
|
1755
1743
|
break;
|
|
@@ -1760,38 +1748,38 @@ function dt(e) {
|
|
|
1760
1748
|
var n = e.position, t;
|
|
1761
1749
|
return t = e.input.charCodeAt(n), !!((t === 45 || t === 46) && t === e.input.charCodeAt(n + 1) && t === e.input.charCodeAt(n + 2) && (n += 3, t = e.input.charCodeAt(n), t === 0 || he(t)));
|
|
1762
1750
|
}
|
|
1763
|
-
function
|
|
1751
|
+
function Ot(e, n) {
|
|
1764
1752
|
n === 1 ? e.result += " " : n > 1 && (e.result += le.repeat(`
|
|
1765
1753
|
`, n - 1));
|
|
1766
1754
|
}
|
|
1767
|
-
function
|
|
1768
|
-
var r, o, a, i, s, l, c, d, u = e.kind,
|
|
1769
|
-
if (
|
|
1755
|
+
function ja(e, n, t) {
|
|
1756
|
+
var r, o, a, i, s, l, c, d, u = e.kind, m = e.result, g;
|
|
1757
|
+
if (g = e.input.charCodeAt(e.position), he(g) || Pe(g) || g === 35 || g === 38 || g === 42 || g === 33 || g === 124 || g === 62 || g === 39 || g === 34 || g === 37 || g === 64 || g === 96 || (g === 63 || g === 45) && (o = e.input.charCodeAt(e.position + 1), he(o) || t && Pe(o)))
|
|
1770
1758
|
return !1;
|
|
1771
|
-
for (e.kind = "scalar", e.result = "", a = i = e.position, s = !1;
|
|
1772
|
-
if (
|
|
1773
|
-
if (o = e.input.charCodeAt(e.position + 1), he(o) || t &&
|
|
1759
|
+
for (e.kind = "scalar", e.result = "", a = i = e.position, s = !1; g !== 0; ) {
|
|
1760
|
+
if (g === 58) {
|
|
1761
|
+
if (o = e.input.charCodeAt(e.position + 1), he(o) || t && Pe(o))
|
|
1774
1762
|
break;
|
|
1775
|
-
} else if (
|
|
1763
|
+
} else if (g === 35) {
|
|
1776
1764
|
if (r = e.input.charCodeAt(e.position - 1), he(r))
|
|
1777
1765
|
break;
|
|
1778
1766
|
} else {
|
|
1779
|
-
if (e.position === e.lineStart && dt(e) || t &&
|
|
1767
|
+
if (e.position === e.lineStart && dt(e) || t && Pe(g))
|
|
1780
1768
|
break;
|
|
1781
|
-
if (we(
|
|
1769
|
+
if (we(g))
|
|
1782
1770
|
if (l = e.line, c = e.lineStart, d = e.lineIndent, ae(e, !1, -1), e.lineIndent >= n) {
|
|
1783
|
-
s = !0,
|
|
1771
|
+
s = !0, g = e.input.charCodeAt(e.position);
|
|
1784
1772
|
continue;
|
|
1785
1773
|
} else {
|
|
1786
1774
|
e.position = i, e.line = l, e.lineStart = c, e.lineIndent = d;
|
|
1787
1775
|
break;
|
|
1788
1776
|
}
|
|
1789
1777
|
}
|
|
1790
|
-
s && ($e(e, a, i, !1),
|
|
1778
|
+
s && ($e(e, a, i, !1), Ot(e, e.line - l), a = i = e.position, s = !1), Fe(g) || (i = e.position + 1), g = e.input.charCodeAt(++e.position);
|
|
1791
1779
|
}
|
|
1792
|
-
return $e(e, a, i, !1), e.result ? !0 : (e.kind = u, e.result =
|
|
1780
|
+
return $e(e, a, i, !1), e.result ? !0 : (e.kind = u, e.result = m, !1);
|
|
1793
1781
|
}
|
|
1794
|
-
function
|
|
1782
|
+
function Fa(e, n) {
|
|
1795
1783
|
var t, r, o;
|
|
1796
1784
|
if (t = e.input.charCodeAt(e.position), t !== 39)
|
|
1797
1785
|
return !1;
|
|
@@ -1802,10 +1790,10 @@ function Ka(e, n) {
|
|
|
1802
1790
|
else
|
|
1803
1791
|
return !0;
|
|
1804
1792
|
else
|
|
1805
|
-
we(t) ? ($e(e, r, o, !0),
|
|
1793
|
+
we(t) ? ($e(e, r, o, !0), Ot(e, ae(e, !1, n)), r = o = e.position) : e.position === e.lineStart && dt(e) ? S(e, "unexpected end of the document within a single quoted scalar") : (e.position++, o = e.position);
|
|
1806
1794
|
S(e, "unexpected end of the stream within a single quoted scalar");
|
|
1807
1795
|
}
|
|
1808
|
-
function
|
|
1796
|
+
function Ka(e, n) {
|
|
1809
1797
|
var t, r, o, a, i, s;
|
|
1810
1798
|
if (s = e.input.charCodeAt(e.position), s !== 34)
|
|
1811
1799
|
return !1;
|
|
@@ -1815,36 +1803,36 @@ function Na(e, n) {
|
|
|
1815
1803
|
if (s === 92) {
|
|
1816
1804
|
if ($e(e, t, e.position, !0), s = e.input.charCodeAt(++e.position), we(s))
|
|
1817
1805
|
ae(e, !1, n);
|
|
1818
|
-
else if (s < 256 &&
|
|
1819
|
-
e.result +=
|
|
1820
|
-
else if ((i =
|
|
1806
|
+
else if (s < 256 && Rn[s])
|
|
1807
|
+
e.result += Vn[s], e.position++;
|
|
1808
|
+
else if ((i = $a(s)) > 0) {
|
|
1821
1809
|
for (o = i, a = 0; o > 0; o--)
|
|
1822
|
-
s = e.input.charCodeAt(++e.position), (i =
|
|
1810
|
+
s = e.input.charCodeAt(++e.position), (i = Ta(s)) >= 0 ? a = (a << 4) + i : S(e, "expected hexadecimal character");
|
|
1823
1811
|
e.result += Oa(a), e.position++;
|
|
1824
1812
|
} else
|
|
1825
1813
|
S(e, "unknown escape sequence");
|
|
1826
1814
|
t = r = e.position;
|
|
1827
1815
|
} else
|
|
1828
|
-
we(s) ? ($e(e, t, r, !0),
|
|
1816
|
+
we(s) ? ($e(e, t, r, !0), Ot(e, ae(e, !1, n)), t = r = e.position) : e.position === e.lineStart && dt(e) ? S(e, "unexpected end of the document within a double quoted scalar") : (e.position++, r = e.position);
|
|
1829
1817
|
}
|
|
1830
1818
|
S(e, "unexpected end of the stream within a double quoted scalar");
|
|
1831
1819
|
}
|
|
1832
|
-
function
|
|
1833
|
-
var t = !0, r, o, a, i = e.tag, s, l = e.anchor, c, d, u,
|
|
1820
|
+
function Ba(e, n) {
|
|
1821
|
+
var t = !0, r, o, a, i = e.tag, s, l = e.anchor, c, d, u, m, g, k = /* @__PURE__ */ Object.create(null), _, p, C, y;
|
|
1834
1822
|
if (y = e.input.charCodeAt(e.position), y === 91)
|
|
1835
|
-
d = 93,
|
|
1823
|
+
d = 93, g = !1, s = [];
|
|
1836
1824
|
else if (y === 123)
|
|
1837
|
-
d = 125,
|
|
1825
|
+
d = 125, g = !0, s = {};
|
|
1838
1826
|
else
|
|
1839
1827
|
return !1;
|
|
1840
1828
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), y = e.input.charCodeAt(++e.position); y !== 0; ) {
|
|
1841
1829
|
if (ae(e, !0, n), y = e.input.charCodeAt(e.position), y === d)
|
|
1842
|
-
return e.position++, e.tag = i, e.anchor = l, e.kind =
|
|
1843
|
-
t ? y === 44 && S(e, "expected the node content, but found ','") : S(e, "missed comma between flow collection entries"), p = _ =
|
|
1830
|
+
return e.position++, e.tag = i, e.anchor = l, e.kind = g ? "mapping" : "sequence", e.result = s, !0;
|
|
1831
|
+
t ? y === 44 && S(e, "expected the node content, but found ','") : S(e, "missed comma between flow collection entries"), p = _ = C = null, u = m = !1, y === 63 && (c = e.input.charCodeAt(e.position + 1), he(c) && (u = m = !0, e.position++, ae(e, !0, n))), r = e.line, o = e.lineStart, a = e.position, Re(e, n, ot, !1, !0), p = e.tag, _ = e.result, ae(e, !0, n), y = e.input.charCodeAt(e.position), (m || e.line === r) && y === 58 && (u = !0, y = e.input.charCodeAt(++e.position), ae(e, !0, n), Re(e, n, ot, !1, !0), C = e.result), g ? Ue(e, s, k, p, _, C, r, o, a) : u ? s.push(Ue(e, null, k, p, _, C, r, o, a)) : s.push(_), ae(e, !0, n), y = e.input.charCodeAt(e.position), y === 44 ? (t = !0, y = e.input.charCodeAt(++e.position)) : t = !1;
|
|
1844
1832
|
}
|
|
1845
1833
|
S(e, "unexpected end of the stream within a flow collection");
|
|
1846
1834
|
}
|
|
1847
|
-
function
|
|
1835
|
+
function Na(e, n) {
|
|
1848
1836
|
var t, r, o = yt, a = !1, i = !1, s = n, l = 0, c = !1, d, u;
|
|
1849
1837
|
if (u = e.input.charCodeAt(e.position), u === 124)
|
|
1850
1838
|
r = !1;
|
|
@@ -1854,8 +1842,8 @@ function qa(e, n) {
|
|
|
1854
1842
|
return !1;
|
|
1855
1843
|
for (e.kind = "scalar", e.result = ""; u !== 0; )
|
|
1856
1844
|
if (u = e.input.charCodeAt(++e.position), u === 43 || u === 45)
|
|
1857
|
-
yt === o ? o = u === 43 ? zt :
|
|
1858
|
-
else if ((d =
|
|
1845
|
+
yt === o ? o = u === 43 ? zt : Ia : S(e, "repeat of a chomping mode identifier");
|
|
1846
|
+
else if ((d = Ma(u)) >= 0)
|
|
1859
1847
|
d === 0 ? S(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : i ? S(e, "repeat of an indentation width identifier") : (s = n + d - 1, i = !0);
|
|
1860
1848
|
else
|
|
1861
1849
|
break;
|
|
@@ -1869,7 +1857,7 @@ function qa(e, n) {
|
|
|
1869
1857
|
while (!we(u) && u !== 0);
|
|
1870
1858
|
}
|
|
1871
1859
|
for (; u !== 0; ) {
|
|
1872
|
-
for (
|
|
1860
|
+
for (Mt(e), e.lineIndent = 0, u = e.input.charCodeAt(e.position); (!i || e.lineIndent < s) && u === 32; )
|
|
1873
1861
|
e.lineIndent++, u = e.input.charCodeAt(++e.position);
|
|
1874
1862
|
if (!i && e.lineIndent > s && (s = e.lineIndent), we(u)) {
|
|
1875
1863
|
l++;
|
|
@@ -1900,7 +1888,7 @@ function Qt(e, n) {
|
|
|
1900
1888
|
a.push(null), l = e.input.charCodeAt(e.position);
|
|
1901
1889
|
continue;
|
|
1902
1890
|
}
|
|
1903
|
-
if (t = e.line,
|
|
1891
|
+
if (t = e.line, Re(e, n, qn, !1, !0), a.push(e.result), ae(e, !0, -1), l = e.input.charCodeAt(e.position), (e.line === t || e.lineIndent > n) && l !== 0)
|
|
1904
1892
|
S(e, "bad indentation of a sequence entry");
|
|
1905
1893
|
else if (e.lineIndent < n)
|
|
1906
1894
|
break;
|
|
@@ -1908,37 +1896,37 @@ function Qt(e, n) {
|
|
|
1908
1896
|
return s ? (e.tag = r, e.anchor = o, e.kind = "sequence", e.result = a, !0) : !1;
|
|
1909
1897
|
}
|
|
1910
1898
|
function La(e, n, t) {
|
|
1911
|
-
var r, o, a, i, s, l, c = e.tag, d = e.anchor, u = {},
|
|
1899
|
+
var r, o, a, i, s, l, c = e.tag, d = e.anchor, u = {}, m = /* @__PURE__ */ Object.create(null), g = null, k = null, _ = null, p = !1, C = !1, y;
|
|
1912
1900
|
if (e.firstTabInLine !== -1)
|
|
1913
1901
|
return !1;
|
|
1914
1902
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = u), y = e.input.charCodeAt(e.position); y !== 0; ) {
|
|
1915
1903
|
if (!p && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, S(e, "tab characters must not be used in indentation")), r = e.input.charCodeAt(e.position + 1), a = e.line, (y === 63 || y === 58) && he(r))
|
|
1916
|
-
y === 63 ? (p && (
|
|
1904
|
+
y === 63 ? (p && (Ue(e, u, m, g, k, null, i, s, l), g = k = _ = null), C = !0, p = !0, o = !0) : p ? (p = !1, o = !0) : S(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, y = r;
|
|
1917
1905
|
else {
|
|
1918
|
-
if (i = e.line, s = e.lineStart, l = e.position, !
|
|
1906
|
+
if (i = e.line, s = e.lineStart, l = e.position, !Re(e, t, Ln, !1, !0))
|
|
1919
1907
|
break;
|
|
1920
1908
|
if (e.line === a) {
|
|
1921
1909
|
for (y = e.input.charCodeAt(e.position); Fe(y); )
|
|
1922
1910
|
y = e.input.charCodeAt(++e.position);
|
|
1923
1911
|
if (y === 58)
|
|
1924
|
-
y = e.input.charCodeAt(++e.position), he(y) || S(e, "a whitespace character is expected after the key-value separator within a block mapping"), p && (
|
|
1925
|
-
else if (
|
|
1912
|
+
y = e.input.charCodeAt(++e.position), he(y) || S(e, "a whitespace character is expected after the key-value separator within a block mapping"), p && (Ue(e, u, m, g, k, null, i, s, l), g = k = _ = null), C = !0, p = !1, o = !1, g = e.tag, k = e.result;
|
|
1913
|
+
else if (C)
|
|
1926
1914
|
S(e, "can not read an implicit mapping pair; a colon is missed");
|
|
1927
1915
|
else
|
|
1928
1916
|
return e.tag = c, e.anchor = d, !0;
|
|
1929
|
-
} else if (
|
|
1917
|
+
} else if (C)
|
|
1930
1918
|
S(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
1931
1919
|
else
|
|
1932
1920
|
return e.tag = c, e.anchor = d, !0;
|
|
1933
1921
|
}
|
|
1934
|
-
if ((e.line === a || e.lineIndent > n) && (p && (i = e.line, s = e.lineStart, l = e.position),
|
|
1922
|
+
if ((e.line === a || e.lineIndent > n) && (p && (i = e.line, s = e.lineStart, l = e.position), Re(e, n, at, !0, o) && (p ? k = e.result : _ = e.result), p || (Ue(e, u, m, g, k, _, i, s, l), g = k = _ = null), ae(e, !0, -1), y = e.input.charCodeAt(e.position)), (e.line === a || e.lineIndent > n) && y !== 0)
|
|
1935
1923
|
S(e, "bad indentation of a mapping entry");
|
|
1936
1924
|
else if (e.lineIndent < n)
|
|
1937
1925
|
break;
|
|
1938
1926
|
}
|
|
1939
|
-
return p &&
|
|
1927
|
+
return p && Ue(e, u, m, g, k, null, i, s, l), C && (e.tag = c, e.anchor = d, e.kind = "mapping", e.result = u), C;
|
|
1940
1928
|
}
|
|
1941
|
-
function
|
|
1929
|
+
function qa(e) {
|
|
1942
1930
|
var n, t = !1, r = !1, o, a, i;
|
|
1943
1931
|
if (i = e.input.charCodeAt(e.position), i !== 33)
|
|
1944
1932
|
return !1;
|
|
@@ -1949,60 +1937,60 @@ function Va(e) {
|
|
|
1949
1937
|
e.position < e.length ? (a = e.input.slice(n, e.position), i = e.input.charCodeAt(++e.position)) : S(e, "unexpected end of the stream within a verbatim tag");
|
|
1950
1938
|
} else {
|
|
1951
1939
|
for (; i !== 0 && !he(i); )
|
|
1952
|
-
i === 33 && (r ? S(e, "tag suffix cannot contain exclamation marks") : (o = e.input.slice(n - 1, e.position + 1),
|
|
1953
|
-
a = e.input.slice(n, e.position),
|
|
1940
|
+
i === 33 && (r ? S(e, "tag suffix cannot contain exclamation marks") : (o = e.input.slice(n - 1, e.position + 1), Pn.test(o) || S(e, "named tag handle cannot contain such characters"), r = !0, n = e.position + 1)), i = e.input.charCodeAt(++e.position);
|
|
1941
|
+
a = e.input.slice(n, e.position), Sa.test(a) && S(e, "tag suffix cannot contain flow indicator characters");
|
|
1954
1942
|
}
|
|
1955
|
-
a && !
|
|
1943
|
+
a && !Un.test(a) && S(e, "tag name cannot contain such characters: " + a);
|
|
1956
1944
|
try {
|
|
1957
1945
|
a = decodeURIComponent(a);
|
|
1958
1946
|
} catch {
|
|
1959
1947
|
S(e, "tag name is malformed: " + a);
|
|
1960
1948
|
}
|
|
1961
|
-
return t ? e.tag = a :
|
|
1949
|
+
return t ? e.tag = a : Me.call(e.tagMap, o) ? e.tag = e.tagMap[o] + a : o === "!" ? e.tag = "!" + a : o === "!!" ? e.tag = "tag:yaml.org,2002:" + a : S(e, 'undeclared tag handle "' + o + '"'), !0;
|
|
1962
1950
|
}
|
|
1963
|
-
function
|
|
1951
|
+
function Pa(e) {
|
|
1964
1952
|
var n, t;
|
|
1965
1953
|
if (t = e.input.charCodeAt(e.position), t !== 38)
|
|
1966
1954
|
return !1;
|
|
1967
|
-
for (e.anchor !== null && S(e, "duplication of an anchor property"), t = e.input.charCodeAt(++e.position), n = e.position; t !== 0 && !he(t) && !
|
|
1955
|
+
for (e.anchor !== null && S(e, "duplication of an anchor property"), t = e.input.charCodeAt(++e.position), n = e.position; t !== 0 && !he(t) && !Pe(t); )
|
|
1968
1956
|
t = e.input.charCodeAt(++e.position);
|
|
1969
1957
|
return e.position === n && S(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(n, e.position), !0;
|
|
1970
1958
|
}
|
|
1971
|
-
function
|
|
1959
|
+
function Ua(e) {
|
|
1972
1960
|
var n, t, r;
|
|
1973
1961
|
if (r = e.input.charCodeAt(e.position), r !== 42)
|
|
1974
1962
|
return !1;
|
|
1975
|
-
for (r = e.input.charCodeAt(++e.position), n = e.position; r !== 0 && !he(r) && !
|
|
1963
|
+
for (r = e.input.charCodeAt(++e.position), n = e.position; r !== 0 && !he(r) && !Pe(r); )
|
|
1976
1964
|
r = e.input.charCodeAt(++e.position);
|
|
1977
|
-
return e.position === n && S(e, "name of an alias node must contain at least one character"), t = e.input.slice(n, e.position),
|
|
1965
|
+
return e.position === n && S(e, "name of an alias node must contain at least one character"), t = e.input.slice(n, e.position), Me.call(e.anchorMap, t) || S(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], ae(e, !0, -1), !0;
|
|
1978
1966
|
}
|
|
1979
|
-
function
|
|
1980
|
-
var a, i, s, l = 1, c = !1, d = !1, u,
|
|
1967
|
+
function Re(e, n, t, r, o) {
|
|
1968
|
+
var a, i, s, l = 1, c = !1, d = !1, u, m, g, k, _, p;
|
|
1981
1969
|
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, a = i = s = at === t || qn === t, r && ae(e, !0, -1) && (c = !0, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)), l === 1)
|
|
1982
|
-
for (;
|
|
1970
|
+
for (; qa(e) || Pa(e); )
|
|
1983
1971
|
ae(e, !0, -1) ? (c = !0, s = a, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)) : s = !1;
|
|
1984
|
-
if (s && (s = c || o), (l === 1 || at === t) && (ot === t ||
|
|
1972
|
+
if (s && (s = c || o), (l === 1 || at === t) && (ot === t || Ln === t ? _ = n : _ = n + 1, p = e.position - e.lineStart, l === 1 ? s && (Qt(e, p) || La(e, p, _)) || Ba(e, _) ? d = !0 : (i && Na(e, _) || Fa(e, _) || Ka(e, _) ? d = !0 : Ua(e) ? (d = !0, (e.tag !== null || e.anchor !== null) && S(e, "alias node should not have any properties")) : ja(e, _, ot === t) && (d = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : l === 0 && (d = s && Qt(e, p))), e.tag === null)
|
|
1985
1973
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1986
1974
|
else if (e.tag === "?") {
|
|
1987
|
-
for (e.result !== null && e.kind !== "scalar" && S(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0,
|
|
1975
|
+
for (e.result !== null && e.kind !== "scalar" && S(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0, m = e.implicitTypes.length; u < m; u += 1)
|
|
1988
1976
|
if (k = e.implicitTypes[u], k.resolve(e.result)) {
|
|
1989
1977
|
e.result = k.construct(e.result), e.tag = k.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1990
1978
|
break;
|
|
1991
1979
|
}
|
|
1992
1980
|
} else if (e.tag !== "!") {
|
|
1993
|
-
if (
|
|
1981
|
+
if (Me.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
1994
1982
|
k = e.typeMap[e.kind || "fallback"][e.tag];
|
|
1995
1983
|
else
|
|
1996
|
-
for (k = null,
|
|
1997
|
-
if (e.tag.slice(0,
|
|
1998
|
-
k =
|
|
1984
|
+
for (k = null, g = e.typeMap.multi[e.kind || "fallback"], u = 0, m = g.length; u < m; u += 1)
|
|
1985
|
+
if (e.tag.slice(0, g[u].tag.length) === g[u].tag) {
|
|
1986
|
+
k = g[u];
|
|
1999
1987
|
break;
|
|
2000
1988
|
}
|
|
2001
1989
|
k || S(e, "unknown tag !<" + e.tag + ">"), e.result !== null && k.kind !== e.kind && S(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + k.kind + '", not "' + e.kind + '"'), k.resolve(e.result, e.tag) ? (e.result = k.construct(e.result, e.tag), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : S(e, "cannot resolve a node with !<" + e.tag + "> explicit tag");
|
|
2002
1990
|
}
|
|
2003
1991
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || d;
|
|
2004
1992
|
}
|
|
2005
|
-
function
|
|
1993
|
+
function Ra(e) {
|
|
2006
1994
|
var n = e.position, t, r, o, a = !1, i;
|
|
2007
1995
|
for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = /* @__PURE__ */ Object.create(null), e.anchorMap = /* @__PURE__ */ Object.create(null); (i = e.input.charCodeAt(e.position)) !== 0 && (ae(e, !0, -1), i = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || i !== 37)); ) {
|
|
2008
1996
|
for (a = !0, i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !he(i); )
|
|
@@ -2022,9 +2010,9 @@ function Da(e) {
|
|
|
2022
2010
|
i = e.input.charCodeAt(++e.position);
|
|
2023
2011
|
o.push(e.input.slice(t, e.position));
|
|
2024
2012
|
}
|
|
2025
|
-
i !== 0 &&
|
|
2013
|
+
i !== 0 && Mt(e), Me.call(Wt, r) ? Wt[r](e, r, o) : it(e, 'unknown document directive "' + r + '"');
|
|
2026
2014
|
}
|
|
2027
|
-
if (ae(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, ae(e, !0, -1)) : a && S(e, "directives end mark is expected"),
|
|
2015
|
+
if (ae(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, ae(e, !0, -1)) : a && S(e, "directives end mark is expected"), Re(e, e.lineIndent - 1, at, !1, !0), ae(e, !0, -1), e.checkLineBreaks && Aa.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 && dt(e)) {
|
|
2028
2016
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, ae(e, !0, -1));
|
|
2029
2017
|
return;
|
|
2030
2018
|
}
|
|
@@ -2036,14 +2024,14 @@ function Da(e) {
|
|
|
2036
2024
|
function Gn(e, n) {
|
|
2037
2025
|
e = String(e), n = n || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2038
2026
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2039
|
-
var t = new
|
|
2027
|
+
var t = new Ea(e, n), r = e.indexOf("\0");
|
|
2040
2028
|
for (r !== -1 && (t.position = r, S(t, "null byte is not allowed in input")), t.input += "\0"; t.input.charCodeAt(t.position) === 32; )
|
|
2041
2029
|
t.lineIndent += 1, t.position += 1;
|
|
2042
2030
|
for (; t.position < t.length - 1; )
|
|
2043
|
-
|
|
2031
|
+
Ra(t);
|
|
2044
2032
|
return t.documents;
|
|
2045
2033
|
}
|
|
2046
|
-
function
|
|
2034
|
+
function Va(e, n, t) {
|
|
2047
2035
|
n !== null && typeof n == "object" && typeof t > "u" && (t = n, n = null);
|
|
2048
2036
|
var r = Gn(e, t);
|
|
2049
2037
|
if (typeof n != "function")
|
|
@@ -2051,7 +2039,7 @@ function Ga(e, n, t) {
|
|
|
2051
2039
|
for (var o = 0, a = r.length; o < a; o += 1)
|
|
2052
2040
|
n(r[o]);
|
|
2053
2041
|
}
|
|
2054
|
-
function
|
|
2042
|
+
function Da(e, n) {
|
|
2055
2043
|
var t = Gn(e, n);
|
|
2056
2044
|
if (t.length !== 0) {
|
|
2057
2045
|
if (t.length === 1)
|
|
@@ -2059,10 +2047,10 @@ function Ha(e, n) {
|
|
|
2059
2047
|
throw new me("expected a single document in the stream, but found more");
|
|
2060
2048
|
}
|
|
2061
2049
|
}
|
|
2062
|
-
var
|
|
2063
|
-
loadAll:
|
|
2064
|
-
load:
|
|
2065
|
-
}, zn = Object.prototype.toString,
|
|
2050
|
+
var Ga = Va, Ha = Da, Hn = {
|
|
2051
|
+
loadAll: Ga,
|
|
2052
|
+
load: Ha
|
|
2053
|
+
}, zn = Object.prototype.toString, Yn = Object.prototype.hasOwnProperty, Et = 65279, za = 9, Je = 10, Ya = 13, Ja = 32, Wa = 33, Za = 34, bt = 35, Qa = 37, Xa = 38, ei = 39, ti = 42, Jn = 44, ni = 45, st = 58, ri = 61, oi = 62, ai = 63, ii = 64, Wn = 91, Zn = 93, si = 96, Qn = 123, li = 124, Xn = 125, fe = {};
|
|
2066
2054
|
fe[0] = "\\0";
|
|
2067
2055
|
fe[7] = "\\a";
|
|
2068
2056
|
fe[8] = "\\b";
|
|
@@ -2078,7 +2066,7 @@ fe[133] = "\\N";
|
|
|
2078
2066
|
fe[160] = "\\_";
|
|
2079
2067
|
fe[8232] = "\\L";
|
|
2080
2068
|
fe[8233] = "\\P";
|
|
2081
|
-
var
|
|
2069
|
+
var ui = [
|
|
2082
2070
|
"y",
|
|
2083
2071
|
"Y",
|
|
2084
2072
|
"yes",
|
|
@@ -2095,16 +2083,16 @@ var di = [
|
|
|
2095
2083
|
"off",
|
|
2096
2084
|
"Off",
|
|
2097
2085
|
"OFF"
|
|
2098
|
-
],
|
|
2099
|
-
function
|
|
2086
|
+
], ci = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2087
|
+
function di(e, n) {
|
|
2100
2088
|
var t, r, o, a, i, s, l;
|
|
2101
2089
|
if (n === null)
|
|
2102
2090
|
return {};
|
|
2103
2091
|
for (t = {}, r = Object.keys(n), o = 0, a = r.length; o < a; o += 1)
|
|
2104
|
-
i = r[o], s = String(n[i]), i.slice(0, 2) === "!!" && (i = "tag:yaml.org,2002:" + i.slice(2)), l = e.compiledTypeMap.fallback[i], l &&
|
|
2092
|
+
i = r[o], s = String(n[i]), i.slice(0, 2) === "!!" && (i = "tag:yaml.org,2002:" + i.slice(2)), l = e.compiledTypeMap.fallback[i], l && Yn.call(l.styleAliases, s) && (s = l.styleAliases[s]), t[i] = s;
|
|
2105
2093
|
return t;
|
|
2106
2094
|
}
|
|
2107
|
-
function
|
|
2095
|
+
function pi(e) {
|
|
2108
2096
|
var n, t, r;
|
|
2109
2097
|
if (n = e.toString(16).toUpperCase(), e <= 255)
|
|
2110
2098
|
t = "x", r = 2;
|
|
@@ -2116,9 +2104,9 @@ function mi(e) {
|
|
|
2116
2104
|
throw new me("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2117
2105
|
return "\\" + t + le.repeat("0", r - n.length) + n;
|
|
2118
2106
|
}
|
|
2119
|
-
var
|
|
2120
|
-
function
|
|
2121
|
-
this.schema = e.schema || $t, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = le.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap =
|
|
2107
|
+
var fi = 1, We = 2;
|
|
2108
|
+
function mi(e) {
|
|
2109
|
+
this.schema = e.schema || $t, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = le.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = di(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 === '"' ? We : fi, 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;
|
|
2122
2110
|
}
|
|
2123
2111
|
function Xt(e, n) {
|
|
2124
2112
|
for (var t = le.repeat(" ", n), r = 0, o = -1, a = "", i, s = e.length; r < s; )
|
|
@@ -2131,7 +2119,7 @@ function Ct(e, n) {
|
|
|
2131
2119
|
return `
|
|
2132
2120
|
` + le.repeat(" ", e.indent * n);
|
|
2133
2121
|
}
|
|
2134
|
-
function
|
|
2122
|
+
function gi(e, n) {
|
|
2135
2123
|
var t, r, o;
|
|
2136
2124
|
for (t = 0, r = e.implicitTypes.length; t < r; t += 1)
|
|
2137
2125
|
if (o = e.implicitTypes[t], o.resolve(n))
|
|
@@ -2139,13 +2127,13 @@ function hi(e, n) {
|
|
|
2139
2127
|
return !1;
|
|
2140
2128
|
}
|
|
2141
2129
|
function lt(e) {
|
|
2142
|
-
return e ===
|
|
2130
|
+
return e === Ja || e === za;
|
|
2143
2131
|
}
|
|
2144
2132
|
function Ze(e) {
|
|
2145
2133
|
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== Et || 65536 <= e && e <= 1114111;
|
|
2146
2134
|
}
|
|
2147
2135
|
function en(e) {
|
|
2148
|
-
return Ze(e) && e !== Et && e !==
|
|
2136
|
+
return Ze(e) && e !== Et && e !== Ya && e !== Je;
|
|
2149
2137
|
}
|
|
2150
2138
|
function tn(e, n, t) {
|
|
2151
2139
|
var r = en(e), o = r && !lt(e);
|
|
@@ -2154,13 +2142,13 @@ function tn(e, n, t) {
|
|
|
2154
2142
|
(t ? (
|
|
2155
2143
|
// c = flow-in
|
|
2156
2144
|
r
|
|
2157
|
-
) : r && e !==
|
|
2145
|
+
) : r && e !== Jn && e !== Wn && e !== Zn && e !== Qn && e !== Xn) && e !== bt && !(n === st && !o) || en(n) && !lt(n) && e === bt || n === st && o
|
|
2158
2146
|
);
|
|
2159
2147
|
}
|
|
2160
|
-
function
|
|
2161
|
-
return Ze(e) && e !== Et && !lt(e) && e !==
|
|
2148
|
+
function yi(e) {
|
|
2149
|
+
return Ze(e) && e !== Et && !lt(e) && e !== ni && e !== ai && e !== st && e !== Jn && e !== Wn && e !== Zn && e !== Qn && e !== Xn && e !== bt && e !== Xa && e !== ti && e !== Wa && e !== li && e !== ri && e !== oi && e !== ei && e !== Za && e !== Qa && e !== ii && e !== si;
|
|
2162
2150
|
}
|
|
2163
|
-
function
|
|
2151
|
+
function hi(e) {
|
|
2164
2152
|
return !lt(e) && e !== st;
|
|
2165
2153
|
}
|
|
2166
2154
|
function He(e, n) {
|
|
@@ -2171,39 +2159,39 @@ function er(e) {
|
|
|
2171
2159
|
var n = /^\n* /;
|
|
2172
2160
|
return n.test(e);
|
|
2173
2161
|
}
|
|
2174
|
-
var tr = 1, kt = 2, nr = 3, rr = 4,
|
|
2175
|
-
function
|
|
2176
|
-
var l, c = 0, d = null, u = !1,
|
|
2162
|
+
var tr = 1, kt = 2, nr = 3, rr = 4, qe = 5;
|
|
2163
|
+
function vi(e, n, t, r, o, a, i, s) {
|
|
2164
|
+
var l, c = 0, d = null, u = !1, m = !1, g = r !== -1, k = -1, _ = yi(He(e, 0)) && hi(He(e, e.length - 1));
|
|
2177
2165
|
if (n || i)
|
|
2178
2166
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2179
2167
|
if (c = He(e, l), !Ze(c))
|
|
2180
|
-
return
|
|
2168
|
+
return qe;
|
|
2181
2169
|
_ = _ && tn(c, d, s), d = c;
|
|
2182
2170
|
}
|
|
2183
2171
|
else {
|
|
2184
2172
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2185
|
-
if (c = He(e, l), c ===
|
|
2186
|
-
u = !0,
|
|
2173
|
+
if (c = He(e, l), c === Je)
|
|
2174
|
+
u = !0, g && (m = m || // Foldable line = too long, and not more-indented.
|
|
2187
2175
|
l - k - 1 > r && e[k + 1] !== " ", k = l);
|
|
2188
2176
|
else if (!Ze(c))
|
|
2189
|
-
return
|
|
2177
|
+
return qe;
|
|
2190
2178
|
_ = _ && tn(c, d, s), d = c;
|
|
2191
2179
|
}
|
|
2192
|
-
|
|
2180
|
+
m = m || g && l - k - 1 > r && e[k + 1] !== " ";
|
|
2193
2181
|
}
|
|
2194
|
-
return !u && !
|
|
2182
|
+
return !u && !m ? _ && !i && !o(e) ? tr : a === We ? qe : kt : t > 9 && er(e) ? qe : i ? a === We ? qe : kt : m ? rr : nr;
|
|
2195
2183
|
}
|
|
2196
|
-
function
|
|
2184
|
+
function bi(e, n, t, r, o) {
|
|
2197
2185
|
e.dump = function() {
|
|
2198
2186
|
if (n.length === 0)
|
|
2199
2187
|
return e.quotingType === We ? '""' : "''";
|
|
2200
|
-
if (!e.noCompatMode && (
|
|
2188
|
+
if (!e.noCompatMode && (ui.indexOf(n) !== -1 || ci.test(n)))
|
|
2201
2189
|
return e.quotingType === We ? '"' + n + '"' : "'" + n + "'";
|
|
2202
2190
|
var a = e.indent * Math.max(1, t), i = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - a), s = r || e.flowLevel > -1 && t >= e.flowLevel;
|
|
2203
2191
|
function l(c) {
|
|
2204
|
-
return
|
|
2192
|
+
return gi(e, c);
|
|
2205
2193
|
}
|
|
2206
|
-
switch (
|
|
2194
|
+
switch (vi(
|
|
2207
2195
|
n,
|
|
2208
2196
|
s,
|
|
2209
2197
|
e.indent,
|
|
@@ -2220,9 +2208,9 @@ function ki(e, n, t, r, o) {
|
|
|
2220
2208
|
case nr:
|
|
2221
2209
|
return "|" + nn(n, e.indent) + rn(Xt(n, a));
|
|
2222
2210
|
case rr:
|
|
2223
|
-
return ">" + nn(n, e.indent) + rn(Xt(
|
|
2224
|
-
case
|
|
2225
|
-
return '"' +
|
|
2211
|
+
return ">" + nn(n, e.indent) + rn(Xt(Ci(n, i), a));
|
|
2212
|
+
case qe:
|
|
2213
|
+
return '"' + ki(n) + '"';
|
|
2226
2214
|
default:
|
|
2227
2215
|
throw new me("impossible error: invalid scalar style");
|
|
2228
2216
|
}
|
|
@@ -2240,7 +2228,7 @@ function rn(e) {
|
|
|
2240
2228
|
return e[e.length - 1] === `
|
|
2241
2229
|
` ? e.slice(0, -1) : e;
|
|
2242
2230
|
}
|
|
2243
|
-
function
|
|
2231
|
+
function Ci(e, n) {
|
|
2244
2232
|
for (var t = /(\n+)([^\n]*)/g, r = function() {
|
|
2245
2233
|
var c = e.indexOf(`
|
|
2246
2234
|
`);
|
|
@@ -2263,12 +2251,12 @@ function on(e, n) {
|
|
|
2263
2251
|
`, e.length - o > n && i > o ? l += e.slice(o, i) + `
|
|
2264
2252
|
` + e.slice(i + 1) : l += e.slice(o), l.slice(1);
|
|
2265
2253
|
}
|
|
2266
|
-
function
|
|
2254
|
+
function ki(e) {
|
|
2267
2255
|
for (var n = "", t = 0, r, o = 0; o < e.length; t >= 65536 ? o += 2 : o++)
|
|
2268
|
-
t = He(e, o), r = fe[t], !r && Ze(t) ? (n += e[o], t >= 65536 && (n += e[o + 1])) : n += r ||
|
|
2256
|
+
t = He(e, o), r = fe[t], !r && Ze(t) ? (n += e[o], t >= 65536 && (n += e[o + 1])) : n += r || pi(t);
|
|
2269
2257
|
return n;
|
|
2270
2258
|
}
|
|
2271
|
-
function
|
|
2259
|
+
function _i(e, n, t) {
|
|
2272
2260
|
var r = "", o = e.tag, a, i, s;
|
|
2273
2261
|
for (a = 0, i = t.length; a < i; a += 1)
|
|
2274
2262
|
s = t[a], e.replacer && (s = e.replacer.call(t, String(a), s)), (Ae(e, n, s, !1, !1) || typeof s > "u" && Ae(e, n, null, !1, !1)) && (r !== "" && (r += "," + (e.condenseFlow ? "" : " ")), r += e.dump);
|
|
@@ -2277,17 +2265,17 @@ function Ii(e, n, t) {
|
|
|
2277
2265
|
function an(e, n, t, r) {
|
|
2278
2266
|
var o = "", a = e.tag, i, s, l;
|
|
2279
2267
|
for (i = 0, s = t.length; i < s; i += 1)
|
|
2280
|
-
l = t[i], e.replacer && (l = e.replacer.call(t, String(i), l)), (Ae(e, n + 1, l, !0, !0, !1, !0) || typeof l > "u" && Ae(e, n + 1, null, !0, !0, !1, !0)) && ((!r || o !== "") && (o += Ct(e, n)), e.dump &&
|
|
2268
|
+
l = t[i], e.replacer && (l = e.replacer.call(t, String(i), l)), (Ae(e, n + 1, l, !0, !0, !1, !0) || typeof l > "u" && Ae(e, n + 1, null, !0, !0, !1, !0)) && ((!r || o !== "") && (o += Ct(e, n)), e.dump && Je === e.dump.charCodeAt(0) ? o += "-" : o += "- ", o += e.dump);
|
|
2281
2269
|
e.tag = a, e.dump = o || "[]";
|
|
2282
2270
|
}
|
|
2283
|
-
function
|
|
2271
|
+
function wi(e, n, t) {
|
|
2284
2272
|
var r = "", o = e.tag, a = Object.keys(t), i, s, l, c, d;
|
|
2285
2273
|
for (i = 0, s = a.length; i < s; i += 1)
|
|
2286
2274
|
d = "", r !== "" && (d += ", "), e.condenseFlow && (d += '"'), l = a[i], c = t[l], e.replacer && (c = e.replacer.call(t, l, c)), Ae(e, n, l, !1, !1) && (e.dump.length > 1024 && (d += "? "), d += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Ae(e, n, c, !1, !1) && (d += e.dump, r += d));
|
|
2287
2275
|
e.tag = o, e.dump = "{" + r + "}";
|
|
2288
2276
|
}
|
|
2289
|
-
function
|
|
2290
|
-
var o = "", a = e.tag, i = Object.keys(t), s, l, c, d, u,
|
|
2277
|
+
function Ii(e, n, t, r) {
|
|
2278
|
+
var o = "", a = e.tag, i = Object.keys(t), s, l, c, d, u, m;
|
|
2291
2279
|
if (e.sortKeys === !0)
|
|
2292
2280
|
i.sort();
|
|
2293
2281
|
else if (typeof e.sortKeys == "function")
|
|
@@ -2295,7 +2283,7 @@ function Ai(e, n, t, r) {
|
|
|
2295
2283
|
else if (e.sortKeys)
|
|
2296
2284
|
throw new me("sortKeys must be a boolean or a function");
|
|
2297
2285
|
for (s = 0, l = i.length; s < l; s += 1)
|
|
2298
|
-
|
|
2286
|
+
m = "", (!r || o !== "") && (m += Ct(e, n)), c = i[s], d = t[c], e.replacer && (d = e.replacer.call(t, c, d)), Ae(e, n + 1, c, !0, !0, !0) && (u = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, u && (e.dump && Je === e.dump.charCodeAt(0) ? m += "?" : m += "? "), m += e.dump, u && (m += Ct(e, n)), Ae(e, n + 1, d, !0, u) && (e.dump && Je === e.dump.charCodeAt(0) ? m += ":" : m += ": ", m += e.dump, o += m));
|
|
2299
2287
|
e.tag = a, e.dump = o || "{}";
|
|
2300
2288
|
}
|
|
2301
2289
|
function sn(e, n, t) {
|
|
@@ -2305,7 +2293,7 @@ function sn(e, n, t) {
|
|
|
2305
2293
|
if (t ? s.multi && s.representName ? e.tag = s.representName(n) : e.tag = s.tag : e.tag = "?", s.represent) {
|
|
2306
2294
|
if (l = e.styleMap[s.tag] || s.defaultStyle, zn.call(s.represent) === "[object Function]")
|
|
2307
2295
|
r = s.represent(n, l);
|
|
2308
|
-
else if (
|
|
2296
|
+
else if (Yn.call(s.represent, l))
|
|
2309
2297
|
r = s.represent[l](n, l);
|
|
2310
2298
|
else
|
|
2311
2299
|
throw new me("!<" + s.tag + '> tag resolver accepts not "' + l + '" style');
|
|
@@ -2319,16 +2307,16 @@ function Ae(e, n, t, r, o, a, i) {
|
|
|
2319
2307
|
e.tag = null, e.dump = t, sn(e, t, !1) || sn(e, t, !0);
|
|
2320
2308
|
var s = zn.call(e.dump), l = r, c;
|
|
2321
2309
|
r && (r = e.flowLevel < 0 || e.flowLevel > n);
|
|
2322
|
-
var d = s === "[object Object]" || s === "[object Array]", u,
|
|
2323
|
-
if (d && (u = e.duplicates.indexOf(t),
|
|
2310
|
+
var d = s === "[object Object]" || s === "[object Array]", u, m;
|
|
2311
|
+
if (d && (u = e.duplicates.indexOf(t), m = u !== -1), (e.tag !== null && e.tag !== "?" || m || e.indent !== 2 && n > 0) && (o = !1), m && e.usedDuplicates[u])
|
|
2324
2312
|
e.dump = "*ref_" + u;
|
|
2325
2313
|
else {
|
|
2326
|
-
if (d &&
|
|
2327
|
-
r && Object.keys(e.dump).length !== 0 ? (
|
|
2314
|
+
if (d && m && !e.usedDuplicates[u] && (e.usedDuplicates[u] = !0), s === "[object Object]")
|
|
2315
|
+
r && Object.keys(e.dump).length !== 0 ? (Ii(e, n, e.dump, o), m && (e.dump = "&ref_" + u + e.dump)) : (wi(e, n, e.dump), m && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2328
2316
|
else if (s === "[object Array]")
|
|
2329
|
-
r && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? an(e, n - 1, e.dump, o) : an(e, n, e.dump, o),
|
|
2317
|
+
r && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? an(e, n - 1, e.dump, o) : an(e, n, e.dump, o), m && (e.dump = "&ref_" + u + e.dump)) : (_i(e, n, e.dump), m && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2330
2318
|
else if (s === "[object String]")
|
|
2331
|
-
e.tag !== "?" &&
|
|
2319
|
+
e.tag !== "?" && bi(e, e.dump, n, a, l);
|
|
2332
2320
|
else {
|
|
2333
2321
|
if (s === "[object Undefined]" || e.skipInvalid)
|
|
2334
2322
|
return !1;
|
|
@@ -2340,7 +2328,7 @@ function Ae(e, n, t, r, o, a, i) {
|
|
|
2340
2328
|
}
|
|
2341
2329
|
return !0;
|
|
2342
2330
|
}
|
|
2343
|
-
function
|
|
2331
|
+
function xi(e, n) {
|
|
2344
2332
|
var t = [], r = [], o, a;
|
|
2345
2333
|
for (_t(e, t, r), o = 0, a = r.length; o < a; o += 1)
|
|
2346
2334
|
n.duplicates.push(t[r[o]]);
|
|
@@ -2358,65 +2346,65 @@ function _t(e, n, t) {
|
|
|
2358
2346
|
for (r = Object.keys(e), o = 0, a = r.length; o < a; o += 1)
|
|
2359
2347
|
_t(e[r[o]], n, t);
|
|
2360
2348
|
}
|
|
2361
|
-
function
|
|
2349
|
+
function Ai(e, n) {
|
|
2362
2350
|
n = n || {};
|
|
2363
|
-
var t = new
|
|
2364
|
-
t.noRefs ||
|
|
2351
|
+
var t = new mi(n);
|
|
2352
|
+
t.noRefs || xi(e, t);
|
|
2365
2353
|
var r = e;
|
|
2366
2354
|
return t.replacer && (r = t.replacer.call({ "": r }, "", r)), Ae(t, 0, r, !0, !0) ? t.dump + `
|
|
2367
2355
|
` : "";
|
|
2368
2356
|
}
|
|
2369
|
-
var
|
|
2370
|
-
dump:
|
|
2357
|
+
var Si = Ai, Ti = {
|
|
2358
|
+
dump: Si
|
|
2371
2359
|
};
|
|
2372
|
-
function
|
|
2360
|
+
function jt(e, n) {
|
|
2373
2361
|
return function() {
|
|
2374
2362
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + n + " instead, which is now safe by default.");
|
|
2375
2363
|
};
|
|
2376
2364
|
}
|
|
2377
|
-
var
|
|
2365
|
+
var $i = pe, Mi = bn, Oi = wn, Ei = Tn, ji = $n, Fi = $t, Ki = Hn.load, Bi = Hn.loadAll, Ni = Ti.dump, Li = me, qi = {
|
|
2378
2366
|
binary: Fn,
|
|
2379
2367
|
float: Sn,
|
|
2380
2368
|
map: _n,
|
|
2381
2369
|
null: In,
|
|
2382
|
-
pairs:
|
|
2370
|
+
pairs: Bn,
|
|
2383
2371
|
set: Nn,
|
|
2384
2372
|
timestamp: En,
|
|
2385
2373
|
bool: xn,
|
|
2386
2374
|
int: An,
|
|
2387
|
-
merge:
|
|
2388
|
-
omap:
|
|
2375
|
+
merge: jn,
|
|
2376
|
+
omap: Kn,
|
|
2389
2377
|
seq: kn,
|
|
2390
2378
|
str: Cn
|
|
2391
|
-
},
|
|
2392
|
-
Type:
|
|
2393
|
-
Schema:
|
|
2379
|
+
}, Pi = jt("safeLoad", "load"), Ui = jt("safeLoadAll", "loadAll"), Ri = jt("safeDump", "dump"), Vi = {
|
|
2380
|
+
Type: $i,
|
|
2381
|
+
Schema: Mi,
|
|
2394
2382
|
FAILSAFE_SCHEMA: Oi,
|
|
2395
|
-
JSON_SCHEMA:
|
|
2396
|
-
CORE_SCHEMA:
|
|
2397
|
-
DEFAULT_SCHEMA:
|
|
2398
|
-
load:
|
|
2399
|
-
loadAll:
|
|
2400
|
-
dump:
|
|
2383
|
+
JSON_SCHEMA: Ei,
|
|
2384
|
+
CORE_SCHEMA: ji,
|
|
2385
|
+
DEFAULT_SCHEMA: Fi,
|
|
2386
|
+
load: Ki,
|
|
2387
|
+
loadAll: Bi,
|
|
2388
|
+
dump: Ni,
|
|
2401
2389
|
YAMLException: Li,
|
|
2402
|
-
types:
|
|
2403
|
-
safeLoad:
|
|
2404
|
-
safeLoadAll:
|
|
2405
|
-
safeDump:
|
|
2390
|
+
types: qi,
|
|
2391
|
+
safeLoad: Pi,
|
|
2392
|
+
safeLoadAll: Ui,
|
|
2393
|
+
safeDump: Ri
|
|
2406
2394
|
};
|
|
2407
|
-
const
|
|
2395
|
+
const Di = {
|
|
2408
2396
|
key: 0,
|
|
2409
2397
|
class: "config-card-display-form"
|
|
2410
|
-
},
|
|
2398
|
+
}, Gi = ["data-testid"], Hi = {
|
|
2411
2399
|
key: 0,
|
|
2412
2400
|
class: "config-card-prop-section-title"
|
|
2413
|
-
},
|
|
2401
|
+
}, zi = {
|
|
2414
2402
|
key: 1,
|
|
2415
2403
|
class: "config-card-display-json"
|
|
2416
|
-
},
|
|
2404
|
+
}, Yi = {
|
|
2417
2405
|
key: 2,
|
|
2418
2406
|
class: "config-card-display-yaml"
|
|
2419
|
-
},
|
|
2407
|
+
}, Ji = /* @__PURE__ */ ie({
|
|
2420
2408
|
__name: "ConfigCardDisplay",
|
|
2421
2409
|
props: {
|
|
2422
2410
|
propertyCollections: {
|
|
@@ -2442,30 +2430,30 @@ const Hi = {
|
|
|
2442
2430
|
}
|
|
2443
2431
|
},
|
|
2444
2432
|
setup(e) {
|
|
2445
|
-
const n = e, t = ut(), { i18n: { t: r } } = de.useI18n(), o = (s) => !!(s.tooltip || t[`${s.key}-label-tooltip`]), a =
|
|
2446
|
-
return
|
|
2447
|
-
s === "json" ? a.value = JSON.stringify(n.record, null, 2) : s === "yaml" && (i.value =
|
|
2433
|
+
const n = e, t = ut(), { i18n: { t: r } } = de.useI18n(), o = (s) => !!(s.tooltip || t[`${s.key}-label-tooltip`]), a = F(""), i = F("");
|
|
2434
|
+
return Oe(() => n.format, (s) => {
|
|
2435
|
+
s === "json" ? a.value = JSON.stringify(n.record, null, 2) : s === "yaml" && (i.value = Vi.dump(n.record));
|
|
2448
2436
|
}, { immediate: !0 }), (s, l) => {
|
|
2449
|
-
const c =
|
|
2437
|
+
const c = N("KCodeBlock");
|
|
2450
2438
|
return f(), A(ve, null, [
|
|
2451
|
-
e.format === "structured" ? (f(), A("div",
|
|
2439
|
+
e.format === "structured" ? (f(), A("div", Di, [
|
|
2452
2440
|
(f(!0), A(ve, null, ye(e.propListTypes, (d) => (f(), A("div", {
|
|
2453
2441
|
key: `config-card-details-${d}-props`,
|
|
2454
|
-
class:
|
|
2442
|
+
class: Ke(`config-card-details-${d}-props`),
|
|
2455
2443
|
"data-testid": `config-card-details-${d}-props`
|
|
2456
2444
|
}, [
|
|
2457
|
-
d !== "basic" ? (f(), A("div",
|
|
2445
|
+
d !== "basic" ? (f(), A("div", Hi, E(d === "advanced" ? h(r)("baseConfigCard.sections.advanced") : h(r)("baseConfigCard.sections.plugin")), 1)) : G("", !0),
|
|
2458
2446
|
(f(!0), A(ve, null, ye(e.propertyCollections[d], (u) => (f(), U(St, {
|
|
2459
2447
|
key: u.key,
|
|
2460
2448
|
item: u
|
|
2461
2449
|
}, Se({
|
|
2462
2450
|
label: v(() => [
|
|
2463
|
-
|
|
2451
|
+
Z(s.$slots, `${u.key}-label`, { row: u }, void 0, !0)
|
|
2464
2452
|
]),
|
|
2465
|
-
[u.key]: v(({ rowValue:
|
|
2466
|
-
|
|
2453
|
+
[u.key]: v(({ rowValue: m }) => [
|
|
2454
|
+
Z(s.$slots, u.key, {
|
|
2467
2455
|
row: u,
|
|
2468
|
-
rowValue:
|
|
2456
|
+
rowValue: m
|
|
2469
2457
|
}, void 0, !0)
|
|
2470
2458
|
]),
|
|
2471
2459
|
_: 2
|
|
@@ -2473,23 +2461,23 @@ const Hi = {
|
|
|
2473
2461
|
o(u) ? {
|
|
2474
2462
|
name: "label-tooltip",
|
|
2475
2463
|
fn: v(() => [
|
|
2476
|
-
|
|
2464
|
+
Z(s.$slots, `${u.key}-label-tooltip`, { row: u }, void 0, !0)
|
|
2477
2465
|
]),
|
|
2478
2466
|
key: "0"
|
|
2479
2467
|
} : void 0
|
|
2480
2468
|
]), 1032, ["item"]))), 128))
|
|
2481
|
-
], 10,
|
|
2469
|
+
], 10, Gi))), 128))
|
|
2482
2470
|
])) : G("", !0),
|
|
2483
|
-
e.format === "json" ? (f(), A("div",
|
|
2484
|
-
|
|
2471
|
+
e.format === "json" ? (f(), A("div", zi, [
|
|
2472
|
+
j(c, {
|
|
2485
2473
|
id: "config-card-codeblock",
|
|
2486
2474
|
code: a.value,
|
|
2487
2475
|
language: "json",
|
|
2488
2476
|
theme: "dark"
|
|
2489
2477
|
}, null, 8, ["code"])
|
|
2490
2478
|
])) : G("", !0),
|
|
2491
|
-
e.format === "yaml" ? (f(), A("div",
|
|
2492
|
-
|
|
2479
|
+
e.format === "yaml" ? (f(), A("div", Yi, [
|
|
2480
|
+
j(c, {
|
|
2493
2481
|
id: "config-card-codeblock",
|
|
2494
2482
|
code: i.value,
|
|
2495
2483
|
language: "yaml",
|
|
@@ -2499,18 +2487,18 @@ const Hi = {
|
|
|
2499
2487
|
], 64);
|
|
2500
2488
|
};
|
|
2501
2489
|
}
|
|
2502
|
-
}),
|
|
2490
|
+
}), Wi = /* @__PURE__ */ ke(Ji, [["__scopeId", "data-v-6c45e9e4"]]), ln = "24px", Zi = (e, n) => {
|
|
2503
2491
|
const t = e.__vccOpts || e;
|
|
2504
2492
|
for (const [r, o] of n)
|
|
2505
2493
|
t[r] = o;
|
|
2506
2494
|
return t;
|
|
2507
|
-
},
|
|
2495
|
+
}, Qi = (e) => (gr("data-v-bae323b8"), e = e(), yr(), e), Xi = ["aria-hidden"], es = {
|
|
2508
2496
|
key: 0,
|
|
2509
2497
|
"data-testid": "kui-icon-svg-title"
|
|
2510
|
-
},
|
|
2498
|
+
}, ts = /* @__PURE__ */ Qi(() => /* @__PURE__ */ P("path", {
|
|
2511
2499
|
d: "M14 9.9V8.2C14.55 7.96667 15.1125 7.79167 15.6875 7.675C16.2625 7.55833 16.8667 7.5 17.5 7.5C17.9333 7.5 18.3583 7.53333 18.775 7.6C19.1917 7.66667 19.6 7.75 20 7.85V9.45C19.6 9.3 19.1958 9.1875 18.7875 9.1125C18.3792 9.0375 17.95 9 17.5 9C16.8667 9 16.2583 9.07917 15.675 9.2375C15.0917 9.39583 14.5333 9.61667 14 9.9ZM14 15.4V13.7C14.55 13.4667 15.1125 13.2917 15.6875 13.175C16.2625 13.0583 16.8667 13 17.5 13C17.9333 13 18.3583 13.0333 18.775 13.1C19.1917 13.1667 19.6 13.25 20 13.35V14.95C19.6 14.8 19.1958 14.6875 18.7875 14.6125C18.3792 14.5375 17.95 14.5 17.5 14.5C16.8667 14.5 16.2583 14.575 15.675 14.725C15.0917 14.875 14.5333 15.1 14 15.4ZM14 12.65V10.95C14.55 10.7167 15.1125 10.5417 15.6875 10.425C16.2625 10.3083 16.8667 10.25 17.5 10.25C17.9333 10.25 18.3583 10.2833 18.775 10.35C19.1917 10.4167 19.6 10.5 20 10.6V12.2C19.6 12.05 19.1958 11.9375 18.7875 11.8625C18.3792 11.7875 17.95 11.75 17.5 11.75C16.8667 11.75 16.2583 11.8292 15.675 11.9875C15.0917 12.1458 14.5333 12.3667 14 12.65ZM6.5 16C7.28333 16 8.04583 16.0875 8.7875 16.2625C9.52917 16.4375 10.2667 16.7 11 17.05V7.2C10.3167 6.8 9.59167 6.5 8.825 6.3C8.05833 6.1 7.28333 6 6.5 6C5.9 6 5.30417 6.05833 4.7125 6.175C4.12083 6.29167 3.55 6.46667 3 6.7V16.6C3.58333 16.4 4.1625 16.25 4.7375 16.15C5.3125 16.05 5.9 16 6.5 16ZM13 17.05C13.7333 16.7 14.4708 16.4375 15.2125 16.2625C15.9542 16.0875 16.7167 16 17.5 16C18.1 16 18.6875 16.05 19.2625 16.15C19.8375 16.25 20.4167 16.4 21 16.6V6.7C20.45 6.46667 19.8792 6.29167 19.2875 6.175C18.6958 6.05833 18.1 6 17.5 6C16.7167 6 15.9417 6.1 15.175 6.3C14.4083 6.5 13.6833 6.8 13 7.2V17.05ZM12 20C11.2 19.3667 10.3333 18.875 9.4 18.525C8.46667 18.175 7.5 18 6.5 18C5.8 18 5.1125 18.0917 4.4375 18.275C3.7625 18.4583 3.11667 18.7167 2.5 19.05C2.15 19.2333 1.8125 19.225 1.4875 19.025C1.1625 18.825 1 18.5333 1 18.15V6.1C1 5.91667 1.04583 5.74167 1.1375 5.575C1.22917 5.40833 1.36667 5.28333 1.55 5.2C2.31667 4.8 3.11667 4.5 3.95 4.3C4.78333 4.1 5.63333 4 6.5 4C7.46667 4 8.4125 4.125 9.3375 4.375C10.2625 4.625 11.15 5 12 5.5C12.85 5 13.7375 4.625 14.6625 4.375C15.5875 4.125 16.5333 4 17.5 4C18.3667 4 19.2167 4.1 20.05 4.3C20.8833 4.5 21.6833 4.8 22.45 5.2C22.6333 5.28333 22.7708 5.40833 22.8625 5.575C22.9542 5.74167 23 5.91667 23 6.1V18.15C23 18.5333 22.8375 18.825 22.5125 19.025C22.1875 19.225 21.85 19.2333 21.5 19.05C20.8833 18.7167 20.2375 18.4583 19.5625 18.275C18.8875 18.0917 18.2 18 17.5 18C16.5 18 15.5333 18.175 14.6 18.525C13.6667 18.875 12.8 19.3667 12 20Z",
|
|
2512
2500
|
fill: "currentColor"
|
|
2513
|
-
}, null, -1)),
|
|
2501
|
+
}, null, -1)), ns = /* @__PURE__ */ ie({
|
|
2514
2502
|
__name: "BookIcon",
|
|
2515
2503
|
props: {
|
|
2516
2504
|
/** The accessibility text provided to screen readers */
|
|
@@ -2596,23 +2584,23 @@ const Hi = {
|
|
|
2596
2584
|
width: "100%",
|
|
2597
2585
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2598
2586
|
}, [
|
|
2599
|
-
e.title ? (f(), A("title",
|
|
2600
|
-
|
|
2601
|
-
], 8,
|
|
2587
|
+
e.title ? (f(), A("title", es, E(e.title), 1)) : G("", !0),
|
|
2588
|
+
ts
|
|
2589
|
+
], 8, Xi))
|
|
2602
2590
|
]),
|
|
2603
2591
|
_: 1
|
|
2604
2592
|
}, 8, ["aria-hidden", "style"]));
|
|
2605
2593
|
}
|
|
2606
|
-
}),
|
|
2594
|
+
}), rs = /* @__PURE__ */ Zi(ns, [["__scopeId", "data-v-bae323b8"]]), os = { "data-testid": "config-card-title" }, as = { class: "config-card-actions" }, is = ["href"], ss = {
|
|
2607
2595
|
key: 2,
|
|
2608
2596
|
class: "config-card-details-section"
|
|
2609
|
-
},
|
|
2597
|
+
}, ls = {
|
|
2610
2598
|
key: 3,
|
|
2611
2599
|
class: "config-card-details-section"
|
|
2612
|
-
},
|
|
2600
|
+
}, us = ["data-testid"], cs = {
|
|
2613
2601
|
key: 0,
|
|
2614
2602
|
class: "config-card-prop-section-title"
|
|
2615
|
-
},
|
|
2603
|
+
}, ds = /* @__PURE__ */ ie({
|
|
2616
2604
|
__name: "EntityBaseConfigCard",
|
|
2617
2605
|
props: {
|
|
2618
2606
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2703,9 +2691,9 @@ const Hi = {
|
|
|
2703
2691
|
label: "YAML",
|
|
2704
2692
|
value: "yaml"
|
|
2705
2693
|
}
|
|
2706
|
-
], d =
|
|
2694
|
+
], d = F("structured"), u = (I) => {
|
|
2707
2695
|
d.value = I == null ? void 0 : I.value;
|
|
2708
|
-
},
|
|
2696
|
+
}, m = {
|
|
2709
2697
|
id: {
|
|
2710
2698
|
type: ne.ID,
|
|
2711
2699
|
label: a("baseConfigCard.commonFields.id_label"),
|
|
@@ -2739,21 +2727,21 @@ const Hi = {
|
|
|
2739
2727
|
// the last property displayed
|
|
2740
2728
|
section: be.Basic
|
|
2741
2729
|
}
|
|
2742
|
-
},
|
|
2743
|
-
var I,
|
|
2730
|
+
}, g = F(!1), k = F(!1), _ = F(""), p = F(), C = T(() => {
|
|
2731
|
+
var I, V, q;
|
|
2744
2732
|
if (!p.value)
|
|
2745
2733
|
return [];
|
|
2746
|
-
const x = [],
|
|
2747
|
-
for (const
|
|
2748
|
-
const K = (
|
|
2749
|
-
let X =
|
|
2750
|
-
(
|
|
2734
|
+
const x = [], O = Object.keys(p.value).length;
|
|
2735
|
+
for (const M in p.value) {
|
|
2736
|
+
const K = (V = (I = r.configSchema) == null ? void 0 : I[M]) == null ? void 0 : V.order, J = (q = m[M]) == null ? void 0 : q.order;
|
|
2737
|
+
let X = O;
|
|
2738
|
+
(J || J === 0) && (X = J === -1 ? O + 1 : J), K && (X = K === -1 ? O + 1 : K), x.push([M, X]);
|
|
2751
2739
|
}
|
|
2752
|
-
return x.sort(function(
|
|
2753
|
-
return
|
|
2754
|
-
}), x.map((
|
|
2755
|
-
var K,
|
|
2756
|
-
const X =
|
|
2740
|
+
return x.sort(function(M, K) {
|
|
2741
|
+
return M[1] - K[1];
|
|
2742
|
+
}), x.map((M) => {
|
|
2743
|
+
var K, J;
|
|
2744
|
+
const X = M[0], ee = (K = p.value) == null ? void 0 : K[X], te = ((J = r.configSchema) == null ? void 0 : J[X]) || {}, se = m[X];
|
|
2757
2745
|
return {
|
|
2758
2746
|
key: X,
|
|
2759
2747
|
value: ee,
|
|
@@ -2763,53 +2751,53 @@ const Hi = {
|
|
|
2763
2751
|
tooltip: te.tooltip ?? ((se == null ? void 0 : se.tooltip) || void 0),
|
|
2764
2752
|
section: te.section ?? ((se == null ? void 0 : se.section) || be.Advanced)
|
|
2765
2753
|
};
|
|
2766
|
-
}).filter((
|
|
2754
|
+
}).filter((M) => !M.hidden && M.key !== r.pluginConfigKey);
|
|
2767
2755
|
}), y = T(() => {
|
|
2768
|
-
var I,
|
|
2756
|
+
var I, V;
|
|
2769
2757
|
if (!p.value || !r.pluginConfigKey)
|
|
2770
2758
|
return [];
|
|
2771
|
-
const
|
|
2772
|
-
for (const
|
|
2773
|
-
const K = (
|
|
2774
|
-
let X =
|
|
2775
|
-
K && (X = K === -1 ? x + 1 : K),
|
|
2759
|
+
const q = p.value[r.pluginConfigKey] || {}, x = Object.keys(q).length, O = [];
|
|
2760
|
+
for (const M in q) {
|
|
2761
|
+
const K = (V = (I = r.pluginConfigSchema) == null ? void 0 : I[M]) == null ? void 0 : V.order, J = q[M];
|
|
2762
|
+
let X = J != null && J !== "" ? x - 1 : x;
|
|
2763
|
+
K && (X = K === -1 ? x + 1 : K), O.push([M, X]);
|
|
2776
2764
|
}
|
|
2777
|
-
return
|
|
2778
|
-
return
|
|
2779
|
-
}),
|
|
2765
|
+
return O.sort(function(M, K) {
|
|
2766
|
+
return M[1] - K[1];
|
|
2767
|
+
}), O.map((M) => {
|
|
2780
2768
|
var K;
|
|
2781
|
-
const
|
|
2769
|
+
const J = M[0], X = q[J], ee = ((K = r.pluginConfigSchema) == null ? void 0 : K[J]) || {};
|
|
2782
2770
|
return {
|
|
2783
|
-
key:
|
|
2771
|
+
key: J,
|
|
2784
2772
|
value: X,
|
|
2785
2773
|
hidden: ee.hidden || !1,
|
|
2786
2774
|
type: ee.type ?? ne.Text,
|
|
2787
|
-
label: ee.label ?? s(
|
|
2775
|
+
label: ee.label ?? s(J),
|
|
2788
2776
|
tooltip: ee.tooltip ?? void 0,
|
|
2789
2777
|
section: be.Plugin
|
|
2790
2778
|
};
|
|
2791
|
-
}).filter((
|
|
2792
|
-
}),
|
|
2793
|
-
var I,
|
|
2779
|
+
}).filter((M) => !M.hidden);
|
|
2780
|
+
}), w = T(() => {
|
|
2781
|
+
var I, V, q, x;
|
|
2794
2782
|
return {
|
|
2795
|
-
basic: (I =
|
|
2796
|
-
advanced: (
|
|
2797
|
-
plugin: (x = y.value) == null ? void 0 : x.concat((
|
|
2783
|
+
basic: (I = C.value) == null ? void 0 : I.filter((O) => O.section === be.Basic),
|
|
2784
|
+
advanced: (V = C.value) == null ? void 0 : V.filter((O) => O.section === be.Advanced),
|
|
2785
|
+
plugin: (x = y.value) == null ? void 0 : x.concat((q = C.value) == null ? void 0 : q.filter((O) => O.section === be.Plugin))
|
|
2798
2786
|
};
|
|
2799
|
-
}),
|
|
2787
|
+
}), R = T(() => {
|
|
2800
2788
|
const I = [];
|
|
2801
|
-
return
|
|
2789
|
+
return w.value.basic.length && I.push("basic"), w.value.advanced.length && I.push("advanced"), w.value.plugin.length && I.push("plugin"), I;
|
|
2802
2790
|
}), H = (I) => !!(I.tooltip || o[`${I.key}-label-tooltip`]), re = T(() => {
|
|
2803
|
-
var I,
|
|
2804
|
-
let
|
|
2805
|
-
return r.config.app === "konnect" ?
|
|
2791
|
+
var I, V;
|
|
2792
|
+
let q = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
2793
|
+
return r.config.app === "konnect" ? q = q.replace(/{controlPlaneId}/gi, ((I = r.config) == null ? void 0 : I.controlPlaneId) || "") : r.config.app === "kongManager" && (q = q.replace(/\/{workspace}/gi, (V = r.config) != null && V.workspace ? `/${r.config.workspace}` : "")), q = q.replace(/{id}/gi, r.config.entityId), q;
|
|
2806
2794
|
}), z = (I) => {
|
|
2807
2795
|
p.value && I(JSON.stringify(p.value)) ? n("copy:success", p.value) : n("copy:error");
|
|
2808
2796
|
};
|
|
2809
|
-
return
|
|
2797
|
+
return Oe(g, (I) => {
|
|
2810
2798
|
n("loading", I);
|
|
2811
2799
|
}, { immediate: !0 }), Qe(async () => {
|
|
2812
|
-
k.value = !1,
|
|
2800
|
+
k.value = !1, g.value = !0;
|
|
2813
2801
|
try {
|
|
2814
2802
|
const { data: I } = await l.get(re.value);
|
|
2815
2803
|
if (r.dataKey)
|
|
@@ -2819,28 +2807,28 @@ const Hi = {
|
|
|
2819
2807
|
throw new Error(a("errors.dataKeyUndefined", { dataKey: r.dataKey }));
|
|
2820
2808
|
else
|
|
2821
2809
|
p.value = { ...I };
|
|
2822
|
-
Object.keys(r.configSchema).filter((
|
|
2823
|
-
p.value && typeof p.value[
|
|
2810
|
+
Object.keys(r.configSchema).filter((V) => r.configSchema[V].forceShow).forEach((V) => {
|
|
2811
|
+
p.value && typeof p.value[V] > "u" && (p.value[V] = null);
|
|
2824
2812
|
}), n("fetch:success", I);
|
|
2825
2813
|
} catch (I) {
|
|
2826
|
-
const
|
|
2827
|
-
_.value =
|
|
2814
|
+
const V = i(I);
|
|
2815
|
+
_.value = V.startsWith("code") ? a("baseConfigCard.errors.load") : V, k.value = !0, n("fetch:error", I);
|
|
2828
2816
|
} finally {
|
|
2829
|
-
|
|
2817
|
+
g.value = !1;
|
|
2830
2818
|
}
|
|
2831
|
-
}), (I,
|
|
2832
|
-
const
|
|
2819
|
+
}), (I, V) => {
|
|
2820
|
+
const q = N("KLabel"), x = N("KSelect"), O = N("KButton"), M = N("KClipboardProvider"), K = N("KSkeleton"), J = N("KEmptyState"), X = N("KCard");
|
|
2833
2821
|
return f(), U(X, { class: "kong-ui-entity-base-config-card" }, Se({
|
|
2834
2822
|
actions: v(() => [
|
|
2835
|
-
|
|
2836
|
-
|
|
2837
|
-
e.config.jsonYamlEnabled ? (f(), U(
|
|
2823
|
+
P("div", as, [
|
|
2824
|
+
Z(I.$slots, "actions", {}, void 0, !0),
|
|
2825
|
+
e.config.jsonYamlEnabled ? (f(), U(q, {
|
|
2838
2826
|
key: 0,
|
|
2839
2827
|
class: "config-format-select-label",
|
|
2840
2828
|
"data-testid": "config-format-select-label"
|
|
2841
2829
|
}, {
|
|
2842
2830
|
default: v(() => [
|
|
2843
|
-
|
|
2831
|
+
Q(E(e.label), 1)
|
|
2844
2832
|
]),
|
|
2845
2833
|
_: 1
|
|
2846
2834
|
})) : G("", !0),
|
|
@@ -2851,33 +2839,33 @@ const Hi = {
|
|
|
2851
2839
|
items: c,
|
|
2852
2840
|
onChange: u
|
|
2853
2841
|
})) : G("", !0),
|
|
2854
|
-
r.config.jsonYamlEnabled && e.configCardDoc ? (f(), U(
|
|
2842
|
+
r.config.jsonYamlEnabled && e.configCardDoc ? (f(), U(O, {
|
|
2855
2843
|
key: 2,
|
|
2856
2844
|
appearance: "btn-link",
|
|
2857
2845
|
class: "book-icon",
|
|
2858
2846
|
"data-testid": "book-icon"
|
|
2859
2847
|
}, {
|
|
2860
2848
|
default: v(() => [
|
|
2861
|
-
|
|
2849
|
+
P("a", {
|
|
2862
2850
|
href: e.configCardDoc,
|
|
2863
2851
|
rel: "noopener",
|
|
2864
2852
|
target: "_blank"
|
|
2865
2853
|
}, [
|
|
2866
|
-
|
|
2867
|
-
], 8,
|
|
2854
|
+
j(h(rs), { size: h(uo) }, null, 8, ["size"])
|
|
2855
|
+
], 8, is)
|
|
2868
2856
|
]),
|
|
2869
2857
|
_: 1
|
|
2870
2858
|
})) : G("", !0),
|
|
2871
|
-
e.config.jsonYamlEnabled ? G("", !0) : (f(), U(
|
|
2859
|
+
e.config.jsonYamlEnabled ? G("", !0) : (f(), U(M, { key: 3 }, {
|
|
2872
2860
|
default: v(({ copyToClipboard: ee }) => [
|
|
2873
|
-
!
|
|
2861
|
+
!g.value && !k.value ? (f(), U(O, {
|
|
2874
2862
|
key: 0,
|
|
2875
2863
|
appearance: "btn-link",
|
|
2876
2864
|
"data-testid": "json-copy-button",
|
|
2877
2865
|
onClick: (te) => z(ee)
|
|
2878
2866
|
}, {
|
|
2879
2867
|
default: v(() => [
|
|
2880
|
-
|
|
2868
|
+
Q(E(h(a)("baseConfigCard.actions.copy")), 1)
|
|
2881
2869
|
]),
|
|
2882
2870
|
_: 2
|
|
2883
2871
|
}, 1032, ["onClick"])) : G("", !0)
|
|
@@ -2887,54 +2875,54 @@ const Hi = {
|
|
|
2887
2875
|
])
|
|
2888
2876
|
]),
|
|
2889
2877
|
body: v(() => [
|
|
2890
|
-
|
|
2878
|
+
g.value ? (f(), U(K, {
|
|
2891
2879
|
key: 0,
|
|
2892
2880
|
"data-testid": "config-card-loader",
|
|
2893
2881
|
"table-columns": 2,
|
|
2894
2882
|
type: "table"
|
|
2895
|
-
})) : k.value ? (f(), U(
|
|
2883
|
+
})) : k.value ? (f(), U(J, {
|
|
2896
2884
|
key: 1,
|
|
2897
2885
|
"data-testid": "config-card-fetch-error",
|
|
2898
2886
|
"is-error": ""
|
|
2899
2887
|
}, {
|
|
2900
2888
|
message: v(() => [
|
|
2901
|
-
|
|
2889
|
+
P("h3", null, E(_.value), 1)
|
|
2902
2890
|
]),
|
|
2903
2891
|
_: 1
|
|
2904
2892
|
})) : G("", !0),
|
|
2905
|
-
e.config.jsonYamlEnabled ? (f(), A("div",
|
|
2906
|
-
|
|
2893
|
+
e.config.jsonYamlEnabled ? (f(), A("div", ss, [
|
|
2894
|
+
j(Wi, {
|
|
2907
2895
|
format: d.value,
|
|
2908
|
-
"prop-list-types":
|
|
2909
|
-
"property-collections":
|
|
2896
|
+
"prop-list-types": R.value,
|
|
2897
|
+
"property-collections": w.value,
|
|
2910
2898
|
record: p.value
|
|
2911
2899
|
}, Se({ _: 2 }, [
|
|
2912
2900
|
ye(Object.keys(I.$slots), (ee) => ({
|
|
2913
2901
|
name: ee,
|
|
2914
2902
|
fn: v(({ row: te, rowValue: se }) => [
|
|
2915
|
-
|
|
2903
|
+
Z(I.$slots, ee, {
|
|
2916
2904
|
row: te,
|
|
2917
2905
|
rowValue: se
|
|
2918
2906
|
}, void 0, !0)
|
|
2919
2907
|
])
|
|
2920
2908
|
}))
|
|
2921
2909
|
]), 1032, ["format", "prop-list-types", "property-collections", "record"])
|
|
2922
|
-
])) : (f(), A("div",
|
|
2923
|
-
(f(!0), A(ve, null, ye(
|
|
2910
|
+
])) : (f(), A("div", ls, [
|
|
2911
|
+
(f(!0), A(ve, null, ye(R.value, (ee) => (f(), A("div", {
|
|
2924
2912
|
key: `config-card-details-${ee}-props`,
|
|
2925
|
-
class:
|
|
2913
|
+
class: Ke(`config-card-details-${ee}-props`),
|
|
2926
2914
|
"data-testid": `config-card-details-${ee}-props`
|
|
2927
2915
|
}, [
|
|
2928
|
-
ee !== "basic" ? (f(), A("div",
|
|
2929
|
-
(f(!0), A(ve, null, ye(
|
|
2916
|
+
ee !== "basic" ? (f(), A("div", cs, E(ee === "advanced" ? h(a)("baseConfigCard.sections.advanced") : h(a)("baseConfigCard.sections.plugin")), 1)) : G("", !0),
|
|
2917
|
+
(f(!0), A(ve, null, ye(w.value[ee], (te) => (f(), U(St, {
|
|
2930
2918
|
key: te.key,
|
|
2931
2919
|
item: te
|
|
2932
2920
|
}, Se({
|
|
2933
2921
|
label: v(() => [
|
|
2934
|
-
|
|
2922
|
+
Z(I.$slots, `${te.key}-label`, { row: te }, void 0, !0)
|
|
2935
2923
|
]),
|
|
2936
2924
|
[te.key]: v(({ rowValue: se }) => [
|
|
2937
|
-
|
|
2925
|
+
Z(I.$slots, te.key, {
|
|
2938
2926
|
row: te,
|
|
2939
2927
|
rowValue: se
|
|
2940
2928
|
}, void 0, !0)
|
|
@@ -2944,12 +2932,12 @@ const Hi = {
|
|
|
2944
2932
|
H(te) ? {
|
|
2945
2933
|
name: "label-tooltip",
|
|
2946
2934
|
fn: v(() => [
|
|
2947
|
-
|
|
2935
|
+
Z(I.$slots, `${te.key}-label-tooltip`, { row: te }, void 0, !0)
|
|
2948
2936
|
]),
|
|
2949
2937
|
key: "0"
|
|
2950
2938
|
} : void 0
|
|
2951
2939
|
]), 1032, ["item"]))), 128))
|
|
2952
|
-
], 10,
|
|
2940
|
+
], 10, us))), 128))
|
|
2953
2941
|
]))
|
|
2954
2942
|
]),
|
|
2955
2943
|
_: 2
|
|
@@ -2957,9 +2945,9 @@ const Hi = {
|
|
|
2957
2945
|
e.hideTitle ? void 0 : {
|
|
2958
2946
|
name: "title",
|
|
2959
2947
|
fn: v(() => [
|
|
2960
|
-
|
|
2961
|
-
|
|
2962
|
-
|
|
2948
|
+
P("div", os, [
|
|
2949
|
+
Z(I.$slots, "title", {}, () => [
|
|
2950
|
+
Q(E(h(a)("baseConfigCard.title")), 1)
|
|
2963
2951
|
], !0)
|
|
2964
2952
|
])
|
|
2965
2953
|
]),
|
|
@@ -2968,10 +2956,10 @@ const Hi = {
|
|
|
2968
2956
|
]), 1024);
|
|
2969
2957
|
};
|
|
2970
2958
|
}
|
|
2971
|
-
}),
|
|
2959
|
+
}), ps = /* @__PURE__ */ ke(ds, [["__scopeId", "data-v-64349aa2"]]), fs = ["onReset", "onSubmit"], ms = {
|
|
2972
2960
|
class: "form-actions",
|
|
2973
2961
|
"data-testid": "form-actions"
|
|
2974
|
-
},
|
|
2962
|
+
}, gs = /* @__PURE__ */ ie({
|
|
2975
2963
|
__name: "EntityBaseForm",
|
|
2976
2964
|
props: {
|
|
2977
2965
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3023,49 +3011,49 @@ const Hi = {
|
|
|
3023
3011
|
var t;
|
|
3024
3012
|
const r = e, o = wt(), { i18n: { t: a } } = de.useI18n(), { getMessageFromError: i } = de.useErrors(), { axiosInstance: s } = de.useAxios({
|
|
3025
3013
|
headers: (t = r.config) == null ? void 0 : t.requestHeaders
|
|
3026
|
-
}), l =
|
|
3027
|
-
var p,
|
|
3014
|
+
}), l = F(!1), c = F(!1), d = F(""), u = T(() => r.canSubmit === !1 || r.isReadonly), m = T(() => {
|
|
3015
|
+
var p, C;
|
|
3028
3016
|
if (!r.editId)
|
|
3029
3017
|
return "";
|
|
3030
3018
|
let y = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3031
|
-
return r.config.app === "konnect" ? y = y.replace(/{controlPlaneId}/gi, ((p = r.config) == null ? void 0 : p.controlPlaneId) || "") : r.config.app === "kongManager" && (y = y.replace(/\/{workspace}/gi, (
|
|
3032
|
-
}),
|
|
3019
|
+
return r.config.app === "konnect" ? y = y.replace(/{controlPlaneId}/gi, ((p = r.config) == null ? void 0 : p.controlPlaneId) || "") : r.config.app === "kongManager" && (y = y.replace(/\/{workspace}/gi, (C = r.config) != null && C.workspace ? `/${r.config.workspace}` : "")), y = y.replace(/{id}/gi, r.editId), y;
|
|
3020
|
+
}), g = () => {
|
|
3033
3021
|
r.config.cancelRoute ? o.push(r.config.cancelRoute) : k();
|
|
3034
3022
|
}, k = () => {
|
|
3035
3023
|
n("cancel");
|
|
3036
3024
|
}, _ = () => {
|
|
3037
3025
|
u.value || n("submit");
|
|
3038
3026
|
};
|
|
3039
|
-
return
|
|
3027
|
+
return Oe(() => l.value, (p) => {
|
|
3040
3028
|
n("loading", p);
|
|
3041
3029
|
}, { immediate: !0 }), Qe(async () => {
|
|
3042
3030
|
if (r.editId)
|
|
3043
3031
|
try {
|
|
3044
3032
|
c.value = !1, l.value = !0;
|
|
3045
|
-
const { data: p } = await s.get(
|
|
3033
|
+
const { data: p } = await s.get(m.value);
|
|
3046
3034
|
n("fetch:success", p);
|
|
3047
3035
|
} catch (p) {
|
|
3048
|
-
const
|
|
3049
|
-
d.value =
|
|
3036
|
+
const C = i(p);
|
|
3037
|
+
d.value = C.startsWith("code") ? a("baseForm.errors.edit") : C, c.value = !0, n("fetch:error", p);
|
|
3050
3038
|
} finally {
|
|
3051
3039
|
l.value = !1;
|
|
3052
3040
|
}
|
|
3053
|
-
}), (p,
|
|
3054
|
-
const y =
|
|
3041
|
+
}), (p, C) => {
|
|
3042
|
+
const y = N("KSkeleton"), w = N("KEmptyState"), R = N("KAlert"), H = N("KButton"), re = N("KCard");
|
|
3055
3043
|
return f(), U(re, { class: "kong-ui-entity-base-form" }, {
|
|
3056
3044
|
body: v(() => [
|
|
3057
3045
|
l.value ? (f(), U(y, {
|
|
3058
3046
|
key: 0,
|
|
3059
3047
|
type: "form"
|
|
3060
|
-
})) : c.value ? (f(), U(
|
|
3048
|
+
})) : c.value ? (f(), U(w, {
|
|
3061
3049
|
key: 1,
|
|
3062
3050
|
"cta-text": h(a)("baseForm.actions.back"),
|
|
3063
3051
|
"data-testid": "form-fetch-error",
|
|
3064
|
-
"handle-click":
|
|
3052
|
+
"handle-click": g,
|
|
3065
3053
|
"is-error": !0
|
|
3066
3054
|
}, {
|
|
3067
3055
|
message: v(() => [
|
|
3068
|
-
|
|
3056
|
+
P("h3", null, E(d.value), 1)
|
|
3069
3057
|
]),
|
|
3070
3058
|
_: 1
|
|
3071
3059
|
}, 8, ["cta-text"])) : (f(), A("form", {
|
|
@@ -3074,46 +3062,46 @@ const Hi = {
|
|
|
3074
3062
|
onReset: rt(k, ["prevent"]),
|
|
3075
3063
|
onSubmit: rt(_, ["prevent"])
|
|
3076
3064
|
}, [
|
|
3077
|
-
|
|
3078
|
-
e.errorMessage ? (f(), U(
|
|
3065
|
+
Z(p.$slots, "default", {}, void 0, !0),
|
|
3066
|
+
e.errorMessage ? (f(), U(R, {
|
|
3079
3067
|
key: 0,
|
|
3080
3068
|
"alert-message": e.errorMessage,
|
|
3081
3069
|
appearance: "danger",
|
|
3082
3070
|
"data-testid": "form-error"
|
|
3083
3071
|
}, null, 8, ["alert-message"])) : G("", !0),
|
|
3084
|
-
|
|
3085
|
-
|
|
3086
|
-
|
|
3072
|
+
P("div", ms, [
|
|
3073
|
+
Z(p.$slots, "form-actions", {}, () => [
|
|
3074
|
+
j(H, {
|
|
3087
3075
|
appearance: "outline",
|
|
3088
3076
|
"data-testid": "form-cancel",
|
|
3089
3077
|
disabled: e.isReadonly,
|
|
3090
3078
|
type: "reset"
|
|
3091
3079
|
}, {
|
|
3092
3080
|
default: v(() => [
|
|
3093
|
-
|
|
3081
|
+
Q(E(h(a)("baseForm.actions.cancel")), 1)
|
|
3094
3082
|
]),
|
|
3095
3083
|
_: 1
|
|
3096
3084
|
}, 8, ["disabled"]),
|
|
3097
|
-
|
|
3085
|
+
j(H, {
|
|
3098
3086
|
appearance: "primary",
|
|
3099
3087
|
"data-testid": "form-submit",
|
|
3100
3088
|
disabled: u.value,
|
|
3101
3089
|
type: "submit"
|
|
3102
3090
|
}, {
|
|
3103
3091
|
default: v(() => [
|
|
3104
|
-
|
|
3092
|
+
Q(E(h(a)("baseForm.actions.save")), 1)
|
|
3105
3093
|
]),
|
|
3106
3094
|
_: 1
|
|
3107
3095
|
}, 8, ["disabled"])
|
|
3108
3096
|
], !0)
|
|
3109
3097
|
])
|
|
3110
|
-
], 40,
|
|
3098
|
+
], 40, fs))
|
|
3111
3099
|
]),
|
|
3112
3100
|
_: 3
|
|
3113
3101
|
});
|
|
3114
3102
|
};
|
|
3115
3103
|
}
|
|
3116
|
-
}),
|
|
3104
|
+
}), ys = /* @__PURE__ */ ke(gs, [["__scopeId", "data-v-44a90aae"]]), hs = { key: 0 }, vs = /* @__PURE__ */ ie({
|
|
3117
3105
|
__name: "EntityBaseTableCell",
|
|
3118
3106
|
props: {
|
|
3119
3107
|
keyName: {
|
|
@@ -3134,17 +3122,17 @@ const Hi = {
|
|
|
3134
3122
|
return ((_ = t.value) == null ? void 0 : _.querySelector('[role="button"]')) || null;
|
|
3135
3123
|
}), o = T(() => {
|
|
3136
3124
|
var _, p;
|
|
3137
|
-
const
|
|
3138
|
-
return
|
|
3125
|
+
const C = (_ = n.rowEl) == null ? void 0 : _.querySelectorAll("td");
|
|
3126
|
+
return C ? ((p = C[0]) == null ? void 0 : p.getAttribute("data-testid")) === n.keyName : !1;
|
|
3139
3127
|
});
|
|
3140
3128
|
let a;
|
|
3141
3129
|
const i = () => {
|
|
3142
3130
|
a && (a.disconnect(), a = void 0);
|
|
3143
3131
|
}, s = () => {
|
|
3144
|
-
var _, p,
|
|
3145
|
-
c.value = ((_ = r.value) == null ? void 0 : _.getBoundingClientRect().width) || 0, d.value = ((p = t.value) == null ? void 0 : p.clientWidth) || 0, u.value = ((
|
|
3146
|
-
}, l =
|
|
3147
|
-
|
|
3132
|
+
var _, p, C;
|
|
3133
|
+
c.value = ((_ = r.value) == null ? void 0 : _.getBoundingClientRect().width) || 0, d.value = ((p = t.value) == null ? void 0 : p.clientWidth) || 0, u.value = ((C = l.value) == null ? void 0 : C.innerText) || "";
|
|
3134
|
+
}, l = F({}), c = F(0), d = F(0), u = F(""), m = T(() => [r.value, t.value]), g = Oe(
|
|
3135
|
+
m,
|
|
3148
3136
|
(_) => {
|
|
3149
3137
|
if (o.value && (i(), "ResizeObserver" in window && window)) {
|
|
3150
3138
|
a = new ResizeObserver((p) => {
|
|
@@ -3161,34 +3149,34 @@ const Hi = {
|
|
|
3161
3149
|
return dr(() => {
|
|
3162
3150
|
s();
|
|
3163
3151
|
}), pr(() => {
|
|
3164
|
-
|
|
3152
|
+
g();
|
|
3165
3153
|
}), (_, p) => {
|
|
3166
|
-
const
|
|
3154
|
+
const C = N("KTooltip");
|
|
3167
3155
|
return f(), A("span", {
|
|
3168
3156
|
ref_key: "contentRef",
|
|
3169
3157
|
ref: l,
|
|
3170
3158
|
class: "content-wrapper"
|
|
3171
3159
|
}, [
|
|
3172
|
-
o.value ? (f(), A("span",
|
|
3173
|
-
|
|
3160
|
+
o.value ? (f(), A("span", hs, [
|
|
3161
|
+
j(C, {
|
|
3174
3162
|
disabled: !k.value,
|
|
3175
3163
|
label: u.value,
|
|
3176
3164
|
"max-width": "300",
|
|
3177
3165
|
placement: "bottomStart"
|
|
3178
3166
|
}, {
|
|
3179
3167
|
default: v(() => [
|
|
3180
|
-
|
|
3168
|
+
Z(_.$slots, "default", {}, void 0, !0)
|
|
3181
3169
|
]),
|
|
3182
3170
|
_: 3
|
|
3183
3171
|
}, 8, ["disabled", "label"])
|
|
3184
|
-
])) :
|
|
3172
|
+
])) : Z(_.$slots, "default", { key: 1 }, void 0, !0)
|
|
3185
3173
|
], 512);
|
|
3186
3174
|
};
|
|
3187
3175
|
}
|
|
3188
|
-
}),
|
|
3176
|
+
}), bs = /* @__PURE__ */ ke(vs, [["__scopeId", "data-v-f8a220e9"]]), Cs = { class: "toolbar-container" }, ks = {
|
|
3189
3177
|
key: 0,
|
|
3190
3178
|
class: "toolbar-button-container"
|
|
3191
|
-
},
|
|
3179
|
+
}, _s = ["data-testid"], ws = /* @__PURE__ */ ie({
|
|
3192
3180
|
__name: "EntityBaseTable",
|
|
3193
3181
|
props: {
|
|
3194
3182
|
// table header configuration
|
|
@@ -3297,61 +3285,61 @@ const Hi = {
|
|
|
3297
3285
|
},
|
|
3298
3286
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked"],
|
|
3299
3287
|
setup(e, { emit: n }) {
|
|
3300
|
-
const t = e, { i18n: { t: r } } = de.useI18n(), o = T(() => t.cacheIdentifier || t.preferencesStorageKey), a = (
|
|
3301
|
-
const
|
|
3302
|
-
return Object.keys(t.tableHeaders).forEach((
|
|
3303
|
-
const H = t.tableHeaders[
|
|
3304
|
-
|
|
3305
|
-
label: H.label ??
|
|
3306
|
-
key:
|
|
3288
|
+
const t = e, { i18n: { t: r } } = de.useI18n(), o = T(() => t.cacheIdentifier || t.preferencesStorageKey), a = (w) => w.hasData || !!t.query, i = T(() => {
|
|
3289
|
+
const w = [];
|
|
3290
|
+
return Object.keys(t.tableHeaders).forEach((R) => {
|
|
3291
|
+
const H = t.tableHeaders[R];
|
|
3292
|
+
w.push({
|
|
3293
|
+
label: H.label ?? R,
|
|
3294
|
+
key: R,
|
|
3307
3295
|
sortable: H.sortable ?? !1
|
|
3308
3296
|
});
|
|
3309
|
-
}), t.enableEntityActions &&
|
|
3297
|
+
}), t.enableEntityActions && w.push({
|
|
3310
3298
|
key: "actions",
|
|
3311
3299
|
hideLabel: !0
|
|
3312
|
-
}),
|
|
3313
|
-
}), s = (
|
|
3314
|
-
"data-rowid":
|
|
3315
|
-
"data-testid":
|
|
3316
|
-
...t.rowAttributes(
|
|
3317
|
-
}), l =
|
|
3318
|
-
var
|
|
3319
|
-
return (
|
|
3320
|
-
}, d = (
|
|
3321
|
-
const
|
|
3322
|
-
"data-testid":
|
|
3323
|
-
...t.cellAttributes(
|
|
3300
|
+
}), w;
|
|
3301
|
+
}), s = (w) => ({
|
|
3302
|
+
"data-rowid": w.id,
|
|
3303
|
+
"data-testid": w.name,
|
|
3304
|
+
...t.rowAttributes(w)
|
|
3305
|
+
}), l = F({}), c = (w) => {
|
|
3306
|
+
var R;
|
|
3307
|
+
return (R = l.value) == null ? void 0 : R.$el.querySelector(`[data-rowid="${w.id}"]`);
|
|
3308
|
+
}, d = (w) => {
|
|
3309
|
+
const R = {
|
|
3310
|
+
"data-testid": w.headerKey,
|
|
3311
|
+
...t.cellAttributes(w)
|
|
3324
3312
|
};
|
|
3325
|
-
return
|
|
3313
|
+
return w.colIndex === 0 && (R.style = {
|
|
3326
3314
|
maxWidth: "250px",
|
|
3327
3315
|
overflowX: "hidden",
|
|
3328
3316
|
textOverflow: "ellipsis"
|
|
3329
|
-
}),
|
|
3317
|
+
}), R;
|
|
3330
3318
|
}, u = () => {
|
|
3331
|
-
n("empty-state-cta-clicked"),
|
|
3332
|
-
},
|
|
3319
|
+
n("empty-state-cta-clicked"), m();
|
|
3320
|
+
}, m = () => {
|
|
3333
3321
|
n("clear-search-input");
|
|
3334
|
-
},
|
|
3335
|
-
n("click:row",
|
|
3336
|
-
}), k = (
|
|
3337
|
-
n("sort",
|
|
3338
|
-
}, { setTablePreferences: _, getTablePreferences: p } = Ir(),
|
|
3339
|
-
const
|
|
3322
|
+
}, g = T(() => t.disableRowClick ? void 0 : (w, R) => {
|
|
3323
|
+
n("click:row", R);
|
|
3324
|
+
}), k = (w) => {
|
|
3325
|
+
n("sort", w);
|
|
3326
|
+
}, { setTablePreferences: _, getTablePreferences: p } = Ir(), C = T(() => {
|
|
3327
|
+
const w = p(t.preferencesStorageKey);
|
|
3340
3328
|
return {
|
|
3341
3329
|
...t.initialFetcherParams,
|
|
3342
|
-
...
|
|
3330
|
+
...w
|
|
3343
3331
|
};
|
|
3344
|
-
}), y = (
|
|
3345
|
-
t.preferencesStorageKey && _(t.preferencesStorageKey,
|
|
3332
|
+
}), y = (w) => {
|
|
3333
|
+
t.preferencesStorageKey && _(t.preferencesStorageKey, w);
|
|
3346
3334
|
};
|
|
3347
|
-
return (
|
|
3348
|
-
const H =
|
|
3349
|
-
return f(), U(
|
|
3335
|
+
return (w, R) => {
|
|
3336
|
+
const H = N("KIcon"), re = N("KButton"), z = N("KDropdownMenu"), I = N("KTable"), V = N("KCard");
|
|
3337
|
+
return f(), U(V, {
|
|
3350
3338
|
class: "kong-ui-entity-base-table",
|
|
3351
3339
|
title: e.title
|
|
3352
3340
|
}, {
|
|
3353
3341
|
body: v(() => [
|
|
3354
|
-
|
|
3342
|
+
j(I, {
|
|
3355
3343
|
ref_key: "tableRefs",
|
|
3356
3344
|
ref: l,
|
|
3357
3345
|
"cache-identifier": o.value,
|
|
@@ -3372,50 +3360,50 @@ const Hi = {
|
|
|
3372
3360
|
"has-error": !!e.errorMessage,
|
|
3373
3361
|
headers: i.value,
|
|
3374
3362
|
"hide-pagination-when-optional": "",
|
|
3375
|
-
"initial-fetcher-params":
|
|
3363
|
+
"initial-fetcher-params": C.value,
|
|
3376
3364
|
"is-loading": e.isLoading,
|
|
3377
3365
|
"pagination-type": e.paginationType,
|
|
3378
3366
|
"row-attrs": s,
|
|
3379
3367
|
"search-input": e.query,
|
|
3380
3368
|
onKtableEmptyStateCtaClicked: u,
|
|
3381
|
-
"onRow:click":
|
|
3382
|
-
onSort:
|
|
3369
|
+
"onRow:click": g.value,
|
|
3370
|
+
onSort: R[0] || (R[0] = (q) => k(q)),
|
|
3383
3371
|
"onUpdate:tablePreferences": y
|
|
3384
3372
|
}, Se({
|
|
3385
|
-
toolbar: v(({ state:
|
|
3386
|
-
et(
|
|
3387
|
-
|
|
3388
|
-
|
|
3389
|
-
|
|
3373
|
+
toolbar: v(({ state: q }) => [
|
|
3374
|
+
et(P("div", Cs, [
|
|
3375
|
+
Z(w.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3376
|
+
w.$slots["toolbar-button"] ? (f(), A("div", ks, [
|
|
3377
|
+
Z(w.$slots, "toolbar-button", {}, void 0, !0)
|
|
3390
3378
|
])) : G("", !0)
|
|
3391
3379
|
], 512), [
|
|
3392
|
-
[tt, a(
|
|
3380
|
+
[tt, a(q)]
|
|
3393
3381
|
])
|
|
3394
3382
|
]),
|
|
3395
|
-
actions: v(({ row:
|
|
3396
|
-
|
|
3383
|
+
actions: v(({ row: q, rowKey: x, rowValue: O }) => [
|
|
3384
|
+
P("div", {
|
|
3397
3385
|
class: "actions-container",
|
|
3398
|
-
"data-testid":
|
|
3386
|
+
"data-testid": q.name
|
|
3399
3387
|
}, [
|
|
3400
|
-
|
|
3388
|
+
j(z, {
|
|
3401
3389
|
"kpop-attributes": { placement: "bottomEnd" },
|
|
3402
3390
|
width: e.dropdownMenuWidth
|
|
3403
3391
|
}, {
|
|
3404
3392
|
items: v(() => [
|
|
3405
|
-
|
|
3406
|
-
row:
|
|
3393
|
+
Z(w.$slots, "actions", {
|
|
3394
|
+
row: q,
|
|
3407
3395
|
rowKey: x,
|
|
3408
|
-
rowValue:
|
|
3396
|
+
rowValue: O
|
|
3409
3397
|
}, void 0, !0)
|
|
3410
3398
|
]),
|
|
3411
3399
|
default: v(() => [
|
|
3412
|
-
|
|
3400
|
+
j(re, {
|
|
3413
3401
|
class: "actions-trigger",
|
|
3414
3402
|
"data-testid": "overflow-actions-button",
|
|
3415
3403
|
size: "small"
|
|
3416
3404
|
}, {
|
|
3417
3405
|
icon: v(() => [
|
|
3418
|
-
|
|
3406
|
+
j(H, {
|
|
3419
3407
|
color: h(so),
|
|
3420
3408
|
icon: "more",
|
|
3421
3409
|
size: "16"
|
|
@@ -3426,24 +3414,24 @@ const Hi = {
|
|
|
3426
3414
|
]),
|
|
3427
3415
|
_: 2
|
|
3428
3416
|
}, 1032, ["width"])
|
|
3429
|
-
], 8,
|
|
3417
|
+
], 8, _s)
|
|
3430
3418
|
]),
|
|
3431
3419
|
_: 2
|
|
3432
3420
|
}, [
|
|
3433
|
-
ye(e.tableHeaders, (
|
|
3421
|
+
ye(e.tableHeaders, (q, x) => ({
|
|
3434
3422
|
name: x,
|
|
3435
|
-
fn: v(({ row:
|
|
3436
|
-
|
|
3423
|
+
fn: v(({ row: O, rowKey: M, rowValue: K }) => [
|
|
3424
|
+
j(bs, {
|
|
3437
3425
|
"key-name": String(x),
|
|
3438
|
-
"row-el": c(
|
|
3426
|
+
"row-el": c(O)
|
|
3439
3427
|
}, {
|
|
3440
3428
|
default: v(() => [
|
|
3441
|
-
|
|
3442
|
-
row:
|
|
3443
|
-
rowKey:
|
|
3429
|
+
Z(w.$slots, x, {
|
|
3430
|
+
row: O,
|
|
3431
|
+
rowKey: M,
|
|
3444
3432
|
rowValue: K
|
|
3445
3433
|
}, () => [
|
|
3446
|
-
|
|
3434
|
+
Q(E(K), 1)
|
|
3447
3435
|
], !0)
|
|
3448
3436
|
]),
|
|
3449
3437
|
_: 2
|
|
@@ -3456,13 +3444,13 @@ const Hi = {
|
|
|
3456
3444
|
}, 8, ["title"]);
|
|
3457
3445
|
};
|
|
3458
3446
|
}
|
|
3459
|
-
}),
|
|
3447
|
+
}), Is = /* @__PURE__ */ ke(ws, [["__scopeId", "data-v-6bf92df6"]]), xs = {
|
|
3460
3448
|
key: 0,
|
|
3461
3449
|
class: "kong-ui-entity-delete-error"
|
|
3462
|
-
},
|
|
3450
|
+
}, As = {
|
|
3463
3451
|
key: 1,
|
|
3464
3452
|
class: "description"
|
|
3465
|
-
},
|
|
3453
|
+
}, Ss = /* @__PURE__ */ ie({
|
|
3466
3454
|
__name: "EntityDeleteModal",
|
|
3467
3455
|
props: {
|
|
3468
3456
|
visible: {
|
|
@@ -3507,7 +3495,7 @@ const Hi = {
|
|
|
3507
3495
|
n("proceed");
|
|
3508
3496
|
};
|
|
3509
3497
|
return (s, l) => {
|
|
3510
|
-
const c =
|
|
3498
|
+
const c = N("KAlert"), d = N("KPrompt");
|
|
3511
3499
|
return f(), U(d, {
|
|
3512
3500
|
"action-button-text": "Yes, delete",
|
|
3513
3501
|
"action-pending": e.actionPending,
|
|
@@ -3520,35 +3508,35 @@ const Hi = {
|
|
|
3520
3508
|
onProceed: i
|
|
3521
3509
|
}, {
|
|
3522
3510
|
"body-content": v(() => [
|
|
3523
|
-
e.error ? (f(), A("div",
|
|
3524
|
-
|
|
3511
|
+
e.error ? (f(), A("div", xs, [
|
|
3512
|
+
j(c, { appearance: "danger" }, {
|
|
3525
3513
|
alertMessage: v(() => [
|
|
3526
|
-
|
|
3514
|
+
Q(E(e.error), 1)
|
|
3527
3515
|
]),
|
|
3528
3516
|
_: 1
|
|
3529
3517
|
})
|
|
3530
3518
|
])) : G("", !0),
|
|
3531
|
-
|
|
3519
|
+
j(h(r), {
|
|
3532
3520
|
class: "message",
|
|
3533
3521
|
keypath: t.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
3534
3522
|
tag: "p"
|
|
3535
3523
|
}, Se({
|
|
3536
3524
|
entityType: v(() => [
|
|
3537
|
-
|
|
3525
|
+
Q(E(t.entityType), 1)
|
|
3538
3526
|
]),
|
|
3539
3527
|
_: 2
|
|
3540
3528
|
}, [
|
|
3541
3529
|
t.entityName ? {
|
|
3542
3530
|
name: "entityName",
|
|
3543
3531
|
fn: v(() => [
|
|
3544
|
-
|
|
3532
|
+
P("strong", null, E(t.entityName), 1)
|
|
3545
3533
|
]),
|
|
3546
3534
|
key: "0"
|
|
3547
3535
|
} : void 0
|
|
3548
3536
|
]), 1032, ["keypath"]),
|
|
3549
|
-
t.description || s.$slots.description ? (f(), A("div",
|
|
3550
|
-
|
|
3551
|
-
|
|
3537
|
+
t.description || s.$slots.description ? (f(), A("div", As, [
|
|
3538
|
+
Z(s.$slots, "description", {}, () => [
|
|
3539
|
+
P("p", null, E(t.description), 1)
|
|
3552
3540
|
], !0)
|
|
3553
3541
|
])) : G("", !0)
|
|
3554
3542
|
]),
|
|
@@ -3556,13 +3544,13 @@ const Hi = {
|
|
|
3556
3544
|
}, 8, ["action-pending", "confirmation-text", "is-visible", "title"]);
|
|
3557
3545
|
};
|
|
3558
3546
|
}
|
|
3559
|
-
}),
|
|
3547
|
+
}), Ts = /* @__PURE__ */ ke(Ss, [["__scopeId", "data-v-1c9a2a07"]]), $s = {
|
|
3560
3548
|
fill: "none",
|
|
3561
3549
|
height: "20",
|
|
3562
3550
|
viewBox: "0 0 20 20",
|
|
3563
3551
|
width: "20",
|
|
3564
3552
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3565
|
-
},
|
|
3553
|
+
}, Ms = {
|
|
3566
3554
|
id: "mask0_180_20349",
|
|
3567
3555
|
height: "20",
|
|
3568
3556
|
maskUnits: "userSpaceOnUse",
|
|
@@ -3570,7 +3558,7 @@ const Hi = {
|
|
|
3570
3558
|
width: "20",
|
|
3571
3559
|
x: "0",
|
|
3572
3560
|
y: "0"
|
|
3573
|
-
}, Os = ["fill"],
|
|
3561
|
+
}, Os = ["fill"], Es = { mask: "url(#mask0_180_20349)" }, js = ["fill"], Fs = /* @__PURE__ */ ie({
|
|
3574
3562
|
__name: "IconFilter",
|
|
3575
3563
|
props: {
|
|
3576
3564
|
color: {
|
|
@@ -3579,26 +3567,26 @@ const Hi = {
|
|
|
3579
3567
|
}
|
|
3580
3568
|
},
|
|
3581
3569
|
setup(e) {
|
|
3582
|
-
return (n, t) => (f(), A("svg",
|
|
3583
|
-
|
|
3584
|
-
|
|
3570
|
+
return (n, t) => (f(), A("svg", $s, [
|
|
3571
|
+
P("mask", Ms, [
|
|
3572
|
+
P("rect", {
|
|
3585
3573
|
fill: e.color,
|
|
3586
3574
|
height: "20",
|
|
3587
3575
|
width: "20"
|
|
3588
3576
|
}, null, 8, Os)
|
|
3589
3577
|
]),
|
|
3590
|
-
|
|
3591
|
-
|
|
3578
|
+
P("g", Es, [
|
|
3579
|
+
P("path", {
|
|
3592
3580
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3593
3581
|
fill: e.color
|
|
3594
|
-
}, null, 8,
|
|
3582
|
+
}, null, 8, js)
|
|
3595
3583
|
])
|
|
3596
3584
|
]));
|
|
3597
3585
|
}
|
|
3598
|
-
}),
|
|
3586
|
+
}), Ks = {
|
|
3599
3587
|
key: 1,
|
|
3600
3588
|
class: "kong-ui-entity-filter"
|
|
3601
|
-
},
|
|
3589
|
+
}, Bs = { class: "menu-item-title" }, Ns = { class: "menu-item-indicator" }, Ls = { class: "menu-item-body" }, qs = ["for"], Ps = { class: "menu-item-buttons" }, Us = /* @__PURE__ */ ie({
|
|
3602
3590
|
__name: "EntityFilter",
|
|
3603
3591
|
props: {
|
|
3604
3592
|
// filter config, either exact match or fuzzy match
|
|
@@ -3618,21 +3606,21 @@ const Hi = {
|
|
|
3618
3606
|
},
|
|
3619
3607
|
emits: ["update:modelValue"],
|
|
3620
3608
|
setup(e, { emit: n }) {
|
|
3621
|
-
const t = e, { i18n: { t: r } } = de.useI18n(), o =
|
|
3609
|
+
const t = e, { i18n: { t: r } } = de.useI18n(), o = F(!1), a = F({}), i = T(() => {
|
|
3622
3610
|
const p = [];
|
|
3623
|
-
return new URLSearchParams(t.modelValue).forEach((
|
|
3624
|
-
|
|
3611
|
+
return new URLSearchParams(t.modelValue).forEach((C, y) => {
|
|
3612
|
+
C !== "" && p.push(y);
|
|
3625
3613
|
}), p;
|
|
3626
3614
|
}), s = T(() => {
|
|
3627
3615
|
const p = t.config.fields;
|
|
3628
|
-
return Object.keys(p).filter((
|
|
3629
|
-
label: p[
|
|
3630
|
-
value:
|
|
3616
|
+
return Object.keys(p).filter((C) => p[C].searchable).map((C) => ({
|
|
3617
|
+
label: p[C].label || C,
|
|
3618
|
+
value: C
|
|
3631
3619
|
}));
|
|
3632
3620
|
});
|
|
3633
|
-
|
|
3634
|
-
a.value = {}, new URLSearchParams(p).forEach((
|
|
3635
|
-
a.value[y] =
|
|
3621
|
+
Oe(() => t.modelValue, (p) => {
|
|
3622
|
+
a.value = {}, new URLSearchParams(p).forEach((C, y) => {
|
|
3623
|
+
a.value[y] = C;
|
|
3636
3624
|
});
|
|
3637
3625
|
});
|
|
3638
3626
|
const l = () => {
|
|
@@ -3640,15 +3628,15 @@ const Hi = {
|
|
|
3640
3628
|
}, c = (p) => {
|
|
3641
3629
|
n("update:modelValue", p);
|
|
3642
3630
|
}, d = (p) => `filter-${p}`, u = (p) => {
|
|
3643
|
-
var
|
|
3644
|
-
return (((y = (
|
|
3645
|
-
value:
|
|
3646
|
-
label:
|
|
3631
|
+
var C, y;
|
|
3632
|
+
return (((y = (C = t.config.schema) == null ? void 0 : C[p]) == null ? void 0 : y.values) ?? []).map((w) => ({
|
|
3633
|
+
value: w,
|
|
3634
|
+
label: w
|
|
3647
3635
|
}));
|
|
3648
|
-
}, g = (p) => {
|
|
3649
|
-
var w, y;
|
|
3650
|
-
return ((y = (w = t.config.schema) == null ? void 0 : w[p]) == null ? void 0 : y.type) ?? "text";
|
|
3651
3636
|
}, m = (p) => {
|
|
3637
|
+
var C, y;
|
|
3638
|
+
return ((y = (C = t.config.schema) == null ? void 0 : C[p]) == null ? void 0 : y.type) ?? "text";
|
|
3639
|
+
}, g = (p) => {
|
|
3652
3640
|
a.value = {
|
|
3653
3641
|
...a.value,
|
|
3654
3642
|
[p]: ""
|
|
@@ -3656,11 +3644,11 @@ const Hi = {
|
|
|
3656
3644
|
}, k = () => {
|
|
3657
3645
|
a.value = {}, _(!0);
|
|
3658
3646
|
}, _ = (p = !1) => {
|
|
3659
|
-
const
|
|
3660
|
-
p && (o.value = !1), n("update:modelValue", new URLSearchParams(
|
|
3647
|
+
const C = Object.keys(a.value).reduce((y, w) => (a.value[w] && (y[w] = `${a.value[w]}`), y), {});
|
|
3648
|
+
p && (o.value = !1), n("update:modelValue", new URLSearchParams(C).toString());
|
|
3661
3649
|
};
|
|
3662
|
-
return (p,
|
|
3663
|
-
const y =
|
|
3650
|
+
return (p, C) => {
|
|
3651
|
+
const y = N("KInput"), w = N("KButton"), R = N("KSelect"), H = N("KMenuItem"), re = N("KMenu");
|
|
3664
3652
|
return e.config.isExactMatch ? (f(), U(y, {
|
|
3665
3653
|
key: 0,
|
|
3666
3654
|
autocomplete: "off",
|
|
@@ -3671,28 +3659,28 @@ const Hi = {
|
|
|
3671
3659
|
"onUpdate:modelValue": c
|
|
3672
3660
|
}, {
|
|
3673
3661
|
icon: v(() => [
|
|
3674
|
-
|
|
3662
|
+
j(Fs)
|
|
3675
3663
|
]),
|
|
3676
3664
|
_: 1
|
|
3677
|
-
}, 8, ["model-value", "placeholder"])) : (f(), A("div",
|
|
3678
|
-
|
|
3665
|
+
}, 8, ["model-value", "placeholder"])) : (f(), A("div", Ks, [
|
|
3666
|
+
j(w, {
|
|
3679
3667
|
appearance: "btn-link",
|
|
3680
3668
|
"data-testid": "filter-button",
|
|
3681
3669
|
icon: "filter",
|
|
3682
3670
|
onClick: l
|
|
3683
3671
|
}, {
|
|
3684
3672
|
default: v(() => [
|
|
3685
|
-
|
|
3673
|
+
Q(E(h(r)("filter.filterButtonText")) + " " + E(i.value.length > 0 ? `(${i.value.length})` : ""), 1)
|
|
3686
3674
|
]),
|
|
3687
3675
|
_: 1
|
|
3688
3676
|
}),
|
|
3689
|
-
et(
|
|
3677
|
+
et(P("div", {
|
|
3690
3678
|
class: "kong-ui-entity-filter-backdrop",
|
|
3691
3679
|
onClick: l
|
|
3692
3680
|
}, null, 512), [
|
|
3693
3681
|
[tt, o.value]
|
|
3694
3682
|
]),
|
|
3695
|
-
et(
|
|
3683
|
+
et(j(re, { class: "kong-ui-entity-filter-menu" }, {
|
|
3696
3684
|
body: v(() => [
|
|
3697
3685
|
(f(!0), A(ve, null, ye(s.value, (z, I) => (f(), U(H, {
|
|
3698
3686
|
key: z.value,
|
|
@@ -3701,22 +3689,22 @@ const Hi = {
|
|
|
3701
3689
|
"last-menu-item": I === s.value.length - 1
|
|
3702
3690
|
}, {
|
|
3703
3691
|
itemTitle: v(() => [
|
|
3704
|
-
|
|
3705
|
-
|
|
3706
|
-
et(
|
|
3692
|
+
P("span", Bs, [
|
|
3693
|
+
Q(E(z.label) + " ", 1),
|
|
3694
|
+
et(P("span", Ns, null, 512), [
|
|
3707
3695
|
[tt, i.value.includes(z.value)]
|
|
3708
3696
|
])
|
|
3709
3697
|
])
|
|
3710
3698
|
]),
|
|
3711
3699
|
itemBody: v(() => {
|
|
3712
|
-
var
|
|
3700
|
+
var V, q;
|
|
3713
3701
|
return [
|
|
3714
|
-
|
|
3715
|
-
|
|
3702
|
+
P("div", Ls, [
|
|
3703
|
+
P("label", {
|
|
3716
3704
|
class: "menu-item-label",
|
|
3717
3705
|
for: d(z.value)
|
|
3718
|
-
},
|
|
3719
|
-
((
|
|
3706
|
+
}, E(h(r)("filter.fieldLabel")), 9, qs),
|
|
3707
|
+
((q = (V = e.config.schema) == null ? void 0 : V[z.value]) == null ? void 0 : q.type) === "select" ? (f(), U(R, {
|
|
3720
3708
|
key: 0,
|
|
3721
3709
|
id: d(z.value),
|
|
3722
3710
|
modelValue: a.value[z.value],
|
|
@@ -3732,29 +3720,29 @@ const Hi = {
|
|
|
3732
3720
|
autocomplete: "off",
|
|
3733
3721
|
placeholder: h(r)("filter.inputPlaceholder"),
|
|
3734
3722
|
size: "small",
|
|
3735
|
-
type:
|
|
3723
|
+
type: m(z.value)
|
|
3736
3724
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3737
3725
|
]),
|
|
3738
|
-
|
|
3739
|
-
|
|
3726
|
+
P("div", Ps, [
|
|
3727
|
+
j(w, {
|
|
3740
3728
|
appearance: "btn-link",
|
|
3741
3729
|
"data-testid": "apply-filter",
|
|
3742
3730
|
size: "small",
|
|
3743
|
-
onClick:
|
|
3731
|
+
onClick: C[0] || (C[0] = (x) => _(!0))
|
|
3744
3732
|
}, {
|
|
3745
3733
|
default: v(() => [
|
|
3746
|
-
|
|
3734
|
+
Q(E(h(r)("filter.applyButtonText")), 1)
|
|
3747
3735
|
]),
|
|
3748
3736
|
_: 1
|
|
3749
3737
|
}),
|
|
3750
|
-
|
|
3738
|
+
j(w, {
|
|
3751
3739
|
appearance: "btn-link",
|
|
3752
3740
|
"data-testid": "clear-filter",
|
|
3753
3741
|
size: "small",
|
|
3754
|
-
onClick: (x) =>
|
|
3742
|
+
onClick: (x) => g(z.value)
|
|
3755
3743
|
}, {
|
|
3756
3744
|
default: v(() => [
|
|
3757
|
-
|
|
3745
|
+
Q(E(h(r)("filter.clearButtonText")), 1)
|
|
3758
3746
|
]),
|
|
3759
3747
|
_: 2
|
|
3760
3748
|
}, 1032, ["onClick"])
|
|
@@ -3765,9 +3753,9 @@ const Hi = {
|
|
|
3765
3753
|
}, 1032, ["data-testid", "last-menu-item"]))), 128))
|
|
3766
3754
|
]),
|
|
3767
3755
|
actionButton: v(() => [
|
|
3768
|
-
|
|
3756
|
+
j(w, { onClick: k }, {
|
|
3769
3757
|
default: v(() => [
|
|
3770
|
-
|
|
3758
|
+
Q(E(h(r)("filter.clearAllButtonText")), 1)
|
|
3771
3759
|
]),
|
|
3772
3760
|
_: 1
|
|
3773
3761
|
})
|
|
@@ -3779,7 +3767,7 @@ const Hi = {
|
|
|
3779
3767
|
]));
|
|
3780
3768
|
};
|
|
3781
3769
|
}
|
|
3782
|
-
}),
|
|
3770
|
+
}), Rs = /* @__PURE__ */ ke(Us, [["__scopeId", "data-v-745f38c0"]]), Xe = /* @__PURE__ */ ie({
|
|
3783
3771
|
__name: "PermissionsWrapper",
|
|
3784
3772
|
props: {
|
|
3785
3773
|
/**
|
|
@@ -3801,24 +3789,24 @@ const Hi = {
|
|
|
3801
3789
|
}
|
|
3802
3790
|
},
|
|
3803
3791
|
setup(e) {
|
|
3804
|
-
const n = e, t =
|
|
3805
|
-
return
|
|
3792
|
+
const n = e, t = F(void 0), r = T(() => t.value === !0 || t.value !== void 0 && n.forceShow === !0);
|
|
3793
|
+
return Oe(() => n.authFunction, async () => {
|
|
3806
3794
|
t.value = await n.authFunction();
|
|
3807
|
-
}, { immediate: !0 }), (o, a) => r.value ?
|
|
3795
|
+
}, { immediate: !0 }), (o, a) => r.value ? Z(o.$slots, "default", {
|
|
3808
3796
|
key: 0,
|
|
3809
3797
|
isAllowed: t.value
|
|
3810
3798
|
}) : G("", !0);
|
|
3811
3799
|
}
|
|
3812
|
-
}),
|
|
3800
|
+
}), Vs = { class: "form-section-wrapper" }, Ds = {
|
|
3813
3801
|
key: 0,
|
|
3814
3802
|
class: "form-section-title"
|
|
3815
|
-
},
|
|
3803
|
+
}, Gs = {
|
|
3816
3804
|
key: 1,
|
|
3817
3805
|
class: "form-section-description"
|
|
3818
|
-
},
|
|
3806
|
+
}, Hs = {
|
|
3819
3807
|
key: 2,
|
|
3820
3808
|
class: "form-section-footer"
|
|
3821
|
-
},
|
|
3809
|
+
}, zs = { class: "form-section-content" }, Ys = /* @__PURE__ */ ie({
|
|
3822
3810
|
__name: "EntityFormSection",
|
|
3823
3811
|
props: {
|
|
3824
3812
|
title: {
|
|
@@ -3845,34 +3833,34 @@ const Hi = {
|
|
|
3845
3833
|
setup(e) {
|
|
3846
3834
|
const n = ut();
|
|
3847
3835
|
return (t, r) => (f(), A("fieldset", {
|
|
3848
|
-
class:
|
|
3836
|
+
class: Ke(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }])
|
|
3849
3837
|
}, [
|
|
3850
|
-
|
|
3838
|
+
P("div", Vs, [
|
|
3851
3839
|
e.hideInfoHeader ? G("", !0) : (f(), A("div", {
|
|
3852
3840
|
key: 0,
|
|
3853
|
-
class:
|
|
3841
|
+
class: Ke(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
3854
3842
|
}, [
|
|
3855
|
-
e.title ? (f(), A("h4",
|
|
3856
|
-
e.description || h(n).description ? (f(), A("div",
|
|
3857
|
-
|
|
3858
|
-
|
|
3843
|
+
e.title ? (f(), A("h4", Ds, E(e.title), 1)) : G("", !0),
|
|
3844
|
+
e.description || h(n).description ? (f(), A("div", Gs, [
|
|
3845
|
+
Z(t.$slots, "description", {}, () => [
|
|
3846
|
+
P("p", null, E(e.description), 1)
|
|
3859
3847
|
], !0)
|
|
3860
3848
|
])) : G("", !0),
|
|
3861
|
-
h(n).footer ? (f(), A("div",
|
|
3862
|
-
|
|
3849
|
+
h(n).footer ? (f(), A("div", Hs, [
|
|
3850
|
+
Z(t.$slots, "footer", {}, void 0, !0)
|
|
3863
3851
|
])) : G("", !0)
|
|
3864
3852
|
], 2)),
|
|
3865
|
-
|
|
3866
|
-
|
|
3853
|
+
P("div", zs, [
|
|
3854
|
+
Z(t.$slots, "default", {}, void 0, !0)
|
|
3867
3855
|
])
|
|
3868
3856
|
])
|
|
3869
3857
|
], 2));
|
|
3870
3858
|
}
|
|
3871
|
-
}), un = /* @__PURE__ */ ke(
|
|
3872
|
-
const
|
|
3859
|
+
}), un = /* @__PURE__ */ ke(Ys, [["__scopeId", "data-v-8b6dc312"]]), { useAxios: Ft, useDeleteUrlBuilder: Js, useErrors: Ws, useFetchUrlBuilder: hl, useFetcher: Zs, useDebouncedFilter: or, useStringHelpers: vl, useHelpers: bl, useGatewayFeatureSupported: Cl } = de;
|
|
3860
|
+
const Qs = { class: "add-to-group-form-container" }, Xs = { class: "add-to-group-cta-text" }, el = {
|
|
3873
3861
|
key: 0,
|
|
3874
3862
|
class: "kong-ui-entity-add-to-groups-error"
|
|
3875
|
-
},
|
|
3863
|
+
}, tl = { key: 0 }, nl = /* @__PURE__ */ ie({
|
|
3876
3864
|
__name: "AddToGroupModal",
|
|
3877
3865
|
props: {
|
|
3878
3866
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3889,10 +3877,10 @@ const el = { class: "add-to-group-form-container" }, tl = { class: "add-to-group
|
|
|
3889
3877
|
},
|
|
3890
3878
|
emits: ["cancel", "add:success", "add:partial-success", "error"],
|
|
3891
3879
|
setup(e, { emit: n }) {
|
|
3892
|
-
var
|
|
3880
|
+
var q;
|
|
3893
3881
|
const t = e, { i18n: { t: r } } = ct.useI18n(), { axiosInstance: o } = Ft({
|
|
3894
|
-
headers: (
|
|
3895
|
-
}), a =
|
|
3882
|
+
headers: (q = t.config) == null ? void 0 : q.requestHeaders
|
|
3883
|
+
}), a = F([]), {
|
|
3896
3884
|
debouncedQueryChange: i,
|
|
3897
3885
|
loading: s,
|
|
3898
3886
|
allRecords: l,
|
|
@@ -3907,77 +3895,77 @@ const el = { class: "add-to-group-form-container" }, tl = { class: "add-to-group
|
|
|
3907
3895
|
fetchedItemsKey: "data",
|
|
3908
3896
|
searchKeys: ["name", "id"]
|
|
3909
3897
|
}
|
|
3910
|
-
),
|
|
3898
|
+
), m = T(() => c.value ? r("consumer_groups.errors.general") : ""), g = F(0), k = T(() => l.value === void 0), _ = T(() => u.value.map((x) => ({
|
|
3911
3899
|
label: x.name,
|
|
3912
3900
|
value: x.id,
|
|
3913
3901
|
selected: a.value.includes(x.id),
|
|
3914
3902
|
data: x
|
|
3915
3903
|
// we need this to determine whether or not to show the description text
|
|
3916
3904
|
}))), p = (x) => {
|
|
3917
|
-
var
|
|
3918
|
-
const
|
|
3919
|
-
return
|
|
3920
|
-
},
|
|
3921
|
-
|
|
3922
|
-
}, y =
|
|
3905
|
+
var M;
|
|
3906
|
+
const O = k.value ? u.value.find((K) => K.id === x) : (M = l.value) == null ? void 0 : M.find((K) => K.id === x);
|
|
3907
|
+
return O ? O.name : x;
|
|
3908
|
+
}, C = () => {
|
|
3909
|
+
R.value = "", y.value = [], I.value = [], n("cancel");
|
|
3910
|
+
}, y = F([]), w = F(!1), R = F(""), H = async () => {
|
|
3923
3911
|
if (!a.value.length) {
|
|
3924
|
-
|
|
3912
|
+
R.value = "", I.value = [], n("cancel");
|
|
3925
3913
|
return;
|
|
3926
3914
|
}
|
|
3927
|
-
|
|
3915
|
+
w.value = !0, R.value = "", y.value = [], I.value = [];
|
|
3928
3916
|
try {
|
|
3929
|
-
const x = a.value.map((K) => z(K)),
|
|
3930
|
-
let
|
|
3931
|
-
|
|
3932
|
-
K.status !== "fulfilled" && (
|
|
3933
|
-
}),
|
|
3917
|
+
const x = a.value.map((K) => z(K)), O = await Promise.allSettled(x);
|
|
3918
|
+
let M = !0;
|
|
3919
|
+
O.forEach((K) => {
|
|
3920
|
+
K.status !== "fulfilled" && (M = !1);
|
|
3921
|
+
}), M ? (y.value = [], I.value = [], n("add:success", a.value), a.value = []) : (y.value.length && n("add:partial-success", y.value), a.value = [], V(O));
|
|
3934
3922
|
} catch {
|
|
3935
|
-
|
|
3923
|
+
R.value = r("consumer_groups.errors.add"), n("error", R.value);
|
|
3936
3924
|
} finally {
|
|
3937
|
-
|
|
3925
|
+
w.value = !1;
|
|
3938
3926
|
}
|
|
3939
3927
|
}, re = T(() => {
|
|
3940
|
-
var
|
|
3928
|
+
var O, M, K, J;
|
|
3941
3929
|
let x = `${t.config.apiBaseUrl}${Te.list[t.config.app].forConsumer}`;
|
|
3942
|
-
return t.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((
|
|
3930
|
+
return t.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((O = t.config) == null ? void 0 : O.controlPlaneId) || "").replace(/{consumerId}/gi, ((M = t.config) == null ? void 0 : M.consumerId) || "") : t.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (K = t.config) != null && K.workspace ? `/${t.config.workspace}` : "").replace(/{consumerId}/gi, ((J = t.config) == null ? void 0 : J.consumerId) || "")), x;
|
|
3943
3931
|
}), z = async (x) => {
|
|
3944
|
-
const
|
|
3932
|
+
const O = {
|
|
3945
3933
|
group: x
|
|
3946
3934
|
};
|
|
3947
3935
|
try {
|
|
3948
|
-
const
|
|
3949
|
-
return y.value.push(x),
|
|
3950
|
-
} catch (
|
|
3951
|
-
let K = `${p(x)} - ${
|
|
3952
|
-
return
|
|
3936
|
+
const M = await o.post(re.value, O);
|
|
3937
|
+
return y.value.push(x), M;
|
|
3938
|
+
} catch (M) {
|
|
3939
|
+
let K = `${p(x)} - ${M.message}`;
|
|
3940
|
+
return M.response.status === 409 && (K = `${p(x)} - ${r("consumer_groups.errors.already_added")}`), Promise.reject(Error(K));
|
|
3953
3941
|
}
|
|
3954
|
-
}, I =
|
|
3955
|
-
I.value = x.map((
|
|
3956
|
-
var
|
|
3957
|
-
return (
|
|
3942
|
+
}, I = F([]), V = (x) => {
|
|
3943
|
+
I.value = x.map((O) => {
|
|
3944
|
+
var M;
|
|
3945
|
+
return (M = O.reason) == null ? void 0 : M.message;
|
|
3958
3946
|
}).filter(Boolean);
|
|
3959
3947
|
};
|
|
3960
|
-
return
|
|
3961
|
-
|
|
3948
|
+
return Oe(_, () => {
|
|
3949
|
+
g.value++;
|
|
3962
3950
|
}, { immediate: !0, deep: !0 }), Qe(async () => {
|
|
3963
3951
|
await d();
|
|
3964
|
-
}), (x,
|
|
3965
|
-
const
|
|
3966
|
-
return f(), U(
|
|
3967
|
-
"action-pending":
|
|
3952
|
+
}), (x, O) => {
|
|
3953
|
+
const M = N("KMultiselect"), K = N("KAlert"), J = N("KPrompt");
|
|
3954
|
+
return f(), U(J, {
|
|
3955
|
+
"action-pending": w.value,
|
|
3968
3956
|
class: "kong-ui-entities-add-to-groups-modal",
|
|
3969
3957
|
"data-testid": "add-to-group-modal",
|
|
3970
3958
|
"is-visible": e.visible,
|
|
3971
3959
|
title: h(r)("consumer_groups.consumers.add.title"),
|
|
3972
|
-
onCanceled:
|
|
3960
|
+
onCanceled: C,
|
|
3973
3961
|
onProceed: H
|
|
3974
3962
|
}, {
|
|
3975
3963
|
"body-content": v(() => [
|
|
3976
|
-
|
|
3977
|
-
|
|
3978
|
-
|
|
3964
|
+
P("div", Qs, [
|
|
3965
|
+
P("p", Xs, E(h(r)("consumer_groups.consumers.add.ctaText")), 1),
|
|
3966
|
+
j(M, {
|
|
3979
3967
|
modelValue: a.value,
|
|
3980
|
-
"onUpdate:modelValue":
|
|
3968
|
+
"onUpdate:modelValue": O[0] || (O[0] = (X) => a.value = X),
|
|
3981
3969
|
autosuggest: "",
|
|
3982
3970
|
"data-testid": "add-to-groups-multiselect",
|
|
3983
3971
|
"dropdown-footer-text": k.value ? h(r)("consumer_groups.consumers.add.footer") : void 0,
|
|
@@ -3985,19 +3973,19 @@ const el = { class: "add-to-group-form-container" }, tl = { class: "add-to-group
|
|
|
3985
3973
|
label: h(r)("consumer_groups.consumers.add.consumer_groups_label"),
|
|
3986
3974
|
loading: h(s),
|
|
3987
3975
|
placeholder: h(r)("consumer_groups.consumers.add.consumer_group_placeholder"),
|
|
3988
|
-
readonly:
|
|
3976
|
+
readonly: w.value,
|
|
3989
3977
|
required: "",
|
|
3990
3978
|
width: "100%",
|
|
3991
3979
|
onQueryChange: h(i)
|
|
3992
3980
|
}, null, 8, ["modelValue", "dropdown-footer-text", "items", "label", "loading", "placeholder", "readonly", "onQueryChange"]),
|
|
3993
|
-
|
|
3994
|
-
|
|
3981
|
+
R.value || m.value || I.value.length ? (f(), A("div", el, [
|
|
3982
|
+
j(K, { appearance: "danger" }, {
|
|
3995
3983
|
alertMessage: v(() => [
|
|
3996
|
-
|
|
3997
|
-
I.value.length ? (f(), A("ul",
|
|
3998
|
-
(f(!0), A(ve, null, ye(I.value, (X, ee) => (f(), A("li", { key: ee },
|
|
3984
|
+
P("p", null, E(h(r)("consumer_groups.errors.add")), 1),
|
|
3985
|
+
I.value.length ? (f(), A("ul", tl, [
|
|
3986
|
+
(f(!0), A(ve, null, ye(I.value, (X, ee) => (f(), A("li", { key: ee }, E(X), 1))), 128))
|
|
3999
3987
|
])) : G("", !0),
|
|
4000
|
-
|
|
3988
|
+
P("div", null, E(R.value || m.value), 1)
|
|
4001
3989
|
]),
|
|
4002
3990
|
_: 1
|
|
4003
3991
|
})
|
|
@@ -4009,12 +3997,12 @@ const el = { class: "add-to-group-form-container" }, tl = { class: "add-to-group
|
|
|
4009
3997
|
};
|
|
4010
3998
|
}
|
|
4011
3999
|
});
|
|
4012
|
-
const
|
|
4000
|
+
const Kt = (e, n) => {
|
|
4013
4001
|
const t = e.__vccOpts || e;
|
|
4014
4002
|
for (const [r, o] of n)
|
|
4015
4003
|
t[r] = o;
|
|
4016
4004
|
return t;
|
|
4017
|
-
},
|
|
4005
|
+
}, rl = /* @__PURE__ */ Kt(nl, [["__scopeId", "data-v-4d30f3c5"]]), ol = { class: "kong-ui-entities-consumer-groups-list" }, al = { key: 1 }, il = /* @__PURE__ */ ie({
|
|
4018
4006
|
__name: "ConsumerGroupList",
|
|
4019
4007
|
props: {
|
|
4020
4008
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4055,20 +4043,20 @@ const Bt = (e, n) => {
|
|
|
4055
4043
|
},
|
|
4056
4044
|
emits: ["error", "copy:success", "copy:error", "delete:success", "add:success", "remove:success"],
|
|
4057
4045
|
setup(e, { emit: n }) {
|
|
4058
|
-
var
|
|
4046
|
+
var Bt;
|
|
4059
4047
|
const t = e, { i18nT: r, i18n: { t: o } } = ct.useI18n(), a = wt(), { axiosInstance: i } = Ft({
|
|
4060
|
-
headers: (
|
|
4061
|
-
}), s =
|
|
4048
|
+
headers: (Bt = t.config) == null ? void 0 : Bt.requestHeaders
|
|
4049
|
+
}), s = F(1), l = T(() => !!t.config.consumerId), c = T(() => t.config.app !== "kongManager" || !!t.config.disableSorting), d = {
|
|
4062
4050
|
name: { label: o("consumer_groups.list.table_headers.name"), searchable: !0, sortable: !0 }
|
|
4063
4051
|
};
|
|
4064
4052
|
t.config.app === "kongManager" && (d.consumers_count = { label: o("consumer_groups.list.table_headers.consumers_count"), searchable: !1, sortable: !1 }), d.tags = { label: o("consumer_groups.list.table_headers.tags"), sortable: !1 };
|
|
4065
|
-
const u = d,
|
|
4053
|
+
const u = d, m = ($) => ({
|
|
4066
4054
|
"data-testid": $.username ?? $.custom_id ?? $.id
|
|
4067
|
-
}),
|
|
4068
|
-
var
|
|
4055
|
+
}), g = T(() => {
|
|
4056
|
+
var Y, ue, Ce, Ee;
|
|
4069
4057
|
let $ = `${t.config.apiBaseUrl}${Te.list[t.config.app][l.value ? "forConsumer" : "all"]}`;
|
|
4070
|
-
return t.config.app === "konnect" ? $ = $.replace(/{controlPlaneId}/gi, ((
|
|
4071
|
-
}), k =
|
|
4058
|
+
return t.config.app === "konnect" ? $ = $.replace(/{controlPlaneId}/gi, ((Y = t.config) == null ? void 0 : Y.controlPlaneId) || "").replace(/{consumerId}/gi, ((ue = t.config) == null ? void 0 : ue.consumerId) || "") : t.config.app === "kongManager" && ($ = $.replace(/\/{workspace}/gi, (Ce = t.config) != null && Ce.workspace ? `/${t.config.workspace}` : "").replace(/{consumerId}/gi, ((Ee = t.config) == null ? void 0 : Ee.consumerId) || "")), $;
|
|
4059
|
+
}), k = F(""), _ = T(() => {
|
|
4072
4060
|
const $ = t.config.app === "konnect" || t.config.isExactMatch;
|
|
4073
4061
|
return $ ? {
|
|
4074
4062
|
isExactMatch: $,
|
|
@@ -4084,13 +4072,13 @@ const Bt = (e, n) => {
|
|
|
4084
4072
|
},
|
|
4085
4073
|
schema: t.config.filterSchema
|
|
4086
4074
|
};
|
|
4087
|
-
}), p = T(() => l.value ? "consumer_groups" : void 0), { fetcher:
|
|
4075
|
+
}), p = T(() => l.value ? "consumer_groups" : void 0), { fetcher: C, fetcherState: y } = Zs(t.config, g.value, p.value), w = () => {
|
|
4088
4076
|
k.value = "";
|
|
4089
|
-
},
|
|
4077
|
+
}, R = () => {
|
|
4090
4078
|
s.value++;
|
|
4091
|
-
}, H =
|
|
4079
|
+
}, H = F(""), re = ($, Y) => {
|
|
4092
4080
|
const ue = $.id;
|
|
4093
|
-
if (!
|
|
4081
|
+
if (!Y(ue)) {
|
|
4094
4082
|
n("copy:error", {
|
|
4095
4083
|
entity: $,
|
|
4096
4084
|
field: "id",
|
|
@@ -4103,9 +4091,9 @@ const Bt = (e, n) => {
|
|
|
4103
4091
|
field: "id",
|
|
4104
4092
|
message: o("consumer_groups.copy.success", { val: ue })
|
|
4105
4093
|
});
|
|
4106
|
-
}, z = ($,
|
|
4094
|
+
}, z = ($, Y) => {
|
|
4107
4095
|
const ue = JSON.stringify($);
|
|
4108
|
-
if (!
|
|
4096
|
+
if (!Y(ue)) {
|
|
4109
4097
|
n("copy:error", {
|
|
4110
4098
|
entity: $,
|
|
4111
4099
|
message: o("consumer_groups.errors.copy")
|
|
@@ -4119,50 +4107,50 @@ const Bt = (e, n) => {
|
|
|
4119
4107
|
}, I = async ($) => {
|
|
4120
4108
|
var ue;
|
|
4121
4109
|
await ((ue = t.canRetrieve) == null ? void 0 : ue.call(t, $)) && a.push(t.config.getViewRoute($.id));
|
|
4122
|
-
},
|
|
4110
|
+
}, V = ($) => ({
|
|
4123
4111
|
label: o("consumer_groups.actions.view"),
|
|
4124
4112
|
to: t.config.getViewRoute($)
|
|
4125
|
-
}),
|
|
4113
|
+
}), q = ($) => ({
|
|
4126
4114
|
label: o("consumer_groups.actions.edit"),
|
|
4127
4115
|
to: t.config.getEditRoute($)
|
|
4128
|
-
}), x =
|
|
4129
|
-
x.value = $,
|
|
4116
|
+
}), x = F(void 0), O = F(!1), M = F(!1), K = F(""), J = Js(t.config, g.value), X = ($) => {
|
|
4117
|
+
x.value = $, O.value = !0;
|
|
4130
4118
|
}, ee = () => {
|
|
4131
|
-
|
|
4119
|
+
O.value = !1;
|
|
4132
4120
|
}, te = async () => {
|
|
4133
|
-
var $,
|
|
4121
|
+
var $, Y, ue;
|
|
4134
4122
|
if (($ = x.value) != null && $.id) {
|
|
4135
|
-
|
|
4123
|
+
M.value = !0;
|
|
4136
4124
|
try {
|
|
4137
|
-
await i.delete(
|
|
4125
|
+
await i.delete(J(x.value.id)), M.value = !1, O.value = !1, s.value++, n("delete:success", x.value);
|
|
4138
4126
|
} catch (Ce) {
|
|
4139
|
-
K.value = ((ue = (
|
|
4127
|
+
K.value = ((ue = (Y = Ce.response) == null ? void 0 : Y.data) == null ? void 0 : ue.message) || Ce.message || o("consumer_groups.errors.delete"), n("error", Ce);
|
|
4140
4128
|
} finally {
|
|
4141
|
-
|
|
4129
|
+
M.value = !1;
|
|
4142
4130
|
}
|
|
4143
4131
|
}
|
|
4144
|
-
}, se =
|
|
4132
|
+
}, se = F(!1), Ve = () => {
|
|
4145
4133
|
se.value = !0;
|
|
4146
|
-
},
|
|
4134
|
+
}, b = () => {
|
|
4147
4135
|
se.value = !1;
|
|
4148
|
-
},
|
|
4149
|
-
|
|
4136
|
+
}, B = ($, Y) => {
|
|
4137
|
+
Y || b(), s.value++, n("add:success", $);
|
|
4150
4138
|
}, oe = () => {
|
|
4151
|
-
l.value &&
|
|
4152
|
-
},
|
|
4153
|
-
|
|
4139
|
+
l.value && Ve();
|
|
4140
|
+
}, L = F(void 0), D = F(!1), ge = F(""), _e = ($) => {
|
|
4141
|
+
L.value = $, D.value = !0;
|
|
4154
4142
|
}, ce = () => {
|
|
4155
|
-
D.value = !1,
|
|
4143
|
+
D.value = !1, L.value = void 0;
|
|
4156
4144
|
}, Be = T(() => {
|
|
4157
|
-
var
|
|
4145
|
+
var Y, ue, Ce, Ee;
|
|
4158
4146
|
let $ = `${t.config.apiBaseUrl}${Te.list[t.config.app].oneForConsumer}`;
|
|
4159
|
-
return t.config.app === "konnect" ? $ = $.replace(/{controlPlaneId}/gi, ((
|
|
4160
|
-
}), De =
|
|
4161
|
-
if (
|
|
4147
|
+
return t.config.app === "konnect" ? $ = $.replace(/{controlPlaneId}/gi, ((Y = t.config) == null ? void 0 : Y.controlPlaneId) || "").replace(/{consumerId}/gi, ((ue = t.config) == null ? void 0 : ue.consumerId) || "") : t.config.app === "kongManager" && ($ = $.replace(/\/{workspace}/gi, (Ce = t.config) != null && Ce.workspace ? `/${t.config.workspace}` : "").replace(/{consumerId}/gi, ((Ee = t.config) == null ? void 0 : Ee.consumerId) || "")), $;
|
|
4148
|
+
}), De = F(!1), ar = async () => {
|
|
4149
|
+
if (L.value) {
|
|
4162
4150
|
De.value = !0;
|
|
4163
4151
|
try {
|
|
4164
|
-
const $ = Be.value.replace(/{consumerGroupId}/gi,
|
|
4165
|
-
await i.delete($), n("remove:success",
|
|
4152
|
+
const $ = Be.value.replace(/{consumerGroupId}/gi, L.value.id);
|
|
4153
|
+
await i.delete($), n("remove:success", L.value), ce(), s.value++;
|
|
4166
4154
|
} catch ($) {
|
|
4167
4155
|
ge.value = $.message || o("consumer_groups.errors.delete"), n("error", $);
|
|
4168
4156
|
} finally {
|
|
@@ -4170,14 +4158,14 @@ const Bt = (e, n) => {
|
|
|
4170
4158
|
}
|
|
4171
4159
|
}
|
|
4172
4160
|
};
|
|
4173
|
-
|
|
4174
|
-
if ($.status ===
|
|
4161
|
+
Oe(y, ($) => {
|
|
4162
|
+
if ($.status === je.Error) {
|
|
4175
4163
|
H.value = o("consumer_groups.errors.general"), n("error", $.error);
|
|
4176
4164
|
return;
|
|
4177
4165
|
}
|
|
4178
4166
|
H.value = "";
|
|
4179
4167
|
});
|
|
4180
|
-
const pt =
|
|
4168
|
+
const pt = F({
|
|
4181
4169
|
ctaPath: l.value ? void 0 : t.config.createRoute,
|
|
4182
4170
|
ctaText: void 0,
|
|
4183
4171
|
message: o("consumer_groups.list.empty_state.description"),
|
|
@@ -4185,10 +4173,10 @@ const Bt = (e, n) => {
|
|
|
4185
4173
|
});
|
|
4186
4174
|
return Qe(async () => {
|
|
4187
4175
|
await t.canCreate() && (pt.value.title = l.value ? o("consumer_groups.list.empty_state.title_for_consumer") : o("consumer_groups.list.empty_state.title"), pt.value.ctaText = l.value ? o("consumer_groups.actions.add_to_group") : o("consumer_groups.actions.create"));
|
|
4188
|
-
}), ($,
|
|
4189
|
-
const ue =
|
|
4190
|
-
return f(), A("div",
|
|
4191
|
-
|
|
4176
|
+
}), ($, Y) => {
|
|
4177
|
+
const ue = N("KButton"), Ce = N("KBadge"), Ee = N("KTruncate"), Ge = N("KDropdownItem"), Nt = N("KClipboardProvider"), ir = N("KPrompt");
|
|
4178
|
+
return f(), A("div", ol, [
|
|
4179
|
+
j(h(Is), {
|
|
4192
4180
|
"cache-identifier": e.cacheIdentifier,
|
|
4193
4181
|
"disable-pagination": l.value,
|
|
4194
4182
|
"disable-pagination-page-jump": "",
|
|
@@ -4196,40 +4184,40 @@ const Bt = (e, n) => {
|
|
|
4196
4184
|
"empty-state-options": pt.value,
|
|
4197
4185
|
"enable-entity-actions": "",
|
|
4198
4186
|
"error-message": H.value,
|
|
4199
|
-
fetcher: h(
|
|
4187
|
+
fetcher: h(C),
|
|
4200
4188
|
"fetcher-cache-key": s.value,
|
|
4201
4189
|
"pagination-type": "offset",
|
|
4202
4190
|
"preferences-storage-key": "kong-ui-entities-consumer-groups-list",
|
|
4203
4191
|
query: k.value,
|
|
4204
|
-
"row-attributes":
|
|
4192
|
+
"row-attributes": m,
|
|
4205
4193
|
"table-headers": h(u),
|
|
4206
|
-
onClearSearchInput:
|
|
4207
|
-
"onClick:row":
|
|
4194
|
+
onClearSearchInput: w,
|
|
4195
|
+
"onClick:row": Y[3] || (Y[3] = (W) => I(W)),
|
|
4208
4196
|
onEmptyStateCtaClicked: oe,
|
|
4209
|
-
onSort:
|
|
4197
|
+
onSort: R
|
|
4210
4198
|
}, {
|
|
4211
4199
|
"toolbar-filter": v(() => [
|
|
4212
|
-
l.value ? G("", !0) : (f(), U(h(
|
|
4200
|
+
l.value ? G("", !0) : (f(), U(h(Rs), {
|
|
4213
4201
|
key: 0,
|
|
4214
4202
|
modelValue: k.value,
|
|
4215
|
-
"onUpdate:modelValue":
|
|
4203
|
+
"onUpdate:modelValue": Y[0] || (Y[0] = (W) => k.value = W),
|
|
4216
4204
|
config: _.value
|
|
4217
4205
|
}, null, 8, ["modelValue", "config"]))
|
|
4218
4206
|
]),
|
|
4219
4207
|
"toolbar-button": v(() => [
|
|
4220
|
-
|
|
4208
|
+
j(h(Xe), {
|
|
4221
4209
|
"auth-function": () => e.canCreate()
|
|
4222
4210
|
}, {
|
|
4223
4211
|
default: v(() => [
|
|
4224
|
-
|
|
4212
|
+
j(ue, {
|
|
4225
4213
|
appearance: "primary",
|
|
4226
4214
|
"data-testid": "toolbar-add-consumer-group",
|
|
4227
4215
|
icon: "plus",
|
|
4228
4216
|
to: e.config.consumerId ? void 0 : e.config.createRoute,
|
|
4229
|
-
onClick:
|
|
4217
|
+
onClick: Y[1] || (Y[1] = () => e.config.consumerId ? Ve() : void 0)
|
|
4230
4218
|
}, {
|
|
4231
4219
|
default: v(() => [
|
|
4232
|
-
|
|
4220
|
+
Q(E(e.config.consumerId ? h(o)("consumer_groups.actions.add_to_group") : h(o)("consumer_groups.list.toolbar_actions.new_consumer_group")), 1)
|
|
4233
4221
|
]),
|
|
4234
4222
|
_: 1
|
|
4235
4223
|
}, 8, ["to"])
|
|
@@ -4238,92 +4226,92 @@ const Bt = (e, n) => {
|
|
|
4238
4226
|
}, 8, ["auth-function"])
|
|
4239
4227
|
]),
|
|
4240
4228
|
name: v(({ rowValue: W }) => [
|
|
4241
|
-
|
|
4229
|
+
P("b", null, E(W ?? "-"), 1)
|
|
4242
4230
|
]),
|
|
4243
4231
|
consumers_count: v(({ rowValue: W }) => [
|
|
4244
|
-
|
|
4232
|
+
Q(E(W ?? "-"), 1)
|
|
4245
4233
|
]),
|
|
4246
4234
|
tags: v(({ rowValue: W }) => [
|
|
4247
4235
|
(W == null ? void 0 : W.length) > 0 ? (f(), U(Ee, { key: 0 }, {
|
|
4248
4236
|
default: v(() => [
|
|
4249
|
-
(f(!0), A(ve, null, ye(W, (
|
|
4250
|
-
key:
|
|
4251
|
-
onClick:
|
|
4237
|
+
(f(!0), A(ve, null, ye(W, (Ne) => (f(), U(Ce, {
|
|
4238
|
+
key: Ne,
|
|
4239
|
+
onClick: Y[2] || (Y[2] = rt(() => {
|
|
4252
4240
|
}, ["stop"]))
|
|
4253
4241
|
}, {
|
|
4254
4242
|
default: v(() => [
|
|
4255
|
-
|
|
4243
|
+
Q(E(Ne), 1)
|
|
4256
4244
|
]),
|
|
4257
4245
|
_: 2
|
|
4258
4246
|
}, 1024))), 128))
|
|
4259
4247
|
]),
|
|
4260
4248
|
_: 2
|
|
4261
|
-
}, 1024)) : (f(), A("span",
|
|
4249
|
+
}, 1024)) : (f(), A("span", al, "-"))
|
|
4262
4250
|
]),
|
|
4263
4251
|
actions: v(({ row: W }) => [
|
|
4264
|
-
|
|
4265
|
-
default: v(({ copyToClipboard:
|
|
4266
|
-
|
|
4252
|
+
j(Nt, null, {
|
|
4253
|
+
default: v(({ copyToClipboard: Ne }) => [
|
|
4254
|
+
j(Ge, {
|
|
4267
4255
|
"data-testid": "action-entity-copy-id",
|
|
4268
|
-
onClick: (sr) => re(W,
|
|
4256
|
+
onClick: (sr) => re(W, Ne)
|
|
4269
4257
|
}, {
|
|
4270
4258
|
default: v(() => [
|
|
4271
|
-
|
|
4259
|
+
Q(E(h(o)("consumer_groups.actions.copy_id")), 1)
|
|
4272
4260
|
]),
|
|
4273
4261
|
_: 2
|
|
4274
4262
|
}, 1032, ["onClick"])
|
|
4275
4263
|
]),
|
|
4276
4264
|
_: 2
|
|
4277
4265
|
}, 1024),
|
|
4278
|
-
|
|
4279
|
-
default: v(({ copyToClipboard:
|
|
4280
|
-
|
|
4266
|
+
j(Nt, null, {
|
|
4267
|
+
default: v(({ copyToClipboard: Ne }) => [
|
|
4268
|
+
j(Ge, {
|
|
4281
4269
|
"data-testid": "action-entity-copy-json",
|
|
4282
|
-
onClick: (sr) => z(W,
|
|
4270
|
+
onClick: (sr) => z(W, Ne)
|
|
4283
4271
|
}, {
|
|
4284
4272
|
default: v(() => [
|
|
4285
|
-
|
|
4273
|
+
Q(E(h(o)("consumer_groups.actions.copy_json")), 1)
|
|
4286
4274
|
]),
|
|
4287
4275
|
_: 2
|
|
4288
4276
|
}, 1032, ["onClick"])
|
|
4289
4277
|
]),
|
|
4290
4278
|
_: 2
|
|
4291
4279
|
}, 1024),
|
|
4292
|
-
|
|
4280
|
+
j(h(Xe), {
|
|
4293
4281
|
"auth-function": () => e.canRetrieve(W)
|
|
4294
4282
|
}, {
|
|
4295
4283
|
default: v(() => [
|
|
4296
|
-
|
|
4284
|
+
j(Ge, {
|
|
4297
4285
|
"data-testid": "action-entity-view",
|
|
4298
4286
|
"has-divider": "",
|
|
4299
|
-
item:
|
|
4287
|
+
item: V(W.id)
|
|
4300
4288
|
}, null, 8, ["item"])
|
|
4301
4289
|
]),
|
|
4302
4290
|
_: 2
|
|
4303
4291
|
}, 1032, ["auth-function"]),
|
|
4304
|
-
|
|
4292
|
+
j(h(Xe), {
|
|
4305
4293
|
"auth-function": () => e.canEdit(W)
|
|
4306
4294
|
}, {
|
|
4307
4295
|
default: v(() => [
|
|
4308
|
-
|
|
4296
|
+
j(Ge, {
|
|
4309
4297
|
"data-testid": "action-entity-edit",
|
|
4310
|
-
item:
|
|
4298
|
+
item: q(W.id)
|
|
4311
4299
|
}, null, 8, ["item"])
|
|
4312
4300
|
]),
|
|
4313
4301
|
_: 2
|
|
4314
4302
|
}, 1032, ["auth-function"]),
|
|
4315
|
-
|
|
4303
|
+
j(h(Xe), {
|
|
4316
4304
|
"auth-function": () => e.canDelete(W)
|
|
4317
4305
|
}, {
|
|
4318
4306
|
default: v(() => [
|
|
4319
|
-
|
|
4307
|
+
j(Ge, {
|
|
4320
4308
|
"data-testid": "action-entity-delete",
|
|
4321
4309
|
"has-divider": "",
|
|
4322
4310
|
"is-dangerous": "",
|
|
4323
4311
|
onClick: () => e.config.consumerId ? _e(W) : X(W)
|
|
4324
4312
|
}, {
|
|
4325
4313
|
default: v(() => [
|
|
4326
|
-
|
|
4314
|
+
Q(E(e.config.consumerId ? h(o)("consumer_groups.actions.exit") : h(o)("consumer_groups.actions.delete")), 1)
|
|
4327
4315
|
]),
|
|
4328
4316
|
_: 2
|
|
4329
4317
|
}, 1032, ["onClick"])
|
|
@@ -4333,28 +4321,28 @@ const Bt = (e, n) => {
|
|
|
4333
4321
|
]),
|
|
4334
4322
|
_: 1
|
|
4335
4323
|
}, 8, ["cache-identifier", "disable-pagination", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers"]),
|
|
4336
|
-
|
|
4337
|
-
"action-pending":
|
|
4324
|
+
j(h(Ts), {
|
|
4325
|
+
"action-pending": M.value,
|
|
4338
4326
|
"data-testid": "delete-consumer-group-modal",
|
|
4339
4327
|
description: h(o)("consumer_groups.delete.description"),
|
|
4340
4328
|
"entity-name": x.value && (x.value.name || x.value.id),
|
|
4341
4329
|
"entity-type": h(dn).ConsumerGroup,
|
|
4342
4330
|
error: K.value,
|
|
4343
4331
|
title: h(o)("consumer_groups.delete.title"),
|
|
4344
|
-
visible:
|
|
4332
|
+
visible: O.value,
|
|
4345
4333
|
onCancel: ee,
|
|
4346
4334
|
onProceed: te
|
|
4347
4335
|
}, null, 8, ["action-pending", "description", "entity-name", "entity-type", "error", "title", "visible"]),
|
|
4348
|
-
e.config.consumerId ? (f(), U(
|
|
4336
|
+
e.config.consumerId ? (f(), U(rl, {
|
|
4349
4337
|
key: 0,
|
|
4350
4338
|
config: e.config,
|
|
4351
4339
|
"data-testid": "add-to-group-modal",
|
|
4352
4340
|
visible: se.value,
|
|
4353
|
-
"onAdd:partialSuccess":
|
|
4354
|
-
"onAdd:success":
|
|
4355
|
-
onCancel:
|
|
4341
|
+
"onAdd:partialSuccess": Y[4] || (Y[4] = (W) => B(W, !0)),
|
|
4342
|
+
"onAdd:success": Y[5] || (Y[5] = (W) => B(W)),
|
|
4343
|
+
onCancel: b
|
|
4356
4344
|
}, null, 8, ["config", "visible"])) : G("", !0),
|
|
4357
|
-
e.config.consumerId &&
|
|
4345
|
+
e.config.consumerId && L.value ? (f(), U(ir, {
|
|
4358
4346
|
key: 1,
|
|
4359
4347
|
"data-testid": "exit-group-modal",
|
|
4360
4348
|
"is-visible": D.value,
|
|
@@ -4364,25 +4352,25 @@ const Bt = (e, n) => {
|
|
|
4364
4352
|
onProceed: ar
|
|
4365
4353
|
}, {
|
|
4366
4354
|
"body-content": v(() => [
|
|
4367
|
-
|
|
4355
|
+
j(h(r), {
|
|
4368
4356
|
class: "exit-modal-message",
|
|
4369
4357
|
keypath: e.config.consumerUsername ? "consumer_groups.consumers.exit.confirmation" : "consumer_groups.consumers.exit.confirmationNoUsername",
|
|
4370
4358
|
tag: "p"
|
|
4371
4359
|
}, Se({
|
|
4372
4360
|
consumerGroup: v(() => [
|
|
4373
|
-
|
|
4361
|
+
P("strong", null, E(L.value.name || L.value.id), 1)
|
|
4374
4362
|
]),
|
|
4375
4363
|
_: 2
|
|
4376
4364
|
}, [
|
|
4377
4365
|
e.config.consumerUsername ? {
|
|
4378
4366
|
name: "consumer",
|
|
4379
4367
|
fn: v(() => [
|
|
4380
|
-
|
|
4368
|
+
P("strong", null, E(e.config.consumerUsername), 1)
|
|
4381
4369
|
]),
|
|
4382
4370
|
key: "0"
|
|
4383
4371
|
} : void 0
|
|
4384
4372
|
]), 1032, ["keypath"]),
|
|
4385
|
-
|
|
4373
|
+
P("p", null, E(h(o)("consumer_groups.consumers.exit.description")), 1)
|
|
4386
4374
|
]),
|
|
4387
4375
|
_: 1
|
|
4388
4376
|
}, 8, ["is-visible", "title"])) : G("", !0)
|
|
@@ -4390,10 +4378,10 @@ const Bt = (e, n) => {
|
|
|
4390
4378
|
};
|
|
4391
4379
|
}
|
|
4392
4380
|
});
|
|
4393
|
-
const
|
|
4381
|
+
const kl = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { class: "kong-ui-entities-consumer-group-form" }, ll = { class: "select-item-label" }, ul = {
|
|
4394
4382
|
key: 0,
|
|
4395
4383
|
class: "select-item-desc"
|
|
4396
|
-
},
|
|
4384
|
+
}, cl = /* @__PURE__ */ ie({
|
|
4397
4385
|
__name: "ConsumerGroupForm",
|
|
4398
4386
|
props: {
|
|
4399
4387
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4411,8 +4399,8 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4411
4399
|
},
|
|
4412
4400
|
emits: ["update", "error", "loading"],
|
|
4413
4401
|
setup(e, { emit: n }) {
|
|
4414
|
-
var te, se,
|
|
4415
|
-
const t = e, { i18n: { t: r } } = ct.useI18n(), o = wt(), a =
|
|
4402
|
+
var te, se, Ve;
|
|
4403
|
+
const t = e, { i18n: { t: r } } = ct.useI18n(), o = wt(), a = Lt({
|
|
4416
4404
|
fields: {
|
|
4417
4405
|
name: "",
|
|
4418
4406
|
tags: "",
|
|
@@ -4420,7 +4408,7 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4420
4408
|
},
|
|
4421
4409
|
errorMessage: "",
|
|
4422
4410
|
readonly: !1
|
|
4423
|
-
}), i =
|
|
4411
|
+
}), i = Lt({
|
|
4424
4412
|
name: "",
|
|
4425
4413
|
tags: "",
|
|
4426
4414
|
consumers: []
|
|
@@ -4433,135 +4421,135 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4433
4421
|
} = or(t.config, (se = Te.form[(te = t.config) == null ? void 0 : te.app]) == null ? void 0 : se.consumersList, "", {
|
|
4434
4422
|
fetchedItemsKey: "data",
|
|
4435
4423
|
searchKeys: ["username", "custom_id"]
|
|
4436
|
-
}), { axiosInstance:
|
|
4437
|
-
headers: (
|
|
4438
|
-
}), { getMessageFromError:
|
|
4439
|
-
label:
|
|
4440
|
-
value:
|
|
4441
|
-
selected: a.fields.consumers.includes(
|
|
4442
|
-
data:
|
|
4424
|
+
}), { axiosInstance: m } = Ft({
|
|
4425
|
+
headers: (Ve = t.config) == null ? void 0 : Ve.requestHeaders
|
|
4426
|
+
}), { getMessageFromError: g } = Ws(), k = T(() => u.value.map((b) => ({
|
|
4427
|
+
label: b.username || b.custom_id,
|
|
4428
|
+
value: b.id,
|
|
4429
|
+
selected: a.fields.consumers.includes(b.id),
|
|
4430
|
+
data: b
|
|
4443
4431
|
// we need this to determine whether or not to show the description text
|
|
4444
4432
|
}))), _ = T(() => {
|
|
4445
|
-
var
|
|
4446
|
-
return (
|
|
4447
|
-
}), p = T(() => t.consumerGroupId ? nt.Edit : nt.Create),
|
|
4433
|
+
var b, B;
|
|
4434
|
+
return (B = Te.form[(b = t.config) == null ? void 0 : b.app]) == null ? void 0 : B.edit;
|
|
4435
|
+
}), p = T(() => t.consumerGroupId ? nt.Edit : nt.Create), C = T(() => !!a.fields.name && !I.value), y = T(() => JSON.stringify(a.fields) !== JSON.stringify(i)), w = (b, B = "", oe = "") => {
|
|
4448
4436
|
var D, ge, _e, ce, Be, De;
|
|
4449
|
-
let
|
|
4450
|
-
return ((_e = t.config) == null ? void 0 : _e.app) === "konnect" ?
|
|
4451
|
-
},
|
|
4452
|
-
var
|
|
4453
|
-
o.push(((
|
|
4454
|
-
}, H = (
|
|
4455
|
-
n("error",
|
|
4456
|
-
}, re = (
|
|
4457
|
-
n("loading",
|
|
4458
|
-
}, z = async (
|
|
4459
|
-
var oe,
|
|
4460
|
-
a.fields.name = ((oe =
|
|
4461
|
-
const
|
|
4462
|
-
if (a.fields.tags = (
|
|
4463
|
-
a.fields.consumers = ((ge =
|
|
4437
|
+
let L = `${(D = t.config) == null ? void 0 : D.apiBaseUrl}${Te.form[(ge = t.config) == null ? void 0 : ge.app][b]}`;
|
|
4438
|
+
return ((_e = t.config) == null ? void 0 : _e.app) === "konnect" ? L = L.replace(/{controlPlaneId}/gi, ((ce = t.config) == null ? void 0 : ce.controlPlaneId) || "") : ((Be = t.config) == null ? void 0 : Be.app) === "kongManager" && (L = L.replace(/\/{workspace}/gi, (De = t.config) != null && De.workspace ? `/${t.config.workspace}` : "")), L = L.replace(/{id}/gi, B || t.consumerGroupId), (b === "addConsumer" || b === "removeConsumer") && (L = L.replace(/{consumerId}/gi, oe)), L;
|
|
4439
|
+
}, R = () => {
|
|
4440
|
+
var b;
|
|
4441
|
+
o.push(((b = t.config) == null ? void 0 : b.cancelRoute) || { name: "consumer-group-list" });
|
|
4442
|
+
}, H = (b) => {
|
|
4443
|
+
n("error", b);
|
|
4444
|
+
}, re = (b) => {
|
|
4445
|
+
n("loading", b);
|
|
4446
|
+
}, z = async (b) => {
|
|
4447
|
+
var oe, L, D, ge, _e;
|
|
4448
|
+
a.fields.name = ((oe = b == null ? void 0 : b.item) == null ? void 0 : oe.name) || ((L = b == null ? void 0 : b.consumer_group) == null ? void 0 : L.name) || (b == null ? void 0 : b.name) || "";
|
|
4449
|
+
const B = ((D = b == null ? void 0 : b.item) == null ? void 0 : D.tags) || (b == null ? void 0 : b.consumer_group.tags) || (b == null ? void 0 : b.tags) || [];
|
|
4450
|
+
if (a.fields.tags = (B == null ? void 0 : B.join(", ")) || "", "consumers" in b)
|
|
4451
|
+
a.fields.consumers = ((ge = b == null ? void 0 : b.consumers) == null ? void 0 : ge.map((ce) => ce.id)) || [];
|
|
4464
4452
|
else
|
|
4465
4453
|
try {
|
|
4466
|
-
const { data: ce } = await
|
|
4454
|
+
const { data: ce } = await m.get(w("getConsumers"));
|
|
4467
4455
|
a.fields.consumers = "consumers" in ce ? (_e = ce == null ? void 0 : ce.consumers) == null ? void 0 : _e.map((Be) => Be.id) : [];
|
|
4468
4456
|
} catch (ce) {
|
|
4469
|
-
|
|
4457
|
+
O(ce);
|
|
4470
4458
|
}
|
|
4471
4459
|
Object.assign(i, a.fields);
|
|
4472
|
-
}, I = T(() => /^[0-9a-zA-Z.\-_~]*$/.test(a.fields.name) ? "" : r("consumer_groups.form.validation_errors.name")),
|
|
4473
|
-
var
|
|
4460
|
+
}, I = T(() => /^[0-9a-zA-Z.\-_~]*$/.test(a.fields.name) ? "" : r("consumer_groups.form.validation_errors.name")), V = () => {
|
|
4461
|
+
var b, B;
|
|
4474
4462
|
return {
|
|
4475
4463
|
name: a.fields.name,
|
|
4476
|
-
tags: (
|
|
4464
|
+
tags: (B = (b = a.fields.tags.split(",")) == null ? void 0 : b.map((oe) => String(oe || "").trim())) == null ? void 0 : B.filter((oe) => oe !== "")
|
|
4477
4465
|
};
|
|
4478
|
-
},
|
|
4479
|
-
a.errorMessage =
|
|
4480
|
-
},
|
|
4481
|
-
Object.assign(i, a.fields), n("update", { ...a.fields, id:
|
|
4482
|
-
}, K = (
|
|
4483
|
-
const
|
|
4484
|
-
|
|
4485
|
-
code:
|
|
4486
|
-
message:
|
|
4487
|
-
}) :
|
|
4488
|
-
},
|
|
4489
|
-
let
|
|
4466
|
+
}, q = async (b, B = "") => await m.post(w("addConsumer", B, b), { consumer: b }), x = async (b, B = "") => await m.delete(w("removeConsumer", B, b)), O = (b) => {
|
|
4467
|
+
a.errorMessage = g(b), n("error", b);
|
|
4468
|
+
}, M = (b = t.consumerGroupId) => {
|
|
4469
|
+
Object.assign(i, a.fields), n("update", { ...a.fields, id: b });
|
|
4470
|
+
}, K = (b, B, oe = t.consumerGroupId) => {
|
|
4471
|
+
const L = b == null ? void 0 : b.find((D) => D.status !== "fulfilled");
|
|
4472
|
+
L ? O({
|
|
4473
|
+
code: L.status,
|
|
4474
|
+
message: B
|
|
4475
|
+
}) : M(oe);
|
|
4476
|
+
}, J = async () => {
|
|
4477
|
+
let b = "";
|
|
4490
4478
|
try {
|
|
4491
|
-
const { data:
|
|
4492
|
-
|
|
4493
|
-
} catch (
|
|
4494
|
-
|
|
4479
|
+
const { data: B } = await m.post(w("create"), V());
|
|
4480
|
+
b = "item" in B ? B.item.id : B.id;
|
|
4481
|
+
} catch (B) {
|
|
4482
|
+
O(B);
|
|
4495
4483
|
}
|
|
4496
|
-
if (a.fields.consumers.length > 0 &&
|
|
4484
|
+
if (a.fields.consumers.length > 0 && b)
|
|
4497
4485
|
try {
|
|
4498
|
-
const
|
|
4499
|
-
K(oe, r("consumer_groups.errors.add_consumer"),
|
|
4500
|
-
} catch (
|
|
4501
|
-
|
|
4486
|
+
const B = a.fields.consumers.map((L) => q(L, b)), oe = await Promise.allSettled(B);
|
|
4487
|
+
K(oe, r("consumer_groups.errors.add_consumer"), b);
|
|
4488
|
+
} catch (B) {
|
|
4489
|
+
O(B);
|
|
4502
4490
|
}
|
|
4503
4491
|
else
|
|
4504
|
-
a.fields.consumers.length === 0 &&
|
|
4492
|
+
a.fields.consumers.length === 0 && b && M(b);
|
|
4505
4493
|
}, X = async () => {
|
|
4506
4494
|
var oe;
|
|
4507
4495
|
try {
|
|
4508
|
-
((oe = t.config) == null ? void 0 : oe.app) === "konnect" ? await
|
|
4509
|
-
} catch (
|
|
4510
|
-
|
|
4496
|
+
((oe = t.config) == null ? void 0 : oe.app) === "konnect" ? await m.put(w("edit"), V()) : await m.patch(w("edit"), V());
|
|
4497
|
+
} catch (L) {
|
|
4498
|
+
O(L);
|
|
4511
4499
|
}
|
|
4512
|
-
const
|
|
4513
|
-
if (
|
|
4514
|
-
|
|
4500
|
+
const b = a.fields.consumers.filter((L) => !i.consumers.includes(L)), B = i.consumers.filter((L) => !a.fields.consumers.includes(L));
|
|
4501
|
+
if (B.length === 0 && b.length === 0)
|
|
4502
|
+
M();
|
|
4515
4503
|
else {
|
|
4516
|
-
if (
|
|
4504
|
+
if (B.length > 0)
|
|
4517
4505
|
try {
|
|
4518
|
-
const
|
|
4506
|
+
const L = B.map((ge) => x(ge)), D = await Promise.allSettled(L);
|
|
4519
4507
|
K(D, r("consumer_groups.errors.remove_consumer"));
|
|
4520
|
-
} catch (
|
|
4521
|
-
|
|
4508
|
+
} catch (L) {
|
|
4509
|
+
O(L);
|
|
4522
4510
|
}
|
|
4523
|
-
if (
|
|
4511
|
+
if (b.length > 0)
|
|
4524
4512
|
try {
|
|
4525
|
-
const
|
|
4513
|
+
const L = b.map((ge) => q(ge)), D = await Promise.allSettled(L);
|
|
4526
4514
|
K(D, r("consumer_groups.errors.add_consumer"));
|
|
4527
|
-
} catch (
|
|
4528
|
-
|
|
4515
|
+
} catch (L) {
|
|
4516
|
+
O(L);
|
|
4529
4517
|
}
|
|
4530
4518
|
}
|
|
4531
4519
|
}, ee = async () => {
|
|
4532
4520
|
try {
|
|
4533
|
-
a.readonly = !0, p.value === nt.Create ? await
|
|
4521
|
+
a.readonly = !0, p.value === nt.Create ? await J() : await X();
|
|
4534
4522
|
} finally {
|
|
4535
4523
|
a.readonly = !1;
|
|
4536
4524
|
}
|
|
4537
4525
|
};
|
|
4538
4526
|
return Qe(async () => {
|
|
4539
4527
|
await d();
|
|
4540
|
-
}), (
|
|
4541
|
-
const oe =
|
|
4542
|
-
return f(), A("div",
|
|
4543
|
-
|
|
4544
|
-
"can-submit":
|
|
4528
|
+
}), (b, B) => {
|
|
4529
|
+
const oe = N("KInput"), L = N("KMultiselect");
|
|
4530
|
+
return f(), A("div", sl, [
|
|
4531
|
+
j(h(ys), {
|
|
4532
|
+
"can-submit": C.value && y.value,
|
|
4545
4533
|
config: e.config,
|
|
4546
4534
|
"edit-id": e.consumerGroupId,
|
|
4547
4535
|
"error-message": a.errorMessage || h(c) || I.value,
|
|
4548
4536
|
"fetch-url": _.value,
|
|
4549
4537
|
"is-readonly": a.readonly,
|
|
4550
|
-
onCancel:
|
|
4551
|
-
"onFetch:error":
|
|
4538
|
+
onCancel: R,
|
|
4539
|
+
"onFetch:error": B[3] || (B[3] = (D) => H(D)),
|
|
4552
4540
|
"onFetch:success": z,
|
|
4553
|
-
onLoading:
|
|
4541
|
+
onLoading: B[4] || (B[4] = (D) => re(D)),
|
|
4554
4542
|
onSubmit: ee
|
|
4555
4543
|
}, {
|
|
4556
4544
|
default: v(() => [
|
|
4557
|
-
|
|
4545
|
+
j(h(un), {
|
|
4558
4546
|
description: h(r)("consumer_groups.form.general_info.description"),
|
|
4559
4547
|
title: h(r)("consumer_groups.form.general_info.title")
|
|
4560
4548
|
}, {
|
|
4561
4549
|
default: v(() => [
|
|
4562
|
-
|
|
4550
|
+
j(oe, {
|
|
4563
4551
|
modelValue: a.fields.name,
|
|
4564
|
-
"onUpdate:modelValue":
|
|
4552
|
+
"onUpdate:modelValue": B[0] || (B[0] = (D) => a.fields.name = D),
|
|
4565
4553
|
modelModifiers: { trim: !0 },
|
|
4566
4554
|
autocomplete: "off",
|
|
4567
4555
|
"data-testid": "consumer-group-form-name",
|
|
@@ -4570,9 +4558,9 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4570
4558
|
required: "",
|
|
4571
4559
|
type: "text"
|
|
4572
4560
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
4573
|
-
|
|
4561
|
+
j(oe, {
|
|
4574
4562
|
modelValue: a.fields.tags,
|
|
4575
|
-
"onUpdate:modelValue":
|
|
4563
|
+
"onUpdate:modelValue": B[1] || (B[1] = (D) => a.fields.tags = D),
|
|
4576
4564
|
modelModifiers: { trim: !0 },
|
|
4577
4565
|
autocomplete: "off",
|
|
4578
4566
|
"data-testid": "consumer-group-form-tags",
|
|
@@ -4588,15 +4576,15 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4588
4576
|
]),
|
|
4589
4577
|
_: 1
|
|
4590
4578
|
}, 8, ["description", "title"]),
|
|
4591
|
-
|
|
4579
|
+
j(h(un), {
|
|
4592
4580
|
description: h(r)("consumer_groups.form.consumers.description"),
|
|
4593
4581
|
"has-divider": "",
|
|
4594
4582
|
title: h(r)("consumer_groups.form.consumers.title")
|
|
4595
4583
|
}, {
|
|
4596
4584
|
default: v(() => [
|
|
4597
|
-
|
|
4585
|
+
j(L, {
|
|
4598
4586
|
modelValue: a.fields.consumers,
|
|
4599
|
-
"onUpdate:modelValue":
|
|
4587
|
+
"onUpdate:modelValue": B[2] || (B[2] = (D) => a.fields.consumers = D),
|
|
4600
4588
|
appearance: "select",
|
|
4601
4589
|
autosuggest: "",
|
|
4602
4590
|
"expand-selected": "",
|
|
@@ -4610,8 +4598,8 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4610
4598
|
"item-template": v(({ item: D }) => {
|
|
4611
4599
|
var ge, _e, ce;
|
|
4612
4600
|
return [
|
|
4613
|
-
|
|
4614
|
-
(ge = D == null ? void 0 : D.data) != null && ge.username && ((_e = D == null ? void 0 : D.data) != null && _e.custom_id) ? (f(), A("div",
|
|
4601
|
+
P("div", ll, E(D.label), 1),
|
|
4602
|
+
(ge = D == null ? void 0 : D.data) != null && ge.username && ((_e = D == null ? void 0 : D.data) != null && _e.custom_id) ? (f(), A("div", ul, E((ce = D == null ? void 0 : D.data) == null ? void 0 : ce.custom_id), 1)) : G("", !0)
|
|
4615
4603
|
];
|
|
4616
4604
|
}),
|
|
4617
4605
|
_: 1
|
|
@@ -4626,7 +4614,7 @@ const wl = /* @__PURE__ */ Bt(ll, [["__scopeId", "data-v-80c4522c"]]), ul = { cl
|
|
|
4626
4614
|
};
|
|
4627
4615
|
}
|
|
4628
4616
|
});
|
|
4629
|
-
const
|
|
4617
|
+
const _l = /* @__PURE__ */ Kt(cl, [["__scopeId", "data-v-2da12897"]]), dl = { class: "kong-ui-consumer-group-entity-config-card" }, wl = /* @__PURE__ */ ie({
|
|
4630
4618
|
__name: "ConsumerGroupConfigCard",
|
|
4631
4619
|
props: {
|
|
4632
4620
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4653,7 +4641,7 @@ const Il = /* @__PURE__ */ Bt(pl, [["__scopeId", "data-v-2da12897"]]), fl = { cl
|
|
|
4653
4641
|
},
|
|
4654
4642
|
emits: ["loading", "fetch:error", "fetch:success", "copy:success"],
|
|
4655
4643
|
setup(e) {
|
|
4656
|
-
const n = e, { i18n: { t } } = ct.useI18n(), r = T(() => Te.form[n.config.app].edit), o =
|
|
4644
|
+
const n = e, { i18n: { t } } = ct.useI18n(), r = T(() => Te.form[n.config.app].edit), o = F({
|
|
4657
4645
|
id: {},
|
|
4658
4646
|
name: {},
|
|
4659
4647
|
created_at: {},
|
|
@@ -4662,8 +4650,8 @@ const Il = /* @__PURE__ */ Bt(pl, [["__scopeId", "data-v-2da12897"]]), fl = { cl
|
|
|
4662
4650
|
tooltip: t("consumer_groups.form.fields.tags.tooltip")
|
|
4663
4651
|
}
|
|
4664
4652
|
});
|
|
4665
|
-
return (a, i) => (f(), A("div",
|
|
4666
|
-
|
|
4653
|
+
return (a, i) => (f(), A("div", dl, [
|
|
4654
|
+
j(h(ps), {
|
|
4667
4655
|
config: e.config,
|
|
4668
4656
|
"config-card-doc": e.configCardDoc,
|
|
4669
4657
|
"config-schema": o.value,
|
|
@@ -4679,7 +4667,7 @@ const Il = /* @__PURE__ */ Bt(pl, [["__scopeId", "data-v-2da12897"]]), fl = { cl
|
|
|
4679
4667
|
}
|
|
4680
4668
|
});
|
|
4681
4669
|
export {
|
|
4682
|
-
|
|
4683
|
-
|
|
4684
|
-
|
|
4670
|
+
wl as ConsumerGroupConfigCard,
|
|
4671
|
+
_l as ConsumerGroupForm,
|
|
4672
|
+
kl as ConsumerGroupList
|
|
4685
4673
|
};
|