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