vxe-table 4.23.5 → 4.23.6
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/all.esm.js +32456 -33938
- package/dist/style.css +4501 -1
- package/dist/style.mini.css +1 -0
- package/es/colgroup/index.d.ts +760 -0
- package/es/colgroup/index.js +16 -13
- package/es/column/index.d.ts +760 -0
- package/es/column/index.js +16 -13
- package/es/components.d.ts +9 -0
- package/es/components.js +29 -29
- package/es/grid/index.d.ts +2824 -0
- package/es/grid/index.js +14 -9
- package/es/grid/src/emits.d.ts +2 -0
- package/es/grid/src/emits.js +18 -15
- package/es/grid/src/grid.d.ts +556 -0
- package/es/grid/src/grid.js +1695 -1758
- package/es/grid/src/props.d.ts +200 -0
- package/es/grid/src/props.js +19 -6
- package/es/{vxe-grid/style.min.css → grid/style.mini.css} +1 -1
- package/es/index.d.ts +3 -0
- package/es/index.esm.js +6 -3
- package/es/index.js +6 -0
- package/es/locale/lang/ar-EG.d.ts +908 -2
- package/es/locale/lang/ar-EG.js +906 -903
- package/es/locale/lang/de-DE.d.ts +908 -2
- package/es/locale/lang/de-DE.js +906 -903
- package/es/locale/lang/en-US.d.ts +908 -2
- package/es/locale/lang/en-US.js +906 -903
- package/es/locale/lang/es-ES.d.ts +908 -2
- package/es/locale/lang/es-ES.js +906 -903
- package/es/locale/lang/fr-FR.d.ts +908 -2
- package/es/locale/lang/fr-FR.js +906 -903
- package/es/locale/lang/hu-HU.d.ts +908 -2
- package/es/locale/lang/hu-HU.js +906 -903
- package/es/locale/lang/hy-AM.d.ts +908 -2
- package/es/locale/lang/hy-AM.js +906 -903
- package/es/locale/lang/id-ID.d.ts +908 -2
- package/es/locale/lang/id-ID.js +906 -903
- package/es/locale/lang/it-IT.d.ts +908 -2
- package/es/locale/lang/it-IT.js +906 -903
- package/es/locale/lang/ja-JP.d.ts +908 -2
- package/es/locale/lang/ja-JP.js +906 -903
- package/es/locale/lang/ko-KR.d.ts +908 -2
- package/es/locale/lang/ko-KR.js +906 -903
- package/es/locale/lang/ms-MY.d.ts +908 -2
- package/es/locale/lang/ms-MY.js +906 -903
- package/es/locale/lang/nb-NO.d.ts +908 -2
- package/es/locale/lang/nb-NO.js +906 -903
- package/es/locale/lang/pt-BR.d.ts +908 -2
- package/es/locale/lang/pt-BR.js +906 -903
- package/es/locale/lang/ru-RU.d.ts +908 -2
- package/es/locale/lang/ru-RU.js +906 -903
- package/es/locale/lang/th-TH.d.ts +908 -2
- package/es/locale/lang/th-TH.js +906 -903
- package/es/locale/lang/ug-CN.d.ts +908 -2
- package/es/locale/lang/ug-CN.js +906 -903
- package/es/locale/lang/uk-UA.d.ts +908 -2
- package/es/locale/lang/uk-UA.js +906 -903
- package/es/locale/lang/uz-UZ.d.ts +908 -2
- package/es/locale/lang/uz-UZ.js +906 -903
- package/es/locale/lang/vi-VN.d.ts +908 -2
- package/es/locale/lang/vi-VN.js +906 -903
- package/es/locale/lang/zh-CHT.d.ts +908 -2
- package/es/locale/lang/zh-CHT.js +906 -903
- package/es/locale/lang/zh-CN.d.ts +908 -2
- package/es/locale/lang/zh-CN.js +906 -903
- package/es/locale/lang/zh-HK.d.ts +908 -2
- package/es/locale/lang/zh-HK.js +910 -2
- package/es/locale/lang/zh-MO.d.ts +908 -2
- package/es/locale/lang/zh-MO.js +910 -2
- package/es/locale/lang/zh-TC.d.ts +908 -0
- package/es/locale/lang/zh-TC.js +910 -2
- package/es/locale/lang/zh-TW.d.ts +908 -2
- package/es/locale/lang/zh-TW.js +910 -2
- package/es/table/index.d.ts +2672 -0
- package/es/table/index.js +16 -11
- package/es/table/module/custom/hook.d.ts +1 -0
- package/es/table/module/custom/hook.js +462 -483
- package/es/table/module/custom/panel.d.ts +17 -0
- package/es/table/module/custom/panel.js +1482 -1559
- package/es/table/module/edit/hook.d.ts +1 -0
- package/es/table/module/edit/hook.js +1008 -1078
- package/es/table/module/export/export-panel.d.ts +27 -0
- package/es/table/module/export/export-panel.js +523 -575
- package/es/table/module/export/hook.d.ts +1 -0
- package/es/table/module/export/hook.js +1805 -1884
- package/es/table/module/export/import-panel.d.ts +27 -0
- package/es/table/module/export/import-panel.js +244 -252
- package/es/table/module/export/util.d.ts +5 -0
- package/es/table/module/export/util.js +20 -17
- package/es/table/module/filter/hook.d.ts +1 -0
- package/es/table/module/filter/hook.js +472 -487
- package/es/table/module/filter/panel.d.ts +16 -0
- package/es/table/module/filter/panel.js +251 -275
- package/es/table/module/keyboard/hook.d.ts +1 -0
- package/es/table/module/keyboard/hook.js +445 -497
- package/es/table/module/menu/hook.d.ts +1 -0
- package/es/table/module/menu/hook.js +295 -315
- package/es/table/module/menu/panel.d.ts +2 -0
- package/es/table/module/menu/panel.js +164 -183
- package/es/table/module/validator/hook.d.ts +1 -0
- package/es/table/module/validator/hook.js +522 -571
- package/es/table/render/index.d.ts +1 -0
- package/es/table/render/index.js +1402 -1362
- package/es/table/src/body.d.ts +24 -0
- package/es/table/src/body.js +850 -865
- package/es/table/src/cell.d.ts +192 -0
- package/es/table/src/cell.js +1209 -1207
- package/es/table/src/column.d.ts +263 -0
- package/es/table/src/column.js +178 -174
- package/es/table/src/columnInfo.d.ts +13 -0
- package/es/table/src/columnInfo.js +202 -196
- package/es/table/src/emits.d.ts +2 -0
- package/es/table/src/emits.js +126 -119
- package/es/table/src/footer.d.ts +45 -0
- package/es/table/src/footer.js +336 -340
- package/es/table/src/group.d.ts +178 -0
- package/es/table/src/group.js +49 -46
- package/es/table/src/header.d.ts +26 -0
- package/es/table/src/header.js +517 -519
- package/es/table/src/props.d.ts +238 -0
- package/es/table/src/props.js +331 -328
- package/es/table/src/store.d.ts +6 -0
- package/es/table/src/store.js +9 -6
- package/es/table/src/table.d.ts +539 -0
- package/es/table/src/table.js +14061 -15071
- package/es/table/src/use/cell-view.d.ts +10 -0
- package/es/table/src/use/cell-view.js +36 -33
- package/es/table/src/use/index.d.ts +1 -0
- package/es/table/src/use/index.js +1 -1
- package/es/table/src/util.d.ts +74 -0
- package/es/table/src/util.js +1038 -1026
- package/es/table/style.css +1 -1
- package/es/table/style.mini.css +1 -0
- package/es/toolbar/index.d.ts +340 -0
- package/es/toolbar/index.js +14 -9
- package/es/toolbar/src/toolbar.d.ts +75 -0
- package/es/toolbar/src/toolbar.js +605 -613
- package/es/toolbar/{style.min.css → style.mini.css} +1 -1
- package/es/ui/index.d.ts +86 -0
- package/es/ui/index.js +457 -501
- package/es/ui/src/anime.d.ts +10 -0
- package/es/ui/src/anime.js +40 -40
- package/es/ui/src/comp.d.ts +2 -0
- package/es/ui/src/comp.js +5 -2
- package/es/ui/src/dom.d.ts +80 -0
- package/es/ui/src/dom.js +377 -380
- package/es/ui/src/log.d.ts +6 -0
- package/es/ui/src/log.js +18 -13
- package/es/ui/src/utils.d.ts +23 -0
- package/es/ui/src/utils.js +57 -53
- package/es/ui/src/vn.d.ts +7 -0
- package/es/ui/src/vn.js +49 -42
- package/es/v-x-e-table/index.d.ts +3 -0
- package/es/v-x-e-table/index.js +6 -3
- package/es/vxe-colgroup/index.d.ts +3 -0
- package/es/vxe-colgroup/index.js +6 -3
- package/es/vxe-column/index.d.ts +3 -0
- package/es/vxe-column/index.js +6 -3
- package/es/vxe-grid/index.d.ts +3 -0
- package/es/vxe-grid/index.js +6 -3
- package/{lib/grid/style/style.min.css → es/vxe-grid/style.mini.css} +1 -1
- package/es/vxe-table/index.d.ts +3 -0
- package/es/vxe-table/index.js +6 -3
- package/es/vxe-table/style.css +1 -1
- package/es/vxe-table/style.mini.css +1 -0
- package/es/vxe-toolbar/index.d.ts +3 -0
- package/es/vxe-toolbar/index.js +6 -3
- package/es/vxe-toolbar/{style.min.css → style.mini.css} +1 -1
- package/es/vxe-ui/index.d.ts +3 -0
- package/es/vxe-ui/index.js +6 -3
- package/lib/colgroup/index.js +44 -18
- package/lib/colgroup/style/index.js +1 -1
- package/lib/column/index.js +44 -18
- package/lib/column/style/index.js +1 -1
- package/lib/components.js +58 -92
- package/lib/grid/index.js +42 -14
- package/lib/grid/src/emits.js +37 -6
- package/lib/grid/src/grid.js +850 -1195
- package/lib/grid/src/props.js +27 -11
- package/lib/grid/style/index.js +1 -1
- package/lib/{vxe-grid/style/style.min.css → grid/style/style.mini.css} +1 -1
- package/lib/iconfont.1792977622800.ttf +0 -0
- package/lib/iconfont.1792977622800.woff +0 -0
- package/lib/iconfont.1792977622800.woff2 +0 -0
- package/lib/index.common.js +35 -19
- package/lib/index.js +37 -0
- package/lib/index.umd.js +30584 -24324
- package/lib/index.umd.min.js +3 -1
- package/lib/locale/ar-EG.umd.js +948 -0
- package/lib/locale/de-DE.umd.js +948 -0
- package/lib/locale/en-US.umd.js +948 -0
- package/lib/locale/es-ES.umd.js +948 -0
- package/lib/locale/fr-FR.umd.js +948 -0
- package/lib/locale/hu-HU.umd.js +948 -0
- package/lib/locale/hy-AM.umd.js +948 -0
- package/lib/locale/id-ID.umd.js +948 -0
- package/lib/locale/it-IT.umd.js +948 -0
- package/lib/locale/ja-JP.umd.js +948 -0
- package/lib/locale/ko-KR.umd.js +948 -0
- package/lib/locale/lang/ar-EG.js +681 -664
- package/lib/locale/lang/ar-EG.umd.js +913 -892
- package/lib/locale/lang/de-DE.js +681 -664
- package/lib/locale/lang/de-DE.umd.js +913 -892
- package/lib/locale/lang/en-US.js +678 -661
- package/lib/locale/lang/en-US.umd.js +913 -892
- package/lib/locale/lang/es-ES.js +681 -664
- package/lib/locale/lang/es-ES.umd.js +913 -892
- package/lib/locale/lang/fr-FR.js +654 -637
- package/lib/locale/lang/fr-FR.umd.js +913 -892
- package/lib/locale/lang/hu-HU.js +681 -664
- package/lib/locale/lang/hu-HU.umd.js +913 -892
- package/lib/locale/lang/hy-AM.js +681 -664
- package/lib/locale/lang/hy-AM.umd.js +913 -892
- package/lib/locale/lang/id-ID.js +681 -664
- package/lib/locale/lang/id-ID.umd.js +913 -892
- package/lib/locale/lang/it-IT.js +661 -644
- package/lib/locale/lang/it-IT.umd.js +912 -891
- package/lib/locale/lang/ja-JP.js +710 -693
- package/lib/locale/lang/ja-JP.umd.js +913 -892
- package/lib/locale/lang/ko-KR.js +681 -664
- package/lib/locale/lang/ko-KR.umd.js +913 -892
- package/lib/locale/lang/ms-MY.js +681 -664
- package/lib/locale/lang/ms-MY.umd.js +913 -892
- package/lib/locale/lang/nb-NO.js +681 -664
- package/lib/locale/lang/nb-NO.umd.js +913 -892
- package/lib/locale/lang/pt-BR.js +681 -664
- package/lib/locale/lang/pt-BR.umd.js +913 -892
- package/lib/locale/lang/ru-RU.js +690 -673
- package/lib/locale/lang/ru-RU.umd.js +913 -892
- package/lib/locale/lang/th-TH.js +681 -664
- package/lib/locale/lang/th-TH.umd.js +913 -892
- package/lib/locale/lang/ug-CN.js +681 -664
- package/lib/locale/lang/ug-CN.umd.js +913 -892
- package/lib/locale/lang/uk-UA.js +674 -657
- package/lib/locale/lang/uk-UA.umd.js +913 -892
- package/lib/locale/lang/uz-UZ.js +583 -566
- package/lib/locale/lang/uz-UZ.umd.js +908 -887
- package/lib/locale/lang/vi-VN.js +681 -664
- package/lib/locale/lang/vi-VN.umd.js +913 -892
- package/lib/locale/lang/zh-CHT.js +681 -664
- package/lib/locale/lang/zh-CHT.umd.js +913 -892
- package/lib/locale/lang/zh-CN.js +681 -664
- package/lib/locale/lang/zh-CN.umd.js +913 -892
- package/lib/locale/lang/zh-HK.js +928 -7
- package/lib/locale/lang/zh-HK.umd.js +945 -20
- package/lib/locale/lang/zh-MO.js +928 -7
- package/lib/locale/lang/zh-MO.umd.js +945 -20
- package/lib/locale/lang/zh-TC.js +928 -7
- package/lib/locale/lang/zh-TC.umd.js +948 -0
- package/lib/locale/lang/zh-TW.js +928 -7
- package/lib/locale/lang/zh-TW.umd.js +945 -20
- package/lib/locale/ms-MY.umd.js +948 -0
- package/lib/locale/nb-NO.umd.js +948 -0
- package/lib/locale/pt-BR.umd.js +948 -0
- package/lib/locale/ru-RU.umd.js +948 -0
- package/lib/locale/th-TH.umd.js +948 -0
- package/lib/locale/ug-CN.umd.js +948 -0
- package/lib/locale/uk-UA.umd.js +948 -0
- package/lib/locale/uz-UZ.umd.js +948 -0
- package/lib/locale/vi-VN.umd.js +948 -0
- package/lib/locale/zh-CHT.umd.js +948 -0
- package/lib/locale/zh-CN.umd.js +948 -0
- package/lib/locale/zh-HK.umd.js +948 -0
- package/lib/locale/zh-MO.umd.js +948 -0
- package/lib/locale/zh-TC.umd.js +948 -0
- package/lib/locale/zh-TW.umd.js +948 -0
- package/lib/style.css +4501 -1
- package/lib/style.mini.css +1 -0
- package/lib/table/index.js +45 -17
- package/lib/table/module/custom/hook.js +132 -252
- package/lib/table/module/custom/panel.js +919 -970
- package/lib/table/module/edit/hook.js +248 -618
- package/lib/table/module/export/export-panel.js +390 -347
- package/lib/table/module/export/hook.js +745 -1179
- package/lib/table/module/export/import-panel.js +170 -136
- package/lib/table/module/export/util.js +37 -14
- package/lib/table/module/filter/hook.js +127 -227
- package/lib/table/module/filter/panel.js +177 -208
- package/lib/table/module/keyboard/hook.js +93 -172
- package/lib/table/module/menu/hook.js +86 -165
- package/lib/table/module/menu/panel.js +176 -141
- package/lib/table/module/validator/hook.js +164 -271
- package/lib/table/render/index.js +700 -1147
- package/lib/table/src/body.js +426 -559
- package/lib/table/src/cell.js +619 -987
- package/lib/table/src/column.js +55 -30
- package/lib/table/src/columnInfo.js +88 -110
- package/lib/table/src/emits.js +145 -13
- package/lib/table/src/footer.js +181 -240
- package/lib/table/src/group.js +56 -34
- package/lib/table/src/header.js +292 -367
- package/lib/table/src/props.js +27 -12
- package/lib/table/src/store.js +25 -9
- package/lib/table/src/table.js +14179 -1023
- package/lib/table/src/use/cell-view.js +47 -37
- package/lib/table/src/use/index.js +17 -15
- package/lib/table/src/util.js +236 -337
- package/lib/table/style/index.js +1 -1
- package/lib/table/style/style.css +1 -1
- package/lib/table/style/style.mini.css +1 -0
- package/lib/toolbar/index.js +42 -14
- package/lib/toolbar/src/toolbar.js +271 -379
- package/lib/toolbar/style/index.js +1 -1
- package/lib/toolbar/style/{style.min.css → style.mini.css} +1 -1
- package/lib/ui/index.js +153 -195
- package/lib/ui/src/anime.js +49 -29
- package/lib/ui/src/comp.js +23 -6
- package/lib/ui/src/dom.js +114 -147
- package/lib/ui/src/log.js +34 -18
- package/lib/ui/src/utils.js +57 -45
- package/lib/ui/src/vn.js +60 -34
- package/lib/ui/style/index.js +1 -1
- package/lib/v-x-e-table/index.js +35 -19
- package/lib/vxe-colgroup/index.js +35 -19
- package/lib/vxe-colgroup/style/index.js +1 -1
- package/lib/vxe-column/index.js +35 -19
- package/lib/vxe-column/style/index.js +1 -1
- package/lib/vxe-grid/index.js +35 -19
- package/lib/vxe-grid/style/index.js +1 -1
- package/{es/grid/style.min.css → lib/vxe-grid/style/style.mini.css} +1 -1
- package/lib/vxe-table/index.js +35 -19
- package/lib/vxe-table/style/index.js +1 -1
- package/lib/vxe-table/style/style.css +1 -1
- package/lib/vxe-table/style/style.mini.css +1 -0
- package/lib/vxe-toolbar/index.js +35 -19
- package/lib/vxe-toolbar/style/index.js +1 -1
- package/lib/vxe-toolbar/style/{style.min.css → style.mini.css} +1 -1
- package/lib/vxe-ui/index.js +35 -19
- package/lib/vxe-ui/style/index.js +1 -1
- package/package.json +8 -4
- package/packages/locale/lang/zh-HK.ts +907 -3
- package/packages/locale/lang/zh-MO.ts +907 -3
- package/packages/locale/lang/zh-TC.ts +907 -3
- package/packages/locale/lang/zh-TW.ts +907 -3
- package/packages/ui/index.ts +1 -28
- package/dist/style.min.css +0 -1
- package/es/index.css +0 -1
- package/es/index.min.css +0 -1
- package/es/style.css +0 -1
- package/es/style.min.css +0 -1
- package/es/table/style.min.css +0 -1
- package/es/vxe-table/style.min.css +0 -1
- package/es/vxe-v-x-e-table/index.js +0 -3
- package/lib/colgroup/index.min.js +0 -1
- package/lib/column/index.min.js +0 -1
- package/lib/components.min.js +0 -1
- package/lib/grid/index.min.js +0 -1
- package/lib/grid/src/emits.min.js +0 -1
- package/lib/grid/src/grid.min.js +0 -1
- package/lib/grid/src/props.min.js +0 -1
- package/lib/index.css +0 -1
- package/lib/index.min.css +0 -1
- package/lib/locale/lang/ar-EG.d.ts +0 -2
- package/lib/locale/lang/ar-EG.min.js +0 -1
- package/lib/locale/lang/de-DE.d.ts +0 -2
- package/lib/locale/lang/de-DE.min.js +0 -1
- package/lib/locale/lang/en-US.d.ts +0 -2
- package/lib/locale/lang/en-US.min.js +0 -1
- package/lib/locale/lang/es-ES.d.ts +0 -2
- package/lib/locale/lang/es-ES.min.js +0 -1
- package/lib/locale/lang/fr-FR.d.ts +0 -2
- package/lib/locale/lang/fr-FR.min.js +0 -1
- package/lib/locale/lang/hu-HU.d.ts +0 -2
- package/lib/locale/lang/hu-HU.min.js +0 -1
- package/lib/locale/lang/hy-AM.d.ts +0 -2
- package/lib/locale/lang/hy-AM.min.js +0 -1
- package/lib/locale/lang/id-ID.d.ts +0 -2
- package/lib/locale/lang/id-ID.min.js +0 -1
- package/lib/locale/lang/it-IT.d.ts +0 -2
- package/lib/locale/lang/it-IT.min.js +0 -1
- package/lib/locale/lang/ja-JP.d.ts +0 -2
- package/lib/locale/lang/ja-JP.min.js +0 -1
- package/lib/locale/lang/ko-KR.d.ts +0 -2
- package/lib/locale/lang/ko-KR.min.js +0 -1
- package/lib/locale/lang/ms-MY.d.ts +0 -2
- package/lib/locale/lang/ms-MY.min.js +0 -1
- package/lib/locale/lang/nb-NO.d.ts +0 -2
- package/lib/locale/lang/nb-NO.min.js +0 -1
- package/lib/locale/lang/pt-BR.d.ts +0 -2
- package/lib/locale/lang/pt-BR.min.js +0 -1
- package/lib/locale/lang/ru-RU.d.ts +0 -2
- package/lib/locale/lang/ru-RU.min.js +0 -1
- package/lib/locale/lang/th-TH.d.ts +0 -2
- package/lib/locale/lang/th-TH.min.js +0 -1
- package/lib/locale/lang/ug-CN.d.ts +0 -2
- package/lib/locale/lang/ug-CN.min.js +0 -1
- package/lib/locale/lang/uk-UA.d.ts +0 -2
- package/lib/locale/lang/uk-UA.min.js +0 -1
- package/lib/locale/lang/uz-UZ.d.ts +0 -2
- package/lib/locale/lang/uz-UZ.min.js +0 -1
- package/lib/locale/lang/vi-VN.d.ts +0 -2
- package/lib/locale/lang/vi-VN.min.js +0 -1
- package/lib/locale/lang/zh-CHT.d.ts +0 -2
- package/lib/locale/lang/zh-CHT.min.js +0 -1
- package/lib/locale/lang/zh-CN.d.ts +0 -2
- package/lib/locale/lang/zh-CN.min.js +0 -1
- package/lib/locale/lang/zh-HK.d.ts +0 -2
- package/lib/locale/lang/zh-HK.min.js +0 -1
- package/lib/locale/lang/zh-MO.d.ts +0 -2
- package/lib/locale/lang/zh-MO.min.js +0 -1
- package/lib/locale/lang/zh-TC.min.js +0 -1
- package/lib/locale/lang/zh-TW.d.ts +0 -2
- package/lib/locale/lang/zh-TW.min.js +0 -1
- package/lib/style.min.css +0 -1
- package/lib/table/index.min.js +0 -1
- package/lib/table/module/custom/hook.min.js +0 -1
- package/lib/table/module/custom/panel.min.js +0 -1
- package/lib/table/module/edit/hook.min.js +0 -1
- package/lib/table/module/export/export-panel.min.js +0 -1
- package/lib/table/module/export/hook.min.js +0 -1
- package/lib/table/module/export/import-panel.min.js +0 -1
- package/lib/table/module/export/util.min.js +0 -1
- package/lib/table/module/filter/hook.min.js +0 -1
- package/lib/table/module/filter/panel.min.js +0 -1
- package/lib/table/module/keyboard/hook.min.js +0 -1
- package/lib/table/module/menu/hook.min.js +0 -1
- package/lib/table/module/menu/panel.min.js +0 -1
- package/lib/table/module/validator/hook.min.js +0 -1
- package/lib/table/render/index.min.js +0 -1
- package/lib/table/src/body.min.js +0 -1
- package/lib/table/src/cell.min.js +0 -1
- package/lib/table/src/column.min.js +0 -1
- package/lib/table/src/columnInfo.min.js +0 -1
- package/lib/table/src/emits.min.js +0 -1
- package/lib/table/src/footer.min.js +0 -1
- package/lib/table/src/group.min.js +0 -1
- package/lib/table/src/header.min.js +0 -1
- package/lib/table/src/props.min.js +0 -1
- package/lib/table/src/store.min.js +0 -1
- package/lib/table/src/table.min.js +0 -1
- package/lib/table/src/use/cell-view.min.js +0 -1
- package/lib/table/src/use/index.min.js +0 -1
- package/lib/table/src/util.min.js +0 -1
- package/lib/table/style/style.min.css +0 -1
- package/lib/toolbar/index.min.js +0 -1
- package/lib/toolbar/src/toolbar.min.js +0 -1
- package/lib/ui/index.min.js +0 -1
- package/lib/ui/src/anime.min.js +0 -1
- package/lib/ui/src/comp.min.js +0 -1
- package/lib/ui/src/dom.min.js +0 -1
- package/lib/ui/src/log.min.js +0 -1
- package/lib/ui/src/utils.min.js +0 -1
- package/lib/ui/src/vn.min.js +0 -1
- package/lib/ui/style/style.min.css +0 -0
- package/lib/v-x-e-table/index.min.js +0 -1
- package/lib/v-x-e-table/style/index.js +0 -1
- package/lib/v-x-e-table/style/style.css +0 -0
- package/lib/v-x-e-table/style/style.min.css +0 -0
- package/lib/vxe-colgroup/index.min.js +0 -1
- package/lib/vxe-colgroup/style/style.min.css +0 -0
- package/lib/vxe-column/index.min.js +0 -1
- package/lib/vxe-column/style/style.min.css +0 -0
- package/lib/vxe-grid/index.min.js +0 -1
- package/lib/vxe-table/index.min.js +0 -1
- package/lib/vxe-table/style/style.min.css +0 -1
- package/lib/vxe-toolbar/index.min.js +0 -1
- package/lib/vxe-ui/index.min.js +0 -1
- package/lib/vxe-ui/style/style.min.css +0 -0
- package/lib/vxe-v-x-e-table/index.js +0 -21
- package/lib/vxe-v-x-e-table/index.min.js +0 -1
- package/lib/vxe-v-x-e-table/style/index.js +0 -1
- package/lib/vxe-v-x-e-table/style/style.css +0 -0
- package/lib/vxe-v-x-e-table/style/style.min.css +0 -0
- /package/{es/iconfont.1792838769925.ttf → dist/iconfont.1792977622800.ttf} +0 -0
- /package/{es/iconfont.1792838769925.woff → dist/iconfont.1792977622800.woff} +0 -0
- /package/{es/iconfont.1792838769925.woff2 → dist/iconfont.1792977622800.woff2} +0 -0
- /package/es/colgroup/{style.min.css → style.mini.css} +0 -0
- /package/es/column/{style.min.css → style.mini.css} +0 -0
- /package/{lib/iconfont.1792838769925.ttf → es/iconfont.1792977622800.ttf} +0 -0
- /package/{lib/iconfont.1792838769925.woff → es/iconfont.1792977622800.woff} +0 -0
- /package/{lib/iconfont.1792838769925.woff2 → es/iconfont.1792977622800.woff2} +0 -0
- /package/es/ui/{style.min.css → style.mini.css} +0 -0
- /package/es/{v-x-e-table/style.css → vxe-colgroup/style.mini.css} +0 -0
- /package/es/{v-x-e-table/style.min.css → vxe-column/style.mini.css} +0 -0
- /package/es/{vxe-colgroup/style.min.css → vxe-ui/style.mini.css} +0 -0
- /package/{es/vxe-column/style.min.css → lib/colgroup/style/style.mini.css} +0 -0
- /package/{es/vxe-ui/style.min.css → lib/column/style/style.mini.css} +0 -0
- /package/{es/vxe-v-x-e-table/style.css → lib/ui/style/style.mini.css} +0 -0
- /package/{es/vxe-v-x-e-table/style.min.css → lib/vxe-colgroup/style/style.mini.css} +0 -0
- /package/lib/{colgroup/style/style.min.css → vxe-column/style/style.mini.css} +0 -0
- /package/lib/{column/style/style.min.css → vxe-ui/style/style.mini.css} +0 -0
|
@@ -1,26 +1,46 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty
|
|
4
|
-
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var import_panel_exports = {};
|
|
30
|
+
__export(import_panel_exports, {
|
|
31
|
+
default: () => import_panel_default
|
|
5
32
|
});
|
|
6
|
-
exports
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
const {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
const {
|
|
18
|
-
getI18n,
|
|
19
|
-
getIcon,
|
|
20
|
-
renderEmptyElement
|
|
21
|
-
} = _ui.VxeUI;
|
|
22
|
-
var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
23
|
-
name: 'VxeTableImportPanel',
|
|
33
|
+
module.exports = __toCommonJS(import_panel_exports);
|
|
34
|
+
var import_vue = require("vue");
|
|
35
|
+
var import_comp = require("../../../ui/src/comp");
|
|
36
|
+
var import_ui = require("../../../ui");
|
|
37
|
+
var import_xe_utils = __toESM(require("xe-utils"));
|
|
38
|
+
var import_utils = require("../../../ui/src/utils");
|
|
39
|
+
var import_log = require("../../../ui/src/log");
|
|
40
|
+
const { errLog } = (0, import_log.createComponentLog)("table");
|
|
41
|
+
const { getI18n, getIcon, renderEmptyElement } = import_ui.VxeUI;
|
|
42
|
+
var import_panel_default = (0, import_comp.defineVxeComponent)({
|
|
43
|
+
name: "VxeTableImportPanel",
|
|
24
44
|
props: {
|
|
25
45
|
defaultOptions: {
|
|
26
46
|
type: Object,
|
|
@@ -32,69 +52,50 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
32
52
|
}
|
|
33
53
|
},
|
|
34
54
|
setup(props) {
|
|
35
|
-
const VxeUIModalComponent =
|
|
36
|
-
const VxeUIButtonComponent =
|
|
37
|
-
const VxeUISelectComponent =
|
|
38
|
-
const $xeTable = (0,
|
|
39
|
-
const {
|
|
40
|
-
|
|
41
|
-
} = $xeTable.getComputeMaps();
|
|
42
|
-
const reactData = (0, _vue.reactive)({
|
|
55
|
+
const VxeUIModalComponent = import_ui.VxeUI.getComponent("VxeModal");
|
|
56
|
+
const VxeUIButtonComponent = import_ui.VxeUI.getComponent("VxeButton");
|
|
57
|
+
const VxeUISelectComponent = import_ui.VxeUI.getComponent("VxeSelect");
|
|
58
|
+
const $xeTable = (0, import_vue.inject)("$xeTable", {});
|
|
59
|
+
const { computeImportOpts } = $xeTable.getComputeMaps();
|
|
60
|
+
const reactData = (0, import_vue.reactive)({
|
|
43
61
|
loading: false
|
|
44
62
|
});
|
|
45
|
-
const refFileBtn = (0,
|
|
46
|
-
const computeSelectName = (0,
|
|
47
|
-
const {
|
|
48
|
-
storeData
|
|
49
|
-
} = props;
|
|
63
|
+
const refFileBtn = (0, import_vue.ref)();
|
|
64
|
+
const computeSelectName = (0, import_vue.computed)(() => {
|
|
65
|
+
const { storeData } = props;
|
|
50
66
|
return `${storeData.filename}.${storeData.type}`;
|
|
51
67
|
});
|
|
52
|
-
const computeHasFile = (0,
|
|
53
|
-
const {
|
|
54
|
-
storeData
|
|
55
|
-
} = props;
|
|
68
|
+
const computeHasFile = (0, import_vue.computed)(() => {
|
|
69
|
+
const { storeData } = props;
|
|
56
70
|
return storeData.file && storeData.type;
|
|
57
71
|
});
|
|
58
|
-
const computeParseTypeLabel = (0,
|
|
59
|
-
const {
|
|
60
|
-
|
|
61
|
-
} = props;
|
|
62
|
-
const {
|
|
63
|
-
type,
|
|
64
|
-
typeList
|
|
65
|
-
} = storeData;
|
|
72
|
+
const computeParseTypeLabel = (0, import_vue.computed)(() => {
|
|
73
|
+
const { storeData } = props;
|
|
74
|
+
const { type, typeList } = storeData;
|
|
66
75
|
if (type) {
|
|
67
|
-
const selectItem =
|
|
68
|
-
return `${selectItem ? selectItem.label :
|
|
76
|
+
const selectItem = import_xe_utils.default.find(typeList, (item) => type === item.value);
|
|
77
|
+
return `${selectItem ? selectItem.label : "*.*"}`;
|
|
69
78
|
}
|
|
70
|
-
return `*.${typeList.map(item => item.value).join(
|
|
79
|
+
return `*.${typeList.map((item) => item.value).join(", *.")}`;
|
|
71
80
|
});
|
|
72
81
|
const clearFileEvent = () => {
|
|
73
|
-
const {
|
|
74
|
-
storeData
|
|
75
|
-
} = props;
|
|
82
|
+
const { storeData } = props;
|
|
76
83
|
Object.assign(storeData, {
|
|
77
|
-
filename:
|
|
78
|
-
sheetName:
|
|
79
|
-
type:
|
|
84
|
+
filename: "",
|
|
85
|
+
sheetName: "",
|
|
86
|
+
type: ""
|
|
80
87
|
});
|
|
81
88
|
};
|
|
82
89
|
const selectFileEvent = () => {
|
|
83
|
-
const {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
file
|
|
90
|
-
} = params;
|
|
91
|
-
Object.assign(storeData, (0, _utils.parseFile)(file), {
|
|
92
|
-
file
|
|
93
|
-
});
|
|
94
|
-
}).catch(() => {});
|
|
90
|
+
const { storeData, defaultOptions } = props;
|
|
91
|
+
$xeTable.readFile(defaultOptions).then((params) => {
|
|
92
|
+
const { file } = params;
|
|
93
|
+
Object.assign(storeData, (0, import_utils.parseFile)(file), { file });
|
|
94
|
+
}).catch(() => {
|
|
95
|
+
});
|
|
95
96
|
};
|
|
96
97
|
const showEvent = () => {
|
|
97
|
-
(0,
|
|
98
|
+
(0, import_vue.nextTick)(() => {
|
|
98
99
|
const targetElem = refFileBtn.value;
|
|
99
100
|
if (targetElem) {
|
|
100
101
|
targetElem.focus();
|
|
@@ -102,16 +103,11 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
102
103
|
});
|
|
103
104
|
};
|
|
104
105
|
const cancelEvent = () => {
|
|
105
|
-
const {
|
|
106
|
-
storeData
|
|
107
|
-
} = props;
|
|
106
|
+
const { storeData } = props;
|
|
108
107
|
storeData.visible = false;
|
|
109
108
|
};
|
|
110
109
|
const importEvent = () => {
|
|
111
|
-
const {
|
|
112
|
-
storeData,
|
|
113
|
-
defaultOptions
|
|
114
|
-
} = props;
|
|
110
|
+
const { storeData, defaultOptions } = props;
|
|
115
111
|
const importOpts = computeImportOpts.value;
|
|
116
112
|
reactData.loading = true;
|
|
117
113
|
$xeTable.importByFile(storeData.file, Object.assign({}, importOpts, defaultOptions)).then(() => {
|
|
@@ -124,10 +120,7 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
124
120
|
const renderVN = () => {
|
|
125
121
|
const $xeGrid = $xeTable.xeGrid;
|
|
126
122
|
const $xeGantt = $xeTable.xeGantt;
|
|
127
|
-
const {
|
|
128
|
-
defaultOptions,
|
|
129
|
-
storeData
|
|
130
|
-
} = props;
|
|
123
|
+
const { defaultOptions, storeData } = props;
|
|
131
124
|
const selectName = computeSelectName.value;
|
|
132
125
|
const hasFile = computeHasFile.value;
|
|
133
126
|
const importOpts = computeImportOpts.value;
|
|
@@ -139,17 +132,17 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
139
132
|
const bottomSlot = slots.bottom;
|
|
140
133
|
const defaultSlot = slots.default;
|
|
141
134
|
const footerSlot = slots.footer;
|
|
142
|
-
return VxeUIModalComponent ? (0,
|
|
143
|
-
id:
|
|
135
|
+
return VxeUIModalComponent ? (0, import_vue.h)(VxeUIModalComponent, {
|
|
136
|
+
id: "VXE_IMPORT_MODAL",
|
|
144
137
|
modelValue: storeData.visible,
|
|
145
|
-
title: modelOptions.title || getI18n(
|
|
146
|
-
className:
|
|
138
|
+
title: modelOptions.title || getI18n("vxe.import.impTitle"),
|
|
139
|
+
className: "vxe-table-export-popup-wrapper",
|
|
147
140
|
width: modelOptions.width || 540,
|
|
148
141
|
height: modelOptions.height,
|
|
149
142
|
minWidth: modelOptions.minWidth || 360,
|
|
150
143
|
minHeight: modelOptions.minHeight || 240,
|
|
151
|
-
mask: (0,
|
|
152
|
-
lockView: (0,
|
|
144
|
+
mask: (0, import_utils.getDefaultConfig)(modelOptions.mask, true),
|
|
145
|
+
lockView: (0, import_utils.getDefaultConfig)(modelOptions.lockView, true),
|
|
153
146
|
showFooter: true,
|
|
154
147
|
escClosable: true,
|
|
155
148
|
maskClosable: true,
|
|
@@ -157,10 +150,10 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
157
150
|
fullscreen: modelOptions.fullscreen,
|
|
158
151
|
remember: modelOptions.remember,
|
|
159
152
|
showMinimize: modelOptions.showMinimize,
|
|
160
|
-
showMaximize: (0,
|
|
161
|
-
resize: (0,
|
|
153
|
+
showMaximize: (0, import_utils.getDefaultConfig)(modelOptions.showMaximize, true),
|
|
154
|
+
resize: (0, import_utils.getDefaultConfig)(modelOptions.resize, true),
|
|
162
155
|
loading: reactData.loading,
|
|
163
|
-
|
|
156
|
+
"onUpdate:modelValue"(value) {
|
|
164
157
|
storeData.visible = value;
|
|
165
158
|
},
|
|
166
159
|
onShow: showEvent
|
|
@@ -173,36 +166,68 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
173
166
|
options: defaultOptions,
|
|
174
167
|
params: defaultOptions.params
|
|
175
168
|
};
|
|
176
|
-
return (0,
|
|
177
|
-
class:
|
|
178
|
-
}, [
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
169
|
+
return (0, import_vue.h)("div", {
|
|
170
|
+
class: "vxe-table-export--panel"
|
|
171
|
+
}, [
|
|
172
|
+
topSlot ? (0, import_vue.h)("div", {
|
|
173
|
+
class: "vxe-table-export--panel-top"
|
|
174
|
+
}, $xeTable.callSlot(topSlot, params)) : renderEmptyElement($xeTable),
|
|
175
|
+
(0, import_vue.h)(
|
|
176
|
+
"div",
|
|
177
|
+
{
|
|
178
|
+
class: "vxe-table-export--panel-body"
|
|
179
|
+
},
|
|
180
|
+
defaultSlot ? $xeTable.callSlot(defaultSlot, params) : [
|
|
181
|
+
(0, import_vue.h)("table", {
|
|
182
|
+
class: "vxe-table-export--panel-table",
|
|
183
|
+
cellspacing: 0,
|
|
184
|
+
cellpadding: 0,
|
|
185
|
+
border: 0
|
|
186
|
+
}, [
|
|
187
|
+
(0, import_vue.h)("tbody", [
|
|
188
|
+
(0, import_vue.h)("tr", [
|
|
189
|
+
(0, import_vue.h)("td", getI18n("vxe.import.impFile")),
|
|
190
|
+
(0, import_vue.h)("td", [
|
|
191
|
+
hasFile ? (0, import_vue.h)("div", {
|
|
192
|
+
class: "vxe-table-export--selected--file",
|
|
193
|
+
title: selectName
|
|
194
|
+
}, [
|
|
195
|
+
(0, import_vue.h)("span", selectName),
|
|
196
|
+
(0, import_vue.h)("i", {
|
|
197
|
+
class: getIcon().INPUT_CLEAR,
|
|
198
|
+
onClick: clearFileEvent
|
|
199
|
+
})
|
|
200
|
+
]) : (0, import_vue.h)("button", {
|
|
201
|
+
ref: refFileBtn,
|
|
202
|
+
class: "vxe-table-export--select--file",
|
|
203
|
+
onClick: selectFileEvent
|
|
204
|
+
}, getI18n("vxe.import.impSelect"))
|
|
205
|
+
])
|
|
206
|
+
]),
|
|
207
|
+
(0, import_vue.h)("tr", [
|
|
208
|
+
(0, import_vue.h)("td", getI18n("vxe.import.impType")),
|
|
209
|
+
(0, import_vue.h)("td", parseTypeLabel)
|
|
210
|
+
]),
|
|
211
|
+
settingOptions.showMode === false ? renderEmptyElement($xeTable) : (0, import_vue.h)("tr", [
|
|
212
|
+
(0, import_vue.h)("td", getI18n("vxe.import.impMode")),
|
|
213
|
+
(0, import_vue.h)("td", [
|
|
214
|
+
VxeUISelectComponent ? (0, import_vue.h)(VxeUISelectComponent, {
|
|
215
|
+
modelValue: defaultOptions.mode,
|
|
216
|
+
options: storeData.modeList,
|
|
217
|
+
"onUpdate:modelValue"(value) {
|
|
218
|
+
defaultOptions.mode = value;
|
|
219
|
+
}
|
|
220
|
+
}) : renderEmptyElement($xeTable)
|
|
221
|
+
])
|
|
222
|
+
])
|
|
223
|
+
])
|
|
224
|
+
])
|
|
225
|
+
]
|
|
226
|
+
),
|
|
227
|
+
bottomSlot ? (0, import_vue.h)("div", {
|
|
228
|
+
class: "vxe-table-export--panel-bottom"
|
|
229
|
+
}, $xeTable.callSlot(bottomSlot, params)) : renderEmptyElement($xeTable)
|
|
230
|
+
]);
|
|
206
231
|
},
|
|
207
232
|
footer() {
|
|
208
233
|
const params = {
|
|
@@ -212,33 +237,42 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
|
|
|
212
237
|
options: defaultOptions,
|
|
213
238
|
params: defaultOptions.params
|
|
214
239
|
};
|
|
215
|
-
return (0,
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
240
|
+
return (0, import_vue.h)(
|
|
241
|
+
"div",
|
|
242
|
+
{
|
|
243
|
+
class: "vxe-table-export--panel-footer"
|
|
244
|
+
},
|
|
245
|
+
footerSlot ? $xeTable.callSlot(footerSlot, params) : [
|
|
246
|
+
(0, import_vue.h)("div", {
|
|
247
|
+
class: "vxe-table-export--panel-btns"
|
|
248
|
+
}, [
|
|
249
|
+
VxeUIButtonComponent ? (0, import_vue.h)(VxeUIButtonComponent, {
|
|
250
|
+
content: getI18n("vxe.import.impCancel"),
|
|
251
|
+
onClick: cancelEvent
|
|
252
|
+
}) : renderEmptyElement($xeTable),
|
|
253
|
+
VxeUIButtonComponent ? (0, import_vue.h)(VxeUIButtonComponent, {
|
|
254
|
+
status: "primary",
|
|
255
|
+
disabled: !hasFile || reactData.loading,
|
|
256
|
+
content: getI18n("vxe.import.impConfirm"),
|
|
257
|
+
onClick: importEvent
|
|
258
|
+
}) : renderEmptyElement($xeTable)
|
|
259
|
+
])
|
|
260
|
+
]
|
|
261
|
+
);
|
|
228
262
|
}
|
|
229
263
|
}) : renderEmptyElement($xeTable);
|
|
230
264
|
};
|
|
231
|
-
(0,
|
|
265
|
+
(0, import_vue.nextTick)(() => {
|
|
232
266
|
if (!VxeUIModalComponent) {
|
|
233
|
-
errLog(
|
|
267
|
+
errLog("vxe.error.reqComp", ["vxe-modal"]);
|
|
234
268
|
}
|
|
235
269
|
if (!VxeUIButtonComponent) {
|
|
236
|
-
errLog(
|
|
270
|
+
errLog("vxe.error.reqComp", ["vxe-button"]);
|
|
237
271
|
}
|
|
238
272
|
if (!VxeUISelectComponent) {
|
|
239
|
-
errLog(
|
|
273
|
+
errLog("vxe.error.reqComp", ["vxe-select"]);
|
|
240
274
|
}
|
|
241
275
|
});
|
|
242
276
|
return renderVN;
|
|
243
277
|
}
|
|
244
|
-
});
|
|
278
|
+
});
|
|
@@ -1,20 +1,43 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var util_exports = {};
|
|
20
|
+
__export(util_exports, {
|
|
21
|
+
createHtmlPage: () => createHtmlPage,
|
|
22
|
+
getExportBlobByContent: () => getExportBlobByContent
|
|
5
23
|
});
|
|
6
|
-
exports
|
|
7
|
-
exports.getExportBlobByContent = getExportBlobByContent;
|
|
8
|
-
// 默认导出或打印的 HTML 样式
|
|
24
|
+
module.exports = __toCommonJS(util_exports);
|
|
9
25
|
const defaultHtmlStyle = 'body{padding:0;color:rgba(0,0,0,0.7);font-family:"Microsoft YaHei",微软雅黑,"MicrosoftJhengHei",华文细黑,STHeiti,MingLiu}body *{-webkit-box-sizing:border-box;box-sizing:border-box}.vxe-table{border-collapse:collapse;text-align:left;border-spacing:0}.vxe-table.is--default-width,.vxe-table.is--auto-width{width:100%}.vxe-table.is--scale-width{table-layout:fixed}.vxe-table,.vxe-table th,.vxe-table td,.vxe-table td{white-space:pre-line;word-break:break-all;border-color:#D0D0D0;border-style:solid;border-width:0}.border--default,.border--full,.border--outer{border-top-width:1px}.border--default,.border--full,.border--outer{border-left-width:1px}.border--outer,.border--default th,.border--default td,.border--full th,.border--full td,.border--outer th,.border--inner th,.border--inner td{border-bottom-width:1px}.border--default,.border--outer,.border--full th,.border--full td{border-right-width:1px}.border--default th,.border--full th,.border--outer th{background-color:#f8f8f9}.vxe-table td>div,.vxe-table th>div{padding:0.5em 0.4em}.col--center{text-align:center}.col--right{text-align:right}.vxe-table .col--ellipsis>div{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;word-break:break-all}.vxe-table--tree-node{text-align:left}.vxe-table--tree-node-wrapper{position:relative}.vxe-table--tree-icon-wrapper{position:absolute;top:50%;width:1em;height:1em;text-align:center;-webkit-transform:translateY(-50%);transform:translateY(-50%);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer}.vxe-table--tree-unfold-icon,.vxe-table--tree-fold-icon{position:absolute;width:0;height:0;border-style:solid;border-width:0.5em;border-right-color:transparent;border-bottom-color:transparent}.vxe-table--tree-unfold-icon{left:.3em;top:0;border-left-color:#939599;border-top-color:transparent}.vxe-table--tree-fold-icon{left:0;top:.3em;border-left-color:transparent;border-top-color:#939599}.vxe-table--tree-cell{display:block;padding-left:1.5em}.vxe-table input[type="checkbox"]{margin:0}.vxe-table input[type="checkbox"],.vxe-table input[type="radio"],.vxe-table input[type="checkbox"]+span,.vxe-table input[type="radio"]+span{vertical-align:middle;padding-left:0.4em}';
|
|
10
26
|
function getExportBlobByContent(content, options) {
|
|
11
|
-
return new Blob([content], {
|
|
12
|
-
type: `text/${options.type};charset=utf-8;`
|
|
13
|
-
});
|
|
27
|
+
return new Blob([content], { type: `text/${options.type};charset=utf-8;` });
|
|
14
28
|
}
|
|
15
29
|
function createHtmlPage(opts, content) {
|
|
16
|
-
const {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
30
|
+
const { style } = opts;
|
|
31
|
+
return [
|
|
32
|
+
"<!DOCTYPE html><html>",
|
|
33
|
+
"<head>",
|
|
34
|
+
'<meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no,minimal-ui">',
|
|
35
|
+
`<title>${opts.sheetName}</title>`,
|
|
36
|
+
'<style media="print">.vxe-page-break-before{page-break-before:always;}.vxe-page-break-after{page-break-after:always;}</style>',
|
|
37
|
+
`<style>${defaultHtmlStyle}</style>`,
|
|
38
|
+
style ? `<style>${style}</style>` : "",
|
|
39
|
+
"</head>",
|
|
40
|
+
`<body>${content}</body>`,
|
|
41
|
+
"</html>"
|
|
42
|
+
].join("");
|
|
43
|
+
}
|