From 953baa44f824e139fb331c282ec21b13051fe775 Mon Sep 17 00:00:00 2001 From: kohaiy Date: Sat, 16 Mar 2024 08:17:58 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20kohaiy/e?= =?UTF-8?q?asytable@1884deff4db8dd5b637927d6e86c1bf400c06f29=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 0.0.1/assets/QA-ImlnGGpM.js | 7 + 0.0.1/assets/api-tpl-Z63SnkFF.js | 33 + .../cell-autofill-option-props-PVvG-H0r.js | 1 + .../cell-selection-option-props-WpqHDtMX.js | 1 + 0.0.1/assets/cell-span-yHkHui2h.js | 137 ++ 0.0.1/assets/cell-style-J6QPc3a3.js | 96 ++ .../cell-style-option-props-wwwBJA6z.js | 1 + .../assets/checkbox-option-props-vjbvR-9D.js | 1 + .../assets/clipboard-option-props-rOa_fB64.js | 1 + .../column-hidden-option-props-UZznIf1E.js | 1 + ...lumn-width-resize-option-props-0-04grYc.js | 1 + .../contextmenu-body-option-props-vDSrAbcQ.js | 1 + 0.0.1/assets/custom-cell-bPTUsX60.js | 95 ++ 0.0.1/assets/doc-layout-kbt0n1Fb.js | 1 + 0.0.1/assets/edit-option-props-6r6jYFDB.js | 1 + 0.0.1/assets/ellipsis-props-FT1Wp8uT.js | 1 + 0.0.1/assets/empty-layout-Z7kFjUrR.js | 1 + .../event-custom-option-props-iG1cDXrz.js | 1 + 0.0.1/assets/expand-option-props-ajZ-Efp0.js | 1 + 0.0.1/assets/filter-custom-props-pHu9KLvu.js | 1 + 0.0.1/assets/filter-props-FoQwjggY.js | 1 + 0.0.1/assets/index-BxRg2T26.js | 99 ++ 0.0.1/assets/index-w1ao0-uj.js | 1 + 0.0.1/assets/instance-methods-67I7herw.js | 1 + 0.0.1/assets/intro-f-rQVurW.js | 1 + 0.0.1/assets/intro-sq0g5ryX.js | 1 + 0.0.1/assets/locale-jHMo_lBT.js | 29 + 0.0.1/assets/main--1tUTdaK.js | 262 ++++ 0.0.1/assets/main--gn7gfYF.js | 201 +++ 0.0.1/assets/main--llkxrDJ.js | 1159 +++++++++++++++++ 0.0.1/assets/main-0XtYKihT.js | 202 +++ 0.0.1/assets/main-1T4f3v1w.js | 244 ++++ 0.0.1/assets/main-3-ayi7Mt.js | 248 ++++ 0.0.1/assets/main-3YEiymwp.js | 61 + 0.0.1/assets/main-5NCVkYkC.js | 507 +++++++ 0.0.1/assets/main-6sNHsSaX.js | 67 + 0.0.1/assets/main-72rotpIA.js | 15 + 0.0.1/assets/main-A7eTmMCn.js | 334 +++++ 0.0.1/assets/main-BiJmqvno.js | 331 +++++ 0.0.1/assets/main-CUPsbrKJ.js | 173 +++ 0.0.1/assets/main-Ck3y4-BJ.js | 71 + 0.0.1/assets/main-EpeGXgIb.js | 623 +++++++++ 0.0.1/assets/main-Horfk5RY.js | 555 ++++++++ 0.0.1/assets/main-HsWl_mo0.js | 335 +++++ 0.0.1/assets/main-JFPb23Oq.js | 125 ++ 0.0.1/assets/main-L1QQUS4v.js | 552 ++++++++ 0.0.1/assets/main-LS2BR78K.js | 186 +++ 0.0.1/assets/main-MUWFfmHB.js | 612 +++++++++ 0.0.1/assets/main-MY_LL2AI.js | 359 +++++ 0.0.1/assets/main-PPvjnslh.js | 55 + 0.0.1/assets/main-Q8OtVeN0.js | 116 ++ 0.0.1/assets/main-QhlIwgV4.js | 471 +++++++ 0.0.1/assets/main-QyfMpihV.js | 131 ++ 0.0.1/assets/main-RDRERbvv.js | 176 +++ 0.0.1/assets/main-SJtYuYkk.js | 82 ++ 0.0.1/assets/main-UjHb7BKn.js | 75 ++ 0.0.1/assets/main-VQzAg4xT.js | 419 ++++++ 0.0.1/assets/main-VpGYcr-2.js | 66 + 0.0.1/assets/main-bazS0Ljx.js | 1 + 0.0.1/assets/main-eQ8WU5JA.js | 287 ++++ 0.0.1/assets/main-exGfMmkl.js | 361 +++++ 0.0.1/assets/main-f3_0kYf9.js | 94 ++ 0.0.1/assets/main-hkLckNI1.js | 337 +++++ 0.0.1/assets/main-kDbZqJ-z.js | 133 ++ 0.0.1/assets/main-lSDe-H2F.js | 760 +++++++++++ 0.0.1/assets/main-lcacPNly.js | 196 +++ 0.0.1/assets/main-oGT2X4aA.js | 528 ++++++++ 0.0.1/assets/main-phH5IE3B.js | 277 ++++ 0.0.1/assets/main-qqA05Hok.js | 1092 ++++++++++++++++ 0.0.1/assets/main-tf1nfeUd.js | 58 + 0.0.1/assets/main-uhIHR_FU.js | 86 ++ 0.0.1/assets/main-uuQg_qO_.js | 278 ++++ 0.0.1/assets/main-wHq1L87p.js | 348 +++++ 0.0.1/assets/main-x5R28hVs.js | 192 +++ 0.0.1/assets/mock-G9bGU2k0.js | 9 + 0.0.1/assets/on-footer-cell-_clcYqiF.js | 235 ++++ 0.0.1/assets/radio-option-props-h76pwA4-.js | 1 + .../assets/row-style-option-props-ZxzGM0QF.js | 1 + 0.0.1/assets/sort-option-props-LscfJy--.js | 1 + 0.0.1/assets/start-JZ4LZvVe.js | 184 +++ 0.0.1/assets/theme-tXLZ7TKU.js | 17 + 0.0.1/assets/virtual-scroll-OArggChC.js | 87 ++ .../virtual-scroll-option-props-S_Yd6c2k.js | 1 + .../vue.runtime.esm-bundler-Tv19svLr.js | 1 + 0.0.1/index.html | 8 +- assets/QA-DfjvJ4Mh.js | 7 + assets/api-tpl-2bea2PZj.js | 33 + assets/cell-autofill-option-props-0R_Om15t.js | 1 + .../cell-selection-option-props-tDEDSk04.js | 1 + assets/cell-span-ZlkhoFuz.js | 137 ++ assets/cell-style-WdasCc-Z.js | 96 ++ assets/cell-style-option-props-Rq3ZLLBE.js | 1 + assets/checkbox-option-props-d-xYySPr.js | 1 + assets/clipboard-option-props-tFAwShKE.js | 1 + assets/column-hidden-option-props-FnDpjEd7.js | 1 + ...lumn-width-resize-option-props-EYke_oaA.js | 1 + .../contextmenu-body-option-props-KT-5R_1p.js | 1 + assets/custom-cell-6vPuPZ2Z.js | 95 ++ assets/doc-layout-86Gc4eYA.js | 1 + assets/edit-option-props-XYsoLWKD.js | 1 + assets/ellipsis-props-QDapEaTm.js | 1 + assets/empty-layout-hX-hM7Cs.js | 1 + assets/event-custom-option-props-_CpiPhsg.js | 1 + assets/expand-option-props--LocRKpG.js | 1 + assets/filter-custom-props--Vb6JTAo.js | 1 + assets/filter-props-JJBQX_Qq.js | 1 + assets/index-1-5pqjkO.js | 99 ++ assets/index-wPGUw0QQ.js | 1 + assets/instance-methods-L7uvXbg9.js | 1 + assets/intro-jcdmJcqm.js | 1 + assets/intro-r2swwhPU.js | 1 + assets/locale-UIbrbHDr.js | 29 + assets/main--W5Wonc_.js | 248 ++++ assets/main-17l9Le9C.js | 1 + assets/main-1dAiCUDB.js | 528 ++++++++ assets/main-26vogcrd.js | 75 ++ assets/main-2Nk0WLQw.js | 244 ++++ assets/main-2UivnEui.js | 1092 ++++++++++++++++ assets/main-2UjHVf51.js | 331 +++++ assets/main-2d6Hkj-n.js | 348 +++++ assets/main-6b0FYdOO.js | 66 + assets/main-83ddpPez.js | 201 +++ assets/main-9jHI81Vd.js | 186 +++ assets/main-BwpXU_8z.js | 359 +++++ assets/main-FQ28Z7WK.js | 555 ++++++++ assets/main-HZaYx2wN.js | 277 ++++ assets/main-IzGoUuEd.js | 176 +++ assets/main-KmLOsA3U.js | 58 + assets/main-KpaSLMob.js | 133 ++ assets/main-NHAWTZGK.js | 116 ++ assets/main-OYx4UD-r.js | 192 +++ assets/main-OiuIaD6L.js | 125 ++ assets/main-Qy8tg5X8.js | 623 +++++++++ assets/main-T1irLhjO.js | 337 +++++ assets/main-UUmGkGra.js | 131 ++ assets/main-WzwVS29_.js | 419 ++++++ assets/main-XMLdYpOo.js | 552 ++++++++ assets/main-_bL2S7Be.js | 15 + assets/main-c8IesKoM.js | 361 +++++ assets/main-dLN9-39D.js | 507 +++++++ assets/main-ddj5M9wu.js | 262 ++++ assets/main-eT7Rewox.js | 471 +++++++ assets/main-i26r8H7k.js | 202 +++ assets/main-j5awyz45.js | 1159 +++++++++++++++++ assets/main-k2XxPO89.js | 55 + assets/main-kWXi7p0k.js | 61 + assets/main-kiA_3LV1.js | 287 ++++ assets/main-l62S280x.js | 67 + assets/main-lQAXGSOb.js | 86 ++ assets/main-mdqUC3wM.js | 760 +++++++++++ assets/main-oNG-9QtR.js | 278 ++++ assets/main-qIGFIVu9.js | 612 +++++++++ assets/main-qow36mic.js | 196 +++ assets/main-r7To42z7.js | 335 +++++ assets/main-rSrz9u1K.js | 94 ++ assets/main-rh-PSLEw.js | 173 +++ assets/main-vD1a44gF.js | 71 + assets/main-x-NT5uSl.js | 82 ++ assets/main-ySpUTs_g.js | 334 +++++ assets/mock-PofGB_Zt.js | 9 + assets/on-footer-cell-luWCVXdh.js | 235 ++++ assets/radio-option-props-tF8Vb_CK.js | 1 + assets/row-style-option-props-4byVXW3H.js | 1 + assets/sort-option-props-TbQ67WW6.js | 1 + assets/start-CoomlFpR.js | 184 +++ assets/theme-kQ_e6ul8.js | 17 + .../virtual-scroll-option-props-ugP_FZa6.js | 1 + assets/virtual-scroll-xyOnKzhu.js | 87 ++ assets/vue.runtime.esm-bundler-BRNTKtdd.js | 1 + index.html | 8 +- 170 files changed, 29796 insertions(+), 8 deletions(-) create mode 100644 0.0.1/assets/QA-ImlnGGpM.js create mode 100644 0.0.1/assets/api-tpl-Z63SnkFF.js create mode 100644 0.0.1/assets/cell-autofill-option-props-PVvG-H0r.js create mode 100644 0.0.1/assets/cell-selection-option-props-WpqHDtMX.js create mode 100644 0.0.1/assets/cell-span-yHkHui2h.js create mode 100644 0.0.1/assets/cell-style-J6QPc3a3.js create mode 100644 0.0.1/assets/cell-style-option-props-wwwBJA6z.js create mode 100644 0.0.1/assets/checkbox-option-props-vjbvR-9D.js create mode 100644 0.0.1/assets/clipboard-option-props-rOa_fB64.js create mode 100644 0.0.1/assets/column-hidden-option-props-UZznIf1E.js create mode 100644 0.0.1/assets/column-width-resize-option-props-0-04grYc.js create mode 100644 0.0.1/assets/contextmenu-body-option-props-vDSrAbcQ.js create mode 100644 0.0.1/assets/custom-cell-bPTUsX60.js create mode 100644 0.0.1/assets/doc-layout-kbt0n1Fb.js create mode 100644 0.0.1/assets/edit-option-props-6r6jYFDB.js create mode 100644 0.0.1/assets/ellipsis-props-FT1Wp8uT.js create mode 100644 0.0.1/assets/empty-layout-Z7kFjUrR.js create mode 100644 0.0.1/assets/event-custom-option-props-iG1cDXrz.js create mode 100644 0.0.1/assets/expand-option-props-ajZ-Efp0.js create mode 100644 0.0.1/assets/filter-custom-props-pHu9KLvu.js create mode 100644 0.0.1/assets/filter-props-FoQwjggY.js create mode 100644 0.0.1/assets/index-BxRg2T26.js create mode 100644 0.0.1/assets/index-w1ao0-uj.js create mode 100644 0.0.1/assets/instance-methods-67I7herw.js create mode 100644 0.0.1/assets/intro-f-rQVurW.js create mode 100644 0.0.1/assets/intro-sq0g5ryX.js create mode 100644 0.0.1/assets/locale-jHMo_lBT.js create mode 100644 0.0.1/assets/main--1tUTdaK.js create mode 100644 0.0.1/assets/main--gn7gfYF.js create mode 100644 0.0.1/assets/main--llkxrDJ.js create mode 100644 0.0.1/assets/main-0XtYKihT.js create mode 100644 0.0.1/assets/main-1T4f3v1w.js create mode 100644 0.0.1/assets/main-3-ayi7Mt.js create mode 100644 0.0.1/assets/main-3YEiymwp.js create mode 100644 0.0.1/assets/main-5NCVkYkC.js create mode 100644 0.0.1/assets/main-6sNHsSaX.js create mode 100644 0.0.1/assets/main-72rotpIA.js create mode 100644 0.0.1/assets/main-A7eTmMCn.js create mode 100644 0.0.1/assets/main-BiJmqvno.js create mode 100644 0.0.1/assets/main-CUPsbrKJ.js create mode 100644 0.0.1/assets/main-Ck3y4-BJ.js create mode 100644 0.0.1/assets/main-EpeGXgIb.js create mode 100644 0.0.1/assets/main-Horfk5RY.js create mode 100644 0.0.1/assets/main-HsWl_mo0.js create mode 100644 0.0.1/assets/main-JFPb23Oq.js create mode 100644 0.0.1/assets/main-L1QQUS4v.js create mode 100644 0.0.1/assets/main-LS2BR78K.js create mode 100644 0.0.1/assets/main-MUWFfmHB.js create mode 100644 0.0.1/assets/main-MY_LL2AI.js create mode 100644 0.0.1/assets/main-PPvjnslh.js create mode 100644 0.0.1/assets/main-Q8OtVeN0.js create mode 100644 0.0.1/assets/main-QhlIwgV4.js create mode 100644 0.0.1/assets/main-QyfMpihV.js create mode 100644 0.0.1/assets/main-RDRERbvv.js create mode 100644 0.0.1/assets/main-SJtYuYkk.js create mode 100644 0.0.1/assets/main-UjHb7BKn.js create mode 100644 0.0.1/assets/main-VQzAg4xT.js create mode 100644 0.0.1/assets/main-VpGYcr-2.js create mode 100644 0.0.1/assets/main-bazS0Ljx.js create mode 100644 0.0.1/assets/main-eQ8WU5JA.js create mode 100644 0.0.1/assets/main-exGfMmkl.js create mode 100644 0.0.1/assets/main-f3_0kYf9.js create mode 100644 0.0.1/assets/main-hkLckNI1.js create mode 100644 0.0.1/assets/main-kDbZqJ-z.js create mode 100644 0.0.1/assets/main-lSDe-H2F.js create mode 100644 0.0.1/assets/main-lcacPNly.js create mode 100644 0.0.1/assets/main-oGT2X4aA.js create mode 100644 0.0.1/assets/main-phH5IE3B.js create mode 100644 0.0.1/assets/main-qqA05Hok.js create mode 100644 0.0.1/assets/main-tf1nfeUd.js create mode 100644 0.0.1/assets/main-uhIHR_FU.js create mode 100644 0.0.1/assets/main-uuQg_qO_.js create mode 100644 0.0.1/assets/main-wHq1L87p.js create mode 100644 0.0.1/assets/main-x5R28hVs.js create mode 100644 0.0.1/assets/mock-G9bGU2k0.js create mode 100644 0.0.1/assets/on-footer-cell-_clcYqiF.js create mode 100644 0.0.1/assets/radio-option-props-h76pwA4-.js create mode 100644 0.0.1/assets/row-style-option-props-ZxzGM0QF.js create mode 100644 0.0.1/assets/sort-option-props-LscfJy--.js create mode 100644 0.0.1/assets/start-JZ4LZvVe.js create mode 100644 0.0.1/assets/theme-tXLZ7TKU.js create mode 100644 0.0.1/assets/virtual-scroll-OArggChC.js create mode 100644 0.0.1/assets/virtual-scroll-option-props-S_Yd6c2k.js create mode 100644 0.0.1/assets/vue.runtime.esm-bundler-Tv19svLr.js create mode 100644 assets/QA-DfjvJ4Mh.js create mode 100644 assets/api-tpl-2bea2PZj.js create mode 100644 assets/cell-autofill-option-props-0R_Om15t.js create mode 100644 assets/cell-selection-option-props-tDEDSk04.js create mode 100644 assets/cell-span-ZlkhoFuz.js create mode 100644 assets/cell-style-WdasCc-Z.js create mode 100644 assets/cell-style-option-props-Rq3ZLLBE.js create mode 100644 assets/checkbox-option-props-d-xYySPr.js create mode 100644 assets/clipboard-option-props-tFAwShKE.js create mode 100644 assets/column-hidden-option-props-FnDpjEd7.js create mode 100644 assets/column-width-resize-option-props-EYke_oaA.js create mode 100644 assets/contextmenu-body-option-props-KT-5R_1p.js create mode 100644 assets/custom-cell-6vPuPZ2Z.js create mode 100644 assets/doc-layout-86Gc4eYA.js create mode 100644 assets/edit-option-props-XYsoLWKD.js create mode 100644 assets/ellipsis-props-QDapEaTm.js create mode 100644 assets/empty-layout-hX-hM7Cs.js create mode 100644 assets/event-custom-option-props-_CpiPhsg.js create mode 100644 assets/expand-option-props--LocRKpG.js create mode 100644 assets/filter-custom-props--Vb6JTAo.js create mode 100644 assets/filter-props-JJBQX_Qq.js create mode 100644 assets/index-1-5pqjkO.js create mode 100644 assets/index-wPGUw0QQ.js create mode 100644 assets/instance-methods-L7uvXbg9.js create mode 100644 assets/intro-jcdmJcqm.js create mode 100644 assets/intro-r2swwhPU.js create mode 100644 assets/locale-UIbrbHDr.js create mode 100644 assets/main--W5Wonc_.js create mode 100644 assets/main-17l9Le9C.js create mode 100644 assets/main-1dAiCUDB.js create mode 100644 assets/main-26vogcrd.js create mode 100644 assets/main-2Nk0WLQw.js create mode 100644 assets/main-2UivnEui.js create mode 100644 assets/main-2UjHVf51.js create mode 100644 assets/main-2d6Hkj-n.js create mode 100644 assets/main-6b0FYdOO.js create mode 100644 assets/main-83ddpPez.js create mode 100644 assets/main-9jHI81Vd.js create mode 100644 assets/main-BwpXU_8z.js create mode 100644 assets/main-FQ28Z7WK.js create mode 100644 assets/main-HZaYx2wN.js create mode 100644 assets/main-IzGoUuEd.js create mode 100644 assets/main-KmLOsA3U.js create mode 100644 assets/main-KpaSLMob.js create mode 100644 assets/main-NHAWTZGK.js create mode 100644 assets/main-OYx4UD-r.js create mode 100644 assets/main-OiuIaD6L.js create mode 100644 assets/main-Qy8tg5X8.js create mode 100644 assets/main-T1irLhjO.js create mode 100644 assets/main-UUmGkGra.js create mode 100644 assets/main-WzwVS29_.js create mode 100644 assets/main-XMLdYpOo.js create mode 100644 assets/main-_bL2S7Be.js create mode 100644 assets/main-c8IesKoM.js create mode 100644 assets/main-dLN9-39D.js create mode 100644 assets/main-ddj5M9wu.js create mode 100644 assets/main-eT7Rewox.js create mode 100644 assets/main-i26r8H7k.js create mode 100644 assets/main-j5awyz45.js create mode 100644 assets/main-k2XxPO89.js create mode 100644 assets/main-kWXi7p0k.js create mode 100644 assets/main-kiA_3LV1.js create mode 100644 assets/main-l62S280x.js create mode 100644 assets/main-lQAXGSOb.js create mode 100644 assets/main-mdqUC3wM.js create mode 100644 assets/main-oNG-9QtR.js create mode 100644 assets/main-qIGFIVu9.js create mode 100644 assets/main-qow36mic.js create mode 100644 assets/main-r7To42z7.js create mode 100644 assets/main-rSrz9u1K.js create mode 100644 assets/main-rh-PSLEw.js create mode 100644 assets/main-vD1a44gF.js create mode 100644 assets/main-x-NT5uSl.js create mode 100644 assets/main-ySpUTs_g.js create mode 100644 assets/mock-PofGB_Zt.js create mode 100644 assets/on-footer-cell-luWCVXdh.js create mode 100644 assets/radio-option-props-tF8Vb_CK.js create mode 100644 assets/row-style-option-props-4byVXW3H.js create mode 100644 assets/sort-option-props-TbQ67WW6.js create mode 100644 assets/start-CoomlFpR.js create mode 100644 assets/theme-kQ_e6ul8.js create mode 100644 assets/virtual-scroll-option-props-ugP_FZa6.js create mode 100644 assets/virtual-scroll-xyOnKzhu.js create mode 100644 assets/vue.runtime.esm-bundler-BRNTKtdd.js diff --git a/0.0.1/assets/QA-ImlnGGpM.js b/0.0.1/assets/QA-ImlnGGpM.js new file mode 100644 index 0000000..a7e94a2 --- /dev/null +++ b/0.0.1/assets/QA-ImlnGGpM.js @@ -0,0 +1,7 @@ +import{_ as n,r as s,o as d,c,a as t,m as e,p as l}from"./index-BxRg2T26.js";const r={},a={class:"content example-md-doc"},i=e("h2",null,"常见问题",-1),_=e("p",null,[l("Q:"),e("code",null,"scrollWidth"),l("属性的用法?")],-1),h=e("p",null,[l("A:当外层容器宽度小于 "),e("code",null,"scrollWidth"),l(" 值时,将会出现横向滚动条;当外层容器宽度大于 "),e("code",null,"scrollWidth"),l(" 值时,将会跟随容器自适应")],-1),u=e("p",null,"Q:为什么设置固定列后,有些列无法显示?",-1),m=e("p",null,[l("A:因为设置的 "),e("code",null,"scrollWidth"),l("值小于列(设置具体宽度的)的宽度之和,会导致未设置宽度或者设置百分比的列挤掉")],-1),p=e("p",null,[l("Q:什么时候使用"),e("code",null,"rowKeyFieldName"),l(" 属性?")],-1),f=e("p",null,"A:此属性为了解决数据更新时,渲染的正确性。适用的功能有:行展开、行单选、行多选、行点击高亮、虚拟滚动",-1),b=e("p",null,[l("Q:为什么使用自定义列渲染函数"),e("code",null,"renderBodyCell"),l("报‘ReferenceError: h is not defined’")],-1),A=e("p",null,[l("A:参考"),e("a",{href:"https://cn.vuejs.org/v2/guide/render-function.html#JSX"},"官方文档"),l("。你可以"),e("strong",null,"加上"),l("第二个参数解决,如:")],-1),N=e("pre",null,[e("code",null,`renderBodyCell: ({ row, column, rowIndex },h) => { + return (
hello
); +} +`)],-1),Q=e("p",null,"Q:为什么当单元格内容过多时,设置的宽度不生效",-1),w=e("p",null,[l("A:当单元格文本内容过多时会破坏布局,此时可以通过样式 "),e("a",{href:"https://developer.mozilla.org/zh-CN/docs/Web/CSS/word-break"},"word-break"),l(" 控制("),e("a",{href:"#/zh/doc/table/column-width?anchor=long-text-destroys-layout"},"具体参考这个示例"),l("),如:")],-1),g=e("pre",null,[e("code",{class:"language-html"},` +`)],-1),v=e("p",null,"Q:如何自定义滚动条样式",-1),k=e("p",null,"A:组件内部没有定制滚动条样式,根据你的业务自定义即可。滚动条样式自定义可参考:https://developer.mozilla.org/zh-CN/docs/Web/CSS/::-webkit-scrollbar",-1);function x(y,C){const o=s("anchor");return d(),c("section",a,[i,t(o,{"is-edit":"",label:"scrollWidth 属性",fileName:"QA.md"}),_,h,t(o,{"is-edit":"",label:"固定列",fileName:"QA.md"}),u,m,t(o,{"is-edit":"",label:"rowKeyFieldName 属性",fileName:"QA.md"}),p,f,t(o,{"is-edit":"",label:"报错:‘ReferenceError: h is not defined’",fileName:"QA.md"}),b,A,N,t(o,{"is-edit":"",label:"长文本破坏布局",fileName:"QA.md"}),Q,w,g,t(o,{"is-edit":"",label:"自定义滚动条样式",fileName:"QA.md"}),v,k])}const z=n(r,[["render",x]]);export{z as default}; diff --git a/0.0.1/assets/api-tpl-Z63SnkFF.js b/0.0.1/assets/api-tpl-Z63SnkFF.js new file mode 100644 index 0000000..b5f724b --- /dev/null +++ b/0.0.1/assets/api-tpl-Z63SnkFF.js @@ -0,0 +1,33 @@ +import{a as c,_ as p,r as n,o as u,c as m,m as f,t as y}from"./index-BxRg2T26.js";const e=[{key:"a",field:"param",title:"参数",width:"10%",align:"left",type:"expand",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.param},null)},{key:"b",field:"desc",title:"说明",width:"60%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.desc},null)},{key:"c",field:"type",title:"类型",width:"10%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.type},null)},{key:"d",field:"optionalVal",title:"可选值",width:"10%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.optionalVal},null)},{key:"e",field:"default",title:"默认值",width:"10%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.default},null)}],b=[{key:"b",field:"name",title:"方法名",width:"15%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.name},null)},{key:"c",field:"desc",title:"说明",width:"65%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.desc},null)},{key:"d",field:"param",title:"参数",width:"20%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.param},null)}],R={table:{data:[{param:"tableData",desc:"表格数据",type:"Array",optionalVal:"-",default:"-"},{param:"footerData",desc:"表格footer 汇总数据,数据结构和 tableData 一致",type:"Array",optionalVal:"-",default:"-"},{param:"columns",desc:"列配置,具体项见下表 columns 配置",type:"Array",optionalVal:"-",default:"-"},{param:"showHeader",desc:"是否展示表头",type:"Boolean",optionalVal:"-",default:"true"},{param:"fixedHeader",desc:"是否固定表头,默认启用。需要和 `maxHeight`结合使用",type:"Boolean",optionalVal:"-",default:"true"},{param:"fixedFooter",desc:"是否固定footer 汇总,默认启用。需要和 `maxHeight`结合使用",type:"Boolean",optionalVal:"-",default:"true"},{param:"scrollWidth",desc:"表格滚动区域的宽(开始出滚动条的宽度)。Number指定像素;String指定百分比",type:"NumberString",optionalVal:"-",default:"-"},{param:"maxHeight",desc:"表格的最大高度。Number指定像素;String指定百分比。用于“固定头”或“虚拟滚动”功能",type:"NumberString",optionalVal:"-",default:"-"},{param:"rowKeyFieldName",desc:"指定 row key 的字段名称。用于行展开、行单选、行多选、行点击高亮、虚拟滚动",type:"String",optionalVal:"-",default:"-"},{param:"borderAround",desc:"是否展示表格外边框",type:"Boolean",optionalVal:"-",default:"true"},{param:"borderX",desc:"是否展示列横向边框",type:"Boolean",optionalVal:"-",default:"true"},{param:"borderY",desc:"是否展示列纵向边框",type:"Boolean",optionalVal:"-",default:"false"},{param:"cellSpanOption",desc:"单元格合并配置,具体见下表 cellSpanOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"columnHiddenOption",desc:"列隐藏配置,具体见下表 columnHiddenOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"cellStyleOption",desc:"单元格样式配置,具体见下表 cellStyleOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"rowStyleOption",desc:"行样式配置,具体见下表 rowStyleOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"expandOption",desc:"行展开配置,具体见下表 expandOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"checkboxOption",desc:"行多选配置,具体见下表 checkboxOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"radioOption",desc:"行单选配置,具体见下表 radioOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"virtualScrollOption",desc:"虚拟滚动配置,建议需要一次性展示1000条以上使用。具体见下表 virtualScrollOption 配置。",type:"Object",optionalVal:"-",default:"-"},{param:"sortOption",desc:"排序配置,具体见下表 sortOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"cellSelectionOption",desc:"单元格选择配置,具体见下表 cellSelectionOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"editOption",desc:"单元格编辑配置,具体见下表 editOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"contextmenuHeaderOption",desc:"表格 header 右键菜单配置,具体见下表 contextmenuHeaderOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"contextmenuBodyOption",desc:"表格 body 右键菜单配置,具体见下表 contextmenuBodyOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"eventCustomOption",desc:"自定义事件配置,具体见下表 eventCustomOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"cellAutofillOption",desc:"单元格自动填充配置,具体见下表 cellAutofillOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"clipboardOption",desc:"单元格剪贴板配置,具体见下表 clipboardOption 配置",type:"Object",optionalVal:"-",default:"-"}],columns:e},columns:{data:[{param:"field",desc:"对应列的字段",type:"String",optionalVal:"-",default:"-"},{param:"key",desc:"每个列的唯一key值",type:"String",optionalVal:"-",default:"-"},{param:"type",desc:'当前列类型。 "expand":行展开;"checkbox":行多选;"radio":行单选',type:"String",optionalVal:'"expand"、"checkbox"、"radio"',default:"-"},{param:"title",desc:"列标题",type:"String",optionalVal:"-",default:"-"},{param:"width",desc:"Number指定像素;String指定百分比(指定了也不生效?)",type:"StringNumber",optionalVal:"-",default:"-"},{param:"align",desc:"单元格对齐方式",type:"String",optionalVal:'"left"、"center"、"right"',default:'"center"'},{param:"operationColumn",desc:"是否是操作列",type:"Boolean",optionalVal:"-",default:"false"},{param:"edit",desc:"是否开启列编辑",type:"Boolean",optionalVal:"-",default:"false"},{param:"sortBy",desc:'排序规则。
1、sortBy="":允许排序但无排序规则;
2、sortBy="asc":默认当前列升序;
3、sortBy="desc":默认当前列降序;',type:"String",optionalVal:'""、"desc"、"asc"',default:'""'},{param:"renderBodyCell",desc:'1、表体自定义单元格渲染函数。jsx 语法,书写和模板语法接近。\r2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引、h:createElement 函数的别名
3、更多 jsx 知识请参考Vue.js 官方文档',type:"Function({row,column,rowIndex},h):VNode",optionalVal:"-",default:"-"},{param:"renderHeaderCell",desc:"1、表头自定义单元格渲染函数。用法同renderBodyCell。\r2、参数信息。column:当前列配置、h:createElement 函数的别名",type:"Function({ column },h):VNode",optionalVal:"-",default:"-"},{param:"renderFooterCell",desc:'1、footer汇总 自定义单元格渲染函数。\r2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引、h:createElement 函数的别名
3、更多 jsx 知识请参考Vue.js 官方文档',type:"Function({row,column,rowIndex},h):VNode",optionalVal:"-",default:"-"},{param:"disableResizing",desc:"Disable resizing for this column. Only effective if columnWidthResizeOption is enabled",type:"Boolean",optionalVal:"-",default:"false",rowKey:46},{param:"ellipsis",desc:"单元格省略配置。",type:"Object",optionalVal:"-",default:"-",expandId:49},{param:"filter",desc:"筛选配置。",type:"Object",optionalVal:"-",default:"-",expandId:50},{param:"filterCustom",desc:"筛选自定义配置。",type:"Object",optionalVal:"-",default:"-",expandId:55}],columns:e,filterProps:{data:[{param:"filterList",desc:'1、筛选条件。
2、包含label、value、selected 3 个属性,形如:[{ value: 0, label: "1900-05-20", selected: false }]',type:"Array",optionalVal:"-",default:"-"},{param:"isMultiple",desc:"开启筛选项多选。
",type:"Boolean",optionalVal:"-",default:"false"},{param:"filterConfirm",desc:"1、筛选确认函数。
2、接收1个参数,filterList:筛选条件",type:"Function({filterList})",optionalVal:"-",default:"-"},{param:"filterReset",desc:"1、筛选重置函数
2、接收1个参数,filterList:筛选条件",type:"Function({filterList})",optionalVal:"-",default:"-"},{param:"filterIcon",desc:"1、filter 自定义图标渲染函数。
2、参数信息。h:createElement 函数的别名",type:"Function(h):VNode",optionalVal:"-",default:"-"},{param:"maxHeight",desc:"1、筛选框的最大高度。不包含操作按钮的高度",type:"Number",optionalVal:"-",default:"1000"},{param:"beforeVisibleChange({nextVisible})",desc:"filter 面板显示或者隐藏之前的回调方法,返回false则阻止显示或隐藏",type:"Function",optionalVal:"-",default:"-"}],columns:e},filterCustomProps:{data:[{param:"render",desc:"1、渲染函数。
2、渲染函数接收的参数,showFn:显示filter 函数、closeFn:关闭filter的函数、h:createElement 函数的别名",type:"Function({showFn,closeFn},h):VNode",optionalVal:"-",default:"-"},{param:"filterIcon",desc:"1、filter 自定义图标渲染函数。
2、参数信息。h:createElement 函数的别名",type:"Function(h):VNode",optionalVal:"-",default:"-"},{param:"beforeVisibleChange({nextVisible})",desc:"filter 面板显示或者隐藏之前的回调方法,返回false则阻止显示或隐藏",type:"Function",optionalVal:"-",default:"-"}],columns:e},ellipsisProps:{data:[{param:"lineClamp",desc:"多少行开始省略",type:"Number",optionalVal:"-",default:"1"},{param:"showTitle",desc:"是否鼠标悬浮,展示title",type:"Boolean",optionalVal:"-",default:"true"}],columns:e}},instanceMethods:{data:[{name:"scrollTo",desc:"使表格滚动到指定的位置 参考示例",param:"参考 MDN scrollTo"},{name:"scrollToColKey",desc:"将指定的列显示在可视区域 参考示例",param:"{ rowKey, colKey }"},{name:"scrollToRowKey",desc:"将表格滚动到行为rowKey的位置 参考示例",param:"{rowKey}"},{name:"setHighlightRow",desc:"设置高亮的行 参考示例",param:"{rowKey}"},{name:"startEditingCell",desc:"开始单元格编辑 参考示例",param:"{rowKey,colKey,defaultValue}"},{name:"stopEditingCell",desc:"停止单元格编辑",param:"-"},{name:"hideColumnsByKeys",desc:"隐藏列 参考示例",param:"keys"},{name:"showColumnsByKeys",desc:"显示列 参考示例",param:"keys"},{name:"setCellSelection",desc:"单元格选中 参考示例",param:"{ rowKey, colKey }"},{name:"setAllCellSelection",desc:"单元格全选 参考示例",param:"-"},{name:"setRangeCellSelection",desc:"区域单元格选中 参考示例",param:"{ startRowKey,startColKey,endRowKey,endColKey,isScrollToStartCell }"},{name:"getRangeCellSelection",desc:"获取当前选择区域的信息。返回所选区域索引和key信息",param:"{selectionRangeKeys,selectionRangeIndexes}"}],columns:b},expandOption:{data:[{param:"expandable",desc:"1、是否允许展开行渲染函数。返回布尔值。\r2、渲染函数接收三个参数,row:当前行数据、column:可展开列配置、rowIndex:行索引。",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"},{param:"render",desc:"1、渲染函数。\r2、渲染函数接收的参数,row:当前行数据、column:可展开列配置、rowIndex:行索引、h:createElement 函数的别名",type:"Function({row,column,rowIndex},h):VNode",optionalVal:"-",default:"-"},{param:"defaultExpandAllRows",desc:"是否默认展开全部行",type:"Boolean",optionalVal:"-",default:"false"},{param:"defaultExpandedRowKeys",desc:"默认展开的行key。defaultExpandAllRows 参数和defaultExpandedRowKeys 参数同时存在时,优先使用defaultExpandAllRows",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"expandedRowKeys",desc:"展开行的可控属性,设置后属性后 defaultExpandAllRowsdefaultExpandedRowKeys属性将会失效。具体见相关实例",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"beforeExpandRowChange",desc:"1、展开切换前的函数,如果返回false 则中断执行。\r2、函数接收三个参数,beforeExpandedRowKeys:改变前所有展开的key,row:当前的行数据,rowIndex行号",type:"Function({beforeExpandedRowKeys,row,rowIndex})",optionalVal:"-",default:"-"},{param:"afterExpandRowChange",desc:"1、展开切换后的函数。\r2、函数接收三个参数,afterExpandedRowKeys:改变后所有展开的key,row:当前的行数据,rowIndex行号",type:"Function({afterExpandedRowKeys,row,rowIndex})",optionalVal:"-",default:"-"},{param:"trigger",desc:"展开行事件触发类型。\ricon:点击展开小图标;cell:点击单元格;row:点击行",type:"String",optionalVal:'"icon"、"cell"、"row"',default:'"icon"'}],columns:e},checkboxOption:{data:[{param:"defaultSelectedAllRows",desc:"是否默认全部选中",type:"Boolean",optionalVal:"-",default:"false"},{param:"defaultSelectedRowKeys",desc:"默认选中的行key",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"disableSelectedRowKeys",desc:"禁止勾选或者禁止取消勾选的行key",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"selectedRowKeys",desc:"选中行的可控属性,设置后 defaultSelectedAllRowsdefaultSelectedRowKeys 属性将会失效。具体参考示例",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"selectedRowChange",desc:"行选中的改变事件。事件接收 3 个参数,row:当前行数据,isSelected当前行是否选中,selectedRowKeys所有选中的 rowKey 信息",type:"Function({row, isSelected, selectedRowKeys})",optionalVal:"-",default:"-"},{param:"selectedAllChange",desc:"全选改变事件。事件接收 2 个参数,isSelected 是否全选。selectedRowKeys所有选中的 rowKey 信息",type:"Function({isSelected, selectedRowKeys})",optionalVal:"-",default:"-"},{param:"hideSelectAll",desc:"是否隐藏全选按钮",type:"Boolean",optionalVal:"-",default:"false"}],columns:e},radioOption:{data:[{param:"defaultSelectedRowKey",desc:"默认选中的行key",type:"StringNumber",optionalVal:"-",default:"-"},{param:"disableSelectedRowKeys",desc:"禁止勾选或者禁止取消勾选的行key",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"selectedRowKey",desc:"选中行的可控属性,设置后 defaultSelectedRowKey属性将会失效。具体参考示例",type:"StringNumber",optionalVal:"-",default:"-"},{param:"selectedRowChange",desc:"行选中的改变事件。事件接收 1 个参数,row:当前行数据",type:"Function({row})",optionalVal:"-",default:"-"}],columns:e},virtualScrollOption:{data:[{param:"enable",desc:"是否开启虚拟滚动",type:"Boolean",optionalVal:"-",default:"false"},{param:"minRowHeight",desc:"最小行高(px)。值越小,可视化范围渲染的数据越多,具体根据实际最小高度设置即可",type:"Number",optionalVal:"-",default:"40"},{param:"scrolling",desc:"滚动回调事件。
startRowIndex为当前开始渲染的行号,visibleStartIndex为当前可见区域的开始行号,visibleEndIndex为当前可见区域的结束行号,visibleAboveCount为当前可见区域上方渲染的数量,visibleBelowCount为当前可见区域下方渲染的数量",type:"Function({startRowIndex,visibleStartIndex,visibleEndIndex,visibleAboveCount,visibleBelowCount})",optionalVal:"-",default:"-"},{param:"bufferScale",desc:"缓冲倍数。1个缓冲倍数为当前表格高度内的行数量",type:"Number",optionalVal:"-",default:"1"}],columns:e},sortOption:{data:[{param:"multipleSort",desc:"是否开启多字段排序",type:"Boolean",optionalVal:"-",default:"false"},{param:"sortAlways",desc:"是否开启排序只在升序和降序切换",type:"Boolean",optionalVal:"-",default:"false"},{param:"sortChange",desc:"排序改变事件。事件接收 1 个参数对象,列的排序规则",type:"Function({row})",optionalVal:"-",default:"-"}],columns:e},cellSpanOption:{data:[{param:"bodyCellSpan",desc:"1、body单元格合并函数
2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"},{param:"footerCellSpan",desc:"1、footer单元格合并函数
2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"}],columns:e},eventCustomOption:{data:[{param:"bodyRowEvents",desc:"1、body 行自定义事件,返回需要自定义的事件。
2、接收2个参数。row当前行数据、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,rowIndx})",optionalVal:"-",default:"-"},{param:"bodyCellEvents",desc:"1、body 列自定义事件,返回需要自定义的事件。
2、接收3个参数。row当前行数据、column:当前列配置、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,column,rowIndx})",optionalVal:"-",default:"-"},{param:"headerRowEvents",desc:"1、header 行自定义事件,返回需要自定义的事件。
2、接收1个参数。rowIndex:表头行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave
",type:"Function({rowIndex})",optionalVal:"-",default:"-"},{param:"headerCellEvents",desc:"1、header 列自定义事件,返回需要自定义的事件。
2、接收2个参数。column:当前列配置、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({column,rowIndx})",optionalVal:"-",default:"-"},{param:"footerRowEvents",desc:"1、footer 行自定义事件,返回需要自定义的事件。
2、接收2个参数。row当前行数据、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,rowIndx})",optionalVal:"-",default:"-"},{param:"footerCellEvents",desc:"1、footer 列自定义事件,返回需要自定义的事件。
2、接收3个参数。row当前行数据、column:当前列配置、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,column,rowIndx})",optionalVal:"-",default:"-"}],columns:e},columnHiddenOption:{data:[{param:"defaultHiddenColumnKeys v2.11.0",desc:"设置默认隐藏的列",type:"Array",optionalVal:"-",default:"-"}],columns:e},cellStyleOption:{data:[{param:"bodyCellClass",desc:"1、表体单元格样式\r2、接收3个参数,row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"},{param:"headerCellClass",desc:"1、表头单元格样式\r2、接收2个参数,column:当前列配置、rowIndex:行索引",type:"Function({column,rowIndex})",optionalVal:"-",default:"-"},{param:"footerCellClass",desc:"1、footer汇总 单元格样式\r2、接收3个参数,row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"}],columns:e},rowStyleOption:{data:[{param:"hoverHighlight",desc:"是否开启行hover 背景高亮",type:"Boolean",optionalVal:"-",default:"true"},{param:"clickHighlight",desc:"是否开启行click 背景高亮",type:"Boolean",optionalVal:"-",default:"true"},{param:"stripe",desc:"是否开启斑马纹",type:"Boolean",optionalVal:"-",default:"false"}],columns:e},editOption:{data:[{param:"beforeStartCellEditing",desc:"单元格进入编辑状态前的回调方法。row当前行数据,column当前列信息,cellValue当前单元格的值。如果返回false,将则会阻止单元格进入编辑状态",type:"Function({ row, column,cellValue })",optionalVal:"-",default:"-"},{param:"beforeCellValueChange",desc:"单元格内容改变前的回调方法。row当前行数据,column当前列信息,changeValue单元格改变的值。如果返回false,将会阻止编辑,单元格还原为编辑前状态",type:"Function({ row, column,changeValue })",optionalVal:"-",default:"-"},{param:"afterCellValueChange",desc:"单元格内容改变后的回调方法。row当前行数据,column当前列信息,changeValue单元格改变的值",type:"Function({ row, column,changeValue })",optionalVal:"-",default:"-"},{param:"cellValueChange",desc:"即将废弃的方法",type:"Function({ row, column })",optionalVal:"-",default:"-"}],columns:e},contextmenuHeaderOption:{data:[{param:"beforeShow",desc:"菜单显示之前的回调事件,你可以在这个阶段改变菜单项信息。
isWholeColSelection是否整列选中,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ isWholeColSelection, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"afterMenuClick",desc:"菜单项被点击的回调,返回 false 将阻止当前右键操作。
type菜单类型,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ type, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"contextmenus",desc:"右键菜单配置项。 右键菜单组件",type:"Array",optionalVal:"-",default:"-"}],columns:e},contextmenuBodyOption:{data:[{param:"beforeShow",desc:"菜单显示之前的回调事件,你可以在这个阶段改变菜单项信息。
isWholeRowSelection是否整行选中,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ isWholeRowSelection, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"afterMenuClick",desc:"菜单项被点击的回调,返回 false 将阻止当前右键操作。
type菜单类型,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ type, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"contextmenus",desc:"右键菜单配置项。 右键菜单组件",type:"Array",optionalVal:"-",default:"-"}],columns:e},cellSelectionOption:{data:[{param:"enable",desc:"是否开启单元格选择",type:"Boolean",optionalVal:"-",default:"true"}],columns:e},cellAutofillOption:{data:[{param:"directionX",desc:"是否开启横向填充",type:"Boolean",optionalVal:"-",default:"true"},{param:"directionY",desc:"是否开启纵向填充",type:"Boolean",optionalVal:"-",default:"true"},{param:"beforeAutofill",desc:"单元格自动填充前的回调方法,返回false 则取消自动填充。参数说明:\r1、direction自动填充的方向\r2、sourceSelectionRangeIndexes自动填充来源的行和列索引\r3、targetSelectionRangeIndexes自动填充目标的行和列索引\r4、sourceSelectionData自动填充来源的数据,超出会自动去除\r5、targetSelectionData自动填充目标的数据",type:`Function({ + direction, + sourceSelectionRangeIndexes, + targetSelectionRangeIndexes, + sourceSelectionData, + targetSelectionData, +})`,optionalVal:"-",default:"-"},{param:"afterAutofill",desc:"单元格自动填充后的回调方法。参数说明:\r1、direction自动填充的方向\r2、sourceSelectionRangeIndexes自动填充来源的行和列索引\r3、targetSelectionRangeIndexes自动填充目标的行和列索引\r4、sourceSelectionData自动填充来源的数据,超出会自动去除\r5、targetSelectionData自动填充目标的数据",type:`Function({ + direction, + sourceSelectionRangeIndexes, + targetSelectionRangeIndexes, + sourceSelectionData, + targetSelectionData, +})`,optionalVal:"-",default:"-"}],columns:e},clipboardOption:{data:[{param:"copy",desc:"是否开启单元格复制",type:"Boolean",optionalVal:"-",default:"true"},{param:"paste",desc:"是否开启单元格粘贴",type:"Boolean",optionalVal:"-",default:"true"},{param:"cut",desc:"是否开启单元格剪切",type:"Boolean",optionalVal:"-",default:"true"},{param:"delete",desc:"是否开启单元格删除",type:"Boolean",optionalVal:"-",default:"true"},{param:"beforeCopy",desc:"单元格拷贝前的回调方法,返回false 则取消拷贝。参数说明:\r1、data拷贝的数据\r2、selectionRangeIndexes拷贝区域的索引信息\r3、selectionRangeKeys拷贝区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterCopy",desc:"单元格拷贝后回调方法。参数说明:\r1、data拷贝的数据\r2、selectionRangeIndexes拷贝区域的索引信息\r3、selectionRangeKeys拷贝区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"beforePaste",desc:"单元格粘贴前的回调方法,返回false 则取消粘贴。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterPaste",desc:"单元格粘贴后回调方法。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"beforeCut",desc:"单元格剪切前的回调方法,返回false 则取消剪切。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterCut",desc:"单元格剪切后回调方法。参数说明:\r1、data剪切的数据\r2、selectionRangeIndexes剪切区域的索引信息\r3、selectionRangeKeys剪切区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"beforeDelete",desc:"单元格删除前的回调方法,返回false 则取消删除。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterDelete",desc:"单元格删除后回调方法。参数说明:\r1、data删除的数据\r2、selectionRangeIndexes删除区域的索引信息\r3、selectionRangeKeys删除区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"}],columns:e},columnWidthResizeOption:{data:[{param:"enable",desc:"是否开启列宽可变",type:"Boolean",optionalVal:"-",default:"false"},{param:"minWidth",desc:"可改变列的最小宽度",type:"Number",optionalVal:"-",default:"30px"},{param:"sizeChange",desc:"列宽改变后的回调函数。参数说明:\r1、column宽度改变的列信息\r2、differWidth列宽改变后差异的宽度\r3、columnWidth列宽改变后的宽度",type:`Function({ + column, + differWidth, + columnWidth, +})`,optionalVal:"-",default:"-"}],columns:e}},h={name:"ApiTpl",props:{desc:{type:String,required:!0},anchor:{type:String,default:null},tableData:{type:Array,required:!0},columns:{type:Array,required:!0},expandOption:{type:Object,default(){return null}}},data(){return{cellSelectionOption:{enable:!1},cloneTable:[]}},computed:{getAnchor(){return this.anchor?this.anchor:this.desc}},watch:{tableData:{handler(o){o&&(this.cloneTable=o.map((d,a)=>(d.__key__=a,d)))},immediate:!0}}},w={class:"api-tpl"},g={class:"api-tpl-desc"};function V(o,d,a,t,l,r){const i=n("anchor"),s=n("ve-table");return u(),m("div",w,[c(i,{"is-edit":!1,label:r.getAnchor},null,8,["label"]),f("div",g,y(a.desc),1),c(s,{class:"tpl-table",columns:a.columns,"table-data":l.cloneTable,"border-around":!0,"border-x":!0,"border-y":!1,"row-key-field-name":"__key__","expand-option":a.expandOption,"cell-selection-option":l.cellSelectionOption},null,8,["columns","table-data","expand-option","cell-selection-option"])])}const S=p(h,[["render",V]]);export{R as d,S as t}; diff --git a/0.0.1/assets/cell-autofill-option-props-PVvG-H0r.js b/0.0.1/assets/cell-autofill-option-props-PVvG-H0r.js new file mode 100644 index 0000000..3137eb6 --- /dev/null +++ b/0.0.1/assets/cell-autofill-option-props-PVvG-H0r.js @@ -0,0 +1 @@ +import{t as l,d as n}from"./api-tpl-Z63SnkFF.js";import{_ as c,r as a,o as s,c as r,a as p}from"./index-BxRg2T26.js";const d={components:{Tpl:l},props:{anchor:{type:String,default:"单元格自动填充配置"},desc:{type:String,default:"cellAutofillOption"}},data(){return{db:n}}};function i(u,f,t,m,o,_){const e=a("Tpl");return s(),r("div",null,[p(e,{desc:t.desc,anchor:t.anchor,"table-data":o.db.cellAutofillOption.data,columns:o.db.cellAutofillOption.columns},null,8,["desc","anchor","table-data","columns"])])}const A=c(d,[["render",i]]);export{A as c}; diff --git a/0.0.1/assets/cell-selection-option-props-WpqHDtMX.js b/0.0.1/assets/cell-selection-option-props-WpqHDtMX.js new file mode 100644 index 0000000..7f0a665 --- /dev/null +++ b/0.0.1/assets/cell-selection-option-props-WpqHDtMX.js @@ -0,0 +1 @@ +import{t as n,d as c}from"./api-tpl-Z63SnkFF.js";import{_ as l,r as a,o as s,c as r,a as p}from"./index-BxRg2T26.js";const d={components:{Tpl:n},props:{anchor:{type:String,default:"单元格选择配置"},desc:{type:String,default:"cellSelectionOption"}},data(){return{db:c}}};function i(m,u,e,_,t,f){const o=a("Tpl");return s(),r("div",null,[p(o,{desc:e.desc,anchor:e.anchor,"table-data":t.db.cellSelectionOption.data,columns:t.db.cellSelectionOption.columns},null,8,["desc","anchor","table-data","columns"])])}const h=l(d,[["render",i]]);export{h as C}; diff --git a/0.0.1/assets/cell-span-yHkHui2h.js b/0.0.1/assets/cell-span-yHkHui2h.js new file mode 100644 index 0000000..4510614 --- /dev/null +++ b/0.0.1/assets/cell-span-yHkHui2h.js @@ -0,0 +1,137 @@ +import{V as m}from"./vue.runtime.esm-bundler-Tv19svLr.js";import{_ as b,r as i,o as y,c as f,a as l,w as s,m as n,p as d}from"./index-BxRg2T26.js";const g={name:"component-doc",components:{"element-demo0":{render:function(){const{resolveComponent:a,openBlock:e,createBlock:o}=m;return function(t,u){const r=a("ve-table");return e(),o(r,{"border-y":"","fixed-header":"","max-height":300,columns:t.columns,"table-data":t.tableData,"footer-data":t.footerData,rowKeyFieldName:"rowKey","cell-span-option":t.cellSpanOption},null,8,["columns","table-data","footer-data","cell-span-option"])}}(),...function(){return{data(){return{cellSpanOption:{footerCellSpan:this.footerCellSpan},columns:[{field:"name",key:"a",title:"Name",width:200,align:"center"},{field:"date",key:"b",title:"Date",width:200,align:"left"},{field:"hobby",key:"c",title:"Hobby",width:200,align:"right"},{field:"address",key:"d",title:"Address",width:""}],tableData:[{name:"John",date:"1900-05-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Shanghai"},{name:"Dickerson",date:"1910-06-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Beijing"},{name:"Larsen",date:"2000-07-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Chongqing"},{name:"Geneva",date:"2010-08-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Xiamen"},{name:"Jami",date:"2020-09-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Shenzhen"}]}},methods:{footerCellSpan({row:a,column:e,rowIndex:o}){if(o===0){if(e.field==="date")return{rowspan:1,colspan:2};if(e.field==="hobby")return{rowspan:0,colspan:0}}},initTableData(){let a=[];for(let e=0;e<15;e++)a.push({rowKey:e,name:e,date:e,hobby:e,address:e});this.tableData=a},initFooterData(){this.footerData=[{rowKey:0,name:"平均值",date:213,hobby:355,address:189},{rowKey:1,name:"汇总值",date:1780,hobby:890,address:2988}]}},created(){this.initTableData(),this.initFooterData()}}}()}}},C={class:"content example-md-doc"},w=n("div",null,[n("p",null,[d("设置 footer 汇总第 1 行"),n("code",null,"date"),d("列和"),n("code",null,"hoby"),d("列合并。 同时需要指定第 2 行"),n("code",null,"hoby"),d("列不渲染")])],-1),_=n("pre",null,[n("code",{class:"html"},` + + + diff --git a/assets/QA-DfjvJ4Mh.js b/assets/QA-DfjvJ4Mh.js new file mode 100644 index 0000000..c629891 --- /dev/null +++ b/assets/QA-DfjvJ4Mh.js @@ -0,0 +1,7 @@ +import{_ as n,r as s,o as d,c,a as t,m as e,p as l}from"./index-1-5pqjkO.js";const r={},a={class:"content example-md-doc"},i=e("h2",null,"常见问题",-1),_=e("p",null,[l("Q:"),e("code",null,"scrollWidth"),l("属性的用法?")],-1),h=e("p",null,[l("A:当外层容器宽度小于 "),e("code",null,"scrollWidth"),l(" 值时,将会出现横向滚动条;当外层容器宽度大于 "),e("code",null,"scrollWidth"),l(" 值时,将会跟随容器自适应")],-1),u=e("p",null,"Q:为什么设置固定列后,有些列无法显示?",-1),m=e("p",null,[l("A:因为设置的 "),e("code",null,"scrollWidth"),l("值小于列(设置具体宽度的)的宽度之和,会导致未设置宽度或者设置百分比的列挤掉")],-1),p=e("p",null,[l("Q:什么时候使用"),e("code",null,"rowKeyFieldName"),l(" 属性?")],-1),f=e("p",null,"A:此属性为了解决数据更新时,渲染的正确性。适用的功能有:行展开、行单选、行多选、行点击高亮、虚拟滚动",-1),b=e("p",null,[l("Q:为什么使用自定义列渲染函数"),e("code",null,"renderBodyCell"),l("报‘ReferenceError: h is not defined’")],-1),A=e("p",null,[l("A:参考"),e("a",{href:"https://cn.vuejs.org/v2/guide/render-function.html#JSX"},"官方文档"),l("。你可以"),e("strong",null,"加上"),l("第二个参数解决,如:")],-1),N=e("pre",null,[e("code",null,`renderBodyCell: ({ row, column, rowIndex },h) => { + return (
hello
); +} +`)],-1),Q=e("p",null,"Q:为什么当单元格内容过多时,设置的宽度不生效",-1),w=e("p",null,[l("A:当单元格文本内容过多时会破坏布局,此时可以通过样式 "),e("a",{href:"https://developer.mozilla.org/zh-CN/docs/Web/CSS/word-break"},"word-break"),l(" 控制("),e("a",{href:"#/zh/doc/table/column-width?anchor=long-text-destroys-layout"},"具体参考这个示例"),l("),如:")],-1),g=e("pre",null,[e("code",{class:"language-html"},` +`)],-1),v=e("p",null,"Q:如何自定义滚动条样式",-1),k=e("p",null,"A:组件内部没有定制滚动条样式,根据你的业务自定义即可。滚动条样式自定义可参考:https://developer.mozilla.org/zh-CN/docs/Web/CSS/::-webkit-scrollbar",-1);function x(y,C){const o=s("anchor");return d(),c("section",a,[i,t(o,{"is-edit":"",label:"scrollWidth 属性",fileName:"QA.md"}),_,h,t(o,{"is-edit":"",label:"固定列",fileName:"QA.md"}),u,m,t(o,{"is-edit":"",label:"rowKeyFieldName 属性",fileName:"QA.md"}),p,f,t(o,{"is-edit":"",label:"报错:‘ReferenceError: h is not defined’",fileName:"QA.md"}),b,A,N,t(o,{"is-edit":"",label:"长文本破坏布局",fileName:"QA.md"}),Q,w,g,t(o,{"is-edit":"",label:"自定义滚动条样式",fileName:"QA.md"}),v,k])}const z=n(r,[["render",x]]);export{z as default}; diff --git a/assets/api-tpl-2bea2PZj.js b/assets/api-tpl-2bea2PZj.js new file mode 100644 index 0000000..5f0d610 --- /dev/null +++ b/assets/api-tpl-2bea2PZj.js @@ -0,0 +1,33 @@ +import{a as c,_ as p,r as n,o as u,c as m,m as f,t as y}from"./index-1-5pqjkO.js";const e=[{key:"a",field:"param",title:"参数",width:"10%",align:"left",type:"expand",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.param},null)},{key:"b",field:"desc",title:"说明",width:"60%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.desc},null)},{key:"c",field:"type",title:"类型",width:"10%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.type},null)},{key:"d",field:"optionalVal",title:"可选值",width:"10%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.optionalVal},null)},{key:"e",field:"default",title:"默认值",width:"10%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.default},null)}],b=[{key:"b",field:"name",title:"方法名",width:"15%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.name},null)},{key:"c",field:"desc",title:"说明",width:"65%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.desc},null)},{key:"d",field:"param",title:"参数",width:"20%",align:"left",renderBodyCell:({row:o,column:d,rowIndex:a},t)=>c("span",{innerHTML:o.param},null)}],R={table:{data:[{param:"tableData",desc:"表格数据",type:"Array",optionalVal:"-",default:"-"},{param:"footerData",desc:"表格footer 汇总数据,数据结构和 tableData 一致",type:"Array",optionalVal:"-",default:"-"},{param:"columns",desc:"列配置,具体项见下表 columns 配置",type:"Array",optionalVal:"-",default:"-"},{param:"showHeader",desc:"是否展示表头",type:"Boolean",optionalVal:"-",default:"true"},{param:"fixedHeader",desc:"是否固定表头,默认启用。需要和 `maxHeight`结合使用",type:"Boolean",optionalVal:"-",default:"true"},{param:"fixedFooter",desc:"是否固定footer 汇总,默认启用。需要和 `maxHeight`结合使用",type:"Boolean",optionalVal:"-",default:"true"},{param:"scrollWidth",desc:"表格滚动区域的宽(开始出滚动条的宽度)。Number指定像素;String指定百分比",type:"NumberString",optionalVal:"-",default:"-"},{param:"maxHeight",desc:"表格的最大高度。Number指定像素;String指定百分比。用于“固定头”或“虚拟滚动”功能",type:"NumberString",optionalVal:"-",default:"-"},{param:"rowKeyFieldName",desc:"指定 row key 的字段名称。用于行展开、行单选、行多选、行点击高亮、虚拟滚动",type:"String",optionalVal:"-",default:"-"},{param:"borderAround",desc:"是否展示表格外边框",type:"Boolean",optionalVal:"-",default:"true"},{param:"borderX",desc:"是否展示列横向边框",type:"Boolean",optionalVal:"-",default:"true"},{param:"borderY",desc:"是否展示列纵向边框",type:"Boolean",optionalVal:"-",default:"false"},{param:"cellSpanOption",desc:"单元格合并配置,具体见下表 cellSpanOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"columnHiddenOption",desc:"列隐藏配置,具体见下表 columnHiddenOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"cellStyleOption",desc:"单元格样式配置,具体见下表 cellStyleOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"rowStyleOption",desc:"行样式配置,具体见下表 rowStyleOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"expandOption",desc:"行展开配置,具体见下表 expandOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"checkboxOption",desc:"行多选配置,具体见下表 checkboxOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"radioOption",desc:"行单选配置,具体见下表 radioOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"virtualScrollOption",desc:"虚拟滚动配置,建议需要一次性展示1000条以上使用。具体见下表 virtualScrollOption 配置。",type:"Object",optionalVal:"-",default:"-"},{param:"sortOption",desc:"排序配置,具体见下表 sortOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"cellSelectionOption",desc:"单元格选择配置,具体见下表 cellSelectionOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"editOption",desc:"单元格编辑配置,具体见下表 editOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"contextmenuHeaderOption",desc:"表格 header 右键菜单配置,具体见下表 contextmenuHeaderOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"contextmenuBodyOption",desc:"表格 body 右键菜单配置,具体见下表 contextmenuBodyOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"eventCustomOption",desc:"自定义事件配置,具体见下表 eventCustomOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"cellAutofillOption",desc:"单元格自动填充配置,具体见下表 cellAutofillOption 配置",type:"Object",optionalVal:"-",default:"-"},{param:"clipboardOption",desc:"单元格剪贴板配置,具体见下表 clipboardOption 配置",type:"Object",optionalVal:"-",default:"-"}],columns:e},columns:{data:[{param:"field",desc:"对应列的字段",type:"String",optionalVal:"-",default:"-"},{param:"key",desc:"每个列的唯一key值",type:"String",optionalVal:"-",default:"-"},{param:"type",desc:'当前列类型。 "expand":行展开;"checkbox":行多选;"radio":行单选',type:"String",optionalVal:'"expand"、"checkbox"、"radio"',default:"-"},{param:"title",desc:"列标题",type:"String",optionalVal:"-",default:"-"},{param:"width",desc:"Number指定像素;String指定百分比(指定了也不生效?)",type:"StringNumber",optionalVal:"-",default:"-"},{param:"align",desc:"单元格对齐方式",type:"String",optionalVal:'"left"、"center"、"right"',default:'"center"'},{param:"operationColumn",desc:"是否是操作列",type:"Boolean",optionalVal:"-",default:"false"},{param:"edit",desc:"是否开启列编辑",type:"Boolean",optionalVal:"-",default:"false"},{param:"sortBy",desc:'排序规则。
1、sortBy="":允许排序但无排序规则;
2、sortBy="asc":默认当前列升序;
3、sortBy="desc":默认当前列降序;',type:"String",optionalVal:'""、"desc"、"asc"',default:'""'},{param:"renderBodyCell",desc:'1、表体自定义单元格渲染函数。jsx 语法,书写和模板语法接近。\r2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引、h:createElement 函数的别名
3、更多 jsx 知识请参考Vue.js 官方文档',type:"Function({row,column,rowIndex},h):VNode",optionalVal:"-",default:"-"},{param:"renderHeaderCell",desc:"1、表头自定义单元格渲染函数。用法同renderBodyCell。\r2、参数信息。column:当前列配置、h:createElement 函数的别名",type:"Function({ column },h):VNode",optionalVal:"-",default:"-"},{param:"renderFooterCell",desc:'1、footer汇总 自定义单元格渲染函数。\r2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引、h:createElement 函数的别名
3、更多 jsx 知识请参考Vue.js 官方文档',type:"Function({row,column,rowIndex},h):VNode",optionalVal:"-",default:"-"},{param:"disableResizing",desc:"Disable resizing for this column. Only effective if columnWidthResizeOption is enabled",type:"Boolean",optionalVal:"-",default:"false",rowKey:46},{param:"ellipsis",desc:"单元格省略配置。",type:"Object",optionalVal:"-",default:"-",expandId:49},{param:"filter",desc:"筛选配置。",type:"Object",optionalVal:"-",default:"-",expandId:50},{param:"filterCustom",desc:"筛选自定义配置。",type:"Object",optionalVal:"-",default:"-",expandId:55}],columns:e,filterProps:{data:[{param:"filterList",desc:'1、筛选条件。
2、包含label、value、selected 3 个属性,形如:[{ value: 0, label: "1900-05-20", selected: false }]',type:"Array",optionalVal:"-",default:"-"},{param:"isMultiple",desc:"开启筛选项多选。
",type:"Boolean",optionalVal:"-",default:"false"},{param:"filterConfirm",desc:"1、筛选确认函数。
2、接收1个参数,filterList:筛选条件",type:"Function({filterList})",optionalVal:"-",default:"-"},{param:"filterReset",desc:"1、筛选重置函数
2、接收1个参数,filterList:筛选条件",type:"Function({filterList})",optionalVal:"-",default:"-"},{param:"filterIcon",desc:"1、filter 自定义图标渲染函数。
2、参数信息。h:createElement 函数的别名",type:"Function(h):VNode",optionalVal:"-",default:"-"},{param:"maxHeight",desc:"1、筛选框的最大高度。不包含操作按钮的高度",type:"Number",optionalVal:"-",default:"1000"},{param:"beforeVisibleChange({nextVisible})",desc:"filter 面板显示或者隐藏之前的回调方法,返回false则阻止显示或隐藏",type:"Function",optionalVal:"-",default:"-"}],columns:e},filterCustomProps:{data:[{param:"render",desc:"1、渲染函数。
2、渲染函数接收的参数,showFn:显示filter 函数、closeFn:关闭filter的函数、h:createElement 函数的别名",type:"Function({showFn,closeFn},h):VNode",optionalVal:"-",default:"-"},{param:"filterIcon",desc:"1、filter 自定义图标渲染函数。
2、参数信息。h:createElement 函数的别名",type:"Function(h):VNode",optionalVal:"-",default:"-"},{param:"beforeVisibleChange({nextVisible})",desc:"filter 面板显示或者隐藏之前的回调方法,返回false则阻止显示或隐藏",type:"Function",optionalVal:"-",default:"-"}],columns:e},ellipsisProps:{data:[{param:"lineClamp",desc:"多少行开始省略",type:"Number",optionalVal:"-",default:"1"},{param:"showTitle",desc:"是否鼠标悬浮,展示title",type:"Boolean",optionalVal:"-",default:"true"}],columns:e}},instanceMethods:{data:[{name:"scrollTo",desc:"使表格滚动到指定的位置 参考示例",param:"参考 MDN scrollTo"},{name:"scrollToColKey",desc:"将指定的列显示在可视区域 参考示例",param:"{ rowKey, colKey }"},{name:"scrollToRowKey",desc:"将表格滚动到行为rowKey的位置 参考示例",param:"{rowKey}"},{name:"setHighlightRow",desc:"设置高亮的行 参考示例",param:"{rowKey}"},{name:"startEditingCell",desc:"开始单元格编辑 参考示例",param:"{rowKey,colKey,defaultValue}"},{name:"stopEditingCell",desc:"停止单元格编辑",param:"-"},{name:"hideColumnsByKeys",desc:"隐藏列 参考示例",param:"keys"},{name:"showColumnsByKeys",desc:"显示列 参考示例",param:"keys"},{name:"setCellSelection",desc:"单元格选中 参考示例",param:"{ rowKey, colKey }"},{name:"setAllCellSelection",desc:"单元格全选 参考示例",param:"-"},{name:"setRangeCellSelection",desc:"区域单元格选中 参考示例",param:"{ startRowKey,startColKey,endRowKey,endColKey,isScrollToStartCell }"},{name:"getRangeCellSelection",desc:"获取当前选择区域的信息。返回所选区域索引和key信息",param:"{selectionRangeKeys,selectionRangeIndexes}"}],columns:b},expandOption:{data:[{param:"expandable",desc:"1、是否允许展开行渲染函数。返回布尔值。\r2、渲染函数接收三个参数,row:当前行数据、column:可展开列配置、rowIndex:行索引。",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"},{param:"render",desc:"1、渲染函数。\r2、渲染函数接收的参数,row:当前行数据、column:可展开列配置、rowIndex:行索引、h:createElement 函数的别名",type:"Function({row,column,rowIndex},h):VNode",optionalVal:"-",default:"-"},{param:"defaultExpandAllRows",desc:"是否默认展开全部行",type:"Boolean",optionalVal:"-",default:"false"},{param:"defaultExpandedRowKeys",desc:"默认展开的行key。defaultExpandAllRows 参数和defaultExpandedRowKeys 参数同时存在时,优先使用defaultExpandAllRows",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"expandedRowKeys",desc:"展开行的可控属性,设置后属性后 defaultExpandAllRowsdefaultExpandedRowKeys属性将会失效。具体见相关实例",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"beforeExpandRowChange",desc:"1、展开切换前的函数,如果返回false 则中断执行。\r2、函数接收三个参数,beforeExpandedRowKeys:改变前所有展开的key,row:当前的行数据,rowIndex行号",type:"Function({beforeExpandedRowKeys,row,rowIndex})",optionalVal:"-",default:"-"},{param:"afterExpandRowChange",desc:"1、展开切换后的函数。\r2、函数接收三个参数,afterExpandedRowKeys:改变后所有展开的key,row:当前的行数据,rowIndex行号",type:"Function({afterExpandedRowKeys,row,rowIndex})",optionalVal:"-",default:"-"},{param:"trigger",desc:"展开行事件触发类型。\ricon:点击展开小图标;cell:点击单元格;row:点击行",type:"String",optionalVal:'"icon"、"cell"、"row"',default:'"icon"'}],columns:e},checkboxOption:{data:[{param:"defaultSelectedAllRows",desc:"是否默认全部选中",type:"Boolean",optionalVal:"-",default:"false"},{param:"defaultSelectedRowKeys",desc:"默认选中的行key",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"disableSelectedRowKeys",desc:"禁止勾选或者禁止取消勾选的行key",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"selectedRowKeys",desc:"选中行的可控属性,设置后 defaultSelectedAllRowsdefaultSelectedRowKeys 属性将会失效。具体参考示例",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"selectedRowChange",desc:"行选中的改变事件。事件接收 3 个参数,row:当前行数据,isSelected当前行是否选中,selectedRowKeys所有选中的 rowKey 信息",type:"Function({row, isSelected, selectedRowKeys})",optionalVal:"-",default:"-"},{param:"selectedAllChange",desc:"全选改变事件。事件接收 2 个参数,isSelected 是否全选。selectedRowKeys所有选中的 rowKey 信息",type:"Function({isSelected, selectedRowKeys})",optionalVal:"-",default:"-"},{param:"hideSelectAll",desc:"是否隐藏全选按钮",type:"Boolean",optionalVal:"-",default:"false"}],columns:e},radioOption:{data:[{param:"defaultSelectedRowKey",desc:"默认选中的行key",type:"StringNumber",optionalVal:"-",default:"-"},{param:"disableSelectedRowKeys",desc:"禁止勾选或者禁止取消勾选的行key",type:"String[]Number[]",optionalVal:"-",default:"-"},{param:"selectedRowKey",desc:"选中行的可控属性,设置后 defaultSelectedRowKey属性将会失效。具体参考示例",type:"StringNumber",optionalVal:"-",default:"-"},{param:"selectedRowChange",desc:"行选中的改变事件。事件接收 1 个参数,row:当前行数据",type:"Function({row})",optionalVal:"-",default:"-"}],columns:e},virtualScrollOption:{data:[{param:"enable",desc:"是否开启虚拟滚动",type:"Boolean",optionalVal:"-",default:"false"},{param:"minRowHeight",desc:"最小行高(px)。值越小,可视化范围渲染的数据越多,具体根据实际最小高度设置即可",type:"Number",optionalVal:"-",default:"40"},{param:"scrolling",desc:"滚动回调事件。
startRowIndex为当前开始渲染的行号,visibleStartIndex为当前可见区域的开始行号,visibleEndIndex为当前可见区域的结束行号,visibleAboveCount为当前可见区域上方渲染的数量,visibleBelowCount为当前可见区域下方渲染的数量",type:"Function({startRowIndex,visibleStartIndex,visibleEndIndex,visibleAboveCount,visibleBelowCount})",optionalVal:"-",default:"-"},{param:"bufferScale",desc:"缓冲倍数。1个缓冲倍数为当前表格高度内的行数量",type:"Number",optionalVal:"-",default:"1"}],columns:e},sortOption:{data:[{param:"multipleSort",desc:"是否开启多字段排序",type:"Boolean",optionalVal:"-",default:"false"},{param:"sortAlways",desc:"是否开启排序只在升序和降序切换",type:"Boolean",optionalVal:"-",default:"false"},{param:"sortChange",desc:"排序改变事件。事件接收 1 个参数对象,列的排序规则",type:"Function({row})",optionalVal:"-",default:"-"}],columns:e},cellSpanOption:{data:[{param:"bodyCellSpan",desc:"1、body单元格合并函数
2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"},{param:"footerCellSpan",desc:"1、footer单元格合并函数
2、参数信息。row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"}],columns:e},eventCustomOption:{data:[{param:"bodyRowEvents",desc:"1、body 行自定义事件,返回需要自定义的事件。
2、接收2个参数。row当前行数据、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,rowIndx})",optionalVal:"-",default:"-"},{param:"bodyCellEvents",desc:"1、body 列自定义事件,返回需要自定义的事件。
2、接收3个参数。row当前行数据、column:当前列配置、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,column,rowIndx})",optionalVal:"-",default:"-"},{param:"headerRowEvents",desc:"1、header 行自定义事件,返回需要自定义的事件。
2、接收1个参数。rowIndex:表头行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave
",type:"Function({rowIndex})",optionalVal:"-",default:"-"},{param:"headerCellEvents",desc:"1、header 列自定义事件,返回需要自定义的事件。
2、接收2个参数。column:当前列配置、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({column,rowIndx})",optionalVal:"-",default:"-"},{param:"footerRowEvents",desc:"1、footer 行自定义事件,返回需要自定义的事件。
2、接收2个参数。row当前行数据、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,rowIndx})",optionalVal:"-",default:"-"},{param:"footerCellEvents",desc:"1、footer 列自定义事件,返回需要自定义的事件。
2、接收3个参数。row当前行数据、column:当前列配置、rowIndex:行索引
3、支持自定义事件有 click、dblclick、contextmenu、mouseenter、mouseleave",type:"Function({row,column,rowIndx})",optionalVal:"-",default:"-"}],columns:e},columnHiddenOption:{data:[{param:"defaultHiddenColumnKeys v2.11.0",desc:"设置默认隐藏的列",type:"Array",optionalVal:"-",default:"-"}],columns:e},cellStyleOption:{data:[{param:"bodyCellClass",desc:"1、表体单元格样式\r2、接收3个参数,row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"},{param:"headerCellClass",desc:"1、表头单元格样式\r2、接收2个参数,column:当前列配置、rowIndex:行索引",type:"Function({column,rowIndex})",optionalVal:"-",default:"-"},{param:"footerCellClass",desc:"1、footer汇总 单元格样式\r2、接收3个参数,row:当前行数据、column:当前列配置、rowIndex:行索引",type:"Function({row,column,rowIndex})",optionalVal:"-",default:"-"}],columns:e},rowStyleOption:{data:[{param:"hoverHighlight",desc:"是否开启行hover 背景高亮",type:"Boolean",optionalVal:"-",default:"true"},{param:"clickHighlight",desc:"是否开启行click 背景高亮",type:"Boolean",optionalVal:"-",default:"true"},{param:"stripe",desc:"是否开启斑马纹",type:"Boolean",optionalVal:"-",default:"false"}],columns:e},editOption:{data:[{param:"beforeStartCellEditing",desc:"单元格进入编辑状态前的回调方法。row当前行数据,column当前列信息,cellValue当前单元格的值。如果返回false,将则会阻止单元格进入编辑状态",type:"Function({ row, column,cellValue })",optionalVal:"-",default:"-"},{param:"beforeCellValueChange",desc:"单元格内容改变前的回调方法。row当前行数据,column当前列信息,changeValue单元格改变的值。如果返回false,将会阻止编辑,单元格还原为编辑前状态",type:"Function({ row, column,changeValue })",optionalVal:"-",default:"-"},{param:"afterCellValueChange",desc:"单元格内容改变后的回调方法。row当前行数据,column当前列信息,changeValue单元格改变的值",type:"Function({ row, column,changeValue })",optionalVal:"-",default:"-"},{param:"cellValueChange",desc:"即将废弃的方法",type:"Function({ row, column })",optionalVal:"-",default:"-"}],columns:e},contextmenuHeaderOption:{data:[{param:"beforeShow",desc:"菜单显示之前的回调事件,你可以在这个阶段改变菜单项信息。
isWholeColSelection是否整列选中,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ isWholeColSelection, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"afterMenuClick",desc:"菜单项被点击的回调,返回 false 将阻止当前右键操作。
type菜单类型,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ type, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"contextmenus",desc:"右键菜单配置项。 右键菜单组件",type:"Array",optionalVal:"-",default:"-"}],columns:e},contextmenuBodyOption:{data:[{param:"beforeShow",desc:"菜单显示之前的回调事件,你可以在这个阶段改变菜单项信息。
isWholeRowSelection是否整行选中,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ isWholeRowSelection, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"afterMenuClick",desc:"菜单项被点击的回调,返回 false 将阻止当前右键操作。
type菜单类型,
selectionRangeKeys 当前选中的单元格key信息,
selectionRangeIndexes 当前选中的单元格索引信息",type:"Function({ type, selectionRangeKeys, selectionRangeIndexes })",optionalVal:"-",default:"-"},{param:"contextmenus",desc:"右键菜单配置项。 右键菜单组件",type:"Array",optionalVal:"-",default:"-"}],columns:e},cellSelectionOption:{data:[{param:"enable",desc:"是否开启单元格选择",type:"Boolean",optionalVal:"-",default:"true"}],columns:e},cellAutofillOption:{data:[{param:"directionX",desc:"是否开启横向填充",type:"Boolean",optionalVal:"-",default:"true"},{param:"directionY",desc:"是否开启纵向填充",type:"Boolean",optionalVal:"-",default:"true"},{param:"beforeAutofill",desc:"单元格自动填充前的回调方法,返回false 则取消自动填充。参数说明:\r1、direction自动填充的方向\r2、sourceSelectionRangeIndexes自动填充来源的行和列索引\r3、targetSelectionRangeIndexes自动填充目标的行和列索引\r4、sourceSelectionData自动填充来源的数据,超出会自动去除\r5、targetSelectionData自动填充目标的数据",type:`Function({ + direction, + sourceSelectionRangeIndexes, + targetSelectionRangeIndexes, + sourceSelectionData, + targetSelectionData, +})`,optionalVal:"-",default:"-"},{param:"afterAutofill",desc:"单元格自动填充后的回调方法。参数说明:\r1、direction自动填充的方向\r2、sourceSelectionRangeIndexes自动填充来源的行和列索引\r3、targetSelectionRangeIndexes自动填充目标的行和列索引\r4、sourceSelectionData自动填充来源的数据,超出会自动去除\r5、targetSelectionData自动填充目标的数据",type:`Function({ + direction, + sourceSelectionRangeIndexes, + targetSelectionRangeIndexes, + sourceSelectionData, + targetSelectionData, +})`,optionalVal:"-",default:"-"}],columns:e},clipboardOption:{data:[{param:"copy",desc:"是否开启单元格复制",type:"Boolean",optionalVal:"-",default:"true"},{param:"paste",desc:"是否开启单元格粘贴",type:"Boolean",optionalVal:"-",default:"true"},{param:"cut",desc:"是否开启单元格剪切",type:"Boolean",optionalVal:"-",default:"true"},{param:"delete",desc:"是否开启单元格删除",type:"Boolean",optionalVal:"-",default:"true"},{param:"beforeCopy",desc:"单元格拷贝前的回调方法,返回false 则取消拷贝。参数说明:\r1、data拷贝的数据\r2、selectionRangeIndexes拷贝区域的索引信息\r3、selectionRangeKeys拷贝区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterCopy",desc:"单元格拷贝后回调方法。参数说明:\r1、data拷贝的数据\r2、selectionRangeIndexes拷贝区域的索引信息\r3、selectionRangeKeys拷贝区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"beforePaste",desc:"单元格粘贴前的回调方法,返回false 则取消粘贴。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterPaste",desc:"单元格粘贴后回调方法。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"beforeCut",desc:"单元格剪切前的回调方法,返回false 则取消剪切。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterCut",desc:"单元格剪切后回调方法。参数说明:\r1、data剪切的数据\r2、selectionRangeIndexes剪切区域的索引信息\r3、selectionRangeKeys剪切区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"beforeDelete",desc:"单元格删除前的回调方法,返回false 则取消删除。参数说明:\r1、data粘贴的数据\r2、selectionRangeIndexes粘贴区域的索引信息\r3、selectionRangeKeys粘贴区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"},{param:"afterDelete",desc:"单元格删除后回调方法。参数说明:\r1、data删除的数据\r2、selectionRangeIndexes删除区域的索引信息\r3、selectionRangeKeys删除区域的key信息",type:`Function({ + data, selectionRangeIndexes, selectionRangeKeys +})`,optionalVal:"-",default:"-"}],columns:e},columnWidthResizeOption:{data:[{param:"enable",desc:"是否开启列宽可变",type:"Boolean",optionalVal:"-",default:"false"},{param:"minWidth",desc:"可改变列的最小宽度",type:"Number",optionalVal:"-",default:"30px"},{param:"sizeChange",desc:"列宽改变后的回调函数。参数说明:\r1、column宽度改变的列信息\r2、differWidth列宽改变后差异的宽度\r3、columnWidth列宽改变后的宽度",type:`Function({ + column, + differWidth, + columnWidth, +})`,optionalVal:"-",default:"-"}],columns:e}},h={name:"ApiTpl",props:{desc:{type:String,required:!0},anchor:{type:String,default:null},tableData:{type:Array,required:!0},columns:{type:Array,required:!0},expandOption:{type:Object,default(){return null}}},data(){return{cellSelectionOption:{enable:!1},cloneTable:[]}},computed:{getAnchor(){return this.anchor?this.anchor:this.desc}},watch:{tableData:{handler(o){o&&(this.cloneTable=o.map((d,a)=>(d.__key__=a,d)))},immediate:!0}}},w={class:"api-tpl"},g={class:"api-tpl-desc"};function V(o,d,a,t,l,r){const i=n("anchor"),s=n("ve-table");return u(),m("div",w,[c(i,{"is-edit":!1,label:r.getAnchor},null,8,["label"]),f("div",g,y(a.desc),1),c(s,{class:"tpl-table",columns:a.columns,"table-data":l.cloneTable,"border-around":!0,"border-x":!0,"border-y":!1,"row-key-field-name":"__key__","expand-option":a.expandOption,"cell-selection-option":l.cellSelectionOption},null,8,["columns","table-data","expand-option","cell-selection-option"])])}const S=p(h,[["render",V]]);export{R as d,S as t}; diff --git a/assets/cell-autofill-option-props-0R_Om15t.js b/assets/cell-autofill-option-props-0R_Om15t.js new file mode 100644 index 0000000..5174fd2 --- /dev/null +++ b/assets/cell-autofill-option-props-0R_Om15t.js @@ -0,0 +1 @@ +import{t as l,d as n}from"./api-tpl-2bea2PZj.js";import{_ as c,r as a,o as s,c as r,a as p}from"./index-1-5pqjkO.js";const d={components:{Tpl:l},props:{anchor:{type:String,default:"单元格自动填充配置"},desc:{type:String,default:"cellAutofillOption"}},data(){return{db:n}}};function i(u,f,t,m,o,_){const e=a("Tpl");return s(),r("div",null,[p(e,{desc:t.desc,anchor:t.anchor,"table-data":o.db.cellAutofillOption.data,columns:o.db.cellAutofillOption.columns},null,8,["desc","anchor","table-data","columns"])])}const A=c(d,[["render",i]]);export{A as c}; diff --git a/assets/cell-selection-option-props-tDEDSk04.js b/assets/cell-selection-option-props-tDEDSk04.js new file mode 100644 index 0000000..f13fbaa --- /dev/null +++ b/assets/cell-selection-option-props-tDEDSk04.js @@ -0,0 +1 @@ +import{t as n,d as c}from"./api-tpl-2bea2PZj.js";import{_ as l,r as a,o as s,c as r,a as p}from"./index-1-5pqjkO.js";const d={components:{Tpl:n},props:{anchor:{type:String,default:"单元格选择配置"},desc:{type:String,default:"cellSelectionOption"}},data(){return{db:c}}};function i(m,u,e,_,t,f){const o=a("Tpl");return s(),r("div",null,[p(o,{desc:e.desc,anchor:e.anchor,"table-data":t.db.cellSelectionOption.data,columns:t.db.cellSelectionOption.columns},null,8,["desc","anchor","table-data","columns"])])}const h=l(d,[["render",i]]);export{h as C}; diff --git a/assets/cell-span-ZlkhoFuz.js b/assets/cell-span-ZlkhoFuz.js new file mode 100644 index 0000000..642a812 --- /dev/null +++ b/assets/cell-span-ZlkhoFuz.js @@ -0,0 +1,137 @@ +import{V as m}from"./vue.runtime.esm-bundler-BRNTKtdd.js";import{_ as b,r as i,o as y,c as f,a as l,w as s,m as n,p as d}from"./index-1-5pqjkO.js";const g={name:"component-doc",components:{"element-demo0":{render:function(){const{resolveComponent:a,openBlock:e,createBlock:o}=m;return function(t,u){const r=a("ve-table");return e(),o(r,{"border-y":"","fixed-header":"","max-height":300,columns:t.columns,"table-data":t.tableData,"footer-data":t.footerData,rowKeyFieldName:"rowKey","cell-span-option":t.cellSpanOption},null,8,["columns","table-data","footer-data","cell-span-option"])}}(),...function(){return{data(){return{cellSpanOption:{footerCellSpan:this.footerCellSpan},columns:[{field:"name",key:"a",title:"Name",width:200,align:"center"},{field:"date",key:"b",title:"Date",width:200,align:"left"},{field:"hobby",key:"c",title:"Hobby",width:200,align:"right"},{field:"address",key:"d",title:"Address",width:""}],tableData:[{name:"John",date:"1900-05-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Shanghai"},{name:"Dickerson",date:"1910-06-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Beijing"},{name:"Larsen",date:"2000-07-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Chongqing"},{name:"Geneva",date:"2010-08-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Xiamen"},{name:"Jami",date:"2020-09-20",hobby:"coding and coding repeat",address:"No.1 Century Avenue, Shenzhen"}]}},methods:{footerCellSpan({row:a,column:e,rowIndex:o}){if(o===0){if(e.field==="date")return{rowspan:1,colspan:2};if(e.field==="hobby")return{rowspan:0,colspan:0}}},initTableData(){let a=[];for(let e=0;e<15;e++)a.push({rowKey:e,name:e,date:e,hobby:e,address:e});this.tableData=a},initFooterData(){this.footerData=[{rowKey:0,name:"平均值",date:213,hobby:355,address:189},{rowKey:1,name:"汇总值",date:1780,hobby:890,address:2988}]}},created(){this.initTableData(),this.initFooterData()}}}()}}},C={class:"content example-md-doc"},w=n("div",null,[n("p",null,[d("设置 footer 汇总第 1 行"),n("code",null,"date"),d("列和"),n("code",null,"hoby"),d("列合并。 同时需要指定第 2 行"),n("code",null,"hoby"),d("列不渲染")])],-1),_=n("pre",null,[n("code",{class:"html"},` + + +