UNPKG

yanzhen-design-vue

Version:

24 lines (23 loc) 857 B
import { defineAsyncComponent } from "vue"; import { defineComponent, withInstall } from "@yanzhen-lowcode/core"; import "../text-preview/index.mjs"; import { formulaProps, formulaEmits } from "./src/formula.mjs"; import { defineTextPreviewComponent, YzSchemaTextPreview } from "../text-preview/schema.mjs"; const SchemaFormulaOptions = { props: formulaProps, emits: formulaEmits, styleImport: () => import("./style/index.mjs") }; const PreviewFormula = defineTextPreviewComponent("preview-formula", { ...SchemaFormulaOptions, component: YzSchemaTextPreview.component }); const Formula = defineComponent("formula", { ...SchemaFormulaOptions, component: defineAsyncComponent(() => import("./src/formula.vue.mjs")) }); const YzSchemaFormula = withInstall(Formula, { PreviewFormula }); export { YzSchemaFormula, YzSchemaFormula as default };