code:1,dataType:"json",H5Request:!0})} /*! * cookie * Copyright(c) 2012-2014 Roman Shtylman * Copyright(c) 2015 Douglas Christopher Wilson * MIT Licensed */function BT(e){let t="";const{getHost:n,getChannel:o}=window.IcbuIM&&window.IcbuIM.IMSDKHelper||{},r=window.IcbuIM&&window.IcbuIM.IMBaaSSDK&&window.IcbuIM.IMBaaSSDK.default,{getLinkVars:i}=window.IcbuIM&&window.IcbuIM.CommonUtil||{};if("string"==typeof e)t=e;else if("object"==typeof e){const{ext:n,bizData:o,resultCode:r,errCode:i,resultMsg:a,errMsg:s}=e;t=n;const l={actionName:n,bizData:o,context:window.navigator.userAgent,resultCode:r||i,resultMsg:a||s};for(const n in e)["ext","bizData","resultCode","errCode","resultMsg","errMsg","clickId"].includes(n)||(t+=`&${n}=${e[n]}`);t+=`&operateContent=${encodeURIComponent(JSON.stringify(l))}`}else console.error("goldlog::params\u7c7b\u578b\u9519\u8bef",e);if(t+=`&uid=${window.aliId||"unknown"}`,n&&(t+=`&host=${n()}`),o&&(t+=`&imChannel=${o()}`),i){const{traceId:e}=i(window.location.search);t+=`&urlTraceId=${e}`}r&&(t+=`&connectionStatus=${r.getAuthService().connectionStatus}`),window.navigator&&(t+=`&hardwareConcurrency=${window.navigator.hardwareConcurrency||0}`),window.__BB&&(t+=`&bbScene=${window.__BB.scene||""}`);let a="";if(a=window.pageId?`page_id=${window.pageId}&ext=${encodeURIComponent(t)}`:`ext=${encodeURIComponent(t)}`,window.goldlog&&window.goldlog.record)setTimeout((()=>{window.goldlog.record(`${e&&e.clickId||"/sc.ma.im"}`,"CLK",a,"GET")}),0);else{const t=undefined;(window.goldlog_queue||(window.goldlog_queue=[])).push({action:"goldlog.record",arguments:[`${e&&e.clickId||"/sc.ma.im"}`,"CLK",a,"GET"]})}}const VT=ly({parsePage:!0,namespace:(window.mcmsWithoutAppName?"":"intl-gangesweb.")+"cloudDisk"}),KT=12e4,WT="preview",ZT="download",UT=["heic","pdf","doc","docx","xls","xlsx","ppt","pptx","txt","dwt","dxf","igs","stl","slprt","numbers","key","wps","page","fdf","frt","mar","jpe","tif","fax","mp3","rm","rmvb","ram","fla","flc","flv","gl","m3d","mkv","mpe","psd","ai","cad","cdr","drw","mpp","2d","3d","sketch","csv","xml","step","mp4","mpg","mpeg","avi","wmv","mov","swf","png","jpg","jpeg","gif","bmp","webp"],YT={godLightCheck(e,t={}){const{contactAccountId:n,materialType:o,gmtCreateLong:r,id:i,parentId:a}=t,s={appkey:"OneChat",id:i,parentId:a,secOperateAliId:"MC1IDX1fNII63x-mBZVsc-GEiuelr4iFciWKhNAoLEjAowHKZleBZ7NLoIrGwcFizUcYYn_",scene:1};return new Promise((t=>{zT(s).then((i=>{const a=i&&1*i.data;switch(BT({ext:"checkFileScanStatusSuccess",bizData:{status:a,contactAccountId:n}}),a){case 1:BT({ext:"checkFileStop",bizData:{contactAccountId:n}}),El.show({v2:!0,prefix:"im-cloud-drive-",title:Nm.jsxs("div",{children:[Nm.jsx(ko,{prefix:"im-cloud-drive-",type:"warning",style:{color:"#FFA003",marginRight:"10px"}}),Nm.jsx("span",{children:VT.get("fileCheck.stopTitle")||"\u75c5\u6bd2\u63d0\u793a"})]}),content:VT.get("fileCheck.stopContent")||"\u6587\u4ef6\u5b58\u5728\u75c5\u6bd2\uff01\u8bf7\u52ff\u4e0b\u8f7d",footerActions:["ok"],onOk:()=>{BT({ext:"fileStopAccepted",bizData:{contactAccountId:n}}),t(!1)},onClose:()=>{BT({ext:"fileStopClose",bizData:{contactAccountId:n}}),t(!1)},okProps:{children:VT.get("fileCheck.sure")||"\u786e\u5b9a"}});break;case 4:BT({ext:"checkFileWarn",bizData:{contactAccountId:n}}),El.show({v2:!0,prefix:"im-cloud-drive-",title:Nm.jsxs("div",{children:[Nm.jsx(ko,{prefix:"im-cloud-drive-",type:"prompt",style:{color:"#FFA003",marginRight:"10px"}}),Nm.jsx("span",{children:VT.get("fileCheck.warnTitle")||"\u98ce\u9669\u63d0\u793a"})]}),content:VT.get("fileCheck.warnContent")||"\u6587\u4ef6\u5b89\u5168\u6027\u4f4e\uff01\u8bf7\u8c28\u614e\u4e0b\u8f7d",footerActions:["cancel","ok"],onOk:()=>{BT({ext:"fileWarnAccepted",bizData:{contactAccountId:n}}),t(!1)},onCancel:()=>{BT({ext:"fileWarnRefused",bizData:{contactAccountId:n}}),t(!0)},onClose:()=>{BT({ext:"fileWarnClose",bizData:{contactAccountId:n}}),t(!1)},okProps:{children:VT.get("fileCheck.close")||"\u5173\u95ed"},cancelProps:{children:(e===WT?VT.get("fileCheck.goOnPreview"):VT.get("fileCheck.goOnDownload"))||"\u7ee7\u7eed\u4e0b\u8f7d/\u9884\u89c8"}});break;case 2:if(Date.now()-r<=KT){BT({ext:"checkFileWarn",bizData:{contactAccountId:n}}),El.show({v2:!0,prefix:"im-cloud-drive-",title:Nm.jsxs("div",{children:[Nm.jsx(ko,{prefix:"im-cloud-drive-",type:"prompt",style:{color:"#65c9f5",marginRight:"10px"}}),Nm.jsx("span",{children:VT.get("fileCheck.noticeTitle")||"\u6587\u4ef6\u5b89\u5168\u626b\u63cf\u4e2d"})]}),content:VT.get("fileCheck.noticeContent")||"\u6587\u4ef6\u5b89\u5168\u626b\u63cf\u4e2d\uff0c\u8bf7\u518d\u626b\u63cf\u5b8c\u6210\u540e\u518d\u9884\u89c8",footerActions:["cancel","ok"],onOk:()=>{BT({ext:"fileNoticeAccepted",bizData:{contactAccountId:n}}),t(!1)},onCancel:()=>{BT({ext:"fileNoticeRefused",bizData:{contactAccountId:n}}),t(!0)},onClose:()=>{BT({ext:"fileNoticeClose",bizData:{contactAccountId:n}}),t(!1)},okProps:{children:VT.get("fileCheck.close")||"\u5173\u95ed"},cancelProps:{children:(e===WT?VT.get("fileCheck.goOnPreview"):VT.get("fileCheck.goOnDownload"))||"\u7ee7\u7eed\u4e0b\u8f7d/\u9884\u89c8"}});break}default:UT.includes(o.toLowerCase())?(BT({ext:"checkFilePass",bizData:{contactAccountId:n}}),t(!0)):(BT({ext:"checkFileWarn",bizData:{contactAccountId:n}}),El.show({v2:!0,prefix:"im-cloud-drive-",title:Nm.jsxs("div",{children:[Nm.jsx(ko,{prefix:"im-cloud-drive-",type:"prompt",style:{color:"#FFA003",marginRight:"10px"}}),Nm.jsx("span",{children:VT.get("fileCheck.mumaTitle")||"\u6728\u9a6c\u98ce\u9669\u63d0\u793a"})]}),content:VT.get("fileCheck.mumaContent")||"\u8be5\u6587\u4ef6\u7c7b\u578b\u53ef\u80fd\u5b58\u5728\u6728\u9a6c\uff0c\u8bf7\u8c28\u614e\u4e0b\u8f7d",footerActions:["cancel","ok"],onOk:()=>{BT({ext:"fileMumaAccepted",bizData:{contactAccountId:n}}),t(!1)},onCancel:()=>{BT({ext:"fileMumaRefused",bizData:{contactAccountId:n}}),t(!0)},onClose:()=>{BT({ext:"fileMumaClose",bizData:{contactAccountId:n}}),t(!1)},okProps:{children:VT.get("fileCheck.close")||"\u5173\u95ed"},cancelProps:{children:(e===WT?VT.get("fileCheck.goOnPreview"):VT.get("fileCheck.goOnDownload"))||"\u7ee7\u7eed\u4e0b\u8f7d/\u9884\u89c8"}}))}})).catch((e=>{console.error("==== checkFileScanStatus failed ====",e),BT({ext:"checkFileScanStatusFail",resultMsg:e&&e.message,bizData:{contactAccountId:n}}),t(!0)}))}))}},qT=ly({parsePage:!0,namespace:(window.mcmsWithoutAppName?"":"intl-gangesweb.")+"cloudDisk"}),$T=[{key:0,title:qT.get("recentFilesTabTitle")||"Recent"},{key:1,title:qT.get("myFilesTabTitle")||"My drive"}],GT={ALL:"all",DOC:"document",MEDIA:"media"},JT=[{key:GT.ALL,pageSize:20,title:qT.get("filesTypeAll")||"All"},{key:GT.DOC,pageSize:20,title:qT.get("filesTypeDocs")||"Files"},{key:GT.MEDIA,pageSize:40,title:qT.get("filesTypePhotos")||"Photos & videos"}],XT={entry:"2020MC_CloudDrive_ICON_Click",tab_0:"2020MC_CloudDrive_RecentFiles_Click",tab_1:"2020MC_CloudDrive_MyFiles_Click",[`tab_0_${GT.All}`]:"2020MC_CloudDrive_RecentFiles_All_Click",[`tab_0_${GT.DOC}`]:"2020MC_CloudDrive_RecentFiles_Docs_Click",[`tab_0_${GT.MEDIA}`]:"2020MC_CloudDrive_RecentFiles_Photos_Click",[`tab_1_${GT.All}`]:"2020MC_CloudDrive_MyFiles_All_Click",[`tab_1_${GT.DOC}`]:"2020MC_CloudDrive_MyFiles_Docs_Click",[`tab_1_${GT.MEDIA}`]:"2020MC_CloudDrive_MyFiles_Photos_Click",preview:"2020MC_CloudDrive_ListItem_Preview_Click",download:"2020MC_CloudDrive_ListItem_Download_Click",locate:"2020MC_CloudDrive_ListItem_LocateToChat_Click",delete:"2020MC_CloudDrive_ListItem_Delete_Click",search:"2020MC_CloudDrive_Search_Click",pagination:"2020MC_CloudDrive_Pagination_Click",closePreview:"2020MC_close_file_view"};function QT(){const e=document.cookie.match(/xman_us_f=([^;]+)/),t=e&&e[1];let n="";if(t){const e=t.match(/x_user=([^&"]+)/),o=e&&e[1];if(o){const e=o.split("|");n=e[e.length-1]||""}}return n}function ek(){const e=localStorage.getItem(`${QT()}-firstPageDriveFileList`);try{return e?JSON.parse(e):null}catch(e){return null}}function tk(e){localStorage.setItem(`${QT()}-firstPageDriveFileList`,JSON.stringify(e))}class nk extends p.Component{constructor(e){super(e),gm(this,"goldlog",(e=>{const{channel:t}=this.props;return t&&(e+=`&channel=${t}`),_m(e)})),gm(this,"onSearch",(e=>{this.fetchList({searchField:e})})),gm(this,"onSearchInputChange",(e=>{this.searchField=e})),gm(this,"fetchList",(async(e={})=>{const t=this.levelType,n=this.fileType[this.levelType],o=this.fileTypeTabs.find((e=>e.key===n));if(!o)return console.error(`params [fileType: ${n}] is invalid`),!1;const r=undefined,i={pageSize:o?o.pageSize:20,currentPage:1,levelType:this.props.isGroupChat&&0===t?2:t,fileType:n==GT.