@web-utils/component 2.0.13 → 2.2.0
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/address-input/index.mjs +113 -0
- package/address-input/style.css +1 -0
- package/affix/index.mjs +102 -0
- package/affix/style.css +1 -0
- package/aside-menu/index.mjs +58 -0
- package/aside-menu/style.css +1 -0
- package/avatar/index.mjs +106 -0
- package/avatar/style.css +1 -0
- package/awesome-button/index.mjs +112 -0
- package/base.css +1 -0
- package/capsule-tab/index.mjs +52 -0
- package/capsule-tab/style.css +1 -0
- package/card/index.mjs +126 -0
- package/card/style.css +1 -0
- package/carousel/index.mjs +70 -0
- package/carousel/style.css +1 -0
- package/chat/index.mjs +576 -0
- package/chat/style.css +1 -0
- package/chunk-file-uploader/index.mjs +121 -0
- package/chunk-file-uploader/style.css +1 -0
- package/chunks/FormTemp.FX8xmbVB.mjs +165 -0
- package/chunks/confirmable-mixin.rTUMhoRH.mjs +106 -0
- package/chunks/dataformat.X_61lMA7.mjs +158 -0
- package/chunks/dic.6tk91Dmq.mjs +130 -0
- package/chunks/event.NHA7rYFE.mjs +236 -0
- package/chunks/form-input-mixin.IKogWBfn.mjs +24 -0
- package/chunks/form-item-mixin.BilKDUlK.mjs +140 -0
- package/{dist/chunks/822300f3.js → chunks/form-pick-mixin.y-qhZJi6.mjs} +3 -3
- package/chunks/index.LGsb2aDq.mjs +185 -0
- package/chunks/init.Ac4dKUJB.mjs +122 -0
- package/{dist/chunks/44b78389.js → chunks/input-number-mixin.GE2zr_3s.mjs} +8 -8
- package/chunks/json-beautifier.fUZFSW5j.mjs +126 -0
- package/chunks/packages.v6r2Hr7E.mjs +58 -0
- package/chunks/permission.E9kZbW48.mjs +16 -0
- package/chunks/slot.j1uMmBnG.mjs +27 -0
- package/chunks/tab-mixin.tM9jcRT8.mjs +81 -0
- package/chunks/util.C2Bhx22L.mjs +259 -0
- package/chunks/vueComponentNormalizer.JwmUNtgn.mjs +32 -0
- package/code-mirror-editor/index.mjs +313 -0
- package/code-mirror-editor/style.css +1 -0
- package/color-picker/index.mjs +128 -0
- package/comment/index.mjs +90 -0
- package/comment/style.css +1 -0
- package/confirm-button/index.mjs +57 -0
- package/confirmable/index.mjs +28 -0
- package/context-menu/index.mjs +255 -0
- package/context-menu/style.css +1 -0
- package/count-up/index.mjs +131 -0
- package/custom-scrollbar/index.mjs +116 -0
- package/data-box/index.mjs +97 -0
- package/data-box/style.css +1 -0
- package/data-card/index.mjs +98 -0
- package/data-card/style.css +1 -0
- package/data-cardtext/index.mjs +82 -0
- package/data-cardtext/style.css +1 -0
- package/data-display/index.mjs +97 -0
- package/data-display/style.css +1 -0
- package/data-icons/index.mjs +104 -0
- package/data-icons/style.css +1 -0
- package/data-imgtext/index.mjs +106 -0
- package/data-imgtext/style.css +1 -0
- package/data-operatext/index.mjs +99 -0
- package/data-operatext/style.css +1 -0
- package/data-panel/index.mjs +93 -0
- package/data-panel/style.css +1 -0
- package/data-pay/index.mjs +152 -0
- package/data-pay/style.css +1 -0
- package/data-price/index.mjs +84 -0
- package/data-price/style.css +1 -0
- package/data-progress/index.mjs +97 -0
- package/data-progress/style.css +1 -0
- package/data-rotate/index.mjs +96 -0
- package/data-rotate/style.css +1 -0
- package/data-table-picker/index.mjs +137 -0
- package/data-tabs/index.mjs +94 -0
- package/data-tabs/style.css +1 -0
- package/dialog-form/index.mjs +148 -0
- package/dialog-form/style.css +1 -0
- package/dynamic-table/index.mjs +195 -0
- package/dynamic-table/style.css +1 -0
- package/e-charts/index.mjs +216 -0
- package/e-charts/style.css +1 -0
- package/easy-popup/index.mjs +136 -0
- package/easy-popup/style.css +1 -0
- package/editable-progress/index.mjs +141 -0
- package/editable-progress/style.css +1 -0
- package/editable-tree/index.mjs +844 -0
- package/editable-tree/style.css +1 -0
- package/egd-collapse/index.mjs +79 -0
- package/egd-collapse-item/index.mjs +134 -0
- package/element-dialog/index.mjs +296 -0
- package/element-dialog/style.css +1 -0
- package/empty-view/index.mjs +69 -0
- package/empty-view/style.css +1 -0
- package/error-view/index.mjs +61 -0
- package/error-view/style.css +1 -0
- package/flex-column/index.mjs +62 -0
- package/flex-item/index.mjs +81 -0
- package/flex-row/index.mjs +62 -0
- package/flex-scroller/index.mjs +47 -0
- package/flex-scroller/style.css +1 -0
- package/flow/index.mjs +277 -0
- package/flow/style.css +1 -0
- package/flow-designer/index.mjs +10184 -0
- package/flow-designer/style.css +1 -0
- package/flow-node/index.mjs +102 -0
- package/flow-viewer/index.mjs +209 -0
- package/flow-viewer/style.css +1 -0
- package/form-block/index.mjs +156 -0
- package/form-block/style.css +1 -0
- package/form-button/index.mjs +58 -0
- package/form-cascader/index.mjs +163 -0
- package/form-checkbox-group/index.mjs +203 -0
- package/form-checkbox-group/style.css +1 -0
- package/form-date-picker/index.mjs +191 -0
- package/form-holder/index.mjs +129 -0
- package/form-input/index.mjs +117 -0
- package/form-input-email/index.mjs +108 -0
- package/form-input-id-card/index.mjs +115 -0
- package/form-input-number/index.mjs +134 -0
- package/form-input-number/style.css +1 -0
- package/form-input-phone-number/index.mjs +109 -0
- package/form-input-tag/index.mjs +108 -0
- package/form-input-time/index.mjs +135 -0
- package/form-item/index.mjs +147 -0
- package/form-item/style.css +1 -0
- package/form-item-config-provider/index.mjs +63 -0
- package/form-item-group/index.mjs +169 -0
- package/form-item-group/style.css +1 -0
- package/form-radio-group/index.mjs +181 -0
- package/form-radio-group/style.css +1 -0
- package/form-select/index.mjs +165 -0
- package/form-switch/index.mjs +108 -0
- package/form-textarea/index.mjs +113 -0
- package/form-view/index.mjs +371 -0
- package/form-view/style.css +1 -0
- package/fy-array/index.mjs +158 -0
- package/fy-array/style.css +1 -0
- package/fy-article/index.mjs +93 -0
- package/fy-article/style.css +1 -0
- package/fy-cascader/index.mjs +132 -0
- package/fy-checkbox/index.mjs +117 -0
- package/fy-checkbox/style.css +1 -0
- package/fy-code/index.mjs +66 -0
- package/fy-curd/index.mjs +3119 -0
- package/fy-curd/style.css +1 -0
- package/fy-date/index.mjs +84 -0
- package/fy-date/style.css +1 -0
- package/fy-draggable/index.mjs +382 -0
- package/fy-draggable/style.css +1 -0
- package/fy-dynamic/index.mjs +337 -0
- package/fy-dynamic/style.css +1 -0
- package/fy-empty/index.mjs +59 -0
- package/fy-empty/style.css +1 -0
- package/fy-form/index.mjs +993 -0
- package/fy-form/style.css +1 -0
- package/fy-form-design/index.mjs +7483 -0
- package/fy-form-design/style.css +1 -0
- package/fy-input/index.mjs +171 -0
- package/fy-input-color/index.mjs +101 -0
- package/fy-input-icon/index.mjs +169 -0
- package/fy-input-icon/style.css +1 -0
- package/fy-input-map/index.mjs +279 -0
- package/fy-input-map/style.css +1 -0
- package/fy-input-number/index.mjs +87 -0
- package/fy-input-table/index.mjs +172 -0
- package/fy-input-table/style.css +1 -0
- package/fy-input-tree/index.mjs +267 -0
- package/fy-input-tree/style.css +1 -0
- package/fy-progress/index.mjs +60 -0
- package/fy-radio/index.mjs +70 -0
- package/fy-radio/style.css +1 -0
- package/fy-rate/index.mjs +106 -0
- package/fy-rate/style.css +1 -0
- package/fy-select/index.mjs +225 -0
- package/fy-select/style.css +1 -0
- package/fy-slider/index.mjs +79 -0
- package/fy-switch/index.mjs +74 -0
- package/fy-tabs/index.mjs +92 -0
- package/fy-time/index.mjs +95 -0
- package/fy-title/index.mjs +40 -0
- package/fy-title/style.css +1 -0
- package/fy-tree/index.mjs +433 -0
- package/fy-tree/style.css +1 -0
- package/fy-u-editor/index.mjs +398 -0
- package/fy-u-editor/style.css +1 -0
- package/fy-upload/index.mjs +592 -0
- package/fy-upload/style.css +1 -0
- package/guide-steps/index.mjs +94 -0
- package/guide-steps/style.css +1 -0
- package/highlight-j-s/index.mjs +76 -0
- package/highlight-j-s/style.css +1 -0
- package/icon-card/index.mjs +62 -0
- package/icon-card/style.css +1 -0
- package/icon-temp/index.mjs +50 -0
- package/icon-temp/style.css +1 -0
- package/iframe-window/index.mjs +61 -0
- package/iframe-window/style.css +1 -0
- package/image-cropper/index.mjs +249 -0
- package/image-cropper/style.css +1 -0
- package/image-preview/index.mjs +260 -0
- package/image-preview/style.css +1 -0
- package/image-viewer/index.mjs +95 -0
- package/image-viewer/style.css +1 -0
- package/index.mjs +627 -0
- package/input-number/index.mjs +274 -0
- package/input-number/style.css +1 -0
- package/input-number-range/index.mjs +110 -0
- package/input-number-range/style.css +1 -0
- package/{dist/components/j-s-x-component/index.js → j-s-x-component/index.mjs} +4 -4
- package/keep-view-alive/index.mjs +123 -0
- package/keyboard/index.mjs +384 -0
- package/keyboard/style.css +1 -0
- package/license/index.mjs +134 -0
- package/loading-view/index.mjs +61 -0
- package/loading-view/style.css +1 -0
- package/login/index.mjs +250 -0
- package/login/style.css +1 -0
- package/monaco-editor/index.mjs +197 -0
- package/name-avatar/index.mjs +66 -0
- package/name-avatar/style.css +1 -0
- package/nav-bar/index.mjs +52 -0
- package/nav-bar/style.css +1 -0
- package/not-implement/index.mjs +35 -0
- package/not-implement/style.css +1 -0
- package/notice/index.mjs +143 -0
- package/notice/style.css +1 -0
- package/package.json +41 -148
- package/page/index.mjs +40 -0
- package/page/style.css +1 -0
- package/page-header/index.mjs +56 -0
- package/page-header/style.css +1 -0
- package/page-index/index.mjs +175 -0
- package/page-index/style.css +1 -0
- package/page-index-top/index.mjs +141 -0
- package/page-skeleton/index.mjs +67 -0
- package/page-skeleton/style.css +1 -0
- package/page-skeleton-new/index.mjs +98 -0
- package/page-skeleton-new/style.css +1 -0
- package/pageable-table/index.mjs +478 -0
- package/pageable-table/style.css +1 -0
- package/pageable-view/index.mjs +378 -0
- package/pageable-view/style.css +1 -0
- package/photo-swipe/index.mjs +129 -0
- package/present-view/index.mjs +365 -0
- package/present-view/style.css +1 -0
- package/queue/index.mjs +71 -0
- package/queue/style.css +1 -0
- package/record-video/index.mjs +173 -0
- package/record-video/style.css +1 -0
- package/resize-observer/index.mjs +62 -0
- package/resize-observer/style.css +1 -0
- package/search/index.mjs +143 -0
- package/search/style.css +1 -0
- package/search-popover/index.mjs +412 -0
- package/search-popover/style.css +1 -0
- package/sign/index.mjs +132 -0
- package/sign/style.css +1 -0
- package/sign-panel/index.mjs +255 -0
- package/sign-panel/style.css +1 -0
- package/skeleton/index.mjs +82 -0
- package/skeleton/style.css +1 -0
- package/split-pane/index.mjs +306 -0
- package/split-pane/style.css +1 -0
- package/stateful/index.mjs +84 -0
- package/stateful/style.css +1 -0
- package/static-pageable-table/index.mjs +92 -0
- package/static-pageable-table/style.css +1 -0
- package/swiper/index.mjs +183 -0
- package/swiper/style.css +1 -0
- package/tab/index.mjs +147 -0
- package/tab/style.css +1 -0
- package/tab-item/index.mjs +73 -0
- package/table-column/index.mjs +102 -0
- package/table-view/index.mjs +390 -0
- package/table-view/style.css +1 -0
- package/tag-render/index.mjs +116 -0
- package/tag-render/style.css +1 -0
- package/text-ellipsis/index.mjs +108 -0
- package/text-ellipsis/style.css +1 -0
- package/{dist/components/tinymce-wrapper/index.js → tinymce-editor/index.mjs} +479 -133
- package/tinymce-editor/style.css +1 -0
- package/toolbar/index.mjs +217 -0
- package/toolbar/style.css +1 -0
- package/toolbar-button/index.mjs +108 -0
- package/toolbar-button/style.css +1 -0
- package/verify/index.mjs +80 -0
- package/verify/style.css +1 -0
- package/vue-cron/index.mjs +1410 -0
- package/vue-cron/style.css +1 -0
- package/vue-qr-code/index.mjs +83 -0
- package/vue-quill-editor/index.mjs +117 -0
- package/vue-quill-editor/style.css +1 -0
- package/vue-tags-input/index.mjs +553 -0
- package/vue-tags-input/style.css +1 -0
- package/vue-tree-select/index.mjs +2881 -0
- package/vue-tree-select/style.css +1 -0
- package/vue-video-player/index.mjs +192 -0
- package/vue-video-player/style.css +1 -0
- package/watermark/index.mjs +95 -0
- package/watermark/style.css +1 -0
- package/web-types.json +14033 -2752
- package/x-input-tag/index.mjs +203 -0
- package/x-input-tag/style.css +1 -0
- package/README.md +0 -27
- package/dist/chunks/3d28cc08.js +0 -57
- package/dist/chunks/5d33812d.js +0 -147
- package/dist/chunks/9d848bf6.js +0 -99
- package/dist/chunks/a0bb327b.js +0 -96
- package/dist/chunks/a8891d2c.js +0 -30
- package/dist/chunks/c69d5628.js +0 -248
- package/dist/chunks/de9fe802.js +0 -24
- package/dist/chunks/e1939731.js +0 -17
- package/dist/components/address-input/index.js +0 -126
- package/dist/components/address-input/style.css +0 -15
- package/dist/components/aside-menu/index.js +0 -64
- package/dist/components/aside-menu/style.css +0 -9
- package/dist/components/awesome-button/index.js +0 -85
- package/dist/components/base.css +0 -66
- package/dist/components/capsule-tab/index.js +0 -58
- package/dist/components/capsule-tab/style.css +0 -32
- package/dist/components/chunk-file-uploader/index.js +0 -153
- package/dist/components/chunk-file-uploader/style.css +0 -4
- package/dist/components/chunk-file-uploader-button/index.js +0 -66
- package/dist/components/chunk-file-uploader-button/style.css +0 -17
- package/dist/components/chunk-file-uploader-drop/index.js +0 -79
- package/dist/components/chunk-file-uploader-drop/style.css +0 -12
- package/dist/components/chunk-file-uploader-file/index.js +0 -388
- package/dist/components/chunk-file-uploader-file/style.css +0 -125
- package/dist/components/chunk-file-uploader-files/index.js +0 -55
- package/dist/components/chunk-file-uploader-files/style.css +0 -9
- package/dist/components/chunk-file-uploader-list/index.js +0 -56
- package/dist/components/chunk-file-uploader-list/style.css +0 -9
- package/dist/components/chunk-file-uploader-un-support/index.js +0 -59
- package/dist/components/chunk-file-uploader-un-support/style.css +0 -6
- package/dist/components/code-mirror-editor/index.js +0 -338
- package/dist/components/code-mirror-editor/style.css +0 -17
- package/dist/components/color-picker/index.js +0 -129
- package/dist/components/confirm-button/index.js +0 -59
- package/dist/components/confirmable/index.js +0 -29
- package/dist/components/context-menu/index.js +0 -265
- package/dist/components/context-menu/style.css +0 -88
- package/dist/components/custom-scrollbar/index.js +0 -167
- package/dist/components/data-table-picker/index.js +0 -156
- package/dist/components/dynamic-table/index.js +0 -219
- package/dist/components/dynamic-table/style.css +0 -30
- package/dist/components/e-charts/index.js +0 -310
- package/dist/components/e-charts/style.css +0 -10
- package/dist/components/editable-progress/index.js +0 -174
- package/dist/components/editable-progress/style.css +0 -37
- package/dist/components/editable-tree/index.js +0 -1004
- package/dist/components/editable-tree/style.css +0 -82
- package/dist/components/egd-collapse/index.js +0 -92
- package/dist/components/egd-collapse-item/index.js +0 -148
- package/dist/components/element-dialog/index.js +0 -295
- package/dist/components/element-dialog/style.css +0 -102
- package/dist/components/empty-view/index.js +0 -75
- package/dist/components/empty-view/style.css +0 -17
- package/dist/components/error-view/index.js +0 -67
- package/dist/components/error-view/style.css +0 -17
- package/dist/components/flex-column/index.js +0 -65
- package/dist/components/flex-item/index.js +0 -94
- package/dist/components/flex-row/index.js +0 -65
- package/dist/components/flex-scroller/index.js +0 -53
- package/dist/components/flex-scroller/style.css +0 -20
- package/dist/components/form-button/index.js +0 -84
- package/dist/components/form-cascader/index.js +0 -161
- package/dist/components/form-checkbox-group/index.js +0 -217
- package/dist/components/form-checkbox-group/style.css +0 -51
- package/dist/components/form-date-picker/index.js +0 -244
- package/dist/components/form-holder/index.js +0 -97
- package/dist/components/form-input/index.js +0 -112
- package/dist/components/form-input-email/index.js +0 -109
- package/dist/components/form-input-id-card/index.js +0 -110
- package/dist/components/form-input-number/index.js +0 -130
- package/dist/components/form-input-number/style.css +0 -12
- package/dist/components/form-input-phone-number/index.js +0 -104
- package/dist/components/form-input-time/index.js +0 -130
- package/dist/components/form-item/index.js +0 -162
- package/dist/components/form-item/style.css +0 -11
- package/dist/components/form-item-config-provider/index.js +0 -64
- package/dist/components/form-item-group/index.js +0 -195
- package/dist/components/form-item-group/style.css +0 -30
- package/dist/components/form-radio-group/index.js +0 -189
- package/dist/components/form-radio-group/style.css +0 -53
- package/dist/components/form-select/index.js +0 -169
- package/dist/components/form-switch/index.js +0 -103
- package/dist/components/form-textarea/index.js +0 -108
- package/dist/components/form-view/index.js +0 -410
- package/dist/components/form-view/style.css +0 -158
- package/dist/components/guide-steps/index.js +0 -108
- package/dist/components/guide-steps/style.css +0 -34
- package/dist/components/icon-card/index.js +0 -68
- package/dist/components/icon-card/style.css +0 -56
- package/dist/components/iframe-window/index.js +0 -67
- package/dist/components/iframe-window/style.css +0 -20
- package/dist/components/image-viewer/index.js +0 -113
- package/dist/components/image-viewer/style.css +0 -21
- package/dist/components/input-number/index.js +0 -340
- package/dist/components/input-number/style.css +0 -15
- package/dist/components/input-number-range/index.js +0 -122
- package/dist/components/input-number-range/style.css +0 -12
- package/dist/components/keep-view-alive/index.js +0 -166
- package/dist/components/loading-view/index.js +0 -67
- package/dist/components/loading-view/style.css +0 -17
- package/dist/components/nav-bar/index.js +0 -62
- package/dist/components/nav-bar/style.css +0 -17
- package/dist/components/not-implement/index.js +0 -43
- package/dist/components/not-implement/style.css +0 -15
- package/dist/components/page/index.js +0 -46
- package/dist/components/page/style.css +0 -12
- package/dist/components/page-header/index.js +0 -62
- package/dist/components/page-header/style.css +0 -14
- package/dist/components/page-index/index.js +0 -172
- package/dist/components/page-index/style.css +0 -23
- package/dist/components/page-index-top/index.js +0 -134
- package/dist/components/page-skeleton/index.js +0 -62
- package/dist/components/page-skeleton/style.css +0 -23
- package/dist/components/page-skeleton-new/index.js +0 -104
- package/dist/components/page-skeleton-new/style.css +0 -42
- package/dist/components/pageable-table/index.js +0 -496
- package/dist/components/pageable-table/style.css +0 -72
- package/dist/components/pageable-view/index.js +0 -398
- package/dist/components/pageable-view/style.css +0 -69
- package/dist/components/photo-swipe/index.js +0 -228
- package/dist/components/photo-swipe/style.css +0 -20
- package/dist/components/resize-observer/index.js +0 -96
- package/dist/components/resize-observer/style.css +0 -31
- package/dist/components/search-popover/index.js +0 -449
- package/dist/components/search-popover/style.css +0 -93
- package/dist/components/sign-panel/index.js +0 -292
- package/dist/components/sign-panel/style.css +0 -97
- package/dist/components/split-pane/index.js +0 -270
- package/dist/components/split-pane/style.css +0 -100
- package/dist/components/stateful/index.js +0 -87
- package/dist/components/stateful/style.css +0 -33
- package/dist/components/static-pageable-table/index.js +0 -99
- package/dist/components/static-pageable-table/style.css +0 -9
- package/dist/components/swiper/index.js +0 -223
- package/dist/components/swiper/style.css +0 -43
- package/dist/components/tab/index.js +0 -163
- package/dist/components/tab/style.css +0 -122
- package/dist/components/tab-item/index.js +0 -78
- package/dist/components/table-column/index.js +0 -91
- package/dist/components/table-view/index.js +0 -434
- package/dist/components/table-view/style.css +0 -95
- package/dist/components/tag-render/index.js +0 -111
- package/dist/components/tag-render/style.css +0 -33
- package/dist/components/tinymce-editor/index.js +0 -189
- package/dist/components/tinymce-editor/style.css +0 -43
- package/dist/components/tinymce-wrapper/style.css +0 -36
- package/dist/components/toolbar/index.js +0 -238
- package/dist/components/toolbar/style.css +0 -39
- package/dist/components/toolbar-button/index.js +0 -97
- package/dist/components/toolbar-button/style.css +0 -21
- package/dist/components/trigger/index.js +0 -78
- package/dist/components/vue-tags-input/index.js +0 -559
- package/dist/components/vue-tags-input/style.css +0 -682
- package/dist/components/watermark/index.js +0 -75
- package/dist/components/watermark/style.css +0 -11
- package/dist/components/x-dialog/index.js +0 -199
- package/dist/components/x-dialog/style.css +0 -15
- package/dist/index.css +0 -2972
- package/dist/index.es.js +0 -15689
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
import { n } from "../chunks/vueComponentNormalizer.JwmUNtgn.mjs";
|
|
2
|
+
var o = function() {
|
|
3
|
+
var t = this, e = t.$createElement, i = t._self._c || e;
|
|
4
|
+
return i("div", {
|
|
5
|
+
staticClass: "sign-panel flex-column"
|
|
6
|
+
}, [i("div", {
|
|
7
|
+
directives: [{
|
|
8
|
+
name: "show",
|
|
9
|
+
rawName: "v-show",
|
|
10
|
+
value: !t.disabled && t.edit,
|
|
11
|
+
expression: "!disabled && edit"
|
|
12
|
+
}],
|
|
13
|
+
staticClass: "sign-edit"
|
|
14
|
+
}, [i("div", {
|
|
15
|
+
staticClass: "sign-draw-area",
|
|
16
|
+
style: {
|
|
17
|
+
width: `${t.width + 2}px`,
|
|
18
|
+
height: `${t.height + 2}px`
|
|
19
|
+
}
|
|
20
|
+
}, [i("div", {
|
|
21
|
+
staticClass: "sign-watermark",
|
|
22
|
+
style: {
|
|
23
|
+
fontSize: `${t.fontSize}px`
|
|
24
|
+
}
|
|
25
|
+
}, [t._v(" " + t._s(t.text) + " ")]), i("canvas", {
|
|
26
|
+
ref: "canvas",
|
|
27
|
+
staticClass: "sign-canvas",
|
|
28
|
+
attrs: {
|
|
29
|
+
width: t.width,
|
|
30
|
+
height: t.height
|
|
31
|
+
},
|
|
32
|
+
on: {
|
|
33
|
+
touchstart: function(s) {
|
|
34
|
+
return s.stopPropagation(), t.touchstart.apply(null, arguments);
|
|
35
|
+
},
|
|
36
|
+
touchmove: function(s) {
|
|
37
|
+
return s.stopPropagation(), t.touchmove.apply(null, arguments);
|
|
38
|
+
},
|
|
39
|
+
mousedown: function(s) {
|
|
40
|
+
return s.stopPropagation(), t.down.apply(null, arguments);
|
|
41
|
+
},
|
|
42
|
+
touchend: function(s) {
|
|
43
|
+
return s.stopPropagation(), t.touchend.apply(null, arguments);
|
|
44
|
+
},
|
|
45
|
+
mouseup: function(s) {
|
|
46
|
+
return s.stopPropagation(), t.up.apply(null, arguments);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}, [t._v("当前浏览器不支持手写签名 ")])]), i("div", {
|
|
50
|
+
staticClass: "sign-tool-bar"
|
|
51
|
+
}, [i("div", {
|
|
52
|
+
staticClass: "sign-button flex-item",
|
|
53
|
+
staticStyle: {
|
|
54
|
+
color: "red"
|
|
55
|
+
},
|
|
56
|
+
on: {
|
|
57
|
+
click: t.clear
|
|
58
|
+
}
|
|
59
|
+
}, [i("i", {
|
|
60
|
+
staticClass: "fa fa-trash"
|
|
61
|
+
}), t._v(" 清除 ")]), i("div", {
|
|
62
|
+
staticClass: "sign-button flex-item",
|
|
63
|
+
staticStyle: {
|
|
64
|
+
color: "red"
|
|
65
|
+
},
|
|
66
|
+
on: {
|
|
67
|
+
click: t.cancel
|
|
68
|
+
}
|
|
69
|
+
}, [i("i", {
|
|
70
|
+
staticClass: "fa fa-close"
|
|
71
|
+
}), t._v(" 取消 ")]), i("div", {
|
|
72
|
+
staticClass: "sign-button flex-item",
|
|
73
|
+
staticStyle: {
|
|
74
|
+
color: "orange"
|
|
75
|
+
},
|
|
76
|
+
on: {
|
|
77
|
+
click: t.rollback
|
|
78
|
+
}
|
|
79
|
+
}, [i("i", {
|
|
80
|
+
staticClass: "fa fa-repeat"
|
|
81
|
+
}), t._v(" 撤销 ")]), i("div", {
|
|
82
|
+
staticClass: "sign-button flex-item",
|
|
83
|
+
staticStyle: {
|
|
84
|
+
color: "green"
|
|
85
|
+
},
|
|
86
|
+
on: {
|
|
87
|
+
click: t.save
|
|
88
|
+
}
|
|
89
|
+
}, [i("i", {
|
|
90
|
+
staticClass: "fa fa-check"
|
|
91
|
+
}), t._v(" 确定 ")])])]), i("div", {
|
|
92
|
+
directives: [{
|
|
93
|
+
name: "show",
|
|
94
|
+
rawName: "v-show",
|
|
95
|
+
value: t.disabled || !t.edit,
|
|
96
|
+
expression: "disabled || !edit"
|
|
97
|
+
}],
|
|
98
|
+
staticClass: "sign-view",
|
|
99
|
+
style: {
|
|
100
|
+
cursor: t.disabled ? "not-allowed" : "pointer"
|
|
101
|
+
},
|
|
102
|
+
on: {
|
|
103
|
+
click: t.showSign
|
|
104
|
+
}
|
|
105
|
+
}, [t.value ? i("img", {
|
|
106
|
+
staticClass: "sign-image",
|
|
107
|
+
attrs: {
|
|
108
|
+
src: t.value,
|
|
109
|
+
alt: "签名"
|
|
110
|
+
}
|
|
111
|
+
}) : t._e(), t.value ? t._e() : i("p", {
|
|
112
|
+
staticClass: "sign-tips",
|
|
113
|
+
style: {
|
|
114
|
+
color: !t.value && t.disabled ? "red" : ""
|
|
115
|
+
}
|
|
116
|
+
}, [t._v(" " + t._s(t.disabled ? "未签名" : "点击进行签名") + " ")]), t.disabled ? t._e() : i("i", {
|
|
117
|
+
staticClass: "el-icon-edit-outline sign-edit-icon"
|
|
118
|
+
})])]);
|
|
119
|
+
}, c = [];
|
|
120
|
+
const l = {
|
|
121
|
+
name: "SignPanel",
|
|
122
|
+
props: {
|
|
123
|
+
width: {
|
|
124
|
+
type: Number,
|
|
125
|
+
default: 400
|
|
126
|
+
},
|
|
127
|
+
height: {
|
|
128
|
+
type: Number,
|
|
129
|
+
default: 150
|
|
130
|
+
},
|
|
131
|
+
lineWidth: {
|
|
132
|
+
type: Number,
|
|
133
|
+
default: 1
|
|
134
|
+
},
|
|
135
|
+
text: {
|
|
136
|
+
type: String,
|
|
137
|
+
default: "签名区"
|
|
138
|
+
},
|
|
139
|
+
fontSize: {
|
|
140
|
+
type: Number,
|
|
141
|
+
default: 20
|
|
142
|
+
},
|
|
143
|
+
value: {
|
|
144
|
+
type: String
|
|
145
|
+
},
|
|
146
|
+
disabled: Boolean
|
|
147
|
+
},
|
|
148
|
+
data() {
|
|
149
|
+
return {
|
|
150
|
+
edit: !1
|
|
151
|
+
};
|
|
152
|
+
},
|
|
153
|
+
mounted() {
|
|
154
|
+
this.init();
|
|
155
|
+
},
|
|
156
|
+
methods: {
|
|
157
|
+
// 初始化
|
|
158
|
+
init() {
|
|
159
|
+
if (this.stack = [], this.canvas = this.$refs.canvas, !this.canvas.getContext) {
|
|
160
|
+
alert("当前浏览器不支持手写签名");
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
163
|
+
this.canvasInit();
|
|
164
|
+
},
|
|
165
|
+
rollback() {
|
|
166
|
+
if (this.stack.length > 0) {
|
|
167
|
+
const t = this.stack[this.stack.length - 1];
|
|
168
|
+
this.ctx.putImageData(t, 0, 0), this.stack.length = this.stack.length - 1;
|
|
169
|
+
}
|
|
170
|
+
},
|
|
171
|
+
// 位置初始化
|
|
172
|
+
position() {
|
|
173
|
+
this.restorePoint = this.ctx.getImageData(0, 0, this.canvas.width, this.canvas.height);
|
|
174
|
+
const t = this.canvas.getBoundingClientRect();
|
|
175
|
+
this.start = t.left, this.end = t.top;
|
|
176
|
+
},
|
|
177
|
+
// 画布初始化
|
|
178
|
+
canvasInit() {
|
|
179
|
+
this.ctx = this.canvas.getContext("2d"), this.ctx.lineCap = "round", this.ctx.lineWidth = this.lineWidth, this.ctx.clearRect(0, 0, this.width, this.height), this.blank = this.canvas.toDataURL("image/png");
|
|
180
|
+
},
|
|
181
|
+
/**
|
|
182
|
+
* 绘制水印
|
|
183
|
+
*/
|
|
184
|
+
drawWaterMark() {
|
|
185
|
+
this.ctx.font = `${this.fontSize}px bold 黑体`, this.ctx.fillStyle = "#eee", this.ctx.textAlign = "center", this.ctx.shadowBlur = 1, this.ctx.textBaseline = "middle", this.ctx.fillText(this.text, this.width / 2, this.height / 2);
|
|
186
|
+
},
|
|
187
|
+
// PC 端鼠标按下开始绘画
|
|
188
|
+
down(t) {
|
|
189
|
+
this.position(), this.startLine(t.clientX, t.clientY, t), this.target = t.target, this.target.addEventListener("mousemove", this.move), window.addEventListener("mouseup", this.up);
|
|
190
|
+
},
|
|
191
|
+
// PC 端鼠标按下开始绘画后,跟踪移动轨迹
|
|
192
|
+
move(t) {
|
|
193
|
+
this.moveLine(t.clientX, t.clientY, t);
|
|
194
|
+
},
|
|
195
|
+
// PC 端鼠标松开结束绘画
|
|
196
|
+
up() {
|
|
197
|
+
this.target && this.target.removeEventListener("mousemove", this.move), window.removeEventListener("mouseup", this.up), this.record();
|
|
198
|
+
},
|
|
199
|
+
// 移动端触摸开始绘画
|
|
200
|
+
touchstart(t) {
|
|
201
|
+
this.position(), this.startLine(t.changedTouches[0].clientX, t.changedTouches[0].clientY, t);
|
|
202
|
+
},
|
|
203
|
+
// 移动端触摸开始绘画后,跟踪滑动轨迹
|
|
204
|
+
touchmove(t) {
|
|
205
|
+
this.moveLine(t.touches[0].clientX, t.touches[0].clientY, t);
|
|
206
|
+
},
|
|
207
|
+
// 开始绘画
|
|
208
|
+
startLine(t, e) {
|
|
209
|
+
this.ctx.beginPath(), t -= this.start, e -= this.end, this.ctx.moveTo(t, e);
|
|
210
|
+
},
|
|
211
|
+
// 绘制移动轨迹
|
|
212
|
+
moveLine(t, e, i) {
|
|
213
|
+
i && i.preventDefault(), t -= this.start, e -= this.end, this.ctx.lineTo(t, e), this.ctx.stroke();
|
|
214
|
+
},
|
|
215
|
+
clear() {
|
|
216
|
+
this.ctx.clearRect(0, 0, this.width, this.height);
|
|
217
|
+
},
|
|
218
|
+
cancel() {
|
|
219
|
+
this.clear(), this.edit = !1;
|
|
220
|
+
},
|
|
221
|
+
touchend() {
|
|
222
|
+
this.record();
|
|
223
|
+
},
|
|
224
|
+
record() {
|
|
225
|
+
this.stack.push(this.restorePoint);
|
|
226
|
+
},
|
|
227
|
+
save() {
|
|
228
|
+
const t = this.canvas.toDataURL("image/png");
|
|
229
|
+
this.blank === t ? this.$emit("input", "") : this.$emit("input", t), this.edit = !1, this.stack.length = 0, this.ctx.clearRect(0, 0, this.width, this.height);
|
|
230
|
+
},
|
|
231
|
+
showSign() {
|
|
232
|
+
this.disabled || (this.edit = !0);
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}, a = {};
|
|
236
|
+
var h = /* @__PURE__ */ n(
|
|
237
|
+
l,
|
|
238
|
+
o,
|
|
239
|
+
c,
|
|
240
|
+
!1,
|
|
241
|
+
r,
|
|
242
|
+
null,
|
|
243
|
+
null,
|
|
244
|
+
null
|
|
245
|
+
);
|
|
246
|
+
function r(t) {
|
|
247
|
+
for (let e in a)
|
|
248
|
+
this[e] = a[e];
|
|
249
|
+
}
|
|
250
|
+
const u = /* @__PURE__ */ function() {
|
|
251
|
+
return h.exports;
|
|
252
|
+
}();
|
|
253
|
+
export {
|
|
254
|
+
u as default
|
|
255
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.sign-panel{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:#fff;justify-content:center;align-items:flex-start;width:100%}.sign-panel .sign-canvas{background:rgba(255,255,155,0);border:1px solid #ccc;width:100%;max-width:100%;height:100%;position:absolute;top:0;bottom:0;left:0;right:0}.sign-panel .sign-tool-bar{border:1px solid #ccc;border-top:none;width:100%;display:flex}.sign-panel .sign-tips{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none}.sign-panel .sign-button{text-align:center;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:#ebeef5;padding:6px;line-height:1.6}.sign-panel .sign-button:hover{color:#1989fa;background-color:#d0d4de}.sign-panel .sign-button:nth-child(n){border-right:1px solid #ccc}.sign-panel .sign-button:last-child{border:none!important}.sign-panel .sign-watermark{color:#eee;justify-content:center;align-items:center;width:100%;height:100%;display:flex;position:absolute;top:0;bottom:0;left:0;right:0}.sign-panel .sign-view{background-color:#fff;border:1px solid #eee;justify-content:center;align-items:center;min-width:212px;height:80px;display:flex;position:relative}.sign-panel .sign-edit-icon{position:absolute;bottom:4px;right:4px}.sign-panel .sign-image{min-width:160px;height:80px;display:inline-block}.sign-panel .sign-edit{background-color:#fff;flex-direction:column;align-items:center;max-width:100%;display:flex}.sign-panel .sign-draw-area{max-width:100%;position:relative}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { n as o } from "../chunks/vueComponentNormalizer.JwmUNtgn.mjs";
|
|
2
|
+
var r = function() {
|
|
3
|
+
var e = this, a = e.$createElement, t = e._self._c || a;
|
|
4
|
+
return t("div", {
|
|
5
|
+
staticClass: "avue-skeleton"
|
|
6
|
+
}, [e.loading ? e._l(e.number, function(m, n) {
|
|
7
|
+
return t("div", {
|
|
8
|
+
key: n,
|
|
9
|
+
staticClass: "avue-skeleton__item"
|
|
10
|
+
}, [t("div", {
|
|
11
|
+
staticClass: "avue-skeleton__header"
|
|
12
|
+
}, [e.avatar ? t("span", {
|
|
13
|
+
staticClass: "avue-skeleton__vatar'),className]"
|
|
14
|
+
}) : e._e()]), t("div", {
|
|
15
|
+
staticClass: "avue-skeleton__content"
|
|
16
|
+
}, [t("h3", {
|
|
17
|
+
class: ["avue-skeleton__title", e.className]
|
|
18
|
+
}), t("div", {
|
|
19
|
+
staticClass: "avue-skeleton__list"
|
|
20
|
+
}, e._l(e.rows, function(d, l) {
|
|
21
|
+
return t("p", {
|
|
22
|
+
key: l,
|
|
23
|
+
class: ["avue-skeleton__li", e.className],
|
|
24
|
+
style: e.styleName
|
|
25
|
+
});
|
|
26
|
+
}), 0)])]);
|
|
27
|
+
}) : t("div", [e._t("default")], 2)], 2);
|
|
28
|
+
}, i = [];
|
|
29
|
+
const u = "avue-skeleton", c = {
|
|
30
|
+
name: "Skeleton",
|
|
31
|
+
props: {
|
|
32
|
+
loading: {
|
|
33
|
+
type: Boolean,
|
|
34
|
+
default: !0
|
|
35
|
+
},
|
|
36
|
+
avatar: Boolean,
|
|
37
|
+
active: {
|
|
38
|
+
type: Boolean,
|
|
39
|
+
default: !0
|
|
40
|
+
},
|
|
41
|
+
block: Boolean,
|
|
42
|
+
number: {
|
|
43
|
+
type: Number,
|
|
44
|
+
default: 1
|
|
45
|
+
},
|
|
46
|
+
rows: {
|
|
47
|
+
type: Number,
|
|
48
|
+
default: 3
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
computed: {
|
|
52
|
+
styleName() {
|
|
53
|
+
return this.block ? {
|
|
54
|
+
width: "100%"
|
|
55
|
+
} : {};
|
|
56
|
+
},
|
|
57
|
+
className() {
|
|
58
|
+
const { active: e } = this;
|
|
59
|
+
return { [`${u}__loading`]: e };
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}, s = {};
|
|
63
|
+
var _ = /* @__PURE__ */ o(
|
|
64
|
+
c,
|
|
65
|
+
r,
|
|
66
|
+
i,
|
|
67
|
+
!1,
|
|
68
|
+
v,
|
|
69
|
+
null,
|
|
70
|
+
null,
|
|
71
|
+
null
|
|
72
|
+
);
|
|
73
|
+
function v(e) {
|
|
74
|
+
for (let a in s)
|
|
75
|
+
this[a] = s[a];
|
|
76
|
+
}
|
|
77
|
+
const p = /* @__PURE__ */ function() {
|
|
78
|
+
return _.exports;
|
|
79
|
+
}();
|
|
80
|
+
export {
|
|
81
|
+
p as default
|
|
82
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.avue-skeleton__avatar{background:#f2f2f2;border-radius:50%;width:40px;height:40px;line-height:40px;display:inline-block}.avue-skeleton__header{vertical-align:top;padding-right:16px;display:table-cell}.avue-skeleton__content{vertical-align:top;width:100%;display:table-cell}.avue-skeleton__title{background:#f2f2f2;width:40%;height:16px;margin-top:16px}.avue-skeleton__item{border-bottom:1px solid #e8e8e8;padding-top:16px;padding-bottom:16px}.avue-skeleton__item:last-child{border-bottom:none}.avue-skeleton__li{background:#f2f2f2;width:100%;height:16px;margin-bottom:10px;list-style:none}.avue-skeleton__li:last-child{width:50%}.avue-skeleton__loading{background:linear-gradient(90deg,#f2f2f2 25%,#e6e6e6 37%,#f2f2f2 63%) 0 0/400% 100%;animation:1.4s infinite avue-skeleton-loading}@keyframes avue-skeleton-loading{0%{background-position:100%}to{background-position:0}}
|
|
@@ -0,0 +1,306 @@
|
|
|
1
|
+
var l = (t, e, s) => new Promise((o, i) => {
|
|
2
|
+
var n = (r) => {
|
|
3
|
+
try {
|
|
4
|
+
a(s.next(r));
|
|
5
|
+
} catch (f) {
|
|
6
|
+
i(f);
|
|
7
|
+
}
|
|
8
|
+
}, g = (r) => {
|
|
9
|
+
try {
|
|
10
|
+
a(s.throw(r));
|
|
11
|
+
} catch (f) {
|
|
12
|
+
i(f);
|
|
13
|
+
}
|
|
14
|
+
}, a = (r) => r.done ? o(r.value) : Promise.resolve(r.value).then(n, g);
|
|
15
|
+
a((s = s.apply(t, e)).next());
|
|
16
|
+
});
|
|
17
|
+
import { n as d } from "../chunks/vueComponentNormalizer.JwmUNtgn.mjs";
|
|
18
|
+
import v from "@web-utils/component/resize-observer";
|
|
19
|
+
import "@web-utils/component/resize-observer/style.css";
|
|
20
|
+
function m(t, e) {
|
|
21
|
+
for (let s = 0; s < e.length; s++)
|
|
22
|
+
if (t === e[s])
|
|
23
|
+
return !0;
|
|
24
|
+
return !1;
|
|
25
|
+
}
|
|
26
|
+
const h = function() {
|
|
27
|
+
return document.addEventListener ? function(t, e, s) {
|
|
28
|
+
t && e && s && t.addEventListener(e, s, !1);
|
|
29
|
+
} : function(t, e, s) {
|
|
30
|
+
t && e && s && t.attachEvent(`on${e}`, s);
|
|
31
|
+
};
|
|
32
|
+
}(), p = function() {
|
|
33
|
+
return document.removeEventListener ? function(t, e, s) {
|
|
34
|
+
t && e && t.removeEventListener(e, s, !1);
|
|
35
|
+
} : function(t, e, s) {
|
|
36
|
+
t && e && t.detachEvent(`on${e}`, s);
|
|
37
|
+
};
|
|
38
|
+
}();
|
|
39
|
+
var x = function() {
|
|
40
|
+
var t = this, e = t.$createElement, s = t._self._c || e;
|
|
41
|
+
return s("div", {
|
|
42
|
+
class: t.classes
|
|
43
|
+
}, [t.showIcon ? s("div", {
|
|
44
|
+
class: t.barConClasses
|
|
45
|
+
}, t._m(0), 0) : t._e()]);
|
|
46
|
+
}, $ = [function() {
|
|
47
|
+
var t = this, e = t.$createElement, s = t._self._c || e;
|
|
48
|
+
return t._l(8, function(o) {
|
|
49
|
+
return s("i", {
|
|
50
|
+
key: `trigger-${o}`,
|
|
51
|
+
class: `${t.prefix}-bar`
|
|
52
|
+
});
|
|
53
|
+
});
|
|
54
|
+
}];
|
|
55
|
+
const _ = {
|
|
56
|
+
name: "Trigger",
|
|
57
|
+
props: {
|
|
58
|
+
mode: String,
|
|
59
|
+
showIcon: Boolean,
|
|
60
|
+
line: {
|
|
61
|
+
type: Boolean,
|
|
62
|
+
default: !0
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
data() {
|
|
66
|
+
return {
|
|
67
|
+
prefix: "egd-split-trigger"
|
|
68
|
+
};
|
|
69
|
+
},
|
|
70
|
+
computed: {
|
|
71
|
+
isVertical() {
|
|
72
|
+
return this.mode === "vertical";
|
|
73
|
+
},
|
|
74
|
+
classes() {
|
|
75
|
+
return [
|
|
76
|
+
this.prefix,
|
|
77
|
+
this.line ? this.isVertical ? ` ${this.prefix}-vertical-line` : `${this.prefix}-horizontal-line` : "",
|
|
78
|
+
this.isVertical ? `${this.prefix}-vertical` : `${this.prefix}-horizontal`
|
|
79
|
+
];
|
|
80
|
+
},
|
|
81
|
+
barConClasses() {
|
|
82
|
+
return [
|
|
83
|
+
`${this.prefix}-bar-con`,
|
|
84
|
+
this.isVertical ? "vertical" : "horizontal"
|
|
85
|
+
];
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}, u = {};
|
|
89
|
+
var M = /* @__PURE__ */ d(
|
|
90
|
+
_,
|
|
91
|
+
x,
|
|
92
|
+
$,
|
|
93
|
+
!1,
|
|
94
|
+
z,
|
|
95
|
+
null,
|
|
96
|
+
null,
|
|
97
|
+
null
|
|
98
|
+
);
|
|
99
|
+
function z(t) {
|
|
100
|
+
for (let e in u)
|
|
101
|
+
this[e] = u[e];
|
|
102
|
+
}
|
|
103
|
+
const O = /* @__PURE__ */ function() {
|
|
104
|
+
return M.exports;
|
|
105
|
+
}();
|
|
106
|
+
var w = function() {
|
|
107
|
+
var t = this, e = t.$createElement, s = t._self._c || e;
|
|
108
|
+
return s("div", {
|
|
109
|
+
ref: "outerWrapper",
|
|
110
|
+
class: t.wrapperClasses
|
|
111
|
+
}, [t.isHorizontal ? s("div", {
|
|
112
|
+
class: `${t.prefix}-horizontal`
|
|
113
|
+
}, [t.hideLeft ? s("div", {
|
|
114
|
+
class: [`${t.prefix}-pane`, "right-pane"],
|
|
115
|
+
staticStyle: {
|
|
116
|
+
left: "0"
|
|
117
|
+
}
|
|
118
|
+
}, [t._t("right")], 2) : [s("div", {
|
|
119
|
+
class: [`${t.prefix}-pane`, "left-pane"],
|
|
120
|
+
style: {
|
|
121
|
+
right: `${t.anotherOffset}%`
|
|
122
|
+
}
|
|
123
|
+
}, [t._t("left")], 2), s("div", {
|
|
124
|
+
class: `${t.prefix}-trigger-con`,
|
|
125
|
+
style: {
|
|
126
|
+
left: `calc(${t.offset}% + ${t.triggerSize / 2}px)`,
|
|
127
|
+
width: `${t.triggerSize}px`
|
|
128
|
+
},
|
|
129
|
+
on: {
|
|
130
|
+
mousedown: t.handleMousedown
|
|
131
|
+
}
|
|
132
|
+
}, [t._t("trigger", function() {
|
|
133
|
+
return [s("Trigger", {
|
|
134
|
+
attrs: {
|
|
135
|
+
mode: "vertical"
|
|
136
|
+
}
|
|
137
|
+
})];
|
|
138
|
+
})], 2), s("div", {
|
|
139
|
+
class: [`${t.prefix}-pane`, "right-pane"],
|
|
140
|
+
style: {
|
|
141
|
+
left: `calc(${t.offset}% + ${t.triggerSize}px)`
|
|
142
|
+
}
|
|
143
|
+
}, [t._t("right")], 2)]], 2) : s("div", {
|
|
144
|
+
class: `${t.prefix}-vertical`
|
|
145
|
+
}, [s("div", {
|
|
146
|
+
class: [`${t.prefix}-pane`, "top-pane"],
|
|
147
|
+
style: {
|
|
148
|
+
bottom: `${t.anotherOffset}%`
|
|
149
|
+
}
|
|
150
|
+
}, [t._t("top")], 2), s("div", {
|
|
151
|
+
class: `${t.prefix}-trigger-con`,
|
|
152
|
+
style: {
|
|
153
|
+
top: `calc(${t.offset}% + ${t.triggerSize / 2}px)`,
|
|
154
|
+
height: `${t.triggerSize}px`
|
|
155
|
+
},
|
|
156
|
+
on: {
|
|
157
|
+
mousedown: t.handleMousedown
|
|
158
|
+
}
|
|
159
|
+
}, [t._t("trigger", function() {
|
|
160
|
+
return [s("Trigger", {
|
|
161
|
+
attrs: {
|
|
162
|
+
mode: "horizontal"
|
|
163
|
+
}
|
|
164
|
+
})];
|
|
165
|
+
})], 2), s("div", {
|
|
166
|
+
class: [`${t.prefix}-pane`, "bottom-pane"],
|
|
167
|
+
style: {
|
|
168
|
+
top: `calc(${t.offset}% + ${t.triggerSize}px)`
|
|
169
|
+
}
|
|
170
|
+
}, [t._t("bottom")], 2)]), s("ResizeObserver", {
|
|
171
|
+
on: {
|
|
172
|
+
notify: t.resetOffset
|
|
173
|
+
}
|
|
174
|
+
})], 1);
|
|
175
|
+
}, S = [];
|
|
176
|
+
const F = {
|
|
177
|
+
name: "SplitPane",
|
|
178
|
+
components: {
|
|
179
|
+
Trigger: O,
|
|
180
|
+
ResizeObserver: v
|
|
181
|
+
},
|
|
182
|
+
props: {
|
|
183
|
+
value: {
|
|
184
|
+
type: [Number, String],
|
|
185
|
+
default: 0.5
|
|
186
|
+
},
|
|
187
|
+
mode: {
|
|
188
|
+
validator(t) {
|
|
189
|
+
return m(t, ["horizontal", "vertical"]);
|
|
190
|
+
},
|
|
191
|
+
default: "horizontal"
|
|
192
|
+
},
|
|
193
|
+
hideLeft: Boolean,
|
|
194
|
+
triggerSize: {
|
|
195
|
+
type: Number,
|
|
196
|
+
default: 6
|
|
197
|
+
},
|
|
198
|
+
min: {
|
|
199
|
+
type: [Number, String],
|
|
200
|
+
default: "40px"
|
|
201
|
+
},
|
|
202
|
+
max: {
|
|
203
|
+
type: [Number, String],
|
|
204
|
+
default: "40px"
|
|
205
|
+
}
|
|
206
|
+
},
|
|
207
|
+
/**
|
|
208
|
+
* Events
|
|
209
|
+
* @on-move-start
|
|
210
|
+
* @on-moving 返回值:事件对象,但是在事件对象中加入了两个参数:atMin(当前是否在最小值处), atMax(当前是否在最大值处)
|
|
211
|
+
* @on-move-end
|
|
212
|
+
*/
|
|
213
|
+
data() {
|
|
214
|
+
return {
|
|
215
|
+
prefix: "egd-split",
|
|
216
|
+
offset: 0,
|
|
217
|
+
oldOffset: 0,
|
|
218
|
+
isMoving: !1
|
|
219
|
+
};
|
|
220
|
+
},
|
|
221
|
+
computed: {
|
|
222
|
+
wrapperClasses() {
|
|
223
|
+
return [`${this.prefix}-wrapper`, this.isMoving ? "no-select" : ""];
|
|
224
|
+
},
|
|
225
|
+
isHorizontal() {
|
|
226
|
+
return this.mode === "horizontal";
|
|
227
|
+
},
|
|
228
|
+
anotherOffset() {
|
|
229
|
+
return 100 - this.offset;
|
|
230
|
+
},
|
|
231
|
+
valueIsPx() {
|
|
232
|
+
return typeof this.value == "string";
|
|
233
|
+
},
|
|
234
|
+
offsetSize() {
|
|
235
|
+
return this.isHorizontal ? "offsetWidth" : "offsetHeight";
|
|
236
|
+
},
|
|
237
|
+
computedMin() {
|
|
238
|
+
return this.getComputedThresholdValue("min");
|
|
239
|
+
},
|
|
240
|
+
computedMax() {
|
|
241
|
+
return this.getComputedThresholdValue("max");
|
|
242
|
+
}
|
|
243
|
+
},
|
|
244
|
+
watch: {
|
|
245
|
+
value: "resetOffset"
|
|
246
|
+
},
|
|
247
|
+
mounted() {
|
|
248
|
+
return l(this, null, function* () {
|
|
249
|
+
yield this.$nextTick(), this.resetOffset();
|
|
250
|
+
});
|
|
251
|
+
},
|
|
252
|
+
methods: {
|
|
253
|
+
resetOffset() {
|
|
254
|
+
this.offset = (this.valueIsPx ? this.px2percent(this.value, this.$refs.outerWrapper[this.offsetSize]) : this.value) * 1e4 / 100;
|
|
255
|
+
},
|
|
256
|
+
px2percent(t, e) {
|
|
257
|
+
return parseFloat(t) / parseFloat(e);
|
|
258
|
+
},
|
|
259
|
+
getComputedThresholdValue(t) {
|
|
260
|
+
const e = this.$refs.outerWrapper[this.offsetSize];
|
|
261
|
+
return this.valueIsPx ? typeof this[t] == "string" ? this[t] : e * this[t] : typeof this[t] == "string" ? this.px2percent(this[t], e) : this[t];
|
|
262
|
+
},
|
|
263
|
+
getMin(t, e) {
|
|
264
|
+
return this.valueIsPx ? `${Math.min(parseFloat(t), parseFloat(e))}px` : Math.min(t, e);
|
|
265
|
+
},
|
|
266
|
+
getMax(t, e) {
|
|
267
|
+
return this.valueIsPx ? `${Math.max(parseFloat(t), parseFloat(e))}px` : Math.max(t, e);
|
|
268
|
+
},
|
|
269
|
+
getAnotherOffset(t) {
|
|
270
|
+
let e = 0;
|
|
271
|
+
return this.valueIsPx ? e = `${this.$refs.outerWrapper[this.offsetSize] - parseFloat(t)}px` : e = 1 - t, e;
|
|
272
|
+
},
|
|
273
|
+
handleMove(t) {
|
|
274
|
+
const s = (this.isHorizontal ? t.pageX : t.pageY) - this.initOffset, o = this.$refs.outerWrapper[this.offsetSize];
|
|
275
|
+
let i = this.valueIsPx ? `${parseFloat(this.oldOffset) + s}px` : this.px2percent(o * this.oldOffset + s, o);
|
|
276
|
+
const n = this.getAnotherOffset(i);
|
|
277
|
+
parseFloat(i) <= parseFloat(this.computedMin) && (i = this.getMax(i, this.computedMin)), parseFloat(n) <= parseFloat(this.computedMax) && (i = this.getAnotherOffset(this.getMax(n, this.computedMax))), t.atMin = this.value === this.computedMin, t.atMax = this.valueIsPx ? this.getAnotherOffset(this.value) === this.computedMax : this.getAnotherOffset(this.value).toFixed(5) === this.computedMax.toFixed(5), this.$emit("input", i), this.$emit("on-moving", t);
|
|
278
|
+
},
|
|
279
|
+
handleUp() {
|
|
280
|
+
this.isMoving = !1, p(window, "mousemove", this.handleMove), p(window, "mouseup", this.handleUp), this.$emit("on-move-end");
|
|
281
|
+
},
|
|
282
|
+
handleMousedown(t) {
|
|
283
|
+
this.initOffset = this.isHorizontal ? t.pageX : t.pageY, this.oldOffset = this.value, this.isMoving = !0, h(window, "mousemove", this.handleMove), h(window, "mouseup", this.handleUp), this.$emit("on-move-start");
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
}, c = {};
|
|
287
|
+
var y = /* @__PURE__ */ d(
|
|
288
|
+
F,
|
|
289
|
+
w,
|
|
290
|
+
S,
|
|
291
|
+
!1,
|
|
292
|
+
b,
|
|
293
|
+
null,
|
|
294
|
+
null,
|
|
295
|
+
null
|
|
296
|
+
);
|
|
297
|
+
function b(t) {
|
|
298
|
+
for (let e in c)
|
|
299
|
+
this[e] = c[e];
|
|
300
|
+
}
|
|
301
|
+
const T = /* @__PURE__ */ function() {
|
|
302
|
+
return y.exports;
|
|
303
|
+
}();
|
|
304
|
+
export {
|
|
305
|
+
T as default
|
|
306
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.egd-split-wrapper{width:100%;height:100%;position:relative}.egd-split-pane{position:absolute}.egd-split-pane.left-pane,.egd-split-pane.right-pane{top:0;bottom:0}.egd-split-pane.left-pane{left:0}.egd-split-pane.right-pane{right:0}.egd-split-pane.top-pane,.egd-split-pane.bottom-pane{left:0;right:0}.egd-split-pane.top-pane{top:0}.egd-split-pane.bottom-pane{bottom:0}.egd-split-trigger-con{z-index:10;position:absolute;transform:translate(-50%,-50%)}.egd-split-trigger-bar-con{position:absolute;overflow:hidden}.egd-split-trigger-bar-con.vertical{height:32px;top:50%;left:1px;transform:translateY(-50%)}.egd-split-trigger-bar-con.horizontal{width:32px;top:1px;left:50%;transform:translate(-50%)}.egd-split-trigger-vertical{cursor:ew-resize;background:#f8f8f9;width:6px;height:100%;box-shadow:0 0 4px rgba(28,36,56,.4)}.egd-split-trigger-vertical .egd-split-trigger-bar{float:left;background:rgba(23,35,61,.25);width:4px;height:1px;margin-top:3px}.egd-split-trigger-horizontal{cursor:ns-resize;background:#f8f8f9;width:100%;height:6px;box-shadow:0 0 4px rgba(28,36,56,.4)}.egd-split-trigger-horizontal .egd-split-trigger-bar{float:left;background:rgba(23,35,61,.25);width:1px;height:4px;margin-right:3px}.egd-split-horizontal .egd-split-trigger-con{border-right:1px solid #d7dae0;height:100%;top:50%}.egd-split-vertical .egd-split-trigger-con{border-bottom:1px solid #d7dae0;width:100%;left:50%}.egd-split-trigger-vertical-line,.egd-split-trigger-horizontal-line{box-shadow:none;background-color:transparent}.egd-split .no-select{-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}
|