@kong-ui-public/entities-consumers 2.2.8 → 2.2.10-pr.940.0fa4e316.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-consumers.es.js +1291 -1255
- package/dist/entities-consumers.umd.js +21 -21
- package/dist/style.css +1 -1
- package/package.json +4 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as ne, ref as
|
|
1
|
+
import { defineComponent as ne, ref as E, computed as $, watch as ve, renderSlot as Z, createCommentVNode as H, unref as m, useSlots as Ze, onBeforeMount as gt, resolveComponent as D, openBlock as f, createBlock as R, createSlots as ke, withCtx as g, createElementVNode as B, createTextVNode as W, toDisplayString as j, createVNode as O, createElementBlock as T, renderList as pe, Fragment as me, normalizeClass as Ie, withModifiers as Ge, withDirectives as Be, vShow as Le, useCssVars as cn, resolveDynamicComponent as Fe, normalizeProps as ya, guardReactiveProps as ha, mergeProps as st, onMounted as va, onUnmounted as ba, normalizeStyle as dn, inject as Ca, pushScopeId as pn, popScopeId as fn, Teleport as ka, reactive as qt } from "vue";
|
|
2
2
|
import { useRouter as yt } from "vue-router";
|
|
3
|
-
import { createI18n as ht, i18nTComponent as
|
|
3
|
+
import { createI18n as ht, i18nTComponent as mn } from "@kong-ui-public/i18n";
|
|
4
4
|
import wa from "axios";
|
|
5
5
|
import { BadgeMethodAppearances as Ia } from "@kong/kongponents";
|
|
6
6
|
const _a = {
|
|
@@ -98,19 +98,19 @@ const _a = {
|
|
|
98
98
|
tooltip: "An optional set of strings associated with the Consumer for grouping and filtering."
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
|
-
},
|
|
101
|
+
}, Sa = {
|
|
102
102
|
consumers: _a
|
|
103
103
|
};
|
|
104
|
-
function
|
|
105
|
-
const e = ht("en-us",
|
|
104
|
+
function Aa() {
|
|
105
|
+
const e = ht("en-us", Sa);
|
|
106
106
|
return {
|
|
107
107
|
i18n: e,
|
|
108
|
-
i18nT:
|
|
108
|
+
i18nT: mn(e)
|
|
109
109
|
// Translation component <i18n-t>
|
|
110
110
|
};
|
|
111
111
|
}
|
|
112
112
|
const Qe = {
|
|
113
|
-
useI18n:
|
|
113
|
+
useI18n: Aa
|
|
114
114
|
}, at = "/api/runtime_groups/{controlPlaneId}", $e = "/{workspace}", xe = {
|
|
115
115
|
list: {
|
|
116
116
|
konnect: {
|
|
@@ -137,7 +137,7 @@ const Qe = {
|
|
|
137
137
|
}
|
|
138
138
|
}
|
|
139
139
|
};
|
|
140
|
-
var
|
|
140
|
+
var gn = /* @__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))(gn || {}), ut = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(ut || {}), Se = /* @__PURE__ */ ((e) => (e[e.Loading = 0] = "Loading", e[e.Idle = 1] = "Idle", e[e.NoResults = 2] = "NoResults", e[e.Error = 3] = "Error", e))(Se || {}), ee = /* @__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))(ee || {}), de = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e))(de || {});
|
|
141
141
|
function vt(e = {}) {
|
|
142
142
|
return {
|
|
143
143
|
axiosInstance: wa.create({
|
|
@@ -195,14 +195,14 @@ function $a() {
|
|
|
195
195
|
}
|
|
196
196
|
};
|
|
197
197
|
}
|
|
198
|
-
const
|
|
198
|
+
const ja = {
|
|
199
199
|
actions: {
|
|
200
200
|
copyId: "Copy ID",
|
|
201
201
|
copied_id: 'Copied "{id}" to the clipboard',
|
|
202
202
|
copyToClipboard: "Copied successfully!",
|
|
203
203
|
copyToClipboardFailed: "Failed to copy to the clipboard"
|
|
204
204
|
}
|
|
205
|
-
},
|
|
205
|
+
}, Ma = {
|
|
206
206
|
message: "Are you sure you want to delete this {entityType}?",
|
|
207
207
|
messageWithName: "Are you sure you want to delete this {entityType} {entityName}?"
|
|
208
208
|
}, Oa = {
|
|
@@ -220,7 +220,7 @@ const Ma = {
|
|
|
220
220
|
noSearchResultsMessage: "Please adjust the criteria and try again.",
|
|
221
221
|
noSearchResultsCtaText: "Clear"
|
|
222
222
|
}
|
|
223
|
-
},
|
|
223
|
+
}, Fa = {
|
|
224
224
|
title: "Configuration",
|
|
225
225
|
actions: {
|
|
226
226
|
copy: "Copy JSON"
|
|
@@ -243,6 +243,9 @@ const Ma = {
|
|
|
243
243
|
enabledLabel: "Enabled",
|
|
244
244
|
disabledLabel: "Disabled"
|
|
245
245
|
},
|
|
246
|
+
endpoints: {
|
|
247
|
+
get: "Get"
|
|
248
|
+
},
|
|
246
249
|
copy: {
|
|
247
250
|
tooltip: "Copy {label}",
|
|
248
251
|
success: "Copied!"
|
|
@@ -255,7 +258,7 @@ const Ma = {
|
|
|
255
258
|
entryTitle: "Entry {index}",
|
|
256
259
|
structuredFormat: "Structured"
|
|
257
260
|
}
|
|
258
|
-
},
|
|
261
|
+
}, Na = {
|
|
259
262
|
filterButtonText: "Filter",
|
|
260
263
|
fieldLabel: "Filter by:",
|
|
261
264
|
inputPlaceholder: "Enter a value",
|
|
@@ -263,15 +266,15 @@ const Ma = {
|
|
|
263
266
|
applyButtonText: "Apply",
|
|
264
267
|
clearButtonText: "Clear",
|
|
265
268
|
clearAllButtonText: "Clear all filters"
|
|
266
|
-
},
|
|
269
|
+
}, Ka = {
|
|
267
270
|
errors: {
|
|
268
271
|
fetch: "Could not fetch available items",
|
|
269
272
|
invalid: "Please select a valid value"
|
|
270
273
|
}
|
|
271
|
-
},
|
|
274
|
+
}, qa = {
|
|
272
275
|
unexpected: "An unexpected error has occurred",
|
|
273
276
|
dataKeyUndefined: 'The data key "{dataKey}" does not exist in the response.'
|
|
274
|
-
},
|
|
277
|
+
}, Ba = {
|
|
275
278
|
enable: {
|
|
276
279
|
title: "Enable {entityType}",
|
|
277
280
|
message: "Are you sure you want to enable the {entityType} {entityName}?",
|
|
@@ -283,32 +286,32 @@ const Ma = {
|
|
|
283
286
|
confirmText: "Yes, disable"
|
|
284
287
|
}
|
|
285
288
|
}, La = {
|
|
286
|
-
global:
|
|
287
|
-
deleteModal:
|
|
289
|
+
global: ja,
|
|
290
|
+
deleteModal: Ma,
|
|
288
291
|
baseForm: Oa,
|
|
289
292
|
baseTable: Ea,
|
|
290
|
-
baseConfigCard:
|
|
291
|
-
filter:
|
|
292
|
-
debouncedFilter:
|
|
293
|
-
errors:
|
|
294
|
-
toggleModal:
|
|
293
|
+
baseConfigCard: Fa,
|
|
294
|
+
filter: Na,
|
|
295
|
+
debouncedFilter: Ka,
|
|
296
|
+
errors: qa,
|
|
297
|
+
toggleModal: Ba
|
|
295
298
|
};
|
|
296
299
|
function bt() {
|
|
297
300
|
const e = ht("en-us", La);
|
|
298
301
|
return {
|
|
299
302
|
i18n: e,
|
|
300
|
-
i18nT:
|
|
303
|
+
i18nT: mn(e)
|
|
301
304
|
// Translation component <i18n-t>
|
|
302
305
|
};
|
|
303
306
|
}
|
|
304
|
-
function
|
|
307
|
+
function yn() {
|
|
305
308
|
const e = (t, a) => (a == null ? void 0 : a[t]) ?? void 0, n = (t, a) => {
|
|
306
309
|
if (t.length !== a.length)
|
|
307
310
|
return !1;
|
|
308
311
|
const r = /* @__PURE__ */ new Set([...t, ...a]);
|
|
309
312
|
for (const o of r) {
|
|
310
|
-
const i = t.filter((
|
|
311
|
-
if (i !==
|
|
313
|
+
const i = t.filter((s) => s === o).length, l = a.filter((s) => s === o).length;
|
|
314
|
+
if (i !== l)
|
|
312
315
|
return !1;
|
|
313
316
|
}
|
|
314
317
|
return !0;
|
|
@@ -345,91 +348,91 @@ function gn() {
|
|
|
345
348
|
isValidUuid: (t) => t ? /[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/.test(t) : !1
|
|
346
349
|
};
|
|
347
350
|
}
|
|
348
|
-
function
|
|
351
|
+
function Ua(e, n, t, a = {
|
|
349
352
|
fetchedItemsKey: "data",
|
|
350
353
|
searchKeys: ["id"]
|
|
351
354
|
}) {
|
|
352
355
|
t || (t = "100");
|
|
353
356
|
const { axiosInstance: r } = vt({
|
|
354
357
|
headers: e.requestHeaders
|
|
355
|
-
}), { i18n: { t: o } } = bt(), { debounce: i } = xa(),
|
|
356
|
-
await
|
|
357
|
-
}, 200),
|
|
358
|
+
}), { i18n: { t: o } } = bt(), { debounce: i } = xa(), l = i(async (S) => {
|
|
359
|
+
await U(S);
|
|
360
|
+
}, 200), s = E(!1), u = E(""), p = E(""), c = E([]), h = E([]), d = E(void 0), w = m(n);
|
|
358
361
|
let v = `${e.apiBaseUrl}${w}`;
|
|
359
362
|
e.app === "konnect" ? v = v.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" && (v = v.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : ""));
|
|
360
|
-
const { isValidUuid:
|
|
363
|
+
const { isValidUuid: A } = yn(), y = async () => {
|
|
361
364
|
try {
|
|
362
|
-
|
|
363
|
-
const { data:
|
|
364
|
-
|
|
365
|
+
s.value = !0;
|
|
366
|
+
const { data: S } = await r.get(`${v}?size=${t}`);
|
|
367
|
+
S != null && S.next || (d.value = a.fetchedItemsKey in S ? S[a.fetchedItemsKey] : []), h.value = a.fetchedItemsKey in S ? S[a.fetchedItemsKey] : [], c.value = h.value;
|
|
365
368
|
} catch {
|
|
366
369
|
c.value = [], u.value = o("debouncedFilter.errors.fetch");
|
|
367
370
|
} finally {
|
|
368
|
-
|
|
371
|
+
s.value = !1;
|
|
369
372
|
}
|
|
370
|
-
}, C =
|
|
371
|
-
var
|
|
372
|
-
if (C.value !==
|
|
373
|
-
if (C.value =
|
|
373
|
+
}, C = E(""), U = async (S) => {
|
|
374
|
+
var F, k, K;
|
|
375
|
+
if (C.value !== S)
|
|
376
|
+
if (C.value = S || "", d.value === void 0)
|
|
374
377
|
try {
|
|
375
|
-
if (
|
|
376
|
-
let
|
|
377
|
-
|
|
378
|
-
const { data: b } = await r.get(`${
|
|
378
|
+
if (s.value = !0, u.value = "", p.value = "", e.app === "konnect") {
|
|
379
|
+
let q = v + "";
|
|
380
|
+
S && (q += `/${S}`);
|
|
381
|
+
const { data: b } = await r.get(`${q}?size=${t}`);
|
|
379
382
|
a.fetchedItemsKey in b ? c.value = b[a.fetchedItemsKey] : b != null && b.id ? c.value = [b] : c.value = [];
|
|
380
|
-
} else if (
|
|
381
|
-
const
|
|
382
|
-
S
|
|
383
|
-
const { data:
|
|
384
|
-
return [
|
|
385
|
-
})()) :
|
|
386
|
-
...a.searchKeys.filter((
|
|
387
|
-
const { data:
|
|
388
|
-
return
|
|
383
|
+
} else if (S) {
|
|
384
|
+
const q = [];
|
|
385
|
+
A(S) && a.searchKeys.includes("id") ? q.push((async () => {
|
|
386
|
+
const { data: N } = await r.get(`${v}/${S}`);
|
|
387
|
+
return [N[a.fetchedItemsKey] ?? N];
|
|
388
|
+
})()) : q.push(
|
|
389
|
+
...a.searchKeys.filter((N) => N !== "id").map(async (N) => {
|
|
390
|
+
const { data: V } = await r.get(`${v}?${N}=${S}`);
|
|
391
|
+
return V[a.fetchedItemsKey];
|
|
389
392
|
})
|
|
390
393
|
);
|
|
391
|
-
const b = await Promise.all(
|
|
392
|
-
c.value = [], (
|
|
393
|
-
var
|
|
394
|
-
(
|
|
394
|
+
const b = await Promise.all(q), I = /* @__PURE__ */ new Set();
|
|
395
|
+
c.value = [], (F = b == null ? void 0 : b.forEach) == null || F.call(b, (N) => {
|
|
396
|
+
var V;
|
|
397
|
+
(V = N == null ? void 0 : N.forEach) == null || V.call(N, (_) => {
|
|
395
398
|
I.has(_.id) || (I.add(_.id), c.value.push(_));
|
|
396
399
|
});
|
|
397
400
|
});
|
|
398
401
|
} else
|
|
399
402
|
c.value = h.value;
|
|
400
|
-
} catch (
|
|
401
|
-
((k =
|
|
403
|
+
} catch (q) {
|
|
404
|
+
((k = q == null ? void 0 : q.response) == null ? void 0 : k.status) === 404 ? p.value = o("debouncedFilter.errors.invalid") : (c.value = [], u.value = o("debouncedFilter.errors.fetch"));
|
|
402
405
|
} finally {
|
|
403
|
-
|
|
406
|
+
s.value = !1;
|
|
404
407
|
}
|
|
405
408
|
else
|
|
406
|
-
|
|
409
|
+
s.value = !0, p.value = "", S ? (c.value = (K = d.value) == null ? void 0 : K.filter((q) => {
|
|
407
410
|
var b;
|
|
408
411
|
let I = !1;
|
|
409
|
-
for (const
|
|
410
|
-
const
|
|
411
|
-
|
|
412
|
+
for (const N of a.searchKeys) {
|
|
413
|
+
const V = typeof q[N] == "string" ? (b = q[N]) == null ? void 0 : b.toLowerCase() : q[N];
|
|
414
|
+
V != null && V.includes(S.toLowerCase()) && (I = !0);
|
|
412
415
|
}
|
|
413
416
|
return I;
|
|
414
|
-
}), (!c.value || !c.value.length) && (
|
|
417
|
+
}), (!c.value || !c.value.length) && (p.value = o("debouncedFilter.errors.invalid"))) : c.value = d.value, s.value = !1;
|
|
415
418
|
};
|
|
416
419
|
return {
|
|
417
|
-
loading:
|
|
420
|
+
loading: s,
|
|
418
421
|
error: u,
|
|
419
|
-
validationError:
|
|
422
|
+
validationError: p,
|
|
420
423
|
results: c,
|
|
421
|
-
allRecords:
|
|
422
|
-
loadItems:
|
|
423
|
-
debouncedQueryChange:
|
|
424
|
+
allRecords: d,
|
|
425
|
+
loadItems: y,
|
|
426
|
+
debouncedQueryChange: l
|
|
424
427
|
};
|
|
425
428
|
}
|
|
426
|
-
function
|
|
429
|
+
function Pa(e, n) {
|
|
427
430
|
const t = m(n), a = $(
|
|
428
431
|
() => e.apiBaseUrl.startsWith("/") ? new URL(`${window.location.origin}${t}`) : new URL(t)
|
|
429
432
|
);
|
|
430
433
|
return a.value.search = "", (r) => `${a.value.href}/${r}`;
|
|
431
434
|
}
|
|
432
|
-
function
|
|
435
|
+
function Da() {
|
|
433
436
|
const { i18n: { t: e } } = bt();
|
|
434
437
|
return {
|
|
435
438
|
getMessageFromError: (n) => {
|
|
@@ -457,7 +460,7 @@ function Ua() {
|
|
|
457
460
|
}
|
|
458
461
|
};
|
|
459
462
|
}
|
|
460
|
-
function
|
|
463
|
+
function Va(e) {
|
|
461
464
|
const n = window.location.origin, t = n.endsWith("/") ? n : `${n}/`;
|
|
462
465
|
try {
|
|
463
466
|
const a = e.join("/"), r = `${t}${a}`, o = e.some((i) => i.trim() === "");
|
|
@@ -468,36 +471,36 @@ function Ra(e) {
|
|
|
468
471
|
return console.warn("Failed to build valid URL:", a), "";
|
|
469
472
|
}
|
|
470
473
|
}
|
|
471
|
-
function
|
|
472
|
-
const t =
|
|
474
|
+
function hn(e, n) {
|
|
475
|
+
const t = E(m(e)), a = E(m(n)), r = $(
|
|
473
476
|
() => !!(t.value.app === "konnect" || t.value.isExactMatch)
|
|
474
477
|
), o = $(
|
|
475
478
|
() => a.value.startsWith("/") ? new URL(`${window.location.origin}${a.value}`) : new URL(a.value)
|
|
476
479
|
);
|
|
477
480
|
return (i) => {
|
|
478
|
-
const { page:
|
|
481
|
+
const { page: l, pageSize: s, offset: u, sortColumnKey: p, sortColumnOrder: c, query: h } = i;
|
|
479
482
|
try {
|
|
480
|
-
let
|
|
481
|
-
return r.value && h ? (
|
|
482
|
-
|
|
483
|
-
}),
|
|
484
|
-
} catch (
|
|
485
|
-
return console.error("RouteList(fetcher)",
|
|
483
|
+
let d = new URL(o.value.href);
|
|
484
|
+
return r.value && h ? (d.search = "", d = t.value.app === "konnect" ? new URL(`${d.href}?filter[name][contains]=${h}`) : new URL(`${d.href}/${h}/`)) : (r.value || new URLSearchParams(h).forEach((w, v) => {
|
|
485
|
+
d.searchParams.append(v, w);
|
|
486
|
+
}), p && d.searchParams.append("sort_by", p), c === "desc" && d.searchParams.append("sort_desc", "1"), d.searchParams.append("size", String(s))), u && l !== 1 && d.searchParams.append("offset", String(u)), d.href;
|
|
487
|
+
} catch (d) {
|
|
488
|
+
return console.error("RouteList(fetcher)", d), a.value;
|
|
486
489
|
}
|
|
487
490
|
};
|
|
488
491
|
}
|
|
489
|
-
function
|
|
492
|
+
function Ra(e, n, t = "data") {
|
|
490
493
|
const a = m(n), { axiosInstance: r } = vt({
|
|
491
494
|
headers: e.requestHeaders
|
|
492
|
-
}), o =
|
|
493
|
-
status:
|
|
495
|
+
}), o = hn(e, a), i = E({
|
|
496
|
+
status: Se.Idle
|
|
494
497
|
});
|
|
495
|
-
return { fetcher: async (
|
|
498
|
+
return { fetcher: async (l) => {
|
|
496
499
|
try {
|
|
497
|
-
i.value = { status:
|
|
498
|
-
const
|
|
500
|
+
i.value = { status: Se.Loading };
|
|
501
|
+
const s = o(l), { data: u } = await r.get(s), p = t && t.replace(/[^\w-_]/gi, "");
|
|
499
502
|
let c;
|
|
500
|
-
u[
|
|
503
|
+
u[p] && Array.isArray(u[p]) ? c = u[p] : Array.isArray(u) ? c = u : c = Object.keys(u).length ? [u] : [];
|
|
501
504
|
const h = {
|
|
502
505
|
data: c,
|
|
503
506
|
total: c.length,
|
|
@@ -508,22 +511,22 @@ function Da(e, n, t = "data") {
|
|
|
508
511
|
} : null
|
|
509
512
|
};
|
|
510
513
|
return i.value = {
|
|
511
|
-
status:
|
|
514
|
+
status: Se.Idle,
|
|
512
515
|
response: h
|
|
513
516
|
}, h;
|
|
514
|
-
} catch (
|
|
517
|
+
} catch (s) {
|
|
515
518
|
const u = {
|
|
516
519
|
data: [],
|
|
517
520
|
total: 0
|
|
518
521
|
};
|
|
519
|
-
return
|
|
520
|
-
status:
|
|
522
|
+
return l.query && s.response.status === 404 ? (i.value = {
|
|
523
|
+
status: Se.NoResults,
|
|
521
524
|
response: u,
|
|
522
|
-
error:
|
|
525
|
+
error: s
|
|
523
526
|
}, u) : (i.value = {
|
|
524
|
-
status:
|
|
527
|
+
status: Se.Error,
|
|
525
528
|
response: u,
|
|
526
|
-
error:
|
|
529
|
+
error: s
|
|
527
530
|
}, u);
|
|
528
531
|
}
|
|
529
532
|
}, fetcherState: i };
|
|
@@ -535,22 +538,22 @@ function Ga() {
|
|
|
535
538
|
convertKeyToTitle: e
|
|
536
539
|
};
|
|
537
540
|
}
|
|
538
|
-
const
|
|
541
|
+
const vn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, Bt = (e) => {
|
|
539
542
|
if (typeof e != "string")
|
|
540
543
|
throw new TypeError("Invalid argument expected string");
|
|
541
|
-
const n = e.match(
|
|
544
|
+
const n = e.match(vn);
|
|
542
545
|
if (!n)
|
|
543
546
|
throw new Error(`Invalid argument not valid semver ('${e}' received)`);
|
|
544
547
|
return n.shift(), n;
|
|
545
|
-
}, Lt = (e) => e === "*" || e === "x" || e === "X",
|
|
548
|
+
}, Lt = (e) => e === "*" || e === "x" || e === "X", Ut = (e) => {
|
|
546
549
|
const n = parseInt(e, 10);
|
|
547
550
|
return isNaN(n) ? e : n;
|
|
548
551
|
}, Ha = (e, n) => typeof e != typeof n ? [String(e), String(n)] : [e, n], za = (e, n) => {
|
|
549
552
|
if (Lt(e) || Lt(n))
|
|
550
553
|
return 0;
|
|
551
|
-
const [t, a] = Ha(
|
|
554
|
+
const [t, a] = Ha(Ut(e), Ut(n));
|
|
552
555
|
return t > a ? 1 : t < a ? -1 : 0;
|
|
553
|
-
},
|
|
556
|
+
}, Pt = (e, n) => {
|
|
554
557
|
for (let t = 0; t < Math.max(e.length, n.length); t++) {
|
|
555
558
|
const a = za(e[t] || "0", n[t] || "0");
|
|
556
559
|
if (a !== 0)
|
|
@@ -558,40 +561,40 @@ const hn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
558
561
|
}
|
|
559
562
|
return 0;
|
|
560
563
|
}, Ja = (e, n) => {
|
|
561
|
-
const t =
|
|
562
|
-
return i !== 0 ? i : r && o ?
|
|
563
|
-
},
|
|
564
|
-
|
|
564
|
+
const t = Bt(e), a = Bt(n), r = t.pop(), o = a.pop(), i = Pt(t, a);
|
|
565
|
+
return i !== 0 ? i : r && o ? Pt(r.split("."), o.split(".")) : r || o ? r ? -1 : 1 : 0;
|
|
566
|
+
}, Dt = (e, n, t) => {
|
|
567
|
+
Wa(t);
|
|
565
568
|
const a = Ja(e, n);
|
|
566
|
-
return
|
|
567
|
-
},
|
|
569
|
+
return bn[t].includes(a);
|
|
570
|
+
}, bn = {
|
|
568
571
|
">": [1],
|
|
569
572
|
">=": [0, 1],
|
|
570
573
|
"=": [0],
|
|
571
574
|
"<=": [-1, 0],
|
|
572
575
|
"<": [-1],
|
|
573
576
|
"!=": [-1, 1]
|
|
574
|
-
},
|
|
577
|
+
}, Vt = Object.keys(bn), Wa = (e) => {
|
|
575
578
|
if (typeof e != "string")
|
|
576
579
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
577
|
-
if (
|
|
578
|
-
throw new Error(`Invalid operator, expected one of ${
|
|
579
|
-
},
|
|
580
|
+
if (Vt.indexOf(e) === -1)
|
|
581
|
+
throw new Error(`Invalid operator, expected one of ${Vt.join("|")}`);
|
|
582
|
+
}, Ya = (e) => typeof e == "string" && /^[v\d]/.test(e) && vn.test(e);
|
|
580
583
|
function Za(e) {
|
|
581
584
|
const { gatewayInfo: n, supportedRange: t } = e;
|
|
582
585
|
if (!n)
|
|
583
586
|
return !0;
|
|
584
587
|
const { edition: a, version: r } = n;
|
|
585
|
-
if (!
|
|
588
|
+
if (!Ya(r))
|
|
586
589
|
return console.error("Invalid version"), !1;
|
|
587
590
|
const o = t[a];
|
|
588
591
|
if (!o)
|
|
589
592
|
return !1;
|
|
590
|
-
const [i,
|
|
591
|
-
return !(i &&
|
|
593
|
+
const [i, l] = o;
|
|
594
|
+
return !(i && Dt(r, i, "<") || l && Dt(r, l, ">"));
|
|
592
595
|
}
|
|
593
596
|
function Qa(e) {
|
|
594
|
-
const n =
|
|
597
|
+
const n = E(0), t = E(0), a = E(!1);
|
|
595
598
|
return ve(e, (r) => {
|
|
596
599
|
r && !a.value && (n.value = r.offsetWidth, t.value = r.scrollWidth, a.value = !0);
|
|
597
600
|
}), {
|
|
@@ -600,13 +603,13 @@ function Qa(e) {
|
|
|
600
603
|
}
|
|
601
604
|
const oe = {
|
|
602
605
|
useAxios: vt,
|
|
603
|
-
useDebouncedFilter:
|
|
604
|
-
useDeleteUrlBuilder:
|
|
605
|
-
useErrors:
|
|
606
|
-
useExternalLinkCreator:
|
|
607
|
-
useFetcher:
|
|
608
|
-
useFetchUrlBuilder:
|
|
609
|
-
useHelpers:
|
|
606
|
+
useDebouncedFilter: Ua,
|
|
607
|
+
useDeleteUrlBuilder: Pa,
|
|
608
|
+
useErrors: Da,
|
|
609
|
+
useExternalLinkCreator: Va,
|
|
610
|
+
useFetcher: Ra,
|
|
611
|
+
useFetchUrlBuilder: hn,
|
|
612
|
+
useHelpers: yn,
|
|
610
613
|
useStringHelpers: Ga,
|
|
611
614
|
useI18n: bt,
|
|
612
615
|
useGatewayFeatureSupported: Za,
|
|
@@ -620,18 +623,18 @@ const oe = {
|
|
|
620
623
|
}, er = "Copy to clipboard", tr = {
|
|
621
624
|
message: Xa,
|
|
622
625
|
iconTitle: er
|
|
623
|
-
}, nr = "kong-ui-copy-uuid-notify",
|
|
626
|
+
}, nr = "kong-ui-copy-uuid-notify", Rt = "24px", ar = (e, n) => {
|
|
624
627
|
const t = e.__vccOpts || e;
|
|
625
628
|
for (const [a, r] of n)
|
|
626
629
|
t[a] = r;
|
|
627
630
|
return t;
|
|
628
|
-
}, rr = (e) => (
|
|
631
|
+
}, rr = (e) => (pn("data-v-641e0aee"), e = e(), fn(), e), or = ["aria-hidden"], ir = {
|
|
629
632
|
key: 0,
|
|
630
633
|
"data-testid": "kui-icon-svg-title"
|
|
631
|
-
},
|
|
634
|
+
}, lr = /* @__PURE__ */ rr(() => /* @__PURE__ */ B("path", {
|
|
632
635
|
d: "M5 22C4.45 22 3.97917 21.8042 3.5875 21.4125C3.19583 21.0208 3 20.55 3 20V6H5V20H16V22H5ZM9 18C8.45 18 7.97917 17.8042 7.5875 17.4125C7.19583 17.0208 7 16.55 7 16V4C7 3.45 7.19583 2.97917 7.5875 2.5875C7.97917 2.19583 8.45 2 9 2H18C18.55 2 19.0208 2.19583 19.4125 2.5875C19.8042 2.97917 20 3.45 20 4V16C20 16.55 19.8042 17.0208 19.4125 17.4125C19.0208 17.8042 18.55 18 18 18H9ZM9 16H18V4H9V16Z",
|
|
633
636
|
fill: "currentColor"
|
|
634
|
-
}, null, -1)),
|
|
637
|
+
}, null, -1)), sr = /* @__PURE__ */ ne({
|
|
635
638
|
__name: "CopyIcon",
|
|
636
639
|
props: {
|
|
637
640
|
/** The accessibility text provided to screen readers */
|
|
@@ -662,7 +665,7 @@ const oe = {
|
|
|
662
665
|
size: {
|
|
663
666
|
type: [Number, String],
|
|
664
667
|
required: !1,
|
|
665
|
-
default:
|
|
668
|
+
default: Rt,
|
|
666
669
|
// if setting to the imported const fails, just pass a number of 24 as the default.
|
|
667
670
|
validator: (e) => {
|
|
668
671
|
if (typeof e == "number" && e > 0)
|
|
@@ -691,7 +694,7 @@ const oe = {
|
|
|
691
694
|
if (o && !isNaN(o) && Number.isInteger(o) && o > 0)
|
|
692
695
|
return `${o}px`;
|
|
693
696
|
}
|
|
694
|
-
return
|
|
697
|
+
return Rt;
|
|
695
698
|
}), a = $(() => ({
|
|
696
699
|
boxSizing: "border-box",
|
|
697
700
|
color: n.color,
|
|
@@ -700,14 +703,14 @@ const oe = {
|
|
|
700
703
|
lineHeight: "0",
|
|
701
704
|
width: t.value
|
|
702
705
|
}));
|
|
703
|
-
return (r, o) => (
|
|
706
|
+
return (r, o) => (f(), R(Fe(e.as), {
|
|
704
707
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
705
708
|
class: "kui-icon copy-icon",
|
|
706
709
|
"data-testid": "kui-icon-wrapper-copy-icon",
|
|
707
|
-
style:
|
|
710
|
+
style: dn(a.value)
|
|
708
711
|
}, {
|
|
709
|
-
default:
|
|
710
|
-
(
|
|
712
|
+
default: g(() => [
|
|
713
|
+
(f(), T("svg", {
|
|
711
714
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
712
715
|
"data-testid": "kui-icon-svg-copy-icon",
|
|
713
716
|
fill: "none",
|
|
@@ -717,14 +720,14 @@ const oe = {
|
|
|
717
720
|
width: "100%",
|
|
718
721
|
xmlns: "http://www.w3.org/2000/svg"
|
|
719
722
|
}, [
|
|
720
|
-
e.title ? (
|
|
721
|
-
|
|
723
|
+
e.title ? (f(), T("title", ir, j(e.title), 1)) : H("", !0),
|
|
724
|
+
lr
|
|
722
725
|
], 8, or))
|
|
723
726
|
]),
|
|
724
727
|
_: 1
|
|
725
728
|
}, 8, ["aria-hidden", "style"]));
|
|
726
729
|
}
|
|
727
|
-
}), ur = /* @__PURE__ */ ar(
|
|
730
|
+
}), ur = /* @__PURE__ */ ar(sr, [["__scopeId", "data-v-641e0aee"]]), cr = "16px", dr = { class: "kong-ui-copy-uuid" }, pr = ["onClick"], Gt = 15, fr = /* @__PURE__ */ ne({
|
|
728
731
|
__name: "CopyUuid",
|
|
729
732
|
props: {
|
|
730
733
|
uuid: {
|
|
@@ -775,59 +778,59 @@ const oe = {
|
|
|
775
778
|
placement: "bottomStart"
|
|
776
779
|
} : {
|
|
777
780
|
title: a.uuid
|
|
778
|
-
}),
|
|
779
|
-
label:
|
|
781
|
+
}), l = $(() => !!(a.tooltip && a.successTooltip)), s = E(a.tooltip), u = $(() => a.tooltip ? {
|
|
782
|
+
label: s.value,
|
|
780
783
|
positionFixed: !0,
|
|
781
784
|
maxWidth: "500px",
|
|
782
785
|
placement: "bottomStart"
|
|
783
|
-
} : {}),
|
|
784
|
-
var
|
|
785
|
-
return a.format === "redacted" ? "*****" : a.format === "deleted" ? `*${(
|
|
786
|
-
}), c = (
|
|
787
|
-
|
|
788
|
-
|
|
786
|
+
} : {}), p = $(() => {
|
|
787
|
+
var d;
|
|
788
|
+
return a.format === "redacted" ? "*****" : a.format === "deleted" ? `*${(d = a.uuid) == null ? void 0 : d.substring(0, 5)}` : a.uuid;
|
|
789
|
+
}), c = (d) => {
|
|
790
|
+
s.value = d, setTimeout(() => {
|
|
791
|
+
s.value = a.tooltip;
|
|
789
792
|
}, 1800);
|
|
790
|
-
}, h = (
|
|
793
|
+
}, h = (d) => {
|
|
791
794
|
var w, v;
|
|
792
|
-
if (!
|
|
795
|
+
if (!d(a.uuid)) {
|
|
793
796
|
typeof o == "function" && o({
|
|
794
797
|
type: "error",
|
|
795
798
|
message: t("message.fail")
|
|
796
|
-
}),
|
|
799
|
+
}), l.value ? c(t("message.fail")) : r("error", a.uuid);
|
|
797
800
|
return;
|
|
798
801
|
}
|
|
799
|
-
const
|
|
802
|
+
const A = ((w = a.uuid) == null ? void 0 : w.length) > Gt, y = a.format === "hidden" || a.format === "redacted" ? t("message.success.prefix") : `"${((v = a.uuid) == null ? void 0 : v.substring(0, Gt)) + (A ? "..." : "")}"`;
|
|
800
803
|
typeof o == "function" && o({
|
|
801
804
|
type: "success",
|
|
802
|
-
message: `${
|
|
803
|
-
}),
|
|
805
|
+
message: `${y}${t("message.success.content")}`
|
|
806
|
+
}), l.value ? c(a.successTooltip) : r("success", a.uuid);
|
|
804
807
|
};
|
|
805
|
-
return (
|
|
806
|
-
const v =
|
|
807
|
-
return
|
|
808
|
-
e.format !== "hidden" ? (
|
|
809
|
-
default:
|
|
808
|
+
return (d, w) => {
|
|
809
|
+
const v = D("KClipboardProvider");
|
|
810
|
+
return f(), T("div", dr, [
|
|
811
|
+
e.format !== "hidden" ? (f(), R(Fe(e.idTooltip ? "KTooltip" : "div"), st({ key: 0 }, i.value, { "data-testid": "copy-id" }), {
|
|
812
|
+
default: g(() => [
|
|
810
813
|
B("div", {
|
|
811
|
-
class:
|
|
814
|
+
class: Ie([
|
|
812
815
|
"uuid-container",
|
|
813
816
|
e.truncated ? "truncated-uuid" : null,
|
|
814
817
|
e.useMono ? "mono" : null
|
|
815
818
|
])
|
|
816
|
-
},
|
|
819
|
+
}, j(p.value), 3)
|
|
817
820
|
]),
|
|
818
821
|
_: 1
|
|
819
822
|
}, 16)) : H("", !0),
|
|
820
|
-
(
|
|
821
|
-
default:
|
|
822
|
-
|
|
823
|
-
default:
|
|
823
|
+
(f(), R(Fe(e.tooltip ? "KTooltip" : "div"), st(u.value, { class: "uuid-icon-wrapper" }), {
|
|
824
|
+
default: g(() => [
|
|
825
|
+
O(v, null, {
|
|
826
|
+
default: g(({ copyToClipboard: A }) => [
|
|
824
827
|
B("span", {
|
|
825
828
|
"data-testid": "copy-to-clipboard",
|
|
826
829
|
role: "button",
|
|
827
830
|
tabindex: "0",
|
|
828
|
-
onClick: Ge((
|
|
831
|
+
onClick: Ge((y) => h(A), ["stop"])
|
|
829
832
|
}, [
|
|
830
|
-
|
|
833
|
+
O(m(ur), {
|
|
831
834
|
class: "uuid-icon",
|
|
832
835
|
color: e.iconColor,
|
|
833
836
|
decorative: !!e.tooltip,
|
|
@@ -849,7 +852,7 @@ const oe = {
|
|
|
849
852
|
for (const [a, r] of n)
|
|
850
853
|
t[a] = r;
|
|
851
854
|
return t;
|
|
852
|
-
},
|
|
855
|
+
}, Cn = /* @__PURE__ */ mr(fr, [["__scopeId", "data-v-0c07874b"]]), gr = {
|
|
853
856
|
key: 0,
|
|
854
857
|
class: "config-card-fieldset-title"
|
|
855
858
|
}, yr = /* @__PURE__ */ ne({
|
|
@@ -870,25 +873,25 @@ const oe = {
|
|
|
870
873
|
},
|
|
871
874
|
setup(e) {
|
|
872
875
|
const n = e, { i18n: { t } } = oe.useI18n(), { convertKeyToTitle: a } = oe.useStringHelpers(), r = $(() => n.item.key ?? "json-array-item"), o = $(() => n.item.value ?? n.item), i = $(() => {
|
|
873
|
-
const
|
|
874
|
-
return n.isArrayItem && delete
|
|
875
|
-
}),
|
|
876
|
-
var
|
|
877
|
-
return n.isArrayItem ? (
|
|
876
|
+
const s = JSON.parse(JSON.stringify(o.value));
|
|
877
|
+
return n.isArrayItem && delete s.name, s;
|
|
878
|
+
}), l = $(() => {
|
|
879
|
+
var s;
|
|
880
|
+
return n.isArrayItem ? (s = o.value) != null && s.name ? a(o.value.name, "_") : t("baseConfigCard.general.entryTitle", { index: n.index }) : "";
|
|
878
881
|
});
|
|
879
|
-
return (
|
|
880
|
-
class:
|
|
882
|
+
return (s, u) => (f(), R(Fe(e.isArrayItem ? "fieldset" : "div"), {
|
|
883
|
+
class: Ie(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
881
884
|
}, {
|
|
882
|
-
default:
|
|
883
|
-
e.isArrayItem ? (
|
|
884
|
-
B("b", null,
|
|
885
|
+
default: g(() => [
|
|
886
|
+
e.isArrayItem ? (f(), T("legend", gr, [
|
|
887
|
+
B("b", null, j(l.value), 1)
|
|
885
888
|
])) : H("", !0),
|
|
886
|
-
(
|
|
889
|
+
(f(!0), T(me, null, pe(Object.keys(i.value), (p, c) => (f(), R(Ct, {
|
|
887
890
|
key: `${r.value}-property-${c}`,
|
|
888
891
|
item: {
|
|
889
|
-
key:
|
|
890
|
-
label: m(a)(
|
|
891
|
-
value: i.value[
|
|
892
|
+
key: p,
|
|
893
|
+
label: m(a)(p),
|
|
894
|
+
value: i.value[p]
|
|
892
895
|
}
|
|
893
896
|
}, null, 8, ["item"]))), 128))
|
|
894
897
|
]),
|
|
@@ -900,7 +903,7 @@ const oe = {
|
|
|
900
903
|
for (const [a, r] of n)
|
|
901
904
|
t[a] = r;
|
|
902
905
|
return t;
|
|
903
|
-
},
|
|
906
|
+
}, kn = /* @__PURE__ */ ge(yr, [["__scopeId", "data-v-68ca83ec"]]), hr = /* @__PURE__ */ ne({
|
|
904
907
|
__name: "InternalLinkItem",
|
|
905
908
|
props: {
|
|
906
909
|
item: {
|
|
@@ -912,15 +915,15 @@ const oe = {
|
|
|
912
915
|
setup(e) {
|
|
913
916
|
const { i18n: { t: n } } = oe.useI18n();
|
|
914
917
|
return (t, a) => {
|
|
915
|
-
const r =
|
|
916
|
-
return
|
|
917
|
-
|
|
918
|
+
const r = D("KButton");
|
|
919
|
+
return f(), T("div", null, [
|
|
920
|
+
O(r, {
|
|
918
921
|
appearance: "tertiary",
|
|
919
922
|
class: "navigation-button",
|
|
920
923
|
onClick: a[0] || (a[0] = (o) => t.$emit("navigation-click", e.item))
|
|
921
924
|
}, {
|
|
922
|
-
default:
|
|
923
|
-
|
|
925
|
+
default: g(() => [
|
|
926
|
+
W(j(e.item.value || m(n)("baseConfigCard.commonFields.link")), 1)
|
|
924
927
|
]),
|
|
925
928
|
_: 1
|
|
926
929
|
})
|
|
@@ -938,22 +941,22 @@ const oe = {
|
|
|
938
941
|
setup(e) {
|
|
939
942
|
const { i18n: { t: n } } = oe.useI18n();
|
|
940
943
|
return (t, a) => {
|
|
941
|
-
const r =
|
|
942
|
-
return
|
|
944
|
+
const r = D("KBadge");
|
|
945
|
+
return f(), R(r, {
|
|
943
946
|
appearance: e.status ? "success" : "neutral"
|
|
944
947
|
}, {
|
|
945
|
-
default:
|
|
946
|
-
|
|
948
|
+
default: g(() => [
|
|
949
|
+
W(j(e.status ? m(n)("baseConfigCard.statusBadge.enabledLabel") : m(n)("baseConfigCard.statusBadge.disabledLabel")), 1)
|
|
947
950
|
]),
|
|
948
951
|
_: 1
|
|
949
952
|
}, 8, ["appearance"]);
|
|
950
953
|
};
|
|
951
954
|
}
|
|
952
|
-
}), Cr = "#0044f4", kr = "#e0e4ea", wr = "#3a3f51", Ir = "1px", _r = "20px",
|
|
955
|
+
}), Cr = "#0044f4", kr = "#e0e4ea", wr = "#3a3f51", Ir = "1px", _r = "20px", Sr = { class: "config-card-details-row" }, Ar = ["data-testid"], xr = ["data-testid"], Tr = ["data-testid"], $r = ["data-testid"], jr = { key: 1 }, Mr = ["data-testid"], Or = ["data-testid"], Er = ["data-testid"], Fr = ["data-testid"], Nr = {
|
|
953
956
|
name: "ConfigCardItem",
|
|
954
|
-
components: { CopyUuid:
|
|
955
|
-
},
|
|
956
|
-
...
|
|
957
|
+
components: { CopyUuid: Cn, JsonCardItem: kn, StatusBadge: br, InternalLinkItem: vr }
|
|
958
|
+
}, Kr = /* @__PURE__ */ ne({
|
|
959
|
+
...Nr,
|
|
957
960
|
props: {
|
|
958
961
|
item: {
|
|
959
962
|
type: Object,
|
|
@@ -972,13 +975,13 @@ const oe = {
|
|
|
972
975
|
},
|
|
973
976
|
emits: ["navigation-click"],
|
|
974
977
|
setup(e, { emit: n }) {
|
|
975
|
-
|
|
976
|
-
"0da74440":
|
|
977
|
-
"02a039da": u.value &&
|
|
978
|
-
"690f3ced": u.value &&
|
|
979
|
-
"691182c8": u.value &&
|
|
978
|
+
cn((w) => ({
|
|
979
|
+
"0da74440": p.value ? "none" : `solid ${m(Ir)} ${m(kr)}`,
|
|
980
|
+
"02a039da": u.value && l.value ? "block" : "flex",
|
|
981
|
+
"690f3ced": u.value && l.value ? "100%" : t.slim ? "50%" : "25%",
|
|
982
|
+
"691182c8": u.value && l.value ? "100%" : t.slim ? "50%" : "75%"
|
|
980
983
|
}));
|
|
981
|
-
const t = e, a = n, r = Ze(), { i18n: { t: o, formatUnixTimeStamp: i } } = oe.useI18n(),
|
|
984
|
+
const t = e, a = n, r = Ze(), { i18n: { t: o, formatUnixTimeStamp: i } } = oe.useI18n(), l = $(() => t.item.value !== void 0 && t.item.value !== null && t.item.value !== ""), s = $(() => !!(t.item.tooltip || r["label-tooltip"])), u = $(() => t.item.type === ee.Json || t.item.type === ee.JsonArray), p = $(() => t.item.type === ee.JsonArray), c = $(() => {
|
|
982
985
|
switch (t.item.type) {
|
|
983
986
|
case ee.ID:
|
|
984
987
|
return {
|
|
@@ -1104,29 +1107,29 @@ const oe = {
|
|
|
1104
1107
|
text: t.item.value
|
|
1105
1108
|
};
|
|
1106
1109
|
}
|
|
1107
|
-
}), h =
|
|
1110
|
+
}), h = E(), { isTruncated: d } = oe.useTruncationDetector(h);
|
|
1108
1111
|
return (w, v) => {
|
|
1109
|
-
const
|
|
1110
|
-
return
|
|
1112
|
+
const A = D("KLabel"), y = D("KBadge"), C = D("KTooltip");
|
|
1113
|
+
return f(), T("div", Sr, [
|
|
1111
1114
|
B("div", {
|
|
1112
1115
|
class: "config-card-details-label",
|
|
1113
1116
|
"data-testid": `${e.item.key}-label`
|
|
1114
1117
|
}, [
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
default:
|
|
1118
|
-
|
|
1118
|
+
Z(w.$slots, "label", { item: e.item }, () => [
|
|
1119
|
+
O(A, { "tooltip-attributes": { maxWidth: "500px" } }, ke({
|
|
1120
|
+
default: g(() => [
|
|
1121
|
+
W(j(e.item.label) + " ", 1)
|
|
1119
1122
|
]),
|
|
1120
1123
|
_: 2
|
|
1121
1124
|
}, [
|
|
1122
|
-
|
|
1125
|
+
s.value ? {
|
|
1123
1126
|
name: "tooltip",
|
|
1124
|
-
fn:
|
|
1127
|
+
fn: g(() => [
|
|
1125
1128
|
B("div", {
|
|
1126
1129
|
"data-testid": `${e.item.key}-label-tooltip`
|
|
1127
1130
|
}, [
|
|
1128
|
-
|
|
1129
|
-
|
|
1131
|
+
Z(w.$slots, "label-tooltip", {}, () => [
|
|
1132
|
+
W(j(e.item.tooltip), 1)
|
|
1130
1133
|
], !0)
|
|
1131
1134
|
], 8, xr)
|
|
1132
1135
|
]),
|
|
@@ -1134,88 +1137,88 @@ const oe = {
|
|
|
1134
1137
|
} : void 0
|
|
1135
1138
|
]), 1024)
|
|
1136
1139
|
], !0)
|
|
1137
|
-
], 8,
|
|
1140
|
+
], 8, Ar),
|
|
1138
1141
|
B("div", {
|
|
1139
1142
|
class: "config-card-details-value",
|
|
1140
1143
|
"data-testid": `${e.item.key}-property-value`
|
|
1141
1144
|
}, [
|
|
1142
|
-
|
|
1145
|
+
Z(w.$slots, e.item.key, {
|
|
1143
1146
|
rowValue: e.item.value
|
|
1144
1147
|
}, () => [
|
|
1145
|
-
|
|
1146
|
-
(
|
|
1147
|
-
default:
|
|
1148
|
-
c.value.additionalComponent === "KBadge" ? (
|
|
1148
|
+
l.value ? (f(), T("div", jr, [
|
|
1149
|
+
(f(), R(Fe(c.value.tag), ya(ha(c.value.attrs)), {
|
|
1150
|
+
default: g(() => [
|
|
1151
|
+
c.value.additionalComponent === "KBadge" ? (f(), T("div", {
|
|
1149
1152
|
key: 0,
|
|
1150
1153
|
"data-testid": `${e.item.key}-badge-tags`
|
|
1151
1154
|
}, [
|
|
1152
|
-
(
|
|
1153
|
-
key: `${e.item.key}-badge-tag-${
|
|
1155
|
+
(f(!0), T(me, null, pe(e.item.value, (U, S) => (f(), R(y, {
|
|
1156
|
+
key: `${e.item.key}-badge-tag-${S}`,
|
|
1154
1157
|
class: "config-badge",
|
|
1155
|
-
"data-testid": `${e.item.key}-badge-tag-${
|
|
1156
|
-
tooltip:
|
|
1158
|
+
"data-testid": `${e.item.key}-badge-tag-${S}`,
|
|
1159
|
+
tooltip: U,
|
|
1157
1160
|
"truncation-tooltip": ""
|
|
1158
1161
|
}, {
|
|
1159
|
-
default:
|
|
1160
|
-
|
|
1162
|
+
default: g(() => [
|
|
1163
|
+
W(j(U), 1)
|
|
1161
1164
|
]),
|
|
1162
1165
|
_: 2
|
|
1163
1166
|
}, 1032, ["data-testid", "tooltip"]))), 128))
|
|
1164
|
-
], 8,
|
|
1165
|
-
c.value.additionalComponent === "CopyUuid" ? (
|
|
1167
|
+
], 8, Mr)) : H("", !0),
|
|
1168
|
+
c.value.additionalComponent === "CopyUuid" ? (f(), T("div", {
|
|
1166
1169
|
key: 1,
|
|
1167
1170
|
class: "copy-uuid-array",
|
|
1168
1171
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
1169
1172
|
}, [
|
|
1170
|
-
(
|
|
1171
|
-
key: `${e.item.key}-copy-uuid-${
|
|
1172
|
-
"data-testid": `${e.item.key}-copy-uuid-${
|
|
1173
|
-
uuid:
|
|
1173
|
+
(f(!0), T(me, null, pe(e.item.value, (U, S) => (f(), R(m(Cn), st(c.value.childAttrs, {
|
|
1174
|
+
key: `${e.item.key}-copy-uuid-${S}`,
|
|
1175
|
+
"data-testid": `${e.item.key}-copy-uuid-${S}`,
|
|
1176
|
+
uuid: U
|
|
1174
1177
|
}), null, 16, ["data-testid", "uuid"]))), 128))
|
|
1175
|
-
], 8, Or)) : c.value.additionalComponent === "KMethodBadge" ? (
|
|
1178
|
+
], 8, Or)) : c.value.additionalComponent === "KMethodBadge" ? (f(), T("div", {
|
|
1176
1179
|
key: 2,
|
|
1177
1180
|
class: "method-badge-array",
|
|
1178
1181
|
"data-testid": `${e.item.key}-badge-methods`
|
|
1179
1182
|
}, [
|
|
1180
|
-
(
|
|
1181
|
-
key: `${e.item.key}-badge-method-${
|
|
1182
|
-
appearance: Object.values(m(Ia)).includes(
|
|
1183
|
+
(f(!0), T(me, null, pe(e.item.value, (U, S) => (f(), R(y, {
|
|
1184
|
+
key: `${e.item.key}-badge-method-${S}`,
|
|
1185
|
+
appearance: Object.values(m(Ia)).includes(U.toLowerCase()) ? U.toLowerCase() : "custom",
|
|
1183
1186
|
class: "config-badge",
|
|
1184
|
-
"data-testid": `${e.item.key}-badge-method-${
|
|
1187
|
+
"data-testid": `${e.item.key}-badge-method-${S}`
|
|
1185
1188
|
}, {
|
|
1186
|
-
default:
|
|
1187
|
-
|
|
1189
|
+
default: g(() => [
|
|
1190
|
+
W(j(U), 1)
|
|
1188
1191
|
]),
|
|
1189
1192
|
_: 2
|
|
1190
1193
|
}, 1032, ["appearance", "data-testid"]))), 128))
|
|
1191
1194
|
], 8, Er)) : H("", !0),
|
|
1192
|
-
c.value.additionalComponent === "JsonCardItem" ? (
|
|
1195
|
+
c.value.additionalComponent === "JsonCardItem" ? (f(), T("div", {
|
|
1193
1196
|
key: 3,
|
|
1194
1197
|
"data-testid": `${t.item.key}-json-array-content`
|
|
1195
1198
|
}, [
|
|
1196
|
-
(
|
|
1197
|
-
key: `json-array-item-${
|
|
1198
|
-
index:
|
|
1199
|
+
(f(!0), T(me, null, pe(e.item.value, (U, S) => (f(), R(kn, {
|
|
1200
|
+
key: `json-array-item-${S}`,
|
|
1201
|
+
index: S,
|
|
1199
1202
|
"is-array-item": "",
|
|
1200
|
-
item:
|
|
1203
|
+
item: U
|
|
1201
1204
|
}, null, 8, ["index", "item"]))), 128))
|
|
1202
|
-
], 8,
|
|
1205
|
+
], 8, Fr)) : (f(), R(C, {
|
|
1203
1206
|
key: 4,
|
|
1204
|
-
label: m(
|
|
1207
|
+
label: m(d) ? e.item.value : ""
|
|
1205
1208
|
}, {
|
|
1206
|
-
default:
|
|
1209
|
+
default: g(() => [
|
|
1207
1210
|
B("span", {
|
|
1208
1211
|
ref_key: "textContent",
|
|
1209
1212
|
ref: h,
|
|
1210
|
-
class:
|
|
1211
|
-
},
|
|
1213
|
+
class: Ie(["attrs-data-text", { truncated: e.truncated }])
|
|
1214
|
+
}, j(c.value.text), 3)
|
|
1212
1215
|
]),
|
|
1213
1216
|
_: 1
|
|
1214
1217
|
}, 8, ["label"]))
|
|
1215
1218
|
]),
|
|
1216
1219
|
_: 1
|
|
1217
1220
|
}, 16))
|
|
1218
|
-
])) : (
|
|
1221
|
+
])) : (f(), T("div", {
|
|
1219
1222
|
key: 0,
|
|
1220
1223
|
"data-testid": `${e.item.key}-no-value`
|
|
1221
1224
|
}, " – ", 8, $r))
|
|
@@ -1224,16 +1227,16 @@ const oe = {
|
|
|
1224
1227
|
]);
|
|
1225
1228
|
};
|
|
1226
1229
|
}
|
|
1227
|
-
}), Ct = /* @__PURE__ */ ge(
|
|
1230
|
+
}), Ct = /* @__PURE__ */ ge(Kr, [["__scopeId", "data-v-9c87856b"]]);
|
|
1228
1231
|
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
|
|
1229
|
-
function
|
|
1232
|
+
function wn(e) {
|
|
1230
1233
|
return typeof e > "u" || e === null;
|
|
1231
1234
|
}
|
|
1232
|
-
function
|
|
1235
|
+
function qr(e) {
|
|
1233
1236
|
return typeof e == "object" && e !== null;
|
|
1234
1237
|
}
|
|
1235
|
-
function
|
|
1236
|
-
return Array.isArray(e) ? e :
|
|
1238
|
+
function Br(e) {
|
|
1239
|
+
return Array.isArray(e) ? e : wn(e) ? [] : [e];
|
|
1237
1240
|
}
|
|
1238
1241
|
function Lr(e, n) {
|
|
1239
1242
|
var t, a, r, o;
|
|
@@ -1242,41 +1245,41 @@ function Lr(e, n) {
|
|
|
1242
1245
|
r = o[t], e[r] = n[r];
|
|
1243
1246
|
return e;
|
|
1244
1247
|
}
|
|
1245
|
-
function
|
|
1248
|
+
function Ur(e, n) {
|
|
1246
1249
|
var t = "", a;
|
|
1247
1250
|
for (a = 0; a < n; a += 1)
|
|
1248
1251
|
t += e;
|
|
1249
1252
|
return t;
|
|
1250
1253
|
}
|
|
1251
|
-
function
|
|
1254
|
+
function Pr(e) {
|
|
1252
1255
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1253
1256
|
}
|
|
1254
|
-
var
|
|
1255
|
-
isNothing:
|
|
1256
|
-
isObject:
|
|
1257
|
-
toArray:
|
|
1257
|
+
var Dr = wn, Vr = qr, Rr = Br, Gr = Ur, Hr = Pr, zr = Lr, re = {
|
|
1258
|
+
isNothing: Dr,
|
|
1259
|
+
isObject: Vr,
|
|
1260
|
+
toArray: Rr,
|
|
1258
1261
|
repeat: Gr,
|
|
1259
1262
|
isNegativeZero: Hr,
|
|
1260
1263
|
extend: zr
|
|
1261
1264
|
};
|
|
1262
|
-
function
|
|
1265
|
+
function In(e, n) {
|
|
1263
1266
|
var t = "", a = e.reason || "(unknown reason)";
|
|
1264
1267
|
return e.mark ? (e.mark.name && (t += 'in "' + e.mark.name + '" '), t += "(" + (e.mark.line + 1) + ":" + (e.mark.column + 1) + ")", !n && e.mark.snippet && (t += `
|
|
1265
1268
|
|
|
1266
1269
|
` + e.mark.snippet), a + " " + t) : a;
|
|
1267
1270
|
}
|
|
1268
|
-
function
|
|
1269
|
-
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = n, this.message =
|
|
1271
|
+
function Ue(e, n) {
|
|
1272
|
+
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = n, this.message = In(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack || "";
|
|
1270
1273
|
}
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
return this.name + ": " +
|
|
1274
|
+
Ue.prototype = Object.create(Error.prototype);
|
|
1275
|
+
Ue.prototype.constructor = Ue;
|
|
1276
|
+
Ue.prototype.toString = function(e) {
|
|
1277
|
+
return this.name + ": " + In(this, e);
|
|
1275
1278
|
};
|
|
1276
|
-
var
|
|
1279
|
+
var se = Ue;
|
|
1277
1280
|
function ot(e, n, t, a, r) {
|
|
1278
|
-
var o = "", i = "",
|
|
1279
|
-
return a - n >
|
|
1281
|
+
var o = "", i = "", l = Math.floor(r / 2) - 1;
|
|
1282
|
+
return a - n > l && (o = " ... ", n = a - l + o.length), t - a > l && (i = " ...", t = a + l - i.length), {
|
|
1280
1283
|
str: o + e.slice(n, t).replace(/\t/g, "→") + i,
|
|
1281
1284
|
pos: a - n + o.length
|
|
1282
1285
|
// relative position
|
|
@@ -1292,30 +1295,30 @@ function Jr(e, n) {
|
|
|
1292
1295
|
for (var t = /\r?\n|\r|\0/g, a = [0], r = [], o, i = -1; o = t.exec(e.buffer); )
|
|
1293
1296
|
r.push(o.index), a.push(o.index + o[0].length), e.position <= o.index && i < 0 && (i = a.length - 2);
|
|
1294
1297
|
i < 0 && (i = a.length - 1);
|
|
1295
|
-
var
|
|
1296
|
-
for (
|
|
1298
|
+
var l = "", s, u, p = Math.min(e.line + n.linesAfter, r.length).toString().length, c = n.maxLength - (n.indent + p + 3);
|
|
1299
|
+
for (s = 1; s <= n.linesBefore && !(i - s < 0); s++)
|
|
1297
1300
|
u = ot(
|
|
1298
1301
|
e.buffer,
|
|
1299
|
-
a[i -
|
|
1300
|
-
r[i -
|
|
1301
|
-
e.position - (a[i] - a[i -
|
|
1302
|
+
a[i - s],
|
|
1303
|
+
r[i - s],
|
|
1304
|
+
e.position - (a[i] - a[i - s]),
|
|
1302
1305
|
c
|
|
1303
|
-
),
|
|
1304
|
-
` +
|
|
1305
|
-
for (u = ot(e.buffer, a[i], r[i], e.position, c),
|
|
1306
|
-
`,
|
|
1307
|
-
`,
|
|
1306
|
+
), l = re.repeat(" ", n.indent) + it((e.line - s + 1).toString(), p) + " | " + u.str + `
|
|
1307
|
+
` + l;
|
|
1308
|
+
for (u = ot(e.buffer, a[i], r[i], e.position, c), l += re.repeat(" ", n.indent) + it((e.line + 1).toString(), p) + " | " + u.str + `
|
|
1309
|
+
`, l += re.repeat("-", n.indent + p + 3 + u.pos) + `^
|
|
1310
|
+
`, s = 1; s <= n.linesAfter && !(i + s >= r.length); s++)
|
|
1308
1311
|
u = ot(
|
|
1309
1312
|
e.buffer,
|
|
1310
|
-
a[i +
|
|
1311
|
-
r[i +
|
|
1312
|
-
e.position - (a[i] - a[i +
|
|
1313
|
+
a[i + s],
|
|
1314
|
+
r[i + s],
|
|
1315
|
+
e.position - (a[i] - a[i + s]),
|
|
1313
1316
|
c
|
|
1314
|
-
),
|
|
1317
|
+
), l += re.repeat(" ", n.indent) + it((e.line + s + 1).toString(), p) + " | " + u.str + `
|
|
1315
1318
|
`;
|
|
1316
|
-
return
|
|
1319
|
+
return l.replace(/\n$/, "");
|
|
1317
1320
|
}
|
|
1318
|
-
var
|
|
1321
|
+
var Wr = Jr, Yr = [
|
|
1319
1322
|
"kind",
|
|
1320
1323
|
"multi",
|
|
1321
1324
|
"resolve",
|
|
@@ -1341,14 +1344,14 @@ function Qr(e) {
|
|
|
1341
1344
|
}
|
|
1342
1345
|
function Xr(e, n) {
|
|
1343
1346
|
if (n = n || {}, Object.keys(n).forEach(function(t) {
|
|
1344
|
-
if (
|
|
1345
|
-
throw new
|
|
1347
|
+
if (Yr.indexOf(t) === -1)
|
|
1348
|
+
throw new se('Unknown option "' + t + '" is met in definition of "' + e + '" YAML type.');
|
|
1346
1349
|
}), this.options = n, this.tag = e, this.kind = n.kind || null, this.resolve = n.resolve || function() {
|
|
1347
1350
|
return !0;
|
|
1348
1351
|
}, this.construct = n.construct || function(t) {
|
|
1349
1352
|
return t;
|
|
1350
1353
|
}, 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 = Qr(n.styleAliases || null), Zr.indexOf(this.kind) === -1)
|
|
1351
|
-
throw new
|
|
1354
|
+
throw new se('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.');
|
|
1352
1355
|
}
|
|
1353
1356
|
var ie = Xr;
|
|
1354
1357
|
function Ht(e, n) {
|
|
@@ -1392,22 +1395,22 @@ ct.prototype.extend = function(e) {
|
|
|
1392
1395
|
else if (e && (Array.isArray(e.implicit) || Array.isArray(e.explicit)))
|
|
1393
1396
|
e.implicit && (n = n.concat(e.implicit)), e.explicit && (t = t.concat(e.explicit));
|
|
1394
1397
|
else
|
|
1395
|
-
throw new
|
|
1398
|
+
throw new se("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");
|
|
1396
1399
|
n.forEach(function(r) {
|
|
1397
1400
|
if (!(r instanceof ie))
|
|
1398
|
-
throw new
|
|
1401
|
+
throw new se("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1399
1402
|
if (r.loadKind && r.loadKind !== "scalar")
|
|
1400
|
-
throw new
|
|
1403
|
+
throw new se("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");
|
|
1401
1404
|
if (r.multi)
|
|
1402
|
-
throw new
|
|
1405
|
+
throw new se("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.");
|
|
1403
1406
|
}), t.forEach(function(r) {
|
|
1404
1407
|
if (!(r instanceof ie))
|
|
1405
|
-
throw new
|
|
1408
|
+
throw new se("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1406
1409
|
});
|
|
1407
1410
|
var a = Object.create(ct.prototype);
|
|
1408
1411
|
return a.implicit = (this.implicit || []).concat(n), a.explicit = (this.explicit || []).concat(t), a.compiledImplicit = Ht(a, "implicit"), a.compiledExplicit = Ht(a, "explicit"), a.compiledTypeMap = eo(a.compiledImplicit, a.compiledExplicit), a;
|
|
1409
1412
|
};
|
|
1410
|
-
var
|
|
1413
|
+
var _n = ct, Sn = new ie("tag:yaml.org,2002:str", {
|
|
1411
1414
|
kind: "scalar",
|
|
1412
1415
|
construct: function(e) {
|
|
1413
1416
|
return e !== null ? e : "";
|
|
@@ -1417,16 +1420,16 @@ var In = ct, _n = new ie("tag:yaml.org,2002:str", {
|
|
|
1417
1420
|
construct: function(e) {
|
|
1418
1421
|
return e !== null ? e : [];
|
|
1419
1422
|
}
|
|
1420
|
-
}),
|
|
1423
|
+
}), xn = new ie("tag:yaml.org,2002:map", {
|
|
1421
1424
|
kind: "mapping",
|
|
1422
1425
|
construct: function(e) {
|
|
1423
1426
|
return e !== null ? e : {};
|
|
1424
1427
|
}
|
|
1425
|
-
}),
|
|
1428
|
+
}), Tn = new _n({
|
|
1426
1429
|
explicit: [
|
|
1427
|
-
|
|
1430
|
+
Sn,
|
|
1428
1431
|
An,
|
|
1429
|
-
|
|
1432
|
+
xn
|
|
1430
1433
|
]
|
|
1431
1434
|
});
|
|
1432
1435
|
function to(e) {
|
|
@@ -1441,7 +1444,7 @@ function no() {
|
|
|
1441
1444
|
function ao(e) {
|
|
1442
1445
|
return e === null;
|
|
1443
1446
|
}
|
|
1444
|
-
var
|
|
1447
|
+
var $n = new ie("tag:yaml.org,2002:null", {
|
|
1445
1448
|
kind: "scalar",
|
|
1446
1449
|
resolve: to,
|
|
1447
1450
|
construct: no,
|
|
@@ -1477,7 +1480,7 @@ function oo(e) {
|
|
|
1477
1480
|
function io(e) {
|
|
1478
1481
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1479
1482
|
}
|
|
1480
|
-
var
|
|
1483
|
+
var jn = new ie("tag:yaml.org,2002:bool", {
|
|
1481
1484
|
kind: "scalar",
|
|
1482
1485
|
resolve: ro,
|
|
1483
1486
|
construct: oo,
|
|
@@ -1495,10 +1498,10 @@ var $n = new ie("tag:yaml.org,2002:bool", {
|
|
|
1495
1498
|
},
|
|
1496
1499
|
defaultStyle: "lowercase"
|
|
1497
1500
|
});
|
|
1498
|
-
function
|
|
1501
|
+
function lo(e) {
|
|
1499
1502
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1500
1503
|
}
|
|
1501
|
-
function
|
|
1504
|
+
function so(e) {
|
|
1502
1505
|
return 48 <= e && e <= 55;
|
|
1503
1506
|
}
|
|
1504
1507
|
function uo(e) {
|
|
@@ -1525,7 +1528,7 @@ function co(e) {
|
|
|
1525
1528
|
if (r === "x") {
|
|
1526
1529
|
for (t++; t < n; t++)
|
|
1527
1530
|
if (r = e[t], r !== "_") {
|
|
1528
|
-
if (!
|
|
1531
|
+
if (!lo(e.charCodeAt(t)))
|
|
1529
1532
|
return !1;
|
|
1530
1533
|
a = !0;
|
|
1531
1534
|
}
|
|
@@ -1534,7 +1537,7 @@ function co(e) {
|
|
|
1534
1537
|
if (r === "o") {
|
|
1535
1538
|
for (t++; t < n; t++)
|
|
1536
1539
|
if (r = e[t], r !== "_") {
|
|
1537
|
-
if (!
|
|
1540
|
+
if (!so(e.charCodeAt(t)))
|
|
1538
1541
|
return !1;
|
|
1539
1542
|
a = !0;
|
|
1540
1543
|
}
|
|
@@ -1645,45 +1648,45 @@ function vo(e, n) {
|
|
|
1645
1648
|
function bo(e) {
|
|
1646
1649
|
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 !== 0 || re.isNegativeZero(e));
|
|
1647
1650
|
}
|
|
1648
|
-
var
|
|
1651
|
+
var On = new ie("tag:yaml.org,2002:float", {
|
|
1649
1652
|
kind: "scalar",
|
|
1650
1653
|
resolve: go,
|
|
1651
1654
|
construct: yo,
|
|
1652
1655
|
predicate: bo,
|
|
1653
1656
|
represent: vo,
|
|
1654
1657
|
defaultStyle: "lowercase"
|
|
1655
|
-
}),
|
|
1658
|
+
}), En = Tn.extend({
|
|
1656
1659
|
implicit: [
|
|
1657
|
-
Tn,
|
|
1658
1660
|
$n,
|
|
1661
|
+
jn,
|
|
1659
1662
|
Mn,
|
|
1660
|
-
|
|
1663
|
+
On
|
|
1661
1664
|
]
|
|
1662
|
-
}),
|
|
1665
|
+
}), Fn = En, Nn = new RegExp(
|
|
1663
1666
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1664
|
-
),
|
|
1667
|
+
), Kn = new RegExp(
|
|
1665
1668
|
"^([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]))?))?$"
|
|
1666
1669
|
);
|
|
1667
1670
|
function Co(e) {
|
|
1668
|
-
return e === null ? !1 :
|
|
1671
|
+
return e === null ? !1 : Nn.exec(e) !== null || Kn.exec(e) !== null;
|
|
1669
1672
|
}
|
|
1670
1673
|
function ko(e) {
|
|
1671
|
-
var n, t, a, r, o, i,
|
|
1672
|
-
if (n =
|
|
1674
|
+
var n, t, a, r, o, i, l, s = 0, u = null, p, c, h;
|
|
1675
|
+
if (n = Nn.exec(e), n === null && (n = Kn.exec(e)), n === null)
|
|
1673
1676
|
throw new Error("Date resolve error");
|
|
1674
1677
|
if (t = +n[1], a = +n[2] - 1, r = +n[3], !n[4])
|
|
1675
1678
|
return new Date(Date.UTC(t, a, r));
|
|
1676
|
-
if (o = +n[4], i = +n[5],
|
|
1677
|
-
for (
|
|
1678
|
-
|
|
1679
|
-
|
|
1679
|
+
if (o = +n[4], i = +n[5], l = +n[6], n[7]) {
|
|
1680
|
+
for (s = n[7].slice(0, 3); s.length < 3; )
|
|
1681
|
+
s += "0";
|
|
1682
|
+
s = +s;
|
|
1680
1683
|
}
|
|
1681
|
-
return n[9] && (
|
|
1684
|
+
return n[9] && (p = +n[10], c = +(n[11] || 0), u = (p * 60 + c) * 6e4, n[9] === "-" && (u = -u)), h = new Date(Date.UTC(t, a, r, o, i, l, s)), u && h.setTime(h.getTime() - u), h;
|
|
1682
1685
|
}
|
|
1683
1686
|
function wo(e) {
|
|
1684
1687
|
return e.toISOString();
|
|
1685
1688
|
}
|
|
1686
|
-
var
|
|
1689
|
+
var qn = new ie("tag:yaml.org,2002:timestamp", {
|
|
1687
1690
|
kind: "scalar",
|
|
1688
1691
|
resolve: Co,
|
|
1689
1692
|
construct: ko,
|
|
@@ -1710,13 +1713,13 @@ function _o(e) {
|
|
|
1710
1713
|
}
|
|
1711
1714
|
return a % 8 === 0;
|
|
1712
1715
|
}
|
|
1713
|
-
function
|
|
1714
|
-
var n, t, a = e.replace(/[\r\n=]/g, ""), r = a.length, o = kt, i = 0,
|
|
1716
|
+
function So(e) {
|
|
1717
|
+
var n, t, a = e.replace(/[\r\n=]/g, ""), r = a.length, o = kt, i = 0, l = [];
|
|
1715
1718
|
for (n = 0; n < r; n++)
|
|
1716
|
-
n % 4 === 0 && n && (
|
|
1717
|
-
return t = r % 4 * 6, t === 0 ? (
|
|
1719
|
+
n % 4 === 0 && n && (l.push(i >> 16 & 255), l.push(i >> 8 & 255), l.push(i & 255)), i = i << 6 | o.indexOf(a.charAt(n));
|
|
1720
|
+
return t = r % 4 * 6, t === 0 ? (l.push(i >> 16 & 255), l.push(i >> 8 & 255), l.push(i & 255)) : t === 18 ? (l.push(i >> 10 & 255), l.push(i >> 2 & 255)) : t === 12 && l.push(i >> 4 & 255), new Uint8Array(l);
|
|
1718
1721
|
}
|
|
1719
|
-
function
|
|
1722
|
+
function Ao(e) {
|
|
1720
1723
|
var n = "", t = 0, a, r, o = e.length, i = kt;
|
|
1721
1724
|
for (a = 0; a < o; a++)
|
|
1722
1725
|
a % 3 === 0 && a && (n += i[t >> 18 & 63], n += i[t >> 12 & 63], n += i[t >> 6 & 63], n += i[t & 63]), t = (t << 8) + e[a];
|
|
@@ -1725,19 +1728,19 @@ function So(e) {
|
|
|
1725
1728
|
function xo(e) {
|
|
1726
1729
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1727
1730
|
}
|
|
1728
|
-
var
|
|
1731
|
+
var Ln = new ie("tag:yaml.org,2002:binary", {
|
|
1729
1732
|
kind: "scalar",
|
|
1730
1733
|
resolve: _o,
|
|
1731
|
-
construct:
|
|
1734
|
+
construct: So,
|
|
1732
1735
|
predicate: xo,
|
|
1733
|
-
represent:
|
|
1736
|
+
represent: Ao
|
|
1734
1737
|
}), To = Object.prototype.hasOwnProperty, $o = Object.prototype.toString;
|
|
1735
|
-
function
|
|
1738
|
+
function jo(e) {
|
|
1736
1739
|
if (e === null)
|
|
1737
1740
|
return !0;
|
|
1738
|
-
var n = [], t, a, r, o, i,
|
|
1739
|
-
for (t = 0, a =
|
|
1740
|
-
if (r =
|
|
1741
|
+
var n = [], t, a, r, o, i, l = e;
|
|
1742
|
+
for (t = 0, a = l.length; t < a; t += 1) {
|
|
1743
|
+
if (r = l[t], i = !1, $o.call(r) !== "[object Object]")
|
|
1741
1744
|
return !1;
|
|
1742
1745
|
for (o in r)
|
|
1743
1746
|
if (To.call(r, o))
|
|
@@ -1754,13 +1757,13 @@ function Mo(e) {
|
|
|
1754
1757
|
}
|
|
1755
1758
|
return !0;
|
|
1756
1759
|
}
|
|
1757
|
-
function
|
|
1760
|
+
function Mo(e) {
|
|
1758
1761
|
return e !== null ? e : [];
|
|
1759
1762
|
}
|
|
1760
|
-
var
|
|
1763
|
+
var Un = new ie("tag:yaml.org,2002:omap", {
|
|
1761
1764
|
kind: "sequence",
|
|
1762
|
-
resolve:
|
|
1763
|
-
construct:
|
|
1765
|
+
resolve: jo,
|
|
1766
|
+
construct: Mo
|
|
1764
1767
|
}), Oo = Object.prototype.toString;
|
|
1765
1768
|
function Eo(e) {
|
|
1766
1769
|
if (e === null)
|
|
@@ -1773,7 +1776,7 @@ function Eo(e) {
|
|
|
1773
1776
|
}
|
|
1774
1777
|
return !0;
|
|
1775
1778
|
}
|
|
1776
|
-
function
|
|
1779
|
+
function Fo(e) {
|
|
1777
1780
|
if (e === null)
|
|
1778
1781
|
return [];
|
|
1779
1782
|
var n, t, a, r, o, i = e;
|
|
@@ -1784,36 +1787,36 @@ function Ko(e) {
|
|
|
1784
1787
|
var Pn = new ie("tag:yaml.org,2002:pairs", {
|
|
1785
1788
|
kind: "sequence",
|
|
1786
1789
|
resolve: Eo,
|
|
1787
|
-
construct:
|
|
1788
|
-
}),
|
|
1789
|
-
function
|
|
1790
|
+
construct: Fo
|
|
1791
|
+
}), No = Object.prototype.hasOwnProperty;
|
|
1792
|
+
function Ko(e) {
|
|
1790
1793
|
if (e === null)
|
|
1791
1794
|
return !0;
|
|
1792
1795
|
var n, t = e;
|
|
1793
1796
|
for (n in t)
|
|
1794
|
-
if (
|
|
1797
|
+
if (No.call(t, n) && t[n] !== null)
|
|
1795
1798
|
return !1;
|
|
1796
1799
|
return !0;
|
|
1797
1800
|
}
|
|
1798
|
-
function
|
|
1801
|
+
function qo(e) {
|
|
1799
1802
|
return e !== null ? e : {};
|
|
1800
1803
|
}
|
|
1801
|
-
var
|
|
1804
|
+
var Dn = new ie("tag:yaml.org,2002:set", {
|
|
1802
1805
|
kind: "mapping",
|
|
1803
|
-
resolve:
|
|
1804
|
-
construct:
|
|
1805
|
-
}), wt =
|
|
1806
|
+
resolve: Ko,
|
|
1807
|
+
construct: qo
|
|
1808
|
+
}), wt = Fn.extend({
|
|
1806
1809
|
implicit: [
|
|
1807
|
-
|
|
1810
|
+
qn,
|
|
1808
1811
|
Bn
|
|
1809
1812
|
],
|
|
1810
1813
|
explicit: [
|
|
1811
|
-
qn,
|
|
1812
1814
|
Ln,
|
|
1815
|
+
Un,
|
|
1813
1816
|
Pn,
|
|
1814
|
-
|
|
1817
|
+
Dn
|
|
1815
1818
|
]
|
|
1816
|
-
}),
|
|
1819
|
+
}), _e = Object.prototype.hasOwnProperty, He = 1, Vn = 2, Rn = 3, ze = 4, lt = 1, Bo = 2, zt = 3, Lo = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Uo = /[\x85\u2028\u2029]/, Po = /[,\[\]\{\}]/, Gn = /^(?:!|!!|![a-z\-]+!)$/i, Hn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1817
1820
|
function Jt(e) {
|
|
1818
1821
|
return Object.prototype.toString.call(e);
|
|
1819
1822
|
}
|
|
@@ -1829,17 +1832,17 @@ function fe(e) {
|
|
|
1829
1832
|
function Oe(e) {
|
|
1830
1833
|
return e === 44 || e === 91 || e === 93 || e === 123 || e === 125;
|
|
1831
1834
|
}
|
|
1832
|
-
function
|
|
1835
|
+
function Do(e) {
|
|
1833
1836
|
var n;
|
|
1834
1837
|
return 48 <= e && e <= 57 ? e - 48 : (n = e | 32, 97 <= n && n <= 102 ? n - 97 + 10 : -1);
|
|
1835
1838
|
}
|
|
1836
|
-
function
|
|
1839
|
+
function Vo(e) {
|
|
1837
1840
|
return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0;
|
|
1838
1841
|
}
|
|
1839
|
-
function
|
|
1842
|
+
function Ro(e) {
|
|
1840
1843
|
return 48 <= e && e <= 57 ? e - 48 : -1;
|
|
1841
1844
|
}
|
|
1842
|
-
function
|
|
1845
|
+
function Wt(e) {
|
|
1843
1846
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? `
|
|
1844
1847
|
` : 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" : "";
|
|
1845
1848
|
}
|
|
@@ -1849,13 +1852,13 @@ function Go(e) {
|
|
|
1849
1852
|
(e - 65536 & 1023) + 56320
|
|
1850
1853
|
);
|
|
1851
1854
|
}
|
|
1852
|
-
var
|
|
1853
|
-
for (var
|
|
1854
|
-
|
|
1855
|
+
var zn = new Array(256), Jn = new Array(256);
|
|
1856
|
+
for (var je = 0; je < 256; je++)
|
|
1857
|
+
zn[je] = Wt(je) ? 1 : 0, Jn[je] = Wt(je);
|
|
1855
1858
|
function Ho(e, n) {
|
|
1856
1859
|
this.input = e, this.filename = n.filename || null, this.schema = n.schema || wt, 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 = [];
|
|
1857
1860
|
}
|
|
1858
|
-
function
|
|
1861
|
+
function Wn(e, n) {
|
|
1859
1862
|
var t = {
|
|
1860
1863
|
name: e.filename,
|
|
1861
1864
|
buffer: e.input.slice(0, -1),
|
|
@@ -1864,59 +1867,59 @@ function Jn(e, n) {
|
|
|
1864
1867
|
line: e.line,
|
|
1865
1868
|
column: e.position - e.lineStart
|
|
1866
1869
|
};
|
|
1867
|
-
return t.snippet =
|
|
1870
|
+
return t.snippet = Wr(t), new se(n, t);
|
|
1868
1871
|
}
|
|
1869
|
-
function
|
|
1870
|
-
throw
|
|
1872
|
+
function M(e, n) {
|
|
1873
|
+
throw Wn(e, n);
|
|
1871
1874
|
}
|
|
1872
1875
|
function Je(e, n) {
|
|
1873
|
-
e.onWarning && e.onWarning.call(null,
|
|
1876
|
+
e.onWarning && e.onWarning.call(null, Wn(e, n));
|
|
1874
1877
|
}
|
|
1875
|
-
var
|
|
1878
|
+
var Yt = {
|
|
1876
1879
|
YAML: function(e, n, t) {
|
|
1877
1880
|
var a, r, o;
|
|
1878
|
-
e.version !== null &&
|
|
1881
|
+
e.version !== null && M(e, "duplication of %YAML directive"), t.length !== 1 && M(e, "YAML directive accepts exactly one argument"), a = /^([0-9]+)\.([0-9]+)$/.exec(t[0]), a === null && M(e, "ill-formed argument of the YAML directive"), r = parseInt(a[1], 10), o = parseInt(a[2], 10), r !== 1 && M(e, "unacceptable YAML version of the document"), e.version = t[0], e.checkLineBreaks = o < 2, o !== 1 && o !== 2 && Je(e, "unsupported YAML version of the document");
|
|
1879
1882
|
},
|
|
1880
1883
|
TAG: function(e, n, t) {
|
|
1881
1884
|
var a, r;
|
|
1882
|
-
t.length !== 2 &&
|
|
1885
|
+
t.length !== 2 && M(e, "TAG directive accepts exactly two arguments"), a = t[0], r = t[1], Gn.test(a) || M(e, "ill-formed tag handle (first argument) of the TAG directive"), _e.call(e.tagMap, a) && M(e, 'there is a previously declared suffix for "' + a + '" tag handle'), Hn.test(r) || M(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1883
1886
|
try {
|
|
1884
1887
|
r = decodeURIComponent(r);
|
|
1885
1888
|
} catch {
|
|
1886
|
-
|
|
1889
|
+
M(e, "tag prefix is malformed: " + r);
|
|
1887
1890
|
}
|
|
1888
1891
|
e.tagMap[a] = r;
|
|
1889
1892
|
}
|
|
1890
1893
|
};
|
|
1891
1894
|
function we(e, n, t, a) {
|
|
1892
|
-
var r, o, i,
|
|
1895
|
+
var r, o, i, l;
|
|
1893
1896
|
if (n < t) {
|
|
1894
|
-
if (
|
|
1895
|
-
for (r = 0, o =
|
|
1896
|
-
i =
|
|
1897
|
+
if (l = e.input.slice(n, t), a)
|
|
1898
|
+
for (r = 0, o = l.length; r < o; r += 1)
|
|
1899
|
+
i = l.charCodeAt(r), i === 9 || 32 <= i && i <= 1114111 || M(e, "expected valid JSON character");
|
|
1897
1900
|
else
|
|
1898
|
-
Lo.test(
|
|
1899
|
-
e.result +=
|
|
1901
|
+
Lo.test(l) && M(e, "the stream contains non-printable characters");
|
|
1902
|
+
e.result += l;
|
|
1900
1903
|
}
|
|
1901
1904
|
}
|
|
1902
1905
|
function Zt(e, n, t, a) {
|
|
1903
|
-
var r, o, i,
|
|
1904
|
-
for (re.isObject(t) ||
|
|
1905
|
-
o = r[i],
|
|
1906
|
+
var r, o, i, l;
|
|
1907
|
+
for (re.isObject(t) || M(e, "cannot merge mappings; the provided source object is unacceptable"), r = Object.keys(t), i = 0, l = r.length; i < l; i += 1)
|
|
1908
|
+
o = r[i], _e.call(n, o) || (n[o] = t[o], a[o] = !0);
|
|
1906
1909
|
}
|
|
1907
|
-
function Ee(e, n, t, a, r, o, i,
|
|
1908
|
-
var u,
|
|
1910
|
+
function Ee(e, n, t, a, r, o, i, l, s) {
|
|
1911
|
+
var u, p;
|
|
1909
1912
|
if (Array.isArray(r))
|
|
1910
|
-
for (r = Array.prototype.slice.call(r), u = 0,
|
|
1911
|
-
Array.isArray(r[u]) &&
|
|
1913
|
+
for (r = Array.prototype.slice.call(r), u = 0, p = r.length; u < p; u += 1)
|
|
1914
|
+
Array.isArray(r[u]) && M(e, "nested arrays are not supported inside keys"), typeof r == "object" && Jt(r[u]) === "[object Object]" && (r[u] = "[object Object]");
|
|
1912
1915
|
if (typeof r == "object" && Jt(r) === "[object Object]" && (r = "[object Object]"), r = String(r), n === null && (n = {}), a === "tag:yaml.org,2002:merge")
|
|
1913
1916
|
if (Array.isArray(o))
|
|
1914
|
-
for (u = 0,
|
|
1917
|
+
for (u = 0, p = o.length; u < p; u += 1)
|
|
1915
1918
|
Zt(e, n, o[u], t);
|
|
1916
1919
|
else
|
|
1917
1920
|
Zt(e, n, o, t);
|
|
1918
1921
|
else
|
|
1919
|
-
!e.json && !
|
|
1922
|
+
!e.json && !_e.call(t, r) && _e.call(n, r) && (e.line = i || e.line, e.lineStart = l || e.lineStart, e.position = s || e.position, M(e, "duplicated mapping key")), r === "__proto__" ? Object.defineProperty(n, r, {
|
|
1920
1923
|
configurable: !0,
|
|
1921
1924
|
enumerable: !0,
|
|
1922
1925
|
writable: !0,
|
|
@@ -1926,7 +1929,7 @@ function Ee(e, n, t, a, r, o, i, s, l) {
|
|
|
1926
1929
|
}
|
|
1927
1930
|
function It(e) {
|
|
1928
1931
|
var n;
|
|
1929
|
-
n = e.input.charCodeAt(e.position), n === 10 ? e.position++ : n === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) :
|
|
1932
|
+
n = e.input.charCodeAt(e.position), n === 10 ? e.position++ : n === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : M(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1;
|
|
1930
1933
|
}
|
|
1931
1934
|
function ae(e, n, t) {
|
|
1932
1935
|
for (var a = 0, r = e.input.charCodeAt(e.position); r !== 0; ) {
|
|
@@ -1953,29 +1956,29 @@ function _t(e, n) {
|
|
|
1953
1956
|
`, n - 1));
|
|
1954
1957
|
}
|
|
1955
1958
|
function zo(e, n, t) {
|
|
1956
|
-
var a, r, o, i,
|
|
1957
|
-
if (
|
|
1959
|
+
var a, r, o, i, l, s, u, p, c = e.kind, h = e.result, d;
|
|
1960
|
+
if (d = e.input.charCodeAt(e.position), fe(d) || Oe(d) || d === 35 || d === 38 || d === 42 || d === 33 || d === 124 || d === 62 || d === 39 || d === 34 || d === 37 || d === 64 || d === 96 || (d === 63 || d === 45) && (r = e.input.charCodeAt(e.position + 1), fe(r) || t && Oe(r)))
|
|
1958
1961
|
return !1;
|
|
1959
|
-
for (e.kind = "scalar", e.result = "", o = i = e.position,
|
|
1960
|
-
if (
|
|
1962
|
+
for (e.kind = "scalar", e.result = "", o = i = e.position, l = !1; d !== 0; ) {
|
|
1963
|
+
if (d === 58) {
|
|
1961
1964
|
if (r = e.input.charCodeAt(e.position + 1), fe(r) || t && Oe(r))
|
|
1962
1965
|
break;
|
|
1963
|
-
} else if (
|
|
1966
|
+
} else if (d === 35) {
|
|
1964
1967
|
if (a = e.input.charCodeAt(e.position - 1), fe(a))
|
|
1965
1968
|
break;
|
|
1966
1969
|
} else {
|
|
1967
|
-
if (e.position === e.lineStart && Xe(e) || t && Oe(
|
|
1970
|
+
if (e.position === e.lineStart && Xe(e) || t && Oe(d))
|
|
1968
1971
|
break;
|
|
1969
|
-
if (he(
|
|
1970
|
-
if (
|
|
1971
|
-
|
|
1972
|
+
if (he(d))
|
|
1973
|
+
if (s = e.line, u = e.lineStart, p = e.lineIndent, ae(e, !1, -1), e.lineIndent >= n) {
|
|
1974
|
+
l = !0, d = e.input.charCodeAt(e.position);
|
|
1972
1975
|
continue;
|
|
1973
1976
|
} else {
|
|
1974
|
-
e.position = i, e.line =
|
|
1977
|
+
e.position = i, e.line = s, e.lineStart = u, e.lineIndent = p;
|
|
1975
1978
|
break;
|
|
1976
1979
|
}
|
|
1977
1980
|
}
|
|
1978
|
-
|
|
1981
|
+
l && (we(e, o, i, !1), _t(e, e.line - s), o = i = e.position, l = !1), Ae(d) || (i = e.position + 1), d = e.input.charCodeAt(++e.position);
|
|
1979
1982
|
}
|
|
1980
1983
|
return we(e, o, i, !1), e.result ? !0 : (e.kind = c, e.result = h, !1);
|
|
1981
1984
|
}
|
|
@@ -1990,50 +1993,50 @@ function Jo(e, n) {
|
|
|
1990
1993
|
else
|
|
1991
1994
|
return !0;
|
|
1992
1995
|
else
|
|
1993
|
-
he(t) ? (we(e, a, r, !0), _t(e, ae(e, !1, n)), a = r = e.position) : e.position === e.lineStart && Xe(e) ?
|
|
1994
|
-
|
|
1996
|
+
he(t) ? (we(e, a, r, !0), _t(e, ae(e, !1, n)), a = r = e.position) : e.position === e.lineStart && Xe(e) ? M(e, "unexpected end of the document within a single quoted scalar") : (e.position++, r = e.position);
|
|
1997
|
+
M(e, "unexpected end of the stream within a single quoted scalar");
|
|
1995
1998
|
}
|
|
1996
|
-
function
|
|
1997
|
-
var t, a, r, o, i,
|
|
1998
|
-
if (
|
|
1999
|
+
function Wo(e, n) {
|
|
2000
|
+
var t, a, r, o, i, l;
|
|
2001
|
+
if (l = e.input.charCodeAt(e.position), l !== 34)
|
|
1999
2002
|
return !1;
|
|
2000
|
-
for (e.kind = "scalar", e.result = "", e.position++, t = a = e.position; (
|
|
2001
|
-
if (
|
|
2003
|
+
for (e.kind = "scalar", e.result = "", e.position++, t = a = e.position; (l = e.input.charCodeAt(e.position)) !== 0; ) {
|
|
2004
|
+
if (l === 34)
|
|
2002
2005
|
return we(e, t, e.position, !0), e.position++, !0;
|
|
2003
|
-
if (
|
|
2004
|
-
if (we(e, t, e.position, !0),
|
|
2006
|
+
if (l === 92) {
|
|
2007
|
+
if (we(e, t, e.position, !0), l = e.input.charCodeAt(++e.position), he(l))
|
|
2005
2008
|
ae(e, !1, n);
|
|
2006
|
-
else if (
|
|
2007
|
-
e.result +=
|
|
2008
|
-
else if ((i =
|
|
2009
|
+
else if (l < 256 && zn[l])
|
|
2010
|
+
e.result += Jn[l], e.position++;
|
|
2011
|
+
else if ((i = Vo(l)) > 0) {
|
|
2009
2012
|
for (r = i, o = 0; r > 0; r--)
|
|
2010
|
-
|
|
2013
|
+
l = e.input.charCodeAt(++e.position), (i = Do(l)) >= 0 ? o = (o << 4) + i : M(e, "expected hexadecimal character");
|
|
2011
2014
|
e.result += Go(o), e.position++;
|
|
2012
2015
|
} else
|
|
2013
|
-
|
|
2016
|
+
M(e, "unknown escape sequence");
|
|
2014
2017
|
t = a = e.position;
|
|
2015
2018
|
} else
|
|
2016
|
-
he(
|
|
2019
|
+
he(l) ? (we(e, t, a, !0), _t(e, ae(e, !1, n)), t = a = e.position) : e.position === e.lineStart && Xe(e) ? M(e, "unexpected end of the document within a double quoted scalar") : (e.position++, a = e.position);
|
|
2017
2020
|
}
|
|
2018
|
-
|
|
2021
|
+
M(e, "unexpected end of the stream within a double quoted scalar");
|
|
2019
2022
|
}
|
|
2020
|
-
function
|
|
2021
|
-
var t = !0, a, r, o, i = e.tag,
|
|
2023
|
+
function Yo(e, n) {
|
|
2024
|
+
var t = !0, a, r, o, i = e.tag, l, s = e.anchor, u, p, c, h, d, w = /* @__PURE__ */ Object.create(null), v, A, y, C;
|
|
2022
2025
|
if (C = e.input.charCodeAt(e.position), C === 91)
|
|
2023
|
-
|
|
2026
|
+
p = 93, d = !1, l = [];
|
|
2024
2027
|
else if (C === 123)
|
|
2025
|
-
|
|
2028
|
+
p = 125, d = !0, l = {};
|
|
2026
2029
|
else
|
|
2027
2030
|
return !1;
|
|
2028
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] =
|
|
2029
|
-
if (ae(e, !0, n), C = e.input.charCodeAt(e.position), C ===
|
|
2030
|
-
return e.position++, e.tag = i, e.anchor =
|
|
2031
|
-
t ? C === 44 &&
|
|
2031
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = l), C = e.input.charCodeAt(++e.position); C !== 0; ) {
|
|
2032
|
+
if (ae(e, !0, n), C = e.input.charCodeAt(e.position), C === p)
|
|
2033
|
+
return e.position++, e.tag = i, e.anchor = s, e.kind = d ? "mapping" : "sequence", e.result = l, !0;
|
|
2034
|
+
t ? C === 44 && M(e, "expected the node content, but found ','") : M(e, "missed comma between flow collection entries"), A = v = y = null, c = h = !1, C === 63 && (u = e.input.charCodeAt(e.position + 1), fe(u) && (c = h = !0, e.position++, ae(e, !0, n))), a = e.line, r = e.lineStart, o = e.position, Ne(e, n, He, !1, !0), A = e.tag, v = e.result, ae(e, !0, n), C = e.input.charCodeAt(e.position), (h || e.line === a) && C === 58 && (c = !0, C = e.input.charCodeAt(++e.position), ae(e, !0, n), Ne(e, n, He, !1, !0), y = e.result), d ? Ee(e, l, w, A, v, y, a, r, o) : c ? l.push(Ee(e, null, w, A, v, y, a, r, o)) : l.push(v), ae(e, !0, n), C = e.input.charCodeAt(e.position), C === 44 ? (t = !0, C = e.input.charCodeAt(++e.position)) : t = !1;
|
|
2032
2035
|
}
|
|
2033
|
-
|
|
2036
|
+
M(e, "unexpected end of the stream within a flow collection");
|
|
2034
2037
|
}
|
|
2035
2038
|
function Zo(e, n) {
|
|
2036
|
-
var t, a, r =
|
|
2039
|
+
var t, a, r = lt, o = !1, i = !1, l = n, s = 0, u = !1, p, c;
|
|
2037
2040
|
if (c = e.input.charCodeAt(e.position), c === 124)
|
|
2038
2041
|
a = !1;
|
|
2039
2042
|
else if (c === 62)
|
|
@@ -2042,9 +2045,9 @@ function Zo(e, n) {
|
|
|
2042
2045
|
return !1;
|
|
2043
2046
|
for (e.kind = "scalar", e.result = ""; c !== 0; )
|
|
2044
2047
|
if (c = e.input.charCodeAt(++e.position), c === 43 || c === 45)
|
|
2045
|
-
|
|
2046
|
-
else if ((
|
|
2047
|
-
|
|
2048
|
+
lt === r ? r = c === 43 ? zt : Bo : M(e, "repeat of a chomping mode identifier");
|
|
2049
|
+
else if ((p = Ro(c)) >= 0)
|
|
2050
|
+
p === 0 ? M(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : i ? M(e, "repeat of an indentation width identifier") : (l = n + p - 1, i = !0);
|
|
2048
2051
|
else
|
|
2049
2052
|
break;
|
|
2050
2053
|
if (Ae(c)) {
|
|
@@ -2057,104 +2060,104 @@ function Zo(e, n) {
|
|
|
2057
2060
|
while (!he(c) && c !== 0);
|
|
2058
2061
|
}
|
|
2059
2062
|
for (; c !== 0; ) {
|
|
2060
|
-
for (It(e), e.lineIndent = 0, c = e.input.charCodeAt(e.position); (!i || e.lineIndent <
|
|
2063
|
+
for (It(e), e.lineIndent = 0, c = e.input.charCodeAt(e.position); (!i || e.lineIndent < l) && c === 32; )
|
|
2061
2064
|
e.lineIndent++, c = e.input.charCodeAt(++e.position);
|
|
2062
|
-
if (!i && e.lineIndent >
|
|
2063
|
-
|
|
2065
|
+
if (!i && e.lineIndent > l && (l = e.lineIndent), he(c)) {
|
|
2066
|
+
s++;
|
|
2064
2067
|
continue;
|
|
2065
2068
|
}
|
|
2066
|
-
if (e.lineIndent <
|
|
2069
|
+
if (e.lineIndent < l) {
|
|
2067
2070
|
r === zt ? e.result += re.repeat(`
|
|
2068
|
-
`, o ? 1 +
|
|
2071
|
+
`, o ? 1 + s : s) : r === lt && o && (e.result += `
|
|
2069
2072
|
`);
|
|
2070
2073
|
break;
|
|
2071
2074
|
}
|
|
2072
2075
|
for (a ? Ae(c) ? (u = !0, e.result += re.repeat(`
|
|
2073
|
-
`, o ? 1 +
|
|
2074
|
-
`,
|
|
2075
|
-
`,
|
|
2076
|
-
`, o ? 1 +
|
|
2076
|
+
`, o ? 1 + s : s)) : u ? (u = !1, e.result += re.repeat(`
|
|
2077
|
+
`, s + 1)) : s === 0 ? o && (e.result += " ") : e.result += re.repeat(`
|
|
2078
|
+
`, s) : e.result += re.repeat(`
|
|
2079
|
+
`, o ? 1 + s : s), o = !0, i = !0, s = 0, t = e.position; !he(c) && c !== 0; )
|
|
2077
2080
|
c = e.input.charCodeAt(++e.position);
|
|
2078
2081
|
we(e, t, e.position, !1);
|
|
2079
2082
|
}
|
|
2080
2083
|
return !0;
|
|
2081
2084
|
}
|
|
2082
2085
|
function Qt(e, n) {
|
|
2083
|
-
var t, a = e.tag, r = e.anchor, o = [], i,
|
|
2086
|
+
var t, a = e.tag, r = e.anchor, o = [], i, l = !1, s;
|
|
2084
2087
|
if (e.firstTabInLine !== -1)
|
|
2085
2088
|
return !1;
|
|
2086
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = o),
|
|
2087
|
-
if (
|
|
2088
|
-
o.push(null),
|
|
2089
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = o), s = e.input.charCodeAt(e.position); s !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, M(e, "tab characters must not be used in indentation")), !(s !== 45 || (i = e.input.charCodeAt(e.position + 1), !fe(i)))); ) {
|
|
2090
|
+
if (l = !0, e.position++, ae(e, !0, -1) && e.lineIndent <= n) {
|
|
2091
|
+
o.push(null), s = e.input.charCodeAt(e.position);
|
|
2089
2092
|
continue;
|
|
2090
2093
|
}
|
|
2091
|
-
if (t = e.line,
|
|
2092
|
-
|
|
2094
|
+
if (t = e.line, Ne(e, n, Rn, !1, !0), o.push(e.result), ae(e, !0, -1), s = e.input.charCodeAt(e.position), (e.line === t || e.lineIndent > n) && s !== 0)
|
|
2095
|
+
M(e, "bad indentation of a sequence entry");
|
|
2093
2096
|
else if (e.lineIndent < n)
|
|
2094
2097
|
break;
|
|
2095
2098
|
}
|
|
2096
|
-
return
|
|
2099
|
+
return l ? (e.tag = a, e.anchor = r, e.kind = "sequence", e.result = o, !0) : !1;
|
|
2097
2100
|
}
|
|
2098
2101
|
function Qo(e, n, t) {
|
|
2099
|
-
var a, r, o, i,
|
|
2102
|
+
var a, r, o, i, l, s, u = e.tag, p = e.anchor, c = {}, h = /* @__PURE__ */ Object.create(null), d = null, w = null, v = null, A = !1, y = !1, C;
|
|
2100
2103
|
if (e.firstTabInLine !== -1)
|
|
2101
2104
|
return !1;
|
|
2102
2105
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = c), C = e.input.charCodeAt(e.position); C !== 0; ) {
|
|
2103
|
-
if (!
|
|
2104
|
-
C === 63 ? (
|
|
2106
|
+
if (!A && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, M(e, "tab characters must not be used in indentation")), a = e.input.charCodeAt(e.position + 1), o = e.line, (C === 63 || C === 58) && fe(a))
|
|
2107
|
+
C === 63 ? (A && (Ee(e, c, h, d, w, null, i, l, s), d = w = v = null), y = !0, A = !0, r = !0) : A ? (A = !1, r = !0) : M(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, C = a;
|
|
2105
2108
|
else {
|
|
2106
|
-
if (i = e.line,
|
|
2109
|
+
if (i = e.line, l = e.lineStart, s = e.position, !Ne(e, t, Vn, !1, !0))
|
|
2107
2110
|
break;
|
|
2108
2111
|
if (e.line === o) {
|
|
2109
2112
|
for (C = e.input.charCodeAt(e.position); Ae(C); )
|
|
2110
2113
|
C = e.input.charCodeAt(++e.position);
|
|
2111
2114
|
if (C === 58)
|
|
2112
|
-
C = e.input.charCodeAt(++e.position), fe(C) ||
|
|
2113
|
-
else if (
|
|
2114
|
-
|
|
2115
|
+
C = e.input.charCodeAt(++e.position), fe(C) || M(e, "a whitespace character is expected after the key-value separator within a block mapping"), A && (Ee(e, c, h, d, w, null, i, l, s), d = w = v = null), y = !0, A = !1, r = !1, d = e.tag, w = e.result;
|
|
2116
|
+
else if (y)
|
|
2117
|
+
M(e, "can not read an implicit mapping pair; a colon is missed");
|
|
2115
2118
|
else
|
|
2116
|
-
return e.tag = u, e.anchor =
|
|
2117
|
-
} else if (
|
|
2118
|
-
|
|
2119
|
+
return e.tag = u, e.anchor = p, !0;
|
|
2120
|
+
} else if (y)
|
|
2121
|
+
M(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
2119
2122
|
else
|
|
2120
|
-
return e.tag = u, e.anchor =
|
|
2123
|
+
return e.tag = u, e.anchor = p, !0;
|
|
2121
2124
|
}
|
|
2122
|
-
if ((e.line === o || e.lineIndent > n) && (
|
|
2123
|
-
|
|
2125
|
+
if ((e.line === o || e.lineIndent > n) && (A && (i = e.line, l = e.lineStart, s = e.position), Ne(e, n, ze, !0, r) && (A ? w = e.result : v = e.result), A || (Ee(e, c, h, d, w, v, i, l, s), d = w = v = null), ae(e, !0, -1), C = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > n) && C !== 0)
|
|
2126
|
+
M(e, "bad indentation of a mapping entry");
|
|
2124
2127
|
else if (e.lineIndent < n)
|
|
2125
2128
|
break;
|
|
2126
2129
|
}
|
|
2127
|
-
return
|
|
2130
|
+
return A && Ee(e, c, h, d, w, null, i, l, s), y && (e.tag = u, e.anchor = p, e.kind = "mapping", e.result = c), y;
|
|
2128
2131
|
}
|
|
2129
2132
|
function Xo(e) {
|
|
2130
2133
|
var n, t = !1, a = !1, r, o, i;
|
|
2131
2134
|
if (i = e.input.charCodeAt(e.position), i !== 33)
|
|
2132
2135
|
return !1;
|
|
2133
|
-
if (e.tag !== null &&
|
|
2136
|
+
if (e.tag !== null && M(e, "duplication of a tag property"), i = e.input.charCodeAt(++e.position), i === 60 ? (t = !0, i = e.input.charCodeAt(++e.position)) : i === 33 ? (a = !0, r = "!!", i = e.input.charCodeAt(++e.position)) : r = "!", n = e.position, t) {
|
|
2134
2137
|
do
|
|
2135
2138
|
i = e.input.charCodeAt(++e.position);
|
|
2136
2139
|
while (i !== 0 && i !== 62);
|
|
2137
|
-
e.position < e.length ? (o = e.input.slice(n, e.position), i = e.input.charCodeAt(++e.position)) :
|
|
2140
|
+
e.position < e.length ? (o = e.input.slice(n, e.position), i = e.input.charCodeAt(++e.position)) : M(e, "unexpected end of the stream within a verbatim tag");
|
|
2138
2141
|
} else {
|
|
2139
2142
|
for (; i !== 0 && !fe(i); )
|
|
2140
|
-
i === 33 && (a ?
|
|
2141
|
-
o = e.input.slice(n, e.position),
|
|
2143
|
+
i === 33 && (a ? M(e, "tag suffix cannot contain exclamation marks") : (r = e.input.slice(n - 1, e.position + 1), Gn.test(r) || M(e, "named tag handle cannot contain such characters"), a = !0, n = e.position + 1)), i = e.input.charCodeAt(++e.position);
|
|
2144
|
+
o = e.input.slice(n, e.position), Po.test(o) && M(e, "tag suffix cannot contain flow indicator characters");
|
|
2142
2145
|
}
|
|
2143
|
-
o && !
|
|
2146
|
+
o && !Hn.test(o) && M(e, "tag name cannot contain such characters: " + o);
|
|
2144
2147
|
try {
|
|
2145
2148
|
o = decodeURIComponent(o);
|
|
2146
2149
|
} catch {
|
|
2147
|
-
|
|
2150
|
+
M(e, "tag name is malformed: " + o);
|
|
2148
2151
|
}
|
|
2149
|
-
return t ? e.tag = o :
|
|
2152
|
+
return t ? e.tag = o : _e.call(e.tagMap, r) ? e.tag = e.tagMap[r] + o : r === "!" ? e.tag = "!" + o : r === "!!" ? e.tag = "tag:yaml.org,2002:" + o : M(e, 'undeclared tag handle "' + r + '"'), !0;
|
|
2150
2153
|
}
|
|
2151
2154
|
function ei(e) {
|
|
2152
2155
|
var n, t;
|
|
2153
2156
|
if (t = e.input.charCodeAt(e.position), t !== 38)
|
|
2154
2157
|
return !1;
|
|
2155
|
-
for (e.anchor !== null &&
|
|
2158
|
+
for (e.anchor !== null && M(e, "duplication of an anchor property"), t = e.input.charCodeAt(++e.position), n = e.position; t !== 0 && !fe(t) && !Oe(t); )
|
|
2156
2159
|
t = e.input.charCodeAt(++e.position);
|
|
2157
|
-
return e.position === n &&
|
|
2160
|
+
return e.position === n && M(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(n, e.position), !0;
|
|
2158
2161
|
}
|
|
2159
2162
|
function ti(e) {
|
|
2160
2163
|
var n, t, a;
|
|
@@ -2162,40 +2165,40 @@ function ti(e) {
|
|
|
2162
2165
|
return !1;
|
|
2163
2166
|
for (a = e.input.charCodeAt(++e.position), n = e.position; a !== 0 && !fe(a) && !Oe(a); )
|
|
2164
2167
|
a = e.input.charCodeAt(++e.position);
|
|
2165
|
-
return e.position === n &&
|
|
2168
|
+
return e.position === n && M(e, "name of an alias node must contain at least one character"), t = e.input.slice(n, e.position), _e.call(e.anchorMap, t) || M(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], ae(e, !0, -1), !0;
|
|
2166
2169
|
}
|
|
2167
|
-
function
|
|
2168
|
-
var o, i,
|
|
2169
|
-
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = i =
|
|
2170
|
+
function Ne(e, n, t, a, r) {
|
|
2171
|
+
var o, i, l, s = 1, u = !1, p = !1, c, h, d, w, v, A;
|
|
2172
|
+
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = i = l = ze === t || Rn === t, a && ae(e, !0, -1) && (u = !0, e.lineIndent > n ? s = 1 : e.lineIndent === n ? s = 0 : e.lineIndent < n && (s = -1)), s === 1)
|
|
2170
2173
|
for (; Xo(e) || ei(e); )
|
|
2171
|
-
ae(e, !0, -1) ? (u = !0,
|
|
2172
|
-
if (
|
|
2174
|
+
ae(e, !0, -1) ? (u = !0, l = o, e.lineIndent > n ? s = 1 : e.lineIndent === n ? s = 0 : e.lineIndent < n && (s = -1)) : l = !1;
|
|
2175
|
+
if (l && (l = u || r), (s === 1 || ze === t) && (He === t || Vn === t ? v = n : v = n + 1, A = e.position - e.lineStart, s === 1 ? l && (Qt(e, A) || Qo(e, A, v)) || Yo(e, v) ? p = !0 : (i && Zo(e, v) || Jo(e, v) || Wo(e, v) ? p = !0 : ti(e) ? (p = !0, (e.tag !== null || e.anchor !== null) && M(e, "alias node should not have any properties")) : zo(e, v, He === t) && (p = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : s === 0 && (p = l && Qt(e, A))), e.tag === null)
|
|
2173
2176
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2174
2177
|
else if (e.tag === "?") {
|
|
2175
|
-
for (e.result !== null && e.kind !== "scalar" &&
|
|
2178
|
+
for (e.result !== null && e.kind !== "scalar" && M(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), c = 0, h = e.implicitTypes.length; c < h; c += 1)
|
|
2176
2179
|
if (w = e.implicitTypes[c], w.resolve(e.result)) {
|
|
2177
2180
|
e.result = w.construct(e.result), e.tag = w.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2178
2181
|
break;
|
|
2179
2182
|
}
|
|
2180
2183
|
} else if (e.tag !== "!") {
|
|
2181
|
-
if (
|
|
2184
|
+
if (_e.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
2182
2185
|
w = e.typeMap[e.kind || "fallback"][e.tag];
|
|
2183
2186
|
else
|
|
2184
|
-
for (w = null,
|
|
2185
|
-
if (e.tag.slice(0,
|
|
2186
|
-
w =
|
|
2187
|
+
for (w = null, d = e.typeMap.multi[e.kind || "fallback"], c = 0, h = d.length; c < h; c += 1)
|
|
2188
|
+
if (e.tag.slice(0, d[c].tag.length) === d[c].tag) {
|
|
2189
|
+
w = d[c];
|
|
2187
2190
|
break;
|
|
2188
2191
|
}
|
|
2189
|
-
w ||
|
|
2192
|
+
w || M(e, "unknown tag !<" + e.tag + ">"), e.result !== null && w.kind !== e.kind && M(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + w.kind + '", not "' + e.kind + '"'), w.resolve(e.result, e.tag) ? (e.result = w.construct(e.result, e.tag), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : M(e, "cannot resolve a node with !<" + e.tag + "> explicit tag");
|
|
2190
2193
|
}
|
|
2191
|
-
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null ||
|
|
2194
|
+
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || p;
|
|
2192
2195
|
}
|
|
2193
2196
|
function ni(e) {
|
|
2194
2197
|
var n = e.position, t, a, r, o = !1, i;
|
|
2195
2198
|
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)); ) {
|
|
2196
2199
|
for (o = !0, i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !fe(i); )
|
|
2197
2200
|
i = e.input.charCodeAt(++e.position);
|
|
2198
|
-
for (a = e.input.slice(t, e.position), r = [], a.length < 1 &&
|
|
2201
|
+
for (a = e.input.slice(t, e.position), r = [], a.length < 1 && M(e, "directive name must not be less than one character in length"); i !== 0; ) {
|
|
2199
2202
|
for (; Ae(i); )
|
|
2200
2203
|
i = e.input.charCodeAt(++e.position);
|
|
2201
2204
|
if (i === 35) {
|
|
@@ -2210,14 +2213,14 @@ function ni(e) {
|
|
|
2210
2213
|
i = e.input.charCodeAt(++e.position);
|
|
2211
2214
|
r.push(e.input.slice(t, e.position));
|
|
2212
2215
|
}
|
|
2213
|
-
i !== 0 && It(e),
|
|
2216
|
+
i !== 0 && It(e), _e.call(Yt, a) ? Yt[a](e, a, r) : Je(e, 'unknown document directive "' + a + '"');
|
|
2214
2217
|
}
|
|
2215
|
-
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)) : o &&
|
|
2218
|
+
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)) : o && M(e, "directives end mark is expected"), Ne(e, e.lineIndent - 1, ze, !1, !0), ae(e, !0, -1), e.checkLineBreaks && Uo.test(e.input.slice(n, e.position)) && Je(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && Xe(e)) {
|
|
2216
2219
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, ae(e, !0, -1));
|
|
2217
2220
|
return;
|
|
2218
2221
|
}
|
|
2219
2222
|
if (e.position < e.length - 1)
|
|
2220
|
-
|
|
2223
|
+
M(e, "end of the stream or a document separator is expected");
|
|
2221
2224
|
else
|
|
2222
2225
|
return;
|
|
2223
2226
|
}
|
|
@@ -2225,7 +2228,7 @@ function Yn(e, n) {
|
|
|
2225
2228
|
e = String(e), n = n || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2226
2229
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2227
2230
|
var t = new Ho(e, n), a = e.indexOf("\0");
|
|
2228
|
-
for (a !== -1 && (t.position = a,
|
|
2231
|
+
for (a !== -1 && (t.position = a, M(t, "null byte is not allowed in input")), t.input += "\0"; t.input.charCodeAt(t.position) === 32; )
|
|
2229
2232
|
t.lineIndent += 1, t.position += 1;
|
|
2230
2233
|
for (; t.position < t.length - 1; )
|
|
2231
2234
|
ni(t);
|
|
@@ -2244,28 +2247,28 @@ function ri(e, n) {
|
|
|
2244
2247
|
if (t.length !== 0) {
|
|
2245
2248
|
if (t.length === 1)
|
|
2246
2249
|
return t[0];
|
|
2247
|
-
throw new
|
|
2250
|
+
throw new se("expected a single document in the stream, but found more");
|
|
2248
2251
|
}
|
|
2249
2252
|
}
|
|
2250
|
-
var oi = ai, ii = ri,
|
|
2253
|
+
var oi = ai, ii = ri, Zn = {
|
|
2251
2254
|
loadAll: oi,
|
|
2252
2255
|
load: ii
|
|
2253
|
-
},
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2256
|
+
}, Qn = Object.prototype.toString, Xn = Object.prototype.hasOwnProperty, St = 65279, li = 9, Pe = 10, si = 13, ui = 32, ci = 33, di = 34, dt = 35, pi = 37, fi = 38, mi = 39, gi = 42, ea = 44, yi = 45, We = 58, hi = 61, vi = 62, bi = 63, Ci = 64, ta = 91, na = 93, ki = 96, aa = 123, wi = 124, ra = 125, le = {};
|
|
2257
|
+
le[0] = "\\0";
|
|
2258
|
+
le[7] = "\\a";
|
|
2259
|
+
le[8] = "\\b";
|
|
2260
|
+
le[9] = "\\t";
|
|
2261
|
+
le[10] = "\\n";
|
|
2262
|
+
le[11] = "\\v";
|
|
2263
|
+
le[12] = "\\f";
|
|
2264
|
+
le[13] = "\\r";
|
|
2265
|
+
le[27] = "\\e";
|
|
2266
|
+
le[34] = '\\"';
|
|
2267
|
+
le[92] = "\\\\";
|
|
2268
|
+
le[133] = "\\N";
|
|
2269
|
+
le[160] = "\\_";
|
|
2270
|
+
le[8232] = "\\L";
|
|
2271
|
+
le[8233] = "\\P";
|
|
2269
2272
|
var Ii = [
|
|
2270
2273
|
"y",
|
|
2271
2274
|
"Y",
|
|
@@ -2284,15 +2287,15 @@ var Ii = [
|
|
|
2284
2287
|
"Off",
|
|
2285
2288
|
"OFF"
|
|
2286
2289
|
], _i = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2287
|
-
function
|
|
2288
|
-
var t, a, r, o, i,
|
|
2290
|
+
function Si(e, n) {
|
|
2291
|
+
var t, a, r, o, i, l, s;
|
|
2289
2292
|
if (n === null)
|
|
2290
2293
|
return {};
|
|
2291
2294
|
for (t = {}, a = Object.keys(n), r = 0, o = a.length; r < o; r += 1)
|
|
2292
|
-
i = a[r],
|
|
2295
|
+
i = a[r], l = String(n[i]), i.slice(0, 2) === "!!" && (i = "tag:yaml.org,2002:" + i.slice(2)), s = e.compiledTypeMap.fallback[i], s && Xn.call(s.styleAliases, l) && (l = s.styleAliases[l]), t[i] = l;
|
|
2293
2296
|
return t;
|
|
2294
2297
|
}
|
|
2295
|
-
function
|
|
2298
|
+
function Ai(e) {
|
|
2296
2299
|
var n, t, a;
|
|
2297
2300
|
if (n = e.toString(16).toUpperCase(), e <= 255)
|
|
2298
2301
|
t = "x", a = 2;
|
|
@@ -2301,17 +2304,17 @@ function Si(e) {
|
|
|
2301
2304
|
else if (e <= 4294967295)
|
|
2302
2305
|
t = "U", a = 8;
|
|
2303
2306
|
else
|
|
2304
|
-
throw new
|
|
2307
|
+
throw new se("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2305
2308
|
return "\\" + t + re.repeat("0", a - n.length) + n;
|
|
2306
2309
|
}
|
|
2307
|
-
var xi = 1,
|
|
2310
|
+
var xi = 1, De = 2;
|
|
2308
2311
|
function Ti(e) {
|
|
2309
|
-
this.schema = e.schema || wt, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = re.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap =
|
|
2312
|
+
this.schema = e.schema || wt, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = re.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = Si(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 === '"' ? De : xi, 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;
|
|
2310
2313
|
}
|
|
2311
2314
|
function Xt(e, n) {
|
|
2312
|
-
for (var t = re.repeat(" ", n), a = 0, r = -1, o = "", i,
|
|
2315
|
+
for (var t = re.repeat(" ", n), a = 0, r = -1, o = "", i, l = e.length; a < l; )
|
|
2313
2316
|
r = e.indexOf(`
|
|
2314
|
-
`, a), r === -1 ? (i = e.slice(a), a =
|
|
2317
|
+
`, a), r === -1 ? (i = e.slice(a), a = l) : (i = e.slice(a, r + 1), a = r + 1), i.length && i !== `
|
|
2315
2318
|
` && (o += t), o += i;
|
|
2316
2319
|
return o;
|
|
2317
2320
|
}
|
|
@@ -2326,98 +2329,98 @@ function $i(e, n) {
|
|
|
2326
2329
|
return !0;
|
|
2327
2330
|
return !1;
|
|
2328
2331
|
}
|
|
2329
|
-
function
|
|
2330
|
-
return e === ui || e ===
|
|
2332
|
+
function Ye(e) {
|
|
2333
|
+
return e === ui || e === li;
|
|
2331
2334
|
}
|
|
2332
|
-
function
|
|
2333
|
-
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !==
|
|
2335
|
+
function Ve(e) {
|
|
2336
|
+
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== St || 65536 <= e && e <= 1114111;
|
|
2334
2337
|
}
|
|
2335
2338
|
function en(e) {
|
|
2336
|
-
return
|
|
2339
|
+
return Ve(e) && e !== St && e !== si && e !== Pe;
|
|
2337
2340
|
}
|
|
2338
2341
|
function tn(e, n, t) {
|
|
2339
|
-
var a = en(e), r = a && !
|
|
2342
|
+
var a = en(e), r = a && !Ye(e);
|
|
2340
2343
|
return (
|
|
2341
2344
|
// ns-plain-safe
|
|
2342
2345
|
(t ? (
|
|
2343
2346
|
// c = flow-in
|
|
2344
2347
|
a
|
|
2345
|
-
) : a && e !==
|
|
2348
|
+
) : a && e !== ea && e !== ta && e !== na && e !== aa && e !== ra) && e !== dt && !(n === We && !r) || en(n) && !Ye(n) && e === dt || n === We && r
|
|
2346
2349
|
);
|
|
2347
2350
|
}
|
|
2348
|
-
function Mi(e) {
|
|
2349
|
-
return Re(e) && e !== At && !We(e) && e !== yi && e !== bi && e !== Ye && e !== Xn && e !== ea && e !== ta && e !== na && e !== aa && e !== dt && e !== fi && e !== gi && e !== ci && e !== wi && e !== hi && e !== vi && e !== mi && e !== di && e !== pi && e !== Ci && e !== ki;
|
|
2350
|
-
}
|
|
2351
2351
|
function ji(e) {
|
|
2352
|
-
return !
|
|
2352
|
+
return Ve(e) && e !== St && !Ye(e) && e !== yi && e !== bi && e !== We && e !== ea && e !== ta && e !== na && e !== aa && e !== ra && e !== dt && e !== fi && e !== gi && e !== ci && e !== wi && e !== hi && e !== vi && e !== mi && e !== di && e !== pi && e !== Ci && e !== ki;
|
|
2353
2353
|
}
|
|
2354
|
-
function
|
|
2354
|
+
function Mi(e) {
|
|
2355
|
+
return !Ye(e) && e !== We;
|
|
2356
|
+
}
|
|
2357
|
+
function qe(e, n) {
|
|
2355
2358
|
var t = e.charCodeAt(n), a;
|
|
2356
2359
|
return t >= 55296 && t <= 56319 && n + 1 < e.length && (a = e.charCodeAt(n + 1), a >= 56320 && a <= 57343) ? (t - 55296) * 1024 + a - 56320 + 65536 : t;
|
|
2357
2360
|
}
|
|
2358
|
-
function
|
|
2361
|
+
function oa(e) {
|
|
2359
2362
|
var n = /^\n* /;
|
|
2360
2363
|
return n.test(e);
|
|
2361
2364
|
}
|
|
2362
|
-
var
|
|
2363
|
-
function Oi(e, n, t, a, r, o, i,
|
|
2364
|
-
var
|
|
2365
|
+
var ia = 1, ft = 2, la = 3, sa = 4, Me = 5;
|
|
2366
|
+
function Oi(e, n, t, a, r, o, i, l) {
|
|
2367
|
+
var s, u = 0, p = null, c = !1, h = !1, d = a !== -1, w = -1, v = ji(qe(e, 0)) && Mi(qe(e, e.length - 1));
|
|
2365
2368
|
if (n || i)
|
|
2366
|
-
for (
|
|
2367
|
-
if (u =
|
|
2368
|
-
return
|
|
2369
|
-
v = v && tn(u,
|
|
2369
|
+
for (s = 0; s < e.length; u >= 65536 ? s += 2 : s++) {
|
|
2370
|
+
if (u = qe(e, s), !Ve(u))
|
|
2371
|
+
return Me;
|
|
2372
|
+
v = v && tn(u, p, l), p = u;
|
|
2370
2373
|
}
|
|
2371
2374
|
else {
|
|
2372
|
-
for (
|
|
2373
|
-
if (u =
|
|
2374
|
-
c = !0,
|
|
2375
|
-
|
|
2376
|
-
else if (!
|
|
2377
|
-
return
|
|
2378
|
-
v = v && tn(u,
|
|
2375
|
+
for (s = 0; s < e.length; u >= 65536 ? s += 2 : s++) {
|
|
2376
|
+
if (u = qe(e, s), u === Pe)
|
|
2377
|
+
c = !0, d && (h = h || // Foldable line = too long, and not more-indented.
|
|
2378
|
+
s - w - 1 > a && e[w + 1] !== " ", w = s);
|
|
2379
|
+
else if (!Ve(u))
|
|
2380
|
+
return Me;
|
|
2381
|
+
v = v && tn(u, p, l), p = u;
|
|
2379
2382
|
}
|
|
2380
|
-
h = h ||
|
|
2383
|
+
h = h || d && s - w - 1 > a && e[w + 1] !== " ";
|
|
2381
2384
|
}
|
|
2382
|
-
return !c && !h ? v && !i && !r(e) ?
|
|
2385
|
+
return !c && !h ? v && !i && !r(e) ? ia : o === De ? Me : ft : t > 9 && oa(e) ? Me : i ? o === De ? Me : ft : h ? sa : la;
|
|
2383
2386
|
}
|
|
2384
2387
|
function Ei(e, n, t, a, r) {
|
|
2385
2388
|
e.dump = function() {
|
|
2386
2389
|
if (n.length === 0)
|
|
2387
|
-
return e.quotingType ===
|
|
2390
|
+
return e.quotingType === De ? '""' : "''";
|
|
2388
2391
|
if (!e.noCompatMode && (Ii.indexOf(n) !== -1 || _i.test(n)))
|
|
2389
|
-
return e.quotingType ===
|
|
2390
|
-
var o = e.indent * Math.max(1, t), i = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - o),
|
|
2391
|
-
function
|
|
2392
|
+
return e.quotingType === De ? '"' + n + '"' : "'" + n + "'";
|
|
2393
|
+
var o = e.indent * Math.max(1, t), i = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - o), l = a || e.flowLevel > -1 && t >= e.flowLevel;
|
|
2394
|
+
function s(u) {
|
|
2392
2395
|
return $i(e, u);
|
|
2393
2396
|
}
|
|
2394
2397
|
switch (Oi(
|
|
2395
2398
|
n,
|
|
2396
|
-
|
|
2399
|
+
l,
|
|
2397
2400
|
e.indent,
|
|
2398
2401
|
i,
|
|
2399
|
-
|
|
2402
|
+
s,
|
|
2400
2403
|
e.quotingType,
|
|
2401
2404
|
e.forceQuotes && !a,
|
|
2402
2405
|
r
|
|
2403
2406
|
)) {
|
|
2404
|
-
case
|
|
2407
|
+
case ia:
|
|
2405
2408
|
return n;
|
|
2406
2409
|
case ft:
|
|
2407
2410
|
return "'" + n.replace(/'/g, "''") + "'";
|
|
2408
|
-
case
|
|
2411
|
+
case la:
|
|
2409
2412
|
return "|" + nn(n, e.indent) + an(Xt(n, o));
|
|
2410
2413
|
case sa:
|
|
2411
|
-
return ">" + nn(n, e.indent) + an(Xt(
|
|
2412
|
-
case
|
|
2413
|
-
return '"' +
|
|
2414
|
+
return ">" + nn(n, e.indent) + an(Xt(Fi(n, i), o));
|
|
2415
|
+
case Me:
|
|
2416
|
+
return '"' + Ni(n) + '"';
|
|
2414
2417
|
default:
|
|
2415
|
-
throw new
|
|
2418
|
+
throw new se("impossible error: invalid scalar style");
|
|
2416
2419
|
}
|
|
2417
2420
|
}();
|
|
2418
2421
|
}
|
|
2419
2422
|
function nn(e, n) {
|
|
2420
|
-
var t =
|
|
2423
|
+
var t = oa(e) ? String(n) : "", a = e[e.length - 1] === `
|
|
2421
2424
|
`, r = a && (e[e.length - 2] === `
|
|
2422
2425
|
` || e === `
|
|
2423
2426
|
`), o = r ? "+" : a ? "" : "-";
|
|
@@ -2428,75 +2431,75 @@ function an(e) {
|
|
|
2428
2431
|
return e[e.length - 1] === `
|
|
2429
2432
|
` ? e.slice(0, -1) : e;
|
|
2430
2433
|
}
|
|
2431
|
-
function
|
|
2434
|
+
function Fi(e, n) {
|
|
2432
2435
|
for (var t = /(\n+)([^\n]*)/g, a = function() {
|
|
2433
2436
|
var u = e.indexOf(`
|
|
2434
2437
|
`);
|
|
2435
2438
|
return u = u !== -1 ? u : e.length, t.lastIndex = u, rn(e.slice(0, u), n);
|
|
2436
2439
|
}(), r = e[0] === `
|
|
2437
2440
|
` || e[0] === " ", o, i; i = t.exec(e); ) {
|
|
2438
|
-
var
|
|
2439
|
-
o =
|
|
2440
|
-
` : "") + rn(
|
|
2441
|
+
var l = i[1], s = i[2];
|
|
2442
|
+
o = s[0] === " ", a += l + (!r && !o && s !== "" ? `
|
|
2443
|
+
` : "") + rn(s, n), r = o;
|
|
2441
2444
|
}
|
|
2442
2445
|
return a;
|
|
2443
2446
|
}
|
|
2444
2447
|
function rn(e, n) {
|
|
2445
2448
|
if (e === "" || e[0] === " ")
|
|
2446
2449
|
return e;
|
|
2447
|
-
for (var t = / [^ ]/g, a, r = 0, o, i = 0,
|
|
2448
|
-
|
|
2449
|
-
` + e.slice(r, o), r = o + 1), i =
|
|
2450
|
-
return
|
|
2451
|
-
`, e.length - r > n && i > r ?
|
|
2452
|
-
` + e.slice(i + 1) :
|
|
2453
|
-
}
|
|
2454
|
-
function
|
|
2450
|
+
for (var t = / [^ ]/g, a, r = 0, o, i = 0, l = 0, s = ""; a = t.exec(e); )
|
|
2451
|
+
l = a.index, l - r > n && (o = i > r ? i : l, s += `
|
|
2452
|
+
` + e.slice(r, o), r = o + 1), i = l;
|
|
2453
|
+
return s += `
|
|
2454
|
+
`, e.length - r > n && i > r ? s += e.slice(r, i) + `
|
|
2455
|
+
` + e.slice(i + 1) : s += e.slice(r), s.slice(1);
|
|
2456
|
+
}
|
|
2457
|
+
function Ni(e) {
|
|
2455
2458
|
for (var n = "", t = 0, a, r = 0; r < e.length; t >= 65536 ? r += 2 : r++)
|
|
2456
|
-
t =
|
|
2459
|
+
t = qe(e, r), a = le[t], !a && Ve(t) ? (n += e[r], t >= 65536 && (n += e[r + 1])) : n += a || Ai(t);
|
|
2457
2460
|
return n;
|
|
2458
2461
|
}
|
|
2459
|
-
function
|
|
2460
|
-
var a = "", r = e.tag, o, i,
|
|
2462
|
+
function Ki(e, n, t) {
|
|
2463
|
+
var a = "", r = e.tag, o, i, l;
|
|
2461
2464
|
for (o = 0, i = t.length; o < i; o += 1)
|
|
2462
|
-
|
|
2465
|
+
l = t[o], e.replacer && (l = e.replacer.call(t, String(o), l)), (Ce(e, n, l, !1, !1) || typeof l > "u" && Ce(e, n, null, !1, !1)) && (a !== "" && (a += "," + (e.condenseFlow ? "" : " ")), a += e.dump);
|
|
2463
2466
|
e.tag = r, e.dump = "[" + a + "]";
|
|
2464
2467
|
}
|
|
2465
2468
|
function on(e, n, t, a) {
|
|
2466
|
-
var r = "", o = e.tag, i,
|
|
2467
|
-
for (i = 0,
|
|
2468
|
-
|
|
2469
|
+
var r = "", o = e.tag, i, l, s;
|
|
2470
|
+
for (i = 0, l = t.length; i < l; i += 1)
|
|
2471
|
+
s = t[i], e.replacer && (s = e.replacer.call(t, String(i), s)), (Ce(e, n + 1, s, !0, !0, !1, !0) || typeof s > "u" && Ce(e, n + 1, null, !0, !0, !1, !0)) && ((!a || r !== "") && (r += pt(e, n)), e.dump && Pe === e.dump.charCodeAt(0) ? r += "-" : r += "- ", r += e.dump);
|
|
2469
2472
|
e.tag = o, e.dump = r || "[]";
|
|
2470
2473
|
}
|
|
2471
|
-
function
|
|
2472
|
-
var a = "", r = e.tag, o = Object.keys(t), i,
|
|
2473
|
-
for (i = 0,
|
|
2474
|
-
|
|
2474
|
+
function qi(e, n, t) {
|
|
2475
|
+
var a = "", r = e.tag, o = Object.keys(t), i, l, s, u, p;
|
|
2476
|
+
for (i = 0, l = o.length; i < l; i += 1)
|
|
2477
|
+
p = "", a !== "" && (p += ", "), e.condenseFlow && (p += '"'), s = o[i], u = t[s], e.replacer && (u = e.replacer.call(t, s, u)), Ce(e, n, s, !1, !1) && (e.dump.length > 1024 && (p += "? "), p += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Ce(e, n, u, !1, !1) && (p += e.dump, a += p));
|
|
2475
2478
|
e.tag = r, e.dump = "{" + a + "}";
|
|
2476
2479
|
}
|
|
2477
|
-
function
|
|
2478
|
-
var r = "", o = e.tag, i = Object.keys(t),
|
|
2480
|
+
function Bi(e, n, t, a) {
|
|
2481
|
+
var r = "", o = e.tag, i = Object.keys(t), l, s, u, p, c, h;
|
|
2479
2482
|
if (e.sortKeys === !0)
|
|
2480
2483
|
i.sort();
|
|
2481
2484
|
else if (typeof e.sortKeys == "function")
|
|
2482
2485
|
i.sort(e.sortKeys);
|
|
2483
2486
|
else if (e.sortKeys)
|
|
2484
|
-
throw new
|
|
2485
|
-
for (
|
|
2486
|
-
h = "", (!a || r !== "") && (h += pt(e, n)), u = i[
|
|
2487
|
+
throw new se("sortKeys must be a boolean or a function");
|
|
2488
|
+
for (l = 0, s = i.length; l < s; l += 1)
|
|
2489
|
+
h = "", (!a || r !== "") && (h += pt(e, n)), u = i[l], p = t[u], e.replacer && (p = e.replacer.call(t, u, p)), Ce(e, n + 1, u, !0, !0, !0) && (c = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, c && (e.dump && Pe === e.dump.charCodeAt(0) ? h += "?" : h += "? "), h += e.dump, c && (h += pt(e, n)), Ce(e, n + 1, p, !0, c) && (e.dump && Pe === e.dump.charCodeAt(0) ? h += ":" : h += ": ", h += e.dump, r += h));
|
|
2487
2490
|
e.tag = o, e.dump = r || "{}";
|
|
2488
2491
|
}
|
|
2489
|
-
function
|
|
2490
|
-
var a, r, o, i,
|
|
2492
|
+
function ln(e, n, t) {
|
|
2493
|
+
var a, r, o, i, l, s;
|
|
2491
2494
|
for (r = t ? e.explicitTypes : e.implicitTypes, o = 0, i = r.length; o < i; o += 1)
|
|
2492
|
-
if (
|
|
2493
|
-
if (t ?
|
|
2494
|
-
if (
|
|
2495
|
-
a =
|
|
2496
|
-
else if (
|
|
2497
|
-
a =
|
|
2495
|
+
if (l = r[o], (l.instanceOf || l.predicate) && (!l.instanceOf || typeof n == "object" && n instanceof l.instanceOf) && (!l.predicate || l.predicate(n))) {
|
|
2496
|
+
if (t ? l.multi && l.representName ? e.tag = l.representName(n) : e.tag = l.tag : e.tag = "?", l.represent) {
|
|
2497
|
+
if (s = e.styleMap[l.tag] || l.defaultStyle, Qn.call(l.represent) === "[object Function]")
|
|
2498
|
+
a = l.represent(n, s);
|
|
2499
|
+
else if (Xn.call(l.represent, s))
|
|
2500
|
+
a = l.represent[s](n, s);
|
|
2498
2501
|
else
|
|
2499
|
-
throw new
|
|
2502
|
+
throw new se("!<" + l.tag + '> tag resolver accepts not "' + s + '" style');
|
|
2500
2503
|
e.dump = a;
|
|
2501
2504
|
}
|
|
2502
2505
|
return !0;
|
|
@@ -2504,23 +2507,23 @@ function sn(e, n, t) {
|
|
|
2504
2507
|
return !1;
|
|
2505
2508
|
}
|
|
2506
2509
|
function Ce(e, n, t, a, r, o, i) {
|
|
2507
|
-
e.tag = null, e.dump = t,
|
|
2508
|
-
var
|
|
2510
|
+
e.tag = null, e.dump = t, ln(e, t, !1) || ln(e, t, !0);
|
|
2511
|
+
var l = Qn.call(e.dump), s = a, u;
|
|
2509
2512
|
a && (a = e.flowLevel < 0 || e.flowLevel > n);
|
|
2510
|
-
var
|
|
2511
|
-
if (
|
|
2513
|
+
var p = l === "[object Object]" || l === "[object Array]", c, h;
|
|
2514
|
+
if (p && (c = e.duplicates.indexOf(t), h = c !== -1), (e.tag !== null && e.tag !== "?" || h || e.indent !== 2 && n > 0) && (r = !1), h && e.usedDuplicates[c])
|
|
2512
2515
|
e.dump = "*ref_" + c;
|
|
2513
2516
|
else {
|
|
2514
|
-
if (
|
|
2515
|
-
a && Object.keys(e.dump).length !== 0 ? (
|
|
2516
|
-
else if (
|
|
2517
|
-
a && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? on(e, n - 1, e.dump, r) : on(e, n, e.dump, r), h && (e.dump = "&ref_" + c + e.dump)) : (
|
|
2518
|
-
else if (
|
|
2519
|
-
e.tag !== "?" && Ei(e, e.dump, n, o,
|
|
2517
|
+
if (p && h && !e.usedDuplicates[c] && (e.usedDuplicates[c] = !0), l === "[object Object]")
|
|
2518
|
+
a && Object.keys(e.dump).length !== 0 ? (Bi(e, n, e.dump, r), h && (e.dump = "&ref_" + c + e.dump)) : (qi(e, n, e.dump), h && (e.dump = "&ref_" + c + " " + e.dump));
|
|
2519
|
+
else if (l === "[object Array]")
|
|
2520
|
+
a && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? on(e, n - 1, e.dump, r) : on(e, n, e.dump, r), h && (e.dump = "&ref_" + c + e.dump)) : (Ki(e, n, e.dump), h && (e.dump = "&ref_" + c + " " + e.dump));
|
|
2521
|
+
else if (l === "[object String]")
|
|
2522
|
+
e.tag !== "?" && Ei(e, e.dump, n, o, s);
|
|
2520
2523
|
else {
|
|
2521
|
-
if (
|
|
2524
|
+
if (l === "[object Undefined]" || e.skipInvalid)
|
|
2522
2525
|
return !1;
|
|
2523
|
-
throw new
|
|
2526
|
+
throw new se("unacceptable kind of an object to dump " + l);
|
|
2524
2527
|
}
|
|
2525
2528
|
e.tag !== null && e.tag !== "?" && (u = encodeURI(
|
|
2526
2529
|
e.tag[0] === "!" ? e.tag.slice(1) : e.tag
|
|
@@ -2546,7 +2549,7 @@ function mt(e, n, t) {
|
|
|
2546
2549
|
for (a = Object.keys(e), r = 0, o = a.length; r < o; r += 1)
|
|
2547
2550
|
mt(e[a[r]], n, t);
|
|
2548
2551
|
}
|
|
2549
|
-
function
|
|
2552
|
+
function Ui(e, n) {
|
|
2550
2553
|
n = n || {};
|
|
2551
2554
|
var t = new Ti(n);
|
|
2552
2555
|
t.noRefs || Li(e, t);
|
|
@@ -2554,57 +2557,60 @@ function Pi(e, n) {
|
|
|
2554
2557
|
return t.replacer && (a = t.replacer.call({ "": a }, "", a)), Ce(t, 0, a, !0, !0) ? t.dump + `
|
|
2555
2558
|
` : "";
|
|
2556
2559
|
}
|
|
2557
|
-
var
|
|
2558
|
-
dump:
|
|
2560
|
+
var Pi = Ui, Di = {
|
|
2561
|
+
dump: Pi
|
|
2559
2562
|
};
|
|
2560
|
-
function
|
|
2563
|
+
function At(e, n) {
|
|
2561
2564
|
return function() {
|
|
2562
2565
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + n + " instead, which is now safe by default.");
|
|
2563
2566
|
};
|
|
2564
2567
|
}
|
|
2565
|
-
var
|
|
2566
|
-
binary:
|
|
2567
|
-
float:
|
|
2568
|
-
map:
|
|
2569
|
-
null:
|
|
2568
|
+
var Vi = ie, Ri = _n, Gi = Tn, Hi = En, zi = Fn, Ji = wt, Wi = Zn.load, Yi = Zn.loadAll, Zi = Di.dump, Qi = se, Xi = {
|
|
2569
|
+
binary: Ln,
|
|
2570
|
+
float: On,
|
|
2571
|
+
map: xn,
|
|
2572
|
+
null: $n,
|
|
2570
2573
|
pairs: Pn,
|
|
2571
|
-
set:
|
|
2572
|
-
timestamp:
|
|
2573
|
-
bool:
|
|
2574
|
+
set: Dn,
|
|
2575
|
+
timestamp: qn,
|
|
2576
|
+
bool: jn,
|
|
2574
2577
|
int: Mn,
|
|
2575
2578
|
merge: Bn,
|
|
2576
|
-
omap:
|
|
2579
|
+
omap: Un,
|
|
2577
2580
|
seq: An,
|
|
2578
|
-
str:
|
|
2579
|
-
},
|
|
2580
|
-
Type:
|
|
2581
|
-
Schema:
|
|
2581
|
+
str: Sn
|
|
2582
|
+
}, el = At("safeLoad", "load"), tl = At("safeLoadAll", "loadAll"), nl = At("safeDump", "dump"), al = {
|
|
2583
|
+
Type: Vi,
|
|
2584
|
+
Schema: Ri,
|
|
2582
2585
|
FAILSAFE_SCHEMA: Gi,
|
|
2583
2586
|
JSON_SCHEMA: Hi,
|
|
2584
2587
|
CORE_SCHEMA: zi,
|
|
2585
2588
|
DEFAULT_SCHEMA: Ji,
|
|
2586
|
-
load:
|
|
2587
|
-
loadAll:
|
|
2589
|
+
load: Wi,
|
|
2590
|
+
loadAll: Yi,
|
|
2588
2591
|
dump: Zi,
|
|
2589
2592
|
YAMLException: Qi,
|
|
2590
2593
|
types: Xi,
|
|
2591
|
-
safeLoad:
|
|
2592
|
-
safeLoadAll:
|
|
2593
|
-
safeDump:
|
|
2594
|
+
safeLoad: el,
|
|
2595
|
+
safeLoadAll: tl,
|
|
2596
|
+
safeDump: nl
|
|
2594
2597
|
};
|
|
2595
|
-
const
|
|
2598
|
+
const rl = {
|
|
2596
2599
|
key: 0,
|
|
2597
2600
|
class: "config-card-display-form"
|
|
2598
|
-
},
|
|
2601
|
+
}, ol = ["data-testid"], il = {
|
|
2599
2602
|
key: 0,
|
|
2600
2603
|
class: "config-card-prop-section-title"
|
|
2601
|
-
},
|
|
2604
|
+
}, ll = {
|
|
2602
2605
|
key: 1,
|
|
2603
2606
|
class: "config-card-display-json"
|
|
2604
|
-
},
|
|
2607
|
+
}, sl = {
|
|
2608
|
+
key: 0,
|
|
2609
|
+
class: "config-card-display-json-endpoint"
|
|
2610
|
+
}, ul = {
|
|
2605
2611
|
key: 2,
|
|
2606
2612
|
class: "config-card-display-yaml"
|
|
2607
|
-
},
|
|
2613
|
+
}, cl = /* @__PURE__ */ ne({
|
|
2608
2614
|
__name: "ConfigCardDisplay",
|
|
2609
2615
|
props: {
|
|
2610
2616
|
propertyCollections: {
|
|
@@ -2627,60 +2633,89 @@ const rs = {
|
|
|
2627
2633
|
type: Object,
|
|
2628
2634
|
required: !1,
|
|
2629
2635
|
default: () => null
|
|
2636
|
+
},
|
|
2637
|
+
fetcherUrl: {
|
|
2638
|
+
type: String,
|
|
2639
|
+
required: !0
|
|
2630
2640
|
}
|
|
2631
2641
|
},
|
|
2632
2642
|
setup(e) {
|
|
2633
|
-
|
|
2643
|
+
cn((s) => ({
|
|
2644
|
+
"7b486894": `${l.value}ch`
|
|
2645
|
+
}));
|
|
2646
|
+
const n = e, t = Ze(), { i18n: { t: a } } = oe.useI18n(), r = (s) => !!(s.tooltip || t[`${s.key}-label-tooltip`]), o = E(""), i = E(""), l = $(() => {
|
|
2647
|
+
var s;
|
|
2648
|
+
if (!n.fetcherUrl)
|
|
2649
|
+
return 0;
|
|
2650
|
+
const u = (s = n.fetcherUrl) == null ? void 0 : s.split("/");
|
|
2651
|
+
return u.length < 2 ? 0 : 41 + u[u.length - 2].length;
|
|
2652
|
+
});
|
|
2634
2653
|
return ve(() => n.format, (s) => {
|
|
2635
2654
|
if (s !== "structured") {
|
|
2636
|
-
const
|
|
2637
|
-
delete
|
|
2655
|
+
const u = JSON.parse(JSON.stringify(n.record));
|
|
2656
|
+
delete u.created_at, delete u.updated_at, s === "json" ? o.value = JSON.stringify(u, null, 2) : s === "yaml" && (i.value = al.dump(u));
|
|
2638
2657
|
}
|
|
2639
|
-
}, { immediate: !0 }), (s,
|
|
2640
|
-
const
|
|
2641
|
-
return
|
|
2642
|
-
e.format === "structured" ? (
|
|
2643
|
-
(
|
|
2644
|
-
key: `config-card-details-${
|
|
2645
|
-
class:
|
|
2646
|
-
"data-testid": `config-card-details-${
|
|
2658
|
+
}, { immediate: !0 }), (s, u) => {
|
|
2659
|
+
const p = D("KBadge"), c = D("KCodeBlock");
|
|
2660
|
+
return f(), T(me, null, [
|
|
2661
|
+
e.format === "structured" ? (f(), T("div", rl, [
|
|
2662
|
+
(f(!0), T(me, null, pe(e.propListTypes, (h) => (f(), T("div", {
|
|
2663
|
+
key: `config-card-details-${h}-props`,
|
|
2664
|
+
class: Ie(`config-card-details-${h}-props`),
|
|
2665
|
+
"data-testid": `config-card-details-${h}-props`
|
|
2647
2666
|
}, [
|
|
2648
|
-
|
|
2649
|
-
(
|
|
2650
|
-
key:
|
|
2651
|
-
item:
|
|
2667
|
+
h !== "basic" ? (f(), T("div", il, j(h === "advanced" ? m(a)("baseConfigCard.sections.advanced") : m(a)("baseConfigCard.sections.plugin")), 1)) : H("", !0),
|
|
2668
|
+
(f(!0), T(me, null, pe(e.propertyCollections[h], (d) => (f(), R(Ct, {
|
|
2669
|
+
key: d.key,
|
|
2670
|
+
item: d
|
|
2652
2671
|
}, ke({
|
|
2653
|
-
label:
|
|
2654
|
-
|
|
2672
|
+
label: g(() => [
|
|
2673
|
+
Z(s.$slots, `${d.key}-label`, { row: d }, void 0, !0)
|
|
2655
2674
|
]),
|
|
2656
|
-
[
|
|
2657
|
-
|
|
2658
|
-
row:
|
|
2659
|
-
rowValue:
|
|
2675
|
+
[d.key]: g(({ rowValue: w }) => [
|
|
2676
|
+
Z(s.$slots, d.key, {
|
|
2677
|
+
row: d,
|
|
2678
|
+
rowValue: w
|
|
2660
2679
|
}, void 0, !0)
|
|
2661
2680
|
]),
|
|
2662
2681
|
_: 2
|
|
2663
2682
|
}, [
|
|
2664
|
-
r(
|
|
2683
|
+
r(d) ? {
|
|
2665
2684
|
name: "label-tooltip",
|
|
2666
|
-
fn:
|
|
2667
|
-
|
|
2685
|
+
fn: g(() => [
|
|
2686
|
+
Z(s.$slots, `${d.key}-label-tooltip`, { row: d }, void 0, !0)
|
|
2668
2687
|
]),
|
|
2669
2688
|
key: "0"
|
|
2670
2689
|
} : void 0
|
|
2671
2690
|
]), 1032, ["item"]))), 128))
|
|
2672
|
-
], 10,
|
|
2691
|
+
], 10, ol))), 128))
|
|
2673
2692
|
])) : H("", !0),
|
|
2674
|
-
e.format === "json" ? (
|
|
2675
|
-
|
|
2693
|
+
e.format === "json" ? (f(), T("div", ll, [
|
|
2694
|
+
n.fetcherUrl ? (f(), T("div", sl, [
|
|
2695
|
+
O(p, { appearance: "get" }, {
|
|
2696
|
+
default: g(() => [
|
|
2697
|
+
W(j(m(a)("baseConfigCard.endpoints.get")), 1)
|
|
2698
|
+
]),
|
|
2699
|
+
_: 1
|
|
2700
|
+
}),
|
|
2701
|
+
O(c, {
|
|
2702
|
+
id: "config-card-endpoint-codeblock",
|
|
2703
|
+
code: n.fetcherUrl,
|
|
2704
|
+
"is-single-line": "",
|
|
2705
|
+
language: "json",
|
|
2706
|
+
theme: "dark"
|
|
2707
|
+
}, null, 8, ["code"])
|
|
2708
|
+
])) : H("", !0),
|
|
2709
|
+
O(c, {
|
|
2676
2710
|
id: "config-card-codeblock",
|
|
2711
|
+
class: Ie({ "config-card-display-json-content": n.fetcherUrl }),
|
|
2677
2712
|
code: o.value,
|
|
2678
2713
|
language: "json",
|
|
2679
2714
|
theme: "dark"
|
|
2680
|
-
}, null, 8, ["code"])
|
|
2715
|
+
}, null, 8, ["class", "code"])
|
|
2681
2716
|
])) : H("", !0),
|
|
2682
|
-
e.format === "yaml" ? (
|
|
2683
|
-
|
|
2717
|
+
e.format === "yaml" ? (f(), T("div", ul, [
|
|
2718
|
+
O(c, {
|
|
2684
2719
|
id: "config-card-codeblock",
|
|
2685
2720
|
code: i.value,
|
|
2686
2721
|
language: "yaml",
|
|
@@ -2690,18 +2725,18 @@ const rs = {
|
|
|
2690
2725
|
], 64);
|
|
2691
2726
|
};
|
|
2692
2727
|
}
|
|
2693
|
-
}),
|
|
2728
|
+
}), dl = /* @__PURE__ */ ge(cl, [["__scopeId", "data-v-27f85338"]]), sn = "24px", pl = (e, n) => {
|
|
2694
2729
|
const t = e.__vccOpts || e;
|
|
2695
2730
|
for (const [a, r] of n)
|
|
2696
2731
|
t[a] = r;
|
|
2697
2732
|
return t;
|
|
2698
|
-
},
|
|
2733
|
+
}, fl = (e) => (pn("data-v-a53b73fd"), e = e(), fn(), e), ml = ["aria-hidden"], gl = {
|
|
2699
2734
|
key: 0,
|
|
2700
2735
|
"data-testid": "kui-icon-svg-title"
|
|
2701
|
-
},
|
|
2736
|
+
}, yl = /* @__PURE__ */ fl(() => /* @__PURE__ */ B("path", {
|
|
2702
2737
|
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",
|
|
2703
2738
|
fill: "currentColor"
|
|
2704
|
-
}, null, -1)),
|
|
2739
|
+
}, null, -1)), hl = /* @__PURE__ */ ne({
|
|
2705
2740
|
__name: "BookIcon",
|
|
2706
2741
|
props: {
|
|
2707
2742
|
/** The accessibility text provided to screen readers */
|
|
@@ -2732,7 +2767,7 @@ const rs = {
|
|
|
2732
2767
|
size: {
|
|
2733
2768
|
type: [Number, String],
|
|
2734
2769
|
required: !1,
|
|
2735
|
-
default:
|
|
2770
|
+
default: sn,
|
|
2736
2771
|
// if setting to the imported const fails, just pass a number of 24 as the default.
|
|
2737
2772
|
validator: (e) => {
|
|
2738
2773
|
if (typeof e == "number" && e > 0)
|
|
@@ -2761,7 +2796,7 @@ const rs = {
|
|
|
2761
2796
|
if (o && !isNaN(o) && Number.isInteger(o) && o > 0)
|
|
2762
2797
|
return `${o}px`;
|
|
2763
2798
|
}
|
|
2764
|
-
return
|
|
2799
|
+
return sn;
|
|
2765
2800
|
}), a = $(() => ({
|
|
2766
2801
|
boxSizing: "border-box",
|
|
2767
2802
|
color: n.color,
|
|
@@ -2770,14 +2805,14 @@ const rs = {
|
|
|
2770
2805
|
lineHeight: "0",
|
|
2771
2806
|
width: t.value
|
|
2772
2807
|
}));
|
|
2773
|
-
return (r, o) => (
|
|
2808
|
+
return (r, o) => (f(), R(Fe(e.as), {
|
|
2774
2809
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2775
2810
|
class: "kui-icon book-icon",
|
|
2776
2811
|
"data-testid": "kui-icon-wrapper-book-icon",
|
|
2777
|
-
style:
|
|
2812
|
+
style: dn(a.value)
|
|
2778
2813
|
}, {
|
|
2779
|
-
default:
|
|
2780
|
-
(
|
|
2814
|
+
default: g(() => [
|
|
2815
|
+
(f(), T("svg", {
|
|
2781
2816
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2782
2817
|
"data-testid": "kui-icon-svg-book-icon",
|
|
2783
2818
|
fill: "none",
|
|
@@ -2787,23 +2822,23 @@ const rs = {
|
|
|
2787
2822
|
width: "100%",
|
|
2788
2823
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2789
2824
|
}, [
|
|
2790
|
-
e.title ? (
|
|
2791
|
-
|
|
2792
|
-
], 8,
|
|
2825
|
+
e.title ? (f(), T("title", gl, j(e.title), 1)) : H("", !0),
|
|
2826
|
+
yl
|
|
2827
|
+
], 8, ml))
|
|
2793
2828
|
]),
|
|
2794
2829
|
_: 1
|
|
2795
2830
|
}, 8, ["aria-hidden", "style"]));
|
|
2796
2831
|
}
|
|
2797
|
-
}),
|
|
2832
|
+
}), vl = /* @__PURE__ */ pl(hl, [["__scopeId", "data-v-a53b73fd"]]), bl = { "data-testid": "config-card-title" }, Cl = { class: "config-card-actions" }, kl = ["href"], wl = {
|
|
2798
2833
|
key: 2,
|
|
2799
2834
|
class: "config-card-details-section"
|
|
2800
|
-
},
|
|
2835
|
+
}, Il = {
|
|
2801
2836
|
key: 3,
|
|
2802
2837
|
class: "config-card-details-section"
|
|
2803
|
-
},
|
|
2838
|
+
}, _l = ["data-testid"], Sl = {
|
|
2804
2839
|
key: 0,
|
|
2805
2840
|
class: "config-card-prop-section-title"
|
|
2806
|
-
},
|
|
2841
|
+
}, Al = /* @__PURE__ */ ne({
|
|
2807
2842
|
__name: "EntityBaseConfigCard",
|
|
2808
2843
|
props: {
|
|
2809
2844
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2878,9 +2913,9 @@ const rs = {
|
|
|
2878
2913
|
emits: ["loading", "fetch:success", "fetch:error", "copy:success", "copy:error"],
|
|
2879
2914
|
setup(e, { emit: n }) {
|
|
2880
2915
|
var t;
|
|
2881
|
-
const a = n, r = e, o = Ze(), { i18n: { t: i } } = oe.useI18n(), { getMessageFromError:
|
|
2916
|
+
const a = n, r = e, o = Ze(), { i18n: { t: i } } = oe.useI18n(), { getMessageFromError: l } = oe.useErrors(), { convertKeyToTitle: s } = oe.useStringHelpers(), { axiosInstance: u } = oe.useAxios({
|
|
2882
2917
|
headers: (t = r.config) == null ? void 0 : t.requestHeaders
|
|
2883
|
-
}),
|
|
2918
|
+
}), p = [
|
|
2884
2919
|
{
|
|
2885
2920
|
label: i("baseConfigCard.general.structuredFormat"),
|
|
2886
2921
|
value: "structured",
|
|
@@ -2894,9 +2929,9 @@ const rs = {
|
|
|
2894
2929
|
label: "YAML",
|
|
2895
2930
|
value: "yaml"
|
|
2896
2931
|
}
|
|
2897
|
-
], c =
|
|
2932
|
+
], c = E("structured"), h = (b) => {
|
|
2898
2933
|
c.value = b == null ? void 0 : b.value;
|
|
2899
|
-
},
|
|
2934
|
+
}, d = {
|
|
2900
2935
|
id: {
|
|
2901
2936
|
type: ee.ID,
|
|
2902
2937
|
label: i("baseConfigCard.commonFields.id_label"),
|
|
@@ -2930,145 +2965,145 @@ const rs = {
|
|
|
2930
2965
|
// the last property displayed
|
|
2931
2966
|
section: de.Basic
|
|
2932
2967
|
}
|
|
2933
|
-
}, w =
|
|
2934
|
-
var b, I,
|
|
2935
|
-
if (!
|
|
2968
|
+
}, w = E(!1), v = E(!1), A = E(""), y = E(), C = $(() => {
|
|
2969
|
+
var b, I, N;
|
|
2970
|
+
if (!y.value)
|
|
2936
2971
|
return [];
|
|
2937
|
-
const
|
|
2938
|
-
for (const L in
|
|
2939
|
-
const
|
|
2972
|
+
const V = [], _ = Object.keys(y.value).length;
|
|
2973
|
+
for (const L in y.value) {
|
|
2974
|
+
const P = (I = (b = r.configSchema) == null ? void 0 : b[L]) == null ? void 0 : I.order, G = (N = d[L]) == null ? void 0 : N.order;
|
|
2940
2975
|
let Q = _;
|
|
2941
|
-
(G || G === 0) && (Q = G === -1 ? _ + 1 : G),
|
|
2976
|
+
(G || G === 0) && (Q = G === -1 ? _ + 1 : G), P && (Q = P === -1 ? _ + 1 : P), V.push([L, Q]);
|
|
2942
2977
|
}
|
|
2943
|
-
return
|
|
2944
|
-
return L[1] -
|
|
2945
|
-
}),
|
|
2946
|
-
var
|
|
2947
|
-
const Q = L[0], J = (
|
|
2978
|
+
return V.sort(function(L, P) {
|
|
2979
|
+
return L[1] - P[1];
|
|
2980
|
+
}), V.map((L) => {
|
|
2981
|
+
var P, G;
|
|
2982
|
+
const Q = L[0], J = (P = y.value) == null ? void 0 : P[Q], X = ((G = r.configSchema) == null ? void 0 : G[Q]) || {}, ue = d[Q];
|
|
2948
2983
|
return {
|
|
2949
2984
|
key: Q,
|
|
2950
2985
|
value: J,
|
|
2951
2986
|
hidden: X.hidden || !1,
|
|
2952
2987
|
type: X.type ?? ((ue == null ? void 0 : ue.type) || ee.Text),
|
|
2953
|
-
label: X.label ?? ((ue == null ? void 0 : ue.label) ||
|
|
2988
|
+
label: X.label ?? ((ue == null ? void 0 : ue.label) || s(Q)),
|
|
2954
2989
|
tooltip: X.tooltip ?? ((ue == null ? void 0 : ue.tooltip) || void 0),
|
|
2955
2990
|
section: X.section ?? ((ue == null ? void 0 : ue.section) || de.Advanced)
|
|
2956
2991
|
};
|
|
2957
2992
|
}).filter((L) => !L.hidden && L.key !== r.pluginConfigKey);
|
|
2958
|
-
}),
|
|
2993
|
+
}), U = $(() => {
|
|
2959
2994
|
var b, I;
|
|
2960
|
-
if (!
|
|
2995
|
+
if (!y.value || !r.pluginConfigKey)
|
|
2961
2996
|
return [];
|
|
2962
|
-
const
|
|
2963
|
-
for (const L in
|
|
2964
|
-
const
|
|
2965
|
-
let Q = G != null && G !== "" ?
|
|
2966
|
-
|
|
2997
|
+
const N = y.value[r.pluginConfigKey] || {}, V = Object.keys(N).length, _ = [];
|
|
2998
|
+
for (const L in N) {
|
|
2999
|
+
const P = (I = (b = r.pluginConfigSchema) == null ? void 0 : b[L]) == null ? void 0 : I.order, G = N[L];
|
|
3000
|
+
let Q = G != null && G !== "" ? V - 1 : V;
|
|
3001
|
+
P && (Q = P === -1 ? V + 1 : P), _.push([L, Q]);
|
|
2967
3002
|
}
|
|
2968
|
-
return _.sort(function(L,
|
|
2969
|
-
return L[1] -
|
|
3003
|
+
return _.sort(function(L, P) {
|
|
3004
|
+
return L[1] - P[1];
|
|
2970
3005
|
}), _.map((L) => {
|
|
2971
|
-
var
|
|
2972
|
-
const G = L[0], Q =
|
|
3006
|
+
var P;
|
|
3007
|
+
const G = L[0], Q = N[G], J = ((P = r.pluginConfigSchema) == null ? void 0 : P[G]) || {};
|
|
2973
3008
|
return {
|
|
2974
3009
|
key: G,
|
|
2975
3010
|
value: Q,
|
|
2976
3011
|
hidden: J.hidden || !1,
|
|
2977
3012
|
type: J.type ?? ee.Text,
|
|
2978
|
-
label: J.label ??
|
|
3013
|
+
label: J.label ?? s(G),
|
|
2979
3014
|
tooltip: J.tooltip ?? void 0,
|
|
2980
3015
|
section: de.Plugin
|
|
2981
3016
|
};
|
|
2982
3017
|
}).filter((L) => !L.hidden);
|
|
2983
|
-
}),
|
|
2984
|
-
var b, I,
|
|
3018
|
+
}), S = $(() => {
|
|
3019
|
+
var b, I, N, V;
|
|
2985
3020
|
return {
|
|
2986
3021
|
basic: (b = C.value) == null ? void 0 : b.filter((_) => _.section === de.Basic),
|
|
2987
3022
|
advanced: (I = C.value) == null ? void 0 : I.filter((_) => _.section === de.Advanced),
|
|
2988
|
-
plugin: (
|
|
3023
|
+
plugin: (V = U.value) == null ? void 0 : V.concat((N = C.value) == null ? void 0 : N.filter((_) => _.section === de.Plugin))
|
|
2989
3024
|
};
|
|
2990
|
-
}),
|
|
3025
|
+
}), F = $(() => {
|
|
2991
3026
|
const b = [];
|
|
2992
|
-
return
|
|
2993
|
-
}), k = (b) => !!(b.tooltip || o[`${b.key}-label-tooltip`]),
|
|
3027
|
+
return S.value.basic.length && b.push("basic"), S.value.advanced.length && b.push("advanced"), S.value.plugin.length && b.push("plugin"), b;
|
|
3028
|
+
}), k = (b) => !!(b.tooltip || o[`${b.key}-label-tooltip`]), K = $(() => {
|
|
2994
3029
|
var b, I;
|
|
2995
|
-
let
|
|
2996
|
-
return r.config.app === "konnect" ?
|
|
2997
|
-
}),
|
|
2998
|
-
|
|
3030
|
+
let N = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3031
|
+
return r.config.app === "konnect" ? N = N.replace(/{controlPlaneId}/gi, ((b = r.config) == null ? void 0 : b.controlPlaneId) || "") : r.config.app === "kongManager" && (N = N.replace(/\/{workspace}/gi, (I = r.config) != null && I.workspace ? `/${r.config.workspace}` : "")), N = N.replace(/{id}/gi, r.config.entityId), N;
|
|
3032
|
+
}), q = (b) => {
|
|
3033
|
+
y.value && b(JSON.stringify(y.value)) ? a("copy:success", y.value) : a("copy:error");
|
|
2999
3034
|
};
|
|
3000
3035
|
return ve(w, (b) => {
|
|
3001
3036
|
a("loading", b);
|
|
3002
3037
|
}, { immediate: !0 }), gt(async () => {
|
|
3003
3038
|
v.value = !1, w.value = !0;
|
|
3004
3039
|
try {
|
|
3005
|
-
const { data: b } = await u.get(
|
|
3040
|
+
const { data: b } = await u.get(K.value);
|
|
3006
3041
|
if (r.dataKey)
|
|
3007
3042
|
if (typeof b[r.dataKey] < "u")
|
|
3008
|
-
|
|
3043
|
+
y.value = { ...b[r.dataKey] };
|
|
3009
3044
|
else
|
|
3010
3045
|
throw new Error(i("errors.dataKeyUndefined", { dataKey: r.dataKey }));
|
|
3011
3046
|
else
|
|
3012
|
-
|
|
3047
|
+
y.value = { ...b };
|
|
3013
3048
|
Object.keys(r.configSchema).filter((I) => r.configSchema[I].forceShow).forEach((I) => {
|
|
3014
|
-
|
|
3049
|
+
y.value && typeof y.value[I] > "u" && (y.value[I] = null);
|
|
3015
3050
|
}), a("fetch:success", b);
|
|
3016
3051
|
} catch (b) {
|
|
3017
|
-
const I =
|
|
3018
|
-
|
|
3052
|
+
const I = l(b);
|
|
3053
|
+
A.value = I.startsWith("code") ? i("baseConfigCard.errors.load") : I, v.value = !0, a("fetch:error", b);
|
|
3019
3054
|
} finally {
|
|
3020
3055
|
w.value = !1;
|
|
3021
3056
|
}
|
|
3022
3057
|
}), (b, I) => {
|
|
3023
|
-
const
|
|
3024
|
-
return
|
|
3025
|
-
actions:
|
|
3026
|
-
B("div",
|
|
3027
|
-
|
|
3028
|
-
e.config.jsonYamlEnabled ? (
|
|
3058
|
+
const N = D("KLabel"), V = D("KSelect"), _ = D("KButton"), L = D("KClipboardProvider"), P = D("KSkeleton"), G = D("KEmptyState"), Q = D("KCard");
|
|
3059
|
+
return f(), R(Q, { class: "kong-ui-entity-base-config-card" }, ke({
|
|
3060
|
+
actions: g(() => [
|
|
3061
|
+
B("div", Cl, [
|
|
3062
|
+
Z(b.$slots, "actions", {}, void 0, !0),
|
|
3063
|
+
e.config.jsonYamlEnabled ? (f(), R(N, {
|
|
3029
3064
|
key: 0,
|
|
3030
3065
|
class: "config-format-select-label",
|
|
3031
3066
|
"data-testid": "config-format-select-label"
|
|
3032
3067
|
}, {
|
|
3033
|
-
default:
|
|
3034
|
-
|
|
3068
|
+
default: g(() => [
|
|
3069
|
+
W(j(e.label), 1)
|
|
3035
3070
|
]),
|
|
3036
3071
|
_: 1
|
|
3037
3072
|
})) : H("", !0),
|
|
3038
|
-
e.config.jsonYamlEnabled ? (
|
|
3073
|
+
e.config.jsonYamlEnabled ? (f(), R(V, {
|
|
3039
3074
|
key: 1,
|
|
3040
3075
|
appearance: "select",
|
|
3041
3076
|
"data-testid": "select-config-format",
|
|
3042
|
-
items:
|
|
3077
|
+
items: p,
|
|
3043
3078
|
onChange: h
|
|
3044
3079
|
})) : H("", !0),
|
|
3045
|
-
r.config.jsonYamlEnabled && e.configCardDoc ? (
|
|
3080
|
+
r.config.jsonYamlEnabled && e.configCardDoc ? (f(), R(_, {
|
|
3046
3081
|
key: 2,
|
|
3047
3082
|
appearance: "tertiary",
|
|
3048
3083
|
class: "book-icon",
|
|
3049
3084
|
"data-testid": "book-icon"
|
|
3050
3085
|
}, {
|
|
3051
|
-
default:
|
|
3086
|
+
default: g(() => [
|
|
3052
3087
|
B("a", {
|
|
3053
3088
|
href: e.configCardDoc,
|
|
3054
3089
|
rel: "noopener",
|
|
3055
3090
|
target: "_blank"
|
|
3056
3091
|
}, [
|
|
3057
|
-
|
|
3058
|
-
], 8,
|
|
3092
|
+
O(m(vl), { size: m(_r) }, null, 8, ["size"])
|
|
3093
|
+
], 8, kl)
|
|
3059
3094
|
]),
|
|
3060
3095
|
_: 1
|
|
3061
3096
|
})) : H("", !0),
|
|
3062
|
-
e.config.jsonYamlEnabled ? H("", !0) : (
|
|
3063
|
-
default:
|
|
3064
|
-
!w.value && !v.value ? (
|
|
3097
|
+
e.config.jsonYamlEnabled ? H("", !0) : (f(), R(L, { key: 3 }, {
|
|
3098
|
+
default: g(({ copyToClipboard: J }) => [
|
|
3099
|
+
!w.value && !v.value ? (f(), R(_, {
|
|
3065
3100
|
key: 0,
|
|
3066
3101
|
appearance: "tertiary",
|
|
3067
3102
|
"data-testid": "json-copy-button",
|
|
3068
|
-
onClick: (X) =>
|
|
3103
|
+
onClick: (X) => q(J)
|
|
3069
3104
|
}, {
|
|
3070
|
-
default:
|
|
3071
|
-
|
|
3105
|
+
default: g(() => [
|
|
3106
|
+
W(j(m(i)("baseConfigCard.actions.copy")), 1)
|
|
3072
3107
|
]),
|
|
3073
3108
|
_: 2
|
|
3074
3109
|
}, 1032, ["onClick"])) : H("", !0)
|
|
@@ -3077,55 +3112,56 @@ const rs = {
|
|
|
3077
3112
|
}))
|
|
3078
3113
|
])
|
|
3079
3114
|
]),
|
|
3080
|
-
default:
|
|
3081
|
-
w.value ? (
|
|
3115
|
+
default: g(() => [
|
|
3116
|
+
w.value ? (f(), R(P, {
|
|
3082
3117
|
key: 0,
|
|
3083
3118
|
"data-testid": "config-card-loader",
|
|
3084
3119
|
"table-columns": 2,
|
|
3085
3120
|
type: "table"
|
|
3086
|
-
})) : v.value ? (
|
|
3121
|
+
})) : v.value ? (f(), R(G, {
|
|
3087
3122
|
key: 1,
|
|
3088
3123
|
"data-testid": "config-card-fetch-error",
|
|
3089
3124
|
"is-error": ""
|
|
3090
3125
|
}, {
|
|
3091
|
-
message:
|
|
3092
|
-
B("h3", null,
|
|
3126
|
+
message: g(() => [
|
|
3127
|
+
B("h3", null, j(A.value), 1)
|
|
3093
3128
|
]),
|
|
3094
3129
|
_: 1
|
|
3095
3130
|
})) : H("", !0),
|
|
3096
|
-
e.config.jsonYamlEnabled ? (
|
|
3097
|
-
|
|
3131
|
+
e.config.jsonYamlEnabled ? (f(), T("div", wl, [
|
|
3132
|
+
O(dl, {
|
|
3133
|
+
"fetcher-url": K.value,
|
|
3098
3134
|
format: c.value,
|
|
3099
|
-
"prop-list-types":
|
|
3100
|
-
"property-collections":
|
|
3101
|
-
record:
|
|
3135
|
+
"prop-list-types": F.value,
|
|
3136
|
+
"property-collections": S.value,
|
|
3137
|
+
record: y.value
|
|
3102
3138
|
}, ke({ _: 2 }, [
|
|
3103
3139
|
pe(Object.keys(b.$slots), (J) => ({
|
|
3104
3140
|
name: J,
|
|
3105
|
-
fn:
|
|
3106
|
-
|
|
3141
|
+
fn: g(({ row: X, rowValue: ue }) => [
|
|
3142
|
+
Z(b.$slots, J, {
|
|
3107
3143
|
row: X,
|
|
3108
3144
|
rowValue: ue
|
|
3109
3145
|
}, void 0, !0)
|
|
3110
3146
|
])
|
|
3111
3147
|
}))
|
|
3112
|
-
]), 1032, ["format", "prop-list-types", "property-collections", "record"])
|
|
3113
|
-
])) : (
|
|
3114
|
-
(
|
|
3148
|
+
]), 1032, ["fetcher-url", "format", "prop-list-types", "property-collections", "record"])
|
|
3149
|
+
])) : (f(), T("div", Il, [
|
|
3150
|
+
(f(!0), T(me, null, pe(F.value, (J) => (f(), T("div", {
|
|
3115
3151
|
key: `config-card-details-${J}-props`,
|
|
3116
|
-
class:
|
|
3152
|
+
class: Ie(`config-card-details-${J}-props`),
|
|
3117
3153
|
"data-testid": `config-card-details-${J}-props`
|
|
3118
3154
|
}, [
|
|
3119
|
-
J !== "basic" ? (
|
|
3120
|
-
(
|
|
3155
|
+
J !== "basic" ? (f(), T("div", Sl, j(J === "advanced" ? m(i)("baseConfigCard.sections.advanced") : m(i)("baseConfigCard.sections.plugin")), 1)) : H("", !0),
|
|
3156
|
+
(f(!0), T(me, null, pe(S.value[J], (X) => (f(), R(Ct, {
|
|
3121
3157
|
key: X.key,
|
|
3122
3158
|
item: X
|
|
3123
3159
|
}, ke({
|
|
3124
|
-
label:
|
|
3125
|
-
|
|
3160
|
+
label: g(() => [
|
|
3161
|
+
Z(b.$slots, `${X.key}-label`, { row: X }, void 0, !0)
|
|
3126
3162
|
]),
|
|
3127
|
-
[X.key]:
|
|
3128
|
-
|
|
3163
|
+
[X.key]: g(({ rowValue: ue }) => [
|
|
3164
|
+
Z(b.$slots, X.key, {
|
|
3129
3165
|
row: X,
|
|
3130
3166
|
rowValue: ue
|
|
3131
3167
|
}, void 0, !0)
|
|
@@ -3134,23 +3170,23 @@ const rs = {
|
|
|
3134
3170
|
}, [
|
|
3135
3171
|
k(X) ? {
|
|
3136
3172
|
name: "label-tooltip",
|
|
3137
|
-
fn:
|
|
3138
|
-
|
|
3173
|
+
fn: g(() => [
|
|
3174
|
+
Z(b.$slots, `${X.key}-label-tooltip`, { row: X }, void 0, !0)
|
|
3139
3175
|
]),
|
|
3140
3176
|
key: "0"
|
|
3141
3177
|
} : void 0
|
|
3142
3178
|
]), 1032, ["item"]))), 128))
|
|
3143
|
-
], 10,
|
|
3179
|
+
], 10, _l))), 128))
|
|
3144
3180
|
]))
|
|
3145
3181
|
]),
|
|
3146
3182
|
_: 2
|
|
3147
3183
|
}, [
|
|
3148
3184
|
e.hideTitle ? void 0 : {
|
|
3149
3185
|
name: "title",
|
|
3150
|
-
fn:
|
|
3151
|
-
B("div",
|
|
3152
|
-
|
|
3153
|
-
|
|
3186
|
+
fn: g(() => [
|
|
3187
|
+
B("div", bl, [
|
|
3188
|
+
Z(b.$slots, "title", {}, () => [
|
|
3189
|
+
W(j(m(i)("baseConfigCard.title")), 1)
|
|
3154
3190
|
], !0)
|
|
3155
3191
|
])
|
|
3156
3192
|
]),
|
|
@@ -3159,10 +3195,10 @@ const rs = {
|
|
|
3159
3195
|
]), 1024);
|
|
3160
3196
|
};
|
|
3161
3197
|
}
|
|
3162
|
-
}),
|
|
3198
|
+
}), xl = /* @__PURE__ */ ge(Al, [["__scopeId", "data-v-4f47d6ad"]]), Tl = {
|
|
3163
3199
|
class: "form-actions",
|
|
3164
3200
|
"data-testid": "form-actions"
|
|
3165
|
-
},
|
|
3201
|
+
}, $l = /* @__PURE__ */ ne({
|
|
3166
3202
|
__name: "EntityBaseForm",
|
|
3167
3203
|
props: {
|
|
3168
3204
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3212,87 +3248,87 @@ const rs = {
|
|
|
3212
3248
|
emits: ["loading", "fetch:success", "fetch:error", "submit", "cancel"],
|
|
3213
3249
|
setup(e, { emit: n }) {
|
|
3214
3250
|
var t;
|
|
3215
|
-
const a = n, r = e, o = yt(), { i18n: { t: i } } = oe.useI18n(), { getMessageFromError:
|
|
3251
|
+
const a = n, r = e, o = yt(), { i18n: { t: i } } = oe.useI18n(), { getMessageFromError: l } = oe.useErrors(), { axiosInstance: s } = oe.useAxios({
|
|
3216
3252
|
headers: (t = r.config) == null ? void 0 : t.requestHeaders
|
|
3217
|
-
}), u =
|
|
3218
|
-
var
|
|
3253
|
+
}), u = E(!1), p = E(!1), c = E(""), h = $(() => r.canSubmit === !1 || r.isReadonly), d = $(() => {
|
|
3254
|
+
var y, C;
|
|
3219
3255
|
if (!r.editId)
|
|
3220
3256
|
return "";
|
|
3221
|
-
let
|
|
3222
|
-
return r.config.app === "konnect" ?
|
|
3257
|
+
let U = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3258
|
+
return r.config.app === "konnect" ? U = U.replace(/{controlPlaneId}/gi, ((y = r.config) == null ? void 0 : y.controlPlaneId) || "") : r.config.app === "kongManager" && (U = U.replace(/\/{workspace}/gi, (C = r.config) != null && C.workspace ? `/${r.config.workspace}` : "")), U = U.replace(/{id}/gi, r.editId), U;
|
|
3223
3259
|
}), w = () => {
|
|
3224
3260
|
r.config.cancelRoute ? o.push(r.config.cancelRoute) : v();
|
|
3225
3261
|
}, v = () => {
|
|
3226
3262
|
a("cancel");
|
|
3227
|
-
},
|
|
3263
|
+
}, A = () => {
|
|
3228
3264
|
h.value || a("submit");
|
|
3229
3265
|
};
|
|
3230
|
-
return ve(() => u.value, (
|
|
3231
|
-
a("loading",
|
|
3266
|
+
return ve(() => u.value, (y) => {
|
|
3267
|
+
a("loading", y);
|
|
3232
3268
|
}, { immediate: !0 }), gt(async () => {
|
|
3233
3269
|
if (r.editId)
|
|
3234
3270
|
try {
|
|
3235
|
-
|
|
3236
|
-
const { data:
|
|
3237
|
-
a("fetch:success",
|
|
3238
|
-
} catch (
|
|
3239
|
-
const C =
|
|
3240
|
-
c.value = C.startsWith("code") ? i("baseForm.errors.edit") : C,
|
|
3271
|
+
p.value = !1, u.value = !0;
|
|
3272
|
+
const { data: y } = await s.get(d.value);
|
|
3273
|
+
a("fetch:success", y);
|
|
3274
|
+
} catch (y) {
|
|
3275
|
+
const C = l(y);
|
|
3276
|
+
c.value = C.startsWith("code") ? i("baseForm.errors.edit") : C, p.value = !0, a("fetch:error", y);
|
|
3241
3277
|
} finally {
|
|
3242
3278
|
u.value = !1;
|
|
3243
3279
|
}
|
|
3244
|
-
}), (
|
|
3245
|
-
const
|
|
3246
|
-
return
|
|
3247
|
-
default:
|
|
3248
|
-
u.value ? (
|
|
3280
|
+
}), (y, C) => {
|
|
3281
|
+
const U = D("KSkeleton"), S = D("KEmptyState"), F = D("KAlert"), k = D("KButton"), K = D("KCard");
|
|
3282
|
+
return f(), R(K, { class: "kong-ui-entity-base-form" }, {
|
|
3283
|
+
default: g(() => [
|
|
3284
|
+
u.value ? (f(), R(U, {
|
|
3249
3285
|
key: 0,
|
|
3250
3286
|
type: "form"
|
|
3251
|
-
})) :
|
|
3287
|
+
})) : p.value ? (f(), R(S, {
|
|
3252
3288
|
key: 1,
|
|
3253
3289
|
"cta-text": m(i)("baseForm.actions.back"),
|
|
3254
3290
|
"data-testid": "form-fetch-error",
|
|
3255
3291
|
"handle-click": w,
|
|
3256
3292
|
"is-error": !0
|
|
3257
3293
|
}, {
|
|
3258
|
-
message:
|
|
3259
|
-
B("h3", null,
|
|
3294
|
+
message: g(() => [
|
|
3295
|
+
B("h3", null, j(c.value), 1)
|
|
3260
3296
|
]),
|
|
3261
3297
|
_: 1
|
|
3262
|
-
}, 8, ["cta-text"])) : (
|
|
3298
|
+
}, 8, ["cta-text"])) : (f(), T("form", {
|
|
3263
3299
|
key: 2,
|
|
3264
3300
|
"data-testid": "form-content",
|
|
3265
3301
|
onReset: Ge(v, ["prevent"]),
|
|
3266
|
-
onSubmit: Ge(
|
|
3302
|
+
onSubmit: Ge(A, ["prevent"])
|
|
3267
3303
|
}, [
|
|
3268
|
-
|
|
3269
|
-
e.errorMessage ? (
|
|
3304
|
+
Z(y.$slots, "default", {}, void 0, !0),
|
|
3305
|
+
e.errorMessage ? (f(), R(F, {
|
|
3270
3306
|
key: 0,
|
|
3271
3307
|
"alert-message": e.errorMessage,
|
|
3272
3308
|
appearance: "danger",
|
|
3273
3309
|
"data-testid": "form-error"
|
|
3274
3310
|
}, null, 8, ["alert-message"])) : H("", !0),
|
|
3275
|
-
B("div",
|
|
3276
|
-
|
|
3277
|
-
|
|
3311
|
+
B("div", Tl, [
|
|
3312
|
+
Z(y.$slots, "form-actions", {}, () => [
|
|
3313
|
+
O(k, {
|
|
3278
3314
|
appearance: "secondary",
|
|
3279
3315
|
"data-testid": "form-cancel",
|
|
3280
3316
|
disabled: e.isReadonly,
|
|
3281
3317
|
type: "reset"
|
|
3282
3318
|
}, {
|
|
3283
|
-
default:
|
|
3284
|
-
|
|
3319
|
+
default: g(() => [
|
|
3320
|
+
W(j(m(i)("baseForm.actions.cancel")), 1)
|
|
3285
3321
|
]),
|
|
3286
3322
|
_: 1
|
|
3287
3323
|
}, 8, ["disabled"]),
|
|
3288
|
-
|
|
3324
|
+
O(k, {
|
|
3289
3325
|
appearance: "primary",
|
|
3290
3326
|
"data-testid": "form-submit",
|
|
3291
3327
|
disabled: h.value,
|
|
3292
3328
|
type: "submit"
|
|
3293
3329
|
}, {
|
|
3294
|
-
default:
|
|
3295
|
-
|
|
3330
|
+
default: g(() => [
|
|
3331
|
+
W(j(m(i)("baseForm.actions.save")), 1)
|
|
3296
3332
|
]),
|
|
3297
3333
|
_: 1
|
|
3298
3334
|
}, 8, ["disabled"])
|
|
@@ -3304,10 +3340,10 @@ const rs = {
|
|
|
3304
3340
|
});
|
|
3305
3341
|
};
|
|
3306
3342
|
}
|
|
3307
|
-
}),
|
|
3343
|
+
}), jl = /* @__PURE__ */ ge($l, [["__scopeId", "data-v-448d8512"]]), Ml = {
|
|
3308
3344
|
key: 0,
|
|
3309
3345
|
"data-testid": "first-col"
|
|
3310
|
-
},
|
|
3346
|
+
}, Ol = /* @__PURE__ */ ne({
|
|
3311
3347
|
__name: "EntityBaseTableCell",
|
|
3312
3348
|
props: {
|
|
3313
3349
|
keyName: {
|
|
@@ -3327,61 +3363,61 @@ const rs = {
|
|
|
3327
3363
|
var v;
|
|
3328
3364
|
return ((v = t.value) == null ? void 0 : v.querySelector('[data-testid="first-col"]')) || null;
|
|
3329
3365
|
}), r = $(() => {
|
|
3330
|
-
var v,
|
|
3331
|
-
const
|
|
3332
|
-
return
|
|
3366
|
+
var v, A;
|
|
3367
|
+
const y = (v = n.rowEl) == null ? void 0 : v.querySelectorAll("td");
|
|
3368
|
+
return y ? ((A = y[0]) == null ? void 0 : A.getAttribute("data-testid")) === n.keyName : !1;
|
|
3333
3369
|
});
|
|
3334
3370
|
let o;
|
|
3335
3371
|
const i = () => {
|
|
3336
3372
|
o && (o.disconnect(), o = void 0);
|
|
3337
|
-
},
|
|
3338
|
-
var v,
|
|
3339
|
-
u.value = ((v = a.value) == null ? void 0 : v.getBoundingClientRect().width) || 0,
|
|
3340
|
-
},
|
|
3373
|
+
}, l = () => {
|
|
3374
|
+
var v, A, y;
|
|
3375
|
+
u.value = ((v = a.value) == null ? void 0 : v.getBoundingClientRect().width) || 0, p.value = ((A = t.value) == null ? void 0 : A.clientWidth) || 0, c.value = ((y = s.value) == null ? void 0 : y.innerText) || "";
|
|
3376
|
+
}, s = E({}), u = E(0), p = E(0), c = E(""), h = $(() => [a.value, t.value]), d = ve(
|
|
3341
3377
|
h,
|
|
3342
3378
|
(v) => {
|
|
3343
3379
|
if (r.value && (i(), "ResizeObserver" in window && window)) {
|
|
3344
|
-
o = new ResizeObserver((
|
|
3380
|
+
o = new ResizeObserver((A) => {
|
|
3345
3381
|
window.requestAnimationFrame(() => {
|
|
3346
|
-
!Array.isArray(
|
|
3382
|
+
!Array.isArray(A) || !A.length || l();
|
|
3347
3383
|
});
|
|
3348
3384
|
});
|
|
3349
|
-
for (const
|
|
3350
|
-
|
|
3385
|
+
for (const A of v)
|
|
3386
|
+
A && o.observe(A);
|
|
3351
3387
|
}
|
|
3352
3388
|
},
|
|
3353
3389
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
3354
|
-
), w = $(() => r.value ? u.value >
|
|
3390
|
+
), w = $(() => r.value ? u.value > p.value : !1);
|
|
3355
3391
|
return va(() => {
|
|
3356
|
-
|
|
3392
|
+
l();
|
|
3357
3393
|
}), ba(() => {
|
|
3358
|
-
|
|
3359
|
-
}), (v,
|
|
3360
|
-
const
|
|
3361
|
-
return
|
|
3394
|
+
d();
|
|
3395
|
+
}), (v, A) => {
|
|
3396
|
+
const y = D("KTooltip");
|
|
3397
|
+
return f(), T("span", {
|
|
3362
3398
|
ref_key: "contentRef",
|
|
3363
|
-
ref:
|
|
3399
|
+
ref: s,
|
|
3364
3400
|
class: "content-wrapper"
|
|
3365
3401
|
}, [
|
|
3366
|
-
r.value ? (
|
|
3367
|
-
|
|
3402
|
+
r.value ? (f(), T("span", Ml, [
|
|
3403
|
+
O(y, {
|
|
3368
3404
|
label: w.value ? c.value : "",
|
|
3369
3405
|
"max-width": "300",
|
|
3370
3406
|
placement: "bottomStart"
|
|
3371
3407
|
}, {
|
|
3372
|
-
default:
|
|
3373
|
-
|
|
3408
|
+
default: g(() => [
|
|
3409
|
+
Z(v.$slots, "default", {}, void 0, !0)
|
|
3374
3410
|
]),
|
|
3375
3411
|
_: 3
|
|
3376
3412
|
}, 8, ["label"])
|
|
3377
|
-
])) :
|
|
3413
|
+
])) : Z(v.$slots, "default", { key: 1 }, void 0, !0)
|
|
3378
3414
|
], 512);
|
|
3379
3415
|
};
|
|
3380
3416
|
}
|
|
3381
|
-
}),
|
|
3417
|
+
}), El = /* @__PURE__ */ ge(Ol, [["__scopeId", "data-v-e42a20c9"]]), Fl = { class: "toolbar-container" }, Nl = {
|
|
3382
3418
|
key: 0,
|
|
3383
3419
|
class: "toolbar-button-container"
|
|
3384
|
-
},
|
|
3420
|
+
}, Kl = ["data-testid"], ql = /* @__PURE__ */ ne({
|
|
3385
3421
|
__name: "EntityBaseTable",
|
|
3386
3422
|
props: {
|
|
3387
3423
|
// table header configuration
|
|
@@ -3492,73 +3528,73 @@ const rs = {
|
|
|
3492
3528
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked"],
|
|
3493
3529
|
setup(e, { emit: n }) {
|
|
3494
3530
|
const t = e, a = n, { i18n: { t: r } } = oe.useI18n(), o = $(() => {
|
|
3495
|
-
var
|
|
3531
|
+
var F, k;
|
|
3496
3532
|
return typeof t.errorMessage == "string" ? {
|
|
3497
3533
|
hasError: !!t.errorMessage,
|
|
3498
3534
|
title: t.errorMessage,
|
|
3499
3535
|
message: void 0
|
|
3500
3536
|
} : {
|
|
3501
3537
|
hasError: !!t.errorMessage,
|
|
3502
|
-
title: (
|
|
3538
|
+
title: (F = t.errorMessage) == null ? void 0 : F.title,
|
|
3503
3539
|
message: (k = t.errorMessage) == null ? void 0 : k.message
|
|
3504
3540
|
};
|
|
3505
|
-
}), i = $(() => t.cacheIdentifier || t.preferencesStorageKey),
|
|
3506
|
-
const
|
|
3541
|
+
}), i = $(() => t.cacheIdentifier || t.preferencesStorageKey), l = (F) => F.hasData || !!t.query, s = $(() => {
|
|
3542
|
+
const F = [];
|
|
3507
3543
|
return Object.keys(t.tableHeaders).forEach((k) => {
|
|
3508
|
-
const
|
|
3509
|
-
|
|
3510
|
-
label:
|
|
3544
|
+
const K = t.tableHeaders[k];
|
|
3545
|
+
F.push({
|
|
3546
|
+
label: K.label ?? k,
|
|
3511
3547
|
key: k,
|
|
3512
|
-
sortable:
|
|
3548
|
+
sortable: K.sortable ?? !1
|
|
3513
3549
|
});
|
|
3514
|
-
}), t.enableEntityActions &&
|
|
3550
|
+
}), t.enableEntityActions && F.push({
|
|
3515
3551
|
key: "actions",
|
|
3516
3552
|
hideLabel: !0
|
|
3517
|
-
}),
|
|
3518
|
-
}), u = (
|
|
3519
|
-
"data-rowid":
|
|
3520
|
-
"data-testid":
|
|
3521
|
-
...t.rowAttributes(
|
|
3522
|
-
}),
|
|
3553
|
+
}), F;
|
|
3554
|
+
}), u = (F) => ({
|
|
3555
|
+
"data-rowid": F.id,
|
|
3556
|
+
"data-testid": F.name,
|
|
3557
|
+
...t.rowAttributes(F)
|
|
3558
|
+
}), p = E({}), c = (F) => {
|
|
3523
3559
|
var k;
|
|
3524
|
-
return (k =
|
|
3525
|
-
}, h = (
|
|
3560
|
+
return (k = p.value) == null ? void 0 : k.$el.querySelector(`[data-rowid="${F.id}"]`);
|
|
3561
|
+
}, h = (F) => {
|
|
3526
3562
|
const k = {
|
|
3527
|
-
"data-testid":
|
|
3528
|
-
...t.cellAttributes(
|
|
3563
|
+
"data-testid": F.headerKey,
|
|
3564
|
+
...t.cellAttributes(F)
|
|
3529
3565
|
};
|
|
3530
|
-
return
|
|
3566
|
+
return F.colIndex === 0 && (k.style = {
|
|
3531
3567
|
maxWidth: "250px",
|
|
3532
3568
|
overflowX: "hidden",
|
|
3533
3569
|
textOverflow: "ellipsis"
|
|
3534
3570
|
}), k;
|
|
3535
|
-
},
|
|
3571
|
+
}, d = () => {
|
|
3536
3572
|
a("empty-state-cta-clicked"), w();
|
|
3537
3573
|
}, w = () => {
|
|
3538
3574
|
a("clear-search-input");
|
|
3539
|
-
}, v = $(() => t.disableRowClick ? void 0 : (
|
|
3575
|
+
}, v = $(() => t.disableRowClick ? void 0 : (F, k) => {
|
|
3540
3576
|
a("click:row", k);
|
|
3541
|
-
}),
|
|
3542
|
-
a("sort",
|
|
3543
|
-
}, { setTablePreferences:
|
|
3544
|
-
const
|
|
3577
|
+
}), A = (F) => {
|
|
3578
|
+
a("sort", F);
|
|
3579
|
+
}, { setTablePreferences: y, getTablePreferences: C } = $a(), U = $(() => {
|
|
3580
|
+
const F = C(t.preferencesStorageKey);
|
|
3545
3581
|
return {
|
|
3546
3582
|
...t.initialFetcherParams,
|
|
3547
|
-
...
|
|
3583
|
+
...F
|
|
3548
3584
|
};
|
|
3549
|
-
}),
|
|
3550
|
-
t.preferencesStorageKey &&
|
|
3585
|
+
}), S = (F) => {
|
|
3586
|
+
t.preferencesStorageKey && y(t.preferencesStorageKey, F);
|
|
3551
3587
|
};
|
|
3552
|
-
return (
|
|
3553
|
-
const
|
|
3554
|
-
return
|
|
3588
|
+
return (F, k) => {
|
|
3589
|
+
const K = D("KIcon"), q = D("KButton"), b = D("KDropdown"), I = D("KTable"), N = D("KCard");
|
|
3590
|
+
return f(), R(N, {
|
|
3555
3591
|
class: "kong-ui-entity-base-table",
|
|
3556
3592
|
title: e.title
|
|
3557
3593
|
}, {
|
|
3558
|
-
default:
|
|
3559
|
-
|
|
3594
|
+
default: g(() => [
|
|
3595
|
+
O(I, {
|
|
3560
3596
|
ref_key: "tableRefs",
|
|
3561
|
-
ref:
|
|
3597
|
+
ref: p,
|
|
3562
3598
|
"cache-identifier": i.value,
|
|
3563
3599
|
"cell-attrs": h,
|
|
3564
3600
|
"disable-pagination-page-jump": e.disablePaginationPageJump,
|
|
@@ -3576,52 +3612,52 @@ const rs = {
|
|
|
3576
3612
|
fetcher: e.fetcher,
|
|
3577
3613
|
"fetcher-cache-key": String(e.fetcherCacheKey),
|
|
3578
3614
|
"has-error": o.value.hasError,
|
|
3579
|
-
headers:
|
|
3615
|
+
headers: s.value,
|
|
3580
3616
|
"hide-pagination-when-optional": "",
|
|
3581
|
-
"initial-fetcher-params":
|
|
3617
|
+
"initial-fetcher-params": U.value,
|
|
3582
3618
|
"is-loading": e.isLoading,
|
|
3583
3619
|
"pagination-type": e.paginationType,
|
|
3584
3620
|
"row-attrs": u,
|
|
3585
3621
|
"search-input": e.query,
|
|
3586
|
-
onKtableEmptyStateCtaClicked:
|
|
3622
|
+
onKtableEmptyStateCtaClicked: d,
|
|
3587
3623
|
"onRow:click": v.value,
|
|
3588
|
-
onSort: k[0] || (k[0] = (
|
|
3589
|
-
"onUpdate:tablePreferences":
|
|
3624
|
+
onSort: k[0] || (k[0] = (V) => A(V)),
|
|
3625
|
+
"onUpdate:tablePreferences": S
|
|
3590
3626
|
}, ke({
|
|
3591
|
-
toolbar:
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3627
|
+
toolbar: g(({ state: V }) => [
|
|
3628
|
+
Be(B("div", Fl, [
|
|
3629
|
+
Z(F.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3630
|
+
F.$slots["toolbar-button"] ? (f(), T("div", Nl, [
|
|
3631
|
+
Z(F.$slots, "toolbar-button", {}, void 0, !0)
|
|
3596
3632
|
])) : H("", !0)
|
|
3597
3633
|
], 512), [
|
|
3598
|
-
[Le,
|
|
3634
|
+
[Le, l(V)]
|
|
3599
3635
|
])
|
|
3600
3636
|
]),
|
|
3601
|
-
actions:
|
|
3637
|
+
actions: g(({ row: V, rowKey: _, rowValue: L }) => [
|
|
3602
3638
|
B("div", {
|
|
3603
3639
|
class: "actions-container",
|
|
3604
|
-
"data-testid":
|
|
3640
|
+
"data-testid": V.name
|
|
3605
3641
|
}, [
|
|
3606
|
-
|
|
3642
|
+
O(b, {
|
|
3607
3643
|
"kpop-attributes": { placement: "bottomEnd" },
|
|
3608
3644
|
width: e.dropdownMenuWidth
|
|
3609
3645
|
}, {
|
|
3610
|
-
items:
|
|
3611
|
-
|
|
3612
|
-
row:
|
|
3646
|
+
items: g(() => [
|
|
3647
|
+
Z(F.$slots, "actions", {
|
|
3648
|
+
row: V,
|
|
3613
3649
|
rowKey: _,
|
|
3614
3650
|
rowValue: L
|
|
3615
3651
|
}, void 0, !0)
|
|
3616
3652
|
]),
|
|
3617
|
-
default:
|
|
3618
|
-
|
|
3653
|
+
default: g(() => [
|
|
3654
|
+
O(q, {
|
|
3619
3655
|
class: "actions-trigger",
|
|
3620
3656
|
"data-testid": "overflow-actions-button",
|
|
3621
3657
|
size: "small"
|
|
3622
3658
|
}, {
|
|
3623
|
-
icon:
|
|
3624
|
-
|
|
3659
|
+
icon: g(() => [
|
|
3660
|
+
O(K, {
|
|
3625
3661
|
color: m(wr),
|
|
3626
3662
|
icon: "more",
|
|
3627
3663
|
size: "16"
|
|
@@ -3632,24 +3668,24 @@ const rs = {
|
|
|
3632
3668
|
]),
|
|
3633
3669
|
_: 2
|
|
3634
3670
|
}, 1032, ["width"])
|
|
3635
|
-
], 8,
|
|
3671
|
+
], 8, Kl)
|
|
3636
3672
|
]),
|
|
3637
3673
|
_: 2
|
|
3638
3674
|
}, [
|
|
3639
|
-
pe(e.tableHeaders, (
|
|
3675
|
+
pe(e.tableHeaders, (V, _) => ({
|
|
3640
3676
|
name: _,
|
|
3641
|
-
fn:
|
|
3642
|
-
|
|
3677
|
+
fn: g(({ row: L, rowKey: P, rowValue: G }) => [
|
|
3678
|
+
O(El, {
|
|
3643
3679
|
"key-name": String(_),
|
|
3644
3680
|
"row-el": c(L)
|
|
3645
3681
|
}, {
|
|
3646
|
-
default:
|
|
3647
|
-
|
|
3682
|
+
default: g(() => [
|
|
3683
|
+
Z(F.$slots, _, {
|
|
3648
3684
|
row: L,
|
|
3649
|
-
rowKey:
|
|
3685
|
+
rowKey: P,
|
|
3650
3686
|
rowValue: G
|
|
3651
3687
|
}, () => [
|
|
3652
|
-
|
|
3688
|
+
W(j(G), 1)
|
|
3653
3689
|
], !0)
|
|
3654
3690
|
]),
|
|
3655
3691
|
_: 2
|
|
@@ -3662,13 +3698,13 @@ const rs = {
|
|
|
3662
3698
|
}, 8, ["title"]);
|
|
3663
3699
|
};
|
|
3664
3700
|
}
|
|
3665
|
-
}),
|
|
3701
|
+
}), Bl = /* @__PURE__ */ ge(ql, [["__scopeId", "data-v-57b5a97b"]]), Ll = {
|
|
3666
3702
|
key: 0,
|
|
3667
3703
|
class: "kong-ui-entity-delete-error"
|
|
3668
|
-
},
|
|
3704
|
+
}, Ul = {
|
|
3669
3705
|
key: 1,
|
|
3670
3706
|
class: "description"
|
|
3671
|
-
},
|
|
3707
|
+
}, Pl = /* @__PURE__ */ ne({
|
|
3672
3708
|
__name: "EntityDeleteModal",
|
|
3673
3709
|
props: {
|
|
3674
3710
|
visible: {
|
|
@@ -3709,12 +3745,12 @@ const rs = {
|
|
|
3709
3745
|
setup(e, { emit: n }) {
|
|
3710
3746
|
const { i18nT: t } = oe.useI18n(), a = e, r = n, o = $(() => a.needConfirm ? a.entityName : ""), i = () => {
|
|
3711
3747
|
r("cancel");
|
|
3712
|
-
},
|
|
3748
|
+
}, l = () => {
|
|
3713
3749
|
r("proceed");
|
|
3714
3750
|
};
|
|
3715
|
-
return (
|
|
3716
|
-
const
|
|
3717
|
-
return
|
|
3751
|
+
return (s, u) => {
|
|
3752
|
+
const p = D("KAlert"), c = D("KPrompt");
|
|
3753
|
+
return f(), R(c, {
|
|
3718
3754
|
"action-button-text": "Yes, delete",
|
|
3719
3755
|
"action-pending": e.actionPending,
|
|
3720
3756
|
class: "kong-ui-entity-delete-modal",
|
|
@@ -3723,38 +3759,38 @@ const rs = {
|
|
|
3723
3759
|
title: e.title,
|
|
3724
3760
|
type: "danger",
|
|
3725
3761
|
onCanceled: i,
|
|
3726
|
-
onProceed:
|
|
3762
|
+
onProceed: l
|
|
3727
3763
|
}, {
|
|
3728
|
-
"body-content":
|
|
3729
|
-
e.error ? (
|
|
3730
|
-
|
|
3731
|
-
alertMessage:
|
|
3732
|
-
|
|
3764
|
+
"body-content": g(() => [
|
|
3765
|
+
e.error ? (f(), T("div", Ll, [
|
|
3766
|
+
O(p, { appearance: "danger" }, {
|
|
3767
|
+
alertMessage: g(() => [
|
|
3768
|
+
W(j(e.error), 1)
|
|
3733
3769
|
]),
|
|
3734
3770
|
_: 1
|
|
3735
3771
|
})
|
|
3736
3772
|
])) : H("", !0),
|
|
3737
|
-
|
|
3773
|
+
O(m(t), {
|
|
3738
3774
|
class: "message",
|
|
3739
3775
|
keypath: a.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
3740
3776
|
tag: "p"
|
|
3741
3777
|
}, ke({
|
|
3742
|
-
entityType:
|
|
3743
|
-
|
|
3778
|
+
entityType: g(() => [
|
|
3779
|
+
W(j(a.entityType), 1)
|
|
3744
3780
|
]),
|
|
3745
3781
|
_: 2
|
|
3746
3782
|
}, [
|
|
3747
3783
|
a.entityName ? {
|
|
3748
3784
|
name: "entityName",
|
|
3749
|
-
fn:
|
|
3750
|
-
B("strong", null,
|
|
3785
|
+
fn: g(() => [
|
|
3786
|
+
B("strong", null, j(a.entityName), 1)
|
|
3751
3787
|
]),
|
|
3752
3788
|
key: "0"
|
|
3753
3789
|
} : void 0
|
|
3754
3790
|
]), 1032, ["keypath"]),
|
|
3755
|
-
a.description ||
|
|
3756
|
-
|
|
3757
|
-
B("p", null,
|
|
3791
|
+
a.description || s.$slots.description ? (f(), T("div", Ul, [
|
|
3792
|
+
Z(s.$slots, "description", {}, () => [
|
|
3793
|
+
B("p", null, j(a.description), 1)
|
|
3758
3794
|
], !0)
|
|
3759
3795
|
])) : H("", !0)
|
|
3760
3796
|
]),
|
|
@@ -3762,13 +3798,13 @@ const rs = {
|
|
|
3762
3798
|
}, 8, ["action-pending", "confirmation-text", "is-visible", "title"]);
|
|
3763
3799
|
};
|
|
3764
3800
|
}
|
|
3765
|
-
}),
|
|
3801
|
+
}), Dl = /* @__PURE__ */ ge(Pl, [["__scopeId", "data-v-1c9a2a07"]]), Vl = {
|
|
3766
3802
|
fill: "none",
|
|
3767
3803
|
height: "20",
|
|
3768
3804
|
viewBox: "0 0 20 20",
|
|
3769
3805
|
width: "20",
|
|
3770
3806
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3771
|
-
},
|
|
3807
|
+
}, Rl = {
|
|
3772
3808
|
id: "mask0_180_20349",
|
|
3773
3809
|
height: "20",
|
|
3774
3810
|
maskUnits: "userSpaceOnUse",
|
|
@@ -3776,7 +3812,7 @@ const rs = {
|
|
|
3776
3812
|
width: "20",
|
|
3777
3813
|
x: "0",
|
|
3778
3814
|
y: "0"
|
|
3779
|
-
},
|
|
3815
|
+
}, Gl = ["fill"], Hl = { mask: "url(#mask0_180_20349)" }, zl = ["fill"], un = /* @__PURE__ */ ne({
|
|
3780
3816
|
__name: "IconFilter",
|
|
3781
3817
|
props: {
|
|
3782
3818
|
color: {
|
|
@@ -3785,26 +3821,26 @@ const rs = {
|
|
|
3785
3821
|
}
|
|
3786
3822
|
},
|
|
3787
3823
|
setup(e) {
|
|
3788
|
-
return (n, t) => (
|
|
3789
|
-
B("mask",
|
|
3824
|
+
return (n, t) => (f(), T("svg", Vl, [
|
|
3825
|
+
B("mask", Rl, [
|
|
3790
3826
|
B("rect", {
|
|
3791
3827
|
fill: e.color,
|
|
3792
3828
|
height: "20",
|
|
3793
3829
|
width: "20"
|
|
3794
|
-
}, null, 8,
|
|
3830
|
+
}, null, 8, Gl)
|
|
3795
3831
|
]),
|
|
3796
|
-
B("g",
|
|
3832
|
+
B("g", Hl, [
|
|
3797
3833
|
B("path", {
|
|
3798
3834
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3799
3835
|
fill: e.color
|
|
3800
|
-
}, null, 8,
|
|
3836
|
+
}, null, 8, zl)
|
|
3801
3837
|
])
|
|
3802
3838
|
]));
|
|
3803
3839
|
}
|
|
3804
|
-
}),
|
|
3840
|
+
}), Jl = {
|
|
3805
3841
|
key: 1,
|
|
3806
3842
|
class: "kong-ui-entity-filter"
|
|
3807
|
-
},
|
|
3843
|
+
}, Wl = { class: "menu-item-title" }, Yl = { class: "menu-item-indicator" }, Zl = { class: "menu-item-body" }, Ql = ["for"], Xl = { class: "menu-item-buttons" }, es = { class: "filter-clear-button-container" }, ts = /* @__PURE__ */ ne({
|
|
3808
3844
|
__name: "EntityFilter",
|
|
3809
3845
|
props: {
|
|
3810
3846
|
// filter config, either exact match or fuzzy match
|
|
@@ -3824,142 +3860,142 @@ const rs = {
|
|
|
3824
3860
|
},
|
|
3825
3861
|
emits: ["update:modelValue"],
|
|
3826
3862
|
setup(e, { emit: n }) {
|
|
3827
|
-
const { i18n: { t } } = oe.useI18n(), a = e, r = n, o =
|
|
3828
|
-
const
|
|
3829
|
-
return new URLSearchParams(a.modelValue).forEach((C,
|
|
3830
|
-
C !== "" &&
|
|
3831
|
-
}),
|
|
3832
|
-
}),
|
|
3833
|
-
const
|
|
3834
|
-
return Object.keys(
|
|
3835
|
-
label:
|
|
3863
|
+
const { i18n: { t } } = oe.useI18n(), a = e, r = n, o = E(!1), i = E({}), l = $(() => {
|
|
3864
|
+
const y = [];
|
|
3865
|
+
return new URLSearchParams(a.modelValue).forEach((C, U) => {
|
|
3866
|
+
C !== "" && y.push(U);
|
|
3867
|
+
}), y;
|
|
3868
|
+
}), s = $(() => {
|
|
3869
|
+
const y = a.config.fields;
|
|
3870
|
+
return Object.keys(y).filter((C) => y[C].searchable).map((C) => ({
|
|
3871
|
+
label: y[C].label || C,
|
|
3836
3872
|
value: C
|
|
3837
3873
|
}));
|
|
3838
3874
|
});
|
|
3839
|
-
ve(() => a.modelValue, (
|
|
3840
|
-
i.value = {}, new URLSearchParams(
|
|
3841
|
-
i.value[
|
|
3875
|
+
ve(() => a.modelValue, (y) => {
|
|
3876
|
+
i.value = {}, new URLSearchParams(y).forEach((C, U) => {
|
|
3877
|
+
i.value[U] = C;
|
|
3842
3878
|
});
|
|
3843
3879
|
});
|
|
3844
3880
|
const u = () => {
|
|
3845
3881
|
o.value = !o.value;
|
|
3846
|
-
},
|
|
3847
|
-
r("update:modelValue",
|
|
3848
|
-
}, c = (
|
|
3849
|
-
var C,
|
|
3850
|
-
return (((
|
|
3851
|
-
value:
|
|
3852
|
-
label:
|
|
3882
|
+
}, p = (y) => {
|
|
3883
|
+
r("update:modelValue", y);
|
|
3884
|
+
}, c = (y) => `filter-${y}`, h = (y) => {
|
|
3885
|
+
var C, U;
|
|
3886
|
+
return (((U = (C = a.config.schema) == null ? void 0 : C[y]) == null ? void 0 : U.values) ?? []).map((S) => ({
|
|
3887
|
+
value: S,
|
|
3888
|
+
label: S
|
|
3853
3889
|
}));
|
|
3854
|
-
},
|
|
3855
|
-
var C,
|
|
3856
|
-
return ((
|
|
3857
|
-
}, w = (
|
|
3890
|
+
}, d = (y) => {
|
|
3891
|
+
var C, U;
|
|
3892
|
+
return ((U = (C = a.config.schema) == null ? void 0 : C[y]) == null ? void 0 : U.type) ?? "text";
|
|
3893
|
+
}, w = (y) => {
|
|
3858
3894
|
i.value = {
|
|
3859
3895
|
...i.value,
|
|
3860
|
-
[
|
|
3861
|
-
},
|
|
3896
|
+
[y]: ""
|
|
3897
|
+
}, A();
|
|
3862
3898
|
}, v = () => {
|
|
3863
|
-
i.value = {},
|
|
3864
|
-
},
|
|
3865
|
-
const C = Object.keys(i.value).reduce((
|
|
3866
|
-
|
|
3899
|
+
i.value = {}, A(!0);
|
|
3900
|
+
}, A = (y = !1) => {
|
|
3901
|
+
const C = Object.keys(i.value).reduce((U, S) => (i.value[S] && (U[S] = `${i.value[S]}`), U), {});
|
|
3902
|
+
y && (o.value = !1), r("update:modelValue", new URLSearchParams(C).toString());
|
|
3867
3903
|
};
|
|
3868
|
-
return (
|
|
3869
|
-
const
|
|
3870
|
-
return e.config.isExactMatch ? (
|
|
3904
|
+
return (y, C) => {
|
|
3905
|
+
const U = D("KInput"), S = D("KButton"), F = D("KSelect"), k = D("KMenuItem"), K = D("KMenu");
|
|
3906
|
+
return e.config.isExactMatch ? (f(), R(U, {
|
|
3871
3907
|
key: 0,
|
|
3872
3908
|
autocomplete: "off",
|
|
3873
3909
|
class: "kong-ui-entity-filter-input",
|
|
3874
3910
|
"data-testid": "search-input",
|
|
3875
3911
|
"model-value": e.modelValue,
|
|
3876
3912
|
placeholder: e.config.placeholder,
|
|
3877
|
-
"onUpdate:modelValue":
|
|
3913
|
+
"onUpdate:modelValue": p
|
|
3878
3914
|
}, {
|
|
3879
|
-
before:
|
|
3880
|
-
|
|
3915
|
+
before: g(() => [
|
|
3916
|
+
O(un)
|
|
3881
3917
|
]),
|
|
3882
3918
|
_: 1
|
|
3883
|
-
}, 8, ["model-value", "placeholder"])) : (
|
|
3884
|
-
|
|
3919
|
+
}, 8, ["model-value", "placeholder"])) : (f(), T("div", Jl, [
|
|
3920
|
+
O(S, {
|
|
3885
3921
|
appearance: "tertiary",
|
|
3886
3922
|
"data-testid": "filter-button",
|
|
3887
3923
|
onClick: u
|
|
3888
3924
|
}, {
|
|
3889
|
-
default:
|
|
3890
|
-
|
|
3891
|
-
|
|
3925
|
+
default: g(() => [
|
|
3926
|
+
O(un),
|
|
3927
|
+
W(" " + j(m(t)("filter.filterButtonText")) + " " + j(l.value.length > 0 ? `(${l.value.length})` : ""), 1)
|
|
3892
3928
|
]),
|
|
3893
3929
|
_: 1
|
|
3894
3930
|
}),
|
|
3895
|
-
|
|
3931
|
+
Be(B("div", {
|
|
3896
3932
|
class: "kong-ui-entity-filter-backdrop",
|
|
3897
3933
|
onClick: u
|
|
3898
3934
|
}, null, 512), [
|
|
3899
3935
|
[Le, o.value]
|
|
3900
3936
|
]),
|
|
3901
|
-
|
|
3902
|
-
body:
|
|
3903
|
-
(
|
|
3904
|
-
key:
|
|
3905
|
-
"data-testid":
|
|
3937
|
+
Be(O(K, { class: "kong-ui-entity-filter-menu" }, {
|
|
3938
|
+
body: g(() => [
|
|
3939
|
+
(f(!0), T(me, null, pe(s.value, (q, b) => (f(), R(k, {
|
|
3940
|
+
key: q.value,
|
|
3941
|
+
"data-testid": q.value,
|
|
3906
3942
|
expandable: "",
|
|
3907
|
-
"last-menu-item": b ===
|
|
3943
|
+
"last-menu-item": b === s.value.length - 1
|
|
3908
3944
|
}, {
|
|
3909
|
-
itemTitle:
|
|
3910
|
-
B("span",
|
|
3911
|
-
|
|
3912
|
-
|
|
3913
|
-
[Le,
|
|
3945
|
+
itemTitle: g(() => [
|
|
3946
|
+
B("span", Wl, [
|
|
3947
|
+
W(j(q.label) + " ", 1),
|
|
3948
|
+
Be(B("span", Yl, null, 512), [
|
|
3949
|
+
[Le, l.value.includes(q.value)]
|
|
3914
3950
|
])
|
|
3915
3951
|
])
|
|
3916
3952
|
]),
|
|
3917
|
-
itemBody:
|
|
3918
|
-
var I,
|
|
3953
|
+
itemBody: g(() => {
|
|
3954
|
+
var I, N;
|
|
3919
3955
|
return [
|
|
3920
|
-
B("div",
|
|
3956
|
+
B("div", Zl, [
|
|
3921
3957
|
B("label", {
|
|
3922
3958
|
class: "menu-item-label",
|
|
3923
|
-
for: c(
|
|
3924
|
-
},
|
|
3925
|
-
((
|
|
3959
|
+
for: c(q.value)
|
|
3960
|
+
}, j(m(t)("filter.fieldLabel")), 9, Ql),
|
|
3961
|
+
((N = (I = e.config.schema) == null ? void 0 : I[q.value]) == null ? void 0 : N.type) === "select" ? (f(), R(F, {
|
|
3926
3962
|
key: 0,
|
|
3927
|
-
id: c(
|
|
3928
|
-
modelValue: i.value[
|
|
3929
|
-
"onUpdate:modelValue": (
|
|
3963
|
+
id: c(q.value),
|
|
3964
|
+
modelValue: i.value[q.value],
|
|
3965
|
+
"onUpdate:modelValue": (V) => i.value[q.value] = V,
|
|
3930
3966
|
appearance: "select",
|
|
3931
|
-
items: h(
|
|
3967
|
+
items: h(q.value),
|
|
3932
3968
|
placeholder: m(t)("filter.selectPlaceholder")
|
|
3933
|
-
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (
|
|
3969
|
+
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (f(), R(U, {
|
|
3934
3970
|
key: 1,
|
|
3935
|
-
id: c(
|
|
3936
|
-
modelValue: i.value[
|
|
3937
|
-
"onUpdate:modelValue": (
|
|
3971
|
+
id: c(q.value),
|
|
3972
|
+
modelValue: i.value[q.value],
|
|
3973
|
+
"onUpdate:modelValue": (V) => i.value[q.value] = V,
|
|
3938
3974
|
autocomplete: "off",
|
|
3939
3975
|
placeholder: m(t)("filter.inputPlaceholder"),
|
|
3940
|
-
type:
|
|
3976
|
+
type: d(q.value)
|
|
3941
3977
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3942
3978
|
]),
|
|
3943
|
-
B("div",
|
|
3944
|
-
|
|
3979
|
+
B("div", Xl, [
|
|
3980
|
+
O(S, {
|
|
3945
3981
|
appearance: "tertiary",
|
|
3946
3982
|
"data-testid": "apply-filter",
|
|
3947
3983
|
size: "small",
|
|
3948
|
-
onClick: C[0] || (C[0] = (
|
|
3984
|
+
onClick: C[0] || (C[0] = (V) => A(!0))
|
|
3949
3985
|
}, {
|
|
3950
|
-
default:
|
|
3951
|
-
|
|
3986
|
+
default: g(() => [
|
|
3987
|
+
W(j(m(t)("filter.applyButtonText")), 1)
|
|
3952
3988
|
]),
|
|
3953
3989
|
_: 1
|
|
3954
3990
|
}),
|
|
3955
|
-
|
|
3991
|
+
O(S, {
|
|
3956
3992
|
appearance: "tertiary",
|
|
3957
3993
|
"data-testid": "clear-filter",
|
|
3958
3994
|
size: "small",
|
|
3959
|
-
onClick: (
|
|
3995
|
+
onClick: (V) => w(q.value)
|
|
3960
3996
|
}, {
|
|
3961
|
-
default:
|
|
3962
|
-
|
|
3997
|
+
default: g(() => [
|
|
3998
|
+
W(j(m(t)("filter.clearButtonText")), 1)
|
|
3963
3999
|
]),
|
|
3964
4000
|
_: 2
|
|
3965
4001
|
}, 1032, ["onClick"])
|
|
@@ -3969,15 +4005,15 @@ const rs = {
|
|
|
3969
4005
|
_: 2
|
|
3970
4006
|
}, 1032, ["data-testid", "last-menu-item"]))), 128))
|
|
3971
4007
|
]),
|
|
3972
|
-
actionButton:
|
|
3973
|
-
B("div",
|
|
3974
|
-
|
|
4008
|
+
actionButton: g(() => [
|
|
4009
|
+
B("div", es, [
|
|
4010
|
+
O(S, {
|
|
3975
4011
|
appearance: "tertiary",
|
|
3976
4012
|
size: "small",
|
|
3977
4013
|
onClick: v
|
|
3978
4014
|
}, {
|
|
3979
|
-
default:
|
|
3980
|
-
|
|
4015
|
+
default: g(() => [
|
|
4016
|
+
W(j(m(t)("filter.clearAllButtonText")), 1)
|
|
3981
4017
|
]),
|
|
3982
4018
|
_: 1
|
|
3983
4019
|
})
|
|
@@ -3990,7 +4026,7 @@ const rs = {
|
|
|
3990
4026
|
]));
|
|
3991
4027
|
};
|
|
3992
4028
|
}
|
|
3993
|
-
}),
|
|
4029
|
+
}), ns = /* @__PURE__ */ ge(ts, [["__scopeId", "data-v-15962ee2"]]), Re = /* @__PURE__ */ ne({
|
|
3994
4030
|
__name: "PermissionsWrapper",
|
|
3995
4031
|
props: {
|
|
3996
4032
|
/**
|
|
@@ -4012,24 +4048,24 @@ const rs = {
|
|
|
4012
4048
|
}
|
|
4013
4049
|
},
|
|
4014
4050
|
setup(e) {
|
|
4015
|
-
const n = e, t =
|
|
4051
|
+
const n = e, t = E(void 0), a = $(() => t.value === !0 || t.value !== void 0 && n.forceShow === !0);
|
|
4016
4052
|
return ve(() => n.authFunction, async () => {
|
|
4017
4053
|
t.value = await n.authFunction();
|
|
4018
|
-
}, { immediate: !0 }), (r, o) => a.value ?
|
|
4054
|
+
}, { immediate: !0 }), (r, o) => a.value ? Z(r.$slots, "default", {
|
|
4019
4055
|
key: 0,
|
|
4020
4056
|
isAllowed: t.value
|
|
4021
4057
|
}) : H("", !0);
|
|
4022
4058
|
}
|
|
4023
|
-
}),
|
|
4059
|
+
}), as = { class: "form-section-wrapper" }, rs = {
|
|
4024
4060
|
key: 0,
|
|
4025
4061
|
class: "form-section-title"
|
|
4026
|
-
},
|
|
4062
|
+
}, os = {
|
|
4027
4063
|
key: 1,
|
|
4028
4064
|
class: "form-section-description"
|
|
4029
|
-
},
|
|
4065
|
+
}, is = {
|
|
4030
4066
|
key: 2,
|
|
4031
4067
|
class: "form-section-footer"
|
|
4032
|
-
},
|
|
4068
|
+
}, ls = { class: "form-section-content" }, ss = /* @__PURE__ */ ne({
|
|
4033
4069
|
__name: "EntityFormSection",
|
|
4034
4070
|
props: {
|
|
4035
4071
|
title: {
|
|
@@ -4055,37 +4091,37 @@ const rs = {
|
|
|
4055
4091
|
},
|
|
4056
4092
|
setup(e) {
|
|
4057
4093
|
const n = Ze();
|
|
4058
|
-
return (t, a) => (
|
|
4059
|
-
class:
|
|
4094
|
+
return (t, a) => (f(), T("fieldset", {
|
|
4095
|
+
class: Ie(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }])
|
|
4060
4096
|
}, [
|
|
4061
|
-
B("div",
|
|
4062
|
-
e.hideInfoHeader ? H("", !0) : (
|
|
4097
|
+
B("div", as, [
|
|
4098
|
+
e.hideInfoHeader ? H("", !0) : (f(), T("div", {
|
|
4063
4099
|
key: 0,
|
|
4064
|
-
class:
|
|
4100
|
+
class: Ie(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
4065
4101
|
}, [
|
|
4066
|
-
e.title ? (
|
|
4067
|
-
e.description || m(n).description ? (
|
|
4068
|
-
|
|
4069
|
-
B("p", null,
|
|
4102
|
+
e.title ? (f(), T("h4", rs, j(e.title), 1)) : H("", !0),
|
|
4103
|
+
e.description || m(n).description ? (f(), T("div", os, [
|
|
4104
|
+
Z(t.$slots, "description", {}, () => [
|
|
4105
|
+
B("p", null, j(e.description), 1)
|
|
4070
4106
|
], !0)
|
|
4071
4107
|
])) : H("", !0),
|
|
4072
|
-
m(n).footer ? (
|
|
4073
|
-
|
|
4108
|
+
m(n).footer ? (f(), T("div", is, [
|
|
4109
|
+
Z(t.$slots, "footer", {}, void 0, !0)
|
|
4074
4110
|
])) : H("", !0)
|
|
4075
4111
|
], 2)),
|
|
4076
|
-
B("div",
|
|
4077
|
-
|
|
4112
|
+
B("div", ls, [
|
|
4113
|
+
Z(t.$slots, "default", {}, void 0, !0)
|
|
4078
4114
|
])
|
|
4079
4115
|
])
|
|
4080
4116
|
], 2));
|
|
4081
4117
|
}
|
|
4082
|
-
}),
|
|
4118
|
+
}), us = /* @__PURE__ */ ge(ss, [["__scopeId", "data-v-8b6dc312"]]), { useAxios: xt, useDeleteUrlBuilder: cs, useErrors: ds, useExternalLinkCreator: Ns, useFetchUrlBuilder: Ks, useFetcher: ps, useDebouncedFilter: fs, useStringHelpers: qs, useHelpers: Bs, useGatewayFeatureSupported: Ls, useTruncationDetector: Us } = oe, ms = { class: "add-consumer-form-container" }, gs = { class: "add-consumer-form-cta" }, ys = { class: "select-item-label" }, hs = {
|
|
4083
4119
|
key: 0,
|
|
4084
4120
|
class: "select-item-desc"
|
|
4085
|
-
},
|
|
4121
|
+
}, vs = {
|
|
4086
4122
|
key: 0,
|
|
4087
4123
|
class: "kong-ui-entity-add-consumers-error"
|
|
4088
|
-
},
|
|
4124
|
+
}, bs = { key: 0 }, Cs = /* @__PURE__ */ ne({
|
|
4089
4125
|
__name: "AddConsumerModal",
|
|
4090
4126
|
props: {
|
|
4091
4127
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4102,17 +4138,17 @@ const rs = {
|
|
|
4102
4138
|
},
|
|
4103
4139
|
emits: ["cancel", "add:success", "add:partial-success", "error"],
|
|
4104
4140
|
setup(e, { emit: n }) {
|
|
4105
|
-
var
|
|
4141
|
+
var V;
|
|
4106
4142
|
const { i18n: { t } } = Qe.useI18n(), a = e, r = n, { axiosInstance: o } = xt({
|
|
4107
|
-
headers: (
|
|
4108
|
-
}), i =
|
|
4109
|
-
debouncedQueryChange:
|
|
4110
|
-
loading:
|
|
4143
|
+
headers: (V = a.config) == null ? void 0 : V.requestHeaders
|
|
4144
|
+
}), i = E([]), {
|
|
4145
|
+
debouncedQueryChange: l,
|
|
4146
|
+
loading: s,
|
|
4111
4147
|
allRecords: u,
|
|
4112
|
-
error:
|
|
4148
|
+
error: p,
|
|
4113
4149
|
loadItems: c,
|
|
4114
4150
|
results: h
|
|
4115
|
-
} =
|
|
4151
|
+
} = fs(
|
|
4116
4152
|
a.config,
|
|
4117
4153
|
xe.list[a.config.app].all,
|
|
4118
4154
|
"",
|
|
@@ -4120,103 +4156,103 @@ const rs = {
|
|
|
4120
4156
|
fetchedItemsKey: "data",
|
|
4121
4157
|
searchKeys: ["username", "id"]
|
|
4122
4158
|
}
|
|
4123
|
-
),
|
|
4159
|
+
), d = (_) => _, w = $(() => p.value ? t("consumers.errors.general") : ""), v = E(0), A = $(() => u.value === void 0), y = $(() => h.value.map((_) => ({
|
|
4124
4160
|
label: _.username || _.customId,
|
|
4125
4161
|
value: _.id,
|
|
4126
4162
|
selected: i.value.includes(_.id),
|
|
4127
4163
|
data: _
|
|
4128
4164
|
// we need this to determine whether or not to show the description text
|
|
4129
4165
|
}))), C = (_) => {
|
|
4130
|
-
var
|
|
4131
|
-
const L =
|
|
4166
|
+
var P;
|
|
4167
|
+
const L = A.value ? h.value.find((G) => G.id === _) : (P = u.value) == null ? void 0 : P.find((G) => G.id === _);
|
|
4132
4168
|
return L ? L.username || L.custom_id : _;
|
|
4133
|
-
},
|
|
4134
|
-
k.value = "",
|
|
4135
|
-
},
|
|
4169
|
+
}, U = () => {
|
|
4170
|
+
k.value = "", S.value = [], I.value = [], r("cancel");
|
|
4171
|
+
}, S = E([]), F = E(!1), k = E(""), K = async () => {
|
|
4136
4172
|
if (!i.value.length) {
|
|
4137
4173
|
k.value = "", I.value = [], r("cancel");
|
|
4138
4174
|
return;
|
|
4139
4175
|
}
|
|
4140
|
-
|
|
4176
|
+
F.value = !0, k.value = "", S.value = [], I.value = [];
|
|
4141
4177
|
try {
|
|
4142
4178
|
const _ = i.value.map((G) => b(G)), L = await Promise.allSettled(_);
|
|
4143
|
-
let
|
|
4179
|
+
let P = !0;
|
|
4144
4180
|
L.forEach((G) => {
|
|
4145
|
-
G.status !== "fulfilled" && (
|
|
4146
|
-
}),
|
|
4181
|
+
G.status !== "fulfilled" && (P = !1);
|
|
4182
|
+
}), P ? (S.value = [], I.value = [], r("add:success", i.value), i.value = []) : (S.value.length && r("add:partial-success", S.value), i.value = [], N(L));
|
|
4147
4183
|
} catch {
|
|
4148
4184
|
k.value = t("consumers.errors.add"), r("error", k.value);
|
|
4149
4185
|
} finally {
|
|
4150
|
-
|
|
4186
|
+
F.value = !1;
|
|
4151
4187
|
}
|
|
4152
|
-
},
|
|
4153
|
-
var L,
|
|
4188
|
+
}, q = $(() => {
|
|
4189
|
+
var L, P, G, Q;
|
|
4154
4190
|
let _ = `${a.config.apiBaseUrl}${xe.list[a.config.app].forConsumerGroup}`;
|
|
4155
|
-
return a.config.app === "konnect" ? _ = _.replace(/{controlPlaneId}/gi, ((L = a.config) == null ? void 0 : L.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((
|
|
4191
|
+
return a.config.app === "konnect" ? _ = _.replace(/{controlPlaneId}/gi, ((L = a.config) == null ? void 0 : L.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((P = a.config) == null ? void 0 : P.consumerGroupId) || "") : a.config.app === "kongManager" && (_ = _.replace(/\/{workspace}/gi, (G = a.config) != null && G.workspace ? `/${a.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((Q = a.config) == null ? void 0 : Q.consumerGroupId) || "")), _;
|
|
4156
4192
|
}), b = async (_) => {
|
|
4157
4193
|
const L = {
|
|
4158
4194
|
consumer: _
|
|
4159
4195
|
};
|
|
4160
4196
|
try {
|
|
4161
|
-
const
|
|
4162
|
-
return
|
|
4163
|
-
} catch (
|
|
4164
|
-
let G = `${C(_)} - ${
|
|
4165
|
-
return
|
|
4197
|
+
const P = await o.post(q.value, L);
|
|
4198
|
+
return S.value.push(_), P;
|
|
4199
|
+
} catch (P) {
|
|
4200
|
+
let G = `${C(_)} - ${P.message}`;
|
|
4201
|
+
return P.response.status === 409 && (G = `${C(_)} - ${t("consumers.errors.already_added")}`), Promise.reject(Error(G));
|
|
4166
4202
|
}
|
|
4167
|
-
}, I =
|
|
4203
|
+
}, I = E([]), N = (_) => {
|
|
4168
4204
|
I.value = _.map((L) => {
|
|
4169
|
-
var
|
|
4170
|
-
return (
|
|
4205
|
+
var P;
|
|
4206
|
+
return (P = L.reason) == null ? void 0 : P.message;
|
|
4171
4207
|
}).filter(Boolean);
|
|
4172
4208
|
};
|
|
4173
|
-
return ve(
|
|
4209
|
+
return ve(y, () => {
|
|
4174
4210
|
v.value++;
|
|
4175
4211
|
}, { immediate: !0, deep: !0 }), ve(() => a.visible, () => {
|
|
4176
4212
|
a.visible && c();
|
|
4177
4213
|
}, { immediate: !0 }), (_, L) => {
|
|
4178
|
-
const
|
|
4179
|
-
return
|
|
4180
|
-
"action-pending":
|
|
4214
|
+
const P = D("KMultiselect"), G = D("KAlert"), Q = D("KPrompt");
|
|
4215
|
+
return f(), R(Q, {
|
|
4216
|
+
"action-pending": F.value,
|
|
4181
4217
|
class: "kong-ui-entities-add-consumers-modal",
|
|
4182
4218
|
"data-testid": "add-consumer-modal",
|
|
4183
4219
|
"is-visible": e.visible,
|
|
4184
4220
|
title: m(t)("consumers.consumer_groups.add.title"),
|
|
4185
|
-
onCanceled:
|
|
4186
|
-
onProceed:
|
|
4221
|
+
onCanceled: U,
|
|
4222
|
+
onProceed: K
|
|
4187
4223
|
}, {
|
|
4188
|
-
"body-content":
|
|
4189
|
-
B("div",
|
|
4190
|
-
B("p",
|
|
4191
|
-
|
|
4224
|
+
"body-content": g(() => [
|
|
4225
|
+
B("div", ms, [
|
|
4226
|
+
B("p", gs, j(m(t)("consumers.consumer_groups.add.ctaText")), 1),
|
|
4227
|
+
O(P, {
|
|
4192
4228
|
modelValue: i.value,
|
|
4193
4229
|
"onUpdate:modelValue": L[0] || (L[0] = (J) => i.value = J),
|
|
4194
4230
|
autosuggest: "",
|
|
4195
4231
|
"data-testid": "add-consumers-multiselect",
|
|
4196
|
-
"dropdown-footer-text":
|
|
4197
|
-
items:
|
|
4232
|
+
"dropdown-footer-text": A.value ? m(t)("consumers.consumer_groups.add.footer") : void 0,
|
|
4233
|
+
items: y.value,
|
|
4198
4234
|
label: m(t)("consumers.consumer_groups.add.consumers_label"),
|
|
4199
|
-
loading: m(
|
|
4235
|
+
loading: m(s),
|
|
4200
4236
|
placeholder: m(t)("consumers.consumer_groups.add.consumer_placeholder"),
|
|
4201
|
-
readonly:
|
|
4237
|
+
readonly: F.value,
|
|
4202
4238
|
required: "",
|
|
4203
4239
|
width: "100%",
|
|
4204
|
-
onQueryChange: m(
|
|
4240
|
+
onQueryChange: m(l)
|
|
4205
4241
|
}, {
|
|
4206
|
-
"item-template":
|
|
4207
|
-
B("div",
|
|
4208
|
-
|
|
4242
|
+
"item-template": g(({ item: J }) => [
|
|
4243
|
+
B("div", ys, j(J.label), 1),
|
|
4244
|
+
d(J).data.username && d(J).data.custom_id ? (f(), T("div", hs, j(d(J).data.custom_id), 1)) : H("", !0)
|
|
4209
4245
|
]),
|
|
4210
4246
|
_: 1
|
|
4211
4247
|
}, 8, ["modelValue", "dropdown-footer-text", "items", "label", "loading", "placeholder", "readonly", "onQueryChange"]),
|
|
4212
|
-
k.value || w.value || I.value.length ? (
|
|
4213
|
-
|
|
4214
|
-
alertMessage:
|
|
4215
|
-
B("p", null,
|
|
4216
|
-
I.value.length ? (
|
|
4217
|
-
(
|
|
4248
|
+
k.value || w.value || I.value.length ? (f(), T("div", vs, [
|
|
4249
|
+
O(G, { appearance: "danger" }, {
|
|
4250
|
+
alertMessage: g(() => [
|
|
4251
|
+
B("p", null, j(m(t)("consumers.errors.add")), 1),
|
|
4252
|
+
I.value.length ? (f(), T("ul", bs, [
|
|
4253
|
+
(f(!0), T(me, null, pe(I.value, (J, X) => (f(), T("li", { key: X }, j(J), 1))), 128))
|
|
4218
4254
|
])) : H("", !0),
|
|
4219
|
-
B("div", null,
|
|
4255
|
+
B("div", null, j(k.value || w.value), 1)
|
|
4220
4256
|
]),
|
|
4221
4257
|
_: 1
|
|
4222
4258
|
})
|
|
@@ -4232,7 +4268,7 @@ const rs = {
|
|
|
4232
4268
|
for (const [a, r] of n)
|
|
4233
4269
|
t[a] = r;
|
|
4234
4270
|
return t;
|
|
4235
|
-
},
|
|
4271
|
+
}, ks = /* @__PURE__ */ Tt(Cs, [["__scopeId", "data-v-68cc6403"]]), ws = { class: "kong-ui-entities-consumers-list" }, Is = { key: 1 }, _s = /* @__PURE__ */ ne({
|
|
4236
4272
|
__name: "ConsumerList",
|
|
4237
4273
|
props: {
|
|
4238
4274
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4278,20 +4314,20 @@ const rs = {
|
|
|
4278
4314
|
},
|
|
4279
4315
|
emits: ["error", "copy:success", "copy:error", "delete:success", "add:success", "remove:success"],
|
|
4280
4316
|
setup(e, { emit: n }) {
|
|
4281
|
-
var
|
|
4282
|
-
const t = n, a = e, { i18nT: r, i18n: { t: o } } = Qe.useI18n(), i = yt(), { axiosInstance:
|
|
4283
|
-
headers: (
|
|
4284
|
-
}),
|
|
4317
|
+
var Nt;
|
|
4318
|
+
const t = n, a = e, { i18nT: r, i18n: { t: o } } = Qe.useI18n(), i = yt(), { axiosInstance: l } = xt({
|
|
4319
|
+
headers: (Nt = a.config) == null ? void 0 : Nt.requestHeaders
|
|
4320
|
+
}), s = E(1), u = $(() => !!a.config.consumerGroupId), p = $(() => a.config.app !== "kongManager" || !!a.config.disableSorting), c = {
|
|
4285
4321
|
username: { label: o("consumers.list.table_headers.username"), searchable: !0, sortable: !0 },
|
|
4286
4322
|
custom_id: { label: o("consumers.list.table_headers.custom_id"), searchable: !0, sortable: !0 },
|
|
4287
4323
|
tags: { label: o("consumers.list.table_headers.tags"), sortable: !1 }
|
|
4288
|
-
}, h = c,
|
|
4324
|
+
}, h = c, d = (x) => ({
|
|
4289
4325
|
"data-testid": x.username ?? x.custom_id ?? x.id
|
|
4290
4326
|
}), w = $(() => {
|
|
4291
4327
|
var z, te, ce, ye;
|
|
4292
4328
|
let x = `${a.config.apiBaseUrl}${xe.list[a.config.app][u.value ? "forConsumerGroup" : "all"]}`;
|
|
4293
4329
|
return a.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((z = a.config) == null ? void 0 : z.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((te = a.config) == null ? void 0 : te.consumerGroupId) || "") : a.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (ce = a.config) != null && ce.workspace ? `/${a.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((ye = a.config) == null ? void 0 : ye.consumerGroupId) || "")), x;
|
|
4294
|
-
}), v =
|
|
4330
|
+
}), v = E(""), A = $(() => {
|
|
4295
4331
|
const x = a.config.app === "konnect" || a.config.isExactMatch;
|
|
4296
4332
|
return x ? {
|
|
4297
4333
|
isExactMatch: x,
|
|
@@ -4304,11 +4340,11 @@ const rs = {
|
|
|
4304
4340
|
},
|
|
4305
4341
|
schema: a.config.filterSchema
|
|
4306
4342
|
};
|
|
4307
|
-
}),
|
|
4343
|
+
}), y = $(() => u.value ? "consumers" : void 0), { fetcher: C, fetcherState: U } = ps(a.config, w.value, y.value), S = () => {
|
|
4308
4344
|
v.value = "";
|
|
4309
|
-
},
|
|
4310
|
-
|
|
4311
|
-
}, k = (x) => x ?? "-",
|
|
4345
|
+
}, F = () => {
|
|
4346
|
+
s.value++;
|
|
4347
|
+
}, k = (x) => x ?? "-", K = E(null), q = (x, z) => {
|
|
4312
4348
|
const te = x.id;
|
|
4313
4349
|
if (!z(te)) {
|
|
4314
4350
|
t("copy:error", {
|
|
@@ -4339,68 +4375,68 @@ const rs = {
|
|
|
4339
4375
|
}, I = async (x) => {
|
|
4340
4376
|
var te;
|
|
4341
4377
|
await ((te = a.canRetrieve) == null ? void 0 : te.call(a, x)) && i.push(a.config.getViewRoute(x.id));
|
|
4342
|
-
},
|
|
4378
|
+
}, N = (x) => ({
|
|
4343
4379
|
label: o("consumers.actions.view"),
|
|
4344
4380
|
to: a.config.getViewRoute(x)
|
|
4345
|
-
}),
|
|
4381
|
+
}), V = (x) => ({
|
|
4346
4382
|
label: o("consumers.actions.edit"),
|
|
4347
4383
|
to: a.config.getEditRoute(x)
|
|
4348
|
-
}), _ =
|
|
4384
|
+
}), _ = E(void 0), L = E(!1), P = E(!1), G = E(""), Q = cs(a.config, w.value), J = (x) => {
|
|
4349
4385
|
_.value = x, L.value = !0;
|
|
4350
4386
|
}, X = () => {
|
|
4351
4387
|
L.value = !1;
|
|
4352
4388
|
}, ue = async () => {
|
|
4353
4389
|
var x, z, te;
|
|
4354
4390
|
if ((x = _.value) != null && x.id) {
|
|
4355
|
-
|
|
4391
|
+
P.value = !0;
|
|
4356
4392
|
try {
|
|
4357
|
-
await
|
|
4393
|
+
await l.delete(Q(_.value.id)), P.value = !1, L.value = !1, s.value++, t("delete:success", _.value);
|
|
4358
4394
|
} catch (ce) {
|
|
4359
4395
|
G.value = ((te = (z = ce.response) == null ? void 0 : z.data) == null ? void 0 : te.message) || ce.message || o("consumers.errors.delete"), t("error", ce);
|
|
4360
4396
|
} finally {
|
|
4361
|
-
|
|
4397
|
+
P.value = !1;
|
|
4362
4398
|
}
|
|
4363
4399
|
}
|
|
4364
|
-
}, et =
|
|
4400
|
+
}, et = E(!1), $t = () => {
|
|
4365
4401
|
et.value = !0;
|
|
4366
|
-
},
|
|
4402
|
+
}, jt = () => {
|
|
4367
4403
|
et.value = !1;
|
|
4368
|
-
},
|
|
4369
|
-
z ||
|
|
4370
|
-
},
|
|
4404
|
+
}, Mt = (x, z) => {
|
|
4405
|
+
z || jt(), s.value++, t("add:success", x);
|
|
4406
|
+
}, ua = () => {
|
|
4371
4407
|
u.value && $t();
|
|
4372
|
-
}, be =
|
|
4408
|
+
}, be = E(void 0), tt = E(!1), ca = E(""), da = (x) => {
|
|
4373
4409
|
be.value = x, tt.value = !0;
|
|
4374
4410
|
}, Ot = () => {
|
|
4375
4411
|
tt.value = !1, be.value = void 0;
|
|
4376
|
-
},
|
|
4412
|
+
}, pa = $(() => {
|
|
4377
4413
|
var z, te, ce, ye;
|
|
4378
4414
|
let x = `${a.config.apiBaseUrl}${xe.list[a.config.app].oneForConsumerGroup}`;
|
|
4379
4415
|
return a.config.app === "konnect" ? x = x.replace(/{controlPlaneId}/gi, ((z = a.config) == null ? void 0 : z.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((te = a.config) == null ? void 0 : te.consumerGroupId) || "") : a.config.app === "kongManager" && (x = x.replace(/\/{workspace}/gi, (ce = a.config) != null && ce.workspace ? `/${a.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((ye = a.config) == null ? void 0 : ye.consumerGroupId) || "")), x;
|
|
4380
|
-
}), Et =
|
|
4416
|
+
}), Et = E(!1), fa = async () => {
|
|
4381
4417
|
if (be.value) {
|
|
4382
4418
|
Et.value = !0;
|
|
4383
4419
|
try {
|
|
4384
|
-
const x =
|
|
4385
|
-
await
|
|
4420
|
+
const x = pa.value.replace(/{consumerId}/gi, be.value.id);
|
|
4421
|
+
await l.delete(x), t("remove:success", be.value), Ot(), s.value++;
|
|
4386
4422
|
} catch (x) {
|
|
4387
|
-
|
|
4423
|
+
ca.value = x.message || o("consumers.errors.delete"), t("error", x);
|
|
4388
4424
|
} finally {
|
|
4389
4425
|
Et.value = !1;
|
|
4390
4426
|
}
|
|
4391
4427
|
}
|
|
4392
|
-
},
|
|
4393
|
-
ve(
|
|
4428
|
+
}, Ft = E(!0);
|
|
4429
|
+
ve(U, (x) => {
|
|
4394
4430
|
var z, te, ce, ye;
|
|
4395
|
-
if (Array.isArray((z = x == null ? void 0 : x.response) == null ? void 0 : z.data) && (
|
|
4396
|
-
|
|
4431
|
+
if (Array.isArray((z = x == null ? void 0 : x.response) == null ? void 0 : z.data) && (Ft.value = x.response.data.length > 0), x.status === Se.Error) {
|
|
4432
|
+
K.value = {
|
|
4397
4433
|
title: o("consumers.errors.general")
|
|
4398
|
-
}, (ye = (ce = (te = x.error) == null ? void 0 : te.response) == null ? void 0 : ce.data) != null && ye.message && (
|
|
4434
|
+
}, (ye = (ce = (te = x.error) == null ? void 0 : te.response) == null ? void 0 : ce.data) != null && ye.message && (K.value.message = x.error.response.data.message), t("error", x.error);
|
|
4399
4435
|
return;
|
|
4400
4436
|
}
|
|
4401
|
-
|
|
4437
|
+
K.value = null;
|
|
4402
4438
|
});
|
|
4403
|
-
const nt =
|
|
4439
|
+
const nt = E({
|
|
4404
4440
|
ctaPath: u.value ? void 0 : a.config.createRoute,
|
|
4405
4441
|
ctaText: void 0,
|
|
4406
4442
|
message: o("consumers.list.empty_state.description"),
|
|
@@ -4409,152 +4445,152 @@ const rs = {
|
|
|
4409
4445
|
return gt(async () => {
|
|
4410
4446
|
await a.canCreate() && (nt.value.title = u.value ? o("consumers.list.empty_state.title_for_consumer_group") : o("consumers.list.empty_state.title"), nt.value.ctaText = u.value ? o("consumers.actions.add_consumer") : o("consumers.actions.create"));
|
|
4411
4447
|
}), (x, z) => {
|
|
4412
|
-
const te =
|
|
4413
|
-
return
|
|
4414
|
-
|
|
4448
|
+
const te = D("KButton"), ce = D("KBadge"), ye = D("KTruncate"), Ke = D("KDropdownItem"), Kt = D("KClipboardProvider"), ma = D("KPrompt");
|
|
4449
|
+
return f(), T("div", ws, [
|
|
4450
|
+
O(m(Bl), {
|
|
4415
4451
|
"cache-identifier": e.cacheIdentifier,
|
|
4416
4452
|
"disable-pagination": u.value,
|
|
4417
4453
|
"disable-pagination-page-jump": "",
|
|
4418
|
-
"disable-sorting":
|
|
4454
|
+
"disable-sorting": p.value,
|
|
4419
4455
|
"empty-state-options": nt.value,
|
|
4420
4456
|
"enable-entity-actions": "",
|
|
4421
|
-
"error-message":
|
|
4457
|
+
"error-message": K.value,
|
|
4422
4458
|
fetcher: m(C),
|
|
4423
|
-
"fetcher-cache-key":
|
|
4459
|
+
"fetcher-cache-key": s.value,
|
|
4424
4460
|
"pagination-type": "offset",
|
|
4425
4461
|
"preferences-storage-key": "kong-ui-entities-consumers-list",
|
|
4426
4462
|
query: v.value,
|
|
4427
|
-
"row-attributes":
|
|
4463
|
+
"row-attributes": d,
|
|
4428
4464
|
"table-headers": m(h),
|
|
4429
4465
|
"use-action-outside": e.useActionOutside,
|
|
4430
|
-
onClearSearchInput:
|
|
4466
|
+
onClearSearchInput: S,
|
|
4431
4467
|
"onClick:row": z[3] || (z[3] = (Y) => I(Y)),
|
|
4432
|
-
onEmptyStateCtaClicked:
|
|
4433
|
-
onSort:
|
|
4468
|
+
onEmptyStateCtaClicked: ua,
|
|
4469
|
+
onSort: F
|
|
4434
4470
|
}, {
|
|
4435
|
-
"toolbar-filter":
|
|
4436
|
-
u.value ? H("", !0) : (
|
|
4471
|
+
"toolbar-filter": g(() => [
|
|
4472
|
+
u.value ? H("", !0) : (f(), R(m(ns), {
|
|
4437
4473
|
key: 0,
|
|
4438
4474
|
modelValue: v.value,
|
|
4439
4475
|
"onUpdate:modelValue": z[0] || (z[0] = (Y) => v.value = Y),
|
|
4440
|
-
config:
|
|
4476
|
+
config: A.value
|
|
4441
4477
|
}, null, 8, ["modelValue", "config"]))
|
|
4442
4478
|
]),
|
|
4443
|
-
"toolbar-button":
|
|
4444
|
-
(
|
|
4479
|
+
"toolbar-button": g(() => [
|
|
4480
|
+
(f(), R(ka, {
|
|
4445
4481
|
disabled: !e.useActionOutside,
|
|
4446
4482
|
to: "#kong-ui-app-page-header-action-button"
|
|
4447
4483
|
}, [
|
|
4448
|
-
|
|
4484
|
+
O(m(Re), {
|
|
4449
4485
|
"auth-function": () => e.canCreate()
|
|
4450
4486
|
}, {
|
|
4451
|
-
default:
|
|
4452
|
-
|
|
4487
|
+
default: g(() => [
|
|
4488
|
+
Be(O(te, {
|
|
4453
4489
|
appearance: "primary",
|
|
4454
4490
|
"data-testid": "toolbar-add-consumer",
|
|
4455
4491
|
icon: "plus",
|
|
4456
4492
|
to: e.config.consumerGroupId ? void 0 : e.config.createRoute,
|
|
4457
4493
|
onClick: z[1] || (z[1] = () => e.config.consumerGroupId ? $t() : void 0)
|
|
4458
4494
|
}, {
|
|
4459
|
-
default:
|
|
4460
|
-
|
|
4495
|
+
default: g(() => [
|
|
4496
|
+
W(j(e.config.consumerGroupId ? m(o)("consumers.actions.add_consumer") : m(o)("consumers.list.toolbar_actions.new_consumer")), 1)
|
|
4461
4497
|
]),
|
|
4462
4498
|
_: 1
|
|
4463
4499
|
}, 8, ["to"]), [
|
|
4464
|
-
[Le,
|
|
4500
|
+
[Le, Ft.value]
|
|
4465
4501
|
])
|
|
4466
4502
|
]),
|
|
4467
4503
|
_: 1
|
|
4468
4504
|
}, 8, ["auth-function"])
|
|
4469
4505
|
], 8, ["disabled"]))
|
|
4470
4506
|
]),
|
|
4471
|
-
username:
|
|
4472
|
-
B("b", null,
|
|
4507
|
+
username: g(({ rowValue: Y }) => [
|
|
4508
|
+
B("b", null, j(k(Y)), 1)
|
|
4473
4509
|
]),
|
|
4474
|
-
custom_id:
|
|
4475
|
-
|
|
4510
|
+
custom_id: g(({ rowValue: Y }) => [
|
|
4511
|
+
W(j(k(Y)), 1)
|
|
4476
4512
|
]),
|
|
4477
|
-
tags:
|
|
4478
|
-
Y && Y.length > 0 ? (
|
|
4479
|
-
default:
|
|
4480
|
-
(
|
|
4513
|
+
tags: g(({ rowValue: Y }) => [
|
|
4514
|
+
Y && Y.length > 0 ? (f(), R(ye, { key: 0 }, {
|
|
4515
|
+
default: g(() => [
|
|
4516
|
+
(f(!0), T(me, null, pe(Y, (Te) => (f(), R(ce, {
|
|
4481
4517
|
key: Te,
|
|
4482
4518
|
onClick: z[2] || (z[2] = Ge(() => {
|
|
4483
4519
|
}, ["stop"]))
|
|
4484
4520
|
}, {
|
|
4485
|
-
default:
|
|
4486
|
-
|
|
4521
|
+
default: g(() => [
|
|
4522
|
+
W(j(Te), 1)
|
|
4487
4523
|
]),
|
|
4488
4524
|
_: 2
|
|
4489
4525
|
}, 1024))), 128))
|
|
4490
4526
|
]),
|
|
4491
4527
|
_: 2
|
|
4492
|
-
}, 1024)) : (
|
|
4528
|
+
}, 1024)) : (f(), T("span", Is, "-"))
|
|
4493
4529
|
]),
|
|
4494
|
-
actions:
|
|
4495
|
-
|
|
4496
|
-
default:
|
|
4497
|
-
|
|
4530
|
+
actions: g(({ row: Y }) => [
|
|
4531
|
+
O(Kt, null, {
|
|
4532
|
+
default: g(({ copyToClipboard: Te }) => [
|
|
4533
|
+
O(Ke, {
|
|
4498
4534
|
"data-testid": "action-entity-copy-id",
|
|
4499
|
-
onClick: (
|
|
4535
|
+
onClick: (ga) => q(Y, Te)
|
|
4500
4536
|
}, {
|
|
4501
|
-
default:
|
|
4502
|
-
|
|
4537
|
+
default: g(() => [
|
|
4538
|
+
W(j(m(o)("consumers.actions.copy_id")), 1)
|
|
4503
4539
|
]),
|
|
4504
4540
|
_: 2
|
|
4505
4541
|
}, 1032, ["onClick"])
|
|
4506
4542
|
]),
|
|
4507
4543
|
_: 2
|
|
4508
4544
|
}, 1024),
|
|
4509
|
-
|
|
4510
|
-
default:
|
|
4511
|
-
|
|
4545
|
+
O(Kt, null, {
|
|
4546
|
+
default: g(({ copyToClipboard: Te }) => [
|
|
4547
|
+
O(Ke, {
|
|
4512
4548
|
"data-testid": "action-entity-copy-json",
|
|
4513
|
-
onClick: (
|
|
4549
|
+
onClick: (ga) => b(Y, Te)
|
|
4514
4550
|
}, {
|
|
4515
|
-
default:
|
|
4516
|
-
|
|
4551
|
+
default: g(() => [
|
|
4552
|
+
W(j(m(o)("consumers.actions.copy_json")), 1)
|
|
4517
4553
|
]),
|
|
4518
4554
|
_: 2
|
|
4519
4555
|
}, 1032, ["onClick"])
|
|
4520
4556
|
]),
|
|
4521
4557
|
_: 2
|
|
4522
4558
|
}, 1024),
|
|
4523
|
-
|
|
4559
|
+
O(m(Re), {
|
|
4524
4560
|
"auth-function": () => e.canRetrieve(Y)
|
|
4525
4561
|
}, {
|
|
4526
|
-
default:
|
|
4527
|
-
|
|
4562
|
+
default: g(() => [
|
|
4563
|
+
O(Ke, {
|
|
4528
4564
|
"data-testid": "action-entity-view",
|
|
4529
4565
|
"has-divider": "",
|
|
4530
|
-
item:
|
|
4566
|
+
item: N(Y.id)
|
|
4531
4567
|
}, null, 8, ["item"])
|
|
4532
4568
|
]),
|
|
4533
4569
|
_: 2
|
|
4534
4570
|
}, 1032, ["auth-function"]),
|
|
4535
|
-
|
|
4571
|
+
O(m(Re), {
|
|
4536
4572
|
"auth-function": () => e.canEdit(Y)
|
|
4537
4573
|
}, {
|
|
4538
|
-
default:
|
|
4539
|
-
|
|
4574
|
+
default: g(() => [
|
|
4575
|
+
O(Ke, {
|
|
4540
4576
|
"data-testid": "action-entity-edit",
|
|
4541
|
-
item:
|
|
4577
|
+
item: V(Y.id)
|
|
4542
4578
|
}, null, 8, ["item"])
|
|
4543
4579
|
]),
|
|
4544
4580
|
_: 2
|
|
4545
4581
|
}, 1032, ["auth-function"]),
|
|
4546
|
-
|
|
4582
|
+
O(m(Re), {
|
|
4547
4583
|
"auth-function": () => e.canDelete(Y)
|
|
4548
4584
|
}, {
|
|
4549
|
-
default:
|
|
4550
|
-
|
|
4585
|
+
default: g(() => [
|
|
4586
|
+
O(Ke, {
|
|
4551
4587
|
danger: "",
|
|
4552
4588
|
"data-testid": "action-entity-delete",
|
|
4553
4589
|
"has-divider": "",
|
|
4554
|
-
onClick: () => e.config.consumerGroupId ?
|
|
4590
|
+
onClick: () => e.config.consumerGroupId ? da(Y) : J(Y)
|
|
4555
4591
|
}, {
|
|
4556
|
-
default:
|
|
4557
|
-
|
|
4592
|
+
default: g(() => [
|
|
4593
|
+
W(j(e.config.consumerGroupId ? m(o)("consumers.actions.remove") : m(o)("consumers.actions.delete")), 1)
|
|
4558
4594
|
]),
|
|
4559
4595
|
_: 2
|
|
4560
4596
|
}, 1032, ["onClick"])
|
|
@@ -4564,63 +4600,63 @@ const rs = {
|
|
|
4564
4600
|
]),
|
|
4565
4601
|
_: 1
|
|
4566
4602
|
}, 8, ["cache-identifier", "disable-pagination", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers", "use-action-outside"]),
|
|
4567
|
-
|
|
4568
|
-
"action-pending":
|
|
4603
|
+
O(m(Dl), {
|
|
4604
|
+
"action-pending": P.value,
|
|
4569
4605
|
"data-testid": "delete-consumer-modal",
|
|
4570
4606
|
description: m(o)("consumers.delete.description"),
|
|
4571
4607
|
"entity-name": _.value && (_.value.username || _.value.custom_id || _.value.id),
|
|
4572
|
-
"entity-type": m(
|
|
4608
|
+
"entity-type": m(gn).Consumer,
|
|
4573
4609
|
error: G.value,
|
|
4574
4610
|
title: m(o)("consumers.delete.title"),
|
|
4575
4611
|
visible: L.value,
|
|
4576
4612
|
onCancel: X,
|
|
4577
4613
|
onProceed: ue
|
|
4578
4614
|
}, null, 8, ["action-pending", "description", "entity-name", "entity-type", "error", "title", "visible"]),
|
|
4579
|
-
e.config.consumerGroupId ? (
|
|
4615
|
+
e.config.consumerGroupId ? (f(), R(ks, {
|
|
4580
4616
|
key: 0,
|
|
4581
4617
|
config: e.config,
|
|
4582
4618
|
"data-testid": "add-consumer-modal",
|
|
4583
4619
|
visible: et.value,
|
|
4584
|
-
"onAdd:partialSuccess": z[4] || (z[4] = (Y) =>
|
|
4585
|
-
"onAdd:success": z[5] || (z[5] = (Y) =>
|
|
4586
|
-
onCancel:
|
|
4620
|
+
"onAdd:partialSuccess": z[4] || (z[4] = (Y) => Mt(Y, !0)),
|
|
4621
|
+
"onAdd:success": z[5] || (z[5] = (Y) => Mt(Y)),
|
|
4622
|
+
onCancel: jt
|
|
4587
4623
|
}, null, 8, ["config", "visible"])) : H("", !0),
|
|
4588
|
-
e.config.consumerGroupId && be.value ? (
|
|
4624
|
+
e.config.consumerGroupId && be.value ? (f(), R(ma, {
|
|
4589
4625
|
key: 1,
|
|
4590
4626
|
"data-testid": "remove-consumer-modal",
|
|
4591
4627
|
"is-visible": tt.value,
|
|
4592
4628
|
title: m(o)("consumers.consumer_groups.remove.title"),
|
|
4593
4629
|
type: "danger",
|
|
4594
4630
|
onCanceled: Ot,
|
|
4595
|
-
onProceed:
|
|
4631
|
+
onProceed: fa
|
|
4596
4632
|
}, {
|
|
4597
|
-
"body-content":
|
|
4598
|
-
|
|
4633
|
+
"body-content": g(() => [
|
|
4634
|
+
O(m(r), {
|
|
4599
4635
|
class: "message",
|
|
4600
4636
|
keypath: e.config.consumerGroupName ? "consumers.consumer_groups.remove.confirmation" : "consumers.consumer_groups.remove.confirmationNoCG",
|
|
4601
4637
|
tag: "p"
|
|
4602
4638
|
}, ke({
|
|
4603
|
-
consumer:
|
|
4604
|
-
B("strong", null,
|
|
4639
|
+
consumer: g(() => [
|
|
4640
|
+
B("strong", null, j(be.value.username || be.value.custom_id || be.value.id), 1)
|
|
4605
4641
|
]),
|
|
4606
4642
|
_: 2
|
|
4607
4643
|
}, [
|
|
4608
4644
|
e.config.consumerGroupName ? {
|
|
4609
4645
|
name: "consumerGroup",
|
|
4610
|
-
fn:
|
|
4611
|
-
B("strong", null,
|
|
4646
|
+
fn: g(() => [
|
|
4647
|
+
B("strong", null, j(e.config.consumerGroupName), 1)
|
|
4612
4648
|
]),
|
|
4613
4649
|
key: "0"
|
|
4614
4650
|
} : void 0
|
|
4615
4651
|
]), 1032, ["keypath"]),
|
|
4616
|
-
B("p", null,
|
|
4652
|
+
B("p", null, j(m(o)("consumers.consumer_groups.remove.description")), 1)
|
|
4617
4653
|
]),
|
|
4618
4654
|
_: 1
|
|
4619
4655
|
}, 8, ["is-visible", "title"])) : H("", !0)
|
|
4620
4656
|
]);
|
|
4621
4657
|
};
|
|
4622
4658
|
}
|
|
4623
|
-
}),
|
|
4659
|
+
}), Ps = /* @__PURE__ */ Tt(_s, [["__scopeId", "data-v-38535d5a"]]), Ss = { class: "kong-ui-entities-consumer-form" }, As = { class: "fields-group-title" }, xs = { class: "fields-group-text" }, Ts = /* @__PURE__ */ ne({
|
|
4624
4660
|
__name: "ConsumerForm",
|
|
4625
4661
|
props: {
|
|
4626
4662
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4638,10 +4674,10 @@ const rs = {
|
|
|
4638
4674
|
},
|
|
4639
4675
|
emits: ["update", "error", "loading"],
|
|
4640
4676
|
setup(e, { emit: n }) {
|
|
4641
|
-
var
|
|
4642
|
-
const t = e, a = n, { i18nT: r, i18n: { t: o } } = Qe.useI18n(), i = yt(), { axiosInstance:
|
|
4643
|
-
headers: (
|
|
4644
|
-
}), { getMessageFromError:
|
|
4677
|
+
var F;
|
|
4678
|
+
const t = e, a = n, { i18nT: r, i18n: { t: o } } = Qe.useI18n(), i = yt(), { axiosInstance: l } = xt({
|
|
4679
|
+
headers: (F = t.config) == null ? void 0 : F.requestHeaders
|
|
4680
|
+
}), { getMessageFromError: s } = ds(), u = qt({
|
|
4645
4681
|
fields: {
|
|
4646
4682
|
username: "",
|
|
4647
4683
|
customId: "",
|
|
@@ -4649,79 +4685,79 @@ const rs = {
|
|
|
4649
4685
|
},
|
|
4650
4686
|
readonly: !1,
|
|
4651
4687
|
errorMessage: ""
|
|
4652
|
-
}),
|
|
4688
|
+
}), p = qt({
|
|
4653
4689
|
username: "",
|
|
4654
4690
|
customId: "",
|
|
4655
4691
|
tags: ""
|
|
4656
4692
|
}), c = $(() => {
|
|
4657
|
-
var k,
|
|
4658
|
-
return (
|
|
4693
|
+
var k, K;
|
|
4694
|
+
return (K = xe.form[(k = t.config) == null ? void 0 : k.app]) == null ? void 0 : K.edit;
|
|
4659
4695
|
}), h = () => {
|
|
4660
4696
|
var k;
|
|
4661
4697
|
i.push(((k = t.config) == null ? void 0 : k.cancelRoute) || { name: "consumer-list" });
|
|
4662
|
-
},
|
|
4698
|
+
}, d = (k) => {
|
|
4663
4699
|
a("loading", k);
|
|
4664
4700
|
}, w = (k) => {
|
|
4665
4701
|
a("error", k);
|
|
4666
4702
|
}, v = (k) => {
|
|
4667
|
-
var
|
|
4668
|
-
u.fields.username = ((
|
|
4669
|
-
const
|
|
4670
|
-
u.fields.tags = (
|
|
4671
|
-
},
|
|
4672
|
-
var
|
|
4673
|
-
let
|
|
4674
|
-
return ((I = t.config) == null ? void 0 : I.app) === "konnect" ?
|
|
4675
|
-
}, C = $(() => !!u.fields.username || !!u.fields.customId),
|
|
4676
|
-
var k,
|
|
4703
|
+
var q, b, I;
|
|
4704
|
+
u.fields.username = ((q = k == null ? void 0 : k.item) == null ? void 0 : q.username) || (k == null ? void 0 : k.username) || "", u.fields.customId = ((b = k == null ? void 0 : k.item) == null ? void 0 : b.custom_id) || (k == null ? void 0 : k.custom_id) || "";
|
|
4705
|
+
const K = ((I = k == null ? void 0 : k.item) == null ? void 0 : I.tags) || (k == null ? void 0 : k.tags) || [];
|
|
4706
|
+
u.fields.tags = (K == null ? void 0 : K.join(", ")) || "", Object.assign(p, u.fields);
|
|
4707
|
+
}, A = $(() => t.consumerId ? ut.Edit : ut.Create), y = (k) => {
|
|
4708
|
+
var q, b, I, N, V, _;
|
|
4709
|
+
let K = `${(q = t.config) == null ? void 0 : q.apiBaseUrl}${xe.form[(b = t.config) == null ? void 0 : b.app][k]}`;
|
|
4710
|
+
return ((I = t.config) == null ? void 0 : I.app) === "konnect" ? K = K.replace(/{controlPlaneId}/gi, ((N = t.config) == null ? void 0 : N.controlPlaneId) || "") : ((V = t.config) == null ? void 0 : V.app) === "kongManager" && (K = K.replace(/\/{workspace}/gi, (_ = t.config) != null && _.workspace ? `/${t.config.workspace}` : "")), K = K.replace(/{id}/gi, t.consumerId), K;
|
|
4711
|
+
}, C = $(() => !!u.fields.username || !!u.fields.customId), U = $(() => JSON.stringify(u.fields) !== JSON.stringify(p)), S = async () => {
|
|
4712
|
+
var k, K, q;
|
|
4677
4713
|
try {
|
|
4678
4714
|
u.readonly = !0;
|
|
4679
4715
|
const b = {
|
|
4680
4716
|
username: u.fields.username || null,
|
|
4681
4717
|
custom_id: u.fields.customId || null,
|
|
4682
|
-
tags: (
|
|
4718
|
+
tags: (K = (k = u.fields.tags.split(",")) == null ? void 0 : k.map((N) => String(N || "").trim())) == null ? void 0 : K.filter((N) => N !== "")
|
|
4683
4719
|
};
|
|
4684
4720
|
let I;
|
|
4685
|
-
await
|
|
4721
|
+
await l.post(y("validate"), b), A.value === "create" ? I = await l.post(y("create"), b) : A.value === "edit" && (I = ((q = t.config) == null ? void 0 : q.app) === "konnect" ? await l.put(y("edit"), b) : await l.patch(y("edit"), b)), v(I == null ? void 0 : I.data), a("update", I == null ? void 0 : I.data);
|
|
4686
4722
|
} catch (b) {
|
|
4687
|
-
u.errorMessage =
|
|
4723
|
+
u.errorMessage = s(b), a("error", b);
|
|
4688
4724
|
} finally {
|
|
4689
4725
|
u.readonly = !1;
|
|
4690
4726
|
}
|
|
4691
4727
|
};
|
|
4692
|
-
return (k,
|
|
4693
|
-
const
|
|
4694
|
-
return
|
|
4695
|
-
|
|
4696
|
-
"can-submit": C.value &&
|
|
4728
|
+
return (k, K) => {
|
|
4729
|
+
const q = D("KInput"), b = D("KCard");
|
|
4730
|
+
return f(), T("div", Ss, [
|
|
4731
|
+
O(m(jl), {
|
|
4732
|
+
"can-submit": C.value && U.value,
|
|
4697
4733
|
config: e.config,
|
|
4698
4734
|
"edit-id": e.consumerId,
|
|
4699
4735
|
"error-message": u.errorMessage,
|
|
4700
4736
|
"fetch-url": c.value,
|
|
4701
4737
|
"is-readonly": u.readonly,
|
|
4702
4738
|
onCancel: h,
|
|
4703
|
-
"onFetch:error":
|
|
4739
|
+
"onFetch:error": K[3] || (K[3] = (I) => w(I)),
|
|
4704
4740
|
"onFetch:success": v,
|
|
4705
|
-
onLoading:
|
|
4706
|
-
onSubmit:
|
|
4741
|
+
onLoading: K[4] || (K[4] = (I) => d(I)),
|
|
4742
|
+
onSubmit: S
|
|
4707
4743
|
}, {
|
|
4708
|
-
default:
|
|
4744
|
+
default: g(() => [
|
|
4709
4745
|
B("div", null, [
|
|
4710
|
-
|
|
4746
|
+
O(m(us), {
|
|
4711
4747
|
description: m(o)("consumers.form.info.description"),
|
|
4712
4748
|
"has-divider": "",
|
|
4713
4749
|
title: m(o)("consumers.form.info.title")
|
|
4714
4750
|
}, {
|
|
4715
|
-
default:
|
|
4751
|
+
default: g(() => [
|
|
4716
4752
|
B("div", null, [
|
|
4717
|
-
B("h5",
|
|
4718
|
-
B("p",
|
|
4753
|
+
B("h5", As, j(m(o)("consumers.form.consumer_identification.title")) + "* ", 1),
|
|
4754
|
+
B("p", xs, j(m(o)("consumers.form.consumer_identification.description")), 1)
|
|
4719
4755
|
]),
|
|
4720
|
-
|
|
4721
|
-
default:
|
|
4722
|
-
|
|
4756
|
+
O(b, null, {
|
|
4757
|
+
default: g(() => [
|
|
4758
|
+
O(q, {
|
|
4723
4759
|
modelValue: u.fields.username,
|
|
4724
|
-
"onUpdate:modelValue":
|
|
4760
|
+
"onUpdate:modelValue": K[0] || (K[0] = (I) => u.fields.username = I),
|
|
4725
4761
|
modelModifiers: { trim: !0 },
|
|
4726
4762
|
autocomplete: "off",
|
|
4727
4763
|
class: "username-field",
|
|
@@ -4734,22 +4770,22 @@ const rs = {
|
|
|
4734
4770
|
readonly: u.readonly,
|
|
4735
4771
|
type: "text"
|
|
4736
4772
|
}, {
|
|
4737
|
-
"label-tooltip":
|
|
4738
|
-
|
|
4773
|
+
"label-tooltip": g(() => [
|
|
4774
|
+
O(m(r), {
|
|
4739
4775
|
keypath: "consumers.fields.username.tooltip",
|
|
4740
4776
|
scope: "global"
|
|
4741
4777
|
}, {
|
|
4742
|
-
custom_id:
|
|
4743
|
-
B("code", null,
|
|
4778
|
+
custom_id: g(() => [
|
|
4779
|
+
B("code", null, j(m(o)("consumers.fields.username.custom_id")), 1)
|
|
4744
4780
|
]),
|
|
4745
4781
|
_: 1
|
|
4746
4782
|
})
|
|
4747
4783
|
]),
|
|
4748
4784
|
_: 1
|
|
4749
4785
|
}, 8, ["modelValue", "label", "placeholder", "readonly"]),
|
|
4750
|
-
|
|
4786
|
+
O(q, {
|
|
4751
4787
|
modelValue: u.fields.customId,
|
|
4752
|
-
"onUpdate:modelValue":
|
|
4788
|
+
"onUpdate:modelValue": K[1] || (K[1] = (I) => u.fields.customId = I),
|
|
4753
4789
|
modelModifiers: { trim: !0 },
|
|
4754
4790
|
autocomplete: "off",
|
|
4755
4791
|
"data-testid": "consumer-form-custom-id",
|
|
@@ -4761,13 +4797,13 @@ const rs = {
|
|
|
4761
4797
|
readonly: u.readonly,
|
|
4762
4798
|
type: "text"
|
|
4763
4799
|
}, {
|
|
4764
|
-
"label-tooltip":
|
|
4765
|
-
|
|
4800
|
+
"label-tooltip": g(() => [
|
|
4801
|
+
O(m(r), {
|
|
4766
4802
|
keypath: "consumers.fields.custom_id.tooltip",
|
|
4767
4803
|
scope: "global"
|
|
4768
4804
|
}, {
|
|
4769
|
-
username:
|
|
4770
|
-
B("code", null,
|
|
4805
|
+
username: g(() => [
|
|
4806
|
+
B("code", null, j(m(o)("consumers.fields.custom_id.username")), 1)
|
|
4771
4807
|
]),
|
|
4772
4808
|
_: 1
|
|
4773
4809
|
})
|
|
@@ -4777,9 +4813,9 @@ const rs = {
|
|
|
4777
4813
|
]),
|
|
4778
4814
|
_: 1
|
|
4779
4815
|
}),
|
|
4780
|
-
|
|
4816
|
+
O(q, {
|
|
4781
4817
|
modelValue: u.fields.tags,
|
|
4782
|
-
"onUpdate:modelValue":
|
|
4818
|
+
"onUpdate:modelValue": K[2] || (K[2] = (I) => u.fields.tags = I),
|
|
4783
4819
|
modelModifiers: { trim: !0 },
|
|
4784
4820
|
autocomplete: "off",
|
|
4785
4821
|
"data-testid": "consumer-form-tags",
|
|
@@ -4803,7 +4839,7 @@ const rs = {
|
|
|
4803
4839
|
]);
|
|
4804
4840
|
};
|
|
4805
4841
|
}
|
|
4806
|
-
}),
|
|
4842
|
+
}), Ds = /* @__PURE__ */ Tt(Ts, [["__scopeId", "data-v-99612940"]]), $s = { class: "kong-ui-consumer-entity-config-card" }, Vs = /* @__PURE__ */ ne({
|
|
4807
4843
|
__name: "ConsumerConfigCard",
|
|
4808
4844
|
props: {
|
|
4809
4845
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4830,7 +4866,7 @@ const rs = {
|
|
|
4830
4866
|
},
|
|
4831
4867
|
emits: ["loading", "fetch:error", "fetch:success", "copy:success"],
|
|
4832
4868
|
setup(e) {
|
|
4833
|
-
const n = e, { i18n: { t }, i18nT: a } = Qe.useI18n(), r = $(() => xe.form[n.config.app].edit), o =
|
|
4869
|
+
const n = e, { i18n: { t }, i18nT: a } = Qe.useI18n(), r = $(() => xe.form[n.config.app].edit), o = E({
|
|
4834
4870
|
id: {},
|
|
4835
4871
|
username: {
|
|
4836
4872
|
section: de.Basic,
|
|
@@ -4855,36 +4891,36 @@ const rs = {
|
|
|
4855
4891
|
hidden: !0
|
|
4856
4892
|
}
|
|
4857
4893
|
});
|
|
4858
|
-
return (i,
|
|
4859
|
-
|
|
4894
|
+
return (i, l) => (f(), T("div", $s, [
|
|
4895
|
+
O(m(xl), {
|
|
4860
4896
|
config: e.config,
|
|
4861
4897
|
"config-card-doc": e.configCardDoc,
|
|
4862
4898
|
"config-schema": o.value,
|
|
4863
4899
|
"fetch-url": r.value,
|
|
4864
4900
|
"hide-title": e.hideTitle,
|
|
4865
|
-
"onCopy:success":
|
|
4866
|
-
"onFetch:error":
|
|
4867
|
-
"onFetch:success":
|
|
4868
|
-
onLoading:
|
|
4901
|
+
"onCopy:success": l[0] || (l[0] = (s) => i.$emit("copy:success", s)),
|
|
4902
|
+
"onFetch:error": l[1] || (l[1] = (s) => i.$emit("fetch:error", s)),
|
|
4903
|
+
"onFetch:success": l[2] || (l[2] = (s) => i.$emit("fetch:success", s)),
|
|
4904
|
+
onLoading: l[3] || (l[3] = (s) => i.$emit("loading", s))
|
|
4869
4905
|
}, {
|
|
4870
|
-
"username-label-tooltip":
|
|
4871
|
-
|
|
4906
|
+
"username-label-tooltip": g(() => [
|
|
4907
|
+
O(m(a), {
|
|
4872
4908
|
keypath: "consumers.fields.username.tooltip",
|
|
4873
4909
|
scope: "global"
|
|
4874
4910
|
}, {
|
|
4875
|
-
custom_id:
|
|
4876
|
-
B("code", null,
|
|
4911
|
+
custom_id: g(() => [
|
|
4912
|
+
B("code", null, j(m(t)("consumers.fields.username.custom_id")), 1)
|
|
4877
4913
|
]),
|
|
4878
4914
|
_: 1
|
|
4879
4915
|
})
|
|
4880
4916
|
]),
|
|
4881
|
-
"custom_id-label-tooltip":
|
|
4882
|
-
|
|
4917
|
+
"custom_id-label-tooltip": g(() => [
|
|
4918
|
+
O(m(a), {
|
|
4883
4919
|
keypath: "consumers.fields.custom_id.tooltip",
|
|
4884
4920
|
scope: "global"
|
|
4885
4921
|
}, {
|
|
4886
|
-
username:
|
|
4887
|
-
B("code", null,
|
|
4922
|
+
username: g(() => [
|
|
4923
|
+
B("code", null, j(m(t)("consumers.fields.custom_id.username")), 1)
|
|
4888
4924
|
]),
|
|
4889
4925
|
_: 1
|
|
4890
4926
|
})
|
|
@@ -4895,7 +4931,7 @@ const rs = {
|
|
|
4895
4931
|
}
|
|
4896
4932
|
});
|
|
4897
4933
|
export {
|
|
4898
|
-
|
|
4899
|
-
|
|
4900
|
-
|
|
4934
|
+
Vs as ConsumerConfigCard,
|
|
4935
|
+
Ds as ConsumerForm,
|
|
4936
|
+
Ps as ConsumerList
|
|
4901
4937
|
};
|