@kong-ui-public/entities-plugins 9.219.1 → 9.220.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-plugins.es.js +360 -358
- package/dist/entities-plugins.umd.js +11 -11
- package/dist/style.css +1 -1
- package/dist/types/components/PluginEntityForm.vue.d.ts.map +1 -1
- package/dist/types/types/plugin-form.d.ts +0 -4
- package/dist/types/types/plugin-form.d.ts.map +1 -1
- package/package.json +11 -11
|
@@ -5987,7 +5987,7 @@ const [Kp, K1] = cl(
|
|
|
5987
5987
|
function H(ee, le, fe = !0) {
|
|
5988
5988
|
const Ae = x(ee);
|
|
5989
5989
|
if (!Ae || dn(Ae.type)) return;
|
|
5990
|
-
const
|
|
5990
|
+
const Ee = {
|
|
5991
5991
|
...si(Ae),
|
|
5992
5992
|
id: ho("node"),
|
|
5993
5993
|
name: ac(Ae.name, A.value),
|
|
@@ -5995,32 +5995,32 @@ const [Kp, K1] = cl(
|
|
|
5995
5995
|
x: Ae.position.x + 20,
|
|
5996
5996
|
y: Ae.position.y + 20
|
|
5997
5997
|
}
|
|
5998
|
-
}, $e = ha(
|
|
5999
|
-
if ($e.length &&
|
|
5998
|
+
}, $e = ha(Ee.type);
|
|
5999
|
+
if ($e.length && Ee.config) {
|
|
6000
6000
|
for (const g of $e)
|
|
6001
|
-
delete
|
|
6002
|
-
Object.keys(
|
|
6001
|
+
delete Ee.config[g];
|
|
6002
|
+
Object.keys(Ee.config).length === 0 && delete Ee.config;
|
|
6003
6003
|
}
|
|
6004
|
-
return i.value.nodes.push(
|
|
6004
|
+
return i.value.nodes.push(Ee), fe && s.commit(), d.value = !0, Ee.id;
|
|
6005
6005
|
}
|
|
6006
6006
|
function se(ee, le = !0) {
|
|
6007
6007
|
if (!x(ee)) return;
|
|
6008
6008
|
i.value.edges = i.value.edges.filter(
|
|
6009
|
-
(
|
|
6009
|
+
(Ee) => Ee.source !== ee && Ee.target !== ee
|
|
6010
6010
|
), k.clear(ee, { commit: !1 }), k.removeMember(ee, { commit: !1 }), i.value.nodes = i.value.nodes.filter(
|
|
6011
|
-
(
|
|
6011
|
+
(Ee) => Ee.id !== ee
|
|
6012
6012
|
), o.value === ee && (o.value = void 0);
|
|
6013
6013
|
const Ae = P();
|
|
6014
6014
|
Ae.ok || console.warn("[removeNode] topology invalid:", Ae.errors.join("; ")), le && s.commit();
|
|
6015
6015
|
}
|
|
6016
6016
|
function F(ee, le, fe = !0, Ae) {
|
|
6017
|
-
const
|
|
6018
|
-
if (!
|
|
6019
|
-
if (Fl(
|
|
6017
|
+
const Ee = x(ee);
|
|
6018
|
+
if (!Ee) return;
|
|
6019
|
+
if (Fl(Ee.name)) {
|
|
6020
6020
|
console.warn("[renameNode] implicit node name is reserved.");
|
|
6021
6021
|
return;
|
|
6022
6022
|
}
|
|
6023
|
-
|
|
6023
|
+
Ee.name !== le && (Ee.name = le, fe && s.commit(Ae));
|
|
6024
6024
|
}
|
|
6025
6025
|
function $(ee, le, fe = !0) {
|
|
6026
6026
|
const Ae = x(ee);
|
|
@@ -6029,50 +6029,50 @@ const [Kp, K1] = cl(
|
|
|
6029
6029
|
function V(ee, le, fe = !0) {
|
|
6030
6030
|
const Ae = E.value.get(ee);
|
|
6031
6031
|
if (!Ae) return;
|
|
6032
|
-
const
|
|
6033
|
-
|
|
6032
|
+
const Ee = Ae.position;
|
|
6033
|
+
Ee && Ee.x === le.x && Ee.y === le.y || (Ae.position = { ...le }, fe && s.commit());
|
|
6034
6034
|
}
|
|
6035
6035
|
function ie(ee, le, fe = !0) {
|
|
6036
6036
|
const Ae = E.value.get(ee);
|
|
6037
6037
|
if (!Ae) return !1;
|
|
6038
|
-
const
|
|
6039
|
-
return g && Z ? !1 : (Ae.position =
|
|
6038
|
+
const Ee = { ...le.position }, $e = { ...le.dimensions }, g = Ae.position && Ae.position.x === Ee.x && Ae.position.y === Ee.y, Z = Ae.dimensions && Ae.dimensions.width === $e.width && Ae.dimensions.height === $e.height;
|
|
6039
|
+
return g && Z ? !1 : (Ae.position = Ee, Ae.dimensions = $e, fe && s.commit(), !0);
|
|
6040
6040
|
}
|
|
6041
|
-
function ne(ee, le, fe, Ae = !0,
|
|
6041
|
+
function ne(ee, le, fe, Ae = !0, Ee) {
|
|
6042
6042
|
const $e = x(ee);
|
|
6043
6043
|
if (!$e) return;
|
|
6044
6044
|
const g = fe ?? !$e.expanded[le];
|
|
6045
|
-
g !== !!$e.expanded[le] && ($e.expanded[le] = g, Ae && s.commit(
|
|
6045
|
+
g !== !!$e.expanded[le] && ($e.expanded[le] = g, Ae && s.commit(Ee ?? `toggle:${ee}:${le}`));
|
|
6046
6046
|
}
|
|
6047
6047
|
function he(ee, le, fe = !0, Ae) {
|
|
6048
|
-
const
|
|
6049
|
-
|
|
6048
|
+
const Ee = x(ee);
|
|
6049
|
+
Ee && (Ee.config = si(le), fe && s.commit(Ae));
|
|
6050
6050
|
}
|
|
6051
6051
|
function we(ee, le, fe, Ae = !0) {
|
|
6052
|
-
const
|
|
6053
|
-
if (!
|
|
6054
|
-
const $e =
|
|
6052
|
+
const Ee = x(ee);
|
|
6053
|
+
if (!Ee) return;
|
|
6054
|
+
const $e = Ee.fields[le];
|
|
6055
6055
|
if ($e.some((g) => g.name === fe)) {
|
|
6056
6056
|
console.warn(`[addField] field "${fe}" already exists on ${le}.`);
|
|
6057
6057
|
return;
|
|
6058
6058
|
}
|
|
6059
|
-
$e.push({ id: ho("field"), name: fe }), le === "input" ?
|
|
6059
|
+
$e.push({ id: ho("field"), name: fe }), le === "input" ? Ee.fields.input = $e : Ee.fields.output = $e, Ae && s.commit();
|
|
6060
6060
|
}
|
|
6061
6061
|
function ce(ee, le, fe, Ae = !0) {
|
|
6062
|
-
const
|
|
6063
|
-
if (!
|
|
6064
|
-
const $e =
|
|
6062
|
+
const Ee = x(ee);
|
|
6063
|
+
if (!Ee) return;
|
|
6064
|
+
const $e = Ee.fields.input, g = Ee.fields.output, Z = $e.find((be) => be.id === le) ?? g.find((be) => be.id === le);
|
|
6065
6065
|
Z && (Z.name = fe, Ae && s.commit());
|
|
6066
6066
|
}
|
|
6067
6067
|
function ve(ee, le, fe = !0, Ae = !0) {
|
|
6068
|
-
const
|
|
6069
|
-
if (!
|
|
6070
|
-
const $e =
|
|
6068
|
+
const Ee = x(ee);
|
|
6069
|
+
if (!Ee) return;
|
|
6070
|
+
const $e = Ee.fields.input, g = Ee.fields.output, Z = $e.findIndex((me) => me.id === le);
|
|
6071
6071
|
Z >= 0 && $e.splice(Z, 1);
|
|
6072
6072
|
const be = g.findIndex(
|
|
6073
6073
|
(me) => me.id === le
|
|
6074
6074
|
);
|
|
6075
|
-
be >= 0 && g.splice(be, 1),
|
|
6075
|
+
be >= 0 && g.splice(be, 1), Ee.fields.input = $e, Ee.fields.output = g, fe && (i.value.edges = i.value.edges.filter(
|
|
6076
6076
|
(me) => me.sourceField !== le && me.targetField !== le
|
|
6077
6077
|
));
|
|
6078
6078
|
const ke = P();
|
|
@@ -6087,14 +6087,14 @@ const [Kp, K1] = cl(
|
|
|
6087
6087
|
);
|
|
6088
6088
|
return;
|
|
6089
6089
|
}
|
|
6090
|
-
const
|
|
6091
|
-
i.value.edges.push(
|
|
6090
|
+
const Ee = { id: ho("edge"), ...fe };
|
|
6091
|
+
i.value.edges.push(Ee);
|
|
6092
6092
|
const $e = P();
|
|
6093
6093
|
if (!$e.ok) {
|
|
6094
6094
|
i.value.edges.pop(), console.warn("[connectEdge] topology invalid:", $e.errors.join("; "));
|
|
6095
6095
|
return;
|
|
6096
6096
|
}
|
|
6097
|
-
return le && s.commit(),
|
|
6097
|
+
return le && s.commit(), Ee.id;
|
|
6098
6098
|
}
|
|
6099
6099
|
function Be(ee, le, fe = !0) {
|
|
6100
6100
|
qe(ee, !1), je(le, !1), fe && s.commit();
|
|
@@ -6104,11 +6104,11 @@ const [Kp, K1] = cl(
|
|
|
6104
6104
|
if (fe < 0) return;
|
|
6105
6105
|
const Ae = i.value.edges[fe];
|
|
6106
6106
|
i.value.edges.splice(fe, 1);
|
|
6107
|
-
const
|
|
6108
|
-
if (!
|
|
6107
|
+
const Ee = P();
|
|
6108
|
+
if (!Ee.ok) {
|
|
6109
6109
|
i.value.edges.splice(fe, 0, Ae), console.warn(
|
|
6110
6110
|
"[disconnectEdge] topology invalid:",
|
|
6111
|
-
|
|
6111
|
+
Ee.errors.join("; ")
|
|
6112
6112
|
);
|
|
6113
6113
|
return;
|
|
6114
6114
|
}
|
|
@@ -6127,7 +6127,7 @@ const [Kp, K1] = cl(
|
|
|
6127
6127
|
le && s.commit();
|
|
6128
6128
|
}
|
|
6129
6129
|
function at() {
|
|
6130
|
-
var le, fe, Ae,
|
|
6130
|
+
var le, fe, Ae, Ee, $e;
|
|
6131
6131
|
const ee = [];
|
|
6132
6132
|
for (const g of i.value.nodes) {
|
|
6133
6133
|
if (dn(g.type))
|
|
@@ -6140,8 +6140,8 @@ const [Kp, K1] = cl(
|
|
|
6140
6140
|
const B = x(ae.source);
|
|
6141
6141
|
if (!B)
|
|
6142
6142
|
continue;
|
|
6143
|
-
const z = (le = Ci(B, "output", ae.sourceField)) == null ? void 0 : le.name, pe = z ? `${B.name}.${z}` : B.name,
|
|
6144
|
-
|
|
6143
|
+
const z = (le = Ci(B, "output", ae.sourceField)) == null ? void 0 : le.name, pe = z ? `${B.name}.${z}` : B.name, xe = (fe = Ci(g, "input", ae.targetField)) == null ? void 0 : fe.name;
|
|
6144
|
+
xe ? be[xe] = pe : Z === void 0 && (Z = pe);
|
|
6145
6145
|
}
|
|
6146
6146
|
for (const ae of i.value.edges.filter((B) => B.source === g.id)) {
|
|
6147
6147
|
const B = x(ae.target);
|
|
@@ -6150,8 +6150,8 @@ const [Kp, K1] = cl(
|
|
|
6150
6150
|
const z = B.type;
|
|
6151
6151
|
if (!dn(z) || !((Ae = jr[z].io) != null && Ae.input))
|
|
6152
6152
|
continue;
|
|
6153
|
-
const pe = (
|
|
6154
|
-
Te ? me[Te] =
|
|
6153
|
+
const pe = (Ee = Ci(B, "input", ae.targetField)) == null ? void 0 : Ee.name, xe = pe ? `${B.name}.${pe}` : B.name, Te = ($e = Ci(g, "output", ae.sourceField)) == null ? void 0 : $e.name;
|
|
6154
|
+
Te ? me[Te] = xe : ke === void 0 && (ke = xe);
|
|
6155
6155
|
}
|
|
6156
6156
|
const Me = {
|
|
6157
6157
|
...si(g.config),
|
|
@@ -6165,8 +6165,8 @@ const [Kp, K1] = cl(
|
|
|
6165
6165
|
continue;
|
|
6166
6166
|
const z = [];
|
|
6167
6167
|
for (const pe of B) {
|
|
6168
|
-
const
|
|
6169
|
-
|
|
6168
|
+
const xe = x(pe);
|
|
6169
|
+
xe && z.push(xe.name);
|
|
6170
6170
|
}
|
|
6171
6171
|
z.length ? Me[ae] = Array.from(new Set(z)) : delete Me[ae];
|
|
6172
6172
|
}
|
|
@@ -6195,13 +6195,13 @@ const [Kp, K1] = cl(
|
|
|
6195
6195
|
fe && Object.keys(fe).length > 0 && (ee.vault = fe);
|
|
6196
6196
|
}
|
|
6197
6197
|
if (i.value.cacheConfig) {
|
|
6198
|
-
const { strategy: fe, redis: Ae, memory:
|
|
6199
|
-
ee.cache = { strategy: fe, redis: Ae, memory:
|
|
6198
|
+
const { strategy: fe, redis: Ae, memory: Ee } = i.value.cacheConfig;
|
|
6199
|
+
ee.cache = { strategy: fe, redis: Ae, memory: Ee };
|
|
6200
6200
|
}
|
|
6201
6201
|
if (Object.keys(ee).length !== 0)
|
|
6202
6202
|
return ee;
|
|
6203
6203
|
}
|
|
6204
|
-
function
|
|
6204
|
+
function Ce() {
|
|
6205
6205
|
const ee = [];
|
|
6206
6206
|
for (const le of i.value.groups) {
|
|
6207
6207
|
const fe = x(le.ownerId);
|
|
@@ -6217,7 +6217,7 @@ const [Kp, K1] = cl(
|
|
|
6217
6217
|
function _e() {
|
|
6218
6218
|
return {
|
|
6219
6219
|
nodes: Ue(),
|
|
6220
|
-
groups:
|
|
6220
|
+
groups: Ce()
|
|
6221
6221
|
};
|
|
6222
6222
|
}
|
|
6223
6223
|
function oe(ee, le) {
|
|
@@ -6273,7 +6273,7 @@ const [Kp, K1] = cl(
|
|
|
6273
6273
|
// serialization
|
|
6274
6274
|
toConfigNodes: at,
|
|
6275
6275
|
toUINodes: Ue,
|
|
6276
|
-
toUIGroups:
|
|
6276
|
+
toUIGroups: Ce,
|
|
6277
6277
|
toUIData: _e,
|
|
6278
6278
|
load: oe,
|
|
6279
6279
|
// history
|
|
@@ -6938,8 +6938,8 @@ const [z1, G1] = cl(
|
|
|
6938
6938
|
he.value = B;
|
|
6939
6939
|
}, ce = Qc(he);
|
|
6940
6940
|
function ve(B, z) {
|
|
6941
|
-
const pe = G(B.source),
|
|
6942
|
-
return !!(pe &&
|
|
6941
|
+
const pe = G(B.source), xe = G(B.target);
|
|
6942
|
+
return !!(pe && xe && pe.phase === z && xe.phase === z);
|
|
6943
6943
|
}
|
|
6944
6944
|
const je = q1({
|
|
6945
6945
|
phase: t,
|
|
@@ -6954,7 +6954,7 @@ const [z1, G1] = cl(
|
|
|
6954
6954
|
updateGroupLayout: at,
|
|
6955
6955
|
translateGroupTree: Ue,
|
|
6956
6956
|
getNodeDepth: Se,
|
|
6957
|
-
maxGroupDepth:
|
|
6957
|
+
maxGroupDepth: Ce
|
|
6958
6958
|
} = je, {
|
|
6959
6959
|
activeGroupId: _e,
|
|
6960
6960
|
start: oe,
|
|
@@ -6968,10 +6968,10 @@ const [z1, G1] = cl(
|
|
|
6968
6968
|
draggingId: ce
|
|
6969
6969
|
}), fe = L(
|
|
6970
6970
|
() => D.value.nodes.filter((B) => B.phase === t && !B.hidden).map((B) => {
|
|
6971
|
-
const z = Be.value.get(B.id), pe = z == null ? void 0 : z.position,
|
|
6971
|
+
const z = Be.value.get(B.id), pe = z == null ? void 0 : z.position, xe = z == null ? void 0 : z.dimensions, Te = z && pe && xe ? {
|
|
6972
6972
|
x: B.position.x - pe.x,
|
|
6973
6973
|
y: B.position.y - pe.y
|
|
6974
|
-
} : B.position, Ne = Se(B.id), De = !!(z && pe &&
|
|
6974
|
+
} : B.position, Ne = Se(B.id), De = !!(z && pe && xe), We = (De ? Ne : 0) + Ce.value + 1;
|
|
6975
6975
|
return {
|
|
6976
6976
|
id: B.id,
|
|
6977
6977
|
type: "flow",
|
|
@@ -6992,7 +6992,7 @@ const [z1, G1] = cl(
|
|
|
6992
6992
|
const Te = [];
|
|
6993
6993
|
throw z || Te.push(`source node "${B.source}"`), pe || Te.push(`target node "${B.target}"`), new Error(`Missing ${Te.join(" and ")} for edge "${B.id}" in phase "${t}"`);
|
|
6994
6994
|
}
|
|
6995
|
-
const
|
|
6995
|
+
const xe = Math.max(Se(B.source), Se(B.target)) + Ce.value + 1;
|
|
6996
6996
|
return Ba({
|
|
6997
6997
|
id: B.id,
|
|
6998
6998
|
source: B.source,
|
|
@@ -7002,10 +7002,10 @@ const [z1, G1] = cl(
|
|
|
7002
7002
|
markerEnd: ld.ArrowClosed,
|
|
7003
7003
|
data: B,
|
|
7004
7004
|
updatable: !o,
|
|
7005
|
-
zIndex:
|
|
7005
|
+
zIndex: xe * ur + sy
|
|
7006
7006
|
});
|
|
7007
7007
|
})
|
|
7008
|
-
),
|
|
7008
|
+
), Ee = L(() => [
|
|
7009
7009
|
...He.value,
|
|
7010
7010
|
...Ae.value
|
|
7011
7011
|
]), { autoLayout: $e } = j1({
|
|
@@ -7013,12 +7013,12 @@ const [z1, G1] = cl(
|
|
|
7013
7013
|
layoutOptions: i,
|
|
7014
7014
|
branchLayout: je,
|
|
7015
7015
|
nodes: fe,
|
|
7016
|
-
edges:
|
|
7016
|
+
edges: Ee
|
|
7017
7017
|
});
|
|
7018
7018
|
U1({
|
|
7019
7019
|
readonly: o,
|
|
7020
7020
|
flowId: n
|
|
7021
|
-
}), Xe([fe, qe,
|
|
7021
|
+
}), Xe([fe, qe, Ee], ([B, z, pe]) => {
|
|
7022
7022
|
S([...z, ...B]), x(pe);
|
|
7023
7023
|
}, { immediate: !0 });
|
|
7024
7024
|
const g = L(() => ({
|
|
@@ -7026,10 +7026,10 @@ const [z1, G1] = cl(
|
|
|
7026
7026
|
padding: a / Math.max(_t(r == null ? void 0 : r.width) ?? 0, _t(r == null ? void 0 : r.height) ?? 0)
|
|
7027
7027
|
// maxZoom and minZoom come from the VueFlow store
|
|
7028
7028
|
}));
|
|
7029
|
-
async function Z({ source: B, sourceHandle: z, target: pe, targetHandle:
|
|
7030
|
-
if (!z || !
|
|
7031
|
-
const Te = uc(z), Ne = uc(
|
|
7032
|
-
if ((Te == null ? void 0 : Te.io) === "input" || (Ne == null ? void 0 : Ne.io) === "output" || z === "output" &&
|
|
7029
|
+
async function Z({ source: B, sourceHandle: z, target: pe, targetHandle: xe }) {
|
|
7030
|
+
if (!z || !xe) return;
|
|
7031
|
+
const Te = uc(z), Ne = uc(xe);
|
|
7032
|
+
if ((Te == null ? void 0 : Te.io) === "input" || (Ne == null ? void 0 : Ne.io) === "output" || z === "output" && xe === "output")
|
|
7033
7033
|
return;
|
|
7034
7034
|
const De = H(pe);
|
|
7035
7035
|
let We = !1, Ge = !1;
|
|
@@ -7085,15 +7085,15 @@ const [z1, G1] = cl(
|
|
|
7085
7085
|
be && (be = !1, F());
|
|
7086
7086
|
};
|
|
7087
7087
|
A((B) => {
|
|
7088
|
-
B.filter((
|
|
7089
|
-
J(
|
|
7088
|
+
B.filter((xe) => xe.type === "select").filter((xe) => !ie(xe.id)).sort((xe, Te) => xe.selected === Te.selected ? 0 : xe.selected ? 1 : -1).forEach((xe) => {
|
|
7089
|
+
J(xe.selected ? xe.id : void 0);
|
|
7090
7090
|
});
|
|
7091
7091
|
let pe = !1;
|
|
7092
|
-
B.forEach((
|
|
7093
|
-
if (
|
|
7094
|
-
if (ie(
|
|
7092
|
+
B.forEach((xe) => {
|
|
7093
|
+
if (xe.type === "remove") {
|
|
7094
|
+
if (ie(xe.id))
|
|
7095
7095
|
return;
|
|
7096
|
-
pe = !0, q(
|
|
7096
|
+
pe = !0, q(xe.id, !1);
|
|
7097
7097
|
}
|
|
7098
7098
|
}), pe && !be && (be = !0, queueMicrotask(ke));
|
|
7099
7099
|
}), v(({ node: B, event: z }) => {
|
|
@@ -7112,10 +7112,10 @@ const [z1, G1] = cl(
|
|
|
7112
7112
|
}
|
|
7113
7113
|
const pe = B.id;
|
|
7114
7114
|
oe("canvas"), we(pe);
|
|
7115
|
-
const
|
|
7115
|
+
const xe = B.parentNode;
|
|
7116
7116
|
let Te = { ...B.position };
|
|
7117
|
-
if (
|
|
7118
|
-
const Fe = V.value.get(
|
|
7117
|
+
if (xe && ie(xe)) {
|
|
7118
|
+
const Fe = V.value.get(xe);
|
|
7119
7119
|
Fe != null && Fe.position && (Te = {
|
|
7120
7120
|
x: Fe.position.x + B.position.x,
|
|
7121
7121
|
y: Fe.position.y + B.position.y
|
|
@@ -7133,7 +7133,7 @@ const [z1, G1] = cl(
|
|
|
7133
7133
|
};
|
|
7134
7134
|
ee(Pe ?? tt);
|
|
7135
7135
|
}
|
|
7136
|
-
const Ne =
|
|
7136
|
+
const Ne = xe && ie(xe) ? xe : (Ge = Be.value.get(pe)) == null ? void 0 : Ge.id;
|
|
7137
7137
|
Ne && at(Ne, !1);
|
|
7138
7138
|
}), b(({ node: B }) => {
|
|
7139
7139
|
var Ne;
|
|
@@ -7143,29 +7143,29 @@ const [z1, G1] = cl(
|
|
|
7143
7143
|
return;
|
|
7144
7144
|
}
|
|
7145
7145
|
const z = B.id, pe = B.parentNode;
|
|
7146
|
-
let
|
|
7146
|
+
let xe = { ...B.position };
|
|
7147
7147
|
if (pe && ie(pe)) {
|
|
7148
7148
|
const De = V.value.get(pe);
|
|
7149
|
-
De != null && De.position && (
|
|
7149
|
+
De != null && De.position && (xe = {
|
|
7150
7150
|
x: De.position.x + B.position.x,
|
|
7151
7151
|
y: De.position.y + B.position.y
|
|
7152
7152
|
});
|
|
7153
7153
|
}
|
|
7154
|
-
X(z,
|
|
7154
|
+
X(z, xe, !1);
|
|
7155
7155
|
const Te = pe && ie(pe) ? pe : (Ne = Be.value.get(z)) == null ? void 0 : Ne.id;
|
|
7156
7156
|
Te && at(Te, !1), Ke(z), le(), W();
|
|
7157
7157
|
}), k((B) => {
|
|
7158
|
-
B.filter((
|
|
7159
|
-
Je(
|
|
7158
|
+
B.filter((xe) => xe.type === "select").sort((xe, Te) => xe.selected === Te.selected ? 0 : xe.selected ? 1 : -1).forEach((xe) => {
|
|
7159
|
+
Je(xe.id) || (qp = xe.selected ? xe.id : void 0, x((Te) => Te.map((Ne) => Ne.id !== xe.id || !Ne.markerEnd ? Ne : Ba({
|
|
7160
7160
|
...Ne,
|
|
7161
|
-
zIndex:
|
|
7161
|
+
zIndex: xe.selected ? 1 : void 0
|
|
7162
7162
|
}))));
|
|
7163
7163
|
});
|
|
7164
7164
|
let pe = !1;
|
|
7165
|
-
B.forEach((
|
|
7166
|
-
if (
|
|
7167
|
-
if (Je(
|
|
7168
|
-
pe = !0, U(
|
|
7165
|
+
B.forEach((xe) => {
|
|
7166
|
+
if (xe.type === "remove") {
|
|
7167
|
+
if (Je(xe.id)) return;
|
|
7168
|
+
pe = !0, U(xe.id, !1);
|
|
7169
7169
|
}
|
|
7170
7170
|
}), pe && !be && (be = !0, queueMicrotask(ke));
|
|
7171
7171
|
}), T(({ edge: B }) => {
|
|
@@ -7192,8 +7192,8 @@ const [z1, G1] = cl(
|
|
|
7192
7192
|
function K(B) {
|
|
7193
7193
|
const z = j.value.filter(({ type: tt }) => tt !== "group"), pe = z.find(({ id: tt }) => tt === B);
|
|
7194
7194
|
if (!pe) throw new Error(`Node ${B} not found`);
|
|
7195
|
-
const { x:
|
|
7196
|
-
let Pe =
|
|
7195
|
+
const { x: xe, y: Te } = pe.data.position, { width: Ne, height: De } = pe.dimensions, We = Te, Ge = Te + De, Fe = z.filter(({ id: tt }) => tt !== B).filter(({ data: { position: { y: tt } }, dimensions: { height: Mt } }) => tt < Ge && tt + Mt > We).map(({ data: { position: { x: tt } }, dimensions: { width: Mt } }) => ({ left: tt, right: tt + Mt })).sort((tt, Mt) => tt.left - Mt.left);
|
|
7196
|
+
let Pe = xe + Ne + s;
|
|
7197
7197
|
for (const { left: tt, right: Mt } of Fe)
|
|
7198
7198
|
if (!(Mt <= Pe)) {
|
|
7199
7199
|
if (Pe + Ne <= tt) return { x: Pe, y: We };
|
|
@@ -7207,8 +7207,8 @@ const [z1, G1] = cl(
|
|
|
7207
7207
|
if (!z) throw new Error(`Node ${B} not found`);
|
|
7208
7208
|
const {
|
|
7209
7209
|
position: { x: pe },
|
|
7210
|
-
dimensions: { width:
|
|
7211
|
-
} = z, Te = pe +
|
|
7210
|
+
dimensions: { width: xe }
|
|
7211
|
+
} = z, Te = pe + xe, { viewport: Ne, dimensions: De, setViewport: We } = d, { x: Ge, y: Fe, zoom: Pe } = Ne.value, { width: tt } = De.value, Mt = pe * Pe + Ge, jn = Te * Pe + Ge, Tt = tt - xd - s;
|
|
7212
7212
|
if (jn <= Tt) return;
|
|
7213
7213
|
let Xt = Tt - jn;
|
|
7214
7214
|
Mt + Xt < 0 && (Xt = -Mt), Xt !== 0 && We(
|
|
@@ -7218,15 +7218,15 @@ const [z1, G1] = cl(
|
|
|
7218
7218
|
}
|
|
7219
7219
|
function Ke(B) {
|
|
7220
7220
|
if (!_e.value) return !1;
|
|
7221
|
-
const { nodeId: z, branch: pe } = Qk(_e.value),
|
|
7222
|
-
return ee(void 0),
|
|
7221
|
+
const { nodeId: z, branch: pe } = Qk(_e.value), xe = se.addMember(z, pe, B, { commit: !1 });
|
|
7222
|
+
return ee(void 0), xe;
|
|
7223
7223
|
}
|
|
7224
7224
|
return {
|
|
7225
7225
|
vueFlowStore: d,
|
|
7226
7226
|
editorStore: f,
|
|
7227
7227
|
readonly: o,
|
|
7228
7228
|
nodes: fe,
|
|
7229
|
-
edges:
|
|
7229
|
+
edges: Ee,
|
|
7230
7230
|
selectNode: Me,
|
|
7231
7231
|
autoLayout: $e,
|
|
7232
7232
|
placeToRight: K,
|
|
@@ -13823,7 +13823,7 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
13823
13823
|
let ye;
|
|
13824
13824
|
const Ke = g.anchor;
|
|
13825
13825
|
let ae, B, z, pe;
|
|
13826
|
-
const
|
|
13826
|
+
const xe = /* @__PURE__ */ Object.create(null);
|
|
13827
13827
|
let Te, Ne, De, We = g.input.charCodeAt(g.position);
|
|
13828
13828
|
if (We === 91)
|
|
13829
13829
|
ae = 93, pe = !1, ye = [];
|
|
@@ -13833,7 +13833,7 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
13833
13833
|
for (g.anchor !== null && M(g, g.anchor, ye), We = g.input.charCodeAt(++g.position); We !== 0; ) {
|
|
13834
13834
|
if (ce(g, !0, Z), We = g.input.charCodeAt(g.position), We === ae)
|
|
13835
13835
|
return g.position++, g.tag = K, g.anchor = Ke, g.kind = pe ? "mapping" : "sequence", g.result = ye, !0;
|
|
13836
|
-
be ? We === 44 && q(g, "expected the node content, but found ','") : q(g, "missed comma between flow collection entries"), Ne = Te = De = null, B = z = !1, We === 63 && w(g.input.charCodeAt(g.position + 1)) && (B = z = !0, g.position++, ce(g, !0, Z)), ke = g.line, me = g.lineStart, Me = g.position, le(g, Z, l, !1, !0), Ne = g.tag, Te = g.result, ce(g, !0, Z), We = g.input.charCodeAt(g.position), (z || g.line === ke) && We === 58 && (B = !0, We = g.input.charCodeAt(++g.position), ce(g, !0, Z), le(g, Z, l, !1, !0), De = g.result), pe ? he(g, ye,
|
|
13836
|
+
be ? We === 44 && q(g, "expected the node content, but found ','") : q(g, "missed comma between flow collection entries"), Ne = Te = De = null, B = z = !1, We === 63 && w(g.input.charCodeAt(g.position + 1)) && (B = z = !0, g.position++, ce(g, !0, Z)), ke = g.line, me = g.lineStart, Me = g.position, le(g, Z, l, !1, !0), Ne = g.tag, Te = g.result, ce(g, !0, Z), We = g.input.charCodeAt(g.position), (z || g.line === ke) && We === 58 && (B = !0, We = g.input.charCodeAt(++g.position), ce(g, !0, Z), le(g, Z, l, !1, !0), De = g.result), pe ? he(g, ye, xe, Ne, Te, De, ke, me, Me) : B ? ye.push(he(g, null, xe, Ne, Te, De, ke, me, Me)) : ye.push(Te), ce(g, !0, Z), We = g.input.charCodeAt(g.position), We === 44 ? (be = !0, We = g.input.charCodeAt(++g.position)) : be = !1;
|
|
13837
13837
|
}
|
|
13838
13838
|
q(g, "unexpected end of the stream within a flow collection");
|
|
13839
13839
|
}
|
|
@@ -13898,7 +13898,7 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
13898
13898
|
function Se(g, Z, be) {
|
|
13899
13899
|
let ke, me, Me, K;
|
|
13900
13900
|
const ye = g.tag, Ke = g.anchor, ae = {}, B = /* @__PURE__ */ Object.create(null);
|
|
13901
|
-
let z = null, pe = null,
|
|
13901
|
+
let z = null, pe = null, xe = null, Te = !1, Ne = !1;
|
|
13902
13902
|
if (g.firstTabInLine !== -1) return !1;
|
|
13903
13903
|
g.anchor !== null && M(g, g.anchor, ae);
|
|
13904
13904
|
let De = g.input.charCodeAt(g.position);
|
|
@@ -13906,13 +13906,13 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
13906
13906
|
!Te && g.firstTabInLine !== -1 && (g.position = g.firstTabInLine, q(g, "tab characters must not be used in indentation"));
|
|
13907
13907
|
const We = g.input.charCodeAt(g.position + 1), Ge = g.line;
|
|
13908
13908
|
if ((De === 63 || De === 58) && w(We))
|
|
13909
|
-
De === 63 ? (Te && (he(g, ae, B, z, pe, null, me, Me, K), z = pe =
|
|
13909
|
+
De === 63 ? (Te && (he(g, ae, B, z, pe, null, me, Me, K), z = pe = xe = null), Ne = !0, Te = !0, ke = !0) : Te ? (Te = !1, ke = !0) : q(g, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), g.position += 1, De = We;
|
|
13910
13910
|
else {
|
|
13911
13911
|
if (me = g.line, Me = g.lineStart, K = g.position, !le(g, be, s, !1, !0)) break;
|
|
13912
13912
|
if (g.line === Ge) {
|
|
13913
13913
|
for (De = g.input.charCodeAt(g.position); k(De); ) De = g.input.charCodeAt(++g.position);
|
|
13914
13914
|
if (De === 58)
|
|
13915
|
-
De = g.input.charCodeAt(++g.position), w(De) || q(g, "a whitespace character is expected after the key-value separator within a block mapping"), Te && (he(g, ae, B, z, pe, null, me, Me, K), z = pe =
|
|
13915
|
+
De = g.input.charCodeAt(++g.position), w(De) || q(g, "a whitespace character is expected after the key-value separator within a block mapping"), Te && (he(g, ae, B, z, pe, null, me, Me, K), z = pe = xe = null), Ne = !0, Te = !1, ke = !1, z = g.tag, pe = g.result;
|
|
13916
13916
|
else if (Ne) q(g, "can not read an implicit mapping pair; a colon is missed");
|
|
13917
13917
|
else
|
|
13918
13918
|
return g.tag = ye, g.anchor = Ke, !0;
|
|
@@ -13920,12 +13920,12 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
13920
13920
|
else
|
|
13921
13921
|
return g.tag = ye, g.anchor = Ke, !0;
|
|
13922
13922
|
}
|
|
13923
|
-
if ((g.line === Ge || g.lineIndent > Z) && (Te && (me = g.line, Me = g.lineStart, K = g.position), le(g, Z, f, !0, ke) && (Te ? pe = g.result :
|
|
13923
|
+
if ((g.line === Ge || g.lineIndent > Z) && (Te && (me = g.line, Me = g.lineStart, K = g.position), le(g, Z, f, !0, ke) && (Te ? pe = g.result : xe = g.result), Te || (he(g, ae, B, z, pe, xe, me, Me, K), z = pe = xe = null), ce(g, !0, -1), De = g.input.charCodeAt(g.position)), (g.line === Ge || g.lineIndent > Z) && De !== 0) q(g, "bad indentation of a mapping entry");
|
|
13924
13924
|
else if (g.lineIndent < Z) break;
|
|
13925
13925
|
}
|
|
13926
13926
|
return Te && he(g, ae, B, z, pe, null, me, Me, K), Ne && (g.tag = ye, g.anchor = Ke, g.kind = "mapping", g.result = ae), Ne;
|
|
13927
13927
|
}
|
|
13928
|
-
function
|
|
13928
|
+
function Ce(g) {
|
|
13929
13929
|
let Z = !1, be = !1, ke, me, Me = g.input.charCodeAt(g.position);
|
|
13930
13930
|
if (Me !== 33) return !1;
|
|
13931
13931
|
g.tag !== null && q(g, "duplication of a tag property"), Me = g.input.charCodeAt(++g.position), Me === 60 ? (Z = !0, Me = g.input.charCodeAt(++g.position)) : Me === 33 ? (be = !0, ke = "!!", Me = g.input.charCodeAt(++g.position)) : ke = "!";
|
|
@@ -13971,21 +13971,21 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
13971
13971
|
return U(g), $(g, Z), g.tag = null, g.anchor = null, g.kind = null, g.result = null, Se(g, be, ke) && g.kind === "mapping" ? (H(g), !0) : (se(g), $(g, me), !1);
|
|
13972
13972
|
}
|
|
13973
13973
|
function le(g, Z, be, ke, me) {
|
|
13974
|
-
let Me, K, ye = 1, Ke = !1, ae = !1, B = null, z, pe,
|
|
13974
|
+
let Me, K, ye = 1, Ke = !1, ae = !1, B = null, z, pe, xe;
|
|
13975
13975
|
g.depth >= g.maxDepth && q(g, "nesting exceeded maxDepth (" + g.maxDepth + ")"), g.depth += 1, g.listener !== null && g.listener("open", g), g.tag = null, g.anchor = null, g.kind = null, g.result = null;
|
|
13976
13976
|
const Te = Me = K = f === be || d === be;
|
|
13977
13977
|
if (ke && ce(g, !0, -1) && (Ke = !0, g.lineIndent > Z ? ye = 1 : g.lineIndent === Z ? ye = 0 : g.lineIndent < Z && (ye = -1)), ye === 1) for (; ; ) {
|
|
13978
13978
|
const Ne = g.input.charCodeAt(g.position), De = F(g);
|
|
13979
|
-
if (Ke && (Ne === 33 && g.tag !== null || Ne === 38 && g.anchor !== null) || !
|
|
13979
|
+
if (Ke && (Ne === 33 && g.tag !== null || Ne === 38 && g.anchor !== null) || !Ce(g) && !_e(g)) break;
|
|
13980
13980
|
B === null && (B = De), ce(g, !0, -1) ? (Ke = !0, K = Te, g.lineIndent > Z ? ye = 1 : g.lineIndent === Z ? ye = 0 : g.lineIndent < Z && (ye = -1)) : K = !1;
|
|
13981
13981
|
}
|
|
13982
13982
|
if (K && (K = Ke || me), ye === 1 || f === be)
|
|
13983
|
-
if (l === be || s === be ? pe = Z : pe = Z + 1,
|
|
13983
|
+
if (l === be || s === be ? pe = Z : pe = Z + 1, xe = g.position - g.lineStart, ye === 1) if (K && (Ue(g, xe) || Se(g, xe, pe)) || Je(g, pe)) ae = !0;
|
|
13984
13984
|
else {
|
|
13985
13985
|
const Ne = g.input.charCodeAt(g.position);
|
|
13986
13986
|
B !== null && Te && !K && Ne !== 124 && Ne !== 62 && ee(g, B, B.position - B.lineStart, pe) || Me && at(g, pe) || qe(g, pe) || He(g, pe) ? ae = !0 : oe(g) ? (ae = !0, (g.tag !== null || g.anchor !== null) && q(g, "alias node should not have any properties")) : Be(g, pe, l === be) && (ae = !0, g.tag === null && (g.tag = "?")), g.anchor !== null && M(g, g.anchor, g.result);
|
|
13987
13987
|
}
|
|
13988
|
-
else ye === 0 && (ae = K && Ue(g,
|
|
13988
|
+
else ye === 0 && (ae = K && Ue(g, xe));
|
|
13989
13989
|
if (g.tag === null)
|
|
13990
13990
|
g.anchor !== null && M(g, g.anchor, g.result);
|
|
13991
13991
|
else if (g.tag === "?") {
|
|
@@ -14046,7 +14046,7 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14046
14046
|
for (; be.position < be.length - 1; ) fe(be);
|
|
14047
14047
|
return be.documents;
|
|
14048
14048
|
}
|
|
14049
|
-
function
|
|
14049
|
+
function Ee(g, Z, be) {
|
|
14050
14050
|
Z !== null && typeof Z == "object" && typeof be > "u" && (be = Z, Z = null);
|
|
14051
14051
|
const ke = Ae(g, be);
|
|
14052
14052
|
if (typeof Z != "function") return ke;
|
|
@@ -14059,7 +14059,7 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14059
14059
|
throw new i("expected a single document in the stream, but found more");
|
|
14060
14060
|
}
|
|
14061
14061
|
}
|
|
14062
|
-
t.exports.loadAll =
|
|
14062
|
+
t.exports.loadAll = Ee, t.exports.load = $e;
|
|
14063
14063
|
}), lS = /* @__PURE__ */ Nt((e, t) => {
|
|
14064
14064
|
var n = Oa(), i = Na(), o = zl(), r = Object.prototype.toString, a = Object.prototype.hasOwnProperty, l = 65279, s = 9, d = 10, f = 13, c = 32, p = 33, m = 34, h = 35, y = 37, _ = 38, v = 39, b = 42, E = 44, A = 45, k = 58, w = 61, T = 62, P = 63, j = 64, S = 91, x = 93, O = 96, R = 123, D = 124, W = 125, X = {};
|
|
14065
14065
|
X[0] = "\\0", X[7] = "\\a", X[8] = "\\b", X[9] = "\\t", X[10] = "\\n", X[11] = "\\v", X[12] = "\\f", X[13] = "\\r", X[27] = "\\e", X[34] = '\\"', X[92] = "\\\\", X[133] = "\\N", X[160] = "\\_", X[8232] = "\\L", X[8233] = "\\P";
|
|
@@ -14085,10 +14085,10 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14085
14085
|
if (ye === null) return {};
|
|
14086
14086
|
const Ke = {}, ae = Object.keys(ye);
|
|
14087
14087
|
for (let B = 0, z = ae.length; B < z; B += 1) {
|
|
14088
|
-
let pe = ae[B],
|
|
14088
|
+
let pe = ae[B], xe = String(ye[pe]);
|
|
14089
14089
|
pe.slice(0, 2) === "!!" && (pe = "tag:yaml.org,2002:" + pe.slice(2));
|
|
14090
14090
|
const Te = K.compiledTypeMap.fallback[pe];
|
|
14091
|
-
Te && a.call(Te.styleAliases,
|
|
14091
|
+
Te && a.call(Te.styleAliases, xe) && (xe = Te.styleAliases[xe]), Ke[pe] = xe;
|
|
14092
14092
|
}
|
|
14093
14093
|
return Ke;
|
|
14094
14094
|
}
|
|
@@ -14114,9 +14114,9 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14114
14114
|
const z = K.length;
|
|
14115
14115
|
for (; ae < z; ) {
|
|
14116
14116
|
let pe;
|
|
14117
|
-
const
|
|
14117
|
+
const xe = K.indexOf(`
|
|
14118
14118
|
`, ae);
|
|
14119
|
-
|
|
14119
|
+
xe === -1 ? (pe = K.slice(ae), ae = z) : (pe = K.slice(ae, xe + 1), ae = xe + 1), pe.length && pe !== `
|
|
14120
14120
|
` && (B += Ke), B += pe;
|
|
14121
14121
|
}
|
|
14122
14122
|
return B;
|
|
@@ -14157,35 +14157,35 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14157
14157
|
return /^\n* /.test(K);
|
|
14158
14158
|
}
|
|
14159
14159
|
var qe = 1, He = 2, Je = 3, at = 4, Ue = 5;
|
|
14160
|
-
function Se(K, ye, Ke, ae, B, z, pe,
|
|
14160
|
+
function Se(K, ye, Ke, ae, B, z, pe, xe) {
|
|
14161
14161
|
let Te, Ne = 0, De = null, We = !1, Ge = !1;
|
|
14162
14162
|
const Fe = ae !== -1;
|
|
14163
14163
|
let Pe = -1, tt = ce(je(K, 0)) && ve(je(K, K.length - 1));
|
|
14164
14164
|
if (ye || pe) for (Te = 0; Te < K.length; Ne >= 65536 ? Te += 2 : Te++) {
|
|
14165
14165
|
if (Ne = je(K, Te), !ne(Ne)) return Ue;
|
|
14166
|
-
tt = tt && we(Ne, De,
|
|
14166
|
+
tt = tt && we(Ne, De, xe), De = Ne;
|
|
14167
14167
|
}
|
|
14168
14168
|
else {
|
|
14169
14169
|
for (Te = 0; Te < K.length; Ne >= 65536 ? Te += 2 : Te++) {
|
|
14170
14170
|
if (Ne = je(K, Te), Ne === d)
|
|
14171
14171
|
We = !0, Fe && (Ge = Ge || Te - Pe - 1 > ae && K[Pe + 1] !== " ", Pe = Te);
|
|
14172
14172
|
else if (!ne(Ne)) return Ue;
|
|
14173
|
-
tt = tt && we(Ne, De,
|
|
14173
|
+
tt = tt && we(Ne, De, xe), De = Ne;
|
|
14174
14174
|
}
|
|
14175
14175
|
Ge = Ge || Fe && Te - Pe - 1 > ae && K[Pe + 1] !== " ";
|
|
14176
14176
|
}
|
|
14177
14177
|
return !We && !Ge ? tt && !pe && !B(K) ? qe : z === H ? Ue : He : Ke > 9 && Be(K) ? Ue : pe ? z === H ? Ue : He : Ge ? at : Je;
|
|
14178
14178
|
}
|
|
14179
|
-
function
|
|
14179
|
+
function Ce(K, ye, Ke, ae, B) {
|
|
14180
14180
|
K.dump = function() {
|
|
14181
14181
|
if (ye.length === 0) return K.quotingType === H ? '""' : "''";
|
|
14182
14182
|
if (!K.noCompatMode && (J.indexOf(ye) !== -1 || q.test(ye)))
|
|
14183
14183
|
return K.quotingType === H ? '"' + ye + '"' : "'" + ye + "'";
|
|
14184
|
-
const z = K.indent * Math.max(1, Ke), pe = K.lineWidth === -1 ? -1 : Math.max(Math.min(K.lineWidth, 40), K.lineWidth - z),
|
|
14184
|
+
const z = K.indent * Math.max(1, Ke), pe = K.lineWidth === -1 ? -1 : Math.max(Math.min(K.lineWidth, 40), K.lineWidth - z), xe = ae || K.flowLevel > -1 && Ke >= K.flowLevel;
|
|
14185
14185
|
function Te(Ne) {
|
|
14186
14186
|
return V(K, Ne);
|
|
14187
14187
|
}
|
|
14188
|
-
switch (Se(ye,
|
|
14188
|
+
switch (Se(ye, xe, K.indent, pe, Te, K.quotingType, K.forceQuotes && !ae, B)) {
|
|
14189
14189
|
case qe:
|
|
14190
14190
|
return ye;
|
|
14191
14191
|
case He:
|
|
@@ -14216,14 +14216,14 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14216
14216
|
function ee(K, ye) {
|
|
14217
14217
|
const Ke = /(\n+)([^\n]*)/g;
|
|
14218
14218
|
let ae = function() {
|
|
14219
|
-
let
|
|
14219
|
+
let xe = K.indexOf(`
|
|
14220
14220
|
`);
|
|
14221
|
-
return
|
|
14221
|
+
return xe = xe !== -1 ? xe : K.length, Ke.lastIndex = xe, le(K.slice(0, xe), ye);
|
|
14222
14222
|
}(), B = K[0] === `
|
|
14223
14223
|
` || K[0] === " ", z, pe;
|
|
14224
14224
|
for (; pe = Ke.exec(K); ) {
|
|
14225
|
-
const
|
|
14226
|
-
z = Te[0] === " ", ae +=
|
|
14225
|
+
const xe = pe[1], Te = pe[2];
|
|
14226
|
+
z = Te[0] === " ", ae += xe + (!B && !z && Te !== "" ? `
|
|
14227
14227
|
` : "") + le(Te, ye), B = z;
|
|
14228
14228
|
}
|
|
14229
14229
|
return ae;
|
|
@@ -14231,10 +14231,10 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14231
14231
|
function le(K, ye) {
|
|
14232
14232
|
if (K === "" || K[0] === " ") return K;
|
|
14233
14233
|
const Ke = / [^ ]/g;
|
|
14234
|
-
let ae, B = 0, z, pe = 0,
|
|
14234
|
+
let ae, B = 0, z, pe = 0, xe = 0, Te = "";
|
|
14235
14235
|
for (; ae = Ke.exec(K); )
|
|
14236
|
-
|
|
14237
|
-
` + K.slice(B, z), B = z + 1), pe =
|
|
14236
|
+
xe = ae.index, xe - B > ye && (z = pe > B ? pe : xe, Te += `
|
|
14237
|
+
` + K.slice(B, z), B = z + 1), pe = xe;
|
|
14238
14238
|
return Te += `
|
|
14239
14239
|
`, K.length - B > ye && pe > B ? Te += K.slice(B, pe) + `
|
|
14240
14240
|
` + K.slice(pe + 1) : Te += K.slice(B), Te.slice(1);
|
|
@@ -14252,15 +14252,15 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14252
14252
|
let ae = "";
|
|
14253
14253
|
const B = K.tag;
|
|
14254
14254
|
for (let z = 0, pe = Ke.length; z < pe; z += 1) {
|
|
14255
|
-
let
|
|
14256
|
-
K.replacer && (
|
|
14255
|
+
let xe = Ke[z];
|
|
14256
|
+
K.replacer && (xe = K.replacer.call(Ke, String(z), xe)), (be(K, ye, xe, !1, !1) || typeof xe > "u" && be(K, ye, null, !1, !1)) && (ae !== "" && (ae += "," + (K.condenseFlow ? "" : " ")), ae += K.dump);
|
|
14257
14257
|
}
|
|
14258
14258
|
K.tag = B, K.dump = "[" + ae + "]";
|
|
14259
14259
|
}
|
|
14260
|
-
function
|
|
14260
|
+
function Ee(K, ye, Ke, ae) {
|
|
14261
14261
|
let B = "";
|
|
14262
14262
|
const z = K.tag;
|
|
14263
|
-
for (let pe = 0,
|
|
14263
|
+
for (let pe = 0, xe = Ke.length; pe < xe; pe += 1) {
|
|
14264
14264
|
let Te = Ke[pe];
|
|
14265
14265
|
K.replacer && (Te = K.replacer.call(Ke, String(pe), Te)), (be(K, ye + 1, Te, !0, !0, !1, !0) || typeof Te > "u" && be(K, ye + 1, null, !0, !0, !1, !0)) && ((!ae || B !== "") && (B += $(K, ye)), K.dump && d === K.dump.charCodeAt(0) ? B += "-" : B += "- ", B += K.dump);
|
|
14266
14266
|
}
|
|
@@ -14269,7 +14269,7 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14269
14269
|
function $e(K, ye, Ke) {
|
|
14270
14270
|
let ae = "";
|
|
14271
14271
|
const B = K.tag, z = Object.keys(Ke);
|
|
14272
|
-
for (let pe = 0,
|
|
14272
|
+
for (let pe = 0, xe = z.length; pe < xe; pe += 1) {
|
|
14273
14273
|
let Te = "";
|
|
14274
14274
|
ae !== "" && (Te += ", "), K.condenseFlow && (Te += '"');
|
|
14275
14275
|
const Ne = z[pe];
|
|
@@ -14284,10 +14284,10 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14284
14284
|
if (K.sortKeys === !0) pe.sort();
|
|
14285
14285
|
else if (typeof K.sortKeys == "function") pe.sort(K.sortKeys);
|
|
14286
14286
|
else if (K.sortKeys) throw new i("sortKeys must be a boolean or a function");
|
|
14287
|
-
for (let
|
|
14287
|
+
for (let xe = 0, Te = pe.length; xe < Te; xe += 1) {
|
|
14288
14288
|
let Ne = "";
|
|
14289
14289
|
(!ae || B !== "") && (Ne += $(K, ye));
|
|
14290
|
-
const De = pe[
|
|
14290
|
+
const De = pe[xe];
|
|
14291
14291
|
let We = Ke[De];
|
|
14292
14292
|
if (K.replacer && (We = K.replacer.call(Ke, De, We)), !be(K, ye + 1, De, !0, !0, !0)) continue;
|
|
14293
14293
|
const Ge = K.tag !== null && K.tag !== "?" || K.dump && K.dump.length > 1024;
|
|
@@ -14301,11 +14301,11 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14301
14301
|
const pe = ae[B];
|
|
14302
14302
|
if ((pe.instanceOf || pe.predicate) && (!pe.instanceOf || typeof ye == "object" && ye instanceof pe.instanceOf) && (!pe.predicate || pe.predicate(ye))) {
|
|
14303
14303
|
if (Ke ? pe.multi && pe.representName ? K.tag = pe.representName(ye) : K.tag = pe.tag : K.tag = "?", pe.represent) {
|
|
14304
|
-
const
|
|
14304
|
+
const xe = K.styleMap[pe.tag] || pe.defaultStyle;
|
|
14305
14305
|
let Te;
|
|
14306
|
-
if (r.call(pe.represent) === "[object Function]") Te = pe.represent(ye,
|
|
14307
|
-
else if (a.call(pe.represent,
|
|
14308
|
-
else throw new i("!<" + pe.tag + '> tag resolver accepts not "' +
|
|
14306
|
+
if (r.call(pe.represent) === "[object Function]") Te = pe.represent(ye, xe);
|
|
14307
|
+
else if (a.call(pe.represent, xe)) Te = pe.represent[xe](ye, xe);
|
|
14308
|
+
else throw new i("!<" + pe.tag + '> tag resolver accepts not "' + xe + '" style');
|
|
14309
14309
|
K.dump = Te;
|
|
14310
14310
|
}
|
|
14311
14311
|
return !0;
|
|
@@ -14315,20 +14315,20 @@ var Qx = Object.create, tf = Object.defineProperty, eS = Object.getOwnPropertyDe
|
|
|
14315
14315
|
}
|
|
14316
14316
|
function be(K, ye, Ke, ae, B, z, pe) {
|
|
14317
14317
|
K.tag = null, K.dump = Ke, Z(K, Ke, !1) || Z(K, Ke, !0);
|
|
14318
|
-
const
|
|
14318
|
+
const xe = r.call(K.dump), Te = ae;
|
|
14319
14319
|
ae && (ae = K.flowLevel < 0 || K.flowLevel > ye);
|
|
14320
|
-
const Ne =
|
|
14320
|
+
const Ne = xe === "[object Object]" || xe === "[object Array]";
|
|
14321
14321
|
let De, We;
|
|
14322
14322
|
if (Ne && (De = K.duplicates.indexOf(Ke), We = De !== -1), (K.tag !== null && K.tag !== "?" || We || K.indent !== 2 && ye > 0) && (B = !1), We && K.usedDuplicates[De]) K.dump = "*ref_" + De;
|
|
14323
14323
|
else {
|
|
14324
|
-
if (Ne && We && !K.usedDuplicates[De] && (K.usedDuplicates[De] = !0),
|
|
14325
|
-
else if (
|
|
14326
|
-
else if (
|
|
14327
|
-
K.tag !== "?" &&
|
|
14324
|
+
if (Ne && We && !K.usedDuplicates[De] && (K.usedDuplicates[De] = !0), xe === "[object Object]") ae && Object.keys(K.dump).length !== 0 ? (g(K, ye, K.dump, B), We && (K.dump = "&ref_" + De + K.dump)) : ($e(K, ye, K.dump), We && (K.dump = "&ref_" + De + " " + K.dump));
|
|
14325
|
+
else if (xe === "[object Array]") ae && K.dump.length !== 0 ? (K.noArrayIndent && !pe && ye > 0 ? Ee(K, ye - 1, K.dump, B) : Ee(K, ye, K.dump, B), We && (K.dump = "&ref_" + De + K.dump)) : (Ae(K, ye, K.dump), We && (K.dump = "&ref_" + De + " " + K.dump));
|
|
14326
|
+
else if (xe === "[object String]")
|
|
14327
|
+
K.tag !== "?" && Ce(K, K.dump, ye, z, Te);
|
|
14328
14328
|
else {
|
|
14329
|
-
if (
|
|
14329
|
+
if (xe === "[object Undefined]") return !1;
|
|
14330
14330
|
if (K.skipInvalid) return !1;
|
|
14331
|
-
throw new i("unacceptable kind of an object to dump " +
|
|
14331
|
+
throw new i("unacceptable kind of an object to dump " + xe);
|
|
14332
14332
|
}
|
|
14333
14333
|
if (K.tag !== null && K.tag !== "?") {
|
|
14334
14334
|
let Ge = encodeURI(K.tag[0] === "!" ? K.tag.slice(1) : K.tag).replace(/!/g, "%21");
|
|
@@ -21784,7 +21784,7 @@ const fT = { class: "label-content" }, mT = { class: "count" }, gT = { class: "l
|
|
|
21784
21784
|
at();
|
|
21785
21785
|
return;
|
|
21786
21786
|
}
|
|
21787
|
-
Se.some((
|
|
21787
|
+
Se.some((Ce) => Ce.type === "select") && He.value.length + Je.value.length > 0 && at();
|
|
21788
21788
|
}
|
|
21789
21789
|
Be(Ue), qe(Ue), je(() => Ue());
|
|
21790
21790
|
}
|
|
@@ -29025,7 +29025,7 @@ const ut = {
|
|
|
29025
29025
|
}
|
|
29026
29026
|
};
|
|
29027
29027
|
return (ce, ve) => {
|
|
29028
|
-
const je = Ie("KSkeleton"), Be = Ie("KEmptyState"), qe = Ie("KRadio"), He = Ie("KCollapse"), Je = Ie("KFileUpload"), at = Ie("KLabel"), Ue = Ie("KAlert"), Se = Ie("KSelect"),
|
|
29028
|
+
const je = Ie("KSkeleton"), Be = Ie("KEmptyState"), qe = Ie("KRadio"), He = Ie("KCollapse"), Je = Ie("KFileUpload"), at = Ie("KLabel"), Ue = Ie("KAlert"), Se = Ie("KSelect"), Ce = Ie("KInput"), _e = Ie("KButton");
|
|
29029
29029
|
return I(), re("div", q2, [
|
|
29030
29030
|
C(u(dd), {
|
|
29031
29031
|
ref_key: "entityBaseFormRef",
|
|
@@ -29371,7 +29371,7 @@ const ut = {
|
|
|
29371
29371
|
title: u(a)("custom_plugin_form.step3.title")
|
|
29372
29372
|
}, {
|
|
29373
29373
|
default: N(() => [
|
|
29374
|
-
C(
|
|
29374
|
+
C(Ce, {
|
|
29375
29375
|
modelValue: M.fields.name,
|
|
29376
29376
|
"onUpdate:modelValue": ve[11] || (ve[11] = (oe) => M.fields.name = oe),
|
|
29377
29377
|
modelModifiers: { trim: !0 },
|
|
@@ -29394,7 +29394,7 @@ const ut = {
|
|
|
29394
29394
|
title: u(a)("custom_plugin_form.step3.title")
|
|
29395
29395
|
}, {
|
|
29396
29396
|
default: N(() => [
|
|
29397
|
-
C(
|
|
29397
|
+
C(Ce, {
|
|
29398
29398
|
modelValue: M.fields.aliasName,
|
|
29399
29399
|
"onUpdate:modelValue": ve[12] || (ve[12] = (oe) => M.fields.aliasName = oe),
|
|
29400
29400
|
modelModifiers: { trim: !0 },
|
|
@@ -29406,7 +29406,7 @@ const ut = {
|
|
|
29406
29406
|
required: "",
|
|
29407
29407
|
type: "text"
|
|
29408
29408
|
}, null, 8, ["modelValue", "help", "label", "placeholder", "readonly"]),
|
|
29409
|
-
C(
|
|
29409
|
+
C(Ce, {
|
|
29410
29410
|
modelValue: M.fields.priority,
|
|
29411
29411
|
"onUpdate:modelValue": ve[13] || (ve[13] = (oe) => M.fields.priority = oe),
|
|
29412
29412
|
modelModifiers: { trim: !0 },
|
|
@@ -29802,57 +29802,57 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
29802
29802
|
}), { convertToDotNotation: d, unFlattenObject: f, dismissField: c, isObjectEmpty: p, unsetNullForeignKey: m } = ut.usePluginHelpers(), { shouldUseFreeForm: h, getFreeFormComponent: y } = ut.useFreeFormResolver(), _ = ft(pl), v = (Se) => {
|
|
29803
29803
|
_ && (_.value = Se);
|
|
29804
29804
|
}, { objectsAreEqual: b } = xa(), { i18n: { t: E } } = nt(), A = (Se) => {
|
|
29805
|
-
let
|
|
29806
|
-
return i.config.app === "konnect" && (
|
|
29807
|
-
}, k = (Se,
|
|
29805
|
+
let Ce = Se;
|
|
29806
|
+
return i.config.app === "konnect" && (Ce = Ce.replace(/{controlPlaneId}/gi, i.config.controlPlaneId || "")), Ce.replace(/\/{workspace}/gi, i.config.workspace ? `/${i.config.workspace}` : "");
|
|
29807
|
+
}, k = (Se, Ce) => {
|
|
29808
29808
|
let _e = `${i.config.apiBaseUrl}${it.form[i.config.app].entityGetOne}`;
|
|
29809
|
-
return _e = A(_e), _e = _e.replace(/{entity}/gi, Se), _e = _e.replace(/{id}/gi,
|
|
29809
|
+
return _e = A(_e), _e = _e.replace(/{entity}/gi, Se), _e = _e.replace(/{id}/gi, Ce), _e;
|
|
29810
29810
|
}, w = (Se) => {
|
|
29811
|
-
let
|
|
29812
|
-
return
|
|
29811
|
+
let Ce = `${i.config.apiBaseUrl}${it.form[i.config.app].entityGetAll}`;
|
|
29812
|
+
return Ce = A(Ce), Ce = Ce.replace(/{entity}/gi, Se), Ce;
|
|
29813
29813
|
};
|
|
29814
29814
|
Kt(md, {
|
|
29815
|
-
getOne: (Se,
|
|
29816
|
-
const oe = k(Se,
|
|
29815
|
+
getOne: (Se, Ce, _e) => {
|
|
29816
|
+
const oe = k(Se, Ce);
|
|
29817
29817
|
return l.get(oe, _e);
|
|
29818
29818
|
},
|
|
29819
|
-
getAll: (Se,
|
|
29819
|
+
getAll: (Se, Ce) => {
|
|
29820
29820
|
const _e = w(Se);
|
|
29821
29821
|
return i.config.app === "konnect" ? l.get(_e).then((oe) => {
|
|
29822
29822
|
const { data: { data: ee } } = oe;
|
|
29823
|
-
if (delete
|
|
29824
|
-
const le = Object.keys(
|
|
29823
|
+
if (delete Ce.size, delete Ce.offset, ee.length && Object.keys(Ce).length === 1) {
|
|
29824
|
+
const le = Object.keys(Ce)[0], fe = ee.filter((Ae) => Ae[le] ? !!Ae[le].toLowerCase().includes(Ce[le].toLowerCase()) : !1);
|
|
29825
29825
|
oe.data.data = fe;
|
|
29826
29826
|
}
|
|
29827
29827
|
return oe;
|
|
29828
|
-
}) : l.get(_e, { params:
|
|
29828
|
+
}) : l.get(_e, { params: Ce });
|
|
29829
29829
|
},
|
|
29830
|
-
getAllV2: (Se,
|
|
29830
|
+
getAllV2: (Se, Ce, _e) => {
|
|
29831
29831
|
const oe = w(Se);
|
|
29832
29832
|
if (i.config.app === "konnect") {
|
|
29833
|
-
const { size: ee, offset: le, ...fe } =
|
|
29833
|
+
const { size: ee, offset: le, ...fe } = Ce;
|
|
29834
29834
|
if (Se === "consumer_groups")
|
|
29835
29835
|
return l.get(oe, {
|
|
29836
29836
|
params: {
|
|
29837
29837
|
size: 1e3
|
|
29838
29838
|
},
|
|
29839
29839
|
signal: _e
|
|
29840
|
-
}).then((
|
|
29841
|
-
const { data: { data: $e } } =
|
|
29840
|
+
}).then((Ee) => {
|
|
29841
|
+
const { data: { data: $e } } = Ee;
|
|
29842
29842
|
if ($e.length && Object.keys(fe).length === 1) {
|
|
29843
29843
|
const g = Object.keys(fe)[0], Z = $e.filter((be) => be[g] ? !!be[g].toLowerCase().includes(fe[g].toLowerCase()) : !1);
|
|
29844
|
-
|
|
29844
|
+
Ee.data.data = Z;
|
|
29845
29845
|
}
|
|
29846
|
-
return
|
|
29846
|
+
return Ee;
|
|
29847
29847
|
});
|
|
29848
29848
|
const Ae = {
|
|
29849
29849
|
size: ee,
|
|
29850
29850
|
offset: le
|
|
29851
29851
|
};
|
|
29852
|
-
for (const
|
|
29852
|
+
for (const Ee of Object.keys(fe))
|
|
29853
29853
|
Ae.filter = {
|
|
29854
|
-
[
|
|
29855
|
-
contains: fe[
|
|
29854
|
+
[Ee]: {
|
|
29855
|
+
contains: fe[Ee]
|
|
29856
29856
|
}
|
|
29857
29857
|
};
|
|
29858
29858
|
return l.get(oe, {
|
|
@@ -29860,13 +29860,13 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
29860
29860
|
signal: _e
|
|
29861
29861
|
});
|
|
29862
29862
|
}
|
|
29863
|
-
return l.get(oe, { params:
|
|
29863
|
+
return l.get(oe, { params: Ce, signal: _e });
|
|
29864
29864
|
},
|
|
29865
|
-
peek: (Se,
|
|
29865
|
+
peek: (Se, Ce = 50) => {
|
|
29866
29866
|
const _e = w(Se);
|
|
29867
29867
|
return l.get(_e, {
|
|
29868
29868
|
params: {
|
|
29869
|
-
size:
|
|
29869
|
+
size: Ce
|
|
29870
29870
|
}
|
|
29871
29871
|
});
|
|
29872
29872
|
}
|
|
@@ -29880,38 +29880,38 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
29880
29880
|
i.rawSchema
|
|
29881
29881
|
);
|
|
29882
29882
|
return RR(Se);
|
|
29883
|
-
}), M = de(!1), U = de(), H = (Se,
|
|
29884
|
-
M.value = Se ?? "", U.value =
|
|
29883
|
+
}), M = de(!1), U = de(), H = (Se, Ce) => {
|
|
29884
|
+
M.value = Se ?? "", U.value = Ce;
|
|
29885
29885
|
}, se = (Se) => {
|
|
29886
|
-
var
|
|
29887
|
-
(
|
|
29886
|
+
var Ce;
|
|
29887
|
+
(Ce = U.value) == null || Ce.call(U, Se), M.value = !1;
|
|
29888
29888
|
}, F = (Se) => {
|
|
29889
29889
|
var _e;
|
|
29890
29890
|
if (!Se) {
|
|
29891
29891
|
O.value = void 0, R.value = void 0, x.value = "", v(!1);
|
|
29892
29892
|
return;
|
|
29893
29893
|
}
|
|
29894
|
-
const
|
|
29895
|
-
O.value = Om(
|
|
29894
|
+
const Ce = ((_e = i.schema) == null ? void 0 : _e._sourcePlugin) || Se;
|
|
29895
|
+
O.value = Om(Ce), R.value = h(Ce, i.engine) ? y(Ce) ?? cm : void 0, x.value = gd(Ce), v(!!R.value);
|
|
29896
29896
|
}, $ = (Se) => {
|
|
29897
|
-
var Ae,
|
|
29898
|
-
const
|
|
29897
|
+
var Ae, Ee;
|
|
29898
|
+
const Ce = { ...i.schema }, _e = J, oe = X, ee = Object.keys(_e), le = {};
|
|
29899
29899
|
if (!p(W.value))
|
|
29900
|
-
for (let $e = 0; $e < ((
|
|
29901
|
-
|
|
29900
|
+
for (let $e = 0; $e < ((Ee = (Ae = W.value) == null ? void 0 : Ae.fields) == null ? void 0 : Ee.length); $e++)
|
|
29901
|
+
Ce[W.value.fields[$e].model] = W.value.fields[$e];
|
|
29902
29902
|
Ts.forEach(($e) => {
|
|
29903
|
-
|
|
29903
|
+
Ce[$e] && (Ce[$e].fields.forEach((g) => {
|
|
29904
29904
|
g.fields && g.fields.forEach((Z) => {
|
|
29905
|
-
|
|
29906
|
-
}), g.model && (
|
|
29907
|
-
}), delete
|
|
29905
|
+
Ce[Z.model] = Z;
|
|
29906
|
+
}), g.model && (Ce[g.model] = g);
|
|
29907
|
+
}), delete Ce[$e]);
|
|
29908
29908
|
}), ee.forEach(($e) => {
|
|
29909
29909
|
var Ke;
|
|
29910
|
-
if (!
|
|
29910
|
+
if (!Ce[$e]) {
|
|
29911
29911
|
$e === "partials" && (le[$e] = _e[$e]);
|
|
29912
29912
|
return;
|
|
29913
29913
|
}
|
|
29914
|
-
const g =
|
|
29914
|
+
const g = Ce[$e];
|
|
29915
29915
|
let Z = _e[$e];
|
|
29916
29916
|
const be = oe[$e], ke = Array.isArray(Z) ? "array" : typeof Z, me = g ? g.valueType : null, Me = g ? g.valueArrayType : null, K = g ? g.transform : null;
|
|
29917
29917
|
if (Z == null && be == null && !g.submitWhenNull)
|
|
@@ -29978,16 +29978,16 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
29978
29978
|
Object.assign(fe, Be.value);
|
|
29979
29979
|
}
|
|
29980
29980
|
return fe;
|
|
29981
|
-
}, V = (Se,
|
|
29982
|
-
c(J,
|
|
29981
|
+
}, V = (Se, Ce = {}) => {
|
|
29982
|
+
c(J, Ce, Se, i.editing), n("model-updated", {
|
|
29983
29983
|
model: J,
|
|
29984
29984
|
originalModel: X,
|
|
29985
29985
|
data: $()
|
|
29986
29986
|
});
|
|
29987
|
-
}, ie = (Se,
|
|
29987
|
+
}, ie = (Se, Ce) => {
|
|
29988
29988
|
var ee;
|
|
29989
|
-
const _e = { [
|
|
29990
|
-
typeof ((ee = i.schema[
|
|
29989
|
+
const _e = { [Ce]: Se };
|
|
29990
|
+
typeof ((ee = i.schema[Ce]) == null ? void 0 : ee.modelTransformer) == "function" && (_e[Ce] = i.schema[Ce].modelTransformer(Se));
|
|
29991
29991
|
const oe = Object.assign({}, J, _e);
|
|
29992
29992
|
Object.assign(J, oe), n("model-updated", {
|
|
29993
29993
|
model: J,
|
|
@@ -29996,13 +29996,13 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
29996
29996
|
});
|
|
29997
29997
|
}, ne = (Se) => {
|
|
29998
29998
|
n("validity-change", Se);
|
|
29999
|
-
}, he = (Se,
|
|
29999
|
+
}, he = (Se, Ce) => {
|
|
30000
30000
|
Object.keys(Se).forEach((_e) => {
|
|
30001
|
-
var Ae,
|
|
30002
|
-
let oe =
|
|
30001
|
+
var Ae, Ee;
|
|
30002
|
+
let oe = Ce ? `${Ce}-${_e}` : _e, ee = i.schema[oe];
|
|
30003
30003
|
if (!ee) {
|
|
30004
|
-
const $e =
|
|
30005
|
-
(Ae = i.schema[$e]) != null && Ae.fieldNameHasDashes && (oe = $e, ee = i.schema[oe]),
|
|
30004
|
+
const $e = Ce ? `${Ce}-${_e.replace(/-/g, "_")}` : _e.replace(/-/g, "_");
|
|
30005
|
+
(Ae = i.schema[$e]) != null && Ae.fieldNameHasDashes && (oe = $e, ee = i.schema[oe]), Ce && ((Ee = i.schema[Ce]) == null ? void 0 : Ee.keyFromObject) === _e && (oe = Ce, ee = i.schema[oe]);
|
|
30006
30006
|
}
|
|
30007
30007
|
const le = Se[_e], fe = typeof le;
|
|
30008
30008
|
if (ee && ee.type === "object-advanced" && !le) {
|
|
@@ -30025,22 +30025,22 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30025
30025
|
originalModel: X,
|
|
30026
30026
|
data: $()
|
|
30027
30027
|
});
|
|
30028
|
-
}, we = (Se,
|
|
30029
|
-
if (!
|
|
30028
|
+
}, we = (Se, Ce) => {
|
|
30029
|
+
if (!Ce) return Se;
|
|
30030
30030
|
if (Array.isArray(Se)) {
|
|
30031
|
-
const ee =
|
|
30031
|
+
const ee = Ce.elements;
|
|
30032
30032
|
return ee ? Se.map((le) => we(le, ee)) : Se;
|
|
30033
30033
|
}
|
|
30034
30034
|
if (!Se || typeof Se != "object") return Se;
|
|
30035
|
-
if (
|
|
30036
|
-
const ee =
|
|
30035
|
+
if (Ce.type === "map" && Ce.values) {
|
|
30036
|
+
const ee = Ce.values, le = {};
|
|
30037
30037
|
for (const fe of Object.keys(Se))
|
|
30038
30038
|
le[fe] = we(Se[fe], ee);
|
|
30039
30039
|
return le;
|
|
30040
30040
|
}
|
|
30041
|
-
if (!Array.isArray(
|
|
30041
|
+
if (!Array.isArray(Ce.fields)) return Se;
|
|
30042
30042
|
const _e = /* @__PURE__ */ new Map();
|
|
30043
|
-
for (const ee of
|
|
30043
|
+
for (const ee of Ce.fields) {
|
|
30044
30044
|
const le = ee && Object.keys(ee)[0];
|
|
30045
30045
|
le && _e.set(le, ee[le]);
|
|
30046
30046
|
}
|
|
@@ -30054,23 +30054,23 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30054
30054
|
var _e;
|
|
30055
30055
|
const Se = (_e = i.rawSchema) == null ? void 0 : _e.fields;
|
|
30056
30056
|
if (!Array.isArray(Se)) return;
|
|
30057
|
-
const
|
|
30058
|
-
return
|
|
30057
|
+
const Ce = Se.find((oe) => oe == null ? void 0 : oe.config);
|
|
30058
|
+
return Ce == null ? void 0 : Ce.config;
|
|
30059
30059
|
}, ve = /* @__PURE__ */ new Set(["datakit"]), je = L(() => {
|
|
30060
30060
|
var Se;
|
|
30061
30061
|
return ((Se = i.schema) == null ? void 0 : Se._sourcePlugin) || J.name;
|
|
30062
|
-
}), Be = pn(i.record), qe = (Se,
|
|
30062
|
+
}), Be = pn(i.record), qe = (Se, Ce) => {
|
|
30063
30063
|
const _e = ve.has(je.value) ? Se : { ...Se, config: we(Se.config, ce()) };
|
|
30064
30064
|
Be.value = _e;
|
|
30065
30065
|
const oe = { ...J };
|
|
30066
|
-
for (const ee of
|
|
30066
|
+
for (const ee of Ce || [])
|
|
30067
30067
|
delete oe[ee];
|
|
30068
30068
|
n("model-updated", {
|
|
30069
30069
|
// config change should also update the form model
|
|
30070
30070
|
// otherwise the submit button will be disabled
|
|
30071
30071
|
model: { ...oe, ..._e },
|
|
30072
30072
|
originalModel: X,
|
|
30073
|
-
data: $(
|
|
30073
|
+
data: $(Ce)
|
|
30074
30074
|
});
|
|
30075
30075
|
}, He = de(!0), Je = () => {
|
|
30076
30076
|
var Se;
|
|
@@ -30088,35 +30088,35 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30088
30088
|
consumer_id: i.record.consumer_id || i.record.consumer,
|
|
30089
30089
|
consumer_group_id: i.record.consumer_group_id || i.record.consumer_group
|
|
30090
30090
|
}), i.record.partials && V("redis", { partials: i.record.partials }), R.value ? qe(i.record) : he(i.record.config, "config"))), Object.keys(i.entityMap).length && !i.entityMap.global && i.schema) {
|
|
30091
|
-
const
|
|
30091
|
+
const Ce = {};
|
|
30092
30092
|
for (const _e in i.entityMap) {
|
|
30093
30093
|
const oe = i.entityMap[_e].id, ee = i.entityMap[_e].idField, le = ee === "consumer_group_id" ? "consumer_group-id" : JSON.parse(JSON.stringify(ee).replace("_", "-"));
|
|
30094
|
-
Object.prototype.hasOwnProperty.call(J, le) && (
|
|
30094
|
+
Object.prototype.hasOwnProperty.call(J, le) && (Ce[le] = oe);
|
|
30095
30095
|
}
|
|
30096
|
-
he(
|
|
30096
|
+
he(Ce);
|
|
30097
30097
|
}
|
|
30098
30098
|
if ((Se = i.entityMap.consumer) != null && Se.id && i.schema && i.credential) {
|
|
30099
|
-
const
|
|
30100
|
-
Object.prototype.hasOwnProperty.call(J, "consumer") && (
|
|
30099
|
+
const Ce = {};
|
|
30100
|
+
Object.prototype.hasOwnProperty.call(J, "consumer") && (Ce.consumer = i.entityMap.consumer.id), he(Ce);
|
|
30101
30101
|
}
|
|
30102
30102
|
He.value = !1;
|
|
30103
30103
|
};
|
|
30104
30104
|
return Xe(He, (Se) => {
|
|
30105
30105
|
n("loading", Se);
|
|
30106
|
-
}), Xe(() => i.schema, (Se,
|
|
30106
|
+
}), Xe(() => i.schema, (Se, Ce) => {
|
|
30107
30107
|
var oe, ee;
|
|
30108
|
-
if (b(Se || {},
|
|
30108
|
+
if (b(Se || {}, Ce || {}))
|
|
30109
30109
|
return;
|
|
30110
30110
|
const _e = s(Se, void 0, void 0, i.engine);
|
|
30111
30111
|
Object.assign(J, _e.model), W.value = {
|
|
30112
30112
|
fields: (ee = (oe = W.value) == null ? void 0 : oe.fields) == null ? void 0 : ee.map((le) => ({ ...le, disabled: le.disabled || !1 }))
|
|
30113
30113
|
}, Object.assign(X, JSON.parse(JSON.stringify(_e.model))), F(_e.model.name), Je();
|
|
30114
30114
|
}, { immediate: !0, deep: !0 }), Gi(() => {
|
|
30115
|
-
var Se,
|
|
30116
|
-
D.value = s(i.schema, void 0, void 0, i.engine), Object.assign(J, ((Se = D.value) == null ? void 0 : Se.model) || {}), W.value = ((
|
|
30115
|
+
var Se, Ce, _e, oe;
|
|
30116
|
+
D.value = s(i.schema, void 0, void 0, i.engine), Object.assign(J, ((Se = D.value) == null ? void 0 : Se.model) || {}), W.value = ((Ce = D.value) == null ? void 0 : Ce.schema) || {}, F((oe = (_e = D.value) == null ? void 0 : _e.model) == null ? void 0 : oe.name), Je();
|
|
30117
30117
|
}), Ca(() => {
|
|
30118
30118
|
v(!1);
|
|
30119
|
-
}), (Se,
|
|
30119
|
+
}), (Se, Ce) => {
|
|
30120
30120
|
var oe, ee, le;
|
|
30121
30121
|
const _e = Ie("KSkeleton");
|
|
30122
30122
|
return I(), re(ze, null, [
|
|
@@ -30139,9 +30139,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30139
30139
|
"plugin-name": J.name,
|
|
30140
30140
|
"render-rules": (ee = O.value) == null ? void 0 : ee.renderRules,
|
|
30141
30141
|
schema: G.value,
|
|
30142
|
-
"onClick:createEntity":
|
|
30143
|
-
"onClick:learnMore":
|
|
30144
|
-
onGlobalAction:
|
|
30142
|
+
"onClick:createEntity": Ce[0] || (Ce[0] = (fe) => Se.$emit("click:create-entity", fe)),
|
|
30143
|
+
"onClick:learnMore": Ce[1] || (Ce[1] = (fe) => Se.$emit("click:learn-more", fe)),
|
|
30144
|
+
onGlobalAction: Ce[2] || (Ce[2] = (fe, Ae) => Se.$emit("globalAction", fe, Ae))
|
|
30145
30145
|
}, vt({ _: 2 }, [
|
|
30146
30146
|
e.enableVaultSecretPicker ? {
|
|
30147
30147
|
name: u($n),
|
|
@@ -30161,7 +30161,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30161
30161
|
"is-konnect-managed-redis-enabled": o.value,
|
|
30162
30162
|
"on-model-updated": ie,
|
|
30163
30163
|
"on-partial-toggled": V,
|
|
30164
|
-
"show-new-partial-modal": (fe) => Se.$emit("showNewPartialModal", fe)
|
|
30164
|
+
"show-new-partial-modal": (fe) => Se.$emit("showNewPartialModal", fe),
|
|
30165
|
+
"onClick:createEntity": Ce[3] || (Ce[3] = (fe) => Se.$emit("click:create-entity", fe)),
|
|
30166
|
+
"onClick:learnMore": Ce[4] || (Ce[4] = (fe) => Se.$emit("click:learn-more", fe))
|
|
30165
30167
|
}, vt({ _: 2 }, [
|
|
30166
30168
|
e.enableVaultSecretPicker ? {
|
|
30167
30169
|
name: u($n),
|
|
@@ -30181,7 +30183,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30181
30183
|
onModelUpdated: ie,
|
|
30182
30184
|
onPartialToggled: V,
|
|
30183
30185
|
onRefreshModel: $,
|
|
30184
|
-
onShowNewPartialModal:
|
|
30186
|
+
onShowNewPartialModal: Ce[5] || (Ce[5] = (fe) => Se.$emit("showNewPartialModal", fe))
|
|
30185
30187
|
}, vt({
|
|
30186
30188
|
"plugin-config-empty-state": N(() => [
|
|
30187
30189
|
te("div", jR, ue(u(E)("plugins.form.grouping.plugin_configuration.empty")), 1)
|
|
@@ -30210,13 +30212,13 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30210
30212
|
C(u(yd), {
|
|
30211
30213
|
config: i.config,
|
|
30212
30214
|
setup: M.value,
|
|
30213
|
-
onCancel:
|
|
30215
|
+
onCancel: Ce[6] || (Ce[6] = () => M.value = !1),
|
|
30214
30216
|
onProceed: se
|
|
30215
30217
|
}, null, 8, ["config", "setup"])
|
|
30216
30218
|
], 64);
|
|
30217
30219
|
};
|
|
30218
30220
|
}
|
|
30219
|
-
}), qR = /* @__PURE__ */ Ve(DR, [["__scopeId", "data-v-
|
|
30221
|
+
}), qR = /* @__PURE__ */ Ve(DR, [["__scopeId", "data-v-b10596ae"]]), BR = { key: 1 }, UR = /* @__PURE__ */ Oe({
|
|
30220
30222
|
__name: "PluginFormActionsWrapper",
|
|
30221
30223
|
props: {
|
|
30222
30224
|
teleportTarget: {
|
|
@@ -30338,7 +30340,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30338
30340
|
default: void 0
|
|
30339
30341
|
}
|
|
30340
30342
|
},
|
|
30341
|
-
emits: ["cancel", "error:fetch-schema", "error", "loading", "update", "model-updated", "showNewPartialModal", "globalAction", "click:
|
|
30343
|
+
emits: ["cancel", "error:fetch-schema", "error", "loading", "update", "model-updated", "showNewPartialModal", "globalAction", "click:create-entity", "click:learn-more"],
|
|
30342
30344
|
setup(e, { emit: t }) {
|
|
30343
30345
|
var ye, Ke;
|
|
30344
30346
|
const n = ft(pi.KM_2306_CONDITION_FIELD_314, !1), i = ft(pi.KM_2485_CLONED_PLUGINS, !1), o = de(!1);
|
|
@@ -30361,7 +30363,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30361
30363
|
() => D.value && R.value ? R.value : a.pluginType
|
|
30362
30364
|
), X = L(() => {
|
|
30363
30365
|
if (a.engine) return a.engine;
|
|
30364
|
-
if (!(!O || !
|
|
30366
|
+
if (!(!O || !Ee.value))
|
|
30365
30367
|
return D.value && R.value ? p(R.value) ? "freeform" : "vfg" : "freeform";
|
|
30366
30368
|
});
|
|
30367
30369
|
Kt(qo, {
|
|
@@ -30431,33 +30433,33 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30431
30433
|
entityEndpoint: "plugins"
|
|
30432
30434
|
}
|
|
30433
30435
|
};
|
|
30434
|
-
const
|
|
30435
|
-
return z && (
|
|
30436
|
+
const xe = {};
|
|
30437
|
+
return z && (xe.service = {
|
|
30436
30438
|
entity: Rt.SERVICE,
|
|
30437
30439
|
entityEndpoint: "services",
|
|
30438
30440
|
id: z,
|
|
30439
30441
|
idField: so.SERVICE
|
|
30440
|
-
}), pe && (
|
|
30442
|
+
}), pe && (xe.route = {
|
|
30441
30443
|
entity: Rt.ROUTE,
|
|
30442
30444
|
entityEndpoint: "routes",
|
|
30443
30445
|
id: pe,
|
|
30444
30446
|
idField: so.ROUTE
|
|
30445
|
-
}), ae && (
|
|
30447
|
+
}), ae && (xe.consumer = {
|
|
30446
30448
|
entity: Rt.CONSUMER,
|
|
30447
30449
|
entityEndpoint: "consumers",
|
|
30448
30450
|
id: ae,
|
|
30449
30451
|
idField: so.CONSUMER
|
|
30450
|
-
}), B && (
|
|
30452
|
+
}), B && (xe.consumer_group = {
|
|
30451
30453
|
entity: Rt.CONSUMER_GROUP,
|
|
30452
30454
|
entityEndpoint: "consumer_groups",
|
|
30453
30455
|
id: B,
|
|
30454
30456
|
idField: so.CONSUMER_GROUP
|
|
30455
|
-
}), a.config.entityType && (
|
|
30457
|
+
}), a.config.entityType && (xe.focusedEntity = {
|
|
30456
30458
|
entity: Rt[a.config.entityType.substring(0, a.config.entityType.length - 1).toUpperCase()],
|
|
30457
30459
|
entityEndpoint: a.config.entityType,
|
|
30458
30460
|
id: a.config.entityId,
|
|
30459
30461
|
idField: so[a.config.entityType.substring(0, a.config.entityType.length - 1).toUpperCase()]
|
|
30460
|
-
}),
|
|
30462
|
+
}), xe;
|
|
30461
30463
|
}), ce = Ei({
|
|
30462
30464
|
// this is a required field that the user cannot set, it's always the name of the plugin
|
|
30463
30465
|
// ex. 'acl'
|
|
@@ -30541,9 +30543,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30541
30543
|
return B.length > 1 ? "string" : B[0];
|
|
30542
30544
|
}, Be = (ae, B, z, pe) => {
|
|
30543
30545
|
var De, We;
|
|
30544
|
-
let
|
|
30546
|
+
let xe = B && B.fields || [];
|
|
30545
30547
|
const Te = d[W.value], Ne = (We = (De = co[a.pluginType]) == null ? void 0 : De.schema) == null ? void 0 : We.fields;
|
|
30546
|
-
return Array.isArray(
|
|
30548
|
+
return Array.isArray(xe) && (xe = xe.reduce((Ge, Fe) => {
|
|
30547
30549
|
const Pe = Object.keys(Fe)[0];
|
|
30548
30550
|
return Pe.match(/-/g) ? Ge[Pe.replace(/-/g, "_")] = {
|
|
30549
30551
|
...Fe[Pe],
|
|
@@ -30551,9 +30553,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30551
30553
|
// When submitting the form, the underscores should be replaced with dashes again
|
|
30552
30554
|
fieldNameHasDashes: !0
|
|
30553
30555
|
} : Ge[Pe] = Fe[Pe], Ge;
|
|
30554
|
-
}, {})), Object.keys(
|
|
30556
|
+
}, {})), Object.keys(xe).sort().forEach((Ge) => {
|
|
30555
30557
|
var Mt, jn, Tt, Xt, Bo, Uo, Vo;
|
|
30556
|
-
const Fe =
|
|
30558
|
+
const Fe = xe[Ge];
|
|
30557
30559
|
Fe.type === "set" && !(p(a.pluginType, X.value) && Fe.elements.one_of) && (Fe.type = "array");
|
|
30558
30560
|
const Pe = ae ? `${ae}-${Ge}` : `${Ge}`;
|
|
30559
30561
|
if ((Mt = Te == null ? void 0 : Te.fieldsToDelete) != null && Mt.includes(Pe)) {
|
|
@@ -30578,7 +30580,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30578
30580
|
z[Pe].label = dt.split("-").map(c).join(".");
|
|
30579
30581
|
} else
|
|
30580
30582
|
z[Pe].label = c(Pe);
|
|
30581
|
-
if ((ae === "config" || ae.startsWith("config-")) && (jn =
|
|
30583
|
+
if ((ae === "config" || ae.startsWith("config-")) && (jn = xe[Ge]) != null && jn.description && (z[Pe].help = nr.parse(xe[Ge].description, { mangle: !1, headerIds: !1 })), Fe.type === "map") {
|
|
30582
30584
|
if (z[Pe].type = "object-advanced", z[Pe].values = Fe.values, Fe.values.type === "array") {
|
|
30583
30585
|
const { type: dt } = Fe.values.elements || {};
|
|
30584
30586
|
z[Pe].schema = {
|
|
@@ -30720,7 +30722,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30720
30722
|
}), z;
|
|
30721
30723
|
}, qe = () => {
|
|
30722
30724
|
var tt, Mt, jn, Tt, Xt, Bo, Uo, Vo, dt, Zt, $t, ht;
|
|
30723
|
-
const ae = D.value && R.value ? R.value : a.pluginType, B = ((tt = An[ae]) == null ? void 0 : tt.scope.includes(Rt.SERVICE)) ?? !0, z = ((Mt = An[ae]) == null ? void 0 : Mt.scope.includes(Rt.ROUTE)) ?? !0, pe = ((jn = An[ae]) == null ? void 0 : jn.scope.includes(Rt.CONSUMER)) ?? !0,
|
|
30725
|
+
const ae = D.value && R.value ? R.value : a.pluginType, B = ((tt = An[ae]) == null ? void 0 : tt.scope.includes(Rt.SERVICE)) ?? !0, z = ((Mt = An[ae]) == null ? void 0 : Mt.scope.includes(Rt.ROUTE)) ?? !0, pe = ((jn = An[ae]) == null ? void 0 : jn.scope.includes(Rt.CONSUMER)) ?? !0, xe = a.config.disableConsumerGroupScope ? !1 : ((Tt = An[ae]) == null ? void 0 : Tt.scope.includes(Rt.CONSUMER_GROUP)) ?? !0, Te = a.config.entityType === "consumers" && !!a.config.entityId || !!((Bo = (Xt = P.value) == null ? void 0 : Xt.consumer) != null && Bo.id), Ne = a.config.entityType === "consumer_groups" && !!a.config.entityId || !!((Vo = (Uo = P.value) == null ? void 0 : Uo.consumer_group) != null && Vo.id), De = a.config.entityType === "services" && !!a.config.entityId || !!((Zt = (dt = P.value) == null ? void 0 : dt.service) != null && Zt.id), We = a.config.entityType === "routes" && !!a.config.entityId || !!((ht = ($t = P.value) == null ? void 0 : $t.route) != null && ht.id), Ge = [], Fe = (ct, xt, Ct) => ct ? s("plugins.form.disable_source_scope_change", { scope: Ct }) : xt ? s("plugins.form.disable_data_retrieving", { scope: Ct }) : "", Pe = (ct) => {
|
|
30724
30726
|
var xt, Ct;
|
|
30725
30727
|
return ((Ct = (xt = a.scopedEntitiesPermissions) == null ? void 0 : xt[ct]) == null ? void 0 : Ct.canRetrieve) === !1;
|
|
30726
30728
|
};
|
|
@@ -30781,7 +30783,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30781
30783
|
disabledTooltip: Fe(Ct, ct, xt)
|
|
30782
30784
|
});
|
|
30783
30785
|
}
|
|
30784
|
-
if (
|
|
30786
|
+
if (xe) {
|
|
30785
30787
|
const ct = Pe("consumer_group"), xt = "consumer_groups", Ct = Ne && a.disableScopeSelection;
|
|
30786
30788
|
Ge.push({
|
|
30787
30789
|
model: "consumer_group-id",
|
|
@@ -30805,7 +30807,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30805
30807
|
...B ? ["service"] : [],
|
|
30806
30808
|
...z ? ["route"] : [],
|
|
30807
30809
|
...pe ? ["consumer"] : [],
|
|
30808
|
-
...
|
|
30810
|
+
...xe ? ["consumer_group"] : []
|
|
30809
30811
|
], Ct = ct.splice(ct.length - 2, 2).map((xn) => s(xn === "service" ? "plugins.form.scoping.gateway_service.plural" : `plugins.form.scoping.${xn}.plural`)).join(`${ct.length > 0 ? "," : ""} and/or `), wn = [
|
|
30810
30812
|
"Specific",
|
|
30811
30813
|
[
|
|
@@ -30824,9 +30826,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30824
30826
|
d[W.value] && d[W.value].overwriteDefault && Object.hasOwnProperty.call(d[W.value], "formSchema") && Object.assign(ce, d[W.value].formSchema);
|
|
30825
30827
|
}, He = L(() => !y(F.fields, se, !0)), Je = L(() => !me.value && !H.value && (A.value === $i.Create || He.value)), at = de(!1), Ue = de(), Se = (ae) => {
|
|
30826
30828
|
a.credential && ae.password && (ae.password = ""), F.fields.id = (ae == null ? void 0 : ae.id) || void 0, Ue.value = ae == null ? void 0 : ae.ordering, Object.assign(se, F.fields), P.value = ae, at.value = !0;
|
|
30827
|
-
},
|
|
30829
|
+
}, Ce = de({}), _e = (ae) => {
|
|
30828
30830
|
var B;
|
|
30829
|
-
F.fields = ae.model, F.fields.id = ((B = P.value) == null ? void 0 : B.id) || void 0, Object.assign(se, ae.originalModel),
|
|
30831
|
+
F.fields = ae.model, F.fields.id = ((B = P.value) == null ? void 0 : B.id) || void 0, Object.assign(se, ae.originalModel), Ce.value = ae.data, a.isWizardStep && r("model-updated", {
|
|
30830
30832
|
model: F.fields,
|
|
30831
30833
|
data: ae.data,
|
|
30832
30834
|
resourceEndpoint: ve.value
|
|
@@ -30835,10 +30837,10 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30835
30837
|
ae.valid ? oe.value.delete(ae.model) : oe.value.set(ae.model, ae.error), F.clientErrorMessage = [...oe.value.entries()].map(([B, z]) => `${B}: ${typeof z == "string" ? z : m(z)}`).join("; "), F.clientErrorMessage && (F.serverErrorMessage = "");
|
|
30836
30838
|
};
|
|
30837
30839
|
Xe([we, at], (ae, B) => {
|
|
30838
|
-
const z = ae[0] !== B[0], pe = ae[1],
|
|
30839
|
-
if (!T.value && A.value === $i.Edit && (z || pe && pe !==
|
|
30840
|
+
const z = ae[0] !== B[0], pe = ae[1], xe = B[1];
|
|
30841
|
+
if (!T.value && A.value === $i.Edit && (z || pe && pe !== xe)) {
|
|
30840
30842
|
const Te = Be("config", j.value, ce);
|
|
30841
|
-
|
|
30843
|
+
Ee.value && (Te._isCustomPlugin = !0), D.value && R.value && (Te._sourcePlugin = R.value), S.value && (Te._supported_redis_partial_type = S.value), w.value = Te;
|
|
30842
30844
|
}
|
|
30843
30845
|
}, { deep: !0 });
|
|
30844
30846
|
const fe = () => {
|
|
@@ -30847,8 +30849,8 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30847
30849
|
const ae = a.config.entityType && a.config.entityId && !a.developer, B = T.value ? it.form[a.config.app].credential[A.value] : it.form[a.config.app][A.value][ae ? "forEntity" : "all"];
|
|
30848
30850
|
let z = `${a.config.apiBaseUrl}${B}`;
|
|
30849
30851
|
return a.config.app === "konnect" && (z = z.replace(/{controlPlaneId}/gi, a.config.controlPlaneId || "")), z = z.replace(/\/{workspace}/gi, a.config.workspace ? `/${a.config.workspace}` : ""), z = z.replace(/{resourceEndpoint}/gi, ve.value), z = z.replace(/{id}/gi, a.pluginId ?? ""), z = z.replace(/{entityType}/gi, a.config.entityType || ""), z = z.replace(/{entityId}/gi, a.config.entityId || ""), z;
|
|
30850
|
-
}),
|
|
30851
|
-
const ae =
|
|
30852
|
+
}), Ee = L(() => !Object.keys(An).includes(a.pluginType)), $e = L(() => {
|
|
30853
|
+
const ae = Ce.value;
|
|
30852
30854
|
if (T.value) {
|
|
30853
30855
|
for (const B in Rt) {
|
|
30854
30856
|
const z = Rt[B];
|
|
@@ -30856,7 +30858,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30856
30858
|
}
|
|
30857
30859
|
delete ae.created_at;
|
|
30858
30860
|
}
|
|
30859
|
-
return
|
|
30861
|
+
return Ce.value.partials && x.value && ec(ae, x.value), ae;
|
|
30860
30862
|
}), g = L(() => {
|
|
30861
30863
|
const { __ui_data: ae, ...B } = { ...$e.value };
|
|
30862
30864
|
return B;
|
|
@@ -30888,12 +30890,12 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30888
30890
|
me.value = !0;
|
|
30889
30891
|
try {
|
|
30890
30892
|
if (T.value && a.config.app === "konnect") {
|
|
30891
|
-
const
|
|
30892
|
-
ke.value =
|
|
30893
|
+
const xe = (ae = co[a.pluginType]) == null ? void 0 : ae.schemaEndpoint, Te = YC[xe];
|
|
30894
|
+
ke.value = xe, w.value = Be("", Te, {}), me.value = !1;
|
|
30893
30895
|
} else {
|
|
30894
|
-
const
|
|
30896
|
+
const xe = i && Ee.value, Te = a.schema ? Promise.resolve(a.schema) : _.get(be.value).then((De) => De.data), [Ne] = await Promise.all([
|
|
30895
30897
|
Te,
|
|
30896
|
-
|
|
30898
|
+
xe ? K(a.pluginType) : Promise.resolve()
|
|
30897
30899
|
]);
|
|
30898
30900
|
if (k.value = Ne, Ne)
|
|
30899
30901
|
if (T.value)
|
|
@@ -30910,12 +30912,12 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30910
30912
|
}
|
|
30911
30913
|
if (at.value || A.value === $i.Create) {
|
|
30912
30914
|
const Ge = Be("config", j.value, ce);
|
|
30913
|
-
S.value && (Ge._supported_redis_partial_type = S.value),
|
|
30915
|
+
S.value && (Ge._supported_redis_partial_type = S.value), Ee.value && (Ge._isCustomPlugin = !0), D.value && R.value && (Ge._sourcePlugin = R.value), w.value = Ge;
|
|
30914
30916
|
}
|
|
30915
30917
|
}
|
|
30916
30918
|
}
|
|
30917
|
-
} catch (
|
|
30918
|
-
console.error(
|
|
30919
|
+
} catch (xe) {
|
|
30920
|
+
console.error(xe), Me.value = m(xe), r("error:fetch-schema", xe);
|
|
30919
30921
|
} finally {
|
|
30920
30922
|
me.value = !1;
|
|
30921
30923
|
}
|
|
@@ -30932,7 +30934,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30932
30934
|
}
|
|
30933
30935
|
}
|
|
30934
30936
|
return (ae, B) => {
|
|
30935
|
-
const z = Ie("KSkeleton"), pe = Ie("KEmptyState"),
|
|
30937
|
+
const z = Ie("KSkeleton"), pe = Ie("KEmptyState"), xe = Ie("KButton"), Te = Ie("KTabs"), Ne = Ie("KSlideout");
|
|
30936
30938
|
return I(), re("div", {
|
|
30937
30939
|
class: yt(["kong-ui-entities-plugin-form-container", { "new-form-layout": o.value }])
|
|
30938
30940
|
}, [
|
|
@@ -30973,7 +30975,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30973
30975
|
}, {
|
|
30974
30976
|
default: N(() => [
|
|
30975
30977
|
te("div", zR, [
|
|
30976
|
-
e.hideViewConfigAction ? ge("", !0) : (I(), Q(
|
|
30978
|
+
e.hideViewConfigAction ? ge("", !0) : (I(), Q(xe, {
|
|
30977
30979
|
key: 0,
|
|
30978
30980
|
appearance: "tertiary",
|
|
30979
30981
|
"data-testid": `plugin-${E.value ? "edit" : "create"}-form-view-configuration`,
|
|
@@ -30984,7 +30986,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30984
30986
|
]),
|
|
30985
30987
|
_: 1
|
|
30986
30988
|
}, 8, ["data-testid"])),
|
|
30987
|
-
C(
|
|
30989
|
+
C(xe, {
|
|
30988
30990
|
appearance: "secondary",
|
|
30989
30991
|
class: "form-action-button",
|
|
30990
30992
|
"data-testid": `plugin-${E.value ? "edit" : "create"}-form-cancel`,
|
|
@@ -30996,7 +30998,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
30996
30998
|
]),
|
|
30997
30999
|
_: 1
|
|
30998
31000
|
}, 8, ["data-testid", "disabled"]),
|
|
30999
|
-
C(
|
|
31001
|
+
C(xe, {
|
|
31000
31002
|
appearance: "primary",
|
|
31001
31003
|
"data-testid": `plugin-${E.value ? "edit" : "create"}-form-submit`,
|
|
31002
31004
|
disabled: !Je.value || F.isReadonly,
|
|
@@ -31082,7 +31084,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31082
31084
|
]),
|
|
31083
31085
|
deck: N(() => [
|
|
31084
31086
|
u(M) ? (I(), re("div", GR, [
|
|
31085
|
-
C(
|
|
31087
|
+
C(xe, {
|
|
31086
31088
|
appearance: "secondary",
|
|
31087
31089
|
class: "button-customize-deck",
|
|
31088
31090
|
onClick: B[9] || (B[9] = (De) => q.value = !0)
|
|
@@ -31114,7 +31116,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31114
31116
|
], 2);
|
|
31115
31117
|
};
|
|
31116
31118
|
}
|
|
31117
|
-
}), PF = /* @__PURE__ */ Ve(HR, [["__scopeId", "data-v-
|
|
31119
|
+
}), PF = /* @__PURE__ */ Ve(HR, [["__scopeId", "data-v-aefa9b20"]]), WR = { class: "kong-ui-entities-plugins-list" }, YR = { class: "button-row" }, JR = { class: "name-cell-wrapper" }, XR = { class: "info-wrapper" }, ZR = {
|
|
31118
31120
|
key: 0,
|
|
31119
31121
|
class: "info-name"
|
|
31120
31122
|
}, QR = {
|
|
@@ -31214,9 +31216,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31214
31216
|
};
|
|
31215
31217
|
(at = o.config) != null && at.entityId || (_.appliedTo = { label: r("plugins.list.table_headers.applied_to"), sortable: !1 }), _.enabled = { label: r("plugins.list.table_headers.enabled"), searchable: !0, sortable: !0 }, h && (_.ordering = { label: r("plugins.list.table_headers.ordering"), sortable: !0 }), _.tags = { label: r("plugins.list.table_headers.tags"), sortable: !1 };
|
|
31216
31218
|
const v = _, b = L(() => {
|
|
31217
|
-
var Se,
|
|
31219
|
+
var Se, Ce, _e, oe;
|
|
31218
31220
|
let Ue = o.config.entityType ? `${o.config.apiBaseUrl}${it.list[o.config.app].forEntity}` : `${o.config.apiBaseUrl}${it.list[o.config.app].all}`;
|
|
31219
|
-
return o.config.app === "konnect" && (Ue = Ue.replace(/{controlPlaneId}/gi, ((Se = o.config) == null ? void 0 : Se.controlPlaneId) || "")), Ue.replace(/\/{workspace}/gi, (
|
|
31221
|
+
return o.config.app === "konnect" && (Ue = Ue.replace(/{controlPlaneId}/gi, ((Se = o.config) == null ? void 0 : Se.controlPlaneId) || "")), Ue.replace(/\/{workspace}/gi, (Ce = o.config) != null && Ce.workspace ? `/${o.config.workspace}` : "").replace(/{entityType}/gi, ((_e = o.config) == null ? void 0 : _e.entityType) || "").replace(/{entityId}/gi, ((oe = o.config) == null ? void 0 : oe.entityId) || "");
|
|
31220
31222
|
}), E = de(""), A = L(() => o.config.app === "konnect" || o.config.isExactMatch ? {
|
|
31221
31223
|
isExactMatch: !0,
|
|
31222
31224
|
fields: {
|
|
@@ -31242,30 +31244,30 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31242
31244
|
}, j = () => {
|
|
31243
31245
|
T.value++;
|
|
31244
31246
|
}, S = de(null), x = (Ue) => {
|
|
31245
|
-
var
|
|
31247
|
+
var Ce, _e, oe, ee;
|
|
31246
31248
|
const Se = [];
|
|
31247
|
-
return ((
|
|
31249
|
+
return ((Ce = Ue.route) != null && Ce.id || Ue.route_id) && Se.push({ type: "route", badgeText: r("plugins.list.table_headers.applied_to_badges.route") }), ((_e = Ue.service) != null && _e.id || Ue.service_id) && Se.push({ type: "service", badgeText: r("plugins.list.table_headers.applied_to_badges.service") }), ((oe = Ue.consumer) != null && oe.id || Ue.consumer_id) && Se.push({ type: "consumer", badgeText: r("plugins.list.table_headers.applied_to_badges.consumer") }), ((ee = Ue.consumer_group) != null && ee.id || Ue.consumer_group_id) && Se.push({ type: "consumer_group", badgeText: r("plugins.list.table_headers.applied_to_badges.consumer_group") }), Se.length ? Se : [{ type: null, badgeText: r("plugins.list.table_headers.applied_to_badges.global") }];
|
|
31248
31250
|
}, O = async (Ue, Se) => {
|
|
31249
|
-
var
|
|
31250
|
-
return Ue === null ? !1 : await ((
|
|
31251
|
+
var Ce;
|
|
31252
|
+
return Ue === null ? !1 : await ((Ce = o.canRetrieveScopedEntity) == null ? void 0 : Ce.call(o, Ue, Se.id));
|
|
31251
31253
|
}, R = (Ue, Se) => {
|
|
31252
31254
|
var _e, oe, ee, le, fe;
|
|
31253
|
-
let
|
|
31255
|
+
let Ce = null;
|
|
31254
31256
|
switch (Ue) {
|
|
31255
31257
|
case "route":
|
|
31256
|
-
|
|
31258
|
+
Ce = (_e = Se.route) == null ? void 0 : _e.id;
|
|
31257
31259
|
break;
|
|
31258
31260
|
case "service":
|
|
31259
|
-
|
|
31261
|
+
Ce = (oe = Se.service) == null ? void 0 : oe.id;
|
|
31260
31262
|
break;
|
|
31261
31263
|
case "consumer":
|
|
31262
|
-
|
|
31264
|
+
Ce = (ee = Se.consumer) == null ? void 0 : ee.id;
|
|
31263
31265
|
break;
|
|
31264
31266
|
case "consumer_group":
|
|
31265
|
-
|
|
31267
|
+
Ce = (le = Se.consumer_group) == null ? void 0 : le.id;
|
|
31266
31268
|
break;
|
|
31267
31269
|
}
|
|
31268
|
-
|
|
31270
|
+
Ce && ((fe = o.config) != null && fe.getScopedEntityViewRoute) && a.push(o.config.getScopedEntityViewRoute(Ue, Ce));
|
|
31269
31271
|
}, D = de(!1), W = de(null), X = L(() => {
|
|
31270
31272
|
const Ue = {
|
|
31271
31273
|
action: "disable",
|
|
@@ -31273,8 +31275,8 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31273
31275
|
name: ""
|
|
31274
31276
|
};
|
|
31275
31277
|
if (W.value) {
|
|
31276
|
-
const { enabled: Se, id:
|
|
31277
|
-
Ue.action = Se ? "disable" : "enable", Ue.id =
|
|
31278
|
+
const { enabled: Se, id: Ce, name: _e } = W.value;
|
|
31279
|
+
Ue.action = Se ? "disable" : "enable", Ue.id = Ce, Ue.name = n.getDisplayName(_e) || Ce;
|
|
31278
31280
|
}
|
|
31279
31281
|
return Ue;
|
|
31280
31282
|
}), J = (Ue) => {
|
|
@@ -31282,24 +31284,24 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31282
31284
|
}, q = () => {
|
|
31283
31285
|
D.value = !1, W.value = null;
|
|
31284
31286
|
}, G = async () => {
|
|
31285
|
-
var _e, oe, ee, le, fe, Ae,
|
|
31287
|
+
var _e, oe, ee, le, fe, Ae, Ee, $e;
|
|
31286
31288
|
if (!await ((_e = o.canEdit) == null ? void 0 : _e.call(o, W.value)) || !W.value)
|
|
31287
31289
|
return;
|
|
31288
31290
|
let Se = `${o.config.apiBaseUrl}${(fe = it.item[o.config.app]) == null ? void 0 : fe[(oe = o.config) != null && oe.entityType ? "forEntity" : "all"].replace(/{entityType}/gi, ((ee = o.config) == null ? void 0 : ee.entityType) || "").replace(/{entityId}/gi, ((le = o.config) == null ? void 0 : le.entityId) || "")}`.replace(/{id}/gi, W.value.id || "");
|
|
31289
|
-
o.config.app === "konnect" && (Se = Se.replace(/{controlPlaneId}/gi, ((Ae = o.config) == null ? void 0 : Ae.controlPlaneId) || "")), Se = Se.replace(/\/{workspace}/gi, (
|
|
31290
|
-
const
|
|
31291
|
+
o.config.app === "konnect" && (Se = Se.replace(/{controlPlaneId}/gi, ((Ae = o.config) == null ? void 0 : Ae.controlPlaneId) || "")), Se = Se.replace(/\/{workspace}/gi, (Ee = o.config) != null && Ee.workspace ? `/${o.config.workspace}` : "");
|
|
31292
|
+
const Ce = !W.value.enabled;
|
|
31291
31293
|
try {
|
|
31292
31294
|
const g = ($e = o.config) == null ? void 0 : $e.app;
|
|
31293
31295
|
let Z;
|
|
31294
31296
|
E.value && g === "konnect" && (Z = await l.get(Se));
|
|
31295
|
-
const { data: be } = g === "konnect" ? await l.put(Se, { ...(Z == null ? void 0 : Z.data) || W.value, enabled:
|
|
31296
|
-
i("toggle-enabled",
|
|
31297
|
+
const { data: be } = g === "konnect" ? await l.put(Se, { ...(Z == null ? void 0 : Z.data) || W.value, enabled: Ce }, { timeout: 12e4 }) : await l.patch(Se, { ...W.value, enabled: Ce }, { timeout: 12e4 });
|
|
31298
|
+
i("toggle-enabled", Ce, be), W.value.enabled = Ce;
|
|
31297
31299
|
} catch (g) {
|
|
31298
31300
|
i("error", g);
|
|
31299
31301
|
}
|
|
31300
31302
|
}, M = async (Ue, Se) => {
|
|
31301
|
-
const
|
|
31302
|
-
if (!await Se(
|
|
31303
|
+
const Ce = Ue.id;
|
|
31304
|
+
if (!await Se(Ce)) {
|
|
31303
31305
|
i("copy:error", {
|
|
31304
31306
|
entity: Ue,
|
|
31305
31307
|
field: "id",
|
|
@@ -31310,11 +31312,11 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31310
31312
|
i("copy:success", {
|
|
31311
31313
|
entity: Ue,
|
|
31312
31314
|
field: "id",
|
|
31313
|
-
message: r("copy.success", { val:
|
|
31315
|
+
message: r("copy.success", { val: Ce })
|
|
31314
31316
|
});
|
|
31315
31317
|
}, U = async (Ue, Se) => {
|
|
31316
|
-
const
|
|
31317
|
-
if (!await Se(
|
|
31318
|
+
const Ce = JSON.stringify(Ue);
|
|
31319
|
+
if (!await Se(Ce)) {
|
|
31318
31320
|
i("copy:error", {
|
|
31319
31321
|
entity: Ue,
|
|
31320
31322
|
message: r("errors.copy")
|
|
@@ -31326,8 +31328,8 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31326
31328
|
message: r("copy.success_brief")
|
|
31327
31329
|
});
|
|
31328
31330
|
}, H = async (Ue) => {
|
|
31329
|
-
var
|
|
31330
|
-
await ((
|
|
31331
|
+
var Ce;
|
|
31332
|
+
await ((Ce = o.canRetrieve) == null ? void 0 : Ce.call(o, Ue)) && a.push(o.config.getViewRoute(Ue));
|
|
31331
31333
|
}, se = (Ue) => ({
|
|
31332
31334
|
label: r("actions.view"),
|
|
31333
31335
|
to: o.config.getViewRoute(Ue)
|
|
@@ -31342,13 +31344,13 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31342
31344
|
}, ve = () => {
|
|
31343
31345
|
ie.value = !1;
|
|
31344
31346
|
}, je = async () => {
|
|
31345
|
-
var Ue, Se,
|
|
31347
|
+
var Ue, Se, Ce;
|
|
31346
31348
|
if ((Ue = V.value) != null && Ue.id) {
|
|
31347
31349
|
ne.value = !0;
|
|
31348
31350
|
try {
|
|
31349
31351
|
await l.delete(we(V.value.id)), ne.value = !1, ie.value = !1, T.value++, i("delete:success", V.value);
|
|
31350
31352
|
} catch (_e) {
|
|
31351
|
-
he.value = ((
|
|
31353
|
+
he.value = ((Ce = (Se = _e.response) == null ? void 0 : Se.data) == null ? void 0 : Ce.message) || _e.message || r("errors.delete"), i("error", _e);
|
|
31352
31354
|
} finally {
|
|
31353
31355
|
ne.value = !1;
|
|
31354
31356
|
}
|
|
@@ -31357,11 +31359,11 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31357
31359
|
a.push(o.config.createRoute);
|
|
31358
31360
|
};
|
|
31359
31361
|
Xe(w, (Ue) => {
|
|
31360
|
-
var Se,
|
|
31362
|
+
var Se, Ce, _e;
|
|
31361
31363
|
if (Ue.status === oh.Error) {
|
|
31362
31364
|
S.value = {
|
|
31363
31365
|
title: r("errors.general")
|
|
31364
|
-
}, (_e = (
|
|
31366
|
+
}, (_e = (Ce = (Se = Ue.error) == null ? void 0 : Se.response) == null ? void 0 : Ce.data) != null && _e.message && (S.value.message = Ue.error.response.data.message), i("error", Ue.error);
|
|
31365
31367
|
return;
|
|
31366
31368
|
}
|
|
31367
31369
|
S.value = null;
|
|
@@ -31375,7 +31377,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31375
31377
|
return Gi(async () => {
|
|
31376
31378
|
He.value = await o.canCreate(), He.value && (qe.value.title = r("plugins.list.empty_state.title"), qe.value.ctaText = r("actions.create"));
|
|
31377
31379
|
}), (Ue, Se) => {
|
|
31378
|
-
const
|
|
31380
|
+
const Ce = Ie("KButton"), _e = Ie("KEmptyState"), oe = Ie("KBadge"), ee = Ie("KTruncate"), le = Ie("KInputSwitch"), fe = Ie("KDropdownItem"), Ae = Ie("KClipboardProvider");
|
|
31379
31381
|
return I(), re("div", WR, [
|
|
31380
31382
|
C(u(ah), {
|
|
31381
31383
|
"cache-identifier": e.cacheIdentifier,
|
|
@@ -31392,14 +31394,14 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31392
31394
|
title: e.title,
|
|
31393
31395
|
"title-tag": e.titleTag,
|
|
31394
31396
|
onClearSearchInput: P,
|
|
31395
|
-
"onClick:row": Se[4] || (Se[4] = (
|
|
31397
|
+
"onClick:row": Se[4] || (Se[4] = (Ee) => H(Ee)),
|
|
31396
31398
|
onSort: j,
|
|
31397
31399
|
onState: u(d)
|
|
31398
31400
|
}, vt({
|
|
31399
31401
|
"toolbar-filter": N(() => [
|
|
31400
31402
|
C(u(sh), {
|
|
31401
31403
|
modelValue: E.value,
|
|
31402
|
-
"onUpdate:modelValue": Se[0] || (Se[0] = (
|
|
31404
|
+
"onUpdate:modelValue": Se[0] || (Se[0] = (Ee) => E.value = Ee),
|
|
31403
31405
|
config: A.value
|
|
31404
31406
|
}, null, 8, ["modelValue", "config"])
|
|
31405
31407
|
]),
|
|
@@ -31409,13 +31411,13 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31409
31411
|
to: "#kong-ui-app-page-header-action-button"
|
|
31410
31412
|
}, [
|
|
31411
31413
|
te("div", YR, [
|
|
31412
|
-
!c.value && f.value ? (I(), Q(
|
|
31414
|
+
!c.value && f.value ? (I(), Q(Ce, {
|
|
31413
31415
|
key: 0,
|
|
31414
31416
|
appearance: "secondary",
|
|
31415
31417
|
class: "open-learning-hub",
|
|
31416
31418
|
"data-testid": "plugins-learn-more-button",
|
|
31417
31419
|
icon: "",
|
|
31418
|
-
onClick: Se[1] || (Se[1] = (
|
|
31420
|
+
onClick: Se[1] || (Se[1] = (Ee) => Ue.$emit("click:learn-more"))
|
|
31419
31421
|
}, {
|
|
31420
31422
|
default: N(() => [
|
|
31421
31423
|
C(u(Is), { decorative: "" })
|
|
@@ -31426,7 +31428,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31426
31428
|
"auth-function": () => e.canCreate()
|
|
31427
31429
|
}, {
|
|
31428
31430
|
default: N(() => [
|
|
31429
|
-
C(
|
|
31431
|
+
C(Ce, {
|
|
31430
31432
|
appearance: "primary",
|
|
31431
31433
|
"data-testid": "toolbar-add-plugin",
|
|
31432
31434
|
size: e.useActionOutside ? "medium" : "large",
|
|
@@ -31444,31 +31446,31 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31444
31446
|
])
|
|
31445
31447
|
], 8, ["disabled"]))
|
|
31446
31448
|
]),
|
|
31447
|
-
name: N(({ row:
|
|
31449
|
+
name: N(({ row: Ee }) => [
|
|
31448
31450
|
te("div", JR, [
|
|
31449
31451
|
C(u(Di), {
|
|
31450
31452
|
class: "plugin-icon",
|
|
31451
|
-
name:
|
|
31453
|
+
name: Ee.name,
|
|
31452
31454
|
size: 24
|
|
31453
31455
|
}, null, 8, ["name"]),
|
|
31454
31456
|
te("div", XR, [
|
|
31455
|
-
|
|
31456
|
-
|
|
31457
|
+
Ee.instance_name ? (I(), re("span", ZR, ue(Ee.instance_name), 1)) : (I(), re("span", QR, ue(u(n).getDisplayName(Ee.name)), 1)),
|
|
31458
|
+
Ee.instance_name ? (I(), re("span", eM, ue(u(n).getDisplayName(Ee.name)), 1)) : ge("", !0)
|
|
31457
31459
|
])
|
|
31458
31460
|
])
|
|
31459
31461
|
]),
|
|
31460
|
-
appliedTo: N(({ row:
|
|
31461
|
-
x(
|
|
31462
|
+
appliedTo: N(({ row: Ee }) => [
|
|
31463
|
+
x(Ee).length > 0 ? (I(), Q(ee, { key: 0 }, {
|
|
31462
31464
|
default: N(() => [
|
|
31463
|
-
(I(!0), re(ze, null, Qe(x(
|
|
31465
|
+
(I(!0), re(ze, null, Qe(x(Ee), ($e) => (I(), Q(u(Pi), {
|
|
31464
31466
|
key: $e.badgeText,
|
|
31465
|
-
"auth-function": () => O($e.type,
|
|
31467
|
+
"auth-function": () => O($e.type, Ee),
|
|
31466
31468
|
"force-show": ""
|
|
31467
31469
|
}, {
|
|
31468
31470
|
default: N(({ isAllowed: g }) => [
|
|
31469
31471
|
C(oe, {
|
|
31470
31472
|
class: yt(g || "disabled"),
|
|
31471
|
-
onClick: Ft((Z) => g && $e.type && R($e.type,
|
|
31473
|
+
onClick: Ft((Z) => g && $e.type && R($e.type, Ee), ["stop"])
|
|
31472
31474
|
}, {
|
|
31473
31475
|
default: N(() => [
|
|
31474
31476
|
Le(ue($e.badgeText), 1)
|
|
@@ -31482,9 +31484,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31482
31484
|
_: 2
|
|
31483
31485
|
}, 1024)) : (I(), re("span", tM, "-"))
|
|
31484
31486
|
]),
|
|
31485
|
-
enabled: N(({ row:
|
|
31487
|
+
enabled: N(({ row: Ee }) => [
|
|
31486
31488
|
C(u(Pi), {
|
|
31487
|
-
"auth-function": async () => !!(await e.canEdit(
|
|
31489
|
+
"auth-function": async () => !!(await e.canEdit(Ee) && await e.canToggle(Ee)),
|
|
31488
31490
|
"force-show": ""
|
|
31489
31491
|
}, {
|
|
31490
31492
|
default: N(({ isAllowed: $e }) => {
|
|
@@ -31496,9 +31498,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31496
31498
|
}, [
|
|
31497
31499
|
C(le, {
|
|
31498
31500
|
disabled: !$e,
|
|
31499
|
-
"disabled-tooltip-text": !$e && ((Z = (g = e.config).getToggleDisabledTooltip) == null ? void 0 : Z.call(g,
|
|
31500
|
-
"model-value":
|
|
31501
|
-
onClick: Ft((be) => $e && J(
|
|
31501
|
+
"disabled-tooltip-text": !$e && ((Z = (g = e.config).getToggleDisabledTooltip) == null ? void 0 : Z.call(g, Ee)) || void 0,
|
|
31502
|
+
"model-value": Ee.enabled,
|
|
31503
|
+
onClick: Ft((be) => $e && J(Ee), ["stop", "prevent"])
|
|
31502
31504
|
}, null, 8, ["disabled", "disabled-tooltip-text", "model-value", "onClick"])
|
|
31503
31505
|
])
|
|
31504
31506
|
];
|
|
@@ -31506,25 +31508,25 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31506
31508
|
_: 2
|
|
31507
31509
|
}, 1032, ["auth-function"])
|
|
31508
31510
|
]),
|
|
31509
|
-
ordering: N(({ rowValue:
|
|
31511
|
+
ordering: N(({ rowValue: Ee }) => [
|
|
31510
31512
|
C(oe, {
|
|
31511
|
-
appearance: u(Qu)(
|
|
31513
|
+
appearance: u(Qu)(Ee) ? "info" : "warning"
|
|
31512
31514
|
}, {
|
|
31513
31515
|
default: N(() => [
|
|
31514
|
-
Le(ue(u(Qu)(
|
|
31516
|
+
Le(ue(u(Qu)(Ee) ? u(r)("plugins.list.table_headers.ordering_badge.static") : u(r)("plugins.list.table_headers.ordering_badge.dynamic")), 1)
|
|
31515
31517
|
]),
|
|
31516
31518
|
_: 2
|
|
31517
31519
|
}, 1032, ["appearance"])
|
|
31518
31520
|
]),
|
|
31519
|
-
tags: N(({ rowValue:
|
|
31520
|
-
C(u(rh), { tags:
|
|
31521
|
+
tags: N(({ rowValue: Ee }) => [
|
|
31522
|
+
C(u(rh), { tags: Ee }, null, 8, ["tags"])
|
|
31521
31523
|
]),
|
|
31522
|
-
actions: N(({ row:
|
|
31524
|
+
actions: N(({ row: Ee }) => [
|
|
31523
31525
|
C(Ae, null, {
|
|
31524
31526
|
default: N(({ copyToClipboard: $e }) => [
|
|
31525
31527
|
C(fe, {
|
|
31526
31528
|
"data-testid": "action-entity-copy-id",
|
|
31527
|
-
onClick: (g) => M(
|
|
31529
|
+
onClick: (g) => M(Ee, $e)
|
|
31528
31530
|
}, {
|
|
31529
31531
|
default: N(() => [
|
|
31530
31532
|
Le(ue(u(r)("actions.copy_id")), 1)
|
|
@@ -31538,7 +31540,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31538
31540
|
default: N(({ copyToClipboard: $e }) => [
|
|
31539
31541
|
C(fe, {
|
|
31540
31542
|
"data-testid": "action-entity-copy-json",
|
|
31541
|
-
onClick: (g) => U(
|
|
31543
|
+
onClick: (g) => U(Ee, $e)
|
|
31542
31544
|
}, {
|
|
31543
31545
|
default: N(() => [
|
|
31544
31546
|
Le(ue(u(r)("actions.copy_json")), 1)
|
|
@@ -31549,50 +31551,50 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31549
31551
|
_: 2
|
|
31550
31552
|
}, 1024),
|
|
31551
31553
|
C(u(Pi), {
|
|
31552
|
-
"auth-function": () => e.canRetrieve(
|
|
31554
|
+
"auth-function": () => e.canRetrieve(Ee)
|
|
31553
31555
|
}, {
|
|
31554
31556
|
default: N(() => [
|
|
31555
31557
|
C(fe, {
|
|
31556
31558
|
"data-testid": "action-entity-view",
|
|
31557
31559
|
"has-divider": "",
|
|
31558
|
-
item: se(
|
|
31560
|
+
item: se(Ee)
|
|
31559
31561
|
}, null, 8, ["item"])
|
|
31560
31562
|
]),
|
|
31561
31563
|
_: 2
|
|
31562
31564
|
}, 1032, ["auth-function"]),
|
|
31563
31565
|
C(u(Pi), {
|
|
31564
|
-
"auth-function": () => e.canEdit(
|
|
31566
|
+
"auth-function": () => e.canEdit(Ee)
|
|
31565
31567
|
}, {
|
|
31566
31568
|
default: N(() => [
|
|
31567
31569
|
C(fe, {
|
|
31568
31570
|
"data-testid": "action-entity-edit",
|
|
31569
|
-
item: F(
|
|
31571
|
+
item: F(Ee)
|
|
31570
31572
|
}, null, 8, ["item"])
|
|
31571
31573
|
]),
|
|
31572
31574
|
_: 2
|
|
31573
31575
|
}, 1032, ["auth-function"]),
|
|
31574
31576
|
!p.value && !m.value && u(h) ? (I(), Q(u(Pi), {
|
|
31575
31577
|
key: 0,
|
|
31576
|
-
"auth-function": () => e.canConfigureDynamicOrdering(
|
|
31578
|
+
"auth-function": () => e.canConfigureDynamicOrdering(Ee)
|
|
31577
31579
|
}, {
|
|
31578
31580
|
default: N(() => [
|
|
31579
|
-
$(
|
|
31581
|
+
$(Ee) ? (I(), Q(fe, {
|
|
31580
31582
|
key: 0,
|
|
31581
31583
|
"data-testid": "action-entity-config-dyn-order",
|
|
31582
|
-
item: $(
|
|
31584
|
+
item: $(Ee)
|
|
31583
31585
|
}, null, 8, ["item"])) : ge("", !0)
|
|
31584
31586
|
]),
|
|
31585
31587
|
_: 2
|
|
31586
31588
|
}, 1032, ["auth-function"])) : ge("", !0),
|
|
31587
31589
|
C(u(Pi), {
|
|
31588
|
-
"auth-function": () => e.canDelete(
|
|
31590
|
+
"auth-function": () => e.canDelete(Ee)
|
|
31589
31591
|
}, {
|
|
31590
31592
|
default: N(() => [
|
|
31591
31593
|
C(fe, {
|
|
31592
31594
|
danger: "",
|
|
31593
31595
|
"data-testid": "action-entity-delete",
|
|
31594
31596
|
"has-divider": "",
|
|
31595
|
-
onClick: ($e) => ce(
|
|
31597
|
+
onClick: ($e) => ce(Ee)
|
|
31596
31598
|
}, {
|
|
31597
31599
|
default: N(() => [
|
|
31598
31600
|
Le(ue(u(r)("actions.delete")), 1)
|
|
@@ -31608,7 +31610,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31608
31610
|
!E.value && e.config.app === "konnect" ? {
|
|
31609
31611
|
name: "empty-state",
|
|
31610
31612
|
fn: N(() => {
|
|
31611
|
-
var
|
|
31613
|
+
var Ee;
|
|
31612
31614
|
return [
|
|
31613
31615
|
C(_e, {
|
|
31614
31616
|
"data-testid": e.config.entityId ? "nested-plugins-entity-empty-state" : "plugins-entity-empty-state",
|
|
@@ -31620,7 +31622,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31620
31622
|
C(u(hg), { decorative: "" })
|
|
31621
31623
|
]),
|
|
31622
31624
|
action: N(() => [
|
|
31623
|
-
He.value ? (I(), Q(
|
|
31625
|
+
He.value ? (I(), Q(Ce, {
|
|
31624
31626
|
key: 0,
|
|
31625
31627
|
"data-testid": "entity-create-button",
|
|
31626
31628
|
onClick: Be
|
|
@@ -31631,7 +31633,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31631
31633
|
]),
|
|
31632
31634
|
_: 1
|
|
31633
31635
|
})) : ge("", !0),
|
|
31634
|
-
C(
|
|
31636
|
+
C(Ce, {
|
|
31635
31637
|
appearance: "secondary",
|
|
31636
31638
|
"data-testid": "entity-learn-more-button",
|
|
31637
31639
|
onClick: Se[2] || (Se[2] = ($e) => Ue.$emit("click:learn-more"))
|
|
@@ -31645,7 +31647,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
31645
31647
|
]),
|
|
31646
31648
|
_: 2
|
|
31647
31649
|
}, [
|
|
31648
|
-
(
|
|
31650
|
+
(Ee = e.config) != null && Ee.isControlPlaneGroup ? {
|
|
31649
31651
|
name: "default",
|
|
31650
31652
|
fn: N(() => [
|
|
31651
31653
|
Le(ue(u(r)("plugins.list.empty_state_v2.group")), 1)
|
|
@@ -32500,9 +32502,9 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32500
32502
|
return {};
|
|
32501
32503
|
const oe = c.value.toLowerCase(), ee = JSON.parse(JSON.stringify(E.value));
|
|
32502
32504
|
for (const fe in E.value) {
|
|
32503
|
-
const Ae = ((le = E.value[fe]) == null ? void 0 : le.filter((
|
|
32505
|
+
const Ae = ((le = E.value[fe]) == null ? void 0 : le.filter((Ee) => {
|
|
32504
32506
|
var $e, g;
|
|
32505
|
-
return
|
|
32507
|
+
return Ee.name.toLowerCase().includes(oe) || Ee.id.toLowerCase().includes(oe) || Ee.group.toLowerCase().includes(oe) || (($e = Ee.clonedFromRef) == null ? void 0 : $e.toLowerCase().includes(oe)) || ((g = Ee.customPluginType) == null ? void 0 : g.toLowerCase().includes(oe));
|
|
32506
32508
|
})) || [];
|
|
32507
32509
|
Ae.length ? ee[fe] = Ae : delete ee[fe];
|
|
32508
32510
|
}
|
|
@@ -32542,10 +32544,10 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32542
32544
|
return n.config.entityType === "services" && l[Ae] && !l[Ae].scope.includes(Rt.SERVICE) || n.config.entityType === "routes" && l[Ae] && !l[Ae].scope.includes(Rt.ROUTE) || n.config.entityType === "consumer_groups" && l[Ae] && !l[Ae].scope.includes(Rt.CONSUMER_GROUP) || n.config.entityType === "consumers" && l[Ae] && !l[Ae].scope.includes(Rt.CONSUMER) ? !1 : fe;
|
|
32543
32545
|
}).reduce((fe, Ae) => {
|
|
32544
32546
|
var me;
|
|
32545
|
-
const
|
|
32547
|
+
const Ee = l[Ae] && l[Ae].name || Ae, $e = oe.get(Ae), g = ee.has(Ae), Z = {
|
|
32546
32548
|
...l[Ae],
|
|
32547
32549
|
id: Ae,
|
|
32548
|
-
name:
|
|
32550
|
+
name: Ee,
|
|
32549
32551
|
available: _.value.includes(Ae) || !!$e || g,
|
|
32550
32552
|
disabledMessage: "",
|
|
32551
32553
|
group: ((me = l[Ae]) == null ? void 0 : me.group) || et.CUSTOM_PLUGINS
|
|
@@ -32648,7 +32650,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32648
32650
|
le,
|
|
32649
32651
|
fe,
|
|
32650
32652
|
Ae,
|
|
32651
|
-
|
|
32653
|
+
Ee,
|
|
32652
32654
|
$e
|
|
32653
32655
|
] = await Promise.all([
|
|
32654
32656
|
n.canCreateCustomPlugin(),
|
|
@@ -32659,12 +32661,12 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32659
32661
|
n.canDeleteClonedPlugin ? n.canDeleteClonedPlugin() : Promise.resolve(null),
|
|
32660
32662
|
n.canReadClonedPlugin()
|
|
32661
32663
|
]);
|
|
32662
|
-
je.value = oe, Be.value = ee, qe.value = le, He.value = fe, Je.value = Ae ?? ee, at.value =
|
|
32664
|
+
je.value = oe, Be.value = ee, qe.value = le, He.value = fe, Je.value = Ae ?? ee, at.value = Ee ?? le, Ue.value = $e;
|
|
32663
32665
|
});
|
|
32664
|
-
const
|
|
32666
|
+
const Ce = Et("filter-input");
|
|
32665
32667
|
return fn(async () => {
|
|
32666
32668
|
var oe, ee;
|
|
32667
|
-
w.value = !0, (ee = (oe =
|
|
32669
|
+
w.value = !0, (ee = (oe = Ce.value) == null ? void 0 : oe.input) == null || ee.focus(), await ve();
|
|
32668
32670
|
}), Xe(
|
|
32669
32671
|
() => {
|
|
32670
32672
|
var oe;
|
|
@@ -32685,7 +32687,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32685
32687
|
var oe;
|
|
32686
32688
|
(oe = k.value) == null || oe.abort();
|
|
32687
32689
|
}), (oe, ee) => {
|
|
32688
|
-
const le = Ie("KInput"), fe = Ie("KSkeletonBox"), Ae = Ie("KSkeleton"),
|
|
32690
|
+
const le = Ie("KInput"), fe = Ie("KSkeletonBox"), Ae = Ie("KSkeleton"), Ee = Ie("KEmptyState"), $e = Ie("KTooltip"), g = Ie("KAlert"), Z = Ie("KTabs");
|
|
32689
32691
|
return I(), re("div", CM, [
|
|
32690
32692
|
te("div", EM, [
|
|
32691
32693
|
C(le, {
|
|
@@ -32709,7 +32711,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32709
32711
|
class: "plugins-skeleton-cards",
|
|
32710
32712
|
type: "card"
|
|
32711
32713
|
})
|
|
32712
|
-
])) : m.value ? (I(), Q(
|
|
32714
|
+
])) : m.value ? (I(), Q(Ee, {
|
|
32713
32715
|
key: 1,
|
|
32714
32716
|
"action-button-visible": !1,
|
|
32715
32717
|
"data-testid": "plugins-fetch-error",
|
|
@@ -32719,7 +32721,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
32719
32721
|
te("h3", null, ue(h.value), 1)
|
|
32720
32722
|
]),
|
|
32721
32723
|
_: 1
|
|
32722
|
-
})) : U.value && c.value ? (I(), Q(
|
|
32724
|
+
})) : U.value && c.value ? (I(), Q(Ee, {
|
|
32723
32725
|
key: 2,
|
|
32724
32726
|
"action-button-visible": !1,
|
|
32725
32727
|
"data-testid": "plugins-empty-state",
|
|
@@ -33380,8 +33382,8 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33380
33382
|
},
|
|
33381
33383
|
emits: ["loading", "plugin-clicked", "delete-custom:success"],
|
|
33382
33384
|
setup(e, { emit: t }) {
|
|
33383
|
-
var
|
|
33384
|
-
const n = t, { i18n: { t: i } } = ut.useI18n(), { pluginMetaData: o } = ut.usePluginMetaData(), { getMessageFromError: r } = Ti(), { sortAlpha: a, objectsAreEqual: l } = xa(), s = e, { axiosInstance: d } = Cn((
|
|
33385
|
+
var Ce;
|
|
33386
|
+
const n = t, { i18n: { t: i } } = ut.useI18n(), { pluginMetaData: o } = ut.usePluginMetaData(), { getMessageFromError: r } = Ti(), { sortAlpha: a, objectsAreEqual: l } = xa(), s = e, { axiosInstance: d } = Cn((Ce = s.config) == null ? void 0 : Ce.axiosRequestConfig), f = Et("filter-input"), c = de(""), p = de(!1), m = de(!1), h = de(Object.fromEntries(Hs.concat(Ws).map((_e) => [_e, !1]))), y = de(!0), _ = de(!1), v = de(""), b = de(""), E = de([]), A = de([]), k = de([]), w = de({}), T = de([]), P = de(!1), j = de(null), S = de(!1), x = L(() => P.value ? Ag : Ig), O = ft(pi.KM_2485_CLONED_PLUGINS, !1), R = L(() => u(O)), D = (_e) => _e === "none" || _e === "disabled" ? /* @__PURE__ */ new Set() : new Set(Array.isArray(_e) ? _e : [_e]), W = L(() => D(s.customPluginSupport)), X = L(() => [...W.value].sort().join("|")), J = L(() => W.value.has("streaming")), q = L(() => R.value && W.value.has("cloned")), G = (_e) => go(_e) && _e.code === "ERR_CANCELED", M = (_e) => r(_e).toLowerCase().includes("requires a license"), U = L(() => {
|
|
33385
33387
|
var oe;
|
|
33386
33388
|
let _e = `${s.config.apiBaseUrl}${it.select[s.config.app].availablePlugins}`;
|
|
33387
33389
|
if (s.config.app === "konnect")
|
|
@@ -33408,7 +33410,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33408
33410
|
}
|
|
33409
33411
|
return "";
|
|
33410
33412
|
}), $ = L(() => {
|
|
33411
|
-
var
|
|
33413
|
+
var Ee;
|
|
33412
33414
|
if (!w.value)
|
|
33413
33415
|
return {};
|
|
33414
33416
|
const _e = Object.entries(h.value).filter(([, $e]) => $e).map(([$e]) => $e);
|
|
@@ -33421,7 +33423,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33421
33423
|
return oe;
|
|
33422
33424
|
const le = JSON.parse(JSON.stringify(oe));
|
|
33423
33425
|
for (const $e in oe) {
|
|
33424
|
-
const g = ((
|
|
33426
|
+
const g = ((Ee = oe[$e]) == null ? void 0 : Ee.filter((Z) => [
|
|
33425
33427
|
Z.name.toLowerCase(),
|
|
33426
33428
|
Z.id.toLowerCase()
|
|
33427
33429
|
// plugin.group.toLowerCase(),
|
|
@@ -33453,10 +33455,10 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33453
33455
|
return s.config.entityType === "services" && o[Ae] && !o[Ae].scope.includes(Rt.SERVICE) || s.config.entityType === "routes" && o[Ae] && !o[Ae].scope.includes(Rt.ROUTE) || s.config.entityType === "consumer_groups" && o[Ae] && !o[Ae].scope.includes(Rt.CONSUMER_GROUP) || s.config.entityType === "consumers" && o[Ae] && !o[Ae].scope.includes(Rt.CONSUMER) ? !1 : fe;
|
|
33454
33456
|
}).reduce((fe, Ae) => {
|
|
33455
33457
|
var me;
|
|
33456
|
-
const
|
|
33458
|
+
const Ee = o[Ae] && o[Ae].name || Ae, $e = _e.get(Ae), g = oe.has(Ae), Z = {
|
|
33457
33459
|
...o[Ae],
|
|
33458
33460
|
id: Ae,
|
|
33459
|
-
name:
|
|
33461
|
+
name: Ee,
|
|
33460
33462
|
available: E.value.includes(Ae) || !!$e || g,
|
|
33461
33463
|
disabledMessage: "",
|
|
33462
33464
|
group: ((me = o[Ae]) == null ? void 0 : me.group) || et.CUSTOM_PLUGINS
|
|
@@ -33467,15 +33469,15 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33467
33469
|
return ke || (ke = []), ke.push(Z), ke.sort(a("name")), fe[be] = ke, fe;
|
|
33468
33470
|
}, {});
|
|
33469
33471
|
if (s.highlightedPluginIds && s.highlightedPluginIds.length > 0) {
|
|
33470
|
-
const fe = new Set(Object.values(le).flat().map((
|
|
33472
|
+
const fe = new Set(Object.values(le).flat().map((Ee) => Ee == null ? void 0 : Ee.id)), Ae = s.highlightedPluginIds.flatMap((Ee) => {
|
|
33471
33473
|
var g;
|
|
33472
|
-
const $e = o[
|
|
33473
|
-
return !$e || !fe.has(
|
|
33474
|
+
const $e = o[Ee];
|
|
33475
|
+
return !$e || !fe.has(Ee) ? [] : {
|
|
33474
33476
|
...$e,
|
|
33475
|
-
id:
|
|
33476
|
-
name: $e.name ||
|
|
33477
|
-
available: E.value.includes(
|
|
33478
|
-
disabledMessage: ((g = s.disabledPlugins) == null ? void 0 : g[
|
|
33477
|
+
id: Ee,
|
|
33478
|
+
name: $e.name || Ee,
|
|
33479
|
+
available: E.value.includes(Ee),
|
|
33480
|
+
disabledMessage: ((g = s.disabledPlugins) == null ? void 0 : g[Ee]) || "",
|
|
33479
33481
|
group: $e.group || et.CUSTOM_PLUGINS
|
|
33480
33482
|
};
|
|
33481
33483
|
}).filter(Boolean);
|
|
@@ -33584,7 +33586,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33584
33586
|
var _e;
|
|
33585
33587
|
(_e = j.value) == null || _e.abort();
|
|
33586
33588
|
}), (_e, oe) => {
|
|
33587
|
-
const ee = Ie("KButton"), le = Ie("KCheckbox"), fe = Ie("KBadge"), Ae = Ie("KCollapse"),
|
|
33589
|
+
const ee = Ie("KButton"), le = Ie("KCheckbox"), fe = Ie("KBadge"), Ae = Ie("KCollapse"), Ee = Ie("KInput"), $e = Ie("KSkeletonBox"), g = Ie("KSkeleton"), Z = Ie("KEmptyState"), be = Ie("KAlert");
|
|
33588
33590
|
return I(), re("div", cL, [
|
|
33589
33591
|
te("div", dL, [
|
|
33590
33592
|
te("div", pL, [
|
|
@@ -33675,7 +33677,7 @@ const FR = { class: "kong-ui-entities-plugin-form" }, KR = {
|
|
|
33675
33677
|
]),
|
|
33676
33678
|
te("div", _L, [
|
|
33677
33679
|
te("div", bL, [
|
|
33678
|
-
C(
|
|
33680
|
+
C(Ee, {
|
|
33679
33681
|
ref: "filter-input",
|
|
33680
33682
|
modelValue: c.value,
|
|
33681
33683
|
"onUpdate:modelValue": oe[2] || (oe[2] = (ke) => c.value = ke),
|