@smallwei/avue 3.9.1 → 3.9.3
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/README.md +2 -2
- package/dist/avue.js +32058 -27369
- package/dist/avue.js.map +1 -1
- package/dist/avue.min.js +2 -2
- package/dist/index.css +1 -1
- package/es/_virtual/_commonjs-dynamic-modules.mjs +6 -6
- package/es/_virtual/_commonjsHelpers.mjs +6 -6
- package/es/_virtual/axios.mjs +8 -8
- package/es/_virtual/axios2.mjs +4 -4
- package/es/_virtual/countUp.min.mjs +28 -28
- package/es/_virtual/countUp.min2.mjs +4 -4
- package/es/_virtual/dayjs.min.mjs +8 -8
- package/es/_virtual/dayjs.min2.mjs +4 -4
- package/es/index.css +1 -1
- package/es/locale/browser/en.mjs +299 -288
- package/es/locale/browser/zh-cn.mjs +299 -288
- package/es/locale/browser/zh.mjs +299 -288
- package/es/node_modules/.pnpm/countup.js@1.9.3/node_modules/countup.js/dist/countUp.min.mjs +1 -1
- package/es/node_modules/.pnpm/dayjs@1.11.13/node_modules/dayjs/dayjs.min.mjs +1 -1
- package/es/node_modules/.pnpm/qrcode-generator@2.0.4/node_modules/qrcode-generator/dist/qrcode.mjs +2235 -0
- package/es/node_modules/axios/dist/axios.mjs +1 -1
- package/es/packages/core/common/event.mjs +62 -62
- package/es/packages/core/common/init.mjs +222 -138
- package/es/packages/core/common/props.mjs +243 -243
- package/es/packages/core/components/dialog-form/index.mjs +8 -8
- package/es/packages/core/components/dialog-form/index2.mjs +34 -34
- package/es/packages/core/components/dialog-form/index3.mjs +6 -6
- package/es/packages/core/components/dialog-form/index4.mjs +67 -67
- package/es/packages/core/components/form/custom.mjs +44 -44
- package/es/packages/core/components/form/index.mjs +8 -8
- package/es/packages/core/components/form/index2.mjs +8 -8
- package/es/packages/core/components/form/index3.mjs +91 -91
- package/es/packages/core/components/icon/index.mjs +8 -8
- package/es/packages/core/components/icon/index2.mjs +25 -4
- package/es/packages/core/components/icon/index3.mjs +43 -41
- package/es/packages/core/components/image-preview/index.mjs +8 -8
- package/es/packages/core/components/image-preview/index2.mjs +39 -39
- package/es/packages/core/components/image-preview/index3.mjs +8 -8
- package/es/packages/core/components/image-preview/index4.mjs +160 -160
- package/es/packages/core/directive/contextmenu.mjs +95 -95
- package/es/packages/core/directive/permission.mjs +22 -22
- package/es/packages/data/box/index.mjs +8 -8
- package/es/packages/data/box/index2.mjs +6 -6
- package/es/packages/data/box/index3.mjs +66 -66
- package/es/packages/data/card/index.mjs +8 -8
- package/es/packages/data/card/index2.mjs +6 -6
- package/es/packages/data/card/index3.mjs +57 -57
- package/es/packages/data/cardText/index.mjs +8 -8
- package/es/packages/data/cardText/index2.mjs +6 -6
- package/es/packages/data/cardText/index3.mjs +50 -50
- package/es/packages/data/countdown/index.mjs +8 -8
- package/es/packages/data/countdown/index2.mjs +7 -7
- package/es/packages/data/countdown/index3.mjs +95 -95
- package/es/packages/data/dashboard/index.mjs +8 -8
- package/es/packages/data/dashboard/index2.mjs +6 -6
- package/es/packages/data/dashboard/index3.mjs +100 -100
- package/es/packages/data/display/index.mjs +8 -8
- package/es/packages/data/display/index2.mjs +6 -6
- package/es/packages/data/display/index3.mjs +56 -56
- package/es/packages/data/icons/index.mjs +8 -8
- package/es/packages/data/icons/index2.mjs +6 -6
- package/es/packages/data/icons/index3.mjs +66 -66
- package/es/packages/data/imgText/index.mjs +8 -8
- package/es/packages/data/imgText/index2.mjs +6 -6
- package/es/packages/data/imgText/index3.mjs +87 -87
- package/es/packages/data/list/index.mjs +8 -8
- package/es/packages/data/list/index2.mjs +11 -6
- package/es/packages/data/list/index3.mjs +137 -134
- package/es/packages/data/notice/index.mjs +8 -8
- package/es/packages/data/notice/index2.mjs +7 -7
- package/es/packages/data/notice/index3.mjs +59 -59
- package/es/packages/data/operaText/index.mjs +8 -8
- package/es/packages/data/operaText/index2.mjs +6 -6
- package/es/packages/data/operaText/index3.mjs +74 -74
- package/es/packages/data/panel/index.mjs +8 -8
- package/es/packages/data/panel/index2.mjs +6 -6
- package/es/packages/data/panel/index3.mjs +64 -64
- package/es/packages/data/pay/index.mjs +8 -8
- package/es/packages/data/pay/index2.mjs +6 -6
- package/es/packages/data/pay/index3.mjs +128 -128
- package/es/packages/data/price/index.mjs +8 -8
- package/es/packages/data/price/index2.mjs +6 -6
- package/es/packages/data/price/index3.mjs +56 -56
- package/es/packages/data/product/index.mjs +8 -8
- package/es/packages/data/product/index2.mjs +7 -7
- package/es/packages/data/product/index3.mjs +158 -158
- package/es/packages/data/profile/index.mjs +8 -8
- package/es/packages/data/profile/index2.mjs +6 -6
- package/es/packages/data/profile/index3.mjs +166 -166
- package/es/packages/data/progress/index.mjs +8 -8
- package/es/packages/data/progress/index2.mjs +6 -6
- package/es/packages/data/progress/index3.mjs +63 -63
- package/es/packages/data/rank/index.mjs +8 -8
- package/es/packages/data/rank/index2.mjs +6 -6
- package/es/packages/data/rank/index3.mjs +99 -99
- package/es/packages/data/rotate/index.mjs +8 -8
- package/es/packages/data/rotate/index2.mjs +7 -7
- package/es/packages/data/rotate/index3.mjs +75 -75
- package/es/packages/data/statistic/index.mjs +8 -8
- package/es/packages/data/statistic/index2.mjs +20 -6
- package/es/packages/data/statistic/index3.mjs +103 -100
- package/es/packages/data/tabs/index.mjs +8 -8
- package/es/packages/data/tabs/index2.mjs +6 -6
- package/es/packages/data/tabs/index3.mjs +65 -65
- package/es/packages/data/task/index.mjs +8 -8
- package/es/packages/data/task/index2.mjs +7 -7
- package/es/packages/data/task/index3.mjs +82 -82
- package/es/packages/data/weather/index.mjs +8 -8
- package/es/packages/data/weather/index2.mjs +12 -7
- package/es/packages/data/weather/index3.mjs +81 -80
- package/es/packages/element-plus/array/index.mjs +8 -8
- package/es/packages/element-plus/array/index2.mjs +9 -9
- package/es/packages/element-plus/array/index3.mjs +102 -102
- package/es/packages/element-plus/article/index.mjs +8 -8
- package/es/packages/element-plus/article/index2.mjs +6 -6
- package/es/packages/element-plus/article/index3.mjs +48 -48
- package/es/packages/element-plus/card/index.mjs +8 -8
- package/es/packages/element-plus/card/index2.mjs +7 -7
- package/es/packages/element-plus/card/index3.mjs +94 -94
- package/es/packages/element-plus/cascader/index.mjs +8 -8
- package/es/packages/element-plus/cascader/index2.mjs +18 -8
- package/es/packages/element-plus/cascader/index3.mjs +51 -47
- package/es/packages/element-plus/chat/index.mjs +8 -8
- package/es/packages/element-plus/chat/index2.mjs +8 -8
- package/es/packages/element-plus/chat/index3.mjs +392 -392
- package/es/packages/element-plus/checkbox/index.mjs +8 -8
- package/es/packages/element-plus/checkbox/index2.mjs +9 -9
- package/es/packages/element-plus/checkbox/index3.mjs +61 -61
- package/es/packages/element-plus/comment/index.mjs +8 -8
- package/es/packages/element-plus/comment/index2.mjs +6 -6
- package/es/packages/element-plus/comment/index3.mjs +43 -43
- package/es/packages/element-plus/count-up/index.mjs +8 -8
- package/es/packages/element-plus/count-up/index2.mjs +16 -16
- package/es/packages/element-plus/count-up/index3.mjs +8 -8
- package/es/packages/element-plus/crud/column/column-default.mjs +8 -8
- package/es/packages/element-plus/crud/column/column-default2.mjs +10 -10
- package/es/packages/element-plus/crud/column/column-default3.mjs +62 -62
- package/es/packages/element-plus/crud/column/column-dynamic.mjs +8 -8
- package/es/packages/element-plus/crud/column/column-dynamic2.mjs +9 -9
- package/es/packages/element-plus/crud/column/column-dynamic3.mjs +75 -75
- package/es/packages/element-plus/crud/column/column-menu.mjs +8 -8
- package/es/packages/element-plus/crud/column/column-menu2.mjs +11 -11
- package/es/packages/element-plus/crud/column/column-menu3.mjs +304 -304
- package/es/packages/element-plus/crud/column/column-slot.mjs +8 -8
- package/es/packages/element-plus/crud/column/column-slot2.mjs +18 -18
- package/es/packages/element-plus/crud/column/column-slot3.mjs +207 -207
- package/es/packages/element-plus/crud/column/column.mjs +8 -8
- package/es/packages/element-plus/crud/column/column2.mjs +12 -12
- package/es/packages/element-plus/crud/column/column3.mjs +49 -49
- package/es/packages/element-plus/crud/column/menu.mjs +8 -8
- package/es/packages/element-plus/crud/column/menu2.mjs +7 -7
- package/es/packages/element-plus/crud/column/menu3.mjs +57 -57
- package/es/packages/element-plus/crud/config.mjs +77 -77
- package/es/packages/element-plus/crud/dialog/dialog-column.mjs +8 -8
- package/es/packages/element-plus/crud/dialog/dialog-column2.mjs +125 -46
- package/es/packages/element-plus/crud/dialog/dialog-column3.mjs +172 -71
- package/es/packages/element-plus/crud/dialog/dialog-excel.mjs +8 -8
- package/es/packages/element-plus/crud/dialog/dialog-excel2.mjs +9 -9
- package/es/packages/element-plus/crud/dialog/dialog-excel3.mjs +59 -59
- package/es/packages/element-plus/crud/dialog/dialog-filter.mjs +8 -8
- package/es/packages/element-plus/crud/dialog/dialog-filter2.mjs +7 -7
- package/es/packages/element-plus/crud/dialog/dialog-filter3.mjs +146 -146
- package/es/packages/element-plus/crud/dialog/dialog-form.mjs +8 -8
- package/es/packages/element-plus/crud/dialog/dialog-form2.mjs +9 -9
- package/es/packages/element-plus/crud/dialog/dialog-form3.mjs +137 -137
- package/es/packages/element-plus/crud/grid/index.mjs +8 -8
- package/es/packages/element-plus/crud/grid/index2.mjs +7 -7
- package/es/packages/element-plus/crud/grid/index3.mjs +117 -117
- package/es/packages/element-plus/crud/grid/item.mjs +8 -8
- package/es/packages/element-plus/crud/grid/item2.mjs +4 -4
- package/es/packages/element-plus/crud/grid/item3.mjs +6 -6
- package/es/packages/element-plus/crud/index.mjs +8 -8
- package/es/packages/element-plus/crud/index2.mjs +124 -57
- package/es/packages/element-plus/crud/index3.mjs +312 -281
- package/es/packages/element-plus/crud/menu/header-menu.mjs +8 -8
- package/es/packages/element-plus/crud/menu/header-menu2.mjs +27 -15
- package/es/packages/element-plus/crud/menu/header-menu3.mjs +231 -171
- package/es/packages/element-plus/crud/menu/header-search.mjs +8 -8
- package/es/packages/element-plus/crud/menu/header-search2.mjs +12 -11
- package/es/packages/element-plus/crud/menu/header-search3.mjs +81 -81
- package/es/packages/element-plus/crud/menu/table-page.mjs +8 -8
- package/es/packages/element-plus/crud/menu/table-page2.mjs +7 -7
- package/es/packages/element-plus/crud/menu/table-page3.mjs +40 -40
- package/es/packages/element-plus/date/index.mjs +8 -8
- package/es/packages/element-plus/date/index2.mjs +13 -9
- package/es/packages/element-plus/date/index3.mjs +63 -62
- package/es/packages/element-plus/draggable/index.mjs +8 -8
- package/es/packages/element-plus/draggable/index2.mjs +55 -27
- package/es/packages/element-plus/draggable/index3.mjs +83 -83
- package/es/packages/element-plus/dynamic/index.mjs +8 -8
- package/es/packages/element-plus/dynamic/index2.mjs +9 -9
- package/es/packages/element-plus/dynamic/index3.mjs +135 -135
- package/es/packages/element-plus/flow/index.mjs +8 -8
- package/es/packages/element-plus/flow/index2.mjs +10 -10
- package/es/packages/element-plus/flow/index3.mjs +45 -45
- package/es/packages/element-plus/flow/node.mjs +8 -8
- package/es/packages/element-plus/flow/node2.mjs +6 -6
- package/es/packages/element-plus/flow/node3.mjs +47 -47
- package/es/packages/element-plus/form/config.mjs +9 -9
- package/es/packages/element-plus/form/index.mjs +8 -8
- package/es/packages/element-plus/form/index2.mjs +25 -22
- package/es/packages/element-plus/form/index3.mjs +325 -312
- package/es/packages/element-plus/form/menu.mjs +8 -8
- package/es/packages/element-plus/form/menu2.mjs +7 -7
- package/es/packages/element-plus/form/menu3.mjs +91 -91
- package/es/packages/element-plus/group/index.mjs +8 -8
- package/es/packages/element-plus/group/index2.mjs +11 -6
- package/es/packages/element-plus/group/index3.mjs +76 -73
- package/es/packages/element-plus/iframe/index.mjs +8 -0
- package/es/packages/element-plus/iframe/index2.mjs +190 -0
- package/es/packages/element-plus/iframe/index3.mjs +64 -0
- package/es/packages/element-plus/input/index.mjs +8 -8
- package/es/packages/element-plus/input/index2.mjs +9 -9
- package/es/packages/element-plus/input/index3.mjs +316 -316
- package/es/packages/element-plus/input-color/index.mjs +8 -8
- package/es/packages/element-plus/input-color/index2.mjs +8 -8
- package/es/packages/element-plus/input-color/index3.mjs +42 -42
- package/es/packages/element-plus/input-cron/index.mjs +8 -8
- package/es/packages/element-plus/input-cron/index2.mjs +15 -10
- package/es/packages/element-plus/input-cron/index3.mjs +218 -214
- package/es/packages/element-plus/input-icon/index.mjs +8 -8
- package/es/packages/element-plus/input-icon/index2.mjs +11 -11
- package/es/packages/element-plus/input-icon/index3.mjs +96 -96
- package/es/packages/element-plus/input-map/index.mjs +8 -8
- package/es/packages/element-plus/input-map/index2.mjs +10 -10
- package/es/packages/element-plus/input-map/index3.mjs +99 -99
- package/es/packages/element-plus/input-number/index.mjs +8 -8
- package/es/packages/element-plus/input-number/index2.mjs +8 -8
- package/es/packages/element-plus/input-number/index3.mjs +54 -54
- package/es/packages/element-plus/input-otp/index.mjs +8 -0
- package/es/packages/element-plus/input-otp/index2.mjs +67 -0
- package/es/packages/element-plus/input-otp/index3.mjs +41 -0
- package/es/packages/element-plus/input-table/index.mjs +8 -8
- package/es/packages/element-plus/input-table/index2.mjs +9 -9
- package/es/packages/element-plus/input-table/index3.mjs +77 -77
- package/es/packages/element-plus/input-tag/index.mjs +8 -8
- package/es/packages/element-plus/input-tag/index2.mjs +8 -8
- package/es/packages/element-plus/input-tag/index3.mjs +61 -61
- package/es/packages/element-plus/input-tree/index.mjs +8 -8
- package/es/packages/element-plus/input-tree/index2.mjs +9 -9
- package/es/packages/element-plus/input-tree/index3.mjs +75 -75
- package/es/packages/element-plus/license/index.mjs +8 -8
- package/es/packages/element-plus/license/index2.mjs +7 -7
- package/es/packages/element-plus/license/index3.mjs +19 -19
- package/es/packages/element-plus/login/index.mjs +8 -8
- package/es/packages/element-plus/login/index2.mjs +19 -10
- package/es/packages/element-plus/login/index3.mjs +165 -165
- package/es/packages/element-plus/mention/index.mjs +8 -8
- package/es/packages/element-plus/mention/index2.mjs +40 -16
- package/es/packages/element-plus/mention/index3.mjs +66 -66
- package/es/packages/element-plus/qrcode/index.mjs +8 -0
- package/es/packages/element-plus/qrcode/index2.mjs +274 -0
- package/es/packages/element-plus/qrcode/index3.mjs +57 -0
- package/es/packages/element-plus/radio/index.mjs +8 -8
- package/es/packages/element-plus/radio/index2.mjs +8 -8
- package/es/packages/element-plus/radio/index3.mjs +38 -38
- package/es/packages/element-plus/rate/index.mjs +8 -8
- package/es/packages/element-plus/rate/index2.mjs +8 -8
- package/es/packages/element-plus/rate/index3.mjs +22 -22
- package/es/packages/element-plus/search/index.mjs +8 -8
- package/es/packages/element-plus/search/index2.mjs +8 -8
- package/es/packages/element-plus/search/index3.mjs +50 -50
- package/es/packages/element-plus/select/index.mjs +8 -8
- package/es/packages/element-plus/select/index2.mjs +53 -16
- package/es/packages/element-plus/select/index3.mjs +161 -160
- package/es/packages/element-plus/sign/index.mjs +8 -8
- package/es/packages/element-plus/sign/index2.mjs +6 -6
- package/es/packages/element-plus/sign/index3.mjs +19 -19
- package/es/packages/element-plus/slider/index.mjs +8 -8
- package/es/packages/element-plus/slider/index2.mjs +8 -8
- package/es/packages/element-plus/slider/index3.mjs +25 -25
- package/es/packages/element-plus/switch/index.mjs +8 -8
- package/es/packages/element-plus/switch/index2.mjs +8 -8
- package/es/packages/element-plus/switch/index3.mjs +29 -29
- package/es/packages/element-plus/tabs/index.mjs +8 -8
- package/es/packages/element-plus/tabs/index2.mjs +11 -6
- package/es/packages/element-plus/tabs/index3.mjs +54 -39
- package/es/packages/element-plus/text-ellipsis/index.mjs +8 -8
- package/es/packages/element-plus/text-ellipsis/index2.mjs +6 -6
- package/es/packages/element-plus/text-ellipsis/index3.mjs +42 -42
- package/es/packages/element-plus/time/index.mjs +8 -8
- package/es/packages/element-plus/time/index2.mjs +9 -9
- package/es/packages/element-plus/time/index3.mjs +40 -40
- package/es/packages/element-plus/title/index.mjs +8 -8
- package/es/packages/element-plus/title/index2.mjs +8 -8
- package/es/packages/element-plus/title/index3.mjs +14 -14
- package/es/packages/element-plus/tree/index.mjs +8 -8
- package/es/packages/element-plus/tree/index2.mjs +9 -9
- package/es/packages/element-plus/tree/index3.mjs +186 -186
- package/es/packages/element-plus/upload/index.mjs +8 -8
- package/es/packages/element-plus/upload/index2.mjs +14 -14
- package/es/packages/element-plus/upload/index3.mjs +366 -366
- package/es/packages/element-plus/verify/index.mjs +8 -8
- package/es/packages/element-plus/verify/index2.mjs +6 -6
- package/es/packages/element-plus/verify/index3.mjs +18 -18
- package/es/packages/element-plus/video/index.mjs +8 -8
- package/es/packages/element-plus/video/index2.mjs +54 -17
- package/es/packages/element-plus/video/index3.mjs +41 -41
- package/es/src/core/column-state.mjs +102 -0
- package/es/src/core/create.mjs +12 -12
- package/es/src/core/dataformat.mjs +188 -188
- package/es/src/core/detail.mjs +78 -78
- package/es/src/core/dic.mjs +188 -216
- package/es/src/core/locale.mjs +12 -12
- package/es/src/core/option.mjs +211 -0
- package/es/src/core/packages.mjs +65 -65
- package/es/src/core/slot.mjs +35 -35
- package/es/src/global/variable.mjs +83 -83
- package/es/src/icon.mjs +13 -13
- package/es/src/index.mjs +272 -262
- package/es/src/locale/index.mjs +145 -145
- package/es/src/locale/lang/en.mjs +296 -285
- package/es/src/locale/lang/zh-cn.mjs +296 -285
- package/es/src/locale/lang/zh.mjs +296 -285
- package/es/src/plugin/ali/index.mjs +7 -7
- package/es/src/plugin/clipboard/index.mjs +64 -64
- package/es/src/plugin/export/_blob.mjs +151 -151
- package/es/src/plugin/export/_export2Excel.mjs +156 -156
- package/es/src/plugin/export/index.mjs +308 -268
- package/es/src/plugin/logs/index.mjs +46 -46
- package/es/src/plugin/print/index.mjs +233 -147
- package/es/src/plugin/qiniu/index.mjs +69 -69
- package/es/src/plugin/screenshot/index.mjs +12 -12
- package/es/src/plugin/video/index.mjs +101 -55
- package/es/src/plugin/watermark/index.mjs +118 -118
- package/es/src/plugin/watermark/watermark.mjs +103 -103
- package/es/src/ui/data/index.mjs +75 -75
- package/es/src/ui/element-plus/index.mjs +141 -132
- package/es/src/ui/index.mjs +7 -7
- package/es/src/utils/bem.mjs +32 -32
- package/es/src/utils/mock.mjs +141 -141
- package/es/src/utils/print.mjs +216 -0
- package/es/src/utils/util.mjs +374 -374
- package/es/src/utils/validate.mjs +21 -21
- package/es/src/version.mjs +4 -4
- package/lib/_virtual/_commonjsHelpers.js +8 -8
- package/lib/_virtual/dayjs.min.js +12 -12
- package/lib/_virtual/dayjs.min2.js +6 -6
- package/lib/index.css +1 -1
- package/lib/locale/browser/en.js +299 -288
- package/lib/locale/browser/zh-cn.js +299 -288
- package/lib/locale/browser/zh.js +299 -288
- package/lib/node_modules/.pnpm/dayjs@1.11.13/node_modules/dayjs/dayjs.min.js +1 -1
- package/lib/node_modules/.pnpm/qrcode-generator@2.0.4/node_modules/qrcode-generator/dist/qrcode.js +2240 -0
- package/lib/packages/core/common/event.js +66 -66
- package/lib/packages/core/common/init.js +226 -142
- package/lib/packages/core/common/props.js +247 -247
- package/lib/packages/core/components/dialog-form/index.js +12 -12
- package/lib/packages/core/components/dialog-form/index2.js +38 -38
- package/lib/packages/core/components/dialog-form/index3.js +10 -10
- package/lib/packages/core/components/dialog-form/index4.js +69 -69
- package/lib/packages/core/components/form/custom.js +48 -48
- package/lib/packages/core/components/form/index.js +12 -12
- package/lib/packages/core/components/form/index2.js +12 -12
- package/lib/packages/core/components/form/index3.js +93 -93
- package/lib/packages/core/components/icon/index.js +12 -12
- package/lib/packages/core/components/icon/index2.js +29 -8
- package/lib/packages/core/components/icon/index3.js +45 -43
- package/lib/packages/core/components/image-preview/index.js +12 -12
- package/lib/packages/core/components/image-preview/index2.js +43 -43
- package/lib/packages/core/components/image-preview/index3.js +12 -12
- package/lib/packages/core/components/image-preview/index4.js +162 -162
- package/lib/packages/core/directive/contextmenu.js +99 -99
- package/lib/packages/core/directive/permission.js +26 -26
- package/lib/packages/data/box/index.js +12 -12
- package/lib/packages/data/box/index2.js +10 -10
- package/lib/packages/data/box/index3.js +68 -68
- package/lib/packages/data/card/index.js +12 -12
- package/lib/packages/data/card/index2.js +10 -10
- package/lib/packages/data/card/index3.js +59 -59
- package/lib/packages/data/cardText/index.js +12 -12
- package/lib/packages/data/cardText/index2.js +10 -10
- package/lib/packages/data/cardText/index3.js +52 -52
- package/lib/packages/data/countdown/index.js +12 -12
- package/lib/packages/data/countdown/index2.js +11 -11
- package/lib/packages/data/countdown/index3.js +97 -97
- package/lib/packages/data/dashboard/index.js +12 -12
- package/lib/packages/data/dashboard/index2.js +10 -10
- package/lib/packages/data/dashboard/index3.js +102 -102
- package/lib/packages/data/display/index.js +12 -12
- package/lib/packages/data/display/index2.js +10 -10
- package/lib/packages/data/display/index3.js +58 -58
- package/lib/packages/data/icons/index.js +12 -12
- package/lib/packages/data/icons/index2.js +10 -10
- package/lib/packages/data/icons/index3.js +68 -68
- package/lib/packages/data/imgText/index.js +12 -12
- package/lib/packages/data/imgText/index2.js +10 -10
- package/lib/packages/data/imgText/index3.js +89 -89
- package/lib/packages/data/list/index.js +12 -12
- package/lib/packages/data/list/index2.js +15 -10
- package/lib/packages/data/list/index3.js +139 -136
- package/lib/packages/data/notice/index.js +12 -12
- package/lib/packages/data/notice/index2.js +11 -11
- package/lib/packages/data/notice/index3.js +61 -61
- package/lib/packages/data/operaText/index.js +12 -12
- package/lib/packages/data/operaText/index2.js +10 -10
- package/lib/packages/data/operaText/index3.js +76 -76
- package/lib/packages/data/panel/index.js +12 -12
- package/lib/packages/data/panel/index2.js +10 -10
- package/lib/packages/data/panel/index3.js +66 -66
- package/lib/packages/data/pay/index.js +12 -12
- package/lib/packages/data/pay/index2.js +10 -10
- package/lib/packages/data/pay/index3.js +130 -130
- package/lib/packages/data/price/index.js +12 -12
- package/lib/packages/data/price/index2.js +10 -10
- package/lib/packages/data/price/index3.js +58 -58
- package/lib/packages/data/product/index.js +12 -12
- package/lib/packages/data/product/index2.js +11 -11
- package/lib/packages/data/product/index3.js +160 -160
- package/lib/packages/data/profile/index.js +12 -12
- package/lib/packages/data/profile/index2.js +10 -10
- package/lib/packages/data/profile/index3.js +168 -168
- package/lib/packages/data/progress/index.js +12 -12
- package/lib/packages/data/progress/index2.js +10 -10
- package/lib/packages/data/progress/index3.js +65 -65
- package/lib/packages/data/rank/index.js +12 -12
- package/lib/packages/data/rank/index2.js +10 -10
- package/lib/packages/data/rank/index3.js +101 -101
- package/lib/packages/data/rotate/index.js +12 -12
- package/lib/packages/data/rotate/index2.js +11 -11
- package/lib/packages/data/rotate/index3.js +77 -77
- package/lib/packages/data/statistic/index.js +12 -12
- package/lib/packages/data/statistic/index2.js +24 -10
- package/lib/packages/data/statistic/index3.js +105 -102
- package/lib/packages/data/tabs/index.js +12 -12
- package/lib/packages/data/tabs/index2.js +10 -10
- package/lib/packages/data/tabs/index3.js +67 -67
- package/lib/packages/data/task/index.js +12 -12
- package/lib/packages/data/task/index2.js +11 -11
- package/lib/packages/data/task/index3.js +84 -84
- package/lib/packages/data/weather/index.js +12 -12
- package/lib/packages/data/weather/index2.js +16 -11
- package/lib/packages/data/weather/index3.js +83 -82
- package/lib/packages/element-plus/array/index.js +12 -12
- package/lib/packages/element-plus/array/index2.js +13 -13
- package/lib/packages/element-plus/array/index3.js +104 -104
- package/lib/packages/element-plus/article/index.js +12 -12
- package/lib/packages/element-plus/article/index2.js +10 -10
- package/lib/packages/element-plus/article/index3.js +50 -50
- package/lib/packages/element-plus/card/index.js +12 -12
- package/lib/packages/element-plus/card/index2.js +11 -11
- package/lib/packages/element-plus/card/index3.js +96 -96
- package/lib/packages/element-plus/cascader/index.js +12 -12
- package/lib/packages/element-plus/cascader/index2.js +22 -12
- package/lib/packages/element-plus/cascader/index3.js +53 -49
- package/lib/packages/element-plus/chat/index.js +12 -12
- package/lib/packages/element-plus/chat/index2.js +12 -12
- package/lib/packages/element-plus/chat/index3.js +394 -394
- package/lib/packages/element-plus/checkbox/index.js +12 -12
- package/lib/packages/element-plus/checkbox/index2.js +13 -13
- package/lib/packages/element-plus/checkbox/index3.js +63 -63
- package/lib/packages/element-plus/comment/index.js +12 -12
- package/lib/packages/element-plus/comment/index2.js +10 -10
- package/lib/packages/element-plus/comment/index3.js +45 -45
- package/lib/packages/element-plus/count-up/index.js +12 -12
- package/lib/packages/element-plus/count-up/index2.js +20 -20
- package/lib/packages/element-plus/count-up/index3.js +10 -10
- package/lib/packages/element-plus/crud/column/column-default.js +12 -12
- package/lib/packages/element-plus/crud/column/column-default2.js +14 -14
- package/lib/packages/element-plus/crud/column/column-default3.js +64 -64
- package/lib/packages/element-plus/crud/column/column-dynamic.js +12 -12
- package/lib/packages/element-plus/crud/column/column-dynamic2.js +13 -13
- package/lib/packages/element-plus/crud/column/column-dynamic3.js +77 -77
- package/lib/packages/element-plus/crud/column/column-menu.js +12 -12
- package/lib/packages/element-plus/crud/column/column-menu2.js +15 -15
- package/lib/packages/element-plus/crud/column/column-menu3.js +306 -306
- package/lib/packages/element-plus/crud/column/column-slot.js +12 -12
- package/lib/packages/element-plus/crud/column/column-slot2.js +22 -22
- package/lib/packages/element-plus/crud/column/column-slot3.js +209 -209
- package/lib/packages/element-plus/crud/column/column.js +12 -12
- package/lib/packages/element-plus/crud/column/column2.js +16 -16
- package/lib/packages/element-plus/crud/column/column3.js +51 -51
- package/lib/packages/element-plus/crud/column/menu.js +12 -12
- package/lib/packages/element-plus/crud/column/menu2.js +11 -11
- package/lib/packages/element-plus/crud/column/menu3.js +59 -59
- package/lib/packages/element-plus/crud/config.js +81 -81
- package/lib/packages/element-plus/crud/dialog/dialog-column.js +12 -12
- package/lib/packages/element-plus/crud/dialog/dialog-column2.js +129 -50
- package/lib/packages/element-plus/crud/dialog/dialog-column3.js +174 -73
- package/lib/packages/element-plus/crud/dialog/dialog-excel.js +12 -12
- package/lib/packages/element-plus/crud/dialog/dialog-excel2.js +13 -13
- package/lib/packages/element-plus/crud/dialog/dialog-excel3.js +61 -61
- package/lib/packages/element-plus/crud/dialog/dialog-filter.js +12 -12
- package/lib/packages/element-plus/crud/dialog/dialog-filter2.js +11 -11
- package/lib/packages/element-plus/crud/dialog/dialog-filter3.js +148 -148
- package/lib/packages/element-plus/crud/dialog/dialog-form.js +12 -12
- package/lib/packages/element-plus/crud/dialog/dialog-form2.js +13 -13
- package/lib/packages/element-plus/crud/dialog/dialog-form3.js +139 -139
- package/lib/packages/element-plus/crud/grid/index.js +12 -12
- package/lib/packages/element-plus/crud/grid/index2.js +11 -11
- package/lib/packages/element-plus/crud/grid/index3.js +119 -119
- package/lib/packages/element-plus/crud/grid/item.js +12 -12
- package/lib/packages/element-plus/crud/grid/item2.js +8 -8
- package/lib/packages/element-plus/crud/grid/item3.js +8 -8
- package/lib/packages/element-plus/crud/index.js +12 -12
- package/lib/packages/element-plus/crud/index2.js +128 -61
- package/lib/packages/element-plus/crud/index3.js +314 -283
- package/lib/packages/element-plus/crud/menu/header-menu.js +12 -12
- package/lib/packages/element-plus/crud/menu/header-menu2.js +31 -19
- package/lib/packages/element-plus/crud/menu/header-menu3.js +233 -173
- package/lib/packages/element-plus/crud/menu/header-search.js +12 -12
- package/lib/packages/element-plus/crud/menu/header-search2.js +16 -15
- package/lib/packages/element-plus/crud/menu/header-search3.js +83 -83
- package/lib/packages/element-plus/crud/menu/table-page.js +12 -12
- package/lib/packages/element-plus/crud/menu/table-page2.js +11 -11
- package/lib/packages/element-plus/crud/menu/table-page3.js +42 -42
- package/lib/packages/element-plus/date/index.js +12 -12
- package/lib/packages/element-plus/date/index2.js +17 -13
- package/lib/packages/element-plus/date/index3.js +65 -64
- package/lib/packages/element-plus/draggable/index.js +12 -12
- package/lib/packages/element-plus/draggable/index2.js +59 -31
- package/lib/packages/element-plus/draggable/index3.js +85 -85
- package/lib/packages/element-plus/dynamic/index.js +12 -12
- package/lib/packages/element-plus/dynamic/index2.js +13 -13
- package/lib/packages/element-plus/dynamic/index3.js +137 -137
- package/lib/packages/element-plus/flow/index.js +12 -12
- package/lib/packages/element-plus/flow/index2.js +14 -14
- package/lib/packages/element-plus/flow/index3.js +47 -47
- package/lib/packages/element-plus/flow/node.js +12 -12
- package/lib/packages/element-plus/flow/node2.js +10 -10
- package/lib/packages/element-plus/flow/node3.js +49 -49
- package/lib/packages/element-plus/form/config.js +13 -13
- package/lib/packages/element-plus/form/index.js +12 -12
- package/lib/packages/element-plus/form/index2.js +28 -25
- package/lib/packages/element-plus/form/index3.js +327 -314
- package/lib/packages/element-plus/form/menu.js +12 -12
- package/lib/packages/element-plus/form/menu2.js +11 -11
- package/lib/packages/element-plus/form/menu3.js +93 -93
- package/lib/packages/element-plus/group/index.js +12 -12
- package/lib/packages/element-plus/group/index2.js +15 -10
- package/lib/packages/element-plus/group/index3.js +78 -75
- package/lib/packages/element-plus/iframe/index.js +12 -0
- package/lib/packages/element-plus/iframe/index2.js +194 -0
- package/lib/packages/element-plus/iframe/index3.js +66 -0
- package/lib/packages/element-plus/input/index.js +12 -12
- package/lib/packages/element-plus/input/index2.js +13 -13
- package/lib/packages/element-plus/input/index3.js +318 -318
- package/lib/packages/element-plus/input-color/index.js +12 -12
- package/lib/packages/element-plus/input-color/index2.js +12 -12
- package/lib/packages/element-plus/input-color/index3.js +44 -44
- package/lib/packages/element-plus/input-cron/index.js +12 -12
- package/lib/packages/element-plus/input-cron/index2.js +19 -14
- package/lib/packages/element-plus/input-cron/index3.js +220 -216
- package/lib/packages/element-plus/input-icon/index.js +12 -12
- package/lib/packages/element-plus/input-icon/index2.js +15 -15
- package/lib/packages/element-plus/input-icon/index3.js +98 -98
- package/lib/packages/element-plus/input-map/index.js +12 -12
- package/lib/packages/element-plus/input-map/index2.js +14 -14
- package/lib/packages/element-plus/input-map/index3.js +101 -101
- package/lib/packages/element-plus/input-number/index.js +12 -12
- package/lib/packages/element-plus/input-number/index2.js +12 -12
- package/lib/packages/element-plus/input-number/index3.js +56 -56
- package/lib/packages/element-plus/input-otp/index.js +12 -0
- package/lib/packages/element-plus/input-otp/index2.js +71 -0
- package/lib/packages/element-plus/input-otp/index3.js +43 -0
- package/lib/packages/element-plus/input-table/index.js +12 -12
- package/lib/packages/element-plus/input-table/index2.js +13 -13
- package/lib/packages/element-plus/input-table/index3.js +79 -79
- package/lib/packages/element-plus/input-tag/index.js +12 -12
- package/lib/packages/element-plus/input-tag/index2.js +12 -12
- package/lib/packages/element-plus/input-tag/index3.js +63 -63
- package/lib/packages/element-plus/input-tree/index.js +12 -12
- package/lib/packages/element-plus/input-tree/index2.js +13 -13
- package/lib/packages/element-plus/input-tree/index3.js +77 -77
- package/lib/packages/element-plus/license/index.js +12 -12
- package/lib/packages/element-plus/license/index2.js +11 -11
- package/lib/packages/element-plus/license/index3.js +21 -21
- package/lib/packages/element-plus/login/index.js +12 -12
- package/lib/packages/element-plus/login/index2.js +23 -14
- package/lib/packages/element-plus/login/index3.js +167 -167
- package/lib/packages/element-plus/mention/index.js +12 -12
- package/lib/packages/element-plus/mention/index2.js +44 -20
- package/lib/packages/element-plus/mention/index3.js +68 -68
- package/lib/packages/element-plus/qrcode/index.js +12 -0
- package/lib/packages/element-plus/qrcode/index2.js +278 -0
- package/lib/packages/element-plus/qrcode/index3.js +59 -0
- package/lib/packages/element-plus/radio/index.js +12 -12
- package/lib/packages/element-plus/radio/index2.js +12 -12
- package/lib/packages/element-plus/radio/index3.js +40 -40
- package/lib/packages/element-plus/rate/index.js +12 -12
- package/lib/packages/element-plus/rate/index2.js +12 -12
- package/lib/packages/element-plus/rate/index3.js +24 -24
- package/lib/packages/element-plus/search/index.js +12 -12
- package/lib/packages/element-plus/search/index2.js +12 -12
- package/lib/packages/element-plus/search/index3.js +52 -52
- package/lib/packages/element-plus/select/index.js +12 -12
- package/lib/packages/element-plus/select/index2.js +57 -20
- package/lib/packages/element-plus/select/index3.js +163 -162
- package/lib/packages/element-plus/sign/index.js +12 -12
- package/lib/packages/element-plus/sign/index2.js +10 -10
- package/lib/packages/element-plus/sign/index3.js +21 -21
- package/lib/packages/element-plus/slider/index.js +12 -12
- package/lib/packages/element-plus/slider/index2.js +12 -12
- package/lib/packages/element-plus/slider/index3.js +27 -27
- package/lib/packages/element-plus/switch/index.js +12 -12
- package/lib/packages/element-plus/switch/index2.js +12 -12
- package/lib/packages/element-plus/switch/index3.js +31 -31
- package/lib/packages/element-plus/tabs/index.js +12 -12
- package/lib/packages/element-plus/tabs/index2.js +15 -10
- package/lib/packages/element-plus/tabs/index3.js +56 -41
- package/lib/packages/element-plus/text-ellipsis/index.js +12 -12
- package/lib/packages/element-plus/text-ellipsis/index2.js +10 -10
- package/lib/packages/element-plus/text-ellipsis/index3.js +44 -44
- package/lib/packages/element-plus/time/index.js +12 -12
- package/lib/packages/element-plus/time/index2.js +13 -13
- package/lib/packages/element-plus/time/index3.js +42 -42
- package/lib/packages/element-plus/title/index.js +12 -12
- package/lib/packages/element-plus/title/index2.js +12 -12
- package/lib/packages/element-plus/title/index3.js +16 -16
- package/lib/packages/element-plus/tree/index.js +12 -12
- package/lib/packages/element-plus/tree/index2.js +13 -13
- package/lib/packages/element-plus/tree/index3.js +188 -188
- package/lib/packages/element-plus/upload/index.js +12 -12
- package/lib/packages/element-plus/upload/index2.js +18 -18
- package/lib/packages/element-plus/upload/index3.js +368 -368
- package/lib/packages/element-plus/verify/index.js +12 -12
- package/lib/packages/element-plus/verify/index2.js +10 -10
- package/lib/packages/element-plus/verify/index3.js +20 -20
- package/lib/packages/element-plus/video/index.js +12 -12
- package/lib/packages/element-plus/video/index2.js +58 -21
- package/lib/packages/element-plus/video/index3.js +43 -43
- package/lib/src/core/column-state.js +109 -0
- package/lib/src/core/create.js +16 -16
- package/lib/src/core/dataformat.js +196 -196
- package/lib/src/core/detail.js +80 -80
- package/lib/src/core/dic.js +193 -221
- package/lib/src/core/locale.js +16 -16
- package/lib/src/core/option.js +214 -0
- package/lib/src/core/packages.js +69 -69
- package/lib/src/core/slot.js +39 -39
- package/lib/src/global/variable.js +99 -99
- package/lib/src/icon.js +37 -37
- package/lib/src/index.js +371 -356
- package/lib/src/locale/index.js +159 -159
- package/lib/src/locale/lang/en.js +300 -289
- package/lib/src/locale/lang/zh-cn.js +300 -289
- package/lib/src/locale/lang/zh.js +300 -289
- package/lib/src/plugin/ali/index.js +9 -9
- package/lib/src/plugin/clipboard/index.js +68 -68
- package/lib/src/plugin/export/_blob.js +153 -153
- package/lib/src/plugin/export/_export2Excel.js +159 -159
- package/lib/src/plugin/export/index.js +312 -272
- package/lib/src/plugin/logs/index.js +50 -50
- package/lib/src/plugin/print/index.js +237 -151
- package/lib/src/plugin/qiniu/index.js +71 -71
- package/lib/src/plugin/screenshot/index.js +16 -16
- package/lib/src/plugin/video/index.js +105 -59
- package/lib/src/plugin/watermark/index.js +123 -123
- package/lib/src/plugin/watermark/watermark.js +107 -107
- package/lib/src/ui/data/index.js +102 -102
- package/lib/src/ui/element-plus/index.js +190 -178
- package/lib/src/ui/index.js +11 -11
- package/lib/src/utils/bem.js +36 -36
- package/lib/src/utils/mock.js +145 -145
- package/lib/src/utils/print.js +218 -0
- package/lib/src/utils/util.js +408 -408
- package/lib/src/utils/validate.js +23 -23
- package/lib/src/version.js +6 -6
- package/package.json +3 -2
- package/types/index.d.ts +107 -91
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
/*! Avue.js v3.9.
|
|
2
|
-
'use strict';
|
|
3
|
-
|
|
4
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
-
|
|
6
|
-
var src_core_dataformat = require('../../../src/core/dataformat.js');
|
|
7
|
-
var src_utils_util = require('../../../src/utils/util.js');
|
|
8
|
-
|
|
9
|
-
function event () {
|
|
10
|
-
return {
|
|
11
|
-
methods: {
|
|
12
|
-
bindEvent(name, params) {
|
|
13
|
-
const item = src_utils_util.findNode(this.dic, this.props, this.text);
|
|
14
|
-
params = Object.assign(params, { column: this.column, dic: this.dic, item }, this.tableData);
|
|
15
|
-
if (typeof this[name] === 'function') {
|
|
16
|
-
if (name == 'change') {
|
|
17
|
-
if (this.column.cell != true) {
|
|
18
|
-
this[name](params);
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
else {
|
|
22
|
-
this[name](params);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
this.$emit(name, params);
|
|
26
|
-
},
|
|
27
|
-
initVal() {
|
|
28
|
-
this.stringMode = typeof this.modelValue == 'string';
|
|
29
|
-
this.text = src_core_dataformat.initVal(this.modelValue, this);
|
|
30
|
-
},
|
|
31
|
-
getLabelText(item) {
|
|
32
|
-
if (this.validatenull(item))
|
|
33
|
-
return '';
|
|
34
|
-
if (typeof this.typeformat === 'function') {
|
|
35
|
-
return this.typeformat(item, this.labelKey, this.valueKey);
|
|
36
|
-
}
|
|
37
|
-
return item[this.labelKey];
|
|
38
|
-
},
|
|
39
|
-
handleFocus(event) {
|
|
40
|
-
this.bindEvent('focus', { value: this.modelValue, event });
|
|
41
|
-
},
|
|
42
|
-
handleBlur(event) {
|
|
43
|
-
this.bindEvent('blur', { value: this.modelValue, event });
|
|
44
|
-
},
|
|
45
|
-
handleClick(event) {
|
|
46
|
-
this.bindEvent('click', { value: this.modelValue, event });
|
|
47
|
-
},
|
|
48
|
-
handleChange(value) {
|
|
49
|
-
let result = value;
|
|
50
|
-
if (this.isJson) {
|
|
51
|
-
result = JSON.stringify(value);
|
|
52
|
-
}
|
|
53
|
-
else {
|
|
54
|
-
const flag = this.isString || this.isNumber || this.stringMode || this.listType === 'picture-img';
|
|
55
|
-
if (flag && Array.isArray(value)) {
|
|
56
|
-
result = value.join(this.separator);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
this.bindEvent('change', { value: result });
|
|
60
|
-
this.$emit('update:modelValue', result);
|
|
61
|
-
},
|
|
62
|
-
},
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
exports.default = event;
|
|
1
|
+
/*! Avue.js v3.9.3 | (c) 2017-2026 Smallwei | Released under the MIT License. */
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
+
|
|
6
|
+
var src_core_dataformat = require('../../../src/core/dataformat.js');
|
|
7
|
+
var src_utils_util = require('../../../src/utils/util.js');
|
|
8
|
+
|
|
9
|
+
function event () {
|
|
10
|
+
return {
|
|
11
|
+
methods: {
|
|
12
|
+
bindEvent(name, params) {
|
|
13
|
+
const item = src_utils_util.findNode(this.dic, this.props, this.text);
|
|
14
|
+
params = Object.assign(params, { column: this.column, dic: this.dic, item }, this.tableData);
|
|
15
|
+
if (typeof this[name] === 'function') {
|
|
16
|
+
if (name == 'change') {
|
|
17
|
+
if (this.column.cell != true) {
|
|
18
|
+
this[name](params);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
this[name](params);
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
this.$emit(name, params);
|
|
26
|
+
},
|
|
27
|
+
initVal() {
|
|
28
|
+
this.stringMode = typeof this.modelValue == 'string';
|
|
29
|
+
this.text = src_core_dataformat.initVal(this.modelValue, this);
|
|
30
|
+
},
|
|
31
|
+
getLabelText(item) {
|
|
32
|
+
if (this.validatenull(item))
|
|
33
|
+
return '';
|
|
34
|
+
if (typeof this.typeformat === 'function') {
|
|
35
|
+
return this.typeformat(item, this.labelKey, this.valueKey);
|
|
36
|
+
}
|
|
37
|
+
return item[this.labelKey];
|
|
38
|
+
},
|
|
39
|
+
handleFocus(event) {
|
|
40
|
+
this.bindEvent('focus', { value: this.modelValue, event });
|
|
41
|
+
},
|
|
42
|
+
handleBlur(event) {
|
|
43
|
+
this.bindEvent('blur', { value: this.modelValue, event });
|
|
44
|
+
},
|
|
45
|
+
handleClick(event) {
|
|
46
|
+
this.bindEvent('click', { value: this.modelValue, event });
|
|
47
|
+
},
|
|
48
|
+
handleChange(value) {
|
|
49
|
+
let result = value;
|
|
50
|
+
if (this.isJson) {
|
|
51
|
+
result = JSON.stringify(value);
|
|
52
|
+
}
|
|
53
|
+
else {
|
|
54
|
+
const flag = this.isString || this.isNumber || this.stringMode || this.listType === 'picture-img';
|
|
55
|
+
if (flag && Array.isArray(value)) {
|
|
56
|
+
result = value.join(this.separator);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
this.bindEvent('change', { value: result });
|
|
60
|
+
this.$emit('update:modelValue', result);
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
exports.default = event;
|
|
@@ -1,142 +1,226 @@
|
|
|
1
|
-
/*! Avue.js v3.9.
|
|
2
|
-
'use strict';
|
|
3
|
-
|
|
4
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
-
|
|
6
|
-
var src_core_dic = require('../../../src/core/dic.js');
|
|
7
|
-
var src_global_variable = require('../../../src/global/variable.js');
|
|
8
|
-
var src_core_slot = require('../../../src/core/slot.js');
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
},
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
},
|
|
42
|
-
},
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
...
|
|
83
|
-
...
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
if (this.
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
}
|
|
113
|
-
if (
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
|
|
1
|
+
/*! Avue.js v3.9.3 | (c) 2017-2026 Smallwei | Released under the MIT License. */
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
+
|
|
6
|
+
var src_core_dic = require('../../../src/core/dic.js');
|
|
7
|
+
var src_global_variable = require('../../../src/global/variable.js');
|
|
8
|
+
var src_core_slot = require('../../../src/core/slot.js');
|
|
9
|
+
var src_core_option = require('../../../src/core/option.js');
|
|
10
|
+
|
|
11
|
+
const dicRequestStates = new WeakMap();
|
|
12
|
+
const getDicRequestState = (safe) => {
|
|
13
|
+
let state = dicRequestStates.get(safe);
|
|
14
|
+
if (!state) {
|
|
15
|
+
state = {
|
|
16
|
+
active: new Set(),
|
|
17
|
+
sequence: {},
|
|
18
|
+
unmounted: false,
|
|
19
|
+
};
|
|
20
|
+
dicRequestStates.set(safe, state);
|
|
21
|
+
}
|
|
22
|
+
return state;
|
|
23
|
+
};
|
|
24
|
+
function init (name) {
|
|
25
|
+
return {
|
|
26
|
+
mixins: [src_core_slot.default],
|
|
27
|
+
emits: ['update:modelValue', 'change', 'dic-error'],
|
|
28
|
+
props: {
|
|
29
|
+
tableData: {
|
|
30
|
+
type: Object,
|
|
31
|
+
default: () => {
|
|
32
|
+
return {};
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
option: {
|
|
36
|
+
type: Object,
|
|
37
|
+
required: true,
|
|
38
|
+
default: () => {
|
|
39
|
+
return {};
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
watch: {
|
|
44
|
+
propOption: {
|
|
45
|
+
handler(list) {
|
|
46
|
+
list.forEach((ele) => (this.objectOption[ele.prop] = ele));
|
|
47
|
+
},
|
|
48
|
+
deep: true,
|
|
49
|
+
},
|
|
50
|
+
option: {
|
|
51
|
+
handler() {
|
|
52
|
+
this.init(false);
|
|
53
|
+
},
|
|
54
|
+
deep: true,
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
data() {
|
|
58
|
+
return {
|
|
59
|
+
DIC: {},
|
|
60
|
+
cascaderDIC: {},
|
|
61
|
+
tableOption: {},
|
|
62
|
+
objectOption: {},
|
|
63
|
+
dicLoading: false,
|
|
64
|
+
dicError: null,
|
|
65
|
+
};
|
|
66
|
+
},
|
|
67
|
+
mounted() {
|
|
68
|
+
getDicRequestState(this).unmounted = false;
|
|
69
|
+
this.init();
|
|
70
|
+
},
|
|
71
|
+
beforeUnmount() {
|
|
72
|
+
const state = getDicRequestState(this);
|
|
73
|
+
state.unmounted = true;
|
|
74
|
+
state.active.clear();
|
|
75
|
+
},
|
|
76
|
+
computed: {
|
|
77
|
+
isMobile() {
|
|
78
|
+
return document.body.clientWidth <= 768;
|
|
79
|
+
},
|
|
80
|
+
resultOption() {
|
|
81
|
+
return {
|
|
82
|
+
...this.tableOption,
|
|
83
|
+
...{
|
|
84
|
+
column: this.propOption || [],
|
|
85
|
+
},
|
|
86
|
+
};
|
|
87
|
+
},
|
|
88
|
+
rowKey() {
|
|
89
|
+
return this.tableOption.rowKey || src_global_variable.DIC_PROPS.rowKey;
|
|
90
|
+
},
|
|
91
|
+
formRules() {
|
|
92
|
+
const result = {};
|
|
93
|
+
this.propOption.forEach((ele) => {
|
|
94
|
+
if (ele.rules && ele.display !== false)
|
|
95
|
+
result[ele.prop] = ele.rules;
|
|
96
|
+
});
|
|
97
|
+
return result;
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
methods: {
|
|
101
|
+
init(type) {
|
|
102
|
+
const globOption = this.deepClone(this.$AVUE[`${name}Option`]);
|
|
103
|
+
const option = {
|
|
104
|
+
...globOption,
|
|
105
|
+
...this.option,
|
|
106
|
+
};
|
|
107
|
+
this.tableOption = option;
|
|
108
|
+
const componentName = name || (this.$options.name || '').replace(/^avue-/, '') || 'component';
|
|
109
|
+
if (this.$AVUE.optionValidate !== false &&
|
|
110
|
+
option.optionValidate !== false) {
|
|
111
|
+
src_core_option.warnOption(src_core_option.validateOption(option, componentName), componentName);
|
|
112
|
+
}
|
|
113
|
+
if (name === 'crud' && typeof this.restoreColumnState === 'function') {
|
|
114
|
+
this.restoreColumnState();
|
|
115
|
+
}
|
|
116
|
+
this.handleLocalDic();
|
|
117
|
+
if (type !== false)
|
|
118
|
+
this.handleLoadDic();
|
|
119
|
+
},
|
|
120
|
+
dicInit(type) {
|
|
121
|
+
if (type === 'cascader') {
|
|
122
|
+
return this.handleLoadCascaderDic();
|
|
123
|
+
}
|
|
124
|
+
else {
|
|
125
|
+
return this.handleLoadDic();
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
updateDic(prop, list) {
|
|
129
|
+
const column = this.findObject(this.propOption, prop);
|
|
130
|
+
if (!column)
|
|
131
|
+
return Promise.resolve(null);
|
|
132
|
+
const formatter = column.dicFormatter;
|
|
133
|
+
const callback = (currentList, useFormatter = true) => {
|
|
134
|
+
if (useFormatter && typeof formatter === 'function') {
|
|
135
|
+
this.DIC[prop] = formatter(currentList, this.tableForm || this.form);
|
|
136
|
+
}
|
|
137
|
+
else {
|
|
138
|
+
this.DIC[prop] = currentList;
|
|
139
|
+
}
|
|
140
|
+
};
|
|
141
|
+
if (this.validatenull(list) && this.validatenull(prop)) {
|
|
142
|
+
return this.handleLoadDic();
|
|
143
|
+
}
|
|
144
|
+
if (this.validatenull(list) && !this.validatenull(column.dicUrl)) {
|
|
145
|
+
return this.requestDic({
|
|
146
|
+
column,
|
|
147
|
+
}, `update:${prop}`).then((currentList) => {
|
|
148
|
+
if (currentList)
|
|
149
|
+
callback(currentList, false);
|
|
150
|
+
return currentList;
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
else {
|
|
154
|
+
callback(list || []);
|
|
155
|
+
return Promise.resolve(list || []);
|
|
156
|
+
}
|
|
157
|
+
},
|
|
158
|
+
handleSetDic(list, res = {}) {
|
|
159
|
+
Object.keys(res).forEach((ele) => {
|
|
160
|
+
list[ele] = res[ele];
|
|
161
|
+
});
|
|
162
|
+
},
|
|
163
|
+
handleLocalDic() {
|
|
164
|
+
const localDic = src_core_dic.loadLocalDic(this.resultOption);
|
|
165
|
+
this.handleSetDic(this.DIC, localDic.data);
|
|
166
|
+
return this.runDicRequest('local-dic', () => localDic.pending, (result) => {
|
|
167
|
+
this.handleSetDic(this.DIC, result);
|
|
168
|
+
});
|
|
169
|
+
},
|
|
170
|
+
handleLoadDic() {
|
|
171
|
+
return this.runDicRequest('dic', () => src_core_dic.loadDic(this.resultOption, this), (result) => {
|
|
172
|
+
this.handleSetDic(this.DIC, result);
|
|
173
|
+
});
|
|
174
|
+
},
|
|
175
|
+
handleLoadCascaderDic() {
|
|
176
|
+
return this.runDicRequest('cascader', () => src_core_dic.loadCascaderDic(this.propOption, this), (result) => {
|
|
177
|
+
Object.keys(result).forEach((index) => {
|
|
178
|
+
if (!this.cascaderDIC[index])
|
|
179
|
+
this.cascaderDIC[index] = {};
|
|
180
|
+
this.handleSetDic(this.cascaderDIC[index], result[index]);
|
|
181
|
+
});
|
|
182
|
+
});
|
|
183
|
+
},
|
|
184
|
+
requestDic(params, requestType = 'manual') {
|
|
185
|
+
return this.runDicRequest(requestType, () => src_core_dic.sendDic(params, this));
|
|
186
|
+
},
|
|
187
|
+
runDicRequest(requestType, request, apply) {
|
|
188
|
+
const state = getDicRequestState(this);
|
|
189
|
+
const requestId = (state.sequence[requestType] || 0) + 1;
|
|
190
|
+
const token = `${requestType}:${requestId}`;
|
|
191
|
+
state.sequence[requestType] = requestId;
|
|
192
|
+
state.active.add(token);
|
|
193
|
+
this.dicLoading = true;
|
|
194
|
+
this.dicError = null;
|
|
195
|
+
const isCurrent = () => !state.unmounted && state.sequence[requestType] === requestId;
|
|
196
|
+
return Promise.resolve()
|
|
197
|
+
.then(request)
|
|
198
|
+
.then((result) => {
|
|
199
|
+
if (!isCurrent())
|
|
200
|
+
return null;
|
|
201
|
+
if (apply)
|
|
202
|
+
apply(result);
|
|
203
|
+
return result;
|
|
204
|
+
})
|
|
205
|
+
.catch((error) => {
|
|
206
|
+
if (isCurrent()) {
|
|
207
|
+
this.dicError = error;
|
|
208
|
+
this.$emit('dic-error', {
|
|
209
|
+
type: requestType,
|
|
210
|
+
error,
|
|
211
|
+
});
|
|
212
|
+
}
|
|
213
|
+
return null;
|
|
214
|
+
})
|
|
215
|
+
.finally(() => {
|
|
216
|
+
state.active.delete(token);
|
|
217
|
+
if (!state.unmounted) {
|
|
218
|
+
this.dicLoading = state.active.size > 0;
|
|
219
|
+
}
|
|
220
|
+
});
|
|
221
|
+
},
|
|
222
|
+
},
|
|
223
|
+
};
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
exports.default = init;
|