@kong-ui-public/entities-shared 3.33.2-pr.2640.fb8bab909.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 +1304 -1208
- 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 di() {
|
|
|
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 fi() {
|
|
|
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 mi() {
|
|
|
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 hi = {
|
|
|
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 hi = {
|
|
|
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 hi = {
|
|
|
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 hi = {
|
|
|
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 $i(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 Ii() {
|
|
|
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 Ei(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 Mi(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 = Gn(), o =
|
|
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
1100
|
/*! js-yaml 4.1.1 https://github.com/nodeca/js-yaml @license MIT */
|
|
1085
|
-
function
|
|
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 $r(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 Tr = $r, Ir = [
|
|
|
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 Fr(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 Lr() {
|
|
|
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 qr(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 qr(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 qr(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 Hr(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 zr(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 Xr(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 na(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 sa(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,27 +1673,27 @@ 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
|
-
function
|
|
1696
|
+
function $n(e, t, n) {
|
|
1681
1697
|
t === "__proto__" ? Object.defineProperty(e, t, {
|
|
1682
1698
|
configurable: !0,
|
|
1683
1699
|
enumerable: !0,
|
|
@@ -1685,13 +1701,13 @@ function In(e, t, n) {
|
|
|
1685
1701
|
value: n
|
|
1686
1702
|
}) : e[t] = n;
|
|
1687
1703
|
}
|
|
1688
|
-
var
|
|
1704
|
+
var Tn = new Array(256), En = new Array(256);
|
|
1689
1705
|
for (var ke = 0; ke < 256; ke++)
|
|
1690
|
-
|
|
1691
|
-
function
|
|
1706
|
+
Tn[ke] = St(ke) ? 1 : 0, En[ke] = St(ke);
|
|
1707
|
+
function $a(e, t) {
|
|
1692
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 = [];
|
|
1693
1709
|
}
|
|
1694
|
-
function
|
|
1710
|
+
function In(e, t) {
|
|
1695
1711
|
var n = {
|
|
1696
1712
|
name: e.filename,
|
|
1697
1713
|
buffer: e.input.slice(0, -1),
|
|
@@ -1700,26 +1716,26 @@ function On(e, t) {
|
|
|
1700
1716
|
line: e.line,
|
|
1701
1717
|
column: e.position - e.lineStart
|
|
1702
1718
|
};
|
|
1703
|
-
return n.snippet =
|
|
1719
|
+
return n.snippet = Fr(n), new oe(t, n);
|
|
1704
1720
|
}
|
|
1705
|
-
function
|
|
1706
|
-
throw
|
|
1721
|
+
function F(e, t) {
|
|
1722
|
+
throw In(e, t);
|
|
1707
1723
|
}
|
|
1708
|
-
function
|
|
1709
|
-
e.onWarning && e.onWarning.call(null,
|
|
1724
|
+
function Ne(e, t) {
|
|
1725
|
+
e.onWarning && e.onWarning.call(null, In(e, t));
|
|
1710
1726
|
}
|
|
1711
1727
|
var $t = {
|
|
1712
1728
|
YAML: function(t, n, i) {
|
|
1713
1729
|
var r, o, a;
|
|
1714
|
-
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");
|
|
1715
1731
|
},
|
|
1716
1732
|
TAG: function(t, n, i) {
|
|
1717
1733
|
var r, o;
|
|
1718
|
-
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");
|
|
1719
1735
|
try {
|
|
1720
1736
|
o = decodeURIComponent(o);
|
|
1721
1737
|
} catch {
|
|
1722
|
-
|
|
1738
|
+
F(t, "tag prefix is malformed: " + o);
|
|
1723
1739
|
}
|
|
1724
1740
|
t.tagMap[r] = o;
|
|
1725
1741
|
}
|
|
@@ -1729,21 +1745,21 @@ function ge(e, t, n, i) {
|
|
|
1729
1745
|
if (t < n) {
|
|
1730
1746
|
if (s = e.input.slice(t, n), i)
|
|
1731
1747
|
for (r = 0, o = s.length; r < o; r += 1)
|
|
1732
|
-
a = s.charCodeAt(r), a === 9 || 32 <= a && a <= 1114111 ||
|
|
1733
|
-
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");
|
|
1734
1750
|
e.result += s;
|
|
1735
1751
|
}
|
|
1736
1752
|
}
|
|
1737
1753
|
function Tt(e, t, n, i) {
|
|
1738
1754
|
var r, o, a, s;
|
|
1739
|
-
for (ee.isObject(n) ||
|
|
1740
|
-
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);
|
|
1741
1757
|
}
|
|
1742
1758
|
function we(e, t, n, i, r, o, a, s, l) {
|
|
1743
1759
|
var c, d;
|
|
1744
1760
|
if (Array.isArray(r))
|
|
1745
1761
|
for (r = Array.prototype.slice.call(r), c = 0, d = r.length; c < d; c += 1)
|
|
1746
|
-
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]");
|
|
1747
1763
|
if (typeof r == "object" && wt(r) === "[object Object]" && (r = "[object Object]"), r = String(r), t === null && (t = {}), i === "tag:yaml.org,2002:merge")
|
|
1748
1764
|
if (Array.isArray(o))
|
|
1749
1765
|
for (c = 0, d = o.length; c < d; c += 1)
|
|
@@ -1751,12 +1767,12 @@ function we(e, t, n, i, r, o, a, s, l) {
|
|
|
1751
1767
|
else
|
|
1752
1768
|
Tt(e, t, o, n);
|
|
1753
1769
|
else
|
|
1754
|
-
!e.json && !
|
|
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];
|
|
1755
1771
|
return t;
|
|
1756
1772
|
}
|
|
1757
1773
|
function lt(e) {
|
|
1758
1774
|
var t;
|
|
1759
|
-
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;
|
|
1760
1776
|
}
|
|
1761
1777
|
function Z(e, t, n) {
|
|
1762
1778
|
for (var i = 0, r = e.input.charCodeAt(e.position); r !== 0; ) {
|
|
@@ -1772,9 +1788,9 @@ function Z(e, t, n) {
|
|
|
1772
1788
|
else
|
|
1773
1789
|
break;
|
|
1774
1790
|
}
|
|
1775
|
-
return n !== -1 && i !== 0 && e.lineIndent < n &&
|
|
1791
|
+
return n !== -1 && i !== 0 && e.lineIndent < n && Ne(e, "deficient indentation"), i;
|
|
1776
1792
|
}
|
|
1777
|
-
function
|
|
1793
|
+
function He(e) {
|
|
1778
1794
|
var t = e.position, n;
|
|
1779
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)));
|
|
1780
1796
|
}
|
|
@@ -1782,7 +1798,7 @@ function st(e, t) {
|
|
|
1782
1798
|
t === 1 ? e.result += " " : t > 1 && (e.result += ee.repeat(`
|
|
1783
1799
|
`, t - 1));
|
|
1784
1800
|
}
|
|
1785
|
-
function
|
|
1801
|
+
function Ta(e, t, n) {
|
|
1786
1802
|
var i, r, o, a, s, l, c, d, u = e.kind, p = e.result, g;
|
|
1787
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)))
|
|
1788
1804
|
return !1;
|
|
@@ -1794,7 +1810,7 @@ function wa(e, t, n) {
|
|
|
1794
1810
|
if (i = e.input.charCodeAt(e.position - 1), le(i))
|
|
1795
1811
|
break;
|
|
1796
1812
|
} else {
|
|
1797
|
-
if (e.position === e.lineStart &&
|
|
1813
|
+
if (e.position === e.lineStart && He(e) || n && _e(g))
|
|
1798
1814
|
break;
|
|
1799
1815
|
if (de(g))
|
|
1800
1816
|
if (l = e.line, c = e.lineStart, d = e.lineIndent, Z(e, !1, -1), e.lineIndent >= t) {
|
|
@@ -1809,7 +1825,7 @@ function wa(e, t, n) {
|
|
|
1809
1825
|
}
|
|
1810
1826
|
return ge(e, o, a, !1), e.result ? !0 : (e.kind = u, e.result = p, !1);
|
|
1811
1827
|
}
|
|
1812
|
-
function
|
|
1828
|
+
function Ea(e, t) {
|
|
1813
1829
|
var n, i, r;
|
|
1814
1830
|
if (n = e.input.charCodeAt(e.position), n !== 39)
|
|
1815
1831
|
return !1;
|
|
@@ -1819,10 +1835,10 @@ function Sa(e, t) {
|
|
|
1819
1835
|
i = e.position, e.position++, r = e.position;
|
|
1820
1836
|
else
|
|
1821
1837
|
return !0;
|
|
1822
|
-
else de(n) ? (ge(e, i, r, !0), st(e, Z(e, !1, t)), i = r = e.position) : e.position === e.lineStart &&
|
|
1823
|
-
|
|
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");
|
|
1824
1840
|
}
|
|
1825
|
-
function
|
|
1841
|
+
function Ia(e, t) {
|
|
1826
1842
|
var n, i, r, o, a, s;
|
|
1827
1843
|
if (s = e.input.charCodeAt(e.position), s !== 34)
|
|
1828
1844
|
return !1;
|
|
@@ -1832,21 +1848,21 @@ function $a(e, t) {
|
|
|
1832
1848
|
if (s === 92) {
|
|
1833
1849
|
if (ge(e, n, e.position, !0), s = e.input.charCodeAt(++e.position), de(s))
|
|
1834
1850
|
Z(e, !1, t);
|
|
1835
|
-
else if (s < 256 &&
|
|
1836
|
-
e.result +=
|
|
1837
|
-
else if ((a =
|
|
1851
|
+
else if (s < 256 && Tn[s])
|
|
1852
|
+
e.result += En[s], e.position++;
|
|
1853
|
+
else if ((a = _a(s)) > 0) {
|
|
1838
1854
|
for (r = a, o = 0; r > 0; r--)
|
|
1839
|
-
s = e.input.charCodeAt(++e.position), (a =
|
|
1840
|
-
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++;
|
|
1841
1857
|
} else
|
|
1842
|
-
|
|
1858
|
+
F(e, "unknown escape sequence");
|
|
1843
1859
|
n = i = e.position;
|
|
1844
|
-
} 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);
|
|
1845
1861
|
}
|
|
1846
|
-
|
|
1862
|
+
F(e, "unexpected end of the stream within a double quoted scalar");
|
|
1847
1863
|
}
|
|
1848
|
-
function
|
|
1849
|
-
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;
|
|
1850
1866
|
if (C = e.input.charCodeAt(e.position), C === 91)
|
|
1851
1867
|
d = 93, g = !1, s = [];
|
|
1852
1868
|
else if (C === 123)
|
|
@@ -1856,12 +1872,12 @@ function Ta(e, t) {
|
|
|
1856
1872
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = s), C = e.input.charCodeAt(++e.position); C !== 0; ) {
|
|
1857
1873
|
if (Z(e, !0, t), C = e.input.charCodeAt(e.position), C === d)
|
|
1858
1874
|
return e.position++, e.tag = a, e.anchor = l, e.kind = g ? "mapping" : "sequence", e.result = s, !0;
|
|
1859
|
-
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;
|
|
1860
1876
|
}
|
|
1861
|
-
|
|
1877
|
+
F(e, "unexpected end of the stream within a flow collection");
|
|
1862
1878
|
}
|
|
1863
|
-
function
|
|
1864
|
-
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;
|
|
1865
1881
|
if (u = e.input.charCodeAt(e.position), u === 124)
|
|
1866
1882
|
i = !1;
|
|
1867
1883
|
else if (u === 62)
|
|
@@ -1870,9 +1886,9 @@ function Ia(e, t) {
|
|
|
1870
1886
|
return !1;
|
|
1871
1887
|
for (e.kind = "scalar", e.result = ""; u !== 0; )
|
|
1872
1888
|
if (u = e.input.charCodeAt(++e.position), u === 43 || u === 45)
|
|
1873
|
-
|
|
1874
|
-
else if ((d =
|
|
1875
|
-
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);
|
|
1876
1892
|
else
|
|
1877
1893
|
break;
|
|
1878
1894
|
if (ve(u)) {
|
|
@@ -1893,7 +1909,7 @@ function Ia(e, t) {
|
|
|
1893
1909
|
}
|
|
1894
1910
|
if (e.lineIndent < s) {
|
|
1895
1911
|
r === _t ? e.result += ee.repeat(`
|
|
1896
|
-
`, o ? 1 + l : l) : r ===
|
|
1912
|
+
`, o ? 1 + l : l) : r === Je && o && (e.result += `
|
|
1897
1913
|
`);
|
|
1898
1914
|
break;
|
|
1899
1915
|
}
|
|
@@ -1907,118 +1923,118 @@ function Ia(e, t) {
|
|
|
1907
1923
|
}
|
|
1908
1924
|
return !0;
|
|
1909
1925
|
}
|
|
1910
|
-
function
|
|
1926
|
+
function Et(e, t) {
|
|
1911
1927
|
var n, i = e.tag, r = e.anchor, o = [], a, s = !1, l;
|
|
1912
1928
|
if (e.firstTabInLine !== -1) return !1;
|
|
1913
|
-
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)))); ) {
|
|
1914
1930
|
if (s = !0, e.position++, Z(e, !0, -1) && e.lineIndent <= t) {
|
|
1915
1931
|
o.push(null), l = e.input.charCodeAt(e.position);
|
|
1916
1932
|
continue;
|
|
1917
1933
|
}
|
|
1918
|
-
if (n = e.line, $e(e, t,
|
|
1919
|
-
|
|
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");
|
|
1920
1936
|
else if (e.lineIndent < t)
|
|
1921
1937
|
break;
|
|
1922
1938
|
}
|
|
1923
1939
|
return s ? (e.tag = i, e.anchor = r, e.kind = "sequence", e.result = o, !0) : !1;
|
|
1924
1940
|
}
|
|
1925
|
-
function
|
|
1926
|
-
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;
|
|
1927
1943
|
if (e.firstTabInLine !== -1) return !1;
|
|
1928
1944
|
for (e.anchor !== null && (e.anchorMap[e.anchor] = u), C = e.input.charCodeAt(e.position); C !== 0; ) {
|
|
1929
|
-
if (!
|
|
1930
|
-
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;
|
|
1931
1947
|
else {
|
|
1932
|
-
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))
|
|
1933
1949
|
break;
|
|
1934
1950
|
if (e.line === o) {
|
|
1935
1951
|
for (C = e.input.charCodeAt(e.position); ve(C); )
|
|
1936
1952
|
C = e.input.charCodeAt(++e.position);
|
|
1937
1953
|
if (C === 58)
|
|
1938
|
-
C = e.input.charCodeAt(++e.position), le(C) ||
|
|
1939
|
-
else if (
|
|
1940
|
-
|
|
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");
|
|
1941
1957
|
else
|
|
1942
1958
|
return e.tag = c, e.anchor = d, !0;
|
|
1943
|
-
} else if (
|
|
1944
|
-
|
|
1959
|
+
} else if (A)
|
|
1960
|
+
F(e, "can not read a block mapping entry; a multiline key may not be an implicit key");
|
|
1945
1961
|
else
|
|
1946
1962
|
return e.tag = c, e.anchor = d, !0;
|
|
1947
1963
|
}
|
|
1948
|
-
if ((e.line === o || e.lineIndent > t) && (
|
|
1949
|
-
|
|
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");
|
|
1950
1966
|
else if (e.lineIndent < t)
|
|
1951
1967
|
break;
|
|
1952
1968
|
}
|
|
1953
|
-
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;
|
|
1954
1970
|
}
|
|
1955
|
-
function
|
|
1971
|
+
function Ba(e) {
|
|
1956
1972
|
var t, n = !1, i = !1, r, o, a;
|
|
1957
1973
|
if (a = e.input.charCodeAt(e.position), a !== 33) return !1;
|
|
1958
|
-
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) {
|
|
1959
1975
|
do
|
|
1960
1976
|
a = e.input.charCodeAt(++e.position);
|
|
1961
1977
|
while (a !== 0 && a !== 62);
|
|
1962
|
-
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");
|
|
1963
1979
|
} else {
|
|
1964
1980
|
for (; a !== 0 && !le(a); )
|
|
1965
|
-
a === 33 && (i ?
|
|
1966
|
-
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");
|
|
1967
1983
|
}
|
|
1968
|
-
o && !
|
|
1984
|
+
o && !Sn.test(o) && F(e, "tag name cannot contain such characters: " + o);
|
|
1969
1985
|
try {
|
|
1970
1986
|
o = decodeURIComponent(o);
|
|
1971
1987
|
} catch {
|
|
1972
|
-
|
|
1988
|
+
F(e, "tag name is malformed: " + o);
|
|
1973
1989
|
}
|
|
1974
|
-
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;
|
|
1975
1991
|
}
|
|
1976
|
-
function
|
|
1992
|
+
function Ra(e) {
|
|
1977
1993
|
var t, n;
|
|
1978
1994
|
if (n = e.input.charCodeAt(e.position), n !== 38) return !1;
|
|
1979
|
-
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); )
|
|
1980
1996
|
n = e.input.charCodeAt(++e.position);
|
|
1981
|
-
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;
|
|
1982
1998
|
}
|
|
1983
|
-
function
|
|
1999
|
+
function Ka(e) {
|
|
1984
2000
|
var t, n, i;
|
|
1985
2001
|
if (i = e.input.charCodeAt(e.position), i !== 42) return !1;
|
|
1986
2002
|
for (i = e.input.charCodeAt(++e.position), t = e.position; i !== 0 && !le(i) && !_e(i); )
|
|
1987
2003
|
i = e.input.charCodeAt(++e.position);
|
|
1988
|
-
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;
|
|
1989
2005
|
}
|
|
1990
2006
|
function $e(e, t, n, i, r) {
|
|
1991
|
-
var o, a, s, l = 1, c = !1, d = !1, u, p, g,
|
|
1992
|
-
if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, o = a = s =
|
|
1993
|
-
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); )
|
|
1994
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;
|
|
1995
|
-
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)
|
|
1996
2012
|
e.anchor !== null && (e.anchorMap[e.anchor] = e.result);
|
|
1997
2013
|
else if (e.tag === "?") {
|
|
1998
|
-
for (e.result !== null && e.kind !== "scalar" &&
|
|
1999
|
-
if (
|
|
2000
|
-
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);
|
|
2001
2017
|
break;
|
|
2002
2018
|
}
|
|
2003
2019
|
} else if (e.tag !== "!") {
|
|
2004
|
-
if (
|
|
2005
|
-
|
|
2020
|
+
if (he.call(e.typeMap[e.kind || "fallback"], e.tag))
|
|
2021
|
+
y = e.typeMap[e.kind || "fallback"][e.tag];
|
|
2006
2022
|
else
|
|
2007
|
-
for (
|
|
2023
|
+
for (y = null, g = e.typeMap.multi[e.kind || "fallback"], u = 0, p = g.length; u < p; u += 1)
|
|
2008
2024
|
if (e.tag.slice(0, g[u].tag.length) === g[u].tag) {
|
|
2009
|
-
|
|
2025
|
+
y = g[u];
|
|
2010
2026
|
break;
|
|
2011
2027
|
}
|
|
2012
|
-
|
|
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");
|
|
2013
2029
|
}
|
|
2014
2030
|
return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || d;
|
|
2015
2031
|
}
|
|
2016
|
-
function
|
|
2032
|
+
function Na(e) {
|
|
2017
2033
|
var t = e.position, n, i, r, o = !1, a;
|
|
2018
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)); ) {
|
|
2019
2035
|
for (o = !0, a = e.input.charCodeAt(++e.position), n = e.position; a !== 0 && !le(a); )
|
|
2020
2036
|
a = e.input.charCodeAt(++e.position);
|
|
2021
|
-
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; ) {
|
|
2022
2038
|
for (; ve(a); )
|
|
2023
2039
|
a = e.input.charCodeAt(++e.position);
|
|
2024
2040
|
if (a === 35) {
|
|
@@ -2032,47 +2048,47 @@ function Ba(e) {
|
|
|
2032
2048
|
a = e.input.charCodeAt(++e.position);
|
|
2033
2049
|
r.push(e.input.slice(n, e.position));
|
|
2034
2050
|
}
|
|
2035
|
-
a !== 0 && lt(e),
|
|
2051
|
+
a !== 0 && lt(e), he.call($t, i) ? $t[i](e, i, r) : Ne(e, 'unknown document directive "' + i + '"');
|
|
2036
2052
|
}
|
|
2037
|
-
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)) {
|
|
2038
2054
|
e.input.charCodeAt(e.position) === 46 && (e.position += 3, Z(e, !0, -1));
|
|
2039
2055
|
return;
|
|
2040
2056
|
}
|
|
2041
2057
|
if (e.position < e.length - 1)
|
|
2042
|
-
|
|
2058
|
+
F(e, "end of the stream or a document separator is expected");
|
|
2043
2059
|
else
|
|
2044
2060
|
return;
|
|
2045
2061
|
}
|
|
2046
|
-
function
|
|
2062
|
+
function Fn(e, t) {
|
|
2047
2063
|
e = String(e), t = t || {}, e.length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += `
|
|
2048
2064
|
`), e.charCodeAt(0) === 65279 && (e = e.slice(1)));
|
|
2049
|
-
var n = new
|
|
2050
|
-
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; )
|
|
2051
2067
|
n.lineIndent += 1, n.position += 1;
|
|
2052
2068
|
for (; n.position < n.length - 1; )
|
|
2053
|
-
|
|
2069
|
+
Na(n);
|
|
2054
2070
|
return n.documents;
|
|
2055
2071
|
}
|
|
2056
|
-
function
|
|
2072
|
+
function Ma(e, t, n) {
|
|
2057
2073
|
t !== null && typeof t == "object" && typeof n > "u" && (n = t, t = null);
|
|
2058
|
-
var i =
|
|
2074
|
+
var i = Fn(e, n);
|
|
2059
2075
|
if (typeof t != "function")
|
|
2060
2076
|
return i;
|
|
2061
2077
|
for (var r = 0, o = i.length; r < o; r += 1)
|
|
2062
2078
|
t(i[r]);
|
|
2063
2079
|
}
|
|
2064
|
-
function
|
|
2065
|
-
var n =
|
|
2080
|
+
function ja(e, t) {
|
|
2081
|
+
var n = Fn(e, t);
|
|
2066
2082
|
if (n.length !== 0) {
|
|
2067
2083
|
if (n.length === 1)
|
|
2068
2084
|
return n[0];
|
|
2069
2085
|
throw new oe("expected a single document in the stream, but found more");
|
|
2070
2086
|
}
|
|
2071
2087
|
}
|
|
2072
|
-
var
|
|
2073
|
-
loadAll:
|
|
2074
|
-
load:
|
|
2075
|
-
},
|
|
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 = {};
|
|
2076
2092
|
re[0] = "\\0";
|
|
2077
2093
|
re[7] = "\\a";
|
|
2078
2094
|
re[8] = "\\b";
|
|
@@ -2088,7 +2104,7 @@ re[133] = "\\N";
|
|
|
2088
2104
|
re[160] = "\\_";
|
|
2089
2105
|
re[8232] = "\\L";
|
|
2090
2106
|
re[8233] = "\\P";
|
|
2091
|
-
var
|
|
2107
|
+
var ro = [
|
|
2092
2108
|
"y",
|
|
2093
2109
|
"Y",
|
|
2094
2110
|
"yes",
|
|
@@ -2105,15 +2121,15 @@ var to = [
|
|
|
2105
2121
|
"off",
|
|
2106
2122
|
"Off",
|
|
2107
2123
|
"OFF"
|
|
2108
|
-
],
|
|
2109
|
-
function
|
|
2124
|
+
], ao = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
|
|
2125
|
+
function oo(e, t) {
|
|
2110
2126
|
var n, i, r, o, a, s, l;
|
|
2111
2127
|
if (t === null) return {};
|
|
2112
2128
|
for (n = {}, i = Object.keys(t), r = 0, o = i.length; r < o; r += 1)
|
|
2113
|
-
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;
|
|
2114
2130
|
return n;
|
|
2115
2131
|
}
|
|
2116
|
-
function
|
|
2132
|
+
function lo(e) {
|
|
2117
2133
|
var t, n, i;
|
|
2118
2134
|
if (t = e.toString(16).toUpperCase(), e <= 255)
|
|
2119
2135
|
n = "x", i = 2;
|
|
@@ -2125,94 +2141,94 @@ function ro(e) {
|
|
|
2125
2141
|
throw new oe("code point within a string may not be greater than 0xFFFFFFFF");
|
|
2126
2142
|
return "\\" + n + ee.repeat("0", i - t.length) + t;
|
|
2127
2143
|
}
|
|
2128
|
-
var
|
|
2129
|
-
function
|
|
2130
|
-
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;
|
|
2131
2147
|
}
|
|
2132
|
-
function
|
|
2148
|
+
function It(e, t) {
|
|
2133
2149
|
for (var n = ee.repeat(" ", t), i = 0, r = -1, o = "", a, s = e.length; i < s; )
|
|
2134
2150
|
r = e.indexOf(`
|
|
2135
2151
|
`, i), r === -1 ? (a = e.slice(i), i = s) : (a = e.slice(i, r + 1), i = r + 1), a.length && a !== `
|
|
2136
2152
|
` && (o += n), o += a;
|
|
2137
2153
|
return o;
|
|
2138
2154
|
}
|
|
2139
|
-
function
|
|
2155
|
+
function Xe(e, t) {
|
|
2140
2156
|
return `
|
|
2141
2157
|
` + ee.repeat(" ", e.indent * t);
|
|
2142
2158
|
}
|
|
2143
|
-
function
|
|
2159
|
+
function uo(e, t) {
|
|
2144
2160
|
var n, i, r;
|
|
2145
2161
|
for (n = 0, i = e.implicitTypes.length; n < i; n += 1)
|
|
2146
2162
|
if (r = e.implicitTypes[n], r.resolve(t))
|
|
2147
2163
|
return !0;
|
|
2148
2164
|
return !1;
|
|
2149
2165
|
}
|
|
2150
|
-
function
|
|
2151
|
-
return e ===
|
|
2166
|
+
function je(e) {
|
|
2167
|
+
return e === Ha || e === Ua;
|
|
2152
2168
|
}
|
|
2153
|
-
function
|
|
2169
|
+
function Le(e) {
|
|
2154
2170
|
return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && e !== 8232 && e !== 8233 || 57344 <= e && e <= 65533 && e !== ct || 65536 <= e && e <= 1114111;
|
|
2155
2171
|
}
|
|
2156
2172
|
function Ft(e) {
|
|
2157
|
-
return
|
|
2173
|
+
return Le(e) && e !== ct && e !== qa && e !== Fe;
|
|
2158
2174
|
}
|
|
2159
2175
|
function Ot(e, t, n) {
|
|
2160
|
-
var i = Ft(e), r = i && !
|
|
2176
|
+
var i = Ft(e), r = i && !je(e);
|
|
2161
2177
|
return (
|
|
2162
2178
|
// ns-plain-safe
|
|
2163
2179
|
(n ? (
|
|
2164
2180
|
// c = flow-in
|
|
2165
2181
|
i
|
|
2166
|
-
) : 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
|
|
2167
2183
|
);
|
|
2168
2184
|
}
|
|
2169
|
-
function
|
|
2170
|
-
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;
|
|
2171
2187
|
}
|
|
2172
|
-
function
|
|
2173
|
-
return !
|
|
2188
|
+
function po(e) {
|
|
2189
|
+
return !je(e) && e !== Me;
|
|
2174
2190
|
}
|
|
2175
2191
|
function Te(e, t) {
|
|
2176
2192
|
var n = e.charCodeAt(t), i;
|
|
2177
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;
|
|
2178
2194
|
}
|
|
2179
|
-
function
|
|
2195
|
+
function Dn(e) {
|
|
2180
2196
|
var t = /^\n* /;
|
|
2181
2197
|
return t.test(e);
|
|
2182
2198
|
}
|
|
2183
|
-
var
|
|
2184
|
-
function
|
|
2185
|
-
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));
|
|
2186
2202
|
if (t || a)
|
|
2187
2203
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2188
|
-
if (c = Te(e, l), !
|
|
2204
|
+
if (c = Te(e, l), !Le(c))
|
|
2189
2205
|
return Ae;
|
|
2190
2206
|
x = x && Ot(c, d, s), d = c;
|
|
2191
2207
|
}
|
|
2192
2208
|
else {
|
|
2193
2209
|
for (l = 0; l < e.length; c >= 65536 ? l += 2 : l++) {
|
|
2194
|
-
if (c = Te(e, l), c ===
|
|
2210
|
+
if (c = Te(e, l), c === Fe)
|
|
2195
2211
|
u = !0, g && (p = p || // Foldable line = too long, and not more-indented.
|
|
2196
|
-
l -
|
|
2197
|
-
else if (!
|
|
2212
|
+
l - y - 1 > i && e[y + 1] !== " ", y = l);
|
|
2213
|
+
else if (!Le(c))
|
|
2198
2214
|
return Ae;
|
|
2199
2215
|
x = x && Ot(c, d, s), d = c;
|
|
2200
2216
|
}
|
|
2201
|
-
p = p || g && l -
|
|
2217
|
+
p = p || g && l - y - 1 > i && e[y + 1] !== " ";
|
|
2202
2218
|
}
|
|
2203
|
-
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;
|
|
2204
2220
|
}
|
|
2205
|
-
function
|
|
2221
|
+
function yo(e, t, n, i, r) {
|
|
2206
2222
|
e.dump = function() {
|
|
2207
2223
|
if (t.length === 0)
|
|
2208
|
-
return e.quotingType ===
|
|
2209
|
-
if (!e.noCompatMode && (
|
|
2210
|
-
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 + "'";
|
|
2211
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;
|
|
2212
2228
|
function l(c) {
|
|
2213
|
-
return
|
|
2229
|
+
return uo(e, c);
|
|
2214
2230
|
}
|
|
2215
|
-
switch (
|
|
2231
|
+
switch (mo(
|
|
2216
2232
|
t,
|
|
2217
2233
|
s,
|
|
2218
2234
|
e.indent,
|
|
@@ -2222,23 +2238,23 @@ function fo(e, t, n, i, r) {
|
|
|
2222
2238
|
e.forceQuotes && !i,
|
|
2223
2239
|
r
|
|
2224
2240
|
)) {
|
|
2225
|
-
case
|
|
2241
|
+
case Pn:
|
|
2226
2242
|
return t;
|
|
2227
|
-
case
|
|
2243
|
+
case et:
|
|
2228
2244
|
return "'" + t.replace(/'/g, "''") + "'";
|
|
2229
|
-
case
|
|
2230
|
-
return "|" + Lt(t, e.indent) + Bt(
|
|
2231
|
-
case
|
|
2232
|
-
return ">" + Lt(t, e.indent) + Bt(
|
|
2245
|
+
case Un:
|
|
2246
|
+
return "|" + Lt(t, e.indent) + Bt(It(t, o));
|
|
2247
|
+
case qn:
|
|
2248
|
+
return ">" + Lt(t, e.indent) + Bt(It(go(t, a), o));
|
|
2233
2249
|
case Ae:
|
|
2234
|
-
return '"' +
|
|
2250
|
+
return '"' + ho(t) + '"';
|
|
2235
2251
|
default:
|
|
2236
2252
|
throw new oe("impossible error: invalid scalar style");
|
|
2237
2253
|
}
|
|
2238
2254
|
}();
|
|
2239
2255
|
}
|
|
2240
2256
|
function Lt(e, t) {
|
|
2241
|
-
var n =
|
|
2257
|
+
var n = Dn(e) ? String(t) : "", i = e[e.length - 1] === `
|
|
2242
2258
|
`, r = i && (e[e.length - 2] === `
|
|
2243
2259
|
` || e === `
|
|
2244
2260
|
`), o = r ? "+" : i ? "" : "-";
|
|
@@ -2249,7 +2265,7 @@ function Bt(e) {
|
|
|
2249
2265
|
return e[e.length - 1] === `
|
|
2250
2266
|
` ? e.slice(0, -1) : e;
|
|
2251
2267
|
}
|
|
2252
|
-
function
|
|
2268
|
+
function go(e, t) {
|
|
2253
2269
|
for (var n = /(\n+)([^\n]*)/g, i = function() {
|
|
2254
2270
|
var c = e.indexOf(`
|
|
2255
2271
|
`);
|
|
@@ -2271,12 +2287,12 @@ function Rt(e, t) {
|
|
|
2271
2287
|
`, e.length - r > t && a > r ? l += e.slice(r, a) + `
|
|
2272
2288
|
` + e.slice(a + 1) : l += e.slice(r), l.slice(1);
|
|
2273
2289
|
}
|
|
2274
|
-
function
|
|
2290
|
+
function ho(e) {
|
|
2275
2291
|
for (var t = "", n = 0, i, r = 0; r < e.length; n >= 65536 ? r += 2 : r++)
|
|
2276
|
-
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);
|
|
2277
2293
|
return t;
|
|
2278
2294
|
}
|
|
2279
|
-
function
|
|
2295
|
+
function vo(e, t, n) {
|
|
2280
2296
|
var i = "", r = e.tag, o, a, s;
|
|
2281
2297
|
for (o = 0, a = n.length; o < a; o += 1)
|
|
2282
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);
|
|
@@ -2285,16 +2301,16 @@ function ho(e, t, n) {
|
|
|
2285
2301
|
function Kt(e, t, n, i) {
|
|
2286
2302
|
var r = "", o = e.tag, a, s, l;
|
|
2287
2303
|
for (a = 0, s = n.length; a < s; a += 1)
|
|
2288
|
-
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);
|
|
2289
2305
|
e.tag = o, e.dump = r || "[]";
|
|
2290
2306
|
}
|
|
2291
|
-
function
|
|
2307
|
+
function bo(e, t, n) {
|
|
2292
2308
|
var i = "", r = e.tag, o = Object.keys(n), a, s, l, c, d;
|
|
2293
2309
|
for (a = 0, s = o.length; a < s; a += 1)
|
|
2294
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));
|
|
2295
2311
|
e.tag = r, e.dump = "{" + i + "}";
|
|
2296
2312
|
}
|
|
2297
|
-
function
|
|
2313
|
+
function xo(e, t, n, i) {
|
|
2298
2314
|
var r = "", o = e.tag, a = Object.keys(n), s, l, c, d, u, p;
|
|
2299
2315
|
if (e.sortKeys === !0)
|
|
2300
2316
|
a.sort();
|
|
@@ -2303,7 +2319,7 @@ function yo(e, t, n, i) {
|
|
|
2303
2319
|
else if (e.sortKeys)
|
|
2304
2320
|
throw new oe("sortKeys must be a boolean or a function");
|
|
2305
2321
|
for (s = 0, l = a.length; s < l; s += 1)
|
|
2306
|
-
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));
|
|
2307
2323
|
e.tag = o, e.dump = r || "{}";
|
|
2308
2324
|
}
|
|
2309
2325
|
function Nt(e, t, n) {
|
|
@@ -2311,9 +2327,9 @@ function Nt(e, t, n) {
|
|
|
2311
2327
|
for (r = n ? e.explicitTypes : e.implicitTypes, o = 0, a = r.length; o < a; o += 1)
|
|
2312
2328
|
if (s = r[o], (s.instanceOf || s.predicate) && (!s.instanceOf || typeof t == "object" && t instanceof s.instanceOf) && (!s.predicate || s.predicate(t))) {
|
|
2313
2329
|
if (n ? s.multi && s.representName ? e.tag = s.representName(t) : e.tag = s.tag : e.tag = "?", s.represent) {
|
|
2314
|
-
if (l = e.styleMap[s.tag] || s.defaultStyle,
|
|
2330
|
+
if (l = e.styleMap[s.tag] || s.defaultStyle, Ln.call(s.represent) === "[object Function]")
|
|
2315
2331
|
i = s.represent(t, l);
|
|
2316
|
-
else if (
|
|
2332
|
+
else if (Bn.call(s.represent, l))
|
|
2317
2333
|
i = s.represent[l](t, l);
|
|
2318
2334
|
else
|
|
2319
2335
|
throw new oe("!<" + s.tag + '> tag resolver accepts not "' + l + '" style');
|
|
@@ -2325,18 +2341,18 @@ function Nt(e, t, n) {
|
|
|
2325
2341
|
}
|
|
2326
2342
|
function pe(e, t, n, i, r, o, a) {
|
|
2327
2343
|
e.tag = null, e.dump = n, Nt(e, n, !1) || Nt(e, n, !0);
|
|
2328
|
-
var s =
|
|
2344
|
+
var s = Ln.call(e.dump), l = i, c;
|
|
2329
2345
|
i && (i = e.flowLevel < 0 || e.flowLevel > t);
|
|
2330
2346
|
var d = s === "[object Object]" || s === "[object Array]", u, p;
|
|
2331
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])
|
|
2332
2348
|
e.dump = "*ref_" + u;
|
|
2333
2349
|
else {
|
|
2334
2350
|
if (d && p && !e.usedDuplicates[u] && (e.usedDuplicates[u] = !0), s === "[object Object]")
|
|
2335
|
-
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));
|
|
2336
2352
|
else if (s === "[object Array]")
|
|
2337
|
-
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));
|
|
2338
2354
|
else if (s === "[object String]")
|
|
2339
|
-
e.tag !== "?" &&
|
|
2355
|
+
e.tag !== "?" && yo(e, e.dump, t, o, l);
|
|
2340
2356
|
else {
|
|
2341
2357
|
if (s === "[object Undefined]")
|
|
2342
2358
|
return !1;
|
|
@@ -2349,71 +2365,71 @@ function pe(e, t, n, i, r, o, a) {
|
|
|
2349
2365
|
}
|
|
2350
2366
|
return !0;
|
|
2351
2367
|
}
|
|
2352
|
-
function
|
|
2368
|
+
function Co(e, t) {
|
|
2353
2369
|
var n = [], i = [], r, o;
|
|
2354
|
-
for (
|
|
2370
|
+
for (tt(e, n, i), r = 0, o = i.length; r < o; r += 1)
|
|
2355
2371
|
t.duplicates.push(n[i[r]]);
|
|
2356
2372
|
t.usedDuplicates = new Array(o);
|
|
2357
2373
|
}
|
|
2358
|
-
function
|
|
2374
|
+
function tt(e, t, n) {
|
|
2359
2375
|
var i, r, o;
|
|
2360
2376
|
if (e !== null && typeof e == "object")
|
|
2361
2377
|
if (r = t.indexOf(e), r !== -1)
|
|
2362
2378
|
n.indexOf(r) === -1 && n.push(r);
|
|
2363
2379
|
else if (t.push(e), Array.isArray(e))
|
|
2364
2380
|
for (r = 0, o = e.length; r < o; r += 1)
|
|
2365
|
-
|
|
2381
|
+
tt(e[r], t, n);
|
|
2366
2382
|
else
|
|
2367
2383
|
for (i = Object.keys(e), r = 0, o = i.length; r < o; r += 1)
|
|
2368
|
-
|
|
2384
|
+
tt(e[i[r]], t, n);
|
|
2369
2385
|
}
|
|
2370
|
-
function
|
|
2386
|
+
function ko(e, t) {
|
|
2371
2387
|
t = t || {};
|
|
2372
|
-
var n = new
|
|
2373
|
-
n.noRefs ||
|
|
2388
|
+
var n = new co(t);
|
|
2389
|
+
n.noRefs || Co(e, n);
|
|
2374
2390
|
var i = e;
|
|
2375
2391
|
return n.replacer && (i = n.replacer.call({ "": i }, "", i)), pe(n, 0, i, !0, !0) ? n.dump + `
|
|
2376
2392
|
` : "";
|
|
2377
2393
|
}
|
|
2378
|
-
var
|
|
2379
|
-
dump:
|
|
2394
|
+
var Ao = ko, _o = {
|
|
2395
|
+
dump: Ao
|
|
2380
2396
|
};
|
|
2381
2397
|
function ut(e, t) {
|
|
2382
2398
|
return function() {
|
|
2383
2399
|
throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.");
|
|
2384
2400
|
};
|
|
2385
2401
|
}
|
|
2386
|
-
var
|
|
2387
|
-
binary:
|
|
2388
|
-
float:
|
|
2389
|
-
map:
|
|
2390
|
-
null:
|
|
2391
|
-
pairs:
|
|
2392
|
-
set:
|
|
2393
|
-
timestamp:
|
|
2394
|
-
bool:
|
|
2395
|
-
int:
|
|
2396
|
-
merge:
|
|
2397
|
-
omap:
|
|
2398
|
-
seq:
|
|
2399
|
-
str:
|
|
2400
|
-
},
|
|
2401
|
-
Type:
|
|
2402
|
-
Schema:
|
|
2403
|
-
FAILSAFE_SCHEMA:
|
|
2404
|
-
JSON_SCHEMA:
|
|
2405
|
-
CORE_SCHEMA:
|
|
2406
|
-
DEFAULT_SCHEMA:
|
|
2407
|
-
load:
|
|
2408
|
-
loadAll:
|
|
2409
|
-
dump:
|
|
2410
|
-
YAMLException:
|
|
2411
|
-
types:
|
|
2412
|
-
safeLoad:
|
|
2413
|
-
safeLoadAll:
|
|
2414
|
-
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
|
|
2415
2431
|
};
|
|
2416
|
-
const
|
|
2432
|
+
const jo = { class: "yaml-config config-card-code-block" }, Vn = /* @__PURE__ */ z({
|
|
2417
2433
|
__name: "YamlCodeBlock",
|
|
2418
2434
|
props: {
|
|
2419
2435
|
/** A record to indicate the entity's configuration, used to populate the YAML code block */
|
|
@@ -2423,24 +2439,24 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2423
2439
|
}
|
|
2424
2440
|
},
|
|
2425
2441
|
setup(e) {
|
|
2426
|
-
const t = e, n =
|
|
2442
|
+
const t = e, n = $(() => {
|
|
2427
2443
|
const i = Object.fromEntries(Object.entries(t.entityRecord).filter(([, r]) => r !== null && r !== "" && (Array.isArray(r) ? r.length !== 0 : !0)));
|
|
2428
|
-
return Object.keys(i).length === 0 && i.constructor === Object ? "" :
|
|
2444
|
+
return Object.keys(i).length === 0 && i.constructor === Object ? "" : Hn.dump(i).trim();
|
|
2429
2445
|
});
|
|
2430
2446
|
return (i, r) => {
|
|
2431
2447
|
const o = P("KCodeBlock");
|
|
2432
|
-
return m(), S("div",
|
|
2433
|
-
t.entityRecord ? (m(),
|
|
2448
|
+
return m(), S("div", jo, [
|
|
2449
|
+
t.entityRecord ? (m(), j(o, {
|
|
2434
2450
|
key: 0,
|
|
2435
2451
|
id: "yaml-codeblock",
|
|
2436
2452
|
code: n.value,
|
|
2437
2453
|
language: "yaml",
|
|
2438
2454
|
theme: "dark"
|
|
2439
|
-
}, null, 8, ["code"])) :
|
|
2455
|
+
}, null, 8, ["code"])) : M("", !0)
|
|
2440
2456
|
]);
|
|
2441
2457
|
};
|
|
2442
2458
|
}
|
|
2443
|
-
}),
|
|
2459
|
+
}), Do = { class: "terraform-config config-card-code-block" }, ie = " ", Yn = /* @__PURE__ */ z({
|
|
2444
2460
|
__name: "TerraformCodeBlock",
|
|
2445
2461
|
props: {
|
|
2446
2462
|
/** A record to indicate the entity's configuration, used to populate the Terraform code block */
|
|
@@ -2451,7 +2467,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2451
2467
|
entityType: {
|
|
2452
2468
|
type: String,
|
|
2453
2469
|
required: !0,
|
|
2454
|
-
validator: (e) =>
|
|
2470
|
+
validator: (e) => Ue.includes(e)
|
|
2455
2471
|
},
|
|
2456
2472
|
credentialType: {
|
|
2457
2473
|
type: String,
|
|
@@ -2464,7 +2480,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2464
2480
|
}
|
|
2465
2481
|
},
|
|
2466
2482
|
setup(e) {
|
|
2467
|
-
const t = e, n =
|
|
2483
|
+
const t = e, n = $(() => pi.includes(t.entityType)), i = (l, c) => {
|
|
2468
2484
|
const d = ie;
|
|
2469
2485
|
let u = "";
|
|
2470
2486
|
return typeof l == "string" ? u += `${d}${c} = "${l}"
|
|
@@ -2479,11 +2495,11 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2479
2495
|
`), l === null)
|
|
2480
2496
|
return c ? p += `${u}}` : p = "{}", p;
|
|
2481
2497
|
const g = Object.fromEntries(Object.entries(l).filter(([, x]) => x !== null));
|
|
2482
|
-
let
|
|
2483
|
-
for (const [x,
|
|
2484
|
-
Array.isArray(
|
|
2485
|
-
`,
|
|
2486
|
-
`,
|
|
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}
|
|
2487
2503
|
`;
|
|
2488
2504
|
return c ? p += `${u}}
|
|
2489
2505
|
` : p;
|
|
@@ -2495,9 +2511,9 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2495
2511
|
c && (l.length === 0 ? p += `${u}${c} = [` : p += `${u}${c} = [
|
|
2496
2512
|
`);
|
|
2497
2513
|
for (let g = 0; g < l.length; g++) {
|
|
2498
|
-
const
|
|
2499
|
-
typeof
|
|
2500
|
-
`, 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 += `
|
|
2501
2517
|
`;
|
|
2502
2518
|
}
|
|
2503
2519
|
return c && (l.length === 0 ? p += `]
|
|
@@ -2508,21 +2524,21 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2508
2524
|
for (const [d, u] of Object.entries(l))
|
|
2509
2525
|
Array.isArray(u) ? c += o(u, d) : typeof u == "object" ? c += r(u, d) : c += i(u, d);
|
|
2510
2526
|
return c;
|
|
2511
|
-
}, s =
|
|
2512
|
-
var p, g,
|
|
2513
|
-
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;
|
|
2514
2530
|
if (c && (l.config = c), Object.keys(l).length === 0)
|
|
2515
2531
|
return "";
|
|
2516
2532
|
delete l.id;
|
|
2517
2533
|
let d = "", u = "";
|
|
2518
|
-
if ((g = l.service) != null && g.id ? (u = "service", delete l.service) : (
|
|
2519
|
-
const
|
|
2520
|
-
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("_", "")}" {
|
|
2521
2537
|
`, d += `${ie}provider = konnect-beta
|
|
2522
2538
|
`;
|
|
2523
2539
|
} else if (t.entityType === "plugin") {
|
|
2524
|
-
const
|
|
2525
|
-
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}" {
|
|
2526
2542
|
`;
|
|
2527
2543
|
} else
|
|
2528
2544
|
d += `resource "konnect_gateway_${t.entityType}" "my_${t.entityType}" {
|
|
@@ -2536,24 +2552,92 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2536
2552
|
});
|
|
2537
2553
|
return (l, c) => {
|
|
2538
2554
|
const d = P("KCodeBlock");
|
|
2539
|
-
return m(), S("div",
|
|
2540
|
-
t.entityRecord ? (m(),
|
|
2555
|
+
return m(), S("div", Do, [
|
|
2556
|
+
t.entityRecord ? (m(), j(d, {
|
|
2541
2557
|
key: 0,
|
|
2542
2558
|
id: "terraform-codeblock",
|
|
2543
2559
|
code: s.value,
|
|
2544
2560
|
language: "terraform",
|
|
2545
2561
|
theme: "dark"
|
|
2546
|
-
}, 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)
|
|
2547
2631
|
]);
|
|
2548
2632
|
};
|
|
2549
2633
|
}
|
|
2550
|
-
}),
|
|
2634
|
+
}), Uo = {
|
|
2551
2635
|
key: 0,
|
|
2552
2636
|
class: "config-card-display-form"
|
|
2553
|
-
},
|
|
2637
|
+
}, qo = ["data-testid"], Ho = {
|
|
2554
2638
|
key: 0,
|
|
2555
2639
|
class: "config-card-prop-section-title"
|
|
2556
|
-
},
|
|
2640
|
+
}, Vo = /* @__PURE__ */ z({
|
|
2557
2641
|
__name: "ConfigCardDisplay",
|
|
2558
2642
|
props: {
|
|
2559
2643
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2565,7 +2649,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2565
2649
|
entityType: {
|
|
2566
2650
|
type: String,
|
|
2567
2651
|
required: !0,
|
|
2568
|
-
validator: (e) =>
|
|
2652
|
+
validator: (e) => Ue.includes(e)
|
|
2569
2653
|
},
|
|
2570
2654
|
subEntityType: {
|
|
2571
2655
|
// only for event gateway entities
|
|
@@ -2610,32 +2694,32 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2610
2694
|
}
|
|
2611
2695
|
},
|
|
2612
2696
|
setup(e) {
|
|
2613
|
-
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 = $(() => {
|
|
2614
2698
|
if (!t.record)
|
|
2615
2699
|
return t.record;
|
|
2616
2700
|
let s = t.record;
|
|
2617
2701
|
t.codeBlockRecordFormatter && (s = t.codeBlockRecordFormatter(s, t.format));
|
|
2618
2702
|
const l = JSON.parse(JSON.stringify(s));
|
|
2619
2703
|
return delete l.created_at, delete l.updated_at, l;
|
|
2620
|
-
}), a =
|
|
2704
|
+
}), a = $(() => t.fetcherUrl.replace(/(\?|&)__ui_data=true/, ""));
|
|
2621
2705
|
return (s, l) => (m(), S(ue, null, [
|
|
2622
|
-
e.format === "structured" ? (m(), S("div",
|
|
2706
|
+
e.format === "structured" ? (m(), S("div", Uo, [
|
|
2623
2707
|
(m(!0), S(ue, null, ce(e.propListTypes, (c) => (m(), S("div", {
|
|
2624
2708
|
key: `config-card-details-${c}-props`,
|
|
2625
2709
|
class: fe(`config-card-details-${c}-props`),
|
|
2626
2710
|
"data-testid": `config-card-details-${c}-props`
|
|
2627
2711
|
}, [
|
|
2628
|
-
c !== "basic" ? (m(), S("div",
|
|
2629
|
-
(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}`, {
|
|
2630
2714
|
key: d.key,
|
|
2631
2715
|
item: d
|
|
2632
2716
|
}, () => [
|
|
2633
|
-
|
|
2634
|
-
label:
|
|
2635
|
-
|
|
2717
|
+
K(Xt, { item: d }, Se({
|
|
2718
|
+
label: k(() => [
|
|
2719
|
+
D(s.$slots, `${d.key}-label`, { row: d }, void 0, !0)
|
|
2636
2720
|
]),
|
|
2637
|
-
[d.key]:
|
|
2638
|
-
|
|
2721
|
+
[d.key]: k(({ rowValue: u }) => [
|
|
2722
|
+
D(s.$slots, d.key, {
|
|
2639
2723
|
row: d,
|
|
2640
2724
|
rowValue: u
|
|
2641
2725
|
}, void 0, !0)
|
|
@@ -2644,38 +2728,45 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2644
2728
|
}, [
|
|
2645
2729
|
r(d) ? {
|
|
2646
2730
|
name: "label-tooltip",
|
|
2647
|
-
fn:
|
|
2648
|
-
|
|
2731
|
+
fn: k(() => [
|
|
2732
|
+
D(s.$slots, `${d.key}-label-tooltip`, { row: d }, void 0, !0)
|
|
2649
2733
|
]),
|
|
2650
2734
|
key: "0"
|
|
2651
2735
|
} : void 0
|
|
2652
2736
|
]), 1032, ["item"])
|
|
2653
2737
|
], !0)), 128))
|
|
2654
|
-
], 10,
|
|
2655
|
-
])) :
|
|
2656
|
-
e.format === "json" && o.value ? (m(),
|
|
2738
|
+
], 10, qo))), 128))
|
|
2739
|
+
])) : M("", !0),
|
|
2740
|
+
e.format === "json" && o.value ? (m(), j(en, {
|
|
2657
2741
|
key: 1,
|
|
2658
2742
|
config: t.config,
|
|
2659
2743
|
"entity-record": o.value,
|
|
2660
2744
|
"fetcher-url": a.value,
|
|
2661
2745
|
"request-method": "get"
|
|
2662
|
-
}, null, 8, ["config", "entity-record", "fetcher-url"])) :
|
|
2663
|
-
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, {
|
|
2664
2748
|
key: 2,
|
|
2665
2749
|
"entity-record": o.value
|
|
2666
|
-
}, null, 8, ["entity-record"])) :
|
|
2667
|
-
e.format === "terraform" && o.value ? (m(),
|
|
2750
|
+
}, null, 8, ["entity-record"])) : M("", !0),
|
|
2751
|
+
e.format === "terraform" && o.value ? (m(), j(Yn, {
|
|
2668
2752
|
key: 3,
|
|
2669
2753
|
"entity-record": o.value,
|
|
2670
2754
|
"entity-type": t.entityType,
|
|
2671
2755
|
"sub-entity-type": t.subEntityType
|
|
2672
|
-
}, 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)
|
|
2673
2764
|
], 64));
|
|
2674
2765
|
}
|
|
2675
|
-
}),
|
|
2766
|
+
}), Yo = /* @__PURE__ */ se(Vo, [["__scopeId", "data-v-2104198c"]]), Wo = {
|
|
2676
2767
|
class: "config-card-title",
|
|
2677
2768
|
"data-testid": "config-card-title"
|
|
2678
|
-
},
|
|
2769
|
+
}, Jo = { class: "config-card-actions" }, Go = ["href"], zo = { class: "config-card-details-section" }, Qo = /* @__PURE__ */ z({
|
|
2679
2770
|
__name: "EntityBaseConfigCard",
|
|
2680
2771
|
props: {
|
|
2681
2772
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -2696,7 +2787,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2696
2787
|
entityType: {
|
|
2697
2788
|
type: String,
|
|
2698
2789
|
required: !0,
|
|
2699
|
-
validator: (e) =>
|
|
2790
|
+
validator: (e) => Ue.includes(e)
|
|
2700
2791
|
},
|
|
2701
2792
|
/**
|
|
2702
2793
|
* Sub Entity type, required to generate terraform code for event gateway entities
|
|
@@ -2819,14 +2910,14 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2819
2910
|
label: r("baseForm.configuration.terraform"),
|
|
2820
2911
|
value: "terraform"
|
|
2821
2912
|
});
|
|
2822
|
-
const c = l[0].value, d =
|
|
2913
|
+
const c = l[0].value, d = N(c), u = (f) => {
|
|
2823
2914
|
d.value = f == null ? void 0 : f.value, n("configFormatChange", d.value);
|
|
2824
2915
|
}, p = (f, v) => {
|
|
2825
2916
|
localStorage.setItem(f, v);
|
|
2826
2917
|
};
|
|
2827
2918
|
be(d, (f) => {
|
|
2828
2919
|
i.config.formatPreferenceKey && p(i.config.formatPreferenceKey, f);
|
|
2829
|
-
}),
|
|
2920
|
+
}), nt(() => {
|
|
2830
2921
|
if (i.config.formatPreferenceKey) {
|
|
2831
2922
|
const f = localStorage.getItem(i.config.formatPreferenceKey);
|
|
2832
2923
|
f && l.some((v) => v.value === f) ? d.value = f : d.value = c, p(i.config.formatPreferenceKey, d.value);
|
|
@@ -2873,195 +2964,195 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
2873
2964
|
// the last property displayed
|
|
2874
2965
|
section: ae.Basic
|
|
2875
2966
|
}
|
|
2876
|
-
},
|
|
2877
|
-
var b, H,
|
|
2878
|
-
if (!
|
|
2967
|
+
}, y = N(!1), x = N(!1), h = N(""), A = N({}), C = $(() => {
|
|
2968
|
+
var b, H, J;
|
|
2969
|
+
if (!A.value)
|
|
2879
2970
|
return [];
|
|
2880
|
-
const f = [], v = Object.keys(
|
|
2881
|
-
for (const I in
|
|
2971
|
+
const f = [], v = Object.keys(A.value).length;
|
|
2972
|
+
for (const I in A.value) {
|
|
2882
2973
|
if (I === "__ui_data") continue;
|
|
2883
|
-
const
|
|
2884
|
-
let
|
|
2885
|
-
(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]);
|
|
2886
2977
|
}
|
|
2887
|
-
return f.sort(function(I,
|
|
2888
|
-
return I[1] -
|
|
2978
|
+
return f.sort(function(I, R) {
|
|
2979
|
+
return I[1] - R[1];
|
|
2889
2980
|
}), f.map((I) => {
|
|
2890
2981
|
var dt, ft;
|
|
2891
|
-
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];
|
|
2892
2983
|
return {
|
|
2893
|
-
key:
|
|
2984
|
+
key: R,
|
|
2894
2985
|
value: G,
|
|
2895
|
-
hidden:
|
|
2896
|
-
type:
|
|
2897
|
-
label:
|
|
2898
|
-
tooltip:
|
|
2899
|
-
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)
|
|
2900
2991
|
};
|
|
2901
2992
|
}).filter((I) => !I.hidden && I.key !== i.pluginConfigKey);
|
|
2902
|
-
}),
|
|
2903
|
-
var H,
|
|
2904
|
-
if (!
|
|
2993
|
+
}), E = $(() => {
|
|
2994
|
+
var H, J;
|
|
2995
|
+
if (!A.value || !i.pluginConfigKey)
|
|
2905
2996
|
return [];
|
|
2906
|
-
const f =
|
|
2997
|
+
const f = A.value[i.pluginConfigKey] || {}, v = Object.keys(f).length, b = [];
|
|
2907
2998
|
for (const I in f) {
|
|
2908
|
-
const
|
|
2909
|
-
let
|
|
2910
|
-
|
|
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]);
|
|
2911
3002
|
}
|
|
2912
|
-
return b.sort(function(I,
|
|
2913
|
-
return I[1] -
|
|
3003
|
+
return b.sort(function(I, R) {
|
|
3004
|
+
return I[1] - R[1];
|
|
2914
3005
|
}), b.map((I) => {
|
|
2915
3006
|
var Q;
|
|
2916
|
-
const
|
|
3007
|
+
const R = I[0], G = f[R], q = ((Q = i.pluginConfigSchema) == null ? void 0 : Q[R]) || {};
|
|
2917
3008
|
return {
|
|
2918
|
-
key:
|
|
3009
|
+
key: R,
|
|
2919
3010
|
value: G,
|
|
2920
|
-
hidden:
|
|
2921
|
-
type:
|
|
2922
|
-
label:
|
|
2923
|
-
tooltip:
|
|
3011
|
+
hidden: q.hidden || !1,
|
|
3012
|
+
type: q.type ?? V.Text,
|
|
3013
|
+
label: q.label ?? a(R),
|
|
3014
|
+
tooltip: q.tooltip ?? void 0,
|
|
2924
3015
|
section: ae.Plugin
|
|
2925
3016
|
};
|
|
2926
3017
|
}).filter((I) => !I.hidden);
|
|
2927
|
-
}),
|
|
2928
|
-
var H,
|
|
2929
|
-
if (!
|
|
3018
|
+
}), Y = $(() => {
|
|
3019
|
+
var H, J;
|
|
3020
|
+
if (!A.value || !i.policyConfigKey)
|
|
2930
3021
|
return [];
|
|
2931
|
-
const f =
|
|
3022
|
+
const f = A.value[i.policyConfigKey] || {}, v = Object.keys(f).length, b = [];
|
|
2932
3023
|
for (const I in f) {
|
|
2933
|
-
const
|
|
2934
|
-
let
|
|
2935
|
-
|
|
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]);
|
|
2936
3027
|
}
|
|
2937
|
-
return b.sort(function(I,
|
|
2938
|
-
return I[1] -
|
|
3028
|
+
return b.sort(function(I, R) {
|
|
3029
|
+
return I[1] - R[1];
|
|
2939
3030
|
}), b.map((I) => {
|
|
2940
3031
|
var Q;
|
|
2941
|
-
const
|
|
3032
|
+
const R = I[0], G = f[R], q = ((Q = i.policyConfigSchema) == null ? void 0 : Q[R]) || {};
|
|
2942
3033
|
return {
|
|
2943
|
-
key:
|
|
3034
|
+
key: R,
|
|
2944
3035
|
value: G,
|
|
2945
|
-
hidden:
|
|
2946
|
-
type:
|
|
2947
|
-
label:
|
|
2948
|
-
tooltip:
|
|
3036
|
+
hidden: q.hidden || !1,
|
|
3037
|
+
type: q.type ?? V.Text,
|
|
3038
|
+
label: q.label ?? a(R),
|
|
3039
|
+
tooltip: q.tooltip ?? void 0,
|
|
2949
3040
|
section: ae.Policy
|
|
2950
3041
|
};
|
|
2951
3042
|
}).filter((I) => !I.hidden);
|
|
2952
|
-
}), X =
|
|
2953
|
-
var f, v, b, H,
|
|
3043
|
+
}), X = $(() => {
|
|
3044
|
+
var f, v, b, H, J, I;
|
|
2954
3045
|
return {
|
|
2955
|
-
basic: (f = C.value) == null ? void 0 : f.filter((
|
|
2956
|
-
advanced: (v = C.value) == null ? void 0 : v.filter((
|
|
2957
|
-
plugin: (H =
|
|
2958
|
-
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))
|
|
2959
3050
|
};
|
|
2960
|
-
}), w =
|
|
3051
|
+
}), w = $(() => {
|
|
2961
3052
|
const f = [];
|
|
2962
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;
|
|
2963
|
-
}),
|
|
3054
|
+
}), _ = $(() => {
|
|
2964
3055
|
var v, b;
|
|
2965
3056
|
let f = `${i.config.apiBaseUrl}${i.fetchUrl}`;
|
|
2966
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;
|
|
2967
3058
|
});
|
|
2968
|
-
return be(
|
|
3059
|
+
return be(y, (f) => {
|
|
2969
3060
|
n("loading", f);
|
|
2970
|
-
}, { immediate: !0 }),
|
|
2971
|
-
x.value = !1,
|
|
3061
|
+
}, { immediate: !0 }), it(async () => {
|
|
3062
|
+
x.value = !1, y.value = !0;
|
|
2972
3063
|
try {
|
|
2973
|
-
const { data: f } = await s.get(
|
|
3064
|
+
const { data: f } = await s.get(_.value);
|
|
2974
3065
|
if (i.dataKey)
|
|
2975
3066
|
if (typeof f[i.dataKey] < "u")
|
|
2976
|
-
|
|
3067
|
+
A.value = { ...f[i.dataKey] };
|
|
2977
3068
|
else
|
|
2978
3069
|
throw new Error(r("errors.dataKeyUndefined", { dataKey: i.dataKey }));
|
|
2979
|
-
else i.recordResolver ?
|
|
3070
|
+
else i.recordResolver ? A.value = { ...i.recordResolver(f) } : A.value = { ...f };
|
|
2980
3071
|
Object.keys(i.configSchema).filter((b) => i.configSchema[b].forceShow).forEach((b) => {
|
|
2981
|
-
|
|
3072
|
+
A.value && typeof A.value[b] > "u" && (A.value[b] = null);
|
|
2982
3073
|
}), n("fetch:success", f);
|
|
2983
3074
|
} catch (f) {
|
|
2984
3075
|
const v = o(f);
|
|
2985
|
-
|
|
3076
|
+
h.value = v.startsWith("code") ? r("baseConfigCard.errors.load") : v, x.value = !0, n("fetch:error", f);
|
|
2986
3077
|
} finally {
|
|
2987
|
-
|
|
3078
|
+
y.value = !1;
|
|
2988
3079
|
}
|
|
2989
3080
|
}), (f, v) => {
|
|
2990
|
-
const b = P("KLabel"), H = P("KSelect"),
|
|
2991
|
-
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, {
|
|
2992
3083
|
class: "kong-ui-entity-base-config-card",
|
|
2993
3084
|
"title-tag": e.titleTag
|
|
2994
3085
|
}, Se({
|
|
2995
|
-
actions:
|
|
2996
|
-
|
|
2997
|
-
|
|
2998
|
-
|
|
3086
|
+
actions: k(() => [
|
|
3087
|
+
B("div", Jo, [
|
|
3088
|
+
D(f.$slots, "actions", {}, void 0, !0),
|
|
3089
|
+
K(b, {
|
|
2999
3090
|
class: "config-format-select-label",
|
|
3000
3091
|
"data-testid": "config-format-select-label"
|
|
3001
3092
|
}, {
|
|
3002
|
-
default:
|
|
3003
|
-
|
|
3093
|
+
default: k(() => [
|
|
3094
|
+
U(L(e.label), 1)
|
|
3004
3095
|
]),
|
|
3005
3096
|
_: 1
|
|
3006
3097
|
}),
|
|
3007
|
-
|
|
3098
|
+
K(H, {
|
|
3008
3099
|
modelValue: d.value,
|
|
3009
|
-
"onUpdate:modelValue": v[0] || (v[0] = (
|
|
3100
|
+
"onUpdate:modelValue": v[0] || (v[0] = (q) => d.value = q),
|
|
3010
3101
|
"data-testid": "select-config-format",
|
|
3011
3102
|
items: l,
|
|
3012
3103
|
onChange: u
|
|
3013
3104
|
}, null, 8, ["modelValue"]),
|
|
3014
|
-
e.configCardDoc ? (m(),
|
|
3105
|
+
e.configCardDoc ? (m(), j(J, {
|
|
3015
3106
|
key: 0,
|
|
3016
3107
|
appearance: "tertiary",
|
|
3017
3108
|
class: "book-icon",
|
|
3018
3109
|
"data-testid": "book-icon"
|
|
3019
3110
|
}, {
|
|
3020
|
-
default:
|
|
3021
|
-
|
|
3111
|
+
default: k(() => [
|
|
3112
|
+
B("a", {
|
|
3022
3113
|
href: e.configCardDoc,
|
|
3023
3114
|
rel: "noopener",
|
|
3024
3115
|
target: "_blank"
|
|
3025
3116
|
}, [
|
|
3026
|
-
|
|
3027
|
-
], 8,
|
|
3117
|
+
K(T(Vt), { size: T(rr) }, null, 8, ["size"])
|
|
3118
|
+
], 8, Go)
|
|
3028
3119
|
]),
|
|
3029
3120
|
_: 1
|
|
3030
|
-
})) :
|
|
3121
|
+
})) : M("", !0)
|
|
3031
3122
|
])
|
|
3032
3123
|
]),
|
|
3033
|
-
default:
|
|
3034
|
-
|
|
3124
|
+
default: k(() => [
|
|
3125
|
+
y.value ? (m(), j(I, {
|
|
3035
3126
|
key: 0,
|
|
3036
3127
|
"data-testid": "config-card-loader",
|
|
3037
3128
|
"table-columns": 2,
|
|
3038
3129
|
type: "table"
|
|
3039
|
-
})) : x.value ? (m(),
|
|
3130
|
+
})) : x.value ? (m(), j(R, {
|
|
3040
3131
|
key: 1,
|
|
3041
3132
|
"data-testid": "config-card-fetch-error",
|
|
3042
3133
|
"icon-variant": "error"
|
|
3043
3134
|
}, {
|
|
3044
|
-
default:
|
|
3045
|
-
|
|
3135
|
+
default: k(() => [
|
|
3136
|
+
B("h3", null, L(h.value), 1)
|
|
3046
3137
|
]),
|
|
3047
3138
|
_: 1
|
|
3048
|
-
})) :
|
|
3049
|
-
|
|
3050
|
-
|
|
3139
|
+
})) : M("", !0),
|
|
3140
|
+
B("div", zo, [
|
|
3141
|
+
K(Yo, {
|
|
3051
3142
|
"code-block-record-formatter": e.codeBlockRecordFormatter,
|
|
3052
3143
|
config: e.config,
|
|
3053
3144
|
"entity-type": e.entityType,
|
|
3054
|
-
"fetcher-url":
|
|
3145
|
+
"fetcher-url": _.value,
|
|
3055
3146
|
format: d.value,
|
|
3056
3147
|
"prop-list-types": w.value,
|
|
3057
3148
|
"property-collections": X.value,
|
|
3058
|
-
record:
|
|
3149
|
+
record: A.value,
|
|
3059
3150
|
"sub-entity-type": e.subEntityType
|
|
3060
3151
|
}, Se({ _: 2 }, [
|
|
3061
|
-
ce(Object.keys(f.$slots), (
|
|
3062
|
-
name:
|
|
3063
|
-
fn:
|
|
3064
|
-
|
|
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)
|
|
3065
3156
|
])
|
|
3066
3157
|
}))
|
|
3067
3158
|
]), 1032, ["code-block-record-formatter", "config", "entity-type", "fetcher-url", "format", "prop-list-types", "property-collections", "record", "sub-entity-type"])
|
|
@@ -3071,10 +3162,10 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3071
3162
|
}, [
|
|
3072
3163
|
e.hideTitle ? void 0 : {
|
|
3073
3164
|
name: "title",
|
|
3074
|
-
fn:
|
|
3075
|
-
|
|
3076
|
-
|
|
3077
|
-
|
|
3165
|
+
fn: k(() => [
|
|
3166
|
+
B("span", Wo, [
|
|
3167
|
+
D(f.$slots, "title", {}, () => [
|
|
3168
|
+
U(L(T(r)("baseConfigCard.title")), 1)
|
|
3078
3169
|
], !0)
|
|
3079
3170
|
])
|
|
3080
3171
|
]),
|
|
@@ -3083,7 +3174,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3083
3174
|
]), 1032, ["title-tag"]);
|
|
3084
3175
|
};
|
|
3085
3176
|
}
|
|
3086
|
-
}),
|
|
3177
|
+
}), hs = /* @__PURE__ */ se(Qo, [["__scopeId", "data-v-f2b42324"]]), Zo = ["novalidate"], Xo = /* @__PURE__ */ z({
|
|
3087
3178
|
__name: "EntityBaseForm",
|
|
3088
3179
|
props: {
|
|
3089
3180
|
/** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
|
|
@@ -3104,7 +3195,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3104
3195
|
entityType: {
|
|
3105
3196
|
type: String,
|
|
3106
3197
|
required: !0,
|
|
3107
|
-
validator: (e) =>
|
|
3198
|
+
validator: (e) => Ue.includes(e)
|
|
3108
3199
|
},
|
|
3109
3200
|
/**
|
|
3110
3201
|
* Sub entity type, required for event gateway entities to generate terraform code
|
|
@@ -3207,19 +3298,19 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3207
3298
|
emits: ["loading", "fetch:success", "fetch:error", "submit", "cancel", "codeBlockTabChange"],
|
|
3208
3299
|
setup(e, { expose: t, emit: n }) {
|
|
3209
3300
|
var X;
|
|
3210
|
-
const i = n, r = e, o =
|
|
3211
|
-
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;
|
|
3212
3303
|
let w = `${r.config.apiBaseUrl}${r.fetchUrl}`;
|
|
3213
|
-
return r.config.app === "konnect" ? w = w.replace(/{controlPlaneId}/gi, ((
|
|
3214
|
-
}),
|
|
3215
|
-
|
|
3216
|
-
},
|
|
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 = () => {
|
|
3217
3308
|
r.config.cancelRoute ? o.push(r.config.cancelRoute) : C();
|
|
3218
3309
|
}, C = () => {
|
|
3219
3310
|
i("cancel");
|
|
3220
|
-
},
|
|
3311
|
+
}, E = () => {
|
|
3221
3312
|
g.value || i("submit");
|
|
3222
|
-
},
|
|
3313
|
+
}, Y = N([
|
|
3223
3314
|
{
|
|
3224
3315
|
title: a("baseForm.configuration.json"),
|
|
3225
3316
|
hash: "#json"
|
|
@@ -3229,143 +3320,153 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3229
3320
|
hash: "#yaml"
|
|
3230
3321
|
}
|
|
3231
3322
|
]);
|
|
3232
|
-
return r.config.app === "konnect" && r.entityType !==
|
|
3323
|
+
return r.config.app === "konnect" && r.entityType !== Ee.Other && Y.value.splice(1, 0, {
|
|
3233
3324
|
title: a("baseForm.configuration.terraform"),
|
|
3234
3325
|
hash: "#terraform"
|
|
3326
|
+
}), fi.includes(r.entityType) && Y.value.push({
|
|
3327
|
+
title: a("baseForm.configuration.deck"),
|
|
3328
|
+
hash: "#deck"
|
|
3235
3329
|
}), be(() => c.value, (w) => {
|
|
3236
3330
|
i("loading", w);
|
|
3237
|
-
}, { immediate: !0 }),
|
|
3331
|
+
}, { immediate: !0 }), it(async () => {
|
|
3238
3332
|
if (r.editId)
|
|
3239
3333
|
try {
|
|
3240
3334
|
u.value = !1, c.value = !0;
|
|
3241
3335
|
const { data: w } = await l.get(x.value);
|
|
3242
3336
|
i("fetch:success", w);
|
|
3243
3337
|
} catch (w) {
|
|
3244
|
-
const
|
|
3245
|
-
p.value =
|
|
3338
|
+
const _ = s(w);
|
|
3339
|
+
p.value = _.startsWith("code") ? a("baseForm.errors.edit") : _, u.value = !0, i("fetch:error", w);
|
|
3246
3340
|
} finally {
|
|
3247
3341
|
c.value = !1;
|
|
3248
3342
|
}
|
|
3249
3343
|
}), t({
|
|
3250
|
-
viewConfig:
|
|
3344
|
+
viewConfig: h,
|
|
3251
3345
|
formCancel: C,
|
|
3252
|
-
formSubmit:
|
|
3253
|
-
}), (w,
|
|
3254
|
-
const O = P("KSkeleton"), f = P("KEmptyState"), v = P("KAlert"), b = P("KButton"), H = P("KTabs"),
|
|
3255
|
-
return m(),
|
|
3256
|
-
default:
|
|
3257
|
-
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, {
|
|
3258
3352
|
key: 0,
|
|
3259
3353
|
type: "form"
|
|
3260
|
-
})) : u.value ? (m(),
|
|
3354
|
+
})) : u.value ? (m(), j(f, {
|
|
3261
3355
|
key: 1,
|
|
3262
|
-
"action-button-text":
|
|
3356
|
+
"action-button-text": T(a)("baseForm.actions.back"),
|
|
3263
3357
|
"data-testid": "form-fetch-error",
|
|
3264
3358
|
"icon-variant": "error",
|
|
3265
|
-
onClickAction:
|
|
3359
|
+
onClickAction: A
|
|
3266
3360
|
}, {
|
|
3267
|
-
default:
|
|
3268
|
-
|
|
3361
|
+
default: k(() => [
|
|
3362
|
+
B("h3", null, L(p.value), 1)
|
|
3269
3363
|
]),
|
|
3270
3364
|
_: 1
|
|
3271
3365
|
}, 8, ["action-button-text"])) : (m(), S("form", {
|
|
3272
3366
|
key: 2,
|
|
3273
3367
|
"data-testid": "form-content",
|
|
3274
3368
|
novalidate: r.noValidate,
|
|
3275
|
-
onReset:
|
|
3276
|
-
onSubmit:
|
|
3369
|
+
onReset: Be(C, ["prevent"]),
|
|
3370
|
+
onSubmit: Be(E, ["prevent"])
|
|
3277
3371
|
}, [
|
|
3278
|
-
|
|
3279
|
-
e.errorMessage ? (m(),
|
|
3372
|
+
D(w.$slots, "default", {}, void 0, !0),
|
|
3373
|
+
e.errorMessage ? (m(), j(v, {
|
|
3280
3374
|
key: 0,
|
|
3281
3375
|
appearance: "danger",
|
|
3282
3376
|
"data-testid": "form-error",
|
|
3283
3377
|
message: e.errorMessage
|
|
3284
|
-
}, null, 8, ["message"])) :
|
|
3285
|
-
e.hideActions ?
|
|
3378
|
+
}, null, 8, ["message"])) : M("", !0),
|
|
3379
|
+
e.hideActions ? M("", !0) : (m(), j(Ht, {
|
|
3286
3380
|
key: 1,
|
|
3287
3381
|
disabled: !e.actionTeleportTarget,
|
|
3288
3382
|
to: e.actionTeleportTarget
|
|
3289
3383
|
}, [
|
|
3290
|
-
|
|
3384
|
+
B("div", {
|
|
3291
3385
|
class: fe(["form-actions", { "form-actions-reverted": e.alignActionButtonToLeft }]),
|
|
3292
3386
|
"data-testid": "form-actions"
|
|
3293
3387
|
}, [
|
|
3294
|
-
|
|
3295
|
-
|
|
3388
|
+
D(w.$slots, "form-actions", {}, () => [
|
|
3389
|
+
K(b, {
|
|
3296
3390
|
appearance: "tertiary",
|
|
3297
3391
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-view-configuration`,
|
|
3298
|
-
onClick:
|
|
3392
|
+
onClick: _[0] || (_[0] = (I) => h())
|
|
3299
3393
|
}, {
|
|
3300
|
-
default:
|
|
3301
|
-
|
|
3394
|
+
default: k(() => [
|
|
3395
|
+
U(L(T(a)("baseForm.actions.viewConfiguration")), 1)
|
|
3302
3396
|
]),
|
|
3303
3397
|
_: 1
|
|
3304
3398
|
}, 8, ["data-testid"]),
|
|
3305
|
-
|
|
3399
|
+
K(b, {
|
|
3306
3400
|
appearance: "secondary",
|
|
3307
3401
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-cancel`,
|
|
3308
3402
|
disabled: e.isReadonly,
|
|
3309
3403
|
type: "reset",
|
|
3310
|
-
onClick:
|
|
3404
|
+
onClick: _[1] || (_[1] = (I) => !!e.actionTeleportTarget && C())
|
|
3311
3405
|
}, {
|
|
3312
|
-
default:
|
|
3313
|
-
|
|
3406
|
+
default: k(() => [
|
|
3407
|
+
U(L(e.cancelButtonText ?? T(a)("baseForm.actions.cancel")), 1)
|
|
3314
3408
|
]),
|
|
3315
3409
|
_: 1
|
|
3316
3410
|
}, 8, ["data-testid", "disabled"]),
|
|
3317
|
-
|
|
3411
|
+
K(b, {
|
|
3318
3412
|
appearance: "primary",
|
|
3319
3413
|
"data-testid": `${e.entityType}-${d.value ? "edit" : "create"}-form-submit`,
|
|
3320
3414
|
disabled: g.value,
|
|
3321
3415
|
type: "submit",
|
|
3322
|
-
onClick:
|
|
3416
|
+
onClick: _[2] || (_[2] = (I) => !!e.actionTeleportTarget && E())
|
|
3323
3417
|
}, {
|
|
3324
|
-
default:
|
|
3325
|
-
|
|
3418
|
+
default: k(() => [
|
|
3419
|
+
U(L(e.saveButtonText ?? T(a)("baseForm.actions.save")), 1)
|
|
3326
3420
|
]),
|
|
3327
3421
|
_: 1
|
|
3328
3422
|
}, 8, ["data-testid", "disabled"])
|
|
3329
3423
|
], !0)
|
|
3330
3424
|
], 2)
|
|
3331
3425
|
], 8, ["disabled", "to"]))
|
|
3332
|
-
], 40,
|
|
3333
|
-
|
|
3426
|
+
], 40, Zo)),
|
|
3427
|
+
K(J, {
|
|
3334
3428
|
"close-on-blur": !1,
|
|
3335
3429
|
"data-testid": "form-view-configuration-slideout",
|
|
3336
3430
|
"has-overlay": !1,
|
|
3337
3431
|
"offset-top": e.slidoutTopOffset,
|
|
3338
|
-
title:
|
|
3339
|
-
visible:
|
|
3340
|
-
onClose:
|
|
3432
|
+
title: T(a)("baseForm.configuration.title"),
|
|
3433
|
+
visible: y.value,
|
|
3434
|
+
onClose: _[4] || (_[4] = (I) => h())
|
|
3341
3435
|
}, {
|
|
3342
|
-
default:
|
|
3343
|
-
|
|
3344
|
-
|
|
3436
|
+
default: k(() => [
|
|
3437
|
+
B("div", null, L(T(a)("baseForm.configuration.message")), 1),
|
|
3438
|
+
K(H, {
|
|
3345
3439
|
"data-testid": "form-view-configuration-slideout-tabs",
|
|
3346
|
-
tabs:
|
|
3347
|
-
onChange:
|
|
3440
|
+
tabs: Y.value,
|
|
3441
|
+
onChange: _[3] || (_[3] = (I) => i("codeBlockTabChange", I.replace("#", "")))
|
|
3348
3442
|
}, {
|
|
3349
|
-
json:
|
|
3350
|
-
|
|
3443
|
+
json: k(() => [
|
|
3444
|
+
K(en, {
|
|
3351
3445
|
config: e.config,
|
|
3352
3446
|
"entity-record": r.formFields,
|
|
3353
3447
|
"fetcher-url": x.value,
|
|
3354
3448
|
"request-method": r.editId ? "put" : "post"
|
|
3355
3449
|
}, null, 8, ["config", "entity-record", "fetcher-url", "request-method"])
|
|
3356
3450
|
]),
|
|
3357
|
-
yaml:
|
|
3358
|
-
|
|
3451
|
+
yaml: k(() => [
|
|
3452
|
+
K(Vn, {
|
|
3359
3453
|
"entity-record": r.formFields
|
|
3360
3454
|
}, null, 8, ["entity-record"])
|
|
3361
3455
|
]),
|
|
3362
|
-
terraform:
|
|
3363
|
-
|
|
3456
|
+
terraform: k(() => [
|
|
3457
|
+
K(Yn, {
|
|
3364
3458
|
"entity-record": r.formFields,
|
|
3365
3459
|
"entity-type": e.entityType,
|
|
3366
3460
|
"sub-entity-type": e.subEntityType
|
|
3367
3461
|
}, null, 8, ["entity-record", "entity-type", "sub-entity-type"])
|
|
3368
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
|
+
]),
|
|
3369
3470
|
_: 1
|
|
3370
3471
|
}, 8, ["tabs"])
|
|
3371
3472
|
]),
|
|
@@ -3376,7 +3477,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3376
3477
|
});
|
|
3377
3478
|
};
|
|
3378
3479
|
}
|
|
3379
|
-
}),
|
|
3480
|
+
}), vs = /* @__PURE__ */ se(Xo, [["__scopeId", "data-v-b732b5bb"]]), el = ["data-truncate"], tl = /* @__PURE__ */ z({
|
|
3380
3481
|
__name: "EntityBaseTableCell",
|
|
3381
3482
|
props: {
|
|
3382
3483
|
keyName: {
|
|
@@ -3393,48 +3494,48 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3393
3494
|
}
|
|
3394
3495
|
},
|
|
3395
3496
|
setup(e) {
|
|
3396
|
-
const t = e, n =
|
|
3397
|
-
var
|
|
3398
|
-
return ((
|
|
3399
|
-
}), i =
|
|
3400
|
-
var
|
|
3401
|
-
return ((
|
|
3402
|
-
}), r =
|
|
3403
|
-
var
|
|
3404
|
-
const
|
|
3405
|
-
return
|
|
3406
|
-
}), 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);
|
|
3407
3508
|
let a;
|
|
3408
3509
|
const s = () => {
|
|
3409
3510
|
a && (a.disconnect(), a = void 0);
|
|
3410
3511
|
}, l = () => {
|
|
3411
|
-
var
|
|
3412
|
-
let
|
|
3512
|
+
var A, C, E;
|
|
3513
|
+
let h = ((A = n.value) == null ? void 0 : A.clientWidth) || 0;
|
|
3413
3514
|
if (n.value && "getComputedStyle" in window) {
|
|
3414
|
-
const
|
|
3415
|
-
|
|
3515
|
+
const Y = window.getComputedStyle(n.value);
|
|
3516
|
+
h -= (parseFloat(Y.paddingLeft) || 0) + (parseFloat(Y.paddingRight) || 0);
|
|
3416
3517
|
}
|
|
3417
|
-
d.value = ((C = i.value) == null ? void 0 : C.getBoundingClientRect().width) || 0, u.value =
|
|
3418
|
-
}, 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(
|
|
3419
3520
|
g,
|
|
3420
|
-
(
|
|
3521
|
+
(h) => {
|
|
3421
3522
|
if (o.value && (s(), "ResizeObserver" in window && window)) {
|
|
3422
|
-
a = new ResizeObserver((
|
|
3523
|
+
a = new ResizeObserver((A) => {
|
|
3423
3524
|
window.requestAnimationFrame(() => {
|
|
3424
|
-
!Array.isArray(
|
|
3525
|
+
!Array.isArray(A) || !A.length || l();
|
|
3425
3526
|
});
|
|
3426
3527
|
});
|
|
3427
|
-
for (const
|
|
3428
|
-
|
|
3528
|
+
for (const A of h)
|
|
3529
|
+
A && a.observe(A);
|
|
3429
3530
|
}
|
|
3430
3531
|
},
|
|
3431
3532
|
{ immediate: !0, flush: "post", deep: !0 }
|
|
3432
|
-
), x =
|
|
3433
|
-
return
|
|
3533
|
+
), x = $(() => o.value ? d.value > u.value : !1);
|
|
3534
|
+
return nt(() => {
|
|
3434
3535
|
l();
|
|
3435
|
-
}),
|
|
3436
|
-
|
|
3437
|
-
}), (
|
|
3536
|
+
}), Zn(() => {
|
|
3537
|
+
y();
|
|
3538
|
+
}), (h, A) => {
|
|
3438
3539
|
const C = P("KTooltip");
|
|
3439
3540
|
return m(), S("span", {
|
|
3440
3541
|
ref_key: "contentRef",
|
|
@@ -3445,27 +3546,27 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3445
3546
|
key: 0,
|
|
3446
3547
|
"data-truncate": o.value || void 0
|
|
3447
3548
|
}, [
|
|
3448
|
-
|
|
3549
|
+
K(C, {
|
|
3449
3550
|
"max-width": "300",
|
|
3450
3551
|
placement: "bottom-start",
|
|
3451
3552
|
text: x.value ? p.value : ""
|
|
3452
3553
|
}, {
|
|
3453
|
-
default:
|
|
3454
|
-
|
|
3554
|
+
default: k(() => [
|
|
3555
|
+
D(h.$slots, "default", {}, void 0, !0)
|
|
3455
3556
|
]),
|
|
3456
3557
|
_: 3
|
|
3457
3558
|
}, 8, ["text"])
|
|
3458
|
-
], 8,
|
|
3559
|
+
], 8, el)) : D(h.$slots, "default", { key: 1 }, void 0, !0)
|
|
3459
3560
|
], 512);
|
|
3460
3561
|
};
|
|
3461
3562
|
}
|
|
3462
|
-
}),
|
|
3563
|
+
}), nl = /* @__PURE__ */ se(tl, [["__scopeId", "data-v-a3a65cac"]]), il = { class: "toolbar-container" }, rl = {
|
|
3463
3564
|
key: 0,
|
|
3464
3565
|
class: "toolbar-button-container"
|
|
3465
|
-
},
|
|
3566
|
+
}, al = {
|
|
3466
3567
|
key: 0,
|
|
3467
3568
|
class: "hidden"
|
|
3468
|
-
},
|
|
3569
|
+
}, ol = /* @__PURE__ */ z({
|
|
3469
3570
|
__name: "EntityBaseTable",
|
|
3470
3571
|
props: {
|
|
3471
3572
|
// table header configuration
|
|
@@ -3610,7 +3711,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3610
3711
|
},
|
|
3611
3712
|
emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked", "state"],
|
|
3612
3713
|
setup(e, { emit: t }) {
|
|
3613
|
-
const n = e, i = t, { i18n: { t: r } } = W.useI18n(), o =
|
|
3714
|
+
const n = e, i = t, { i18n: { t: r } } = W.useI18n(), o = $(() => {
|
|
3614
3715
|
var f, v;
|
|
3615
3716
|
return typeof n.errorMessage == "string" ? {
|
|
3616
3717
|
hasError: !!n.errorMessage,
|
|
@@ -3621,7 +3722,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3621
3722
|
title: (f = n.errorMessage) == null ? void 0 : f.title,
|
|
3622
3723
|
message: (v = n.errorMessage) == null ? void 0 : v.message
|
|
3623
3724
|
};
|
|
3624
|
-
}), a =
|
|
3725
|
+
}), a = $(() => n.cacheIdentifier || n.preferencesStorageKey), s = $(() => {
|
|
3625
3726
|
const f = [];
|
|
3626
3727
|
return Object.keys(n.tableHeaders).forEach((b) => {
|
|
3627
3728
|
const H = n.tableHeaders[b];
|
|
@@ -3639,7 +3740,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3639
3740
|
"data-rowid": f.id,
|
|
3640
3741
|
"data-testid": f.name,
|
|
3641
3742
|
...n.rowAttributes(f)
|
|
3642
|
-
}), c =
|
|
3743
|
+
}), c = N({}), d = (f) => {
|
|
3643
3744
|
var v;
|
|
3644
3745
|
return (v = c.value) == null ? void 0 : v.$el.querySelector(`[data-rowid="${f.id}"]`);
|
|
3645
3746
|
}, u = (f) => {
|
|
@@ -3655,47 +3756,47 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3655
3756
|
}, p = (f) => {
|
|
3656
3757
|
C(f), i("state", f);
|
|
3657
3758
|
}, g = () => {
|
|
3658
|
-
i("empty-state-cta-clicked"),
|
|
3659
|
-
},
|
|
3759
|
+
i("empty-state-cta-clicked"), y();
|
|
3760
|
+
}, y = () => {
|
|
3660
3761
|
i("clear-search-input");
|
|
3661
|
-
}, x =
|
|
3762
|
+
}, x = $(() => n.disableRowClick ? void 0 : (f, v) => {
|
|
3662
3763
|
i("click:row", v);
|
|
3663
|
-
}),
|
|
3764
|
+
}), h = (f) => {
|
|
3664
3765
|
i("sort", f);
|
|
3665
|
-
}, { hideTableToolbar:
|
|
3666
|
-
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);
|
|
3667
3768
|
return {
|
|
3668
3769
|
...n.initialFetcherParams,
|
|
3669
3770
|
...f
|
|
3670
3771
|
};
|
|
3671
|
-
}),
|
|
3772
|
+
}), _ = (f) => {
|
|
3672
3773
|
X.value = f, s.value.forEach((v) => {
|
|
3673
3774
|
!("hidable" in v) || !X.value.columnVisibility || v.hidable === !1 && (X.value.columnVisibility[v.key] = !0);
|
|
3674
|
-
}), a.value &&
|
|
3675
|
-
}, O =
|
|
3775
|
+
}), a.value && E(a.value, f);
|
|
3776
|
+
}, O = $(() => ({
|
|
3676
3777
|
disablePageJump: n.disablePaginationPageJump,
|
|
3677
3778
|
offset: n.paginationType === "offset",
|
|
3678
3779
|
...n.paginationAttributes
|
|
3679
3780
|
}));
|
|
3680
3781
|
return (f, v) => {
|
|
3681
3782
|
const b = P("KTableData"), H = P("KCard");
|
|
3682
|
-
return m(),
|
|
3783
|
+
return m(), j(H, {
|
|
3683
3784
|
class: "kong-ui-entity-base-table",
|
|
3684
3785
|
title: e.title,
|
|
3685
3786
|
"title-tag": e.titleTag
|
|
3686
3787
|
}, {
|
|
3687
|
-
default:
|
|
3688
|
-
|
|
3788
|
+
default: k(() => [
|
|
3789
|
+
K(b, {
|
|
3689
3790
|
ref_key: "tableRefs",
|
|
3690
3791
|
ref: c,
|
|
3691
3792
|
"cache-identifier": a.value,
|
|
3692
3793
|
"cell-attrs": u,
|
|
3693
3794
|
"client-sort": e.enableClientSort,
|
|
3694
|
-
"empty-state-action-message": e.query ?
|
|
3795
|
+
"empty-state-action-message": e.query ? T(r)("baseTable.emptyState.noSearchResultsCtaText") : e.emptyStateOptions.ctaText,
|
|
3695
3796
|
"empty-state-action-route": e.query ? void 0 : e.emptyStateOptions.ctaPath,
|
|
3696
3797
|
"empty-state-icon-variant": e.query ? "search" : "kong",
|
|
3697
|
-
"empty-state-message": e.query ?
|
|
3698
|
-
"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,
|
|
3699
3800
|
error: o.value.hasError,
|
|
3700
3801
|
"error-state-message": o.value.message,
|
|
3701
3802
|
"error-state-title": o.value.title,
|
|
@@ -3704,7 +3805,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3704
3805
|
headers: s.value,
|
|
3705
3806
|
"hide-pagination": e.hidePagination,
|
|
3706
3807
|
"hide-pagination-when-optional": e.hidePaginationWhenOptional,
|
|
3707
|
-
"hide-toolbar": e.hideToolbar ??
|
|
3808
|
+
"hide-toolbar": e.hideToolbar ?? T(A),
|
|
3708
3809
|
"initial-fetcher-params": w.value,
|
|
3709
3810
|
loading: e.isLoading,
|
|
3710
3811
|
"pagination-attributes": O.value,
|
|
@@ -3717,81 +3818,74 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3717
3818
|
"table-preferences": X.value,
|
|
3718
3819
|
onEmptyStateActionClick: g,
|
|
3719
3820
|
"onRow:click": x.value,
|
|
3720
|
-
onSort: v[0] || (v[0] = (
|
|
3821
|
+
onSort: v[0] || (v[0] = (J) => h(J)),
|
|
3721
3822
|
onState: p,
|
|
3722
|
-
"onUpdate:tablePreferences":
|
|
3823
|
+
"onUpdate:tablePreferences": _
|
|
3723
3824
|
}, Se({
|
|
3724
|
-
toolbar:
|
|
3725
|
-
|
|
3726
|
-
|
|
3727
|
-
f.$slots["toolbar-button"] ? (m(), S("div",
|
|
3728
|
-
|
|
3729
|
-
])) :
|
|
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)
|
|
3730
3831
|
])
|
|
3731
3832
|
]),
|
|
3732
|
-
"action-items":
|
|
3733
|
-
|
|
3833
|
+
"action-items": k(({ row: J }) => [
|
|
3834
|
+
D(f.$slots, "actions", { row: J }, void 0, !0)
|
|
3734
3835
|
]),
|
|
3735
3836
|
_: 2
|
|
3736
3837
|
}, [
|
|
3737
3838
|
f.$slots["empty-state"] ? {
|
|
3738
3839
|
name: "empty-state",
|
|
3739
|
-
fn:
|
|
3740
|
-
|
|
3840
|
+
fn: k(() => [
|
|
3841
|
+
D(f.$slots, "empty-state", {}, void 0, !0)
|
|
3741
3842
|
]),
|
|
3742
3843
|
key: "0"
|
|
3743
3844
|
} : void 0,
|
|
3744
|
-
ce(e.tableHeaders, (
|
|
3845
|
+
ce(e.tableHeaders, (J, I) => ({
|
|
3745
3846
|
name: I,
|
|
3746
|
-
fn:
|
|
3747
|
-
|
|
3847
|
+
fn: k(({ row: R, rowValue: G }) => [
|
|
3848
|
+
K(nl, {
|
|
3748
3849
|
"key-name": String(I),
|
|
3749
|
-
"row-el": d(
|
|
3750
|
-
tooltip:
|
|
3850
|
+
"row-el": d(R),
|
|
3851
|
+
tooltip: J.tooltip
|
|
3751
3852
|
}, {
|
|
3752
|
-
default:
|
|
3753
|
-
|
|
3754
|
-
row:
|
|
3853
|
+
default: k(() => [
|
|
3854
|
+
D(f.$slots, I, {
|
|
3855
|
+
row: R,
|
|
3755
3856
|
rowKey: e.rowKey,
|
|
3756
3857
|
rowValue: G
|
|
3757
3858
|
}, () => [
|
|
3758
|
-
|
|
3859
|
+
U(L(G), 1)
|
|
3759
3860
|
], !0)
|
|
3760
3861
|
]),
|
|
3761
3862
|
_: 2
|
|
3762
3863
|
}, 1032, ["key-name", "row-el", "tooltip"])
|
|
3763
3864
|
])
|
|
3764
3865
|
})),
|
|
3765
|
-
f.$slots["bulk-actions"] ? {
|
|
3766
|
-
name: "bulk-actions",
|
|
3767
|
-
fn: _((Y) => [
|
|
3768
|
-
j(f.$slots, "bulk-actions", qt(Ht(Y)), void 0, !0)
|
|
3769
|
-
]),
|
|
3770
|
-
key: "1"
|
|
3771
|
-
} : void 0,
|
|
3772
3866
|
e.query ? void 0 : {
|
|
3773
3867
|
name: "empty-state-action-icon",
|
|
3774
|
-
fn:
|
|
3775
|
-
|
|
3868
|
+
fn: k(() => [
|
|
3869
|
+
K(T(Yt))
|
|
3776
3870
|
]),
|
|
3777
|
-
key: "
|
|
3871
|
+
key: "1"
|
|
3778
3872
|
}
|
|
3779
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"]),
|
|
3780
|
-
f.$slots["outside-actions"] &&
|
|
3781
|
-
|
|
3782
|
-
])) :
|
|
3874
|
+
f.$slots["outside-actions"] && T(A) ? (m(), S("div", al, [
|
|
3875
|
+
D(f.$slots, "outside-actions", {}, void 0, !0)
|
|
3876
|
+
])) : M("", !0)
|
|
3783
3877
|
]),
|
|
3784
3878
|
_: 3
|
|
3785
3879
|
}, 8, ["title", "title-tag"]);
|
|
3786
3880
|
};
|
|
3787
3881
|
}
|
|
3788
|
-
}),
|
|
3882
|
+
}), bs = /* @__PURE__ */ se(ol, [["__scopeId", "data-v-44153100"]]), ll = {
|
|
3789
3883
|
key: 0,
|
|
3790
3884
|
class: "kong-ui-entity-delete-error"
|
|
3791
|
-
},
|
|
3885
|
+
}, sl = {
|
|
3792
3886
|
key: 1,
|
|
3793
3887
|
class: "description"
|
|
3794
|
-
},
|
|
3888
|
+
}, cl = /* @__PURE__ */ z({
|
|
3795
3889
|
__name: "EntityDeleteModal",
|
|
3796
3890
|
props: {
|
|
3797
3891
|
visible: {
|
|
@@ -3830,14 +3924,14 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3830
3924
|
},
|
|
3831
3925
|
emits: ["cancel", "proceed"],
|
|
3832
3926
|
setup(e, { emit: t }) {
|
|
3833
|
-
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 = () => {
|
|
3834
3928
|
r("cancel");
|
|
3835
3929
|
}, s = () => {
|
|
3836
3930
|
r("proceed");
|
|
3837
3931
|
};
|
|
3838
3932
|
return (l, c) => {
|
|
3839
3933
|
const d = P("KAlert"), u = P("KPrompt");
|
|
3840
|
-
return m(),
|
|
3934
|
+
return m(), j(u, {
|
|
3841
3935
|
"action-button-appearance": "danger",
|
|
3842
3936
|
"action-button-disabled": e.actionPending,
|
|
3843
3937
|
"action-button-text": "Yes, delete",
|
|
@@ -3848,50 +3942,50 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3848
3942
|
onCancel: a,
|
|
3849
3943
|
onProceed: s
|
|
3850
3944
|
}, {
|
|
3851
|
-
default:
|
|
3852
|
-
e.error ? (m(), S("div",
|
|
3853
|
-
|
|
3854
|
-
default:
|
|
3855
|
-
|
|
3945
|
+
default: k(() => [
|
|
3946
|
+
e.error ? (m(), S("div", ll, [
|
|
3947
|
+
K(d, { appearance: "danger" }, {
|
|
3948
|
+
default: k(() => [
|
|
3949
|
+
U(L(e.error), 1)
|
|
3856
3950
|
]),
|
|
3857
3951
|
_: 1
|
|
3858
3952
|
})
|
|
3859
|
-
])) :
|
|
3860
|
-
|
|
3953
|
+
])) : M("", !0),
|
|
3954
|
+
K(T(n), {
|
|
3861
3955
|
class: "message",
|
|
3862
3956
|
keypath: i.entityName ? "deleteModal.messageWithName" : "deleteModal.message",
|
|
3863
3957
|
tag: "p"
|
|
3864
3958
|
}, Se({
|
|
3865
|
-
entityType:
|
|
3866
|
-
|
|
3959
|
+
entityType: k(() => [
|
|
3960
|
+
U(L(i.entityType), 1)
|
|
3867
3961
|
]),
|
|
3868
3962
|
_: 2
|
|
3869
3963
|
}, [
|
|
3870
3964
|
i.entityName ? {
|
|
3871
3965
|
name: "entityName",
|
|
3872
|
-
fn:
|
|
3873
|
-
|
|
3966
|
+
fn: k(() => [
|
|
3967
|
+
B("strong", null, L(i.entityName), 1)
|
|
3874
3968
|
]),
|
|
3875
3969
|
key: "0"
|
|
3876
3970
|
} : void 0
|
|
3877
3971
|
]), 1032, ["keypath"]),
|
|
3878
|
-
i.description || l.$slots.description ? (m(), S("div",
|
|
3879
|
-
|
|
3880
|
-
|
|
3972
|
+
i.description || l.$slots.description ? (m(), S("div", sl, [
|
|
3973
|
+
D(l.$slots, "description", {}, () => [
|
|
3974
|
+
B("p", null, L(i.description), 1)
|
|
3881
3975
|
], !0)
|
|
3882
|
-
])) :
|
|
3976
|
+
])) : M("", !0)
|
|
3883
3977
|
]),
|
|
3884
3978
|
_: 3
|
|
3885
3979
|
}, 8, ["action-button-disabled", "confirmation-text", "title", "visible"]);
|
|
3886
3980
|
};
|
|
3887
3981
|
}
|
|
3888
|
-
}),
|
|
3982
|
+
}), xs = /* @__PURE__ */ se(cl, [["__scopeId", "data-v-4361d622"]]), ul = {
|
|
3889
3983
|
fill: "none",
|
|
3890
3984
|
height: "20",
|
|
3891
3985
|
viewBox: "0 0 20 20",
|
|
3892
3986
|
width: "20",
|
|
3893
3987
|
xmlns: "http://www.w3.org/2000/svg"
|
|
3894
|
-
},
|
|
3988
|
+
}, dl = {
|
|
3895
3989
|
id: "mask0_180_20349",
|
|
3896
3990
|
height: "20",
|
|
3897
3991
|
maskUnits: "userSpaceOnUse",
|
|
@@ -3899,35 +3993,35 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3899
3993
|
width: "20",
|
|
3900
3994
|
x: "0",
|
|
3901
3995
|
y: "0"
|
|
3902
|
-
},
|
|
3996
|
+
}, fl = ["fill"], pl = { mask: "url(#mask0_180_20349)" }, ml = ["fill"], Mt = /* @__PURE__ */ z({
|
|
3903
3997
|
__name: "IconFilter",
|
|
3904
3998
|
props: {
|
|
3905
3999
|
color: {
|
|
3906
4000
|
type: String,
|
|
3907
|
-
default: `var(--kong-ui-entity-filter-color, ${
|
|
4001
|
+
default: `var(--kong-ui-entity-filter-color, ${Zi})`
|
|
3908
4002
|
}
|
|
3909
4003
|
},
|
|
3910
4004
|
setup(e) {
|
|
3911
|
-
return (t, n) => (m(), S("svg",
|
|
3912
|
-
|
|
3913
|
-
|
|
4005
|
+
return (t, n) => (m(), S("svg", ul, [
|
|
4006
|
+
B("mask", dl, [
|
|
4007
|
+
B("rect", {
|
|
3914
4008
|
fill: e.color,
|
|
3915
4009
|
height: "20",
|
|
3916
4010
|
width: "20"
|
|
3917
|
-
}, null, 8,
|
|
4011
|
+
}, null, 8, fl)
|
|
3918
4012
|
]),
|
|
3919
|
-
|
|
3920
|
-
|
|
4013
|
+
B("g", pl, [
|
|
4014
|
+
B("path", {
|
|
3921
4015
|
d: "M8 14.5V13H12V14.5H8ZM5 10.75V9.25H15V10.75H5ZM3 7V5.5H17V7H3Z",
|
|
3922
4016
|
fill: e.color
|
|
3923
|
-
}, null, 8,
|
|
4017
|
+
}, null, 8, ml)
|
|
3924
4018
|
])
|
|
3925
4019
|
]));
|
|
3926
4020
|
}
|
|
3927
|
-
}),
|
|
4021
|
+
}), yl = {
|
|
3928
4022
|
key: 1,
|
|
3929
4023
|
class: "kong-ui-entity-filter"
|
|
3930
|
-
},
|
|
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({
|
|
3931
4025
|
__name: "EntityFilter",
|
|
3932
4026
|
props: {
|
|
3933
4027
|
// filter config, either exact match or fuzzy match
|
|
@@ -3947,25 +4041,25 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3947
4041
|
},
|
|
3948
4042
|
emits: ["update:modelValue"],
|
|
3949
4043
|
setup(e, { emit: t }) {
|
|
3950
|
-
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 = $(() => {
|
|
3951
4045
|
const w = [];
|
|
3952
|
-
return new URLSearchParams(i.modelValue).forEach((
|
|
3953
|
-
|
|
4046
|
+
return new URLSearchParams(i.modelValue).forEach((_, O) => {
|
|
4047
|
+
_ !== "" && w.push(O);
|
|
3954
4048
|
}), w;
|
|
3955
|
-
}), c =
|
|
4049
|
+
}), c = $(() => {
|
|
3956
4050
|
const w = i.config.fields;
|
|
3957
|
-
return Object.keys(w).filter((
|
|
4051
|
+
return Object.keys(w).filter((_) => {
|
|
3958
4052
|
var O;
|
|
3959
|
-
return (O = w == null ? void 0 : w[
|
|
3960
|
-
}).map((
|
|
3961
|
-
label: w[
|
|
3962
|
-
value:
|
|
4053
|
+
return (O = w == null ? void 0 : w[_]) == null ? void 0 : O.searchable;
|
|
4054
|
+
}).map((_) => ({
|
|
4055
|
+
label: w[_].label || _,
|
|
4056
|
+
value: _,
|
|
3963
4057
|
expanded: !1
|
|
3964
4058
|
}));
|
|
3965
4059
|
});
|
|
3966
4060
|
be(() => i.modelValue, (w) => {
|
|
3967
|
-
a.value = {}, new URLSearchParams(w).forEach((
|
|
3968
|
-
a.value[O] =
|
|
4061
|
+
a.value = {}, new URLSearchParams(w).forEach((_, O) => {
|
|
4062
|
+
a.value[O] = _;
|
|
3969
4063
|
});
|
|
3970
4064
|
});
|
|
3971
4065
|
const d = () => {
|
|
@@ -3976,33 +4070,33 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
3976
4070
|
r("update:modelValue", w);
|
|
3977
4071
|
}, g = () => {
|
|
3978
4072
|
p("");
|
|
3979
|
-
},
|
|
3980
|
-
var
|
|
3981
|
-
return (((O = (
|
|
3982
|
-
},
|
|
3983
|
-
var
|
|
3984
|
-
return ((O = (
|
|
3985
|
-
},
|
|
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) => {
|
|
3986
4080
|
a.value = {
|
|
3987
4081
|
...a.value,
|
|
3988
4082
|
[w]: ""
|
|
3989
|
-
},
|
|
4083
|
+
}, E();
|
|
3990
4084
|
}, C = () => {
|
|
3991
|
-
a.value = {},
|
|
3992
|
-
},
|
|
3993
|
-
const
|
|
3994
|
-
w && (o.value = !1), r("update:modelValue", new URLSearchParams(
|
|
3995
|
-
},
|
|
3996
|
-
var
|
|
3997
|
-
return !!((O = (
|
|
3998
|
-
}, 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, _) => {
|
|
3999
4093
|
var f;
|
|
4000
4094
|
const O = (f = i.config.schema) == null ? void 0 : f[w];
|
|
4001
|
-
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(_);
|
|
4002
4096
|
};
|
|
4003
|
-
return (w,
|
|
4097
|
+
return (w, _) => {
|
|
4004
4098
|
const O = P("KInput"), f = P("KButton"), v = P("KSelect");
|
|
4005
|
-
return e.config.isExactMatch ? (m(),
|
|
4099
|
+
return e.config.isExactMatch ? (m(), j(O, {
|
|
4006
4100
|
key: 0,
|
|
4007
4101
|
autocomplete: "off",
|
|
4008
4102
|
class: "kong-ui-entity-filter-input",
|
|
@@ -4011,11 +4105,11 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4011
4105
|
placeholder: e.config.placeholder,
|
|
4012
4106
|
"onUpdate:modelValue": p
|
|
4013
4107
|
}, {
|
|
4014
|
-
before:
|
|
4015
|
-
|
|
4108
|
+
before: k(() => [
|
|
4109
|
+
K(Mt)
|
|
4016
4110
|
]),
|
|
4017
|
-
after:
|
|
4018
|
-
xe(
|
|
4111
|
+
after: k(() => [
|
|
4112
|
+
xe(K(T(oi), {
|
|
4019
4113
|
class: "kong-ui-entity-filter-clear",
|
|
4020
4114
|
role: "button",
|
|
4021
4115
|
tabindex: "0",
|
|
@@ -4025,110 +4119,110 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4025
4119
|
])
|
|
4026
4120
|
]),
|
|
4027
4121
|
_: 1
|
|
4028
|
-
}, 8, ["model-value", "placeholder"])) : (m(), S("div",
|
|
4029
|
-
|
|
4122
|
+
}, 8, ["model-value", "placeholder"])) : (m(), S("div", yl, [
|
|
4123
|
+
K(f, {
|
|
4030
4124
|
appearance: "tertiary",
|
|
4031
4125
|
"data-testid": "filter-button",
|
|
4032
4126
|
onClick: d
|
|
4033
4127
|
}, {
|
|
4034
|
-
default:
|
|
4035
|
-
|
|
4036
|
-
|
|
4128
|
+
default: k(() => [
|
|
4129
|
+
K(Mt),
|
|
4130
|
+
U(" " + L(T(n)("filter.filterButtonText")) + " " + L(l.value.length > 0 ? `(${l.value.length})` : ""), 1)
|
|
4037
4131
|
]),
|
|
4038
4132
|
_: 1
|
|
4039
4133
|
}),
|
|
4040
|
-
xe(
|
|
4134
|
+
xe(B("div", {
|
|
4041
4135
|
class: "kong-ui-entity-filter-backdrop",
|
|
4042
4136
|
onClick: d
|
|
4043
4137
|
}, null, 512), [
|
|
4044
4138
|
[Ce, o.value]
|
|
4045
4139
|
]),
|
|
4046
|
-
xe(
|
|
4140
|
+
xe(B("div", gl, [
|
|
4047
4141
|
(m(!0), S(ue, null, ce(c.value, (b) => {
|
|
4048
|
-
var H,
|
|
4142
|
+
var H, J;
|
|
4049
4143
|
return m(), S("div", {
|
|
4050
4144
|
key: b.value,
|
|
4051
4145
|
class: "kong-ui-entity-filter-menu-item",
|
|
4052
4146
|
"data-testid": b.value
|
|
4053
4147
|
}, [
|
|
4054
|
-
|
|
4148
|
+
B("span", {
|
|
4055
4149
|
class: fe(["menu-item-title", { expanded: s.value.has(b.value) }]),
|
|
4056
4150
|
role: "button",
|
|
4057
4151
|
tabindex: "0",
|
|
4058
4152
|
onClick: (I) => u(b.value),
|
|
4059
|
-
onKeydown:
|
|
4153
|
+
onKeydown: Xn((I) => u(b.value), ["enter"])
|
|
4060
4154
|
}, [
|
|
4061
|
-
|
|
4062
|
-
xe(
|
|
4155
|
+
U(L(b.label) + " ", 1),
|
|
4156
|
+
xe(B("span", bl, null, 512), [
|
|
4063
4157
|
[Ce, l.value.includes(b.value)]
|
|
4064
4158
|
]),
|
|
4065
|
-
|
|
4159
|
+
K(T(li), {
|
|
4066
4160
|
class: fe(["menu-item-expand-icon", { expanded: s.value.has(b.value) }]),
|
|
4067
|
-
color:
|
|
4161
|
+
color: T(er)
|
|
4068
4162
|
}, null, 8, ["class", "color"])
|
|
4069
|
-
], 42,
|
|
4070
|
-
xe(
|
|
4071
|
-
|
|
4163
|
+
], 42, vl),
|
|
4164
|
+
xe(B("div", xl, [
|
|
4165
|
+
B("label", {
|
|
4072
4166
|
class: "menu-item-label",
|
|
4073
|
-
for:
|
|
4074
|
-
}, L(
|
|
4075
|
-
((
|
|
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, {
|
|
4076
4170
|
key: 0,
|
|
4077
|
-
id:
|
|
4171
|
+
id: y(b.value),
|
|
4078
4172
|
modelValue: a.value[b.value],
|
|
4079
4173
|
"onUpdate:modelValue": (I) => a.value[b.value] = I,
|
|
4080
|
-
"enable-filtering":
|
|
4174
|
+
"enable-filtering": Y(b.value),
|
|
4081
4175
|
"filter-function": (I) => X(b.value, I),
|
|
4082
4176
|
items: x(b.value),
|
|
4083
|
-
placeholder:
|
|
4084
|
-
}, 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, {
|
|
4085
4179
|
key: 1,
|
|
4086
|
-
id:
|
|
4180
|
+
id: y(b.value),
|
|
4087
4181
|
modelValue: a.value[b.value],
|
|
4088
4182
|
"onUpdate:modelValue": (I) => a.value[b.value] = I,
|
|
4089
4183
|
autocomplete: "off",
|
|
4090
|
-
placeholder:
|
|
4091
|
-
type:
|
|
4184
|
+
placeholder: T(n)("filter.inputPlaceholder"),
|
|
4185
|
+
type: h(b.value)
|
|
4092
4186
|
}, null, 8, ["id", "modelValue", "onUpdate:modelValue", "placeholder", "type"]))
|
|
4093
4187
|
], 512), [
|
|
4094
4188
|
[Ce, s.value.has(b.value)]
|
|
4095
4189
|
]),
|
|
4096
|
-
xe(
|
|
4097
|
-
|
|
4190
|
+
xe(B("div", kl, [
|
|
4191
|
+
K(f, {
|
|
4098
4192
|
appearance: "tertiary",
|
|
4099
4193
|
"data-testid": "apply-filter",
|
|
4100
4194
|
size: "small",
|
|
4101
|
-
onClick:
|
|
4195
|
+
onClick: _[0] || (_[0] = (I) => E(!0))
|
|
4102
4196
|
}, {
|
|
4103
|
-
default:
|
|
4104
|
-
|
|
4197
|
+
default: k(() => [
|
|
4198
|
+
U(L(T(n)("filter.applyButtonText")), 1)
|
|
4105
4199
|
]),
|
|
4106
4200
|
_: 1
|
|
4107
4201
|
}),
|
|
4108
|
-
|
|
4202
|
+
K(f, {
|
|
4109
4203
|
appearance: "tertiary",
|
|
4110
4204
|
"data-testid": "clear-filter",
|
|
4111
4205
|
size: "small",
|
|
4112
|
-
onClick: (I) =>
|
|
4206
|
+
onClick: (I) => A(b.value)
|
|
4113
4207
|
}, {
|
|
4114
|
-
default:
|
|
4115
|
-
|
|
4208
|
+
default: k(() => [
|
|
4209
|
+
U(L(T(n)("filter.clearButtonText")), 1)
|
|
4116
4210
|
]),
|
|
4117
4211
|
_: 1
|
|
4118
4212
|
}, 8, ["onClick"])
|
|
4119
4213
|
], 512), [
|
|
4120
4214
|
[Ce, s.value.has(b.value)]
|
|
4121
4215
|
])
|
|
4122
|
-
], 8,
|
|
4216
|
+
], 8, hl);
|
|
4123
4217
|
}), 128)),
|
|
4124
|
-
|
|
4125
|
-
|
|
4218
|
+
B("div", Al, [
|
|
4219
|
+
K(f, {
|
|
4126
4220
|
appearance: "tertiary",
|
|
4127
4221
|
size: "small",
|
|
4128
4222
|
onClick: C
|
|
4129
4223
|
}, {
|
|
4130
|
-
default:
|
|
4131
|
-
|
|
4224
|
+
default: k(() => [
|
|
4225
|
+
U(L(T(n)("filter.clearAllButtonText")), 1)
|
|
4132
4226
|
]),
|
|
4133
4227
|
_: 1
|
|
4134
4228
|
})
|
|
@@ -4139,7 +4233,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4139
4233
|
]));
|
|
4140
4234
|
};
|
|
4141
4235
|
}
|
|
4142
|
-
}),
|
|
4236
|
+
}), Cs = /* @__PURE__ */ se(_l, [["__scopeId", "data-v-084f7978"]]), ks = /* @__PURE__ */ z({
|
|
4143
4237
|
__name: "EntityToggleModal",
|
|
4144
4238
|
props: {
|
|
4145
4239
|
visible: {
|
|
@@ -4171,9 +4265,9 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4171
4265
|
},
|
|
4172
4266
|
emits: ["cancel", "proceed"],
|
|
4173
4267
|
setup(e, { emit: t }) {
|
|
4174
|
-
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 = $(
|
|
4175
4269
|
() => r.action === "enable" ? n("toggleModal.enable.title", { entityType: r.entityType }) : n("toggleModal.disable.title", { entityType: r.entityType })
|
|
4176
|
-
), l =
|
|
4270
|
+
), l = $(
|
|
4177
4271
|
() => r.action === "enable" ? n("toggleModal.enable.confirmText") : n("toggleModal.disable.confirmText")
|
|
4178
4272
|
), c = () => o("cancel"), d = async () => {
|
|
4179
4273
|
if (r.onConfirm) {
|
|
@@ -4189,8 +4283,8 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4189
4283
|
};
|
|
4190
4284
|
return (u, p) => {
|
|
4191
4285
|
const g = P("KPrompt");
|
|
4192
|
-
return m(),
|
|
4193
|
-
|
|
4286
|
+
return m(), j(Ht, { to: "body" }, [
|
|
4287
|
+
K(g, {
|
|
4194
4288
|
"action-button-disabled": a.value,
|
|
4195
4289
|
"action-button-text": l.value,
|
|
4196
4290
|
"data-testid": `${e.entityType}-${e.entityId}-toggle-prompt`,
|
|
@@ -4199,16 +4293,16 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4199
4293
|
onCancel: c,
|
|
4200
4294
|
onProceed: d
|
|
4201
4295
|
}, {
|
|
4202
|
-
default:
|
|
4203
|
-
|
|
4296
|
+
default: k(() => [
|
|
4297
|
+
K(T(i), {
|
|
4204
4298
|
keypath: `toggleModal.${r.action}.message`,
|
|
4205
4299
|
scope: "global"
|
|
4206
4300
|
}, {
|
|
4207
|
-
entityType:
|
|
4208
|
-
|
|
4301
|
+
entityType: k(() => [
|
|
4302
|
+
U(L(e.entityType), 1)
|
|
4209
4303
|
]),
|
|
4210
|
-
entityName:
|
|
4211
|
-
|
|
4304
|
+
entityName: k(() => [
|
|
4305
|
+
B("strong", null, L(e.entityName), 1)
|
|
4212
4306
|
]),
|
|
4213
4307
|
_: 1
|
|
4214
4308
|
}, 8, ["keypath"])
|
|
@@ -4218,7 +4312,7 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4218
4312
|
]);
|
|
4219
4313
|
};
|
|
4220
4314
|
}
|
|
4221
|
-
}),
|
|
4315
|
+
}), As = /* @__PURE__ */ z({
|
|
4222
4316
|
__name: "PermissionsWrapper",
|
|
4223
4317
|
props: {
|
|
4224
4318
|
/**
|
|
@@ -4240,48 +4334,48 @@ const No = { class: "yaml-config config-card-code-block" }, Yn = /* @__PURE__ */
|
|
|
4240
4334
|
}
|
|
4241
4335
|
},
|
|
4242
4336
|
setup(e) {
|
|
4243
|
-
const t = e, n =
|
|
4337
|
+
const t = e, n = N(void 0), i = $(() => n.value === !0 || n.value !== void 0 && t.forceShow === !0);
|
|
4244
4338
|
return be(() => t.authFunction, async () => {
|
|
4245
4339
|
n.value = await t.authFunction();
|
|
4246
|
-
}, { immediate: !0 }), (r, o) => i.value ?
|
|
4340
|
+
}, { immediate: !0 }), (r, o) => i.value ? D(r.$slots, "default", {
|
|
4247
4341
|
key: 0,
|
|
4248
4342
|
isAllowed: n.value
|
|
4249
|
-
}) :
|
|
4343
|
+
}) : M("", !0);
|
|
4250
4344
|
}
|
|
4251
4345
|
}), te = [];
|
|
4252
4346
|
for (let e = 0; e < 256; ++e)
|
|
4253
4347
|
te.push((e + 256).toString(16).slice(1));
|
|
4254
|
-
function
|
|
4348
|
+
function wl(e, t = 0) {
|
|
4255
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();
|
|
4256
4350
|
}
|
|
4257
|
-
let
|
|
4258
|
-
const
|
|
4259
|
-
function
|
|
4260
|
-
if (!
|
|
4351
|
+
let Ge;
|
|
4352
|
+
const Sl = new Uint8Array(16);
|
|
4353
|
+
function $l() {
|
|
4354
|
+
if (!Ge) {
|
|
4261
4355
|
if (typeof crypto > "u" || !crypto.getRandomValues)
|
|
4262
4356
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
4263
|
-
|
|
4357
|
+
Ge = crypto.getRandomValues.bind(crypto);
|
|
4264
4358
|
}
|
|
4265
|
-
return
|
|
4359
|
+
return Ge(Sl);
|
|
4266
4360
|
}
|
|
4267
|
-
const
|
|
4268
|
-
function
|
|
4361
|
+
const Tl = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), jt = { randomUUID: Tl };
|
|
4362
|
+
function El(e, t, n) {
|
|
4269
4363
|
var r;
|
|
4270
4364
|
if (jt.randomUUID && !e)
|
|
4271
4365
|
return jt.randomUUID();
|
|
4272
4366
|
e = e || {};
|
|
4273
|
-
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();
|
|
4274
4368
|
if (i.length < 16)
|
|
4275
4369
|
throw new Error("Random bytes length must be >= 16");
|
|
4276
|
-
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);
|
|
4277
4371
|
}
|
|
4278
|
-
const
|
|
4372
|
+
const Il = ["aria-labelledby"], Fl = { class: "form-section-wrapper" }, Ol = {
|
|
4279
4373
|
key: 1,
|
|
4280
4374
|
class: "form-section-description"
|
|
4281
|
-
},
|
|
4375
|
+
}, Ll = {
|
|
4282
4376
|
key: 2,
|
|
4283
4377
|
class: "form-section-footer"
|
|
4284
|
-
},
|
|
4378
|
+
}, Bl = { class: "form-section-content" }, Rl = /* @__PURE__ */ z({
|
|
4285
4379
|
__name: "EntityFormSection",
|
|
4286
4380
|
props: {
|
|
4287
4381
|
title: {
|
|
@@ -4310,52 +4404,52 @@ const $l = ["aria-labelledby"], Tl = { class: "form-section-wrapper" }, Il = {
|
|
|
4310
4404
|
}
|
|
4311
4405
|
},
|
|
4312
4406
|
setup(e) {
|
|
4313
|
-
const t =
|
|
4407
|
+
const t = Pe(), n = El();
|
|
4314
4408
|
return (i, r) => (m(), S("div", {
|
|
4315
|
-
"aria-labelledby": e.title ?
|
|
4409
|
+
"aria-labelledby": e.title ? T(n) : void 0,
|
|
4316
4410
|
class: fe(["kong-ui-entity-form-section", { "has-divider": e.hasDivider }]),
|
|
4317
4411
|
role: "group"
|
|
4318
4412
|
}, [
|
|
4319
|
-
|
|
4320
|
-
e.hideInfoHeader ?
|
|
4413
|
+
B("div", Fl, [
|
|
4414
|
+
e.hideInfoHeader ? M("", !0) : (m(), S("div", {
|
|
4321
4415
|
key: 0,
|
|
4322
4416
|
class: fe(["form-section-info", { sticky: e.stickyInfoHeader }])
|
|
4323
4417
|
}, [
|
|
4324
|
-
e.title ? (m(),
|
|
4418
|
+
e.title ? (m(), j(De(e.titleTag), {
|
|
4325
4419
|
key: 0,
|
|
4326
|
-
id:
|
|
4420
|
+
id: T(n),
|
|
4327
4421
|
class: "form-section-title"
|
|
4328
4422
|
}, {
|
|
4329
|
-
default:
|
|
4330
|
-
|
|
4423
|
+
default: k(() => [
|
|
4424
|
+
U(L(e.title), 1)
|
|
4331
4425
|
]),
|
|
4332
4426
|
_: 1
|
|
4333
|
-
}, 8, ["id"])) :
|
|
4334
|
-
e.description ||
|
|
4335
|
-
|
|
4336
|
-
|
|
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)
|
|
4337
4431
|
], !0)
|
|
4338
|
-
])) :
|
|
4339
|
-
|
|
4340
|
-
|
|
4341
|
-
])) :
|
|
4432
|
+
])) : M("", !0),
|
|
4433
|
+
T(t).footer ? (m(), S("div", Ll, [
|
|
4434
|
+
D(i.$slots, "footer", {}, void 0, !0)
|
|
4435
|
+
])) : M("", !0)
|
|
4342
4436
|
], 2)),
|
|
4343
|
-
|
|
4344
|
-
|
|
4437
|
+
B("div", Bl, [
|
|
4438
|
+
D(i.$slots, "default", {}, void 0, !0)
|
|
4345
4439
|
])
|
|
4346
4440
|
])
|
|
4347
|
-
], 10,
|
|
4441
|
+
], 10, Il));
|
|
4348
4442
|
}
|
|
4349
|
-
}),
|
|
4443
|
+
}), _s = /* @__PURE__ */ se(Rl, [["__scopeId", "data-v-b1f74200"]]), Kl = { class: "ff-form-section" }, Nl = { class: "header" }, Ml = {
|
|
4350
4444
|
key: 0,
|
|
4351
4445
|
class: "step"
|
|
4352
|
-
},
|
|
4446
|
+
}, jl = { class: "header-content" }, Dl = { class: "header-title" }, Pl = {
|
|
4353
4447
|
key: 0,
|
|
4354
4448
|
class: "header-description"
|
|
4355
|
-
},
|
|
4449
|
+
}, Ul = {
|
|
4356
4450
|
key: 1,
|
|
4357
4451
|
class: "header-extra"
|
|
4358
|
-
},
|
|
4452
|
+
}, ql = { class: "content" }, Hl = /* @__PURE__ */ z({
|
|
4359
4453
|
__name: "EntityFormBlock",
|
|
4360
4454
|
props: {
|
|
4361
4455
|
step: {},
|
|
@@ -4363,38 +4457,38 @@ const $l = ["aria-labelledby"], Tl = { class: "form-section-wrapper" }, Il = {
|
|
|
4363
4457
|
description: { default: "" }
|
|
4364
4458
|
},
|
|
4365
4459
|
setup(e) {
|
|
4366
|
-
const t =
|
|
4367
|
-
return (n, i) => (m(), S("div",
|
|
4368
|
-
|
|
4369
|
-
e.step != null ? (m(), S("div",
|
|
4370
|
-
|
|
4371
|
-
|
|
4372
|
-
|
|
4373
|
-
|
|
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)
|
|
4374
4468
|
], !0)
|
|
4375
4469
|
]),
|
|
4376
|
-
e.description || t.description ? (m(), S("div",
|
|
4377
|
-
|
|
4378
|
-
|
|
4470
|
+
e.description || t.description ? (m(), S("div", Pl, [
|
|
4471
|
+
D(n.$slots, "description", {}, () => [
|
|
4472
|
+
U(L(e.description), 1)
|
|
4379
4473
|
], !0)
|
|
4380
|
-
])) :
|
|
4474
|
+
])) : M("", !0)
|
|
4381
4475
|
]),
|
|
4382
|
-
t.extra ? (m(), S("div",
|
|
4383
|
-
|
|
4384
|
-
])) :
|
|
4476
|
+
t.extra ? (m(), S("div", Ul, [
|
|
4477
|
+
D(n.$slots, "extra", {}, void 0, !0)
|
|
4478
|
+
])) : M("", !0)
|
|
4385
4479
|
]),
|
|
4386
|
-
|
|
4387
|
-
|
|
4480
|
+
B("div", ql, [
|
|
4481
|
+
D(n.$slots, "default", {}, void 0, !0)
|
|
4388
4482
|
])
|
|
4389
4483
|
]));
|
|
4390
4484
|
}
|
|
4391
|
-
}),
|
|
4485
|
+
}), ws = /* @__PURE__ */ se(Hl, [["__scopeId", "data-v-cb6d2e95"]]), Vl = {
|
|
4392
4486
|
class: "kong-ui-public-entity-link",
|
|
4393
4487
|
"data-testid": "entity-link-parent"
|
|
4394
|
-
},
|
|
4488
|
+
}, Yl = {
|
|
4395
4489
|
key: 0,
|
|
4396
4490
|
class: "deleted-entity"
|
|
4397
|
-
},
|
|
4491
|
+
}, Wl = { key: 1 }, Jl = ["onClick"], Gl = /* @__PURE__ */ z({
|
|
4398
4492
|
__name: "EntityLink",
|
|
4399
4493
|
props: {
|
|
4400
4494
|
entityLinkData: {
|
|
@@ -4418,10 +4512,10 @@ const $l = ["aria-labelledby"], Tl = { class: "form-section-wrapper" }, Il = {
|
|
|
4418
4512
|
}
|
|
4419
4513
|
},
|
|
4420
4514
|
setup(e) {
|
|
4421
|
-
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 = $(() => {
|
|
4422
4516
|
var u;
|
|
4423
4517
|
return (u = t.entityLinkData.id) != null && u.toString().includes(":") ? t.entityLinkData.id.toString().split(":")[1] : t.entityLinkData.id;
|
|
4424
|
-
}), c =
|
|
4518
|
+
}), c = $(() => {
|
|
4425
4519
|
var u;
|
|
4426
4520
|
return `${(u = l.value) == null ? void 0 : u.toString().slice(0, 5)} (deleted)`;
|
|
4427
4521
|
}), d = async (u) => {
|
|
@@ -4430,21 +4524,21 @@ const $l = ["aria-labelledby"], Tl = { class: "form-section-wrapper" }, Il = {
|
|
|
4430
4524
|
}, 1800));
|
|
4431
4525
|
};
|
|
4432
4526
|
return (u, p) => {
|
|
4433
|
-
const g = P("KTooltip"),
|
|
4434
|
-
return m(), S("div",
|
|
4435
|
-
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, {
|
|
4436
4530
|
key: 2,
|
|
4437
4531
|
class: "entity-link",
|
|
4438
4532
|
"hide-icon": !e.newWindow,
|
|
4439
4533
|
href: e.externalLink,
|
|
4440
4534
|
target: e.newWindow ? "_blank" : "_self"
|
|
4441
4535
|
}, {
|
|
4442
|
-
default:
|
|
4443
|
-
|
|
4444
|
-
text:
|
|
4536
|
+
default: k(() => [
|
|
4537
|
+
K(g, {
|
|
4538
|
+
text: T(i) && e.entityLinkData.label || ""
|
|
4445
4539
|
}, {
|
|
4446
|
-
default:
|
|
4447
|
-
|
|
4540
|
+
default: k(() => [
|
|
4541
|
+
B("span", {
|
|
4448
4542
|
ref_key: "textContent",
|
|
4449
4543
|
ref: n,
|
|
4450
4544
|
class: "entity-link-label"
|
|
@@ -4454,71 +4548,71 @@ const $l = ["aria-labelledby"], Tl = { class: "form-section-wrapper" }, Il = {
|
|
|
4454
4548
|
}, 8, ["text"])
|
|
4455
4549
|
]),
|
|
4456
4550
|
_: 1
|
|
4457
|
-
}, 8, ["hide-icon", "href", "target"])) :
|
|
4458
|
-
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, {
|
|
4459
4553
|
key: a.value,
|
|
4460
4554
|
class: "copy-uuid-tooltip",
|
|
4461
4555
|
"max-width": "160",
|
|
4462
4556
|
placement: "bottom-end",
|
|
4463
4557
|
text: a.value
|
|
4464
4558
|
}, {
|
|
4465
|
-
default:
|
|
4466
|
-
|
|
4467
|
-
default:
|
|
4468
|
-
|
|
4559
|
+
default: k(() => [
|
|
4560
|
+
K(x, null, {
|
|
4561
|
+
default: k(({ copyToClipboard: h }) => [
|
|
4562
|
+
B("span", {
|
|
4469
4563
|
class: "entity-link-copy-id",
|
|
4470
|
-
onClick:
|
|
4564
|
+
onClick: Be((A) => d(h), ["stop"])
|
|
4471
4565
|
}, [
|
|
4472
|
-
|
|
4566
|
+
K(T(si), {
|
|
4473
4567
|
class: "copy-icon",
|
|
4474
|
-
color:
|
|
4568
|
+
color: T(tr),
|
|
4475
4569
|
"data-testid": "copy-id",
|
|
4476
|
-
size:
|
|
4570
|
+
size: T(ir)
|
|
4477
4571
|
}, null, 8, ["color", "size"])
|
|
4478
|
-
], 8,
|
|
4572
|
+
], 8, Jl)
|
|
4479
4573
|
]),
|
|
4480
4574
|
_: 1
|
|
4481
4575
|
})
|
|
4482
4576
|
]),
|
|
4483
4577
|
_: 1
|
|
4484
|
-
}, 8, ["text"])) :
|
|
4578
|
+
}, 8, ["text"])) : M("", !0)
|
|
4485
4579
|
]);
|
|
4486
4580
|
};
|
|
4487
4581
|
}
|
|
4488
|
-
}),
|
|
4582
|
+
}), Ss = /* @__PURE__ */ se(Gl, [["__scopeId", "data-v-96efdfa5"]]), zl = { class: "kong-ui-public-entity-empty-state" }, Ql = { class: "entity-empty-state-content" }, Zl = {
|
|
4489
4583
|
key: 0,
|
|
4490
4584
|
class: "empty-state-image"
|
|
4491
|
-
},
|
|
4585
|
+
}, Xl = {
|
|
4492
4586
|
key: 1,
|
|
4493
4587
|
class: "entity-empty-state-title"
|
|
4494
|
-
},
|
|
4588
|
+
}, es = {
|
|
4495
4589
|
key: 2,
|
|
4496
4590
|
class: "entity-empty-state-description"
|
|
4497
|
-
},
|
|
4591
|
+
}, ts = {
|
|
4498
4592
|
key: 3,
|
|
4499
4593
|
class: "entity-empty-state-pricing"
|
|
4500
|
-
},
|
|
4594
|
+
}, ns = {
|
|
4501
4595
|
key: 0,
|
|
4502
4596
|
class: "entity-empty-state-message"
|
|
4503
|
-
},
|
|
4597
|
+
}, is = {
|
|
4504
4598
|
key: 1,
|
|
4505
4599
|
class: "entity-empty-state-action"
|
|
4506
|
-
},
|
|
4600
|
+
}, rs = {
|
|
4507
4601
|
key: 2,
|
|
4508
4602
|
class: "entity-empty-state-card-container"
|
|
4509
|
-
},
|
|
4603
|
+
}, as = {
|
|
4510
4604
|
key: 0,
|
|
4511
4605
|
class: "feature-icon"
|
|
4512
|
-
},
|
|
4606
|
+
}, os = { class: "card-header" }, ls = ["title"], ss = {
|
|
4513
4607
|
key: 3,
|
|
4514
4608
|
class: "entity-empty-state-bottom-container"
|
|
4515
|
-
},
|
|
4609
|
+
}, cs = /* @__PURE__ */ z({
|
|
4516
4610
|
__name: "EntityEmptyState",
|
|
4517
4611
|
props: {
|
|
4518
4612
|
appearance: {
|
|
4519
4613
|
type: String,
|
|
4520
4614
|
default: () => "primary",
|
|
4521
|
-
validator: (e) =>
|
|
4615
|
+
validator: (e) => yt.includes(e)
|
|
4522
4616
|
},
|
|
4523
4617
|
title: {
|
|
4524
4618
|
type: String,
|
|
@@ -4553,100 +4647,100 @@ const $l = ["aria-labelledby"], Tl = { class: "form-section-wrapper" }, Il = {
|
|
|
4553
4647
|
},
|
|
4554
4648
|
emits: ["click:create", "click:learn-more"],
|
|
4555
4649
|
setup(e) {
|
|
4556
|
-
const t = e, { i18n: { t: n } } = W.useI18n(), i =
|
|
4557
|
-
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 () => {
|
|
4558
4652
|
i.value = await t.canCreate();
|
|
4559
|
-
}),
|
|
4653
|
+
}), nt(() => ei(`EntityEmptyState is deprecated and will be removed in future releases. Please use the KEmptyState component instead.
|
|
4560
4654
|
Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) => {
|
|
4561
4655
|
const l = P("KCard");
|
|
4562
|
-
return m(), S("div",
|
|
4563
|
-
|
|
4564
|
-
a.$slots.image ? (m(), S("div",
|
|
4565
|
-
|
|
4566
|
-
])) :
|
|
4567
|
-
e.title || a.$slots.title ? (m(), S("div",
|
|
4568
|
-
|
|
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", {
|
|
4569
4663
|
class: fe(o.value)
|
|
4570
4664
|
}, [
|
|
4571
|
-
|
|
4572
|
-
|
|
4665
|
+
D(a.$slots, "title", {}, () => [
|
|
4666
|
+
U(L(e.title), 1)
|
|
4573
4667
|
], !0)
|
|
4574
4668
|
], 2)
|
|
4575
|
-
])) :
|
|
4576
|
-
e.description || a.$slots.default ? (m(), S("div",
|
|
4577
|
-
|
|
4578
|
-
|
|
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)
|
|
4579
4673
|
], !0)
|
|
4580
|
-
])) :
|
|
4581
|
-
e.pricing || a.$slots.pricing ? (m(), S("div",
|
|
4582
|
-
|
|
4583
|
-
|
|
4584
|
-
s[2] || (s[2] =
|
|
4585
|
-
|
|
4586
|
-
|
|
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)
|
|
4587
4681
|
], !0)
|
|
4588
4682
|
])
|
|
4589
|
-
])) :
|
|
4683
|
+
])) : M("", !0)
|
|
4590
4684
|
]),
|
|
4591
|
-
a.$slots.message ? (m(), S("div",
|
|
4592
|
-
|
|
4593
|
-
])) :
|
|
4594
|
-
r.value || e.learnMore || a.$slots.actions ? (m(), S("div",
|
|
4595
|
-
|
|
4596
|
-
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), {
|
|
4597
4691
|
key: 0,
|
|
4598
4692
|
appearance: "primary",
|
|
4599
4693
|
"data-testid": "entity-create-button",
|
|
4600
4694
|
size: e.appearance === "secondary" ? "medium" : "large",
|
|
4601
4695
|
onClick: s[0] || (s[0] = (c) => a.$emit("click:create"))
|
|
4602
4696
|
}, {
|
|
4603
|
-
default:
|
|
4604
|
-
|
|
4605
|
-
|
|
4697
|
+
default: k(() => [
|
|
4698
|
+
K(T(Yt)),
|
|
4699
|
+
U(" " + L(e.actionButtonText), 1)
|
|
4606
4700
|
]),
|
|
4607
4701
|
_: 1
|
|
4608
|
-
}, 8, ["size"])) :
|
|
4609
|
-
e.learnMore ? (m(),
|
|
4702
|
+
}, 8, ["size"])) : M("", !0),
|
|
4703
|
+
e.learnMore ? (m(), j(T(mt), {
|
|
4610
4704
|
key: 1,
|
|
4611
4705
|
appearance: "secondary",
|
|
4612
4706
|
"data-testid": "entity-learn-more-button",
|
|
4613
4707
|
size: e.appearance === "secondary" ? "medium" : "large",
|
|
4614
4708
|
onClick: s[1] || (s[1] = (c) => a.$emit("click:learn-more"))
|
|
4615
4709
|
}, {
|
|
4616
|
-
default:
|
|
4617
|
-
|
|
4618
|
-
|
|
4710
|
+
default: k(() => [
|
|
4711
|
+
K(T(Vt), { decorative: "" }),
|
|
4712
|
+
U(" " + L(T(n)("emptyState.learnMore")), 1)
|
|
4619
4713
|
]),
|
|
4620
4714
|
_: 1
|
|
4621
|
-
}, 8, ["size"])) :
|
|
4715
|
+
}, 8, ["size"])) : M("", !0)
|
|
4622
4716
|
], !0)
|
|
4623
|
-
])) :
|
|
4624
|
-
e.features.length ? (m(), S("div",
|
|
4625
|
-
(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, {
|
|
4626
4720
|
key: c,
|
|
4627
4721
|
class: "entity-empty-state-card"
|
|
4628
4722
|
}, {
|
|
4629
|
-
title:
|
|
4630
|
-
a.$slots[`feature-${d}-icon`] ? (m(), S("div",
|
|
4631
|
-
|
|
4632
|
-
])) :
|
|
4633
|
-
|
|
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)
|
|
4634
4728
|
]),
|
|
4635
|
-
default:
|
|
4636
|
-
|
|
4729
|
+
default: k(() => [
|
|
4730
|
+
B("div", {
|
|
4637
4731
|
title: c.description
|
|
4638
|
-
}, L(c.description), 9,
|
|
4732
|
+
}, L(c.description), 9, ls)
|
|
4639
4733
|
]),
|
|
4640
4734
|
_: 2
|
|
4641
4735
|
}, 1024))), 128))
|
|
4642
|
-
])) :
|
|
4643
|
-
a.$slots.bottom ? (m(), S("div",
|
|
4644
|
-
|
|
4645
|
-
])) :
|
|
4736
|
+
])) : M("", !0),
|
|
4737
|
+
a.$slots.bottom ? (m(), S("div", ss, [
|
|
4738
|
+
D(a.$slots, "bottom", {}, void 0, !0)
|
|
4739
|
+
])) : M("", !0)
|
|
4646
4740
|
]);
|
|
4647
4741
|
};
|
|
4648
4742
|
}
|
|
4649
|
-
}),
|
|
4743
|
+
}), $s = /* @__PURE__ */ se(cs, [["__scopeId", "data-v-645aae54"]]), us = { key: 1 }, Ts = /* @__PURE__ */ z({
|
|
4650
4744
|
__name: "TableTags",
|
|
4651
4745
|
props: {
|
|
4652
4746
|
/** The tags to display in the table */
|
|
@@ -4660,7 +4754,7 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4660
4754
|
}
|
|
4661
4755
|
},
|
|
4662
4756
|
setup(e) {
|
|
4663
|
-
const t = e, n =
|
|
4757
|
+
const t = e, n = $(() => {
|
|
4664
4758
|
if (Array.isArray(t.tags))
|
|
4665
4759
|
return t.tags;
|
|
4666
4760
|
if (typeof t.tags == "string")
|
|
@@ -4674,66 +4768,68 @@ Docs: https://kongponents.konghq.com/components/empty-state.html.`)), (a, s) =>
|
|
|
4674
4768
|
});
|
|
4675
4769
|
return (i, r) => {
|
|
4676
4770
|
var o;
|
|
4677
|
-
return ((o = n.value) == null ? void 0 : o.length) > 0 ? (m(),
|
|
4678
|
-
default:
|
|
4679
|
-
(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), {
|
|
4680
4774
|
key: a,
|
|
4681
4775
|
"max-width": e.tagMaxWidth,
|
|
4682
|
-
onClick: r[0] || (r[0] =
|
|
4776
|
+
onClick: r[0] || (r[0] = Be(() => {
|
|
4683
4777
|
}, ["stop"]))
|
|
4684
4778
|
}, {
|
|
4685
|
-
default:
|
|
4686
|
-
|
|
4779
|
+
default: k(() => [
|
|
4780
|
+
U(L(a), 1)
|
|
4687
4781
|
]),
|
|
4688
4782
|
_: 2
|
|
4689
4783
|
}, 1032, ["max-width"]))), 128))
|
|
4690
4784
|
]),
|
|
4691
4785
|
_: 1
|
|
4692
|
-
})) : (m(), S("span",
|
|
4786
|
+
})) : (m(), S("span", us, "-"));
|
|
4693
4787
|
};
|
|
4694
4788
|
}
|
|
4695
|
-
}), { 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;
|
|
4696
4790
|
export {
|
|
4697
|
-
|
|
4698
|
-
|
|
4699
|
-
|
|
4791
|
+
yt as Appearances,
|
|
4792
|
+
Yo as ConfigCardDisplay,
|
|
4793
|
+
Xt as ConfigCardItem,
|
|
4700
4794
|
ae as ConfigurationSchemaSection,
|
|
4701
4795
|
V as ConfigurationSchemaType,
|
|
4702
|
-
|
|
4703
|
-
hs as
|
|
4704
|
-
|
|
4705
|
-
|
|
4706
|
-
|
|
4707
|
-
|
|
4708
|
-
|
|
4709
|
-
|
|
4710
|
-
|
|
4711
|
-
|
|
4712
|
-
|
|
4713
|
-
|
|
4714
|
-
ui as
|
|
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,
|
|
4715
4810
|
me as FetcherStatus,
|
|
4716
|
-
|
|
4717
|
-
|
|
4718
|
-
|
|
4719
|
-
|
|
4720
|
-
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
Yn as
|
|
4724
|
-
|
|
4725
|
-
|
|
4726
|
-
|
|
4727
|
-
|
|
4728
|
-
|
|
4729
|
-
|
|
4730
|
-
|
|
4731
|
-
|
|
4732
|
-
|
|
4733
|
-
|
|
4734
|
-
|
|
4735
|
-
|
|
4736
|
-
|
|
4737
|
-
|
|
4738
|
-
|
|
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,
|
|
4818
|
+
Yn as TerraformCodeBlock,
|
|
4819
|
+
Vn as YamlCodeBlock,
|
|
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
|
|
4739
4835
|
};
|