epic-designer-gold 1.0.30 → 1.0.32
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/{_vue_commonjs-external-BbihI59z.cjs → _vue_commonjs-external-CccDNqHl.cjs} +1 -1
- package/dist/attributeView-3gE9ZveH.cjs +1 -0
- package/dist/{attributeView-CSiGWdPc.js → attributeView-Dcfm_fDW.js} +22 -22
- package/dist/{az-CJXcaytS.cjs → az-BHlmRKxT.cjs} +1 -1
- package/dist/be-Bix86zGn.cjs +1 -0
- package/dist/be-kPl6P6VI.js +37 -0
- package/dist/{bg-DCT06eJE.cjs → bg-DRyWA3-W.cjs} +1 -1
- package/dist/{bn-bd-DaKs5QkR.cjs → bn-bd-DsQtVph4.cjs} +1 -1
- package/dist/{button-BbHi0DmU.js → button-q-1FLMFj.js} +2 -2
- package/dist/{ca-DCcDFeSK.js → ca-B_2hM20M.js} +6 -6
- package/dist/core/components/asyncLoader/index.vue.d.ts +1 -1
- package/dist/core/components/builder/src/builder.vue.d.ts +6 -11
- package/dist/core/components/designer/src/designer.vue.d.ts +200 -9
- package/dist/core/components/designer/src/modules/actionBar/index.vue.d.ts +1 -1
- package/dist/core/components/designer/src/modules/attributeView/attributeView.vue.d.ts +1 -1
- package/dist/core/components/designer/src/modules/attributeView/eventView.vue.d.ts +1 -1
- package/dist/core/components/designer/src/modules/attributeView/styleView.vue.d.ts +1 -1
- package/dist/core/components/designer/src/modules/componentView/index.vue.d.ts +1 -1
- package/dist/core/components/designer/src/modules/editContainer/editNodeItem.vue.d.ts +4 -5
- package/dist/core/components/designer/src/modules/editContainer/editScreenContainer.vue.d.ts +7 -2
- package/dist/core/components/designer/src/modules/editContainer/index.vue.d.ts +19 -1
- package/dist/core/components/designer/src/modules/editContainer/nodeItem.vue.d.ts +3 -5
- package/dist/core/components/designer/src/modules/editContainer/previewJson.vue.d.ts +3 -1
- package/dist/core/components/designer/src/modules/editContainer/previewWidgets.vue.d.ts +5 -1
- package/dist/core/components/designer/src/modules/editContainer/toolbar.vue.d.ts +17 -1
- package/dist/core/components/designer/src/modules/header/index.vue.d.ts +6 -5
- package/dist/core/components/designer/src/modules/outline/outline.vue.d.ts +1 -1
- package/dist/core/components/designer/src/modules/preview/index.vue.d.ts +85 -1
- package/dist/core/components/designer/src/modules/rightSidebar/breadcrumb.vue.d.ts +1 -1
- package/dist/core/components/icon/src/icon.vue.d.ts +4 -6
- package/dist/core/components/node/src/dynamicFormItem.vue.d.ts +12 -11
- package/dist/core/components/node/src/node.vue.d.ts +19 -24
- package/dist/core/components/tree/src/tree.vue.d.ts +1 -1
- package/dist/core/components/tree/src/treeNodeItem.vue.d.ts +3 -4
- package/dist/core/components/tree/src/treeNodes.vue.d.ts +4 -6
- package/dist/core/extensions/EActionEditor/index.vue.d.ts +25 -1
- package/dist/core/extensions/EActionEditor/src/EArgsEditor.vue.d.ts +5 -7
- package/dist/core/extensions/EActionEditor/src/EScriptEdit.vue.d.ts +3 -1
- package/dist/core/extensions/EColEditor/index.vue.d.ts +1 -1
- package/dist/core/extensions/EColumnEditor/columnItem.vue.d.ts +4 -5
- package/dist/core/extensions/EColumnEditor/index.vue.d.ts +5 -9
- package/dist/core/extensions/EDataSource/index.vue.d.ts +3 -1
- package/dist/core/extensions/EDescribe/index.vue.d.ts +9 -0
- package/dist/core/extensions/EInputSize/index.vue.d.ts +4 -5
- package/dist/core/extensions/EOptionsEditor/index.vue.d.ts +9 -13
- package/dist/core/extensions/EOptionsEditor/optionItem.vue.d.ts +4 -5
- package/dist/core/extensions/ERuleEditor/ERuleItem.vue.d.ts +5 -6
- package/dist/core/extensions/ERuleEditor/index.vue.d.ts +1 -1
- package/dist/core/extensions/ESourceDataSelect/index.vue.d.ts +6 -10
- package/dist/core/extensions/EValidateParam/index.vue.d.ts +13 -0
- package/dist/core/extensions/MonacoEditor/index.vue.d.ts +15 -21
- package/dist/core/extensions/PaddingMarginControl/index.vue.d.ts +5 -6
- package/dist/core/extensions/Page/index.vue.d.ts +7 -7
- package/dist/{cs-D_hyDJBU.cjs → cs-fe0nQEUY.cjs} +1 -1
- package/dist/{de-CjumkRE8.js → de-DC7xuNPN.js} +3 -3
- package/dist/{el-DyUHskgW.js → el-C0J72FUl.js} +2 -2
- package/dist/{el-BCec0wpC.cjs → el-CUlPbKiq.cjs} +1 -1
- package/dist/{en-gb-C8f1Enek.js → en-gb-D42jaZg9.js} +5 -5
- package/dist/{es-DP04S73E.js → es-C058DgcQ.js} +4 -4
- package/dist/{es-BFLRglxD.cjs → es-CV4N9sQJ.cjs} +1 -1
- package/dist/{et-ipLqjCDG.js → et-hoTk9uxt.js} +5 -5
- package/dist/{eventView-5fa6mfSD.cjs → eventView-BExxE07B.cjs} +1 -1
- package/dist/{eventView-C2wKhfU_.js → eventView-eNaiVabA.js} +4 -4
- package/dist/{fade-in-scale-up.cssr-C_UMnGtI.cjs → fade-in-scale-up.cssr-D5DdSaTl.cjs} +1 -1
- package/dist/{fade-in-scale-up.cssr-BXjoIAAA.js → fade-in-scale-up.cssr-XJx96aae.js} +1 -1
- package/dist/{form-ChuxpD-f.cjs → form-BfnGWRf4.cjs} +1 -1
- package/dist/form-CUbklubB.cjs +1 -0
- package/dist/form-DGbjgAvD.js +208 -0
- package/dist/{form-Cr7tBgLQ.js → form-DkDGcNCH.js} +7 -7
- package/dist/{form-BPH0cDFl.js → form-r1D2WYPd.js} +3 -3
- package/dist/{formItem-D10Om12T.js → formItem-B6XaNgi9.js} +2 -2
- package/dist/{formItem-cj8JQT2r.js → formItem-BJ-M4LAL.js} +2 -2
- package/dist/{formItem-Do31LPIz.cjs → formItem-DS5AjuJ9.cjs} +1 -1
- package/dist/{formItem-DPnbV4m-.js → formItem-E3dd7dU1.js} +3 -3
- package/dist/{fr-D1kezmpm.cjs → fr-B_IotmK8.cjs} +1 -1
- package/dist/{fr-ca-EPfCD7sc.js → fr-ca-DfJb7eFN.js} +4 -4
- package/dist/ga-DP4_Ma79.js +22 -0
- package/dist/ga-Upa8swLh.cjs +1 -0
- package/dist/{gl-CBMDu4db.js → gl-L0SOKqrF.js} +1 -1
- package/dist/{gl-DI-aVaAh.cjs → gl-buZ-VDaz.cjs} +1 -1
- package/dist/{he-O14-JKYm.cjs → he-CwFEkyZP.cjs} +1 -1
- package/dist/{hi-nXeMgLvO.js → hi-CG6raJ8L.js} +2 -2
- package/dist/{hy-am-BLnv1pCz.cjs → hy-am-IbMCW8s4.cjs} +1 -1
- package/dist/{hy-am-CvHDFapi.js → hy-am-QWdQfrnZ.js} +2 -2
- package/dist/{icon.vue_vue_type_script_setup_true_lang-D3QdcReY.js → icon.vue_vue_type_script_setup_true_lang-DW206h_7.js} +2 -2
- package/dist/{id-CO78nlWo.js → id-CXRpiOjX.js} +4 -4
- package/dist/{index-CU1ZFiwn.cjs → index-2ohl2GLw.cjs} +1 -1
- package/dist/index-3k1IXN1T.js +1772 -0
- package/dist/{index-B0OgKtuT.js → index-9Mn4Y5ul.js} +30 -30
- package/dist/index-B6Ukyb87.js +19 -0
- package/dist/index-B7v1JNbf.cjs +351 -0
- package/dist/index-BAbwPcMn.cjs +1 -0
- package/dist/index-BB6SDXJs.cjs +1 -0
- package/dist/{index-DgcFxYFp.js → index-BMXnkqXx.js} +3 -3
- package/dist/{index-CCCx1tbF.cjs → index-BRAbfTxT.cjs} +1 -1
- package/dist/index-BRSms-yQ.cjs +10 -0
- package/dist/{index-WkZdU_zw.js → index-BTaKazMR.js} +3 -3
- package/dist/index-BU3ulVXO.cjs +51 -0
- package/dist/index-BVGB9juO.cjs +352 -0
- package/dist/index-BWTbnurN.cjs +102 -0
- package/dist/index-BakH-Ay7.js +1513 -0
- package/dist/{index-BENF2JDS.cjs → index-Bc7x5Vkn.cjs} +1 -1
- package/dist/{index-B2RMcVgD.js → index-Bc8u8eU-.js} +3 -3
- package/dist/{index-tSmvj7CR.js → index-BdXFwT-C.js} +749 -721
- package/dist/{index-D1ZL6feZ.js → index-Bf7gu4Ub.js} +28210 -27533
- package/dist/index-BlIhb2K5.cjs +65 -0
- package/dist/{index-DYQi05p8.cjs → index-BozsQqds.cjs} +1 -1
- package/dist/index-BtKa0UKV.cjs +326 -0
- package/dist/{index-RL7vrExY.js → index-Bvn6Y1A5.js} +17 -17
- package/dist/index-C3ri9kGU.cjs +110 -0
- package/dist/index-C4CkFEzv.cjs +1 -0
- package/dist/{index-COyKmK8p.js → index-C4laxGCk.js} +532 -529
- package/dist/{index-DymbM-qI.js → index-C7vJTifa.js} +79 -72
- package/dist/{index-CpTA2IRB.js → index-CAYHjLKP.js} +10 -10
- package/dist/{index-BbTWJKHb.js → index-CEDiZXAp.js} +23 -23
- package/dist/index-CFjfJ0Cn.js +4 -0
- package/dist/index-CGiL64iE.cjs +10 -0
- package/dist/{index-CNOUPCih.js → index-CLAopW_w.js} +143 -142
- package/dist/index-CPjLNlCP.cjs +1 -0
- package/dist/{index-CdnV7DS4.js → index-CQSYlqUB.js} +3 -3
- package/dist/{index-Hdc_C4Xg.js → index-CRaEQ5ns.js} +116 -115
- package/dist/index-CcXd7BgN.js +451 -0
- package/dist/index-CmQ11tKB.js +59 -0
- package/dist/index-CnPBVx5Y.cjs +181 -0
- package/dist/index-CpTUkT9o.cjs +159 -0
- package/dist/index-CqIGF1hQ.cjs +86 -0
- package/dist/{index-lCYWKDlK.js → index-Cqt_axIP.js} +6 -6
- package/dist/index-DAYEBASh.js +1712 -0
- package/dist/{index-FgdbKgb5.cjs → index-DER3z6SG.cjs} +1 -1
- package/dist/{index-Dk0fyxAJ.cjs → index-DKeQ2WZr.cjs} +1 -1
- package/dist/{index-Cx7gKpkD.js → index-DMnyvgEN.js} +3 -3
- package/dist/{index-DaRhLTx9.js → index-DMuf-r1U.js} +489 -489
- package/dist/index-DNmTSnEn.js +122 -0
- package/dist/index-DRzL2wcU.cjs +1 -0
- package/dist/{index-gA02bxwJ.js → index-DUFhAGX3.js} +3443 -3361
- package/dist/{index-CjcjqKkB.js → index-DWSlxQBe.js} +87 -86
- package/dist/{index-DQ9Vb0QH.js → index-Dkj_Zz4E.js} +309 -308
- package/dist/index-DlWUR7vt.cjs +6 -0
- package/dist/{index-D2GF87Tg.cjs → index-DnpZItWQ.cjs} +1 -1
- package/dist/{index-BhMVNODR.js → index-DouKA23f.js} +4 -4
- package/dist/{index-3fW_aWMH.js → index-Ds_DeGh-.js} +581 -567
- package/dist/index-FaOdtMdB.cjs +214 -0
- package/dist/{index-DiDIFoTk.js → index-KXG0ExdR.js} +3 -3
- package/dist/{index-Cmfhlo_3.js → index-Tohe0ps_.js} +5 -5
- package/dist/index-Wv68i_Qm.cjs +1 -0
- package/dist/index-XEUPyaqB.js +655 -0
- package/dist/index-Y9Wgjz5m.cjs +1 -0
- package/dist/{index-v2u1WTMm.cjs → index-aIGMRk0a.cjs} +1 -1
- package/dist/{index-BEUYVwRA.cjs → index-eAXbC_rr.cjs} +1 -1
- package/dist/index-j1FWyAIY.cjs +1 -0
- package/dist/index-o6azVcPr.js +11903 -0
- package/dist/{index-Cln9MN7u.js → index-ocw8DZly.js} +5 -5
- package/dist/index-r7I2iBup.cjs +9 -0
- package/dist/{index-IGxCNti8.js → index-syyNmnFq.js} +5 -5
- package/dist/index-t1QZ07qC.cjs +864 -0
- package/dist/{index-R2r9Rw5O.cjs → index-uyQPLEww.cjs} +1 -1
- package/dist/{index-CpevxZqj.cjs → index-waYHs7SN.cjs} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +6 -6
- package/dist/{is-C40R_fdL.cjs → is-DKGME0z-.cjs} +1 -1
- package/dist/{it-BFF7WzRR.js → it-BtbhD8pq.js} +1 -1
- package/dist/{it-D7K-0U_k.cjs → it-ZWKZeGyD.cjs} +1 -1
- package/dist/{ja-4CWMghxy.js → ja--ZXRcv9f.js} +4 -4
- package/dist/{ja-CAXCMb11.cjs → ja-pfO_QIN1.cjs} +1 -1
- package/dist/{ka-DrA_EMLP.js → ka-2eqGlkEl.js} +2 -2
- package/dist/{kk-Bv8yYeRk.cjs → kk-8gl4nJDr.cjs} +1 -1
- package/dist/{kk-QVPqpI2b.js → kk-U2vwYR0_.js} +2 -2
- package/dist/{km-BmycjYfj.cjs → km-BhO_ypYk.cjs} +1 -1
- package/dist/{km-CBMnSWv_.js → km-CvriZlET.js} +2 -2
- package/dist/{kn-TECqDIit.js → kn-B3fo7baQ.js} +2 -2
- package/dist/{kn-CFiXt5hu.cjs → kn-DbnERw-L.cjs} +1 -1
- package/dist/{lt-D0cq_0yM.js → lt-LJQA5IUB.js} +8 -8
- package/dist/{lv-CoTNe47-.cjs → lv-BOhsxkyH.cjs} +1 -1
- package/dist/{lv-CVdYvxq8.js → lv-mhTNPcB7.js} +6 -6
- package/dist/{mk-DVN6iYK_.cjs → mk-Bjsw8OIP.cjs} +1 -1
- package/dist/{mk-DDuk7A3P.js → mk-CwQCoXyz.js} +2 -2
- package/dist/{ml-DnXJOqZ0.cjs → ml-B2Uwy4uy.cjs} +1 -1
- package/dist/{ml-CPI3tJe8.js → ml-Cb3T32D6.js} +2 -2
- package/dist/{mn-CNbMEx0y.js → mn-CNzb6fwh.js} +2 -2
- package/dist/{mn-DMIrWGkN.cjs → mn-CsItTiQc.cjs} +1 -1
- package/dist/{modal-3Iw7tqyx.js → modal-BRQmBRpE.js} +4 -4
- package/dist/{modal-DZRJyZfk.cjs → modal-BgQNXEZY.cjs} +1 -1
- package/dist/{ms-my-BoMZ8Hzl.cjs → ms-my-BgFBTdYR.cjs} +1 -1
- package/dist/{ms-my-BcgYEtml.js → ms-my-CQBECOnt.js} +6 -6
- package/dist/{nb-BL5QmNEa.js → nb-ChJHZ1i8.js} +2 -2
- package/dist/{ne-9klrwaIE.js → ne-KSsPp_--.js} +4 -4
- package/dist/{ne-VNPqdWFn.cjs → ne-wk64JT9v.cjs} +1 -1
- package/dist/{nl-DBFNL8wC.cjs → nl-B5Fclgi6.cjs} +1 -1
- package/dist/ocrUpload-CMskfGHX.cjs +1 -0
- package/dist/ocrUpload-Cxxs1GtD.js +521 -0
- package/dist/orcSelectPage-CXd59VaA.js +47 -0
- package/dist/orcSelectPage-DY_4W3lm.cjs +1 -0
- package/dist/{outline-BE98qFHQ.cjs → outline-BkNtj_2a.cjs} +1 -1
- package/dist/{outline-Ch5PHy3c.js → outline-S7RIV1S6.js} +4 -4
- package/dist/{pluginManager-BCnrHPYv.js → pluginManager-B0y107-1.js} +1 -1
- package/dist/{pluginManager-DWHAX8kP.cjs → pluginManager-C8aQylGX.cjs} +1 -1
- package/dist/{pt-BaTZB0XW.cjs → pt-BfCV6EE0.cjs} +1 -1
- package/dist/{pt-br-C1mqj5qX.js → pt-br-BC7LLaiM.js} +3 -3
- package/dist/{pt-br-B_N58uu_.cjs → pt-br-Cmqeku7l.cjs} +1 -1
- package/dist/{ro-Cnuhxb40.cjs → ro-BoP4bVrV.cjs} +1 -1
- package/dist/row-CAcx39Av.cjs +1 -0
- package/dist/row-DhORW-4_.js +34 -0
- package/dist/{ru-CCbLARi0.js → ru-CLqP_yvB.js} +5 -5
- package/dist/select-957IpcJa.js +38 -0
- package/dist/select-BgVmNynq.cjs +1 -0
- package/dist/{selectPage-CrdVWKGk.cjs → selectPage-H4G0pWhK.cjs} +1 -1
- package/dist/{selectPage-Bm45M31g.js → selectPage-oM1OpHbJ.js} +3 -3
- package/dist/{sign-BS-9u6is.cjs → sign-Cusu4oCD.cjs} +1 -1
- package/dist/{sign-l63EYvVo.js → sign-Cz5OCE1C.js} +12 -12
- package/dist/{sk-DRjgEzVO.cjs → sk-DvU2x_On.cjs} +1 -1
- package/dist/{sl-CL8MnX8D.js → sl-MH1u3xWj.js} +9 -9
- package/dist/style.css +1 -1
- package/dist/{styleView-DONajUQ-.js → styleView-DlcY7spf.js} +8 -8
- package/dist/{styleView-CrBDikDV.cjs → styleView-v0USu1ar.cjs} +1 -1
- package/dist/{ta-CsfYqZQU.js → ta-CeKe4tRh.js} +2 -2
- package/dist/{tabs-CYH9lAUk.cjs → tabs-5lcSnurM.cjs} +1 -1
- package/dist/{tabs-DCyifACM.js → tabs-Cu4PLnTU.js} +1 -1
- package/dist/{th-C-CGWPlT.cjs → th-B1vCpSkb.cjs} +1 -1
- package/dist/{th-CC5sx7mS.js → th-DuVrYobw.js} +2 -2
- package/dist/theme/var.less +6 -5
- package/dist/{tree.vue_vue_type_script_setup_true_lang-VGvT-OYl.cjs → tree.vue_vue_type_script_setup_true_lang-583kvI0Q.cjs} +1 -1
- package/dist/{tree.vue_vue_type_script_setup_true_lang-BsVyMb-n.js → tree.vue_vue_type_script_setup_true_lang-M13R0TPV.js} +4 -4
- package/dist/ui/antd/button/button.vue.d.ts +2 -1
- package/dist/ui/antd/index.cjs +2 -2
- package/dist/ui/antd/index.js +40 -40
- package/dist/ui/antd/modal/modal.vue.d.ts +3 -2
- package/dist/ui/antd/upload-image/uploadImage.vue.d.ts +1 -1
- package/dist/ui/elementPlus/form/form.vue.d.ts +372 -7
- package/dist/ui/elementPlus/formItem/formItem.vue.d.ts +346 -3
- package/dist/ui/elementPlus/index.cjs +1 -1
- package/dist/ui/elementPlus/index.js +558 -255
- package/dist/ui/elementPlus/modal/modal.d.ts +1 -1
- package/dist/ui/elementPlus/ocr-select-page/index.d.ts +3 -0
- package/dist/ui/elementPlus/ocr-select-page/orcSelectPage.d.ts +8 -0
- package/dist/ui/elementPlus/ocr-upload/index.d.ts +3 -0
- package/dist/ui/elementPlus/ocr-upload/ocrUpload.d.ts +21 -0
- package/dist/ui/naiveUi/form-item/formItem.vue.d.ts +772 -3
- package/dist/ui/naiveUi/index.cjs +1 -1
- package/dist/ui/naiveUi/index.js +11 -11
- package/dist/ui/naiveUi/modal/modal.d.ts +1 -1
- package/dist/{uk-Cc6k-QUE.cjs → uk-8RCZke0G.cjs} +1 -1
- package/dist/uploadFile-CTDuT_4r.cjs +1 -0
- package/dist/uploadFile-D1Wv0mlk.js +90 -0
- package/dist/uploadImage-0mGONFA8.cjs +1 -0
- package/dist/{uploadImage-Db_66X3C.js → uploadImage-DKgjQrSu.js} +4 -4
- package/dist/{uploadImage-DQmVV0jl.js → uploadImage-lNqQKWH3.js} +23 -22
- package/dist/{uploadImage-nwjqcVFU.cjs → uploadImage-r7uyNOKB.cjs} +1 -1
- package/dist/{ur-C0tmW1hr.js → ur-Dj65NIKf.js} +3 -3
- package/dist/utils/manager/pluginManager.d.ts +16 -16
- package/dist/{vi-j1PGHz1o.js → vi-BEZaL78_.js} +4 -4
- package/dist/{vi-Dyfq5Qgz.cjs → vi-aBc6LsS_.cjs} +1 -1
- package/dist/{vuedraggable.umd-BqhSJIAi.cjs → vuedraggable.umd-CxOWsXm8.cjs} +6 -6
- package/dist/{vuedraggable.umd-D2S7Eo7p.js → vuedraggable.umd-D908YPOr.js} +396 -400
- package/dist/{zh-cn-BKQHxHe9.cjs → zh-cn-DTp5Vsak.cjs} +1 -1
- package/dist/{zh-hk-hNFRxlrX.cjs → zh-hk-DvIiOtyL.cjs} +1 -1
- package/dist/{zh-tw-BT16WIrT.js → zh-tw-BZt76cZl.js} +7 -7
- package/dist/{zh-tw-SGOlw9Wo.cjs → zh-tw-OGVt40m9.cjs} +1 -1
- package/package.json +2 -2
- package/dist/attributeView-UzP3tU2D.cjs +0 -1
- package/dist/axios-CXDYiOMX.js +0 -1704
- package/dist/axios-tuVKNgv9.cjs +0 -6
- package/dist/be--_CkdeMD.cjs +0 -1
- package/dist/be-DJzFjqtL.js +0 -22
- package/dist/form-Bofkrmkd.cjs +0 -1
- package/dist/form-VbfBmb63.js +0 -72
- package/dist/ga-B7Rd2JIZ.cjs +0 -1
- package/dist/ga-BcnAx7jm.js +0 -22
- package/dist/index-4PPmJYKt.cjs +0 -51
- package/dist/index-B72l3XQl.js +0 -453
- package/dist/index-B8exdhvc.cjs +0 -1
- package/dist/index-BB9rZNCd.cjs +0 -181
- package/dist/index-BCk0LJsg.cjs +0 -347
- package/dist/index-BHZbtFEF.cjs +0 -1
- package/dist/index-BVUz9lFN.cjs +0 -325
- package/dist/index-BhICtIH5.js +0 -1433
- package/dist/index-BsXm6fLD.js +0 -1493
- package/dist/index-BwLkOBWy.cjs +0 -10
- package/dist/index-C9PHR_YC.js +0 -4
- package/dist/index-CR_tJiJv.js +0 -653
- package/dist/index-CZFPJ6vM.cjs +0 -1
- package/dist/index-Cap7FkuS.cjs +0 -1
- package/dist/index-Cphndmia.cjs +0 -214
- package/dist/index-CraRg8wh.js +0 -107
- package/dist/index-D5WpEOUO.cjs +0 -351
- package/dist/index-DEBQD_h0.cjs +0 -1
- package/dist/index-DMszow96.cjs +0 -110
- package/dist/index-DTzB2pWI.cjs +0 -159
- package/dist/index-DWCSzZfR.cjs +0 -80
- package/dist/index-DyWFUxn5.js +0 -11674
- package/dist/index-RdEhd65J.cjs +0 -65
- package/dist/index-XU85x6vz.cjs +0 -9
- package/dist/index-g5ZjtbqH.cjs +0 -102
- package/dist/index-jx5A2kt8.cjs +0 -850
- package/dist/index-n6H8b6fT.cjs +0 -1
- package/dist/index-zYoSB4fa.cjs +0 -9
- package/dist/row-CkyJ9pQh.js +0 -35
- package/dist/row-NNlPGZRG.cjs +0 -1
- package/dist/select-BvJWp4t6.cjs +0 -1
- package/dist/select-CjWTf5kk.js +0 -45
- package/dist/ui/antd/form/form.vue.d.ts +0 -64
- package/dist/ui/antd/form-item/formItem.vue.d.ts +0 -18
- package/dist/uploadFile-pgvj4Lm9.cjs +0 -1
- package/dist/uploadFile-qCbXuHfd.js +0 -81
- package/dist/uploadImage-B3sOX-5F.cjs +0 -1
|
@@ -0,0 +1,521 @@
|
|
|
1
|
+
import { defineComponent as _, ref as w, watch as W, inject as N, computed as O, h as n, nextTick as T } from "vue";
|
|
2
|
+
import { ElUpload as $, ElButton as H, ElImageViewer as q, ElMessage as g } from "element-plus";
|
|
3
|
+
import { a as G, u as J } from "./index-B1s67XDZ.js";
|
|
4
|
+
const { t: z } = J(), Y = _({
|
|
5
|
+
props: {
|
|
6
|
+
modelValue: {
|
|
7
|
+
type: Array,
|
|
8
|
+
default: () => []
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
emits: ["update:modelValue", "update:ocrData"],
|
|
12
|
+
setup(E, { emit: I, attrs: e }) {
|
|
13
|
+
const s = w([]), v = w(""), j = w(!1), C = w(!1), y = (o) => {
|
|
14
|
+
j.value = o;
|
|
15
|
+
};
|
|
16
|
+
W(s, (o) => {
|
|
17
|
+
I("update:modelValue", o);
|
|
18
|
+
});
|
|
19
|
+
const h = N("disabled", { value: !1 });
|
|
20
|
+
W(
|
|
21
|
+
() => E.modelValue,
|
|
22
|
+
(o) => {
|
|
23
|
+
if (o != null && o.length > 0 && s.value != null) {
|
|
24
|
+
if (s.value === o) return;
|
|
25
|
+
s.value.length = 0, s.value.push(...o);
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
{ deep: !0, immediate: !0 }
|
|
29
|
+
);
|
|
30
|
+
const R = (o, l) => {
|
|
31
|
+
T(() => {
|
|
32
|
+
k ? (s.value = l.filter(
|
|
33
|
+
(t) => {
|
|
34
|
+
var c, i;
|
|
35
|
+
return ((c = t == null ? void 0 : t.response) == null ? void 0 : c.code) === 200 || ((i = t == null ? void 0 : t.response) == null ? void 0 : i.code) === 201;
|
|
36
|
+
}
|
|
37
|
+
), k = !1) : s.value = l;
|
|
38
|
+
});
|
|
39
|
+
}, B = (o) => {
|
|
40
|
+
var d, p, u;
|
|
41
|
+
let l = o.url || ((p = (d = o == null ? void 0 : o.response) == null ? void 0 : d.data) == null ? void 0 : p.url);
|
|
42
|
+
if (!l) return;
|
|
43
|
+
const t = [".jpg", ".jpeg", ".png", ".gif", ".svg", ".bmp", ".webp"], c = ((u = o.name) == null ? void 0 : u.toLowerCase()) || "", i = t.some((f) => c.endsWith(f)), m = c.endsWith(".pdf");
|
|
44
|
+
i ? (v.value = l, C.value = !1, y(!0)) : m ? (v.value = l, C.value = !0, y(!0)) : window.open(l);
|
|
45
|
+
}, L = (o) => {
|
|
46
|
+
var i, m, d, p, u;
|
|
47
|
+
const l = (m = (i = e.componentSchema) == null ? void 0 : i.componentProps) == null ? void 0 : m.accept;
|
|
48
|
+
if (l) {
|
|
49
|
+
const f = l.split(",").map((r) => r.trim().toLowerCase()).filter((r) => r), x = (((d = o.name) == null ? void 0 : d.toLowerCase()) || "").split("."), b = x.length > 1 ? "." + x.pop() : "", a = o.type || "";
|
|
50
|
+
if (!f.some((r) => {
|
|
51
|
+
if (r === "*/*")
|
|
52
|
+
return !0;
|
|
53
|
+
if (r.startsWith("."))
|
|
54
|
+
return b === r;
|
|
55
|
+
if (r.endsWith("/*")) {
|
|
56
|
+
const A = r.split("/")[0];
|
|
57
|
+
return a.startsWith(A + "/");
|
|
58
|
+
} else return r.includes("/") ? a === r || a.startsWith(r + "/") : b === "." + r;
|
|
59
|
+
}))
|
|
60
|
+
return g.error(`只能上传${l}类型的文件!`), !1;
|
|
61
|
+
}
|
|
62
|
+
const t = +(((u = (p = e.componentSchema) == null ? void 0 : p.componentProps) == null ? void 0 : u.maxSize) ?? 10);
|
|
63
|
+
return o.size / 1024 / 1024 < t ? !0 : (g.error(`文件大小不能超过 ${t}MB!`), !1);
|
|
64
|
+
};
|
|
65
|
+
let k = !1;
|
|
66
|
+
const D = (o, l, t) => {
|
|
67
|
+
o.code !== 200 && o.code !== 201 && (g.error(z("uploadFailed")), k = !0), console.log(t);
|
|
68
|
+
}, U = (o, l, t) => {
|
|
69
|
+
g.error(z("uploadFailed")), console.error(o);
|
|
70
|
+
}, F = (o, l) => {
|
|
71
|
+
let { limit: t } = e;
|
|
72
|
+
g.warning(`最多只能上传 ${t} 个文件`);
|
|
73
|
+
}, M = () => {
|
|
74
|
+
var o, l;
|
|
75
|
+
if (s.value.length === 0) {
|
|
76
|
+
g.warning("请先上传文件");
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
if (!(e != null && e.callBackUrl)) {
|
|
80
|
+
g.warning("请先配置回填接口地址");
|
|
81
|
+
return;
|
|
82
|
+
}
|
|
83
|
+
I("update:ocrData", {
|
|
84
|
+
url: s.value.map((t) => {
|
|
85
|
+
var c, i;
|
|
86
|
+
return (i = (c = t.response) == null ? void 0 : c.data) == null ? void 0 : i.url;
|
|
87
|
+
}),
|
|
88
|
+
field: (o = e.componentSchema) == null ? void 0 : o.field,
|
|
89
|
+
label: (l = e.componentSchema) == null ? void 0 : l.label,
|
|
90
|
+
callBackUrl: e == null ? void 0 : e.callBackUrl,
|
|
91
|
+
callBackMethod: e == null ? void 0 : e.callBackMethod,
|
|
92
|
+
callBackField: e == null ? void 0 : e.callBackField,
|
|
93
|
+
callBackDataPath: e == null ? void 0 : e.callBackDataPath,
|
|
94
|
+
validate: e == null ? void 0 : e.validate,
|
|
95
|
+
validateParams: e == null ? void 0 : e.validateParams
|
|
96
|
+
}), e.componentSchema.componentProps = {
|
|
97
|
+
...e.componentSchema.componentProps,
|
|
98
|
+
hasAlreadyOcr: !0
|
|
99
|
+
};
|
|
100
|
+
}, V = O(() => ({
|
|
101
|
+
...e,
|
|
102
|
+
"file-list": s.value,
|
|
103
|
+
beforeUpload: L,
|
|
104
|
+
onChange: R,
|
|
105
|
+
onSuccess: D,
|
|
106
|
+
onError: U,
|
|
107
|
+
onPreview: B,
|
|
108
|
+
onExceed: F
|
|
109
|
+
}));
|
|
110
|
+
return () => n(
|
|
111
|
+
"div",
|
|
112
|
+
{
|
|
113
|
+
class: "epic-ocr-upload",
|
|
114
|
+
style: {
|
|
115
|
+
padding: "20px",
|
|
116
|
+
backgroundColor: "#ffffff",
|
|
117
|
+
borderRadius: "8px",
|
|
118
|
+
boxShadow: "0 2px 12px 0 rgba(0, 0, 0, 0.08)",
|
|
119
|
+
transition: "all 0.3s ease"
|
|
120
|
+
}
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
default: () => {
|
|
124
|
+
var o, l, t, c;
|
|
125
|
+
return [
|
|
126
|
+
// 提示文案
|
|
127
|
+
e.disabled || h.value ? null : n(
|
|
128
|
+
"div",
|
|
129
|
+
{
|
|
130
|
+
style: {
|
|
131
|
+
padding: "16px 20px",
|
|
132
|
+
backgroundColor: "#f0f9ff",
|
|
133
|
+
borderRadius: "6px",
|
|
134
|
+
marginBottom: "20px",
|
|
135
|
+
border: "1px solid #e0f2fe",
|
|
136
|
+
color: "#334155",
|
|
137
|
+
fontSize: "14px",
|
|
138
|
+
lineHeight: "1.5",
|
|
139
|
+
display: "flex",
|
|
140
|
+
alignItems: "flex-start",
|
|
141
|
+
gap: "8px"
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
[
|
|
145
|
+
n("span", {
|
|
146
|
+
class: "icon--epic icon--epic--error-outline-rounded",
|
|
147
|
+
style: {
|
|
148
|
+
color: "#3b82f6",
|
|
149
|
+
fontSize: "16px",
|
|
150
|
+
marginTop: "2px"
|
|
151
|
+
}
|
|
152
|
+
}),
|
|
153
|
+
// "完成文件上传后,点击「回填数据」,系统将自动识别文件内容并填充表单。",
|
|
154
|
+
"操作步骤:① 上传文件 → ② 点击「OCR识别」 → 自动识别并回填信息"
|
|
155
|
+
]
|
|
156
|
+
),
|
|
157
|
+
// 上传按钮
|
|
158
|
+
n(
|
|
159
|
+
$,
|
|
160
|
+
{
|
|
161
|
+
...V.value,
|
|
162
|
+
headers: {
|
|
163
|
+
Authorization: `Bearer ${G.get("Admin-Token")}`
|
|
164
|
+
},
|
|
165
|
+
listType: "picture-card",
|
|
166
|
+
style: {
|
|
167
|
+
marginBottom: e.disabled || h.value ? "0" : "20px"
|
|
168
|
+
}
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
default: () => [
|
|
172
|
+
n(
|
|
173
|
+
"div",
|
|
174
|
+
{
|
|
175
|
+
style: {
|
|
176
|
+
display: "flex",
|
|
177
|
+
flexDirection: "column",
|
|
178
|
+
alignItems: "center",
|
|
179
|
+
justifyContent: "center",
|
|
180
|
+
width: "100%",
|
|
181
|
+
height: "100%",
|
|
182
|
+
cursor: e.disabled || h.value ? "not-allowed" : "pointer",
|
|
183
|
+
opacity: e.disabled || h.value ? 0.6 : 1,
|
|
184
|
+
transition: "all 0.3s ease",
|
|
185
|
+
borderRadius: "6px",
|
|
186
|
+
backgroundColor: "#fafafa"
|
|
187
|
+
}
|
|
188
|
+
},
|
|
189
|
+
[
|
|
190
|
+
n("span", {
|
|
191
|
+
class: "icon--epic icon--epic--cloud-upload-outlined",
|
|
192
|
+
style: {
|
|
193
|
+
marginBottom: "8px",
|
|
194
|
+
color: "#9ca3af",
|
|
195
|
+
fontSize: "28px",
|
|
196
|
+
transition: "all 0.3s ease"
|
|
197
|
+
}
|
|
198
|
+
}),
|
|
199
|
+
n(
|
|
200
|
+
"span",
|
|
201
|
+
{
|
|
202
|
+
style: {
|
|
203
|
+
fontSize: "14px",
|
|
204
|
+
color: "#6b7280",
|
|
205
|
+
fontWeight: 500,
|
|
206
|
+
marginBottom: "4px"
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
z("fileUpload")
|
|
210
|
+
),
|
|
211
|
+
n(
|
|
212
|
+
"span",
|
|
213
|
+
{
|
|
214
|
+
style: {
|
|
215
|
+
fontSize: "12px",
|
|
216
|
+
color: "#9ca3af"
|
|
217
|
+
}
|
|
218
|
+
},
|
|
219
|
+
"支持图片和PDF文件"
|
|
220
|
+
)
|
|
221
|
+
]
|
|
222
|
+
)
|
|
223
|
+
],
|
|
224
|
+
file: ({ file: i }) => {
|
|
225
|
+
var S, x, b;
|
|
226
|
+
const m = [".jpg", ".jpeg", ".png", ".gif", ".svg", ".bmp", ".webp"], d = ((S = i.name) == null ? void 0 : S.toLowerCase()) || "", p = m.some((a) => d.endsWith(a)), u = d.endsWith(".pdf"), f = i.url || ((b = (x = i == null ? void 0 : i.response) == null ? void 0 : x.data) == null ? void 0 : b.url);
|
|
227
|
+
return n(
|
|
228
|
+
"div",
|
|
229
|
+
{
|
|
230
|
+
class: "el-upload-list__item",
|
|
231
|
+
style: {
|
|
232
|
+
backgroundColor: "transparent",
|
|
233
|
+
border: "none",
|
|
234
|
+
display: "flex",
|
|
235
|
+
flexDirection: "column",
|
|
236
|
+
alignItems: "center",
|
|
237
|
+
justifyContent: "center",
|
|
238
|
+
position: "relative",
|
|
239
|
+
cursor: "pointer"
|
|
240
|
+
},
|
|
241
|
+
onClick: () => B(i)
|
|
242
|
+
},
|
|
243
|
+
[
|
|
244
|
+
// 删除按钮
|
|
245
|
+
n(
|
|
246
|
+
"button",
|
|
247
|
+
{
|
|
248
|
+
type: "button",
|
|
249
|
+
class: "el-upload-list__item-delete",
|
|
250
|
+
style: {
|
|
251
|
+
position: "absolute",
|
|
252
|
+
top: "4px",
|
|
253
|
+
right: "4px",
|
|
254
|
+
width: "20px",
|
|
255
|
+
height: "20px",
|
|
256
|
+
border: "none",
|
|
257
|
+
borderRadius: "50%",
|
|
258
|
+
backgroundColor: "rgba(0, 0, 0, 0.6)",
|
|
259
|
+
color: "white",
|
|
260
|
+
fontSize: "12px",
|
|
261
|
+
cursor: "pointer",
|
|
262
|
+
display: "flex",
|
|
263
|
+
alignItems: "center",
|
|
264
|
+
justifyContent: "center",
|
|
265
|
+
transition: "all 0.3s ease",
|
|
266
|
+
zIndex: 10
|
|
267
|
+
},
|
|
268
|
+
onClick: (a) => {
|
|
269
|
+
a.stopPropagation();
|
|
270
|
+
const P = s.value.findIndex((r) => r.uid === i.uid);
|
|
271
|
+
P !== -1 && s.value.splice(P, 1);
|
|
272
|
+
},
|
|
273
|
+
onMouseenter: (a) => {
|
|
274
|
+
a.target && (a.target.style.backgroundColor = "#ff4d4f", a.target.style.transform = "scale(1.1)");
|
|
275
|
+
},
|
|
276
|
+
onMouseleave: (a) => {
|
|
277
|
+
a.target && (a.target.style.backgroundColor = "rgba(0, 0, 0, 0.6)", a.target.style.transform = "scale(1)");
|
|
278
|
+
}
|
|
279
|
+
},
|
|
280
|
+
"×"
|
|
281
|
+
),
|
|
282
|
+
// 缩略图
|
|
283
|
+
n(
|
|
284
|
+
"div",
|
|
285
|
+
{
|
|
286
|
+
style: {
|
|
287
|
+
width: "100%",
|
|
288
|
+
height: "100%",
|
|
289
|
+
display: "flex",
|
|
290
|
+
alignItems: "center",
|
|
291
|
+
justifyContent: "center",
|
|
292
|
+
borderRadius: "4px",
|
|
293
|
+
overflow: "hidden"
|
|
294
|
+
}
|
|
295
|
+
},
|
|
296
|
+
[
|
|
297
|
+
p && f ? n("img", {
|
|
298
|
+
src: f,
|
|
299
|
+
style: {
|
|
300
|
+
width: "100%",
|
|
301
|
+
height: "100%",
|
|
302
|
+
objectFit: "contain"
|
|
303
|
+
}
|
|
304
|
+
}) : u && f ? n(
|
|
305
|
+
"div",
|
|
306
|
+
{
|
|
307
|
+
style: {
|
|
308
|
+
width: "100%",
|
|
309
|
+
height: "100%",
|
|
310
|
+
display: "flex",
|
|
311
|
+
alignItems: "center",
|
|
312
|
+
justifyContent: "center",
|
|
313
|
+
backgroundColor: "white"
|
|
314
|
+
}
|
|
315
|
+
},
|
|
316
|
+
[
|
|
317
|
+
n("img", {
|
|
318
|
+
src: "https://ess-ds.com/statics/gd-data/images/pdf.png",
|
|
319
|
+
style: {
|
|
320
|
+
width: "60%",
|
|
321
|
+
height: "60%",
|
|
322
|
+
objectFit: "contain"
|
|
323
|
+
},
|
|
324
|
+
alt: i.name
|
|
325
|
+
})
|
|
326
|
+
]
|
|
327
|
+
) : n(
|
|
328
|
+
"div",
|
|
329
|
+
{
|
|
330
|
+
style: {
|
|
331
|
+
width: "100%",
|
|
332
|
+
height: "100%",
|
|
333
|
+
display: "flex",
|
|
334
|
+
alignItems: "center",
|
|
335
|
+
justifyContent: "center",
|
|
336
|
+
backgroundColor: "white"
|
|
337
|
+
}
|
|
338
|
+
},
|
|
339
|
+
[
|
|
340
|
+
n("img", {
|
|
341
|
+
src: "https://ess-ds.com/statics/gd-data/images/unknown-file.png",
|
|
342
|
+
style: {
|
|
343
|
+
width: "60%",
|
|
344
|
+
height: "60%",
|
|
345
|
+
objectFit: "contain"
|
|
346
|
+
},
|
|
347
|
+
alt: i.name
|
|
348
|
+
})
|
|
349
|
+
]
|
|
350
|
+
)
|
|
351
|
+
]
|
|
352
|
+
),
|
|
353
|
+
// 文件名
|
|
354
|
+
n(
|
|
355
|
+
"span",
|
|
356
|
+
{
|
|
357
|
+
title: i.name,
|
|
358
|
+
style: {
|
|
359
|
+
marginTop: "4px",
|
|
360
|
+
fontSize: "12px",
|
|
361
|
+
color: "#606266",
|
|
362
|
+
maxWidth: "100%",
|
|
363
|
+
overflow: "hidden",
|
|
364
|
+
textOverflow: "ellipsis",
|
|
365
|
+
whiteSpace: "nowrap",
|
|
366
|
+
textAlign: "center"
|
|
367
|
+
}
|
|
368
|
+
},
|
|
369
|
+
i.name
|
|
370
|
+
)
|
|
371
|
+
]
|
|
372
|
+
);
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
),
|
|
376
|
+
// 回填数据按钮
|
|
377
|
+
e.disabled || h.value ? null : n(
|
|
378
|
+
H,
|
|
379
|
+
{
|
|
380
|
+
disabled: e.disabled || h.value,
|
|
381
|
+
onClick: M,
|
|
382
|
+
style: {
|
|
383
|
+
marginTop: "0",
|
|
384
|
+
width: "100%",
|
|
385
|
+
padding: "10px 24px",
|
|
386
|
+
fontSize: "14px",
|
|
387
|
+
fontWeight: 500,
|
|
388
|
+
borderRadius: "6px",
|
|
389
|
+
backgroundColor: "#3b82f6",
|
|
390
|
+
borderColor: "#3b82f6",
|
|
391
|
+
color: "white",
|
|
392
|
+
transition: "all 0.3s ease"
|
|
393
|
+
}
|
|
394
|
+
},
|
|
395
|
+
{
|
|
396
|
+
default: () => [
|
|
397
|
+
// 按钮内容
|
|
398
|
+
n("span", {
|
|
399
|
+
class: "icon--epic icon--epic--radio-button-checked-outline",
|
|
400
|
+
style: {
|
|
401
|
+
marginRight: "8px",
|
|
402
|
+
fontSize: "16px"
|
|
403
|
+
}
|
|
404
|
+
}),
|
|
405
|
+
"OCR识别"
|
|
406
|
+
]
|
|
407
|
+
}
|
|
408
|
+
),
|
|
409
|
+
// 警告信息显示
|
|
410
|
+
n(
|
|
411
|
+
"div",
|
|
412
|
+
{
|
|
413
|
+
style: {
|
|
414
|
+
marginTop: "8px",
|
|
415
|
+
padding: "12px 16px",
|
|
416
|
+
backgroundColor: "#ff4d4f",
|
|
417
|
+
color: "white",
|
|
418
|
+
borderRadius: "6px",
|
|
419
|
+
fontSize: "14px",
|
|
420
|
+
fontWeight: 500,
|
|
421
|
+
textAlign: "left",
|
|
422
|
+
boxShadow: "0 2px 8px rgba(255, 77, 79, 0.3)",
|
|
423
|
+
display: (l = e.model) != null && l[((o = e.componentSchema) == null ? void 0 : o.field) + "-orcWarningInfo"] ? "block" : "none"
|
|
424
|
+
}
|
|
425
|
+
},
|
|
426
|
+
((c = e.model) == null ? void 0 : c[((t = e.componentSchema) == null ? void 0 : t.field) + "-orcWarningInfo"]) || ""
|
|
427
|
+
),
|
|
428
|
+
// 预览器
|
|
429
|
+
(() => {
|
|
430
|
+
if (j.value)
|
|
431
|
+
return C.value ? n(
|
|
432
|
+
"div",
|
|
433
|
+
{
|
|
434
|
+
class: "el-image-viewer__wrapper",
|
|
435
|
+
style: {
|
|
436
|
+
position: "fixed",
|
|
437
|
+
top: 0,
|
|
438
|
+
left: 0,
|
|
439
|
+
right: 0,
|
|
440
|
+
bottom: 0,
|
|
441
|
+
zIndex: 2e3,
|
|
442
|
+
backgroundColor: "rgba(0, 0, 0, 0.8)",
|
|
443
|
+
display: "flex",
|
|
444
|
+
alignItems: "center",
|
|
445
|
+
justifyContent: "center"
|
|
446
|
+
}
|
|
447
|
+
},
|
|
448
|
+
[
|
|
449
|
+
// 关闭按钮
|
|
450
|
+
n(
|
|
451
|
+
"button",
|
|
452
|
+
{
|
|
453
|
+
style: {
|
|
454
|
+
position: "absolute",
|
|
455
|
+
top: "24px",
|
|
456
|
+
right: "24px",
|
|
457
|
+
width: "36px",
|
|
458
|
+
height: "36px",
|
|
459
|
+
border: "none",
|
|
460
|
+
borderRadius: "50%",
|
|
461
|
+
backgroundColor: "rgba(255, 255, 255, 0.15)",
|
|
462
|
+
color: "white",
|
|
463
|
+
fontSize: "20px",
|
|
464
|
+
cursor: "pointer",
|
|
465
|
+
display: "flex",
|
|
466
|
+
alignItems: "center",
|
|
467
|
+
justifyContent: "center",
|
|
468
|
+
transition: "all 0.3s ease",
|
|
469
|
+
backdropFilter: "blur(8px)"
|
|
470
|
+
},
|
|
471
|
+
onClick: () => y(!1)
|
|
472
|
+
},
|
|
473
|
+
"×"
|
|
474
|
+
),
|
|
475
|
+
// PDF预览内容
|
|
476
|
+
n(
|
|
477
|
+
"div",
|
|
478
|
+
{
|
|
479
|
+
style: {
|
|
480
|
+
width: "90%",
|
|
481
|
+
height: "90%",
|
|
482
|
+
backgroundColor: "white",
|
|
483
|
+
borderRadius: "8px",
|
|
484
|
+
overflow: "hidden",
|
|
485
|
+
position: "relative",
|
|
486
|
+
boxShadow: "0 20px 60px rgba(0, 0, 0, 0.5)",
|
|
487
|
+
maxWidth: "1400px",
|
|
488
|
+
maxHeight: "900px",
|
|
489
|
+
minWidth: "980px",
|
|
490
|
+
minHeight: "600px"
|
|
491
|
+
}
|
|
492
|
+
},
|
|
493
|
+
[
|
|
494
|
+
n("iframe", {
|
|
495
|
+
src: v.value,
|
|
496
|
+
style: {
|
|
497
|
+
width: "100%",
|
|
498
|
+
height: "100%",
|
|
499
|
+
border: "none"
|
|
500
|
+
},
|
|
501
|
+
title: "PDF Preview"
|
|
502
|
+
})
|
|
503
|
+
]
|
|
504
|
+
)
|
|
505
|
+
]
|
|
506
|
+
) : n(q, {
|
|
507
|
+
urlList: [v.value],
|
|
508
|
+
onClose: () => {
|
|
509
|
+
y(!1);
|
|
510
|
+
}
|
|
511
|
+
});
|
|
512
|
+
})()
|
|
513
|
+
];
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
);
|
|
517
|
+
}
|
|
518
|
+
});
|
|
519
|
+
export {
|
|
520
|
+
Y as default
|
|
521
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { defineComponent as r, inject as m, h as b } from "vue";
|
|
2
|
+
/* empty css */
|
|
3
|
+
import { ElSelect as s } from "element-plus";
|
|
4
|
+
const j = r({
|
|
5
|
+
emits: ["update:modelValue", "update:modelValueLabel", "update:selectFillData"],
|
|
6
|
+
setup(V, { emit: a, attrs: e }) {
|
|
7
|
+
const c = m("disabled", { value: !1 });
|
|
8
|
+
e.modelValue && !e.disabled && !c.value && d(e.modelValue);
|
|
9
|
+
function d(l = null) {
|
|
10
|
+
var t, n;
|
|
11
|
+
if (Object.prototype.toString.call(l) === "[object Array]") {
|
|
12
|
+
const u = l.map((o) => {
|
|
13
|
+
var i;
|
|
14
|
+
let p = (i = e.options) == null ? void 0 : i.find((f) => f.value === o);
|
|
15
|
+
return p || {
|
|
16
|
+
label: o,
|
|
17
|
+
value: o
|
|
18
|
+
};
|
|
19
|
+
});
|
|
20
|
+
a("update:modelValueLabel", u);
|
|
21
|
+
} else {
|
|
22
|
+
const u = (t = e.options) == null ? void 0 : t.find((o) => o.value === l);
|
|
23
|
+
u ? a("update:modelValueLabel", u) : a("update:modelValueLabel", {
|
|
24
|
+
label: l,
|
|
25
|
+
value: l
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
a("update:modelValue", l), a("update:selectFillData", {
|
|
29
|
+
value: l,
|
|
30
|
+
field: ((n = e.componentSchema) == null ? void 0 : n.field) || "",
|
|
31
|
+
fillDataSource: e.fillDataSource,
|
|
32
|
+
fillDataParams: e.fillDataParams
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
return () => {
|
|
36
|
+
const l = {
|
|
37
|
+
...e,
|
|
38
|
+
key: String(e.multiple),
|
|
39
|
+
"onUpdate:modelValue": d
|
|
40
|
+
};
|
|
41
|
+
return b(s, l);
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
});
|
|
45
|
+
export {
|
|
46
|
+
j as default
|
|
47
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("vue");;/* empty css */const s=require("element-plus"),b=d.defineComponent({emits:["update:modelValue","update:modelValueLabel","update:selectFillData"],setup(m,{emit:a,attrs:e}){const r=d.inject("disabled",{value:!1});e.modelValue&&!e.disabled&&!r.value&&t(e.modelValue);function t(l=null){var n,i;if(Object.prototype.toString.call(l)==="[object Array]"){const o=l.map(u=>{var p;let c=(p=e.options)==null?void 0:p.find(f=>f.value===u);return c||{label:u,value:u}});a("update:modelValueLabel",o)}else{const o=(n=e.options)==null?void 0:n.find(u=>u.value===l);o?a("update:modelValueLabel",o):a("update:modelValueLabel",{label:l,value:l})}a("update:modelValue",l),a("update:selectFillData",{value:l,field:((i=e.componentSchema)==null?void 0:i.field)||"",fillDataSource:e.fillDataSource,fillDataParams:e.fillDataParams})}return()=>{const l={...e,key:String(e.multiple),"onUpdate:modelValue":t};return d.h(s.ElSelect,l)}}});exports.default=b;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),_=require("./tree.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),_=require("./tree.vue_vue_type_script_setup_true_lang-583kvI0Q.cjs"),f=require("./pluginManager-C8aQylGX.cjs"),m=require("./icon.vue_vue_type_script_setup_true_lang-DJbUD5AQ.cjs"),g={class:"epic-outline"},v=["onMouseenter"],y={class:"max-w-full truncate"},h={class:"epic-node-type-text flex-1 w-0 truncate"},k=e.defineComponent({__name:"outline",setup(N){const n=e.inject("designer"),a=e.inject("pageSchema"),l=e.computed(()=>{var s;const o=(s=n.state.checkedNode)==null?void 0:s.id;return o?[o]:[]});function u(o){n.setCheckedNode(o.componentSchema)}return(o,s)=>{var i;return e.openBlock(),e.createElementBlock("div",g,[e.createVNode(e.unref(_._sfc_main),{options:e.unref(a).schemas,draggable:"","selected-keys":l.value,"hover-key":(i=e.unref(n).state.hoverNode)==null?void 0:i.id,onNodeClick:u},{"tree-node":e.withCtx(({schema:t})=>{var r,c,d;return[e.createElementVNode("div",{class:e.normalizeClass(["epic-text-padding flex",{hidden:(r=t.componentProps)==null?void 0:r.hidden}]),onMouseenter:e.withModifiers(p=>e.unref(n).setHoverNode(t),["stop"]),onMouseleave:s[0]||(s[0]=e.withModifiers(p=>e.unref(n).setHoverNode(null),["stop"]))},[e.createElementVNode("span",y,[(c=t.componentProps)!=null&&c.hidden?(e.openBlock(),e.createBlock(e.unref(m._sfc_main),{key:0,name:"icon--epic--visibility-off-outline-rounded",class:"translate-y-2px"})):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(t.label??((d=e.unref(f.pluginManager).getComponentConfingByType(t.type))==null?void 0:d.defaultSchema.label)),1)]),e.createElementVNode("span",h,e.toDisplayString(t.id),1)],42,v)]}),_:1},8,["options","selected-keys","hover-key"])])}}});exports.default=k;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as g, inject as l, computed as k,
|
|
2
|
-
import { _ as w } from "./tree.vue_vue_type_script_setup_true_lang-
|
|
3
|
-
import { p as B } from "./pluginManager-
|
|
4
|
-
import { _ as V } from "./icon.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import { defineComponent as g, inject as l, computed as k, createElementBlock as v, openBlock as p, createVNode as N, unref as e, withCtx as x, createElementVNode as i, withModifiers as m, normalizeClass as C, createBlock as M, createCommentVNode as S, createTextVNode as b, toDisplayString as u } from "vue";
|
|
2
|
+
import { _ as w } from "./tree.vue_vue_type_script_setup_true_lang-M13R0TPV.js";
|
|
3
|
+
import { p as B } from "./pluginManager-B0y107-1.js";
|
|
4
|
+
import { _ as V } from "./icon.vue_vue_type_script_setup_true_lang-DW206h_7.js";
|
|
5
5
|
const $ = { class: "epic-outline" }, E = ["onMouseenter"], H = { class: "max-w-full truncate" }, P = { class: "epic-node-type-text flex-1 w-0 truncate" }, q = /* @__PURE__ */ g({
|
|
6
6
|
__name: "outline",
|
|
7
7
|
setup(T) {
|
|
@@ -327,7 +327,7 @@ class O {
|
|
|
327
327
|
// 组件分组名称映射,key 为组件原名称,value 为组件分组映射名称
|
|
328
328
|
l(this, "componentGroupNameMap", {});
|
|
329
329
|
// 组件分组排序列表(设置之后,按该数组下标排序)
|
|
330
|
-
l(this, "sortedGroups", ["表单", "布局"]);
|
|
330
|
+
l(this, "sortedGroups", ["表单", "布局", "业务组件"]);
|
|
331
331
|
// 视图容器模型,包含活动栏和右侧边栏的配置
|
|
332
332
|
l(this, "viewsContainers", {
|
|
333
333
|
activitybars: w([]),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var B=Object.defineProperty;var M=(s,e,n)=>e in s?B(s,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):s[e]=n;var l=(s,e,n)=>M(s,typeof e!="symbol"?e+"":e,n);const p=require("vue"),k=require("./index-BoL2PSBk.cjs"),h=(s,e)=>p.defineAsyncComponent({loader:s,loadingComponent:e,delay:80});function m(s=10){const e="abcdefghijklmnopqrstuvwxyz0123456789";let n="";for(let i=0;i<s;i++){const t=Math.floor(Math.random()*e.length);n+=e[t]}return n}function F(s){return s.charAt(0).toUpperCase()+s.slice(1)}const{t:S}=k.useLocale();function d(s,e=new WeakMap){if(typeof s!="object"||s===null)return s;if(e.has(s))return e.get(s);if(Array.isArray(s)){const i=s.map(t=>d(t,e));return e.set(s,i),i}const n={};return e.set(s,n),Object.keys(s).forEach(i=>{n[i]=d(s[i],e)}),n}function P(s){const[e]=x([d(s)],n=>{var t,o;const i={...n,id:`${n.type}_${m(8)}`};return(i.field||i.input)&&!((o=(t=G.getComponentConfingByType(i.type))==null?void 0:t.editConstraints)!=null&&o.fixedField)&&(i.field=i.id),i});return e}function C(s,e,n=!0){for(const[i,t]of Object.entries(e)){let o=s==null?void 0:s[i];o&&t&&typeof o=="object"&&typeof t=="object"?(Array.isArray(o)&&!Array.isArray(t)?o=s[i]={}:!Array.isArray(o)&&Array.isArray(t)&&(o=s[i]=[]),C(o,t,n)):s[i]=t}n&&Object.keys(s).reverse().forEach(i=>{e.hasOwnProperty(i)||(Array.isArray(s)?s.splice(Number(i),1):delete s[i])})}function z(s,e,n=[],i=new WeakMap){const t=o=>{if(Array.isArray(o))return o.map(t);if(typeof o=="object"&&o!==null){if(i.has(o))return"[Circular]";i.set(o,!0);const r=Object.keys(o).sort(),a={};return r.forEach(c=>{n.includes(c)||(a[c]=t(o[c]))}),i.delete(o),a}else return o};return JSON.stringify(t(s))===JSON.stringify(t(e))}function E(s,e){const n=[];let i=!1;function t(o){if(n.push(o),o.id===e&&(i=!0),!i&&o.children!=null&&o.children.length>0)for(let r=0;r<o.children.length&&(t(o.children[r]),!i);r++);if(!i&&o.slots)for(let r in o.slots)for(let a=0;a<o.slots[r].length&&(t(o.slots[r][a]),!i);a++);i||n.pop()}return s.forEach(t),i||console.error(`没有查询到id为${e}的节点`),n}function O(s,e,n){const i=e.split(".");let t=s;for(let o=0;o<i.length;o++){if(t==null)return n;t=t[i[o]]}return t===void 0?n:t}function L(s,e,n){const i=e.replace(/\[(\d+)\]/g,".$1").split(".").filter(Boolean);let t=s;for(let o=0;o<i.length-1;o++){const r=i[o];t[r]==null&&(t[r]=isNaN(Number(i[o+1]))?{}:[]),t=t[r]}return t[i[i.length-1]]=n,s}function R(s,e="default"){return b(s,e).map(i=>i.field)}function b(s,e="default"){const n=f(s,t=>{var o;return t.type==="form"&&(((o=t.componentProps)==null?void 0:o.name)??t.name===e)},!0);return f((n==null?void 0:n.children)??[],t=>!!t.input,!1,t=>t.type!=="subform")}function f(s,e,n=!1,i){const t=[],o=[...s];for(;o.length;){const r=o.pop();if(r!=null&&r.children&&(!i||i(r))&&o.push(...r.children),r!=null&&r.slots&&(!i||i(r)))for(let a in r.slots)o.push(...r.slots[a]);if(e(r)&&(t.push(r),n))return r}return n?!1:t}function x(s,e,n){const i=[...s];for(;i.length;){const t=i.pop();if(t!=null&&t.children&&(!n||n(t))&&i.push(...t.children),t!=null&&t.slots&&(!n||n(t)))for(let o in t.slots)i.push(...t.slots[o]);C(t,e(t))}return s}function T(s,e){const n=f(s,i=>i.id===e,!0);if(!n)throw new Error(`没有查询到id为${e}的节点`);return n}function D(s,e){const n=[{type:"",children:s}];let i=0,t=null;if(f(n,o=>{if(t=o.children??null,!t){if(o!=null&&o.slots)for(let r in o.slots){t=o.slots[r];for(let a=0;a<t.length;a++)if(t[a].id===e)return i=a,!0}return!1}for(let r=0;r<t.length;r++)if(t[r].id===e)return i=r,!0;return!1},!0),!t)throw new Error(`没有查询到id为${e}的节点`);return{list:t,schema:t[i],index:i}}function V(s){const e={schemas:[{type:"page",id:"root",label:S("page"),children:[{label:S("form"),type:"form",icon:"epic-icon-daibanshixiang",labelWidth:s.config.labelWidth||100,name:"default",componentProps:{layout:s.config.layout||"horizontal",labelWidth:s.config.labelWidth||100,labelLayout:s.config.labelLayout==="flex"?"fixed":"flex",labelCol:s.config.labelCol||{span:5},wrapperCol:s.config.wrapperCol||{span:19},hideRequiredMark:s.config.hideRequiredMark||!1,colon:s.config.colon||!0,labelAlign:s.config.labelAlign||"right",size:s.config.size||"middle"},children:[],id:"form_"+m()}],componentProps:{style:{padding:"16px"}}}],script:s.script||""};return e.schemas[0].children[0].children=u(s.list),e}function u(s,e){return s.map(n=>{var c,v,w;let i=n.type??"";const t=n.options??{},o=(y,g)=>{i===y&&(i=g,t.defaultValue&&(t.defaultValue=JSON.parse(t.defaultValue)))};if(o("uploadImg","upload-image"),o("uploadFile","upload-file"),i==="date"&&t.range&&(t.type="daterange",delete t.range),(i==="date"||i==="time")&&(t.valueFormat=t.format),i==="textarea"){const{minRows:y,maxRows:g}=t;t.autoSize={minRows:y,maxRows:g},delete t.minRows,delete t.maxRows}i==="number"&&!t.precision&&delete t.precision,t.width&&(t.style={width:t.width},delete t.width),i==="grid"&&(i="row"),e&&e.type==="grid"&&(i="col",t.span=n.span,n.key=m());const r={label:n.label,type:i,icon:n.icon||"",field:n.model,componentProps:t,id:n.key};return(t.noFormItem||!t.showLabel)&&(r.noFormItem=!0,delete t.noFormItem,delete t.showLabel),t.clearable&&(t.allowClear=!0,delete t.clearable),["input","textarea","number","password","select","cascader","checkbox","radio","date","time","slider","switch","color-picker","upload-file","upload-image"].includes(i)&&(r.input=!0,((v=(c=n.rules)==null?void 0:c[0])==null?void 0:v.required)===!1&&n.rules.shift(),((w=n.rules)==null?void 0:w.length)>0&&(r.rules=n.rules)),n.list&&(r.children=u(n.list,n)),n.columns&&(r.children=u(n.columns,n)),n.trs&&(r.children=u(n.trs,n)),n.tds&&(r.children=u(n.tds,n)),r})}function N(s){return{all:s=s||new Map,on:function(e,n){var i=s.get(e);i?i.push(n):s.set(e,[n])},off:function(e,n){var i=s.get(e);i&&(n?i.splice(i.indexOf(n)>>>0,1):s.set(e,[]))},emit:function(e,n){var i=s.get(e);i&&i.slice().map(function(t){t(n)}),(i=s.get("*"))&&i.slice().map(function(t){t(e,n)})}}}const A=N();class I{constructor(){l(this,"initialized",p.ref(!1));l(this,"sourceData",[]);l(this,"components",{});l(this,"componentConfigs",{});l(this,"baseComponentTypes",[]);l(this,"componentSchemaGroups",p.ref([]));l(this,"hiddenComponents",[]);l(this,"formSchemas",[{label:"表单",type:"form",componentProps:{layout:"horizontal",name:"default",labelWidth:100,labelLayout:"fixed",labelCol:{span:5},wrapperCol:{span:19},colon:!0,labelAlign:"right",labelPlacement:"left"},children:[],id:"root"}]);l(this,"componentGroupNameMap",{});l(this,"sortedGroups",["表单","布局"]);l(this,"viewsContainers",{activitybars:p.shallowRef([]),rightSidebars:p.shallowRef([])});l(this,"publicMethods",{})}component(e,n){typeof n=="function"&&(n=h(n)),this.components[e]=n}registerComponent(e){this.component(e.defaultSchema.type,e.component),e.defaultSchema.input&&(e.config.action||(e.config.action=[]),e.config.action.unshift({type:"setValue",describe:"设置值",argsConfigs:[{...e.defaultSchema,label:"设置数据",field:"0"}]},{type:"getValue",describe:"获取值"})),this.componentConfigs[e.defaultSchema.type]=e,this.computedComponentSchemaGroups()}removeComponent(e){delete this.componentConfigs[e],delete this.components[e]}setSourceData(e){this.sourceData=e,A.emit("updateSource",new Date)}getSourceData(){return Object.prototype.toString.call(this.sourceData)==="[object Array]"?this.sourceData:[]}setBaseComponentTypes(e){this.baseComponentTypes=e}addBaseComponentTypes(e){this.baseComponentTypes.push(e)}removeBaseComponents(){this.baseComponentTypes.forEach(e=>{this.removeComponent(e)}),this.setBaseComponentTypes([]),this.computedComponentSchemaGroups()}getComponents(){return this.components}getComponent(e){return this.components[e]}registerActivitybar(e){typeof e.component=="function"&&(e.component=h(e.component)),typeof e.visible>"u"&&(e.visible=!0);const n=this.viewsContainers.activitybars.value.findIndex(i=>i.id===e.id);n!==-1?this.viewsContainers.activitybars.value[n]=e:this.viewsContainers.activitybars.value.push(e)}getActivitybars(){return this.viewsContainers.activitybars.value}hideActivitybar(e,n="title"){const i=this.viewsContainers.activitybars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.activitybars.value[i].visible=!1)}showActivitybar(e,n="title"){const i=this.viewsContainers.activitybars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.activitybars.value[i].visible=!0)}registerRightSidebar(e){typeof e.component=="function"&&(e.component=h(e.component)),typeof e.visible>"u"&&(e.visible=!0);const n=this.viewsContainers.rightSidebars.value.findIndex(i=>i.id===e.id);n!==-1?this.viewsContainers.rightSidebars.value[n]=e:this.viewsContainers.rightSidebars.value.push(e)}getRightSidebars(){return this.viewsContainers.rightSidebars.value}hideRightSidebar(e,n="title"){const i=this.viewsContainers.rightSidebars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.rightSidebars.value[i].visible=!1)}showRightSidebar(e,n="title"){const i=this.viewsContainers.rightSidebars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.rightSidebars.value[i].visible=!0)}getComponentConfings(){return this.componentConfigs}getComponentConfingByType(e){return this.componentConfigs[e]}computedComponentSchemaGroups(){const e=[];Object.values(this.componentConfigs).forEach(n=>{if(!this.hiddenComponents.includes(n.defaultSchema.type)&&n.groupName){const i=this.componentGroupNameMap[n.groupName]??n.groupName;let t=e.findIndex(r=>r.title===i);t===-1&&(e.push({title:i,list:[]}),t=e.length-1);let o=e[t].list.findIndex(r=>r.type===n.defaultSchema.type);o!==-1?e[t].list[o]=n.defaultSchema:e[t].list.push(n.defaultSchema)}}),e.sort((n,i)=>{const t=this.sortedGroups.indexOf(n.title),o=this.sortedGroups.indexOf(i.title);return t===-1?1:o===-1?-1:t-o}),e.forEach(n=>{n.list.sort((i,t)=>{var a,c;const o=((a=this.componentConfigs[i.type])==null?void 0:a.sort)??1e3,r=((c=this.componentConfigs[t.type])==null?void 0:c.sort)??1e3;return o-r})}),this.componentSchemaGroups.value=e}getComponentSchemaGroups(){return this.componentSchemaGroups}setComponentGroupNameMap(e,n){this.componentGroupNameMap[e]=n}clearComponentGroupNameMap(){this.componentGroupNameMap={}}setSortedGroups(e){this.sortedGroups=e,this.computedComponentSchemaGroups()}clearSortedGroups(){this.sortedGroups=[],this.computedComponentSchemaGroups()}hideComponent(e){this.hiddenComponents.push(e),this.computedComponentSchemaGroups()}showComponent(e){this.hiddenComponents=this.hiddenComponents.filter(n=>n!==e),this.computedComponentSchemaGroups()}setHideComponents(e){this.hiddenComponents=e,this.computedComponentSchemaGroups()}setInitialized(e){this.initialized.value=e}addPublicMethod(e){const n=e.methodName??e.name,i=e.method??e.handler;this.publicMethods[n]={...e,name:n,handler:i}}removePublicMethod(e){delete this.publicMethods[e]}}const G=new I;exports.EventBus=A;exports.PluginManager=I;exports.capitalizeFirstLetter=F;exports.convertKFormData=V;exports.deepClone=d;exports.deepCompareAndModify=C;exports.deepEqual=z;exports.findSchemaById=T;exports.findSchemaInfoById=D;exports.findSchemas=f;exports.generateNewSchema=P;exports.getFormFields=R;exports.getFormSchemas=b;exports.getMatchedById=E;exports.getUUID=m;exports.getValueByPath=O;exports.loadAsyncComponent=h;exports.mapSchemas=x;exports.pluginManager=G;exports.recursionConvertedNode=u;exports.setValueByPath=L;
|
|
1
|
+
"use strict";var B=Object.defineProperty;var M=(s,e,n)=>e in s?B(s,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):s[e]=n;var l=(s,e,n)=>M(s,typeof e!="symbol"?e+"":e,n);const p=require("vue"),k=require("./index-BoL2PSBk.cjs"),h=(s,e)=>p.defineAsyncComponent({loader:s,loadingComponent:e,delay:80});function m(s=10){const e="abcdefghijklmnopqrstuvwxyz0123456789";let n="";for(let i=0;i<s;i++){const t=Math.floor(Math.random()*e.length);n+=e[t]}return n}function F(s){return s.charAt(0).toUpperCase()+s.slice(1)}const{t:S}=k.useLocale();function d(s,e=new WeakMap){if(typeof s!="object"||s===null)return s;if(e.has(s))return e.get(s);if(Array.isArray(s)){const i=s.map(t=>d(t,e));return e.set(s,i),i}const n={};return e.set(s,n),Object.keys(s).forEach(i=>{n[i]=d(s[i],e)}),n}function P(s){const[e]=x([d(s)],n=>{var t,o;const i={...n,id:`${n.type}_${m(8)}`};return(i.field||i.input)&&!((o=(t=G.getComponentConfingByType(i.type))==null?void 0:t.editConstraints)!=null&&o.fixedField)&&(i.field=i.id),i});return e}function C(s,e,n=!0){for(const[i,t]of Object.entries(e)){let o=s==null?void 0:s[i];o&&t&&typeof o=="object"&&typeof t=="object"?(Array.isArray(o)&&!Array.isArray(t)?o=s[i]={}:!Array.isArray(o)&&Array.isArray(t)&&(o=s[i]=[]),C(o,t,n)):s[i]=t}n&&Object.keys(s).reverse().forEach(i=>{e.hasOwnProperty(i)||(Array.isArray(s)?s.splice(Number(i),1):delete s[i])})}function z(s,e,n=[],i=new WeakMap){const t=o=>{if(Array.isArray(o))return o.map(t);if(typeof o=="object"&&o!==null){if(i.has(o))return"[Circular]";i.set(o,!0);const r=Object.keys(o).sort(),a={};return r.forEach(c=>{n.includes(c)||(a[c]=t(o[c]))}),i.delete(o),a}else return o};return JSON.stringify(t(s))===JSON.stringify(t(e))}function E(s,e){const n=[];let i=!1;function t(o){if(n.push(o),o.id===e&&(i=!0),!i&&o.children!=null&&o.children.length>0)for(let r=0;r<o.children.length&&(t(o.children[r]),!i);r++);if(!i&&o.slots)for(let r in o.slots)for(let a=0;a<o.slots[r].length&&(t(o.slots[r][a]),!i);a++);i||n.pop()}return s.forEach(t),i||console.error(`没有查询到id为${e}的节点`),n}function O(s,e,n){const i=e.split(".");let t=s;for(let o=0;o<i.length;o++){if(t==null)return n;t=t[i[o]]}return t===void 0?n:t}function L(s,e,n){const i=e.replace(/\[(\d+)\]/g,".$1").split(".").filter(Boolean);let t=s;for(let o=0;o<i.length-1;o++){const r=i[o];t[r]==null&&(t[r]=isNaN(Number(i[o+1]))?{}:[]),t=t[r]}return t[i[i.length-1]]=n,s}function R(s,e="default"){return b(s,e).map(i=>i.field)}function b(s,e="default"){const n=f(s,t=>{var o;return t.type==="form"&&(((o=t.componentProps)==null?void 0:o.name)??t.name===e)},!0);return f((n==null?void 0:n.children)??[],t=>!!t.input,!1,t=>t.type!=="subform")}function f(s,e,n=!1,i){const t=[],o=[...s];for(;o.length;){const r=o.pop();if(r!=null&&r.children&&(!i||i(r))&&o.push(...r.children),r!=null&&r.slots&&(!i||i(r)))for(let a in r.slots)o.push(...r.slots[a]);if(e(r)&&(t.push(r),n))return r}return n?!1:t}function x(s,e,n){const i=[...s];for(;i.length;){const t=i.pop();if(t!=null&&t.children&&(!n||n(t))&&i.push(...t.children),t!=null&&t.slots&&(!n||n(t)))for(let o in t.slots)i.push(...t.slots[o]);C(t,e(t))}return s}function T(s,e){const n=f(s,i=>i.id===e,!0);if(!n)throw new Error(`没有查询到id为${e}的节点`);return n}function D(s,e){const n=[{type:"",children:s}];let i=0,t=null;if(f(n,o=>{if(t=o.children??null,!t){if(o!=null&&o.slots)for(let r in o.slots){t=o.slots[r];for(let a=0;a<t.length;a++)if(t[a].id===e)return i=a,!0}return!1}for(let r=0;r<t.length;r++)if(t[r].id===e)return i=r,!0;return!1},!0),!t)throw new Error(`没有查询到id为${e}的节点`);return{list:t,schema:t[i],index:i}}function V(s){const e={schemas:[{type:"page",id:"root",label:S("page"),children:[{label:S("form"),type:"form",icon:"epic-icon-daibanshixiang",labelWidth:s.config.labelWidth||100,name:"default",componentProps:{layout:s.config.layout||"horizontal",labelWidth:s.config.labelWidth||100,labelLayout:s.config.labelLayout==="flex"?"fixed":"flex",labelCol:s.config.labelCol||{span:5},wrapperCol:s.config.wrapperCol||{span:19},hideRequiredMark:s.config.hideRequiredMark||!1,colon:s.config.colon||!0,labelAlign:s.config.labelAlign||"right",size:s.config.size||"middle"},children:[],id:"form_"+m()}],componentProps:{style:{padding:"16px"}}}],script:s.script||""};return e.schemas[0].children[0].children=u(s.list),e}function u(s,e){return s.map(n=>{var c,v,w;let i=n.type??"";const t=n.options??{},o=(y,g)=>{i===y&&(i=g,t.defaultValue&&(t.defaultValue=JSON.parse(t.defaultValue)))};if(o("uploadImg","upload-image"),o("uploadFile","upload-file"),i==="date"&&t.range&&(t.type="daterange",delete t.range),(i==="date"||i==="time")&&(t.valueFormat=t.format),i==="textarea"){const{minRows:y,maxRows:g}=t;t.autoSize={minRows:y,maxRows:g},delete t.minRows,delete t.maxRows}i==="number"&&!t.precision&&delete t.precision,t.width&&(t.style={width:t.width},delete t.width),i==="grid"&&(i="row"),e&&e.type==="grid"&&(i="col",t.span=n.span,n.key=m());const r={label:n.label,type:i,icon:n.icon||"",field:n.model,componentProps:t,id:n.key};return(t.noFormItem||!t.showLabel)&&(r.noFormItem=!0,delete t.noFormItem,delete t.showLabel),t.clearable&&(t.allowClear=!0,delete t.clearable),["input","textarea","number","password","select","cascader","checkbox","radio","date","time","slider","switch","color-picker","upload-file","upload-image"].includes(i)&&(r.input=!0,((v=(c=n.rules)==null?void 0:c[0])==null?void 0:v.required)===!1&&n.rules.shift(),((w=n.rules)==null?void 0:w.length)>0&&(r.rules=n.rules)),n.list&&(r.children=u(n.list,n)),n.columns&&(r.children=u(n.columns,n)),n.trs&&(r.children=u(n.trs,n)),n.tds&&(r.children=u(n.tds,n)),r})}function N(s){return{all:s=s||new Map,on:function(e,n){var i=s.get(e);i?i.push(n):s.set(e,[n])},off:function(e,n){var i=s.get(e);i&&(n?i.splice(i.indexOf(n)>>>0,1):s.set(e,[]))},emit:function(e,n){var i=s.get(e);i&&i.slice().map(function(t){t(n)}),(i=s.get("*"))&&i.slice().map(function(t){t(e,n)})}}}const A=N();class I{constructor(){l(this,"initialized",p.ref(!1));l(this,"sourceData",[]);l(this,"components",{});l(this,"componentConfigs",{});l(this,"baseComponentTypes",[]);l(this,"componentSchemaGroups",p.ref([]));l(this,"hiddenComponents",[]);l(this,"formSchemas",[{label:"表单",type:"form",componentProps:{layout:"horizontal",name:"default",labelWidth:100,labelLayout:"fixed",labelCol:{span:5},wrapperCol:{span:19},colon:!0,labelAlign:"right",labelPlacement:"left"},children:[],id:"root"}]);l(this,"componentGroupNameMap",{});l(this,"sortedGroups",["表单","布局","业务组件"]);l(this,"viewsContainers",{activitybars:p.shallowRef([]),rightSidebars:p.shallowRef([])});l(this,"publicMethods",{})}component(e,n){typeof n=="function"&&(n=h(n)),this.components[e]=n}registerComponent(e){this.component(e.defaultSchema.type,e.component),e.defaultSchema.input&&(e.config.action||(e.config.action=[]),e.config.action.unshift({type:"setValue",describe:"设置值",argsConfigs:[{...e.defaultSchema,label:"设置数据",field:"0"}]},{type:"getValue",describe:"获取值"})),this.componentConfigs[e.defaultSchema.type]=e,this.computedComponentSchemaGroups()}removeComponent(e){delete this.componentConfigs[e],delete this.components[e]}setSourceData(e){this.sourceData=e,A.emit("updateSource",new Date)}getSourceData(){return Object.prototype.toString.call(this.sourceData)==="[object Array]"?this.sourceData:[]}setBaseComponentTypes(e){this.baseComponentTypes=e}addBaseComponentTypes(e){this.baseComponentTypes.push(e)}removeBaseComponents(){this.baseComponentTypes.forEach(e=>{this.removeComponent(e)}),this.setBaseComponentTypes([]),this.computedComponentSchemaGroups()}getComponents(){return this.components}getComponent(e){return this.components[e]}registerActivitybar(e){typeof e.component=="function"&&(e.component=h(e.component)),typeof e.visible>"u"&&(e.visible=!0);const n=this.viewsContainers.activitybars.value.findIndex(i=>i.id===e.id);n!==-1?this.viewsContainers.activitybars.value[n]=e:this.viewsContainers.activitybars.value.push(e)}getActivitybars(){return this.viewsContainers.activitybars.value}hideActivitybar(e,n="title"){const i=this.viewsContainers.activitybars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.activitybars.value[i].visible=!1)}showActivitybar(e,n="title"){const i=this.viewsContainers.activitybars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.activitybars.value[i].visible=!0)}registerRightSidebar(e){typeof e.component=="function"&&(e.component=h(e.component)),typeof e.visible>"u"&&(e.visible=!0);const n=this.viewsContainers.rightSidebars.value.findIndex(i=>i.id===e.id);n!==-1?this.viewsContainers.rightSidebars.value[n]=e:this.viewsContainers.rightSidebars.value.push(e)}getRightSidebars(){return this.viewsContainers.rightSidebars.value}hideRightSidebar(e,n="title"){const i=this.viewsContainers.rightSidebars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.rightSidebars.value[i].visible=!1)}showRightSidebar(e,n="title"){const i=this.viewsContainers.rightSidebars.value.findIndex(t=>t[n]===e);i!==-1&&(this.viewsContainers.rightSidebars.value[i].visible=!0)}getComponentConfings(){return this.componentConfigs}getComponentConfingByType(e){return this.componentConfigs[e]}computedComponentSchemaGroups(){const e=[];Object.values(this.componentConfigs).forEach(n=>{if(!this.hiddenComponents.includes(n.defaultSchema.type)&&n.groupName){const i=this.componentGroupNameMap[n.groupName]??n.groupName;let t=e.findIndex(r=>r.title===i);t===-1&&(e.push({title:i,list:[]}),t=e.length-1);let o=e[t].list.findIndex(r=>r.type===n.defaultSchema.type);o!==-1?e[t].list[o]=n.defaultSchema:e[t].list.push(n.defaultSchema)}}),e.sort((n,i)=>{const t=this.sortedGroups.indexOf(n.title),o=this.sortedGroups.indexOf(i.title);return t===-1?1:o===-1?-1:t-o}),e.forEach(n=>{n.list.sort((i,t)=>{var a,c;const o=((a=this.componentConfigs[i.type])==null?void 0:a.sort)??1e3,r=((c=this.componentConfigs[t.type])==null?void 0:c.sort)??1e3;return o-r})}),this.componentSchemaGroups.value=e}getComponentSchemaGroups(){return this.componentSchemaGroups}setComponentGroupNameMap(e,n){this.componentGroupNameMap[e]=n}clearComponentGroupNameMap(){this.componentGroupNameMap={}}setSortedGroups(e){this.sortedGroups=e,this.computedComponentSchemaGroups()}clearSortedGroups(){this.sortedGroups=[],this.computedComponentSchemaGroups()}hideComponent(e){this.hiddenComponents.push(e),this.computedComponentSchemaGroups()}showComponent(e){this.hiddenComponents=this.hiddenComponents.filter(n=>n!==e),this.computedComponentSchemaGroups()}setHideComponents(e){this.hiddenComponents=e,this.computedComponentSchemaGroups()}setInitialized(e){this.initialized.value=e}addPublicMethod(e){const n=e.methodName??e.name,i=e.method??e.handler;this.publicMethods[n]={...e,name:n,handler:i}}removePublicMethod(e){delete this.publicMethods[e]}}const G=new I;exports.EventBus=A;exports.PluginManager=I;exports.capitalizeFirstLetter=F;exports.convertKFormData=V;exports.deepClone=d;exports.deepCompareAndModify=C;exports.deepEqual=z;exports.findSchemaById=T;exports.findSchemaInfoById=D;exports.findSchemas=f;exports.generateNewSchema=P;exports.getFormFields=R;exports.getFormSchemas=b;exports.getMatchedById=E;exports.getUUID=m;exports.getValueByPath=O;exports.loadAsyncComponent=h;exports.mapSchemas=x;exports.pluginManager=G;exports.recursionConvertedNode=u;exports.setValueByPath=L;
|