!function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=5)}([function(t,e){t.exports=globalTool},function(t,e){t.exports=globalBus},function(t,e){var n=/^(attrs|props|on|nativeOn|class|style|hook)$/;function r(t,e){return function(){t&&t.apply(this,arguments),e&&e.apply(this,arguments)}}t.exports=function(t){return t.reduce((function(t,e){var o,i,s,a,u;for(s in e)if(o=t[s],i=e[s],o&&n.test(s))if("class"===s&&("string"==typeof o&&(u=o,t[s]=o={},o[u]=!0),"string"==typeof i&&(u=i,e[s]=i={},i[u]=!0)),"on"===s||"nativeOn"===s||"hook"===s)for(a in i)o[a]=r(o[a],i[a]);else if(Array.isArray(o))t[s]=o.concat(i);else if(Array.isArray(i))t[s]=[o].concat(i);else for(a in i)o[a]=i[a];else t[s]=e[s];return t}),{})}},function(t,e){t.exports=globalVue},function(t,e){t.exports=globalCommonMix},function(t,e,n){"use strict";n.r(e);var r=n(2),o=n.n(r),i=n(3),s=n.n(i),a=n(1),u=n.n(a),l=n(4),c=n.n(l),f=n(0),d=n.n(f),m=window.navigator.userAgent,p="",y={tt:{domain:"webcast.tiktokv.com",aid:"1180"},ttm:{domain:"webcast-va.tiktokv.com",aid:"1233"}},g=y[p=m.match(/trill/i)?"tt":m.match(/musical_ly/i)?"ttm":"aweme"===d.a.ENV().channel?"tt":"muse"===d.a.ENV().channel?"ttm":"activity.tiktok.com"===location.hostname?"tt":"ttm"].domain,h=y[p].aid,v=function(t,e){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return function(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(u){o=!0,i=u}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}(t,e);throw new TypeError("Invalid attempt to destructure non-iterable instance")},b=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e="";return t.length>0&&t.map((function(t){(/.png/gi.test(t)||!e&&/.jpeg/gi.test(t))&&(e=t)})),e},w=function(t,e){d.a.inApp()?(u.a.getData({url:"https://"+g+"/webcast/user/relation/update/",type:"jsbridge",method:"POST",params:{to_user_id:e.userId,follow_type:t}}).then((function(n){if((n=d.a.unifyRes(n))&&0==n.status_code){e.followStatus=t,e.btnType={0:"follow",1:"followed"}[t],u.a.$emit("updateItem",e)}else 20003==n.status_code&&u.a.$emit("hybrid",{gotype:"login"})})),d.a.sendLog("follow",{user_id:e.userId,isfollow:t})):d.a.ENV().isDebug||d.a.backToApp()},_=Object.assign||function(t){for(var e=1;e0?(e=t,n=d.a.inApp()?"jsbridge":"http",r="//"+g+"/webcast/room/mget_user_info?sec_user_ids="+e+"&source=mofang",o=d.a.inApp()?r:r+"&aid="+h,u.a.getData({type:n,url:o,method:"POST",cors:!0}).then((function(t){if(0!==(t=d.a.unifyRes(t)).status_code)throw new Error("直播间数据返回错误");var n={},r=t.data,o=!0,i=!1,s=void 0;try{for(var a,u=Object.entries(r)[Symbol.iterator]();!(o=(a=u.next()).done);o=!0){var l=a.value,c=v(l,2),f=c[0],m=c[1],p=m.rooms,y=m.user;n[y.sec_uid]={userId:f||y.id_str,avatar:b(y.avatar_thumb.url_list),nickname:y.nickname,secUid:y.sec_uid,displayId:y.display_id,isLiving:Boolean(p.length),followStatus:y.follow_info.follow_status,roomId:0===p.length?0:p[0].id_str}}}catch(g){i=!0,s=g}finally{try{!o&&u.return&&u.return()}finally{if(i)throw s}}return e.split(",").map((function(t){return n[t]}))})).catch((function(t){return console.log(t.message),[]}))).then((function(t){i.userList=t})):this.userList=[]},initEvent:function(){var t=this;u.a.$on("updateItem",(function(e){t.userList=t.userList.map((function(t){return e.userId===t.userId&&(t.followStatus=e.followStatus),t})),t.$forceUpdate()}))},onHandleBtnClick:function(t){if(!this.isDebug)if("enter"===t.btnType){d.a.sendLog("goLiveRoom",{user_id:t.userId,room_id:t.roomId});var e=(d.a.getQueryString(location.href)||{}).source||"";d.a.getVersion()>=1040?location.href="sslocal://webcast_room?room_id="+t.roomId+"&user_id="+t.userId+"&sec_uid="+t.secUid+"&enter_from=magic_web_"+e+"&enter_from_merge=magic_web_"+e:location.href="snssdk"+h+"://live?room_id="+t.roomId+"&user_id="+t.userId+"&enter_method=web&style=web&from=magic&enter_from=magic_web_"+e+"&enter_from_merge=magic_web_"+e}else"follow"===t.btnType?w(1,t):"followed"===t.btnType&&w(0,t)},onGoUser:function(t){this.isDebug||(d.a.sendLog("goUser",{user_id:t.userId}),navigator.userAgent.match(/WebcastSDK/)?location.href="sslocal://webcast_profile?type=full&user_id="+t.userId+"&sec_uid="+t.secUid:location.href="snssdk"+h+"://user/profile/"+t.userId+"?sec_uid="+t.secUid)},getActionBtn:function(t){return{follow:this.followImg,followed:this.followedImg,enter:this.enterImg}[t.btnType]},parseUserList:function(){var t=this.userList.filter((function(t){return t.isLiving})),e=this.userList.filter((function(t){return!t.isLiving}));return[].concat(S(t),S(e))},parseCustomUserList:function(t){var e=this.userInfo,n=this.clone(t);return e.map((function(t){n.map((function(e){t[0].secUid==e.secUid&&(e.nickname=t[1].text)}))})),n},clone:function(t){var e=t.constructor===Array?[]:{};if("object"===(void 0===t?"undefined":I(t))){for(var n in t)e[n]="object"===I(t[n])?this.clone(t[n]):t[n];return e}}},render:function(t){var e=this,n=function(n){n.btnType||(n.isLiving?n.btnType="enter":0!==n.followStatus?n.btnType="followed":n.btnType="follow");var r=e.showcontent.indexOf("avatar")>-1?t("div",o()([{class:"m-avatar",style:{backgroundImage:"url("+n.avatar+")"}},{on:{click:function(t){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i-1?t("div",{directives:[{name:"show",value:n.isLiving||e.isDebug}],class:"m-live-icon",style:{backgroundImage:"url("+e.liveIconImg+")"}}):null,s=e.showcontent.indexOf("id")>-1?t("div",o()([{directives:[{name:"show",value:n.nickname}],class:"m-topic"},{on:{click:function(t){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i-1?t("div",o()([{class:"m-tittokid"},{on:{click:function(t){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i-1?t("div",o()([{class:"m-btn",style:{backgroundImage:"url("+e.getActionBtn(n)+")"}},{on:{click:function(t){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i1},style:e.itemStyle},[r,i,s,a,u])},r=1===this.showorder?this.userList:this.parseUserList(),i=[];"enable"===this.custom?i=this.parseCustomUserList(r).map((function(t){return n(t)})):i=r.map((function(t){return n(t)}));return this.vvisible?t("div",{style:this.styles,class:_({ttuserlist:!0,component:!0},this.classes),attrs:{id:this.id}},[i]):null}})}]);