优化页面
This commit is contained in:
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../../../../common/vendor.js"),o=require("../../../constant.js"),t=require("../utils/index.js"),i={setRemark:{key:"setRemark",label:"备注名",data:"",labelPosition:o.CONTACT_INFO_LABEL_POSITION.LEFT,editable:!0,editType:o.CONTACT_INFO_MORE_EDIT_TYPE.INPUT,editing:!1,editSubmitHandler:e=>{var o,i,n,l,a,d;if(null==e?void 0:e.isBothFriend){const d=null==(o=null==e?void 0:e.item)?void 0:o.data;t.updateFriendRemark(null==(i=null==e?void 0:e.contactInfoData)?void 0:i.userID,d),(null==(n=null==e?void 0:e.item)?void 0:n.editing)&&(e.item.editing=!1),(null==(l=null==e?void 0:e.item)?void 0:l.data)&&(e.item.data=null==(a=null==e?void 0:e.contactInfoData)?void 0:a.remark)}else(null==(d=null==e?void 0:e.item)?void 0:d.editing)&&(e.item.editing=!1)}},blackList:{key:"blackList",label:"加入黑名单",data:!1,labelPosition:o.CONTACT_INFO_LABEL_POSITION.LEFT,editable:!0,editType:o.CONTACT_INFO_MORE_EDIT_TYPE.SWITCH,editing:!0,editSubmitHandler:o=>{var i,n;(null==o?void 0:o.isInBlackList)?t.removeFromBlacklist(null==(i=null==o?void 0:o.contactInfoData)?void 0:i.userID):(t.addToBlacklist(null==(n=null==o?void 0:o.contactInfoData)?void 0:n.userID),e.Jt.update(e.o.CUSTOM,"currentContactListKey","blackList"))}},setWords:{key:"setWords",label:"请填写验证信息",data:"",labelPosition:o.CONTACT_INFO_LABEL_POSITION.TOP,editable:!0,editType:o.CONTACT_INFO_MORE_EDIT_TYPE.TEXTAREA,editing:!0},displayWords:{key:"displayWords",label:"验证信息",data:"",labelPosition:o.CONTACT_INFO_LABEL_POSITION.LEFT,editable:!1}},n={dismissGroup:{key:"dismissGroup",label:"解散群聊",type:o.CONTACT_INFO_BUTTON_TYPE.CANCEL,onClick:e=>{var o;t.dismissGroup(null==(o=null==e?void 0:e.contactInfoData)?void 0:o.groupID)}},quitGroup:{key:"quitGroup",label:"退出群聊",type:o.CONTACT_INFO_BUTTON_TYPE.CANCEL,onClick:e=>{var o;t.quitGroup(null==(o=null==e?void 0:e.contactInfoData)?void 0:o.groupID)}},joinGroup:{key:"joinGroup",label:"发送申请",type:o.CONTACT_INFO_BUTTON_TYPE.SUBMIT,onClick:e=>{var o,i;t.joinGroup(null==(o=null==e?void 0:e.contactInfoData)?void 0:o.groupID,null==(i=null==e?void 0:e.contactInfoMoreList[0])?void 0:i.data)}},joinAVChatGroup:{key:"joinAVChatGroup",label:"加入直播群",type:o.CONTACT_INFO_BUTTON_TYPE.SUBMIT,onClick:e=>{var o;t.joinGroup(null==(o=null==e?void 0:e.contactInfoData)?void 0:o.groupID)}},enterGroupConversation:{key:"enterGroupConversation",label:"进入群聊",type:o.CONTACT_INFO_BUTTON_TYPE.SUBMIT,onClick:e=>{t.enterConversation(null==e?void 0:e.contactInfoData)}},addFriend:{key:"addFriend",label:"发送申请",type:o.CONTACT_INFO_BUTTON_TYPE.SUBMIT,onClick:e=>{var o,i,n;t.addFriend({to:null==(o=null==e?void 0:e.contactInfoData)?void 0:o.userID,source:"AddSource_Type_Web",remark:null==(i=null==e?void 0:e.contactInfoMoreList[1])?void 0:i.data,wording:null==(n=null==e?void 0:e.contactInfoMoreList[0])?void 0:n.data})}},deleteFriend:{key:"deleteFriend",label:"删除好友",type:o.CONTACT_INFO_BUTTON_TYPE.CANCEL,onClick:e=>{var o;t.deleteFriend(null==(o=null==e?void 0:e.contactInfoData)?void 0:o.userID)}},enterC2CConversation:{key:"enterC2CConversation",label:"发送消息",type:o.CONTACT_INFO_BUTTON_TYPE.SUBMIT,onClick:e=>{t.enterConversation(null==e?void 0:e.contactInfoData)}},acceptFriendApplication:{key:"acceptFriendApplication",label:"同意",type:o.CONTACT_INFO_BUTTON_TYPE.SUBMIT,onClick:o=>{var i;t.acceptFriendApplication(null==(i=null==o?void 0:o.contactInfoData)?void 0:i.userID),e.Jt.update(e.o.CUSTOM,"currentContactListKey","friendList")}},refuseFriendApplication:{key:"refuseFriendApplication",label:"拒绝",type:o.CONTACT_INFO_BUTTON_TYPE.CANCEL,onClick:e=>{var o;t.refuseFriendApplication(null==(o=null==e?void 0:e.contactInfoData)?void 0:o.userID)}}};exports.contactButtonConfig=n,exports.contactMoreInfoConfig=i;
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
7
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.json
vendored
Normal file
7
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.json
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"icon": "../../common/Icon",
|
||||
"switch-bar": "../../common/SwitchBar/index"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view wx:if="{{a}}" class="{{['data-v-f3526d9c', 'tui-contact-info', A]}}"><view wx:if="{{b}}" class="{{['data-v-f3526d9c', 'tui-contact-info-header', h]}}"><view class="{{['data-v-f3526d9c', 'tui-contact-info-header-icon', d]}}" bindtap="{{e}}"><icon wx:if="{{c}}" class="data-v-f3526d9c" u-i="f3526d9c-0" bind:__l="__l" u-p="{{c}}"/></view><view class="{{['data-v-f3526d9c', 'tui-contact-info-header-title', g]}}">{{f}}</view></view><view class="{{['data-v-f3526d9c', 'tui-contact-info-basic', p]}}"><view class="{{['data-v-f3526d9c', 'tui-contact-info-basic-text', m]}}"><view class="{{['data-v-f3526d9c', 'tui-contact-info-basic-text-name', j]}}">{{i}}</view><view wx:for="{{k}}" wx:for-item="item" wx:key="b" class="{{['data-v-f3526d9c', 'tui-contact-info-basic-text-other', l]}}">{{item.a}}</view></view><image class="{{['data-v-f3526d9c', 'tui-contact-info-basic-avatar', n]}}" src="{{o}}"></image></view><view wx:if="{{q}}" class="{{['data-v-f3526d9c', 'tui-contact-info-more', w]}}"><view wx:for="{{r}}" wx:for-item="item" wx:key="z" class="{{['data-v-f3526d9c', 'tui-contact-info-more-item', v, item.A]}}"><view class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-label', s]}}">{{item.a}}</view><view class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-content', t]}}"><view wx:if="{{item.b}}" class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-content-text', item.j]}}"><view class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-content-text-data', item.d]}}">{{item.c}}</view><view wx:if="{{item.e}}" class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-content-text-icon', item.h]}}" bindtap="{{item.i}}"><icon wx:if="{{item.g}}" class="data-v-f3526d9c" u-i="{{item.f}}" bind:__l="__l" u-p="{{item.g}}"/></view></view><input wx:elif="{{item.k}}" class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-content-input', item.l]}}" type="text" bindconfirm="{{item.m}}" bindkeyup="{{item.n}}" value="{{item.o}}" bindinput="{{item.p}}"></input><textarea wx:elif="{{item.q}}" class="{{['data-v-f3526d9c', 'tui-contact-info-more-item-content-textarea', item.r]}}" confirm-type="done" value="{{item.s}}" bindinput="{{item.t}}"/><view wx:elif="{{item.v}}" class="data-v-f3526d9c" bindtap="{{item.y}}"><switch-bar wx:if="{{item.x}}" class="data-v-f3526d9c" u-i="{{item.w}}" bind:__l="__l" u-p="{{item.x}}"/></view></view></view></view><view class="{{['data-v-f3526d9c', 'tui-contact-info-button', z]}}"><button wx:for="{{x}}" wx:for-item="item" wx:key="b" class="{{['data-v-f3526d9c', 'tui-contact-info-button-item', y, item.c]}}" bindtap="{{item.d}}">{{item.a}}</button></view></view>
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-info/index.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../../../../../common/vendor.js");require("../../../../adapter-vue.js");const t=require("../../utils/index.js"),n=require("../../../../utils/env.js");Math||l();const l=()=>"../../../common/Avatar/index.js",u=e.defineComponent({__name:"index",props:{item:{default:()=>({})},displayOnlineStatus:{type:Boolean,default:!1}},setup(l){const u=l,i=e.inject("userOnlineStatusMap"),r=e.ref(!1),o={[e.qt.TYPES.GRP_WORK]:"Work",[e.qt.TYPES.GRP_AVCHATROOM]:"AVChatRoom",[e.qt.TYPES.GRP_PUBLIC]:"Public",[e.qt.TYPES.GRP_MEETING]:"Meeting",[e.qt.TYPES.GRP_COMMUNITY]:"Community"},a=e.computed((()=>{var t,n,l,i,r,o,a,d,s;let v="";return(null==(t=u.item)?void 0:t.type)===(null==(l=null==(n=e.qt)?void 0:n.TYPES)?void 0:l.SNS_APPLICATION_SENT_TO_ME)||(null==(i=u.item)?void 0:i.type)===(null==(o=null==(r=e.qt)?void 0:r.TYPES)?void 0:o.SNS_APPLICATION_SENT_BY_ME)?v=(null==(a=u.item)?void 0:a.wording)||"":(null==(d=u.item)?void 0:d.groupID)&&(v=`ID:${null==(s=u.item)?void 0:s.groupID}`),v})),d=e.computed((()=>{var e,t;let n="";return(null==(e=u.item)?void 0:e.groupID)&&(n=o[null==(t=u.item)?void 0:t.type]),n})),s=e.computed((()=>{var n,l,i,r,o,a;return(null==(n=u.item)?void 0:n.type)===(null==(i=null==(l=e.qt)?void 0:l.TYPES)?void 0:i.SNS_APPLICATION_SENT_BY_ME)?{style:"text",label:"等待验证"}:(null==(r=u.item)?void 0:r.type)===(null==(a=null==(o=e.qt)?void 0:o.TYPES)?void 0:a.SNS_APPLICATION_SENT_TO_ME)&&{style:"button",label:"同意",onClick:()=>{var e;t.acceptFriendApplication(null==(e=u.item)?void 0:e.userID)}}}));return e.watch((()=>null==i?void 0:i.value),(()=>{var t,n,l;r.value=!!(u.displayOnlineStatus&&(null==i?void 0:i.value)&&(null==(t=u.item)?void 0:t.userID)&&(null==(l=null==(n=i.value)?void 0:n[u.item.userID])?void 0:l.statusType)===e.qt.TYPES.USER_STATUS_ONLINE)}),{immediate:!0,deep:!0}),(l,i)=>e.e({a:e.p({useSkeletonAnimation:!0,url:e.unref(t.generateAvatar)(u.item)}),b:u.displayOnlineStatus&&u.item},u.displayOnlineStatus&&u.item?{c:e.unref(r)?1:"",d:e.unref(r)?"":1}:{},{e:e.t(e.unref(t.generateName)(u.item)),f:e.unref(a)},e.unref(a)?{g:e.t(e.unref(a))}:{},{h:e.unref(d)},e.unref(d)?{i:e.t(e.unref(d))}:{},{j:e.unref(s)},e.unref(s)?e.e({k:"text"===e.unref(s).style},"text"===e.unref(s).style?{l:e.t(e.unref(e.Wt).t(`TUIContact.${e.unref(s).label}`))}:"button"===e.unref(s).style?{n:e.t(e.unref(e.Wt).t(`TUIContact.${e.unref(s).label}`)),o:e.o$1(((...t)=>e.unref(s).onClick&&e.unref(s).onClick(...t)))}:{},{m:"button"===e.unref(s).style}):{},{p:e.n(!e.unref(n.isPC)&&"tui-contact-list-card-h5")})}}),i=e._export_sfc(u,[["__scopeId","data-v-b1be463d"]]);wx.createComponent(i);
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"avatar": "../../../common/Avatar/index"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="{{['data-v-b1be463d', 'tui-contact-list-card', p]}}"><view class="tui-contact-list-card-left data-v-b1be463d"><avatar wx:if="{{a}}" class="tui-contact-list-card-left-avatar data-v-b1be463d" u-i="b1be463d-0" bind:__l="__l" u-p="{{a}}"/><view wx:if="{{b}}" class="{{['data-v-b1be463d', 'online-status', c && 'online-status-online', d && 'online-status-offline']}}"/></view><view class="tui-contact-list-card-main data-v-b1be463d"><view class="tui-contact-list-card-main-name data-v-b1be463d">{{e}}</view><view wx:if="{{f}}" class="tui-contact-list-card-main-other data-v-b1be463d">{{g}}</view></view><view class="tui-contact-list-card-right data-v-b1be463d"><view wx:if="{{h}}" class="tui-contact-list-card-right-group-type data-v-b1be463d">{{i}}</view><view wx:if="{{j}}" class="tui-contact-list-card-right-application data-v-b1be463d"><view wx:if="{{k}}" class="tui-contact-list-card-right-application-text data-v-b1be463d">{{l}}</view><button wx:elif="{{m}}" class="tui-contact-list-card-right-application-button data-v-b1be463d" catchtap="{{o}}">{{n}}</button></view></view></view>
|
||||
@@ -0,0 +1 @@
|
||||
.tui-contact-list-card.data-v-b1be463d{padding:5px 0;display:flex;flex-direction:row;align-items:center;cursor:pointer;-webkit-user-select:none;user-select:none;overflow:hidden;flex:1}.tui-contact-list-card-left.data-v-b1be463d{position:relative;width:36px;height:36px}.tui-contact-list-card-left-avatar.data-v-b1be463d{width:36px;height:36px;border-radius:5px}.tui-contact-list-card-left .online-status.data-v-b1be463d{box-sizing:border-box;position:absolute;width:10px;height:10px;left:30px;top:30px;border:2px solid #fff;box-shadow:0 0 4px rgba(0,0,0,.1);border-radius:50%}.tui-contact-list-card-left .online-status-online.data-v-b1be463d{background:#29cc85}.tui-contact-list-card-left .online-status-offline.data-v-b1be463d{background:#a4a4a4}.tui-contact-list-card-main.data-v-b1be463d{flex:1;padding:0 10px;overflow:hidden}.tui-contact-list-card-main-name.data-v-b1be463d,.tui-contact-list-card-main-other.data-v-b1be463d{font-size:14px;flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tui-contact-list-card-main-other.data-v-b1be463d{color:#999}.tui-contact-list-card-right.data-v-b1be463d{width:-webkit-fit-content;width:fit-content}.tui-contact-list-card-right-group-type.data-v-b1be463d{padding:0 4px;line-height:14px;font-size:12px;border-radius:1px;font-weight:400;color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.3)}.tui-contact-list-card-right-application-text.data-v-b1be463d{color:#999;font-size:12px}.tui-contact-list-card-right-application-button.data-v-b1be463d{border:1px solid #006eff;background:#006eff;color:#fff;padding:3px 8px;border-radius:4px;font-size:12px;text-align:center;cursor:pointer;-webkit-user-select:none;user-select:none;line-height:150%}.tui-contact-list-card-right-application-button.data-v-b1be463d:after{border:none}.tui-contact-list-card-h5.data-v-b1be463d{cursor:none!important}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
7
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.json
vendored
Normal file
7
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.json
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"icon": "../../common/Icon",
|
||||
"contact-list-item": "./contact-list-item/index"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view wx:if="{{a}}" class="{{['data-v-12ce2ab3', 'tui-contact-list', c]}}"><view wx:for="{{b}}" wx:for-item="contactListObj" wx:key="i" class="tui-contact-list-item data-v-12ce2ab3"><view class="tui-contact-list-item-header data-v-12ce2ab3" bindtap="{{contactListObj.f}}"><view class="tui-contact-list-item-header-left data-v-12ce2ab3"><icon wx:if="{{contactListObj.b}}" class="data-v-12ce2ab3" u-i="{{contactListObj.a}}" bind:__l="__l" u-p="{{contactListObj.b}}"/><view class="data-v-12ce2ab3">{{contactListObj.c}}</view></view><view class="tui-contact-list-item-header-right data-v-12ce2ab3"><label wx:if="{{contactListObj.d}}" class="tui-contact-list-item-header-right-unread data-v-12ce2ab3">{{contactListObj.e}}</label></view></view><view class="{{['data-v-12ce2ab3', 'tui-contact-list-item-main', contactListObj.h]}}"><view wx:for="{{contactListObj.g}}" wx:for-item="contactListItem" wx:key="d" class="{{['tui-contact-list-item-main-item', 'data-v-12ce2ab3', 'selected']}}" bindtap="{{contactListItem.e}}"><contact-list-item wx:if="{{contactListItem.c}}" class="data-v-12ce2ab3" key="{{contactListItem.a}}" u-i="{{contactListItem.b}}" bind:__l="__l" u-p="{{contactListItem.c}}"/></view></view></view></view><view wx:else class="tui-contact-list data-v-12ce2ab3"><view wx:for="{{d}}" wx:for-item="item" wx:key="d" class="tui-contact-list-item data-v-12ce2ab3"><view wx:if="{{item.a}}" class="tui-contact-search-list data-v-12ce2ab3"><view class="tui-contact-search-list-title data-v-12ce2ab3">{{item.b}}</view><view wx:for="{{item.c}}" wx:for-item="listItem" wx:key="c" class="{{['tui-contact-search-list-item', 'data-v-12ce2ab3', 'selected']}}" bindtap="{{listItem.d}}"><contact-list-item wx:if="{{listItem.b}}" class="data-v-12ce2ab3" u-i="{{listItem.a}}" bind:__l="__l" u-p="{{listItem.b}}"/></view></view></view><view wx:if="{{e}}" class="tui-contact-search-list-default data-v-12ce2ab3">{{f}}</view></view>
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-list/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.tui-contact-list.data-v-12ce2ab3{flex:1;display:flex;flex-direction:column;width:100%;height:100%;overflow-y:auto;list-style:none}.tui-contact-list-item.data-v-12ce2ab3{display:flex;flex-direction:column}.tui-contact-list-item-header.data-v-12ce2ab3{display:flex;flex-direction:row;font-size:14px;cursor:pointer;-webkit-user-select:none;user-select:none;padding:10px 15px;justify-content:space-between}.tui-contact-list-item-header-left.data-v-12ce2ab3{display:flex;flex-direction:row;align-items:center}.tui-contact-list-item-header-right.data-v-12ce2ab3{display:flex;justify-content:center;align-items:center}.tui-contact-list-item-header-right-unread.data-v-12ce2ab3{display:flex;min-width:10px;width:-webkit-fit-content;width:fit-content;padding:0 2.5px;height:15px;font-size:10px;text-align:center;line-height:15px;border-radius:7.5px;background:red;align-items:center;justify-content:center;color:#fff}.tui-contact-list-item-main.data-v-12ce2ab3{padding:0 15px!important}.tui-contact-list-item-main.hidden.data-v-12ce2ab3{display:none}.tui-contact-list-item-main-item.data-v-12ce2ab3{padding:5px 0}.tui-contact-search-list.data-v-12ce2ab3{padding:0 15px!important}.tui-contact-search-list-title.data-v-12ce2ab3{font-size:14px;color:#999;border-bottom:1px solid #f4f5f9}.tui-contact-search-list-item.data-v-12ce2ab3{padding:5px 0}.tui-contact-search-list-default.data-v-12ce2ab3{padding:20px;text-align:center;font-size:14px;color:#999}.tui-contact-list-h5 .tui-contact-list-item .tui-contact-list-item-header.data-v-12ce2ab3{cursor:none}.tui-contact-list-h5 .tui-contact-list-item .tui-contact-list-item-header.data-v-12ce2ab3:active,.tui-contact-list-h5 .tui-contact-list-item .tui-contact-list-item-main-item.data-v-12ce2ab3:active{background-color:#eef0f3}body.data-v-12ce2ab3,div.data-v-12ce2ab3,ul.data-v-12ce2ab3,ol.data-v-12ce2ab3,dt.data-v-12ce2ab3,dd.data-v-12ce2ab3,li.data-v-12ce2ab3,dl.data-v-12ce2ab3,h1.data-v-12ce2ab3,h2.data-v-12ce2ab3,h3.data-v-12ce2ab3,h4.data-v-12ce2ab3,p.data-v-12ce2ab3{margin:0;padding:0;font-style:normal}ol.data-v-12ce2ab3,ul.data-v-12ce2ab3,li.data-v-12ce2ab3{list-style:none}img.data-v-12ce2ab3{border:0;vertical-align:middle;pointer-events:none}body.data-v-12ce2ab3{color:#000;background:#fff}.clear.data-v-12ce2ab3{clear:both;height:1px;width:100%;overflow:hidden;margin-top:-1px}a.data-v-12ce2ab3{color:#000;text-decoration:none;cursor:pointer}a.data-v-12ce2ab3:hover{text-decoration:none}input.data-v-12ce2ab3,textarea.data-v-12ce2ab3{-webkit-user-select:auto;user-select:auto}input.data-v-12ce2ab3:focus,input.data-v-12ce2ab3:active,textarea.data-v-12ce2ab3:focus,textarea.data-v-12ce2ab3:active{outline:none}.chat-aside.data-v-12ce2ab3{position:absolute;top:50px;right:0;box-sizing:border-box;width:360px!important;border-radius:8px 0 0 8px;z-index:9999;max-height:calc(100% - 50px)}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../../../../common/vendor.js");require("../../../adapter-vue.js");const r=require("../../../../common/assets.js"),a=require("../../../utils/env.js"),t=require("../../../utils/lodash.js");Math||u();const u=()=>"../../common/Icon.js",n=e.defineComponent({__name:"index",setup(u){const n=e.Wt.t("TUIContact.输入ID"),c=e.ref(!1),s=e.ref(""),o=e.ref({user:{label:"联系人",list:[]},group:{label:"群聊",list:[]}}),i=t.debounce((function(e){c.value=e}),200),l=async()=>{s.value&&(e.R.callService({serviceName:e.E.TUISearch.SERVICE.NAME,method:e.E.TUISearch.SERVICE.METHOD.SEARCH_USER,params:{userID:s.value}}).then((e=>{o.value.user.list=e.data})).catch((e=>{o.value.user.list=[],console.warn("search user error",e)})),e.R.callService({serviceName:e.E.TUISearch.SERVICE.NAME,method:e.E.TUISearch.SERVICE.METHOD.SEARCH_GROUP,params:{groupID:s.value}}).then((e=>{o.value.group.list=[e.data.group]})).catch((e=>{o.value.group.list=[],console.warn("search group error",e)})))};return e.watch((()=>o.value),(()=>{e.Jt.update(e.o.CUSTOM,"currentContactSearchResult",o.value)}),{deep:!0,immediate:!0}),e.watch((()=>c.value),(()=>{e.Jt.update(e.o.CUSTOM,"currentContactSearchingStatus",c.value),c.value&&(s.value="",o.value.user.list=[],o.value.group.list=[])}),{deep:!0,immediate:!0}),e.i.updateContactSearch=l,e.i.closeSearching=()=>{c.value=!1},(t,u)=>e.e({a:!e.unref(c)||!e.unref(a.isPC)},e.unref(c)&&e.unref(a.isPC)?{}:{b:e.p({file:e.unref(c)?e.unref(r.backIcon):e.unref(r.addSVG),width:e.unref(c)?"20px":"14px",height:e.unref(c)?"20px":"14px"}),c:e.n(!e.unref(a.isPC)&&"tui-contact-search-h5-header-icon"),d:e.o$1((r=>e.unref(i)(!e.unref(c)))),e:e.t(e.unref(e.Wt).t("TUIContact.添加好友/群聊")),f:e.n(!e.unref(a.isPC)&&"tui-contact-search-h5-header-title"),g:e.n(!e.unref(a.isPC)&&"tui-contact-search-h5-header"),h:e.n(e.unref(c)&&"tui-contact-searching-h5-header"),i:e.o$1((r=>e.unref(i)(!0)))},{j:e.unref(c)},e.unref(c)?{k:e.unref(n),l:e.o$1(l),m:e.o$1(l),n:e.o$1(l),o:e.unref(s),p:e.o$1((r=>e.isRef(s)?s.value=r.detail.value:null)),q:e.t(e.unref(e.Wt).t("取消")),r:e.o$1((e=>c.value=!1)),s:e.n(!e.unref(a.isPC)&&"tui-contact-search-h5-main")}:{},{t:e.n(!e.unref(a.isPC)&&"tui-contact-search-h5")})}}),c=e._export_sfc(n,[["__scopeId","data-v-d5e20145"]]);wx.createComponent(c);
|
||||
6
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.json
vendored
Normal file
6
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"icon": "../../common/Icon"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view class="{{['data-v-d5e20145', 'tui-contact-search', t]}}"><view wx:if="{{a}}" class="{{['data-v-d5e20145', 'tui-contact-search-header', g, h]}}" bindtap="{{i}}"><view class="{{['data-v-d5e20145', 'tui-contact-search-header-icon', c]}}" catchtap="{{d}}"><icon wx:if="{{b}}" class="data-v-d5e20145" u-i="d5e20145-0" bind:__l="__l" u-p="{{b}}"/></view><view class="{{['data-v-d5e20145', 'tui-contact-search-header-title', f]}}">{{e}}</view></view><view wx:if="{{j}}" class="{{['data-v-d5e20145', 'tui-contact-search-main', s]}}"><input class="tui-contact-search-main-input data-v-d5e20145" type="text" placeholder="{{k}}" enterkeyhint="search" bindkeyup="{{l}}" bindblur="{{m}}" bindconfirm="{{n}}" value="{{o}}" bindinput="{{p}}"></input><view class="tui-contact-search-main-cancel data-v-d5e20145" bindtap="{{r}}">{{q}}</view></view></view>
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/contact-search/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.tui-contact-search.data-v-d5e20145{position:-webkit-sticky;position:sticky;top:0;z-index:1;padding:12px;display:flex;justify-content:space-between;align-items:center;background:#fff;border-bottom:1px solid #f4f5f9;flex-direction:column}.tui-contact-search-header.data-v-d5e20145,.tui-contact-search-main.data-v-d5e20145{width:100%;height:30px;display:flex;flex-direction:row;align-items:center}.tui-contact-search-header.data-v-d5e20145{-webkit-user-select:none;user-select:none;cursor:pointer}.tui-contact-search-header-icon.data-v-d5e20145{padding-right:10px}.tui-contact-search-header-title.data-v-d5e20145{font-size:14px}.tui-contact-search-main.data-v-d5e20145{display:flex;flex-direction:row;flex:1;justify-content:center;align-items:center;width:100%}.tui-contact-search-main-input.data-v-d5e20145{flex:1;font-size:14px;border-radius:5px;padding:7px;border:1px solid #ddd}.tui-contact-search-main-input.data-v-d5e20145:focus{outline:none;border:1px solid #006eff}.tui-contact-search-main-cancel.data-v-d5e20145{padding-left:10px;-webkit-user-select:none;user-select:none;cursor:pointer}.tui-contact-search-h5-header.data-v-d5e20145{width:100%}.tui-contact-searching-h5-header.data-v-d5e20145{padding-bottom:10px;display:flex;flex-direction:row}.tui-contact-searching-h5-header .tui-contact-search-h5-header-title.data-v-d5e20145{flex:1;text-align:center;font-weight:500;font-size:14px;margin-right:30px}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../index.js");wx.createPage(e.MiniProgramPage$2);
|
||||
9
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.json
vendored
Normal file
9
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.json
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"navigationBarTitleText": "腾讯云 IM",
|
||||
"usingComponents": {
|
||||
"select-friend": "./select-friend/index",
|
||||
"contact-search": "./contact-search/index",
|
||||
"contact-list": "./contact-list/index",
|
||||
"contact-info": "./contact-info/index"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<select-friend wx:if="{{a}}" class="data-v-fd60a8e2" u-i="fd60a8e2-0" bind:__l="__l"/><view wx:elif="{{b}}" class="{{['data-v-fd60a8e2', 'tui-contact', h]}}"><view class="{{['data-v-fd60a8e2', 'tui-contact-left', d]}}"><contact-search class="data-v-fd60a8e2" u-i="fd60a8e2-1" bind:__l="__l"/><contact-list class="{{['data-v-fd60a8e2', 'tui-contact-left-list', c]}}" u-i="fd60a8e2-2" bind:__l="__l"/></view><view wx:if="{{e}}" class="{{['data-v-fd60a8e2', 'tui-contact-right', g]}}"><contact-info class="data-v-fd60a8e2" bindswitchConversation="{{f}}" u-i="fd60a8e2-3" bind:__l="__l"/></view></view>
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/index.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
||||
body.data-v-fd60a8e2,div.data-v-fd60a8e2,ul.data-v-fd60a8e2,ol.data-v-fd60a8e2,dt.data-v-fd60a8e2,dd.data-v-fd60a8e2,li.data-v-fd60a8e2,dl.data-v-fd60a8e2,h1.data-v-fd60a8e2,h2.data-v-fd60a8e2,h3.data-v-fd60a8e2,h4.data-v-fd60a8e2,p.data-v-fd60a8e2{margin:0;padding:0;font-style:normal}ol.data-v-fd60a8e2,ul.data-v-fd60a8e2,li.data-v-fd60a8e2{list-style:none}img.data-v-fd60a8e2{border:0;vertical-align:middle;pointer-events:none}body.data-v-fd60a8e2{color:#000;background:#fff}.clear.data-v-fd60a8e2{clear:both;height:1px;width:100%;overflow:hidden;margin-top:-1px}a.data-v-fd60a8e2{color:#000;text-decoration:none;cursor:pointer}a.data-v-fd60a8e2:hover{text-decoration:none}input.data-v-fd60a8e2,textarea.data-v-fd60a8e2{-webkit-user-select:auto;user-select:auto}input.data-v-fd60a8e2:focus,input.data-v-fd60a8e2:active,textarea.data-v-fd60a8e2:focus,textarea.data-v-fd60a8e2:active{outline:none}.chat-aside.data-v-fd60a8e2{position:absolute;top:50px;right:0;box-sizing:border-box;width:360px!important;border-radius:8px 0 0 8px;z-index:9999;max-height:calc(100% - 50px)}.tui-contact.data-v-fd60a8e2{width:100%;height:100%;box-sizing:border-box;display:flex;overflow:hidden}.tui-contact-left.data-v-fd60a8e2{min-width:285px;flex:0 0 24%;overflow:hidden;display:flex;flex-direction:column}.tui-contact-right.data-v-fd60a8e2{border-left:1px solid #f4f5f9;flex:1;overflow:hidden}.tui-contact-h5.data-v-fd60a8e2{position:relative}.tui-contact-h5-left.data-v-fd60a8e2,.tui-contact-h5-right.data-v-fd60a8e2{width:100%;height:100%;flex:1}.tui-contact-h5-right.data-v-fd60a8e2{position:absolute;z-index:100}.tui-contact-h5-left-list.data-v-fd60a8e2{overflow-y:auto}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../../../../common/vendor.js");require("../../../adapter-vue.js");const a=require("../../common/Toast/index.js"),t=require("../server.js"),r=require("../../common/Toast/type.js");Math||s();const s=()=>"../../common/SelectUser/index.js",n=e.defineComponent({__name:"index",setup(s){const n=t.TUIContactServer.getInstance(),o=n.constants,i=e.ref(!1),c=e.ref([]),u=e.ref([]),l=e.ref(null),d=e.ref({isRadio:!1,isNeedSearch:!1,title:""});e.watchEffect((()=>{const a=n.getOnCallParams(o.TUIContact.SERVICE.METHOD.SELECT_FRIEND);var t;d.value.title=a.title,d.value.isRadio=a.isRadio,d.value.isNeedSearch=a.isNeedSearch,a.isNeedSearch&&(t=a.isNeedSearch,l.value=e.R.getService(o.TUISearch.SERVICE.NAME),l.value?i.value=t:console.warn("请添加 TUISearch 组件")),e.ts.getFriendList().then((e=>{c.value=e.data.map((e=>e.profile)),u.value=c.value})).catch((e=>{console.warn("getFriendList error:",e)}))}));const v=a=>{e.Jt.update(e.o.CUSTOM,"isShowSelectFriendComponent",!1);const t=n.getOnCallCallback(o.TUIContact.SERVICE.METHOD.SELECT_FRIEND);t&&t(a)},S=()=>{a.Toast({message:e.Wt.t("TUIGroup.该用户不存在"),type:r.TOAST_TYPE.ERROR}),u.value=[...c.value]},E=async e=>{if(!e)return u.value=c.value;try{const a=await l.value.searchUser(e);if(!a.data[0])return S();u.value=a.data;const t=c.value.filter((e=>e.userID===a.data[0].userID));c.value=t.length?c.value:[...c.value,...u.value]}catch(a){return S()}};return(a,t)=>({a:e.o$1(E),b:e.o$1(v),c:e.p({isRadio:e.unref(d).isRadio,isNeedSearch:e.unref(d).isNeedSearch,title:e.unref(d).title,userList:e.unref(u)})})}});wx.createComponent(n);
|
||||
6
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.json
vendored
Normal file
6
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"select-user": "../../common/SelectUser/index"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<select-user wx:if="{{c}}" bindsearch="{{a}}" bindcomplete="{{b}}" u-i="ffa11ea6-0" bind:__l="__l" u-p="{{c}}"/>
|
||||
0
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.wxss
vendored
Normal file
0
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/select-friend/index.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/server.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/server.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const a=require("../../../common/vendor.js"),t=require("../../utils/env.js");class n{constructor(){a.R.registerService(a.E.TUIContact.SERVICE.NAME,this),this.onCallParamsMap=new Map,this.onCallCallbackMap=new Map,this.constants=a.E}static getInstance(){return n.instance||(n.instance=new n),n.instance}getOnCallParams(a){return this.onCallParamsMap.get(a)}getOnCallCallback(a){return this.onCallCallbackMap.get(a)}async onCall(n,e,s){var l;this.onCallParamsMap.set(n,e),this.onCallCallbackMap.set(n,s),n===a.E.TUIContact.SERVICE.METHOD.SELECT_FRIEND&&(a.Jt.update(a.o.CUSTOM,"isShowSelectFriendComponent",!0),t.isUniFrameWork&&(null==(l=a.i)||l.reLaunch({url:"/TUIKit/components/TUIContact/index"})))}}exports.TUIContactServer=n;
|
||||
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/utils/index.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/TUIKit/components/TUIContact/utils/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user