@javaguns/flow-ui
Version:
``` <template> <a-spin :spinning="loading"> <FlowDesigner ref="flowDesigner" top="50px"> </FlowDesigner> </a-spin> </template> <script lang="ts" setup> import { ref, provide, onMounted } from 'vue'; import { FlowDesigner, LoadingKey } from '@j
50 lines (49 loc) • 1.83 kB
JavaScript
import { defineComponent as _, toRefs as y, openBlock as o, createElementBlock as l, createElementVNode as e, createVNode as a, unref as t, createBlock as g, Fragment as C, renderList as b, toDisplayString as c } from "vue";
import { pluginManager as E } from "@javaguns/utils";
import { IconDeleteOutline as r } from "@javaguns/icon";
const N = { class: "flow-select-list" }, V = { class: "selected-top" }, A = /* @__PURE__ */ e("span", null, "已选", -1), B = { class: "selected-del" }, w = { class: "selected-bottom" }, x = { class: "bottom-list" }, D = { key: 1 }, F = { class: "selected-name" }, I = { class: "selected-del" }, L = _({ name: "flow-selection-list" }), j = /* @__PURE__ */ _({
...L,
props: {
datas: {}
},
emits: ["delete", "deleteAll"],
setup(m, { emit: p }) {
const u = E.getComponent("Empty"), f = m, { datas: n } = y(f), d = p, h = (i) => {
d("delete", i);
}, k = () => {
d("deleteAll");
};
return (i, M) => (o(), l("div", N, [
e("div", V, [
A,
e("span", B, [
a(t(r), { onClick: k })
])
]),
e("div", w, [
e("div", x, [
t(n) && t(n).length == 0 ? (o(), g(t(u), {
key: 0,
description: "暂无数据"
})) : (o(), l("div", D, [
(o(!0), l(C, null, b(t(n), (s, v) => (o(), l("div", {
class: "list",
key: s.id
}, [
e("div", F, c(v + 1) + " " + c(s.subValueName ? s.subValueName + "#" : "") + c(s.name), 1),
e("div", I, [
a(t(r), {
style: { color: "red" },
onClick: (O) => h(s)
}, null, 8, ["onClick"])
])
]))), 128))
]))
])
])
]));
}
});
export {
j as default
};