@kong-ui-public/entities-consumers 1.2.2-pr.759.d0a1ea1c.0 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as te, ref as F, computed as j, watch as ke, renderSlot as J, createCommentVNode as G, unref as m, useSlots as Ze, onBeforeMount as Qe, resolveComponent as q, openBlock as f, createBlock as
|
|
2
|
-
import { useRouter as
|
|
3
|
-
import { createI18n as
|
|
4
|
-
import
|
|
5
|
-
import { MethodsArray as
|
|
6
|
-
const
|
|
1
|
+
import { defineComponent as te, ref as F, computed as j, watch as ke, renderSlot as J, createCommentVNode as G, unref as m, useSlots as Ze, onBeforeMount as Qe, resolveComponent as q, openBlock as f, createBlock as U, createSlots as ve, withCtx as y, createElementVNode as B, createTextVNode as W, toDisplayString as M, createVNode as O, createElementBlock as x, renderList as ce, Fragment as pe, normalizeClass as Ae, withModifiers as Ge, withDirectives as Ve, vShow as De, useCssVars as sa, resolveDynamicComponent as Ne, normalizeProps as la, guardReactiveProps as ua, mergeProps as lt, onMounted as ca, onUnmounted as da, normalizeStyle as pa, inject as fa, pushScopeId as ma, popScopeId as ga, reactive as Bt } from "vue";
|
|
2
|
+
import { useRouter as gt } from "vue-router";
|
|
3
|
+
import { createI18n as yt, i18nTComponent as rn } from "@kong-ui-public/i18n";
|
|
4
|
+
import ya from "axios";
|
|
5
|
+
import { MethodsArray as ha } from "@kong/kongponents";
|
|
6
|
+
const va = {
|
|
7
7
|
list: {
|
|
8
8
|
table_headers: {
|
|
9
9
|
username: "Username",
|
|
@@ -95,19 +95,19 @@ const ha = {
|
|
|
95
95
|
tooltip: "An optional set of strings associated with the Consumer for grouping and filtering."
|
|
96
96
|
}
|
|
97
97
|
}
|
|
98
|
-
},
|
|
99
|
-
consumers:
|
|
98
|
+
}, ba = {
|
|
99
|
+
consumers: va
|
|
100
100
|
};
|
|
101
|
-
function
|
|
102
|
-
const e =
|
|
101
|
+
function Ca() {
|
|
102
|
+
const e = yt("en-us", ba);
|
|
103
103
|
return {
|
|
104
104
|
i18n: e,
|
|
105
|
-
i18nT:
|
|
105
|
+
i18nT: rn(e)
|
|
106
106
|
// Translation component <i18n-t>
|
|
107
107
|
};
|
|
108
108
|
}
|
|
109
109
|
const Xe = {
|
|
110
|
-
useI18n:
|
|
110
|
+
useI18n: Ca
|
|
111
111
|
}, Te = "/api/runtime_groups/{controlPlaneId}", $e = "/{workspace}", Se = {
|
|
112
112
|
list: {
|
|
113
113
|
konnect: {
|
|
@@ -134,17 +134,17 @@ const Xe = {
|
|
|
134
134
|
}
|
|
135
135
|
}
|
|
136
136
|
};
|
|
137
|
-
var
|
|
138
|
-
function
|
|
137
|
+
var sn = /* @__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))(sn || {}), ut = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(ut || {}), _e = /* @__PURE__ */ ((e) => (e[e.Loading = 0] = "Loading", e[e.Idle = 1] = "Idle", e[e.NoResults = 2] = "NoResults", e[e.Error = 3] = "Error", e))(_e || {}), X = /* @__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))(X || {}), ue = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e))(ue || {});
|
|
138
|
+
function ht(e = {}) {
|
|
139
139
|
return {
|
|
140
|
-
axiosInstance:
|
|
140
|
+
axiosInstance: ya.create({
|
|
141
141
|
withCredentials: !0,
|
|
142
142
|
timeout: 3e4,
|
|
143
143
|
...e
|
|
144
144
|
})
|
|
145
145
|
};
|
|
146
146
|
}
|
|
147
|
-
function
|
|
147
|
+
function ka() {
|
|
148
148
|
return {
|
|
149
149
|
debounce: (e, n) => {
|
|
150
150
|
let t;
|
|
@@ -156,12 +156,12 @@ function Ca() {
|
|
|
156
156
|
}
|
|
157
157
|
};
|
|
158
158
|
}
|
|
159
|
-
const
|
|
159
|
+
const ot = "khcp-user-table-preferences", wa = {
|
|
160
160
|
pageSize: 30,
|
|
161
161
|
sortColumnKey: void 0,
|
|
162
162
|
sortColumnOrder: void 0
|
|
163
163
|
};
|
|
164
|
-
function
|
|
164
|
+
function _a() {
|
|
165
165
|
const e = (t) => {
|
|
166
166
|
if (typeof t == "string")
|
|
167
167
|
try {
|
|
@@ -171,31 +171,31 @@ function wa() {
|
|
|
171
171
|
return;
|
|
172
172
|
}
|
|
173
173
|
}, n = () => {
|
|
174
|
-
const t = e(localStorage.getItem(
|
|
174
|
+
const t = e(localStorage.getItem(ot));
|
|
175
175
|
return !t || !Object.keys(t).length ? /* @__PURE__ */ new Map() : new Map(Object.entries(t));
|
|
176
176
|
};
|
|
177
177
|
return {
|
|
178
178
|
setTablePreferences: (t, a) => {
|
|
179
179
|
try {
|
|
180
180
|
const o = n();
|
|
181
|
-
o.set(t, a), localStorage.setItem(
|
|
181
|
+
o.set(t, a), localStorage.setItem(ot, JSON.stringify(Object.fromEntries(o.entries())));
|
|
182
182
|
} catch (o) {
|
|
183
183
|
console.error("useTablePreferences(setTablePreferences)", o);
|
|
184
184
|
}
|
|
185
185
|
},
|
|
186
186
|
getTablePreferences: (t) => {
|
|
187
187
|
const a = n();
|
|
188
|
-
return (a == null ? void 0 : a.get(t)) || void 0 ||
|
|
188
|
+
return (a == null ? void 0 : a.get(t)) || void 0 || wa;
|
|
189
189
|
},
|
|
190
190
|
deleteAllTablePreferences: () => {
|
|
191
|
-
localStorage.removeItem(
|
|
191
|
+
localStorage.removeItem(ot);
|
|
192
192
|
}
|
|
193
193
|
};
|
|
194
194
|
}
|
|
195
|
-
const
|
|
195
|
+
const Ia = {
|
|
196
196
|
message: "Are you sure you want to delete this {entityType}?",
|
|
197
197
|
messageWithName: "Are you sure you want to delete this {entityType} {entityName}?"
|
|
198
|
-
},
|
|
198
|
+
}, Aa = {
|
|
199
199
|
actions: {
|
|
200
200
|
save: "Save",
|
|
201
201
|
cancel: "Cancel",
|
|
@@ -204,13 +204,13 @@ const _a = {
|
|
|
204
204
|
errors: {
|
|
205
205
|
edit: "The entity could not be edited at this time."
|
|
206
206
|
}
|
|
207
|
-
},
|
|
207
|
+
}, Sa = {
|
|
208
208
|
emptyState: {
|
|
209
209
|
noSearchResultsTitle: "No results found",
|
|
210
210
|
noSearchResultsMessage: "Please adjust the criteria and try again.",
|
|
211
211
|
noSearchResultsCtaText: "Clear"
|
|
212
212
|
}
|
|
213
|
-
},
|
|
213
|
+
}, xa = {
|
|
214
214
|
title: "Configuration",
|
|
215
215
|
actions: {
|
|
216
216
|
copy: "Copy JSON"
|
|
@@ -245,7 +245,7 @@ const _a = {
|
|
|
245
245
|
entryTitle: "Entry {index}",
|
|
246
246
|
structuredFormat: "Structured"
|
|
247
247
|
}
|
|
248
|
-
},
|
|
248
|
+
}, Ta = {
|
|
249
249
|
filterButtonText: "Filter",
|
|
250
250
|
fieldLabel: "Filter by:",
|
|
251
251
|
inputPlaceholder: "Enter a value",
|
|
@@ -253,15 +253,15 @@ const _a = {
|
|
|
253
253
|
applyButtonText: "Apply",
|
|
254
254
|
clearButtonText: "Clear",
|
|
255
255
|
clearAllButtonText: "Clear all filters"
|
|
256
|
-
},
|
|
256
|
+
}, $a = {
|
|
257
257
|
errors: {
|
|
258
258
|
fetch: "Could not fetch available items",
|
|
259
259
|
invalid: "Please select a valid value"
|
|
260
260
|
}
|
|
261
|
-
},
|
|
261
|
+
}, Ma = {
|
|
262
262
|
unexpected: "An unexpected error has occurred",
|
|
263
263
|
dataKeyUndefined: 'The data key "{dataKey}" does not exist in the response.'
|
|
264
|
-
},
|
|
264
|
+
}, Oa = {
|
|
265
265
|
enable: {
|
|
266
266
|
title: "Enable {entityType}",
|
|
267
267
|
message: "Are you sure you want to enable the {entityType} {entityName}?",
|
|
@@ -272,32 +272,32 @@ const _a = {
|
|
|
272
272
|
message: "Are you sure you want to disable the {entityType} {entityName}?",
|
|
273
273
|
confirmText: "Yes, disable"
|
|
274
274
|
}
|
|
275
|
-
},
|
|
276
|
-
deleteModal:
|
|
277
|
-
baseForm:
|
|
278
|
-
baseTable:
|
|
279
|
-
baseConfigCard:
|
|
280
|
-
filter:
|
|
281
|
-
debouncedFilter:
|
|
282
|
-
errors:
|
|
283
|
-
toggleModal:
|
|
275
|
+
}, ja = {
|
|
276
|
+
deleteModal: Ia,
|
|
277
|
+
baseForm: Aa,
|
|
278
|
+
baseTable: Sa,
|
|
279
|
+
baseConfigCard: xa,
|
|
280
|
+
filter: Ta,
|
|
281
|
+
debouncedFilter: $a,
|
|
282
|
+
errors: Ma,
|
|
283
|
+
toggleModal: Oa
|
|
284
284
|
};
|
|
285
|
-
function
|
|
286
|
-
const e =
|
|
285
|
+
function vt() {
|
|
286
|
+
const e = yt("en-us", ja);
|
|
287
287
|
return {
|
|
288
288
|
i18n: e,
|
|
289
|
-
i18nT:
|
|
289
|
+
i18nT: rn(e)
|
|
290
290
|
// Translation component <i18n-t>
|
|
291
291
|
};
|
|
292
292
|
}
|
|
293
|
-
function
|
|
293
|
+
function Ea(e, n, t, a = {
|
|
294
294
|
fetchedItemsKey: "data",
|
|
295
295
|
searchKeys: ["id"]
|
|
296
296
|
}) {
|
|
297
297
|
t || (t = "100");
|
|
298
|
-
const { axiosInstance: o } =
|
|
298
|
+
const { axiosInstance: o } = ht({
|
|
299
299
|
headers: e.requestHeaders
|
|
300
|
-
}), { i18n: { t: r } } =
|
|
300
|
+
}), { i18n: { t: r } } = vt(), { debounce: i } = ka(), s = i(async (v) => {
|
|
301
301
|
await b(v);
|
|
302
302
|
}, 200), l = F(!1), c = F(""), d = F(""), u = F([]), h = F(void 0), g = m(n);
|
|
303
303
|
let C = `${e.apiBaseUrl}${g}`;
|
|
@@ -348,14 +348,14 @@ function ja(e, n, t, a = {
|
|
|
348
348
|
debouncedQueryChange: s
|
|
349
349
|
};
|
|
350
350
|
}
|
|
351
|
-
function
|
|
351
|
+
function Fa(e, n) {
|
|
352
352
|
const t = m(n), a = j(
|
|
353
353
|
() => e.apiBaseUrl.startsWith("/") ? new URL(`${window.location.origin}${t}`) : new URL(t)
|
|
354
354
|
);
|
|
355
355
|
return a.value.search = "", (o) => `${a.value.href}/${o}`;
|
|
356
356
|
}
|
|
357
|
-
function
|
|
358
|
-
const { i18n: { t: e } } =
|
|
357
|
+
function Ba() {
|
|
358
|
+
const { i18n: { t: e } } = vt();
|
|
359
359
|
return {
|
|
360
360
|
getMessageFromError: (n) => {
|
|
361
361
|
var t, a, o;
|
|
@@ -382,7 +382,7 @@ function Fa() {
|
|
|
382
382
|
}
|
|
383
383
|
};
|
|
384
384
|
}
|
|
385
|
-
function
|
|
385
|
+
function ln(e, n) {
|
|
386
386
|
const t = F(m(e)), a = F(m(n)), o = j(
|
|
387
387
|
() => !!(t.value.app === "konnect" || t.value.isExactMatch)
|
|
388
388
|
), r = j(
|
|
@@ -400,10 +400,10 @@ function sn(e, n) {
|
|
|
400
400
|
}
|
|
401
401
|
};
|
|
402
402
|
}
|
|
403
|
-
function
|
|
404
|
-
const a = m(n), { axiosInstance: o } =
|
|
403
|
+
function Ka(e, n, t = "data") {
|
|
404
|
+
const a = m(n), { axiosInstance: o } = ht({
|
|
405
405
|
headers: e.requestHeaders
|
|
406
|
-
}), r =
|
|
406
|
+
}), r = ln(e, a), i = F({
|
|
407
407
|
status: _e.Idle
|
|
408
408
|
});
|
|
409
409
|
return { fetcher: async (s) => {
|
|
@@ -442,92 +442,92 @@ function Ba(e, n, t = "data") {
|
|
|
442
442
|
}
|
|
443
443
|
}, fetcherState: i };
|
|
444
444
|
}
|
|
445
|
-
function
|
|
445
|
+
function Na() {
|
|
446
446
|
return {
|
|
447
447
|
getPropValue: (e, n) => (n == null ? void 0 : n[e]) ?? void 0
|
|
448
448
|
};
|
|
449
449
|
}
|
|
450
|
-
function
|
|
450
|
+
function qa() {
|
|
451
451
|
return {
|
|
452
452
|
convertKeyToTitle: (e, n = "_") => e ? e.split(n).map((t) => t.toLowerCase() === "id" ? t.toUpperCase() : t.charAt(0).toUpperCase() + t.substring(1)).join(" ") : ""
|
|
453
453
|
};
|
|
454
454
|
}
|
|
455
|
-
const
|
|
455
|
+
const un = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, Kt = (e) => {
|
|
456
456
|
if (typeof e != "string")
|
|
457
457
|
throw new TypeError("Invalid argument expected string");
|
|
458
|
-
const n = e.match(
|
|
458
|
+
const n = e.match(un);
|
|
459
459
|
if (!n)
|
|
460
460
|
throw new Error(`Invalid argument not valid semver ('${e}' received)`);
|
|
461
461
|
return n.shift(), n;
|
|
462
|
-
},
|
|
462
|
+
}, Nt = (e) => e === "*" || e === "x" || e === "X", qt = (e) => {
|
|
463
463
|
const n = parseInt(e, 10);
|
|
464
464
|
return isNaN(n) ? e : n;
|
|
465
|
-
},
|
|
466
|
-
if (
|
|
465
|
+
}, La = (e, n) => typeof e != typeof n ? [String(e), String(n)] : [e, n], Pa = (e, n) => {
|
|
466
|
+
if (Nt(e) || Nt(n))
|
|
467
467
|
return 0;
|
|
468
|
-
const [t, a] =
|
|
468
|
+
const [t, a] = La(qt(e), qt(n));
|
|
469
469
|
return t > a ? 1 : t < a ? -1 : 0;
|
|
470
|
-
},
|
|
470
|
+
}, Lt = (e, n) => {
|
|
471
471
|
for (let t = 0; t < Math.max(e.length, n.length); t++) {
|
|
472
|
-
const a =
|
|
472
|
+
const a = Pa(e[t] || "0", n[t] || "0");
|
|
473
473
|
if (a !== 0)
|
|
474
474
|
return a;
|
|
475
475
|
}
|
|
476
476
|
return 0;
|
|
477
|
-
},
|
|
478
|
-
const t =
|
|
479
|
-
return i !== 0 ? i : o && r ?
|
|
480
|
-
},
|
|
481
|
-
|
|
482
|
-
const a =
|
|
483
|
-
return
|
|
484
|
-
},
|
|
477
|
+
}, Ua = (e, n) => {
|
|
478
|
+
const t = Kt(e), a = Kt(n), o = t.pop(), r = a.pop(), i = Lt(t, a);
|
|
479
|
+
return i !== 0 ? i : o && r ? Lt(o.split("."), r.split(".")) : o || r ? o ? -1 : 1 : 0;
|
|
480
|
+
}, Pt = (e, n, t) => {
|
|
481
|
+
Ra(t);
|
|
482
|
+
const a = Ua(e, n);
|
|
483
|
+
return cn[t].includes(a);
|
|
484
|
+
}, cn = {
|
|
485
485
|
">": [1],
|
|
486
486
|
">=": [0, 1],
|
|
487
487
|
"=": [0],
|
|
488
488
|
"<=": [-1, 0],
|
|
489
489
|
"<": [-1],
|
|
490
490
|
"!=": [-1, 1]
|
|
491
|
-
},
|
|
491
|
+
}, Ut = Object.keys(cn), Ra = (e) => {
|
|
492
492
|
if (typeof e != "string")
|
|
493
493
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
494
|
-
if (
|
|
495
|
-
throw new Error(`Invalid operator, expected one of ${
|
|
496
|
-
},
|
|
497
|
-
function
|
|
494
|
+
if (Ut.indexOf(e) === -1)
|
|
495
|
+
throw new Error(`Invalid operator, expected one of ${Ut.join("|")}`);
|
|
496
|
+
}, Va = (e) => typeof e == "string" && /^[v\d]/.test(e) && un.test(e);
|
|
497
|
+
function Da(e) {
|
|
498
498
|
const { gatewayInfo: n, supportedRange: t } = e;
|
|
499
499
|
if (!n)
|
|
500
500
|
return !0;
|
|
501
501
|
const { edition: a, version: o } = n;
|
|
502
|
-
if (!
|
|
502
|
+
if (!Va(o))
|
|
503
503
|
return console.error("Invalid version"), !1;
|
|
504
504
|
const r = t[a];
|
|
505
505
|
if (!r)
|
|
506
506
|
return !1;
|
|
507
507
|
const [i, s] = r;
|
|
508
|
-
return !(i &&
|
|
508
|
+
return !(i && Pt(o, i, "<") || s && Pt(o, s, ">"));
|
|
509
509
|
}
|
|
510
510
|
const oe = {
|
|
511
|
-
useAxios:
|
|
512
|
-
useDebouncedFilter:
|
|
513
|
-
useDeleteUrlBuilder:
|
|
514
|
-
useErrors:
|
|
515
|
-
useFetcher:
|
|
516
|
-
useFetchUrlBuilder:
|
|
517
|
-
useHelpers:
|
|
518
|
-
useStringHelpers:
|
|
519
|
-
useI18n:
|
|
520
|
-
useGatewayFeatureSupported:
|
|
521
|
-
},
|
|
511
|
+
useAxios: ht,
|
|
512
|
+
useDebouncedFilter: Ea,
|
|
513
|
+
useDeleteUrlBuilder: Fa,
|
|
514
|
+
useErrors: Ba,
|
|
515
|
+
useFetcher: Ka,
|
|
516
|
+
useFetchUrlBuilder: ln,
|
|
517
|
+
useHelpers: Na,
|
|
518
|
+
useStringHelpers: qa,
|
|
519
|
+
useI18n: vt,
|
|
520
|
+
useGatewayFeatureSupported: Da
|
|
521
|
+
}, Ga = {
|
|
522
522
|
fail: "Failed to copy id to clipboard",
|
|
523
523
|
success: {
|
|
524
524
|
prefix: "Successfully",
|
|
525
525
|
content: " copied to clipboard"
|
|
526
526
|
}
|
|
527
|
-
},
|
|
528
|
-
message:
|
|
529
|
-
iconTitle:
|
|
530
|
-
},
|
|
527
|
+
}, Ha = "Copy to clipboard", Ya = {
|
|
528
|
+
message: Ga,
|
|
529
|
+
iconTitle: Ha
|
|
530
|
+
}, za = "kong-ui-copy-uuid-notify", Ja = { class: "kong-ui-copy-uuid" }, Wa = ["onClick"], Rt = 15, Za = /* @__PURE__ */ te({
|
|
531
531
|
__name: "CopyUuid",
|
|
532
532
|
props: {
|
|
533
533
|
uuid: {
|
|
@@ -571,7 +571,7 @@ const oe = {
|
|
|
571
571
|
},
|
|
572
572
|
emits: ["success", "error"],
|
|
573
573
|
setup(e, { emit: n }) {
|
|
574
|
-
const t = e, { t: a } =
|
|
574
|
+
const t = e, { t: a } = yt("en-us", Ya), o = t.notify || fa(za, () => {
|
|
575
575
|
}), r = j(() => t.idTooltip ? {
|
|
576
576
|
label: t.idTooltip,
|
|
577
577
|
positionFixed: !0,
|
|
@@ -595,7 +595,7 @@ const oe = {
|
|
|
595
595
|
}), i.value ? d(a("message.fail")) : n("error", t.uuid);
|
|
596
596
|
return;
|
|
597
597
|
}
|
|
598
|
-
const g = t.uuid.length >
|
|
598
|
+
const g = t.uuid.length > Rt, C = t.format === "hidden" || t.format === "redacted" ? a("message.success.prefix") : `"${t.uuid.substring(0, Rt) + (g ? "..." : "")}"`;
|
|
599
599
|
typeof o == "function" && o({
|
|
600
600
|
type: "success",
|
|
601
601
|
message: `${C}${a("message.success.content")}`
|
|
@@ -603,8 +603,8 @@ const oe = {
|
|
|
603
603
|
};
|
|
604
604
|
return (h, g) => {
|
|
605
605
|
const C = q("KIcon"), k = q("KClipboardProvider");
|
|
606
|
-
return f(), x("div",
|
|
607
|
-
e.format !== "hidden" ? (f(),
|
|
606
|
+
return f(), x("div", Ja, [
|
|
607
|
+
e.format !== "hidden" ? (f(), U(Ne(e.idTooltip ? "KTooltip" : "div"), lt({ key: 0 }, r.value, { "data-testid": "copy-id" }), {
|
|
608
608
|
default: y(() => [
|
|
609
609
|
B("div", {
|
|
610
610
|
class: Ae([
|
|
@@ -616,7 +616,7 @@ const oe = {
|
|
|
616
616
|
]),
|
|
617
617
|
_: 1
|
|
618
618
|
}, 16)) : G("", !0),
|
|
619
|
-
(f(),
|
|
619
|
+
(f(), U(Ne(e.tooltip ? "KTooltip" : "div"), lt(l.value, { class: "uuid-icon-wrapper" }), {
|
|
620
620
|
default: y(() => [
|
|
621
621
|
O(k, null, {
|
|
622
622
|
default: y(({ copyToClipboard: p }) => [
|
|
@@ -634,7 +634,7 @@ const oe = {
|
|
|
634
634
|
size: "16",
|
|
635
635
|
title: m(a)("iconTitle")
|
|
636
636
|
}, null, 8, ["color", "hide-title", "title"])
|
|
637
|
-
], 8,
|
|
637
|
+
], 8, Wa)
|
|
638
638
|
]),
|
|
639
639
|
_: 1
|
|
640
640
|
})
|
|
@@ -644,15 +644,15 @@ const oe = {
|
|
|
644
644
|
]);
|
|
645
645
|
};
|
|
646
646
|
}
|
|
647
|
-
}),
|
|
647
|
+
}), Qa = (e, n) => {
|
|
648
648
|
const t = e.__vccOpts || e;
|
|
649
649
|
for (const [a, o] of n)
|
|
650
650
|
t[a] = o;
|
|
651
651
|
return t;
|
|
652
|
-
},
|
|
652
|
+
}, dn = /* @__PURE__ */ Qa(Za, [["__scopeId", "data-v-bfdaf6f7"]]), Xa = {
|
|
653
653
|
key: 0,
|
|
654
654
|
class: "config-card-fieldset-title"
|
|
655
|
-
},
|
|
655
|
+
}, eo = /* @__PURE__ */ te({
|
|
656
656
|
__name: "JsonCardItem",
|
|
657
657
|
props: {
|
|
658
658
|
item: {
|
|
@@ -676,14 +676,14 @@ const oe = {
|
|
|
676
676
|
var l;
|
|
677
677
|
return n.isArrayItem ? (l = r.value) != null && l.name ? a(r.value.name, "_") : t("baseConfigCard.general.entryTitle", { index: n.index }) : "";
|
|
678
678
|
});
|
|
679
|
-
return (l, c) => (f(),
|
|
679
|
+
return (l, c) => (f(), U(Ne(e.isArrayItem ? "fieldset" : "div"), {
|
|
680
680
|
class: Ae(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
681
681
|
}, {
|
|
682
682
|
default: y(() => [
|
|
683
|
-
e.isArrayItem ? (f(), x("legend",
|
|
683
|
+
e.isArrayItem ? (f(), x("legend", Xa, [
|
|
684
684
|
B("b", null, M(s.value), 1)
|
|
685
685
|
])) : G("", !0),
|
|
686
|
-
(f(!0), x(pe, null, ce(Object.keys(i.value), (d, u) => (f(),
|
|
686
|
+
(f(!0), x(pe, null, ce(Object.keys(i.value), (d, u) => (f(), U(bt, {
|
|
687
687
|
key: `${o.value}-property-${u}`,
|
|
688
688
|
item: {
|
|
689
689
|
key: d,
|
|
@@ -700,7 +700,7 @@ const oe = {
|
|
|
700
700
|
for (const [a, o] of n)
|
|
701
701
|
t[a] = o;
|
|
702
702
|
return t;
|
|
703
|
-
},
|
|
703
|
+
}, pn = /* @__PURE__ */ me(eo, [["__scopeId", "data-v-68ca83ec"]]), to = /* @__PURE__ */ te({
|
|
704
704
|
__name: "InternalLinkItem",
|
|
705
705
|
props: {
|
|
706
706
|
item: {
|
|
@@ -727,7 +727,7 @@ const oe = {
|
|
|
727
727
|
]);
|
|
728
728
|
};
|
|
729
729
|
}
|
|
730
|
-
}),
|
|
730
|
+
}), no = /* @__PURE__ */ me(to, [["__scopeId", "data-v-7410504d"]]), ao = /* @__PURE__ */ te({
|
|
731
731
|
__name: "StatusBadge",
|
|
732
732
|
props: {
|
|
733
733
|
status: {
|
|
@@ -739,7 +739,7 @@ const oe = {
|
|
|
739
739
|
const { i18n: { t: n } } = oe.useI18n();
|
|
740
740
|
return (t, a) => {
|
|
741
741
|
const o = q("KBadge");
|
|
742
|
-
return f(),
|
|
742
|
+
return f(), U(o, {
|
|
743
743
|
appearance: e.status ? "success" : "neutral"
|
|
744
744
|
}, {
|
|
745
745
|
default: y(() => [
|
|
@@ -749,11 +749,11 @@ const oe = {
|
|
|
749
749
|
}, 8, ["appearance"]);
|
|
750
750
|
};
|
|
751
751
|
}
|
|
752
|
-
}),
|
|
752
|
+
}), oo = "#0044f4", ro = "#e0e4ea", io = "#3a3f51", so = "1px", lo = "20px", uo = { class: "config-card-details-row" }, co = ["data-testid"], po = ["data-testid"], fo = ["data-testid"], mo = ["data-testid"], go = { key: 1 }, yo = ["data-testid"], ho = ["data-testid"], vo = ["data-testid"], bo = ["data-testid"], Co = ["title"], ko = {
|
|
753
753
|
name: "ConfigCardItem",
|
|
754
|
-
components: { CopyUuid:
|
|
755
|
-
},
|
|
756
|
-
...
|
|
754
|
+
components: { CopyUuid: dn, JsonCardItem: pn, StatusBadge: ao, InternalLinkItem: no }
|
|
755
|
+
}, wo = /* @__PURE__ */ te({
|
|
756
|
+
...ko,
|
|
757
757
|
props: {
|
|
758
758
|
item: {
|
|
759
759
|
type: Object,
|
|
@@ -773,8 +773,8 @@ const oe = {
|
|
|
773
773
|
emits: ["navigation-click"],
|
|
774
774
|
setup(e, { emit: n }) {
|
|
775
775
|
const t = e;
|
|
776
|
-
|
|
777
|
-
"2c6ac268": c.value ? "none" : `solid ${m(
|
|
776
|
+
sa((u) => ({
|
|
777
|
+
"2c6ac268": c.value ? "none" : `solid ${m(so)} ${m(ro)}`,
|
|
778
778
|
c7a65802: l.value && i.value ? "block" : "flex",
|
|
779
779
|
"778426fe": l.value && i.value ? "100%" : t.slim ? "50%" : "25%",
|
|
780
780
|
"777f9b48": l.value && i.value ? "100%" : t.slim ? "50%" : "75%"
|
|
@@ -908,7 +908,7 @@ const oe = {
|
|
|
908
908
|
});
|
|
909
909
|
return (u, h) => {
|
|
910
910
|
const g = q("KLabel"), C = q("KBadge"), k = q("KMethodBadge");
|
|
911
|
-
return f(), x("div",
|
|
911
|
+
return f(), x("div", uo, [
|
|
912
912
|
B("div", {
|
|
913
913
|
class: "config-card-details-label",
|
|
914
914
|
"data-testid": `${e.item.key}-label`
|
|
@@ -929,13 +929,13 @@ const oe = {
|
|
|
929
929
|
J(u.$slots, "label-tooltip", {}, () => [
|
|
930
930
|
W(M(e.item.tooltip), 1)
|
|
931
931
|
], !0)
|
|
932
|
-
], 8,
|
|
932
|
+
], 8, po)
|
|
933
933
|
]),
|
|
934
934
|
key: "0"
|
|
935
935
|
} : void 0
|
|
936
936
|
]), 1024)
|
|
937
937
|
], !0)
|
|
938
|
-
], 8,
|
|
938
|
+
], 8, co),
|
|
939
939
|
B("div", {
|
|
940
940
|
class: "config-card-details-value",
|
|
941
941
|
"data-testid": `${e.item.key}-property-value`
|
|
@@ -943,14 +943,14 @@ const oe = {
|
|
|
943
943
|
J(u.$slots, e.item.key, {
|
|
944
944
|
rowValue: e.item.value
|
|
945
945
|
}, () => [
|
|
946
|
-
i.value ? (f(), x("div",
|
|
947
|
-
(f(),
|
|
946
|
+
i.value ? (f(), x("div", go, [
|
|
947
|
+
(f(), U(Ne(d.value.tag), la(ua(d.value.attrs)), {
|
|
948
948
|
default: y(() => [
|
|
949
949
|
d.value.additionalComponent === "KBadge" ? (f(), x("div", {
|
|
950
950
|
key: 0,
|
|
951
951
|
"data-testid": `${e.item.key}-badge-tags`
|
|
952
952
|
}, [
|
|
953
|
-
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(),
|
|
953
|
+
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(), U(C, {
|
|
954
954
|
key: `${e.item.key}-badge-tag-${b}`,
|
|
955
955
|
class: "config-badge",
|
|
956
956
|
"data-testid": `${e.item.key}-badge-tag-${b}`,
|
|
@@ -961,114 +961,114 @@ const oe = {
|
|
|
961
961
|
]),
|
|
962
962
|
_: 2
|
|
963
963
|
}, 1032, ["data-testid", "truncation-tooltip"]))), 128))
|
|
964
|
-
], 8,
|
|
964
|
+
], 8, yo)) : G("", !0),
|
|
965
965
|
d.value.additionalComponent === "CopyUuid" ? (f(), x("div", {
|
|
966
966
|
key: 1,
|
|
967
967
|
class: "copy-uuid-array",
|
|
968
968
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
969
969
|
}, [
|
|
970
|
-
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(),
|
|
970
|
+
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(), U(m(dn), lt(d.value.childAttrs, {
|
|
971
971
|
key: `${e.item.key}-copy-uuid-${b}`,
|
|
972
972
|
"data-testid": `${e.item.key}-copy-uuid-${b}`,
|
|
973
973
|
uuid: p
|
|
974
974
|
}), null, 16, ["data-testid", "uuid"]))), 128))
|
|
975
|
-
], 8,
|
|
975
|
+
], 8, ho)) : d.value.additionalComponent === "KMethodBadge" ? (f(), x("div", {
|
|
976
976
|
key: 2,
|
|
977
977
|
class: "method-badge-array",
|
|
978
978
|
"data-testid": `${e.item.key}-badge-methods`
|
|
979
979
|
}, [
|
|
980
|
-
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(),
|
|
980
|
+
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(), U(k, {
|
|
981
981
|
key: `${e.item.key}-badge-method-${b}`,
|
|
982
982
|
class: "config-badge",
|
|
983
983
|
"data-testid": `${e.item.key}-badge-method-${b}`,
|
|
984
984
|
"is-rounded": "",
|
|
985
985
|
label: p,
|
|
986
|
-
method: m(
|
|
986
|
+
method: m(ha).includes(p.toLowerCase()) ? p.toLowerCase() : "custom"
|
|
987
987
|
}, {
|
|
988
988
|
default: y(() => [
|
|
989
989
|
W(M(p), 1)
|
|
990
990
|
]),
|
|
991
991
|
_: 2
|
|
992
992
|
}, 1032, ["data-testid", "label", "method"]))), 128))
|
|
993
|
-
], 8,
|
|
993
|
+
], 8, vo)) : G("", !0),
|
|
994
994
|
d.value.additionalComponent === "JsonCardItem" ? (f(), x("div", {
|
|
995
995
|
key: 3,
|
|
996
996
|
"data-testid": `${t.item.key}-json-array-content`
|
|
997
997
|
}, [
|
|
998
|
-
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(),
|
|
998
|
+
(f(!0), x(pe, null, ce(e.item.value, (p, b) => (f(), U(pn, {
|
|
999
999
|
key: `json-array-item-${b}`,
|
|
1000
1000
|
index: b,
|
|
1001
1001
|
"is-array-item": "",
|
|
1002
1002
|
item: p
|
|
1003
1003
|
}, null, 8, ["index", "item"]))), 128))
|
|
1004
|
-
], 8,
|
|
1004
|
+
], 8, bo)) : (f(), x("span", {
|
|
1005
1005
|
key: 4,
|
|
1006
1006
|
class: Ae(["attrs-data-text", { truncated: e.truncated }]),
|
|
1007
1007
|
title: e.truncated ? e.item.value : void 0
|
|
1008
|
-
}, M(d.value.text), 11,
|
|
1008
|
+
}, M(d.value.text), 11, Co))
|
|
1009
1009
|
]),
|
|
1010
1010
|
_: 1
|
|
1011
1011
|
}, 16))
|
|
1012
1012
|
])) : (f(), x("div", {
|
|
1013
1013
|
key: 0,
|
|
1014
1014
|
"data-testid": `${e.item.key}-no-value`
|
|
1015
|
-
}, " – ", 8,
|
|
1015
|
+
}, " – ", 8, mo))
|
|
1016
1016
|
], !0)
|
|
1017
|
-
], 8,
|
|
1017
|
+
], 8, fo)
|
|
1018
1018
|
]);
|
|
1019
1019
|
};
|
|
1020
1020
|
}
|
|
1021
|
-
}),
|
|
1021
|
+
}), bt = /* @__PURE__ */ me(wo, [["__scopeId", "data-v-a3c5ab01"]]);
|
|
1022
1022
|
/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
|
|
1023
|
-
function
|
|
1023
|
+
function fn(e) {
|
|
1024
1024
|
return typeof e > "u" || e === null;
|
|
1025
1025
|
}
|
|
1026
|
-
function
|
|
1026
|
+
function _o(e) {
|
|
1027
1027
|
return typeof e == "object" && e !== null;
|
|
1028
1028
|
}
|
|
1029
|
-
function
|
|
1030
|
-
return Array.isArray(e) ? e :
|
|
1029
|
+
function Io(e) {
|
|
1030
|
+
return Array.isArray(e) ? e : fn(e) ? [] : [e];
|
|
1031
1031
|
}
|
|
1032
|
-
function
|
|
1032
|
+
function Ao(e, n) {
|
|
1033
1033
|
var t, a, o, r;
|
|
1034
1034
|
if (n)
|
|
1035
1035
|
for (r = Object.keys(n), t = 0, a = r.length; t < a; t += 1)
|
|
1036
1036
|
o = r[t], e[o] = n[o];
|
|
1037
1037
|
return e;
|
|
1038
1038
|
}
|
|
1039
|
-
function
|
|
1039
|
+
function So(e, n) {
|
|
1040
1040
|
var t = "", a;
|
|
1041
1041
|
for (a = 0; a < n; a += 1)
|
|
1042
1042
|
t += e;
|
|
1043
1043
|
return t;
|
|
1044
1044
|
}
|
|
1045
|
-
function
|
|
1045
|
+
function xo(e) {
|
|
1046
1046
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1047
1047
|
}
|
|
1048
|
-
var
|
|
1049
|
-
isNothing:
|
|
1050
|
-
isObject:
|
|
1051
|
-
toArray:
|
|
1052
|
-
repeat:
|
|
1053
|
-
isNegativeZero:
|
|
1054
|
-
extend:
|
|
1048
|
+
var To = fn, $o = _o, Mo = Io, Oo = So, jo = xo, Eo = Ao, ne = {
|
|
1049
|
+
isNothing: To,
|
|
1050
|
+
isObject: $o,
|
|
1051
|
+
toArray: Mo,
|
|
1052
|
+
repeat: Oo,
|
|
1053
|
+
isNegativeZero: jo,
|
|
1054
|
+
extend: Eo
|
|
1055
1055
|
};
|
|
1056
|
-
function
|
|
1056
|
+
function mn(e, n) {
|
|
1057
1057
|
var t = "", a = e.reason || "(unknown reason)";
|
|
1058
1058
|
return e.mark ? (e.mark.name && (t += 'in "' + e.mark.name + '" '), t += "(" + (e.mark.line + 1) + ":" + (e.mark.column + 1) + ")", !n && e.mark.snippet && (t += `
|
|
1059
1059
|
|
|
1060
1060
|
` + e.mark.snippet), a + " " + t) : a;
|
|
1061
1061
|
}
|
|
1062
1062
|
function qe(e, n) {
|
|
1063
|
-
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = n, this.message =
|
|
1063
|
+
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = n, this.message = mn(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack || "";
|
|
1064
1064
|
}
|
|
1065
1065
|
qe.prototype = Object.create(Error.prototype);
|
|
1066
1066
|
qe.prototype.constructor = qe;
|
|
1067
1067
|
qe.prototype.toString = function(e) {
|
|
1068
|
-
return this.name + ": " +
|
|
1068
|
+
return this.name + ": " + mn(this, e);
|
|
1069
1069
|
};
|
|
1070
|
-
var
|
|
1071
|
-
function
|
|
1070
|
+
var se = qe;
|
|
1071
|
+
function rt(e, n, t, a, o) {
|
|
1072
1072
|
var r = "", i = "", s = Math.floor(o / 2) - 1;
|
|
1073
1073
|
return a - n > s && (r = " ... ", n = a - s + r.length), t - a > s && (i = " ...", t = a + s - i.length), {
|
|
1074
1074
|
str: r + e.slice(n, t).replace(/\t/g, "→") + i,
|
|
@@ -1076,10 +1076,10 @@ function ot(e, n, t, a, o) {
|
|
|
1076
1076
|
// relative position
|
|
1077
1077
|
};
|
|
1078
1078
|
}
|
|
1079
|
-
function
|
|
1079
|
+
function it(e, n) {
|
|
1080
1080
|
return ne.repeat(" ", n - e.length) + e;
|
|
1081
1081
|
}
|
|
1082
|
-
function
|
|
1082
|
+
function Fo(e, n) {
|
|
1083
1083
|
if (n = Object.create(n || null), !e.buffer)
|
|
1084
1084
|
return null;
|
|
1085
1085
|
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);
|
|
@@ -1088,28 +1088,28 @@ function Eo(e, n) {
|
|
|
1088
1088
|
i < 0 && (i = a.length - 1);
|
|
1089
1089
|
var s = "", l, c, d = Math.min(e.line + n.linesAfter, o.length).toString().length, u = n.maxLength - (n.indent + d + 3);
|
|
1090
1090
|
for (l = 1; l <= n.linesBefore && !(i - l < 0); l++)
|
|
1091
|
-
c =
|
|
1091
|
+
c = rt(
|
|
1092
1092
|
e.buffer,
|
|
1093
1093
|
a[i - l],
|
|
1094
1094
|
o[i - l],
|
|
1095
1095
|
e.position - (a[i] - a[i - l]),
|
|
1096
1096
|
u
|
|
1097
|
-
), s = ne.repeat(" ", n.indent) +
|
|
1097
|
+
), s = ne.repeat(" ", n.indent) + it((e.line - l + 1).toString(), d) + " | " + c.str + `
|
|
1098
1098
|
` + s;
|
|
1099
|
-
for (c =
|
|
1099
|
+
for (c = rt(e.buffer, a[i], o[i], e.position, u), s += ne.repeat(" ", n.indent) + it((e.line + 1).toString(), d) + " | " + c.str + `
|
|
1100
1100
|
`, s += ne.repeat("-", n.indent + d + 3 + c.pos) + `^
|
|
1101
1101
|
`, l = 1; l <= n.linesAfter && !(i + l >= o.length); l++)
|
|
1102
|
-
c =
|
|
1102
|
+
c = rt(
|
|
1103
1103
|
e.buffer,
|
|
1104
1104
|
a[i + l],
|
|
1105
1105
|
o[i + l],
|
|
1106
1106
|
e.position - (a[i] - a[i + l]),
|
|
1107
1107
|
u
|
|
1108
|
-
), s += ne.repeat(" ", n.indent) +
|
|
1108
|
+
), s += ne.repeat(" ", n.indent) + it((e.line + l + 1).toString(), d) + " | " + c.str + `
|
|
1109
1109
|
`;
|
|
1110
1110
|
return s.replace(/\n$/, "");
|
|
1111
1111
|
}
|
|
1112
|
-
var
|
|
1112
|
+
var Bo = Fo, Ko = [
|
|
1113
1113
|
"kind",
|
|
1114
1114
|
"multi",
|
|
1115
1115
|
"resolve",
|
|
@@ -1120,12 +1120,12 @@ var Fo = Eo, Bo = [
|
|
|
1120
1120
|
"representName",
|
|
1121
1121
|
"defaultStyle",
|
|
1122
1122
|
"styleAliases"
|
|
1123
|
-
],
|
|
1123
|
+
], No = [
|
|
1124
1124
|
"scalar",
|
|
1125
1125
|
"sequence",
|
|
1126
1126
|
"mapping"
|
|
1127
1127
|
];
|
|
1128
|
-
function
|
|
1128
|
+
function qo(e) {
|
|
1129
1129
|
var n = {};
|
|
1130
1130
|
return e !== null && Object.keys(e).forEach(function(t) {
|
|
1131
1131
|
e[t].forEach(function(a) {
|
|
@@ -1133,19 +1133,19 @@ function No(e) {
|
|
|
1133
1133
|
});
|
|
1134
1134
|
}), n;
|
|
1135
1135
|
}
|
|
1136
|
-
function
|
|
1136
|
+
function Lo(e, n) {
|
|
1137
1137
|
if (n = n || {}, Object.keys(n).forEach(function(t) {
|
|
1138
|
-
if (
|
|
1139
|
-
throw new
|
|
1138
|
+
if (Ko.indexOf(t) === -1)
|
|
1139
|
+
throw new se('Unknown option "' + t + '" is met in definition of "' + e + '" YAML type.');
|
|
1140
1140
|
}), this.options = n, this.tag = e, this.kind = n.kind || null, this.resolve = n.resolve || function() {
|
|
1141
1141
|
return !0;
|
|
1142
1142
|
}, this.construct = n.construct || function(t) {
|
|
1143
1143
|
return t;
|
|
1144
|
-
}, 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 =
|
|
1145
|
-
throw new
|
|
1144
|
+
}, this.instanceOf = n.instanceOf || null, this.predicate = n.predicate || null, this.represent = n.represent || null, this.representName = n.representName || null, this.defaultStyle = n.defaultStyle || null, this.multi = n.multi || !1, this.styleAliases = qo(n.styleAliases || null), No.indexOf(this.kind) === -1)
|
|
1145
|
+
throw new se('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.');
|
|
1146
1146
|
}
|
|
1147
|
-
var re =
|
|
1148
|
-
function
|
|
1147
|
+
var re = Lo;
|
|
1148
|
+
function Vt(e, n) {
|
|
1149
1149
|
var t = [];
|
|
1150
1150
|
return e[n].forEach(function(a) {
|
|
1151
1151
|
var o = t.length;
|
|
@@ -1154,7 +1154,7 @@ function Rt(e, n) {
|
|
|
1154
1154
|
}), t[o] = a;
|
|
1155
1155
|
}), t;
|
|
1156
1156
|
}
|
|
1157
|
-
function
|
|
1157
|
+
function Po() {
|
|
1158
1158
|
var e = {
|
|
1159
1159
|
scalar: {},
|
|
1160
1160
|
sequence: {},
|
|
@@ -1174,10 +1174,10 @@ function Lo() {
|
|
|
1174
1174
|
arguments[n].forEach(a);
|
|
1175
1175
|
return e;
|
|
1176
1176
|
}
|
|
1177
|
-
function
|
|
1177
|
+
function ct(e) {
|
|
1178
1178
|
return this.extend(e);
|
|
1179
1179
|
}
|
|
1180
|
-
|
|
1180
|
+
ct.prototype.extend = function(e) {
|
|
1181
1181
|
var n = [], t = [];
|
|
1182
1182
|
if (e instanceof re)
|
|
1183
1183
|
t.push(e);
|
|
@@ -1186,60 +1186,60 @@ ut.prototype.extend = function(e) {
|
|
|
1186
1186
|
else if (e && (Array.isArray(e.implicit) || Array.isArray(e.explicit)))
|
|
1187
1187
|
e.implicit && (n = n.concat(e.implicit)), e.explicit && (t = t.concat(e.explicit));
|
|
1188
1188
|
else
|
|
1189
|
-
throw new
|
|
1189
|
+
throw new se("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");
|
|
1190
1190
|
n.forEach(function(o) {
|
|
1191
1191
|
if (!(o instanceof re))
|
|
1192
|
-
throw new
|
|
1192
|
+
throw new se("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1193
1193
|
if (o.loadKind && o.loadKind !== "scalar")
|
|
1194
|
-
throw new
|
|
1194
|
+
throw new se("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");
|
|
1195
1195
|
if (o.multi)
|
|
1196
|
-
throw new
|
|
1196
|
+
throw new se("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.");
|
|
1197
1197
|
}), t.forEach(function(o) {
|
|
1198
1198
|
if (!(o instanceof re))
|
|
1199
|
-
throw new
|
|
1199
|
+
throw new se("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1200
1200
|
});
|
|
1201
|
-
var a = Object.create(
|
|
1202
|
-
return a.implicit = (this.implicit || []).concat(n), a.explicit = (this.explicit || []).concat(t), a.compiledImplicit =
|
|
1201
|
+
var a = Object.create(ct.prototype);
|
|
1202
|
+
return a.implicit = (this.implicit || []).concat(n), a.explicit = (this.explicit || []).concat(t), a.compiledImplicit = Vt(a, "implicit"), a.compiledExplicit = Vt(a, "explicit"), a.compiledTypeMap = Po(a.compiledImplicit, a.compiledExplicit), a;
|
|
1203
1203
|
};
|
|
1204
|
-
var
|
|
1204
|
+
var gn = ct, yn = new re("tag:yaml.org,2002:str", {
|
|
1205
1205
|
kind: "scalar",
|
|
1206
1206
|
construct: function(e) {
|
|
1207
1207
|
return e !== null ? e : "";
|
|
1208
1208
|
}
|
|
1209
|
-
}),
|
|
1209
|
+
}), hn = new re("tag:yaml.org,2002:seq", {
|
|
1210
1210
|
kind: "sequence",
|
|
1211
1211
|
construct: function(e) {
|
|
1212
1212
|
return e !== null ? e : [];
|
|
1213
1213
|
}
|
|
1214
|
-
}),
|
|
1214
|
+
}), vn = new re("tag:yaml.org,2002:map", {
|
|
1215
1215
|
kind: "mapping",
|
|
1216
1216
|
construct: function(e) {
|
|
1217
1217
|
return e !== null ? e : {};
|
|
1218
1218
|
}
|
|
1219
|
-
}),
|
|
1219
|
+
}), bn = new gn({
|
|
1220
1220
|
explicit: [
|
|
1221
|
-
gn,
|
|
1222
1221
|
yn,
|
|
1223
|
-
hn
|
|
1222
|
+
hn,
|
|
1223
|
+
vn
|
|
1224
1224
|
]
|
|
1225
1225
|
});
|
|
1226
|
-
function
|
|
1226
|
+
function Uo(e) {
|
|
1227
1227
|
if (e === null)
|
|
1228
1228
|
return !0;
|
|
1229
1229
|
var n = e.length;
|
|
1230
1230
|
return n === 1 && e === "~" || n === 4 && (e === "null" || e === "Null" || e === "NULL");
|
|
1231
1231
|
}
|
|
1232
|
-
function
|
|
1232
|
+
function Ro() {
|
|
1233
1233
|
return null;
|
|
1234
1234
|
}
|
|
1235
|
-
function
|
|
1235
|
+
function Vo(e) {
|
|
1236
1236
|
return e === null;
|
|
1237
1237
|
}
|
|
1238
|
-
var
|
|
1238
|
+
var Cn = new re("tag:yaml.org,2002:null", {
|
|
1239
1239
|
kind: "scalar",
|
|
1240
|
-
resolve:
|
|
1241
|
-
construct:
|
|
1242
|
-
predicate:
|
|
1240
|
+
resolve: Uo,
|
|
1241
|
+
construct: Ro,
|
|
1242
|
+
predicate: Vo,
|
|
1243
1243
|
represent: {
|
|
1244
1244
|
canonical: function() {
|
|
1245
1245
|
return "~";
|
|
@@ -1259,23 +1259,23 @@ var bn = new re("tag:yaml.org,2002:null", {
|
|
|
1259
1259
|
},
|
|
1260
1260
|
defaultStyle: "lowercase"
|
|
1261
1261
|
});
|
|
1262
|
-
function
|
|
1262
|
+
function Do(e) {
|
|
1263
1263
|
if (e === null)
|
|
1264
1264
|
return !1;
|
|
1265
1265
|
var n = e.length;
|
|
1266
1266
|
return n === 4 && (e === "true" || e === "True" || e === "TRUE") || n === 5 && (e === "false" || e === "False" || e === "FALSE");
|
|
1267
1267
|
}
|
|
1268
|
-
function
|
|
1268
|
+
function Go(e) {
|
|
1269
1269
|
return e === "true" || e === "True" || e === "TRUE";
|
|
1270
1270
|
}
|
|
1271
|
-
function
|
|
1271
|
+
function Ho(e) {
|
|
1272
1272
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1273
1273
|
}
|
|
1274
|
-
var
|
|
1274
|
+
var kn = new re("tag:yaml.org,2002:bool", {
|
|
1275
1275
|
kind: "scalar",
|
|
1276
|
-
resolve:
|
|
1277
|
-
construct:
|
|
1278
|
-
predicate:
|
|
1276
|
+
resolve: Do,
|
|
1277
|
+
construct: Go,
|
|
1278
|
+
predicate: Ho,
|
|
1279
1279
|
represent: {
|
|
1280
1280
|
lowercase: function(e) {
|
|
1281
1281
|
return e ? "true" : "false";
|
|
@@ -1289,16 +1289,16 @@ var Cn = new re("tag:yaml.org,2002:bool", {
|
|
|
1289
1289
|
},
|
|
1290
1290
|
defaultStyle: "lowercase"
|
|
1291
1291
|
});
|
|
1292
|
-
function
|
|
1292
|
+
function Yo(e) {
|
|
1293
1293
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1294
1294
|
}
|
|
1295
|
-
function
|
|
1295
|
+
function zo(e) {
|
|
1296
1296
|
return 48 <= e && e <= 55;
|
|
1297
1297
|
}
|
|
1298
|
-
function
|
|
1298
|
+
function Jo(e) {
|
|
1299
1299
|
return 48 <= e && e <= 57;
|
|
1300
1300
|
}
|
|
1301
|
-
function
|
|
1301
|
+
function Wo(e) {
|
|
1302
1302
|
if (e === null)
|
|
1303
1303
|
return !1;
|
|
1304
1304
|
var n = e.length, t = 0, a = !1, o;
|
|
@@ -1319,7 +1319,7 @@ function Jo(e) {
|
|
|
1319
1319
|
if (o === "x") {
|
|
1320
1320
|
for (t++; t < n; t++)
|
|
1321
1321
|
if (o = e[t], o !== "_") {
|
|
1322
|
-
if (!
|
|
1322
|
+
if (!Yo(e.charCodeAt(t)))
|
|
1323
1323
|
return !1;
|
|
1324
1324
|
a = !0;
|
|
1325
1325
|
}
|
|
@@ -1328,7 +1328,7 @@ function Jo(e) {
|
|
|
1328
1328
|
if (o === "o") {
|
|
1329
1329
|
for (t++; t < n; t++)
|
|
1330
1330
|
if (o = e[t], o !== "_") {
|
|
1331
|
-
if (!
|
|
1331
|
+
if (!zo(e.charCodeAt(t)))
|
|
1332
1332
|
return !1;
|
|
1333
1333
|
a = !0;
|
|
1334
1334
|
}
|
|
@@ -1339,13 +1339,13 @@ function Jo(e) {
|
|
|
1339
1339
|
return !1;
|
|
1340
1340
|
for (; t < n; t++)
|
|
1341
1341
|
if (o = e[t], o !== "_") {
|
|
1342
|
-
if (!
|
|
1342
|
+
if (!Jo(e.charCodeAt(t)))
|
|
1343
1343
|
return !1;
|
|
1344
1344
|
a = !0;
|
|
1345
1345
|
}
|
|
1346
1346
|
return !(!a || o === "_");
|
|
1347
1347
|
}
|
|
1348
|
-
function
|
|
1348
|
+
function Zo(e) {
|
|
1349
1349
|
var n = e, t = 1, a;
|
|
1350
1350
|
if (n.indexOf("_") !== -1 && (n = n.replace(/_/g, "")), a = n[0], (a === "-" || a === "+") && (a === "-" && (t = -1), n = n.slice(1), a = n[0]), n === "0")
|
|
1351
1351
|
return 0;
|
|
@@ -1359,14 +1359,14 @@ function Wo(e) {
|
|
|
1359
1359
|
}
|
|
1360
1360
|
return t * parseInt(n, 10);
|
|
1361
1361
|
}
|
|
1362
|
-
function
|
|
1362
|
+
function Qo(e) {
|
|
1363
1363
|
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 === 0 && !ne.isNegativeZero(e);
|
|
1364
1364
|
}
|
|
1365
|
-
var
|
|
1365
|
+
var wn = new re("tag:yaml.org,2002:int", {
|
|
1366
1366
|
kind: "scalar",
|
|
1367
|
-
resolve:
|
|
1368
|
-
construct:
|
|
1369
|
-
predicate:
|
|
1367
|
+
resolve: Wo,
|
|
1368
|
+
construct: Zo,
|
|
1369
|
+
predicate: Qo,
|
|
1370
1370
|
represent: {
|
|
1371
1371
|
binary: function(e) {
|
|
1372
1372
|
return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1);
|
|
@@ -1389,21 +1389,21 @@ var kn = new re("tag:yaml.org,2002:int", {
|
|
|
1389
1389
|
decimal: [10, "dec"],
|
|
1390
1390
|
hexadecimal: [16, "hex"]
|
|
1391
1391
|
}
|
|
1392
|
-
}),
|
|
1392
|
+
}), Xo = new RegExp(
|
|
1393
1393
|
// 2.5e4, 2.5 and integers
|
|
1394
1394
|
"^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"
|
|
1395
1395
|
);
|
|
1396
|
-
function
|
|
1397
|
-
return !(e === null || !
|
|
1396
|
+
function er(e) {
|
|
1397
|
+
return !(e === null || !Xo.test(e) || // Quick hack to not allow integers end with `_`
|
|
1398
1398
|
// Probably should update regexp & check speed
|
|
1399
1399
|
e[e.length - 1] === "_");
|
|
1400
1400
|
}
|
|
1401
|
-
function
|
|
1401
|
+
function tr(e) {
|
|
1402
1402
|
var n, t;
|
|
1403
1403
|
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);
|
|
1404
1404
|
}
|
|
1405
|
-
var
|
|
1406
|
-
function
|
|
1405
|
+
var nr = /^[-+]?[0-9]+e/;
|
|
1406
|
+
function ar(e, n) {
|
|
1407
1407
|
var t;
|
|
1408
1408
|
if (isNaN(e))
|
|
1409
1409
|
switch (n) {
|
|
@@ -1434,36 +1434,36 @@ function nr(e, n) {
|
|
|
1434
1434
|
}
|
|
1435
1435
|
else if (ne.isNegativeZero(e))
|
|
1436
1436
|
return "-0.0";
|
|
1437
|
-
return t = e.toString(10),
|
|
1437
|
+
return t = e.toString(10), nr.test(t) ? t.replace("e", ".e") : t;
|
|
1438
1438
|
}
|
|
1439
|
-
function
|
|
1439
|
+
function or(e) {
|
|
1440
1440
|
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 !== 0 || ne.isNegativeZero(e));
|
|
1441
1441
|
}
|
|
1442
|
-
var
|
|
1442
|
+
var _n = new re("tag:yaml.org,2002:float", {
|
|
1443
1443
|
kind: "scalar",
|
|
1444
|
-
resolve:
|
|
1445
|
-
construct:
|
|
1446
|
-
predicate:
|
|
1447
|
-
represent:
|
|
1444
|
+
resolve: er,
|
|
1445
|
+
construct: tr,
|
|
1446
|
+
predicate: or,
|
|
1447
|
+
represent: ar,
|
|
1448
1448
|
defaultStyle: "lowercase"
|
|
1449
|
-
}),
|
|
1449
|
+
}), In = bn.extend({
|
|
1450
1450
|
implicit: [
|
|
1451
|
-
bn,
|
|
1452
1451
|
Cn,
|
|
1453
1452
|
kn,
|
|
1454
|
-
wn
|
|
1453
|
+
wn,
|
|
1454
|
+
_n
|
|
1455
1455
|
]
|
|
1456
|
-
}),
|
|
1456
|
+
}), An = In, Sn = new RegExp(
|
|
1457
1457
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1458
|
-
),
|
|
1458
|
+
), xn = new RegExp(
|
|
1459
1459
|
"^([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]))?))?$"
|
|
1460
1460
|
);
|
|
1461
|
-
function or(e) {
|
|
1462
|
-
return e === null ? !1 : An.exec(e) !== null || Sn.exec(e) !== null;
|
|
1463
|
-
}
|
|
1464
1461
|
function rr(e) {
|
|
1462
|
+
return e === null ? !1 : Sn.exec(e) !== null || xn.exec(e) !== null;
|
|
1463
|
+
}
|
|
1464
|
+
function ir(e) {
|
|
1465
1465
|
var n, t, a, o, r, i, s, l = 0, c = null, d, u, h;
|
|
1466
|
-
if (n =
|
|
1466
|
+
if (n = Sn.exec(e), n === null && (n = xn.exec(e)), n === null)
|
|
1467
1467
|
throw new Error("Date resolve error");
|
|
1468
1468
|
if (t = +n[1], a = +n[2] - 1, o = +n[3], !n[4])
|
|
1469
1469
|
return new Date(Date.UTC(t, a, o));
|
|
@@ -1474,28 +1474,28 @@ function rr(e) {
|
|
|
1474
1474
|
}
|
|
1475
1475
|
return n[9] && (d = +n[10], u = +(n[11] || 0), c = (d * 60 + u) * 6e4, n[9] === "-" && (c = -c)), h = new Date(Date.UTC(t, a, o, r, i, s, l)), c && h.setTime(h.getTime() - c), h;
|
|
1476
1476
|
}
|
|
1477
|
-
function
|
|
1477
|
+
function sr(e) {
|
|
1478
1478
|
return e.toISOString();
|
|
1479
1479
|
}
|
|
1480
|
-
var
|
|
1480
|
+
var Tn = new re("tag:yaml.org,2002:timestamp", {
|
|
1481
1481
|
kind: "scalar",
|
|
1482
|
-
resolve:
|
|
1483
|
-
construct:
|
|
1482
|
+
resolve: rr,
|
|
1483
|
+
construct: ir,
|
|
1484
1484
|
instanceOf: Date,
|
|
1485
|
-
represent:
|
|
1485
|
+
represent: sr
|
|
1486
1486
|
});
|
|
1487
|
-
function
|
|
1487
|
+
function lr(e) {
|
|
1488
1488
|
return e === "<<" || e === null;
|
|
1489
1489
|
}
|
|
1490
|
-
var
|
|
1490
|
+
var $n = new re("tag:yaml.org,2002:merge", {
|
|
1491
1491
|
kind: "scalar",
|
|
1492
|
-
resolve:
|
|
1493
|
-
}),
|
|
1492
|
+
resolve: lr
|
|
1493
|
+
}), Ct = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
1494
1494
|
\r`;
|
|
1495
|
-
function
|
|
1495
|
+
function ur(e) {
|
|
1496
1496
|
if (e === null)
|
|
1497
1497
|
return !1;
|
|
1498
|
-
var n, t, a = 0, o = e.length, r =
|
|
1498
|
+
var n, t, a = 0, o = e.length, r = Ct;
|
|
1499
1499
|
for (t = 0; t < o; t++)
|
|
1500
1500
|
if (n = r.indexOf(e.charAt(t)), !(n > 64)) {
|
|
1501
1501
|
if (n < 0)
|
|
@@ -1504,37 +1504,37 @@ function lr(e) {
|
|
|
1504
1504
|
}
|
|
1505
1505
|
return a % 8 === 0;
|
|
1506
1506
|
}
|
|
1507
|
-
function
|
|
1508
|
-
var n, t, a = e.replace(/[\r\n=]/g, ""), o = a.length, r =
|
|
1507
|
+
function cr(e) {
|
|
1508
|
+
var n, t, a = e.replace(/[\r\n=]/g, ""), o = a.length, r = Ct, i = 0, s = [];
|
|
1509
1509
|
for (n = 0; n < o; n++)
|
|
1510
1510
|
n % 4 === 0 && n && (s.push(i >> 16 & 255), s.push(i >> 8 & 255), s.push(i & 255)), i = i << 6 | r.indexOf(a.charAt(n));
|
|
1511
1511
|
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);
|
|
1512
1512
|
}
|
|
1513
|
-
function
|
|
1514
|
-
var n = "", t = 0, a, o, r = e.length, i =
|
|
1513
|
+
function dr(e) {
|
|
1514
|
+
var n = "", t = 0, a, o, r = e.length, i = Ct;
|
|
1515
1515
|
for (a = 0; a < r; a++)
|
|
1516
1516
|
a % 3 === 0 && a && (n += i[t >> 18 & 63], n += i[t >> 12 & 63], n += i[t >> 6 & 63], n += i[t & 63]), t = (t << 8) + e[a];
|
|
1517
1517
|
return o = r % 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;
|
|
1518
1518
|
}
|
|
1519
|
-
function
|
|
1519
|
+
function pr(e) {
|
|
1520
1520
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1521
1521
|
}
|
|
1522
|
-
var
|
|
1522
|
+
var Mn = new re("tag:yaml.org,2002:binary", {
|
|
1523
1523
|
kind: "scalar",
|
|
1524
|
-
resolve:
|
|
1525
|
-
construct:
|
|
1526
|
-
predicate:
|
|
1527
|
-
represent:
|
|
1528
|
-
}),
|
|
1529
|
-
function
|
|
1524
|
+
resolve: ur,
|
|
1525
|
+
construct: cr,
|
|
1526
|
+
predicate: pr,
|
|
1527
|
+
represent: dr
|
|
1528
|
+
}), fr = Object.prototype.hasOwnProperty, mr = Object.prototype.toString;
|
|
1529
|
+
function gr(e) {
|
|
1530
1530
|
if (e === null)
|
|
1531
1531
|
return !0;
|
|
1532
1532
|
var n = [], t, a, o, r, i, s = e;
|
|
1533
1533
|
for (t = 0, a = s.length; t < a; t += 1) {
|
|
1534
|
-
if (o = s[t], i = !1,
|
|
1534
|
+
if (o = s[t], i = !1, mr.call(o) !== "[object Object]")
|
|
1535
1535
|
return !1;
|
|
1536
1536
|
for (r in o)
|
|
1537
|
-
if (
|
|
1537
|
+
if (fr.call(o, r))
|
|
1538
1538
|
if (!i)
|
|
1539
1539
|
i = !0;
|
|
1540
1540
|
else
|
|
@@ -1548,26 +1548,26 @@ function mr(e) {
|
|
|
1548
1548
|
}
|
|
1549
1549
|
return !0;
|
|
1550
1550
|
}
|
|
1551
|
-
function
|
|
1551
|
+
function yr(e) {
|
|
1552
1552
|
return e !== null ? e : [];
|
|
1553
1553
|
}
|
|
1554
|
-
var
|
|
1554
|
+
var On = new re("tag:yaml.org,2002:omap", {
|
|
1555
1555
|
kind: "sequence",
|
|
1556
|
-
resolve:
|
|
1557
|
-
construct:
|
|
1558
|
-
}),
|
|
1559
|
-
function
|
|
1556
|
+
resolve: gr,
|
|
1557
|
+
construct: yr
|
|
1558
|
+
}), hr = Object.prototype.toString;
|
|
1559
|
+
function vr(e) {
|
|
1560
1560
|
if (e === null)
|
|
1561
1561
|
return !0;
|
|
1562
1562
|
var n, t, a, o, r, i = e;
|
|
1563
1563
|
for (r = new Array(i.length), n = 0, t = i.length; n < t; n += 1) {
|
|
1564
|
-
if (a = i[n],
|
|
1564
|
+
if (a = i[n], hr.call(a) !== "[object Object]" || (o = Object.keys(a), o.length !== 1))
|
|
1565
1565
|
return !1;
|
|
1566
1566
|
r[n] = [o[0], a[o[0]]];
|
|
1567
1567
|
}
|
|
1568
1568
|
return !0;
|
|
1569
1569
|
}
|
|
1570
|
-
function
|
|
1570
|
+
function br(e) {
|
|
1571
1571
|
if (e === null)
|
|
1572
1572
|
return [];
|
|
1573
1573
|
var n, t, a, o, r, i = e;
|
|
@@ -1575,40 +1575,40 @@ function vr(e) {
|
|
|
1575
1575
|
a = i[n], o = Object.keys(a), r[n] = [o[0], a[o[0]]];
|
|
1576
1576
|
return r;
|
|
1577
1577
|
}
|
|
1578
|
-
var
|
|
1578
|
+
var jn = new re("tag:yaml.org,2002:pairs", {
|
|
1579
1579
|
kind: "sequence",
|
|
1580
|
-
resolve:
|
|
1581
|
-
construct:
|
|
1582
|
-
}),
|
|
1583
|
-
function
|
|
1580
|
+
resolve: vr,
|
|
1581
|
+
construct: br
|
|
1582
|
+
}), Cr = Object.prototype.hasOwnProperty;
|
|
1583
|
+
function kr(e) {
|
|
1584
1584
|
if (e === null)
|
|
1585
1585
|
return !0;
|
|
1586
1586
|
var n, t = e;
|
|
1587
1587
|
for (n in t)
|
|
1588
|
-
if (
|
|
1588
|
+
if (Cr.call(t, n) && t[n] !== null)
|
|
1589
1589
|
return !1;
|
|
1590
1590
|
return !0;
|
|
1591
1591
|
}
|
|
1592
|
-
function
|
|
1592
|
+
function wr(e) {
|
|
1593
1593
|
return e !== null ? e : {};
|
|
1594
1594
|
}
|
|
1595
|
-
var
|
|
1595
|
+
var En = new re("tag:yaml.org,2002:set", {
|
|
1596
1596
|
kind: "mapping",
|
|
1597
|
-
resolve:
|
|
1598
|
-
construct:
|
|
1599
|
-
}),
|
|
1597
|
+
resolve: kr,
|
|
1598
|
+
construct: wr
|
|
1599
|
+
}), kt = An.extend({
|
|
1600
1600
|
implicit: [
|
|
1601
|
-
|
|
1602
|
-
|
|
1601
|
+
Tn,
|
|
1602
|
+
$n
|
|
1603
1603
|
],
|
|
1604
1604
|
explicit: [
|
|
1605
|
-
$n,
|
|
1606
1605
|
Mn,
|
|
1607
1606
|
On,
|
|
1608
|
-
jn
|
|
1607
|
+
jn,
|
|
1608
|
+
En
|
|
1609
1609
|
]
|
|
1610
|
-
}), Ce = Object.prototype.hasOwnProperty, He = 1,
|
|
1611
|
-
function
|
|
1610
|
+
}), Ce = Object.prototype.hasOwnProperty, He = 1, Fn = 2, Bn = 3, Ye = 4, st = 1, _r = 2, Dt = 3, Ir = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Ar = /[\x85\u2028\u2029]/, Sr = /[,\[\]\{\}]/, Kn = /^(?:!|!!|![a-z\-]+!)$/i, Nn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1611
|
+
function Gt(e) {
|
|
1612
1612
|
return Object.prototype.toString.call(e);
|
|
1613
1613
|
}
|
|
1614
1614
|
function ge(e) {
|
|
@@ -1623,33 +1623,33 @@ function de(e) {
|
|
|
1623
1623
|
function je(e) {
|
|
1624
1624
|
return e === 44 || e === 91 || e === 93 || e === 123 || e === 125;
|
|
1625
1625
|
}
|
|
1626
|
-
function
|
|
1626
|
+
function xr(e) {
|
|
1627
1627
|
var n;
|
|
1628
1628
|
return 48 <= e && e <= 57 ? e - 48 : (n = e | 32, 97 <= n && n <= 102 ? n - 97 + 10 : -1);
|
|
1629
1629
|
}
|
|
1630
|
-
function
|
|
1630
|
+
function Tr(e) {
|
|
1631
1631
|
return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0;
|
|
1632
1632
|
}
|
|
1633
|
-
function
|
|
1633
|
+
function $r(e) {
|
|
1634
1634
|
return 48 <= e && e <= 57 ? e - 48 : -1;
|
|
1635
1635
|
}
|
|
1636
|
-
function
|
|
1636
|
+
function Ht(e) {
|
|
1637
1637
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? `
|
|
1638
1638
|
` : 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" : "";
|
|
1639
1639
|
}
|
|
1640
|
-
function
|
|
1640
|
+
function Mr(e) {
|
|
1641
1641
|
return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(
|
|
1642
1642
|
(e - 65536 >> 10) + 55296,
|
|
1643
1643
|
(e - 65536 & 1023) + 56320
|
|
1644
1644
|
);
|
|
1645
1645
|
}
|
|
1646
|
-
var
|
|
1646
|
+
var qn = new Array(256), Ln = new Array(256);
|
|
1647
1647
|
for (var Me = 0; Me < 256; Me++)
|
|
1648
|
-
|
|
1649
|
-
function
|
|
1650
|
-
this.input = e, this.filename = n.filename || null, this.schema = n.schema ||
|
|
1648
|
+
qn[Me] = Ht(Me) ? 1 : 0, Ln[Me] = Ht(Me);
|
|
1649
|
+
function Or(e, n) {
|
|
1650
|
+
this.input = e, this.filename = n.filename || null, this.schema = n.schema || kt, 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 = [];
|
|
1651
1651
|
}
|
|
1652
|
-
function
|
|
1652
|
+
function Pn(e, n) {
|
|
1653
1653
|
var t = {
|
|
1654
1654
|
name: e.filename,
|
|
1655
1655
|
buffer: e.input.slice(0, -1),
|
|
@@ -1658,22 +1658,22 @@ function Ln(e, n) {
|
|
|
1658
1658
|
line: e.line,
|
|
1659
1659
|
column: e.position - e.lineStart
|
|
1660
1660
|
};
|
|
1661
|
-
return t.snippet =
|
|
1661
|
+
return t.snippet = Bo(t), new se(n, t);
|
|
1662
1662
|
}
|
|
1663
1663
|
function T(e, n) {
|
|
1664
|
-
throw
|
|
1664
|
+
throw Pn(e, n);
|
|
1665
1665
|
}
|
|
1666
1666
|
function ze(e, n) {
|
|
1667
|
-
e.onWarning && e.onWarning.call(null,
|
|
1667
|
+
e.onWarning && e.onWarning.call(null, Pn(e, n));
|
|
1668
1668
|
}
|
|
1669
|
-
var
|
|
1669
|
+
var Yt = {
|
|
1670
1670
|
YAML: function(e, n, t) {
|
|
1671
1671
|
var a, o, r;
|
|
1672
1672
|
e.version !== null && T(e, "duplication of %YAML directive"), t.length !== 1 && T(e, "YAML directive accepts exactly one argument"), a = /^([0-9]+)\.([0-9]+)$/.exec(t[0]), a === null && T(e, "ill-formed argument of the YAML directive"), o = parseInt(a[1], 10), r = parseInt(a[2], 10), o !== 1 && T(e, "unacceptable YAML version of the document"), e.version = t[0], e.checkLineBreaks = r < 2, r !== 1 && r !== 2 && ze(e, "unsupported YAML version of the document");
|
|
1673
1673
|
},
|
|
1674
1674
|
TAG: function(e, n, t) {
|
|
1675
1675
|
var a, o;
|
|
1676
|
-
t.length !== 2 && T(e, "TAG directive accepts exactly two arguments"), a = t[0], o = t[1],
|
|
1676
|
+
t.length !== 2 && T(e, "TAG directive accepts exactly two arguments"), a = t[0], o = t[1], Kn.test(a) || T(e, "ill-formed tag handle (first argument) of the TAG directive"), Ce.call(e.tagMap, a) && T(e, 'there is a previously declared suffix for "' + a + '" tag handle'), Nn.test(o) || T(e, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1677
1677
|
try {
|
|
1678
1678
|
o = decodeURIComponent(o);
|
|
1679
1679
|
} catch {
|
|
@@ -1689,11 +1689,11 @@ function be(e, n, t, a) {
|
|
|
1689
1689
|
for (o = 0, r = s.length; o < r; o += 1)
|
|
1690
1690
|
i = s.charCodeAt(o), i === 9 || 32 <= i && i <= 1114111 || T(e, "expected valid JSON character");
|
|
1691
1691
|
else
|
|
1692
|
-
|
|
1692
|
+
Ir.test(s) && T(e, "the stream contains non-printable characters");
|
|
1693
1693
|
e.result += s;
|
|
1694
1694
|
}
|
|
1695
1695
|
}
|
|
1696
|
-
function
|
|
1696
|
+
function zt(e, n, t, a) {
|
|
1697
1697
|
var o, r, i, s;
|
|
1698
1698
|
for (ne.isObject(t) || T(e, "cannot merge mappings; the provided source object is unacceptable"), o = Object.keys(t), i = 0, s = o.length; i < s; i += 1)
|
|
1699
1699
|
r = o[i], Ce.call(n, r) || (n[r] = t[r], a[r] = !0);
|
|
@@ -1702,13 +1702,13 @@ function Ee(e, n, t, a, o, r, i, s, l) {
|
|
|
1702
1702
|
var c, d;
|
|
1703
1703
|
if (Array.isArray(o))
|
|
1704
1704
|
for (o = Array.prototype.slice.call(o), c = 0, d = o.length; c < d; c += 1)
|
|
1705
|
-
Array.isArray(o[c]) && T(e, "nested arrays are not supported inside keys"), typeof o == "object" &&
|
|
1706
|
-
if (typeof o == "object" &&
|
|
1705
|
+
Array.isArray(o[c]) && T(e, "nested arrays are not supported inside keys"), typeof o == "object" && Gt(o[c]) === "[object Object]" && (o[c] = "[object Object]");
|
|
1706
|
+
if (typeof o == "object" && Gt(o) === "[object Object]" && (o = "[object Object]"), o = String(o), n === null && (n = {}), a === "tag:yaml.org,2002:merge")
|
|
1707
1707
|
if (Array.isArray(r))
|
|
1708
1708
|
for (c = 0, d = r.length; c < d; c += 1)
|
|
1709
|
-
|
|
1709
|
+
zt(e, n, r[c], t);
|
|
1710
1710
|
else
|
|
1711
|
-
|
|
1711
|
+
zt(e, n, r, t);
|
|
1712
1712
|
else
|
|
1713
1713
|
!e.json && !Ce.call(t, o) && Ce.call(n, o) && (e.line = i || e.line, e.lineStart = s || e.lineStart, e.position = l || e.position, T(e, "duplicated mapping key")), o === "__proto__" ? Object.defineProperty(n, o, {
|
|
1714
1714
|
configurable: !0,
|
|
@@ -1718,7 +1718,7 @@ function Ee(e, n, t, a, o, r, i, s, l) {
|
|
|
1718
1718
|
}) : n[o] = r, delete t[o];
|
|
1719
1719
|
return n;
|
|
1720
1720
|
}
|
|
1721
|
-
function
|
|
1721
|
+
function wt(e) {
|
|
1722
1722
|
var n;
|
|
1723
1723
|
n = e.input.charCodeAt(e.position), n === 10 ? e.position++ : n === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : T(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1;
|
|
1724
1724
|
}
|
|
@@ -1731,7 +1731,7 @@ function ee(e, n, t) {
|
|
|
1731
1731
|
o = e.input.charCodeAt(++e.position);
|
|
1732
1732
|
while (o !== 10 && o !== 13 && o !== 0);
|
|
1733
1733
|
if (ge(o))
|
|
1734
|
-
for (
|
|
1734
|
+
for (wt(e), o = e.input.charCodeAt(e.position), a++, e.lineIndent = 0; o === 32; )
|
|
1735
1735
|
e.lineIndent++, o = e.input.charCodeAt(++e.position);
|
|
1736
1736
|
else
|
|
1737
1737
|
break;
|
|
@@ -1742,11 +1742,11 @@ function et(e) {
|
|
|
1742
1742
|
var n = e.position, t;
|
|
1743
1743
|
return t = e.input.charCodeAt(n), !!((t === 45 || t === 46) && t === e.input.charCodeAt(n + 1) && t === e.input.charCodeAt(n + 2) && (n += 3, t = e.input.charCodeAt(n), t === 0 || de(t)));
|
|
1744
1744
|
}
|
|
1745
|
-
function
|
|
1745
|
+
function _t(e, n) {
|
|
1746
1746
|
n === 1 ? e.result += " " : n > 1 && (e.result += ne.repeat(`
|
|
1747
1747
|
`, n - 1));
|
|
1748
1748
|
}
|
|
1749
|
-
function
|
|
1749
|
+
function jr(e, n, t) {
|
|
1750
1750
|
var a, o, r, i, s, l, c, d, u = e.kind, h = e.result, g;
|
|
1751
1751
|
if (g = e.input.charCodeAt(e.position), de(g) || je(g) || g === 35 || g === 38 || g === 42 || g === 33 || g === 124 || g === 62 || g === 39 || g === 34 || g === 37 || g === 64 || g === 96 || (g === 63 || g === 45) && (o = e.input.charCodeAt(e.position + 1), de(o) || t && je(o)))
|
|
1752
1752
|
return !1;
|
|
@@ -1769,11 +1769,11 @@ function Or(e, n, t) {
|
|
|
1769
1769
|
break;
|
|
1770
1770
|
}
|
|
1771
1771
|
}
|
|
1772
|
-
s && (be(e, r, i, !1),
|
|
1772
|
+
s && (be(e, r, i, !1), _t(e, e.line - l), r = i = e.position, s = !1), Ie(g) || (i = e.position + 1), g = e.input.charCodeAt(++e.position);
|
|
1773
1773
|
}
|
|
1774
1774
|
return be(e, r, i, !1), e.result ? !0 : (e.kind = u, e.result = h, !1);
|
|
1775
1775
|
}
|
|
1776
|
-
function
|
|
1776
|
+
function Er(e, n) {
|
|
1777
1777
|
var t, a, o;
|
|
1778
1778
|
if (t = e.input.charCodeAt(e.position), t !== 39)
|
|
1779
1779
|
return !1;
|
|
@@ -1784,10 +1784,10 @@ function jr(e, n) {
|
|
|
1784
1784
|
else
|
|
1785
1785
|
return !0;
|
|
1786
1786
|
else
|
|
1787
|
-
ge(t) ? (be(e, a, o, !0),
|
|
1787
|
+
ge(t) ? (be(e, a, o, !0), _t(e, ee(e, !1, n)), a = o = e.position) : e.position === e.lineStart && et(e) ? T(e, "unexpected end of the document within a single quoted scalar") : (e.position++, o = e.position);
|
|
1788
1788
|
T(e, "unexpected end of the stream within a single quoted scalar");
|
|
1789
1789
|
}
|
|
1790
|
-
function
|
|
1790
|
+
function Fr(e, n) {
|
|
1791
1791
|
var t, a, o, r, i, s;
|
|
1792
1792
|
if (s = e.input.charCodeAt(e.position), s !== 34)
|
|
1793
1793
|
return !1;
|
|
@@ -1797,21 +1797,21 @@ function Er(e, n) {
|
|
|
1797
1797
|
if (s === 92) {
|
|
1798
1798
|
if (be(e, t, e.position, !0), s = e.input.charCodeAt(++e.position), ge(s))
|
|
1799
1799
|
ee(e, !1, n);
|
|
1800
|
-
else if (s < 256 &&
|
|
1801
|
-
e.result +=
|
|
1802
|
-
else if ((i =
|
|
1800
|
+
else if (s < 256 && qn[s])
|
|
1801
|
+
e.result += Ln[s], e.position++;
|
|
1802
|
+
else if ((i = Tr(s)) > 0) {
|
|
1803
1803
|
for (o = i, r = 0; o > 0; o--)
|
|
1804
|
-
s = e.input.charCodeAt(++e.position), (i =
|
|
1805
|
-
e.result +=
|
|
1804
|
+
s = e.input.charCodeAt(++e.position), (i = xr(s)) >= 0 ? r = (r << 4) + i : T(e, "expected hexadecimal character");
|
|
1805
|
+
e.result += Mr(r), e.position++;
|
|
1806
1806
|
} else
|
|
1807
1807
|
T(e, "unknown escape sequence");
|
|
1808
1808
|
t = a = e.position;
|
|
1809
1809
|
} else
|
|
1810
|
-
ge(s) ? (be(e, t, a, !0),
|
|
1810
|
+
ge(s) ? (be(e, t, a, !0), _t(e, ee(e, !1, n)), t = a = e.position) : e.position === e.lineStart && et(e) ? T(e, "unexpected end of the document within a double quoted scalar") : (e.position++, a = e.position);
|
|
1811
1811
|
}
|
|
1812
1812
|
T(e, "unexpected end of the stream within a double quoted scalar");
|
|
1813
1813
|
}
|
|
1814
|
-
function
|
|
1814
|
+
function Br(e, n) {
|
|
1815
1815
|
var t = !0, a, o, r, i = e.tag, s, l = e.anchor, c, d, u, h, g, C = /* @__PURE__ */ Object.create(null), k, p, b, v;
|
|
1816
1816
|
if (v = e.input.charCodeAt(e.position), v === 91)
|
|
1817
1817
|
d = 93, g = !1, s = [];
|
|
@@ -1826,8 +1826,8 @@ function Fr(e, n) {
|
|
|
1826
1826
|
}
|
|
1827
1827
|
T(e, "unexpected end of the stream within a flow collection");
|
|
1828
1828
|
}
|
|
1829
|
-
function
|
|
1830
|
-
var t, a, o =
|
|
1829
|
+
function Kr(e, n) {
|
|
1830
|
+
var t, a, o = st, r = !1, i = !1, s = n, l = 0, c = !1, d, u;
|
|
1831
1831
|
if (u = e.input.charCodeAt(e.position), u === 124)
|
|
1832
1832
|
a = !1;
|
|
1833
1833
|
else if (u === 62)
|
|
@@ -1836,8 +1836,8 @@ function Br(e, n) {
|
|
|
1836
1836
|
return !1;
|
|
1837
1837
|
for (e.kind = "scalar", e.result = ""; u !== 0; )
|
|
1838
1838
|
if (u = e.input.charCodeAt(++e.position), u === 43 || u === 45)
|
|
1839
|
-
|
|
1840
|
-
else if ((d =
|
|
1839
|
+
st === o ? o = u === 43 ? Dt : _r : T(e, "repeat of a chomping mode identifier");
|
|
1840
|
+
else if ((d = $r(u)) >= 0)
|
|
1841
1841
|
d === 0 ? T(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : i ? T(e, "repeat of an indentation width identifier") : (s = n + d - 1, i = !0);
|
|
1842
1842
|
else
|
|
1843
1843
|
break;
|
|
@@ -1851,15 +1851,15 @@ function Br(e, n) {
|
|
|
1851
1851
|
while (!ge(u) && u !== 0);
|
|
1852
1852
|
}
|
|
1853
1853
|
for (; u !== 0; ) {
|
|
1854
|
-
for (
|
|
1854
|
+
for (wt(e), e.lineIndent = 0, u = e.input.charCodeAt(e.position); (!i || e.lineIndent < s) && u === 32; )
|
|
1855
1855
|
e.lineIndent++, u = e.input.charCodeAt(++e.position);
|
|
1856
1856
|
if (!i && e.lineIndent > s && (s = e.lineIndent), ge(u)) {
|
|
1857
1857
|
l++;
|
|
1858
1858
|
continue;
|
|
1859
1859
|
}
|
|
1860
1860
|
if (e.lineIndent < s) {
|
|
1861
|
-
o ===
|
|
1862
|
-
`, r ? 1 + l : l) : o ===
|
|
1861
|
+
o === Dt ? e.result += ne.repeat(`
|
|
1862
|
+
`, r ? 1 + l : l) : o === st && r && (e.result += `
|
|
1863
1863
|
`);
|
|
1864
1864
|
break;
|
|
1865
1865
|
}
|
|
@@ -1873,7 +1873,7 @@ function Br(e, n) {
|
|
|
1873
1873
|
}
|
|
1874
1874
|
return !0;
|
|
1875
1875
|
}
|
|
1876
|
-
function
|
|
1876
|
+
function Jt(e, n) {
|
|
1877
1877
|
var t, a = e.tag, o = e.anchor, r = [], i, s = !1, l;
|
|
1878
1878
|
if (e.firstTabInLine !== -1)
|
|
1879
1879
|
return !1;
|
|
@@ -1882,14 +1882,14 @@ function zt(e, n) {
|
|
|
1882
1882
|
r.push(null), l = e.input.charCodeAt(e.position);
|
|
1883
1883
|
continue;
|
|
1884
1884
|
}
|
|
1885
|
-
if (t = e.line, Fe(e, n,
|
|
1885
|
+
if (t = e.line, Fe(e, n, Bn, !1, !0), r.push(e.result), ee(e, !0, -1), l = e.input.charCodeAt(e.position), (e.line === t || e.lineIndent > n) && l !== 0)
|
|
1886
1886
|
T(e, "bad indentation of a sequence entry");
|
|
1887
1887
|
else if (e.lineIndent < n)
|
|
1888
1888
|
break;
|
|
1889
1889
|
}
|
|
1890
1890
|
return s ? (e.tag = a, e.anchor = o, e.kind = "sequence", e.result = r, !0) : !1;
|
|
1891
1891
|
}
|
|
1892
|
-
function
|
|
1892
|
+
function Nr(e, n, t) {
|
|
1893
1893
|
var a, o, r, i, s, l, c = e.tag, d = e.anchor, u = {}, h = /* @__PURE__ */ Object.create(null), g = null, C = null, k = null, p = !1, b = !1, v;
|
|
1894
1894
|
if (e.firstTabInLine !== -1)
|
|
1895
1895
|
return !1;
|
|
@@ -1897,7 +1897,7 @@ function Kr(e, n, t) {
|
|
|
1897
1897
|
if (!p && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, T(e, "tab characters must not be used in indentation")), a = e.input.charCodeAt(e.position + 1), r = e.line, (v === 63 || v === 58) && de(a))
|
|
1898
1898
|
v === 63 ? (p && (Ee(e, u, h, g, C, null, i, s, l), g = C = k = null), b = !0, p = !0, o = !0) : p ? (p = !1, o = !0) : T(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, v = a;
|
|
1899
1899
|
else {
|
|
1900
|
-
if (i = e.line, s = e.lineStart, l = e.position, !Fe(e, t,
|
|
1900
|
+
if (i = e.line, s = e.lineStart, l = e.position, !Fe(e, t, Fn, !1, !0))
|
|
1901
1901
|
break;
|
|
1902
1902
|
if (e.line === r) {
|
|
1903
1903
|
for (v = e.input.charCodeAt(e.position); Ie(v); )
|
|
@@ -1920,7 +1920,7 @@ function Kr(e, n, t) {
|
|
|
1920
1920
|
}
|
|
1921
1921
|
return p && Ee(e, u, h, g, C, null, i, s, l), b && (e.tag = c, e.anchor = d, e.kind = "mapping", e.result = u), b;
|
|
1922
1922
|
}
|
|
1923
|
-
function
|
|
1923
|
+
function qr(e) {
|
|
1924
1924
|
var n, t = !1, a = !1, o, r, i;
|
|
1925
1925
|
if (i = e.input.charCodeAt(e.position), i !== 33)
|
|
1926
1926
|
return !1;
|
|
@@ -1931,10 +1931,10 @@ function Nr(e) {
|
|
|
1931
1931
|
e.position < e.length ? (r = e.input.slice(n, e.position), i = e.input.charCodeAt(++e.position)) : T(e, "unexpected end of the stream within a verbatim tag");
|
|
1932
1932
|
} else {
|
|
1933
1933
|
for (; i !== 0 && !de(i); )
|
|
1934
|
-
i === 33 && (a ? T(e, "tag suffix cannot contain exclamation marks") : (o = e.input.slice(n - 1, e.position + 1),
|
|
1935
|
-
r = e.input.slice(n, e.position),
|
|
1934
|
+
i === 33 && (a ? T(e, "tag suffix cannot contain exclamation marks") : (o = e.input.slice(n - 1, e.position + 1), Kn.test(o) || T(e, "named tag handle cannot contain such characters"), a = !0, n = e.position + 1)), i = e.input.charCodeAt(++e.position);
|
|
1935
|
+
r = e.input.slice(n, e.position), Sr.test(r) && T(e, "tag suffix cannot contain flow indicator characters");
|
|
1936
1936
|
}
|
|
1937
|
-
r && !
|
|
1937
|
+
r && !Nn.test(r) && T(e, "tag name cannot contain such characters: " + r);
|
|
1938
1938
|
try {
|
|
1939
1939
|
r = decodeURIComponent(r);
|
|
1940
1940
|
} catch {
|
|
@@ -1942,7 +1942,7 @@ function Nr(e) {
|
|
|
1942
1942
|
}
|
|
1943
1943
|
return t ? e.tag = r : Ce.call(e.tagMap, o) ? e.tag = e.tagMap[o] + r : o === "!" ? e.tag = "!" + r : o === "!!" ? e.tag = "tag:yaml.org,2002:" + r : T(e, 'undeclared tag handle "' + o + '"'), !0;
|
|
1944
1944
|
}
|
|
1945
|
-
function
|
|
1945
|
+
function Lr(e) {
|
|
1946
1946
|
var n, t;
|
|
1947
1947
|
if (t = e.input.charCodeAt(e.position), t !== 38)
|
|
1948
1948
|
return !1;
|
|
@@ -1950,7 +1950,7 @@ function qr(e) {
|
|
|
1950
1950
|
t = e.input.charCodeAt(++e.position);
|
|
1951
1951
|
return e.position === n && T(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(n, e.position), !0;
|
|
1952
1952
|
}
|
|
1953
|
-
function
|
|
1953
|
+
function Pr(e) {
|
|
1954
1954
|
var n, t, a;
|
|
1955
1955
|
if (a = e.input.charCodeAt(e.position), a !== 42)
|
|
1956
1956
|
return !1;
|
|
@@ -1960,10 +1960,10 @@ function Lr(e) {
|
|
|
1960
1960
|
}
|
|
1961
1961
|
function Fe(e, n, t, a, o) {
|
|
1962
1962
|
var r, i, s, l = 1, c = !1, d = !1, u, h, g, C, k, p;
|
|
1963
|
-
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, r = i = s = Ye === t ||
|
|
1964
|
-
for (;
|
|
1963
|
+
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, r = i = s = Ye === t || Bn === t, a && ee(e, !0, -1) && (c = !0, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)), l === 1)
|
|
1964
|
+
for (; qr(e) || Lr(e); )
|
|
1965
1965
|
ee(e, !0, -1) ? (c = !0, s = r, e.lineIndent > n ? l = 1 : e.lineIndent === n ? l = 0 : e.lineIndent < n && (l = -1)) : s = !1;
|
|
1966
|
-
if (s && (s = c || o), (l === 1 || Ye === t) && (He === t ||
|
|
1966
|
+
if (s && (s = c || o), (l === 1 || Ye === t) && (He === t || Fn === t ? k = n : k = n + 1, p = e.position - e.lineStart, l === 1 ? s && (Jt(e, p) || Nr(e, p, k)) || Br(e, k) ? d = !0 : (i && Kr(e, k) || Er(e, k) || Fr(e, k) ? d = !0 : Pr(e) ? (d = !0, (e.tag !== null || e.anchor !== null) && T(e, "alias node should not have any properties")) : jr(e, k, He === t) && (d = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : l === 0 && (d = s && Jt(e, p))), e.tag === null)
|
|
1967
1967
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1968
1968
|
else if (e.tag === "?") {
|
|
1969
1969
|
for (e.result !== null && e.kind !== "scalar" && T(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0, h = e.implicitTypes.length; u < h; u += 1)
|
|
@@ -1984,7 +1984,7 @@ function Fe(e, n, t, a, o) {
|
|
|
1984
1984
|
}
|
|
1985
1985
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || d;
|
|
1986
1986
|
}
|
|
1987
|
-
function
|
|
1987
|
+
function Ur(e) {
|
|
1988
1988
|
var n = e.position, t, a, o, r = !1, i;
|
|
1989
1989
|
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 && (ee(e, !0, -1), i = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || i !== 37)); ) {
|
|
1990
1990
|
for (r = !0, i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !de(i); )
|
|
@@ -2004,9 +2004,9 @@ function Pr(e) {
|
|
|
2004
2004
|
i = e.input.charCodeAt(++e.position);
|
|
2005
2005
|
o.push(e.input.slice(t, e.position));
|
|
2006
2006
|
}
|
|
2007
|
-
i !== 0 &&
|
|
2007
|
+
i !== 0 && wt(e), Ce.call(Yt, a) ? Yt[a](e, a, o) : ze(e, 'unknown document directive "' + a + '"');
|
|
2008
2008
|
}
|
|
2009
|
-
if (ee(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, ee(e, !0, -1)) : r && T(e, "directives end mark is expected"), Fe(e, e.lineIndent - 1, Ye, !1, !0), ee(e, !0, -1), e.checkLineBreaks &&
|
|
2009
|
+
if (ee(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, ee(e, !0, -1)) : r && T(e, "directives end mark is expected"), Fe(e, e.lineIndent - 1, Ye, !1, !0), ee(e, !0, -1), e.checkLineBreaks && Ar.test(e.input.slice(n, e.position)) && ze(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && et(e)) {
|
|
2010
2010
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, ee(e, !0, -1));
|
|
2011
2011
|
return;
|
|
2012
2012
|
}
|
|
@@ -2015,52 +2015,52 @@ function Pr(e) {
|
|
|
2015
2015
|
else
|
|
2016
2016
|
return;
|
|
2017
2017
|
}
|
|
2018
|
-
function
|
|
2018
|
+
function Un(e, n) {
|
|
2019
2019
|
e = String(e), n = n || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2020
2020
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2021
|
-
var t = new
|
|
2021
|
+
var t = new Or(e, n), a = e.indexOf("\0");
|
|
2022
2022
|
for (a !== -1 && (t.position = a, T(t, "null byte is not allowed in input")), t.input += "\0"; t.input.charCodeAt(t.position) === 32; )
|
|
2023
2023
|
t.lineIndent += 1, t.position += 1;
|
|
2024
2024
|
for (; t.position < t.length - 1; )
|
|
2025
|
-
|
|
2025
|
+
Ur(t);
|
|
2026
2026
|
return t.documents;
|
|
2027
2027
|
}
|
|
2028
|
-
function
|
|
2028
|
+
function Rr(e, n, t) {
|
|
2029
2029
|
n !== null && typeof n == "object" && typeof t > "u" && (t = n, n = null);
|
|
2030
|
-
var a =
|
|
2030
|
+
var a = Un(e, t);
|
|
2031
2031
|
if (typeof n != "function")
|
|
2032
2032
|
return a;
|
|
2033
2033
|
for (var o = 0, r = a.length; o < r; o += 1)
|
|
2034
2034
|
n(a[o]);
|
|
2035
2035
|
}
|
|
2036
|
-
function
|
|
2037
|
-
var t =
|
|
2036
|
+
function Vr(e, n) {
|
|
2037
|
+
var t = Un(e, n);
|
|
2038
2038
|
if (t.length !== 0) {
|
|
2039
2039
|
if (t.length === 1)
|
|
2040
2040
|
return t[0];
|
|
2041
|
-
throw new
|
|
2041
|
+
throw new se("expected a single document in the stream, but found more");
|
|
2042
2042
|
}
|
|
2043
2043
|
}
|
|
2044
|
-
var
|
|
2045
|
-
loadAll:
|
|
2046
|
-
load:
|
|
2047
|
-
},
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
var
|
|
2044
|
+
var Dr = Rr, Gr = Vr, Rn = {
|
|
2045
|
+
loadAll: Dr,
|
|
2046
|
+
load: Gr
|
|
2047
|
+
}, Vn = Object.prototype.toString, Dn = Object.prototype.hasOwnProperty, It = 65279, Hr = 9, Le = 10, Yr = 13, zr = 32, Jr = 33, Wr = 34, dt = 35, Zr = 37, Qr = 38, Xr = 39, ei = 42, Gn = 44, ti = 45, Je = 58, ni = 61, ai = 62, oi = 63, ri = 64, Hn = 91, Yn = 93, ii = 96, zn = 123, si = 124, Jn = 125, ie = {};
|
|
2048
|
+
ie[0] = "\\0";
|
|
2049
|
+
ie[7] = "\\a";
|
|
2050
|
+
ie[8] = "\\b";
|
|
2051
|
+
ie[9] = "\\t";
|
|
2052
|
+
ie[10] = "\\n";
|
|
2053
|
+
ie[11] = "\\v";
|
|
2054
|
+
ie[12] = "\\f";
|
|
2055
|
+
ie[13] = "\\r";
|
|
2056
|
+
ie[27] = "\\e";
|
|
2057
|
+
ie[34] = '\\"';
|
|
2058
|
+
ie[92] = "\\\\";
|
|
2059
|
+
ie[133] = "\\N";
|
|
2060
|
+
ie[160] = "\\_";
|
|
2061
|
+
ie[8232] = "\\L";
|
|
2062
|
+
ie[8233] = "\\P";
|
|
2063
|
+
var li = [
|
|
2064
2064
|
"y",
|
|
2065
2065
|
"Y",
|
|
2066
2066
|
"yes",
|
|
@@ -2077,16 +2077,16 @@ var si = [
|
|
|
2077
2077
|
"off",
|
|
2078
2078
|
"Off",
|
|
2079
2079
|
"OFF"
|
|
2080
|
-
],
|
|
2081
|
-
function
|
|
2080
|
+
], ui = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2081
|
+
function ci(e, n) {
|
|
2082
2082
|
var t, a, o, r, i, s, l;
|
|
2083
2083
|
if (n === null)
|
|
2084
2084
|
return {};
|
|
2085
2085
|
for (t = {}, a = Object.keys(n), o = 0, r = a.length; o < r; o += 1)
|
|
2086
|
-
i = a[o], s = String(n[i]), i.slice(0, 2) === "!!" && (i = "tag:yaml.org,2002:" + i.slice(2)), l = e.compiledTypeMap.fallback[i], l &&
|
|
2086
|
+
i = a[o], s = String(n[i]), i.slice(0, 2) === "!!" && (i = "tag:yaml.org,2002:" + i.slice(2)), l = e.compiledTypeMap.fallback[i], l && Dn.call(l.styleAliases, s) && (s = l.styleAliases[s]), t[i] = s;
|
|
2087
2087
|
return t;
|
|
2088
2088
|
}
|
|
2089
|
-
function
|
|
2089
|
+
function di(e) {
|
|
2090
2090
|
var n, t, a;
|
|
2091
2091
|
if (n = e.toString(16).toUpperCase(), e <= 255)
|
|
2092
2092
|
t = "x", a = 2;
|
|
@@ -2095,25 +2095,25 @@ function ci(e) {
|
|
|
2095
2095
|
else if (e <= 4294967295)
|
|
2096
2096
|
t = "U", a = 8;
|
|
2097
2097
|
else
|
|
2098
|
-
throw new
|
|
2098
|
+
throw new se("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2099
2099
|
return "\\" + t + ne.repeat("0", a - n.length) + n;
|
|
2100
2100
|
}
|
|
2101
|
-
var
|
|
2102
|
-
function
|
|
2103
|
-
this.schema = e.schema ||
|
|
2101
|
+
var pi = 1, Pe = 2;
|
|
2102
|
+
function fi(e) {
|
|
2103
|
+
this.schema = e.schema || kt, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = ne.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = ci(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 === '"' ? Pe : pi, 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;
|
|
2104
2104
|
}
|
|
2105
|
-
function
|
|
2105
|
+
function Wt(e, n) {
|
|
2106
2106
|
for (var t = ne.repeat(" ", n), a = 0, o = -1, r = "", i, s = e.length; a < s; )
|
|
2107
2107
|
o = e.indexOf(`
|
|
2108
2108
|
`, a), o === -1 ? (i = e.slice(a), a = s) : (i = e.slice(a, o + 1), a = o + 1), i.length && i !== `
|
|
2109
2109
|
` && (r += t), r += i;
|
|
2110
2110
|
return r;
|
|
2111
2111
|
}
|
|
2112
|
-
function
|
|
2112
|
+
function pt(e, n) {
|
|
2113
2113
|
return `
|
|
2114
2114
|
` + ne.repeat(" ", e.indent * n);
|
|
2115
2115
|
}
|
|
2116
|
-
function
|
|
2116
|
+
function mi(e, n) {
|
|
2117
2117
|
var t, a, o;
|
|
2118
2118
|
for (t = 0, a = e.implicitTypes.length; t < a; t += 1)
|
|
2119
2119
|
if (o = e.implicitTypes[t], o.resolve(n))
|
|
@@ -2121,46 +2121,46 @@ function fi(e, n) {
|
|
|
2121
2121
|
return !1;
|
|
2122
2122
|
}
|
|
2123
2123
|
function We(e) {
|
|
2124
|
-
return e ===
|
|
2124
|
+
return e === zr || e === Hr;
|
|
2125
2125
|
}
|
|
2126
2126
|
function Ue(e) {
|
|
2127
|
-
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !==
|
|
2127
|
+
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== It || 65536 <= e && e <= 1114111;
|
|
2128
2128
|
}
|
|
2129
|
-
function
|
|
2130
|
-
return Ue(e) && e !==
|
|
2129
|
+
function Zt(e) {
|
|
2130
|
+
return Ue(e) && e !== It && e !== Yr && e !== Le;
|
|
2131
2131
|
}
|
|
2132
|
-
function
|
|
2133
|
-
var a =
|
|
2132
|
+
function Qt(e, n, t) {
|
|
2133
|
+
var a = Zt(e), o = a && !We(e);
|
|
2134
2134
|
return (
|
|
2135
2135
|
// ns-plain-safe
|
|
2136
2136
|
(t ? (
|
|
2137
2137
|
// c = flow-in
|
|
2138
2138
|
a
|
|
2139
|
-
) : a && e !==
|
|
2139
|
+
) : a && e !== Gn && e !== Hn && e !== Yn && e !== zn && e !== Jn) && e !== dt && !(n === Je && !o) || Zt(n) && !We(n) && e === dt || n === Je && o
|
|
2140
2140
|
);
|
|
2141
2141
|
}
|
|
2142
|
-
function mi(e) {
|
|
2143
|
-
return Ue(e) && e !== _t && !We(e) && e !== ei && e !== ai && e !== Je && e !== Dn && e !== Gn && e !== Hn && e !== Yn && e !== zn && e !== ct && e !== Zr && e !== Xr && e !== zr && e !== ii && e !== ti && e !== ni && e !== Qr && e !== Jr && e !== Wr && e !== oi && e !== ri;
|
|
2144
|
-
}
|
|
2145
2142
|
function gi(e) {
|
|
2143
|
+
return Ue(e) && e !== It && !We(e) && e !== ti && e !== oi && e !== Je && e !== Gn && e !== Hn && e !== Yn && e !== zn && e !== Jn && e !== dt && e !== Qr && e !== ei && e !== Jr && e !== si && e !== ni && e !== ai && e !== Xr && e !== Wr && e !== Zr && e !== ri && e !== ii;
|
|
2144
|
+
}
|
|
2145
|
+
function yi(e) {
|
|
2146
2146
|
return !We(e) && e !== Je;
|
|
2147
2147
|
}
|
|
2148
2148
|
function Ke(e, n) {
|
|
2149
2149
|
var t = e.charCodeAt(n), a;
|
|
2150
2150
|
return t >= 55296 && t <= 56319 && n + 1 < e.length && (a = e.charCodeAt(n + 1), a >= 56320 && a <= 57343) ? (t - 55296) * 1024 + a - 56320 + 65536 : t;
|
|
2151
2151
|
}
|
|
2152
|
-
function
|
|
2152
|
+
function Wn(e) {
|
|
2153
2153
|
var n = /^\n* /;
|
|
2154
2154
|
return n.test(e);
|
|
2155
2155
|
}
|
|
2156
|
-
var
|
|
2157
|
-
function
|
|
2158
|
-
var l, c = 0, d = null, u = !1, h = !1, g = a !== -1, C = -1, k =
|
|
2156
|
+
var Zn = 1, ft = 2, Qn = 3, Xn = 4, Oe = 5;
|
|
2157
|
+
function hi(e, n, t, a, o, r, i, s) {
|
|
2158
|
+
var l, c = 0, d = null, u = !1, h = !1, g = a !== -1, C = -1, k = gi(Ke(e, 0)) && yi(Ke(e, e.length - 1));
|
|
2159
2159
|
if (n || i)
|
|
2160
2160
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2161
2161
|
if (c = Ke(e, l), !Ue(c))
|
|
2162
2162
|
return Oe;
|
|
2163
|
-
k = k &&
|
|
2163
|
+
k = k && Qt(c, d, s), d = c;
|
|
2164
2164
|
}
|
|
2165
2165
|
else {
|
|
2166
2166
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
@@ -2169,23 +2169,23 @@ function yi(e, n, t, a, o, r, i, s) {
|
|
|
2169
2169
|
l - C - 1 > a && e[C + 1] !== " ", C = l);
|
|
2170
2170
|
else if (!Ue(c))
|
|
2171
2171
|
return Oe;
|
|
2172
|
-
k = k &&
|
|
2172
|
+
k = k && Qt(c, d, s), d = c;
|
|
2173
2173
|
}
|
|
2174
2174
|
h = h || g && l - C - 1 > a && e[C + 1] !== " ";
|
|
2175
2175
|
}
|
|
2176
|
-
return !u && !h ? k && !i && !o(e) ?
|
|
2176
|
+
return !u && !h ? k && !i && !o(e) ? Zn : r === Pe ? Oe : ft : t > 9 && Wn(e) ? Oe : i ? r === Pe ? Oe : ft : h ? Xn : Qn;
|
|
2177
2177
|
}
|
|
2178
|
-
function
|
|
2178
|
+
function vi(e, n, t, a, o) {
|
|
2179
2179
|
e.dump = function() {
|
|
2180
2180
|
if (n.length === 0)
|
|
2181
2181
|
return e.quotingType === Pe ? '""' : "''";
|
|
2182
|
-
if (!e.noCompatMode && (
|
|
2182
|
+
if (!e.noCompatMode && (li.indexOf(n) !== -1 || ui.test(n)))
|
|
2183
2183
|
return e.quotingType === Pe ? '"' + n + '"' : "'" + n + "'";
|
|
2184
2184
|
var r = e.indent * Math.max(1, t), i = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - r), s = a || e.flowLevel > -1 && t >= e.flowLevel;
|
|
2185
2185
|
function l(c) {
|
|
2186
|
-
return
|
|
2186
|
+
return mi(e, c);
|
|
2187
2187
|
}
|
|
2188
|
-
switch (
|
|
2188
|
+
switch (hi(
|
|
2189
2189
|
n,
|
|
2190
2190
|
s,
|
|
2191
2191
|
e.indent,
|
|
@@ -2195,47 +2195,47 @@ function hi(e, n, t, a, o) {
|
|
|
2195
2195
|
e.forceQuotes && !a,
|
|
2196
2196
|
o
|
|
2197
2197
|
)) {
|
|
2198
|
-
case
|
|
2198
|
+
case Zn:
|
|
2199
2199
|
return n;
|
|
2200
|
-
case
|
|
2200
|
+
case ft:
|
|
2201
2201
|
return "'" + n.replace(/'/g, "''") + "'";
|
|
2202
|
-
case Zn:
|
|
2203
|
-
return "|" + Qt(n, e.indent) + Xt(Jt(n, r));
|
|
2204
2202
|
case Qn:
|
|
2205
|
-
return "
|
|
2203
|
+
return "|" + Xt(n, e.indent) + en(Wt(n, r));
|
|
2204
|
+
case Xn:
|
|
2205
|
+
return ">" + Xt(n, e.indent) + en(Wt(bi(n, i), r));
|
|
2206
2206
|
case Oe:
|
|
2207
|
-
return '"' +
|
|
2207
|
+
return '"' + Ci(n) + '"';
|
|
2208
2208
|
default:
|
|
2209
|
-
throw new
|
|
2209
|
+
throw new se("impossible error: invalid scalar style");
|
|
2210
2210
|
}
|
|
2211
2211
|
}();
|
|
2212
2212
|
}
|
|
2213
|
-
function
|
|
2214
|
-
var t =
|
|
2213
|
+
function Xt(e, n) {
|
|
2214
|
+
var t = Wn(e) ? String(n) : "", a = e[e.length - 1] === `
|
|
2215
2215
|
`, o = a && (e[e.length - 2] === `
|
|
2216
2216
|
` || e === `
|
|
2217
2217
|
`), r = o ? "+" : a ? "" : "-";
|
|
2218
2218
|
return t + r + `
|
|
2219
2219
|
`;
|
|
2220
2220
|
}
|
|
2221
|
-
function
|
|
2221
|
+
function en(e) {
|
|
2222
2222
|
return e[e.length - 1] === `
|
|
2223
2223
|
` ? e.slice(0, -1) : e;
|
|
2224
2224
|
}
|
|
2225
|
-
function
|
|
2225
|
+
function bi(e, n) {
|
|
2226
2226
|
for (var t = /(\n+)([^\n]*)/g, a = function() {
|
|
2227
2227
|
var c = e.indexOf(`
|
|
2228
2228
|
`);
|
|
2229
|
-
return c = c !== -1 ? c : e.length, t.lastIndex = c,
|
|
2229
|
+
return c = c !== -1 ? c : e.length, t.lastIndex = c, tn(e.slice(0, c), n);
|
|
2230
2230
|
}(), o = e[0] === `
|
|
2231
2231
|
` || e[0] === " ", r, i; i = t.exec(e); ) {
|
|
2232
2232
|
var s = i[1], l = i[2];
|
|
2233
2233
|
r = l[0] === " ", a += s + (!o && !r && l !== "" ? `
|
|
2234
|
-
` : "") +
|
|
2234
|
+
` : "") + tn(l, n), o = r;
|
|
2235
2235
|
}
|
|
2236
2236
|
return a;
|
|
2237
2237
|
}
|
|
2238
|
-
function
|
|
2238
|
+
function tn(e, n) {
|
|
2239
2239
|
if (e === "" || e[0] === " ")
|
|
2240
2240
|
return e;
|
|
2241
2241
|
for (var t = / [^ ]/g, a, o = 0, r, i = 0, s = 0, l = ""; a = t.exec(e); )
|
|
@@ -2245,52 +2245,52 @@ function en(e, n) {
|
|
|
2245
2245
|
`, e.length - o > n && i > o ? l += e.slice(o, i) + `
|
|
2246
2246
|
` + e.slice(i + 1) : l += e.slice(o), l.slice(1);
|
|
2247
2247
|
}
|
|
2248
|
-
function
|
|
2248
|
+
function Ci(e) {
|
|
2249
2249
|
for (var n = "", t = 0, a, o = 0; o < e.length; t >= 65536 ? o += 2 : o++)
|
|
2250
|
-
t = Ke(e, o), a =
|
|
2250
|
+
t = Ke(e, o), a = ie[t], !a && Ue(t) ? (n += e[o], t >= 65536 && (n += e[o + 1])) : n += a || di(t);
|
|
2251
2251
|
return n;
|
|
2252
2252
|
}
|
|
2253
|
-
function
|
|
2253
|
+
function ki(e, n, t) {
|
|
2254
2254
|
var a = "", o = e.tag, r, i, s;
|
|
2255
2255
|
for (r = 0, i = t.length; r < i; r += 1)
|
|
2256
2256
|
s = t[r], e.replacer && (s = e.replacer.call(t, String(r), s)), (he(e, n, s, !1, !1) || typeof s > "u" && he(e, n, null, !1, !1)) && (a !== "" && (a += "," + (e.condenseFlow ? "" : " ")), a += e.dump);
|
|
2257
2257
|
e.tag = o, e.dump = "[" + a + "]";
|
|
2258
2258
|
}
|
|
2259
|
-
function
|
|
2259
|
+
function nn(e, n, t, a) {
|
|
2260
2260
|
var o = "", r = e.tag, i, s, l;
|
|
2261
2261
|
for (i = 0, s = t.length; i < s; i += 1)
|
|
2262
|
-
l = t[i], e.replacer && (l = e.replacer.call(t, String(i), l)), (he(e, n + 1, l, !0, !0, !1, !0) || typeof l > "u" && he(e, n + 1, null, !0, !0, !1, !0)) && ((!a || o !== "") && (o +=
|
|
2262
|
+
l = t[i], e.replacer && (l = e.replacer.call(t, String(i), l)), (he(e, n + 1, l, !0, !0, !1, !0) || typeof l > "u" && he(e, n + 1, null, !0, !0, !1, !0)) && ((!a || o !== "") && (o += pt(e, n)), e.dump && Le === e.dump.charCodeAt(0) ? o += "-" : o += "- ", o += e.dump);
|
|
2263
2263
|
e.tag = r, e.dump = o || "[]";
|
|
2264
2264
|
}
|
|
2265
|
-
function
|
|
2265
|
+
function wi(e, n, t) {
|
|
2266
2266
|
var a = "", o = e.tag, r = Object.keys(t), i, s, l, c, d;
|
|
2267
2267
|
for (i = 0, s = r.length; i < s; i += 1)
|
|
2268
2268
|
d = "", a !== "" && (d += ", "), e.condenseFlow && (d += '"'), l = r[i], c = t[l], e.replacer && (c = e.replacer.call(t, l, c)), he(e, n, l, !1, !1) && (e.dump.length > 1024 && (d += "? "), d += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), he(e, n, c, !1, !1) && (d += e.dump, a += d));
|
|
2269
2269
|
e.tag = o, e.dump = "{" + a + "}";
|
|
2270
2270
|
}
|
|
2271
|
-
function
|
|
2271
|
+
function _i(e, n, t, a) {
|
|
2272
2272
|
var o = "", r = e.tag, i = Object.keys(t), s, l, c, d, u, h;
|
|
2273
2273
|
if (e.sortKeys === !0)
|
|
2274
2274
|
i.sort();
|
|
2275
2275
|
else if (typeof e.sortKeys == "function")
|
|
2276
2276
|
i.sort(e.sortKeys);
|
|
2277
2277
|
else if (e.sortKeys)
|
|
2278
|
-
throw new
|
|
2278
|
+
throw new se("sortKeys must be a boolean or a function");
|
|
2279
2279
|
for (s = 0, l = i.length; s < l; s += 1)
|
|
2280
|
-
h = "", (!a || o !== "") && (h +=
|
|
2280
|
+
h = "", (!a || o !== "") && (h += pt(e, n)), c = i[s], d = t[c], e.replacer && (d = e.replacer.call(t, c, d)), he(e, n + 1, c, !0, !0, !0) && (u = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, u && (e.dump && Le === e.dump.charCodeAt(0) ? h += "?" : h += "? "), h += e.dump, u && (h += pt(e, n)), he(e, n + 1, d, !0, u) && (e.dump && Le === e.dump.charCodeAt(0) ? h += ":" : h += ": ", h += e.dump, o += h));
|
|
2281
2281
|
e.tag = r, e.dump = o || "{}";
|
|
2282
2282
|
}
|
|
2283
|
-
function
|
|
2283
|
+
function an(e, n, t) {
|
|
2284
2284
|
var a, o, r, i, s, l;
|
|
2285
2285
|
for (o = t ? e.explicitTypes : e.implicitTypes, r = 0, i = o.length; r < i; r += 1)
|
|
2286
2286
|
if (s = o[r], (s.instanceOf || s.predicate) && (!s.instanceOf || typeof n == "object" && n instanceof s.instanceOf) && (!s.predicate || s.predicate(n))) {
|
|
2287
2287
|
if (t ? s.multi && s.representName ? e.tag = s.representName(n) : e.tag = s.tag : e.tag = "?", s.represent) {
|
|
2288
|
-
if (l = e.styleMap[s.tag] || s.defaultStyle,
|
|
2288
|
+
if (l = e.styleMap[s.tag] || s.defaultStyle, Vn.call(s.represent) === "[object Function]")
|
|
2289
2289
|
a = s.represent(n, l);
|
|
2290
|
-
else if (
|
|
2290
|
+
else if (Dn.call(s.represent, l))
|
|
2291
2291
|
a = s.represent[l](n, l);
|
|
2292
2292
|
else
|
|
2293
|
-
throw new
|
|
2293
|
+
throw new se("!<" + s.tag + '> tag resolver accepts not "' + l + '" style');
|
|
2294
2294
|
e.dump = a;
|
|
2295
2295
|
}
|
|
2296
2296
|
return !0;
|
|
@@ -2298,23 +2298,23 @@ function nn(e, n, t) {
|
|
|
2298
2298
|
return !1;
|
|
2299
2299
|
}
|
|
2300
2300
|
function he(e, n, t, a, o, r, i) {
|
|
2301
|
-
e.tag = null, e.dump = t,
|
|
2302
|
-
var s =
|
|
2301
|
+
e.tag = null, e.dump = t, an(e, t, !1) || an(e, t, !0);
|
|
2302
|
+
var s = Vn.call(e.dump), l = a, c;
|
|
2303
2303
|
a && (a = e.flowLevel < 0 || e.flowLevel > n);
|
|
2304
2304
|
var d = s === "[object Object]" || s === "[object Array]", u, h;
|
|
2305
2305
|
if (d && (u = e.duplicates.indexOf(t), h = u !== -1), (e.tag !== null && e.tag !== "?" || h || e.indent !== 2 && n > 0) && (o = !1), h && e.usedDuplicates[u])
|
|
2306
2306
|
e.dump = "*ref_" + u;
|
|
2307
2307
|
else {
|
|
2308
2308
|
if (d && h && !e.usedDuplicates[u] && (e.usedDuplicates[u] = !0), s === "[object Object]")
|
|
2309
|
-
a && Object.keys(e.dump).length !== 0 ? (
|
|
2309
|
+
a && Object.keys(e.dump).length !== 0 ? (_i(e, n, e.dump, o), h && (e.dump = "&ref_" + u + e.dump)) : (wi(e, n, e.dump), h && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2310
2310
|
else if (s === "[object Array]")
|
|
2311
|
-
a && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ?
|
|
2311
|
+
a && e.dump.length !== 0 ? (e.noArrayIndent && !i && n > 0 ? nn(e, n - 1, e.dump, o) : nn(e, n, e.dump, o), h && (e.dump = "&ref_" + u + e.dump)) : (ki(e, n, e.dump), h && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2312
2312
|
else if (s === "[object String]")
|
|
2313
|
-
e.tag !== "?" &&
|
|
2313
|
+
e.tag !== "?" && vi(e, e.dump, n, r, l);
|
|
2314
2314
|
else {
|
|
2315
2315
|
if (s === "[object Undefined]" || e.skipInvalid)
|
|
2316
2316
|
return !1;
|
|
2317
|
-
throw new
|
|
2317
|
+
throw new se("unacceptable kind of an object to dump " + s);
|
|
2318
2318
|
}
|
|
2319
2319
|
e.tag !== null && e.tag !== "?" && (c = encodeURI(
|
|
2320
2320
|
e.tag[0] === "!" ? e.tag.slice(1) : e.tag
|
|
@@ -2322,83 +2322,83 @@ function he(e, n, t, a, o, r, i) {
|
|
|
2322
2322
|
}
|
|
2323
2323
|
return !0;
|
|
2324
2324
|
}
|
|
2325
|
-
function
|
|
2325
|
+
function Ii(e, n) {
|
|
2326
2326
|
var t = [], a = [], o, r;
|
|
2327
|
-
for (
|
|
2327
|
+
for (mt(e, t, a), o = 0, r = a.length; o < r; o += 1)
|
|
2328
2328
|
n.duplicates.push(t[a[o]]);
|
|
2329
2329
|
n.usedDuplicates = new Array(r);
|
|
2330
2330
|
}
|
|
2331
|
-
function
|
|
2331
|
+
function mt(e, n, t) {
|
|
2332
2332
|
var a, o, r;
|
|
2333
2333
|
if (e !== null && typeof e == "object")
|
|
2334
2334
|
if (o = n.indexOf(e), o !== -1)
|
|
2335
2335
|
t.indexOf(o) === -1 && t.push(o);
|
|
2336
2336
|
else if (n.push(e), Array.isArray(e))
|
|
2337
2337
|
for (o = 0, r = e.length; o < r; o += 1)
|
|
2338
|
-
|
|
2338
|
+
mt(e[o], n, t);
|
|
2339
2339
|
else
|
|
2340
2340
|
for (a = Object.keys(e), o = 0, r = a.length; o < r; o += 1)
|
|
2341
|
-
|
|
2341
|
+
mt(e[a[o]], n, t);
|
|
2342
2342
|
}
|
|
2343
|
-
function
|
|
2343
|
+
function Ai(e, n) {
|
|
2344
2344
|
n = n || {};
|
|
2345
|
-
var t = new
|
|
2346
|
-
t.noRefs ||
|
|
2345
|
+
var t = new fi(n);
|
|
2346
|
+
t.noRefs || Ii(e, t);
|
|
2347
2347
|
var a = e;
|
|
2348
2348
|
return t.replacer && (a = t.replacer.call({ "": a }, "", a)), he(t, 0, a, !0, !0) ? t.dump + `
|
|
2349
2349
|
` : "";
|
|
2350
2350
|
}
|
|
2351
|
-
var
|
|
2352
|
-
dump:
|
|
2351
|
+
var Si = Ai, xi = {
|
|
2352
|
+
dump: Si
|
|
2353
2353
|
};
|
|
2354
|
-
function
|
|
2354
|
+
function At(e, n) {
|
|
2355
2355
|
return function() {
|
|
2356
2356
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + n + " instead, which is now safe by default.");
|
|
2357
2357
|
};
|
|
2358
2358
|
}
|
|
2359
|
-
var
|
|
2360
|
-
binary:
|
|
2361
|
-
float:
|
|
2362
|
-
map:
|
|
2363
|
-
null:
|
|
2364
|
-
pairs:
|
|
2365
|
-
set:
|
|
2366
|
-
timestamp:
|
|
2367
|
-
bool:
|
|
2368
|
-
int:
|
|
2369
|
-
merge:
|
|
2370
|
-
omap:
|
|
2371
|
-
seq:
|
|
2372
|
-
str:
|
|
2373
|
-
},
|
|
2374
|
-
Type:
|
|
2375
|
-
Schema:
|
|
2376
|
-
FAILSAFE_SCHEMA:
|
|
2377
|
-
JSON_SCHEMA:
|
|
2378
|
-
CORE_SCHEMA:
|
|
2379
|
-
DEFAULT_SCHEMA:
|
|
2380
|
-
load:
|
|
2381
|
-
loadAll:
|
|
2382
|
-
dump:
|
|
2383
|
-
YAMLException:
|
|
2384
|
-
types:
|
|
2385
|
-
safeLoad:
|
|
2386
|
-
safeLoadAll:
|
|
2387
|
-
safeDump:
|
|
2359
|
+
var Ti = re, $i = gn, Mi = bn, Oi = In, ji = An, Ei = kt, Fi = Rn.load, Bi = Rn.loadAll, Ki = xi.dump, Ni = se, qi = {
|
|
2360
|
+
binary: Mn,
|
|
2361
|
+
float: _n,
|
|
2362
|
+
map: vn,
|
|
2363
|
+
null: Cn,
|
|
2364
|
+
pairs: jn,
|
|
2365
|
+
set: En,
|
|
2366
|
+
timestamp: Tn,
|
|
2367
|
+
bool: kn,
|
|
2368
|
+
int: wn,
|
|
2369
|
+
merge: $n,
|
|
2370
|
+
omap: On,
|
|
2371
|
+
seq: hn,
|
|
2372
|
+
str: yn
|
|
2373
|
+
}, Li = At("safeLoad", "load"), Pi = At("safeLoadAll", "loadAll"), Ui = At("safeDump", "dump"), Ri = {
|
|
2374
|
+
Type: Ti,
|
|
2375
|
+
Schema: $i,
|
|
2376
|
+
FAILSAFE_SCHEMA: Mi,
|
|
2377
|
+
JSON_SCHEMA: Oi,
|
|
2378
|
+
CORE_SCHEMA: ji,
|
|
2379
|
+
DEFAULT_SCHEMA: Ei,
|
|
2380
|
+
load: Fi,
|
|
2381
|
+
loadAll: Bi,
|
|
2382
|
+
dump: Ki,
|
|
2383
|
+
YAMLException: Ni,
|
|
2384
|
+
types: qi,
|
|
2385
|
+
safeLoad: Li,
|
|
2386
|
+
safeLoadAll: Pi,
|
|
2387
|
+
safeDump: Ui
|
|
2388
2388
|
};
|
|
2389
|
-
const
|
|
2389
|
+
const Vi = {
|
|
2390
2390
|
key: 0,
|
|
2391
2391
|
class: "config-card-display-form"
|
|
2392
|
-
},
|
|
2392
|
+
}, Di = ["data-testid"], Gi = {
|
|
2393
2393
|
key: 0,
|
|
2394
2394
|
class: "config-card-prop-section-title"
|
|
2395
|
-
},
|
|
2395
|
+
}, Hi = {
|
|
2396
2396
|
key: 1,
|
|
2397
2397
|
class: "config-card-display-json"
|
|
2398
|
-
},
|
|
2398
|
+
}, Yi = {
|
|
2399
2399
|
key: 2,
|
|
2400
2400
|
class: "config-card-display-yaml"
|
|
2401
|
-
},
|
|
2401
|
+
}, zi = /* @__PURE__ */ te({
|
|
2402
2402
|
__name: "ConfigCardDisplay",
|
|
2403
2403
|
props: {
|
|
2404
2404
|
propertyCollections: {
|
|
@@ -2426,18 +2426,18 @@ const Ri = {
|
|
|
2426
2426
|
setup(e) {
|
|
2427
2427
|
const n = e, t = Ze(), { i18n: { t: a } } = oe.useI18n(), o = (s) => !!(s.tooltip || t[`${s.key}-label-tooltip`]), r = F(""), i = F("");
|
|
2428
2428
|
return ke(() => n.format, (s) => {
|
|
2429
|
-
s === "json" ? r.value = JSON.stringify(n.record, null, 2) : s === "yaml" && (i.value =
|
|
2429
|
+
s === "json" ? r.value = JSON.stringify(n.record, null, 2) : s === "yaml" && (i.value = Ri.dump(n.record));
|
|
2430
2430
|
}, { immediate: !0 }), (s, l) => {
|
|
2431
2431
|
const c = q("KCodeBlock");
|
|
2432
2432
|
return f(), x(pe, null, [
|
|
2433
|
-
e.format === "structured" ? (f(), x("div",
|
|
2433
|
+
e.format === "structured" ? (f(), x("div", Vi, [
|
|
2434
2434
|
(f(!0), x(pe, null, ce(e.propListTypes, (d) => (f(), x("div", {
|
|
2435
2435
|
key: `config-card-details-${d}-props`,
|
|
2436
2436
|
class: Ae(`config-card-details-${d}-props`),
|
|
2437
2437
|
"data-testid": `config-card-details-${d}-props`
|
|
2438
2438
|
}, [
|
|
2439
|
-
d !== "basic" ? (f(), x("div",
|
|
2440
|
-
(f(!0), x(pe, null, ce(e.propertyCollections[d], (u) => (f(),
|
|
2439
|
+
d !== "basic" ? (f(), x("div", Gi, M(d === "advanced" ? m(a)("baseConfigCard.sections.advanced") : m(a)("baseConfigCard.sections.plugin")), 1)) : G("", !0),
|
|
2440
|
+
(f(!0), x(pe, null, ce(e.propertyCollections[d], (u) => (f(), U(bt, {
|
|
2441
2441
|
key: u.key,
|
|
2442
2442
|
item: u
|
|
2443
2443
|
}, ve({
|
|
@@ -2460,9 +2460,9 @@ const Ri = {
|
|
|
2460
2460
|
key: "0"
|
|
2461
2461
|
} : void 0
|
|
2462
2462
|
]), 1032, ["item"]))), 128))
|
|
2463
|
-
], 10,
|
|
2463
|
+
], 10, Di))), 128))
|
|
2464
2464
|
])) : G("", !0),
|
|
2465
|
-
e.format === "json" ? (f(), x("div",
|
|
2465
|
+
e.format === "json" ? (f(), x("div", Hi, [
|
|
2466
2466
|
O(c, {
|
|
2467
2467
|
id: "config-card-codeblock",
|
|
2468
2468
|
code: r.value,
|
|
@@ -2470,7 +2470,7 @@ const Ri = {
|
|
|
2470
2470
|
theme: "dark"
|
|
2471
2471
|
}, null, 8, ["code"])
|
|
2472
2472
|
])) : G("", !0),
|
|
2473
|
-
e.format === "yaml" ? (f(), x("div",
|
|
2473
|
+
e.format === "yaml" ? (f(), x("div", Yi, [
|
|
2474
2474
|
O(c, {
|
|
2475
2475
|
id: "config-card-codeblock",
|
|
2476
2476
|
code: i.value,
|
|
@@ -2482,18 +2482,18 @@ const Ri = {
|
|
|
2482
2482
|
], 64);
|
|
2483
2483
|
};
|
|
2484
2484
|
}
|
|
2485
|
-
}),
|
|
2485
|
+
}), Ji = /* @__PURE__ */ me(zi, [["__scopeId", "data-v-a58d7adb"]]), on = "24px", Wi = (e, n) => {
|
|
2486
2486
|
const t = e.__vccOpts || e;
|
|
2487
2487
|
for (const [a, o] of n)
|
|
2488
2488
|
t[a] = o;
|
|
2489
2489
|
return t;
|
|
2490
|
-
},
|
|
2490
|
+
}, Zi = (e) => (ma("data-v-817dfcab"), e = e(), ga(), e), Qi = ["aria-hidden"], Xi = {
|
|
2491
2491
|
key: 0,
|
|
2492
2492
|
"data-testid": "kui-icon-svg-title"
|
|
2493
|
-
},
|
|
2493
|
+
}, es = /* @__PURE__ */ Zi(() => /* @__PURE__ */ B("path", {
|
|
2494
2494
|
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",
|
|
2495
2495
|
fill: "currentColor"
|
|
2496
|
-
}, null, -1)),
|
|
2496
|
+
}, null, -1)), ts = /* @__PURE__ */ te({
|
|
2497
2497
|
__name: "BookIcon",
|
|
2498
2498
|
props: {
|
|
2499
2499
|
/** The accessibility text provided to screen readers */
|
|
@@ -2524,7 +2524,7 @@ const Ri = {
|
|
|
2524
2524
|
size: {
|
|
2525
2525
|
type: [Number, String],
|
|
2526
2526
|
required: !1,
|
|
2527
|
-
default:
|
|
2527
|
+
default: on,
|
|
2528
2528
|
// if setting to the imported const fails, just pass a number of 24 as the default.
|
|
2529
2529
|
validator: (e) => {
|
|
2530
2530
|
if (typeof e == "number" && e > 0)
|
|
@@ -2553,7 +2553,7 @@ const Ri = {
|
|
|
2553
2553
|
if (r && !isNaN(r) && Number.isInteger(r) && r > 0)
|
|
2554
2554
|
return `${r}px`;
|
|
2555
2555
|
}
|
|
2556
|
-
return
|
|
2556
|
+
return on;
|
|
2557
2557
|
}), a = j(() => ({
|
|
2558
2558
|
boxSizing: "border-box",
|
|
2559
2559
|
color: n.color,
|
|
@@ -2562,11 +2562,11 @@ const Ri = {
|
|
|
2562
2562
|
lineHeight: "0",
|
|
2563
2563
|
width: t.value
|
|
2564
2564
|
}));
|
|
2565
|
-
return (o, r) => (f(),
|
|
2565
|
+
return (o, r) => (f(), U(Ne(e.as), {
|
|
2566
2566
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2567
2567
|
class: "kui-icon book-icon",
|
|
2568
2568
|
"data-testid": "kui-icon-wrapper-book-icon",
|
|
2569
|
-
style:
|
|
2569
|
+
style: pa(a.value)
|
|
2570
2570
|
}, {
|
|
2571
2571
|
default: y(() => [
|
|
2572
2572
|
(f(), x("svg", {
|
|
@@ -2579,23 +2579,23 @@ const Ri = {
|
|
|
2579
2579
|
width: "100%",
|
|
2580
2580
|
xmlns: "http://www.w3.org/2000/svg"
|
|
2581
2581
|
}, [
|
|
2582
|
-
e.title ? (f(), x("title",
|
|
2583
|
-
|
|
2584
|
-
], 8,
|
|
2582
|
+
e.title ? (f(), x("title", Xi, M(e.title), 1)) : G("", !0),
|
|
2583
|
+
es
|
|
2584
|
+
], 8, Qi))
|
|
2585
2585
|
]),
|
|
2586
2586
|
_: 1
|
|
2587
2587
|
}, 8, ["aria-hidden", "style"]));
|
|
2588
2588
|
}
|
|
2589
|
-
}),
|
|
2589
|
+
}), ns = /* @__PURE__ */ Wi(ts, [["__scopeId", "data-v-817dfcab"]]), as = { "data-testid": "config-card-title" }, os = { class: "config-card-actions" }, rs = ["href"], is = {
|
|
2590
2590
|
key: 2,
|
|
2591
2591
|
class: "config-card-details-section"
|
|
2592
|
-
},
|
|
2592
|
+
}, ss = {
|
|
2593
2593
|
key: 3,
|
|
2594
2594
|
class: "config-card-details-section"
|
|
2595
|
-
},
|
|
2595
|
+
}, ls = ["data-testid"], us = {
|
|
2596
2596
|
key: 0,
|
|
2597
2597
|
class: "config-card-prop-section-title"
|
|
2598
|
-
},
|
|
2598
|
+
}, cs = /* @__PURE__ */ te({
|
|
2599
2599
|
__name: "EntityBaseConfigCard",
|
|
2600
2600
|
props: {
|
|
2601
2601
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2726,58 +2726,58 @@ const Ri = {
|
|
|
2726
2726
|
var w, I, L;
|
|
2727
2727
|
if (!p.value)
|
|
2728
2728
|
return [];
|
|
2729
|
-
const
|
|
2729
|
+
const D = [], S = Object.keys(p.value).length;
|
|
2730
2730
|
for (const K in p.value) {
|
|
2731
|
-
const N = (I = (w = a.configSchema) == null ? void 0 : w[K]) == null ? void 0 : I.order,
|
|
2731
|
+
const N = (I = (w = a.configSchema) == null ? void 0 : w[K]) == null ? void 0 : I.order, R = (L = h[K]) == null ? void 0 : L.order;
|
|
2732
2732
|
let Z = S;
|
|
2733
|
-
(
|
|
2733
|
+
(R || R === 0) && (Z = R === -1 ? S + 1 : R), N && (Z = N === -1 ? S + 1 : N), D.push([K, Z]);
|
|
2734
2734
|
}
|
|
2735
|
-
return
|
|
2735
|
+
return D.sort(function(K, N) {
|
|
2736
2736
|
return K[1] - N[1];
|
|
2737
|
-
}),
|
|
2738
|
-
var N,
|
|
2739
|
-
const Z = K[0], H = (N = p.value) == null ? void 0 : N[Z], Q = ((
|
|
2737
|
+
}), D.map((K) => {
|
|
2738
|
+
var N, R;
|
|
2739
|
+
const Z = K[0], H = (N = p.value) == null ? void 0 : N[Z], Q = ((R = a.configSchema) == null ? void 0 : R[Z]) || {}, le = h[Z];
|
|
2740
2740
|
return {
|
|
2741
2741
|
key: Z,
|
|
2742
2742
|
value: H,
|
|
2743
2743
|
hidden: Q.hidden || !1,
|
|
2744
|
-
type: Q.type ?? ((
|
|
2745
|
-
label: Q.label ?? ((
|
|
2746
|
-
tooltip: Q.tooltip ?? ((
|
|
2747
|
-
section: Q.section ?? ((
|
|
2744
|
+
type: Q.type ?? ((le == null ? void 0 : le.type) || X.Text),
|
|
2745
|
+
label: Q.label ?? ((le == null ? void 0 : le.label) || s(Z)),
|
|
2746
|
+
tooltip: Q.tooltip ?? ((le == null ? void 0 : le.tooltip) || void 0),
|
|
2747
|
+
section: Q.section ?? ((le == null ? void 0 : le.section) || ue.Advanced)
|
|
2748
2748
|
};
|
|
2749
2749
|
}).filter((K) => !K.hidden && K.key !== a.pluginConfigKey);
|
|
2750
2750
|
}), v = j(() => {
|
|
2751
2751
|
var w, I;
|
|
2752
2752
|
if (!p.value || !a.pluginConfigKey)
|
|
2753
2753
|
return [];
|
|
2754
|
-
const L = p.value[a.pluginConfigKey] || {},
|
|
2754
|
+
const L = p.value[a.pluginConfigKey] || {}, D = Object.keys(L).length, S = [];
|
|
2755
2755
|
for (const K in L) {
|
|
2756
|
-
const N = (I = (w = a.pluginConfigSchema) == null ? void 0 : w[K]) == null ? void 0 : I.order,
|
|
2757
|
-
let Z =
|
|
2758
|
-
N && (Z = N === -1 ?
|
|
2756
|
+
const N = (I = (w = a.pluginConfigSchema) == null ? void 0 : w[K]) == null ? void 0 : I.order, R = L[K];
|
|
2757
|
+
let Z = R != null && R !== "" ? D - 1 : D;
|
|
2758
|
+
N && (Z = N === -1 ? D + 1 : N), S.push([K, Z]);
|
|
2759
2759
|
}
|
|
2760
2760
|
return S.sort(function(K, N) {
|
|
2761
2761
|
return K[1] - N[1];
|
|
2762
2762
|
}), S.map((K) => {
|
|
2763
2763
|
var N;
|
|
2764
|
-
const
|
|
2764
|
+
const R = K[0], Z = L[R], H = ((N = a.pluginConfigSchema) == null ? void 0 : N[R]) || {};
|
|
2765
2765
|
return {
|
|
2766
|
-
key:
|
|
2766
|
+
key: R,
|
|
2767
2767
|
value: Z,
|
|
2768
2768
|
hidden: H.hidden || !1,
|
|
2769
2769
|
type: H.type ?? X.Text,
|
|
2770
|
-
label: H.label ?? s(
|
|
2770
|
+
label: H.label ?? s(R),
|
|
2771
2771
|
tooltip: H.tooltip ?? void 0,
|
|
2772
2772
|
section: ue.Plugin
|
|
2773
2773
|
};
|
|
2774
2774
|
}).filter((K) => !K.hidden);
|
|
2775
2775
|
}), A = j(() => {
|
|
2776
|
-
var w, I, L,
|
|
2776
|
+
var w, I, L, D;
|
|
2777
2777
|
return {
|
|
2778
2778
|
basic: (w = b.value) == null ? void 0 : w.filter((S) => S.section === ue.Basic),
|
|
2779
2779
|
advanced: (I = b.value) == null ? void 0 : I.filter((S) => S.section === ue.Advanced),
|
|
2780
|
-
plugin: (
|
|
2780
|
+
plugin: (D = v.value) == null ? void 0 : D.concat((L = b.value) == null ? void 0 : L.filter((S) => S.section === ue.Plugin))
|
|
2781
2781
|
};
|
|
2782
2782
|
}), V = j(() => {
|
|
2783
2783
|
const w = [];
|
|
@@ -2812,12 +2812,12 @@ const Ri = {
|
|
|
2812
2812
|
g.value = !1;
|
|
2813
2813
|
}
|
|
2814
2814
|
}), (w, I) => {
|
|
2815
|
-
const L = q("KLabel"),
|
|
2816
|
-
return f(),
|
|
2815
|
+
const L = q("KLabel"), D = q("KSelect"), S = q("KButton"), K = q("KClipboardProvider"), N = q("KSkeleton"), R = q("KEmptyState"), Z = q("KCard");
|
|
2816
|
+
return f(), U(Z, { class: "kong-ui-entity-base-config-card" }, ve({
|
|
2817
2817
|
actions: y(() => [
|
|
2818
|
-
B("div",
|
|
2818
|
+
B("div", os, [
|
|
2819
2819
|
J(w.$slots, "actions", {}, void 0, !0),
|
|
2820
|
-
e.config.jsonYamlEnabled ? (f(),
|
|
2820
|
+
e.config.jsonYamlEnabled ? (f(), U(L, {
|
|
2821
2821
|
key: 0,
|
|
2822
2822
|
class: "config-format-select-label",
|
|
2823
2823
|
"data-testid": "config-format-select-label"
|
|
@@ -2827,14 +2827,14 @@ const Ri = {
|
|
|
2827
2827
|
]),
|
|
2828
2828
|
_: 1
|
|
2829
2829
|
})) : G("", !0),
|
|
2830
|
-
e.config.jsonYamlEnabled ? (f(),
|
|
2830
|
+
e.config.jsonYamlEnabled ? (f(), U(D, {
|
|
2831
2831
|
key: 1,
|
|
2832
2832
|
appearance: "select",
|
|
2833
2833
|
"data-testid": "select-config-format",
|
|
2834
2834
|
items: c,
|
|
2835
2835
|
onChange: u
|
|
2836
2836
|
})) : G("", !0),
|
|
2837
|
-
a.config.jsonYamlEnabled && e.configCardDoc ? (f(),
|
|
2837
|
+
a.config.jsonYamlEnabled && e.configCardDoc ? (f(), U(S, {
|
|
2838
2838
|
key: 2,
|
|
2839
2839
|
appearance: "btn-link",
|
|
2840
2840
|
class: "book-icon",
|
|
@@ -2846,14 +2846,14 @@ const Ri = {
|
|
|
2846
2846
|
rel: "noopener",
|
|
2847
2847
|
target: "_blank"
|
|
2848
2848
|
}, [
|
|
2849
|
-
O(m(
|
|
2850
|
-
], 8,
|
|
2849
|
+
O(m(ns), { size: m(lo) }, null, 8, ["size"])
|
|
2850
|
+
], 8, rs)
|
|
2851
2851
|
]),
|
|
2852
2852
|
_: 1
|
|
2853
2853
|
})) : G("", !0),
|
|
2854
|
-
e.config.jsonYamlEnabled ? G("", !0) : (f(),
|
|
2854
|
+
e.config.jsonYamlEnabled ? G("", !0) : (f(), U(K, { key: 3 }, {
|
|
2855
2855
|
default: y(({ copyToClipboard: H }) => [
|
|
2856
|
-
!g.value && !C.value ? (f(),
|
|
2856
|
+
!g.value && !C.value ? (f(), U(S, {
|
|
2857
2857
|
key: 0,
|
|
2858
2858
|
appearance: "btn-link",
|
|
2859
2859
|
"data-testid": "json-copy-button",
|
|
@@ -2870,12 +2870,12 @@ const Ri = {
|
|
|
2870
2870
|
])
|
|
2871
2871
|
]),
|
|
2872
2872
|
body: y(() => [
|
|
2873
|
-
g.value ? (f(),
|
|
2873
|
+
g.value ? (f(), U(N, {
|
|
2874
2874
|
key: 0,
|
|
2875
2875
|
"data-testid": "config-card-loader",
|
|
2876
2876
|
"table-columns": 2,
|
|
2877
2877
|
type: "table"
|
|
2878
|
-
})) : C.value ? (f(), R
|
|
2878
|
+
})) : C.value ? (f(), U(R, {
|
|
2879
2879
|
key: 1,
|
|
2880
2880
|
"data-testid": "config-card-fetch-error",
|
|
2881
2881
|
"is-error": ""
|
|
@@ -2885,8 +2885,8 @@ const Ri = {
|
|
|
2885
2885
|
]),
|
|
2886
2886
|
_: 1
|
|
2887
2887
|
})) : G("", !0),
|
|
2888
|
-
e.config.jsonYamlEnabled ? (f(), x("div",
|
|
2889
|
-
O(
|
|
2888
|
+
e.config.jsonYamlEnabled ? (f(), x("div", is, [
|
|
2889
|
+
O(Ji, {
|
|
2890
2890
|
format: d.value,
|
|
2891
2891
|
"prop-list-types": V.value,
|
|
2892
2892
|
"property-collections": A.value,
|
|
@@ -2894,32 +2894,32 @@ const Ri = {
|
|
|
2894
2894
|
}, ve({ _: 2 }, [
|
|
2895
2895
|
ce(Object.keys(w.$slots), (H) => ({
|
|
2896
2896
|
name: H,
|
|
2897
|
-
fn: y(({ row: Q, rowValue:
|
|
2897
|
+
fn: y(({ row: Q, rowValue: le }) => [
|
|
2898
2898
|
J(w.$slots, H, {
|
|
2899
2899
|
row: Q,
|
|
2900
|
-
rowValue:
|
|
2900
|
+
rowValue: le
|
|
2901
2901
|
}, void 0, !0)
|
|
2902
2902
|
])
|
|
2903
2903
|
}))
|
|
2904
2904
|
]), 1032, ["format", "prop-list-types", "property-collections", "record"])
|
|
2905
|
-
])) : (f(), x("div",
|
|
2905
|
+
])) : (f(), x("div", ss, [
|
|
2906
2906
|
(f(!0), x(pe, null, ce(V.value, (H) => (f(), x("div", {
|
|
2907
2907
|
key: `config-card-details-${H}-props`,
|
|
2908
2908
|
class: Ae(`config-card-details-${H}-props`),
|
|
2909
2909
|
"data-testid": `config-card-details-${H}-props`
|
|
2910
2910
|
}, [
|
|
2911
|
-
H !== "basic" ? (f(), x("div",
|
|
2912
|
-
(f(!0), x(pe, null, ce(A.value[H], (Q) => (f(),
|
|
2911
|
+
H !== "basic" ? (f(), x("div", us, M(H === "advanced" ? m(r)("baseConfigCard.sections.advanced") : m(r)("baseConfigCard.sections.plugin")), 1)) : G("", !0),
|
|
2912
|
+
(f(!0), x(pe, null, ce(A.value[H], (Q) => (f(), U(bt, {
|
|
2913
2913
|
key: Q.key,
|
|
2914
2914
|
item: Q
|
|
2915
2915
|
}, ve({
|
|
2916
2916
|
label: y(() => [
|
|
2917
2917
|
J(w.$slots, `${Q.key}-label`, { row: Q }, void 0, !0)
|
|
2918
2918
|
]),
|
|
2919
|
-
[Q.key]: y(({ rowValue:
|
|
2919
|
+
[Q.key]: y(({ rowValue: le }) => [
|
|
2920
2920
|
J(w.$slots, Q.key, {
|
|
2921
2921
|
row: Q,
|
|
2922
|
-
rowValue:
|
|
2922
|
+
rowValue: le
|
|
2923
2923
|
}, void 0, !0)
|
|
2924
2924
|
]),
|
|
2925
2925
|
_: 2
|
|
@@ -2932,7 +2932,7 @@ const Ri = {
|
|
|
2932
2932
|
key: "0"
|
|
2933
2933
|
} : void 0
|
|
2934
2934
|
]), 1032, ["item"]))), 128))
|
|
2935
|
-
], 10,
|
|
2935
|
+
], 10, ls))), 128))
|
|
2936
2936
|
]))
|
|
2937
2937
|
]),
|
|
2938
2938
|
_: 2
|
|
@@ -2940,7 +2940,7 @@ const Ri = {
|
|
|
2940
2940
|
e.hideTitle ? void 0 : {
|
|
2941
2941
|
name: "title",
|
|
2942
2942
|
fn: y(() => [
|
|
2943
|
-
B("div",
|
|
2943
|
+
B("div", as, [
|
|
2944
2944
|
J(w.$slots, "title", {}, () => [
|
|
2945
2945
|
W(M(m(r)("baseConfigCard.title")), 1)
|
|
2946
2946
|
], !0)
|
|
@@ -2951,10 +2951,10 @@ const Ri = {
|
|
|
2951
2951
|
]), 1024);
|
|
2952
2952
|
};
|
|
2953
2953
|
}
|
|
2954
|
-
}),
|
|
2954
|
+
}), ds = /* @__PURE__ */ me(cs, [["__scopeId", "data-v-64349aa2"]]), ps = ["onReset", "onSubmit"], fs = {
|
|
2955
2955
|
class: "form-actions",
|
|
2956
2956
|
"data-testid": "form-actions"
|
|
2957
|
-
},
|
|
2957
|
+
}, ms = /* @__PURE__ */ te({
|
|
2958
2958
|
__name: "EntityBaseForm",
|
|
2959
2959
|
props: {
|
|
2960
2960
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3004,7 +3004,7 @@ const Ri = {
|
|
|
3004
3004
|
emits: ["loading", "fetch:success", "fetch:error", "submit", "cancel"],
|
|
3005
3005
|
setup(e, { emit: n }) {
|
|
3006
3006
|
var t;
|
|
3007
|
-
const a = e, o =
|
|
3007
|
+
const a = e, o = gt(), { i18n: { t: r } } = oe.useI18n(), { getMessageFromError: i } = oe.useErrors(), { axiosInstance: s } = oe.useAxios({
|
|
3008
3008
|
headers: (t = a.config) == null ? void 0 : t.requestHeaders
|
|
3009
3009
|
}), l = F(!1), c = F(!1), d = F(""), u = j(() => a.canSubmit === !1 || a.isReadonly), h = j(() => {
|
|
3010
3010
|
var p, b;
|
|
@@ -3035,12 +3035,12 @@ const Ri = {
|
|
|
3035
3035
|
}
|
|
3036
3036
|
}), (p, b) => {
|
|
3037
3037
|
const v = q("KSkeleton"), A = q("KEmptyState"), V = q("KAlert"), _ = q("KButton"), E = q("KCard");
|
|
3038
|
-
return f(),
|
|
3038
|
+
return f(), U(E, { class: "kong-ui-entity-base-form" }, {
|
|
3039
3039
|
body: y(() => [
|
|
3040
|
-
l.value ? (f(),
|
|
3040
|
+
l.value ? (f(), U(v, {
|
|
3041
3041
|
key: 0,
|
|
3042
3042
|
type: "form"
|
|
3043
|
-
})) : c.value ? (f(),
|
|
3043
|
+
})) : c.value ? (f(), U(A, {
|
|
3044
3044
|
key: 1,
|
|
3045
3045
|
"cta-text": m(r)("baseForm.actions.back"),
|
|
3046
3046
|
"data-testid": "form-fetch-error",
|
|
@@ -3058,13 +3058,13 @@ const Ri = {
|
|
|
3058
3058
|
onSubmit: Ge(k, ["prevent"])
|
|
3059
3059
|
}, [
|
|
3060
3060
|
J(p.$slots, "default", {}, void 0, !0),
|
|
3061
|
-
e.errorMessage ? (f(),
|
|
3061
|
+
e.errorMessage ? (f(), U(V, {
|
|
3062
3062
|
key: 0,
|
|
3063
3063
|
"alert-message": e.errorMessage,
|
|
3064
3064
|
appearance: "danger",
|
|
3065
3065
|
"data-testid": "form-error"
|
|
3066
3066
|
}, null, 8, ["alert-message"])) : G("", !0),
|
|
3067
|
-
B("div",
|
|
3067
|
+
B("div", fs, [
|
|
3068
3068
|
J(p.$slots, "form-actions", {}, () => [
|
|
3069
3069
|
O(_, {
|
|
3070
3070
|
appearance: "outline",
|
|
@@ -3090,13 +3090,13 @@ const Ri = {
|
|
|
3090
3090
|
}, 8, ["disabled"])
|
|
3091
3091
|
], !0)
|
|
3092
3092
|
])
|
|
3093
|
-
], 40,
|
|
3093
|
+
], 40, ps))
|
|
3094
3094
|
]),
|
|
3095
3095
|
_: 3
|
|
3096
3096
|
});
|
|
3097
3097
|
};
|
|
3098
3098
|
}
|
|
3099
|
-
}),
|
|
3099
|
+
}), gs = /* @__PURE__ */ me(ms, [["__scopeId", "data-v-44a90aae"]]), ys = { key: 0 }, hs = /* @__PURE__ */ te({
|
|
3100
3100
|
__name: "EntityBaseTableCell",
|
|
3101
3101
|
props: {
|
|
3102
3102
|
keyName: {
|
|
@@ -3141,9 +3141,9 @@ const Ri = {
|
|
|
3141
3141
|
},
|
|
3142
3142
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
3143
3143
|
), C = j(() => o.value ? c.value > d.value : !1);
|
|
3144
|
-
return
|
|
3144
|
+
return ca(() => {
|
|
3145
3145
|
s();
|
|
3146
|
-
}),
|
|
3146
|
+
}), da(() => {
|
|
3147
3147
|
g();
|
|
3148
3148
|
}), (k, p) => {
|
|
3149
3149
|
const b = q("KTooltip");
|
|
@@ -3152,7 +3152,7 @@ const Ri = {
|
|
|
3152
3152
|
ref: l,
|
|
3153
3153
|
class: "content-wrapper"
|
|
3154
3154
|
}, [
|
|
3155
|
-
o.value ? (f(), x("span",
|
|
3155
|
+
o.value ? (f(), x("span", ys, [
|
|
3156
3156
|
O(b, {
|
|
3157
3157
|
disabled: !C.value,
|
|
3158
3158
|
label: u.value,
|
|
@@ -3168,10 +3168,10 @@ const Ri = {
|
|
|
3168
3168
|
], 512);
|
|
3169
3169
|
};
|
|
3170
3170
|
}
|
|
3171
|
-
}),
|
|
3171
|
+
}), vs = /* @__PURE__ */ me(hs, [["__scopeId", "data-v-f8a220e9"]]), bs = { class: "toolbar-container" }, Cs = {
|
|
3172
3172
|
key: 0,
|
|
3173
3173
|
class: "toolbar-button-container"
|
|
3174
|
-
},
|
|
3174
|
+
}, ks = ["data-testid"], ws = /* @__PURE__ */ te({
|
|
3175
3175
|
__name: "EntityBaseTable",
|
|
3176
3176
|
props: {
|
|
3177
3177
|
// table header configuration
|
|
@@ -3313,7 +3313,7 @@ const Ri = {
|
|
|
3313
3313
|
n("click:row", V);
|
|
3314
3314
|
}, C = (A) => {
|
|
3315
3315
|
n("sort", A);
|
|
3316
|
-
}, { setTablePreferences: k, getTablePreferences: p } =
|
|
3316
|
+
}, { setTablePreferences: k, getTablePreferences: p } = _a(), b = j(() => {
|
|
3317
3317
|
const A = p(t.preferencesStorageKey);
|
|
3318
3318
|
return {
|
|
3319
3319
|
...t.initialFetcherParams,
|
|
@@ -3324,7 +3324,7 @@ const Ri = {
|
|
|
3324
3324
|
};
|
|
3325
3325
|
return (A, V) => {
|
|
3326
3326
|
const _ = q("KIcon"), E = q("KButton"), P = q("KDropdownMenu"), w = q("KTable"), I = q("KCard");
|
|
3327
|
-
return f(),
|
|
3327
|
+
return f(), U(I, {
|
|
3328
3328
|
class: "kong-ui-entity-base-table",
|
|
3329
3329
|
title: e.title
|
|
3330
3330
|
}, {
|
|
@@ -3361,16 +3361,16 @@ const Ri = {
|
|
|
3361
3361
|
"onUpdate:tablePreferences": v
|
|
3362
3362
|
}, ve({
|
|
3363
3363
|
toolbar: y(({ state: L }) => [
|
|
3364
|
-
Ve(B("div",
|
|
3364
|
+
Ve(B("div", bs, [
|
|
3365
3365
|
J(A.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3366
|
-
A.$slots["toolbar-button"] ? (f(), x("div",
|
|
3366
|
+
A.$slots["toolbar-button"] ? (f(), x("div", Cs, [
|
|
3367
3367
|
J(A.$slots, "toolbar-button", {}, void 0, !0)
|
|
3368
3368
|
])) : G("", !0)
|
|
3369
3369
|
], 512), [
|
|
3370
3370
|
[De, r(L)]
|
|
3371
3371
|
])
|
|
3372
3372
|
]),
|
|
3373
|
-
actions: y(({ row: L, rowKey:
|
|
3373
|
+
actions: y(({ row: L, rowKey: D, rowValue: S }) => [
|
|
3374
3374
|
B("div", {
|
|
3375
3375
|
class: "actions-container",
|
|
3376
3376
|
"data-testid": L.name
|
|
@@ -3382,7 +3382,7 @@ const Ri = {
|
|
|
3382
3382
|
items: y(() => [
|
|
3383
3383
|
J(A.$slots, "actions", {
|
|
3384
3384
|
row: L,
|
|
3385
|
-
rowKey:
|
|
3385
|
+
rowKey: D,
|
|
3386
3386
|
rowValue: S
|
|
3387
3387
|
}, void 0, !0)
|
|
3388
3388
|
]),
|
|
@@ -3394,7 +3394,7 @@ const Ri = {
|
|
|
3394
3394
|
}, {
|
|
3395
3395
|
icon: y(() => [
|
|
3396
3396
|
O(_, {
|
|
3397
|
-
color: m(
|
|
3397
|
+
color: m(io),
|
|
3398
3398
|
icon: "more",
|
|
3399
3399
|
size: "16"
|
|
3400
3400
|
}, null, 8, ["color"])
|
|
@@ -3404,19 +3404,19 @@ const Ri = {
|
|
|
3404
3404
|
]),
|
|
3405
3405
|
_: 2
|
|
3406
3406
|
}, 1032, ["width"])
|
|
3407
|
-
], 8,
|
|
3407
|
+
], 8, ks)
|
|
3408
3408
|
]),
|
|
3409
3409
|
_: 2
|
|
3410
3410
|
}, [
|
|
3411
|
-
ce(e.tableHeaders, (L,
|
|
3412
|
-
name:
|
|
3411
|
+
ce(e.tableHeaders, (L, D) => ({
|
|
3412
|
+
name: D,
|
|
3413
3413
|
fn: y(({ row: S, rowKey: K, rowValue: N }) => [
|
|
3414
|
-
O(
|
|
3415
|
-
"key-name": String(
|
|
3414
|
+
O(vs, {
|
|
3415
|
+
"key-name": String(D),
|
|
3416
3416
|
"row-el": c(S)
|
|
3417
3417
|
}, {
|
|
3418
3418
|
default: y(() => [
|
|
3419
|
-
J(A.$slots,
|
|
3419
|
+
J(A.$slots, D, {
|
|
3420
3420
|
row: S,
|
|
3421
3421
|
rowKey: K,
|
|
3422
3422
|
rowValue: N
|
|
@@ -3434,13 +3434,13 @@ const Ri = {
|
|
|
3434
3434
|
}, 8, ["title"]);
|
|
3435
3435
|
};
|
|
3436
3436
|
}
|
|
3437
|
-
}),
|
|
3437
|
+
}), _s = /* @__PURE__ */ me(ws, [["__scopeId", "data-v-2622d034"]]), Is = {
|
|
3438
3438
|
key: 0,
|
|
3439
3439
|
class: "kong-ui-entity-delete-error"
|
|
3440
|
-
},
|
|
3440
|
+
}, As = {
|
|
3441
3441
|
key: 1,
|
|
3442
3442
|
class: "description"
|
|
3443
|
-
},
|
|
3443
|
+
}, Ss = /* @__PURE__ */ te({
|
|
3444
3444
|
__name: "EntityDeleteModal",
|
|
3445
3445
|
props: {
|
|
3446
3446
|
visible: {
|
|
@@ -3486,7 +3486,7 @@ const Ri = {
|
|
|
3486
3486
|
};
|
|
3487
3487
|
return (s, l) => {
|
|
3488
3488
|
const c = q("KAlert"), d = q("KPrompt");
|
|
3489
|
-
return f(),
|
|
3489
|
+
return f(), U(d, {
|
|
3490
3490
|
"action-button-text": "Yes, delete",
|
|
3491
3491
|
"action-pending": e.actionPending,
|
|
3492
3492
|
class: "kong-ui-entity-delete-modal",
|
|
@@ -3498,7 +3498,7 @@ const Ri = {
|
|
|
3498
3498
|
onProceed: i
|
|
3499
3499
|
}, {
|
|
3500
3500
|
"body-content": y(() => [
|
|
3501
|
-
e.error ? (f(), x("div",
|
|
3501
|
+
e.error ? (f(), x("div", Is, [
|
|
3502
3502
|
O(c, { appearance: "danger" }, {
|
|
3503
3503
|
alertMessage: y(() => [
|
|
3504
3504
|
W(M(e.error), 1)
|
|
@@ -3524,7 +3524,7 @@ const Ri = {
|
|
|
3524
3524
|
key: "0"
|
|
3525
3525
|
} : void 0
|
|
3526
3526
|
]), 1032, ["keypath"]),
|
|
3527
|
-
t.description || s.$slots.description ? (f(), x("div",
|
|
3527
|
+
t.description || s.$slots.description ? (f(), x("div", As, [
|
|
3528
3528
|
J(s.$slots, "description", {}, () => [
|
|
3529
3529
|
B("p", null, M(t.description), 1)
|
|
3530
3530
|
], !0)
|
|
@@ -3534,13 +3534,13 @@ const Ri = {
|
|
|
3534
3534
|
}, 8, ["action-pending", "confirmation-text", "is-visible", "title"]);
|
|
3535
3535
|
};
|
|
3536
3536
|
}
|
|
3537
|
-
}),
|
|
3537
|
+
}), xs = /* @__PURE__ */ me(Ss, [["__scopeId", "data-v-1c9a2a07"]]), Ts = {
|
|
3538
3538
|
fill: "none",
|
|
3539
3539
|
height: "20",
|
|
3540
3540
|
viewBox: "0 0 20 20",
|
|
3541
3541
|
width: "20",
|
|
3542
3542
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3543
|
-
},
|
|
3543
|
+
}, $s = {
|
|
3544
3544
|
id: "mask0_180_20349",
|
|
3545
3545
|
height: "20",
|
|
3546
3546
|
maskUnits: "userSpaceOnUse",
|
|
@@ -3548,35 +3548,35 @@ const Ri = {
|
|
|
3548
3548
|
width: "20",
|
|
3549
3549
|
x: "0",
|
|
3550
3550
|
y: "0"
|
|
3551
|
-
},
|
|
3551
|
+
}, Ms = ["fill"], Os = { mask: "url(#mask0_180_20349)" }, js = ["fill"], Es = /* @__PURE__ */ te({
|
|
3552
3552
|
__name: "IconFilter",
|
|
3553
3553
|
props: {
|
|
3554
3554
|
color: {
|
|
3555
3555
|
type: String,
|
|
3556
|
-
default: `var(--kong-ui-entity-filter-color, ${
|
|
3556
|
+
default: `var(--kong-ui-entity-filter-color, ${oo})`
|
|
3557
3557
|
}
|
|
3558
3558
|
},
|
|
3559
3559
|
setup(e) {
|
|
3560
|
-
return (n, t) => (f(), x("svg",
|
|
3561
|
-
B("mask",
|
|
3560
|
+
return (n, t) => (f(), x("svg", Ts, [
|
|
3561
|
+
B("mask", $s, [
|
|
3562
3562
|
B("rect", {
|
|
3563
3563
|
fill: e.color,
|
|
3564
3564
|
height: "20",
|
|
3565
3565
|
width: "20"
|
|
3566
|
-
}, null, 8,
|
|
3566
|
+
}, null, 8, Ms)
|
|
3567
3567
|
]),
|
|
3568
|
-
B("g",
|
|
3568
|
+
B("g", Os, [
|
|
3569
3569
|
B("path", {
|
|
3570
3570
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3571
3571
|
fill: e.color
|
|
3572
|
-
}, null, 8,
|
|
3572
|
+
}, null, 8, js)
|
|
3573
3573
|
])
|
|
3574
3574
|
]));
|
|
3575
3575
|
}
|
|
3576
|
-
}),
|
|
3576
|
+
}), Fs = {
|
|
3577
3577
|
key: 1,
|
|
3578
3578
|
class: "kong-ui-entity-filter"
|
|
3579
|
-
},
|
|
3579
|
+
}, Bs = { class: "menu-item-title" }, Ks = { class: "menu-item-indicator" }, Ns = { class: "menu-item-body" }, qs = ["for"], Ls = { class: "menu-item-buttons" }, Ps = /* @__PURE__ */ te({
|
|
3580
3580
|
__name: "EntityFilter",
|
|
3581
3581
|
props: {
|
|
3582
3582
|
// filter config, either exact match or fuzzy match
|
|
@@ -3639,7 +3639,7 @@ const Ri = {
|
|
|
3639
3639
|
};
|
|
3640
3640
|
return (p, b) => {
|
|
3641
3641
|
const v = q("KInput"), A = q("KButton"), V = q("KSelect"), _ = q("KMenuItem"), E = q("KMenu");
|
|
3642
|
-
return e.config.isExactMatch ? (f(),
|
|
3642
|
+
return e.config.isExactMatch ? (f(), U(v, {
|
|
3643
3643
|
key: 0,
|
|
3644
3644
|
autocomplete: "off",
|
|
3645
3645
|
class: "kong-ui-entity-filter-input",
|
|
@@ -3649,10 +3649,10 @@ const Ri = {
|
|
|
3649
3649
|
"onUpdate:modelValue": c
|
|
3650
3650
|
}, {
|
|
3651
3651
|
icon: y(() => [
|
|
3652
|
-
O(
|
|
3652
|
+
O(Es)
|
|
3653
3653
|
]),
|
|
3654
3654
|
_: 1
|
|
3655
|
-
}, 8, ["model-value", "placeholder"])) : (f(), x("div",
|
|
3655
|
+
}, 8, ["model-value", "placeholder"])) : (f(), x("div", Fs, [
|
|
3656
3656
|
O(A, {
|
|
3657
3657
|
appearance: "btn-link",
|
|
3658
3658
|
"data-testid": "filter-button",
|
|
@@ -3672,16 +3672,16 @@ const Ri = {
|
|
|
3672
3672
|
]),
|
|
3673
3673
|
Ve(O(E, { class: "kong-ui-entity-filter-menu" }, {
|
|
3674
3674
|
body: y(() => [
|
|
3675
|
-
(f(!0), x(pe, null, ce(s.value, (P, w) => (f(),
|
|
3675
|
+
(f(!0), x(pe, null, ce(s.value, (P, w) => (f(), U(_, {
|
|
3676
3676
|
key: P.value,
|
|
3677
3677
|
"data-testid": P.value,
|
|
3678
3678
|
expandable: "",
|
|
3679
3679
|
"last-menu-item": w === s.value.length - 1
|
|
3680
3680
|
}, {
|
|
3681
3681
|
itemTitle: y(() => [
|
|
3682
|
-
B("span",
|
|
3682
|
+
B("span", Bs, [
|
|
3683
3683
|
W(M(P.label) + " ", 1),
|
|
3684
|
-
Ve(B("span",
|
|
3684
|
+
Ve(B("span", Ks, null, 512), [
|
|
3685
3685
|
[De, i.value.includes(P.value)]
|
|
3686
3686
|
])
|
|
3687
3687
|
])
|
|
@@ -3689,36 +3689,36 @@ const Ri = {
|
|
|
3689
3689
|
itemBody: y(() => {
|
|
3690
3690
|
var I, L;
|
|
3691
3691
|
return [
|
|
3692
|
-
B("div",
|
|
3692
|
+
B("div", Ns, [
|
|
3693
3693
|
B("label", {
|
|
3694
3694
|
class: "menu-item-label",
|
|
3695
3695
|
for: d(P.value)
|
|
3696
|
-
}, M(m(a)("filter.fieldLabel")), 9,
|
|
3697
|
-
((L = (I = e.config.schema) == null ? void 0 : I[P.value]) == null ? void 0 : L.type) === "select" ? (f(),
|
|
3696
|
+
}, M(m(a)("filter.fieldLabel")), 9, qs),
|
|
3697
|
+
((L = (I = e.config.schema) == null ? void 0 : I[P.value]) == null ? void 0 : L.type) === "select" ? (f(), U(V, {
|
|
3698
3698
|
key: 0,
|
|
3699
3699
|
id: d(P.value),
|
|
3700
3700
|
modelValue: r.value[P.value],
|
|
3701
|
-
"onUpdate:modelValue": (
|
|
3701
|
+
"onUpdate:modelValue": (D) => r.value[P.value] = D,
|
|
3702
3702
|
appearance: "select",
|
|
3703
3703
|
items: u(P.value),
|
|
3704
3704
|
placeholder: m(a)("filter.selectPlaceholder")
|
|
3705
|
-
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (f(),
|
|
3705
|
+
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "items", "placeholder"])) : (f(), U(v, {
|
|
3706
3706
|
key: 1,
|
|
3707
3707
|
id: d(P.value),
|
|
3708
3708
|
modelValue: r.value[P.value],
|
|
3709
|
-
"onUpdate:modelValue": (
|
|
3709
|
+
"onUpdate:modelValue": (D) => r.value[P.value] = D,
|
|
3710
3710
|
autocomplete: "off",
|
|
3711
3711
|
placeholder: m(a)("filter.inputPlaceholder"),
|
|
3712
3712
|
size: "small",
|
|
3713
3713
|
type: h(P.value)
|
|
3714
3714
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
3715
3715
|
]),
|
|
3716
|
-
B("div",
|
|
3716
|
+
B("div", Ls, [
|
|
3717
3717
|
O(A, {
|
|
3718
3718
|
appearance: "btn-link",
|
|
3719
3719
|
"data-testid": "apply-filter",
|
|
3720
3720
|
size: "small",
|
|
3721
|
-
onClick: b[0] || (b[0] = (
|
|
3721
|
+
onClick: b[0] || (b[0] = (D) => k(!0))
|
|
3722
3722
|
}, {
|
|
3723
3723
|
default: y(() => [
|
|
3724
3724
|
W(M(m(a)("filter.applyButtonText")), 1)
|
|
@@ -3729,7 +3729,7 @@ const Ri = {
|
|
|
3729
3729
|
appearance: "btn-link",
|
|
3730
3730
|
"data-testid": "clear-filter",
|
|
3731
3731
|
size: "small",
|
|
3732
|
-
onClick: (
|
|
3732
|
+
onClick: (D) => g(P.value)
|
|
3733
3733
|
}, {
|
|
3734
3734
|
default: y(() => [
|
|
3735
3735
|
W(M(m(a)("filter.clearButtonText")), 1)
|
|
@@ -3757,7 +3757,7 @@ const Ri = {
|
|
|
3757
3757
|
]));
|
|
3758
3758
|
};
|
|
3759
3759
|
}
|
|
3760
|
-
}),
|
|
3760
|
+
}), Us = /* @__PURE__ */ me(Ps, [["__scopeId", "data-v-745f38c0"]]), Re = /* @__PURE__ */ te({
|
|
3761
3761
|
__name: "PermissionsWrapper",
|
|
3762
3762
|
props: {
|
|
3763
3763
|
/**
|
|
@@ -3787,16 +3787,16 @@ const Ri = {
|
|
|
3787
3787
|
isAllowed: t.value
|
|
3788
3788
|
}) : G("", !0);
|
|
3789
3789
|
}
|
|
3790
|
-
}),
|
|
3790
|
+
}), Rs = { class: "form-section-wrapper" }, Vs = {
|
|
3791
3791
|
key: 0,
|
|
3792
3792
|
class: "form-section-title"
|
|
3793
|
-
},
|
|
3793
|
+
}, Ds = {
|
|
3794
3794
|
key: 1,
|
|
3795
3795
|
class: "form-section-description"
|
|
3796
|
-
},
|
|
3796
|
+
}, Gs = {
|
|
3797
3797
|
key: 2,
|
|
3798
3798
|
class: "form-section-footer"
|
|
3799
|
-
},
|
|
3799
|
+
}, Hs = { class: "form-section-content" }, Ys = /* @__PURE__ */ te({
|
|
3800
3800
|
__name: "EntityFormSection",
|
|
3801
3801
|
props: {
|
|
3802
3802
|
title: {
|
|
@@ -3825,35 +3825,35 @@ const Ri = {
|
|
|
3825
3825
|
return (t, a) => (f(), x("fieldset", {
|
|
3826
3826
|
class: Ae(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }])
|
|
3827
3827
|
}, [
|
|
3828
|
-
B("div",
|
|
3828
|
+
B("div", Rs, [
|
|
3829
3829
|
e.hideInfoHeader ? G("", !0) : (f(), x("div", {
|
|
3830
3830
|
key: 0,
|
|
3831
3831
|
class: Ae(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
3832
3832
|
}, [
|
|
3833
|
-
e.title ? (f(), x("h4",
|
|
3834
|
-
e.description || m(n).description ? (f(), x("div",
|
|
3833
|
+
e.title ? (f(), x("h4", Vs, M(e.title), 1)) : G("", !0),
|
|
3834
|
+
e.description || m(n).description ? (f(), x("div", Ds, [
|
|
3835
3835
|
J(t.$slots, "description", {}, () => [
|
|
3836
3836
|
B("p", null, M(e.description), 1)
|
|
3837
3837
|
], !0)
|
|
3838
3838
|
])) : G("", !0),
|
|
3839
|
-
m(n).footer ? (f(), x("div",
|
|
3839
|
+
m(n).footer ? (f(), x("div", Gs, [
|
|
3840
3840
|
J(t.$slots, "footer", {}, void 0, !0)
|
|
3841
3841
|
])) : G("", !0)
|
|
3842
3842
|
], 2)),
|
|
3843
|
-
B("div",
|
|
3843
|
+
B("div", Hs, [
|
|
3844
3844
|
J(t.$slots, "default", {}, void 0, !0)
|
|
3845
3845
|
])
|
|
3846
3846
|
])
|
|
3847
3847
|
], 2));
|
|
3848
3848
|
}
|
|
3849
|
-
}),
|
|
3850
|
-
const
|
|
3849
|
+
}), zs = /* @__PURE__ */ me(Ys, [["__scopeId", "data-v-8b6dc312"]]), { useAxios: St, useDeleteUrlBuilder: Js, useErrors: Ws, useFetchUrlBuilder: Cl, useFetcher: Zs, useDebouncedFilter: Qs, useStringHelpers: kl, useHelpers: wl, useGatewayFeatureSupported: _l } = oe;
|
|
3850
|
+
const Xs = { class: "add-consumer-form-container" }, el = { class: "add-consumer-form-cta" }, tl = { class: "select-item-label" }, nl = {
|
|
3851
3851
|
key: 0,
|
|
3852
3852
|
class: "select-item-desc"
|
|
3853
|
-
},
|
|
3853
|
+
}, al = {
|
|
3854
3854
|
key: 0,
|
|
3855
3855
|
class: "kong-ui-entity-add-consumers-error"
|
|
3856
|
-
},
|
|
3856
|
+
}, ol = { key: 0 }, rl = /* @__PURE__ */ te({
|
|
3857
3857
|
__name: "AddConsumerModal",
|
|
3858
3858
|
props: {
|
|
3859
3859
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3870,9 +3870,9 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3870
3870
|
},
|
|
3871
3871
|
emits: ["cancel", "add:success", "add:partial-success", "error"],
|
|
3872
3872
|
setup(e, { emit: n }) {
|
|
3873
|
-
var
|
|
3874
|
-
const t = e, { i18n: { t: a } } = Xe.useI18n(), { axiosInstance: o } =
|
|
3875
|
-
headers: (
|
|
3873
|
+
var D;
|
|
3874
|
+
const t = e, { i18n: { t: a } } = Xe.useI18n(), { axiosInstance: o } = St({
|
|
3875
|
+
headers: (D = t.config) == null ? void 0 : D.requestHeaders
|
|
3876
3876
|
}), r = F([]), {
|
|
3877
3877
|
debouncedQueryChange: i,
|
|
3878
3878
|
loading: s,
|
|
@@ -3880,7 +3880,7 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3880
3880
|
error: c,
|
|
3881
3881
|
loadItems: d,
|
|
3882
3882
|
results: u
|
|
3883
|
-
} =
|
|
3883
|
+
} = Qs(
|
|
3884
3884
|
t.config,
|
|
3885
3885
|
Se.list[t.config.app].all,
|
|
3886
3886
|
"",
|
|
@@ -3896,7 +3896,7 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3896
3896
|
// we need this to determine whether or not to show the description text
|
|
3897
3897
|
}))), b = (S) => {
|
|
3898
3898
|
var N;
|
|
3899
|
-
const K = k.value ? u.value.find((
|
|
3899
|
+
const K = k.value ? u.value.find((R) => R.id === S) : (N = l.value) == null ? void 0 : N.find((R) => R.id === S);
|
|
3900
3900
|
return K ? K.username || K.custom_id : S;
|
|
3901
3901
|
}, v = () => {
|
|
3902
3902
|
_.value = "", A.value = [], I.value = [], n("cancel");
|
|
@@ -3907,10 +3907,10 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3907
3907
|
}
|
|
3908
3908
|
V.value = !0, _.value = "", A.value = [], I.value = [];
|
|
3909
3909
|
try {
|
|
3910
|
-
const S = r.value.map((
|
|
3910
|
+
const S = r.value.map((R) => w(R)), K = await Promise.allSettled(S);
|
|
3911
3911
|
let N = !0;
|
|
3912
|
-
K.forEach((
|
|
3913
|
-
|
|
3912
|
+
K.forEach((R) => {
|
|
3913
|
+
R.status !== "fulfilled" && (N = !1);
|
|
3914
3914
|
}), N ? (A.value = [], I.value = [], n("add:success", r.value), r.value = []) : (A.value.length && n("add:partial-success", A.value), r.value = [], L(K));
|
|
3915
3915
|
} catch {
|
|
3916
3916
|
_.value = a("consumers.errors.add"), n("error", _.value);
|
|
@@ -3918,9 +3918,9 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3918
3918
|
V.value = !1;
|
|
3919
3919
|
}
|
|
3920
3920
|
}, P = j(() => {
|
|
3921
|
-
var K, N,
|
|
3921
|
+
var K, N, R, Z;
|
|
3922
3922
|
let S = `${t.config.apiBaseUrl}${Se.list[t.config.app].forConsumerGroup}`;
|
|
3923
|
-
return t.config.app === "konnect" ? S = S.replace(/{controlPlaneId}/gi, ((K = t.config) == null ? void 0 : K.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((N = t.config) == null ? void 0 : N.consumerGroupId) || "") : t.config.app === "kongManager" && (S = S.replace(/\/{workspace}/gi, (
|
|
3923
|
+
return t.config.app === "konnect" ? S = S.replace(/{controlPlaneId}/gi, ((K = t.config) == null ? void 0 : K.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((N = t.config) == null ? void 0 : N.consumerGroupId) || "") : t.config.app === "kongManager" && (S = S.replace(/\/{workspace}/gi, (R = t.config) != null && R.workspace ? `/${t.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((Z = t.config) == null ? void 0 : Z.consumerGroupId) || "")), S;
|
|
3924
3924
|
}), w = async (S) => {
|
|
3925
3925
|
const K = {
|
|
3926
3926
|
consumer: S
|
|
@@ -3929,8 +3929,8 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3929
3929
|
const N = await o.post(P.value, K);
|
|
3930
3930
|
return A.value.push(S), N;
|
|
3931
3931
|
} catch (N) {
|
|
3932
|
-
let
|
|
3933
|
-
return N.response.status === 409 && (
|
|
3932
|
+
let R = `${b(S)} - ${N.message}`;
|
|
3933
|
+
return N.response.status === 409 && (R = `${b(S)} - ${a("consumers.errors.already_added")}`), Promise.reject(Error(R));
|
|
3934
3934
|
}
|
|
3935
3935
|
}, I = F([]), L = (S) => {
|
|
3936
3936
|
I.value = S.map((K) => {
|
|
@@ -3943,8 +3943,8 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3943
3943
|
}, { immediate: !0, deep: !0 }), Qe(async () => {
|
|
3944
3944
|
await d();
|
|
3945
3945
|
}), (S, K) => {
|
|
3946
|
-
const N = q("KMultiselect"),
|
|
3947
|
-
return f(),
|
|
3946
|
+
const N = q("KMultiselect"), R = q("KAlert"), Z = q("KPrompt");
|
|
3947
|
+
return f(), U(Z, {
|
|
3948
3948
|
"action-pending": V.value,
|
|
3949
3949
|
class: "kong-ui-entities-add-consumers-modal",
|
|
3950
3950
|
"data-testid": "add-consumer-modal",
|
|
@@ -3954,8 +3954,8 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3954
3954
|
onProceed: E
|
|
3955
3955
|
}, {
|
|
3956
3956
|
"body-content": y(() => [
|
|
3957
|
-
B("div",
|
|
3958
|
-
B("p",
|
|
3957
|
+
B("div", Xs, [
|
|
3958
|
+
B("p", el, M(m(a)("consumers.consumer_groups.add.ctaText")), 1),
|
|
3959
3959
|
O(N, {
|
|
3960
3960
|
modelValue: r.value,
|
|
3961
3961
|
"onUpdate:modelValue": K[0] || (K[0] = (H) => r.value = H),
|
|
@@ -3972,16 +3972,16 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3972
3972
|
onQueryChange: m(i)
|
|
3973
3973
|
}, {
|
|
3974
3974
|
"item-template": y(({ item: H }) => [
|
|
3975
|
-
B("div",
|
|
3976
|
-
h(H).data.username && h(H).data.custom_id ? (f(), x("div",
|
|
3975
|
+
B("div", tl, M(H.label), 1),
|
|
3976
|
+
h(H).data.username && h(H).data.custom_id ? (f(), x("div", nl, M(h(H).data.custom_id), 1)) : G("", !0)
|
|
3977
3977
|
]),
|
|
3978
3978
|
_: 1
|
|
3979
3979
|
}, 8, ["modelValue", "dropdown-footer-text", "items", "label", "loading", "placeholder", "readonly", "onQueryChange"]),
|
|
3980
|
-
_.value || g.value || I.value.length ? (f(), x("div",
|
|
3981
|
-
O(
|
|
3980
|
+
_.value || g.value || I.value.length ? (f(), x("div", al, [
|
|
3981
|
+
O(R, { appearance: "danger" }, {
|
|
3982
3982
|
alertMessage: y(() => [
|
|
3983
3983
|
B("p", null, M(m(a)("consumers.errors.add")), 1),
|
|
3984
|
-
I.value.length ? (f(), x("ul",
|
|
3984
|
+
I.value.length ? (f(), x("ul", ol, [
|
|
3985
3985
|
(f(!0), x(pe, null, ce(I.value, (H, Q) => (f(), x("li", { key: Q }, M(H), 1))), 128))
|
|
3986
3986
|
])) : G("", !0),
|
|
3987
3987
|
B("div", null, M(_.value || g.value), 1)
|
|
@@ -3996,12 +3996,12 @@ const Qs = { class: "add-consumer-form-container" }, Xs = { class: "add-consumer
|
|
|
3996
3996
|
};
|
|
3997
3997
|
}
|
|
3998
3998
|
});
|
|
3999
|
-
const
|
|
3999
|
+
const xt = (e, n) => {
|
|
4000
4000
|
const t = e.__vccOpts || e;
|
|
4001
4001
|
for (const [a, o] of n)
|
|
4002
4002
|
t[a] = o;
|
|
4003
4003
|
return t;
|
|
4004
|
-
},
|
|
4004
|
+
}, il = /* @__PURE__ */ xt(rl, [["__scopeId", "data-v-86f09821"]]), sl = { class: "kong-ui-entities-consumers-list" }, ll = { key: 1 }, ul = /* @__PURE__ */ te({
|
|
4005
4005
|
__name: "ConsumerList",
|
|
4006
4006
|
props: {
|
|
4007
4007
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4042,9 +4042,9 @@ const St = (e, n) => {
|
|
|
4042
4042
|
},
|
|
4043
4043
|
emits: ["error", "copy:success", "copy:error", "delete:success", "add:success", "remove:success"],
|
|
4044
4044
|
setup(e, { emit: n }) {
|
|
4045
|
-
var
|
|
4046
|
-
const t = e, { i18nT: a, i18n: { t: o } } = Xe.useI18n(), r =
|
|
4047
|
-
headers: (
|
|
4045
|
+
var Et;
|
|
4046
|
+
const t = e, { i18nT: a, i18n: { t: o } } = Xe.useI18n(), r = gt(), { axiosInstance: i } = St({
|
|
4047
|
+
headers: (Et = t.config) == null ? void 0 : Et.requestHeaders
|
|
4048
4048
|
}), s = F(1), l = j(() => !!t.config.consumerGroupId), c = j(() => t.config.app !== "kongManager" || !!t.config.disableSorting), d = {
|
|
4049
4049
|
username: { label: o("consumers.list.table_headers.username"), searchable: !0, sortable: !0 },
|
|
4050
4050
|
custom_id: { label: o("consumers.list.table_headers.custom_id"), searchable: !0, sortable: !0 },
|
|
@@ -4068,11 +4068,11 @@ const St = (e, n) => {
|
|
|
4068
4068
|
},
|
|
4069
4069
|
schema: t.config.filterSchema
|
|
4070
4070
|
};
|
|
4071
|
-
}), { fetcher:
|
|
4071
|
+
}), p = j(() => l.value ? "consumers" : void 0), { fetcher: b, fetcherState: v } = Zs(t.config, g.value, p.value), A = () => {
|
|
4072
4072
|
C.value = "";
|
|
4073
|
-
},
|
|
4073
|
+
}, V = () => {
|
|
4074
4074
|
s.value++;
|
|
4075
|
-
},
|
|
4075
|
+
}, _ = ($) => $ ?? "-", E = F(""), P = ($, Y) => {
|
|
4076
4076
|
const ae = $.id;
|
|
4077
4077
|
if (!Y(ae)) {
|
|
4078
4078
|
n("copy:error", {
|
|
@@ -4087,7 +4087,7 @@ const St = (e, n) => {
|
|
|
4087
4087
|
field: "id",
|
|
4088
4088
|
message: o("consumers.copy.success", { val: ae })
|
|
4089
4089
|
});
|
|
4090
|
-
},
|
|
4090
|
+
}, w = ($, Y) => {
|
|
4091
4091
|
const ae = JSON.stringify($);
|
|
4092
4092
|
if (!Y(ae)) {
|
|
4093
4093
|
n("copy:error", {
|
|
@@ -4100,99 +4100,100 @@ const St = (e, n) => {
|
|
|
4100
4100
|
entity: $,
|
|
4101
4101
|
message: o("consumers.copy.success_brief")
|
|
4102
4102
|
});
|
|
4103
|
-
},
|
|
4103
|
+
}, I = async ($) => {
|
|
4104
4104
|
var ae;
|
|
4105
4105
|
await ((ae = t.canRetrieve) == null ? void 0 : ae.call(t, $)) && r.push(t.config.getViewRoute($.id));
|
|
4106
|
-
},
|
|
4106
|
+
}, L = ($) => ({
|
|
4107
4107
|
label: o("consumers.actions.view"),
|
|
4108
4108
|
to: t.config.getViewRoute($)
|
|
4109
|
-
}),
|
|
4109
|
+
}), D = ($) => ({
|
|
4110
4110
|
label: o("consumers.actions.edit"),
|
|
4111
4111
|
to: t.config.getEditRoute($)
|
|
4112
|
-
}),
|
|
4113
|
-
|
|
4114
|
-
},
|
|
4115
|
-
|
|
4116
|
-
},
|
|
4112
|
+
}), S = F(void 0), K = F(!1), N = F(!1), R = F(""), Z = Js(t.config, g.value), H = ($) => {
|
|
4113
|
+
S.value = $, K.value = !0;
|
|
4114
|
+
}, Q = () => {
|
|
4115
|
+
K.value = !1;
|
|
4116
|
+
}, le = async () => {
|
|
4117
4117
|
var $, Y, ae;
|
|
4118
|
-
if (($ =
|
|
4119
|
-
|
|
4118
|
+
if (($ = S.value) != null && $.id) {
|
|
4119
|
+
N.value = !0;
|
|
4120
4120
|
try {
|
|
4121
|
-
await i.delete(
|
|
4121
|
+
await i.delete(Z(S.value.id)), N.value = !1, K.value = !1, s.value++, n("delete:success", S.value);
|
|
4122
4122
|
} catch (fe) {
|
|
4123
|
-
|
|
4123
|
+
R.value = ((ae = (Y = fe.response) == null ? void 0 : Y.data) == null ? void 0 : ae.message) || fe.message || o("consumers.errors.delete"), n("error", fe);
|
|
4124
4124
|
} finally {
|
|
4125
|
-
|
|
4125
|
+
N.value = !1;
|
|
4126
4126
|
}
|
|
4127
4127
|
}
|
|
4128
|
-
},
|
|
4129
|
-
|
|
4130
|
-
},
|
|
4131
|
-
|
|
4132
|
-
},
|
|
4133
|
-
Y ||
|
|
4134
|
-
},
|
|
4135
|
-
l.value &&
|
|
4136
|
-
}, ye = F(void 0),
|
|
4137
|
-
ye.value = $,
|
|
4138
|
-
},
|
|
4139
|
-
|
|
4140
|
-
},
|
|
4128
|
+
}, tt = F(!1), Tt = () => {
|
|
4129
|
+
tt.value = !0;
|
|
4130
|
+
}, $t = () => {
|
|
4131
|
+
tt.value = !1;
|
|
4132
|
+
}, Mt = ($, Y) => {
|
|
4133
|
+
Y || $t(), s.value++, n("add:success", $);
|
|
4134
|
+
}, ea = () => {
|
|
4135
|
+
l.value && Tt();
|
|
4136
|
+
}, ye = F(void 0), nt = F(!1), ta = F(""), na = ($) => {
|
|
4137
|
+
ye.value = $, nt.value = !0;
|
|
4138
|
+
}, Ot = () => {
|
|
4139
|
+
nt.value = !1, ye.value = void 0;
|
|
4140
|
+
}, aa = j(() => {
|
|
4141
4141
|
var Y, ae, fe, we;
|
|
4142
4142
|
let $ = `${t.config.apiBaseUrl}${Se.list[t.config.app].oneForConsumerGroup}`;
|
|
4143
4143
|
return t.config.app === "konnect" ? $ = $.replace(/{controlPlaneId}/gi, ((Y = t.config) == null ? void 0 : Y.controlPlaneId) || "").replace(/{consumerGroupId}/gi, ((ae = t.config) == null ? void 0 : ae.consumerGroupId) || "") : t.config.app === "kongManager" && ($ = $.replace(/\/{workspace}/gi, (fe = t.config) != null && fe.workspace ? `/${t.config.workspace}` : "").replace(/{consumerGroupId}/gi, ((we = t.config) == null ? void 0 : we.consumerGroupId) || "")), $;
|
|
4144
|
-
}),
|
|
4144
|
+
}), jt = F(!1), oa = async () => {
|
|
4145
4145
|
if (ye.value) {
|
|
4146
|
-
|
|
4146
|
+
jt.value = !0;
|
|
4147
4147
|
try {
|
|
4148
|
-
const $ =
|
|
4149
|
-
await i.delete($), n("remove:success", ye.value),
|
|
4148
|
+
const $ = aa.value.replace(/{consumerId}/gi, ye.value.id);
|
|
4149
|
+
await i.delete($), n("remove:success", ye.value), Ot(), s.value++;
|
|
4150
4150
|
} catch ($) {
|
|
4151
|
-
|
|
4151
|
+
ta.value = $.message || o("consumers.errors.delete"), n("error", $);
|
|
4152
4152
|
} finally {
|
|
4153
|
-
|
|
4153
|
+
jt.value = !1;
|
|
4154
4154
|
}
|
|
4155
4155
|
}
|
|
4156
4156
|
};
|
|
4157
|
-
ke(
|
|
4157
|
+
ke(v, ($) => {
|
|
4158
4158
|
if ($.status === _e.Error) {
|
|
4159
|
-
|
|
4159
|
+
E.value = o("consumers.errors.general"), n("error", $.error);
|
|
4160
4160
|
return;
|
|
4161
4161
|
}
|
|
4162
|
-
|
|
4162
|
+
E.value = "";
|
|
4163
4163
|
});
|
|
4164
|
-
const
|
|
4164
|
+
const at = F({
|
|
4165
4165
|
ctaPath: l.value ? void 0 : t.config.createRoute,
|
|
4166
4166
|
ctaText: void 0,
|
|
4167
4167
|
message: o("consumers.list.empty_state.description"),
|
|
4168
4168
|
title: o("consumers.title")
|
|
4169
4169
|
});
|
|
4170
4170
|
return Qe(async () => {
|
|
4171
|
-
await t.canCreate() && (
|
|
4171
|
+
await t.canCreate() && (at.value.title = l.value ? o("consumers.list.empty_state.title_for_consumer_group") : o("consumers.list.empty_state.title"), at.value.ctaText = l.value ? o("consumers.actions.add_consumer") : o("consumers.actions.create"));
|
|
4172
4172
|
}), ($, Y) => {
|
|
4173
|
-
const ae = q("KButton"), fe = q("KBadge"), we = q("KTruncate"), Be = q("KDropdownItem"),
|
|
4174
|
-
return f(), x("div",
|
|
4175
|
-
O(m(
|
|
4173
|
+
const ae = q("KButton"), fe = q("KBadge"), we = q("KTruncate"), Be = q("KDropdownItem"), Ft = q("KClipboardProvider"), ra = q("KPrompt");
|
|
4174
|
+
return f(), x("div", sl, [
|
|
4175
|
+
O(m(_s), {
|
|
4176
4176
|
"cache-identifier": e.cacheIdentifier,
|
|
4177
|
+
"disable-pagination": l.value,
|
|
4177
4178
|
"disable-pagination-page-jump": "",
|
|
4178
4179
|
"disable-sorting": c.value,
|
|
4179
|
-
"empty-state-options":
|
|
4180
|
+
"empty-state-options": at.value,
|
|
4180
4181
|
"enable-entity-actions": "",
|
|
4181
|
-
"error-message":
|
|
4182
|
-
fetcher: m(
|
|
4182
|
+
"error-message": E.value,
|
|
4183
|
+
fetcher: m(b),
|
|
4183
4184
|
"fetcher-cache-key": s.value,
|
|
4184
4185
|
"pagination-type": "offset",
|
|
4185
4186
|
"preferences-storage-key": "kong-ui-entities-consumers-list",
|
|
4186
4187
|
query: C.value,
|
|
4187
4188
|
"row-attributes": h,
|
|
4188
4189
|
"table-headers": m(u),
|
|
4189
|
-
onClearSearchInput:
|
|
4190
|
-
"onClick:row": Y[3] || (Y[3] = (z) =>
|
|
4191
|
-
onEmptyStateCtaClicked:
|
|
4192
|
-
onSort:
|
|
4190
|
+
onClearSearchInput: A,
|
|
4191
|
+
"onClick:row": Y[3] || (Y[3] = (z) => I(z)),
|
|
4192
|
+
onEmptyStateCtaClicked: ea,
|
|
4193
|
+
onSort: V
|
|
4193
4194
|
}, {
|
|
4194
4195
|
"toolbar-filter": y(() => [
|
|
4195
|
-
l.value ? G("", !0) : (f(),
|
|
4196
|
+
l.value ? G("", !0) : (f(), U(m(Us), {
|
|
4196
4197
|
key: 0,
|
|
4197
4198
|
modelValue: C.value,
|
|
4198
4199
|
"onUpdate:modelValue": Y[0] || (Y[0] = (z) => C.value = z),
|
|
@@ -4209,7 +4210,7 @@ const St = (e, n) => {
|
|
|
4209
4210
|
"data-testid": "toolbar-add-consumer",
|
|
4210
4211
|
icon: "plus",
|
|
4211
4212
|
to: e.config.consumerGroupId ? void 0 : e.config.createRoute,
|
|
4212
|
-
onClick: Y[1] || (Y[1] = () => e.config.consumerGroupId ?
|
|
4213
|
+
onClick: Y[1] || (Y[1] = () => e.config.consumerGroupId ? Tt() : void 0)
|
|
4213
4214
|
}, {
|
|
4214
4215
|
default: y(() => [
|
|
4215
4216
|
W(M(e.config.consumerGroupId ? m(o)("consumers.actions.add_consumer") : m(o)("consumers.list.toolbar_actions.new_consumer")), 1)
|
|
@@ -4221,15 +4222,15 @@ const St = (e, n) => {
|
|
|
4221
4222
|
}, 8, ["auth-function"])
|
|
4222
4223
|
]),
|
|
4223
4224
|
username: y(({ rowValue: z }) => [
|
|
4224
|
-
B("b", null, M(
|
|
4225
|
+
B("b", null, M(_(z)), 1)
|
|
4225
4226
|
]),
|
|
4226
4227
|
custom_id: y(({ rowValue: z }) => [
|
|
4227
|
-
W(M(
|
|
4228
|
+
W(M(_(z)), 1)
|
|
4228
4229
|
]),
|
|
4229
4230
|
tags: y(({ rowValue: z }) => [
|
|
4230
|
-
z && z.length > 0 ? (f(),
|
|
4231
|
+
z && z.length > 0 ? (f(), U(we, { key: 0 }, {
|
|
4231
4232
|
default: y(() => [
|
|
4232
|
-
(f(!0), x(pe, null, ce(z, (xe) => (f(),
|
|
4233
|
+
(f(!0), x(pe, null, ce(z, (xe) => (f(), U(fe, {
|
|
4233
4234
|
key: xe,
|
|
4234
4235
|
onClick: Y[2] || (Y[2] = Ge(() => {
|
|
4235
4236
|
}, ["stop"]))
|
|
@@ -4241,14 +4242,14 @@ const St = (e, n) => {
|
|
|
4241
4242
|
}, 1024))), 128))
|
|
4242
4243
|
]),
|
|
4243
4244
|
_: 2
|
|
4244
|
-
}, 1024)) : (f(), x("span",
|
|
4245
|
+
}, 1024)) : (f(), x("span", ll, "-"))
|
|
4245
4246
|
]),
|
|
4246
4247
|
actions: y(({ row: z }) => [
|
|
4247
|
-
O(
|
|
4248
|
+
O(Ft, null, {
|
|
4248
4249
|
default: y(({ copyToClipboard: xe }) => [
|
|
4249
4250
|
O(Be, {
|
|
4250
4251
|
"data-testid": "action-entity-copy-id",
|
|
4251
|
-
onClick: (
|
|
4252
|
+
onClick: (ia) => P(z, xe)
|
|
4252
4253
|
}, {
|
|
4253
4254
|
default: y(() => [
|
|
4254
4255
|
W(M(m(o)("consumers.actions.copy_id")), 1)
|
|
@@ -4258,11 +4259,11 @@ const St = (e, n) => {
|
|
|
4258
4259
|
]),
|
|
4259
4260
|
_: 2
|
|
4260
4261
|
}, 1024),
|
|
4261
|
-
O(
|
|
4262
|
+
O(Ft, null, {
|
|
4262
4263
|
default: y(({ copyToClipboard: xe }) => [
|
|
4263
4264
|
O(Be, {
|
|
4264
4265
|
"data-testid": "action-entity-copy-json",
|
|
4265
|
-
onClick: (
|
|
4266
|
+
onClick: (ia) => w(z, xe)
|
|
4266
4267
|
}, {
|
|
4267
4268
|
default: y(() => [
|
|
4268
4269
|
W(M(m(o)("consumers.actions.copy_json")), 1)
|
|
@@ -4279,7 +4280,7 @@ const St = (e, n) => {
|
|
|
4279
4280
|
O(Be, {
|
|
4280
4281
|
"data-testid": "action-entity-view",
|
|
4281
4282
|
"has-divider": "",
|
|
4282
|
-
item:
|
|
4283
|
+
item: L(z.id)
|
|
4283
4284
|
}, null, 8, ["item"])
|
|
4284
4285
|
]),
|
|
4285
4286
|
_: 2
|
|
@@ -4290,7 +4291,7 @@ const St = (e, n) => {
|
|
|
4290
4291
|
default: y(() => [
|
|
4291
4292
|
O(Be, {
|
|
4292
4293
|
"data-testid": "action-entity-edit",
|
|
4293
|
-
item:
|
|
4294
|
+
item: D(z.id)
|
|
4294
4295
|
}, null, 8, ["item"])
|
|
4295
4296
|
]),
|
|
4296
4297
|
_: 2
|
|
@@ -4303,7 +4304,7 @@ const St = (e, n) => {
|
|
|
4303
4304
|
"data-testid": "action-entity-delete",
|
|
4304
4305
|
"has-divider": "",
|
|
4305
4306
|
"is-dangerous": "",
|
|
4306
|
-
onClick: () => e.config.consumerGroupId ?
|
|
4307
|
+
onClick: () => e.config.consumerGroupId ? na(z) : H(z)
|
|
4307
4308
|
}, {
|
|
4308
4309
|
default: y(() => [
|
|
4309
4310
|
W(M(e.config.consumerGroupId ? m(o)("consumers.actions.remove") : m(o)("consumers.actions.delete")), 1)
|
|
@@ -4315,36 +4316,36 @@ const St = (e, n) => {
|
|
|
4315
4316
|
}, 1032, ["auth-function"])
|
|
4316
4317
|
]),
|
|
4317
4318
|
_: 1
|
|
4318
|
-
}, 8, ["cache-identifier", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers"]),
|
|
4319
|
-
O(m(
|
|
4320
|
-
"action-pending":
|
|
4319
|
+
}, 8, ["cache-identifier", "disable-pagination", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers"]),
|
|
4320
|
+
O(m(xs), {
|
|
4321
|
+
"action-pending": N.value,
|
|
4321
4322
|
"data-testid": "delete-consumer-modal",
|
|
4322
4323
|
description: m(o)("consumers.delete.description"),
|
|
4323
|
-
"entity-name":
|
|
4324
|
-
"entity-type": m(
|
|
4325
|
-
error:
|
|
4324
|
+
"entity-name": S.value && (S.value.username || S.value.custom_id || S.value.id),
|
|
4325
|
+
"entity-type": m(sn).Consumer,
|
|
4326
|
+
error: R.value,
|
|
4326
4327
|
title: m(o)("consumers.delete.title"),
|
|
4327
|
-
visible:
|
|
4328
|
-
onCancel:
|
|
4329
|
-
onProceed:
|
|
4328
|
+
visible: K.value,
|
|
4329
|
+
onCancel: Q,
|
|
4330
|
+
onProceed: le
|
|
4330
4331
|
}, null, 8, ["action-pending", "description", "entity-name", "entity-type", "error", "title", "visible"]),
|
|
4331
|
-
e.config.consumerGroupId ? (f(),
|
|
4332
|
+
e.config.consumerGroupId ? (f(), U(il, {
|
|
4332
4333
|
key: 0,
|
|
4333
4334
|
config: e.config,
|
|
4334
4335
|
"data-testid": "add-consumer-modal",
|
|
4335
|
-
visible:
|
|
4336
|
-
"onAdd:partialSuccess": Y[4] || (Y[4] = (z) =>
|
|
4337
|
-
"onAdd:success": Y[5] || (Y[5] = (z) =>
|
|
4338
|
-
onCancel:
|
|
4336
|
+
visible: tt.value,
|
|
4337
|
+
"onAdd:partialSuccess": Y[4] || (Y[4] = (z) => Mt(z, !0)),
|
|
4338
|
+
"onAdd:success": Y[5] || (Y[5] = (z) => Mt(z)),
|
|
4339
|
+
onCancel: $t
|
|
4339
4340
|
}, null, 8, ["config", "visible"])) : G("", !0),
|
|
4340
|
-
e.config.consumerGroupId && ye.value ? (f(),
|
|
4341
|
+
e.config.consumerGroupId && ye.value ? (f(), U(ra, {
|
|
4341
4342
|
key: 1,
|
|
4342
4343
|
"data-testid": "remove-consumer-modal",
|
|
4343
|
-
"is-visible":
|
|
4344
|
+
"is-visible": nt.value,
|
|
4344
4345
|
title: m(o)("consumers.consumer_groups.remove.title"),
|
|
4345
4346
|
type: "danger",
|
|
4346
|
-
onCanceled:
|
|
4347
|
-
onProceed:
|
|
4347
|
+
onCanceled: Ot,
|
|
4348
|
+
onProceed: oa
|
|
4348
4349
|
}, {
|
|
4349
4350
|
"body-content": y(() => [
|
|
4350
4351
|
O(m(a), {
|
|
@@ -4373,7 +4374,7 @@ const St = (e, n) => {
|
|
|
4373
4374
|
};
|
|
4374
4375
|
}
|
|
4375
4376
|
});
|
|
4376
|
-
const
|
|
4377
|
+
const Il = /* @__PURE__ */ xt(ul, [["__scopeId", "data-v-45929bbf"]]), cl = { class: "kong-ui-entities-consumer-form" }, dl = { class: "fields-group-title" }, pl = { class: "fields-group-text" }, fl = /* @__PURE__ */ te({
|
|
4377
4378
|
__name: "ConsumerForm",
|
|
4378
4379
|
props: {
|
|
4379
4380
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4392,9 +4393,9 @@ const _l = /* @__PURE__ */ St(ll, [["__scopeId", "data-v-a408fc0e"]]), ul = { cl
|
|
|
4392
4393
|
emits: ["update", "error", "loading"],
|
|
4393
4394
|
setup(e, { emit: n }) {
|
|
4394
4395
|
var V;
|
|
4395
|
-
const t = e, { i18nT: a, i18n: { t: o } } = Xe.useI18n(), r =
|
|
4396
|
+
const t = e, { i18nT: a, i18n: { t: o } } = Xe.useI18n(), r = gt(), { axiosInstance: i } = St({
|
|
4396
4397
|
headers: (V = t.config) == null ? void 0 : V.requestHeaders
|
|
4397
|
-
}), { getMessageFromError: s } =
|
|
4398
|
+
}), { getMessageFromError: s } = Ws(), l = Bt({
|
|
4398
4399
|
fields: {
|
|
4399
4400
|
username: "",
|
|
4400
4401
|
customId: "",
|
|
@@ -4402,7 +4403,7 @@ const _l = /* @__PURE__ */ St(ll, [["__scopeId", "data-v-a408fc0e"]]), ul = { cl
|
|
|
4402
4403
|
},
|
|
4403
4404
|
readonly: !1,
|
|
4404
4405
|
errorMessage: ""
|
|
4405
|
-
}), c =
|
|
4406
|
+
}), c = Bt({
|
|
4406
4407
|
username: "",
|
|
4407
4408
|
customId: "",
|
|
4408
4409
|
tags: ""
|
|
@@ -4421,10 +4422,10 @@ const _l = /* @__PURE__ */ St(ll, [["__scopeId", "data-v-a408fc0e"]]), ul = { cl
|
|
|
4421
4422
|
l.fields.username = ((P = _ == null ? void 0 : _.item) == null ? void 0 : P.username) || (_ == null ? void 0 : _.username) || "", l.fields.customId = ((w = _ == null ? void 0 : _.item) == null ? void 0 : w.custom_id) || (_ == null ? void 0 : _.custom_id) || "";
|
|
4422
4423
|
const E = ((I = _ == null ? void 0 : _.item) == null ? void 0 : I.tags) || (_ == null ? void 0 : _.tags) || [];
|
|
4423
4424
|
l.fields.tags = (E == null ? void 0 : E.join(", ")) || "", Object.assign(c, l.fields);
|
|
4424
|
-
}, k = j(() => t.consumerId ?
|
|
4425
|
-
var P, w, I, L,
|
|
4425
|
+
}, k = j(() => t.consumerId ? ut.Edit : ut.Create), p = (_) => {
|
|
4426
|
+
var P, w, I, L, D, S;
|
|
4426
4427
|
let E = `${(P = t.config) == null ? void 0 : P.apiBaseUrl}${Se.form[(w = t.config) == null ? void 0 : w.app][_]}`;
|
|
4427
|
-
return ((I = t.config) == null ? void 0 : I.app) === "konnect" ? E = E.replace(/{controlPlaneId}/gi, ((L = t.config) == null ? void 0 : L.controlPlaneId) || "") : ((
|
|
4428
|
+
return ((I = t.config) == null ? void 0 : I.app) === "konnect" ? E = E.replace(/{controlPlaneId}/gi, ((L = t.config) == null ? void 0 : L.controlPlaneId) || "") : ((D = t.config) == null ? void 0 : D.app) === "kongManager" && (E = E.replace(/\/{workspace}/gi, (S = t.config) != null && S.workspace ? `/${t.config.workspace}` : "")), E = E.replace(/{id}/gi, t.consumerId), E;
|
|
4428
4429
|
}, b = j(() => !!l.fields.username || !!l.fields.customId), v = j(() => JSON.stringify(l.fields) !== JSON.stringify(c)), A = async () => {
|
|
4429
4430
|
var _, E, P;
|
|
4430
4431
|
try {
|
|
@@ -4444,8 +4445,8 @@ const _l = /* @__PURE__ */ St(ll, [["__scopeId", "data-v-a408fc0e"]]), ul = { cl
|
|
|
4444
4445
|
};
|
|
4445
4446
|
return (_, E) => {
|
|
4446
4447
|
const P = q("KInput"), w = q("KCard");
|
|
4447
|
-
return f(), x("div",
|
|
4448
|
-
O(m(
|
|
4448
|
+
return f(), x("div", cl, [
|
|
4449
|
+
O(m(gs), {
|
|
4449
4450
|
"can-submit": b.value && v.value,
|
|
4450
4451
|
config: e.config,
|
|
4451
4452
|
"edit-id": e.consumerId,
|
|
@@ -4460,15 +4461,15 @@ const _l = /* @__PURE__ */ St(ll, [["__scopeId", "data-v-a408fc0e"]]), ul = { cl
|
|
|
4460
4461
|
}, {
|
|
4461
4462
|
default: y(() => [
|
|
4462
4463
|
B("div", null, [
|
|
4463
|
-
O(m(
|
|
4464
|
+
O(m(zs), {
|
|
4464
4465
|
description: m(o)("consumers.form.info.description"),
|
|
4465
4466
|
"has-divider": "",
|
|
4466
4467
|
title: m(o)("consumers.form.info.title")
|
|
4467
4468
|
}, {
|
|
4468
4469
|
default: y(() => [
|
|
4469
4470
|
B("div", null, [
|
|
4470
|
-
B("h5",
|
|
4471
|
-
B("p",
|
|
4471
|
+
B("h5", dl, M(m(o)("consumers.form.consumer_identification.title")) + "* ", 1),
|
|
4472
|
+
B("p", pl, M(m(o)("consumers.form.consumer_identification.description")), 1)
|
|
4472
4473
|
]),
|
|
4473
4474
|
O(w, null, {
|
|
4474
4475
|
body: y(() => [
|
|
@@ -4557,7 +4558,7 @@ const _l = /* @__PURE__ */ St(ll, [["__scopeId", "data-v-a408fc0e"]]), ul = { cl
|
|
|
4557
4558
|
};
|
|
4558
4559
|
}
|
|
4559
4560
|
});
|
|
4560
|
-
const
|
|
4561
|
+
const Al = /* @__PURE__ */ xt(fl, [["__scopeId", "data-v-335659fc"]]), ml = { class: "kong-ui-consumer-entity-config-card" }, Sl = /* @__PURE__ */ te({
|
|
4561
4562
|
__name: "ConsumerConfigCard",
|
|
4562
4563
|
props: {
|
|
4563
4564
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -4609,8 +4610,8 @@ const Il = /* @__PURE__ */ St(pl, [["__scopeId", "data-v-335659fc"]]), fl = { cl
|
|
|
4609
4610
|
hidden: !0
|
|
4610
4611
|
}
|
|
4611
4612
|
});
|
|
4612
|
-
return (i, s) => (f(), x("div",
|
|
4613
|
-
O(m(
|
|
4613
|
+
return (i, s) => (f(), x("div", ml, [
|
|
4614
|
+
O(m(ds), {
|
|
4614
4615
|
config: e.config,
|
|
4615
4616
|
"config-card-doc": e.configCardDoc,
|
|
4616
4617
|
"config-schema": r.value,
|
|
@@ -4649,7 +4650,7 @@ const Il = /* @__PURE__ */ St(pl, [["__scopeId", "data-v-335659fc"]]), fl = { cl
|
|
|
4649
4650
|
}
|
|
4650
4651
|
});
|
|
4651
4652
|
export {
|
|
4652
|
-
|
|
4653
|
-
|
|
4654
|
-
|
|
4653
|
+
Sl as ConsumerConfigCard,
|
|
4654
|
+
Al as ConsumerForm,
|
|
4655
|
+
Il as ConsumerList
|
|
4655
4656
|
};
|