UNPKG

ai-form-designer

Version:

vue3+adv的设计器,可视化开发页面表单

31 lines (30 loc) 899 B
import { defineComponent as u, inject as d, useAttrs as i, computed as h, createBlock as f, openBlock as g, unref as v, mergeProps as _ } from "vue"; import { Select as I } from "ant-design-vue"; const j = /* @__PURE__ */ u({ __name: "rel-select", props: { componentSchema: { type: Object, default: () => { } } }, emits: ["update:value"], setup(c, { emit: a }) { const p = d("pageManager", {}), n = c, t = i(), s = a, m = h(() => ({ ...t, value: t.modelValue, "onUpdate:value": r })); function r(e = null) { s("update:value", e); } function l(e, o) { n.componentSchema.componentProps.childId && p.componentInstances.value[n.componentSchema.componentProps.childId].setAttr("options", o.children); } return (e, o) => (g(), f(v(I), _(m.value, { onChange: l }), null, 16)); } }); export { j as default };