@kong-ui-public/entities-shared 3.33.2-pr.2640.47178031d.0 → 3.33.2-pr.2665.0286fb582.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities-shared.es.js +1308 -1209
- package/dist/entities-shared.umd.js +37 -34
- package/dist/style.css +1 -1
- package/dist/types/components/common/DeckCodeBlock.vue.d.ts +12 -0
- package/dist/types/components/common/DeckCodeBlock.vue.d.ts.map +1 -0
- package/dist/types/components/entity-base-config-card/ConfigCardDisplay.vue.d.ts +1 -1
- package/dist/types/components/entity-base-config-card/ConfigCardDisplay.vue.d.ts.map +1 -1
- package/dist/types/components/entity-base-form/EntityBaseForm.vue.d.ts.map +1 -1
- package/dist/types/components/entity-base-table/EntityBaseTable.vue.d.ts +2 -6
- package/dist/types/components/entity-base-table/EntityBaseTable.vue.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/types/app-config.d.ts +4 -0
- package/dist/types/types/app-config.d.ts.map +1 -1
- package/dist/types/types/entity-base-config-card.d.ts +2 -0
- package/dist/types/types/entity-base-config-card.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -1,17 +1,32 @@
|
|
|
1
|
-
import { inject as Dt, ref as
|
|
1
|
+
import { inject as Dt, ref as N, computed as $, unref as T, toValue as ye, watch as be, toRef as Jn, provide as Pt, defineComponent as z, createBlock as j, openBlock as m, resolveDynamicComponent as De, normalizeClass as fe, withCtx as k, createElementBlock as S, createCommentVNode as M, createElementVNode as B, toDisplayString as L, Fragment as ue, renderList as ce, resolveComponent as P, createVNode as K, createTextVNode as U, useCssVars as Ut, useId as Gn, useSlots as Pe, renderSlot as D, createSlots as Se, normalizeProps as zn, guardReactiveProps as Qn, mergeProps as qt, onMounted as nt, onBeforeMount as it, withModifiers as Be, Teleport as Ht, onUnmounted as Zn, withDirectives as xe, vShow as Ce, withKeys as Xn, warn as ei } from "vue";
|
|
2
2
|
import pt from "axios";
|
|
3
|
-
import { createI18n as
|
|
4
|
-
import { BadgeMethodAppearances as
|
|
5
|
-
import { BookIcon as
|
|
6
|
-
import { useRouter as
|
|
7
|
-
var
|
|
8
|
-
const
|
|
3
|
+
import { createI18n as ti, i18nTComponent as ni } from "@kong-ui-public/i18n";
|
|
4
|
+
import { BadgeMethodAppearances as ii, KButton as mt, KTruncate as ri, KBadge as ai } from "@kong/kongponents";
|
|
5
|
+
import { BookIcon as Vt, AddIcon as Yt, CloseIcon as oi, ChevronDownIcon as li, CopyIcon as si } from "@kong/icons";
|
|
6
|
+
import { useRouter as ci } from "vue-router";
|
|
7
|
+
var ui = /* @__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.Secret = "secret", e.RedisConfiguration = "redis configuration", e))(ui || {}), di = /* @__PURE__ */ ((e) => (e.Edit = "edit", e.Create = "create", e))(di || {}), me = /* @__PURE__ */ ((e) => (e[e.InitialLoad = 0] = "InitialLoad", e[e.Loading = 1] = "Loading", e[e.Idle = 2] = "Idle", e[e.NoResults = 3] = "NoResults", e[e.NoRecords = 4] = "NoRecords", e[e.Error = 5] = "Error", e))(me || {}), Ee = /* @__PURE__ */ ((e) => (e.CaCertificate = "ca_certificate", e.Certificate = "certificate", e.Consumer = "consumer", e.ConsumerGroup = "consumer_group", e.GatewayService = "service", e.Key = "key", e.KeySet = "set", e.Plugin = "plugin", e.Route = "route", e.SNI = "sni", e.Upstream = "upstream", e.Target = "target", e.Vault = "vault", e.Partial = "partial", e.BackendCluster = "backend_cluster", e.VirtualCluster = "virtual_cluster", e.Listener = "listener", e.ProducePolicy = "produce_policy", e.ConsumePolicy = "consume_policy", e.ClusterPolicy = "cluster_policy", e.ListenerPolicy = "listener_policy", e.SchemaRegistry = "schema_registry", e.StaticKey = "static_key", e.Other = "other", e))(Ee || {});
|
|
8
|
+
const Ue = Object.values(Ee), fi = [
|
|
9
|
+
"ca_certificate",
|
|
10
|
+
"certificate",
|
|
11
|
+
"consumer",
|
|
12
|
+
"consumer_group",
|
|
13
|
+
"service",
|
|
14
|
+
"key",
|
|
15
|
+
"set",
|
|
16
|
+
"plugin",
|
|
17
|
+
"route",
|
|
18
|
+
"upstream",
|
|
19
|
+
"target",
|
|
20
|
+
"vault",
|
|
21
|
+
"partial"
|
|
22
|
+
/* Partial */
|
|
23
|
+
], pi = ["backend_cluster", "virtual_cluster", "listener", "produce_policy", "consume_policy", "cluster_policy", "listener_policy", "schema_registry", "static_key"];
|
|
9
24
|
var V = /* @__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.CopyBadge = "copy-badge", e.BadgeStatus = "badge-status", e.BadgeMethod = "badge-method", e.LinkInternal = "link-internal", e.LinkExternal = "link-external", e))(V || {}), ae = /* @__PURE__ */ ((e) => (e.Basic = "basic", e.Advanced = "advanced", e.Plugin = "plugin", e.Policy = "policy", e))(ae || {});
|
|
10
|
-
const
|
|
25
|
+
const yt = [
|
|
11
26
|
"primary",
|
|
12
27
|
"secondary"
|
|
13
28
|
];
|
|
14
|
-
function
|
|
29
|
+
function mi() {
|
|
15
30
|
return {
|
|
16
31
|
getAxiosInstance: (e = {}) => {
|
|
17
32
|
try {
|
|
@@ -35,7 +50,7 @@ function ui() {
|
|
|
35
50
|
}
|
|
36
51
|
};
|
|
37
52
|
}
|
|
38
|
-
function
|
|
53
|
+
function yi() {
|
|
39
54
|
return {
|
|
40
55
|
debounce: (e, t) => {
|
|
41
56
|
let n;
|
|
@@ -47,13 +62,13 @@ function di() {
|
|
|
47
62
|
}
|
|
48
63
|
};
|
|
49
64
|
}
|
|
50
|
-
const
|
|
65
|
+
const Ve = "khcp-user-table-preferences", gi = {
|
|
51
66
|
pageSize: 30,
|
|
52
67
|
sortColumnKey: void 0,
|
|
53
68
|
sortColumnOrder: void 0,
|
|
54
69
|
columnVisibility: {}
|
|
55
70
|
};
|
|
56
|
-
function
|
|
71
|
+
function hi() {
|
|
57
72
|
const e = (n) => {
|
|
58
73
|
if (typeof n == "string")
|
|
59
74
|
try {
|
|
@@ -63,44 +78,44 @@ function pi() {
|
|
|
63
78
|
return;
|
|
64
79
|
}
|
|
65
80
|
}, t = () => {
|
|
66
|
-
const n = e(localStorage.getItem(
|
|
81
|
+
const n = e(localStorage.getItem(Ve));
|
|
67
82
|
return !n || !Object.keys(n).length ? /* @__PURE__ */ new Map() : new Map(Object.entries(n));
|
|
68
83
|
};
|
|
69
84
|
return {
|
|
70
85
|
setTablePreferences: (n, i) => {
|
|
71
86
|
try {
|
|
72
87
|
const r = t();
|
|
73
|
-
r.set(n, i), localStorage.setItem(
|
|
88
|
+
r.set(n, i), localStorage.setItem(Ve, JSON.stringify(Object.fromEntries(r.entries())));
|
|
74
89
|
} catch (r) {
|
|
75
90
|
console.error("useTablePreferences(setTablePreferences)", r);
|
|
76
91
|
}
|
|
77
92
|
},
|
|
78
93
|
getTablePreferences: (n, i) => {
|
|
79
94
|
const r = t();
|
|
80
|
-
return (r == null ? void 0 : r.get(n)) || void 0 || i ||
|
|
95
|
+
return (r == null ? void 0 : r.get(n)) || void 0 || i || gi;
|
|
81
96
|
},
|
|
82
97
|
deleteAllTablePreferences: () => {
|
|
83
|
-
localStorage.removeItem(
|
|
98
|
+
localStorage.removeItem(Ve);
|
|
84
99
|
}
|
|
85
100
|
};
|
|
86
101
|
}
|
|
87
102
|
function rt(e = {}) {
|
|
88
|
-
const { getAxiosInstance: t } =
|
|
103
|
+
const { getAxiosInstance: t } = mi();
|
|
89
104
|
return {
|
|
90
105
|
axiosInstance: t(e)
|
|
91
106
|
};
|
|
92
107
|
}
|
|
93
|
-
const
|
|
108
|
+
const vi = {
|
|
94
109
|
actions: {
|
|
95
110
|
copyId: "Copy ID",
|
|
96
111
|
copied_id: 'Copied "{id}" to the clipboard',
|
|
97
112
|
copyToClipboard: "Copied successfully!",
|
|
98
113
|
copyToClipboardFailed: "Failed to copy to the clipboard"
|
|
99
114
|
}
|
|
100
|
-
},
|
|
115
|
+
}, bi = {
|
|
101
116
|
message: "Are you sure you want to delete this {entityType}?",
|
|
102
117
|
messageWithName: "Are you sure you want to delete this {entityType} {entityName}?"
|
|
103
|
-
},
|
|
118
|
+
}, xi = {
|
|
104
119
|
actions: {
|
|
105
120
|
viewConfiguration: "View Configuration",
|
|
106
121
|
save: "Save",
|
|
@@ -112,18 +127,19 @@ const mi = {
|
|
|
112
127
|
message: "Export configurations for core Kong Gateway objects, like services, routes, and plugins, to either YAML or JSON. This allows for straightforward importing into APIOps tools like decK with YAML, or Insomnia and cURL with JSON.",
|
|
113
128
|
yaml: "YAML",
|
|
114
129
|
json: "JSON",
|
|
115
|
-
terraform: "Terraform"
|
|
130
|
+
terraform: "Terraform",
|
|
131
|
+
deck: "decK"
|
|
116
132
|
},
|
|
117
133
|
errors: {
|
|
118
134
|
edit: "The entity could not be edited at this time."
|
|
119
135
|
}
|
|
120
|
-
},
|
|
136
|
+
}, Ci = {
|
|
121
137
|
emptyState: {
|
|
122
138
|
noSearchResultsTitle: "No results found",
|
|
123
139
|
noSearchResultsMessage: "Please adjust the criteria and try again.",
|
|
124
140
|
noSearchResultsCtaText: "Clear"
|
|
125
141
|
}
|
|
126
|
-
},
|
|
142
|
+
}, ki = {
|
|
127
143
|
title: "Configuration",
|
|
128
144
|
actions: {
|
|
129
145
|
copy: "Copy JSON"
|
|
@@ -160,10 +176,10 @@ const mi = {
|
|
|
160
176
|
entryTitle: "Entry {index}",
|
|
161
177
|
structuredFormat: "Structured"
|
|
162
178
|
}
|
|
163
|
-
},
|
|
179
|
+
}, Ai = {
|
|
164
180
|
learnMore: "Learn more",
|
|
165
181
|
pricingTitle: "Pricing: "
|
|
166
|
-
},
|
|
182
|
+
}, _i = {
|
|
167
183
|
filterButtonText: "Filter",
|
|
168
184
|
fieldLabel: "Filter by:",
|
|
169
185
|
inputPlaceholder: "Enter a value",
|
|
@@ -171,17 +187,17 @@ const mi = {
|
|
|
171
187
|
applyButtonText: "Apply",
|
|
172
188
|
clearButtonText: "Clear",
|
|
173
189
|
clearAllButtonText: "Clear all filters"
|
|
174
|
-
},
|
|
190
|
+
}, wi = {
|
|
175
191
|
errors: {
|
|
176
192
|
fetch: "Could not fetch available items",
|
|
177
193
|
invalid: "Please select a valid value"
|
|
178
194
|
}
|
|
179
|
-
},
|
|
195
|
+
}, Si = {
|
|
180
196
|
unexpected: "An unexpected error has occurred",
|
|
181
197
|
dataKeyUndefined: 'The data key "{dataKey}" does not exist in the response.'
|
|
182
|
-
},
|
|
198
|
+
}, $i = {
|
|
183
199
|
utf8Name: "The name can be any string containing characters, letters, numbers, or the following characters: ., -, _, or ~. Do not use spaces."
|
|
184
|
-
},
|
|
200
|
+
}, Ti = {
|
|
185
201
|
enable: {
|
|
186
202
|
title: "Enable {entityType}",
|
|
187
203
|
message: "Are you sure you want to enable the {entityType} {entityName}?",
|
|
@@ -192,28 +208,28 @@ const mi = {
|
|
|
192
208
|
message: "Are you sure you want to disable the {entityType} {entityName}?",
|
|
193
209
|
confirmText: "Yes, disable"
|
|
194
210
|
}
|
|
195
|
-
},
|
|
196
|
-
global:
|
|
197
|
-
deleteModal:
|
|
198
|
-
baseForm:
|
|
199
|
-
baseTable:
|
|
200
|
-
baseConfigCard:
|
|
201
|
-
emptyState:
|
|
202
|
-
filter:
|
|
203
|
-
debouncedFilter:
|
|
204
|
-
errors:
|
|
205
|
-
validationErrors:
|
|
206
|
-
toggleModal:
|
|
211
|
+
}, Ei = {
|
|
212
|
+
global: vi,
|
|
213
|
+
deleteModal: bi,
|
|
214
|
+
baseForm: xi,
|
|
215
|
+
baseTable: Ci,
|
|
216
|
+
baseConfigCard: ki,
|
|
217
|
+
emptyState: Ai,
|
|
218
|
+
filter: _i,
|
|
219
|
+
debouncedFilter: wi,
|
|
220
|
+
errors: Si,
|
|
221
|
+
validationErrors: $i,
|
|
222
|
+
toggleModal: Ti
|
|
207
223
|
};
|
|
208
|
-
function
|
|
209
|
-
const e =
|
|
224
|
+
function qe() {
|
|
225
|
+
const e = ti("en-us", Ei);
|
|
210
226
|
return {
|
|
211
227
|
i18n: e,
|
|
212
|
-
i18nT:
|
|
228
|
+
i18nT: ni(e)
|
|
213
229
|
// Translation component <i18n-t>
|
|
214
230
|
};
|
|
215
231
|
}
|
|
216
|
-
function
|
|
232
|
+
function Wt() {
|
|
217
233
|
const e = (o, a) => (a == null ? void 0 : a[o]) ?? void 0, t = (o, a) => {
|
|
218
234
|
if (o.length !== a.length) return !1;
|
|
219
235
|
const s = /* @__PURE__ */ new Set([...o, ...a]);
|
|
@@ -255,69 +271,69 @@ function Gt() {
|
|
|
255
271
|
isValidUuid: (o) => o ? /[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/.test(o) : !1
|
|
256
272
|
};
|
|
257
273
|
}
|
|
258
|
-
function
|
|
274
|
+
function Ii(e, t, n, i = {
|
|
259
275
|
fetchedItemsKey: "data",
|
|
260
276
|
searchKeys: ["id"]
|
|
261
277
|
}) {
|
|
262
278
|
n || (n = "1000");
|
|
263
|
-
const { axiosInstance: r } = rt(e.axiosRequestConfig), { i18n: { t: o } } =
|
|
264
|
-
await C(
|
|
265
|
-
}, 200), l =
|
|
266
|
-
const
|
|
267
|
-
return e.app === "konnect" ?
|
|
268
|
-
}), { isValidUuid: x } =
|
|
279
|
+
const { axiosInstance: r } = rt(e.axiosRequestConfig), { i18n: { t: o } } = qe(), { debounce: a } = yi(), s = a(async (E) => {
|
|
280
|
+
await C(E);
|
|
281
|
+
}, 200), l = N(!1), c = N(""), d = N(""), u = N([]), p = N([]), g = N(void 0), y = $(() => {
|
|
282
|
+
const E = `${e.apiBaseUrl}${T(t)}`;
|
|
283
|
+
return e.app === "konnect" ? E.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" ? E.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : "") : E;
|
|
284
|
+
}), { isValidUuid: x } = Wt(), h = async () => {
|
|
269
285
|
try {
|
|
270
286
|
l.value = !0;
|
|
271
|
-
const { data:
|
|
272
|
-
|
|
287
|
+
const { data: E } = await r.get(`${y.value}?size=${n}`);
|
|
288
|
+
E != null && E.next || (g.value = i.fetchedItemsKey in E ? E[i.fetchedItemsKey] : []), p.value = i.fetchedItemsKey in E ? E[i.fetchedItemsKey] : [], u.value = p.value;
|
|
273
289
|
} catch {
|
|
274
290
|
u.value = [], c.value = o("debouncedFilter.errors.fetch");
|
|
275
291
|
} finally {
|
|
276
292
|
l.value = !1;
|
|
277
293
|
}
|
|
278
|
-
},
|
|
279
|
-
var
|
|
280
|
-
if (
|
|
281
|
-
if (
|
|
294
|
+
}, A = N(""), C = async (E) => {
|
|
295
|
+
var Y, X, w;
|
|
296
|
+
if (A.value !== E) {
|
|
297
|
+
if (A.value = E ?? "", !E) {
|
|
282
298
|
u.value = p.value;
|
|
283
299
|
return;
|
|
284
300
|
}
|
|
285
301
|
if (g.value === void 0)
|
|
286
302
|
try {
|
|
287
303
|
if (l.value = !0, c.value = "", d.value = "", e.app === "konnect") {
|
|
288
|
-
const
|
|
304
|
+
const _ = `${y.value}/${E}`, { data: O } = await r.get(`${_}?size=${n}`);
|
|
289
305
|
i.fetchedItemsKey in O ? u.value = O[i.fetchedItemsKey] : O != null && O[i.exactMatchKey ?? "id"] ? u.value = [O] : u.value = [];
|
|
290
306
|
} else {
|
|
291
|
-
const
|
|
292
|
-
x(
|
|
293
|
-
const { data: v } = await r.get(`${
|
|
307
|
+
const _ = [];
|
|
308
|
+
x(E) && i.searchKeys.includes("id") ? _.push((async () => {
|
|
309
|
+
const { data: v } = await r.get(`${y.value}/${E}`);
|
|
294
310
|
return [v[i.fetchedItemsKey] ?? v];
|
|
295
|
-
})()) :
|
|
311
|
+
})()) : _.push(
|
|
296
312
|
...i.searchKeys.filter((v) => v !== "id").map(async (v) => {
|
|
297
|
-
const { data: b } = await r.get(`${
|
|
313
|
+
const { data: b } = await r.get(`${y.value}?${v}=${E}`);
|
|
298
314
|
return b[i.fetchedItemsKey];
|
|
299
315
|
})
|
|
300
316
|
);
|
|
301
|
-
const O = await Promise.all(
|
|
302
|
-
u.value = [], (
|
|
317
|
+
const O = await Promise.all(_), f = /* @__PURE__ */ new Set();
|
|
318
|
+
u.value = [], (Y = O == null ? void 0 : O.forEach) == null || Y.call(O, (v) => {
|
|
303
319
|
var b;
|
|
304
320
|
(b = v == null ? void 0 : v.forEach) == null || b.call(v, (H) => {
|
|
305
321
|
f.has(H.id) || (f.add(H.id), u.value.push(H));
|
|
306
322
|
});
|
|
307
323
|
});
|
|
308
324
|
}
|
|
309
|
-
} catch (
|
|
310
|
-
((X =
|
|
325
|
+
} catch (_) {
|
|
326
|
+
((X = _ == null ? void 0 : _.response) == null ? void 0 : X.status) === 404 ? d.value = o("debouncedFilter.errors.invalid") : (u.value = [], c.value = o("debouncedFilter.errors.fetch"));
|
|
311
327
|
} finally {
|
|
312
328
|
l.value = !1;
|
|
313
329
|
}
|
|
314
330
|
else
|
|
315
|
-
l.value = !0, d.value = "", u.value = (w = g.value) == null ? void 0 : w.filter((
|
|
331
|
+
l.value = !0, d.value = "", u.value = (w = g.value) == null ? void 0 : w.filter((_) => {
|
|
316
332
|
var f;
|
|
317
333
|
let O = !1;
|
|
318
334
|
for (const v of i.searchKeys) {
|
|
319
|
-
const b = typeof
|
|
320
|
-
b != null && b.includes(
|
|
335
|
+
const b = typeof _[v] == "string" ? (f = _[v]) == null ? void 0 : f.toLowerCase() : _[v];
|
|
336
|
+
b != null && b.includes(E.toLowerCase()) && (O = !0);
|
|
321
337
|
}
|
|
322
338
|
return O;
|
|
323
339
|
}), (!u.value || !u.value.length) && (d.value = o("debouncedFilter.errors.invalid")), l.value = !1;
|
|
@@ -329,18 +345,18 @@ function Si(e, t, n, i = {
|
|
|
329
345
|
validationError: d,
|
|
330
346
|
results: u,
|
|
331
347
|
allRecords: g,
|
|
332
|
-
loadItems:
|
|
348
|
+
loadItems: h,
|
|
333
349
|
debouncedQueryChange: s
|
|
334
350
|
};
|
|
335
351
|
}
|
|
336
|
-
function
|
|
337
|
-
const n =
|
|
352
|
+
function Fi(e, t) {
|
|
353
|
+
const n = T(t), i = $(
|
|
338
354
|
() => e.apiBaseUrl.startsWith("/") ? new URL(`${window.location.origin}${n}`) : new URL(n)
|
|
339
355
|
);
|
|
340
356
|
return i.value.search = "", (r) => `${i.value.href}/${r}`;
|
|
341
357
|
}
|
|
342
|
-
function
|
|
343
|
-
const { i18n: { t: e } } =
|
|
358
|
+
function Oi() {
|
|
359
|
+
const { i18n: { t: e } } = qe();
|
|
344
360
|
return {
|
|
345
361
|
getErrorFieldsFromError: (i) => {
|
|
346
362
|
var a, s, l;
|
|
@@ -411,7 +427,7 @@ function Ti() {
|
|
|
411
427
|
}
|
|
412
428
|
};
|
|
413
429
|
}
|
|
414
|
-
function
|
|
430
|
+
function Li(e) {
|
|
415
431
|
const t = window.location.origin, n = t.endsWith("/") ? t : `${t}/`;
|
|
416
432
|
try {
|
|
417
433
|
const i = e.join("/"), r = `${n}${i}`, o = e.some((s) => s.trim() === "");
|
|
@@ -422,139 +438,139 @@ function Ii(e) {
|
|
|
422
438
|
return console.warn("Failed to build valid URL:", i), "";
|
|
423
439
|
}
|
|
424
440
|
}
|
|
425
|
-
function
|
|
426
|
-
const n =
|
|
427
|
-
const r =
|
|
441
|
+
function Jt(e, t) {
|
|
442
|
+
const n = $(() => {
|
|
443
|
+
const r = ye(e);
|
|
428
444
|
return r.app === "konnect" || !!r.isExactMatch;
|
|
429
|
-
}), i =
|
|
430
|
-
const r =
|
|
445
|
+
}), i = $(() => {
|
|
446
|
+
const r = ye(t);
|
|
431
447
|
return r.startsWith("/") ? new URL(`${window.location.origin}${r}`) : new URL(r);
|
|
432
448
|
});
|
|
433
449
|
return (r) => {
|
|
434
450
|
const { page: o, pageSize: a, offset: s, sortColumnKey: l, sortColumnOrder: c, query: d } = r;
|
|
435
451
|
try {
|
|
436
452
|
let u = new URL(i.value.href);
|
|
437
|
-
return n.value && d ? (u.search = "", u =
|
|
453
|
+
return n.value && d ? (u.search = "", u = ye(e).isExactMatch ? new URL(`${u.href}/${d}`) : new URL(`${u.href}?filter[name][contains]=${d}`)) : (n.value || new URLSearchParams(d).forEach((p, g) => {
|
|
438
454
|
u.searchParams.append(g, p);
|
|
439
455
|
}), l && u.searchParams.append("sort_by", l), c === "desc" && u.searchParams.append("sort_desc", "1"), u.searchParams.append("size", String(a))), s && o !== 1 && u.searchParams.append("offset", String(s)), u.href;
|
|
440
456
|
} catch (u) {
|
|
441
|
-
return console.error("RouteList(fetcher)", u),
|
|
457
|
+
return console.error("RouteList(fetcher)", u), ye(t);
|
|
442
458
|
}
|
|
443
459
|
};
|
|
444
460
|
}
|
|
445
461
|
const gt = /* @__PURE__ */ new Map();
|
|
446
|
-
function
|
|
447
|
-
const i =
|
|
462
|
+
function Bi(e, t, n) {
|
|
463
|
+
const i = N(!0), r = ye(e), { axiosInstance: o } = rt(r.axiosRequestConfig), a = Jt(e, t), s = N({
|
|
448
464
|
status: me.Idle
|
|
449
465
|
}), l = async (u) => {
|
|
450
466
|
var g;
|
|
451
|
-
const p =
|
|
467
|
+
const p = ye(n) || "data";
|
|
452
468
|
try {
|
|
453
469
|
s.value = i.value ? { status: me.InitialLoad } : { status: me.Loading }, i.value = !1;
|
|
454
|
-
let
|
|
455
|
-
|
|
456
|
-
const x = await o.get(
|
|
470
|
+
let y = a(u);
|
|
471
|
+
y.includes("filter[name]") && (y = `${y}&page[size]=${u.pageSize}&page[number]=${u.page}`);
|
|
472
|
+
const x = await o.get(y);
|
|
457
473
|
if (x.status >= 400)
|
|
458
474
|
throw x;
|
|
459
|
-
const
|
|
475
|
+
const h = x.data, A = p && p.replace(/[^\w-_]/gi, "");
|
|
460
476
|
let C;
|
|
461
|
-
|
|
462
|
-
const
|
|
477
|
+
h[A] ? C = Array.isArray(h[A]) ? h[A] : [h[A]] : Array.isArray(h) ? C = h : C = Object.keys(h).length ? [h] : [];
|
|
478
|
+
const E = {
|
|
463
479
|
data: C,
|
|
464
480
|
total: C.length,
|
|
465
|
-
...
|
|
481
|
+
...h.offset ? {
|
|
466
482
|
pagination: {
|
|
467
|
-
offset:
|
|
483
|
+
offset: h.offset
|
|
468
484
|
}
|
|
469
485
|
} : null
|
|
470
486
|
};
|
|
471
|
-
return
|
|
487
|
+
return E.data.length === 0 && !u.query ? s.value = {
|
|
472
488
|
status: me.NoRecords,
|
|
473
|
-
response:
|
|
489
|
+
response: E
|
|
474
490
|
} : s.value = {
|
|
475
491
|
status: me.Idle,
|
|
476
|
-
response:
|
|
477
|
-
},
|
|
478
|
-
} catch (
|
|
492
|
+
response: E
|
|
493
|
+
}, E;
|
|
494
|
+
} catch (y) {
|
|
479
495
|
const x = {
|
|
480
496
|
data: [],
|
|
481
497
|
total: 0
|
|
482
498
|
};
|
|
483
|
-
return u.query && (((g =
|
|
499
|
+
return u.query && (((g = y.response) == null ? void 0 : g.status) === 404 || y.status === 404) ? (s.value = {
|
|
484
500
|
status: me.NoResults,
|
|
485
501
|
response: x,
|
|
486
|
-
error:
|
|
502
|
+
error: y.response ? y : { response: y }
|
|
487
503
|
}, x) : (s.value = {
|
|
488
504
|
status: me.Error,
|
|
489
505
|
response: x,
|
|
490
|
-
error:
|
|
506
|
+
error: y.response ? y : { response: y }
|
|
491
507
|
}, x);
|
|
492
508
|
}
|
|
493
|
-
}, c = r.cacheIdentifier, d =
|
|
509
|
+
}, c = r.cacheIdentifier, d = Gt(c);
|
|
494
510
|
return { fetcher: l, fetcherState: s, fetcherCacheKey: d };
|
|
495
511
|
}
|
|
496
|
-
function
|
|
512
|
+
function Gt(e) {
|
|
497
513
|
if (e) {
|
|
498
514
|
let t = gt.get(e);
|
|
499
|
-
return t || (t =
|
|
515
|
+
return t || (t = N(1), gt.set(e, t)), t;
|
|
500
516
|
}
|
|
501
|
-
return
|
|
517
|
+
return N(1);
|
|
502
518
|
}
|
|
503
|
-
function
|
|
519
|
+
function Ri() {
|
|
504
520
|
const e = (i, r = "_") => i ? i.split(r).map((o) => o.toLowerCase() === "id" ? o.toUpperCase() : o.charAt(0).toUpperCase() + o.substring(1)).join(" ") : "", t = /(?:^|[\s-:'"])\w/g;
|
|
505
521
|
return {
|
|
506
522
|
capitalize: (i) => i ? i.replace(t, (r) => r.toUpperCase()) : "",
|
|
507
523
|
convertKeyToTitle: e
|
|
508
524
|
};
|
|
509
525
|
}
|
|
510
|
-
const
|
|
526
|
+
const zt = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, ht = (e) => {
|
|
511
527
|
if (typeof e != "string")
|
|
512
528
|
throw new TypeError("Invalid argument expected string");
|
|
513
|
-
const t = e.match(
|
|
529
|
+
const t = e.match(zt);
|
|
514
530
|
if (!t)
|
|
515
531
|
throw new Error(`Invalid argument not valid semver ('${e}' received)`);
|
|
516
532
|
return t.shift(), t;
|
|
517
533
|
}, vt = (e) => e === "*" || e === "x" || e === "X", bt = (e) => {
|
|
518
534
|
const t = parseInt(e, 10);
|
|
519
535
|
return isNaN(t) ? e : t;
|
|
520
|
-
},
|
|
536
|
+
}, Ki = (e, t) => typeof e != typeof t ? [String(e), String(t)] : [e, t], Ni = (e, t) => {
|
|
521
537
|
if (vt(e) || vt(t))
|
|
522
538
|
return 0;
|
|
523
|
-
const [n, i] =
|
|
539
|
+
const [n, i] = Ki(bt(e), bt(t));
|
|
524
540
|
return n > i ? 1 : n < i ? -1 : 0;
|
|
525
541
|
}, xt = (e, t) => {
|
|
526
542
|
for (let n = 0; n < Math.max(e.length, t.length); n++) {
|
|
527
|
-
const i =
|
|
543
|
+
const i = Ni(e[n] || "0", t[n] || "0");
|
|
528
544
|
if (i !== 0)
|
|
529
545
|
return i;
|
|
530
546
|
}
|
|
531
547
|
return 0;
|
|
532
|
-
},
|
|
533
|
-
const n =
|
|
548
|
+
}, Mi = (e, t) => {
|
|
549
|
+
const n = ht(e), i = ht(t), r = n.pop(), o = i.pop(), a = xt(n, i);
|
|
534
550
|
return a !== 0 ? a : r && o ? xt(r.split("."), o.split(".")) : r || o ? r ? -1 : 1 : 0;
|
|
535
551
|
}, Ct = (e, t, n) => {
|
|
536
|
-
|
|
537
|
-
const i =
|
|
538
|
-
return
|
|
539
|
-
},
|
|
552
|
+
ji(n);
|
|
553
|
+
const i = Mi(e, t);
|
|
554
|
+
return Qt[n].includes(i);
|
|
555
|
+
}, Qt = {
|
|
540
556
|
">": [1],
|
|
541
557
|
">=": [0, 1],
|
|
542
558
|
"=": [0],
|
|
543
559
|
"<=": [-1, 0],
|
|
544
560
|
"<": [-1],
|
|
545
561
|
"!=": [-1, 1]
|
|
546
|
-
}, kt = Object.keys(
|
|
562
|
+
}, kt = Object.keys(Qt), ji = (e) => {
|
|
547
563
|
if (typeof e != "string")
|
|
548
564
|
throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
|
|
549
565
|
if (kt.indexOf(e) === -1)
|
|
550
566
|
throw new Error(`Invalid operator, expected one of ${kt.join("|")}`);
|
|
551
|
-
},
|
|
552
|
-
function
|
|
567
|
+
}, Di = (e) => typeof e == "string" && /^[v\d]/.test(e) && zt.test(e);
|
|
568
|
+
function Pi(e) {
|
|
553
569
|
const { gatewayInfo: t, supportedRange: n } = e;
|
|
554
570
|
if (!t)
|
|
555
571
|
return !0;
|
|
556
572
|
const { edition: i, version: r } = t;
|
|
557
|
-
if (!
|
|
573
|
+
if (!Di(r))
|
|
558
574
|
return console.error("Invalid version"), !1;
|
|
559
575
|
const o = n[i];
|
|
560
576
|
if (!o)
|
|
@@ -562,64 +578,64 @@ function Ni(e) {
|
|
|
562
578
|
const [a, s] = o;
|
|
563
579
|
return !(a && Ct(r, a, "<") || s && Ct(r, s, ">"));
|
|
564
580
|
}
|
|
565
|
-
function
|
|
566
|
-
const t =
|
|
581
|
+
function Ui(e) {
|
|
582
|
+
const t = N(0), n = N(0), i = N(!1);
|
|
567
583
|
return be(e, (o) => {
|
|
568
584
|
o && !i.value && (t.value = o.offsetWidth, n.value = o.scrollWidth, i.value = !0);
|
|
569
585
|
}), {
|
|
570
|
-
isTruncated:
|
|
586
|
+
isTruncated: $(() => t.value < n.value)
|
|
571
587
|
};
|
|
572
588
|
}
|
|
573
|
-
function
|
|
574
|
-
const { i18n: { t: e } } =
|
|
589
|
+
function qi() {
|
|
590
|
+
const { i18n: { t: e } } = qe();
|
|
575
591
|
return {
|
|
576
592
|
utf8Name: (n) => /^[\p{N}\p{L}.\-_~]*$/u.test(n) ? "" : e("validationErrors.utf8Name")
|
|
577
593
|
};
|
|
578
594
|
}
|
|
579
|
-
const
|
|
580
|
-
Pt(
|
|
581
|
-
},
|
|
595
|
+
const ze = Symbol("schema"), Hi = (e) => {
|
|
596
|
+
Pt(ze, e);
|
|
597
|
+
}, Vi = (e) => {
|
|
582
598
|
var r, o;
|
|
583
|
-
const t = Dt(
|
|
584
|
-
return Pt(
|
|
599
|
+
const t = Dt(ze, void 0), n = (o = (r = t == null ? void 0 : t.value) == null ? void 0 : r.fields) == null ? void 0 : o.find((a) => Object.keys(a)[0] === e), i = Jn(n == null ? void 0 : n[e]);
|
|
600
|
+
return Pt(ze, i), i;
|
|
585
601
|
};
|
|
586
|
-
function
|
|
602
|
+
function Yi(e) {
|
|
587
603
|
let t = "";
|
|
588
|
-
const n =
|
|
604
|
+
const n = N(!1), i = N(null), r = $(() => {
|
|
589
605
|
let a;
|
|
590
|
-
return n.value ? a = !0 : i.value ? a = i.value.hasData || e &&
|
|
606
|
+
return n.value ? a = !0 : i.value ? a = i.value.hasData || e && ye(e) : a = !1, !a;
|
|
591
607
|
});
|
|
592
608
|
return {
|
|
593
609
|
tableState: i,
|
|
594
610
|
hasRecords: n,
|
|
595
611
|
hideTableToolbar: r,
|
|
596
612
|
handleStateChange: (a) => {
|
|
597
|
-
a.hasData ? n.value = !0 : a.state === "success" && !a.hasData && (!e || !t) && (n.value = !1), e && (t =
|
|
613
|
+
a.hasData ? n.value = !0 : a.state === "success" && !a.hasData && (!e || !t) && (n.value = !1), e && (t = ye(e)), i.value = { ...a };
|
|
598
614
|
}
|
|
599
615
|
};
|
|
600
616
|
}
|
|
601
617
|
const W = {
|
|
602
618
|
useAxios: rt,
|
|
603
|
-
useDebouncedFilter:
|
|
604
|
-
useDeleteUrlBuilder:
|
|
605
|
-
useErrors:
|
|
606
|
-
useExternalLinkCreator:
|
|
607
|
-
useFetcher:
|
|
608
|
-
useFetcherCacheKey:
|
|
609
|
-
useFetchUrlBuilder:
|
|
610
|
-
useHelpers:
|
|
611
|
-
useStringHelpers:
|
|
612
|
-
useI18n:
|
|
613
|
-
useGatewayFeatureSupported:
|
|
614
|
-
useTruncationDetector:
|
|
615
|
-
useValidators:
|
|
616
|
-
useSchemaProvider:
|
|
617
|
-
useSubSchema:
|
|
618
|
-
useTableState:
|
|
619
|
-
},
|
|
619
|
+
useDebouncedFilter: Ii,
|
|
620
|
+
useDeleteUrlBuilder: Fi,
|
|
621
|
+
useErrors: Oi,
|
|
622
|
+
useExternalLinkCreator: Li,
|
|
623
|
+
useFetcher: Bi,
|
|
624
|
+
useFetcherCacheKey: Gt,
|
|
625
|
+
useFetchUrlBuilder: Jt,
|
|
626
|
+
useHelpers: Wt,
|
|
627
|
+
useStringHelpers: Ri,
|
|
628
|
+
useI18n: qe,
|
|
629
|
+
useGatewayFeatureSupported: Pi,
|
|
630
|
+
useTruncationDetector: Ui,
|
|
631
|
+
useValidators: qi,
|
|
632
|
+
useSchemaProvider: Hi,
|
|
633
|
+
useSubSchema: Vi,
|
|
634
|
+
useTableState: Yi
|
|
635
|
+
}, Wi = {
|
|
620
636
|
key: 0,
|
|
621
637
|
class: "config-card-fieldset-title"
|
|
622
|
-
},
|
|
638
|
+
}, Ji = /* @__PURE__ */ z({
|
|
623
639
|
__name: "JsonCardItem",
|
|
624
640
|
props: {
|
|
625
641
|
item: {
|
|
@@ -636,25 +652,25 @@ const W = {
|
|
|
636
652
|
}
|
|
637
653
|
},
|
|
638
654
|
setup(e) {
|
|
639
|
-
const t = e, { i18n: { t: n } } = W.useI18n(), { convertKeyToTitle: i } = W.useStringHelpers(), r =
|
|
655
|
+
const t = e, { i18n: { t: n } } = W.useI18n(), { convertKeyToTitle: i } = W.useStringHelpers(), r = $(() => t.item.key ?? "json-array-item"), o = $(() => t.item.value ?? t.item), a = $(() => {
|
|
640
656
|
const l = JSON.parse(JSON.stringify(o.value));
|
|
641
657
|
return t.isArrayItem && delete l.name, l;
|
|
642
|
-
}), s =
|
|
658
|
+
}), s = $(() => {
|
|
643
659
|
var l;
|
|
644
660
|
return t.isArrayItem ? (l = o.value) != null && l.name ? i(o.value.name, "_") : n("baseConfigCard.general.entryTitle", { index: t.index }) : "";
|
|
645
661
|
});
|
|
646
|
-
return (l, c) => (m(),
|
|
662
|
+
return (l, c) => (m(), j(De(e.isArrayItem ? "fieldset" : "div"), {
|
|
647
663
|
class: fe(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
648
664
|
}, {
|
|
649
|
-
default:
|
|
650
|
-
e.isArrayItem ? (m(), S("legend",
|
|
651
|
-
|
|
652
|
-
])) :
|
|
653
|
-
(m(!0), S(ue, null, ce(Object.keys(a.value), (d, u) => (m(),
|
|
665
|
+
default: k(() => [
|
|
666
|
+
e.isArrayItem ? (m(), S("legend", Wi, [
|
|
667
|
+
B("b", null, L(s.value), 1)
|
|
668
|
+
])) : M("", !0),
|
|
669
|
+
(m(!0), S(ue, null, ce(Object.keys(a.value), (d, u) => (m(), j(Xt, {
|
|
654
670
|
key: `${r.value}-property-${u}`,
|
|
655
671
|
item: {
|
|
656
672
|
key: d,
|
|
657
|
-
label:
|
|
673
|
+
label: T(i)(d),
|
|
658
674
|
value: a.value[d]
|
|
659
675
|
}
|
|
660
676
|
}, null, 8, ["item"]))), 128))
|
|
@@ -667,7 +683,7 @@ const W = {
|
|
|
667
683
|
for (const [i, r] of t)
|
|
668
684
|
n[i] = r;
|
|
669
685
|
return n;
|
|
670
|
-
},
|
|
686
|
+
}, Zt = /* @__PURE__ */ se(Ji, [["__scopeId", "data-v-dc1e39a1"]]), Gi = /* @__PURE__ */ z({
|
|
671
687
|
__name: "InternalLinkItem",
|
|
672
688
|
props: {
|
|
673
689
|
item: {
|
|
@@ -681,20 +697,20 @@ const W = {
|
|
|
681
697
|
return (n, i) => {
|
|
682
698
|
const r = P("KButton");
|
|
683
699
|
return m(), S("div", null, [
|
|
684
|
-
|
|
700
|
+
K(r, {
|
|
685
701
|
appearance: "tertiary",
|
|
686
702
|
class: "navigation-button",
|
|
687
703
|
onClick: i[0] || (i[0] = (o) => n.$emit("navigation-click", e.item))
|
|
688
704
|
}, {
|
|
689
|
-
default:
|
|
690
|
-
|
|
705
|
+
default: k(() => [
|
|
706
|
+
U(L(e.item.value || T(t)("baseConfigCard.commonFields.link")), 1)
|
|
691
707
|
]),
|
|
692
708
|
_: 1
|
|
693
709
|
})
|
|
694
710
|
]);
|
|
695
711
|
};
|
|
696
712
|
}
|
|
697
|
-
}),
|
|
713
|
+
}), zi = /* @__PURE__ */ se(Gi, [["__scopeId", "data-v-2feb8c2e"]]), Qi = /* @__PURE__ */ z({
|
|
698
714
|
__name: "StatusBadge",
|
|
699
715
|
props: {
|
|
700
716
|
status: {
|
|
@@ -706,21 +722,21 @@ const W = {
|
|
|
706
722
|
const { i18n: { t } } = W.useI18n();
|
|
707
723
|
return (n, i) => {
|
|
708
724
|
const r = P("KBadge");
|
|
709
|
-
return m(),
|
|
725
|
+
return m(), j(r, {
|
|
710
726
|
appearance: e.status ? "success" : "neutral"
|
|
711
727
|
}, {
|
|
712
|
-
default:
|
|
713
|
-
|
|
728
|
+
default: k(() => [
|
|
729
|
+
U(L(e.status ? T(t)("baseConfigCard.statusBadge.enabledLabel") : T(t)("baseConfigCard.statusBadge.disabledLabel")), 1)
|
|
714
730
|
]),
|
|
715
731
|
_: 1
|
|
716
732
|
}, 8, ["appearance"]);
|
|
717
733
|
};
|
|
718
734
|
}
|
|
719
|
-
}),
|
|
735
|
+
}), Zi = "#0044f4", Xi = "#e0e4ea", er = "#afb7c5", tr = "#0044f4", nr = "1px", ir = "16px", rr = "20px", ar = { class: "config-card-details-row" }, or = ["data-testid"], lr = ["data-testid"], sr = ["data-testid"], cr = ["data-testid"], ur = { key: 1 }, dr = ["data-testid"], fr = ["data-testid"], pr = ["data-testid"], mr = ["data-testid"], yr = {
|
|
720
736
|
name: "ConfigCardItem",
|
|
721
|
-
components: { JsonCardItem:
|
|
722
|
-
},
|
|
723
|
-
...
|
|
737
|
+
components: { JsonCardItem: Zt, StatusBadge: Qi, InternalLinkItem: zi }
|
|
738
|
+
}, gr = /* @__PURE__ */ z({
|
|
739
|
+
...yr,
|
|
724
740
|
props: {
|
|
725
741
|
item: {
|
|
726
742
|
type: Object,
|
|
@@ -739,17 +755,17 @@ const W = {
|
|
|
739
755
|
},
|
|
740
756
|
emits: ["navigation-click"],
|
|
741
757
|
setup(e, { emit: t }) {
|
|
742
|
-
Ut((
|
|
743
|
-
v70f369b3: p.value ? "none" : `solid ${
|
|
758
|
+
Ut((Y) => ({
|
|
759
|
+
v70f369b3: p.value ? "none" : `solid ${T(nr)} ${T(Xi)}`,
|
|
744
760
|
v67c2fae6: u.value && c.value ? "block" : "flex",
|
|
745
761
|
v847b138c: u.value && c.value ? "100%" : n.slim ? "50%" : "25%",
|
|
746
762
|
v847687d6: u.value && c.value ? "100%" : n.slim ? "50%" : "75%"
|
|
747
763
|
}));
|
|
748
|
-
const n = e, i = t, r =
|
|
749
|
-
var
|
|
750
|
-
return n.item.type ? n.item.type : (
|
|
751
|
-
}), x =
|
|
752
|
-
switch (
|
|
764
|
+
const n = e, i = t, r = Gn(), o = Pe(), { i18n: { t: a, formatIsoDate: s, formatUnixTimeStamp: l } } = W.useI18n(), c = $(() => n.item.value !== void 0 && n.item.value !== null && n.item.value !== ""), d = $(() => !!(n.item.tooltip || o["label-tooltip"])), u = $(() => n.item.type === V.Json || n.item.type === V.JsonArray), p = $(() => n.item.type === V.JsonArray), g = W.useSubSchema(n.item.key), y = $(() => {
|
|
765
|
+
var Y;
|
|
766
|
+
return n.item.type ? n.item.type : (Y = g == null ? void 0 : g.value) != null && Y.encrypted ? V.Redacted : void 0;
|
|
767
|
+
}), x = $(() => {
|
|
768
|
+
switch (y.value) {
|
|
753
769
|
case V.ID:
|
|
754
770
|
return {
|
|
755
771
|
tag: "KCopy",
|
|
@@ -829,8 +845,8 @@ const W = {
|
|
|
829
845
|
attrs: {
|
|
830
846
|
"data-testid": `${n.item.key}-internal-link`,
|
|
831
847
|
item: n.item,
|
|
832
|
-
onNavigationClick: (
|
|
833
|
-
i("navigation-click",
|
|
848
|
+
onNavigationClick: (Y) => {
|
|
849
|
+
i("navigation-click", Y);
|
|
834
850
|
}
|
|
835
851
|
}
|
|
836
852
|
};
|
|
@@ -879,24 +895,24 @@ const W = {
|
|
|
879
895
|
text: n.item.value
|
|
880
896
|
};
|
|
881
897
|
}
|
|
882
|
-
}),
|
|
883
|
-
return (
|
|
884
|
-
const w = P("KTooltip"),
|
|
885
|
-
return m(), S("div",
|
|
886
|
-
|
|
898
|
+
}), h = N(), A = N(), { isTruncated: C } = W.useTruncationDetector(h), { isTruncated: E } = W.useTruncationDetector(A);
|
|
899
|
+
return (Y, X) => {
|
|
900
|
+
const w = P("KTooltip"), _ = P("KLabel"), O = P("KBadge"), f = P("KCopy");
|
|
901
|
+
return m(), S("div", ar, [
|
|
902
|
+
B("div", {
|
|
887
903
|
class: "config-card-details-label",
|
|
888
904
|
"data-testid": `${e.item.key}-label`
|
|
889
905
|
}, [
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
default:
|
|
893
|
-
|
|
894
|
-
text:
|
|
906
|
+
D(Y.$slots, "label", { item: e.item }, () => [
|
|
907
|
+
K(_, { "tooltip-attributes": { maxWidth: "500px" } }, Se({
|
|
908
|
+
default: k(() => [
|
|
909
|
+
K(w, {
|
|
910
|
+
text: T(C) ? e.item.label : ""
|
|
895
911
|
}, {
|
|
896
|
-
default:
|
|
897
|
-
|
|
912
|
+
default: k(() => [
|
|
913
|
+
B("span", {
|
|
898
914
|
ref_key: "labelContent",
|
|
899
|
-
ref:
|
|
915
|
+
ref: h,
|
|
900
916
|
class: "label-content"
|
|
901
917
|
}, L(e.item.label), 513)
|
|
902
918
|
]),
|
|
@@ -907,90 +923,90 @@ const W = {
|
|
|
907
923
|
}, [
|
|
908
924
|
d.value ? {
|
|
909
925
|
name: "tooltip",
|
|
910
|
-
fn:
|
|
911
|
-
|
|
926
|
+
fn: k(() => [
|
|
927
|
+
B("div", {
|
|
912
928
|
"data-testid": `${e.item.key}-label-tooltip`
|
|
913
929
|
}, [
|
|
914
|
-
|
|
915
|
-
|
|
930
|
+
D(Y.$slots, "label-tooltip", {}, () => [
|
|
931
|
+
U(L(e.item.tooltip), 1)
|
|
916
932
|
], !0)
|
|
917
|
-
], 8,
|
|
933
|
+
], 8, lr)
|
|
918
934
|
]),
|
|
919
935
|
key: "0"
|
|
920
936
|
} : void 0
|
|
921
937
|
]), 1024)
|
|
922
938
|
], !0)
|
|
923
|
-
], 8,
|
|
924
|
-
|
|
939
|
+
], 8, or),
|
|
940
|
+
B("div", {
|
|
925
941
|
class: "config-card-details-value",
|
|
926
942
|
"data-testid": `${e.item.key}-property-value`
|
|
927
943
|
}, [
|
|
928
|
-
|
|
944
|
+
D(Y.$slots, e.item.key, {
|
|
929
945
|
rowValue: e.item.value
|
|
930
946
|
}, () => [
|
|
931
|
-
c.value ? (m(), S("div",
|
|
932
|
-
(m(),
|
|
933
|
-
default:
|
|
947
|
+
c.value ? (m(), S("div", ur, [
|
|
948
|
+
(m(), j(De(x.value.tag), zn(Qn(x.value.attrs)), {
|
|
949
|
+
default: k(() => [
|
|
934
950
|
x.value.additionalComponent === "KBadge" ? (m(), S("div", {
|
|
935
951
|
key: 0,
|
|
936
952
|
"data-testid": `${e.item.key}-badge-tags`
|
|
937
953
|
}, [
|
|
938
|
-
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(),
|
|
954
|
+
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(), j(O, {
|
|
939
955
|
key: `${e.item.key}-badge-tag-${b}`,
|
|
940
956
|
class: "config-badge",
|
|
941
957
|
"data-testid": `${e.item.key}-badge-tag-${b}`,
|
|
942
958
|
tooltip: v,
|
|
943
959
|
"truncation-tooltip": ""
|
|
944
960
|
}, {
|
|
945
|
-
default:
|
|
946
|
-
|
|
961
|
+
default: k(() => [
|
|
962
|
+
U(L(v), 1)
|
|
947
963
|
]),
|
|
948
964
|
_: 2
|
|
949
965
|
}, 1032, ["data-testid", "tooltip"]))), 128))
|
|
950
|
-
], 8,
|
|
966
|
+
], 8, dr)) : x.value.additionalComponent === "KCopy" ? (m(), S("div", {
|
|
951
967
|
key: 1,
|
|
952
968
|
class: "copy-uuid-array",
|
|
953
969
|
"data-testid": `${e.item.key}-copy-uuid-array`
|
|
954
970
|
}, [
|
|
955
|
-
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(),
|
|
971
|
+
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(), j(f, qt({ ref_for: !0 }, x.value.childAttrs, {
|
|
956
972
|
key: `${e.item.key}-copy-uuid-${b}`,
|
|
957
973
|
"data-testid": `${e.item.key}-copy-uuid-${b}`,
|
|
958
974
|
text: v
|
|
959
975
|
}), null, 16, ["data-testid", "text"]))), 128))
|
|
960
|
-
], 8,
|
|
976
|
+
], 8, fr)) : x.value.additionalComponent === "KMethodBadge" ? (m(), S("div", {
|
|
961
977
|
key: 2,
|
|
962
978
|
class: "method-badge-array",
|
|
963
979
|
"data-testid": `${e.item.key}-badge-methods`
|
|
964
980
|
}, [
|
|
965
|
-
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(),
|
|
981
|
+
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(), j(O, {
|
|
966
982
|
key: `${e.item.key}-badge-method-${b}`,
|
|
967
|
-
appearance: Object.values(
|
|
983
|
+
appearance: Object.values(T(ii)).includes(v.toLowerCase()) ? v.toLowerCase() : "custom",
|
|
968
984
|
class: "config-badge",
|
|
969
985
|
"data-testid": `${e.item.key}-badge-method-${b}`
|
|
970
986
|
}, {
|
|
971
|
-
default:
|
|
972
|
-
|
|
987
|
+
default: k(() => [
|
|
988
|
+
U(L(v), 1)
|
|
973
989
|
]),
|
|
974
990
|
_: 2
|
|
975
991
|
}, 1032, ["appearance", "data-testid"]))), 128))
|
|
976
|
-
], 8,
|
|
992
|
+
], 8, pr)) : x.value.additionalComponent === "JsonCardItem" ? (m(), S("div", {
|
|
977
993
|
key: 3,
|
|
978
994
|
"data-testid": `${n.item.key}-json-array-content`
|
|
979
995
|
}, [
|
|
980
|
-
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(),
|
|
996
|
+
(m(!0), S(ue, null, ce(e.item.value, (v, b) => (m(), j(Zt, {
|
|
981
997
|
key: `json-array-item-${b}`,
|
|
982
998
|
index: b,
|
|
983
999
|
"is-array-item": "",
|
|
984
1000
|
item: v
|
|
985
1001
|
}, null, 8, ["index", "item"]))), 128))
|
|
986
|
-
], 8,
|
|
1002
|
+
], 8, mr)) : (m(), j(w, {
|
|
987
1003
|
key: 4,
|
|
988
|
-
text:
|
|
1004
|
+
text: T(E) ? e.item.value : ""
|
|
989
1005
|
}, {
|
|
990
|
-
default:
|
|
991
|
-
|
|
1006
|
+
default: k(() => [
|
|
1007
|
+
B("span", {
|
|
992
1008
|
ref_key: "textContent",
|
|
993
|
-
ref:
|
|
1009
|
+
ref: A,
|
|
994
1010
|
class: fe(["attrs-data-text", { truncated: e.truncated }])
|
|
995
1011
|
}, L(x.value.text), 3)
|
|
996
1012
|
]),
|
|
@@ -1002,16 +1018,16 @@ const W = {
|
|
|
1002
1018
|
])) : (m(), S("div", {
|
|
1003
1019
|
key: 0,
|
|
1004
1020
|
"data-testid": `${e.item.key}-no-value`
|
|
1005
|
-
}, " – ", 8,
|
|
1021
|
+
}, " – ", 8, cr))
|
|
1006
1022
|
], !0)
|
|
1007
|
-
], 8,
|
|
1023
|
+
], 8, sr)
|
|
1008
1024
|
]);
|
|
1009
1025
|
};
|
|
1010
1026
|
}
|
|
1011
|
-
}),
|
|
1027
|
+
}), Xt = /* @__PURE__ */ se(gr, [["__scopeId", "data-v-66d61bea"]]), hr = { class: "json-config config-card-code-block" }, vr = {
|
|
1012
1028
|
key: 0,
|
|
1013
1029
|
class: "json-endpoint"
|
|
1014
|
-
},
|
|
1030
|
+
}, en = /* @__PURE__ */ z({
|
|
1015
1031
|
__name: "JsonCodeBlock",
|
|
1016
1032
|
props: {
|
|
1017
1033
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -1042,7 +1058,7 @@ const W = {
|
|
|
1042
1058
|
Ut((r) => ({
|
|
1043
1059
|
eca0976a: `${i.value}ch`
|
|
1044
1060
|
}));
|
|
1045
|
-
const t = e, n =
|
|
1061
|
+
const t = e, n = $(() => t.entityRecord), i = $(() => {
|
|
1046
1062
|
var a;
|
|
1047
1063
|
if (!t.fetcherUrl)
|
|
1048
1064
|
return 0;
|
|
@@ -1051,86 +1067,86 @@ const W = {
|
|
|
1051
1067
|
});
|
|
1052
1068
|
return (r, o) => {
|
|
1053
1069
|
const a = P("KBadge"), s = P("KCodeBlock");
|
|
1054
|
-
return m(), S("div",
|
|
1055
|
-
t.fetcherUrl ? (m(), S("div",
|
|
1056
|
-
|
|
1070
|
+
return m(), S("div", hr, [
|
|
1071
|
+
t.fetcherUrl ? (m(), S("div", vr, [
|
|
1072
|
+
K(a, {
|
|
1057
1073
|
appearance: t.requestMethod
|
|
1058
1074
|
}, {
|
|
1059
|
-
default:
|
|
1060
|
-
|
|
1075
|
+
default: k(() => [
|
|
1076
|
+
U(L(t.requestMethod), 1)
|
|
1061
1077
|
]),
|
|
1062
1078
|
_: 1
|
|
1063
1079
|
}, 8, ["appearance"]),
|
|
1064
|
-
|
|
1080
|
+
K(s, {
|
|
1065
1081
|
id: "json-endpoint-codeblock",
|
|
1066
1082
|
code: t.fetcherUrl,
|
|
1067
1083
|
language: "json",
|
|
1068
1084
|
"single-line": "",
|
|
1069
1085
|
theme: "dark"
|
|
1070
1086
|
}, null, 8, ["code"])
|
|
1071
|
-
])) :
|
|
1072
|
-
t.entityRecord ? (m(),
|
|
1087
|
+
])) : M("", !0),
|
|
1088
|
+
t.entityRecord ? (m(), j(s, {
|
|
1073
1089
|
key: 1,
|
|
1074
1090
|
id: "json-codeblock",
|
|
1075
1091
|
class: fe({ "json-content": t.fetcherUrl }),
|
|
1076
1092
|
code: JSON.stringify(n.value, null, 2),
|
|
1077
1093
|
language: "json",
|
|
1078
1094
|
theme: "dark"
|
|
1079
|
-
}, null, 8, ["class", "code"])) :
|
|
1095
|
+
}, null, 8, ["class", "code"])) : M("", !0)
|
|
1080
1096
|
]);
|
|
1081
1097
|
};
|
|
1082
1098
|
}
|
|
1083
1099
|
});
|
|
1084
|
-
/*! js-yaml 4.1.
|
|
1085
|
-
function
|
|
1100
|
+
/*! js-yaml 4.1.1 https://github.com/nodeca/js-yaml @license MIT */
|
|
1101
|
+
function tn(e) {
|
|
1086
1102
|
return typeof e > "u" || e === null;
|
|
1087
1103
|
}
|
|
1088
|
-
function
|
|
1104
|
+
function br(e) {
|
|
1089
1105
|
return typeof e == "object" && e !== null;
|
|
1090
1106
|
}
|
|
1091
|
-
function
|
|
1092
|
-
return Array.isArray(e) ? e :
|
|
1107
|
+
function xr(e) {
|
|
1108
|
+
return Array.isArray(e) ? e : tn(e) ? [] : [e];
|
|
1093
1109
|
}
|
|
1094
|
-
function
|
|
1110
|
+
function Cr(e, t) {
|
|
1095
1111
|
var n, i, r, o;
|
|
1096
1112
|
if (t)
|
|
1097
1113
|
for (o = Object.keys(t), n = 0, i = o.length; n < i; n += 1)
|
|
1098
1114
|
r = o[n], e[r] = t[r];
|
|
1099
1115
|
return e;
|
|
1100
1116
|
}
|
|
1101
|
-
function
|
|
1117
|
+
function kr(e, t) {
|
|
1102
1118
|
var n = "", i;
|
|
1103
1119
|
for (i = 0; i < t; i += 1)
|
|
1104
1120
|
n += e;
|
|
1105
1121
|
return n;
|
|
1106
1122
|
}
|
|
1107
|
-
function
|
|
1123
|
+
function Ar(e) {
|
|
1108
1124
|
return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
|
|
1109
1125
|
}
|
|
1110
|
-
var
|
|
1111
|
-
isNothing:
|
|
1112
|
-
isObject:
|
|
1113
|
-
toArray:
|
|
1114
|
-
repeat:
|
|
1115
|
-
isNegativeZero:
|
|
1116
|
-
extend:
|
|
1126
|
+
var _r = tn, wr = br, Sr = xr, $r = kr, Tr = Ar, Er = Cr, ee = {
|
|
1127
|
+
isNothing: _r,
|
|
1128
|
+
isObject: wr,
|
|
1129
|
+
toArray: Sr,
|
|
1130
|
+
repeat: $r,
|
|
1131
|
+
isNegativeZero: Tr,
|
|
1132
|
+
extend: Er
|
|
1117
1133
|
};
|
|
1118
|
-
function
|
|
1134
|
+
function nn(e, t) {
|
|
1119
1135
|
var n = "", i = e.reason || "(unknown reason)";
|
|
1120
1136
|
return e.mark ? (e.mark.name && (n += 'in "' + e.mark.name + '" '), n += "(" + (e.mark.line + 1) + ":" + (e.mark.column + 1) + ")", !t && e.mark.snippet && (n += `
|
|
1121
1137
|
|
|
1122
1138
|
` + e.mark.snippet), i + " " + n) : i;
|
|
1123
1139
|
}
|
|
1124
1140
|
function Ie(e, t) {
|
|
1125
|
-
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = t, this.message =
|
|
1141
|
+
Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = t, this.message = nn(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack || "";
|
|
1126
1142
|
}
|
|
1127
1143
|
Ie.prototype = Object.create(Error.prototype);
|
|
1128
1144
|
Ie.prototype.constructor = Ie;
|
|
1129
1145
|
Ie.prototype.toString = function(t) {
|
|
1130
|
-
return this.name + ": " +
|
|
1146
|
+
return this.name + ": " + nn(this, t);
|
|
1131
1147
|
};
|
|
1132
1148
|
var oe = Ie;
|
|
1133
|
-
function
|
|
1149
|
+
function Ye(e, t, n, i, r) {
|
|
1134
1150
|
var o = "", a = "", s = Math.floor(r / 2) - 1;
|
|
1135
1151
|
return i - t > s && (o = " ... ", t = i - s + o.length), n - i > s && (a = " ...", n = i + s - a.length), {
|
|
1136
1152
|
str: o + e.slice(t, n).replace(/\t/g, "→") + a,
|
|
@@ -1138,10 +1154,10 @@ function Ve(e, t, n, i, r) {
|
|
|
1138
1154
|
// relative position
|
|
1139
1155
|
};
|
|
1140
1156
|
}
|
|
1141
|
-
function
|
|
1157
|
+
function We(e, t) {
|
|
1142
1158
|
return ee.repeat(" ", t - e.length) + e;
|
|
1143
1159
|
}
|
|
1144
|
-
function
|
|
1160
|
+
function Ir(e, t) {
|
|
1145
1161
|
if (t = Object.create(t || null), !e.buffer) return null;
|
|
1146
1162
|
t.maxLength || (t.maxLength = 79), typeof t.indent != "number" && (t.indent = 1), typeof t.linesBefore != "number" && (t.linesBefore = 3), typeof t.linesAfter != "number" && (t.linesAfter = 2);
|
|
1147
1163
|
for (var n = /\r?\n|\r|\0/g, i = [0], r = [], o, a = -1; o = n.exec(e.buffer); )
|
|
@@ -1149,28 +1165,28 @@ function Sr(e, t) {
|
|
|
1149
1165
|
a < 0 && (a = i.length - 1);
|
|
1150
1166
|
var s = "", l, c, d = Math.min(e.line + t.linesAfter, r.length).toString().length, u = t.maxLength - (t.indent + d + 3);
|
|
1151
1167
|
for (l = 1; l <= t.linesBefore && !(a - l < 0); l++)
|
|
1152
|
-
c =
|
|
1168
|
+
c = Ye(
|
|
1153
1169
|
e.buffer,
|
|
1154
1170
|
i[a - l],
|
|
1155
1171
|
r[a - l],
|
|
1156
1172
|
e.position - (i[a] - i[a - l]),
|
|
1157
1173
|
u
|
|
1158
|
-
), s = ee.repeat(" ", t.indent) +
|
|
1174
|
+
), s = ee.repeat(" ", t.indent) + We((e.line - l + 1).toString(), d) + " | " + c.str + `
|
|
1159
1175
|
` + s;
|
|
1160
|
-
for (c =
|
|
1176
|
+
for (c = Ye(e.buffer, i[a], r[a], e.position, u), s += ee.repeat(" ", t.indent) + We((e.line + 1).toString(), d) + " | " + c.str + `
|
|
1161
1177
|
`, s += ee.repeat("-", t.indent + d + 3 + c.pos) + `^
|
|
1162
1178
|
`, l = 1; l <= t.linesAfter && !(a + l >= r.length); l++)
|
|
1163
|
-
c =
|
|
1179
|
+
c = Ye(
|
|
1164
1180
|
e.buffer,
|
|
1165
1181
|
i[a + l],
|
|
1166
1182
|
r[a + l],
|
|
1167
1183
|
e.position - (i[a] - i[a + l]),
|
|
1168
1184
|
u
|
|
1169
|
-
), s += ee.repeat(" ", t.indent) +
|
|
1185
|
+
), s += ee.repeat(" ", t.indent) + We((e.line + l + 1).toString(), d) + " | " + c.str + `
|
|
1170
1186
|
`;
|
|
1171
1187
|
return s.replace(/\n$/, "");
|
|
1172
1188
|
}
|
|
1173
|
-
var
|
|
1189
|
+
var Fr = Ir, Or = [
|
|
1174
1190
|
"kind",
|
|
1175
1191
|
"multi",
|
|
1176
1192
|
"resolve",
|
|
@@ -1181,12 +1197,12 @@ var $r = Sr, Tr = [
|
|
|
1181
1197
|
"representName",
|
|
1182
1198
|
"defaultStyle",
|
|
1183
1199
|
"styleAliases"
|
|
1184
|
-
],
|
|
1200
|
+
], Lr = [
|
|
1185
1201
|
"scalar",
|
|
1186
1202
|
"sequence",
|
|
1187
1203
|
"mapping"
|
|
1188
1204
|
];
|
|
1189
|
-
function
|
|
1205
|
+
function Br(e) {
|
|
1190
1206
|
var t = {};
|
|
1191
1207
|
return e !== null && Object.keys(e).forEach(function(n) {
|
|
1192
1208
|
e[n].forEach(function(i) {
|
|
@@ -1194,18 +1210,18 @@ function Er(e) {
|
|
|
1194
1210
|
});
|
|
1195
1211
|
}), t;
|
|
1196
1212
|
}
|
|
1197
|
-
function
|
|
1213
|
+
function Rr(e, t) {
|
|
1198
1214
|
if (t = t || {}, Object.keys(t).forEach(function(n) {
|
|
1199
|
-
if (
|
|
1215
|
+
if (Or.indexOf(n) === -1)
|
|
1200
1216
|
throw new oe('Unknown option "' + n + '" is met in definition of "' + e + '" YAML type.');
|
|
1201
1217
|
}), this.options = t, this.tag = e, this.kind = t.kind || null, this.resolve = t.resolve || function() {
|
|
1202
1218
|
return !0;
|
|
1203
1219
|
}, this.construct = t.construct || function(n) {
|
|
1204
1220
|
return n;
|
|
1205
|
-
}, this.instanceOf = t.instanceOf || null, this.predicate = t.predicate || null, this.represent = t.represent || null, this.representName = t.representName || null, this.defaultStyle = t.defaultStyle || null, this.multi = t.multi || !1, this.styleAliases =
|
|
1221
|
+
}, this.instanceOf = t.instanceOf || null, this.predicate = t.predicate || null, this.represent = t.represent || null, this.representName = t.representName || null, this.defaultStyle = t.defaultStyle || null, this.multi = t.multi || !1, this.styleAliases = Br(t.styleAliases || null), Lr.indexOf(this.kind) === -1)
|
|
1206
1222
|
throw new oe('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.');
|
|
1207
1223
|
}
|
|
1208
|
-
var ne =
|
|
1224
|
+
var ne = Rr;
|
|
1209
1225
|
function At(e, t) {
|
|
1210
1226
|
var n = [];
|
|
1211
1227
|
return e[t].forEach(function(i) {
|
|
@@ -1215,7 +1231,7 @@ function At(e, t) {
|
|
|
1215
1231
|
}), n[r] = i;
|
|
1216
1232
|
}), n;
|
|
1217
1233
|
}
|
|
1218
|
-
function
|
|
1234
|
+
function Kr() {
|
|
1219
1235
|
var e = {
|
|
1220
1236
|
scalar: {},
|
|
1221
1237
|
sequence: {},
|
|
@@ -1235,10 +1251,10 @@ function Or() {
|
|
|
1235
1251
|
arguments[t].forEach(i);
|
|
1236
1252
|
return e;
|
|
1237
1253
|
}
|
|
1238
|
-
function
|
|
1254
|
+
function Qe(e) {
|
|
1239
1255
|
return this.extend(e);
|
|
1240
1256
|
}
|
|
1241
|
-
|
|
1257
|
+
Qe.prototype.extend = function(t) {
|
|
1242
1258
|
var n = [], i = [];
|
|
1243
1259
|
if (t instanceof ne)
|
|
1244
1260
|
i.push(t);
|
|
@@ -1259,47 +1275,47 @@ ze.prototype.extend = function(t) {
|
|
|
1259
1275
|
if (!(o instanceof ne))
|
|
1260
1276
|
throw new oe("Specified list of YAML types (or a single Type object) contains a non-Type object.");
|
|
1261
1277
|
});
|
|
1262
|
-
var r = Object.create(
|
|
1263
|
-
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(i), r.compiledImplicit = At(r, "implicit"), r.compiledExplicit = At(r, "explicit"), r.compiledTypeMap =
|
|
1278
|
+
var r = Object.create(Qe.prototype);
|
|
1279
|
+
return r.implicit = (this.implicit || []).concat(n), r.explicit = (this.explicit || []).concat(i), r.compiledImplicit = At(r, "implicit"), r.compiledExplicit = At(r, "explicit"), r.compiledTypeMap = Kr(r.compiledImplicit, r.compiledExplicit), r;
|
|
1264
1280
|
};
|
|
1265
|
-
var
|
|
1281
|
+
var rn = Qe, an = new ne("tag:yaml.org,2002:str", {
|
|
1266
1282
|
kind: "scalar",
|
|
1267
1283
|
construct: function(e) {
|
|
1268
1284
|
return e !== null ? e : "";
|
|
1269
1285
|
}
|
|
1270
|
-
}),
|
|
1286
|
+
}), on = new ne("tag:yaml.org,2002:seq", {
|
|
1271
1287
|
kind: "sequence",
|
|
1272
1288
|
construct: function(e) {
|
|
1273
1289
|
return e !== null ? e : [];
|
|
1274
1290
|
}
|
|
1275
|
-
}),
|
|
1291
|
+
}), ln = new ne("tag:yaml.org,2002:map", {
|
|
1276
1292
|
kind: "mapping",
|
|
1277
1293
|
construct: function(e) {
|
|
1278
1294
|
return e !== null ? e : {};
|
|
1279
1295
|
}
|
|
1280
|
-
}),
|
|
1296
|
+
}), sn = new rn({
|
|
1281
1297
|
explicit: [
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1298
|
+
an,
|
|
1299
|
+
on,
|
|
1300
|
+
ln
|
|
1285
1301
|
]
|
|
1286
1302
|
});
|
|
1287
|
-
function
|
|
1303
|
+
function Nr(e) {
|
|
1288
1304
|
if (e === null) return !0;
|
|
1289
1305
|
var t = e.length;
|
|
1290
1306
|
return t === 1 && e === "~" || t === 4 && (e === "null" || e === "Null" || e === "NULL");
|
|
1291
1307
|
}
|
|
1292
|
-
function
|
|
1308
|
+
function Mr() {
|
|
1293
1309
|
return null;
|
|
1294
1310
|
}
|
|
1295
|
-
function
|
|
1311
|
+
function jr(e) {
|
|
1296
1312
|
return e === null;
|
|
1297
1313
|
}
|
|
1298
|
-
var
|
|
1314
|
+
var cn = new ne("tag:yaml.org,2002:null", {
|
|
1299
1315
|
kind: "scalar",
|
|
1300
|
-
resolve:
|
|
1301
|
-
construct:
|
|
1302
|
-
predicate:
|
|
1316
|
+
resolve: Nr,
|
|
1317
|
+
construct: Mr,
|
|
1318
|
+
predicate: jr,
|
|
1303
1319
|
represent: {
|
|
1304
1320
|
canonical: function() {
|
|
1305
1321
|
return "~";
|
|
@@ -1319,22 +1335,22 @@ var dn = new ne("tag:yaml.org,2002:null", {
|
|
|
1319
1335
|
},
|
|
1320
1336
|
defaultStyle: "lowercase"
|
|
1321
1337
|
});
|
|
1322
|
-
function
|
|
1338
|
+
function Dr(e) {
|
|
1323
1339
|
if (e === null) return !1;
|
|
1324
1340
|
var t = e.length;
|
|
1325
1341
|
return t === 4 && (e === "true" || e === "True" || e === "TRUE") || t === 5 && (e === "false" || e === "False" || e === "FALSE");
|
|
1326
1342
|
}
|
|
1327
|
-
function
|
|
1343
|
+
function Pr(e) {
|
|
1328
1344
|
return e === "true" || e === "True" || e === "TRUE";
|
|
1329
1345
|
}
|
|
1330
|
-
function
|
|
1346
|
+
function Ur(e) {
|
|
1331
1347
|
return Object.prototype.toString.call(e) === "[object Boolean]";
|
|
1332
1348
|
}
|
|
1333
|
-
var
|
|
1349
|
+
var un = new ne("tag:yaml.org,2002:bool", {
|
|
1334
1350
|
kind: "scalar",
|
|
1335
|
-
resolve:
|
|
1336
|
-
construct:
|
|
1337
|
-
predicate:
|
|
1351
|
+
resolve: Dr,
|
|
1352
|
+
construct: Pr,
|
|
1353
|
+
predicate: Ur,
|
|
1338
1354
|
represent: {
|
|
1339
1355
|
lowercase: function(e) {
|
|
1340
1356
|
return e ? "true" : "false";
|
|
@@ -1348,16 +1364,16 @@ var fn = new ne("tag:yaml.org,2002:bool", {
|
|
|
1348
1364
|
},
|
|
1349
1365
|
defaultStyle: "lowercase"
|
|
1350
1366
|
});
|
|
1351
|
-
function
|
|
1367
|
+
function qr(e) {
|
|
1352
1368
|
return 48 <= e && e <= 57 || 65 <= e && e <= 70 || 97 <= e && e <= 102;
|
|
1353
1369
|
}
|
|
1354
|
-
function
|
|
1370
|
+
function Hr(e) {
|
|
1355
1371
|
return 48 <= e && e <= 55;
|
|
1356
1372
|
}
|
|
1357
|
-
function
|
|
1373
|
+
function Vr(e) {
|
|
1358
1374
|
return 48 <= e && e <= 57;
|
|
1359
1375
|
}
|
|
1360
|
-
function
|
|
1376
|
+
function Yr(e) {
|
|
1361
1377
|
if (e === null) return !1;
|
|
1362
1378
|
var t = e.length, n = 0, i = !1, r;
|
|
1363
1379
|
if (!t) return !1;
|
|
@@ -1374,7 +1390,7 @@ function Ur(e) {
|
|
|
1374
1390
|
if (r === "x") {
|
|
1375
1391
|
for (n++; n < t; n++)
|
|
1376
1392
|
if (r = e[n], r !== "_") {
|
|
1377
|
-
if (!
|
|
1393
|
+
if (!qr(e.charCodeAt(n))) return !1;
|
|
1378
1394
|
i = !0;
|
|
1379
1395
|
}
|
|
1380
1396
|
return i && r !== "_";
|
|
@@ -1382,7 +1398,7 @@ function Ur(e) {
|
|
|
1382
1398
|
if (r === "o") {
|
|
1383
1399
|
for (n++; n < t; n++)
|
|
1384
1400
|
if (r = e[n], r !== "_") {
|
|
1385
|
-
if (!
|
|
1401
|
+
if (!Hr(e.charCodeAt(n))) return !1;
|
|
1386
1402
|
i = !0;
|
|
1387
1403
|
}
|
|
1388
1404
|
return i && r !== "_";
|
|
@@ -1391,13 +1407,13 @@ function Ur(e) {
|
|
|
1391
1407
|
if (r === "_") return !1;
|
|
1392
1408
|
for (; n < t; n++)
|
|
1393
1409
|
if (r = e[n], r !== "_") {
|
|
1394
|
-
if (!
|
|
1410
|
+
if (!Vr(e.charCodeAt(n)))
|
|
1395
1411
|
return !1;
|
|
1396
1412
|
i = !0;
|
|
1397
1413
|
}
|
|
1398
1414
|
return !(!i || r === "_");
|
|
1399
1415
|
}
|
|
1400
|
-
function
|
|
1416
|
+
function Wr(e) {
|
|
1401
1417
|
var t = e, n = 1, i;
|
|
1402
1418
|
if (t.indexOf("_") !== -1 && (t = t.replace(/_/g, "")), i = t[0], (i === "-" || i === "+") && (i === "-" && (n = -1), t = t.slice(1), i = t[0]), t === "0") return 0;
|
|
1403
1419
|
if (i === "0") {
|
|
@@ -1407,14 +1423,14 @@ function qr(e) {
|
|
|
1407
1423
|
}
|
|
1408
1424
|
return n * parseInt(t, 10);
|
|
1409
1425
|
}
|
|
1410
|
-
function
|
|
1426
|
+
function Jr(e) {
|
|
1411
1427
|
return Object.prototype.toString.call(e) === "[object Number]" && e % 1 === 0 && !ee.isNegativeZero(e);
|
|
1412
1428
|
}
|
|
1413
|
-
var
|
|
1429
|
+
var dn = new ne("tag:yaml.org,2002:int", {
|
|
1414
1430
|
kind: "scalar",
|
|
1415
|
-
resolve:
|
|
1416
|
-
construct:
|
|
1417
|
-
predicate:
|
|
1431
|
+
resolve: Yr,
|
|
1432
|
+
construct: Wr,
|
|
1433
|
+
predicate: Jr,
|
|
1418
1434
|
represent: {
|
|
1419
1435
|
binary: function(e) {
|
|
1420
1436
|
return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1);
|
|
@@ -1437,21 +1453,21 @@ var pn = new ne("tag:yaml.org,2002:int", {
|
|
|
1437
1453
|
decimal: [10, "dec"],
|
|
1438
1454
|
hexadecimal: [16, "hex"]
|
|
1439
1455
|
}
|
|
1440
|
-
}),
|
|
1456
|
+
}), Gr = new RegExp(
|
|
1441
1457
|
// 2.5e4, 2.5 and integers
|
|
1442
1458
|
"^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"
|
|
1443
1459
|
);
|
|
1444
|
-
function
|
|
1445
|
-
return !(e === null || !
|
|
1460
|
+
function zr(e) {
|
|
1461
|
+
return !(e === null || !Gr.test(e) || // Quick hack to not allow integers end with `_`
|
|
1446
1462
|
// Probably should update regexp & check speed
|
|
1447
1463
|
e[e.length - 1] === "_");
|
|
1448
1464
|
}
|
|
1449
|
-
function
|
|
1465
|
+
function Qr(e) {
|
|
1450
1466
|
var t, n;
|
|
1451
1467
|
return t = e.replace(/_/g, "").toLowerCase(), n = t[0] === "-" ? -1 : 1, "+-".indexOf(t[0]) >= 0 && (t = t.slice(1)), t === ".inf" ? n === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : t === ".nan" ? NaN : n * parseFloat(t, 10);
|
|
1452
1468
|
}
|
|
1453
|
-
var
|
|
1454
|
-
function
|
|
1469
|
+
var Zr = /^[-+]?[0-9]+e/;
|
|
1470
|
+
function Xr(e, t) {
|
|
1455
1471
|
var n;
|
|
1456
1472
|
if (isNaN(e))
|
|
1457
1473
|
switch (t) {
|
|
@@ -1482,36 +1498,36 @@ function Gr(e, t) {
|
|
|
1482
1498
|
}
|
|
1483
1499
|
else if (ee.isNegativeZero(e))
|
|
1484
1500
|
return "-0.0";
|
|
1485
|
-
return n = e.toString(10),
|
|
1501
|
+
return n = e.toString(10), Zr.test(n) ? n.replace("e", ".e") : n;
|
|
1486
1502
|
}
|
|
1487
|
-
function
|
|
1503
|
+
function ea(e) {
|
|
1488
1504
|
return Object.prototype.toString.call(e) === "[object Number]" && (e % 1 !== 0 || ee.isNegativeZero(e));
|
|
1489
1505
|
}
|
|
1490
|
-
var
|
|
1506
|
+
var fn = new ne("tag:yaml.org,2002:float", {
|
|
1491
1507
|
kind: "scalar",
|
|
1492
|
-
resolve:
|
|
1493
|
-
construct:
|
|
1494
|
-
predicate:
|
|
1495
|
-
represent:
|
|
1508
|
+
resolve: zr,
|
|
1509
|
+
construct: Qr,
|
|
1510
|
+
predicate: ea,
|
|
1511
|
+
represent: Xr,
|
|
1496
1512
|
defaultStyle: "lowercase"
|
|
1497
|
-
}),
|
|
1513
|
+
}), pn = sn.extend({
|
|
1498
1514
|
implicit: [
|
|
1515
|
+
cn,
|
|
1516
|
+
un,
|
|
1499
1517
|
dn,
|
|
1500
|
-
fn
|
|
1501
|
-
pn,
|
|
1502
|
-
mn
|
|
1518
|
+
fn
|
|
1503
1519
|
]
|
|
1504
|
-
}),
|
|
1520
|
+
}), mn = pn, yn = new RegExp(
|
|
1505
1521
|
"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"
|
|
1506
|
-
),
|
|
1522
|
+
), gn = new RegExp(
|
|
1507
1523
|
"^([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]))?))?$"
|
|
1508
1524
|
);
|
|
1509
|
-
function
|
|
1510
|
-
return e === null ? !1 : yn.exec(e) !== null ||
|
|
1525
|
+
function ta(e) {
|
|
1526
|
+
return e === null ? !1 : yn.exec(e) !== null || gn.exec(e) !== null;
|
|
1511
1527
|
}
|
|
1512
|
-
function
|
|
1528
|
+
function na(e) {
|
|
1513
1529
|
var t, n, i, r, o, a, s, l = 0, c = null, d, u, p;
|
|
1514
|
-
if (t = yn.exec(e), t === null && (t =
|
|
1530
|
+
if (t = yn.exec(e), t === null && (t = gn.exec(e)), t === null) throw new Error("Date resolve error");
|
|
1515
1531
|
if (n = +t[1], i = +t[2] - 1, r = +t[3], !t[4])
|
|
1516
1532
|
return new Date(Date.UTC(n, i, r));
|
|
1517
1533
|
if (o = +t[4], a = +t[5], s = +t[6], t[7]) {
|
|
@@ -1521,25 +1537,25 @@ function Zr(e) {
|
|
|
1521
1537
|
}
|
|
1522
1538
|
return t[9] && (d = +t[10], u = +(t[11] || 0), c = (d * 60 + u) * 6e4, t[9] === "-" && (c = -c)), p = new Date(Date.UTC(n, i, r, o, a, s, l)), c && p.setTime(p.getTime() - c), p;
|
|
1523
1539
|
}
|
|
1524
|
-
function
|
|
1540
|
+
function ia(e) {
|
|
1525
1541
|
return e.toISOString();
|
|
1526
1542
|
}
|
|
1527
|
-
var
|
|
1543
|
+
var hn = new ne("tag:yaml.org,2002:timestamp", {
|
|
1528
1544
|
kind: "scalar",
|
|
1529
|
-
resolve:
|
|
1530
|
-
construct:
|
|
1545
|
+
resolve: ta,
|
|
1546
|
+
construct: na,
|
|
1531
1547
|
instanceOf: Date,
|
|
1532
|
-
represent:
|
|
1548
|
+
represent: ia
|
|
1533
1549
|
});
|
|
1534
|
-
function
|
|
1550
|
+
function ra(e) {
|
|
1535
1551
|
return e === "<<" || e === null;
|
|
1536
1552
|
}
|
|
1537
|
-
var
|
|
1553
|
+
var vn = new ne("tag:yaml.org,2002:merge", {
|
|
1538
1554
|
kind: "scalar",
|
|
1539
|
-
resolve:
|
|
1555
|
+
resolve: ra
|
|
1540
1556
|
}), at = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
1541
1557
|
\r`;
|
|
1542
|
-
function
|
|
1558
|
+
function aa(e) {
|
|
1543
1559
|
if (e === null) return !1;
|
|
1544
1560
|
var t, n, i = 0, r = e.length, o = at;
|
|
1545
1561
|
for (n = 0; n < r; n++)
|
|
@@ -1549,35 +1565,35 @@ function ta(e) {
|
|
|
1549
1565
|
}
|
|
1550
1566
|
return i % 8 === 0;
|
|
1551
1567
|
}
|
|
1552
|
-
function
|
|
1568
|
+
function oa(e) {
|
|
1553
1569
|
var t, n, i = e.replace(/[\r\n=]/g, ""), r = i.length, o = at, a = 0, s = [];
|
|
1554
1570
|
for (t = 0; t < r; t++)
|
|
1555
1571
|
t % 4 === 0 && t && (s.push(a >> 16 & 255), s.push(a >> 8 & 255), s.push(a & 255)), a = a << 6 | o.indexOf(i.charAt(t));
|
|
1556
1572
|
return n = r % 4 * 6, n === 0 ? (s.push(a >> 16 & 255), s.push(a >> 8 & 255), s.push(a & 255)) : n === 18 ? (s.push(a >> 10 & 255), s.push(a >> 2 & 255)) : n === 12 && s.push(a >> 4 & 255), new Uint8Array(s);
|
|
1557
1573
|
}
|
|
1558
|
-
function
|
|
1574
|
+
function la(e) {
|
|
1559
1575
|
var t = "", n = 0, i, r, o = e.length, a = at;
|
|
1560
1576
|
for (i = 0; i < o; i++)
|
|
1561
1577
|
i % 3 === 0 && i && (t += a[n >> 18 & 63], t += a[n >> 12 & 63], t += a[n >> 6 & 63], t += a[n & 63]), n = (n << 8) + e[i];
|
|
1562
1578
|
return r = o % 3, r === 0 ? (t += a[n >> 18 & 63], t += a[n >> 12 & 63], t += a[n >> 6 & 63], t += a[n & 63]) : r === 2 ? (t += a[n >> 10 & 63], t += a[n >> 4 & 63], t += a[n << 2 & 63], t += a[64]) : r === 1 && (t += a[n >> 2 & 63], t += a[n << 4 & 63], t += a[64], t += a[64]), t;
|
|
1563
1579
|
}
|
|
1564
|
-
function
|
|
1580
|
+
function sa(e) {
|
|
1565
1581
|
return Object.prototype.toString.call(e) === "[object Uint8Array]";
|
|
1566
1582
|
}
|
|
1567
|
-
var
|
|
1583
|
+
var bn = new ne("tag:yaml.org,2002:binary", {
|
|
1568
1584
|
kind: "scalar",
|
|
1569
|
-
resolve:
|
|
1570
|
-
construct:
|
|
1571
|
-
predicate:
|
|
1572
|
-
represent:
|
|
1573
|
-
}),
|
|
1574
|
-
function
|
|
1585
|
+
resolve: aa,
|
|
1586
|
+
construct: oa,
|
|
1587
|
+
predicate: sa,
|
|
1588
|
+
represent: la
|
|
1589
|
+
}), ca = Object.prototype.hasOwnProperty, ua = Object.prototype.toString;
|
|
1590
|
+
function da(e) {
|
|
1575
1591
|
if (e === null) return !0;
|
|
1576
1592
|
var t = [], n, i, r, o, a, s = e;
|
|
1577
1593
|
for (n = 0, i = s.length; n < i; n += 1) {
|
|
1578
|
-
if (r = s[n], a = !1,
|
|
1594
|
+
if (r = s[n], a = !1, ua.call(r) !== "[object Object]") return !1;
|
|
1579
1595
|
for (o in r)
|
|
1580
|
-
if (
|
|
1596
|
+
if (ca.call(r, o))
|
|
1581
1597
|
if (!a) a = !0;
|
|
1582
1598
|
else return !1;
|
|
1583
1599
|
if (!a) return !1;
|
|
@@ -1586,62 +1602,62 @@ function la(e) {
|
|
|
1586
1602
|
}
|
|
1587
1603
|
return !0;
|
|
1588
1604
|
}
|
|
1589
|
-
function
|
|
1605
|
+
function fa(e) {
|
|
1590
1606
|
return e !== null ? e : [];
|
|
1591
1607
|
}
|
|
1592
|
-
var
|
|
1608
|
+
var xn = new ne("tag:yaml.org,2002:omap", {
|
|
1593
1609
|
kind: "sequence",
|
|
1594
|
-
resolve:
|
|
1595
|
-
construct:
|
|
1596
|
-
}),
|
|
1597
|
-
function
|
|
1610
|
+
resolve: da,
|
|
1611
|
+
construct: fa
|
|
1612
|
+
}), pa = Object.prototype.toString;
|
|
1613
|
+
function ma(e) {
|
|
1598
1614
|
if (e === null) return !0;
|
|
1599
1615
|
var t, n, i, r, o, a = e;
|
|
1600
1616
|
for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1) {
|
|
1601
|
-
if (i = a[t],
|
|
1617
|
+
if (i = a[t], pa.call(i) !== "[object Object]" || (r = Object.keys(i), r.length !== 1)) return !1;
|
|
1602
1618
|
o[t] = [r[0], i[r[0]]];
|
|
1603
1619
|
}
|
|
1604
1620
|
return !0;
|
|
1605
1621
|
}
|
|
1606
|
-
function
|
|
1622
|
+
function ya(e) {
|
|
1607
1623
|
if (e === null) return [];
|
|
1608
1624
|
var t, n, i, r, o, a = e;
|
|
1609
1625
|
for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1)
|
|
1610
1626
|
i = a[t], r = Object.keys(i), o[t] = [r[0], i[r[0]]];
|
|
1611
1627
|
return o;
|
|
1612
1628
|
}
|
|
1613
|
-
var
|
|
1629
|
+
var Cn = new ne("tag:yaml.org,2002:pairs", {
|
|
1614
1630
|
kind: "sequence",
|
|
1615
|
-
resolve:
|
|
1616
|
-
construct:
|
|
1617
|
-
}),
|
|
1618
|
-
function
|
|
1631
|
+
resolve: ma,
|
|
1632
|
+
construct: ya
|
|
1633
|
+
}), ga = Object.prototype.hasOwnProperty;
|
|
1634
|
+
function ha(e) {
|
|
1619
1635
|
if (e === null) return !0;
|
|
1620
1636
|
var t, n = e;
|
|
1621
1637
|
for (t in n)
|
|
1622
|
-
if (
|
|
1638
|
+
if (ga.call(n, t) && n[t] !== null)
|
|
1623
1639
|
return !1;
|
|
1624
1640
|
return !0;
|
|
1625
1641
|
}
|
|
1626
|
-
function
|
|
1642
|
+
function va(e) {
|
|
1627
1643
|
return e !== null ? e : {};
|
|
1628
1644
|
}
|
|
1629
|
-
var
|
|
1645
|
+
var kn = new ne("tag:yaml.org,2002:set", {
|
|
1630
1646
|
kind: "mapping",
|
|
1631
|
-
resolve:
|
|
1632
|
-
construct:
|
|
1633
|
-
}), ot =
|
|
1647
|
+
resolve: ha,
|
|
1648
|
+
construct: va
|
|
1649
|
+
}), ot = mn.extend({
|
|
1634
1650
|
implicit: [
|
|
1635
|
-
|
|
1636
|
-
|
|
1651
|
+
hn,
|
|
1652
|
+
vn
|
|
1637
1653
|
],
|
|
1638
1654
|
explicit: [
|
|
1655
|
+
bn,
|
|
1656
|
+
xn,
|
|
1639
1657
|
Cn,
|
|
1640
|
-
kn
|
|
1641
|
-
An,
|
|
1642
|
-
_n
|
|
1658
|
+
kn
|
|
1643
1659
|
]
|
|
1644
|
-
}),
|
|
1660
|
+
}), he = Object.prototype.hasOwnProperty, Re = 1, An = 2, _n = 3, Ke = 4, Je = 1, ba = 2, _t = 3, xa = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Ca = /[\x85\u2028\u2029]/, ka = /[,\[\]\{\}]/, wn = /^(?:!|!!|![a-z\-]+!)$/i, Sn = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
|
|
1645
1661
|
function wt(e) {
|
|
1646
1662
|
return Object.prototype.toString.call(e);
|
|
1647
1663
|
}
|
|
@@ -1657,33 +1673,41 @@ function le(e) {
|
|
|
1657
1673
|
function _e(e) {
|
|
1658
1674
|
return e === 44 || e === 91 || e === 93 || e === 123 || e === 125;
|
|
1659
1675
|
}
|
|
1660
|
-
function
|
|
1676
|
+
function Aa(e) {
|
|
1661
1677
|
var t;
|
|
1662
1678
|
return 48 <= e && e <= 57 ? e - 48 : (t = e | 32, 97 <= t && t <= 102 ? t - 97 + 10 : -1);
|
|
1663
1679
|
}
|
|
1664
|
-
function
|
|
1680
|
+
function _a(e) {
|
|
1665
1681
|
return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0;
|
|
1666
1682
|
}
|
|
1667
|
-
function
|
|
1683
|
+
function wa(e) {
|
|
1668
1684
|
return 48 <= e && e <= 57 ? e - 48 : -1;
|
|
1669
1685
|
}
|
|
1670
1686
|
function St(e) {
|
|
1671
1687
|
return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? `
|
|
1672
1688
|
` : 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" : "";
|
|
1673
1689
|
}
|
|
1674
|
-
function
|
|
1690
|
+
function Sa(e) {
|
|
1675
1691
|
return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(
|
|
1676
1692
|
(e - 65536 >> 10) + 55296,
|
|
1677
1693
|
(e - 65536 & 1023) + 56320
|
|
1678
1694
|
);
|
|
1679
1695
|
}
|
|
1680
|
-
|
|
1696
|
+
function $n(e, t, n) {
|
|
1697
|
+
t === "__proto__" ? Object.defineProperty(e, t, {
|
|
1698
|
+
configurable: !0,
|
|
1699
|
+
enumerable: !0,
|
|
1700
|
+
writable: !0,
|
|
1701
|
+
value: n
|
|
1702
|
+
}) : e[t] = n;
|
|
1703
|
+
}
|
|
1704
|
+
var Tn = new Array(256), En = new Array(256);
|
|
1681
1705
|
for (var ke = 0; ke < 256; ke++)
|
|
1682
|
-
|
|
1683
|
-
function
|
|
1706
|
+
Tn[ke] = St(ke) ? 1 : 0, En[ke] = St(ke);
|
|
1707
|
+
function $a(e, t) {
|
|
1684
1708
|
this.input = e, this.filename = t.filename || null, this.schema = t.schema || ot, this.onWarning = t.onWarning || null, this.legacy = t.legacy || !1, this.json = t.json || !1, this.listener = t.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 = [];
|
|
1685
1709
|
}
|
|
1686
|
-
function
|
|
1710
|
+
function In(e, t) {
|
|
1687
1711
|
var n = {
|
|
1688
1712
|
name: e.filename,
|
|
1689
1713
|
buffer: e.input.slice(0, -1),
|
|
@@ -1692,26 +1716,26 @@ function Fn(e, t) {
|
|
|
1692
1716
|
line: e.line,
|
|
1693
1717
|
column: e.position - e.lineStart
|
|
1694
1718
|
};
|
|
1695
|
-
return n.snippet =
|
|
1719
|
+
return n.snippet = Fr(n), new oe(t, n);
|
|
1696
1720
|
}
|
|
1697
|
-
function
|
|
1698
|
-
throw
|
|
1721
|
+
function F(e, t) {
|
|
1722
|
+
throw In(e, t);
|
|
1699
1723
|
}
|
|
1700
|
-
function
|
|
1701
|
-
e.onWarning && e.onWarning.call(null,
|
|
1724
|
+
function Ne(e, t) {
|
|
1725
|
+
e.onWarning && e.onWarning.call(null, In(e, t));
|
|
1702
1726
|
}
|
|
1703
1727
|
var $t = {
|
|
1704
1728
|
YAML: function(t, n, i) {
|
|
1705
1729
|
var r, o, a;
|
|
1706
|
-
t.version !== null &&
|
|
1730
|
+
t.version !== null && F(t, "duplication of %YAML directive"), i.length !== 1 && F(t, "YAML directive accepts exactly one argument"), r = /^([0-9]+)\.([0-9]+)$/.exec(i[0]), r === null && F(t, "ill-formed argument of the YAML directive"), o = parseInt(r[1], 10), a = parseInt(r[2], 10), o !== 1 && F(t, "unacceptable YAML version of the document"), t.version = i[0], t.checkLineBreaks = a < 2, a !== 1 && a !== 2 && Ne(t, "unsupported YAML version of the document");
|
|
1707
1731
|
},
|
|
1708
1732
|
TAG: function(t, n, i) {
|
|
1709
1733
|
var r, o;
|
|
1710
|
-
i.length !== 2 &&
|
|
1734
|
+
i.length !== 2 && F(t, "TAG directive accepts exactly two arguments"), r = i[0], o = i[1], wn.test(r) || F(t, "ill-formed tag handle (first argument) of the TAG directive"), he.call(t.tagMap, r) && F(t, 'there is a previously declared suffix for "' + r + '" tag handle'), Sn.test(o) || F(t, "ill-formed tag prefix (second argument) of the TAG directive");
|
|
1711
1735
|
try {
|
|
1712
1736
|
o = decodeURIComponent(o);
|
|
1713
1737
|
} catch {
|
|
1714
|
-
|
|
1738
|
+
F(t, "tag prefix is malformed: " + o);
|
|
1715
1739
|
}
|
|
1716
1740
|
t.tagMap[r] = o;
|
|
1717
1741
|
}
|
|
@@ -1721,21 +1745,21 @@ function ge(e, t, n, i) {
|
|
|
1721
1745
|
if (t < n) {
|
|
1722
1746
|
if (s = e.input.slice(t, n), i)
|
|
1723
1747
|
for (r = 0, o = s.length; r < o; r += 1)
|
|
1724
|
-
a = s.charCodeAt(r), a === 9 || 32 <= a && a <= 1114111 ||
|
|
1725
|
-
else
|
|
1748
|
+
a = s.charCodeAt(r), a === 9 || 32 <= a && a <= 1114111 || F(e, "expected valid JSON character");
|
|
1749
|
+
else xa.test(s) && F(e, "the stream contains non-printable characters");
|
|
1726
1750
|
e.result += s;
|
|
1727
1751
|
}
|
|
1728
1752
|
}
|
|
1729
1753
|
function Tt(e, t, n, i) {
|
|
1730
1754
|
var r, o, a, s;
|
|
1731
|
-
for (ee.isObject(n) ||
|
|
1732
|
-
o = r[a],
|
|
1755
|
+
for (ee.isObject(n) || F(e, "cannot merge mappings; the provided source object is unacceptable"), r = Object.keys(n), a = 0, s = r.length; a < s; a += 1)
|
|
1756
|
+
o = r[a], he.call(t, o) || ($n(t, o, n[o]), i[o] = !0);
|
|
1733
1757
|
}
|
|
1734
1758
|
function we(e, t, n, i, r, o, a, s, l) {
|
|
1735
1759
|
var c, d;
|
|
1736
1760
|
if (Array.isArray(r))
|
|
1737
1761
|
for (r = Array.prototype.slice.call(r), c = 0, d = r.length; c < d; c += 1)
|
|
1738
|
-
Array.isArray(r[c]) &&
|
|
1762
|
+
Array.isArray(r[c]) && F(e, "nested arrays are not supported inside keys"), typeof r == "object" && wt(r[c]) === "[object Object]" && (r[c] = "[object Object]");
|
|
1739
1763
|
if (typeof r == "object" && wt(r) === "[object Object]" && (r = "[object Object]"), r = String(r), t === null && (t = {}), i === "tag:yaml.org,2002:merge")
|
|
1740
1764
|
if (Array.isArray(o))
|
|
1741
1765
|
for (c = 0, d = o.length; c < d; c += 1)
|
|
@@ -1743,17 +1767,12 @@ function we(e, t, n, i, r, o, a, s, l) {
|
|
|
1743
1767
|
else
|
|
1744
1768
|
Tt(e, t, o, n);
|
|
1745
1769
|
else
|
|
1746
|
-
!e.json && !
|
|
1747
|
-
configurable: !0,
|
|
1748
|
-
enumerable: !0,
|
|
1749
|
-
writable: !0,
|
|
1750
|
-
value: o
|
|
1751
|
-
}) : t[r] = o, delete n[r];
|
|
1770
|
+
!e.json && !he.call(n, r) && he.call(t, r) && (e.line = a || e.line, e.lineStart = s || e.lineStart, e.position = l || e.position, F(e, "duplicated mapping key")), $n(t, r, o), delete n[r];
|
|
1752
1771
|
return t;
|
|
1753
1772
|
}
|
|
1754
1773
|
function lt(e) {
|
|
1755
1774
|
var t;
|
|
1756
|
-
t = e.input.charCodeAt(e.position), t === 10 ? e.position++ : t === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) :
|
|
1775
|
+
t = e.input.charCodeAt(e.position), t === 10 ? e.position++ : t === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : F(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1;
|
|
1757
1776
|
}
|
|
1758
1777
|
function Z(e, t, n) {
|
|
1759
1778
|
for (var i = 0, r = e.input.charCodeAt(e.position); r !== 0; ) {
|
|
@@ -1769,9 +1788,9 @@ function Z(e, t, n) {
|
|
|
1769
1788
|
else
|
|
1770
1789
|
break;
|
|
1771
1790
|
}
|
|
1772
|
-
return n !== -1 && i !== 0 && e.lineIndent < n &&
|
|
1791
|
+
return n !== -1 && i !== 0 && e.lineIndent < n && Ne(e, "deficient indentation"), i;
|
|
1773
1792
|
}
|
|
1774
|
-
function
|
|
1793
|
+
function He(e) {
|
|
1775
1794
|
var t = e.position, n;
|
|
1776
1795
|
return n = e.input.charCodeAt(t), !!((n === 45 || n === 46) && n === e.input.charCodeAt(t + 1) && n === e.input.charCodeAt(t + 2) && (t += 3, n = e.input.charCodeAt(t), n === 0 || le(n)));
|
|
1777
1796
|
}
|
|
@@ -1779,7 +1798,7 @@ function st(e, t) {
|
|
|
1779
1798
|
t === 1 ? e.result += " " : t > 1 && (e.result += ee.repeat(`
|
|
1780
1799
|
`, t - 1));
|
|
1781
1800
|
}
|
|
1782
|
-
function
|
|
1801
|
+
function Ta(e, t, n) {
|
|
1783
1802
|
var i, r, o, a, s, l, c, d, u = e.kind, p = e.result, g;
|
|
1784
1803
|
if (g = e.input.charCodeAt(e.position), le(g) || _e(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) && (r = e.input.charCodeAt(e.position + 1), le(r) || n && _e(r)))
|
|
1785
1804
|
return !1;
|
|
@@ -1791,7 +1810,7 @@ function _a(e, t, n) {
|
|
|
1791
1810
|
if (i = e.input.charCodeAt(e.position - 1), le(i))
|
|
1792
1811
|
break;
|
|
1793
1812
|
} else {
|
|
1794
|
-
if (e.position === e.lineStart &&
|
|
1813
|
+
if (e.position === e.lineStart && He(e) || n && _e(g))
|
|
1795
1814
|
break;
|
|
1796
1815
|
if (de(g))
|
|
1797
1816
|
if (l = e.line, c = e.lineStart, d = e.lineIndent, Z(e, !1, -1), e.lineIndent >= t) {
|
|
@@ -1806,7 +1825,7 @@ function _a(e, t, n) {
|
|
|
1806
1825
|
}
|
|
1807
1826
|
return ge(e, o, a, !1), e.result ? !0 : (e.kind = u, e.result = p, !1);
|
|
1808
1827
|
}
|
|
1809
|
-
function
|
|
1828
|
+
function Ea(e, t) {
|
|
1810
1829
|
var n, i, r;
|
|
1811
1830
|
if (n = e.input.charCodeAt(e.position), n !== 39)
|
|
1812
1831
|
return !1;
|
|
@@ -1816,10 +1835,10 @@ function wa(e, t) {
|
|
|
1816
1835
|
i = e.position, e.position++, r = e.position;
|
|
1817
1836
|
else
|
|
1818
1837
|
return !0;
|
|
1819
|
-
else de(n) ? (ge(e, i, r, !0), st(e, Z(e, !1, t)), i = r = e.position) : e.position === e.lineStart &&
|
|
1820
|
-
|
|
1838
|
+
else de(n) ? (ge(e, i, r, !0), st(e, Z(e, !1, t)), i = r = e.position) : e.position === e.lineStart && He(e) ? F(e, "unexpected end of the document within a single quoted scalar") : (e.position++, r = e.position);
|
|
1839
|
+
F(e, "unexpected end of the stream within a single quoted scalar");
|
|
1821
1840
|
}
|
|
1822
|
-
function
|
|
1841
|
+
function Ia(e, t) {
|
|
1823
1842
|
var n, i, r, o, a, s;
|
|
1824
1843
|
if (s = e.input.charCodeAt(e.position), s !== 34)
|
|
1825
1844
|
return !1;
|
|
@@ -1829,21 +1848,21 @@ function Sa(e, t) {
|
|
|
1829
1848
|
if (s === 92) {
|
|
1830
1849
|
if (ge(e, n, e.position, !0), s = e.input.charCodeAt(++e.position), de(s))
|
|
1831
1850
|
Z(e, !1, t);
|
|
1832
|
-
else if (s < 256 &&
|
|
1851
|
+
else if (s < 256 && Tn[s])
|
|
1833
1852
|
e.result += En[s], e.position++;
|
|
1834
|
-
else if ((a =
|
|
1853
|
+
else if ((a = _a(s)) > 0) {
|
|
1835
1854
|
for (r = a, o = 0; r > 0; r--)
|
|
1836
|
-
s = e.input.charCodeAt(++e.position), (a =
|
|
1837
|
-
e.result +=
|
|
1855
|
+
s = e.input.charCodeAt(++e.position), (a = Aa(s)) >= 0 ? o = (o << 4) + a : F(e, "expected hexadecimal character");
|
|
1856
|
+
e.result += Sa(o), e.position++;
|
|
1838
1857
|
} else
|
|
1839
|
-
|
|
1858
|
+
F(e, "unknown escape sequence");
|
|
1840
1859
|
n = i = e.position;
|
|
1841
|
-
} else de(s) ? (ge(e, n, i, !0), st(e, Z(e, !1, t)), n = i = e.position) : e.position === e.lineStart &&
|
|
1860
|
+
} else de(s) ? (ge(e, n, i, !0), st(e, Z(e, !1, t)), n = i = e.position) : e.position === e.lineStart && He(e) ? F(e, "unexpected end of the document within a double quoted scalar") : (e.position++, i = e.position);
|
|
1842
1861
|
}
|
|
1843
|
-
|
|
1862
|
+
F(e, "unexpected end of the stream within a double quoted scalar");
|
|
1844
1863
|
}
|
|
1845
|
-
function
|
|
1846
|
-
var n = !0, i, r, o, a = e.tag, s, l = e.anchor, c, d, u, p, g,
|
|
1864
|
+
function Fa(e, t) {
|
|
1865
|
+
var n = !0, i, r, o, a = e.tag, s, l = e.anchor, c, d, u, p, g, y = /* @__PURE__ */ Object.create(null), x, h, A, C;
|
|
1847
1866
|
if (C = e.input.charCodeAt(e.position), C === 91)
|
|
1848
1867
|
d = 93, g = !1, s = [];
|
|
1849
1868
|
else if (C === 123)
|
|
@@ -1853,12 +1872,12 @@ function $a(e, t) {
|
|
|
1853
1872
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), C = e.input.charCodeAt(++e.position); C !== 0; ) {
|
|
1854
1873
|
if (Z(e, !0, t), C = e.input.charCodeAt(e.position), C === d)
|
|
1855
1874
|
return e.position++, e.tag = a, e.anchor = l, e.kind = g ? "mapping" : "sequence", e.result = s, !0;
|
|
1856
|
-
n ? C === 44 &&
|
|
1875
|
+
n ? C === 44 && F(e, "expected the node content, but found ','") : F(e, "missed comma between flow collection entries"), h = x = A = null, u = p = !1, C === 63 && (c = e.input.charCodeAt(e.position + 1), le(c) && (u = p = !0, e.position++, Z(e, !0, t))), i = e.line, r = e.lineStart, o = e.position, $e(e, t, Re, !1, !0), h = e.tag, x = e.result, Z(e, !0, t), C = e.input.charCodeAt(e.position), (p || e.line === i) && C === 58 && (u = !0, C = e.input.charCodeAt(++e.position), Z(e, !0, t), $e(e, t, Re, !1, !0), A = e.result), g ? we(e, s, y, h, x, A, i, r, o) : u ? s.push(we(e, null, y, h, x, A, i, r, o)) : s.push(x), Z(e, !0, t), C = e.input.charCodeAt(e.position), C === 44 ? (n = !0, C = e.input.charCodeAt(++e.position)) : n = !1;
|
|
1857
1876
|
}
|
|
1858
|
-
|
|
1877
|
+
F(e, "unexpected end of the stream within a flow collection");
|
|
1859
1878
|
}
|
|
1860
|
-
function
|
|
1861
|
-
var n, i, r =
|
|
1879
|
+
function Oa(e, t) {
|
|
1880
|
+
var n, i, r = Je, o = !1, a = !1, s = t, l = 0, c = !1, d, u;
|
|
1862
1881
|
if (u = e.input.charCodeAt(e.position), u === 124)
|
|
1863
1882
|
i = !1;
|
|
1864
1883
|
else if (u === 62)
|
|
@@ -1867,9 +1886,9 @@ function Ta(e, t) {
|
|
|
1867
1886
|
return !1;
|
|
1868
1887
|
for (e.kind = "scalar", e.result = ""; u !== 0; )
|
|
1869
1888
|
if (u = e.input.charCodeAt(++e.position), u === 43 || u === 45)
|
|
1870
|
-
|
|
1871
|
-
else if ((d =
|
|
1872
|
-
d === 0 ?
|
|
1889
|
+
Je === r ? r = u === 43 ? _t : ba : F(e, "repeat of a chomping mode identifier");
|
|
1890
|
+
else if ((d = wa(u)) >= 0)
|
|
1891
|
+
d === 0 ? F(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : a ? F(e, "repeat of an indentation width identifier") : (s = t + d - 1, a = !0);
|
|
1873
1892
|
else
|
|
1874
1893
|
break;
|
|
1875
1894
|
if (ve(u)) {
|
|
@@ -1890,7 +1909,7 @@ function Ta(e, t) {
|
|
|
1890
1909
|
}
|
|
1891
1910
|
if (e.lineIndent < s) {
|
|
1892
1911
|
r === _t ? e.result += ee.repeat(`
|
|
1893
|
-
`, o ? 1 + l : l) : r ===
|
|
1912
|
+
`, o ? 1 + l : l) : r === Je && o && (e.result += `
|
|
1894
1913
|
`);
|
|
1895
1914
|
break;
|
|
1896
1915
|
}
|
|
@@ -1904,118 +1923,118 @@ function Ta(e, t) {
|
|
|
1904
1923
|
}
|
|
1905
1924
|
return !0;
|
|
1906
1925
|
}
|
|
1907
|
-
function
|
|
1926
|
+
function Et(e, t) {
|
|
1908
1927
|
var n, i = e.tag, r = e.anchor, o = [], a, s = !1, l;
|
|
1909
1928
|
if (e.firstTabInLine !== -1) return !1;
|
|
1910
|
-
for (e.anchor !== null && (e.anchorMap[e.anchor] = o), l = e.input.charCodeAt(e.position); l !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine,
|
|
1929
|
+
for (e.anchor !== null && (e.anchorMap[e.anchor] = o), l = e.input.charCodeAt(e.position); l !== 0 && (e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, F(e, "tab characters must not be used in indentation")), !(l !== 45 || (a = e.input.charCodeAt(e.position + 1), !le(a)))); ) {
|
|
1911
1930
|
if (s = !0, e.position++, Z(e, !0, -1) && e.lineIndent <= t) {
|
|
1912
1931
|
o.push(null), l = e.input.charCodeAt(e.position);
|
|
1913
1932
|
continue;
|
|
1914
1933
|
}
|
|
1915
|
-
if (n = e.line, $e(e, t,
|
|
1916
|
-
|
|
1934
|
+
if (n = e.line, $e(e, t, _n, !1, !0), o.push(e.result), Z(e, !0, -1), l = e.input.charCodeAt(e.position), (e.line === n || e.lineIndent > t) && l !== 0)
|
|
1935
|
+
F(e, "bad indentation of a sequence entry");
|
|
1917
1936
|
else if (e.lineIndent < t)
|
|
1918
1937
|
break;
|
|
1919
1938
|
}
|
|
1920
1939
|
return s ? (e.tag = i, e.anchor = r, e.kind = "sequence", e.result = o, !0) : !1;
|
|
1921
1940
|
}
|
|
1922
|
-
function
|
|
1923
|
-
var i, r, o, a, s, l, c = e.tag, d = e.anchor, u = {}, p = /* @__PURE__ */ Object.create(null), g = null,
|
|
1941
|
+
function La(e, t, n) {
|
|
1942
|
+
var i, r, o, a, s, l, c = e.tag, d = e.anchor, u = {}, p = /* @__PURE__ */ Object.create(null), g = null, y = null, x = null, h = !1, A = !1, C;
|
|
1924
1943
|
if (e.firstTabInLine !== -1) return !1;
|
|
1925
1944
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = u), C = e.input.charCodeAt(e.position); C !== 0; ) {
|
|
1926
|
-
if (!
|
|
1927
|
-
C === 63 ? (
|
|
1945
|
+
if (!h && e.firstTabInLine !== -1 && (e.position = e.firstTabInLine, F(e, "tab characters must not be used in indentation")), i = e.input.charCodeAt(e.position + 1), o = e.line, (C === 63 || C === 58) && le(i))
|
|
1946
|
+
C === 63 ? (h && (we(e, u, p, g, y, null, a, s, l), g = y = x = null), A = !0, h = !0, r = !0) : h ? (h = !1, r = !0) : F(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, C = i;
|
|
1928
1947
|
else {
|
|
1929
|
-
if (a = e.line, s = e.lineStart, l = e.position, !$e(e, n,
|
|
1948
|
+
if (a = e.line, s = e.lineStart, l = e.position, !$e(e, n, An, !1, !0))
|
|
1930
1949
|
break;
|
|
1931
1950
|
if (e.line === o) {
|
|
1932
1951
|
for (C = e.input.charCodeAt(e.position); ve(C); )
|
|
1933
1952
|
C = e.input.charCodeAt(++e.position);
|
|
1934
1953
|
if (C === 58)
|
|
1935
|
-
C = e.input.charCodeAt(++e.position), le(C) ||
|
|
1936
|
-
else if (
|
|
1937
|
-
|
|
1954
|
+
C = e.input.charCodeAt(++e.position), le(C) || F(e, "a whitespace character is expected after the key-value separator within a block mapping"), h && (we(e, u, p, g, y, null, a, s, l), g = y = x = null), A = !0, h = !1, r = !1, g = e.tag, y = e.result;
|
|
1955
|
+
else if (A)
|
|
1956
|
+
F(e, "can not read an implicit mapping pair; a colon is missed");
|
|
1938
1957
|
else
|
|
1939
1958
|
return e.tag = c, e.anchor = d, !0;
|
|
1940
|
-
} else if (
|
|
1941
|
-
|
|
1959
|
+
} else if (A)
|
|
1960
|
+
F(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
1942
1961
|
else
|
|
1943
1962
|
return e.tag = c, e.anchor = d, !0;
|
|
1944
1963
|
}
|
|
1945
|
-
if ((e.line === o || e.lineIndent > t) && (
|
|
1946
|
-
|
|
1964
|
+
if ((e.line === o || e.lineIndent > t) && (h && (a = e.line, s = e.lineStart, l = e.position), $e(e, t, Ke, !0, r) && (h ? y = e.result : x = e.result), h || (we(e, u, p, g, y, x, a, s, l), g = y = x = null), Z(e, !0, -1), C = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > t) && C !== 0)
|
|
1965
|
+
F(e, "bad indentation of a mapping entry");
|
|
1947
1966
|
else if (e.lineIndent < t)
|
|
1948
1967
|
break;
|
|
1949
1968
|
}
|
|
1950
|
-
return
|
|
1969
|
+
return h && we(e, u, p, g, y, null, a, s, l), A && (e.tag = c, e.anchor = d, e.kind = "mapping", e.result = u), A;
|
|
1951
1970
|
}
|
|
1952
|
-
function
|
|
1971
|
+
function Ba(e) {
|
|
1953
1972
|
var t, n = !1, i = !1, r, o, a;
|
|
1954
1973
|
if (a = e.input.charCodeAt(e.position), a !== 33) return !1;
|
|
1955
|
-
if (e.tag !== null &&
|
|
1974
|
+
if (e.tag !== null && F(e, "duplication of a tag property"), a = e.input.charCodeAt(++e.position), a === 60 ? (n = !0, a = e.input.charCodeAt(++e.position)) : a === 33 ? (i = !0, r = "!!", a = e.input.charCodeAt(++e.position)) : r = "!", t = e.position, n) {
|
|
1956
1975
|
do
|
|
1957
1976
|
a = e.input.charCodeAt(++e.position);
|
|
1958
1977
|
while (a !== 0 && a !== 62);
|
|
1959
|
-
e.position < e.length ? (o = e.input.slice(t, e.position), a = e.input.charCodeAt(++e.position)) :
|
|
1978
|
+
e.position < e.length ? (o = e.input.slice(t, e.position), a = e.input.charCodeAt(++e.position)) : F(e, "unexpected end of the stream within a verbatim tag");
|
|
1960
1979
|
} else {
|
|
1961
1980
|
for (; a !== 0 && !le(a); )
|
|
1962
|
-
a === 33 && (i ?
|
|
1963
|
-
o = e.input.slice(t, e.position),
|
|
1981
|
+
a === 33 && (i ? F(e, "tag suffix cannot contain exclamation marks") : (r = e.input.slice(t - 1, e.position + 1), wn.test(r) || F(e, "named tag handle cannot contain such characters"), i = !0, t = e.position + 1)), a = e.input.charCodeAt(++e.position);
|
|
1982
|
+
o = e.input.slice(t, e.position), ka.test(o) && F(e, "tag suffix cannot contain flow indicator characters");
|
|
1964
1983
|
}
|
|
1965
|
-
o && !
|
|
1984
|
+
o && !Sn.test(o) && F(e, "tag name cannot contain such characters: " + o);
|
|
1966
1985
|
try {
|
|
1967
1986
|
o = decodeURIComponent(o);
|
|
1968
1987
|
} catch {
|
|
1969
|
-
|
|
1988
|
+
F(e, "tag name is malformed: " + o);
|
|
1970
1989
|
}
|
|
1971
|
-
return n ? e.tag = o :
|
|
1990
|
+
return n ? e.tag = o : he.call(e.tagMap, r) ? e.tag = e.tagMap[r] + o : r === "!" ? e.tag = "!" + o : r === "!!" ? e.tag = "tag:yaml.org,2002:" + o : F(e, 'undeclared tag handle "' + r + '"'), !0;
|
|
1972
1991
|
}
|
|
1973
|
-
function
|
|
1992
|
+
function Ra(e) {
|
|
1974
1993
|
var t, n;
|
|
1975
1994
|
if (n = e.input.charCodeAt(e.position), n !== 38) return !1;
|
|
1976
|
-
for (e.anchor !== null &&
|
|
1995
|
+
for (e.anchor !== null && F(e, "duplication of an anchor property"), n = e.input.charCodeAt(++e.position), t = e.position; n !== 0 && !le(n) && !_e(n); )
|
|
1977
1996
|
n = e.input.charCodeAt(++e.position);
|
|
1978
|
-
return e.position === t &&
|
|
1997
|
+
return e.position === t && F(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(t, e.position), !0;
|
|
1979
1998
|
}
|
|
1980
|
-
function
|
|
1999
|
+
function Ka(e) {
|
|
1981
2000
|
var t, n, i;
|
|
1982
2001
|
if (i = e.input.charCodeAt(e.position), i !== 42) return !1;
|
|
1983
2002
|
for (i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !le(i) && !_e(i); )
|
|
1984
2003
|
i = e.input.charCodeAt(++e.position);
|
|
1985
|
-
return e.position === t &&
|
|
2004
|
+
return e.position === t && F(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position), he.call(e.anchorMap, n) || F(e, 'unidentified alias "' + n + '"'), e.result = e.anchorMap[n], Z(e, !0, -1), !0;
|
|
1986
2005
|
}
|
|
1987
2006
|
function $e(e, t, n, i, r) {
|
|
1988
|
-
var o, a, s, l = 1, c = !1, d = !1, u, p, g,
|
|
1989
|
-
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = a = s =
|
|
1990
|
-
for (;
|
|
2007
|
+
var o, a, s, l = 1, c = !1, d = !1, u, p, g, y, x, h;
|
|
2008
|
+
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = a = s = Ke === n || _n === n, i && Z(e, !0, -1) && (c = !0, e.lineIndent > t ? l = 1 : e.lineIndent === t ? l = 0 : e.lineIndent < t && (l = -1)), l === 1)
|
|
2009
|
+
for (; Ba(e) || Ra(e); )
|
|
1991
2010
|
Z(e, !0, -1) ? (c = !0, s = o, e.lineIndent > t ? l = 1 : e.lineIndent === t ? l = 0 : e.lineIndent < t && (l = -1)) : s = !1;
|
|
1992
|
-
if (s && (s = c || r), (l === 1 ||
|
|
2011
|
+
if (s && (s = c || r), (l === 1 || Ke === n) && (Re === n || An === n ? x = t : x = t + 1, h = e.position - e.lineStart, l === 1 ? s && (Et(e, h) || La(e, h, x)) || Fa(e, x) ? d = !0 : (a && Oa(e, x) || Ea(e, x) || Ia(e, x) ? d = !0 : Ka(e) ? (d = !0, (e.tag !== null || e.anchor !== null) && F(e, "alias node should not have any properties")) : Ta(e, x, Re === n) && (d = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : l === 0 && (d = s && Et(e, h))), e.tag === null)
|
|
1993
2012
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1994
2013
|
else if (e.tag === "?") {
|
|
1995
|
-
for (e.result !== null && e.kind !== "scalar" &&
|
|
1996
|
-
if (
|
|
1997
|
-
e.result =
|
|
2014
|
+
for (e.result !== null && e.kind !== "scalar" && F(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), u = 0, p = e.implicitTypes.length; u < p; u += 1)
|
|
2015
|
+
if (y = e.implicitTypes[u], y.resolve(e.result)) {
|
|
2016
|
+
e.result = y.construct(e.result), e.tag = y.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1998
2017
|
break;
|
|
1999
2018
|
}
|
|
2000
2019
|
} else if (e.tag !== "!") {
|
|
2001
|
-
if (
|
|
2002
|
-
|
|
2020
|
+
if (he.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
2021
|
+
y = e.typeMap[e.kind || "fallback"][e.tag];
|
|
2003
2022
|
else
|
|
2004
|
-
for (
|
|
2023
|
+
for (y = null, g = e.typeMap.multi[e.kind || "fallback"], u = 0, p = g.length; u < p; u += 1)
|
|
2005
2024
|
if (e.tag.slice(0, g[u].tag.length) === g[u].tag) {
|
|
2006
|
-
|
|
2025
|
+
y = g[u];
|
|
2007
2026
|
break;
|
|
2008
2027
|
}
|
|
2009
|
-
|
|
2028
|
+
y || F(e, "unknown tag !<" + e.tag + ">"), e.result !== null && y.kind !== e.kind && F(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + y.kind + '", not "' + e.kind + '"'), y.resolve(e.result, e.tag) ? (e.result = y.construct(e.result, e.tag), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : F(e, "cannot resolve a node with !<" + e.tag + "> explicit tag");
|
|
2010
2029
|
}
|
|
2011
2030
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || d;
|
|
2012
2031
|
}
|
|
2013
|
-
function
|
|
2032
|
+
function Na(e) {
|
|
2014
2033
|
var t = e.position, n, i, r, o = !1, a;
|
|
2015
2034
|
for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = /* @__PURE__ */ Object.create(null), e.anchorMap = /* @__PURE__ */ Object.create(null); (a = e.input.charCodeAt(e.position)) !== 0 && (Z(e, !0, -1), a = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || a !== 37)); ) {
|
|
2016
2035
|
for (o = !0, a = e.input.charCodeAt(++e.position), n = e.position; a !== 0 && !le(a); )
|
|
2017
2036
|
a = e.input.charCodeAt(++e.position);
|
|
2018
|
-
for (i = e.input.slice(n, e.position), r = [], i.length < 1 &&
|
|
2037
|
+
for (i = e.input.slice(n, e.position), r = [], i.length < 1 && F(e, "directive name must not be less than one character in length"); a !== 0; ) {
|
|
2019
2038
|
for (; ve(a); )
|
|
2020
2039
|
a = e.input.charCodeAt(++e.position);
|
|
2021
2040
|
if (a === 35) {
|
|
@@ -2029,47 +2048,47 @@ function La(e) {
|
|
|
2029
2048
|
a = e.input.charCodeAt(++e.position);
|
|
2030
2049
|
r.push(e.input.slice(n, e.position));
|
|
2031
2050
|
}
|
|
2032
|
-
a !== 0 && lt(e),
|
|
2051
|
+
a !== 0 && lt(e), he.call($t, i) ? $t[i](e, i, r) : Ne(e, 'unknown document directive "' + i + '"');
|
|
2033
2052
|
}
|
|
2034
|
-
if (Z(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, Z(e, !0, -1)) : o &&
|
|
2053
|
+
if (Z(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, Z(e, !0, -1)) : o && F(e, "directives end mark is expected"), $e(e, e.lineIndent - 1, Ke, !1, !0), Z(e, !0, -1), e.checkLineBreaks && Ca.test(e.input.slice(t, e.position)) && Ne(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && He(e)) {
|
|
2035
2054
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, Z(e, !0, -1));
|
|
2036
2055
|
return;
|
|
2037
2056
|
}
|
|
2038
2057
|
if (e.position < e.length - 1)
|
|
2039
|
-
|
|
2058
|
+
F(e, "end of the stream or a document separator is expected");
|
|
2040
2059
|
else
|
|
2041
2060
|
return;
|
|
2042
2061
|
}
|
|
2043
|
-
function
|
|
2062
|
+
function Fn(e, t) {
|
|
2044
2063
|
e = String(e), t = t || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2045
2064
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2046
|
-
var n = new
|
|
2047
|
-
for (i !== -1 && (n.position = i,
|
|
2065
|
+
var n = new $a(e, t), i = e.indexOf("\0");
|
|
2066
|
+
for (i !== -1 && (n.position = i, F(n, "null byte is not allowed in input")), n.input += "\0"; n.input.charCodeAt(n.position) === 32; )
|
|
2048
2067
|
n.lineIndent += 1, n.position += 1;
|
|
2049
2068
|
for (; n.position < n.length - 1; )
|
|
2050
|
-
|
|
2069
|
+
Na(n);
|
|
2051
2070
|
return n.documents;
|
|
2052
2071
|
}
|
|
2053
|
-
function
|
|
2072
|
+
function Ma(e, t, n) {
|
|
2054
2073
|
t !== null && typeof t == "object" && typeof n > "u" && (n = t, t = null);
|
|
2055
|
-
var i =
|
|
2074
|
+
var i = Fn(e, n);
|
|
2056
2075
|
if (typeof t != "function")
|
|
2057
2076
|
return i;
|
|
2058
2077
|
for (var r = 0, o = i.length; r < o; r += 1)
|
|
2059
2078
|
t(i[r]);
|
|
2060
2079
|
}
|
|
2061
|
-
function
|
|
2062
|
-
var n =
|
|
2080
|
+
function ja(e, t) {
|
|
2081
|
+
var n = Fn(e, t);
|
|
2063
2082
|
if (n.length !== 0) {
|
|
2064
2083
|
if (n.length === 1)
|
|
2065
2084
|
return n[0];
|
|
2066
2085
|
throw new oe("expected a single document in the stream, but found more");
|
|
2067
2086
|
}
|
|
2068
2087
|
}
|
|
2069
|
-
var
|
|
2070
|
-
loadAll:
|
|
2071
|
-
load:
|
|
2072
|
-
},
|
|
2088
|
+
var Da = Ma, Pa = ja, On = {
|
|
2089
|
+
loadAll: Da,
|
|
2090
|
+
load: Pa
|
|
2091
|
+
}, Ln = Object.prototype.toString, Bn = Object.prototype.hasOwnProperty, ct = 65279, Ua = 9, Fe = 10, qa = 13, Ha = 32, Va = 33, Ya = 34, Ze = 35, Wa = 37, Ja = 38, Ga = 39, za = 42, Rn = 44, Qa = 45, Me = 58, Za = 61, Xa = 62, eo = 63, to = 64, Kn = 91, Nn = 93, no = 96, Mn = 123, io = 124, jn = 125, re = {};
|
|
2073
2092
|
re[0] = "\\0";
|
|
2074
2093
|
re[7] = "\\a";
|
|
2075
2094
|
re[8] = "\\b";
|
|
@@ -2085,7 +2104,7 @@ re[133] = "\\N";
|
|
|
2085
2104
|
re[160] = "\\_";
|
|
2086
2105
|
re[8232] = "\\L";
|
|
2087
2106
|
re[8233] = "\\P";
|
|
2088
|
-
var
|
|
2107
|
+
var ro = [
|
|
2089
2108
|
"y",
|
|
2090
2109
|
"Y",
|
|
2091
2110
|
"yes",
|
|
@@ -2102,15 +2121,15 @@ var eo = [
|
|
|
2102
2121
|
"off",
|
|
2103
2122
|
"Off",
|
|
2104
2123
|
"OFF"
|
|
2105
|
-
],
|
|
2106
|
-
function
|
|
2124
|
+
], ao = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2125
|
+
function oo(e, t) {
|
|
2107
2126
|
var n, i, r, o, a, s, l;
|
|
2108
2127
|
if (t === null) return {};
|
|
2109
2128
|
for (n = {}, i = Object.keys(t), r = 0, o = i.length; r < o; r += 1)
|
|
2110
|
-
a = i[r], s = String(t[a]), a.slice(0, 2) === "!!" && (a = "tag:yaml.org,2002:" + a.slice(2)), l = e.compiledTypeMap.fallback[a], l &&
|
|
2129
|
+
a = i[r], s = String(t[a]), a.slice(0, 2) === "!!" && (a = "tag:yaml.org,2002:" + a.slice(2)), l = e.compiledTypeMap.fallback[a], l && Bn.call(l.styleAliases, s) && (s = l.styleAliases[s]), n[a] = s;
|
|
2111
2130
|
return n;
|
|
2112
2131
|
}
|
|
2113
|
-
function
|
|
2132
|
+
function lo(e) {
|
|
2114
2133
|
var t, n, i;
|
|
2115
2134
|
if (t = e.toString(16).toUpperCase(), e <= 255)
|
|
2116
2135
|
n = "x", i = 2;
|
|
@@ -2122,94 +2141,94 @@ function io(e) {
|
|
|
2122
2141
|
throw new oe("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2123
2142
|
return "\\" + n + ee.repeat("0", i - t.length) + t;
|
|
2124
2143
|
}
|
|
2125
|
-
var
|
|
2126
|
-
function
|
|
2127
|
-
this.schema = e.schema || ot, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = ee.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap =
|
|
2144
|
+
var so = 1, Oe = 2;
|
|
2145
|
+
function co(e) {
|
|
2146
|
+
this.schema = e.schema || ot, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = ee.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = oo(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 === '"' ? Oe : so, 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;
|
|
2128
2147
|
}
|
|
2129
|
-
function
|
|
2148
|
+
function It(e, t) {
|
|
2130
2149
|
for (var n = ee.repeat(" ", t), i = 0, r = -1, o = "", a, s = e.length; i < s; )
|
|
2131
2150
|
r = e.indexOf(`
|
|
2132
2151
|
`, i), r === -1 ? (a = e.slice(i), i = s) : (a = e.slice(i, r + 1), i = r + 1), a.length && a !== `
|
|
2133
2152
|
` && (o += n), o += a;
|
|
2134
2153
|
return o;
|
|
2135
2154
|
}
|
|
2136
|
-
function
|
|
2155
|
+
function Xe(e, t) {
|
|
2137
2156
|
return `
|
|
2138
2157
|
` + ee.repeat(" ", e.indent * t);
|
|
2139
2158
|
}
|
|
2140
|
-
function
|
|
2159
|
+
function uo(e, t) {
|
|
2141
2160
|
var n, i, r;
|
|
2142
2161
|
for (n = 0, i = e.implicitTypes.length; n < i; n += 1)
|
|
2143
2162
|
if (r = e.implicitTypes[n], r.resolve(t))
|
|
2144
2163
|
return !0;
|
|
2145
2164
|
return !1;
|
|
2146
2165
|
}
|
|
2147
|
-
function
|
|
2148
|
-
return e ===
|
|
2166
|
+
function je(e) {
|
|
2167
|
+
return e === Ha || e === Ua;
|
|
2149
2168
|
}
|
|
2150
|
-
function
|
|
2169
|
+
function Le(e) {
|
|
2151
2170
|
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== ct || 65536 <= e && e <= 1114111;
|
|
2152
2171
|
}
|
|
2153
2172
|
function Ft(e) {
|
|
2154
|
-
return
|
|
2173
|
+
return Le(e) && e !== ct && e !== qa && e !== Fe;
|
|
2155
2174
|
}
|
|
2156
2175
|
function Ot(e, t, n) {
|
|
2157
|
-
var i = Ft(e), r = i && !
|
|
2176
|
+
var i = Ft(e), r = i && !je(e);
|
|
2158
2177
|
return (
|
|
2159
2178
|
// ns-plain-safe
|
|
2160
2179
|
(n ? (
|
|
2161
2180
|
// c = flow-in
|
|
2162
2181
|
i
|
|
2163
|
-
) : i && e !==
|
|
2182
|
+
) : i && e !== Rn && e !== Kn && e !== Nn && e !== Mn && e !== jn) && e !== Ze && !(t === Me && !r) || Ft(t) && !je(t) && e === Ze || t === Me && r
|
|
2164
2183
|
);
|
|
2165
2184
|
}
|
|
2166
|
-
function
|
|
2167
|
-
return
|
|
2185
|
+
function fo(e) {
|
|
2186
|
+
return Le(e) && e !== ct && !je(e) && e !== Qa && e !== eo && e !== Me && e !== Rn && e !== Kn && e !== Nn && e !== Mn && e !== jn && e !== Ze && e !== Ja && e !== za && e !== Va && e !== io && e !== Za && e !== Xa && e !== Ga && e !== Ya && e !== Wa && e !== to && e !== no;
|
|
2168
2187
|
}
|
|
2169
|
-
function
|
|
2170
|
-
return !
|
|
2188
|
+
function po(e) {
|
|
2189
|
+
return !je(e) && e !== Me;
|
|
2171
2190
|
}
|
|
2172
2191
|
function Te(e, t) {
|
|
2173
2192
|
var n = e.charCodeAt(t), i;
|
|
2174
2193
|
return n >= 55296 && n <= 56319 && t + 1 < e.length && (i = e.charCodeAt(t + 1), i >= 56320 && i <= 57343) ? (n - 55296) * 1024 + i - 56320 + 65536 : n;
|
|
2175
2194
|
}
|
|
2176
|
-
function
|
|
2195
|
+
function Dn(e) {
|
|
2177
2196
|
var t = /^\n* /;
|
|
2178
2197
|
return t.test(e);
|
|
2179
2198
|
}
|
|
2180
|
-
var
|
|
2181
|
-
function
|
|
2182
|
-
var l, c = 0, d = null, u = !1, p = !1, g = i !== -1,
|
|
2199
|
+
var Pn = 1, et = 2, Un = 3, qn = 4, Ae = 5;
|
|
2200
|
+
function mo(e, t, n, i, r, o, a, s) {
|
|
2201
|
+
var l, c = 0, d = null, u = !1, p = !1, g = i !== -1, y = -1, x = fo(Te(e, 0)) && po(Te(e, e.length - 1));
|
|
2183
2202
|
if (t || a)
|
|
2184
2203
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2185
|
-
if (c = Te(e, l), !
|
|
2204
|
+
if (c = Te(e, l), !Le(c))
|
|
2186
2205
|
return Ae;
|
|
2187
2206
|
x = x && Ot(c, d, s), d = c;
|
|
2188
2207
|
}
|
|
2189
2208
|
else {
|
|
2190
2209
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2191
|
-
if (c = Te(e, l), c ===
|
|
2210
|
+
if (c = Te(e, l), c === Fe)
|
|
2192
2211
|
u = !0, g && (p = p || // Foldable line = too long, and not more-indented.
|
|
2193
|
-
l -
|
|
2194
|
-
else if (!
|
|
2212
|
+
l - y - 1 > i && e[y + 1] !== " ", y = l);
|
|
2213
|
+
else if (!Le(c))
|
|
2195
2214
|
return Ae;
|
|
2196
2215
|
x = x && Ot(c, d, s), d = c;
|
|
2197
2216
|
}
|
|
2198
|
-
p = p || g && l -
|
|
2217
|
+
p = p || g && l - y - 1 > i && e[y + 1] !== " ";
|
|
2199
2218
|
}
|
|
2200
|
-
return !u && !p ? x && !a && !r(e) ?
|
|
2219
|
+
return !u && !p ? x && !a && !r(e) ? Pn : o === Oe ? Ae : et : n > 9 && Dn(e) ? Ae : a ? o === Oe ? Ae : et : p ? qn : Un;
|
|
2201
2220
|
}
|
|
2202
|
-
function
|
|
2221
|
+
function yo(e, t, n, i, r) {
|
|
2203
2222
|
e.dump = function() {
|
|
2204
2223
|
if (t.length === 0)
|
|
2205
|
-
return e.quotingType ===
|
|
2206
|
-
if (!e.noCompatMode && (
|
|
2207
|
-
return e.quotingType ===
|
|
2224
|
+
return e.quotingType === Oe ? '""' : "''";
|
|
2225
|
+
if (!e.noCompatMode && (ro.indexOf(t) !== -1 || ao.test(t)))
|
|
2226
|
+
return e.quotingType === Oe ? '"' + t + '"' : "'" + t + "'";
|
|
2208
2227
|
var o = e.indent * Math.max(1, n), a = e.lineWidth === -1 ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - o), s = i || e.flowLevel > -1 && n >= e.flowLevel;
|
|
2209
2228
|
function l(c) {
|
|
2210
|
-
return
|
|
2229
|
+
return uo(e, c);
|
|
2211
2230
|
}
|
|
2212
|
-
switch (
|
|
2231
|
+
switch (mo(
|
|
2213
2232
|
t,
|
|
2214
2233
|
s,
|
|
2215
2234
|
e.indent,
|
|
@@ -2219,23 +2238,23 @@ function uo(e, t, n, i, r) {
|
|
|
2219
2238
|
e.forceQuotes && !i,
|
|
2220
2239
|
r
|
|
2221
2240
|
)) {
|
|
2222
|
-
case
|
|
2241
|
+
case Pn:
|
|
2223
2242
|
return t;
|
|
2224
|
-
case
|
|
2243
|
+
case et:
|
|
2225
2244
|
return "'" + t.replace(/'/g, "''") + "'";
|
|
2245
|
+
case Un:
|
|
2246
|
+
return "|" + Lt(t, e.indent) + Bt(It(t, o));
|
|
2226
2247
|
case qn:
|
|
2227
|
-
return "
|
|
2228
|
-
case Hn:
|
|
2229
|
-
return ">" + Lt(t, e.indent) + Bt(Et(fo(t, a), o));
|
|
2248
|
+
return ">" + Lt(t, e.indent) + Bt(It(go(t, a), o));
|
|
2230
2249
|
case Ae:
|
|
2231
|
-
return '"' +
|
|
2250
|
+
return '"' + ho(t) + '"';
|
|
2232
2251
|
default:
|
|
2233
2252
|
throw new oe("impossible error: invalid scalar style");
|
|
2234
2253
|
}
|
|
2235
2254
|
}();
|
|
2236
2255
|
}
|
|
2237
2256
|
function Lt(e, t) {
|
|
2238
|
-
var n =
|
|
2257
|
+
var n = Dn(e) ? String(t) : "", i = e[e.length - 1] === `
|
|
2239
2258
|
`, r = i && (e[e.length - 2] === `
|
|
2240
2259
|
` || e === `
|
|
2241
2260
|
`), o = r ? "+" : i ? "" : "-";
|
|
@@ -2246,7 +2265,7 @@ function Bt(e) {
|
|
|
2246
2265
|
return e[e.length - 1] === `
|
|
2247
2266
|
` ? e.slice(0, -1) : e;
|
|
2248
2267
|
}
|
|
2249
|
-
function
|
|
2268
|
+
function go(e, t) {
|
|
2250
2269
|
for (var n = /(\n+)([^\n]*)/g, i = function() {
|
|
2251
2270
|
var c = e.indexOf(`
|
|
2252
2271
|
`);
|
|
@@ -2268,12 +2287,12 @@ function Rt(e, t) {
|
|
|
2268
2287
|
`, e.length - r > t && a > r ? l += e.slice(r, a) + `
|
|
2269
2288
|
` + e.slice(a + 1) : l += e.slice(r), l.slice(1);
|
|
2270
2289
|
}
|
|
2271
|
-
function
|
|
2290
|
+
function ho(e) {
|
|
2272
2291
|
for (var t = "", n = 0, i, r = 0; r < e.length; n >= 65536 ? r += 2 : r++)
|
|
2273
|
-
n = Te(e, r), i = re[n], !i &&
|
|
2292
|
+
n = Te(e, r), i = re[n], !i && Le(n) ? (t += e[r], n >= 65536 && (t += e[r + 1])) : t += i || lo(n);
|
|
2274
2293
|
return t;
|
|
2275
2294
|
}
|
|
2276
|
-
function
|
|
2295
|
+
function vo(e, t, n) {
|
|
2277
2296
|
var i = "", r = e.tag, o, a, s;
|
|
2278
2297
|
for (o = 0, a = n.length; o < a; o += 1)
|
|
2279
2298
|
s = n[o], e.replacer && (s = e.replacer.call(n, String(o), s)), (pe(e, t, s, !1, !1) || typeof s > "u" && pe(e, t, null, !1, !1)) && (i !== "" && (i += "," + (e.condenseFlow ? "" : " ")), i += e.dump);
|
|
@@ -2282,16 +2301,16 @@ function mo(e, t, n) {
|
|
|
2282
2301
|
function Kt(e, t, n, i) {
|
|
2283
2302
|
var r = "", o = e.tag, a, s, l;
|
|
2284
2303
|
for (a = 0, s = n.length; a < s; a += 1)
|
|
2285
|
-
l = n[a], e.replacer && (l = e.replacer.call(n, String(a), l)), (pe(e, t + 1, l, !0, !0, !1, !0) || typeof l > "u" && pe(e, t + 1, null, !0, !0, !1, !0)) && ((!i || r !== "") && (r +=
|
|
2304
|
+
l = n[a], e.replacer && (l = e.replacer.call(n, String(a), l)), (pe(e, t + 1, l, !0, !0, !1, !0) || typeof l > "u" && pe(e, t + 1, null, !0, !0, !1, !0)) && ((!i || r !== "") && (r += Xe(e, t)), e.dump && Fe === e.dump.charCodeAt(0) ? r += "-" : r += "- ", r += e.dump);
|
|
2286
2305
|
e.tag = o, e.dump = r || "[]";
|
|
2287
2306
|
}
|
|
2288
|
-
function
|
|
2307
|
+
function bo(e, t, n) {
|
|
2289
2308
|
var i = "", r = e.tag, o = Object.keys(n), a, s, l, c, d;
|
|
2290
2309
|
for (a = 0, s = o.length; a < s; a += 1)
|
|
2291
2310
|
d = "", i !== "" && (d += ", "), e.condenseFlow && (d += '"'), l = o[a], c = n[l], e.replacer && (c = e.replacer.call(n, l, c)), pe(e, t, l, !1, !1) && (e.dump.length > 1024 && (d += "? "), d += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), pe(e, t, c, !1, !1) && (d += e.dump, i += d));
|
|
2292
2311
|
e.tag = r, e.dump = "{" + i + "}";
|
|
2293
2312
|
}
|
|
2294
|
-
function
|
|
2313
|
+
function xo(e, t, n, i) {
|
|
2295
2314
|
var r = "", o = e.tag, a = Object.keys(n), s, l, c, d, u, p;
|
|
2296
2315
|
if (e.sortKeys === !0)
|
|
2297
2316
|
a.sort();
|
|
@@ -2300,7 +2319,7 @@ function go(e, t, n, i) {
|
|
|
2300
2319
|
else if (e.sortKeys)
|
|
2301
2320
|
throw new oe("sortKeys must be a boolean or a function");
|
|
2302
2321
|
for (s = 0, l = a.length; s < l; s += 1)
|
|
2303
|
-
p = "", (!i || r !== "") && (p +=
|
|
2322
|
+
p = "", (!i || r !== "") && (p += Xe(e, t)), c = a[s], d = n[c], e.replacer && (d = e.replacer.call(n, c, d)), pe(e, t + 1, c, !0, !0, !0) && (u = e.tag !== null && e.tag !== "?" || e.dump && e.dump.length > 1024, u && (e.dump && Fe === e.dump.charCodeAt(0) ? p += "?" : p += "? "), p += e.dump, u && (p += Xe(e, t)), pe(e, t + 1, d, !0, u) && (e.dump && Fe === e.dump.charCodeAt(0) ? p += ":" : p += ": ", p += e.dump, r += p));
|
|
2304
2323
|
e.tag = o, e.dump = r || "{}";
|
|
2305
2324
|
}
|
|
2306
2325
|
function Nt(e, t, n) {
|
|
@@ -2308,9 +2327,9 @@ function Nt(e, t, n) {
|
|
|
2308
2327
|
for (r = n ? e.explicitTypes : e.implicitTypes, o = 0, a = r.length; o < a; o += 1)
|
|
2309
2328
|
if (s = r[o], (s.instanceOf || s.predicate) && (!s.instanceOf || typeof t == "object" && t instanceof s.instanceOf) && (!s.predicate || s.predicate(t))) {
|
|
2310
2329
|
if (n ? s.multi && s.representName ? e.tag = s.representName(t) : e.tag = s.tag : e.tag = "?", s.represent) {
|
|
2311
|
-
if (l = e.styleMap[s.tag] || s.defaultStyle,
|
|
2330
|
+
if (l = e.styleMap[s.tag] || s.defaultStyle, Ln.call(s.represent) === "[object Function]")
|
|
2312
2331
|
i = s.represent(t, l);
|
|
2313
|
-
else if (
|
|
2332
|
+
else if (Bn.call(s.represent, l))
|
|
2314
2333
|
i = s.represent[l](t, l);
|
|
2315
2334
|
else
|
|
2316
2335
|
throw new oe("!<" + s.tag + '> tag resolver accepts not "' + l + '" style');
|
|
@@ -2322,18 +2341,18 @@ function Nt(e, t, n) {
|
|
|
2322
2341
|
}
|
|
2323
2342
|
function pe(e, t, n, i, r, o, a) {
|
|
2324
2343
|
e.tag = null, e.dump = n, Nt(e, n, !1) || Nt(e, n, !0);
|
|
2325
|
-
var s =
|
|
2344
|
+
var s = Ln.call(e.dump), l = i, c;
|
|
2326
2345
|
i && (i = e.flowLevel < 0 || e.flowLevel > t);
|
|
2327
2346
|
var d = s === "[object Object]" || s === "[object Array]", u, p;
|
|
2328
2347
|
if (d && (u = e.duplicates.indexOf(n), p = u !== -1), (e.tag !== null && e.tag !== "?" || p || e.indent !== 2 && t > 0) && (r = !1), p && e.usedDuplicates[u])
|
|
2329
2348
|
e.dump = "*ref_" + u;
|
|
2330
2349
|
else {
|
|
2331
2350
|
if (d && p && !e.usedDuplicates[u] && (e.usedDuplicates[u] = !0), s === "[object Object]")
|
|
2332
|
-
i && Object.keys(e.dump).length !== 0 ? (
|
|
2351
|
+
i && Object.keys(e.dump).length !== 0 ? (xo(e, t, e.dump, r), p && (e.dump = "&ref_" + u + e.dump)) : (bo(e, t, e.dump), p && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2333
2352
|
else if (s === "[object Array]")
|
|
2334
|
-
i && e.dump.length !== 0 ? (e.noArrayIndent && !a && t > 0 ? Kt(e, t - 1, e.dump, r) : Kt(e, t, e.dump, r), p && (e.dump = "&ref_" + u + e.dump)) : (
|
|
2353
|
+
i && e.dump.length !== 0 ? (e.noArrayIndent && !a && t > 0 ? Kt(e, t - 1, e.dump, r) : Kt(e, t, e.dump, r), p && (e.dump = "&ref_" + u + e.dump)) : (vo(e, t, e.dump), p && (e.dump = "&ref_" + u + " " + e.dump));
|
|
2335
2354
|
else if (s === "[object String]")
|
|
2336
|
-
e.tag !== "?" &&
|
|
2355
|
+
e.tag !== "?" && yo(e, e.dump, t, o, l);
|
|
2337
2356
|
else {
|
|
2338
2357
|
if (s === "[object Undefined]")
|
|
2339
2358
|
return !1;
|
|
@@ -2346,71 +2365,71 @@ function pe(e, t, n, i, r, o, a) {
|
|
|
2346
2365
|
}
|
|
2347
2366
|
return !0;
|
|
2348
2367
|
}
|
|
2349
|
-
function
|
|
2368
|
+
function Co(e, t) {
|
|
2350
2369
|
var n = [], i = [], r, o;
|
|
2351
|
-
for (
|
|
2370
|
+
for (tt(e, n, i), r = 0, o = i.length; r < o; r += 1)
|
|
2352
2371
|
t.duplicates.push(n[i[r]]);
|
|
2353
2372
|
t.usedDuplicates = new Array(o);
|
|
2354
2373
|
}
|
|
2355
|
-
function
|
|
2374
|
+
function tt(e, t, n) {
|
|
2356
2375
|
var i, r, o;
|
|
2357
2376
|
if (e !== null && typeof e == "object")
|
|
2358
2377
|
if (r = t.indexOf(e), r !== -1)
|
|
2359
2378
|
n.indexOf(r) === -1 && n.push(r);
|
|
2360
2379
|
else if (t.push(e), Array.isArray(e))
|
|
2361
2380
|
for (r = 0, o = e.length; r < o; r += 1)
|
|
2362
|
-
|
|
2381
|
+
tt(e[r], t, n);
|
|
2363
2382
|
else
|
|
2364
2383
|
for (i = Object.keys(e), r = 0, o = i.length; r < o; r += 1)
|
|
2365
|
-
|
|
2384
|
+
tt(e[i[r]], t, n);
|
|
2366
2385
|
}
|
|
2367
|
-
function
|
|
2386
|
+
function ko(e, t) {
|
|
2368
2387
|
t = t || {};
|
|
2369
|
-
var n = new
|
|
2370
|
-
n.noRefs ||
|
|
2388
|
+
var n = new co(t);
|
|
2389
|
+
n.noRefs || Co(e, n);
|
|
2371
2390
|
var i = e;
|
|
2372
2391
|
return n.replacer && (i = n.replacer.call({ "": i }, "", i)), pe(n, 0, i, !0, !0) ? n.dump + `
|
|
2373
2392
|
` : "";
|
|
2374
2393
|
}
|
|
2375
|
-
var
|
|
2376
|
-
dump:
|
|
2394
|
+
var Ao = ko, _o = {
|
|
2395
|
+
dump: Ao
|
|
2377
2396
|
};
|
|
2378
2397
|
function ut(e, t) {
|
|
2379
2398
|
return function() {
|
|
2380
2399
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.");
|
|
2381
2400
|
};
|
|
2382
2401
|
}
|
|
2383
|
-
var
|
|
2384
|
-
binary:
|
|
2385
|
-
float:
|
|
2386
|
-
map:
|
|
2387
|
-
null:
|
|
2388
|
-
pairs:
|
|
2389
|
-
set:
|
|
2390
|
-
timestamp:
|
|
2391
|
-
bool:
|
|
2392
|
-
int:
|
|
2393
|
-
merge:
|
|
2394
|
-
omap:
|
|
2395
|
-
seq:
|
|
2396
|
-
str:
|
|
2397
|
-
},
|
|
2398
|
-
Type:
|
|
2399
|
-
Schema:
|
|
2400
|
-
FAILSAFE_SCHEMA:
|
|
2401
|
-
JSON_SCHEMA:
|
|
2402
|
-
CORE_SCHEMA:
|
|
2403
|
-
DEFAULT_SCHEMA:
|
|
2404
|
-
load:
|
|
2405
|
-
loadAll:
|
|
2406
|
-
dump:
|
|
2407
|
-
YAMLException:
|
|
2408
|
-
types:
|
|
2409
|
-
safeLoad:
|
|
2410
|
-
safeLoadAll:
|
|
2411
|
-
safeDump:
|
|
2402
|
+
var wo = ne, So = rn, $o = sn, To = pn, Eo = mn, Io = ot, Fo = On.load, Oo = On.loadAll, Lo = _o.dump, Bo = oe, Ro = {
|
|
2403
|
+
binary: bn,
|
|
2404
|
+
float: fn,
|
|
2405
|
+
map: ln,
|
|
2406
|
+
null: cn,
|
|
2407
|
+
pairs: Cn,
|
|
2408
|
+
set: kn,
|
|
2409
|
+
timestamp: hn,
|
|
2410
|
+
bool: un,
|
|
2411
|
+
int: dn,
|
|
2412
|
+
merge: vn,
|
|
2413
|
+
omap: xn,
|
|
2414
|
+
seq: on,
|
|
2415
|
+
str: an
|
|
2416
|
+
}, Ko = ut("safeLoad", "load"), No = ut("safeLoadAll", "loadAll"), Mo = ut("safeDump", "dump"), Hn = {
|
|
2417
|
+
Type: wo,
|
|
2418
|
+
Schema: So,
|
|
2419
|
+
FAILSAFE_SCHEMA: $o,
|
|
2420
|
+
JSON_SCHEMA: To,
|
|
2421
|
+
CORE_SCHEMA: Eo,
|
|
2422
|
+
DEFAULT_SCHEMA: Io,
|
|
2423
|
+
load: Fo,
|
|
2424
|
+
loadAll: Oo,
|
|
2425
|
+
dump: Lo,
|
|
2426
|
+
YAMLException: Bo,
|
|
2427
|
+
types: Ro,
|
|
2428
|
+
safeLoad: Ko,
|
|
2429
|
+
safeLoadAll: No,
|
|
2430
|
+
safeDump: Mo
|
|
2412
2431
|
};
|
|
2413
|
-
const
|
|
2432
|
+
const jo = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */ z({
|
|
2414
2433
|
__name: "YamlCodeBlock",
|
|
2415
2434
|
props: {
|
|
2416
2435
|
/** A record to indicate the entity's configuration, used to populate the YAML code block */
|
|
@@ -2420,24 +2439,24 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2420
2439
|
}
|
|
2421
2440
|
},
|
|
2422
2441
|
setup(e) {
|
|
2423
|
-
const t = e, n =
|
|
2442
|
+
const t = e, n = $(() => {
|
|
2424
2443
|
const i = Object.fromEntries(Object.entries(t.entityRecord).filter(([, r]) => r !== null && r !== "" && (Array.isArray(r) ? r.length !== 0 : !0)));
|
|
2425
|
-
return Object.keys(i).length === 0 && i.constructor === Object ? "" :
|
|
2444
|
+
return Object.keys(i).length === 0 && i.constructor === Object ? "" : Hn.dump(i).trim();
|
|
2426
2445
|
});
|
|
2427
2446
|
return (i, r) => {
|
|
2428
2447
|
const o = P("KCodeBlock");
|
|
2429
|
-
return m(), S("div",
|
|
2430
|
-
t.entityRecord ? (m(),
|
|
2448
|
+
return m(), S("div", jo, [
|
|
2449
|
+
t.entityRecord ? (m(), j(o, {
|
|
2431
2450
|
key: 0,
|
|
2432
2451
|
id: "yaml-codeblock",
|
|
2433
2452
|
code: n.value,
|
|
2434
2453
|
language: "yaml",
|
|
2435
2454
|
theme: "dark"
|
|
2436
|
-
}, null, 8, ["code"])) :
|
|
2455
|
+
}, null, 8, ["code"])) : M("", !0)
|
|
2437
2456
|
]);
|
|
2438
2457
|
};
|
|
2439
2458
|
}
|
|
2440
|
-
}),
|
|
2459
|
+
}), Do = { class: "terraform-config config-card-code-block" }, ie = " ", Yn = /* @__PURE__ */ z({
|
|
2441
2460
|
__name: "TerraformCodeBlock",
|
|
2442
2461
|
props: {
|
|
2443
2462
|
/** A record to indicate the entity's configuration, used to populate the Terraform code block */
|
|
@@ -2448,7 +2467,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2448
2467
|
entityType: {
|
|
2449
2468
|
type: String,
|
|
2450
2469
|
required: !0,
|
|
2451
|
-
validator: (e) =>
|
|
2470
|
+
validator: (e) => Ue.includes(e)
|
|
2452
2471
|
},
|
|
2453
2472
|
credentialType: {
|
|
2454
2473
|
type: String,
|
|
@@ -2461,7 +2480,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2461
2480
|
}
|
|
2462
2481
|
},
|
|
2463
2482
|
setup(e) {
|
|
2464
|
-
const t = e, n =
|
|
2483
|
+
const t = e, n = $(() => pi.includes(t.entityType)), i = (l, c) => {
|
|
2465
2484
|
const d = ie;
|
|
2466
2485
|
let u = "";
|
|
2467
2486
|
return typeof l == "string" ? u += `${d}${c} = "${l}"
|
|
@@ -2476,11 +2495,11 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2476
2495
|
`), l === null)
|
|
2477
2496
|
return c ? p += `${u}}` : p = "{}", p;
|
|
2478
2497
|
const g = Object.fromEntries(Object.entries(l).filter(([, x]) => x !== null));
|
|
2479
|
-
let
|
|
2480
|
-
for (const [x,
|
|
2481
|
-
Array.isArray(
|
|
2482
|
-
`,
|
|
2483
|
-
`,
|
|
2498
|
+
let y = "";
|
|
2499
|
+
for (const [x, h] of Object.entries(g))
|
|
2500
|
+
Array.isArray(h) ? h.length === 0 ? y = "[]" : (y = `[
|
|
2501
|
+
`, y += o(h, void 0, u), y += `${u}${ie}]`) : h && typeof h == "object" ? (y = `{
|
|
2502
|
+
`, y += r(h, void 0, u), y += `${u}${ie}}`) : y = String(h ?? ""), typeof h == "string" && (y = `"${y}"`), p += `${u}${ie}${x} = ${y}
|
|
2484
2503
|
`;
|
|
2485
2504
|
return c ? p += `${u}}
|
|
2486
2505
|
` : p;
|
|
@@ -2492,9 +2511,9 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2492
2511
|
c && (l.length === 0 ? p += `${u}${c} = [` : p += `${u}${c} = [
|
|
2493
2512
|
`);
|
|
2494
2513
|
for (let g = 0; g < l.length; g++) {
|
|
2495
|
-
const
|
|
2496
|
-
typeof
|
|
2497
|
-
`, p += r(
|
|
2514
|
+
const y = l[g];
|
|
2515
|
+
typeof y == "object" ? (p += `${u}${ie}{
|
|
2516
|
+
`, p += r(y, void 0, u), p += `${u}${ie}}`) : typeof y == "string" ? p += `${u}${ie}"${y}"` : p += `${u}${ie}${String(y ?? "")}`, g < l.length - 1 && (p += ","), p += `
|
|
2498
2517
|
`;
|
|
2499
2518
|
}
|
|
2500
2519
|
return c && (l.length === 0 ? p += `]
|
|
@@ -2505,21 +2524,21 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2505
2524
|
for (const [d, u] of Object.entries(l))
|
|
2506
2525
|
Array.isArray(u) ? c += o(u, d) : typeof u == "object" ? c += r(u, d) : c += i(u, d);
|
|
2507
2526
|
return c;
|
|
2508
|
-
}, s =
|
|
2509
|
-
var p, g,
|
|
2510
|
-
const l = Object.fromEntries(Object.entries(t.entityRecord).filter(([,
|
|
2527
|
+
}, s = $(() => {
|
|
2528
|
+
var p, g, y, x, h, A, C;
|
|
2529
|
+
const l = Object.fromEntries(Object.entries(t.entityRecord).filter(([, E]) => E != null)), c = t.entityRecord.config ? Object.fromEntries(Object.entries((p = t.entityRecord) == null ? void 0 : p.config).filter(([, E]) => E != null)) : void 0;
|
|
2511
2530
|
if (c && (l.config = c), Object.keys(l).length === 0)
|
|
2512
2531
|
return "";
|
|
2513
2532
|
delete l.id;
|
|
2514
2533
|
let d = "", u = "";
|
|
2515
|
-
if ((g = l.service) != null && g.id ? (u = "service", delete l.service) : (
|
|
2516
|
-
const
|
|
2517
|
-
d += `resource "konnect_event_gateway_${
|
|
2534
|
+
if ((g = l.service) != null && g.id ? (u = "service", delete l.service) : (y = l.route) != null && y.id ? (u = "route", delete l.route) : (x = l.consumer) != null && x.id ? (u = "consumer", delete l.consumer) : (h = l.consumer_group) != null && h.id ? (u = "consumer_group", delete l.consumer_group) : (A = l.certificate) != null && A.id ? (u = "certificate", delete l.certificate) : (C = l.set) != null && C.id && (u = "set", delete l.set), n.value) {
|
|
2535
|
+
const E = t.subEntityType ? `${t.entityType}_${t.subEntityType}` : t.entityType;
|
|
2536
|
+
d += `resource "konnect_event_gateway_${E}" "my_eventgateway${E.replaceAll("_", "")}" {
|
|
2518
2537
|
`, d += `${ie}provider = konnect-beta
|
|
2519
2538
|
`;
|
|
2520
2539
|
} else if (t.entityType === "plugin") {
|
|
2521
|
-
const
|
|
2522
|
-
delete l.name, d += `resource "konnect_gateway_plugin_${
|
|
2540
|
+
const E = t.credentialType.replace(/-/g, "_") || (l.name + "").replace(/-/g, "_");
|
|
2541
|
+
delete l.name, d += `resource "konnect_gateway_plugin_${E}" "my_${E}" {
|
|
2523
2542
|
`;
|
|
2524
2543
|
} else
|
|
2525
2544
|
d += `resource "konnect_gateway_${t.entityType}" "my_${t.entityType}" {
|
|
@@ -2533,24 +2552,92 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2533
2552
|
});
|
|
2534
2553
|
return (l, c) => {
|
|
2535
2554
|
const d = P("KCodeBlock");
|
|
2536
|
-
return m(), S("div",
|
|
2537
|
-
t.entityRecord ? (m(),
|
|
2555
|
+
return m(), S("div", Do, [
|
|
2556
|
+
t.entityRecord ? (m(), j(d, {
|
|
2538
2557
|
key: 0,
|
|
2539
2558
|
id: "terraform-codeblock",
|
|
2540
2559
|
code: s.value,
|
|
2541
2560
|
language: "terraform",
|
|
2542
2561
|
theme: "dark"
|
|
2543
|
-
}, null, 8, ["code"])) :
|
|
2562
|
+
}, null, 8, ["code"])) : M("", !0)
|
|
2563
|
+
]);
|
|
2564
|
+
};
|
|
2565
|
+
}
|
|
2566
|
+
}), Po = { class: "deck-config config-card-code-block" }, Wn = /* @__PURE__ */ z({
|
|
2567
|
+
__name: "DeckCodeBlock",
|
|
2568
|
+
props: {
|
|
2569
|
+
entityRecord: {},
|
|
2570
|
+
entityType: {},
|
|
2571
|
+
geoServerUrl: {},
|
|
2572
|
+
controlPlaneName: {}
|
|
2573
|
+
},
|
|
2574
|
+
setup(e) {
|
|
2575
|
+
const t = e, n = $(() => {
|
|
2576
|
+
const o = {
|
|
2577
|
+
_format_version: "3.0"
|
|
2578
|
+
};
|
|
2579
|
+
return t.controlPlaneName && (o._konnect = {
|
|
2580
|
+
control_plane_name: t.controlPlaneName
|
|
2581
|
+
}), o;
|
|
2582
|
+
}), i = $(() => {
|
|
2583
|
+
var s, l, c, d, u;
|
|
2584
|
+
const o = Object.fromEntries(Object.entries(t.entityRecord).filter(([, p]) => p !== null && p !== "" && (Array.isArray(p) ? p.length !== 0 : !0)));
|
|
2585
|
+
t.entityType === Ee.Plugin ? ((s = o.service) != null && s.id && (o.service = o.service.id), (l = o.route) != null && l.id && (o.route = o.route.id), (c = o.consumer) != null && c.id && (o.consumer = o.consumer.id), (d = o.consumer_group) != null && d.id && (o.consumer_group = o.consumer_group.id)) : t.entityType === Ee.Key && (u = o.key_set) != null && u.id && (o.key_set = o.key_set.id);
|
|
2586
|
+
const a = {
|
|
2587
|
+
...n.value,
|
|
2588
|
+
[t.entityType + "s"]: [o]
|
|
2589
|
+
};
|
|
2590
|
+
return Hn.dump(a);
|
|
2591
|
+
}), r = $(() => {
|
|
2592
|
+
let o = "deck gatway apply -";
|
|
2593
|
+
return t.geoServerUrl && (o += ` --konnect-addr ${t.geoServerUrl}`), `echo
|
|
2594
|
+
'${i.value}
|
|
2595
|
+
' | ${o}
|
|
2596
|
+
`;
|
|
2597
|
+
});
|
|
2598
|
+
return (o, a) => {
|
|
2599
|
+
const s = P("KBadge"), l = P("KCodeBlock");
|
|
2600
|
+
return m(), S("div", Po, [
|
|
2601
|
+
B("p", null, [
|
|
2602
|
+
a[1] || (a[1] = U(" The ", -1)),
|
|
2603
|
+
K(s, null, {
|
|
2604
|
+
default: k(() => [...a[0] || (a[0] = [
|
|
2605
|
+
U("DECK_KONNECT_TOKEN", -1)
|
|
2606
|
+
])]),
|
|
2607
|
+
_: 1
|
|
2608
|
+
}),
|
|
2609
|
+
a[2] || (a[2] = U(" environment variable must be added first. See ", -1)),
|
|
2610
|
+
a[3] || (a[3] = B("a", {
|
|
2611
|
+
href: "https://developer.konghq.com/deck/get-started/",
|
|
2612
|
+
target: "_blank"
|
|
2613
|
+
}, "the documentation", -1)),
|
|
2614
|
+
a[4] || (a[4] = U(" for details. ", -1))
|
|
2615
|
+
]),
|
|
2616
|
+
K(l, {
|
|
2617
|
+
id: "deck-env-codeblock",
|
|
2618
|
+
code: "export DECK_KONNECT_TOKEN=<your_konnect_PAT>",
|
|
2619
|
+
language: "shell",
|
|
2620
|
+
"single-line": "",
|
|
2621
|
+
style: { "margin-bottom": "28px" },
|
|
2622
|
+
theme: "dark"
|
|
2623
|
+
}),
|
|
2624
|
+
t.entityRecord ? (m(), j(l, {
|
|
2625
|
+
key: 0,
|
|
2626
|
+
id: "deck-codeblock",
|
|
2627
|
+
code: r.value,
|
|
2628
|
+
language: "shell",
|
|
2629
|
+
theme: "dark"
|
|
2630
|
+
}, null, 8, ["code"])) : M("", !0)
|
|
2544
2631
|
]);
|
|
2545
2632
|
};
|
|
2546
2633
|
}
|
|
2547
|
-
}),
|
|
2634
|
+
}), Uo = {
|
|
2548
2635
|
key: 0,
|
|
2549
2636
|
class: "config-card-display-form"
|
|
2550
|
-
},
|
|
2637
|
+
}, qo = ["data-testid"], Ho = {
|
|
2551
2638
|
key: 0,
|
|
2552
2639
|
class: "config-card-prop-section-title"
|
|
2553
|
-
},
|
|
2640
|
+
}, Vo = /* @__PURE__ */ z({
|
|
2554
2641
|
__name: "ConfigCardDisplay",
|
|
2555
2642
|
props: {
|
|
2556
2643
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2562,7 +2649,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2562
2649
|
entityType: {
|
|
2563
2650
|
type: String,
|
|
2564
2651
|
required: !0,
|
|
2565
|
-
validator: (e) =>
|
|
2652
|
+
validator: (e) => Ue.includes(e)
|
|
2566
2653
|
},
|
|
2567
2654
|
subEntityType: {
|
|
2568
2655
|
// only for event gateway entities
|
|
@@ -2607,32 +2694,32 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2607
2694
|
}
|
|
2608
2695
|
},
|
|
2609
2696
|
setup(e) {
|
|
2610
|
-
const t = e, n =
|
|
2697
|
+
const t = e, n = Pe(), { i18n: { t: i } } = W.useI18n(), r = (s) => !!(s.tooltip || n[`${s.key}-label-tooltip`]), o = $(() => {
|
|
2611
2698
|
if (!t.record)
|
|
2612
2699
|
return t.record;
|
|
2613
2700
|
let s = t.record;
|
|
2614
2701
|
t.codeBlockRecordFormatter && (s = t.codeBlockRecordFormatter(s, t.format));
|
|
2615
2702
|
const l = JSON.parse(JSON.stringify(s));
|
|
2616
2703
|
return delete l.created_at, delete l.updated_at, l;
|
|
2617
|
-
}), a =
|
|
2704
|
+
}), a = $(() => t.fetcherUrl.replace(/(\?|&)__ui_data=true/, ""));
|
|
2618
2705
|
return (s, l) => (m(), S(ue, null, [
|
|
2619
|
-
e.format === "structured" ? (m(), S("div",
|
|
2706
|
+
e.format === "structured" ? (m(), S("div", Uo, [
|
|
2620
2707
|
(m(!0), S(ue, null, ce(e.propListTypes, (c) => (m(), S("div", {
|
|
2621
2708
|
key: `config-card-details-${c}-props`,
|
|
2622
2709
|
class: fe(`config-card-details-${c}-props`),
|
|
2623
2710
|
"data-testid": `config-card-details-${c}-props`
|
|
2624
2711
|
}, [
|
|
2625
|
-
c !== "basic" ? (m(), S("div",
|
|
2626
|
-
(m(!0), S(ue, null, ce(e.propertyCollections[c], (d) =>
|
|
2712
|
+
c !== "basic" ? (m(), S("div", Ho, L(c === "advanced" ? T(i)("baseConfigCard.sections.advanced") : c === "plugin" ? T(i)("baseConfigCard.sections.plugin") : T(i)("baseConfigCard.sections.policy")), 1)) : M("", !0),
|
|
2713
|
+
(m(!0), S(ue, null, ce(e.propertyCollections[c], (d) => D(s.$slots, `config-card-item-${d.key}`, {
|
|
2627
2714
|
key: d.key,
|
|
2628
2715
|
item: d
|
|
2629
2716
|
}, () => [
|
|
2630
|
-
|
|
2631
|
-
label:
|
|
2632
|
-
|
|
2717
|
+
K(Xt, { item: d }, Se({
|
|
2718
|
+
label: k(() => [
|
|
2719
|
+
D(s.$slots, `${d.key}-label`, { row: d }, void 0, !0)
|
|
2633
2720
|
]),
|
|
2634
|
-
[d.key]:
|
|
2635
|
-
|
|
2721
|
+
[d.key]: k(({ rowValue: u }) => [
|
|
2722
|
+
D(s.$slots, d.key, {
|
|
2636
2723
|
row: d,
|
|
2637
2724
|
rowValue: u
|
|
2638
2725
|
}, void 0, !0)
|
|
@@ -2641,38 +2728,45 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2641
2728
|
}, [
|
|
2642
2729
|
r(d) ? {
|
|
2643
2730
|
name: "label-tooltip",
|
|
2644
|
-
fn:
|
|
2645
|
-
|
|
2731
|
+
fn: k(() => [
|
|
2732
|
+
D(s.$slots, `${d.key}-label-tooltip`, { row: d }, void 0, !0)
|
|
2646
2733
|
]),
|
|
2647
2734
|
key: "0"
|
|
2648
2735
|
} : void 0
|
|
2649
2736
|
]), 1032, ["item"])
|
|
2650
2737
|
], !0)), 128))
|
|
2651
|
-
], 10,
|
|
2652
|
-
])) :
|
|
2653
|
-
e.format === "json" && o.value ? (m(),
|
|
2738
|
+
], 10, qo))), 128))
|
|
2739
|
+
])) : M("", !0),
|
|
2740
|
+
e.format === "json" && o.value ? (m(), j(en, {
|
|
2654
2741
|
key: 1,
|
|
2655
2742
|
config: t.config,
|
|
2656
2743
|
"entity-record": o.value,
|
|
2657
2744
|
"fetcher-url": a.value,
|
|
2658
2745
|
"request-method": "get"
|
|
2659
|
-
}, null, 8, ["config", "entity-record", "fetcher-url"])) :
|
|
2660
|
-
e.format === "yaml" && o.value ? (m(),
|
|
2746
|
+
}, null, 8, ["config", "entity-record", "fetcher-url"])) : M("", !0),
|
|
2747
|
+
e.format === "yaml" && o.value ? (m(), j(Vn, {
|
|
2661
2748
|
key: 2,
|
|
2662
2749
|
"entity-record": o.value
|
|
2663
|
-
}, null, 8, ["entity-record"])) :
|
|
2664
|
-
e.format === "terraform" && o.value ? (m(),
|
|
2750
|
+
}, null, 8, ["entity-record"])) : M("", !0),
|
|
2751
|
+
e.format === "terraform" && o.value ? (m(), j(Yn, {
|
|
2665
2752
|
key: 3,
|
|
2666
2753
|
"entity-record": o.value,
|
|
2667
2754
|
"entity-type": t.entityType,
|
|
2668
2755
|
"sub-entity-type": t.subEntityType
|
|
2669
|
-
}, null, 8, ["entity-record", "entity-type", "sub-entity-type"])) :
|
|
2756
|
+
}, null, 8, ["entity-record", "entity-type", "sub-entity-type"])) : M("", !0),
|
|
2757
|
+
e.format === "deck" && o.value ? (m(), j(Wn, {
|
|
2758
|
+
key: 4,
|
|
2759
|
+
"control-plane-name": t.config.app === "konnect" ? t.config.controlPlaneName : void 0,
|
|
2760
|
+
"entity-record": o.value,
|
|
2761
|
+
"entity-type": t.entityType,
|
|
2762
|
+
"geo-server-url": t.config.app === "konnect" ? t.config.geoServerUrl : void 0
|
|
2763
|
+
}, null, 8, ["control-plane-name", "entity-record", "entity-type", "geo-server-url"])) : M("", !0)
|
|
2670
2764
|
], 64));
|
|
2671
2765
|
}
|
|
2672
|
-
}),
|
|
2766
|
+
}), Yo = /* @__PURE__ */ se(Vo, [["__scopeId", "data-v-2104198c"]]), Wo = {
|
|
2673
2767
|
class: "config-card-title",
|
|
2674
2768
|
"data-testid": "config-card-title"
|
|
2675
|
-
},
|
|
2769
|
+
}, Jo = { class: "config-card-actions" }, Go = ["href"], zo = { class: "config-card-details-section" }, Qo = /* @__PURE__ */ z({
|
|
2676
2770
|
__name: "EntityBaseConfigCard",
|
|
2677
2771
|
props: {
|
|
2678
2772
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2693,7 +2787,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2693
2787
|
entityType: {
|
|
2694
2788
|
type: String,
|
|
2695
2789
|
required: !0,
|
|
2696
|
-
validator: (e) =>
|
|
2790
|
+
validator: (e) => Ue.includes(e)
|
|
2697
2791
|
},
|
|
2698
2792
|
/**
|
|
2699
2793
|
* Sub Entity type, required to generate terraform code for event gateway entities
|
|
@@ -2816,14 +2910,14 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2816
2910
|
label: r("baseForm.configuration.terraform"),
|
|
2817
2911
|
value: "terraform"
|
|
2818
2912
|
});
|
|
2819
|
-
const c = l[0].value, d =
|
|
2913
|
+
const c = l[0].value, d = N(c), u = (f) => {
|
|
2820
2914
|
d.value = f == null ? void 0 : f.value, n("configFormatChange", d.value);
|
|
2821
2915
|
}, p = (f, v) => {
|
|
2822
2916
|
localStorage.setItem(f, v);
|
|
2823
2917
|
};
|
|
2824
2918
|
be(d, (f) => {
|
|
2825
2919
|
i.config.formatPreferenceKey && p(i.config.formatPreferenceKey, f);
|
|
2826
|
-
}),
|
|
2920
|
+
}), nt(() => {
|
|
2827
2921
|
if (i.config.formatPreferenceKey) {
|
|
2828
2922
|
const f = localStorage.getItem(i.config.formatPreferenceKey);
|
|
2829
2923
|
f && l.some((v) => v.value === f) ? d.value = f : d.value = c, p(i.config.formatPreferenceKey, d.value);
|
|
@@ -2870,195 +2964,195 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
2870
2964
|
// the last property displayed
|
|
2871
2965
|
section: ae.Basic
|
|
2872
2966
|
}
|
|
2873
|
-
},
|
|
2874
|
-
var b, H,
|
|
2875
|
-
if (!
|
|
2967
|
+
}, y = N(!1), x = N(!1), h = N(""), A = N({}), C = $(() => {
|
|
2968
|
+
var b, H, J;
|
|
2969
|
+
if (!A.value)
|
|
2876
2970
|
return [];
|
|
2877
|
-
const f = [], v = Object.keys(
|
|
2878
|
-
for (const I in
|
|
2971
|
+
const f = [], v = Object.keys(A.value).length;
|
|
2972
|
+
for (const I in A.value) {
|
|
2879
2973
|
if (I === "__ui_data") continue;
|
|
2880
|
-
const
|
|
2881
|
-
let
|
|
2882
|
-
(G || G === 0) && (
|
|
2974
|
+
const R = (H = (b = i.configSchema) == null ? void 0 : b[I]) == null ? void 0 : H.order, G = (J = g[I]) == null ? void 0 : J.order;
|
|
2975
|
+
let q = v;
|
|
2976
|
+
(G || G === 0) && (q = G === -1 ? v + 1 : G), R && (q = R === -1 ? v + 1 : R), f.push([I, q]);
|
|
2883
2977
|
}
|
|
2884
|
-
return f.sort(function(I,
|
|
2885
|
-
return I[1] -
|
|
2978
|
+
return f.sort(function(I, R) {
|
|
2979
|
+
return I[1] - R[1];
|
|
2886
2980
|
}), f.map((I) => {
|
|
2887
2981
|
var dt, ft;
|
|
2888
|
-
const
|
|
2982
|
+
const R = I[0], G = (dt = A.value) == null ? void 0 : dt[R], q = ((ft = i.configSchema) == null ? void 0 : ft[R]) || {}, Q = g[R];
|
|
2889
2983
|
return {
|
|
2890
|
-
key:
|
|
2984
|
+
key: R,
|
|
2891
2985
|
value: G,
|
|
2892
|
-
hidden:
|
|
2893
|
-
type:
|
|
2894
|
-
label:
|
|
2895
|
-
tooltip:
|
|
2896
|
-
section:
|
|
2986
|
+
hidden: q.hidden || !1,
|
|
2987
|
+
type: q.type ?? ((Q == null ? void 0 : Q.type) || V.Text),
|
|
2988
|
+
label: q.label ?? ((Q == null ? void 0 : Q.label) || a(R)),
|
|
2989
|
+
tooltip: q.tooltip ?? ((Q == null ? void 0 : Q.tooltip) || void 0),
|
|
2990
|
+
section: q.section ?? ((Q == null ? void 0 : Q.section) || ae.Advanced)
|
|
2897
2991
|
};
|
|
2898
2992
|
}).filter((I) => !I.hidden && I.key !== i.pluginConfigKey);
|
|
2899
|
-
}),
|
|
2900
|
-
var H,
|
|
2901
|
-
if (!
|
|
2993
|
+
}), E = $(() => {
|
|
2994
|
+
var H, J;
|
|
2995
|
+
if (!A.value || !i.pluginConfigKey)
|
|
2902
2996
|
return [];
|
|
2903
|
-
const f =
|
|
2997
|
+
const f = A.value[i.pluginConfigKey] || {}, v = Object.keys(f).length, b = [];
|
|
2904
2998
|
for (const I in f) {
|
|
2905
|
-
const
|
|
2906
|
-
let
|
|
2907
|
-
|
|
2999
|
+
const R = (J = (H = i.pluginConfigSchema) == null ? void 0 : H[I]) == null ? void 0 : J.order, G = f[I];
|
|
3000
|
+
let q = G != null && G !== "" ? v - 1 : v;
|
|
3001
|
+
R && (q = R === -1 ? v + 1 : R), b.push([I, q]);
|
|
2908
3002
|
}
|
|
2909
|
-
return b.sort(function(I,
|
|
2910
|
-
return I[1] -
|
|
3003
|
+
return b.sort(function(I, R) {
|
|
3004
|
+
return I[1] - R[1];
|
|
2911
3005
|
}), b.map((I) => {
|
|
2912
3006
|
var Q;
|
|
2913
|
-
const
|
|
3007
|
+
const R = I[0], G = f[R], q = ((Q = i.pluginConfigSchema) == null ? void 0 : Q[R]) || {};
|
|
2914
3008
|
return {
|
|
2915
|
-
key:
|
|
3009
|
+
key: R,
|
|
2916
3010
|
value: G,
|
|
2917
|
-
hidden:
|
|
2918
|
-
type:
|
|
2919
|
-
label:
|
|
2920
|
-
tooltip:
|
|
3011
|
+
hidden: q.hidden || !1,
|
|
3012
|
+
type: q.type ?? V.Text,
|
|
3013
|
+
label: q.label ?? a(R),
|
|
3014
|
+
tooltip: q.tooltip ?? void 0,
|
|
2921
3015
|
section: ae.Plugin
|
|
2922
3016
|
};
|
|
2923
3017
|
}).filter((I) => !I.hidden);
|
|
2924
|
-
}),
|
|
2925
|
-
var H,
|
|
2926
|
-
if (!
|
|
3018
|
+
}), Y = $(() => {
|
|
3019
|
+
var H, J;
|
|
3020
|
+
if (!A.value || !i.policyConfigKey)
|
|
2927
3021
|
return [];
|
|
2928
|
-
const f =
|
|
3022
|
+
const f = A.value[i.policyConfigKey] || {}, v = Object.keys(f).length, b = [];
|
|
2929
3023
|
for (const I in f) {
|
|
2930
|
-
const
|
|
2931
|
-
let
|
|
2932
|
-
|
|
3024
|
+
const R = (J = (H = i.policyConfigSchema) == null ? void 0 : H[I]) == null ? void 0 : J.order, G = f[I];
|
|
3025
|
+
let q = G != null && G !== "" ? v - 1 : v;
|
|
3026
|
+
R && (q = R === -1 ? v + 1 : R), b.push([I, q]);
|
|
2933
3027
|
}
|
|
2934
|
-
return b.sort(function(I,
|
|
2935
|
-
return I[1] -
|
|
3028
|
+
return b.sort(function(I, R) {
|
|
3029
|
+
return I[1] - R[1];
|
|
2936
3030
|
}), b.map((I) => {
|
|
2937
3031
|
var Q;
|
|
2938
|
-
const
|
|
3032
|
+
const R = I[0], G = f[R], q = ((Q = i.policyConfigSchema) == null ? void 0 : Q[R]) || {};
|
|
2939
3033
|
return {
|
|
2940
|
-
key:
|
|
3034
|
+
key: R,
|
|
2941
3035
|
value: G,
|
|
2942
|
-
hidden:
|
|
2943
|
-
type:
|
|
2944
|
-
label:
|
|
2945
|
-
tooltip:
|
|
3036
|
+
hidden: q.hidden || !1,
|
|
3037
|
+
type: q.type ?? V.Text,
|
|
3038
|
+
label: q.label ?? a(R),
|
|
3039
|
+
tooltip: q.tooltip ?? void 0,
|
|
2946
3040
|
section: ae.Policy
|
|
2947
3041
|
};
|
|
2948
3042
|
}).filter((I) => !I.hidden);
|
|
2949
|
-
}), X =
|
|
2950
|
-
var f, v, b, H,
|
|
3043
|
+
}), X = $(() => {
|
|
3044
|
+
var f, v, b, H, J, I;
|
|
2951
3045
|
return {
|
|
2952
|
-
basic: (f = C.value) == null ? void 0 : f.filter((
|
|
2953
|
-
advanced: (v = C.value) == null ? void 0 : v.filter((
|
|
2954
|
-
plugin: (H =
|
|
2955
|
-
policy: (I =
|
|
3046
|
+
basic: (f = C.value) == null ? void 0 : f.filter((R) => R.section === ae.Basic),
|
|
3047
|
+
advanced: (v = C.value) == null ? void 0 : v.filter((R) => R.section === ae.Advanced),
|
|
3048
|
+
plugin: (H = E.value) == null ? void 0 : H.concat((b = C.value) == null ? void 0 : b.filter((R) => R.section === ae.Plugin)),
|
|
3049
|
+
policy: (I = Y.value) == null ? void 0 : I.concat((J = C.value) == null ? void 0 : J.filter((R) => R.section === ae.Policy))
|
|
2956
3050
|
};
|
|
2957
|
-
}), w =
|
|
3051
|
+
}), w = $(() => {
|
|
2958
3052
|
const f = [];
|
|
2959
3053
|
return X.value.basic.length && f.push("basic"), X.value.advanced.length && f.push("advanced"), X.value.plugin.length && f.push("plugin"), X.value.policy.length && f.push("policy"), f;
|
|
2960
|
-
}),
|
|
3054
|
+
}), _ = $(() => {
|
|
2961
3055
|
var v, b;
|
|
2962
3056
|
let f = `${i.config.apiBaseUrl}${i.fetchUrl}`;
|
|
2963
3057
|
return i.config.app === "konnect" ? f = f.replace(/{controlPlaneId}/gi, ((v = i.config) == null ? void 0 : v.controlPlaneId) || "") : i.config.app === "kongManager" && (f = f.replace(/\/{workspace}/gi, (b = i.config) != null && b.workspace ? `/${i.config.workspace}` : "")), f = f.replace(/{id}/gi, i.config.entityId), f;
|
|
2964
3058
|
});
|
|
2965
|
-
return be(
|
|
3059
|
+
return be(y, (f) => {
|
|
2966
3060
|
n("loading", f);
|
|
2967
|
-
}, { immediate: !0 }),
|
|
2968
|
-
x.value = !1,
|
|
3061
|
+
}, { immediate: !0 }), it(async () => {
|
|
3062
|
+
x.value = !1, y.value = !0;
|
|
2969
3063
|
try {
|
|
2970
|
-
const { data: f } = await s.get(
|
|
3064
|
+
const { data: f } = await s.get(_.value);
|
|
2971
3065
|
if (i.dataKey)
|
|
2972
3066
|
if (typeof f[i.dataKey] < "u")
|
|
2973
|
-
|
|
3067
|
+
A.value = { ...f[i.dataKey] };
|
|
2974
3068
|
else
|
|
2975
3069
|
throw new Error(r("errors.dataKeyUndefined", { dataKey: i.dataKey }));
|
|
2976
|
-
else i.recordResolver ?
|
|
3070
|
+
else i.recordResolver ? A.value = { ...i.recordResolver(f) } : A.value = { ...f };
|
|
2977
3071
|
Object.keys(i.configSchema).filter((b) => i.configSchema[b].forceShow).forEach((b) => {
|
|
2978
|
-
|
|
3072
|
+
A.value && typeof A.value[b] > "u" && (A.value[b] = null);
|
|
2979
3073
|
}), n("fetch:success", f);
|
|
2980
3074
|
} catch (f) {
|
|
2981
3075
|
const v = o(f);
|
|
2982
|
-
|
|
3076
|
+
h.value = v.startsWith("code") ? r("baseConfigCard.errors.load") : v, x.value = !0, n("fetch:error", f);
|
|
2983
3077
|
} finally {
|
|
2984
|
-
|
|
3078
|
+
y.value = !1;
|
|
2985
3079
|
}
|
|
2986
3080
|
}), (f, v) => {
|
|
2987
|
-
const b = P("KLabel"), H = P("KSelect"),
|
|
2988
|
-
return m(),
|
|
3081
|
+
const b = P("KLabel"), H = P("KSelect"), J = P("KButton"), I = P("KSkeleton"), R = P("KEmptyState"), G = P("KCard");
|
|
3082
|
+
return m(), j(G, {
|
|
2989
3083
|
class: "kong-ui-entity-base-config-card",
|
|
2990
3084
|
"title-tag": e.titleTag
|
|
2991
3085
|
}, Se({
|
|
2992
|
-
actions:
|
|
2993
|
-
|
|
2994
|
-
|
|
2995
|
-
|
|
3086
|
+
actions: k(() => [
|
|
3087
|
+
B("div", Jo, [
|
|
3088
|
+
D(f.$slots, "actions", {}, void 0, !0),
|
|
3089
|
+
K(b, {
|
|
2996
3090
|
class: "config-format-select-label",
|
|
2997
3091
|
"data-testid": "config-format-select-label"
|
|
2998
3092
|
}, {
|
|
2999
|
-
default:
|
|
3000
|
-
|
|
3093
|
+
default: k(() => [
|
|
3094
|
+
U(L(e.label), 1)
|
|
3001
3095
|
]),
|
|
3002
3096
|
_: 1
|
|
3003
3097
|
}),
|
|
3004
|
-
|
|
3098
|
+
K(H, {
|
|
3005
3099
|
modelValue: d.value,
|
|
3006
|
-
"onUpdate:modelValue": v[0] || (v[0] = (
|
|
3100
|
+
"onUpdate:modelValue": v[0] || (v[0] = (q) => d.value = q),
|
|
3007
3101
|
"data-testid": "select-config-format",
|
|
3008
3102
|
items: l,
|
|
3009
3103
|
onChange: u
|
|
3010
3104
|
}, null, 8, ["modelValue"]),
|
|
3011
|
-
e.configCardDoc ? (m(),
|
|
3105
|
+
e.configCardDoc ? (m(), j(J, {
|
|
3012
3106
|
key: 0,
|
|
3013
3107
|
appearance: "tertiary",
|
|
3014
3108
|
class: "book-icon",
|
|
3015
3109
|
"data-testid": "book-icon"
|
|
3016
3110
|
}, {
|
|
3017
|
-
default:
|
|
3018
|
-
|
|
3111
|
+
default: k(() => [
|
|
3112
|
+
B("a", {
|
|
3019
3113
|
href: e.configCardDoc,
|
|
3020
3114
|
rel: "noopener",
|
|
3021
3115
|
target: "_blank"
|
|
3022
3116
|
}, [
|
|
3023
|
-
|
|
3024
|
-
], 8,
|
|
3117
|
+
K(T(Vt), { size: T(rr) }, null, 8, ["size"])
|
|
3118
|
+
], 8, Go)
|
|
3025
3119
|
]),
|
|
3026
3120
|
_: 1
|
|
3027
|
-
})) :
|
|
3121
|
+
})) : M("", !0)
|
|
3028
3122
|
])
|
|
3029
3123
|
]),
|
|
3030
|
-
default:
|
|
3031
|
-
|
|
3124
|
+
default: k(() => [
|
|
3125
|
+
y.value ? (m(), j(I, {
|
|
3032
3126
|
key: 0,
|
|
3033
3127
|
"data-testid": "config-card-loader",
|
|
3034
3128
|
"table-columns": 2,
|
|
3035
3129
|
type: "table"
|
|
3036
|
-
})) : x.value ? (m(),
|
|
3130
|
+
})) : x.value ? (m(), j(R, {
|
|
3037
3131
|
key: 1,
|
|
3038
3132
|
"data-testid": "config-card-fetch-error",
|
|
3039
3133
|
"icon-variant": "error"
|
|
3040
3134
|
}, {
|
|
3041
|
-
default:
|
|
3042
|
-
|
|
3135
|
+
default: k(() => [
|
|
3136
|
+
B("h3", null, L(h.value), 1)
|
|
3043
3137
|
]),
|
|
3044
3138
|
_: 1
|
|
3045
|
-
})) :
|
|
3046
|
-
|
|
3047
|
-
|
|
3139
|
+
})) : M("", !0),
|
|
3140
|
+
B("div", zo, [
|
|
3141
|
+
K(Yo, {
|
|
3048
3142
|
"code-block-record-formatter": e.codeBlockRecordFormatter,
|
|
3049
3143
|
config: e.config,
|
|
3050
3144
|
"entity-type": e.entityType,
|
|
3051
|
-
"fetcher-url":
|
|
3145
|
+
"fetcher-url": _.value,
|
|
3052
3146
|
format: d.value,
|
|
3053
3147
|
"prop-list-types": w.value,
|
|
3054
3148
|
"property-collections": X.value,
|
|
3055
|
-
record:
|
|
3149
|
+
record: A.value,
|
|
3056
3150
|
"sub-entity-type": e.subEntityType
|
|
3057
3151
|
}, Se({ _: 2 }, [
|
|
3058
|
-
ce(Object.keys(f.$slots), (
|
|
3059
|
-
name:
|
|
3060
|
-
fn:
|
|
3061
|
-
|
|
3152
|
+
ce(Object.keys(f.$slots), (q) => ({
|
|
3153
|
+
name: q,
|
|
3154
|
+
fn: k((Q) => [
|
|
3155
|
+
D(f.$slots, q, qt({ record: A.value }, Q), void 0, !0)
|
|
3062
3156
|
])
|
|
3063
3157
|
}))
|
|
3064
3158
|
]), 1032, ["code-block-record-formatter", "config", "entity-type", "fetcher-url", "format", "prop-list-types", "property-collections", "record", "sub-entity-type"])
|
|
@@ -3068,10 +3162,10 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3068
3162
|
}, [
|
|
3069
3163
|
e.hideTitle ? void 0 : {
|
|
3070
3164
|
name: "title",
|
|
3071
|
-
fn:
|
|
3072
|
-
|
|
3073
|
-
|
|
3074
|
-
|
|
3165
|
+
fn: k(() => [
|
|
3166
|
+
B("span", Wo, [
|
|
3167
|
+
D(f.$slots, "title", {}, () => [
|
|
3168
|
+
U(L(T(r)("baseConfigCard.title")), 1)
|
|
3075
3169
|
], !0)
|
|
3076
3170
|
])
|
|
3077
3171
|
]),
|
|
@@ -3080,7 +3174,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3080
3174
|
]), 1032, ["title-tag"]);
|
|
3081
3175
|
};
|
|
3082
3176
|
}
|
|
3083
|
-
}),
|
|
3177
|
+
}), hs = /* @__PURE__ */ se(Qo, [["__scopeId", "data-v-f2b42324"]]), Zo = ["novalidate"], Xo = /* @__PURE__ */ z({
|
|
3084
3178
|
__name: "EntityBaseForm",
|
|
3085
3179
|
props: {
|
|
3086
3180
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3101,7 +3195,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3101
3195
|
entityType: {
|
|
3102
3196
|
type: String,
|
|
3103
3197
|
required: !0,
|
|
3104
|
-
validator: (e) =>
|
|
3198
|
+
validator: (e) => Ue.includes(e)
|
|
3105
3199
|
},
|
|
3106
3200
|
/**
|
|
3107
3201
|
* Sub entity type, required for event gateway entities to generate terraform code
|
|
@@ -3204,19 +3298,19 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3204
3298
|
emits: ["loading", "fetch:success", "fetch:error", "submit", "cancel", "codeBlockTabChange"],
|
|
3205
3299
|
setup(e, { expose: t, emit: n }) {
|
|
3206
3300
|
var X;
|
|
3207
|
-
const i = n, r = e, o =
|
|
3208
|
-
var
|
|
3301
|
+
const i = n, r = e, o = ci(), { i18n: { t: a } } = W.useI18n(), { getMessageFromError: s } = W.useErrors(), { axiosInstance: l } = W.useAxios((X = r.config) == null ? void 0 : X.axiosRequestConfig), c = N(!1), d = $(() => !!r.editId), u = N(!1), p = N(""), g = $(() => r.canSubmit === !1 || r.isReadonly), y = N(!1), x = $(() => {
|
|
3302
|
+
var _, O;
|
|
3209
3303
|
let w = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3210
|
-
return r.config.app === "konnect" ? w = w.replace(/{controlPlaneId}/gi, ((
|
|
3211
|
-
}),
|
|
3212
|
-
|
|
3213
|
-
},
|
|
3304
|
+
return r.config.app === "konnect" ? w = w.replace(/{controlPlaneId}/gi, ((_ = r.config) == null ? void 0 : _.controlPlaneId) || "") : r.config.app === "kongManager" && (w = w.replace(/\/{workspace}/gi, (O = r.config) != null && O.workspace ? `/${r.config.workspace}` : "")), r.editId ? (w = w.replace(/{id}/gi, r.editId), w) : (w = w.replace(/\/{id}/gi, ""), w);
|
|
3305
|
+
}), h = () => {
|
|
3306
|
+
y.value = !y.value;
|
|
3307
|
+
}, A = () => {
|
|
3214
3308
|
r.config.cancelRoute ? o.push(r.config.cancelRoute) : C();
|
|
3215
3309
|
}, C = () => {
|
|
3216
3310
|
i("cancel");
|
|
3217
|
-
},
|
|
3311
|
+
}, E = () => {
|
|
3218
3312
|
g.value || i("submit");
|
|
3219
|
-
},
|
|
3313
|
+
}, Y = N([
|
|
3220
3314
|
{
|
|
3221
3315
|
title: a("baseForm.configuration.json"),
|
|
3222
3316
|
hash: "#json"
|
|
@@ -3226,143 +3320,153 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3226
3320
|
hash: "#yaml"
|
|
3227
3321
|
}
|
|
3228
3322
|
]);
|
|
3229
|
-
return r.config.app === "konnect" && r.entityType !==
|
|
3323
|
+
return r.config.app === "konnect" && r.entityType !== Ee.Other && Y.value.splice(1, 0, {
|
|
3230
3324
|
title: a("baseForm.configuration.terraform"),
|
|
3231
3325
|
hash: "#terraform"
|
|
3326
|
+
}), fi.includes(r.entityType) && Y.value.push({
|
|
3327
|
+
title: a("baseForm.configuration.deck"),
|
|
3328
|
+
hash: "#deck"
|
|
3232
3329
|
}), be(() => c.value, (w) => {
|
|
3233
3330
|
i("loading", w);
|
|
3234
|
-
}, { immediate: !0 }),
|
|
3331
|
+
}, { immediate: !0 }), it(async () => {
|
|
3235
3332
|
if (r.editId)
|
|
3236
3333
|
try {
|
|
3237
3334
|
u.value = !1, c.value = !0;
|
|
3238
3335
|
const { data: w } = await l.get(x.value);
|
|
3239
3336
|
i("fetch:success", w);
|
|
3240
3337
|
} catch (w) {
|
|
3241
|
-
const
|
|
3242
|
-
p.value =
|
|
3338
|
+
const _ = s(w);
|
|
3339
|
+
p.value = _.startsWith("code") ? a("baseForm.errors.edit") : _, u.value = !0, i("fetch:error", w);
|
|
3243
3340
|
} finally {
|
|
3244
3341
|
c.value = !1;
|
|
3245
3342
|
}
|
|
3246
3343
|
}), t({
|
|
3247
|
-
viewConfig:
|
|
3344
|
+
viewConfig: h,
|
|
3248
3345
|
formCancel: C,
|
|
3249
|
-
formSubmit:
|
|
3250
|
-
}), (w,
|
|
3251
|
-
const O = P("KSkeleton"), f = P("KEmptyState"), v = P("KAlert"), b = P("KButton"), H = P("KTabs"),
|
|
3252
|
-
return m(),
|
|
3253
|
-
default:
|
|
3254
|
-
c.value ? (m(),
|
|
3346
|
+
formSubmit: E
|
|
3347
|
+
}), (w, _) => {
|
|
3348
|
+
const O = P("KSkeleton"), f = P("KEmptyState"), v = P("KAlert"), b = P("KButton"), H = P("KTabs"), J = P("KSlideout");
|
|
3349
|
+
return m(), j(De(e.wrapperComponent), { class: "kong-ui-entity-base-form" }, {
|
|
3350
|
+
default: k(() => [
|
|
3351
|
+
c.value ? (m(), j(O, {
|
|
3255
3352
|
key: 0,
|
|
3256
3353
|
type: "form"
|
|
3257
|
-
})) : u.value ? (m(),
|
|
3354
|
+
})) : u.value ? (m(), j(f, {
|
|
3258
3355
|
key: 1,
|
|
3259
|
-
"action-button-text":
|
|
3356
|
+
"action-button-text": T(a)("baseForm.actions.back"),
|
|
3260
3357
|
"data-testid": "form-fetch-error",
|
|
3261
3358
|
"icon-variant": "error",
|
|
3262
|
-
onClickAction:
|
|
3359
|
+
onClickAction: A
|
|
3263
3360
|
}, {
|
|
3264
|
-
default:
|
|
3265
|
-
|
|
3361
|
+
default: k(() => [
|
|
3362
|
+
B("h3", null, L(p.value), 1)
|
|
3266
3363
|
]),
|
|
3267
3364
|
_: 1
|
|
3268
3365
|
}, 8, ["action-button-text"])) : (m(), S("form", {
|
|
3269
3366
|
key: 2,
|
|
3270
3367
|
"data-testid": "form-content",
|
|
3271
3368
|
novalidate: r.noValidate,
|
|
3272
|
-
onReset:
|
|
3273
|
-
onSubmit:
|
|
3369
|
+
onReset: Be(C, ["prevent"]),
|
|
3370
|
+
onSubmit: Be(E, ["prevent"])
|
|
3274
3371
|
}, [
|
|
3275
|
-
|
|
3276
|
-
e.errorMessage ? (m(),
|
|
3372
|
+
D(w.$slots, "default", {}, void 0, !0),
|
|
3373
|
+
e.errorMessage ? (m(), j(v, {
|
|
3277
3374
|
key: 0,
|
|
3278
3375
|
appearance: "danger",
|
|
3279
3376
|
"data-testid": "form-error",
|
|
3280
3377
|
message: e.errorMessage
|
|
3281
|
-
}, null, 8, ["message"])) :
|
|
3282
|
-
e.hideActions ?
|
|
3378
|
+
}, null, 8, ["message"])) : M("", !0),
|
|
3379
|
+
e.hideActions ? M("", !0) : (m(), j(Ht, {
|
|
3283
3380
|
key: 1,
|
|
3284
3381
|
disabled: !e.actionTeleportTarget,
|
|
3285
3382
|
to: e.actionTeleportTarget
|
|
3286
3383
|
}, [
|
|
3287
|
-
|
|
3384
|
+
B("div", {
|
|
3288
3385
|
class: fe(["form-actions", { "form-actions-reverted": e.alignActionButtonToLeft }]),
|
|
3289
3386
|
"data-testid": "form-actions"
|
|
3290
3387
|
}, [
|
|
3291
|
-
|
|
3292
|
-
|
|
3388
|
+
D(w.$slots, "form-actions", {}, () => [
|
|
3389
|
+
K(b, {
|
|
3293
3390
|
appearance: "tertiary",
|
|
3294
3391
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-view-configuration`,
|
|
3295
|
-
onClick:
|
|
3392
|
+
onClick: _[0] || (_[0] = (I) => h())
|
|
3296
3393
|
}, {
|
|
3297
|
-
default:
|
|
3298
|
-
|
|
3394
|
+
default: k(() => [
|
|
3395
|
+
U(L(T(a)("baseForm.actions.viewConfiguration")), 1)
|
|
3299
3396
|
]),
|
|
3300
3397
|
_: 1
|
|
3301
3398
|
}, 8, ["data-testid"]),
|
|
3302
|
-
|
|
3399
|
+
K(b, {
|
|
3303
3400
|
appearance: "secondary",
|
|
3304
3401
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-cancel`,
|
|
3305
3402
|
disabled: e.isReadonly,
|
|
3306
3403
|
type: "reset",
|
|
3307
|
-
onClick:
|
|
3404
|
+
onClick: _[1] || (_[1] = (I) => !!e.actionTeleportTarget && C())
|
|
3308
3405
|
}, {
|
|
3309
|
-
default:
|
|
3310
|
-
|
|
3406
|
+
default: k(() => [
|
|
3407
|
+
U(L(e.cancelButtonText ?? T(a)("baseForm.actions.cancel")), 1)
|
|
3311
3408
|
]),
|
|
3312
3409
|
_: 1
|
|
3313
3410
|
}, 8, ["data-testid", "disabled"]),
|
|
3314
|
-
|
|
3411
|
+
K(b, {
|
|
3315
3412
|
appearance: "primary",
|
|
3316
3413
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-submit`,
|
|
3317
3414
|
disabled: g.value,
|
|
3318
3415
|
type: "submit",
|
|
3319
|
-
onClick:
|
|
3416
|
+
onClick: _[2] || (_[2] = (I) => !!e.actionTeleportTarget && E())
|
|
3320
3417
|
}, {
|
|
3321
|
-
default:
|
|
3322
|
-
|
|
3418
|
+
default: k(() => [
|
|
3419
|
+
U(L(e.saveButtonText ?? T(a)("baseForm.actions.save")), 1)
|
|
3323
3420
|
]),
|
|
3324
3421
|
_: 1
|
|
3325
3422
|
}, 8, ["data-testid", "disabled"])
|
|
3326
3423
|
], !0)
|
|
3327
3424
|
], 2)
|
|
3328
3425
|
], 8, ["disabled", "to"]))
|
|
3329
|
-
], 40,
|
|
3330
|
-
|
|
3426
|
+
], 40, Zo)),
|
|
3427
|
+
K(J, {
|
|
3331
3428
|
"close-on-blur": !1,
|
|
3332
3429
|
"data-testid": "form-view-configuration-slideout",
|
|
3333
3430
|
"has-overlay": !1,
|
|
3334
3431
|
"offset-top": e.slidoutTopOffset,
|
|
3335
|
-
title:
|
|
3336
|
-
visible:
|
|
3337
|
-
onClose:
|
|
3432
|
+
title: T(a)("baseForm.configuration.title"),
|
|
3433
|
+
visible: y.value,
|
|
3434
|
+
onClose: _[4] || (_[4] = (I) => h())
|
|
3338
3435
|
}, {
|
|
3339
|
-
default:
|
|
3340
|
-
|
|
3341
|
-
|
|
3436
|
+
default: k(() => [
|
|
3437
|
+
B("div", null, L(T(a)("baseForm.configuration.message")), 1),
|
|
3438
|
+
K(H, {
|
|
3342
3439
|
"data-testid": "form-view-configuration-slideout-tabs",
|
|
3343
|
-
tabs:
|
|
3344
|
-
onChange:
|
|
3440
|
+
tabs: Y.value,
|
|
3441
|
+
onChange: _[3] || (_[3] = (I) => i("codeBlockTabChange", I.replace("#", "")))
|
|
3345
3442
|
}, {
|
|
3346
|
-
json:
|
|
3347
|
-
|
|
3443
|
+
json: k(() => [
|
|
3444
|
+
K(en, {
|
|
3348
3445
|
config: e.config,
|
|
3349
3446
|
"entity-record": r.formFields,
|
|
3350
3447
|
"fetcher-url": x.value,
|
|
3351
3448
|
"request-method": r.editId ? "put" : "post"
|
|
3352
3449
|
}, null, 8, ["config", "entity-record", "fetcher-url", "request-method"])
|
|
3353
3450
|
]),
|
|
3354
|
-
yaml:
|
|
3355
|
-
|
|
3451
|
+
yaml: k(() => [
|
|
3452
|
+
K(Vn, {
|
|
3356
3453
|
"entity-record": r.formFields
|
|
3357
3454
|
}, null, 8, ["entity-record"])
|
|
3358
3455
|
]),
|
|
3359
|
-
terraform:
|
|
3360
|
-
|
|
3456
|
+
terraform: k(() => [
|
|
3457
|
+
K(Yn, {
|
|
3361
3458
|
"entity-record": r.formFields,
|
|
3362
3459
|
"entity-type": e.entityType,
|
|
3363
3460
|
"sub-entity-type": e.subEntityType
|
|
3364
3461
|
}, null, 8, ["entity-record", "entity-type", "sub-entity-type"])
|
|
3365
3462
|
]),
|
|
3463
|
+
deck: k(() => [
|
|
3464
|
+
K(Wn, {
|
|
3465
|
+
"entity-record": r.formFields,
|
|
3466
|
+
"entity-type": e.entityType,
|
|
3467
|
+
"geo-server-url": e.config.app === "konnect" ? e.config.geoServerUrl : void 0
|
|
3468
|
+
}, null, 8, ["entity-record", "entity-type", "geo-server-url"])
|
|
3469
|
+
]),
|
|
3366
3470
|
_: 1
|
|
3367
3471
|
}, 8, ["tabs"])
|
|
3368
3472
|
]),
|
|
@@ -3373,7 +3477,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3373
3477
|
});
|
|
3374
3478
|
};
|
|
3375
3479
|
}
|
|
3376
|
-
}),
|
|
3480
|
+
}), vs = /* @__PURE__ */ se(Xo, [["__scopeId", "data-v-b732b5bb"]]), el = ["data-truncate"], tl = /* @__PURE__ */ z({
|
|
3377
3481
|
__name: "EntityBaseTableCell",
|
|
3378
3482
|
props: {
|
|
3379
3483
|
keyName: {
|
|
@@ -3390,48 +3494,48 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3390
3494
|
}
|
|
3391
3495
|
},
|
|
3392
3496
|
setup(e) {
|
|
3393
|
-
const t = e, n =
|
|
3394
|
-
var
|
|
3395
|
-
return ((
|
|
3396
|
-
}), i =
|
|
3397
|
-
var
|
|
3398
|
-
return ((
|
|
3399
|
-
}), r =
|
|
3400
|
-
var
|
|
3401
|
-
const
|
|
3402
|
-
return
|
|
3403
|
-
}), o =
|
|
3497
|
+
const t = e, n = $(() => {
|
|
3498
|
+
var h;
|
|
3499
|
+
return ((h = t.rowEl) == null ? void 0 : h.querySelector(`[data-testid="${t.keyName}"]`)) || null;
|
|
3500
|
+
}), i = $(() => {
|
|
3501
|
+
var h;
|
|
3502
|
+
return ((h = n.value) == null ? void 0 : h.querySelector('[data-truncate="true"]')) || null;
|
|
3503
|
+
}), r = $(() => {
|
|
3504
|
+
var A, C;
|
|
3505
|
+
const h = (A = t.rowEl) == null ? void 0 : A.querySelectorAll("td");
|
|
3506
|
+
return h ? ((C = h[0]) == null ? void 0 : C.getAttribute("data-testid")) === t.keyName : !0;
|
|
3507
|
+
}), o = $(() => r.value || t.tooltip);
|
|
3404
3508
|
let a;
|
|
3405
3509
|
const s = () => {
|
|
3406
3510
|
a && (a.disconnect(), a = void 0);
|
|
3407
3511
|
}, l = () => {
|
|
3408
|
-
var
|
|
3409
|
-
let
|
|
3512
|
+
var A, C, E;
|
|
3513
|
+
let h = ((A = n.value) == null ? void 0 : A.clientWidth) || 0;
|
|
3410
3514
|
if (n.value && "getComputedStyle" in window) {
|
|
3411
|
-
const
|
|
3412
|
-
|
|
3515
|
+
const Y = window.getComputedStyle(n.value);
|
|
3516
|
+
h -= (parseFloat(Y.paddingLeft) || 0) + (parseFloat(Y.paddingRight) || 0);
|
|
3413
3517
|
}
|
|
3414
|
-
d.value = ((C = i.value) == null ? void 0 : C.getBoundingClientRect().width) || 0, u.value =
|
|
3415
|
-
}, c =
|
|
3518
|
+
d.value = ((C = i.value) == null ? void 0 : C.getBoundingClientRect().width) || 0, u.value = h, p.value = ((E = c.value) == null ? void 0 : E.innerText) || "";
|
|
3519
|
+
}, c = N({}), d = N(0), u = N(0), p = N(""), g = $(() => [i.value, n.value]), y = be(
|
|
3416
3520
|
g,
|
|
3417
|
-
(
|
|
3521
|
+
(h) => {
|
|
3418
3522
|
if (o.value && (s(), "ResizeObserver" in window && window)) {
|
|
3419
|
-
a = new ResizeObserver((
|
|
3523
|
+
a = new ResizeObserver((A) => {
|
|
3420
3524
|
window.requestAnimationFrame(() => {
|
|
3421
|
-
!Array.isArray(
|
|
3525
|
+
!Array.isArray(A) || !A.length || l();
|
|
3422
3526
|
});
|
|
3423
3527
|
});
|
|
3424
|
-
for (const
|
|
3425
|
-
|
|
3528
|
+
for (const A of h)
|
|
3529
|
+
A && a.observe(A);
|
|
3426
3530
|
}
|
|
3427
3531
|
},
|
|
3428
3532
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
3429
|
-
), x =
|
|
3430
|
-
return
|
|
3533
|
+
), x = $(() => o.value ? d.value > u.value : !1);
|
|
3534
|
+
return nt(() => {
|
|
3431
3535
|
l();
|
|
3432
|
-
}),
|
|
3433
|
-
|
|
3434
|
-
}), (
|
|
3536
|
+
}), Zn(() => {
|
|
3537
|
+
y();
|
|
3538
|
+
}), (h, A) => {
|
|
3435
3539
|
const C = P("KTooltip");
|
|
3436
3540
|
return m(), S("span", {
|
|
3437
3541
|
ref_key: "contentRef",
|
|
@@ -3442,27 +3546,27 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3442
3546
|
key: 0,
|
|
3443
3547
|
"data-truncate": o.value || void 0
|
|
3444
3548
|
}, [
|
|
3445
|
-
|
|
3549
|
+
K(C, {
|
|
3446
3550
|
"max-width": "300",
|
|
3447
3551
|
placement: "bottom-start",
|
|
3448
3552
|
text: x.value ? p.value : ""
|
|
3449
3553
|
}, {
|
|
3450
|
-
default:
|
|
3451
|
-
|
|
3554
|
+
default: k(() => [
|
|
3555
|
+
D(h.$slots, "default", {}, void 0, !0)
|
|
3452
3556
|
]),
|
|
3453
3557
|
_: 3
|
|
3454
3558
|
}, 8, ["text"])
|
|
3455
|
-
], 8,
|
|
3559
|
+
], 8, el)) : D(h.$slots, "default", { key: 1 }, void 0, !0)
|
|
3456
3560
|
], 512);
|
|
3457
3561
|
};
|
|
3458
3562
|
}
|
|
3459
|
-
}),
|
|
3563
|
+
}), nl = /* @__PURE__ */ se(tl, [["__scopeId", "data-v-a3a65cac"]]), il = { class: "toolbar-container" }, rl = {
|
|
3460
3564
|
key: 0,
|
|
3461
3565
|
class: "toolbar-button-container"
|
|
3462
|
-
},
|
|
3566
|
+
}, al = {
|
|
3463
3567
|
key: 0,
|
|
3464
3568
|
class: "hidden"
|
|
3465
|
-
},
|
|
3569
|
+
}, ol = /* @__PURE__ */ z({
|
|
3466
3570
|
__name: "EntityBaseTable",
|
|
3467
3571
|
props: {
|
|
3468
3572
|
// table header configuration
|
|
@@ -3607,7 +3711,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3607
3711
|
},
|
|
3608
3712
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked", "state"],
|
|
3609
3713
|
setup(e, { emit: t }) {
|
|
3610
|
-
const n = e, i = t, { i18n: { t: r } } = W.useI18n(), o =
|
|
3714
|
+
const n = e, i = t, { i18n: { t: r } } = W.useI18n(), o = $(() => {
|
|
3611
3715
|
var f, v;
|
|
3612
3716
|
return typeof n.errorMessage == "string" ? {
|
|
3613
3717
|
hasError: !!n.errorMessage,
|
|
@@ -3618,7 +3722,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3618
3722
|
title: (f = n.errorMessage) == null ? void 0 : f.title,
|
|
3619
3723
|
message: (v = n.errorMessage) == null ? void 0 : v.message
|
|
3620
3724
|
};
|
|
3621
|
-
}), a =
|
|
3725
|
+
}), a = $(() => n.cacheIdentifier || n.preferencesStorageKey), s = $(() => {
|
|
3622
3726
|
const f = [];
|
|
3623
3727
|
return Object.keys(n.tableHeaders).forEach((b) => {
|
|
3624
3728
|
const H = n.tableHeaders[b];
|
|
@@ -3636,7 +3740,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3636
3740
|
"data-rowid": f.id,
|
|
3637
3741
|
"data-testid": f.name,
|
|
3638
3742
|
...n.rowAttributes(f)
|
|
3639
|
-
}), c =
|
|
3743
|
+
}), c = N({}), d = (f) => {
|
|
3640
3744
|
var v;
|
|
3641
3745
|
return (v = c.value) == null ? void 0 : v.$el.querySelector(`[data-rowid="${f.id}"]`);
|
|
3642
3746
|
}, u = (f) => {
|
|
@@ -3652,47 +3756,47 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3652
3756
|
}, p = (f) => {
|
|
3653
3757
|
C(f), i("state", f);
|
|
3654
3758
|
}, g = () => {
|
|
3655
|
-
i("empty-state-cta-clicked"),
|
|
3656
|
-
},
|
|
3759
|
+
i("empty-state-cta-clicked"), y();
|
|
3760
|
+
}, y = () => {
|
|
3657
3761
|
i("clear-search-input");
|
|
3658
|
-
}, x =
|
|
3762
|
+
}, x = $(() => n.disableRowClick ? void 0 : (f, v) => {
|
|
3659
3763
|
i("click:row", v);
|
|
3660
|
-
}),
|
|
3764
|
+
}), h = (f) => {
|
|
3661
3765
|
i("sort", f);
|
|
3662
|
-
}, { hideTableToolbar:
|
|
3663
|
-
const f =
|
|
3766
|
+
}, { hideTableToolbar: A, handleStateChange: C } = W.useTableState(() => n.query), { setTablePreferences: E, getTablePreferences: Y } = hi(), X = N(Y(a.value, n.defaultTablePreferences)), w = $(() => {
|
|
3767
|
+
const f = Y(a.value);
|
|
3664
3768
|
return {
|
|
3665
3769
|
...n.initialFetcherParams,
|
|
3666
3770
|
...f
|
|
3667
3771
|
};
|
|
3668
|
-
}),
|
|
3772
|
+
}), _ = (f) => {
|
|
3669
3773
|
X.value = f, s.value.forEach((v) => {
|
|
3670
3774
|
!("hidable" in v) || !X.value.columnVisibility || v.hidable === !1 && (X.value.columnVisibility[v.key] = !0);
|
|
3671
|
-
}), a.value &&
|
|
3672
|
-
}, O =
|
|
3775
|
+
}), a.value && E(a.value, f);
|
|
3776
|
+
}, O = $(() => ({
|
|
3673
3777
|
disablePageJump: n.disablePaginationPageJump,
|
|
3674
3778
|
offset: n.paginationType === "offset",
|
|
3675
3779
|
...n.paginationAttributes
|
|
3676
3780
|
}));
|
|
3677
3781
|
return (f, v) => {
|
|
3678
3782
|
const b = P("KTableData"), H = P("KCard");
|
|
3679
|
-
return m(),
|
|
3783
|
+
return m(), j(H, {
|
|
3680
3784
|
class: "kong-ui-entity-base-table",
|
|
3681
3785
|
title: e.title,
|
|
3682
3786
|
"title-tag": e.titleTag
|
|
3683
3787
|
}, {
|
|
3684
|
-
default:
|
|
3685
|
-
|
|
3788
|
+
default: k(() => [
|
|
3789
|
+
K(b, {
|
|
3686
3790
|
ref_key: "tableRefs",
|
|
3687
3791
|
ref: c,
|
|
3688
3792
|
"cache-identifier": a.value,
|
|
3689
3793
|
"cell-attrs": u,
|
|
3690
3794
|
"client-sort": e.enableClientSort,
|
|
3691
|
-
"empty-state-action-message": e.query ?
|
|
3795
|
+
"empty-state-action-message": e.query ? T(r)("baseTable.emptyState.noSearchResultsCtaText") : e.emptyStateOptions.ctaText,
|
|
3692
3796
|
"empty-state-action-route": e.query ? void 0 : e.emptyStateOptions.ctaPath,
|
|
3693
3797
|
"empty-state-icon-variant": e.query ? "search" : "kong",
|
|
3694
|
-
"empty-state-message": e.query ?
|
|
3695
|
-
"empty-state-title": e.query ?
|
|
3798
|
+
"empty-state-message": e.query ? T(r)("baseTable.emptyState.noSearchResultsMessage") : e.emptyStateOptions.message,
|
|
3799
|
+
"empty-state-title": e.query ? T(r)("baseTable.emptyState.noSearchResultsTitle") : e.emptyStateOptions.title,
|
|
3696
3800
|
error: o.value.hasError,
|
|
3697
3801
|
"error-state-message": o.value.message,
|
|
3698
3802
|
"error-state-title": o.value.title,
|
|
@@ -3701,7 +3805,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3701
3805
|
headers: s.value,
|
|
3702
3806
|
"hide-pagination": e.hidePagination,
|
|
3703
3807
|
"hide-pagination-when-optional": e.hidePaginationWhenOptional,
|
|
3704
|
-
"hide-toolbar": e.hideToolbar ??
|
|
3808
|
+
"hide-toolbar": e.hideToolbar ?? T(A),
|
|
3705
3809
|
"initial-fetcher-params": w.value,
|
|
3706
3810
|
loading: e.isLoading,
|
|
3707
3811
|
"pagination-attributes": O.value,
|
|
@@ -3714,81 +3818,74 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3714
3818
|
"table-preferences": X.value,
|
|
3715
3819
|
onEmptyStateActionClick: g,
|
|
3716
3820
|
"onRow:click": x.value,
|
|
3717
|
-
onSort: v[0] || (v[0] = (
|
|
3821
|
+
onSort: v[0] || (v[0] = (J) => h(J)),
|
|
3718
3822
|
onState: p,
|
|
3719
|
-
"onUpdate:tablePreferences":
|
|
3823
|
+
"onUpdate:tablePreferences": _
|
|
3720
3824
|
}, Se({
|
|
3721
|
-
toolbar:
|
|
3722
|
-
|
|
3723
|
-
|
|
3724
|
-
f.$slots["toolbar-button"] ? (m(), S("div",
|
|
3725
|
-
|
|
3726
|
-
])) :
|
|
3825
|
+
toolbar: k(() => [
|
|
3826
|
+
B("div", il, [
|
|
3827
|
+
D(f.$slots, "toolbar-filter", {}, void 0, !0),
|
|
3828
|
+
f.$slots["toolbar-button"] ? (m(), S("div", rl, [
|
|
3829
|
+
D(f.$slots, "toolbar-button", {}, void 0, !0)
|
|
3830
|
+
])) : M("", !0)
|
|
3727
3831
|
])
|
|
3728
3832
|
]),
|
|
3729
|
-
"action-items":
|
|
3730
|
-
|
|
3833
|
+
"action-items": k(({ row: J }) => [
|
|
3834
|
+
D(f.$slots, "actions", { row: J }, void 0, !0)
|
|
3731
3835
|
]),
|
|
3732
3836
|
_: 2
|
|
3733
3837
|
}, [
|
|
3734
3838
|
f.$slots["empty-state"] ? {
|
|
3735
3839
|
name: "empty-state",
|
|
3736
|
-
fn:
|
|
3737
|
-
|
|
3840
|
+
fn: k(() => [
|
|
3841
|
+
D(f.$slots, "empty-state", {}, void 0, !0)
|
|
3738
3842
|
]),
|
|
3739
3843
|
key: "0"
|
|
3740
3844
|
} : void 0,
|
|
3741
|
-
ce(e.tableHeaders, (
|
|
3845
|
+
ce(e.tableHeaders, (J, I) => ({
|
|
3742
3846
|
name: I,
|
|
3743
|
-
fn:
|
|
3744
|
-
|
|
3847
|
+
fn: k(({ row: R, rowValue: G }) => [
|
|
3848
|
+
K(nl, {
|
|
3745
3849
|
"key-name": String(I),
|
|
3746
|
-
"row-el": d(
|
|
3747
|
-
tooltip:
|
|
3850
|
+
"row-el": d(R),
|
|
3851
|
+
tooltip: J.tooltip
|
|
3748
3852
|
}, {
|
|
3749
|
-
default:
|
|
3750
|
-
|
|
3751
|
-
row:
|
|
3853
|
+
default: k(() => [
|
|
3854
|
+
D(f.$slots, I, {
|
|
3855
|
+
row: R,
|
|
3752
3856
|
rowKey: e.rowKey,
|
|
3753
3857
|
rowValue: G
|
|
3754
3858
|
}, () => [
|
|
3755
|
-
|
|
3859
|
+
U(L(G), 1)
|
|
3756
3860
|
], !0)
|
|
3757
3861
|
]),
|
|
3758
3862
|
_: 2
|
|
3759
3863
|
}, 1032, ["key-name", "row-el", "tooltip"])
|
|
3760
3864
|
])
|
|
3761
3865
|
})),
|
|
3762
|
-
f.$slots["bulk-actions"] ? {
|
|
3763
|
-
name: "bulk-actions",
|
|
3764
|
-
fn: _((Y) => [
|
|
3765
|
-
j(f.$slots, "bulk-actions", qt(Ht(Y)), void 0, !0)
|
|
3766
|
-
]),
|
|
3767
|
-
key: "1"
|
|
3768
|
-
} : void 0,
|
|
3769
3866
|
e.query ? void 0 : {
|
|
3770
3867
|
name: "empty-state-action-icon",
|
|
3771
|
-
fn:
|
|
3772
|
-
|
|
3868
|
+
fn: k(() => [
|
|
3869
|
+
K(T(Yt))
|
|
3773
3870
|
]),
|
|
3774
|
-
key: "
|
|
3871
|
+
key: "1"
|
|
3775
3872
|
}
|
|
3776
3873
|
]), 1032, ["cache-identifier", "client-sort", "empty-state-action-message", "empty-state-action-route", "empty-state-icon-variant", "empty-state-message", "empty-state-title", "error", "error-state-message", "error-state-title", "fetcher", "fetcher-cache-key", "headers", "hide-pagination", "hide-pagination-when-optional", "hide-toolbar", "initial-fetcher-params", "loading", "pagination-attributes", "row-key", "search-input", "sort-handler-function", "sortable", "table-preferences", "onRow:click"]),
|
|
3777
|
-
f.$slots["outside-actions"] &&
|
|
3778
|
-
|
|
3779
|
-
])) :
|
|
3874
|
+
f.$slots["outside-actions"] && T(A) ? (m(), S("div", al, [
|
|
3875
|
+
D(f.$slots, "outside-actions", {}, void 0, !0)
|
|
3876
|
+
])) : M("", !0)
|
|
3780
3877
|
]),
|
|
3781
3878
|
_: 3
|
|
3782
3879
|
}, 8, ["title", "title-tag"]);
|
|
3783
3880
|
};
|
|
3784
3881
|
}
|
|
3785
|
-
}),
|
|
3882
|
+
}), bs = /* @__PURE__ */ se(ol, [["__scopeId", "data-v-44153100"]]), ll = {
|
|
3786
3883
|
key: 0,
|
|
3787
3884
|
class: "kong-ui-entity-delete-error"
|
|
3788
|
-
},
|
|
3885
|
+
}, sl = {
|
|
3789
3886
|
key: 1,
|
|
3790
3887
|
class: "description"
|
|
3791
|
-
},
|
|
3888
|
+
}, cl = /* @__PURE__ */ z({
|
|
3792
3889
|
__name: "EntityDeleteModal",
|
|
3793
3890
|
props: {
|
|
3794
3891
|
visible: {
|
|
@@ -3827,14 +3924,14 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3827
3924
|
},
|
|
3828
3925
|
emits: ["cancel", "proceed"],
|
|
3829
3926
|
setup(e, { emit: t }) {
|
|
3830
|
-
const { i18nT: n } = W.useI18n(), i = e, r = t, o =
|
|
3927
|
+
const { i18nT: n } = W.useI18n(), i = e, r = t, o = $(() => i.needConfirm ? i.entityName : ""), a = () => {
|
|
3831
3928
|
r("cancel");
|
|
3832
3929
|
}, s = () => {
|
|
3833
3930
|
r("proceed");
|
|
3834
3931
|
};
|
|
3835
3932
|
return (l, c) => {
|
|
3836
3933
|
const d = P("KAlert"), u = P("KPrompt");
|
|
3837
|
-
return m(),
|
|
3934
|
+
return m(), j(u, {
|
|
3838
3935
|
"action-button-appearance": "danger",
|
|
3839
3936
|
"action-button-disabled": e.actionPending,
|
|
3840
3937
|
"action-button-text": "Yes, delete",
|
|
@@ -3845,50 +3942,50 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3845
3942
|
onCancel: a,
|
|
3846
3943
|
onProceed: s
|
|
3847
3944
|
}, {
|
|
3848
|
-
default:
|
|
3849
|
-
e.error ? (m(), S("div",
|
|
3850
|
-
|
|
3851
|
-
default:
|
|
3852
|
-
|
|
3945
|
+
default: k(() => [
|
|
3946
|
+
e.error ? (m(), S("div", ll, [
|
|
3947
|
+
K(d, { appearance: "danger" }, {
|
|
3948
|
+
default: k(() => [
|
|
3949
|
+
U(L(e.error), 1)
|
|
3853
3950
|
]),
|
|
3854
3951
|
_: 1
|
|
3855
3952
|
})
|
|
3856
|
-
])) :
|
|
3857
|
-
|
|
3953
|
+
])) : M("", !0),
|
|
3954
|
+
K(T(n), {
|
|
3858
3955
|
class: "message",
|
|
3859
3956
|
keypath: i.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
3860
3957
|
tag: "p"
|
|
3861
3958
|
}, Se({
|
|
3862
|
-
entityType:
|
|
3863
|
-
|
|
3959
|
+
entityType: k(() => [
|
|
3960
|
+
U(L(i.entityType), 1)
|
|
3864
3961
|
]),
|
|
3865
3962
|
_: 2
|
|
3866
3963
|
}, [
|
|
3867
3964
|
i.entityName ? {
|
|
3868
3965
|
name: "entityName",
|
|
3869
|
-
fn:
|
|
3870
|
-
|
|
3966
|
+
fn: k(() => [
|
|
3967
|
+
B("strong", null, L(i.entityName), 1)
|
|
3871
3968
|
]),
|
|
3872
3969
|
key: "0"
|
|
3873
3970
|
} : void 0
|
|
3874
3971
|
]), 1032, ["keypath"]),
|
|
3875
|
-
i.description || l.$slots.description ? (m(), S("div",
|
|
3876
|
-
|
|
3877
|
-
|
|
3972
|
+
i.description || l.$slots.description ? (m(), S("div", sl, [
|
|
3973
|
+
D(l.$slots, "description", {}, () => [
|
|
3974
|
+
B("p", null, L(i.description), 1)
|
|
3878
3975
|
], !0)
|
|
3879
|
-
])) :
|
|
3976
|
+
])) : M("", !0)
|
|
3880
3977
|
]),
|
|
3881
3978
|
_: 3
|
|
3882
3979
|
}, 8, ["action-button-disabled", "confirmation-text", "title", "visible"]);
|
|
3883
3980
|
};
|
|
3884
3981
|
}
|
|
3885
|
-
}),
|
|
3982
|
+
}), xs = /* @__PURE__ */ se(cl, [["__scopeId", "data-v-4361d622"]]), ul = {
|
|
3886
3983
|
fill: "none",
|
|
3887
3984
|
height: "20",
|
|
3888
3985
|
viewBox: "0 0 20 20",
|
|
3889
3986
|
width: "20",
|
|
3890
3987
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3891
|
-
},
|
|
3988
|
+
}, dl = {
|
|
3892
3989
|
id: "mask0_180_20349",
|
|
3893
3990
|
height: "20",
|
|
3894
3991
|
maskUnits: "userSpaceOnUse",
|
|
@@ -3896,35 +3993,35 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3896
3993
|
width: "20",
|
|
3897
3994
|
x: "0",
|
|
3898
3995
|
y: "0"
|
|
3899
|
-
},
|
|
3996
|
+
}, fl = ["fill"], pl = { mask: "url(#mask0_180_20349)" }, ml = ["fill"], Mt = /* @__PURE__ */ z({
|
|
3900
3997
|
__name: "IconFilter",
|
|
3901
3998
|
props: {
|
|
3902
3999
|
color: {
|
|
3903
4000
|
type: String,
|
|
3904
|
-
default: `var(--kong-ui-entity-filter-color, ${
|
|
4001
|
+
default: `var(--kong-ui-entity-filter-color, ${Zi})`
|
|
3905
4002
|
}
|
|
3906
4003
|
},
|
|
3907
4004
|
setup(e) {
|
|
3908
|
-
return (t, n) => (m(), S("svg",
|
|
3909
|
-
|
|
3910
|
-
|
|
4005
|
+
return (t, n) => (m(), S("svg", ul, [
|
|
4006
|
+
B("mask", dl, [
|
|
4007
|
+
B("rect", {
|
|
3911
4008
|
fill: e.color,
|
|
3912
4009
|
height: "20",
|
|
3913
4010
|
width: "20"
|
|
3914
|
-
}, null, 8,
|
|
4011
|
+
}, null, 8, fl)
|
|
3915
4012
|
]),
|
|
3916
|
-
|
|
3917
|
-
|
|
4013
|
+
B("g", pl, [
|
|
4014
|
+
B("path", {
|
|
3918
4015
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3919
4016
|
fill: e.color
|
|
3920
|
-
}, null, 8,
|
|
4017
|
+
}, null, 8, ml)
|
|
3921
4018
|
])
|
|
3922
4019
|
]));
|
|
3923
4020
|
}
|
|
3924
|
-
}),
|
|
4021
|
+
}), yl = {
|
|
3925
4022
|
key: 1,
|
|
3926
4023
|
class: "kong-ui-entity-filter"
|
|
3927
|
-
},
|
|
4024
|
+
}, gl = { class: "kong-ui-entity-filter-menu" }, hl = ["data-testid"], vl = ["onClick", "onKeydown"], bl = { class: "menu-item-indicator" }, xl = { class: "menu-item-body" }, Cl = ["for"], kl = { class: "menu-item-buttons" }, Al = { class: "filter-clear-button-container" }, _l = /* @__PURE__ */ z({
|
|
3928
4025
|
__name: "EntityFilter",
|
|
3929
4026
|
props: {
|
|
3930
4027
|
// filter config, either exact match or fuzzy match
|
|
@@ -3944,25 +4041,25 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3944
4041
|
},
|
|
3945
4042
|
emits: ["update:modelValue"],
|
|
3946
4043
|
setup(e, { emit: t }) {
|
|
3947
|
-
const { i18n: { t: n } } = W.useI18n(), i = e, r = t, o =
|
|
4044
|
+
const { i18n: { t: n } } = W.useI18n(), i = e, r = t, o = N(!1), a = N({}), s = N(/* @__PURE__ */ new Set()), l = $(() => {
|
|
3948
4045
|
const w = [];
|
|
3949
|
-
return new URLSearchParams(i.modelValue).forEach((
|
|
3950
|
-
|
|
4046
|
+
return new URLSearchParams(i.modelValue).forEach((_, O) => {
|
|
4047
|
+
_ !== "" && w.push(O);
|
|
3951
4048
|
}), w;
|
|
3952
|
-
}), c =
|
|
4049
|
+
}), c = $(() => {
|
|
3953
4050
|
const w = i.config.fields;
|
|
3954
|
-
return Object.keys(w).filter((
|
|
4051
|
+
return Object.keys(w).filter((_) => {
|
|
3955
4052
|
var O;
|
|
3956
|
-
return (O = w == null ? void 0 : w[
|
|
3957
|
-
}).map((
|
|
3958
|
-
label: w[
|
|
3959
|
-
value:
|
|
4053
|
+
return (O = w == null ? void 0 : w[_]) == null ? void 0 : O.searchable;
|
|
4054
|
+
}).map((_) => ({
|
|
4055
|
+
label: w[_].label || _,
|
|
4056
|
+
value: _,
|
|
3960
4057
|
expanded: !1
|
|
3961
4058
|
}));
|
|
3962
4059
|
});
|
|
3963
4060
|
be(() => i.modelValue, (w) => {
|
|
3964
|
-
a.value = {}, new URLSearchParams(w).forEach((
|
|
3965
|
-
a.value[O] =
|
|
4061
|
+
a.value = {}, new URLSearchParams(w).forEach((_, O) => {
|
|
4062
|
+
a.value[O] = _;
|
|
3966
4063
|
});
|
|
3967
4064
|
});
|
|
3968
4065
|
const d = () => {
|
|
@@ -3973,33 +4070,33 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
3973
4070
|
r("update:modelValue", w);
|
|
3974
4071
|
}, g = () => {
|
|
3975
4072
|
p("");
|
|
3976
|
-
},
|
|
3977
|
-
var
|
|
3978
|
-
return (((O = (
|
|
3979
|
-
},
|
|
3980
|
-
var
|
|
3981
|
-
return ((O = (
|
|
3982
|
-
},
|
|
4073
|
+
}, y = (w) => `filter-${w}`, x = (w) => {
|
|
4074
|
+
var _, O;
|
|
4075
|
+
return (((O = (_ = i.config.schema) == null ? void 0 : _[w]) == null ? void 0 : O.values) ?? []).map((f) => typeof f == "string" ? { value: f, label: f } : f);
|
|
4076
|
+
}, h = (w) => {
|
|
4077
|
+
var _, O;
|
|
4078
|
+
return ((O = (_ = i.config.schema) == null ? void 0 : _[w]) == null ? void 0 : O.type) ?? "text";
|
|
4079
|
+
}, A = (w) => {
|
|
3983
4080
|
a.value = {
|
|
3984
4081
|
...a.value,
|
|
3985
4082
|
[w]: ""
|
|
3986
|
-
},
|
|
4083
|
+
}, E();
|
|
3987
4084
|
}, C = () => {
|
|
3988
|
-
a.value = {},
|
|
3989
|
-
},
|
|
3990
|
-
const
|
|
3991
|
-
w && (o.value = !1), r("update:modelValue", new URLSearchParams(
|
|
3992
|
-
},
|
|
3993
|
-
var
|
|
3994
|
-
return !!((O = (
|
|
3995
|
-
}, X = (w,
|
|
4085
|
+
a.value = {}, E(!0);
|
|
4086
|
+
}, E = (w = !1) => {
|
|
4087
|
+
const _ = Object.keys(a.value).reduce((O, f) => (a.value[f] && (O[f] = `${a.value[f]}`), O), {});
|
|
4088
|
+
w && (o.value = !1), r("update:modelValue", new URLSearchParams(_).toString());
|
|
4089
|
+
}, Y = (w) => {
|
|
4090
|
+
var _, O;
|
|
4091
|
+
return !!((O = (_ = i.config.schema) == null ? void 0 : _[w]) != null && O.filterFunction);
|
|
4092
|
+
}, X = (w, _) => {
|
|
3996
4093
|
var f;
|
|
3997
4094
|
const O = (f = i.config.schema) == null ? void 0 : f[w];
|
|
3998
|
-
return (O == null ? void 0 : O.filterFunction) === void 0 ? !0 : O.filterFunction(
|
|
4095
|
+
return (O == null ? void 0 : O.filterFunction) === void 0 ? !0 : O.filterFunction(_);
|
|
3999
4096
|
};
|
|
4000
|
-
return (w,
|
|
4097
|
+
return (w, _) => {
|
|
4001
4098
|
const O = P("KInput"), f = P("KButton"), v = P("KSelect");
|
|
4002
|
-
return e.config.isExactMatch ? (m(),
|
|
4099
|
+
return e.config.isExactMatch ? (m(), j(O, {
|
|
4003
4100
|
key: 0,
|
|
4004
4101
|
autocomplete: "off",
|
|
4005
4102
|
class: "kong-ui-entity-filter-input",
|
|
@@ -4008,11 +4105,11 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4008
4105
|
placeholder: e.config.placeholder,
|
|
4009
4106
|
"onUpdate:modelValue": p
|
|
4010
4107
|
}, {
|
|
4011
|
-
before:
|
|
4012
|
-
|
|
4108
|
+
before: k(() => [
|
|
4109
|
+
K(Mt)
|
|
4013
4110
|
]),
|
|
4014
|
-
after:
|
|
4015
|
-
xe(
|
|
4111
|
+
after: k(() => [
|
|
4112
|
+
xe(K(T(oi), {
|
|
4016
4113
|
class: "kong-ui-entity-filter-clear",
|
|
4017
4114
|
role: "button",
|
|
4018
4115
|
tabindex: "0",
|
|
@@ -4022,110 +4119,110 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4022
4119
|
])
|
|
4023
4120
|
]),
|
|
4024
4121
|
_: 1
|
|
4025
|
-
}, 8, ["model-value", "placeholder"])) : (m(), S("div",
|
|
4026
|
-
|
|
4122
|
+
}, 8, ["model-value", "placeholder"])) : (m(), S("div", yl, [
|
|
4123
|
+
K(f, {
|
|
4027
4124
|
appearance: "tertiary",
|
|
4028
4125
|
"data-testid": "filter-button",
|
|
4029
4126
|
onClick: d
|
|
4030
4127
|
}, {
|
|
4031
|
-
default:
|
|
4032
|
-
|
|
4033
|
-
|
|
4128
|
+
default: k(() => [
|
|
4129
|
+
K(Mt),
|
|
4130
|
+
U(" " + L(T(n)("filter.filterButtonText")) + " " + L(l.value.length > 0 ? `(${l.value.length})` : ""), 1)
|
|
4034
4131
|
]),
|
|
4035
4132
|
_: 1
|
|
4036
4133
|
}),
|
|
4037
|
-
xe(
|
|
4134
|
+
xe(B("div", {
|
|
4038
4135
|
class: "kong-ui-entity-filter-backdrop",
|
|
4039
4136
|
onClick: d
|
|
4040
4137
|
}, null, 512), [
|
|
4041
4138
|
[Ce, o.value]
|
|
4042
4139
|
]),
|
|
4043
|
-
xe(
|
|
4140
|
+
xe(B("div", gl, [
|
|
4044
4141
|
(m(!0), S(ue, null, ce(c.value, (b) => {
|
|
4045
|
-
var H,
|
|
4142
|
+
var H, J;
|
|
4046
4143
|
return m(), S("div", {
|
|
4047
4144
|
key: b.value,
|
|
4048
4145
|
class: "kong-ui-entity-filter-menu-item",
|
|
4049
4146
|
"data-testid": b.value
|
|
4050
4147
|
}, [
|
|
4051
|
-
|
|
4148
|
+
B("span", {
|
|
4052
4149
|
class: fe(["menu-item-title", { expanded: s.value.has(b.value) }]),
|
|
4053
4150
|
role: "button",
|
|
4054
4151
|
tabindex: "0",
|
|
4055
4152
|
onClick: (I) => u(b.value),
|
|
4056
|
-
onKeydown:
|
|
4153
|
+
onKeydown: Xn((I) => u(b.value), ["enter"])
|
|
4057
4154
|
}, [
|
|
4058
|
-
|
|
4059
|
-
xe(
|
|
4155
|
+
U(L(b.label) + " ", 1),
|
|
4156
|
+
xe(B("span", bl, null, 512), [
|
|
4060
4157
|
[Ce, l.value.includes(b.value)]
|
|
4061
4158
|
]),
|
|
4062
|
-
|
|
4159
|
+
K(T(li), {
|
|
4063
4160
|
class: fe(["menu-item-expand-icon", { expanded: s.value.has(b.value) }]),
|
|
4064
|
-
color:
|
|
4161
|
+
color: T(er)
|
|
4065
4162
|
}, null, 8, ["class", "color"])
|
|
4066
|
-
], 42,
|
|
4067
|
-
xe(
|
|
4068
|
-
|
|
4163
|
+
], 42, vl),
|
|
4164
|
+
xe(B("div", xl, [
|
|
4165
|
+
B("label", {
|
|
4069
4166
|
class: "menu-item-label",
|
|
4070
|
-
for:
|
|
4071
|
-
}, L(
|
|
4072
|
-
((
|
|
4167
|
+
for: y(b.value)
|
|
4168
|
+
}, L(T(n)("filter.fieldLabel")), 9, Cl),
|
|
4169
|
+
((J = (H = e.config.schema) == null ? void 0 : H[b.value]) == null ? void 0 : J.type) === "select" ? (m(), j(v, {
|
|
4073
4170
|
key: 0,
|
|
4074
|
-
id:
|
|
4171
|
+
id: y(b.value),
|
|
4075
4172
|
modelValue: a.value[b.value],
|
|
4076
4173
|
"onUpdate:modelValue": (I) => a.value[b.value] = I,
|
|
4077
|
-
"enable-filtering":
|
|
4174
|
+
"enable-filtering": Y(b.value),
|
|
4078
4175
|
"filter-function": (I) => X(b.value, I),
|
|
4079
4176
|
items: x(b.value),
|
|
4080
|
-
placeholder:
|
|
4081
|
-
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "enable-filtering", "filter-function", "items", "placeholder"])) : (m(),
|
|
4177
|
+
placeholder: T(n)("filter.selectPlaceholder")
|
|
4178
|
+
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "enable-filtering", "filter-function", "items", "placeholder"])) : (m(), j(O, {
|
|
4082
4179
|
key: 1,
|
|
4083
|
-
id:
|
|
4180
|
+
id: y(b.value),
|
|
4084
4181
|
modelValue: a.value[b.value],
|
|
4085
4182
|
"onUpdate:modelValue": (I) => a.value[b.value] = I,
|
|
4086
4183
|
autocomplete: "off",
|
|
4087
|
-
placeholder:
|
|
4088
|
-
type:
|
|
4184
|
+
placeholder: T(n)("filter.inputPlaceholder"),
|
|
4185
|
+
type: h(b.value)
|
|
4089
4186
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
4090
4187
|
], 512), [
|
|
4091
4188
|
[Ce, s.value.has(b.value)]
|
|
4092
4189
|
]),
|
|
4093
|
-
xe(
|
|
4094
|
-
|
|
4190
|
+
xe(B("div", kl, [
|
|
4191
|
+
K(f, {
|
|
4095
4192
|
appearance: "tertiary",
|
|
4096
4193
|
"data-testid": "apply-filter",
|
|
4097
4194
|
size: "small",
|
|
4098
|
-
onClick:
|
|
4195
|
+
onClick: _[0] || (_[0] = (I) => E(!0))
|
|
4099
4196
|
}, {
|
|
4100
|
-
default:
|
|
4101
|
-
|
|
4197
|
+
default: k(() => [
|
|
4198
|
+
U(L(T(n)("filter.applyButtonText")), 1)
|
|
4102
4199
|
]),
|
|
4103
4200
|
_: 1
|
|
4104
4201
|
}),
|
|
4105
|
-
|
|
4202
|
+
K(f, {
|
|
4106
4203
|
appearance: "tertiary",
|
|
4107
4204
|
"data-testid": "clear-filter",
|
|
4108
4205
|
size: "small",
|
|
4109
|
-
onClick: (I) =>
|
|
4206
|
+
onClick: (I) => A(b.value)
|
|
4110
4207
|
}, {
|
|
4111
|
-
default:
|
|
4112
|
-
|
|
4208
|
+
default: k(() => [
|
|
4209
|
+
U(L(T(n)("filter.clearButtonText")), 1)
|
|
4113
4210
|
]),
|
|
4114
4211
|
_: 1
|
|
4115
4212
|
}, 8, ["onClick"])
|
|
4116
4213
|
], 512), [
|
|
4117
4214
|
[Ce, s.value.has(b.value)]
|
|
4118
4215
|
])
|
|
4119
|
-
], 8,
|
|
4216
|
+
], 8, hl);
|
|
4120
4217
|
}), 128)),
|
|
4121
|
-
|
|
4122
|
-
|
|
4218
|
+
B("div", Al, [
|
|
4219
|
+
K(f, {
|
|
4123
4220
|
appearance: "tertiary",
|
|
4124
4221
|
size: "small",
|
|
4125
4222
|
onClick: C
|
|
4126
4223
|
}, {
|
|
4127
|
-
default:
|
|
4128
|
-
|
|
4224
|
+
default: k(() => [
|
|
4225
|
+
U(L(T(n)("filter.clearAllButtonText")), 1)
|
|
4129
4226
|
]),
|
|
4130
4227
|
_: 1
|
|
4131
4228
|
})
|
|
@@ -4136,7 +4233,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4136
4233
|
]));
|
|
4137
4234
|
};
|
|
4138
4235
|
}
|
|
4139
|
-
}),
|
|
4236
|
+
}), Cs = /* @__PURE__ */ se(_l, [["__scopeId", "data-v-084f7978"]]), ks = /* @__PURE__ */ z({
|
|
4140
4237
|
__name: "EntityToggleModal",
|
|
4141
4238
|
props: {
|
|
4142
4239
|
visible: {
|
|
@@ -4168,9 +4265,9 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4168
4265
|
},
|
|
4169
4266
|
emits: ["cancel", "proceed"],
|
|
4170
4267
|
setup(e, { emit: t }) {
|
|
4171
|
-
const { i18n: { t: n }, i18nT: i } = W.useI18n(), r = e, o = t, a =
|
|
4268
|
+
const { i18n: { t: n }, i18nT: i } = W.useI18n(), r = e, o = t, a = N(!1), s = $(
|
|
4172
4269
|
() => r.action === "enable" ? n("toggleModal.enable.title", { entityType: r.entityType }) : n("toggleModal.disable.title", { entityType: r.entityType })
|
|
4173
|
-
), l =
|
|
4270
|
+
), l = $(
|
|
4174
4271
|
() => r.action === "enable" ? n("toggleModal.enable.confirmText") : n("toggleModal.disable.confirmText")
|
|
4175
4272
|
), c = () => o("cancel"), d = async () => {
|
|
4176
4273
|
if (r.onConfirm) {
|
|
@@ -4186,8 +4283,8 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4186
4283
|
};
|
|
4187
4284
|
return (u, p) => {
|
|
4188
4285
|
const g = P("KPrompt");
|
|
4189
|
-
return m(),
|
|
4190
|
-
|
|
4286
|
+
return m(), j(Ht, { to: "body" }, [
|
|
4287
|
+
K(g, {
|
|
4191
4288
|
"action-button-disabled": a.value,
|
|
4192
4289
|
"action-button-text": l.value,
|
|
4193
4290
|
"data-testid": `${e.entityType}-${e.entityId}-toggle-prompt`,
|
|
@@ -4196,16 +4293,16 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4196
4293
|
onCancel: c,
|
|
4197
4294
|
onProceed: d
|
|
4198
4295
|
}, {
|
|
4199
|
-
default:
|
|
4200
|
-
|
|
4296
|
+
default: k(() => [
|
|
4297
|
+
K(T(i), {
|
|
4201
4298
|
keypath: `toggleModal.${r.action}.message`,
|
|
4202
4299
|
scope: "global"
|
|
4203
4300
|
}, {
|
|
4204
|
-
entityType:
|
|
4205
|
-
|
|
4301
|
+
entityType: k(() => [
|
|
4302
|
+
U(L(e.entityType), 1)
|
|
4206
4303
|
]),
|
|
4207
|
-
entityName:
|
|
4208
|
-
|
|
4304
|
+
entityName: k(() => [
|
|
4305
|
+
B("strong", null, L(e.entityName), 1)
|
|
4209
4306
|
]),
|
|
4210
4307
|
_: 1
|
|
4211
4308
|
}, 8, ["keypath"])
|
|
@@ -4215,7 +4312,7 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4215
4312
|
]);
|
|
4216
4313
|
};
|
|
4217
4314
|
}
|
|
4218
|
-
}),
|
|
4315
|
+
}), As = /* @__PURE__ */ z({
|
|
4219
4316
|
__name: "PermissionsWrapper",
|
|
4220
4317
|
props: {
|
|
4221
4318
|
/**
|
|
@@ -4237,48 +4334,48 @@ const Ko = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */
|
|
|
4237
4334
|
}
|
|
4238
4335
|
},
|
|
4239
4336
|
setup(e) {
|
|
4240
|
-
const t = e, n =
|
|
4337
|
+
const t = e, n = N(void 0), i = $(() => n.value === !0 || n.value !== void 0 && t.forceShow === !0);
|
|
4241
4338
|
return be(() => t.authFunction, async () => {
|
|
4242
4339
|
n.value = await t.authFunction();
|
|
4243
|
-
}, { immediate: !0 }), (r, o) => i.value ?
|
|
4340
|
+
}, { immediate: !0 }), (r, o) => i.value ? D(r.$slots, "default", {
|
|
4244
4341
|
key: 0,
|
|
4245
4342
|
isAllowed: n.value
|
|
4246
|
-
}) :
|
|
4343
|
+
}) : M("", !0);
|
|
4247
4344
|
}
|
|
4248
4345
|
}), te = [];
|
|
4249
4346
|
for (let e = 0; e < 256; ++e)
|
|
4250
4347
|
te.push((e + 256).toString(16).slice(1));
|
|
4251
|
-
function
|
|
4348
|
+
function wl(e, t = 0) {
|
|
4252
4349
|
return (te[e[t + 0]] + te[e[t + 1]] + te[e[t + 2]] + te[e[t + 3]] + "-" + te[e[t + 4]] + te[e[t + 5]] + "-" + te[e[t + 6]] + te[e[t + 7]] + "-" + te[e[t + 8]] + te[e[t + 9]] + "-" + te[e[t + 10]] + te[e[t + 11]] + te[e[t + 12]] + te[e[t + 13]] + te[e[t + 14]] + te[e[t + 15]]).toLowerCase();
|
|
4253
4350
|
}
|
|
4254
|
-
let
|
|
4255
|
-
const
|
|
4256
|
-
function
|
|
4257
|
-
if (!
|
|
4351
|
+
let Ge;
|
|
4352
|
+
const Sl = new Uint8Array(16);
|
|
4353
|
+
function $l() {
|
|
4354
|
+
if (!Ge) {
|
|
4258
4355
|
if (typeof crypto > "u" || !crypto.getRandomValues)
|
|
4259
4356
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
4260
|
-
|
|
4357
|
+
Ge = crypto.getRandomValues.bind(crypto);
|
|
4261
4358
|
}
|
|
4262
|
-
return
|
|
4359
|
+
return Ge(Sl);
|
|
4263
4360
|
}
|
|
4264
|
-
const
|
|
4265
|
-
function
|
|
4361
|
+
const Tl = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), jt = { randomUUID: Tl };
|
|
4362
|
+
function El(e, t, n) {
|
|
4266
4363
|
var r;
|
|
4267
4364
|
if (jt.randomUUID && !e)
|
|
4268
4365
|
return jt.randomUUID();
|
|
4269
4366
|
e = e || {};
|
|
4270
|
-
const i = e.random ?? ((r = e.rng) == null ? void 0 : r.call(e)) ??
|
|
4367
|
+
const i = e.random ?? ((r = e.rng) == null ? void 0 : r.call(e)) ?? $l();
|
|
4271
4368
|
if (i.length < 16)
|
|
4272
4369
|
throw new Error("Random bytes length must be >= 16");
|
|
4273
|
-
return i[6] = i[6] & 15 | 64, i[8] = i[8] & 63 | 128,
|
|
4370
|
+
return i[6] = i[6] & 15 | 64, i[8] = i[8] & 63 | 128, wl(i);
|
|
4274
4371
|
}
|
|
4275
|
-
const
|
|
4372
|
+
const Il = ["aria-labelledby"], Fl = { class: "form-section-wrapper" }, Ol = {
|
|
4276
4373
|
key: 1,
|
|
4277
4374
|
class: "form-section-description"
|
|
4278
|
-
},
|
|
4375
|
+
}, Ll = {
|
|
4279
4376
|
key: 2,
|
|
4280
4377
|
class: "form-section-footer"
|
|
4281
|
-
},
|
|
4378
|
+
}, Bl = { class: "form-section-content" }, Rl = /* @__PURE__ */ z({
|
|
4282
4379
|
__name: "EntityFormSection",
|
|
4283
4380
|
props: {
|
|
4284
4381
|
title: {
|
|
@@ -4307,52 +4404,52 @@ const Sl = ["aria-labelledby"], $l = { class: "form-section-wrapper" }, Tl = {
|
|
|
4307
4404
|
}
|
|
4308
4405
|
},
|
|
4309
4406
|
setup(e) {
|
|
4310
|
-
const t =
|
|
4407
|
+
const t = Pe(), n = El();
|
|
4311
4408
|
return (i, r) => (m(), S("div", {
|
|
4312
|
-
"aria-labelledby": e.title ?
|
|
4409
|
+
"aria-labelledby": e.title ? T(n) : void 0,
|
|
4313
4410
|
class: fe(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }]),
|
|
4314
4411
|
role: "group"
|
|
4315
4412
|
}, [
|
|
4316
|
-
|
|
4317
|
-
e.hideInfoHeader ?
|
|
4413
|
+
B("div", Fl, [
|
|
4414
|
+
e.hideInfoHeader ? M("", !0) : (m(), S("div", {
|
|
4318
4415
|
key: 0,
|
|
4319
4416
|
class: fe(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
4320
4417
|
}, [
|
|
4321
|
-
e.title ? (m(),
|
|
4418
|
+
e.title ? (m(), j(De(e.titleTag), {
|
|
4322
4419
|
key: 0,
|
|
4323
|
-
id:
|
|
4420
|
+
id: T(n),
|
|
4324
4421
|
class: "form-section-title"
|
|
4325
4422
|
}, {
|
|
4326
|
-
default:
|
|
4327
|
-
|
|
4423
|
+
default: k(() => [
|
|
4424
|
+
U(L(e.title), 1)
|
|
4328
4425
|
]),
|
|
4329
4426
|
_: 1
|
|
4330
|
-
}, 8, ["id"])) :
|
|
4331
|
-
e.description ||
|
|
4332
|
-
|
|
4333
|
-
|
|
4427
|
+
}, 8, ["id"])) : M("", !0),
|
|
4428
|
+
e.description || T(t).description ? (m(), S("div", Ol, [
|
|
4429
|
+
D(i.$slots, "description", {}, () => [
|
|
4430
|
+
B("p", null, L(e.description), 1)
|
|
4334
4431
|
], !0)
|
|
4335
|
-
])) :
|
|
4336
|
-
|
|
4337
|
-
|
|
4338
|
-
])) :
|
|
4432
|
+
])) : M("", !0),
|
|
4433
|
+
T(t).footer ? (m(), S("div", Ll, [
|
|
4434
|
+
D(i.$slots, "footer", {}, void 0, !0)
|
|
4435
|
+
])) : M("", !0)
|
|
4339
4436
|
], 2)),
|
|
4340
|
-
|
|
4341
|
-
|
|
4437
|
+
B("div", Bl, [
|
|
4438
|
+
D(i.$slots, "default", {}, void 0, !0)
|
|
4342
4439
|
])
|
|
4343
4440
|
])
|
|
4344
|
-
], 10,
|
|
4441
|
+
], 10, Il));
|
|
4345
4442
|
}
|
|
4346
|
-
}),
|
|
4443
|
+
}), _s = /* @__PURE__ */ se(Rl, [["__scopeId", "data-v-b1f74200"]]), Kl = { class: "ff-form-section" }, Nl = { class: "header" }, Ml = {
|
|
4347
4444
|
key: 0,
|
|
4348
4445
|
class: "step"
|
|
4349
|
-
},
|
|
4446
|
+
}, jl = { class: "header-content" }, Dl = { class: "header-title" }, Pl = {
|
|
4350
4447
|
key: 0,
|
|
4351
4448
|
class: "header-description"
|
|
4352
|
-
},
|
|
4449
|
+
}, Ul = {
|
|
4353
4450
|
key: 1,
|
|
4354
4451
|
class: "header-extra"
|
|
4355
|
-
},
|
|
4452
|
+
}, ql = { class: "content" }, Hl = /* @__PURE__ */ z({
|
|
4356
4453
|
__name: "EntityFormBlock",
|
|
4357
4454
|
props: {
|
|
4358
4455
|
step: {},
|
|
@@ -4360,38 +4457,38 @@ const Sl = ["aria-labelledby"], $l = { class: "form-section-wrapper" }, Tl = {
|
|
|
4360
4457
|
description: { default: "" }
|
|
4361
4458
|
},
|
|
4362
4459
|
setup(e) {
|
|
4363
|
-
const t =
|
|
4364
|
-
return (n, i) => (m(), S("div",
|
|
4365
|
-
|
|
4366
|
-
e.step != null ? (m(), S("div",
|
|
4367
|
-
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4460
|
+
const t = Pe();
|
|
4461
|
+
return (n, i) => (m(), S("div", Kl, [
|
|
4462
|
+
B("header", Nl, [
|
|
4463
|
+
e.step != null ? (m(), S("div", Ml, L(e.step), 1)) : M("", !0),
|
|
4464
|
+
B("div", jl, [
|
|
4465
|
+
B("h2", Dl, [
|
|
4466
|
+
D(n.$slots, "title", {}, () => [
|
|
4467
|
+
U(L(e.title), 1)
|
|
4371
4468
|
], !0)
|
|
4372
4469
|
]),
|
|
4373
|
-
e.description || t.description ? (m(), S("div",
|
|
4374
|
-
|
|
4375
|
-
|
|
4470
|
+
e.description || t.description ? (m(), S("div", Pl, [
|
|
4471
|
+
D(n.$slots, "description", {}, () => [
|
|
4472
|
+
U(L(e.description), 1)
|
|
4376
4473
|
], !0)
|
|
4377
|
-
])) :
|
|
4474
|
+
])) : M("", !0)
|
|
4378
4475
|
]),
|
|
4379
|
-
t.extra ? (m(), S("div",
|
|
4380
|
-
|
|
4381
|
-
])) :
|
|
4476
|
+
t.extra ? (m(), S("div", Ul, [
|
|
4477
|
+
D(n.$slots, "extra", {}, void 0, !0)
|
|
4478
|
+
])) : M("", !0)
|
|
4382
4479
|
]),
|
|
4383
|
-
|
|
4384
|
-
|
|
4480
|
+
B("div", ql, [
|
|
4481
|
+
D(n.$slots, "default", {}, void 0, !0)
|
|
4385
4482
|
])
|
|
4386
4483
|
]));
|
|
4387
4484
|
}
|
|
4388
|
-
}),
|
|
4485
|
+
}), ws = /* @__PURE__ */ se(Hl, [["__scopeId", "data-v-cb6d2e95"]]), Vl = {
|
|
4389
4486
|
class: "kong-ui-public-entity-link",
|
|
4390
4487
|
"data-testid": "entity-link-parent"
|
|
4391
|
-
},
|
|
4488
|
+
}, Yl = {
|
|
4392
4489
|
key: 0,
|
|
4393
4490
|
class: "deleted-entity"
|
|
4394
|
-
},
|
|
4491
|
+
}, Wl = { key: 1 }, Jl = ["onClick"], Gl = /* @__PURE__ */ z({
|
|
4395
4492
|
__name: "EntityLink",
|
|
4396
4493
|
props: {
|
|
4397
4494
|
entityLinkData: {
|
|
@@ -4415,10 +4512,10 @@ const Sl = ["aria-labelledby"], $l = { class: "form-section-wrapper" }, Tl = {
|
|
|
4415
4512
|
}
|
|
4416
4513
|
},
|
|
4417
4514
|
setup(e) {
|
|
4418
|
-
const t = e, n =
|
|
4515
|
+
const t = e, n = N(), { isTruncated: i } = W.useTruncationDetector(n), { i18n: { t: r } } = W.useI18n(), o = r("global.actions.copyId"), a = N(o), s = $(() => t.entityLinkData.deleted ?? !1), l = $(() => {
|
|
4419
4516
|
var u;
|
|
4420
4517
|
return (u = t.entityLinkData.id) != null && u.toString().includes(":") ? t.entityLinkData.id.toString().split(":")[1] : t.entityLinkData.id;
|
|
4421
|
-
}), c =
|
|
4518
|
+
}), c = $(() => {
|
|
4422
4519
|
var u;
|
|
4423
4520
|
return `${(u = l.value) == null ? void 0 : u.toString().slice(0, 5)} (deleted)`;
|
|
4424
4521
|
}), d = async (u) => {
|
|
@@ -4427,21 +4524,21 @@ const Sl = ["aria-labelledby"], $l = { class: "form-section-wrapper" }, Tl = {
|
|
|
4427
4524
|
}, 1800));
|
|
4428
4525
|
};
|
|
4429
4526
|
return (u, p) => {
|
|
4430
|
-
const g = P("KTooltip"),
|
|
4431
|
-
return m(), S("div",
|
|
4432
|
-
s.value ? (m(), S("div",
|
|
4527
|
+
const g = P("KTooltip"), y = P("KExternalLink"), x = P("KClipboardProvider");
|
|
4528
|
+
return m(), S("div", Vl, [
|
|
4529
|
+
s.value ? (m(), S("div", Yl, L(c.value), 1)) : l.value ? l.value ? (m(), j(y, {
|
|
4433
4530
|
key: 2,
|
|
4434
4531
|
class: "entity-link",
|
|
4435
4532
|
"hide-icon": !e.newWindow,
|
|
4436
4533
|
href: e.externalLink,
|
|
4437
4534
|
target: e.newWindow ? "_blank" : "_self"
|
|
4438
4535
|
}, {
|
|
4439
|
-
default:
|
|
4440
|
-
|
|
4441
|
-
text:
|
|
4536
|
+
default: k(() => [
|
|
4537
|
+
K(g, {
|
|
4538
|
+
text: T(i) && e.entityLinkData.label || ""
|
|
4442
4539
|
}, {
|
|
4443
|
-
default:
|
|
4444
|
-
|
|
4540
|
+
default: k(() => [
|
|
4541
|
+
B("span", {
|
|
4445
4542
|
ref_key: "textContent",
|
|
4446
4543
|
ref: n,
|
|
4447
4544
|
class: "entity-link-label"
|
|
@@ -4451,71 +4548,71 @@ const Sl = ["aria-labelledby"], $l = { class: "form-section-wrapper" }, Tl = {
|
|
|
4451
4548
|
}, 8, ["text"])
|
|
4452
4549
|
]),
|
|
4453
4550
|
_: 1
|
|
4454
|
-
}, 8, ["hide-icon", "href", "target"])) :
|
|
4455
|
-
l.value && e.allowCopy ? (m(),
|
|
4551
|
+
}, 8, ["hide-icon", "href", "target"])) : M("", !0) : (m(), S("div", Wl, L(" – "))),
|
|
4552
|
+
l.value && e.allowCopy ? (m(), j(g, {
|
|
4456
4553
|
key: a.value,
|
|
4457
4554
|
class: "copy-uuid-tooltip",
|
|
4458
4555
|
"max-width": "160",
|
|
4459
4556
|
placement: "bottom-end",
|
|
4460
4557
|
text: a.value
|
|
4461
4558
|
}, {
|
|
4462
|
-
default:
|
|
4463
|
-
|
|
4464
|
-
default:
|
|
4465
|
-
|
|
4559
|
+
default: k(() => [
|
|
4560
|
+
K(x, null, {
|
|
4561
|
+
default: k(({ copyToClipboard: h }) => [
|
|
4562
|
+
B("span", {
|
|
4466
4563
|
class: "entity-link-copy-id",
|
|
4467
|
-
onClick:
|
|
4564
|
+
onClick: Be((A) => d(h), ["stop"])
|
|
4468
4565
|
}, [
|
|
4469
|
-
|
|
4566
|
+
K(T(si), {
|
|
4470
4567
|
class: "copy-icon",
|
|
4471
|
-
color:
|
|
4568
|
+
color: T(tr),
|
|
4472
4569
|
"data-testid": "copy-id",
|
|
4473
|
-
size:
|
|
4570
|
+
size: T(ir)
|
|
4474
4571
|
}, null, 8, ["color", "size"])
|
|
4475
|
-
], 8,
|
|
4572
|
+
], 8, Jl)
|
|
4476
4573
|
]),
|
|
4477
4574
|
_: 1
|
|
4478
4575
|
})
|
|
4479
4576
|
]),
|
|
4480
4577
|
_: 1
|
|
4481
|
-
}, 8, ["text"])) :
|
|
4578
|
+
}, 8, ["text"])) : M("", !0)
|
|
4482
4579
|
]);
|
|
4483
4580
|
};
|
|
4484
4581
|
}
|
|
4485
|
-
}),
|
|
4582
|
+
}), Ss = /* @__PURE__ */ se(Gl, [["__scopeId", "data-v-96efdfa5"]]), zl = { class: "kong-ui-public-entity-empty-state" }, Ql = { class: "entity-empty-state-content" }, Zl = {
|
|
4486
4583
|
key: 0,
|
|
4487
4584
|
class: "empty-state-image"
|
|
4488
|
-
},
|
|
4585
|
+
}, Xl = {
|
|
4489
4586
|
key: 1,
|
|
4490
4587
|
class: "entity-empty-state-title"
|
|
4491
|
-
},
|
|
4588
|
+
}, es = {
|
|
4492
4589
|
key: 2,
|
|
4493
4590
|
class: "entity-empty-state-description"
|
|
4494
|
-
},
|
|
4591
|
+
}, ts = {
|
|
4495
4592
|
key: 3,
|
|
4496
4593
|
class: "entity-empty-state-pricing"
|
|
4497
|
-
},
|
|
4594
|
+
}, ns = {
|
|
4498
4595
|
key: 0,
|
|
4499
4596
|
class: "entity-empty-state-message"
|
|
4500
|
-
},
|
|
4597
|
+
}, is = {
|
|
4501
4598
|
key: 1,
|
|
4502
4599
|
class: "entity-empty-state-action"
|
|
4503
|
-
},
|
|
4600
|
+
}, rs = {
|
|
4504
4601
|
key: 2,
|
|
4505
4602
|
class: "entity-empty-state-card-container"
|
|
4506
|
-
},
|
|
4603
|
+
}, as = {
|
|
4507
4604
|
key: 0,
|
|
4508
4605
|
class: "feature-icon"
|
|
4509
|
-
},
|
|
4606
|
+
}, os = { class: "card-header" }, ls = ["title"], ss = {
|
|
4510
4607
|
key: 3,
|
|
4511
4608
|
class: "entity-empty-state-bottom-container"
|
|
4512
|
-
},
|
|
4609
|
+
}, cs = /* @__PURE__ */ z({
|
|
4513
4610
|
__name: "EntityEmptyState",
|
|
4514
4611
|
props: {
|
|
4515
4612
|
appearance: {
|
|
4516
4613
|
type: String,
|
|
4517
4614
|
default: () => "primary",
|
|
4518
|
-
validator: (e) =>
|
|
4615
|
+
validator: (e) => yt.includes(e)
|
|
4519
4616
|
},
|
|
4520
4617
|
title: {
|
|
4521
4618
|
type: String,
|
|
@@ -4550,100 +4647,100 @@ const Sl = ["aria-labelledby"], $l = { class: "form-section-wrapper" }, Tl = {
|
|
|
4550
4647
|
},
|
|
4551
4648
|
emits: ["click:create", "click:learn-more"],
|
|
4552
4649
|
setup(e) {
|
|
4553
|
-
const t = e, { i18n: { t: n } } = W.useI18n(), i =
|
|
4554
|
-
return
|
|
4650
|
+
const t = e, { i18n: { t: n } } = W.useI18n(), i = N(!1), r = $(() => i.value && !!t.actionButtonText), o = $(() => yt.includes(t.appearance) ? t.appearance : ["primary", t.appearance]);
|
|
4651
|
+
return it(async () => {
|
|
4555
4652
|
i.value = await t.canCreate();
|
|
4556
|
-
}),
|
|
4653
|
+
}), nt(() => ei(`EntityEmptyState is deprecated and will be removed in future releases. Please use the KEmptyState component instead.
|
|
4557
4654
|
Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) => {
|
|
4558
4655
|
const l = P("KCard");
|
|
4559
|
-
return m(), S("div",
|
|
4560
|
-
|
|
4561
|
-
a.$slots.image ? (m(), S("div",
|
|
4562
|
-
|
|
4563
|
-
])) :
|
|
4564
|
-
e.title || a.$slots.title ? (m(), S("div",
|
|
4565
|
-
|
|
4656
|
+
return m(), S("div", zl, [
|
|
4657
|
+
B("div", Ql, [
|
|
4658
|
+
a.$slots.image ? (m(), S("div", Zl, [
|
|
4659
|
+
D(a.$slots, "image", {}, void 0, !0)
|
|
4660
|
+
])) : M("", !0),
|
|
4661
|
+
e.title || a.$slots.title ? (m(), S("div", Xl, [
|
|
4662
|
+
B("h1", {
|
|
4566
4663
|
class: fe(o.value)
|
|
4567
4664
|
}, [
|
|
4568
|
-
|
|
4569
|
-
|
|
4665
|
+
D(a.$slots, "title", {}, () => [
|
|
4666
|
+
U(L(e.title), 1)
|
|
4570
4667
|
], !0)
|
|
4571
4668
|
], 2)
|
|
4572
|
-
])) :
|
|
4573
|
-
e.description || a.$slots.default ? (m(), S("div",
|
|
4574
|
-
|
|
4575
|
-
|
|
4669
|
+
])) : M("", !0),
|
|
4670
|
+
e.description || a.$slots.default ? (m(), S("div", es, [
|
|
4671
|
+
D(a.$slots, "default", {}, () => [
|
|
4672
|
+
B("p", null, L(e.description), 1)
|
|
4576
4673
|
], !0)
|
|
4577
|
-
])) :
|
|
4578
|
-
e.pricing || a.$slots.pricing ? (m(), S("div",
|
|
4579
|
-
|
|
4580
|
-
|
|
4581
|
-
s[2] || (s[2] =
|
|
4582
|
-
|
|
4583
|
-
|
|
4674
|
+
])) : M("", !0),
|
|
4675
|
+
e.pricing || a.$slots.pricing ? (m(), S("div", ts, [
|
|
4676
|
+
B("p", null, [
|
|
4677
|
+
B("b", null, L(T(n)("emptyState.pricingTitle")), 1),
|
|
4678
|
+
s[2] || (s[2] = U()),
|
|
4679
|
+
D(a.$slots, "pricing", {}, () => [
|
|
4680
|
+
U(L(e.pricing), 1)
|
|
4584
4681
|
], !0)
|
|
4585
4682
|
])
|
|
4586
|
-
])) :
|
|
4683
|
+
])) : M("", !0)
|
|
4587
4684
|
]),
|
|
4588
|
-
a.$slots.message ? (m(), S("div",
|
|
4589
|
-
|
|
4590
|
-
])) :
|
|
4591
|
-
r.value || e.learnMore || a.$slots.actions ? (m(), S("div",
|
|
4592
|
-
|
|
4593
|
-
r.value ? (m(),
|
|
4685
|
+
a.$slots.message ? (m(), S("div", ns, [
|
|
4686
|
+
D(a.$slots, "message", {}, void 0, !0)
|
|
4687
|
+
])) : M("", !0),
|
|
4688
|
+
r.value || e.learnMore || a.$slots.actions ? (m(), S("div", is, [
|
|
4689
|
+
D(a.$slots, "actions", {}, () => [
|
|
4690
|
+
r.value ? (m(), j(T(mt), {
|
|
4594
4691
|
key: 0,
|
|
4595
4692
|
appearance: "primary",
|
|
4596
4693
|
"data-testid": "entity-create-button",
|
|
4597
4694
|
size: e.appearance === "secondary" ? "medium" : "large",
|
|
4598
4695
|
onClick: s[0] || (s[0] = (c) => a.$emit("click:create"))
|
|
4599
4696
|
}, {
|
|
4600
|
-
default:
|
|
4601
|
-
|
|
4602
|
-
|
|
4697
|
+
default: k(() => [
|
|
4698
|
+
K(T(Yt)),
|
|
4699
|
+
U(" " + L(e.actionButtonText), 1)
|
|
4603
4700
|
]),
|
|
4604
4701
|
_: 1
|
|
4605
|
-
}, 8, ["size"])) :
|
|
4606
|
-
e.learnMore ? (m(),
|
|
4702
|
+
}, 8, ["size"])) : M("", !0),
|
|
4703
|
+
e.learnMore ? (m(), j(T(mt), {
|
|
4607
4704
|
key: 1,
|
|
4608
4705
|
appearance: "secondary",
|
|
4609
4706
|
"data-testid": "entity-learn-more-button",
|
|
4610
4707
|
size: e.appearance === "secondary" ? "medium" : "large",
|
|
4611
4708
|
onClick: s[1] || (s[1] = (c) => a.$emit("click:learn-more"))
|
|
4612
4709
|
}, {
|
|
4613
|
-
default:
|
|
4614
|
-
|
|
4615
|
-
|
|
4710
|
+
default: k(() => [
|
|
4711
|
+
K(T(Vt), { decorative: "" }),
|
|
4712
|
+
U(" " + L(T(n)("emptyState.learnMore")), 1)
|
|
4616
4713
|
]),
|
|
4617
4714
|
_: 1
|
|
4618
|
-
}, 8, ["size"])) :
|
|
4715
|
+
}, 8, ["size"])) : M("", !0)
|
|
4619
4716
|
], !0)
|
|
4620
|
-
])) :
|
|
4621
|
-
e.features.length ? (m(), S("div",
|
|
4622
|
-
(m(!0), S(ue, null, ce(e.features, (c, d) => (m(),
|
|
4717
|
+
])) : M("", !0),
|
|
4718
|
+
e.features.length ? (m(), S("div", rs, [
|
|
4719
|
+
(m(!0), S(ue, null, ce(e.features, (c, d) => (m(), j(l, {
|
|
4623
4720
|
key: c,
|
|
4624
4721
|
class: "entity-empty-state-card"
|
|
4625
4722
|
}, {
|
|
4626
|
-
title:
|
|
4627
|
-
a.$slots[`feature-${d}-icon`] ? (m(), S("div",
|
|
4628
|
-
|
|
4629
|
-
])) :
|
|
4630
|
-
|
|
4723
|
+
title: k(() => [
|
|
4724
|
+
a.$slots[`feature-${d}-icon`] ? (m(), S("div", as, [
|
|
4725
|
+
D(a.$slots, `feature-${d}-icon`, {}, void 0, !0)
|
|
4726
|
+
])) : M("", !0),
|
|
4727
|
+
B("div", os, L(c.title), 1)
|
|
4631
4728
|
]),
|
|
4632
|
-
default:
|
|
4633
|
-
|
|
4729
|
+
default: k(() => [
|
|
4730
|
+
B("div", {
|
|
4634
4731
|
title: c.description
|
|
4635
|
-
}, L(c.description), 9,
|
|
4732
|
+
}, L(c.description), 9, ls)
|
|
4636
4733
|
]),
|
|
4637
4734
|
_: 2
|
|
4638
4735
|
}, 1024))), 128))
|
|
4639
|
-
])) :
|
|
4640
|
-
a.$slots.bottom ? (m(), S("div",
|
|
4641
|
-
|
|
4642
|
-
])) :
|
|
4736
|
+
])) : M("", !0),
|
|
4737
|
+
a.$slots.bottom ? (m(), S("div", ss, [
|
|
4738
|
+
D(a.$slots, "bottom", {}, void 0, !0)
|
|
4739
|
+
])) : M("", !0)
|
|
4643
4740
|
]);
|
|
4644
4741
|
};
|
|
4645
4742
|
}
|
|
4646
|
-
}),
|
|
4743
|
+
}), $s = /* @__PURE__ */ se(cs, [["__scopeId", "data-v-645aae54"]]), us = { key: 1 }, Ts = /* @__PURE__ */ z({
|
|
4647
4744
|
__name: "TableTags",
|
|
4648
4745
|
props: {
|
|
4649
4746
|
/** The tags to display in the table */
|
|
@@ -4657,7 +4754,7 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4657
4754
|
}
|
|
4658
4755
|
},
|
|
4659
4756
|
setup(e) {
|
|
4660
|
-
const t = e, n =
|
|
4757
|
+
const t = e, n = $(() => {
|
|
4661
4758
|
if (Array.isArray(t.tags))
|
|
4662
4759
|
return t.tags;
|
|
4663
4760
|
if (typeof t.tags == "string")
|
|
@@ -4671,66 +4768,68 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4671
4768
|
});
|
|
4672
4769
|
return (i, r) => {
|
|
4673
4770
|
var o;
|
|
4674
|
-
return ((o = n.value) == null ? void 0 : o.length) > 0 ? (m(),
|
|
4675
|
-
default:
|
|
4676
|
-
(m(!0), S(ue, null, ce(n.value, (a) => (m(),
|
|
4771
|
+
return ((o = n.value) == null ? void 0 : o.length) > 0 ? (m(), j(T(ri), { key: 0 }, {
|
|
4772
|
+
default: k(() => [
|
|
4773
|
+
(m(!0), S(ue, null, ce(n.value, (a) => (m(), j(T(ai), {
|
|
4677
4774
|
key: a,
|
|
4678
4775
|
"max-width": e.tagMaxWidth,
|
|
4679
|
-
onClick: r[0] || (r[0] =
|
|
4776
|
+
onClick: r[0] || (r[0] = Be(() => {
|
|
4680
4777
|
}, ["stop"]))
|
|
4681
4778
|
}, {
|
|
4682
|
-
default:
|
|
4683
|
-
|
|
4779
|
+
default: k(() => [
|
|
4780
|
+
U(L(a), 1)
|
|
4684
4781
|
]),
|
|
4685
4782
|
_: 2
|
|
4686
4783
|
}, 1032, ["max-width"]))), 128))
|
|
4687
4784
|
]),
|
|
4688
4785
|
_: 1
|
|
4689
|
-
})) : (m(), S("span",
|
|
4786
|
+
})) : (m(), S("span", us, "-"));
|
|
4690
4787
|
};
|
|
4691
4788
|
}
|
|
4692
|
-
}), { useAxios:
|
|
4789
|
+
}), { useAxios: Es, useDeleteUrlBuilder: Is, useErrors: Fs, useExternalLinkCreator: Os, useFetchUrlBuilder: Ls, useFetcher: Bs, useFetcherCacheKey: Rs, useDebouncedFilter: Ks, useStringHelpers: Ns, useHelpers: Ms, useGatewayFeatureSupported: js, useTruncationDetector: Ds, useValidators: Ps, useSchemaProvider: Us, useTableState: qs } = W;
|
|
4693
4790
|
export {
|
|
4694
|
-
|
|
4695
|
-
|
|
4696
|
-
|
|
4791
|
+
yt as Appearances,
|
|
4792
|
+
Yo as ConfigCardDisplay,
|
|
4793
|
+
Xt as ConfigCardItem,
|
|
4697
4794
|
ae as ConfigurationSchemaSection,
|
|
4698
4795
|
V as ConfigurationSchemaType,
|
|
4699
|
-
|
|
4700
|
-
|
|
4701
|
-
|
|
4702
|
-
|
|
4703
|
-
|
|
4704
|
-
|
|
4705
|
-
|
|
4706
|
-
Cs as
|
|
4707
|
-
|
|
4708
|
-
|
|
4709
|
-
|
|
4710
|
-
|
|
4711
|
-
|
|
4796
|
+
Wn as DeckCodeBlock,
|
|
4797
|
+
hs as EntityBaseConfigCard,
|
|
4798
|
+
vs as EntityBaseForm,
|
|
4799
|
+
di as EntityBaseFormType,
|
|
4800
|
+
bs as EntityBaseTable,
|
|
4801
|
+
xs as EntityDeleteModal,
|
|
4802
|
+
$s as EntityEmptyState,
|
|
4803
|
+
Cs as EntityFilter,
|
|
4804
|
+
ws as EntityFormBlock,
|
|
4805
|
+
_s as EntityFormSection,
|
|
4806
|
+
Ss as EntityLink,
|
|
4807
|
+
ks as EntityToggleModal,
|
|
4808
|
+
ui as EntityTypes,
|
|
4809
|
+
pi as EventGatewayTypesArray,
|
|
4712
4810
|
me as FetcherStatus,
|
|
4713
|
-
|
|
4714
|
-
|
|
4715
|
-
|
|
4716
|
-
|
|
4717
|
-
|
|
4718
|
-
|
|
4811
|
+
zi as InternalLinkItem,
|
|
4812
|
+
en as JsonCodeBlock,
|
|
4813
|
+
As as PermissionsWrapper,
|
|
4814
|
+
fi as SupportedEntityDeckArray,
|
|
4815
|
+
Ee as SupportedEntityType,
|
|
4816
|
+
Ue as SupportedEntityTypesArray,
|
|
4817
|
+
Ts as TableTags,
|
|
4719
4818
|
Yn as TerraformCodeBlock,
|
|
4720
4819
|
Vn as YamlCodeBlock,
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
|
|
4724
|
-
|
|
4725
|
-
|
|
4726
|
-
|
|
4727
|
-
|
|
4728
|
-
|
|
4729
|
-
|
|
4730
|
-
|
|
4731
|
-
|
|
4732
|
-
|
|
4733
|
-
|
|
4734
|
-
|
|
4735
|
-
|
|
4820
|
+
Es as useAxios,
|
|
4821
|
+
Ks as useDebouncedFilter,
|
|
4822
|
+
Is as useDeleteUrlBuilder,
|
|
4823
|
+
Fs as useErrors,
|
|
4824
|
+
Os as useExternalLinkCreator,
|
|
4825
|
+
Ls as useFetchUrlBuilder,
|
|
4826
|
+
Bs as useFetcher,
|
|
4827
|
+
Rs as useFetcherCacheKey,
|
|
4828
|
+
js as useGatewayFeatureSupported,
|
|
4829
|
+
Ms as useHelpers,
|
|
4830
|
+
Us as useSchemaProvider,
|
|
4831
|
+
Ns as useStringHelpers,
|
|
4832
|
+
qs as useTableState,
|
|
4833
|
+
Ds as useTruncationDetector,
|
|
4834
|
+
Ps as useValidators
|
|
4736
4835
|
};
|