@kong-ui-public/entities-consumer-groups 1.3.1 → 1.3.2-pr.913.4cd42865.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities-consumer-groups.es.js +602 -592
- package/dist/entities-consumer-groups.umd.js +10 -10
- package/dist/style.css +1 -1
- package/package.json +2 -2
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as ae, ref as O, computed as M, watch as xe, renderSlot as Y, createCommentVNode as G, unref as y, useSlots as ut, onBeforeMount as Qe, resolveComponent as U, openBlock as m, createBlock as V, createSlots as Te, withCtx as h, createElementVNode as R, createTextVNode as Z, toDisplayString as F, createVNode as K, createElementBlock as j, renderList as ye, Fragment as ve, normalizeClass as Ke, withModifiers as rt, withDirectives as et, vShow as tt, useCssVars as
|
|
1
|
+
import { defineComponent as ae, ref as O, computed as M, watch as xe, renderSlot as Y, createCommentVNode as G, unref as y, useSlots as ut, onBeforeMount as Qe, resolveComponent as U, openBlock as m, createBlock as V, createSlots as Te, withCtx as h, createElementVNode as R, createTextVNode as Z, toDisplayString as F, createVNode as K, createElementBlock as j, renderList as ye, Fragment as ve, normalizeClass as Ke, withModifiers as rt, withDirectives as et, Teleport as ur, vShow as tt, useCssVars as cr, resolveDynamicComponent as ze, normalizeProps as dr, guardReactiveProps as pr, mergeProps as ht, onMounted as fr, onUnmounted as mr, normalizeStyle as gr, inject as yr, pushScopeId as hr, popScopeId as vr, reactive as Pt } from "vue";
|
|
2
2
|
import { useRouter as wt } from "vue-router";
|
|
3
3
|
import { createI18n as It, i18nTComponent as cn } from "@kong-ui-public/i18n";
|
|
4
|
-
import
|
|
5
|
-
import { MethodsArray as
|
|
6
|
-
const
|
|
4
|
+
import br from "axios";
|
|
5
|
+
import { MethodsArray as Cr } from "@kong/kongponents";
|
|
6
|
+
const kr = {
|
|
7
7
|
list: {
|
|
8
8
|
table_headers: {
|
|
9
9
|
name: "Name",
|
|
@@ -95,11 +95,11 @@ const Cr = {
|
|
|
95
95
|
name: "The name can be any string containing letters, numbers, or the following characters: ., -, _, or ~. Do not use spaces."
|
|
96
96
|
}
|
|
97
97
|
}
|
|
98
|
-
},
|
|
99
|
-
consumer_groups:
|
|
98
|
+
}, _r = {
|
|
99
|
+
consumer_groups: kr
|
|
100
100
|
};
|
|
101
|
-
function
|
|
102
|
-
const e = It("en-us",
|
|
101
|
+
function wr() {
|
|
102
|
+
const e = It("en-us", _r);
|
|
103
103
|
return {
|
|
104
104
|
i18n: e,
|
|
105
105
|
i18nT: cn(e)
|
|
@@ -107,7 +107,7 @@ function _r() {
|
|
|
107
107
|
};
|
|
108
108
|
}
|
|
109
109
|
const ct = {
|
|
110
|
-
useI18n:
|
|
110
|
+
useI18n: wr
|
|
111
111
|
}, Ie = "/api/runtime_groups/{controlPlaneId}", Ae = "/{workspace}", $e = {
|
|
112
112
|
list: {
|
|
113
113
|
konnect: {
|
|
@@ -143,14 +143,14 @@ const ct = {
|
|
|
143
143
|
var dn = /* @__PURE__ */ ((e) => (e.GatewayService = "service", e.Route = "route", e.Consumer = "consumer", e.ConsumerGroup = "consumer group", e.Plugin = "plugin", e.Upstream = "upstream", e.Certificate = "certificate", e.CACertificate = "ca certificate", e.SNI = "SNI", e.Key = "key", e.KeySet = "key set", e.Vault = "vault", e.Application = "application", e.Developer = "developer", e.acls = "ACL Credential", e["basic-auth"] = "Basic Auth Credential", e["key-auth"] = "Key Auth Credential", e["key-auth-enc"] = "Key Auth Encrypted Credential", e.oauth2 = "OAuth 2.0 Credential", e["hmac-auth"] = "HMAC Credential", e.jwt = "JWT Credential", e.Target = "target", e.Policy = "policy", e))(dn || {}), nt = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(nt || {}), Oe = /* @__PURE__ */ ((e) => (e[e.Loading = 0] = "Loading", e[e.Idle = 1] = "Idle", e[e.NoResults = 2] = "NoResults", e[e.Error = 3] = "Error", e))(Oe || {}), te = /* @__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))(te || {}), be = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e))(be || {});
|
|
144
144
|
function At(e = {}) {
|
|
145
145
|
return {
|
|
146
|
-
axiosInstance:
|
|
146
|
+
axiosInstance: br.create({
|
|
147
147
|
withCredentials: !0,
|
|
148
148
|
timeout: 3e4,
|
|
149
149
|
...e
|
|
150
150
|
})
|
|
151
151
|
};
|
|
152
152
|
}
|
|
153
|
-
function
|
|
153
|
+
function Ir() {
|
|
154
154
|
return {
|
|
155
155
|
debounce: (e, n) => {
|
|
156
156
|
let t;
|
|
@@ -162,12 +162,12 @@ function wr() {
|
|
|
162
162
|
}
|
|
163
163
|
};
|
|
164
164
|
}
|
|
165
|
-
const ft = "khcp-user-table-preferences",
|
|
165
|
+
const ft = "khcp-user-table-preferences", Ar = {
|
|
166
166
|
pageSize: 30,
|
|
167
167
|
sortColumnKey: void 0,
|
|
168
168
|
sortColumnOrder: void 0
|
|
169
169
|
};
|
|
170
|
-
function
|
|
170
|
+
function Sr() {
|
|
171
171
|
const e = (t) => {
|
|
172
172
|
if (typeof t == "string")
|
|
173
173
|
try {
|
|
@@ -191,17 +191,17 @@ function Ar() {
|
|
|
191
191
|
},
|
|
192
192
|
getTablePreferences: (t) => {
|
|
193
193
|
const r = n();
|
|
194
|
-
return (r == null ? void 0 : r.get(t)) || void 0 ||
|
|
194
|
+
return (r == null ? void 0 : r.get(t)) || void 0 || Ar;
|
|
195
195
|
},
|
|
196
196
|
deleteAllTablePreferences: () => {
|
|
197
197
|
localStorage.removeItem(ft);
|
|
198
198
|
}
|
|
199
199
|
};
|
|
200
200
|
}
|
|
201
|
-
const
|
|
201
|
+
const xr = {
|
|
202
202
|
message: "Are you sure you want to delete this {entityType}?",
|
|
203
203
|
messageWithName: "Are you sure you want to delete this {entityType} {entityName}?"
|
|
204
|
-
},
|
|
204
|
+
}, Tr = {
|
|
205
205
|
actions: {
|
|
206
206
|
save: "Save",
|
|
207
207
|
cancel: "Cancel",
|
|
@@ -210,13 +210,13 @@ const Sr = {
|
|
|
210
210
|
errors: {
|
|
211
211
|
edit: "The entity could not be edited at this time."
|
|
212
212
|
}
|
|
213
|
-
},
|
|
213
|
+
}, $r = {
|
|
214
214
|
emptyState: {
|
|
215
215
|
noSearchResultsTitle: "No results found",
|
|
216
216
|
noSearchResultsMessage: "Please adjust the criteria and try again.",
|
|
217
217
|
noSearchResultsCtaText: "Clear"
|
|
218
218
|
}
|
|
219
|
-
},
|
|
219
|
+
}, Mr = {
|
|
220
220
|
title: "Configuration",
|
|
221
221
|
actions: {
|
|
222
222
|
copy: "Copy JSON"
|
|
@@ -251,7 +251,7 @@ const Sr = {
|
|
|
251
251
|
entryTitle: "Entry {index}",
|
|
252
252
|
structuredFormat: "Structured"
|
|
253
253
|
}
|
|
254
|
-
},
|
|
254
|
+
}, jr = {
|
|
255
255
|
filterButtonText: "Filter",
|
|
256
256
|
fieldLabel: "Filter by:",
|
|
257
257
|
inputPlaceholder: "Enter a value",
|
|
@@ -259,15 +259,15 @@ const Sr = {
|
|
|
259
259
|
applyButtonText: "Apply",
|
|
260
260
|
clearButtonText: "Clear",
|
|
261
261
|
clearAllButtonText: "Clear all filters"
|
|
262
|
-
},
|
|
262
|
+
}, Er = {
|
|
263
263
|
errors: {
|
|
264
264
|
fetch: "Could not fetch available items",
|
|
265
265
|
invalid: "Please select a valid value"
|
|
266
266
|
}
|
|
267
|
-
},
|
|
267
|
+
}, Or = {
|
|
268
268
|
unexpected: "An unexpected error has occurred",
|
|
269
269
|
dataKeyUndefined: 'The data key "{dataKey}" does not exist in the response.'
|
|
270
|
-
},
|
|
270
|
+
}, Fr = {
|
|
271
271
|
enable: {
|
|
272
272
|
title: "Enable {entityType}",
|
|
273
273
|
message: "Are you sure you want to enable the {entityType} {entityName}?",
|
|
@@ -278,18 +278,18 @@ const Sr = {
|
|
|
278
278
|
message: "Are you sure you want to disable the {entityType} {entityName}?",
|
|
279
279
|
confirmText: "Yes, disable"
|
|
280
280
|
}
|
|
281
|
-
},
|
|
282
|
-
deleteModal:
|
|
283
|
-
baseForm:
|
|
284
|
-
baseTable:
|
|
285
|
-
baseConfigCard:
|
|
286
|
-
filter:
|
|
287
|
-
debouncedFilter:
|
|
288
|
-
errors:
|
|
289
|
-
toggleModal:
|
|
281
|
+
}, Kr = {
|
|
282
|
+
deleteModal: xr,
|
|
283
|
+
baseForm: Tr,
|
|
284
|
+
baseTable: $r,
|
|
285
|
+
baseConfigCard: Mr,
|
|
286
|
+
filter: jr,
|
|
287
|
+
debouncedFilter: Er,
|
|
288
|
+
errors: Or,
|
|
289
|
+
toggleModal: Fr
|
|
290
290
|
};
|
|
291
291
|
function St() {
|
|
292
|
-
const e = It("en-us",
|
|
292
|
+
const e = It("en-us", Kr);
|
|
293
293
|
return {
|
|
294
294
|
i18n: e,
|
|
295
295
|
i18nT: cn(e)
|
|
@@ -313,54 +313,54 @@ function pn() {
|
|
|
313
313
|
isValidUuid: (e) => e ? /[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/.test(e) : !1
|
|
314
314
|
};
|
|
315
315
|
}
|
|
316
|
-
function
|
|
316
|
+
function Br(e, n, t, r = {
|
|
317
317
|
fetchedItemsKey: "data",
|
|
318
318
|
searchKeys: ["id"]
|
|
319
319
|
}) {
|
|
320
320
|
t || (t = "100");
|
|
321
321
|
const { axiosInstance: o } = At({
|
|
322
322
|
headers: e.requestHeaders
|
|
323
|
-
}), { i18n: { t: a } } = St(), { debounce: i } =
|
|
324
|
-
await
|
|
323
|
+
}), { i18n: { t: a } } = St(), { debounce: i } = Ir(), s = i(async (I) => {
|
|
324
|
+
await v(I);
|
|
325
325
|
}, 200), l = O(!1), c = O(""), d = O(""), u = O([]), g = O([]), f = O(void 0), A = y(n);
|
|
326
|
-
let
|
|
327
|
-
e.app === "konnect" ?
|
|
326
|
+
let b = `${e.apiBaseUrl}${A}`;
|
|
327
|
+
e.app === "konnect" ? b = b.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" && (b = b.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : ""));
|
|
328
328
|
const { isValidUuid: p } = pn(), S = async () => {
|
|
329
329
|
try {
|
|
330
330
|
l.value = !0;
|
|
331
|
-
const { data: I } = await o.get(`${
|
|
331
|
+
const { data: I } = await o.get(`${b}?size=${t}`);
|
|
332
332
|
I != null && I.next || (f.value = r.fetchedItemsKey in I ? I[r.fetchedItemsKey] : []), g.value = r.fetchedItemsKey in I ? I[r.fetchedItemsKey] : [], u.value = g.value;
|
|
333
333
|
} catch {
|
|
334
334
|
u.value = [], c.value = a("debouncedFilter.errors.fetch");
|
|
335
335
|
} finally {
|
|
336
336
|
l.value = !1;
|
|
337
337
|
}
|
|
338
|
-
},
|
|
338
|
+
}, C = O(""), v = async (I) => {
|
|
339
339
|
var ne, pe, H;
|
|
340
|
-
if (
|
|
341
|
-
if (
|
|
340
|
+
if (C.value !== I)
|
|
341
|
+
if (C.value = I || "", f.value === void 0)
|
|
342
342
|
try {
|
|
343
343
|
if (l.value = !0, c.value = "", d.value = "", e.app === "konnect") {
|
|
344
|
-
let w =
|
|
344
|
+
let w = b + "";
|
|
345
345
|
I && (w += `/${I}`);
|
|
346
|
-
const { data:
|
|
347
|
-
r.fetchedItemsKey in
|
|
346
|
+
const { data: B } = await o.get(`${w}?size=${t}`);
|
|
347
|
+
r.fetchedItemsKey in B ? u.value = B[r.fetchedItemsKey] : B != null && B.id ? u.value = [B] : u.value = [];
|
|
348
348
|
} else if (I) {
|
|
349
349
|
const w = [];
|
|
350
350
|
p(I) && r.searchKeys.includes("id") ? w.push((async () => {
|
|
351
|
-
const { data: k } = await o.get(`${
|
|
351
|
+
const { data: k } = await o.get(`${b}/${I}`);
|
|
352
352
|
return [k[r.fetchedItemsKey] ?? k];
|
|
353
353
|
})()) : w.push(
|
|
354
354
|
...r.searchKeys.filter((k) => k !== "id").map(async (k) => {
|
|
355
|
-
const { data: x } = await o.get(`${
|
|
355
|
+
const { data: x } = await o.get(`${b}?${k}=${I}`);
|
|
356
356
|
return x[r.fetchedItemsKey];
|
|
357
357
|
})
|
|
358
358
|
);
|
|
359
|
-
const
|
|
360
|
-
u.value = [], (ne =
|
|
359
|
+
const B = await Promise.all(w), N = /* @__PURE__ */ new Set();
|
|
360
|
+
u.value = [], (ne = B == null ? void 0 : B.forEach) == null || ne.call(B, (k) => {
|
|
361
361
|
var x;
|
|
362
362
|
(x = k == null ? void 0 : k.forEach) == null || x.call(k, (T) => {
|
|
363
|
-
|
|
363
|
+
N.has(T.id) || (N.add(T.id), u.value.push(T));
|
|
364
364
|
});
|
|
365
365
|
});
|
|
366
366
|
} else
|
|
@@ -372,13 +372,13 @@ function Kr(e, n, t, r = {
|
|
|
372
372
|
}
|
|
373
373
|
else
|
|
374
374
|
l.value = !0, d.value = "", I ? (u.value = (H = f.value) == null ? void 0 : H.filter((w) => {
|
|
375
|
-
var
|
|
376
|
-
let
|
|
375
|
+
var B;
|
|
376
|
+
let N = !1;
|
|
377
377
|
for (const k of r.searchKeys) {
|
|
378
|
-
const x = typeof w[k] == "string" ? (
|
|
379
|
-
x != null && x.includes(I.toLowerCase()) && (
|
|
378
|
+
const x = typeof w[k] == "string" ? (B = w[k]) == null ? void 0 : B.toLowerCase() : w[k];
|
|
379
|
+
x != null && x.includes(I.toLowerCase()) && (N = !0);
|
|
380
380
|
}
|
|
381
|
-
return
|
|
381
|
+
return N;
|
|
382
382
|
}), (!u.value || !u.value.length) && (d.value = a("debouncedFilter.errors.invalid"))) : u.value = f.value, l.value = !1;
|
|
383
383
|
};
|
|
384
384
|
return {
|
|
@@ -397,7 +397,7 @@ function Nr(e, n) {
|
|
|
397
397
|
);
|
|
398
398
|
return r.value.search = "", (o) => `${r.value.href}/${o}`;
|
|
399
399
|
}
|
|
400
|
-
function
|
|
400
|
+
function Pr() {
|
|
401
401
|
const { i18n: { t: e } } = St();
|
|
402
402
|
return {
|
|
403
403
|
getMessageFromError: (n) => {
|
|
@@ -435,15 +435,15 @@ function fn(e, n) {
|
|
|
435
435
|
const { page: s, pageSize: l, offset: c, sortColumnKey: d, sortColumnOrder: u, query: g } = i;
|
|
436
436
|
try {
|
|
437
437
|
let f = new URL(a.value.href);
|
|
438
|
-
return o.value && g ? (f.search = "", f = new URL(`${f.href}/${g}/`)) : (o.value || new URLSearchParams(g).forEach((A,
|
|
439
|
-
f.searchParams.append(
|
|
438
|
+
return o.value && g ? (f.search = "", f = new URL(`${f.href}/${g}/`)) : (o.value || new URLSearchParams(g).forEach((A, b) => {
|
|
439
|
+
f.searchParams.append(b, A);
|
|
440
440
|
}), d && f.searchParams.append("sort_by", d), u === "desc" && f.searchParams.append("sort_desc", "1"), f.searchParams.append("size", String(l))), c && s !== 1 && f.searchParams.append("offset", String(c)), f.href;
|
|
441
441
|
} catch (f) {
|
|
442
442
|
return console.error("RouteList(fetcher)", f), r.value;
|
|
443
443
|
}
|
|
444
444
|
};
|
|
445
445
|
}
|
|
446
|
-
function
|
|
446
|
+
function Lr(e, n, t = "data") {
|
|
447
447
|
const r = y(n), { axiosInstance: o } = At({
|
|
448
448
|
headers: e.requestHeaders
|
|
449
449
|
}), a = fn(e, r), i = O({
|
|
@@ -485,7 +485,7 @@ function Pr(e, n, t = "data") {
|
|
|
485
485
|
}
|
|
486
486
|
}, fetcherState: i };
|
|
487
487
|
}
|
|
488
|
-
function
|
|
488
|
+
function Ur() {
|
|
489
489
|
return {
|
|
490
490
|
convertKeyToTitle: (e, n = "_") => e ? e.split(n).map((t) => t.toLowerCase() === "id" ? t.toUpperCase() : t.charAt(0).toUpperCase() + t.substring(1)).join(" ") : ""
|
|
491
491
|
};
|
|
@@ -500,24 +500,24 @@ const mn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
500
500
|
}, Ut = (e) => e === "*" || e === "x" || e === "X", qt = (e) => {
|
|
501
501
|
const n = parseInt(e, 10);
|
|
502
502
|
return isNaN(n) ? e : n;
|
|
503
|
-
},
|
|
503
|
+
}, qr = (e, n) => typeof e != typeof n ? [String(e), String(n)] : [e, n], Rr = (e, n) => {
|
|
504
504
|
if (Ut(e) || Ut(n))
|
|
505
505
|
return 0;
|
|
506
|
-
const [t, r] =
|
|
506
|
+
const [t, r] = qr(qt(e), qt(n));
|
|
507
507
|
return t > r ? 1 : t < r ? -1 : 0;
|
|
508
508
|
}, Rt = (e, n) => {
|
|
509
509
|
for (let t = 0; t < Math.max(e.length, n.length); t++) {
|
|
510
|
-
const r =
|
|
510
|
+
const r = Rr(e[t] || "0", n[t] || "0");
|
|
511
511
|
if (r !== 0)
|
|
512
512
|
return r;
|
|
513
513
|
}
|
|
514
514
|
return 0;
|
|
515
|
-
},
|
|
515
|
+
}, Vr = (e, n) => {
|
|
516
516
|
const t = Lt(e), r = Lt(n), o = t.pop(), a = r.pop(), i = Rt(t, r);
|
|
517
517
|
return i !== 0 ? i : o && a ? Rt(o.split("."), a.split(".")) : o || a ? o ? -1 : 1 : 0;
|
|
518
518
|
}, Vt = (e, n, t) => {
|
|
519
|
-
|
|
520
|
-
const r =
|
|
519
|
+
Dr(t);
|
|
520
|
+
const r = Vr(e, n);
|
|
521
521
|
return gn[t].includes(r);
|
|
522
522
|
}, gn = {
|
|
523
523
|
">": [1],
|
|
@@ -526,18 +526,18 @@ const mn = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
|
|
|
526
526
|
"<=": [-1, 0],
|
|
527
527
|
"<": [-1],
|
|
528
528
|
"!=": [-1, 1]
|
|
529
|
-
}, Dt = Object.keys(gn),
|
|
529
|
+
}, Dt = Object.keys(gn), Dr = (e) => {
|
|
530
530
|
if (typeof e != "string")
|
|
531
531
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
532
532
|
if (Dt.indexOf(e) === -1)
|
|
533
533
|
throw new Error(`Invalid operator, expected one of ${Dt.join("|")}`);
|
|
534
|
-
},
|
|
535
|
-
function
|
|
534
|
+
}, Gr = (e) => typeof e == "string" && /^[v\d]/.test(e) && mn.test(e);
|
|
535
|
+
function Hr(e) {
|
|
536
536
|
const { gatewayInfo: n, supportedRange: t } = e;
|
|
537
537
|
if (!n)
|
|
538
538
|
return !0;
|
|
539
539
|
const { edition: r, version: o } = n;
|
|
540
|
-
if (!
|
|
540
|
+
if (!Gr(o))
|
|
541
541
|
return console.error("Invalid version"), !1;
|
|
542
542
|
const a = t[r];
|
|
543
543
|
if (!a)
|
|
@@ -545,7 +545,7 @@ function Gr(e) {
|
|
|
545
545
|
const [i, s] = a;
|
|
546
546
|
return !(i && Vt(o, i, "<") || s && Vt(o, s, ">"));
|
|
547
547
|
}
|
|
548
|
-
function
|
|
548
|
+
function zr(e) {
|
|
549
549
|
const n = O(0), t = O(0), r = O(!1);
|
|
550
550
|
return xe(e, (o) => {
|
|
551
551
|
o && !r.value && (n.value = o.offsetWidth, t.value = o.scrollWidth, r.value = !0);
|
|
@@ -555,26 +555,26 @@ function Hr(e) {
|
|
|
555
555
|
}
|
|
556
556
|
const ue = {
|
|
557
557
|
useAxios: At,
|
|
558
|
-
useDebouncedFilter:
|
|
558
|
+
useDebouncedFilter: Br,
|
|
559
559
|
useDeleteUrlBuilder: Nr,
|
|
560
|
-
useErrors:
|
|
561
|
-
useFetcher:
|
|
560
|
+
useErrors: Pr,
|
|
561
|
+
useFetcher: Lr,
|
|
562
562
|
useFetchUrlBuilder: fn,
|
|
563
563
|
useHelpers: pn,
|
|
564
|
-
useStringHelpers:
|
|
564
|
+
useStringHelpers: Ur,
|
|
565
565
|
useI18n: St,
|
|
566
|
-
useGatewayFeatureSupported:
|
|
567
|
-
useTruncationDetector:
|
|
568
|
-
},
|
|
566
|
+
useGatewayFeatureSupported: Hr,
|
|
567
|
+
useTruncationDetector: zr
|
|
568
|
+
}, Jr = {
|
|
569
569
|
fail: "Failed to copy id to clipboard",
|
|
570
570
|
success: {
|
|
571
571
|
prefix: "Successfully",
|
|
572
572
|
content: " copied to clipboard"
|
|
573
573
|
}
|
|
574
|
-
},
|
|
575
|
-
message:
|
|
576
|
-
iconTitle:
|
|
577
|
-
},
|
|
574
|
+
}, Wr = "Copy to clipboard", Yr = {
|
|
575
|
+
message: Jr,
|
|
576
|
+
iconTitle: Wr
|
|
577
|
+
}, Zr = "kong-ui-copy-uuid-notify", Qr = { class: "kong-ui-copy-uuid" }, Xr = ["onClick"], Gt = 15, eo = /* @__PURE__ */ ae({
|
|
578
578
|
__name: "CopyUuid",
|
|
579
579
|
props: {
|
|
580
580
|
uuid: {
|
|
@@ -618,7 +618,7 @@ const ue = {
|
|
|
618
618
|
},
|
|
619
619
|
emits: ["success", "error"],
|
|
620
620
|
setup(e, { emit: n }) {
|
|
621
|
-
const t = e, { t: r } = It("en-us",
|
|
621
|
+
const t = e, { t: r } = It("en-us", Yr), o = t.notify || yr(Zr, () => {
|
|
622
622
|
}), a = M(() => t.idTooltip ? {
|
|
623
623
|
label: t.idTooltip,
|
|
624
624
|
positionFixed: !0,
|
|
@@ -649,8 +649,8 @@ const ue = {
|
|
|
649
649
|
}), i.value ? d(t.successTooltip) : n("success", t.uuid);
|
|
650
650
|
};
|
|
651
651
|
return (g, f) => {
|
|
652
|
-
const A = U("KIcon"),
|
|
653
|
-
return m(), j("div",
|
|
652
|
+
const A = U("KIcon"), b = U("KClipboardProvider");
|
|
653
|
+
return m(), j("div", Qr, [
|
|
654
654
|
e.format !== "hidden" ? (m(), V(ze(e.idTooltip ? "KTooltip" : "div"), ht({ key: 0 }, a.value, { "data-testid": "copy-id" }), {
|
|
655
655
|
default: h(() => [
|
|
656
656
|
R("div", {
|
|
@@ -665,7 +665,7 @@ const ue = {
|
|
|
665
665
|
}, 16)) : G("", !0),
|
|
666
666
|
(m(), V(ze(e.tooltip ? "KTooltip" : "div"), ht(l.value, { class: "uuid-icon-wrapper" }), {
|
|
667
667
|
default: h(() => [
|
|
668
|
-
K(
|
|
668
|
+
K(b, null, {
|
|
669
669
|
default: h(({ copyToClipboard: p }) => [
|
|
670
670
|
R("span", {
|
|
671
671
|
"data-testid": "copy-to-clipboard",
|
|
@@ -681,7 +681,7 @@ const ue = {
|
|
|
681
681
|
size: "16",
|
|
682
682
|
title: y(r)("iconTitle")
|
|
683
683
|
}, null, 8, ["color", "hide-title", "title"])
|
|
684
|
-
], 8,
|
|
684
|
+
], 8, Xr)
|
|
685
685
|
]),
|
|
686
686
|
_: 1
|
|
687
687
|
})
|
|
@@ -691,15 +691,15 @@ const ue = {
|
|
|
691
691
|
]);
|
|
692
692
|
};
|
|
693
693
|
}
|
|
694
|
-
}),
|
|
694
|
+
}), to = (e, n) => {
|
|
695
695
|
const t = e.__vccOpts || e;
|
|
696
696
|
for (const [r, o] of n)
|
|
697
697
|
t[r] = o;
|
|
698
698
|
return t;
|
|
699
|
-
}, yn = /* @__PURE__ */ eo
|
|
699
|
+
}, yn = /* @__PURE__ */ to(eo, [["__scopeId", "data-v-bfdaf6f7"]]), no = {
|
|
700
700
|
key: 0,
|
|
701
701
|
class: "config-card-fieldset-title"
|
|
702
|
-
},
|
|
702
|
+
}, ro = /* @__PURE__ */ ae({
|
|
703
703
|
__name: "JsonCardItem",
|
|
704
704
|
props: {
|
|
705
705
|
item: {
|
|
@@ -727,7 +727,7 @@ const ue = {
|
|
|
727
727
|
class: Ke(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
728
728
|
}, {
|
|
729
729
|
default: h(() => [
|
|
730
|
-
e.isArrayItem ? (m(), j("legend",
|
|
730
|
+
e.isArrayItem ? (m(), j("legend", no, [
|
|
731
731
|
R("b", null, F(s.value), 1)
|
|
732
732
|
])) : G("", !0),
|
|
733
733
|
(m(!0), j(ve, null, ye(Object.keys(i.value), (d, u) => (m(), V(xt, {
|
|
@@ -747,7 +747,7 @@ const ue = {
|
|
|
747
747
|
for (const [r, o] of n)
|
|
748
748
|
t[r] = o;
|
|
749
749
|
return t;
|
|
750
|
-
}, hn = /* @__PURE__ */ ke(
|
|
750
|
+
}, hn = /* @__PURE__ */ ke(ro, [["__scopeId", "data-v-68ca83ec"]]), oo = /* @__PURE__ */ ae({
|
|
751
751
|
__name: "InternalLinkItem",
|
|
752
752
|
props: {
|
|
753
753
|
item: {
|
|
@@ -774,7 +774,7 @@ const ue = {
|
|
|
774
774
|
]);
|
|
775
775
|
};
|
|
776
776
|
}
|
|
777
|
-
}),
|
|
777
|
+
}), ao = /* @__PURE__ */ ke(oo, [["__scopeId", "data-v-7410504d"]]), io = /* @__PURE__ */ ae({
|
|
778
778
|
__name: "StatusBadge",
|
|
779
779
|
props: {
|
|
780
780
|
status: {
|
|
@@ -796,11 +796,11 @@ const ue = {
|
|
|
796
796
|
}, 8, ["appearance"]);
|
|
797
797
|
};
|
|
798
798
|
}
|
|
799
|
-
}),
|
|
799
|
+
}), so = "#0044f4", lo = "#e0e4ea", uo = "#3a3f51", co = "1px", po = "20px", fo = { class: "config-card-details-row" }, mo = ["data-testid"], go = ["data-testid"], yo = ["data-testid"], ho = ["data-testid"], vo = { key: 1 }, bo = ["data-testid"], Co = ["data-testid"], ko = ["data-testid"], _o = ["data-testid"], wo = {
|
|
800
800
|
name: "ConfigCardItem",
|
|
801
|
-
components: { CopyUuid: yn, JsonCardItem: hn, StatusBadge:
|
|
802
|
-
},
|
|
803
|
-
...
|
|
801
|
+
components: { CopyUuid: yn, JsonCardItem: hn, StatusBadge: io, InternalLinkItem: ao }
|
|
802
|
+
}, Io = /* @__PURE__ */ ae({
|
|
803
|
+
...wo,
|
|
804
804
|
props: {
|
|
805
805
|
item: {
|
|
806
806
|
type: Object,
|
|
@@ -820,8 +820,8 @@ const ue = {
|
|
|
820
820
|
emits: ["navigation-click"],
|
|
821
821
|
setup(e, { emit: n }) {
|
|
822
822
|
const t = e;
|
|
823
|
-
|
|
824
|
-
"1df60db4": c.value ? "none" : `solid ${y(
|
|
823
|
+
cr((f) => ({
|
|
824
|
+
"1df60db4": c.value ? "none" : `solid ${y(co)} ${y(lo)}`,
|
|
825
825
|
"21d1d34e": l.value && i.value ? "block" : "flex",
|
|
826
826
|
"4d3dc7e7": l.value && i.value ? "100%" : t.slim ? "50%" : "25%",
|
|
827
827
|
"4d400dc2": l.value && i.value ? "100%" : t.slim ? "50%" : "75%"
|
|
@@ -954,14 +954,14 @@ const ue = {
|
|
|
954
954
|
}
|
|
955
955
|
}), u = O(), { isTruncated: g } = ue.useTruncationDetector(u);
|
|
956
956
|
return (f, A) => {
|
|
957
|
-
const
|
|
958
|
-
return m(), j("div",
|
|
957
|
+
const b = U("KLabel"), p = U("KBadge"), S = U("KMethodBadge"), C = U("KTooltip");
|
|
958
|
+
return m(), j("div", fo, [
|
|
959
959
|
R("div", {
|
|
960
960
|
class: "config-card-details-label",
|
|
961
961
|
"data-testid": `${e.item.key}-label`
|
|
962
962
|
}, [
|
|
963
963
|
Y(f.$slots, "label", { item: e.item }, () => [
|
|
964
|
-
K(
|
|
964
|
+
K(b, { "tooltip-attributes": { maxWidth: "500px" } }, Te({
|
|
965
965
|
default: h(() => [
|
|
966
966
|
Z(F(e.item.label) + " ", 1)
|
|
967
967
|
]),
|
|
@@ -976,13 +976,13 @@ const ue = {
|
|
|
976
976
|
Y(f.$slots, "label-tooltip", {}, () => [
|
|
977
977
|
Z(F(e.item.tooltip), 1)
|
|
978
978
|
], !0)
|
|
979
|
-
], 8,
|
|
979
|
+
], 8, go)
|
|
980
980
|
]),
|
|
981
981
|
key: "0"
|
|
982
982
|
} : void 0
|
|
983
983
|
]), 1024)
|
|
984
984
|
], !0)
|
|
985
|
-
], 8,
|
|
985
|
+
], 8, mo),
|
|
986
986
|
R("div", {
|
|
987
987
|
class: "config-card-details-value",
|
|
988
988
|
"data-testid": `${e.item.key}-property-value`
|
|
@@ -990,65 +990,65 @@ const ue = {
|
|
|
990
990
|
Y(f.$slots, e.item.key, {
|
|
991
991
|
rowValue: e.item.value
|
|
992
992
|
}, () => [
|
|
993
|
-
i.value ? (m(), j("div",
|
|
994
|
-
(m(), V(ze(d.value.tag),
|
|
993
|
+
i.value ? (m(), j("div", vo, [
|
|
994
|
+
(m(), V(ze(d.value.tag), dr(pr(d.value.attrs)), {
|
|
995
995
|
default: h(() => [
|
|
996
996
|
d.value.additionalComponent === "KBadge" ? (m(), j("div", {
|
|
997
997
|
key: 0,
|
|
998
998
|
"data-testid": `${e.item.key}-badge-tags`
|
|
999
999
|
}, [
|
|
1000
|
-
(m(!0), j(ve, null, ye(e.item.value, (
|
|
1000
|
+
(m(!0), j(ve, null, ye(e.item.value, (v, I) => (m(), V(p, {
|
|
1001
1001
|
key: `${e.item.key}-badge-tag-${I}`,
|
|
1002
1002
|
class: "config-badge",
|
|
1003
1003
|
"data-testid": `${e.item.key}-badge-tag-${I}`,
|
|
1004
|
-
"truncation-tooltip":
|
|
1004
|
+
"truncation-tooltip": v
|
|
1005
1005
|
}, {
|
|
1006
1006
|
default: h(() => [
|
|
1007
|
-
Z(F(
|
|
1007
|
+
Z(F(v), 1)
|
|
1008
1008
|
]),
|
|
1009
1009
|
_: 2
|
|
1010
1010
|
}, 1032, ["data-testid", "truncation-tooltip"]))), 128))
|
|
1011
|
-
], 8,
|
|
1011
|
+
], 8, bo)) : G("", !0),
|
|
1012
1012
|
d.value.additionalComponent === "CopyUuid" ? (m(), j("div", {
|
|
1013
1013
|
key: 1,
|
|
1014
1014
|
class: "copy-uuid-array",
|
|
1015
1015
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
1016
1016
|
}, [
|
|
1017
|
-
(m(!0), j(ve, null, ye(e.item.value, (
|
|
1017
|
+
(m(!0), j(ve, null, ye(e.item.value, (v, I) => (m(), V(y(yn), ht(d.value.childAttrs, {
|
|
1018
1018
|
key: `${e.item.key}-copy-uuid-${I}`,
|
|
1019
1019
|
"data-testid": `${e.item.key}-copy-uuid-${I}`,
|
|
1020
|
-
uuid:
|
|
1020
|
+
uuid: v
|
|
1021
1021
|
}), null, 16, ["data-testid", "uuid"]))), 128))
|
|
1022
|
-
], 8,
|
|
1022
|
+
], 8, Co)) : d.value.additionalComponent === "KMethodBadge" ? (m(), j("div", {
|
|
1023
1023
|
key: 2,
|
|
1024
1024
|
class: "method-badge-array",
|
|
1025
1025
|
"data-testid": `${e.item.key}-badge-methods`
|
|
1026
1026
|
}, [
|
|
1027
|
-
(m(!0), j(ve, null, ye(e.item.value, (
|
|
1027
|
+
(m(!0), j(ve, null, ye(e.item.value, (v, I) => (m(), V(S, {
|
|
1028
1028
|
key: `${e.item.key}-badge-method-${I}`,
|
|
1029
1029
|
class: "config-badge",
|
|
1030
1030
|
"data-testid": `${e.item.key}-badge-method-${I}`,
|
|
1031
1031
|
"is-rounded": "",
|
|
1032
|
-
label:
|
|
1033
|
-
method: y(
|
|
1032
|
+
label: v,
|
|
1033
|
+
method: y(Cr).includes(v.toLowerCase()) ? v.toLowerCase() : "custom"
|
|
1034
1034
|
}, {
|
|
1035
1035
|
default: h(() => [
|
|
1036
|
-
Z(F(
|
|
1036
|
+
Z(F(v), 1)
|
|
1037
1037
|
]),
|
|
1038
1038
|
_: 2
|
|
1039
1039
|
}, 1032, ["data-testid", "label", "method"]))), 128))
|
|
1040
|
-
], 8,
|
|
1040
|
+
], 8, ko)) : G("", !0),
|
|
1041
1041
|
d.value.additionalComponent === "JsonCardItem" ? (m(), j("div", {
|
|
1042
1042
|
key: 3,
|
|
1043
1043
|
"data-testid": `${t.item.key}-json-array-content`
|
|
1044
1044
|
}, [
|
|
1045
|
-
(m(!0), j(ve, null, ye(e.item.value, (
|
|
1045
|
+
(m(!0), j(ve, null, ye(e.item.value, (v, I) => (m(), V(hn, {
|
|
1046
1046
|
key: `json-array-item-${I}`,
|
|
1047
1047
|
index: I,
|
|
1048
1048
|
"is-array-item": "",
|
|
1049
|
-
item:
|
|
1049
|
+
item: v
|
|
1050
1050
|
}, null, 8, ["index", "item"]))), 128))
|
|
1051
|
-
], 8,
|
|
1051
|
+
], 8, _o)) : (m(), V(C, {
|
|
1052
1052
|
key: 4,
|
|
1053
1053
|
label: y(g) ? e.item.value : ""
|
|
1054
1054
|
}, {
|
|
@@ -1067,46 +1067,46 @@ const ue = {
|
|
|
1067
1067
|
])) : (m(), j("div", {
|
|
1068
1068
|
key: 0,
|
|
1069
1069
|
"data-testid": `${e.item.key}-no-value`
|
|
1070
|
-
}, " – ", 8,
|
|
1070
|
+
}, " – ", 8, ho))
|
|
1071
1071
|
], !0)
|
|
1072
|
-
], 8,
|
|
1072
|
+
], 8, yo)
|
|
1073
1073
|
]);
|
|
1074
1074
|
};
|
|
1075
1075
|
}
|
|
1076
|
-
}), xt = /* @__PURE__ */ ke(
|
|
1076
|
+
}), xt = /* @__PURE__ */ ke(Io, [["__scopeId", "data-v-307ab96d"]]);
|
|
1077
1077
|
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
|
|
1078
1078
|
function vn(e) {
|
|
1079
1079
|
return typeof e > "u" || e === null;
|
|
1080
1080
|
}
|
|
1081
|
-
function
|
|
1081
|
+
function Ao(e) {
|
|
1082
1082
|
return typeof e == "object" && e !== null;
|
|
1083
1083
|
}
|
|
1084
|
-
function
|
|
1084
|
+
function So(e) {
|
|
1085
1085
|
return Array.isArray(e) ? e : vn(e) ? [] : [e];
|
|
1086
1086
|
}
|
|
1087
|
-
function
|
|
1087
|
+
function xo(e, n) {
|
|
1088
1088
|
var t, r, o, a;
|
|
1089
1089
|
if (n)
|
|
1090
1090
|
for (a = Object.keys(n), t = 0, r = a.length; t < r; t += 1)
|
|
1091
1091
|
o = a[t], e[o] = n[o];
|
|
1092
1092
|
return e;
|
|
1093
1093
|
}
|
|
1094
|
-
function
|
|
1094
|
+
function To(e, n) {
|
|
1095
1095
|
var t = "", r;
|
|
1096
1096
|
for (r = 0; r < n; r += 1)
|
|
1097
1097
|
t += e;
|
|
1098
1098
|
return t;
|
|
1099
1099
|
}
|
|
1100
|
-
function
|
|
1100
|
+
function $o(e) {
|
|
1101
1101
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1102
1102
|
}
|
|
1103
|
-
var
|
|
1104
|
-
isNothing:
|
|
1105
|
-
isObject:
|
|
1106
|
-
toArray:
|
|
1107
|
-
repeat:
|
|
1108
|
-
isNegativeZero:
|
|
1109
|
-
extend:
|
|
1103
|
+
var Mo = vn, jo = Ao, Eo = So, Oo = To, Fo = $o, Ko = xo, se = {
|
|
1104
|
+
isNothing: Mo,
|
|
1105
|
+
isObject: jo,
|
|
1106
|
+
toArray: Eo,
|
|
1107
|
+
repeat: Oo,
|
|
1108
|
+
isNegativeZero: Fo,
|
|
1109
|
+
extend: Ko
|
|
1110
1110
|
};
|
|
1111
1111
|
function bn(e, n) {
|
|
1112
1112
|
var t = "", r = e.reason || "(unknown reason)";
|
|
@@ -1134,7 +1134,7 @@ function mt(e, n, t, r, o) {
|
|
|
1134
1134
|
function gt(e, n) {
|
|
1135
1135
|
return se.repeat(" ", n - e.length) + e;
|
|
1136
1136
|
}
|
|
1137
|
-
function
|
|
1137
|
+
function Bo(e, n) {
|
|
1138
1138
|
if (n = Object.create(n || null), !e.buffer)
|
|
1139
1139
|
return null;
|
|
1140
1140
|
n.maxLength || (n.maxLength = 79), typeof n.indent != "number" && (n.indent = 1), typeof n.linesBefore != "number" && (n.linesBefore = 3), typeof n.linesAfter != "number" && (n.linesAfter = 2);
|
|
@@ -1164,7 +1164,7 @@ function Ko(e, n) {
|
|
|
1164
1164
|
`;
|
|
1165
1165
|
return s.replace(/\n$/, "");
|
|
1166
1166
|
}
|
|
1167
|
-
var No =
|
|
1167
|
+
var No = Bo, Po = [
|
|
1168
1168
|
"kind",
|
|
1169
1169
|
"multi",
|
|
1170
1170
|
"resolve",
|
|
@@ -1175,12 +1175,12 @@ var No = Ko, Bo = [
|
|
|
1175
1175
|
"representName",
|
|
1176
1176
|
"defaultStyle",
|
|
1177
1177
|
"styleAliases"
|
|
1178
|
-
],
|
|
1178
|
+
], Lo = [
|
|
1179
1179
|
"scalar",
|
|
1180
1180
|
"sequence",
|
|
1181
1181
|
"mapping"
|
|
1182
1182
|
];
|
|
1183
|
-
function
|
|
1183
|
+
function Uo(e) {
|
|
1184
1184
|
var n = {};
|
|
1185
1185
|
return e !== null && Object.keys(e).forEach(function(t) {
|
|
1186
1186
|
e[t].forEach(function(r) {
|
|
@@ -1188,18 +1188,18 @@ function Lo(e) {
|
|
|
1188
1188
|
});
|
|
1189
1189
|
}), n;
|
|
1190
1190
|
}
|
|
1191
|
-
function
|
|
1191
|
+
function qo(e, n) {
|
|
1192
1192
|
if (n = n || {}, Object.keys(n).forEach(function(t) {
|
|
1193
|
-
if (
|
|
1193
|
+
if (Po.indexOf(t) === -1)
|
|
1194
1194
|
throw new me('Unknown option "' + t + '" is met in definition of "' + e + '" YAML type.');
|
|
1195
1195
|
}), this.options = n, this.tag = e, this.kind = n.kind || null, this.resolve = n.resolve || function() {
|
|
1196
1196
|
return !0;
|
|
1197
1197
|
}, this.construct = n.construct || function(t) {
|
|
1198
1198
|
return t;
|
|
1199
|
-
}, 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 =
|
|
1199
|
+
}, 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 = Uo(n.styleAliases || null), Lo.indexOf(this.kind) === -1)
|
|
1200
1200
|
throw new me('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.');
|
|
1201
1201
|
}
|
|
1202
|
-
var de =
|
|
1202
|
+
var de = qo;
|
|
1203
1203
|
function Ht(e, n) {
|
|
1204
1204
|
var t = [];
|
|
1205
1205
|
return e[n].forEach(function(r) {
|
|
@@ -1209,7 +1209,7 @@ function Ht(e, n) {
|
|
|
1209
1209
|
}), t[o] = r;
|
|
1210
1210
|
}), t;
|
|
1211
1211
|
}
|
|
1212
|
-
function
|
|
1212
|
+
function Ro() {
|
|
1213
1213
|
var e = {
|
|
1214
1214
|
scalar: {},
|
|
1215
1215
|
sequence: {},
|
|
@@ -1254,7 +1254,7 @@ vt.prototype.extend = function(e) {
|
|
|
1254
1254
|
throw new me("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1255
1255
|
});
|
|
1256
1256
|
var r = Object.create(vt.prototype);
|
|
1257
|
-
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(t), r.compiledImplicit = Ht(r, "implicit"), r.compiledExplicit = Ht(r, "explicit"), r.compiledTypeMap =
|
|
1257
|
+
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(t), r.compiledImplicit = Ht(r, "implicit"), r.compiledExplicit = Ht(r, "explicit"), r.compiledTypeMap = Ro(r.compiledImplicit, r.compiledExplicit), r;
|
|
1258
1258
|
};
|
|
1259
1259
|
var Cn = vt, kn = new de("tag:yaml.org,2002:str", {
|
|
1260
1260
|
kind: "scalar",
|
|
@@ -1278,23 +1278,23 @@ var Cn = vt, kn = new de("tag:yaml.org,2002:str", {
|
|
|
1278
1278
|
wn
|
|
1279
1279
|
]
|
|
1280
1280
|
});
|
|
1281
|
-
function
|
|
1281
|
+
function Vo(e) {
|
|
1282
1282
|
if (e === null)
|
|
1283
1283
|
return !0;
|
|
1284
1284
|
var n = e.length;
|
|
1285
1285
|
return n === 1 && e === "~" || n === 4 && (e === "null" || e === "Null" || e === "NULL");
|
|
1286
1286
|
}
|
|
1287
|
-
function
|
|
1287
|
+
function Do() {
|
|
1288
1288
|
return null;
|
|
1289
1289
|
}
|
|
1290
|
-
function
|
|
1290
|
+
function Go(e) {
|
|
1291
1291
|
return e === null;
|
|
1292
1292
|
}
|
|
1293
1293
|
var An = new de("tag:yaml.org,2002:null", {
|
|
1294
1294
|
kind: "scalar",
|
|
1295
|
-
resolve:
|
|
1296
|
-
construct:
|
|
1297
|
-
predicate:
|
|
1295
|
+
resolve: Vo,
|
|
1296
|
+
construct: Do,
|
|
1297
|
+
predicate: Go,
|
|
1298
1298
|
represent: {
|
|
1299
1299
|
canonical: function() {
|
|
1300
1300
|
return "~";
|
|
@@ -1314,23 +1314,23 @@ var An = new de("tag:yaml.org,2002:null", {
|
|
|
1314
1314
|
},
|
|
1315
1315
|
defaultStyle: "lowercase"
|
|
1316
1316
|
});
|
|
1317
|
-
function
|
|
1317
|
+
function Ho(e) {
|
|
1318
1318
|
if (e === null)
|
|
1319
1319
|
return !1;
|
|
1320
1320
|
var n = e.length;
|
|
1321
1321
|
return n === 4 && (e === "true" || e === "True" || e === "TRUE") || n === 5 && (e === "false" || e === "False" || e === "FALSE");
|
|
1322
1322
|
}
|
|
1323
|
-
function
|
|
1323
|
+
function zo(e) {
|
|
1324
1324
|
return e === "true" || e === "True" || e === "TRUE";
|
|
1325
1325
|
}
|
|
1326
|
-
function
|
|
1326
|
+
function Jo(e) {
|
|
1327
1327
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1328
1328
|
}
|
|
1329
1329
|
var Sn = new de("tag:yaml.org,2002:bool", {
|
|
1330
1330
|
kind: "scalar",
|
|
1331
|
-
resolve:
|
|
1332
|
-
construct:
|
|
1333
|
-
predicate:
|
|
1331
|
+
resolve: Ho,
|
|
1332
|
+
construct: zo,
|
|
1333
|
+
predicate: Jo,
|
|
1334
1334
|
represent: {
|
|
1335
1335
|
lowercase: function(e) {
|
|
1336
1336
|
return e ? "true" : "false";
|
|
@@ -1344,16 +1344,16 @@ var Sn = new de("tag:yaml.org,2002:bool", {
|
|
|
1344
1344
|
},
|
|
1345
1345
|
defaultStyle: "lowercase"
|
|
1346
1346
|
});
|
|
1347
|
-
function
|
|
1347
|
+
function Wo(e) {
|
|
1348
1348
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1349
1349
|
}
|
|
1350
|
-
function
|
|
1350
|
+
function Yo(e) {
|
|
1351
1351
|
return 48 <= e && e <= 55;
|
|
1352
1352
|
}
|
|
1353
|
-
function
|
|
1353
|
+
function Zo(e) {
|
|
1354
1354
|
return 48 <= e && e <= 57;
|
|
1355
1355
|
}
|
|
1356
|
-
function
|
|
1356
|
+
function Qo(e) {
|
|
1357
1357
|
if (e === null)
|
|
1358
1358
|
return !1;
|
|
1359
1359
|
var n = e.length, t = 0, r = !1, o;
|
|
@@ -1374,7 +1374,7 @@ function Zo(e) {
|
|
|
1374
1374
|
if (o === "x") {
|
|
1375
1375
|
for (t++; t < n; t++)
|
|
1376
1376
|
if (o = e[t], o !== "_") {
|
|
1377
|
-
if (!
|
|
1377
|
+
if (!Wo(e.charCodeAt(t)))
|
|
1378
1378
|
return !1;
|
|
1379
1379
|
r = !0;
|
|
1380
1380
|
}
|
|
@@ -1383,7 +1383,7 @@ function Zo(e) {
|
|
|
1383
1383
|
if (o === "o") {
|
|
1384
1384
|
for (t++; t < n; t++)
|
|
1385
1385
|
if (o = e[t], o !== "_") {
|
|
1386
|
-
if (!
|
|
1386
|
+
if (!Yo(e.charCodeAt(t)))
|
|
1387
1387
|
return !1;
|
|
1388
1388
|
r = !0;
|
|
1389
1389
|
}
|
|
@@ -1394,13 +1394,13 @@ function Zo(e) {
|
|
|
1394
1394
|
return !1;
|
|
1395
1395
|
for (; t < n; t++)
|
|
1396
1396
|
if (o = e[t], o !== "_") {
|
|
1397
|
-
if (!
|
|
1397
|
+
if (!Zo(e.charCodeAt(t)))
|
|
1398
1398
|
return !1;
|
|
1399
1399
|
r = !0;
|
|
1400
1400
|
}
|
|
1401
1401
|
return !(!r || o === "_");
|
|
1402
1402
|
}
|
|
1403
|
-
function
|
|
1403
|
+
function Xo(e) {
|
|
1404
1404
|
var n = e, t = 1, r;
|
|
1405
1405
|
if (n.indexOf("_") !== -1 && (n = n.replace(/_/g, "")), r = n[0], (r === "-" || r === "+") && (r === "-" && (t = -1), n = n.slice(1), r = n[0]), n === "0")
|
|
1406
1406
|
return 0;
|
|
@@ -1414,14 +1414,14 @@ function Qo(e) {
|
|
|
1414
1414
|
}
|
|
1415
1415
|
return t * parseInt(n, 10);
|
|
1416
1416
|
}
|
|
1417
|
-
function
|
|
1417
|
+
function ea(e) {
|
|
1418
1418
|
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 === 0 && !se.isNegativeZero(e);
|
|
1419
1419
|
}
|
|
1420
1420
|
var xn = new de("tag:yaml.org,2002:int", {
|
|
1421
1421
|
kind: "scalar",
|
|
1422
|
-
resolve:
|
|
1423
|
-
construct:
|
|
1424
|
-
predicate:
|
|
1422
|
+
resolve: Qo,
|
|
1423
|
+
construct: Xo,
|
|
1424
|
+
predicate: ea,
|
|
1425
1425
|
represent: {
|
|
1426
1426
|
binary: function(e) {
|
|
1427
1427
|
return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1);
|
|
@@ -1444,21 +1444,21 @@ var xn = new de("tag:yaml.org,2002:int", {
|
|
|
1444
1444
|
decimal: [10, "dec"],
|
|
1445
1445
|
hexadecimal: [16, "hex"]
|
|
1446
1446
|
}
|
|
1447
|
-
}),
|
|
1447
|
+
}), ta = new RegExp(
|
|
1448
1448
|
// 2.5e4, 2.5 and integers
|
|
1449
1449
|
"^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"
|
|
1450
1450
|
);
|
|
1451
|
-
function
|
|
1452
|
-
return !(e === null || !
|
|
1451
|
+
function na(e) {
|
|
1452
|
+
return !(e === null || !ta.test(e) || // Quick hack to not allow integers end with `_`
|
|
1453
1453
|
// Probably should update regexp & check speed
|
|
1454
1454
|
e[e.length - 1] === "_");
|
|
1455
1455
|
}
|
|
1456
|
-
function
|
|
1456
|
+
function ra(e) {
|
|
1457
1457
|
var n, t;
|
|
1458
1458
|
return n = e.replace(/_/g, "").toLowerCase(), t = n[0] === "-" ? -1 : 1, "+-".indexOf(n[0]) >= 0 && (n = n.slice(1)), n === ".inf" ? t === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : n === ".nan" ? NaN : t * parseFloat(n, 10);
|
|
1459
1459
|
}
|
|
1460
|
-
var
|
|
1461
|
-
function
|
|
1460
|
+
var oa = /^[-+]?[0-9]+e/;
|
|
1461
|
+
function aa(e, n) {
|
|
1462
1462
|
var t;
|
|
1463
1463
|
if (isNaN(e))
|
|
1464
1464
|
switch (n) {
|
|
@@ -1489,17 +1489,17 @@ function oa(e, n) {
|
|
|
1489
1489
|
}
|
|
1490
1490
|
else if (se.isNegativeZero(e))
|
|
1491
1491
|
return "-0.0";
|
|
1492
|
-
return t = e.toString(10),
|
|
1492
|
+
return t = e.toString(10), oa.test(t) ? t.replace("e", ".e") : t;
|
|
1493
1493
|
}
|
|
1494
|
-
function
|
|
1494
|
+
function ia(e) {
|
|
1495
1495
|
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 !== 0 || se.isNegativeZero(e));
|
|
1496
1496
|
}
|
|
1497
1497
|
var Tn = new de("tag:yaml.org,2002:float", {
|
|
1498
1498
|
kind: "scalar",
|
|
1499
|
-
resolve:
|
|
1500
|
-
construct:
|
|
1501
|
-
predicate:
|
|
1502
|
-
represent:
|
|
1499
|
+
resolve: na,
|
|
1500
|
+
construct: ra,
|
|
1501
|
+
predicate: ia,
|
|
1502
|
+
represent: aa,
|
|
1503
1503
|
defaultStyle: "lowercase"
|
|
1504
1504
|
}), $n = In.extend({
|
|
1505
1505
|
implicit: [
|
|
@@ -1513,10 +1513,10 @@ var Tn = new de("tag:yaml.org,2002:float", {
|
|
|
1513
1513
|
), En = new RegExp(
|
|
1514
1514
|
"^([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]))?))?$"
|
|
1515
1515
|
);
|
|
1516
|
-
function
|
|
1516
|
+
function sa(e) {
|
|
1517
1517
|
return e === null ? !1 : jn.exec(e) !== null || En.exec(e) !== null;
|
|
1518
1518
|
}
|
|
1519
|
-
function
|
|
1519
|
+
function la(e) {
|
|
1520
1520
|
var n, t, r, o, a, i, s, l = 0, c = null, d, u, g;
|
|
1521
1521
|
if (n = jn.exec(e), n === null && (n = En.exec(e)), n === null)
|
|
1522
1522
|
throw new Error("Date resolve error");
|
|
@@ -1529,25 +1529,25 @@ function sa(e) {
|
|
|
1529
1529
|
}
|
|
1530
1530
|
return n[9] && (d = +n[10], u = +(n[11] || 0), c = (d * 60 + u) * 6e4, n[9] === "-" && (c = -c)), g = new Date(Date.UTC(t, r, o, a, i, s, l)), c && g.setTime(g.getTime() - c), g;
|
|
1531
1531
|
}
|
|
1532
|
-
function
|
|
1532
|
+
function ua(e) {
|
|
1533
1533
|
return e.toISOString();
|
|
1534
1534
|
}
|
|
1535
1535
|
var On = new de("tag:yaml.org,2002:timestamp", {
|
|
1536
1536
|
kind: "scalar",
|
|
1537
|
-
resolve:
|
|
1538
|
-
construct:
|
|
1537
|
+
resolve: sa,
|
|
1538
|
+
construct: la,
|
|
1539
1539
|
instanceOf: Date,
|
|
1540
|
-
represent:
|
|
1540
|
+
represent: ua
|
|
1541
1541
|
});
|
|
1542
|
-
function
|
|
1542
|
+
function ca(e) {
|
|
1543
1543
|
return e === "<<" || e === null;
|
|
1544
1544
|
}
|
|
1545
1545
|
var Fn = new de("tag:yaml.org,2002:merge", {
|
|
1546
1546
|
kind: "scalar",
|
|
1547
|
-
resolve:
|
|
1547
|
+
resolve: ca
|
|
1548
1548
|
}), Tt = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
1549
1549
|
\r`;
|
|
1550
|
-
function
|
|
1550
|
+
function da(e) {
|
|
1551
1551
|
if (e === null)
|
|
1552
1552
|
return !1;
|
|
1553
1553
|
var n, t, r = 0, o = e.length, a = Tt;
|
|
@@ -1559,37 +1559,37 @@ function ca(e) {
|
|
|
1559
1559
|
}
|
|
1560
1560
|
return r % 8 === 0;
|
|
1561
1561
|
}
|
|
1562
|
-
function
|
|
1562
|
+
function pa(e) {
|
|
1563
1563
|
var n, t, r = e.replace(/[\r\n=]/g, ""), o = r.length, a = Tt, i = 0, s = [];
|
|
1564
1564
|
for (n = 0; n < o; n++)
|
|
1565
1565
|
n % 4 === 0 && n && (s.push(i >> 16 & 255), s.push(i >> 8 & 255), s.push(i & 255)), i = i << 6 | a.indexOf(r.charAt(n));
|
|
1566
1566
|
return t = o % 4 * 6, t === 0 ? (s.push(i >> 16 & 255), s.push(i >> 8 & 255), s.push(i & 255)) : t === 18 ? (s.push(i >> 10 & 255), s.push(i >> 2 & 255)) : t === 12 && s.push(i >> 4 & 255), new Uint8Array(s);
|
|
1567
1567
|
}
|
|
1568
|
-
function
|
|
1568
|
+
function fa(e) {
|
|
1569
1569
|
var n = "", t = 0, r, o, a = e.length, i = Tt;
|
|
1570
1570
|
for (r = 0; r < a; r++)
|
|
1571
1571
|
r % 3 === 0 && r && (n += i[t >> 18 & 63], n += i[t >> 12 & 63], n += i[t >> 6 & 63], n += i[t & 63]), t = (t << 8) + e[r];
|
|
1572
1572
|
return o = a % 3, o === 0 ? (n += i[t >> 18 & 63], n += i[t >> 12 & 63], n += i[t >> 6 & 63], n += i[t & 63]) : o === 2 ? (n += i[t >> 10 & 63], n += i[t >> 4 & 63], n += i[t << 2 & 63], n += i[64]) : o === 1 && (n += i[t >> 2 & 63], n += i[t << 4 & 63], n += i[64], n += i[64]), n;
|
|
1573
1573
|
}
|
|
1574
|
-
function
|
|
1574
|
+
function ma(e) {
|
|
1575
1575
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1576
1576
|
}
|
|
1577
1577
|
var Kn = new de("tag:yaml.org,2002:binary", {
|
|
1578
1578
|
kind: "scalar",
|
|
1579
|
-
resolve:
|
|
1580
|
-
construct:
|
|
1581
|
-
predicate:
|
|
1582
|
-
represent:
|
|
1583
|
-
}),
|
|
1584
|
-
function
|
|
1579
|
+
resolve: da,
|
|
1580
|
+
construct: pa,
|
|
1581
|
+
predicate: ma,
|
|
1582
|
+
represent: fa
|
|
1583
|
+
}), ga = Object.prototype.hasOwnProperty, ya = Object.prototype.toString;
|
|
1584
|
+
function ha(e) {
|
|
1585
1585
|
if (e === null)
|
|
1586
1586
|
return !0;
|
|
1587
1587
|
var n = [], t, r, o, a, i, s = e;
|
|
1588
1588
|
for (t = 0, r = s.length; t < r; t += 1) {
|
|
1589
|
-
if (o = s[t], i = !1,
|
|
1589
|
+
if (o = s[t], i = !1, ya.call(o) !== "[object Object]")
|
|
1590
1590
|
return !1;
|
|
1591
1591
|
for (a in o)
|
|
1592
|
-
if (
|
|
1592
|
+
if (ga.call(o, a))
|
|
1593
1593
|
if (!i)
|
|
1594
1594
|
i = !0;
|
|
1595
1595
|
else
|
|
@@ -1603,26 +1603,26 @@ function ya(e) {
|
|
|
1603
1603
|
}
|
|
1604
1604
|
return !0;
|
|
1605
1605
|
}
|
|
1606
|
-
function
|
|
1606
|
+
function va(e) {
|
|
1607
1607
|
return e !== null ? e : [];
|
|
1608
1608
|
}
|
|
1609
|
-
var
|
|
1609
|
+
var Bn = new de("tag:yaml.org,2002:omap", {
|
|
1610
1610
|
kind: "sequence",
|
|
1611
|
-
resolve:
|
|
1612
|
-
construct:
|
|
1613
|
-
}),
|
|
1614
|
-
function
|
|
1611
|
+
resolve: ha,
|
|
1612
|
+
construct: va
|
|
1613
|
+
}), ba = Object.prototype.toString;
|
|
1614
|
+
function Ca(e) {
|
|
1615
1615
|
if (e === null)
|
|
1616
1616
|
return !0;
|
|
1617
1617
|
var n, t, r, o, a, i = e;
|
|
1618
1618
|
for (a = new Array(i.length), n = 0, t = i.length; n < t; n += 1) {
|
|
1619
|
-
if (r = i[n],
|
|
1619
|
+
if (r = i[n], ba.call(r) !== "[object Object]" || (o = Object.keys(r), o.length !== 1))
|
|
1620
1620
|
return !1;
|
|
1621
1621
|
a[n] = [o[0], r[o[0]]];
|
|
1622
1622
|
}
|
|
1623
1623
|
return !0;
|
|
1624
1624
|
}
|
|
1625
|
-
function
|
|
1625
|
+
function ka(e) {
|
|
1626
1626
|
if (e === null)
|
|
1627
1627
|
return [];
|
|
1628
1628
|
var n, t, r, o, a, i = e;
|
|
@@ -1630,27 +1630,27 @@ function Ca(e) {
|
|
|
1630
1630
|
r = i[n], o = Object.keys(r), a[n] = [o[0], r[o[0]]];
|
|
1631
1631
|
return a;
|
|
1632
1632
|
}
|
|
1633
|
-
var
|
|
1633
|
+
var Nn = new de("tag:yaml.org,2002:pairs", {
|
|
1634
1634
|
kind: "sequence",
|
|
1635
|
-
resolve:
|
|
1636
|
-
construct:
|
|
1637
|
-
}),
|
|
1638
|
-
function
|
|
1635
|
+
resolve: Ca,
|
|
1636
|
+
construct: ka
|
|
1637
|
+
}), _a = Object.prototype.hasOwnProperty;
|
|
1638
|
+
function wa(e) {
|
|
1639
1639
|
if (e === null)
|
|
1640
1640
|
return !0;
|
|
1641
1641
|
var n, t = e;
|
|
1642
1642
|
for (n in t)
|
|
1643
|
-
if (
|
|
1643
|
+
if (_a.call(t, n) && t[n] !== null)
|
|
1644
1644
|
return !1;
|
|
1645
1645
|
return !0;
|
|
1646
1646
|
}
|
|
1647
|
-
function
|
|
1647
|
+
function Ia(e) {
|
|
1648
1648
|
return e !== null ? e : {};
|
|
1649
1649
|
}
|
|
1650
1650
|
var Pn = new de("tag:yaml.org,2002:set", {
|
|
1651
1651
|
kind: "mapping",
|
|
1652
|
-
resolve:
|
|
1653
|
-
construct:
|
|
1652
|
+
resolve: wa,
|
|
1653
|
+
construct: Ia
|
|
1654
1654
|
}), $t = Mn.extend({
|
|
1655
1655
|
implicit: [
|
|
1656
1656
|
On,
|
|
@@ -1658,11 +1658,11 @@ var Pn = new de("tag:yaml.org,2002:set", {
|
|
|
1658
1658
|
],
|
|
1659
1659
|
explicit: [
|
|
1660
1660
|
Kn,
|
|
1661
|
-
Nn,
|
|
1662
1661
|
Bn,
|
|
1662
|
+
Nn,
|
|
1663
1663
|
Pn
|
|
1664
1664
|
]
|
|
1665
|
-
}), je = Object.prototype.hasOwnProperty, ot = 1, Ln = 2, Un = 3, at = 4, yt = 1,
|
|
1665
|
+
}), je = Object.prototype.hasOwnProperty, ot = 1, Ln = 2, Un = 3, at = 4, yt = 1, Aa = 2, zt = 3, Sa = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, xa = /[\x85\u2028\u2029]/, Ta = /[,\[\]\{\}]/, qn = /^(?:!|!!|![a-z\-]+!)$/i, Rn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1666
1666
|
function Jt(e) {
|
|
1667
1667
|
return Object.prototype.toString.call(e);
|
|
1668
1668
|
}
|
|
@@ -1678,21 +1678,21 @@ function he(e) {
|
|
|
1678
1678
|
function Ue(e) {
|
|
1679
1679
|
return e === 44 || e === 91 || e === 93 || e === 123 || e === 125;
|
|
1680
1680
|
}
|
|
1681
|
-
function
|
|
1681
|
+
function $a(e) {
|
|
1682
1682
|
var n;
|
|
1683
1683
|
return 48 <= e && e <= 57 ? e - 48 : (n = e | 32, 97 <= n && n <= 102 ? n - 97 + 10 : -1);
|
|
1684
1684
|
}
|
|
1685
|
-
function
|
|
1685
|
+
function Ma(e) {
|
|
1686
1686
|
return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0;
|
|
1687
1687
|
}
|
|
1688
|
-
function
|
|
1688
|
+
function ja(e) {
|
|
1689
1689
|
return 48 <= e && e <= 57 ? e - 48 : -1;
|
|
1690
1690
|
}
|
|
1691
1691
|
function Wt(e) {
|
|
1692
1692
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? `
|
|
1693
1693
|
` : 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" : "";
|
|
1694
1694
|
}
|
|
1695
|
-
function
|
|
1695
|
+
function Ea(e) {
|
|
1696
1696
|
return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(
|
|
1697
1697
|
(e - 65536 >> 10) + 55296,
|
|
1698
1698
|
(e - 65536 & 1023) + 56320
|
|
@@ -1701,7 +1701,7 @@ function ja(e) {
|
|
|
1701
1701
|
var Vn = new Array(256), Dn = new Array(256);
|
|
1702
1702
|
for (var Pe = 0; Pe < 256; Pe++)
|
|
1703
1703
|
Vn[Pe] = Wt(Pe) ? 1 : 0, Dn[Pe] = Wt(Pe);
|
|
1704
|
-
function
|
|
1704
|
+
function Oa(e, n) {
|
|
1705
1705
|
this.input = e, this.filename = n.filename || null, this.schema = n.schema || $t, this.onWarning = n.onWarning || null, this.legacy = n.legacy || !1, this.json = n.json || !1, this.listener = n.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.firstTabInLine = -1, this.documents = [];
|
|
1706
1706
|
}
|
|
1707
1707
|
function Gn(e, n) {
|
|
@@ -1744,7 +1744,7 @@ function Me(e, n, t, r) {
|
|
|
1744
1744
|
for (o = 0, a = s.length; o < a; o += 1)
|
|
1745
1745
|
i = s.charCodeAt(o), i === 9 || 32 <= i && i <= 1114111 || $(e, "expected valid JSON character");
|
|
1746
1746
|
else
|
|
1747
|
-
|
|
1747
|
+
Sa.test(s) && $(e, "the stream contains non-printable characters");
|
|
1748
1748
|
e.result += s;
|
|
1749
1749
|
}
|
|
1750
1750
|
}
|
|
@@ -1801,7 +1801,7 @@ function jt(e, n) {
|
|
|
1801
1801
|
n === 1 ? e.result += " " : n > 1 && (e.result += se.repeat(`
|
|
1802
1802
|
`, n - 1));
|
|
1803
1803
|
}
|
|
1804
|
-
function
|
|
1804
|
+
function Fa(e, n, t) {
|
|
1805
1805
|
var r, o, a, i, s, l, c, d, u = e.kind, g = e.result, f;
|
|
1806
1806
|
if (f = e.input.charCodeAt(e.position), he(f) || Ue(f) || f === 35 || f === 38 || f === 42 || f === 33 || f === 124 || f === 62 || f === 39 || f === 34 || f === 37 || f === 64 || f === 96 || (f === 63 || f === 45) && (o = e.input.charCodeAt(e.position + 1), he(o) || t && Ue(o)))
|
|
1807
1807
|
return !1;
|
|
@@ -1828,7 +1828,7 @@ function Oa(e, n, t) {
|
|
|
1828
1828
|
}
|
|
1829
1829
|
return Me(e, a, i, !1), e.result ? !0 : (e.kind = u, e.result = g, !1);
|
|
1830
1830
|
}
|
|
1831
|
-
function
|
|
1831
|
+
function Ka(e, n) {
|
|
1832
1832
|
var t, r, o;
|
|
1833
1833
|
if (t = e.input.charCodeAt(e.position), t !== 39)
|
|
1834
1834
|
return !1;
|
|
@@ -1842,7 +1842,7 @@ function Fa(e, n) {
|
|
|
1842
1842
|
we(t) ? (Me(e, r, o, !0), jt(e, oe(e, !1, n)), r = o = e.position) : e.position === e.lineStart && dt(e) ? $(e, "unexpected end of the document within a single quoted scalar") : (e.position++, o = e.position);
|
|
1843
1843
|
$(e, "unexpected end of the stream within a single quoted scalar");
|
|
1844
1844
|
}
|
|
1845
|
-
function
|
|
1845
|
+
function Ba(e, n) {
|
|
1846
1846
|
var t, r, o, a, i, s;
|
|
1847
1847
|
if (s = e.input.charCodeAt(e.position), s !== 34)
|
|
1848
1848
|
return !1;
|
|
@@ -1854,10 +1854,10 @@ function Ka(e, n) {
|
|
|
1854
1854
|
oe(e, !1, n);
|
|
1855
1855
|
else if (s < 256 && Vn[s])
|
|
1856
1856
|
e.result += Dn[s], e.position++;
|
|
1857
|
-
else if ((i =
|
|
1857
|
+
else if ((i = Ma(s)) > 0) {
|
|
1858
1858
|
for (o = i, a = 0; o > 0; o--)
|
|
1859
|
-
s = e.input.charCodeAt(++e.position), (i =
|
|
1860
|
-
e.result +=
|
|
1859
|
+
s = e.input.charCodeAt(++e.position), (i = $a(s)) >= 0 ? a = (a << 4) + i : $(e, "expected hexadecimal character");
|
|
1860
|
+
e.result += Ea(a), e.position++;
|
|
1861
1861
|
} else
|
|
1862
1862
|
$(e, "unknown escape sequence");
|
|
1863
1863
|
t = r = e.position;
|
|
@@ -1867,21 +1867,21 @@ function Ka(e, n) {
|
|
|
1867
1867
|
$(e, "unexpected end of the stream within a double quoted scalar");
|
|
1868
1868
|
}
|
|
1869
1869
|
function Na(e, n) {
|
|
1870
|
-
var t = !0, r, o, a, i = e.tag, s, l = e.anchor, c, d, u, g, f, A = /* @__PURE__ */ Object.create(null),
|
|
1871
|
-
if (
|
|
1870
|
+
var t = !0, r, o, a, i = e.tag, s, l = e.anchor, c, d, u, g, f, A = /* @__PURE__ */ Object.create(null), b, p, S, C;
|
|
1871
|
+
if (C = e.input.charCodeAt(e.position), C === 91)
|
|
1872
1872
|
d = 93, f = !1, s = [];
|
|
1873
|
-
else if (
|
|
1873
|
+
else if (C === 123)
|
|
1874
1874
|
d = 125, f = !0, s = {};
|
|
1875
1875
|
else
|
|
1876
1876
|
return !1;
|
|
1877
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = s),
|
|
1878
|
-
if (oe(e, !0, n),
|
|
1877
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), C = e.input.charCodeAt(++e.position); C !== 0; ) {
|
|
1878
|
+
if (oe(e, !0, n), C = e.input.charCodeAt(e.position), C === d)
|
|
1879
1879
|
return e.position++, e.tag = i, e.anchor = l, e.kind = f ? "mapping" : "sequence", e.result = s, !0;
|
|
1880
|
-
t ?
|
|
1880
|
+
t ? C === 44 && $(e, "expected the node content, but found ','") : $(e, "missed comma between flow collection entries"), p = b = S = null, u = g = !1, C === 63 && (c = e.input.charCodeAt(e.position + 1), he(c) && (u = g = !0, e.position++, oe(e, !0, n))), r = e.line, o = e.lineStart, a = e.position, Re(e, n, ot, !1, !0), p = e.tag, b = e.result, oe(e, !0, n), C = e.input.charCodeAt(e.position), (g || e.line === r) && C === 58 && (u = !0, C = e.input.charCodeAt(++e.position), oe(e, !0, n), Re(e, n, ot, !1, !0), S = e.result), f ? qe(e, s, A, p, b, S, r, o, a) : u ? s.push(qe(e, null, A, p, b, S, r, o, a)) : s.push(b), oe(e, !0, n), C = e.input.charCodeAt(e.position), C === 44 ? (t = !0, C = e.input.charCodeAt(++e.position)) : t = !1;
|
|
1881
1881
|
}
|
|
1882
1882
|
$(e, "unexpected end of the stream within a flow collection");
|
|
1883
1883
|
}
|
|
1884
|
-
function
|
|
1884
|
+
function Pa(e, n) {
|
|
1885
1885
|
var t, r, o = yt, a = !1, i = !1, s = n, l = 0, c = !1, d, u;
|
|
1886
1886
|
if (u = e.input.charCodeAt(e.position), u === 124)
|
|
1887
1887
|
r = !1;
|
|
@@ -1891,8 +1891,8 @@ function Ba(e, n) {
|
|
|
1891
1891
|
return !1;
|
|
1892
1892
|
for (e.kind = "scalar", e.result = ""; u !== 0; )
|
|
1893
1893
|
if (u = e.input.charCodeAt(++e.position), u === 43 || u === 45)
|
|
1894
|
-
yt === o ? o = u === 43 ? zt :
|
|
1895
|
-
else if ((d =
|
|
1894
|
+
yt === o ? o = u === 43 ? zt : Aa : $(e, "repeat of a chomping mode identifier");
|
|
1895
|
+
else if ((d = ja(u)) >= 0)
|
|
1896
1896
|
d === 0 ? $(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : i ? $(e, "repeat of an indentation width identifier") : (s = n + d - 1, i = !0);
|
|
1897
1897
|
else
|
|
1898
1898
|
break;
|
|
@@ -1944,21 +1944,21 @@ function Qt(e, n) {
|
|
|
1944
1944
|
}
|
|
1945
1945
|
return s ? (e.tag = r, e.anchor = o, e.kind = "sequence", e.result = a, !0) : !1;
|
|
1946
1946
|
}
|
|
1947
|
-
function
|
|
1948
|
-
var r, o, a, i, s, l, c = e.tag, d = e.anchor, u = {}, g = /* @__PURE__ */ Object.create(null), f = null, A = null,
|
|
1947
|
+
function La(e, n, t) {
|
|
1948
|
+
var r, o, a, i, s, l, c = e.tag, d = e.anchor, u = {}, g = /* @__PURE__ */ Object.create(null), f = null, A = null, b = null, p = !1, S = !1, C;
|
|
1949
1949
|
if (e.firstTabInLine !== -1)
|
|
1950
1950
|
return !1;
|
|
1951
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = u),
|
|
1952
|
-
if (!p && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, $(e, "tab characters must not be used in indentation")), r = e.input.charCodeAt(e.position + 1), a = e.line, (
|
|
1953
|
-
|
|
1951
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = u), C = e.input.charCodeAt(e.position); C !== 0; ) {
|
|
1952
|
+
if (!p && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, $(e, "tab characters must not be used in indentation")), r = e.input.charCodeAt(e.position + 1), a = e.line, (C === 63 || C === 58) && he(r))
|
|
1953
|
+
C === 63 ? (p && (qe(e, u, g, f, A, null, i, s, l), f = A = b = null), S = !0, p = !0, o = !0) : p ? (p = !1, o = !0) : $(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, C = r;
|
|
1954
1954
|
else {
|
|
1955
1955
|
if (i = e.line, s = e.lineStart, l = e.position, !Re(e, t, Ln, !1, !0))
|
|
1956
1956
|
break;
|
|
1957
1957
|
if (e.line === a) {
|
|
1958
|
-
for (
|
|
1959
|
-
|
|
1960
|
-
if (
|
|
1961
|
-
|
|
1958
|
+
for (C = e.input.charCodeAt(e.position); Fe(C); )
|
|
1959
|
+
C = e.input.charCodeAt(++e.position);
|
|
1960
|
+
if (C === 58)
|
|
1961
|
+
C = e.input.charCodeAt(++e.position), he(C) || $(e, "a whitespace character is expected after the key-value separator within a block mapping"), p && (qe(e, u, g, f, A, null, i, s, l), f = A = b = null), S = !0, p = !1, o = !1, f = e.tag, A = e.result;
|
|
1962
1962
|
else if (S)
|
|
1963
1963
|
$(e, "can not read an implicit mapping pair; a colon is missed");
|
|
1964
1964
|
else
|
|
@@ -1968,14 +1968,14 @@ function Pa(e, n, t) {
|
|
|
1968
1968
|
else
|
|
1969
1969
|
return e.tag = c, e.anchor = d, !0;
|
|
1970
1970
|
}
|
|
1971
|
-
if ((e.line === a || e.lineIndent > n) && (p && (i = e.line, s = e.lineStart, l = e.position), Re(e, n, at, !0, o) && (p ? A = e.result :
|
|
1971
|
+
if ((e.line === a || e.lineIndent > n) && (p && (i = e.line, s = e.lineStart, l = e.position), Re(e, n, at, !0, o) && (p ? A = e.result : b = e.result), p || (qe(e, u, g, f, A, b, i, s, l), f = A = b = null), oe(e, !0, -1), C = e.input.charCodeAt(e.position)), (e.line === a || e.lineIndent > n) && C !== 0)
|
|
1972
1972
|
$(e, "bad indentation of a mapping entry");
|
|
1973
1973
|
else if (e.lineIndent < n)
|
|
1974
1974
|
break;
|
|
1975
1975
|
}
|
|
1976
1976
|
return p && qe(e, u, g, f, A, null, i, s, l), S && (e.tag = c, e.anchor = d, e.kind = "mapping", e.result = u), S;
|
|
1977
1977
|
}
|
|
1978
|
-
function
|
|
1978
|
+
function Ua(e) {
|
|
1979
1979
|
var n, t = !1, r = !1, o, a, i;
|
|
1980
1980
|
if (i = e.input.charCodeAt(e.position), i !== 33)
|
|
1981
1981
|
return !1;
|
|
@@ -1987,7 +1987,7 @@ function La(e) {
|
|
|
1987
1987
|
} else {
|
|
1988
1988
|
for (; i !== 0 && !he(i); )
|
|
1989
1989
|
i === 33 && (r ? $(e, "tag suffix cannot contain exclamation marks") : (o = e.input.slice(n - 1, e.position + 1), qn.test(o) || $(e, "named tag handle cannot contain such characters"), r = !0, n = e.position + 1)), i = e.input.charCodeAt(++e.position);
|
|
1990
|
-
a = e.input.slice(n, e.position),
|
|
1990
|
+
a = e.input.slice(n, e.position), Ta.test(a) && $(e, "tag suffix cannot contain flow indicator characters");
|
|
1991
1991
|
}
|
|
1992
1992
|
a && !Rn.test(a) && $(e, "tag name cannot contain such characters: " + a);
|
|
1993
1993
|
try {
|
|
@@ -1997,7 +1997,7 @@ function La(e) {
|
|
|
1997
1997
|
}
|
|
1998
1998
|
return t ? e.tag = a : je.call(e.tagMap, o) ? e.tag = e.tagMap[o] + a : o === "!" ? e.tag = "!" + a : o === "!!" ? e.tag = "tag:yaml.org,2002:" + a : $(e, 'undeclared tag handle "' + o + '"'), !0;
|
|
1999
1999
|
}
|
|
2000
|
-
function
|
|
2000
|
+
function qa(e) {
|
|
2001
2001
|
var n, t;
|
|
2002
2002
|
if (t = e.input.charCodeAt(e.position), t !== 38)
|
|
2003
2003
|
return !1;
|
|
@@ -2005,7 +2005,7 @@ function Ua(e) {
|
|
|
2005
2005
|
t = e.input.charCodeAt(++e.position);
|
|
2006
2006
|
return e.position === n && $(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(n, e.position), !0;
|
|
2007
2007
|
}
|
|
2008
|
-
function
|
|
2008
|
+
function Ra(e) {
|
|
2009
2009
|
var n, t, r;
|
|
2010
2010
|
if (r = e.input.charCodeAt(e.position), r !== 42)
|
|
2011
2011
|
return !1;
|
|
@@ -2014,11 +2014,11 @@ function qa(e) {
|
|
|
2014
2014
|
return e.position === n && $(e, "name of an alias node must contain at least one character"), t = e.input.slice(n, e.position), je.call(e.anchorMap, t) || $(e, 'unidentified alias "' + t + '"'), e.result = e.anchorMap[t], oe(e, !0, -1), !0;
|
|
2015
2015
|
}
|
|
2016
2016
|
function Re(e, n, t, r, o) {
|
|
2017
|
-
var a, i, s, l = 1, c = !1, d = !1, u, g, f, A,
|
|
2017
|
+
var a, i, s, l = 1, c = !1, d = !1, u, g, f, A, b, p;
|
|
2018
2018
|
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, a = i = s = at === t || Un === t, r && oe(e, !0, -1) && (c = !0, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)), l === 1)
|
|
2019
|
-
for (;
|
|
2019
|
+
for (; Ua(e) || qa(e); )
|
|
2020
2020
|
oe(e, !0, -1) ? (c = !0, s = a, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)) : s = !1;
|
|
2021
|
-
if (s && (s = c || o), (l === 1 || at === t) && (ot === t || Ln === t ?
|
|
2021
|
+
if (s && (s = c || o), (l === 1 || at === t) && (ot === t || Ln === t ? b = n : b = n + 1, p = e.position - e.lineStart, l === 1 ? s && (Qt(e, p) || La(e, p, b)) || Na(e, b) ? d = !0 : (i && Pa(e, b) || Ka(e, b) || Ba(e, b) ? d = !0 : Ra(e) ? (d = !0, (e.tag !== null || e.anchor !== null) && $(e, "alias node should not have any properties")) : Fa(e, b, ot === t) && (d = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : l === 0 && (d = s && Qt(e, p))), e.tag === null)
|
|
2022
2022
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
2023
2023
|
else if (e.tag === "?") {
|
|
2024
2024
|
for (e.result !== null && e.kind !== "scalar" && $(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0, g = e.implicitTypes.length; u < g; u += 1)
|
|
@@ -2039,7 +2039,7 @@ function Re(e, n, t, r, o) {
|
|
|
2039
2039
|
}
|
|
2040
2040
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || d;
|
|
2041
2041
|
}
|
|
2042
|
-
function
|
|
2042
|
+
function Va(e) {
|
|
2043
2043
|
var n = e.position, t, r, o, a = !1, i;
|
|
2044
2044
|
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 && (oe(e, !0, -1), i = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || i !== 37)); ) {
|
|
2045
2045
|
for (a = !0, i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !he(i); )
|
|
@@ -2061,7 +2061,7 @@ function Ra(e) {
|
|
|
2061
2061
|
}
|
|
2062
2062
|
i !== 0 && Mt(e), je.call(Yt, r) ? Yt[r](e, r, o) : it(e, 'unknown document directive "' + r + '"');
|
|
2063
2063
|
}
|
|
2064
|
-
if (oe(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, oe(e, !0, -1)) : a && $(e, "directives end mark is expected"), Re(e, e.lineIndent - 1, at, !1, !0), oe(e, !0, -1), e.checkLineBreaks &&
|
|
2064
|
+
if (oe(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, oe(e, !0, -1)) : a && $(e, "directives end mark is expected"), Re(e, e.lineIndent - 1, at, !1, !0), oe(e, !0, -1), e.checkLineBreaks && xa.test(e.input.slice(n, e.position)) && it(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && dt(e)) {
|
|
2065
2065
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, oe(e, !0, -1));
|
|
2066
2066
|
return;
|
|
2067
2067
|
}
|
|
@@ -2073,14 +2073,14 @@ function Ra(e) {
|
|
|
2073
2073
|
function Hn(e, n) {
|
|
2074
2074
|
e = String(e), n = n || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2075
2075
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2076
|
-
var t = new
|
|
2076
|
+
var t = new Oa(e, n), r = e.indexOf("\0");
|
|
2077
2077
|
for (r !== -1 && (t.position = r, $(t, "null byte is not allowed in input")), t.input += "\0"; t.input.charCodeAt(t.position) === 32; )
|
|
2078
2078
|
t.lineIndent += 1, t.position += 1;
|
|
2079
2079
|
for (; t.position < t.length - 1; )
|
|
2080
|
-
|
|
2080
|
+
Va(t);
|
|
2081
2081
|
return t.documents;
|
|
2082
2082
|
}
|
|
2083
|
-
function
|
|
2083
|
+
function Da(e, n, t) {
|
|
2084
2084
|
n !== null && typeof n == "object" && typeof t > "u" && (t = n, n = null);
|
|
2085
2085
|
var r = Hn(e, t);
|
|
2086
2086
|
if (typeof n != "function")
|
|
@@ -2088,7 +2088,7 @@ function Va(e, n, t) {
|
|
|
2088
2088
|
for (var o = 0, a = r.length; o < a; o += 1)
|
|
2089
2089
|
n(r[o]);
|
|
2090
2090
|
}
|
|
2091
|
-
function
|
|
2091
|
+
function Ga(e, n) {
|
|
2092
2092
|
var t = Hn(e, n);
|
|
2093
2093
|
if (t.length !== 0) {
|
|
2094
2094
|
if (t.length === 1)
|
|
@@ -2096,10 +2096,10 @@ function Da(e, n) {
|
|
|
2096
2096
|
throw new me("expected a single document in the stream, but found more");
|
|
2097
2097
|
}
|
|
2098
2098
|
}
|
|
2099
|
-
var
|
|
2100
|
-
loadAll:
|
|
2101
|
-
load:
|
|
2102
|
-
}, Jn = Object.prototype.toString, Wn = Object.prototype.hasOwnProperty, Et = 65279,
|
|
2099
|
+
var Ha = Da, za = Ga, zn = {
|
|
2100
|
+
loadAll: Ha,
|
|
2101
|
+
load: za
|
|
2102
|
+
}, Jn = Object.prototype.toString, Wn = Object.prototype.hasOwnProperty, Et = 65279, Ja = 9, We = 10, Wa = 13, Ya = 32, Za = 33, Qa = 34, bt = 35, Xa = 37, ei = 38, ti = 39, ni = 42, Yn = 44, ri = 45, st = 58, oi = 61, ai = 62, ii = 63, si = 64, Zn = 91, Qn = 93, li = 96, Xn = 123, ui = 124, er = 125, fe = {};
|
|
2103
2103
|
fe[0] = "\\0";
|
|
2104
2104
|
fe[7] = "\\a";
|
|
2105
2105
|
fe[8] = "\\b";
|
|
@@ -2115,7 +2115,7 @@ fe[133] = "\\N";
|
|
|
2115
2115
|
fe[160] = "\\_";
|
|
2116
2116
|
fe[8232] = "\\L";
|
|
2117
2117
|
fe[8233] = "\\P";
|
|
2118
|
-
var
|
|
2118
|
+
var ci = [
|
|
2119
2119
|
"y",
|
|
2120
2120
|
"Y",
|
|
2121
2121
|
"yes",
|
|
@@ -2132,8 +2132,8 @@ var ui = [
|
|
|
2132
2132
|
"off",
|
|
2133
2133
|
"Off",
|
|
2134
2134
|
"OFF"
|
|
2135
|
-
],
|
|
2136
|
-
function
|
|
2135
|
+
], di = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2136
|
+
function pi(e, n) {
|
|
2137
2137
|
var t, r, o, a, i, s, l;
|
|
2138
2138
|
if (n === null)
|
|
2139
2139
|
return {};
|
|
@@ -2141,7 +2141,7 @@ function di(e, n) {
|
|
|
2141
2141
|
i = r[o], s = String(n[i]), i.slice(0, 2) === "!!" && (i = "tag:yaml.org,2002:" + i.slice(2)), l = e.compiledTypeMap.fallback[i], l && Wn.call(l.styleAliases, s) && (s = l.styleAliases[s]), t[i] = s;
|
|
2142
2142
|
return t;
|
|
2143
2143
|
}
|
|
2144
|
-
function
|
|
2144
|
+
function fi(e) {
|
|
2145
2145
|
var n, t, r;
|
|
2146
2146
|
if (n = e.toString(16).toUpperCase(), e <= 255)
|
|
2147
2147
|
t = "x", r = 2;
|
|
@@ -2153,9 +2153,9 @@ function pi(e) {
|
|
|
2153
2153
|
throw new me("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2154
2154
|
return "\\" + t + se.repeat("0", r - n.length) + n;
|
|
2155
2155
|
}
|
|
2156
|
-
var
|
|
2157
|
-
function
|
|
2158
|
-
this.schema = e.schema || $t, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = se.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap =
|
|
2156
|
+
var mi = 1, Ye = 2;
|
|
2157
|
+
function gi(e) {
|
|
2158
|
+
this.schema = e.schema || $t, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = se.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = pi(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 === '"' ? Ye : mi, 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;
|
|
2159
2159
|
}
|
|
2160
2160
|
function Xt(e, n) {
|
|
2161
2161
|
for (var t = se.repeat(" ", n), r = 0, o = -1, a = "", i, s = e.length; r < s; )
|
|
@@ -2168,7 +2168,7 @@ function Ct(e, n) {
|
|
|
2168
2168
|
return `
|
|
2169
2169
|
` + se.repeat(" ", e.indent * n);
|
|
2170
2170
|
}
|
|
2171
|
-
function
|
|
2171
|
+
function yi(e, n) {
|
|
2172
2172
|
var t, r, o;
|
|
2173
2173
|
for (t = 0, r = e.implicitTypes.length; t < r; t += 1)
|
|
2174
2174
|
if (o = e.implicitTypes[t], o.resolve(n))
|
|
@@ -2176,13 +2176,13 @@ function gi(e, n) {
|
|
|
2176
2176
|
return !1;
|
|
2177
2177
|
}
|
|
2178
2178
|
function lt(e) {
|
|
2179
|
-
return e ===
|
|
2179
|
+
return e === Ya || e === Ja;
|
|
2180
2180
|
}
|
|
2181
2181
|
function Ze(e) {
|
|
2182
2182
|
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== Et || 65536 <= e && e <= 1114111;
|
|
2183
2183
|
}
|
|
2184
2184
|
function en(e) {
|
|
2185
|
-
return Ze(e) && e !== Et && e !==
|
|
2185
|
+
return Ze(e) && e !== Et && e !== Wa && e !== We;
|
|
2186
2186
|
}
|
|
2187
2187
|
function tn(e, n, t) {
|
|
2188
2188
|
var r = en(e), o = r && !lt(e);
|
|
@@ -2194,10 +2194,10 @@ function tn(e, n, t) {
|
|
|
2194
2194
|
) : r && e !== Yn && e !== Zn && e !== Qn && e !== Xn && e !== er) && e !== bt && !(n === st && !o) || en(n) && !lt(n) && e === bt || n === st && o
|
|
2195
2195
|
);
|
|
2196
2196
|
}
|
|
2197
|
-
function yi(e) {
|
|
2198
|
-
return Ze(e) && e !== Et && !lt(e) && e !== ni && e !== ai && e !== st && e !== Yn && e !== Zn && e !== Qn && e !== Xn && e !== er && e !== bt && e !== Xa && e !== ti && e !== Ya && e !== li && e !== ri && e !== oi && e !== ei && e !== Za && e !== Qa && e !== ii && e !== si;
|
|
2199
|
-
}
|
|
2200
2197
|
function hi(e) {
|
|
2198
|
+
return Ze(e) && e !== Et && !lt(e) && e !== ri && e !== ii && e !== st && e !== Yn && e !== Zn && e !== Qn && e !== Xn && e !== er && e !== bt && e !== ei && e !== ni && e !== Za && e !== ui && e !== oi && e !== ai && e !== ti && e !== Qa && e !== Xa && e !== si && e !== li;
|
|
2199
|
+
}
|
|
2200
|
+
function vi(e) {
|
|
2201
2201
|
return !lt(e) && e !== st;
|
|
2202
2202
|
}
|
|
2203
2203
|
function He(e, n) {
|
|
@@ -2209,13 +2209,13 @@ function tr(e) {
|
|
|
2209
2209
|
return n.test(e);
|
|
2210
2210
|
}
|
|
2211
2211
|
var nr = 1, kt = 2, rr = 3, or = 4, Le = 5;
|
|
2212
|
-
function
|
|
2213
|
-
var l, c = 0, d = null, u = !1, g = !1, f = r !== -1, A = -1,
|
|
2212
|
+
function bi(e, n, t, r, o, a, i, s) {
|
|
2213
|
+
var l, c = 0, d = null, u = !1, g = !1, f = r !== -1, A = -1, b = hi(He(e, 0)) && vi(He(e, e.length - 1));
|
|
2214
2214
|
if (n || i)
|
|
2215
2215
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2216
2216
|
if (c = He(e, l), !Ze(c))
|
|
2217
2217
|
return Le;
|
|
2218
|
-
|
|
2218
|
+
b = b && tn(c, d, s), d = c;
|
|
2219
2219
|
}
|
|
2220
2220
|
else {
|
|
2221
2221
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
@@ -2224,23 +2224,23 @@ function vi(e, n, t, r, o, a, i, s) {
|
|
|
2224
2224
|
l - A - 1 > r && e[A + 1] !== " ", A = l);
|
|
2225
2225
|
else if (!Ze(c))
|
|
2226
2226
|
return Le;
|
|
2227
|
-
|
|
2227
|
+
b = b && tn(c, d, s), d = c;
|
|
2228
2228
|
}
|
|
2229
2229
|
g = g || f && l - A - 1 > r && e[A + 1] !== " ";
|
|
2230
2230
|
}
|
|
2231
|
-
return !u && !g ?
|
|
2231
|
+
return !u && !g ? b && !i && !o(e) ? nr : a === Ye ? Le : kt : t > 9 && tr(e) ? Le : i ? a === Ye ? Le : kt : g ? or : rr;
|
|
2232
2232
|
}
|
|
2233
|
-
function
|
|
2233
|
+
function Ci(e, n, t, r, o) {
|
|
2234
2234
|
e.dump = function() {
|
|
2235
2235
|
if (n.length === 0)
|
|
2236
2236
|
return e.quotingType === Ye ? '""' : "''";
|
|
2237
|
-
if (!e.noCompatMode && (
|
|
2237
|
+
if (!e.noCompatMode && (ci.indexOf(n) !== -1 || di.test(n)))
|
|
2238
2238
|
return e.quotingType === Ye ? '"' + n + '"' : "'" + n + "'";
|
|
2239
2239
|
var a = e.indent * Math.max(1, t), i = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - a), s = r || e.flowLevel > -1 && t >= e.flowLevel;
|
|
2240
2240
|
function l(c) {
|
|
2241
|
-
return
|
|
2241
|
+
return yi(e, c);
|
|
2242
2242
|
}
|
|
2243
|
-
switch (
|
|
2243
|
+
switch (bi(
|
|
2244
2244
|
n,
|
|
2245
2245
|
s,
|
|
2246
2246
|
e.indent,
|
|
@@ -2257,9 +2257,9 @@ function bi(e, n, t, r, o) {
|
|
|
2257
2257
|
case rr:
|
|
2258
2258
|
return "|" + nn(n, e.indent) + rn(Xt(n, a));
|
|
2259
2259
|
case or:
|
|
2260
|
-
return ">" + nn(n, e.indent) + rn(Xt(
|
|
2260
|
+
return ">" + nn(n, e.indent) + rn(Xt(ki(n, i), a));
|
|
2261
2261
|
case Le:
|
|
2262
|
-
return '"' +
|
|
2262
|
+
return '"' + _i(n) + '"';
|
|
2263
2263
|
default:
|
|
2264
2264
|
throw new me("impossible error: invalid scalar style");
|
|
2265
2265
|
}
|
|
@@ -2277,7 +2277,7 @@ function rn(e) {
|
|
|
2277
2277
|
return e[e.length - 1] === `
|
|
2278
2278
|
` ? e.slice(0, -1) : e;
|
|
2279
2279
|
}
|
|
2280
|
-
function
|
|
2280
|
+
function ki(e, n) {
|
|
2281
2281
|
for (var t = /(\n+)([^\n]*)/g, r = function() {
|
|
2282
2282
|
var c = e.indexOf(`
|
|
2283
2283
|
`);
|
|
@@ -2300,12 +2300,12 @@ function on(e, n) {
|
|
|
2300
2300
|
`, e.length - o > n && i > o ? l += e.slice(o, i) + `
|
|
2301
2301
|
` + e.slice(i + 1) : l += e.slice(o), l.slice(1);
|
|
2302
2302
|
}
|
|
2303
|
-
function
|
|
2303
|
+
function _i(e) {
|
|
2304
2304
|
for (var n = "", t = 0, r, o = 0; o < e.length; t >= 65536 ? o += 2 : o++)
|
|
2305
|
-
t = He(e, o), r = fe[t], !r && Ze(t) ? (n += e[o], t >= 65536 && (n += e[o + 1])) : n += r ||
|
|
2305
|
+
t = He(e, o), r = fe[t], !r && Ze(t) ? (n += e[o], t >= 65536 && (n += e[o + 1])) : n += r || fi(t);
|
|
2306
2306
|
return n;
|
|
2307
2307
|
}
|
|
2308
|
-
function
|
|
2308
|
+
function wi(e, n, t) {
|
|
2309
2309
|
var r = "", o = e.tag, a, i, s;
|
|
2310
2310
|
for (a = 0, i = t.length; a < i; a += 1)
|
|
2311
2311
|
s = t[a], e.replacer && (s = e.replacer.call(t, String(a), s)), (Se(e, n, s, !1, !1) || typeof s > "u" && Se(e, n, null, !1, !1)) && (r !== "" && (r += "," + (e.condenseFlow ? "" : " ")), r += e.dump);
|
|
@@ -2317,13 +2317,13 @@ function an(e, n, t, r) {
|
|
|
2317
2317
|
l = t[i], e.replacer && (l = e.replacer.call(t, String(i), l)), (Se(e, n + 1, l, !0, !0, !1, !0) || typeof l > "u" && Se(e, n + 1, null, !0, !0, !1, !0)) && ((!r || o !== "") && (o += Ct(e, n)), e.dump && We === e.dump.charCodeAt(0) ? o += "-" : o += "- ", o += e.dump);
|
|
2318
2318
|
e.tag = a, e.dump = o || "[]";
|
|
2319
2319
|
}
|
|
2320
|
-
function
|
|
2320
|
+
function Ii(e, n, t) {
|
|
2321
2321
|
var r = "", o = e.tag, a = Object.keys(t), i, s, l, c, d;
|
|
2322
2322
|
for (i = 0, s = a.length; i < s; i += 1)
|
|
2323
2323
|
d = "", r !== "" && (d += ", "), e.condenseFlow && (d += '"'), l = a[i], c = t[l], e.replacer && (c = e.replacer.call(t, l, c)), Se(e, n, l, !1, !1) && (e.dump.length > 1024 && (d += "? "), d += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Se(e, n, c, !1, !1) && (d += e.dump, r += d));
|
|
2324
2324
|
e.tag = o, e.dump = "{" + r + "}";
|
|
2325
2325
|
}
|
|
2326
|
-
function
|
|
2326
|
+
function Ai(e, n, t, r) {
|
|
2327
2327
|
var o = "", a = e.tag, i = Object.keys(t), s, l, c, d, u, g;
|
|
2328
2328
|
if (e.sortKeys === !0)
|
|
2329
2329
|
i.sort();
|
|
@@ -2361,11 +2361,11 @@ function Se(e, n, t, r, o, a, i) {
|
|
|
2361
2361
|
e.dump = "*ref_" + u;
|
|
2362
2362
|
else {
|
|
2363
2363
|
if (d && g && !e.usedDuplicates[u] && (e.usedDuplicates[u] = !0), s === "[object Object]")
|
|
2364
|
-
r && Object.keys(e.dump).length !== 0 ? (
|
|
2364
|
+
r && Object.keys(e.dump).length !== 0 ? (Ai(e, n, e.dump, o), g && (e.dump = "&ref_" + u + e.dump)) : (Ii(e, n, e.dump), g && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2365
2365
|
else if (s === "[object Array]")
|
|
2366
|
-
r && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? an(e, n - 1, e.dump, o) : an(e, n, e.dump, o), g && (e.dump = "&ref_" + u + e.dump)) : (
|
|
2366
|
+
r && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? an(e, n - 1, e.dump, o) : an(e, n, e.dump, o), g && (e.dump = "&ref_" + u + e.dump)) : (wi(e, n, e.dump), g && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2367
2367
|
else if (s === "[object String]")
|
|
2368
|
-
e.tag !== "?" &&
|
|
2368
|
+
e.tag !== "?" && Ci(e, e.dump, n, a, l);
|
|
2369
2369
|
else {
|
|
2370
2370
|
if (s === "[object Undefined]" || e.skipInvalid)
|
|
2371
2371
|
return !1;
|
|
@@ -2377,7 +2377,7 @@ function Se(e, n, t, r, o, a, i) {
|
|
|
2377
2377
|
}
|
|
2378
2378
|
return !0;
|
|
2379
2379
|
}
|
|
2380
|
-
function
|
|
2380
|
+
function Si(e, n) {
|
|
2381
2381
|
var t = [], r = [], o, a;
|
|
2382
2382
|
for (_t(e, t, r), o = 0, a = r.length; o < a; o += 1)
|
|
2383
2383
|
n.duplicates.push(t[r[o]]);
|
|
@@ -2395,65 +2395,65 @@ function _t(e, n, t) {
|
|
|
2395
2395
|
for (r = Object.keys(e), o = 0, a = r.length; o < a; o += 1)
|
|
2396
2396
|
_t(e[r[o]], n, t);
|
|
2397
2397
|
}
|
|
2398
|
-
function
|
|
2398
|
+
function xi(e, n) {
|
|
2399
2399
|
n = n || {};
|
|
2400
|
-
var t = new
|
|
2401
|
-
t.noRefs ||
|
|
2400
|
+
var t = new gi(n);
|
|
2401
|
+
t.noRefs || Si(e, t);
|
|
2402
2402
|
var r = e;
|
|
2403
2403
|
return t.replacer && (r = t.replacer.call({ "": r }, "", r)), Se(t, 0, r, !0, !0) ? t.dump + `
|
|
2404
2404
|
` : "";
|
|
2405
2405
|
}
|
|
2406
|
-
var
|
|
2407
|
-
dump:
|
|
2406
|
+
var Ti = xi, $i = {
|
|
2407
|
+
dump: Ti
|
|
2408
2408
|
};
|
|
2409
2409
|
function Ot(e, n) {
|
|
2410
2410
|
return function() {
|
|
2411
2411
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + n + " instead, which is now safe by default.");
|
|
2412
2412
|
};
|
|
2413
2413
|
}
|
|
2414
|
-
var
|
|
2414
|
+
var Mi = de, ji = Cn, Ei = In, Oi = $n, Fi = Mn, Ki = $t, Bi = zn.load, Ni = zn.loadAll, Pi = $i.dump, Li = me, Ui = {
|
|
2415
2415
|
binary: Kn,
|
|
2416
2416
|
float: Tn,
|
|
2417
2417
|
map: wn,
|
|
2418
2418
|
null: An,
|
|
2419
|
-
pairs:
|
|
2419
|
+
pairs: Nn,
|
|
2420
2420
|
set: Pn,
|
|
2421
2421
|
timestamp: On,
|
|
2422
2422
|
bool: Sn,
|
|
2423
2423
|
int: xn,
|
|
2424
2424
|
merge: Fn,
|
|
2425
|
-
omap:
|
|
2425
|
+
omap: Bn,
|
|
2426
2426
|
seq: _n,
|
|
2427
2427
|
str: kn
|
|
2428
|
-
},
|
|
2429
|
-
Type:
|
|
2430
|
-
Schema:
|
|
2431
|
-
FAILSAFE_SCHEMA:
|
|
2432
|
-
JSON_SCHEMA:
|
|
2433
|
-
CORE_SCHEMA:
|
|
2434
|
-
DEFAULT_SCHEMA:
|
|
2435
|
-
load:
|
|
2428
|
+
}, qi = Ot("safeLoad", "load"), Ri = Ot("safeLoadAll", "loadAll"), Vi = Ot("safeDump", "dump"), Di = {
|
|
2429
|
+
Type: Mi,
|
|
2430
|
+
Schema: ji,
|
|
2431
|
+
FAILSAFE_SCHEMA: Ei,
|
|
2432
|
+
JSON_SCHEMA: Oi,
|
|
2433
|
+
CORE_SCHEMA: Fi,
|
|
2434
|
+
DEFAULT_SCHEMA: Ki,
|
|
2435
|
+
load: Bi,
|
|
2436
2436
|
loadAll: Ni,
|
|
2437
|
-
dump:
|
|
2438
|
-
YAMLException:
|
|
2439
|
-
types:
|
|
2440
|
-
safeLoad:
|
|
2441
|
-
safeLoadAll:
|
|
2442
|
-
safeDump:
|
|
2437
|
+
dump: Pi,
|
|
2438
|
+
YAMLException: Li,
|
|
2439
|
+
types: Ui,
|
|
2440
|
+
safeLoad: qi,
|
|
2441
|
+
safeLoadAll: Ri,
|
|
2442
|
+
safeDump: Vi
|
|
2443
2443
|
};
|
|
2444
|
-
const
|
|
2444
|
+
const Gi = {
|
|
2445
2445
|
key: 0,
|
|
2446
2446
|
class: "config-card-display-form"
|
|
2447
|
-
},
|
|
2447
|
+
}, Hi = ["data-testid"], zi = {
|
|
2448
2448
|
key: 0,
|
|
2449
2449
|
class: "config-card-prop-section-title"
|
|
2450
|
-
},
|
|
2450
|
+
}, Ji = {
|
|
2451
2451
|
key: 1,
|
|
2452
2452
|
class: "config-card-display-json"
|
|
2453
|
-
},
|
|
2453
|
+
}, Wi = {
|
|
2454
2454
|
key: 2,
|
|
2455
2455
|
class: "config-card-display-yaml"
|
|
2456
|
-
},
|
|
2456
|
+
}, Yi = /* @__PURE__ */ ae({
|
|
2457
2457
|
__name: "ConfigCardDisplay",
|
|
2458
2458
|
props: {
|
|
2459
2459
|
propertyCollections: {
|
|
@@ -2481,17 +2481,17 @@ const Di = {
|
|
|
2481
2481
|
setup(e) {
|
|
2482
2482
|
const n = e, t = ut(), { i18n: { t: r } } = ue.useI18n(), o = (s) => !!(s.tooltip || t[`${s.key}-label-tooltip`]), a = O(""), i = O("");
|
|
2483
2483
|
return xe(() => n.format, (s) => {
|
|
2484
|
-
s === "json" ? a.value = JSON.stringify(n.record, null, 2) : s === "yaml" && (i.value =
|
|
2484
|
+
s === "json" ? a.value = JSON.stringify(n.record, null, 2) : s === "yaml" && (i.value = Di.dump(n.record));
|
|
2485
2485
|
}, { immediate: !0 }), (s, l) => {
|
|
2486
2486
|
const c = U("KCodeBlock");
|
|
2487
2487
|
return m(), j(ve, null, [
|
|
2488
|
-
e.format === "structured" ? (m(), j("div",
|
|
2488
|
+
e.format === "structured" ? (m(), j("div", Gi, [
|
|
2489
2489
|
(m(!0), j(ve, null, ye(e.propListTypes, (d) => (m(), j("div", {
|
|
2490
2490
|
key: `config-card-details-${d}-props`,
|
|
2491
2491
|
class: Ke(`config-card-details-${d}-props`),
|
|
2492
2492
|
"data-testid": `config-card-details-${d}-props`
|
|
2493
2493
|
}, [
|
|
2494
|
-
d !== "basic" ? (m(), j("div",
|
|
2494
|
+
d !== "basic" ? (m(), j("div", zi, F(d === "advanced" ? y(r)("baseConfigCard.sections.advanced") : y(r)("baseConfigCard.sections.plugin")), 1)) : G("", !0),
|
|
2495
2495
|
(m(!0), j(ve, null, ye(e.propertyCollections[d], (u) => (m(), V(xt, {
|
|
2496
2496
|
key: u.key,
|
|
2497
2497
|
item: u
|
|
@@ -2515,9 +2515,9 @@ const Di = {
|
|
|
2515
2515
|
key: "0"
|
|
2516
2516
|
} : void 0
|
|
2517
2517
|
]), 1032, ["item"]))), 128))
|
|
2518
|
-
], 10,
|
|
2518
|
+
], 10, Hi))), 128))
|
|
2519
2519
|
])) : G("", !0),
|
|
2520
|
-
e.format === "json" ? (m(), j("div",
|
|
2520
|
+
e.format === "json" ? (m(), j("div", Ji, [
|
|
2521
2521
|
K(c, {
|
|
2522
2522
|
id: "config-card-codeblock",
|
|
2523
2523
|
code: a.value,
|
|
@@ -2525,7 +2525,7 @@ const Di = {
|
|
|
2525
2525
|
theme: "dark"
|
|
2526
2526
|
}, null, 8, ["code"])
|
|
2527
2527
|
])) : G("", !0),
|
|
2528
|
-
e.format === "yaml" ? (m(), j("div",
|
|
2528
|
+
e.format === "yaml" ? (m(), j("div", Wi, [
|
|
2529
2529
|
K(c, {
|
|
2530
2530
|
id: "config-card-codeblock",
|
|
2531
2531
|
code: i.value,
|
|
@@ -2536,18 +2536,18 @@ const Di = {
|
|
|
2536
2536
|
], 64);
|
|
2537
2537
|
};
|
|
2538
2538
|
}
|
|
2539
|
-
}),
|
|
2539
|
+
}), Zi = /* @__PURE__ */ ke(Yi, [["__scopeId", "data-v-6c45e9e4"]]), ln = "24px", Qi = (e, n) => {
|
|
2540
2540
|
const t = e.__vccOpts || e;
|
|
2541
2541
|
for (const [r, o] of n)
|
|
2542
2542
|
t[r] = o;
|
|
2543
2543
|
return t;
|
|
2544
|
-
},
|
|
2544
|
+
}, Xi = (e) => (hr("data-v-dd88a2bb"), e = e(), vr(), e), es = ["aria-hidden"], ts = {
|
|
2545
2545
|
key: 0,
|
|
2546
2546
|
"data-testid": "kui-icon-svg-title"
|
|
2547
|
-
},
|
|
2547
|
+
}, ns = /* @__PURE__ */ Xi(() => /* @__PURE__ */ R("path", {
|
|
2548
2548
|
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",
|
|
2549
2549
|
fill: "currentColor"
|
|
2550
|
-
}, null, -1)),
|
|
2550
|
+
}, null, -1)), rs = /* @__PURE__ */ ae({
|
|
2551
2551
|
__name: "BookIcon",
|
|
2552
2552
|
props: {
|
|
2553
2553
|
/** The accessibility text provided to screen readers */
|
|
@@ -2620,7 +2620,7 @@ const Di = {
|
|
|
2620
2620
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2621
2621
|
class: "kui-icon book-icon",
|
|
2622
2622
|
"data-testid": "kui-icon-wrapper-book-icon",
|
|
2623
|
-
style:
|
|
2623
|
+
style: gr(r.value)
|
|
2624
2624
|
}, {
|
|
2625
2625
|
default: h(() => [
|
|
2626
2626
|
(m(), j("svg", {
|
|
@@ -2633,23 +2633,23 @@ const Di = {
|
|
|
2633
2633
|
width: "100%",
|
|
2634
2634
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2635
2635
|
}, [
|
|
2636
|
-
e.title ? (m(), j("title",
|
|
2637
|
-
|
|
2638
|
-
], 8,
|
|
2636
|
+
e.title ? (m(), j("title", ts, F(e.title), 1)) : G("", !0),
|
|
2637
|
+
ns
|
|
2638
|
+
], 8, es))
|
|
2639
2639
|
]),
|
|
2640
2640
|
_: 1
|
|
2641
2641
|
}, 8, ["aria-hidden", "style"]));
|
|
2642
2642
|
}
|
|
2643
|
-
}),
|
|
2643
|
+
}), os = /* @__PURE__ */ Qi(rs, [["__scopeId", "data-v-dd88a2bb"]]), as = { "data-testid": "config-card-title" }, is = { class: "config-card-actions" }, ss = ["href"], ls = {
|
|
2644
2644
|
key: 2,
|
|
2645
2645
|
class: "config-card-details-section"
|
|
2646
|
-
},
|
|
2646
|
+
}, us = {
|
|
2647
2647
|
key: 3,
|
|
2648
2648
|
class: "config-card-details-section"
|
|
2649
|
-
},
|
|
2649
|
+
}, cs = ["data-testid"], ds = {
|
|
2650
2650
|
key: 0,
|
|
2651
2651
|
class: "config-card-prop-section-title"
|
|
2652
|
-
},
|
|
2652
|
+
}, ps = /* @__PURE__ */ ae({
|
|
2653
2653
|
__name: "EntityBaseConfigCard",
|
|
2654
2654
|
props: {
|
|
2655
2655
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2776,13 +2776,13 @@ const Di = {
|
|
|
2776
2776
|
// the last property displayed
|
|
2777
2777
|
section: be.Basic
|
|
2778
2778
|
}
|
|
2779
|
-
}, f = O(!1), A = O(!1),
|
|
2780
|
-
var w,
|
|
2779
|
+
}, f = O(!1), A = O(!1), b = O(""), p = O(), S = M(() => {
|
|
2780
|
+
var w, B, N;
|
|
2781
2781
|
if (!p.value)
|
|
2782
2782
|
return [];
|
|
2783
2783
|
const k = [], x = Object.keys(p.value).length;
|
|
2784
2784
|
for (const T in p.value) {
|
|
2785
|
-
const P = (
|
|
2785
|
+
const P = (B = (w = r.configSchema) == null ? void 0 : w[T]) == null ? void 0 : B.order, J = (N = g[T]) == null ? void 0 : N.order;
|
|
2786
2786
|
let Q = x;
|
|
2787
2787
|
(J || J === 0) && (Q = J === -1 ? x + 1 : J), P && (Q = P === -1 ? x + 1 : P), k.push([T, Q]);
|
|
2788
2788
|
}
|
|
@@ -2801,13 +2801,13 @@ const Di = {
|
|
|
2801
2801
|
section: ee.section ?? ((ie == null ? void 0 : ie.section) || be.Advanced)
|
|
2802
2802
|
};
|
|
2803
2803
|
}).filter((T) => !T.hidden && T.key !== r.pluginConfigKey);
|
|
2804
|
-
}),
|
|
2805
|
-
var w,
|
|
2804
|
+
}), C = M(() => {
|
|
2805
|
+
var w, B;
|
|
2806
2806
|
if (!p.value || !r.pluginConfigKey)
|
|
2807
2807
|
return [];
|
|
2808
|
-
const
|
|
2809
|
-
for (const T in
|
|
2810
|
-
const P = (
|
|
2808
|
+
const N = p.value[r.pluginConfigKey] || {}, k = Object.keys(N).length, x = [];
|
|
2809
|
+
for (const T in N) {
|
|
2810
|
+
const P = (B = (w = r.pluginConfigSchema) == null ? void 0 : w[T]) == null ? void 0 : B.order, J = N[T];
|
|
2811
2811
|
let Q = J != null && J !== "" ? k - 1 : k;
|
|
2812
2812
|
P && (Q = P === -1 ? k + 1 : P), x.push([T, Q]);
|
|
2813
2813
|
}
|
|
@@ -2815,7 +2815,7 @@ const Di = {
|
|
|
2815
2815
|
return T[1] - P[1];
|
|
2816
2816
|
}), x.map((T) => {
|
|
2817
2817
|
var P;
|
|
2818
|
-
const J = T[0], Q =
|
|
2818
|
+
const J = T[0], Q = N[J], X = ((P = r.pluginConfigSchema) == null ? void 0 : P[J]) || {};
|
|
2819
2819
|
return {
|
|
2820
2820
|
key: J,
|
|
2821
2821
|
value: Q,
|
|
@@ -2826,20 +2826,20 @@ const Di = {
|
|
|
2826
2826
|
section: be.Plugin
|
|
2827
2827
|
};
|
|
2828
2828
|
}).filter((T) => !T.hidden);
|
|
2829
|
-
}),
|
|
2830
|
-
var w,
|
|
2829
|
+
}), v = M(() => {
|
|
2830
|
+
var w, B, N, k;
|
|
2831
2831
|
return {
|
|
2832
2832
|
basic: (w = S.value) == null ? void 0 : w.filter((x) => x.section === be.Basic),
|
|
2833
|
-
advanced: (
|
|
2834
|
-
plugin: (k =
|
|
2833
|
+
advanced: (B = S.value) == null ? void 0 : B.filter((x) => x.section === be.Advanced),
|
|
2834
|
+
plugin: (k = C.value) == null ? void 0 : k.concat((N = S.value) == null ? void 0 : N.filter((x) => x.section === be.Plugin))
|
|
2835
2835
|
};
|
|
2836
2836
|
}), I = M(() => {
|
|
2837
2837
|
const w = [];
|
|
2838
|
-
return
|
|
2838
|
+
return v.value.basic.length && w.push("basic"), v.value.advanced.length && w.push("advanced"), v.value.plugin.length && w.push("plugin"), w;
|
|
2839
2839
|
}), ne = (w) => !!(w.tooltip || o[`${w.key}-label-tooltip`]), pe = M(() => {
|
|
2840
|
-
var w,
|
|
2841
|
-
let
|
|
2842
|
-
return r.config.app === "konnect" ?
|
|
2840
|
+
var w, B;
|
|
2841
|
+
let N = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
2842
|
+
return r.config.app === "konnect" ? N = N.replace(/{controlPlaneId}/gi, ((w = r.config) == null ? void 0 : w.controlPlaneId) || "") : r.config.app === "kongManager" && (N = N.replace(/\/{workspace}/gi, (B = r.config) != null && B.workspace ? `/${r.config.workspace}` : "")), N = N.replace(/{id}/gi, r.config.entityId), N;
|
|
2843
2843
|
}), H = (w) => {
|
|
2844
2844
|
p.value && w(JSON.stringify(p.value)) ? n("copy:success", p.value) : n("copy:error");
|
|
2845
2845
|
};
|
|
@@ -2856,22 +2856,22 @@ const Di = {
|
|
|
2856
2856
|
throw new Error(a("errors.dataKeyUndefined", { dataKey: r.dataKey }));
|
|
2857
2857
|
else
|
|
2858
2858
|
p.value = { ...w };
|
|
2859
|
-
Object.keys(r.configSchema).filter((
|
|
2860
|
-
p.value && typeof p.value[
|
|
2859
|
+
Object.keys(r.configSchema).filter((B) => r.configSchema[B].forceShow).forEach((B) => {
|
|
2860
|
+
p.value && typeof p.value[B] > "u" && (p.value[B] = null);
|
|
2861
2861
|
}), n("fetch:success", w);
|
|
2862
2862
|
} catch (w) {
|
|
2863
|
-
const
|
|
2864
|
-
|
|
2863
|
+
const B = i(w);
|
|
2864
|
+
b.value = B.startsWith("code") ? a("baseConfigCard.errors.load") : B, A.value = !0, n("fetch:error", w);
|
|
2865
2865
|
} finally {
|
|
2866
2866
|
f.value = !1;
|
|
2867
2867
|
}
|
|
2868
|
-
}), (w,
|
|
2869
|
-
const
|
|
2868
|
+
}), (w, B) => {
|
|
2869
|
+
const N = U("KLabel"), k = U("KSelect"), x = U("KButton"), T = U("KClipboardProvider"), P = U("KSkeleton"), J = U("KEmptyState"), Q = U("KCard");
|
|
2870
2870
|
return m(), V(Q, { class: "kong-ui-entity-base-config-card" }, Te({
|
|
2871
2871
|
actions: h(() => [
|
|
2872
|
-
R("div",
|
|
2872
|
+
R("div", is, [
|
|
2873
2873
|
Y(w.$slots, "actions", {}, void 0, !0),
|
|
2874
|
-
e.config.jsonYamlEnabled ? (m(), V(
|
|
2874
|
+
e.config.jsonYamlEnabled ? (m(), V(N, {
|
|
2875
2875
|
key: 0,
|
|
2876
2876
|
class: "config-format-select-label",
|
|
2877
2877
|
"data-testid": "config-format-select-label"
|
|
@@ -2900,8 +2900,8 @@ const Di = {
|
|
|
2900
2900
|
rel: "noopener",
|
|
2901
2901
|
target: "_blank"
|
|
2902
2902
|
}, [
|
|
2903
|
-
K(y(
|
|
2904
|
-
], 8,
|
|
2903
|
+
K(y(os), { size: y(po) }, null, 8, ["size"])
|
|
2904
|
+
], 8, ss)
|
|
2905
2905
|
]),
|
|
2906
2906
|
_: 1
|
|
2907
2907
|
})) : G("", !0),
|
|
@@ -2935,15 +2935,15 @@ const Di = {
|
|
|
2935
2935
|
"is-error": ""
|
|
2936
2936
|
}, {
|
|
2937
2937
|
message: h(() => [
|
|
2938
|
-
R("h3", null, F(
|
|
2938
|
+
R("h3", null, F(b.value), 1)
|
|
2939
2939
|
]),
|
|
2940
2940
|
_: 1
|
|
2941
2941
|
})) : G("", !0),
|
|
2942
|
-
e.config.jsonYamlEnabled ? (m(), j("div",
|
|
2943
|
-
K(
|
|
2942
|
+
e.config.jsonYamlEnabled ? (m(), j("div", ls, [
|
|
2943
|
+
K(Zi, {
|
|
2944
2944
|
format: d.value,
|
|
2945
2945
|
"prop-list-types": I.value,
|
|
2946
|
-
"property-collections":
|
|
2946
|
+
"property-collections": v.value,
|
|
2947
2947
|
record: p.value
|
|
2948
2948
|
}, Te({ _: 2 }, [
|
|
2949
2949
|
ye(Object.keys(w.$slots), (X) => ({
|
|
@@ -2956,14 +2956,14 @@ const Di = {
|
|
|
2956
2956
|
])
|
|
2957
2957
|
}))
|
|
2958
2958
|
]), 1032, ["format", "prop-list-types", "property-collections", "record"])
|
|
2959
|
-
])) : (m(), j("div",
|
|
2959
|
+
])) : (m(), j("div", us, [
|
|
2960
2960
|
(m(!0), j(ve, null, ye(I.value, (X) => (m(), j("div", {
|
|
2961
2961
|
key: `config-card-details-${X}-props`,
|
|
2962
2962
|
class: Ke(`config-card-details-${X}-props`),
|
|
2963
2963
|
"data-testid": `config-card-details-${X}-props`
|
|
2964
2964
|
}, [
|
|
2965
|
-
X !== "basic" ? (m(), j("div",
|
|
2966
|
-
(m(!0), j(ve, null, ye(
|
|
2965
|
+
X !== "basic" ? (m(), j("div", ds, F(X === "advanced" ? y(a)("baseConfigCard.sections.advanced") : y(a)("baseConfigCard.sections.plugin")), 1)) : G("", !0),
|
|
2966
|
+
(m(!0), j(ve, null, ye(v.value[X], (ee) => (m(), V(xt, {
|
|
2967
2967
|
key: ee.key,
|
|
2968
2968
|
item: ee
|
|
2969
2969
|
}, Te({
|
|
@@ -2986,7 +2986,7 @@ const Di = {
|
|
|
2986
2986
|
key: "0"
|
|
2987
2987
|
} : void 0
|
|
2988
2988
|
]), 1032, ["item"]))), 128))
|
|
2989
|
-
], 10,
|
|
2989
|
+
], 10, cs))), 128))
|
|
2990
2990
|
]))
|
|
2991
2991
|
]),
|
|
2992
2992
|
_: 2
|
|
@@ -2994,7 +2994,7 @@ const Di = {
|
|
|
2994
2994
|
e.hideTitle ? void 0 : {
|
|
2995
2995
|
name: "title",
|
|
2996
2996
|
fn: h(() => [
|
|
2997
|
-
R("div",
|
|
2997
|
+
R("div", as, [
|
|
2998
2998
|
Y(w.$slots, "title", {}, () => [
|
|
2999
2999
|
Z(F(y(a)("baseConfigCard.title")), 1)
|
|
3000
3000
|
], !0)
|
|
@@ -3005,10 +3005,10 @@ const Di = {
|
|
|
3005
3005
|
]), 1024);
|
|
3006
3006
|
};
|
|
3007
3007
|
}
|
|
3008
|
-
}),
|
|
3008
|
+
}), fs = /* @__PURE__ */ ke(ps, [["__scopeId", "data-v-64349aa2"]]), ms = ["onReset", "onSubmit"], gs = {
|
|
3009
3009
|
class: "form-actions",
|
|
3010
3010
|
"data-testid": "form-actions"
|
|
3011
|
-
},
|
|
3011
|
+
}, ys = /* @__PURE__ */ ae({
|
|
3012
3012
|
__name: "EntityBaseForm",
|
|
3013
3013
|
props: {
|
|
3014
3014
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3064,13 +3064,13 @@ const Di = {
|
|
|
3064
3064
|
var p, S;
|
|
3065
3065
|
if (!r.editId)
|
|
3066
3066
|
return "";
|
|
3067
|
-
let
|
|
3068
|
-
return r.config.app === "konnect" ?
|
|
3067
|
+
let C = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3068
|
+
return r.config.app === "konnect" ? C = C.replace(/{controlPlaneId}/gi, ((p = r.config) == null ? void 0 : p.controlPlaneId) || "") : r.config.app === "kongManager" && (C = C.replace(/\/{workspace}/gi, (S = r.config) != null && S.workspace ? `/${r.config.workspace}` : "")), C = C.replace(/{id}/gi, r.editId), C;
|
|
3069
3069
|
}), f = () => {
|
|
3070
3070
|
r.config.cancelRoute ? o.push(r.config.cancelRoute) : A();
|
|
3071
3071
|
}, A = () => {
|
|
3072
3072
|
n("cancel");
|
|
3073
|
-
},
|
|
3073
|
+
}, b = () => {
|
|
3074
3074
|
u.value || n("submit");
|
|
3075
3075
|
};
|
|
3076
3076
|
return xe(() => l.value, (p) => {
|
|
@@ -3088,13 +3088,13 @@ const Di = {
|
|
|
3088
3088
|
l.value = !1;
|
|
3089
3089
|
}
|
|
3090
3090
|
}), (p, S) => {
|
|
3091
|
-
const
|
|
3091
|
+
const C = U("KSkeleton"), v = U("KEmptyState"), I = U("KAlert"), ne = U("KButton"), pe = U("KCard");
|
|
3092
3092
|
return m(), V(pe, { class: "kong-ui-entity-base-form" }, {
|
|
3093
3093
|
body: h(() => [
|
|
3094
|
-
l.value ? (m(), V(
|
|
3094
|
+
l.value ? (m(), V(C, {
|
|
3095
3095
|
key: 0,
|
|
3096
3096
|
type: "form"
|
|
3097
|
-
})) : c.value ? (m(), V(
|
|
3097
|
+
})) : c.value ? (m(), V(v, {
|
|
3098
3098
|
key: 1,
|
|
3099
3099
|
"cta-text": y(a)("baseForm.actions.back"),
|
|
3100
3100
|
"data-testid": "form-fetch-error",
|
|
@@ -3109,7 +3109,7 @@ const Di = {
|
|
|
3109
3109
|
key: 2,
|
|
3110
3110
|
"data-testid": "form-content",
|
|
3111
3111
|
onReset: rt(A, ["prevent"]),
|
|
3112
|
-
onSubmit: rt(
|
|
3112
|
+
onSubmit: rt(b, ["prevent"])
|
|
3113
3113
|
}, [
|
|
3114
3114
|
Y(p.$slots, "default", {}, void 0, !0),
|
|
3115
3115
|
e.errorMessage ? (m(), V(I, {
|
|
@@ -3118,7 +3118,7 @@ const Di = {
|
|
|
3118
3118
|
appearance: "danger",
|
|
3119
3119
|
"data-testid": "form-error"
|
|
3120
3120
|
}, null, 8, ["alert-message"])) : G("", !0),
|
|
3121
|
-
R("div",
|
|
3121
|
+
R("div", gs, [
|
|
3122
3122
|
Y(p.$slots, "form-actions", {}, () => [
|
|
3123
3123
|
K(ne, {
|
|
3124
3124
|
appearance: "outline",
|
|
@@ -3144,16 +3144,16 @@ const Di = {
|
|
|
3144
3144
|
}, 8, ["disabled"])
|
|
3145
3145
|
], !0)
|
|
3146
3146
|
])
|
|
3147
|
-
], 40,
|
|
3147
|
+
], 40, ms))
|
|
3148
3148
|
]),
|
|
3149
3149
|
_: 3
|
|
3150
3150
|
});
|
|
3151
3151
|
};
|
|
3152
3152
|
}
|
|
3153
|
-
}),
|
|
3153
|
+
}), hs = /* @__PURE__ */ ke(ys, [["__scopeId", "data-v-44a90aae"]]), vs = {
|
|
3154
3154
|
key: 0,
|
|
3155
3155
|
"data-testid": "first-col"
|
|
3156
|
-
},
|
|
3156
|
+
}, bs = /* @__PURE__ */ ae({
|
|
3157
3157
|
__name: "EntityBaseTableCell",
|
|
3158
3158
|
props: {
|
|
3159
3159
|
keyName: {
|
|
@@ -3167,67 +3167,67 @@ const Di = {
|
|
|
3167
3167
|
},
|
|
3168
3168
|
setup(e) {
|
|
3169
3169
|
const n = e, t = M(() => {
|
|
3170
|
-
var
|
|
3171
|
-
return ((
|
|
3170
|
+
var b;
|
|
3171
|
+
return ((b = n.rowEl) == null ? void 0 : b.querySelector(`[data-testid="${n.keyName}"]`)) || null;
|
|
3172
3172
|
}), r = M(() => {
|
|
3173
|
-
var
|
|
3174
|
-
return ((
|
|
3173
|
+
var b;
|
|
3174
|
+
return ((b = t.value) == null ? void 0 : b.querySelector('[data-testid="first-col"]')) || null;
|
|
3175
3175
|
}), o = M(() => {
|
|
3176
|
-
var
|
|
3177
|
-
const S = (
|
|
3176
|
+
var b, p;
|
|
3177
|
+
const S = (b = n.rowEl) == null ? void 0 : b.querySelectorAll("td");
|
|
3178
3178
|
return S ? ((p = S[0]) == null ? void 0 : p.getAttribute("data-testid")) === n.keyName : !1;
|
|
3179
3179
|
});
|
|
3180
3180
|
let a;
|
|
3181
3181
|
const i = () => {
|
|
3182
3182
|
a && (a.disconnect(), a = void 0);
|
|
3183
3183
|
}, s = () => {
|
|
3184
|
-
var
|
|
3185
|
-
c.value = ((
|
|
3184
|
+
var b, p, S;
|
|
3185
|
+
c.value = ((b = r.value) == null ? void 0 : b.getBoundingClientRect().width) || 0, d.value = ((p = t.value) == null ? void 0 : p.clientWidth) || 0, u.value = ((S = l.value) == null ? void 0 : S.innerText) || "";
|
|
3186
3186
|
}, l = O({}), c = O(0), d = O(0), u = O(""), g = M(() => [r.value, t.value]), f = xe(
|
|
3187
3187
|
g,
|
|
3188
|
-
(
|
|
3188
|
+
(b) => {
|
|
3189
3189
|
if (o.value && (i(), "ResizeObserver" in window && window)) {
|
|
3190
3190
|
a = new ResizeObserver((p) => {
|
|
3191
3191
|
window.requestAnimationFrame(() => {
|
|
3192
3192
|
!Array.isArray(p) || !p.length || s();
|
|
3193
3193
|
});
|
|
3194
3194
|
});
|
|
3195
|
-
for (const p of
|
|
3195
|
+
for (const p of b)
|
|
3196
3196
|
p && a.observe(p);
|
|
3197
3197
|
}
|
|
3198
3198
|
},
|
|
3199
3199
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
3200
3200
|
), A = M(() => o.value ? c.value > d.value : !1);
|
|
3201
|
-
return
|
|
3201
|
+
return fr(() => {
|
|
3202
3202
|
s();
|
|
3203
|
-
}),
|
|
3203
|
+
}), mr(() => {
|
|
3204
3204
|
f();
|
|
3205
|
-
}), (
|
|
3205
|
+
}), (b, p) => {
|
|
3206
3206
|
const S = U("KTooltip");
|
|
3207
3207
|
return m(), j("span", {
|
|
3208
3208
|
ref_key: "contentRef",
|
|
3209
3209
|
ref: l,
|
|
3210
3210
|
class: "content-wrapper"
|
|
3211
3211
|
}, [
|
|
3212
|
-
o.value ? (m(), j("span",
|
|
3212
|
+
o.value ? (m(), j("span", vs, [
|
|
3213
3213
|
K(S, {
|
|
3214
3214
|
label: A.value ? u.value : "",
|
|
3215
3215
|
"max-width": "300",
|
|
3216
3216
|
placement: "bottomStart"
|
|
3217
3217
|
}, {
|
|
3218
3218
|
default: h(() => [
|
|
3219
|
-
Y(
|
|
3219
|
+
Y(b.$slots, "default", {}, void 0, !0)
|
|
3220
3220
|
]),
|
|
3221
3221
|
_: 3
|
|
3222
3222
|
}, 8, ["label"])
|
|
3223
|
-
])) : Y(
|
|
3223
|
+
])) : Y(b.$slots, "default", { key: 1 }, void 0, !0)
|
|
3224
3224
|
], 512);
|
|
3225
3225
|
};
|
|
3226
3226
|
}
|
|
3227
|
-
}),
|
|
3227
|
+
}), Cs = /* @__PURE__ */ ke(bs, [["__scopeId", "data-v-e42a20c9"]]), ks = { class: "toolbar-container" }, _s = {
|
|
3228
3228
|
key: 0,
|
|
3229
3229
|
class: "toolbar-button-container"
|
|
3230
|
-
},
|
|
3230
|
+
}, ws = ["data-testid"], Is = /* @__PURE__ */ ae({
|
|
3231
3231
|
__name: "EntityBaseTable",
|
|
3232
3232
|
props: {
|
|
3233
3233
|
// table header configuration
|
|
@@ -3332,36 +3332,41 @@ const Di = {
|
|
|
3332
3332
|
disableRowClick: {
|
|
3333
3333
|
type: Boolean,
|
|
3334
3334
|
default: !1
|
|
3335
|
+
},
|
|
3336
|
+
/** default to false, setting to true will teleport the toolbar button to the destination in the consuming app */
|
|
3337
|
+
useActionOutside: {
|
|
3338
|
+
type: Boolean,
|
|
3339
|
+
default: !1
|
|
3335
3340
|
}
|
|
3336
3341
|
},
|
|
3337
3342
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked"],
|
|
3338
3343
|
setup(e, { emit: n }) {
|
|
3339
|
-
const t = e, { i18n: { t: r } } = ue.useI18n(), o = M(() => t.cacheIdentifier || t.preferencesStorageKey), a = (
|
|
3340
|
-
const
|
|
3344
|
+
const t = e, { i18n: { t: r } } = ue.useI18n(), o = M(() => t.cacheIdentifier || t.preferencesStorageKey), a = (v) => v.hasData || !!t.query, i = M(() => {
|
|
3345
|
+
const v = [];
|
|
3341
3346
|
return Object.keys(t.tableHeaders).forEach((I) => {
|
|
3342
3347
|
const ne = t.tableHeaders[I];
|
|
3343
|
-
|
|
3348
|
+
v.push({
|
|
3344
3349
|
label: ne.label ?? I,
|
|
3345
3350
|
key: I,
|
|
3346
3351
|
sortable: ne.sortable ?? !1
|
|
3347
3352
|
});
|
|
3348
|
-
}), t.enableEntityActions &&
|
|
3353
|
+
}), t.enableEntityActions && v.push({
|
|
3349
3354
|
key: "actions",
|
|
3350
3355
|
hideLabel: !0
|
|
3351
|
-
}),
|
|
3352
|
-
}), s = (
|
|
3353
|
-
"data-rowid":
|
|
3354
|
-
"data-testid":
|
|
3355
|
-
...t.rowAttributes(
|
|
3356
|
-
}), l = O({}), c = (
|
|
3356
|
+
}), v;
|
|
3357
|
+
}), s = (v) => ({
|
|
3358
|
+
"data-rowid": v.id,
|
|
3359
|
+
"data-testid": v.name,
|
|
3360
|
+
...t.rowAttributes(v)
|
|
3361
|
+
}), l = O({}), c = (v) => {
|
|
3357
3362
|
var I;
|
|
3358
|
-
return (I = l.value) == null ? void 0 : I.$el.querySelector(`[data-rowid="${
|
|
3359
|
-
}, d = (
|
|
3363
|
+
return (I = l.value) == null ? void 0 : I.$el.querySelector(`[data-rowid="${v.id}"]`);
|
|
3364
|
+
}, d = (v) => {
|
|
3360
3365
|
const I = {
|
|
3361
|
-
"data-testid":
|
|
3362
|
-
...t.cellAttributes(
|
|
3366
|
+
"data-testid": v.headerKey,
|
|
3367
|
+
...t.cellAttributes(v)
|
|
3363
3368
|
};
|
|
3364
|
-
return
|
|
3369
|
+
return v.colIndex === 0 && (I.style = {
|
|
3365
3370
|
maxWidth: "250px",
|
|
3366
3371
|
overflowX: "hidden",
|
|
3367
3372
|
textOverflow: "ellipsis"
|
|
@@ -3370,22 +3375,22 @@ const Di = {
|
|
|
3370
3375
|
n("empty-state-cta-clicked"), g();
|
|
3371
3376
|
}, g = () => {
|
|
3372
3377
|
n("clear-search-input");
|
|
3373
|
-
}, f = M(() => t.disableRowClick ? void 0 : (
|
|
3378
|
+
}, f = M(() => t.disableRowClick ? void 0 : (v, I) => {
|
|
3374
3379
|
n("click:row", I);
|
|
3375
|
-
}), A = (
|
|
3376
|
-
n("sort",
|
|
3377
|
-
}, { setTablePreferences:
|
|
3378
|
-
const
|
|
3380
|
+
}), A = (v) => {
|
|
3381
|
+
n("sort", v);
|
|
3382
|
+
}, { setTablePreferences: b, getTablePreferences: p } = Sr(), S = M(() => {
|
|
3383
|
+
const v = p(t.preferencesStorageKey);
|
|
3379
3384
|
return {
|
|
3380
3385
|
...t.initialFetcherParams,
|
|
3381
|
-
...
|
|
3386
|
+
...v
|
|
3382
3387
|
};
|
|
3383
|
-
}),
|
|
3384
|
-
t.preferencesStorageKey &&
|
|
3388
|
+
}), C = (v) => {
|
|
3389
|
+
t.preferencesStorageKey && b(t.preferencesStorageKey, v);
|
|
3385
3390
|
};
|
|
3386
|
-
return (
|
|
3387
|
-
const ne = U("KIcon"), pe = U("KButton"), H = U("KDropdownMenu"), w = U("KTable"),
|
|
3388
|
-
return m(), V(
|
|
3391
|
+
return (v, I) => {
|
|
3392
|
+
const ne = U("KIcon"), pe = U("KButton"), H = U("KDropdownMenu"), w = U("KTable"), B = U("KCard");
|
|
3393
|
+
return m(), V(B, {
|
|
3389
3394
|
class: "kong-ui-entity-base-table",
|
|
3390
3395
|
title: e.title
|
|
3391
3396
|
}, {
|
|
@@ -3418,31 +3423,36 @@ const Di = {
|
|
|
3418
3423
|
"search-input": e.query,
|
|
3419
3424
|
onKtableEmptyStateCtaClicked: u,
|
|
3420
3425
|
"onRow:click": f.value,
|
|
3421
|
-
onSort: I[0] || (I[0] = (
|
|
3422
|
-
"onUpdate:tablePreferences":
|
|
3426
|
+
onSort: I[0] || (I[0] = (N) => A(N)),
|
|
3427
|
+
"onUpdate:tablePreferences": C
|
|
3423
3428
|
}, Te({
|
|
3424
|
-
toolbar: h(({ state:
|
|
3425
|
-
et(R("div",
|
|
3426
|
-
Y(
|
|
3427
|
-
|
|
3428
|
-
Y(
|
|
3429
|
+
toolbar: h(({ state: N }) => [
|
|
3430
|
+
et(R("div", ks, [
|
|
3431
|
+
Y(v.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3432
|
+
v.$slots["toolbar-button"] ? (m(), j("div", _s, [
|
|
3433
|
+
e.useActionOutside ? Y(v.$slots, "toolbar-button", { key: 1 }, void 0, !0) : (m(), V(ur, {
|
|
3434
|
+
key: 0,
|
|
3435
|
+
to: "#action-button"
|
|
3436
|
+
}, [
|
|
3437
|
+
Y(v.$slots, "toolbar-button", {}, void 0, !0)
|
|
3438
|
+
]))
|
|
3429
3439
|
])) : G("", !0)
|
|
3430
3440
|
], 512), [
|
|
3431
|
-
[tt, a(
|
|
3441
|
+
[tt, a(N)]
|
|
3432
3442
|
])
|
|
3433
3443
|
]),
|
|
3434
|
-
actions: h(({ row:
|
|
3444
|
+
actions: h(({ row: N, rowKey: k, rowValue: x }) => [
|
|
3435
3445
|
R("div", {
|
|
3436
3446
|
class: "actions-container",
|
|
3437
|
-
"data-testid":
|
|
3447
|
+
"data-testid": N.name
|
|
3438
3448
|
}, [
|
|
3439
3449
|
K(H, {
|
|
3440
3450
|
"kpop-attributes": { placement: "bottomEnd" },
|
|
3441
3451
|
width: e.dropdownMenuWidth
|
|
3442
3452
|
}, {
|
|
3443
3453
|
items: h(() => [
|
|
3444
|
-
Y(
|
|
3445
|
-
row:
|
|
3454
|
+
Y(v.$slots, "actions", {
|
|
3455
|
+
row: N,
|
|
3446
3456
|
rowKey: k,
|
|
3447
3457
|
rowValue: x
|
|
3448
3458
|
}, void 0, !0)
|
|
@@ -3455,7 +3465,7 @@ const Di = {
|
|
|
3455
3465
|
}, {
|
|
3456
3466
|
icon: h(() => [
|
|
3457
3467
|
K(ne, {
|
|
3458
|
-
color: y(
|
|
3468
|
+
color: y(uo),
|
|
3459
3469
|
icon: "more",
|
|
3460
3470
|
size: "16"
|
|
3461
3471
|
}, null, 8, ["color"])
|
|
@@ -3465,19 +3475,19 @@ const Di = {
|
|
|
3465
3475
|
]),
|
|
3466
3476
|
_: 2
|
|
3467
3477
|
}, 1032, ["width"])
|
|
3468
|
-
], 8,
|
|
3478
|
+
], 8, ws)
|
|
3469
3479
|
]),
|
|
3470
3480
|
_: 2
|
|
3471
3481
|
}, [
|
|
3472
|
-
ye(e.tableHeaders, (
|
|
3482
|
+
ye(e.tableHeaders, (N, k) => ({
|
|
3473
3483
|
name: k,
|
|
3474
3484
|
fn: h(({ row: x, rowKey: T, rowValue: P }) => [
|
|
3475
|
-
K(
|
|
3485
|
+
K(Cs, {
|
|
3476
3486
|
"key-name": String(k),
|
|
3477
3487
|
"row-el": c(x)
|
|
3478
3488
|
}, {
|
|
3479
3489
|
default: h(() => [
|
|
3480
|
-
Y(
|
|
3490
|
+
Y(v.$slots, k, {
|
|
3481
3491
|
row: x,
|
|
3482
3492
|
rowKey: T,
|
|
3483
3493
|
rowValue: P
|
|
@@ -3495,13 +3505,13 @@ const Di = {
|
|
|
3495
3505
|
}, 8, ["title"]);
|
|
3496
3506
|
};
|
|
3497
3507
|
}
|
|
3498
|
-
}),
|
|
3508
|
+
}), As = /* @__PURE__ */ ke(Is, [["__scopeId", "data-v-4b5b750e"]]), Ss = {
|
|
3499
3509
|
key: 0,
|
|
3500
3510
|
class: "kong-ui-entity-delete-error"
|
|
3501
|
-
},
|
|
3511
|
+
}, xs = {
|
|
3502
3512
|
key: 1,
|
|
3503
3513
|
class: "description"
|
|
3504
|
-
},
|
|
3514
|
+
}, Ts = /* @__PURE__ */ ae({
|
|
3505
3515
|
__name: "EntityDeleteModal",
|
|
3506
3516
|
props: {
|
|
3507
3517
|
visible: {
|
|
@@ -3559,7 +3569,7 @@ const Di = {
|
|
|
3559
3569
|
onProceed: i
|
|
3560
3570
|
}, {
|
|
3561
3571
|
"body-content": h(() => [
|
|
3562
|
-
e.error ? (m(), j("div",
|
|
3572
|
+
e.error ? (m(), j("div", Ss, [
|
|
3563
3573
|
K(c, { appearance: "danger" }, {
|
|
3564
3574
|
alertMessage: h(() => [
|
|
3565
3575
|
Z(F(e.error), 1)
|
|
@@ -3585,7 +3595,7 @@ const Di = {
|
|
|
3585
3595
|
key: "0"
|
|
3586
3596
|
} : void 0
|
|
3587
3597
|
]), 1032, ["keypath"]),
|
|
3588
|
-
t.description || s.$slots.description ? (m(), j("div",
|
|
3598
|
+
t.description || s.$slots.description ? (m(), j("div", xs, [
|
|
3589
3599
|
Y(s.$slots, "description", {}, () => [
|
|
3590
3600
|
R("p", null, F(t.description), 1)
|
|
3591
3601
|
], !0)
|
|
@@ -3595,13 +3605,13 @@ const Di = {
|
|
|
3595
3605
|
}, 8, ["action-pending", "confirmation-text", "is-visible", "title"]);
|
|
3596
3606
|
};
|
|
3597
3607
|
}
|
|
3598
|
-
}),
|
|
3608
|
+
}), $s = /* @__PURE__ */ ke(Ts, [["__scopeId", "data-v-1c9a2a07"]]), Ms = {
|
|
3599
3609
|
fill: "none",
|
|
3600
3610
|
height: "20",
|
|
3601
3611
|
viewBox: "0 0 20 20",
|
|
3602
3612
|
width: "20",
|
|
3603
3613
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3604
|
-
},
|
|
3614
|
+
}, js = {
|
|
3605
3615
|
id: "mask0_180_20349",
|
|
3606
3616
|
height: "20",
|
|
3607
3617
|
maskUnits: "userSpaceOnUse",
|
|
@@ -3609,35 +3619,35 @@ const Di = {
|
|
|
3609
3619
|
width: "20",
|
|
3610
3620
|
x: "0",
|
|
3611
3621
|
y: "0"
|
|
3612
|
-
},
|
|
3622
|
+
}, Es = ["fill"], Os = { mask: "url(#mask0_180_20349)" }, Fs = ["fill"], Ks = /* @__PURE__ */ ae({
|
|
3613
3623
|
__name: "IconFilter",
|
|
3614
3624
|
props: {
|
|
3615
3625
|
color: {
|
|
3616
3626
|
type: String,
|
|
3617
|
-
default: `var(--kong-ui-entity-filter-color, ${
|
|
3627
|
+
default: `var(--kong-ui-entity-filter-color, ${so})`
|
|
3618
3628
|
}
|
|
3619
3629
|
},
|
|
3620
3630
|
setup(e) {
|
|
3621
|
-
return (n, t) => (m(), j("svg",
|
|
3622
|
-
R("mask",
|
|
3631
|
+
return (n, t) => (m(), j("svg", Ms, [
|
|
3632
|
+
R("mask", js, [
|
|
3623
3633
|
R("rect", {
|
|
3624
3634
|
fill: e.color,
|
|
3625
3635
|
height: "20",
|
|
3626
3636
|
width: "20"
|
|
3627
|
-
}, null, 8,
|
|
3637
|
+
}, null, 8, Es)
|
|
3628
3638
|
]),
|
|
3629
|
-
R("g",
|
|
3639
|
+
R("g", Os, [
|
|
3630
3640
|
R("path", {
|
|
3631
3641
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3632
3642
|
fill: e.color
|
|
3633
|
-
}, null, 8,
|
|
3643
|
+
}, null, 8, Fs)
|
|
3634
3644
|
])
|
|
3635
3645
|
]));
|
|
3636
3646
|
}
|
|
3637
|
-
}),
|
|
3647
|
+
}), Bs = {
|
|
3638
3648
|
key: 1,
|
|
3639
3649
|
class: "kong-ui-entity-filter"
|
|
3640
|
-
}, Ns = { class: "menu-item-title" },
|
|
3650
|
+
}, Ns = { class: "menu-item-title" }, Ps = { class: "menu-item-indicator" }, Ls = { class: "menu-item-body" }, Us = ["for"], qs = { class: "menu-item-buttons" }, Rs = /* @__PURE__ */ ae({
|
|
3641
3651
|
__name: "EntityFilter",
|
|
3642
3652
|
props: {
|
|
3643
3653
|
// filter config, either exact match or fuzzy match
|
|
@@ -3659,8 +3669,8 @@ const Di = {
|
|
|
3659
3669
|
setup(e, { emit: n }) {
|
|
3660
3670
|
const t = e, { i18n: { t: r } } = ue.useI18n(), o = O(!1), a = O({}), i = M(() => {
|
|
3661
3671
|
const p = [];
|
|
3662
|
-
return new URLSearchParams(t.modelValue).forEach((S,
|
|
3663
|
-
S !== "" && p.push(
|
|
3672
|
+
return new URLSearchParams(t.modelValue).forEach((S, C) => {
|
|
3673
|
+
S !== "" && p.push(C);
|
|
3664
3674
|
}), p;
|
|
3665
3675
|
}), s = M(() => {
|
|
3666
3676
|
const p = t.config.fields;
|
|
@@ -3670,8 +3680,8 @@ const Di = {
|
|
|
3670
3680
|
}));
|
|
3671
3681
|
});
|
|
3672
3682
|
xe(() => t.modelValue, (p) => {
|
|
3673
|
-
a.value = {}, new URLSearchParams(p).forEach((S,
|
|
3674
|
-
a.value[
|
|
3683
|
+
a.value = {}, new URLSearchParams(p).forEach((S, C) => {
|
|
3684
|
+
a.value[C] = S;
|
|
3675
3685
|
});
|
|
3676
3686
|
});
|
|
3677
3687
|
const l = () => {
|
|
@@ -3679,28 +3689,28 @@ const Di = {
|
|
|
3679
3689
|
}, c = (p) => {
|
|
3680
3690
|
n("update:modelValue", p);
|
|
3681
3691
|
}, d = (p) => `filter-${p}`, u = (p) => {
|
|
3682
|
-
var S,
|
|
3683
|
-
return (((
|
|
3684
|
-
value:
|
|
3685
|
-
label:
|
|
3692
|
+
var S, C;
|
|
3693
|
+
return (((C = (S = t.config.schema) == null ? void 0 : S[p]) == null ? void 0 : C.values) ?? []).map((v) => ({
|
|
3694
|
+
value: v,
|
|
3695
|
+
label: v
|
|
3686
3696
|
}));
|
|
3687
3697
|
}, g = (p) => {
|
|
3688
|
-
var S,
|
|
3689
|
-
return ((
|
|
3698
|
+
var S, C;
|
|
3699
|
+
return ((C = (S = t.config.schema) == null ? void 0 : S[p]) == null ? void 0 : C.type) ?? "text";
|
|
3690
3700
|
}, f = (p) => {
|
|
3691
3701
|
a.value = {
|
|
3692
3702
|
...a.value,
|
|
3693
3703
|
[p]: ""
|
|
3694
|
-
},
|
|
3704
|
+
}, b();
|
|
3695
3705
|
}, A = () => {
|
|
3696
|
-
a.value = {},
|
|
3697
|
-
},
|
|
3698
|
-
const S = Object.keys(a.value).reduce((
|
|
3706
|
+
a.value = {}, b(!0);
|
|
3707
|
+
}, b = (p = !1) => {
|
|
3708
|
+
const S = Object.keys(a.value).reduce((C, v) => (a.value[v] && (C[v] = `${a.value[v]}`), C), {});
|
|
3699
3709
|
p && (o.value = !1), n("update:modelValue", new URLSearchParams(S).toString());
|
|
3700
3710
|
};
|
|
3701
3711
|
return (p, S) => {
|
|
3702
|
-
const
|
|
3703
|
-
return e.config.isExactMatch ? (m(), V(
|
|
3712
|
+
const C = U("KInput"), v = U("KButton"), I = U("KSelect"), ne = U("KMenuItem"), pe = U("KMenu");
|
|
3713
|
+
return e.config.isExactMatch ? (m(), V(C, {
|
|
3704
3714
|
key: 0,
|
|
3705
3715
|
autocomplete: "off",
|
|
3706
3716
|
class: "kong-ui-entity-filter-input",
|
|
@@ -3710,11 +3720,11 @@ const Di = {
|
|
|
3710
3720
|
"onUpdate:modelValue": c
|
|
3711
3721
|
}, {
|
|
3712
3722
|
icon: h(() => [
|
|
3713
|
-
K(
|
|
3723
|
+
K(Ks)
|
|
3714
3724
|
]),
|
|
3715
3725
|
_: 1
|
|
3716
|
-
}, 8, ["model-value", "placeholder"])) : (m(), j("div",
|
|
3717
|
-
K(
|
|
3726
|
+
}, 8, ["model-value", "placeholder"])) : (m(), j("div", Bs, [
|
|
3727
|
+
K(v, {
|
|
3718
3728
|
appearance: "btn-link",
|
|
3719
3729
|
"data-testid": "filter-button",
|
|
3720
3730
|
icon: "filter",
|
|
@@ -3742,20 +3752,20 @@ const Di = {
|
|
|
3742
3752
|
itemTitle: h(() => [
|
|
3743
3753
|
R("span", Ns, [
|
|
3744
3754
|
Z(F(H.label) + " ", 1),
|
|
3745
|
-
et(R("span",
|
|
3755
|
+
et(R("span", Ps, null, 512), [
|
|
3746
3756
|
[tt, i.value.includes(H.value)]
|
|
3747
3757
|
])
|
|
3748
3758
|
])
|
|
3749
3759
|
]),
|
|
3750
3760
|
itemBody: h(() => {
|
|
3751
|
-
var
|
|
3761
|
+
var B, N;
|
|
3752
3762
|
return [
|
|
3753
|
-
R("div",
|
|
3763
|
+
R("div", Ls, [
|
|
3754
3764
|
R("label", {
|
|
3755
3765
|
class: "menu-item-label",
|
|
3756
3766
|
for: d(H.value)
|
|
3757
|
-
}, F(y(r)("filter.fieldLabel")), 9,
|
|
3758
|
-
((
|
|
3767
|
+
}, F(y(r)("filter.fieldLabel")), 9, Us),
|
|
3768
|
+
((N = (B = e.config.schema) == null ? void 0 : B[H.value]) == null ? void 0 : N.type) === "select" ? (m(), V(I, {
|
|
3759
3769
|
key: 0,
|
|
3760
3770
|
id: d(H.value),
|
|
3761
3771
|
modelValue: a.value[H.value],
|
|
@@ -3763,7 +3773,7 @@ const Di = {
|
|
|
3763
3773
|
appearance: "select",
|
|
3764
3774
|
items: u(H.value),
|
|
3765
3775
|
placeholder: y(r)("filter.selectPlaceholder")
|
|
3766
|
-
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (m(), V(
|
|
3776
|
+
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (m(), V(C, {
|
|
3767
3777
|
key: 1,
|
|
3768
3778
|
id: d(H.value),
|
|
3769
3779
|
modelValue: a.value[H.value],
|
|
@@ -3774,19 +3784,19 @@ const Di = {
|
|
|
3774
3784
|
type: g(H.value)
|
|
3775
3785
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3776
3786
|
]),
|
|
3777
|
-
R("div",
|
|
3778
|
-
K(
|
|
3787
|
+
R("div", qs, [
|
|
3788
|
+
K(v, {
|
|
3779
3789
|
appearance: "btn-link",
|
|
3780
3790
|
"data-testid": "apply-filter",
|
|
3781
3791
|
size: "small",
|
|
3782
|
-
onClick: S[0] || (S[0] = (k) =>
|
|
3792
|
+
onClick: S[0] || (S[0] = (k) => b(!0))
|
|
3783
3793
|
}, {
|
|
3784
3794
|
default: h(() => [
|
|
3785
3795
|
Z(F(y(r)("filter.applyButtonText")), 1)
|
|
3786
3796
|
]),
|
|
3787
3797
|
_: 1
|
|
3788
3798
|
}),
|
|
3789
|
-
K(
|
|
3799
|
+
K(v, {
|
|
3790
3800
|
appearance: "btn-link",
|
|
3791
3801
|
"data-testid": "clear-filter",
|
|
3792
3802
|
size: "small",
|
|
@@ -3804,7 +3814,7 @@ const Di = {
|
|
|
3804
3814
|
}, 1032, ["data-testid", "last-menu-item"]))), 128))
|
|
3805
3815
|
]),
|
|
3806
3816
|
actionButton: h(() => [
|
|
3807
|
-
K(
|
|
3817
|
+
K(v, { onClick: A }, {
|
|
3808
3818
|
default: h(() => [
|
|
3809
3819
|
Z(F(y(r)("filter.clearAllButtonText")), 1)
|
|
3810
3820
|
]),
|
|
@@ -3818,7 +3828,7 @@ const Di = {
|
|
|
3818
3828
|
]));
|
|
3819
3829
|
};
|
|
3820
3830
|
}
|
|
3821
|
-
}),
|
|
3831
|
+
}), Vs = /* @__PURE__ */ ke(Rs, [["__scopeId", "data-v-745f38c0"]]), Xe = /* @__PURE__ */ ae({
|
|
3822
3832
|
__name: "PermissionsWrapper",
|
|
3823
3833
|
props: {
|
|
3824
3834
|
/**
|
|
@@ -3848,16 +3858,16 @@ const Di = {
|
|
|
3848
3858
|
isAllowed: t.value
|
|
3849
3859
|
}) : G("", !0);
|
|
3850
3860
|
}
|
|
3851
|
-
}),
|
|
3861
|
+
}), Ds = { class: "form-section-wrapper" }, Gs = {
|
|
3852
3862
|
key: 0,
|
|
3853
3863
|
class: "form-section-title"
|
|
3854
|
-
},
|
|
3864
|
+
}, Hs = {
|
|
3855
3865
|
key: 1,
|
|
3856
3866
|
class: "form-section-description"
|
|
3857
|
-
},
|
|
3867
|
+
}, zs = {
|
|
3858
3868
|
key: 2,
|
|
3859
3869
|
class: "form-section-footer"
|
|
3860
|
-
},
|
|
3870
|
+
}, Js = { class: "form-section-content" }, Ws = /* @__PURE__ */ ae({
|
|
3861
3871
|
__name: "EntityFormSection",
|
|
3862
3872
|
props: {
|
|
3863
3873
|
title: {
|
|
@@ -3886,32 +3896,32 @@ const Di = {
|
|
|
3886
3896
|
return (t, r) => (m(), j("fieldset", {
|
|
3887
3897
|
class: Ke(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }])
|
|
3888
3898
|
}, [
|
|
3889
|
-
R("div",
|
|
3899
|
+
R("div", Ds, [
|
|
3890
3900
|
e.hideInfoHeader ? G("", !0) : (m(), j("div", {
|
|
3891
3901
|
key: 0,
|
|
3892
3902
|
class: Ke(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
3893
3903
|
}, [
|
|
3894
|
-
e.title ? (m(), j("h4",
|
|
3895
|
-
e.description || y(n).description ? (m(), j("div",
|
|
3904
|
+
e.title ? (m(), j("h4", Gs, F(e.title), 1)) : G("", !0),
|
|
3905
|
+
e.description || y(n).description ? (m(), j("div", Hs, [
|
|
3896
3906
|
Y(t.$slots, "description", {}, () => [
|
|
3897
3907
|
R("p", null, F(e.description), 1)
|
|
3898
3908
|
], !0)
|
|
3899
3909
|
])) : G("", !0),
|
|
3900
|
-
y(n).footer ? (m(), j("div",
|
|
3910
|
+
y(n).footer ? (m(), j("div", zs, [
|
|
3901
3911
|
Y(t.$slots, "footer", {}, void 0, !0)
|
|
3902
3912
|
])) : G("", !0)
|
|
3903
3913
|
], 2)),
|
|
3904
|
-
R("div",
|
|
3914
|
+
R("div", Js, [
|
|
3905
3915
|
Y(t.$slots, "default", {}, void 0, !0)
|
|
3906
3916
|
])
|
|
3907
3917
|
])
|
|
3908
3918
|
], 2));
|
|
3909
3919
|
}
|
|
3910
|
-
}), un = /* @__PURE__ */ ke(
|
|
3911
|
-
const
|
|
3920
|
+
}), un = /* @__PURE__ */ ke(Ws, [["__scopeId", "data-v-8b6dc312"]]), { useAxios: Ft, useDeleteUrlBuilder: Ys, useErrors: Zs, useFetchUrlBuilder: vl, useFetcher: Qs, useDebouncedFilter: ar, useStringHelpers: bl, useHelpers: Cl, useGatewayFeatureSupported: kl, useTruncationDetector: _l } = ue;
|
|
3921
|
+
const Xs = { class: "add-to-group-form-container" }, el = { class: "add-to-group-cta-text" }, tl = {
|
|
3912
3922
|
key: 0,
|
|
3913
3923
|
class: "kong-ui-entity-add-to-groups-error"
|
|
3914
|
-
},
|
|
3924
|
+
}, nl = { key: 0 }, rl = /* @__PURE__ */ ae({
|
|
3915
3925
|
__name: "AddToGroupModal",
|
|
3916
3926
|
props: {
|
|
3917
3927
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3928,9 +3938,9 @@ const Qs = { class: "add-to-group-form-container" }, Xs = { class: "add-to-group
|
|
|
3928
3938
|
},
|
|
3929
3939
|
emits: ["cancel", "add:success", "add:partial-success", "error"],
|
|
3930
3940
|
setup(e, { emit: n }) {
|
|
3931
|
-
var
|
|
3941
|
+
var N;
|
|
3932
3942
|
const t = e, { i18n: { t: r } } = ct.useI18n(), { axiosInstance: o } = Ft({
|
|
3933
|
-
headers: (
|
|
3943
|
+
headers: (N = t.config) == null ? void 0 : N.requestHeaders
|
|
3934
3944
|
}), a = O([]), {
|
|
3935
3945
|
debouncedQueryChange: i,
|
|
3936
3946
|
loading: s,
|
|
@@ -3946,7 +3956,7 @@ const Qs = { class: "add-to-group-form-container" }, Xs = { class: "add-to-group
|
|
|
3946
3956
|
fetchedItemsKey: "data",
|
|
3947
3957
|
searchKeys: ["name", "id"]
|
|
3948
3958
|
}
|
|
3949
|
-
), g = M(() => c.value ? r("consumer_groups.errors.general") : ""), f = O(0), A = M(() => l.value === void 0),
|
|
3959
|
+
), g = M(() => c.value ? r("consumer_groups.errors.general") : ""), f = O(0), A = M(() => l.value === void 0), b = M(() => u.value.map((k) => ({
|
|
3950
3960
|
label: k.name,
|
|
3951
3961
|
value: k.id,
|
|
3952
3962
|
selected: a.value.includes(k.id),
|
|
@@ -3957,23 +3967,23 @@ const Qs = { class: "add-to-group-form-container" }, Xs = { class: "add-to-group
|
|
|
3957
3967
|
const x = A.value ? u.value.find((P) => P.id === k) : (T = l.value) == null ? void 0 : T.find((P) => P.id === k);
|
|
3958
3968
|
return x ? x.name : k;
|
|
3959
3969
|
}, S = () => {
|
|
3960
|
-
I.value = "",
|
|
3961
|
-
},
|
|
3970
|
+
I.value = "", C.value = [], w.value = [], n("cancel");
|
|
3971
|
+
}, C = O([]), v = O(!1), I = O(""), ne = async () => {
|
|
3962
3972
|
if (!a.value.length) {
|
|
3963
3973
|
I.value = "", w.value = [], n("cancel");
|
|
3964
3974
|
return;
|
|
3965
3975
|
}
|
|
3966
|
-
|
|
3976
|
+
v.value = !0, I.value = "", C.value = [], w.value = [];
|
|
3967
3977
|
try {
|
|
3968
3978
|
const k = a.value.map((P) => H(P)), x = await Promise.allSettled(k);
|
|
3969
3979
|
let T = !0;
|
|
3970
3980
|
x.forEach((P) => {
|
|
3971
3981
|
P.status !== "fulfilled" && (T = !1);
|
|
3972
|
-
}), T ? (
|
|
3982
|
+
}), T ? (C.value = [], w.value = [], n("add:success", a.value), a.value = []) : (C.value.length && n("add:partial-success", C.value), a.value = [], B(x));
|
|
3973
3983
|
} catch {
|
|
3974
3984
|
I.value = r("consumer_groups.errors.add"), n("error", I.value);
|
|
3975
3985
|
} finally {
|
|
3976
|
-
|
|
3986
|
+
v.value = !1;
|
|
3977
3987
|
}
|
|
3978
3988
|
}, pe = M(() => {
|
|
3979
3989
|
var x, T, P, J;
|
|
@@ -3985,25 +3995,25 @@ const Qs = { class: "add-to-group-form-container" }, Xs = { class: "add-to-group
|
|
|
3985
3995
|
};
|
|
3986
3996
|
try {
|
|
3987
3997
|
const T = await o.post(pe.value, x);
|
|
3988
|
-
return
|
|
3998
|
+
return C.value.push(k), T;
|
|
3989
3999
|
} catch (T) {
|
|
3990
4000
|
let P = `${p(k)} - ${T.message}`;
|
|
3991
4001
|
return T.response.status === 409 && (P = `${p(k)} - ${r("consumer_groups.errors.already_added")}`), Promise.reject(Error(P));
|
|
3992
4002
|
}
|
|
3993
|
-
}, w = O([]),
|
|
4003
|
+
}, w = O([]), B = (k) => {
|
|
3994
4004
|
w.value = k.map((x) => {
|
|
3995
4005
|
var T;
|
|
3996
4006
|
return (T = x.reason) == null ? void 0 : T.message;
|
|
3997
4007
|
}).filter(Boolean);
|
|
3998
4008
|
};
|
|
3999
|
-
return xe(
|
|
4009
|
+
return xe(b, () => {
|
|
4000
4010
|
f.value++;
|
|
4001
4011
|
}, { immediate: !0, deep: !0 }), Qe(async () => {
|
|
4002
4012
|
await d();
|
|
4003
4013
|
}), (k, x) => {
|
|
4004
4014
|
const T = U("KMultiselect"), P = U("KAlert"), J = U("KPrompt");
|
|
4005
4015
|
return m(), V(J, {
|
|
4006
|
-
"action-pending":
|
|
4016
|
+
"action-pending": v.value,
|
|
4007
4017
|
class: "kong-ui-entities-add-to-groups-modal",
|
|
4008
4018
|
"data-testid": "add-to-group-modal",
|
|
4009
4019
|
"is-visible": e.visible,
|
|
@@ -4012,28 +4022,28 @@ const Qs = { class: "add-to-group-form-container" }, Xs = { class: "add-to-group
|
|
|
4012
4022
|
onProceed: ne
|
|
4013
4023
|
}, {
|
|
4014
4024
|
"body-content": h(() => [
|
|
4015
|
-
R("div",
|
|
4016
|
-
R("p",
|
|
4025
|
+
R("div", Xs, [
|
|
4026
|
+
R("p", el, F(y(r)("consumer_groups.consumers.add.ctaText")), 1),
|
|
4017
4027
|
K(T, {
|
|
4018
4028
|
modelValue: a.value,
|
|
4019
4029
|
"onUpdate:modelValue": x[0] || (x[0] = (Q) => a.value = Q),
|
|
4020
4030
|
autosuggest: "",
|
|
4021
4031
|
"data-testid": "add-to-groups-multiselect",
|
|
4022
4032
|
"dropdown-footer-text": A.value ? y(r)("consumer_groups.consumers.add.footer") : void 0,
|
|
4023
|
-
items:
|
|
4033
|
+
items: b.value,
|
|
4024
4034
|
label: y(r)("consumer_groups.consumers.add.consumer_groups_label"),
|
|
4025
4035
|
loading: y(s),
|
|
4026
4036
|
placeholder: y(r)("consumer_groups.consumers.add.consumer_group_placeholder"),
|
|
4027
|
-
readonly:
|
|
4037
|
+
readonly: v.value,
|
|
4028
4038
|
required: "",
|
|
4029
4039
|
width: "100%",
|
|
4030
4040
|
onQueryChange: y(i)
|
|
4031
4041
|
}, null, 8, ["modelValue", "dropdown-footer-text", "items", "label", "loading", "placeholder", "readonly", "onQueryChange"]),
|
|
4032
|
-
I.value || g.value || w.value.length ? (m(), j("div",
|
|
4042
|
+
I.value || g.value || w.value.length ? (m(), j("div", tl, [
|
|
4033
4043
|
K(P, { appearance: "danger" }, {
|
|
4034
4044
|
alertMessage: h(() => [
|
|
4035
4045
|
R("p", null, F(y(r)("consumer_groups.errors.add")), 1),
|
|
4036
|
-
w.value.length ? (m(), j("ul",
|
|
4046
|
+
w.value.length ? (m(), j("ul", nl, [
|
|
4037
4047
|
(m(!0), j(ve, null, ye(w.value, (Q, X) => (m(), j("li", { key: X }, F(Q), 1))), 128))
|
|
4038
4048
|
])) : G("", !0),
|
|
4039
4049
|
R("div", null, F(I.value || g.value), 1)
|
|
@@ -4053,7 +4063,7 @@ const Kt = (e, n) => {
|
|
|
4053
4063
|
for (const [r, o] of n)
|
|
4054
4064
|
t[r] = o;
|
|
4055
4065
|
return t;
|
|
4056
|
-
},
|
|
4066
|
+
}, ol = /* @__PURE__ */ Kt(rl, [["__scopeId", "data-v-4d30f3c5"]]), al = { class: "kong-ui-entities-consumer-groups-list" }, il = { key: 1 }, sl = /* @__PURE__ */ ae({
|
|
4057
4067
|
__name: "ConsumerGroupList",
|
|
4058
4068
|
props: {
|
|
4059
4069
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4094,9 +4104,9 @@ const Kt = (e, n) => {
|
|
|
4094
4104
|
},
|
|
4095
4105
|
emits: ["error", "copy:success", "copy:error", "delete:success", "add:success", "remove:success"],
|
|
4096
4106
|
setup(e, { emit: n }) {
|
|
4097
|
-
var
|
|
4107
|
+
var Bt;
|
|
4098
4108
|
const t = e, { i18nT: r, i18n: { t: o } } = ct.useI18n(), a = wt(), { axiosInstance: i } = Ft({
|
|
4099
|
-
headers: (
|
|
4109
|
+
headers: (Bt = t.config) == null ? void 0 : Bt.requestHeaders
|
|
4100
4110
|
}), s = O(1), l = M(() => !!t.config.consumerId), c = M(() => t.config.app !== "kongManager" || !!t.config.disableSorting), d = {
|
|
4101
4111
|
name: { label: o("consumer_groups.list.table_headers.name"), searchable: !0, sortable: !0 }
|
|
4102
4112
|
};
|
|
@@ -4107,7 +4117,7 @@ const Kt = (e, n) => {
|
|
|
4107
4117
|
var z, le, Ce, Ee;
|
|
4108
4118
|
let E = `${t.config.apiBaseUrl}${$e.list[t.config.app][l.value ? "forConsumer" : "all"]}`;
|
|
4109
4119
|
return t.config.app === "konnect" ? E = E.replace(/{controlPlaneId}/gi, ((z = t.config) == null ? void 0 : z.controlPlaneId) || "").replace(/{consumerId}/gi, ((le = t.config) == null ? void 0 : le.consumerId) || "") : t.config.app === "kongManager" && (E = E.replace(/\/{workspace}/gi, (Ce = t.config) != null && Ce.workspace ? `/${t.config.workspace}` : "").replace(/{consumerId}/gi, ((Ee = t.config) == null ? void 0 : Ee.consumerId) || "")), E;
|
|
4110
|
-
}), A = O(""),
|
|
4120
|
+
}), A = O(""), b = M(() => {
|
|
4111
4121
|
const E = t.config.app === "konnect" || t.config.isExactMatch;
|
|
4112
4122
|
return E ? {
|
|
4113
4123
|
isExactMatch: E,
|
|
@@ -4123,7 +4133,7 @@ const Kt = (e, n) => {
|
|
|
4123
4133
|
},
|
|
4124
4134
|
schema: t.config.filterSchema
|
|
4125
4135
|
};
|
|
4126
|
-
}), p = M(() => l.value ? "consumer_groups" : void 0), { fetcher: S, fetcherState:
|
|
4136
|
+
}), p = M(() => l.value ? "consumer_groups" : void 0), { fetcher: S, fetcherState: C } = Qs(t.config, f.value, p.value), v = () => {
|
|
4127
4137
|
A.value = "";
|
|
4128
4138
|
}, I = () => {
|
|
4129
4139
|
s.value++;
|
|
@@ -4158,13 +4168,13 @@ const Kt = (e, n) => {
|
|
|
4158
4168
|
}, w = async (E) => {
|
|
4159
4169
|
var le;
|
|
4160
4170
|
await ((le = t.canRetrieve) == null ? void 0 : le.call(t, E)) && a.push(t.config.getViewRoute(E.id));
|
|
4161
|
-
},
|
|
4171
|
+
}, B = (E) => ({
|
|
4162
4172
|
label: o("consumer_groups.actions.view"),
|
|
4163
4173
|
to: t.config.getViewRoute(E)
|
|
4164
|
-
}),
|
|
4174
|
+
}), N = (E) => ({
|
|
4165
4175
|
label: o("consumer_groups.actions.edit"),
|
|
4166
4176
|
to: t.config.getEditRoute(E)
|
|
4167
|
-
}), k = O(void 0), x = O(!1), T = O(!1), P = O(""), J =
|
|
4177
|
+
}), k = O(void 0), x = O(!1), T = O(!1), P = O(""), J = Ys(t.config, f.value), Q = (E) => {
|
|
4168
4178
|
k.value = E, x.value = !0;
|
|
4169
4179
|
}, X = () => {
|
|
4170
4180
|
x.value = !1;
|
|
@@ -4192,7 +4202,7 @@ const Kt = (e, n) => {
|
|
|
4192
4202
|
q.value = E, D.value = !0;
|
|
4193
4203
|
}, ce = () => {
|
|
4194
4204
|
D.value = !1, q.value = void 0;
|
|
4195
|
-
},
|
|
4205
|
+
}, Be = M(() => {
|
|
4196
4206
|
var z, le, Ce, Ee;
|
|
4197
4207
|
let E = `${t.config.apiBaseUrl}${$e.list[t.config.app].oneForConsumer}`;
|
|
4198
4208
|
return t.config.app === "konnect" ? E = E.replace(/{controlPlaneId}/gi, ((z = t.config) == null ? void 0 : z.controlPlaneId) || "").replace(/{consumerId}/gi, ((le = t.config) == null ? void 0 : le.consumerId) || "") : t.config.app === "kongManager" && (E = E.replace(/\/{workspace}/gi, (Ce = t.config) != null && Ce.workspace ? `/${t.config.workspace}` : "").replace(/{consumerId}/gi, ((Ee = t.config) == null ? void 0 : Ee.consumerId) || "")), E;
|
|
@@ -4200,7 +4210,7 @@ const Kt = (e, n) => {
|
|
|
4200
4210
|
if (q.value) {
|
|
4201
4211
|
De.value = !0;
|
|
4202
4212
|
try {
|
|
4203
|
-
const E =
|
|
4213
|
+
const E = Be.value.replace(/{consumerGroupId}/gi, q.value.id);
|
|
4204
4214
|
await i.delete(E), n("remove:success", q.value), ce(), s.value++;
|
|
4205
4215
|
} catch (E) {
|
|
4206
4216
|
ge.value = E.message || o("consumer_groups.errors.delete"), n("error", E);
|
|
@@ -4209,7 +4219,7 @@ const Kt = (e, n) => {
|
|
|
4209
4219
|
}
|
|
4210
4220
|
}
|
|
4211
4221
|
};
|
|
4212
|
-
xe(
|
|
4222
|
+
xe(C, (E) => {
|
|
4213
4223
|
if (E.status === Oe.Error) {
|
|
4214
4224
|
ne.value = o("consumer_groups.errors.general"), n("error", E.error);
|
|
4215
4225
|
return;
|
|
@@ -4225,9 +4235,9 @@ const Kt = (e, n) => {
|
|
|
4225
4235
|
return Qe(async () => {
|
|
4226
4236
|
await t.canCreate() && (pt.value.title = l.value ? o("consumer_groups.list.empty_state.title_for_consumer") : o("consumer_groups.list.empty_state.title"), pt.value.ctaText = l.value ? o("consumer_groups.actions.add_to_group") : o("consumer_groups.actions.create"));
|
|
4227
4237
|
}), (E, z) => {
|
|
4228
|
-
const le = U("KButton"), Ce = U("KBadge"), Ee = U("KTruncate"), Ge = U("KDropdownItem"),
|
|
4229
|
-
return m(), j("div",
|
|
4230
|
-
K(y(
|
|
4238
|
+
const le = U("KButton"), Ce = U("KBadge"), Ee = U("KTruncate"), Ge = U("KDropdownItem"), Nt = U("KClipboardProvider"), sr = U("KPrompt");
|
|
4239
|
+
return m(), j("div", al, [
|
|
4240
|
+
K(y(As), {
|
|
4231
4241
|
"cache-identifier": e.cacheIdentifier,
|
|
4232
4242
|
"disable-pagination": l.value,
|
|
4233
4243
|
"disable-pagination-page-jump": "",
|
|
@@ -4242,17 +4252,17 @@ const Kt = (e, n) => {
|
|
|
4242
4252
|
query: A.value,
|
|
4243
4253
|
"row-attributes": g,
|
|
4244
4254
|
"table-headers": y(u),
|
|
4245
|
-
onClearSearchInput:
|
|
4255
|
+
onClearSearchInput: v,
|
|
4246
4256
|
"onClick:row": z[3] || (z[3] = (W) => w(W)),
|
|
4247
4257
|
onEmptyStateCtaClicked: re,
|
|
4248
4258
|
onSort: I
|
|
4249
4259
|
}, {
|
|
4250
4260
|
"toolbar-filter": h(() => [
|
|
4251
|
-
l.value ? G("", !0) : (m(), V(y(
|
|
4261
|
+
l.value ? G("", !0) : (m(), V(y(Vs), {
|
|
4252
4262
|
key: 0,
|
|
4253
4263
|
modelValue: A.value,
|
|
4254
4264
|
"onUpdate:modelValue": z[0] || (z[0] = (W) => A.value = W),
|
|
4255
|
-
config:
|
|
4265
|
+
config: b.value
|
|
4256
4266
|
}, null, 8, ["modelValue", "config"]))
|
|
4257
4267
|
]),
|
|
4258
4268
|
"toolbar-button": h(() => [
|
|
@@ -4285,26 +4295,26 @@ const Kt = (e, n) => {
|
|
|
4285
4295
|
tags: h(({ rowValue: W }) => [
|
|
4286
4296
|
(W == null ? void 0 : W.length) > 0 ? (m(), V(Ee, { key: 0 }, {
|
|
4287
4297
|
default: h(() => [
|
|
4288
|
-
(m(!0), j(ve, null, ye(W, (
|
|
4289
|
-
key:
|
|
4298
|
+
(m(!0), j(ve, null, ye(W, (Ne) => (m(), V(Ce, {
|
|
4299
|
+
key: Ne,
|
|
4290
4300
|
onClick: z[2] || (z[2] = rt(() => {
|
|
4291
4301
|
}, ["stop"]))
|
|
4292
4302
|
}, {
|
|
4293
4303
|
default: h(() => [
|
|
4294
|
-
Z(F(
|
|
4304
|
+
Z(F(Ne), 1)
|
|
4295
4305
|
]),
|
|
4296
4306
|
_: 2
|
|
4297
4307
|
}, 1024))), 128))
|
|
4298
4308
|
]),
|
|
4299
4309
|
_: 2
|
|
4300
|
-
}, 1024)) : (m(), j("span",
|
|
4310
|
+
}, 1024)) : (m(), j("span", il, "-"))
|
|
4301
4311
|
]),
|
|
4302
4312
|
actions: h(({ row: W }) => [
|
|
4303
|
-
K(
|
|
4304
|
-
default: h(({ copyToClipboard:
|
|
4313
|
+
K(Nt, null, {
|
|
4314
|
+
default: h(({ copyToClipboard: Ne }) => [
|
|
4305
4315
|
K(Ge, {
|
|
4306
4316
|
"data-testid": "action-entity-copy-id",
|
|
4307
|
-
onClick: (lr) => pe(W,
|
|
4317
|
+
onClick: (lr) => pe(W, Ne)
|
|
4308
4318
|
}, {
|
|
4309
4319
|
default: h(() => [
|
|
4310
4320
|
Z(F(y(o)("consumer_groups.actions.copy_id")), 1)
|
|
@@ -4314,11 +4324,11 @@ const Kt = (e, n) => {
|
|
|
4314
4324
|
]),
|
|
4315
4325
|
_: 2
|
|
4316
4326
|
}, 1024),
|
|
4317
|
-
K(
|
|
4318
|
-
default: h(({ copyToClipboard:
|
|
4327
|
+
K(Nt, null, {
|
|
4328
|
+
default: h(({ copyToClipboard: Ne }) => [
|
|
4319
4329
|
K(Ge, {
|
|
4320
4330
|
"data-testid": "action-entity-copy-json",
|
|
4321
|
-
onClick: (lr) => H(W,
|
|
4331
|
+
onClick: (lr) => H(W, Ne)
|
|
4322
4332
|
}, {
|
|
4323
4333
|
default: h(() => [
|
|
4324
4334
|
Z(F(y(o)("consumer_groups.actions.copy_json")), 1)
|
|
@@ -4335,7 +4345,7 @@ const Kt = (e, n) => {
|
|
|
4335
4345
|
K(Ge, {
|
|
4336
4346
|
"data-testid": "action-entity-view",
|
|
4337
4347
|
"has-divider": "",
|
|
4338
|
-
item:
|
|
4348
|
+
item: B(W.id)
|
|
4339
4349
|
}, null, 8, ["item"])
|
|
4340
4350
|
]),
|
|
4341
4351
|
_: 2
|
|
@@ -4346,7 +4356,7 @@ const Kt = (e, n) => {
|
|
|
4346
4356
|
default: h(() => [
|
|
4347
4357
|
K(Ge, {
|
|
4348
4358
|
"data-testid": "action-entity-edit",
|
|
4349
|
-
item:
|
|
4359
|
+
item: N(W.id)
|
|
4350
4360
|
}, null, 8, ["item"])
|
|
4351
4361
|
]),
|
|
4352
4362
|
_: 2
|
|
@@ -4372,7 +4382,7 @@ const Kt = (e, n) => {
|
|
|
4372
4382
|
]),
|
|
4373
4383
|
_: 1
|
|
4374
4384
|
}, 8, ["cache-identifier", "disable-pagination", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers"]),
|
|
4375
|
-
K(y(
|
|
4385
|
+
K(y($s), {
|
|
4376
4386
|
"action-pending": T.value,
|
|
4377
4387
|
"data-testid": "delete-consumer-group-modal",
|
|
4378
4388
|
description: y(o)("consumer_groups.delete.description"),
|
|
@@ -4384,7 +4394,7 @@ const Kt = (e, n) => {
|
|
|
4384
4394
|
onCancel: X,
|
|
4385
4395
|
onProceed: ee
|
|
4386
4396
|
}, null, 8, ["action-pending", "description", "entity-name", "entity-type", "error", "title", "visible"]),
|
|
4387
|
-
e.config.consumerId ? (m(), V(
|
|
4397
|
+
e.config.consumerId ? (m(), V(ol, {
|
|
4388
4398
|
key: 0,
|
|
4389
4399
|
config: e.config,
|
|
4390
4400
|
"data-testid": "add-to-group-modal",
|
|
@@ -4429,10 +4439,10 @@ const Kt = (e, n) => {
|
|
|
4429
4439
|
};
|
|
4430
4440
|
}
|
|
4431
4441
|
});
|
|
4432
|
-
const
|
|
4442
|
+
const wl = /* @__PURE__ */ Kt(sl, [["__scopeId", "data-v-80c4522c"]]), ll = { class: "kong-ui-entities-consumer-group-form" }, ul = { class: "select-item-label" }, cl = {
|
|
4433
4443
|
key: 0,
|
|
4434
4444
|
class: "select-item-desc"
|
|
4435
|
-
},
|
|
4445
|
+
}, dl = /* @__PURE__ */ ae({
|
|
4436
4446
|
__name: "ConsumerGroupForm",
|
|
4437
4447
|
props: {
|
|
4438
4448
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4474,19 +4484,19 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4474
4484
|
searchKeys: ["username", "custom_id", "id"]
|
|
4475
4485
|
}), { axiosInstance: g } = Ft({
|
|
4476
4486
|
headers: (Ve = t.config) == null ? void 0 : Ve.requestHeaders
|
|
4477
|
-
}), { getMessageFromError: f } =
|
|
4487
|
+
}), { getMessageFromError: f } = Zs(), A = M(() => u.value.map((_) => ({
|
|
4478
4488
|
label: _.username || _.custom_id,
|
|
4479
4489
|
value: _.id,
|
|
4480
4490
|
selected: a.fields.consumers.includes(_.id),
|
|
4481
4491
|
data: _
|
|
4482
4492
|
// we need this to determine whether or not to show the description text
|
|
4483
|
-
}))),
|
|
4493
|
+
}))), b = M(() => {
|
|
4484
4494
|
var _, L;
|
|
4485
4495
|
return (L = $e.form[(_ = t.config) == null ? void 0 : _.app]) == null ? void 0 : L.edit;
|
|
4486
|
-
}), p = M(() => t.consumerGroupId ? nt.Edit : nt.Create), S = M(() => !!a.fields.name && !w.value),
|
|
4487
|
-
var D, ge, _e, ce,
|
|
4496
|
+
}), p = M(() => t.consumerGroupId ? nt.Edit : nt.Create), S = M(() => !!a.fields.name && !w.value), C = M(() => JSON.stringify(a.fields) !== JSON.stringify(i)), v = (_, L = "", re = "") => {
|
|
4497
|
+
var D, ge, _e, ce, Be, De;
|
|
4488
4498
|
let q = `${(D = t.config) == null ? void 0 : D.apiBaseUrl}${$e.form[(ge = t.config) == null ? void 0 : ge.app][_]}`;
|
|
4489
|
-
return ((_e = t.config) == null ? void 0 : _e.app) === "konnect" ? q = q.replace(/{controlPlaneId}/gi, ((ce = t.config) == null ? void 0 : ce.controlPlaneId) || "") : ((
|
|
4499
|
+
return ((_e = t.config) == null ? void 0 : _e.app) === "konnect" ? q = q.replace(/{controlPlaneId}/gi, ((ce = t.config) == null ? void 0 : ce.controlPlaneId) || "") : ((Be = t.config) == null ? void 0 : Be.app) === "kongManager" && (q = q.replace(/\/{workspace}/gi, (De = t.config) != null && De.workspace ? `/${t.config.workspace}` : "")), q = q.replace(/{id}/gi, L || t.consumerGroupId), (_ === "addConsumer" || _ === "removeConsumer") && (q = q.replace(/{consumerId}/gi, re)), q;
|
|
4490
4500
|
}, I = () => {
|
|
4491
4501
|
var _;
|
|
4492
4502
|
o.push(((_ = t.config) == null ? void 0 : _.cancelRoute) || { name: "consumer-group-list" });
|
|
@@ -4502,19 +4512,19 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4502
4512
|
a.fields.consumers = ((ge = _ == null ? void 0 : _.consumers) == null ? void 0 : ge.map((ce) => ce.id)) || [];
|
|
4503
4513
|
else
|
|
4504
4514
|
try {
|
|
4505
|
-
const { data: ce } = await g.get(
|
|
4506
|
-
a.fields.consumers = "consumers" in ce ? (_e = ce == null ? void 0 : ce.consumers) == null ? void 0 : _e.map((
|
|
4515
|
+
const { data: ce } = await g.get(v("getConsumers"));
|
|
4516
|
+
a.fields.consumers = "consumers" in ce ? (_e = ce == null ? void 0 : ce.consumers) == null ? void 0 : _e.map((Be) => Be.id) : [];
|
|
4507
4517
|
} catch (ce) {
|
|
4508
4518
|
x(ce);
|
|
4509
4519
|
}
|
|
4510
4520
|
Object.assign(i, a.fields);
|
|
4511
|
-
}, w = M(() => /^[0-9a-zA-Z.\-_~]*$/.test(a.fields.name) ? "" : r("consumer_groups.form.validation_errors.name")),
|
|
4521
|
+
}, w = M(() => /^[0-9a-zA-Z.\-_~]*$/.test(a.fields.name) ? "" : r("consumer_groups.form.validation_errors.name")), B = () => {
|
|
4512
4522
|
var _, L;
|
|
4513
4523
|
return {
|
|
4514
4524
|
name: a.fields.name,
|
|
4515
4525
|
tags: (L = (_ = a.fields.tags.split(",")) == null ? void 0 : _.map((re) => String(re || "").trim())) == null ? void 0 : L.filter((re) => re !== "")
|
|
4516
4526
|
};
|
|
4517
|
-
},
|
|
4527
|
+
}, N = async (_, L = "") => await g.post(v("addConsumer", L, _), { consumer: _ }), k = async (_, L = "") => await g.delete(v("removeConsumer", L, _)), x = (_) => {
|
|
4518
4528
|
a.errorMessage = f(_), n("error", _);
|
|
4519
4529
|
}, T = (_ = t.consumerGroupId) => {
|
|
4520
4530
|
Object.assign(i, a.fields), n("update", { ...a.fields, id: _ });
|
|
@@ -4527,14 +4537,14 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4527
4537
|
}, J = async () => {
|
|
4528
4538
|
let _ = "";
|
|
4529
4539
|
try {
|
|
4530
|
-
const { data: L } = await g.post(
|
|
4540
|
+
const { data: L } = await g.post(v("create"), B());
|
|
4531
4541
|
_ = "item" in L ? L.item.id : L.id;
|
|
4532
4542
|
} catch (L) {
|
|
4533
4543
|
x(L);
|
|
4534
4544
|
}
|
|
4535
4545
|
if (a.fields.consumers.length > 0 && _)
|
|
4536
4546
|
try {
|
|
4537
|
-
const L = a.fields.consumers.map((q) =>
|
|
4547
|
+
const L = a.fields.consumers.map((q) => N(q, _)), re = await Promise.allSettled(L);
|
|
4538
4548
|
P(re, r("consumer_groups.errors.add_consumer"), _);
|
|
4539
4549
|
} catch (L) {
|
|
4540
4550
|
x(L);
|
|
@@ -4544,7 +4554,7 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4544
4554
|
}, Q = async () => {
|
|
4545
4555
|
var re;
|
|
4546
4556
|
try {
|
|
4547
|
-
((re = t.config) == null ? void 0 : re.app) === "konnect" ? await g.put(
|
|
4557
|
+
((re = t.config) == null ? void 0 : re.app) === "konnect" ? await g.put(v("edit"), B()) : await g.patch(v("edit"), B());
|
|
4548
4558
|
} catch (q) {
|
|
4549
4559
|
x(q);
|
|
4550
4560
|
}
|
|
@@ -4561,7 +4571,7 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4561
4571
|
}
|
|
4562
4572
|
if (_.length > 0)
|
|
4563
4573
|
try {
|
|
4564
|
-
const q = _.map((ge) =>
|
|
4574
|
+
const q = _.map((ge) => N(ge)), D = await Promise.allSettled(q);
|
|
4565
4575
|
P(D, r("consumer_groups.errors.add_consumer"));
|
|
4566
4576
|
} catch (q) {
|
|
4567
4577
|
x(q);
|
|
@@ -4578,13 +4588,13 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4578
4588
|
await d();
|
|
4579
4589
|
}), (_, L) => {
|
|
4580
4590
|
const re = U("KInput"), q = U("KMultiselect");
|
|
4581
|
-
return m(), j("div",
|
|
4582
|
-
K(y(
|
|
4583
|
-
"can-submit": S.value &&
|
|
4591
|
+
return m(), j("div", ll, [
|
|
4592
|
+
K(y(hs), {
|
|
4593
|
+
"can-submit": S.value && C.value,
|
|
4584
4594
|
config: e.config,
|
|
4585
4595
|
"edit-id": e.consumerGroupId,
|
|
4586
4596
|
"error-message": a.errorMessage || y(c) || w.value,
|
|
4587
|
-
"fetch-url":
|
|
4597
|
+
"fetch-url": b.value,
|
|
4588
4598
|
"is-readonly": a.readonly,
|
|
4589
4599
|
onCancel: I,
|
|
4590
4600
|
"onFetch:error": L[3] || (L[3] = (D) => ne(D)),
|
|
@@ -4649,8 +4659,8 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4649
4659
|
"item-template": h(({ item: D }) => {
|
|
4650
4660
|
var ge, _e, ce;
|
|
4651
4661
|
return [
|
|
4652
|
-
R("div",
|
|
4653
|
-
(ge = D == null ? void 0 : D.data) != null && ge.username && ((_e = D == null ? void 0 : D.data) != null && _e.custom_id) ? (m(), j("div",
|
|
4662
|
+
R("div", ul, F(D.label), 1),
|
|
4663
|
+
(ge = D == null ? void 0 : D.data) != null && ge.username && ((_e = D == null ? void 0 : D.data) != null && _e.custom_id) ? (m(), j("div", cl, F((ce = D == null ? void 0 : D.data) == null ? void 0 : ce.custom_id), 1)) : G("", !0)
|
|
4654
4664
|
];
|
|
4655
4665
|
}),
|
|
4656
4666
|
_: 1
|
|
@@ -4665,7 +4675,7 @@ const _l = /* @__PURE__ */ Kt(il, [["__scopeId", "data-v-80c4522c"]]), sl = { cl
|
|
|
4665
4675
|
};
|
|
4666
4676
|
}
|
|
4667
4677
|
});
|
|
4668
|
-
const
|
|
4678
|
+
const Il = /* @__PURE__ */ Kt(dl, [["__scopeId", "data-v-102d40d2"]]), pl = { class: "kong-ui-consumer-group-entity-config-card" }, Al = /* @__PURE__ */ ae({
|
|
4669
4679
|
__name: "ConsumerGroupConfigCard",
|
|
4670
4680
|
props: {
|
|
4671
4681
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4701,8 +4711,8 @@ const wl = /* @__PURE__ */ Kt(cl, [["__scopeId", "data-v-102d40d2"]]), dl = { cl
|
|
|
4701
4711
|
tooltip: t("consumer_groups.form.fields.tags.tooltip")
|
|
4702
4712
|
}
|
|
4703
4713
|
});
|
|
4704
|
-
return (a, i) => (m(), j("div",
|
|
4705
|
-
K(y(
|
|
4714
|
+
return (a, i) => (m(), j("div", pl, [
|
|
4715
|
+
K(y(fs), {
|
|
4706
4716
|
config: e.config,
|
|
4707
4717
|
"config-card-doc": e.configCardDoc,
|
|
4708
4718
|
"config-schema": o.value,
|
|
@@ -4718,7 +4728,7 @@ const wl = /* @__PURE__ */ Kt(cl, [["__scopeId", "data-v-102d40d2"]]), dl = { cl
|
|
|
4718
4728
|
}
|
|
4719
4729
|
});
|
|
4720
4730
|
export {
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
|
|
4731
|
+
Al as ConsumerGroupConfigCard,
|
|
4732
|
+
Il as ConsumerGroupForm,
|
|
4733
|
+
wl as ConsumerGroupList
|
|
4724
4734
|
};
|