@kong-ui-public/entities-plugins 7.1.3 → 7.1.4
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-plugins.es.js +81 -83
- package/dist/entities-plugins.umd.js +3 -3
- package/dist/style.css +1 -1
- package/package.json +6 -6
|
@@ -10,7 +10,7 @@ var Gi = (e, t, n) => {
|
|
|
10
10
|
t instanceof WeakSet ? t.add(e) : t.set(e, n);
|
|
11
11
|
};
|
|
12
12
|
var ri = (e, t, n) => (Vl(e, t, "access private method"), n);
|
|
13
|
-
import { defineComponent as ue, useCssVars as Es, computed as j, resolveComponent as H, openBlock as g, createElementBlock as w, createVNode as x, withCtx as b, createTextVNode as re, toDisplayString as U, createCommentVNode as J, createBlock as P, normalizeClass as ge, ref as q, Teleport as pa, unref as v, createElementVNode as y, watch as rt, renderSlot as Se, onBeforeMount as Ft, createSlots as ct, renderList as de, resolveDynamicComponent as
|
|
13
|
+
import { defineComponent as ue, useCssVars as Es, computed as j, resolveComponent as H, openBlock as g, createElementBlock as w, createVNode as x, withCtx as b, createTextVNode as re, toDisplayString as U, createCommentVNode as J, createBlock as P, normalizeClass as ge, ref as q, Teleport as pa, unref as v, createElementVNode as y, watch as rt, renderSlot as Se, onBeforeMount as Ft, createSlots as ct, renderList as de, resolveDynamicComponent as Le, withModifiers as Gt, withDirectives as ve, vShow as Bt, Fragment as oe, withKeys as Fl, inject as zl, useSlots as ks, onMounted as Ii, onUnmounted as Kl, normalizeStyle as Ot, normalizeProps as ql, guardReactiveProps as Xl, mergeProps as St, pushScopeId as Ke, popScopeId as qe, nextTick as Qa, toRefs as Os, resolveDirective as Jn, vModelSelect as Is, Transition as Jl, vModelText as Wt, vModelCheckbox as ga, vModelDynamic as Zl, vModelRadio as Wl, provide as Ql, reactive as xn, mergeModels as _a, useModel as _l } from "vue";
|
|
14
14
|
import $a from "axios";
|
|
15
15
|
import { createI18n as Zn, i18nTComponent as Ms } from "@kong-ui-public/i18n";
|
|
16
16
|
import { BadgeMethodAppearances as $l } from "@kong/kongponents";
|
|
@@ -560,7 +560,7 @@ const Ge = {
|
|
|
560
560
|
var l;
|
|
561
561
|
return t.isArrayItem ? (l = r.value) != null && l.name ? i(r.value.name, "_") : n("baseConfigCard.general.entryTitle", { index: t.index }) : "";
|
|
562
562
|
});
|
|
563
|
-
return (l, u) => (g(), P(
|
|
563
|
+
return (l, u) => (g(), P(Le(e.isArrayItem ? "fieldset" : "div"), {
|
|
564
564
|
class: ge(e.isArrayItem ? "config-card-fieldset" : "config-card-json-item")
|
|
565
565
|
}, {
|
|
566
566
|
default: b(() => [
|
|
@@ -811,7 +811,7 @@ const Ge = {
|
|
|
811
811
|
rowValue: e.item.value
|
|
812
812
|
}, () => [
|
|
813
813
|
o.value ? (g(), w("div", zu, [
|
|
814
|
-
(g(), P(
|
|
814
|
+
(g(), P(Le(p.value.tag), ql(Xl(p.value.attrs)), {
|
|
815
815
|
default: b(() => [
|
|
816
816
|
p.value.additionalComponent === "KBadge" ? (g(), w("div", {
|
|
817
817
|
key: 0,
|
|
@@ -924,7 +924,7 @@ const Ge = {
|
|
|
924
924
|
},
|
|
925
925
|
setup(e) {
|
|
926
926
|
Es((a) => ({
|
|
927
|
-
"
|
|
927
|
+
"090794fe": `${i.value}ch`
|
|
928
928
|
}));
|
|
929
929
|
const t = e, n = j(() => t.jsonRecord), i = j(() => {
|
|
930
930
|
var a;
|
|
@@ -2536,7 +2536,7 @@ const vp = { class: "yaml-config" }, Ea = /* @__PURE__ */ ue({
|
|
|
2536
2536
|
lineHeight: "0",
|
|
2537
2537
|
width: n.value
|
|
2538
2538
|
}));
|
|
2539
|
-
return (a, r) => (g(), P(
|
|
2539
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
2540
2540
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2541
2541
|
class: "kui-icon add-icon",
|
|
2542
2542
|
"data-testid": "kui-icon-wrapper-add-icon",
|
|
@@ -2635,7 +2635,7 @@ const vp = { class: "yaml-config" }, Ea = /* @__PURE__ */ ue({
|
|
|
2635
2635
|
lineHeight: "0",
|
|
2636
2636
|
width: n.value
|
|
2637
2637
|
}));
|
|
2638
|
-
return (a, r) => (g(), P(
|
|
2638
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
2639
2639
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2640
2640
|
class: "kui-icon book-icon",
|
|
2641
2641
|
"data-testid": "kui-icon-wrapper-book-icon",
|
|
@@ -2734,7 +2734,7 @@ const vp = { class: "yaml-config" }, Ea = /* @__PURE__ */ ue({
|
|
|
2734
2734
|
lineHeight: "0",
|
|
2735
2735
|
width: n.value
|
|
2736
2736
|
}));
|
|
2737
|
-
return (a, r) => (g(), P(
|
|
2737
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
2738
2738
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2739
2739
|
class: "kui-icon chevron-down-icon",
|
|
2740
2740
|
"data-testid": "kui-icon-wrapper-chevron-down-icon",
|
|
@@ -2833,7 +2833,7 @@ const vp = { class: "yaml-config" }, Ea = /* @__PURE__ */ ue({
|
|
|
2833
2833
|
lineHeight: "0",
|
|
2834
2834
|
width: n.value
|
|
2835
2835
|
}));
|
|
2836
|
-
return (a, r) => (g(), P(
|
|
2836
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
2837
2837
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2838
2838
|
class: "kui-icon close-icon",
|
|
2839
2839
|
"data-testid": "kui-icon-wrapper-close-icon",
|
|
@@ -2932,7 +2932,7 @@ const vp = { class: "yaml-config" }, Ea = /* @__PURE__ */ ue({
|
|
|
2932
2932
|
lineHeight: "0",
|
|
2933
2933
|
width: n.value
|
|
2934
2934
|
}));
|
|
2935
|
-
return (a, r) => (g(), P(
|
|
2935
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
2936
2936
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
2937
2937
|
class: "kui-icon more-icon",
|
|
2938
2938
|
"data-testid": "kui-icon-wrapper-more-icon",
|
|
@@ -3380,7 +3380,7 @@ const vp = { class: "yaml-config" }, Ea = /* @__PURE__ */ ue({
|
|
|
3380
3380
|
}
|
|
3381
3381
|
}), (E, A) => {
|
|
3382
3382
|
const f = H("KSkeleton"), B = H("KEmptyState"), S = H("KAlert"), k = H("KButton"), D = H("KTabs"), N = H("KSlideout");
|
|
3383
|
-
return g(), P(
|
|
3383
|
+
return g(), P(Le(e.wrapperComponent), { class: "kong-ui-entity-base-form" }, {
|
|
3384
3384
|
default: b(() => [
|
|
3385
3385
|
u.value ? (g(), P(f, {
|
|
3386
3386
|
key: 0,
|
|
@@ -9085,9 +9085,9 @@ const Ze = {
|
|
|
9085
9085
|
invalidTextContainSpec: "Invalid text! Cannot contains special characters"
|
|
9086
9086
|
};
|
|
9087
9087
|
function ut(e, t, n = Ze) {
|
|
9088
|
-
return Pe(e) || e === "" ? t ? [
|
|
9088
|
+
return Pe(e) || e === "" ? t ? [Te(n.fieldIsRequired)] : [] : null;
|
|
9089
9089
|
}
|
|
9090
|
-
function
|
|
9090
|
+
function Te(e, ...t) {
|
|
9091
9091
|
if (e != null && t.length > 0)
|
|
9092
9092
|
for (let n = 0; n < t.length; n++)
|
|
9093
9093
|
e = e.replace("{" + (n - 1) + "}", t[n]);
|
|
@@ -9103,41 +9103,41 @@ const nn = {
|
|
|
9103
9103
|
if (a != null)
|
|
9104
9104
|
return a;
|
|
9105
9105
|
const r = [];
|
|
9106
|
-
return v1(e) ? (!Pe(t.min) && e < t.min && r.push(
|
|
9106
|
+
return v1(e) ? (!Pe(t.min) && e < t.min && r.push(Te(i.numberTooSmall, t.min)), !Pe(t.max) && e > t.max && r.push(Te(i.numberTooBig, t.max))) : r.push(Te(i.invalidNumber)), r;
|
|
9107
9107
|
},
|
|
9108
9108
|
integer(e, t, n, i = Ze) {
|
|
9109
9109
|
const a = ut(e, t.required, i);
|
|
9110
9110
|
if (a != null)
|
|
9111
9111
|
return a;
|
|
9112
9112
|
const r = nn.number(e, t, n, i);
|
|
9113
|
-
return C1(e) || r.push(
|
|
9113
|
+
return C1(e) || r.push(Te(i.invalidInteger)), r;
|
|
9114
9114
|
},
|
|
9115
9115
|
double(e, t, n, i = Ze) {
|
|
9116
9116
|
const a = ut(e, t.required, i);
|
|
9117
9117
|
if (a != null)
|
|
9118
9118
|
return a;
|
|
9119
9119
|
if (!ca(e) || isNaN(e))
|
|
9120
|
-
return [
|
|
9120
|
+
return [Te(i.invalidNumber)];
|
|
9121
9121
|
},
|
|
9122
9122
|
string(e, t, n, i = Ze) {
|
|
9123
9123
|
const a = ut(e, t.required, i);
|
|
9124
9124
|
if (a != null)
|
|
9125
9125
|
return a;
|
|
9126
9126
|
const r = [];
|
|
9127
|
-
return en(e) ? (!Pe(t.min) && e.length < t.min && r.push(
|
|
9127
|
+
return en(e) ? (!Pe(t.min) && e.length < t.min && r.push(Te(i.textTooSmall, e.length, t.min)), !Pe(t.max) && e.length > t.max && r.push(Te(i.textTooBig, e.length, t.max))) : r.push(Te(i.thisNotText)), r;
|
|
9128
9128
|
},
|
|
9129
9129
|
array(e, t, n, i = Ze) {
|
|
9130
9130
|
if (t.required) {
|
|
9131
9131
|
if (!Array.isArray(e))
|
|
9132
|
-
return [
|
|
9132
|
+
return [Te(i.thisNotArray)];
|
|
9133
9133
|
if (e.length === 0)
|
|
9134
|
-
return [
|
|
9134
|
+
return [Te(i.fieldIsRequired)];
|
|
9135
9135
|
}
|
|
9136
9136
|
if (!Pe(e)) {
|
|
9137
9137
|
if (!Pe(t.min) && e.length < t.min)
|
|
9138
|
-
return [
|
|
9138
|
+
return [Te(i.selectMinItems, t.min)];
|
|
9139
9139
|
if (!Pe(t.max) && e.length > t.max)
|
|
9140
|
-
return [
|
|
9140
|
+
return [Te(i.selectMaxItems, t.max)];
|
|
9141
9141
|
}
|
|
9142
9142
|
},
|
|
9143
9143
|
date(e, t, n, i = Ze) {
|
|
@@ -9146,15 +9146,15 @@ const nn = {
|
|
|
9146
9146
|
return a;
|
|
9147
9147
|
const r = new Date(e);
|
|
9148
9148
|
if (isNaN(r.getDate()))
|
|
9149
|
-
return [
|
|
9149
|
+
return [Te(i.invalidDate)];
|
|
9150
9150
|
const s = [];
|
|
9151
9151
|
if (!Pe(t.min)) {
|
|
9152
9152
|
const o = new Date(t.min);
|
|
9153
|
-
r.valueOf() < o.valueOf() && s.push(
|
|
9153
|
+
r.valueOf() < o.valueOf() && s.push(Te(i.dateIsEarly, fn.format(r), fn.format(o)));
|
|
9154
9154
|
}
|
|
9155
9155
|
if (!Pe(t.max)) {
|
|
9156
9156
|
const o = new Date(t.max);
|
|
9157
|
-
r.valueOf() > o.valueOf() && s.push(
|
|
9157
|
+
r.valueOf() > o.valueOf() && s.push(Te(i.dateIsLate, fn.format(r), fn.format(o)));
|
|
9158
9158
|
}
|
|
9159
9159
|
return s;
|
|
9160
9160
|
},
|
|
@@ -9163,21 +9163,21 @@ const nn = {
|
|
|
9163
9163
|
if (a != null)
|
|
9164
9164
|
return a;
|
|
9165
9165
|
if (!Pe(t.pattern) && !new RegExp(t.pattern).test(e))
|
|
9166
|
-
return [
|
|
9166
|
+
return [Te(i.invalidFormat)];
|
|
9167
9167
|
},
|
|
9168
9168
|
email(e, t, n, i = Ze) {
|
|
9169
9169
|
const a = ut(e, t.required, i);
|
|
9170
9170
|
if (a != null)
|
|
9171
9171
|
return a;
|
|
9172
9172
|
if (!/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e))
|
|
9173
|
-
return [
|
|
9173
|
+
return [Te(i.invalidEmail)];
|
|
9174
9174
|
},
|
|
9175
9175
|
url(e, t, n, i = Ze) {
|
|
9176
9176
|
const a = ut(e, t.required, i);
|
|
9177
9177
|
if (a != null)
|
|
9178
9178
|
return a;
|
|
9179
9179
|
if (!/https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,4}\b([-a-zA-Z0-9@:%_\+.~#?&//=]*)/g.test(e))
|
|
9180
|
-
return [
|
|
9180
|
+
return [Te(i.invalidURL)];
|
|
9181
9181
|
},
|
|
9182
9182
|
creditCard(e, t, n, i = Ze) {
|
|
9183
9183
|
const a = ut(e, t.required, i);
|
|
@@ -9185,26 +9185,26 @@ const nn = {
|
|
|
9185
9185
|
return a;
|
|
9186
9186
|
const r = /^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|6(?:011|5[0-9][0-9])[0-9]{12}|3[47][0-9]{13}|3(?:0[0-5]|[68][0-9])[0-9]{11}|(?:2131|1800|35\d{3})\d{11})$/, s = e.replace(/[^0-9]+/g, "");
|
|
9187
9187
|
if (!r.test(s))
|
|
9188
|
-
return [
|
|
9188
|
+
return [Te(i.invalidCard)];
|
|
9189
9189
|
let o = 0, l, u, c;
|
|
9190
9190
|
for (let p = s.length - 1; p >= 0; p--)
|
|
9191
9191
|
l = s.substring(p, p + 1), u = parseInt(l, 10), c ? (u *= 2, u >= 10 ? o += u % 10 + 1 : o += u) : o += u, c = !c;
|
|
9192
9192
|
if (!(o % 10 === 0 && s))
|
|
9193
|
-
return [
|
|
9193
|
+
return [Te(i.invalidCardNumber)];
|
|
9194
9194
|
},
|
|
9195
9195
|
alpha(e, t, n, i = Ze) {
|
|
9196
9196
|
const a = ut(e, t.required, i);
|
|
9197
9197
|
if (a != null)
|
|
9198
9198
|
return a;
|
|
9199
9199
|
if (!/^[a-zA-Z]*$/.test(e))
|
|
9200
|
-
return [
|
|
9200
|
+
return [Te(i.invalidTextContainNumber)];
|
|
9201
9201
|
},
|
|
9202
9202
|
alphaNumeric(e, t, n, i = Ze) {
|
|
9203
9203
|
const a = ut(e, t.required, i);
|
|
9204
9204
|
if (a != null)
|
|
9205
9205
|
return a;
|
|
9206
9206
|
if (!/^[a-zA-Z0-9]*$/.test(e))
|
|
9207
|
-
return [
|
|
9207
|
+
return [Te(i.invalidTextContainSpec)];
|
|
9208
9208
|
}
|
|
9209
9209
|
};
|
|
9210
9210
|
Object.keys(nn).forEach((e) => {
|
|
@@ -10036,7 +10036,7 @@ const D0 = {
|
|
|
10036
10036
|
lineHeight: "0",
|
|
10037
10037
|
width: n.value
|
|
10038
10038
|
}));
|
|
10039
|
-
return (a, r) => (g(), P(
|
|
10039
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
10040
10040
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
10041
10041
|
class: "kui-icon add-icon",
|
|
10042
10042
|
"data-testid": "kui-icon-wrapper-add-icon",
|
|
@@ -10135,7 +10135,7 @@ const D0 = {
|
|
|
10135
10135
|
lineHeight: "0",
|
|
10136
10136
|
width: n.value
|
|
10137
10137
|
}));
|
|
10138
|
-
return (a, r) => (g(), P(
|
|
10138
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
10139
10139
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
10140
10140
|
class: "kui-icon remove-icon",
|
|
10141
10141
|
"data-testid": "kui-icon-wrapper-remove-icon",
|
|
@@ -10234,7 +10234,7 @@ const D0 = {
|
|
|
10234
10234
|
lineHeight: "0",
|
|
10235
10235
|
width: n.value
|
|
10236
10236
|
}));
|
|
10237
|
-
return (a, r) => (g(), P(
|
|
10237
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
10238
10238
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
10239
10239
|
class: "kui-icon trash-icon",
|
|
10240
10240
|
"data-testid": "kui-icon-wrapper-trash-icon",
|
|
@@ -10948,14 +10948,14 @@ function uC(e, t, n, i, a, r) {
|
|
|
10948
10948
|
key: c,
|
|
10949
10949
|
class: ge(e.schema.fieldItemsClasses)
|
|
10950
10950
|
}, [
|
|
10951
|
-
e.schema.items && e.schema.itemContainerComponent ? (g(), P(
|
|
10951
|
+
e.schema.items && e.schema.itemContainerComponent ? (g(), P(Le(e.schema.itemContainerComponent), {
|
|
10952
10952
|
key: 0,
|
|
10953
10953
|
model: u,
|
|
10954
10954
|
schema: r.generateSchema(e.value, e.schema.items, c),
|
|
10955
10955
|
onRemoveItem: (p) => r.removeElement(c)
|
|
10956
10956
|
}, {
|
|
10957
10957
|
default: b(() => [
|
|
10958
|
-
(g(), P(
|
|
10958
|
+
(g(), P(Le(r.getFieldType(e.schema.items)), {
|
|
10959
10959
|
"form-options": e.formOptions,
|
|
10960
10960
|
model: u,
|
|
10961
10961
|
schema: r.generateSchema(e.value, e.schema.items, c),
|
|
@@ -10964,13 +10964,13 @@ function uC(e, t, n, i, a, r) {
|
|
|
10964
10964
|
]),
|
|
10965
10965
|
_: 2
|
|
10966
10966
|
}, 1064, ["model", "schema", "onRemoveItem"])) : e.schema.items ? (g(), w("span", aC, [
|
|
10967
|
-
(g(), P(
|
|
10967
|
+
(g(), P(Le(r.getFieldType(e.schema.items)), {
|
|
10968
10968
|
"form-options": e.formOptions,
|
|
10969
10969
|
model: u,
|
|
10970
10970
|
schema: r.generateSchema(e.value, e.schema.items, c),
|
|
10971
10971
|
onModelUpdated: r.modelUpdated
|
|
10972
10972
|
}, null, 40, ["form-options", "model", "schema", "onModelUpdated"]))
|
|
10973
|
-
])) : e.schema.itemContainerComponent ? (g(), P(
|
|
10973
|
+
])) : e.schema.itemContainerComponent ? (g(), P(Le(e.schema.itemContainerComponent), {
|
|
10974
10974
|
key: 2,
|
|
10975
10975
|
"data-testid": `${e.getFieldID(e.schema)}-item-${c}`,
|
|
10976
10976
|
model: u,
|
|
@@ -11687,7 +11687,7 @@ function yE(e, t, n, i, a, r) {
|
|
|
11687
11687
|
} : void 0
|
|
11688
11688
|
]), 1032, ["aria-describedby", "class", "for", "info", "tooltip-attributes"])) : J("", !0),
|
|
11689
11689
|
y("div", pE, [
|
|
11690
|
-
(g(), P(
|
|
11690
|
+
(g(), P(Le(r.getFieldType(n.field)), St(e.$attrs, {
|
|
11691
11691
|
ref: "child",
|
|
11692
11692
|
disabled: e.fieldDisabled(n.field) || null,
|
|
11693
11693
|
"form-options": n.options,
|
|
@@ -11862,7 +11862,7 @@ const vE = /* @__PURE__ */ be(rE, [["render", yE], ["__scopeId", "data-v-6558b1f
|
|
|
11862
11862
|
function EE(e, t, n, i, a, r) {
|
|
11863
11863
|
const s = H("form-group"), o = H("KCollapse");
|
|
11864
11864
|
return n.schema != null ? (g(), w("div", wE, [
|
|
11865
|
-
n.schema.fields ? (g(), P(
|
|
11865
|
+
n.schema.fields ? (g(), P(Le(n.tag), { key: 0 }, {
|
|
11866
11866
|
default: b(() => [
|
|
11867
11867
|
(g(!0), w(oe, null, de(r.fields, (l) => (g(), w(oe, {
|
|
11868
11868
|
key: l.model
|
|
@@ -11896,7 +11896,7 @@ function EE(e, t, n, i, a, r) {
|
|
|
11896
11896
|
var c, p, m, h;
|
|
11897
11897
|
return [
|
|
11898
11898
|
(c = l.slots) != null && c.beforeContent ? Se(e.$slots, (p = l.slots) == null ? void 0 : p.beforeContent, { key: 0 }) : J("", !0),
|
|
11899
|
-
l.fields.length === 0 && (m = l.slots) != null && m.emptyState ? Se(e.$slots, (h = l.slots) == null ? void 0 : h.emptyState, { key: 1 }) : (g(), P(
|
|
11899
|
+
l.fields.length === 0 && (m = l.slots) != null && m.emptyState ? Se(e.$slots, (h = l.slots) == null ? void 0 : h.emptyState, { key: 1 }) : (g(), P(Le(n.tag), {
|
|
11900
11900
|
key: 2,
|
|
11901
11901
|
class: ge(e.getFieldRowClasses(l))
|
|
11902
11902
|
}, {
|
|
@@ -11929,7 +11929,7 @@ function EE(e, t, n, i, a, r) {
|
|
|
11929
11929
|
"onUpdate:modelValue": (M) => a.collapseStates[`group-${u}-nested`] = M
|
|
11930
11930
|
}, {
|
|
11931
11931
|
default: b(() => [
|
|
11932
|
-
(g(), P(
|
|
11932
|
+
(g(), P(Le(n.tag), {
|
|
11933
11933
|
class: ge(e.getFieldRowClasses(l))
|
|
11934
11934
|
}, {
|
|
11935
11935
|
default: b(() => [
|
|
@@ -11966,7 +11966,7 @@ function EE(e, t, n, i, a, r) {
|
|
|
11966
11966
|
]),
|
|
11967
11967
|
key: "0"
|
|
11968
11968
|
} : void 0
|
|
11969
|
-
]), 1032, ["title"])) : (g(), P(
|
|
11969
|
+
]), 1032, ["title"])) : (g(), P(Le(n.tag), {
|
|
11970
11970
|
key: 1,
|
|
11971
11971
|
class: ge(e.getFieldRowClasses(l))
|
|
11972
11972
|
}, {
|
|
@@ -14681,25 +14681,25 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
14681
14681
|
return;
|
|
14682
14682
|
const Q = V[$];
|
|
14683
14683
|
let F = z[$];
|
|
14684
|
-
const ye = te[$], we = Array.isArray(F) ? "array" : typeof F, Ue = Q ? Q.valueType : null, Mt = Q ? Q.valueArrayType : null,
|
|
14684
|
+
const ye = te[$], we = Array.isArray(F) ? "array" : typeof F, Ue = Q ? Q.valueType : null, Mt = Q ? Q.valueArrayType : null, Re = Q ? Q.transform : null;
|
|
14685
14685
|
if (F == null && ye == null && !Q.submitWhenNull)
|
|
14686
14686
|
return;
|
|
14687
14687
|
if (Q) {
|
|
14688
14688
|
if (Ue && we !== Ue)
|
|
14689
14689
|
switch (Ue) {
|
|
14690
14690
|
case "array":
|
|
14691
|
-
we === "string" && F.length && (F = F.split(",").map((
|
|
14692
|
-
if (
|
|
14693
|
-
return String(
|
|
14691
|
+
we === "string" && F.length && (F = F.split(",").map((xe) => {
|
|
14692
|
+
if (xe = xe.trim(), Mt === "string")
|
|
14693
|
+
return String(xe);
|
|
14694
14694
|
if (Mt === "number")
|
|
14695
|
-
return Number(
|
|
14695
|
+
return Number(xe);
|
|
14696
14696
|
if (Mt === "boolean") {
|
|
14697
|
-
if (typeof
|
|
14698
|
-
return
|
|
14699
|
-
if (typeof
|
|
14700
|
-
return
|
|
14697
|
+
if (typeof xe == "string")
|
|
14698
|
+
return xe.toLowerCase() === "true" || xe === "1";
|
|
14699
|
+
if (typeof xe == "number")
|
|
14700
|
+
return xe === 1;
|
|
14701
14701
|
}
|
|
14702
|
-
return
|
|
14702
|
+
return xe;
|
|
14703
14703
|
})), (!F || !F.length) && (F = Q.submitWhenNull ? null : []);
|
|
14704
14704
|
break;
|
|
14705
14705
|
case "number":
|
|
@@ -14714,22 +14714,22 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
14714
14714
|
}
|
|
14715
14715
|
else
|
|
14716
14716
|
Ue === "array" && (!F || !F.length) && (F = Q.submitWhenNull ? null : []);
|
|
14717
|
-
Q.type === "object-advanced" && Q.fields && F !== null && (Object.entries(F).length === 0 ? F = null : Object.keys(F).forEach((
|
|
14718
|
-
Array.isArray(F[
|
|
14717
|
+
Q.type === "object-advanced" && Q.fields && F !== null && (Object.entries(F).length === 0 ? F = null : Object.keys(F).forEach((xe) => {
|
|
14718
|
+
Array.isArray(F[xe]) || (F[xe] = F[xe].split(","));
|
|
14719
14719
|
}));
|
|
14720
14720
|
}
|
|
14721
14721
|
let Fe = s($);
|
|
14722
14722
|
if (Q.fieldNameHasDashes) {
|
|
14723
|
-
const [
|
|
14724
|
-
Fe = [
|
|
14723
|
+
const [xe, ...gt] = Fe.split(".").reverse();
|
|
14724
|
+
Fe = [xe.replace(/_/g, "-"), ...gt].reverse().join(".");
|
|
14725
14725
|
}
|
|
14726
14726
|
if (Ue === "object-expand") {
|
|
14727
|
-
let
|
|
14728
|
-
[Fe,
|
|
14727
|
+
let xe;
|
|
14728
|
+
[Fe, xe] = Fe.split(".");
|
|
14729
14729
|
let gt = {};
|
|
14730
|
-
ie[Fe] && (gt = ie[Fe]), gt[
|
|
14730
|
+
ie[Fe] && (gt = ie[Fe]), gt[xe] = F, F = gt;
|
|
14731
14731
|
}
|
|
14732
|
-
ye !== void 0 && F === "" && F !== ye ? ie[Fe] = Ue === "object" ? {} : null : Q.type === "checklist" && F === "" ? ie[Fe] = [] : F !== "" && (ie[Fe] = F), ie[Fe] =
|
|
14732
|
+
ye !== void 0 && F === "" && F !== ye ? ie[Fe] = Ue === "object" ? {} : null : Q.type === "checklist" && F === "" ? ie[Fe] = [] : F !== "" && (ie[Fe] = F), ie[Fe] = Re ? Re(F) : ie[Fe], u(Fe, ie);
|
|
14733
14733
|
}), o(ie);
|
|
14734
14734
|
}, B = (V, z) => {
|
|
14735
14735
|
var ie;
|
|
@@ -14816,7 +14816,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
14816
14816
|
key: 0,
|
|
14817
14817
|
type: "form"
|
|
14818
14818
|
})) : (g(), w("div", eO, [
|
|
14819
|
-
O.value && (E.id && e.editing || !e.editing) ? (g(), P(
|
|
14819
|
+
O.value && (E.id && e.editing || !e.editing) ? (g(), P(Le(O.value), {
|
|
14820
14820
|
key: 0,
|
|
14821
14821
|
"form-model": E,
|
|
14822
14822
|
"form-options": A.value,
|
|
@@ -15285,7 +15285,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15285
15285
|
const T = i.config.entityType && i.config.entityId && !i.developer, W = O.value ? Ve.form[i.config.app].credential[M.value] : Ve.form[i.config.app][M.value][T ? "forEntity" : "all"];
|
|
15286
15286
|
let L = `${i.config.apiBaseUrl}${W}`;
|
|
15287
15287
|
return i.config.app === "konnect" ? L = L.replace(/{controlPlaneId}/gi, i.config.controlPlaneId || "") : i.config.app === "kongManager" && (L = L.replace(/\/{workspace}/gi, i.config.workspace ? `/${i.config.workspace}` : "")), L = L.replace(/{resourceEndpoint}/gi, G.value), L = L.replace(/{id}/gi, i.pluginId), L = L.replace(/{entityType}/gi, i.config.entityType || ""), L = L.replace(/{entityId}/gi, i.config.entityId || ""), L;
|
|
15288
|
-
}), Mt = j(() => !Object.keys(At).includes(i.pluginType)),
|
|
15288
|
+
}), Mt = j(() => !Object.keys(At).includes(i.pluginType)), Re = j(() => {
|
|
15289
15289
|
const T = Q.value;
|
|
15290
15290
|
if (O.value) {
|
|
15291
15291
|
for (const W in d) {
|
|
@@ -15300,13 +15300,13 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15300
15300
|
try {
|
|
15301
15301
|
f.isReadonly = !0;
|
|
15302
15302
|
let T;
|
|
15303
|
-
!O.value && !Mt.value && await m.post(we.value,
|
|
15303
|
+
!O.value && !Mt.value && await m.post(we.value, Re.value), M.value === "create" ? T = await m.post(Ue.value, Re.value) : M.value === "edit" && (T = i.config.app === "konnect" ? await m.put(Ue.value, Object.assign({ ordering: Z.value }, Re.value)) : await m.patch(Ue.value, Re.value)), Object.assign(A, f.fields), n("update", T == null ? void 0 : T.data);
|
|
15304
15304
|
} catch (T) {
|
|
15305
15305
|
f.errorMessage = u(T), n("error", T);
|
|
15306
15306
|
} finally {
|
|
15307
15307
|
f.isReadonly = !1;
|
|
15308
15308
|
}
|
|
15309
|
-
},
|
|
15309
|
+
}, xe = j(() => {
|
|
15310
15310
|
var se;
|
|
15311
15311
|
const T = O.value ? (se = An[i.pluginType]) == null ? void 0 : se.schemaEndpoint : i.pluginType, W = O.value ? Ve.form[i.config.app].credentialSchema : Ve.form[i.config.app].pluginSchema;
|
|
15312
15312
|
let L = `${i.config.apiBaseUrl}${W}`;
|
|
@@ -15324,7 +15324,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15324
15324
|
const se = (T = An[i.pluginType]) == null ? void 0 : T.schemaEndpoint, le = Uf[se];
|
|
15325
15325
|
C.value = z("", le, {}), lt.value = !1;
|
|
15326
15326
|
} else {
|
|
15327
|
-
const se = await m.get(
|
|
15327
|
+
const se = await m.get(xe.value), { data: le } = se;
|
|
15328
15328
|
if (le)
|
|
15329
15329
|
if (O.value)
|
|
15330
15330
|
C.value = z("", le, {}), lt.value = !1;
|
|
@@ -15367,7 +15367,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15367
15367
|
"edit-id": e.pluginId,
|
|
15368
15368
|
"error-message": f.errorMessage,
|
|
15369
15369
|
"fetch-url": S.value,
|
|
15370
|
-
"form-fields":
|
|
15370
|
+
"form-fields": Re.value,
|
|
15371
15371
|
"is-readonly": f.isReadonly,
|
|
15372
15372
|
"no-validate": "",
|
|
15373
15373
|
"wrapper-component": e.noCardWrapper ? "div" : void 0,
|
|
@@ -15463,14 +15463,12 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15463
15463
|
x(v(fa), {
|
|
15464
15464
|
config: e.config,
|
|
15465
15465
|
"fetcher-url": Ue.value,
|
|
15466
|
-
"json-record":
|
|
15466
|
+
"json-record": Re.value,
|
|
15467
15467
|
"request-method": i.pluginId ? "put" : "post"
|
|
15468
15468
|
}, null, 8, ["config", "fetcher-url", "json-record", "request-method"])
|
|
15469
15469
|
]),
|
|
15470
15470
|
yaml: b(() => [
|
|
15471
|
-
x(v(Ea), {
|
|
15472
|
-
"yaml-record": f.fields
|
|
15473
|
-
}, null, 8, ["yaml-record"])
|
|
15471
|
+
x(v(Ea), { "yaml-record": Re.value }, null, 8, ["yaml-record"])
|
|
15474
15472
|
]),
|
|
15475
15473
|
_: 1
|
|
15476
15474
|
}, 8, ["tabs"])
|
|
@@ -15480,7 +15478,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15480
15478
|
]);
|
|
15481
15479
|
};
|
|
15482
15480
|
}
|
|
15483
|
-
}), DI = /* @__PURE__ */ ft(lO, [["__scopeId", "data-v-
|
|
15481
|
+
}), DI = /* @__PURE__ */ ft(lO, [["__scopeId", "data-v-e995b170"]]), uO = ["alt", "src", "width"], Ka = /* @__PURE__ */ ue({
|
|
15484
15482
|
__name: "PluginIcon",
|
|
15485
15483
|
props: {
|
|
15486
15484
|
name: {
|
|
@@ -15592,7 +15590,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15592
15590
|
lineHeight: "0",
|
|
15593
15591
|
width: n.value
|
|
15594
15592
|
}));
|
|
15595
|
-
return (a, r) => (g(), P(
|
|
15593
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
15596
15594
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
15597
15595
|
class: "kui-icon add-icon",
|
|
15598
15596
|
"data-testid": "kui-icon-wrapper-add-icon",
|
|
@@ -15691,7 +15689,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15691
15689
|
lineHeight: "0",
|
|
15692
15690
|
width: n.value
|
|
15693
15691
|
}));
|
|
15694
|
-
return (a, r) => (g(), P(
|
|
15692
|
+
return (a, r) => (g(), P(Le(e.as), {
|
|
15695
15693
|
"aria-hidden": e.decorative ? "true" : void 0,
|
|
15696
15694
|
class: "kui-icon more-icon",
|
|
15697
15695
|
"data-testid": "kui-icon-wrapper-more-icon",
|
|
@@ -15931,11 +15929,11 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
15931
15929
|
}), Q = (T) => ({
|
|
15932
15930
|
label: r("actions.configure_dynamic_ordering"),
|
|
15933
15931
|
to: a.config.getConfigureDynamicOrderingRoute(T)
|
|
15934
|
-
}), F = q(void 0), ye = q(!1), we = q(!1), Ue = q(""), Mt = Gg(a.config, M.value),
|
|
15932
|
+
}), F = q(void 0), ye = q(!1), we = q(!1), Ue = q(""), Mt = Gg(a.config, M.value), Re = (T) => {
|
|
15935
15933
|
F.value = T, ye.value = !0;
|
|
15936
15934
|
}, Fe = () => {
|
|
15937
15935
|
ye.value = !1;
|
|
15938
|
-
},
|
|
15936
|
+
}, xe = async () => {
|
|
15939
15937
|
var T, W, L;
|
|
15940
15938
|
if ((T = F.value) != null && T.id) {
|
|
15941
15939
|
we.value = !0;
|
|
@@ -16187,7 +16185,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
16187
16185
|
danger: "",
|
|
16188
16186
|
"data-testid": "action-entity-delete",
|
|
16189
16187
|
"has-divider": "",
|
|
16190
|
-
onClick: (X) =>
|
|
16188
|
+
onClick: (X) => Re(ne)
|
|
16191
16189
|
}, {
|
|
16192
16190
|
default: b(() => [
|
|
16193
16191
|
re(U(v(r)("actions.delete")), 1)
|
|
@@ -16219,7 +16217,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
16219
16217
|
title: v(r)("delete.title"),
|
|
16220
16218
|
visible: ye.value,
|
|
16221
16219
|
onCancel: Fe,
|
|
16222
|
-
onProceed:
|
|
16220
|
+
onProceed: xe
|
|
16223
16221
|
}, null, 8, ["action-pending", "description", "entity-name", "entity-type", "error", "title", "visible"])
|
|
16224
16222
|
]);
|
|
16225
16223
|
};
|
|
@@ -17056,7 +17054,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
17056
17054
|
y("div", cI, [
|
|
17057
17055
|
x(Q, {
|
|
17058
17056
|
modelValue: p.value,
|
|
17059
|
-
"onUpdate:modelValue": $[0] || ($[0] = (
|
|
17057
|
+
"onUpdate:modelValue": $[0] || ($[0] = (Re) => p.value = Re),
|
|
17060
17058
|
modelModifiers: { trim: !0 },
|
|
17061
17059
|
class: "plugins-filter-input",
|
|
17062
17060
|
"data-testid": "plugins-filter",
|
|
@@ -17106,7 +17104,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
17106
17104
|
v(S).length && !e.hideCustomPlugins ? (g(), P(Mt, {
|
|
17107
17105
|
key: 0,
|
|
17108
17106
|
modelValue: k.value,
|
|
17109
|
-
"onUpdate:modelValue": $[5] || ($[5] = (
|
|
17107
|
+
"onUpdate:modelValue": $[5] || ($[5] = (Re) => k.value = Re),
|
|
17110
17108
|
"data-testid": "plugins-tabs",
|
|
17111
17109
|
tabs: v(S),
|
|
17112
17110
|
onChange: V
|
|
@@ -17122,7 +17120,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
17122
17120
|
"navigate-on-click": e.navigateOnClick,
|
|
17123
17121
|
"plugin-list": E.value,
|
|
17124
17122
|
"plugins-per-row": e.pluginsPerRow,
|
|
17125
|
-
onPluginClicked: $[1] || ($[1] = (
|
|
17123
|
+
onPluginClicked: $[1] || ($[1] = (Re) => Z.$emit("plugin-clicked", Re))
|
|
17126
17124
|
}, null, 8, ["config", "hide-highlighted-plugins", "highlighted-plugins", "highlighted-plugins-title", "navigate-on-click", "plugin-list", "plugins-per-row"])
|
|
17127
17125
|
])
|
|
17128
17126
|
]),
|
|
@@ -17137,8 +17135,8 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
17137
17135
|
"navigate-on-click": e.navigateOnClick,
|
|
17138
17136
|
"plugin-list": E.value,
|
|
17139
17137
|
"plugins-per-row": e.pluginsPerRow,
|
|
17140
|
-
"onDelete:success": $[2] || ($[2] = (
|
|
17141
|
-
onPluginClicked: $[3] || ($[3] = (
|
|
17138
|
+
"onDelete:success": $[2] || ($[2] = (Re) => Z.$emit("delete-custom:success", Re)),
|
|
17139
|
+
onPluginClicked: $[3] || ($[3] = (Re) => Z.$emit("plugin-clicked", Re)),
|
|
17142
17140
|
onRevalidate: $[4] || ($[4] = () => O.value = D())
|
|
17143
17141
|
}, null, 8, ["can-create-custom-plugin", "can-delete-custom-plugin", "can-edit-custom-plugin", "config", "navigate-on-click", "plugin-list", "plugins-per-row"])
|
|
17144
17142
|
])
|
|
@@ -17169,7 +17167,7 @@ will extend the wait time by about 12 minutes, continuously adjusting as new req
|
|
|
17169
17167
|
"navigate-on-click": e.navigateOnClick,
|
|
17170
17168
|
"plugin-list": E.value,
|
|
17171
17169
|
"plugins-per-row": e.pluginsPerRow,
|
|
17172
|
-
onPluginClicked: $[6] || ($[6] = (
|
|
17170
|
+
onPluginClicked: $[6] || ($[6] = (Re) => Z.$emit("plugin-clicked", Re))
|
|
17173
17171
|
}, null, 8, ["config", "hide-highlighted-plugins", "highlighted-plugins", "highlighted-plugins-title", "navigate-on-click", "plugin-list", "plugins-per-row"]))
|
|
17174
17172
|
]))
|
|
17175
17173
|
]);
|