即时系统
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

1 lines
340 KiB

(function(){var t={8100:function(t,e,i){"use strict";i.d(e,{Z:function(){return k}});var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"chat-main"},[e("el-input",{staticClass:"input-with-select",attrs:{placeholder:"请输入关键字搜索聊天"},model:{value:t.params.keywords,callback:function(e){t.$set(t.params,"keywords",e)},expression:"params.keywords"}},[e("el-button",{attrs:{slot:"append",icon:"el-icon-search"},on:{click:t.searchMessage},slot:"append"})],1),e("el-tabs",{on:{"tab-click":t.handleClick},model:{value:t.activeName,callback:function(e){t.activeName=e},expression:"activeName"}},[e("el-tab-pane",{attrs:{label:"全部",name:"all"}},[e("div",{staticClass:"el-tab-body-list"},[e("el-scrollbar",[t.dataList.length?t._l(t.dataList,(function(t,i){return e("ChatItem",{key:i,attrs:{data:t}})})):e("div",[e("el-empty",{attrs:{description:"暂无数据"}})],1)],2)],1)]),e("el-tab-pane",{attrs:{label:"文本",name:"text"}},[e("div",{staticClass:"el-tab-body-list"},[t.dataList.length?[e("el-scrollbar",t._l(t.dataList,(function(t,i){return e("ChatItem",{key:i,attrs:{data:t}})})),1)]:e("div",[e("el-empty",{attrs:{description:"暂无数据"}})],1)],2)]),e("el-tab-pane",{attrs:{label:"图片",name:"image"}},[e("div",{staticClass:"el-tab-body-list"},[t.dataList.length?[e("el-scrollbar",[e("el-row",{staticStyle:{}},t._l(t.dataList,(function(i,s){return e("ChatImage",{key:s,attrs:{data:i,previewUrl:t.previewList}})})),1)],1)]:e("div",[e("el-empty",{attrs:{description:"暂无数据"}})],1)],2)]),e("el-tab-pane",{attrs:{label:"视频",name:"video"}},[e("div",{staticClass:"el-tab-body-list"},[t.dataList.length?[e("el-scrollbar",t._l(t.dataList,(function(t,i){return e("ChatItem",{key:i,attrs:{data:t}})})),1)]:e("div",[e("el-empty",{attrs:{description:"暂无数据"}})],1)],2)]),e("el-tab-pane",{attrs:{label:"文件",name:"file"}},[e("div",{staticClass:"el-tab-body-list"},[t.dataList.length?[e("el-table",{staticStyle:{width:"100%"},attrs:{data:t.dataList,height:"450"}},[e("el-table-column",{attrs:{prop:"fileName",label:"文件",width:"300"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("div",{staticClass:"chat-file"},[e("div",[e("el-image",{staticClass:"fileExt",attrs:{fit:"cover",src:t.fileExt(i.row.fileName)}})],1),e("div",{staticClass:"fileName"},[t._v(t._s(i.row.fileName))])])]}}],null,!1,1885044645)}),e("el-table-column",{attrs:{prop:"sendTime",label:"上传时间",width:"160"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(t.formatTime(e.row.sendTime))+" ")]}}],null,!1,349674723)}),e("el-table-column",{attrs:{prop:"fileSize",label:"大小",width:"100"},scopedSlots:t._u([{key:"default",fn:function(e){return[t._v(" "+t._s(t.fileSize(e.row.fileSize))+" ")]}}],null,!1,3523241436)}),e("el-table-column",{attrs:{prop:"fromUser.realname",label:"上传者",width:"100"}}),e("el-table-column",{attrs:{label:"操作"},scopedSlots:t._u([{key:"default",fn:function(i){return[e("el-button",{attrs:{size:"mini"},on:{click:function(e){return t.downloadFile(i.row)}}},[t._v("下载")])]}}],null,!1,2401469366)})],1)]:e("div",[e("el-empty",{attrs:{description:"暂无数据"}})],1)],2)])],1),e("el-pagination",{attrs:{background:"","hide-on-single-page":t.singlePage,"page-size":t.params.limit,"current-page":t.params.page,layout:"prev, pager, next",total:t.total},on:{"update:pageSize":function(e){return t.$set(t.params,"limit",e)},"update:page-size":function(e){return t.$set(t.params,"limit",e)},"update:currentPage":function(e){return t.$set(t.params,"page",e)},"update:current-page":function(e){return t.$set(t.params,"page",e)},"current-change":t.handleCurrentChange}})],1)},n=[],a=function(){var t=this,e=t._self._c;return e("div",{staticClass:"chat-list-item"},[e("div",{staticClass:"chat-list-avatar",on:{click:function(e){return t.$user(t.data.fromUser.id)}}},[e("el-avatar",{attrs:{shape:"square",size:"medium",src:t.data.fromUser.avatar}})],1),e("div",{staticClass:"chat-list-body"},[e("div",{staticClass:"chat-list-title"},[t._v(" "+t._s(t.data.fromUser.realname)+" "),e("span",{staticClass:"time"},[t._v(" "+t._s(t.formatTime(t.data.sendTime)))])]),"text"==t.data.type?e("div",{staticClass:"chat-list-text",domProps:{innerHTML:t._s(t.data.content)}}):t._e(),"text"==t.data.type?e("div",{staticClass:"chat-list-tools"},[e("el-tooltip",{attrs:{effect:"dark",content:"复制文本",placement:"top"}},[e("i",{staticClass:"el-icon-document-copy",on:{click:function(e){return t.copyText(t.data.content)}}})])],1):t._e(),"image"==t.data.type?e("div",{staticClass:"chat-list-image"},[e("el-image",{staticStyle:{"max-width":"300px"},attrs:{src:t.data.content,"z-index":3e3,"preview-src-list":[t.data.content],fit:"contain"}})],1):t._e(),"video"==t.data.type?e("div",{staticClass:"chat-list-video"},[e("video",{staticStyle:{"max-width":"300px"},attrs:{src:t.data.content,controls:""}})]):t._e(),"file"==t.data.type?e("div",{staticClass:"chat-list-file"},[e("el-card",{staticStyle:{width:"260px"},attrs:{"body-style":{padding:"10px 10px 0 10px"}}},[e("div",{staticClass:"chat-file-content"},[e("div",{staticClass:"chat-file-ext"},[e("el-image",{staticStyle:{width:"35px"},attrs:{src:t.fileExt(t.data.fileName),fit:"fill"}})],1),e("div",{staticClass:"chat-file-title"},[e("div",{staticClass:"chat-file-name"},[e("span",{staticClass:"fileName"},[t._v(t._s(t.data.fileName)+" ")]),e("span",{staticClass:"fileSize"},[t._v("("+t._s(t.fileSize(t.data.fileSize))+")")])]),e("div",{staticClass:"chat-file-remark"},[t._v(" 文件已成功发送, 文件助手永久保存 ")])])]),e("hr"),e("div",{staticClass:"bottom clearfix",attrs:{align:"right"}},[e("el-button",{staticClass:"button",attrs:{type:"text"},on:{click:function(e){return t.downloadFile(t.data)}}},[t._v("下载")]),e("el-button",{staticClass:"button",attrs:{type:"text"},on:{click:function(e){return t.onlinePreview(t.data)}}},[t._v("在线预览")])],1)])],1):t._e()])])},r=[],o=i(2325),c=i(3817),l={name:"chatItem",props:{data:{type:Object,default:{}}},computed:{formatTime(){return function(t){return t=parseInt(t/1e3),(0,o.hT)("Y/m/d H:i:s",t)}},fileSize(){return function(t){return(0,c.hR)(t)}},fileExt(){return function(t){return(0,c.AC)(t)}}},data(){return{}},methods:{copyText(t){this.$clipboard(t),this.$message({type:"success",message:"复制成功!"})},onlinePreview(t){this.$preview(t.preview)},downloadFile(t){(0,c.LR)(t.content,t.fileName)}},created(){}},d=l,u=i(1001),h=(0,u.Z)(d,a,r,!1,null,"294ef229",null),p=h.exports,m=function(){var t=this,e=t._self._c;return e("div",[e("el-col",{staticStyle:{padding:"0 12px 12px 0"},attrs:{span:6}},["image"==t.data.type?e("el-card",{attrs:{"body-style":{padding:"0px"}}},[e("el-image",{staticStyle:{width:"100%",height:"120px"},attrs:{src:t.data.content,"preview-src-list":t.previewUrl,"z-index":9999,fit:"cover"}}),e("div",{staticStyle:{padding:"10px"}},[e("div",{staticClass:"bottom clearfix"},[e("time",{staticClass:"time"},[t._v(t._s(t.data.fromUser.realname)+" 上传于 "+t._s(t.formatTime(t.data.sendTime)))])])])],1):t._e()],1)],1)},g=[],f={name:"chatImage",props:{data:{type:Object,default:{}},previewUrl:{type:Array,default:function(){return[]}}},computed:{formatTime(){return function(t){return t=parseInt(t/1e3),(0,o.hT)("Y/m/d",t)}},fileSize(){return function(t){return(0,c.hR)(t)}},fileExt(){return function(t){return(0,c.AC)(t)}}},data(){return{currentDate:new Date}},methods:{copyText(t){this.$clipboard(t),this.$message({type:"success",message:"复制成功!"})},downloadFile(t){(0,c.LR)(t.content,t.fileName)}},created(){}},v=f,b=(0,u.Z)(v,m,g,!1,null,"94e9276a",null),y=b.exports,C={name:"chatRecord",components:{ChatItem:p,ChatImage:y},props:{contact:{type:Object,default:{}},condition:{type:Object,default:{}},manage:{type:Boolean,default:!1}},computed:{formatTime(){return function(t){return t/=1e3,(0,o.hT)("Y/m/d H:i:s",t)}},fileSize(){return function(t){return(0,c.hR)(t)}},fileExt(){return function(t){return(0,c.AC)(t)}}},data(){return{activeName:"all",total:0,singlePage:!1,dataList:[],previewList:[],params:{toContactId:this.contact.id,is_group:this.contact.is_group,type:"all",keywords:"",page:1,limit:20}}},methods:{handleClick(t,e){this.params.page=1,this.params.type=t.name,this.getMessage()},searchMessage(){this.getMessage()},getMessage(){this.manage?this.$api.messageApi.getMessageList(this.params).then((t=>{this.realData(t)})):this.$api.imApi.getMessageListAPI(this.params).then((t=>{this.realData(t)}))},realData(t){this.dataList=t.data,this.total=t.count,t.count<=this.params.limit?this.singlePage=!0:this.singlePage=!1,"image"==this.params.type&&(this.previewList=(0,o.Nj)(t.data,"content",!1))},handleCurrentChange(t){this.params.page=t,this.getMessage()},downloadFile(t){(0,c.LR)(t.content,t.fileName,t.type)}},created(){this.params=Object.assign(this.params,this.condition),this.getMessage()},mounted(){}},x=C,w=(0,u.Z)(x,s,n,!1,null,"3e98c9b5",null),k=w.exports},6038:function(t,e,i){"use strict";i.d(e,{Z:function(){return l}});var s=function(){var t=this,e=t._self._c;return e("el-dialog",{attrs:{title:t.title,visible:t.visible,modal:!0,width:t.width,"append-to-body":""},on:{close:t.closeDialog}},[e("el-transfer",{attrs:{filterable:"",titles:t.createChatTitles,"filter-placeholder":"请输入关键词",props:t.contactsProps,data:t.allUser},model:{value:t.selectUid,callback:function(e){t.selectUid=e},expression:"selectUid"}}),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:t.closeDialog}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:t.comfirmChat}},[t._v("确 定")])],1)],1)},n=[],a={name:"manageGroup",props:{title:{type:String,default:"选择聊天"},visible:{type:Boolean,default:!1},width:{type:String,default:"612px"},allUser:{type:Array,default:()=>[]}},data(){return{createChatTitles:["用户列表","已选用户"],selectUid:[],contactsProps:{key:"id",label:"realname"}}},mounted(){},methods:{closeDialog(){this.$emit("update:visible",!1),this.selectUid=[]},comfirmChat(){0!==this.selectUid.length?this.$emit("selectChat",this.selectUid):this.$message.error("请选择聊天对象")}}},r=a,o=i(1001),c=(0,o.Z)(r,s,n,!1,null,null,null),l=c.exports},4773:function(t,e,i){"use strict";i.d(e,{Z:function(){return h}});var s=function(){var t=this,e=t._self._c;return e("el-container",{staticStyle:{height:"100%"}},[e("el-header",{staticClass:"file-header"},[e("div",{staticClass:"file-header-title"},[t._v("文件列表")]),e("div",{staticClass:"file-header-search"},[e("el-input",{staticStyle:{width:"300px"},attrs:{placeholder:"请输入关键字搜索","prefix-icon":"el-icon-search"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.getFileList.apply(null,arguments)}},model:{value:t.params.keywords,callback:function(e){t.$set(t.params,"keywords",e)},expression:"params.keywords"}},[e("el-button",{attrs:{slot:"append",icon:"el-icon-search"},on:{click:t.getFileList},slot:"append"})],1)],1)]),e("el-container",[e("el-aside",{staticClass:"lz-flex group-box",attrs:{width:"150px"}},[e("div",{staticClass:"group-box-list"},t._l(t.fileType,(function(i){return e("div",{key:i.id,staticClass:"chat-item",class:t.params.cate==i.id?"active":"",on:{click:function(e){return t.openFolder(i)}}},[t._v(" "+t._s(i.name)+" ")])})),0)]),e("el-main",{staticClass:"lz-flex group-box group-user-box no-padding"},[t.fileList.length?e("div",{staticClass:"group-box-list"},[e("el-scrollbar",[e("div",{staticClass:"file-list"},t._l(t.fileList,(function(i,s){return e("el-tooltip",{key:s,staticClass:"item",attrs:{effect:"dark",placement:"right"}},[e("template",{slot:"content"},[e("p",{staticClass:"mb-5"},[t._v("名称:"+t._s(i.name))]),e("p",[t._v("大小:"+t._s(t.getFileSize(i.size)))])]),e("div",{staticClass:"file-item",on:{dblclick:function(e){return t.openFile(i.preview)}}},[e("div",{staticClass:"file-img"},[e("el-image",{staticClass:"img",attrs:{fit:"contain",src:i.extUrl}})],1),e("div",{staticClass:"file-name mt-5",attrs:{align:"center"}},[t._v(t._s(i.name))]),e("div",{staticClass:"file-opt"},[e("el-button",{attrs:{type:"text",size:"mini"},on:{click:function(e){return e.stopPropagation(),t.openFile(i.preview)}}},[t._v("查看")]),e("el-button",{attrs:{type:"text",size:"mini"},on:{click:function(e){return e.stopPropagation(),t.downloadFile(i)}}},[t._v("下载")]),e("el-button",{attrs:{type:"text",size:"mini"},on:{click:function(e){return e.stopPropagation(),t.openDialog(i)}}},[t._v("发送")])],1)])],2)})),1)])],1):e("div",{staticClass:"pd-40"},[e("el-empty")],1),t.singlePage?t._e():e("div",{staticClass:"group-box-page",attrs:{align:"center"}},[e("el-pagination",{attrs:{background:"","hide-on-single-page":t.singlePage,"current-page":t.params.page,"page-sizes":[20,50,100,200,300,400,500],"page-size":t.params.limit,layout:"total, sizes, prev, pager, next, jumper",total:t.total},on:{"size-change":t.handleChange,"current-change":t.getFileList,"update:currentPage":function(e){return t.$set(t.params,"page",e)},"update:current-page":function(e){return t.$set(t.params,"page",e)},"update:pageSize":function(e){return t.$set(t.params,"limit",e)},"update:page-size":function(e){return t.$set(t.params,"limit",e)}}})],1),e("ChooseDialog",{attrs:{visible:t.visible,title:"发送到聊天",allUser:t.$store.state.allContacts},on:{"update:visible":function(e){t.visible=e},selectChat:t.sendChat}})],1)],1)],1)},n=[],a=(i(7658),i(6038)),r=i(3817),o=i(2325),c={components:{ChooseDialog:a.Z},props:{isAll:{type:Number,default:0}},computed:{getFileSize(){return function(t){return r.hR(t)}}},data(){return{params:{page:1,limit:20,keywords:"",cate:0,is_all:this.isAll,role:0},visible:!1,singlePage:!0,total:0,curFile:{},fileType:[{id:0,name:"所有文件",icon:""},{id:1,name:"文档",icon:""},{id:2,name:"图片",icon:""},{id:3,name:"音频",icon:""},{id:4,name:"视频",icon:""},{id:5,name:"其他文件",icon:""}],fileList:[]}},mounted(){this.getFileList()},methods:{changeRole(t){this.params.role=t,this.getFileList()},openFolder(t){this.params.cate=t.id,this.getFileList()},getFileList(){this.$api.imApi.getFileList(this.params).then((t=>{0==t.code&&(this.fileList=t.data,this.total=t.count,this.singlePage=t.count<=this.params.limit,this.params.page=t.page)}))},handleChange(t){this.params.limit=t,this.getFileList()},openFile(t){t?this.$preview(t):this.$message.error("文件不存在")},downloadFile(t){t.download&&(window.location=t.download)},openDialog(t){this.visible=!0,this.curFile=t},sendChat(t){if(t.length>5)return this.$message.error("转发的人数不能超过5人!");let e=this.$store.state.userInfo;this.forwardBox=!1;let i={type:this.curFile.msg_type,content:this.curFile.src,file_name:this.curFile.name,file_size:this.curFile.size,file_id:this.curFile.file_id,fromUser:{id:e.user_id,displayName:e.realname,avatar:e.avatar,account:e.account}};var s=[];t.forEach((t=>{let e=t.toString(),n=JSON.parse(JSON.stringify(i));n.id=o.NW(),n.status="successd",n.sendTime=(new Date).getTime(),n.toContactId=e,n.is_group=0,-1!=e.indexOf("group")&&(n.is_group=1),s.push(this.test(n))})),Promise.all(s).then((t=>{})).catch((t=>{console.log("error",t)})),this.$message.success("发送成功!"),this.visible=!1},fn(t){return new Promise(((e,i)=>{this.$api.imApi.sendMessageAPI(t).then((t=>{0===t.code?e(t):this.$message.error(t.msg)})).catch((t=>{}))}))},async test(t){let e=await this.fn(t);return e}}},l=c,d=i(1001),u=(0,d.Z)(l,s,n,!1,null,"029f4e7e",null),h=u.exports},284:function(t,e,i){"use strict";i.d(e,{Z:function(){return l}});var s=function(){var t=this,e=t._self._c;return e("el-dialog",{attrs:{title:t.title,visible:t.visible,modal:!0,width:t.width,"append-to-body":""},on:{open:t.openDialog,close:t.closeDialog}},[e("div",{directives:[{name:"show",rawName:"v-show",value:t.isAdd,expression:"isAdd"}],staticClass:"mb-20"},[t._v(" 群聊名称:"),e("el-input",{staticStyle:{width:"300px"},attrs:{placeholder:"请输入群聊名称"},model:{value:t.groupName,callback:function(e){t.groupName=e},expression:"groupName"}}),t._v(" "),e("span",{staticClass:"ml-10 c-999"},[t._v(" (必填项)")])],1),e("el-transfer",{attrs:{filterable:"",titles:t.createChatTitles,"filter-placeholder":"请输入关键词",props:t.defaultProps,data:t.allUser},model:{value:t.selectUid,callback:function(e){t.selectUid=e},expression:"selectUid"}}),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:t.closeDialog}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:t.manageGroup}},[t._v("确 定")])],1)],1)},n=[],a={name:"manageGroup",props:{title:{type:String,default:"创建群聊"},visible:{type:Boolean,default:!1},userIds:{type:Array,default:()=>[]},isAdd:{type:Number,default:0},width:{type:String,default:"612px"},groupId:{type:String,default:""}},data(){return{createChatTitles:["用户列表","已选用户"],selectUid:[],allUser:[],groupName:"",defaultProps:{key:"user_id",label:"realname",pinyin:"name_py"}}},mounted(){},methods:{openDialog(){let t={};this.userIds.length>0&&(t.user_ids=this.userIds),this.groupId&&2==this.isAdd&&(t.group_id=this.groupId),this.getAllUser(t)},closeDialog(){this.$emit("update:visible",!1),this.selectUid=[]},manageGroup(){switch(this.isAdd){case 0:if(this.selectUid.length<1)return void this.$message.error("请选择要添加的成员");break;case 1:if(this.selectUid.length<2)return void this.$message.error("群聊人数不能少于2人");if(""==this.groupName||this.groupName.length<2||this.groupName.length>20)return void this.$message.error("请输入正确的群聊名称");break;case 2:if(1!=this.selectUid.length)return void this.$message.error("只能选择一位成员!");break}this.$emit("manageGroup",this.selectUid,this.isAdd,this.groupName)},getAllUser(t){this.$api.imApi.getAllUserAPI(t).then((t=>{const e=t.data;this.allUser=e}))}}},r=a,o=i(1001),c=(0,o.Z)(r,s,n,!1,null,null,null),l=c.exports},8824:function(t,e,i){i(7658),i(2087),i(541),function(e,i){t.exports=i()}("undefined"!==typeof self&&self,(function(){return function(t){var e={};function i(s){if(e[s])return e[s].exports;var n=e[s]={i:s,l:!1,exports:{}};return t[s].call(n.exports,n,n.exports,i),n.l=!0,n.exports}return i.m=t,i.c=e,i.d=function(t,e,s){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:s})},i.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var s=Object.create(null);if(i.r(s),Object.defineProperty(s,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)i.d(s,n,function(e){return t[e]}.bind(null,n));return s},i.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s="fb15")}({"01f9":function(t,e,i){"use strict";var s=i("2d00"),n=i("5ca1"),a=i("2aba"),r=i("32e9"),o=i("84f2"),c=i("41a0"),l=i("7f20"),d=i("38fd"),u=i("2b4c")("iterator"),h=!([].keys&&"next"in[].keys()),p="@@iterator",m="keys",g="values",f=function(){return this};t.exports=function(t,e,i,v,b,y,C){c(i,e,v);var x,w,k,I=function(t){if(!h&&t in S)return S[t];switch(t){case m:return function(){return new i(this,t)};case g:return function(){return new i(this,t)}}return function(){return new i(this,t)}},A=e+" Iterator",_=b==g,E=!1,S=t.prototype,T=S[u]||S[p]||b&&S[b],N=T||I(b),M=b?_?I("entries"):N:void 0,L="Array"==e&&S.entries||T;if(L&&(k=d(L.call(new t)),k!==Object.prototype&&k.next&&(l(k,A,!0),s||"function"==typeof k[u]||r(k,u,f))),_&&T&&T.name!==g&&(E=!0,N=function(){return T.call(this)}),s&&!C||!h&&!E&&S[u]||r(S,u,N),o[e]=N,o[A]=f,b)if(x={values:_?N:I(g),keys:y?N:I(m),entries:M},C)for(w in x)w in S||a(S,w,x[w]);else n(n.P+n.F*(h||E),e,x);return x}},"02f4":function(t,e,i){var s=i("4588"),n=i("be13");t.exports=function(t){return function(e,i){var a,r,o=String(n(e)),c=s(i),l=o.length;return c<0||c>=l?t?"":void 0:(a=o.charCodeAt(c),a<55296||a>56319||c+1===l||(r=o.charCodeAt(c+1))<56320||r>57343?t?o.charAt(c):a:t?o.slice(c,c+2):r-56320+(a-55296<<10)+65536)}}},"0390":function(t,e,i){"use strict";var s=i("02f4")(!0);t.exports=function(t,e,i){return e+(i?s(t,e).length:1)}},"0a49":function(t,e,i){var s=i("9b43"),n=i("626a"),a=i("4bf8"),r=i("9def"),o=i("cd1c");t.exports=function(t,e){var i=1==t,c=2==t,l=3==t,d=4==t,u=6==t,h=5==t||u,p=e||o;return function(e,o,m){for(var g,f,v=a(e),b=n(v),y=s(o,m,3),C=r(b.length),x=0,w=i?p(e,C):c?p(e,0):void 0;C>x;x++)if((h||x in b)&&(g=b[x],f=y(g,x,v),t))if(i)w[x]=f;else if(f)switch(t){case 3:return!0;case 5:return g;case 6:return x;case 2:w.push(g)}else if(d)return!1;return u?-1:l||d?d:w}}},"0bfb":function(t,e,i){"use strict";var s=i("cb7c");t.exports=function(){var t=s(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},"0d58":function(t,e,i){var s=i("ce10"),n=i("e11e");t.exports=Object.keys||function(t){return s(t,n)}},1169:function(t,e,i){var s=i("2d95");t.exports=Array.isArray||function(t){return"Array"==s(t)}},"117e":function(t,e,i){},"11e9":function(t,e,i){var s=i("52a7"),n=i("4630"),a=i("6821"),r=i("6a99"),o=i("69a8"),c=i("c69a"),l=Object.getOwnPropertyDescriptor;e.f=i("9e1e")?l:function(t,e){if(t=a(t),e=r(e,!0),c)try{return l(t,e)}catch(i){}if(o(t,e))return n(!s.f.call(t,e),t[e])}},1495:function(t,e,i){var s=i("86cc"),n=i("cb7c"),a=i("0d58");t.exports=i("9e1e")?Object.defineProperties:function(t,e){n(t);var i,r=a(e),o=r.length,c=0;while(o>c)s.f(t,i=r[c++],e[i]);return t}},"1c4c":function(t,e,i){"use strict";var s=i("9b43"),n=i("5ca1"),a=i("4bf8"),r=i("1fa8"),o=i("33a4"),c=i("9def"),l=i("f1ae"),d=i("27ee");n(n.S+n.F*!i("5cc5")((function(t){Array.from(t)})),"Array",{from:function(t){var e,i,n,u,h=a(t),p="function"==typeof this?this:Array,m=arguments.length,g=m>1?arguments[1]:void 0,f=void 0!==g,v=0,b=d(h);if(f&&(g=s(g,m>2?arguments[2]:void 0,2)),void 0==b||p==Array&&o(b))for(e=c(h.length),i=new p(e);e>v;v++)l(i,v,f?g(h[v],v):h[v]);else for(u=b.call(h),i=new p;!(n=u.next()).done;v++)l(i,v,f?r(u,g,[n.value,v],!0):n.value);return i.length=v,i}})},"1fa8":function(t,e,i){var s=i("cb7c");t.exports=function(t,e,i,n){try{return n?e(s(i)[0],i[1]):e(i)}catch(r){var a=t["return"];throw void 0!==a&&s(a.call(t)),r}}},"20d6":function(t,e,i){"use strict";var s=i("5ca1"),n=i("0a49")(6),a="findIndex",r=!0;a in[]&&Array(1)[a]((function(){r=!1})),s(s.P+s.F*r,"Array",{findIndex:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}}),i("9c6c")(a)},"214f":function(t,e,i){"use strict";i("b0c5");var s=i("2aba"),n=i("32e9"),a=i("79e5"),r=i("be13"),o=i("2b4c"),c=i("520a"),l=o("species"),d=!a((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")})),u=function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var i="ab".split(t);return 2===i.length&&"a"===i[0]&&"b"===i[1]}();t.exports=function(t,e,i){var h=o(t),p=!a((function(){var e={};return e[h]=function(){return 7},7!=""[t](e)})),m=p?!a((function(){var e=!1,i=/a/;return i.exec=function(){return e=!0,null},"split"===t&&(i.constructor={},i.constructor[l]=function(){return i}),i[h](""),!e})):void 0;if(!p||!m||"replace"===t&&!d||"split"===t&&!u){var g=/./[h],f=i(r,h,""[t],(function(t,e,i,s,n){return e.exec===c?p&&!n?{done:!0,value:g.call(e,i,s)}:{done:!0,value:t.call(i,e,s)}:{done:!1}})),v=f[0],b=f[1];s(String.prototype,t,v),n(RegExp.prototype,h,2==e?function(t,e){return b.call(t,this,e)}:function(t){return b.call(t,this)})}}},"230e":function(t,e,i){var s=i("d3f4"),n=i("7726").document,a=s(n)&&s(n.createElement);t.exports=function(t){return a?n.createElement(t):{}}},"23c6":function(t,e,i){var s=i("2d95"),n=i("2b4c")("toStringTag"),a="Arguments"==s(function(){return arguments}()),r=function(t,e){try{return t[e]}catch(i){}};t.exports=function(t){var e,i,o;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(i=r(e=Object(t),n))?i:a?s(e):"Object"==(o=s(e))&&"function"==typeof e.callee?"Arguments":o}},2621:function(t,e){e.f=Object.getOwnPropertySymbols},2638:function(t,e,i){"use strict";function s(){return s=Object.assign?Object.assign.bind():function(t){for(var e,i=1;i<arguments.length;i++)for(var s in e=arguments[i],e)Object.prototype.hasOwnProperty.call(e,s)&&(t[s]=e[s]);return t},s.apply(this,arguments)}var n=["attrs","props","domProps"],a=["class","style","directives"],r=["on","nativeOn"],o=function(t){return t.reduce((function(t,e){for(var i in e)if(t[i])if(-1!==n.indexOf(i))t[i]=s({},t[i],e[i]);else if(-1!==a.indexOf(i)){var o=t[i]instanceof Array?t[i]:[t[i]],l=e[i]instanceof Array?e[i]:[e[i]];t[i]=[].concat(o,l)}else if(-1!==r.indexOf(i))for(var d in e[i])if(t[i][d]){var u=t[i][d]instanceof Array?t[i][d]:[t[i][d]],h=e[i][d]instanceof Array?e[i][d]:[e[i][d]];t[i][d]=[].concat(u,h)}else t[i][d]=e[i][d];else if("hook"===i)for(var p in e[i])t[i][p]=t[i][p]?c(t[i][p],e[i][p]):e[i][p];else t[i]=e[i];else t[i]=e[i];return t}),{})},c=function(t,e){return function(){t&&t.apply(this,arguments),e&&e.apply(this,arguments)}};t.exports=o},"27ee":function(t,e,i){var s=i("23c6"),n=i("2b4c")("iterator"),a=i("84f2");t.exports=i("8378").getIteratorMethod=function(t){if(void 0!=t)return t[n]||t["@@iterator"]||a[s(t)]}},"2aba":function(t,e,i){var s=i("7726"),n=i("32e9"),a=i("69a8"),r=i("ca5a")("src"),o=i("fa5b"),c="toString",l=(""+o).split(c);i("8378").inspectSource=function(t){return o.call(t)},(t.exports=function(t,e,i,o){var c="function"==typeof i;c&&(a(i,"name")||n(i,"name",e)),t[e]!==i&&(c&&(a(i,r)||n(i,r,t[e]?""+t[e]:l.join(String(e)))),t===s?t[e]=i:o?t[e]?t[e]=i:n(t,e,i):(delete t[e],n(t,e,i)))})(Function.prototype,c,(function(){return"function"==typeof this&&this[r]||o.call(this)}))},"2aeb":function(t,e,i){var s=i("cb7c"),n=i("1495"),a=i("e11e"),r=i("613b")("IE_PROTO"),o=function(){},c="prototype",l=function(){var t,e=i("230e")("iframe"),s=a.length,n="<",r=">";e.style.display="none",i("fab2").appendChild(e),e.src="javascript:",t=e.contentWindow.document,t.open(),t.write(n+"script"+r+"document.F=Object"+n+"/script"+r),t.close(),l=t.F;while(s--)delete l[c][a[s]];return l()};t.exports=Object.create||function(t,e){var i;return null!==t?(o[c]=s(t),i=new o,o[c]=null,i[r]=t):i=l(),void 0===e?i:n(i,e)}},"2b4c":function(t,e,i){var s=i("5537")("wks"),n=i("ca5a"),a=i("7726").Symbol,r="function"==typeof a,o=t.exports=function(t){return s[t]||(s[t]=r&&a[t]||(r?a:n)("Symbol."+t))};o.store=s},"2d00":function(t,e){t.exports=!1},"2d95":function(t,e){var i={}.toString;t.exports=function(t){return i.call(t).slice(8,-1)}},"2f21":function(t,e,i){"use strict";var s=i("79e5");t.exports=function(t,e){return!!t&&s((function(){e?t.call(null,(function(){}),1):t.call(null)}))}},"2fdb":function(t,e,i){"use strict";var s=i("5ca1"),n=i("d2c8"),a="includes";s(s.P+s.F*i("5147")(a),"String",{includes:function(t){return!!~n(this,t,a).indexOf(t,arguments.length>1?arguments[1]:void 0)}})},"323d":function(t,e,i){},"32e9":function(t,e,i){var s=i("86cc"),n=i("4630");t.exports=i("9e1e")?function(t,e,i){return s.f(t,e,n(1,i))}:function(t,e,i){return t[e]=i,t}},"33a4":function(t,e,i){var s=i("84f2"),n=i("2b4c")("iterator"),a=Array.prototype;t.exports=function(t){return void 0!==t&&(s.Array===t||a[n]===t)}},3846:function(t,e,i){i("9e1e")&&"g"!=/./g.flags&&i("86cc").f(RegExp.prototype,"flags",{configurable:!0,get:i("0bfb")})},"38fd":function(t,e,i){var s=i("69a8"),n=i("4bf8"),a=i("613b")("IE_PROTO"),r=Object.prototype;t.exports=Object.getPrototypeOf||function(t){return t=n(t),s(t,a)?t[a]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?r:null}},"3b2b":function(t,e,i){var s=i("7726"),n=i("5dbc"),a=i("86cc").f,r=i("9093").f,o=i("aae3"),c=i("0bfb"),l=s.RegExp,d=l,u=l.prototype,h=/a/g,p=/a/g,m=new l(h)!==h;if(i("9e1e")&&(!m||i("79e5")((function(){return p[i("2b4c")("match")]=!1,l(h)!=h||l(p)==p||"/a/i"!=l(h,"i")})))){l=function(t,e){var i=this instanceof l,s=o(t),a=void 0===e;return!i&&s&&t.constructor===l&&a?t:n(m?new d(s&&!a?t.source:t,e):d((s=t instanceof l)?t.source:t,s&&a?c.call(t):e),i?this:u,l)};for(var g=function(t){t in l||a(l,t,{configurable:!0,get:function(){return d[t]},set:function(e){d[t]=e}})},f=r(d),v=0;f.length>v;)g(f[v++]);u.constructor=l,l.prototype=u,i("2aba")(s,"RegExp",l)}i("7a56")("RegExp")},"3bcf":function(t,e,i){},"41a0":function(t,e,i){"use strict";var s=i("2aeb"),n=i("4630"),a=i("7f20"),r={};i("32e9")(r,i("2b4c")("iterator"),(function(){return this})),t.exports=function(t,e,i){t.prototype=s(r,{next:n(1,i)}),a(t,e+" Iterator")}},"456d":function(t,e,i){var s=i("4bf8"),n=i("0d58");i("5eda")("keys",(function(){return function(t){return n(s(t))}}))},4588:function(t,e){var i=Math.ceil,s=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?s:i)(t)}},4630:function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},"4bf8":function(t,e,i){var s=i("be13");t.exports=function(t){return Object(s(t))}},"4c77":function(t,e,i){"use strict";i("d6f8")},"504c":function(t,e,i){var s=i("9e1e"),n=i("0d58"),a=i("6821"),r=i("52a7").f;t.exports=function(t){return function(e){var i,o=a(e),c=n(o),l=c.length,d=0,u=[];while(l>d)i=c[d++],s&&!r.call(o,i)||u.push(t?[i,o[i]]:o[i]);return u}}},5147:function(t,e,i){var s=i("2b4c")("match");t.exports=function(t){var e=/./;try{"/./"[t](e)}catch(i){try{return e[s]=!1,!"/./"[t](e)}catch(n){}}return!0}},"520a":function(t,e,i){"use strict";var s=i("0bfb"),n=RegExp.prototype.exec,a=String.prototype.replace,r=n,o="lastIndex",c=function(){var t=/a/,e=/b*/g;return n.call(t,"a"),n.call(e,"a"),0!==t[o]||0!==e[o]}(),l=void 0!==/()??/.exec("")[1],d=c||l;d&&(r=function(t){var e,i,r,d,u=this;return l&&(i=new RegExp("^"+u.source+"$(?!\\s)",s.call(u))),c&&(e=u[o]),r=n.call(u,t),c&&r&&(u[o]=u.global?r.index+r[0].length:e),l&&r&&r.length>1&&a.call(r[0],i,(function(){for(d=1;d<arguments.length-2;d++)void 0===arguments[d]&&(r[d]=void 0)})),r}),t.exports=r},"52a7":function(t,e){e.f={}.propertyIsEnumerable},5537:function(t,e,i){var s=i("8378"),n=i("7726"),a="__core-js_shared__",r=n[a]||(n[a]={});(t.exports=function(t,e){return r[t]||(r[t]=void 0!==e?e:{})})("versions",[]).push({version:s.version,mode:i("2d00")?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},"55dd":function(t,e,i){"use strict";var s=i("5ca1"),n=i("d8e8"),a=i("4bf8"),r=i("79e5"),o=[].sort,c=[1,2,3];s(s.P+s.F*(r((function(){c.sort(void 0)}))||!r((function(){c.sort(null)}))||!i("2f21")(o)),"Array",{sort:function(t){return void 0===t?o.call(a(this)):o.call(a(this),n(t))}})},5778:function(t,e,i){"use strict";i("80be")},"5ca1":function(t,e,i){var s=i("7726"),n=i("8378"),a=i("32e9"),r=i("2aba"),o=i("9b43"),c="prototype",l=function(t,e,i){var d,u,h,p,m=t&l.F,g=t&l.G,f=t&l.S,v=t&l.P,b=t&l.B,y=g?s:f?s[e]||(s[e]={}):(s[e]||{})[c],C=g?n:n[e]||(n[e]={}),x=C[c]||(C[c]={});for(d in g&&(i=e),i)u=!m&&y&&void 0!==y[d],h=(u?y:i)[d],p=b&&u?o(h,s):v&&"function"==typeof h?o(Function.call,h):h,y&&r(y,d,h,t&l.U),C[d]!=h&&a(C,d,p),v&&x[d]!=h&&(x[d]=h)};s.core=n,l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,t.exports=l},"5cc5":function(t,e,i){var s=i("2b4c")("iterator"),n=!1;try{var a=[7][s]();a["return"]=function(){n=!0},Array.from(a,(function(){throw 2}))}catch(r){}t.exports=function(t,e){if(!e&&!n)return!1;var i=!1;try{var a=[7],o=a[s]();o.next=function(){return{done:i=!0}},a[s]=function(){return o},t(a)}catch(r){}return i}},"5dbc":function(t,e,i){var s=i("d3f4"),n=i("8b97").set;t.exports=function(t,e,i){var a,r=e.constructor;return r!==i&&"function"==typeof r&&(a=r.prototype)!==i.prototype&&s(a)&&n&&n(t,a),t}},"5df3":function(t,e,i){"use strict";var s=i("02f4")(!0);i("01f9")(String,"String",(function(t){this._t=String(t),this._i=0}),(function(){var t,e=this._t,i=this._i;return i>=e.length?{value:void 0,done:!0}:(t=s(e,i),this._i+=t.length,{value:t,done:!1})}))},"5eda":function(t,e,i){var s=i("5ca1"),n=i("8378"),a=i("79e5");t.exports=function(t,e){var i=(n.Object||{})[t]||Object[t],r={};r[t]=e(i),s(s.S+s.F*a((function(){i(1)})),"Object",r)}},"5f1b":function(t,e,i){"use strict";var s=i("23c6"),n=RegExp.prototype.exec;t.exports=function(t,e){var i=t.exec;if("function"===typeof i){var a=i.call(t,e);if("object"!==typeof a)throw new TypeError("RegExp exec method returned something other than an Object or null");return a}if("RegExp"!==s(t))throw new TypeError("RegExp#exec called on incompatible receiver");return n.call(t,e)}},"613b":function(t,e,i){var s=i("5537")("keys"),n=i("ca5a");t.exports=function(t){return s[t]||(s[t]=n(t))}},"61c8":function(t,e,i){},"626a":function(t,e,i){var s=i("2d95");t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==s(t)?t.split(""):Object(t)}},6762:function(t,e,i){"use strict";var s=i("5ca1"),n=i("c366")(!0);s(s.P,"Array",{includes:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}}),i("9c6c")("includes")},6821:function(t,e,i){var s=i("626a"),n=i("be13");t.exports=function(t){return s(n(t))}},"69a8":function(t,e){var i={}.hasOwnProperty;t.exports=function(t,e){return i.call(t,e)}},"69bb":function(t,e,i){"use strict";i("ba05")},"6a2b":function(t,e,i){},"6a99":function(t,e,i){var s=i("d3f4");t.exports=function(t,e){if(!s(t))return t;var i,n;if(e&&"function"==typeof(i=t.toString)&&!s(n=i.call(t)))return n;if("function"==typeof(i=t.valueOf)&&!s(n=i.call(t)))return n;if(!e&&"function"==typeof(i=t.toString)&&!s(n=i.call(t)))return n;throw TypeError("Can't convert object to primitive value")}},"6b54":function(t,e,i){"use strict";i("3846");var s=i("cb7c"),n=i("0bfb"),a=i("9e1e"),r="toString",o=/./[r],c=function(t){i("2aba")(RegExp.prototype,r,t,!0)};i("79e5")((function(){return"/a/b"!=o.call({source:"a",flags:"b"})}))?c((function(){var t=s(this);return"/".concat(t.source,"/","flags"in t?t.flags:!a&&t instanceof RegExp?n.call(t):void 0)})):o.name!=r&&c((function(){return o.call(this)}))},"6fb5":function(t,e,i){},"718e":function(t,e,i){"use strict";i("dfa9")},7333:function(t,e,i){"use strict";var s=i("9e1e"),n=i("0d58"),a=i("2621"),r=i("52a7"),o=i("4bf8"),c=i("626a"),l=Object.assign;t.exports=!l||i("79e5")((function(){var t={},e={},i=Symbol(),s="abcdefghijklmnopqrst";return t[i]=7,s.split("").forEach((function(t){e[t]=t})),7!=l({},t)[i]||Object.keys(l({},e)).join("")!=s}))?function(t,e){var i=o(t),l=arguments.length,d=1,u=a.f,h=r.f;while(l>d){var p,m=c(arguments[d++]),g=u?n(m).concat(u(m)):n(m),f=g.length,v=0;while(f>v)p=g[v++],s&&!h.call(m,p)||(i[p]=m[p])}return i}:l},7514:function(t,e,i){"use strict";var s=i("5ca1"),n=i("0a49")(5),a="find",r=!0;a in[]&&Array(1)[a]((function(){r=!1})),s(s.P+s.F*r,"Array",{find:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}}),i("9c6c")(a)},7726:function(t,e){var i=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=i)},"77f1":function(t,e,i){var s=i("4588"),n=Math.max,a=Math.min;t.exports=function(t,e){return t=s(t),t<0?n(t+e,0):a(t,e)}},"79e5":function(t,e){t.exports=function(t){try{return!!t()}catch(e){return!0}}},"7a56":function(t,e,i){"use strict";var s=i("7726"),n=i("86cc"),a=i("9e1e"),r=i("2b4c")("species");t.exports=function(t){var e=s[t];a&&e&&!e[r]&&n.f(e,r,{configurable:!0,get:function(){return this}})}},"7f20":function(t,e,i){var s=i("86cc").f,n=i("69a8"),a=i("2b4c")("toStringTag");t.exports=function(t,e,i){t&&!n(t=i?t:t.prototype,a)&&s(t,a,{configurable:!0,value:e})}},"7f7f":function(t,e,i){var s=i("86cc").f,n=Function.prototype,a=/^\s*function ([^ (]*)/,r="name";r in n||i("9e1e")&&s(n,r,{configurable:!0,get:function(){try{return(""+this).match(a)[1]}catch(t){return""}}})},"80be":function(t,e,i){},8378:function(t,e){var i=t.exports={version:"2.6.12"};"number"==typeof __e&&(__e=i)},"83a1":function(t,e,i){},"84f2":function(t,e){t.exports={}},"85ff":function(t,e,i){"use strict";i("cb50")},8615:function(t,e,i){var s=i("5ca1"),n=i("504c")(!1);s(s.S,"Object",{values:function(t){return n(t)}})},"86cc":function(t,e,i){var s=i("cb7c"),n=i("c69a"),a=i("6a99"),r=Object.defineProperty;e.f=i("9e1e")?Object.defineProperty:function(t,e,i){if(s(t),e=a(e,!0),s(i),n)try{return r(t,e,i)}catch(o){}if("get"in i||"set"in i)throw TypeError("Accessors not supported!");return"value"in i&&(t[e]=i.value),t}},"8b97":function(t,e,i){var s=i("d3f4"),n=i("cb7c"),a=function(t,e){if(n(t),!s(e)&&null!==e)throw TypeError(e+": can't set as prototype!")};t.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(t,e,s){try{s=i("9b43")(Function.call,i("11e9").f(Object.prototype,"__proto__").set,2),s(t,[]),e=!(t instanceof Array)}catch(n){e=!0}return function(t,i){return a(t,i),e?t.__proto__=i:s(t,i),t}}({},!1):void 0),check:a}},"8bcf":function(t,e,i){},"8e6e":function(t,e,i){var s=i("5ca1"),n=i("990b"),a=i("6821"),r=i("11e9"),o=i("f1ae");s(s.S,"Object",{getOwnPropertyDescriptors:function(t){var e,i,s=a(t),c=r.f,l=n(s),d={},u=0;while(l.length>u)i=c(s,e=l[u++]),void 0!==i&&o(d,e,i);return d}})},"8fb6":function(t,e,i){"use strict";i("83a1")},9093:function(t,e,i){var s=i("ce10"),n=i("e11e").concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return s(t,n)}},9204:function(t,e){var i=Object.defineProperty,s=(t,e,s)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[e]=s,n=(t,e,i)=>(s(t,"symbol"!=typeof e?e+"":e,i),i);(function(){const t=document.createElement("link").relList;if(!(t&&t.supports&&t.supports("modulepreload"))){for(const t of document.querySelectorAll('link[rel="modulepreload"]'))i(t);new MutationObserver((t=>{for(const e of t)if("childList"===e.type)for(const t of e.addedNodes)"LINK"===t.tagName&&"modulepreload"===t.rel&&i(t)})).observe(document,{childList:!0,subtree:!0})}function e(t){const e={};return t.integrity&&(e.integrity=t.integrity),t.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),"use-credentials"===t.crossOrigin?e.credentials="include":"anonymous"===t.crossOrigin?e.credentials="omit":e.credentials="same-origin",e}function i(t){if(t.ep)return;t.ep=!0;const i=e(t);fetch(t.href,i)}})();class a{constructor(t){n(this,"richText"),n(this,"vnode"),n(this,"cursorIndex"),n(this,"cursorLeft"),n(this,"needCallSpace",!1),n(this,"VOID_KEY","\ufeff"),n(this,"ZERO_WIDTH_KEY","​"),n(this,"pointEndIME"),n(this,"IME_KEY","​_"),this.richText=t,this.textInnerHtmlInit(),this.richText.focus()}textInnerHtmlInit(t=!1,e){if(t||this.getNodeEmpty(this.richText)){this.richText.innerHTML="";const t=this.getGridElm();this.richText.appendChild(t);const i=t.children[0].children[0];e&&(i.innerHTML=e,i.setAttribute("data-set-empty","false"));const s=i.childNodes[0];this.restCursorPos(s,s.textContent===this.VOID_KEY?1:s.textContent.length)}}onceCall(t,e=!1,i=""){return new Promise((s=>{const n=this.createAtUserSpan(t),a=this.replaceRegContent(n,!0,e,i)||"";s(a)}))}searchCall(t,e){return new Promise((i=>{const s=this.createAtUserSpan(t);this.replaceRegContent(s,e),i()}))}onceExternalCall(t){return new Promise((e=>{const i=this.createAtUserSpan(t),s=this.replaceRegContent(i,!1,!0)||"";e(s)}))}upDataNodeOrIndex(){var t,e,i;const{focusNode:s,focusOffset:n,anchorOffset:a}=window.getSelection(),r=(null==s?void 0:s.parentNode)||void 0;!r||!r.getAttribute||"richInput"!==r.getAttribute("data-set-richType")||(null==(i=null==(e=null==(t=null==s?void 0:s.parentNode)?void 0:t.parentNode)?void 0:e.parentNode)?void 0:i.parentNode)!==this.richText||(this.vnode=s,this.cursorIndex=n,this.cursorLeft=a<n?a:n)}showAt(){if(this.upDataNodeOrIndex(),!this.vnode||this.vnode.nodeType!==Node.TEXT_NODE)return!1;const t=this.vnode.textContent||"",e=/@([^@\s]*)$/,i=t.slice(0,this.cursorIndex),s=e.exec(i);return s&&2===s.length&&"@"===i[i.length-1]}getRangeRect(){let t=0,e=0;const i=window.getSelection().getRangeAt(0).getClientRects()[0];return i&&(t=i.x,e=i.y),{x:t,y:e}}createAtUserSpan(t){const e=document.createElement("span");return e.dataset.userId=String(t.id),e.className="at-user",e.contentEditable="false",e.textContent=`@${t.name}${this.needCallSpace?" ":""}`,this.createNewDom(e)}createNewDom(t){const e=document.createElement("span");return e.className="chat-tag",e.setAttribute("contenteditable","false"),e.setAttribute("data-set-richType","chatTag"),t.className+=" chat-stat",e.appendChild(t),e}restCursorPos(t,e){null==e?e=t.textContent===this.VOID_KEY?1:0:e>t.textContent.length&&(e=t.textContent.length);const i=new Range;i.setStart(t,e),i.setEnd(t,e);const s=window.getSelection();s&&(this.vnode=t,this.cursorIndex=e,this.cursorLeft=e,s.removeAllRanges(),s.addRange(i))}setCursorPos(t,e){const i=window.getSelection();if(i.rangeCount<=0)return;const s=i.getRangeAt(0);s.setStart(t,e),s.collapse(!0),this.vnode=t,this.cursorIndex=e,this.cursorLeft=e}replaceRegContent(t,e=!1,i=!1,s=""){const n=this.vnode.textContent;let a;a="boolean"==typeof e?n.slice(0,e?this.cursorIndex-1:this.cursorIndex):n.slice(0,e-1),0===a.length?(this.vnode.parentElement.setAttribute("data-set-empty",!0),this.vnode.textContent=this.VOID_KEY):this.vnode.textContent=a;let r=s||n.slice(this.cursorIndex);const o=this.vnode.parentNode.parentNode,c=o.nextSibling;c?o.parentNode.insertBefore(t,c):o.parentNode.appendChild(t);const l=t.previousSibling.childNodes[0],d=l.childNodes[1];d&&l.removeChild(d);const u=this.getGridElm(!0),h=u.childNodes[0];!i&&r&&r!==this.VOID_KEY&&(h.setAttribute("data-set-empty","false"),h.innerHTML=r);const p=h.childNodes[1];return i&&p&&h.removeChild(p),t.nextSibling?(p&&h.removeChild(p),o.parentNode.insertBefore(u,t.nextSibling)):o.parentNode.appendChild(u),this.restCursorPos(h.childNodes[0]),r}switchRange(t){var e,i;const{focusNode:s,focusOffset:n}=window.getSelection();let a,r;if(s.nodeType===Node.TEXT_NODE){const o=s.textContent.length,c=s.parentNode.parentNode;switch(t){case"ArrowLeft":if(n>0&&s.textContent!==this.VOID_KEY){r=n-1,a=s;break}const t=null==(e=null==c?void 0:c.previousSibling)?void 0:e.previousSibling;if(t)a=t.childNodes[0].childNodes[0],r=a.textContent.length;else{const t=c.parentNode.previousSibling;t&&(a=t.lastChild.childNodes[0].childNodes[0],r=a.textContent.length)}break;case"ArrowRight":if(n<o&&s.textContent!==this.VOID_KEY){r=n+1,a=s;break}const l=null==(i=null==c?void 0:c.nextSibling)?void 0:i.nextSibling;if(l)a=l.childNodes[0].childNodes[0],r=a.textContent===this.VOID_KEY?1:0;else{const t=c.parentNode.nextSibling;t&&(a=t.childNodes[0].childNodes[0].childNodes[0],r=a.textContent===this.VOID_KEY?1:0)}break}}(r||0===r)&&this.restCursorPos(a,r)}getGridElm(t=!1){const e=document.createElement("span");if(e.setAttribute("data-set-richType","richMark"),e.innerHTML=`<span class="chat-grid-input chat-stat" data-set-richType="richInput" data-set-empty="true">${this.VOID_KEY}<br></span>`,t)return e;const i=document.createElement("p");return i.className="chat-grid-wrap",i.setAttribute("data-set-richType","richBox"),i.appendChild(e),i}updateGrid(){const t=window.getSelection(),e=t.focusNode,i=e.parentNode,s=i.getAttribute("data-set-richType");let n,a,r,o;switch(s){case"richAllBox":if(n=e.childNodes[t.focusOffset],!n||"chatTag"===n.getAttribute("data-set-richType")){const t=this.getGridElm(!0),i=t.children[0];n?(i.removeChild(i.childNodes[1]),e.insertBefore(t,n)):e.appendChild(t),this.restCursorPos(i.childNodes[0]);break}if("BR"===n.tagName){const t=this.getGridElm(!0),i=t.children[0];e.insertBefore(t,n),e.removeChild(n),this.restCursorPos(i.childNodes[0],i.childNodes[0].textContent.length)}break;case"richMark":const s=i.parentNode,c=Array.prototype.indexOf.call(s.childNodes,i);if(-1===c)break;if(0===c){const e=t.focusNode;e.setAttribute("data-set-empty","true"),e.innerHTML=this.VOID_KEY+"<br>",n=e.childNodes[0],this.restCursorPos(n,n.textContent.length);break}let l,d=i.previousSibling;"chatTag"===d.getAttribute("data-set-richType")?(l=d.previousSibling,s.removeChild(d),s.removeChild(i)):(l=i.previousSibling,s.removeChild(i)),n=l.childNodes[0].childNodes[0],n.textContent===this.VOID_KEY&&n.parentNode.appendChild(document.createElement("br")),this.restCursorPos(n,n.textContent.length);break;case"richInput":if(o=i.parentNode,r=o.parentNode,this.getNodeEmpty(i)){i.setAttribute("data-set-empty","true"),r.childNodes[r.childNodes.length-1]===o&&(i.innerHTML=this.VOID_KEY+"<br>"),n=i.childNodes[0],this.restCursorPos(n,n.textContent.length);break}if("true"===String(i.getAttribute("data-set-empty"))){i.setAttribute("data-set-empty","false");const t=[],e=[];Array.prototype.forEach.call(i.childNodes,(i=>{i.nodeType===Node.TEXT_NODE&&-1!==i.textContent.indexOf(this.VOID_KEY)?e.push(i):"BR"===i.tagName&&t.push(i)})),t.forEach((t=>{i.removeChild(t)})),e.forEach((t=>{const e=t.textContent.indexOf(this.VOID_KEY),i=new Range;i.setStart(t,t.textContent.indexOf(this.VOID_KEY)),i.setEnd(t,e+1),i.deleteContents()})),n=i.childNodes[0],this.restCursorPos(n,n.textContent.length)}if(a=i.parentNode.nextSibling,a&&a.nodeType===Node.TEXT_NODE){let t=a.textContent,e=this.getGridElm(!0);e.childNodes[0].textContent=t,e.childNodes[0].setAttribute("data-set-empty","false"),a.parentNode.insertBefore(e,a),a.parentNode.removeChild(a),a=e}a&&"richMark"===a.getAttribute("data-set-richType")&&this.markMerge(i.parentNode,a);break}}getNodeEmpty(t){const e=new RegExp(`^(${this.ZERO_WIDTH_KEY}|<br>|${this.VOID_KEY})+$`);return!t.innerHTML||e.test(t.innerHTML)}setWrap(){const t=window.getSelection();let{focusNode:e,focusOffset:i}=t;if(e.nodeType!==Node.TEXT_NODE){if(!e.getAttribute||"richInput"!==e.getAttribute("data-set-richType"))return;e=e.childNodes[0]}const s=e.textContent.slice(i),n=e.parentNode.parentNode,a=n.parentNode,r=Array.prototype.indexOf.call(a.childNodes,n),o=Array.prototype.slice.call(a.childNodes,r+1),c=this.getGridElm();let l=c.children[0].children[0].childNodes[0],d=1;(s||o.length>0)&&l.parentNode.removeChild(l.parentNode.childNodes[1]),s&&s!==this.VOID_KEY&&(e.textContent=e.textContent.slice(0,i),l.textContent=(l.textContent+s).replace(new RegExp(this.VOID_KEY,"g"),(()=>(d--,""))),l.parentElement.setAttribute("data-set-empty","false")),o.forEach((t=>{a.removeChild(t),c.appendChild(t)}));const u=a.lastChild.childNodes[0],h=c.lastChild.childNodes[0];if(u.childNodes.length<=1){const t=u.childNodes[0];(!t.textContent||t.textContent===this.VOID_KEY)&&(u.innerHTML=this.VOID_KEY+"<br>",u.setAttribute("data-set-empty","true"))}if("richMark"!==h.parentElement.getAttribute("data-set-richType"))c.appendChild(this.getGridElm(!0));else if(h.childNodes.length<=1){const t=h.childNodes[0];(!t.textContent||t.textContent===this.VOID_KEY)&&(h.innerHTML=this.VOID_KEY+"<br>",h.setAttribute("data-set-empty","true"),l=c.children[0].children[0].childNodes[0])}a.nextSibling?this.richText.insertBefore(c,a.nextSibling):this.richText.appendChild(c),this.restCursorPos(l,l.textContent===this.VOID_KEY?1:d),this.viewIntoPoint()}selectRegionMerge(){const t=window.getSelection();if(t.isCollapsed||t.rangeCount<=0)return;const e=t.getRangeAt(0);if(e.startContainer.nodeType===Node.TEXT_NODE&&e.startContainer===e.endContainer){const t=e.startContainer;if(t.length===e.endOffset-e.startOffset){const e=t.parentNode,i=e.parentNode===e.parentNode.parentNode.lastChild;e.setAttribute("data-set-empty","true"),e.innerHTML="\ufeff"+(i?"<br>":""),this.restCursorPos(e.childNodes[0])}else e.deleteContents()}else if(e.commonAncestorContainer&&"richBox"===e.commonAncestorContainer.getAttribute("data-set-richType")){const t=e.startContainer.nodeType===Node.TEXT_NODE?e.startContainer.parentNode.parentNode:e.startContainer,i=e.endContainer.nodeType===Node.TEXT_NODE?e.endContainer.parentNode.parentNode:e.endContainer;e.deleteContents(),t.getAttribute("data-set-richType")===i.getAttribute("data-set-richType")&&this.markMerge(t,i)}else if(e.commonAncestorContainer===e.startContainer&&e.startContainer===e.endContainer)this.textInnerHtmlInit(!0);else{const t=t=>{if(t.nodeType===Node.TEXT_NODE)return t.parentNode.parentNode.parentNode;switch(t.getAttribute("data-set-richType")){case"richInput":return t.parentNode.parentNode;case"richMark":return t.parentNode;case"richBox":return t;default:return null}},i=t(e.startContainer),s=t(e.endContainer);if(!i||!s)return;e.deleteContents(),this.gridMerge(i,s)}return!0}gridElmMerge(){const t=window.getSelection(),{focusNode:e,focusOffset:i,isCollapsed:s}=t;if(i>1||!s)return!1;const n=(t,e)=>(t.parentNode===this.richText||t===t.parentNode.childNodes[0])&&(-1!==Array.prototype.indexOf.call(this.richText.childNodes,t)?t:!(e>=6)&&n(t.parentNode,e+1)),a=n(e,0);if(!a||a===this.richText.childNodes[0]||1===i&&"false"===a.children[0].children[0].getAttribute("data-set-empty"))return!1;const r=a.previousSibling;return this.gridMerge(r,a),!0}delMarkRule(){const t=window.getSelection(),e=t.focusNode,i=e.textContent,s=e.parentNode,n=s.parentNode,a=n.parentNode;if(!t.isCollapsed||"richInput"!==s.getAttribute("data-set-richType"))return!1;if(i&&1===i.length&&n!==a.childNodes[0]&&(0!==t.focusOffset||i===this.VOID_KEY)){if(i===this.VOID_KEY){const t=n.previousSibling.previousSibling;a.removeChild(n.previousSibling),a.removeChild(n);const e=t.childNodes[0],i=e.childNodes[0];i.textContent===this.VOID_KEY&&t===a.lastChild&&e.appendChild(document.createElement("br")),this.restCursorPos(i,i.textContent.length)}else{s.innerHTML=n===a.lastChild?this.VOID_KEY+"<br>":this.VOID_KEY,s.setAttribute("data-set-empty","true");const t=s.childNodes[0];this.restCursorPos(t,1)}return!0}if(0===t.focusOffset){const t=s.parentNode,e=null==t?void 0:t.previousSibling;return!(!e||"chatTag"!==e.getAttribute("data-set-richType"))&&(this.delTag(e),!0)}}setIMESelection(){const t=window.getSelection(),e=t.focusNode,i=e.parentNode.parentNode;"richMark"===((null==i?void 0:i.getAttribute("data-set-richType"))||"")&&(this.pointEndIME=t.focusOffset,e.textContent=e.textContent.slice(0,this.pointEndIME)+this.IME_KEY+e.textContent.slice(this.pointEndIME),this.restCursorPos(e,this.pointEndIME+this.IME_KEY.length))}delMarkRuleIME(){const t=window.getSelection(),e=t.focusNode,i=e.parentNode,s=i.parentNode;if("richMark"===((null==s?void 0:s.getAttribute("data-set-richType"))||"")){this.pointEndIME=t.focusOffset;const n=new RegExp(this.IME_KEY.slice(0,-1),"g");if(e.textContent=e.textContent.replace(n,""),this.pointEndIME>this.IME_KEY.length-1&&e.textContent!==this.VOID_KEY){const t=this.pointEndIME-(this.IME_KEY.length-1);e.textContent=e.textContent.slice(0,t-1)+e.textContent.slice(t),this.setCursorPos(e,t-1)}else{if("false"===i.getAttribute("data-set-empty")&&(""===e.textContent||e.textContent===this.VOID_KEY)){i.innerHTML=s===s.parentElement.lastChild?this.VOID_KEY+"<br>":this.VOID_KEY,i.setAttribute("data-set-empty","true");const t=i.childNodes[0];return void this.setCursorPos(t,1)}const t=s.previousSibling;if(t&&t.getAttribute&&"chatTag"===t.getAttribute("data-set-richType"))return void this.delTag(t);const n=s.parentElement,a=n.previousElementSibling;a&&this.gridMerge(a,n)}}}wrapIME(){const t=window.getSelection().focusNode;if(t.getAttribute&&"richBox"===t.getAttribute("data-set-richType")){const e=t.previousSibling.lastChild.children[0].childNodes[0];e.textContent=e.textContent.slice(0,-this.IME_KEY.length);const i=t.children[0];return void("BR"===i.tagName&&t.removeChild(i))}const e=t.parentNode.parentNode,i=(null==e?void 0:e.getAttribute("data-set-richType"))||"";if("richMark"===i){const t=e.parentElement.previousSibling.lastChild.children[0].childNodes[0];t.textContent=t.textContent.slice(0,-this.IME_KEY.length)}else if("richBox"===i){const t=e.previousSibling.lastChild.children[0].childNodes[0];t.textContent=t.textContent.slice(0,-this.IME_KEY.length)}}resetIME(t){" "===t&&(t=" "),t||(t="");const e=window.getSelection(),i=e.focusNode,s=i.parentNode.parentNode;"richMark"===((null==s?void 0:s.getAttribute("data-set-richType"))||"")&&(i.textContent=i.textContent.slice(0,e.focusOffset-this.IME_KEY.length-t.length)+t+i.textContent.slice(e.focusOffset),i.textContent=i.textContent.replace(new RegExp(this.ZERO_WIDTH_KEY,"g"),""),this.setCursorPos(i,this.pointEndIME+t.length))}delTag(t){const e=t.previousSibling,i=t.nextSibling;t.parentNode.removeChild(t),this.markMerge(e,i)}gridMerge(t,e,i=!1){"richMark"!==t.lastChild.getAttribute("data-set-richType")&&t.appendChild(this.getGridElm(!0)),"richMark"!==e.childNodes[0].getAttribute("data-set-richType")&&e.insertBefore(this.getGridElm(!0),e.childNodes[0]);const s=t.lastChild.childNodes[0],n=s.childNodes[0];let a=n.textContent.length;Array.prototype.forEach.call(e.childNodes,(e=>{t.appendChild(e.cloneNode(!0))})),e.childNodes.length>1&&s.childNodes[1]&&s.removeChild(s.childNodes[1]);const r=s.parentNode.nextSibling;if(r){const e=r.children[0].childNodes[0];e&&e.textContent!==this.VOID_KEY&&(s.childNodes[1]&&s.removeChild(s.childNodes[1]),n.textContent=(n.textContent+e.textContent).replace(new RegExp(this.VOID_KEY,"g"),(()=>(a--,""))),n.parentElement.setAttribute("data-set-empty","false")),t.removeChild(r)}if(""===n.textContent&&(n.textContent=this.VOID_KEY,n.parentNode.setAttribute("data-set-empty","true"),a=1),i){const e=t.childNodes[t.childNodes.length-1].childNodes[0].childNodes[0];this.restCursorPos(e,e.textContent.length)}else this.richText.removeChild(e),this.restCursorPos(n,a);this.viewIntoPoint()}markMerge(t,e){const i=t.children[0].childNodes[0];let s=i.textContent.length;if(e){const t=e.children[0].childNodes[0];t&&t.textContent!==this.VOID_KEY&&(i.textContent=(i.textContent+t.textContent).replace(new RegExp(this.VOID_KEY,"g"),(()=>(s--,""))),i.parentElement.setAttribute("data-set-empty","false")),e.parentNode.removeChild(e)}""===i.textContent&&(i.textContent=this.VOID_KEY,i.parentNode.setAttribute("data-set-empty","true"),s=1);const n=t.parentNode;i.textContent===this.VOID_KEY&&t===n.lastChild&&(i.parentNode.appendChild(document.createElement("br")),i.parentNode.setAttribute("data-set-empty","true"),s=1),this.restCursorPos(i,s)}setCallSpace(t){this.needCallSpace=t}getWrapNode(t){if(t.nodeType===Node.TEXT_NODE)return t.parentNode.parentNode.parentNode;switch(t.getAttribute("data-set-richType")){case"richInput":return t.parentNode.parentNode;case"richMark":return t.parentNode;case"richBox":return t}}getMarkNode(t){if(t.nodeType===Node.TEXT_NODE)return t.parentNode.parentNode;switch(t.getAttribute("data-set-richType")){case"richInput":return t.parentNode;case"richMark":return t}}getRichTextNodeIndex(t){const e=this.getMarkNode(t),i=e.parentNode;return{gridIndex:Array.prototype.indexOf.call(this.richText.childNodes,i),markIndex:Array.prototype.indexOf.call(i.childNodes,e)}}setWrapNodeByMark(t){const e=document.createElement("p");return e.className="chat-grid-wrap",e.setAttribute("data-set-richType","richBox"),Array.prototype.forEach.call(t,(t=>{e.appendChild(t)})),e}setRangeLastText(){const t=this.richText.childNodes[this.richText.childNodes.length-1],e=t.childNodes[t.childNodes.length-1].children[0].childNodes[0];this.restCursorPos(e,e.textContent===this.VOID_KEY?1:e.textContent.length),this.viewIntoPoint()}viewIntoPoint(){const t=window.getSelection();if(t.rangeCount>0){const e=t.getRangeAt(0).getBoundingClientRect(),i=this.richText.parentElement;i.scrollTop=e.top+i.scrollTop-i.clientHeight/2}}}const r=(t=50)=>new Promise((e=>{setTimeout(e,t)})),o=(t,e,i,s)=>{const n=Object.assign(Object.assign({},{precision:"first",continuous:!1,space:"ignore",lastPrecision:"start",insensitive:!0}),s||{});return n.insensitive&&(t=t.toLowerCase(),i=i.toLowerCase()),"ignore"===n.space&&(i=i.replace(/\s/g,"")),c(t,e,i,n)||[]},c=(t,e,i,s)=>{let n=[];for(let a=0;a<t.length;a++){if("ignore"===s.space&&" "===t[a]){n.push(a);continue}if(t[a]===i[0]){i=i.slice(1),n.push(a);continue}const r=e.split(" ");let o=0;if(r.forEach((t=>{const e=l(t,i);e>o&&(o=e)})),o&&(i=i.slice(o),n.push(a)),!i)break}if(i)return null;if(s.continuous){const t=n;if(n.some(((e,i)=>i>0&&e!==t[i-1]+1)))return null}return"ignore"===s.space&&(n=n.filter((e=>" "!==t[e]))),n.length?n:null},l=(t,e)=>{let i=0;for(let s=0;s<t.length;s++)t[s]===e[i]&&i++;return i};function d(){const t=navigator.userAgent,e=/(?:Windows Phone)/.test(t),i=/(?:SymbianOS)/.test(t)||e,s=/(?:Android)/.test(t),n=/(?:Firefox)/.test(t),a=/(?:iPad|PlayBook)/.test(t)||s&&!/(?:Mobile)/.test(t)||n&&/(?:Tablet)/.test(t),r=/(?:iPhone)/.test(t)&&!a;return{isTablet:a,isPhone:r,isAndroid:s,isPc:!r&&!s&&!i}}const u=function(t,e,i){return t.forEach((t=>{if(i in t){const s=e.indexOf(String(t[i]));-1!==s&&(e[s]=t)}})),e.filter((t=>t[i]))},h=function(t){return Object.prototype.toString.call(t).slice(8,-1)},p=function(t,e){const i=h(t).toLowerCase();switch(h(e)){case"String":return i===e.toLowerCase();case"Array":return e.some((t=>i===t.toLowerCase()));default:return!0}};class m{constructor({elm:t,userList:e,placeholder:i,copyType:s,uploadImage:o,needCallEvery:c,callEveryLabel:l,userProps:u,needCallSpace:h,wrapKeyFun:p,sendKeyFun:m,needDialog:g,maxLength:f}){if(n(this,"richText"),n(this,"needCallEvery",!0),n(this,"callEveryLabel","所有人"),n(this,"maxLength"),n(this,"textLength",0),n(this,"needDialog",!0),n(this,"placeholderElm"),n(this,"userProps",{id:"id",name:"name",avatar:"avatar",pinyin:"pinyin"}),n(this,"chat"),n(this,"targetUserList",[]),n(this,"userList",[]),n(this,"copyType",["text"]),n(this,"itemShowList",[]),n(this,"checkboxRows",[]),n(this,"base64Images",{}),n(this,"uploadImage"),n(this,"deviceInfo",d()),n(this,"isComposition",!1),n(this,"undoHistory",[]),n(this,"redoHistory",[]),n(this,"doOverHistory",!0),n(this,"isExternalCallPopup",!1),n(this,"isIMEModel",!1),n(this,"chatEventModule",{enterSend:[],operate:[],defaultAction:[]}),n(this,"wrapKeyFun",(t=>t.ctrlKey&&["Enter"].includes(t.key))),n(this,"sendKeyFun",(t=>!t.ctrlKey&&["Enter"].includes(t.key))),n(this,"startOpenIndex",0),n(this,"toolUserList"),n(this,"dialogElm"),n(this,"dialogCheckElm"),n(this,"dialogMainElm"),n(this,"checkboxElm"),n(this,"searchResultElm"),n(this,"checkGroupElm"),n(this,"searchElm"),n(this,"tagsElm"),n(this,"dialogActiveItemElm"),n(this,"searchEmptyLabel","没有匹配到任何结果"),n(this,"checkAllLabel","全选"),n(this,"dialogH5Elm"),n(this,"dialogH5MainElm"),n(this,"dialogH5CheckElm"),n(this,"dialogH5ShowElm"),n(this,"dialogH5SearchElm"),n(this,"winClick",(()=>{this.getElmBlock(this.dialogElm)&&this.exitDialog(),this.searchResultElm&&this.domElmShow(this.searchResultElm)})),n(this,"winKeydown",(async t=>{if(t.ctrlKey&&"KeyZ"===t.code&&t.preventDefault(),this.getElmBlock(this.dialogElm)&&0!==this.itemShowList.length&&!this.isComposition){if("ArrowDown"===t.code)return void this.moveActiveItem("down");if("ArrowUp"===t.code)return void this.moveActiveItem("up");if(("Enter"===t.code||"NumpadEnter"===t.code)&&this.dialogActiveItemElm){t.preventDefault();const e=this.dialogActiveItemElm.getAttribute("data-set-id")||"";await r(100),this.toolUserList&&this.toolUserList.length>0?await this.matchSetTag(this.userList.find((t=>t.id===e))):await this.onceSetTag("isALL"===e?{[this.userProps.id]:"isALL",[this.userProps.name]:this.callEveryLabel}:this.userList.find((t=>t.id===e))),this.exitDialog()}}})),!(t instanceof HTMLElement))throw new Error("参数值elm:参数类型错误, 参数类型应为HTMLElement!");["absolute","relative","fixed"].includes(t.style.position)||(t.style.position="relative"),t.className+=" chat-area-"+(this.deviceInfo.isPc?"pc":"h5"),this.richText=document.createElement("div"),this.richText.setAttribute("class","chat-rich-text"),this.richText.setAttribute("data-set-richType","richAllBox"),this.richText.setAttribute("contenteditable","true"),t.appendChild(this.richText),this.placeholderElm=document.createElement("div"),this.placeholderElm.className="chat-placeholder-wrap",this.domElmShow(this.placeholderElm,!0),t.appendChild(this.placeholderElm),this.chat=new a(this.richText),l&&(this.callEveryLabel=l),void 0!==g&&(this.needDialog="false"!==String(g)),this.needDialog&&(this.deviceInfo.isPc?this.hasPc():this.hasH5()),this.registerEvent(),this.updateConfig({userList:e,placeholder:i,maxLength:f,copyType:s,uploadImage:o,needCallEvery:c,needCallSpace:h,userProps:u,wrapKeyFun:p,sendKeyFun:m});const v={html:this.richText.innerHTML,gridIndex:0,markIndex:0,cursorIndex:this.chat.cursorIndex};this.undoHistory=[v]}registerEvent(){this.richText.addEventListener("keyup",(t=>{if(!this.needDialog)return;if(t.stopPropagation(),this.deviceInfo.isPc)return void((50===t.keyCode||"Digit2"===t.code||"@"===t.key)&&this.ruleCanShowPointDialog());const e="Unidentified"===t.key?"android":"ios";let i=!1;switch(e){case"android":i=229===t.keyCode;break;case"ios":i=50===t.keyCode||"Digit2"===t.code||"@"===t.key;break}i&&this.userList.length>0&&this.chat.showAt()&&(this.showH5Dialog(),this.isExternalCallPopup=!1)})),this.richText.addEventListener("keydown",(async t=>{if(!this.deviceInfo.isPc&&"Unidentified"===t.key&&229===t.keyCode)return t.preventDefault(),this.isIMEModel=!0,void this.chat.setIMESelection();this.isIMEModel||(this.getElmBlock(this.dialogElm)?["ArrowUp","ArrowDown","Enter","NumpadEnter"].includes(t.code)?t.preventDefault():["ArrowLeft","ArrowRight"].includes(t.code)&&this.exitDialog():("Backspace"===t.code||"Backspace"===t.key?(this.chat.selectRegionMerge()||this.chat.gridElmMerge()||this.chat.delMarkRule())&&(t.preventDefault(),await this.richTextInput()):this.wrapKeyFun(t)||!this.deviceInfo.isPc&&"Enter"===t.key?(t.preventDefault(),this.chat.setWrap(),await this.richTextInput()):this.sendKeyFun(t)?(t.preventDefault(),await r(100),this.enterSend()):["ArrowLeft","ArrowRight"].includes(t.code)?(t.preventDefault(),this.chat.switchRange(t.code)):t.ctrlKey&&"KeyA"===t.code?this.isEmpty()&&t.preventDefault():t.ctrlKey&&"KeyZ"===t.code?(t.preventDefault(),this.ruleChatEvent(this.undo,"defaultAction","UNDO")):t.ctrlKey&&"KeyY"===t.code&&(t.preventDefault(),this.ruleChatEvent(this.redo,"defaultAction","REDO")),-1===["Backspace","Shift","Tab","CapsLock","Control","Meta","Alt","ContextMenu","Enter","NumpadEnter","Escape","ArrowLeft","ArrowUp","ArrowRight","ArrowDown","Home","End","PageUp","PageDown","Insert","Delete","NumLock"].indexOf(t.key)&&!t.ctrlKey&&!t.altKey&&!t.metaKey&&this.chat.selectRegionMerge()))})),this.richText.addEventListener("input",(async t=>{if(this.isIMEModel)return this.isIMEModel=!1,"deleteContentBackward"===t.inputType?(await r(50),this.chat.delMarkRuleIME()):"insertParagraph"===t.inputType?this.chat.wrapIME():this.chat.resetIME(t.data),this.chat.upDataNodeOrIndex(),this.chat.updateGrid(),void 0!==this.maxLength&&this.ruleMaxLength(),this.showPlaceholder(),void this.triggerChatEvent("operate");if(await this.richTextInput(),this.getElmBlock(this.dialogElm)&&!this.isComposition){const t=this.chat.vnode.textContent,e=this.chat.cursorIndex,i=new RegExp(`^([${this.chat.ZERO_WIDTH_KEY}${this.chat.VOID_KEY}])+$`);if(!t||i.test(t)||e<this.startOpenIndex)return void this.exitDialog();const s=t.slice(this.startOpenIndex,e+1),n=String(s||"");if(/\s{2,}/gi.test(n))return void this.exitDialog();if(!n)return this.resizeUserTool(),void this.showPCDialog();this.toolUserList||(this.toolUserList=this.userList);const a=this.searchUserList(n,this.toolUserList);a.length>0?(this.updateUserList(a,!0),this.showPCDialog()):this.exitDialog()}})),this.richText.addEventListener("copy",(t=>{t.preventDefault(),this.ruleChatEvent((()=>{this.copyRange(t)}),"defaultAction","COPY")})),this.richText.addEventListener("cut",(t=>{t.preventDefault(),this.ruleChatEvent((()=>{this.copyRange(t),this.removeRange()}),"defaultAction","CUT")})),this.richText.addEventListener("paste",(t=>{t.preventDefault(),this.ruleChatEvent((()=>{const e=t.clipboardData.getData("text/plain");if("string"==typeof e&&""!==e){if(-1===this.copyType.indexOf("text"))return;let i=document.createElement("div");i.innerHTML=t.clipboardData.getData("application/my-custom-format")||"",this.chat.selectRegionMerge(),i.children[0]&&"richBox"===i.children[0].getAttribute("data-set-richType")?this.insertInsideHtml(i.innerHTML):(i.innerHTML=e,this.insertText(i.innerText)),i=null}else{if(-1===this.copyType.indexOf("image"))return;const e=(t.clipboardData||t.originalEvent.clipboardData).items||[];Array.prototype.forEach.call(e,(async t=>{if(-1===t.type.indexOf("image"))return;const e=t.getAsFile();if(this.uploadImage){const t=await this.uploadImage(e);this.insertHtml(`<img class="chat-img" src="${t}" alt="" />`)}else{const t=new FileReader;t.onload=t=>{this.insertHtml(`<img class="chat-img" src="${t.target.result}" alt="" />`)},t.readAsDataURL(e)}}))}}),"defaultAction","PASTE")})),this.richText.addEventListener("blur",(t=>{this.chat.upDataNodeOrIndex()})),this.richText.addEventListener("focus",(t=>{this.chat.upDataNodeOrIndex()})),this.richText.addEventListener("click",(()=>{this.chat.upDataNodeOrIndex()})),this.richText.addEventListener("dragstart",(t=>{t.stopPropagation(),t.preventDefault()})),this.richText.addEventListener("dragover",(t=>{t.stopPropagation(),t.preventDefault()})),this.richText.addEventListener("drop",(t=>{t.stopPropagation(),t.preventDefault()})),this.richText.addEventListener("compositionstart",(()=>{this.isComposition=!0})),this.richText.addEventListener("compositionend",(()=>{this.isComposition=!1}))}async richTextInput(t=!0){this.chat.upDataNodeOrIndex(),this.deviceInfo.isPc&&this.chat.selectRegionMerge(),await r(50),this.isComposition||this.chat.updateGrid();const e=(this.richText.children[0]||{childNodes:[]}).childNodes[0];if(!e||!e.getAttribute||"richMark"!==e.getAttribute("data-set-richType"))return this.chat.textInnerHtmlInit(!0),this.showPlaceholder(),void this.triggerChatEvent("operate");if(void 0!==this.maxLength&&this.ruleMaxLength(),this.showPlaceholder(),this.triggerChatEvent("operate"),t&&!this.isComposition){const{gridIndex:t,markIndex:e}=this.chat.getRichTextNodeIndex(this.chat.vnode),i={html:this.richText.innerHTML,gridIndex:t,markIndex:e,cursorIndex:this.chat.cursorIndex};this.undoHistory.push(i),this.undoHistory.length>50&&this.undoHistory.shift()}}copyRange(t){const e=window.getSelection();if(e.isCollapsed||e.rangeCount<=0)return t.clipboardData.setData("application/my-custom-format",""),void t.clipboardData.setData("text/plain","");const i=e.toString()||"";let s=document.createElement("div");s.innerHTML=i;const n=s.innerText.replace(/\n\n/g,"\n");s=null,t.clipboardData.setData("text/plain",n);const a=e.anchorNode,r=e.focusNode;if(a===r&&a.nodeType===Node.TEXT_NODE){const i=a.textContent.slice(e.anchorOffset,e.focusOffset);return void t.clipboardData.setData("application/my-custom-format",i)}if(a===this.richText&&r===this.richText)return void t.clipboardData.setData("application/my-custom-format",this.richText.innerHTML);const o=this.chat.getWrapNode(a),c=this.chat.getWrapNode(r),l=this.chat.getMarkNode(a),d=this.chat.getMarkNode(r),u=Array.prototype.indexOf.call(o.childNodes,l),h=Array.prototype.indexOf.call(c.childNodes,d);if(o===c&&o.parentNode===this.richText){const i=u>h,s=Array.prototype.filter.call(o.childNodes,((t,e)=>i?e<u&&e>h:e>u&&e<h)).map((t=>t.cloneNode(!0))),n=i?a.textContent.slice(0,e.anchorOffset):a.textContent.slice(e.anchorOffset),c=i?r.textContent.slice(e.focusOffset):r.textContent.slice(0,e.focusOffset),l=this.chat.getGridElm(!0),d=this.chat.getGridElm(!0);n&&(l.childNodes[0].innerHTML=n,l.childNodes[0].setAttribute("data-set-empty","false")),c&&(d.childNodes[0].innerHTML=c,d.childNodes[0].setAttribute("data-set-empty","false")),i?(s.unshift(d),s.push(l)):(s.unshift(l),s.push(d));let p=document.createElement("div");const m=this.chat.setWrapNodeByMark(s);return p.appendChild(m),t.clipboardData.setData("application/my-custom-format",p.innerHTML),void(p=null)}if(o.parentNode===this.richText&&c.parentNode===this.richText){const i=Array.prototype.indexOf.call(this.richText.childNodes,o),s=Array.prototype.indexOf.call(this.richText.childNodes,c),n=i>s,l=Array.prototype.filter.call(this.richText.childNodes,((t,e)=>n?e<i&&e>s:e>i&&e<s)).map((t=>t.cloneNode(!0))),d=n?a.textContent.slice(0,e.anchorOffset):a.textContent.slice(e.anchorOffset),p=n?r.textContent.slice(e.focusOffset):r.textContent.slice(0,e.focusOffset),m=this.chat.getGridElm(!0),g=this.chat.getGridElm(!0);d&&(m.childNodes[0].innerHTML=d,m.childNodes[0].setAttribute("data-set-empty","false")),p&&(g.childNodes[0].innerHTML=p,g.childNodes[0].setAttribute("data-set-empty","false"));const f=Array.prototype.filter.call(o.childNodes,((t,e)=>n?e<u:e>u)).map((t=>t.cloneNode(!0))),v=Array.prototype.filter.call(c.childNodes,((t,e)=>n?e>h:e<h)).map((t=>t.cloneNode(!0)));if(n){f.push(m),v.unshift(g);const t=this.chat.setWrapNodeByMark(f),e=this.chat.setWrapNodeByMark(v);l.push(t),l.unshift(e)}else{f.unshift(m),v.push(g);const t=this.chat.setWrapNodeByMark(f),e=this.chat.setWrapNodeByMark(v);l.unshift(t),l.push(e)}let b=document.createElement("div");return Array.prototype.forEach.call(l,(t=>{b.appendChild(t)})),t.clipboardData.setData("application/my-custom-format",b.innerHTML),void(b=null)}}async removeRange(){window.getSelection().getRangeAt(0).deleteContents(),await r(50),this.chat.updateGrid(),this.showPlaceholder()}updateUserList(t,e){t&&(this.userList=this.getRuleUserList(t)),e||(this.base64Images={}),this.needDialog&&(this.deviceInfo.isPc?this.updatePCUser():this.updateH5User())}getRuleUserList(t){if(!p(t,"Array"))throw new Error("参数值userList:类型值应为Array!");this.targetUserList=JSON.parse(JSON.stringify(t||[]));const e=Object.create(null);return e[this.userProps.id]="isALL",e[this.userProps.name]=this.callEveryLabel,this.targetUserList.unshift(e),(null==t?void 0:t.map(((t,e)=>{const i=t[this.userProps.id];if(!i&&0!==i)throw new Error(`参数值userList:下标第${e}${this.userProps.id}值异常!`);return t.name=String(t[this.userProps.name]||""),t.pinyin=String(t[this.userProps.pinyin]||""),t.id=String(i),t.avatar=String(t[this.userProps.avatar]||""),t})))||[]}getElmBlock(t){return t&&"block"===t.style.display}domElmShow(t,e=!1){t&&(t.className=t.className.replace(/ chat-view-show| chat-view-hidden/g,""),e?(t.style.display="block",t.className+=" chat-view-show"):t.style.display="none")}getUserHtmlTemplate(t,e){const i=document.createElement("span");if(i.setAttribute("class","call-user-dialog-item-sculpture "+(e.avatar?"is-avatar":"")),e.avatar){const t=new Image;t.alt="";const s=this.base64Images[e.id];s?t.src=s:(t.src=String(e.avatar),t.setAttribute("crossOrigin","Anonymous"),t.onload=()=>{const i=document.createElement("canvas");i.width=48,i.height=48;const s=i.getContext("2d");s&&(s.drawImage(t,0,0,i.width,i.height),this.base64Images[e.id]=i.toDataURL("image/png",1))}),i.appendChild(t)}else i.innerHTML=`<span style="transform: scale(0.75)">${e.name.slice(-2)}</span>`;t.appendChild(i);const s=document.createElement("span");s.setAttribute("class","call-user-dialog-item-name"),s.innerHTML=e.name,t.appendChild(s)}hasPc(){this.initCheckbox(),this.initCallUser(),window.addEventListener("click",this.winClick),window.addEventListener("keydown",this.winKeydown)}initCheckbox(){this.checkboxElm=document.createElement("div"),this.checkboxElm.setAttribute("class","checkbox-dialog"),this.domElmShow(this.checkboxElm),this.checkboxElm.innerHTML='\n <div class="checkbox-dialog-container">\n <div class="checkbox-dialog-container-header">\n <span>选择要@的人</span>\n <span class="checkbox-dialog-container-header-close">⛌</span>\n </div>\n <div class="checkbox-dialog-container-body">\n <div class="checkbox-dialog-left-box">\n <div class="checkbox-dialog-search">\n <input class="checkbox-dialog-search-input" placeholder="搜索人员名称" type="text">\n\n <div data-set-remark="搜索下拉" class="checkbox-dialog-search-group"></div>\n </div>\n\n <div data-set-remark="反显选取的人员" class="checkbox-dialog-tags"></div>\n\n <div class="checkbox-dialog-option">\n <button class="checkbox-dialog-option-btn btn-submit">确定</button>\n <button class="checkbox-dialog-option-btn btn-close">取消</button>\n </div>\n </div>\n \n <div class="checkbox-dialog-right-box">\n <div class="checkbox-dialog-right-box-title">研讨成员列表</div>\n\n <div data-set-remark="多选人员列表" class="checkbox-dialog-check-group"></div>\n </div>\n </div>\n </div>\n ',document.body.appendChild(this.checkboxElm),this.checkGroupElm=this.checkboxElm.querySelector(".checkbox-dialog-check-group"),this.searchResultElm=this.checkboxElm.querySelector(".checkbox-dialog-search-group"),this.searchElm=this.checkboxElm.querySelector(".checkbox-dialog-search-input"),this.tagsElm=this.checkboxElm.querySelector(".checkbox-dialog-tags");const t=()=>{this.domElmShow(this.checkboxElm),this.isExternalCallPopup=!1},e=this.checkboxElm.querySelector(".checkbox-dialog-container-header-close"),i=this.checkboxElm.querySelector(".btn-close");e.onclick=t,i.onclick=t;const s=this.checkboxElm.querySelector(".btn-submit");s.onclick=async()=>{await this.batchSetTag(this.checkboxRows),t(),this.chat.viewIntoPoint()},this.domElmShow(this.searchResultElm),this.searchResultElm.onclick=t=>{t.stopPropagation()},this.searchElm.onclick=t=>{t.stopPropagation()},this.searchElm.oninput=t=>{this.searchResultElm.innerHTML="";const e=String(t.target.value||"").replace(/'/g,"");if(!e)return void this.domElmShow(this.searchResultElm);const i=this.searchUserList(e),s=document.createDocumentFragment();if(i.forEach((t=>{const e=document.createElement("div");e.setAttribute("class","checkbox-dialog-check-item"),e.setAttribute("data-set-value",t.id);const i=document.createElement("div");i.setAttribute("class","checkbox-dialog-check-item-label"),this.getUserHtmlTemplate(i,t),e.appendChild(i),e.onclick=()=>{this.domElmShow(this.searchResultElm);const t=e.getAttribute("data-set-value")||"";if(this.searchElm.value="",this.checkboxRows.some((e=>e.id===t)))return;const i=this.userList.find((e=>e.id===t));i&&this.checkboxRows.push(i),Array.prototype.some.call(this.checkGroupElm.children,((e,i)=>0===i&&this.checkboxRows.length===this.userList.length?(e.className+=" checkbox-dialog-check-item-check",!1):e.getAttribute("data-set-value")===t?(e.className+=" checkbox-dialog-check-item-check",!0):void 0)),this.updateTags()},s.appendChild(e)})),!i.length){const t=document.createElement("div");t.setAttribute("class","checkbox-dialog-search-empty"),t.innerText=this.searchEmptyLabel,s.appendChild(t)}this.searchResultElm.appendChild(s),this.domElmShow(this.searchResultElm,!0)}}searchUserList(t,e){return(e||this.userList).filter((e=>o(e.name,e.pinyin||"",t).length>0))}updateTags(){const t=this.checkboxRows.map((t=>t.id)),e=[],i=[];Array.prototype.forEach.call(this.tagsElm.children,(s=>{const n=s.getAttribute("data-set-value");-1===t.indexOf(n)?i.push(s):e.push(n)})),i.forEach((t=>{this.tagsElm.removeChild(t)}));const s=this.checkboxRows.filter((t=>-1===e.indexOf(t.id)));if(!s.length)return;const n=document.createDocumentFragment();s.forEach((t=>{const e=document.createElement("div");e.setAttribute("class","checkbox-dialog-tag-item"),e.setAttribute("data-set-value",t.id),e.innerHTML=`\n <span>${t.name}</span>\n `;const i=document.createElement("span");i.setAttribute("class","checkbox-dialog-tag-item-close"),i.innerHTML="⛌",i.onclick=()=>{const t=e.getAttribute("data-set-value");this.checkboxRows=this.checkboxRows.filter((e=>e.id!==t)),this.tagsElm.removeChild(e),Array.prototype.some.call(this.checkGroupElm.children,((e,i)=>0===i?(e.className=e.className.replace(/ checkbox-dialog-check-item-check/g,""),!1):e.getAttribute("data-set-value")===t?(e.className=e.className.replace(/ checkbox-dialog-check-item-check/g,""),!0):void 0))},e.appendChild(i),n.appendChild(e)})),this.tagsElm.appendChild(n)}initCallUser(){this.dialogElm=document.createElement("div"),this.dialogElm.setAttribute("class","call-user-dialog"),this.domElmShow(this.dialogElm);const t=document.createElement("div");t.setAttribute("class","call-user-dialog-header"),t.innerHTML='\n <span class="call-user-dialog-header-title">群成员</span>\n ',this.dialogCheckElm=document.createElement("span"),this.dialogCheckElm.setAttribute("class","call-user-dialog-header-check"),this.domElmShow(this.dialogCheckElm,this.userList.length>0),this.dialogCheckElm.innerText="多选",this.dialogCheckElm.onclick=()=>{this.showPCCheckDialog(),this.isExternalCallPopup=!1},t.appendChild(this.dialogCheckElm),this.dialogElm.appendChild(t),this.dialogMainElm=document.createElement("div"),this.dialogMainElm.setAttribute("class","call-user-dialog-main"),this.dialogElm.appendChild(this.dialogMainElm),this.updateUserList();const e=document.createElement("div");e.setAttribute("class","call-user-dialog-footer"),this.dialogElm.appendChild(e),document.body.appendChild(this.dialogElm)}resizeUserTool(){this.toolUserList&&(this.userList=this.toolUserList),this.toolUserList=void 0,this.updateUserList(this.userList,!0)}updatePCUser(){this.dialogMainElm.innerHTML="",this.dialogActiveItemElm=void 0;const t=this.userList&&this.userList.length>0,e=document.createDocumentFragment();if(this.domElmShow(this.dialogCheckElm),!this.toolUserList&&t&&(this.domElmShow(this.dialogCheckElm,!0),this.needCallEvery)){const t=document.createElement("div");t.setAttribute("class","call-user-dialog-item"),t.setAttribute("data-set-id","isALL"),this.userSelectStyleAndEvent(t,{[this.userProps.id]:"isALL",[this.userProps.name]:this.callEveryLabel}),t.innerHTML=`\n <span class="call-user-dialog-item-sculpture">\n <span style="transform: scale(0.75)">@</span>\n </span>\n <span class="call-user-dialog-item-name">${this.callEveryLabel}(${this.userList.length})</span>\n `,e.appendChild(t)}this.userList.forEach((t=>{const i=document.createElement("div");i.setAttribute("class","call-user-dialog-item"),i.setAttribute("data-set-id",t.id),this.userSelectStyleAndEvent(i,t),this.getUserHtmlTemplate(i,t),e.appendChild(i)})),this.dialogMainElm.appendChild(e),this.callUserDialogMap(),this.checkGroupElm.innerHTML=`\n <div class="checkbox-dialog-check-item" data-set-value="ALL">\n <input type="checkbox" value>\n <span class="checkbox-dialog-check-item-inner"></span>\n <div class="checkbox-dialog-check-item-label">${this.checkAllLabel}</div>\n </div>`;const i=document.createDocumentFragment();this.userList.forEach((t=>{const e=document.createElement("div");e.setAttribute("class","checkbox-dialog-check-item"),e.setAttribute("data-set-value",t.id),e.innerHTML='\n <input type="checkbox" value>\n <span class="checkbox-dialog-check-item-inner"></span>\n ',this.getUserHtmlTemplate(e,t),i.appendChild(e)})),this.checkGroupElm.appendChild(i),this.checkGroupElm&&this.checkGroupElm.children.length&&Array.prototype.forEach.call(this.checkGroupElm.children,(t=>{t.onclick=()=>{const e=t.getAttribute("data-set-value")||"",i=this.userList.find((t=>t.id===e));-1!==t.className.indexOf("checkbox-dialog-check-item-check")?(t.className=t.className.replace(/ checkbox-dialog-check-item-check/g,""),"ALL"!==e&&(this.checkboxRows=this.checkboxRows.filter((t=>t.id!==e)))):(t.className+=" checkbox-dialog-check-item-check","ALL"!==e&&i&&this.checkboxRows.push(i)),"ALL"===e?(Array.prototype.forEach.call(this.checkGroupElm.children,(e=>{e.className=t.className})),this.checkboxRows=-1!==t.className.indexOf("checkbox-dialog-check-item-check")?this.userList.map((t=>t)):[]):this.checkboxRows.length===this.userList.length?this.checkGroupElm.children[0].className+=" checkbox-dialog-check-item-check":this.checkGroupElm.children[0].className=this.checkGroupElm.children[0].className.replace(/ checkbox-dialog-check-item-check/g,""),this.updateTags()}}))}userSelectStyleAndEvent(t,e){t.addEventListener("click",(async i=>{i.stopPropagation(),this.upDateActiveItem(t),this.toolUserList&&this.toolUserList.length>0?await this.matchSetTag(e):await this.onceSetTag(e),this.exitDialog()}))}callUserDialogMap(){this.itemShowList=[],Array.prototype.forEach.call(this.dialogMainElm.children||[],((t,e)=>{this.itemShowList.push({index:e,elm:t})}))}ruleCanShowPointDialog(){this.userList.length>0&&this.chat.showAt()&&(this.startOpenIndex=this.chat.cursorIndex,this.showPCDialog())}showPCDialog(){this.domElmShow(this.dialogElm,!0);let t="0",e="100%";this.upDateActiveItem(this.dialogMainElm.firstElementChild,!0);const i=this.chat.getRangeRect(),{clientWidth:s,clientHeight:n}=this.dialogElm;i.x>window.innerWidth-s&&(i.x=i.x-s-16,t="100%"),i.y<n&&(i.y=n+i.y,e="0"),this.dialogElm.style.transformOrigin=`${t} ${e}`,this.dialogElm.style.left=i.x+6+"px",this.dialogElm.style.bottom=`calc(100% - ${i.y}px)`,this.dialogElm.style.opacity="1"}showPCCheckDialog(){this.winClick(),this.checkboxRows=[],this.domElmShow(this.checkboxElm,!0),this.tagsElm.scrollTop=0,this.checkGroupElm.scrollTop=0,this.searchElm.value="",Array.prototype.forEach.call(this.checkGroupElm.children,(t=>{t.className="checkbox-dialog-check-item"})),this.updateTags(),this.isExternalCallPopup=!0}async showPCPointDialog(){this.insertText("@"),this.startOpenIndex=this.chat.cursorIndex,window.removeEventListener("click",this.winClick),this.showPCDialog(),await r(50),window.addEventListener("click",this.winClick)}moveActiveItem(t){if(!this.dialogActiveItemElm||0===this.itemShowList.length)return;let e=0;const i=this.dialogActiveItemElm.getAttribute("data-set-id");this.itemShowList.some((t=>{const s=t.elm.getAttribute("data-set-id");return e=t.index,i===s}));const s=this.itemShowList.map((t=>t.index));if("down"===t&&e!==this.itemShowList[this.itemShowList.length-1].index){const t=this.itemShowList[s.indexOf(e)+1];t&&this.upDateActiveItem(t.elm,!0)}else if("up"===t&&e!==this.itemShowList[0].index){const t=this.itemShowList[s.indexOf(e)-1];t&&this.upDateActiveItem(t.elm,!0)}}upDateActiveItem(t,e=!1){this.dialogActiveItemElm&&(this.dialogActiveItemElm.className=this.dialogActiveItemElm.className.replace(/ call-user-dialog-item-active/g,"")),this.dialogActiveItemElm=t,t&&(t.className+=" call-user-dialog-item-active",e&&t.scrollIntoView({block:"center"}))}exitDialog(){this.toolUserList&&this.resizeUserTool(),this.upDateActiveItem(),this.domElmShow(this.dialogElm)}hasH5(){this.dialogH5Elm=document.createElement("div"),this.dialogH5Elm.setAttribute("class","call-user-popup"),this.dialogH5Elm.innerHTML='\n <div class="call-user-popup-main">\n <div class="call-user-popup-header">\n <span class="popup-show">收起</span>\n <span class="popup-title">选择提醒的人</span>\n <span class="popup-check">确定</span>\n </div>\n \n <div class="call-user-popup-search">\n <svg class="icon-search"\n style="vertical-align: middle;fill: currentColor;overflow: hidden;"\n viewBox="0 0 1024 1024" version="1.1"\n xmlns="http://www.w3.org/2000/svg"\n p-id="4209">\n <path d="M684.8 223.530667a326.272 326.272 0 0 1 24.96 433.621333c2.645333 2.133333 5.290667 4.48 7.850667 7.04L870.4 817.066667c24.789333 24.746667 32.896 56.832 18.133333 71.594666-14.762667 14.805333-46.848 6.656-71.637333-18.090666l-152.789333-152.832a106.282667 106.282667 0 0 1-7.210667-7.936 326.101333 326.101333 0 0 1-433.109333-25.173334c-127.445333-127.445333-127.573333-333.952-0.256-461.269333 127.36-127.36 333.866667-127.232 461.269333 0.213333zM275.328 275.114667a252.885333 252.885333 0 0 0 0.256 357.632 252.885333 252.885333 0 0 0 357.632 0.256 252.885333 252.885333 0 0 0-0.256-357.632 252.885333 252.885333 0 0 0-357.632-0.256z"\n fill="#9B9B9B"\n p-id="4210"></path>\n </svg>\n <input class="call-user-popup-search-input"\n placeholder="搜索人员名称"\n type="text">\n </div>\n \n <div class="call-user-popup-body">\n </div>\n </div>\n ';const t=async()=>{this.dialogH5Elm.className=this.dialogH5Elm.className.replace(/ chat-view-show/g," chat-view-hidden"),this.dialogH5SearchElm.value="",await r(260),this.domElmShow(this.dialogH5Elm),this.chat.restCursorPos(this.chat.vnode,this.chat.cursorIndex),this.isExternalCallPopup=!1,this.chat.viewIntoPoint()};this.dialogH5Elm.onclick=t,this.dialogH5Elm.querySelector(".call-user-popup-main").onclick=t=>{t.stopPropagation()},this.dialogH5ShowElm=this.dialogH5Elm.querySelector(".popup-show"),this.dialogH5ShowElm.onclick=t,this.dialogH5CheckElm=this.dialogH5Elm.querySelector(".popup-check"),this.dialogH5CheckElm.onclick=async()=>{const e=this.dialogH5Elm.querySelectorAll(".user-popup-check-item-check")||[];if(0===e.length)return void await t();if(Array.prototype.some.call(e,(t=>"isALL"===t.getAttribute("data-set-id"))))return await this.onceSetTag({[this.userProps.id]:"isALL",[this.userProps.name]:this.callEveryLabel}),void await t();const i=Array.prototype.map.call(e,(t=>t.getAttribute("data-set-id"))),s=this.userList.filter((t=>i.includes(t.id)));await this.batchSetTag(s),await t()},this.dialogH5MainElm=this.dialogH5Elm.querySelector(".call-user-popup-body"),this.updateUserList(),this.dialogH5SearchElm=this.dialogH5Elm.querySelector(".call-user-popup-search-input"),this.dialogH5SearchElm.oninput=t=>{const e=String(t.target.value||"").replace(/'/g,"");Array.prototype.forEach.call(this.dialogH5MainElm.children,(t=>{if(!e)return void(t.style.display="");const i=t.getAttribute("data-set-name")||"",s=t.getAttribute("data-set-pinyin")||"";t.style.display=o(i,s,e).length>0?"":"none"}))},this.domElmShow(this.dialogH5Elm),document.body.appendChild(this.dialogH5Elm)}updateH5User(){this.dialogH5MainElm.innerHTML="",this.domElmShow(this.dialogH5CheckElm,this.userList.length>0);const t=this.userList&&this.userList.length>0,e=document.createDocumentFragment(),i=document.createElement("span");if(i.innerHTML='\n <input type="checkbox" value>\n <span class="user-popup-check-item-inner"></span>\n ',t){const t=document.createElement("div");this.needCallEvery&&(t.setAttribute("class","call-user-popup-item"),t.setAttribute("data-set-id","isALL"),t.innerHTML=`\n <span class="call-user-dialog-item-sculpture">\n <span style="transform: scale(0.75)">@</span>\n </span>\n <span class="call-user-dialog-item-name">${this.callEveryLabel}(${this.userList.length})</span>\n `,t.appendChild(i.cloneNode(!0)),t.onclick=()=>{const e=-1===t.className.indexOf("user-popup-check-item-check");Array.prototype.forEach.call(this.dialogH5MainElm.children,(t=>{e?t.className+=" user-popup-check-item-check":t.className=t.className.replace(/ user-popup-check-item-check/g,"")}))},e.appendChild(t)),this.userList.forEach(((s,n)=>{const a=document.createElement("div");a.setAttribute("class","call-user-popup-item"),a.setAttribute("data-set-id",s.id),a.setAttribute("data-set-name",s.name),a.setAttribute("data-set-pinyin",s.pinyin||""),this.getUserHtmlTemplate(a,s),a.appendChild(i.cloneNode(!0)),e.appendChild(a),a.onclick=e=>{-1===a.className.indexOf("user-popup-check-item-check")?(a.className+=" user-popup-check-item-check",t.className+=Array.prototype.every.call(this.dialogH5MainElm.children,(t=>-1!==t.className.indexOf("user-popup-check-item-check")||"isALL"===t.getAttribute("data-set-id")))?" user-popup-check-item-check":""):(a.className=a.className.replace(/ user-popup-check-item-check/g,""),t.className=t.className.replace(/ user-popup-check-item-check/g,""))}}))}this.dialogH5MainElm.appendChild(e)}showH5Dialog(){this.richText&&this.richText.blur(),Array.prototype.forEach.call(this.dialogH5MainElm.children,(t=>{t.style.display="",t.className=t.className.replace(/ user-popup-check-item-check/g,"")})),this.domElmShow(this.dialogH5Elm,!0),this.dialogH5MainElm.scrollTop=0,this.isExternalCallPopup=!0}updateConfig({copyType:t,userProps:e,userList:i,uploadImage:s,needCallEvery:n,placeholder:a,maxLength:r,needCallSpace:o,wrapKeyFun:c,sendKeyFun:l}={}){if(t){if(!p(t,"Array"))throw new Error("参数值copyType:类型值应为Array!");this.copyType=t.map((t=>{if(-1===["text","image"].indexOf(t))throw new Error(`参数值copyType:无效的参数值"${t}"!`);return t}))}if(e){if(!p(e,"Object"))throw new Error("参数值copyType:类型值应为Object!");this.userProps=Object.assign({},{id:"id",name:"name",avatar:"avatar",pinyin:"pinyin"},e)}if(s){if("function"!=typeof s)throw new Error("参数值uploadImage:参数类型错误,参数类型应为Function!");this.uploadImage=s}if(a&&(this.placeholderElm.innerText=a),void 0!==r){if(!p(r,"Number"))throw new Error("参数值maxLength:类型值应为Number!");this.maxLength=r,this.ruleMaxLength()}if((void 0!==n||i)&&(this.needCallEvery="false"!==String(n),this.updateUserList(i)),void 0!==o&&this.chat.setCallSpace(o),c){if("function"!=typeof c)throw new Error("参数值wrapKeyFun:参数类型错误,参数类型应为Function!");this.wrapKeyFun=c}if(l){if("function"!=typeof l)throw new Error("参数值sendKeyFun:参数类型错误,参数类型应为Function!");this.sendKeyFun=l}}enterSend(){this.triggerChatEvent("enterSend")}insertHtml(t){const e=document.createElement("span");e.innerHTML=t,e.className="chat-set-html";const i=this.chat.createNewDom(e);return this.chat.replaceRegContent(i),this.chat.viewIntoPoint(),this.richTextInput(),i}insertInsideHtml(t){let e=document.createElement("div");if(e.innerHTML=t,!e.children.length)return;const i=this.chat.vnode,s=this.chat.getWrapNode(i);if(1===e.children.length)this.chat.gridMerge(s,e.children[0],!0);else{this.chat.gridMerge(s,e.children[0],!0);const t=Array.prototype.slice.call(e.children,1);let i=s;Array.prototype.forEach.call(t,((e,s)=>{if(i.parentElement?this.richText.insertBefore(e,i.nextElementSibling):this.richText.appendChild(e),i=e,s===t.length-1){const t=e.childNodes[e.childNodes.length-1].childNodes[0].childNodes[0];this.chat.restCursorPos(t,t.textContent.length)}}))}e=null,this.chat.viewIntoPoint(),this.richTextInput()}insertText(t){var e,i;if(!t)return;const s=new RegExp(`${this.chat.ZERO_WIDTH_KEY}${this.chat.VOID_KEY}`,"ig"),n=t.replace(s,"");if(!n)return;let a,r=0;const o=this.chat.vnode;o&&o.parentElement&&"richInput"===o.parentElement.getAttribute("data-set-richType")?(a=o.parentElement,r=o.textContent===this.chat.VOID_KEY?1:this.chat.cursorLeft):(a=null==(i=null==(e=this.richText)?void 0:e.lastChild)?void 0:i.lastChild,r=a.childNodes[0].textContent.length);const c=(t,e=!1)=>{const i=a.childNodes[0],s=i.textContent.split("");return s.splice(r,0,t),i.textContent=s.join("").replace(new RegExp(this.chat.VOID_KEY,"g"),(()=>(r--,""))),a.setAttribute("data-set-empty","false"),a.childNodes[1]&&a.removeChild(a.childNodes[1]),this.chat.restCursorPos(i,r+t.length),e&&this.chat.viewIntoPoint(),a.parentElement.parentElement},l=(t,e=!1,i)=>{const s=this.chat.getGridElm(),n=s.childNodes[0].childNodes[0];let a=1;return t&&(n.innerHTML=t,n.setAttribute("data-set-empty","false"),a=t.length),i.nextSibling?this.richText.insertBefore(s,i.nextSibling):this.richText.appendChild(s),e&&(this.chat.restCursorPos(n.childNodes[0],a),this.chat.viewIntoPoint()),s},d=n.split("\n");if(d.length>1){let t;d.forEach(((e,i)=>{t=0===i?c(e):l(e,i===d.length-1,t)}))}else c(n,!0);this.richTextInput()}getCallUserList(){const t=this.richText.querySelectorAll(".at-user");if(t&&t.length>0){const e=Array.prototype.map.call(t,(t=>t.dataset.userId));return u(this.targetUserList,e,this.userProps.id)}return[]}getCallUserTagList(){const t=this.richText.querySelectorAll(".at-user");return t&&t.length>0?Array.prototype.map.call(t,(t=>({[this.userProps.id]:t.dataset.userId,[this.userProps.name]:t.innerText.slice(1)}))):[]}clear(t){this.chat.textInnerHtmlInit(!0,t);const e={html:this.richText.innerHTML,gridIndex:0,markIndex:0,cursorIndex:this.chat.cursorIndex};this.undoHistory=[e],this.redoHistory=[],this.richTextInput(!1)}isEmpty(t=!1){if((this.richText.querySelectorAll(".chat-tag")||[]).length>0)return!1;const e=new RegExp(`^(${this.chat.ZERO_WIDTH_KEY}|<br>|${this.chat.VOID_KEY})+$`),i=this.richText.querySelectorAll(".chat-grid-input")||[];return t?Array.prototype.every.call(i,(t=>!t.innerHTML||!t.innerText||!t.innerText.trim()||e.test(t.innerHTML))):Array.prototype.every.call(i,(t=>!t.innerHTML||!t.innerText||e.test(t.innerHTML)))}showPlaceholder(){this.domElmShow(this.placeholderElm,this.isEmpty())}getReduceNode(t={}){const e=Object.assign({},{needUserId:!1,wrapClassName:void 0,rowClassName:void 0,imgToText:!1,identifyLink:!1},t),i=/(https?|http|ftp|file):\/\/[-A-Za-z0-9+&@#/%?=~_|!:,.;]+[-A-Za-z0-9+&@#/%=~_|]/g,s=this.richText.cloneNode(!0).querySelectorAll(".chat-grid-wrap")||[],n=document.createElement("div");return e.wrapClassName&&(n.className=e.wrapClassName),Array.prototype.forEach.call(s,((t,s)=>{const a=t.querySelectorAll(".chat-stat")||[],r=document.createElement("p");e.rowClassName&&(r.className=e.rowClassName),Array.prototype.forEach.call(a,(t=>{this.chat.getNodeEmpty(t)||(t.removeAttribute("data-set-richType"),t.removeAttribute("contenteditable"),t.removeAttribute("data-set-empty"),e.needUserId||t.removeAttribute("data-user-id"),e.imgToText&&t.firstChild&&"IMG"===t.firstChild.tagName&&(t.className+=" img-to-text",t.innerHTML=`[${t.firstChild.getAttribute("data-img-text")||"元素data-img-text未定义"}]`),e.identifyLink&&-1!==t.className.indexOf("chat-grid-input")&&(t.innerHTML=t.innerHTML.replace(i,(t=>`<a class="chat-grid-link" href="${t}" target="_blank">${t}</a>`))),r.appendChild(t))})),r.innerHTML||(r.innerHTML="<br>"),n.appendChild(r)})),n}getText(t={}){let e="";const i=this.getReduceNode(t);return Array.prototype.forEach.call(i.children,((t,i)=>{e=e+(i>0?"\n":"")+t.textContent})),e}getHtml(t={}){return this.getReduceNode(t).innerHTML}dispose(){const t=this.richText.parentElement;t&&(t.removeChild(this.richText),t.removeChild(this.placeholderElm)),this.needDialog&&(this.deviceInfo.isPc?(document.body.removeChild(this.dialogElm),document.body.removeChild(this.checkboxElm),window.removeEventListener("click",this.winClick),window.removeEventListener("keydown",this.winKeydown)):document.body.removeChild(this.dialogH5Elm));for(const e in this)delete this[e];Object.setPrototypeOf(this,Object)}setUserTag(t){const e=this.chat.createAtUserSpan({id:t[this.userProps.id],name:t[this.userProps.name]});this.chat.replaceRegContent(e,!1),this.chat.viewIntoPoint(),this.richTextInput()}async matchSetTag(t){await this.chat.searchCall(t,this.startOpenIndex),await this.richTextInput()}async onceSetTag(t){await this.chat.onceCall({id:t[this.userProps.id],name:t[this.userProps.name]}),await this.richTextInput()}async batchSetTag(t){if(1===t.length)return void(this.isExternalCallPopup?await this.chat.onceExternalCall(t[0]):await this.onceSetTag(t[0]));let e="";for(let i=0;i<=t.length-1;){const s={id:t[i][this.userProps.id],name:t[i][this.userProps.name]};0===i?e=this.isExternalCallPopup?await this.chat.onceExternalCall(s):await this.chat.onceCall(s,!0):i===t.length-1?await this.chat.onceCall(s,!1,e):await this.chat.onceCall(s,!0),i++}await this.richTextInput()}disabled(){this.richText.setAttribute("contenteditable","false"),this.richText.className=this.richText.className.replace(/ chat-rich-text-disabled/g,"")+" chat-rich-text-disabled"}enable(){this.richText.setAttribute("contenteditable","true"),this.richText.className=this.richText.className.replace(/ chat-rich-text-disabled/g,""),this.chat.setRangeLastText()}undo(){if(!this.doOverHistory||!this.undoHistory||this.undoHistory.length<=1)return;const t=this.undoHistory[this.undoHistory.length-2],e=this.undoHistory[this.undoHistory.length-1];this.redoHistory.push(e),this.undoHistory.pop(),this.setChatHistory(t,!1)}redo(){if(!this.doOverHistory||!this.redoHistory||this.redoHistory.length<1)return;const t=this.redoHistory[this.redoHistory.length-1];this.redoHistory.pop(),this.setChatHistory(t,!0)}ruleMaxLength(){if(this.isEmpty()||void 0===this.maxLength)return void(this.textLength=0);let t=0,e=0;const i=[];Array.prototype.some.call(this.richText.children,((s,n)=>{const{nodeInfos:a,nodeTextLength:r}=this.getGirdNodeTextInfo(s);if(t+=r,i.push(a),e=n,t>=this.maxLength)return!0}));const s=[];Array.prototype.forEach.call(this.richText.children,((t,i)=>{i>e&&s.push(t)})),s.forEach((t=>this.richText.removeChild(t))),this.deepDelGirdText(i,t)}getGirdNodeTextInfo(t){const e=[];let i=0;if(1===t.children.length&&t!==t.parentElement.children[0]){const s=t.children[0],n=(s.textContent||"").replace(new RegExp(this.chat.VOID_KEY,"g"),"");i+=n.length||1,e[0]={node:s,textLength:n.length||1,type:"richMark"}}else Array.prototype.forEach.call(t.children,((t,s)=>{if("richMark"===t.getAttribute("data-set-richType")){const n=(t.textContent||"").replace(new RegExp(this.chat.VOID_KEY,"g"),"");i+=n.length,e[s]={node:t,textLength:n.length,type:"richMark"}}else{const n=(t.textContent||"").replace(new RegExp(this.chat.VOID_KEY,"g"),"");i+=n.length||1,e[s]={node:t,textLength:n.length||1,type:"chatTag"}}}));return{nodeInfos:e,nodeTextLength:i}}deepDelGirdText(t,e){if(e>this.maxLength){const i=t[t.length-1];t.pop(),this.deepDelNode(i,t,e)}else this.textLength=e}deepDelNode(t,e,i){const s=t[0].node.parentElement;if(i>this.maxLength){let n=i-this.maxLength,a=t[t.length-1];if("richMark"===a.type)if(0===a.textLength||n>=a.textLength)s.removeChild(a.node),t.pop(),n-=a.textLength,a=t[t.length-1],s.removeChild(a.node),t.pop(),n-=a.textLength;else{const t=a.node.childNodes[0];t.textContent=t.textContent.slice(0,a.textLength-n),0===t.textContent&&(t.setAttribute("data-set-empty","true"),t.innerHTML=this.chat.VOID_KEY+"<br>"),n=0}else s.removeChild(a.node),t.pop(),n-=a.textLength;n>0?t.length>0?this.deepDelNode(t,e,n+this.maxLength):(this.richText.appendChild(s),this.deepDelGirdText(e,n+this.maxLength)):(this.textLength=this.maxLength+n,this.enable())}}setChatHistory(t,e){this.doOverHistory=!1;const{html:i,gridIndex:s,markIndex:n,cursorIndex:a}=t;this.richText.innerHTML=i;const r=this.richText.childNodes[s].childNodes[n].childNodes[0].childNodes[0];this.chat.restCursorPos(r,a),this.chat.viewIntoPoint(),this.richTextInput(e).then((()=>{this.doOverHistory=!0}))}revisePCPointDialogLabel(t={}){const e=Object.assign({},{title:"群成员",checkLabel:"多选"},t);this.dialogElm.querySelector(".call-user-dialog-header-title").innerText=e.title,this.dialogCheckElm.innerText=e.checkLabel}revisePCCheckDialogLabel(t={}){const e=Object.assign({},{title:"选择要@的人",searchPlaceholder:"搜素人员名称",searchEmptyLabel:"没有匹配到任何结果",userTagTitle:"研讨成员列表",checkAllLabel:"全选",confirmLabel:"确定",cancelLabel:"取消"},t);this.checkboxElm.querySelector(".checkbox-dialog-container-header").children[0].innerText=e.title,this.searchElm.setAttribute("placeholder",e.searchPlaceholder||""),this.searchEmptyLabel=e.searchEmptyLabel||"",this.checkboxElm.querySelector(".checkbox-dialog-right-box-title").innerText=e.userTagTitle,this.checkAllLabel=e.checkAllLabel||"",this.checkGroupElm.children[0].children[2].innerText=this.checkAllLabel,this.checkboxElm.querySelector(".btn-submit").innerText=e.confirmLabel,this.checkboxElm.querySelector(".btn-close").innerText=e.cancelLabel}reviseH5DialogLabel(t){const e=Object.assign({},{title:"选择提醒的人",searchPlaceholder:"搜素人员名称",confirmLabel:"确定",cancelLabel:"收起"},t);this.dialogH5Elm.querySelector(".popup-title").innerText=e.title,this.dialogH5SearchElm.setAttribute("placeholder",e.searchPlaceholder||""),this.dialogH5CheckElm.innerText=e.confirmLabel,this.dialogH5ShowElm.innerText=e.cancelLabel}reverseAnalysis(t,e){const i=document.createElement("div");i.innerHTML=t;const s=i.children;Array.prototype.forEach.call(s,(t=>{t.className="chat-grid-wrap",t.setAttribute("data-set-richType","richBox");const e=t.children,i={},s=[];Array.prototype.forEach.call(e,((n,a)=>{if(-1!==n.className.indexOf("chat-grid-input")){const t=n.innerText;return n.className="",n.setAttribute("data-set-richType","richMark"),void(n.innerHTML=`<span class="chat-grid-input chat-stat" data-set-richType="richInput" data-set-empty="false">${t}</span>`)}if("BR"===n.tagName){const e=this.chat.getGridElm(!0);return t.removeChild(n),void t.appendChild(e)}const r=n.cloneNode(!0);r.setAttribute("contenteditable","false");const o=document.createElement("span");o.className="chat-tag",o.setAttribute("contenteditable","false"),o.setAttribute("data-set-richType","chatTag"),o.appendChild(r),i[a]=o,a!==e.length-1?-1===e[a+1].className.indexOf("chat-grid-input")&&s.push(a):s.push(a),0===a&&s.push(-1)}));for(const r in i){const s=Number(r);s===e.length-1?(t.removeChild(e[s]),t.appendChild(i[r])):(t.insertBefore(i[r],e[s+1]),t.removeChild(e[s]))}const n=[],a=t.children;s.forEach((t=>{t===a.length-1?n.push("isEnd"):n.push(a[t+1])})),n.forEach((e=>{const i=this.chat.getGridElm(!0);if("isEnd"===e)t.appendChild(i);else{const s=i.children[0];s.removeChild(s.childNodes[1]),t.insertBefore(i,e)}}))})),e?(this.enable(),this.insertInsideHtml(i.innerHTML)):(this.richText.innerHTML=i.innerHTML,this.enable(),this.chat.viewIntoPoint(),this.richTextInput())}addEventListener(t,e){this.chatEventModule[t].push(e)}removeEventListener(t,e){const i=this.chatEventModule[t],s=i.indexOf(e);-1!==s&&i.splice(s,1)}triggerChatEvent(t,...e){let i;return this.chatEventModule[t].forEach((t=>{t&&(i?t(...e):i=t(...e))})),i}ruleChatEvent(t,e,...i){"PREVENT"!==(this.triggerChatEvent(e,...i)+"").toUpperCase()&&(t&&t.bind(this)(),t=null)}}if(!window)throw new Error("非web环境!");window.console&&window.console.log&&console.log(" %c ".concat("ChatArea"," %c v4.6.5 "),"background: #269AFF; color: #FFFFFF; padding: 4px 0; border-radius: 4px 0px 0px 4px; font-style: italic;","background: #FFFFFF; color: #269AFF; padding: 2px 0; border-radius: 0px 4px 4px 0px; font-style: italic; border: 2px solid #269AFF;"),window.ChatArea=m},"93f9":function(t,e,i){"use strict";i("323d")},"96cf":function(t,e,i){var s=function(t){"use strict";var e,i=Object.prototype,s=i.hasOwnProperty,n=Object.defineProperty||function(t,e,i){t[e]=i.value},a="function"===typeof Symbol?Symbol:{},r=a.iterator||"@@iterator",o=a.asyncIterator||"@@asyncIterator",c=a.toStringTag||"@@toStringTag";function l(t,e,i){return Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(U){l=function(t,e,i){return t[e]=i}}function d(t,e,i,s){var a=e&&e.prototype instanceof v?e:v,r=Object.create(a.prototype),o=new N(s||[]);return n(r,"_invoke",{value:_(t,i,o)}),r}function u(t,e,i){try{return{type:"normal",arg:t.call(e,i)}}catch(U){return{type:"throw",arg:U}}}t.wrap=d;var h="suspendedStart",p="suspendedYield",m="executing",g="completed",f={};function v(){}function b(){}function y(){}var C={};l(C,r,(function(){return this}));var x=Object.getPrototypeOf,w=x&&x(x(M([])));w&&w!==i&&s.call(w,r)&&(C=w);var k=y.prototype=v.prototype=Object.create(C);function I(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function A(t,e){function i(n,a,r,o){var c=u(t[n],t,a);if("throw"!==c.type){var l=c.arg,d=l.value;return d&&"object"===typeof d&&s.call(d,"__await")?e.resolve(d.__await).then((function(t){i("next",t,r,o)}),(function(t){i("throw",t,r,o)})):e.resolve(d).then((function(t){l.value=t,r(l)}),(function(t){return i("throw",t,r,o)}))}o(c.arg)}var a;function r(t,s){function n(){return new e((function(e,n){i(t,s,e,n)}))}return a=a?a.then(n,n):n()}n(this,"_invoke",{value:r})}function _(t,e,i){var s=h;return function(n,a){if(s===m)throw new Error("Generator is already running");if(s===g){if("throw"===n)throw a;return L()}i.method=n,i.arg=a;while(1){var r=i.delegate;if(r){var o=E(r,i);if(o){if(o===f)continue;return o}}if("next"===i.method)i.sent=i._sent=i.arg;else if("throw"===i.method){if(s===h)throw s=g,i.arg;i.dispatchException(i.arg)}else"return"===i.method&&i.abrupt("return",i.arg);s=m;var c=u(t,e,i);if("normal"===c.type){if(s=i.done?g:p,c.arg===f)continue;return{value:c.arg,done:i.done}}"throw"===c.type&&(s=g,i.method="throw",i.arg=c.arg)}}}function E(t,i){var s=i.method,n=t.iterator[s];if(n===e)return i.delegate=null,"throw"===s&&t.iterator["return"]&&(i.method="return",i.arg=e,E(t,i),"throw"===i.method)||"return"!==s&&(i.method="throw",i.arg=new TypeError("The iterator does not provide a '"+s+"' method")),f;var a=u(n,t.iterator,i.arg);if("throw"===a.type)return i.method="throw",i.arg=a.arg,i.delegate=null,f;var r=a.arg;return r?r.done?(i[t.resultName]=r.value,i.next=t.nextLoc,"return"!==i.method&&(i.method="next",i.arg=e),i.delegate=null,f):r:(i.method="throw",i.arg=new TypeError("iterator result is not an object"),i.delegate=null,f)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function M(t){if(null!=t){var i=t[r];if(i)return i.call(t);if("function"===typeof t.next)return t;if(!isNaN(t.length)){var n=-1,a=function i(){while(++n<t.length)if(s.call(t,n))return i.value=t[n],i.done=!1,i;return i.value=e,i.done=!0,i};return a.next=a}}throw new TypeError(typeof t+" is not iterable")}function L(){return{value:e,done:!0}}return b.prototype=y,n(k,"constructor",{value:y,configurable:!0}),n(y,"constructor",{value:b,configurable:!0}),b.displayName=l(y,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"===typeof t&&t.constructor;return!!e&&(e===b||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,y):(t.__proto__=y,l(t,c,"GeneratorFunction")),t.prototype=Object.create(k),t},t.awrap=function(t){return{__await:t}},I(A.prototype),l(A.prototype,o,(function(){return this})),t.AsyncIterator=A,t.async=function(e,i,s,n,a){void 0===a&&(a=Promise);var r=new A(d(e,i,s,n),a);return t.isGeneratorFunction(i)?r:r.next().then((function(t){return t.done?t.value:r.next()}))},I(k),l(k,c,"Generator"),l(k,r,(function(){return this})),l(k,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),i=[];for(var s in e)i.push(s);return i.reverse(),function t(){while(i.length){var s=i.pop();if(s in e)return t.value=s,t.done=!1,t}return t.done=!0,t}},t.values=M,N.prototype={constructor:N,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(T),!t)for(var i in this)"t"===i.charAt(0)&&s.call(this,i)&&!isNaN(+i.slice(1))&&(this[i]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0],e=t.completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var i=this;function n(s,n){return o.type="throw",o.arg=t,i.next=s,n&&(i.method="next",i.arg=e),!!n}for(var a=this.tryEntries.length-1;a>=0;--a){var r=this.tryEntries[a],o=r.completion;if("root"===r.tryLoc)return n("end");if(r.tryLoc<=this.prev){var c=s.call(r,"catchLoc"),l=s.call(r,"finallyLoc");if(c&&l){if(this.prev<r.catchLoc)return n(r.catchLoc,!0);if(this.prev<r.finallyLoc)return n(r.finallyLoc)}else if(c){if(this.prev<r.catchLoc)return n(r.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<r.finallyLoc)return n(r.finallyLoc)}}}},abrupt:function(t,e){for(var i=this.tryEntries.length-1;i>=0;--i){var n=this.tryEntries[i];if(n.tryLoc<=this.prev&&s.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var a=n;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var r=a?a.completion:{};return r.type=t,r.arg=e,a?(this.method="next",this.next=a.finallyLoc,f):this.complete(r)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var i=this.tryEntries[e];if(i.finallyLoc===t)return this.complete(i.completion,i.afterLoc),T(i),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var i=this.tryEntries[e];if(i.tryLoc===t){var s=i.completion;if("throw"===s.type){var n=s.arg;T(i)}return n}}throw new Error("illegal catch attempt")},delegateYield:function(t,i,s){return this.delegate={iterator:M(t),resultName:i,nextLoc:s},"next"===this.method&&(this.arg=e),f}},t}(t.exports);try{regeneratorRuntime=s}catch(n){"object"===typeof globalThis?globalThis.regeneratorRuntime=s:Function("r","regeneratorRuntime = r")(s)}},"990b":function(t,e,i){var s=i("9093"),n=i("2621"),a=i("cb7c"),r=i("7726").Reflect;t.exports=r&&r.ownKeys||function(t){var e=s.f(a(t)),i=n.f;return i?e.concat(i(t)):e}},"9b43":function(t,e,i){var s=i("d8e8");t.exports=function(t,e,i){if(s(t),void 0===e)return t;switch(i){case 1:return function(i){return t.call(e,i)};case 2:return function(i,s){return t.call(e,i,s)};case 3:return function(i,s,n){return t.call(e,i,s,n)}}return function(){return t.apply(e,arguments)}}},"9c6c":function(t,e,i){var s=i("2b4c")("unscopables"),n=Array.prototype;void 0==n[s]&&i("32e9")(n,s,{}),t.exports=function(t){n[s][t]=!0}},"9def":function(t,e,i){var s=i("4588"),n=Math.min;t.exports=function(t){return t>0?n(s(t),9007199254740991):0}},"9e1e":function(t,e,i){t.exports=!i("79e5")((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},a481:function(t,e,i){"use strict";var s=i("cb7c"),n=i("4bf8"),a=i("9def"),r=i("4588"),o=i("0390"),c=i("5f1b"),l=Math.max,d=Math.min,u=Math.floor,h=/\$([$&`']|\d\d?|<[^>]*>)/g,p=/\$([$&`']|\d\d?)/g,m=function(t){return void 0===t?t:String(t)};i("214f")("replace",2,(function(t,e,i,g){return[function(s,n){var a=t(this),r=void 0==s?void 0:s[e];return void 0!==r?r.call(s,a,n):i.call(String(a),s,n)},function(t,e){var n=g(i,t,this,e);if(n.done)return n.value;var u=s(t),h=String(this),p="function"===typeof e;p||(e=String(e));var v=u.global;if(v){var b=u.unicode;u.lastIndex=0}var y=[];while(1){var C=c(u,h);if(null===C)break;if(y.push(C),!v)break;var x=String(C[0]);""===x&&(u.lastIndex=o(h,a(u.lastIndex),b))}for(var w="",k=0,I=0;I<y.length;I++){C=y[I];for(var A=String(C[0]),_=l(d(r(C.index),h.length),0),E=[],S=1;S<C.length;S++)E.push(m(C[S]));var T=C.groups;if(p){var N=[A].concat(E,_,h);void 0!==T&&N.push(T);var M=String(e.apply(void 0,N))}else M=f(A,h,_,E,T,e);_>=k&&(w+=h.slice(k,_)+M,k=_+A.length)}return w+h.slice(k)}];function f(t,e,s,a,r,o){var c=s+t.length,l=a.length,d=p;return void 0!==r&&(r=n(r),d=h),i.call(o,d,(function(i,n){var o;switch(n.charAt(0)){case"$":return"$";case"&":return t;case"`":return e.slice(0,s);case"'":return e.slice(c);case"<":o=r[n.slice(1,-1)];break;default:var d=+n;if(0===d)return i;if(d>l){var h=u(d/10);return 0===h?i:h<=l?void 0===a[h-1]?n.charAt(1):a[h-1]+n.charAt(1):i}o=a[d-1]}return void 0===o?"":o}))}}))},aa77:function(t,e,i){var s=i("5ca1"),n=i("be13"),a=i("79e5"),r=i("fdef"),o="["+r+"]",c="​…",l=RegExp("^"+o+o+"*"),d=RegExp(o+o+"*$"),u=function(t,e,i){var n={},o=a((function(){return!!r[t]()||c[t]()!=c})),l=n[t]=o?e(h):r[t];i&&(n[i]=l),s(s.P+s.F*o,"String",n)},h=u.trim=function(t,e){return t=String(n(t)),1&e&&(t=t.replace(l,"")),2&e&&(t=t.replace(d,"")),t};t.exports=u},aae3:function(t,e,i){var s=i("d3f4"),n=i("2d95"),a=i("2b4c")("match");t.exports=function(t){var e;return s(t)&&(void 0!==(e=t[a])?!!e:"RegExp"==n(t))}},ab30:function(t,e,i){},ac6a:function(t,e,i){for(var s=i("cadf"),n=i("0d58"),a=i("2aba"),r=i("7726"),o=i("32e9"),c=i("84f2"),l=i("2b4c"),d=l("iterator"),u=l("toStringTag"),h=c.Array,p={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},m=n(p),g=0;g<m.length;g++){var f,v=m[g],b=p[v],y=r[v],C=y&&y.prototype;if(C&&(C[d]||o(C,d,h),C[u]||o(C,u,v),c[v]=h,b))for(f in s)C[f]||a(C,f,s[f],!0)}},b0c5:function(t,e,i){"use strict";var s=i("520a");i("5ca1")({target:"RegExp",proto:!0,forced:s!==/./.exec},{exec:s})},b25a:function(t,e,i){"use strict";i("ab30")},ba05:function(t,e,i){},bd33:function(t,e,i){"use strict";i("e6e3")},be13:function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},c366:function(t,e,i){var s=i("6821"),n=i("9def"),a=i("77f1");t.exports=function(t){return function(e,i,r){var o,c=s(e),l=n(c.length),d=a(r,l);if(t&&i!=i){while(l>d)if(o=c[d++],o!=o)return!0}else for(;l>d;d++)if((t||d in c)&&c[d]===i)return t||d||0;return!t&&-1}}},c5f6:function(t,e,i){"use strict";var s=i("7726"),n=i("69a8"),a=i("2d95"),r=i("5dbc"),o=i("6a99"),c=i("79e5"),l=i("9093").f,d=i("11e9").f,u=i("86cc").f,h=i("aa77").trim,p="Number",m=s[p],g=m,f=m.prototype,v=a(i("2aeb")(f))==p,b="trim"in String.prototype,y=function(t){var e=o(t,!1);if("string"==typeof e&&e.length>2){e=b?e.trim():h(e,3);var i,s,n,a=e.charCodeAt(0);if(43===a||45===a){if(i=e.charCodeAt(2),88===i||120===i)return NaN}else if(48===a){switch(e.charCodeAt(1)){case 66:case 98:s=2,n=49;break;case 79:case 111:s=8,n=55;break;default:return+e}for(var r,c=e.slice(2),l=0,d=c.length;l<d;l++)if(r=c.charCodeAt(l),r<48||r>n)return NaN;return parseInt(c,s)}}return+e};if(!m(" 0o1")||!m("0b1")||m("+0x1")){m=function(t){var e=arguments.length<1?0:t,i=this;return i instanceof m&&(v?c((function(){f.valueOf.call(i)})):a(i)!=p)?r(new g(y(e)),i,m):y(e)};for(var C,x=i("9e1e")?l(g):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),w=0;x.length>w;w++)n(g,C=x[w])&&!n(m,C)&&u(m,C,d(g,C));m.prototype=f,f.constructor=m,i("2aba")(s,p,m)}},c69a:function(t,e,i){t.exports=!i("9e1e")&&!i("79e5")((function(){return 7!=Object.defineProperty(i("230e")("div"),"a",{get:function(){return 7}}).a}))},ca5a:function(t,e){var i=0,s=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++i+s).toString(36))}},cadf:function(t,e,i){"use strict";var s=i("9c6c"),n=i("d53b"),a=i("84f2"),r=i("6821");t.exports=i("01f9")(Array,"Array",(function(t,e){this._t=r(t),this._i=0,this._k=e}),(function(){var t=this._t,e=this._k,i=this._i++;return!t||i>=t.length?(this._t=void 0,n(1)):n(0,"keys"==e?i:"values"==e?t[i]:[i,t[i]])}),"values"),a.Arguments=a.Array,s("keys"),s("values"),s("entries")},cb50:function(t,e,i){},cb7c:function(t,e,i){var s=i("d3f4");t.exports=function(t){if(!s(t))throw TypeError(t+" is not an object!");return t}},cc9a:function(t,e,i){"use strict";i("8bcf")},cd1c:function(t,e,i){var s=i("e853");t.exports=function(t,e){return new(s(t))(e)}},ce10:function(t,e,i){var s=i("69a8"),n=i("6821"),a=i("c366")(!1),r=i("613b")("IE_PROTO");t.exports=function(t,e){var i,o=n(t),c=0,l=[];for(i in o)i!=r&&s(o,i)&&l.push(i);while(e.length>c)s(o,i=e[c++])&&(~a(l,i)||l.push(i));return l}},d2c8:function(t,e,i){var s=i("aae3"),n=i("be13");t.exports=function(t,e,i){if(s(e))throw TypeError("String#"+i+" doesn't accept regex!");return String(n(t))}},d3f4:function(t,e){t.exports=function(t){return"object"===typeof t?null!==t:"function"===typeof t}},d53b:function(t,e){t.exports=function(t,e){return{value:e,done:!!t}}},d6dd:function(t,e,i){},d6f8:function(t,e,i){},d8e8:function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},dcc3:function(t,e,i){"use strict";i("117e")},dfa9:function(t,e,i){},e003:function(t,e,i){"use strict";i("61c8")},e11e:function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},e61c:function(t,e,i){"use strict";i("d6dd")},e6e3:function(t,e,i){},e853:function(t,e,i){var s=i("d3f4"),n=i("1169"),a=i("2b4c")("species");t.exports=function(t){var e;return n(t)&&(e=t.constructor,"function"!=typeof e||e!==Array&&!n(e.prototype)||(e=void 0),s(e)&&(e=e[a],null===e&&(e=void 0))),void 0===e?Array:e}},ed7d:function(t,e,i){"use strict";i("3bcf")},f1ae:function(t,e,i){"use strict";var s=i("86cc"),n=i("4630");t.exports=function(t,e,i){e in t?s.f(t,e,n(0,i)):t[e]=i}},f559:function(t,e,i){"use strict";var s=i("5ca1"),n=i("9def"),a=i("d2c8"),r="startsWith",o=""[r];s(s.P+s.F*i("5147")(r),"String",{startsWith:function(t){var e=a(this,t,r),i=n(Math.min(arguments.length>1?arguments[1]:void 0,e.length)),s=String(t);return o?o.call(e,s,i):e.slice(i,i+s.length)===s}})},f6fd:function(t,e){(function(t){var e="currentScript",i=t.getElementsByTagName("script");e in t||Object.defineProperty(t,e,{get:function(){try{throw new Error}catch(s){var t,e=(/.*at [^\(]*\((.*):.+:.+\)$/gi.exec(s.stack)||[!1])[1];for(t in i)if(i[t].src==e||"interactive"==i[t].readyState)return i[t];return null}}})})(document)},f751:function(t,e,i){var s=i("5ca1");s(s.S+s.F,"Object",{assign:i("7333")})},fa5b:function(t,e,i){t.exports=i("5537")("native-function-to-string",Function.toString)},fab2:function(t,e,i){var s=i("7726").document;t.exports=s&&s.documentElement},fb15:function(t,e,i){"use strict";var s;function n(t){return"[object Object]"===Object.prototype.toString.call(t)}function a(t){return"string"==typeof t}function r(t){return(new Date).getTime()-t<864e5}function o(t){return!t||!(!Array.isArray(t)||0!=t.length)||!(!n(t)||0!=Object.values(t).length)}function c(t){return t&&"function"===typeof t}function l(t,e,i,s,n,a,r){try{var o=t[a](r),c=o.value}catch(l){return void i(l)}o.done?e(c):Promise.resolve(c).then(s,n)}function d(t){return function(){var e=this,i=arguments;return new Promise((function(s,n){var a=t.apply(e,i);function r(t){l(a,s,n,r,o,"next",t)}function o(t){l(a,s,n,r,o,"throw",t)}r(void 0)}))}}i.r(e),"undefined"!==typeof window&&(i("f6fd"),(s=window.document.currentScript)&&(s=s.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(i.p=s[1])),i("7f7f"),i("ac6a"),i("3b2b"),i("cadf"),i("8615"),i("6b54"),i("96cf"),i("456d"),i("6762"),i("2fdb");var u,h,p=[],m={hover:function(t){},focus:function(t){var e=this;t.addEventListener("focus",(function(t){e.changeVisible()})),t.addEventListener("blur",(function(t){e.changeVisible()}))},click:function(t){var e=this;t.addEventListener("click",(function(t){t.stopPropagation(),M.hide(),e.changeVisible()}))},contextmenu:function(t){var e=this;t.addEventListener("contextmenu",(function(t){t.preventDefault(),e.changeVisible()}))}},g={name:"LemonPopover",props:{trigger:{type:String,default:"click",validator:function(t){return Object.keys(m).includes(t)}}},data:function(){return{popoverStyle:{},visible:!1}},created:function(){document.addEventListener("click",this._documentClickEvent),p.push(this.close)},mounted:function(){m[this.trigger].call(this,this.$slots.default[0].elm)},render:function(){var t=arguments[0];return t("span",{style:"position:relative"},[t("transition",{attrs:{name:"lemon-slide-top"}},[this.visible&&t("div",{class:"lemon-popover",ref:"popover",style:this.popoverStyle,on:{click:function(t){return t.stopPropagation()}}},[t("div",{class:"lemon-popover__content"},[this.$slots.content]),t("div",{class:"lemon-popover__arrow"})])]),this.$slots.default])},destroyed:function(){document.removeEventListener("click",this._documentClickEvent)},computed:{},watch:{visible:function(){var t=d(regeneratorRuntime.mark((function t(e){var i,s;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!e){t.next=6;break}return t.next=3,this.$nextTick();case 3:i=this.$slots.default[0].elm,s=this.$refs.popover,this.popoverStyle={top:"-".concat(s.offsetHeight+10,"px"),left:"".concat(i.offsetWidth/2-s.offsetWidth/2,"px")};case 6:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}()},methods:{_documentClickEvent:function(t){t.stopPropagation(),this.visible&&this.close()},changeVisible:function(){this.visible?this.close():this.open()},open:function(){this.closeAll(),this.visible=!0},closeAll:function(){p.forEach((function(t){return t()}))},close:function(){this.visible=!1}}},f=g;function v(t,e,i,s,n,a,r,o){var c,l="function"===typeof t?t.options:t;if(e&&(l.render=e,l.staticRenderFns=i,l._compiled=!0),s&&(l.functional=!0),a&&(l._scopeId="data-v-"+a),r?(c=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),n&&n.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(r)},l._ssrRegister=c):n&&(c=o?function(){n.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:n),c)if(l.functional){l._injectStyles=c;var d=l.render;l.render=function(t,e){return c.call(e),d(t,e)}}else{var u=l.beforeCreate;l.beforeCreate=u?[].concat(u,c):[c]}return{exports:t,options:l}}i("718e");var b,y=v(f,u,h,!1,null,null,null),C=y.exports,x=function(){b&&(b.style.display="none")},w=function(){b&&(b.style.display="block")};document.addEventListener("click",(function(t){x()}));var k,I,A,_,E,S,T,N,M={hide:x,bind:function(t,e,i){t.addEventListener(e.modifiers.click?"click":"contextmenu",(function(t){if(!o(e.value)&&Array.isArray(e.value)){var s;e.modifiers.click&&t.stopPropagation(),t.preventDefault(),C.methods.closeAll();var n=[];e.modifiers.message?s=i.context:e.modifiers.contact&&(s=i.child),b||(b=document.createElement("div"),b.className="lemon-contextmenu",document.body.appendChild(b)),b.innerHTML=e.value.map((function(t){var e;if(e=c(t.visible)?t.visible(s):void 0===t.visible||t.visible,e){n.push(t);var i=t.icon?'<i class="lemon-contextmenu__icon '.concat(t.icon,'"></i>'):"";return'<div style="color:'.concat(t.color,'" title="').concat(t.text,'" class="lemon-contextmenu__item">').concat(i,"<span>").concat(t.text,"</span></div>")}return""})).join("");var a=b.offsetHeight,r=b.offsetWidth,l=window.innerHeight,d=window.innerWidth,u=t.clientY+a>l?t.pageY-a-5:t.pageY,h=t.clientX+r>d?t.pageX-r-5:t.pageX;b.style.top="".concat(u,"px"),b.style.left="".concat(h,"px"),b.childNodes.forEach((function(t,e){var i=n[e],a=i.click;i.render,t.addEventListener("click",(function(t){t.stopPropagation(),c(a)&&a(t,s,x)}))})),w()}}))}},L={name:"LemonTabs",props:{activeIndex:String},data:function(){return{active:this.activeIndex}},mounted:function(){this.active||(this.active=this.$slots["tab-pane"][0].data.attrs.index)},render:function(){var t=this,e=arguments[0],i=[],s=[];return this.$slots["tab-pane"].map((function(n){var a=n.data.attrs,r=a.tab,o=a.index;i.push(e("div",{class:"lemon-tabs-content__pane",directives:[{name:"show",value:t.active==o}]},[n])),s.push(e("div",{class:["lemon-tabs-nav__item",t.active==o&&"lemon-tabs-nav__item--active"],on:{click:function(){return t._handleNavClick(o)}}},[r]))})),e("div",{class:"lemon-tabs"},[e("div",{class:"lemon-tabs-content"},[i]),e("div",{class:"lemon-tabs-nav"},[s])])},methods:{_handleNavClick:function(t){this.active=t}}},U=L,O=(i("69bb"),v(U,k,I,!1,null,null,null)),D=O.exports,P={name:"LemonButton",props:{color:{type:String,default:"default"},disabled:Boolean},render:function(){var t=arguments[0];return t("button",{class:["lemon-button","lemon-button--color-".concat(this.color)],attrs:{disabled:this.disabled,type:"button"},on:{click:this._handleClick}},[this.$slots.default])},methods:{_handleClick:function(t){this.$emit("click",t)}}},j=P,R=(i("cc9a"),v(j,A,_,!1,null,null,null)),B=R.exports,F=(i("c5f6"),{name:"LemonBadge",props:{count:[Number,Boolean],overflowCount:{type:Number,default:99}},render:function(){var t=arguments[0];return t("span",{class:"lemon-badge"},[this.$slots.default,0!==this.count&&void 0!==this.count&&t("span",{class:["lemon-badge__label",this.isDot&&"lemon-badge__label--dot"]},[this.label])])},computed:{isDot:function(){return!0===this.count},label:function(){return this.isDot?"":this.count>this.overflowCount?"".concat(this.overflowCount,"+"):this.count}},methods:{}}),$=F,H=(i("93f9"),v($,E,S,!1,null,null,null)),V=H.exports,G={name:"LemonAvatar",inject:["IMUI"],props:{src:String,icon:{type:String,default:"lemon-icon-people"},circle:{type:Boolean,default:function(){return!!this.IMUI&&this.IMUI.avatarCricle}},size:{type:Number,default:32}},data:function(){return{imageFinishLoad:!0}},render:function(){var t=this,e=arguments[0];return e("span",{style:this.style,class:["lemon-avatar",{"lemon-avatar--circle":this.circle}],on:{click:function(e){return t.$emit("click",e)}}},[(this.imageFinishLoad||!this.src)&&e("i",{class:this.icon}),e("img",{attrs:{src:this.src},on:{load:this._handleLoad}})])},computed:{style:function(){var t="".concat(this.size,"px");return{width:t,height:t,lineHeight:t,fontSize:"".concat(this.size/2,"px")}}},methods:{_handleLoad:function(){this.imageFinishLoad=!1}}},K=G,z=(i("e003"),v(K,T,N,!1,null,null,null)),Q=z.exports,Y=i("2638"),J=i.n(Y);function q(t){return q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},q(t)}function W(t,e){if("object"!=q(t)||!t)return t;var i=t[Symbol.toPrimitive];if(void 0!==i){var s=i.call(t,e||"default");if("object"!=q(s))return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}function Z(t){var e=W(t,"string");return"symbol"==q(e)?e:String(e)}function X(t,e,i){return e=Z(e),e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function tt(t,e,i){return t?t(i):e}function et(t){return t<10?"0".concat(t):t}function it(t){var e,i=new Date(t),s=new Date,n=function(t){return t.getFullYear()},a=function(t){return"".concat(t.getMonth()+1,"-").concat(t.getDate())},r=n(i),o=n(s);return e=r!==o?"y年m月d日 h:i":"".concat(r,"-").concat(a(i))==="".concat(o,"-").concat(a(s))?"h:i":"m月d日 h:i",st(t,e)}function st(t,e){e||(e="y-m-d h:i:s"),t=t?new Date(t):new Date;for(var i=[t.getFullYear().toString(),et((t.getMonth()+1).toString()),et(t.getDate().toString()),et(t.getHours().toString()),et(t.getMinutes().toString()),et(t.getSeconds().toString())],s="ymdhis",n=0;n<i.length;n++)e=e.replace(s.charAt(n),i[n]);return e}function nt(t,e){c(t)?t((function(){e()})):e()}function at(t){return t.replace(/<(?!img).*?>/gi,"")}function rt(t){if(null==t||""==t)return"0 Bytes";var e=["B","K","M","G","T","P","E","Z","Y"],i=0,s=parseFloat(t);i=Math.floor(Math.log(s)/Math.log(1024));var n=s/Math.pow(1024,i);return n=parseFloat(n.toFixed(2)),n+e[i]}function ot(){var t=(new Date).getTime();window.performance&&"function"===typeof window.performance.now&&(t+=performance.now());var e="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var i=(t+16*Math.random())%16|0;return t=Math.floor(t/16),("x"==e?i:3&i|8).toString(16)}));return e}i("8e6e"),i("a481");var ct,lt,dt={name:"LemonContact",components:{},inject:{IMUI:{from:"IMUI",default:function(){return this}}},data:function(){return{}},props:{contact:Object,simple:Boolean,timeFormat:{type:Function,default:function(t){return st(t,r(t)?"h:i":"y/m/d")}}},render:function(){var t=this,e=arguments[0];return e("div",{class:["lemon-contact",{"lemon-contact--name-center":this.simple}],attrs:{title:this.contact.displayName},on:{click:function(e){return t._handleClick(e,t.contact)}}},[tt(this.$scopedSlots.default,this._renderInner(),this.contact)])},created:function(){},mounted:function(){},computed:{},watch:{},methods:{_renderInner:function(){var t=this.$createElement,e=this.contact;return[t("lemon-badge",{attrs:{count:this.simple?0:e.unread},class:"lemon-contact__avatar"},[t("lemon-avatar",{attrs:{size:40,src:e.avatar}})]),t("div",{class:"lemon-contact__inner"},[t("p",{class:"lemon-contact__label"},[t("span",{class:"lemon-contact__name"},[e.displayName]),!this.simple&&t("span",{class:"lemon-contact__time"},[this.timeFormat(e.lastSendTime)])]),!this.simple&&t("p",{class:"lemon-contact__content"},[a(e.lastContent)?t("span",J()([{},{domProps:{innerHTML:e.lastContent}}])):e.lastContent])])]},_handleClick:function(t,e){this.$emit("click",e)}}},ut=dt,ht=(i("8fb6"),v(ut,ct,lt,!1,null,null,null)),pt=ht.exports;i("5df3"),i("1c4c"),i("9204");const mt=window.ChatArea;var gt=mt;function ft(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function vt(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?ft(Object(i),!0).forEach((function(e){X(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):ft(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}i("6fb5");var bt,yt,Ct,xt,wt,kt,It,At=function(t,e){document.execCommand(t,!1,e)},_t=window.getSelection(),Et=[],St={name:"LemonEditor",inject:{IMUI:{from:"IMUI",default:function(){return this}}},components:{},props:{tools:{type:Array,default:function(){return[]}},sendText:{type:String,default:"发 送"},wrapKey:{type:Function,default:function(t){return 13==t.keyCode&&!0===t.ctrlKey}},sendKey:{type:Function,default:function(t){return 13==t.keyCode&&0==t.ctrlKey&&0==t.shiftKey}}},data:function(){return this.clipboardBlob=null,{clipboardUrl:"",submitDisabled:!0,accept:"",chatArea:null}},created:function(){var t=this;this.IMUI.$on("change-contact",(function(){t.closeClipboardImage()})),this.$nextTick((function(){t.chatArea=new gt({elm:t.$refs.textarea,userList:[],userProps:{id:"id",name:"displayName",avatar:"avatar",pinyin:"name_py"},placeholder:"",needCallSpace:!0,wrapKeyFun:function(e){return t.wrapKey(e)},sendKeyFun:function(e){return t.sendKey(e)}}),t.chatArea.revisePCCheckDialogLabel({title:"选择要@的人",searchPlaceholder:"搜素人员名称",searchEmptyLabel:"没有匹配到任何结果",userTagTitle:"成员列表",checkAllLabel:"全选",confirmLabel:"确定",cancelLabel:"取消"}),t.chatArea.richText.addEventListener("blur",(function(e){setTimeout(t.chatArea.winClick,200)})),t.chatArea.richText.addEventListener("drop",(function(e){var i=e.dataTransfer,s=i.files;Array.from(s).forEach((function(e){t.$emit("upload",e)}))})),t.chatArea.enterSend=function(){0==t.submitDisabled&&t._handleSend()}}))},render:function(){var t=this,e=arguments[0],i=[],s=[];return this.proxyTools.forEach((function(n){var a=n.name,r=n.title,o=n.render,c=n.click,l=n.isRight;c=c||new Function;var d,u=["lemon-editor__tool-item",{"lemon-editor__tool-item--right":l}];d="emoji"==a?0==Et.length?"":e("lemon-popover",{class:"lemon-editor__emoji"},[e("template",{slot:"content"},[t._renderEmojiTabs()]),e("div",{class:u,attrs:{title:r}},[o()])]):e("div",{class:u,on:{click:c},attrs:{title:r}},[o()]),l?s.push(d):i.push(d)})),e("div",{class:"lemon-editor"},[this.clipboardUrl&&e("div",{class:"lemon-editor__clipboard-image"},[e("img",{attrs:{src:this.clipboardUrl}}),e("div",[e("lemon-button",{style:{marginRight:"10px"},on:{click:this.closeClipboardImage},attrs:{color:"grey"}},["取消"]),e("lemon-button",{on:{click:this.sendClipboardImage}},["发送图片"])])]),e("input",{style:"display:none",attrs:{type:"file",multiple:"multiple",accept:this.accept},ref:"fileInput",on:{change:this._handleChangeFile}}),e("div",{class:"lemon-editor__tool"},[e("div",{class:"lemon-editor__tool-left"},[i]),e("div",{class:"lemon-editor__tool-right"},[s])]),e("div",{class:"lemon-editor__inner"},[e("div",{class:"lemon-editor__input",ref:"textarea",on:{keyup:this._handleKeyup,keydown:this._handleKeydown,paste:this._handlePaste,click:this._handleClick,input:this._handleInput},attrs:{spellcheck:"false"}})]),e("div",{class:"lemon-editor__footer"},[e("div",{class:"lemon-editor__tip"},[tt(this.IMUI.$scopedSlots["editor-footer"],"使用 ctrl + enter 换行")]),e("div",{class:"lemon-editor__submit"},[e("lemon-button",{attrs:{disabled:this.submitDisabled},on:{click:this._handleSend}},[this.sendText])])])])},computed:{proxyTools:function(){var t=this,e=this.$createElement;if(!this.tools)return[];var i=[{name:"emoji",title:"表情",click:null,render:function(t){return e("i",{class:"lemon-icon-emoji"})}},{name:"uploadFile",title:"文件上传",click:function(){return t.selectFile("*")},render:function(t){return e("i",{class:"lemon-icon-folder"})}},{name:"uploadImage",title:"图片上传",click:function(){return t.selectFile("image/*")},render:function(t){return e("i",{class:"lemon-icon-image"})}}],s=[];if(Array.isArray(this.tools)){var n={emoji:0,uploadFile:1,uploadImage:2},a=Object.keys(n);s=this.tools.map((function(t){return a.includes(t.name)?vt(vt({},i[n[t.name]]),t):t}))}else s=i;return s}},methods:{closeClipboardImage:function(){this.clipboardUrl="",this.clipboardBlob=null},sendClipboardImage:function(){this.clipboardBlob&&(this.$emit("upload",this.clipboardBlob),this.closeClipboardImage())},saveRangeToLast:function(){bt||(bt=document.createRange()),bt.selectNodeContents(textarea.value),bt.collapse(!1),_t.removeAllRanges(),_t.addRange(bt)},inertContent:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];e&&saveRangeToLast(),this.focusRange(),At("insertHTML",t),this.saveRange()},saveRange:function(){bt=_t.getRangeAt(0)},focusRange:function(){this.$refs.textarea.focus(),bt&&(_t.removeAllRanges(),_t.addRange(bt))},_handleClick:function(){this.saveRange()},_handleInput:function(){this._checkSubmitDisabled()},_renderEmojiTabs:function(){var t=this,e=this.$createElement,i=function(i){return i.map((function(i){return e("img",{attrs:{src:i.src,title:i.title},class:"lemon-editor__emoji-item",on:{click:function(){return t._handleSelectEmoji(i)}}})}))};if(Et[0].label){var s=Et.map((function(t,s){return e("div",{slot:"tab-pane",attrs:{index:s,tab:t.label}},[i(t.children)])}));return e("lemon-tabs",{style:"width: 412px"},[s])}return e("div",{class:"lemon-tabs-content",style:"width:406px"},[i(Et)])},_handleSelectEmoji:function(t){this.chatArea.insertHtml('<img emoji-name="'.concat(t.name,'" src="').concat(t.src,'"></img>')),this._checkSubmitDisabled()},selectFile:function(){var t=d(regeneratorRuntime.mark((function t(e){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return this.accept=e,t.next=3,this.$nextTick();case 3:this.$refs.fileInput.click();case 4:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}(),_handlePaste:function(t){t.preventDefault();var e=t.clipboardData||window.clipboardData,i=e.getData("Text");if(i)this.submitDisabled=!1;else{var s=this._getClipboardBlob(e),n=s.blob,a=s.blobUrl;this.clipboardBlob=n,this.clipboardUrl=a}},_getClipboardBlob:function(t){for(var e,i,s=0;s<t.items.length;++s)"file"==t.items[s].kind&&-1!==t.items[s].type.indexOf("image/")&&(e=t.items[s].getAsFile(),i=(window.URL||window.webkitURL).createObjectURL(e));return{blob:e,blobUrl:i}},_handleKeyup:function(t){this.saveRange(),this._checkSubmitDisabled()},_handleKeydown:function(t){(13==t.keyCode||13==t.keyCode&&t.shiftKey)&&t.preventDefault(),this.wrapKey(t)&&(t.preventDefault(),At("insertLineBreak"))},getFormatValue:function(){return this.IMUI.emojiImageToName(this.chatArea.getHtml({needUserId:!0}))},_checkSubmitDisabled:function(){this.submitDisabled=!at(this.chatArea.getHtml().trim())},_handleSend:function(t){var e=this.getFormatValue();this.$emit("send",e),this.clear(),this._checkSubmitDisabled()},_handleChangeFile:function(t){var e=this,i=this.$refs.fileInput;Array.from(i.files).forEach((function(t){e.$emit("upload",t)})),i.value=""},clear:function(){this.chatArea.clear()},initEmoji:function(t){Et=t,this.$forceUpdate()},setValue:function(t){""==t?this.clear():this.chatArea.reverseAnalysis(this.IMUI.emojiNameToImage(t)),this._checkSubmitDisabled()}}},Tt=St,Nt=(i("bd33"),v(Tt,yt,Ct,!1,null,null,null)),Mt=Nt.exports,Lt={name:"LemonMessages",components:{},props:{hideName:Boolean,hideTime:Boolean,reverseUserId:[String,Number],timeRange:{type:Number,default:1},timeFormat:{type:Function,default:function(t){return it(t)}},loadingText:{type:[String,Function]},loadendText:{type:[String,Function],default:"暂无更多消息"},messages:{type:Array,default:function(){return[]}}},data:function(){return this._lockScroll=!1,{_loading:!1,_loadend:!1,isBottom:!0}},render:function(){var t=this,e=arguments[0];return e("div",{class:"lemon-messages",ref:"wrap",on:{scroll:this._handleScroll}},[e("div",{class:["lemon-messages__load","lemon-messages__load--".concat(this._loadend?"end":"ing")]},[e("span",{class:"lemon-messages__loadend"},[a(this.loadendText)?this.loadendText:this.loadendText()]),e("span",{class:"lemon-messages__loading"},[this.loadingText?a(this.loadingText)?this.loadingText:this.loadingText():e("i",{class:"lemon-icon-loading lemonani-spin"})])]),this.messages.map((function(i,s){var n=[],a="lemon-message-".concat(i.type),r=t.toCamelCase(a);t.$options.components[r]||(i.type="text",i.content="[暂不支持的消息类型]",a="lemon-message-text");var o,c=t.messages[s-1];return c&&t.msecRange&&i.sendTime-c.sendTime>t.msecRange&&n.push(e("lemon-message-event",J()([{},{attrs:{message:{id:"__time__",type:"event",content:it(i.sendTime)}}}]))),o="event"==i.type?{message:i}:{timeFormat:t.timeFormat,message:i,reverse:t.reverseUserId==i.fromUser.id,hideTime:t.hideTime,hideName:t.hideName},n.push(e(a,J()([{ref:"message",refInFor:!0},{attrs:o}]))),n}))])},computed:{msecRange:function(){return 1e3*this.timeRange*60}},watch:{},methods:{loaded:function(){this._loadend=!0,this.$forceUpdate()},toCamelCase:function(t){return t.replace(/-([a-z])/g,(function(t,e){return e.toUpperCase()}))},resetLoadState:function(){var t=this;this._lockScroll=!0,this._loading=!1,this._loadend=!1,setTimeout((function(){t._lockScroll=!1}),200)},_handleScroll:function(){var t=d(regeneratorRuntime.mark((function t(e){var i,s,n,a,r,o=this;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!this._lockScroll){t.next=2;break}return t.abrupt("return");case 2:if(i=e.target,M.hide(),0!=i.scrollTop||0!=this._loading||0!=this._loadend){t.next=10;break}return this._loading=!0,t.next=8,this.$nextTick();case 8:s=i.scrollHeight,this.$emit("reach-top",function(){var t=d(regeneratorRuntime.mark((function t(e){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,o.$nextTick();case 2:i.scrollTop=i.scrollHeight-s,o._loading=!1,o._loadend=!!e;case 5:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 10:n=i.scrollTop,a=i.scrollHeight,r=this.$refs.wrap,this.isBottom=n+r.offsetHeight>=a-20,this.$emit("is-bottom",this.isBottom);case 15:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}(),scrollToBottom:function(){var t=d(regeneratorRuntime.mark((function t(){var e;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,this.$nextTick();case 2:e=this.$refs.wrap,e&&(e.scrollTop=e.scrollHeight);case 4:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()},created:function(){},mounted:function(){}},Ut=Lt,Ot=(i("ed7d"),v(Ut,xt,wt,!1,null,null,null)),Dt=Ot.exports,Pt={name:"lemonMessageBasic",inject:{IMUI:{from:"IMUI",default:function(){return this}}},props:{contextmenu:Array,message:{type:Object,default:function(){return{}}},timeFormat:{type:Function,default:function(){return""}},reverse:Boolean,hideName:Boolean,hideTime:Boolean},data:function(){return{}},render:function(){var t=this,e=arguments[0],i=this.message,s=i.fromUser,n=i.status,a=i.sendTime,r=1==this.hideName&&1==this.hideTime;return e("div",{class:["lemon-message","lemon-message--status-".concat(n),{"lemon-message--reverse":this.reverse,"lemon-message--hide-title":r}]},[e("div",{class:"lemon-message__avatar"},[e("lemon-avatar",{attrs:{size:36,shape:"square",src:s.avatar},on:{click:function(e){t._emitClick(e,"avatar")}}})]),e("div",{class:"lemon-message__inner"},[e("div",{class:"lemon-message__title"},[0==this.hideName&&e("span",{on:{click:function(e){t._emitClick(e,"displayName")}}},[s.displayName]),0==this.hideTime&&e("span",{class:"lemon-message__time",on:{click:function(e){t._emitClick(e,"sendTime")}}},[this.timeFormat(a)])]),e("div",{class:"lemon-message__content-flex"},[e("div",{directives:[{name:"lemon-contextmenu",value:this.IMUI.contextmenu,modifiers:{message:!0}}],class:"lemon-message__content",on:{click:function(e){t._emitClick(e,"content")}}},[tt(this.$scopedSlots["content"],null,this.message)]),e("div",{class:"lemon-message__content-after"},[tt(this.IMUI.$scopedSlots["message-after"],null,this.message)]),e("div",{class:"lemon-message__status",on:{click:function(e){t._emitClick(e,"status")}}},[e("i",{class:"lemon-icon-loading lemonani-spin"}),e("i",{class:"lemon-icon-prompt",attrs:{title:"重发消息"},style:{color:"#ff2525",cursor:"pointer"}})])])])])},created:function(){},mounted:function(){},computed:{},watch:{},methods:{_emitClick:function(t,e){this.IMUI.$emit("message-click",t,e,this.message,this.IMUI)}}},jt=Pt,Rt=(i("4c77"),v(jt,kt,It,!1,null,null,null)),Bt=Rt.exports;function Ft(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function $t(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?Ft(Object(i),!0).forEach((function(e){X(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Ft(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var Ht,Vt,Gt={name:"lemonMessageText",inheritAttrs:!1,inject:["IMUI"],render:function(){var t=this,e=arguments[0];return e("lemon-message-basic",J()([{class:"lemon-message-text"},{props:$t({},this.$attrs)},{scopedSlots:{content:function(i){var s=t.IMUI.emojiNameToImage(i.content);return e("span",J()([{},{domProps:{innerHTML:s}}]))}}}]))}},Kt=Gt,zt=(i("5778"),v(Kt,Ht,Vt,!1,null,null,null)),Qt=zt.exports;function Yt(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function Jt(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?Yt(Object(i),!0).forEach((function(e){X(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Yt(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var qt,Wt,Zt={name:"lemonMessageImage",inheritAttrs:!1,render:function(){var t=arguments[0];return t("lemon-message-basic",J()([{class:"lemon-message-image"},{props:Jt({},this.$attrs)},{scopedSlots:{content:function(e){return t("img",{attrs:{src:e.content}})}}}]))}},Xt=Zt,te=(i("e61c"),v(Xt,qt,Wt,!1,null,null,null)),ee=te.exports;function ie(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function se(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?ie(Object(i),!0).forEach((function(e){X(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):ie(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var ne,ae,re,oe,ce={name:"lemonMessageFile",inheritAttrs:!1,render:function(){var t=arguments[0];return t("lemon-message-basic",J()([{class:"lemon-message-file"},{props:se({},this.$attrs)},{scopedSlots:{content:function(e){return[t("div",{class:"lemon-message-file__inner"},[t("p",{class:"lemon-message-file__name"},[e.fileName]),t("p",{class:"lemon-message-file__byte"},[rt(e.fileSize)])]),t("div",{class:"lemon-message-file__sfx"},[t("i",{class:"lemon-icon-attah"})])]}}}]))}},le=ce,de=(i("85ff"),v(le,ne,ae,!1,null,null,null)),ue=de.exports,he={name:"lemonMessageEvent",inheritAttrs:!1,inject:["IMUI"],render:function(){var t=this,e=arguments[0],i=this.$attrs.message.content;return e("div",{class:"lemon-message lemon-message-event"},[e("span",{class:"lemon-message-event__content",on:{click:function(e){return t._emitClick(e,"content")}}},[i])])},methods:{_emitClick:function(t,e){this.IMUI.$emit("message-click",t,e,this.$attrs.message,this.IMUI)}}},pe=he,me=(i("dcc3"),v(pe,re,oe,!1,null,null,null)),ge=me.exports;function fe(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,s=new Array(e);i<e;i++)s[i]=t[i];return s}function ve(t){if(Array.isArray(t))return fe(t)}function be(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}function ye(t,e){if(t){if("string"===typeof t)return fe(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?fe(t,e):void 0}}function Ce(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function xe(t){return ve(t)||be(t)||ye(t)||Ce()}i("20d6"),i("f559"),i("f751"),i("7514"),i("55dd");var we="messages",ke="contacts",Ie=[we,ke],Ae={file:function(t){return"[文件]"},image:function(t){return"[图片]"},text:function(t){return this.emojiNameToImage(at(t.content))},event:function(t){return"[通知]"}};function _e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Ee(t,e){for(var i=0;i<e.length;i++){var s=e[i];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(t,Z(s.key),s)}}function Se(t,e,i){return e&&Ee(t.prototype,e),i&&Ee(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}var Te=function(){function t(){_e(this,t),this.table={}}return Se(t,[{key:"get",value:function(t){return t?this.table[t]:this.table}},{key:"set",value:function(t,e){this.table[t]=e}},{key:"remove",value:function(t){t?delete this.table[t]:this.table={}}},{key:"has",value:function(t){return!!this.table[t]}}]),t}();function Ne(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function Me(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?Ne(Object(i),!0).forEach((function(e){X(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Ne(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var Le,Ue,Oe={},De={},Pe=function(t){return a(t)?t:"".concat(t,"px")},je=function(t){return t.replace("%","")/100},Re=function(){},Be={name:"LemonImui",provide:function(){return{IMUI:this}},props:{width:{type:[String,Number],default:850},height:{type:[String,Number],default:580},theme:{type:String,default:"default"},simple:{type:Boolean,default:!1},loadingText:[String,Function],loadendText:[String,Function],messageTimeFormat:Function,contactTimeFormat:Function,hideDrawer:{type:Boolean,default:!0},hideMenuAvatar:Boolean,hideMenu:Boolean,hideMessageName:Boolean,hideMessageTime:Boolean,sendKey:Function,wrapKey:Function,sendText:String,contextmenu:Array,contactContextmenu:Array,avatarCricle:Boolean,user:{type:Object,default:function(){return{}}},latelyContacts:{type:Function,default:function(t){var e=t.filter((function(t){return!o(t.lastContent)}));return e.sort((function(t,e){return e.lastSendTime-t.lastSendTime})),e}}},data:function(){return this.CacheContactContainer=new Te,this.CacheMenuContainer=new Te,this.CacheMessageLoaded=new Te,this.CacheDraft=new Te,{drawerVisible:!this.hideDrawer,currentContactId:null,currentContactIdSidebarContact:null,currentMessages:[],activeSidebar:we,contacts:[],menus:[],editorTools:[{name:"emoji"},{name:"uploadFile"},{name:"uploadImage"}]}},render:function(){return this._renderWrapper([this._renderMenu(),this._renderSidebarMessage(),this._renderSidebarContact(),this._renderContainer(),this._renderDrawer()])},created:function(){this.initMenus()},mounted:function(){var t=d(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,this.$nextTick();case 2:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}(),computed:{currentContact:function(){var t=this;return this.contacts.find((function(e){return e.id==t.currentContactId}))||{}},currentContactSidebarContact:function(){var t=this;return this.contacts.find((function(e){return e.id==t.currentContactIdSidebarContact}))||{}},currentMenu:function(){var t=this;return this.menus.find((function(e){return e.name==t.activeSidebar}))||{}},currentIsDefSidebar:function(){return Ie.includes(this.activeSidebar)},lastMessages:function(){return this.latelyContacts(this.contacts)}},watch:{activeSidebar:function(){}},methods:{_menuIsContacts:function(){return this.activeSidebar==ke},_menuIsMessages:function(){return this.activeSidebar==we},_createMessage:function(t){return Me(Me({},{id:ot(),type:"text",status:"going",sendTime:(new Date).getTime(),toContactId:this.currentContactId,fromUser:Me({},this.user)}),t)},appendMessage:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i="+1",s=Oe[t.toContactId];if("event"!=t.type&&this.user.id!=t.fromUser.id||(i="+0"),void 0===s)this.updateContact({id:t.toContactId,unread:i,lastSendTime:t.sendTime,lastContent:this.lastContentRender(t)});else{var n=s.some((function(e){var i=e.id;return i==t.id}));if(n)return;this._addMessage(t,t.toContactId,1);var a={id:t.toContactId,lastContent:this.lastContentRender(t),lastSendTime:t.sendTime};t.toContactId==this.currentContactId?(1==e&&this.messageViewToBottom(),this.CacheDraft.remove(t.toContactId)):a.unread=i,this.updateContact(a)}},_emitSend:function(t,e,i){var s=this;this.$emit("send",t,(function(){var i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{status:"succeed"};e(),s.updateMessage(Object.assign(t,i))}),i)},_handleSend:function(t){var e=this,i=this.$refs.editor.chatArea.getCallUserList(),s=i.map((function(t){return t.id})),n=this._createMessage({content:t,at:s});this.appendMessage(n,!0),this._emitSend(n,(function(){e.updateContact({id:n.toContactId,lastContent:e.lastContentRender(n),lastSendTime:n.sendTime}),e.CacheDraft.remove(n.toContactId)}))},_handleUpload:function(t){var e,i=this,s=["image/gif","image/jpeg","image/png"];e=s.includes(t.type)?{type:"image",content:URL.createObjectURL(t)}:{type:"file",fileSize:t.size,fileName:t.name,content:""};var n=this._createMessage(e);this.appendMessage(n,!0),this._emitSend(n,(function(){i.updateContact({id:n.toContactId,lastContent:i.lastContentRender(n),lastSendTime:n.sendTime})}),t)},_emitPullMessages:function(t){var e=this;this._changeContactLock=!0,this.$emit("pull-messages",this.currentContact,(function(){var i=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],s=arguments.length>1&&void 0!==arguments[1]&&arguments[1];e._addMessage(i,e.currentContactId,0),e.CacheMessageLoaded.set(e.currentContactId,s),1==s&&e.$refs.messages.loaded(),e.updateCurrentMessages(),e._changeContactLock=!1,t(s)}),this)},callIsBottom:function(t){this.$emit("is-bottom",t)},clearCacheContainer:function(t){this.CacheContactContainer.remove(t),this.CacheMenuContainer.remove(t)},_renderWrapper:function(t){var e=this.$createElement;return e("div",{style:{width:Pe(this.width),height:Pe(this.height)},ref:"wrapper",class:["lemon-wrapper","lemon-wrapper--theme-".concat(this.theme),{"lemon-wrapper--simple":this.simple},this.drawerVisible&&"lemon-wrapper--drawer-show"]},[t])},_renderMenu:function(){var t=this,e=this.$createElement,i=this._renderMenuItem();return e("div",{class:"lemon-menu",directives:[{name:"show",value:!this.hideMenu}]},[e("lemon-avatar",{directives:[{name:"show",value:!this.hideMenuAvatar}],on:{click:function(e){t.$emit("menu-avatar-click",e)}},class:"lemon-menu__avatar",attrs:{src:this.user.avatar}}),i.top,this.$slots.menu,e("div",{class:"lemon-menu__bottom"},[this.$slots["menu-bottom"],i.bottom])])},_renderMenuAvatar:function(){},_renderMenuItem:function(){var t=this,e=this.$createElement,i=[],s=[];return this.menus.forEach((function(n){var a=n.name,r=n.title,o=n.unread,c=n.render,l=n.click,d=e("div",{class:["lemon-menu__item",{"lemon-menu__item--active":t.activeSidebar==a}],on:{click:function(){nt(l,(function(){a&&t.changeMenu(a)}))}},attrs:{title:r}},[e("lemon-badge",{attrs:{count:o}},[c(n)])]);!0===n.isBottom?s.push(d):i.push(d)})),{top:i,bottom:s}},_renderSidebarMessage:function(){var t=this;return this._renderSidebar([tt(this.$scopedSlots["sidebar-message-top"],null,this),this.lastMessages.map((function(e){return t._renderContact({contact:e,timeFormat:t.contactTimeFormat},(function(){return t.changeContact(e.id)}),t.$scopedSlots["sidebar-message"])}))],we,tt(this.$scopedSlots["sidebar-message-fixedtop"],null,this))},_renderContact:function(t,e,i){var s=this,n=this.$createElement,a=t.contact,r=a.click,o=a.renderContainer,c=a.id,l=function(){nt(r,(function(){e(),s._customContainerReady(o,s.CacheContactContainer,c)}))};return n("lemon-contact",J()([{class:{"lemon-contact--active":this.activeSidebar==ke?this.currentContactIdSidebarContact==t.contact.id:this.currentContactId==t.contact.id},directives:[{name:"lemon-contextmenu",value:this.contactContextmenu,modifiers:{contact:!0}}]},{props:t},{on:{click:l},scopedSlots:{default:i}}]))},_renderSidebarContact:function(){var t,e=this,i=this.$createElement;return this._renderSidebar([tt(this.$scopedSlots["sidebar-contact-top"],null,this),this.contacts.map((function(s){if(s.index){s.index=s.index.replace(/\[[0-9]*\]/,"");var n=[s.index!==t&&i("p",{class:"lemon-sidebar__label"},[s.index]),e._renderContact({contact:s,simple:!0},(function(){e.changeContact(s.id)}),e.$scopedSlots["sidebar-contact"])];return t=s.index,n}}))],ke,tt(this.$scopedSlots["sidebar-contact-fixedtop"],null,this))},_renderSidebar:function(t,e,i){var s=this.$createElement;return s("div",{class:"lemon-sidebar",directives:[{name:"show",value:this.activeSidebar==e}],on:{scroll:this._handleSidebarScroll}},[s("div",{class:"lemon-sidebar__fixed-top"},[i]),s("div",{class:"lemon-sidebar__scroll"},[t])])},_renderDrawer:function(){var t=this.$createElement;return this._menuIsMessages()&&this.currentContactId?t("div",{class:"lemon-drawer",ref:"drawer"},[Re(this.currentContact),tt(this.$scopedSlots.drawer,"",this.currentContact)]):""},_isContactContainerCache:function(t){return t.startsWith("contact#")},_renderContainer:function(){var t=this,e=this.$createElement,i=[],s="lemon-container",n=this.activeSidebar==ke?this.currentContactSidebarContact:this.currentContact,a=!0;for(var r in this.CacheContactContainer.get()){var c=n.id==r&&this.currentIsDefSidebar;c&&(a=!c),i.push(e("div",{class:s,directives:[{name:"show",value:c}]},[this.CacheContactContainer.get(r)]))}for(var l in this.CacheMenuContainer.get())i.push(e("div",{class:s,directives:[{name:"show",value:this.activeSidebar==l&&!this.currentIsDefSidebar}]},[this.CacheMenuContainer.get(l)]));return i.push(e("div",{class:s,directives:[{name:"show",value:this._menuIsMessages()&&a&&n.id}]},[e("div",{class:"lemon-container__title"},[tt(this.$scopedSlots["message-title"],e("div",{class:"lemon-container__displayname"},[n.displayName]),n)]),e("div",{class:"lemon-vessel"},[e("div",{class:"lemon-vessel__left"},[e("lemon-messages",{ref:"messages",attrs:{"loading-text":this.loadingText,"loadend-text":this.loadendText,"hide-time":this.hideMessageTime,"hide-name":this.hideMessageName,"time-format":this.messageTimeFormat,"reverse-user-id":this.user.id,messages:this.currentMessages},on:{"reach-top":this._emitPullMessages,"is-bottom":this.callIsBottom}}),e("lemon-editor",{ref:"editor",attrs:{tools:this.editorTools,sendText:this.sendText,sendKey:this.sendKey,wrapKey:this.wrapKey},on:{send:this._handleSend,upload:this._handleUpload}})]),e("div",{class:"lemon-vessel__right"},[tt(this.$scopedSlots["message-side"],null,n)])])])),i.push(e("div",{class:s,directives:[{name:"show",value:!n.id&&this.currentIsDefSidebar}]},[this.$slots.cover])),i.push(e("div",{class:s,directives:[{name:"show",value:this._menuIsContacts()&&a&&n.id}]},[tt(this.$scopedSlots["contact-info"],e("div",{class:"lemon-contact-info"},[e("lemon-avatar",{attrs:{src:n.avatar,size:90}}),e("h4",[n.displayName]),e("lemon-button",{on:{click:function(){o(n.lastContent)&&t.updateContact({id:n.id,lastContent:" "}),t.changeContact(n.id,we)}}},["发送消息"])]),n)])),i},_handleSidebarScroll:function(){M.hide()},_addContact:function(t,e){var i={0:"unshift",1:"push"}[e];this.contacts[i](t)},_addMessage:function(t,e,i){var s,n={0:"unshift",1:"push"}[i];Array.isArray(t)||(t=[t]),Oe[e]=Oe[e]||[],(s=Oe[e])[n].apply(s,xe(t))},setLastContentRender:function(t,e){Ae[t]=e},lastContentRender:function(t){return c(Ae[t.type])?Ae[t.type].call(this,t):"[不支持的消息类型]"},emojiNameToImage:function(t){return t.replace(/\[!(\w+)\]/gi,(function(t,e){var i=e;return De[i]?'<img emoji-name="'.concat(e,'" src="').concat(De[i],'" />'):"[!".concat(e,"]")}))},emojiImageToName:function(t){return t.replace(/<img emoji-name=\"([^\"]*?)\" [^>]*>/gi,"[!$1]")},updateCurrentMessages:function(){Oe[this.currentContactId]||(Oe[this.currentContactId]=[]),this.currentMessages=Oe[this.currentContactId]},messageViewToBottom:function(){this.$refs.messages.scrollToBottom()},setDraft:function(t,e){if(o(t)||o(e))return!1;var i=this.findContact(t),s=i.lastContent;if(o(i))return!1;this.CacheDraft.has(t)&&(s=this.CacheDraft.get(t).lastContent),this.CacheDraft.set(t,{editorValue:e,lastContent:s}),this.updateContact({id:t,lastContent:'<span style="color:red;">[草稿]</span><span>'.concat(this.lastContentRender({type:"text",content:e}),"</span>")})},clearDraft:function(t){var e=this.CacheDraft.get(t);if(e){var i=this.findContact(t).lastContent;0===i.indexOf('<span style="color:red;">[草稿]</span>')&&this.updateContact({id:t,lastContent:e.lastContent}),this.CacheDraft.remove(t)}},changeContact:function(){var t=d(regeneratorRuntime.mark((function t(e,i){var s,n,a,r=this;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!i){t.next=4;break}this.changeMenu(i),t.next=6;break;case 4:if(!(this._changeContactLock||this.activeSidebar==we&&this.currentContactId==e||this.activeSidebar==ke&&this.currentContactIdSidebarContact==e)){t.next=6;break}return t.abrupt("return",!1);case 6:if(this.currentContactId&&(s=this.$refs.editor.chatArea.getHtml({needUserId:!0}),n=this.$refs.editor.chatArea.getText(),n?(this.setDraft(this.currentContactId,s),this.setEditorValue()):this.clearDraft(this.currentContactId)),this.activeSidebar==ke?this.currentContactIdSidebarContact=e:this.currentContactId=e,this.currentContactId){t.next=10;break}return t.abrupt("return",!1);case 10:if(this.$emit("change-contact",this.currentContact,this),!c(this.currentContact.renderContainer)&&this.activeSidebar!=ke){t.next=13;break}return t.abrupt("return");case 13:a=this.CacheDraft.get(e),a&&(this.$refs.editor.chatArea.reverseAnalysis(a.editorValue),this.$refs.editor._checkSubmitDisabled()),this.CacheMessageLoaded.has(e)?this.$refs.messages.loaded():this.$refs.messages.resetLoadState(),Oe[e]?setTimeout((function(){r.updateCurrentMessages(),r.messageViewToBottom()}),0):(this.updateCurrentMessages(),this._emitPullMessages((function(t){r.messageViewToBottom()})));case 17:case"end":return t.stop()}}),t,this)})));function e(e,i){return t.apply(this,arguments)}return e}(),removeMessage:function(t){var e=this.findMessage(t);if(!e)return!1;var i=Oe[e.toContactId].findIndex((function(e){var i=e.id;return i==t}));return Oe[e.toContactId].splice(i,1),!0},updateMessage:function(t){if(!t.id)return!1;var e=this.findMessage(t.id);return!!e&&(e=Object.assign(e,t,{toContactId:e.toContactId}),!0)},forceUpdateMessage:function(t){if(t){var e=this.$refs.messages.$refs.message;if(e){var i=e.find((function(e){return e.$attrs.message.id==t}));i&&i.$forceUpdate()}}else this.$refs.messages.$forceUpdate()},_customContainerReady:function(t,e,i){c(t)&&!e.has(i)&&e.set(i,t.call(this))},changeMenu:function(t){this.$emit("change-menu",t),this.activeSidebar=t},initEmoji:function(t){var e=[];this.$refs.editor.initEmoji(t),t[0].label?t.forEach((function(t){var i;(i=e).push.apply(i,xe(t.children))})):e=t,e.forEach((function(t){var e=t.name,i=t.src;return De[e]=i}))},initEditorTools:function(t){this.editorTools=t},initMenus:function(t){var e=this,i=this.$createElement,s=[{name:we,title:"聊天",unread:0,click:null,render:function(t){return i("i",{class:"lemon-icon-message"})},isBottom:!1},{name:ke,title:"通讯录",unread:0,click:null,render:function(t){return i("i",{class:"lemon-icon-addressbook"})},isBottom:!1}],n=[];if(Array.isArray(t)){var a={messages:0,contacts:1},r=Object.keys(a);n=t.map((function(t){return r.includes(t.name)?Me(Me(Me({},s[a[t.name]]),t),{renderContainer:null}):(t.renderContainer&&e._customContainerReady(t.renderContainer,e.CacheMenuContainer,t.name),t)}))}else n=s;this.menus=n},initContacts:function(t){this.contacts=t,this.sortContacts()},sortContacts:function(){this.contacts.sort((function(t,e){if(t.index)return t.index.localeCompare(e.index)}))},appendContact:function(t){return o(t.id)||o(t.displayName)?(console.error("id | displayName cant be empty"),!1):(this.hasContact(t.id)||this.contacts.push(Object.assign({id:"",displayName:"",avatar:"",index:"",unread:0,lastSendTime:"",lastContent:""},t)),!0)},removeContact:function(t){var e=this.findContactIndexById(t);return-1!==e&&(this.contacts.splice(e,1),this.CacheDraft.remove(t),this.CacheMessageLoaded.remove(t),!0)},updateContact:function(t){var e=t.id;delete t.id;var i=this.findContactIndexById(e);if(-1!==i){var s=t.unread;a(s)&&(0!==s.indexOf("+")&&0!==s.indexOf("-")||(t.unread=parseInt(s)+parseInt(this.contacts[i].unread))),this.$set(this.contacts,i,Me(Me({},this.contacts[i]),t))}},findContactIndexById:function(t){return this.contacts.findIndex((function(e){return e.id==t}))},hasContact:function(t){return-1!==this.findContactIndexById(t)},findMessage:function(t){for(var e in Oe){var i=Oe[e].find((function(e){var i=e.id;return i==t}));if(i)return i}},findContact:function(t){return this.getContacts().find((function(e){var i=e.id;return i==t}))},getContacts:function(){return this.contacts},getCurrentContact:function(){return this.currentContact},getCurrentMessages:function(){return this.currentMessages},setEditorValue:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";if(!a(t))return!1;this.$refs.editor.setValue(this.emojiNameToImage(t))},getEditorValue:function(){return this.$refs.editor.getFormatValue()},clearMessages:function(t){return t?(delete Oe[t],this.CacheMessageLoaded.remove(t),this.CacheDraft.remove(t)):(Oe={},this.CacheMessageLoaded.remove(),this.CacheDraft.remove()),!0},getMessages:function(t){return(t?Oe[t]:Oe)||[]},changeDrawer:function(t){this.drawerVisible=!this.drawerVisible,1==this.drawerVisible&&this.openDrawer(t)},openDrawer:function(t){Re=c(t)?t:t.render||new Function;var e=this.$refs.wrapper.clientWidth,i=this.$refs.wrapper.clientHeight,s=t.width||200,n=t.height||i,r=t.offsetX||0,o=t.offsetY||0,l=t.position||"right";a(s)&&(s=e*je(s)),a(n)&&(n=i*je(n)),a(r)&&(r=e*je(r)),a(o)&&(o=i*je(o)),this.$refs.drawer.style.width="".concat(s,"px"),this.$refs.drawer.style.height="".concat(n,"px");var d=0,u=0,h="";"right"==l?d=e:"rightInside"==l?(d=e-s,h="-15px 0 16px -14px rgba(0,0,0,0.08)"):"center"==l&&(d=e/2-s/2,u=i/2-n/2,h="0 0 20px rgba(0,0,0,0.08)"),d+=r,u+=o+-1,this.$refs.drawer.style.top="".concat(u,"px"),this.$refs.drawer.style.left="".concat(d,"px"),this.$refs.drawer.style.boxShadow=h,this.drawerVisible=!0},closeDrawer:function(){this.drawerVisible=!1},setAtUserList:function(t,e){this.$refs.editor.chatArea.updateConfig({userList:t,needCallEvery:e})},setUserTag:function(t){this.$refs.editor.chatArea.setUserTag(t),this.$refs.editor._checkSubmitDisabled()}}},Fe=Be,$e=(i("b25a"),v(Fe,Le,Ue,!1,null,null,null)),He=$e.exports,Ve=(i("6a2b"),"1.4.2"),Ge=[He,pt,Dt,Mt,Q,V,B,C,D,Bt,Qt,ee,ue,ge],Ke=function(t){t.directive("LemonContextmenu",M),Ge.forEach((function(e){t.component(e.name,e)}))};"undefined"!==typeof window&&window.Vue&&Ke(window.Vue);var ze={version:Ve,install:Ke};e["default"]=ze},fdef:function(t,e){t.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"}})}))},8138:function(t,e,i){"use strict";var s=i(3032),n=function(){var t=this,e=t._self._c;return e("div",{attrs:{id:"app"}},[e("router-view")],1)},a=[],r=(i(7658),i(4462)),o=i.n(r),c={name:"App",data(){return{msg:"Welcome to Your Vue.js App"}},created(){let t=o().get("UserInfo"),e=o().get("globalConfig");e&&(document.title=e.sysInfo.name,this.$store.commit("setGlobalConfig",e)),t&&this.$store.commit("SET_USERINFO",t),this.$store.dispatch("getSystemInfo").then((t=>{0!=t.data.sysInfo.state||this.$router.push({path:"/404",query:{msg:t.data.sysInfo.closeTips}})}))},watch:{"$store.state.globalConfig"(t){document.title=t.sysInfo.name}}},l=c,d=i(1001),u=(0,d.Z)(l,n,a,!1,null,null,null),h=u.exports,p=i(8499),m=i.n(p),g=function(){var t=this,e=t._self._c;return e("div",{staticClass:"user-card-box"},[e("el-container",{directives:[{name:"outside",rawName:"v-outside",value:t.closeDialog,expression:"closeDialog"}],staticClass:"container"},[e("el-header",{staticClass:"no-padding header",attrs:{height:"180px"}},[e("i",{staticClass:"close el-icon-error cur-handle",on:{click:t.closeDialog}}),e("div",{staticClass:"img-banner"}),e("div",{staticClass:"user-header"},[e("div",{staticClass:"avatar"},[e("div",{staticClass:"avatar-box"},[e("img",{attrs:{src:t.detail.avatar}})])]),e("div",{staticClass:"username"},[e("i",{staticClass:"iconfont icon-qianming"}),e("span",[t._v(t._s(t.detail.realname||"未设置昵称"))])])])]),e("el-main",{staticClass:"no-padding main"},[e("div",{staticClass:"user-sign"},[e("div",{staticClass:"sign-arrow"}),e("i",{staticClass:"iconfont icon-bianji"}),e("span",[t._v(t._s(t.detail.motto||"这家伙有点懒,什么都没留下!")+" ")])]),e("div",{staticClass:"card-rows no-select"},[e("div",{staticClass:"card-row"},[e("div",{staticClass:"label"},[t._v("账号")]),e("div",[t._v(t._s(t.detail.account))])]),e("div",{staticClass:"card-row"},[e("div",{staticClass:"label"},[t._v(t._s(2==t.globalConfig.sysInfo.runMode?"昵称":"姓名"))]),e("div",[t._v(t._s(t.detail.realname))])]),t.detail.friend&&2==t.globalConfig.sysInfo.runMode?e("div",{staticClass:"card-row"},[e("div",{staticClass:"label"},[t._v("备注")]),e("div",[t._v(t._s(t.detail.friend.nickname||"未设置")+" "),e("i",{staticClass:"el-icon-edit ml-10",attrs:{title:"设置备注"},on:{click:t.setNickname}})])]):t._e(),e("div",{staticClass:"card-row"},[e("div",{staticClass:"label"},[t._v("性别")]),e("div",[t._v(t._s(t._f("sex")(t.detail.sex)))])]),e("div",{staticClass:"card-row"},[e("div",{staticClass:"label"},[t._v("邮箱")]),e("div",[t._v(t._s(t.detail.email||"未设置"))])]),parseInt(t.globalConfig.sysInfo.ipregion)&&t.isFriend?e("div",{staticClass:"card-row"},[e("div",{staticClass:"label"},[t._v("IP")]),t.detail.last_login_ip?e("div",[t._v(t._s(t.detail.last_login_ip||"未知")+" ("+t._s(t.detail.location||"未知")+")")]):e("div",[t._v("未知")])]):t._e()])]),e("el-footer",{staticClass:"footer"},[t.isFriend?e("el-button",{staticStyle:{width:"150px"},attrs:{type:"primary",round:""},on:{click:function(e){return t.openChat()}}},[t._v("发消息")]):t._e(),2!=t.globalConfig.sysInfo.runMode||t.detail.friend||t.user_id==t.userInfo.user_id?t._e():e("el-button",{staticStyle:{width:"150px"},attrs:{type:"primary",round:""},on:{click:function(e){return t.addFriend()}}},[t._v("加好友")]),t.options.isManage?e("el-button",{staticStyle:{width:"150px"},attrs:{round:""},on:{click:t.editUser}},[t._v("编辑资料")]):t._e()],1)],1)],1)},f=[],v=i(3822),b={name:"UserCard",props:{user_id:{type:[Number,String],default:0},options:{type:Object,default:()=>({isManage:!1})}},computed:{...(0,v.rn)({userInfo:t=>t.userInfo,globalConfig:t=>t.globalConfig}),isFriend(){return this.userInfo.user_id!=this.detail.user_id&&(this.detail.friend||1==this.globalConfig.sysInfo.runMode)}},filters:{sex(t){let e=["女","男","未知"];return e[t]||"未知"}},data(){return{detail:{}}},mounted(){this.getUserDetal()},methods:{closeDialog(){this.$emit("close")},getUserDetal(){this.$api.imApi.getUserInfo({user_id:this.user_id}).then((t=>{0==t.code&&(this.detail=t.data)}))},openChat(){this.closeDialog(),this.$store.commit("openChat",this.detail.user_id)},editUser(){this.$emit("editUser",this.detail)},addFriend(){this.closeDialog(),this.$prompt("请填写验证信息,让朋友知道你!","添加好友",{confirmButtonText:"确定",cancelButtonText:"取消"}).then((({value:t})=>{if(!t)return this.$message.error("请输入验证信息"),!1;this.$api.friendApi.addFriend({user_id:this.detail.user_id,remark:t}).then((t=>{0==t.code&&this.$message.success("已发送好友申请")}))})).catch((t=>{this.$message({type:"warning",message:t})}))},setNickname(){let t=this.detail.friend.friend_id??"";if(!this.detail.friend)return this.$message.error("该用户不是您的好友"),!1;this.closeDialog();let e=this.detail.friend.nickname?this.detail.friend.nickname:this.detail.realname;this.$prompt("请填写备注信息","设置备注",{confirmButtonText:"确定",cancelButtonText:"取消",inputValue:e}).then((({value:e})=>{if(!e)return this.$message.error("请输入备注信息"),!1;this.$api.friendApi.setNickname({friend_id:t,nickname:e}).then((t=>{0==t.code&&(this.$message.success("设置成功"),this.detail.realname=e)}))})).catch((()=>{}))}}},y=b,C=(0,d.Z)(y,g,f,!1,null,"499318c8",null),x=C.exports,w={install(t){function e(e,i){let s=this;const n=new t({router:s.$router,store:s.$store,render(t){return t(x,{on:{close:()=>{n.$destroy(),document.body.removeChild(n.$el)},editUser:t=>{i.editDataCallbak&&i.editDataCallbak(t),n.$destroy(),document.body.removeChild(n.$el)}},props:{user_id:e,options:i}})}}).$mount();document.body.appendChild(n.$el)}t.prototype.$user=e}},k=function(){var t=this,e=t._self._c;return e("div",[e("transition",{attrs:{name:"fade-user"}},[e("div",{staticClass:"previewBox"},[e("el-button",{staticClass:"drawer-close",attrs:{type:"danger",icon:"el-icon-close",circle:""},on:{click:t.closeDrawer}}),e("iframe",{attrs:{src:t.url,frameborder:"0",width:"100%",height:"100%"}})],1)])],1)},I=[],A={name:"preview",props:{url:{type:String,default:""}},data(){return{}},methods:{closeDrawer(){this.$emit("close")}}},_=A,E=(0,d.Z)(_,k,I,!1,null,"022a2c23",null),S=E.exports,T={install(t){function e(e,i){let s=this;const n=new t({router:s.$router,store:s.$store,render(t){return t(S,{on:{close:()=>{n.$destroy(),document.body.removeChild(n.$el)}},props:{url:e,options:i}})}}).$mount();document.body.appendChild(n.$el)}t.prototype.$preview=e}},N=i(8824),M=i.n(N),L=i(2631),U=function(){var t=this,e=t._self._c;return e("div",{staticClass:"main-container"},[e("div",{staticClass:"im-title"},[e("div",{staticClass:"logo"},[e("el-image",{staticStyle:{width:"80px",height:"80px"},attrs:{src:t.$packageData.logo,fit:"cover"}})],1),e("div",{staticClass:"im-content"},[e("div",{staticClass:"im-name"},[e("div",{staticClass:"text f-36"},[t._v(t._s(t.$packageData.name))]),e("div",{staticClass:"version ml-5"},[e("el-tag",{attrs:{size:"mini",type:"primary",effect:"plain"}},[t._v("v"+t._s(t.$packageData.version))])],1)]),e("div",{staticClass:"im-des"},[t._v(t._s(t.$packageData.description))])])]),e("div",{staticClass:"code-url"},[e("div",{staticClass:"ml-15 mb-15"},[t._v(" 前端地址: "),e("a",{attrs:{href:t.$packageData.frontUrl,target:"_blank"}},[e("el-image",{attrs:{src:t.$packageData.frontUrl+"/badge/star.svg?theme=white",alt:"star"}})],1)]),e("div",{staticClass:"ml-15 mb-15"},[t._v(" 后端地址:"),e("a",{attrs:{href:t.$packageData.backstageUrl,target:"_blank"}},[e("el-image",{attrs:{src:t.$packageData.backstageUrl+"/badge/star.svg?theme=dark",alt:"star"}})],1)]),e("div",{staticClass:"ml-15 mb-15"},[e("el-button",{attrs:{type:"warning",plain:"",size:"mini",round:""}},[e("a",{attrs:{href:t.$packageData.qqGroupUrl,target:"_blank"}},[t._v("QQ交流群:336921267")])])],1)]),e("el-alert",{staticClass:"mt-15 mb-15",attrs:{"show-icon":"",closable:!1,title:"本项目为演示系统,请仔细阅读一下文档!进群请先Star项目。本项目是一款开源的即时通信demo(存在一定的BUG),主要用于学习交流,为大家提供即时通讯的开发思路。",type:"info"}}),e("el-alert",{staticClass:"mt-15 mb-15",attrs:{"show-icon":"",closable:!1,title:"该项目服务端和web端都属于全开源项目,仅用于个人学习,任何个人和单位不得对源码进行售卖;捐赠后获得的移动端源码也仅供学习使用,不可对源码进行二次售卖。",type:"warning"}}),e("el-alert",{staticClass:"mt-15 mb-15",attrs:{"show-icon":"",closable:!1,title:"免责声明:请勿将源码用于木马、病毒、色情、赌博、诈骗等违反国家法律法规行业,如有发现我会协助相关行政执法机关清查!",type:"error"}}),e("el-tabs",{staticClass:"mb-20",attrs:{type:"card"},on:{"tab-click":t.handleClick},model:{value:t.activeName,callback:function(e){t.activeName=e},expression:"activeName"}},[e("el-tab-pane",{attrs:{label:"📘 程序介绍"}},[e("div",{staticClass:"tip"},t._l(t.introduce,(function(i,s){return e("p",{key:s,staticClass:"mb-5"},[e("i",{class:i.icon}),t._v(" "),e("span",{domProps:{innerHTML:t._s(i.text)}})])})),0)]),e("el-tab-pane",{attrs:{label:"🪄 支持功能"}},[e("div",{staticClass:"success"},t._l(t.$packageData.funcList,(function(i,s){return e("p",{key:s,staticClass:"mb-5"},[e("i",{class:i.icon}),t._v(" "),e("span",{domProps:{innerHTML:t._s(i.text)}})])})),0)]),e("el-tab-pane",{attrs:{label:"🛒 技术栈"}},[e("div",{staticClass:"info"},t._l(t.techStack,(function(i,s){return e("p",{key:s,staticClass:"mb-5"},[e("i",{class:i.icon}),t._v(" "),e("span",{domProps:{innerHTML:t._s(i.text)}})])})),0)])],1),t._m(0),e("div",{staticClass:"demo-btn"},[e("div",{staticClass:"flex-box-center mb-15",on:{click:function(e){return t.showMessageBox()}}},[e("el-badge",{staticClass:"item",attrs:{value:t.unread,max:99,hidden:!t.unread}},[e("el-button",[t._v("窗口模式")])],1)],1),e("div",{staticClass:"mb-15 mr-15",on:{click:function(e){return t.$router.push({path:"/chat"})}}},[e("el-button",[t._v("纯享模式")])],1),e("div",{staticClass:"mb-15 mr-15",on:{click:function(e){return t.$router.push({path:"/manage/index"})}}},[e("el-button",[t._v("管理后台")])],1),e("div",{staticClass:"mb-15 mr-15"},[e("el-tooltip",{attrs:{placement:"right-start",effect:"light"}},[e("div",{attrs:{slot:"content"},slot:"content"},[e("el-image",{staticStyle:{width:"200px"},attrs:{src:"/assets/img/h5.png"}})],1),e("el-button",[e("a",{attrs:{href:t.$packageData.mobileUrl,target:"_blank"}},[t._v("H5体验")])])],1)],1),e("div",{staticClass:"mb-15"},[e("el-button",{on:{click:t.downApp}},[e("a",{attrs:{target:"_blank"}},[t._v("客户端下载")])])],1)]),e("div",{staticClass:"contact-main"},[t._m(1),t._l(t.allContacts,(function(i){return 0==i.is_group&&i.id<6?e("div",{key:i.id,staticClass:"contact-box"},[e("div",{staticClass:"contact-item"},[e("el-avatar",{attrs:{src:i.avatar}}),e("span",[t._v(t._s(i.realname))]),e("div",[e("el-button",{attrs:{plain:"",size:"mini",round:""},on:{click:function(e){return t.$store.commit("openChat",i.id)}}},[t._v("发消息")])],1)],1)]):t._e()}))],2),e("div",{staticClass:"tip mb-20 mt-10"},[t._m(2),t._m(3),e("p",[t._v("1. 服务端协助部署:仅提供服务端远程 [todesk] 技术指导,需要提供纯净的centOS服务器一台。")]),t._m(4),e("p",[t._v("3. 桌面端源码【付费获取】:使用vue+electron前端技术打包,和web端功能一样,支持后台运行和消息通知。")]),e("p",[t._v("4. webRTC中继服务器:原则上参考底部的教程链接来自行安装,确需服务,也可联系作者协助。")]),e("p",[t._v("5. 技术指导服务:包含远程指导,代码解析,开发思路等,付费之日起一个月内有效。")]),e("p",[t._v("6. 团队安心包:包含上述前4项服务,根据需求选择,以及安卓APP和H5打包(需要提供Dcloud账号【打包】、服务器、域名、证书等,APP还需要提供应用名称和图标)")]),e("p",[t._v("7、其他未列出的服务,请进群咨询作者!作者8年phper,前端水平一般,不接外包和二开!当然除非你要的东西非常简单。")]),e("el-link",{staticClass:"mt-10 mb-10",attrs:{type:"primary",href:t.$packageData.qqGroupUrl,target:"_blank"}},[t._v("有技术问题需要交流或者购买移动端的可以【戳我】加入交流群。"),e("b",{staticClass:"c-red"},[t._v("加群前请先点star,否则不予通过,长时间不活跃的将被定期清理")])])],1),t._m(5),e("div",{staticClass:"other-pro"},[e("h2",[t._v("其他项目")]),e("br"),e("div",{staticClass:"mb-15"},[e("el-link",{attrs:{type:"primary",href:"https://gitee.com/raingad/j-preview"}},[t._v("纯JS文件预览插件")])],1)]),e("div",{staticClass:"other-pro"},[e("h2",[t._v("其他资料")]),e("br"),e("div",{staticClass:"mb-15"},[e("el-link",{attrs:{type:"primary",href:"https://lemon.raingad.com"}},[t._v("Lemon-IMUI使用文档")])],1),e("div",{staticClass:"mb-15"},[e("el-link",{attrs:{type:"primary",href:"https://www.npmjs.com/package/chatarea"}},[t._v("聊天输入框插件【chatarea】")])],1),e("div",{staticClass:"mb-15"},[e("el-link",{attrs:{type:"primary",href:"https://blog.csdn.net/ruiye99/article/details/130992960"}},[t._v("WebRTC 网络中继 Coturn 服务安装及部署")])],1)]),e("Message",{ref:"Message",attrs:{dialogTableVisible:t.dialogTableVisible},on:{"update:dialogTableVisible":function(e){t.dialogTableVisible=e},"update:dialog-table-visible":function(e){t.dialogTableVisible=e}}})],1)},O=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"mb-15"},[e("b",{staticStyle:{"font-size":"20px"}},[t._v("功能演示")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"title"},[e("b",{staticStyle:{"font-size":"20px"}},[t._v("联系人")]),t._v("(仅展示部分用于演示)")])},function(){var t=this,e=t._self._c;return e("h3",{staticClass:"mb-5"},[e("b",[t._v("服务介绍")])])},function(){var t=this,e=t._self._c;return e("p",[t._v(" 详细的使用方法在源码中基本上都有备注,如果您觉得这个项目对您有帮助,欢迎star,如果有问题可以加QQ群交流,如果您有更好的建议,欢迎提出。"),e("b",[t._v(" 开源不易,如果需要以下功能,捐赠相应金额,作者可提供服务,进群后咨询作者!")])])},function(){var t=this,e=t._self._c;return e("p",[t._v("2. uniapp移动端源码【付费获取】(源码无加密,仅提供源码,"),e("b",[t._v("不提供专业指导和部署 ")]),t._v(")")])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"danger mb-20"},[e("h3",{staticClass:"mb-5"},[e("b",[t._v("注意事项")])]),e("p",{staticClass:"m-5"},[t._v(" 1、捐赠购买移动端或者桌面端赠送文档,包含:接口说明、安装教程、常见问题的解决方法等。"),e("br"),t._v(" 2、源码作者不保证无任何问题,可能存在兼容性问题或者一些小的BUG,需要自行优化升级,望悉知。"),e("br"),t._v(" 3、捐赠获得的源码仅供学习或二次开发使用,不可对源码进行二次售卖。"),e("br"),t._v(" 4、价格或服务内容可能会有变动,"),e("b",{staticClass:"c-red"},[t._v("随着功能的增加,价格会上涨")]),t._v(",以咨询作者时给的服务方案为准! ")])])}],D=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"show",rawName:"v-show",value:t.dialogTableVisible,expression:"dialogTableVisible"}],staticClass:"messageBoxStyle"},[e("el-dialog",{attrs:{visible:t.dialogIsShow,modal:!1,"custom-class":"sideMenu-message","show-close":!1,width:"1000px","close-on-press-escape":!0},on:{"update:visible":function(e){t.dialogIsShow=e},close:t.closeDialog}},[e("rainagdIm",{on:{newChat:t.contactSync,close:t.closeDialog}})],1)],1)},P=[],j=function(){var t=this,e=t._self._c;return e("div",[e("div",{staticClass:"chat-box"},[e("lemon-imui",{ref:"IMUI",staticStyle:{"min-height":"600px"},attrs:{user:t.user,width:t.curWidth,height:t.curHeight,contextmenu:t.contextmenu,"contact-contextmenu":t.contactContextmenu,theme:t.setting.theme,"hide-message-name":t.setting.hideMessageName,"hide-message-time":t.setting.hideMessageTime,avatarCricle:t.setting.avatarCricle,sendKey:t.setSendKey,wrapKey:t.wrapKey,latelyContacts:t.latelyContact},on:{"is-bottom":t.eventBottom,"menu-avatar-click":t.openSetting,"change-contact":t.handleChangeContact,"pull-messages":t.handlePullMessages,"message-click":t.handleMessageClick,send:t.handleSend},scopedSlots:t._u([{key:"cover",fn:function(){return[e("div",[e("div",{staticClass:"cover"},[e("i",{staticClass:"lemon-icon-message"}),e("p",[e("b",[t._v(t._s(t.globalConfig.sysInfo.name??""))])])])])]},proxy:!0},{key:"sidebar-message",fn:function(i){return[e("div",{staticClass:"lemon-contact-item",class:1==i.is_top?"bg-gray":""},[e("el-badge",{staticClass:"lemon-badge lemon-contact__avatar",attrs:{value:i.unread,max:99,"is-dot":0==i.is_notice,hidden:i.unread<=0}},[e("span",{staticClass:"lemon-avatar",class:{"lemon-avatar--circle":t.setting.avatarCricle},staticStyle:{width:"40px",height:"40px","line-height":"40px","font-size":"20px"}},[e("img",{attrs:{src:i.avatar}})]),i.is_online&&0==i.is_group&&1==t.globalConfig.chatInfo.online?e("span",{staticClass:"online-status",attrs:{title:"在线"}}):t._e()]),e("div",{staticClass:"lemon-contact__inner"},[e("p",{staticClass:"lemon-contact__label"},[e("span",{staticClass:"lemon-contact__name"},[t._v(" "+t._s(i.displayName)+" ")]),e("span",{staticClass:"lemon-contact__time",domProps:{textContent:t._s(t.formatTime(i.lastSendTime))}})]),e("p",{staticClass:"lemon-contact__content lemon-last-content"},[e("span",{staticClass:"lastContent"},[i.is_at>0?e("span",{staticClass:"c-red"},[t._v("[有"+t._s(i.is_at)+"人@我] ")]):t._e(),e("span",{domProps:{innerHTML:t._s(i.lastContent)}})]),0==i.is_notice?e("span",{staticClass:"el-icon-close-notification f-16"}):t._e()])])],1)]}},{key:"message-title",fn:function(i){return[e("div",{staticClass:"message-title-box"},[e("div",[0==t.isEdit?e("span",[1==t.is_group?e("span",{staticClass:"displayName",on:{click:function(e){t.isEdit=!0}}},[t._v(" "+t._s(i.displayName)),e("span",{staticClass:"mr-5"},[t._v("("+t._s(t.groupUserCount)+")")]),i.setting&&1==i.setting.nospeak?e("el-tag",{attrs:{size:"mini",type:"warning"}},[t._v("仅群管理员可发言")]):t._e(),i.setting&&2==i.setting.nospeak?e("el-tag",{attrs:{size:"mini",type:"danger"}},[t._v("全员禁言中")]):t._e()],1):t._e(),t.is_group>1?e("span",{staticClass:"displayName"},[2==t.is_group?e("el-tag",{attrs:{size:"mini"}},[t._v("BOT")]):t._e(),t._v(" "+t._s(i.displayName)+" ")],1):t._e(),0==t.is_group?e("span",{staticClass:"displayName"},[t.globalConfig.chatInfo.online?e("OnlineStatus",{attrs:{type:i.is_online?"success":"info",pulse:i.is_online}}):t._e(),t._v(" "+t._s(i.displayName))],1):t._e(),parseInt(t.globalConfig.sysInfo.ipregion)&&i.last_login_ip?e("span",{staticClass:"c-999 f-12 ml-5"},[t.globalConfig.chatInfo.online&&!i.is_online?e("span",[t._v("(离线)")]):t._e(),t._v(t._s(i.last_login_ip)+" "+t._s(i.location))]):t._e()]):t._e(),1==t.isEdit?e("input",{directives:[{name:"model",rawName:"v-model",value:t.displayName,expression:"displayName"}],staticClass:"editInput",domProps:{value:t.displayName},on:{blur:function(e){return t.saveGroupName(i)},input:function(e){e.target.composing||(t.displayName=e.target.value)}}}):t._e()]),e("div",{staticClass:"message-title-tools"},[t.globalConfig.chatInfo.webrtc?[!i.is_group&&parseInt(t.globalConfig.chatInfo.webrtc)?e("i",{staticClass:"el-icon-phone-outline ml-10",attrs:{title:"语音通话"},on:{click:function(e){return t.called(0)}}}):t._e(),!i.is_group&&parseInt(t.globalConfig.chatInfo.webrtc)?e("i",{staticClass:"el-icon-video-camera ml-10",attrs:{title:"视频通话"},on:{click:function(e){return t.called(1)}}}):t._e()]:t._e(),1==i.is_group?e("i",{staticClass:"iconfont icon-ico ml-10 f-22",attrs:{title:"群二维码"},on:{click:function(e){t.groupQrShow=!0}}}):t._e(),i.is_group?t._e():e("i",{staticClass:"el-icon-more ml-10",attrs:{title:"基本资料"},on:{click:function(e){return t.$user(i.id)}}}),i.is_group&&1==t.currentChat.role?e("i",{staticClass:"el-icon-more ml-10",attrs:{title:"群管理"},on:{click:function(e){return t.openGroupSetting(!1)}}}):t._e()],2)])]}},{key:"sidebar-message-fixedtop",fn:function(i){return[t.wsStatus?t._e():e("div",{staticClass:"lz-flex no-internet pd-10 mb-10 lz-space-between lz-align-items-center"},[e("div",{staticClass:"el-icon-info"}),e("div",[t._v("当前网络无法实时接收消息")]),e("div",{staticClass:"el-icon-refresh cur-handle",attrs:{title:"重新链接"},on:{click:t.reconnect}})]),e("div",{staticClass:"contact-fixedtop-box"},[e("el-input",{staticClass:"input-with-select",attrs:{placeholder:"搜索联系人","prefix-icon":"el-icon-search"},on:{blur:t.closeSearch,focus:function(e){t.searchResult=!0}},model:{value:t.keywords,callback:function(e){t.keywords=e},expression:"keywords"}}),2==t.globalConfig.sysInfo.runMode?e("div",{staticStyle:{"margin-left":"10px"}},[e("el-dropdown",{on:{command:t.handleCommand}},[e("el-button",{attrs:{icon:"el-icon-plus",circle:""}}),e("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},[e("el-dropdown-item",{attrs:{command:"addFriend"}},[t._v("添加朋友")]),t.globalConfig.chatInfo.groupChat?e("el-dropdown-item",{attrs:{command:"addGroup"}},[t._v("创建群聊")]):t._e()],1)],1)],1):t._e(),1==t.globalConfig.sysInfo.runMode&&t.globalConfig.chatInfo.groupChat?e("div",{staticStyle:{"margin-left":"10px"}},[e("el-button",{attrs:{title:"创建群聊",icon:"el-icon-plus",circle:""},on:{click:t.openCreateGroup}})],1):t._e(),e("div",{directives:[{name:"show",rawName:"v-show",value:t.searchResult,expression:"searchResult"}],staticClass:"search-list"},[t._l(t.searchList,(function(s,n){return t.searchList.length>0?e("div",{key:n,staticClass:"search-list-item"},[e("lemon-contact",{attrs:{contact:s},on:{click:function(e){return t.openChat(s.id,i)}}})],1):t._e()})),0==t.searchList.length?e("div",{staticStyle:{margin:"20px"},attrs:{align:"center"}},[t._v(" 暂无 ")]):t._e()],2)],1),e("im-tab",{attrs:{values:t.tabList,height:40},on:{change:t.changeTab}})]}},{key:"sidebar-message-top",fn:function(i){return[t.chatTopList.length>0?e("div",{staticClass:"chat-top-list"},t._l(t.chatTopList,(function(s,n){return e("ChatTop",{key:n,attrs:{contact:s,avatarCricle:t.setting.avatarCricle,currentId:t.currentChat.id},nativeOn:{click:function(e){return t.openChat(s.id,i)}}})})),1):t._e()]}},{key:"sidebar-contact-fixedtop",fn:function(i){return[e("div",{staticStyle:{margin:"15px 10px"}},[t._v(" 联系人 ")])]}},{key:"message-side",fn:function(i){return[1==i.is_group?e("div",{staticClass:"slot-group-list lemon-wrapper",class:"blue"==t.setting.theme?"lemon-wrapper--theme-blue":""},[e("div",{staticClass:"group-side-box lemon-container"},[e("div",{staticClass:"group-notice"},[e("div",{staticClass:"group-side-title"},[e("h4",[t._v("群公告")]),e("div",[i.role<3||0==i.setting.manage?e("span",{staticClass:"el-icon-edit f-18 cur-handle",on:{click:function(e){t.noticeBox=!0}}}):t._e()])]),e("hr"),i.notice?e("div",{staticClass:"group-side-body",on:{click:t.openNotice}},[t._v(" "+t._s(i.notice)+" ")]):t._e(),i.notice?t._e():e("div",{staticClass:"group-side-body"},[t._v(" 暂无公告 ")])]),e("div",{staticClass:"group-user"},[e("div",{staticClass:"group-side-title"},[e("h4",[t._v("群成员")]),e("div",[i.role<3||1==i.setting.invite?e("span",{staticClass:"el-icon-circle-plus-outline f-18 cur-handle",on:{click:t.openAddGroupUser}}):t._e()])]),e("hr"),e("div",{staticClass:"group-user-body",style:[{height:"calc("+t.curHeight+" - 230px)",background:"blue"==t.setting.theme?"#ffffff":"#f4f4f4"}],attrs:{id:"group-user"}},[e("el-scrollbar",{staticStyle:{height:"100%"}},t._l(t.groupUser,(function(i,s){return e("lemon-contact",{directives:[{name:"lemon-contextmenu",rawName:"v-lemon-contextmenu.contact",value:t.groupMenu,expression:"groupMenu",modifiers:{contact:!0}}],key:s,staticClass:"user-list",attrs:{contact:i}},[e("div",{staticClass:"user-avatar"},[e("el-avatar",{attrs:{size:20,src:i.userInfo.avatar}})],1),e("div",{staticClass:"user-name"},[i.userInfo.id==t.user.id?e("span",{staticClass:"fc-danger"},[t._v(t._s(i.userInfo.displayName)+"(我)")]):t._e(),i.userInfo.id!=t.user.id?e("span",[t._v(t._s(i.userInfo.displayName))]):t._e(),e("el-tooltip",{staticClass:"item",attrs:{effect:"dark",content:"已禁言至:"+t.noSpeakExp(i.no_speak_time),placement:"top"}},[t.noSpeakExp(i.no_speak_time)?e("span",{staticClass:"c-red ml-5 el-icon el-icon-turn-off-microphone"}):t._e()])],1),e("div",{staticClass:"user-role"},[1==i.role?e("el-tag",{attrs:{type:"danger",size:"mini"}},[t._v("群主")]):t._e(),2==i.role?e("el-tag",{attrs:{type:"warning",size:"mini"}},[t._v("管理员")]):t._e()],1)])})),1)],1)])])]):t._e()]}},{key:"message-after",fn:function(i){return[i.fromUser.id==t.user.id&&0==i.is_group?e("span",{staticStyle:{visibility:"visible"}},[i.is_read||"succeed"!=i.status?t._e():e("span",[t._v(" 未读 ")]),i.is_read&&"succeed"==i.status?e("span",{staticClass:"fc-success"},[t._v(" 已读 ")]):t._e()]):t._e()]}},{key:"editor-footer",fn:function(){return[e("div",{staticClass:"lz-flex lz-space-between lz-align-items-center"},[t.currentChat.is_at?e("div",{staticClass:"at-item cur-handle mr-10",on:{click:function(e){return t.openMsgBox()}}},[t._v("有"+t._s(t.currentChat.is_at)+"人提到你")]):t._e(),t.quote?e("div",{staticClass:"message-quote cur-handle mr-10 lz-flex lz-space-between lz-align-items-center"},[e("div",{staticClass:"text-overflow"},[t._v(t._s(t.quote.content))]),e("div",{staticClass:"el-icon-close",on:{click:function(e){return t.closeQuote()}}})]):t._e(),e("div"),e("div",[t._v(t._s(1==t.setting.sendKey?"使用 Ctrl + Enter 换行":"使用 Ctrl + Enter 发送消息"))])])]},proxy:!0}])})],1),e("Group",{attrs:{visible:t.createChatBox,title:t.dialogTitle,isAdd:t.isAdd,userIds:t.userIds,groupId:t.group_id},on:{"update:visible":function(e){t.createChatBox=e},manageGroup:t.manageGroup}}),e("el-dialog",{attrs:{title:"发布公告",visible:t.noticeBox,modal:!0,width:"500px","append-to-body":""},on:{"update:visible":function(e){t.noticeBox=e}}},[e("el-input",{attrs:{type:"textarea",rows:10,placeholder:"请输入内容"},model:{value:t.notice,callback:function(e){t.notice=e},expression:"notice"}}),e("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:function(e){t.noticeBox=!1}}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:t.publishNotice}},[t._v("确 定")])],1)],1),e("addFriend",{attrs:{visible:t.addFriendBox},on:{"update:visible":function(e){t.addFriendBox=e}}}),e("ChooseDialog",{attrs:{visible:t.forwardBox,title:"转发聊天",allUser:t.allUser},on:{"update:visible":function(e){t.forwardBox=e},selectChat:t.forwardUser}}),e("el-dialog",{attrs:{title:"消息管理器",visible:t.messageBox,modal:!0,width:"800px","append-to-body":""},on:{"update:visible":function(e){t.messageBox=e}}},[e("ChatRecord",{key:t.componentKey,attrs:{contact:t.currentChat,condition:t.ChatRecordMap}})],1),e("el-dialog",{attrs:{title:"群设置",visible:t.groupSetting,modal:!0,width:"500px","append-to-body":""},on:{"update:visible":function(e){t.groupSetting=e}}},[e("ChatSet",{key:t.componentKey,attrs:{contact:t.contactSetting},on:{changeOwner:t.changeOwner}})],1),e("el-dialog",{attrs:{title:"语音录制","custom-class":"no-padding",visible:t.VoiceStatus,modal:!0,width:"500px","append-to-body":"","destroy-on-close":""},on:{"update:visible":function(e){t.VoiceStatus=e}}},[e("voice-recorder",{on:{send:t.sendVoice}})],1),e("el-dialog",{attrs:{title:"设置禁言",width:"500px","append-to-body":"","destroy-on-close":"",visible:t.noSpeakBox},on:{"update:visible":function(e){t.noSpeakBox=e}}},[e("el-radio-group",{staticClass:"mb-20",attrs:{size:"small"},on:{change:function(e){t.noSpeakData.noSpeakDay=1}},model:{value:t.noSpeakData.noSpeakTimer,callback:function(e){t.$set(t.noSpeakData,"noSpeakTimer",e)},expression:"noSpeakData.noSpeakTimer"}},[e("el-radio",{attrs:{label:"1",border:""}},[t._v("10分钟")]),e("el-radio",{attrs:{label:"2",border:""}},[t._v("1小时")]),e("el-radio",{attrs:{label:"3",border:""}},[t._v("3小时")]),e("el-radio",{attrs:{label:"4",border:""}},[t._v("1天")])],1),e("div",[t._v(" 自定义"),e("el-input-number",{staticClass:"ml-10 mr-10",attrs:{min:1,max:365,label:"自定义"},on:{change:function(e){t.noSpeakData.noSpeakTimer=0}},model:{value:t.noSpeakData.noSpeakDay,callback:function(e){t.$set(t.noSpeakData,"noSpeakDay",e)},expression:"noSpeakData.noSpeakDay"}}),t._v(" 天 ")],1),e("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:function(e){t.noSpeakBox=!1}}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.setNoSpeak()}}},[t._v("确 定")])],1)],1),e("group-qr",{attrs:{contact:t.currentChat,visible:t.groupQrShow},on:{"update:visible":function(e){t.groupQrShow=e}}}),e("Socket",{ref:"socket"}),e("webrtc",{key:t.componentKey,ref:"webrtc",attrs:{contact:t.currentChat,config:t.webrtcConfig,alias:t.$packageData.name,userInfo:t.user},on:{message:t.rtcMsg}})],1)},R=[];i(2801),i(3408),i(4590);const B=window.location.protocol+"//"+window.location.host+"/";var F=[{label:"表情",type:1,name:"emoji",icon:"cuIcon-emoji",children:[{name:"1f600",title:"emoji",src:B+"/static/img/emoji/twitter/1f600.png"},{name:"1f62c",title:"emoji",src:B+"/static/img/emoji/twitter/1f62c.png"},{name:"1f601",title:"emoji",src:B+"/static/img/emoji/twitter/1f601.png"},{name:"1f602",title:"emoji",src:B+"/static/img/emoji/twitter/1f602.png"},{name:"1f923",title:"emoji",src:B+"/static/img/emoji/twitter/1f923.png"},{name:"1f973",title:"emoji",src:B+"/static/img/emoji/twitter/1f973.png"},{name:"1f974",title:"emoji",src:B+"/static/img/emoji/twitter/1f974.png"},{name:"1f979",title:"emoji",src:B+"/static/img/emoji/twitter/1f979.png"},{name:"1f603",title:"emoji",src:B+"/static/img/emoji/twitter/1f603.png"},{name:"1f604",title:"emoji",src:B+"/static/img/emoji/twitter/1f604.png"},{name:"1f605",title:"emoji",src:B+"/static/img/emoji/twitter/1f605.png"},{name:"1f606",title:"emoji",src:B+"/static/img/emoji/twitter/1f606.png"},{name:"1f607",title:"emoji",src:B+"/static/img/emoji/twitter/1f607.png"},{name:"1f608",title:"emoji",src:B+"/static/img/emoji/twitter/1f608.png"},{name:"1f609",title:"emoji",src:B+"/static/img/emoji/twitter/1f609.png"},{name:"1f60a",title:"emoji",src:B+"/static/img/emoji/twitter/1f60a.png"},{name:"1f642",title:"emoji",src:B+"/static/img/emoji/twitter/1f642.png"},{name:"1f643",title:"emoji",src:B+"/static/img/emoji/twitter/1f643.png"},{name:"1263a",title:"emoji",src:B+"/static/img/emoji/twitter/263a.png"},{name:"1f60b",title:"emoji",src:B+"/static/img/emoji/twitter/1f60b.png"},{name:"1f60c",title:"emoji",src:B+"/static/img/emoji/twitter/1f60c.png"},{name:"1f60d",title:"emoji",src:B+"/static/img/emoji/twitter/1f60d.png"},{name:"1f970",title:"emoji",src:B+"/static/img/emoji/twitter/1f970.png"},{name:"1f618",title:"emoji",src:B+"/static/img/emoji/twitter/1f618.png"},{name:"1f617",title:"emoji",src:B+"/static/img/emoji/twitter/1f617.png"},{name:"1f619",title:"emoji",src:B+"/static/img/emoji/twitter/1f619.png"},{name:"1f61a",title:"emoji",src:B+"/static/img/emoji/twitter/1f61a.png"},{name:"1f61c",title:"emoji",src:B+"/static/img/emoji/twitter/1f61c.png"},{name:"1f92a",title:"emoji",src:B+"/static/img/emoji/twitter/1f92a.png"},{name:"1f928",title:"emoji",src:B+"/static/img/emoji/twitter/1f928.png"},{name:"1f9d0",title:"emoji",src:B+"/static/img/emoji/twitter/1f9d0.png"},{name:"1f61d",title:"emoji",src:B+"/static/img/emoji/twitter/1f61d.png"},{name:"1f61b",title:"emoji",src:B+"/static/img/emoji/twitter/1f61b.png"},{name:"1f911",title:"emoji",src:B+"/static/img/emoji/twitter/1f911.png"},{name:"1f913",title:"emoji",src:B+"/static/img/emoji/twitter/1f913.png"},{name:"1f60e",title:"emoji",src:B+"/static/img/emoji/twitter/1f60e.png"},{name:"1f929",title:"emoji",src:B+"/static/img/emoji/twitter/1f929.png"},{name:"1f921",title:"emoji",src:B+"/static/img/emoji/twitter/1f921.png"},{name:"1f920",title:"emoji",src:B+"/static/img/emoji/twitter/1f920.png"},{name:"1f917",title:"emoji",src:B+"/static/img/emoji/twitter/1f917.png"},{name:"1f60f",title:"emoji",src:B+"/static/img/emoji/twitter/1f60f.png"},{name:"1f636",title:"emoji",src:B+"/static/img/emoji/twitter/1f636.png"},{name:"1f610",title:"emoji",src:B+"/static/img/emoji/twitter/1f610.png"},{name:"1f611",title:"emoji",src:B+"/static/img/emoji/twitter/1f611.png"},{name:"1f612",title:"emoji",src:B+"/static/img/emoji/twitter/1f612.png"},{name:"1f644",title:"emoji",src:B+"/static/img/emoji/twitter/1f644.png"},{name:"1f914",title:"emoji",src:B+"/static/img/emoji/twitter/1f914.png"},{name:"1f925",title:"emoji",src:B+"/static/img/emoji/twitter/1f925.png"},{name:"1f927",title:"emoji",src:B+"/static/img/emoji/twitter/1f927.png"},{name:"1f928",title:"emoji",src:B+"/static/img/emoji/twitter/1f928.png"},{name:"1f929",title:"emoji",src:B+"/static/img/emoji/twitter/1f929.png"},{name:"1f92d",title:"emoji",src:B+"/static/img/emoji/twitter/1f92d.png"},{name:"1f92b",title:"emoji",src:B+"/static/img/emoji/twitter/1f92b.png"},{name:"1f92c",title:"emoji",src:B+"/static/img/emoji/twitter/1f92c.png"},{name:"1f92f",title:"emoji",src:B+"/static/img/emoji/twitter/1f92f.png"},{name:"1f633",title:"emoji",src:B+"/static/img/emoji/twitter/1f633.png"},{name:"1f61e",title:"emoji",src:B+"/static/img/emoji/twitter/1f61e.png"},{name:"1f61f",title:"emoji",src:B+"/static/img/emoji/twitter/1f61f.png"},{name:"1f620",title:"emoji",src:B+"/static/img/emoji/twitter/1f620.png"},{name:"1f621",title:"emoji",src:B+"/static/img/emoji/twitter/1f621.png"},{name:"1fae0",title:"emoji",src:B+"/static/img/emoji/twitter/1fae0.png"},{name:"1fae1",title:"emoji",src:B+"/static/img/emoji/twitter/1fae1.png"},{name:"1fae2",title:"emoji",src:B+"/static/img/emoji/twitter/1fae2.png"},{name:"1fae3",title:"emoji",src:B+"/static/img/emoji/twitter/1fae3.png"},{name:"1fae4",title:"emoji",src:B+"/static/img/emoji/twitter/1fae4.png"},{name:"1fae5",title:"emoji",src:B+"/static/img/emoji/twitter/1fae5.png"},{name:"1faf0",title:"emoji",src:B+"/static/img/emoji/twitter/1faf0.png"},{name:"2639",title:"emoji",src:B+"/static/img/emoji/twitter/2639.png"},{name:"263a",title:"emoji",src:B+"/static/img/emoji/twitter/263a.png"}]},{label:"收藏",type:2,name:"favor",icon:"cuIcon-favor",children:[{name:"1f62c",title:"emoji",src:B+"/static/img/emoji/twitter/1f62c.png"},{name:"1f621",title:"emoji",src:B+"/static/img/emoji/twitter/1f621.png"}]}],$=i(2325),H=function(){var t=this;t._self._c;return t._m(0)},V=[function(){var t=this,e=t._self._c;return e("div",[e("audio",{attrs:{id:"chatAudio"}},[e("source",{attrs:{src:i(1315),type:"audio/ogg"}}),e("source",{attrs:{src:i(444),type:"audio/mpeg"}}),e("source",{attrs:{src:i(8611),type:"audio/wav"}})])])}],G={name:"socket",data(){return{is_open_socket:!1,websocket:null,pingInterval:30,connectNum:1,manMade:!0,timeout:3e4,heartbeatInterval:null,reconnectTimeOut:null}},methods:{getWsUrl(){let t={NODE_ENV:"production",BASE_URL:""}.VUE_APP_BASE_API,e=window.location.protocol,i="ws://";t=window.location.host,"https:"==e&&(i="wss://");const s=i+t+"/wss";return s},initWebSocket(){const t=this.getWsUrl();this.websocket=new WebSocket(t),this.start(),this.is_open_socket=!0,this.websocket.onmessage=this.websocketOnMessage,this.websocket.onclose=this.websocketClose,s["default"].prototype.$websocket=this.websocket,this.$store.state.wsStatus=!0},websocketOnMessage(t){const e=JSON.parse(t.data);let i=o().get("UserInfo"),s=o().get("authToken");switch(e["type"]){case"ping":this.websocketSend({type:"pong"});break;case"init":o().set("client_id",e["client_id"]),this.$api.commonApi.bindClientIdAPI({client_id:e["client_id"],user_id:i.user_id}).then((t=>{this.websocketSend({type:"bindUid",user_id:i.user_id,token:s}),console.log(e["client_id"],"消息服务启动成功")})).catch((t=>{console.log("连接失败")}));break;default:this.$store.commit("catchSocketAction",e);break}},websocketClose(t){if(console.log("websocket连接关闭"),this.is_open_socket=!1,clearInterval(this.heartbeatInterval),clearInterval(this.reconnectTimeOut),this.connectNum<3)return this.manMade=!1,this.reconnect(),void(this.connectNum+=1);this.$store.state.wsStatus=!1,this.connectNum=1,this.websocket=null;let e=o().get("UserInfo");this.$api.commonApi.offlineAPI({user_id:e.user_id}).then((e=>{console.log("connection closed ("+t.code+")")}))},start(){this.heartbeatInterval=setInterval((()=>{this.websocketSend({type:"ping"})}),this.timeout)},websocketSend(t){var e=JSON.stringify(t);this.checkStatus&&this.websocket.send(e)},checkStatus(){return!(!this.websocket||[2,3].includes(this.websocket.readyState))||(console.log("未链接!"),!1)},close(){this.is_open_socket&&this.websocket.close()},reconnect(){console.log("正在重连..."),clearInterval(this.heartbeatInterval),this.is_open_socket||0!=this.manMade||(console.log("5秒后重新连接..."),this.reconnectTimeOut=setInterval((()=>{this.initWebSocket()}),5e3))},playAudio(){const t=document.getElementById("chatAudio");t.currentTime=0,t.play()}},created(){this.initWebSocket()}},K=G,z=(0,d.Z)(K,H,V,!1,null,null,null),Q=z.exports,Y=i(8100),J=function(){var t=this,e=t._self._c;return e("div",[e("div",{staticClass:"group-item"},[e("div",{staticClass:"group-avatar"},[e("el-avatar",{attrs:{shape:"square",src:t.contact.avatar}})],1),e("div",{staticClass:"group-content"},[e("div",{staticClass:"group-title"},[t._v(t._s(t.contact.displayName)+" "),e("span",[t._v("("+t._s(t.groupInfo.groupUserCount)+")")])]),e("div",{staticClass:"group-user"},[t._v("群主:"+t._s(t.groupInfo.ownerName))])])]),e("div",{staticClass:"setting-item"},[e("div",{staticClass:"setting-title"},[t._v("群管理:")]),e("div",{staticClass:"setting-option"},[e("el-switch",{attrs:{"active-value":"1","inactive-value":"0"},on:{change:t.groupSetting},model:{value:t.setting.manage,callback:function(e){t.$set(t.setting,"manage",e)},expression:"setting.manage"}})],1),t._m(0)]),e("div",{staticClass:"setting-item"},[e("div",{staticClass:"setting-title"},[t._v("群成员邀请:")]),e("div",{staticClass:"setting-option"},[e("el-switch",{attrs:{"active-value":"1","inactive-value":"0"},on:{change:t.groupSetting},model:{value:t.setting.invite,callback:function(e){t.$set(t.setting,"invite",e)},expression:"setting.invite"}})],1),t._m(1)]),e("div",{staticClass:"setting-item"},[e("div",{staticClass:"setting-title"},[t._v("群成员隐私:")]),e("div",{staticClass:"setting-option"},[e("el-switch",{attrs:{"active-value":"1","inactive-value":"0"},on:{change:t.groupSetting},model:{value:t.setting.profile,callback:function(e){t.$set(t.setting,"profile",e)},expression:"setting.profile"}})],1),t._m(2)]),e("div",{staticClass:"setting-item"},[e("div",{staticClass:"setting-title"},[t._v("群历史消息:")]),e("div",{staticClass:"setting-option"},[e("el-switch",{attrs:{"active-value":"1","inactive-value":"0"},on:{change:t.groupSetting},model:{value:t.setting.history,callback:function(e){t.$set(t.setting,"history",e)},expression:"setting.history"}})],1),t._m(3)]),e("div",{staticClass:"setting-item"},[e("div",{staticClass:"setting-title"},[t._v("群禁言:")]),e("div",{staticClass:"setting-option"},[e("el-radio-group",{attrs:{size:"mini"},on:{change:t.groupSetting},model:{value:t.setting.nospeak,callback:function(e){t.$set(t.setting,"nospeak",e)},expression:"setting.nospeak"}},[e("el-radio-button",{attrs:{label:"0"}},[t._v("关闭")]),e("el-radio-button",{attrs:{label:"1"}},[t._v("仅管理员可发言")]),e("el-radio-button",{attrs:{label:"2"}},[t._v("仅群主可发言")])],1)],1)]),e("div",{staticClass:"setting-item"},[e("div",{staticClass:"setting-title"},[t._v("其他操作:")]),e("div",{staticClass:"setting-option"},[e("el-button",{attrs:{size:"mini"},on:{click:t.changeOwner}},[t._v("转让群主")]),e("el-button",{attrs:{size:"mini",type:"danger"},on:{click:t.clearMessage}},[t._v("清空聊天记录")])],1)])])},q=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"setting-description"},[e("div",{staticClass:"des-title"},[t._v("仅群主和群管理员可以管理")]),e("div",{staticClass:"des-comment"},[t._v("启用后,其他成员不能修改群名称,编辑公告等")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"setting-description"},[e("div",{staticClass:"des-title"},[t._v("允许群成员邀请")]),e("div",{staticClass:"des-comment"},[t._v("启用后,其他成员可以邀请其他人加入群聊")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"setting-description"},[e("div",{staticClass:"des-title"},[t._v("允许添加群成员为好友")]),e("div",{staticClass:"des-comment"},[t._v("启用后,成员可以互相查看资料并添加为好友或发消息")])])},function(){var t=this,e=t._self._c;return e("div",{staticClass:"setting-description"},[e("div",{staticClass:"des-title"},[t._v("允许成员查看历史消息")]),e("div",{staticClass:"des-comment"},[t._v("启用后,新入群的成员可以查看所有的历史记录")])])}],W={name:"chatSet",props:{contact:{type:Object,default:{}}},data(){return{setting:{},groupInfo:{}}},methods:{groupSetting(){this.$api.imApi.groupSettingAPI({id:this.contact.id,setting:this.setting})},changeOwner(){this.$emit("changeOwner",this.contact.id)},clearMessage(){this.$confirm("确定情况该群组的所有聊天记录吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$api.imApi.clearMessageAPI({id:this.contact.id})})).catch((()=>{this.$message({type:"info",message:"已取消"})}))}},created(){this.$api.imApi.getGroupInfoAPI({group_id:this.contact.id}).then((t=>{var e=t.data;this.groupInfo=e,this.setting=e.setting}))}},Z=W,X=(0,d.Z)(Z,J,q,!1,null,"6abb37da",null),tt=X.exports,et=function(){var t=this,e=t._self._c;return e("div",{staticClass:"chatTop"},[e("el-tooltip",{attrs:{content:t.contact.displayName,placement:"top-start",effect:"light"}},[e("div",{staticClass:"top-item",class:t.currentId==t.contact.id?"active":""},[e("div",{staticClass:"avatar"},[e("el-avatar",{attrs:{shape:t.avatarCricle?"circle":"square",size:"small",src:t.contact.avatar}})],1),e("div",{staticClass:"username"},[t._v(" "+t._s(t.contact.displayName)+" ")])])])],1)},it=[],st={name:"chatTop",props:{contact:{type:Object,default:{}},currentId:[String,Number],avatarCricle:{type:Boolean,default:!1}},data(){return{}},methods:{},created(){}},nt=st,at=(0,d.Z)(nt,et,it,!1,null,"069c0360",null),rt=at.exports,ot=function(){var t=this,e=t._self._c;return e("div",{staticClass:"lum-dialog-mask animated fadeIn"},[e("el-container",{staticClass:"lum-dialog-box"},[e("el-main",{staticClass:"no-padding mian"},[e("div",{staticClass:"music"},[e("span",{staticClass:"line line1",class:{"line-ani":t.animation}}),e("span",{staticClass:"line line2",class:{"line-ani":t.animation}}),e("span",{staticClass:"line line3",class:{"line-ani":t.animation}}),e("span",{staticClass:"line line4",class:{"line-ani":t.animation}}),e("span",{staticClass:"line line5",class:{"line-ani":t.animation}})]),e("div",{staticStyle:{"margin-top":"35px",color:"#676262","font-weight":"300"}},[0==t.recorderStatus?[e("p",{staticStyle:{"font-size":"13px","margin-top":"5px"}},[e("span",[t._v("语音消息,让聊天更简单方便 ...")])])]:1==t.recorderStatus||2==t.recorderStatus||3==t.recorderStatus?[e("p",[t._v(t._s(t.datetime))]),e("p",{staticStyle:{"font-size":"13px","margin-top":"5px"}},[1==t.recorderStatus?e("span",[t._v("正在录音...")]):2==t.recorderStatus?e("span",[t._v("已暂停录音")]):3==t.recorderStatus?e("span",[t._v("录音时长")]):t._e()])]:4==t.recorderStatus||5==t.recorderStatus||6==t.recorderStatus?[e("p",[t._v(t._s(t.formatPlayTime))]),e("p",{staticStyle:{"font-size":"13px","margin-top":"5px"}},[4==t.recorderStatus?e("span",[t._v("正在播放")]):5==t.recorderStatus?e("span",[t._v("已暂停播放")]):6==t.recorderStatus?e("span",[t._v("播放已结束")]):t._e()])]:t._e()],2)]),e("el-footer",{staticClass:"footer",attrs:{height:"60px"}},[e("el-button",{directives:[{name:"show",rawName:"v-show",value:0==t.recorderStatus,expression:"recorderStatus == 0"}],attrs:{type:"primary",size:"small",round:"",icon:"el-icon-microphone"},on:{click:t.startRecorder}},[t._v("开始录音 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:1==t.recorderStatus,expression:"recorderStatus == 1"}],attrs:{type:"warning",size:"small",round:"",icon:"el-icon-video-pause"},on:{click:t.pauseRecorder}},[t._v("暂停录音 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:2==t.recorderStatus,expression:"recorderStatus == 2"}],attrs:{type:"primary",size:"small",round:"",icon:"el-icon-microphone"},on:{click:t.resumeRecorder}},[t._v("继续录音 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:(2==t.recorderStatus||1==t.recorderStatus)&&t.duration>1,expression:"(recorderStatus == 2 || recorderStatus == 1) && duration>1"}],attrs:{type:"danger",size:"small",round:"",icon:"el-icon-microphone"},on:{click:t.stopRecorder}},[t._v("结束录音 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:3==t.recorderStatus||6==t.recorderStatus,expression:"recorderStatus == 3 || recorderStatus == 6"}],attrs:{type:"success",size:"small",round:"",icon:"el-icon-video-play"},on:{click:t.playRecorder}},[t._v("播放录音 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:3==t.recorderStatus||5==t.recorderStatus||6==t.recorderStatus,expression:"\n recorderStatus == 3 || recorderStatus == 5 || recorderStatus == 6\n "}],attrs:{type:"warning",size:"small",round:"",icon:"el-icon-refresh-right"},on:{click:t.startRecorder}},[t._v("重新录音 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:4==t.recorderStatus,expression:"recorderStatus == 4"}],attrs:{type:"info",size:"small",round:"",icon:"el-icon-video-pause"},on:{click:t.pausePlayRecorder}},[t._v("暂停播放 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:5==t.recorderStatus,expression:"recorderStatus == 5"}],attrs:{type:"success",size:"small",round:"",icon:"el-icon-video-play"},on:{click:t.resumePlayRecorder}},[t._v("继续播放 ")]),e("el-button",{directives:[{name:"show",rawName:"v-show",value:3==t.recorderStatus||5==t.recorderStatus||6==t.recorderStatus,expression:"\n recorderStatus == 3 || recorderStatus == 5 || recorderStatus == 6\n "}],attrs:{type:"primary",size:"small",round:""},on:{click:t.submit}},[t._v("立即发送 ")])],1)],1)],1)},ct=[],lt=i(7362),dt=i.n(lt),ut={name:"voiceRecorder",data(){return{recorder:null,duration:0,playTime:0,animation:!1,recorderStatus:0,playTimeout:null}},computed:{datetime(){let t=parseInt(this.duration/60/60%24),e=parseInt(this.duration/60%60),i=parseInt(this.duration%60);return t<10&&(t=`0${t}`),e<10&&(e=`0${e}`),i<10&&(i=`0${i}`),`${t}:${e}:${i}`},formatPlayTime(){let t=parseInt(this.playTime/60/60%24),e=parseInt(this.playTime/60%60),i=parseInt(this.playTime%60);return t<10&&(t=`0${t}`),e<10&&(e=`0${e}`),i<10&&(i=`0${i}`),`${t}:${e}:${i}`}},destroyed(){this.recorder&&this.destroyRecorder()},methods:{closeBox(){null!=this.recorder?(1==this.recorderStatus?this.stopRecorder():4==this.recorderStatus&&this.pausePlayRecorder(),this.destroyRecorder((()=>{this.$emit("close",!1)}))):this.$emit("close",!1)},startRecorder(){let t=this;this.recorder=new(dt()),this.recorder.onprocess=e=>{e=parseInt(e),t.duration=e},this.recorder.start().then((()=>{this.recorderStatus=1,this.animation=!0}),(t=>{console.log(`${t.name} : ${t.message}`)}))},pauseRecorder(){this.recorder.pause(),this.recorderStatus=2,this.animation=!1},resumeRecorder(){this.recorderStatus=1,this.recorder.resume(),this.animation=!0},stopRecorder(){this.recorderStatus=3,this.recorder.stop(),this.animation=!1},playRecorder(){this.recorderStatus=4,this.recorder.play(),this.playTimeouts(),this.animation=!0},pausePlayRecorder(){this.recorderStatus=5,this.recorder.pausePlay(),clearInterval(this.playTimeout),this.animation=!1},resumePlayRecorder(){this.recorderStatus=4,this.recorder.resumePlay(),this.playTimeouts(),this.animation=!0},destroyRecorder(t){this.recorder.destroy().then((()=>{this.recorder=null,t&&t()}))},recorderSize(){return this.recorder.fileSize},playTimeouts(){this.playTimeout=setInterval((()=>{let t=parseInt(this.recorder.getPlayTime());this.playTime=t,t==this.duration&&(clearInterval(this.playTimeout),this.animation=!1,this.recorderStatus=6)}),100)},submit(){let t=this.recorder.getWAVBlob(),e=new File([t],"在线录音.wav",{type:t.type,lastModified:Date.now()});this.$emit("send",this.duration,e)}}},ht=ut,pt=(0,d.Z)(ht,ot,ct,!1,null,"dcd1bb58",null),mt=pt.exports,gt=i(284),ft=function(){var t=this,e=t._self._c;return e("el-dialog",{attrs:{title:"群二维码分享",visible:t.visible,modal:!0,width:"340px","append-to-body":""},on:{close:t.closeDialog}},[e("el-image",{staticStyle:{width:"300px",height:"432px"},attrs:{src:t.image}},[e("div",{staticClass:"image-slot",attrs:{slot:"error"},slot:"error"},[e("i",{staticClass:"el-icon-picture-outline f-20"}),e("p",{staticClass:"ml-10 f-18"},[t._v("二维码生成中...")])])]),e("div",{staticClass:"mt-20",attrs:{align:"center"}},[e("el-button",{on:{click:t.saveBase64Image}},[t._v("保存到电脑")])],1),e("vue-canvas-poster",{staticStyle:{display:"none"},attrs:{widthPixels:1e3,painting:t.painting},on:{success:t.success,fail:t.fail}})],1)},vt=[],bt=i(2484),yt={components:{VueCanvasPoster:bt.VueCanvasPoster},props:{contact:{type:Object,default:()=>({})},visible:{type:Boolean,default:!1}},data(){return{painting:{width:"500px",height:"720px",background:"#ffffff",views:[]},image:""}},watch:{visible(t){t&&this.getGroupUserInfo()}},methods:{success(t){this.image=t},fail(t){},closeDialog(){this.$emit("update:visible",!1),this.image=""},saveBase64Image(){var t=document.createElement("a");t.href=this.image,t.download=this.contact.displayName+".png",t.click()},getGroupUserInfo(){this.$api.imApi.getGroupInfoAPI({group_id:this.contact.id}).then((t=>{var e=t.data;this.painting.views=[{type:"image",url:e.avatar,css:{top:"40px",left:"200px",borderRadius:"8px",width:"100px",height:"100px"}},{type:"text",text:"群聊:"+e.name,css:{top:"160px",left:"50px",width:"400px",maxLines:1,fontSize:"30px",textAlign:"center",color:"#000000",fontWeight:"bloder"}},{type:"qrcode",content:e.qrUrl,css:{top:"240px",left:"70px",color:"#000",width:"360px",height:"360px"}},{type:"text",text:"该二维码7天内("+e.qrExpire+"前)有效",css:{top:"640px",left:"50px",width:"400px",maxLines:1,fontSize:"20px",textAlign:"center",color:"#999"}}]}))}}},Ct=yt,xt=(0,d.Z)(Ct,ft,vt,!1,null,null,null),wt=xt.exports,kt=i(6038),It=function(){var t=this,e=t._self._c;return e("el-container",[e("el-header",{staticClass:"slider-aside"},[e("el-tabs",{staticClass:"tab-diy",attrs:{"tab-position":"bottom"},on:{"tab-click":t.handleClick},model:{value:t.activeName,callback:function(e){t.activeName=e},expression:"activeName"}},[e("el-tab-pane",{attrs:{label:"所有文件",name:"all"}}),e("el-tab-pane",{attrs:{label:"我发送的",name:"send"}}),e("el-tab-pane",{attrs:{label:"我收到的",name:"receive"}})],1)],1),e("el-main",{staticClass:"no-padding"},[e("fileItems",{ref:"fileItem"})],1)],1)},At=[],_t=i(4773),Et={name:"files",components:{fileItems:_t.Z},props:{title:{type:String,default:"创建群聊"}},data(){return{selectUid:[],allUser:[],activeName:"all"}},methods:{handleClick(t){"all"==t.name?this.$refs.fileItem.changeRole(0):"send"==t.name?this.$refs.fileItem.changeRole(1):"receive"==t.name&&this.$refs.fileItem.changeRole(2)}}},St=Et,Tt=(0,d.Z)(St,It,At,!1,null,"37188710",null),Nt=Tt.exports,Mt=function(){var t=this,e=t._self._c;return e("el-tabs",{staticStyle:{height:"100%"},attrs:{"tab-position":"left"}},[e("el-tab-pane",{staticClass:"pd-20",attrs:{label:"账号设置"}},[e("div",{staticClass:"user-center"},[e("div",{staticClass:"user-avatar"},[e("el-upload",{ref:"upload",staticClass:"upload-demo",attrs:{multiple:!1,action:t.getUrl,"show-file-list":!1,data:{type:1},headers:t.getToken,"on-success":t.handleAvatarSuccess,"auto-upload":!1,"on-change":t.change,"before-upload":t.before,"http-request":t.request}},[e("el-image",{staticClass:"m-20",staticStyle:{width:"160px","border-radius":"8px",overflow:"hidden"},attrs:{src:t.user.avatar}}),e("el-button",{staticClass:"replace-picture-button mab-30",attrs:{size:"mini"}},[t._v("更换头像")])],1),e("el-dialog",{attrs:{title:"头像剪裁","close-on-click-modal":!1,visible:t.cropperDialogVisible,width:"580px","append-to-body":!0,"show-close":!0},on:{"update:visible":function(e){t.cropperDialogVisible=e},closed:function(e){return t.$refs.upload.clearFiles()}},scopedSlots:t._u([{key:"footer",fn:function(){return[e("el-button",{on:{click:function(e){t.cropperDialogVisible=!1,t.$refs.upload.clearFiles()}}},[t._v("取 消")]),e("el-button",{attrs:{type:"primary"},on:{click:t.cropperSave}},[t._v("确 定")])]},proxy:!0}])},[e("Cropper",{key:t.componentsKey,ref:"cropper",attrs:{src:t.cropperImg,compress:t.compress,aspectRatio:t.aspectRatio}})],1),e("div",{staticClass:"mt-20"},[e("el-button",{attrs:{type:"warning"},on:{click:function(e){return t.editInfo(1)}}},[t._v("修改密码")])],1)],1),e("div",{staticClass:"user-info"},[e("el-form",{ref:"userinfo",attrs:{model:t.user,"label-width":"100px"}},[e("el-form-item",{attrs:{label:"登陆账号",prop:"account"}},[t._v(" "+t._s(t.user.account)+" "),e("span",{staticClass:"fc-primary ml-10 cur-handle",on:{click:function(e){return t.editInfo(0)}}},[t._v("修改")])]),1==t.$store.state.globalConfig.sysInfo.runMode&&1!=t.$store.state.globalConfig.sysInfo.diyName?e("el-form-item",{attrs:{label:"姓名"}},[t._v(" "+t._s(t.user.realname)+" ")]):e("el-form-item",{attrs:{label:"昵称"}},[e("el-input",{staticStyle:{width:"400px"},attrs:{placeholder:"请输入昵称",maxlength:"20"},model:{value:t.user.realname,callback:function(e){t.$set(t.user,"realname",e)},expression:"user.realname"}})],1),e("el-form-item",{attrs:{label:"e-mail"}},[e("el-input",{staticStyle:{width:"400px"},attrs:{placeholder:"请输入邮箱地址",maxlength:"120"},model:{value:t.user.email,callback:function(e){t.$set(t.user,"email",e)},expression:"user.email"}})],1),e("el-form-item",{attrs:{label:"性别"}},[e("el-radio-group",{model:{value:t.user.sex,callback:function(e){t.$set(t.user,"sex",e)},expression:"user.sex"}},[e("el-radio",{attrs:{label:2,border:""}},[t._v("未知")]),e("el-radio",{attrs:{label:1,border:""}},[t._v("男")]),e("el-radio",{attrs:{label:0,border:""}},[t._v("女")])],1)],1),e("el-form-item",{attrs:{label:"个性签名"}},[e("el-input",{staticStyle:{width:"400px"},attrs:{type:"textarea",rows:3,maxlength:"100","show-word-limit":""},model:{value:t.user.motto,callback:function(e){t.$set(t.user,"motto",e)},expression:"user.motto"}})],1),e("el-form-item",[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.submitForm()}}},[t._v("保存")])],1)],1)],1)]),e("el-dialog",{attrs:{title:t.dialogTitle,visible:t.dialog,modal:!0,width:"400px","append-to-body":""},on:{"update:visible":function(e){t.dialog=e}}},[e("el-form",{attrs:{"label-width":"100px"}},[e("el-form-item",{attrs:{label:"当前账号"}},[t._v(" "+t._s(t.user.account)+" ")]),e("el-alert",{staticClass:"mb-20",attrs:{title:"验证账户的真实性,绑定后请使用新账户来重新登录!",type:"warning"}}),t.user.is_auth?e("el-form-item",{attrs:{label:"验证码"}},[e("el-input",{staticStyle:{width:"260px"},attrs:{placeholder:"请输入验证码",maxlength:"6"},model:{value:t.code,callback:function(e){t.code=e},expression:"code"}},[e("el-button",{attrs:{slot:"append",loading:t.loading},on:{click:function(e){return t.sendCode(!0)}},slot:"append"},[t._v("发送验证码")])],1)],1):t._e(),!t.editPass||t.globalConfig.sysInfo.regauth&&t.user.is_auth?t._e():e("el-form-item",{attrs:{label:"原密码"}},[e("el-input",{attrs:{"show-password":"",placeholder:"请输入原来的密码"},model:{value:t.originalPassword,callback:function(e){t.originalPassword=e},expression:"originalPassword"}})],1),t.editPass?t._e():e("el-form-item",{attrs:{label:"新账号"}},[e("el-input",{attrs:{placeholder:"请输入新的账号"},model:{value:t.account,callback:function(e){t.account=e},expression:"account"}})],1),t.editPass?t._e():e("el-form-item",{attrs:{label:"新账号验证码"}},[e("el-input",{staticStyle:{width:"260px"},attrs:{placeholder:"请输入新账号验证码",maxlength:"6"},model:{value:t.newCode,callback:function(e){t.newCode=e},expression:"newCode"}},[e("el-button",{attrs:{slot:"append",loading:t.loading},on:{click:function(e){return t.sendCode(!1)}},slot:"append"},[t._v("发送验证码")])],1)],1),t.editPass?e("el-form-item",{attrs:{label:"新密码"}},[e("el-input",{attrs:{"show-password":"",placeholder:"请输入密码"},model:{value:t.password,callback:function(e){t.password=e},expression:"password"}})],1):t._e(),t.editPass?e("el-form-item",{attrs:{label:"重复密码"}},[e("el-input",{attrs:{"show-password":"",placeholder:"请输入重复输入密码"},model:{value:t.repass,callback:function(e){t.repass=e},expression:"repass"}})],1):t._e(),e("el-form-item",[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.editPassword()}}},[t._v("保存")])],1)],1)],1),e("div",{staticClass:"mt-40",attrs:{align:"center"}},[e("el-button",{staticStyle:{width:"150px"},attrs:{type:"danger",plain:"",round:""},on:{click:t.logout}},[t._v("退出登录")])],1)],1),e("el-tab-pane",{staticClass:"pd-20",attrs:{label:"通用设置"}},[e("el-form",{ref:"form",attrs:{model:t.setting,"label-width":"100px"}},[e("el-form-item",{attrs:{label:"发送消息:"}},[e("el-radio-group",{model:{value:t.setting.sendKey,callback:function(e){t.$set(t.setting,"sendKey",e)},expression:"setting.sendKey"}},[e("el-radio-button",{attrs:{label:"1"}},[t._v("Enter")]),e("el-radio-button",{attrs:{label:"2"}},[t._v("Ctrl + Enter")])],1)],1),e("el-form-item",{attrs:{label:"系统主题:"}},[e("el-radio-group",{model:{value:t.setting.theme,callback:function(e){t.$set(t.setting,"theme",e)},expression:"setting.theme"}},[e("el-radio-button",{attrs:{label:"default"}}),e("el-radio-button",{attrs:{label:"blue"}})],1)],1)],1),e("div",{staticClass:"setting-switch"},[e("el-switch",{model:{value:t.setting.isVoice,callback:function(e){t.$set(t.setting,"isVoice",e)},expression:"setting.isVoice"}}),t._v(" 开启新消息声音提醒 ")],1),e("div",{staticClass:"setting-switch"},[e("el-switch",{model:{value:t.setting.avatarCricle,callback:function(e){t.$set(t.setting,"avatarCricle",e)},expression:"setting.avatarCricle"}}),t._v(" 开启聊天圆形头像(需要刷新) ")],1),e("div",{staticClass:"setting-switch"},[e("el-switch",{model:{value:t.setting.hideMessageName,callback:function(e){t.$set(t.setting,"hideMessageName",e)},expression:"setting.hideMessageName"}}),t._v(" 是否隐藏聊天窗口内的联系人名字 ")],1),e("div",{staticClass:"setting-switch"},[e("el-switch",{model:{value:t.setting.hideMessageTime,callback:function(e){t.$set(t.setting,"hideMessageTime",e)},expression:"setting.hideMessageTime"}}),t._v(" 是否隐藏聊天窗口内的消息发送时间 ")],1)],1),1==parseInt(t.globalConfig.demon_mode)?e("el-tab-pane",{staticClass:"pd-20",attrs:{label:"关于 IM"}},[e("div",{staticClass:"about-logo"},[e("el-avatar",{attrs:{src:t.$packageData.logo,size:50}}),e("br"),e("br"),e("p",[e("span",{staticClass:"fc-primary"},[t._v(" "+t._s(t.$packageData.name)+" ")]),t._v("for "+t._s(t.$packageData.version)+" ")])],1),e("div",{staticClass:"setting-version"},[e("b",[t._v(" 已经支持功能:")]),t._l(t.$packageData.funcList,(function(i){return e("p",{key:i.icon},[e("i",{class:i.icon}),t._v(" "+t._s(i.text))])}))],2)]):t._e(),1==parseInt(t.globalConfig.demon_mode)?e("el-tab-pane",{staticClass:"pd-20",attrs:{label:"开源"}},[e("div",{staticClass:"about-logo"},[e("el-avatar",{attrs:{src:t.$packageData.logo,size:50}}),e("br"),e("br"),e("p",[e("span",{staticClass:"fc-primary"},[t._v(" "+t._s(t.$packageData.name)+" ")]),t._v("for "+t._s(t.$packageData.version)+" ")])],1),e("div",{staticClass:"setting-version"},[e("p",[t._v(" 前端地址:"),e("a",{staticClass:"fc-primary",attrs:{href:t.$packageData.frontUrl,target:"_blank"}},[t._v("[链接] im-chat-front")])]),e("p",[t._v(" 后端地址:"),e("a",{staticClass:"fc-primary",attrs:{href:t.$packageData.backstageUrl,target:"_blank"}},[t._v("[链接] im-instant-chat")])])]),e("div",{staticClass:"setting-version",staticStyle:{color:"#a6a6a6"}},[e("p",[t._v("前端技术栈:vue+Lemon-IMUI+element-UI")]),e("p",[t._v("后端技术栈:thinkphp6+workerman")])]),e("div",{staticClass:"setting-version"},[e("p",[t._v(" QQ交流群: "),e("a",{staticClass:"fc-primary",attrs:{href:t.$packageData.qqGroupUrl,target:"_blank"}},[t._v("336921267")])])])]):t._e()],1)},Lt=[],Ut=function(){var t=this,e=t._self._c;return e("div",{staticClass:"sc-cropper"},[e("div",{staticClass:"sc-cropper__img"},[e("img",{ref:"img",attrs:{src:t.src}})]),e("div",{staticClass:"sc-cropper__preview"},[e("h4",[t._v("图像预览")]),e("div",{ref:"preview",staticClass:"sc-cropper__preview__img"})])])},Ot=[],Dt=i(255),Pt=i.n(Dt),jt={props:{src:{type:String,default:""},compress:{type:Number,default:1},aspectRatio:{type:Number,default:NaN}},data(){return{crop:null}},watch:{aspectRatio(t){this.crop.setAspectRatio(t)}},mounted(){this.init()},methods:{init(){this.crop=new(Pt())(this.$refs.img,{viewMode:2,dragMode:"move",responsive:!1,aspectRatio:this.aspectRatio,preview:this.$refs.preview})},setAspectRatio(t){this.crop.setAspectRatio(t)},getCropData(t,e="image/jpeg"){t(this.crop.getCroppedCanvas().toDataURL(e,this.compress))},getCropBlob(t,e="image/jpeg"){this.crop.getCroppedCanvas().toBlob((e=>{t(e)}),e,this.compress)},getCropFile(t,e="fileName.jpg",i="image/jpeg"){this.crop.getCroppedCanvas({width:240,height:240}).toBlob((s=>{let n=new File([s],e,{type:i});t(n)}),i,this.compress)}}},Rt=jt,Bt=(0,d.Z)(Rt,Ut,Ot,!1,null,"5f07d210",null),Ft=Bt.exports;o().get("UserInfo");var $t={name:"manageGroup",props:{},components:{Cropper:Ft},data(){return{componentsKey:1,maxSize:5,compress:1,aspectRatio:1,cropperDialogVisible:!1,cropper:!0,cropperImg:"",tempImg:"",dialogVisible:!1,dialog:!1,dialogTitle:"修改密码",editPass:1,originalPassword:"",account:"",password:"",repass:"",code:"",newCode:"",loading:!1}},computed:{...(0,v.rn)({setting:t=>t.setting,user:t=>t.userInfo,globalConfig:t=>t.globalConfig}),getUrl(){return window.BASE_URL+"/common/upload/uploadAvatar"},getToken(){const t=o().get("authToken");return{Authorization:t}}},watch:{setting:{handler(t,e){this.$api.imApi.settingAPI(t);let i=o().get("UserInfo");i.setting=t,o().set("UserInfo",i)},deep:!0},editPass(t){this.dialogTitle=1==t?"修改密码":"修改账号"}},methods:{logout(){this.$confirm("确定退出登录吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$store.dispatch("LogOut").then((()=>{this.$router.push("/login")}))})).catch((()=>{}))},submitForm(){if(""==this.user.realname)return this.$message.error("请输入昵称"),!1;let t={realname:this.user.realname,email:this.user.email,sex:this.user.sex,motto:this.user.motto};this.$api.imApi.updateUserInfo(t).then((t=>{if(0==t.code){this.$message.success("修改成功");let t=JSON.parse(JSON.stringify(this.user));this.$store.commit("SET_USERINFO",t)}}))},isImg(t){var e="(.jpg|.png|.gif|.jpeg)$",i=new RegExp(e);i.test(t.toLowerCase())?this.fileIsImg=!0:this.fileIsImg=!1},change(t){if(this.cropper&&"ready"==t.status){if(this.isImg(t.name),!this.fileIsImg)return this.$message.error("选择的文件非图像类文件"),!1;this.componentsKey++,this.cropperDialogVisible=!0,this.cropperImg=URL.createObjectURL(t.raw)}},before(t){t=this.cropper?this.cropperUploadFile:t;const e=t.size/1024/1024<this.maxSize;if(!e)return this.$message.warning(`上传文件大小不能超过 ${this.maxSize}MB!`),!1;this.isImg(t.name),this.tempImg=URL.createObjectURL(t)},request(t){const e=this.$loading({lock:!0,text:"Loading"}),i=new FormData;var s=this.cropper?this.cropperUploadFile:t.file;i.append("file",s),i.append("type",1),this.$api.commonApi.uploadAvatar(i).then((i=>{this.cropperImg="",e.close(),this.handleAvatarSuccess(i),t.onSuccess(i)})).catch((i=>{e.close(),t.onError(i)}))},cropperSave(){var t=this.$refs.upload.uploadFiles[0].raw;this.$refs.cropper.getCropFile((t=>{this.cropperUploadFile=t,this.$refs.upload.submit(),this.cropperDialogVisible=!1}),t.name,t.type)},handleAvatarSuccess(t,e){let i=this.$store.state.userInfo;this.$set(i,"avatar",t.data),this.$store.commit("SET_USERINFO",i)},editInfo(t){this.dialog=!0,this.editPass=t},editPassword(){if(""==this.code&&this.user.is_auth)return this.$message({message:"请输入验证码",type:"warning"}),!1;if(this.editPass){if(""==this.password||this.password.length<6||this.password.length>16)return this.$message({message:"请输入6-16个字符串的密码",type:"warning"}),!1;if(this.password!=this.repass)return this.$message({message:"两次密码不一致",type:"warning"}),!1;if(!this.originalPassword)return this.$message({message:"请输入原密码",type:"warning"}),!1;let t={password:this.password,code:this.code,originalPassword:this.originalPassword};this.$api.imApi.editPassword(t).then((t=>{0==t.code&&(this.dialog=!1,this.password="",this.repass="",this.$message({message:t.msg,type:"success"}))}))}else{if(""==this.account)return this.$message({message:"请输入账号",type:"warning"}),!1;if(""==this.newCode)return this.$message({message:"请输入新账户验证码",type:"warning"}),!1;let t={account:this.account,code:this.code,newCode:this.newCode};this.$api.imApi.editAccount(t).then((t=>{0==t.code&&(this.dialog=!1,this.account="",this.code="",this.newCode="",this.$message({message:t.msg,type:"success"}),this.$store.dispatch("LogOut").then((()=>{this.$router.push("/login")})))}))}},sendCode(t){let e=t?this.user.account:this.account,i=this.editPass?3:4;if(""==e)return this.$message({message:"请输入新的账号",type:"warning"}),!1;this.loading=!0,this.$store.dispatch("sendCode",{type:i,account:e}).then((t=>{this.$message.success("发送成功"),this.loading=!1})).catch((()=>{this.loading=!1}))}}},Ht=$t,Vt=(0,d.Z)(Ht,Mt,Lt,!1,null,"05277269",null),Gt=Vt.exports,Kt=function(){var t=this,e=t._self._c;return e("el-dialog",{attrs:{title:"添加好友",visible:t.visible,modal:!0,width:t.width,"append-to-body":""},on:{close:t.closeDialog}},[e("div",{staticClass:"mb-20"},[e("el-input",{staticStyle:{width:"300px"},attrs:{placeholder:"请输入账号进行搜索","prefix-icon":"el-icon-search"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.handleChange.apply(null,arguments)}},model:{value:t.keywords,callback:function(e){t.keywords=e},expression:"keywords"}},[e("el-button",{attrs:{slot:"append",icon:"el-icon-search"},on:{click:t.handleChange},slot:"append"})],1)],1),e("div",{staticClass:"dialog-main"},[e("div",{staticClass:"member-list"},t._l(t.list,(function(i){return e("div",{key:i.user_id,staticClass:"member-item",on:{click:function(e){return t.$user(i.user_id)}}},[e("div",{staticClass:"member-avatar"},[e("img",{attrs:{src:i.avatar,alt:"avatar"}})]),e("div",{staticClass:"member-content"},[e("div",{staticClass:"member-header"},[e("span",{staticClass:"member-name"},[t._v(t._s(i.realname))]),e("span",{staticClass:"member-account"},[t._v(t._s(i.account))])]),e("div",{staticClass:"member-actions"},[e("el-button",{attrs:{type:"primary",size:"mini"}},[t._v("查看")])],1)])])})),0),0==t.list.length?e("el-empty"):t._e()],1)])},zt=[],Qt={name:"addFriend",props:{visible:{type:Boolean,default:!1},width:{type:String,default:"612px"}},data(){return{keywords:"",list:[]}},mounted(){},methods:{closeDialog(){this.$emit("update:visible",!1),this.selectUid=[]},handleChange(){this.keywords&&this.$api.imApi.searchUser({keywords:this.keywords}).then((t=>{this.list=t.data}))}}},Yt=Qt,Jt=(0,d.Z)(Yt,Kt,zt,!1,null,"18f3aea4",null),qt=Jt.exports,Wt=function(){var t=this,e=t._self._c;return e("span",{staticClass:"sc-state",class:[{"sc-status-processing":t.pulse},"sc-state-bg--"+t.type]})},Zt=[],Xt={props:{type:{type:String,default:"primary"},pulse:{type:[Boolean,Number],default:!0}}},te=Xt,ee=(0,d.Z)(te,Wt,Zt,!1,null,"bf2f9cfc",null),ie=ee.exports,se=function(){var t=this,e=t._self._c;return e("div",{staticClass:"tab-main lz-flex lz-justify-content-start lz-align-items-center",style:{height:t.height+"px"}},t._l(t.values,(function(i,s){return e("div",{staticClass:"tab-item",class:t.active==s?"active":"",style:{height:t.itemHeight+"px",borderRadius:t.itemHeight+"px",lineHeight:t.itemHeight+"px"},on:{click:function(e){return t.changeItem(i,s)}}},[t._v(" "+t._s(i.name)+" "),i.count>0?e("span",[t._v(t._s(i.count>99?"99+":i.count))]):t._e()])})),0)},ne=[],ae={name:"im-tab",components:{},props:{values:{type:Array,default:function(){return[]}},height:{type:Number,default:40}},data(){return{active:0,itemHeight:24}},created:function(){this.itemHeight=this.height-16},methods:{changeItem(t,e){this.active=e,this.$emit("change",t,e)}}},re=ae,oe=(0,d.Z)(re,se,ne,!1,null,"e57a8f0a",null),ce=oe.exports,le=function(){var t=this,e=t._self._c;return e("div",{directives:[{name:"show",rawName:"v-show",value:t.status,expression:"status"}],staticClass:"webrtc-box"},[t._m(0),t._m(1),e("video",{directives:[{name:"show",rawName:"v-show",value:t.localStream&&t.is_video,expression:"localStream && is_video"}],ref:"localvideo",staticClass:"localvideo",attrs:{autoplay:"",playsinline:"",muted:""},domProps:{muted:!0}}),e("video",{directives:[{name:"show",rawName:"v-show",value:t.remoteStream&&t.is_video,expression:"remoteStream && is_video"}],ref:"remotevideo",staticClass:"remotevideo",attrs:{autoplay:"",playsinline:""}}),e("div",[t.caller?e("div",{staticClass:"call-user"},[2==t.status&&t.is_video?t._e():e("img",{staticClass:"avatar",attrs:{src:t.caller.avatar,alt:""}}),e("div",{staticClass:"text"},[t.is_video||2!=t.status?t._e():e("b",[t._v(t._s(t.caller.displayName))]),2!=t.status?e("span",[t.isReceived?e("span",[t._v(" "+t._s(t.caller.displayName)+" 正在请求与您"+t._s(t.is_video?"视频":"语音")+"通话")]):e("span",[t._v("您正对 "),e("b",[t._v(t._s(t.caller.displayName))]),t._v(" 发起"+t._s(t.is_video?"视频":"语音")+"通话")])]):t._e()]),t.callTime&&2==t.status?e("div",{staticClass:"call-time"},[t._v(" "+t._s(t.setCallTime())+" ")]):t._e()]):t._e(),e("div",{staticClass:"calling-button"},[t.caller&&3==t.status?e("div",{staticClass:"button"},[e("img",{staticClass:"image",attrs:{src:i(8516)},on:{click:function(e){return t.answer()}}}),e("div",{staticClass:"text"},[t._v("接听")])]):t._e(),2==t.status?e("div",{staticClass:"button"},[e("img",{staticClass:"image-icon",attrs:{src:t.voiceStatus?t.voiceIcon:t.voiceOffIcon},on:{click:function(e){return t.switchVoice()}}})]):t._e(),t.caller&&0!=t.status?e("div",{staticClass:"button"},[e("img",{staticClass:"image",attrs:{src:i(8421)},on:{click:function(e){return t.hangup(!0)}}}),e("div",{staticClass:"text"},[t._v("挂断")])]):t._e(),2==t.status?e("div",{staticClass:"button"},[t.is_video?e("img",{staticClass:"image-icon",attrs:{src:t.videoStatus?t.videoIcon:t.videoOffIcon},on:{click:function(e){return t.switchVideo()}}}):e("div",{staticClass:"image-icon"})]):t._e()])])])},de=[function(){var t=this,e=t._self._c;return e("audio",{attrs:{id:"music1"}},[e("source",{attrs:{src:i(7420)}})])},function(){var t=this,e=t._self._c;return e("audio",{attrs:{id:"music2"}},[e("source",{attrs:{src:i(1739)}})])}],ue={name:"webrtc",props:{contact:{type:Object,default:{}},userInfo:{type:Object,default:{}},config:{type:Object,default:{}},alias:{type:String,default:"raingad"}},data(){return{voiceIcon:i(2942),voiceOffIcon:i(2414),videoIcon:i(9072),videoOffIcon:i(5617),pc:null,hasCamera:!1,status:0,localVideo:"",remoteVideo:"",remoteStream:null,localStream:null,caller:null,is_video:1,isReceived:!1,videoStatus:!0,voiceStatus:!0,cutdown:40,timer:null,offerParams:{},callTime:0,timerIntervalId:null}},mounted(){this.localVideo=this.$refs.localvideo,this.remoteVideo=this.$refs.remotevideo,this.checkForCamera()},methods:{initPeer(t){let e=this.config,i={iceServers:[{urls:["stun:stun.xten.com","stun:stun.l.google.com:19302","stun:stun1.l.google.com:19302","stun:stun2.l.google.com:19302","stun:stun3.l.google.com:19302","stun:stun4.l.google.com:19302"]},{urls:e.stun?[e.stun]:["stun:stun.callwithus.com"],username:e.stunUser??null,credential:e.stunPass??null}]};this.pc=new RTCPeerConnection(i),this.pc.ontrack=t=>{this.localVideo&&(this.remoteStream=t.streams[0],this.remoteVideo.srcObject=t.streams[0])},this.localStream=t,t.getTracks().forEach((e=>{this.pc.addTrack(e,t)})),this.localVideo.srcObject=this.localStream},checkForCamera(){navigator.mediaDevices.enumerateDevices().then((t=>{const e=t.filter((t=>"videoinput"===t.kind));this.hasCamera=e.length>0})).catch((t=>{console.error("设备检测错误: "+t.message)}))},initLocalStream(t,e){let i=0;this.hasCamera&&(i=1),this.offerParams=e?{offerToRecieveAudio:1,offerToRecieveVideo:1}:{offerToRecieveAudio:1,offerToRecieveVideo:0};let s=1==i;var n=navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.mozGetUserMedia;n({video:s,audio:{echoCancellation:!0}},(e=>{this.initPeer(e),t?(this.$emit("message",{event:"calling"}),this.status=1,this.timer=setInterval((()=>{this.cutdown--,0==this.cutdown&&this.hangup(!0)}),1e3)):(this.$emit("message",{event:"acceptRtc",code:904}),this.startTime())}),(t=>{let i=1==e?"摄像头":"麦克风";this.$message.error("请连接"+i+"设备,并开启"+i+"权限"),this.caller=null,this.hangup(!1)}))},called(t){if(console.log(this.status,this.caller),this.status||this.caller)return!1;this.is_video=t,this.caller=this.contact,this.initLocalStream(!0,t),this.playMusicCall("state")},answer(){this.status=2,this.initLocalStream(!1,this.is_video),this.playMusicCall("close")},startTime(){this.timerIntervalId=setInterval((()=>{this.callTime++}),1e3)},setCallTime(){let t=this.callTime;const e=Math.floor(t/3600),i=Math.floor((t-3600*e)/60),s=t-3600*e-60*i;return`${e.toString().padStart(2,"0")}:${i.toString().padStart(2,"0")}:${s.toString().padStart(2,"0")}`},hangup(t){clearInterval(this.timer),clearInterval(this.timerIntervalId),2!=this.status&&this.playMusicCall("close");let e=902;2==this.status?e=906:3==this.status?e=903:4==this.status&&(e=907),this.status&&(this.status=0,this.closeLocalMedia(),this.remoteStream=null,this.playMusicHandup(),this.isReceived=!1,this.caller=null,this.voiceStatus=!0,this.videoStatus=!0),this.$emit("message",{event:"hangup",code:e,isbtn:t,callTime:this.callTime}),this.callTime=0},closeLocalMedia(){this.localStream&&this.localStream.getTracks()&&this.localStream.getTracks().forEach((t=>{t.stop()})),this.localStream=null},switchVoice(){if(null==this.localStream)return alert("请打开音视频"),!1;const t=this.localStream.getTracks();this.voiceStatus?(t.forEach((t=>{"audio"===t.kind&&(t.enabled=!1)})),this.voiceStatus=!1):(t.forEach((t=>{"audio"===t.kind&&(t.enabled=!0)})),this.voiceStatus=!0)},switchVideo(){if(null==this.localStream)return alert("请打开音视频"),!1;const t=this.localStream.getTracks();this.videoStatus?(t.forEach((t=>{"video"===t.kind&&(t.enabled=!1)})),this.videoStatus=!1):(t.forEach((t=>{"video"===t.kind&&(t.enabled=!0)})),this.videoStatus=!0)},webrtcAction(t){let e=t.extends;switch(e.event){case"calling":this.caller=t.fromUser,this.is_video=parseInt(e.type),this.status=3,this.isReceived=!0,this.playMusicCall("state");break;case"hangup":this.hangup(!1);break;case"busy":this.status=4,this.hangup(!1);break;case"acceptRtc":this.status=2,clearInterval(this.timer),this.startTime(),this.playMusicCall("close"),this.createOffer(),this.onicecandidate();break;case"turndown":break;case"answer":this.pc.setRemoteDescription(new RTCSessionDescription({type:"answer",sdp:e.sdp}));break;case"iceCandidate":setTimeout((()=>{"object"===typeof e.iceCandidate?this.pc.addIceCandidate(new RTCIceCandidate(e.iceCandidate)):this.pc.addIceCandidate(new RTCIceCandidate(JSON.parse(e.iceCandidate)))}),100);break;case"offer":this.pc.setRemoteDescription(new RTCSessionDescription({type:"offer",sdp:e.sdp})),this.createAnswer();break}},createOffer(){this.pc.createOffer(this.offerParams).then((t=>{this.pc.setLocalDescription(t),this.$emit("message",{event:"offer",sdp:t.sdp})}))},createAnswer(){this.pc.createAnswer(this.offerParams).then((t=>{this.pc.setLocalDescription(t),this.$emit("message",{event:"answer",sdp:t.sdp}),this.onicecandidate()}))},onicecandidate(){this.pc.onicecandidate=t=>{var e=t.candidate;e&&this.$emit("message",{event:"iceCandidate",iceCandidate:JSON.parse(JSON.stringify(e))})}},playMusicCall(t){var e=document.getElementById("music1");if("close"===t)return e.pause();e.loop="state"===t,e.paused?e.play():e.pause()},playMusicHandup(){var t=document.getElementById("music2");t.play()}}},he=ue,pe=(0,d.Z)(he,le,de,!1,null,"33f9f506",null),me=pe.exports,ge=function(){var t=this,e=t._self._c;return e("el-container",[e("el-header",{staticClass:"slider-aside"},[e("el-tabs",{staticClass:"tab-diy",attrs:{"tab-position":"bottom"},on:{"tab-click":t.handleClick},model:{value:t.activeName,callback:function(e){t.activeName=e},expression:"activeName"}},[e("el-tab-pane",{attrs:{label:"我收到的",name:"receive"}}),e("el-tab-pane",{attrs:{label:"我发送的",name:"send"}})],1)],1),e("el-main",{staticClass:"no-padding"},[e("div",{staticClass:"apply-list"},[e("div",{staticClass:"apply-list-main"},[e("el-scrollbar",[e("el-alert",{staticClass:"mt-10 mb-10",attrs:{"show-icon":"",title:"未处理的邀请消息会在每次初始化或者页面刷新时会重新提示!",type:"warning"}}),t._l(t.list,(function(i,s){return e("div",{key:s,staticClass:"apply-list-item"},[e("div",{staticClass:"avatar"},[t.params.is_mine?t._e():e("el-avatar",{attrs:{src:i.create_user_info.avatar}}),t.params.is_mine?e("el-avatar",{attrs:{src:i.user_id_info.avatar}}):t._e()],1),e("div",{staticClass:"main"},[t.params.is_mine?t._e():e("div",{on:{click:function(e){return t.$user(i.create_user_info.user_id)}}},[e("span",{staticClass:"fc-primary cur-handle"},[t._v(t._s(i.create_user_info.realname))]),t._v(" 申请添加为好友 "),1==i.status?e("el-tag",{attrs:{type:"success"}},[t._v("已同意")]):t._e()],1),t.params.is_mine?e("div",{on:{click:function(e){return t.$user(i.user_id_info.user_id)}}},[t._v(" 请求添加 "),e("span",{staticClass:"fc-primary cur-handle"},[t._v(t._s(i.user_id_info.realname))]),t._v(" 为好友 "),1==i.status?e("el-tag",{attrs:{type:"success"}},[t._v("已同意")]):t._e()],1):t._e(),e("div",{staticClass:"f-12 c-999"},[t._v(t._s(i.remark))])]),t.params.is_mine?e("div",{staticClass:"option"},[1==i.status?e("span",{staticClass:"fc-primary cur-handle",on:{click:function(e){return t.$store.commit("openChat",i.user_id_info.user_id)}}},[t._v("发消息")]):t._e(),2==i.status?e("el-tag",{attrs:{type:"warning"}},[t._v("待同意")]):t._e(),0==i.status?e("el-tag",{attrs:{type:"danger"}},[t._v("已拒绝")]):t._e()],1):e("div",{staticClass:"option"},[2==i.status?e("el-popconfirm",{attrs:{title:"您确定接受该好友的申请吗?"},on:{confirm:function(e){return t.acceptApply(i.friend_id,!0)}}},[e("el-button",{attrs:{slot:"reference",type:"success",circle:"",plain:"",icon:"el-icon-check"},slot:"reference"})],1):t._e(),2==i.status?e("el-popconfirm",{staticClass:"ml-15",attrs:{title:"您确定拒绝该好友的申请吗?"},on:{confirm:function(e){return t.acceptApply(i.friend_id,!1)}}},[e("el-button",{attrs:{slot:"reference",type:"danger",circle:"",plain:"",icon:"el-icon-close"},slot:"reference"})],1):t._e(),1==i.status?e("span",{staticClass:"fc-primary cur-handle",on:{click:function(e){return t.$store.commit("openChat",i.create_user_info.user_id)}}},[t._v("发消息")]):t._e(),0==i.status?e("el-tag",{attrs:{type:"danger"}},[t._v("已拒绝")]):t._e()],1)])})),0==t.list.length?e("div",[e("el-empty",{attrs:{description:"暂无数据"}})],1):t._e()],2)],1),t.singlePage?t._e():e("div",{staticClass:"apply-list-page",attrs:{align:"center"}},[e("el-pagination",{attrs:{background:"","hide-on-single-page":t.singlePage,"current-page":t.params.page,"page-sizes":[20,50,100,200,300,400,500],"page-size":t.params.limit,layout:"total, sizes, prev, pager, next, jumper",total:t.total},on:{"size-change":t.handleChange,"current-change":t.getList,"update:currentPage":function(e){return t.$set(t.params,"page",e)},"update:current-page":function(e){return t.$set(t.params,"page",e)},"update:pageSize":function(e){return t.$set(t.params,"limit",e)},"update:page-size":function(e){return t.$set(t.params,"limit",e)}}})],1)])])],1)},fe=[],ve={name:"apply",data(){return{singlePage:!0,total:0,list:[],activeName:"receive",params:{page:1,limit:20,is_mine:0}}},mounted(){this.getList()},methods:{handleClick(t){"send"==t.name?this.params.is_mine=1:"receive"==t.name&&(this.params.is_mine=0),this.params.page=1,this.getList()},acceptApply(t,e){let i=e?1:0;this.$api.friendApi.acceptFriend({friend_id:t,status:i}).then((t=>{this.$message.success("操作成功"),this.getList()}))},getList(){this.$api.friendApi.getApplyList(this.params).then((t=>{this.list=t.data,this.total=t.count,this.singlePage=this.total<=this.params.limit}))},handleChange(t){this.params.limit=t,this.getList()}}},be=ve,ye=(0,d.Z)(be,ge,fe,!1,null,"5aced73a",null),Ce=ye.exports,xe=i.p+"assets/img/invite.108c2fc8.png",we=i(2176);const ke=()=>(new Date).getTime(),Ie=o().get("UserInfo");var Ae={name:"app",components:{Socket:Q,ChatRecord:Y.Z,ChatSet:tt,ChatTop:rt,VoiceRecorder:mt,webrtc:me,Group:gt.Z,groupQr:wt,Files:Nt,addFriend:qt,Setting:Gt,ChooseDialog:kt.Z,OnlineStatus:ie,imTab:ce,Apply:Ce},props:{width:{type:String,default:"1000px"},height:{type:String,default:"640px"},fullScreen:{type:Boolean,default:!1}},data(){const t=this.$createElement;var e=this;let i=this.$store.state.globalConfig.chatInfo;return{noSimpleTips:"群已开启禁言,无法发送消息",isFullscreen:!1,curWidth:this.width,curHeight:this.height,unread:0,atUnread:0,webrtcConfig:i,wsData:null,webrtcLock:!1,caller:"",is_video:1,curFile:null,componentKey:1,searchResult:!1,addFriendBox:!1,createChatBox:!1,forwardBox:!1,noticeBox:!1,messageBox:!1,webrtcBox:!1,groupSetting:!1,VoiceStatus:!1,groupQrShow:!1,ChatRecordMap:{},contactSetting:{},groupUserCount:0,dialogTitle:"创建群聊",isAdd:1,userIds:[],noSpeakData:{noSpeakTimer:0,noSpeakDay:1,user_id:0,id:0},curGroupUser:{},notice:"",searchList:[],keywords:"",displayName:"",oldName:"",isEdit:!1,isBottom:!0,user:{id:Ie.user_id,displayName:Ie.realname,avatar:Ie.avatar,account:Ie.account},params:{page:1,limit:10},is_group:0,group_id:"",contacts:[],allUser:[],groupUser:[],currentChat:{},currentMessage:{},lastMessages:[],chatTopList:[],playAudio:null,activeTab:0,tabList:[{name:"所有",count:0},{name:"未读",count:0},{name:"@我",count:0}],quote:"",noSpeakBox:!1,groupMenu:[{text:"发送消息",click:(t,e,i)=>{const{IMUI:s,contact:n}=e;s.changeContact(n.user_id),i()},visible:t=>t.contact.user_id!=this.user.id&&1==this.globalConfig.sysInfo.runMode},{text:"@TA",click:(t,e,i)=>{const{IMUI:s,contact:n}=e;s.setUserTag(n.userInfo),i()},visible:t=>t.contact.user_id!=this.user.id},{text:"设置管理员",click:(t,e,i)=>{const{IMUI:s,contact:n}=e;i(),this.$confirm("确定设置该成员为管理员吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$api.imApi.setManagerAPI({id:this.group_id,user_id:n.user_id,role:2}),this.$message({type:"success",message:"设置成功!"})}))},visible:t=>3==t.contact.role&&this.currentChat.owner_id==this.user.id},{text:"取消管理员",click:(t,e,i)=>{const{IMUI:s,contact:n}=e;i(),this.$confirm("确定取消该成员的管理员权限吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$api.imApi.setManagerAPI({id:this.group_id,user_id:n.user_id,role:3}),this.$message({type:"success",message:"取消成功!"})}))},visible:t=>2==t.contact.role&&this.currentChat.owner_id==this.user.id},{text:"设置禁言",click:(t,e,i)=>{this.noSpeakBox=!0;const{IMUI:s,contact:n}=e;this.noSpeakData.user_id=n.user_id,this.noSpeakData.id=this.group_id,i()},visible:t=>t.contact.user_id!=this.user.id&&t.contact.role>1&&this.currentChat.role<=2},{text:"查看资料",click:(t,e,i)=>{const{IMUI:s,contact:n}=e;i();let a=this.getContact(n.user_id),r=s.getCurrentContact();1==r.setting.profile||r.role<3||a||n.user_id==this.user.id?this.$user(n.user_id):this.$message.error("已开启隐私,无法查看资料")},visible:t=>t.contact.user_id!=this.user.id},{text:"移出群聊",color:"red",click:(t,e,i)=>{const{IMUI:s,contact:n}=e;i(),this.$confirm("确定移除该成员吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$api.imApi.removeUserAPI({id:this.group_id,user_id:n.user_id})}))},visible:t=>t.contact.user_id!=this.user.id&&this.currentChat.owner_id!=t.contact.user_id&&this.currentChat.role<=2}],contactContextmenu:[{click(t,i,s){const{IMUI:n,contact:a}=i;e.$user(a.user_id),s()},icon:"el-icon-tickets",text:"查看资料",visible:t=>0==t.contact.is_group},{icon:"el-icon-upload2",text:"置顶聊天",click:(t,i,s)=>{const{IMUI:n,contact:a}=i;e.$api.imApi.setChatTopAPI({id:a.id,is_top:1,is_group:a.is_group}).then((t=>{0==t.code&&n.updateContact({id:a.id,is_top:1})})),s()},visible:t=>0==t.contact.is_top&&t.contact.is_group<2},{icon:"el-icon-download",text:"取消置顶",click:(t,i,s)=>{const{IMUI:n,contact:a}=i;e.$api.imApi.setChatTopAPI({id:a.id,is_top:0,is_group:a.is_group}).then((t=>{0==t.code&&n.updateContact({id:a.id,is_top:0})})),s()},visible:t=>1==t.contact.is_top&&t.contact.is_group<2},{click(t,i,s){const{IMUI:n,contact:a}=i;s(),e.$api.imApi.isNoticeAPI({id:a.id,is_notice:0,is_group:a.is_group}),n.updateContact({id:a.id,is_notice:0})},icon:"el-icon-bell",text:"消息免打扰",visible:t=>1==t.contact.is_notice&&t.contact.is_group<2},{click(t,i,s){const{IMUI:n,contact:a}=i;s(),e.$api.imApi.isNoticeAPI({id:a.id,is_notice:1,is_group:a.is_group}),n.updateContact({id:a.id,is_notice:1})},icon:"el-icon-close-notification",text:"取消免打扰",visible:t=>0==t.contact.is_notice&&t.contact.is_group<2},{click(t,i,s){const{IMUI:n,contact:a}=i;s(),e.$confirm("确定删除该好友吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{e.$api.friendApi.delFriend({id:a.id}).then((t=>{0==t.code&&(e.$message({type:"success",message:"删除成功!"}),e.removeContact(a.id))}))})).catch((()=>{}))},icon:"el-icon-delete",color:"red",text:"删除好友",visible:t=>2==e.globalConfig.sysInfo.runMode&&0==t.contact.is_group},{click(t,i,s){const{IMUI:n,contact:a}=i;s(),e.$confirm("确定解散该群聊吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{e.$api.imApi.removeGrouprAPI({id:a.id})})).catch((()=>{}))},icon:"el-icon-delete",color:"red",text:"解散群聊",visible:t=>t.contact.owner_id==e.user.id&&1==t.contact.is_group},{click(t,i,s){const{IMUI:n,contact:a}=i;s(),e.$confirm("确定退出该群聊吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{e.$api.imApi.removeUserAPI({id:a.id,user_id:e.user.id}).then((t=>{0==t.code&&(e.$message({type:"success",message:"退出成功!"}),e.removeContact(a.id))}))})).catch((()=>{}))},icon:"el-icon-remove-outline",color:"red",text:"退出群聊",visible:t=>t.contact.owner_id!=e.user.id&&1==t.contact.is_group}],contextmenu:[{click:(e,i,s)=>{const{IMUI:n}=i,a=JSON.parse(JSON.stringify(i.message));this.$api.imApi.undoMessageAPI({id:a.id}).then((e=>{const i={id:a.id,type:"event",content:t("div",[t("span",["你撤回了一条消息"," ",t("span",{directives:[{name:"show",value:"text"==a.type}],style:"color:#409EFF;cursor:pointer",attrs:{content:a.content,data:a.type},on:{click:t=>{n.setEditorValue(t.target.getAttribute("content"))}}},["重新编辑"])])]),toContactId:a.toContactId,sendTime:a.sendTime};n.updateMessage(i);const s=n.getMessages(a.toContactId);a.id==s[s.length-1].id&&n.updateContact({id:a.toContactId,lastContent:"你撤回了一条消息"})})).catch((t=>{this.$message.error("发生错误"+t)})),s()},visible:t=>{const{IMUI:e,message:i}=t;let s=3;if(1==t.message.is_group){let t=e.getCurrentContact();s=t.role}return t.message.fromUser.id==this.user.id&&ke()-t.message.sendTime<1e3*this.globalConfig.chatInfo.redoTime||s<3},text:"撤回消息"},{text:"@TA",click:(t,e,i)=>{const{IMUI:s,message:n}=e;s.setUserTag(n.fromUser),i()},visible:t=>t.message.fromUser.id!=this.user.id&&1==t.message.is_group},{text:"转发",click:(t,e,i)=>{this.currentMessage=e.message;const{IMUI:s}=this.$refs,n=s.getContacts(),a=s.getCurrentContact();this.allUser=$.L4(n,"id",a.id),i(),this.forwardBox=!0}},{text:"引用",click:(t,e,i)=>{let s=e.message,n=/<[^>]+>/g,a=s.content.replace(n,"");"text"!=s.type&&(a=$.nZ(s.type));let r={msg_id:s.msg_id,content:s.fromUser.displayName+":"+a,user_id:s.fromUser.id,realname:s.fromUser.displayName};if(this.quote=r,this.is_group&&r.user_id!=this.user.id){const{IMUI:t}=this.$refs;t.setUserTag(s.fromUser)}i()}},{visible:t=>"image"==t.message.type,text:"复制图片",click:async(t,e,i)=>{i();try{const{message:t}=e,i=await fetch(t.download),s=await i.blob(),n=new Blob([s],{type:"image/png"}),a=new ClipboardItem({"image/png":n});await navigator.clipboard.write([a]),this.$message({type:"success",message:"图片复制成功!"})}catch(s){this.$message.error("复制图片失败: "+s)}}},{visible:t=>"text"==t.message.type,text:"复制文字",click:(t,e,i)=>{this.$clipboard(e.message.content),this.$message({type:"success",message:"复制成功!"}),i()}},{visible:t=>"image"==t.message.type,text:"下载图片",click:(t,e,i)=>{const{message:s}=e;i(),s.download&&(window.location=s.download)}},{visible:t=>"file"==t.message.type,text:"下载文件",click:(t,e,i)=>{const{message:s}=e;window.open(s.download),i()}},{text:"删除消息",color:"red",click:(t,e,i)=>{const{IMUI:s,message:n}=e;this.$confirm("删除消息会从所有人的聊天记录中抹掉,是否确定?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$api.imApi.delMessageAPI({id:n.id}).then((t=>{0==t.code&&(this.$message({type:"success",message:"删除成功!"}),s.removeMessage(n.id))}))})).catch((()=>{this.$message({type:"info",message:"已取消"})})),i()},visible:t=>t.message.fromUser.id==this.user.id&&t.message.is_group<2&&this.globalConfig.chatInfo.dbDelMsg}]}},computed:{...(0,v.rn)({wsStatus:t=>t.wsStatus,socketAction:t=>t.socketAction,contactId:t=>t.toContactId,contactSync:t=>t.contactSync,setting:t=>t.setting,userInfo:t=>t.userInfo,globalConfig:t=>t.globalConfig}),formatTime(){return function(t){return $.i$(t)}}},watch:{isFullscreen(t){o().set("isFullscreen",t),this.curWidth=t?"100vw":this.width,this.curHeight=t?"100vh":this.height},playAudio(t){if(t&&this.currentMessage){let t=this.currentMessage;var e=this;const{IMUI:i}=this.$refs;this.playAudio.addEventListener("ended",(function(){console.log("声音停止"),e.playAudio=null,e.currentMessage=null,i.updateMessage({id:t.id,status:"successd",isPlay:0})}),!1)}},contactSync(t){this.$emit("newChat",t);const{IMUI:e}=this.$refs;e.changeContact(this.contactId)},unread(t){this.tabList[1].count=t,this.$store.commit("updateUnread",t)},atUnread(t){this.tabList[2].count=t},keywords(){const{IMUI:t}=this.$refs,e=t.getContacts();this.searchContact(e)},socketAction(t){const e=this.$createElement;let i=t.data;const{IMUI:s}=this.$refs;let n=o().get("client_id");switch(t.type){case"isOnline":s.updateContact({id:i.id,is_online:i.is_online}),i.is_online||this.webrtcLock!=i.id||(this.webrtcLock=!1);break;case"offline":if(this.globalConfig.sysInfo.multipleLogin)return;i.id!=this.user.id||i.client_id==n||i.isMobile||(this.$message.error="您的账号在其他地方登录,已被迫下线!",this.$store.dispatch("LogOut").then((()=>{this.$router.push({path:"/login"})})));break;case"simple":case"group":if(i.fromUser.id!=this.user.id){let t=this.getContact(i.toContactId,i);if(1==i.is_group&&i.toContactId!=this.currentChat.id){let e=0;i.at.includes(this.user.id)&&(e=1),this.$refs.IMUI.updateContact({id:i.toContactId,is_at:t.is_at+e}),this.atUnread+=e}this.setting.isVoice&&1==t.is_notice&&i.toContactId!=this.currentChat.id&&this.popNotice(i)}this.recieveMsg(i);break;case"undoMessage":if(i.from_user==this.user.id&&0==i.isMobile&&ke()-i.sendTime<1e3*this.globalConfig.chatInfo.redoTime)return!1;s.updateMessage(i);const a=s.getMessages(i.toContactId);i.id==a[a.length-1].id&&s.updateContact({id:i.toContactId,lastContent:"对方撤回了一条消息"});break;case"delMessage":s.removeMessage(i.id);break;case"updateMessage":s.updateMessage(i);break;case"setChatTop":s.updateContact({id:i.id,is_top:i.is_top});break;case"setIsNotice":s.updateContact({id:i.id,is_notice:i.is_notice});break;case"editGroupName":s.updateContact({id:i.id,displayName:i.displayName});const r={id:$.NW(),type:"event",content:e("div",[e("span",[i.editUserName," 修改了群名为 ",i.displayName])]),toContactId:i.id,sendTime:ke()};s.appendMessage(r,!0);break;case"isRead":this.setLocalMsgIsRead(i);break;case"readAll":let c=s.getMessages(i.toContactId);c.forEach((t=>{if(0==t.is_read){const e={id:t.id,is_read:1,status:"succeed",sendTime:parseInt(t.sendTime)+1,content:t.content};s.updateMessage(e)}}));break;case"addGroup":i.owner_id!=this.user.id&&s.appendContact(i),this.$api.commonApi.bindGroupAPI({client_id:n,group_id:i.id});break;case"setManager":case"addGroupUser":case"removeUser":i.group_id==this.group_id&&this.getGroupUserList(i.group_id),"removeUser"==t.type&&i.user_id==this.user.id?this.removeContact(i.group_id):s.updateContact({id:i.group_id,avatar:i.avatar});break;case"setNoSpeak":i.group_id==this.group_id&&this.getGroupUserList(i.group_id);break;case"removeGroup":this.removeContact(i.group_id);break;case"clearMessage":s.clearMessages(i.group_id),this.groupSetting=!1,s.updateContact({id:i.group_id,lastContent:""}),i.group_id==this.currentChat.id&&(s.changeContact(null),setTimeout((()=>{s.changeContact(i.group_id)}),100));break;case"updateConfig":this.$store.commit("setGlobalConfig",i);break;case"setNotice":s.updateContact({id:i.group_id,notice:i.notice}),s.appendMessage({id:$.NW(),type:"event",content:e("div",[e("span",["管理员 发布了公告: ",i.notice])]),toContactId:i.group_id,sendTime:ke()},!0);break;case"groupSetting":s.updateContact({id:i.group_id,setting:i.setting}),this.currentChat.id==i.group_id&&(this.currentChat.setting=i.setting);break;case"appendContact":s.appendContact(i);break;case"webrtc":if(i.fromUser.id==this.user.id){let t=i.extends,e=o().get("wsData");return[902,903,905,906,907].includes(parseInt(t.code))&&(e.content=i.content,s.updateMessage(e),this.webrtcLock=!1),0==t.isMobile||"calling"==t.event?void("calling"==t.event&&(o().set("wsData",i),this.recieveMsg(i))):void("otherOpt"==t.event&&(e.content=i.content,s.updateMessage(e),this.wsData=null,this.caller="",this.webrtcLock=!1,this.$refs.webrtc.hangup(!1)))}if(this.wsData&&this.wsData.id!=i.id)this.$api.imApi.sendToMsg({toContactId:i.fromUser.user_id,type:i.extends.type,event:"busy",status:i.extends.status,code:907,id:i.id,msg_id:i.msg_id});else{if("calling"==i.extends.event)this.recieveMsg(i),this.wsData=i,o().set("wsData",i),this.caller=i.fromUser;else if("offer"==i.extends.event||"answer"==i.extends.event)this.webrtcLock=i.fromUser.user_id;else if("hangup"==i.extends.event){let t=o().get("wsData");t.content=i.content,s.updateMessage(t),this.webrtcLock=!1}this.wsData&&this.wsData.id==i.id&&this.$refs.webrtc.webrtcAction(JSON.parse(JSON.stringify(i)))}break}}},created(){let t=this.$store.state.userInfo;t&&(this.user={id:t.user_id,displayName:t.realname,avatar:t.avatar,account:t.account}),window.Notification?"granted"==Notification.permission?console.log("允许通知"):"denied"!=Notification.permission&&(console.log("需要通知权限"),Notification.requestPermission((t=>{}))):console.error("浏览器不支持Notification")},mounted(){this.fullScreen&&(this.isFullscreen=o().get("isFullscreen")),this.searchResult&&document.addEventListener("click",(function(t){that.$refs.configforms.contains(t.target)||(that.searchResult=!1)})),this.getSimpleChat()},methods:{called(t){return parseInt(this.globalConfig.chatInfo.webrtc)?this.globalConfig.chatInfo.simpleChat?void(this.webrtcLock?this.$message.error("其他端正在通话中"):(this.webrtcBox=!0,this.is_video=t,this.caller=this.currentChat,this.$refs.webrtc.called(t))):this.$message.error("当前系统已关闭单聊功能"):this.$message.error("当前系统未开启音视频通话功能")},changeTab(t,e){this.activeTab=e},latelyContact(t){let e=[];return e=1==this.activeTab?t.filter((t=>t.unread>0)):2==this.activeTab?t.filter((t=>t.is_at>0)):t.filter((t=>t.lastContent||t.unread>0)),e.sort(((t,e)=>e.lastSendTime-t.lastSendTime)),e.sort(((t,e)=>e.is_top-t.is_top)),e},getSimpleChat(t){const e=this.$createElement;this.$nextTick((()=>{const i=this.$refs.IMUI;this.IMUI=i,i.setLastContentRender("voice",(t=>"[语音]")),i.setLastContentRender("video",(t=>"[视频]")),i.setLastContentRender("webrtc",(t=>"[音视频通话]"));let s=[{name:"emoji"},{name:"screenShot",title:"发送截屏",click:()=>{this.shotScreen()},render:()=>e("i",{class:"el-icon el-icon-scissors f-18",style:"vertical-align: middle;font-weight: 600;"})},{name:"uploadImage",title:"发送图片"},{name:"sendVoice",title:"发送语音",click:()=>{this.VoiceStatus=!0},render:()=>e("i",{class:"el-icon el-icon-microphone f-18",style:"vertical-align: middle;font-weight: 600;"})},{name:"uploadVideo",title:"发送视频",click:()=>{var t=this.$refs.uploadVideo;t.click()},render:()=>e("i",{class:"el-icon el-icon-video-play f-18",style:"vertical-align: middle;font-weight: 600;"},[e("input",{style:"display:none",attrs:{type:"file",accept:"video/*"},ref:"uploadVideo",on:{change:t=>{this.uploadVideo(t)}}})])},{name:"uploadFile",title:"发送文件"},{name:"msgBox",title:"消息管理器",click:()=>{this.ChatRecordMap={},this.messageBox=!0,this.componentKey+=1},render:()=>e("i",{class:"el-icon el-icon-time f-18",style:"vertical-align: middle;"}),isRight:!0}];i.initEditorTools(s),i.initEmoji(F),this.$api.imApi.getContactsAPI().then((s=>{const n=s.data;this.contacts=n;var a={};if(n.forEach(((e,s)=>{e.type&&(a.type=e.type,a.content=e.lastContent,n[s]["lastContent"]=i.lastContentRender(a)),e.unread&&!t&&1==e.is_notice&&(this.unread+=e.unread),e.is_at&&(this.atUnread+=e.is_at)})),2==this.globalConfig.sysInfo.runMode){const t={id:"system",displayName:"新邀请",name_py:"xinyaoqing",avatar:xe,is_group:2,index:"[1]系统消息",click(t){t()},renderContainer:()=>e(Ce),lastSendTime:s.page,lastContent:s.page?"新的申请":"",unread:parseInt(s.count),is_notice:1};this.unread+=s.count,n.push({...t})}this.$store.commit("initContacts",n),i.initContacts(n),this.lastMessages=i.lastMessages,this.initMenus(i)}))}))},shotScreen(){new we.Z({enableWebRtc:!0,level:999999,completeCallback:this.callback,closeCallback:this.closeShotScreen})},closeShotScreen(){console.log("关闭截图")},callback(t){let e=new Image;e.src=t.base64,e.onload=()=>{let t=this.convertImageToCanvas(e),i=t.toDataURL("image/jpeg"),s=window.atob(i.split(",")[1]),n=new ArrayBuffer(s.length),a=new Uint8Array(n);for(let e=0;e<s.length;e++)a[e]=s.charCodeAt(e);let r=new File([n],"screenShot"+$.NW()+".jpg",{type:"image/jpeg"});this.$confirm("<img src="+e.src+' style="width:390px;height:100%;max-height:360px;object-fit:contain">',"发送截图",{dangerouslyUseHTMLString:!0,confirmButtonText:"发送",showCancelButton:!0,callback:(t,e)=>{if("confirm"==t){let t={content:URL.createObjectURL(r),fromUser:this.user,id:$.NW(),sendTime:ke(),status:"going",toContactId:this.currentChat.id,type:"image"};this.diySendMessage(t,r)}else e.close()}})}},convertImageToCanvas(t){let e=document.createElement("canvas");return e.width=t.width,e.height=t.height,e.getContext("2d").drawImage(t,0,0),e},initMenus(t){const e=this.$createElement;let i=[{name:"messages",unread:this.unread},{name:"contacts"},{name:"files",title:"文件",unread:0,render:t=>e("i",{class:"el-icon-folder"}),renderContainer:()=>e(Nt,{attrs:{title:this.dialogTitle}})},{name:"mobile",title:"客户端下载",unread:0,render:t=>e("i",{class:"el-icon-mobile"}),click:()=>{window.open(window.BASE_URL+"downapp","_blank")},isBottom:!0},{name:"setting",title:"设置",unread:0,render:t=>e("i",{class:"el-icon-setting"}),renderContainer:()=>e(Gt),isBottom:!0}];this.fullScreen&&i.push({name:"fullscrren",title:"全屏/窗口",unread:0,click:()=>{this.isFullscreen=!this.isFullscreen},render:t=>e("i",{class:"el-icon-full-screen"})}),(Ie.role>0||this.globalConfig.demon_mode)&&i.push({name:"manage",title:"后台管理",unread:0,click:()=>{this.$route.path.indexOf("manage")>-1?this.$emit("close"):this.$router.push("/manage/index")},render:t=>e("i",{class:"el-icon-s-operation"}),isBottom:!0}),t.initMenus(i)},getContact(t,e=null){const{IMUI:i}=this.$refs;let s=i.findContact(t);return!s&&e&&e.contactInfo&&(s=e.contactInfo,i.appendContact(s)),s},wrapKey(t){return 1==this.setting.sendKey?13==t.keyCode&&t.ctrlKey:13==t.keyCode&&!t.ctrlKey&&!t.shiftKey},setSendKey(t){return 1==this.setting.sendKey?13==t.keyCode&&!t.ctrlKey&&!t.shiftKey:13==t.keyCode&&t.ctrlKey},handleMessageClick(t,e,i,s){if("status"==e)return s.updateMessage({id:i.id,status:"going"}),i.status="going",void this.diySendMessage(i,this.curFile);if("avatar"!=e){if("voice"==i.type){if(!this.playAudio)return this.currentMessage=i,this.playVoice(i,s);this.playAudio.pause(),this.playAudio=null,s.updateMessage({id:this.currentMessage.id,status:"successd",isPlay:0}),i.id!=this.currentMessage.id&&(this.currentMessage=i,this.playVoice(i,s))}var n=["image","file","video"];if(n.includes(i.type)){if(!i.preview)return this.$message.error("没有配置预览接口");this.$preview(i.preview)}else"webrtc"==i.type&&this.called(parseFloat(i.extends.type))}else{if(1==i.is_group&&0==this.currentChat.setting.profile&&this.currentChat.role>2)return void this.$message.error("已开启隐私,无法查看资料");if(i.fromUser.id==this.user.id)return;this.$user(i.fromUser.id)}},playVoice(t,e){this.playAudio=new Audio(t.content),this.playAudio.play(),e.updateMessage({id:t.id,status:"succeed",isPlay:1})},openChat(t,e){this.keywords="",e.changeContact(t)},handleChangeContact(t,e){e.updateContact({id:t.id,unread:0}),1==t.is_notice&&(this.unread-=t.unread);const{IMUI:i}=this.$refs;this.initMenus(i),this.params.page=1,this.displayName=t.displayName,this.oldName=t.displayName,this.currentChat=t,1==t.is_group&&(this.group_id!=t.id?this.getGroupUserList(t.id):this.setAtUserList(this.groupUser)),this.is_group=t.is_group,1==this.is_group?(this.group_id=t.id,this.notice=t.notice):i.setAtUserList([],!1);for(var s=[],n=i.getMessages(t.id),a=0;n.length>a;a++)0==n[a].is_read&&n[a].fromUser.id!=this.user.id&&(n[a]["contactInfo"]={},s.push(n[a]));s.length>0&&(this.$api.imApi.setMsgIsReadAPI({is_group:t.is_group,toContactId:t.id,messages:s,fromUser:t.id}),this.setLocalMsgIsRead(s)),e.closeDrawer()},setAtUserList(t){let e=[],i=!1;t.forEach((t=>{t.user_id!=this.user.id?e.push(t.userInfo):t.role<3&&(i=!0)})),this.$refs.IMUI.setAtUserList(e,i)},uploadVideo(t){if(!this.nospeak())return this.$message.error(this.noSimpleTips),!1;let e,i=t.srcElement.files[0],s=URL.createObjectURL(i),n=new Audio(s);n.addEventListener("loadedmetadata",(function(t){e=n.duration}));let a={content:s,fromUser:this.user,id:$.NW(),sendTime:ke(),status:"going",toContactId:this.currentChat.id,type:"video",extends:{duration:e}};this.diySendMessage(a,i),this.$refs.uploadVideo.value=""},sendVoice(t,e){if(!this.globalConfig.chatInfo.simpleChat&&0==this.is_group||!this.nospeak())return this.$message.error(this.noSimpleTips),!1;let i={content:URL.createObjectURL(e),fromUser:this.user,id:$.NW(),sendTime:ke(),status:"going",toContactId:this.currentChat.id,type:"voice",isPlay:0,extends:{duration:t}};this.VoiceStatus=!1,this.diySendMessage(i,e)},removeContact(t){const{IMUI:e}=this.$refs,i=e.getCurrentContact();i.id==t&&e.changeContact(null),e.removeContact(t)},diySendMessage(t,e){const{IMUI:i}=this.$refs;i.appendMessage(t,!0),this.handleSend(t,(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{status:"succeed"};i.updateContact({id:t.toContactId,lastContent:i.lastContentRender(t),lastSendTime:t.sendTime}),i.CacheDraft.remove(t.toContactId),i.updateMessage(Object.assign(t,e))}),e)},nospeak(){return!(1==this.is_group&&this.currentChat.setting.nospeak>0)||(1==this.currentChat.setting.nospeak&&this.currentChat.role<3||2==this.currentChat.setting.nospeak&&1==this.currentChat.role)},handleSend(t,e,i){const{IMUI:s}=this.$refs;if(t.is_group=this.is_group,this.curFile=i,!this.nospeak())return s.removeMessage(t.id),this.$message.error(this.noSimpleTips),!1;this.quote&&(t.pid=this.quote.msg_id,t.extends=this.quote);let n=new FormData;if(i){if(i.size>1024*this.globalConfig.fileUpload.size*1024)return s.removeMessage(t.id),this.$message.error("上传的内容不等大于"+this.globalConfig.fileUpload.size+"MB!");n.append("file",i),n.append("message",JSON.stringify(t)),this.$api.imApi.sendFileAPI(n).then((t=>{0==t.code?(s.setEditorValue(""),s.updateMessage(t.data),e()):e({status:"failed"})})).catch((t=>{e({status:"failed"})}))}else this.closeQuote(),this.$api.imApi.sendMessageAPI(t).then((t=>{0==t.code?(s.setEditorValue(""),s.updateMessage(t.data),e()):e({status:"failed"})})).catch((t=>{e({status:"failed"})}))},handlePullMessages(t,e,i){let s=this.params,n=i.getMessages(t.id);return n.length>0?(s.last_id=n[0].msg_id,s.page=1):s.last_id=0,s.toContactId=t.id,s.is_group=t.is_group,this.$api.imApi.getMessageListAPI(s).then((t=>{this.params.page++;let i=!1,s=t.data;s.length<this.params.limit&&(i=!0),e(s,i)})).catch((t=>{e([],!0)})),!0},publishNotice(){this.noticeBox=!1,this.$api.imApi.setNoticeAPI({id:this.group_id,notice:this.notice}).then((t=>{0==t.code&&this.$message({type:"success",message:"发布成功!"})}))},openMsgBox(){this.ChatRecordMap={is_at:1},this.messageBox=!0,this.componentKey+=1,this.$refs.IMUI.updateContact({id:this.currentChat.id,is_at:0});let t=this.currentChat.is_at;this.atUnread-=t,this.currentChat.is_at=0},openNotice(){var t="<div style='white-space: break-spaces;'>"+this.notice+"</div>";this.$alert(t,"群公告",{confirmButtonText:"确定",dangerouslyUseHTMLString:!0}).then((()=>{})).catch((()=>{}))},openCreateGroup(){this.isAdd=1,this.dialogTitle="创建群聊",this.userIds=[],this.createChatBox=!0},changeOwner(){this.isAdd=2,this.dialogTitle="转让群聊",this.createChatBox=!0},openAddGroupUser(){var t=$.Nj(this.groupUser,"user_id");this.isAdd=0,this.userIds=t,this.dialogTitle="添加群成员",this.createChatBox=!0},manageGroup(t,e,i){this.createChatBox=!1;let s=this.globalConfig.chatInfo.groupUserMax;if(0==e){if(t.length+this.groupUser.length>s&&s>0)return this.$message.error("群成员不能大于"+s+"人!");this.$api.imApi.addGroupUserAPI({user_ids:t,id:this.group_id})}else if(1==e){if(t.length>s&&s>0)return this.$message.error("群成员不能大于"+s+"人!");this.$api.imApi.addGroupAPI({user_ids:t,name:i}).then((t=>{const e=t.data,{IMUI:i}=this.$refs;0==t.code&&(i.appendContact(e),i.changeContact(e.id))}))}else this.$api.imApi.changeOwnerAPI({user_id:t[0],id:this.group_id}).then((e=>{const{IMUI:i}=this.$refs;0==e.code&&(this.$message({type:"success",message:e.msg}),this.groupSetting=!1,i.updateContact({id:this.group_id,role:3,owner_id:t[0]}),i.changeContact(null))}))},forwardUser(t){if(t.length>5)return this.$message.error("转发的人数不能超过5人!");this.forwardBox=!1;var e=this.currentMessage;this.$api.imApi.forwardMessageAPI({user_ids:t,msg_id:e.msg_id})},getGroupUserList(t){this.$api.imApi.groupUserListAPI({group_id:t}).then((t=>{if(0==t.code){let e=t.data;this.groupUser=e,this.setAtUserList(e),this.groupUserCount=e.length}}))},saveGroupName(t){if(this.displayName.length<1)return this.$notify({title:"警告",message:"名称不能为空!",type:"warning"}),this.isEdit=!1,!1;if(this.displayName!=this.oldName){const{IMUI:e}=this.$refs;this.$api.imApi.editGroupNameAPI({id:t.id,displayName:this.displayName}).then((i=>{e.updateContact({id:t.id,displayName:this.displayName})}))}this.isEdit=!1},openGroupSetting(t){this.groupSetting=!0,this.contactSetting=t||this.currentChat,this.componentKey++},closeSearch(){var t=this;setTimeout((function(){t.searchResult=!1}),300)},searchContact(t){""!=this.keywords&&(this.searchList=$.iu(t,["displayName","name_py"],this.keywords))},setLocalMsgIsRead(t){const{IMUI:e}=this.$refs;for(let i=0;t.length>i;i++){const s={id:t[i]["id"],is_read:1,status:"succeed",sendTime:parseInt(t[i]["sendTime"])+1,content:t[i]["content"]};e.updateMessage(s)}},popNotice(t){let e=this;const{IMUI:i}=this.$refs;if("granted"==Notification.permission){let s=t.fromUser.displayName||t.fromUser.realname,n=i.lastContentRender(t),a=new Notification("收到一条新消息",{body:s+":"+n,icon:t.fromUser.avatar});a.onclick=function(t){e.$nextTick((()=>{setTimeout((()=>{}),500)})),window.focus(),a.close()}}else{const t=document.getElementById("chatAudio");t.currentTime=0,t.play()}},recieveMsg(t){const{IMUI:e}=this.$refs,i=e.getCurrentContact();if(i.id==t.toContactId&&"system"!=i.id){var s=[];s.push(t),this.$api.imApi.setMsgIsReadAPI({toContactId:i.id,is_group:i.is_group,messages:s,fromUser:t.fromUser.id})}else if(this.user.id!=t.fromUser.id){let i=this.getContact(t.toContactId);1==i.is_notice&&this.unread++,this.initMenus(e)}this.user.id==t.toContactId&&(t.toContactId=t.toUser),"system"==t.toContactId&&e.updateContact({id:t.toContactId,lastContent:e.lastContentRender(t),lastSendTime:t.sendTime,unread:"+1"}),e.appendMessage(t,this.isBottom)},openMessageBox(){this.messageBox=!0,this.componentKey+=1},openSetting(){const{IMUI:t}=this.$refs;t.changeMenu("setting")},setNoSpeak(){this.noSpeakBox=!1,this.$api.imApi.setNoSpeakAPI(this.noSpeakData)},handleCommand(t){"addGroup"==t?this.openCreateGroup():this.addFriendBox=!0},rtcMsg(t){let e="",i="",s="";this.wsData&&(i=this.wsData.msg_id??"",s=this.wsData.id??"");let n=!0;switch(t.event){case"calling":s=$.NW();break;case"hangup":907==t.code&&this.$message.error("对方忙线中"),t.isbtn||(n=!1),this.wsData="",this.webrtcLock=!1;break;case"iceCandidate":let i={};i["candidate"]=t["iceCandidate"]["candidate"],i["sdpMLineIndex"]=t["iceCandidate"]["sdpMLineIndex"],i["sdpMid"]=t["iceCandidate"]["sdpMid"],e=JSON.stringify(i);break;case"mediaDevices":n=!1;break}n&&this.$api.imApi.sendToMsg({id:s,msg_id:i,toContactId:this.caller.id,type:this.is_video?1:0,event:t.event,status:t.status??"",code:t.code??"",callTime:t.callTime??"",sdp:t.sdp??"",iceCandidate:e}).then((e=>{0==e.code&&"calling"==t.event&&(this.wsData=e.data,o().set("wsData",e.data),this.recieveMsg(e.data)),"907"==e.data.extends.code&&this.$message.error("对方不在线")}))},reconnect(){this.$refs.socket.initWebSocket()},closeSocket(){this.$refs.socket.close()},closeQuote(){this.quote=""},noSpeakExp(t){return 1e3*t>(new Date).getTime()&&$.hT("m-d H:i",t)},eventBottom(t){this.isBottom=t},logout(){this.$confirm("你确定要退出聊天室吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$store.dispatch("LogOut").then((()=>{this.$router.push({path:"/login"})}))})).catch((()=>{this.$message({type:"info",message:"已取消退出"})}))}}},_e=Ae,Ee=(0,d.Z)(_e,j,R,!1,null,"6c5c2dba",null),Se=Ee.exports;var Te={name:"app",components:{rainagdIm:Se},props:{dialogTableVisible:{type:Boolean,default:!1}},data(){return{unread:0,dialogIsShow:!0}},computed:{formatTime(){return function(t){return timeFormat(t)}}},watch:{dialogTableVisible(t){t&&this.$nextTick((()=>{this.dialogIsShow=t}))}},created(){},mounted(){},methods:{closeDialog(){this.appList=!1,this.$nextTick((()=>{this.$emit("update:dialogTableVisible",!1)}))},contactSync(t){this.dialogIsShow=!0,this.$emit("update:dialogTableVisible",!0)}}},Ne=Te,Me=(0,d.Z)(Ne,D,P,!1,null,"6e7fdceb",null),Le=Me.exports,Ue={name:"Index",components:{Message:Le},data(){return{dialogTableVisible:!1,unread:0,allContacts:[],activeName:"0",techStack:[{icon:"el-icon-cpu",text:"后端:TP6+Mysql+workerman+webRTC中继服务。 <b class='c-success'>[开源]</b>"},{icon:"el-icon-news",text:"前端:vue2+element-ui+lemon-imui。 <b class='c-success'>[开源]</b>"},{icon:"el-icon-mobile",text:"移动端:uniapp for vue3+pinia。支持编译为小程序+h5+APP。<b class='c-red'>[联系作者,捐赠获取]</b>"},{icon:"el-icon-monitor",text:"桌面端:vue2(web端修改版)+electron。<b class='c-red'>[联系作者,捐赠获取]</b>"}],introduce:[{icon:"el-icon-chat-dot-square",text:this.$packageData.name+"是一个<b class='c-red'>开源的即时通信demo(存在一定的BUG),主要用于学习交流,为大家提供即时通讯的开发思路</b>,许多功能需要自行开发,开发的初衷旨在快速建立企业内部通讯系统、内网交流、社交交流。"},{icon:"el-icon-cpu",text:"不建议用于商业用途,如确有需要商用,请联系作者授权,自行开发代码量必须要高于原代码量的30%以上,并注明相关的版权问题。"},{icon:"el-icon-office-building",text:"支持企业模式:类似于企业微信,初始化联系人是加载企业内的所有人员,无须加好友可以直接进行对话、创建群聊等,适用于企业内部通讯。"},{icon:"el-icon-chat-line-round",text:"支持社交模式:类似于微信或QQ,需要添加好友才能进行对话,适用于社交交流。社交模式支持加好友、删除好友、改备注等功能。"},{icon:"el-icon-discover",text:"选择适合自己项目的模式,然后在后台设置即可。社交模式体验需要自行搭建部署哦,可以在项目地址中看到相关的截图。"}]}},computed:{...(0,v.rn)({chatSocket:t=>t.unread,getContacts:t=>t.allContacts})},watch:{chatSocket(t){this.unread=t},getContacts(t){this.allContacts=t}},methods:{handleClick(t,e){console.log(t,e)},showMessageBox(){this.dialogTableVisible?this.dialogTableVisible=!1:this.dialogTableVisible=!0},scrollTo(){window.scrollTo(0,document.body.scrollHeight)},downApp(){window.open(window.BASE_URL+"downapp")}}},Oe=Ue,De=(0,d.Z)(Oe,U,O,!1,null,"2b35c012",null),Pe=De.exports,je=function(){var t=this,e=t._self._c;return e("div",{staticClass:"main-container",style:"background-image:url("+t.Background+")"},[e("raingadIm",{attrs:{fullScreen:!0}})],1)},Re=[],Be=i.p+"assets/img/login-background.4d69904c.jpg",Fe={name:"app",components:{raingadIm:Se},data(){return{Background:Be}}},$e=Fe,He=(0,d.Z)($e,je,Re,!1,null,"f0e47f02",null),Ve=He.exports,Ge=function(){var t=this,e=t._self._c;return e("div",{staticClass:"login-wrapper",style:"background-image:url("+t.Background+")"},[e("div",{staticClass:"form-box"},[e("div",{staticClass:"form-title"},[e("img",{attrs:{src:t.globalConfig.sysInfo.logo?t.globalConfig.sysInfo.logo:t.$packageData.logo,width:"100",alt:"icon"}}),e("p",{staticClass:"mt-10 f-20"},[t._v(t._s(t.globalConfig.sysInfo.name))])]),e("el-form",{ref:"loginForm",staticClass:"login-form",attrs:{model:t.loginForm,rules:t.loginRules,"label-width":"0px"}},[e("el-form-item",{attrs:{prop:"account"}},[e("el-input",{ref:"account",attrs:{type:"text","auto-complete":"off",placeholder:"请输入账号","prefix-icon":"el-icon-user"},model:{value:t.loginForm.account,callback:function(e){t.$set(t.loginForm,"account",e)},expression:"loginForm.account"}})],1),e("el-form-item",{directives:[{name:"show",rawName:"v-show",value:!t.forget,expression:"!forget"}],attrs:{prop:"password"}},[e("el-input",{attrs:{type:"password","auto-complete":"off",placeholder:"请输入密码","prefix-icon":"el-icon-lock"},nativeOn:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.handleLogin.apply(null,arguments)}},model:{value:t.loginForm.password,callback:function(e){t.$set(t.loginForm,"password",e)},expression:"loginForm.password"}})],1),e("el-form-item",{directives:[{name:"show",rawName:"v-show",value:t.forget,expression:"forget"}],attrs:{prop:"code"}},[e("el-input",{attrs:{placeholder:"请输入验证码",maxlength:"6"},model:{value:t.loginForm.code,callback:function(e){t.$set(t.loginForm,"code",e)},expression:"loginForm.code"}},[e("el-button",{attrs:{slot:"append",loading:t.coding},on:{click:function(e){return t.sendCode()}},slot:"append"},[t._v("发送验证码")])],1)],1),t.globalConfig.demon_mode?e("div",{staticClass:"c-666",staticStyle:{"font-size":"12px"}},[t._v("演示账号:13800000002~13800000020,密码:123456")]):t._e(),e("el-form-item",[e("div",{staticClass:"remenber"},[e("el-checkbox",{model:{value:t.loginForm.rememberMe,callback:function(e){t.$set(t.loginForm,"rememberMe",e)},expression:"loginForm.rememberMe"}},[t._v("记住我")]),e("el-button",{attrs:{type:"text"},on:{click:function(e){t.forget=!t.forget}}},[t._v(t._s(t.forget?"密码登陆":"忘记密码"))])],1)]),e("el-form-item",[e("el-button",{staticStyle:{width:"100%"},attrs:{loading:t.loading,size:"small",type:"primary"},nativeOn:{click:function(e){return e.preventDefault(),t.handleLogin.apply(null,arguments)}}},[t.loading?e("span",[t._v("登 录 中...")]):e("span",[t._v("登 录")])])],1),1==t.globalConfig.sysInfo.regtype?e("el-form-item",[e("el-button",{staticStyle:{width:"100%"},attrs:{size:"small",plain:""},on:{click:function(e){return t.$router.push("/register")}}},[t._v(" 注册 ")])],1):t._e(),e("div",{staticClass:"c-999",attrs:{align:"center"}},[t._v(t._s(t.globalConfig.sysInfo.name)+" for "+t._s(t.$packageData.version))]),e("el-button",{staticClass:"mt-10",staticStyle:{width:"100%"},attrs:{plain:""},on:{click:function(e){return t.downapp()}}},[e("span",[t._v("下载客户端")])])],1)],1)])},Ke=[],ze={name:"Login",data(){return{Background:Be,forget:!1,loginForm:{account:"",password:"",code:"",rememberMe:!0},loginRules:{account:[{required:!0,trigger:"blur",message:"用户名不能为空"}],password:[{required:!0,trigger:"blur",message:"密码不能为空"}]},loading:!1,coding:!1,redirect:void 0}},computed:{...(0,v.rn)({globalConfig:t=>t.globalConfig})},watch:{$route:{handler:function(t){this.redirect=t.query&&t.query.redirect},immediate:!0},forget(t){t&&(this.loginForm.password="123456")}},mounted(){this.$nextTick((()=>{let t=this.$route.query.token;if(t)return this.dologin({token:t});if(this.globalConfig.demon_mode){const t=Math.floor(19*Math.random()+2);this.loginForm.account=138e8+t,this.loginForm.password="123456",this.$refs.account.focus()}const e=o().get("LoginAccount");e&&(this.loginForm.account=e.account,this.loginForm.password=e.password,this.loginForm.rememberMe=!0,this.$refs.account.focus())}))},methods:{handleLogin(){!this.forget||this.loginForm.code?this.$refs.loginForm.validate((t=>{const e={account:this.loginForm.account,password:this.loginForm.password,code:this.loginForm.code};this.loginForm.rememberMe?o().set("LoginAccount",e):o().rm("LoginAccount"),t&&this.dologin(e)})):this.$message.error("请输入验证码")},dologin(t){this.loading=!0,this.$store.dispatch("Login",t).then((t=>{window.location.reload()})).catch((()=>{this.loading=!1}))},sendCode(){if(!this.loginForm.account)return void this.$message.error("请输入账号");this.coding=!0;let t={account:this.loginForm.account,type:1};this.$store.dispatch("sendCode",t).then((t=>{this.$message.success("发送成功"),this.coding=!1})).catch((()=>{this.coding=!1}))},downapp(){window.open(window.BASE_URL+"downapp")}}},Qe=ze,Ye=(0,d.Z)(Qe,Ge,Ke,!1,null,null,null),Je=Ye.exports,qe=function(){var t=this,e=t._self._c;return e("div",{staticClass:"login-wrapper",style:"background-image:url("+t.Background+")"},[e("div",{staticClass:"form-box"},[e("div",{staticClass:"form-title"},[e("div",{staticClass:"f-14 cur-handle",on:{click:function(e){return t.$router.push("/login")}}},[e("i",{staticClass:"el-icon-back"},[t._v("返回")])]),t._m(0),e("div")]),e("el-form",{ref:"regForm",staticClass:"login-form",attrs:{model:t.regForm,rules:t.loginRules,"label-width":"0px"}},[e("el-form-item",{attrs:{prop:"account"}},[e("el-input",{ref:"account",attrs:{type:"text","auto-complete":"off",placeholder:t.placeholder,"prefix-icon":"el-icon-user"},on:{input:t.handleInput},model:{value:t.regForm.account,callback:function(e){t.$set(t.regForm,"account",e)},expression:"regForm.account"}})],1),e("el-form-item",{attrs:{prop:"realname"}},[e("el-input",{ref:"realname",attrs:{type:"text","auto-complete":"off",placeholder:"请输入用户名/昵称","prefix-icon":"el-icon-user"},model:{value:t.regForm.realname,callback:function(e){t.$set(t.regForm,"realname",e)},expression:"regForm.realname"}})],1),0!=t.globalConfig.sysInfo.regauth?e("el-form-item",{attrs:{prop:"code"}},[e("el-input",{attrs:{placeholder:"请输入验证码",maxlength:"6"},model:{value:t.regForm.code,callback:function(e){t.$set(t.regForm,"code",e)},expression:"regForm.code"}},[e("el-button",{attrs:{slot:"append",loading:t.loading},on:{click:function(e){return t.sendCode(!0)}},slot:"append"},[t._v("发送验证码")])],1)],1):t._e(),e("el-form-item",{attrs:{prop:"password"}},[e("el-input",{attrs:{type:"password","show-password":"","auto-complete":"off",placeholder:"请输入密码","prefix-icon":"el-icon-lock"},model:{value:t.regForm.password,callback:function(e){t.$set(t.regForm,"password",e)},expression:"regForm.password"}})],1),e("el-form-item",{attrs:{prop:"password"}},[e("el-input",{attrs:{type:"password","show-password":"","auto-complete":"off",placeholder:"请再次输入密码","prefix-icon":"el-icon-lock"},model:{value:t.regForm.repass,callback:function(e){t.$set(t.regForm,"repass",e)},expression:"regForm.repass"}})],1),e("el-form-item",[e("el-button",{staticStyle:{width:"100%"},attrs:{loading:t.loading,size:"small",type:"primary"},nativeOn:{click:function(e){return e.preventDefault(),t.handleRegist.apply(null,arguments)}}},[t.loading?e("span",[t._v("注 册 中...")]):e("span",[t._v("注册")])])],1),e("div",{staticClass:"c-999",attrs:{align:"center"}},[t._v(t._s(t.globalConfig.sysInfo.name)+" for "+t._s(t.$packageData.version))])],1)],1)])},We=[function(){var t=this,e=t._self._c;return e("div",{staticClass:"mr-40"},[e("b",[t._v("注册用户")])])}],Ze={name:"Register",data(){return{Background:Be,placeholder:"请输入账号:4-32个字符",regForm:{account:"",realname:"",password:"",repass:"",code:""},loginRules:{account:[{min:4,max:32,message:"长度在 4 到 32 个字符",trigger:"blur"}],realname:[{required:!0,message:"请输入用户名/昵称",trigger:"blur"},{min:2,max:16,message:"长度在 2 到 16 个字符",trigger:"blur"}],password:[{required:!0,message:"请输入密码",trigger:"blur"},{min:6,max:16,message:"长度在 6 到 16 个字符",trigger:"blur"}]},loading:!1,redirect:void 0}},computed:{...(0,v.rn)({globalConfig:t=>t.globalConfig})},watch:{$route:{handler:function(t){this.redirect=t.query&&t.query.redirect},immediate:!0}},mounted(){let t=this.globalConfig.sysInfo.regauth??0,e="请输入账号:4-32个字符";switch(parseInt(t)){case 1:e="请输入正确的手机号";break;case 2:e="请输入正确的邮箱";break;case 3:e="请输入正确的手机号或者邮箱";break;default:e="请输入正确的账号"}let i={required:!0,message:e,trigger:"blur"};this.loginRules.account.push(i);let s={type:"email",message:e,trigger:"blur",validator:this.validateContact},n={type:"phone",message:e,trigger:"blur",validator:this.validateContact};1==t?(this.placeholder="请输入手机号",this.loginRules.account.push(n)):2==t?(this.placeholder="请输入邮箱账号",this.loginRules.account.push(s)):3==t&&(this.placeholder="请输入手机号/邮箱",this.loginRules.account.push(s),this.loginRules.account.push(n))},methods:{handleInput(t){const e=t.replace(/[\u4e00-\u9fa5]/g,"");this.regForm.account=e},validateContact(t,e,i){e?/^1[3456789]\d{9}$/.test(e)||/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/.test(e)?i():i(new Error("请输入正确的手机号或邮箱")):i()},handleRegist(){this.$refs.regForm.validate((t=>{if(this.regForm.password!=this.regForm.repass)return this.$message.error("两次密码不一致"),!1;const e={account:this.regForm.account,realname:this.regForm.realname,password:this.regForm.password,code:this.regForm.code,inviteCode:this.$route.query.inviteCode??""};if(!t)return this.$message.error("请检查输入项");this.loading=!0,this.$api.commonApi.register(e).then((t=>{this.loading=!1,0===t.code&&(this.$message.success("注册成功"),this.$router.push("/login"))})).catch((t=>{this.loading=!1}))}))},sendCode(){if(!this.regForm.account)return void this.$message.error("请输入账号");this.coding=!0;let t={account:this.regForm.account,type:2};this.$store.dispatch("sendCode",t).then((t=>{this.$message.success("发送成功"),this.coding=!1})).catch((()=>{this.coding=!1}))}}},Xe=Ze,ti=(0,d.Z)(Xe,qe,We,!1,null,"021f4740",null),ei=ti.exports,ii=function(){var t=this,e=t._self._c;return e("div",{staticClass:"main-container"},[e("el-container",{staticStyle:{height:"100vh",border:"1px solid #eee"}},[e("el-header",{staticStyle:{"text-align":"right","font-size":"12px","border-bottom":"1px solid #e6e6e6"}},[e("el-row",{style:{height:"60px"},attrs:{type:"flex",justify:"space-between",align:"middle"}},[e("el-col",{staticClass:"logo",attrs:{span:8}},[e("div",{staticClass:"image"},[e("img",{attrs:{src:t.globalConfig.sysInfo.logo,alt:"logo"}})]),e("div",{staticClass:"f-20 ml-5"},[t._v(t._s(t.globalConfig.sysInfo.name)+" 管理中心")])]),e("el-col",{staticClass:"text-right",attrs:{span:16}},[e("div",{staticClass:"user"},[e("span",{staticClass:"message"},[e("router-link",{attrs:{to:"/chat"}},[e("el-button",[t._v(" 进入聊天 ")])],1)],1),e("span",{staticClass:"message",on:{click:function(e){return t.showMessageBox()}}},[e("el-badge",{attrs:{value:t.unread,max:99,hidden:!t.unread}},[e("i",{staticClass:"el-icon-chat-line-round f-24",attrs:{circle:""}})])],1),e("el-dropdown",{attrs:{trigger:"click"},on:{command:t.handleCommand}},[e("div",{staticClass:"lz-flex lz-align-items-center cur-handle"},[e("span",{staticClass:"avatar"},[e("img",{attrs:{src:t.$store.state.userInfo.avatar,alt:"avatar"}})]),e("span",{staticClass:"username"},[t._v(t._s(t.$store.state.userInfo.realname))]),e("i",{staticClass:"el-icon-arrow-down el-icon--right"})]),e("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},[e("el-dropdown-item",{attrs:{command:"profile"}},[t._v("个人信息")]),e("el-dropdown-item",{attrs:{command:"logout"}},[t._v("退出登录")])],1)],1)],1)])],1)],1),e("el-container",[e("el-aside",{staticClass:"main-aside",style:{width:t.asideWidth}},[e("div",{staticClass:"aside-menu"},[e("el-scrollbar",[e("el-menu",{staticClass:"el-menu-vertical-demo",staticStyle:{border:"none"},attrs:{"default-active":t.active,mode:"vertical","ext-color":"#fff",collapse:t.isCollapse},on:{select:t.handleMenuSelect}},[t._l(t.routes,(function(i,s){return[e("el-menu-item",{key:s,attrs:{index:i.path}},[e("i",{class:i.meta.icon}),e("span",{attrs:{slot:"title"},slot:"title"},[t._v(t._s(i.meta.title))])])]}))],2)],1)],1),e("div",{staticClass:"aside-bottom",on:{click:t.handleCollapse}},[e("span",{staticClass:"el-icon-s-fold f-18"})])]),e("el-main",{staticStyle:{"background-color":"#f5f5f5",padding:"0"}},[e("el-scrollbar",[e("transition",{attrs:{name:"fade",mode:"out-in"}},[e("router-view",{key:t.key})],1)],1)],1)],1)],1),e("Message",{ref:"Message",attrs:{dialogTableVisible:t.dialogTableVisible},on:{"update:dialogTableVisible":function(e){t.dialogTableVisible=e},"update:dialog-table-visible":function(e){t.dialogTableVisible=e}}})],1)},si=[],ni={name:"Index",components:{Message:Le},data(){return{dialogTableVisible:!1,unread:0,allContacts:[],isCollapse:!1,asideWidth:"200px",active:"",routes:[]}},computed:{...(0,v.rn)({chatSocket:t=>t.unread,getContacts:t=>t.allContacts,globalConfig:t=>t.globalConfig}),key(){return this.$route.path}},watch:{chatSocket(t){this.unread=t},getContacts(t){this.allContacts=t},isCollapse(t){this.asideWidth=t?"65px":"200px"}},mounted(){this.isCollapse=o().get("isCollapse")||!1,this.active=this.$route.path;const t=this.$router.options.routes.filter((t=>"manage"==t.name));this.routes=t[0].children,window.addEventListener("resize",this.handleResize)},methods:{handleResize(){window.innerWidth<900?this.isCollapse=!0:this.isCollapse=!1},handleMenuSelect(t){this.active=t,this.$route.path!=t&&this.$router.push(t)},showMessageBox(){this.dialogTableVisible?this.dialogTableVisible=!1:this.dialogTableVisible=!0},handleCommand(t){"profile"==t?this.$user(this.$store.state.userInfo.user_id):this.$confirm("你确定要退出聊天室吗?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{this.$store.dispatch("LogOut").then((()=>{this.$router.push({path:"/login"})}))})).catch((()=>{this.$message({type:"info",message:"已取消退出"})}))},handleCollapse(){this.isCollapse=!this.isCollapse,o().set("isCollapse",this.isCollapse)}}},ai=ni,ri=(0,d.Z)(ai,ii,si,!1,null,"482b879c",null),oi=ri.exports,ci=[{path:"/manage",name:"manage",component:oi,meta:{title:"管理"},icon:"el-icon-s-tools",children:[{path:"/manage/index",name:"index",component:()=>i.e(585).then(i.bind(i,4585)),meta:{title:"概况",icon:"el-icon-data-line"}},{path:"/manage/setting",name:"setting",component:()=>Promise.all([i.e(647),i.e(789)]).then(i.bind(i,3585)),meta:{title:"设置",icon:"el-icon-setting"}},{path:"/manage/user",name:"user",component:()=>Promise.all([i.e(647),i.e(687)]).then(i.bind(i,4368)),meta:{title:"成员",icon:"el-icon-user"}},{path:"/manage/message",name:"user",component:()=>Promise.all([i.e(647),i.e(982)]).then(i.bind(i,196)),meta:{title:"消息",icon:"el-icon-chat-dot-round"}},{path:"/manage/group",name:"group",component:()=>i.e(173).then(i.bind(i,4173)),meta:{title:"群聊",icon:"el-icon-chat-dot-square"}},{path:"/manage/files",name:"files",component:()=>i.e(567).then(i.bind(i,7567)),meta:{title:"文件",icon:"el-icon-folder-opened"}}]}];s["default"].use(L.ZP);const li=[{path:"/",name:"home",component:Ve,meta:{title:"聊天"}},{path:"/chat",name:"chat",component:Ve,meta:{title:"聊天演示页"}},{path:"/demo",name:"demo",component:Pe,meta:{title:"演示页"}},{path:"/login",name:"login",component:Je,meta:{title:"登录"}},{path:"/register",name:"register",component:ei,meta:{title:"注册"}},{path:"*",redirect:"/404",hidden:!0},{path:"/404",component:()=>i.e(133).then(i.bind(i,4133)),hidden:!0}],di=()=>new L.ZP({mode:"hash",scrollBehavior:()=>({y:0}),routes:[...li,...ci]}),ui=di();function hi(){const t=di();ui.matcher=t.matcher}var pi=ui,mi=i(6265),gi=i.n(mi);const fi={loadingCache:function(){if(o().get("authToken")&&!gi().defaults.headers.authToken){const t=o().get("UserInfo");t&&Di.commit("SET_USERINFO",t)}Di.commit("SET_APPNAME",o().get("systemName")),Di.commit("SET_APPLOGO",o().get("systemLogo"))},updateAxiosCache:function(){gi().defaults.headers.authToken=o().get("authToken"),gi().defaults.headers.sessionId=o().get("sessionId")},updateAxiosHeaders:function(){gi().defaults.headers.authToken=o().get("authToken"),gi().defaults.headers.sessionId=o().get("sessionId")},rmAxiosCache:function(){o().rm("authToken"),o().rm("sessionId")}};var vi=fi;function bi(){return new Promise(((t,e)=>{vi.rmAxiosCache(),delete gi().defaults.headers.authToken,delete gi().defaults.headers.sessionId,t(!0)}))}function yi(t,e){return new Promise(((i,s)=>{gi().defaults.headers.authToken=t,gi().defaults.headers.sessionId=e,i(!0)}))}function Ci(){return o().get("authToken")&&!gi().defaults.headers.authToken&&vi.updateAxiosCache(),!!o().get("authToken")}var xi=i(5410),wi=i.n(xi),ki=i(9070);const Ii=(0,ki.debounce)(500,(()=>{bi().then((()=>{location.reload()})).catch((()=>{location.reload()}))})),Ai=(0,ki.debounce)(500,((t,e="error")=>{(0,p.Message)({message:t,duration:1500,type:e})})),_i=(0,ki.debounce)(1e3,(t=>{p.MessageBox.confirm(t,"提示",{confirmButtonText:"确定",showCancelButton:!1,type:"warning"}).then((()=>{Ii()})).catch((()=>{}))}));gi().defaults.headers.post["Content-Type"]="application/x-www-form-urlencoded;charset=UTF-8";const Ei=window.location.protocol+"//"+window.location.host+"/";window.BASE_URL=Ei;const Si=gi().create({baseURL:Ei,timeout:6e4});Si.interceptors.request.use((t=>{const e=o().get("sessionId"),i=o().get("authToken");e&&i&&(t.headers["sessionId"]=e,t.headers["Authorization"]=i);const s=t.headers["Content-Type"]&&-1!==t.headers["Content-Type"].indexOf("application/json");if(s)void 0!==t.data&&null!==t.data||(t.data={});else{const e=t.headers["Content-Type"]&&-1!==t.headers["Content-Type"].indexOf("multipart/form-data");t.data=e?t.data:wi().stringify(t.data)}return t}),(t=>Promise.reject(t))),Si.interceptors.response.use((t=>{const e=t.data;if(200!==t.status||"blob"!==t.config.responseType)return 0!==e.code?(-1===e.code?_i(e.msg):[400,402,403,404,405,502,500].includes(e.code)?Ai(e.msg,"warning"):Ai(e.msg),e):e;if(t.headers["content-disposition"]||t.headers["content-type"]&&-1!=t.headers["content-type"].indexOf("application/pdf"))return t;{const e=new Blob([t.data],{type:"application/json"}),i=new FileReader;i.onload=function(){const t=JSON.parse(this.result);t.msg&&Ai(t.msg,1==t.code?"success":"error")},i.readAsText(e)}}),(t=>{if(t.response){const e=t.response;500==e.status?Ai("服务器返回错误,请检查!"):e.data&&e.data.msg&&Ai(e.data.msg)}return Promise.reject(t)}));var Ti=Si;const Ni={loginAPI:t=>Ti({url:"common/pub/login",method:"post",data:t}),logoutAPI:()=>Ti({url:"common/pub/logout",method:"post"}),bindClientIdAPI:t=>Ti({url:"common/pub/bindUid",method:"post",data:t}),offlineAPI:t=>Ti({url:"common/pub/offline",method:"post",data:t}),bindGroupAPI:t=>Ti({url:"common/pub/bindGroup",method:"post",data:t}),sendCode:t=>Ti({url:"common/pub/sendCode",method:"post",data:t}),getSystemInfo:t=>Ti({url:"common/pub/getSystemInfo",method:"post",data:t}),register:t=>Ti({url:"common/pub/register",method:"post",data:t}),uploadAvatar:t=>Ti({url:"common/upload/uploadAvatar",method:"post",data:t,headers:{"Content-Type":"multipart/form-data"}}),publishNotice:t=>Ti({url:"manage/index/publishNotice",method:"post",data:t}),getNoticeList:t=>Ti({url:"manage/index/noticeList",method:"post",data:t}),delNotice:t=>Ti({url:"manage/index/delNotice",method:"post",data:t})};var Mi=Ni;s["default"].use(v.ZP);const Li={userInfo:null,allAuth:null,socketAction:"",contactSync:"",toContactId:0,unread:0,allContacts:[],globalConfig:[],wsStatus:!0,setting:{sendKey:"1",theme:"default",isVoice:!0,avatarCricle:!1,hideMessageName:!1,hideMessageTime:!1}},Ui={SET_USERINFO:(t,e)=>{o().set("UserInfo",e),t.userInfo=e,e.setting&&(t.setting=e.setting)},SET_AUTH:(t,e)=>{const i=e.authToken,s=e.sessionId;o().set("authToken",i),o().set("sessionId",s),yi(i,s)},catchSocketAction(t,e){t.socketAction=e},updateUnread:(t,e)=>{t.unread=parseInt(e)},initContacts:(t,e)=>{t.allContacts=e},openChat:(t,e)=>{t.toContactId=e,t.contactSync=Math.random().toString(36).substr(-8)},updateSetting(t,e){t.userInfo.setting=e,t.setting=e},setGlobalConfig(t,e){t.globalConfig=e}},Oi={Login({commit:t,dispatch:e},i){return new Promise(((s,n)=>{Mi.loginAPI(i).then((e=>{const i=e.data||i;t("SET_AUTH",i),t("SET_USERINFO",i.userInfo),s(e)})).catch((t=>{e("LogOut"),n(t)}))}))},LogOut({commit:t}){return new Promise(((t,e)=>{Mi.logoutAPI().then((()=>{o().rm("authToken"),o().rm("sessionId"),o().rm("UserInfo"),bi(),hi(),t()})).catch((t=>{e(t)}))}))},getSystemInfo({commit:t}){return new Promise(((e,i)=>{Mi.getSystemInfo().then((i=>{0==i.code&&(o().set("globalConfig",i.data),t("setGlobalConfig",i.data),e(i))})).catch((t=>{i(t)}))}))},sendCode({commit:t},e){return new Promise(((t,i)=>{Mi.sendCode(e).then((e=>{t(e)})).catch((t=>{i(t)}))}))}};var Di=new v.ZP.Store({state:Li,mutations:Ui,actions:Oi}),Pi=i(5602),ji=i.n(Pi),Ri=i(1081);s["default"].directive("outside",Ri.Z);var Bi=i(530),Fi=i.n(Bi);const $i=["/login","/register"],Hi=["/","/demo","/chat"];pi.beforeEach(((t,e,i)=>{if(t.meta.disabled)i(!1);else if(Fi().start(),Ci()){let e=o().get("globalConfig"),s=e.demon_mode,n="";s&&(n="/demo");let a=o().get("UserInfo");$i.includes(t.path)||"/"==t.path&&n?(i({path:n}),Fi().done()):Hi.includes(t.path)&&0==e.sysInfo.state?(a&&a.role>0||s?i({path:"/manage/index"}):i({path:"/404",query:{msg:e.sysInfo.closeTips}}),Fi().done()):-1!==t.path.indexOf("manage")?a&&a.role>0||s?i():(p.Message.error("您没有权限访问该页面"),i(!1),Fi().done()):i()}else-1!==$i.indexOf(t.path)?i():(i("/login"),Fi().done())})),pi.afterEach((()=>{Fi().done()})),pi.onError((t=>{const e=/Loading chunk (\d)+ failed/g,i=t.message.match(e),s=pi.history.pending.fullPath;i&&pi.replace(s)}));var Vi,Gi,Ki,zi,Qi,Yi,Ji,qi,Wi,Zi,Xi=JSON.parse('{"name":"Raingad-IM","version":"5.5.0","description":"一款基于vue2.0的即时聊天工具","logo":"/assets/img/logo.png","frontUrl":"https://gitee.com/raingad/im-chat-front","backstageUrl":"https://gitee.com/raingad/im-instant-chat","mobileUrl":"https://im.raingad.com/h5","author":"Raingad","license":"Apache2.0","qqGroupUrl":"https://jq.qq.com/?_wv=1027&k=jMQAt9lh","private":true,"funcList":[{"icon":"el-icon-chat-line-round","text":"支持单聊和群聊,支持发送表情、图片、语音、视频和文件消息"},{"icon":"el-icon-potato-strips","text":"单聊支持消息已读未读的状态显示,在线状态显示"},{"icon":"el-icon-user","text":"群聊创建、删除和群成员管理、群公告、群禁言、@群成员等"},{"icon":"el-icon-ice-cream-round","text":"支持置顶联系人,消息免打扰;支持设置新消息声音提醒,浏览器通知"},{"icon":"el-icon-video-camera","text":"支持一对一音视频通话(已打通web端和移动端,小程序不支持)"},{"icon":"el-icon-milk-tea","text":"支持文件、图片和绝大部分媒体文件在线预览"},{"icon":"el-icon-mobile-phone","text":"支持移动端(由uniapp开发,可打包H5、APP和小程序),支持简易后台管理"},{"icon":"el-icon-coffee-cup","text":"支持企业模式和社交模式,社交模式支持注册、添加好友功能"}],"scripts":{"serve":"vue-cli-service serve","build":"vue-cli-service build","lint":"vue-cli-service lint"},"dependencies":{"axios":"^0.21.4","core-js":"^3.8.3","cropperjs":"^1.5.13","element-ui":"^2.15.13","js-audio-recorder":"^1.0.7","js-web-screen-shot":"^1.9.8-rc.3","lockr":"^0.8.5","nprogress":"^0.2.0","v-clipboard":"^2.2.3","vue":"^2.6.14","vue-canvas-poster":"^1.2.1","vue-qr":"^4.0.9","vue-router":"^3.5.1","vuex":"^3.6.2"},"devDependencies":{"@babel/core":"^7.12.16","@babel/eslint-parser":"^7.12.16","@vue/cli-plugin-babel":"~5.0.0","@vue/cli-plugin-eslint":"~5.0.0","@vue/cli-plugin-router":"~5.0.0","@vue/cli-plugin-vuex":"~5.0.0","@vue/cli-service":"~5.0.0","eslint":"^7.32.0","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^4.0.0","eslint-plugin-vue":"^8.0.3","prettier":"^2.4.1","sass":"^1.32.7","sass-loader":"^12.0.0","vue-template-compiler":"^2.6.14"},"rules":{"generator-star-spacing":"off","no-tabs":"off","no-unused-vars":"off","no-console":"off","no-irregular-whitespace":"off","no-debugger":"off"}}'),ts=i(8701),es=i.n(ts),is={name:"lemonMessageVoice",inheritAttrs:!1,inject:["IMUI"],render(){const t=arguments[0];return t("lemon-message-basic",es()([{class:"lemon-message-voice"},{props:{...this.$attrs}},{attrs:{reverse:this.$attrs.reverse,message:this.$attrs.message,hideName:this.$attrs.hideName,hideTime:this.$attrs.hideTime},scopedSlots:{content:e=>t("div",{class:["voice-card lz-flex lz-justify-content-start lz-align-items-center",{"im-rows-reverse":this.$attrs.reverse}],style:{width:3*e.extends.duration+"px"}},[t("div",{class:["iconfont icon-im-yuyin f-16",{"voice-icon":e.isPlay},{rotate180:this.$attrs.reverse}]}),"  ",t("div",[e.extends.duration,'"'])])}}]))}},ss=is,ns=(0,d.Z)(ss,Vi,Gi,!1,null,null,null),as=ns.exports,rs={name:"lemonMessageVideo",inheritAttrs:!1,inject:["IMUI"],render(){const t=arguments[0];return t("lemon-message-basic",es()([{class:"lemon-message-video"},{props:{...this.$attrs}},{attrs:{reverse:this.$attrs.reverse,message:this.$attrs.message,hideName:this.$attrs.hideName,hideTime:this.$attrs.hideTime},scopedSlots:{content:e=>t("div",{class:["video-card"],style:{}},[t("el-image",{style:"max-height: 200px",attrs:{src:e.extends.poster,fit:"cover"}},[t("div",{slot:"error",class:"image-slot"},[t("i",{class:"el-icon-picture-outline"})])]),t("div",{class:"video-shadow"},[t("div",{class:"el-icon el-icon-video-play c-white f-28 video-icon"})])])}}]))}},os=rs,cs=(0,d.Z)(os,Ki,zi,!1,null,null,null),ls=cs.exports,ds={name:"lemonMessageWebrtc",inheritAttrs:!1,inject:["IMUI"],render(){const t=arguments[0];return t("lemon-message-basic",es()([{class:"lemon-message-webrtc"},{props:{...this.$attrs}},{attrs:{reverse:this.$attrs.reverse,message:this.$attrs.message,hideName:this.$attrs.hideName,hideTime:this.$attrs.hideTime},scopedSlots:{content:e=>t("div",{class:["voice-card lz-flex lz-justify-content-start lz-align-items-center",{"im-rows-reverse":this.$attrs.reverse}],style:""},[t("div",{class:["el-icon f-16",{"el-icon-phone-outline":0==e.extends.type},{"el-icon-video-camera":1==e.extends.type},{rotate180:this.$attrs.reverse}]}),"  ",t("div",[e.content])])}}]))}},us=ds,hs=(0,d.Z)(us,Qi,Yi,!1,null,null,null),ps=hs.exports,ms=i(3817),gs={name:"lemonMessageFile",inheritAttrs:!1,render(){const t=arguments[0];return t("lemon-message-basic",es()([{class:"lemon-message-file"},{props:{...this.$attrs}},{scopedSlots:{content:e=>[t("div",{class:"lemon-message-file__inner"},[t("p",{class:"lemon-message-file__name"},[e.fileName]),t("p",{class:"lemon-message-file__byte"},[(0,ms.hR)(e.fileSize)])]),t("div",{class:"lemon-message-file__sfx"},[t("img",{attrs:{src:e.extUrl},style:"width:34px;height:42px"})])]}}]))}},fs=gs,vs=(0,d.Z)(fs,Ji,qi,!1,null,"8e81f66c",null),bs=vs.exports,ys={name:"lemonMessageText",inheritAttrs:!1,inject:["IMUI"],render(){const t=arguments[0];return t("lemon-message-basic",es()([{class:"lemon-message-text"},{props:{...this.$attrs}},{scopedSlots:{content:e=>{const i=this.IMUI.emojiNameToImage(e.content),s=e.extends&&e.extends.content;return t("div",[t("span",es()([{},{domProps:{innerHTML:i}}])),s?t("div",{class:"message-quote"},[t("span",[e.extends.content])]):""])}}}]))}},Cs=ys,xs=(0,d.Z)(Cs,Wi,Zi,!1,null,"bf5aa10c",null),ws=xs.exports;const ks=function(){return document.addEventListener?function(t,e,i){t&&e&&i&&t.addEventListener(e,i,!1)}:function(t,e,i){t&&e&&i&&t.attachEvent("on"+e,i)}}(),Is=(function(){document.removeEventListener}(),[]),As="@@wkClickoutsideContext";let _s,Es=0;function Ss(t,e,i){return function(s={},n={}){!(i&&i.context&&s.target&&n.target)||t.contains(s.target)||t.contains(n.target)||t===s.target||i.context.popperElm&&(i.context.popperElm.contains(s.target)||i.context.popperElm.contains(n.target))||(e.expression&&t[As].methodName&&i.context[t[As].methodName]?i.context[t[As].methodName]():t[As].bindingFn&&t[As].bindingFn())}}!s["default"].prototype.$isServer&&ks(document,"mousedown",(t=>_s=t)),!s["default"].prototype.$isServer&&ks(document,"mouseup",(t=>{Is.forEach((e=>e[As].documentHandler(t,_s)))}));var Ts={bind(t,e,i){Is.push(t);const s=Es++;t[As]={id:s,documentHandler:Ss(t,e,i),methodName:e.expression,bindingFn:e.value}},update(t,e,i){t[As].documentHandler=Ss(t,e,i),t[As].methodName=e.expression,t[As].bindingFn=e.value},unbind(t){const e=Is.length;for(let i=0;i<e;i++)if(Is[i][As].id===t[As].id){Is.splice(i,1);break}delete t[As]}};const Ns={getTaskList:t=>Ti({url:"/manage/Task/getTaskList",method:"post",data:t}),startTask:t=>Ti({url:"/manage/Task/startTask",method:"post",data:t}),stopTask:t=>Ti({url:"/manage/Task/stopTask",method:"post",data:t}),getTaskLog:t=>Ti({url:"/manage/Task/getTaskLog",method:"post",data:t}),clearTaskLog:t=>Ti({url:"/manage/Task/clearTaskLog",method:"post",data:t})};var Ms=Ns;const Ls={setConfig:t=>Ti({url:"manage/config/setConfig",method:"post",data:t}),getConfig:t=>Ti({url:"manage/config/getConfig",method:"post",data:t}),getAllConfig:t=>Ti({url:"manage/config/getAllConfig",method:"post",data:t}),getInviteLink:t=>Ti({url:"manage/config/getInviteLink",method:"post",data:t}),sendTestEmail:t=>Ti({url:"manage/config/sendTestEmail",method:"post",data:t})};var Us=Ls;const Os={getUserList:t=>Ti({url:"/manage/User/index",method:"post",data:t}),addUser:t=>Ti({url:"/manage/User/add",method:"post",data:t}),editUser:t=>Ti({url:"/manage/User/edit",method:"post",data:t}),delUser:t=>Ti({url:"/manage/User/del",method:"post",data:t}),getUserDetail:t=>Ti({url:"/manage/User/detail",method:"post",data:t}),editPassword:t=>Ti({url:"/manage/User/editPassword",method:"post",data:t}),setStatus:t=>Ti({url:"/manage/User/setStatus",method:"post",data:t}),setRole:t=>Ti({url:"/manage/User/setRole",method:"post",data:t})};var Ds=Os;const Ps={getGroupList:t=>Ti({url:"/manage/Group/index",method:"post",data:t}),addGroupUser:t=>Ti({url:"/manage/Group/addGroupUser",method:"post",data:t}),delGroupUser:t=>Ti({url:"/manage/Group/delGroupUser",method:"post",data:t}),changeOwner:t=>Ti({url:"/manage/Group/changeOwner",method:"post",data:t}),setManager:t=>Ti({url:"/manage/Group/setManager",method:"post",data:t}),delGroup:t=>Ti({url:"/manage/Group/del",method:"post",data:t})};var js=Ps;const Rs={getContactsAPI:t=>Ti({url:"enterprise/im/getContacts",method:"post",data:t}),sendMessageAPI:t=>Ti({url:"enterprise/im/sendMessage",method:"post",data:t}),forwardMessageAPI:t=>Ti({url:"enterprise/im/forwardMessage",method:"post",data:t}),sendToMsg:t=>Ti({url:"enterprise/im/sendToMsg",method:"post",data:t})};Rs.forwardMessageAPI=t=>Ti({url:"enterprise/im/forwardMessage",method:"post",data:t}),Rs.sendFileAPI=t=>Ti({url:"common/upload/uploadFile",method:"post",data:t,headers:{"Content-Type":"multipart/form-data"}}),Rs.getMessageListAPI=t=>Ti({url:"enterprise/im/getMessageList",method:"post",data:t}),Rs.setMsgIsReadAPI=t=>Ti({url:"enterprise/im/setMsgIsRead",method:"post",data:t}),Rs.undoMessageAPI=t=>Ti({url:"enterprise/im/undoMessage",method:"post",data:t}),Rs.delMessageAPI=t=>Ti({url:"enterprise/im/delMessage",method:"post",data:t}),Rs.removeMessageAPI=t=>Ti({url:"enterprise/im/removeMessage",method:"post",data:t}),Rs.settingAPI=t=>Ti({url:"enterprise/im/setting",method:"post",data:t}),Rs.editGroupNameAPI=t=>Ti({url:"enterprise/group/editGroupName",method:"post",data:t}),Rs.setNoSpeakAPI=t=>Ti({url:"enterprise/group/setNoSpeak",method:"post",data:t}),Rs.groupUserListAPI=t=>Ti({url:"enterprise/group/groupuserlist",method:"post",data:t}),Rs.getAllUserAPI=t=>Ti({url:"enterprise/group/getAllUser",method:"post",data:t}),Rs.addGroupAPI=t=>Ti({url:"enterprise/group/add",method:"post",data:t}),Rs.setManagerAPI=t=>Ti({url:"enterprise/group/setManager",method:"post",data:t}),Rs.removeUserAPI=t=>Ti({url:"enterprise/group/removeUser",method:"post",data:t}),Rs.addGroupUserAPI=t=>Ti({url:"enterprise/group/addGroupUser",method:"post",data:t}),Rs.removeGrouprAPI=t=>Ti({url:"enterprise/group/removeGroup",method:"post",data:t}),Rs.setNoticeAPI=t=>Ti({url:"enterprise/group/setNotice",method:"post",data:t}),Rs.groupSettingAPI=t=>Ti({url:"enterprise/group/groupSetting",method:"post",data:t}),Rs.clearMessageAPI=t=>Ti({url:"enterprise/group/clearMessage",method:"post",data:t}),Rs.getGroupInfoAPI=t=>Ti({url:"enterprise/group/groupInfo",method:"post",data:t}),Rs.changeOwnerAPI=t=>Ti({url:"enterprise/group/changeOwner",method:"post",data:t}),Rs.isNoticeAPI=t=>Ti({url:"enterprise/im/isNotice",method:"post",data:t}),Rs.setChatTopAPI=t=>Ti({url:"enterprise/im/setChatTop",method:"post",data:t}),Rs.getUserInfo=t=>Ti({url:"enterprise/im/getUserInfo",method:"post",data:t}),Rs.getFileList=t=>Ti({url:"enterprise/files/index",method:"post",data:t}),Rs.updateUserInfo=t=>Ti({url:"enterprise/im/updateUserInfo",method:"post",data:t}),Rs.editAccount=t=>Ti({url:"enterprise/im/editAccount",method:"post",data:t}),Rs.editPassword=t=>Ti({url:"enterprise/im/editpassword",method:"post",data:t}),Rs.searchUser=t=>Ti({url:"enterprise/im/searchUser",method:"post",data:t}),Rs.userList=t=>Ti({url:"enterprise/im/userList",method:"post",data:t}),Rs.contactInfo=t=>Ti({url:"enterprise/im/getContactInfo",method:"post",data:t});var Bs=Rs;const Fs={getApplyList:t=>Ti({url:"enterprise/friend/index",method:"post",data:t}),addFriend:t=>Ti({url:"enterprise/friend/add",method:"post",data:t}),delFriend:t=>Ti({url:"enterprise/friend/del",method:"post",data:t}),acceptFriend:t=>Ti({url:"enterprise/friend/update",method:"post",data:t}),setNickname:t=>Ti({url:"enterprise/friend/setNickname",method:"post",data:t}),getApplyMsg:t=>Ti({url:"enterprise/friend/getApplyMsg",method:"post",data:t})};var $s=Fs;const Hs={getMessageList:t=>Ti({url:"manage/message/index",method:"post",data:t}),getContacts:t=>Ti({url:"manage/message/getContacts",method:"post",data:t}),dealMsg:t=>Ti({url:"manage/message/dealMsg",method:"post",data:t})};var Vs=Hs,Gs={taskApi:Ms,configApi:Us,userApi:Ds,groupApi:js,imApi:Bs,commonApi:Mi,friendApi:$s,messageApi:Vs};s["default"].use(w),s["default"].use(T),s["default"].use(m(),{size:"small"}),s["default"].use(M()),s["default"].use(Di),s["default"].use(ji()),s["default"].config.productionTip=!1,s["default"].prototype.$packageData=Xi,s["default"].component(ls.name,ls),s["default"].component(as.name,as),s["default"].component(ps.name,ps),s["default"].component(bs.name,bs),s["default"].component(ws.name,ws),s["default"].directive("elclickoutside",Ts),s["default"].prototype.$api=Gs,new s["default"]({el:"#app",router:pi,store:Di,components:{App:h},template:"<App/>"})},3817:function(t,e,i){"use strict";function s(t){let e=new Array(" B"," KB"," MB"," GB"," TB"),i=t+"B";for(let s=0;t>=1024&&s<4;s++)t/=1024,i=t.toFixed(2)+e[s+1];return i}function n(t){var e="https://file.lcoce.com/ext/",i=t.split("."),s=i[i.length-1],n=s.toUpperCase(),a=["jpg","jpeg","png","bmp","gif","pdf","mp3","wav","wmv","amr","mp4","3gp","avi","m2v","mkv","mov","webp","ppt","pptx","doc","docx","xls","xlsx","pdf"];return a.includes(n)?e+n+".png":e+"icon/document.svg"}function a(t,e){let i=document.createElement("a"),s=t.split(".").pop(),n=["jpg","jpeg","png","bmp","gif","pdf","mp3","wav","wmv","amr","mp4","3gp","avi","m2v","mkv","mov","webp"];-1!==n.indexOf(s)?i.download=e||"pic":i.download=e||"file",i.href=t,i.click()}i.d(e,{AC:function(){return n},LR:function(){return a},hR:function(){return s}})},2325:function(t,e,i){"use strict";i.d(e,{I8:function(){return s},L4:function(){return r},NW:function(){return l},Nj:function(){return a},hT:function(){return c},i$:function(){return o},iu:function(){return n},nZ:function(){return d},xb:function(){return u}});i(2801),i(7658),i(3408),i(4590);function s(t){return JSON.parse(JSON.stringify(t))}function n(t,e,i){if("object"!==typeof t)return!1;for(var s=[],n=0;t.length>n;n++)if("object"==typeof e)for(var a=0;e.length>a;a++){var r=e[a],o=t[n][r];if(-1!=o.indexOf(i)){s.push(t[n]);break}}else{o=t[n][e];-1!=o.indexOf(i)&&s.push(t[n])}return s}function a(t,e,i){i="undefined"!==typeof i&&i;for(var s=[],n=0;n<t.length;n++)s.push(t[n][e]);return!0===i?s.join(","):s}function r(t,e,i){for(var s=0;s<t.length;s++)t[s]["disabled"]=!1,t[s][e]==i&&(t[s]["disabled"]=!0);return t}function o(t){const e=new Date,i=new Date(t),s=new Date(e.getFullYear(),e.getMonth(),e.getDate()),n=new Date(s-864e5),a=new Date(s-24*(s.getDay()-1)*60*60*1e3),r=new Date(e.getFullYear(),0,1);if(i>=s)return c("H:i",t/1e3);if(i>=n&&i<s)return"昨天";if(i>=a&&i<n){const t=["周日","周一","周二","周三","周四","周五","周六"],e=t[i.getDay()];return e}return c(i>=r&&i<a?"m-d":"Y-m-d",t/1e3)}function c(t,e){var i=e?new Date(1e3*e):new Date,s=function(t,e){return(t+="").length<e?new Array(++e-t.length).join("0")+t:t},n=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],a={1:"st",2:"nd",3:"rd",21:"st",22:"nd",23:"rd",31:"st"},r=["","January","February","March","April","May","June","July","August","September","October","November","December"],o={d:function(){return s(o.j(),2)},D:function(){return o.l().substr(0,3)},j:function(){return i.getDate()},l:function(){return n[o.w()]},N:function(){return o.w()+1},S:function(){return a[o.j()]?a[o.j()]:"th"},w:function(){return i.getDay()},z:function(){return(i-new Date(i.getFullYear()+"/1/1"))/864e5>>0},W:function(){var t,e=o.z(),s=364+o.L()-e,n=(new Date(i.getFullYear()+"/1/1").getDay()||7)-1;return s<=2&&(i.getDay()||7)-1<=2-s?1:e<=2&&n>=4&&e>=6-n?(t=new Date(i.getFullYear()-1+"/12/31"),c("W",Math.round(t.getTime()/1e3))):1+(n<=3?(e+n)/7:(e-(7-n))/7)>>0},F:function(){return r[o.n()]},m:function(){return s(o.n(),2)},M:function(){return o.F().substr(0,3)},n:function(){return i.getMonth()+1},t:function(){var t;return 2===(t=i.getMonth()+1)?28+o.L():1&t&&t<8||!(1&t)&&t>7?31:30},L:function(){var t=o.Y();return 3&t||!(t%100)&&t%400?0:1},Y:function(){return i.getFullYear()},y:function(){return(i.getFullYear()+"").slice(2)},a:function(){return i.getHours()>11?"pm":"am"},A:function(){return o.a().toUpperCase()},B:function(){var t=60*(i.getTimezoneOffset()+60),e=3600*i.getHours()+60*i.getMinutes()+i.getSeconds()+t,s=Math.floor(e/86.4);return s>1e3&&(s-=1e3),s<0&&(s+=1e3),1===String(s).length&&(s="00"+s),2===String(s).length&&(s="0"+s),s},g:function(){return i.getHours()%12||12},G:function(){return i.getHours()},h:function(){return s(o.g(),2)},H:function(){return s(i.getHours(),2)},i:function(){return s(i.getMinutes(),2)},s:function(){return s(i.getSeconds(),2)},O:function(){var t=s(Math.abs(i.getTimezoneOffset()/60*100),4);return t=i.getTimezoneOffset()>0?"-"+t:"+"+t,t},P:function(){var t=o.O();return t.substr(0,3)+":"+t.substr(3,2)},c:function(){return o.Y()+"-"+o.m()+"-"+o.d()+"T"+o.h()+":"+o.i()+":"+o.s()+o.P()},U:function(){return Math.round(i.getTime()/1e3)}};let l="";return t.replace(/[\\]?([a-zA-Z])/g,(function(t,e){return l=t!==e?e:o[e]?o[e]():e,l}))}function l(){var t=(new Date).getTime(),e="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var i=(t+16*Math.random())%16|0;return t=Math.floor(t/16),("x"==e?i:3&i|8).toString(16)}));return e}function d(t,e){let i="[暂不支持的消息类型]";switch(t){case"text":i="[文本]";break;case"image":i="[图片]";break;case"voice":i="[语音]";break;case"video":i="[视频]";break;case"file":i="[文件]";break;case"location":i="[位置]";break;case"contact":i="[个人名片]";break;case"webrtc":i=e?"[正在请求与您视频通话]":"[正在请求与您语音通话]";break}return i}function u(t){return null===t||(void 0===t||("[object Array]"===Object.prototype.toString.call(t)?0===t.length:"[object Object]"===Object.prototype.toString.call(t)?0===Object.keys(t).length:"string"===typeof t&&""===t.trim()))}},5617:function(t){"use strict";t.exports="data:image/png;base64,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"},9072:function(t){"use strict";t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAQAAAAHUWYVAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QA/4ePzL8AAAjNSURBVHja7Z1/kJVVGcc/lIFmhCDrBpVomtBipmxJhk2s7jAhDhXITIE5TjRE2QxTjU4zSmvjNKMxplOTqRM2bSWm1li4mAoSW/yRWrnuwsKoiSy7grADhGua1O2PDdzde8857/ve857nvHefz/PfPe89z/Oc73vufX+cH6AoiqIoiqIoiqIoiqIoiqIoiqIoiqIoiqIoiqIoiqIoiqJEzGweYif/ohTYXqSdJdLJx0cLbwSXYqjdw0TpJoiJdaJiDNrLNEo3A8AY6QCAfzJeOoT/M5Pt0iG8TToANkYjB7TRIB2CNDeI/1QNtwelG0SW2bwuLsFI+4p0o0iyXrz5y62HD0g3ixQrxBu/st0l3TBSPC3e9CYTvACWu8paEcd1f0VG5f9IvP2jRIk5Us0i1UNi7h8A10gHEJpu8T7gsrkyDSPTQ1YwQybdFHxTOoCQ9Iqf/xH3kfB8Q7ypk9kTEo0j8bT3VU6WSDUDTfwxtMsTUh1dx0waqKvSZ1HkgBY+VdX3B+hgBz35BHcLz4n/iBTTeniI8/yKcSYbxdMqtg34vLP5sng6tWH3JWnstzuPWMQv/Xa3Ucu5vMmfXAe5rrIms4dx0pnUEBez1X6A6079ZyqHV+5ksv0A+0/WQlqkM6gxTmMMj9sOsPeQ+J84FY9z7cV2QT4kHX0NUpUg50tHX4O83/6kQwUJz0xbofzIRWUYKkhkqCDp2cdf86s83eP30c5atvAkO4GT+BgfZTWnhA1A+nFcXHZZWfs08LcM9VhfDetPVjI6GcOGsk+3M4sb/TpSQZJxubHku6z36UgFScIt7LaUrqTPnysVxE0f33aU3+bPmQrixn2R2+HPmQrixi3I1kT1JEIFceMW5DX+7stZ0W8MD9NLH730MZ4pTGUKUxnr2cdUT8ckopiCdPEH2uilj4EKpacylQ8yn/m814s398SJ6dT7Sq1YguynnXbaeMF6VD/9dPJbYDbNNFc9aNotyIWhGkD6YcVQ28TCjAMuzuF7DFTl2yXpT73WVgBBtrGiylPrPNZW4X+zte7LPMsbuSD9fId3VynHIPNoyxyFbQEn3/0takF+zDlexDjGVTybMZLK/ySnZ6ivwIJU+0NViTN4LGM0d5WJcnOmeqyC2IeSlnJokOQ0symnmlv5YsZvPksHT7KLRhppzHj3UcU0ILm+sY8zchJjkJsEcyvgC6pnqGdXrh5Wc4l0kpWJUZAuLgjgZXMUq+mVEd+dej8fTvmNidQxnjc5xF7+neqbZ/O8dLojiU2Q/3JRwiPraWYOs5jBhCGf7qaLp9jiuJU7xgvM4zHplNMQ/g9vWaK4rnZeuh7gJwmlXRnXn3pcgqxKENO32JO4vke4NEGN31dBKpt7ctBn2J661p8neDT+exWk3LqdowBvz1jzPhY7ap6vgpTbSmsk9WyqqvbrHZner4IMN/tV0dlsq9qDfahOkwoy3D5riWIaO734sEvSqoK8ZessMYzlL9782H64LlJB3rKPW2K416sn24umu1WQQbPN217l2dcByyPzBTEIEsPDxY3GkrO41bOvU1ljLGvjJemmiF2QGxMsjpOWpRUm3hzjUemmiEGQ541DNS/kylw8Xmss+Z10Y8QgyCPGkq/m5HEuTYaSDeyVbo54BTmFq3PzeZWxRLyPxCvIohx9LjG+LUy06lueSAtingz26Ry9nsy81PEEQlqQl40ln8zV78Wp4wmEtCCmM3Ia78nV7yzD50c4Itsg0oKYzki/A0jLmZ46okBIC2LqIe/L2e/pqSMKhLQgpvNxUs5+32EcUa89pCIn5e75xJQRBUJaENP9QP7DvI+mjCgQ0oKYHoa/lrvnwykjCoS0IKZ5sv05+32F/xhKRrkgpvR3p6wnLf8wlviZSp2ZWAXZkbPfbakjCoS0IKbzcW/O80OeMnw+KcD1nRVpQcznY3uufk21C/cPeUEmG28BN6SsKQ3b6DaUNAi3h7ggMN/w+W94NTefDxpLPi/dHPEKcpR7cvPZavh8HAukmyNeQeCOnDy2Gi96v+B9aafUyAsyiWZDyU5+lItH88gs8f4RgyAYBYEWXvHubQ1dhpKJxhe7AYlbkIPe92zu5Dpj2QJPi9xURQyCNHKFsexX/NCrr69ZysSvsNyEGXxccuzu528G4HKLl8XBso1+9HuJEl+3RDGOLV58XGfNNdzmsoUQ5Dnr/n7v4vGc5VgWMNdCCFLiJkcsv6iq9i85av+zCjLSjrg2lOPajDV3GofFHWN50EwLIkiJe53xNPJo6lpvdV5JTqFDBalsP0gQ0xK2Jq7vPuMIxaGsC5xlgQQpWSbTDGUud7PfWs8u1tj3CzzO6uA5FmzNRecG18eZwye4gBlMO/5O5RAv0c3TtBvfCI7kCh4InqF1zcX4BHk9w0vUExgPDKRcvgwaLO/W88MqSAyPToZzYoYBDkc5yMHUciAih4P4BIHp/nbjsNAkvAiugRgFgfMDLBP7hHSSlYlTEDiNFxOtBpeNVm6QTtBErIIAbMxtqfGs61qLE/4+ZKTdyUe8ZrQ882L8o/TGsNze4HZPE9yWBX2EWLOClChxmJstk9CSsDjg+45RIEiJEvtoYU6GHCawlIfFo69BQQatk9sSJzSWz7GWg+IxpxIkvkcnSehhPQ9Yt82bziIWZdxELG8K9iwrHSE2lvSNVZDYFuNPywQmyI9Y90nMN4ajEhUkMlSQyFBBIkMFiQwVJDJUkMhQQSJDBYkMFSQyVJDIUEEiQwWJDBUkMlSQyLAL8ox0eDWJdUSxChKaHvbbiu2CdKP4pstebBck75UPRyMOQVzLBq/ncukMaooumjhgO8AlyGT2RDqYppg4J+y5LnsPsFQ6hxrievf8Sfc+gd30slA6k5rg16zyVdWZEQ1VLqYNcE2ypk62k+YhWnkn9bnv6lGb7GEzV/JwsoPTbc5Qx0waqJPOsDAM0MEOeqTDUBRFURRFURRFURRFURRFURRFURRFURRFURRFURRFURQlPf8DKbLR1j/mRNAAAAAASUVORK5CYII="},8421:function(t){"use strict";t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEQAAABECAYAAAA4E5OyAAAABHNCSVQICAgIfAhkiAAAB95JREFUeF7tXGtsFFUUvnd2Zys1QoCCPH1RAZUEjYCogD8kIMEAiSYi/tAaRSCB7qO8QoPFQATS3S0hBESN9YcRfqjFYLCERAUVFDQQIKKBhAg0KBRojYXu7M71O7Pdpd3udufOzLa74E0mnXbO635zzplzX+Wsm5qYP784Wlw8QXB+P+d8mGBsuBBiOMdPmEAXtXP4+zk8P4e/x+91/ay7peVnvn17S3eYCr25aegM17zex9C5aQBhGrQ8jctjUVsEfD/A2HrI3auGQkdxj1vnm+OAaIHAJKHrbzDOZ8LcEudNNiReZkJ8xRXlAzUY/N5JHY4B0hoIPAwjN0Dg804amE0W3GQ3U5SVRdXVJ7LRmnluGxDh85VqjK2GR7wChYoZpTmg0fEyPlGFWM1ras7akW8ZEOH1DtYUZQ2Ul+Fy2zHCQV7KNdtUTVvLN2++ZEWuJUAigcDjTNf3wCsGWFGacx4hLiGMZniCwV9kdUkDovl8zyFuPwMYxbLKupVeiBZ07gU1HP5aRq8UIBGfj8LjfYDhklHSY7RCxKD7TU84/JFZG0wD0ur3V4H4bbOC84pOCC9A2WTGJlOAIExWoLh614zAfKXhQqxE+KzPZl9WQAAGVZp7evCTmq0PZp/rAGVmtpzSJSBiyZIHNZfrCHJGb7Na85yuSWVsAg+F/shkZ0ZAxLJld0Wi0SMgGJnnnZQyDwPK3z3R6ATUKc3pGNMCIqqq3JHm5t14OF1KW4EQA5Q9SLIz0w0Q0wKCz+sChMnWAumfNTOFWAhQtqUydwKEQkWLRk+DcKA1TQXCJcRfajQ6MjV0OgGCemM9/ri8QLply0xU3GuKQqGq9kI6ACIWLx6gqeqfILjDlqbCYW5SFWUkr67+O2FyB0Aifj/F1FuF0x9HLH3PEwot6ARIq8/3CNA5VjDjFEewgBCMdzCPUpqYR0l6yG3qHXFYhdiEL46XbpOAIJmexS/3OgV8IcmhYq0oHB6dBEQEAqM1IX4rpE44bavK+UM8GDxleMitMJq1C1BiNGwAgsr0EJLpE3aFWuXn/foxceWKVXZn+IT4CXlkIhdLlw5CZdoAQLJOBdjRzEeMYAouNnQo4716Mfo9UxNnzsQBamhgOt1fuGBHtTleJBJ8bYbyaCAwRxfiC3Nc5qnorStjxjBOVxedNyXx+nWmnzjBBC4CiOH3XDSEzQzu5EAuCcK4cYzDE3LV9MOH4+DgcriVcSfmSpXx4xldtj1BsncUVuLAARYDQE54DY1tyENqkT9elbSFMeQB1+TJjBMQCI8ebW0hpe/day85C/ExAfItAHlGpkPkDa7Zsw1QHGk3bmA46cx4ksLJKjDwkHqOMcwpfGBGme2YUlrKXAsXmiXvRCeuXmX68eOMnTzJ9NM07dKxkXxGXyTyvL59remBx8Rqa9PKzyLwGMcY5hqI+pjV7CorM74e0g1eEKurY/QGzTYCR4En8iFDzLLcpAMoWmWlLF+TNCDuRYssJU991y4W279f1kAjP7lXrZLmI4bY1q2yXtIkHTJWPSS6bp3lhOcOBCx5iSwgNMiTTqpUX7j9fqk3JlBxRoNBKZ72xK4pU4zQkWoIUU3Ws4T4jkJmBxS9JKPM+MrMnWuaxWq4JBRYCZvYjh1S+apN107ykBp8dstN966NUAYUI7nZLLdlwsYiGMZEEbcz9M8KioUvS6YXQ182yl/ZmmUw4oJ9FDKv4cb0/olUg1JBoXxh1BcYhDk91qDPMKdxEv1MU6PYBAMOIl7mTsyWUaKlIb1Ow3SboZHNA5J5hXTCaxI1kV5fb/sFGLNmpEC2WjVrdCHRJeZV44DcRqt1mV4SxjEbsIq3Ij6F6PdPxI+DhfRGc2Drk1iwOnRzGcLna8Agb3AOFOW9SHjHRXiH0ff/F6riryu5nHnTQyoqxvBY7OjtuJQJDxmLhaqTHTzEyCVWZ8/yPii6NDD9YjexYP/6fdi/Tit4zkxf5T9QN7Av/p72++I7rcVYHdvkf987W5j41LZ/0nlLVUXFQE3Xadui6Vm0QgQDdXqzqqrD+MaN/3QJSFuhVrjbuE2+nUw7mzNuy9Sammg2ns7J3XpNiINqnz5TeFVVNLVzmTfuBgIlESF+BUHixOQtAQzGLOc9kcijfMuWxnQd6nKBGyX9WMTaQXiKQwswPYwp8gYS6STUHFgHSd+yrvhHvd4XdUXZCfaeOk/nFIq0+X86Nv/v60pgVkCI2c6smlO9sSvHseMhCUMiXu9ihE644Er7+KmqpdgMEzYDqikPSQjS/P5nkZQ+L5jjIsgZGMHPwUnwb8yAQTRSgBCDKC8fFXG56sBo7NrL12YcA+F8VldnY6S/Mpk6axwQ0DTylKn5CAid9va43fNSq1Aztkp7SEIoztQo2rVrrwOUtbjuNqOsG2hoz3ql2rv3hyi6dCv6LAOSBCZ+8qoSWbwcwBRZMcI2D87owiuqPapabcUr2uu3DUgSGJ/vAY3zd1DIzcv1jsZkB5AocP8pzr0sxxD+vG1grSTVbErbJqxp3zj9l4g7s9FbfP4v+HbjqqGJYYsy0rI55iGp0nH2pijmck1FlTsHz2bhsntCi/LDl4qu17lisX3wiFYngUjIyhkgqcaihnkK4TQVZ4AHwc9LkHP6I7T6w+tLUCv0J3rcN+Ke/llKI+gaYdxl0F0E3T7UEj/mAoBUmf8B4MQdVOI4ES0AAAAASUVORK5CYII="},8516:function(t){"use strict";t.exports="data:image/png;base64,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"},2414:function(t){"use strict";t.exports="data:image/png;base64,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"},2942:function(t){"use strict";t.exports="data:image/png;base64,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"},7420:function(t,e,i){"use strict";t.exports=i.p+"assets/media/calling.69742e4c.mp3"},1739:function(t,e,i){"use strict";t.exports=i.p+"assets/media/guaduan.c0b3124b.mp3"},444:function(t,e,i){"use strict";t.exports=i.p+"assets/media/notify.3d49176d.mp3"},1315:function(t,e,i){"use strict";t.exports=i.p+"assets/media/notify.7668dd76.ogg"},8611:function(t,e,i){"use strict";t.exports=i.p+"assets/media/notify.e6953ff1.wav"},4654:function(){}},e={};function i(s){var n=e[s];if(void 0!==n)return n.exports;var a=e[s]={id:s,loaded:!1,exports:{}};return t[s].call(a.exports,a,a.exports,i),a.loaded=!0,a.exports}i.m=t,function(){i.amdO={}}(),function(){var t=[];i.O=function(e,s,n,a){if(!s){var r=1/0;for(d=0;d<t.length;d++){s=t[d][0],n=t[d][1],a=t[d][2];for(var o=!0,c=0;c<s.length;c++)(!1&a||r>=a)&&Object.keys(i.O).every((function(t){return i.O[t](s[c])}))?s.splice(c--,1):(o=!1,a<r&&(r=a));if(o){t.splice(d--,1);var l=n();void 0!==l&&(e=l)}}return e}a=a||0;for(var d=t.length;d>0&&t[d-1][2]>a;d--)t[d]=t[d-1];t[d]=[s,n,a]}}(),function(){i.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return i.d(e,{a:e}),e}}(),function(){i.d=function(t,e){for(var s in e)i.o(e,s)&&!i.o(t,s)&&Object.defineProperty(t,s,{enumerable:!0,get:e[s]})}}(),function(){i.f={},i.e=function(t){return Promise.all(Object.keys(i.f).reduce((function(e,s){return i.f[s](t,e),e}),[]))}}(),function(){i.u=function(t){return"assets/js/"+t+"."+{133:"3a1dfa9e",173:"9e08cf23",567:"a6404721",585:"dea7864f",647:"d01223a0",687:"70d7eca3",789:"34f6ec0f",982:"0e09100e"}[t]+".js"}}(),function(){i.miniCssF=function(t){return"assets/css/"+t+"."+{133:"7f9367b6",173:"fc941ab9",567:"74d1a927",585:"8fcf2825",687:"d8d9e482",789:"62ab164a",982:"f6ad2033"}[t]+".css"}}(),function(){i.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"===typeof window)return window}}()}(),function(){i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)}}(),function(){var t={},e="Raingad-IM:";i.l=function(s,n,a,r){if(t[s])t[s].push(n);else{var o,c;if(void 0!==a)for(var l=document.getElementsByTagName("script"),d=0;d<l.length;d++){var u=l[d];if(u.getAttribute("src")==s||u.getAttribute("data-webpack")==e+a){o=u;break}}o||(c=!0,o=document.createElement("script"),o.charset="utf-8",o.timeout=120,i.nc&&o.setAttribute("nonce",i.nc),o.setAttribute("data-webpack",e+a),o.src=s),t[s]=[n];var h=function(e,i){o.onerror=o.onload=null,clearTimeout(p);var n=t[s];if(delete t[s],o.parentNode&&o.parentNode.removeChild(o),n&&n.forEach((function(t){return t(i)})),e)return e(i)},p=setTimeout(h.bind(null,void 0,{type:"timeout",target:o}),12e4);o.onerror=h.bind(null,o.onerror),o.onload=h.bind(null,o.onload),c&&document.head.appendChild(o)}}}(),function(){i.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}}(),function(){i.nmd=function(t){return t.paths=[],t.children||(t.children=[]),t}}(),function(){i.p=""}(),function(){var t=function(t,e,i,s){var n=document.createElement("link");n.rel="stylesheet",n.type="text/css";var a=function(a){if(n.onerror=n.onload=null,"load"===a.type)i();else{var r=a&&("load"===a.type?"missing":a.type),o=a&&a.target&&a.target.href||e,c=new Error("Loading CSS chunk "+t+" failed.\n("+o+")");c.code="CSS_CHUNK_LOAD_FAILED",c.type=r,c.request=o,n.parentNode.removeChild(n),s(c)}};return n.onerror=n.onload=a,n.href=e,document.head.appendChild(n),n},e=function(t,e){for(var i=document.getElementsByTagName("link"),s=0;s<i.length;s++){var n=i[s],a=n.getAttribute("data-href")||n.getAttribute("href");if("stylesheet"===n.rel&&(a===t||a===e))return n}var r=document.getElementsByTagName("style");for(s=0;s<r.length;s++){n=r[s],a=n.getAttribute("data-href");if(a===t||a===e)return n}},s=function(s){return new Promise((function(n,a){var r=i.miniCssF(s),o=i.p+r;if(e(r,o))return n();t(s,o,n,a)}))},n={143:0};i.f.miniCss=function(t,e){var i={133:1,173:1,567:1,585:1,687:1,789:1,982:1};n[t]?e.push(n[t]):0!==n[t]&&i[t]&&e.push(n[t]=s(t).then((function(){n[t]=0}),(function(e){throw delete n[t],e})))}}(),function(){var t={143:0};i.f.j=function(e,s){var n=i.o(t,e)?t[e]:void 0;if(0!==n)if(n)s.push(n[2]);else{var a=new Promise((function(i,s){n=t[e]=[i,s]}));s.push(n[2]=a);var r=i.p+i.u(e),o=new Error,c=function(s){if(i.o(t,e)&&(n=t[e],0!==n&&(t[e]=void 0),n)){var a=s&&("load"===s.type?"missing":s.type),r=s&&s.target&&s.target.src;o.message="Loading chunk "+e+" failed.\n("+a+": "+r+")",o.name="ChunkLoadError",o.type=a,o.request=r,n[1](o)}};i.l(r,c,"chunk-"+e,e)}},i.O.j=function(e){return 0===t[e]};var e=function(e,s){var n,a,r=s[0],o=s[1],c=s[2],l=0;if(r.some((function(e){return 0!==t[e]}))){for(n in o)i.o(o,n)&&(i.m[n]=o[n]);if(c)var d=c(i)}for(e&&e(s);l<r.length;l++)a=r[l],i.o(t,a)&&t[a]&&t[a][0](),t[a]=0;return i.O(d)},s=self["webpackChunkRaingad_IM"]=self["webpackChunkRaingad_IM"]||[];s.forEach(e.bind(null,0)),s.push=e.bind(null,s.push.bind(s))}();var s=i.O(void 0,[998],(function(){return i(8138)}));s=i.O(s)})();