@web-utils/component 5.0.0-beta03 → 5.0.0-beta04
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/chunks/DialogForm.BzmXN481.mjs +37816 -0
- package/chunks/ElementDialog.BrqPs1yL.mjs +198 -0
- package/chunks/FormTemp.DWB4CV8h.mjs +251 -0
- package/chunks/FyButton.DGd1yE_h.mjs +27 -0
- package/chunks/{FyCurd.DqJuCLNW.mjs → FyCurd.DmIW6Tjw.mjs} +490 -483
- package/chunks/{FyForm.CgyGhetD.mjs → FyForm.Dh77gj0Z.mjs} +149 -149
- package/chunks/{FyUEditor.uvZS8UgS.mjs → FyUEditor.BMGigcYw.mjs} +7 -7
- package/chunks/{FyUpload.DoBEuYcC.mjs → FyUpload.Y_mVdD0K.mjs} +77 -77
- package/chunks/{MonacoEditor.Bq9d6JSz.mjs → MonacoEditor.DQ1vPh6D.mjs} +8 -8
- package/chunks/dataformat.BpAzVPYN.mjs +165 -0
- package/chunks/{dic.NZCGhtA7.mjs → dic.N2PNjL8o.mjs} +1 -1
- package/chunks/{event.CmOTnori.mjs → event.BevSLXu4.mjs} +8 -9
- package/chunks/{util.g-WQEec9.mjs → util.Cdt7t08t.mjs} +35 -50
- package/dialog/index.d.ts +14 -0
- package/dialog/props.d.ts +101 -0
- package/dialog-form/index.mjs +2 -145
- package/element-dialog/index.mjs +1 -1
- package/element-dialog/style.css +1 -1
- package/fy-array/index.mjs +7 -7
- package/fy-button/index.mjs +2 -0
- package/fy-button/style.css +1 -0
- package/fy-cascader/index.mjs +2 -2
- package/fy-checkbox/index.mjs +2 -2
- package/fy-curd/index.mjs +1 -1
- package/fy-curd/style.css +1 -1
- package/fy-date/index.mjs +2 -2
- package/fy-date/style.css +1 -1
- package/fy-dynamic/index.mjs +15 -15
- package/fy-empty/index.mjs +4 -4
- package/fy-form/index.mjs +1 -1
- package/fy-input/index.mjs +3 -3
- package/fy-input-color/index.mjs +2 -2
- package/fy-input-map/index.mjs +36 -34
- package/fy-input-number/index.mjs +2 -2
- package/fy-input-table/index.mjs +40 -38
- package/fy-input-tree/index.mjs +17 -17
- package/fy-radio/index.mjs +2 -2
- package/fy-rate/index.mjs +2 -2
- package/fy-select/index.mjs +29 -29
- package/fy-slider/index.mjs +5 -5
- package/fy-switch/index.mjs +2 -2
- package/fy-tabs/index.mjs +1 -1
- package/fy-time/index.mjs +7 -7
- package/fy-title/index.mjs +2 -2
- package/fy-tree/index.mjs +76 -74
- package/fy-u-editor/index.mjs +1 -1
- package/fy-upload/index.mjs +1 -1
- package/icon-temp/index.mjs +1 -1
- package/index.d.ts +2 -141
- package/index.mjs +31 -178
- package/monaco-editor/index.mjs +1 -1
- package/package.json +4 -4
- package/web-types.json +2431 -20044
- package/address-input/index.mjs +0 -76
- package/address-input/style.css +0 -1
- package/affix/index.mjs +0 -72
- package/affix/style.css +0 -1
- package/aside-menu/index.mjs +0 -20
- package/aside-menu/style.css +0 -1
- package/avatar/index.mjs +0 -94
- package/avatar/style.css +0 -1
- package/awesome-button/index.mjs +0 -49
- package/base.css +0 -1
- package/capsule-tab/index.mjs +0 -27
- package/capsule-tab/style.css +0 -1
- package/card/index.mjs +0 -86
- package/card/style.css +0 -1
- package/carousel/index.mjs +0 -46
- package/carousel/style.css +0 -1
- package/chat/index.mjs +0 -432
- package/chat/style.css +0 -1
- package/chunk-file-uploader/index.mjs +0 -2
- package/chunk-file-uploader/style.css +0 -1
- package/chunks/ChunkFileUploader.C3EA0e5t.mjs +0 -114
- package/chunks/EditableTree.CV8b95tW.mjs +0 -639
- package/chunks/ElementBaseInfo.lW0iwU10.mjs +0 -208
- package/chunks/ElementDialog.DWhAJsUn.mjs +0 -520
- package/chunks/ElementForm.C7yebHWH.mjs +0 -600
- package/chunks/ElementListeners.B_SjC8dp.mjs +0 -635
- package/chunks/ElementMultiInstance.Xw27Z5mm.mjs +0 -289
- package/chunks/ElementOtherConfig.DnNmAhKn.mjs +0 -50
- package/chunks/ElementProperties.DKr9JE_O.mjs +0 -187
- package/chunks/ElementTaskConfig.CPjsXlpS.mjs +0 -442
- package/chunks/FlowCondition.BA7GF34X.mjs +0 -193
- package/chunks/FlowDesigner.DH1ypcUw.mjs +0 -5100
- package/chunks/FormBlock.D6kZl7sm.mjs +0 -117
- package/chunks/FormCascader.BXL8lKww.mjs +0 -1229
- package/chunks/FormInputTime.DzTPiDNh.mjs +0 -1775
- package/chunks/FormItem.B8iPLduv.mjs +0 -89
- package/chunks/FormItemGroup.CCGqEapT.mjs +0 -154
- package/chunks/FormSelect.t0jbTL_K.mjs +0 -1475
- package/chunks/FormSwitch.uoFQ-xp_.mjs +0 -298
- package/chunks/FormTemp.CeHtEZQe.mjs +0 -144
- package/chunks/FyFormDesign.DIIK7mXK.mjs +0 -5521
- package/chunks/ImagePreview.DDFrZgo5.mjs +0 -649
- package/chunks/Keyboard.DBspwbYo.mjs +0 -379
- package/chunks/PageableTable.DR-REJN5.mjs +0 -659
- package/chunks/RecordVideo.CKTY-gk9.mjs +0 -116
- package/chunks/SignalAndMessage.CL2u19it.mjs +0 -189
- package/chunks/SplitPane.DNNid7WB.mjs +0 -219
- package/chunks/TableColumn.Cq9Bvevm.mjs +0 -186
- package/chunks/TableView.DMWMaGLA.mjs +0 -477
- package/chunks/Toolbar.DytZ6fO0.mjs +0 -219
- package/chunks/ToolbarButton.AlTszc53.mjs +0 -107
- package/chunks/UserTaskListeners.Qfm8hKWP.mjs +0 -581
- package/chunks/VueCron.BmPnLuu3.mjs +0 -1787
- package/chunks/VueTreeSelect.GHx4Z2lG.mjs +0 -1877
- package/chunks/button.gVyl7Y__.mjs +0 -927
- package/chunks/checkbox.AmhCpaBZ.mjs +0 -438
- package/chunks/chunk.A6TnG60p.mjs +0 -13
- package/chunks/confirmable-mixin.BZtxXY0h.mjs +0 -273
- package/chunks/constants.Dw7hXt67.mjs +0 -4
- package/chunks/core.Blrh_Fjl.mjs +0 -51
- package/chunks/dataformat.F7GtAoiN.mjs +0 -144
- package/chunks/dictionary.BqVLM7Lf.mjs +0 -87
- package/chunks/dictionary.DXYdZefs.mjs +0 -19
- package/chunks/event.ZRs4J5TN.mjs +0 -4
- package/chunks/focus-trap.CuUc8N2C.mjs +0 -211
- package/chunks/form-input.DdSb45Tz.mjs +0 -34
- package/chunks/form-item.fYYCXvCs.mjs +0 -716
- package/chunks/form-pick.BEC7lrNH.mjs +0 -7
- package/chunks/form-validate.JFOV_f-C.mjs +0 -11
- package/chunks/icon.AJYLfX1m.mjs +0 -26
- package/chunks/icon.niAg1zTC.mjs +0 -251
- package/chunks/init.CtUEiRbU.mjs +0 -115
- package/chunks/input.B_wW4aF-.mjs +0 -548
- package/chunks/install.BJl2MN77.mjs +0 -73
- package/chunks/message-box.wGWcYSSd.mjs +0 -463
- package/chunks/message.DnTACuzV.mjs +0 -401
- package/chunks/overlay.Rhu_rfhx.mjs +0 -122
- package/chunks/photo-swipe.BvBJGc5x.mjs +0 -55
- package/chunks/radio.BMkZBhl5.mjs +0 -274
- package/chunks/scroll.BJIpzi2Q.mjs +0 -28
- package/chunks/scrollbar.CvxOszy3.mjs +0 -345
- package/chunks/slot.CZCo32Cw.mjs +0 -25
- package/chunks/style.CraPDfJA.mjs +0 -325
- package/chunks/sub-table-plus-props.DvS8aKT4.mjs +0 -28
- package/chunks/tab-mixin.C9DSz8xu.mjs +0 -70
- package/chunks/tag.B6yUaGj-.mjs +0 -141
- package/chunks/teleport.87mkIv8m.mjs +0 -22
- package/chunks/tooltip.Dzjs7LZ8.mjs +0 -1926
- package/chunks/typescript.D0a40c7B.mjs +0 -4
- package/chunks/use-aria.B9uqqWAE.mjs +0 -17
- package/chunks/use-composition.BMPJBvYs.mjs +0 -47
- package/chunks/use-deprecated.vx6LTDA_.mjs +0 -12
- package/chunks/use-empty-values.CxYKjLV9.mjs +0 -81
- package/chunks/use-form-item.DMDTkMq9.mjs +0 -48
- package/chunks/use-global-config.Dkt91Ob3.mjs +0 -57
- package/chunks/use-id.CyzdvfQn.mjs +0 -15
- package/chunks/use-locale.CBoQRFjH.mjs +0 -188
- package/chunks/use-size.CoorvF12.mjs +0 -18
- package/chunks/util.fjuzrmWz.mjs +0 -103
- package/chunks/utilSelf.Bv7FtUNb.mjs +0 -46
- package/chunks/utils.C37EhJ-u.mjs +0 -60
- package/chunks/utils.C8RvIGLM.mjs +0 -14
- package/chunks/validator.Drv0r2Nb.mjs +0 -5
- package/chunks/vnode.raM3wMJz.mjs +0 -14
- package/code-mirror-editor/index.mjs +0 -99
- package/code-mirror-editor/style.css +0 -1
- package/comment/index.mjs +0 -62
- package/comment/style.css +0 -1
- package/configComponents.d.ts +0 -29
- package/configComponents.mjs +0 -42
- package/confirm-button/index.mjs +0 -35
- package/confirmable/index.mjs +0 -8
- package/context-menu/index.mjs +0 -196
- package/context-menu/style.css +0 -1
- package/count-up/index.mjs +0 -99
- package/custom-scrollbar/index.mjs +0 -93
- package/data-box/index.mjs +0 -64
- package/data-box/style.css +0 -1
- package/data-card/index.mjs +0 -60
- package/data-card/style.css +0 -1
- package/data-card-text/index.mjs +0 -64
- package/data-card-text/style.css +0 -1
- package/data-display/index.mjs +0 -71
- package/data-display/style.css +0 -1
- package/data-icons/index.mjs +0 -70
- package/data-icons/style.css +0 -1
- package/data-imgtext/index.mjs +0 -67
- package/data-imgtext/style.css +0 -1
- package/data-operatext/index.mjs +0 -51
- package/data-operatext/style.css +0 -1
- package/data-panel/index.mjs +0 -57
- package/data-panel/style.css +0 -1
- package/data-pay/index.mjs +0 -105
- package/data-pay/style.css +0 -1
- package/data-price/index.mjs +0 -48
- package/data-price/style.css +0 -1
- package/data-progress/index.mjs +0 -67
- package/data-progress/style.css +0 -1
- package/data-rotate/index.mjs +0 -61
- package/data-rotate/style.css +0 -1
- package/data-table-picker/index.mjs +0 -116
- package/data-tabs/index.mjs +0 -67
- package/data-tabs/style.css +0 -1
- package/dynamic-table/index.mjs +0 -165
- package/dynamic-table/style.css +0 -1
- package/e-charts/index.mjs +0 -176
- package/e-charts/style.css +0 -1
- package/easy-popup/index.mjs +0 -92
- package/easy-popup/style.css +0 -1
- package/editable-progress/index.mjs +0 -113
- package/editable-progress/style.css +0 -1
- package/editable-tree/index.mjs +0 -2
- package/editable-tree/style.css +0 -1
- package/element-listeners/style.css +0 -1
- package/element-multi-instance/style.css +0 -1
- package/ellipsis/index.mjs +0 -124
- package/ellipsis/style.css +0 -1
- package/empty-view/index.mjs +0 -46
- package/empty-view/style.css +0 -1
- package/error-view/index.mjs +0 -37
- package/error-view/style.css +0 -1
- package/flex-column/index.mjs +0 -35
- package/flex-item/index.mjs +0 -61
- package/flex-row/index.mjs +0 -34
- package/flex-scroller/index.mjs +0 -29
- package/flex-scroller/style.css +0 -1
- package/flow/index.mjs +0 -240
- package/flow/style.css +0 -1
- package/flow-designer/index.mjs +0 -2
- package/flow-designer/style.css +0 -1
- package/flow-node/index.mjs +0 -56
- package/flow-viewer/index.mjs +0 -160
- package/flow-viewer/style.css +0 -1
- package/form-block/index.mjs +0 -2
- package/form-block/style.css +0 -1
- package/form-button/index.mjs +0 -36
- package/form-card/index.mjs +0 -14
- package/form-cascader/index.mjs +0 -2
- package/form-checkbox/index.mjs +0 -90
- package/form-checkbox-group/index.mjs +0 -162
- package/form-checkbox-group/style.css +0 -1
- package/form-date-picker/index.mjs +0 -156
- package/form-holder/index.mjs +0 -134
- package/form-holder/style.css +0 -1
- package/form-input/index.mjs +0 -114
- package/form-input-cron-expression/index.mjs +0 -98
- package/form-input-cron-expression/style.css +0 -1
- package/form-input-email/index.mjs +0 -66
- package/form-input-id-card/index.mjs +0 -74
- package/form-input-phone-number/index.mjs +0 -73
- package/form-input-tag/index.mjs +0 -89
- package/form-input-time/index.mjs +0 -2
- package/form-item/index.mjs +0 -2
- package/form-item/style.css +0 -1
- package/form-item-config-provider/index.mjs +0 -47
- package/form-item-group/index.mjs +0 -2
- package/form-item-group/style.css +0 -1
- package/form-radio-group/index.mjs +0 -162
- package/form-radio-group/style.css +0 -1
- package/form-select/index.mjs +0 -2
- package/form-select/style.css +0 -1
- package/form-switch/index.mjs +0 -2
- package/form-table/index.mjs +0 -132
- package/form-table-plus/index.mjs +0 -165
- package/form-textarea/index.mjs +0 -91
- package/form-tree-select/index.mjs +0 -90
- package/form-tree-select/style.css +0 -1
- package/form-tree-select-multiple/index.mjs +0 -93
- package/form-view/index.mjs +0 -280
- package/form-view/style.css +0 -1
- package/fy-article/index.mjs +0 -73
- package/fy-article/style.css +0 -1
- package/fy-code/index.mjs +0 -48
- package/fy-draggable/index.mjs +0 -323
- package/fy-draggable/style.css +0 -1
- package/fy-form-design/index.mjs +0 -2
- package/fy-form-design/style.css +0 -1
- package/fy-input-icon/index.mjs +0 -134
- package/fy-input-icon/style.css +0 -1
- package/fy-progress/index.mjs +0 -36
- package/guide-steps/index.mjs +0 -73
- package/guide-steps/style.css +0 -1
- package/helper-function.d.ts +0 -5
- package/helper-function.mjs +0 -58
- package/highlight-j-s/index.mjs +0 -51
- package/highlight-j-s/style.css +0 -1
- package/icon-card/index.mjs +0 -34
- package/icon-card/style.css +0 -1
- package/iframe-window/index.mjs +0 -40
- package/iframe-window/style.css +0 -1
- package/image-cropper/index.mjs +0 -152
- package/image-cropper/style.css +0 -1
- package/image-preview/index.mjs +0 -2
- package/image-preview/style.css +0 -1
- package/image-viewer/index.mjs +0 -70
- package/image-viewer/style.css +0 -1
- package/input-number-range/index.mjs +0 -76
- package/input-number-range/style.css +0 -1
- package/j-s-x-component/index.mjs +0 -14
- package/keyboard/index.mjs +0 -2
- package/keyboard/style.css +0 -1
- package/license/index.mjs +0 -106
- package/loading-view/index.mjs +0 -39
- package/loading-view/style.css +0 -1
- package/name-avatar/index.mjs +0 -61
- package/name-avatar/style.css +0 -1
- package/nav-bar/index.mjs +0 -34
- package/nav-bar/style.css +0 -1
- package/not-implement/index.mjs +0 -10
- package/not-implement/style.css +0 -1
- package/notice/index.mjs +0 -97
- package/notice/style.css +0 -1
- package/page/index.mjs +0 -19
- package/page/style.css +0 -1
- package/page-header/index.mjs +0 -27
- package/page-header/style.css +0 -1
- package/page-index/index.mjs +0 -121
- package/page-index/style.css +0 -1
- package/page-index-top/index.mjs +0 -80
- package/page-skeleton/index.mjs +0 -49
- package/page-skeleton/style.css +0 -1
- package/page-skeleton-new/index.mjs +0 -79
- package/page-skeleton-new/style.css +0 -1
- package/pageable-table/index.mjs +0 -2
- package/pageable-table/style.css +0 -1
- package/pageable-view/index.mjs +0 -280
- package/pageable-view/style.css +0 -1
- package/photo-swipe/index.d.ts +0 -8
- package/photo-swipe/index.mjs +0 -33
- package/picker-table-view/index.mjs +0 -221
- package/present-view/index.mjs +0 -271
- package/present-view/style.css +0 -1
- package/queue/index.mjs +0 -46
- package/queue/style.css +0 -1
- package/record-video/index.mjs +0 -2
- package/record-video/style.css +0 -1
- package/resize-observer/index.mjs +0 -45
- package/resize-observer/style.css +0 -1
- package/search/index.mjs +0 -116
- package/search/style.css +0 -1
- package/sign/index.mjs +0 -104
- package/sign/style.css +0 -1
- package/sign-panel/index.mjs +0 -183
- package/sign-panel/style.css +0 -1
- package/skeleton/index.mjs +0 -51
- package/skeleton/style.css +0 -1
- package/skeleton-panel/index.mjs +0 -34
- package/skeleton-panel/style.css +0 -1
- package/split-pane/index.mjs +0 -3
- package/split-pane/style.css +0 -1
- package/stateful/index.mjs +0 -71
- package/stateful/style.css +0 -1
- package/static-pageable-table/index.mjs +0 -69
- package/static-pageable-table/style.css +0 -1
- package/sub-table/index.mjs +0 -505
- package/sub-table/style.css +0 -1
- package/sub-table-plus/index.mjs +0 -590
- package/sub-table-plus/style.css +0 -1
- package/swiper/index.mjs +0 -128
- package/swiper/style.css +0 -1
- package/tab/index.mjs +0 -117
- package/tab/style.css +0 -1
- package/tab-item/index.mjs +0 -49
- package/table-column/index.mjs +0 -2
- package/table-column/style.css +0 -1
- package/table-view/index.mjs +0 -3
- package/table-view/style.css +0 -1
- package/tabs-view/index.mjs +0 -109
- package/tabs-view/style.css +0 -1
- package/tag-render/index.mjs +0 -84
- package/tag-render/style.css +0 -1
- package/text-ellipsis/index.mjs +0 -95
- package/text-ellipsis/style.css +0 -1
- package/toolbar/index.mjs +0 -2
- package/toolbar/style.css +0 -1
- package/toolbar-button/index.mjs +0 -2
- package/verify/index.mjs +0 -58
- package/verify/style.css +0 -1
- package/video/index.d.ts +0 -10
- package/vue-cron/index.mjs +0 -2
- package/vue-cron/style.css +0 -1
- package/vue-qr-code/index.mjs +0 -32
- package/vue-quill-editor/index.mjs +0 -127
- package/vue-quill-editor/style.css +0 -1
- package/vue-tags-input/index.mjs +0 -348
- package/vue-tags-input/style.css +0 -1
- package/vue-tree-select/index.mjs +0 -2
- package/vue-tree-select/style.css +0 -1
- package/vue-video-player/index.mjs +0 -136
- package/vue-video-player/style.css +0 -1
- package/watermark/index.mjs +0 -47
- package/watermark/style.css +0 -1
- package/x-input-tag/index.mjs +0 -142
- package/x-input-tag/style.css +0 -1
- /package/chunks/{_plugin-vue_export-helper.7vrlOII_.mjs → _plugin-vue_export-helper.CTBRVsXt.mjs} +0 -0
- /package/chunks/{packages.CONbEH13.mjs → packages.W76nKiMk.mjs} +0 -0
- /package/chunks/{permission.8WDtOmzA.mjs → permission.ZYdXiCsn.mjs} +0 -0
package/chat/index.mjs
DELETED
|
@@ -1,432 +0,0 @@
|
|
|
1
|
-
import { t as e } from "../chunks/_plugin-vue_export-helper.7vrlOII_.mjs";
|
|
2
|
-
import { x as t } from "../chunks/util.g-WQEec9.mjs";
|
|
3
|
-
import { Fragment as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createTextVNode as s, createVNode as c, normalizeClass as l, normalizeStyle as u, openBlock as d, renderList as f, renderSlot as p, resolveComponent as m, toDisplayString as h, vModelText as g, withCtx as _, withDirectives as v, withKeys as y } from "vue";
|
|
4
|
-
import { formatDate as b } from "@web-utils/integrations/dayjs";
|
|
5
|
-
//#region src/components/chat/Chat.vue
|
|
6
|
-
var x = {
|
|
7
|
-
name: "Chat",
|
|
8
|
-
props: {
|
|
9
|
-
beforeOpen: Function,
|
|
10
|
-
tools: {
|
|
11
|
-
type: Object,
|
|
12
|
-
default: () => ({
|
|
13
|
-
img: !0,
|
|
14
|
-
video: !0,
|
|
15
|
-
file: !0
|
|
16
|
-
})
|
|
17
|
-
},
|
|
18
|
-
placeholder: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: "请输入..."
|
|
21
|
-
},
|
|
22
|
-
width: {
|
|
23
|
-
type: [String, Number],
|
|
24
|
-
default: "100%"
|
|
25
|
-
},
|
|
26
|
-
height: {
|
|
27
|
-
type: [String, Number],
|
|
28
|
-
default: "520px"
|
|
29
|
-
},
|
|
30
|
-
modelValue: { type: String },
|
|
31
|
-
notice: {
|
|
32
|
-
type: Boolean,
|
|
33
|
-
default: !0
|
|
34
|
-
},
|
|
35
|
-
audio: {
|
|
36
|
-
type: Array,
|
|
37
|
-
default: () => [
|
|
38
|
-
"https://www.helloweba.net/demo/notifysound/notify.ogg",
|
|
39
|
-
"https://www.helloweba.net/demo/notifysound/notify.mp3",
|
|
40
|
-
"https://www.helloweba.net/demo/notifysound/notify.wav"
|
|
41
|
-
]
|
|
42
|
-
},
|
|
43
|
-
config: {
|
|
44
|
-
type: Object,
|
|
45
|
-
default: () => ({})
|
|
46
|
-
},
|
|
47
|
-
keylist: {
|
|
48
|
-
type: Array,
|
|
49
|
-
default: () => []
|
|
50
|
-
},
|
|
51
|
-
list: {
|
|
52
|
-
type: Array,
|
|
53
|
-
default: () => []
|
|
54
|
-
}
|
|
55
|
-
},
|
|
56
|
-
emits: [
|
|
57
|
-
"update:modelValue",
|
|
58
|
-
"change",
|
|
59
|
-
"submit",
|
|
60
|
-
"keyadd",
|
|
61
|
-
"keysend"
|
|
62
|
-
],
|
|
63
|
-
data() {
|
|
64
|
-
return {
|
|
65
|
-
upload: {
|
|
66
|
-
box: !1,
|
|
67
|
-
src: "",
|
|
68
|
-
type: "",
|
|
69
|
-
title: ""
|
|
70
|
-
},
|
|
71
|
-
visible: !1,
|
|
72
|
-
imgSrc: "",
|
|
73
|
-
videoSrc: "",
|
|
74
|
-
audioSrc: "",
|
|
75
|
-
keys: "",
|
|
76
|
-
show: !1
|
|
77
|
-
};
|
|
78
|
-
},
|
|
79
|
-
computed: {
|
|
80
|
-
msg: {
|
|
81
|
-
get() {
|
|
82
|
-
return this.modelValue;
|
|
83
|
-
},
|
|
84
|
-
set(e) {
|
|
85
|
-
this.$emit("update:modelValue", e), this.$emit("change", e);
|
|
86
|
-
}
|
|
87
|
-
},
|
|
88
|
-
heightStyleName() {
|
|
89
|
-
return { height: t(this.height) };
|
|
90
|
-
},
|
|
91
|
-
widthStyleName() {
|
|
92
|
-
return { width: t(this.width) };
|
|
93
|
-
},
|
|
94
|
-
msgActive() {
|
|
95
|
-
return this.msg.replace(/[\r\n]/g, "");
|
|
96
|
-
}
|
|
97
|
-
},
|
|
98
|
-
methods: {
|
|
99
|
-
uploadSubmit() {
|
|
100
|
-
this.$refs.form.validate((e) => {
|
|
101
|
-
e && (this.upload.box = !1, this.$emit("submit", this.getDetail(this.upload)));
|
|
102
|
-
});
|
|
103
|
-
},
|
|
104
|
-
handleUpload(e) {
|
|
105
|
-
this.upload.type = e, this.upload.src = "", e === "img" ? this.upload.title = "图片上传" : e === "video" ? this.upload.title = "视频上传" : e === "file" && (this.upload.title = "文件上传"), this.upload.box = !0;
|
|
106
|
-
},
|
|
107
|
-
handleClose(e) {
|
|
108
|
-
this.imgSrc = void 0, this.videoSrc = void 0, this.audioSrc = void 0, e();
|
|
109
|
-
},
|
|
110
|
-
addKey() {
|
|
111
|
-
this.keys !== "" && (this.$emit("keyadd", this.keys), this.keys = ""), this.visible = !1;
|
|
112
|
-
},
|
|
113
|
-
sendKey(e) {
|
|
114
|
-
this.$emit("keysend", e);
|
|
115
|
-
},
|
|
116
|
-
getAudio() {
|
|
117
|
-
this.$refs.chatAudio.play();
|
|
118
|
-
},
|
|
119
|
-
getNotification(e) {
|
|
120
|
-
let t = this, n = Notification || window.Notification;
|
|
121
|
-
if (n) {
|
|
122
|
-
let r = n.permission;
|
|
123
|
-
r === "granted" ? a() : r === "denied" ? console.log("用户拒绝了你!!!") : i();
|
|
124
|
-
function i() {
|
|
125
|
-
n.requestPermission((e) => {
|
|
126
|
-
e === "granted" ? a() : console.log("用户无情残忍的拒绝了你!!!");
|
|
127
|
-
});
|
|
128
|
-
}
|
|
129
|
-
function a() {
|
|
130
|
-
let n = new Notification(t.config.name, {
|
|
131
|
-
body: e,
|
|
132
|
-
icon: t.config.img
|
|
133
|
-
});
|
|
134
|
-
n.onshow = function() {
|
|
135
|
-
t.getAudio(), setTimeout(() => {
|
|
136
|
-
n.close();
|
|
137
|
-
}, 2500);
|
|
138
|
-
}, n.onclick = function() {
|
|
139
|
-
n.close();
|
|
140
|
-
};
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
},
|
|
144
|
-
pushMsg(e = {}) {
|
|
145
|
-
let t = e.mine === !0, n = e.text || {}, r = {
|
|
146
|
-
date: e.date || b(Date.now(), "YYYY-MM-DD HH:mm:ss"),
|
|
147
|
-
text: typeof n == "object" ? n : { text: n },
|
|
148
|
-
mine: t,
|
|
149
|
-
img: t ? this.config.myImg : this.config.img,
|
|
150
|
-
name: t ? this.config.myName : this.config.name
|
|
151
|
-
};
|
|
152
|
-
this.list.push(r), setTimeout(() => {
|
|
153
|
-
this.setScroll();
|
|
154
|
-
}, 50);
|
|
155
|
-
},
|
|
156
|
-
setScroll(e) {
|
|
157
|
-
this.$nextTick(() => {
|
|
158
|
-
this.$refs.main.scrollTop = e || this.$refs.main.scrollHeight;
|
|
159
|
-
});
|
|
160
|
-
},
|
|
161
|
-
handleSend() {
|
|
162
|
-
this.msgActive && this.$emit("submit");
|
|
163
|
-
},
|
|
164
|
-
handleItemMsg(e) {
|
|
165
|
-
this.$emit("submit", e.ask);
|
|
166
|
-
},
|
|
167
|
-
handleDetail(e = "") {
|
|
168
|
-
let t = e;
|
|
169
|
-
return setTimeout(() => {
|
|
170
|
-
(this.$refs.content || []).forEach((e) => {
|
|
171
|
-
for (let t = 0; t < e.children.length; t++) {
|
|
172
|
-
let n = e.children[t];
|
|
173
|
-
n.getAttribute("data-flag") !== "0" && (n.setAttribute("data-flag", 0), n.onclick = () => {
|
|
174
|
-
this.handleEvent(n.dataset);
|
|
175
|
-
}, n.tagName === "IMG" ? (n.className = "web__msg--img", n.src = n.getAttribute("data-src")) : n.tagName === "VIDEO" ? (n.className = "web__msg--video", n.src = n.getAttribute("data-src")) : n.tagName === "AUDIO" ? (n.className = "web__msg--audio", n.controls = "controls", n.src = n.getAttribute("data-src")) : n.tagName === "FILE" ? (n.className = "web__msg--file", n.innerHTML = `<h2>File</h2><span>${n.getAttribute("data-name")}</span>`) : n.tagName === "MAP" && (n.className = "web__msg--file web__msg--map", n.innerHTML = `<h2>Map</h2><span>${n.getAttribute("data-longitude")} , ${n.getAttribute("data-latitude")}<br />${n.getAttribute("data-address")}</span>`), this.setScroll());
|
|
176
|
-
}
|
|
177
|
-
});
|
|
178
|
-
}, 0), t;
|
|
179
|
-
},
|
|
180
|
-
getDetail(e = {}) {
|
|
181
|
-
let { type: t, src: n, name: r, longitude: i, latitude: a, address: o } = e;
|
|
182
|
-
if (t === "img") return `<img data-type="IMG" data-src="${n}" alt=""/>`;
|
|
183
|
-
if (t === "video") return `<video data-type="VIDEO" data-src="${n}"></video>`;
|
|
184
|
-
if (t === "audio") return `<audio data-type="AUDIO" data-src="${n}"></audio>`;
|
|
185
|
-
if (t === "file") return `<file data-type="FILE" data-name="${r}" data-src="${n}"></file>`;
|
|
186
|
-
if (t === "map") return `<map data-type="MAP" data-src="${n}" data-address="${o} " data-latitude="${a}" data-longitude="${i}"></map>`;
|
|
187
|
-
},
|
|
188
|
-
handleEvent(e) {
|
|
189
|
-
let t = () => {
|
|
190
|
-
e.type === "IMG" ? (this.imgSrc = e.src, this.show = !0) : e.type === "VIDEO" ? (this.videoSrc = e.src, this.show = !0) : e.type === "AUDIO" ? (this.audioSrc = e.src, this.show = !0) : e.type === "FILE" && window.open(e.src);
|
|
191
|
-
};
|
|
192
|
-
typeof this.beforeOpen == "function" ? this.beforeOpen(e, t) : t();
|
|
193
|
-
},
|
|
194
|
-
rootSendMsg(e) {
|
|
195
|
-
this.pushMsg({ text: e }), this.notice && this.getNotification(e.text || e);
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
}, S = { ref: "chatAudio" }, ee = ["src"], te = ["src"], C = ["src"], w = { class: "web__logo" }, T = ["src"], E = { class: "web__logo-info" }, D = { class: "web__logo-name" }, O = { class: "web__logo-dept" }, k = { class: "web__content" }, A = {
|
|
199
|
-
ref: "main",
|
|
200
|
-
class: "web__main"
|
|
201
|
-
}, j = { class: "web__main-user" }, M = ["src"], N = { class: "web__main-text" }, P = ["innerHTML"], F = {
|
|
202
|
-
key: 0,
|
|
203
|
-
class: "web__main-list"
|
|
204
|
-
}, I = ["onClick"], L = { class: "web__tools" }, ne = { class: "web__msg" }, R = ["placeholder"], z = { class: "web__msg-menu" }, B = { style: {
|
|
205
|
-
margin: "0",
|
|
206
|
-
"text-align": "right"
|
|
207
|
-
} }, V = { key: 0 }, H = { key: 1 }, U = ["src"], W = ["src"], G = ["src"];
|
|
208
|
-
function K(e, t, b, x, K, q) {
|
|
209
|
-
let J = m("ElInput"), Y = m("ElButton"), X = m("ElPopover"), Z = m("ElDropdownItem"), Q = m("ElTooltip"), re = m("ElScrollbar"), ie = m("ElDropdownMenu"), ae = m("ElDropdown"), oe = m("ElFormItem"), se = m("ElForm"), $ = m("ElementDialog");
|
|
210
|
-
return d(), a("div", {
|
|
211
|
-
class: "avue-chat",
|
|
212
|
-
style: u(q.heightStyleName),
|
|
213
|
-
onKeyup: t[11] || (t[11] = y((...e) => q.handleSend && q.handleSend(...e), ["enter"]))
|
|
214
|
-
}, [
|
|
215
|
-
o("audio", S, [
|
|
216
|
-
o("source", {
|
|
217
|
-
src: b.audio[0],
|
|
218
|
-
type: "audio/ogg"
|
|
219
|
-
}, null, 8, ee),
|
|
220
|
-
o("source", {
|
|
221
|
-
src: b.audio[1],
|
|
222
|
-
type: "audio/mpeg"
|
|
223
|
-
}, null, 8, te),
|
|
224
|
-
o("source", {
|
|
225
|
-
src: b.audio[2],
|
|
226
|
-
type: "audio/wav"
|
|
227
|
-
}, null, 8, C)
|
|
228
|
-
], 512),
|
|
229
|
-
o("div", w, [
|
|
230
|
-
o("img", {
|
|
231
|
-
src: b.config.img,
|
|
232
|
-
class: "web__logo-img",
|
|
233
|
-
alt: ""
|
|
234
|
-
}, null, 8, T),
|
|
235
|
-
o("div", E, [o("p", D, h(b.config.name), 1), o("p", O, h(b.config.dept), 1)]),
|
|
236
|
-
p(e.$slots, "header")
|
|
237
|
-
]),
|
|
238
|
-
o("div", k, [o("div", { style: u(q.widthStyleName) }, [o("div", A, [(d(!0), a(n, null, f(b.list, (e, r) => (d(), a("div", {
|
|
239
|
-
key: r,
|
|
240
|
-
class: l(["web__main-item", { "web__main-item--mine": e.mine }])
|
|
241
|
-
}, [o("div", j, [o("img", {
|
|
242
|
-
src: e.img,
|
|
243
|
-
alt: ""
|
|
244
|
-
}, null, 8, M), o("cite", null, [s(h(e.name) + " ", 1), o("i", null, h(e.date), 1)])]), o("div", N, [
|
|
245
|
-
t[12] || (t[12] = o("div", { class: "web__main-arrow" }, null, -1)),
|
|
246
|
-
o("span", {
|
|
247
|
-
ref_for: !0,
|
|
248
|
-
ref: "content",
|
|
249
|
-
innerHTML: q.handleDetail(e.text.text)
|
|
250
|
-
}, null, 8, P),
|
|
251
|
-
e.text.list ? i("v-if", !0) : (d(), a("ul", F, [(d(!0), a(n, null, f(e.text.list, (e, t) => (d(), a("li", {
|
|
252
|
-
key: t,
|
|
253
|
-
onClick: (t) => q.handleItemMsg(e)
|
|
254
|
-
}, h(e.text), 9, I))), 128))]))
|
|
255
|
-
])], 2))), 128))], 512), o("div", {
|
|
256
|
-
class: "web__footer",
|
|
257
|
-
style: u(q.widthStyleName)
|
|
258
|
-
}, [o("div", L, [
|
|
259
|
-
b.tools.img ? (d(), a("i", {
|
|
260
|
-
key: 0,
|
|
261
|
-
class: "el-icon-picture-outline",
|
|
262
|
-
onClick: t[0] || (t[0] = (e) => q.handleUpload("img"))
|
|
263
|
-
})) : i("v-if", !0),
|
|
264
|
-
b.tools.video ? (d(), a("i", {
|
|
265
|
-
key: 1,
|
|
266
|
-
class: "el-icon-video-camera",
|
|
267
|
-
onClick: t[1] || (t[1] = (e) => q.handleUpload("video"))
|
|
268
|
-
})) : i("v-if", !0),
|
|
269
|
-
b.tools.file ? (d(), a("i", {
|
|
270
|
-
key: 2,
|
|
271
|
-
class: "el-icon-folder-opened",
|
|
272
|
-
onClick: t[2] || (t[2] = (e) => q.handleUpload("file"))
|
|
273
|
-
})) : i("v-if", !0)
|
|
274
|
-
]), o("div", ne, [v(o("textarea", {
|
|
275
|
-
"onUpdate:modelValue": t[3] || (t[3] = (e) => q.msg = e),
|
|
276
|
-
rows: "2",
|
|
277
|
-
placeholder: b.placeholder,
|
|
278
|
-
class: "web__msg-input"
|
|
279
|
-
}, null, 8, R), [[g, q.msg]]), o("div", z, [c(ae, {
|
|
280
|
-
"split-button": "",
|
|
281
|
-
class: "web__msg-submit",
|
|
282
|
-
type: "primary",
|
|
283
|
-
trigger: "click",
|
|
284
|
-
onClick: q.handleSend
|
|
285
|
-
}, {
|
|
286
|
-
dropdown: _(() => [c(ie, null, {
|
|
287
|
-
default: _(() => [c(Z, null, {
|
|
288
|
-
default: _(() => [c(X, {
|
|
289
|
-
modelValue: K.visible,
|
|
290
|
-
"onUpdate:modelValue": t[6] || (t[6] = (e) => K.visible = e),
|
|
291
|
-
placement: "top",
|
|
292
|
-
width: "160"
|
|
293
|
-
}, {
|
|
294
|
-
reference: _(() => [c(Y, {
|
|
295
|
-
text: "",
|
|
296
|
-
icon: "el-icon-plus"
|
|
297
|
-
})]),
|
|
298
|
-
default: _(() => [c(J, {
|
|
299
|
-
modelValue: K.keys,
|
|
300
|
-
"onUpdate:modelValue": t[4] || (t[4] = (e) => K.keys = e),
|
|
301
|
-
style: { "margin-bottom": "10px" },
|
|
302
|
-
rows: 3,
|
|
303
|
-
"show-word-limit": "",
|
|
304
|
-
maxlength: "100",
|
|
305
|
-
placeholder: "请输入快捷回复语",
|
|
306
|
-
type: "textarea"
|
|
307
|
-
}, null, 8, ["modelValue"]), o("div", B, [c(Y, {
|
|
308
|
-
text: "",
|
|
309
|
-
onClick: t[5] || (t[5] = (e) => K.visible = !1)
|
|
310
|
-
}, {
|
|
311
|
-
default: _(() => [...t[13] || (t[13] = [s(" 取消 ", -1)])]),
|
|
312
|
-
_: 1
|
|
313
|
-
}), c(Y, {
|
|
314
|
-
type: "primary",
|
|
315
|
-
onClick: q.addKey
|
|
316
|
-
}, {
|
|
317
|
-
default: _(() => [...t[14] || (t[14] = [s(" 确定 ", -1)])]),
|
|
318
|
-
_: 1
|
|
319
|
-
}, 8, ["onClick"])])]),
|
|
320
|
-
_: 1
|
|
321
|
-
}, 8, ["modelValue"])]),
|
|
322
|
-
_: 1
|
|
323
|
-
}), c(re, { style: { height: "100px" } }, {
|
|
324
|
-
default: _(() => [(d(!0), a(n, null, f(b.keylist, (e, t) => (d(), r(Z, {
|
|
325
|
-
key: t,
|
|
326
|
-
onClick: (t) => q.sendKey(e)
|
|
327
|
-
}, {
|
|
328
|
-
default: _(() => [c(Q, {
|
|
329
|
-
effect: "dark",
|
|
330
|
-
content: e,
|
|
331
|
-
placement: "top"
|
|
332
|
-
}, {
|
|
333
|
-
default: _(() => [o("span", null, h(e.substr(0, 10)) + h(e.length > 10 ? "..." : ""), 1)]),
|
|
334
|
-
_: 2
|
|
335
|
-
}, 1032, ["content"])]),
|
|
336
|
-
_: 2
|
|
337
|
-
}, 1032, ["onClick"]))), 128))]),
|
|
338
|
-
_: 1
|
|
339
|
-
})]),
|
|
340
|
-
_: 1
|
|
341
|
-
})]),
|
|
342
|
-
default: _(() => [t[15] || (t[15] = s(" 发送 ", -1))]),
|
|
343
|
-
_: 1
|
|
344
|
-
}, 8, ["onClick"])])])], 4)], 4), p(e.$slots, "default")]),
|
|
345
|
-
K.upload.box ? (d(), a("div", V, [c($, {
|
|
346
|
-
visible: K.upload.box,
|
|
347
|
-
"onUpdate:visible": t[9] || (t[9] = (e) => K.upload.box = e),
|
|
348
|
-
title: K.upload.title,
|
|
349
|
-
"body-padding": !1,
|
|
350
|
-
width: "30%"
|
|
351
|
-
}, {
|
|
352
|
-
footer: _(() => [c(Y, { onClick: t[8] || (t[8] = (e) => K.upload.box = !1) }, {
|
|
353
|
-
default: _(() => [...t[16] || (t[16] = [s("取 消", -1)])]),
|
|
354
|
-
_: 1
|
|
355
|
-
}), c(Y, {
|
|
356
|
-
type: "primary",
|
|
357
|
-
onClick: q.uploadSubmit
|
|
358
|
-
}, {
|
|
359
|
-
default: _(() => [...t[17] || (t[17] = [s("确 定", -1)])]),
|
|
360
|
-
_: 1
|
|
361
|
-
}, 8, ["onClick"])]),
|
|
362
|
-
default: _(() => [c(se, {
|
|
363
|
-
ref: "form",
|
|
364
|
-
model: K.upload
|
|
365
|
-
}, {
|
|
366
|
-
default: _(() => [c(oe, {
|
|
367
|
-
prop: "src",
|
|
368
|
-
rules: [{
|
|
369
|
-
required: !0,
|
|
370
|
-
message: "地址不能为空"
|
|
371
|
-
}]
|
|
372
|
-
}, {
|
|
373
|
-
default: _(() => [c(J, {
|
|
374
|
-
modelValue: K.upload.src,
|
|
375
|
-
"onUpdate:modelValue": t[7] || (t[7] = (e) => K.upload.src = e),
|
|
376
|
-
style: { "margin-bottom": "10px" },
|
|
377
|
-
rows: 4,
|
|
378
|
-
"show-word-limit": "",
|
|
379
|
-
maxlength: "100",
|
|
380
|
-
placeholder: "请输入地址",
|
|
381
|
-
type: "textarea"
|
|
382
|
-
}, null, 8, ["modelValue"])]),
|
|
383
|
-
_: 1
|
|
384
|
-
})]),
|
|
385
|
-
_: 1
|
|
386
|
-
}, 8, ["model"])]),
|
|
387
|
-
_: 1
|
|
388
|
-
}, 8, ["visible", "title"])])) : i("v-if", !0),
|
|
389
|
-
K.show ? (d(), a("div", H, [c($, {
|
|
390
|
-
visible: K.show,
|
|
391
|
-
"onUpdate:visible": t[10] || (t[10] = (e) => K.show = e),
|
|
392
|
-
"body-padding": !1,
|
|
393
|
-
title: "预览",
|
|
394
|
-
width: "40%",
|
|
395
|
-
"before-close": q.handleClose,
|
|
396
|
-
class: "web__dialog"
|
|
397
|
-
}, {
|
|
398
|
-
default: _(() => [
|
|
399
|
-
K.imgSrc ? (d(), a("img", {
|
|
400
|
-
key: 0,
|
|
401
|
-
src: K.imgSrc,
|
|
402
|
-
style: {
|
|
403
|
-
width: "100%",
|
|
404
|
-
"object-fit": "cover"
|
|
405
|
-
}
|
|
406
|
-
}, null, 8, U)) : i("v-if", !0),
|
|
407
|
-
K.videoSrc ? (d(), a("video", {
|
|
408
|
-
key: 1,
|
|
409
|
-
src: K.videoSrc,
|
|
410
|
-
style: {
|
|
411
|
-
width: "100%",
|
|
412
|
-
"object-fit": "cover"
|
|
413
|
-
},
|
|
414
|
-
controls: "controls"
|
|
415
|
-
}, null, 8, W)) : i("v-if", !0),
|
|
416
|
-
K.audioSrc ? (d(), a("audio", {
|
|
417
|
-
key: 2,
|
|
418
|
-
src: K.audioSrc,
|
|
419
|
-
style: {
|
|
420
|
-
width: "100%",
|
|
421
|
-
"object-fit": "cover"
|
|
422
|
-
},
|
|
423
|
-
controls: "controls"
|
|
424
|
-
}, null, 8, G)) : i("v-if", !0)
|
|
425
|
-
]),
|
|
426
|
-
_: 1
|
|
427
|
-
}, 8, ["visible", "before-close"])])) : i("v-if", !0)
|
|
428
|
-
], 36);
|
|
429
|
-
}
|
|
430
|
-
var q = /* @__PURE__ */ e(x, [["render", K]]);
|
|
431
|
-
//#endregion
|
|
432
|
-
export { q as default };
|
package/chat/style.css
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.avue-chat{background-color:#fcfcfc;position:relative;box-shadow:1px 2px 10px #eee}.avue-chat ul,.avue-chat li{margin:0;padding:0}.avue-chat li{cursor:pointer;list-style:none}.avue-chat .web__content{height:100%;display:flex}.avue-chat .web__main{box-sizing:border-box;height:calc(100% - 200px);padding:15px 15px 20px;overflow:hidden auto}.avue-chat .web__logo{vertical-align:middle;background-color:#409eff;margin:0 auto;padding:15px 12px;display:flex}.avue-chat .web__logo-img{border-radius:100%;width:35px;height:35px;margin-top:3px;box-shadow:0 3px 3px #0000001a}.avue-chat .web__logo-info{margin-left:10px}.avue-chat .web__logo-name{margin-top:5px;font-size:13px;position:relative}.avue-chat .web__logo-dept{margin-top:1px;font-size:12px}.avue-chat .web__logo-name,.avue-chat .web__logo-dept{color:#fff;white-space:nowrap;text-overflow:ellipsis;width:175px;margin:0;padding:0;overflow:hidden}.avue-chat .web__main-item{min-height:68px;margin-bottom:10px;padding-left:60px;font-size:0;position:relative}.avue-chat .web__main-user,.avue-chat .web__main-text{vertical-align:top;font-size:14px;display:inline-block}.avue-chat .web__main-user{position:absolute;left:3px}.avue-chat .web__main-user img{border-radius:100%;width:40px;height:40px}.avue-chat .web__main-user cite{color:#999;white-space:nowrap;text-align:left;width:500px;font-size:12px;font-style:normal;line-height:24px;position:absolute;top:-2px;left:60px}.avue-chat .web__main-user cite i{padding-left:15px;font-style:normal}.avue-chat .web__main-text{color:#000;word-break:break-all;background-color:#f3f3f3;border:1px solid #f0f0f0;border-radius:3px;margin-top:25px;padding:8px 15px;line-height:22px;position:relative}.avue-chat .web__main-arrow{border:8px solid #0000;border-left-width:0;border-right-color:#ebeef5;width:0;height:0;display:block;position:absolute;top:6px;left:-8px}.avue-chat .web__main-arrow:after{content:" ";border:7px solid #0000;border-left-width:0;border-right-color:#fff;width:0;height:0;display:block;position:absolute;top:-7px;left:1px}.avue-chat .web__main-item--mine .web__main-text .web__main-arrow{border:8px solid #0000;border-left-color:#409eff;border-right-width:0;left:auto;right:-5px}.avue-chat .web__main-item--mine .web__main-text .web__main-arrow:after{border:7px solid #0000;border-left-color:#409eff;border-right-width:0;left:auto;right:-2px}.avue-chat .web__main-list{margin:10px 0}.avue-chat .web__main-list li{color:#409eff;height:30px;line-height:30px}.avue-chat .web__main-item--mine{text-align:right;padding-left:0;padding-right:60px}.avue-chat .web__main-item--mine .web__main-user{left:auto;right:3px}.avue-chat .web__main-item--mine .web__main-user cite{text-align:right;left:auto;right:60px}.avue-chat .web__main-item--mine .web__main-user cite i{padding-left:0;padding-right:15px}.avue-chat .web__main-item--mine .web__main-text{color:#fff;text-align:left;background-color:#409eff;margin-left:0}.avue-chat .web__footer{background-color:#fff;width:100%;position:absolute;bottom:0;left:0;box-shadow:0 -1px #0000000a,0 -2px #00000003}.avue-chat .web__msg{height:auto;padding:10px;overflow:hidden}.avue-chat .web__msg--img,.avue-chat .web__msg--video,.avue-chat .web__msg--file{cursor:pointer;border:1px solid #eee;border-radius:5px;width:100%;min-width:200px;max-width:250px;margin:10px 0;display:block;position:relative;overflow:hidden}.avue-chat .web__msg--file{background-color:#fff;height:140px}.avue-chat .web__msg--file span{box-sizing:border-box;color:#333;text-align:center;justify-content:center;align-items:center;width:100%;height:calc(100% - 80px);padding:3px 5px;font-size:13px;display:flex;overflow:hidden}.avue-chat .web__msg--file h2{color:#fff;text-align:center;background-color:#409eff;width:100%;margin:0;line-height:80px}.avue-chat .web__msg--map{height:160px}.avue-chat .web__msg-input{box-sizing:border-box;word-break:break-all;-webkit-appearance:none;-moz-appearance:none;appearance:none;resize:none;background-color:#fff;border:0;outline:0;width:100%;height:60px;font-size:13px;line-height:17px;display:block;overflow:hidden auto}.avue-chat .web__msg-submit{float:right;text-align:center;cursor:pointer;outline:none;display:block}.avue-chat .web__tools{box-sizing:border-box;padding:8px 10px 0}.avue-chat .web__tools i{color:#888a91;margin-right:12px;font-size:20px}.avue-chat .web__tools i:hover{color:#76b1f9}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.uploader{position:relative}
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
import { t as e } from "./_plugin-vue_export-helper.7vrlOII_.mjs";
|
|
2
|
-
import { createElementBlock as t, createElementVNode as n, createTextVNode as r, createVNode as i, openBlock as a, renderSlot as o, resolveComponent as s, withCtx as c } from "vue";
|
|
3
|
-
import l from "simple-uploader.js";
|
|
4
|
-
//#region src/components/chunk-file-uploader/common/utils.js
|
|
5
|
-
function u(e) {
|
|
6
|
-
return e.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`);
|
|
7
|
-
}
|
|
8
|
-
//#endregion
|
|
9
|
-
//#region src/components/chunk-file-uploader/ChunkFileUploader.vue
|
|
10
|
-
var d = "fileAdded", f = "filesAdded", p = "uploadStart", m = {
|
|
11
|
-
name: "ChunkFileUploader",
|
|
12
|
-
provide() {
|
|
13
|
-
return { uploader: this };
|
|
14
|
-
},
|
|
15
|
-
props: {
|
|
16
|
-
options: {
|
|
17
|
-
type: Object,
|
|
18
|
-
default() {
|
|
19
|
-
return {};
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
autoStart: {
|
|
23
|
-
type: Boolean,
|
|
24
|
-
default: !0
|
|
25
|
-
},
|
|
26
|
-
fileStatusText: {
|
|
27
|
-
type: [Object, Function],
|
|
28
|
-
default() {
|
|
29
|
-
return {
|
|
30
|
-
success: "success",
|
|
31
|
-
error: "error",
|
|
32
|
-
uploading: "uploading",
|
|
33
|
-
paused: "paused",
|
|
34
|
-
waiting: "waiting"
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
emits: ["file-removed"],
|
|
40
|
-
data() {
|
|
41
|
-
return {
|
|
42
|
-
started: !1,
|
|
43
|
-
files: [],
|
|
44
|
-
fileList: []
|
|
45
|
-
};
|
|
46
|
-
},
|
|
47
|
-
created() {
|
|
48
|
-
this.options.initialPaused = !this.autoStart;
|
|
49
|
-
let e = new l(this.options);
|
|
50
|
-
this.uploader = e, this.uploader.fileStatusText = this.fileStatusText, e.on("catchAll", this.allEvent), e.on(d, this.fileAdded), e.on(f, this.filesAdded), e.on("fileRemoved", this.fileRemoved), e.on("filesSubmitted", this.filesSubmitted);
|
|
51
|
-
},
|
|
52
|
-
unmounted() {
|
|
53
|
-
let e = this.uploader;
|
|
54
|
-
e.off("catchAll", this.allEvent), e.off(d, this.fileAdded), e.off(f, this.filesAdded), e.off("fileRemoved", this.fileRemoved), e.off("filesSubmitted", this.filesSubmitted), this.uploader = null;
|
|
55
|
-
},
|
|
56
|
-
methods: {
|
|
57
|
-
uploadStart() {
|
|
58
|
-
this.started = !0;
|
|
59
|
-
},
|
|
60
|
-
fileAdded(e) {
|
|
61
|
-
if (this.$emit(u(d), e), e.ignored) return !1;
|
|
62
|
-
},
|
|
63
|
-
filesAdded(e, t) {
|
|
64
|
-
if (this.$emit(u(f), e, t), e.ignored || t.ignored) return !1;
|
|
65
|
-
},
|
|
66
|
-
fileRemoved(e) {
|
|
67
|
-
this.$emit("file-removed", e), this.files = this.uploader.files, this.fileList = this.uploader.fileList;
|
|
68
|
-
},
|
|
69
|
-
filesSubmitted() {
|
|
70
|
-
this.files = this.uploader.files, this.fileList = this.uploader.fileList, this.autoStart && this.uploader.upload();
|
|
71
|
-
},
|
|
72
|
-
allEvent(...e) {
|
|
73
|
-
let t = e[0], n = {
|
|
74
|
-
[d]: !0,
|
|
75
|
-
[f]: !0,
|
|
76
|
-
[p]: "uploadStart"
|
|
77
|
-
}[t];
|
|
78
|
-
if (n) {
|
|
79
|
-
var r;
|
|
80
|
-
if (n === !0) return;
|
|
81
|
-
(r = this[n]) == null || r.call(this, e.slice(1));
|
|
82
|
-
}
|
|
83
|
-
e[0] = u(t), this.$emit(...e);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
}, h = { class: "uploader" };
|
|
87
|
-
function g(e, l, u, d, f, p) {
|
|
88
|
-
let m = s("ChunkFileUploaderUnSupport"), g = s("ChunkFileUploaderButton"), _ = s("ChunkFileUploaderDrop"), v = s("ChunkFileUploaderList");
|
|
89
|
-
return a(), t("div", h, [o(e.$slots, "default", {
|
|
90
|
-
files: f.files,
|
|
91
|
-
fileList: f.fileList,
|
|
92
|
-
started: f.started
|
|
93
|
-
}, () => [
|
|
94
|
-
i(m),
|
|
95
|
-
i(_, null, {
|
|
96
|
-
default: c(() => [
|
|
97
|
-
l[2] || (l[2] = n("p", null, "Drop files here to upload or", -1)),
|
|
98
|
-
i(g, null, {
|
|
99
|
-
default: c(() => [...l[0] || (l[0] = [r("select files", -1)])]),
|
|
100
|
-
_: 1
|
|
101
|
-
}),
|
|
102
|
-
i(g, { directory: !0 }, {
|
|
103
|
-
default: c(() => [...l[1] || (l[1] = [r(" select folder ", -1)])]),
|
|
104
|
-
_: 1
|
|
105
|
-
})
|
|
106
|
-
]),
|
|
107
|
-
_: 1
|
|
108
|
-
}),
|
|
109
|
-
i(v)
|
|
110
|
-
])]);
|
|
111
|
-
}
|
|
112
|
-
var _ = /* @__PURE__ */ e(m, [["render", g]]);
|
|
113
|
-
//#endregion
|
|
114
|
-
export { _ as t };
|