/*! For license information please see webapp-desktop.c9a013dafca480fd60e8.js.LICENSE.txt */ (self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[1127],{7399:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});var i=n(24643),o=n(40099),a=n(84987);const r={id:"right-arrow-5237fc96",use:"right-arrow-5237fc96-usage",viewBox:"0 0 17 16",content:''};function s(e){const t=(0,o.useContext)(a.X);return(0,o.useLayoutEffect)((()=>(t.add(r),()=>{t.remove("right-arrow-5237fc96")})),[]),(0,i.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,i.jsx)("use",{xlinkHref:"#right-arrow-5237fc96"},void 0)}),void 0)}},75972:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});var i=n(24643),o=n(40099),a=n(84987);const r={id:"header-arrow-f8c49d4b",use:"header-arrow-f8c49d4b-usage",viewBox:"0 0 24 24",content:''};function s(e){const t=(0,o.useContext)(a.X);return(0,o.useLayoutEffect)((()=>(t.add(r),()=>{t.remove("header-arrow-f8c49d4b")})),[]),(0,i.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,i.jsx)("use",{xlinkHref:"#header-arrow-f8c49d4b"},void 0)}),void 0)}},8475:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});var i=n(24643),o=n(40099),a=n(84987);const r={id:"right-arrow-5237fc96",use:"right-arrow-5237fc96-usage",viewBox:"0 0 17 16",content:''};function s(e){const t=(0,o.useContext)(a.X);return(0,o.useLayoutEffect)((()=>(t.add(r),()=>{t.remove("right-arrow-5237fc96")})),[]),(0,i.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,i.jsx)("use",{xlinkHref:"#right-arrow-5237fc96"},void 0)}),void 0)}},86702:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});var i=n(24643),o=n(40099),a=n(84987);const r={id:"logo-dark-c4561408",use:"logo-dark-c4561408-usage",viewBox:"0 0 118 42",content:''};function s(e){const t=(0,o.useContext)(a.X);return(0,o.useLayoutEffect)((()=>(t.add(r),()=>{t.remove("logo-dark-c4561408")})),[]),(0,i.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,i.jsx)("use",{xlinkHref:"#logo-dark-c4561408"},void 0)}),void 0)}},93678:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});var i=n(24643),o=n(40099),a=n(84987);const r={id:"logo-light-0ca3c974",use:"logo-light-0ca3c974-usage",viewBox:"0 0 118 30",content:''};function s(e){const t=(0,o.useContext)(a.X);return(0,o.useLayoutEffect)((()=>(t.add(r),()=>{t.remove("logo-light-0ca3c974")})),[]),(0,i.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,i.jsx)("use",{xlinkHref:"#logo-light-0ca3c974"},void 0)}),void 0)}},77734:(e,t,n)=>{"use strict";n.d(t,{GC:()=>k,xX:()=>x,Ak:()=>w,VB:()=>b});var i,o=n(58632),a=n(64162),r=n(4126),s=n(93995),l=n(23999),c=n(26324),d=n(62564),u=n(8536),p=n(98812),v=n(95719),m=n(57431),g=n(16469),h=n(50970),_=n(7672),f=n(55099);!function(e){e[e.Int=1]="Int",e[e.Bool=2]="Bool",e[e.String=3]="String"}(i||(i={}));let y=class{constructor(e){this.fetch=e}postScheduleRecord(e){return this.fetch.post("/api/v1/post_schedule/ack/",{query:Object.assign(Object.assign({},e),{tt_csrf_token:this.fetch.csrfToken})})}updateRedDot(e){return this.fetch.post("/api/reddot/report",{query:Object.assign({},e)})}queryLongVideoTooltipVisibility(e){return this.fetch.post("/tiktok/popup/display/v1/",{query:Object.assign({},e)})}updateLongVideoToolTipVisibility(e){return this.fetch.post("/tiktok/popup/report/v1/",{query:Object.assign({},e)})}};y=(0,o.__decorate)([(0,_._)(),(0,o.__metadata)("design:paramtypes",[f.p])],y);const b="upload-long-video",w="series-tip",x="upload-podcast";var T;!function(e){e[e.Schedule=0]="Schedule",e[e.LongVideo=1]="LongVideo",e[e.Podcast=2]="Podcast"}(T||(T={}));let k=class extends a.E{constructor(e,t){var n,i,o,a,r;super(),this.defaultState={tooltipPriority:2,uploadTooltipType:0,maxPublishVideoDuration:-60,redDot:null!==(r=null===(a=null===(o=null===(i=null===(n=this.home)||void 0===n?void 0:n.state)||void 0===i?void 0:i.appContext)||void 0===o?void 0:o.user)||void 0===a?void 0:a.redDot)&&void 0!==r?r:[]},this.service=e,this.home=t}setUploadLongVideoTooltip(e,{hasLongVideoPermission:t,uploadProfileMaxPublishVideoDuration:n,hasPosted1MinPlusVideo:i}){const o=window.location.pathname.includes("/upload");if(t&&i&&!g.bc.getItem(b)&&!o&&n>0)return e.tooltipPriority=4,e.uploadTooltipType=1,void(e.maxPublishVideoDuration=n)}triggerUploadLongVideoTooltip(e){var t,n;if(!window.location.pathname.includes("/upload")){const i=(0,m.x)();e.tooltipPriority=4,e.uploadTooltipType=1,e.maxPublishVideoDuration=null!==(n=null===(t=i.user)||void 0===t?void 0:t.longVideoMinutes)&&void 0!==n?n:0}}setTooltipPriority(e,t){e.tooltipPriority=t}deleteTypeRedDot(e,t){const n=[...e.redDot],i=n.indexOf(t);n.splice(i,1),e.redDot=n}checkLongVideoTooltipStatus(e){return e.pipe((0,d.T)((()=>{var e,t,n,i,o,a,r,s,l,c,d;const u=(0,m.x)(),p=null!==(t=null===(e=u.user)||void 0===e?void 0:e.longVideoMinutes)&&void 0!==t?t:0,v=(()=>{var e,t,n,i;const o=(0,m.x)();return Boolean(null===(i=null===(n=null===(t=null===(e=null==o?void 0:o.abTestVersion)||void 0===e?void 0:e.abTestApp)||void 0===t?void 0:t.parameters)||void 0===n?void 0:n.tiktok)||void 0===i?void 0:i.long_video_popup_display_optimization)})();if(!v){const e=Boolean((null===(n=u.user)||void 0===n?void 0:n.longVideoMinutes)&&(null===(i=u.user)||void 0===i?void 0:i.longVideoMinutes)>1),t=null===(o=u.abTestVersion)||void 0===o?void 0:o.parameters,r=Boolean(null===(a=t.tiktok)||void 0===a?void 0:a.has_posted_1minplus);return this.getActions().setUploadLongVideoTooltip({hasLongVideoPermission:e,uploadProfileMaxPublishVideoDuration:p,hasPosted1MinPlusVideo:r})}const g=parseInt(null!==(l=null===(s=null===(r=null==u?void 0:u.user)||void 0===r?void 0:r.longVideoPopupDisplayedStatus)||void 0===s?void 0:s.display_history)&&void 0!==l?l:"-1",10),h=parseInt(null!==(d=localStorage.getItem(`longvideo_popup_already_displayed_local_${null===(c=null==u?void 0:u.user)||void 0===c?void 0:c.uid}`))&&void 0!==d?d:"-1",10);let _=null,f=!1;return-1===g&&-1!==h?(f=!0,_=h):_=g,_this.service.queryLongVideoTooltipVisibility({permission_type:e.permission_type}).pipe((0,p.H)((t=>{const n=t;return n&&0===n.status_code&&n.need_to_display?(0,l.of)(this.getActions().triggerUploadLongVideoTooltip(),this.getActions().updateLongVideoTooltip({permission_type:e.permission_type})):(0,l.of)(this.noop())}))))))}updateLongVideoTooltip(e){return e.pipe((0,u.Z)((e=>this.service.updateLongVideoToolTipVisibility({permission_type:e.permission_type}).pipe((0,d.T)((t=>{var n;if(t&&0===t.status_code){const t=(0,m.x)();try{localStorage.setItem(`longvideo_popup_already_displayed_local_${null===(n=null==t?void 0:t.user)||void 0===n?void 0:n.uid}`,`${e.permission_type}`)}catch(e){}}return this.noop()}))))))}postScheduleRecord(e){return e.pipe((0,u.Z)((e=>this.service.postScheduleRecord(e).pipe((0,d.T)((()=>this.noop()))))))}updateRedDot(e){return e.pipe((0,u.Z)((({redirect:e,type:t,isElectronApp:n=!1})=>this.service.updateRedDot({type:t}).pipe((0,v.M)((()=>{e&&(n?window.open(e,"_blank"):location.href=e)})),(0,d.T)((()=>this.getActions().deleteTypeRedDot(t)))))))}};(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Object]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"setUploadLongVideoTooltip",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"triggerUploadLongVideoTooltip",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Number]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"setTooltipPriority",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Number]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"deleteTypeRedDot",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[c.c]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"checkLongVideoTooltipStatus",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[c.c]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"queryLongVideoTooltip",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[c.c]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"updateLongVideoTooltip",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[c.c]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"postScheduleRecord",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[c.c]),(0,o.__metadata)("design:returntype",void 0)],k.prototype,"updateRedDot",null),k=(0,o.__decorate)([(0,s.n)("Header"),(0,o.__metadata)("design:paramtypes",[y,h.L])],k)},21683:(e,t,n)=>{"use strict";n.d(t,{Db:()=>L,L2:()=>I,YS:()=>E,oY:()=>O,r7:()=>P});var i=n(41271),o=n(40099),a=n(47172),r=n(58305),s=n(45297),l=n(95868),c=n(34012),d=n(88920),u=n(96689),p=n(25616),v=n(49057),m=n(71281),g=n(54888),h=n(75792),_=n(8615),f=n(39505);const y=5e3,b=5,w="auto_show";var x;!function(e){e.Sidebar="sidebar",e.Footer="footer"}(x||(x={}));const T=[{title:"terms",key:"terms-of-service",href:""},{title:"privacy",key:"privacy-policy-row",href:""},{title:"accessibility",key:"accessibility",href:""},{title:"copyright",key:"copyright-policy",href:""}],k="accessibility",S="copyright-policy";function E(){const{pathname:e}=(0,a.useLocation)();return!!e.startsWith("/coin")}function A(){const e=(0,r._S)(s._),{count:t,date:n}=e?JSON.parse(e):{date:"",count:0};return{todayShowed:(new Date).toDateString()===new Date(Number(n)).toDateString(),count:t}}function O(){const{pathname:e}=(0,a.useLocation)(),t=(0,l.Fj)(e)||(0,l.Tc)(e);return(0,c.Ig)()&&t}function P(e=0){const t=(0,o.useRef)(0),n=(0,o.useRef)(0),i=(0,o.useRef)(0),a=(0,o.useRef)(!1),[l,c]=(0,o.useState)(!1),{tooltipPriority:d,handlePopoverEnd:u,handlePopoverInitial:p}=(0,f.N)(2);(0,o.useEffect)((()=>{2===d&&a.current&&(c(!0),i.current=window.setTimeout((()=>{c(!1),u(),a.current=!1}),y))}),[d]);const v=(0,o.useCallback)((e=>{e!==w?c(!0):2===d&&(c(!0),i.current=window.setTimeout((()=>{c(!1),u(),a.current=!1}),y)),window.clearTimeout(n.current),window.clearTimeout(t.current);const{todayShowed:o,count:l}=A();!o&&l{const{todayShowed:e,count:t}=A();if(a.current=!e&&t{p(),v(w)}),e)}else u();return()=>{window.clearTimeout(n.current),window.clearTimeout(i.current)}}),[]);const m=(0,o.useCallback)((()=>{t.current=window.setTimeout((()=>{c(!1)}),e)}),[e]),g=(0,o.useCallback)((()=>{(0,r.AP)(s._,JSON.stringify({date:(new Date).getTime(),count:b+1}))}),[]);return{active:l,handleMouseEnter:v,handleMouseLeave:m,handleEndAutoShow:g}}function I(e){const t=new Date,n={redirect_url:"undefined"==typeof window?"":window.location.href,loginPath:h.tH.linkPhoneOrEmail,isLinkPhoneOrEmail:!0},i=(0,d.ZO)(),a=(0,u.K)(n);(0,o.useEffect)((()=>{const n=function(){const e=(0,r._S)(s.gM),t=new Date;if(e){const n=new Date(parseInt(e,10));if((n.getDate()===t.getDate()||n.getDate()===t.getDate()-1)&&n.getMonth()===t.getMonth()&&n.getFullYear()===t.getFullYear())return!0}return!1}();if(!n&&e&&i)try{a(),_._.handleLinkPhoneOrEmailPopupShow({enterMethod:"periodic"}),(0,r.AP)(s.gM,t.getTime().toString())}catch(e){console.log("show link phone pop up failed")}}),[e,i])}function C(e){var t;return e?Object.assign(Object.assign({},e),{children:null!==(t=null==e?void 0:e.children.filter((({placements:e=[]})=>0===e.length||e.includes("sidebar"))))&&void 0!==t?t:[]}):void 0}function L(){var e,t;const n=(0,p.s)(),{language:a="en"}=null!==(e=(0,v.W)((()=>["language"]),[]))&&void 0!==e?e:{},r=null!==(t=(0,m.TQ)("enable_privacy_center"))&&void 0!==t&&t,{navList:s=[],$legalList:l}=(0,i.P)(g.$,{selector:e=>{var t,i;return{$legalList:null===(t=e.bizContext)||void 0===t?void 0:t.navList.find((({title:e})=>e===n("Legal"))),navList:null===(i=e.bizContext)||void 0===i?void 0:i.navList}},dependencies:[]}),c=T.find((e=>"privacy"===e.title));c&&(c.title=r?"Privacy Policy":"privacy");const{pageList:d,programList:u,legalList:h}=(0,o.useMemo)((()=>{const e=[{title:n("help"),key:"help-center",href:`https://support.tiktok.com/${a}`},{title:n("safety"),key:"safety-center",href:`https://www.tiktok.com/safety?lang=${a}`},...T.reduce(((e,t)=>{var i,o,s;const c=(null!==(i=null==l?void 0:l.children)&&void 0!==i?i:[]).map((({key:e})=>e)).indexOf(t.key);return t.key===k&&e.push({title:"Accessibility",key:"accessibility",href:`https://www.tiktok.com/accessibility/${a}`}),t.key===S&&(r&&e.push({title:n("privacyCenter_webFooter_resourcesPrivacy_navLink"),key:"privacy-center",href:`https://www.tiktok.com/privacy/overview/${a}?enter_method=webapp_desktop`}),e.push({title:"Creator Academy",key:"create-portal",href:"https://www.tiktok.com/creator-academy"}),e.push({title:n("Community Guidelines"),key:"community-guidelines",href:`https://www.tiktok.com/community-guidelines?lang=${a}`})),c>=0&&e.push(Object.assign(Object.assign({},t),{title:n(t.title),href:null!==(s=null===(o=null==l?void 0:l.children)||void 0===o?void 0:o[c].href)&&void 0!==s?s:""})),e}),[])],t=C(s[0]),i=C(s[1]);return{pageList:t?{title:n("hca_web_Company",void 0,t.title),children:t.children}:void 0,programList:i?{title:n("hca_web_Program",void 0,i.title),children:i.children}:void 0,legalList:l?{title:n("hca_web_TermsAndPolicies",void 0,"Terms & Policies"),children:e}:void 0}}),[l,a,s,n]);return{pageList:d,programList:u,legalList:h}}},39505:(e,t,n)=>{"use strict";var i;n.d(t,{N:()=>l}),function(e){e[e.None=0]="None",e[e.PromotePopupTip=1]="PromotePopupTip",e[e.DesktopDownloadTip=2]="DesktopDownloadTip",e[e.LoginTip=3]="LoginTip",e[e.Upload=4]="Upload",e[e.Inbox=5]="Inbox",e[e.Series=6]="Series",e[e.DarkMode=7]="DarkMode",e[e.EditProfile=8]="EditProfile",e[e.LiveCreatorTooltip=9]="LiveCreatorTooltip",e[e.LiveChatTooltip=10]="LiveChatTooltip"}(i||(i={}));const o=new class{constructor(){this.priorityKeys=[],this.endPriorityKeys=[]}start(e){this.endPriorityKeys.filter((t=>t!==e))}end(e){if(!this.endPriorityKeys.includes(e)){this.endPriorityKeys.push(e);const t=this.priorityKeys.find((e=>!this.endPriorityKeys.includes(e)));if(t)return t}return null}remove(e){this.priorityKeys.filter((t=>t!==e))}add(e){this.priorityKeys.includes(e)||(this.priorityKeys=[...this.priorityKeys,e].sort(((e,t)=>e-t)))}clean(){this.priorityKeys=[],this.endPriorityKeys=[]}};var a=n(46682),r=n(40099),s=n(77734);function l(e){const[{tooltipPriority:t,maxPublishVideoDuration:n},i]=(0,a.S)(s.GC),l=(0,r.useRef)(!1),c=(0,r.useCallback)((()=>{if(e!==t)o.remove(e);else{const t=o.end(e);t&&i.setTooltipPriority(t)}}),[t]),d=(0,r.useCallback)((()=>{o.start(e)}),[]);return l.current||(o.add(e),l.current=!0),(0,r.useEffect)((()=>()=>{o.clean()}),[]),{tooltipPriority:t,maxPublishVideoDuration:n,handlePopoverInitial:d,handlePopoverEnd:c}}},82041:()=>{"use strict";"undefined"!=typeof window&&(window.TTAP_APPPARSE_STARTTIME=Date.now())},66994:(e,t,n)=>{"use strict";n.d(t,{YH:()=>l,eK:()=>a,no:()=>s,s0:()=>r});var i=n(11060),o=n(95868);const a=()=>{const{pathname:e}=(0,i.zy)(),t=(0,o.cj)(e);return t?{isUserPage:t,pageType:1}:{isUserPage:t}},r=()=>{const{pathname:e}=(0,i.zy)();return{isDetailPage:(0,o.Iy)(e)||(0,o.nq)(e)||(0,o.Ke)(e)||(0,o.cj)(e)||(0,o.LC)(e)||(0,o.Fj)(e)||(0,o.vb)(e)||(0,o.Ds)(e)||(0,o.eD)(e)}},s=()=>{const{pathname:e}=(0,i.zy)();return{isSearchPage:(0,o.a1)(e)||(0,o.ZG)(e)||(0,o.ie)(e)||(0,o.q$)(e)||(0,o.N6)(e)}},l=()=>{const{pathname:e}=(0,i.zy)();return{isFeedbackPage:(0,o.hh)(e)}}},6990:(e,t,n)=>{"use strict";n.d(t,{UX:()=>m,KE:()=>v});var i=n(97086),o=n(71281),a=n(95868),r=n(88874),s=n(63615);const l=[{routeName:"expansion",pageType:104},{routeName:"messages",pageType:13},{routeName:"searchUser",pageType:106},{routeName:"videoPlaylist",pageType:108},{routeName:"searchLive",pageType:123},{routeName:"following",pageType:11},{routeName:"challenge",pageType:3},{routeName:"poi",pageType:18},{routeName:"collection",pageType:121},{routeName:"searchHome",pageType:105},{routeName:"effect",pageType:129},{routeName:"searchVideo",pageType:107},{routeName:"music",pageType:4},{routeName:"friends",pageType:20}];var c=n(57431),d=n(65444);const u={resourceStrategy:"preload"},p={resourceStrategy:"custom",loadEvent:d.bL,defaultProps:{renderStrategy:"custom",renderEvent:d.bL,raceTime:6e3}},v=(d.uM,d.uM,function(){var e,t,n,d,v;let m=!1;if(!(0,i.fU)())try{const i=(0,r.YI)(s.Ow);let u="v0",p="v0",g="v0",h="v0",_="v0";i&&((0,c.D)(i),u=null!==(e=(0,o.d)("islands_arch_phase2"))&&void 0!==e?e:"v0",p=null!==(t=(0,o.d)("islands_arch_video_detail"))&&void 0!==t?t:"v0",g=null!==(n=(0,o.d)("islands_arch_explore"))&&void 0!==n?n:"v0",h=null!==(d=(0,o.d)("islands_arch_user_profile"))&&void 0!==d?d:"v0",_=null!==(v=(0,o.d)("islands_arch_rest_page"))&&void 0!==v?v:"v0");const f=window.location.pathname,y=window.location.search,b=(0,a.tO)(f),w="business"===new URLSearchParams(y).get("scene"),x=(0,a.Fj)(f),T=(0,a.eD)(f),k=(0,a.cj)(f),S=(0,a.M5)(f),E=Boolean(l.find((e=>Number(S)===e.pageType)));m="v0"!==u&&b||"v0"!==p&&x&&!w||"v0"!==g&&T||"v0"!==h&&k||"v0"!==_&&E}catch(e){}return m?p:u}()),m=(function(){var e;let t=!1;if(!(0,i.fU)())try{const n=(0,r.YI)(s.Ow);let i="v0";n&&((0,c.D)(n),i=null!==(e=(0,o.d)("explore_trending_topics"))&&void 0!==e?e:"v0");const l=window.location.pathname,d=(0,a.eD)(l);t="v0"!==i&&d}catch(e){}}(),[3,18,121,105,129,107,4])},65444:(e,t,n)=>{"use strict";n.d(t,{aY:()=>r,bL:()=>o,uM:()=>a});var i=n(81054);const o=Symbol.for("first-video-loaded"),a=Symbol.for("explore-custom-loaded"),r=new class{constructor(){this.loadEvent=o,this.updated=!1,this.updatedDetail=!1,this.updatedExplore=!1,this.updatedUserProfile=!1,this.updatedCommon=!1}updateVideoLoadEvent(){this.updated||(i.PD.emit(this.loadEvent),this.updated=!0)}updateVideoDetailLoadEvent(){this.updatedDetail||(i.PD.emit(this.loadEvent),this.updatedDetail=!0)}updateExploreVideoLoadEvent(){this.updatedExplore||(i.PD.emit(this.loadEvent),this.updatedExplore=!0)}updateUserProfileLoadEvent(){this.updatedUserProfile||(i.PD.emit(this.loadEvent),this.updatedUserProfile=!0)}updateCommonLoadEvent(){this.updatedCommon||(i.PD.emit(this.loadEvent),this.updatedCommon=!0)}};new class{constructor(){this.exploreCustomLoadEvent=a}updateExploreCustomLoadEvent(){i.PD.emit(this.exploreCustomLoadEvent)}}},77682:(e,t,n)=>{"use strict";n.d(t,{A:()=>o});const i={},o={has:function(e){return void 0!==i[e]},push:function(e,t){i[e]=t},get:function(e){return i[e]},pop:function(e){const t=i[e];return delete i[e],t},clear:function(e){delete i[e]},clearAll:function(){for(const e of Object.getOwnPropertyNames(i))delete i[e]}}},9244:(e,t,n)=>{"use strict";n.d(t,{A:()=>s,x:()=>l});var i=n(40099),o=n(11060),a=n(77682);const r={};function s(){const e=(0,o.W6)();(0,i.useEffect)((()=>e.block(((e,t)=>{for(const n of Object.values(r))if(n.getShouldSaveState(e.pathname,t)){const e=n.getStateToSave();a.A.push(n.key,e)}else if(n.getShouldRestoreState(e.pathname,t)){if(a.A.has(n.key)){const e=a.A.get(n.key);n.restoreState(e)}}else n.getShouldClearCache(e.pathname,t)&&a.A.clear(n.key)}))),[e])}function l(e){(0,i.useEffect)((()=>(r[e.key]=e,()=>{delete r[e.key]})))}},38283:(e,t,n)=>{"use strict";n.d(t,{Nb:()=>h,VV:()=>m,cF:()=>g});var i=n(40099),o=n(11060),a=n(88920),r=n(95868),s=n(29909),l=n(60072),c=n(93341),d=n(32125),u=n(77682),p=n(9244);const v="foryou",m=(0,i.memo)((function(){const{list:e,browserList:t,preloadList:n,cursor:u}=(0,s.Lu)((e=>{var t;return{list:e.list,browserList:e.browserList,preloadList:null!==(t=e.preloadList)&&void 0!==t?t:[],cursor:e.cursor}}),d.bN),m=(0,c.VP)(),g=(0,l.F3)((t=>t[e[m]]),d.bN),{pathname:h}=(0,o.zy)(),{cacheRange:_,shouldCacheIndex:f}=(0,a.pC)(),{enableFYPSideNavPreloadAndCache:y,cacheRange:b,cacheAfter:w}=(0,a.oJ)(),x=(0,i.useCallback)(((e,t)=>"PUSH"===t&&!(null==g?void 0:g.ad_info)&&!(null==g?void 0:g.liveRoomInfo)&&(y&&(0,r.tO)(h)||(0,r.tO)(h)&&(0,r.cj)(e))),[null==g?void 0:g.ad_info,null==g?void 0:g.liveRoomInfo,h]),T=(0,i.useCallback)(((e,t)=>y&&(0,r.tO)(e)||"POP"===t&&(0,r.cj)(h)&&(0,r.tO)(e)),[h]),k=(0,i.useCallback)(((e,t)=>"PUSH"===t&&!x(e,t)),[x]),S=(0,i.useCallback)((()=>{let i,o=m;if(b)i=e.slice(m,m+b);else if(w)i=ma.has(e))),preloadList:n.filter((e=>a.has(e.id))),cursor:u,lastPlayedIndex:f?o:0}}),[_,b,w,m,u,t,n,e,f]),E=(0,i.useCallback)((e=>{e.ready=!0}),[]);return(0,p.x)({key:v,getShouldSaveState:x,getShouldRestoreState:T,getShouldClearCache:k,getStateToSave:S,restoreState:E}),null}));function g(){const e=(0,s.sL)(),t=(0,c.nr)(),{isFyfProfileUjEnabled:n}=(0,a.pC)(),{enableFYPSideNavPreloadAndCache:o}=(0,a.oJ)(),r=(0,i.useCallback)((()=>{var n;if(null===(n=u.A.get(v))||void 0===n?void 0:n.ready){const n=u.A.get(v);return e.setRecommendListById(n),setTimeout((()=>{const e=document.querySelector(`[data-scroll-index="${n.lastPlayedIndex}"]`);null==e||e.scrollIntoView({behavior:"instant"}),t.updateVideo({currentVideo:{id:n.list[n.lastPlayedIndex],index:n.lastPlayedIndex,mode:0},playProgress:0,pageType:5})}),0),!0}return!1}),[e,t]);return n||o?r:()=>!1}function h(){var e,t;return null!==(t=null===(e=u.A.get(v))||void 0===e?void 0:e.ready)&&void 0!==t&&t}},27871:(e,t,n)=>{"use strict";n.d(t,{SI:()=>a,T:()=>o,Y5:()=>i,dv:()=>r});const i=["Webapp"],o=new Map,a=0,r=2},68010:(e,t,n)=>{"use strict";n(82041),n(14713);var i=n(91334),o=n(15203);const a=()=>/google|yahoo|yandex|bing|naver|duckduckgo/gi.test((0,o.q)());var r=n(82290),s=n(48211),l=n(24643),c=n(18499),d=(n(7073),n(47236)),u=n(94999),p=n(20146),v=n(57432),m=n.n(v),g=n(17995),h=n(1569),_=n(40099),f=n(90535),y=n(11654),b=n(99661),w=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const x=(0,_.createContext)({onLocationChange:m()});var T=n(77966),k=n(58632);const S=["fetch"],E=["includes"],A=["values","entries","getOwnPropertyDescriptors"];var O=n(37209),P=n(56070),I=n(51660),C=n(64356),L=n(87181),j=n(88874),M=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};function N(e,t){return M(this,void 0,void 0,(function*(){try{if(!(0,j.YI)(C.rv)){const n={};yield Promise.all(t.map((t=>(0,O.gW)(t,e).then((e=>{n[t]=e}))))),(0,j.A7)(C.rv,n)}}catch(e){console.error(`[Fetch Error]: translation data fetch failed: ${e}`)}}))}const D="webapp.browserRedirect-context";function R(){const e=(0,j.YI)(D);if(e){const t=u.l.getInstance(y.V$);try{window.history.replaceState(window.history.state,"",e.browserRedirectUrl),t.emitEvent("seo.browser-redirect.succeed",{count:1},{})}catch(e){t.emitEvent("seo.browser-redirect.error",{count:1},{})}}}var B=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};function U(e){var t;return B(this,void 0,void 0,(function*(){Object.getPrototypeOf(u.l).constructor.prototype.createChild=e=>(u.l.addProviders(e),u.l);const i=(0,h.S)(),{beforeStart:o=m(),defaultNS:a,nss:r,customInitBiz:s,slardarOption:l,appName:c,missingKeyHandler:v,asyncSlardarPre:_=!1}=e;yield function(){return(0,k.__awaiter)(this,void 0,void 0,(function*(){"Promise"in window?(S.some((e=>!(e in window)))&&(yield n.e(2844).then(n.bind(n,23596))),(E.some((e=>!(e in Array.prototype)))||A.some((e=>!(e in Object))))&&(yield Promise.all([n.e(2837).then(n.t.bind(n,76431,23)),n.e(2837).then(n.t.bind(n,20929,23)),n.e(2837).then(n.t.bind(n,68091,23)),n.e(2837).then(n.t.bind(n,87323,23))]))):window.location.href="https://www.tiktok.com/unsupported"}))}(),(0,p.a)(),(0,g.sF)(i);const x=(0,I.qm)();let M;yield Promise.all([(0,b.eE)(x),N(x,r),R(),s?Promise.resolve():(0,f.a)(c),(0,L.Zi)(),o(),(0,d.ai)(),(0,O.Dy)(x,a,v)]),function(e){const t=(0,j.YI)(C.rv);t?(0,O.EK)(t,e):console.error("[Error]: No translation data to be added")}(x),u.l.addProvider({provide:C.hp,useValue:T.Ay.t});try{const e=e=>B(this,void 0,void 0,(function*(){M=yield function(e){return w(this,void 0,void 0,(function*(){const t=yield function(e){return w(this,void 0,void 0,(function*(){return"function"==typeof e?yield e():e}))}(e),n=(0,b.xq)(),i=yield(0,f.h)(),o=u.l.getInstance(y.V$);return y.V$.start(o,Object.assign({appContext:n,bizContext:i,initLocation:window.location.pathname},t))}))}(e),(0,P.J)(null==M?void 0:M.slardar)}));if(l)if(_)if(window.SlardarClient)yield e(l);else{const t=document.querySelector('script[src*="slardar.web.pre.js"]');t&&(yield new Promise((n=>{t.onload=()=>B(this,void 0,void 0,(function*(){yield e(l),n()}))})))}else yield e(l)}catch(e){console.error(e)}return{slardarUtils:M,jotaiStore:i,rootProps:{jotaiStore:i,disableInlineSlardar:void 0!==l,slardarContext:{onLocationChange:null!==(t=null==M?void 0:M.handleLocationChange)&&void 0!==t?t:m()}}}}))}var F=n(15605),V=n(67518),z=n(23721);function H(e){const{jotaiStore:t,disableInlineSlardar:n,slardarContext:i,children:o,csr:a}=e,r=(0,_.useMemo)((()=>{const e=null!=o?o:(0,l.jsx)(_.Fragment,{});return(0,g.ZB)(e,t?{jotaiStore:t}:void 0)}),[o,t]);if(a)return(0,l.jsx)(x.Provider,{value:i,children:(0,l.jsx)(z.ug.Provider,{value:{enable:!n,enableInlineScript:!1},children:(0,l.jsx)(r,{})})});{const e=(0,F.A)({key:"tiktok"});return(0,l.jsx)(x.Provider,{value:i,children:(0,l.jsx)(z.ug.Provider,{value:{enable:!n},children:(0,l.jsx)(V.C,{value:e,children:(0,l.jsx)(r,{})})})})}}var q=n(2787),G=n(81396),$=n.n(G),W=n(84987);class Z{constructor(){this.sprites=new Map,this.domParser=new DOMParser;const e=document.querySelector("#svg-sprite-container");e?this.$root=e:(this.$root=this.domParser.parseFromString(``${e}="${t}"`)).join(" ")}>`,"image/svg+xml").childNodes[0],document.body.prepend(this.$root)),this.restore()}add({id:e,content:t}){if(this.sprites.has(e)){const{initialCount:t=0,count:n,content:i}=this.sprites.get(e);return t>0?void this.sprites.set(e,{initialCount:t-1,count:n,content:i}):void this.sprites.set(e,{count:n+1,content:i})}this.sprites.set(e,{count:1,content:t});const n=this.domParser.parseFromString(t,"text/xml");n.firstChild&&this.$root.appendChild(n.firstChild)}remove(e){if(!this.sprites.has(e))return;const{count:t,content:n}=this.sprites.get(e);if(t>1)return void this.sprites.set(e,{count:t-1,content:n});this.sprites.delete(e);const i=this.$root.querySelector(`#${e}`);i&&i.remove()}serialize(){return this.$root.innerHTML}restore(){this.$root.hasChildNodes()&&this.$root.childNodes.forEach((e=>{var t,n;if("symbol"!==e.tagName)return;const i=null!==(t=e.getAttribute("id"))&&void 0!==t?t:"",o=Number(null!==(n=e.getAttribute("data-count"))&&void 0!==n?n:"0");this.sprites.set(i,{initialCount:o,count:o,content:e.outerHTML})}))}}Z.defaultConfig=[["xmlns","http://www.w3.org/2000/svg"],["xmlns:xlink","http://www.w3.org/1999/xlink"],["style","position: absolute; width: 0; height: 0"],["aria-hidden","true"],["id","svg-sprite-container"]];var Y=n(47172),K=n(82231);const X={MT_Analytics:null,WebApp_Login:null,MT_Reflow:null,Webapp:null,poi_web:null,Webapp_recharge_referral:null,kick_user_frontier:null},Q={MT_Analytics:null,WebApp_Login:null,MT_Reflow:null,Webapp:null,poi_web:null,Webapp_recharge_referral:null,kick_user_frontier:null},J=({children:e,t,initialNamespaces:n,translations:i=X})=>{const[o,a,r]=(0,K.Dh)(C.rv,i),s=(0,_.useRef)(o),[c]=(0,_.useState)((0,I.qm)()),d=(0,_.useCallback)((e=>Boolean(e&&s.current[e])),[]),u=(0,_.useCallback)(((e,t)=>(0,k.__awaiter)(void 0,void 0,void 0,(function*(){try{if(!s.current[e]){Q[e]||(Q[e]=(0,O.gW)(e,t));const n=yield Q[e];T.Ay.addResourceBundle(c,e,n,!0,!0),s.current=Object.assign(Object.assign({},s.current),{[e]:n})}return!0}catch(e){return console.error("[I18nContext] load starling error",e),!1}}))),[a]),p=(0,_.useMemo)((()=>null!=t?t:T.Ay.t),[t]),v=(0,_.useMemo)((()=>({t:p,hasLoaded:d,loadStarling:u,initialNamespaces:n,lang:c})),[d,n,c,u,p]);return(0,O.EK)(o,c),(0,l.jsxs)(C.Ss.Provider,{value:v,children:[e,(0,l.jsx)(r,{data:o})]})};var ee=n(72241),te=n(28591),ne=n(63615);function ie(e,t={}){return{Component:e,props:t}}function oe(e){const{children:t,provisions:n}=e,i=(0,l.jsx)(_.Fragment,{children:t});return[...n].reverse().reduce(((e,{Component:t,props:n})=>(0,l.jsx)(t,Object.assign(Object.assign({},n),{children:e}))),i)}var ae=n(62186),re=n(71615),se=n(32744);function le(){window.location.reload()}function ce(){return(0,l.jsx)(re.A,{width:90,height:90,fill:"rgba(128, 130, 133, 1)"})}const de=(0,ae.default)("div",{target:"e7iph6u0"})({height:"100vh",display:"flex",flexDirection:"column"},"label:DivContainer;");function ue(){const{t:e}=(0,_.useContext)(C.Ss);return(0,l.jsx)(de,{children:(0,l.jsx)(se.W,{isFullScreen:!0,onButtonClick:le,iconElem:ce,title:e("Page not available",{},"Page not available"),desc:e("server_error_sub",{},"Sorry about that! Please try again later."),buttonText:e("try_again_btn",{},"Try again")})})}var pe=n(22980),ve=n(89933);const me=n.n(ve)()("webapp-launcher").extend("provider");function ge(e){me("SigiProvider Rendered");const{children:t}=e,n=(0,Y.useHistory)();return(0,l.jsx)(pe.j,{history:n,children:t})}var he,_e=n(67823),fe=n(45297);!function(e){e.OneColumnMode="one_column_mode",e.SwiperMode="swiper_mode"}(he||(he={}));const ye=(0,_.createContext)({feedMode:"swiper_mode",switchFeedMode:m()}),be=(0,_.memo)((({feedMode:e,children:t})=>{const n=null!=e?e:_e.A.get(fe.i_)||"swiper_mode",[i,o]=(0,_.useState)(n),a=(0,_.useCallback)((e=>{o(e)}),[]),r=(0,_.useMemo)((()=>({feedMode:i,switchFeedMode:a})),[i,a]);return(0,l.jsx)(ye.Provider,{value:r,children:t})}));function we(e){return me("FeedModeProvider Rendered"),(0,l.jsx)(be,{children:e.children})}var xe=n(21355),Te=n(13392),ke=n(93608),Se=n(68252),Ee=n(88920),Ae=n(31960),Oe=n(37434),Pe=n(54888),Ie=n(95868),Ce=n(84506),Le=n(35267),je=n(83658),Me=n(23294),Ne=n(58305),De=n(90341);const Re=({children:e})=>{var t;me("AppThemingProvider Rendered");const{isInProductHoldout:n}=(0,Ee.Vv)(),{baseExpId:i,isInAutoDarkModeControl:o,isInAutoDarkModeTreatment:a,isInAutoDarkModeExperiment:r}=(0,Ee.WE)(),s=(0,je.OC)(),{isInBasicTreatment:c,isInVerification:d}=(0,Ee.Pl)(),u=(0,Ae.TJ)(),p=(0,De.J3)(),{isInTreatment:v}=(0,Me.w)("default_auto_scroll"),{appContext:m}=null!==(t=(0,Oe.Us)())&&void 0!==t?t:{},{user:g,region:h}=null!=m?m:{},{isMobile:f,hashedIP:y,vgeo:b}=(0,Te.Ph)(Pe.$,{selector:e=>{var t,n,i;return{isMobile:null===(t=e.bizContext)||void 0===t?void 0:t.isMobile,hashedIP:null===(n=e.bizContext)||void 0===n?void 0:n.hashedIP,vgeo:null===(i=e.bizContext)||void 0===i?void 0:i.vgeo}},dependencies:[]}),{pathname:w,search:x}=(0,Y.useLocation)(),T=(0,Ie.bc)(w,x)&&!f,k=(0,Ie.$p)(w)&&!f,S=(0,Ie.xj)(w),E=(0,Ce.sy)(),[A,O]=(0,_.useState)((0,Le.MJ)(fe.n9)||"light"),P=e=>{O(e),_e.A.set(fe.n9,e,fe.Ah)},[I,C]=(0,_.useState)(k),L=e=>{C(e),_e.A.set(fe.tS,e?"dark":"light",fe.Ah)};(0,_.useEffect)((()=>{const e=(()=>{var e,t,l,c,d;if(k)return!0;if(!T)return"1"===(0,Le.MJ)(fe.HF)&&_e.A.set(fe.HF,"0",fe.Ah),P("light"),r&&s.disqualifyForInference(i,"app_init","launcher","not_dark_mode_page"),!1;if("1"===(0,Le.MJ)(fe.HF)&&(r&&s.disqualifyForInference(i,"app_init","launcher","manually_set"),"dark"===A||"light"===A))return"dark"===A;let u=!1;try{u=null===(e=(0,xe.A)())||void 0===e?void 0:e.dark;const n=null===(l=null===(t=Intl.DateTimeFormat())||void 0===t?void 0:t.resolvedOptions())||void 0===l?void 0:l.timeZone;ke.f.event("auto_dark_mode_timezone_info",{info_msg:`Local Time Zone: ${n}`})}catch(e){console.error("Error: Unable to determine theme from timezone. Falling back to local time-based method.",e);const t=null===(d=null===(c=Intl.DateTimeFormat())||void 0===c?void 0:c.resolvedOptions())||void 0===d?void 0:d.timeZone;ke.f.event("auto_dark_mode_timezone_error",{error_msg:`Local Time Zone: ${t}`});const n=(new Date).getHours();u=n<6||n>=18}const p=(0,Le.MJ)(fe.tS);if(S)return r&&s.disqualifyForInference(i,"app_init","launcher","basic_dark_mode_page"),p?(P("dark"===p?"dark":"light"),"dark"===p):(P(S?"dark":"light"),S);if(n)return P("system"),E;if(!r)return P("auto"),!!E||u;try{s.maybeTriggerInference({projectName:i,vgeo:b,user:g,enterMethod:"app_init",pageName:"launcher"})}catch(e){console.error("Error. Unable to trigger inference for auto dark mode: ",e)}return o?(P("system"),E):a?(P("auto"),!!E||u):(P("dark"===p?"dark":"light"),"dark"===p)})();L(e)}),[T,S,E,A,o]),(0,_.useEffect)((()=>{""===(0,Ne._S)("auto_scroll")&&p.setAutoScroll(v)}),[v,p]),(0,_.useEffect)((()=>{var e,t,n,i;e=void 0,t=void 0,i=function*(){(c||d)&&(yield u.maybeGenerateAndReportGlobalWidInfo({isLanding:!0,enterMethod:"app_launch",hashedIP:null!=y?y:"",region:null!=h?h:""})),d&&(0,Se.uh)(void 0,!!g)&&(yield u.maybeGenerateAndReportGlobalWidInfo({isLanding:!0,enterMethod:"post_guest_mode",hashedIP:null!=y?y:"",region:null!=h?h:""})),(c||d)&&u.setLandingPageETSentFlag({hasReportedOnLanding:!0})},new((n=void 0)||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))}),[g,c,d,u,Se.uh]);const j=(0,_.useMemo)((()=>({value:I,toggle:L,currentThemeOption:A,setCurrentThemeOption:P})),[I,A]);return(0,l.jsx)(ee.xm.Provider,{value:j,children:e})};var Be=n(73580);class Ue extends _.Component{constructor(){super(...arguments),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(e,t){const{onCatchError:n}=this.props;n(e,t)}render(){const{hasError:e}=this.state;return e?(0,l.jsx)(V.a,{theme:ee.pz,children:(0,l.jsx)(ue,{})}):this.props.children}}function Fe(){const e=(0,Y.useRouteError)();if(e)throw e;return null}const Ve=e=>{const{children:t,initialNamespaces:n,errorStateComponent:i,t:o}=e,[a]=(0,K.Dh)(ne.Ow),{onLocationChange:r}=(0,_.useContext)(x),s=(0,Y.useHistory)();(0,_.useEffect)((()=>s.listen((e=>r(e)))),[s,r]);const c=(0,_.useMemo)((()=>({lang:a.language,initialNamespaces:n,t:o,clusterRegion:null==a?void 0:a.clusterRegion})),[a.language,n,o,null==a?void 0:a.clusterRegion]),d=(0,_.useMemo)((()=>[ie(te.vd),ie(J,c),ie(ge),ie(we),ie(Re)]),[c]);return a?(0,l.jsx)(oe,{provisions:d,children:t}):(0,l.jsx)(V.a,{theme:ee.pz,children:null!=i?i:(0,l.jsx)(ue,{})})},ze=e=>{var t;const{supportRoutes:n,children:i,Outlet:o,routerProps:a}=e,r=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{(null===history||void 0===history?void 0:history.scrollRestoration)&&(history.scrollRestoration="manual")}));const c=(0,_.useCallback)((e=>{try{s.captureMessage(e,"fatal",{fromLauncher:"1"})}catch(e){console.error("Error occurs when reporting error:",e)}}),[s]),d=(0,_.useMemo)((()=>(null==a?void 0:a.routes)&&o?[{id:"@tiktok/fe-shared_RootLayout",element:(0,l.jsx)(Ve,Object.assign(Object.assign({},r),{children:(0,l.jsx)(o,{})})),children:a.routes,errorElement:(0,l.jsx)(Fe,{})}]:null),[null==a?void 0:a.routes,o,r]);return a&&d?(0,l.jsx)(_.StrictMode,{children:(0,l.jsx)(Ue,{onCatchError:c,children:(0,l.jsx)(Y.CompatRouter,Object.assign(Object.assign({},a),{historyPaths:null!==(t=a.historyPaths)&&void 0!==t?t:n,routes:d}))})}):(0,l.jsx)(_.StrictMode,{children:(0,l.jsx)(Ue,{onCatchError:c,children:(0,l.jsx)(Y.CompatRouter,{historyPaths:n,children:(0,l.jsx)(Ve,Object.assign(Object.assign({},r),{children:i}))})})})};var He=n(97086),qe=n(82715),Ge=n(69589),$e=n(40046),We=n(49057),Ze=n(15942),Ye=n(60484),Ke=n(71281),Xe=n(48615);const Qe=["//v16.tiktokcdn.com","//p16-va.tiktokcdn.com","//s20.tiktokcdn.com"],Je=["https://p16-sign-va.tiktokcdn.com","https://p16-sign-sg.tiktokcdn.com","https://p77-sign-va.tiktokcdn.com","https://sf16-website.neutral.ttwstatic.com","https://v16-webapp-prime.tiktok.com","https://v19-webapp-prime.tiktok.com"],et=["https://p16-pu-sign-useast8.tiktokcdn-us.com","https://p19-pu-sign-useast8.tiktokcdn-us.com","https://lf16-cdn-tos.tiktokcdn-us.com","https://p16-sign.tiktokcdn-us.com","https://p19-sign.tiktokcdn-us.com","https://v16-webapp-prime.us.tiktok.com","https://v19-webapp-prime.us.tiktok.com"],tt=["https://p16-sign-useast2a.tiktokcdn.com","https://p16-pu-sign-no.tiktokcdn-eu.com","https://p77-sign-sg.tiktokcdn.com","https://v16-webapp-prime.tiktok.com","https://v19-webapp-prime.tiktok.com"],nt={"Singapore-Central":Je,"US-East":Je,"US-EastRed":tt,"US-TTP":et,"US-TTP2":et,"EU-TTP":tt,"EU-TTP2":tt},it=function(){var e,t;const{abTestVersion:n}=(0,Ye.L$)((0,We.W)((()=>["abTestVersion"]),[])),i=null!==(e=(0,Ke.qt)(n,"page_loading_tiny_changes"))&&void 0!==e?e:"v0",{vregion:o}=(0,Ye.L$)((0,Xe.U)((()=>["vregion"]),[]));let a=Qe;return"v1"!==i&&"v4"!==i||!o||(a=null!==(t=nt[o])&&void 0!==t?t:Qe),(0,l.jsx)(te.mg,{children:a.map(((e,t)=>(0,l.jsx)("link",{rel:"dns-prefetch",href:e},`prefetch-${t+1}`)))})};var ot=n(21683),at=n(9244),rt=n(38283);const st=(0,_.memo)((function(){const{isFyfProfileUjEnabled:e}=(0,Ee.pC)(),{enableFYPSideNavPreloadAndCache:t}=(0,Ee.oJ)();return(0,at.A)(),(0,q.Y)(q.FK,{children:(e||t)&&(0,q.Y)(rt.VV,{})})}));var lt=n(81659),ct=n(11060),dt=n(34012),ut=n(63950),pt=n(58542);const vt=(0,ae.default)(ut.N$,{target:"e1x8fefz0"})({maxWidth:"unset",justifyContent:"flex-start"},"label:StyledDivBodyContainerV2;"),mt=(0,ae.default)(ut.N$,{target:"e1x8fefz1"})({width:"100%"},"label:StyledDivBodyContainerV3;"),gt=(0,_.memo)((e=>{const{pathname:t}=(0,ct.zy)(),n=(0,dt.Ig)(),{isInNavPhase3:i}=(0,Ee.Oj)();let o=ut.N$;return(0,Ie.pz)(t)&&(o=vt),n&&(o=mt),(0,q.Y)(o,Object.assign(Object.assign({},e),{backgroundColor:i?pt.Tj4.UIPageFlat1:void 0}))}));var ht=n(81054),_t=n(6990),ft=n(11328),yt=n(72153);const bt=(0,ae.default)("div",{target:"e4gdqxf0"})((({theme:{colors:e}})=>[{display:"flex",justifyContent:"space-around",boxShadow:`0px 1px 1px ${e.ShadowPrimary}`,height:yt.uF,width:"100%",top:0,position:"fixed",alignItems:"center",background:e.BGPrimary,zIndex:3e3}]),"label:DivSkeletonHeaderContainer;"),wt=(0,ae.default)("div",{target:"e4gdqxf1"})({width:"100%",display:"flex",height:"100%",flexDirection:"row",justifyContent:"space-between",alignItems:"center"},(({expand:e})=>e?{}:{maxWidth:yt.hj}),(({theme:{direction:e}})=>(0,yt.mp)({direction:e,paddingStart:"20px",paddingEnd:"24px"})),"label:DivSkeletonHeaderWrapper;"),xt=(0,ae.default)(wt,{target:"e4gdqxf2"})([{maxWidth:"100%"},({theme:{direction:e}})=>(0,yt.mp)({direction:e,paddingStart:"16px",paddingEnd:"24px"})],"label:StyledDivSkeletonHeaderWrapperV2;");var Tt=n(86702),kt=n(93678);const St=(0,ae.default)("a",{target:"e1u8yrdb0"})({fontSize:0},"label:ALogo;");St.defaultProps=Object.assign(Object.assign({},St.defaultProps),{"data-e2e":"tiktok-logo"});const Et=(0,_.memo)((function({isDark:e}){const t=(0,_.useMemo)((()=>e?(0,l.jsx)(kt.A,{height:42,width:118}):(0,l.jsx)(Tt.A,{height:42,width:118})),[e]);return(0,l.jsx)(St,{to:qe.OZ.home,style:{position:"relative"},children:t})}));var At=n(81825);const Ot=(0,ae.default)("div",{target:"e1jlaln00"})((({theme:{colors:e}})=>({display:"flex",flexDirection:"row",alignItems:"center",padding:"12px 16px",background:e.BGInput,borderRadius:"92px",position:"relative",overflow:"hidden",zIndex:1,margin:0})),"label:DivContainer;"),Pt=(0,ae.default)("div",{target:"e1jlaln01"})({width:"292px",height:"22px"},"label:DivInputPlaceholder;"),It=(0,ae.default)("span",{target:"e1jlaln02"})((({theme:{colors:e}})=>({width:"1px",height:"28px",margin:"-3px 0",background:e.LineSecondary})),"label:SpanSpliter;"),Ct=(0,ae.default)(At.A,{target:"e1jlaln04"})({display:"block",margin:"-1px 0",marginInlineStart:"12px"},"label:StyledMagnifyingGlass;"),Lt=function(){const{colors:e}=(0,V.u)();return(0,l.jsxs)(Ot,{children:[(0,l.jsx)(Pt,{}),(0,l.jsx)(It,{}),(0,l.jsx)(Ct,{fill:e.TextQuaternary,width:24,height:24})]})};var jt=n(12731);const Mt=(0,ht.Ay)({resolved:{},chunkName:()=>"header.island",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(7716),n.e(8873),n.e(8785),n.e(5934),n.e(9127),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(7485),n.e(9280),n.e(8239),n.e(1952),n.e(6283),n.e(2047),n.e(5890),n.e(1211),n.e(2301),n.e(7284),n.e(9502),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(2375),n.e(5245),n.e(9058),n.e(4623),n.e(6389),n.e(6851),n.e(6735),n.e(9245),n.e(13)]).then(n.bind(n,768)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>768},Object.assign({fallback:(0,q.Y)((()=>{const{isDark:e}=(0,V.u)(),t=(0,ot.oY)(),{showFullSideNav:n}=(0,Ee.Oj)();return t||n?null:(0,q.Y)(bt,{children:(0,q.FD)(xt,{children:[(0,q.Y)(Et,{isDark:e}),(0,q.Y)(Lt,{}),(0,q.Y)(ft.EA.Avatar,{style:{width:32,height:32}})]})})}),{})},_t.KE)),Nt=(0,ht.Ay)({resolved:{},chunkName:()=>"sideNav.island",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(7716),n.e(7978),n.e(8873),n.e(8785),n.e(5934),n.e(9127),n.e(1735),n.e(2396),n.e(5985),n.e(8345),n.e(9280),n.e(1648),n.e(9835),n.e(8239),n.e(1952),n.e(6283),n.e(2047),n.e(4687),n.e(1357),n.e(9687),n.e(9438),n.e(5890),n.e(1211),n.e(2301),n.e(7284),n.e(9502),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(2375),n.e(5245),n.e(3654),n.e(47),n.e(9058),n.e(4623),n.e(6389),n.e(6851),n.e(6735),n.e(9245),n.e(2365),n.e(2206)]).then(n.bind(n,48367)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>48367},Object.assign({fallback:(0,q.Y)((()=>(0,q.FD)(jt.Ws,{children:[(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{}),(0,q.Y)(jt.Hj,{})]})),{})},_t.KE)),Dt=(0,ht.Ay)({resolved:{},chunkName:()=>"bottomSideEffect.island",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(7978),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(7485),n.e(272),n.e(1648),n.e(1531),n.e(7599),n.e(3031),n.e(7104),n.e(1211),n.e(2110),n.e(2014),n.e(499),n.e(7859),n.e(4488),n.e(3206),n.e(9204),n.e(6389),n.e(8116),n.e(2189),n.e(5229)]).then(n.bind(n,12743)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>12743},Object.assign({},_t.KE)),Rt=(0,ht.Ay)({resolved:{},chunkName:()=>"headSideEffect.island",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(4563),n.e(8345),n.e(5021),n.e(2710),n.e(4534),n.e(4096),n.e(1636)]).then(n.bind(n,48676)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>48676},Object.assign({},_t.KE)),Bt=(0,ht.Ay)({resolved:{},chunkName:()=>"notificationSideEffect.island",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(8564),n.e(9280),n.e(6851),n.e(3569)]).then(n.bind(n,93677)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>93677},Object.assign({},_t.KE));var Ut=n(33805);const Ft={id:"tiktok-icon-e4e3456a",use:"tiktok-icon-e4e3456a-usage",viewBox:"0 0 88 88",content:''};var Vt=n(46682),zt=n(99789),Ht=n.n(zt),qt=n(7672),Gt=n(91689),$t=n(55099);let Wt=class{constructor(e){this.fetch=e,this.initTargetIdcRequest=()=>this.fetch.get("/passport/web/account/info/",{credentials:"include",baseUrlType:2,query:{aid:1459}})}checkTTwid(){return(0,k.__awaiter)(this,void 0,void 0,(function*(){const e=new Gt.TtWid({aid:fe.xE,service:"www.tiktok.com",union:!1,unionHost:"",needFid:!1});try{yield e.checkWebId()}catch(e){ke.f.sendEvent("check_ttwid_error",{error_msg:e}),console.error(e)}}))}};Wt=(0,k.__decorate)([(0,qt._)(),(0,k.__metadata)("design:paramtypes",[$t.p])],Wt);var Zt=n(57431),Yt=n(70873);const Kt=(0,ae.default)("div",{target:"eyhjz840"})({height:"100vh",display:"flex",flexDirection:"column"},"label:DivErrorBoundaryContainer;");class Xt extends _.Component{constructor(){super(...arguments),this.state={isNetOffline:!1,hasError:!1},this.handleOnlineStatusChange=()=>{this.setState({isNetOffline:!navigator.onLine})}}get iconElem(){const{hasError:e}=this.state;return e?(0,l.jsx)(re.A,{width:90,height:90,fill:"rgba(128, 130, 133, 1)"}):(0,l.jsx)(Yt.A,{width:90,height:90,fill:"rgba(128, 130, 133, 1)"})}get text(){const{hasError:e}=this.state;return e?{title:"Page not available",desc:"server_error_sub",button:"try_again_btn"}:{title:"network_error_title",desc:"network_error_sub",button:"try_again_btn"}}componentDidMount(){window.addEventListener("online",this.handleOnlineStatusChange),window.addEventListener("offline",this.handleOnlineStatusChange)}componentWillUnmount(){window.removeEventListener("online",this.handleOnlineStatusChange),window.removeEventListener("offline",this.handleOnlineStatusChange)}handleRetry(){window.location.reload()}componentDidCatch(e,t){const{onCatchError:n}=this.props;n(e,t),this.setState({hasError:!0})}render(){const{isNetOffline:e,hasError:t}=this.state,{children:n,isMobile:i}=this.props,{t:o}=this.context;if(e||t){const{title:e,desc:t,button:n}=this.text;return i?(0,l.jsx)(Kt,{children:(0,l.jsx)(se.W,{brightness:0,isFullScreen:!0,iconElem:this.iconElem,title:o(e),desc:o(t),buttonText:o(n),onButtonClick:this.handleRetry})}):(0,l.jsx)(se.W,{isFullScreen:!0,onButtonClick:this.handleRetry,iconElem:this.iconElem,title:o(e),desc:o(t),buttonText:o(n)})}return n}}Xt.contextType=C.Ss;let Qt=class{constructor(e){this.fetch=e}reportRenderError(e){return this.fetch.get("/node-webapp/page/error",{query:{page:e},baseUrlType:2})}};Qt=(0,k.__decorate)([(0,qt._)(),(0,k.__metadata)("design:paramtypes",[$t.p])],Qt);var Jt=n(2584),en=n(20157);function tn(e){me("GlobalModalProvider Rendered");const{GlobalModalProvider:t,value:n}=(0,en.li)();return(0,l.jsx)(t,{value:n,children:e.children})}var nn=n(89311);function on(e){me("TUXProvider Rendered");const{isRTL:t}=(0,nn.m)(),{value:n}=(0,_.useContext)(ee.xm);return(0,l.jsx)(pt.juU,{colorSchemePreference:n?"dark":"light",textDirection:t?"rtl":"ltr",zIndexConfig:ee.pz.zIndex,children:e.children})}var an=n(75431);function rn(e){me("ThemeProvider Rendered");const{isMobile:t,children:n,extraGlobalStyles:i}=e,o=(0,_.useMemo)((()=>(0,Zt.x)()),[]),{value:a}=(0,_.useContext)(ee.xm),r=(0,_.useMemo)((()=>(0,ee.O4)({isDark:a,isMobile:t,lang:null==o?void 0:o.language})),[a,t,null==o?void 0:o.language]);return(0,l.jsxs)(V.a,{theme:r,children:[(0,l.jsx)(an.mL,{styles:{".link-a11y-focus":{"&:focus":{outline:"none"},"&:focus-visible":{outline:`2px solid ${r.colors.Negative}`},"&.auto-outline-style:focus-visible":{outline:`2px auto ${r.colors.Negative} !important`}}}}),i?(0,l.jsx)(an.mL,{styles:i(r)}):null,n]})}const sn=[{"@font-face":{fontFamily:"TikTokFont",src:'local("TikTokFont-Regular"), url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Regular.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Regular.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Regular.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:400,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokFont",src:'local("TikTokFont-Medium"), url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Semibold.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Semibold.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Semibold.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:500,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokFont",src:'local("TikTokFont-Medium"), url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Semibold.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Semibold.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Semibold.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:600,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokFont",src:'local("TikTokFont-Bold"), url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Bold.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Bold.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokFont-Bold.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:700,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokDisplayFont",src:'url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Regular.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Regular.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Regular.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:400,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokDisplayFont",src:'url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Semibold.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Semibold.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Semibold.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:500,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokDisplayFont",src:'url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Semibold.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Semibold.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Semibold.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:600,fontStyle:"normal",fontDisplay:"fallback"}},{"@font-face":{fontFamily:"TikTokDisplayFont",src:'url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Bold.woff2?_default_font=1&v=2)\n format("woff2"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Bold.woff?_default_font=1&v=2)\n format("woff"),\n url(https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/tiktok_fonts/TikTokDisplayFont-Bold.otf?_default_font=1&v=2)\n format("opentype")',fontWeight:700,fontStyle:"normal",fontDisplay:"fallback"}}],ln=".tw-only",cn=[{"*, *::before, *::after":{boxSizing:"border-box",userSelect:"unset"},"body,h1,h2,h3,h4,p,figure,blockquote,dl,dd":{margin:0},'ul[role="list"], ol[role="list"]':{listStyle:"none"},"html:focus-within":{scrollBehavior:"smooth"},body:{minHeight:"100vh",textRendering:"optimizeSpeed",lineHeight:1.5},"a:not([class])":{textDecorationSkipInk:"auto"},"img, picture":{maxWidth:"100%",display:"block"},"input,button,textarea,select":{font:"inherit"},"@media (prefers-reduced-motion: reduce)":{"html:focus-within":{scrollBehavior:"auto"},"*,*::before,*::after":{animationDuration:"0.01ms !important",animationIterationCount:"1 !important",transitionDuration:"0.01ms !important",scrollBehavior:"auto !important"}},"@supports (-webkit-touch-callout: none)":{body:{minHeight:"-webkit-fill-available"}}}];function dn(e){const{isMobile:t,delayFonts:n=!1}=e,{value:i}=(0,_.useContext)(ee.xm),{isRTL:o}=(0,nn.m)(),a=(0,_.useMemo)((()=>(0,Zt.x)()),[]),r=function(e){return(0,_.useMemo)((()=>function(e,t,n=!0){return[cn,{body:{fontFamily:n?e.fontFamilies.TikTokFont:void 0,fontSize:e.text.fontSize,color:e.colors.TextPrimary,backgroundColor:e.colors.BGPrimary,direction:e.direction,a:{color:e.colors.TextPrimary,transition:"color 250ms",textDecoration:"none",cursor:"pointer"},[`a:where(${ln}),:where(${ln}) a`]:{transition:"all 0s ease 0s"},"a:visited":{color:e.colors.TextPrimary},[`a:where(${ln}):visited,:where(${ln}) a:visited`]:{color:"inherit"},"a:hover":{color:e.colors.TextPrimary,textDecoration:"underline"},[`a:where(${ln}):hover,:where(${ln}) a:hover`]:{color:"inherit",textDecoration:"inherit"},"a:active":{color:e.colors.TextPrimary},[`a:where(${ln}):active,:where(${ln}) a:active`]:{color:"inherit"},"a:focus":{color:e.colors.TextPrimary},[`a:where(${ln}):focus,:where(${ln}) a:focus`]:{color:"inherit"},input:{"::-ms-clear":{display:"none",width:0,height:0},"::-ms-reveal":{display:"none",width:0,height:0},"::-webkit-search-decoration, ::-webkit-search-cancel-button, ::-webkit-search-results-button, ::-webkit-search-results-decoration":{display:"none"}},"&.hidden":{overflow:"hidden",display:"block"},WebkitFontSmoothing:"antialiased","a, abbr, acronym, address, applet, article, aside, audio, b, big, blockquote, body, canvas, caption, center, cite, code, dd, del, details, dfn, div, dl, dt, em, embed, fieldset, figcaption, figure, footer, form, h1, h2, h3, h4, h5, h6, header, hgroup, html, i, iframe, img, ins, kbd, label, legend, li, mark, menu, nav, object, ol, output, p, pre, q, ruby, s, samp, section, small, span, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, time, tr, tt, u, ul, var, video":{fontFamily:n?e.fontFamilies.TikTokFont:void 0},strong:{fontWeight:700}}},...n?sn:[],{html:t?{}:{body:{overflowY:"overlay"},"*":{"::-webkit-scrollbar":{borderRadius:"0",width:"8px"},"::-webkit-scrollbar-track":{borderRadius:"0",backgroundColor:"rgba(0, 0, 0, 0)"},"::-webkit-scrollbar-thumb":{borderRadius:"4px",backgroundColor:e.colors.BGPlaceholderDefault}}}}]}((0,ee.O4)(e),e.isMobile,e.withFonts)),[e])}({isDark:i,lang:null==a?void 0:a.language,isMobile:t,withFonts:!n}),s=(0,pt.N9v)({colorSchemePreference:i?"dark":"light",textDirection:o?"rtl":"ltr"});return(0,l.jsx)(an.mL,Object.assign({styles:r},s))}function un({children:e,isMobile:t,path2PidFunc:n,delayFonts:i=!1}){const[o]=(0,Vt.S)(Pe.$,{selector:e=>({bizContext:e.bizContext&&Ht()(e.bizContext,"statusCode"),bizInitialized:e.initialized}),dependencies:[]}),{pathname:a}=(0,Y.useLocation)(),r=(0,Be.Nj)(Wt),s=(0,_.useMemo)((()=>(0,Zt.x)()),[]);(0,_.useEffect)((()=>{var e;{const{user:t,isTTwidDecryptedFail:n,wid:i}=s;n&&ke.f.sendEvent("check_ttwid_error",{error_msg:"isTTwidDecryptedFail from server"}),!(null===(e=o.bizContext)||void 0===e?void 0:e.isBot)&&r.checkTTwid(),t&&r.initTargetIdcRequest().subscribe();const a="ttwid",l=(0,Se._S)(a,"");l&&l!==i&&ke.f.sendEvent("check_ttwid_error",{error_msg:"appcontext ttwid is different from local storage"}),(0,Se.AP)(a,i)}}),[]),(e=>{(0,_.useEffect)((()=>{if(e){const e=new AbortController;let t,n,i=!1;const o=50,a={touchstart:e=>{n=void 0,t=e.targetTouches[0].clientY},touchmove:e=>{n=e.targetTouches[0].clientY},touchend:()=>{if(i||(Jt.O.handleCommonTap(),i=!0),!t||!n)return;const a=t-n;(a>o||a<-o)&&(Jt.O.handleCommonScroll(),e.abort())}};return Object.keys(a).forEach((t=>{window.addEventListener(t,a[t],{signal:e.signal,capture:!0})})),()=>{e.abort(),Object.keys(a).forEach((e=>{window.removeEventListener(e,a[e])}))}}const t={click:()=>{Jt.O.handleCommonClick()},scroll:()=>{Jt.O.handleCommonScroll()},mousemove:()=>{Jt.O.handleCommonMousemove()}};return Object.keys(t).forEach((e=>{window.addEventListener(e,t[e],{once:!0,capture:!0})})),()=>{Object.keys(t).forEach((e=>{window.removeEventListener(e,t[e])}))}}),[])})(t);const c=(0,Be.Nj)(y.V$),d=(0,Be.Nj)(Qt),u=(0,_.useMemo)((()=>n(a)),[a]),p=(0,_.useCallback)(((e,t)=>{try{d.reportRenderError(u);const n=t.componentStack,i=n.split("\n").filter((e=>""!==e.trim())),o=(null==i?void 0:i[0])||"Unknown Component";c.captureMessage(`Page render Error: ${e}. The error component is ${o}`,"fatal",{page:u}),console.info("Error occurs in render time:",e),console.info("Error occurs in component:",n)}catch(e){console.error("Error occurs when reporting error:",e)}}),[d,u,c]),v=(0,_.useMemo)((()=>[ie(tn),ie(on),ie(rn,{isMobile:t})]),[t]);return(0,l.jsx)(oe,{provisions:v,children:(0,l.jsxs)(Xt,{onCatchError:p,isMobile:t,children:[(0,l.jsx)(dn,{isMobile:t,withFonts:!i}),e]})})}var pn=n(34832),vn=n(28658);const mn=(0,q.Y)((function(e){const t=(0,_.useContext)(W.X);return(0,_.useLayoutEffect)((()=>(t.add(Ft),()=>{t.remove("tiktok-icon-e4e3456a")})),[]),(0,l.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,l.jsx)("use",{xlinkHref:"#tiktok-icon-e4e3456a"},void 0)}),void 0)}),{style:{margin:"auto",width:"77px",height:"88px"}});function gn(){return(0,q.Y)("link",{rel:"stylesheet",href:pn})}function hn(){return(0,q.Y)("link",{rel:"stylesheet",href:vn})}const _n=({children:e})=>(0,q.FD)(un,{isMobile:!1,loading:mn,path2PidFunc:Ut.oN,children:[(0,q.Y)(gn,{}),(0,q.Y)(hn,{}),e]});var fn,yn,bn,wn,xn,Tn,kn,Sn=n(4474),En=n(50970),An=n(33063),On=n(4912),Pn=n(48831),In=n(41271),Cn=n(47926),Ln=n(13947),jn=n(78305),Mn=n(64162),Nn=n(4126),Dn=n(93995),Rn=n(340);!function(e){e.VIDEO="1",e.COMMENT="3",e.PROFILE="4",e.DM="5",e.SUICIDE="7",e.AUDIO="8",e.OLD_COPYRIGHT="101",e.COPYRIGHT="102",e.NETZDG_REPORTER="103",e.NETZDG="104",e.ANCHOR="105",e.LIVE_REPORTER="107",e.LIVE_COMMENT_REPORTER="130",e.PHOTO_AVIA_REPORTER="210",e.LIVE_COMMENT="302",e.COMMENT_NETZDG="303",e.COMMENT_NETZDG_REPORTER="304",e.AUDIO_COMMUNITY_GUIDELINE="801",e.AUDIO_COPYRIGHT="802",e.AUDIO_MULTIPLE_VIOLATIONS="803",e.MASK_LAYER="1011",e.COPYRIGHT_AUTO_REMOVAL="1014",e.DMCA_VIDEO="1024",e.DMCA_POST="1025",e.TRADEMARK_VIDEO="1026",e.TRADEMARK_POST="1027",e.COPYRIGHT_STRIKE="1033",e.TRADEMARK_STRIKE="1034",e.DSA_ILLEGAL_VIDEO="1035",e.DSA_ILLEGAL_PHOTO="1037",e.DSA_ILLEGAL_EFFECT="1041",e.SeriesVideoCopyright="1042",e.SeriesVideoTrademark="1043",e.SeriesCollectionCopyright="1044",e.SeriesCollectionTrademark="1045",e.DSA_ILLEGAL_PROFILE="2016",e.DSA_ILLEGAL_COMMENT="3006",e.OneLinerDSA="3008",e.SeriesReviewDSA="3009",e.DSA_CG_AUDIO="4000",e.DMCA_AUDIO="4001",e.DSA_ILLEGAL_AUDIO="4003",e.DSA_NR_AUDIO="4004",e.MCC_AUDIO="4005",e.COPYRIGHT_PROFILE="2011",e.TRADEMARK_PROFILE="2012",e.SUSPEND_LINK="2005",e.LiveCommentDSA="5005",e.HASHTAG="8000",e.CONTENT_CHECK_VIDEO="9000",e.RESET_LINK="20051",e.POI_COMMENT="300000",e.POI_COMMENT_ILLEGAL="300004",e.SUB_SPACE_COMMENT="300005",e.SUB_SPACE_COMMENT_ILLEGAL="300006"}(fn||(fn={})),function(e){e.VIDEO="video",e.COMMENT="comment",e.AUDIO="audio",e.LINK="link",e.USER="user",e.IMAGE="image",e.HASHTAG="hashtag",e.HEART="heart",e.STATUS_SUCCESS="status_success",e.STATUS_FAIL="status_fail",e.STATUS_FAIL_LIGHT="status_fail_light",e.STATUS_RECEIVED="status_received",e.PHOTO="photo",e.PROFILE="profile"}(yn||(yn={})),function(e){e[e.ON_APPEAL=0]="ON_APPEAL",e[e.NOT_APPEAL=1]="NOT_APPEAL",e[e.APPEAL_SUCCESS=2]="APPEAL_SUCCESS",e[e.APPEAL_FAIL=3]="APPEAL_FAIL",e[e.APPEAL_EXPIRED=4]="APPEAL_EXPIRED",e[e.CANNOT_APPEAL=5]="CANNOT_APPEAL"}(bn||(bn={})),function(e){e[e.VIOLATION_INFO_SUCCESS=1]="VIOLATION_INFO_SUCCESS",e[e.VIOLATION_INFO_VIOLATION=2]="VIOLATION_INFO_VIOLATION",e[e.VIOLATION_INFO_NR=3]="VIOLATION_INFO_NR",e[e.VIOLATION_INFO_NFF=4]="VIOLATION_INFO_NFF",e[e.VIOLATION_INFO_IN_PROGRESS=5]="VIOLATION_INFO_IN_PROGRESS"}(wn||(wn={})),function(e){e[e.UNCHANGEABLE=0]="UNCHANGEABLE",e[e.CHANGEABLE=1]="CHANGEABLE",e[e.CHANGED=2]="CHANGED"}(xn||(xn={})),function(e){e[e.NORMAL=0]="NORMAL",e[e.EXPIRE=1]="EXPIRE",e[e.EXCEED=2]="EXCEED",e[e.NOT_SUPPORTED=3]="NOT_SUPPORTED"}(Tn||(Tn={})),function(e){e[e.STATUS=0]="STATUS",e[e.SUBMIT=1]="SUBMIT"}(kn||(kn={})),fn.VIDEO,fn.DSA_ILLEGAL_VIDEO,fn.LIVE_REPORTER,fn.LIVE_COMMENT_REPORTER,fn.DSA_ILLEGAL_VIDEO,fn.DSA_ILLEGAL_PHOTO,fn.DSA_ILLEGAL_EFFECT,fn.DSA_ILLEGAL_PROFILE,fn.DSA_ILLEGAL_COMMENT,fn.OneLinerDSA,fn.SeriesReviewDSA,fn.DSA_ILLEGAL_AUDIO,fn.LiveCommentDSA,fn.POI_COMMENT_ILLEGAL,fn.SUB_SPACE_COMMENT_ILLEGAL;var Bn,Un,Fn,Vn,zn,Hn,qn,Gn,$n,Wn=n(24451),Zn=n(35572),Yn=n(20259),Kn=n(23999),Xn=n(8536),Qn=n(74690),Jn=n(80339),ei=n(26324),ti=n(25342),ni=n(11983);!function(e){e[e.VIDEO=1]="VIDEO",e[e.PHOTO_MODE=2]="PHOTO_MODE"}(Bn||(Bn={})),function(e){e[e.PUBLIC=1]="PUBLIC",e[e.PRIVATE=2]="PRIVATE",e[e.FRIENDS=3]="FRIENDS",e[e.INVISIBLE=4]="INVISIBLE"}(Un||(Un={})),($n=Fn||(Fn={}))[$n.OTHER=0]="OTHER",$n[$n.COMMUNITY_GUIDELINES=1]="COMMUNITY_GUIDELINES",$n[$n.TOBACCO=2]="TOBACCO",$n[$n.VIOLENT=3]="VIOLENT",$n[$n.DANGEROUS=4]="DANGEROUS",$n[$n.OVERLY_SEXUALIZED=5]="OVERLY_SEXUALIZED",$n[$n.SPAM=6]="SPAM",$n[$n.UNORIGINAL=7]="UNORIGINAL",$n[$n.MINOR_SAFETY=8]="MINOR_SAFETY",$n[$n.UNORIGINAL_NR=9]="UNORIGINAL_NR",$n[$n.REPRODUCED=10]="REPRODUCED",function(e){e[e.CAN_SUBMIT=0]="CAN_SUBMIT",e[e.CANNOT_SUBMIT=1]="CANNOT_SUBMIT",e[e.NO_PENALTY=2]="NO_PENALTY",e[e.REVIEWING=3]="REVIEWING",e[e.SUCCEEDED=4]="SUCCEEDED",e[e.FAILED=5]="FAILED",e[e.TIMEOUT=6]="TIMEOUT"}(Vn||(Vn={})),function(e){e[e.SUBMITTED=0]="SUBMITTED",e[e.NOT_SUBMITTED=1]="NOT_SUBMITTED"}(zn||(zn={})),function(e){e[e.PENALTY_TYPE_NR=0]="PENALTY_TYPE_NR",e[e.PENALTY_TYPE_NFF=1]="PENALTY_TYPE_NFF"}(Hn||(Hn={})),function(e){e[e.PENALTY_SOURCE_HUMAN=0]="PENALTY_SOURCE_HUMAN",e[e.PENALTY_SOURCE_MACHINE=1]="PENALTY_SOURCE_MACHINE"}(qn||(qn={})),function(e){e[e.PENALTY_TRIGGER_REPORT=0]="PENALTY_TRIGGER_REPORT",e[e.PENALTY_TRIGGER_RECALL=1]="PENALTY_TRIGGER_RECALL"}(Gn||(Gn={})),n(22113),n(300),Fn.TOBACCO,Fn.VIOLENT,Fn.DANGEROUS,Fn.OVERLY_SEXUALIZED,Fn.SPAM,Fn.UNORIGINAL,Fn.MINOR_SAFETY,Fn.UNORIGINAL_NR,Fn.REPRODUCED,Fn.COMMUNITY_GUIDELINES,Fn.OTHER,Vn.CANNOT_SUBMIT,bn.APPEAL_FAIL,Vn.CAN_SUBMIT,bn.ON_APPEAL,Vn.NO_PENALTY,bn.APPEAL_SUCCESS,Vn.REVIEWING,bn.ON_APPEAL,Vn.SUCCEEDED,bn.APPEAL_SUCCESS,Vn.FAILED,bn.APPEAL_FAIL,Vn.TIMEOUT,bn.APPEAL_EXPIRED;var ii=n(68878),oi=n(37568);const ai={punish_key:"",object_type:fn.VIDEO,object_id:"",content_info_list:[]},ri={app_id:1988,aid:1988,app_name:"tiktok_web",device_id:0,device_platform:"tiktok_web",device_type:"tiktok_web"};let si=class extends Mn.E{constructor(e,t){super(),this.reportService=e,this.t=t,this.defaultState={detail:ai,reporterAppealInfo:null,violationList:[],contentDetailList:[],appealReasons:[],audioCopyrightInfo:null,currentAppealReason:null,status:"init",isV2:!0,surveyData:null,loggedOutCode:null}}setViolationAppealStatus(e,t){e.status=t}postAdAppeal(e){return e.pipe((0,Wn.E)(this.state$),(0,Zn.p)((([{reason:e,text:t,extraData:n,region:i,uid:o,extra:a,report_from:r}])=>{const{logExtraParams:s,cid:l,logExtraStr:c}=(e=>{let t={},n="",i="",o={cid:"",log_extra:""};try{o=JSON.parse(e),i=o.cid,o.log_extra&&(n=o.log_extra,t=JSON.parse(o.log_extra))}catch(e){}return{logExtraParams:t,logExtraStr:n,cid:i}})(a),d={origin:"tiktok_web",data:JSON.stringify(Object.assign(Object.assign({app_name:"tiktok_web",aid:1988,current_region:i,reason:e,report_type:"ad"},{}),{report_from:"creative",user_id:o,user_ip:"",version:"",device_id:"",platform:"web",install_id:"",group_id:"",item_id:"",text:(null==n?void 0:n.description)||"",report_type_id:Number(e),report_type_name:t,extra:JSON.stringify({cid:l,log_extra:c,req_id:null==s?void 0:s.req_id}),content_type:"ad"}))},u=Object.assign(Object.assign({},ri),{user_id:Number(o)});return this.reportService.postReport(d,u).pipe((0,Yn.W)((()=>(0,Kn.of)({status:"unknown_error"}))),(0,Xn.Z)((t=>("success"===t.status?oi.J.handleReport({tag:r,category:ti.XJ,refer:ti.Hq.Button,ad_extra_data:JSON.stringify(Object.assign(Object.assign({},n),{reason_id:`${e}`})),log_extra:c,value:l,is_ad_event:"1"}):ni.F.open({content:this.t("Sorry, something wrong with the server, please try again."),duration:2,widthType:"half"}),(0,Kn.of)()))),(0,Qn.Z)(this.getActions().setViolationAppealStatus("submitting")),(0,Jn.q)(this.getActions().setViolationAppealStatus("submitted")))})))}};(0,k.__decorate)([(0,Nn.h5)(),(0,k.__metadata)("design:type",Function),(0,k.__metadata)("design:paramtypes",[Object,String]),(0,k.__metadata)("design:returntype",void 0)],si.prototype,"setViolationAppealStatus",null),(0,k.__decorate)([(0,Nn.Mj)(),(0,k.__metadata)("design:type",Function),(0,k.__metadata)("design:paramtypes",[ei.c]),(0,k.__metadata)("design:returntype",void 0)],si.prototype,"postAdAppeal",null),si=(0,k.__decorate)([(0,Dn.n)("AdViolationAppeal"),(0,k.__param)(1,(0,Rn.y)(C.hp)),(0,k.__metadata)("design:paramtypes",[ii.D,Function])],si);const li=(0,ae.default)("div",{target:"ekur9620"})({height:"100%",width:"100%",display:"flex",flexDirection:"column",alignItems:"stretch",overflow:"hidden"},"label:Container;"),ci=(0,ae.default)("div",{target:"ekur9621"})((({showTopBanner:e})=>[{display:"flex",flexDirection:"row",alignItems:"center",margin:"24px 24px 16px 24px"},e&&{marginBottom:"0"}]),"label:DivHeader;"),di=(0,ae.default)("span",{target:"ekur9622"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"H4",color:"TextPrimary",fontWeight:"bold"}),{flexGrow:1}]),"label:SpanHeaderTitle;"),ui=(0,ae.default)("div",{target:"ekur9623"})((({theme:{direction:e,colors:t}})=>[Object.assign(Object.assign({width:"24px",height:"24px",cursor:"pointer"},"rtl"===e&&{transform:"rotate(180deg)"}),{"> svg > path":{fill:t.TextPrimary}})]),"label:DivBackButton;");var pi=n(93037),vi=n(54622),mi=n(84827),gi=n(25616),hi=n(60094),_i=n(35626),fi=n.n(_i);const yi={position:"absolute",bottom:0,left:0,height:0,overflow:"hidden","padding-top":0,"padding-bottom":0,border:"none"},bi=["box-sizing","width","font-size","font-weight","font-family","font-style","letter-spacing","text-indent","white-space","word-break","overflow-wrap","padding-left","padding-right"];function wi(e,t){var n;if("letters"!==t&&"words"!==t)throw new Error(`Unsupported options basedOn: ${t}`);if(e.nodeType===Node.TEXT_NODE){const t=document.createDocumentFragment();Array.from(e.textContent||"").forEach((e=>{t.appendChild(function(e){const t=document.createElement("span");return t.className="LinesEllipsis-unit",t.textContent=e,t}(e))})),null===(n=e.parentNode)||void 0===n||n.replaceChild(t,e)}else if(e.nodeType===Node.ELEMENT_NODE){const n=[].slice.call(e.childNodes),i=n.length;for(let e=0;enull,winWidth:void 0},Ai=Object.keys(Ei);class Oi extends _.Component{constructor(e){super(e),this.state={html:e.unsafeHTML,clamped:!1},this.canvas=null,this.maxLine=0,this.nlUnits=[]}componentDidMount(){this.initCanvas(),this.reflow(this.props)}componentDidUpdate(e){e.winWidth!==this.props.winWidth&&this.copyStyleToCanvas(),fi()(this.props,e)||this.reflow(this.props)}componentWillUnmount(){this.canvas.parentNode.removeChild(this.canvas)}setState(e,t){return void 0!==e.clamped&&(this.clamped=e.clamped),super.setState(e,t)}initCanvas(){if(this.canvas)return;this.canvas=document.createElement("div");const{canvas:e}=this;e.className=`LinesEllipsis-canvas ${this.props.className}`,e.setAttribute("aria-hidden","true"),this.copyStyleToCanvas(),Object.keys(yi).forEach((t=>{e.style[t]=yi[t]})),document.body.appendChild(e)}copyStyleToCanvas(){const e=window.getComputedStyle(this.target);bi.forEach((t=>{this.canvas.style[t]=e[t]}))}reflow(e){this.maxLine=Number(e.maxLine)||1,this.canvas.innerHTML=e.unsafeHTML;const t=e.basedOn||(/^[\x00-\x7F]+$/.test(e.unsafeHTML)?"words":"letters");wi(this.canvas,t);const n={clamped:this.putEllipsis(this.calcIndexes()),html:this.canvas.innerHTML};this.setState(n,e.onReflow.bind(this,n))}calcIndexes(){const e=[0];this.nlUnits=Array.from(this.canvas.querySelectorAll(".LinesEllipsis-unit"));const{nlUnits:t}=this,n=t.length;if(!t.length)return e;const i=t.find(Si);if(!i)return e;let o=1,{offsetTop:a}=i;for(let i=1;i1&&(o++,e.push(i),a=t[i].offsetTop,o>this.maxLine));i++);return e}putEllipsis(e){if(e.length<=this.maxLine)return!1;this.nlUnits=this.nlUnits.slice(0,e[this.maxLine]);let t=this.nlUnits.pop();const n=this.makeEllipsisSpan();do{Ti(t,this.canvas),ki(t).appendChild(n),t=this.nlUnits.pop()}while(t&&(!Si(t)||n.offsetHeight>t.offsetHeight||n.offsetTop>t.offsetTop));return t&&xi(t),this.nlUnits.forEach(xi),!0}makeEllipsisSpan(){const{ellipsisHTML:e,ellipsis:t}=this.props,n=document.createElement("span"),i=document.createElement("span");return i.className="p1 font-semibold text-color-TextSecondary",i.setAttribute("style","cursor: pointer;"),e?i.innerHTML=e:i.textContent=t,n.appendChild(i),n}isClamped(){return this.clamped}render(){const{html:e,clamped:t}=this.state,n=this.props,{component:i,className:o,unsafeHTML:a}=n,r=(0,k.__rest)(n,["component","className","unsafeHTML"]);return(0,l.jsx)(i,Object.assign({className:`LinesEllipsis ${t?"LinesEllipsis--clamped":""} ${o}`,ref:e=>{this.target=e}},function(e,t){if(!e||"object"!=typeof e)return e;const n={};return Object.keys(e).forEach((i=>{t.indexOf(i)>-1||(n[i]=e[i])})),n}(r,Ai),{children:(0,l.jsx)("div",{dangerouslySetInnerHTML:{__html:t?e:a}})}))}}Oi.defaultProps=Ei;const Pi=Oi,Ii=(0,ae.default)("div",{target:"e6o8e620"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:12}]),"label:SectionHeader;"),Ci=(0,ae.default)("div",{target:"e6o8e621"})((({showDivider:e})=>[{display:"flex",alignItems:"flex-start",justifyContent:"space-between"},e&&{cursor:"pointer",paddingBottom:8}]),"label:ContentHeader;"),Li=(0,ae.default)("div",{target:"e6o8e622"})((({theme:e,isList:t})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{marginBottom:8},t&&{paddingInlineEnd:30}]),"label:ContentTitle;"),ji=(0,ae.default)("div",{target:"e6o8e623"})((({theme:e,showDivider:t,isList:n})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextTertiaryAlt",fontWeight:"normal"}),n&&Object.assign({paddingTop:16},t&&{paddingTop:0,marginBottom:12})]),"label:ContentDescription;"),Mi=(0,ae.default)("div",{target:"e6o8e624"})([{marginBottom:16}],"label:ContentDivider;"),Ni=(0,ae.default)("div",{target:"e6o8e625"})((({theme:{direction:e,colors:t},isShow:n})=>[Object.assign(Object.assign({minWidth:"16px",width:"16px",height:"16px",transition:"transform .4s"},"rtl"===e&&{transform:"rotate(180deg)"}),{"> svg > path":{fill:t.TextTertiary}}),n&&{transform:"rotateZ(-90deg)"}]),"label:DivArrowContainer;");var Di=n(88091),Ri=n(7399);const Bi=({isShowByDefault:e,showSeeMore:t,showDivider:n,item:i,seeMoreText:o,onToggle:a})=>{const[r,s]=(0,_.useState)(e),[c,d]=(0,_.useState)(!0),u=(0,_.useCallback)((()=>{0!==i.contentList.length&&s((e=>(a&&a(!e),!e)))}),[a,i]),p=(0,l.jsx)("section",{children:(0,l.jsx)("article",{children:i.contentList.map(((e,t)=>"break"===e.type?(0,l.jsx)("br",{},t):"text"===e.type?(0,l.jsx)("p",{children:e.text},t):"list"===e.type?(0,l.jsx)("ul",{children:(e.list||[]).map(((e,n)=>(0,l.jsx)("li",{className:0===t?"mb-8":"my-8",children:e},n)))},t):null))})}),{value:v}=(0,_.useContext)(ee.xm),m=(0,l.jsx)("span",{style:Object.assign({color:"rgba(0, 0, 0, 0.72)",fontWeight:500},v&&{color:"rgba(255, 255, 255, 0.75)"}),children:`... ${o}`});return(0,l.jsx)(l.Fragment,{children:t?(0,l.jsxs)("article",{children:[(0,l.jsx)(Li,{children:i.title}),c?(0,l.jsx)(ji,{children:(0,l.jsx)(Pi,{"data-cy":"see-more-btn",onClick:()=>d(!1),unsafeHTML:hi.renderToString(p),maxLine:"4",basedOn:"letters",ellipsisHTML:hi.renderToString(m),style:{overflowWrap:"break-word",wordBreak:"break-word",wordWrap:"break-word"}})}):(0,l.jsx)(ji,{children:p})]}):(0,l.jsxs)("article",{children:[(0,l.jsxs)(Ci,{showDivider:n,onClick:u,children:[(0,l.jsx)(Li,{isList:!0,children:i.title}),i.contentList.length>0&&(0,l.jsx)(Ni,{isShow:r,children:(0,l.jsx)(Ri.A,{width:16,height:16})})]}),r&&(0,l.jsx)(ji,{isList:!0,showDivider:n,children:p}),n&&(0,l.jsx)(Mi,{children:(0,l.jsx)(Di.zm,{size:"medium",color:"LineSecondary"})})]})})},Ui=/
  • ([\s\S]*?)<\/li>/g,Fi=()=>{},Vi=({title:e,list:t,isShowByDefault:n=!1,seeMoreText:i="",handleOpenLink:o=Fi,onToggle:a})=>{const r=(0,_.useMemo)((()=>t.map((e=>{var t;const n=Object.assign(Object.assign({},e),{contentList:[]});if(e.content_v2&&e.content_v2.length>1&&""!==e.content_v2[0])return e.content_v2.forEach(((t,i)=>{n.contentList.push({text:t,type:"text"}),e.content_v2&&i!==e.content_v2.length-1&&n.contentList.push({text:"",type:"break"})})),n;if(!e.content)return n;let i=0,o=Ui.exec(e.content);for(;null!==o;){o.index!==i&&n.contentList.push({text:e.content.slice(i,o.index),type:"text"});const{length:a}=n.contentList,r=o.length>1?o[1]:"";a&&"list"===n.contentList[a-1].type?null===(t=n.contentList[a-1].list)||void 0===t||t.push(r):n.contentList.push({list:[r],type:"list"}),i=o.index+o[0].length,o=Ui.exec(e.content)}return i<=e.content.length&&n.contentList.push({text:e.content.slice(i),type:"text"}),n}))),[t]);return(0,l.jsxs)("div",{children:[(0,l.jsx)(Ii,{children:e}),r.map(((e,t)=>(0,l.jsx)(Bi,{item:e,isShowByDefault:n,seeMoreText:i,showSeeMore:1===r.length,showDivider:1!==r.length&&t!==r.length-1,onToggle:e=>null==a?void 0:a(t,e),onOpenLink:o},t)))]})};var zi=n(50708),Hi=n.n(zi);const qi=(0,ae.default)("div",{target:"e10vb9hi0"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:12}]),"label:SectionHeader;"),Gi=(0,ae.default)("div",{target:"e10vb9hi1"})((({theme:e,hasBorder:t})=>[{fontSize:0,height:40,width:40,borderRadius:24,display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.colors.BGTertiary,color:e.colors.TextPrimary},t&&{border:`1px solid ${e.colors.LineSecondary2}`}]),"label:DivIconWrapper;"),$i=(0,ae.default)("div",{target:"e10vb9hi2"})((({isHelpAndSupport:e})=>[{display:"flex",flexDirection:"row"},e?{alignItems:"center"}:{alignItems:"start"}]),"label:SectionContentContainer;"),Wi=(0,ae.default)("div",{target:"e10vb9hi3"})((({theme:{direction:e},hasHeartIcon:t})=>[Object.assign({display:"flex",flexDirection:"column",alignItems:"start",flexGrow:1},"rtl"===e&&{marginLeft:0}),t&&{paddingInlineStart:12}]),"label:SectionContent;"),Zi=(0,ae.default)("div",{target:"e10vb9hi4"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextSecondary",fontWeight:"normal"}),{wordBreak:"break-word"}]),"label:SectionContentMain;"),Yi=(0,ae.default)("div",{target:"e10vb9hi5"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{display:"inline"}]),"label:TitleText;"),Ki=(0,ae.default)("div",{target:"e10vb9hi6"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"}),{display:"inline",cursor:"pointer"}]),"label:InnerLinkText;"),Xi=(0,ae.default)("div",{target:"e10vb9hi7"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextTertiaryAlt",fontWeight:"normal"}),{marginTop:4}]),"label:SectionContentFooter;"),Qi=(0,ae.default)("div",{target:"e10vb9hi8"})((({theme:{direction:e},imageUrl:t,isProfileIcon:n})=>[Object.assign({width:68,height:87,borderRadius:4,overflow:"hidden",backgroundSize:"cover",backgroundPosition:"center",backgroundRepeat:"no-repeat",position:"relative",marginTop:-33,marginLeft:12,backgroundImage:`url(${t})`},"rtl"===e&&{marginLeft:0,marginRight:12}),n&&{height:44,width:44,borderRadius:40}]),"label:VideoPoster;"),Ji=(0,ae.default)("div",{target:"e10vb9hi9"})({position:"absolute",top:0,left:0,width:"100%",height:"100%",backgroundColor:"rgba(0, 0, 0, 0.5)",backgroundImage:"url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMjAiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHJlY3Qgd2lkdGg9IjEuNTAwNTYiIGhlaWdodD0iMTcuNzY4NCIgcng9IjAuNSIgdHJhbnNmb3JtPSJtYXRyaXgoMC42OTkxODYgLTAuNzE0OTQgLTAuNzE0OTQgLTAuNjk5MTg2IDE1LjIwMzMgMTYuMjUpIiBmaWxsPSJ3aGl0ZSIvPgo8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTEwLjA3MDcgMTQuNTU1OUMxMS4xODA2IDE0LjU1NTkgMTIuMjM0MyAxNC4zODcyIDEzLjE4MjMgMTQuMDg0NEwxMi4wMDIxIDEyLjkzMDJDMTEuOTgwMyAxMi45MDg5IDExLjk2MDggMTIuODg2IDExLjk0MzggMTIuODYyQzExLjM1OTMgMTIuOTg2NCAxMC43MzA4IDEzLjA1NTQgMTAuMDcwNyAxMy4wNTU0QzguMjY4OTUgMTMuMDU1NCA2LjcwMjE5IDEyLjU0MTggNS42MjU5NCAxMS43ODg0QzQuNTQ0OTUgMTEuMDMxNyA0LjA2ODQ5IDEwLjEzMDMgNC4wNjg0OSA5LjMwNDAzQzQuMDY4NDkgOC40Nzc4IDQuNTQ0OTUgNy41NzYzNiA1LjYyNTk0IDYuODE5NjdDNS42NTA3MSA2LjgwMjMzIDUuNjc1NzQgNi43ODUxMiA1LjcwMTAzIDYuNzY4MDRMNC42MTA4MSA1LjcwMTg1QzMuMzQ0MjUgNi42NDIxNyAyLjU2Nzk1IDcuOTA5NjQgMi41Njc5NSA5LjMwNDAzQzIuNTY3OTUgMTIuMjA0NiA1LjkyNzAyIDE0LjU1NTkgMTAuMDcwNyAxNC41NTU5Wk02Ljk3NzExIDQuNTE3OTRDNy45MjAzMyA0LjIxODczIDguOTY3NyA0LjA1MjE0IDEwLjA3MDcgNC4wNTIxNEMxNC4yMTQzIDQuMDUyMTQgMTcuNTczNCA2LjQwMzQ5IDE3LjU3MzQgOS4zMDQwM0MxNy41NzM0IDEwLjY5MzQgMTYuODAyNiAxMS45NTY4IDE1LjU0NDEgMTIuODk2MUwxNC40NTQ0IDExLjgzMDRDMTQuNDc0OSAxMS44MTY1IDE0LjQ5NTIgMTEuODAyNSAxNC41MTU0IDExLjc4ODRDMTUuNTk2NCAxMS4wMzE3IDE2LjA3MjggMTAuMTMwMyAxNi4wNzI4IDkuMzA0MDNDMTYuMDcyOCA4LjQ3NzggMTUuNTk2NCA3LjU3NjM2IDE0LjUxNTQgNi44MTk2N0MxMy40MzkxIDYuMDY2MyAxMS44NzI0IDUuNTUyNjggMTAuMDcwNyA1LjU1MjY4QzkuNDIxNDkgNS41NTI2OCA4LjgwMjgyIDUuNjE5MzYgOC4yMjY2MSA1LjczOTlMNi45NzcxMSA0LjUxNzk0WiIgZmlsbD0id2hpdGUiLz4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xMC44NTY5IDExLjgxMDJDMTAuNjA4NyAxMS44ODggMTAuMzQ0NiAxMS45MyAxMC4wNzA3IDExLjkzQzguNjIwMzkgMTEuOTMgNy40NDQ3MiAxMC43NTQzIDcuNDQ0NzIgOS4zMDQwM0M3LjQ0NDcyIDkuMDUwNjUgNy40ODA2IDguODA1NjUgNy41NDc1NyA4LjU3Mzg0TDEwLjg1NjkgMTEuODEwMlpNOS4zMDI2NSA2Ljc5MjE4QzkuNTQ1NTcgNi43MTc5OSA5LjgwMzQ2IDYuNjc4MDggMTAuMDcwNyA2LjY3ODA4QzExLjUyMDkgNi42NzgwOCAxMi42OTY2IDcuODUzNzYgMTIuNjk2NiA5LjMwNDAzQzEyLjY5NjYgOS41NTA3NCAxMi42NjI2IDkuNzg5NSAxMi41OTkgMTAuMDE1OUw5LjMwMjY1IDYuNzkyMThaIiBmaWxsPSJ3aGl0ZSIvPgo8L3N2Zz4K')",backgroundSize:"20px 20px",backgroundPosition:"center",backgroundRepeat:"no-repeat"},"label:MaskIcon;"),eo={id:"heart-4636b1b5",use:"heart-4636b1b5-usage",viewBox:"0 0 40 40",content:''};function to(e){const t=(0,_.useContext)(W.X);return(0,_.useLayoutEffect)((()=>(t.add(eo),()=>{t.remove("heart-4636b1b5")})),[]),(0,l.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,l.jsx)("use",{xlinkHref:"#heart-4636b1b5"},void 0)}),void 0)}const no={id:"photo-4dee05ae",use:"photo-4dee05ae-usage",viewBox:"0 0 48 48",content:''};function io(e){const t=(0,_.useContext)(W.X);return(0,_.useLayoutEffect)((()=>(t.add(no),()=>{t.remove("photo-4dee05ae")})),[]),(0,l.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,l.jsx)("use",{xlinkHref:"#photo-4dee05ae"},void 0)}),void 0)}var oo=n(62541),ao=n(32567),ro=n(54977),so=n(87992),lo=n(81678),co=n(86406),uo=n(63581);const po=e=>{var t;const{contentInfo:n,handlePressLink:i,title:o}=e;if(null==n?void 0:n.content_id){const e={item_id:n.content_id,result_type:n.result_type,reason_code:n.reason_code};ke.f.event("web_appeal_result_show",e)}const a=(e,t,n)=>{var i,o;if(n){let e=null!==(i=n.text)&&void 0!==i?i:"";for(const t of null!==(o=n.elements)&&void 0!==o?o:[])e=e.replace(t.placeholder,``);return t?`"${e}"`:e}return t?`"${e}"`:e},r=e=>{let t,n=!0;switch(e){case yn.VIDEO:t=(0,l.jsx)(oo.q,{size:20});break;case yn.COMMENT:t=(0,l.jsx)(ao.S,{size:20});break;case yn.AUDIO:t=(0,l.jsx)(ro.G,{size:20});break;case yn.LINK:t=(0,l.jsx)(so.j,{size:20});break;case yn.HASHTAG:t=(0,l.jsx)(lo.g,{size:20});break;case yn.IMAGE:t=(0,l.jsx)(co.P,{size:20});break;case yn.USER:t=(0,l.jsx)(uo.Y,{size:20});break;case yn.PHOTO:t=(0,l.jsx)(io,{width:20,height:20});break;case yn.HEART:t=(0,l.jsx)(to,{width:40,height:40}),n=!1;break;default:t=(0,l.jsx)(uo.Y,{size:20})}return(0,l.jsx)(Gi,{hasBorder:n,children:t})},s=n?[n]:[];return(0,l.jsxs)("div",{children:[(0,l.jsx)(qi,{children:null!==(t=null==n?void 0:n.header)&&void 0!==t?t:o}),null==s?void 0:s.map(((e,t)=>{const{title:n,content:o,has_quote:s,inner_link_text:c,inner_link_url:d,image_url:u,image_has_mask:p,icon_type:v,rich_text:m}=e;return(0,l.jsxs)($i,{isHelpAndSupport:v===yn.HEART,children:[v===yn.HEART&&r(v),(0,l.jsxs)(Wi,{hasHeartIcon:v===yn.HEART,children:[(0,l.jsxs)(Zi,{children:[n&&(0,l.jsx)(Yi,{dangerouslySetInnerHTML:{__html:Hi().sanitize(a(n,s,m))}}),c&&(0,l.jsxs)(Ki,{onClick:()=>i&&i(d),children:[" ",c]})]}),(0,l.jsx)(Xi,{children:o})]}),u&&(0,l.jsx)(Qi,{imageUrl:u,isProfileIcon:v===yn.PROFILE,children:p&&(0,l.jsx)(Ji,{})})]},t)}))]})},vo=(0,ae.default)("div",{target:"e1j3z3dm0"})({paddingLeft:24,paddingRight:24,height:"100%",flexGrow:1},"label:Container;"),mo=(0,ae.default)("div",{target:"e1j3z3dm1"})((({theme:e})=>({padding:16,backgroundColor:e.colors.BGPrimary,borderRadius:8,marginBottom:8})),"label:ComponentWrapper;"),go=(0,ae.default)("div",{target:"e1j3z3dm2"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"})]),"label:FooterText;"),ho=(0,ae.default)("div",{target:"e1j3z3dm4"})((({showAppealButton:e})=>[{position:"relative",bottom:"0",left:"0",width:"100%",height:54,marginBottom:12,padding:8,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},e&&{alignItems:"start",paddingLeft:24}]),"label:DivFooter;"),_o=(0,ae.default)("div",{target:"e1j3z3dm5"})({display:"flex",flexDirection:"column",height:"580px",overflowY:"auto"},"label:ContainerWrapper;"),fo=(0,ae.default)("div",{target:"e1j3z3dm6"})({display:"flex",flexDirection:"column",alignItems:"center",textAlign:"center",marginBottom:32},"label:SectionAppealStatus;"),yo=(0,ae.default)("div",{target:"e1j3z3dm7"})((e=>[(0,yt.zy)({theme:e.theme,color:e.$color}),{display:"flex",justifyContent:"center",alignItems:"center"}]),"label:DivIconWrapper;"),bo=(0,ae.default)("div",{target:"e1j3z3dm8"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"H4",color:"TextPrimary",fontWeight:"bold"}),{marginTop:18,textAlign:"center"}]),"label:AppealTitle;"),wo=(0,ae.default)("div",{target:"e1j3z3dm9"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{marginTop:12,textAlign:"center"}]),"label:AppealSubtitle;"),xo=(0,ae.default)("div",{target:"e1j3z3dm10"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),To=(0,ae.default)("div",{target:"e1j3z3dm11"})({flexGrow:1},"label:FlexGrowDiv;"),ko=(0,ae.default)("div",{target:"e1cp17ug0"})((({hideMargin:e=!1})=>Object.assign({},!e&&{marginTop:12})),"label:HyperlinkTextContainer;"),So=(0,ae.default)("div",{target:"e1cp17ug1"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{display:"inline"}]),"label:MainTextContent;"),Eo=(0,ae.default)("div",{target:"e1cp17ug2"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"}),{display:"inline",cursor:"pointer"}]),"label:LinkTextContent;"),Ao=e=>{const{hideMargin:t=!1,btnText:n,onClick:i}=e;if(!n)return null;const{text:o,links:a=[]}=n,r=function(e,t){let n=0;const i=[],o=[];try{t.forEach((t=>{e.indexOf(t.placeholder)>=0&&o.push({idx:e.indexOf(t.placeholder),length:t.placeholder.length,link_obj:t})})),o.sort(((e,t)=>e.idx-t.idx));let a=0;for(;n"string"===e.type&&e.text?(0,l.jsx)(So,{children:e.text},`text_${t}`):"url"===e.type&&e.text&&e.url?(0,l.jsx)(Eo,{onClick:()=>i(e.url),children:e.text},`url_${t}`):null))})},Oo=(0,ae.default)("div",{target:"e1w4n3ph0"})({display:"flex",flexDirection:"column",marginBottom:20,"&:last-of-type":{marginBottom:0}},"label:TextWrapper;"),Po=(0,ae.default)("div",{target:"e1w4n3ph1"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:6}]),"label:Title;"),Io=(0,ae.default)("div",{target:"e1w4n3ph2"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{wordBreak:"break-word"}]),"label:Description;"),Co=({successTitle:e,failureTitle:t,successDesc:n,failureDesc:i})=>{const o=[{title:t,description:i},{title:e,description:n}];return(0,l.jsx)("div",{children:o.map((({title:e,description:t},n)=>(0,l.jsxs)(Oo,{children:[(0,l.jsx)(Po,{children:e}),(0,l.jsx)(Io,{children:t})]},n)))})},Lo=({handleClose:e})=>{var t,n,i;const o=(0,gi.s)(),{status:a,detail:r,contentDetailList:s}=(0,In.P)(si),{language:c}=null!==(t=(0,We.W)((()=>["language"]),[]))&&void 0!==t?t:{},d=null==r?void 0:r.object_type,u=null===(n=r.violation_info)||void 0===n?void 0:n.violation_info_status,p=(null===(i=null==r?void 0:r.violation_info)||void 0===i?void 0:i.header)||"",v=d===fn.CONTENT_CHECK_VIDEO,m=u===wn.VIOLATION_INFO_IN_PROGRESS,g=v&&m,h=r.content_info_list,f=(0,_.useRef)({}),y=(0,_.useCallback)(((e,t)=>{const n=`category_${e+1}`;"no"===f.current[n]&&t&&(f.current[n]="yes")}),[]),b=(0,_.useCallback)((e=>(0,k.__awaiter)(void 0,void 0,void 0,(function*(){e&&window.open(e,"_blank")}))),[a,r,s]);if("loading"===a)return(0,l.jsx)(mi.R,{center:!0,size:"small"});const w={text:o("dsaCGWebapp_detailPg_sectionCG_body"),links:[{link_text:o("tcm_tt_ad_policy_link"),placeholder:"%s",url:`https://support.tiktok.com/${c}/business-and-creator/creator-and-business-accounts`}]};return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)(ci,{children:[(0,l.jsx)(To,{}),(0,l.jsx)(xo,{onClick:e,children:(0,l.jsx)(vi.A,{width:14,height:14})})]}),(0,l.jsx)(_o,{children:(0,l.jsxs)(vo,{children:[(0,l.jsxs)(fo,{children:[(0,l.jsx)(yo,{$color:"LinePrimary2",children:(0,l.jsx)(pi.i,{size:48})}),(0,l.jsx)(bo,{children:o("dsaCGWebapp_appealSubmitted_sectionTitle_header")}),(0,l.jsx)(wo,{children:o("vidModAnalytics_inbox_notifAppealSubmitted__xNotifBody")})]}),(h||[]).map(((e,t)=>(0,l.jsxs)(mo,{children:[console.log("ContentInfoSection: ",e),(0,l.jsx)(po,{contentInfo:e,handlePressLink:b})]},t))),g&&(0,l.jsx)(mo,{children:(0,l.jsx)(Co,{successTitle:o("contentCheck_progressScreen_page_bullet2Header"),successDesc:o("contentCheck_progressScreen_page_bullet2Body"),failureTitle:o("contentCheck_progressScreen_page_bullet1Header"),failureDesc:o("contentCheck_progressScreen_page_bullet1Body_postPrivate")})}),(null==s?void 0:s.length)>0&&(0,l.jsx)(mo,{children:(0,l.jsx)(Vi,{title:p,list:s,onToggle:y,handleOpenLink:b,seeMoreText:o("search_see_more")})})]})}),(0,l.jsx)(ho,{children:(0,l.jsx)(go,{children:(0,l.jsx)(Ao,{hideMargin:!0,btnText:w,onClick:b})})})]})};var jo=n(26456);const Mo=(0,ae.default)("div",{target:"e1xiurx30"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"}),{marginTop:24}]),"label:SubtitleDiv;"),No=(0,ae.default)("div",{target:"e1xiurx31"})((({theme:e})=>({borderTop:`1px solid ${e.colors.LineSecondary}`,paddingLeft:24,paddingRight:24})),"label:Container;"),Do=(0,ae.default)("div",{target:"e1xiurx32"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"}),{marginTop:32}]),"label:SectionHeaderDiv;"),Ro=(0,ae.default)("div",{target:"e1xiurx33"})({width:72,height:72,borderRadius:6,overflow:"hidden",backgroundSize:"cover",backgroundPosition:"center center",backgroundRepeat:"no-repeat"},"label:ImageDiv;"),Bo=(0,ae.default)("div",{target:"e1xiurx34"})({display:"flex",flexDirection:"row",marginTop:16,alignItems:"center"},"label:ContentInfoRow;"),Uo=(0,ae.default)("div",{target:"e1xiurx35"})({display:"flex",flexDirection:"column",marginInlineStart:16},"label:ContentInfoDetails;"),Fo=(0,ae.default)("div",{target:"e1xiurx36"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"})]),"label:ContentInfoDetailsTitle;"),Vo=(0,ae.default)("div",{target:"e1xiurx37"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextTertiaryAlt",fontWeight:"normal"})]),"label:ContentInfoDetailsContent;"),zo=(0,ae.default)("div",{target:"e1xiurx38"})({marginTop:32},"label:MarginTop32DivWrapper;"),Ho=(0,ae.default)("div",{target:"e1xiurx39"})({marginTop:16},"label:MarginTop16DivWrapper;"),qo=(0,ae.default)("span",{target:"e1xiurx310"})((({theme:e})=>[(0,yt.zy)({theme:e,color:"Primary"})]),"label:PrimarySpanText;"),Go=(0,ae.default)("textarea",{target:"e1xiurx311"})((({theme:e})=>Object.assign(Object.assign({},(e=>({borderStyle:"none",borderColor:"transparent",boxShadow:"none",outline:"none",marginTop:"10px",fontSize:"16px",fontFamily:e.fontFamilies.TikTokFont,fontWeight:e.fontWeights.normal,color:e.colors.TextPrimary,":placeholder":{color:e.colors.TextQuaternary}}))(e)),{resize:"none",height:"48px",width:"100%",backgroundColor:e.colors.BGPrimary})),"label:TextareaDescription;"),$o=(0,ae.default)("div",{target:"e1xiurx312"})((({theme:e})=>({paddingBottom:"12.5px",borderBottom:`0.5px solid ${e.colors.LineInput}`})),"label:TextareaWrapper;"),Wo=(0,ae.default)("div",{target:"e1xiurx313"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"})]),"label:TextAreaHeader;"),Zo=(0,ae.default)("div",{target:"e1xiurx314"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"})]),"label:TextAreaWordCount;"),Yo=(0,ae.default)("div",{target:"e1xiurx315"})({display:"flex",flexDirection:"row"},"label:FlexRowDiv;"),Ko=(0,ae.default)("div",{target:"e1xiurx316"})({flexGrow:1},"label:FlexGrowDiv;"),Xo=(0,ae.default)("div",{target:"e1xiurx317"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P4",color:"TextSecondary",fontWeight:"normal"}),{marginTop:32,marginBottom:17}]),"label:FooterText;"),Qo=(0,ae.default)("span",{target:"e1xiurx318"})((({theme:e})=>[(0,yt.zy)({theme:e,color:"TextPrimary",fontWeight:"semiBold"})]),"label:LinkSpan;"),Jo=(0,ae.default)("div",{target:"e1xiurx319"})((({theme:e})=>({position:"relative",bottom:"0",left:"0",height:"84px",width:"100%",borderTop:`0.5px solid ${e.colors.LinePrimary2}`,backgroundColor:e.colors.BGPrimary})),"label:DivFooter;"),ea=(0,ae.default)("div",{target:"e1xiurx320"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),ta=(0,ae.default)("div",{target:"e13mo2lr0"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"})]),"label:TitleDiv;"),na=(0,ae.default)("div",{target:"e13mo2lr1"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextPrimary",fontWeight:"normal"}),{marginTop:16}]),"label:ContentDiv;"),ia=({title:e,text:t})=>(0,l.jsxs)("div",{children:[(0,l.jsx)(ta,{children:e}),(0,l.jsx)(na,{children:t})]});var oa=n(33843);const aa={id:"header-arrow-f8c49d4b",use:"header-arrow-f8c49d4b-usage",viewBox:"0 0 24 24",content:''};function ra(e){const t=(0,_.useContext)(W.X);return(0,_.useLayoutEffect)((()=>(t.add(aa),()=>{t.remove("header-arrow-f8c49d4b")})),[]),(0,l.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,l.jsx)("use",{xlinkHref:"#header-arrow-f8c49d4b"},void 0)}),void 0)}var sa=n(21512),la=n(86223);const ca=(0,ae.default)("div",{target:"e1opdqbw0"})({padding:"32px",height:"100%"},"label:Container;"),da=(0,ae.default)("div",{target:"e1opdqbw1"})({display:"flex",flexDirection:"column",alignItems:"center",textAlign:"center"},"label:SectionAppealStatus;"),ua=(0,ae.default)("div",{target:"e1opdqbw2"})((e=>[(0,yt.zy)({theme:e.theme,color:e.$color}),{display:"flex",justifyContent:"center",alignItems:"center"}]),"label:DivIconWrapper;"),pa=(0,ae.default)("div",{target:"e1opdqbw3"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",color:"TextPrimary",fontWeight:"bold"}),{fontSize:"24px",lineHeight:"36px",marginTop:"27px",textAlign:"center"}]),"label:AppealTitle;"),va=(0,ae.default)("div",{target:"e1opdqbw4"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",color:"TextSecondary",fontWeight:"normal"}),{fontSize:"16px",lineHeight:"22px",marginTop:"16px",textAlign:"center"}]),"label:AppealSubtitle;"),ma=(0,ae.default)("button",{target:"e1opdqbw5"})((({theme:e})=>({marginTop:"24px",height:"48px",width:"100%",padding:"12px 24px",cursor:"pointer",background:e.colors.Primary,border:"none",borderRadius:"8px"})),"label:PrimaryButton;"),ga=(0,ae.default)("div",{target:"e1opdqbw6"})((({theme:e})=>[(0,yt.zy)({theme:e,fontFamily:"TikTokFont",color:"ConstTextInverse",fontWeight:"bold"}),{fontSize:"16px",lineHeight:"24px",textAlign:"center"}]),"label:PrimaryButtonText;"),ha=({handleClose:e})=>{const t=(0,gi.s)();return(0,l.jsxs)(ca,{children:[(0,l.jsxs)(da,{children:[(0,l.jsx)(ua,{$color:"LinePrimary2",children:(0,l.jsx)(la.Q,{size:72})}),(0,l.jsx)(pa,{children:t("dsa_illegal_appeal_expired_header")}),(0,l.jsx)(va,{children:t("dsa_illegal_appeal_expired_desc")})]}),(0,l.jsx)(ma,{onClick:e,children:(0,l.jsx)(ga,{children:t("dsa_illegal_appeal_button_ok")})})]})},_a=function(e){let t={};try{t=JSON.parse(e)}catch(t){console.error(`JSON.parse report_ad_extra_data error! report_ad_extra_data: ${e}`)}return t},fa=({handleBack:e,handleBackKeyDown:t,handleClose:n,query:i})=>{var o;const{report_type_id:a,report_type_name:r,report_from:s,report_ad_extra_data:c="{}",signature:d,email:u,relevant_law:p,law_country_code:v,notify_time:m,video_name:g,video_post_time:h,video_poster:f,report_unique_id:y,is_trusted_flagger:b,extra:w}=i,x=(0,gi.s)(),T=(0,Vt.w)(si),{region:k="",user:S,language:E}=null!==(o=(0,We.W)((()=>["region","user","language"]),[]))&&void 0!==o?o:{},{status:A,reporterAppealInfo:O}=(0,In.P)(si),P=[{code:"1",text:(0,sa.f2)(Number(a))?x("dsa_illegal_appeal_dropdown_1"):x("vidModAnalytics_appealReporterDetailpg_sectionSelectReason_sectionBullet1")},{code:"2",text:x("dsa_illegal_appeal_dropdown_2")},{code:"3",text:x("dsa_illegal_appeal_dropdown_3")}],[I,C]=(0,_.useState)(""),[L,j]=(0,_.useState)(!1),[M,N]=(0,_.useState)({code:"",text:""});(0,_.useEffect)((()=>{const e=(new Date).getTime(),t=!!m&&e-1e3*Number(m)>15552e6;j(t)}),[]);const D=(0,_.useCallback)((e=>{C(e.target.value)}),[]),R=(0,_.useCallback)((e=>{M.code===e.code?N({code:"",text:""}):N(e)}),[M,N]),B=(0,_.useCallback)((e=>{e.stopPropagation()}),[]),U=(0,_.useCallback)((e=>{e.preventDefault(),e.stopPropagation(),"idle"===A&&T.postAdAppeal({reason:Number(a),text:r,report_from:s,extraData:Object.assign({description:I,report_scene:"1",signature:d,email:u,relevant_law:p,law_country_code:v,appeal_reason_code:M.code,appeal_reason_text:M.text,is_trusted_flagger:!!Number(b),report_unique_id:y},_a(c)),region:k,uid:null==S?void 0:S.uid,extra:w})}),[I,T,O,A,M]);if("loading"===A)return(0,l.jsx)(mi.R,{center:!0,size:"small"});if("submitted"===A)return(0,l.jsx)(Lo,{handleBack:e,handleBackKeyDown:t,handleClose:n});if(L)return(0,l.jsx)(ha,{handleClose:n});let F="",V="";if(h){const e=new Date(1e3*Number(h));F=jo.Ay.format(e,"l"),V=jo.Ay.format(e,"lt")}return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)(ci,{children:[(0,l.jsx)(ui,{onClick:e,onKeyDown:t,tabIndex:0,role:"button",children:(0,l.jsx)(ra,{width:24,height:24})}),(0,l.jsx)(di,{children:x("dsaCGWebapp_appealDetailPg_sectionTitle_header")}),(0,l.jsx)(ea,{onClick:n,children:(0,l.jsx)(vi.A,{width:14,height:14})})]}),(0,l.jsxs)(No,{children:[(0,l.jsx)(Mo,{children:x("dsa_illegal_appeal_desc")}),g&&(0,l.jsxs)("div",{children:[(0,l.jsx)(Do,{children:x("video_detail")}),(0,l.jsxs)(Bo,{children:[(0,l.jsx)(Ro,{style:{backgroundImage:`url(${f})`}}),(0,l.jsxs)(Uo,{children:[(0,l.jsx)(Fo,{children:g}),(0,l.jsx)(Vo,{children:x("vidModAnalytics_detailPg_sectionDatePosted_sectionLabel").replace("%1$s",F).replace("%2$s",V)})]})]})]}),(0,l.jsx)(zo,{children:(0,l.jsx)(ia,{title:x("dsa_illegal_appeal_report_reason"),text:r})}),(0,l.jsxs)(zo,{children:[(0,l.jsxs)(Do,{children:[x("dsa_illegal_appeal_dropdown_title"),(0,l.jsx)(qo,{children:"*"})]}),P.map(((e,t)=>(0,l.jsx)(Ho,{onClick:()=>{R(e)},children:(0,l.jsx)(Di.h$,{label:e.text,checked:M.code===e.code})},`reporter-appeal-reason-${t}`)))]}),(0,l.jsxs)(zo,{children:[(0,l.jsxs)(Yo,{children:[(0,l.jsx)(Wo,{children:x("dsa_illegal_appeal_explanation")}),(0,l.jsx)(Ko,{}),(0,l.jsx)(Zo,{children:`${I.length}/400`})]}),(0,l.jsx)($o,{children:(0,l.jsx)(Go,{rows:2,maxLength:400,placeholder:x("dsa_illegal_appeal_explanation_desc"),value:I,onChange:D,onKeyDown:B})})]}),(0,l.jsxs)(Xo,{children:[x("dsa_illegal_appeal_alt_options").replace("%s",""),(0,l.jsx)(Qo,{onClick:()=>{window.open(`https://support.tiktok.com/${E}/business-and-creator/creator-and-business-accounts`,"_blank")},children:x("dsa_illegal_placeholder_learnmore")})]})]}),(0,l.jsx)(Jo,{children:(0,l.jsx)(oa.jl,{disabled:""===M.code,onClick:U,children:x("Submit")})})]})};var ya=n(54775);const ba=({onBack:e,onClose:t,query:n={}})=>{const i=(0,Vt.w)(si),[o,a]=(0,_.useState)(kn.SUBMIT),r=(0,_.useCallback)((()=>{e?e():a(kn.STATUS)}),[e]),s=(0,_.useCallback)((()=>{t()}),[t]),c=(0,_.useCallback)((()=>{a(kn.SUBMIT)}),[]),d=(0,_.useCallback)((e=>{13!==e.keyCode&&32!==e.keyCode||(e.preventDefault(),e.stopPropagation(),r())}),[r]);return(0,_.useEffect)((()=>{i.setViolationAppealStatus("idle")}),[n,i]),(0,l.jsx)(li,{children:(0,l.jsx)(ya.juU,{children:o===kn.SUBMIT?(0,l.jsx)(fa,{handleBack:r,handleBackKeyDown:d,handleClose:s,query:n}):(0,l.jsx)(Lo,{handleBack:r,handleBackKeyDown:d,handleClose:s,handleAppealClick:c})})})},wa=(0,ae.default)("div",{target:"e16wk1y40"})((()=>({width:"700px"})),"label:ViolationAppealWrapper;");var xa=n(42617);const Ta=(0,_.memo)((function(){const e=function(){const{search:e}=(0,Y.useLocation)();return(0,_.useMemo)((()=>new URLSearchParams(e)),[e])}(),[t,n]=(0,_.useState)(!1),i=(0,In.P)(Ln.L),o=(0,Vt.w)(Ln.L),a=(0,Vt.w)(jn.y7),[r,s]=(0,_.useState)({}),c=(0,_.useMemo)((()=>e.has("ad_report_id")),[e]);(0,_.useEffect)((()=>{var t;if(c){const n=null!==(t=e.get("ad_report_id"))&&void 0!==t?t:"";o.getLogoutReportDetail({reportId:n})}}),[c]),(0,_.useEffect)((()=>{if(i.visible){if(i.reportDetail.data){if(2===i.reportDetail.data.link_status)return void(window.location.href="https://www.tiktok.com/legal/report/report-expired");if(0===i.reportDetail.data.link_status)return void(window.location.href="https://www.tiktok.com/404");if(2===i.reportDetail.data.link_type)return void a.showRereport({rereportObj:i.reportDetail.data});s(i.reportDetail.data)}else s(i.violationAppealInfo);n(!0)}else n(!1)}),[i]);const d=(0,_.useCallback)((()=>{o.setVisible(!1),n(!1)}),[]);return(0,_.useEffect)((()=>{i.reportDetail.data&&!i.reportDetail.isLoading&&o.setVisible(!0)}),[i.reportDetail,o]),(0,l.jsx)(xa.Ay,{autoFocus:!0,disabled:!t,returnFocus:!0,children:(0,l.jsx)(Cn.i,{compact:!0,isOpen:t,closeOnEsc:!0,children:(0,l.jsx)(wa,{children:(0,l.jsx)(ba,{query:r,onClose:()=>{d()}})})})})}));var ka=n(78214),Sa=n(97071);const Ea=n.p+"9ba6b3da175369e04c8c.css";var Aa=n(93341);const Oa=()=>{const{appContext:e}=(0,In.P)(En.L,{selector:({appContext:e})=>({appContext:e}),dependencies:[]}),t=(0,dt.Ig)(),{user:n}=(0,Ye.L$)(e),i=(0,ct.zy)(),o=(0,_.useMemo)((()=>(0,Sn.parse)(i.search)),[i.search]),a=(0,_.useRef)(!0),{setIsPopupPriorityReady:r,clearReadyListOnRouteChange:s}=(0,An._y)(),[l,c]=(0,_.useState)(!1);o.show_promote||l||(r(1),c(!0)),(0,On.Du)(!1);const{handlePopupHide:d,handlePopupShow:u}=(0,Ze.H)();(0,_.useEffect)((()=>{a.current?a.current=!1:s()}),[s,i]),(0,Sa.AR)(n);const p=(0,Aa.nr)(),{shouldResetResolution:v,allowSelectResolution:m,useStoredResolution:g}=(0,Ee.lZ)();let h;try{h="undefined"!=typeof window?localStorage.getItem("resolution_auto"):void 0}catch(e){h=void 0}if(v&&h){try{localStorage.removeItem("resolution")}catch(e){}p.setDefaultResolution("auto")}else g&&m&&p.setDefaultResolution(null!=h?h:"auto");return(0,q.FD)(q.FK,{children:[(0,q.Y)(te.mg,{children:(0,q.Y)("link",{rel:"stylesheet",as:"style",href:Ea})}),(0,q.Y)(Pn.K,{}),(0,q.Y)(Ta,{}),!t&&(0,q.Y)(ka.H,{onShow:u,onHide:d})]})},Pa=({children:e})=>{const t=(0,ot.oY)(),{bodyContainerMaxWidth:n}=(0,lt.vV)(),{popupHeight:i}=(0,Ze.H)(),{isInAppNotificationEnabled:o}=(0,Ee.mf)(),{isFyfProfileUjEnabled:a}=(0,Ee.pC)(),{enableFYPSideNavPreloadAndCache:r}=(0,Ee.oJ)();return(0,q.FD)(_n,{children:[(0,q.Y)(it,{}),(0,q.Y)(Rt,{}),o&&(0,q.Y)(Bt,{}),(a||r)&&(0,q.Y)(st,{}),(0,q.Y)(Mt,{}),(0,q.FD)(gt,{isHideSideComponent:t,extraTop:i,maxWidth:n,children:[(0,q.Y)(Nt,{}),e]}),(0,q.Y)(Oa,{}),(0,q.Y)(Dt,{})]})};var Ia=n(141);const Ca=function(){return window.location.href=`/404?fromUrl=${encodeURIComponent(window.location.pathname)}`,null},La=(0,d.Ay)({resolved:{},chunkName:()=>"following",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(3307),n.e(6521),n.e(1603),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(2423),n.e(300),n.e(4730),n.e(1018),n.e(4856)]).then(n.bind(n,11777)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>11777}),ja=(0,d.Ay)({resolved:{},chunkName:()=>"friends",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(3307),n.e(6521),n.e(1603),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(2423),n.e(300),n.e(4730),n.e(1018),n.e(6814)]).then(n.bind(n,9694)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>9694}),Ma=(0,d.Ay)({resolved:{},chunkName:()=>"search",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(8258),n.e(187)]).then(n.bind(n,61908)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>61908}),Na=(0,d.Ay)({resolved:{},chunkName:()=>"user",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(2318),n.e(1618),n.e(7181),n.e(3392),n.e(241),n.e(4336),n.e(1427),n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(6244),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5021),n.e(3446),n.e(3290),n.e(8474),n.e(3557),n.e(8177),n.e(1274),n.e(9937),n.e(2618),n.e(2142),n.e(1683),n.e(6514),n.e(5308),n.e(8605),n.e(2486),n.e(1605),n.e(4875),n.e(1493),n.e(3593),n.e(9920),n.e(5201),n.e(4978),n.e(8987),n.e(9655),n.e(2128),n.e(5921),n.e(9624),n.e(1924),n.e(825),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(300),n.e(3765),n.e(8258),n.e(7899),n.e(69),n.e(4402),n.e(6806)]).then(n.bind(n,41213)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>41213}),Da=(0,d.Ay)({resolved:{},chunkName:()=>"challenge",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(300),n.e(3765),n.e(8258),n.e(8410)]).then(n.bind(n,95986)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>95986}),Ra=(0,d.Ay)({resolved:{},chunkName:()=>"kep",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(2141),n.e(3328),n.e(4343),n.e(5555),n.e(5833),n.e(865),n.e(8629),n.e(8581)]).then(n.bind(n,21233)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>21233}),Ba=(0,d.Ay)({resolved:{},chunkName:()=>"detail",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(9127),n.e(8345),n.e(5890),n.e(7679),n.e(1211),n.e(2301),n.e(2110),n.e(9502),n.e(2014),n.e(3206),n.e(6145),n.e(3328),n.e(5555),n.e(865),n.e(4332)]).then(n.bind(n,74552)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>74552}),Ua=(0,d.Ay)({resolved:{},chunkName:()=>"video",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(9127),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(3307),n.e(6521),n.e(1603),n.e(5890),n.e(1211),n.e(2301),n.e(2110),n.e(9502),n.e(2014),n.e(9757),n.e(499),n.e(5853),n.e(2375),n.e(4488),n.e(3206),n.e(9204),n.e(6145),n.e(3654),n.e(5425),n.e(3328),n.e(4343),n.e(2423),n.e(300),n.e(4730),n.e(1018),n.e(6180)]).then(n.bind(n,71842)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>71842}),Fa=(0,d.Ay)({resolved:{},chunkName:()=>"playlist",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(300),n.e(3765),n.e(8033)]).then(n.bind(n,5065)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>5065}),Va=(0,d.Ay)({resolved:{},chunkName:()=>"music",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(300),n.e(3765),n.e(8258),n.e(5692)]).then(n.bind(n,21363)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>21363}),za=(0,d.Ay)({resolved:{},chunkName:()=>"effect",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5080),n.e(7912),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(300),n.e(3765),n.e(8258),n.e(5244)]).then(n.bind(n,95828)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>95828}),Ha=(0,ht.Ay)({resolved:{},chunkName:()=>"foryou.islands",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(5021),n.e(3307),n.e(6521),n.e(1603),n.e(2710),n.e(4534),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(2423),n.e(4730),n.e(1018),n.e(7733)]).then(n.bind(n,74030)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>74030},{}),qa=(0,d.Ay)({resolved:{},chunkName:()=>"topics",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(3307),n.e(6521),n.e(1603),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(2423),n.e(4730),n.e(1018),n.e(1263)]).then(n.bind(n,51525)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>51525},{resolveComponent:e=>e.Topics}),Ga=(0,d.Ay)({resolved:{},chunkName:()=>"question",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(300),n.e(3765),n.e(8258),n.e(1621)]).then(n.bind(n,33776)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>33776}),$a=(0,d.Ay)({resolved:{},chunkName:()=>"messages",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(4563),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(2365),n.e(5871)]).then(n.bind(n,71893)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>71893}),Wa=(0,d.Ay)({resolved:{},chunkName:()=>"discover",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(8842)]).then(n.bind(n,80212)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>80212}),Za=(0,d.Ay)({resolved:{},chunkName:()=>"channel",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(2141),n.e(3328),n.e(4343),n.e(5555),n.e(5833),n.e(8188)]).then(n.bind(n,9737)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>9737}),Ya=(0,d.Ay)({resolved:{},chunkName:()=>"find",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(2141),n.e(3328),n.e(4343),n.e(5555),n.e(5833),n.e(865),n.e(8629),n.e(446)]).then(n.bind(n,86473)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>86473}),Ka=(0,d.Ay)({resolved:{},chunkName:()=>"setting",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(7716),n.e(5198),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(8345),n.e(5021),n.e(2710),n.e(4534),n.e(8704),n.e(2297),n.e(8063),n.e(1028),n.e(9659),n.e(7569),n.e(8068),n.e(2513),n.e(4186),n.e(4394),n.e(8478),n.e(4555),n.e(3840),n.e(5890),n.e(1211),n.e(2301),n.e(2110),n.e(4096),n.e(2189),n.e(9889),n.e(417)]).then(n.bind(n,78149)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>78149}),Xa=(0,d.Ay)({resolved:{},chunkName:()=>"upload",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(1799),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(8764),n.e(6455),n.e(5890),n.e(1211),n.e(2301),n.e(2110),n.e(8116),n.e(1188)]).then(n.bind(n,68013)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>68013}),Qa=(0,d.Ay)({resolved:{},chunkName:()=>"faq",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(1799),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(5890),n.e(1211),n.e(2301),n.e(2110),n.e(6389),n.e(2877),n.e(6609)]).then(n.bind(n,22070)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>22070}),Ja=(0,d.Ay)({resolved:{},chunkName:()=>"report",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(1799),n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(9127),n.e(170),n.e(5890),n.e(1211),n.e(2301),n.e(2110),n.e(6389),n.e(2877),n.e(3857)]).then(n.bind(n,17287)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>17287}),er=(0,d.Ay)({resolved:{},chunkName:()=>"poi",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(3765),n.e(8161)]).then(n.bind(n,25577)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>25577}),tr=(0,d.Ay)({resolved:{},chunkName:()=>"poi-category",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(2141),n.e(3328),n.e(4343),n.e(5555),n.e(5833),n.e(130),n.e(7870)]).then(n.bind(n,51500)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>51500}),nr=(0,d.Ay)({resolved:{},chunkName:()=>"travel",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(3765),n.e(5611)]).then(n.bind(n,5703)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>5703}),ir=(0,d.Ay)({resolved:{},chunkName:()=>"collection",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(300),n.e(3765),n.e(1171)]).then(n.bind(n,29173)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>29173}),or=(0,d.Ay)({resolved:{},chunkName:()=>"explore",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(7716),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(8345),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(7243),n.e(9058),n.e(2141),n.e(4623),n.e(3328),n.e(6592),n.e(4343),n.e(2423),n.e(300),n.e(3765),n.e(8258),n.e(9604)]).then(n.bind(n,4040)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>4040}),ar=(0,d.Ay)({resolved:{},chunkName:()=>"video-playlist",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(9443),n.e(1799),n.e(8564),n.e(5956),n.e(2402),n.e(895),n.e(5817),n.e(8873),n.e(3305),n.e(5850),n.e(8785),n.e(5934),n.e(4353),n.e(9127),n.e(4434),n.e(1735),n.e(2396),n.e(2924),n.e(5877),n.e(8014),n.e(4161),n.e(8871),n.e(3895),n.e(7485),n.e(5985),n.e(272),n.e(9302),n.e(744),n.e(35),n.e(415),n.e(9017),n.e(5979),n.e(5201),n.e(4978),n.e(8987),n.e(9655),n.e(2128),n.e(5921),n.e(9624),n.e(5890),n.e(7679),n.e(1211),n.e(6029),n.e(2301),n.e(7284),n.e(2110),n.e(2287),n.e(9502),n.e(9506),n.e(2014),n.e(9757),n.e(499),n.e(7859),n.e(5853),n.e(9636),n.e(2375),n.e(4488),n.e(3206),n.e(6751),n.e(9204),n.e(5245),n.e(5114),n.e(6145),n.e(2380),n.e(3654),n.e(9828),n.e(4573),n.e(47),n.e(5425),n.e(6157),n.e(7985),n.e(9058),n.e(4623),n.e(6592),n.e(300),n.e(3765),n.e(69),n.e(3519)]).then(n.bind(n,88942)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>88942}),rr=(0,d.Ay)({resolved:{},chunkName:()=>"download",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>Promise.all([n.e(8873),n.e(3305),n.e(5850),n.e(4353),n.e(415),n.e(9017),n.e(5979),n.e(862),n.e(1059),n.e(6713),n.e(8990),n.e(7454),n.e(5890),n.e(1211),n.e(2301),n.e(2110),n.e(5467)]).then(n.bind(n,26539)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>26539}),sr=(0,d.Ay)({resolved:{},chunkName:()=>"oauth-spotify",isReady(e){const t=this.resolve(e);return!0===this.resolved[t]&&!n.m[t]},importAsync:()=>n.e(8361).then(n.bind(n,37014)),requireAsync(e){const t=this.resolve(e);return this.resolved[t]=!1,this.importAsync(e).then((e=>(this.resolved[t]=!0,e)))},requireSync(e){const t=this.resolve(e);return n(t)},resolve:()=>37014});function lr({location:e}){const t=(0,_.useMemo)((()=>({pathname:e.pathname.replace(/\/\/+/g,"/"),search:e.search})),[e.pathname,e.search]);return(0,q.Y)(ct.rd,{to:t})}const cr=()=>(0,q.FD)(ct.dO,{children:[(0,q.Y)(ct.qh,{path:"(.*//+.*)",exact:!0,strict:!0,component:lr}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.following,component:La}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.friends,component:ja}),(0,q.Y)(ct.qh,{path:qe.OZ.searchHome,component:Ma}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.user,component:Na}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.challenge,component:Da}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.expansion,component:Ra}),(0,q.Y)(ct.qh,{exact:!0,path:[qe.OZ.trendingDetail,qe.OZ.trendingDetailWithinDiscover],component:Ba}),(0,q.Y)(ct.qh,{exact:!0,path:[qe.OZ.video,qe.OZ.photo],component:Ua}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.musicPlaylist,component:Fa}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.music,component:Va}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.effect,component:za}),(0,q.Y)(ct.qh,{exact:!0,path:Ia.qk,component:Ha}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.topics,component:qa}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.question,component:Ga}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.messages,component:$a}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.discover,component:Wa}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.channel,component:Za}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.find,component:Ya}),(0,q.Y)(ct.qh,{path:qe.OZ.setting,component:Ka}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.upload,component:Xa}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.feedbackReport,component:Ja}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.feedbackHistory,component:Ja}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.feedback,component:Qa}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.poi,component:er}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.travelCategory,component:tr}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.travel,component:nr}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.collection,component:ir}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.explore,component:or}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.videoPlaylist,component:ar}),(0,q.Y)(ct.qh,{exact:!0,path:[qe.OZ.download,...qe.OZ.downloadWithLang],component:rr}),(0,q.Y)(ct.qh,{exact:!0,path:qe.OZ.oauthSpotify,component:sr}),(0,q.Y)(ct.qh,{path:"*",component:Ca})]});function dr(){window.location.reload()}const ur=()=>{var e;const t=(0,We.W)((()=>["user"]),[]),{t:n}=(0,_.useContext)(C.Ss);return(null===(e=null==t?void 0:t.user)||void 0===e?void 0:e.ftcUser)?(0,q.Y)(V.a,{theme:ee.pz,children:(0,q.Y)(se.W,{isFullScreen:!0,onButtonClick:dr,iconElem:(0,q.Y)(re.A,{width:90,height:90,fill:"rgba(128, 130, 133, 1)"}),title:n("Page not available"),desc:n("server_error_sub"),buttonText:n("try_again_btn")})}):(0,q.Y)(Pa,{children:(0,q.Y)(cr,{})})},pr=$()(Object.values(qe.OZ)),vr=new Z,mr=[qe.eU.find,qe.eU.expansion,qe.eU.channel],gr=[qe.OZ.find,qe.OZ.channel,qe.OZ.expansion],hr=[qe.eU.download,qe.eU.downloadWithLang],_r=[qe.OZ.download,...qe.OZ.downloadWithLang],fr=pr.filter((e=>!gr.includes(e)));var yr=n(94337),br=n(31780),wr=n(64590),xr=n(7789),Tr=n(34099),kr=n(14974),Sr=n.n(kr);const Er="__$UNIVERSAL_DATA$__";const Ar={video:"video_detail",photo:"graphic_detail",user:"others_homepage",music:"single_song",effect:"effect_detail",challenge:"challenge",home:"homepage_hot",foryou:"homepage_hot",foryouWithLang:"homepage_hot",following:"homepage_follow",friends:"friends_page",topics:"topic",expansion:"discover_kw",searchHome:"general_search",searchUser:"search_user",searchVideo:"search_video",discover:"discovery",setting:"setting",settingBlockList:"setting",settingDownLoadYourData:"setting",settingKeywordFiltering:"setting",settingAdPrivacyPersonalizedAds:"setting",settingAdPrivacyPersonalizedAdsInferredByTikTokTopics:"setting",settingAdPrivacyPersonalizedAdsYourChoicesTopics:"setting",settingAdPrivacyPersonalizedAdsAllTopics:"setting",settingAdvertiserSettings:"setting",settingDisconnectAdvertisers:"setting",settingDisconnectAdvertisersDetails:"setting",feedback:"feedback",feedbackHistory:"feedback_history",feedbackReport:"feedback_report",find:"find",question:"qa_detail",musicPlaylist:"music_playlist",poi:"place",poiCategory:"place",travel:"place",travelCategory:"place",collection:"collection",messages:"messages",channel:"channel",profile:"personal_homepage",inbox:"homepage_message",explore:"explore_page",videoPlaylist:"playlist",searchReminder:"search_reminder",searchLive:"search_live",upload:"upload",settingDailyScreenTimeEdit:"setting",settingTimeBreakEdit:"setting",settingSleepReminderEdit:"setting",download:"download",downloadWithLang:"download",trendingDetail:"discover_pro",trendingDetailWithinDiscover:"discover_pro",oauthSpotify:"oauth_spotify"};var Or=n(97487),Pr=n(62302),Ir=n(10598),Cr=n(68881),Lr=n(38838),jr=n(97895),Mr=n(13326),Nr=n.n(Mr),Dr=n(16469),Rr=n(87715),Br=n(47888),Ur=n(14576),Fr=n(99374),Vr=n(44349),zr=n(29909),Hr=n(89049),qr=n(5109),Gr=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const $r=3;function Wr(e,t){return Gr(this,void 0,void 0,(function*(){if(Dr.lL.getItem("itemList"))return;const n=(0,I.qm)(),i=u.l.getInstance(Ur.j),[{videoCoverSettings:o},{abTestVersion:a}]=yield Promise.all([(0,Ir.x)(),(0,Pr.zI)(n)]),r=(0,Fr.mx)(a,e);i.getFeedCacheList({count:$r,language:n,coverFormat:null==o?void 0:o.format,isNonPersonalized:r,vv_count_fyp:parseInt((0,Ne._S)(Hr.Bu,"0"),10)||0,vv_count:parseInt((0,Ne._S)(Hr.$H,"0"),10)||0,cpu_core_number:"undefined"!=typeof navigator&&navigator.hardwareConcurrency?navigator.hardwareConcurrency:0,dark_mode:"dark"===(0,Le.MJ)(fe.n9)&&"1"===(0,Le.MJ)(fe.HF),time_of_day:(new Date).getHours(),day_of_week:(new Date).getDay(),clientABVersions:null==a?void 0:a.versionName}).subscribe({next({statusCode:n,itemList:i=[],log_pb:o}){var a;if(0===n){const n=null===(a=i.slice)||void 0===a?void 0:a.call(i,0,$r);Dr.lL.setItem("itemList",n),Dr.lL.setItem("log_pb",o),function(e,t){Dr.lL.setItem("cacheUid",e),Dr.lL.setItem("cacheWid",t);const n=(0,qe.kv)(window.location.pathname);Dr.lL.setItem("pageName",null==n?void 0:n.name)}(e,t),function(e){try{Nr().remove(Vr.n2,{domain:"www.tiktok.com"});const t=JSON.stringify({expireTimestamp:(0,Rr._1)(e),itemIds:e.map((e=>e.id))});Nr().set(Vr.n2,t,{secure:!0,expires:5,domain:"www.tiktok.com"})}catch(e){console.warn(`[Cookie] Set Feed Cache Cookie Error: ${e}`)}}(n)}else(0,Br.dG)(n);(0,Br.bA)(n)},error(){(0,Br.dG)(10111),(0,Br.bA)(10111)}})}))}function Zr(){return e=this,t=void 0,i=function*(){if(function(){const e=document.querySelector("#app");return"1"===(null==e?void 0:e.dataset.csr)}()){const e=(0,I.qm)(),{user:t,wid:n}=yield(0,Pr.zI)(e);try{(function(){const e=(0,qe.kv)(window.location.pathname);return["foryou","foryouWithLang","home"].includes(null==e?void 0:e.name)})()&&function({user:e,wid:t}){const{cacheUid:n,cacheWid:i,itemList:o,pageName:a="unknown",log_pb:r}=Dr.lL.getStorage();Dr.lL.removeAll();const{status:s,validItemList:l}=(0,Rr.Mc)({itemList:o,cacheUid:n,cacheWid:i,wid:t,uid:null==e?void 0:e.uid});[0,4,8].includes(s)&&function(e,t){var n,i,o,a,r,s;(0,zr.HG)().setListFromCache({itemList:e,statusCode:0,log_pb:t}),function(e){if(e){const t=document.createElement("link");t.rel="prefetch",t.href=e,document.head.appendChild(t)}}(null!==(o=null===(i=null===(n=e[0])||void 0===n?void 0:n.video)||void 0===i?void 0:i.originCover)&&void 0!==o?o:null===(s=null===(r=null===(a=e[0])||void 0===a?void 0:a.video)||void 0===r?void 0:r.zoomCover)||void 0===s?void 0:s[720])}(l,r),0===s&&function(e){const t=(0,zr.HG)();u.l.getInstance(Ur.j).checkItemValidation({itemIds:e.map((e=>e.id)).join(",")}).subscribe({next({statusCode:n,availabities:i=[]}){if(0===n){let n=0;i.forEach((({id:e,available:i})=>{i||(n++,t.setDeleteVideo(e))})),0!==n&&(0,Br.Ao)(e.length,n)}},error(e){console.error("Error Occur when deleting invalid video",e)}})}(l),3===s&&function(e=[]){var t,n,i,o,a,r,s;Gr(this,void 0,void 0,(function*(){const l=null===(t=e[0])||void 0===t?void 0:t.id;if(!l)return;const c=(0,I.qm)(),[d,u]=yield Promise.all([(0,Ir.x)(),(0,Pr.zI)()]),p=(0,zr.HG)(),v=(null===(n=u.abTestVersion)||void 0===n?void 0:n.versionName)?null===(o=null===(i=u.abTestVersion)||void 0===i?void 0:i.versionName)||void 0===o?void 0:o.split(","):[];try{const e=null!==(r=yield(0,qr.d)({itemId:l,language:c,coverFormat:null===(a=d.videoCoverSettings)||void 0===a?void 0:a.format,clientABVersions:v}))&&void 0!==r?r:{statusCode:-1},t=e.statusCode,n=null===(s=e.itemInfo)||void 0===s?void 0:s.itemStruct;0===t&&n&&p.setListFromCache({itemList:[n],statusCode:0})}catch(e){console.error("Error Occur when updating item detail",e)}}))}(o),(0,Br.Pv)(s,a)}({user:t,wid:n}),function(e,t){setTimeout((()=>{"requestIdleCallback"in window?window.requestIdleCallback((()=>Wr(e,t))):Wr(e,t)}),3e3)}(null==t?void 0:t.uid,n)}catch(e){console.warn("[Error]feed cache logic error:",e)}}},new((n=void 0)||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}));var e,t,n,i}var Yr,Kr=n(67353),Xr=n(46311),Qr=n(27871),Jr=n(4685);!function(e){e.RequestDeviceScoreTime="request_device_score_time",e.RequestDeviceScoreError="request_device_score_error"}(Yr||(Yr={}));const es=e=>{ke.f.sendEvent("request_device_score_time",e)},ts=e=>{ke.f.sendEvent("request_device_score_error",e)};var ns=n(24220),is=n(90118);const os={video:"video_detail",photo:"graphic_detail",user:"others_homepage",music:"single_song",effect:"effect_detail",challenge:"challenge",home:"homepage_hot",foryou:"homepage_hot",foryouWithLang:"homepage_hot",following:"homepage_follow",friends:"friends_page",topics:"topic",expansion:"discover_kw",searchHome:"general_search",searchUser:"search_user",searchVideo:"search_video",discover:"discovery",setting:"setting",settingBlockList:"setting",settingDownLoadYourData:"setting",settingKeywordFiltering:"setting",settingAdPrivacyPersonalizedAds:"setting",settingAdPrivacyPersonalizedAdsInferredByTikTokTopics:"setting",settingAdPrivacyPersonalizedAdsYourChoicesTopics:"setting",settingAdPrivacyPersonalizedAdsAllTopics:"setting",settingAdvertiserSettings:"setting",settingDisconnectAdvertisers:"setting",settingDisconnectAdvertisersDetails:"setting",feedback:"feedback",feedbackHistory:"feedback_history",feedbackReport:"feedback_report",find:"find",question:"qa_detail",musicPlaylist:"music_playlist",poi:"place",poiCategory:"place",travel:"place",travelCategory:"place",collection:"collection",messages:"messages",channel:"channel",profile:"personal_homepage",inbox:"homepage_message",explore:"explore_page",videoPlaylist:"playlist",searchReminder:"search_reminder",searchLive:"search_live",upload:"upload",settingDailyScreenTimeEdit:"setting",settingTimeBreakEdit:"setting",settingSleepReminderEdit:"setting",download:"download",downloadWithLang:"download",trendingDetail:"discover_pro",trendingDetailWithinDiscover:"discover_pro",oauthSpotify:"oauth_spotify"};new Map;var as=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const{startFn:rs,endFn:ss}=function(){let e,t;return{startFn(){e=(0,xr.V)()},endFn(){t=(0,xr.V)(),(0,i.OA)({duration:t-e})}}}(),ls=a(),cs=(0,j.YI)(ne.Ow);!function(e,t){const{beforeRender:n,afterRender:i}=t;let o;(()=>{return a=this,r=void 0,d=function*(){const a=yield U(t);o=a.slardarUtils;const{rootProps:r,jotaiStore:s}=a;yield null==n?void 0:n({jotaiStore:s,slardarUtils:o}),null==o||o.slardar.reportRenderStart();const d=document.querySelector("#app"),u="1"===(null==d?void 0:d.dataset.csr),p=(0,l.jsx)(H,Object.assign(Object.assign({},r),{csr:u,children:(0,l.jsx)(e,{})}));u?(0,c.render)(p,d):(0,c.hydrate)(p,d),null==o||o.slardar.reportRenderEnd(),yield null==i?void 0:i()},new((s=void 0)||(s=Promise))((function(e,t){function n(e){try{o(d.next(e))}catch(e){t(e)}}function i(e){try{o(d.throw(e))}catch(e){t(e)}}function o(t){var o;t.done?e(t.value):(o=t.value,o instanceof s?o:new s((function(e){e(o)}))).then(n,i)}o((d=d.apply(a,r||[])).next())}));var a,r,s,d})().catch((e=>{var t,n;console.error(e),null===(n=null===(t=null==o?void 0:o.slardar)||void 0===t?void 0:t.captureMessage)||void 0===n||n.call(t,e,"fatal",{fromLauncher:"1"})}))}((()=>{var e;const t=(0,He.fU)()?"/":window.location.pathname;let n=fr;const i=null===(e=(0,qe.jN)(t))||void 0===e?void 0:e.name;i&&mr.includes(i)&&(n=gr),i&&hr.includes(i)&&(n=_r);let r=ur;const s=a();if(s){const e=window.__registerSEOAddon__;e&&(r=e(r,{isFromGoogle:"google"===(0,o.q)(),isFromSearchEngine:s}))}return(0,q.Y)(Ge.QueryProvider,{apiConfigs:(0,$e.H$)(),children:(0,q.Y)(ze,{supportRoutes:n,children:(0,q.Y)(W.d,{context:vr,children:(0,q.Y)(r,{})})})})}),{appName:"desktop",beforeStart:()=>as(void 0,void 0,void 0,(function*(){var e;let t="v0";cs&&((0,Zt.D)(cs),t=null!==(e=(0,Ke.d)("page_loading_tiny_changes"))&&void 0!==e?e:"v0"),"v2"===t||"v4"===t?"requestIdleCallback"in window?window.requestIdleCallback((()=>{(0,r.t6)()})):(0,r.t6)():yield(0,r.t6)()})),nss:Qr.Y5,slardarOption:{bid:s.Gu,extractPid:lt.wI,disableToggleLoginSlardar:!0,ttapOption:{isSpa:!0,includeApiUrl:["/api/recommend/item_list/","/api/item/detail/","/api/following/item_list/","/api/user/detail/","/api/post/item_list/","/api/music/item_list/","/api/topic/item_list/","/node/report/inbox/list/","/node/report/inbox/detail/","/api/explore/item_list/"]}},beforeRender:({slardarUtils:e})=>as(void 0,void 0,void 0,(function*(){var t;rs(),function(){var e,t,n,i;const o=(0,Tr.V)(),a=(0,b.xq)(),r=function(e,t){var n,i,o,a;if(!window[Er]){let e={};try{e=JSON.parse(null!==(i=null===(n=document.getElementById("__UNIVERSAL_DATA_FOR_REHYDRATION__"))||void 0===n?void 0:n.textContent)&&void 0!==i?i:"{}")}catch(e){console.error("error while parsing rehydration data")}window[Er]=e}return null!==(a=null===(o=window[Er][null!=t?t:"__DEFAULT_SCOPE__"])||void 0===o?void 0:o[e])&&void 0!==a?a:null}("webapp.biz-context"),s=Sr()(null==r?void 0:r.solariaPortrait,(e=>Number(e))),{user:l,wid:c,region:d,odinId:u,webIdCreatedTime:p,language:v,abTestVersion:m}=a,g=(0,qe.kv)(window.location.pathname),h=null===(t=null===(e=null==m?void 0:m.parameters)||void 0===e?void 0:e.page_loading_tiny_changes)||void 0===t?void 0:t.vid,_="v3"===h||"v4"===h;ke.f.config({initConfig:{channel_domain:o.tea,ab_channel_domain:o.libraWebSDK,channel_type:null!==(n=o.teaChannelType)&&void 0!==n?n:"tcpy",channel:o.teaChannel,id:1988,reportTime:_?200:void 0,autotrack:{custom:"tea",text:!0,svg:!0}},commonHeaderConfig:{region:d,user_id:null!==(i=null==l?void 0:l.uid)&&void 0!==i?i:u,user_is_login:Boolean(l),user_unique_id:c,device_id:c,user_type:12,"header.custom":Object.assign(Object.assign({session_id:ke.f.getSessionId(c),webid_created_time:p,app_language:v,page_name:g?Ar[g.name]:""},s),ke.f.initDimensionalData)}}),wr.l.init({sender:(e,t)=>{ke.f.event(e,t,!1)},device:"pc",pageName:g?Ar[g.name]:""})}(),(0,i.jT)(),yield function(){var e,t,n,i,o,a,r,s,l,c,d,p,v,m,g,h,_,f;return g=this,h=void 0,f=function*(){const g=(0,qe.CA)(window.location.pathname),h=null==g?void 0:g.name,_=u.l.getInstance(y.V$);if(h===qe.eU.user){const r=(0,I.qm)(),[s,l]=yield Promise.all([(0,Pr.zI)(r),(0,Ir.x)(r)]),c=new URLSearchParams(location.search);if("v2"===(null===(n=null===(t=null===(e=null==s?void 0:s.abTestVersion)||void 0===e?void 0:e.parameters)||void 0===t?void 0:t.foryou_prefetch)||void 0===n?void 0:n.vid)||"v2"===c.get("foryou_prefetch"))return;const d=(0,j.YI)(Or.gA.userDetail);if(d){const{secUid:e=""}=null!==(o=null===(i=d.userInfo)||void 0===i?void 0:i.user)&&void 0!==o?o:{};(0,Cr.dz)(e),(0,Cr.bg)(e,null===(a=l.videoCoverSettings)||void 0===a?void 0:a.format)}}if(h===qe.eU.poi){const{id:e}=null!==(r=null==g?void 0:g.matchedParams)&&void 0!==r?r:{id:""};if(e){const t=yield(0,Ir.x)((0,I.qm)());(0,Cr.hX)(e,t.isBot?121:120)}}if(h===qe.eU.travel){const{id:e}=null!==(s=null==g?void 0:g.matchedParams)&&void 0!==s?s:{id:""};if(e){const t=Object.values(Lr.Wk).slice(0,3).map((e=>e.idlType)),n=(0,I.qm)(),[i,o,a]=yield Promise.all([(0,Pr.zI)(n),(0,Ir.x)(n),(0,jr.e)()]),r={appId:i.appId,region:i.region,coverFormat:null===(l=o.videoCoverSettings)||void 0===l?void 0:l.format,clientAbVersionIds:a};(0,Cr.UM)({poiId:e},r,t)}}if(h===qe.eU.travelCategory){const{id:e,category:t}=null!==(c=null==g?void 0:g.matchedParams)&&void 0!==c?c:{id:"",category:""};if(e&&t){const n=(0,Lr.xG)(t).idlType,i=Array(3).fill(null).map(((e,n)=>Lr.Wk[t].subTitles[n].idlType)),o=(0,I.qm)(),[a,r,s]=yield Promise.all([(0,Pr.zI)(o),(0,Ir.x)(o),(0,jr.e)()]),l={appId:a.appId,region:a.region,coverFormat:null===(d=r.videoCoverSettings)||void 0===d?void 0:d.format,clientAbVersionIds:s};(0,Cr.UM)({poiId:e,subCategoryType:n},l,i)}}if(h===qe.eU.video){const e=(0,j.YI)(Or.gA.videoDetail);if(_.emitEvent("prefetch_data",{video_detail:1},{}),e){const t=null===(m=null===(v=null===(p=null==e?void 0:e.itemInfo)||void 0===p?void 0:p.itemStruct)||void 0===v?void 0:v.video)||void 0===m?void 0:m.originCover;if(_.emitEvent("prefetch_data",{video_detail:1},{status:"success"}),t){const e=Date.now(),n=new Image;n.src=t,n.onload=()=>{_.reportCustomRequest({name:"prefetch_image",startTime:e,endTime:Date.now()})}}}}},new((_=void 0)||(_=Promise))((function(e,t){function n(e){try{o(f.next(e))}catch(e){t(e)}}function i(e){try{o(f.throw(e))}catch(e){t(e)}}function o(t){var o;t.done?e(t.value):(o=t.value,o instanceof _?o:new _((function(e){e(o)}))).then(n,i)}o((f=f.apply(g,h||[])).next())}))}(),Object.keys(Or.gA).forEach((e=>(0,Or.iq)(e))),(0,i.AW)(),(0,i.LY)(),(()=>{try{const e=(0,qe.kv)(window.location.pathname);(()=>{try{const t=performance.now();try{const e=new ns.r({decodeImgUrl:""}).scoreSync({ignoreCachedImg:!0}).performance;if(e&&"object"==typeof e&&"score"in e){let t=e.score;"number"==typeof t&&(t=parseFloat(t.toFixed(2)),(0,Jr.lu)().updateHardwareScore(t),ke.f.config({commonHeaderConfig:{"header.custom":{hardware_score:t}}}))}}catch(t){ts({type:"hardware",page_name:e?os[e.name]:""})}const n=performance.now();es({duration:Math.ceil(n-t),type:"hardware",page_name:e?os[e.name]:""});const i=performance.now();try{const{score:e}=(0,is.rr)();if("number"==typeof e){const t=parseFloat(e.toFixed(2));(0,Jr.lu)().updateTotalDeviceScore(e),ke.f.config({commonHeaderConfig:{"header.custom":{total_score:t}}})}}catch(t){ts({type:"total",page_name:e?os[e.name]:""})}const o=performance.now();es({duration:Math.ceil(o-i),type:"total",page_name:e?os[e.name]:""})}catch(e){console.error("Error in retrieveScore:",e)}})()}catch(e){console.error("Error in setDeviceScore",e)}})(),yield Zr(),yield function(){var e,t,n,i,o;return t=this,n=void 0,o=function*(){let t="";const n=(0,b.xq)();n&&(t=n.region);const i=yield(0,Ir.x)((0,I.qm)());(0,Kr.hd)("webapp-desktop",null!==(e=i.isTTP)&&void 0!==e?e:"US"===t)},new((i=void 0)||(i=Promise))((function(e,a){function r(e){try{l(o.next(e))}catch(e){a(e)}}function s(e){try{l(o.throw(e))}catch(e){a(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof i?n:new i((function(e){e(n)}))).then(r,s)}l((o=o.apply(t,n||[])).next())}))}(),yr.Mh.inject(),ls&&(window.__registerSEOAddon__=(yield Promise.all([n.e(4563,"high"),n.e(8345,"high"),n.e(7581,"high")]).then(n.bind(n,44353))).registerSEOAddon),(null===(t=null==e?void 0:e.slardar)||void 0===t?void 0:t._slardar)&&br.Wk.init({slardarContainer:e.slardar._slardar,shouldReportJSError:{pageCrash:!0,cuj:!0}})})),afterRender:()=>{ss(),function(){const e=u.l.getInstance(y.V$);Xr.P.on("consume_prefetch_data",((t,n,i)=>{e.emitEvent("consume_prefetch_data",{now:t},{status:n,from:i})})),Xr.P.on("consume_prefetch_data_error",((t,n)=>{e.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"fail",from:n})}))}()}})},70281:(e,t,n)=>{"use strict";n.d(t,{$:()=>c});var i=n(72153),o=n(11060),a=n(82715),r=n(71281),s=n(97086),l=n(35267);const c=()=>{var e;try{const t="v0"!==(null!==(e=(0,r.d)("nav_phase_3"))&&void 0!==e?e:"v0"),n="v1"===(0,r.d)("enable_dm_side_nav"),c=(0,s.fU)()?(0,l.yK)().request.path:window.location.pathname;return(0,o.B6)(c,{path:[a.OZ.setting,a.OZ.settingBlockList,a.OZ.feedback,a.OZ.feedbackReport,a.OZ.feedbackHistory,a.OZ.upload,...n?[]:[a.OZ.messages]],exact:!0})?i.uF:t?0:i.uF}catch(e){return i.uF}}},81659:(e,t,n)=>{"use strict";n.d(t,{xG:()=>C,wI:()=>N,xS:()=>R,zd:()=>j,cf:()=>D,vV:()=>L,YB:()=>B,nI:()=>U,G4:()=>F});var i=n(40099),o=n(11060),a=n(72241),r=n(46682),s=n(82715),l=n(88920),c=n(60484),d=n(49057),u=n(48615),p=n(71281),v=n(71777),m=n(66994),g=n(71111),h=n(31209);const _={windowHeight:"undefined"!=typeof window?window.innerHeight:0,windowWidth:"undefined"!=typeof window?window.innerWidth:0},f=(0,g.atom)(_);f.debugLabel="windowAtom";const{useServiceState:y,useServiceDispatchers:b,useAtomService:w,getStaticApi:x}=(0,h.i)(f,((e,t)=>({updateWindowSize(){t(f,(e=>Object.assign(Object.assign({},e),{windowHeight:window.innerHeight,windowWidth:window.innerWidth})))}})));var T=n(18222),k=n(93608),S=n(43201),E=n(2387),A=n.n(E),O=n(33543),P=n(99661),I=n(93341);const C=240,L=()=>{const{isInNavPhase3:e}=(0,l.Oj)(),{isFeedbackPage:t}=(0,m.YH)(),n=!t,i=e?16*Number.parseFloat(O.pJ):C;return{sideNavWidth:n?i:void 0,bodyContainerMaxWidth:n?"100%":void 0}},j=e=>{const{value:t}=(0,i.useContext)(a.xm);return(0,a.O4)({isDark:t,lang:e}).colors.Negative},M={video:"video_detail",photo:"graphic_detail",user:["others_homepage","personal_homepage"],music:"single_song",effect:"effect_detail",challenge:"challenge",channel:"channel",find:"find",home:"homepage_hot",foryouWithLang:"homepage_hot",foryou:"homepage_hot",following:"homepage_follow",friends:"friends_page",topics:["topic"],expansion:"discover_kw",searchHome:"general_search",searchUser:"search_user",searchVideo:"search_video",searchLive:"search_live",searchReminder:"general_search",discover:"discovery",setting:"setting",feedback:"feedback",feedbackHistory:"feedback_history",feedbackReport:"feedback_report",upload:"upload",question:"qa_detail",musicPlaylist:"music_playlist",messages:"messages",settingBlockList:"setting",settingDownLoadYourData:"setting",settingKeywordFiltering:"setting",settingDailyScreenTimeEdit:"setting",settingTimeBreakEdit:"setting",settingSleepReminderEdit:"setting",settingAdPrivacyPersonalizedAds:"setting",settingAdPrivacyPersonalizedAdsInferredByTikTokTopics:"setting",settingAdPrivacyPersonalizedAdsYourChoicesTopics:"setting",settingAdPrivacyPersonalizedAdsAllTopics:"setting",settingAdvertiserSettings:"setting",settingDisconnectAdvertisers:"setting",settingDisconnectAdvertisersDetails:"setting",profile:"personal_homepage",inbox:"homepage_message",explore:"explore_page",videoPlaylist:"playlist",poi:"place",poiCategory:"place",travel:"place",travelCategory:"place_category",collection:"collection",download:"download",downloadWithLang:"download",trendingDetail:"discover_pro",trendingDetailWithinDiscover:"discover_pro",oauthSpotify:"oauth_spotify"},N=(e,t)=>{var n;const i=(0,s.kv)(e),o=t?t.user:null===(n=(0,P.xq)())||void 0===n?void 0:n.user;if(i){const t=M[i.name];if(!Array.isArray(t))return t;if("user"===i.name){const n=null==e?void 0:e.slice(2),i=null==n?void 0:n.toLowerCase();return o&&(Boolean(i&&(null==i?void 0:i.match(o.uniqueId)))||Boolean(n&&(null==n?void 0:n.match(o.secUid))))?t[1]:t[0]}if("topics"===i.name){const n=null==e?void 0:e.slice(8);return`${t[0]}_${n}`.toLowerCase()}return"unknown"}return"unknown"},D=()=>{const e=(0,i.useRef)(null),{pathname:t}=(0,o.zy)(),{user:n}=(0,c.L$)((0,d.W)((()=>["user"]),[]));if(e.current)return e.current;const a=N(t,{user:n});return e.current=a,a},R=()=>{const{user:e}=(0,c.L$)((0,d.W)((()=>["user"]),[])),[{privacyAccountPromptConfig:t},n]=(0,r.S)(T.J),{variant:o,selectPrivateByDefault:a}=t;return(0,i.useEffect)((()=>{Boolean(e)&&n.getComplianceSetting({user:e})}),[n,e]),{privacyAccountPromptVariant:o,selectPrivateByDefault:a}},B=()=>{var e,t;const{user:n}=(0,c.L$)((0,d.W)((()=>["user"]),[])),{bizContext:o}=(0,u.y)(),{abTestVersion:a}=null!==(e=(0,d.W)((()=>["abTestVersion"]),[]))&&void 0!==e?e:{},r=null!==(t=(0,p.qt)(a,"webapp_switch_account"))&&void 0!==t?t:"v1";(0,i.useEffect)((()=>{var e,t;const i=JSON.parse(null!==(e=localStorage.getItem("multi-account-info"))&&void 0!==e?e:'{"data":[]}').data;n&&"v1"!==r&&n.hasIMPermission&&localStorage.setItem("multi-account-info",JSON.stringify({data:[...i.filter((e=>e.secUid!==n.secUid)),{secUid:n.secUid,uniqueId:n.uniqueId,nickName:n.nickName,avatarUrl:n.avatarUri[0],lastActiveTime:Date.now(),userRegion:null!==(t=null==o?void 0:o.idc)&&void 0!==t?t:""}].sort(((e,t)=>e.lastActiveTimet.lastActiveTime?-1:0))}))}),[null==o?void 0:o.idc,r,n])};function U(){const e=(0,i.useCallback)((()=>{k.f.event("enter_picture_in_picture")}),[]);(0,i.useEffect)((()=>(window.addEventListener("enterpictureinpicture",e),()=>{window.removeEventListener("enterpictureinpicture",e)})),[e])}const F=()=>{const e=(0,I.RT)(),[{windowHeight:t,windowWidth:n},o]=w(),a=(0,v.Dy)(),r=(0,i.useCallback)(A()((()=>{(0,S.T)({windowObj:window,playMode:e,width_before:n,height_before:t}),o.updateWindowSize()}),1e3),[t,n,e,o,a]);(0,i.useEffect)((()=>(window.addEventListener("resize",r),()=>{window.removeEventListener("resize",r)})),[r])}},12731:(e,t,n)=>{"use strict";n.d(t,{Hj:()=>c,V$:()=>r,Ws:()=>l,is:()=>s});var i=n(62186),o=n(72153),a=n(17784);const r=(0,i.default)("div",{target:"e8agtid0"})({},"label:DivSideNavContainer;"),s=(0,i.default)("div",{target:"e8agtid1"})((({status:e,theme:{colors:t}})=>(0,o.jJ)({max:767,style:[{position:"fixed",inset:o.uF-1+"px 0 0",zIndex:99,backgroundColor:t.ConstBGInverse2,opacity:e===a.ns||e===a._K?1:0},e===a.ns||e===a.ze?{transition:"all 0.3s"}:null,e===a.kp?{pointerEvents:"none"}:null]})),"label:DivSideNavMask;"),l=(0,i.default)("div",{target:"e8agtid2"})({position:"relative",height:"100%",width:240,flex:"0 0 240px",display:"flex",flexDirection:"column","@media screen and (max-width: 1071px)":{width:72,flex:"0 0 72px"},padding:"16px",maxHeight:`calc(100vh - ${o.uF}px)`,overflow:"hidden"},"label:DivSkeletonSideNavContainer;"),c=(0,i.default)("div",{target:"e8agtid3"})((({theme:{colors:e}})=>({width:"100%",padding:"16px",background:e.BGPlaceholderDefault,borderRadius:"4px",height:32,margin:"16px 0 0 0",opacity:.8})),"label:SkeletonItem;")},63950:(e,t,n)=>{"use strict";n.d(t,{H6:()=>c,K6:()=>l,N$:()=>s});var i=n(75431),o=n(62186),a=n(72153),r=n(70281);const s=(0,o.default)("div",{target:"e1irlpdw0"})((({extraTop:e=0,maxWidth:t,isHideSideComponent:n,width:i,theme:{colors:o},backgroundColor:s=o.BGPrimary})=>({marginTop:n?0:(0,r.$)()+e,display:"flex",width:null!=i?i:"100vw",maxWidth:null!=t?t:a.hj,justifyContent:"space-between",alignSelf:"center",flex:"1 1 auto",backgroundColor:s})),"label:DivBodyContainer;"),l=(0,o.default)("div",{target:"e1irlpdw1"})({".jotai-devtools-trigger-button":{position:"fixed",borderRadius:"50%",borderWidth:0,width:"4rem",height:"4rem"}},"label:DivJotaiDevtoolsWrapper;"),c=e=>i.AH` *[role='button'], *[role='link'], *[role='switch'], *[tabindex], button[aria-label], button[aria-labelledby], button[aria-pressed], button[aria-expanded], button[role='tab'], a[aria-label] { &:focus { outline: none; } &:focus-visible { outline: 2px solid ${e}; } } , *[role='button'], button[aria-label], button[aria-labelledby], button[aria-pressed], button[aria-expanded] { &:focus-visible { outline-offset: 1px; } } , li[role='option'] { &:focus-visible { outline-style: auto; } } `},60408:(e,t,n)=>{"use strict";n.d(t,{F:()=>p});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(23999),l=n(26324),c=n(35572),d=n(8536),u=n(25789);let p=class extends o.E{constructor(e){super(),this.service=e,this.defaultState={userSetting:{privateAccount:!1,adAuthorization:!1,proAccountStatus:0,pushSettings:void 0}}}setUserSetting(e,t){e.userSetting=t}setPrivateAccountStatus(e,t){e.userSetting.privateAccount=t}getUserSetting(e){return e.pipe((0,c.p)((()=>this.service.getUserSetting().pipe((0,d.Z)((({settings:e={}})=>{const{privateAccount:t=!1,adAuthorization:n=!1,proAccountStatus:i=0,pushSettings:o}=e;return(0,s.of)(this.getActions().setUserSetting({privateAccount:t,adAuthorization:n,proAccountStatus:i,pushSettings:o}))}))))))}};(0,i.__decorate)([(0,a.uk)(),(0,i.__metadata)("design:type",l.c)],p.prototype,"dispose$",void 0),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],p.prototype,"setUserSetting",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],p.prototype,"setPrivateAccountStatus",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[l.c]),(0,i.__metadata)("design:returntype",void 0)],p.prototype,"getUserSetting",null),p=(0,i.__decorate)([(0,r.n)("SettingModule"),(0,i.__metadata)("design:paramtypes",[u.q])],p)},25789:(e,t,n)=>{"use strict";n.d(t,{q:()=>r});var i=n(58632),o=n(7672),a=n(55099);let r=class{constructor(e){this.fetch=e}getUserSetting(){return this.fetch.get("/api/user/settings/",{query:{aid:"1988"},baseUrlType:2})}getShowChangeRegion(){return this.fetch.get("/tiktok/region/change/status/get/v1",{query:{},baseUrlType:2})}};r=(0,i.__decorate)([(0,o._)(),(0,i.__metadata)("design:paramtypes",[a.p])],r)},18222:(e,t,n)=>{"use strict";n.d(t,{J:()=>N});var i,o=n(58632),a=n(64162),r=n(4126),s=n(93995),l=n(340),c=n(23999),d=n(63700),u=n(26324),p=n(35572),v=n(95719),m=n(8536),g=n(74690),h=n(80339),_=n(76435),f=n(20259),y=n(24451),b=n(55322),w=n(66401),x=n(64356),T=n(55306),k=n(28889),S=n(11983),E=n(31780),A=n(60408),O=n(25789),P=n(42577),I=n(7672),C=n(26325),L=n(55099);!function(e){e[e.FirstCommit=0]="FirstCommit",e[e.ConfirmEndAdAuth=1]="ConfirmEndAdAuth",e[e.ConfirmEndLive=2]="ConfirmEndLive"}(i||(i={}));let j=class{constructor(e){this.fetch=e}commitUserSetting(e,t){return this.fetch.post("/api/privacy/user/private_account/update/v1",{query:Object.assign(Object.assign({},e),{tt_csrf_token:this.fetch.csrfToken}),headers:{[C.nk]:this.fetch.csrfToken},body:t,baseUrlType:2})}getComplianceSetting(){return this.fetch.get("/api/compliance/settings/",{baseUrlType:2})}getBlockList(e){return this.fetch.get("/api/block/user_list/",{query:{offset:e,count:20},baseUrlType:2})}};j=(0,o.__decorate)([(0,I._)(),(0,o.__metadata)("design:paramtypes",[L.p])],j);var M=n(41719);let N=class extends a.E{constructor(e,t,n,i,o){super(),this.service=e,this.user=t,this.settingModule=n,this.settingService=i,this.t=o,this.defaultState={statusCode:0,loading:!1,initialized:!1,complianceDisable:!1,complianceFamily:!1,complianceSettingStatusCode:0,privacyBCLimitModalOn:!1,privacyOffConfirmModalOn:!1,privacyOnAlertModalOn:!1,privacyEndLiveModalOn:!1,privacyAccountPromptConfig:{variant:null,selectPrivateByDefault:!0},blockList:{list:[],hasMore:!0,offset:"0",loading:!1},isBlockLoading:!1,isChangeRegionEnabled:!1,regionStatus:"",storeRegion:"",regionName:""}}setLoading(e,t){e.loading=t.loading}setStatusCode(e,t){e.statusCode=t.statusCode}setComplianceStatusCode(e,t){e.complianceSettingStatusCode=t.complianceSettingStatusCode}setComplianceDisable(e,t){e.complianceDisable=t}setComplianceFamily(e,t){e.complianceFamily=t}setPrivacyAccountPromptConfig(e,t){e.privacyAccountPromptConfig=t}setInitialized(e,t){e.initialized=t}setPrivacyBCLimitModalOn(e,t){e.privacyBCLimitModalOn=t}setPrivacyOffConfirmModalOn(e,t){e.privacyOffConfirmModalOn=t}setPrivacyOnAlertModalOn(e,t){e.privacyOnAlertModalOn=t}setPrivacyEndLiveModalOn(e,t){e.privacyEndLiveModalOn=t}setBlockList(e,t){const{list:n,offset:i,hasMore:o,loading:a}=t,r=e.blockList.list,s=n.filter((e=>-1===r.indexOf(e)));e.blockList={list:[...r,...s],offset:i,hasMore:o,loading:a}}setBlockListLoading(e,t){e.blockList.loading=t}setIsBlockLoading(e,t){e.isBlockLoading=t}setIsChangeRegionEnabled(e,t){e.isChangeRegionEnabled=t}setRegionStatus(e,t){e.regionStatus=t}setStoreRegion(e,t){e.storeRegion=t}setRegionName(e,t){e.regionName=t}postCommitChangePrivacySetting(e){return e.pipe((0,p.p)((({query:e,data:t,status:n})=>this.service.commitUserSetting(e,t).pipe((0,v.M)((t=>{3026002===(null==t?void 0:t.status_code)?console.warn("bc limit"):3026006===(null==t?void 0:t.status_code)?(console.warn("live on limit"),k.X.handleShowLiveChangePrivacyAccountPopUp()):0===(null==t?void 0:t.status_code)?(S.F.destroy(),S.F.open({content:this.t("settings_updated"),duration:3,type:"success",widthType:"half"}),k.X.handlePrivateAccountChange(n),"1"===e.value?E.Wk.reportCUJ(M.c.CONVERT_TO_PRIVATE_ACCOUNT,E.PY.FINISH):E.Wk.reportCUJ(M.c.CONVERT_TO_PUBLIC_ACCOUNT,E.PY.FINISH)):(S.F.destroy(),S.F.open({content:(null==t?void 0:t.status_msg)||this.t("server_error_title"),duration:3,type:"fail",widthType:"half"}),"1"===e.value?E.Wk.reportCUJ(M.c.CONVERT_TO_PRIVATE_ACCOUNT,E.PY.FAILURE):E.Wk.reportCUJ(M.c.CONVERT_TO_PUBLIC_ACCOUNT,E.PY.FAILURE))})),(0,m.Z)((e=>{const t=[this.getActions().setLoading({loading:!1}),this.getActions().setStatusCode({statusCode:null==e?void 0:e.status_code})];return 3026002===(null==e?void 0:e.status_code)?t.push(this.getActions().setPrivacyBCLimitModalOn(!0)):3026006===(null==e?void 0:e.status_code)?t.push(this.getActions().setPrivacyEndLiveModalOn(!0)):0===(null==e?void 0:e.status_code)&&t.push(this.settingModule.getActions().setPrivateAccountStatus(n)),(0,c.of)(...t)})),(0,g.Z)(this.getActions().setLoading({loading:!0})),(0,h.q)(this.getActions().setLoading({loading:!1})),(0,_.Q)(this.dispose$),(0,f.W)((()=>(S.F.destroy(),S.F.open({content:this.t("server_error_title"),duration:3,type:"fail",widthType:"half"}),"1"===e.value?E.Wk.reportCUJ(M.c.CONVERT_TO_PRIVATE_ACCOUNT,E.PY.FAILURE):E.Wk.reportCUJ(M.c.CONVERT_TO_PUBLIC_ACCOUNT,E.PY.FAILURE),(0,c.of)(this.getActions().setLoading({loading:!1}),this.getActions().setStatusCode({statusCode:-1})))))))))}getUserSetting(e){return e.pipe((0,p.p)((({callback:e,switchStatus:t})=>this.settingService.getUserSetting().pipe((0,m.Z)((({settings:n={}})=>{const{privateAccount:i=!1,adAuthorization:o=!1,proAccountStatus:a=0,pushSettings:r}=n,s=[this.settingModule.getActions().setUserSetting({privateAccount:i,adAuthorization:o,proAccountStatus:a,pushSettings:r}),this.getActions().setInitialized(!0)];return null==e||e(t,i,this.state.complianceFamily,(0,P.f)(n),this.state.complianceDisable),(0,c.of)(...s)}))))))}getShowRegionChangeSetting(e){return e.pipe((0,y.E)(this.settingModule.state$),(0,p.p)((()=>this.settingService.getShowChangeRegion().pipe((0,v.M)((e=>{0!==e.status_code&&console.error("get region change setting error: ",e.status_code)})),(0,m.Z)((e=>{var t,n,i;const o=null!==(t=e.is_change_region_enabled)&&void 0!==t&&t,a=e.localized_country||"",r=null!==(n=e.status_event)&&void 0!==n?n:"",s=null!==(i=e.region_name)&&void 0!==i?i:"";return(0,c.of)(this.getActions().setIsChangeRegionEnabled(o),this.getActions().setRegionStatus(r),this.getActions().setStoreRegion(a),this.getActions().setRegionName(s))})),(0,b.n)({})))))}getComplianceSetting(e){return e.pipe((0,y.E)(this.settingModule.state$),(0,p.p)((([{switchStatus:e,user:t,callback:n},i])=>this.service.getComplianceSetting().pipe((0,v.M)((e=>{0!==(null==e?void 0:e.status_code)&&console.error("get compliance setting error: ",null==e?void 0:e.status_code)})),(0,m.Z)((o=>{var a,r,s,l,u,p,v,m;const g=null==o?void 0:o.status_code;let h;const y=[this.getActions().setComplianceStatusCode({complianceSettingStatusCode:null==o?void 0:o.status_code})];if(0!==g)h=(0,c.of)(...y,this.getActions().setComplianceDisable(!1));else{const t=0!==(null===(s=null===(r=null===(a=null==o?void 0:o.private_settings)||void 0===a?void 0:a.account)||void 0===r?void 0:r.private_account)||void 0===s?void 0:s.show_type),i=2===(null===(m=(null!==(v=null===(p=null===(u=null===(l=null==o?void 0:o.private_settings)||void 0===l?void 0:l.account)||void 0===u?void 0:u.private_account)||void 0===p?void 0:p.values)&&void 0!==v?v:[]).find((e=>0===e.value)))||void 0===m?void 0:m.res_type);h=(0,d.h)((0,c.of)(...y,this.getActions().setComplianceFamily(i),this.getActions().setComplianceDisable(t),this.getActions().setPrivacyAccountPromptConfig({variant:(0,w.pn)(null==o?void 0:o.private_account_prompt,null==o?void 0:o.private_account_prompt_type),selectPrivateByDefault:void 0!==o.private_account_prompt&&8!==o.private_account_prompt})),this.getUserSetting((0,c.of)({switchStatus:e,callback:n})))}return h.pipe((0,_.Q)(this.dispose$),(0,f.W)((()=>{var e;return S.F.destroy(),S.F.open({content:this.t("server_error_title"),duration:3,widthType:"half"}),(0,c.of)(this.getActions().setComplianceStatusCode({complianceSettingStatusCode:-1}),this.settingModule.getActions().setUserSetting({privateAccount:null!==(e=null==t?void 0:t.isPrivateAccount)&&void 0!==e&&e,adAuthorization:i.userSetting.adAuthorization,proAccountStatus:i.userSetting.proAccountStatus}))})))}))))))}getBlockList(e){return e.pipe((0,p.p)((({offset:e="0"})=>this.service.getBlockList(e).pipe((0,p.p)((({userList:e=[],offset:t,hasMore:n})=>{const i=e.map((({user:e})=>e.uniqueId));return(0,c.of)(this.getActions().setBlockList({list:i,hasMore:n,offset:t,loading:!1}),this.user.getActions().multiSetUser(e.map((({user:e})=>Object.assign(Object.assign({},e),{relation:4})))),this.user.getActions().multiSetUserStats(e.map((({user:e,stats:t})=>({uniqueId:e.uniqueId,stats:t})))))})),(0,g.Z)(this.getActions().setBlockListLoading(!0))))))}};(0,o.__decorate)([(0,r.uk)(),(0,o.__metadata)("design:type",u.c)],N.prototype,"dispose$",void 0),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Object]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setLoading",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Object]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setStatusCode",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Object]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setComplianceStatusCode",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setComplianceDisable",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setComplianceFamily",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Object]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setPrivacyAccountPromptConfig",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setInitialized",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setPrivacyBCLimitModalOn",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setPrivacyOffConfirmModalOn",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setPrivacyOnAlertModalOn",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setPrivacyEndLiveModalOn",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Object]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setBlockList",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setBlockListLoading",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setIsBlockLoading",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,Boolean]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setIsChangeRegionEnabled",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,String]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setRegionStatus",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,String]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setStoreRegion",null),(0,o.__decorate)([(0,r.h5)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[Object,String]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"setRegionName",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[u.c]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"postCommitChangePrivacySetting",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[u.c]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"getUserSetting",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[u.c]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"getShowRegionChangeSetting",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[u.c]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"getComplianceSetting",null),(0,o.__decorate)([(0,r.Mj)(),(0,o.__metadata)("design:type",Function),(0,o.__metadata)("design:paramtypes",[u.c]),(0,o.__metadata)("design:returntype",void 0)],N.prototype,"getBlockList",null),N=(0,o.__decorate)([(0,s.n)("SettingPrivacy"),(0,o.__param)(4,(0,l.y)(x.hp)),(0,o.__metadata)("design:paramtypes",[j,T.U,A.F,O.q,Function])],N)},42577:(e,t,n)=>{"use strict";n.d(t,{E:()=>a,f:()=>o});var i=n(44805);const o=e=>{const{adAuthorization:t,proAccountStatus:n}=e;return 3===n?"BA":t?"AD":"NONE"},a=()=>i.FCM.isAvailable()&&"Notification"in window},41719:(e,t,n)=>{"use strict";n.d(t,{c:()=>i});const i={CONVERT_TO_PUBLIC_ACCOUNT:"convert_to_public_account",CONVERT_TO_PRIVATE_ACCOUNT:"convert_to_private_account"}},5109:(e,t,n)=>{"use strict";n.d(t,{V:()=>l,d:()=>s});var i=n(97895),o=n(39785),a=n(97487),r=n(56070);const s=(0,o.M)({csr:function(e){return t=this,n=void 0,s=function*(){const t=(0,a.Ni)("videoDetail");if(t)return t;const n=yield(0,i.e)();return e.clientABVersions=n,r.h.get("/api/item/detail/",{query:e,baseUrlType:2})},new((o=void 0)||(o=Promise))((function(e,i){function a(e){try{l(s.next(e))}catch(e){i(e)}}function r(e){try{l(s.throw(e))}catch(e){i(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof o?n:new o((function(e){e(n)}))).then(a,r)}l((s=s.apply(t,n||[])).next())}));var t,n,o,s}}),l=(0,o.M)({csr:function(e){}})},43723:(e,t,n)=>{"use strict";n.d(t,{p:()=>r});var i=n(71111),o=n(67134),a=n(85969);function r(e,...t){return(0,o.U)(e,(()=>{const n=(0,i.atom)(...t),o=(0,a.Lr)(e);return n.debugLabel=o.id,n}))}},38259:(e,t,n)=>{"use strict";n.d(t,{$:()=>a});var i=n(40099),o=n(67134);function a(e){return t=>(0,o.U)(e,(()=>(0,i.createContext)(t)))}},67134:(e,t,n)=>{"use strict";n.d(t,{U:()=>r});let i=!1;var o=n(85969);const a=new Map;function r(e,t){const n="function"==typeof t?t:()=>t;return i?function(e,t){const{scope:n,id:i}=e;let o;if(a.has(n)?o=a.get(n):(o=new Map,a.set(n,o)),o.has(i))return o.get(i);{const e=t();return o.set(i,e),e}}((0,o.Lr)(e),n):n()}},85969:(e,t,n)=>{"use strict";n.d(t,{Lr:()=>s});const i="__default_scope__",o="__default_version__",a="@",r="~";function s(e){return"string"==typeof e?function(e){const t=e.indexOf(a),n=e.lastIndexOf(r);let s=e,l=i,c=o;return-1!==t&&(s=e.slice(0,t),n>t?(l=e.slice(t,n),c=e.slice(n)):l=e.slice(t)),{id:s,scope:l,version:c}}(e):{id:e[0],scope:null!==(t=e[1])&&void 0!==t?t:i,version:null!==(n=e[2])&&void 0!==n?n:o};var t,n}},91334:(e,t,n)=>{"use strict";n.d(t,{AW:()=>c,LY:()=>d,OA:()=>s,jT:()=>r,mc:()=>l});var i=n(64590),o=n(7789),a=n(92439);function r(e){const{customParams:t,option:n}=null!=e?e:{},a=Object.assign({timer_from_ttfb:(0,o.V)()-(0,o.MZ)()},t);i.l.send("arm_browser_render",a,n)}function s({duration:e,customParams:t,option:n}){const o=Object.assign({timer_render:e},t);i.l.send("arm_render_finish",o,n)}function l(e){const{customParams:t,option:n}=null!=e?e:{};i.l.send("arm_core_content_ready",Object.assign({},t),n)}function c(e){const{customParams:t,option:n}=null!=e?e:{};(0,a.fK)((({name:e,value:o})=>{if("LCP"===e){const e=Object.assign({timer_lcp:Math.ceil(o)},t);i.l.send("arm_lcp",e,n)}else console.warn("Do not get LCP metric in onLCP callback")}))}function d(e){const{customParams:t,option:n}=null!=e?e:{};window.addEventListener("beforeunload",(function e(){i.l.send("arm_bounce",Object.assign({},t),n),window.removeEventListener("beforeunload",e)}))}},64590:(e,t,n)=>{"use strict";n.d(t,{l:()=>r});var i=n(67134),o=n(7789);class a{constructor(){this.allowRepeat=!1,this.eventAlreadySent={},this.stop=!1}init({pageName:e,device:t,sender:n,sendConfig:i}){this.sender=n,this.path=window.location.pathname,this.pageName=e,this.device=t,i&&this.handleConfigGlobal(i)}config({sender:e}){this.sender=e}getCommonParams(e,t){var n,i,a,r;return{page_name:null!==(i=null!==(n=this.pageName)&&void 0!==n?n:e)&&void 0!==i?i:"",last_event:null!==(a=this.lastEvent)&&void 0!==a?a:"",duration:(0,o.V)(),device:null!==(r=this.device)&&void 0!==r?r:"",userAgent:null!=t?t:window.navigator.userAgent}}send(e,t,n){this.sender?(((null==n?void 0:n.forceSend)||this.allowSend(e))&&this.sender(e,Object.assign(Object.assign({},t),this.getCommonParams())),this.updateStatus(e),this.lastEvent=e):console.error("Send ARM events before initialized")}handleConfigGlobal(e){const{allowRepeat:t}=e;this.allowRepeat=t}allowSend(e){const{stop:t,path:n,allowRepeat:i,eventAlreadySent:o}=this,a=window.location.pathname;return!(t||a!==n||!i&&o[e])}updateStatus(e){const t=window.location.pathname;this.stop=this.stop||t!==this.path,this.eventAlreadySent[e]=!0}}const r=(0,i.U)("ArmLogger@tiktok/arm-logger",(()=>new a))},7789:(e,t,n)=>{"use strict";n.d(t,{MZ:()=>i,V:()=>o}),n(92439);const i=()=>{var e,t,n;const i=null===(t=null===(e=window.performance)||void 0===e?void 0:e.getEntriesByType)||void 0===t?void 0:t.call(e,"navigation")[0];return Math.ceil(null!==(n=null==i?void 0:i.responseStart)&&void 0!==n?n:0)},o=()=>Math.ceil(performance.now())},87181:(e,t,n)=>{"use strict";n.d(t,{Zi:()=>u,$U:()=>c,BJ:()=>v,Bl:()=>l,D9:()=>p,yw:()=>d});var i,o,a=n(58632);!function(e){e.ROW="https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/secsdk/secsdk-lastest.umd.js",e.TTP="https://lf16-cdn-tos.tiktokcdn-us.com/obj/static-tx/secsdk/secsdk-lastest.umd.js"}(i||(i={})),function(e){e.Acrawler="acrawler",e.SecSdkSG="secsdk_sg",e.SecSdkVA="secsdk_va",e.SecSdkTTP="secsdk_ttp"}(o||(o={}));const r={acrawler:"https://lf16-tiktok-web.tiktokcdn-us.com/obj/tiktok-web-tx/webmssdk/2.0.0.221/webmssdk.js",secsdk_sg:"https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/secsdk/secsdk-lastest.umd.js",secsdk_va:"https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/secsdk/secsdk-lastest.umd.js",secsdk_ttp:"https://lf16-cdn-tos.tiktokcdn-us.com/obj/static-tx/secsdk/secsdk-lastest.umd.js"};n(24643);const s="script-manager";function l(e){var t,n,i;let o={imports:{}};try{o=JSON.parse(null!==(n=null===(t=document.querySelector(`#${s}`))||void 0===t?void 0:t.innerHTML)&&void 0!==n?n:"")}catch(e){console.error("[Init failed]: sdk config is invalid")}return null!==(i=o.imports[e])&&void 0!==i?i:""}function c(e){return(0,a.__awaiter)(this,void 0,void 0,(function*(){const{moduleId:t}=e,n=l(t),i=document.createElement("script");return i.src=n,i.async=!0,new Promise(((e,t)=>{var o;n?(i.parentNode&&(null===(o=document.parentNode)||void 0===o||o.removeChild(i)),document.body.appendChild(i),i.addEventListener("load",(()=>{e(!0)})),i.addEventListener("error",(()=>{t(new Error("load script failed"))}))):t(new Error("empty script src"))}))}))}function d(e){const{moduleId:t}=e,n=l(t),i=document.querySelector(`script[src="${n}"]`);return Boolean(i)}function u(e="/node-webapp/api/importmap"){return(0,a.__awaiter)(this,void 0,void 0,(function*(){if(document.querySelector(`#${s}`))return;let t={imports:{}};const n=document.createElement("script");n.type="application/json",n.id=s;try{const n=yield window.fetch.call(null,e,{method:"Get",redirect:"error"}),{imports:i}=yield n.json();t={imports:i}}catch(e){t={imports:r}}n.innerText=JSON.stringify(t),document.head.appendChild(n)}))}function p(e){let t="secsdk_sg";switch(e){case"MALI_VA":t="secsdk_va";break;case"TTP":t="secsdk_ttp";break;default:t="secsdk_sg"}return t}function v(){return"acrawler"}},81054:(e,t,n)=>{"use strict";n.d(t,{Ay:()=>N,PD:()=>M});var i=n(47236);function o(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}class a{isTriggered(e){return this._triggeredEvents.has(e)}emit(e){const t=this._activeListeners.get(e);t&&t.forEach((e=>e())),this._activeListeners.delete(e),this._triggeredEvents.add(e)}on(e,t){if(this.isTriggered(e))t();else{var n;const i=null!==(n=this._activeListeners.get(e))&&void 0!==n?n:new Set;i.add(t),this._activeListeners.set(e,i)}return{dispose:()=>this.off(e,t)}}off(e,t){const n=this._activeListeners.get(e);null==n||n.delete(t)}waitFor(e){var t,n=this;return(t=function*(){return new Promise((t=>{n.on(e,t)}))},function(){var e=this,n=arguments;return new Promise((function(i,a){var r=t.apply(e,n);function s(e){o(r,i,a,s,l,"next",e)}function l(e){o(r,i,a,s,l,"throw",e)}s(void 0)}))})()}constructor(){this._triggeredEvents=new Set,this._activeListeners=new Map}}class r extends Error{constructor(e){super(null!=e?e:"Lazy load component timeout.")}}var s=n(40099);const l=Symbol.for("visible_render_strategy"),c=e=>{const{id:t,emitter:n}=e;return(0,s.useEffect)((()=>{if(n.isTriggered(l))return;const e=document.getElementById(t);if(!e)return;const i=new IntersectionObserver((e=>{for(const t of e)if(t.isIntersecting){i.disconnect(),n.emit(l);break}}));return i.observe(e),()=>{i.disconnect()}}),[t,n]),null};var d=n(24643);function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function p(e){for(var t=1;t{m()(e,(i=>{i?(_.delete(e),n(i)):t()}))}));return _.set(e,t),t}))).apply(this,arguments)}function y(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function b(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){y(a,i,o,r,s,"next",e)}function s(e){y(a,i,o,r,s,"throw",e)}r(void 0)}))}}function w(e){return x.apply(this,arguments)}function x(){return(x=b((function*(e){for(const t of e)"function"==typeof t?yield t():yield t}))).apply(this,arguments)}function T(e,t){return b((function*(){yield e.waitFor(t)}))}function k(e){return b((function*(){let t;return new Promise((n=>{t=setTimeout((()=>{n()}),e)})).finally((()=>clearTimeout(t)))}))}function S(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function E(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){S(a,i,o,r,s,"next",e)}function s(e){S(a,i,o,r,s,"throw",e)}r(void 0)}))}}function A(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const O=()=>new Promise((()=>{})),P=()=>Promise.resolve();function I(e,t,n,i){return o=E((function*(o){if(null==(a=o)?void 0:a.__chunkExtractor)return n(o);var a;let s;const c=(d=E((function*(){s=yield n(o)})),function(){return d.apply(this,arguments)});var d;let u=P,p=O;const v=[],{timeout:m,raceTime:g,delayTime:_,renderEvent:y,renderStrategy:x}=function(e){for(var t=1;t{t=setTimeout((()=>{i(new r("Load lazy component timeout."))}),e)})).finally((()=>clearTimeout(t)))}))}(m)),"number"==typeof g&&(p=k(g)),"number"==typeof _&&v.push(k(_)),(null==i?void 0:i.dependencyScripts)&&Array.isArray(i.dependencyScripts)&&v.push((S=i.dependencyScripts,h((function*(){try{yield Promise.all(S.map((e=>function(e){return f.apply(this,arguments)}(e))))}catch(e){console.error("Load script error:",e)}}))));const I=x;"idle"===I?v.push(b((function*(){return new Promise(((e,t)=>{requestIdleCallback((()=>{e()}))}))}))):"visible"===I?v.push(T(t,l)):"custom"===I&&y&&v.push(T(e,y));const C=Promise.race([p(),w(v)]),L=w([C,c]);if(yield Promise.all([L,u()]),!(null==s?void 0:s.default))throw new Error("Default of module should be component.");return s})),function(e){return o.apply(this,arguments)};var o}function C(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const L=new a,j=new Set([L]),M={emit(e){j.forEach((t=>t.emit(e)))}};var N=function(e,t){const n=new a;let o;j.add(n);let r=e;if("function"!=typeof e){r=e.importAsync;const i=I(L,n,r,t);l=function(e){for(var t=1;t{t({}).catch((e=>{console.error("Load resource error",{error:e?e.message:e})}))};"preload"!==e?"custom"===e&&i&&n.on(i,(()=>{o()})):o()}(null==t?void 0:t.resourceStrategy,r,L,null==t?void 0:t.loadEvent),function(e,t,n={}){if(n.dependencyScripts)try{!function(e,t="preload"){for(const n of e){const e=document.createElement("link");e.href=n,e.rel=t,e.as="script",document.head.appendChild(e)}}(n.dependencyScripts)}catch(e){console.error("Link script error:",e)}return n=>{{const{intersectionId:i}=n,o=i?(0,d.jsx)(c,{id:i,emitter:t}):null;return(0,d.jsxs)(s.Fragment,{children:[o,(0,d.jsx)(e,p({},n))]})}}}((0,i.Ay)(o,t),n,t)}},90118:(e,t,n)=>{"use strict";n.d(t,{xk:()=>Z,rr:()=>Y});var i,o,a,r,s,l,c=n(24643),d=n(93608),u=n(40099),p=n(35323),v=n(93987),m=n(12323),g=n(74745),h=n(75420),_=n(14583),f=n(43485),y=n(37085);(o=i||(i={}))[o.Yes=0]="Yes",o[o.No=1]="No",(r=a||(a={}))[r.Public=0]="Public",r[r.Self=1]="Self",r[r.Friend=2]="Friend",(l=s||(s={})).PlayQuality="video_play_quality",l.PlayEnded="video_play_end",l.PlayFailed="video_play_failed",l.BlockStart="video_block_start",l.Block="video_block",l.Request="video_request",l.RequestResponse="video_request_response",l.FirstFrame="first_feed_show_time";const b={corruptedVideoFrames:0,creationTime:0,droppedVideoFrames:0,totalVideoFrames:0},w={currentSrc:"",currentTime:0,duration:0,readyState:0,networkState:0,error:null};var x,T,k,S,E,A;(T=x||(x={})).NoInteract="failed because the user didn't interact with the document first.",T.Interrupted="request was interrupted by a call to pause",T.SafariNoInteract="The request is not allowed by the user agent or the platform in the current context",T.FireFox="The play method is not allowed by the user agent or the platform in the current context, possibly because the user denied permission.",T.LoadInterrupt="request was interrupted by a new load request",T.Abort="The operation was aborted",(S=k||(k={})).LOAD="load",S.WAITING="waiting",S.PAUSE="pause",S.ENDED="ended",S.ERROR="error",S.PLAYING="playing",(A=E||(E={}))[A.NIL=-255]="NIL",A[A.UnknownError=-1]="UnknownError",A[A.Ok=0]="Ok",A[A.ReportLiveFailed=90002]="ReportLiveFailed",A[A.VerifyCode=1e4]="VerifyCode",A[A.VideoLikeFreq=2150]="VideoLikeFreq",A[A.VideoLikeFreq2=2210]="VideoLikeFreq2",A[A.VideoUnavailableDeleted=2054]="VideoUnavailableDeleted",A[A.AdVideoUnavailableChange=2752]="AdVideoUnavailableChange",A[A.CommentBanCode=22]="CommentBanCode",A[A.CommentLikePermissionDisable=3002043]="CommentLikePermissionDisable",A[A.SearchSensitiveCode=403]="SearchSensitiveCode",A[A.SearchYoungCode=203]="SearchYoungCode",A[A.SmsInvalidNumber=-1]="SmsInvalidNumber",A[A.SmsSlideVerify=-4]="SmsSlideVerify",A[A.FypVideoListLimit=10404]="FypVideoListLimit",A[A.ClientPageError=450]="ClientPageError",A[A.LiveNeedLogin=10119]="LiveNeedLogin",A[A.SharkBlock=10114]="SharkBlock",A[A.SharkSlide=10113]="SharkSlide",A[A.NetError=10111]="NetError",A[A.ServerErrorNot500=10101]="ServerErrorNot500",A[A.VideoRisk=10228]="VideoRisk",A[A.VideoRMask=10229]="VideoRMask",A[A.VideoRiskMask=10230]="VideoRiskMask",A[A.VideoNeedRecheck=10227]="VideoNeedRecheck",A[A.VideoUnshelveByMusic=10220]="VideoUnshelveByMusic",A[A.VideoNotExist=10204]="VideoNotExist",A[A.VideoAbnormal=10215]="VideoAbnormal",A[A.VideoLowAgeM=10213]="VideoLowAgeM",A[A.VideoLowAgeT=10214]="VideoLowAgeT",A[A.VideoFirstReviewUnshelve=10217]="VideoFirstReviewUnshelve",A[A.VideoPrivateByUser=10216]="VideoPrivateByUser",A[A.VideoGeofenceBlock=10231]="VideoGeofenceBlock",A[A.VideoPhoto=10239]="VideoPhoto",A[A.VideoFriendsOnly=10240]="VideoFriendsOnly",A[A.VideoDeleted=10241]="VideoDeleted",A[A.VideoUserBlockedByAuthor=10242]="VideoUserBlockedByAuthor",A[A.HashtagNotExist=10205]="HashtagNotExist",A[A.HashtagUnshelve=10212]="HashtagUnshelve",A[A.HashtagSensitivityWord=10211]="HashtagSensitivityWord",A[A.HashtagBlackList=10209]="HashtagBlackList",A[A.UserInboxFollowBan=24]="UserInboxFollowBan",A[A.UserNotExist=10202]="UserNotExist",A[A.UserBan=10221]="UserBan",A[A.UserPrivate=10222]="UserPrivate",A[A.UserNotLogin=10102]="UserNotLogin",A[A.UserFtc=10223]="UserFtc",A[A.UserUniqueSensitivity=10225]="UserUniqueSensitivity",A[A.QuestionNotAvailable=10236]="QuestionNotAvailable",A[A.MusicNotExist=10203]="MusicNotExist",A[A.MusicUnshelve=10218]="MusicUnshelve",A[A.MusicNoCopyright=10219]="MusicNoCopyright",A[A.MusicUnavailable=202001]="MusicUnavailable",A[A.GameNotExist=10224]="GameNotExist",A[A.LiveNotExist=10210]="LiveNotExist",A[A.GoLiveRoomBaned=10018]="GoLiveRoomBaned",A[A.GoLiveBaned=4003035]="GoLiveBaned",A[A.LiveRoomPrepare=30019]="LiveRoomPrepare",A[A.LiveRoomEnd=30003]="LiveRoomEnd",A[A.LiveRoomBan=30012]="LiveRoomBan",A[A.LiveNoGatedAuth=4003043]="LiveNoGatedAuth",A[A.LiveNoAgeGatedAuth=4003110]="LiveNoAgeGatedAuth",A[A.LivePaidEvent=4003072]="LivePaidEvent",A[A.LiveSubscriberOnly=4003135]="LiveSubscriberOnly",A[A.LiveSuicideCase=2403]="LiveSuicideCase",A[A.LiveSensitiveTitle=50004]="LiveSensitiveTitle",A[A.LiveRoomBaned=10018]="LiveRoomBaned",A[A.LiveEnterRoomNeedLogin=20003]="LiveEnterRoomNeedLogin",A[A.LiveAccountUnderRiskControl=20063]="LiveAccountUnderRiskControl",A[A.LiveHitBanStrategy=30009]="LiveHitBanStrategy",A[A.LiveOBSAccessRecalled=4003105]="LiveOBSAccessRecalled",A[A.EffectNotExist=10208]="EffectNotExist",A[A.PlaylistNotExist=10233]="PlaylistNotExist",A[A.PlaylistInTrill=10234]="PlaylistInTrill",A[A.VideoPlaylistUnavailable=10243]="VideoPlaylistUnavailable",A[A.VideoPlaylistIsEmpty=10244]="VideoPlaylistIsEmpty",A[A.PrivateAccountLimitByBC=3026002]="PrivateAccountLimitByBC";var O=n(91257),P=n(68735);new h.Vb;const I=new P.A;function C(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function L(e){for(var t=1;te?e.map((e=>e.GearName||"")):null,M=e=>e?e.map((e=>e.QualityType&&e.Bitrate?`${e.QualityType}:${e.Bitrate}`:"")).filter((e=>!!e)):null,N=e=>{if(!e)return 0;let t=0;for(let n=0;n{if(!e)return t;if("string"==typeof e&&e.indexOf("xgpreload_config")>-1)return e;const n=Number(e);if(!D.has(n)){const t=String(e).match(/^([a-zA-Z]*)+_([0-9]+)_0$/i);return t?`${t[1]}_${t[2]}p`:`_${e}`}return D.get(n)};function B(e=0){return["one_column","three_column","browser_mode","swiper_mode","video_detail","pip","fullscreen","creator_tab","mini_player","immersive_player"][e]}const U={Chrome:{cpuCore:0,dScore:0,score:-2,gpuScore:0,hevcQualityType:14,checkLevel:2,pageNames:["video_detail","homepage_hot","homepage_follow","others_homepage","explore_page"],playModes:["video_detail","one_column","browser_mode","immersive_player","three_column"]},Edge:{cpuCore:0,dScore:0,score:-2,gpuScore:0,hevcQualityType:14,checkLevel:2,pageNames:["video_detail","homepage_hot","homepage_follow","others_homepage","explore_page"],playModes:["video_detail","one_column","browser_mode","immersive_player","three_column"]}};var F=n(90184);function V(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function z(e){for(var t=1;t{},renderState:ve=m.R.ACTIVE},me){var ge;const he=(0,u.useRef)(null),_e=(0,u.useRef)(),fe=(0,u.useRef)(null),ye=(0,u.useRef)(ve),be=(0,u.useRef)(!1),we=(0,u.useRef)(null),xe=(0,u.useRef)((0,_.vA)()),[Te,ke]=(0,u.useState)((new Date).getTime()),[Se,Ee]=(0,u.useState)(),[Ae,Oe]=(0,u.useState)(),[Pe,Ie]=(0,u.useState)(!1);(0,u.useEffect)((()=>{const{playerUpgrade:e,playerH265Soft:t}=ce;let n="XG";(null==t?void 0:t.enableSoftwareH265)||(n=(null==e?void 0:e.playerType)||xe.current.playerType||"XG"),be.current="NEW_TT"===n,we.current=(0,F.AE)(be.current)}),[]),(0,u.useEffect)((()=>{g.M.setHevcTestData(le),g.M.setABTest(ce);const{playerPreload:e,hevcIgnoreEnv:t,hevcResultLocal:n}=ce;f._.updateMaxQueueCount((null==e?void 0:e.maxQueueCount)||3);const i=g.M.checkHevcResult(1===t),{open:o,closePreload:a,qualityType:r,hevcQualityType:s}=i;g.a.getInstance().needPersist=0===n,h.Tz.updateConfig({quality:r,hevcQuality:s}),a||(0,F.$v)(we.current,o?"h265":"h264")}),[le,ce]);const Ce=(0,u.useMemo)((()=>{const{hevcIgnoreEnv:e}=ce;return g.M.checkHevcResult(1===e)}),[Q]),Le=(0,u.useMemo)((()=>de&&de.length>0?de:[]),[de]);(0,u.useEffect)((()=>{var e;Le.length>0?(_e.current?_e.current.setSubTitles(Le):(_e.current=new h.SX({subTitlesList:Le}),_e.current.on("update",(e=>{pe(e)})),_e.current.on("change",(e=>{pe(e)})),_e.current.on("error",(e=>{pe(e)}))),fe.current&&_e.current.attach(fe.current.element)):null===(e=_e.current)||void 0===e||e.switchOff()}),[Le,Q]),(0,u.useEffect)((()=>{var e,t;ue?null===(e=_e.current)||void 0===e||e.switch(ue):null===(t=_e.current)||void 0===t||t.switchOff()}),[ue,Q]),(0,u.useEffect)((()=>{var e;let t=ve;if(fe.current){ve===m.R.BACKUP&&(t=m.R.RETAIN);const e=we.current;null==e||e.updatePlayer(fe.current,t),t===m.R.ACTIVE&&o&&(fe.current.play(),fe.current.forceAutoplay=!1),t!==m.R.ACTIVE&&fe.current.pause()}else ve===m.R.RETAIN&&(t=m.R.BACKUP);(0,_.Tb)(W,"renderStateChange",Q,null===(e=fe.current)||void 0===e?void 0:e.uuid,`renderState:${ve} state:${t} muted:${re} volume:${J} autoplay:${o}`),ye.current=t}),[ve]);const je=(0,u.useMemo)((()=>(0,y.pQ)(e,t,Q,i,o,Z,J,re,ee,ae,null==ne?void 0:ne.vqscore,Ce,Te,ce)),[e,t,Q,Z,i,o,X,J,ee,ae,ne,Ce,Te,ce,n]),Me=(0,u.useRef)(je);Me.current=je;const Ne=(0,u.useCallback)((()=>{var e,t,n,i;const o=null===(e=fe.current)||void 0===e?void 0:e.attributes;if(!o)return{};const a=o.currentSrc,r=null===(t=fe.current)||void 0===t?void 0:t.curDefinition;var s;return{buffered:o.buffered,currentTime:o.currentTime,ended:o.currentTime,currentSrc:a,duration:o.duration,readyState:o.readyState,networkState:o.networkState,error:"",playerType:null===(n=fe.current)||void 0===n?void 0:n.type,volume:o.volume,muted:o.muted,videoBitrate:null==r?void 0:r.bitrate,videoQuality:null==r?void 0:r.definition,codecType:null!==(s=null==r?void 0:r.codecType)&&void 0!==s?s:"h264",play_url:a,render_state:(null===(i=fe.current)||void 0===i?void 0:i.state)||""}}),[]),De=(0,u.useMemo)((()=>{let e=null;return Z&&(e=function(e,t){var n,i,o,a,r,s,l,c,d,u,p,v;return L({itemId:e.group_id||"",authorId:e.author_id||"",isScheduled:Boolean(e.is_scheduled),autoplayStatus:1,searchId:e.search_id,searchKeyword:e.search_keyword,searchResultId:e.search_result_id,questionId:e.question_id,playMode:t&&t.playModeForTea?t.playModeForTea:O.ey.OneColumn,isMute:!(!t||!t.mute),collectionId:e.collection_id,collectionName:e.collection_name,isPaidPartnership:Boolean(e.isPaidPartnership),poiId:e.poi_id,playlistId:e.playlist_id,popupType:e.popup_type,enterTab:e.enter_tab,diversifyId:e.diversify_id,enterMethod:"",isSubOnlyVideo:e.is_sub_only_video,isCopyrightMuted:!(!t||!t.itemMute),isPinnedItem:e.isPinnedItem,tab_name:e.tab_name,isAutoScroll:!(!t||!t.isAutoScroll),caption_mode:null==t||null===(n=t.claParams)||void 0===n?void 0:n.caption_mode,caption_language:null==t||null===(i=t.claParams)||void 0===i?void 0:i.caption_language,caption_options:null==t||null===(o=t.claParams)||void 0===o?void 0:o.caption_options,always_translate_post_mode:null==t||null===(a=t.claParams)||void 0===a?void 0:a.always_translate_post_mode,do_not_translate_mode:null==t||null===(r=t.claParams)||void 0===r?void 0:r.do_not_translate_mode,translate_into_mode:null==t||null===(s=t.claParams)||void 0===s?void 0:s.translate_into_mode,see_original_show:null==t||null===(l=t.claParams)||void 0===l?void 0:l.see_original_show,see_translation_show:null==t||null===(c=t.claParams)||void 0===c?void 0:c.see_translation_show,video_width:(null==t||null===(d=t.videoDimensionParams)||void 0===d?void 0:d.video_width)||0,video_height:(null==t||null===(u=t.videoDimensionParams)||void 0===u?void 0:u.video_height)||0,video_duration:(null==t||null===(p=t.videoDimensionParams)||void 0===p?void 0:p.video_duration)||0},null!==(v=null==t?void 0:t.videoContentParams)&&void 0!==v?v:{})}(Z,ne)),e}),[Z,ne,Q]),Re=(0,u.useRef)(De);Re.current=De;const Be=(0,u.useMemo)((()=>{let e=null;if(Q&&Z){var t;const n=null===(t=fe.current)||void 0===t?void 0:t.attributes;e=function(e,t,n,i,o){let r=a.Public;t.forFriend&&(r=a.Friend),t.secret&&(r=a.Self);let s="";if(null==o?void 0:o.src){const e=/^(?:https?:\/\/)?([^\/\s:]+)/,t=o.src.match(e);s=t?t[1]:""}var l;const{dScore:c,netScore:d}=null!==(l=g.M.getDeviceScore())&&void 0!==l?l:{},u={group_id:e,author_id:t.author_id||"",play_mode:B(i),logo_type:"unwatermarked",item_status:r,play_url:o?o.src:"",host:s,aweme_type:t.aweme_type||0,pic_cnt:t.pic_cnt||0,playlist_id:t.playlist_id||"",popup_type:t.popup_type||"",size:t.size||0,watch_count_foru:1,watch_count_total:1,log_id:t.log_id||"none",is_ad:t.isAd};let p={};n&&(p={video_width:n.video_width||0,video_height:n.video_height||0,video_duration:n.video_duration||0});let v={};return v={cpu_core:I.cpu,memory_size:I.memory,HEVC_supported:I.isHEVCSupported?1:0,hardware_score:c,network_score:d},Object.assign({},v,u,p)}(Q,Z,null==ne?void 0:ne.videoDimensionParams,X,n)}return e}),[Q,Z,ne,X,fe.current,Q]),Ue=(0,u.useMemo)((()=>{var e;let t=null;if((0,_.Tb)(q,"videoParams preloaderInfo",null===(e=fe.current)||void 0===e?void 0:e.uuid,Se),Z&&fe.current){const e=fe.current.curDefinition;t=function(e,t,n,i,o){let a="",r=-1,s=-1,l="";const c=R(n.definition,t.definition);t.videoQuality&&c&&(a=`${t.videoQuality}_${c}`),(null==i?void 0:i.vid)==="TT-vCache-"+e&&(r=i.size,s=Math.floor(i.duration)),o&&(l="XG"===o.type?"xgplayer":"defaultPlayer");const d=(null==o?void 0:o.state)||"default";return{video_bitrate:n.bitrate||t.bitrate||0,video_format:t.format||"",codec_format:n.codecType||"h264",encoded_type:t.encodedType||"",bitrate_quality:t.videoQuality||"",video_quality:a,video_encodeUserTag:t.encodeUserTag||"",original_definition:t.definition||"",preload_size:r,preload_time:s,player_type:l,video_type:"mp4",render_state:d}}(Q,Z,e,Se,fe.current)}return t}),[Q,Z,Se,fe.current,Q]),Fe=(0,u.useMemo)((()=>{let e=!1;return fe.current&&(e=function(e){const t=e?e.codecType:"h264";return!!t&&t.indexOf("h265")>-1}(fe.current.curDefinition)),e}),[]),Ve=(0,u.useCallback)((()=>{var e;if((0,p.uQ)(v.Y.VideoRequest),!Be||1===X)return;const t=Be;(0,_.Tb)(q,"handleVideoRequest",null===(e=fe.current)||void 0===e?void 0:e.uuid,Be),d.f.event(s.Request,t)}),[Be,X,Q]),ze=(0,u.useCallback)((e=>{var t;if(!Be||!Z||!fe.current)return;const{curDefinition:n,attributes:i}=fe.current,o=function(e,t,n,i,o,a){let r="";const s=R(t.definition,n.definition);let l;return n.videoQuality&&s&&(r=`${n.videoQuality}_${s}`),a&&(l=a.error),Object.assign({},{duration:Math.round(o),error_code:l?String(l.code):"",is_success:l?"0":"1",video_quality:r,is_bytevc1:i?1:0,isExpired:2,isSupportMP4:1},e)}(Be,n,Z,Fe,e.duration,i);(0,_.Tb)(q,"handleVideoRequestResponse",null===(t=fe.current)||void 0===t?void 0:t.uuid,e,o),d.f.event(s.RequestResponse,o)}),[Be,Fe,Z,Q]),He=(0,u.useCallback)((e=>{if(!Be||1===X)return;const t=Be;t.block_type=(null==e?void 0:e.blockType)||0,d.f.event(s.BlockStart,t)}),[Be,X,Q]),qe=(0,u.useCallback)((e=>{var t,n;if(!Be||!Ue)return;const i=null===(t=fe.current)||void 0===t?void 0:t.attributes,o=function(e,t,n,i,o){let a,r=0;o&&(a=o.error,r=o.duration);let s=i.code||0,l=i.message||"";return s<=0&&a&&(s=a.code,l=a.message),Object.assign({},t,{error_code:String(s),error_info:l,is_bytevc1:n?1:0,duration:Math.round(1e3*r),isExpired:i.isExpired||0,isSupportMP4:1,is_before:0===i.status?0:1,retry_c:i.retryCount||0,retry_l:i.retryList||[]},e)}(Be,Ue,Fe,e,i);(0,_.Tb)(q,"handlePlayFailed",null===(n=fe.current)||void 0===n?void 0:n.uuid,e,o),d.f.event(s.PlayFailed,o)}),[Be,Ue,Fe,Q]),Ge=(0,u.useCallback)((e=>{var t;if(null==C||C(),!(Be&&Ue&&Z&&fe.current&&1!==X))return;const{curDefinition:n,attributes:i}=fe.current,o=function(e,t,n,i,o,a,r,s,l,c,d){let u,p,v=0,m=0,g=1,h=!1;const _=r-s;d&&(u=d.error,v=d.duration,m=d.readyState,p=d.buffered,g=d.volume,h=d.muted);const f=Math.min(_,1e3*v);let y=i.bitrate;y<=0&&(y=o&&o.bitrate?o.bitrate:0);const b=y/8*(f/1e3);let w=0,x=0,T=0,k=0;if(c){const e=c.playbackQuality;e&&(w=e.droppedVideoFrames,x=e.totalVideoFrames,x&&(T=w/x),k=_)}return Object.assign({},t,{is_success:u?"0":"1",video_duration:Math.round(1e3*r),play_duration:Math.round(1e3*a),buffering:m<=2?1:0,duration:Math.round(_),wait_duration:0,cur_cache_duration:N(p),local_time_ms:Date.now(),volume_level:g,volume_change:0,muted:h?1:0,click_mute:0,session_order:0,play_size:Math.round(b),data_player_type:2,cache_size:0,cache_duration:0,cdn_size_video:0,is_bytevc1:n?1:0,drop_frame:w,total_play_frame:x,drop_frame_rate:T,drop_frame_duration:k,vqm:l},e)}(Be,Ue,Fe,n,Z,e.currentTime,e.duration,e.pauseDuration,e.vqm,fe.current,i);(0,_.Tb)(q,"handlePlayEnded",null===(t=fe.current)||void 0===t?void 0:t.uuid,e,o);const a=function(e){var t,n;const i={isFinish:0,pt:0,vt:0,firstframeDuration:100,errorCode:0,errorMessage:"",codecType:"h264",resolution:"",url:""},o=null==e||null===(n=e.player)||void 0===n||null===(t=n.plugins)||void 0===t?void 0:t.xgVodLogger;return(null==o?void 0:o.getFinalInfo)?L({},i,o.getFinalInfo()):i}(fe.current),r=(l=z({vid:Q,videoQuality:0,stayDuration:0,playPos:Math.round(1e3*e.currentTime)},a),c=null!=(c={logid:Z.log_id||"none"})?c:{},Object.getOwnPropertyDescriptors?Object.defineProperties(l,Object.getOwnPropertyDescriptors(c)):function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t}(Object(c)).forEach((function(e){Object.defineProperty(l,e,Object.getOwnPropertyDescriptor(c,e))})),l);var l,c;null==V||V(r),d.f.event(s.PlayEnded,o)}),[Be,Ue,Fe,Z,X,Q]),$e=(0,u.useCallback)((e=>{var t;if((0,p.uQ)(v.Y.VideoFirstFrame),!Be||1===X)return;const n=function(e,t){return Object.assign({},{feed_total:t},e)}(Be,e.duration);(0,_.Tb)(q,"handleFirstFrame",null===(t=fe.current)||void 0===t?void 0:t.uuid,n);const i=(0,p.xt)();d.f.event(s.FirstFrame,z({},n,i))}),[Be,X,Q]),We=(0,u.useCallback)((t=>{var n,i;if(!Be||!Ue||1===X)return;const o=null===(n=fe.current)||void 0===n?void 0:n.attributes,a=function(e,t,n,i,o,a){let r=0,s=!1;return a&&(r=a.duration,s=a.muted),Object.assign({},t,{duration:Math.round(i.duration),is_bytevc1:n?1:0,video_duration:Math.round(1e3*r),muted:s?1:0,bitrate_set:j(o),quality_bitrate:M(o),duration_from_load:Math.round(i.durationFromLoaded||0),duration_with_load:Math.round(i.durationWithLoaded||0),is_same:0,retry_c:i.retryCount||0,retry_l:i.retryList||[]},e)}(Be,Ue,Fe,t,e,o);(0,_.Tb)(q,"handlePlayQuality",null===(i=fe.current)||void 0===i?void 0:i.uuid,t,Ue.preload_time),d.f.event(s.PlayQuality,a)}),[Be,Ue,Fe,X,Q]),Ze=(0,u.useCallback)((e=>{var t;if(!Be||!Ue||1===X)return;const n=null===(t=fe.current)||void 0===t?void 0:t.attributes,i=function(e,t,n,i,o){let a=0;return o&&(a=o.currentTime),Object.assign({},t,{duration:Math.round(i),is_bytevc1:n?1:0,position:Math.round(1e3*a),should_filter:"0",droppedRate:0,end_type:0},e)}(Be,Ue,Fe,e.duration,n);i.block_type=null==e?void 0:e.blockType,d.f.event(s.Block,i)}),[Be,Ue,Fe,X,Q]),Ye=(0,u.useCallback)((e=>{e&&e.error&&d.f.event("video_mse_error",{code:e.error.errorCode||0,message:e.error.errorMessage||"",httpCode:e.error.httpCode||0,url:e.error.url,type:"running"})}),[fe.current,Ae]),Ke=(0,u.useCallback)((e=>{A&&A(e);const t=Ne();ie&&Re.current&&ie.handlePause(z({},Re.current,t))}),[ie,A,fe.current,Q]),Xe=(0,u.useCallback)((e=>{x&&x(e)}),[fe.current,Ae]),Qe=(0,u.useCallback)((e=>{(0,_.Tb)($,"onWaiting"),T&&T(e);const t=Ne();ie&&Re.current&&ie.handleWaiting(z({},Re.current,t))}),[ie,T,fe.current,Ae]),Je=(0,u.useCallback)((e=>{S&&S(e);const t=Ne();ie&&Re.current&&ie.handleTimeUpdate(z({},Re.current,t)),oe&&!oe.getFirstFrameReport()&&oe.reportVideoFirstFrame(t.currentTime||0)}),[ie,oe,S,fe.current,Ae]),et=(0,u.useCallback)((e=>{E&&E(e),ie&&Re.current&&ie.handleError(Re.current)}),[ie,E,fe.current,Ae]),tt=(0,u.useCallback)((e=>{var t;k&&k(e),ie&&Re.current&&ie.handleEnded(Re.current),r&&(null===(t=fe.current)||void 0===t||t.replay())}),[ie,k,r,fe.current,Ae]),nt=(0,u.useCallback)((e=>{var t,n,i;if((0,_.Tb)($,"onPlaying",null===(t=fe.current)||void 0===t?void 0:t.uuid),P&&P(e),!oe)return;const o=(null===(i=Me.current)||void 0===i||null===(n=i.extra)||void 0===n?void 0:n.url)||"";oe.reportVideoInteract({endTime:Date.now(),videoSource:o})}),[oe,P,fe.current,Ae]),it=(0,u.useCallback)((()=>{}),[fe.current]),ot=(0,u.useCallback)((()=>{if(!fe.current||!(0,_.$m)(ye.current))return;const{volume:e,muted:t}=fe.current;null==D||D(e,t)}),[fe.current,D]),at=(0,u.useCallback)((e=>{var t,n,i;if((0,_.Tb)($,"onCanplay",null===(t=fe.current)||void 0===t?void 0:t.uuid),(0,p.uQ)(v.Y.VideoCanPlay),l&&l(e),!oe||oe.getCurrentPageReport())return;const o=(null===(i=Me.current)||void 0===i||null===(n=i.extra)||void 0===n?void 0:n.url)||"";oe.reportVideoFirstScreen({endTime:Date.now(),videoSource:o}),oe.reportVideoAddition({endTime:Date.now(),videoSource:o})}),[oe,l,fe.current,Ae]),rt=(0,u.useCallback)((e=>{e.id=Q,(0,_.Tb)("onResolutionReadyFn",e),null==K||K(e)}),[K,fe.current,Ae,Q]),st=(0,u.useCallback)((()=>{var e;(0,_.Tb)($,"onPlaybackInstanceChanged",null===(e=fe.current)||void 0===e?void 0:e.uuid),ie&&Re.current&&ie.handlePlayTime(Re.current)}),[ie,Ae]),lt=(0,u.useCallback)((e=>{var t,n,i;(0,_.Tb)(q,"onPreloaderInfoReady preloaderInfo",null===(t=fe.current)||void 0===t?void 0:t.uuid,e,"preloadConfig:",{maxQueueCount:null==ce||null===(n=ce.playerPreload)||void 0===n?void 0:n.maxQueueCount,preloadTime:null==ce||null===(i=ce.playerPreload)||void 0===i?void 0:i.preloadTime}),Ee(e)}),[fe.current,Ae]),ct=(0,u.useCallback)((()=>{}),[]),dt=(0,u.useCallback)((e=>{var t;(0,_.Tb)($,"handlerAutoplayPrevented",null===(t=fe.current)||void 0===t?void 0:t.uuid),null==Y||Y(e)}),[fe.current,Ae]),ut=(0,u.useCallback)((e=>{(0,_.Tb)($,"handleContextMenu"),e.preventDefault()}),[fe.current,Ae]);(0,u.useEffect)((()=>{ke((new Date).getTime());const e=we.current;null==e||e.setCustomTracker({event:(e,t)=>{(0,_.Tb)("VodLogger",e,t),d.f.event(e,t)}})}),[]),(0,u.useEffect)((()=>()=>{var e;(0,_.Tb)(G,"releasePlayer metrics",Q),(null===(e=fe.current)||void 0===e?void 0:e.metrics)&&fe.current.metrics.stop()}),[Q]),(0,F.j9)("PlayEnded",Ge,"metrics",fe.current),(0,F.j9)("VideoRequest",Ve,"metrics",fe.current),(0,F.j9)("VideoRequestResponse",ze,"metrics",fe.current),(0,F.j9)("BlockStart",He,"metrics",fe.current),(0,F.j9)("Block",Ze,"metrics",fe.current),(0,F.j9)("PlayQuality",We,"metrics",fe.current),(0,F.j9)("PlayFailed",qe,"metrics",fe.current),(0,F.j9)("FirstFrame",$e,"metrics",fe.current),(0,F.j9)("canplay",at,"event",fe.current),(0,F.j9)("canplaythrough",it,"event",fe.current),(0,F.j9)("play",Xe,"event",fe.current),(0,F.j9)("waiting",Qe,"event",fe.current),(0,F.j9)("ended",tt,"event",fe.current),(0,F.j9)("timeupdate",Je,"event",fe.current),(0,F.j9)("error",et,"event",fe.current),(0,F.j9)("pause",Ke,"event",fe.current),(0,F.j9)("playing",nt,"event",fe.current),(0,F.j9)("playCatch",Ye,"event",fe.current),(0,F.j9)("autoplayPrevented",dt,"event",fe.current),(0,F.j9)("downloaderError",ct,"event",fe.current),(0,F.j9)("volumechange",ot,"event",fe.current),(0,F.j9)("resolutionReady",rt,"event",fe.current),(0,F.j9)("contextmenu",ut,"element",fe.current),(0,u.useEffect)((()=>{var a,r,s,l;const c=(0,y.zj)(be.current,xe.current,e,t,Q,i,o,Z,J,re,ee,ae,null==ne?void 0:ne.vqscore,Ce,Te,ce,n),d=ye.current;if((0,_.Tb)(W,"usePlayer0",Q,null===(a=fe.current)||void 0===a?void 0:a.uuid,d,re,J,o,`userResolution:${n}`),!fe.current){const e=we.current;fe.current=e.usePlayer(c,d),Oe(fe.current.uuid)}const u=fe.current;if(!u||!he.current||!u.element)return;_e.current&&_e.current.attach(u.element);const g=Ce.open||!1,b=Ce.closePreload;h.Tz.updateConfig({quality:Ce.qualityType,hevcQuality:Ce.hevcQualityType});const w=f._.getXgPayloadsAll();if((0,_.Tb)(G,"xgPreloaderPayloads",Q,null==Z?void 0:Z.log_id,w.map((e=>e.data.vid)),"preloadConfig",{maxQueueCount:null==ce||null===(r=ce.playerPreload)||void 0===r?void 0:r.maxQueueCount,preloadTime:null==ce||null===(s=ce.playerPreload)||void 0===s?void 0:s.preloadTime}),!b){(0,F.$v)(we.current,g?"h265":"h264");const{hevcIgnoreEnv:e}=ce;(0,F.DN)(we.current,w,Q,e)}return d===m.R.ACTIVE&&(u.forceAutoplay=!0),u.muted=re||!1,u.volume=J||1,null===(l=u.event)||void 0===l||l.on("preloaderInfoReady",lt),u.on("autoplay_was_prevented",dt),we.current.mountDom(u,he.current),()=>{var e,t,n,i;if(!u||!u.element||!u.element.parentNode)return;null===(e=u.event)||void 0===e||e.off("preloaderInfoReady",lt),null==u||u.off("autoplay_was_prevented",dt),(0,_.Tb)(W,"releasePlayer",Q,"removeChild",null===(t=fe.current)||void 0===t?void 0:t.uuid,`playerState:${d}`);const o=we.current;null==o||o.releasePlayer(fe.current||null),fe.current=null,null===(n=_e.current)||void 0===n||n.detach(),null===(i=_e.current)||void 0===i||i.destroy(),_e.current=null,(0,p.uQ)(v.Y.PlayerDestroy)}}),[Q]),(0,u.useEffect)((()=>{function e(){const e=Ce.open||!1;if(!Ce.closePreload){const t=f._.getXgPayloadsAll();(0,F.$v)(we.current,e?"h265":"h264");const{hevcIgnoreEnv:n}=ce;(0,F.DN)(we.current,t,Q,n)}}return f._.on("resourceUpdated",e),()=>{f._.off("resourceUpdated",e)}}),[]),(0,u.useEffect)((()=>(window.multimediaPool=we.current,g.M.setHevcEffectiveConditions(U),()=>{var e;(0,_.Tb)(W,"releasePlayer]111",Q,null===(e=fe.current)||void 0===e?void 0:e.uuid,`playerState:${ye.current}`),fe.current&&(we.current.releasePlayer(fe.current),fe.current=null)})),[]),(0,u.useEffect)((()=>{const e=g.M.getInstance();e.channelInfo=(null==ae?void 0:ae.tea)||null;const{region:t="",webId:n="",isLogin:i=!1}=ae||{};e.regionInfo={region:t,uid:n,isLogin:i},e.abTestVersion=(null==ae?void 0:ae.abTestVersion)||"",e.hevcAbVersion=(null==ae?void 0:ae.hevcAbTestVersion)||"",e.isTTP=null==ae?void 0:ae.isTTP}),[ae]),(0,u.useEffect)((()=>{g.M.pageName=(null==ne?void 0:ne.pathId)||"",g.M.playMode=B(X)}),[ne,X]),(0,u.useEffect)((()=>{const e=(0,y.J)(Z);f._.updateDefaultDefinition(e)}),[Z]),(0,u.useEffect)((()=>{fe.current&&te&&(fe.current.playbackRate=te)}),[te]),(0,u.useEffect)((()=>{fe.current&&(fe.current.muted=re||!1)}),[re]),(0,u.useEffect)((()=>{fe.current&&J&&(fe.current.volume=J)}),[J]),(0,u.useEffect)((()=>()=>{st()}),[st]),(0,u.useImperativeHandle)(me,(()=>({play:()=>{var e,t;return(0,_.Tb)(G,"play",null===(e=fe.current)||void 0===e?void 0:e.uuid,ye.current,ye.current!==m.R.ACTIVE),fe.current&&ye.current===m.R.ACTIVE?(null===(t=we.current)||void 0===t||t.callPlay(),fe.current.play()):Promise.resolve()},replay:()=>{var e;(0,_.Tb)(G,"replay",null===(e=fe.current)||void 0===e?void 0:e.uuid,ye.current),fe.current&&fe.current.replay()},pause:()=>{var e;(0,_.Tb)(G,"pause",null===(e=fe.current)||void 0===e?void 0:e.uuid,ye.current),fe.current&&(ie&&ie.triggerPause({enter_method:"click_pause",playMode:X||O.ey.OneColumn,group_id:Q}),fe.current.pause())},load:e=>{var t;(0,_.Tb)(G,"load",null===(t=fe.current)||void 0===t?void 0:t.uuid,ye.current),fe.current&&fe.current.load(e)},mute:e=>{var t;(0,_.Tb)(G,"mute",null===(t=fe.current)||void 0===t?void 0:t.uuid,ye.current),fe.current&&(fe.current.muted=e)},style:(e,t)=>{fe.current&&fe.current.style(e,t)},seek:e=>{var t;(0,_.Tb)(G,"seek",null===(t=fe.current)||void 0===t?void 0:t.uuid,ye.current),fe.current&&fe.current.seek(e)},addSubtitle:(e,t)=>{fe.current},buffered:()=>fe.current&&fe.current.buffered||new TimeRanges,getAttributes:()=>{var e;return(null===(e=fe.current)||void 0===e?void 0:e.attributes)||w},getPlayerType:()=>fe.current?fe.current.type:"",getPlaybackQuality:()=>fe.current?fe.current.getVideoPlaybackQuality():b,bindEvent:(e,t)=>{var n;(0,_.Tb)(G,"bindEvent",null===(n=fe.current)||void 0===n?void 0:n.uuid,ye.current,e),fe.current&&fe.current.element&&fe.current.element.addEventListener(e,t)},enterFullscreen:e=>fe.current?fe.current.enterFullscreen(e):Promise.resolve(),exitFullscreen:e=>fe.current?fe.current.exitFullscreen(e):Promise.resolve(),updatePlayer:e=>{var t;fe.current&&(null===(t=we.current)||void 0===t||t.updatePlayer(fe.current,e))},changeResolution:e=>{var t;fe.current&&(null===(t=we.current)||void 0===t||t.changeResolution(fe.current,e))},getResolutionInfo:()=>{var e;return fe.current?null===(e=we.current)||void 0===e?void 0:e.getResolutionInfo(fe.current):null},getVideoInfo:()=>Ue,setVolume:e=>{fe.current&&(fe.current.volume=e)},setPlaybackRate:e=>{fe.current&&(fe.current.playbackRate=e)}})),[Ue,ie,X]);const pt=(0,_.aZ)();return(0,c.jsx)("div",{className:"xgplayer-container tiktok-web-player playback_refactor",ref:he,children:(0,c.jsx)("div",{children:pt?(0,c.jsxs)("div",{className:"playeridtag",style:H,children:[Ae,"_",null===(ge=fe.current)||void 0===ge?void 0:ge.state,"_",Pe?"hitPreload":""]}):""})})})));function Y(){return g.M.getDeviceScore()}},37085:(e,t,n)=>{"use strict";n.d(t,{J:()=>m,fU:()=>p,pQ:()=>h,zj:()=>y});var i=n(90184),o=n(74745),a=n(78519),r=n(14583);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e){for(var t=1;t{const t=[],n=[];return e&&e.forEach((e=>{const i={qualityType:e.QualityType,gearName:e.GearName};e.CodecType.indexOf("h265")>=0?n.push(i):t.push(i)})),{h264Set:t,h265Set:n}};function m(e){return e&&e.videoQuality&&e.definition?`${e.videoQuality}_${e.definition.substring(0,e.definition.length-1)}_0`:"unknown_definition_from_xgpreload_config"}function g(e,t){return e&&0!==e.length?e.map((e=>{var t,n,i,o,a,r;const s=(null===(t=e.PlayAddr)||void 0===t?void 0:t.UrlList)||[];return{bitrate:e.Bitrate,size:(null===(n=e.PlayAddr)||void 0===n?void 0:n.DataSize)||0,width:(null===(i=e.PlayAddr)||void 0===i?void 0:i.Width)||0,height:(null===(o=e.PlayAddr)||void 0===o?void 0:o.Height)||0,fileId:(null===(a=e.PlayAddr)||void 0===a?void 0:a.FileHash)||"",uri:(null===(r=e.PlayAddr)||void 0===r?void 0:r.Uri)||"",codecType:(l=e.CodecType,l.includes("h265")?"h265":"h264"),gearName:e.GearName,definition:e.GearName,qualityType:e.QualityType,mvmaf:e.MVMAF||"",url:s.map((e=>({src:e}))),vtype:"MP4"};var l})):[{codecType:"h264",url:t.url?[{src:t.url}]:[],qualityType:t.qualityType||0,definition:t.defaultDefinition||"default",bitrate:t.defaultBitrate||0,gearName:t.defaultDefinition||"default",vtype:"MP4"}]}function h(e=[],t=0,n,s=0,h=!0,f,y,b,w,x,T,k,S,E,A){let O,P=w,I="h264",C="",L="",j="",M=!1,N="",D="",R="",B=t,U="";const F=`TT-vCache-${n}`,V=(0,i.xU)(F),z=(null==k?void 0:k.openSrc)&&(!V||"h265"===V.codecType);C=m(f);const{qualityType:H,hevcQualityType:q}=k||{qualityType:20,hevcQualityType:28},G=function(e=[],t=!1,n=20,i=28){const o=_(e,"h264",n),a=_(e,"h265",i);let r=o;return!p()&&t&&a&&(r=a),{h264Source:o,h265Source:a,source:r}}(e,z,H,q),$=G.source,W="h265"===(null==$?void 0:$.codecType)?G.h264Source:null,Z=g(e,{defaultBitrate:t,defaultDefinition:C,url:w}),{h264Set:Y,h265Set:K}=v(e),X=o.M.getABTest();let Q=P;if($&&(P=$.url.length>0?$.url[0].src:"",Q=(0,r.Mc)($.url),I=$.codecType,C=$.definition,B=$.bitrate,$.mvmaf&&(R=$.mvmaf.slice(1,-1),R=R.replace(/\\"/g,'"'))),P){const e=new URL(P);e.hostname&&(U=d[e.hostname]||"")}x&&(x.tea&&(O={channel:x.tea.channel,channel_domain:x.tea.domain,channel_type:x.tea.type}),x.region&&(L=x.region),x.webId&&(j=x.webId),void 0!==x.isLogin&&(M=x.isLogin),x.abTestVersion&&(N=x.abTestVersion),x.hevcAbTestVersion&&(D=x.hevcAbTestVersion));const J=u(P),ee=(null==E?void 0:E.playerPreload)||{},te=(null==x?void 0:x.extInfo)||{},ne=null==E?void 0:E.bitrateSelect,ie={selector:(null==ne?void 0:ne.selector)||"default",selectConfig:(null==ne?void 0:ne.config)||{},quality:null==ne?void 0:ne.qualityType,hevcQuality:null==ne?void 0:ne.hevcQualityType},oe=o.a.getHevcDisableInfo(),{gpuScoreData:ae,deviceScore:re,shortData:se}=o.b.markScore,{vendor:le,gpu:ce}=ae;return{enableSubtitle:!0,enablePreloader:!0,enableLogger:!0,preloader:c(l({minBufferLength:10,preloadCacheType:1,preloadMaxCacheCount:5,preloadTime:10,preloadSize:209715,segmentMinDuration:10,reqOptions:J},ee),{getRequestOptionsCallback:({url:e})=>u(e)}),mp4EncryptPlayer:{closeDowngrade:!1,minBufferLength:10,maxBufferLength:30,needPreloadRangeList:!0,needPreloadCheck:!0,needAutoBitrate:!0,removeBufferLen:60,resumePlayWaterLevel:0,segmentMinDuration:10,reqOptions:J,getRequestOptionsCallback:({url:e})=>u(e)},logger:{appId:548444,line_app_id:1988,playMode:o.M.playMode,playerCoreVersion:"",codec_type:I,tag:o.M.pageName,preTag:o.M.prePageName,preSubtag:o.M.prePlayMode,vid:n,region:L,webId:j,uid:(null==x?void 0:x.uid)||j,isLogin:M,abTestVersion:N,hevcAbTestVersion:D,channelConfig:O,d_score:re,gpu:ce,switchPlayerTime:S,vendor:le,bitrateSet:Y,bitrateSetHevc:K,pIndex:(null==x?void 0:x.vIndex)||-1,ext:c(l({},te,oe),{log_id:(null==f?void 0:f.log_id)||"none",is_ad:(null==f?void 0:f.isAd)?1:0}),deviceScore:se,strategyVersion:a.v},video:{codecType:I,defaultBitrate:B,defaultDefinition:C,definitionList:[],duration:s,autoplay:h,volume:null!=y?y:.7,muted:b||!1,vqscore:null!=T?T:0,mvmaf:R},extra:{h264BitrateList:z?[W]:[],url:P,actualUrl:Q,vid:F,ignores:["play","start"],reqAuth:U,closeMSE:(0,r.nT)(V,X,!!(null==k?void 0:k.closePreload))},hevcResult:k,bitrateList:Z,bitrateAdapter:c(l({},ie),{quality:H,hevcQuality:q,userSelectResolution:A||"auto"})}}function _(e=[],t,n){const i=e.filter((e=>e.CodecType.indexOf(t)>=0));i.sort(((e,t)=>e.Bitrate-t.Bitrate));let o=[];if(i.length>0&&(o=i.filter((e=>e.QualityType===n)),0===o.length&&o.push(i[0])),o.length>0){var a;const e=o[0],n=(null===(a=e.PlayAddr)||void 0===a?void 0:a.UrlList)||[];var r,s,l,c,d;if(n.length>0)return{bitrate:e.Bitrate,size:(null===(r=e.PlayAddr)||void 0===r?void 0:r.DataSize)||0,width:(null===(s=e.PlayAddr)||void 0===s?void 0:s.Width)||0,height:(null===(l=e.PlayAddr)||void 0===l?void 0:l.Height)||0,fileId:(null===(c=e.PlayAddr)||void 0===c?void 0:c.FileHash)||"",uri:(null===(d=e.PlayAddr)||void 0===d?void 0:d.Uri)||"",codecType:t,gearName:e.GearName,definition:e.GearName,qualityType:e.QualityType,mvmaf:e.MVMAF||"",url:n.map((e=>({src:e}))),vtype:"MP4"}}return null}const f=({url:e})=>u(e);function y(e,t,...n){return e?function(e=[],t=0,n,i=0,r=!0,s,d,p,h,_,y,b,w,x,T,k){const{channelInfo:S,regionInfo:E}=o.M.getInstance(),A=(null==b?void 0:b.open)?"h265":"h264",O=n,P=m(s),I=g(e,{defaultBitrate:t,defaultDefinition:P,url:h}),{h264Set:C,h265Set:L}=v(e),j=u(h),M={channel:null==S?void 0:S.channel,channel_domain:null==S?void 0:S.domain,channel_type:null==S?void 0:S.type},N=(null==E?void 0:E.region)||"",D=(null==E?void 0:E.uid)||"",R=(null==E?void 0:E.isLogin)||!1,B=(null==x?void 0:x.playerPreload)||{},U=(null==_?void 0:_.extInfo)||{},F=null==x?void 0:x.bitrateSelect,V={selector:(null==F?void 0:F.selector)||"default",selectConfig:(null==F?void 0:F.config)||{},quality:null==F?void 0:F.qualityType,hevcQuality:null==F?void 0:F.hevcQualityType},z=o.a.getHevcDisableInfo();return{playerType:"NEW_TT",playerConfig:{autoplay:r,volume:d,muted:p,playbackRate:1,codecType:A,vtype:"MP4",mp4EncryptPlayer:{closeDowngrade:!1,minBufferLength:10,maxBufferLength:30,needPreloadRangeList:!0,needPreloadCheck:!0,needAutoBitrate:!0,removeBufferLen:60,resumePlayWaterLevel:0,segmentMinDuration:10,reqOptions:j,getRequestOptionsCallback:f},getRequestOptionsCallback:f},strategyConfig:{enableSubtitle:!0,enablePreloader:"0"!==(null==k?void 0:k.preloader),enableLogger:!0,preloaderConfig:c(l({minBufferLength:10,preloadCacheType:1,preloadMaxCacheCount:5,preloadTime:10,preloadSize:209715,segmentMinDuration:10,reqOptions:j},B),{getRequestOptionsCallback:f}),bitrateAdapter:c(l({},V),{hevcQuality:(null==b?void 0:b.hevcQualityType)||28,quality:(null==b?void 0:b.qualityType)||20,userSelectResolution:T||"auto"}),videoPlayMode:(null==k?void 0:k.videoPlayMode)||"AUTO"},videoInfo:{vid:O,groupId:O,vtype:"MP4",codecType:"h264",definition:P||"",bitrate:t,width:0,height:0,url:h,duration:i,bitrateList:I,vqscore:null!=y?y:0,mvmaf:""},loggerParams:{lineAppId:1988,playerCoreVersion:"",codec_type:A,tag:o.M.pageName,preTag:o.M.prePageName,preSubtag:o.M.prePlayMode,subtag:o.M.playMode,vid:n,region:N,uid:(null==_?void 0:_.uid)||D,webId:D,isLogin:R,channelConfig:M,switchPlayerTime:w,bitrateSet:C,bitrateSetHevc:L,pIndex:(null==_?void 0:_.vIndex)||-1,ext:c(l({},U,z),{log_id:(null==s?void 0:s.log_id)||"",is_ad:(null==s?void 0:s.isAd)?1:0}),deviceScore:o.b.shortData,strategyVersion:a.v},envInfo:{tag:o.M.pageName,subtag:o.M.playMode,preTag:o.M.prePageName,preSubtag:o.M.prePlayMode,isLogin:R}}}(...n,t):h(...n,t)}},90184:(e,t,n)=>{"use strict";n.d(t,{$v:()=>p,AE:()=>l,Ah:()=>u,DN:()=>v,j9:()=>c,xU:()=>d});var i=n(40099),o=n(75420),a=n(74745);let r=null,s=null;function l(e){return e?(s||(s=new o.mx({enableReuse:!1,enableMultiple:!0,minBuffer:0,defaultMSE:!1})),s):(r||(r=new o.SN({enableReuse:!1,enableMultiple:!0,minBuffer:0,defaultMSE:!1})),r)}function c(e,t,n,o){t&&(0,i.useEffect)((()=>{if(!o)return;let i=null;const a=o.metrics,r=o.event;if("metrics"===n||"event"===n)"PlayEnded"===e?null==a||a.bind(e,t):"metrics"===n?null==a||a.on(e,t):null==r||r.on(e,t);else if("element"===n&&o.element){var s;i=e=>{t(e)},null===(s=o.element)||void 0===s||s.addEventListener(e,i)}return()=>{if(!o)return;const a=o.metrics,r=o.event;if("metrics"===n||"event"===n)"PlayEnded"===e?null==a||a.clear(e):"metrics"===n?null==a||a.off(e,t):null==r||r.off(e,t);else if("element"===n&&i){var s;null===(s=o.element)||void 0===s||s.removeEventListener(e,i)}}}),[t])}function d(e){return(null==r?void 0:r.getPreloadMeta(e))||null}const u={playerReuse:0,playerPreload:{vid:"v0",maxQueueCount:3,preloadMaxCacheCount:5,preloadTime:10,segmentMinDuration:10,minBufferLength:10,startPreloadControl:!1,startPreloadMinBuffer:0,startPreloadMinPosTime:0},hevcIgnoreEnv:0,hevcResultLocal:0,bitrateSelect:{vid:"v0",selector:"default",qualityType:20,hevcQualityType:14},playerUpgrade:{vid:"v0",playerType:"XG"},playerH265Soft:{vid:"v0",enableSoftwareH265:0},playerOpenMse:0},p=(e,t)=>{e&&e.updatePreloadCodec(t)},v=(e,t,n,i=0)=>{const o=a.M.checkHevcResult(1===i);e&&!o.closePreload&&t.length>0&&e.preloadResources(t)}},43485:(e,t,n)=>{"use strict";n.d(t,{_:()=>s});var i=class{register(e){this._events.includes(e)||this._events.push(e)}on(e,t){return!!this._events.includes(e)&&(this._callbacks[e]||(this._callbacks[e]=[]),this._callbacks[e].push(t),!0)}off(e,t){var n;if(!this._events.includes(e))return!1;const i=null===(n=this._callbacks[e])||void 0===n?void 0:n.indexOf(t);return void 0!==i&&i>=0&&(this._callbacks[e].splice(i,1),!0)}bind(e,t){return!!this._events.includes(e)&&(this._callbacks[e]=[t],!0)}clear(e){this._callbacks[e]&&(this._callbacks[e]=[])}trigger(e,t){if(!this._callbacks[e]||!this._callbacks[e].length)return!1;let n=null;return this._callbacks[e].forEach(((e,i)=>{0===i?n=e(t):e(t)})),n}set events(e){e.forEach((e=>{this.register(e)}))}get events(){return this._events}constructor(){this._events=[],this._callbacks={}}},o=n(37085);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e){for(var t=1;t{this.defaultDefinition=e},this.updateIndex=e=>{e<0||(this.index=e,this.range=[this.index+1,this.index+this.maxQueueCount+1])},this.updateIds=(e=[])=>{this.ids=e,this.updateItems()},this.getIds=()=>this.ids,this.updateItems=e=>{if(2!==this.range.length)return;e&&(this.items=e);const t=Object.keys(this.items);!this.ids.length&&t.length&&this.updateIds(t);const n=this.ids.slice(this.range[0],this.range[1]);this.h264Resources=[],this.h265Resources=[],this.resources=[],n.forEach(((e,t)=>{var n,i;const a=this.items[e];var s;const l=null!==(s=null==a||null===(n=a.video)||void 0===n?void 0:n.bitrateInfo)&&void 0!==s?s:[];let c=null,d=null;const u=[],p=[],v={vid:"TT-vCache-"+e,duration:(null==a||null===(i=a.video)||void 0===i?void 0:i.duration)||0,payload:[]};l.length?(l.forEach((t=>{var n,i,o,s,l,c;const d=null!==(c=null===(n=t.PlayAddr)||void 0===n?void 0:n.UrlList)&&void 0!==c?c:[null==a||null===(i=a.video)||void 0===i?void 0:i.playAddr];var m;const g={id:e,url:null!==(m=null===(o=t.PlayAddr)||void 0===o?void 0:o.UrlList)&&void 0!==m?m:[null==a||null===(s=a.video)||void 0===s?void 0:s.playAddr],definition:t.GearName,bitrate:t.Bitrate,duration:null==a||null===(l=a.video)||void 0===l?void 0:l.duration,codecType:t.CodecType.includes("h265")?"h265":"h264",vtype:"MP4",qualityType:t.QualityType||20};var h,_;"h264"===t.CodecType&&u.push(g),t.CodecType.indexOf("h265")>=0&&(g.codecType="h265",p.push(g)),v.payload.push((h=r({},g),_=null!=(_={url:d.map((e=>({src:e})))})?_:{},Object.getOwnPropertyDescriptors?Object.defineProperties(h,Object.getOwnPropertyDescriptors(_)):function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t}(Object(_)).forEach((function(e){Object.defineProperty(h,e,Object.getOwnPropertyDescriptor(_,e))})),h))})),u.forEach(((e,t)=>{(0===t||c&&Math.abs(e.qualityType-25){(0===t||d&&Math.abs(e.qualityType-25)!(0,o.fU)()&&e?this.h265Resources:this.h264Resources,this.getXgPayloads=(e=!1)=>this.getResources(e).map(((e,t)=>{var n;return{order:t,data:{codecType:e.codecType,preloadTime:8,vid:"TT-vCache-"+e.id,payload:[{bitrate:e.bitrate,definition:e.definition,duration:e.duration,url:null===(n=e.url)||void 0===n?void 0:n.map((e=>({src:e})))}]}}})),this.getXgPayloadsAll=()=>{const{resources:e}=this;return e.map(((e,t)=>({order:t,data:r({},e)})))},this.updateMaxQueueCount=e=>{this.maxQueueCount=e},this.reset=()=>{this.ids=[],this.range=[],this.h264Resources=[],this.h265Resources=[],this.resources=[],this.items={},this.index=0},this.setTemporaryCallback=()=>{(0,o.fU)()||window.videoChangedCallback||(window.videoChangedCallback=e=>{this.updateIndex(e)})},this.ids=[],this.maxQueueCount=3,this.range=[],this.h264Resources=[],this.h265Resources=[],this.resources=[],this.index=0,this.defaultDefinition="",this.items={},this.updateIndex(0),this.events=["resourceUpdated"]}};s.setTemporaryCallback()},14583:(e,t,n)=>{"use strict";n.d(t,{$m:()=>p,Mc:()=>a,Tb:()=>s,aZ:()=>l,nT:()=>r,vA:()=>u});var i=n(12323);let o=-1;function a(e){return e.length<1?"":e.length<2?e[0].src:e}function r(e,t,n){return!!n||!e}function s(e,...t){o<0&&(o=location.search.includes("ttplayer_debug=1")?1:0),o&&console.log(`[MultiMedia][${e}]`,...t)}function l(){return o>0}const c={player_type:"playerType",video_play_mode:"videoPlayMode",preloader:"preloader",muted:"muted"};let d=null;function u(){if(d)return d;const e={playerType:"",videoPlayMode:"",preloader:""},t=(location.search||"").replace("?","").split("&");for(let n=0;n{"use strict";var i,o,a,r,s,l,c,d;n.d(t,{V7:()=>B,PY:()=>c,tH:()=>R,Wk:()=>M,Q_:()=>j,Gy:()=>U}),(o=i||(i={})).CUSTOM="CUSTOM",o.ACTUAL_FMP="ACTUAL_FMP",(r=a||(a={})).ABORT="ABORT",r.CRASH="CRASH",(l=s||(s={})).normal="normal",l.noRecord="noRecord",l.noInternet="noInternet",l.error="error",(d=c||(c={})).START="START",d.IN_PROGRESS="IN_PROGRESS",d.FAILURE="FAILURE",d.FINISH="FINISH",d.ABORT="ABORT";const u=()=>"undefined"==typeof window||void 0===window.performance||"function"!=typeof window.performance.getEntriesByType?{}:[...window.performance.getEntriesByType("mark").filter((e=>e.name.startsWith("pns_privacy_product_mark"))),...window.performance.getEntriesByType("measure").filter((e=>e.name.startsWith("pns_privacy_product_duration")))].map((e=>({duration:e.duration,entryType:e.entryType,name:e.name,startTime:e.startTime}))).reduce(((e,t)=>(e[t.name]="mark"===t.entryType?Math.floor(t.startTime):Math.floor(t.duration),e)),{}),p=()=>{if("undefined"==typeof window||void 0===window.performance||"function"!=typeof window.performance.measure||"function"!=typeof window.performance.getEntriesByName)return-1;window.performance.measure("DCL","fetchStart","domContentLoadedEventEnd");const e=window.performance.getEntriesByName("DCL");return e.length>0?e[0].duration:-1},v=(e,t,n)=>{((e,t)=>{if(!t)return;const n={method:e,params:t};if("undefined"!=typeof NativeModules){var i,o;const e=null===(o=NativeModules)||void 0===o||null===(i=o.hybridMonitor)||void 0===i?void 0:i.request;return void(null==e||e(n,(()=>{})))}const a=(()=>{var e;let t="unknown";var n;const i=null!==(n=null===(e=navigator)||void 0===e?void 0:e.userAgent)&&void 0!==n?n:"";return/android|Android/i.test(i)&&(t="Android"),/iPhone|iPad|iPod|iOS/i.test(i)&&(t="iOS"),{os:t,isAndroid:"Android"===t,isIOS:"iOS"===t}})();var r,s,l,c,d;if(a.isIOS)null===(d=window)||void 0===d||null===(c=d.webkit)||void 0===c||null===(l=c.messageHandlers)||void 0===l||null===(s=l.bdhmRequest)||void 0===s||null===(r=s.postMessage)||void 0===r||r.call(s,n);else if(a.isAndroid){var u,p,v;null===(v=window)||void 0===v||null===(p=v.iesJsBridgeTransferMonitor)||void 0===p||null===(u=p.request)||void 0===u||u.call(p,JSON.stringify(n))}})("timing.mark",{key:e,value:void 0===t?Date.now():t,description:n||""})},m=(e,t="")=>"undefined"==typeof location||"undefined"==typeof URLSearchParams?"":new URLSearchParams(location.search).get(e)||t,g=()=>{var e,t;return{scm_version:"undefined"==typeof window?"":null!==(t=null===(e=window.gfdatav1)||void 0===e?void 0:e.ver)&&void 0!==t?t:"",path:"undefined"==typeof location?"":location.pathname,enter_from:m("enter_from"),host:"undefined"==typeof location?"":location.host}};function h(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _(e){for(var t=1;t=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}const y={pageCrash:!1,cuj:!1};class b{constructor(){this.slardarWindowGlobalName="",this.slardarHybridGlobalName="",this._shouldReportJSError={pageCrash:!1,cuj:!1},this.initSlardar=e=>{try{const{slardarContainer:t,slardarWindowGlobalName:n,slardarHybridGlobalName:i,sparkMonitor:o,reportActualFMP:a,shouldReportJSError:r}=null!=e?e:{};"string"==typeof n&&(this.slardarWindowGlobalName=n),"string"==typeof i&&(this.slardarHybridGlobalName=i),"function"==typeof a&&(this.reportTTAPActualFMP=a),void 0!==o&&(this.sparkMonitor=o),void 0!==t&&"function"==typeof t.sendEvent&&"function"==typeof t.reportActualFMP&&(this.slardarContainer=t),this._shouldReportJSError=_({},y,null!=r?r:{})}catch(e){}},this.initJSB=e=>{this.jsbBridge=e},this.sendEvent=e=>{try{var t,n;if(this.slardarWindowGlobalName&&"function"==typeof(null===(t=window)||void 0===t?void 0:t[this.slardarWindowGlobalName])&&window[this.slardarWindowGlobalName]("sendEvent",null!=e?e:{}),this.slardarHybridGlobalName&&"function"==typeof(null===(n=window)||void 0===n?void 0:n[this.slardarHybridGlobalName])){const t=null!=e?e:{},{name:n="",categories:i}=t,o=f(t,["name","categories"]);window[this.slardarHybridGlobalName]("emit","custom",_({eventName:n,level:0,category:i},o))}this.slardarContainer&&this.slardarContainer.sendEvent(e)}catch(e){}},this._sendError=(e,t)=>{if(this._shouldReportJSError)try{var n,i;if(this.slardarWindowGlobalName&&"function"==typeof(null===(n=window)||void 0===n?void 0:n[this.slardarWindowGlobalName])&&window[this.slardarWindowGlobalName]("captureException",e,t),this.slardarHybridGlobalName&&"function"==typeof(null===(i=window)||void 0===i?void 0:i[this.slardarHybridGlobalName])){const n=null!=t?t:{},{name:i=""}=n,o=f(n,["name"]);window[this.slardarHybridGlobalName]("captureException",e,_({eventName:i,level:0},o))}this.slardarContainer&&"function"==typeof this.slardarContainer.captureException&&this.slardarContainer.captureException(e,t)}catch(e){}},this.sendPageCrashError=(e,t)=>{this._shouldReportJSError.pageCrash&&this._sendError(e,t)},this.sendCUJError=(e,t)=>{this._shouldReportJSError.cuj&&this._sendError(e,t)},this.teaReport=e=>{var t,n;"undefined"!=typeof window&&"function"==typeof(null===(t=window)||void 0===t?void 0:t.collectEvent)&&(null===(n=window)||void 0===n||n.collectEvent(e.name,_({},e.metrics,e.categories,g()))),this.jsbBridge&&this.jsbBridge.x.reportAppLog({eventName:e.name,params:_({},e.metrics,e.categories,g())})},this.resetTeaModule=()=>{this.jsbBridge=void 0},this.resetSlardarModule=()=>{this.slardarContainer=void 0,this.slardarWindowGlobalName="",this.slardarHybridGlobalName="",this.sparkMonitor=void 0,this.reportTTAPActualFMP=void 0}}}var w,x,T;(T=x||(x={})).FBJS="pns_privacy_product_mark_fbjs",T.AFMP="pns_privacy_product_mark_afmp";const k=(null===(w=performance.timing)||void 0===w?void 0:w.navigationStart)||performance.timeOrigin;function S(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function E(e){for(var t=1;t{var e,t,n,i;if(this._hasReportedFBJS)return;this._hasReportedFBJS=!0;const o=Date.now();window.TTAP_APPPARSE_STARTTIME=o,"function"==typeof(null===(e=this._trackingContext.sparkMonitor)||void 0===e?void 0:e.mark)?this._trackingContext.sparkMonitor.mark("fbjs"):this._trackingContext.slardarHybridGlobalName&&"function"==typeof(null===(t=window)||void 0===t?void 0:t[this._trackingContext.slardarHybridGlobalName])&&v("fbjs"),null===(i=performance)||void 0===i||null===(n=i.mark)||void 0===n||n.call(i,"pns_privacy_product_mark_fbjs"),this._trackingContext.sendEvent({name:x.FBJS,metrics:{cost_ms:o-k},categories:E({},g())})},this.reportActualFMP=(e=s.normal)=>{var t,n,i,o;if(this._hasReportedActualFMP)return;this._hasReportedActualFMP=!0;const a=[s.normal,s.noRecord].includes(e),r=Date.now();var l,c,d,m,h,_;if(null===(n=performance)||void 0===n||null===(t=n.mark)||void 0===t||t.call(n,"pns_privacy_product_mark_afmp"),a)if("function"==typeof(null===(l=this._trackingContext.sparkMonitor)||void 0===l?void 0:l.mark)?this._trackingContext.sparkMonitor.mark("fmp"):this._trackingContext.slardarHybridGlobalName&&"function"==typeof(null===(c=window)||void 0===c?void 0:c[this._trackingContext.slardarHybridGlobalName])&&v("fmp"),"function"==typeof(null===(d=this._trackingContext)||void 0===d?void 0:d.reportTTAPActualFMP))this._trackingContext.reportTTAPActualFMP();else if(this._trackingContext.slardarWindowGlobalName&&"function"==typeof(null===(m=window)||void 0===m?void 0:m[this._trackingContext.slardarWindowGlobalName])){var f;(null===(f=window)||void 0===f?void 0:f[this._trackingContext.slardarWindowGlobalName])("sendCustomPerfMetric",{name:"actual_fmp",value:r-k})}this._trackingContext.slardarHybridGlobalName&&"function"==typeof(null===(i=window)||void 0===i?void 0:i[this._trackingContext.slardarHybridGlobalName])&&(null===(_=window)||void 0===_||null===(h=_[this._trackingContext.slardarHybridGlobalName])||void 0===h||h.call(_,"sendCustomPerfMetric",{name:"actual_fmp",value:r-k})),this._trackingContext.sendEvent({name:x.AFMP,metrics:A(E({costMs:r-k},u()),{pns_privacy_product_mark_dcl:p()}),categories:E({isSuccess:a?"1":"0",scene:e},g())}),this._trackingContext.teaReport({name:x.AFMP,metrics:A(E({costMs:r-k},u()),{pns_privacy_product_mark_dcl:p()}),categories:{isSuccess:a?"1":"0",scene:e}}),"function"==typeof(null===(o=this._trackingContext.slardarContainer)||void 0===o?void 0:o.reportActualFMP)&&this._trackingContext.slardarContainer.reportActualFMP()},this._trackingContext=e}}const P=()=>{var e,t,n;return(null===(t=performance)||void 0===t||null===(e=t.timing)||void 0===e?void 0:e.navigationStart)||(null===(n=performance)||void 0===n?void 0:n.timeOrigin)},I=()=>{window._bound_error_time||(window._bound_error_time=!0,(()=>{var e;if(null===(e=console)||void 0===e?void 0:e.error){const e=console.error;console.error=(t,...n)=>{(e=>{let t=0;try{performance.mark("error"),t=performance.measure("navigationStart_to_error","navigationStart","error").duration,performance.clearMarks("error"),performance.clearMeasures("navigationStart_to_error")}catch(e){t=Date.now()-P()}"object"==typeof e&&(e._triggerTime=t)})(t),e.apply(void 0,[t,...n])}}})())};class C{resetForSPA(){this._hasReportedPageReady=!1,this._hasReportedPageCrash=!1,this._hasReportedUserDrop=!1,this._pageReadyTimestamp=-1,this._cuj={}}constructor(e){this._hasReportedPageReady=!1,this._hasReportedPageCrash=!1,this._hasReportedUserDrop=!1,this._pageReadyTimestamp=-1,this._cuj={},this.reportPageReady=()=>{if(this._hasReportedPageReady||this._hasReportedUserDrop||this._hasReportedPageCrash)return;this._hasReportedPageReady=!0;let e=0;try{performance.mark("pageReady"),e=performance.measure("navigationStart_to_pageReady","navigationStart","pageReady").duration}catch(t){e=Date.now()-P()}this._pageReadyTimestamp=e,this._trackingContext.sendEvent({name:"page_ready",metrics:{time:e}})},this.reportUserDrop=()=>{if(this._hasReportedPageReady||this._hasReportedUserDrop)return;this._hasReportedUserDrop=!0;let e=0;try{performance.mark("userDrop"),e=performance.measure("navigationStart_to_userDrop","navigationStart","userDrop").duration}catch(t){e=Date.now()-P()}this._trackingContext.sendEvent({name:"user_drop",metrics:{time:e},categories:{reason:this._hasReportedPageCrash?a.CRASH:a.ABORT}})},this.reportPageCrash=(e,t=!1,n)=>{var i,o,a;if(this._hasReportedUserDrop||this._hasReportedPageCrash)return;this._hasReportedPageCrash=!0;const{name:r="",message:s,stack:l,_triggerTime:c=0}=null!=e?e:{};let d=0;if(!d)try{performance.mark("pageCrashReporting"),d=performance.measure("navigationStart_to_pageCrashReporting","navigationStart","pageCrashReporting").duration}catch(e){d=Date.now()-P()}const u=t?c:d,p=u{var i,o;const a=`cuj_${e}_${c.START}`,r=`cuj_${e}_${t}`.replace(/\s/g,"_");let s=0,l=0;try{performance.mark(r),s=performance.measure(`navigationStart_to_${r}`,"navigationStart",r).duration,l=performance.measure(`${a}_to_${r}`,a,r).duration}catch(n){if(s=Date.now()-P(),t===c.START)this._cuj[e]={[c.START]:Date.now()},l=0;else{if(!this._cuj[e])return;var d;this._cuj[e][t]=Date.now(),l=this._cuj[e][t]-(null!==(d=this._cuj[e][c.START])&&void 0!==d?d:0)}}const{error:u,detail:p,stepName:v}=null!=n?n:{};var m;const g="string"==typeof u?u:null!==(m=null==u?void 0:u.toString())&&void 0!==m?m:"";var h;const _=p||(null!==(h=null==u?void 0:u.stack)&&void 0!==h?h:"");var f,y;this._trackingContext.sendEvent({name:"pns_cuj",metrics:{timestamp:s,duration:l},categories:{status:t,name:e,stepName:v,error:null!==(f=null==g||null===(i=g.substring)||void 0===i?void 0:i.call(g,0,256))&&void 0!==f?f:"",detail:null!==(y=null==_||null===(o=_.substring)||void 0===o?void 0:o.call(_,0,256))&&void 0!==y?y:""}}),t===c.FAILURE&&u&&this._trackingContext.sendCUJError(u,{stepName:v,cujName:e,status:t,name:"pns_cuj"})},this._trackingContext=e}}const L={},j=(e="")=>{let t=!1;class n{resetForSPA(){this._stabilityTracker.resetForSPA(),this._perfTracker.resetForSPA()}reset(){this.resetForSPA(),t=!1,this._trackingContext.resetSlardarModule(),this._trackingContext.resetTeaModule()}isInitialized(){return t}constructor(e=""){let o;return this._pageReadyTiming=i.ACTUAL_FMP,this.init=e=>{try{if(t)return;t=!0;const{slardarContainer:n,slardarWindowGlobalName:o,slardarHybridGlobalName:a,sparkMonitor:r,reportActualFMP:s,pageReadyTiming:l=i.CUSTOM,jsbBridge:c,shouldReportJSError:d={},shouldRegisterUserDrop:u=!0}=null!=e?e:{};this._pageReadyTiming=l,this._trackingContext.initSlardar({slardarContainer:n,slardarWindowGlobalName:o,slardarHybridGlobalName:a,sparkMonitor:r,reportActualFMP:s,shouldReportJSError:d}),c&&this._trackingContext.initJSB(c),I(),u&&this._registerUserDropEvent()}catch(e){}},this._registerUserDropEvent=()=>{window.addEventListener("beforeunload",this.reportUserDrop,!0)},this.reportPageReady=e=>{this._stabilityTracker.reportPageReady(),this._pageReadyTiming===i.ACTUAL_FMP&&this._perfTracker.reportActualFMP(e)},this.reportUserDrop=()=>{this._stabilityTracker.reportUserDrop()},this.reportPageCrash=(e,t=!1,n)=>{this._stabilityTracker.reportPageCrash(e,t,n)},this.reportFBJS=()=>{this._perfTracker.reportFBJS()},this.reportActualFMP=e=>{this._perfTracker.reportActualFMP(e)},this.reportCUJ=(e,t,n)=>{this._stabilityTracker.reportCUJ(e,t,n)},e?(L[e]=this,o=this):(n._instance||(n._instance=this),o=n._instance),this._trackingContext=new b,this._perfTracker=new O(this._trackingContext),this._stabilityTracker=new C(this._trackingContext),o}}return e?(L[e]||(L[e]=new n(e)),L[e]):new n},M=j();var N=n(24643),D=n(40099);class R extends D.Component{static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(e,t){!1!==this.props.shouldReport&&M.reportPageCrash(e,!0,t.componentStack),this.props.onError&&this.props.onError(e,t)}render(){var e;return this.state.hasError?null!==(e=this.props.fallback)&&void 0!==e?e:(0,N.jsx)("div",{}):this.props.children}constructor(e){super(e),this.state={hasError:!1}}}const B=({children:e,cujName:t,shouldReportPageCrush:n=!1,fallback:i})=>{const o=(0,D.useCallback)((e=>{t&&M.reportCUJ(t,c.FAILURE,{error:e})}),[t]);return(0,N.jsx)(R,{shouldReport:n,fallback:i,onError:o,children:e})},U=()=>{(0,D.useEffect)((()=>{setTimeout((()=>{M.reportPageReady()}),0)}),[])}},47172:(e,t,n)=>{"use strict";n.d(t,{CompatRouter:()=>_,CustomRouterContext:()=>r,Link:()=>u,Prompt:()=>p,getRouterState:()=>b,matchPath:()=>d,useHistory:()=>s,useLocation:()=>l,useRouteError:()=>f,useRouteMatch:()=>c});var i=n(40099),o=n(11060),a=n(99179);const r=(0,i.createContext)(null);function s(){const e=(0,i.useContext)(r),t=(0,o.W6)();var n;return null!==(n=null==e?void 0:e.history)&&void 0!==n?n:t}function l(){const e=(0,i.useContext)(r),t=(0,o.zy)();var n;return null!==(n=null==e?void 0:e.location)&&void 0!==n?n:t}(0,i.createContext)(null);const c=o.W5,d=o.B6,u=a.N_,p=o.XG;var v=n(24643),m=n(26475),g=n(79948),h=n.n(g);const _=({createRouter:e,historyPaths:t,children:n})=>{if(e)throw new Error("Can't pass createRouter in react-router v5.");const i=function(e,t){const n=(0,m.zR)(t);function i(t){return(i,o)=>{const{pathname:a,href:r}=function(e){if("string"==typeof e){const t=new URL(e,window.location.origin);return{pathname:t.pathname,href:t.href}}const{pathname:t="",search:n="",hash:i=""}=e;return{pathname:t,href:`${t}${n}${i}`}}(i);!function(e,t){return t.some((t=>h()(t).test(e)))}(a,e)?t?window.location.replace(r):window.location.assign(r):t?n.replace(i,o):n.push(i,o)}}return Object.create(n,{push:{enumerable:!0,value:i(!1)},replace:{enumerable:!0,value:i(!0)}})}(null!=t?t:[]);return(0,v.jsx)(o.Ix,{history:i,children:n})},f=()=>{throw new Error("useRouteError is not supported in react-router v5")},y="state";function b(){const e=window.history.state;return null==e?void 0:e[y]}},14713:(e,t,n)=>{"use strict";n(37685),console.info("Reflect is polyfilled, using `@abraham/reflection`.")},243:function(e){e.exports=function(){"use strict";function e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function t(e,t){for(var n=0;ne.length)&&(t=e.length);for(var n=0,i=new Array(t);no)return 1;if(i"===t&&i>0||">="===t&&i>=0||"<"===t&&i<0||"<="===t&&i<=0},c=function(){function t(){e(this,t),this._methodRuleMap={}}return n(t,[{key:"registerMethodRules",value:function(e){var t=e.map,n=void 0===t?"":t,i=e.target,o=void 0===i?[]:i;n?this._methodRuleMap[n]=o:r.error("register method rules error")}},{key:"getRuntimeOS",value:function(){return function(){if(s())return"ssr";var e="Win32"===(null===navigator||void 0===navigator?void 0:navigator.platform)||"Windows"===(null===navigator||void 0===navigator?void 0:navigator.platform),t="Mac68K"===(null===navigator||void 0===navigator?void 0:navigator.platform)||"MacPPC"===(null===navigator||void 0===navigator?void 0:navigator.platform)||"Macintosh"===(null===navigator||void 0===navigator?void 0:navigator.platform)||"MacIntel"===(null===navigator||void 0===navigator?void 0:navigator.platform),n="X11"===(null===navigator||void 0===navigator?void 0:navigator.platform)&&!e&&!t,i=String(null===navigator||void 0===navigator?void 0:navigator.platform).indexOf("Linux")>-1;return t?"mac":n?"unix":i?"linux":e?"windows":"unknown"}()}},{key:"getRuntimeVersion",value:function(){var e,t,n;return s()?(r.error("can't get client version in ssr"),""):(null===(n=null===(t=null===(e=null===window||void 0===window?void 0:window.TTE_ENV)||void 0===e?void 0:e.initPageStore)||void 0===t?void 0:t.page)||void 0===n?void 0:n.version)||""}},{key:"checkOS",value:function(e){return!e||"*"===e||this.getRuntimeOS()===e}},{key:"checkMethodAvailable",value:function(e){var t,n,i;return!!this.checkInClient()&&void 0!==(null===(i=null===(n=null===(t=null===window||void 0===window?void 0:window.TTE_ENV)||void 0===t?void 0:t.bridge)||void 0===n?void 0:n.EVENTS)||void 0===i?void 0:i.TO_MAIN_EVENT_TYPES[e])}},{key:"canIUse",value:function(e){return{code:0,data:{isAvailable:this.checkMethodAvailable(e)}}}},{key:"checkVersion",value:function(e){return!e||function(e,t){var n=i(t.split("-"),2),o=n[0],a=void 0===o?"":o,r=n[1],s=void 0===r?"":r;return!a&&!s||(a?s?l(e,">=",a)&&l(e,"<=",s):l(e,">=",a):l(e,"<=",s))}(this.getRuntimeVersion(),e)}},{key:"checkDetail",value:function(e){if(!e||0===e.length)return!0;var t,n=!1,i=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=o(e))){t&&(e=t);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,r=!0,s=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return r=e.done,e},e:function(e){s=!0,a=e},f:function(){try{r||null==t.return||t.return()}finally{if(s)throw a}}}}(e);try{for(i.s();!(t=i.n()).done;){var a=t.value.os;if(n=this.checkOS(a))break}}catch(e){i.e(e)}finally{i.f()}return n}},{key:"checkRule",value:function(e){var t=e.target,n=void 0===t?[]:t;return!e||!!this.checkDetail(n)}},{key:"on",value:function(e,t){return this.checkInClient()?window.TTE_ENV.bridge.on(e,t):(r.warn("turn on listening to ".concat(e," failed, env is not in client.")),!1)}},{key:"off",value:function(e,t){return this.checkInClient()?window.TTE_ENV.bridge.off(e,t):(r.warn("turn off listening to ".concat(e," failed, env is not in client.")),!1)}},{key:"checkInClient",value:function(){var e;return!s()&&void 0!==(null===(e=null===window||void 0===window?void 0:window.TTE_ENV)||void 0===e?void 0:e.bridge)}},{key:"call",value:function(e){var t=this,n=e.params,i=void 0===n?{}:n,o=e.method,a=e.rule,s=e.transParameters,l=void 0!==s&&s;return new Promise((function(e){var n={code:-9,data:null,msg:"Something went wrong. maybe polyfill."};try{if(!t.checkInClient()){var s="WARN:[".concat(o,"]The current environment is not inside the client.");return n.code=-2,n.msg=s,r.warn(s),void e(n)}if(!t.checkMethodAvailable(o)){var c="WARN: [".concat(o,"]The current system doesn't support this method.");return n.code=-3,n.msg=c,r.warn(c),void e(n)}if(!t.checkRule(a)){var d="WARN: [".concat(o,"]The method invocation environment does not meet the rules.");return n.code=-3,n.msg=d,r.warn(d),void e(n)}}catch(t){var u="Bridge SDK Inner Error: ".concat(o,"-{").concat(JSON.stringify(i),"}. ").concat(t.message," | ").concat(t.stack);return r.error(u),n.msg=u,n.code=-5,void e(n)}var p=l?i:{data:i};window.TTE_ENV.bridge.invoke(o,p).then((function(t){var i,o,a;void 0!==(null==t?void 0:t._to_sdk)?(n.code=null!==(i=t._to_sdk.code)&&void 0!==i?i:n.code,n.data=null!==(o=t.data)&&void 0!==o?o:null,n.msg=null!==(a=t._to_sdk.msg)&&void 0!==a?a:"success"):(n.code=0,n.data=t,n.msg="success"),e(n)})).catch((function(t){var a="Bridge SDK Execute Failed: ".concat(o,"-{").concat(JSON.stringify(i),"}}. ").concat(t.message," | ").concat(t.stack);n.code=-1,n.msg=t.message,r.error(a),e(n)}))}))}}]),t}(),d=new c;function u(e){Object.keys(e).forEach((function(t){var n,i=(null===(n=e[t])||void 0===n?void 0:n.rule)||{};d.registerMethodRules(i)}))}var p={target:[{os:"*"}],map:"app.getVersion"};function v(){return d.call({rule:p,method:"GET_VERSION"})}v.rule=p;var m={target:[{os:"*"}],map:"app.setAlwaysOnTop"};function g(e){return d.call({rule:m,method:"SET_ALWAYS_ON_TOP",params:e,transParameters:!0})}g.rule=m;var h={target:[{os:"*"}],map:"app.changeToOriginalMode"};function _(){return d.call({rule:h,method:"CHANGE_TO_ORIGINAL_MODE"})}_.rule=h;var f={target:[{os:"*"}],map:"app.changeToSmallMode"};function y(){return d.call({rule:f,method:"CHANGE_TO_SMALL_MODE"})}y.rule=f;var b={target:[{os:"*"}],map:"app.isAlwaysOnTop"};function w(){return d.call({rule:b,method:"IS_ALWAYS_ON_TOP"})}w.rule=b;var x={target:[{os:"*"}],map:"app.mainWindowMoveTop"};function T(){return d.call({rule:x,method:"MAIN_WINDOW_MOVE_TOP"})}T.rule=x;var k={target:[{os:"*"}],map:"app.minimize"};function S(){return d.call({rule:k,method:"WINDOW_MIN"})}S.rule=k;var E={target:[{os:"*"}],map:"app.handlePageReady"};function A(){return d.call({rule:E,method:"PAGE_READY"})}A.rule=E;var O={target:[{os:"*"}],map:"app.maximize"};function P(){return d.call({rule:O,method:"WINDOW_MAX"})}P.rule=O;var I={target:[{os:"*"}],map:"app.canGoBack"};function C(){return d.call({rule:I,method:"CAN_GO_BACK"})}C.rule=I;var L={target:[{os:"*"}],map:"app.clearCookie"};function j(){return d.call({rule:L,method:"CLEAR_COOKIE"})}j.rule=L;var M={target:[{os:"*"}],map:"app.getWid"};function N(){return d.call({rule:M,method:"GET_WID"})}N.rule=M;var D={target:[{os:"*"}],map:"app.closeParent"};function R(){return d.call({rule:D,method:"CLOSE_PARENT"})}R.rule=D;var B={target:[{os:"*"}],map:"app.closeWindow"};function U(){return d.call({rule:B,method:"WINDOW_CLOSE"})}U.rule=B;var F={target:[{os:"*"}],map:"app.getAllClientLog"};function V(){return d.call({rule:F,method:"GET_ALL_CLIENT_LOG"})}V.rule=F;var z={target:[{os:"*"}],map:"app.getAppConfigItem"};function H(e){return d.call({rule:z,method:"GET_APP_CONFIG_ITEM",params:e})}H.rule=z;var q={target:[{os:"*"}],map:"app.goBack"};function G(){return d.call({rule:q,method:"GO_BACK"})}G.rule=q;var $={target:[{os:"*"}],map:"app.getPageStore"};function W(){return d.call({rule:$,method:"GET_PAGE_STORE"})}W.rule=$;var Z={target:[{os:"*"}],map:"app.getSettings"};function Y(){return d.call({rule:Z,method:"GET_SETTINGS"})}Y.rule=Z;var K={target:[{os:"*"}],map:"app.isFull"};function X(){return d.call({rule:K,method:"WINDOW_IS_FULL"})}X.rule=K;var Q={target:[{os:"*"}],map:"app.openWallpaperWindow"};function J(){return d.call({rule:Q,method:"OPEN_WALLPAPER_WINDOW"})}J.rule=Q;var ee={target:[{os:"*"}],map:"app.getChannelId"};function te(){return d.call({rule:ee,method:"GET_CHANNEL_ID"})}te.rule=ee;var ne={target:[{os:"*"}],map:"app.reload"};function ie(){return d.call({rule:ne,method:"RELOAD"})}ie.rule=ne;var oe={target:[{os:"mac"}],map:"app.setFullScreenable"};function ae(e){return d.call({rule:oe,method:"SET_FULL_SCREENABLE",params:e,transParameters:!0})}ae.rule=oe;var re={target:[{os:"*"}],map:"app.getAllWindowData"};function se(){return d.call({rule:re,method:"GET_ALL_WINDOW_DATA"})}se.rule=re;var le={target:[{os:"*"}],map:"app.reloadWindowFromId"};function ce(){return d.call({rule:le,method:"RELOAD_FROM_ID"})}ce.rule=le;var de={target:[{os:"*"}],map:"app.reportStat"};function ue(e){return d.call({rule:de,method:"REPORT_STAT",params:e,transParameters:!0})}ue.rule=de;var pe={target:[{os:"*"}],map:"app.setAppConfigItem"};function ve(e){return d.call({rule:pe,method:"SET_APP_CONFIG_ITEM",params:e})}ve.rule=pe;var me={target:[{os:"*"}],map:"app.setAutoStart"};function ge(e){return d.call({rule:me,method:"SET_AUTO_START",params:e})}ge.rule=me;var he={target:[{os:"*"}],map:"app.setCloseToTray"};function _e(e){return d.call({rule:he,method:"SET_CLOSE_TO_TRAY",params:e})}_e.rule=he;var fe={target:[{os:"*"}],map:"app.setMiniMizeToTray"};function ye(e){return d.call({rule:fe,method:"SET_MINIMIZE_TO_TRAY",params:e})}ye.rule=fe;var be={target:[{os:"*"}],map:"app.showAbout"};function we(e){return d.call({rule:be,method:"WINDOW_SHOW_ABOUT",params:e})}we.rule=be;var xe={target:[{os:"*"}],map:"app.syncLoginState"};function Te(e){return d.call({rule:xe,method:"SYNC_LOGIN_STATE",params:e,transParameters:!0})}Te.rule=xe;var ke={target:[{os:"*"}],map:"app.themeChange"};function Se(e){return d.call({rule:ke,method:"THEME_CHANGE",params:e})}Se.rule=ke;var Ee={target:[{os:"*"}],map:"app.getAllDisplays"};function Ae(){return d.call({rule:Ee,method:"GET_ALL_DISPLAYS"})}Ae.rule=Ee;var Oe={target:[{os:"*"}],map:"app.getPrimaryDisplay"};function Pe(){return d.call({rule:Oe,method:"GET_PRIMARY_DISPLAY"})}Pe.rule=Oe;var Ie={target:[{os:"*"}],map:"app.navigationGoBack"};function Ce(){return d.call({rule:Ie,method:"NAVIGATION_GO_BACK"})}Ce.rule=Ie;var Le={target:[{os:"windows"}],map:"app.getAutoStart"};function je(){return d.call({rule:Le,method:"GET_AUTO_START"})}je.rule=Le;var Me={target:[{os:"*"}],map:"app.showUpdateModal"};function Ne(){return d.call({rule:Me,method:"SHOW_UPDATE_MODAL"})}Ne.rule=Me;var De={target:[{os:"*"}],map:"app.getIsUpdatePackageReady"};function Re(){return d.call({rule:De,method:"GET_IS_UPDATE_PACKAGE_READY"})}Re.rule=De;var Be={target:[{os:"*"}],map:"app.getClientUpdateInfo"};function Ue(){return d.call({rule:Be,method:"GET_CLIENT_UPDATE_INFO"})}Ue.rule=Be;var Fe={target:[{os:"*"}],map:"app.quitUpdateTip"};function Ve(){return d.call({rule:Fe,method:"QUIT_UPDATE_TIP"})}Ve.rule=Fe;var ze={target:[{os:"mac"}],map:"app.getMediaAccessStatus"};function He(e){return d.call({rule:ze,method:"GET_MEDIA_ACCESS_STATUS",params:e,transParameters:!0})}He.rule=ze;var qe={target:[{os:"mac"}],map:"app.askForMediaAccess"};function Ge(e){return d.call({rule:qe,method:"ASK_FOR_MEDIA_ACCESS",params:e,transParameters:!0})}Ge.rule=qe;var $e={target:[{os:"mac"}],map:"app.getIsMas"};function We(){return d.call({rule:$e,method:"GET_IS_MAS"})}We.rule=$e;var Ze={target:[{os:"*"}],map:"app.getIsFrontShow"};function Ye(){return d.call({rule:Ze,method:"GET_IS_FRONT_SHOW"})}Ye.rule=Ze;var Ke={target:[{os:"*"}],map:"app.downloadWallpaper"};function Xe(e){return d.call({rule:Ke,method:"DOWNLOAD_WALLPAPER",params:e,transParameters:!0})}Xe.rule=Ke;var Qe={target:[{os:"*"}],map:"app.getStoreItem"};function Je(e){return d.call({rule:Qe,method:"GET_STORE_ITEM",params:e,transParameters:!0})}Je.rule=Qe;var et={target:[{os:"*"}],map:"app.setStoreItem"};function tt(e){return d.call({rule:et,method:"SET_STORE_ITEM",params:e,transParameters:!0})}tt.rule=et;var nt={target:[{os:"*"}],map:"app.getMetrics"};function it(){return d.call({rule:nt,method:"GET_METRICS"})}it.rule=nt;var ot={target:[{os:"*"}],map:"app.printFirstFeedShow"};function at(e){return d.call({rule:ot,method:"printFirstFeedShow",params:e,transParameters:!0})}at.rule=ot;var rt={target:[{os:"windows"}],map:"app.getHardwareDecodeState"};function st(){return d.call({rule:rt,method:"getHardwareDecodeState"})}st.rule=rt;var lt={target:[{os:"*"}],map:"app.isTopWebview"};function ct(){return d.call({rule:lt,method:"isTopWebview"})}ct.rule=lt;var dt={target:[{os:"*"}],map:"app.getVolumeInfo"};function ut(){return d.call({rule:dt,method:"getVolumeInfo"})}ut.rule=dt;var pt={target:[{os:"*"}],map:"app.openInternalBrowser"};function vt(e){return d.call({rule:pt,method:"openInternalBrowser",params:e,transParameters:!0})}vt.rule=pt;var mt={target:[{os:"*"}],map:"app.mainWindowShowView"};function gt(){return d.call({rule:mt,method:"mainWindowShowView"})}gt.rule=mt;var ht={target:[{os:"*"}],map:"app.langChange"};function _t(e){return d.call({rule:ht,method:"LANG_CHANGE",params:e})}_t.rule=ht;var ft={target:[{os:"*"}],map:"app.downloadVideo"};function yt(e){return d.call({rule:ft,method:"DOWNLOAD_VIDEO",params:e})}yt.rule=ft;var bt={getVersion:v,setAlwaysOnTop:g,changeToOriginalMode:_,changeToSmallMode:y,isAlwaysOnTop:w,mainWindowMoveTop:T,minimize:S,handlePageReady:A,maximize:P,canGoBack:C,clearCookie:j,getWid:N,closeParent:R,closeWindow:U,getAllClientLog:V,getAppConfigItem:H,goBack:G,getPageStore:W,getSettings:Y,isFull:X,openWallpaperWindow:J,getChannelId:te,reload:ie,setFullScreenable:ae,getAllWindowData:se,reloadWindowFromId:ce,reportStat:ue,setAppConfigItem:ve,setAutoStart:ge,setCloseToTray:_e,setMiniMizeToTray:ye,showAbout:we,syncLoginState:Te,themeChange:Se,getAllDisplays:Ae,getPrimaryDisplay:Pe,navigationGoBack:Ce,getAutoStart:je,showUpdateModal:Ne,getIsUpdatePackageReady:Re,getClientUpdateInfo:Ue,quitUpdateTip:Ve,getMediaAccessStatus:He,askForMediaAccess:Ge,getIsMas:We,getIsFrontShow:Ye,downloadWallpaper:Xe,getStoreItem:Je,setStoreItem:tt,getMetrics:it,printFirstFeedShow:at,getHardwareDecodeState:st,isTopWebview:ct,getVolumeInfo:ut,openInternalBrowser:vt,mainWindowShowView:gt,langChange:_t,downloadVideo:yt};u(bt);var wt=bt,xt={target:[{os:"*"}],map:"user.getUserUniqueId"};function Tt(){return d.call({rule:xt,method:"GET_USER_UNIQUE_ID"})}Tt.rule=xt;var kt={target:[{os:"*"}],map:"user.getCsrInitialData"};function St(){return d.call({rule:kt,method:"getCsrInitialData"})}St.rule=kt;var Et={getUserUniqueId:Tt,getCsrInitialData:St};return u(Et),{app:wt,user:Et,util:{canIUse:d.canIUse.bind(d),isClient:d.checkInClient,sdkVersion:"0.0.0"},on:d.on.bind(d),off:d.off.bind(d)}}()},54775:(e,t,n)=>{"use strict";n.d(t,{juU:()=>L});var i=function(){return"undefined"==typeof window||"undefined"==typeof document},o=i()||!document.documentElement.classList.contains("Android")&&!Boolean(/(?:Android);?[\s/]+([\d.]+)?/.exec(navigator.userAgent))?"iOS":"Android",a=n(23475),r=n.n(a),s=n(71984),l=n.n(s),c=n(86649),d=n.n(c),u=n(88028),p=n.n(u),v=n(22799),m=n.n(v),g=n(55587),h=n.n(g),_=n(35692),f=n(65328),y=n(85609),b=n(34770),w=n.n(b),x=n(58041),T=n.n(x),k=n(40099),S=n(73791),E=function(){if(!i())return function(){if(i())return!1;var e=navigator.userAgent.match(/isDarkMode\/([01])/);return e?"1"===e[1]:Boolean(window.matchMedia)&&window.matchMedia("(prefers-color-scheme: dark)").matches}()?"dark":"light"}(),A=["children","margin","padding","width","height","maxWidth","minWidth","maxHeight","minHeight"],O=["children","margin","padding","width","height","maxWidth","minWidth","maxHeight","minHeight"];function P(e,t){var n=w()(e);if(r()){var i=r()(e);t&&(i=l()(i).call(i,(function(t){return d()(e,t).enumerable}))),n.push.apply(n,i)}return n}function I(e){for(var t=1;t{"use strict";n.d(t,{Bb:()=>Cn,Mw:()=>Zn,Om:()=>i,I0:()=>N,h$:()=>$e,zm:()=>It,Ft:()=>jn,DA:()=>$,uC:()=>W,DW:()=>Z,QK:()=>k,dB:()=>Ut,sg:()=>Qt,nO:()=>ni,Te:()=>Qn,Qx:()=>ei,KW:()=>Jn,ND:()=>Xn,mK:()=>x,R8:()=>Me,Xw:()=>dt,v3:()=>ot,sO:()=>Mn,OV:()=>et,eh:()=>kn,Fm:()=>w,U5:()=>Be,L5:()=>V,ZP:()=>Ce,N0:()=>Te,Tj:()=>l,f5:()=>o,eb:()=>ii,Yk:()=>st,Ab:()=>pn}),n.p,n.p,n.p,n.p,n.p,n.p;const i=Object.freeze({XSmall:"XSmall",Small:"Small",Medium:"Medium",Large:"Large",XLarge:"XLarge"}),o=Object.freeze({[i.XSmall]:480,[i.Small]:768,[i.Medium]:1024,[i.Large]:1280,[i.XLarge]:1440}),a=Object.freeze({[i.XSmall]:`@media screen and (max-width: ${o[i.XSmall]}px)`,[i.Small]:`@media screen and (max-width: ${o[i.Small]}px)`,[i.Medium]:`@media screen and (max-width: ${o[i.Medium]}px)`,[i.Large]:`@media screen and (max-width: ${o[i.Large]}px)`,[i.XLarge]:`@media screen and (max-width: ${o[i.XLarge]}px)`}),r="object"==typeof document?document:void 0,s=Object.freeze({modal:9999,toast:1e4}),l={positive:"var(--tux-colorPositive)",negative:"var(--tux-colorNegative)",toastDefault:"var(--tux-colorToastDefault)",toastNegative:"var(--tux-colorToastNegative)",secondary:"var(--tux-colorSecondary)",secondary2:"var(--tux-colorSecondary2)",positive2:"var(--tux-colorPositive2)",constTextInverse:"var(--tux-colorConstTextInverse)",constTextInverse2:"var(--tux-colorConstTextInverse2)",constTextInverse3:"var(--tux-colorConstTextInverse3)",constTextInverse4:"var(--tux-colorConstTextInverse4)",constTextInverse5:"var(--tux-colorConstTextInverse5)",constTextPrimary:"var(--tux-colorConstTextPrimary)",constBGInverse:"var(--tux-colorConstBGInverse)",constBGInverse2:"var(--tux-colorConstBGInverse2)",constBGInverse3:"var(--tux-colorConstBGInverse3)",constBGInverse4:"var(--tux-colorConstBGInverse4)",BGCreation:"var(--tux-colorBGCreation)",BGCreation2:"var(--tux-colorBGCreation2)",BGCreation5:"var(--tux-colorBGCreation5)",constBGMat:"var(--tux-colorConstBGMat)",constBGContainer:"var(--tux-colorConstBGContainer)",constBGContainer2:"var(--tux-colorConstBGContainer2)",constBGContainer3:"var(--tux-colorConstBGContainer3)",constBGPlaceholderOpaque:"var(--tux-colorConstBGPlaceholderOpaque)",constBGInverseOpaque:"var(--tux-colorConstBGInverseOpaque)",constBGInverse1:"var(--tux-colorConstBGInverse1)",constLineInverse:"var(--tux-colorConstLineInverse)",constLineInverse2:"var(--tux-colorConstLineInverse2)",SDPrimary:"var(--tux-colorSDPrimary)",gradientLive:"var(--tux-gradientLive)",gradientVideoCoverOverlay:"var(--tux-gradientVideoCoverOverlay)",colorAssistColorYellow:"var(--tux-colorAssistColorYellow)",primary:"var(--tux-colorPrimary)",primaryTint4:"var(--tux-colorPrimary-tint-4)",primaryTint8:"var(--tux-colorPrimary-tint-8)",primaryTint12:"var(--tux-colorPrimary-tint-12)",primaryOpacity0:"var(--tux-colorPrimary-opacity-0)",primaryOpacity4:"var(--tux-colorPrimary-opacity-4)",primaryOpacity8:"var(--tux-colorPrimary-opacity-8)",primaryOpacity12:"var(--tux-colorPrimary-opacity-12)",link:"var(--tux-colorLink)",primary2:"var(--tux-colorPrimary2)",textPrimary:"var(--tux-colorTextPrimary)",textSecondary:"var(--tux-colorTextSecondary)",textTertiary:"var(--tux-colorTextTertiary)",textQuaternary:"var(--tux-colorTextQuaternary)",BGPrimary:"var(--tux-colorBGPrimary)",BGSecondary:"var(--tux-colorBGSecondary)",BGSecondaryTint4:"var(--tux-colorBGSecondary-tint-4)",BGSecondaryTint8:"var(--tux-colorBGSecondary-tint-8)",BGSecondaryTint12:"var(--tux-colorBGSecondary-tint-12)",BGSecondaryOpacity0:"var(--tux-colorBGSecondary-opacity-0)",BGSecondaryOpacity4:"var(--tux-colorBGSecondary-opacity-4)",BGSecondaryOpacity8:"var(--tux-colorBGSecondary-opacity-8)",BGSecondaryOpacity12:"var(--tux-colorBGSecondary-opacity-12)",BGTertiary:"var(--tux-colorBGTertiary)",BGQuaternary:"var(--tux-colorBGQuaternary)",BGQuinary:"var(--tux-colorBGQuinary)",BGSecondary2:"var(--tux-colorBGSecondary2)",BGTertiary2:"var(--tux-colorBGTertiary2)",BGPlaceholderDefault:"var(--tux-colorBGPlaceholderDefault)",BGPlaceholderOpaque:"var(--tux-colorBGPlaceholderOpaque)",BGInput:"var(--tux-colorBGInput)",BGInput2:"var(--tux-colorBGInput2)",BGView:"var(--tux-colorBGView)",BGCreation3:"var(--tux-colorBGCreation3)",BGCreation4:"var(--tux-colorBGCreation4)",BGHover:"var(--tux-colorBGHover)",BGBrand:"var(--tux-colorBGBrand)",linePrimary:"var(--tux-colorLinePrimary)",lineSecondary:"var(--tux-colorLineSecondary)",lineInput:"var(--tux-colorLineInput)",linePrimary2:"var(--tux-colorLinePrimary2)",lineSecondary2:"var(--tux-colorLineSecondary2)",lineSecondary3:"var(--tux-colorLineSecondary3)",lineDarker:"var(--tux-colorLineDarker)",SDSecondary:"var(--tux-colorSDSecondary)",SDTertiary:"var(--tux-colorSDTertiary)"};var c=n(40099);const d=e=>Object.fromEntries(Object.entries(e).filter((([e,t])=>void 0!==t)));var u=n(62186);const p="tux";function v(e,...t){return`var(--${p}-${e}${t.join("")})`}function m(e){return v("color",e)}function g(e){return v("fontSize",e)}function h(e){return v("fontWeight",e)}function _(e){return v("fontFamily",e)}function f(e){return v("boxShadow",e)}const y=(0,u.default)("span",{target:"eblccp10"})((({nowrap:e,truncate:t,block:n,inline:i,italic:o,underline:r,strikethrough:s,size:l,weight:c,align:d,lineHeight:u,_fontFamily:p,_color:v})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",marginBlockStart:"0",marginBlockEnd:"0"},l&&{fontSize:g(l)}),"H1"===l&&{fontSize:g(l),[a.Medium]:{fontSize:g("H3")}}),"H2"===l&&{fontSize:g(l),[a.Medium]:{fontSize:g("H4")}}),"H3"===l&&{fontSize:g(l),[a.Medium]:{fontSize:g("H5")}}),"H4"===l&&{fontSize:g(l),[a.Medium]:{fontSize:g("H5")}}),"H5"===l&&{fontSize:g(l),[a.Medium]:{fontSize:g("H6")}}),u&&{lineHeight:u}),p&&{fontFamily:_(p)}),c&&{fontWeight:h(c)}),v&&{color:m(v)}),e&&{whiteSpace:"nowrap",overflow:"hidden"}),t&&{textOverflow:"ellipsis"}),i&&!n&&{display:"inline"}),n&&!i&&{display:"block"}),n&&i&&{display:"inline-block"}),!0===o&&{fontStyle:"italic"}),!1===o&&{fontStyle:"normal"}),r&&{textDecoration:"underline"}),s&&{textDecoration:"line-through"}),r&&s&&{textDecoration:"line-through underline"}),d&&{textAlign:d})),"label:TextContainer;"),b=(0,u.default)(y,{target:"eblccp12"})((({size:e})=>Object.assign({},e&&{marginBlockStart:g(e),marginBlockEnd:g(e)})),"label:ParagraphContainer;");const w=e=>{var{nowrap:t,truncate:n,block:i,inline:o,italic:a,underline:r,strikethrough:s,type:l,align:u,color:p,lineHeight:v,as:m,marginInline:g,marginInlineStart:h,marginInlineEnd:_,marginBlock:f,marginBlockStart:b,marginBlockEnd:w,alignSelf:x,flex:T,deprecatedStyle:k,deprecatedClassName:S,children:E}=e,A=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{const[S,E]=s.split("-"),A=d({marginInline:m,marginInlineStart:g,marginInlineEnd:h,marginBlock:_,marginBlockStart:f,marginBlockEnd:y,alignSelf:w,flex:x});return c.createElement(b,{as:"p",nowrap:e,truncate:t,block:n,inline:i,italic:o,underline:a,strikethrough:r,size:S,weight:E,align:l,lineHeight:null!=p?p:1.5,_fontFamily:"Paragraph",_color:u,className:T,style:Object.assign(Object.assign({},k),A)},v)};const T=(0,u.default)("a",{target:"e1rlcyt00"})((({textColor:e,type:t,isDisabled:n})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({textDecoration:"none"},e&&{color:m(e)}),t&&{fontSize:g(t),fontFamily:_("Paragraph"),fontWeight:h("Semibold"),lineHeight:1.5}),"H7"===t&&{fontFamily:_("Heading"),fontWeight:h("Bold"),lineHeight:1.2}),{":hover, :focus-visible":{textDecoration:n?"none":"underline"}}),n&&Object.assign({color:m("TextQuaternary"),cursor:"not-allowed"},"ConstTextInverse"===e&&{color:m("ConstTextInverse4")}))),"label:Link;"),k=e=>{var{label:t,color:n,disabled:i,onClick:o,marginInline:a,marginInlineStart:r,marginInlineEnd:s,marginBlock:l,marginBlockStart:u,marginBlockEnd:p,alignSelf:v,flex:m,deprecatedClassName:g,deprecatedStyle:h}=e,_=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{i?e.preventDefault():null==o||o(e)},className:g,style:Object.assign(Object.assign({},h),f)},_),t)};var S=n(75431);const E=e=>{var t=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oObject.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",appearance:"none",minWidth:"96px",display:"inline-flex",justifyContent:"center",alignItems:"center",position:"relative",borderStyle:"solid",borderWidth:"1px",borderRadius:"2px",fontFamily:_("Paragraph"),fontWeight:h("Semibold"),textDecoration:"none",cursor:"pointer",backgroundClip:"padding-box"},i&&{display:"flex",width:"100%"}),"small"===t&&{fontSize:g("P4"),height:"28px",paddingInline:"11px"}),"medium"===t&&{fontSize:g("P3"),height:"36px",paddingInline:"15px"}),"large"===t&&{fontSize:g("P3"),height:"48px",paddingInline:"23px"}),"primary"===e&&{color:m("ConstTextInverse"),backgroundColor:m("Primary"),borderColor:m("Primary"),':hover:not(:disabled):not([aria-disabled="true"])':{backgroundColor:m("Primary-tint-8"),borderColor:m("Primary-tint-8")},':active:not(:disabled):not([aria-disabled="true"])':{backgroundColor:m("Primary-tint-12"),borderColor:m("Primary-tint-12")},':disabled, &[aria-disabled="true"]':Object.assign({cursor:"not-allowed"},!n&&{color:m("TextQuaternary"),backgroundColor:m("BGSecondary-tint-8"),borderColor:m("BGSecondary-tint-8")})}),"secondary"===e&&{color:m("TextPrimary"),backgroundColor:m("BGSecondary"),borderColor:m("LineSecondary"),':hover:not(:disabled):not([aria-disabled="true"])':{backgroundColor:m("BGSecondary-tint-4"),borderColor:m("LinePrimary")},':active:not(:disabled):not([aria-disabled="true"])':{backgroundColor:m("BGSecondary-tint-8"),borderColor:m("LinePrimary")},':disabled, &[aria-disabled="true"]':Object.assign({cursor:"not-allowed"},!n&&{color:m("TextQuaternary")})}),"tertiary"===e&&{color:m("Primary"),backgroundColor:m("Primary-opacity-0"),borderColor:m("Primary"),':hover:not(:disabled):not([aria-disabled="true"])':{backgroundColor:m("Primary-opacity-8")},':active:not(:disabled):not([aria-disabled="true"])':{backgroundColor:m("Primary-opacity-12")},':disabled, &[aria-disabled="true"]':Object.assign({cursor:"not-allowed"},!n&&{color:m("TextQuaternary"),borderColor:m("LineSecondary")})}),"const"===e&&{color:m("ConstTextInverse"),backgroundColor:m("ConstBGContainer"),borderColor:m("ConstBGContainer"),':hover:not(:disabled):not([aria-disabled="true"])':{color:m("ConstTextInverse3"),backgroundColor:m("ConstBGContainer2"),borderColor:m("ConstBGContainer2")},':active:not(:disabled):not([aria-disabled="true"])':{color:m("ConstTextInverse3"),backgroundColor:m("ConstBGContainer3"),borderColor:m("ConstBGContainer3")},':disabled, &[aria-disabled="true"]':Object.assign({cursor:"not-allowed"},!n&&{color:m("ConstTextInverse4"),backgroundColor:m("ConstBGContainer2"),borderColor:m("ConstBGContainer2")})}),P=(0,u.default)("button",{target:"e1v8cfre0"})(O,"label:Button;"),I=(0,u.default)("a",{target:"e1v8cfre1"})(O,"label:ButtonAsLink;"),C=(0,u.default)("div",{target:"e1v8cfre2"})((({buttonSize:e,visible:t})=>Object.assign(Object.assign(Object.assign({boxSizing:"border-box",width:"100%",display:"flex",justifyContent:"center",alignItems:"center",opacity:t?1:0,overflow:"hidden",svg:{height:"1em",width:"1em",color:"inherit",flexShrink:0}},"small"===e&&{gap:"4px"}),"medium"===e&&{gap:"6px"}),"large"===e&&{gap:"6px"})),"label:ButtonContent;"),L=(0,u.default)("div",{target:"e1v8cfre3"})({boxSizing:"border-box",whiteSpace:"nowrap",textOverflow:"ellipsis",overflow:"hidden"},"label:ButtonLabel;"),j=(0,S.i7)({from:{transform:"rotate(0deg)"},to:{transform:"rotate(360deg)"}}),M=(0,u.default)(E,{target:"e1v8cfre4"})({boxSizing:"border-box",color:"inherit",position:"absolute",height:"16px",width:"16px",animation:`${j} 1s linear infinite`},"label:LoadingIcon;"),N=(0,c.forwardRef)(((e,t)=>{var{as:n="button",variant:i="secondary",size:o="medium",label:a,icon:r,loading:s,disabled:l,marginInline:u,marginInlineStart:p,marginInlineEnd:v,marginBlock:m,marginBlockStart:g,marginBlockEnd:h,alignSelf:_,flex:f,deprecatedClassName:y,deprecatedStyle:b}=e,w=A(e,["as","variant","size","label","icon","loading","disabled","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd","alignSelf","flex","deprecatedClassName","deprecatedStyle"]);y&&console.warn('The \'deprecatedClassName\' prop is deprecated. Please use the associated style props instead (e.g. "marginInline", "flex")'),b&&console.warn('The \'deprecatedStyle\' prop is deprecated. Please use the associated style props instead (e.g. "marginInline", "flex")');const x=d({marginInline:u,marginInlineStart:p,marginInlineEnd:v,marginBlock:m,marginBlockStart:g,marginBlockEnd:h,alignSelf:_,flex:f}),T=s||l,k=c.createElement(c.Fragment,null,c.createElement(C,{buttonSize:o,visible:!s},r||null,a?c.createElement(L,null,a):null),s?c.createElement(M,null):null);if("a"===n){const{href:e}=w,n=A(w,["href"]);return c.createElement(I,Object.assign({ref:t,variant:i,size:o,isLoading:s,"aria-disabled":T,href:T?void 0:e,style:Object.assign(Object.assign({},b),x),className:y},n),k)}return c.createElement(P,Object.assign({ref:t,variant:i,size:o,isLoading:s,disabled:T,style:Object.assign(Object.assign({},b),x),className:y},w),k)}));N.displayName="TUXButton";var D=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oObject.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",appearance:"none",height:"1.5em",display:"inline-flex",justifyContent:"center",alignItems:"center",padding:0,fontFamily:_("Paragraph"),fontWeight:h("Semibold"),border:"none",backgroundColor:"transparent",textDecoration:"none",cursor:"pointer",svg:{height:"1em",width:"1em",flexShrink:0}},n&&{display:"flex",width:"100%"}),"P2"===t&&{gap:"4px",fontSize:g("P2")}),"P3"===t&&{gap:"4px",fontSize:g("P3")}),"P4"===t&&{gap:"2px",fontSize:g("P4")}),"P5"===t&&{gap:"2px",fontSize:g("P5")}),"primary"===e&&{color:m("TextPrimary"),':disabled, &[aria-disabled="true"]':{cursor:"not-allowed",color:m("TextQuaternary")}}),"secondary"===e&&{color:m("TextSecondary"),':hover:not(:disabled):not([aria-disabled="true"])':{color:m("TextPrimary")},':disabled, &[aria-disabled="true"]':{cursor:"not-allowed",color:m("TextQuaternary")}}),"tertiary"===e&&{color:m("TextTertiary"),':hover:not(:disabled):not([aria-disabled="true"])':{color:m("TextSecondary")},':disabled, &[aria-disabled="true"]':{cursor:"not-allowed",color:m("TextQuaternary")}}),"brand"===e&&{color:m("Primary"),':hover:not(:disabled):not([aria-disabled="true"])':{color:"#EA284E"},':disabled, &[aria-disabled="true"]':{cursor:"not-allowed",color:m("TextQuaternary")}}),B=(0,u.default)("button",{target:"e18zrus10"})(R,"label:Button;"),U=(0,u.default)("a",{target:"e18zrus11"})(R,"label:ButtonAsLink;"),F=(0,u.default)("div",{target:"e18zrus12"})({whiteSpace:"nowrap",textOverflow:"ellipsis",overflow:"hidden"},"label:ButtonLabel;"),V=(0,c.forwardRef)(((e,t)=>{var{as:n="button",variant:i="secondary",size:o="P3",label:a,icon:r,iconPosition:s="before",disabled:l,marginInline:u,marginInlineStart:p,marginInlineEnd:v,marginBlock:m,marginBlockStart:g,marginBlockEnd:h,alignSelf:_}=e,f=D(e,["as","variant","size","label","icon","iconPosition","disabled","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd","alignSelf"]);const y=d({marginInline:u,marginInlineStart:p,marginInlineEnd:v,marginBlock:m,marginBlockStart:g,marginBlockEnd:h,alignSelf:_}),b=c.createElement(c.Fragment,null,r&&"before"===s?r:null,c.createElement(F,null,a),r&&"after"===s?r:null);if("a"===n){const{href:e}=f,n=D(f,["href"]);return c.createElement(U,Object.assign({ref:t,variant:i,size:o,"aria-disabled":l,href:l?void 0:e,style:y},n),b)}return c.createElement(B,Object.assign({ref:t,variant:i,size:o,disabled:l,style:y},f),b)}));V.displayName="TUXTextButton";var z=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oObject.assign(Object.assign({boxSizing:"border-box",appearance:"none",padding:0,border:"none",borderRadius:"50%",display:"inline-flex",justifyContent:"center",alignItems:"center",color:m("TextPrimary"),backgroundColor:m("BGInput"),textDecoration:"none",cursor:"pointer",':hover:not(:disabled):not([aria-disabled="true"])':{backgroundColor:"rgba(22, 24, 35, 0.1)"},':active:not(:disabled):not([aria-disabled="true"])':{backgroundColor:"rgba(22, 24, 35, 0.14)"},':disabled, &[aria-disabled="true"]':{cursor:"not-allowed",opacity:.5}},"small"===e&&{height:"36px",width:"36px",svg:{height:"18px",width:"18px"}}),"large"===e&&{height:"48px",width:"48px",svg:{height:"24px",width:"24px"}}),q=(0,u.default)("button",{target:"e52cqrc0"})(H,"label:Button;"),G=(0,u.default)("a",{target:"e52cqrc1"})(H,"label:ButtonAsLink;"),$=(0,c.forwardRef)(((e,t)=>{var{as:n="button",size:i="small",icon:o,disabled:a,marginInline:r,marginInlineStart:s,marginInlineEnd:l,marginBlock:u,marginBlockStart:p,marginBlockEnd:v,alignSelf:m,deprecatedStyle:g,deprecatedClassName:h}=e,_=z(e,["as","size","icon","disabled","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd","alignSelf","deprecatedStyle","deprecatedClassName"]);const f=d({marginInline:r,marginInlineStart:s,marginInlineEnd:l,marginBlock:u,marginBlockStart:p,marginBlockEnd:v,alignSelf:m});if("a"===n){const{href:e}=_,n=z(_,["href"]);return c.createElement(G,Object.assign({ref:t,size:i,"aria-disabled":a,href:a?void 0:e,style:Object.assign(Object.assign({},g),f),className:h},n),o)}return c.createElement(q,Object.assign({ref:t,size:i,disabled:a,style:Object.assign(Object.assign({},g),f),className:h},_),o)}));$.displayName="TUXIconButton";const W=e=>{var{text:t,marginInline:n,marginInlineStart:i,marginInlineEnd:o,marginBlock:a,marginBlockStart:r,marginBlockEnd:s,alignSelf:l,flex:u}=e,p=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{text:t,marginInline:n,marginInlineStart:i,marginInlineEnd:o,marginBlock:a,marginBlockStart:r,marginBlockEnd:s,alignSelf:l,flex:u}=e,p=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{const{idRef:e}=(0,c.useContext)(Y),[t]=(0,c.useState)((()=>{if(e){const t=e.current++;return String(t)}return""}));return`tux-${t}`},Q=()=>{const[e]=(0,c.useState)((()=>(K++).toString()));return`tux-${e}`},J=e=>{const{idRef:t}=(0,c.useContext)(Y);let n=Q;t&&(n=X);const i=n();return null!=e?e:i};var ee=n(74731),te=n(41664),ne=n(23067),ie=n(17784);const oe=()=>{var e;return"undefined"!=typeof window&&Boolean(null===(e=window.document)||void 0===e?void 0:e.createElement)},ae=oe()?c.useLayoutEffect:c.useEffect,re=()=>{const e=(0,c.useRef)(null),t=(0,c.useCallback)((()=>{e.current&&("timeout"===e.current.type?clearTimeout(e.current.id):cancelAnimationFrame(e.current.id),e.current=null)}),[]),n=(0,c.useCallback)(((n,i)=>{t(),e.current=null!==i?{type:"timeout",id:setTimeout(n,i)}:{type:"animationFrame",id:requestAnimationFrame(n)}}),[t]);return(0,c.useEffect)((()=>t),[t]),[n,t]};function se(e){return void 0===e}function le(e){return e.replace(/([!"#$%&'()*+,.\/:;<=>?@[\\\]^`{|}~])/g,"\\$1")}Object.prototype.toString;const ce=e=>{if(!c.isValidElement(e))throw new Error("Component's child must be a single element");return e.type===c.Fragment?ce(e.props.children):e};var de=n(18499);const ue=e=>{const t=(e=>{const{id:t="tux-portal-container",children:n,mountNode:i,zIndex:o=9999}=e,a=J(t),s=(0,c.useMemo)((()=>{if(void 0===r||i)return;const e=r.querySelector(`#${le(a)}`);if(e)return e;const t=r.createElement("div");return t.setAttribute("id",a),t.style.position="absolute",t.style.zIndex=o.toString(),t.style.height="0",t.style.width="0",t.style.top="0",t.style.left="0",r.body.appendChild(t),t}),[r,i,a,o]);return{children:n,mountNode:null!=i?i:s,shouldRender:oe()}})(e);return(e=>c.createElement(c.Fragment,null,e.shouldRender&&e.mountNode&&de.createPortal(e.children,e.mountNode)))(t)};ue.displayName="TUXPortal";var pe=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{width:t=36,height:n=9}=e,i=pe(e,["width","height"]);return c.createElement("svg",Object.assign({width:t,height:n},i,{viewBox:"0 0 24 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"}),c.createElement("path",{d:"M30 8L24 8C31 8 28 7.99999 30 8Z",fill:"currentColor"}),c.createElement("path",{d:"M30 8L24 8L0 8C7 8 10 -2.86102e-06 12 -2.86102e-06C14 -2.86102e-06 17 8 24 8C31 8 28 7.99999 30 8Z",fill:"currentColor"}))},me=e=>{var{width:t=9,height:n=27}=e,i=pe(e,["width","height"]);return c.createElement("svg",Object.assign({width:t,height:n},i,{viewBox:"0 0 8 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"}),c.createElement("path",{d:"M0 -0.000118256L0 23.9997C1.12143e-06 16.9997 8 13.9999 8 11.9999C8 9.99988 8.94079e-07 6.99988 0 -0.000118256Z",fill:"currentColor"}))},ge=e=>{var{width:t=21,height:n=6}=e,i=pe(e,["width","height"]);return c.createElement("svg",Object.assign({width:t,height:n},i,{viewBox:"0 0 14 4",fill:"none",xmlns:"http://www.w3.org/2000/svg"}),c.createElement("path",{d:"M14 4C9.91667 4 8.16667 0 7 0C5.83333 0 4.08333 4 0 4L14 4Z",fill:"currentColor"}))},he=e=>{var{width:t=6,height:n=21}=e,i=pe(e,["width","height"]);return c.createElement("svg",Object.assign({width:t,height:n},i,{viewBox:"0 0 4 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"}),c.createElement("path",{d:"M0 14C4.95735e-07 9.91667 4 8.16667 4 7C4 5.83333 -3.33131e-06 4.08333 1.66948e-07 -9.53674e-07L0 14Z",fill:"currentColor"}))},_e=(0,u.default)("div",{target:"e1l8d53t0"})({boxSizing:"border-box",background:"transparent"},"label:PopperWrapper;"),fe=(0,u.default)("div",{target:"e1l8d53t1"})((({size:e,isHidden:t,_color:n,background:i,transitionState:o,position:a,maxWidth:r,minWidth:s})=>{const l="top"===a||"bottom"===a?0:2,c=l+6;let d="translate(0, 0)",u=0;switch(a){case"top":d=`translate(0, -${l}px)`,"entering"!==o&&"entered"!==o||(d=`translate(0, -${c}px)`,u=1);break;case"bottom":d=`translate(0, ${l}px)`,"entering"!==o&&"entered"!==o||(d=`translate(0, ${c}px)`,u=1);break;case"left":d=`translate(-${l}px, 0)`,"entering"!==o&&"entered"!==o||(d=`translate(-${c}px, 0)`,u=1);break;case"right":d=`translate(${l}px, 0)`,"entering"!==o&&"entered"!==o||(d=`translate(${c}px, 0)`,u=1)}return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",display:"flex",flexFlow:"column nowrap",justifyContent:"flex-start",alignItems:"flex-start",maxWidth:`${r}px`,minWidth:`${s}px`,width:"max-content",transitionProperty:"transform, opacity",transitionDuration:"200ms",transitionTimingFunction:"cubic-bezier(0.65, 0, 0.35, 1)",transform:d,opacity:u,boxShadow:f("Notice")},n&&{color:m(n)}),i&&{backgroundColor:m(i)}),"small"===e&&{padding:"6px 8px",minHeight:"30px",borderRadius:"6px"}),"medium"===e&&{padding:"12px",minHeight:"40px",borderRadius:"8px"}),"large"===e&&{padding:"16px",minHeight:"40px",borderRadius:"8px"})}),"label:Container;"),ye=(0,u.default)("div",{target:"e1l8d53t2"})((({position:e,background:t,size:n})=>{const i="small"===n?"6px":"9px",o="small"===n?"30px":"40px";return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",border:"none",width:o,height:i,display:"flex",alignItems:"center",justifyContent:"center",overflow:"visible","& > svg":Object.assign(Object.assign(Object.assign(Object.assign({display:"block"},"top"===e&&{transform:"rotate(180deg)"}),"right"===e&&{transform:"rotate(180deg)"}),"bottom"===e&&{}),"left"===e&&{})},t&&{color:m(t)}),"top"===e&&{bottom:`-${i}`,width:o,height:i}),"right"===e&&{left:`-${i}`,width:i,height:o}),"bottom"===e&&{top:`-${i}`,width:o,height:i}),"left"===e&&{right:`-${i}`,width:i,height:o})}),"label:ArrowWrapper;"),be={Top:"top",TL:"top-start",TR:"top-end",Bottom:"bottom",BL:"bottom-start",BR:"bottom-end",Left:"left",LT:"left-start",LB:"left-end",Right:"right",RT:"right-start",RB:"right-end"},we=c.forwardRef((({id:e,background:t="Secondary2",visible:n,onVisibleChange:i,showDelayMS:o=80,hideDelayMS:a=80,disabled:s=!1,disableAutoHide:l=!1,content:d,offset:u,position:p="Top",size:v="small",maxWidth:m=420,minWidth:g=60,onEnterTrigger:h,onLeaveTrigger:_,children:f,className:y,style:b},w)=>{const[x,T]=(0,c.useState)(null),[k,S]=(0,c.useState)(null),E=(0,c.useRef)(null),[A,O]=re(),[P,I]=re(),C=!se(n),[L,j]=(0,c.useState)(!1),[M,N]=(0,c.useState)(!1),D=J(e),R=(0,c.useRef)(null),B=c.useCallback(((e,t)=>{s||(O(),I(),e?(j((n=>(e!==n&&(null==i||i({visible:e},t)),e))),P((()=>{var e;N(!0),null===(e=R.current)||void 0===e||e.call(R)}),0)):(N(!1),P((()=>{j((n=>(e!==n&&(null==i||i({visible:e},t)),e)))}),200)))}),[O,j,i,s]);(0,c.useImperativeHandle)(w,(()=>({setVisible:e=>{C||B(e)}})),[B]),(0,c.useEffect)((()=>{C&&B(Boolean(n))}),[n]);let U=0;switch(v){case"small":U=5;break;case"medium":case"large":U=8}const F=null!=u?u:[0,U],{styles:V,state:z,forceUpdate:H}=(0,ne.E)(E.current,x,{placement:be[p],modifiers:[{name:"arrow",options:{element:k}},{name:"offset",options:{offset:F}},{name:"preventOverflow",options:{mainAxis:!1}},{name:"computeStyles",options:{adaptive:!1}}],strategy:"absolute"});R.current=H;const q=(0,c.useMemo)((()=>null==z?void 0:z.placement.split("-")[0]),[null==z?void 0:z.placement]),G=(()=>{switch(!0){case"top"===q&&"small"===v:case"bottom"===q&&"small"===v:return c.createElement(ge,null);case"top"===q&&"medium"===v:case"bottom"===q&&"medium"===v:case"top"===q&&"large"===v:case"bottom"===q&&"large"===v:return c.createElement(ve,null);case"right"===q&&"small"===v:case"left"===q&&"small"===v:return c.createElement(he,null);case"right"===q&&"medium"===v:case"left"===q&&"medium"===v:case"right"===q&&"large"===v:case"left"===q&&"large"===v:return c.createElement(me,null);default:return null}})(),$=(0,c.useCallback)((e=>{var t;let n=o;"focus"===e.type&&(n=0),A((()=>{C||B(!0,e)}),n),null===(t=e.persist)||void 0===t||t.call(e)}),[A,B,o,L,C]);h&&(h.current=$);const W=(0,c.useCallback)((e=>{var t;let n=a;"blur"===e.type&&(n=0),A((()=>{C||l||B(!1,e)}),n),null===(t=e.persist)||void 0===t||t.call(e)}),[A,B,a,C]);let Z;if(_&&(_.current=W),ae((()=>{if(L){const e=e=>{"Escape"!==e.key&&"Esc"!==e.key||C||B(!1)};return null==r||r.addEventListener("keydown",e),()=>{null==r||r.removeEventListener("keydown",e)}}}),[r,L,B,C]),f){const e=ce(f),t={"aria-labelledby":D,onMouseEnter:$,onMouseLeave:W,onFocus:$,onBlur:W,"data-tux-tooltip":D};Z=(0,c.cloneElement)(e,t)}return ae((()=>{var e;E.current=null==r?void 0:r.querySelector(`[data-tux-tooltip=${le(D)}]`),null===(e=R.current)||void 0===e||e.call(R)}),[D,r,f]),c.createElement(c.Fragment,null,f&&Z,L&&c.createElement(ue,null,c.createElement(_e,{ref:T,style:V.popper},c.createElement(ie.Ay,{in:M,timeout:200},(e=>c.createElement(fe,{id:D,size:v,maxWidth:m,minWidth:g,background:t,transitionState:e,position:q,onMouseEnter:$,onMouseLeave:W,className:y,style:b,role:"tooltip"},c.createElement(ye,{ref:S,style:V.arrow,position:q,background:t,size:v},G),d))))))})),xe=(0,u.default)(w,{target:"e1csn40i0"})({margin:"auto",minHeight:"20px"},"label:Content;"),Te=({id:e,background:t="Secondary2",visible:n,onVisibleChange:i,disabled:o=!1,content:a,position:r="Top",type:s="Tiny",maxWidth:l=420,onEnterTrigger:d,onLeaveTrigger:u,children:p})=>{const v="Tiny"===s?"small":"medium",m="BGPrimary"===t?"TextPrimary":"ConstTextInverse";return c.createElement(we,{id:e,background:t,visible:n,onVisibleChange:i,disabled:o,content:c.createElement(xe,{type:"P3-Semibold",color:m},a),position:r,size:v,maxWidth:l,minWidth:60,onEnterTrigger:d,onLeaveTrigger:u},p)};n.p;const ke=e=>{var{as:t="label",text:n,required:i,tooltipText:o,hidden:a,marginInline:r,marginInlineStart:s,marginInlineEnd:u,marginBlock:p,marginBlockStart:v,marginBlockEnd:m,alignSelf:g,flex:h}=e,_=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{text:t,marginInline:n,marginInlineStart:i,marginInlineEnd:o,marginBlock:a,marginBlockStart:r,marginBlockEnd:s,alignSelf:u,flex:p}=e,v=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oObject.assign({boxSizing:"border-box",width:"240px"},e&&{width:"100%"})),"label:Container;"),Oe=(0,u.default)("div",{target:"eyio37s1"})((({hasDescription:e})=>Object.assign({boxSizing:"border-box",position:"relative",marginBlockStart:"6px",display:"flex",alignItems:"center"},e&&{marginBlockStart:"4px"})),"label:InputContainer;"),Pe=(0,u.default)("input",{target:"eyio37s2"})((({_size:e,hasIcon:t,hasError:n})=>Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",width:"100%",paddingInline:"12px",fontFamily:_("Paragraph"),fontSize:g("P3"),fontWeight:h("Regular"),color:m("TextPrimary"),backgroundColor:m("BGPrimary"),border:`1px solid ${m("LineSecondary")}`,borderRadius:"2px",outline:"none",":focus-visible":{borderColor:m("LineInput")},":disabled":{color:m("TextQuaternary"),backgroundColor:m("BGInput"),cursor:"not-allowed"},"::placeholder":{color:m("TextQuaternary")}},"small"===e&&{height:"36px"}),"large"===e&&{height:"48px"}),n&&{borderColor:m("Negative")}),t&&{paddingInlineEnd:"44px"})),"label:Input;"),Ie=(0,u.default)("div",{target:"eyio37s3"})((({inputDisabled:e,isInteractive:t})=>Object.assign({boxSizing:"border-box",cursor:"pointer",position:"absolute",display:"flex",alignItems:"center",':not([dir="rtl"] &)':{right:"12px"},'[dir="rtl"] &':{left:"12px"},"& > *":Object.assign({color:m("TextSecondary"),height:"20px",width:"20px"},e&&{color:m("TextQuaternary")}),"&:hover > *":{color:m("TextPrimary")}},!t&&{pointerEvents:"none"})),"label:IconContainer;"),Ce=(0,c.forwardRef)(((e,t)=>{var{label:n,required:i,hideLabel:o,tooltipText:a,description:r,errorText:s,hintText:l,icon:u,size:p="large",value:v,onChange:m,disabled:g,maxLength:h,onIconClick:_,block:f,type:y="text",marginInline:b,marginInlineStart:x,marginInlineEnd:T,marginBlock:k,marginBlockStart:S,marginBlockEnd:E,alignSelf:A,flex:O,deprecatedClassName:P,deprecatedStyle:I}=e,C=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{B.forEach((t=>{"function"==typeof t?t(e):null!=t&&(t.current=e)}))}),id:M,"aria-required":i,"aria-invalid":Boolean(s),"aria-describedby":s?D:r?N:void 0,type:y,value:v,onChange:e=>{e.persist(),m(e)},disabled:g,maxLength:h,_size:p,hasIcon:Boolean(u),hasError:Boolean(s)},C)),u?c.createElement(Ie,{inputDisabled:g,isInteractive:Boolean(_),onClick:()=>{_&&R.current&&(_(),R.current.focus())}},c.createElement(u,null)):null),h?c.createElement(w,{block:!0,type:"P5-Regular",marginBlockStart:"4px",color:v.length{var t=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oi((e=>!e))},t))};const Ne=(0,u.default)("div",{target:"eugif8h0"})((({block:e})=>Object.assign({boxSizing:"border-box",width:"352px"},e&&{width:"100%"})),"label:Container;"),De=(0,u.default)("div",{target:"eugif8h1"})((({_disabled:e,hasError:t,hasMaxLength:n,hasDescription:i,isLabelHidden:o})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",width:"100%",marginBlockStart:"6px",paddingBlock:"12px",paddingInline:"12px",backgroundColor:m("BGPrimary"),border:`1px solid ${m("LineSecondary")}`,borderRadius:"2px",":focus-within":{borderColor:m("LineInput")}},i&&{marginBlockStart:"4px"}),o&&{marginBlockStart:"0px"}),e&&{backgroundColor:m("BGInput2"),cursor:"not-allowed"}),t&&{"&, &:focus-within":{borderColor:m("Negative")}}),n&&{paddingBlockEnd:"2px"})),"label:TextAreaContainer;"),Re=(0,u.default)("textarea",{target:"eugif8h2"})({boxSizing:"border-box",width:"100%",fontFamily:_("Paragraph"),fontSize:g("P3"),fontWeight:h("Regular"),color:m("TextPrimary"),resize:"none",outline:"none",border:"none",backgroundColor:"transparent",":disabled":{color:m("TextQuaternary"),backgroundColor:"transparent",cursor:"not-allowed"},"::placeholder":{color:m("TextQuaternary")}},"label:TextArea;"),Be=(0,c.forwardRef)(((e,t)=>{var{label:n,required:i,hideLabel:o,tooltipText:a,description:r,errorText:s,hintText:l,value:u,onChange:p,disabled:v,rows:m=3,maxLength:g,block:h,marginInline:_,marginInlineStart:f,marginInlineEnd:y,marginBlock:b,marginBlockStart:x,marginBlockEnd:T,alignSelf:k,flex:S,deprecatedClassName:E,deprecatedStyle:A}=e,O=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{e.persist(),p(e)},rows:m,maxLength:g,disabled:v},O)),g?c.createElement(w,{block:!0,type:"P5-Regular",color:u.lengthc.createElement("svg",{width:e,height:.25*e,viewBox:"0 0 8 2",fill:"none",xmlns:"http://www.w3.org/2000/svg"},c.createElement("rect",{x:"0.666748",y:"0.335938",width:"6.66667",height:"1.33333",rx:"0.5",fill:"currentColor"})),Fe=({width:e=10})=>c.createElement("svg",{width:e,height:.8*e,viewBox:"0 0 10 8",fill:"none",xmlns:"http://www.w3.org/2000/svg"},c.createElement("path",{d:"M3.88632 5.95189L8.77465 0.915431C8.96697 0.717276 9.28352 0.712552 9.48168 0.904878L9.67738 1.09483C9.87553 1.28715 9.88026 1.6037 9.68793 1.80185L4.34296 7.3088C4.093 7.56633 3.67963 7.56633 3.42967 7.3088L0.948335 4.75227C0.756009 4.55411 0.760734 4.23757 0.958888 4.04524L1.15459 3.85529C1.35275 3.66297 1.66929 3.66769 1.86162 3.86584L3.88632 5.95189Z",fill:"currentColor"})),Ve=(0,u.default)("div",{target:"ex5tlgb0"})({boxSizing:"border-box",display:"flex",flexFlow:"row nowrap",justifyContent:"flex-start",alignItems:"flex-start",minHeight:"24px"},"label:Container;"),ze=(0,u.default)("input",{target:"ex5tlgb1"})({boxSizing:"border-box",appearance:"none",height:"100%",width:"100%",position:"absolute",cursor:"pointer",margin:"0",":disabled":{cursor:"not-allowed"}},"label:Input;"),He=(0,u.default)("div",{target:"ex5tlgb2"})({boxSizing:"border-box",position:"relative",width:"16px",height:"16px",flexShrink:"0",marginBlockStart:"3px"},"label:IndicatorWrapper;"),qe=(0,u.default)("div",{target:"ex5tlgb3"})((({isSelected:e,isDisabled:t})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",position:"relative",height:"100%",width:"100%",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"2px",pointerEvents:"none",color:m("BGPrimary"),"& > svg":{visibility:"hidden"}},!t&&!e&&{border:`1.5px solid ${m("LineSecondary")}`,":hover, [data-tux-checkbox-input]:focus-visible + &, [data-tux-checkbox-input]:hover + &":{border:"1.5px solid rgba(234, 40, 78, 1)"},"[data-tux-checkbox-input]:active + &":{border:"1.5px solid rgba(224, 39, 75, 1)"},"[data-tux-checkbox-label]:active + [data-tux-checkbox-input-wrapper] > &":{border:"1.5px solid rgba(224, 39, 75, 1)"}}),!t&&e&&{border:"none",background:m("Primary"),"& > svg":{visibility:"visible"},"[data-tux-checkbox-input]:focus-visible + &, [data-tux-checkbox-input]:hover + &":{background:"rgba(234, 40, 78, 1)"},"[data-tux-checkbox-input]:active + &":{background:"rgba(224, 39, 75, 1)"},"[data-tux-checkbox-label]:active + [data-tux-checkbox-input-wrapper] > &":{background:"rgba(224, 39, 75, 1)"}}),t&&{cursor:"not-allowed",opacity:.34}),t&&e&&{border:"none",background:m("Primary"),"& > svg":{visibility:"visible"}}),t&&!e&&{border:`1.5px solid ${m("LineSecondary")}`})),"label:Indicator;"),Ge=(0,u.default)("label",{target:"ex5tlgb4"})((({labelPosition:e})=>Object.assign(Object.assign({boxSizing:"border-box",flexGrow:"1"},"after"===e&&{paddingInlineStart:"12px",paddingInlineEnd:"0px",order:1}),"before"===e&&{paddingInlineStart:"0px",paddingInlineEnd:"12px",order:-1})),"label:CheckboxText;"),$e=({id:e,label:t,onChange:n,checked:i,defaultChecked:o,required:a,disabled:r=!1,labelPosition:s="after",marginInline:l,marginInlineStart:u,marginInlineEnd:p,marginBlock:v,marginBlockStart:m,marginBlockEnd:g,alignSelf:h,flex:_})=>{const f=d({marginInline:l,marginInlineStart:u,marginInlineEnd:p,marginBlock:v,marginBlockStart:m,marginBlockEnd:g,alignSelf:h,flex:_}),[y,b]=((e,t)=>{const n=!se(e),[i,o]=c.useState(t),a=n?e:i,r=c.useRef(a);c.useEffect((()=>{r.current=a}),[a]);const s=c.useCallback((e=>{var t;t=e,r.current="function"==typeof t?e(r.current):e,o(r.current)}),[]);return[a,s]})(i,null!=o&&o),x=(0,c.useRef)(null),T=J(e),k="mixed"===y;(0,c.useEffect)((()=>{x.current&&(x.current.indeterminate=k)}),[k]);const S=t?c.createElement(Ge,{labelPosition:s,htmlFor:T,"data-tux-checkbox-label":!0},c.createElement(w,{type:"P3-Regular"},t)):null;return c.createElement(Ve,{style:f},S,c.createElement(He,{"data-tux-checkbox-input-wrapper":!0},c.createElement(ze,{id:T,required:a,type:"checkbox",checked:!0===y,disabled:r,ref:x,onChange:e=>{e.stopPropagation();const t=e.target.indeterminate?"mixed":e.target.checked;null==n||n(e),b(t),e.persist()},"data-tux-checkbox-input":!0}),c.createElement(qe,{isSelected:!1!==y,isDisabled:r},k?c.createElement(Ue,{width:12}):c.createElement(Fe,{width:12}))))};const We=(0,u.default)("div",{target:"e1frb0i80"})({boxSizing:"border-box",display:"flex"},"label:Container;"),Ze=(0,u.default)("label",{target:"e1frb0i81"})({boxSizing:"border-box",flexGrow:"1",paddingInlineStart:"12px"},"label:Label;"),Ye=(0,u.default)("div",{target:"e1frb0i82"})((({isDisabled:e})=>Object.assign({boxSizing:"border-box",position:"relative",width:"44px",height:"24px",display:"inline-flex",alignItems:"center",overflow:"hidden",borderRadius:"999px"},e&&{opacity:.34})),"label:InputContainer;"),Ke=(0,u.default)("input",{target:"e1frb0i83"})({appearance:"none",boxSizing:"border-box",position:"absolute",display:"flex",height:"100%",width:"100%",alignItems:"center",backgroundColor:m("LineSecondary"),cursor:"pointer",margin:"0",":checked":{backgroundColor:m("Positive")},"&:checked:not(:disabled):focus-visible, &:checked:not(:disabled):hover":{backgroundColor:"#0ACE8F"},"&:not(:checked):not(:disabled):focus-visible, &:not(:checked):not(:disabled):hover":{backgroundColor:m("LinePrimary2")},":disabled":{cursor:"not-allowed"}},"label:Input;"),Xe=(0,u.default)("div",{target:"e1frb0i84"})({boxSizing:"border-box",height:"20px",width:"20px",display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.2s",borderRadius:"50%",backgroundColor:m("BGPrimary"),boxShadow:"0px 1px 2px rgba(0, 0, 0, 0.25)",pointerEvents:"none",transform:"translateX(2px)",'[dir="rtl"] &':{transform:"translateX(-2px)"},"[data-tux-switch-input]:checked ~ &":{transform:"translateX(22px)"},'[dir="rtl"] [data-tux-switch-input]:checked ~ &':{transform:"translateX(-22px)"}},"label:SwitchHandle;"),Qe=(0,S.i7)({from:{transform:"rotate(0deg)"},to:{transform:"rotate(360deg)"}}),Je=(0,u.default)(E,{target:"e1frb0i85"})({boxSizing:"border-box",width:"14px",height:"14px",color:"#E3E3E3",animation:`${Qe} 1s linear infinite`},"label:LoadingIcon;"),et=e=>{var{id:t,label:n,loading:i,disabled:o,marginInline:a,marginInlineStart:r,marginInlineEnd:s,marginBlock:l,marginBlockStart:u,marginBlockEnd:p,alignSelf:v,flex:m}=e,g=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var t=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var t=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{disabled:t,marginInline:n,marginInlineStart:i,marginInlineEnd:o,marginBlock:a,marginBlockStart:r,marginBlockEnd:s,alignSelf:l,flex:u}=e,p=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{id:t,label:n,labelPosition:i="after",marginInline:o,marginInlineStart:a,marginInlineEnd:r,marginBlock:s,marginBlockStart:l,marginBlockEnd:u,alignSelf:p,flex:v,deprecatedClassName:m,deprecatedStyle:g}=e,h=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var t,n;const i=(0,c.useRef)(null),o=(0,c.useRef)(null),[a,r]=(0,c.useState)(null),[s,l]=(0,c.useState)(null),[d,u]=re(),[p,v]=(0,c.useState)("unmounted"),m=(0,ne.E)(a,s,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,4]}}]}),g="entering"===p||"entered"===p,h=null!==(n=null===(t=m.state)||void 0===t?void 0:t.placement.split("-")[0])&&void 0!==n?n:null,_=()=>{v("exited"),d((()=>{v("entering"),d((()=>{v("entered")}),120)}),50)},f=(0,c.useCallback)((()=>{var e;u(),v("exiting"),null===(e=i.current)||void 0===e||e.focus(),d((()=>v("unmounted")),120)}),[d,u]);return(0,c.useEffect)((()=>{if(g){const e=e=>{var t,n;(null===(t=i.current)||void 0===t?void 0:t.contains(e.target))||(null===(n=o.current)||void 0===n?void 0:n.contains(e.target))||f()};return window.addEventListener("mousedown",e),window.addEventListener("touchstart",e),()=>{window.removeEventListener("mousedown",e),window.removeEventListener("touchstart",e)}}}),[g,f]),{isExpanded:g,open:_,close:f,getAnchorRef:()=>i,anchorProps:{ref:e=>{i.current=e,r(e)},onClick:()=>{g?f():_()}},popoverProps:{ref:e=>{o.current=e,l(e)},position:h,expandState:p,onKeyDown:e=>{g&&"Escape"===e.key&&(e.preventDefault(),e.stopPropagation(),f())},popoverStyle:m.styles.popper,focusOnOpen:e}}},lt=(0,u.default)("div",{target:"eyr17s0"})({outline:"none"},"label:MenuContainer;"),ct=(0,u.default)("div",{target:"eyr17s1"})((({position:e,expandState:t})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",border:`1px solid ${m("LineSecondary")}`,borderRadius:"4px",backgroundColor:m("BGSecondary"),boxShadow:f("Notice"),outline:"none",overflow:"hidden",transition:`transform 120ms ${rt}, opacity 120ms ${rt}`,opacity:0},("entering"===t||"entered"===t)&&{opacity:1}),"bottom"===e&&"exiting"===t&&{transform:"translateY(-10px)"}),"bottom"===e&&"exited"===t&&{transform:"translateY(-10px)",transition:"none"}),"top"===e&&"exiting"===t&&{transform:"translateY(10px)"}),"top"===e&&"exited"===t&&{transform:"translateY(10px)",transition:"none"})),"label:Menu;"),dt=c.forwardRef(((e,t)=>{var{expandState:n,position:i,onKeyDown:o,children:a,popoverStyle:r,focusOnOpen:s,deprecatedClassName:l,deprecatedStyle:d}=e,u=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{};const mt="cubic-bezier(0.65,0,0.35,1)",gt=(0,u.default)("div",{target:"e1enfu0v0"})((({expandState:e})=>Object.assign({boxSizing:"border-box",overflow:"hidden"},"entered"===e&&{overflow:"visible"})),"label:MenuContainer;"),ht=(0,u.default)("div",{target:"e1enfu0v1"})((({position:e,expandState:t})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",border:`1px solid ${m("LineSecondary")}`,borderRadius:"4px",backgroundColor:m("BGSecondary"),boxShadow:"entered"===t?f("Notice"):"none",outline:"none",transition:`transform 220ms ${mt}, opacity 220ms ${mt}`,overflow:"hidden",opacity:0},("entering"===t||"entered"===t)&&{opacity:1}),"bottom"===e&&"exiting"===t&&{transform:"translateY(-100%)"}),"bottom"===e&&"exited"===t&&{transform:"translateY(-100%)",transition:"none"}),"top"===e&&"exiting"===t&&{transform:"translateY(100%)"}),"top"===e&&"exited"===t&&{transform:"translateY(100%)",transition:"none"})),"label:Menu;"),_t=e=>{var{setPopoverRef:t,popoverStyle:n,expandState:i,position:o,children:a,open:r,close:s,isExpanded:l,setAnchorRef:d,forceUpdate:u}=e,p=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{group:t,children:n}=e,i=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oObject.assign(Object.assign({boxSizing:"border-box",minHeight:"42px",display:"flex",alignItems:"center",paddingBlock:"7px",paddingInline:"11px",cursor:"pointer",fontFamily:_("Paragraph"),fontSize:g("P3"),fontWeight:h("Regular"),color:m("TextPrimary")},e&&{backgroundColor:m("BGView")}),t&&{color:m("TextQuaternary"),cursor:"not-allowed"})),"label:Item;"),Tt=(0,u.default)("div",{target:"e1ctrs061"})({boxSizing:"border-box",display:"flex",marginInlineEnd:"8px","> *":{color:m("TextPrimary"),height:"20px",width:"20px"}},"label:IconContainer;"),kt=(0,u.default)("div",{target:"e1ctrs062"})({boxSizing:"border-box",flexGrow:1},"label:Spacer;"),St=(0,u.default)(wt.A,{target:"e1ctrs063"})({boxSizing:"border-box",marginInlineStart:"4px",flexShrink:0,color:m("TextPrimary")},"label:TickIcon;"),Et=(0,u.default)("div",{target:"e1ctrs064"})({boxSizing:"border-box",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},"label:Label;"),At=(0,u.default)("span",{target:"e1ctrs065"})((({bold:e})=>Object.assign({boxSizing:"border-box",fontWeight:h("Regular")},e&&{fontWeight:h("Bold")})),"label:Text;"),Ot=e=>{var{label:t,icon:n,disabled:i,isSelected:o,isActive:a,searchValue:r,children:s}=e,l=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oc.createElement(At,{key:t,bold:!!r&&e.toLowerCase()!==r.toLowerCase()},e))))),o?c.createElement(c.Fragment,null,c.createElement(kt,null),c.createElement(St,null)):null)},Pt=(0,u.default)("hr",{target:"e8356dj0"})((({_color:e})=>({boxSizing:"border-box",flexGrow:"0",flexShrink:"0",border:0,margin:0,padding:0,width:"100%",borderTop:`1px solid ${m(e)}`})),"label:Divider;");const It=e=>{var{as:t,color:n="LinePrimary",marginInline:i,marginInlineStart:o,marginInlineEnd:a,marginBlock:r,marginBlockStart:s,marginBlockEnd:l,alignSelf:u,flex:p,deprecatedClassName:v,deprecatedStyle:m}=e,g=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oObject.assign({boxSizing:"border-box",width:"240px"},e&&{width:"100%"})),"label:Container;"),Lt=(0,u.default)("div",{target:"e1vf30it1"})((({hasDescription:e,isLabelHidden:t})=>Object.assign(Object.assign({boxSizing:"border-box",marginBlockStart:"6px"},e&&{marginBlockStart:"4px"}),t&&{marginBlockStart:"0px"})),"label:InputContainer;"),jt=(0,u.default)("button",{target:"e1vf30it2"})((({size:e,hasError:t})=>Object.assign(Object.assign(Object.assign({boxSizing:"border-box",appearance:"none",width:"100%",paddingInline:"11px",display:"flex",alignItems:"center",border:`1px solid ${m("LineSecondary")}`,borderRadius:"4px",backgroundColor:m("BGPrimary"),outline:"none",cursor:"pointer",":focus-visible:not(:disabled)":{borderColor:m("LineInput")},":hover:not(:disabled)":{backgroundColor:m("BGSecondary-tint-4")},":disabled":{backgroundColor:m("BGInput"),cursor:"not-allowed"}},"small"===e&&{height:"36px"}),"large"===e&&{height:"48px"}),t&&{borderColor:m("Negative")})),"label:Button;"),Mt=(0,u.default)("div",{target:"e1vf30it3"})({boxSizing:"border-box",display:"flex",marginInlineEnd:"8px",color:m("TextPrimary"),"> *":{height:"20px",width:"20px"}},"label:ButtonIconContainer;"),Nt=(0,u.default)("div",{target:"e1vf30it4"})((({isPlaceholder:e,_disabled:t})=>Object.assign(Object.assign({boxSizing:"border-box",display:"flex",alignItems:"center","> *":{flexShrink:0},whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",fontFamily:_("Paragraph"),fontSize:g("P3"),fontWeight:h("Regular"),color:m("TextPrimary")},e&&{color:m("TextSecondary")}),t&&{color:m("TextQuaternary")})),"label:ButtonText;"),Dt=(0,u.default)("div",{target:"e1vf30it5"})({boxSizing:"border-box",flexGrow:1},"label:Spacer;"),Rt=(0,u.default)(ut.A,{shouldForwardProp:e=>"isExpanded"!==e,target:"e1vf30it6"})((({isExpanded:e})=>({boxSizing:"border-box",display:"flex",marginInlineStart:"4px",height:"16px",width:"16px",flexShrink:0,color:m("TextPrimary"),transition:`transform 220ms ${mt}`,transform:e?"rotate(180deg)":"unset"})),"label:ArrowIcon;"),Bt=(0,u.default)("ul",{target:"e1vf30it7"})({boxSizing:"border-box",maxHeight:"260px",paddingBlock:"3px",overflowY:"auto",paddingInline:0,margin:0,listStyle:"none",outline:"none"},"label:List;"),Ut=({label:e,required:t,hideLabel:n,tooltipText:i,description:o,errorText:a,hintText:r,size:s="large",value:l,onChange:u,disabled:p,placeholder:v,options:m,grouped:g,groups:h,renderButtonLabel:_,renderOptionLabel:f,renderGroup:y,block:b,marginInline:w,marginInlineStart:x,marginInlineEnd:T,marginBlock:k,marginBlockStart:S,marginBlockEnd:E,alignSelf:A,flex:O,className:P,style:I})=>{var C;P&&console.warn('The \'className\' prop is deprecated. Please use the associated style props instead (e.g. "marginInline", "flex")'),I&&console.warn('The \'style\' prop is deprecated. Please use the associated style props instead (e.g. "marginInline", "flex")');const L=d({marginInline:w,marginInlineStart:x,marginInlineEnd:T,marginBlock:k,marginBlockStart:S,marginBlockEnd:E,alignSelf:A,flex:O}),j=J(),M=`${j}_label`,N=`${j}_button`,D=`${j}_list`,R=`${j}_description`,B=`${j}_error`,U=g?h.map((e=>e.options)).flat(1):m,F=(e=>{const t=(0,c.useRef)(null),[n,i]=(0,c.useState)(null),o=(0,c.useRef)(!1),[a]=re(),r=e.filter((e=>!e.disabled)),s=n=>{null!==n&&(n=>{if(!t.current)throw new Error("Can't scroll to item; list element doesn't exist");const i=t.current.querySelector(`[${pt}="${n}"]`);if(!i)throw new Error("Can't scroll to item; item element doesn't exist");const r=e.findIndex((e=>e.value===n)),s=t.current.getBoundingClientRect(),l=i.getBoundingClientRect();o.current=!0,a((()=>{o.current=!1}),250),0===r?t.current.scrollTop=0:r===e.length-1?t.current.scrollTop=t.current.scrollHeight:l.tops.bottom&&(t.current.scrollTop+=l.bottom-s.bottom)})(n.value),i(n)},l=()=>{o.current||i(null)};return{activeItem:n,setListRef:e=>{t.current=e},activateItem:s,activateFirstItem:()=>{0!==r.length&&s(r[0])},activateLastItem:()=>{0!==r.length&&s(r[r.length-1])},activatePrevItem:()=>{if(0===r.length)return;const e=r.findIndex((e=>e.value===(null==n?void 0:n.value)));0!==e&&s(-1!==e?r[e-1]:r[r.length-1])},activateNextItem:()=>{if(0===r.length)return;const e=r.findIndex((e=>e.value===(null==n?void 0:n.value)));e!==r.length-1&&s(-1!==e?r[e+1]:r[0])},getItemAttributes:e=>({[pt]:e.value,isActive:e.value===(null==n?void 0:n.value),disabled:e.disabled,onMouseEnter:()=>(e=>{e.disabled||o.current||i(e)})(e),onMouseLeave:l})}})(U),V=(e=>{var t,n,i;const[o,a]=(0,c.useState)(null),[r,s]=(0,c.useState)(null),[l,d]=re(),u=(0,c.useMemo)((()=>({name:"setPopperWidth",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:({state:e})=>{e.styles.popper.minWidth=`${e.rects.reference.width}px`},effect:({state:e})=>{e.elements.popper.style.minWidth=`${e.elements.reference.getBoundingClientRect().width}px`}})),[]),p=(0,ne.E)(o,r,{placement:"bottom-start",modifiers:[{name:"offset",options:{offset:[0,4]}},u]}),[v,m]=(0,c.useState)("unmounted"),g=null!==(n=null===(t=p.state)||void 0===t?void 0:t.placement.split("-")[0])&&void 0!==n?n:null,h=(0,c.useCallback)((()=>{e.animated?(m("exited"),l((()=>{m("entering"),l((()=>{m("entered")}),220)}),50)):m("entered")}),[e.animated,l]),_=(0,c.useCallback)((()=>{d(),e.animated?(m("exiting"),l((()=>m("unmounted")),220)):m("unmounted")}),[e.animated,l,d]),f="entering"===v||"entered"===v;return{setAnchorRef:a,setPopoverRef:s,popoverStyle:p.styles.popper,position:g,expandState:v,isExpanded:f,close:_,open:h,forceUpdate:null!==(i=p.forceUpdate)&&void 0!==i?i:vt}})({animated:!0}),z=(0,c.useRef)(null),H=(0,c.useRef)(null),[q,G]=re(),$=null!==(C=U.find((e=>e.value===l)))&&void 0!==C?C:null,Y=()=>{V.open(),q((()=>{H.current&&H.current.focus()}),220)},K=V.close,X=(0,c.useCallback)((()=>{G(),K(),z.current&&z.current.focus()}),[G,K]);(0,c.useEffect)((()=>{if(V.isExpanded){const e=e=>{var t,n;(null===(t=z.current)||void 0===t?void 0:t.contains(e.target))||(null===(n=H.current)||void 0===n?void 0:n.contains(e.target))||X()};return window.addEventListener("mousedown",e),window.addEventListener("touchstart",e),()=>{window.removeEventListener("mousedown",e),window.removeEventListener("touchstart",e)}}}),[V.isExpanded,X]);const Q=e=>c.createElement(Ot,Object.assign({key:e.value,id:`${D}_${e.value}`,role:"option","aria-selected":e.value===l,"aria-disabled":e.disabled,label:e.label,icon:e.icon,onClick:()=>(e=>{e.disabled||(V.close(),u(e.value))})(e),isSelected:e.value===l},F.getItemAttributes(e)),f?f(e):null);let ee=c.createElement(Nt,{isPlaceholder:!0,_disabled:p},v);return(null==$?void 0:$.value)&&(ee=_?c.createElement(Nt,{_disabled:p},_($)):c.createElement(c.Fragment,null,$.icon&&c.createElement(Mt,null,c.createElement($.icon,null)),c.createElement(Nt,{_disabled:p},$.label))),c.createElement(Ct,{block:b,className:P,style:Object.assign(Object.assign({},I),L)},c.createElement(ke,{as:"div",id:M,text:e,required:t,tooltipText:i,hidden:n}),o?c.createElement(W,{id:R,text:o,marginBlockStart:"4px"}):null,c.createElement(Lt,{onKeyDown:e=>{if(V.isExpanded)switch(e.key){case"Tab":e.preventDefault();break;case"Escape":e.preventDefault(),e.stopPropagation(),X();break;case"ArrowUp":e.preventDefault(),F.activatePrevItem();break;case"ArrowDown":e.preventDefault(),F.activateNextItem();break;case"Home":F.activateFirstItem();break;case"End":F.activateLastItem();break;case" ":case"Enter":e.preventDefault(),X(),F.activeItem&&u(F.activeItem.value)}else switch(e.key){case"ArrowUp":case"ArrowDown":e.preventDefault(),e.stopPropagation(),Y()}},hasDescription:Boolean(o),isLabelHidden:Boolean(n)},c.createElement(jt,{type:"button",ref:e=>{z.current=e,V.setAnchorRef(e)},id:N,"aria-labelledby":`${M} ${N}`,"aria-describedby":a?B:o?R:void 0,"aria-haspopup":"listbox","aria-controls":D,"aria-expanded":V.isExpanded,"aria-invalid":Boolean(a),"aria-required":t,disabled:p,size:s,onClick:()=>{V.isExpanded?X():(de.flushSync((()=>{Y()})),F.activateItem(null!=$?$:null))},hasError:Boolean(a)},ee,c.createElement(Dt,null),c.createElement(Rt,{isExpanded:V.isExpanded})),c.createElement(_t,Object.assign({},V),c.createElement(Bt,{ref:e=>{H.current=e,F.setListRef(e)},id:D,role:"listbox","aria-labelledby":M,"aria-activedescendant":F.activeItem?`${D}_${F.activeItem.value}`:void 0,tabIndex:-1},g?h.map(((e,t)=>c.createElement(c.Fragment,{key:e.label},t>0&&c.createElement(It,{marginBlockStart:"4px"}),y?y(e,Q):c.createElement(bt,{group:e},e.options.map((e=>Q(e))))))):m.map((e=>Q(e)))))),a?c.createElement(Ee,{id:B,text:a,marginBlockStart:"4px"}):null,r?c.createElement(Z,{text:r,marginBlockStart:"4px"}):null)};n(21380);const Ft="910ms",Vt=(0,S.i7)({"0%":{cx:17,r:17},"10%":{cx:18,r:17},"13.3%":{cx:19.5,r:17.8},"16.7%":{cx:21.5,r:18.5},"20%":{cx:24,r:20},"23.3%":{cx:30,r:21.5},"26.7%":{cx:42,r:21.5},"30%":{cx:46.5,r:19.8},"33.3%":{cx:49.5,r:18.2},"36.7%":{cx:50.5,r:17.8},"40%":{cx:51.5,r:17.2},"43.3%":{cx:53,r:17},"56.7%":{cx:53,r:17},"60%":{cx:52,r:17},"63.3%":{cx:51,r:16},"66.7%":{cx:49,r:15},"70%":{cx:46.5,r:12.8},"73.3%":{cx:41.5,r:11.2},"76.7%":{cx:28.5,r:11.2},"80%":{cx:24,r:13},"83.3%":{cx:21,r:15},"86.7%":{cx:19,r:16},"90%":{cx:18,r:17},"100%":{cx:17,r:17}}),zt=(0,S.i7)({"0%":{cx:53,r:17},"6.7%":{cx:52.5,r:17},"10%":{cx:51.8,r:16.9},"13.3%":{cx:51,r:16},"16.7%":{cx:49,r:15},"20%":{cx:46,r:13},"23.3%":{cx:41.5,r:11.2},"26.7%":{cx:28.5,r:11.2},"30%":{cx:24,r:13},"33.3%":{cx:21,r:15},"36.7%":{cx:19,r:16},"40%":{cx:18,r:16.5},"43.3%":{cx:17,r:17},"53.3%":{cx:17,r:17},"56.7%":{cx:17.5,r:17.2},"60%":{cx:18.5,r:17.2},"63.3%":{cx:19.5,r:17.8},"66.7%":{cx:21,r:18},"70%":{cx:23.5,r:19.8},"73.3%":{cx:28,r:21},"76.7%":{cx:42,r:21},"80%":{cx:46.5,r:19.8},"83.3%":{cx:49,r:18},"86.7%":{cx:50,r:17.5},"90%":{cx:51.5,r:17.2},"93.3%":{cx:52.5,r:17.2},"100%":{cx:53,r:17}}),Ht={r:17,cy:68},qt={0:{fill:"rgb(255, 44, 85)",stroke:"rgb(255, 44, 85)",cx:53,animation:`${zt} ${Ft} linear infinite`},1:{fill:"rgb(58, 242, 255)",stroke:"rgb(58, 242, 255)",cx:17,animation:`${Vt} ${Ft} linear infinite`},2:{fill:"rgb(15, 15, 15)",strokeWidth:0,cx:17,animation:`${Vt} ${Ft} linear infinite`}},Gt=(0,u.default)("circle",{target:"eup464n0"})((({circleType:e,isBlack:t})=>[Ht,qt[e],t?{fill:"black"}:null]),"label:Circle;"),$t=(0,u.default)("svg",{target:"eup464n1"})({boxSizing:"border-box",display:"block"},(({center:e})=>Object.assign({},e&&{margin:"0px auto"})),"label:SvgContainer;"),Wt=(0,u.default)("div",{target:"eup464n2"})({boxSizing:"border-box",display:"block",width:"max-content",maxWidth:"200px"},(({center:e})=>Object.assign({},e&&{margin:"0px auto"})),"label:LoadingContainer;"),Zt=(0,u.default)("div",{target:"eup464n4"})({marginTop:"4px"},"label:TextContainer;");var Yt=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{id:t,size:n="large",center:i=!1,marginInline:o,marginInlineStart:a,marginInlineEnd:r,marginBlock:s,marginBlockStart:l,marginBlockEnd:u,alignSelf:p,deprecatedClassName:v,deprecatedStyle:m}=e,g=Yt(e,["id","size","center","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd","alignSelf","deprecatedClassName","deprecatedStyle"]);const h=d({marginInline:o,marginInlineStart:a,marginInlineEnd:r,marginBlock:s,marginBlockStart:l,marginBlockEnd:u,alignSelf:p}),_=Kt[n],f=J(t),y=`red-hole-${f}`,b=`green-hole-${f}`;return c.createElement($t,Object.assign({id:f,center:i,preserveAspectRatio:"none",viewBox:"-33 0 136 136",width:_,height:_,style:Object.assign(Object.assign({},m),h),className:v},g),c.createElement("defs",null,c.createElement("mask",{id:y},c.createElement("rect",{width:"100%",height:"100%",fill:"white",x:"-33"}),c.createElement(Gt,{circleType:0,isBlack:!0})),c.createElement("mask",{id:b},c.createElement("rect",{width:"100%",height:"100%",fill:"white",x:"-33"}),c.createElement(Gt,{circleType:1,isBlack:!0}))),c.createElement(Gt,{circleType:2}),c.createElement(Gt,{circleType:1,mask:`url(#${y})`}),c.createElement(Gt,{circleType:0,mask:`url(#${b})`}))},Qt=e=>{const{text:t,size:n="large",center:i,variant:o="light",deprecatedClassName:a,deprecatedStyle:r}=e,s=Yt(e,["text","size","center","variant","deprecatedClassName","deprecatedStyle"]);if(a&&console.warn('The \'deprecatedClassName\' prop is deprecated. Please use the associated style props instead (e.g. "marginInline", "flex")'),r&&console.warn('The \'deprecatedStyle\' prop is deprecated. Please use the associated style props instead (e.g. "marginInline", "flex")'),!t)return c.createElement(Xt,Object.assign({},e));let l;switch(o){case"light":l="TextSecondary";break;case"dark":l="ConstTextInverse"}return c.createElement(Wt,{center:i},c.createElement(Xt,Object.assign({},s,{size:n,center:!0,deprecatedClassName:a,deprecatedStyle:r})),c.createElement(Zt,null,c.createElement(w,{block:!0,align:"center",type:"small"===n?"P5-Semibold":"P4-Semibold",color:l},t)))};var Jt=n(16657),en=n(69272),tn=n(68395);const nn=(0,u.default)("ul",{target:"e117t4ax0"})({boxSizing:"border-box",pointerEvents:"none",margin:"0",padding:"4px",position:"fixed",top:"32px",left:"0",right:"0",display:"flex",flexDirection:"column",alignItems:"center",gap:"12px",[a.Small]:{top:"20px"}},"label:ToastFoundationContainer;"),on=(0,u.default)(tn.P.li,{target:"e117t4ax1"})({boxSizing:"border-box",pointerEvents:"auto",margin:"0 auto",background:m("ToastDefault"),backdropFilter:"blur(20px)",borderRadius:"4px",display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",padding:"9px 24px",position:"relative",maxWidth:"720px",minWidth:"400px",[a.Small]:{minWidth:"fit-content",maxWidth:"343px"}},(({minWidth:e})=>{if(void 0!==e)return{minWidth:`${e}px`}}),"label:ToastContainer;"),an=(0,u.default)("div",{target:"e117t4ax2"})({boxSizing:"border-box",flexGrow:0,flexShrink:0,display:"flex",justifyContent:"center",alignItems:"center",marginInlineEnd:"16px",color:m("ConstTextInverse"),svg:{width:"20px",height:"20px"}},"label:ToastIconContainer;"),rn=(0,u.default)(wt.A,{target:"e117t4ax3"})({color:m("Positive")},"label:ToastTickIcon;");const sn={initial:{opacity:0,y:-72},animate:{opacity:1,y:0,transition:{opacity:{duration:.3,ease:[.65,0,.35,1]},y:{duration:.5,ease:[.65,0,.35,1]}}},exit:{opacity:0,y:-72,transition:{opacity:{duration:.3,ease:[.65,0,.35,1]},y:{duration:.5,ease:[.65,0,.35,1]}}}},ln=e=>{var{durationMS:t=2e3,content:n,icon:i,onClose:o,onCloseComplete:a,changeDetected:r,minWidth:s,onMouseEnter:l,onMouseLeave:d}=e,u=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{_||null==a||a()}),[_]),c.useEffect((()=>{p.current&&m(t),p.current=!0}),[t]),c.useEffect((()=>{null===v?h():g((()=>{o()}),v)}),[v,o,r]),c.createElement(on,Object.assign({layout:!0,variants:sn,initial:"initial",animate:"animate",exit:"exit",minWidth:s,onHoverStart:e=>{m(null),null==l||l(e)},onHoverEnd:e=>{m(t),null==d||d(e)}},u),i&&c.createElement(an,null,i),c.createElement(w,{type:"P4-Semibold",color:"ConstTextInverse",align:i?"start":"center"},n))};let cn=0;const dn=c.forwardRef(((e,t)=>{const[n,i]=c.useState([]),o=(e,t)=>{const{message:n,hasTickIcon:o,customIcon:a,durationMS:r,minWidth:s,onCloseComplete:l,onClick:d,onMouseEnter:u,onMouseLeave:p}=t;i((t=>{const i=t.findIndex((t=>t.id===e)),v=[...t],m=Object.assign({},t[i]);let g;return v[i]=m,m.changeDetected=!m.changeDetected,void 0!==n&&(m.content=n),o?g=c.createElement(rn,null):void 0!==a&&(g=a),void 0!==g&&(m.icon=g),void 0!==r&&(m.durationMS=r),void 0!==s&&(m.minWidth=s),void 0!==l&&(m.onCloseComplete=l),void 0!==d&&(m.onClick=d),void 0!==u&&(m.onMouseEnter=u),void 0!==p&&(m.onMouseLeave=p),v}))},a=e=>{i((t=>t.filter((t=>t.id!==e))))},r=e=>{const t=function(e){const{id:t,message:n,hasTickIcon:i,customIcon:o,durationMS:r,onCloseComplete:s}=e,l=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{a(d)},changeDetected:!0},l)}(e),{id:n}=t;return i((i=>{const a=i.findIndex((e=>e.id===n));return-1!==a?(o(n,e),[i[a],...i.slice(0,a),...i.slice(a+1)]):[t,...i]})),n};return c.useImperativeHandle(t,(()=>({open:r,close:a,update:o,closeAll:()=>{i([])},all:()=>n.map((e=>e.id))})),[n]),c.createElement(nn,null,c.createElement(Jt.N,{initial:!1},n.map((e=>c.createElement(ln,Object.assign({key:e.id},e))))))})),un=new class{constructor(e){this.id="",this.id=e,this.toastFoundation=null}guardFoundation(){null===this.toastFoundation&&this.initialFoundation()}updateZIndex(e){if(!oe()||void 0===r)return;const t=r.querySelector(`#${this.id}`);t&&(t.style.zIndex=e.toString())}initialFoundation(){if(!oe()||void 0===r)return;if(r.querySelector(`#${this.id}`))return;const e=r.createElement("div");e.setAttribute("id",this.id),e.style.position="absolute",e.style.zIndex=s.toast.toString(),e.style.height="0",e.style.width="0",e.style.top="0",e.style.left="0",r.body.appendChild(e),(0,de.render)(c.createElement(dn,{ref:e=>{this.toastFoundation=e}}),e)}}("tux-toast-portal"),pn=e=>c.useMemo((()=>(e=>{var t;const n=null!==(t=null==e?void 0:e.zIndex)&&void 0!==t?t:s.toast;return{open:e=>(un.guardFoundation(),un.updateZIndex(n),un.toastFoundation.open(e)),update:(e,t)=>{var n;null===(n=un.toastFoundation)||void 0===n||n.update(e,t)},close:e=>{var t;return null===(t=un.toastFoundation)||void 0===t?void 0:t.close(e)},closeAll:()=>{var e;return null===(e=un.toastFoundation)||void 0===e?void 0:e.closeAll()},all:()=>{var e,t;return null!==(t=null===(e=un.toastFoundation)||void 0===e?void 0:e.all())&&void 0!==t?t:[]}}})(e)),[e]);var vn=n(81521);const mn="data-list-item-value";const gn=(0,u.default)("div",{target:"e1jafjyr0"})({position:"relative",overflowX:"auto",padding:"2px",paddingBottom:"0px"},"label:TabListWrapper;"),hn=(0,u.default)("div",{target:"e1jafjyr1"})((({align:e})=>({boxSizing:"border-box",display:"flex",justifyContent:{center:"space-around",start:"start",fitted:"start"}[e],alignItems:"center"})),"label:TabList;"),_n=(0,u.default)("div",{target:"e1jafjyr2"})((({align:e,active:t,disabled:n})=>Object.assign(Object.assign(Object.assign({boxSizing:"border-box",paddingInline:"24px",color:m("TextTertiary"),cursor:n?"default":"pointer",transition:"color 300ms linear"},"fitted"===e&&{flex:1,justifyContent:"center",padding:0}),t&&{color:m("TextPrimary")}),!n&&{"&:hover > *":{color:`${m("TextPrimary")} !important`}})),"label:TabWrapper;"),fn=(0,u.default)("button",{target:"e1jafjyr3"})((({align:e,active:t,disabled:n})=>Object.assign(Object.assign(Object.assign(Object.assign({boxSizing:"border-box",padding:0,margin:0,background:"transparent",border:"none",appearance:"none",textDecoration:"none",backgroundClip:"padding-box",paddingBlockStart:"8px",paddingBlockEnd:"8px",paddingInline:"10px",whiteSpace:"nowrap",display:"flex",flexDirection:"row",alignItems:"center"},"fitted"===e&&{width:"100%",justifyContent:"center"}),{color:m("TextTertiary"),cursor:n?"default":"pointer",transition:"color 300ms linear"}),t&&{color:m("TextPrimary")}),n&&{opacity:.36})),"label:Tab;"),yn=(0,u.default)("div",{target:"e1jafjyr4"})({boxSizing:"border-box",height:"2px",borderBottom:`0.5px solid ${m("LinePrimary2")}`,overflowX:"hidden"},"label:TabBar;"),bn=(0,u.default)("div",{target:"e1jafjyr5"})((({xOffset:e,xRtlOffset:t,length:n})=>({boxSizing:"border-box",background:m("TextPrimary"),position:"absolute",transform:`translateX(${e}px)`,width:`${n}px`,height:"2px",transition:"transform 300ms cubic-bezier(0.65, 0, 0.35, 1), width 300ms cubic-bezier(0.65, 0, 0.35, 1)",'[dir="rtl"] &':{transform:`translateX(${-t}px)`}})),"label:TabBarHighlight;"),wn=(0,u.default)("div",{target:"e1jafjyr6"})({paddingInlineEnd:"8px"},"label:TabIconBefore;"),xn=(0,u.default)("div",{target:"e1jafjyr7"})({paddingInlineStart:"8px"},"label:TabIconAfter;"),Tn=(0,u.default)("div",{target:"e1jafjyr8"})({},"label:TabPanel;"),kn=e=>{var{defaultTab:t,activeTab:n,tabs:i,align:o="start",onChange:a,isRTL:r=!1,marginInline:s,marginInlineStart:l,marginInlineEnd:u,marginBlock:p,marginBlockStart:v,marginBlockEnd:m,alignSelf:g,deprecatedClassName:h,deprecatedStyle:_}=e,f=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{const a=J(),r=e.filter((e=>!e.disabled)),[s,l]=(0,c.useState)(i||r.length>0&&r[0].id||e.length>0&&e[0].id||""),d=null!=n?n:s,u=e=>{o&&o(e),l(e)},p=(0,c.useRef)(null),v=e=>{var t;const n=null===(t=p.current)||void 0===t?void 0:t.querySelector(`[${mn}="${le(e)}"]`);null==n||n.focus()},m=()=>{0!==r.length&&(u(r[0].id),v(r[0].id))},g=()=>{0!==r.length&&(u(r[r.length-1].id),v(r[r.length-1].id))},h=()=>{if(0===r.length)return;let e=r.findIndex((e=>e.id===d))-1;e<0&&(e=t.shouldCycle?r.length-1:0),u(r[e].id),v(r[e].id)},_=()=>{if(0===r.length)return;let e=r.findIndex((e=>e.id===d))+1;e>=r.length&&(e=t.shouldCycle?0:r.length-1),u(r[e].id),v(r[e].id)},f=e=>{switch(e.key){case"ArrowLeft":e.preventDefault(),h();break;case"ArrowRight":e.preventDefault(),_();break;case"Home":e.preventDefault(),m();break;case"End":e.preventDefault(),g()}};return{activeTab:d,activateTab:u,activateNextTab:_,activatePrevTab:h,activateFirstTab:m,activateLastTab:g,getTabsRef:()=>p,setTabsRef:e=>{p.current=e},getTabListAttributes:()=>({role:"tablist",id:`${a}-tablist`,onKeyDown:f}),getTabWrapperAttributes:e=>{var t;return{disabled:null!==(t=e.disabled)&&void 0!==t&&t,active:d===e.id,onClick:()=>{e.disabled||u(e.id)},key:e.id}},getTabAttributes:e=>{var t;return{[mn]:e.id,role:"tab",id:`${a}-tab-${e.id}`,disabled:null!==(t=e.disabled)&&void 0!==t&&t,active:d===e.id,"aria-controls":`${a}-panel-${e.id}`,"aria-selected":d===e.id,tabIndex:d===e.id?0:-1}},getTabPanelAttributes:e=>e?{role:"tabpanel",id:`${a}-panel-${e.id}`,"aria-labelledby":`${a}-tab-${e.id}`,tabIndex:0,children:e.content}:{}}})(i,{shouldCycle:!0},n,t,a),[x,T]=(0,c.useState)(null),[k,S]=(0,c.useState)(null),[E,A]=(0,c.useState)(null),O=()=>{var e,t,n,i;const o=null===(t=null===(e=b.getTabsRef().current)||void 0===e?void 0:e.querySelector('[role="tablist"]'))||void 0===t?void 0:t.getBoundingClientRect(),a=null===(i=null===(n=b.getTabsRef().current)||void 0===n?void 0:n.querySelector(`[${mn}="${b.activeTab}"]`))||void 0===i?void 0:i.getBoundingClientRect();o&&a&&(T(a.left-o.left),S(o.right-a.right),A(a.width))};return(0,c.useLayoutEffect)((()=>{var e;setTimeout((()=>{O()}),400);const t=new vn.tb((e=>{setTimeout((()=>{O()}),400)})),n=null===(e=b.getTabsRef().current)||void 0===e?void 0:e.querySelector('[role="tablist"]');return n&&t.observe(n),()=>{n&&t.unobserve(n)}}),[b.activeTab,r]),c.createElement("div",Object.assign({ref:b.setTabsRef,className:h,style:Object.assign(Object.assign({},_),y)},f),c.createElement(gn,null,c.createElement(hn,Object.assign({align:o},b.getTabListAttributes()),i.map((e=>c.createElement(_n,Object.assign({align:o},b.getTabWrapperAttributes(e),{key:e.id}),c.createElement(fn,Object.assign({},b.getTabAttributes(e),{align:o}),e.icon&&"after"!==e.iconPosition&&c.createElement(wn,null,c.createElement(e.icon,null)),c.createElement(w,{type:"P3-Semibold"},e.title),e.icon&&"after"===e.iconPosition&&c.createElement(xn,null,c.createElement(e.icon,null))))))),c.createElement(yn,null,null!==x&&null!==k&&null!==E&&c.createElement(bn,{xOffset:x,xRtlOffset:k,length:E}))),c.createElement(Tn,Object.assign({},b.getTabPanelAttributes(i.find((e=>e.id===b.activeTab))))))};var Sn=n(15928);n.p;const En=[{label:"12",value:0},{label:"01",value:1},{label:"02",value:2},{label:"03",value:3},{label:"04",value:4},{label:"05",value:5},{label:"06",value:6},{label:"07",value:7},{label:"08",value:8},{label:"09",value:9},{label:"10",value:10},{label:"11",value:11}],An=[{label:"12",value:12},{label:"01",value:13},{label:"02",value:14},{label:"03",value:15},{label:"04",value:16},{label:"05",value:17},{label:"06",value:18},{label:"07",value:19},{label:"08",value:20},{label:"09",value:21},{label:"10",value:22},{label:"11",value:23}],On=[{label:"00",value:0},{label:"01",value:1},{label:"02",value:2},{label:"03",value:3},{label:"04",value:4},{label:"05",value:5},{label:"06",value:6},{label:"07",value:7},{label:"08",value:8},{label:"09",value:9},{label:"10",value:10},{label:"11",value:11},{label:"12",value:12},{label:"13",value:13},{label:"14",value:14},{label:"15",value:15},{label:"16",value:16},{label:"17",value:17},{label:"18",value:18},{label:"19",value:19},{label:"20",value:20},{label:"21",value:21},{label:"22",value:22},{label:"23",value:23}],Pn=new Intl.DateTimeFormat("en-US",{hour:"2-digit",minute:"2-digit",second:"2-digit",hourCycle:"h23"}),In=(e,t)=>{const n=new Date(1970,0,1,e,t);return Pn.format(n)},Cn=({label:e,required:t,hideLabel:n,tooltipText:i,description:o,hintText:a,size:r="small",value:s,onChange:l,disabled:u,minuteIncrement:p=1,isTimeDisabled:v,invalidTimeMessage:m,locale:g,marginInline:h,marginInlineStart:_,marginInlineEnd:f,marginBlock:y,marginBlockStart:b,marginBlockEnd:x,alignSelf:T,flex:k})=>{const S=J(),E=`${S}_input`,A=`${S}_description`,O=`${S}_error`,P=st(),I=(0,c.useRef)(null),C=(0,c.useRef)(null),L=(0,c.useRef)(null),j=(e=>{const t=new Date(`1970-01-01T${e}`);return isNaN(t.valueOf())?null:t})(s);if(!j)throw new Error(`Value "${s}" is not a valid time string.`);const M=new Intl.DateTimeFormat(g,{hour:"2-digit",minute:"2-digit"}),N=M.formatToParts(j).some((e=>"dayPeriod"===e.type)),D=j.getHours(),R=j.getMinutes(),B=D<12,U=null==v?void 0:v(In(D,R)),F=N?B?En:An:On,V=(0,c.useMemo)((()=>Array.from({length:60/p},((e,t)=>({label:(t*p).toString().padStart(2,"0"),value:t*p})))),[p]),z=(0,c.useMemo)((()=>{const e=[];for(let t=0;t<24;t++)e[t]=V.every((e=>!!v&&v(In(t,e.value))));return t=>e[t]}),[v,V]),H=e=>{if(I.current){const t=F.findIndex((e=>e.value===D));I.current.scrollTo({top:32*t,behavior:e})}},q=e=>{if(C.current){const t=V.findIndex((e=>e.value===R));C.current.scrollTo({top:32*t,behavior:e})}},G=e=>{if(L.current){const t=B?0:1;L.current.scrollTo({top:32*t,behavior:e})}},$=e=>{e&&!B&&l(In(D-12,R)),!e&&B&&l(In(D+12,R))};(0,c.useLayoutEffect)((()=>{q("auto"),H("auto"),G("auto")}),[P.isExpanded]),(0,c.useLayoutEffect)((()=>{H("smooth"),G("smooth")}),[D]),(0,c.useLayoutEffect)((()=>{q("smooth")}),[R]);const Y=d({marginInline:h,marginInlineStart:_,marginInlineEnd:f,marginBlock:y,marginBlockStart:b,marginBlockEnd:x,alignSelf:T,flex:k});return c.createElement("div",{style:Y},c.createElement(ke,{htmlFor:E,text:e,required:t,tooltipText:i,hidden:n}),o?c.createElement(W,{id:A,text:o,marginBlockStart:"4px"}):null,c.createElement("div",{className:(0,ee.A)("_TUXTimeInput-inputContainer",{"_TUXTimeInput-inputContainer--hasDescription":Boolean(o),"_TUXTimeInput-inputContainer--isLabelHidden":n})},c.createElement("button",Object.assign({id:E,type:"button",className:(0,ee.A)("_TUXTimeInput-button",`_TUXTimeInput-button--${r}`,{"_TUXTimeInput-button--error":U}),disabled:u},P.anchorProps),c.createElement(Sn.A,{className:"_TUXTimeInput-buttonIcon"}),c.createElement(w,{type:"P3-Regular",color:u?"TextQuaternary":"TextPrimary",truncate:!0},M.format(j))),c.createElement(dt,Object.assign({},P.popoverProps),c.createElement("div",{className:"_TUXTimeInput-popoverContent"},c.createElement("div",{className:"_TUXTimeInput-list",ref:I},F.map((e=>c.createElement("div",{key:e.label,className:(0,ee.A)("_TUXTimeInput-timeOption",{"_TUXTimeInput-timeOption--selected":e.value===D,"_TUXTimeInput-timeOption--disabled":z(e.value)}),onClick:()=>{return t=e.value,void l(In(t,R));var t}},e.label)))),c.createElement("div",{className:"_TUXTimeInput-list",ref:C},V.map((e=>c.createElement("div",{key:e.label,className:(0,ee.A)("_TUXTimeInput-timeOption",{"_TUXTimeInput-timeOption--selected":e.value===R,"_TUXTimeInput-timeOption--disabled":null==v?void 0:v(In(D,e.value))}),onClick:()=>{return t=e.value,void l(In(D,t));var t}},e.label)))),N?c.createElement("div",{className:"_TUXTimeInput-list",ref:L},c.createElement("div",{className:(0,ee.A)("_TUXTimeInput-timeOption",{"_TUXTimeInput-timeOption--selected":B}),onClick:()=>$(!0)},(e=>{const t=new Date(1970,0,1,1);return e.formatToParts(t).find((e=>"dayPeriod"===e.type)).value})(M)),c.createElement("div",{className:(0,ee.A)("_TUXTimeInput-timeOption",{"_TUXTimeInput-timeOption--selected":!B}),onClick:()=>$(!1)},(e=>{const t=new Date(1970,0,1,23);return e.formatToParts(t).find((e=>"dayPeriod"===e.type)).value})(M))):null))),U?c.createElement(Ee,{id:O,text:m,marginBlockStart:"4px"}):null,a?c.createElement(Z,{text:a,marginBlockStart:"4px"}):null)};var Ln=n(66283);const jn=e=>{var{icon:t,size:n,color:i,background:o,autoMirror:a,marginInline:r,marginInlineStart:s,marginInlineEnd:l,marginBlock:u,marginBlockStart:p,marginBlockEnd:v,alignSelf:g,deprecatedStyle:h,deprecatedClassName:_}=e,f=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oc.createElement("div",{className:(0,ee.A)("_TUXSkeleton","_TUXSkeletonRectangle"),style:{width:e,height:t,marginBlockStart:n,marginBlockEnd:i,marginInlineStart:o,marginInlineEnd:a}}));var Nn=n(63736);const Dn=(0,u.default)("div",{target:"e1wuf0b30"})({boxSizing:"border-box"},"label:ModalContainer;"),Rn=(0,u.default)("div",{target:"e1wuf0b31"})({boxSizing:"border-box",position:"fixed",top:"0px",right:"0px",bottom:"0px",left:"0px",display:"flex",justifyContent:"center",alignItems:"center",overflow:"auto"},"label:ModalContentContainer;"),Bn=(0,u.default)("div",{target:"e1wuf0b32"})({display:"flex",justifyContent:"center",alignItems:"flex-start",maxHeight:"100vh",overflow:"visible"},"label:ModalContentVerticalPositionContainer;"),Un=(0,u.default)("div",{target:"e1wuf0b33"})({display:"flex",justifyContent:"center",alignItems:"center",padding:"32px 16px",maxWidth:"100vw"},"label:ModalContentVerticalPositionPadding;"),Fn=(0,u.default)("section",{target:"e1wuf0b34"})({boxSizing:"border-box",display:"flex",flexDirection:"column",alignItems:"stretch",justifyContent:"flex-start",position:"relative",outline:0,maxWidth:"calc(100vw - 32px)",background:m("BGPrimary"),boxShadow:"0px 2px 12px rgba(0, 0, 0, 0.12)",borderRadius:"8px",overflow:"hidden"},(({size:e,transitionStatus:t,fullHeight:n,fullWidth:i,transparent:o,compact:a})=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"Small"===e&&{width:"400px"}),"Medium"===e&&{width:"764px"}),"Large"===e&&{width:"1000px"}),n&&{height:"calc(100vh - 64px)",minHeight:"178px"}),i&&{width:"calc(100vw - 32px)"}),o&&{background:"transparent",boxShadow:"none"}),a&&{width:"auto"}),{transitionProperty:"transform, opacity",transitionDuration:"300ms",transitionTimingFunction:"cubic-bezier(0.65, 0, 0.35, 1)",opacity:0,transform:"scale(0.8)"}),t===ie.kp&&{opacity:0,transform:"scale(0.8)"}),t===ie.ze&&{transitionDuration:"300ms",transitionTimingFunction:"linear",opacity:0,transform:"scale(1)"}),t===ie.ns&&{opacity:1,transform:"none"}),t===ie._K&&{opacity:1,transform:"none"})),"label:ModalContentSection;"),Vn=(0,u.default)("div",{target:"e1wuf0b35"})({boxSizing:"border-box",position:"fixed",top:"0px",right:"0px",bottom:"0px",left:"0px",background:m("SDSecondary")},(({transitionStatus:e})=>Object.assign(Object.assign(Object.assign(Object.assign({transitionProperty:"opacity",transitionDuration:"300ms",transitionTimingFunction:"linear",opacity:0},e===ie.kp&&{opacity:0}),e===ie.ze&&{opacity:0}),e===ie.ns&&{opacity:1}),e===ie._K&&{opacity:1})),"label:ModalBackdrop;");m("BGSecondary2"),m("TextSecondary");var zn=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o(0,c.useContext)(Hn),Gn=({className:e,style:t,transitionStatus:n})=>{const{closeOnBackdropClick:i,onClose:o}=qn();return c.createElement(Vn,{className:e,style:t,transitionStatus:n,onClick:()=>{i&&(null==o||o("backdrop"))}})},$n=({size:e="Medium",transitionStatus:t,fullHeight:n,fullWidth:i,transparent:o,compact:a,children:r})=>{const s=c.useRef(null),l=c.useRef(null),d=qn(),{onClose:u,closeOnEsc:p,closeOnBackdropClick:v,isOpen:m,size:g,onClick:h,headerId:_,bodyId:f}=d,y=zn(d,["onClose","closeOnEsc","closeOnBackdropClick","isOpen","size","onClick","headerId","bodyId"]),b=c.useCallback((e=>{"Escape"===e.key&&p&&(null==u||u("esc"))}),[u,p]),w=c.useCallback((e=>{v&&s.current===l.current&&(null==u||u("backdrop"))}),[u,v]),x=c.useCallback((e=>{s.current=e.target}),[]),T=c.useCallback((e=>{l.current=e.target}),[]);return c.createElement(Rn,{tabIndex:-1,onKeyDown:b,onClick:w,onMouseDown:x,onMouseUp:T},c.createElement(Bn,null,c.createElement(Un,null,c.createElement(Fn,Object.assign({role:"dialog","aria-modal":"true","aria-labelledby":_,"aria-describedby":f,size:e,transitionStatus:t,fullHeight:n,fullWidth:i,transparent:o,compact:a,onClick:e=>{e.stopPropagation(),null==h||h(e)}},y),r))))},Wn=e=>{var{isOpen:t,onClose:n,onCloseComplete:i,closeOnEsc:o=!0,closeOnBackdropClick:a=!0,size:r,fullHeight:s,fullWidth:l,transparent:d,compact:u,children:p}=e,v=zn(e,["isOpen","onClose","onCloseComplete","closeOnEsc","closeOnBackdropClick","size","fullHeight","fullWidth","transparent","compact","children"]);const[m,g]=(0,c.useState)(!1),[h,_]=(0,c.useState)(!1),[f,y]=re(),b=J(),w=`${b}_header`,x=`${b}_body`,T=c.useCallback((e=>{y(),e?(g(!0),f((()=>{_(!0)}),null)):(_(!1),f((()=>{g((t=>(e!==t&&(null==i||i()),e)))}),300))}),[y,i,f]);c.useEffect((()=>{T(Boolean(t))}),[T,t]);const k=Object.assign({isOpen:t,onClose:n,closeOnEsc:o,closeOnBackdropClick:a,size:r,headerId:w,bodyId:x},v);return c.createElement(c.Fragment,null,m?c.createElement(Hn.Provider,{value:k},c.createElement(ue,null,c.createElement("div",null,c.createElement(at.Ay,{autoFocus:!0,returnFocus:!0},c.createElement(Nn.A,{removeScrollBar:!0,enabled:!0},c.createElement(ie.Ay,{in:h,timeout:300},(e=>c.createElement(Dn,null,c.createElement(Gn,{transitionStatus:e}),c.createElement($n,{size:r,transitionStatus:e,fullHeight:s,fullWidth:l,transparent:d,compact:u},p))))))))):null)};const Zn=e=>{var{isOpen:t,onClose:n,closeOnEsc:i,closeOnBackdropClick:o,size:a,fullHeight:r,fullWidth:s,transparent:l,compact:d,children:u}=e,p=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{var{children:t}=e,n=Kn(e,["children"]);return c.createElement("div",Object.assign({className:"_TUXModalTitle"},n),c.createElement(w,{type:"P1-Bold",as:"h1",color:"TextPrimary"},t))},Qn=e=>{var{children:t}=e,n=Kn(e,["children"]);return c.createElement("div",Object.assign({className:"_TUXModalBody"},n),c.createElement(w,{type:"P3-Regular",color:"TextPrimary"},t))},Jn=e=>{var{children:t}=e,n=Kn(e,["children"]);return c.createElement("div",Object.assign({className:"_TUXModalFooter"},n),t)},ei=e=>{var t=Kn(e,[]);return c.createElement(It,Object.assign({},t))},ti=({onClick:e})=>c.createElement("button",{type:"button",className:"_TUXModalCloseButton",onClick:e},c.createElement(Yn.A,null));n.p;const ni=e=>{var{transitionStatus:t,open:n,close:i,isOpen:o,width:a,height:r,children:s,hasCloseButton:l=!1,transparent:d=!1,mountNode:u,deprecatedClassName:p,deprecatedStyle:v}=e,m=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{"Escape"===e.key&&i("esc")}),[i]),f=(0,c.useCallback)((()=>{g.current===h.current&&i("backdrop")}),[i]),y=(0,c.useCallback)((e=>{g.current=e.target}),[]),b=(0,c.useCallback)((e=>{h.current=e.target}),[]);return"unmounted"===t?null:c.createElement(ue,{mountNode:u},c.createElement(at.Ay,{autoFocus:!0,returnFocus:!0},c.createElement(Nn.A,{removeScrollBar:!0,enabled:!0},c.createElement("div",{className:"_TUXModal-wrapper",tabIndex:-1,onKeyDown:_,onClick:f,onMouseDown:y,onMouseUp:b},c.createElement("div",{className:"_TUXModal-verticalPositionWrapper"},c.createElement("div",{className:"_TUXModal-verticalPaddingWrapper"},c.createElement("div",{className:(0,ee.A)("_TUXModal-backdrop",`_TUXModal-backdrop--${t}`)}),c.createElement("div",Object.assign({role:"dialog","aria-modal":"true",className:(0,ee.A)("_TUXModal",`_TUXModal--width-${a}`,`_TUXModal--height-${r}`,`_TUXModal--${t}`,d&&"_TUXModal--transparent",p),style:v,onClick:e=>{e.stopPropagation()}},m),s,l&&c.createElement("div",{className:"_TUXModal-closeButtonWrapper"},c.createElement(ti,{onClick:()=>i("closeButton")})))))))))},ii=e=>{const{onOpen:t,onClose:n,onOpenComplete:i,onCloseComplete:o,closeOnEsc:a=!0,closeOnBackdropClick:r=!0}=null!=e?e:{},[s,l]=re(),[d,u]=(0,c.useState)("unmounted");return{transitionStatus:d,isOpen:"entering"===d||"entered"===d,open:()=>{null==t||t(),l(),u("exited"),s((()=>{u("entering"),s((()=>{u("entered"),null==i||i()}),300)}),20)},close:e=>{"backdrop"===e&&!r||"esc"===e&&!a||(null==n||n(e),l(),u("exiting"),s((()=>{u("unmounted"),null==o||o(e)}),300))}}}},58542:(e,t,n)=>{"use strict";var i;n.d(t,{AWJ:()=>Ja,Abx:()=>Kn,BQX:()=>sr,Baq:()=>Sa,BbK:()=>fa,C1D:()=>Ka,CD$:()=>nr,CKq:()=>Ir,CWs:()=>ss,CrH:()=>cs,DBO:()=>Qs,DUM:()=>_l,Dol:()=>gr,Eq8:()=>mr,Fm:()=>ti,FuX:()=>Vr,FvE:()=>_r,GDA:()=>ja,GeO:()=>es,Gil:()=>Ks,Gjn:()=>Gr,HEM:()=>xa,HIr:()=>y,HMQ:()=>Sr,HVc:()=>ba,I05:()=>Ls,I7T:()=>Lr,IuZ:()=>ms,JPW:()=>tr,K64:()=>Yr,Kbf:()=>Hr,KhS:()=>kl,LDC:()=>Qa,LdG:()=>os,LyW:()=>dr,Mav:()=>Ha,Mzi:()=>ii,N0Y:()=>rl,N9v:()=>Ss,ND_:()=>Nr,O6d:()=>Fa,OBN:()=>Dr,OH6:()=>Zr,ON7:()=>Xa,OVK:()=>Ms,Om6:()=>kr,PB_:()=>us,PH3:()=>Xs,QKx:()=>fl,Qkv:()=>Us,Qoe:()=>hs,R$6:()=>vs,RBK:()=>$r,Shl:()=>bl,Su8:()=>rs,T4n:()=>ya,TIk:()=>wr,Tj4:()=>l,Twf:()=>Oa,Tyj:()=>gs,U5X:()=>gl,VA8:()=>Ra,VMf:()=>$a,VuH:()=>Na,WI2:()=>Za,WZJ:()=>za,WZi:()=>ar,XWZ:()=>Cs,XaL:()=>Br,Xib:()=>Wr,Xwo:()=>wl,Y4q:()=>Xr,Z6u:()=>wa,ZAy:()=>Or,ZPA:()=>pl,_xK:()=>ls,aCW:()=>Ya,aL3:()=>lr,b$L:()=>qa,bt4:()=>ts,bwt:()=>Rr,c3W:()=>Cr,c5_:()=>is,cwz:()=>Jr,dTl:()=>vr,dpn:()=>xr,dvW:()=>Va,eU:()=>Vn,fUE:()=>Kr,g4Y:()=>er,gGu:()=>hl,gn:()=>Ts,h$y:()=>Bs,hIm:()=>Sl,hN4:()=>zr,hTJ:()=>Ia,hdF:()=>xs,i8t:()=>jr,ipH:()=>Fr,jdl:()=>tl,jgG:()=>Ba,juU:()=>ks,k1d:()=>ur,l$J:()=>hr,lKh:()=>Qr,lcR:()=>Er,ldC:()=>rr,lqC:()=>La,m6j:()=>ir,m8I:()=>ws,mPD:()=>ns,maO:()=>Ca,nDe:()=>Wa,nOL:()=>Ys,nb1:()=>Tl,neO:()=>Ma,o4f:()=>br,oil:()=>Pr,olQ:()=>Ta,osi:()=>Mr,otH:()=>ei,pdK:()=>or,pfZ:()=>il,phF:()=>fs,pmp:()=>ol,pnX:()=>pr,qMW:()=>$s,qY7:()=>fr,qaZ:()=>ni,r1L:()=>as,rGY:()=>Ga,rn1:()=>Pa,rs3:()=>ka,rxD:()=>Xc,sCe:()=>ys,sJ:()=>cr,sLX:()=>yr,sO8:()=>yl,sgs:()=>Os,t4G:()=>Tr,tDo:()=>ps,uCx:()=>_s,wO8:()=>qr,xJb:()=>Ua,xTL:()=>Ar,y3_:()=>Ur,ysD:()=>Da});var o=n(40099),a=n(18499);e=n.hmd(e);var r=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))},s=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o(c((()=>{document.documentElement.dataset.tuxColorScheme=e}),[e]),o.createElement(d.Provider,{value:e},t)),p=2e3,v="undefined"==typeof window,m=()=>{},g=(...e)=>{const t=e.filter(Boolean);return t.length<=1?t[0]:t=>{e.forEach((e=>{((e,t)=>{"function"==typeof e?e(t):"object"==typeof e&&e&&"current"in e&&(e.current=t)})(e,t)}))}},h=(0,o.createContext)(void 0),_=({safeAreaInsetTop:e,zIndexConfig:t,children:n})=>{var i,a,r,s,l,d,u,m;const[g,_]=(0,o.useState)("unknown"),f=void 0!==e?`${e}px`:"env(safe-area-inset-top)",y={modal:null!==(i=null==t?void 0:t.modal)&&void 0!==i?i:p,dialog:null!==(a=null==t?void 0:t.dialog)&&void 0!==a?a:p,popover:null!==(r=null==t?void 0:t.popover)&&void 0!==r?r:p,sheet:null!==(s=null==t?void 0:t.sheet)&&void 0!==s?s:p,tooltip:null!==(l=null==t?void 0:t.tooltip)&&void 0!==l?l:p,toast:null!==(d=null==t?void 0:t.toast)&&void 0!==d?d:3e3,bar:null!==(u=null==t?void 0:t.bar)&&void 0!==u?u:1e3,select:null!==(m=null==t?void 0:t.select)&&void 0!==m?m:p};return c((()=>{if(v)return;const e=window.matchMedia("(prefers-color-scheme: dark)");_(e.matches?"dark":"light");const t=e=>{_(e.matches?"dark":"light")};return e.addEventListener?e.addEventListener("change",t):e.addListener(t),()=>{e.removeEventListener?e.removeEventListener("change",t):e.removeListener(t)}}),[]),o.createElement(h.Provider,{value:{colorSchemeSystemPreference:g,safeAreaInsetTop:f,zIndex:y}},n)},f=()=>{const e=(0,o.useContext)(h);if(void 0===e)throw Error("TUXEnvironmentContext is undefined. Make sure to wrap your app with TUXProvider.");return e},y=()=>{const e=(0,o.useContext)(d),{colorSchemeSystemPreference:t}=f();if(void 0===e)throw new Error("TUXColorSchemeContext is undefined. Make sure to wrap your app with TUXProvider.");return"system"===e?t:e},b=(0,o.createContext)(void 0),w=({textDirection:e,children:t})=>(c((()=>{document.documentElement.dir=e}),[e]),o.createElement(b.Provider,{value:e},t)),x=()=>{const e=(0,o.useContext)(b);if(void 0===e)throw Error("TUXTextDirectionContext is undefined. Make sure to wrap your app with TUXProvider.");return e},T=Math.floor;function k(e){return E(e)?(e.nodeName||"").toLowerCase():"#document"}function S(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function E(e){return e instanceof Node||e instanceof S(e).Node}function A(e){return e instanceof Element||e instanceof S(e).Element}function O(e){return e instanceof HTMLElement||e instanceof S(e).HTMLElement}function P(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof S(e).ShadowRoot)}function I(e){if("html"===k(e))return e;const t=e.assignedSlot||e.parentNode||P(e)&&e.host||function(e){var t;return null==(t=(E(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}(e);return P(t)?t.host:t}function C(e){let t=e.activeElement;for(;null!=(null==(n=t)||null==(i=n.shadowRoot)?void 0:i.activeElement);){var n,i;t=t.shadowRoot.activeElement}return t}function L(e,t){if(!e||!t)return!1;const n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&P(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function j(){const e=navigator.userAgentData;return null!=e&&e.platform?e.platform:navigator.platform}function M(e){if(0===e.mozInputSource&&e.isTrusted)return!0;const t=/Android/i;return(t.test(j())||t.test(function(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map((e=>{let{brand:t,version:n}=e;return t+"/"+n})).join(" "):navigator.userAgent}()))&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType}function N(e){return 0===e.width&&0===e.height||1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"!==e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail}function D(e,t){const n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}function R(e){return(null==e?void 0:e.ownerDocument)||document}function B(e,t){if(null==t)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return null!=n.target&&t.contains(n.target)}function U(e){return"composedPath"in e?e.composedPath()[0]:e.target}const F="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function V(e){return O(e)&&e.matches(F)}function z(e){e.preventDefault(),e.stopPropagation()}const H=Math.min,q=Math.max,G=Math.round,$=Math.floor,W=e=>({x:e,y:e}),Z={left:"right",right:"left",bottom:"top",top:"bottom"},Y={start:"end",end:"start"};function K(e,t,n){return q(e,H(t,n))}function X(e,t){return"function"==typeof e?e(t):e}function Q(e){return e.split("-")[0]}function J(e){return e.split("-")[1]}function ee(e){return"x"===e?"y":"x"}function te(e){return"y"===e?"height":"width"}function ne(e){return["top","bottom"].includes(Q(e))?"y":"x"}function ie(e){return ee(ne(e))}function oe(e){return e.replace(/start|end/g,(e=>Y[e]))}function ae(e){return e.replace(/left|right|bottom|top/g,(e=>Z[e]))}function re(e){return"number"!=typeof e?function(e){return Object.assign({top:0,right:0,bottom:0,left:0},e)}(e):{top:e,right:e,bottom:e,left:e}}function se(e){const{x:t,y:n,width:i,height:o}=e;return{width:i,height:o,top:n,left:t,right:t+i,bottom:n+o,x:t,y:n}}function le(e,t,n){let{reference:i,floating:o}=e;const a=ne(t),r=ie(t),s=te(r),l=Q(t),c="y"===a,d=i.x+i.width/2-o.width/2,u=i.y+i.height/2-o.height/2,p=i[s]/2-o[s]/2;let v;switch(l){case"top":v={x:d,y:i.y-o.height};break;case"bottom":v={x:d,y:i.y+i.height};break;case"right":v={x:i.x+i.width,y:u};break;case"left":v={x:i.x-o.width,y:u};break;default:v={x:i.x,y:i.y}}switch(J(t)){case"start":v[r]-=p*(n&&c?-1:1);break;case"end":v[r]+=p*(n&&c?-1:1)}return v}function ce(e,t){return r(this,void 0,void 0,(function*(){var n;void 0===t&&(t={});const{x:i,y:o,platform:a,rects:r,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:p=!1,padding:v=0}=X(t,e),m=re(v),g=s[p?"floating"===u?"reference":"floating":u],h=se(yield a.getClippingRect({element:null==(n=yield null==a.isElement?void 0:a.isElement(g))||n?g:g.contextElement||(yield null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:l})),_="floating"===u?{x:i,y:o,width:r.floating.width,height:r.floating.height}:r.reference,f=yield null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating),y=(yield null==a.isElement?void 0:a.isElement(f))&&(yield null==a.getScale?void 0:a.getScale(f))||{x:1,y:1},b=se(a.convertOffsetParentRelativeRectToViewportRelativeRect?yield a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:_,offsetParent:f,strategy:l}):_);return{top:(h.top-b.top+m.top)/y.y,bottom:(b.bottom-h.bottom+m.bottom)/y.y,left:(h.left-b.left+m.left)/y.x,right:(b.right-h.right+m.right)/y.x}}))}function de(e){return ve(e)?(e.nodeName||"").toLowerCase():"#document"}function ue(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function pe(e){var t;return null==(t=(ve(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function ve(e){return e instanceof Node||e instanceof ue(e).Node}function me(e){return e instanceof Element||e instanceof ue(e).Element}function ge(e){return e instanceof HTMLElement||e instanceof ue(e).HTMLElement}function he(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof ue(e).ShadowRoot)}function _e(e){const{overflow:t,overflowX:n,overflowY:i,display:o}=Te(e);return/auto|scroll|overlay|hidden|clip/.test(t+i+n)&&!["inline","contents"].includes(o)}function fe(e){return["table","td","th"].includes(de(e))}function ye(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(e){return!1}}))}function be(e){const t=we(),n=Te(e);return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function we(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function xe(e){return["html","body","#document"].includes(de(e))}function Te(e){return ue(e).getComputedStyle(e)}function ke(e){return me(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Se(e){if("html"===de(e))return e;const t=e.assignedSlot||e.parentNode||he(e)&&e.host||pe(e);return he(t)?t.host:t}function Ee(e){const t=Se(e);return xe(t)?e.ownerDocument?e.ownerDocument.body:e.body:ge(t)&&_e(t)?t:Ee(t)}function Ae(e,t,n){var i;void 0===t&&(t=[]),void 0===n&&(n=!0);const o=Ee(e),a=o===(null==(i=e.ownerDocument)?void 0:i.body),r=ue(o);return a?t.concat(r,r.visualViewport||[],_e(o)?o:[],r.frameElement&&n?Ae(r.frameElement):[]):t.concat(o,Ae(o,[],n))}function Oe(e){const t=Te(e);let n=parseFloat(t.width)||0,i=parseFloat(t.height)||0;const o=ge(e),a=o?e.offsetWidth:n,r=o?e.offsetHeight:i,s=G(n)!==a||G(i)!==r;return s&&(n=a,i=r),{width:n,height:i,$:s}}function Pe(e){return me(e)?e:e.contextElement}function Ie(e){const t=Pe(e);if(!ge(t))return W(1);const n=t.getBoundingClientRect(),{width:i,height:o,$:a}=Oe(t);let r=(a?G(n.width):n.width)/i,s=(a?G(n.height):n.height)/o;return r&&Number.isFinite(r)||(r=1),s&&Number.isFinite(s)||(s=1),{x:r,y:s}}const Ce=W(0);function Le(e){const t=ue(e);return we()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Ce}function je(e,t,n,i){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),a=Pe(e);let r=W(1);t&&(i?me(i)&&(r=Ie(i)):r=Ie(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==ue(e))&&t}(a,n,i)?Le(a):W(0);let l=(o.left+s.x)/r.x,c=(o.top+s.y)/r.y,d=o.width/r.x,u=o.height/r.y;if(a){const e=ue(a),t=i&&me(i)?ue(i):i;let n=e,o=n.frameElement;for(;o&&i&&t!==n;){const e=Ie(o),t=o.getBoundingClientRect(),i=Te(o),a=t.left+(o.clientLeft+parseFloat(i.paddingLeft))*e.x,r=t.top+(o.clientTop+parseFloat(i.paddingTop))*e.y;l*=e.x,c*=e.y,d*=e.x,u*=e.y,l+=a,c+=r,n=ue(o),o=n.frameElement}}return se({width:d,height:u,x:l,y:c})}function Me(e){return je(pe(e)).left+ke(e).scrollLeft}function Ne(e,t,n){let i;if("viewport"===t)i=function(e,t){const n=ue(e),i=pe(e),o=n.visualViewport;let a=i.clientWidth,r=i.clientHeight,s=0,l=0;if(o){a=o.width,r=o.height;const e=we();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,l=o.offsetTop)}return{width:a,height:r,x:s,y:l}}(e,n);else if("document"===t)i=function(e){const t=pe(e),n=ke(e),i=e.ownerDocument.body,o=q(t.scrollWidth,t.clientWidth,i.scrollWidth,i.clientWidth),a=q(t.scrollHeight,t.clientHeight,i.scrollHeight,i.clientHeight);let r=-n.scrollLeft+Me(e);const s=-n.scrollTop;return"rtl"===Te(i).direction&&(r+=q(t.clientWidth,i.clientWidth)-o),{width:o,height:a,x:r,y:s}}(pe(e));else if(me(t))i=function(e,t){const n=je(e,!0,"fixed"===t),i=n.top+e.clientTop,o=n.left+e.clientLeft,a=ge(e)?Ie(e):W(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:o*a.x,y:i*a.y}}(t,n);else{const n=Le(e);i=Object.assign(Object.assign({},t),{x:t.x-n.x,y:t.y-n.y})}return se(i)}function De(e,t){const n=Se(e);return!(n===t||!me(n)||xe(n))&&("fixed"===Te(n).position||De(n,t))}function Re(e,t,n){const i=ge(t),o=pe(t),a="fixed"===n,r=je(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const l=W(0);if(i||!i&&!a)if(("body"!==de(t)||_e(o))&&(s=ke(t)),i){const e=je(t,!0,a,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else o&&(l.x=Me(o));return{x:r.left+s.scrollLeft-l.x,y:r.top+s.scrollTop-l.y,width:r.width,height:r.height}}function Be(e){return"static"===Te(e).position}function Ue(e,t){return ge(e)&&"fixed"!==Te(e).position?t?t(e):e.offsetParent:null}function Fe(e,t){const n=ue(e);if(ye(e))return n;if(!ge(e)){let t=Se(e);for(;t&&!xe(t);){if(me(t)&&!Be(t))return t;t=Se(t)}return n}let i=Ue(e,t);for(;i&&fe(i)&&Be(i);)i=Ue(i,t);return i&&xe(i)&&Be(i)&&!be(i)?n:i||function(e){let t=Se(e);for(;ge(t)&&!xe(t);){if(ye(t))return null;if(be(t))return t;t=Se(t)}return null}(e)||n}const Ve={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:i,strategy:o}=e;const a="fixed"===o,r=pe(i),s=!!t&&ye(t.floating);if(i===r||s&&a)return n;let l={scrollLeft:0,scrollTop:0},c=W(1);const d=W(0),u=ge(i);if((u||!u&&!a)&&(("body"!==de(i)||_e(r))&&(l=ke(i)),ge(i))){const e=je(i);c=Ie(i),d.x=e.x+i.clientLeft,d.y=e.y+i.clientTop}return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+d.x,y:n.y*c.y-l.scrollTop*c.y+d.y}},getDocumentElement:pe,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:i,strategy:o}=e;const a=[..."clippingAncestors"===n?ye(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let i=Ae(e,[],!1).filter((e=>me(e)&&"body"!==de(e))),o=null;const a="fixed"===Te(e).position;let r=a?Se(e):e;for(;me(r)&&!xe(r);){const t=Te(r),n=be(r);n||"fixed"!==t.position||(o=null),(a?!n&&!o:!n&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||_e(r)&&!n&&De(e,r))?i=i.filter((e=>e!==r)):o=t,r=Se(r)}return t.set(e,i),i}(t,this._c):[].concat(n),i],r=a[0],s=a.reduce(((e,n)=>{const i=Ne(t,n,o);return e.top=q(i.top,e.top),e.right=H(i.right,e.right),e.bottom=H(i.bottom,e.bottom),e.left=q(i.left,e.left),e}),Ne(t,r,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:Fe,getElementRects:function(e){return r(this,void 0,void 0,(function*(){const t=this.getOffsetParent||Fe,n=this.getDimensions,i=yield n(e.floating);return{reference:Re(e.reference,yield t(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}}))},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Oe(e);return{width:t,height:n}},getScale:Ie,isElement:me,isRTL:function(e){return"rtl"===Te(e).direction}};function ze(e,t,n,i){void 0===i&&(i={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:r="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=i,c=Pe(e),d=o||a?[...c?Ae(c):[],...Ae(t)]:[];d.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),a&&e.addEventListener("resize",n)}));const u=c&&s?function(e,t){let n,i=null;const o=pe(e);function a(){var e;clearTimeout(n),null==(e=i)||e.disconnect(),i=null}return function r(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),a();const{left:c,top:d,width:u,height:p}=e.getBoundingClientRect();if(s||t(),!u||!p)return;const v={rootMargin:-$(d)+"px "+-$(o.clientWidth-(c+u))+"px "+-$(o.clientHeight-(d+p))+"px "+-$(c)+"px",threshold:q(0,H(1,l))||1};let m=!0;function g(e){const t=e[0].intersectionRatio;if(t!==l){if(!m)return r();t?r(!1,t):n=setTimeout((()=>{r(!1,1e-7)}),1e3)}m=!1}try{i=new IntersectionObserver(g,Object.assign(Object.assign({},v),{root:o.ownerDocument}))}catch(e){i=new IntersectionObserver(g,v)}i.observe(e)}(!0),a}(c,n):null;let p,v=-1,m=null;r&&(m=new ResizeObserver((e=>{let[i]=e;i&&i.target===c&&m&&(m.unobserve(t),cancelAnimationFrame(v),v=requestAnimationFrame((()=>{var e;null==(e=m)||e.observe(t)}))),n()})),c&&!l&&m.observe(c),m.observe(t));let g=l?je(e):null;return l&&function t(){const i=je(e);!g||i.x===g.x&&i.y===g.y&&i.width===g.width&&i.height===g.height||n(),g=i,p=requestAnimationFrame(t)}(),n(),()=>{var e;d.forEach((e=>{o&&e.removeEventListener("scroll",n),a&&e.removeEventListener("resize",n)})),null==u||u(),null==(e=m)||e.disconnect(),m=null,l&&cancelAnimationFrame(p)}}const He=function(e){return void 0===e&&(e={}),{name:"flip",options:e,fn(t){return r(this,void 0,void 0,(function*(){var n,i;const{placement:o,middlewareData:a,rects:r,initialPlacement:l,platform:c,elements:d}=t,u=X(e,t),{mainAxis:p=!0,crossAxis:v=!0,fallbackPlacements:m,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:_=!0}=u,f=s(u,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if(null!=(n=a.arrow)&&n.alignmentOffset)return{};const y=Q(o),b=ne(l),w=Q(l)===l,x=yield null==c.isRTL?void 0:c.isRTL(d.floating),T=m||(w||!_?[ae(l)]:function(e){const t=ae(e);return[oe(e),t,oe(t)]}(l)),k="none"!==h;!m&&k&&T.push(...function(e,t,n,i){const o=J(e);let a=function(e,t,n){const i=["left","right"],o=["right","left"],a=["top","bottom"],r=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:i:t?i:o;case"left":case"right":return t?a:r;default:return[]}}(Q(e),"start"===n,i);return o&&(a=a.map((e=>e+"-"+o)),t&&(a=a.concat(a.map(oe)))),a}(l,_,h,x));const S=[l,...T],E=yield ce(t,f),A=[];let O=(null==(i=a.flip)?void 0:i.overflows)||[];if(p&&A.push(E[y]),v){const e=function(e,t,n){void 0===n&&(n=!1);const i=J(e),o=ie(e),a=te(o);let r="x"===o?i===(n?"end":"start")?"right":"left":"start"===i?"bottom":"top";return t.reference[a]>t.floating[a]&&(r=ae(r)),[r,ae(r)]}(o,r,x);A.push(E[e[0]],E[e[1]])}if(O=[...O,{placement:o,overflows:A}],!A.every((e=>e<=0))){var P,I;const e=((null==(P=a.flip)?void 0:P.index)||0)+1,t=S[e];if(t)return{data:{index:e,overflows:O},reset:{placement:t}};let n=null==(I=O.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:I.placement;if(!n)switch(g){case"bestFit":{var C;const e=null==(C=O.filter((e=>{if(k){const t=ne(e.placement);return t===b||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:C[0];e&&(n=e);break}case"initialPlacement":n=l}if(o!==n)return{reset:{placement:n}}}return{}}))}}},qe=e=>({name:"arrow",options:e,fn(t){return r(this,void 0,void 0,(function*(){const{x:n,y:i,placement:o,rects:a,platform:r,elements:s,middlewareData:l}=t,{element:c,padding:d=0}=X(e,t)||{};if(null==c)return{};const u=re(d),p={x:n,y:i},v=ie(o),m=te(v),g=yield r.getDimensions(c),h="y"===v,_=h?"top":"left",f=h?"bottom":"right",y=h?"clientHeight":"clientWidth",b=a.reference[m]+a.reference[v]-p[v]-a.floating[m],w=p[v]-a.reference[v],x=yield null==r.getOffsetParent?void 0:r.getOffsetParent(c);let T=x?x[y]:0;T&&(yield null==r.isElement?void 0:r.isElement(x))||(T=s.floating[y]||a.floating[m]);const k=b/2-w/2,S=T/2-g[m]/2-1,E=H(u[_],S),A=H(u[f],S),O=E,P=T-g[m]-A,I=T/2-g[m]/2+k,C=K(O,I,P),L=!l.arrow&&null!=J(o)&&I!==C&&a.reference[m]/2-(I{const i=new Map,o=Object.assign({platform:Ve},n),a=Object.assign(Object.assign({},o.platform),{_c:i});return((e,t,n)=>r(void 0,void 0,void 0,(function*(){const{placement:i="bottom",strategy:o="absolute",middleware:a=[],platform:r}=n,s=a.filter(Boolean),l=yield null==r.isRTL?void 0:r.isRTL(t);let c=yield r.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:u}=le(c,i,l),p=i,v={},m=0;for(let n=0;n{t.current=e})),t}const Xe=(e,t)=>Object.assign(Object.assign({},function(e){return void 0===e&&(e=0),{name:"offset",options:e,fn(t){return r(this,void 0,void 0,(function*(){var n,i;const{x:o,y:a,placement:s,middlewareData:l}=t,c=yield function(e,t){return r(this,void 0,void 0,(function*(){const{placement:n,platform:i,elements:o}=e,a=yield null==i.isRTL?void 0:i.isRTL(o.floating),r=Q(n),s=J(n),l="y"===ne(n),c=["left","top"].includes(r)?-1:1,d=a&&l?-1:1,u=X(t,e);let{mainAxis:p,crossAxis:v,alignmentAxis:m}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:Object.assign({mainAxis:0,crossAxis:0,alignmentAxis:null},u);return s&&"number"==typeof m&&(v="end"===s?-1*m:m),l?{x:v*d,y:p*c}:{x:p*c,y:v*d}}))}(t,e);return s===(null==(n=l.offset)?void 0:n.placement)&&null!=(i=l.arrow)&&i.alignmentOffset?{}:{x:o+c.x,y:a+c.y,data:Object.assign(Object.assign({},c),{placement:s})}}))}}}(e)),{options:[e,t]}),Qe=(e,t)=>Object.assign(Object.assign({},function(e){return void 0===e&&(e={}),{name:"shift",options:e,fn(t){return r(this,void 0,void 0,(function*(){const{x:n,y:i,placement:o}=t,a=X(e,t),{mainAxis:r=!0,crossAxis:l=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}}}=a,d=s(a,["mainAxis","crossAxis","limiter"]),u={x:n,y:i},p=yield ce(t,d),v=ne(Q(o)),m=ee(v);let g=u[m],h=u[v];if(r){const e="y"===m?"bottom":"right";g=K(g+p["y"===m?"top":"left"],g,g-p[e])}if(l){const e="y"===v?"bottom":"right";h=K(h+p["y"===v?"top":"left"],h,h-p[e])}const _=c.fn(Object.assign(Object.assign({},t),{[m]:g,[v]:h}));return Object.assign(Object.assign({},_),{data:{x:_.x-n,y:_.y-i}})}))}}}(e)),{options:[e,t]}),Je=(e,t)=>Object.assign(Object.assign({},He(e)),{options:[e,t]}),et=(e,t)=>Object.assign(Object.assign({},(e=>({name:"arrow",options:e,fn(t){const{element:n,padding:i}="function"==typeof e?e(t):e;return n&&(o=n,{}.hasOwnProperty.call(o,"current"))?null!=n.current?qe({element:n.current,padding:i}).fn(t):{}:n?qe({element:n,padding:i}).fn(t):{};var o}}))(e)),{options:[e,t]});var tt=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"].join(","),nt="undefined"==typeof Element,it=nt?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,ot=!nt&&Element.prototype.getRootNode?function(e){var t;return null==e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}:function(e){return null==e?void 0:e.ownerDocument},at=function e(t,n){var i;void 0===n&&(n=!0);var o=null==t||null===(i=t.getAttribute)||void 0===i?void 0:i.call(t,"inert");return""===o||"true"===o||n&&t&&e(t.parentNode)},rt=function e(t,n,i){for(var o=[],a=Array.from(t);a.length;){var r=a.shift();if(!at(r,!1))if("SLOT"===r.tagName){var s=r.assignedElements(),l=e(s.length?s:r.children,!0,i);i.flatten?o.push.apply(o,l):o.push({scopeParent:r,candidates:l})}else{it.call(r,tt)&&i.filter(r)&&(n||!t.includes(r))&&o.push(r);var c=r.shadowRoot||"function"==typeof i.getShadowRoot&&i.getShadowRoot(r),d=!at(c,!1)&&(!i.shadowRootFilter||i.shadowRootFilter(r));if(c&&d){var u=e(!0===c?r.children:c.children,!0,i);i.flatten?o.push.apply(o,u):o.push({scopeParent:r,candidates:u})}else a.unshift.apply(a,r.children)}}return o},st=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},lt=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||function(e){var t,n=null==e||null===(t=e.getAttribute)||void 0===t?void 0:t.call(e,"contenteditable");return""===n||"true"===n}(e))&&!st(e)?0:e.tabIndex},ct=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},dt=function(e){return"INPUT"===e.tagName},ut=function(e){var t=e.getBoundingClientRect(),n=t.width,i=t.height;return 0===n&&0===i},pt=function(e,t){return!(t.disabled||at(t)||function(e){return dt(e)&&"hidden"===e.type}(t)||function(e,t){var n=t.displayCheck,i=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var o=it.call(e,"details>summary:first-of-type")?e.parentElement:e;if(it.call(o,"details:not([open]) *"))return!0;if(n&&"full"!==n&&"legacy-full"!==n){if("non-zero-area"===n)return ut(e)}else{if("function"==typeof i){for(var a=e;e;){var r=e.parentElement,s=ot(e);if(r&&!r.shadowRoot&&!0===i(r))return ut(e);e=e.assignedSlot?e.assignedSlot:r||s===e.ownerDocument?r:s.host}e=a}if(function(e){var t,n,i,o,a=e&&ot(e),r=null===(t=a)||void 0===t?void 0:t.host,s=!1;if(a&&a!==e)for(s=!!(null!==(n=r)&&void 0!==n&&null!==(i=n.ownerDocument)&&void 0!==i&&i.contains(r)||null!=e&&null!==(o=e.ownerDocument)&&void 0!==o&&o.contains(e));!s&&r;){var l,c,d;s=!(null===(c=r=null===(l=a=ot(r))||void 0===l?void 0:l.host)||void 0===c||null===(d=c.ownerDocument)||void 0===d||!d.contains(r))}return s}(e))return!e.getClientRects().length;if("legacy-full"!==n)return!0}return!1}(t,e)||function(e){return"DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some((function(e){return"SUMMARY"===e.tagName}))}(t)||function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n=0)},gt=function e(t){var n=[],i=[];return t.forEach((function(t,o){var a=!!t.scopeParent,r=a?t.scopeParent:t,s=function(e,t){var n=lt(e);return n<0&&t&&!st(e)?0:n}(r,a),l=a?e(t.candidates):r;0===s?a?n.push.apply(n,l):n.push(r):i.push({documentOrder:o,tabIndex:s,item:t,isScope:a,content:l})})),i.sort(ct).reduce((function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e}),[]).concat(n)},ht=function(e,t){var n;return n=(t=t||{}).getShadowRoot?rt([e],t.includeContainer,{filter:vt.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:mt}):function(e,t,n){if(at(e))return[];var i=Array.prototype.slice.apply(e.querySelectorAll(tt));return t&&it.call(e,tt)&&i.unshift(e),i.filter(n)}(e,t.includeContainer,vt.bind(null,t)),gt(n)};const _t="ArrowUp",ft="ArrowDown",yt="ArrowLeft",bt="ArrowRight";function wt(e,t,n){return Math.floor(e/t)!==n}function xt(e,t){return t<0||t>=e.current.length}function Tt(e,t){let{startingIndex:n=-1,decrement:i=!1,disabledIndices:o,amount:a=1}=void 0===t?{}:t;const r=e.current;let s=n;do{var l,c;s+=i?-a:a}while(s>=0&&s<=r.length-1&&(o?o.includes(s):null==r[s]||(null==(l=r[s])?void 0:l.hasAttribute("disabled"))||"true"===(null==(c=r[s])?void 0:c.getAttribute("aria-disabled"))));return s}let kt=0;function St(e,t){void 0===t&&(t={});const{preventScroll:n=!1,cancelPrevious:i=!0,sync:o=!1}=t;i&&cancelAnimationFrame(kt);const a=()=>null==e?void 0:e.focus({preventScroll:n});o?a():kt=requestAnimationFrame(a)}var Et="undefined"!=typeof document?o.useLayoutEffect:o.useEffect;function At(e,t){const n=e.compareDocumentPosition(t);return n&Node.DOCUMENT_POSITION_FOLLOWING||n&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:n&Node.DOCUMENT_POSITION_PRECEDING||n&Node.DOCUMENT_POSITION_CONTAINS?1:0}const Ot=o.createContext({register:()=>{},unregister:()=>{},map:new Map,elementsRef:{current:[]}});function Pt(e){let{children:t,elementsRef:n,labelsRef:i}=e;const[a,r]=o.useState((()=>new Map)),s=o.useCallback((e=>{r((t=>new Map(t).set(e,null)))}),[]),l=o.useCallback((e=>{r((t=>{const n=new Map(t);return n.delete(e),n}))}),[]);return Et((()=>{const e=new Map(a);Array.from(e.keys()).sort(At).forEach(((t,n)=>{e.set(t,n)})),function(e,t){if(e.size!==t.size)return!1;for(const[n,i]of e.entries())if(i!==t.get(n))return!1;return!0}(a,e)||r(e)}),[a]),o.createElement(Ot.Provider,{value:o.useMemo((()=>({register:s,unregister:l,map:a,elementsRef:n,labelsRef:i})),[s,l,a,n,i])},t)}function It(e){let{label:t}=void 0===e?{}:e;const[n,i]=o.useState(null),a=o.useRef(null),{register:r,unregister:s,map:l,elementsRef:c,labelsRef:d}=o.useContext(Ot),u=o.useCallback((e=>{if(a.current=e,null!==n&&(c.current[n]=e,d)){var i;const o=void 0!==t;d.current[n]=o?t:null!=(i=null==e?void 0:e.textContent)?i:null}}),[n,c,d,t]);return Et((()=>{const e=a.current;if(e)return r(e),()=>{s(e)}}),[r,s]),Et((()=>{const e=a.current?l.get(a.current):null;null!=e&&i(e)}),[l]),o.useMemo((()=>({ref:u,index:null==n?-1:n})),[n,u])}function Ct(e,t){return"function"==typeof e?e(t):e?o.cloneElement(e,t):o.createElement("div",t)}const Lt=o.createContext({activeIndex:0,setActiveIndex:()=>{}}),jt=[yt,bt],Mt=[_t,ft],Nt=[...jt,...Mt],Dt=o.forwardRef((function(e,t){let{render:n,orientation:i="both",loop:a=!0,cols:r=1,disabledIndices:l}=e,c=s(e,["render","orientation","loop","cols","disabledIndices"]);const[d,u]=o.useState(0),p=o.useRef([]),v=n&&"function"!=typeof n?n.props:{},m=o.useMemo((()=>({activeIndex:d,setActiveIndex:u})),[d]),g=r>1,h=Object.assign(Object.assign(Object.assign({},c),v),{ref:t,"aria-orientation":"both"===i?void 0:i,onKeyDown(e){null==c.onKeyDown||c.onKeyDown(e),null==v.onKeyDown||v.onKeyDown(e),function(e){if(!Nt.includes(e.key))return;const t=function(e,t){return Tt(e,{disabledIndices:t})}(p,l),n=function(e,t){return Tt(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}(p,l);let o=d;g&&(o=function(e,t){let{event:n,orientation:i,loop:o,cols:a,disabledIndices:r,minIndex:s,maxIndex:l,prevIndex:c,stopEvent:d=!1}=t,u=c;if(n.key===_t){if(d&&z(n),-1===c)u=l;else if(u=Tt(e,{startingIndex:u,amount:a,decrement:!0,disabledIndices:r}),o&&(c-ae?n:n-a}xt(e,u)&&(u=c)}if(n.key===ft&&(d&&z(n),-1===c?u=s:(u=Tt(e,{startingIndex:c,amount:a,disabledIndices:r}),o&&c+a>l&&(u=Tt(e,{startingIndex:c%a-a,amount:a,disabledIndices:r}))),xt(e,u)&&(u=c)),"both"===i){const t=T(c/a);n.key===bt&&(d&&z(n),c%a!=a-1?(u=Tt(e,{startingIndex:c,disabledIndices:r}),o&&wt(u,a,t)&&(u=Tt(e,{startingIndex:c-c%a-1,disabledIndices:r}))):o&&(u=Tt(e,{startingIndex:c-c%a-1,disabledIndices:r})),wt(u,a,t)&&(u=c)),n.key===yt&&(d&&z(n),c%a!=0?(u=Tt(e,{startingIndex:c,disabledIndices:r,decrement:!0}),o&&wt(u,a,t)&&(u=Tt(e,{startingIndex:c+(a-c%a),decrement:!0,disabledIndices:r}))):o&&(u=Tt(e,{startingIndex:c+(a-c%a),decrement:!0,disabledIndices:r})),wt(u,a,t)&&(u=c));const i=T(l/a)===t;xt(e,u)&&(u=o&&i?n.key===yt?l:Tt(e,{startingIndex:c-c%a-1,disabledIndices:r}):c)}return u}(p,{event:e,orientation:i,loop:a,cols:r,disabledIndices:l,minIndex:t,maxIndex:n,prevIndex:d}));const s={horizontal:[bt],vertical:[ft],both:[bt,ft]}[i],c={horizontal:[yt],vertical:[_t],both:[yt,_t]}[i],v=g?Nt:{horizontal:jt,vertical:Mt,both:Nt}[i];o===d&&[...s,...c].includes(e.key)&&(o=a&&o===n&&s.includes(e.key)?t:a&&o===t&&c.includes(e.key)?n:Tt(p,{startingIndex:o,decrement:c.includes(e.key),disabledIndices:l})),o===d||xt(p,o)||(e.stopPropagation(),v.includes(e.key)&&e.preventDefault(),u(o),queueMicrotask((()=>{St(p.current[o])})))}(e)}});return o.createElement(Lt.Provider,{value:m},o.createElement(Pt,{elementsRef:p},Ct(n,h)))})),Rt=o.forwardRef((function(e,t){let{render:n}=e,i=s(e,["render"]);const a=n&&"function"!=typeof n?n.props:{},{activeIndex:r,setActiveIndex:l}=o.useContext(Lt),{ref:c,index:d}=It(),u=(p=[c,t,a.ref],o.useMemo((()=>p.every((e=>null==e))?null:e=>{p.forEach((t=>{"function"==typeof t?t(e):null!=t&&(t.current=e)}))}),p));var p;const v=r===d;return Ct(n,Object.assign(Object.assign(Object.assign({},i),a),{ref:u,tabIndex:v?0:-1,"data-active":v?"":void 0,onFocus(e){null==i.onFocus||i.onFocus(e),null==a.onFocus||a.onFocus(e),l(d)}}))}));function Bt(){return Bt=Object.assign?Object.assign.bind():function(e){for(var t=1;t"floating-ui-"+Ft++,zt=(i||(i=n.t(o,2)))["useId".toString()]||function(){const[e,t]=o.useState((()=>Ut?Vt():void 0));return Et((()=>{null==e&&t(Vt())}),[]),o.useEffect((()=>{Ut||(Ut=!0)}),[]),e},Ht=o.forwardRef((function(e,t){let{context:{placement:n,elements:{floating:i},middlewareData:{arrow:a}},width:r=14,height:l=7,tipRadius:c=0,strokeWidth:d=0,staticOffset:u,stroke:p,d:v}=e,m=e.style,g=void 0===m?{}:m,{transform:h}=g,_=s(g,["transform"]),f=s(e,["context","width","height","tipRadius","strokeWidth","staticOffset","stroke","d","style"]);const y=zt();if(!i)return null;d*=2;const b=d/2,w=r/2*(c/-8+1),x=l/2*c/4,[T,k]=n.split("-"),S=Ve.isRTL(i),E=!!v,A="top"===T||"bottom"===T,O=u&&"end"===k?"bottom":"top";let P=u&&"end"===k?"right":"left";u&&S&&(P="end"===k?"left":"right");const I=null!=(null==a?void 0:a.x)?u||a.x:"",C=null!=(null==a?void 0:a.y)?u||a.y:"",L=v||"M0,0 H"+r+" L"+(r-w)+","+(l-x)+" Q"+r/2+","+l+" "+w+","+(l-x)+" Z",j={top:E?"rotate(180deg)":"",left:E?"rotate(90deg)":"rotate(-90deg)",bottom:E?"":"rotate(180deg)",right:E?"rotate(-90deg)":"rotate(90deg)"}[T];return o.createElement("svg",Bt({},f,{"aria-hidden":!0,ref:t,width:E?r:r+d,height:r,viewBox:"0 0 "+r+" "+(l>r?l:r),style:Object.assign({position:"absolute",pointerEvents:"none",[P]:I,[O]:C,[T]:A||E?"100%":"calc(100% - "+d/2+"px)",transform:""+j+(null!=h?h:"")},_)}),d>0&&o.createElement("path",{clipPath:"url(#"+y+")",fill:"none",stroke:p,strokeWidth:d+(v?0:1),d:L}),o.createElement("path",{stroke:d&&!v?f.fill:"none",d:L}),o.createElement("clipPath",{id:y},o.createElement("rect",{x:-b,y:b*(E?-1:1),width:r+d,height:r})))})),qt=o.createContext(null),Gt=o.createContext(null),$t=()=>{var e;return(null==(e=o.useContext(qt))?void 0:e.id)||null},Wt=()=>o.useContext(Gt);function Zt(e){return"data-floating-ui-"+e}function Yt(e){const t=(0,o.useRef)(e);return Et((()=>{t.current=e})),t}const Kt=Zt("safe-polygon");function Xt(e,t,n){return n&&!D(n)?0:"number"==typeof e?e:null==e?void 0:e[t]}function Qt(e,t){let n=e.filter((e=>{var n;return e.parentId===t&&(null==(n=e.context)?void 0:n.open)})),i=n;for(;i.length;)i=e.filter((e=>{var t;return null==(t=i)?void 0:t.some((t=>{var n;return e.parentId===t.id&&(null==(n=e.context)?void 0:n.open)}))})),n=n.concat(i);return n}let Jt=new WeakMap,en=new WeakSet,tn={},nn=0;const on=e=>e&&(e.host||on(e.parentNode)),an=(e,t)=>t.map((t=>{if(e.contains(t))return t;const n=on(t);return e.contains(n)?n:null})).filter((e=>null!=e));function rn(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=!1);const i=R(e[0]).body;return function(e,t,n,i){const o="data-floating-ui-inert",a=i?"inert":n?"aria-hidden":null,r=an(t,e),s=new Set,l=new Set(r),c=[];tn[o]||(tn[o]=new WeakMap);const d=tn[o];return r.forEach((function e(t){t&&!s.has(t)&&(s.add(t),t.parentNode&&e(t.parentNode))})),function e(t){t&&!l.has(t)&&Array.prototype.forEach.call(t.children,(t=>{if(s.has(t))e(t);else{const e=a?t.getAttribute(a):null,n=null!==e&&"false"!==e,i=(Jt.get(t)||0)+1,r=(d.get(t)||0)+1;Jt.set(t,i),d.set(t,r),c.push(t),1===i&&n&&en.add(t),1===r&&t.setAttribute(o,""),!n&&a&&t.setAttribute(a,"true")}}))}(t),s.clear(),nn++,()=>{c.forEach((e=>{const t=(Jt.get(e)||0)-1,n=(d.get(e)||0)-1;Jt.set(e,t),d.set(e,n),t||(!en.has(e)&&a&&e.removeAttribute(a),en.delete(e)),n||e.removeAttribute(o)})),nn--,nn||(Jt=new WeakMap,Jt=new WeakMap,en=new WeakSet,tn={})}}(e.concat(Array.from(i.querySelectorAll("[aria-live]"))),i,t,n)}const sn=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function ln(e,t){const n=ht(e,sn());"prev"===t&&n.reverse();const i=n.indexOf(C(R(e)));return n.slice(i+1)[0]}function cn(){return ln(document.body,"next")}function dn(){return ln(document.body,"prev")}function un(e,t){const n=t||e.currentTarget,i=e.relatedTarget;return!i||!L(n,i)}function pn(e){ht(e,sn()).forEach((e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")}))}function vn(e){e.querySelectorAll("[data-tabindex]").forEach((e=>{const t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")}))}const mn={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0};function gn(e){"Tab"===e.key&&(e.target,clearTimeout(void 0))}const hn=o.forwardRef((function(e,t){const[n,i]=o.useState();Et((()=>(/apple/i.test(navigator.vendor)&&i("button"),document.addEventListener("keydown",gn),()=>{document.removeEventListener("keydown",gn)})),[]);const a={ref:t,tabIndex:0,role:n,"aria-hidden":!n||void 0,[Zt("focus-guard")]:"",style:mn};return o.createElement("span",Bt({},e,a))})),_n=o.createContext(null);function fn(e){let{children:t,id:n,root:i=null,preserveTabOrder:r=!0}=e;const s=function(e){let{id:t,root:n}=void 0===e?{}:e;const[i,a]=o.useState(null),r=zt(),s=yn(),l=o.useMemo((()=>({id:t,root:n,portalContext:s,uniqueId:r})),[t,n,s,r]),c=o.useRef();return Et((()=>()=>{null==i||i.remove()}),[i,l]),Et((()=>{if(c.current===l)return;c.current=l;const{id:e,root:t,portalContext:n,uniqueId:i}=l,o=e?document.getElementById(e):null,r=Zt("portal");if(o){const e=document.createElement("div");e.id=i,e.setAttribute(r,""),o.appendChild(e),a(e)}else{let o=t||(null==n?void 0:n.portalNode);o&&!A(o)&&(o=o.current),o=o||document.body;let s=null;e&&(s=document.createElement("div"),s.id=e,o.appendChild(s));const l=document.createElement("div");l.id=i,l.setAttribute(r,""),o=s||o,o.appendChild(l),a(l)}}),[l]),i}({id:n,root:i}),[l,c]=o.useState(null),d=o.useRef(null),u=o.useRef(null),p=o.useRef(null),v=o.useRef(null),m=!!l&&!l.modal&&l.open&&r&&!(!i&&!s);return o.useEffect((()=>{if(s&&r&&(null==l||!l.modal))return s.addEventListener("focusin",e,!0),s.addEventListener("focusout",e,!0),()=>{s.removeEventListener("focusin",e,!0),s.removeEventListener("focusout",e,!0)};function e(e){s&&un(e)&&("focusin"===e.type?vn:pn)(s)}}),[s,r,null==l?void 0:l.modal]),o.createElement(_n.Provider,{value:o.useMemo((()=>({preserveTabOrder:r,beforeOutsideRef:d,afterOutsideRef:u,beforeInsideRef:p,afterInsideRef:v,portalNode:s,setFocusManagerState:c})),[r,s])},m&&s&&o.createElement(hn,{"data-type":"outside",ref:d,onFocus:e=>{if(un(e,s)){var t;null==(t=p.current)||t.focus()}else{const e=dn()||(null==l?void 0:l.refs.domReference.current);null==e||e.focus()}}}),m&&s&&o.createElement("span",{"aria-owns":s.id,style:mn}),s&&(0,a.createPortal)(t,s),m&&s&&o.createElement(hn,{"data-type":"outside",ref:u,onFocus:e=>{if(un(e,s)){var t;null==(t=v.current)||t.focus()}else{const t=cn()||(null==l?void 0:l.refs.domReference.current);null==t||t.focus(),(null==l?void 0:l.closeOnFocusOut)&&(null==l||l.onOpenChange(!1,e.nativeEvent))}}}))}const yn=()=>o.useContext(_n),bn=o.forwardRef((function(e,t){return o.createElement("button",Bt({},e,{type:"button",ref:t,tabIndex:-1,style:mn}))}));function wn(e){const{context:t,children:n,disabled:i=!1,order:a=["content"],guards:r=!0,initialFocus:s=0,returnFocus:l=!0,modal:c=!0,visuallyHiddenDismiss:d=!1,closeOnFocusOut:u=!0}=e,{open:p,refs:v,nodeId:m,onOpenChange:g,events:h,dataRef:_,elements:{domReference:f,floating:y}}=t,b="undefined"==typeof HTMLElement||!("inert"in HTMLElement.prototype)||r,w=Yt(a),x=Yt(s),T=Yt(l),k=Wt(),S=yn(),E="number"==typeof s&&s<0,A=o.useRef(null),P=o.useRef(null),I=o.useRef(!1),j=o.useRef(null),M=o.useRef(!1),N=null!=S,D=f&&"combobox"===f.getAttribute("role")&&V(f)&&E,B=o.useCallback((function(e){return void 0===e&&(e=y),e?ht(e,sn()):[]}),[y]),F=o.useCallback((e=>{const t=B(e);return w.current.map((e=>f&&"reference"===e?f:y&&"floating"===e?y:t)).filter(Boolean).flat()}),[f,y,w,B]);function H(e){return!i&&d&&c?o.createElement(bn,{ref:"start"===e?A:P,onClick:e=>g(!1,e.nativeEvent)},"string"==typeof d?d:"Dismiss"):null}o.useEffect((()=>{if(i||!c)return;function e(e){if("Tab"===e.key){L(y,C(R(y)))&&0===B().length&&!D&&z(e);const t=F(),n=U(e);"reference"===w.current[0]&&n===f&&(z(e),e.shiftKey?St(t[t.length-1]):St(t[1])),"floating"===w.current[1]&&n===y&&e.shiftKey&&(z(e),St(t[0]))}}const t=R(y);return t.addEventListener("keydown",e),()=>{t.removeEventListener("keydown",e)}}),[i,f,y,c,w,v,D,B,F]),o.useEffect((()=>{if(!i&&u)return y&&O(f)?(f.addEventListener("focusout",t),f.addEventListener("pointerdown",e),!c&&y.addEventListener("focusout",t),()=>{f.removeEventListener("focusout",t),f.removeEventListener("pointerdown",e),!c&&y.removeEventListener("focusout",t)}):void 0;function e(){M.current=!0,setTimeout((()=>{M.current=!1}))}function t(e){const t=e.relatedTarget;queueMicrotask((()=>{const n=!(L(f,t)||L(y,t)||L(t,y)||L(null==S?void 0:S.portalNode,t)||null!=t&&t.hasAttribute(Zt("focus-guard"))||k&&(Qt(k.nodesRef.current,m).find((e=>{var n,i;return L(null==(n=e.context)?void 0:n.elements.floating,t)||L(null==(i=e.context)?void 0:i.elements.domReference,t)}))||function(e,t){var n;let i=[],o=null==(n=e.find((e=>e.id===t)))?void 0:n.parentId;for(;o;){const t=e.find((e=>e.id===o));o=null==t?void 0:t.parentId,t&&(i=i.concat(t))}return i}(k.nodesRef.current,m).find((e=>{var n,i;return(null==(n=e.context)?void 0:n.elements.floating)===t||(null==(i=e.context)?void 0:i.elements.domReference)===t}))));t&&n&&!M.current&&t!==j.current&&(I.current=!0,g(!1,e))}))}}),[i,f,y,c,m,k,S,g,u]),o.useEffect((()=>{var e;if(i)return;const t=Array.from((null==S||null==(e=S.portalNode)?void 0:e.querySelectorAll("["+Zt("portal")+"]"))||[]);if(y){const e=[y,...t,A.current,P.current,w.current.includes("reference")||D?f:null].filter((e=>null!=e)),n=c?rn(e,b,!b):rn(e);return()=>{n()}}}),[i,f,y,c,w,S,D,b]),Et((()=>{if(i||!y)return;const e=C(R(y));queueMicrotask((()=>{const t=F(y),n=x.current,i=("number"==typeof n?t[n]:n.current)||y,o=L(y,e);E||o||!p||St(i,{preventScroll:i===y})}))}),[i,p,y,E,F,x]),Et((()=>{if(i||!y)return;let e=!1;const t=R(y),n=C(t),o=_.current;function a(t){if("escapeKey"===t.type&&v.domReference.current&&(j.current=v.domReference.current),["referencePress","escapeKey"].includes(t.type))return;const n=t.data.returnFocus;"object"==typeof n?(I.current=!1,e=n.preventScroll):I.current=!n}return j.current=n,h.on("dismiss",a),()=>{h.off("dismiss",a);const n=C(t);(L(y,n)||k&&Qt(k.nodesRef.current,m).some((e=>{var t;return L(null==(t=e.context)?void 0:t.elements.floating,n)}))||o.openEvent&&["click","mousedown"].includes(o.openEvent.type))&&v.domReference.current&&(j.current=v.domReference.current),T.current&&O(j.current)&&!I.current&&St(j.current,{cancelPrevious:!1,preventScroll:e})}}),[i,y,T,_,v,h,k,m]),Et((()=>{if(!i&&S)return S.setFocusManagerState({modal:c,closeOnFocusOut:u,open:p,onOpenChange:g,refs:v}),()=>{S.setFocusManagerState(null)}}),[i,S,c,p,g,v,u]),Et((()=>{if(!i&&y&&"function"==typeof MutationObserver&&!E){const e=()=>{const e=y.getAttribute("tabindex");w.current.includes("floating")||C(R(y))!==v.domReference.current&&0===B().length?"0"!==e&&y.setAttribute("tabindex","0"):"-1"!==e&&y.setAttribute("tabindex","-1")};e();const t=new MutationObserver(e);return t.observe(y,{childList:!0,subtree:!0,attributes:!0}),()=>{t.disconnect()}}}),[i,y,v,w,B,E]);const q=!i&&b&&!D&&(N||c);return o.createElement(o.Fragment,null,q&&o.createElement(hn,{"data-type":"inside",ref:null==S?void 0:S.beforeInsideRef,onFocus:e=>{if(c){const e=F();St("reference"===a[0]?e[0]:e[e.length-1])}else if(null!=S&&S.preserveTabOrder&&S.portalNode)if(I.current=!1,un(e,S.portalNode)){const e=cn()||f;null==e||e.focus()}else{var t;null==(t=S.beforeOutsideRef.current)||t.focus()}}}),!D&&H("start"),n,H("end"),q&&o.createElement(hn,{"data-type":"inside",ref:null==S?void 0:S.afterInsideRef,onFocus:e=>{if(c)St(F()[0]);else if(null!=S&&S.preserveTabOrder&&S.portalNode)if(u&&(I.current=!0),un(e,S.portalNode)){const e=dn()||f;null==e||e.focus()}else{var t;null==(t=S.afterOutsideRef.current)||t.focus()}}}))}const xn=new Set,Tn=o.forwardRef((function(e,t){let{lockScroll:n=!1}=e,i=s(e,["lockScroll"]);const a=zt();return Et((()=>{if(!n)return;xn.add(a);const e=/iP(hone|ad|od)|iOS/.test(j()),t=document.body.style,i=Math.round(document.documentElement.getBoundingClientRect().left)+document.documentElement.scrollLeft?"paddingLeft":"paddingRight",o=window.innerWidth-document.documentElement.clientWidth,r=t.left?parseFloat(t.left):window.pageXOffset,s=t.top?parseFloat(t.top):window.pageYOffset;if(t.overflow="hidden",o&&(t[i]=o+"px"),e){var l,c;const e=(null==(l=window.visualViewport)?void 0:l.offsetLeft)||0,n=(null==(c=window.visualViewport)?void 0:c.offsetTop)||0;Object.assign(t,{position:"fixed",top:-(s-Math.floor(n))+"px",left:-(r-Math.floor(e))+"px",right:"0"})}return()=>{xn.delete(a),0===xn.size&&(Object.assign(t,{overflow:"",[i]:""}),e&&(Object.assign(t,{position:"",top:"",left:"",right:""}),window.scrollTo(r,s)))}}),[a,n]),o.createElement("div",Bt({ref:t},i,{style:Object.assign({position:"fixed",overflow:"auto",top:0,right:0,bottom:0,left:0},i.style)}))}));function kn(e){return O(e.target)&&"BUTTON"===e.target.tagName}function Sn(e){return V(e)}function En(e,t){void 0===t&&(t={});const{open:n,onOpenChange:i,dataRef:a,elements:{domReference:r}}=e,{enabled:s=!0,event:l="click",toggle:c=!0,ignoreMouse:d=!1,keyboardHandlers:u=!0}=t,p=o.useRef(),v=o.useRef(!1);return o.useMemo((()=>s?{reference:{onPointerDown(e){p.current=e.pointerType},onMouseDown(e){0===e.button&&(D(p.current,!0)&&d||"click"!==l&&(!n||!c||a.current.openEvent&&"mousedown"!==a.current.openEvent.type?(e.preventDefault(),i(!0,e.nativeEvent)):i(!1,e.nativeEvent)))},onClick(e){"mousedown"===l&&p.current?p.current=void 0:D(p.current,!0)&&d||(!n||!c||a.current.openEvent&&"click"!==a.current.openEvent.type?i(!0,e.nativeEvent):i(!1,e.nativeEvent))},onKeyDown(e){p.current=void 0,e.defaultPrevented||!u||kn(e)||(" "!==e.key||Sn(r)||(e.preventDefault(),v.current=!0),"Enter"===e.key&&i(!n||!c,e.nativeEvent))},onKeyUp(e){e.defaultPrevented||!u||kn(e)||Sn(r)||" "===e.key&&v.current&&(v.current=!1,i(!n||!c,e.nativeEvent))}}}:{}),[s,a,l,d,u,r,c,n,i])}const An=(i||(i=n.t(o,2)))["useInsertionEffect".toString()]||(e=>e());function On(e){const t=o.useRef((()=>{}));return An((()=>{t.current=e})),o.useCallback((function(){for(var e=arguments.length,n=new Array(e),i=0;i!1),x="function"==typeof v?w:v,T=o.useRef(!1),{escapeKeyBubbles:E,outsidePressBubbles:P}=(e=>{var t,n;return{escapeKeyBubbles:"boolean"==typeof e?e:null!=(t=null==e?void 0:e.escapeKey)&&t,outsidePressBubbles:"boolean"==typeof e?e:null==(n=null==e?void 0:e.outsidePress)||n}})(f),C=On((e=>{if(!n||!u||!p||"Escape"!==e.key)return;const t=y?Qt(y.nodesRef.current,r):[];if(!E&&(e.stopPropagation(),t.length>0)){let e=!0;if(t.forEach((t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__escapeKeyBubbles||(e=!1)})),!e)return}a.emit("dismiss",{type:"escapeKey",data:{returnFocus:{preventScroll:!1}}}),i(!1,function(e){return"nativeEvent"in e}(e)?e.nativeEvent:e)})),j=On((e=>{const t=T.current;if(T.current=!1,t)return;if("function"==typeof x&&!x(e))return;const n=U(e),o="["+Zt("inert")+"]",s=R(c).querySelectorAll(o);let d=A(n)?n:null;for(;d&&!["html","body","#document"].includes(k(d));){const e=I(d);if(e===R(c).body||!A(e))break;d=e}if(s.length&&A(n)&&!n.matches("html,body")&&!L(n,c)&&Array.from(s).every((e=>!L(d,e))))return;if(O(n)&&c){const t=n.clientWidth>0&&n.scrollWidth>n.clientWidth,i=n.clientHeight>0&&n.scrollHeight>n.clientHeight;let o=i&&e.offsetX>n.clientWidth;if(i){"rtl"===(u=n,S(u).getComputedStyle(u)).direction&&(o=e.offsetX<=n.offsetWidth-n.clientWidth)}if(o||t&&e.offsetY>n.clientHeight)return}var u;const p=y&&Qt(y.nodesRef.current,r).some((t=>{var n;return B(e,null==(n=t.context)?void 0:n.elements.floating)}));if(B(e,c)||B(e,l)||p)return;const v=y?Qt(y.nodesRef.current,r):[];if(v.length>0){let e=!0;if(v.forEach((t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__outsidePressBubbles||(e=!1)})),!e)return}a.emit("dismiss",{type:"outsidePress",data:{returnFocus:b?{preventScroll:!0}:M(e)||N(e)}}),i(!1,e)}));return o.useEffect((()=>{if(!n||!u)return;function e(e){i(!1,e)}d.current.__escapeKeyBubbles=E,d.current.__outsidePressBubbles=P;const t=R(c);p&&t.addEventListener("keydown",C),x&&t.addEventListener(m,j);let o=[];return _&&(A(l)&&(o=Ae(l)),A(c)&&(o=o.concat(Ae(c))),!A(s)&&s&&s.contextElement&&(o=o.concat(Ae(s.contextElement)))),o=o.filter((e=>{var n;return e!==(null==(n=t.defaultView)?void 0:n.visualViewport)})),o.forEach((t=>{t.addEventListener("scroll",e,{passive:!0})})),()=>{p&&t.removeEventListener("keydown",C),x&&t.removeEventListener(m,j),o.forEach((t=>{t.removeEventListener("scroll",e)}))}}),[d,c,l,s,p,x,m,n,i,_,u,E,P,C,j]),o.useEffect((()=>{T.current=!1}),[x,m]),o.useMemo((()=>u?{reference:{onKeyDown:C,[Pn[h]]:e=>{g&&(a.emit("dismiss",{type:"referencePress",data:{returnFocus:!1}}),i(!1,e.nativeEvent))}},floating:{onKeyDown:C,[In[m]]:()=>{T.current=!0}}}:{}),[u,a,g,m,h,i,C])}function Ln(e){var t;void 0===e&&(e={});const{open:n=!1,onOpenChange:i,nodeId:r}=e,[s,l]=o.useState(null),c=(null==(t=e.elements)?void 0:t.reference)||s,d=function(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:i=[],platform:r,elements:{reference:s,floating:l}={},transform:c=!0,whileElementsMounted:d,open:u}=e,[p,v]=o.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,g]=o.useState(i);We(m,i)||g(i);const[h,_]=o.useState(null),[f,y]=o.useState(null),b=o.useCallback((e=>{e!==k.current&&(k.current=e,_(e))}),[]),w=o.useCallback((e=>{e!==S.current&&(S.current=e,y(e))}),[]),x=s||h,T=l||f,k=o.useRef(null),S=o.useRef(null),E=o.useRef(p),A=null!=d,O=Ke(d),P=Ke(r),I=o.useCallback((()=>{if(!k.current||!S.current)return;const e={placement:t,strategy:n,middleware:m};P.current&&(e.platform=P.current),Ge(k.current,S.current,e).then((e=>{const t=Object.assign(Object.assign({},e),{isPositioned:!0});C.current&&!We(E.current,t)&&(E.current=t,a.flushSync((()=>{v(t)})))}))}),[m,t,n,P]);$e((()=>{!1===u&&E.current.isPositioned&&(E.current.isPositioned=!1,v((e=>Object.assign(Object.assign({},e),{isPositioned:!1}))))}),[u]);const C=o.useRef(!1);$e((()=>(C.current=!0,()=>{C.current=!1})),[]),$e((()=>{if(x&&(k.current=x),T&&(S.current=T),x&&T){if(O.current)return O.current(x,T,I);I()}}),[x,T,I,O,A]);const L=o.useMemo((()=>({reference:k,floating:S,setReference:b,setFloating:w})),[b,w]),j=o.useMemo((()=>({reference:x,floating:T})),[x,T]),M=o.useMemo((()=>{const e={position:n,left:0,top:0};if(!j.floating)return e;const t=Ye(j.floating,p.x),i=Ye(j.floating,p.y);return c?Object.assign(Object.assign(Object.assign({},e),{transform:"translate("+t+"px, "+i+"px)"}),Ze(j.floating)>=1.5&&{willChange:"transform"}):{position:n,left:t,top:i}}),[n,c,j.floating,p.x,p.y]);return o.useMemo((()=>Object.assign(Object.assign({},p),{update:I,refs:L,elements:j,floatingStyles:M})),[p,I,L,j,M])}(e),u=Wt(),p=On(((e,t)=>{e&&(m.current.openEvent=t),null==i||i(e,t)})),v=o.useRef(null),m=o.useRef({}),g=o.useState((()=>function(){const e=new Map;return{emit(t,n){var i;null==(i=e.get(t))||i.forEach((e=>e(n)))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var i;e.set(t,(null==(i=e.get(t))?void 0:i.filter((e=>e!==n)))||[])}}}()))[0],h=zt(),_=o.useCallback((e=>{const t=A(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),contextElement:e}:e;d.refs.setReference(t)}),[d.refs]),f=o.useCallback((e=>{(A(e)||null===e)&&(v.current=e,l(e)),(A(d.refs.reference.current)||null===d.refs.reference.current||null!==e&&!A(e))&&d.refs.setReference(e)}),[d.refs]),y=o.useMemo((()=>Object.assign(Object.assign({},d.refs),{setReference:f,setPositionReference:_,domReference:v})),[d.refs,f,_]),b=o.useMemo((()=>Object.assign(Object.assign({},d.elements),{domReference:c})),[d.elements,c]),w=o.useMemo((()=>Object.assign(Object.assign({},d),{refs:y,elements:b,dataRef:m,nodeId:r,floatingId:h,events:g,open:n,onOpenChange:p})),[d,r,h,g,n,p,y,b]);return Et((()=>{const e=null==u?void 0:u.nodesRef.current.find((e=>e.id===r));e&&(e.context=w)})),o.useMemo((()=>Object.assign(Object.assign({},d),{context:w,refs:y,elements:b})),[d,y,b,w])}function jn(e,t,n){const i=new Map;return Object.assign(Object.assign(Object.assign({},"floating"===n&&{tabIndex:-1}),e),t.map((e=>e?e[n]:null)).concat(e).reduce(((e,t)=>t?(Object.entries(t).forEach((t=>{let[n,o]=t;var a;0===n.indexOf("on")?(i.has(n)||i.set(n,[]),"function"==typeof o&&(null==(a=i.get(n))||a.push(o),e[n]=function(){for(var e,t=arguments.length,o=new Array(t),a=0;ae(...o))).find((e=>void 0!==e))})):e[n]=o})),e):e),{}))}function Mn(e){void 0===e&&(e=[]);const t=e,n=o.useCallback((t=>jn(t,e,"reference")),t),i=o.useCallback((t=>jn(t,e,"floating")),t),a=o.useCallback((t=>jn(t,e,"item")),e.map((e=>null==e?void 0:e.item)));return o.useMemo((()=>({getReferenceProps:n,getFloatingProps:i,getItemProps:a})),[n,i,a])}function Nn(e,t){void 0===t&&(t={});const{open:n,floatingId:i}=e,{enabled:a=!0,role:r="dialog"}=t,s=zt();return o.useMemo((()=>{const e={id:i,role:r};return a?"tooltip"===r?{reference:{"aria-describedby":n?i:void 0},floating:e}:{reference:Object.assign(Object.assign({"aria-expanded":n?"true":"false","aria-haspopup":"alertdialog"===r?"dialog":r,"aria-controls":n?i:void 0},"listbox"===r&&{role:"combobox"}),"menu"===r&&{id:s}),floating:Object.assign(Object.assign({},e),"menu"===r&&{"aria-labelledby":s})}:{}}),[a,r,n,i,s])}function Dn(e,t){void 0===t&&(t={});const{open:n,elements:{floating:i}}=e,{duration:a=250}=t,r=("number"==typeof a?a:a.close)||0,[s,l]=o.useState(!1),[c,d]=o.useState("unmounted"),u=function(e,t){const[n,i]=o.useState(e);return e&&!n&&i(!0),o.useEffect((()=>{if(!e){const e=setTimeout((()=>i(!1)),t);return()=>clearTimeout(e)}}),[e,t]),n}(n,r);return Et((()=>{s&&!u&&d("unmounted")}),[s,u]),Et((()=>{if(i){if(n){d("initial");const e=requestAnimationFrame((()=>{d("open")}));return()=>{cancelAnimationFrame(e)}}l(!0),d("close")}}),[n,i]),{isMounted:u,status:c}}const Rn="TUXToastProvider-topOutlet",Bn="TUXToastProvider-bottomOutlet",Un="TUXToastProvider-centerOutlet",Fn={top:Rn,bottom:Bn,center:Un},Vn=(0,o.createContext)(void 0),zn=({topToastOffset:e,bottomToastOffset:t,children:n})=>{const i=(0,o.useRef)(0),[a,r]=(0,o.useState)([]),s=f(),l=(0,o.useCallback)((e=>{r((t=>t.map((t=>t.id===e?Object.assign(Object.assign({},t),{transitionStatus:"exiting"}):t)))),setTimeout((()=>{r((t=>t.filter((t=>t.id!==e))))}),200)}),[]),c=(0,o.useCallback)(((e,t,n)=>{const o=i.current;return i.current+=1,r((n=>[...n,Object.assign({id:o,listId:e,transitionStatus:"entered",dismiss:()=>l(o)},t)])),setTimeout((()=>{l(o)}),n||5e3),o}),[l]),d=(0,o.useCallback)(((e,t,n)=>{if(!a.length)return void c(e,t,n);const i=Object.assign(Object.assign({},a[0]),t);r([i])}),[c,a]),u=void 0!==e?`${e}px`:"env(safe-area-inset-top)",p=void 0!==t?`${t}px`:"env(safe-area-inset-bottom)";return o.createElement(Vn.Provider,{value:{addToast:c,removeToast:l,addToastSingleMode:d,getToasts:e=>a.filter((t=>t.listId===e))}},n,o.createElement(fn,null,o.createElement("div",{id:Rn,className:"TUXToastProvider-topOutlet",style:{zIndex:s.zIndex.toast,top:u}}),o.createElement("div",{id:Un,className:"TUXToastProvider-center-outlet",style:{zIndex:s.zIndex.toast,top:u}}),o.createElement("div",{className:"TUXToastProvider-bottomOutletContainer",style:{zIndex:s.zIndex.toast,bottom:p}},o.createElement("div",{id:Bn,className:"TUXToastProvider-bottomOutlet"}),o.createElement("div",{id:"TUXToastProvider-noticeOutlet",className:"TUXToastProvider-noticeOutlet"}))))},Hn=(0,o.createContext)({idRef:null});let qn=!1,Gn=0;const $n=()=>"tux-web-"+Gn++,Wn=()=>{const[e,t]=(0,o.useState)((()=>qn?$n():void 0));return(0,o.useLayoutEffect)((()=>{void 0===e&&t($n())}),[]),(0,o.useEffect)((()=>{qn||(qn=!0)}),[]),null!=e?e:""},Zn=()=>{const{idRef:e}=(0,o.useContext)(Hn),[t]=(0,o.useState)((()=>{if(e){const t=e.current++;return String(t)}return""}));return`tux-web-${t}`},Yn=()=>{const{idRef:e}=(0,o.useContext)(Hn);let t=Wn;return e&&(t=Zn),t()},Kn=()=>{const e=(0,o.useContext)(Vn);if(!e)throw Error("ToastContext is undefined when calling useTUXToast. Make sure to wrap your app with TUXProvider.");const t=Yn(),n=e.getToasts(t);return{id:t,show:(n,i)=>{e.addToast(t,n,i)},showSingleMode:(n,i)=>{e.addToastSingleMode(t,n,i)},dismiss:t=>{e.removeToast(t)},list:n}};function Xn(e){var t,n,i="";if("string"==typeof e||"number"==typeof e)i+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t{var{transitionStatus:t,position:n,children:i}=e,a=s(e,["transitionStatus","position","children"]);return o.createElement("div",Object.assign({className:Qn("TUXToast",`TUXToast--${n}--${t}`)},a),i)},ei=({state:e,position:t,render:n})=>{const i=Fn[t];return o.createElement(o.Fragment,null,e.list.map((e=>o.createElement(fn,{key:e.id,id:i},o.createElement(Jn,{position:t,transitionStatus:e.transitionStatus},n(e))))))},ti=e=>{var{size:t,weight:n,font:i="TikTok Sans",color:a,align:r,truncate:c,italic:d,underline:u,strikethrough:p,as:v="span",children:m,className:g,style:h}=e,_=s(e,["size","weight","font","color","align","truncate","italic","underline","strikethrough","as","children","className","style"]);const f=i.toLowerCase().replace(/\s/g,"-"),y=[u&&"underline",p&&"strikethrough"].filter((e=>e)).join("-");return o.createElement(v,Object.assign({className:Qn("TUXText",`TUXText--${f}`,n&&`TUXText--weight-${n}`,y&&`TUXText--${y}`,c&&"TUXText--truncate",d&&"TUXText--italic",r&&`TUXText--align-${r}`,g),style:Object.assign({color:a?l[a]:"inherit",fontSize:t?`${t}px`:"inherit"},h)},_),m)},ni=e=>{var{content:t,leading:n,trailing:i}=e,a=s(e,["content","leading","trailing"]);return o.createElement("div",Object.assign({className:"TUXBottomToast"},a),n?o.createElement("div",{className:"TUXBottomToast-leading"},n):null,o.createElement(ti,{className:"TUXBottomToast-content",as:"div",size:15,weight:"normal"},t),i?o.createElement("div",{className:"TUXBottomToast-trailing"},i):null)},ii=e=>{var{content:t,leading:n}=e,i=s(e,["content","leading"]);return o.createElement("div",Object.assign({className:"TUXTopToast","data-tux-color-scheme":"dark"},i),n?o.createElement("div",{className:"TUXTopToast-leading"},n):null,o.createElement(ti,{className:"TUXTopToast-content",as:"div",size:14,weight:"normal"},t))},oi=e=>{var{className:t}=e,n=s(e,["className"]);return o.createElement("button",Object.assign({type:"button",className:Qn("TUXUnstyledButton",t)},n))};function ai(){return ai=Object.assign?Object.assign.bind():function(e){for(var t=1;t({color:t,size:n,autoMirror:i,className:a,style:r})=>{const s=x(),c=e;return o.createElement(c,{className:a,color:t?l[t]:"inherit",fontSize:void 0!==n?n:"inherit",style:Object.assign(Object.assign({},i&&"rtl"===s&&{transform:"scaleX(-1)"}),r)})},fa=_a(si),ya=_a(li),ba=_a(ci),wa=_a(di),xa=_a(ui),Ta=_a(pi),ka=_a(vi),Sa=_a(mi),Ea=_a(gi),Aa=_a(hi),Oa=_a(_i),Pa=_a(fi),Ia=_a(yi),Ca=_a(bi),La=_a(wi),ja=_a(xi),Ma=_a(Ti),Na=_a(ki),Da=_a(Si),Ra=_a(Ei),Ba=_a(Ai),Ua=_a(Oi),Fa=_a(Pi),Va=_a(Ci),za=_a(Ii),Ha=_a(Li),qa=_a(ji),Ga=_a(Mi),$a=_a(Ni),Wa=_a(Di),Za=_a(Ri),Ya=_a(Ui),Ka=_a(Fi),Xa=_a(zi),Qa=_a(Vi),Ja=_a(co),er=_a(qi),tr=_a(Hi),nr=_a(Gi),ir=_a($i),or=_a(Wi),ar=_a(Zi),rr=_a(Yi),sr=_a(Ki),lr=_a(Qi),cr=_a(Xi),dr=_a(Ji),ur=_a(no),pr=_a(to),vr=_a(io),mr=_a(oo),gr=_a(ao),hr=_a(ro),_r=_a(so),fr=_a(lo),yr=_a(po),br=_a(uo),wr=_a(mo),xr=_a(vo),Tr=_a(go),kr=_a(ho),Sr=_a(_o),Er=_a(fo),Ar=_a(yo),Or=_a(bo),Pr=_a(wo),Ir=_a(xo),Cr=_a(To),Lr=_a(ko),jr=_a(So),Mr=_a(Eo),Nr=_a(Ao),Dr=_a(Oo),Rr=_a(Po),Br=_a(Io),Ur=_a(Co),Fr=_a(Lo),Vr=_a(jo),zr=_a(Mo),Hr=_a(No),qr=_a(Do),Gr=_a(Ro),$r=_a(Bo),Wr=_a(Uo),Zr=_a(Fo),Yr=_a(Vo),Kr=_a(zo),Xr=_a(Ho),Qr=_a(qo),Jr=_a(Go),es=_a($o),ts=_a(Wo),ns=_a(Zo),is=_a(Yo),os=_a(Ko),as=_a(Xo),rs=_a(Qo),ss=_a(Jo),ls=_a(ea),cs=_a(ta),ds=_a(na),us=_a(ia),ps=_a(oa),vs=_a(aa),ms=_a(ra),gs=_a(la),hs=_a(ca),_s=_a(da),fs=_a(ua),ys=_a(pa),bs=_a(va),ws=_a(ma),xs=_a(ga),Ts=_a(ha),ks=({colorSchemePreference:e,textDirection:t,safeAreaInsetTop:n,topToastOffset:i,bottomToastOffset:a,zIndexConfig:r,children:s})=>{const l=(0,o.useRef)(0);return o.createElement(Hn.Provider,{value:{idRef:l}},o.createElement(_,{safeAreaInsetTop:n,zIndexConfig:r},o.createElement(u,{colorSchemePreference:e},o.createElement(w,{textDirection:t},o.createElement(zn,{topToastOffset:i,bottomToastOffset:a},s)))))},Ss=e=>({dir:e.textDirection,"data-tux-color-scheme":e.colorSchemePreference}),Es=()=>{const e=(()=>{const e=(0,o.useContext)(d);if(void 0===e)throw new Error("TUXColorSchemeContext is undefined. Make sure to wrap your app with TUXProvider.");return e})(),t=x();return Ss({colorSchemePreference:e,textDirection:t})},As={large:48,medium:32,small:20},Os=e=>{var{size:t="small",className:n,style:i}=e,a=s(e,["size","className","style"]);const r=As[t],l=Yn(),c=`red-hole-${l}`,d=`green-hole-${l}`;return o.createElement("div",Object.assign({className:Qn("TUXLoading-container",n),style:Object.assign({width:r,height:r},i)},a),o.createElement("svg",{id:l,preserveAspectRatio:"none",viewBox:"-24 0 136 136",width:r,height:r},o.createElement("defs",null,o.createElement("mask",{id:c},o.createElement("rect",{width:"100%",height:"100%",fill:"white",x:"-33"}),o.createElement("circle",{cx:53,cy:68,r:17,className:Qn("TUXLoading-redhole","TUXLoading-redhole--isBlack")})),o.createElement("mask",{id:d},o.createElement("rect",{width:"100%",height:"100%",fill:"white",x:"-33"}),o.createElement("circle",{cx:17,cy:68,r:17,className:Qn("TUXLoading-greenhole","TUXLoading-greenhole--isBlack")}))),o.createElement("circle",{cx:17,cy:68,r:17,className:"TUXLoading-blackhole"}),o.createElement("circle",{cx:17,cy:68,r:17,className:"TUXLoading-greenhole",mask:`url(#${c})`}),o.createElement("circle",{cx:53,cy:68,r:17,className:"TUXLoading-redhole",mask:`url(#${d})`})))},Ps={large:48,medium:32,small:20},Is={normal:3,thin:2},Cs=e=>{var{size:t="small",variant:n="normal",className:i,style:a}=e,r=s(e,["size","variant","className","style"]);const l=Ps[t],c=Is[n],d=24-c,u=Math.PI*d;return o.createElement("div",Object.assign({className:Qn("TUXLoadingSpinner-container",i),style:Object.assign({width:l,height:l},a)},r),o.createElement("svg",{viewBox:"0 0 24 24",width:l,height:l,className:"TUXLoadingSpinner"},o.createElement("circle",{cx:12,cy:12,r:d/2,stroke:"currentColor",strokeWidth:c,strokeDasharray:`${u}`,strokeDashoffset:u-.8*u,strokeLinecap:"round",fill:"none"})))},Ls=(0,o.forwardRef)(((e,t)=>{var{label:n,shape:i,size:a="medium",variant:r="primary",type:l="button",leadingIcon:c,trailingIcon:d,disabled:u=!1,loading:p=!1,onClick:v,onDisabledClick:m,className:g}=e,h=s(e,["label","shape","size","variant","type","leadingIcon","trailingIcon","disabled","loading","onClick","onDisabledClick","className"]);const _=p||u,f=["xsmall","small"].includes(a)?"capsule":"default";return o.createElement("button",Object.assign({className:Qn("TUXButton",`TUXButton--${null!=i?i:f}`,`TUXButton--${a}`,`TUXButton--${r}`,_&&"TUXButton--disabled",p&&"TUXButton--loading",g),ref:t,onClick:_?m:v,"aria-disabled":_,disabled:_,type:l},h),o.createElement("div",{className:"TUXButton-content"},c?o.createElement("div",{className:"TUXButton-iconContainer"},c):null,n?o.createElement("div",{className:"TUXButton-label"},n):null,d?o.createElement("div",{className:"TUXButton-iconContainer"},d):null),p?o.createElement(Cs,{className:"TUXButton-spinner"}):null)}));Ls.displayName="TUXButton";const js=e=>{var t=s(e,[]);return o.createElement("svg",Object.assign({height:"1em",width:"1em",viewBox:"0 0 14 14",fill:"currentColor"},t),o.createElement("path",{d:"M0.333252 6.99967C0.333252 3.31778 3.31802 0.333008 6.99992 0.333008C10.6818 0.333008 13.6666 3.31778 13.6666 6.99967C13.6666 7.36786 13.3681 7.66634 12.9999 7.66634C12.6317 7.66634 12.3333 7.36786 12.3333 6.99967C12.3333 4.05416 9.94544 1.66634 6.99992 1.66634C4.0544 1.66634 1.66659 4.05416 1.66659 6.99967C1.66659 9.94519 4.0544 12.333 6.99992 12.333C8.25704 12.333 9.41093 11.8989 10.3225 11.1719C10.6104 10.9423 11.0298 10.9896 11.2594 11.2774C11.489 11.5653 11.4417 11.9847 11.1539 12.2143C10.0147 13.1229 8.56984 13.6663 6.99992 13.6663C3.31802 13.6663 0.333252 10.6816 0.333252 6.99967Z"}))},Ms=e=>{var{label:t,description:n,size:i="medium",loading:a=!1,disabled:r=!1,onChange:l,labelPosition:c="after",className:d,style:u}=e,p=s(e,["label","description","size","loading","disabled","onChange","labelPosition","className","style"]);const v=Yn(),g=a||r,h=x(),_=o.createElement("div",{className:"TUXSwitch-labelContainer"},o.createElement("label",{className:"TUXSwitch-label",htmlFor:v},t),n?o.createElement("div",{className:"TUXSwitch-description"},n):null);return o.createElement("div",{className:Qn("TUXSwitch",d),"data-size":i,"data-disabled":g,"data-loading":a,"data-label-position":c,"data-text-direction":h,style:u},"before"===c?_:null,o.createElement("div",{className:"TUXSwitch-inputContainer"},o.createElement("input",Object.assign({id:v,className:"TUXSwitch-input",role:"switch",type:"checkbox",onChange:g?m:e=>{l(e.target.checked)},"aria-disabled":g},p)),o.createElement("div",{className:"TUXSwitch-handle"},a?o.createElement(js,{className:"TUXSwitch-spinner"}):null)),"after"===c?_:null)},Ns=e=>o.createElement("svg",Object.assign({viewBox:"0 0 8 2",fill:"none"},e),o.createElement("path",{d:"M0 0.466667C0 0.208934 0.208934 0 0.466667 0H7.53333C7.79107 0 8 0.208934 8 0.466667V1.53333C8 1.79107 7.79107 2 7.53333 2H0.466667C0.208934 2 0 1.79107 0 1.53333V0.466667Z",fill:"currentColor"})),Ds=e=>o.createElement("svg",Object.assign({viewBox:"0 0 26 24",fill:"none"},e),o.createElement("path",{d:"M25.0139 1.77347C25.4794 2.07079 25.6156 2.68912 25.3183 3.15454L13.0799 22.3118C12.656 22.9754 11.9442 23.4005 11.1589 23.459C10.3737 23.5175 9.60676 23.2027 9.08914 22.6093L1.02329 13.3629C0.660243 12.9467 0.703321 12.315 1.11951 11.952L3.38024 9.97989C3.79643 9.61683 4.42812 9.65991 4.79117 10.0761L10.6631 16.8075L21.1047 0.462741C21.4021 -0.00267747 22.0204 -0.138942 22.4858 0.158386L25.0139 1.77347Z",fill:"currentColor"})),Rs=e=>{var{id:t,size:n="medium",shape:i="circle",disabled:a,indeterminate:r,hasError:l=!1,className:c,style:d}=e,u=s(e,["id","size","shape","disabled","indeterminate","hasError","className","style"]);return o.createElement("div",{className:Qn("TUXCheckboxStandalone",`TUXCheckboxStandalone--${n}`,`TUXCheckboxStandalone--${i}`,a&&"TUXCheckboxStandalone--disabled",r&&"TUXCheckboxStandalone--indeterminate",l&&"TUXCheckboxStandalone--hasError",c),style:d},o.createElement("input",Object.assign({className:"TUXCheckboxStandalone-input",id:t,type:"checkbox",disabled:a},u)),o.createElement("div",{className:"TUXCheckboxStandalone-indicator"},r?o.createElement(Ns,{className:"TUXCheckboxStandalone-indeterminateIcon"}):o.createElement(Ds,{className:"TUXCheckboxStandalone-checkedIcon"})))},Bs=e=>{var{label:t,description:n,onChange:i,required:a,disabled:r=!1,size:l="medium",labelPosition:c="after",className:d,style:u}=e,p=s(e,["label","description","onChange","required","disabled","size","labelPosition","className","style"]);const v=Yn(),m=o.createElement("div",{className:"TUXCheckbox-labelContainer"},o.createElement("label",{className:"TUXCheckbox-label",htmlFor:v},t),n?o.createElement("div",{className:"TUXCheckbox-description"},n):null);return o.createElement("div",{className:Qn("TUXCheckbox",d),"data-size":l,"data-disabled":r,"data-label-position":c,style:u},"before"===c?m:null,o.createElement(Rs,Object.assign({id:v,size:l,onChange:e=>{null==i||i(e.target.checked)},disabled:r},p)),"after"===c?m:null)},Us=e=>{var{label:t,values:n,onChange:i,options:a,description:r,error:l,hideLabel:c=!1,className:d,style:u}=e,p=s(e,["label","values","onChange","options","description","error","hideLabel","className","style"]);const v=Yn(),m=`${v}_name`,g=`${v}_legend`;return o.createElement(o.Fragment,null,o.createElement("fieldset",Object.assign({className:Qn("TUXCheckboxGroup-fieldset",d),style:u,"aria-describedby":r?g:void 0},p),c?null:o.createElement("div",{className:"TUXCheckboxGroup-header"},o.createElement("legend",{className:"TUXCheckboxGroup-legend"},o.createElement(ti,{size:16,color:"UIText1",weight:"medium"},t)),r?o.createElement("div",{id:g,className:"TUXCheckboxGroup-description"},o.createElement(ti,{size:13,color:"UIText2",weight:"normal"},r)):null),o.createElement("div",{className:"TUXCheckboxGroup-content"},a.map((e=>o.createElement(Bs,{key:e.value,label:e.label,name:m,value:e.value,onChange:t=>((e,t)=>{i(t?[...n,e]:n.filter((t=>t!==e)))})(e.value,t),checked:n.includes(e.value),disabled:e.disabled,shape:"square",hasError:Boolean(l)})))),l?o.createElement(ti,{className:"TUXCheckboxGroup-error",color:"UITextDanger",size:13,weight:"normal"},o.createElement(kr,{className:"TUXCheckboxGroup-errorIcon"}),o.createElement("div",null,l)):null))},Fs=e=>{var{size:t}=e,n=s(e,["size"]);return o.createElement("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},n),o.createElement("path",{d:"M9.85648 18.0129L19.7212 2.7675C19.8712 2.53566 20.1808 2.46932 20.4126 2.61934L21.588 3.37989C21.8198 3.5299 21.8862 3.83946 21.7362 4.0713L11.0078 20.6515C10.8033 20.9675 10.4624 21.1693 10.0869 21.1965C9.7115 21.2237 9.34507 21.0731 9.0972 20.7898L2.42645 13.1661C2.24461 12.9583 2.26567 12.6424 2.47349 12.4606L3.5271 11.5387C3.73491 11.3568 4.0508 11.3779 4.23264 11.5857L9.85648 18.0129Z",fill:"currentColor"}))},Vs=e=>{var{size:t}=e,n=s(e,["size"]);return"small"===t?o.createElement("svg",Object.assign({viewBox:"0 0 16 16"},n),o.createElement("circle",{cx:"8",cy:"8",r:"4.75",stroke:"currentColor",fill:l.UIImageOverlayWhite,strokeWidth:"3.6"})):o.createElement("svg",Object.assign({viewBox:"0 0 24 24"},n),o.createElement("circle",{cx:"12",cy:"12",r:"6.5",stroke:"currentColor",fill:l.UIImageOverlayWhite,strokeWidth:"4.2"}))},zs=e=>{var{size:t}=e,n=s(e,["size"]);return"small"===t?o.createElement("svg",Object.assign({viewBox:"0 0 16 16"},n),o.createElement("circle",{cx:"8",cy:"8",r:"7.25",stroke:"currentColor",fill:"transparent",strokeWidth:"1.5"})):o.createElement("svg",Object.assign({viewBox:"0 0 24 24"},n),o.createElement("circle",{cx:"12",cy:"12",r:"9.25",stroke:"currentColor",fill:"transparent",strokeWidth:"1.5"}))},Hs=e=>{var{size:t}=e,n=s(e,["size"]);return"small"===t?o.createElement("svg",Object.assign({viewBox:"0 0 16 16"},n),o.createElement("circle",{cx:"8",cy:"8",r:"6.5",stroke:"currentColor",fill:l.UIShapeNeutral4,strokeWidth:"0"})):o.createElement("svg",Object.assign({viewBox:"0 0 24 24"},n),o.createElement("circle",{cx:"12",cy:"12",r:"8.5",stroke:"currentColor",fill:l.UIShapeNeutral4,strokeWidth:"0"}))},qs=e=>{var{checked:t=!1,disabled:n=!1,size:i="medium",indicator:a="radio",className:r,style:l}=e,c=s(e,["checked","disabled","size","indicator","className","style"]);return o.createElement("div",{className:Qn("TUXRadioStandalone",`TUXRadioStandalone--${i}`,t&&"TUXRadioStandalone--checked",n&&"TUXRadioStandalone--disabled",r),style:l},o.createElement("input",Object.assign({type:"radio",className:"TUXRadioStandalone-input",disabled:n,checked:t},c)),"radio"===a?o.createElement(o.Fragment,null,o.createElement(zs,{className:"TUXRadioStandalone-circleOutside",size:i}),o.createElement(Vs,{className:"TUXRadioStandalone-circleInside",size:i}),o.createElement(Hs,{className:"TUXRadioStandalone-circleDisabled",size:i})):o.createElement(Fs,{className:"TUXRadioStandalone-check",size:i}))},Gs=e=>{var{label:t,description:n,name:i,value:a,checked:r,onChange:l,disabled:c=!1,size:d="medium",indicator:u="radio",labelPosition:p="after",className:v,style:m}=e,g=s(e,["label","description","name","value","checked","onChange","disabled","size","indicator","labelPosition","className","style"]);const h=Yn(),_=o.createElement("div",{className:"TUXRadio-labelContainer"},o.createElement("label",{className:"TUXRadio-label",htmlFor:h},t),n?o.createElement("div",{className:"TUXRadio-description"},n):null);return o.createElement("div",{className:Qn("TUXRadio",v),"data-size":d,"data-disabled":c,"data-label-position":p,style:m},"before"===p?_:null,o.createElement(qs,Object.assign({id:h,name:i,value:a,checked:r,onChange:()=>{null==l||l(a)},size:d,disabled:c,indicator:u},g)),"after"===p?_:null)},$s=e=>{var{label:t,value:n,onChange:i,options:a,description:r,error:l,hideLabel:c=!1,className:d,style:u}=e,p=s(e,["label","value","onChange","options","description","error","hideLabel","className","style"]);const v=Yn(),m=`${v}_name`,g=`${v}_legend`;return o.createElement(o.Fragment,null,o.createElement("fieldset",Object.assign({className:Qn("TUXRadioGroup-fieldset",d),style:u,"aria-describedby":r?g:void 0},p),c?null:o.createElement("div",{className:"TUXRadioGroup-header"},o.createElement("legend",{className:"TUXRadioGroup-legend"},o.createElement(ti,{size:16,color:"UIText1",weight:"medium"},t)),r?o.createElement("div",{id:g,className:"TUXRadioGroup-description"},o.createElement(ti,{size:13,color:"UIText3",weight:"normal"},r)):null),o.createElement("div",{className:"TUXRadioGroup-content"},a.map((e=>o.createElement(Gs,{key:e.value,label:e.label,name:m,value:e.value,onChange:i,checked:e.value===n,disabled:e.disabled})))),l?o.createElement(ti,{className:"TUXRadioGroup-error",color:"UITextDanger",size:13,weight:"normal"},o.createElement(kr,{className:"TUXRadioGroup-errorIcon"}),o.createElement("div",null,l)):null))},Ws=(0,o.createContext)(void 0),Zs=e=>{var{titleId:t,onOpenChange:n}=e,i=s(e,["titleId","onOpenChange"]);const a=(0,o.useMemo)((()=>({titleId:t,onOpenChange:n})),[t,n]);return o.createElement(Ws.Provider,Object.assign({value:a},i))},Ys=e=>{var t,{open:n,onOpenChange:i,width:a="small",outsidePressDismiss:r=!0,children:l,className:c,style:d,root:u}=e,p=s(e,["open","onOpenChange","width","outsidePressDismiss","children","className","style","root"]);const v=`${Yn()}_title`,m=f(),{refs:g,context:h}=Ln({open:n,onOpenChange:i}),_=En(h),y=Nn(h),b=Cn(h,{outsidePress:r,outsidePressEvent:"mousedown"}),{isMounted:w,status:x}=Dn(h,{duration:120}),{getFloatingProps:T}=Mn([_,y,b]),k=Es();return w?o.createElement(fn,{root:u},o.createElement(Tn,Object.assign({className:"TUXModal-overlay","data-transition-status":x,lockScroll:!0,style:{zIndex:null!==(t=null==d?void 0:d.zIndex)&&void 0!==t?t:m.zIndex.modal}},k),o.createElement(wn,{context:h,order:["floating","content"]},o.createElement("div",Object.assign(Object.assign(Object.assign({className:Qn("TUXModal",c),"data-width":a,ref:g.setFloating,"aria-labelledby":v},T()),{style:d}),p),o.createElement(Zs,{titleId:v,onOpenChange:i},l))))):o.createElement(o.Fragment,null)},Ks=e=>{var{title:t="",subtitle:n="",customTitle:i,leading:a,trailing:r,content:l,hideBackground:c=!1,hideSeparator:d=!1,titleOpacity:u,flexTitle:p=!1,className:v,style:m}=e,g=s(e,["title","subtitle","customTitle","leading","trailing","content","hideBackground","hideSeparator","titleOpacity","flexTitle","className","style"]);const{safeAreaInsetTop:h}=f();return o.createElement("div",Object.assign({className:Qn("_TUXNavBar",!c&&"_TUXNavBar--withBackground",!d&&"_TUXNavBar--withBorder",v),style:Object.assign({paddingBlockStart:h},m)},g),o.createElement("div",{className:"_TUXNavBar-topRow"},o.createElement("div",{className:Qn("_TUXNavBar-leading",!p&&"_TUXNavBar-leading--fixed")},a),o.createElement("div",{className:"_TUXNavBar-titleContainer",style:{opacity:u}},i||o.createElement(o.Fragment,null,o.createElement(ti,{as:"div",size:n?16:17,font:"TikTok Sans",weight:n?"medium":"bold",align:"center",truncate:!0},t),n?o.createElement(ti,{as:"div",size:11,font:"TikTok Sans",weight:"medium",color:"UIText3",align:"center",truncate:!0},n):null)),o.createElement("div",{className:Qn("_TUXNavBar-trailing",!p&&"_TUXNavBar-trailing--fixed")},r)),o.createElement("div",null,l))};Ks.displayName="TUXNavBar";const Xs=e=>{var{icon:t,className:n}=e,i=s(e,["icon","className"]);return o.createElement(oi,Object.assign({className:Qn("TUXNavBarIconButton",n),type:"button"},i),t)},Qs=e=>{var{title:t,leading:n,className:i}=e,a=s(e,["title","leading","className"]);const r=(0,o.useContext)(Ws);if(!r)throw new Error("TUXModalNavBar must be used inside a TUXModal.");return o.createElement("div",Object.assign({className:Qn("TUXModalNavBar",i)},a),o.createElement("div",{className:"TUXModalNavBar-leading"},n),o.createElement("h2",{id:r.titleId,className:"TUXModalNavBar-title"},t),o.createElement("div",{className:"TUXModalNavBar-trailing"},o.createElement(Xs,{"aria-label":"close",icon:o.createElement(Ts,null),onClick:()=>r.onOpenChange(!1)})))},Js=(0,o.createContext)(void 0),el=e=>{var{titleId:t,onOpenChange:n}=e,i=s(e,["titleId","onOpenChange"]);const a=(0,o.useMemo)((()=>({titleId:t,onOpenChange:n})),[t,n]);return o.createElement(Js.Provider,Object.assign({value:a},i))},tl=e=>{var t,{open:n,onOpenChange:i,children:a,orientation:r="portrait",landscapeAlign:l="start",height:c,maxHeight:d,outsidePressDismiss:u=!0,root:p,className:v,style:m}=e,g=s(e,["open","onOpenChange","children","orientation","landscapeAlign","height","maxHeight","outsidePressDismiss","root","className","style"]);const h=`${Yn()}_title`,_=f(),y=x(),b="ltr"===y&&"start"===l||"rtl"===y&&"end"===l,{refs:w,context:T}=Ln({open:n,onOpenChange:i}),k=En(T),S=Nn(T),E=Cn(T,{outsidePressEvent:"mousedown",outsidePress:u}),{isMounted:A,status:O}=Dn(T,{duration:220}),{getFloatingProps:P}=Mn([k,S,E]),I=(()=>{const e=(0,o.useRef)(null),t=(0,o.useCallback)((()=>{e.current&&("timeout"===e.current.type?clearTimeout(e.current.id):cancelAnimationFrame(e.current.id),e.current=null)}),[]),n=(0,o.useCallback)(((n,i)=>{t(),e.current=null!==i?{type:"timeout",id:setTimeout(n,i)}:{type:"animationFrame",id:requestAnimationFrame(n)}}),[t]);return(0,o.useEffect)((()=>()=>{t()}),[t]),(0,o.useMemo)((()=>({set:n,clear:t})),[n,t])})(),[C,L]=(0,o.useState)(!0),j=Es();return(0,o.useEffect)((()=>{A?I.set((()=>{L(!0)}),220):L(!1)}),[I,A]),A?o.createElement(fn,{root:p},o.createElement(Tn,Object.assign({className:Qn("TUXSheet-overlay",{"TUXSheet-overlay--portrait":"portrait"===r,"TUXSheet-overlay--landscape-start":"landscape"===r&&"start"===l,"TUXSheet-overlay--landscape-end":"landscape"===r&&"end"===l}),"data-transition-status":O,lockScroll:C,style:{zIndex:null!==(t=null==m?void 0:m.zIndex)&&void 0!==t?t:_.zIndex.sheet}},j),o.createElement(wn,{context:T,disabled:!C,order:["floating","content"]},o.createElement("div",{className:Qn("TUXSheet-container",{"TUXSheet-container--landscape":"landscape"===r}),style:{height:c,maxHeight:d}},o.createElement("div",Object.assign(Object.assign({className:Qn("TUXSheet",{"TUXSheet--portrait radius-containerslevel1-large-t":"portrait"===r,"TUXSheet--landscape-left radius-containerslevel1-large-r":"landscape"===r&&b,"TUXSheet--landscape-right radius-containerslevel1-large-l":"landscape"===r&&!b},v),style:m,"data-transition-status":O,ref:w.setFloating,"aria-labelledby":h},P()),g),o.createElement(el,{titleId:h,onOpenChange:i},a)))))):o.createElement(o.Fragment,null)},nl=({src:e,alt:t,size:n=32,square:i,border:a,className:r,style:s})=>{const c={width:`${n}px`,height:`${n}px`,border:a&&`1px solid ${l[a]}`};return e?o.createElement("img",{src:e,alt:t,width:n,height:n,className:Qn("TUXBaseAvatar-src",r),style:Object.assign(Object.assign({},c),s)}):i?o.createElement(Ea,{size:`${n}`,className:Qn(n>=56?"TUXBaseAvatar-default--square":"TUXBaseAvatar-default--square--large",r),style:Object.assign(Object.assign({},c),s)}):o.createElement(Aa,{size:`${n}`,className:Qn("TUXBaseAvatar-default",r),style:Object.assign(Object.assign({},c),s)})},il=({src:e,alt:t,size:n=32,square:i,border:a,className:r,style:s})=>o.createElement(nl,{src:e,alt:t,size:n,square:i,border:a,className:r,style:s}),ol=({frontImageSrc:e,backImageSrc:t,alt:n,size:i=32,className:a,style:r})=>{const s=.7*i,l=.75*i,c=i>=56?2:1,d=l/2,u=s/2,p=d+2*u-i,v=i-d,m=u,g=u,{p1:h,p2:_}=((e,t,n,i,o,a)=>{const r=Math.sqrt(Math.pow(n-e,2)+Math.pow(i-t,2)),s=(Math.pow(o,2)-Math.pow(a,2)+Math.pow(r,2))/(2*r),l=Math.sqrt(Math.pow(o,2)-Math.pow(s,2)),c=-(n-e)/(i-t),d=e+s*(n-e)/r,u=t+s*(i-t)/r,p=d-l/Math.sqrt(1+Math.pow(c,2)),v=u+c*(p-d),m=d+l/Math.sqrt(1+Math.pow(c,2)),g={x:p,y:v},h={x:m,y:u+c*(m-d)};return p{var{placement:t="top",visible:n,onVisibleChange:i,content:a,leadingIcon:r,hasTrailingArrow:l=!1,variant:c="primary",size:d="small",hideIndicator:u=!0,root:p,children:v,closeDelay:m=al,className:g,style:h}=e,_=s(e,["placement","visible","onVisibleChange","content","leadingIcon","hasTrailingArrow","variant","size","hideIndicator","root","children","closeDelay","className","style"]);const[y,b]=(0,o.useState)(!1),w=(0,o.useRef)(null),x=f(),T=null!=n?n:y,k=null!=i?i:b,{refs:S,context:E,floatingStyles:P}=Ln({placement:t,open:T,onOpenChange:k,whileElementsMounted:ze,middleware:[Xe(8),Qe(),Je(),et({element:w,padding:8})]}),{isMounted:I}=Dn(E),j=function(e,t){void 0===t&&(t={});const{open:n,onOpenChange:i,dataRef:a,events:r,elements:{domReference:s,floating:l},refs:c}=e,{enabled:d=!0,delay:u=0,handleClose:p=null,mouseOnly:v=!1,restMs:m=0,move:g=!0}=t,h=Wt(),_=$t(),f=Yt(p),y=Yt(u),b=o.useRef(),w=o.useRef(),x=o.useRef(),T=o.useRef(),k=o.useRef(!0),S=o.useRef(!1),E=o.useRef((()=>{})),O=o.useCallback((()=>{var e;const t=null==(e=a.current.openEvent)?void 0:e.type;return(null==t?void 0:t.includes("mouse"))&&"mousedown"!==t}),[a]);o.useEffect((()=>{if(d)return r.on("dismiss",e),()=>{r.off("dismiss",e)};function e(){clearTimeout(w.current),clearTimeout(T.current),k.current=!0}}),[d,r]),o.useEffect((()=>{if(!d||!f.current||!n)return;function e(e){O()&&i(!1,e)}const t=R(l).documentElement;return t.addEventListener("mouseleave",e),()=>{t.removeEventListener("mouseleave",e)}}),[l,n,i,d,f,a,O]);const P=o.useCallback((function(e,t){void 0===t&&(t=!0);const n=Xt(y.current,"close",b.current);n&&!x.current?(clearTimeout(w.current),w.current=setTimeout((()=>i(!1,e)),n)):t&&(clearTimeout(w.current),i(!1,e))}),[y,i]),I=o.useCallback((()=>{E.current(),x.current=void 0}),[]),C=o.useCallback((()=>{if(S.current){const e=R(c.floating.current).body;e.style.pointerEvents="",e.removeAttribute(Kt),S.current=!1}}),[c]);return o.useEffect((()=>{if(d&&A(s)){const e=s;return n&&e.addEventListener("mouseleave",c),null==l||l.addEventListener("mouseleave",c),g&&e.addEventListener("mousemove",o,{once:!0}),e.addEventListener("mouseenter",o),e.addEventListener("mouseleave",r),()=>{n&&e.removeEventListener("mouseleave",c),null==l||l.removeEventListener("mouseleave",c),g&&e.removeEventListener("mousemove",o),e.removeEventListener("mouseenter",o),e.removeEventListener("mouseleave",r)}}function t(){return!!a.current.openEvent&&["click","mousedown"].includes(a.current.openEvent.type)}function o(e){if(clearTimeout(w.current),k.current=!1,v&&!D(b.current)||m>0&&0===Xt(y.current,"open"))return;const t=Xt(y.current,"open",b.current);t?w.current=setTimeout((()=>{i(!0,e)}),t):i(!0,e)}function r(i){if(t())return;E.current();const o=R(l);if(clearTimeout(T.current),f.current){n||clearTimeout(w.current),x.current=f.current(Object.assign(Object.assign({},e),{tree:h,x:i.clientX,y:i.clientY,onClose(){C(),I(),P(i)}}));const t=x.current;return o.addEventListener("mousemove",t),void(E.current=()=>{o.removeEventListener("mousemove",t)})}("touch"!==b.current||!L(l,i.relatedTarget))&&P(i)}function c(n){t()||null==f.current||f.current(Object.assign(Object.assign({},e),{tree:h,x:n.clientX,y:n.clientY,onClose(){C(),I(),P(n)}}))(n)}}),[s,l,d,e,v,m,g,P,I,C,i,n,h,y,f,a]),Et((()=>{var e;if(d&&n&&null!=(e=f.current)&&e.__options.blockPointerEvents&&O()){const e=R(l).body;if(e.setAttribute(Kt,""),e.style.pointerEvents="none",S.current=!0,A(s)&&l){var t,i;const e=s,n=null==h||null==(t=h.nodesRef.current.find((e=>e.id===_)))||null==(i=t.context)?void 0:i.elements.floating;return n&&(n.style.pointerEvents=""),e.style.pointerEvents="auto",l.style.pointerEvents="auto",()=>{e.style.pointerEvents="",l.style.pointerEvents=""}}}}),[d,n,_,l,s,h,f,a,O]),Et((()=>{n||(b.current=void 0,I(),C())}),[n,I,C]),o.useEffect((()=>()=>{I(),clearTimeout(w.current),clearTimeout(T.current),C()}),[d,s,I,C]),o.useMemo((()=>{if(!d)return{};function e(e){b.current=e.pointerType}return{reference:{onPointerDown:e,onPointerEnter:e,onMouseMove(e){n||0===m||(clearTimeout(T.current),T.current=setTimeout((()=>{k.current||i(!0,e.nativeEvent)}),m))}},floating:{onMouseEnter(){clearTimeout(w.current)},onMouseLeave(e){r.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),P(e.nativeEvent,!1)}}}}),[r,d,m,n,i,P])}(E,{delay:{open:0,close:m}}),M=function(e,t){void 0===t&&(t={});const{open:n,onOpenChange:i,dataRef:a,events:r,refs:s,elements:{floating:l,domReference:c}}=e,{enabled:d=!0,keyboardOnly:u=!0}=t,p=o.useRef(""),v=o.useRef(!1),m=o.useRef();return o.useEffect((()=>{if(!d)return;const e=R(l).defaultView||window;function t(){!n&&O(c)&&c===C(R(c))&&(v.current=!0)}return e.addEventListener("blur",t),()=>{e.removeEventListener("blur",t)}}),[l,c,n,d]),o.useEffect((()=>{if(d)return r.on("dismiss",e),()=>{r.off("dismiss",e)};function e(e){"referencePress"!==e.type&&"escapeKey"!==e.type||(v.current=!0)}}),[r,d]),o.useEffect((()=>()=>{clearTimeout(m.current)}),[]),o.useMemo((()=>d?{reference:{onPointerDown(e){let{pointerType:t}=e;p.current=t,v.current=!(!t||!u)},onMouseLeave(){v.current=!1},onFocus(e){var t;v.current||"focus"===e.type&&"mousedown"===(null==(t=a.current.openEvent)?void 0:t.type)&&B(a.current.openEvent,c)||i(!0,e.nativeEvent)},onBlur(e){v.current=!1;const t=e.relatedTarget,n=A(t)&&t.hasAttribute(Zt("focus-guard"))&&"outside"===t.getAttribute("data-type");m.current=setTimeout((()=>{L(s.floating.current,t)||L(c,t)||n||i(!1,e.nativeEvent)}))}}}:{}),[d,u,c,s,a,i])}(E),N=Nn(E,{role:"tooltip"}),U=Cn(E),{getReferenceProps:F,getFloatingProps:V}=Mn([j,M,N,U]);return o.createElement(o.Fragment,null,o.createElement("div",Object.assign({ref:S.setReference,className:Qn("TUXTooltip-reference",g),style:h},F()),v),I?o.createElement(fn,{root:p},o.createElement("div",Object.assign(Object.assign({ref:S.setFloating,className:`TUXTooltip-tooltip TUXTooltip-tooltip--${c} TUXTooltip-tooltip--${d}`,style:Object.assign({zIndex:x.zIndex.tooltip},P)},V()),_),r?o.createElement("div",{className:"TUXTooltip-leadingIcon"},r):null,o.createElement("div",{className:"TUXTooltip-content P1-Medium"},a),l?o.createElement("div",{className:"TUXTooltip-trailingArrow"},o.createElement(eo,null)):null,u?null:o.createElement(Ht,{fill:"currentColor",ref:w,context:E}))):null)},sl=({inputId:e,label:t,description:n,error:i,requirement:a="optional",characterCount:r=0,maxLength:s,hideLabel:l=!1,children:c,className:d,style:u})=>{const p=`${e}_label`,v=`${e}_description`,m=`${e}_error`;let g=null;return"required"===a&&(g=o.createElement("div",{className:"TUXFormField-requiredStar"},"*")),o.createElement("div",{className:Qn("TUXFormField",d),style:u},!l&&o.createElement("div",{className:"TUXFormField-header"},o.createElement("div",{className:"TUXFormField-labelRow"},o.createElement("div",{className:"TUXFormField-label Headline-Medium"},o.createElement("label",{htmlFor:e,id:p},t)),g),o.createElement("div",{className:"TUXFormField-description P2-Regular",id:v},n)),c,i||void 0!==s?o.createElement("div",{className:"TUXFormField-footer"},o.createElement("div",{className:"TUXFormField-error P2-Medium",id:m},i?o.createElement(o.Fragment,null,o.createElement("div",{className:"TUXFormField-errorIcon"},o.createElement(kr,{size:"12px"})),i):null),void 0!==s?o.createElement("div",{className:Qn("TUXFormField-wordCount",r>s&&"TUXFormField-wordCount--max")},r,"/",s):null):null)},ll=(0,o.forwardRef)(((e,t)=>{var{size:n,disabled:i=!1,hasError:a=!1,hasFocusRing:r=!1,children:l,className:c}=e,d=s(e,["size","disabled","hasError","hasFocusRing","children","className"]);return o.createElement("div",Object.assign({className:Qn("TUXInputBox",{"TUXInputBox-focus-ring":r},c),ref:t,"data-size":n,"data-disabled":i,"data-has-error":a},d),l)})),cl={large:20,medium:20,small:16,xsmall:14},dl={large:5,medium:5,small:4,xsmall:3},ul=(0,o.forwardRef)(((e,t)=>{var{value:n,onChange:i,onClear:a,prefix:r,suffix:l,size:c="large",leadingIcon:d,trailingIcon:u,loading:p=!1,clearable:v=!1,placeholder:m,disabled:h=!1,required:_=!1,hasDescription:f=!1,hasError:y=!1,inputId:b,readOnly:w=!1,isValid:x=!1,className:T,style:k}=e,S=s(e,["value","onChange","onClear","prefix","suffix","size","leadingIcon","trailingIcon","loading","clearable","placeholder","disabled","required","hasDescription","hasError","inputId","readOnly","isValid","className","style"]);const E=(0,o.useRef)(null),A=`${b}_description`,O=`${b}_error`,P={fontSize:cl[c],padding:dl[c]};return o.createElement("div",{className:Qn("TUXTextInputCore",`TUXTextInputCore--${c}`,T),style:k},d?o.createElement("div",{className:"TUXTextInputCore-leadingIconWrapper",style:{fontSize:cl[c]}},d):null,r?o.createElement("div",{className:"TUXTextInputCore-prefix"},r):null,o.createElement("input",Object.assign({className:"TUXTextInputCore-input",type:"text",id:b,"aria-required":_,"aria-invalid":y,"aria-describedby":y?O:f?A:void 0,ref:g(t,E),value:n,placeholder:m,onChange:e=>{i(e.target.value,e)},disabled:h,readOnly:w},S)),l?o.createElement("div",{className:"TUXTextInputCore-suffix"},l):null,p?o.createElement("div",{className:"TUXTextInputCore-trailingIconWrapper",style:P},o.createElement(ds,{className:"TUXTextInputCore-loadingIcon"})):null,v&&n&&!h?o.createElement(oi,{className:"TUXTextInputCore-clearButton",onClick:e=>{var t;i(""),null==a||a(e),null===(t=E.current)||void 0===t||t.focus()},onMouseDown:e=>e.preventDefault(),style:P},o.createElement(bs,{color:"UITextPlaceholder"})):null,x?o.createElement("div",{style:P},o.createElement(ms,{color:"UIShapeSuccess"})):null,u?o.createElement("div",{className:"TUXTextInputCore-trailingIconWrapper",style:P},u):null)})),pl=(0,o.forwardRef)(((e,t)=>{var{value:n,onChange:i,onClear:a,placeholder:r,size:l="large",hideLabel:c=!1,label:d,description:u,requirement:p,isError:v=!1,error:m,prefix:g,suffix:h,disabled:_=!1,leadingIcon:f,trailingIcon:y,loading:b=!1,clearable:w=!1,maxLength:x,readOnly:T=!1,isValid:k=!1,hasFocusRing:S=!1,className:E,style:A}=e,O=s(e,["value","onChange","onClear","placeholder","size","hideLabel","label","description","requirement","isError","error","prefix","suffix","disabled","leadingIcon","trailingIcon","loading","clearable","maxLength","readOnly","isValid","hasFocusRing","className","style"]);const P=Yn(),I=Boolean(m)||Boolean(x&&n.length>x)||v;return o.createElement(sl,{className:Qn("TUXTextInput",E),inputId:P,label:d,hideLabel:c,requirement:p,description:u,error:m,characterCount:n.length,maxLength:x,style:A},o.createElement(ll,{size:l,disabled:_,hasError:I,hasFocusRing:S},o.createElement(ul,Object.assign({inputId:P,ref:t,value:n,placeholder:r,size:l,onChange:i,onClear:a,prefix:g,suffix:h,leadingIcon:f,trailingIcon:y,loading:b,clearable:w,required:"required"===p,disabled:_,hasDescription:Boolean(u),hasError:I,readOnly:T,isValid:k},O))))})),vl=({disabled:e,error:t,children:n,className:i,style:a})=>o.createElement("div",{className:Qn("TUXTextAreaBox",e&&"TUXTextAreaBox--disabled",t&&"TUXTextAreaBox--error",i),style:a},n),ml=(0,o.forwardRef)(((e,t)=>{var{value:n,onChange:i,placeholder:a,inputId:r,disabled:l,required:c,hasError:d,hasDescription:u,autoSize:p}=e,v=s(e,["value","onChange","placeholder","inputId","disabled","required","hasError","hasDescription","autoSize"]);const m=`${r}_description`,g=`${r}_error`,h=`${n} `;return o.createElement("div",{className:"TUXTextAreaCore","data-auto-size":p},p?o.createElement("div",{className:"TUXTextAreaCore-hiddenText"},h):null,o.createElement("textarea",Object.assign({className:"TUXTextAreaCore-textarea",id:r,placeholder:a,disabled:l,"aria-required":c,"aria-invalid":d,"aria-describedby":d?g:u?m:void 0,ref:t,value:n,onChange:e=>{i(e.target.value,e)}},v)))})),gl=(0,o.forwardRef)(((e,t)=>{var{label:n,hideLabel:i,value:a,onChange:r,placeholder:l,disabled:c,description:d,requirement:u,error:p,maxLength:v,autoSize:m,className:g,style:h}=e,_=s(e,["label","hideLabel","value","onChange","placeholder","disabled","description","requirement","error","maxLength","autoSize","className","style"]);const f=Yn();return o.createElement("div",{className:Qn("TUXTextArea",g),style:h},o.createElement(sl,{inputId:f,label:n,hideLabel:i,requirement:u,description:d,error:p,characterCount:a.length,maxLength:v},o.createElement(vl,{error:Boolean(p),disabled:c},o.createElement(ml,Object.assign({value:a,onChange:r,placeholder:l,inputId:f,disabled:c,required:"required"===u,hasError:Boolean(p),hasDescription:Boolean(d),autoSize:m,ref:t},_)))))})),hl=e=>{var{tabs:t,defaultTab:n,activeTab:i,onChange:a,compact:r=!1,className:l,style:c}=e,d=s(e,["tabs","defaultTab","activeTab","onChange","compact","className","style"]);const[u,p]=(0,o.useState)(null!=n?n:""),v=a?i:u,m=(0,o.useRef)([]),[g,h]=(0,o.useState)(Array(t.length).fill(0)),_=t.findIndex((e=>e.id===v)),f=x(),y=(0,o.useMemo)((()=>{const e=_>0?g.slice(0,_).reduce(((e,t)=>e+t)):0;return"ltr"===f?e+10*(2*_+1):-1*e-10*(2*_+1)}),[_,g,f]),b=e=>{e.disabled||(a?a(e.id):e.id!==u&&p(e.id))},w=()=>{const e=m.current.map((e=>(null==e?void 0:e.clientWidth)?e.clientWidth-20:void 0));h(e)};return(0,o.useEffect)((()=>{w()}),[t.length]),(0,o.useEffect)((()=>(window.addEventListener("resize",w),()=>{window.removeEventListener("resize",w)})),[]),o.createElement("div",Object.assign({className:Qn("TUXTabBar",l),style:c,"data-compact":Boolean(r)},d),o.createElement("div",{className:"TUXTabBar-list"},o.createElement("div",{className:"TUXTabBar-activeLine",style:{transform:`translateX(${y}px)`,transition:"transform 100ms cubic-bezier(0.33, 0.86, 0.2, 1)",width:`${g[_]}px`}}),o.createElement(Dt,{orientation:"horizontal",render:o.createElement("div",{style:{display:"flex",width:"100%"}})},t.map(((e,t)=>o.createElement("div",{className:"TUXTabBar-item",key:e.id,id:e.id,ref:e=>m.current[t]=e},o.createElement(Rt,{render:o.createElement("button",{className:Qn("TUXTabBar-itemTitle",v===e.id&&"TUXTabBar-itemTitle--active",e.disabled&&"TUXTabBar-itemTitle--disabled"),type:"button",disabled:e.disabled,onClick:()=>{b(e)},onFocus:()=>{b(e)},id:e.id},e.leadingIcon?o.createElement("div",{className:"TUXTabBar-itemTitle-leadingIcon"},e.leadingIcon):null,o.createElement("div",null,e.title),e.hasTrailingArrow?o.createElement("div",{className:"TUXTabBar-itemTitle-trailingArrow"},o.createElement(Bi,null)):null)}))))),o.createElement("div",{className:"TUXTabBar-underline"})),o.createElement("div",{className:"TUXTabBar-content",tabIndex:0},t.filter((e=>e.id===v))[0].content))},_l=e=>{var{items:t,value:n,onChange:i,size:a="s",shape:r="capsule",compact:l=!1,className:c}=e,d=s(e,["items","value","onChange","size","shape","compact","className"]);return o.createElement("div",Object.assign({className:Qn("TUXSegmentedControl",c),"data-compact":Boolean(l),"data-size":a,"data-shape":r},d),t.map((e=>o.createElement(oi,{"aria-label":e.title,key:e.value,className:"TUXSegmentedControl-item","data-active":n===e.value,"data-has-subtitle":Boolean(e.subtitle),onClick:()=>i(e.value)},o.createElement("div",{className:"TUXSegmentedControl-itemTitleContainer"},e.leadingIcon?o.createElement("div",{className:"TUXSegmentedControl-itemIcon"},e.leadingIcon):null,e.hideTitle?null:o.createElement("div",{className:"TUXSegmentedControl-itemTitle"},e.title),e.trailingIcon?o.createElement("div",{className:"TUXSegmentedControl-itemIcon"},e.trailingIcon):null),e.subtitle?o.createElement("div",{className:"TUXSegmentedControl-itemSubtitle"},e.subtitle):null))))},fl=e=>{var{label:t,href:n,rel:i,disabled:a=!1,size:r,color:c="UITextPrimaryDisplay",weight:d="normal",className:u,style:p}=e,v=s(e,["label","href","rel","disabled","size","color","weight","className","style"]);return o.createElement("a",Object.assign({className:Qn("TUXLink",a&&"TUXLink--disabled",u),style:Object.assign({fontSize:r?`${r}px`:"inherit",color:l[c]},p),href:a?void 0:n,rel:i},v),o.createElement(ti,{weight:d,font:"TikTok Sans"},t))},yl=e=>{var{width:t="64px",height:n="64px",borderRadius:i="2px",className:a,style:r}=e,l=s(e,["width","height","borderRadius","className","style"]);return o.createElement("div",Object.assign({className:Qn("TUXSkeletonRectangle",a),style:Object.assign({width:t,height:n,borderRadius:i},r)},l))},bl=e=>{var{size:t="small",hideBadge:n,children:i,className:a,style:r}=e,l=s(e,["size","hideBadge","children","className","style"]);const c=x();return o.createElement("div",{className:"TUXAlertBadgeDot-reference"},i,!n&&o.createElement("div",Object.assign({className:Qn("TUXAlertBadgeDot",`TUXAlertBadgeDot--${t}`,a),style:r,"data-text-direction":c},l)))},wl=e=>{var t,{placement:n="top",open:i,onOpenChange:a,trigger:r,root:l,noArrow:c,autoFocus:d,positionStrategy:u="absolute",floatingGap:p,children:v,className:m,style:g}=e,h=s(e,["placement","open","onOpenChange","trigger","root","noArrow","autoFocus","positionStrategy","floatingGap","children","className","style"]);const[_,b]=(0,o.useState)(!1),w=(0,o.useRef)(null),x=y(),T=f(),k=null!=i?i:_,S=null!=a?a:b,{refs:E,context:A,floatingStyles:O}=Ln({placement:n,open:k,onOpenChange:S,whileElementsMounted:ze,middleware:[Xe(void 0!==p?p:c?4:12),Qe(),Je(),et({element:w,padding:12})],strategy:u}),{isMounted:P,status:I}=Dn(A,{duration:300}),C=En(A),L=Nn(A),j=Cn(A),{getReferenceProps:M,getFloatingProps:N}=Mn([C,j,L]),D=o.cloneElement(r,Object.assign({ref:E.setReference},M(r.props)));return o.createElement(o.Fragment,null,D,P?o.createElement(fn,{root:l},o.createElement(wn,{context:A,modal:!1,returnFocus:!0,initialFocus:d?0:-1},o.createElement("div",Object.assign(Object.assign({ref:E.setFloating,className:Qn("TUXPopover-popover",`TUXPopover-popover--${I}`,"dark"===x&&"TUXPopover-popover--dark"),style:Object.assign({transition:"opacity 300ms cubic-bezier(0.65, 0, 0.35, 1)",zIndex:null!==(t=null==g?void 0:g.zIndex)&&void 0!==t?t:T.zIndex.popover},O)},N()),h),o.createElement("div",{className:Qn("TUXPopover-content",m),style:g},v),!c&&o.createElement(Ht,{fill:"currentColor",ref:w,context:A,height:8,tipRadius:3,stroke:"dark"===x?"rgb(105, 105, 105)":"rgb(235, 235, 235)",strokeWidth:1})))):null)},xl=(0,o.createContext)(null),Tl=e=>{var{placement:t="bottom-start",open:n,onOpenChange:i,trigger:a,noArrow:r=!0,autoFocus:l,positionStrategy:c,children:d,className:u,style:p}=e,v=s(e,["placement","open","onOpenChange","trigger","noArrow","autoFocus","positionStrategy","children","className","style"]);return o.createElement(xl.Provider,{value:{onOpenChange:i}},o.createElement(wl,Object.assign({placement:t,open:n,onOpenChange:i,trigger:a,noArrow:r,autoFocus:l,positionStrategy:c,style:p,className:Qn(u,"TUXMenu")},v),d))},kl=e=>{var{leadingIcon:t,trailingIcon:n,checked:i,destructive:a,onClick:r,preventCloseOnClick:l,as:c,children:d,className:u,style:p}=e,v=s(e,["leadingIcon","trailingIcon","checked","destructive","onClick","preventCloseOnClick","as","children","className","style"]);const m=(0,o.useContext)(xl);if(!m)throw new Error("TUXMenuItem must be used inside of TUXMenu.");const g=null!=c?c:"div",h=null!=n?n:o.createElement(sa,null);return o.createElement(g,Object.assign({className:Qn("TUXMenuItem",a&&"TUXMenuItem--destructive",u),tabIndex:0,onClick:e=>{l||m.onOpenChange(!1),null==r||r(e)},style:p},v),t?o.createElement("div",{className:"TUXMenuItem-leadingIcon"},t):null,o.createElement(ti,{size:16,weight:"medium",truncate:!0,className:"TUXMenuItem-label"},d),i?o.createElement("div",{className:"TUXMenuItem-trailingIcon"},h):null)},Sl=((0,o.createContext)(null),({thickness:e="thin",color:t="UIShapeNeutral3",direction:n="horizontal",customColorValue:i})=>{const a=null!=i?i:l[t];return o.createElement("div",{role:"separator",className:Qn("tux-separator",`tux-separator-${e}--${n}`),style:{backgroundColor:a}})});new Date(2017,0,1),new Date(2017,0,2),new Date(2017,0,3),new Date(2017,0,4),new Date(2017,0,5),new Date(2017,0,6),new Date(2017,0,7),new Date(2017,0,1),new Date(2017,0,2),new Date(2017,0,3),new Date(2017,0,4),new Date(2017,0,5),new Date(2017,0,6),new Date(2017,0,7);class El{}var Al;function Ol(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}El.lockId=0,El.locker=new Map,El.registerLock=()=>(El.lockId+=1,El.locker.set(El.lockId,!0),El.lockId),El.unregisterLock=e=>{El.locker.delete(e)},El.enterScrollLock=()=>{const e=document.documentElement,{body:t}=document,n=window.pageYOffset||e.scrollTop||t.scrollTop||0,i=document.createElement("style");i.id="tux-screen-lock",i.innerHTML=`\n html {\n height: 100%;\n overflow: hidden;\n }\n body {\n ${n>0?"height: auto;":""}\n min-height: 100%; /* for ios 12 */\n top: -${n}px;\n left: 0;\n right: 0;\n position: fixed;\n }\n `,t.appendChild(i),t.setAttribute("tux-screen-lock-offset",`-${n}`)},El.getBodyFixedTopOffset=()=>{var e;if(!v&&document.body.hasAttribute("tux-screen-lock-offset"))return parseInt(null!==(e=document.body.getAttribute("tux-screen-lock-offset"))&&void 0!==e?e:"0",10)},El.exitScrollLock=()=>{var e;const t=document.documentElement,{body:n}=document,i=document.getElementById("tux-screen-lock"),o=-(null!==(e=El.getBodyFixedTopOffset())&&void 0!==e?e:0);if(i&&n.removeChild(i),n.removeAttribute("tux-screen-lock-offset"),"scrollBehavior"in t.style){const e=document.createElement("style");e.innerHTML="\n html, body {\n scroll-behavior: auto !important;\n }\n ",n.appendChild(e),window.scrollTo({top:o,behavior:"auto"}),n.removeChild(e)}else o&&window.scrollTo(0,o)},El.getBodyFixedTopOffset,(0,o.createContext)({isScrolled:!1,setIsScrolled:m,showCloseButtonBG:!1,setShowCloseButtonBG:m}),function(e){e.NO_BOUNCE_SLOW="NO_BOUNCE_SLOW",e.NO_BOUNCE_FAST="NO_BOUNCE_FAST",e.STRONG_BOUNCE="STRONG_BOUNCE",e.WEEK_BOUNCE="WEEK_BOUNCE",e.INSTANT="INSTANT"}(Al||(Al={})),Al.NO_BOUNCE_SLOW,Al.NO_BOUNCE_FAST,Al.WEEK_BOUNCE,Al.STRONG_BOUNCE,Al.INSTANT,Al.NO_BOUNCE_SLOW,Al.NO_BOUNCE_FAST,Al.WEEK_BOUNCE,Al.STRONG_BOUNCE,Al.INSTANT;var Pl="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,Il="object"==typeof self&&self&&self.Object===Object&&self,Cl=Pl||Il||Function("return this")(),Ll=Cl.Symbol,jl=Object.prototype,Ml=jl.hasOwnProperty,Nl=jl.toString,Dl=Ll?Ll.toStringTag:void 0,Rl=Object.prototype.toString,Bl="[object Null]",Ul="[object Undefined]",Fl=Ll?Ll.toStringTag:void 0;function Vl(e){return null==e?void 0===e?Ul:Bl:Fl&&Fl in Object(e)?function(e){var t=Ml.call(e,Dl),n=e[Dl];try{e[Dl]=void 0;var i=!0}catch(e){}var o=Nl.call(e);return i&&(t?e[Dl]=n:delete e[Dl]),o}(e):function(e){return Rl.call(e)}(e)}function zl(e){return null!=e&&"object"==typeof e}var Hl="[object Symbol]";function ql(e){return"symbol"==typeof e||zl(e)&&Vl(e)==Hl}Math.max,Math.min;(0,o.createContext)({isControlled:!1}).displayName="TUXWheelPickerContext";var Gl=Object.prototype;var $l,Wl,Zl=($l=Object.keys,Wl=Object,function(e){return $l(Wl(e))}),Yl=Object.prototype.hasOwnProperty;function Kl(e){if(n=(t=e)&&t.constructor,t!==("function"==typeof n&&n.prototype||Gl))return Zl(e);var t,n,i=[];for(var o in Object(e))Yl.call(e,o)&&"constructor"!=o&&i.push(o);return i}var Xl="[object AsyncFunction]",Ql="[object Function]",Jl="[object GeneratorFunction]",ec="[object Proxy]";function tc(e){if(!Ol(e))return!1;var t=Vl(e);return t==Ql||t==Jl||t==Xl||t==ec}var nc,ic=Cl["__core-js_shared__"],oc=(nc=/[^.]+$/.exec(ic&&ic.keys&&ic.keys.IE_PROTO||""))?"Symbol(src)_1."+nc:"",ac=Function.prototype.toString;function rc(e){if(null!=e){try{return ac.call(e)}catch(e){}try{return e+""}catch(e){}}return""}var sc=/^\[object .+?Constructor\]$/,lc=Function.prototype,cc=Object.prototype,dc=lc.toString,uc=cc.hasOwnProperty,pc=RegExp("^"+dc.call(uc).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function vc(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return function(e){return!(!Ol(e)||function(e){return!!oc&&oc in e}(e))&&(tc(e)?pc:sc).test(rc(e))}(n)?n:void 0}var mc=vc(Cl,"DataView"),gc=vc(Cl,"Map"),hc=vc(Cl,"Promise"),_c=vc(Cl,"Set"),fc=vc(Cl,"WeakMap"),yc="[object Map]",bc="[object Promise]",wc="[object Set]",xc="[object WeakMap]",Tc="[object DataView]",kc=rc(mc),Sc=rc(gc),Ec=rc(hc),Ac=rc(_c),Oc=rc(fc),Pc=Vl;(mc&&Pc(new mc(new ArrayBuffer(1)))!=Tc||gc&&Pc(new gc)!=yc||hc&&Pc(hc.resolve())!=bc||_c&&Pc(new _c)!=wc||fc&&Pc(new fc)!=xc)&&(Pc=function(e){var t=Vl(e),n="[object Object]"==t?e.constructor:void 0,i=n?rc(n):"";if(i)switch(i){case kc:return Tc;case Sc:return yc;case Ec:return bc;case Ac:return wc;case Oc:return xc}return t});var Ic=Pc;function Cc(e){return zl(e)&&"[object Arguments]"==Vl(e)}var Lc=Object.prototype,jc=Lc.hasOwnProperty,Mc=Lc.propertyIsEnumerable,Nc=Cc(function(){return arguments}())?Cc:function(e){return zl(e)&&jc.call(e,"callee")&&!Mc.call(e,"callee")},Dc=Array.isArray,Rc=9007199254740991;function Bc(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=Rc}function Uc(e){return null!=e&&Bc(e.length)&&!tc(e)}var Fc="object"==typeof exports&&exports&&!exports.nodeType&&exports,Vc=Fc&&e&&!e.nodeType&&e,zc=Vc&&Vc.exports===Fc?Cl.Buffer:void 0,Hc=(zc?zc.isBuffer:void 0)||function(){return!1},qc={};qc["[object Float32Array]"]=qc["[object Float64Array]"]=qc["[object Int8Array]"]=qc["[object Int16Array]"]=qc["[object Int32Array]"]=qc["[object Uint8Array]"]=qc["[object Uint8ClampedArray]"]=qc["[object Uint16Array]"]=qc["[object Uint32Array]"]=!0,qc["[object Arguments]"]=qc["[object Array]"]=qc["[object ArrayBuffer]"]=qc["[object Boolean]"]=qc["[object DataView]"]=qc["[object Date]"]=qc["[object Error]"]=qc["[object Function]"]=qc["[object Map]"]=qc["[object Number]"]=qc["[object Object]"]=qc["[object RegExp]"]=qc["[object Set]"]=qc["[object String]"]=qc["[object WeakMap]"]=!1;var Gc="object"==typeof exports&&exports&&!exports.nodeType&&exports,$c=Gc&&e&&!e.nodeType&&e,Wc=$c&&$c.exports===Gc&&Pl.process,Zc=function(){try{return $c&&$c.require&&$c.require("util").types||Wc&&Wc.binding&&Wc.binding("util")}catch(e){}}(),Yc=Zc&&Zc.isTypedArray,Kc=Yc?function(e){return function(t){return e(t)}}(Yc):function(e){return zl(e)&&Bc(e.length)&&!!qc[Vl(e)]};Object.prototype.hasOwnProperty;const Xc=e=>{var{children:t,className:n,inline:i=!1,basis:a,grow:r,shrink:l,direction:c,wrap:d,style:u}=e,p=s(e,["children","className","inline","basis","grow","shrink","direction","wrap","style"]);const v=Object.assign(Object.assign(Object.assign({},u),p),{display:i?"inline-flex":"flex",flexDirection:c,flexWrap:d,flexBasis:a,flexGrow:r,flexShrink:l});return o.createElement("div",{className:n,style:v},t)};var Qc=function(){try{var e=vc(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();function Jc(e,t,n,i){for(var o=-1,a=null==e?0:e.length;++o-1&&e%1==0&&e-1},ud.prototype.set=function(e,t){var n=this.__data__,i=cd(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this};var pd=vc(Object,"create"),vd=Object.prototype.hasOwnProperty,md=Object.prototype.hasOwnProperty;function gd(e){var t=-1,n=null==e?0:e.length;for(this.clear();++ts))return!1;var c=a.get(e),d=a.get(t);if(c&&d)return c==t&&d==e;var u=-1,p=!0,v=n&xd?new yd:void 0;for(a.set(e,t),a.set(t,e);++u{const e=Su(Eu,(e=>e.label[0]));ad(e).sort().map((t=>({label:t,options:e[t]})))})()},44137:(e,t,n)=>{"use strict";n.d(t,{X:()=>r});var i=n(39858),o=n.n(i),a=n(97208);const r=o()((()=>{if((0,a.fU)())return!1;const e=window.navigator.userAgent;if(!/iPad|iPhone|iPod/.test(e))return!!(null===window||void 0===window?void 0:window.MediaSource)&&((null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.1.6.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.2.4.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.3.E.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.4.10.L120.90"')));try{const e=document.createElement("video");return[e.canPlayType('video/mp4; codecs="hvc1.1.L0.0"'),e.canPlayType('video/mp4;codecs="hev1.1.6.L120.90"'),e.canPlayType('video/mp4;codecs="hev1.2.4.L120.90"'),e.canPlayType('video/mp4;codecs="hev1.3.E.L120.90"'),e.canPlayType('video/mp4;codecs="hev1.4.10.L120.90"')].some((e=>"probably"===e||"maybe"===e))}catch(e){return!1}}))},67353:(e,t,n)=>{"use strict";n.d(t,{AX:()=>g,y8:()=>h,hd:()=>m,p$:()=>p,bt:()=>v});var i=n(44137),o=n(75420),a=n(68735);n(40099),new o.Vb;const r=new a.A;var s,l=n(74745),c=n(97208);const d=()=>r.shouldUseHEVC,u={isSupportBase:null!==(s=d())&&void 0!==s&&s,isHevcSupportRobustness:"unknown",date:new Date};let p={isSupportBase:(0,i.X)()?1:0,isHevcSupportRobustness:"unKnown",project:"unkowon"};const v=new class{constructor(){this.canPlayHevc=!1,this.forceNotHevc=!1,this.h264DropedRate=0,this.h265DropedRate=0,this.minDif=10,this.minFrames=60,this.maxDropedRate=10,this.robustnessTestResult=!1,this.updateHevcInfo(),this.hevcTest={open:!1,qualityType:20,closePreload:!1}}updateHevcInfo(){(0,c.fU)()||(u&&d()?this.forceNotHevc?this.canPlayHevc=!1:this.canPlayHevc="supported"===u.isHevcSupportRobustness:this.canPlayHevc=!1)}useHevc(e){try{return"desktop"===e?(this.updateHevcInfo(),this.canPlayHevc):"mobile"===e&&!(!(0,i.X)()||this.forceNotHevc)}catch(e){return!1}}setDropRate(e,t,n){if(tthis.minDif||this.h265DropedRate>this.maxDropedRate)&&(this.canPlayHevc=!1,this.forceNotHevc=!0)}},m=(e,t=!1)=>{try{const n="webapp-mobile"===e?1:2;l.a.hevcDeviceDetect(t,n)}catch(e){}},g=e=>{try{const t="is unsupported",{message:n="",errorCode:i=1,errorMessage:o=""}=e,a=n||o;return!!a.includes(t)&&(l.a.focusDisableHevc({hevcMsg:a,hevcCode:i}),!0)}catch(e){return!1}},h=e=>{if(!e)return!1;const{videoWidth:t,videoHeight:n}=e;return 0===t&&0===n&&(l.a.focusDisableHevc({hevcMsg:"width and height is 0",hevcCode:2}),!0)}},97208:(e,t,n)=>{"use strict";n.d(t,{Tb:()=>o,Zr:()=>i,fU:()=>a});let i=-1;function o(e,...t){i<0&&(i=location.search.includes("ttplayer_debug=1")?1:0),i&&console.log(`[MultiMedia1][${e}]`,...t)}function a(){return"undefined"==typeof window||"undefined"==typeof document}},40046:(e,t,n)=>{"use strict";n.d(t,{H$:()=>D,nK:()=>f,qZ:()=>b,uv:()=>y,IX:()=>C,eS:()=>I});var i=n(56070),o=n(26325),a=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const r=class extends Error{constructor(e,t){super(e),this.name="ApiError",this.code=t}},s=e=>{var t;return e instanceof r&&null!==(t=e.code)&&void 0!==t?t:-1};var l,c;!function(e){e[e.NIL=-255]="NIL",e[e.UnknownError=-1]="UnknownError",e[e.Ok=0]="Ok",e[e.ReportLiveFailed=90002]="ReportLiveFailed",e[e.VerifyCode=1e4]="VerifyCode",e[e.VideoLikeFreq=2150]="VideoLikeFreq",e[e.VideoLikeFreq2=2210]="VideoLikeFreq2",e[e.VideoUnavailableDeleted=2054]="VideoUnavailableDeleted",e[e.AdVideoUnavailableChange=2752]="AdVideoUnavailableChange",e[e.CommentBanCode=22]="CommentBanCode",e[e.CommentLikePermissionDisable=3002043]="CommentLikePermissionDisable",e[e.SearchSensitiveCode=403]="SearchSensitiveCode",e[e.SearchYoungCode=203]="SearchYoungCode",e[e.SmsInvalidNumber=-1]="SmsInvalidNumber",e[e.SmsSlideVerify=-4]="SmsSlideVerify",e[e.FypVideoListLimit=10404]="FypVideoListLimit",e[e.ClientPageError=450]="ClientPageError",e[e.LiveNeedLogin=10119]="LiveNeedLogin",e[e.SharkBlock=10114]="SharkBlock",e[e.SharkSlide=10113]="SharkSlide",e[e.NetError=10111]="NetError",e[e.ServerErrorNot500=10101]="ServerErrorNot500",e[e.VideoRisk=10228]="VideoRisk",e[e.VideoRMask=10229]="VideoRMask",e[e.VideoRiskMask=10230]="VideoRiskMask",e[e.VideoNeedRecheck=10227]="VideoNeedRecheck",e[e.VideoUnshelveByMusic=10220]="VideoUnshelveByMusic",e[e.VideoNotExist=10204]="VideoNotExist",e[e.VideoAbnormal=10215]="VideoAbnormal",e[e.VideoLowAgeM=10213]="VideoLowAgeM",e[e.VideoLowAgeT=10214]="VideoLowAgeT",e[e.VideoFirstReviewUnshelve=10217]="VideoFirstReviewUnshelve",e[e.VideoPrivateByUser=10216]="VideoPrivateByUser",e[e.VideoGeofenceBlock=10231]="VideoGeofenceBlock",e[e.VideoPhoto=10239]="VideoPhoto",e[e.VideoFriendsOnly=10240]="VideoFriendsOnly",e[e.VideoDeleted=10241]="VideoDeleted",e[e.VideoUserBlockedByAuthor=10242]="VideoUserBlockedByAuthor",e[e.VideoSubscribersOnly=203005]="VideoSubscribersOnly",e[e.HashtagNotExist=10205]="HashtagNotExist",e[e.HashtagUnshelve=10212]="HashtagUnshelve",e[e.HashtagSensitivityWord=10211]="HashtagSensitivityWord",e[e.HashtagBlackList=10209]="HashtagBlackList",e[e.UserInboxFollowBan=24]="UserInboxFollowBan",e[e.UserNotExist=10202]="UserNotExist",e[e.UserBan=10221]="UserBan",e[e.UserPrivate=10222]="UserPrivate",e[e.UserNotLogin=10102]="UserNotLogin",e[e.UserFtc=10223]="UserFtc",e[e.UserUniqueSensitivity=10225]="UserUniqueSensitivity",e[e.QuestionNotAvailable=10236]="QuestionNotAvailable",e[e.MusicNotExist=10203]="MusicNotExist",e[e.MusicUnshelve=10218]="MusicUnshelve",e[e.MusicNoCopyright=10219]="MusicNoCopyright",e[e.MusicUnavailable=202001]="MusicUnavailable",e[e.PlaceNotExist=205001]="PlaceNotExist",e[e.PlaceOffline=205002]="PlaceOffline",e[e.PlaceUnavailableInRegion=205003]="PlaceUnavailableInRegion",e[e.GameNotExist=10224]="GameNotExist",e[e.LiveNotExist=10210]="LiveNotExist",e[e.GoLiveRoomBaned=10018]="GoLiveRoomBaned",e[e.GoLiveBaned=4003035]="GoLiveBaned",e[e.LiveRoomPrepare=30019]="LiveRoomPrepare",e[e.LiveRoomEnd=30003]="LiveRoomEnd",e[e.LiveRoomBan=30012]="LiveRoomBan",e[e.LiveNoGatedAuth=4003043]="LiveNoGatedAuth",e[e.LiveNoAgeGatedAuth=4003110]="LiveNoAgeGatedAuth",e[e.LivePaidEvent=4003072]="LivePaidEvent",e[e.LiveSubscriberOnly=4003135]="LiveSubscriberOnly",e[e.LiveSuicideCase=2403]="LiveSuicideCase",e[e.LiveSensitiveTitle=50004]="LiveSensitiveTitle",e[e.LiveRoomBaned=10018]="LiveRoomBaned",e[e.LiveEnterRoomNeedLogin=20003]="LiveEnterRoomNeedLogin",e[e.LiveAccountUnderRiskControl=20063]="LiveAccountUnderRiskControl",e[e.LiveHitBanStrategy=30009]="LiveHitBanStrategy",e[e.LiveOBSAccessRecalled=4003105]="LiveOBSAccessRecalled",e[e.LiveUserNotFound=19881007]="LiveUserNotFound",e[e.EffectNotExist=10208]="EffectNotExist",e[e.PlaylistNotExist=10233]="PlaylistNotExist",e[e.PlaylistInTrill=10234]="PlaylistInTrill",e[e.VideoPlaylistUnavailable=10243]="VideoPlaylistUnavailable",e[e.VideoPlaylistIsEmpty=10244]="VideoPlaylistIsEmpty",e[e.PrivateAccountLimitByBC=3026002]="PrivateAccountLimitByBC",e[e.PnsPnsPrivateAccountLimitByLiveOn=3026006]="PnsPnsPrivateAccountLimitByLiveOn",e[e.BlockedAndLogout=56009]="BlockedAndLogout",e[e.CreatePlaylistWithRiskError=206001]="CreatePlaylistWithRiskError",e[e.VideoPlaylistVisibleToCreator=206002]="VideoPlaylistVisibleToCreator",e[e.AddPlaylistVideoWithRiskError=206003]="AddPlaylistVideoWithRiskError",e[e.VideoPlaylistUnavailableToVisitor=206004]="VideoPlaylistUnavailableToVisitor",e[e.VideoPlaylistDeleted=206005]="VideoPlaylistDeleted"}(l||(l={})),function(e){e[e.Hot=0]="Hot",e[e.Relation=1]="Relation",e[e.Fresh=2]="Fresh",e[e.Post=3]="Post",e[e.Favorite=4]="Favorite",e[e.Challenge=5]="Challenge",e[e.Music=6]="Music",e[e.Category=7]="Category",e[e.MusicFresh=8]="MusicFresh",e[e.ChallengeFresh=9]="ChallengeFresh",e[e.Follow=10]="Follow",e[e.Trending=18]="Trending",e[e.TitleRecommend=20]="TitleRecommend",e[e.Nearby=21]="Nearby",e[e.Search=23]="Search",e[e.HotVideo=24]="HotVideo",e[e.HotMusic=25]="HotMusic",e[e.FollowerList=26]="FollowerList",e[e.Inbox=33]="Inbox",e[e.Live=27]="Live"}(c||(c={}));var d,u=n(69589),p=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};function v(e=[],t={}){return e.reduce(((e,n)=>{const{reply_comment:i,cid:o}=n;return i&&(0,u.setDataForQueryByKey)(["comment","reply",o],(()=>({pageParams:[i.length],pages:[{cursor:`${i.length}`,comments:i,hasMore:!0}]}))),e.comments.push(function(e,t={}){return Object.assign(Object.assign({},e),{logId:t.logId})}(n,t)),e}),{comments:[]})}!function(e){e[e.Like=1]="Like",e[e.Unlike=2]="Unlike"}(d||(d={}));const m=e=>p(void 0,void 0,void 0,(function*(){var t,n,o,s;const{aweme_id:l,cursor:c="0",insert_ids:d,isNonPersonalized:p}=e;try{const e=yield function(e){return a(this,void 0,void 0,(function*(){return i.h.get("/api/comment/list/",{query:Object.assign(Object.assign({},e),{count:20}),baseUrlType:2})}))}({insert_ids:"0"===c?d:void 0,aweme_id:l,cursor:c,is_non_personalized:p});if(e.status_code,0===e.status_code&&(null===(t=e.comments)||void 0===t?void 0:t.length)){const{comments:t}=v(e.comments,{logId:null===(n=e.log_pb)||void 0===n?void 0:n.impr_id}),i=null!==(s=null===(o=(0,u.getDataForQueryByKey)(["comment",l]))||void 0===o?void 0:o.pages.flatMap((t=>t.cursor!==e.cursor?t.comments:[])))&&void 0!==s?s:[],a=new Set(i.map((e=>e.cid))),r=t.filter((e=>!a.has(e.cid)));return 0===r.length&&e.has_more?m({aweme_id:l,cursor:e.cursor.toString(),insert_ids:d,isNonPersonalized:p}):{comments:r,hasMore:Boolean(e.has_more),cursor:e.cursor,isFirstLoad:0===Number(c),total:e.total}}throw new r("Comment fetch returned no new comments",e.status_code)}catch(e){return{comments:[],hasMore:!0,cursor:c,isFirstLoad:0===Number(c),total:0}}})),g=e=>p(void 0,void 0,void 0,(function*(){var t,n,o;const{itemId:s,cid:l,cursor:c="0"}=e;try{const e=yield function(e){return a(this,void 0,void 0,(function*(){return i.h.get("/api/comment/list/reply/",{query:Object.assign(Object.assign({},e),{count:3}),baseUrlType:2})}))}({comment_id:l,item_id:s,cursor:c});if(e.status_code,0===e.status_code){const{comments:i}=v(e.comments,{logId:null===(t=e.log_pb)||void 0===t?void 0:t.impr_id}),a=["comment","reply",l],r=null!==(o=null===(n=(0,u.getDataForQueryByKey)(a))||void 0===n?void 0:n.pages.flatMap((t=>t.cursor!==e.cursor?t.comments:[])))&&void 0!==o?o:[],c=new Set(r.map((e=>e.cid))),d=i.filter((e=>!c.has(e.cid)));return 0===d.length&&e.has_more?g({itemId:s,cid:l,cursor:e.cursor.toString()}):{comments:[...d],cursor:e.cursor,hasMore:1===e.has_more}}throw new r("Failed to save reply list")}catch(e){return{cursor:c,comments:[],hasMore:!0}}})),h=e=>t=>p(void 0,void 0,void 0,(function*(){const{itemId:n,like:l,cid:c,parentCid:d}=t;if(e&&!d)throw new r("Reply comments need a parentCid to be provided");try{return{statusCode:(yield function(e){return a(this,void 0,void 0,(function*(){return i.h.post("/api/comment/digg/",{query:Object.assign(Object.assign({},e),{channel_id:0}),headers:{[o.nk]:i.h.csrfToken},baseUrlType:2})}))}({aweme_id:n,cid:c,digg_type:l?1:2})).status_code}}catch(e){return{statusCode:s(e)}}})),_=e=>p(void 0,void 0,void 0,(function*(){const{itemId:t,cid:n,parentCid:l}=e;try{const e=yield function(e){return a(this,void 0,void 0,(function*(){return i.h.post("/api/comment/delete/",{query:e,baseUrlType:2,headers:{[o.nk]:i.h.csrfToken}})}))}({cid:n});if(0!==e.status_code)throw new r(e.msg,e.status_code);if(l){const e=["comment",t];(0,u.setDataForQueryByKey)(e,(e=>{if(void 0===e)throw new r("Problem encountered with updating comment count");return{pageParams:e.pageParams,pages:e.pages.map((e=>Object.assign(Object.assign({},e),{comments:e.comments.map((e=>e.cid===l?Object.assign(Object.assign({},e),{reply_comment_total:Number(e.reply_comment_total)-1}):e))})))}}))}return{statusCode:e.status_code}}catch(e){return{statusCode:s(e)}}})),f=e=>{const{aweme_id:t}=e.comment,n=["comment",t],i=(0,u.getDataForQueryByKey)(n);return i?{pageParams:i.pageParams,pages:[{cursor:i.pages[0].cursor,comments:[e.comment,...i.pages[0].comments],hasMore:i.pages[0].hasMore,isFirstLoad:i.pages[0].isFirstLoad},...i.pages.slice(1)]}:{pageParams:[1],pages:[{cursor:1,comments:[e.comment],hasMore:!0,isFirstLoad:!0}]}},y=e=>{const{awemeId:t,parentCid:n}=e,i=["comment",t],o=(0,u.getDataForQueryByKey)(i);if(!o)throw new r("cannot reply to a comment when there are no comments");return{pageParams:o.pageParams,pages:o.pages.map((e=>Object.assign(Object.assign({},e),{comments:e.comments.map((e=>e.cid===n?Object.assign(Object.assign({},e),{reply_comment_total:e.reply_comment_total?Number(e.reply_comment_total)+1:1}):e))})))}},b=e=>{const{parentCid:t}=e,n=["comment","reply",t],i=(0,u.getDataForQueryByKey)(n);return i?{pageParams:i.pageParams,pages:[{cursor:i.pages[0].cursor,comments:[e.reply,...i.pages[0].comments],hasMore:i.pages[0].hasMore,isFirstLoad:i.pages[0].isFirstLoad},...i.pages.slice(1)]}:{pageParams:[1],pages:[{cursor:1,comments:[e.reply],hasMore:!0,isFirstLoad:!0}]}},w=e=>["comment",e.videoId],x=e=>["comment","reply",e.commentId],T={query:{fetchComment:{queryKeys:w,queryFn:m,infinite:!0}},mutation:{postCommentLike:{queryKeys:w,mutationFn:h(!1),optimisticUpdate:e=>{const{itemId:t,cid:n,like:i,isVideoAuthor:o}=e,a=["comment",t],s=(0,u.getDataForQueryByKey)(a);if(!s)throw new r("Tried to like a comment that could not be found in query cache");return{pageParams:s.pageParams,pages:s.pages.map((e=>Object.assign(Object.assign({},e),{comments:e.comments.map((e=>e.cid===n?Object.assign(Object.assign({},e),{user_digged:i?1:2,digg_count:i?e.digg_count+1:e.digg_count-1,is_author_digged:o?i:e.is_author_digged}):e))})))}}},postCommentDelete:{queryKeys:w,mutationFn:_,optimisticUpdate:e=>{const{itemId:t,cid:n}=e,i=["comment",t],o=(0,u.getDataForQueryByKey)(i);if(!o)throw new r("Tried to delete a video that could not be found in query cache");return{pageParams:o.pageParams,pages:o.pages.map((e=>Object.assign(Object.assign({},e),{comments:e.comments.flatMap((e=>e.cid===n?[]:e))})))}}}}},k={query:{fetchReply:{queryKeys:x,queryFn:g,infinite:!0}},mutation:{postReplyLike:{queryKeys:x,mutationFn:h(!0),optimisticUpdate:e=>{const{cid:t,parentCid:n,like:i,isVideoAuthor:o}=e;if(!n)throw new r("Reply comments need a parentCid to be provided");const a=["comment","reply",n],s=(0,u.getDataForQueryByKey)(a);if(!s)throw new r("Tried to like a comment that could not be found in query cache");return{pageParams:s.pageParams,pages:s.pages.map((e=>Object.assign(Object.assign({},e),{comments:e.comments.map((e=>e.cid===t?Object.assign(Object.assign({},e),{user_digged:i?1:0,digg_count:i?e.digg_count+1:e.digg_count-1,is_author_digged:o?i:e.is_author_digged}):e))})))}}},postReplyDelete:{queryKeys:x,mutationFn:_,optimisticUpdate:e=>{const{cid:t,parentCid:n}=e;if(!n)throw new r("Reply comments need a parentComment to be provided");const i=["comment","reply",n],o=(0,u.getDataForQueryByKey)(i);if(!o)throw new r("Could not find reply list for this comment");return{pageParams:o.pageParams,pages:o.pages.map((e=>Object.assign(Object.assign({},e),{comments:e.comments.flatMap((e=>e.cid===t?[]:e))})))}}}}};var S;function E({relation:e,handleIsUnfollow:t,handleIsFollow:n}){switch(e){case 0:case-1:case 4:case 5:case 6:return t();default:return n()}}function A({current:e,targetUser:t}){const n=function(e){var t;return E({relation:null!==(t=e.relation)&&void 0!==t?t:-1,handleIsUnfollow:()=>{var t;return e.privateAccount?1:(null===(t=e.extraInfo)||void 0===t?void 0:t.followed)||6===e.relation?2:0},handleIsFollow:()=>3})}(t);switch(n){case 3:return 0;case 0:return E({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>1});case 1:return E({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>3});case 2:return E({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>2});default:return E({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>-1})}}!function(e){e[e.FollowNormal=0]="FollowNormal",e[e.FollowPrivate=1]="FollowPrivate",e[e.FollowFollower=2]="FollowFollower",e[e.Unfollow=3]="Unfollow"}(S||(S={}));var O=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};var P=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const I=e=>{var t;const{uniqueId:n}=e,i=["user",n],o=(0,u.getDataForQueryByKey)(i);if(!o)throw new r("target user does not exist",10202);var a,s;return Object.assign(Object.assign({},o),{user:Object.assign(Object.assign({},o.user),{relation:A({current:o.user.relation,targetUser:o.user}),extraInfo:Object.assign(Object.assign({},o.user.extraInfo),{followed:(a=o.user.relation,s=null===(t=o.user.extraInfo)||void 0===t?void 0:t.followed,2===a||6===a||5!==a&&s)})})})},C=e=>{const{uniqueId:t,isBlock:n}=e,i=["user",t],o=(0,u.getDataForQueryByKey)(i);if(!o)throw new r("target user does not exist",10202);return Object.assign(Object.assign({},o),{user:Object.assign(Object.assign({},o.user),{relation:n?0:4})})},L=e=>["user",e.uniqueId],j={query:{getUserDetail:{queryKeys:L,queryFn:e=>P(void 0,void 0,void 0,(function*(){try{const t=yield function(e){return O(this,void 0,void 0,(function*(){return i.h.get("/api/user/detail/",{query:e,baseUrlType:2})}))}(e);if(0!==t.statusCode&&10222!==t.statusCode||!t.userInfo)throw new r("Get user detail failed",t.statusCode);return{user:Object.assign(Object.assign({uniqueIdModifyTime:0},t.userInfo.user),{extraInfo:{statusCode:t.statusCode}}),stats:Object.assign(Object.assign({},t.userInfo.stats),{needFix:!1})}}catch(e){throw e}})),infinite:!1}},mutation:{postCommitFollowUser:{queryKeys:L,mutationFn:e=>P(void 0,void 0,void 0,(function*(){var t;try{const{uniqueId:t,useFollowV2:n}=e,a=["user",t],s=(0,u.getDataForQueryByKey)(a);if(!s)throw new r("target user does not exist",10202);const{id:l,secUid:c="",relation:d}=s.user,p=function(e){return E({relation:e,handleIsUnfollow:()=>0,handleIsFollow:()=>1})}(d),v={type:1===p?1:0,action_type:1===p?1:0,user_id:l,sec_user_id:c,from:18,channel_id:0,from_pre:0},m=n?yield function(e){return O(this,void 0,void 0,(function*(){return i.h.post("/api/follow/",{signal:(new AbortController).signal,query:Object.assign(Object.assign({},e),{fromWeb:1}),baseUrlType:2,headers:{[o.nk]:i.h.csrfToken}})}))}(v):yield function(e){return O(this,void 0,void 0,(function*(){return i.h.post("/api/commit/follow/user/",{query:Object.assign(Object.assign({},e),{fromWeb:1}),baseUrlType:2,headers:{[o.nk]:i.h.csrfToken}})}))}(v),{status_code:g,follow_status:h}=m;if(24===g)throw new r("inbox_follow_failed_banned",24);if(-1===g)throw new r("inbox_follow_failed_noconnection",-1);if(0!==g)throw new r("inbox_follow_failed_other",g);return{statusCode:g,followStatus:h}}catch(e){return e instanceof r?{statusCode:null!==(t=e.code)&&void 0!==t?t:-1,followStatus:-1}:{statusCode:-1,followStatus:-1}}})),optimisticUpdate:I},blockOrUnblockUser:{queryKeys:L,mutationFn:e=>P(void 0,void 0,void 0,(function*(){var t;try{const{secUid:t,isBlock:n}=e,{status_code:a}=yield function(e){return O(this,void 0,void 0,(function*(){return i.h.post("/api/user/block/",{query:Object.assign(Object.assign({},e),{source:3}),baseUrlType:2,headers:{[o.nk]:i.h.csrfToken}})}))}({sec_user_id:t,block_type:n?0:1});return a}catch(e){return e instanceof r&&null!==(t=e.code)&&void 0!==t?t:-1}})),optimisticUpdate:C}}};var M=n(51660);const N={query:{getRelatedVideoList:{queryKeys:e=>["video","related",e.itemId],queryFn:e=>{return t=void 0,n=void 0,a=function*(){const{itemId:t,language:n,isNonPersonalized:o,coverFormat:a}=e,r=(0,M.uk)(n),s=yield(l={aid:1988,count:16,itemID:t,language:r,coverFormat:a,isNonPersonalized:o},i.h.get("/api/related/item_list/",{query:l,baseUrlType:2}));var l;return Object.assign(Object.assign({},s),{hasMore:!0})},new((o=void 0)||(o=Promise))((function(e,i){function r(e){try{l(a.next(e))}catch(e){i(e)}}function s(e){try{l(a.throw(e))}catch(e){i(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof o?n:new o((function(e){e(n)}))).then(r,s)}l((a=a.apply(t,n||[])).next())}));var t,n,o,a}}}},D=()=>[T,k,j,N]},75248:(e,t,n)=>{"use strict";n.d(t,{Hd:()=>a,Jz:()=>r,R4:()=>d,S4:()=>s,VN:()=>u,e5:()=>l,i3:()=>c,ol:()=>p});var i=n(43723),o=n(31209);const a=(0,i.p)("basicPlayerAtom@tiktok/webapp-atoms",{mute:!0,playing:!0,volume:0,canAutoPlay:!0,playProgress:null}),{useServiceState:r,useServiceDispatchers:s,useAtomService:l}=(0,o.i)(a,((e,t)=>({setMute(e){t(a,(t=>Object.assign(Object.assign({},t),{mute:e})))},setVolume(e){t(a,(t=>Object.assign(Object.assign({},t),{volume:Math.min(Math.max(0,e),1)})))},setPlaying(e){t(a,(t=>Object.assign(Object.assign({},t),{playing:e})))},setCanAutoPlay(e){t(a,(t=>Object.assign(Object.assign({},t),{canAutoPlay:e})))},getStaticBasicPlayerState:()=>e(a)}))),c=()=>r((e=>e.mute)),d=()=>r((e=>e.volume)),u=()=>r((e=>e.playing)),p=()=>r((e=>e.playProgress))},93341:(e,t,n)=>{"use strict";n.d(t,{$V:()=>_,GF:()=>S,LM:()=>x,MY:()=>y,PU:()=>D,R3:()=>I,RT:()=>E,Ul:()=>k,VP:()=>T,fD:()=>L,gu:()=>C,hM:()=>A,ik:()=>M,nU:()=>O,nr:()=>b,w:()=>P,x1:()=>j,yA:()=>f,yG:()=>N});var i=n(94999),o=n(68252),a=n(38739),r=n(43723),s=n(31209),l=n(32125),c=n(97086),d=n(18499),u=n(90341),p=n(75248);const v="w_g_vv",m="w_g_fyp_vv",g=1e6,h={prevVideo:null,currentVideo:null,playType:"hover",globalVvCount:0,fypVvCount:0,justWatchedVideo:null,predictedPreloadConfig:{},defaultResolution:void 0,multiInstanceActualResolutions:{},autoResolution:!0},_=()=>{var e,t;const n=Object.assign({},h);if((0,c.fU)())return n;try{n.globalVvCount=Number(null!==(e=localStorage.getItem(v))&&void 0!==e?e:"0"),n.fypVvCount=Number(null!==(t=localStorage.getItem(m))&&void 0!==t?t:"0")}catch(e){console.warn("getLocalStorage failed for key: webapp_vv_count")}return n},f=(0,r.p)("videoPlayerAtom@tiktok/webapp-atoms",_()),{useServiceState:y,useServiceDispatchers:b,useAtomService:w,getStaticApi:x}=(0,s.i)(f,((e,t)=>({setAutoResolution(e){t(f,(t=>Object.assign(Object.assign({},t),{autoResolution:e})))},setDefaultResolution(e){t(f,(t=>Object.assign(Object.assign({},t),{defaultResolution:e,autoResolution:"auto"===e})))},setDefaultResolutionAndUpdateLocalStorage(e){this.setDefaultResolution(e);try{localStorage.setItem("resolution_auto",e)}catch(e){console.warn("setLocalStorage failed for key: resolution")}},setMultiInstanceActualResolution(e,n){t(f,(t=>{let i=Object.assign({},t.multiInstanceActualResolutions);i[e]=n;let o=[...t.recentVideoIndexes||[]];return o.includes(e)||(o=[e,...o]),o.length>4&&(o=o.slice(0,4)),i=Object.fromEntries(Object.entries(i).filter((([e])=>o.includes(Number(e))))),Object.assign(Object.assign({},t),{multiInstanceActualResolutions:i,recentVideoIndexes:o})}))},updateVideo(e){const{needResetReport:n=!0,currentVideo:{index:o},teaParams:{isThreeColumnAuto:r=!1,isVideoDetail:s=!1,enterMethod:l="",backendSourceEventTracking:v=""}={}}=e,m=i.l.getInstance(a.Gs);m.setIsThreeColumnAuto(r),m.setEnterMethod(l),m.setBackendSourceEventTracking(v),m.setIsVideoDetail(s),!(0,c.fU)()&&window.videoChangedCallback&&window.videoChangedCallback(o),n&&m.reset(),(0,d.unstable_batchedUpdates)((()=>{var n;t(f,(t=>Object.assign(Object.assign({},t),{prevVideo:t.currentVideo,currentVideo:e.currentVideo,playType:e.playType}))),t(p.Hd,(t=>Object.assign(Object.assign({},t),{playProgress:e.playProgress}))),t(u.vl,(e=>Object.assign(Object.assign({},e),{isPlayerError:!1}))),!(null==(n=e.currentVideo)?void 0:n.id)||void 0===(null==n?void 0:n.mode)||0!==(null==n?void 0:n.mode)&&2!==(null==n?void 0:n.mode)&&9!==(null==n?void 0:n.mode)&&4!==(null==n?void 0:n.mode)||t(f,(e=>Object.assign(Object.assign({},e),{justWatchedVideo:n})))}))},updateVideoFocusTime(e){i.l.getInstance(a.Gs).updateVideoFocusTime(e.blurTime)},updateGlobalVVCount(n){const{globalVvCount:i=0,fypVvCount:a=0}=e(f);let r=i;i<=g&&1!==n&&(r=i+1,(0,o.AP)(v,String(r)),t(f,(e=>Object.assign(Object.assign({},e),{globalVvCount:r})))),a<=g&&0===n&&((0,o.AP)(m,String(a+1)),t(f,(e=>Object.assign(Object.assign({},e),{fypVvCount:a+1}))))},updatePredictedPreloadConfig(e){t(f,(t=>Object.assign(Object.assign({},t),{predictedPreloadConfig:e})))},getStaticPlayerState:()=>e(f)}))),T=()=>y((e=>{var t,n;return Number(null!==(n=null===(t=e.currentVideo)||void 0===t?void 0:t.index)&&void 0!==n?n:0)})),k=()=>y((e=>e.currentVideo)),S=()=>y((e=>{var t;return null===(t=e.currentVideo)||void 0===t?void 0:t.id})),E=()=>y((e=>{var t,n;return null!==(n=null===(t=e.currentVideo)||void 0===t?void 0:t.mode)&&void 0!==n?n:null}),l.bN),A=()=>y((e=>e.defaultResolution)),O=e=>y((t=>{var n;return(null===(n=null==t?void 0:t.currentVideo)||void 0===n?void 0:n.index)===e}),l.bN),P=(e,t,n)=>y((i=>{var o,a,r;return(null===(o=null==i?void 0:i.currentVideo)||void 0===o?void 0:o.index)===e&&(null===(a=null==i?void 0:i.currentVideo)||void 0===a?void 0:a.mode)===t&&(null===(r=null==i?void 0:i.currentVideo)||void 0===r?void 0:r.id)===n}),l.bN),I=(e,t)=>y((n=>{var i,o;return(null===(i=null==n?void 0:n.currentVideo)||void 0===i?void 0:i.index)===e-1&&(null===(o=null==n?void 0:n.currentVideo)||void 0===o?void 0:o.mode)===t}),l.bN),C=e=>y((t=>{var n;return null===(n=t.multiInstanceActualResolutions)||void 0===n?void 0:n[e]}),l.bN),L=()=>y((e=>e.autoResolution),l.bN),j=(e,t)=>y((n=>{var i,o;return(null===(i=null==n?void 0:n.currentVideo)||void 0===i?void 0:i.index)===e+1&&(null===(o=null==n?void 0:n.currentVideo)||void 0===o?void 0:o.mode)===t}),l.bN),M=e=>y((t=>{var n;return(null===(n=null==t?void 0:t.currentVideo)||void 0===n?void 0:n.index)===e-1}),l.bN),N=e=>y((t=>{var n;return(null===(n=null==t?void 0:t.currentVideo)||void 0===n?void 0:n.index)===e+1}),l.bN),D=()=>{var e;return null!==(e=y((e=>e.predictedPreloadConfig)))&&void 0!==e?e:{}}},90341:(e,t,n)=>{"use strict";n.d(t,{J3:()=>c,Sx:()=>v,eu:()=>m,ms:()=>p,vl:()=>s});var i=n(43723),o=n(31209),a=n(97086);const r={isPlayerError:!1,showUnmuteTooltip:!1,isAutoScroll:!1},s=(0,i.p)("videoPlayerViewAtom@tiktok/webapp-atoms",(()=>{var e;const t=Object.assign({},r);if((0,a.fU)())return t;try{const n=null!==(e=localStorage.getItem("auto_scroll"))&&void 0!==e?e:"0";t.isAutoScroll="1"===n}catch(e){console.warn("getLocalStorage failed for key: auto_scroll")}return t})());s.debugLabel="videoPlayerViewAtom";const{useServiceState:l,useServiceDispatchers:c,useAtomService:d,getStaticApi:u}=(0,o.i)(s,((e,t)=>({setAutoScroll(e){t(s,(t=>Object.assign(Object.assign({},t),{isAutoScroll:e})))},setAutoScrollAndUpdateLocalStorage(e){this.setAutoScroll(e);try{localStorage.setItem("auto_scroll",e?"1":"0")}catch(e){console.warn("setLocalStorage failed for key: auto_scroll")}},toggleAutoScroll(){this.setAutoScrollAndUpdateLocalStorage(!e(s).isAutoScroll)},updateShowUnmuteTooltip(e){t(s,(t=>Object.assign(Object.assign({},t),{showUnmuteTooltip:e})))},setPlayerError(){t(s,(e=>Object.assign(Object.assign({},e),{isPlayerError:!0})))},getStaticPlayerUIState:()=>e(s)}))),p=()=>{var e;return null!==(e=l((e=>e.isPlayerError)))&&void 0!==e&&e},v=()=>{var e;return null!==(e=l((e=>e.showUnmuteTooltip)))&&void 0!==e&&e},m=()=>{var e;return null!==(e=l((e=>e.isAutoScroll)))&&void 0!==e&&e}},56013:(e,t,n)=>{"use strict";n.d(t,{ZC:()=>p,d7:()=>m,mo:()=>u});var i=n(88874),o=n(65450),a=n(43723),r=n(14374),s=n(31209),l=n(39785),c=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const d=(0,l.M)({csr:()=>c(void 0,void 0,void 0,(function*(){var e;const t=null!==(e=(0,i.YI)(o.X))&&void 0!==e?e:{pageId:"-1",vidList:[],parameters:{}};return Promise.resolve(t)}))}),u=(0,r._)((0,a.p)("seoAbtestAtom@tiktok/webapp-atoms",{}),{rehydrationKey:"seo.abtest.state"}),{useAtomService:p,useServiceDispatchers:v,useServiceState:m}=(0,s.i)(u,((e,t)=>({setAbtest(n){return c(this,void 0,void 0,(function*(){const i=e(u),{canonical:o}=i;if(n!==o)return t(u,{canonical:n,abtest:yield d()})}))}})))},9472:(e,t,n)=>{"use strict";n.d(t,{b:()=>o});var i=n(43723);const o=(0,n(14374)._)((0,i.p)("seoMetaStateAtom@tiktok/webapp-atoms",{metaParams:{},jsonldList:[],disableAlternateLink:!1,generateAlternateWithCanonical:!1,enableAlternateHreflang:!1,alternateHreflangList:[]}),{rehydrationKey:"seo.meta.state"})},7089:(e,t,n)=>{"use strict";n.d(t,{kV:()=>p,hG:()=>d,VR:()=>u});var i=n(14374),o=n(31209),a=n(43723),r=n(56070),s=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))},l=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const c=(0,i._)((0,a.p)("businessAtom@tiktok/webapp-atoms",{businessPermission:{comment:!1,message:!1},businessAccountInfoResponse:{statusCode:1,statusMsg:"",data:void 0}}),{rehydrationKey:"webapp.business"}),{useAtomService:d,useServiceState:u,useServiceDispatchers:p,getStaticApi:v}=(0,o.i)(c,((e,t)=>({setBusinessPermission(e){t(c,(t=>Object.assign(Object.assign({},t),{businessPermission:e})))},setBusinessAccountInfoResponse(e){t(c,(t=>Object.assign(Object.assign({},t),{businessAccountInfoResponse:e})))},getBusinessPermissionList(){var e;return l(this,void 0,void 0,(function*(){const t=yield function(){return s(this,void 0,void 0,(function*(){return r.h.get("/api/ba/business/suite/permission/list/",{query:{permissionList:"001004,001005"},baseUrlType:2})}))}(),n=null!==(e=null==t?void 0:t.permissionList)&&void 0!==e?e:[];this.setBusinessPermission({message:n.indexOf("001004")>-1,comment:n.indexOf("001005")>-1})}))},getBusinessAccountInfoResponse(){return l(this,void 0,void 0,(function*(){const e=yield function(){return s(this,void 0,void 0,(function*(){return r.h.get("/api/ba/business/suite/bs/account/info/",{query:{scene:"dm"},baseUrlType:2})}))}();this.setBusinessAccountInfoResponse(e)}))}})))},4685:(e,t,n)=>{"use strict";n.d(t,{fL:()=>s,lu:()=>l});var i=n(31209);const o=(0,n(43723).p)("deviceScoreAtom@tiktok/webapp-atoms",{hardwareScore:-1,totalDeviceScore:-1}),{useAtomService:a,useServiceDispatchers:r,useServiceState:s,getStaticApi:l}=(0,i.i)(o,((e,t)=>({updateHardwareScore(e){t(o,(t=>Object.assign(Object.assign({},t),{hardwareScore:e})))},updateTotalDeviceScore(e){t(o,(t=>Object.assign(Object.assign({},t),{totalDeviceScore:e})))}})))},16680:(e,t,n)=>{"use strict";n.d(t,{CP:()=>k,JF:()=>y,b1:()=>T,MR:()=>w,mZ:()=>x});var i=n(57432),o=n.n(i),a=n(4474),r=n(18499),s=n(64431),l=n(57431),c=n(93608),d=n(31974),u=n(18829),p=n(54888),v=n(43723),m=n(14374),g=n(31209);const h={isOpen:!1,url:"",isRedirectToProfilePage:!1,closeable:!1,isBannerActive:!1,bannerEnabled:!1,content:{title:"",desc:"",btnOpenText:""},iframeStyle:{},handleDownload:o(),handleLogin:o(),closeCallback:o(),loginModalShow:!1,maskCloseable:!1,userId:"",groupId:"",enterMethod:void 0,pageType:5,modalType:"",hasCheckedPeriodicLogin:!1,hasCheckedPredictionLogin:!1,hasCheckedGuestMode:!1,showLoginOnLoad:!1,isLoginOnLoadClosed:!1,redirectToHomePage:!1,isGuestMode:!1,isGuestModeUI:!1};function _(){return-1!==(window.location.pathname+window.location.search).indexOf("recharge")}function f(e){if(e)return["click_like","click_comment","click_follow","share_button","click_like_comment","click_reply_comment","click_dislike","click_favorite"].includes(e)?"engagement":"default"}const y=(0,m._)((0,v.p)("loginAtom@tiktok/webapp-atoms",h),{rehydrationKey:"webapp.login"});let b;const{useAtomService:w,useServiceState:x,useServiceDispatchers:T,getStaticApi:k}=(0,g.i)(y,((e,t)=>({setCloseable(e){t(y,(t=>Object.assign(Object.assign({},t),{closeable:e})))},setUrl(e){t(y,(t=>Object.assign(Object.assign({},t),{url:e})))},setLoginPath(e){t(y,(t=>Object.assign(Object.assign({},t),{loginPath:e})))},setCloseCallback(e){e&&t(y,(t=>Object.assign(Object.assign({},t),{closeCallback:e})))},setIsOpen(e){t(y,(t=>Object.assign(Object.assign({},t),{isOpen:e})))},setContent(e){e&&t(y,(t=>Object.assign(Object.assign({},t),{content:e})))},setHandleDownload(e){e&&t(y,(t=>Object.assign(Object.assign({},t),{handleDownload:e})))},setHandleLogin(e){e&&t(y,(t=>Object.assign(Object.assign({},t),{handleLogin:e})))},setIframeStyle(e){t(y,(t=>Object.assign(Object.assign({},t),{iframeStyle:e})))},setModalType(e){t(y,(t=>Object.assign(Object.assign({},t),{modalType:e})))},setLoginModalShow(e){var n,i;if(t(y,(t=>Object.assign(Object.assign({},t),{loginModalShow:e}))),!e&&window.byted_acrawler){const{vgeo:e}=(0,s.c)();null===(i=(n=window.byted_acrawler).setUserMode)||void 0===i||i.call(n,(0,u.n)({isVA:"VGeo-US"===e,isLogin:!1,isFTC:!1,isHighRisk:!1}))}},setMaskCloseable(e){t(y,(t=>Object.assign(Object.assign({},t),{maskCloseable:e})))},setPageType(e){t(y,(t=>Object.assign(Object.assign({},t),{pageType:e})))},setUserId(e){t(y,(t=>Object.assign(Object.assign({},t),{userId:e})))},setGroupId(e){t(y,(t=>Object.assign(Object.assign({},t),{groupId:e})))},setLastGroupId(e){t(y,(t=>Object.assign(Object.assign({},t),{lastGroupId:e})))},setEnterMethod(e){t(y,(t=>Object.assign(Object.assign({},t),{enterMethod:e})))},setModalImage(e){t(y,(t=>Object.assign(Object.assign({},t),{modalImage:e})))},setPopupType(e){t(y,(t=>Object.assign(Object.assign({},t),{popupType:e})))},setIsRedirectToProfilePage(e){t(y,(t=>Object.assign(Object.assign({},t),{isRedirectToProfilePage:e})))},setIsGuestMode(e){t(y,(t=>Object.assign(Object.assign({},t),{isGuestMode:e})))},setIsGuestModeUI(e){t(y,(t=>Object.assign(Object.assign({},t),{isGuestModeUI:e})))},setPredictionPayload(e){t(y,(t=>Object.assign(Object.assign({},t),{predictionPayload:e})))},setIsLinkPhoneOrEmail(e){t(y,(t=>Object.assign(Object.assign({},t),{isLinkPhoneOrEmail:e})))},openModal(n){var i,o;const{url:s,isRedirectToProfilePage:d=!1,loginPath:u,isSignup:v,closeable:m=!0,query:g={},iframeStyle:h={},content:b,handleDownload:w,handleLogin:x,closeCallback:T,maskCloseable:k=!1,userId:S,enterMethod:E,bizActionSource:A,pageType:O=999,popupType:P,groupId:I,lastGroupId:C,isGuestMode:L,isGuestModeUI:j,predictionPayload:M,isLinkPhoneOrEmail:N}=n,{language:D}=(0,l.x)(),{bizContext:R}=e(p.A),B=null!=u?u:"/"+(v?"signup":"login"),U=null!=s?s:(0,a.stringifyUrl)({url:B,query:Object.assign({lang:D,is_modal:1,hide_close_btn:1,event_name:v?"enter_sign_up":null,type:_()?"recharge":"",enter_from:c.f.commonParams.page_name},g)},{skipNull:!0}),F=null!=E?E:g.enter_method,V=null!=I?I:g.group_id,z=null!=C?C:g.last_group_id,H=null!==(o=null!==(i=g.type)&&void 0!==i?i:_()?"recharge":"")&&void 0!==o?o:"";U.match(/\/login|\/signup|\/link-phone-or-email/)&&!(null==R?void 0:R.isMobile)?(0,r.unstable_batchedUpdates)((()=>{t(y,(e=>Object.assign(Object.assign({},e),{url:U,isRedirectToProfilePage:d,modalType:H,closeable:m,popupType:P,enterMethod:F,modalImage:f(F),closeCallback:null!=T?T:e.closeCallback,groupId:V,lastGroupId:z,isGuestMode:null!=L&&L,isGuestModeUI:null!=j&&j,predictionPayload:null!=M?M:"",isLinkPhoneOrEmail:null!=N&&N,bizActionSource:A}))),this.setLoginModalShow(!0)})):t(y,(e=>Object.assign(Object.assign({},e),{url:U,isRedirectToProfilePage:d,closeable:m,isOpen:!0,content:null!=b?b:e.content,handleDownload:null!=w?w:e.handleDownload,handleLogin:null!=x?x:e.handleLogin,iframeStyle:h,maskCloseable:k,closeCallback:null!=T?T:e.closeCallback,userId:S,enterMethod:F,pageType:O,popupType:P,groupId:V,lastGroupId:z,isLinkPhoneOrEmail:null!=N&&N,bizActionSource:A})))},setCheckPeriodicLogin(e){t(y,(e=>Object.assign(Object.assign({},e),{hasCheckedPeriodicLogin:!0}))),t(y,(t=>Object.assign(Object.assign({},t),{showLoginOnLoad:t.showLoginOnLoad||e.showLoginOnLoad})))},setCheckPredictionLogin(e){t(y,(e=>Object.assign(Object.assign({},e),{hasCheckedPredictionLogin:!0}))),t(y,(t=>Object.assign(Object.assign({},t),{showLoginOnLoad:t.showLoginOnLoad||e.showLoginOnLoad})))},setCheckGuestModeLogin(e){t(y,(e=>Object.assign(Object.assign({},e),{hasCheckedGuestMode:!0}))),t(y,(t=>Object.assign(Object.assign({},t),{showLoginOnLoad:t.showLoginOnLoad||e.showLoginOnLoad})))},setIsLoginOnLoadClosed(e){t(y,(t=>Object.assign(Object.assign({},t),{isLoginOnLoadClosed:e.isLoginOnLoadClosed})))},setClearShowLoginOnLoad(){t(y,(e=>Object.assign(Object.assign({},e),{hasCheckedPeriodicLogin:!1}))),t(y,(e=>Object.assign(Object.assign({},e),{hasCheckedPredictionLogin:!1}))),t(y,(e=>Object.assign(Object.assign({},e),{showLoginOnLoad:!1})))},closeModal(n){const{enter_method:i,disableReport:a}=n;if(a)return;b||(b=d.$F.getInstance()),b.loginNotifyClose({enter_method:i});const{closeCallback:r=o()}=e(y);r(),t(y,(e=>Object.assign(Object.assign({},e),{isOpen:!1,url:"",groupId:void 0})))},setIsBannerActive(e){t(y,(t=>Object.assign(Object.assign({},t),{isBannerActive:e})))}})))},10287:(e,t,n)=>{"use strict";n.d(t,{xt:()=>N,SE:()=>j,TP:()=>L});var i=n(70952),o=n.n(i);const a=["like","favorite","click_comment","post_comment","follow","share","download","head","finish","cover","repost"],r=["play","pause","wait","unmount"];var s,l;(l=s||(s={})).Interested="i",l.NotInterested="n",l.Neutral="v";const c="nb_classifier",d=["k_fyp","k_foryou","k_foryoupage","k_parati","k_fy","k_fypage","k_foryourpage","k_fpy","k_4u","k_fouryou","k_fypviral","k_fouryoupage","k_for","k_foru","k_fup","k_typ","k_4upage","k_viral","k_viralvideo","k_viraltiktok","k_goviral","k_videoviral","k_tiktokviral","k_viralvideos","k_viral_video","k_popular","k_trending","k_trendingvideo","k_new","k_trendingtiktok","k_tiktok","k_tiktokviral","k_vairal","k_trend","k_explore","k_explorepage","k_video"];var u=n(21578),p=n(71828);const v=/[^\s#]+#|#[^\s#]+/g,m=(e,t=!1,n=!1)=>{const i=((e,t=!1,n=!1)=>{const i=(e=>{var t;if(!e.textExtra)return[...new Set(null===(t=e.desc.match(v))||void 0===t?void 0:t.map((e=>e.replace("#","").toLowerCase())))].filter(Boolean).map((e=>`k_${e}`));const{textExtra:n}=e;return n.map((e=>{var t,n;return null===(n=null===(t=e.hashtagName)||void 0===t?void 0:t.toLowerCase())||void 0===n?void 0:n.trim()})).filter(Boolean).map((e=>`k_${e}`))})(e),o=(e=>{const t=e.music;if(!t)return;const{id:n,private:i,original:o}=t;return!n||i||o?void 0:`m_${n}`})(e),a=t?(e=>{const{duration:t}=e.video;return t>0&&t<=7?"d_0-7":t>7&&t<=10?"d_7-10":t>10&&t<=12?"d_10-12":t>12&&t<=14?"d_12-14":t>14&&t<=16?"d_14-16":t>16&&t<=20?"d_16-20":t>20&&t<=26?"d_20-26":t>26&&t<=36?"d_26-36":t>36&&t<=51?"d_36-51":t>51&&t<=62?"d_51-62":t>62&&t<=88?"d_62-88":t>88&&t<=143?"d_88-143":t>143?"d_>143":void 0})(e):(e=>{const{duration:t}=e.video;return t>0&&t<=12?"d_0-12":t>12&&t<=23?"d_12-23":t>23&&t<=60?"d_23-60":t>60?"d_>60":void 0})(e),r=(e=>{var t;const{desc:n,textExtra:i}=e;if(!n)return;if(!i)return(0,u.o0)(n);const o=null===(t=[...i].sort(((e,t)=>e.start-t.start)).filter((e=>e.hashtagId))[0])||void 0===t?void 0:t.start,a=n.substring(0,o);return a?(0,u.o0)(a):(0,u.o0)(n)})(e),s=[...i,`h_${(new Date).getHours()}`];return o&&s.push(o),a&&s.push(a),r&&s.push(`l_${r}`),n&&e.diversificationId&&s.push(`c_${e.diversificationId}`),s})(e,t,n),o=e.authorId;return o&&i.push(`a_${o}`),i};var g=n(14374),h=n(31209),_=n(43723),f=n(2408),y=n(57431),b=n(83663),w=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};function x(){return w(this,void 0,void 0,(function*(){return yield(0,b.P2)("nb",1,{upgrade(e){e.createObjectStore(c,{keyPath:"id"})}})}))}function T(e){return w(this,void 0,void 0,(function*(){const{id:t,classifier:n,db:i}=e;try{yield i.put(c,{id:t,classifier:n}),p.F.handleStorageWrite({is_success:1})}catch(e){throw p.F.handleStorageWrite({is_success:0,fail_error_msg:`${e}`}),e}}))}var k=n(93608),S=n(71281);const E=(e,t)=>!/^(m_|a_|k_)/.test(e)||/^(k_fyp|k_parati|k_fy)/.test(e)||d.includes(e)||1===e.length||-1!==e.indexOf(t);var A=n(58305),O=n(40040),P=n(84908),I=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const C=(0,g._)((0,_.p)("mlModelAtom@tiktok/webapp-atoms",{uid:"",item:void 0,classifier:void 0,play_time:0,show_interested:-1,docBuffer:[],is_preview:!1,finish_play:!1,suggestedItemList:[],isSuggestedItemListReady:!("undefined"!=typeof window&&(null===window||void 0===window?void 0:window.indexedDB)),isMlModelReady:!1}),{rehydrationKey:"webapp.mlModel"}),{useAtomService:L,useServiceDispatchers:j,useServiceState:M,getStaticApi:N}=(0,h.i)(C,((e,t)=>({initMlModel(){var n,i,a,r,s;return I(this,void 0,void 0,(function*(){if("undefined"==typeof window||!(null===window||void 0===window?void 0:window.indexedDB))return void p.F.handleStorageLoad({is_success:0,fail_error_msg:"no indexedDB"});const{user:l,odinId:d}=(0,y.x)(),u=null!==(i=null!==(n=null==l?void 0:l.uid)&&void 0!==n?n:d)&&void 0!==i?i:"",v=null!==(a=null==l?void 0:l.secUid)&&void 0!==a?a:"",m=null!==(r=(0,S.d)("enable_ml_model"))&&void 0!==r?r:"v1",g="v0"!==(null!==(s=(0,S.d)("enable_ml_model_suggest_content"))&&void 0!==s?s:"v0"),h=e(f.WH);if("v1"===m||l&&!l.hasIMPermission||(0,f.PJ)(h))p.F.handleStorageLoad({is_success:0,fail_error_msg:"no allowed"});else try{const e=yield x(),{classifier:n}=(yield function(e){var t;return w(this,void 0,void 0,(function*(){const{uid:n,db:i,secUid:o}=e;try{const e=yield i.get(c,n);if(!e&&o){const{classifier:e}=null!==(t=yield i.get(c,o))&&void 0!==t?t:{};e&&(yield T({db:i,id:n,classifier:e}),yield i.delete(c,o))}return p.F.handleStorageLoad({is_success:1}),e}catch(e){throw p.F.handleStorageLoad({is_success:0,fail_error_msg:`${e}`}),e}}))}({db:e,uid:u,secUid:v}))||{},i=new(o());n&&i.restore(n),t(C,(e=>Object.assign(Object.assign({},e),{uid:u,secUid:v,classifier:i,isSuggestedItemListReady:!g,isMlModelReady:!0})))}catch(e){throw p.F.handleStorageLoad({is_success:0,fail_error_msg:`${e}`}),e}}))},trainAndUpdateClassifier(){return I(this,void 0,void 0,(function*(){const{docBuffer:n,classifier:i,uid:o}=e(C);if(n.length<3&&i||!i)return;const a=yield x();try{const e=(e=>{const{documents:t=[],classifier:n,maxDocsCount:i=4e3,evictDocsCount:o=1e3}=e;if(0===t.length)return n;const a=[],r=[];t.forEach((({id:e,action:t})=>{a.push(t),r.push(e)}));const s={video_interactions:a.join(","),interaction_video_ids:r.join(",")};try{p.F.handleTrainRequest(s),t.forEach((({value:e,label:t})=>{n.addDocument(e,t)}));const{docs:e}=n;let a=!1;if(e.length>i){const t=e.slice(e.length-i+o);for(const{label:e,value:i}of t)n.addDocument(i,e);a=!0}n.train(),p.F.handleTrainReturn(Object.assign({is_success:1,is_slicing:a?1:0,docs_count:n.docs.length},s))}catch(e){p.F.handleTrainReturn(Object.assign({is_success:0,fail_error_msg:e.message},s)),console.error(`${e.message} - ${e.stack}`)}return n})({documents:n,classifier:i});yield T({db:a,classifier:e,id:o}),t(C,(t=>Object.assign(Object.assign({},t),{classifier:e,docBuffer:[]})))}catch(e){}}))},addTrainData(n){var i,o,l;return I(this,void 0,void 0,(function*(){const c=e(C),{classifier:d}=c;if(!d)return;const{item:u,action:p,isPreview:v}=n;if(!u||u.video.id===(null===(i=c.item)||void 0===i?void 0:i.video.id)&&c.finish_play&&"finish"===p)return;if("play"===p){if(u.video.id===(null===(o=c.item)||void 0===o?void 0:o.video.id))return void t(C,(e=>Object.assign(Object.assign({},e),{startPlayTimestamp:Date.now(),is_preview:!!v})));const e={item:u,finish_play:!1,show_interested:-1,play_time:0,is_preview:!!v,startPlayTimestamp:Date.now()};if(c.item&&!c.is_preview&&-1===c.show_interested){const t=c.item.video.duration<=5||c.item.video.duration>5&&c.play_time<5e3;e.docBuffer=[...c.docBuffer,{id:c.item.video.id,action:t?"skip":"play",value:m(c.item),label:t?s.NotInterested:s.Neutral}]}return t(C,(t=>Object.assign(Object.assign({},t),e))),void(yield this.trainAndUpdateClassifier())}if(r.includes(p)){const e=c.play_time+(c.startPlayTimestamp?Date.now()-c.startPlayTimestamp:0);return void t(C,(t=>Object.assign(Object.assign({},t),{play_time:e})))}const g={},h=m(u),_=a.includes(p)?1:0;g.docBuffer=[...c.docBuffer,{id:u.video.id,action:p,value:h,label:_?s.Interested:s.NotInterested}],u.video.id===(null===(l=c.item)||void 0===l?void 0:l.video.id)&&(g.show_interested=_),"finish"===p&&(g.finish_play=!0),t(C,(e=>Object.assign(Object.assign({},e),g))),yield this.trainAndUpdateClassifier()}))},getSuggestedForyouList(){var n;return I(this,void 0,void 0,(function*(){const{classifier:i,uid:o}=e(C),a="1"===(0,A._S)(O.Is);if(!i||!a&&!o)return void t(C,(e=>Object.assign(Object.assign({},e),{isSuggestedItemListReady:!0})));const r=((e,t)=>{var n;let i=0;const o=[],{docs:a}=e,r=new Set,s=1e4,{author:l=s}=null!==(n=(0,S.d)("ml_model_suggest_content_threshold"))&&void 0!==n?n:{};for(let e=0;e{var n,i,o,a,r,s,l,d,u,p,v,m,g,h,_,f;const y=null!==(i=null===(n=c.i)||void 0===n?void 0:n[e[0]])&&void 0!==i?i:0,b=null!==(a=null===(o=c.i)||void 0===o?void 0:o[t[0]])&&void 0!==a?a:0;if(y!==b)return b-y;const w=(null!==(s=null===(r=c.i)||void 0===r?void 0:r[e[0]])&&void 0!==s?s:0)+(null!==(d=null===(l=c.v)||void 0===l?void 0:l[e[0]])&&void 0!==d?d:0)-(null!==(p=null===(u=c.n)||void 0===u?void 0:u[e[0]])&&void 0!==p?p:0),x=(null!==(m=null===(v=c.i)||void 0===v?void 0:v[t[0]])&&void 0!==m?m:0)+(null!==(h=null===(g=c.v)||void 0===g?void 0:g[t[0]])&&void 0!==h?h:0)-(null!==(f=null===(_=c.n)||void 0===_?void 0:_[t[0]])&&void 0!==f?f:0);return w!==x?x-w:t[0]-e[0]})),((e,t)=>{const n={i:{},v:{},n:{}},i={i:{},v:{},n:{}},o={i:{},v:{},n:{}},a={a_:n,k_:i,m_:o};e.forEach((([e,n])=>{var i,o,r,s,l,c,d,u,p;const v=a[n.substring(0,2)],m=(null!==(o=null===(i=t.i)||void 0===i?void 0:i[e])&&void 0!==o?o:1)-1,g=(null!==(s=null===(r=t.v)||void 0===r?void 0:r[e])&&void 0!==s?s:1)-1,h=(null!==(c=null===(l=t.n)||void 0===l?void 0:l[e])&&void 0!==c?c:1)-1;v.i[m]=(null!==(d=v.i[m])&&void 0!==d?d:0)+1,v.v[g]=(null!==(u=v.v[g])&&void 0!==u?u:0)+1,v.n[h]=(null!==(p=v.n[h])&&void 0!==p?p:0)+1})),k.f.sendEvent("frontend_rec_author_distribution",{distribution:JSON.stringify(n)}),k.f.sendEvent("frontend_rec_tag_distribution",{distribution:JSON.stringify(i)}),k.f.sendEvent("frontend_rec_music_distribution",{distribution:JSON.stringify(o)})})(o,c);const d=[];let u=0,p=0,v=0;return o.forEach((([e,t])=>{var n,i;const o=(null!==(i=null===(n=c.i)||void 0===n?void 0:n[e])&&void 0!==i?i:1)-1;t.startsWith("a_")&&(o>=l&&u<10&&(d.push(t),u++),o>=1&&p++,o>=2&&v++)})),p>=1&&k.f.sendEvent("frontend_rec_suggested_content_should_show",{threshold:1,count:p}),v>=1&&k.f.sendEvent("frontend_rec_suggested_content_should_show",{threshold:2,count:v}),d})(i,o);if(0===r.length)return void t(C,(e=>Object.assign(Object.assign({},e),{isSuggestedItemListReady:!0})));if("v0"===(null!==(n=(0,S.d)("enable_ml_model_suggest_content"))&&void 0!==n?n:"v0"))return;const s=(yield Promise.all(r.map((e=>I(this,void 0,void 0,(function*(){var t,n;const i=e.split("_").slice(-1)[0];if(e.startsWith("a_")){const e=yield(0,P.Gp)().getUserDetail({userId:i});if(0!==e.statusCode)return;return{type:"author",title:null!==(n=null===(t=e.userInfo)||void 0===t?void 0:t.user.uniqueId)&&void 0!==n?n:""}}})))))).filter((e=>!!e));k.f.sendEvent("frontend_rec_suggested_content",{items:JSON.stringify(s),count:s.length}),t(C,(e=>Object.assign(Object.assign({},e),{suggestedItemList:s,isSuggestedItemListReady:!0})))}))}})))},89558:(e,t,n)=>{"use strict";n.d(t,{Fc:()=>r,Lq:()=>s,MW:()=>a,W$:()=>i,eh:()=>o,oG:()=>l});const i="non_personalized_feeds_web",o="personalized_search_disabled_list",a="personalized_feed_disabled_list",r="personalized_feed_disabled_not_login",s="personalized_feed_ppf_disabled_list",l="webapp_popup_personalization_toast"},2408:(e,t,n)=>{"use strict";n.d(t,{HY:()=>g,JW:()=>h,PJ:()=>u,Qi:()=>_,WH:()=>m,nH:()=>f});var i=n(14374),o=n(31209),a=n(43723),r=n(57431),s=n(99374),l=n(88874),c=n(63615),d=n(97086);const u=e=>{const{isFeedPersonalized:t}=e;return!t},p={isSearchPersonalized:!0,isFeedPersonalized:!0,isSearchConfigInitialized:!1,isFeedConfigInitialized:!1,isManageModalOpen:!1,isExplanationModalOpen:!1,isShowingToast:!1},v={isSearchPersonalized:!1,isFeedPersonalized:!1,isSearchConfigInitialized:!1,isFeedConfigInitialized:!1,isManageModalOpen:!1,isExplanationModalOpen:!1,isShowingToast:!1},m=(0,i._)((0,a.p)("personalizationAtom@tiktok/webapp-atoms",(()=>{const e=function(){if((0,d.fU)())return"";const e=(0,l.YI)(c.Ow),{user:{uid:t=""}={}}=e||{};return t}();return(0,s.mx)(void 0,e)?v:p})()),{rehydrationKey:"webapp.personalization"}),{useAtomService:g,useServiceState:h,useServiceDispatchers:_,getStaticApi:f}=(0,o.i)(m,((e,t)=>({setIsShowingToast(e){t(m,(t=>Object.assign(Object.assign({},t),{isShowingToast:e})))},setIsManageModalOpen(e){t(m,(t=>Object.assign(Object.assign({},t),{isManageModalOpen:e})))},setIsExplanationModalOpen(e){t(m,(t=>Object.assign(Object.assign({},t),{isExplanationModalOpen:e})))},setIsSearchPersonalized(e){t(m,(t=>Object.assign(Object.assign({},t),{isSearchPersonalized:e})))},setIsFeedPersonalized(e){t(m,(t=>Object.assign(Object.assign({},t),{isFeedPersonalized:e})))},setSearchConfigInitialized(e){t(m,(t=>Object.assign(Object.assign({},t),{isSearchConfigInitialized:e})))},setFeedConfigInitialized(e){t(m,(t=>Object.assign(Object.assign({},t),{isFeedConfigInitialized:e})))},init(n){var i,o,a,l,c,d;return a=this,l=void 0,d=function*(){const{isFeed:a}=n,l=(0,r.x)(),{isSearchConfigInitialized:c,isFeedConfigInitialized:d}=e(m);if(c&&!a||d&&a)return;const u=null!==(o=null===(i=l.user)||void 0===i?void 0:i.uid)&&void 0!==o?o:"",p=(0,s.eI)(u,a);t(m,a?e=>Object.assign(Object.assign({},e),{isFeedPersonalized:!p,isFeedConfigInitialized:!0}):e=>Object.assign(Object.assign({},e),{isSearchPersonalized:!p,isSearchConfigInitialized:!0}))},new((c=void 0)||(c=Promise))((function(e,t){function n(e){try{o(d.next(e))}catch(e){t(e)}}function i(e){try{o(d.throw(e))}catch(e){t(e)}}function o(t){var o;t.done?e(t.value):(o=t.value,o instanceof c?o:new c((function(e){e(o)}))).then(n,i)}o((d=d.apply(a,l||[])).next())}))}})))},99374:(e,t,n)=>{"use strict";n.d(t,{Sw:()=>s,eI:()=>a,i1:()=>r,mx:()=>l});var i=n(35267),o=n(89558);const a=(e,t,n,a)=>{if(!e)return!!t&&"1"===(0,i.MJ)(o.Fc);const r=a?o.Lq:t?o.MW:o.eh,s=(0,i.MJ)(r);if(s)try{const t=n?decodeURIComponent(s):s;return JSON.parse(t).includes(e)}catch(e){return console.warn("getIsNonPersonalized get JSON failed"),!1}return!1},r=(e,t)=>((e,t)=>{var n;let i=!1;if(e){const e=null!==(n=null==t?void 0:t.uid)&&void 0!==n?n:"";i=a(e,!0,!0)}return i})("v2"===t,e),s=(e="")=>a(e,void 0,void 0,!0),l=(e,t="")=>{var n;const i="v2"===(null===(n=null==e?void 0:e.parameters[o.W$])||void 0===n?void 0:n.vid),r=s(t);let l=!1;return(i||r)&&(l=a(t,!0,!1)),l}},92651:(e,t,n)=>{"use strict";var i;n.d(t,{L:()=>i,z:()=>o}),function(e){e[e.Low=0]="Low",e[e.Medium=1]="Medium",e[e.High=2]="High"}(i||(i={}));const o={hardware_score_avg:{levels:[{threshold:6.5,target:i.Low},{threshold:7.6,target:i.Medium},{threshold:10,target:i.High}],default:{threshold:10,target:i.High}},network_score_avg:{levels:[{threshold:6,target:i.Low},{threshold:8.5,target:i.Medium},{threshold:10,target:i.High}],default:{threshold:10,target:i.High}}}},36272:(e,t,n)=>{"use strict";n.d(t,{tR:()=>w,u4:()=>y,BX:()=>b});var i=n(14374),o=n(31209),a=n(43723),r=n(54888),s=n(93608);var l=n(14974),c=n.n(l),d=n(57431),u=n(60484),p=n(4474),v=n(92651);const m=({currentPortraitValue:e,portraitStrategy:t,defaultStrategy:n,enable:i,portraitKey:o})=>{var a;const r=null===(a=(0,p.parse)(location.search))||void 0===a?void 0:a[o];if(!r&&(!i||!e||isNaN(e)))return n;const s=r?Number(r):e,{levels:l=[]}=(0,u.L$)(t);for(let e=0;eNumber(s))return t}return n},g=(e,t)=>{const n={target:v.L.High},{target:i}=m({currentPortraitValue:Number(null!=e?e:0),portraitStrategy:v.z[t],defaultStrategy:n,enable:!0,portraitKey:t});return i},h={rawValue:"0",target:0,type:"device"},_=(0,i._)((0,a.p)("portraitHubAtom@tiktok/webapp-atoms",{vv_avg_per_day:h,ff_duration_avg:h,network_score_avg:h,hardware_score_avg:h}),{rehydrationKey:"webapp.portraitHub"}),{useAtomService:f,useServiceDispatchers:y,useServiceState:b,getStaticApi:w}=(0,o.i)(_,((e,t)=>({initPortraitHub(){var n;const{bizContext:i}=e(r.A),{vv_avg_per_day:o,ff_duration_avg:a,network_score_avg:l,hardware_score_avg:u}=null!==(n=null==i?void 0:i.solariaPortrait)&&void 0!==n?n:{},p=(e=>{var t,n,i,o,a;const{abTestVersion:r}=(0,d.x)(),s=null!==(i=null===(n=null===(t=null==r?void 0:r.parameters)||void 0===t?void 0:t.vv_avg_per_day_portrait)||void 0===n?void 0:n.vid)&&void 0!==i?i:{vid:"v0"},l=null===(o=null==r?void 0:r.parameters.change_list_length_new)||void 0===o?void 0:o.vid,c="v0"!==(null!==(a=null==s?void 0:s.vid)&&void 0!==a?a:"v0"),u={target:Number(l)},{target:p}=m({currentPortraitValue:Number(null!=e?e:0),portraitStrategy:s,defaultStrategy:u,enable:c,portraitKey:"vv_avg_per_day"});return p})(o),h=(e=>{var t,n,i,o;const{abTestVersion:a}=(0,d.x)(),r=null!==(i=null===(n=null===(t=null==a?void 0:a.parameters)||void 0===t?void 0:t.ff_avg_duration_portrait)||void 0===n?void 0:n.vid)&&void 0!==i?i:{vid:"v0"},s="v0"!==(null!==(o=null==r?void 0:r.vid)&&void 0!==o?o:"v0"),l={target:v.L.High},{target:c}=m({currentPortraitValue:Number(null!=e?e:0),portraitStrategy:r,defaultStrategy:l,enable:s,portraitKey:"ff_duration_avg"});return c})(a),f={vv_avg_per_day:{rawValue:o,target:p,type:"user"},ff_duration_avg:{rawValue:a,target:h,type:"device"},network_score_avg:{rawValue:l,target:g(l,"network_score_avg"),type:"device"},hardware_score_avg:{rawValue:u,target:g(u,"hardware_score_avg"),type:"device"}};t(_,(e=>Object.assign(Object.assign({},e),f)));const y=(e=>{var t,n,i,o,a,r,s,l;const c=Object.keys(e),{webIdCreatedTime:u=0}=(0,d.x)(),p=Date.now()/1e3-u<86400;let v=0,m=0,g=0;for(let t=0;tNumber(e)));s.f.config({commonHeaderConfig:{"header.custom":Object.assign({},w)}})},getPortraitTarget:t=>e(_)[t].target})))},44841:(e,t,n)=>{"use strict";n.d(t,{i:()=>i});const i={[-1]:-1,0:0,1:1,2:2,4:3}},84908:(e,t,n)=>{"use strict";n.d(t,{Gp:()=>S,JY:()=>k,eI:()=>E,nW:()=>A,p9:()=>T});var i=n(11983),o=n(37745),a=n(22248),r=n(14374),s=n(31209),l=n(43723),c=n(97792),d=n(8046),u=n(69589),p=n(40046),v=n(44841),m=n(97487),g=n(56070),h=n(26325),_=n(39785),f=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const y=(0,_.M)({csr:function(e){return f(this,void 0,void 0,(function*(){return(0,m.Ni)("userDetail")||g.h.get("/api/user/detail/",{query:e,baseUrlType:2})}))}});var b=n(79123),w=n(41548),x=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const T=(0,r._)((0,l.p)("userAtom@tiktok/webapp-atoms",{users:{},stats:{}}),{rehydrationKey:"webapp.user"}),{useAtomService:k,getStaticApi:S,useServiceDispatchers:E,useServiceState:A}=(0,s.i)(T,((e,t)=>({multiSetUser(n){const i=e(T),o={};n.forEach((e=>{o[e.uniqueId]=(0,b.HF)(i.users[e.uniqueId],e)})),t(T,Object.assign(Object.assign({},i),{users:Object.assign(Object.assign({},i.users),o)}))},setUser(e,n=!0){t(T,(t=>Object.assign(Object.assign({},t),{users:Object.assign(Object.assign({},t.users),{[e.uniqueId]:(0,b.HF)(t.users[e.uniqueId],e,n)})})))},setUserRelation({uniqueId:n,relation:i,shouldUpdateFollowed:a,shouldUpdateFollower:r}){var s;const l=e(T),c=l.users[n];if(!c)return;const d=Object.assign(Object.assign({},c),{relation:i});a&&(d.extraInfo=Object.assign(Object.assign({},d.extraInfo),{followed:(0,o.z)(i,null===(s=d.extraInfo)||void 0===s?void 0:s.followed)})),r&&(d.extraInfo=Object.assign(Object.assign({},d.extraInfo),{followerStatus:(0,o.L)(i)})),t(T,Object.assign(Object.assign({},l),{users:Object.assign(Object.assign({},l.users),{[n]:d})}))},setUserStats(e){const{uniqueId:n,stats:i}=e;t(T,(e=>Object.assign(Object.assign({},e),{stats:Object.assign(Object.assign({},e.stats),{[n]:i})})))},multiSetUserStats(n){const i=e(T),o=n.reduce(((e,t)=>(e[t.uniqueId]=t.stats,e)),Object.assign({},i.stats));t(T,Object.assign(Object.assign({},i),{stats:o}))},getUserDetail(e){return x(this,void 0,void 0,(function*(){try{const t=yield y(e);return 0!==t.statusCode&&10222!==t.statusCode||!t.userInfo?console.warn("Get user detail failed for getting wrong response"):(this.setUser(Object.assign(Object.assign({uniqueIdModifyTime:0},t.userInfo.user),{extraInfo:{statusCode:t.statusCode}})),this.setUserStats({stats:Object.assign(Object.assign({},t.userInfo.stats),{needFix:!1}),uniqueId:t.userInfo.user.uniqueId})),t}catch(e){return{statusCode:-1}}}))},postCommitFollowUser(t){return x(this,void 0,void 0,(function*(){try{const n=e(T).users[t.uniqueId];if(!n)return;const o=(0,w.T)(),{id:r,secUid:s="",relation:l=-1}=n,m=(0,b.gN)(l),_={type:1===m?1:0,action_type:1===m?1:0,user_id:r,sec_user_id:s,from:18,channel_id:0,from_pre:0},{uniqueId:y,useFollowV2:x,resetWebappQuery:k,group_id:S,enter_method:E="click_direct_btn",action_position:A}=t,O=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o{"use strict";n.d(t,{A7:()=>f,HF:()=>h,gN:()=>y});var i,o=n(37745),a=n(79479),r=n.n(a),s=n(98885),l=n.n(s),c=n(6226),d=n.n(c);!function(e){e[e.FollowNormal=0]="FollowNormal",e[e.FollowPrivate=1]="FollowPrivate",e[e.FollowFollower=2]="FollowFollower",e[e.Unfollow=3]="Unfollow"}(i||(i={}));const u=["roomId"],p=["uniqueId","avatarThumb","avatarMedium","avatarLarger","nickname","signature"],v="uniqueIdModifyTime",m="nickNameModifyTime",g="ttSeller";function h(e,t,n){var i,a;if(!e)return t;const s=null!==(i=t.relation)&&void 0!==i?i:e.relation,c=d()({},e,t,{extraInfo:{followed:(0,o.z)(s,null===(a=e.extraInfo)||void 0===a?void 0:a.followed)}},((e,t,i)=>"canExpPlaylist"===i?e||t:!u.includes(i)&&l()(t)?e:(n||!p.includes(i)||r()(e)&&!r()(t))&&(i!==v&&i!==g&&i!==m||t)?void 0:e));return n&&void 0===t.roomId&&c.roomId&&(c.roomId=void 0),c}function _({relation:e,handleIsUnfollow:t,handleIsFollow:n}){switch(e){case 0:case-1:case 4:case 5:case 6:return t();default:return n()}}function f({current:e,targetUser:t}){const n=function(e){var t;return _({relation:null!==(t=e.relation)&&void 0!==t?t:-1,handleIsUnfollow:()=>{var t;return e.privateAccount?1:(null===(t=e.extraInfo)||void 0===t?void 0:t.followed)||6===e.relation?2:0},handleIsFollow:()=>3})}(t);switch(n){case 3:return 0;case 0:return _({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>1});case 1:return _({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>3});case 2:return _({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>2});default:return _({relation:e,handleIsFollow:()=>e,handleIsUnfollow:()=>-1})}}function y(e){return _({relation:e,handleIsUnfollow:()=>1,handleIsFollow:()=>0})}},41548:(e,t,n)=>{"use strict";n.d(t,{T:()=>o});var i=n(77966);const o=(0,n(39785).M)({csr:()=>i.Ay.t})},38771:(e,t,n)=>{"use strict";n.d(t,{Q3:()=>m,dv:()=>h,hy:()=>v,jD:()=>d,uI:()=>g});var i=n(14374),o=n(31209),a=n(32125),r=n(43723),s=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o({setVideoInfo(e){var{itemId:n}=e,i=s(e,["itemId"]);t(d,(e=>({[n]:Object.assign(Object.assign(Object.assign({},l),e[n]),i)})))},setPhotoInfo(e){var{itemId:n}=e,i=s(e,["itemId"]);t(d,(e=>({[n]:Object.assign(Object.assign(Object.assign({},c),e[n]),i)})))}}))),g=e=>p((t=>e in t&&t[e]&&"video"===t[e].contentType?t[e]:l),a.bN),h=e=>p((t=>e in t&&t[e]&&"photo"===t[e].contentType?t[e]:c),a.bN)},41735:(e,t,n)=>{"use strict";n.d(t,{Jw:()=>h,QH:()=>g,T8:()=>m,u7:()=>_});var i=n(57431),o=n(39785),a=n(56070),r=n(54888),s=n(43723),l=n(14374),c=n(31209),d=n(89049),u=n(68783),p=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const v=(0,o.M)({csr:e=>p(void 0,void 0,void 0,(function*(){return a.h.get("/api/challenge/item_list/",{query:e,baseUrlType:2})}))}),m=(0,l._)((0,s.p)("challengeListAtom@tiktok/webapp-atoms",d.hA),{rehydrationKey:"desktop.challengePage.challengeList"}),{useAtomService:g,useServiceDispatchers:h,useServiceState:_}=(0,c.i)(m,((e,t)=>({getChallengeList(n){var o;return p(this,void 0,void 0,(function*(){try{const{cursor:a="0"}=e(m),{challengeID:s}=n,{language:l}=(0,i.x)(),{bizContext:c}=e(r.A);t(m,(e=>Object.assign(Object.assign({},e),{loading:!0})));const p=yield v({challengeID:s,language:l,cursor:a,aid:d.xE,count:d.vu,coverFormat:null===(o=null==c?void 0:c.videoCoverSettings)||void 0===o?void 0:o.format});(0,u.Tj)(e,t,m,"challenge",p)}catch(e){(0,u.e_)(t,m)}}))},resetChallengeList(){t(m,d.hA)}})))},79217:(e,t,n)=>{"use strict";n.d(t,{WX:()=>g,ek:()=>v,lE:()=>h,pp:()=>m});var i=n(57431),o=n(39785),a=n(56070),r=n(43723),s=n(14374),l=n(31209),c=n(89049),d=n(68783),u=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const p=(0,o.M)({csr:e=>u(void 0,void 0,void 0,(function*(){return a.h.get("/api/collection/item_list/",{query:e,baseUrlType:2})}))}),v=(0,s._)((0,r.p)("collectionListAtom@tiktok/webapp-atoms",c.hA),{rehydrationKey:"desktop.collectionPage.collectionList"}),{useAtomService:m,useServiceDispatchers:g,useServiceState:h}=(0,l.i)(v,((e,t)=>({getCollectionList(n){return u(this,void 0,void 0,(function*(){try{const{collectionId:o}=n,a=e(v),{cursor:r="0"}=a,{language:s,abTestVersion:l}=(0,i.x)();t(v,(e=>Object.assign(Object.assign({},e),{loading:!0})));const u=yield p({collectionId:o,language:s,cursor:r,aid:c.xE,count:c.vu,sourceType:113,clientABVersions:null==l?void 0:l.versionName});(0,d.Tj)(e,t,v,"collection",u)}catch(e){(0,d.e_)(t,v)}}))},resetCollectionList(){t(v,Object.assign({},c.hA))},addItems(e,n){t(v,(t=>{const{list:i,browserList:o}=(0,d.kf)(t,e,{itemListKey:"collection",addToHead:n});return Object.assign(Object.assign({},t),{list:i,browserList:o})}))},deleteItems(e){(0,d.UJ)(t,v,e)}})))},89049:(e,t,n)=>{"use strict";n.d(t,{$H:()=>l,Bu:()=>s,HF:()=>d,Kq:()=>r,hA:()=>i,n9:()=>c,vu:()=>a,xE:()=>o});const i={statusCode:0,hasMore:!0,cursor:"0",loading:!0,preloadList:[],browserList:[],list:[],items:[]},o=1988,a=30,r=15,s="w_g_fyp_vv",l="w_g_vv",c="tiktok_webapp_theme_source",d="tiktok_webapp_theme_manual"},39415:(e,t,n)=>{"use strict";n.d(t,{BX:()=>v,DK:()=>u,ag:()=>m,sK:()=>p});var i=n(57431),o=n(56070),a=n(43723),r=n(14374),s=n(31209),l=n(89049),c=n(68783),d=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const u=(0,r._)((0,a.p)("creatorTabListAtom@tiktok/webapp-atoms",l.hA),{rehydrationKey:"desktop.creatorTabPage.creatorTabList"}),{useAtomService:p,useServiceDispatchers:v,useServiceState:m}=(0,s.i)(u,((e,t)=>({getCreatorTabList(n){return d(this,void 0,void 0,(function*(){try{const{secUid:a,createTime:r,fetchType:s}=n,{language:p}=(0,i.x)();t(u,(e=>Object.assign(Object.assign({},e),{loading:!0})));const v={aid:l.xE,count:l.Kq,cursor:String(r),secUid:a,type:s,language:p},m=yield(e=>d(void 0,void 0,void 0,(function*(){return o.h.get("/api/creator/item_list/",{query:e,baseUrlType:2})})))(v),g={secUid:a,addToHead:2===s};(0,c.Tj)(e,t,u,"creator_tab",m,g),t(u,(e=>{var t,n;return Object.assign(Object.assign({},e),{hasMorePrevious:null!==(t=m.hasMorePrevious)&&void 0!==t&&t,hasMoreLatest:null!==(n=m.hasMoreLatest)&&void 0!==n&&n})}))}catch(e){(0,c.e_)(t,u)}}))},resetCreatorTabList(){t(u,l.hA)}})))},68783:(e,t,n)=>{"use strict";n.d(t,{Qw:()=>b,bp:()=>T,e_:()=>S,Tj:()=>E,Fx:()=>A,UJ:()=>O,kf:()=>k,X9:()=>y,Jl:()=>w});var i=n(57431),o=n(45537),a=n.n(o),r=n(300),s=n.n(r),l=n(59952),c=n(84908),d=n(18499),u=n(60072),p=n(39785),v=n(57432),m=n.n(v),g=n(65852);const h=(0,p.M)({csr:m()});var _=n(93608);const f="live_",y=e=>!!e&&e.includes(f),b=e=>`${f}${e}`,w=e=>2===(null==e?void 0:e.containerType),x=e=>(null!=e?e:[]).filter((e=>2!==e.containerType)).map((e=>{var t,n,i,o;return{url:null!==(n=null===(t=e.video)||void 0===t?void 0:t.playAddr)&&void 0!==n?n:"",id:null!==(o=null===(i=e.video)||void 0===i?void 0:i.id)&&void 0!==o?o:""}})),T=({list:e})=>e.reduce(((e,{id:t,showNotPass:n,takeDown:i})=>(!n&&6!==i&&t&&e.push(t),e)),[]),k=(e,t,n)=>{const{itemListKey:i,addToHead:o}=n,{list:r,browserList:l}=e,c=s()(t,"id").filter((e=>!r.includes(e.id))),d="topic"===i||"messages"===i;if("foryou"===i){const e=t.length,n=e-c.length;n&&(u=n,p=r.length,v=e,_.f.event("recommend_duplicated_item",{count:u,total_count:p,response_count:v}))}var u,p,v;if(o)return{list:c.map((({id:e})=>e)).concat(r),browserList:[...T({list:c}),...l]};{const e=a()(r,c.map((({id:e})=>e)));return{list:d?r.concat(t.map((({id:e})=>e))):e,browserList:d?l.concat(T({list:t})):a()(l,T({list:t}))}}},S=(e,t)=>{e(t,(e=>Object.assign(Object.assign({},e),{loading:!1,statusCode:-1})))},E=(e,t,n,o,a,r)=>{var s,p,v,m;const _=e(n),{list:f,hasLocateItem:y}=_,{photoSensitiveVideosSetting:T}=e(l.x),{statusCode:S,hasMore:E=!0,itemList:A=[],cursor:O,log_pb:P,has_locate_item_id:I}=a,C=((e,t)=>{let n=(null!=e?e:[]).slice();const{user:o}=(0,i.x)(),{itemListKey:a,photoSensitiveVideosSetting:r,secUid:s}=t;return 1!==(null==o?void 0:o.photoSensitiveVideosSetting)&&(o||1!==r)||"user-post"===a&&(null==o?void 0:o.secUid)===s||!("video"!==a||n.length>1)||(n=n.filter((e=>2===e.containerType||4!==e.maskType))),n=n.map((e=>{var t;return w(e)&&(e.id=b(null===(t=e.liveRoomInfo)||void 0===t?void 0:t.roomID)),e})),n})(A,{itemListKey:o,photoSensitiveVideosSetting:T,secUid:null==r?void 0:r.secUid}),{list:L,browserList:j}=k(_,C,{itemListKey:o,addToHead:null==r?void 0:r.addToHead});(({currentList:e,itemList:t,statusCode:n,disableReportMore:i=!1,isPlayList:o=!1})=>{e.length&&!i&&g.L.handleListMore({is_success:t.length?1:0,error_code:n,popup_type:o?"playlist":void 0})})({currentList:f,itemList:C,statusCode:S,disableReportMore:null!==(s=null==r?void 0:r.disableReportMore)&&void 0!==s&&s,isPlayList:null!==(p=null==r?void 0:r.isPlayList)&&void 0!==p&&p}),h(null===(v=C[0])||void 0===v?void 0:v.video,o);const M=(e=>{const t=e.filter((e=>Boolean(e.author))).map((({author:e})=>e)),n=e.filter((e=>{var t;return Boolean(null===(t=e.liveRoomInfo)||void 0===t?void 0:t.ownerInfo)})).map((e=>Object.assign(Object.assign({},e.liveRoomInfo.ownerInfo),{roomId:e.liveRoomInfo.roomID})));return t.concat(n)})(C),N=((e,t)=>e.map((e=>Object.assign(Object.assign({},e),{logId:t}))))(C,null==P?void 0:P.impr_id),D={statusCode:S,hasMore:E,cursor:O,list:L,loading:!1,browserList:j,preloadList:[...null!==(m=_.preloadList)&&void 0!==m?m:[],...x(C)],items:N,hasLocateItem:!!y||I};(0,d.unstable_batchedUpdates)((()=>{(0,c.Gp)().multiSetUser(M),(0,u.ud)().multiSetItem(N),t(n,D)}))},A=(e,t,n)=>{e(t,(e=>Object.assign(Object.assign({},e),{list:e.list.filter((e=>e!==n)),browserList:e.browserList.filter((e=>e!==n))})))},O=(e,t,n)=>{const i=new Set(n);e(t,(e=>Object.assign(Object.assign({},e),{list:e.list.filter((e=>!i.has(e))),browserList:e.browserList.filter((e=>!i.has(e)))})))}},35043:(e,t,n)=>{"use strict";var i,o;n.d(t,{FB:()=>r,r8:()=>a}),function(e){e.ForYou="foryou",e.Challenge="challenge",e.ChallengeNew="challenge_new",e.Channel="channel",e.Find="find",e.Following="following",e.Video="video",e.Music="music",e.MusicNew="music_new",e.User="user",e.UserPost="user-post",e.UserPostPublic="user-post-public",e.UserRepost="user-repost",e.UserLiked="user-liked",e.SearchTop="search_top",e.SearchVideo="search_video",e.SearchLive="search_live",e.Question="question",e.Playlist="playlist",e.Topic="topic",e.LiveEvent="live_event",e.VideoPlaylist="video_playlist",e.CreateVideoPlaylist="create_video_playlist",e.Sticker="sticker",e.Effect="effect",e.Messages="messages",e.Discover="discover",e.Poi="poi",e.PoiCategory="poi_category",e.Collection="collection",e.Explore="explore",e.Favorites="favorites",e.KeywordExpansion="keyword-expansion",e.CreatorTab="creator_tab",e.Friends="friends",e.TrendingTopics="trending_topics"}(i||(i={})),function(e){e.HIGH="high",e.MEDIUM="medium",e.LOW="low"}(o||(o={}));const a={5:"foryou",11:"following",20:"friends",113:"topic",0:"video"},r={foryou:5,following:11,friends:20,topic:113,video:0,effect:129,user:1,"user-post":1,"user-post-public":1,"user-repost":1,"user-liked":1,explore:19,challenge:3,channel:122,collection:121,discover:103,find:124,live_event:114,messages:13,music:4,playlist:108,poi:18,poi_category:125,question:16,sticker:6}},72370:(e,t,n)=>{"use strict";n.d(t,{H:()=>i});const i=16},79995:(e,t,n)=>{"use strict";n.d(t,{IO:()=>m,Ql:()=>h,ZX:()=>g,dQ:()=>v});var i=n(57431),o=n(43723),a=n(14374),r=n(31209),s=n(89049),l=n(68783),c=n(51660),d=n(27666),u=n(72370),p=n(31241);const v=(0,a._)((0,o.p)("exploreListAtom@tiktok/webapp-atoms",s.hA),{rehydrationKey:"desktop.explorePage.exploreList"}),{useAtomService:m,useServiceDispatchers:g,useServiceState:h}=(0,r.i)(v,((e,t)=>({getExploreList(n){return o=this,a=void 0,m=function*(){try{const{categoryType:o}=n,{language:a,abTestVersion:r}=(0,i.x)();t(v,(e=>Object.assign(Object.assign({},e),{loading:!0})));const m=yield(0,d.e)({language:(0,c.uk)(a),aid:s.xE,count:u.H,categoryType:o,clientABVersions:null==r?void 0:r.versionName,isNonPersonalized:(0,p.X)()});(0,l.Tj)(e,t,v,"explore",m)}catch(e){(0,l.e_)(t,v)}},new((r=void 0)||(r=Promise))((function(e,t){function n(e){try{s(m.next(e))}catch(e){t(e)}}function i(e){try{s(m.throw(e))}catch(e){t(e)}}function s(t){var o;t.done?e(t.value):(o=t.value,o instanceof r?o:new r((function(e){e(o)}))).then(n,i)}s((m=m.apply(o,a||[])).next())}));var o,a,r,m},resetExploreList(){t(v,s.hA)}})))},27666:(e,t,n)=>{"use strict";n.d(t,{e:()=>s});var i=n(39785),o=n(68881),a=n(56070),r=n(46311);const s=(0,i.M)({csr:e=>{return t=void 0,n=void 0,s=function*(){const t=(0,o.DV)("exploreItemList");return t?(r.P.emit("consume_prefetch_data",performance.now(),"unknown","exploreItemList"),t.catch((()=>(r.P.emit("consume_prefetch_data",performance.now(),"fail","exploreItemList"),a.h.get("/api/explore/item_list/",{query:e,baseUrlType:2}))))):a.h.get("/api/explore/item_list/",{query:e,baseUrlType:2})},new((i=void 0)||(i=Promise))((function(e,o){function a(e){try{l(s.next(e))}catch(e){o(e)}}function r(e){try{l(s.throw(e))}catch(e){o(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof i?n:new i((function(e){e(n)}))).then(a,r)}l((s=s.apply(t,n||[])).next())}));var t,n,i,s}})},31241:(e,t,n)=>{"use strict";n.d(t,{X:()=>s});var i=n(57431),o=n(71281),a=n(97086),r=n(99374);const s=()=>{var e;const{user:t}=(0,i.x)();let n;switch((0,o.d)("pc_non_personalized_explore")){case"v0":n=!0;break;case"v1":n=(0,r.eI)(null!==(e=null==t?void 0:t.uid)&&void 0!==e?e:"",!0,(0,a.fU)())}return n}},61918:(e,t,n)=>{"use strict";n.d(t,{Cg:()=>u,D3:()=>s});var i=n(43723),o=n(14374),a=n(31209),r=n(89049);const s=(0,o._)((0,i.p)("messageListAtom@tiktok/webapp-atoms",r.hA),{rehydrationKey:"desktop.messagePage.messageList"}),{useAtomService:l,useServiceDispatchers:c,useServiceState:d,getStaticApi:u}=(0,a.i)(s,((e,t)=>({setItemListById(e){const{list:n,statusCode:i=0,hasMore:o=!0,cursor:a,level:r}=e;t(s,(e=>Object.assign(Object.assign({},e),{list:n,browserList:n,statusCode:i,hasMore:o,cursor:a,level:r})))},getBrowserList:()=>e(s).browserList})))},43227:(e,t,n)=>{"use strict";n.d(t,{Ag:()=>g,DC:()=>h,l6:()=>m,pT:()=>_});var i=n(57431),o=n(39785),a=n(56070),r=n(54888),s=n(43723),l=n(14374),c=n(31209),d=n(89049),u=n(68783),p=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const v=(0,o.M)({csr:e=>p(void 0,void 0,void 0,(function*(){return a.h.get("/api/music/item_list/",{query:e,baseUrlType:2})}))}),m=(0,l._)((0,s.p)("musicListAtom@tiktok/webapp-atoms",d.hA),{rehydrationKey:"desktop.musicPage.musicList"}),{useAtomService:g,useServiceDispatchers:h,useServiceState:_}=(0,c.i)(m,((e,t)=>({getMusicList(n){var o;return p(this,void 0,void 0,(function*(){const a=e(m);try{const{musicID:s}=n,{cursor:l="0"}=a,{language:c}=(0,i.x)(),{bizContext:p}=e(r.A);t(m,(e=>Object.assign(Object.assign({},e),{loading:!0})));const g=yield v({musicID:s,language:c,cursor:l,aid:d.xE,count:d.vu,coverFormat:null===(o=null==p?void 0:p.videoCoverSettings)||void 0===o?void 0:o.format});(0,u.Tj)(e,t,m,"music",g)}catch(e){(0,u.e_)(t,m)}}))},resetMusicList(){t(m,d.hA)}})))},29909:(e,t,n)=>{"use strict";n.d(t,{HG:()=>C,e4:()=>A,sL:()=>P,NY:()=>O,Lu:()=>I});var i=n(57431),o=n(51660),a=n(54888),r=n(97086),s=n(58305),l=n(97071),c=n(8046),d=n(14107),u=n(43723),p=n(14374),v=n(31209),m=n(35267),g=n(89049),h=n(68783),_=n(2408),f=n(79238),y=n(39785),b=n(68881),w=n(56070),x=n(46311),T=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const k=(0,y.M)({csr:e=>T(void 0,void 0,void 0,(function*(){const t=(0,b.t$)("recommendItemList");if(t)return t;const n=(0,b.DV)("recommendItemList");return n?(x.P.emit("consume_prefetch_data",performance.now(),"unknown","recommendItemList"),n.catch((()=>(x.P.emit("consume_prefetch_data",performance.now(),"fail","recommendItemList"),w.h.get("/api/recommend/item_list/",{query:e,baseUrlType:2}))))):w.h.get("/api/recommend/item_list/",{query:e,baseUrlType:2})}))});var S=n(96563),E=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const A=(0,p._)((0,u.p)("recommendListAtom@tiktok/webapp-atoms",g.hA),{rehydrationKey:"desktop.forYouPage.recommendList"}),{useAtomService:O,useServiceDispatchers:P,useServiceState:I,getStaticApi:C}=(0,v.i)(A,((e,t)=>({getRecommendList(n,u=!1){var p,v,y,b,x;return E(this,void 0,void 0,(function*(){const E=u?S.Hx:A,O=u?"video":"foryou";try{const S=e(E),{bizContext:A}=e(a.A),{language:I,abTestVersion:C}=(0,i.x)(),{itemId:L,watchLiveLastTime:j,device_type:M,fromPage:N,pullType:D=2,ttamParams:R={},isNonPersonalized:B=!1,playModeForTea:U="one_column",fypFeederItemId:F,fetchCount:V,enableCDNCache:z}=n,H=(0,r.fU)()?B:(0,_.PJ)(e(_.WH)),q=(0,o.uk)(I);let G=30;const $=null!=V?V:null===(p=null==C?void 0:C.parameters.change_list_length_new)||void 0===p?void 0:p.vid;$&&(G=Number($));const W=Object.assign(Object.assign({isNonPersonalized:H,aid:g.xE,count:1===D?9:G,insertedItemID:L,language:q,clientABVersions:null==C?void 0:C.versionName,pullType:D,watchLiveLastTime:j,device_type:M},R),{coverFormat:null===(v=null==A?void 0:A.videoCoverSettings)||void 0===v?void 0:v.format,itemID:F,vv_count_fyp:parseInt((0,s._S)(g.Bu,"0"),10)||0}),Z=function(e,t,n){var a,r,l;const{language:c="en",abTestVersion:d}=null!==(a=(0,i.x)())&&void 0!==a?a:{},{itemId:u,watchLiveLastTime:p,device_type:v,pullType:h=2,ttamParams:_={},fypFeederItemId:f,fetchCount:y,enableCDNCache:b}=e,w=(0,o.uk)(c);let x=30;const T=null!=y?y:null===(r=null==d?void 0:d.parameters.change_list_length_new)||void 0===r?void 0:r.vid;return T&&(x=Number(T)),Object.assign(Object.assign({isNonPersonalized:n,aid:g.xE,count:1===h?9:x,insertedItemID:u,language:w,clientABVersions:null==d?void 0:d.versionName,pullType:h,watchLiveLastTime:p,device_type:v},_),{coverFormat:null===(l=null==t?void 0:t.videoCoverSettings)||void 0===l?void 0:l.format,itemID:f,vv_count_fyp:parseInt((0,s._S)(g.Bu,"0"),10)||0,vv_count:parseInt((0,s._S)(g.$H,"0"),10)||0,cpu_core_number:"undefined"!=typeof navigator&&navigator.hardwareConcurrency?navigator.hardwareConcurrency:0,dark_mode:"dark"===(0,m.MJ)(g.n9)&&"1"===(0,m.MJ)(g.HF),time_of_day:(new Date).getHours(),day_of_week:(new Date).getDay(),enable_cache:Boolean(b),user_is_login:!b&&void 0})}(n,A,H);console.debug("[getRecommendList]","originParams",W,"expParams",Z,JSON.stringify(Z)===JSON.stringify(W));const Y="v2"!==(null===(b=null===(y=null==C?void 0:C.parameters)||void 0===y?void 0:y.foryou_prefetch)||void 0===b?void 0:b.vid)?W:Z;N&&Object.assign(Y,{from_page:N}),t(E,(e=>Object.assign(Object.assign({},e),{loading:!0})));const K=yield k(Y),X=function(e,t){const{adsOffset:n=0,itemList:i}=t,o=Number(n),a=null==i?void 0:i[o];if(!(null==a?void 0:a.isTT4BAds))return t;const r=o>=e?o-e:0;return null==i||i.splice(o,1),null==i||i.splice(r,0,a),t.itemList=i,t}(S.list.length,K),Q=null!==(x=X.itemList)&&void 0!==x?x:[];Q.forEach((e=>{var t;if(e.ad_info){const t=(0,l.n5)({ad_info:e.ad_info,play_mode:U});c.pg.handleReceive(t)}d.j.handleVideoReceive({item_id:e.id,group_id:null===(t=null==e?void 0:e.video)||void 0===t?void 0:t.id})})),u||t(f.R,X),(0,h.Tj)(e,t,E,O,X);try{z&&(P={aid:g.xE,language:q,itemIds:Q.map((e=>e.id)).join(","),clientABVersions:null==C?void 0:C.versionName,isNonPersonalized:H},T(void 0,void 0,void 0,(function*(){return w.h.get("/api/record/impression/action/",{query:P,baseUrlType:2})})))}catch(e){console.error("Record Impression Action failed in /api/recommend/item_list with CDN Cache",e)}}catch(e){(0,m.mH)().warn("getRecommendList err",e),(0,h.e_)(t,E)}var P}))},setDeleteVideo(e){(0,h.Fx)(t,A,e)},setListFromCache(n){(0,h.Tj)(e,t,A,"foryou",n,{disableReportMore:!0})},getFeedCacheList(){var t;return E(this,void 0,void 0,(function*(){try{const{bizContext:r}=e(a.A),{language:l,abTestVersion:c}=(0,i.x)(),d=(0,_.PJ)(e(_.WH)),u={count:3,language:(0,o.uk)(l),coverFormat:null===(t=null==r?void 0:r.videoCoverSettings)||void 0===t?void 0:t.format,isNonPersonalized:d,vv_count_fyp:parseInt((0,s._S)(g.Bu,"0"),10)||0,clientABVersions:null==c?void 0:c.versionName};return yield(n=u,T(void 0,void 0,void 0,(function*(){return w.h.get("/api/preload/item_list/",{query:n,baseUrlType:2})})))}catch(e){return null}var n}))},resetRecommendList(e){t(A,Object.assign(Object.assign({},g.hA),e))},setRecommendListById(e){const{list:n,browserList:i,preloadList:o}=e;t(A,(e=>Object.assign(Object.assign({},e),{list:n,browserList:null!=i?i:n,preloadList:o})))}})))},79238:(e,t,n)=>{"use strict";n.d(t,{R:()=>r,Z:()=>s});var i=n(14374),o=n(31209),a=n(43723);const r=(0,i._)((0,a.p)("recommendListResponseAtom@tiktok/webapp-atoms",{statusCode:0}),{rehydrationKey:"desktop.forYouPage.recommendListResponse"}),{useServiceState:s}=(0,o.i)(r,(()=>({})))},96563:(e,t,n)=>{"use strict";n.d(t,{AM:()=>_,Hx:()=>h,ND:()=>f,OU:()=>b,mY:()=>y});var i=n(51660),o=n(57431),a=n(56070),r=n(54888),s=n(43723),l=n(14374),c=n(31209),d=n(2408),u=n(89049),p=n(68783),v=n(34308),m=n(60072),g=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const h=(0,l._)((0,s.p)("relatedListAtom@tiktok/webapp-atoms",u.hA),{rehydrationKey:"desktop.videoPage.relatedList"}),{useAtomService:_,useServiceDispatchers:f,useServiceState:y,getStaticApi:b}=(0,c.i)(h,((e,t)=>({getRelatedList(n){var s,l,c,_,f,y;return g(this,void 0,void 0,(function*(){try{const{loading:w,hasMore:x,cursor:T="0"}=e(h);if(w)return;const{itemId:k,secUid:S}=n,{language:E,abTestVersion:A,user:O}=(0,o.x)(),{bizContext:P}=e(r.A),I=(0,i.uk)(E),C=null===(s=null==P?void 0:P.videoCoverSettings)||void 0===s?void 0:s.format,L=(0,d.PJ)(e(d.WH)),j=null!==(c=null===(l=e(m.Pu)[k])||void 0===l?void 0:l.CategoryType)&&void 0!==c?c:0,M=null!==(f=null===(_=null==A?void 0:A.parameters.video_detail_yml_creator)||void 0===_?void 0:_.vid)&&void 0!==f?f:"v0",N="v0"!==M&&!O,D="v2"===M;let R;t(h,(e=>Object.assign(Object.assign({},e),{loading:!0}))),N&&S&&x?(R=yield(0,v.Ob)({aid:u.xE,count:16,cursor:T,secUid:S,language:I,coverFormat:C}),R.itemList=null===(y=R.itemList)||void 0===y?void 0:y.filter((e=>(D||!e.isPinnedItem)&&!e.imagePost)),R.hasMore=!!(R.itemList&&R.itemList.length>3)&&R.hasMore):R=yield(b={aid:u.xE,count:16,itemID:k,language:I,coverFormat:C,isNonPersonalized:L,clientABVersions:null==A?void 0:A.versionName,cursor:T,CategoryType:j},g(void 0,void 0,void 0,(function*(){return a.h.get("/api/related/item_list/",{query:b,baseUrlType:2})}))),(0,p.Tj)(e,t,h,"video",R)}catch(e){(0,p.e_)(t,h)}var b}))},resetRelatedList(){t(h,u.hA)}})))},92032:(e,t,n)=>{"use strict";n.d(t,{Ag:()=>g,Ds:()=>_,jf:()=>h});var i=n(43723),o=n(31209),a=n(99765),r=n(93751),s=n(58351),l=n(57717),c=n(44630),d=n(89049),u=n(68783);const p=(0,i.p)("atomsMapForItemListKey@tiktok/webapp-atoms",{"user-post":r.HP,"user-repost":s.O0,"user-liked":a.MQ,favorites:l.h9}),v=(0,i.p)("userItemListAtom@tiktok/webapp-atoms",(e=>({"user-post":e(r.HP),"user-repost":e(s.O0),"user-liked":e(a.MQ),favorites:e(l.h9)})),(()=>{})),{useAtomService:m,useServiceDispatchers:g,useServiceState:h,getStaticApi:_}=(0,o.i)(v,((e,t)=>({setLoading(n,i){(0,c.yI)(n)&&t(e(p)[n],(e=>Object.assign(Object.assign({},e),{loading:i})))},getItemList(e,t){return n=this,i=void 0,c=function*(){switch(e){case"user-post":default:return(0,r.s5)().getItemList(t);case"user-repost":return(0,s.rg)().getItemList(t);case"user-liked":return(0,a.vz)().getItemList(t);case"favorites":return(0,l.k6)().getItemList(t)}},new((o=void 0)||(o=Promise))((function(e,t){function a(e){try{s(c.next(e))}catch(e){t(e)}}function r(e){try{s(c.throw(e))}catch(e){t(e)}}function s(t){var n;t.done?e(t.value):(n=t.value,n instanceof o?n:new o((function(e){e(n)}))).then(a,r)}s((c=c.apply(n,i||[])).next())}));var n,i,o,c},setDeleteVideo(n){for(const[i,o]of Object.entries(e(p)))"user-post"===i?(0,r.s5)().setDeleteVideoForUserPostAtom(n):(0,u.Fx)(t,o,n)},resetItemList(n){(0,c.yI)(n)&&t(e(p)[n],d.hA)},resetAllLists(){(0,r.s5)().resetAllLists(),t(s.O0,d.hA),t(a.MQ,d.hA),t(l.h9,d.hA)}})))},57717:(e,t,n)=>{"use strict";n.d(t,{h9:()=>u,iK:()=>m,k6:()=>g});var i=n(56070),o=n(43723),a=n(14374),r=n(31209),s=n(89049),l=n(68783),c=n(44630),d=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const u=(0,a._)((0,o.p)("userFavoriteListAtom@tiktok/webapp-atoms",s.hA),{rehydrationKey:"desktop.userPage.userFavoriteList"}),{useAtomService:p,useServiceDispatchers:v,useServiceState:m,getStaticApi:g}=(0,r.i)(u,((e,t)=>({setLoading(e){t(u,(t=>Object.assign(Object.assign({},t),{loading:e})))},getItemList(n){return d(this,void 0,void 0,(function*(){try{t(u,(e=>Object.assign(Object.assign({},e),{loading:!0})));const o=(0,c.bv)(e,u,n),a=yield(e=>d(void 0,void 0,void 0,(function*(){return i.h.get("/api/user/collect/item_list/",{query:e,baseUrlType:2})})))(o);(0,l.Tj)(e,t,u,"favorites",a,{secUid:n.secUid}),t(u,(e=>{var t;return Object.assign(Object.assign({},e),{total:String(null!==(t=a.total)&&void 0!==t?t:0)})}))}catch(e){(0,l.e_)(t,u)}}))},resetItemList(){t(u,s.hA)}})))},99765:(e,t,n)=>{"use strict";n.d(t,{MQ:()=>u,cI:()=>v,vz:()=>g});var i=n(56070),o=n(43723),a=n(14374),r=n(31209),s=n(89049),l=n(68783),c=n(44630),d=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const u=(0,a._)((0,o.p)("userLikedListAtom@tiktok/webapp-atoms",s.hA),{rehydrationKey:"desktop.userPage.userLikedList"}),{useAtomService:p,useServiceDispatchers:v,useServiceState:m,getStaticApi:g}=(0,r.i)(u,((e,t)=>({setLoading(e){t(u,(t=>Object.assign(Object.assign({},t),{loading:e})))},getItemList(n){return d(this,void 0,void 0,(function*(){try{t(u,(e=>Object.assign(Object.assign({},e),{loading:!0})));const o=(0,c.bv)(e,u,n),a=yield(e=>d(void 0,void 0,void 0,(function*(){return i.h.get("/api/favorite/item_list/",{query:e,baseUrlType:2})})))(o);(0,l.Tj)(e,t,u,"user-liked",a,{secUid:n.secUid})}catch(e){(0,l.e_)(t,u)}}))},resetItemList(){t(u,s.hA)}})))},34308:(e,t,n)=>{"use strict";n.d(t,{Ku:()=>h,Ob:()=>g,Tx:()=>b,Ym:()=>m,gT:()=>f});var i=n(43723),o=n(14374),a=n(31209),r=n(89049),s=n(68783),l=n(44630),c=n(39785),d=n(68881),u=n(56070),p=n(46311),v=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const m=(0,o._)((0,i.p)("userPostListLatestAtom@tiktok/webapp-atoms",r.hA),{rehydrationKey:"desktop.userPage.userPostListLatest"}),g=(0,c.M)({csr:e=>v(void 0,void 0,void 0,(function*(){const t=(0,d.t$)("userPostList");if(t)return t;const n=(0,d.DV)("userPostList");return n?(p.P.emit("consume_prefetch_data",performance.now(),"unknown","userPostList"),n.catch((()=>(p.P.emit("consume_prefetch_data",performance.now(),"fail","userPostList"),u.h.get("/api/post/item_list/",{query:e,baseUrlType:2}))))):u.h.get("/api/post/item_list/",{query:e,baseUrlType:2})}))}),h=e=>{const{useAtomService:t,useServiceDispatchers:n,useServiceState:i,getStaticApi:o}=(0,a.i)(e,((t,n)=>({setLoading(t){n(e,(e=>Object.assign(Object.assign({},e),{loading:t})))},getItemList(i){var o;return v(this,void 0,void 0,(function*(){try{n(e,(e=>Object.assign(Object.assign({},e),{loading:!0})));const{secUid:a,userId:r,count:c,postItemListRequestType:u,filterPhotoContent:p,locateItemID:v,needPinnedItemIds:m=!0}=i,h=(0,l.bv)(t,e,Object.assign({secUid:a,userId:r,count:null!=c?c:d.M4,postItemListRequestType:u,needPinnedItemIds:m},v&&{locateItemID:v})),_=g(h);n(e,(e=>Object.assign(Object.assign({},e),{prevPromise:_})));const f=yield _;if(t(e).prevPromise!==_)return;p&&(f.itemList=null===(o=f.itemList)||void 0===o?void 0:o.filter((e=>!e.imagePost))),(0,s.Tj)(t,n,e,"user-post",f,{secUid:a})}catch(t){console.log("in utils, error getItemList!"),(0,s.e_)(n,e)}}))},resetItemList(){n(e,r.hA)}})));return{useAtomService:t,useServiceDispatchers:n,useServiceState:i,getStaticApi:o}},{useAtomService:_,useServiceDispatchers:f,useServiceState:y,getStaticApi:b}=h(m)},93751:(e,t,n)=>{"use strict";n.d(t,{s5:()=>A,BS:()=>S,ch:()=>k,I4:()=>E,eW:()=>w,yR:()=>x,HP:()=>T});var i=n(43723),o=n(31209),a=n(89049),r=n(44630),s=n(34308);const l=(0,i.p)("userPostListPopularAtom@tiktok/webapp-atoms",a.hA),{useAtomService:c,useServiceDispatchers:d,useServiceState:u,getStaticApi:p}=(0,s.Ku)(l),v=(0,i.p)("userPostListOldestAtom@tiktok/webapp-atoms",a.hA),{useAtomService:m,useServiceDispatchers:g,useServiceState:h,getStaticApi:_}=(0,s.Ku)(v);var f=n(68783);const y=(0,i.p)("atomsMapForPostItemListRequestType@tiktok/webapp-atoms",{0:s.Ym,1:l,2:v}),b=(0,i.p)("sortTypeAtom@tiktok/webapp-atoms",0),{useAtomService:w,useServiceState:x}=(0,o.i)(b,((e,t)=>({setUserPostSortType(e){t(b,e)}}))),T=(0,i.p)("userPostListAtom@tiktok/webapp-atoms",(e=>{const t=e(b),n=e(y)[t];return e(n)}),(()=>{})),{useAtomService:k,useServiceDispatchers:S,useServiceState:E,getStaticApi:A}=(0,o.i)(T,((e,t)=>({setLoading(n){(0,r.K8)(e(b))&&t(e(y)[e(b)],(e=>Object.assign(Object.assign({},e),{loading:n})))},getItemList(t){return n=this,i=void 0,a=function*(){switch(e(b)){case 0:default:return t.postItemListRequestType=0,(0,s.Tx)().getItemList(t);case 1:return t.postItemListRequestType=1,p().getItemList(t);case 2:return t.postItemListRequestType=2,_().getItemList(t)}},new((o=void 0)||(o=Promise))((function(e,t){function r(e){try{l(a.next(e))}catch(e){t(e)}}function s(e){try{l(a.throw(e))}catch(e){t(e)}}function l(t){var n;t.done?e(t.value):(n=t.value,n instanceof o?n:new o((function(e){e(n)}))).then(r,s)}l((a=a.apply(n,i||[])).next())}));var n,i,o,a},resetItemList(){(0,r.K8)(e(b))&&t(e(y)[e(b)],a.hA)},resetAllLists(){t(b,0),t(T,a.hA),t(s.Ym,a.hA),t(l,a.hA),t(v,a.hA)},setDeleteVideoForUserPostAtom(n){for(const i of Object.values(e(y)))(0,f.Fx)(t,i,n)}})))},58351:(e,t,n)=>{"use strict";n.d(t,{O0:()=>v,rg:()=>_,zu:()=>m});var i=n(56070),o=n(43723),a=n(14374),r=n(31209),s=n(39785),l=n(89049),c=n(68783),d=n(44630),u=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const p=(0,s.M)({csr:e=>u(void 0,void 0,void 0,(function*(){return i.h.get("/api/repost/item_list/",{query:e,baseUrlType:2})}))}),v=(0,a._)((0,o.p)("userRepostListAtom@tiktok/webapp-atoms",l.hA),{rehydrationKey:"userPage.userRepostList"}),{useAtomService:m,useServiceDispatchers:g,useServiceState:h,getStaticApi:_}=(0,r.i)(v,((e,t)=>({setLoading(e){t(v,(t=>Object.assign(Object.assign({},t),{loading:e})))},getItemList(n){return u(this,void 0,void 0,(function*(){try{t(v,(e=>Object.assign(Object.assign({},e),{loading:!0})));const i=(0,d.bv)(e,v,n),o=p(i);t(v,(e=>Object.assign(Object.assign({},e),{prevPromise:o})));const a=yield o;if(e(v).prevPromise!==o)return;(0,c.Tj)(e,t,v,"user-repost",a,{secUid:n.secUid})}catch(e){(0,c.e_)(t,v)}}))},resetItemList(){t(v,l.hA)}})))},44630:(e,t,n)=>{"use strict";n.d(t,{K8:()=>u,bv:()=>c,yI:()=>d});var i=n(57431),o=n(54888),a=n(89049);const r=30,s=["user-post","user-repost","user-liked","favorites"],l=[0,1,2];function c(e,t,n){var s;const{secUid:l,userId:c,count:d,postItemListRequestType:u,locateItemID:p,needPinnedItemIds:v=!0}=n,m=e(t),{cursor:g="0"}=m,{language:h,region:_}=(0,i.x)(),{bizContext:f}=e(o.A);return Object.assign({secUid:l,aid:a.xE,count:null!=d?d:r,cursor:g,region:_,language:h,userId:c,coverFormat:null===(s=null==f?void 0:f.videoCoverSettings)||void 0===s?void 0:s.format,post_item_list_request_type:null!=u?u:0,needPinnedItemIds:v},p&&{locate_item_id:p})}function d(e){return void 0!==s.find((t=>t===e))}function u(e){return void 0!==l.find((t=>t===e))}},92597:(e,t,n)=>{"use strict";n.d(t,{D:()=>_}),n(57432);var i=n(71281),o=n(41735),a=n(79217),r=n(39415),s=n(79995),l=n(43227),c=n(29909),d=n(96563),u=n(61918),p=n(93751),v=n(58351),m=n(99765),g=n(57717);const h=new Map([["foryou",c.e4],["music",l.l6],["explore",s.dQ],["challenge",o.T8],["creator_tab",r.DK],["user-post",p.HP],["user-repost",v.O0],["user-liked",m.MQ],["favorites",g.h9],["messages",u.D3],["video",d.Hx]]),_=e=>{var t;if(!e)return;const n="v0"!==(null!==(t=(0,i.d)("webapp_collection_profile"))&&void 0!==t?t:"v0");return"collection"===e&&n?a.ek:h.get(e)}},60072:(e,t,n)=>{"use strict";n.d(t,{ud:()=>j,Pu:()=>C,l8:()=>L,mG:()=>M,F3:()=>N,GB:()=>D});var i=n(71510),o=n.n(i),a=n(99789),r=n.n(a),s=n(18499),l=n(57431),c=n(40040),d=n(93608),u=n(6986),p=n(97071),v=n(24154),m=n(25342),g=n(67974),h=n(11983),_=n(53764),f=n(14374),y=n(31209),b=n(32125),w=n(43723),x=n(68783),T=n(84908),k=n(10287),S=n(41548),E=n(77170),A=n(56070),O=n(26325),P=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))},I=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const C=(0,f._)((0,w.p)("itemAtom@tiktok/webapp-atoms",{}),{rehydrationKey:"webapp.item"}),{useAtomService:L,getStaticApi:j,useServiceDispatchers:M,useServiceState:N}=(0,y.i)(C,((e,t)=>({setItem(e){const{id:n}=e;t(C,(t=>Object.assign(Object.assign({},t),{[n]:(0,E.t)(e,t[n])})))},multiSetItem(n){const i=e(C),o=Object.assign({},i);n.forEach((e=>{const{id:t}=e;o[t]=(0,E.t)(e,i[t])})),t(C,o)},updateItem(n){e(C)[n.id]&&t(C,(e=>Object.assign(Object.assign({},e),{[n.id]:o()(e[n.id],n)})))},setLike(n){const{id:i,liked:o,count:a}=n,r=e(C)[i];r&&(r.stats&&(r.stats=Object.assign(Object.assign({},r.stats),{diggCount:a})),r.statsV2&&(r.statsV2=Object.assign(Object.assign({},r.statsV2),{diggCount:a.toString()})),t(C,(e=>Object.assign(Object.assign({},e),{[i]:Object.assign(Object.assign({},r),{digged:o})}))))},setCollect(n){const{id:i,collected:o,count:a}=n,r=e(C)[i];r&&(r.stats&&(r.stats=Object.assign(Object.assign({},r.stats),{collectCount:a})),r.statsV2&&(r.statsV2=Object.assign(Object.assign({},r.statsV2),{collectCount:a.toString()})),t(C,(e=>Object.assign(Object.assign({},e),{[i]:Object.assign(Object.assign({},r),{collected:o})}))))},setCommentCount(n){const{id:i,commentCount:o}=n,a=e(C)[i];a&&(a.stats&&(a.stats=Object.assign(Object.assign({},a.stats),{commentCount:o})),a.statsV2&&(a.statsV2=Object.assign(Object.assign({},a.statsV2),{commentCount:o.toString()})),t(C,(e=>Object.assign(Object.assign({},e),{[i]:Object.assign({},a)}))))},setResolutionList(t){const{resolutionList:n,id:i}=t,o=e(C)[i];if(!o)return;const a=["auto",...n.filter((e=>"auto"!==e))];o.resolutionList=a},prependRepost(n){const{id:i,reposted:o,currentUser:a,count:r}=n,s=e(C)[i];s&&(s.statsV2&&(s.statsV2=Object.assign(Object.assign({},s.statsV2),{repostCount:r.toString()})),t(C,(e=>{var t,n,r,l,c;const d=[...null!==(n=null===(t=e[i])||void 0===t?void 0:t.repostList)&&void 0!==n?n:[]];if(o)d.unshift(Object.assign(Object.assign({},a),{id:a.uid,avatarThumb:null!==(r=a.avatarUri[0])&&void 0!==r?r:"",avatarMedium:null!==(l=a.avatarUri[0])&&void 0!==l?l:"",avatarLarger:null!==(c=a.avatarUri[0])&&void 0!==c?c:"",nickname:a.nickName,relation:0}));else{const e=d.findIndex((e=>e.secUid===a.secUid));d.splice(e,1)}return Object.assign(Object.assign({},e),{[i]:Object.assign(Object.assign({},s),{repostList:d})})})))},reduceOrIncreaseCommentCount(n){const{id:i,isReduce:o,min:a=0}=n,r=e(C),s=r[i];if(s){if(s.stats){const e=o?Math.max(a,s.stats.commentCount-1):s.stats.commentCount+1;s.stats=Object.assign(Object.assign({},s.stats),{commentCount:e})}if(s.statsV2){let e=o?BigInt(s.statsV2.commentCount)-BigInt(1):BigInt(s.statsV2.commentCount)+BigInt(1);eBoolean(e.author))).map((({author:e})=>e)),i=e.filter((e=>{var t;return Boolean((null===(t=null==e?void 0:e.liveRoomInfo)||void 0===t?void 0:t.ownerInfo)&&(0,x.Jl)(e))})).map((e=>Object.assign(Object.assign({},e.liveRoomInfo.ownerInfo),{roomId:e.liveRoomInfo.roomID}))),o=e.map((e=>Object.assign(Object.assign({},e),{logId:t}))),a=(0,T.Gp)();(0,s.unstable_batchedUpdates)((()=>{a.multiSetUser(n.concat(i)),this.multiSetItem(o)}))},postCollectVideo(t){var n,i,o,a;return I(this,void 0,void 0,(function*(){const r=e(C),s=e(T.p9),{itemId:l}=t,d=r[l],p=s.users[null!==(n=null==d?void 0:d.author)&&void 0!==n?n:""],{collected:v=!1,stats:m}=d,g=Number(null!==(i=null==m?void 0:m.collectCount)&&void 0!==i?i:0),h=v?2:1,_={aid:c.xE,itemId:l,action:h,secUid:null!==(o=null==p?void 0:p.secUid)&&void 0!==o?o:""};this.setCollect({id:l,collected:!v,count:v?Math.max(0,g-1):g+1});try{const e=yield function(e){return P(this,void 0,void 0,(function*(){return A.h.post("/api/item/collect/",{query:e,baseUrlType:2,headers:{[O.nk]:A.h.csrfToken}})}))}(_);u.W.handleFavoriteResult({group_id:l,author_id:null!==(a=null==p?void 0:p.id)&&void 0!==a?a:""},h);const{statusCode:t}=e;return 0!==t?void setTimeout((()=>{this.setCollect({id:l,collected:v,count:g})}),3e3):(1===h&&(yield this.addMlModelTrainData({id:l,action:"favorite"})),e)}catch(e){}}))},postLikeVideo(t){var n,i,o,a,r;return I(this,void 0,void 0,(function*(){const s=e(C),c=e(T.p9),d=s[t.id],u=c.users[null!==(n=null==d?void 0:d.author)&&void 0!==n?n:""],{user:m}=(0,l.x)(),{digged:g,stats:_,poi:f,imagePost:y,subVideoMeta:b,ad_info:w,repostList:x}=d,{id:k,forceLike:E,enter_method:I="click",channel_id:L}=t,j=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);oe.secUid!==(null==m?void 0:m.secUid))),type:E?1:g?0:1};if(!E||!g)try{let e;this.setLike({id:k,liked:!g,count:g?Math.max(0,M-1):M+1});try{e=yield function(e){return P(this,void 0,void 0,(function*(){return A.h.post("/api/commit/item/digg/",{query:e,baseUrlType:2,headers:{[O.nk]:A.h.csrfToken}})}))}(N)}catch(t){e={status_code:-1}}const{status_code:t,status_msg:n,log_pb:i={},is_digg:s}=e;if(2150===t||2210===t){const e=(0,S.T)();n&&h.F.open({content:e(n),duration:3,widthType:"half"})}let l={};w&&(l=(0,p.n5)({ad_info:w,play_mode:null!==(o=j.play_mode)&&void 0!==o?o:"one_column"})),v.z.handleLikeVideoResult(Object.assign(Object.assign(Object.assign({},j),l),{group_id:d.id,author_id:null!==(a=null==u?void 0:u.id)&&void 0!==a?a:"",log_pb:i,enter_method:I,poi_id:null==f?void 0:f.id,aweme_type:y?150:0,pic_cnt:null===(r=null==y?void 0:y.images)||void 0===r?void 0:r.length,is_sub_only_video:b?1:0}),N.type),0!==t||s===N.type?setTimeout((()=>this.setLike({id:d.id,liked:g,count:M})),3e3):1===N.type&&this.addMlModelTrainData({id:d.id,action:"like"})}catch(e){}}))},postRepostVideo(t){var n,i;return I(this,void 0,void 0,(function*(){const o=(0,S.T)(),a=e(C)[t.id],{user:r}=(0,l.x)();if(!a||!r)return;const{statsV2:s,repostList:c}=a,{id:u,playMode:p,playlistId:v}=t,m=(null!==(n=null==c?void 0:c.findIndex((e=>e.secUid===r.secUid)))&&void 0!==n?n:-1)>=0,g=Number(null!==(i=null==s?void 0:s.repostCount)&&void 0!==i?i:0),f=!m;try{this.prependRepost({id:u,reposted:f,currentUser:r,count:m?Math.max(0,g-1):g+1});const e={page_name:d.f.commonParams.page_name,group_id:u,play_mode:p,playlist_id:v};let t;try{const n={item_id:u};f?(d.f.sendEvent("click_repost",e),({status_code:t}=yield function(e){return P(this,void 0,void 0,(function*(){return A.h.post("/tiktok/v1/upvote/publish",{query:e,baseUrlType:2})}))}(n))):(d.f.sendEvent("click_repost_remove",e),({status_code:t}=yield function(e){return P(this,void 0,void 0,(function*(){return A.h.post("/tiktok/v1/upvote/delete",{query:e,baseUrlType:2})}))}(n)))}catch(e){t=-1}h.F.destroy();let n=f?"pcWeb_reposted_toast":"pcWeb_repostRemoved_toast";0!==t?(n="Sorry, something wrong with the server, please try again.",setTimeout((()=>this.prependRepost({id:u,reposted:m,currentUser:r,count:g})),3e3)):f?(d.f.sendEvent("repost_success",e),this.addMlModelTrainData({id:a.id,action:"repost"})):d.f.sendEvent("repost_remove_success",e),h.F.open({content:o(n),duration:3,widthType:"half",getContainer:_.M,getContainerPosition:"fixed"})}catch(e){}}))},addMlModelTrainData(t){var n;return I(this,void 0,void 0,(function*(){const{id:i,action:o,isPreview:a}=t,r=e(C);if(i&&r[i]&&!(null===(n=r[i])||void 0===n?void 0:n.liveRoomInfo))return(0,k.xt)().addTrainData({item:r[i],action:o,isPreview:a})}))},postDislikeVideo(t){return I(this,void 0,void 0,(function*(){const n=e(C),{id:i,author_id:o,play_mode:a}=t,r=n[i],s=null==r?void 0:r.ad_info;let l={};s&&(l=(0,p.n5)({ad_info:s,play_mode:a}),l.refer=m.Hq.Button),g.V.handleClickDislike(Object.assign({group_id:i,author_id:o,play_mode:a},l));const c=(0,S.T)();h.F.open({content:c("webapp_forYoufeed_videoRemoved_toast"),duration:3,widthType:"half",getContainer:_.M,getContainerPosition:"fixed"});const d={item_id:i,item_author_id:o};try{try{yield function(e){return P(this,void 0,void 0,(function*(){return A.h.post("/api/dislike/item/",{query:e,baseUrlType:2,headers:{[O.nk]:A.h.csrfToken}})}))}(d)}catch(e){}this.addMlModelTrainData({id:t.id,action:"dislike"})}catch(e){}}))},checkItemValidation(e){return I(this,void 0,void 0,(function*(){const t={itemIds:e};try{return yield function(e){return P(this,void 0,void 0,(function*(){return A.h.get("/api/item/availability/",{query:e,baseUrlType:2})}))}(t)}catch(e){}}))},setItemPrivateState(n){const{id:i,visibility:o}=n,a=e(C),r=a[i];if(!r)return;const s=Object.assign(Object.assign({},r),{forFriend:"3"===o,secret:"2"===o});t(C,Object.assign(Object.assign({},a),{[i]:s}))},setDeleteVideo(e){t(C,(t=>r()(t,e)))},getStaticItem:t=>e(C)[t]}))),D=e=>N((t=>(0,E.D)(t[e])),b.bN)},77170:(e,t,n)=>{"use strict";n.d(t,{D:()=>o,t:()=>i});const i=(e,t)=>{var n,i,o,a,r,s,l,c,d,u,p,v,m,g,h;const _=null!==(i=null===(n=e.anchors)||void 0===n?void 0:n.filter((e=>54===e.type)))&&void 0!==i?i:[],f=null!==(a=null===(o=e.anchors)||void 0===o?void 0:o.filter((e=>28===e.type)))&&void 0!==a?a:[];return Object.assign(Object.assign({},e),{video:e.video,nickname:null===(r=e.author)||void 0===r?void 0:r.nickname,author:null===(s=e.author)||void 0===s?void 0:s.uniqueId,authorId:null===(l=e.author)||void 0===l?void 0:l.id,authorSecId:null===(c=e.author)||void 0===c?void 0:c.secUid,avatarThumb:null===(d=e.author)||void 0===d?void 0:d.avatarThumb,downloadSetting:null===(u=e.author)||void 0===u?void 0:u.downloadSetting,authorPrivate:null===(p=e.author)||void 0===p?void 0:p.privateAccount,stateControlledMedia:null===(v=e.author)||void 0===v?void 0:v.stateControlledMedia,capcutAnchorsOriginal:_,capcutAnchors:(null===(m=e.poi)||void 0===m?void 0:m.id)?[]:_,effectAnchors:f,videoSuggestWordsList:null!==(g=e.videoSuggestWordsList)&&void 0!==g?g:null==t?void 0:t.videoSuggestWordsList,keywordTags:null!==(h=e.keywordTags)&&void 0!==h?h:null==t?void 0:t.keywordTags})},o=e=>{var t,n,i,o,a,r,s,l,c,d,u;if(!e)return{diggCount:BigInt(0),shareCount:BigInt(0),commentCount:BigInt(0),playCount:BigInt(0),collectCount:BigInt(0),repostCount:BigInt(0),isReposted:!1};const{stats:p,statsV2:v}=e;return{diggCount:BigInt(null!==(n=null!==(t=null==v?void 0:v.diggCount)&&void 0!==t?t:null==p?void 0:p.diggCount)&&void 0!==n?n:0),shareCount:BigInt(null!==(o=null!==(i=null==v?void 0:v.shareCount)&&void 0!==i?i:null==p?void 0:p.shareCount)&&void 0!==o?o:0),commentCount:BigInt(null!==(r=null!==(a=null==v?void 0:v.commentCount)&&void 0!==a?a:null==p?void 0:p.commentCount)&&void 0!==r?r:0),playCount:BigInt(null!==(l=null!==(s=null==v?void 0:v.playCount)&&void 0!==s?s:null==p?void 0:p.playCount)&&void 0!==l?l:0),collectCount:BigInt(null!==(d=null!==(c=null==v?void 0:v.collectCount)&&void 0!==c?c:null==p?void 0:p.collectCount)&&void 0!==d?d:0),repostCount:BigInt(null!==(u=null==v?void 0:v.repostCount)&&void 0!==u?u:0),isReposted:Number(null==v?void 0:v.repostCount)>0}}},46311:(e,t,n)=>{"use strict";n.d(t,{P:()=>i});const i=new class{constructor(){this.listeners={}}on(e,t){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push(t)}emit(e,...t){const n=this.listeners[e];n&&n.forEach((e=>{e(...t)}))}off(e,t){const n=this.listeners[e];n&&(this.listeners[e]=n.filter((e=>e!==t)))}}},84669:(e,t,n)=>{"use strict";n.d(t,{D:()=>i});const i=["ar","ur","he-IL"]},93987:(e,t,n)=>{"use strict";var i;n.d(t,{Y:()=>i}),function(e){e.PlayerChange="player_change",e.PlayerDestroy="player_destroy",e.PlayerMounted="player_mounted",e.OneColumnRerender="one_column_rerender",e.BrowseModeRerender="browse_mode_rerender",e.VideoRequest="video_request",e.VideoCanPlay="video_can_play",e.VideoFirstFrame="video_first_frame"}(i||(i={}))},62302:(e,t,n)=>{"use strict";n.d(t,{zI:()=>l});var i=n(4474),o=n(63615),a=n(88874);const r="/node-webapp/api/common-app-context";let s;function l(e){const t=(0,a.YI)(o.Ow);return t?Promise.resolve(Object.assign(Object.assign({},t),{statusCode:0})):s||(s=fetch((0,i.stringifyUrl)({url:r,query:{lang:e}})).then((e=>e.json())),s)}},10598:(e,t,n)=>{"use strict";n.d(t,{x:()=>l});var i=n(4474);const o="webapp.biz-context";var a=n(88874);const r="/node-webapp/api/biz-context";let s;function l(e,t){const n=(0,a.YI)(o);return n?Promise.resolve(Object.assign(Object.assign({},n),{statusCode:0})):s||(s=fetch((0,i.stringifyUrl)({url:r,query:{lang:e,app_name:t}})).then((e=>e.json())),s)}},68881:(e,t,n)=>{"use strict";n.d(t,{M4:()=>b,DV:()=>k,t$:()=>x,UM:()=>O,hX:()=>A,dz:()=>S,bg:()=>E});var i=n(58632),o=n(237),a=n(12904),r=n(74631),s=n(26325),l=n(18829),c=n(58156);const d="content-type",u=["/api/update/profile/","/api/commit/follow/user","/api/comment/publish"],p=["application/pdf"],v={"Singapore-Central":"sg","US-East":"va","US-EastRed":"in","US-TTP":"ttp","US-TTP2":"ttp2","EU-TTP":"ie","EU-TTP2":"no1a"};function m({url:e,response:t,appContext:n,bizContext:g,options:h,config:_,retryFn:f=()=>(0,i.__awaiter)(this,void 0,void 0,(function*(){}))},y){var b,w,x,T,k,S,E,A,O,P,I,C;return(0,i.__awaiter)(this,void 0,void 0,(function*(){if(null===(b=null==y?void 0:y.emitEvent)||void 0===b||b.call(y,"request_status",{now:performance.now()},{statusCode:"unknown"}),t.status>=400)return(0,o.Gy)(t,e),null===(w=null==y?void 0:y.emitEvent)||void 0===w||w.call(y,"request_status",{now:performance.now()},{statusCode:`${t.status}`}),Promise.reject(t);{const i=t.headers.get(d);if(null==i?void 0:i.includes("application/json"))try{let i=t.headers.has(a.Si)?JSON.parse(null!==(x=t.headers.get(a.Si))&&void 0!==x?x:"{}"):yield t.json();const o=t.headers.has(a.Si);null===(T=null==y?void 0:y.emitEvent)||void 0===T||T.call(y,"request_status",{now:performance.now()},{statusCode:`${t.status}`,needVerify:`${o}`}),o&&(null===(k=null==y?void 0:y.context)||void 0===k||k.call(y,{firstScreenRequest:"abort",verify:"1"}));const d=function(e,t,n){var i,o,r;const l=e.status_code||e.code,d=l===a.CQ,p=l===a.Zu;if(u.some((e=>t.includes(e)))&&(d||p)){const e=(0,c.v)(n);return{code:"10000",from:"shark_admin",type:"verify",version:1,region:null!==(r=null!==(i=v[e])&&void 0!==i?i:a.sG[null!==(o=s.si.kind)&&void 0!==o?o:""])&&void 0!==r?r:"va",subtype:d?"slide":"text",verify_event:"",detail:{},fp:-1}}return e}(i,e,null==g?void 0:g.idc),p="TTP"===(null==n?void 0:n.clusterRegion),b=(null==g?void 0:g.idc)?(0,c.v)(g.idc):null==g?void 0:g.vregion,w=yield r.MX.checkVerify(d,null!==(S=null==n?void 0:n.wid)&&void 0!==S?S:"0",p,s.si.captcha,{lang:null==n?void 0:n.language,userMode:(0,l.n)({isVA:"US-TTP"===b||"US-TTP2"===b,isLogin:Boolean(null==n?void 0:n.user),isFTC:null!==(A=null===(E=null==n?void 0:n.user)||void 0===E?void 0:E.ftcUser)&&void 0!==A&&A,isHighRisk:!1,isEU:(null==b?void 0:b.startsWith("EU-TTP"))||"US-EAST-RED"===b})});return 0===w?((null==h?void 0:h.onJsonResponse)&&(i=h.onJsonResponse({response:t,config:_,json:i})),null===(O=null==y?void 0:y.emitEvent)||void 0===O||O.call(y,"request_status",{now:performance.now()},{statusCode:`${t.status}`,status:"success"}),i):2===w?f().then((t=>m({url:e,response:t,appContext:n,bizContext:g,options:h,config:_,retryFn:f},y))):{statusCode:-1}}catch(e){return null===(P=null==y?void 0:y.emitEvent)||void 0===P||P.call(y,"request_status",{now:performance.now()},{statusCode:`${t.status}`,status:"fail",needVerify:`${t.headers.has(a.Si)}`,isRiskControlBlock:`${"0, 0"===t.headers.get("content-length")&&"Janus-Mini(fast)"===t.headers.get("x-janus-mini-api-forward")}`,errorMessage:null==e?void 0:e.message}),null===(I=null==y?void 0:y.context)||void 0===I||I.call(y,{firstScreenRequest:"abort"}),Promise.reject(t)}else{if(null===(C=t.headers.get(d))||void 0===C?void 0:C.includes("text/"))return t.text();if(-1!==p.indexOf(String(i)))return t.blob();if(null==i?void 0:i.includes("application/x-protobuf"))return t.arrayBuffer()}return t.text()}}))}var g=n(51660),h=n(57432),_=n.n(h),f=n(56070);const y=1988,b=35,w={recommendItemList:void 0,userPlayList:void 0,userPostList:void 0,poiDetail:void 0,poiCategory0:void 0,poiCategory1:void 0,poiCategory2:void 0,relatedKeywords:void 0,kapRelatedKeywords:void 0,kapProductList:void 0,linkerStrategy:void 0,exploreItemList:void 0,trendingMediaVideoList:void 0,trendingPublicVideoList:void 0};function x(e){const t=w[e];return t&&(w[e]=void 0),t}const T="$PREFETCH_CACHE";function k(e){var t,n,i,o;const a=null!==(t=window[T])&&void 0!==t?t:{};let r;return window[T]=a,(null===(n=a[e])||void 0===n?void 0:n.used)||(r=null===(o=null===(i=a[e])||void 0===i?void 0:i.request)||void 0===o?void 0:o.then((e=>m(e).catch((e=>{if(e instanceof Response){const t={status:e.status,url:e.url,logId:e.headers.get("x-tt-logid"),bdturingVerify:e.headers.get("bdturing-verify")};throw new Error(JSON.stringify(t))}throw e}))))),a[e]={used:!0,result:r},r}function S(e){const t={secUid:e,cursor:"0",count:20};w.userPlayList=f.h.get("/api/user/playlist/",{query:t,baseUrlType:2})}function E(e,t){const n=(0,g.qm)(),i={secUid:e,aid:y,count:b,cursor:"0",language:n,coverFormat:t};w.userPostList=f.h.get("/api/post/item_list/",{query:i,baseUrlType:2})}function A(e,t){const n=(0,g.qm)(),i=Object.assign({poiId:e,language:n},t&&{sourceType:t});w.poiDetail=f.h.get("/api/poi/detail/",{query:i,baseUrlType:2})}function O({poiId:e,subCategoryType:t},n,i){const o={poiId:e,language:(0,g.qm)()};w.poiDetail=f.h.get("/api/poi/detail/",{query:o,baseUrlType:2});const a=Object.assign({poiId:e,count:15,offset:0,trafficType:0},n);i.forEach(((e,n)=>{const i=0===n?1:0,o=`poiCategory${n}`,r=f.h.get("/api/seo/poi/item_list/",{query:t?Object.assign(Object.assign({},a),{subCategoryType:t,subTitleType:e}):Object.assign(Object.assign({},a),{subCategoryType:e}),baseUrlType:2});r.then((e=>{var t,n;(null!==(n=null===(t=e.itemList)||void 0===t?void 0:t.slice(0,i).map((e=>{var t,n;return null!==(n=null===(t=e.video.zoomCover)||void 0===t?void 0:t[720])&&void 0!==n?n:e.video.cover})))&&void 0!==n?n:[]).forEach((e=>{(new Image).src=e}))})).catch(_()),w[o]=r}))}},97487:(e,t,n)=>{"use strict";n.d(t,{Ni:()=>s,gA:()=>o,iq:()=>r});var i=n(88874);const o={userDetail:"webapp.user-detail",videoDetail:"webapp.video-detail",linkerStrategy:"webapp.linker-strategy",kapDetail:"webapp.kap-detail",kapLinkerStrategy:"webapp.kap.strategy",kapCoinLinkerStrategy:"webapp.kap.coin.strategy",walletRechargeShowGetCoinsEntrance:"wallet.recharge.show-get-coins-entrance",reflowVideoStrategy:"webapp.reflow.video.strategy",reflowVideoUiStrategy:"webapp.reflow.video.uiStrategy",reflowVideoDetail:"webapp.reflow.video.detail",reflowVideoOperationSettings:"webapp.reflow.video.operationSettings",reflowGlobalQueryData:"webapp.reflow.global.queryData",reflowGlobalShareUser:"webapp.reflow.global.shareUser",reflowGlobalStrategy:"webapp.reflow.global.strategy",reflowGlobalUiStrategy:"webapp.reflow.global.uiStrategy",reflowVersionUiStrategy:"webapp.reflow.version.uiStrategy",kapPageStrategy:"webapp.kap.pageStrategy",ssrVersion:"webapp.sharing.ssrVersion",smartuiPreview:"webapp.smartui.preview"},a={};function r(e){const t=(0,i.YI)(o[e]);t&&(a[e]=t)}function s(e){const t=a[e];return t&&(a[e]=void 0),t}},5441:(e,t,n)=>{"use strict";n.d(t,{B:()=>r});var i=n(40099),o=n(60484),a=n(49057);const r=()=>{const{userAgent:e}=(0,o.L$)((0,a.W)((()=>["userAgent"]),[])),t=(null==e?void 0:e.includes("tiktok"))&&(null==e?void 0:e.includes("TTElectron")),n=t&&(null==e?void 0:e.includes("osName/Mac")),r=t&&!n,[s,l]=(0,i.useState)(t),[c,d]=(0,i.useState)(n),[u,p]=(0,i.useState)(r);return(0,i.useEffect)((()=>{const{isElectron:e,osVersion:t=""}=(0,o.L$)(window.TTE_ENV),n=t.includes("Mac OS");l(e),d(e&&n),p(e&&!n)}),[]),{isElectronApp:s,isMacElectronApp:c,isWinElectronApp:u}}},25616:(e,t,n)=>{"use strict";n.d(t,{s:()=>m,Y:()=>g});var i=n(40099),o=n(51660);const a="473824";var r=n(84323),s=n(93991),l=n.n(s),c=n(60484),d=n(49057),u=n(48615);function p(e){let t=[];if(e){const n=e;t=l()(n)?n:[n]}return t.includes(a)}var v=n(64356);const m=(e="Webapp")=>{const{isSharing:t,isCoinLite:n,isCoinPro:o}=function(){const{region:e}=(0,c.L$)((0,d.W)((()=>["region"]),[])),{coinLiteConfig:t,isIOS:n,queryData:i}=(0,c.L$)((0,u.U)((()=>["coinLiteConfig","isIOS","queryData"]),[])),{share_app_id:o,_r:a}=null!=i?i:{},s="1"===a,l=function(e){var t,n;const{share_app_id:i,region:o,os:a="android",coinLiteConfig:s}=e,l=null!==(n=null===(t=null==s?void 0:s.coinLiteRegion)||void 0===t?void 0:t[a])&&void 0!==n?n:r.tt,c=!!o&&l.map((e=>{var t;return null===(t=null==e?void 0:e.toUpperCase)||void 0===t?void 0:t.call(e)})).includes(o);return p(i)&&c}({share_app_id:o,region:e,os:n?"ios":"android",coinLiteConfig:t}),v=function(e){var t,n;const{share_app_id:i,region:o,os:a="android",coinLiteConfig:s}=e,l=null!==(n=null===(t=null==s?void 0:s.coinProRegion)||void 0===t?void 0:t[a])&&void 0!==n?n:r.G,c=!!o&&l.map((e=>{var t;return null===(t=null==e?void 0:e.toUpperCase)||void 0===t?void 0:t.call(e)})).includes(o);return p(i)&&c}({share_app_id:o,region:e,os:n?"ios":"android",coinLiteConfig:t});return{isSharing:s,isCoinLite:l,isCoinPro:v,isCoin:l||v}}(),{t:a}=(0,i.useContext)(v.Ss);let s=a;return t&&n?s=function(e,t=[]){return function(n,i,o){return t.includes(n)?e(n,i,o):e(n,i,o).replace(/(TikTok( Lite)?\b)/g,(function(e,t,n){return n?e:`${t} Lite`}))}}(a):t&&o&&(s=function(e,t=[]){return function(n,i,o){return t.includes(n)?e(n,i,o):e(n,i,o).replace(/(TikTok( Pro)?\b)/g,(function(e,t,n){return n?e:`${t} Pro`}))}}(a)),g([e],t),(0,i.useCallback)(((t,n,i)=>void 0===t||"string"==typeof t&&!t.length?i:s(t,Object.assign({ns:e},n),i)),[e,s])};function g(e,t=!1){t&&(0,o.qm)();const{loadStarling:n,hasLoaded:a}=(0,i.useContext)(v.Ss),[r,s]=(0,i.useState)((null!=e?e:[]).reduce(((e,t)=>e&&a(t)),!0));return(0,i.useEffect)((()=>{e&&Promise.all(e.map((e=>{if(a(e))return!0;const t=(0,o.qm)();return n(e,t)}))).then((e=>{s(e.reduce(((e,t)=>e&&t),!0))}))}),[]),r}},37209:(e,t,n)=>{"use strict";n.d(t,{gW:()=>h,EK:()=>_,xt:()=>f,Dy:()=>p});var i=n(58632),o=n(35357),a=n.n(o),r=n(53385),s=n(77966),l=n(4929),c=n(34099);const d={isPhoenix:"object"==typeof window&&"www.tiktok.in"===window.location.host,textReplace:"undefined"==typeof window?null:new(n(17283).A)({condition:{APPID:"8660"},tccUrl:"https://sf-tcc-config.tiktokcdn.com/obj/tcc-config-web-alisg/tcc-v2-data-webcast.starling.proxy-default"}),loadTcc(){return this.isPhoenix?this.textReplace.getWithCache("webapp-phoenix-tcc"):Promise.resolve()},getPlugin:e=>({type:"postProcessor",name:"text-replace-plugin",process:(t,n)=>d.textReplace.processSync(t,e,n)}),getProcessName(){return this.isPhoenix?["text-replace-plugin"]:void 0}};var u=n(84669);function p(e,t,n){const i=[];return new Promise(((o,a)=>{d.loadTcc().then((r=>{(d.isPhoenix?s.Ay.use(d.getPlugin(r)):s.Ay).init({debug:!1,fallbackLng:["en"],initImmediate:!0,defaultNS:null!=t?t:"Webapp",postProcess:d.getProcessName(),saveMissing:!0,missingKeyHandler:(e,t,o,a)=>{i.includes(o)||(console.warn("[i18n] missing key",e,t,o,a),i.push(o)),n&&n(t,o,a)}},(e=>{e?a(e):o()})),s.Ay.setLang(e)}))}))}const v=["Webapp_recharge_referral"],m=["kick_user_frontier"];function g(e){return v.includes(e)?l.Uy:m.includes(e)?l.AY:l.Lq}function h(e,t,n=!1){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const{starling:i,tea:o}=(0,c.V)();return new r.A({namespace:e,api_key:g(e),locale:t,zoneHost:i,timeout:1e4,TEAChannelDomain:o,lazyUpdate:n}).load()}))}const _=a()(((e,t)=>{Object.entries(e).forEach((([e,n])=>{s.Ay.addResourceBundle(t,e,n,!0,!0)}))})),f=e=>u.D.includes(e)},95868:(e,t,n)=>{"use strict";n.d(t,{$p:()=>se,AT:()=>u,Ds:()=>M,FJ:()=>J,Fj:()=>O,G2:()=>c,Iy:()=>C,Iz:()=>x,K8:()=>A,Ke:()=>j,LC:()=>z,M5:()=>ae,N6:()=>V,P_:()=>S,Pz:()=>ce,RR:()=>$,Tc:()=>H,U0:()=>q,WD:()=>g,ZG:()=>F,a1:()=>R,b8:()=>ie,bc:()=>le,cj:()=>N,eD:()=>K,fJ:()=>v,gq:()=>E,hh:()=>ne,ie:()=>B,j:()=>G,mQ:()=>Q,nq:()=>L,p5:()=>W,pH:()=>d,pz:()=>D,q$:()=>U,qd:()=>P,sM:()=>Z,sn:()=>k,tO:()=>T,vb:()=>X,xj:()=>de,yw:()=>ue,zp:()=>w});var i=n(47172),o=n(82715),a=n(9047),r=n(8227),s=n(97497),l=n(94810);const{getPureLivePath:c,getPureMusicPath:d,getPureTagPath:u,getPureStickerPath:p,getPureUserPath:v,getPureVideoPath:m,getPureQuestionPath:g}=l.h,{getPureUniqueId:h,hasIllegalText:_,isPureNumber:f,isRealUniqueId:y,purifyMusicName:b,purifyPlainText:w}=l.A;function x(e){const t=e.replace(/\/$/,"");return e===o.OZ.home||o.OZ.foryouWithLang.includes(t)}function T(e){return e.replace(/\/$/,"")===o.OZ.foryou||x(e)}function k(e){if(T(e))return"fyp";if(e.match("/following"))return"following";if(e.match("/friends"))return"friend";if(e.match("/setting"))return"setting";if(e.match("/search"))return"search";if(e.match("/message"))return"message";if(e.match("/video"))return"video";if(e.match("/@"))return e.match("/live")?"":"user";if(e.match("/report"))return"report";if(e.match("/music"))return"music";if(e.match("/effect"))return"effect";if(e.match("/tag"))return"hashtag";if(e.match(/\/discover\/.+/))return"expansion";if(e.match("/discover"))return"discover";if(e.match("/live"))return"";if(S(e)){const t=(0,i.matchPath)(e,{path:o.OZ.topics,exact:!0});return`topics_${null==t?void 0:t.params.name}`}return e.match("/profile")?"profile":e.match("/inbox")?"inbox":e.match("/feedback")?"feedback":""}function S(e){return Boolean((0,i.matchPath)(e,{path:o.OZ.topics,exact:!0}))}function E(e){return e===o.OZ.following}function A(e){return e===o.OZ.friends}function O(e){return/^\/@[^/]*\/video\/\d+/.test(e)||/^\/@[^/]*\/photo\/\d+/.test(e)}function P(e){return/^\/@.+\/live/.test(e)}function I(e){return/^\/@.+\/playlist\/.+/.test(e)}function C(e){return/^\/music\/.+/.test(e)}function L(e){return/^\/effect\/.+/.test(e)}function j(e){return/^\/tag\/.+/.test(e)}function M(e){return/^\/@.*\/collection\/.+/.test(e)}function N(e){return!/^\/@.+\/live/.test(e)&&!/^\/@.*\/video\/\d+/.test(e)&&/^\/@.+/.test(e)&&!/^\/@.*\/collection\/.+/.test(e)}function D(e){var t;return"expansion"===(null===(t=(0,a.fq)(e))||void 0===t?void 0:t.name)}function R(e){return e===o.OZ.searchHome}function B(e){return e===o.OZ.searchUser}function U(e){return e===o.OZ.searchVideo}function F(e){return e===o.OZ.searchLive}function V(e){return e===o.OZ.searchReminder}function z(e){return/^\/question\/.+/.test(e)}function H(e){return/^\/messages/.test(e)}function q(e){const t=[r.vI.liveDiscover,r.vI.liveFollowing,r.vI.liveGaming,r.vI.liveSingleGaming,r.vI.liveEventAggregation,r.vI.liveLifestyle,r.vI.liveCategory,r.vI.liveCategoryGaming,r.vI.liveCategoryLifestyle,r.vI.liveCategorySingleGaming,r.vI.liveCategorySingleLifeStyle,r.vI.liveCategorySingleAction];return!!(0,i.matchPath)(e,{path:t,exact:!0})}function G(e){return/live\/event\/\d/.test(e)}function $(e){return/live\/event/.test(e)}function W(e){return e.startsWith("/live")||P(e)}function Z(e){return e.startsWith("/coin")}function Y(e){return Boolean((0,i.matchPath)(e,{path:o.OZ.discover,exact:!0}))}function K(e){return Boolean((0,i.matchPath)(e,{path:o.OZ.explore,exact:!0}))}function X(e){return/^\/place\/.+/.test(e)||/^\/travel\/.+/.test(e)}function Q(e){return/^\/login/.test(e)}function J(e){return/^\/signup/.test(e)}function ee(e){var t;return(null===(t=(0,o.jN)(e))||void 0===t?void 0:t.name)===o.eU.channel}function te(e){var t;return(null===(t=(0,o.jN)(e))||void 0===t?void 0:t.name)===o.eU.videoPlaylist}function ne(e){return e.startsWith("/feedback")}function ie(e){return e.startsWith(o.OZ.setting)}const oe={5:T,11:E,20:A,0:O,4:C,129:L,3:j,121:M,1:N,106:B,107:U,123:F,105:R,16:z,113:S,13:H,103:Y,104:D,122:ee,108:te,18:X};function ae(e){var t;return null!==(t=Object.keys(oe).find((t=>oe[t](e))))&&void 0!==t?t:5}const re=e=>"business"===new URLSearchParams(e).get("scene");function se(e){var t,n;return["download","downloadWithLang"].includes(null!==(n=null===(t=(0,o.jN)(e))||void 0===t?void 0:t.name)&&void 0!==n?n:"")}function le(e,t){return(!t||!re(t))&&(j(e)||S(e)||E(e)||A(e)||T(e)||C(e)||L(e)||O(e)||N(e)&&!I(e)||Y(e)||R(e)||B(e)||U(e)||F(e)||V(e)||z(e)||X(e)||M(e)||K(e)||ee(e)||function(e){var t;return(null===(t=(0,o.jN)(e))||void 0===t?void 0:t.name)===o.eU.find}(e)||te(e)||function(e){return e.startsWith("/404")}(e)||ne(e)||H(e)||ie(e)||D(e)||function(e){return e.startsWith("/upload")}(e)||q(e)||P(e)||function(e){return e.startsWith("/live/popout/")}(e)||G(e))}function ce(e,t){return(!t||!re(t))&&(T(e)||N(e)&&!I(e)||O(e)||M(e)||E(e)||A(e)||K(e)||H(e)||C(e)||Boolean(e.match("/profile"))||R(e)||B(e)||U(e)||F(e)||V(e)||ie(e)||j(e)||ee(e)||D(e)||Y(e))}function de(e){return q(e)||P(e)||G(e)}function ue({uniqueId:e,secUid:t,itemId:n,isPhoto:i}){const o=l.A.getPureUniqueId({uniqueId:e,secUid:t});return o&&n?i?s.Lj.photo({uniqueId:o,id:n}):s.Lj.video({uniqueId:o,id:n}):""}},56070:(e,t,n)=>{"use strict";n.d(t,{h:()=>D,J:()=>L});var i=n(58632),o=n(67134),a=n(4474),r=n(31578),s=n(26325),l=n(32970),c=n(12904),d=n(74631),u=n(58156),p=n(5902),v=n(237),m=n(18829);const g="content-type",h=["application/pdf"],_=["/api/update/profile/","/api/commit/follow/user","/api/comment/publish"],f="webapp-session-referer",y="device_id",b={"Singapore-Central":"sg","US-East":"va","US-EastRed":"in","US-TTP":"ttp","US-TTP2":"ttp2","EU-TTP":"ie","EU-TTP2":"no1a"};class w{constructor(e){this.verify=d.MX,this.isPageVisible=!0,this.isFocus=!0,this.handleAppContext=e=>(0,i.__awaiter)(this,void 0,void 0,(function*(){return this.appContext||(this.appContext=yield this.options.getAppContextAsync()),e})),this.handleBizContext=e=>(0,i.__awaiter)(this,void 0,void 0,(function*(){this.bizContext||e.ignoreBizContext||(this.bizContext=yield this.options.getBizContextAsync());const{ignoreBizContext:t}=e;return(0,i.__rest)(e,["ignoreBizContext"])})),this.handleQuery=e=>(0,i.__awaiter)(this,void 0,void 0,(function*(){var t,n,i,o,a,r,l,c;const d=this.getRiskParams(null!==(t=e.riskParamsType)&&void 0!==t?t:0),u={},p=null===(n=this.bizContext)||void 0===n?void 0:n.canUseQuery,{type:v}=null!==(o=null===(i=this.appContext)||void 0===i?void 0:i.env)&&void 0!==o?o:{type:""},m=null===(a=this.appContext)||void 0===a?void 0:a.odinId,g="ppe"===v||"boe"===v,h=null!==(l=new URLSearchParams(null===(r=window.location)||void 0===r?void 0:r.search).get(y))&&void 0!==l?l:void 0;(p||g)&&h&&(u[y]=h);const _={WebIdLastTime:null===(c=this.appContext)||void 0===c?void 0:c.webIdCreatedTime};m&&(_.odinId=m);const f=(0,s.F0)(),b=f.to?f.dispatchParams:{},w=yield this.options.getExtraParams(e);return e.query=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},d),e.query),w),b),u),_),e})),this.handleURL=e=>{var t;let{url:n}=e;const i=null!==(t=e.query)&&void 0!==t?t:{};return n.startsWith("http:")||n.startsWith("https:")||(n=`${(0,s.$_)(e.baseUrlType)}${n}`),n=(0,a.stringifyUrl)({url:n,query:i}),e.url=n,e},this.options=e,"undefined"!=typeof window&&((0,p.Gz)(this.handleVisibilityChange.bind(this,!1),this.handleVisibilityChange.bind(this,!0)),this.bindFocusChange())}init(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const t=yield this.options.getAppContextAsync(e);this.appContext=t}))}get csrfToken(){var e,t;return this.appContext,null!==(t=null===(e=this.appContext)||void 0===e?void 0:e.csrfToken)&&void 0!==t?t:""}get(e,t){return this.runFetch(e,Object.assign(Object.assign({},t),{method:"GET"}))}post(e,t={}){var{omitContentType:n=!1}=t,o=(0,i.__rest)(t,["omitContentType"]);const a=new Headers(o.headers);return a.get(g)||n||a.set(g,"application/x-www-form-urlencoded"),o.body||(o.body=""),o.headers=a,this.runFetch(e,Object.assign(Object.assign({},o),{method:"POST"}))}delete(e,t={}){var{omitContentType:n=!1}=t,o=(0,i.__rest)(t,["omitContentType"]);return this.runFetch(e,Object.assign(Object.assign({},o),{method:"DELETE"}))}getRiskParams(e){if(!this.appContext)return{};if(2===e)return{};if((0,p.Hd)(f)||(0,p.J2)(f,document.referrer),1===e)return Object.assign({},(0,l.Y)());const t={};(0,c.Yp)()&&(t.security_verification_aid="1459");const n=navigator.userAgent;return Object.assign(Object.assign({},(0,l.w)(Object.assign(Object.assign({},this.appContext),{isMobile:(0,r.Ny)(n),os:(0,r.R0)(n)}),this.isPageVisible,this.isFocus)),t)}runFetch(e,t){var n,o,a,{credentials:r="include"}=t,s=(0,i.__rest)(t,["credentials"]);return(0,i.__awaiter)(this,void 0,void 0,(function*(){let t=Object.assign({url:e,credentials:r},s);t=yield Promise.all([this.options.beforeHandleQuery(t),this.handleAppContext(t),this.handleBizContext(t)]).then((([,,e])=>this.handleQuery(e))).then((e=>this.handleURL(e)));const{url:l}=t,c=(0,i.__rest)(t,["url"]),d=new Set(["query","riskParamsType","baseUrlType","requireSecSdk"]),u=Object.keys(c).reduce(((e,t)=>(d.has(t)||(e[t]=c[t]),e)),{});return u.credentials=r,null===(o=(n=this.options).beforeFetch)||void 0===o||o.call(n,l,null!==(a=s.method)&&void 0!==a?a:"GET"),this.fetchData(l,u)}))}fetchData(e,t){var n,o,a,r,l,d,p,_,f,y,b,w,x,T,k,S,E,A,O,P,I,C;return(0,i.__awaiter)(this,void 0,void 0,(function*(){let i;try{i=yield window.fetch.call(null,e,t)}catch(e){return Promise.reject(e)}if(i){if(i.status>=400)return(0,v.Gy)(i,e),Promise.reject(i);{const v=i.headers.get(g);if(null==v?void 0:v.includes("application/json"))try{let v=i.headers.has(c.Si)?JSON.parse(null!==(n=i.headers.get(c.Si))&&void 0!==n?n:"{}"):yield i.json();const g=this._getVerifyJson(v,e),h="TTP"===(null===(o=this.appContext)||void 0===o?void 0:o.clusterRegion),A=(null===(a=this.bizContext)||void 0===a?void 0:a.idc)?(0,u.v)(this.bizContext.idc):null===(r=this.bizContext)||void 0===r?void 0:r.vregion;i.headers.has(c.Si)&&(null===(l=this.options)||void 0===l?void 0:l.reportFn)&&(null===(f=null===(_=null===(p=(d=this.options).reportFn)||void 0===p?void 0:p.call(d))||void 0===_?void 0:_.context)||void 0===f||f.call(_,{firstScreenRequest:"abort",verify:"1"}));const O=yield this.verify.checkVerify(g,null!==(b=null===(y=this.appContext)||void 0===y?void 0:y.wid)&&void 0!==b?b:"0",h,s.si.captcha,{lang:null===(w=this.appContext)||void 0===w?void 0:w.language,userMode:(0,m.n)({isVA:"US-TTP"===A||"US-TTP2"===A,isLogin:Boolean(null===(x=this.appContext)||void 0===x?void 0:x.user),isFTC:null!==(S=null===(k=null===(T=this.appContext)||void 0===T?void 0:T.user)||void 0===k?void 0:k.ftcUser)&&void 0!==S&&S,isHighRisk:!1,isEU:(null==A?void 0:A.startsWith("EU-TTP"))||"US-EAST-RED"===A})});return 0===O?((null===(E=this.options)||void 0===E?void 0:E.onJsonResponse)&&(v=this.options.onJsonResponse({response:i,config:t,json:v})),v):2===O?this.fetchData(e,t):{statusCode:-1}}catch(e){return null===(I=null===(P=null===(O=null===(A=this.options)||void 0===A?void 0:A.reportFn)||void 0===O?void 0:O.call(A))||void 0===P?void 0:P.context)||void 0===I||I.call(P,{firstScreenRequest:"abort"}),Promise.reject(i)}else{if(null===(C=i.headers.get(g))||void 0===C?void 0:C.includes("text/"))return i.text();if(-1!==h.indexOf(String(v)))return i.blob();if(null==v?void 0:v.includes("application/x-protobuf"))return i.arrayBuffer()}return i.text()}}}))}_getVerifyJson(e,t){var n,i,o,a;const r=e.status_code||e.code,l=r===c.CQ,d=r===c.Zu;if(_.some((e=>t.includes(e)))&&(l||d)){const{idc:e}=null!==(n=this.bizContext)&&void 0!==n?n:{},t=(0,u.v)(e);return{code:"10000",from:"shark_admin",type:"verify",version:1,region:null!==(a=null!==(i=b[t])&&void 0!==i?i:c.sG[null!==(o=s.si.kind)&&void 0!==o?o:""])&&void 0!==a?a:"va",subtype:l?"slide":"text",verify_event:"",detail:{},fp:-1}}return e}handleVisibilityChange(e){this.isPageVisible=e}bindFocusChange(){const e=()=>{this.isFocus=!0},t=()=>{this.isFocus=!1};return window.addEventListener("focus",e),window.addEventListener("blur",t),()=>{window.removeEventListener("focus",e),window.removeEventListener("blur",t)}}}var x=n(93608),T=n(90535),k=n(62302),S=n(95868),E=n(9796),A=n(41857);const O=new Set,P=[];let I;const C=()=>{var e;if(I&&P.length){for(const t of P)try{null===(e=null==I?void 0:I.emitEvent)||void 0===e||e.call(I,"sdkLoad",{duration:t.duration},{name:t.name})}catch(e){console.error("flushSdkLog error",e)}P.splice(0,P.length)}};function L(e){I=e,C()}function j(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){if(E.Qf.loaded)return;const{url:t,method:n,needSign:i}=e;let o=Boolean(A.U8.some((e=>Boolean(t.match(new RegExp(e)))))||t.startsWith("/")&&!t.startsWith("//")&&"GET"===n&&!A.zv.some((e=>Boolean(t.match(new RegExp(e))))));if(o=o&&!i,!o&&(yield E.Qf.load(),e.requireSecSdk&&!E.Qf.sdks[1].initialized))throw new Error("secsdk load error")}))}function M(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){if(E.er.loaded)return;const{url:t,method:n}=e;"POST"===n&&A.VF.some((e=>Boolean(t.match(new RegExp(e)))))&&(yield E.er.load())}))}function N(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const{url:t}=e,n=E.Fs.some((e=>Boolean(t.match(new RegExp(e)))));!E.ZC.loaded&&n&&(yield E.ZC.load())}))}const D=(0,o.U)("fetch@tiktok/webapp-common",(()=>new w({getBizContextAsync:T.h,getAppContextAsync:k.zI,getExtraParams:e=>(0,i.__awaiter)(void 0,void 0,void 0,(function*(){var t,n,i;const o=yield(0,T.h)();let a={};return(null===(t=null==o?void 0:o.liveCommonConfig)||void 0===t?void 0:t.regionEntry)&&[4,5,9].includes(null!==(n=e.baseUrlType)&&void 0!==n?n:0)&&(a={channel:"local_test",carrier_region:null!==(i=localStorage.getItem("LIVE_OFFICE_REGION"))&&void 0!==i?i:"TW"}),Object.assign(Object.assign({},a),{from_page:(0,S.sn)(location.pathname)})})),beforeHandleQuery:e=>(0,i.__awaiter)(void 0,void 0,void 0,(function*(){yield Promise.all([j(e),M(e),N(e)]).catch((e=>{throw e}));try{[E.ZC,E.Qf,E.er].forEach((e=>{e.time&&e.time.forEach((e=>(e=>{try{O.has(e.name)||(O.add(e.name),P.push(e)),C()}catch(e){console.error("sdkLogger error",e)}})(e)))}))}catch(e){console.error("sdkLogger error",e)}return e})),beforeFetch:(e,t)=>{x.f.sendEvent("api_request",{api_path:e,method:t})},onJsonResponse:e=>(0,i.__awaiter)(void 0,void 0,void 0,(function*(){const{response:t,json:n}=e,i=t.headers.get("x-tt-logid");return n.__headers={url:t.url,log_id:i},n})),reportFn:()=>I})))},55099:(e,t,n)=>{"use strict";n.d(t,{p:()=>d});var i=n(58632),o=n(7672),a=n(71510),r=n.n(a),s=n(26324),l=n(56070);function c(e){return(t,n)=>new s.c((i=>{var o;const a="AbortController"in window?new AbortController:{signal:{aborted:!1},abort(){this.signal.aborted=!0}};return l.h[e](t,r()(n,{signal:null!==(o=null==n?void 0:n.signal)&&void 0!==o?o:a.signal})).then((e=>{i.next(e),i.complete()})).catch((e=>{i.error(e)})),()=>{a.signal.aborted||a.abort()}}))}let d=class{constructor(){this.get=c("get"),this.post=c("post"),this.delete=c("delete")}get csrfToken(){return l.h.csrfToken}};d=(0,i.__decorate)([(0,o._)()],d)},9796:(e,t,n)=>{"use strict";n.d(t,{er:()=>y,Qf:()=>f,ZC:()=>T,Fs:()=>x});var i=n(58632),o=n(51660),a=n(87181),r=n(62302),s=n(41857),l=n(58156),c=n(90535);class d{constructor(){this.initialized=!1,this.executionTime=0,this.name=""}load(){if(this.initialized)return Promise.resolve();if(this.promise)return this.promise;const{promise:e,cleanup:t}=function(){let e;return{promise:new Promise((t=>{e=window.setTimeout((()=>{t(null)}),1e4)})),cleanup:()=>{clearTimeout(e)}}}();return this.promise=Promise.race([e.then((()=>{this.promise=void 0})),this.loadSDK()]).then((()=>{t()})).catch((()=>{t(),this.promise=void 0})),this.promise}}class u{constructor(e){this.promise=null,this.keyword=e}get(e){return this.promise||(void 0===this.hasScript&&(this.hasScript=(0,a.yw)(e)),this.hasScript?this.promise=(t=this.keyword,new Promise((e=>{const n=()=>{window.requestAnimationFrame((()=>{window[t]?e(null):n()}))};n()}))):this.promise=(0,a.$U)(e).catch((e=>{throw this.promise=null,e}))),this.promise;var t}}var p=n(18829);const v=new u("byted_acrawler"),m={"Singapore-Central":"sg-tiktok","US-East":"va-tiktok","US-EastRed":"gcp-tiktok","US-TTP":"ttp","US-TTP2":"ttp2","EU-TTP":"eu-ttp","EU-TTP2":"eu-ttp2"},g="MSSDK_INITIALIZED",h=new u("secsdk"),_={"Singapore-Central":"sg","US-East":"va","US-EastRed":"va","US-TTP":"oci","US-TTP2":"oci","EU-TTP":"eu","EU-TTP2":"eu"},f={sdks:[new class extends d{constructor(e,t){super(),this.name="acrawlersdk",this.getContextProps=e,this.configs=t}loadSDK(){const e=performance.now();return Promise.all([this.getContextProps(),v.get({moduleId:(0,a.BJ)()})]).then((([{appId:t,user:n,wid:i,idc:o,vregion:a=""}])=>{var r;if(window[g])return void(this.initialized=!0);window[g]=!0,this.initialized=!0;const s=1233===t,c=void 0!==o?(0,l.v)(o):a,d=null!==(r=m[c])&&void 0!==r?r:s?"va-tiktok":"sg-tiktok",u="useast2b"===o?"https://mssdk16-normal-useastred.tiktokw.eu":"";this.configs.forEach((e=>{var t;window.byted_acrawler.init({aid:e.aid,dfp:e.dfp,boe:e.boe,intercept:e.intercept,enablePathList:e.enablePathList,region:d,apiHost:u,mode:(0,p.n)({isVA:s,isLogin:Boolean(n),isFTC:null!==(t=null==n?void 0:n.ftcUser)&&void 0!==t&&t,isHighRisk:e.isHighRisk}),isSDK:e.isSDK,custom:{ttwid:i}})})),this.executionTime=performance.now()-e}))}}((()=>Promise.all([(0,r.zI)((0,o.qm)()),(0,c.h)()]).then((([{appId:e,user:t,wid:n},{idc:i,vregion:o}])=>({appId:e,user:t,idc:i,wid:n,vregion:o})))),s.TA),new class extends d{constructor(e){super(),this.name="secsdk",this.getContextProps=e}loadSDK(){const e=performance.now();return this.getContextProps().then((({clusterRegion:e})=>{const t=(0,a.D9)(e);return h.get({moduleId:t})})).then((()=>{this.initialized||(this.initialized=!0,window.secsdk.csrf.setProtectedHost(s.sh),this.executionTime=performance.now()-e)}))}}((()=>(0,r.zI)((0,o.qm)())))],load:()=>Promise.all(f.sdks.map((e=>e.load()))),get loaded(){return this.sdks.reduce(((e,{initialized:t})=>e&&t),!0)},get time(){if(this.loaded)return this.sdks.map((({executionTime:e,name:t})=>({duration:e,name:t})))}},y={sdks:[new class extends d{constructor(e){super(),this.loadSDK=()=>(0,i.__awaiter)(this,void 0,void 0,(function*(){const e=performance.now();if(this.initialized)return;const{csrf:t}=yield n.e(5832).then(n.t.bind(n,55167,23));t.setProtectedHost(this.config),this.executionTime=performance.now()-e,this.initialized=!0})),this.name="cthulhusdk",this.config=e}}(s.kM)],load:()=>Promise.all(y.sdks.map((e=>e.load()))),get loaded(){return this.sdks.every((({initialized:e})=>e))},get time(){if(this.loaded)return this.sdks.map((({executionTime:e,name:t})=>({duration:e,name:t})))}},b=["/passport/web/"],w=["/v1/message/send","/api/update/profile","/api/v1/item/create/bulk","/api/v1/web/project/post","/api/commit/follow/user","/api/commit/item/digg","/api/comment/publish","/api/comment/digg","/api/item/collect","/api/aweme/delete","/tiktok/region/change/precheck/get/v1","/webcast/room/enter","/webcast/room/chat","/webcast/room/share","/webcast/gift/send","/webcast/sub/contract/create","/webcast/wallet_api/diamond_buy_external","/webcast/wallet_api_tiktok/withdraw/v2","/webcast/wallet_api/diamond_exchange/","/webcast/user/relation/update","/passport/web/"],x=b.concat(w),T={sdks:[new class extends d{constructor(e,t){super(),this.getContextProps=e,this.name="ztisdk",this.configs=t}loadSDK(){const e=performance.now();return this.getContextProps().then((({appId:t,user:o,wid:a,vregion:r="",idc:s})=>(0,i.__awaiter)(this,void 0,void 0,(function*(){var i;if(this.initialized)return;const c=void 0!==s?(0,l.v)(s):r,d=null!==(i=_[c])&&void 0!==i?i:"va",{SecureSDK:u}=yield Promise.all([n.e(8978),n.e(7586)]).then(n.bind(n,56134));yield u.init(d),u.setRegion(d),u.setConfig(Object.assign({aid:t,scene:"tt_fetch",certType:"header",signVersion:2},this.configs)),u.setLoginStatus(Boolean(o)),u.setWebId(a,t),u.setDisableCrossStorage(!0),u.setDisableStorageSignData(!1),u.setType({initType:"pubKey",signType:"pubKey"}),u.setStorageType("local"),u.start(),this.executionTime=performance.now()-e,this.initialized=!0}))))}}((()=>Promise.all([(0,r.zI)((0,o.qm)()),(0,c.h)()]).then((([{appId:e,user:t,wid:n,abTestVersion:i},{vregion:o,idc:a}])=>({appId:e,user:t,wid:n,vregion:o,abTestVersion:i,idc:a})))),{providerPathList:b,consumerPathList:w})],load:()=>Promise.all(T.sdks.map((e=>e.load()))),get loaded(){return this.sdks.every((({initialized:e})=>e))},get time(){if(this.loaded)return this.sdks.map((({executionTime:e,name:t})=>({duration:e,name:t})))}}},41857:(e,t,n)=>{"use strict";n.d(t,{TA:()=>p,U8:()=>r,VF:()=>h,kM:()=>_,sh:()=>u,zv:()=>a});var i=n(22113),o=n.n(i);const a=["/node/share/","/share/item/list","/discover/render/undefined","/share/item/explore/list","/api/comment/list/","/api/comment/list/reply/","/api/commit/follow/user/","/api/commit/item/digg/","/aweme/v1/upload/image2/","/api/notice/multi/","/api/notice/count/","/api/notice/digg/list/","/api/user/following/request/list/","/api/commit/follow/request/approve/","/api/commit/follow/request/reject/","/api/comment/digg/","/api/comment/publish/","/api/comment/delete/","/api/sticker/item_list/","/api/user/contact/list/","/api/at/default/list/","/api/comment/search/user/","/web/aweme/v1/search/challengesug","/web/aweme/v1/discover/search/","/api/v1/item/create/","/api/ba/business/suite/permission/list","/api/search/user/full/","/api/search/user/preview/","/api/search/item/full/","/api/search/general/full/","/api/music/detail/","/api/challenge/detail/","/api/user/detail/","/api/user/list/","/api/item/detail/","/api/question/detail/","/api/question/item_list/","/api/discover/challenge/","/api/discover/user/","/api/discover/music/","/api/challenge/item_list/","/api/music/item_list/","/api/post/item_list/","/api/favorite/item_list/","/api/following/item_list/","/api/recommend/item_list/","api/preload/item_list","/api/recommend/user/","/api/recommend/embed_videos/","/api/live/detail/","/api/im/multi_user/","/api/user/get/animation/","/api/user/settings/","/aweme/v1/music/list/","/aweme/v1/adult/verify/get/accepted/id/types/","/api/mix/detail","/api/mix/item_list","/api/uniqueid/check/","/api/user/playlist/","/api/reflow/item/detail/","/api/reflow/user/detail/","/api/reflow/recommend/item_list/","/api/reflow/challenge/item_list/","/api/reflow/post/item_list/","/api/reflow/sticker/item_list/","/api/reflow/playlist/item_list/","/api/reflow/survey/detail/","/api/reflow/repost/item_list/","/api/impression/write/","/api/user/set/animation/","/api/aweme/set/react_duet_stitch/","/api/aweme/modify/visibility/","/api/aweme/delete/","/api/schedule/aweme/delete/","/passport/web/login_name/update/","/api/update/profile/","/api/commit/follow/request/approve/","/api/commit/follow/request/reject/","/api/commit/follow/user/","/tiktok/v1/username/save_async/","/api/ba/business/suite/account/off","/api/ba/business/suite/account/quitcheck","/api/playlist/create_with_items/","/api/playlist/update/","/api/playlist/modify_items/","/api/item/collect","/node/report/reasons","/aweme/v1/aweme/feedback/","/aweme/v2/aweme/feedback/","/webcast.*","/v1/message/send","/v2/conversation/create","/v1/voip/call","/v1/conversation/add_participants","/1/conversation/remove_participants","/v1/conversation/update_participant","/v1/conversation/set_setting_info","/v1/conversation/get_setting_info","/v1/conversation/upsert_core_ext_info","/v1/conversation/upsert_settings_ext","/v1/conversation/dissolve","/v1/message/mark","/v1/message/batch_unmark","/v1/message/set_property","/api-live/event/list","/api-live/event/related-videos","/api-live/event/detail","/api-live/share/live","/api-live/user/room","/node-a/send/download_link","/api/uniqueid/check/","/api/v3/register/user/info/sync/","/api/policy/notice/approve/","/api/private_banner/ack/","/api/privacy/agreement/record/agree/v1","/api/v3/register/verification/age/","/api/register/check/login/name/","/api/user/detail/self/","/passport/web/","/shorten/","/api/seo/kap/product_list/","/bi/notification/reporter/record","/api/repost/item_list"],r=["/passport/web/account/info/"],s=[/^\/webcast\/diamond/,/^\/webcast\/wallet_api\/(?!fs\/)/,/^\/webcast\/recharge/,/^\/webcast\/wallet_api_tiktok\/notifycenter/,/^\/webcast\/wallet_api_tiktok\/payment/,/^\/webcast\/wallet_api_tiktok\/periodic_payout_onboarding/,/^\/webcast\/wallet_api_tiktok\/payout_onboarding_confirm/,/^\/webcast\/wallet_api_tiktok\/payment_instrument_bind_url/],l=["/webcast/api/money/kyc/v1/info/detail","/webcast/api/money/kyc/v1/upload_file","/webcast/api/compliance/kyc/v1/submission","/webcast/room/chat/","/webcast/room/create_info/","/webcast/room/enter/","/webcast/room/leave/","/webcast/room/live_podcast/","/webcast/room/ping/audience/","/webcast/user/relation/update/","/webcast/room/emote_chat/","/webcast/room/share/",...s,"/webcast/wallet_api_tiktok/payment/initialize_payment","/webcast/wallet_api_tiktok/payment/initialize_agreement","/webcast/wallet_api_tiktok/payment/payment_methods/primary/set","/webcast/wallet_api_tiktok/payment/payment_methods/delete","/webcast/wallet_api_tiktok/payment/payment_methods/link","/webcast/wallet_api_tiktok/income_plus/tax/get_tax/","/webcast/wallet_api_tiktok/income_plus/tax/create_tax/","/webcast/wallet_api_tiktok/income_plus/tax/update_tax/","/webcast/wallet_api_tiktok/income_plus/agreement/","/webcast/wallet_api_tiktok/payout_onboarding_confirm/"],c=[...s,"/webcast/wallet_api_tiktok/periodic_payout_onboarding/","/webcast/wallet_api_tiktok/payment_instrument_bind_url/","/webcast/wallet_api_tiktok/payment/payment_methods","/webcast/wallet_api_tiktok/notifycenter/notices/","/webcast/wallet_api_tiktok/income_plus/get_user_region_info/","/webcast/wallet_api_tiktok/income_plus/account_steps/","/webcast/wallet_api_tiktok/income_plus/user/"],d=["/api/private_banner/ack/","/cloudpush/update_sender_token/","/cloudpush/app_notice_status/","/api/user/set/settings/","/api/reddot/report","/api/comment/digg/","/api/comment/publish/","/api/comment/delete/","/api/aweme/delete/","/api/schedule/aweme/delete/","/api/privacy/user/private_account/update/v1","/api/privacy/user/settings/update/v1","/api/im_setting/update/v1","/api/privacy/agreement/record/agree/v1","/api/commit/follow/request/approve/","/api/commit/follow/request/reject/","/api/commit/follow/user/","/api/impression/write/","/api/user/set/animation/","/api/aweme/set/react_duet_stitch/","/api/aweme/modify/visibility/","/passport/web/login_name/update/","/api/update/profile/","/api/upload/image/","/tiktok/v1/username/save_async/","/api/commit/ads/action/","/tiktok/v1/kids/commit/item/digg/","/api/im/stranger/unlimit/"],u={"webcast.tiktok.com":{POST:l,GET:c},"webcast-t.tiktok.com":{POST:l,GET:c},"webcast-m.tiktok.com":{POST:l,GET:c},"webcast.us.tiktok.com":{POST:["/webcast/room/chat/","/webcast/room/create_info/","/webcast/room/enter/","/webcast/room/leave/","/webcast/room/live_podcast/","/webcast/room/ping/audience/","/webcast/user/relation/update/","/webcast/room/emote_chat/","/webcast/room/share/",...s],GET:c},"www.tiktok.com":{POST:d},"us.tiktok.com":{POST:d},"m.tiktok.com":{POST:d},"t.tiktok.com":{POST:d}},p=[{aid:1988,dfp:!1,boe:!1,intercept:!0,enablePathList:a,isHighRisk:!1,isSDK:!1},{aid:368462,dfp:!1,boe:!1,intercept:!0,enablePathList:["/payment/v1/"],isHighRisk:!1,isSDK:!1}],v=["/api/aweme/modify/visibility/","/api/ba/business/suite/account/off","/api/ba/business/suite/account/quitcheck","/api/playlist/create_with_items/","/api/schedule/aweme/delete/","/api/update/profile/","/api/user/set/settings/","/api/collection/create/","/api/collection/move_items/","/api/collection/modify_items/","/api/collection/modify_info/","/api/collection/delete/","/api/dislike/item/"],m=["/webcast/gift/send/"],g=["/webcast/gift/send/"],h=o()([...v,...m,...g]),_={"www.tiktok.com":{POST:v},"webcast.tiktok.com":{POST:m},"webcast-t.tiktok.com":{POST:m},"webcast-m.tiktok.com":{POST:m},"webcast.us.tiktok.com":{POST:g}}},10646:(e,t,n)=>{"use strict";n.d(t,{Qq:()=>c,v7:()=>l,w1:()=>s});var i=n(58305);const o=()=>'""',a=()=>{},r=()=>{};class s{constructor(e,t){this.key=e,this.type=t,this.storageObject=null,this.getter=o,this.setter=a,this.remove=r,this.getter="local"===t?i._S:i.Hd,this.setter="local"===t?i.AP:i.J2,this.remove="local"===t?i.sc:i.X}get storage(){return this.storageObject||(this.storageObject=this.tryParseJson(this.getter(this.key,"{}"))),this.storageObject}getStorage(){return this.storage}setItem(e,t){this.storage[e]=t,this.setter(this.key,JSON.stringify(this.storage))}getItem(e){return this.storage[e]}removeItem(e){this.storage[e]=void 0,this.setter(this.key,JSON.stringify(this.storage))}removeAll(){this.storageObject=null,this.remove(this.key)}tryParseJson(e){try{return JSON.parse(e)}catch(e){return{}}}}const l=new s("webapp-common-config","local"),c=new s("webapp-common-config","session")},32862:(e,t,n)=>{"use strict";n.d(t,{GA:()=>d,HL:()=>c,OW:()=>l});var i=n(93608),o=n(11732),a=n(71281),r=n(58305);const s="AB_TEST_PREFIX_";function l(e,t){const n=i.f.getVar(e,t);return"val"in n?n.val:{}}function c(e,t){const n=i.f.getVar(e,t);return"vid"in n?n.vid:""}function d(e){var t,n;const{useDefaultValue:i,value:c}=(0,a.kX)(e),d="undefined"!=typeof window;if(i)return l(e,{}).vid;if(c){const i=null!==(n=null===(t=o.JO.find((t=>t.name===e)))||void 0===t?void 0:t.vid)&&void 0!==n?n:[];return i.includes(c)?(d&&(0,r.J2)(`${s}${e}`,c),c):((0,a.c3)(d,e,i),l(e,{}).vid)}return d&&(0,r.Hd)(`${s}${e}`)?(0,r.Hd)(`${s}${e}`):l(e,{}).vid}},71281:(e,t,n)=>{"use strict";n.d(t,{TQ:()=>x,V7:()=>p,_F:()=>y,c3:()=>w,d:()=>k,kX:()=>b,qt:()=>T,tU:()=>m});var i=n(4474),o=n(47172),a=n(11732),r=n(11983),s=n(35267),l=n(57431),c=n(49057),d=n(48615),u=n(60484);function p(e,t){var n,i;return null===(i=null===(n=null==e?void 0:e.parameters)||void 0===n?void 0:n[t])||void 0===i?void 0:i.vid}const v=()=>"undefined"!=typeof window,m=()=>v()&&window.location.host.startsWith("localhost")||"1"===String(void 0);let g=!1;const h="AB_TEST_PREFIX_",_="FEATURE_FLAG_TEST_PREFIX",f=["0","1"],y=()=>{const{env:e}=(0,u.L$)((0,c.W)((()=>["env"]),[])),{type:t}=(0,u.L$)(e),{canUseQuery:n=!1}=(0,u.L$)((0,d.U)((()=>["canUseQuery"]),[])),i="ppe"===t||"boe"===t||m();return{isDebugEnv:i||n,isDebugPanelEnable:i}};function b(e){const{search:t}=(0,o.useLocation)(),n=(0,u.L$)((0,i.parse)(t)),{isDebugEnv:a}=y();let r=n[e];return Array.isArray(r)&&(r=r[r.length-1]),{searchObj:n,useDefaultValue:!a,value:r}}function w(e,t,n){e&&!g&&(g=!0,r.F.open({content:`feature flag value you provided for ${t} is not valid, valid value are: ${JSON.stringify(n)}`,duration:5,widthType:"padding"}))}function x(e){var t;const{useDefaultValue:n,value:i}=b(e),o=v(),a=(0,d.U)((()=>["config"]),[]),r=null===(t=null==a?void 0:a.config)||void 0===t?void 0:t.featureFlags,s=null==r?void 0:r[e];return n?s:i?f.includes(i)?(o&&sessionStorage.setItem(`${_}${e}`,i),Boolean(Number(i))):(w(o,e,f),s):o&&sessionStorage.getItem(`${_}${e}`)?Boolean(Number(sessionStorage.getItem(`${_}${e}`))):s}function T(e,t){var n,i;const{useDefaultValue:o,value:r}=b(t),s=v();if(o)return p(e,t);if(r){const o=null!==(i=null===(n=a.JO.find((e=>e.name===t)))||void 0===n?void 0:n.vid)&&void 0!==i?i:[];return o.includes(r)?(s&&sessionStorage.setItem(`${h}${t}`,r),r):(w(s,t,o),p(e,t))}return s&&sessionStorage.getItem(`${h}${t}`)?sessionStorage.getItem(`${h}${t}`):p(e,t)}function k(e){const{query:t}=(0,s.xw)(),{abTestVersion:n,env:i}=(0,l.x)(),o=v(),a="ppe"===(null==i?void 0:i.type)||"boe"===(null==i?void 0:i.type)||m();return o&&sessionStorage.getItem(`${h}${e}`)?sessionStorage.getItem(`${h}${e}`):a&&t[e]?t[e]:p(n,e)}},22248:(e,t,n)=>{"use strict";n.d(t,{G:()=>o,d:()=>i});const i=e=>null,o=(e,t,n)=>{}},60484:(e,t,n)=>{"use strict";n.d(t,{D1:()=>m,L$:()=>o});const i=Object.freeze({});function o(e){return null!=e?e:i}function a(e,t=1){return Math.round(Number(`${e}e${t}`))/Math.pow(10,t)}const r=1e3,s="K",l="k",c=1e3*r,d="M",u=1e3*c,p="B",v=BigInt(4294967296);function m(e=0,t){const{isLowerThousandUnit:n=!1}=null!=t?t:{};let i,o=Number(e);return o<0&&(o=Number(v+BigInt(e))),i=o<1e4?o.toString():o{"use strict";n.d(t,{AP:()=>y,Gu:()=>S,Gz:()=>s,Hd:()=>w,J2:()=>x,Lm:()=>c,Qy:()=>k,UP:()=>r,X:()=>T,Zn:()=>g,_S:()=>f,a6:()=>h,aP:()=>d,aV:()=>_,dG:()=>E,hY:()=>p,jf:()=>l,mS:()=>u,nr:()=>a,sc:()=>b,wo:()=>A,y5:()=>m});var i=n(57432),o=n.n(i);function a(){return navigator.vendor&&-1!==navigator.vendor.indexOf("Apple")&&navigator.userAgent&&-1===navigator.userAgent.indexOf("CriOS")&&-1===navigator.userAgent.indexOf("FxiOS")}function r(){return!!navigator.userAgent&&(-1!==navigator.userAgent.indexOf("Edge")||-1!==navigator.userAgent.indexOf("Edg/"))}function s(e=o(),t=o()){let n,i;function a(){n&&document[n]?e():t()}return"hidden"in document?(n="hidden",i="visibilitychange"):"msHidden"in document?(n="msHidden",i="msvisibilitychange"):"webkitHidden"in document&&(n="webkitHidden",i="webkitvisibilitychange"),"addEventListener"in document&&n&&i?(document.addEventListener(i,a,!1),document.removeEventListener.bind(document,i,a,!1)):o()}function l(e,t){let n={top:0,bottom:0,left:0,right:0};try{n=e.getBoundingClientRect()}catch(e){}let{top:i,bottom:o}=n;const{height:a}=n;return i-=t,o-=t,i=Math.abs(i),o<=0||i>=a?0:Number((o/a).toFixed(2))}function c(){return window.innerHeight{const a=p(),r=Date.now(),s=null!=o?o:window,l=()=>{const o=Date.now()-r;if(o>=t)return i?s.scrollTo({top:e,behavior:"smooth"}):s.scrollTo(0,e),void(null==n||n());const c=a+o/t*(e-a);i?s.scrollTo({top:c,behavior:"smooth"}):s.scrollTo(0,c),requestAnimationFrame(l)};l()};function p(){const e=document.documentElement||document.body.parentNode||document.body;return void 0!==window.pageYOffset?window.pageYOffset:e.scrollTop}const v="webapp-scroll_invoke_by_click";function m(){return w(v)}function g(){T(v)}function h(e=0,t=100,n=window){const i=p(),o=Date.now(),a=()=>{x(v,"done"),n.removeEventListener("scrollend",a)};x(v,"start"),n.addEventListener("scrollend",a),function a(){const r=Date.now()-o;if(r>=t)return void n.scrollTo({top:e,behavior:"smooth"});const s=(t-r)/t*(e-i)+i;n.scrollTo({top:s,behavior:"smooth"}),requestAnimationFrame(a)}()}function _(e=0,t=100,n=window){if(!("scrollTop"in n)||!("style"in n))return h(e,t,n);const i=n.scrollTop,o=Date.now();n.style.scrollSnapType="none";const a=()=>{x(v,"done"),n.removeEventListener("scrollend",a)};x(v,"start"),n.addEventListener("scrollend",a),function a(){const r=Date.now()-o;if(r>=t)return n.scrollTo({top:e,behavior:"instant"}),void("style"in n&&(n.style.scrollSnapType=""));const s=r/t*(e-i)+i;n.scrollTo({top:s,behavior:"instant"}),requestAnimationFrame(a)}()}function f(e,t=""){var n;try{return null!==(n=localStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}function y(e,t){try{localStorage.setItem(e,t)}catch(e){}}function b(e){try{localStorage.removeItem(e)}catch(e){}}function w(e,t=""){var n;try{return null!==(n=sessionStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}function x(e,t){try{sessionStorage.setItem(e,t)}catch(e){}}function T(e){try{sessionStorage.removeItem(e)}catch(e){}}function k(e){const t=w(e);return T(e),t}const S=e=>{e.preventDefault(),e.stopPropagation()},E=e=>{e.stopPropagation()},A=e=>{e.preventDefault()}},97086:(e,t,n)=>{"use strict";function i(){return"undefined"==typeof window||"undefined"==typeof document}function o(){var e;if(i())return!1;const t=document.querySelector("#app");return"1"===(null===(e=null==t?void 0:t.dataset)||void 0===e?void 0:e.downgrade)}function a(){return!i()&&null!==document.querySelector('script[data-chunk="ssg"]')}function r(){return/Windows/i.test(window.navigator.userAgent)}function s(e){var t,n;return!i()&&!!e&&"1"!==(null===(n=null===(t=document.querySelector("#app"))||void 0===t?void 0:t.dataset)||void 0===n?void 0:n.downgrade)}n.d(t,{$y:()=>a,Yh:()=>r,_8:()=>s,fU:()=>i,qk:()=>o})},53764:(e,t,n)=>{"use strict";n.d(t,{M:()=>o,e:()=>i});const i=function(e){if(!e)return{fullscreenEnabled:"fullscreenEnabled",fullscreenElement:"fullscreenElement",requestFullscreen:"requestFullscreen",exitFullscreen:"exitFullscreen",fullscreenchange:"fullscreenchange",fullscreenerror:"fullscreenerror"};const t={w3:{fullscreenEnabled:"fullscreenEnabled",fullscreenElement:"fullscreenElement",requestFullscreen:"requestFullscreen",exitFullscreen:"exitFullscreen",fullscreenchange:"fullscreenchange",fullscreenerror:"fullscreenerror"},webkit:{fullscreenEnabled:"webkitFullscreenEnabled",fullscreenElement:"webkitCurrentFullScreenElement",requestFullscreen:"webkitRequestFullscreen",exitFullscreen:"webkitExitFullscreen",fullscreenchange:"webkitfullscreenchange",fullscreenerror:"webkitfullscreenerror"},moz:{fullscreenEnabled:"mozFullScreenEnabled",fullscreenElement:"mozFullScreenElement",requestFullscreen:"mozRequestFullScreen",exitFullscreen:"mozCancelFullScreen",fullscreenchange:"mozfullscreenchange",fullscreenerror:"mozfullscreenerror"},ms:{fullscreenEnabled:"msFullscreenEnabled",fullscreenElement:"msFullscreenElement",requestFullscreen:"msRequestFullscreen",exitFullscreen:"msExitFullscreen",fullscreenchange:"MSFullscreenChange",fullscreenerror:"MSFullscreenError"}};for(const n of Object.values(t))if(n.fullscreenEnabled in e)return n;return{fullscreenEnabled:"fullscreenEnabled",fullscreenElement:"fullscreenElement",requestFullscreen:"requestFullscreen",exitFullscreen:"exitFullscreen",fullscreenchange:"fullscreenchange",fullscreenerror:"fullscreenerror"}}("undefined"==typeof document?void 0:document),o=()=>{var e;return"undefined"!=typeof document?null!==(e=document[null==i?void 0:i.fullscreenElement])&&void 0!==e?e:document.body:null}},35323:(e,t,n)=>{"use strict";n.d(t,{uQ:()=>o,xt:()=>s});var i=n(93987);function o(e){return performance.mark(e)}function a(e){const{start:t,end:n}=e;try{return performance.measure(`${t}-${n}`,t,n)}catch(e){}}function r(e){return e<0?0:e}function s(){var e,t;const n=[i.Y.PlayerDestroy,i.Y.PlayerMounted,i.Y.OneColumnRerender,i.Y.BrowseModeRerender,i.Y.VideoRequest,i.Y.VideoFirstFrame].map((e=>{var t,n;return r(null!==(n=null===(t=a({start:i.Y.PlayerChange,end:e}))||void 0===t?void 0:t.duration)&&void 0!==n?n:0)})),[o,s,l,c,d,u]=n;return{destroy_time:o,mounted_time:s,one_column_rerender_time:l,browse_mode_rerender_time:c,video_request_time:d,video_first_frame_time:u,player_first_frame_time:r(null!==(t=null===(e=a({start:i.Y.VideoRequest,end:i.Y.VideoFirstFrame}))||void 0===e?void 0:e.duration)&&void 0!==t?t:0)}}},37745:(e,t,n)=>{"use strict";function i(e,t){return 2===e||6===e||5!==e&&t}function o(e,t){return 2===e||6===e?1:5===e?0:t}n.d(t,{L:()=>o,z:()=>i})},49057:(e,t,n)=>{"use strict";n.d(t,{W:()=>s});var i=n(32877),o=n.n(i),a=n(40099),r=n(57431);function s(e,t){const n=(0,r.x)();return(0,a.useMemo)((()=>n?o()(n,...e()):n),t)}},90535:(e,t,n)=>{"use strict";n.d(t,{a:()=>p,h:()=>v});var i=n(58632),o=n(1055),a=n(94999),r=n(9685),s=n(17354),l=n(62564),c=n(51660),d=n(10598),u=n(54888);function p(e){var t,n;return(0,i.__awaiter)(this,void 0,void 0,(function*(){if(null===(n=null===(t=window[o.H2])||void 0===t?void 0:t.BizContext)||void 0===n?void 0:n.initialized)return;const i=(0,c.qm)(),l=a.l.getInstance(u.$),p=yield(0,d.x)(i,e);l.store.dispatch(l.getActions().setBizContext(p)),l.store.dispatch(l.getActions().setInitialized(!0)),yield(0,r._)(l.state$.pipe((0,s.p)((e=>!!e.initialized))))}))}function v(){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const e=a.l.getInstance(u.$);return(0,r._)(e.state$.pipe((0,s.p)((e=>!!e.bizContext)),(0,l.T)((e=>e.bizContext))))}))}},48615:(e,t,n)=>{"use strict";n.d(t,{U:()=>l,y:()=>s});var i=n(13392),o=n(32877),a=n.n(o),r=n(54888);function s(){return(0,i.Ph)(r.$)}function l(e,t){return(0,i.Ph)(r.$,{selector:t=>{const{bizContext:n}=t;return n?a()(n,...e()):n},dependencies:t})}},54888:(e,t,n)=>{"use strict";n.d(t,{$:()=>x,A:()=>T});var i=n(58632),o=n(67134),a=n(64162),r=n(4126),s=n(93995),l=n(46657),c=n(63700),d=n(23999),u=n(26324),p=n(24451),v=n(35572),m=n(8536),g=n(74690),h=n(80339),_=n(7672),f=n(4474),y=n(68628);let b=class{getBizContext(e,t){return(0,y.H)(fetch((0,f.stringifyUrl)({url:"/node-webapp/api/biz-context",query:{lang:e,app_name:t}})).then((e=>e.json())))}};b=(0,i.__decorate)([(0,_._)()],b);var w=n(34360);let x=class extends a.E{constructor(e){super(),this.service=e,this.defaultState={bizContext:null,initialized:!1}}setBizContext(e,t){var{statusCode:n}=t,o=(0,i.__rest)(t,["statusCode"]);return 0!==n?e:Object.assign(Object.assign({},e),{bizContext:o})}setInitialized(e,t){return Object.assign(Object.assign({},e),{initialized:t})}init(e){return e.pipe((0,p.E)(this.state$),(0,v.p)((([{lang:e,app_name:t},{initialized:n}])=>n?l.w:this.service.getBizContext(e,t).pipe((0,m.Z)((e=>(0,c.h)((0,d.of)(this.getActions().setBizContext(e))))),(0,g.Z)(this.getActions().setInitialized(!1)),(0,h.q)(this.getActions().setInitialized(!0),this.terminate())))))}};(0,i.__decorate)([(0,r.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",Object)],x.prototype,"setBizContext",null),(0,i.__decorate)([(0,r.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",Object)],x.prototype,"setInitialized",null),(0,i.__decorate)([(0,r.Mj)({payloadGetter:1}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],x.prototype,"init",null),x=(0,i.__decorate)([(0,s.n)("BizContext"),(0,i.__metadata)("design:paramtypes",[b])],x);const T=(0,o.U)("readBizContextModuleAtom@tiktok/webapp-common",(()=>(0,w.y)(x)))},83658:(e,t,n)=>{"use strict";n.d(t,{OC:()=>x,h$:()=>T});var i,o=n(58632),a=n(70322),r=n(71111),s=n(31209),l=n(40407),c=n(40040),d=n(56203);!function(e){e[e.S=1]="S",e[e.T=2]="T",e[e.X=3]="X",e[e.R=4]="R"}(i||(i={}));const u={s:i.S,t:i.T,x:i.X,r:i.R},p=e=>{var t;return null!==(t=u[e.toLowerCase()])&&void 0!==t?t:null},v="/node-webapp/api/inference",m="last_inference";var g=n(4474),h=n(58305);const _=(e,t)=>{if(e.length!==t.length)throw new Error("Array and mask must be of the same length.");return e.filter(((e,n)=>"1"===t[n]))},f=e=>{var t,n,i;const o=atob(e),a=[];for(let e=0;ee.json()));return 0===o.statusCode&&Array.isArray(o.result)?o.result:(console.error(`Unable to get causal inference: ${o.statusCode}`),[-1])}catch(e){return console.error("Error fetching inference result:",e),[-1]}}))}var b;!function(e){e.Base="base",e.Model="model"}(b||(b={}));const w=(0,r.atom)({});w.debugLabel="spaExperimentAtom";const{useServiceDispatchers:x,useServiceState:T}=(0,s.i)(w,((e,t)=>({getAbTestVidWithQuerySPA({projectName:n,isInSpaExperiment:i,expVid:o,wid:a,globalModelInfo:r,vgeo:s,user:l,disableAutoTrigger:c=!1}){const d=e(w);if(null==d?void 0:d[n])return;let u=b.Base,p=o,v=[],m=1,g=[];if(i){const{projectLevelModelInfo:e}=((e,t)=>{let n={};if("string"==typeof e)try{n=JSON.parse(e)}catch(e){console.error("Error: Failed to parse uplift model info.",e)}else"object"==typeof e&&null!==e&&(n=e);return{projectLevelModelInfo:null==n?void 0:n[t]}})(null!=r?r:{},n)||{},{inference_effective_duration:t,inference_disabled_vgeo_list:i}=e||{},{type:a,default_vid:s,treatment_list:l}=(null==e?void 0:e[o])||{};a&&(u=a),s&&(p=s),Array.isArray(l)&&(v=l),t&&(m=t),Array.isArray(i)&&(g=i)}t(w,(e=>Object.assign(Object.assign({},e),{[n]:{projectName:n,vid:p,wid:a,experimentType:u,inferenceCount:0,treatmentList:v,inferenceEffectiveDuration:m,inferenceDisabledVGeoList:g}}))),c||this.maybeTriggerInference({projectName:n,vgeo:s,user:l})},maybeTriggerInference({projectName:n,vgeo:i="",user:r,enterMethod:s="",pageName:u=""}){return(0,o.__awaiter)(this,void 0,void 0,(function*(){const v=e(w)[n];if(!v)return void console.log("Error. Unable to find the experiment: ",n);const{wid:g,experimentType:x,vid:T,inferenceCount:k,treatmentList:S,inferenceEffectiveDuration:E,inferenceDisabledVGeoList:A}=v;let O=(0,l.ZC)(g,c.uV,d.gb);if(S&&S[0]){const e=Number(S[0].feature_number||0);e&&e>0&&(null==O?void 0:O.length)>0&&(O=null==O?void 0:O.slice(0,e))}if(x===b.Base)a.w.handleInferenceTrigger({enter_method:s,page_name:u,model_name:`${n}_${T}`,full_payload:null==O?void 0:O.toString(),payload:null==O?void 0:O.toString(),threshold_exceed:-1,inference_result:-1});else if(x===b.Model&&0===k&&((e,t="",n=!1)=>!!n||!e.includes(t))(A,i,!!r)){const{isCacheValid:e,cachedVid:i}=((e,t=1,n,i="",o="")=>{try{const r=(0,h._S)(m)||"{}",s=JSON.parse(r)[e],l=null==s?void 0:s.timestamp,c=null==s?void 0:s.vid;if(!c||!l)return{isCacheValid:!1};const d=24*t*60*60*1e3;return Date.now()-parseInt(l,10)<=d?(a.w.handleInferenceDisqualify({enter_method:n,model_name:i,reason:"inference_cached",page_name:o}),{isCacheValid:!0,cachedVid:c}):{isCacheValid:!1}}catch(e){return console.error("Error in getValidInferenceCache:",e),{isCacheValid:!1}}})(n,E,s,`${n}_${T}`,u);if(e&&i)return void t(w,(e=>Object.assign(Object.assign({},e),{[n]:Object.assign(Object.assign({},v),{vid:i,inferenceCount:k+1})})));const{isSuccessful:r,resultVid:b}=(yield function(e,t,n,i=[],r,s){var u;return(0,o.__awaiter)(this,void 0,void 0,(function*(){let o={vid:t,inference_result:-1/0},v=!0;for(const e of i){const{treatment_vid:t,model_name:i="",model_type:m="",feature_number:g=0,prediction_threshold:h=0,feature_mask:b=""}=null!=e?e:{},w=(0,l.ZC)(n||"",c.uV,d.gb);if(0===w.length){a.w.handleInferenceDisqualify({enter_method:r,model_name:i,reason:"failed_to_generate_payload",page_name:s});continue}let x=[],T=[];try{const e=(null===(u=f(b||""))||void 0===u?void 0:u.slice(0,g))||[];T=_(w,e);const t=p(m);if(0===T.length||!i||!t)throw new Error(`Missing key parameters, unable to call inference API! maskedPayload.length: ${T.length}, modelName: ${i}, modelType: ${t}`);x=yield y(T,i,t)}catch(e){console.error("Unable to call inference API!",e),a.w.handleInferenceTrigger({enter_method:r,page_name:s,model_name:i,full_payload:w.toString(),payload:T.toString(),threshold_exceed:0,inference_result:-1});continue}const[k]=x,S=void 0!==k&&-1!==k,E=!!S&&k>h;a.w.handleInferenceTrigger({enter_method:r,page_name:s,model_name:i,full_payload:w.toString(),payload:T.toString(),threshold_exceed:E?1:0,inference_result:k}),S?E&&k>o.inference_result&&(o={vid:t,inference_result:k}):v=!1}return v&&((e,t)=>{const n=m,i=(0,h._S)(n)||"{}",o=JSON.parse(i);o[e]={timestamp:Date.now().toString(),vid:t},(0,h.AP)(n,JSON.stringify(o))})(e,o.vid),{isSuccessful:v,resultVid:o.vid}}))}(n,T,g,S,s,u))||{};t(w,(e=>Object.assign(Object.assign({},e),{[n]:Object.assign(Object.assign({},v),{vid:b||v.vid,inferenceCount:r?k+1:k})})))}}))},disqualifyForInference:(e,t,n,i)=>{a.w.handleInferenceDisqualify({enter_method:t,model_name:e,reason:i,page_name:n})}})))},23294:(e,t,n)=>{"use strict";n.d(t,{S:()=>u,w:()=>d});var i=n(40099),o=n(32125),a=n(83658),r=n(49057),s=n(48615),l=n(60484),c=n(71281);const d=e=>{var t;const{abTestVersion:n}=(0,l.L$)((0,r.W)((()=>["abTestVersion"]),[])),o=null!==(t=u(n,e))&&void 0!==t?t:"v0",{isInExperiment:a,isInControl:s,isInTreatment:c}=(0,i.useMemo)((()=>({isInControl:"v0"===o,isInTreatment:"v1"===o,isInExperiment:"v0"===o||"v1"===o})),[o]);return{baseExpId:e,isInControl:s,isInTreatment:c,isInExperiment:a}};function u(e,t,n,i){const{wid:d,user:u}=(0,l.L$)((0,r.W)((()=>["wid","user"]),[])),{upliftModelInfo:p={},vgeo:v=""}=(0,l.L$)((0,s.U)((()=>["upliftModelInfo","vgeo"]),[])),m=null!=i?i:`${t}_spa`,g=(0,c.qt)(e,t),h=(0,c.qt)(e,m),_=(0,a.OC)();h?_.getAbTestVidWithQuerySPA({projectName:t,isInSpaExperiment:!0,expVid:h,wid:d,globalModelInfo:p,vgeo:v,user:u,disableAutoTrigger:n}):g&&_.getAbTestVidWithQuerySPA({projectName:t,isInSpaExperiment:!1,expVid:g,wid:d,globalModelInfo:p,vgeo:v,user:u,disableAutoTrigger:n});const{vid:f}=(0,l.L$)((0,a.h$)((e=>e[t]),o.bN));return f}},59952:(e,t,n)=>{"use strict";n.d(t,{w:()=>f,x:()=>y});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(35572),l=n(23999),c=n(62564),d=n(26324),u=n(34360),p=n(67134),v=n(10646),m=n(7672),g=n(26325),h=n(55099);let _=class{constructor(e){this.fetch=e}postUserSetting(e){return this.fetch.post("/api/user/set/settings/",{query:Object.assign(Object.assign({},e),{tt_csrf_token:this.fetch.csrfToken}),headers:{[g.nk]:this.fetch.csrfToken},baseUrlType:2})}};_=(0,i.__decorate)([(0,m._)(),(0,i.__metadata)("design:paramtypes",[h.p])],_);let f=class extends o.E{constructor(e){super(),this.service=e,this.defaultState={photoSensitiveVideosSetting:v.v7.getItem("photo_sensitive_video_setting"),hideMaskTempVideoId:"",loginStatePhotoSensitiveVideosSetting:void 0,hasClosedVideoMask:!1}}setSkipPhotoSensitiveAction(e,t){const{skipPhotoSensitiveVideo:n,login:i=!1}=t,o=n?1:2;e.photoSensitiveVideosSetting=o,i&&(e.loginStatePhotoSensitiveVideosSetting=o)}setHideMaskTempVideoId(e,t){e.hideMaskTempVideoId=t}setHasClosedMask(e,t){e.hasClosedVideoMask=t}setPhotoSensitiveVideosSetting(e,t){e.photoSensitiveVideosSetting=t}setLoginStatePhotoSensitiveVideosSetting(e,t){e.loginStatePhotoSensitiveVideosSetting=t}setSkipPhotoSensitive(e){return e.pipe((0,s.p)((({skip:e,hasLogin:t})=>{const n=e?1:2;return v.v7.setItem("photo_sensitive_video_setting",n),t?this.service.postUserSetting({field:"photosensitive_videos_setting",value:n}).pipe((0,c.T)((({status_code:t})=>0===t?this.getActions().setSkipPhotoSensitiveAction({skipPhotoSensitiveVideo:e,login:!0}):this.noop()))):(0,l.of)(this.getActions().setSkipPhotoSensitiveAction({skipPhotoSensitiveVideo:e}))})))}};(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"setSkipPhotoSensitiveAction",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"setHideMaskTempVideoId",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"setHasClosedMask",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Number]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"setPhotoSensitiveVideosSetting",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Number]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"setLoginStatePhotoSensitiveVideosSetting",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[d.c]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"setSkipPhotoSensitive",null),f=(0,i.__decorate)([(0,r.n)("VideoMaskModule"),(0,i.__metadata)("design:paramtypes",[_])],f);const y=(0,p.U)("videoMaskModuleAtom@tiktok/fe-shared",(()=>(0,u.y)(f)))},78305:(e,t,n)=>{"use strict";n.d(t,{y7:()=>I,wl:()=>P});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(340),l=n(35626),c=n.n(l),d=n(23999),u=n(46657),p=n(26324),v=n(24451),m=n(8536),g=n(20259),h=n(74690),_=n(80339),f=n(35572),y=n(25342),b=n(11983),w=n(64356),x=n(37568),T=n(4712),k=n(68878),S=n(21512),E=n(81792);const A={app_id:1988,aid:1988,app_name:"tiktok_web",device_id:0,device_platform:"tiktok_web",device_type:"tiktok_web"};var O;!function(e){e[e.Reason=0]="Reason",e[e.Normal=1]="Normal",e[e.DSASubmit=2]="DSASubmit",e[e.ChooseCountry=3]="ChooseCountry"}(O||(O={}));const P={Desc:1};let I=class extends o.E{constructor(e,t){var n;super(),this.service=e,this.t=t,this.defaultState={reasons:null,showing:!1,loading:!1,requesting:void 0,reportTarget:null,lastStatus:"",PageState:0,PageStateData:void 0,PreState:[],UserData:{selectedReason:void 0,submitresult:void 0,HistoryReason:[]},blockedVideos:[],submitCallback:void 0,choosenDSACountry:void 0,DSACountriesList:(n=this.t,[{code:"AT",desc:n("region_at")},{code:"BE",desc:n("region_be")},{code:"BG",desc:n("region_bg")},{code:"HR",desc:n("region_hr")},{code:"CY",desc:n("region_cy")},{code:"CZ",desc:n("region_cz")},{code:"DK",desc:n("region_dk")},{code:"EE",desc:n("region_ee")},{code:"FI",desc:n("region_fi")},{code:"FR",desc:n("region_fr")},{code:"DE",desc:n("region_de")},{code:"GR",desc:n("region_gr")},{code:"HU",desc:n("region_hu")},{code:"IS",desc:n("region_is")},{code:"IE",desc:n("region_ie")},{code:"IT",desc:n("region_it")},{code:"LV",desc:n("region_lv")},{code:"LI",desc:n("region_li")},{code:"LT",desc:n("region_lt")},{code:"LU",desc:n("region_lu")},{code:"MT",desc:n("region_mt")},{code:"NL",desc:n("region_nl")},{code:"NO",desc:n("region_no")},{code:"PL",desc:n("region_pl")},{code:"PT",desc:n("region_pt")},{code:"RO",desc:n("region_ro")},{code:"SK",desc:n("region_sk")},{code:"SI",desc:n("region_si")},{code:"ES",desc:n("region_es")},{code:"SE",desc:n("region_se")}]),isRereport:!1,rereportQuery:{},uuid:""}}setIsRereport(e,t){e.isRereport=t}setRereportQuery(e,t){e.rereportQuery=t}setSubmitCallback(e,t){e.submitCallback=t}setChoosenDSACountry(e,t){e.choosenDSACountry=t}setReportTarget(e,t){e.reportTarget=t}setReasons(e,t){e.reasons=t,e.PageStateData={reasons:t}}addBlockVideo(e,t){e.blockedVideos.includes(t)||e.blockedVideos.push(t)}removeBlockVideo(e,t){e.blockedVideos=e.blockedVideos.filter((e=>e!==t))}setLoading(e,t){e.loading=t}setUuid(e,t){e.uuid=t}getReasons(e){return e.pipe((0,v.E)(this.state$),(0,m.Z)((([{reportTarget:e,uid:t},n])=>{var i;if(c()(e,n.reportTarget)&&n.reasons&&(null===(i=n.reasons)||void 0===i?void 0:i.length)>0)return(0,d.of)(this.getActions().setReasons(n.reasons));const o=Object.assign(Object.assign({},A),{app_language:e.lang||"",sys_language:e.lang||"",language:e.lang||"",user_id:Number(t)}),a=`${"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}-${Date.now()}`;return this.service.getReportReasons(o).pipe((0,g.W)((()=>(0,d.of)({status:"unknown_error"}))),(0,m.Z)((t=>{var n,i,o;if("success"===t.status){const r=(0,T.zW)(null==e?void 0:e.ad_info);let s;if(null===(n=null==e?void 0:e.ad_info)||void 0===n?void 0:n.log_extra)try{s=JSON.parse(e.ad_info.log_extra)}catch(e){s={}}else s={rit:(null==e?void 0:e.isVideoDetailBannerAds)?y.uY:y.OZ,req_id:null==r?void 0:r.req_id};s.uuid=a,x.J.handleAdReasonGet({tag:(null==e?void 0:e.isVideoDetailBannerAds)?"creative":e.play_mode&&y.EM[e.play_mode]||y.xY.OneColumn,category:y.XJ,refer:y.Hq.Button,log_extra:JSON.stringify(s),description:"",value:String(null===(i=null==e?void 0:e.ad_info)||void 0===i?void 0:i.creative_id),is_ad_event:"1"});let l=null!==(o=t.data)&&void 0!==o?o:[];const c=[S.YB.Violence,S.YB.DangerousGoodsOrServices,S.YB.MinorsToPurchase,S.YB.IntellectualPropertyInfringementOld],u=[S.YB.Violence,S.YB.DangerousGoodsOrServices,S.YB.MinorsToPurchase],p={reason_type:"ProhibitedOrInfringing",reason_type_id:"ProhibitedOrInfringing",text:this.t("report_Prohibited_or_infringing"),sub_reason:[]};let v={reason_type:"IPInfringement",reason_type_id:"IPInfringement",text:this.t("Intellectual Property Infringement"),sub_reason:[{reason_type:"IPInfringementRightOwner",reason_type_id:"IPInfringementRightOwner",text:this.t("report_Right_owner")}]};const m={reason_type:"ProhibitedOrViolence",reason_type_id:"ProhibitedOrViolence",text:this.t("report_Prohibited_or_violence"),sub_reason:[]},g={reason_type:"Misleading",reason_type_id:"Misleading",text:"",sub_reason:[]},h={reason_type:"Offensive",reason_type_id:"Offensive",text:"",sub_reason:[]};let _=l.map((e=>Object.assign(Object.assign({},e),{reason_type:e.reason_type||e.reason_type_id})));_.some((e=>e.reason_type_id===S.YB.IntellectualPropertyInfringementNew))?(_=_.filter((e=>u.includes(e.reason_type_id)?((m.sub_reason||[]).push(e),!1):e.reason_type_id!==S.YB.IntellectualPropertyInfringementNew||((v.sub_reason||[]).push(Object.assign(Object.assign({},e),{text:this.t("report_Not_right_owner")})),e.text&&(v.text=e.text),!1))),_.splice(4,0,v,m)):(_=_.filter((e=>!c.includes(e.reason_type_id)||((p.sub_reason||[]).push(e),!1))),_.splice(4,0,p)),_.some((e=>e.reason_type_id===S.YB.AISynthetic))&&(_=_.filter((e=>e.reason_type_id===S.YB.Misleading?(g.sub_reason.push(Object.assign(Object.assign({},e),{text:this.t("ad_report_reason_L1Misinfo_L2misinfo")})),e.reason_type_id===S.YB.Misleading&&(g.text=e.text),!1):e.reason_type_id!==S.YB.AISynthetic||(g.sub_reason.push(e),!1))),_.splice(3,0,g));let f=0;return _.some((e=>e.reason_type_id===S.YB.HateSpeechAndDiscrimination))&&(_=_.filter(((e,t)=>e.reason_type_id===S.YB.OffensiveContent?(f=t,h.sub_reason.push(Object.assign(Object.assign({},e),{text:this.t("ad_report_reason_Offensive_Content")})),h.text=e.text,!1):![S.YB.HateSpeechAndDiscrimination,S.YB.ChildrenRelatedOffensiveContent].includes(e.reason_type_id)||(h.sub_reason.push(e),!1))),_.splice(f,0,h)),(0,d.of)(this.getActions().setReasons(_))}return b.F.open({content:this.t("Sorry, something wrong with the server, please try again."),duration:2,widthType:"half"}),(0,d.of)(this.getActions().setReasons([]))})),(0,h.Z)(this.getActions().setLoading(!0)),(0,_.q)(this.getActions().setUuid(a),this.getActions().setLoading(!1)))})))}handleNextReason(e){return e.pipe((0,v.E)(this.state$),(0,m.Z)((([{nextReason:e},{PageStateData:t,PageState:n}])=>(0,d.of)(this.getActions().setPageStateData({reasons:e}),this.getActions().appendToPreState({state:n,data:t})))))}handleNextForm(e){return e.pipe((0,v.E)(this.state$),(0,m.Z)((([e,{PageStateData:t,PageState:n}])=>(0,d.of)(this.getActions().setPageState(e),this.getActions().setPageStateData({}),this.getActions().appendToPreState({state:n,data:t})))))}setShowing(e,t){e.showing=t}showReport(e){return e.pipe((0,m.Z)((({reportTarget:e,uid:t})=>(0,d.of)(this.getActions().setShowing(!0),this.getActions().getReasons({reportTarget:e,uid:t}),this.getActions().setReportTarget(e)))))}showRereport(e){return e.pipe((0,m.Z)((({rereportUrl:e,rereportObj:t})=>{const n=t||(0,E.U)(decodeURIComponent(e||""));return(0,d.of)(this.getActions().setIsRereport(!0),this.getActions().setShowing(!0),this.getActions().setRereportQuery(n),this.getActions().setPageState((0,S.f2)(Number(n.report_type_id))?2:1),this.getActions().setUserData({selectedReason:{reason_type_id:Number(n.report_type_id),text:n.report_type_name,desc:n.reasonDesc,link:n.learnLink}}))})))}hideReport(e){return e.pipe((0,m.Z)((()=>(0,d.of)(this.getActions().setShowing(!1)))))}setRequesting(e,t){e.requesting=t}setLastStatus(e,t){e.lastStatus=t}postReport(e){return e.pipe((0,v.E)(this.state$),(0,f.p)((([{isDsaMode:e,reason:t,text:n,extraData:i,region:o,uid:a,loggedOut:r,closeModal:s},{reportTarget:l,submitCallback:c,isRereport:p,rereportQuery:v,uuid:f}])=>{var w,k;if(!p&&!l)return u.w;const S=p?(e=>{if(e)try{const t=JSON.parse(e);return{req_id:JSON.parse(t.log_extra).req_id}}catch(e){return}})(v.extra||""):(0,T.zW)(null==l?void 0:l.ad_info),E=null==S?void 0:S.req_id,O=p?(e=>{if(e)try{return JSON.parse(e).log_extra}catch(e){return}})(v.extra||""):(null===(w=null==l?void 0:l.ad_info)||void 0===w?void 0:w.log_extra)||JSON.stringify({rit:(null==l?void 0:l.isVideoDetailBannerAds)?y.uY:y.OZ,req_id:E}),P=p?(e=>{if(e)try{return JSON.parse(e).cid}catch(e){return}})(v.extra||""):String(null===(k=null==l?void 0:l.ad_info)||void 0===k?void 0:k.creative_id),I={origin:"tiktok_web",data:JSON.stringify(Object.assign(Object.assign(Object.assign(Object.assign({app_name:"tiktok_web",aid:1988,current_region:o,reason:t},l),{target:null==l?void 0:l.object_id,report_type:"ad"}),{}),{report_from:"creative",user_id:a,user_ip:"",version:"",device_id:"",platform:"web",install_id:"",group_id:"",item_id:"",text:(null==i?void 0:i.description)||"",report_type_id:Number(t),report_type_name:n,extra:JSON.stringify({cid:P,log_extra:O,req_id:E}),content_type:"ad"}))},C=Object.assign(Object.assign({},A),{app_language:(null==l?void 0:l.lang)||"",sys_language:(null==l?void 0:l.lang)||"",language:(null==l?void 0:l.lang)||"",user_id:Number(a)});return this.service.postReport(I,C).pipe((0,g.W)((()=>(0,d.of)({status:"unknown_error"}))),(0,m.Z)((n=>{if(c)return null==c||c(n),(0,d.of)(this.noop());let o;if(o="success"===n.status?{title:this.t("Web_report_thanks_for_report"),content:r?this.t("dsa_illegal_report_received_confirm_logout"):this.t("dsa_illegal_report_received_confirm"),button:this.t("pm_mt_live_done"),success:!0}:{title:this.t("Web_report_report_for_error"),content:this.t("Sorry, something wrong with the server, please try again."),button:this.t("live_close"),success:!1},"success"===n.status){const n=e?{description:(null==i?void 0:i.description)||"",report_scene:(null==i?void 0:i.report_scene)||"",signature:(null==i?void 0:i.signature)||"",email:(null==i?void 0:i.email)||"",relevant_law:(null==i?void 0:i.relevant_law)||"",law_country_code:(null==i?void 0:i.law_country_code)||"",is_trusted_flagger:(null==i?void 0:i.is_trusted_flagger)||!1,reason_id:`${t}`,uuid:f}:{description:(null==i?void 0:i.description)||"",screenshot_uri:(null==i?void 0:i.uri)||"",reason_id:`${t}`,uuid:f};x.J.handleReport({tag:p?null==v?void 0:v.report_from:(null==l?void 0:l.isVideoDetailBannerAds)?"creative":(null==l?void 0:l.play_mode)&&y.EM[l.play_mode]||y.xY.OneColumn,category:y.XJ,refer:y.Hq.Button,ad_extra_data:JSON.stringify(n),log_extra:O,value:P,is_ad_event:"1"})}else b.F.open({content:this.t("Sorry, something wrong with the server, please try again."),duration:2,widthType:"half"});return"video"===(null==l?void 0:l.report_type)&&"success"===n.status&&(null==l?void 0:l.object_id)?(b.F.open({content:this.t("Web_report_thanks_for_report"),duration:2,widthType:"half"}),s(),(0,d.of)(this.getActions().addBlockVideo(null==l?void 0:l.object_id),this.getActions().setLastStatus(n.status),this.getActions().setUserData({submitresult:o}),this.getActions().hideReport())):"success"===n.status?(b.F.open({content:this.t("Web_report_thanks_for_report"),duration:2,widthType:"half"}),s(),(0,d.of)(this.getActions().setLastStatus(n.status),this.getActions().setUserData({submitresult:o}),this.getActions().hideReport())):(0,d.of)(this.getActions().setLastStatus(n.status),this.getActions().setUserData({submitresult:o}))})),(0,h.Z)(this.getActions().setRequesting(!0)),(0,_.q)(this.getActions().setRequesting(!1)))})))}setPageState(e,t){e.PageState=t}appendToPreState(e,t){e.PreState.push(t)}removeFromPreState(e){e.PreState.pop()}resetPreState(e){e.PreState=[]}setUserData(e,t){e.UserData=Object.assign(Object.assign({},e.UserData),t)}setPageStateData(e,t){e.PageStateData=t}resetState(e){return e.pipe((0,m.Z)((e=>(0,d.of)(this.getActions().resetPreState(),this.getActions().setUserData({selectedReason:void 0,HistoryReason:[]}),this.getActions().setPageState(0),this.getActions().setPageStateData(null),this.getActions().setSubmitCallback(void 0)))))}handlePrevStep(e){return e.pipe((0,v.E)(this.state$),(0,m.Z)((([e,{PreState:t}])=>{if(0===t.length)return u.w;const{state:n,data:i}=t[t.length-1];return(0,d.of)(this.getActions().setPageState(n),this.getActions().setPageStateData(i),this.getActions().removeFromPreState())})))}};(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setIsRereport",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setRereportQuery",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setSubmitCallback",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setChoosenDSACountry",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setReportTarget",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Array]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setReasons",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"addBlockVideo",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"removeBlockVideo",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setLoading",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setUuid",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"getReasons",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"handleNextReason",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"handleNextForm",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setShowing",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"showReport",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"showRereport",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"hideReport",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setRequesting",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setLastStatus",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"postReport",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Number]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setPageState",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"appendToPreState",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"removeFromPreState",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"resetPreState",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setUserData",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"setPageStateData",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"resetState",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],I.prototype,"handlePrevStep",null),I=(0,i.__decorate)([(0,r.n)("AdReport"),(0,i.__param)(1,(0,s.y)(w.hp)),(0,i.__metadata)("design:paramtypes",[k.D,Function])],I)},68878:(e,t,n)=>{"use strict";n.d(t,{D:()=>l});var i=n(58632),o=n(7672),a=n(4474),r=n(26325),s=n(55099);let l=class{constructor(e){this.fetch=e}getReportReasons(e){return this.fetch.get("/api/ad/v1/report/",{query:Object.assign({origin:"tiktok_web",report_ad_type:4},e),baseUrlType:2,headers:{[r.nk]:this.fetch.csrfToken}})}postReport(e,t){return this.fetch.post("/api/ad/v1/report/feedback/",{body:(0,a.stringify)(Object.assign({},e)),query:t,baseUrlType:2,headers:{[r.nk]:this.fetch.csrfToken}})}uploadImage(e){const t=new FormData;return t.append("file",e),t.append("source","0"),this.fetch.post("/api/upload/image/",{body:t,baseUrlType:2,headers:{[r.nk]:this.fetch.csrfToken},omitContentType:!0})}getTustedFlaggerState(){return this.fetch.get("/trusted_flagger/check/v1",{})}unbindTrustedFlagger(){return this.fetch.delete("/trusted_flagger/unbind/v1",{})}};l=(0,i.__decorate)([(0,o._)(),(0,i.__metadata)("design:paramtypes",[s.p])],l)},21512:(e,t,n)=>{"use strict";var i,o;n.d(t,{OD:()=>r,YB:()=>i,ek:()=>o,f2:()=>a}),function(e){e[e.Spam=6]="Spam",e[e.OffensiveContent=4]="OffensiveContent",e[e.SexuallyInappropriate=7]="SexuallyInappropriate",e[e.Violence=3]="Violence",e[e.IntellectualPropertyInfringementOld=8]="IntellectualPropertyInfringementOld",e[e.Misleading=9]="Misleading",e[e.FraudOrScam=10]="FraudOrScam",e[e.DangerousGoodsOrServices=11]="DangerousGoodsOrServices",e[e.Others=14]="Others",e[e.MinorsToPurchase=15]="MinorsToPurchase",e[e.ChildSexualExploitation=17]="ChildSexualExploitation",e[e.ReportIllegalContent=16]="ReportIllegalContent",e[e.ContentIsChildSexualAbuseMaterial=18]="ContentIsChildSexualAbuseMaterial",e[e.OfferingToSupplyChildSexAbuseMaterial=19]="OfferingToSupplyChildSexAbuseMaterial",e[e.ContentRelatesToGroomingOrSexualSolicitationOfAChild=20]="ContentRelatesToGroomingOrSexualSolicitationOfAChild",e[e.TerroristOffences=21]="TerroristOffences",e[e.ProvocationToCommitTerroristOffence=22]="ProvocationToCommitTerroristOffence",e[e.ContentRelatingToSupportFoTerrorism=23]="ContentRelatingToSupportFoTerrorism",e[e.InstructionsOnHowToMakeExplosives=24]="InstructionsOnHowToMakeExplosives",e[e.IllegalHateSpeech=25]="IllegalHateSpeech",e[e.ContentRelatingToViolent=26]="ContentRelatingToViolent",e[e.DepictionsOfGraphicViolence=27]="DepictionsOfGraphicViolence",e[e.ParticipationInOrganisedCriminalOrganization=28]="ParticipationInOrganisedCriminalOrganization",e[e.IllegalRrivacyRelatedViolations=29]="IllegalRrivacyRelatedViolations",e[e.ImageBasedPrivacyViolations=30]="ImageBasedPrivacyViolations",e[e.IllegalImpersonation=31]="IllegalImpersonation",e[e.OtherIllegalPrivacyViolations=32]="OtherIllegalPrivacyViolations",e[e.NonConsensualSharingOfPrivateImages=33]="NonConsensualSharingOfPrivateImages",e[e.IllegalGoods=34]="IllegalGoods",e[e.ContentRelatedToHumanTrafficking=35]="ContentRelatedToHumanTrafficking",e[e.PromotionOfProstitution=36]="PromotionOfProstitution",e[e.ProductionIllegalDrugs=37]="ProductionIllegalDrugs",e[e.ContentThatPromotesThePoaching=38]="ContentThatPromotesThePoaching",e[e.IllicitArmsTrafficking=39]="IllicitArmsTrafficking",e[e.HarrassmentOrThreats=40]="HarrassmentOrThreats",e[e.Defamation=41]="Defamation",e[e.ConsumerRelatedOffences=42]="ConsumerRelatedOffences",e[e.BreachOfConsumerLaw=43]="BreachOfConsumerLaw",e[e.UnsafeProducts=44]="UnsafeProducts",e[e.InformationRelatedOffences=45]="InformationRelatedOffences",e[e.CriminalMisinformation=46]="CriminalMisinformation",e[e.ContemptOfCourt=47]="ContemptOfCourt",e[e.InstructionsInRelationToSuicide=48]="InstructionsInRelationToSuicide",e[e.FinancialCrime=49]="FinancialCrime",e[e.Fraud=50]="Fraud",e[e.MoneyLaundering=51]="MoneyLaundering",e[e.Extortion=52]="Extortion",e[e.NationalSecurityRelatedOffences=53]="NationalSecurityRelatedOffences",e[e.NationalSecurityRelatedCrimes=54]="NationalSecurityRelatedCrimes",e[e.OtherIllegalContent=55]="OtherIllegalContent",e[e.PoliticalContent=56]="PoliticalContent",e[e.IntellectualPropertyInfringementNew=57]="IntellectualPropertyInfringementNew",e[e.AISynthetic=58]="AISynthetic",e[e.HateSpeechAndDiscrimination=59]="HateSpeechAndDiscrimination",e[e.ChildrenRelatedOffensiveContent=60]="ChildrenRelatedOffensiveContent"}(i||(i={})),function(e){e[e.Spam=6]="Spam",e[e.FraudOrScam=10]="FraudOrScam",e[e.Misleading=9]="Misleading",e[e.SexuallyInappropriate=7]="SexuallyInappropriate",e.ProhibitedOrInfringing="ProhibitedOrInfringing",e.IPInfringement="IPInfringement",e.IPInfringementRightOwner="IPInfringementRightOwner",e.ProhibitedOrViolence="ProhibitedOrViolence",e[e.Offensive=4]="Offensive",e[e.ReportIllegalContent=16]="ReportIllegalContent",e[e.Others=14]="Others"}(o||(o={}));const a=e=>e>=i.ChildSexualExploitation&&e<=i.OtherIllegalContent,r=encodeURIComponent("https://www.tiktok.com/falcon/ad_report/page/submit_ad/index.html")},13947:(e,t,n)=>{"use strict";n.d(t,{L:()=>x});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(340),l=n(23999),c=n(26324),d=n(35572),u=n(8536),p=n(74690),v=n(80339),m=n(55322),g=n(64356),h=n(81792),_=n(7672),f=n(55099);let y=class{constructor(e){this.fetch=e}getReportDetail(e){return this.fetch.get("/bi/notification/reporter/record",{query:e,baseUrlType:2})}};y=(0,i.__decorate)([(0,_._)(),(0,i.__metadata)("design:paramtypes",[f.p])],y);var b=n(11983),w=n(45297);let x=class extends o.E{constructor(e,t){super(),this.service=e,this.t=t,this.defaultState={visible:!1,violationAppealInfo:{},reportDetail:{isLoading:!1,data:null}}}setVisible(e,t){e.visible=t}setAppealInfoAndShow(e,t){const{url:n}=t,i=(0,h.U)(decodeURIComponent(n));e.reportDetail.data=null,e.violationAppealInfo=i,e.visible=!0}setReportDetailLoading(e,t){e.reportDetail.isLoading=t}setReportDetail(e,t){e.reportDetail.data=t}getLogoutReportDetail(e){return e.pipe((0,d.p)((({reportId:e})=>this.service.getReportDetail({report_id:e}).pipe((0,u.Z)((e=>(null==e?void 0:e.link_status)?(0,l.of)(this.getActions().setReportDetail(e),this.getActions().setVisible(!0)):(0,l.of)(this.noop()))),(0,p.Z)(this.getActions().setReportDetailLoading(!0)),(0,v.q)(this.getActions().setReportDetailLoading(!1)),(0,m.n)({callback:this.commonToastError})))))}commonToastError(){b.F.destroy(),b.F.open({content:this.t(w.z$),duration:3,widthType:"half"})}};(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],x.prototype,"setVisible",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],x.prototype,"setAppealInfoAndShow",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],x.prototype,"setReportDetailLoading",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],x.prototype,"setReportDetail",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[c.c]),(0,i.__metadata)("design:returntype",void 0)],x.prototype,"getLogoutReportDetail",null),x=(0,i.__decorate)([(0,r.n)("AdViolationAppealModal"),(0,i.__param)(1,(0,s.y)(g.hp)),(0,i.__metadata)("design:paramtypes",[y,Function])],x)},33843:(e,t,n)=>{"use strict";n.d(t,{C8:()=>b,D_:()=>l,Fh:()=>d,JN:()=>s,JS:()=>a,KW:()=>m,Ko:()=>c,Lo:()=>v,Rh:()=>p,TU:()=>g,XP:()=>w,_k:()=>y,an:()=>u,bq:()=>r,jl:()=>_,rW:()=>h});var i=n(62186),o=n(72153);const a=(0,i.default)("form",{target:"e1o0lt9f0"})((({theme:e})=>[(0,o.zy)({theme:e,typography:"H6"}),{zIndex:2,background:e.colors.BGPrimary,borderRadius:"8px",overflow:"hidden",width:"700px",margin:0}]),"label:FormReport;"),r=(0,i.default)("div",{target:"e1o0lt9f1"})((({theme:e})=>({width:"400px",zIndex:2,background:e.colors.BGPrimary,borderRadius:"8px",overflow:"hidden",margin:0})),"label:DivFormBox;"),s=(0,i.default)("div",{target:"e1o0lt9f2"})({display:"flex",alignItems:"center",padding:"24px 24px 16px",height:"72px"},"label:DivFormHeader;"),l=(0,i.default)("div",{target:"e1o0lt9f3"})({cursor:"pointer",padding:"6px",height:"32px"},"label:DivBackButton;"),c=(0,i.default)("div",{target:"e1o0lt9f4"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),d=(0,i.default)("h4",{target:"e1o0lt9f5"})((({theme:e})=>({fontSize:"20px",lineHeight:"32px",color:e.colors.TextPrimary,fontFamily:e.fontFamilies.TikTokFont,fontWeight:e.fontWeights.bold,textAlign:"rtl"===e.direction?"right":"left",flex:1})),"label:H4FormTitle;");d.defaultProps=Object.assign(Object.assign({},d.defaultProps),{"data-e2e":"report-card-title"});const u=(0,i.default)("div",{target:"e1o0lt9f6"})((({theme:e})=>({borderTop:`1px solid ${e.colors.LineSecondary}`,height:"432px",overflowY:"auto",overflowX:"hidden",padding:"16px 16px 0px"})),"label:DivRadioWrapper;"),p=(0,i.default)("div",{target:"e1o0lt9f7"})((({theme:e})=>({paddingBottom:"8px",paddingLeft:"8px",color:e.colors.TextSecondary,height:"22px",lineHeight:"22px"})),"label:DivSelectText;"),v=(0,i.default)("div",{target:"e1o0lt9f8"})((({theme:e})=>({color:e.colors.TextPrimary,lineHeight:"22px",fontSize:"16px",userSelect:"none"})),"label:DivReasonText;"),m=(0,i.default)("label",{target:"e1o0lt9f9"})((({theme:e})=>({boxSizing:"border-box",minHeight:"54px",display:"flex",flex:"1 1 100%",flexDirection:"row",alignItems:"center",cursor:"pointer",position:"relative",wordBreak:"break-all",justifyContent:"space-between",padding:"8px",borderRadius:"8px",":hover":{background:e.colors.BGPlaceholderOpaque}})),"label:LabelRadio;");m.defaultProps=Object.assign(Object.assign({},m.defaultProps),{"data-e2e":"report-card-reason"});const g=(0,i.default)("div",{target:"e1o0lt9f10"})({position:"absolute",left:"50%",top:"50%",transform:"translate(-50% , -50%)"},"label:DivMMid;"),h=(0,i.default)("div",{target:"e1o0lt9f14"})((({theme:e})=>({position:"absolute",bottom:"0",left:"0",height:"84px",width:"100%",borderTop:`0.5px solid ${e.colors.LinePrimary2}`,backgroundColor:e.colors.BGPrimary})),"label:DivFooter;"),_=(0,i.default)("button",{target:"e1o0lt9f15"})((({theme:e})=>({height:"36px",width:"120px",textAlign:"center",padding:"7px 16px",lineHeight:"22px",fontSize:"16px",position:"absolute",cursor:"pointer",top:"24px",right:"24px",color:e.colors.ConstTextInverse,background:e.colors.Primary,border:"none",borderRadius:"4px",":disabled":{background:e.colors.BGPlaceholderDefault,color:e.colors.TextQuaternary}})),"label:ButtonSubmit;"),f=(0,i.default)("div",{target:"e1o0lt9f20"})((({theme:{direction:e,colors:t}})=>[Object.assign(Object.assign({minWidth:"16px",width:"16px",height:"16px"},"rtl"===e&&{transform:"rotate(180deg)"}),{"> svg > path":{fill:t.TextPrimary}})]),"label:DivArrowContainer;"),y=(0,i.default)("div",{target:"e1o0lt9f21"})({DivArrowContainer:f,marginInlineStart:"auto",height:"16px"},"label:DivReportOptionsArrowContainer;"),b=(0,i.default)("div",{target:"e1o0lt9f22"})({display:"flex",flexDirection:"column",alignItems:"stretch",padding:"0px"},"label:DivScrollContainer;"),w=(0,i.default)("div",{target:"e1o0lt9f23"})((({theme:e})=>({display:"flex",flexDirection:"row",boxSizing:"border-box",fontSize:"16px",padding:"16px 24px",lineHeight:"22px",color:e.colors.TextSecondary,backgroundColor:e.colors.BGView,marginBottom:"8px"})),"label:DivSectionLine;")},37568:(e,t,n)=>{"use strict";n.d(t,{J:()=>a});var i,o=n(93608);!function(e){e.AdReasonGet="ads_report_subcategory_list_show",e.AdReasonSelect="ads_report_subcategory_list_click",e.AdEditPageView="ads_report_subcategory_detail_show",e.Report="report"}(i||(i={}));const a={handleAdReasonGet:e=>{o.f.event("ads_report_subcategory_list_show",e)},handleAdReasonSelect:e=>{o.f.event("ads_report_subcategory_list_click",e)},handleAdEditPageView:e=>{o.f.event("ads_report_subcategory_detail_show",e)},handleReport:e=>{o.f.event("report",e)}}},81792:(e,t,n)=>{"use strict";n.d(t,{U:()=>r});var i=n(30932),o=n.n(i);const a=e=>{const t=(e||location.href).split("?")[1]||"";if(t){const e=t.split("&"),n={};for(let t=0;t=2){const e=i.shift();e&&(n[e]=decodeURIComponent(i.join("=")))}}return n}return{}};function r(e){return function(e){const t={};for(const n in e)t[n]=o()(e[n]);return t}(a(new URL(e).search))}},141:(e,t,n)=>{"use strict";n.d(t,{qk:()=>s});var i=n(81396),o=n.n(i),a=n(82715),r=n(91857);const s=[a.OZ.home,a.OZ.foryou,...a.OZ.foryouWithLang],l=(r.Ob.home,r.Ob.foryou,r.Ob.foryouWithLang,r.Ob.discover,r.Ob.topics,a.OZ.expansion,a.OZ.challenge,[r.Ob.report,r.Ob.reportInbox]);var c;o()(Object.values(r.Ob)).filter((e=>!l.includes(e))),function(e){e.Video="video",e.User="user",e.Challenge="hashtag",e.Trending="fyp",e.Live="live",e.Message="message",e.Setting="setting",e.Music="music",e.SearchResults="search",e.Discover="discover",e.Following="following",e.Topics="topics",e.Profile="profile",e.Expansion="expansion",e.Inbox="inbox",e.Report="report",e.Feedback="feedback",e.ChooseTime="custom-choose-time"}(c||(c={}))},72688:(e,t,n)=>{"use strict";n.d(t,{$2s:()=>m,ATn:()=>r,G2o:()=>o,WDv:()=>d,fJR:()=>l,l3z:()=>u,pHc:()=>a,wsj:()=>g,zpT:()=>h});var i=n(94810);const{getPureLivePath:o,getPureMusicPath:a,getPureTagPath:r,getPureStickerPath:s,getPureUserPath:l,getPureVideoPath:c,getPureQuestionPath:d}=i.h,{getPureUniqueId:u,hasIllegalText:p,isPureNumber:v,isRealUniqueId:m,purifyMusicName:g,purifyPlainText:h}=i.A},55322:(e,t,n)=>{"use strict";n.d(t,{n:()=>r});var i=n(46657),o=n(2668),a=n(20259);const r=({msg:e,shouldShowMsg:t=!1,prevent:n=!0,callback:r})=>s=>s.pipe((0,a.W)((a=>(t&&console.error("Effect error: ",null!=e?e:a),null==r||r(),n?i.w:(0,o.$)((()=>a))))))},66401:(e,t,n)=>{"use strict";n.d(t,{Rx:()=>a,pn:()=>i});const i=(e,t)=>null!=e&&Boolean(Number(e))&&null!=t?0!==t?2:5===e?3:1:0,o=new Set([1,2,3]),a=e=>null!=e&&o.has(e)},15942:(e,t,n)=>{"use strict";n.d(t,{H:()=>o});var i=n(40099);function o(){const[e,t]=(0,i.useState)(0),n=(0,i.useCallback)((()=>{t(0)}),[]);return{popupHeight:e,handlePopupShow:(0,i.useCallback)((e=>{t(e)}),[]),handlePopupHide:n}}},78214:(e,t,n)=>{"use strict";n.d(t,{H:()=>vi});var i,o,a,r,s,l,c,d,u,p,v=n(24643),m=n(40099),g=n(237),h=n(49057),_=n(48615),f=n(88920),y=n(70364),b=n.n(y);(o=i||(i={})).POP="pop",o.PC_BANNER="pc_banner",o.MOBILE_BANNER="mobile_banner",o.WEBVIEW="webview",(r=a||(a={})).V1="v1",r.V2="v2",r.CUSTOMIZED="customized",(l=s||(s={})).TEXT="text",l.LINK="link",l.BUTTON="button",(d=c||(c={})).EXTERNAL="external",d.INTERNAL="internal",d.SUB_POPUP="sub_popup",(p=u||(u={})).INFO="info",p.WARN="warn",p.ERROR="error";const w="/tiktok/popup/dispatch/v1",x="/api/policy/notice/",T=w,k="/tiktok/popup/callback/v1",S=k;var E,A;(A=E||(E={})).initError="initError",A.beforeFetchData="beforeFetchData",A.afterFetchData="afterFetchData",A.fetchDataError="fetchDataError",A.popupDataReady="popupDataReady",A.processDataError="processDataError",A.beforeSendCallback="beforeSendCallback",A.afterSendCallback="afterSendCallback",A.sendCallbackError="sendCallbackError",A.beforeNavigateToNextPopup="beforeNavigateToNextPopup",A.afterNavigateToNextPopup="afterNavigateToNextPopup",A.allPopupsCompleted="allPopupsCompleted",A.beforeDestruct="beforeDestruct";var O=n(31780),P=n(60012);const I="0.0.0",C="pns_sdk_common_modules";var L,j,M,N;function D(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}(j=L||(L={})).US_EAST="US-East",j.US_EASTRED="US-EastRed",j.SINGAPORE_CENTRAL="Singapore-Central",j.EU_TTP="EU-TTP",j.EU_TTP2="EU-TTP2",j.US_TTP="US-TTP",j.US_TTP2="US-TTP2",(N=M||(M={})).PRODUCTION="production",N.DEV="dev",N.BOE="boe";class R{constructor(e,t){this.sendEvent=e=>{this._client&&this._client.sendEvent&&this._client.sendEvent(e)},this.reportActualFMP=()=>{};const{slardar:n}=null!=e?e:{},{region:i=L.US_EAST,bid:o=C,mode:a=M.PRODUCTION,consumerBid:r,version:s=I}=null!=t?t:{};this._client=(0,P.kT)();let l={};switch(i){case L.US_EASTRED:case L.EU_TTP:case L.EU_TTP2:l={domain:"https://mon-i18n.tiktokv.com",pluginPathPrefix:"https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/slardar/fe/sdk-web/plugins"};break;case L.US_TTP:case L.US_TTP2:l={domain:"https://mon16-normal-useast5.tiktokv.us",pluginPathPrefix:"https://lf16-cdn-tos.tiktokcdn-us.com/obj/static-tx/slardar/fe/sdk-web/plugins"};break;case L.US_EAST:case L.SINGAPORE_CENTRAL:default:l={domain:"https://mon.tiktokv.com",pluginPathPrefix:"https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/slardar/fe/sdk-web/plugins"}}var c,d;this._client&&(this._client("init",(c=function(e){for(var t=1;t{if(this._isInitialized)return;this._isInitialized=!0;const{bid:n=C,version:i=I}=null!=t?t:{};this._name=`${n}_${i}_${Date.now()}`,this._trackingModule=this._useSingleton?O.Wk:(0,O.Q_)(this._name),this._tea=((e,t)=>{let n=null;if(!1!==(null==e?void 0:e.tea))try{const{tea:i}=null!=e?e:{},{appId:o,region:a,debug:r}=null!=t?t:{},s=(e=>{let t={};switch(e){case L.US_EASTRED:t={channel:"in",channel_type:"tcpy",channel_domain:"https://mcs-i18n.tiktok.com"};break;case L.EU_TTP:t={channel:"ie",channel_type:"ttp",channel_domain:"https://mcs-ie.tiktokw.eu"};break;case L.EU_TTP2:t={channel:"ie2",channel_type:"ttp",channel_domain:"https://mcs-ie2.tiktokw.eu"};break;case L.US_TTP:t={channel_type:"ttp",channel_domain:"https://mcs.tiktokv.us"};break;case L.US_TTP2:t={channel_type:"ttp",channel_domain:"https://mcs.tiktokw.us"};break;case L.SINGAPORE_CENTRAL:t={channel:"sg",channel_type:"tcpy",channel_domain:"https://mcs-sg.tiktokv.com"};break;case L.US_EAST:t={channel:"va",channel_type:"tcpy",channel_domain:"https://mcs-va.tiktokv.com"}}return t})(a),l=F({},s,null!=i?i:{});(e=>!(!e||!e.channel_type||!e.channel&&!e.channel_domain))(l)&&(n=new B.g(`${C}_${I}_${Date.now()}`),n.init(F({app_id:null!=o?o:1988,log:r},l)),n.start())}catch(e){}return n})(e,t),this._teaEventNameFormatter=null==e?void 0:e.teaEventNameFormatter,this._slardar=((e,t)=>{let n=null;if(!1!==(null==e?void 0:e.slardar))try{n=new R(e,t)}catch(e){}return n})(e,t),this._slardar&&this._trackingModule.init({slardarContainer:this._slardar})},this.reportCUJ=(e,t,n)=>{if(e)try{var i,o;this._trackingModule.reportCUJ(e,t,n),this._tea&&this._tea.event(null!==(o=null===(i=this._teaEventNameFormatter)||void 0===i?void 0:i.call(this,e))&&void 0!==o?o:e,function(e){for(var t=1;t{W.info("[ServiceModule]: init"),this._domain=e.domain||"https://www.tiktok.com",this._commonParams=e.commonParams||{}},this.sendRequest=(e,t,n,i)=>{const o=ee.test(e)?e:`${this._domain}${e}`,a=new URL(o),r=Array.from(a.searchParams.entries()).reduce(((e,t)=>{const[n,i]=t;return void 0===i&&""===i||(e[n]=i),e}),{}),s=null!=i?i:{},{params:l,timeout:c}=s,d=function(e,t){if(null==e)return{};var n,i,o=function(e,t){if(null==e)return{};var n,i,o={},a=Object.keys(e);for(i=0;i=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(s,["params","timeout"]);let u=J({},this._commonParams,r,null!=l?l:{});"GET"===t&&n&&"object"==typeof n&&(u=J({},u,n));const p=new URLSearchParams((e=>{if(!e)return"";const t=new URLSearchParams;return Object.entries(e).forEach((([e,n])=>{Array.isArray(n)?n.forEach((n=>{t.append(e,n)})):null!=n&&t.append(e,n)})),t.toString()})(u)),v=new URL(`${a.origin}${a.pathname}?${p.toString()}`),m=Y()({},d,{method:t,timeout:null!=c?c:0,data:n});return W.info("[ServiceModule]: sendRequest start",m),X()(v.href,m).then((e=>(W.info("[ServiceModule]: sendRequest finish",e),e))).catch((e=>{throw W.error("[ServiceModule]: sendRequest error",e),e}))},this.destruct=()=>{W.info("[ServiceModule]: destruct")},te._instance||(te._instance=this),te._instance}}var ne,ie,oe,ae,re,se,le,ce,de,ue,pe,ve,me=new te;function ge(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function he(e){for(var t=1;t{var p;const v=r.exec(d);if(!v)return;const m=he({type:(null==n?void 0:n.link)?s.LINK:s.BUTTON,text:t},(null==n?void 0:n.link)&&{link:xe({link:n.link,lang:e}),linkType:n.link_type===re.LINK_TYPE_ENUM_EXTERNAL?c.EXTERNAL:c.INTERNAL},(null==n||null===(p=n.actions)||void 0===p?void 0:p.includes(de.ACTION_TYPE_ENUM_CALLBACK))&&{callback:a(i,o,n,!1)});l.push({type:s.TEXT,text:d.slice(u,v.index)}),l.push(m),u=Number(v.index)+v[0].length})),l.push({type:s.TEXT,text:d.slice(u)}),l}function ye({rawButtons:e,popupMeta:t,style:n,callback:i}){if(!e)return;const o=[];return e.forEach((({text:e,is_bold:a,is_highlight:r,action:s})=>{const l={text:e,isBold:Boolean(a),isHighlight:Boolean(r),callback:i(t,n,s,!0)};o.push(l)})),o}function be(e){switch(e){case oe.POPUP_STYLE_ENUM_PC_BANNER:return i.PC_BANNER;case oe.POPUP_STYLE_ENUM_MOBILE_BANNER:return i.MOBILE_BANNER;case oe.POPUP_STYLE_ENUM_WEBVIEW:return i.WEBVIEW;case oe.POPUP_STYLE_ENUM_POP:default:return i.POP}}(ie=ne||(ne={})).CALLBACK="callback",ie.H5="h5",(ae=oe||(oe={}))[ae.POPUP_STYLE_ENUM_BOTTOM=0]="POPUP_STYLE_ENUM_BOTTOM",ae[ae.POPUP_STYLE_ENUM_POP=1]="POPUP_STYLE_ENUM_POP",ae[ae.POPUP_STYLE_ENUM_FULLSCREEN=2]="POPUP_STYLE_ENUM_FULLSCREEN",ae[ae.POPUP_STYLE_ENUM_WEBVIEW=3]="POPUP_STYLE_ENUM_WEBVIEW",ae[ae.POPUP_STYLE_ENUM_PC_BANNER=4]="POPUP_STYLE_ENUM_PC_BANNER",ae[ae.POPUP_STYLE_ENUM_MOBILE_BANNER=5]="POPUP_STYLE_ENUM_MOBILE_BANNER",(se=re||(re={}))[se.LINK_TYPE_ENUM_INTERNAL=0]="LINK_TYPE_ENUM_INTERNAL",se[se.LINK_TYPE_ENUM_EXTERNAL=1]="LINK_TYPE_ENUM_EXTERNAL",se[se.LINK_TYPE_ENUM_SUB_POPUP=2]="LINK_TYPE_ENUM_SUB_POPUP",se[se.LINK_TYPE_UPGRADE=3]="LINK_TYPE_UPGRADE",(ce=le||(le={}))[ce.POPUP_OPERATION_ENUM_LEGACY_0=0]="POPUP_OPERATION_ENUM_LEGACY_0",ce[ce.POPUP_OPERATION_ENUM_LEGACY_1=1]="POPUP_OPERATION_ENUM_LEGACY_1",ce[ce.POPUP_OPERATION_ENUM_LEGACY_2=2]="POPUP_OPERATION_ENUM_LEGACY_2",ce[ce.POPUP_OPERATION_ENUM_LEGACY_3=3]="POPUP_OPERATION_ENUM_LEGACY_3",ce[ce.POPUP_OPERATION_ENUM_LEGACY_4_AGREE=4]="POPUP_OPERATION_ENUM_LEGACY_4_AGREE",ce[ce.POPUP_OPERATION_ENUM_LEGACY_5_REMIND_ME_LATER=5]="POPUP_OPERATION_ENUM_LEGACY_5_REMIND_ME_LATER",ce[ce.POPUP_OPERATION_ENUM_LEGACY_7_LEARN_MORE=6]="POPUP_OPERATION_ENUM_LEGACY_7_LEARN_MORE",ce[ce.POPUP_OPERATION_ENUM_LEGACY_8_CONFIRM=7]="POPUP_OPERATION_ENUM_LEGACY_8_CONFIRM",ce[ce.POPUP_OPERATION_ENUM_LEGACY_9_NOT_NOW=8]="POPUP_OPERATION_ENUM_LEGACY_9_NOT_NOW",ce[ce.POPUP_OPERATION_ENUM_LEGACY_10_DOWNLOAD_YOUR_DATA=9]="POPUP_OPERATION_ENUM_LEGACY_10_DOWNLOAD_YOUR_DATA",ce[ce.POPUP_OPERATION_ENUM_LEGACY_11_SUBMIT_APPEAL=10]="POPUP_OPERATION_ENUM_LEGACY_11_SUBMIT_APPEAL",ce[ce.POPUP_OPERATION_ENUM_LEGACY_20_DOWNLOAD_YOUR_DATA=11]="POPUP_OPERATION_ENUM_LEGACY_20_DOWNLOAD_YOUR_DATA",ce[ce.POPUP_OPERATION_ENUM_LEGACY_100_GOT_IT=12]="POPUP_OPERATION_ENUM_LEGACY_100_GOT_IT",ce[ce.POPUP_OPERATION_ENUM_LEGACY_101_LEARN_MORE=13]="POPUP_OPERATION_ENUM_LEGACY_101_LEARN_MORE",ce[ce.POPUP_OPERATION_ENUM_LEGACY_200_LEARN_MORE=14]="POPUP_OPERATION_ENUM_LEGACY_200_LEARN_MORE",(ue=de||(de={}))[ue.ACTION_TYPE_ENUM_CALLBACK=0]="ACTION_TYPE_ENUM_CALLBACK",ue[ue.ACTION_TYPE_ENUM_UPDATE_CONSENT=1]="ACTION_TYPE_ENUM_UPDATE_CONSENT",ue[ue.ACTION_TYPE_ENUM_FETCH_COMPLIANCE_SETTING=2]="ACTION_TYPE_ENUM_FETCH_COMPLIANCE_SETTING",(ve=pe||(pe={}))[ve.POPUP_CALLBACK_TYPE_ENUM_UNKNOWN=0]="POPUP_CALLBACK_TYPE_ENUM_UNKNOWN",ve[ve.POPUP_CALLBACK_TYPE_ENUM_USER_ID=1]="POPUP_CALLBACK_TYPE_ENUM_USER_ID",ve[ve.POPUP_CALLBACK_TYPE_ENUM_DEVICE_ID=2]="POPUP_CALLBACK_TYPE_ENUM_DEVICE_ID";const we="${locale}";function xe({link:e,lang:t}){return e.replace(we,t)}function Te({lang:e,body:t,bodyLinks:n,popupMeta:i,callback:o}){if(!t)return;if(!n||0===n.length)return[{type:s.TEXT,text:t}];const a=[],r=t;let l=0;const d=/%s/g;return n.forEach((({name:t,link:n="",operation:u,dismiss:p,approve:v,new_web_tab:m,extra:g,link_type:h})=>{const _=d.exec(r);if(!_)return;const f=xe({link:n,lang:e}),y=Boolean(v||p),b=h===ne.CALLBACK||v,w={type:n?s.LINK:s.BUTTON,text:t,link:f,linkType:m?c.EXTERNAL:c.INTERNAL,onClick:o(y,!!b,_e(he({},i),{extra:g,operation:null==u?void 0:u.toString()}))};a.push({type:s.TEXT,text:r.slice(l,_.index)}),a.push(w),l=Number(_.index)+_[0].length})),a.push({type:s.TEXT,text:r.slice(l)}),a}function ke({lang:e,first_button_highlight:t,rawButtons:n,popupMeta:i,callback:o}){if(0===n.length)return;const a=[];return n.forEach((({text:n,is_bold:r,link_type:s,link:l,extra:d,approve:u,operation:p,dismiss:v,dismiss_all:m,new_web_tab:g,is_close_style:h},_)=>{const f=Boolean(u||v||m),y=s===ne.CALLBACK||u,b={text:n,isCloseStyle:h,isBold:Boolean(r),isHighlight:0===_&&t,link:l?xe({link:l,lang:e}):void 0,linkType:g?c.EXTERNAL:c.INTERNAL,onClick:o(f,!!y,_e(he({},i),{extra:d,operation:null==p?void 0:p.toString()}),l?{link:xe({link:l,lang:e}),linkType:g?c.EXTERNAL:c.INTERNAL}:void 0)};a.push(b)})),a}function Se(e){if(e)return{url:e,width:"auto",height:"48px"}}function Ee(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function Ae(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class Oe{init(e,t){W.info("[PopupModule]: init",e),this._lang=e.lang,this._popupApi=e.apiPath||T,this._callbackApi=e.callbackApiPath||S,this._scene=e.scene||0,this._dataProcessor=e.dataProcessor||a.V2,this._customizedProcessor=e.customizeDataProcessor,this._navigateToNextPopup=t.navigateToNextPopup,this._completeAllPopups=t.completeAllPopups,this._beforeSendCallback=t.beforeSendCallback,this._afterSendCallback=t.afterSendCallback,this._adjustAPIConfig()}_adjustAPIConfig(){this._popupApi===w?(this._callbackApi=k,this._dataProcessor=a.V2):this._popupApi===x&&(this._callbackApi="/api/policy/notice/approve/",this._dataProcessor=a.V1)}fetch(e){return W.info("[PopupModule]: fetch ",this._popupApi),me.sendRequest(this._popupApi,"GET",function(e){for(var t=1;t{if(!e)return;const t={business:e.business,policy_version:e.policy_version,style:e.style,scene:this._scene},n={eventInfo:{style:e.style,business:e.business},popupType:e.style,title:e.title,icon:Se(e.icon_url),iconDark:Se(e.icon_url_dark),body:Te({lang:this._lang,body:e.body,bodyLinks:e.body_link_list,popupMeta:t,callback:this.callbackFunctionV1}),buttons:ke({lang:this._lang,first_button_highlight:Boolean(e.first_button_highlight),rawButtons:e.actions||[],popupMeta:t,callback:this.callbackFunctionV1})};i.push(n)})),i}_processV2Data(e){const t="string"==typeof e?JSON.parse(e):e;return W.info("[PopupModule]: process V2 response",t),t.popup_responses.map((e=>{const t=e.popup_ui,n=e.popup_meta;return{eventInfo:{style:t.style,business:n.business},popupType:be(t.style),icon:Se(t.icon_url),iconDark:Se(t.icon_url_dark),title:t.title,buttons:ye({rawButtons:t.buttons,popupMeta:n,style:t.style,callback:this.callbackFunctionV2}),body:fe({lang:this._lang,body:t.body,bodyLinks:t.body_links,popupMeta:e.popup_meta,style:t.style,callback:this.callbackFunctionV2})}}))}_processCustomizedData(e){if(W.info("[PopupModule]: process customized response"),!e||!this._customizedProcessor)return[];try{return this._customizedProcessor(e)}catch(e){W.error("[PopupModule]: process customized response fail",e)}return[]}destruct(){W.info("[PopupModule]: destruct")}constructor(){this.callbackFunctionV1=(e,t,n,i)=>()=>{t&&this._sendCallback(n).then((()=>{W.info("[PopupModule]: send callback finished")})).catch((e=>{W.error("[PopupModule]: send callback fail",e)})),i&&(i.linkType===c.EXTERNAL?window.open(i.link):window.location.href=i.link),e&&this._navigateToNextPopup()},this.callbackFunctionV2=(e,t,n,i)=>()=>{if((null==n?void 0:n.actions)&&n.actions.includes(de.ACTION_TYPE_ENUM_CALLBACK)&&this._sendCallback({business:e.business,version:e.version,style:t,extra:n.extra,operation:n.operation}).then((()=>{W.info("[PopupModule]: send callback finished")})).catch((e=>{W.error("[PopupModule]: send callback fail",e)})),i&&(null==n?void 0:n.link)){const e=xe({link:n.link,lang:this._lang});n.link_type===re.LINK_TYPE_ENUM_EXTERNAL?window.open(e):window.location.href=e}(null==n?void 0:n.dismiss_all)?this._completeAllPopups():(null==n?void 0:n.dismiss)&&this._navigateToNextPopup()};var e,t,n=this;return this._sendCallback=(e=function*(e){n._beforeSendCallback();try{const t="object"==typeof e?new URLSearchParams(e):e;yield me.sendRequest(n._callbackApi,"POST",t,{headers:{"Content-Type":"application/x-www-form-urlencoded"}}),n._afterSendCallback(!0)}catch(e){n._afterSendCallback(!1,e)}},t=function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){Ee(a,i,o,r,s,"next",e)}function s(e){Ee(a,i,o,r,s,"throw",e)}r(void 0)}))},function(e){return t.apply(this,arguments)}),Oe._instance||(Oe._instance=this),Oe._instance}}var Pe=new Oe;class Ie{init(e){W.info("[LifeCycleModule]: init"),W.info("[LifeCycleModule]: init Popup module"),Pe.init(e,{navigateToNextPopup:this.navigateToNextPopup,completeAllPopups:this.completeAllPopups,beforeSendCallback:this.beforeSendCallback,afterSendCallback:this.afterSendCallback}),this._currentEvent=new Set}addEventListener(e,t){W.info("[LifeCycleModule]: add event listener to ",e);const n=this._eventListeners.get(e)||[];this._eventListeners.set(e,[...n,t])}removeEventListener(e,t){W.info("[LifeCycleModule]: remove event listener from ",e);const n=this._eventListeners.get(e);if(!n)return;const i=n.filter((e=>e!==t));this._eventListeners.set(e,i)}removeAllEventListeners(e){W.info("[LifeCycleModule]: remove all event listeners from ",e),this._eventListeners.set(e,[])}fetchPopupData(e){return W.info("[LifeCycleModule]: fetch popup data"),this.dispatchEvent(E.beforeFetchData),Pe.fetch(e).then((e=>{this.dispatchEvent(E.afterFetchData),W.info("[LifeCycleModule]: fetch popup data done, start processing response"),this.processData(e)})).catch((e=>{W.error("[LifeCycleModule]: fetch failure - ",e),this.dispatchEvent(E.fetchDataError)}))}processData(e){try{const t=Pe.processData(e);(null==t?void 0:t.length)?(W.info("[LifeCycleModule]: process response done, popup data ready"),this._currentPopupIndex=0,this._popupData=t,this.dispatchEvent(E.popupDataReady)):W.info("[LifeCycleModule]: process popup response done, no popup data")}catch(e){W.error("[LifeCycleModule]: process popup response error - ",e)}}hasPopupData(){return W.info("[LifeCycleModule]: has popup data"),this._popupData.length>0}getAllPopupData(){return W.info("[LifeCycleModule]: get all popup data"),this._popupData}getCurrentPopupData(){return W.info("[LifeCycleModule]: get current popup data"),this._popupData[this._currentPopupIndex]}hasNextPopup(){W.info("[LifeCycleModule]: has next popup");const e=this._popupData.length,t=this._currentPopupIndex+1;return 0!==this._popupData.length&&t{if(W.info("[LifeCycleModule]: dispatch start - ",e),this._currentEvent.has(e))return void W.error("[LifeCycleModule]: Dispatch is already in process",{currentEvent:[...this._currentEvent],upcomingEvent:e});this._currentEvent.add(e);const t=this._eventListeners.get(e);t&&t.forEach((t=>{try{t()}catch(t){W.warn(`[LifeCycleModule]: error executing listener for event: ${e}`,t)}})),this._currentEvent.delete(e),W.info("[LifeCycleModule]: dispatch finish - ",e)},this.beforeSendCallback=()=>{W.info("[LifeCycleModule]: before sendCallback"),this.dispatchEvent(E.beforeSendCallback)},this.afterSendCallback=(e,t)=>{e?(W.info("[LifeCycleModule]: after sendCallback"),this.dispatchEvent(E.afterSendCallback)):(W.error("[LifeCycleModule]: send callback failure",t),this.dispatchEvent(E.sendCallbackError))},this.navigateToNextPopup=()=>{W.info("[LifeCycleModule]: navigate to next popup"),this._currentPopupIndex+1{W.info("[LifeCycleModule]: complete all popup"),this._currentPopupIndex=this._popupData.length},Ie._instance||(Ie._instance=this),Ie._instance}}var Ce=new Ie;function Le(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function je(e){for(var t=1;t0))return"Action: Link url invalid.";window.open(e.link,e.actionType===Ze.LINK_EXTERNAL?"_blank":"_self")}}constructor(){return this._renderMapping={},this._visibilityMap={},Xe._instance||(Xe._instance=this),Xe._instance}}var Qe,Je=new Xe;class et{onDisplay(){var e,t;null===(t=this._customizedCallback)||void 0===t||null===(e=t.onDisplay)||void 0===e||e.call(t,this._meta),this._logger.onDisplay()}onDismiss(){var e,t;null===(t=this._customizedCallback)||void 0===t||null===(e=t.onDismiss)||void 0===e||e.call(t,this._meta),this._logger.onDismiss()}onAction(e){var t,n;null===(n=this._customizedCallback)||void 0===n||null===(t=n.onAction)||void 0===t||t.call(n,this._meta,e),this._logger.onAction(e)}onError(e){var t,n;null===(n=this._customizedCallback)||void 0===n||null===(t=n.onError)||void 0===t||t.call(n,this._meta,e),this._logger.onError(e)}constructor(e,t,n,i){this._meta=e,this._block=t,this._customizedCallback=i,this._logger=n}}(Qe||(Qe={})).INTERACT="interact";const tt={interact:"pns_communication_service_popup_execute"},nt={MALI_VA:L.US_EAST,GCP:L.US_EASTRED,ALL_SG:L.SINGAPORE_CENTRAL,EU_TTP:L.EU_TTP,EU_TTP2:L.EU_TTP2,TTP:L.US_TTP,TTP2:L.US_TTP2,BOE:L.SINGAPORE_CENTRAL,DEFAULT:L.SINGAPORE_CENTRAL};var it=new H(!0);function ot(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function at(e){for(var t=1;t{const{content:t,open:n,colorScheme:i,config:o,eventReport:a,meta:r,callback:s}=e;if(!n)return null;const l=(0,m.useMemo)((()=>new dt(r,mt,a)),[r,a]),c=(0,m.useMemo)((()=>new et(r,mt,l,s)),[r,l,s]);(0,m.useEffect)((()=>{c.onDisplay()}),[]);const{buttons:d,icon:u,iconDark:p,body:g,title:h,eventInfo:_}=t,f=(0,m.useRef)(null),y=(0,m.useCallback)((e=>{var t;"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),e.stopPropagation(),null===(t=f.current)||void 0===t||t.click())}),[]),b="dark"===i?p:u;var w,x;return(0,v.jsx)(Ue,{role:"alert",style:{top:null!==(w=null==o?void 0:o.topOffset)&&void 0!==w?w:"0",zIndex:null!==(x=null==o?void 0:o.zIndex)&&void 0!==x?x:999,backgroundColor:"var(--ui-sheet-backdrop-1)"},children:(0,v.jsxs)(Fe,{children:[(0,v.jsxs)(Ve,{children:[b&&(0,v.jsx)("img",{alt:"icon",src:b.url,height:b.height,width:b.width}),(0,v.jsxs)(He,{children:[h&&(0,v.jsx)(Re.Fm,{as:"h4",size:15,color:"UIShapeText1OnNeutral",weight:"medium",children:h}),(0,v.jsx)(Re.Fm,{as:"p",size:15,color:"UIShapeText1OnNeutral",children:null==g?void 0:g.map((e=>{return e.type===We.TEXT?e.text:(0,v.jsx)(Re.QKx,{color:"UIShapeText1OnNeutral",label:e.text,href:null!==(t=e.link)&&void 0!==t?t:"",target:e.linkType===Ge.EXTERNAL?"_blank":"_self",onClick:t=>{var n;e.action?(t.preventDefault(),Je.handleAction(e.action,r,c)):(null==a||a(Nt,vt(pt({},_),{button_info:e.text})),null===(n=e.onClick)||void 0===n||n.call(e))},weight:"medium"},e.text);var t}))})]})]}),(0,v.jsx)(ze,{children:null==d?void 0:d.map((e=>e.isCloseStyle?(0,v.jsx)("div",{onClick:()=>{var t;e.action?Je.handleAction(e.action,r,c):(null==a||a(Nt,vt(pt({},_),{button_info:e.text})),null===(t=e.onClick)||void 0===t||t.call(e))},onKeyDown:y,ref:f,tabIndex:0,role:"button",children:(0,v.jsx)(Re.gn,{size:"24px",style:{cursor:"pointer"},color:"BrandTikTokBackground"})},e.text):(0,v.jsx)(qe,{children:(0,v.jsx)(Re.I05,{label:e.text,shape:"borderless",variant:"primary",onClick:()=>{var t;e.action?Je.handleAction(e.action,r,c):(null==a||a(Nt,vt(pt({},_),{button_info:e.text})),null===(t=e.onClick)||void 0===t||t.call(e))}})},e.text)))})]})})},ht=(0,Be.default)("div",{target:"e1krb51j0"})((({theme:{colors:e}})=>({width:"100vw",left:"0",marginTop:"1px",position:"fixed",boxShadow:"0 2px 8px rgba(0, 0, 0, .06)",display:"flex",justifyContent:"center",":after":{content:'""',background:"rgba(33, 33, 33, .08)",position:"absolute",left:"0",bottom:"0",width:"100%",height:"1px",transform:"scaleY(0.5)"}})),"label:DivBannerContainer;"),_t=(0,Be.default)("div",{target:"e1krb51j1"})({width:1150,maxWidth:1150,padding:"16px 24px",display:"flex",justifyContent:"space-between",gap:"24px"},"label:DivBannerWrapper;"),ft=(0,Be.default)("div",{target:"e1krb51j2"})({display:"flex",alignItems:"center",gap:"16px"},"label:DivLeftContainer;"),yt=(0,Be.default)("div",{target:"e1krb51j3"})([{display:"flex",alignItems:"center",gap:"24px"}],"label:DivRightContainer;"),bt=(0,Be.default)("div",{target:"e1krb51j4"})({alignSelf:"center"},"label:DivContentWrapper;"),wt=(0,Be.default)("div",{target:"e1krb51j5"})({margin:"9px 0"},"label:DivButton;");function xt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Tt(e){for(var t=1;t{const{content:t,open:n,colorScheme:i,config:o,eventReport:a,meta:r,callback:s}=e;if(!n)return null;const l=(0,m.useMemo)((()=>new dt(r,St,a)),[r,a]),c=(0,m.useMemo)((()=>new et(r,St,l,s)),[r,l,s]);(0,m.useEffect)((()=>{c.onDisplay()}),[]);const{buttons:d,icon:u,iconDark:p,body:g,title:h,eventInfo:_}=t,f=(0,m.useRef)(null),y=(0,m.useCallback)((e=>{var t;"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),e.stopPropagation(),null===(t=f.current)||void 0===t||t.click())}),[]),b="dark"===i?p:u;var w,x;return(0,v.jsx)(ht,{role:"alert",style:{top:null!==(w=null==o?void 0:o.topOffset)&&void 0!==w?w:"59px",zIndex:null!==(x=null==o?void 0:o.zIndex)&&void 0!==x?x:999,backgroundColor:"var(--brand-tiktok-background)"},children:(0,v.jsxs)(_t,{children:[(0,v.jsxs)(ft,{children:[b&&(0,v.jsx)("img",{alt:"icon",src:b.url,height:b.height,width:b.width}),(0,v.jsxs)(bt,{children:[h&&(0,v.jsx)(Re.Fm,{as:"h4",color:"UIText1",size:16,weight:"medium",children:h}),g&&(0,v.jsx)(Re.Fm,{as:"p",size:16,weight:"medium",color:"UIText2",children:g.map((e=>{return e.type===We.TEXT?e.text:(0,v.jsx)(Re.QKx,{color:"UIText1Display",label:e.text,href:null!==(t=e.link)&&void 0!==t?t:"",target:e.linkType===Ge.EXTERNAL?"_blank":"_self",onClick:t=>{var n;e.action?(t.preventDefault(),Je.handleAction(e.action,r,c)):(null==a||a(Nt,kt(Tt({},_),{button_info:e.text})),null===(n=e.onClick)||void 0===n||n.call(e))},weight:"medium"},e.text);var t}))})]})]}),(0,v.jsx)(yt,{children:null==d?void 0:d.map((e=>e.isCloseStyle?(0,v.jsx)("div",{onClick:()=>{var t;e.action?Je.handleAction(e.action,r,c):(null==a||a(Nt,kt(Tt({},_),{button_info:e.text})),null===(t=e.onClick)||void 0===t||t.call(e))},onKeyDown:y,ref:f,tabIndex:0,role:"button",children:(0,v.jsx)(Re.gn,{size:"24px",style:{cursor:"pointer"}})},e.text):(0,v.jsx)(wt,{children:(0,v.jsx)(Re.I05,{label:e.text,shape:"borderless",variant:"primary",onClick:()=>{var t;e.action?Je.handleAction(e.action,r,c):(null==a||a(Nt,kt(Tt({},_),{button_info:e.text})),null===(t=e.onClick)||void 0===t||t.call(e))}})},e.text)))})]})})},At=(0,Be.default)("div",{target:"e140os950"})({display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"center",gap:"8px",padding:"0 24px"},"label:ButtonContainer;"),Ot=(0,Be.default)("img",{target:"e140os951"})({display:"block",margin:"8px auto"},"label:Img;");function Pt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function It(e){for(var t=1;t{var t;const{icon:n,iconDark:i,buttons:o,body:a,title:r,eventInfo:s}=e.content,{meta:l,callback:c,eventReport:d}=e,u="dark"===e.colorScheme?i:n,p=(0,m.useMemo)((()=>new dt(l,Lt,d)),[l,d]),g=(0,m.useMemo)((()=>new et(l,Lt,p,c)),[l,p,c]);var h;return(0,m.useEffect)((()=>{g.onDisplay()}),[]),(0,v.jsxs)(Re.nOL,{open:e.open,onOpenChange:()=>{},style:{padding:"32px 0",zIndex:null!==(h=null===(t=e.config)||void 0===t?void 0:t.zIndex)&&void 0!==h?h:9999},children:[u&&(0,v.jsx)(Ot,{src:u.url,height:u.height,width:u.width}),r&&(0,v.jsx)(Re.Fm,{as:"h2",align:"center",size:20,weight:"bold",style:{wordBreak:"break-word",lineHeight:"24px",padding:"0 20px"},children:r}),(null==a?void 0:a.length)&&(0,v.jsx)(Re.Fm,{as:"p",size:15,align:"center",style:{lineHeight:"18px",padding:"7px 24px 24px",whiteSpace:"pre-wrap"},children:a.map((t=>{return t.type===We.TEXT?t.text:(0,v.jsx)(Re.QKx,{color:"UIText1Display",weight:"medium",label:t.text,href:null!==(n=t.link)&&void 0!==n?n:"",target:t.linkType===Ge.EXTERNAL?"_blank":"_self",onClick:n=>{var i,o;t.action?(n.preventDefault(),Je.handleAction(t.action,l,g)):(null===(i=e.eventReport)||void 0===i||i.call(e,Nt,Ct(It({},s),{button_info:t.text})),null===(o=t.onClick)||void 0===o||o.call(t))}},t.text);var n}))}),(null==o?void 0:o.length)&&(0,v.jsx)(At,{children:o.map((t=>(0,v.jsx)(Re.I05,{style:t.isBold?{fontWeight:"bold"}:{},label:t.text,variant:t.isHighlight?"primary":"secondary",onClick:()=>{var n,i;t.action?Je.handleAction(t.action,l,g):(null===(n=e.eventReport)||void 0===n||n.call(e,Nt,Ct(It({},s),{button_info:t.text})),null===(i=t.onClick)||void 0===i||i.call(t))}},t.text)))})]})};var Mt=n(28658);const Nt="qa_tns_general_dialog_click";function Dt(){return(0,v.jsx)("link",{rel:"stylesheet",href:Mt})}const Rt=e=>{const[t,n]=(0,m.useState)(null),{eventReport:o,noFetchDataAtInit:a,SDKConfig:r,visible:s,onReadyToClose:l,onReadyToShow:c,colorScheme:d,textDirection:u,componentConfig:p}=e;if((0,m.useEffect)((()=>(De.init(r),a||De.fetchPopupData().catch(null),De.addEventListener(E.popupDataReady,(()=>{De.getPopupData()&&(n(De.getPopupData()),c())})),De.addEventListener(E.afterNavigateToNextPopup,(()=>{n(De.getPopupData())})),De.addEventListener(E.allPopupsCompleted,(()=>{l()})),()=>{De.destruct()})),[]),(0,m.useEffect)((()=>{s&&t&&o&&o("tns_general_dialog_show",t.eventInfo)}),[s]),!t)return null;const g={business:"",popup_id:"",policyVersion:""},{popupType:h}=t,_=function(e,t){if(null==e)return{};var n,i,o=function(e,t){if(null==e)return{};var n,i,o={},a=Object.keys(e);for(i=0;i=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(t,["popupType"]);let f;switch(h){case i.MOBILE_BANNER:f=(0,v.jsx)(gt,{colorScheme:d,content:_,open:s,config:null==p?void 0:p.mBanner,meta:g,eventReport:o});break;case i.PC_BANNER:f=(0,v.jsx)(Et,{colorScheme:d,content:_,open:s,config:null==p?void 0:p.pcBanner,meta:g,eventReport:o});break;case i.POP:default:f=(0,v.jsx)(jt,{colorScheme:d,content:_,open:s,config:null==p?void 0:p.popup,meta:g,eventReport:o})}return(0,v.jsxs)(Re.juU,{colorSchemePreference:d,textDirection:u,children:[(0,v.jsx)(Dt,{}),f]})},Bt=(0,Be.default)("div",{target:"euhfx3x0"})((({theme:e})=>({width:"100vw",height:"100vh",overflow:"auto",padding:"32px 16px",zIndex:"9999",position:"fixed",top:0,left:0})),"label:FullScreenView;"),Ut=(0,Be.default)("div",{target:"euhfx3x1"})({display:"flex",flexDirection:"column"},"label:ContainerView;"),Ft=(0,Be.default)("div",{target:"euhfx3x2"})({padding:0,width:"100%"},"label:TopContainerView;"),Vt=(0,Be.default)("div",{target:"euhfx3x3"})({padding:0,alignSelf:"flex-end",width:"100%"},"label:BottomContainerView;"),zt=(0,Be.default)("div",{target:"euhfx3x4"})({flexGrow:1,overflowY:"auto",padding:0},"label:ScrolledContainerView;"),Ht=(0,Be.default)("div",{target:"euhfx3x5"})({display:"flex",gap:"16px"},"label:ButtonGroup;"),qt=(0,Be.default)("div",{target:"euhfx3x6"})({flex:1},"label:ButtonItem;"),Gt={subtext:"UIText2",description:"UIText3"},$t={center:"center",right:"end"},Wt={"H1-Regular":{size:24,weight:"normal"},"H1-Medium":{size:24,weight:"medium"},"H1-Bold":{size:24,weight:"bold"},"H2-Regular":{size:20,weight:"normal"},"H2-Medium":{size:20,weight:"medium"},"H2-Bold":{size:20,weight:"bold"},"H3-Regular":{size:17,weight:"normal"},"H3-Medium":{size:17,weight:"medium"},"H3-Bold":{size:17,weight:"bold"},"H4-Regular":{size:15,weight:"normal"},"H4-Medium":{size:15,weight:"medium"},"H4-Bold":{size:15,weight:"bold"},"P1-Regular":{size:14,weight:"normal"},"P1-Medium":{size:14,weight:"medium"},"P1-Bold":{size:14,weight:"bold"},"P2-Regular":{size:13,weight:"normal"},"P2-Medium":{size:13,weight:"medium"},"P2-Bold":{size:13,weight:"bold"},"P3-Regular":{size:12,weight:"normal"},"P3-Medium":{size:12,weight:"medium"},"P3-Bold":{size:12,weight:"bold"},"SmallText1-Regular":{size:11,weight:"normal"},"SmallText1-Medium":{size:11,weight:"medium"},"SmallText1-Bold":{size:11,weight:"bold"},"SmallText2-Regular":{size:10,weight:"normal"},"SmallText2-Medium":{size:10,weight:"medium"},"SmallText2-Bold":{size:10,weight:"bold"},"Headline-Regular":{size:16,weight:"normal"},"Headline-Medium":{size:16,weight:"medium"},"Headline-Bold":{size:16,weight:"bold"},"Longform-Regular":{size:16,weight:"normal"},"Longform-Medium":{size:16,weight:"medium"},"Longform-Bold":{size:16,weight:"bold"},"LargeTitle-Regular":{size:32,weight:"normal"},"LargeTitle-Medium":{size:32,weight:"medium"},"LargeTitle-Bold":{size:32,weight:"bold"}},Zt=e=>{const{meta:t,content:n,callback:i}=e;var o;const a=null!==(o=Gt[n.subtype])&&void 0!==o?o:"UIText1";var r,s;const l=null!==(s=Wt[null!==(r=n.font)&&void 0!==r?r:"P2-REGULAR"])&&void 0!==s?s:{size:13,weight:"normal"};var c,d;const u=null!==(d=$t[null!==(c=n.align)&&void 0!==c?c:"left"])&&void 0!==d?d:"start",p=(0,m.useMemo)((()=>function(e){const t=e.bodyLinks;if(!e.text||0===e.text.length)throw new Error("TextBlock content is empty.");if(!t||0===t.length)return[{type:"text",name:e.text}];const n=[],i=/%s/g,o=e.text;let a=0;return t.forEach((({name:e,action:t})=>{const r=i.exec(o);if(!r)throw new Error("TextBlock link text can not match.");n.push({type:"text",name:o.slice(a,r.index)});const s={type:"link",name:e,action:t};n.push(s),a=Number(r.index)+r[0].length})),n.push({type:"text",name:o.slice(a)}),n}(n)),[n,i]),g=(0,m.useCallback)((e=>{if(e.action){const n=Je.handleAction(e.action,t,i);n&&i.onError(n)}else i.onError("TextBlock link action is empty.")}),[i,t]);return(0,v.jsx)(Re.Fm,{align:u,size:l.size,color:a,weight:l.weight,as:"div",children:p.length>0?p.map(((e,t)=>"text"===e.type?e.name:(0,v.jsx)(Re.QKx,{color:"UIText1Display",weight:"medium",label:e.name,href:"",target:"_blank",onClick:t=>{t.preventDefault(),g(e)}},t))):""})},Yt={primary:"primary",secondary:"secondary",borderless:"secondary",destructive:"primary"},Kt={primary:"default",secondary:"default",borderless:"borderless",destructive:"borderless"},Xt=e=>{const{meta:t,buttonElement:n,callback:i}=e,o=n.action;var a;const r=null!==(a=n.text)&&void 0!==a?a:"";if(!o)throw new Error("ButtonBlock no action found.");if(!r.length)throw new Error("ButtonBlock title is empty.");const s=n.subtype;var l;const c=null!==(l=Yt[s])&&void 0!==l?l:"primary";var d;const u=null!==(d=Kt[s])&&void 0!==d?d:"default",p=(0,m.useCallback)((()=>{const e=Je.handleAction(o,t,i);e&&i.onError(e)}),[i,t,o]);var g;return(0,v.jsx)(Re.I05,{label:r,variant:c,shape:u,style:{width:"100%"},onClick:p},null!==(g=n.groupId)&&void 0!==g?g:"")};Je.registerBlockCells("info",(e=>{var t;const{colorScheme:n,meta:i,block:o,callback:a}=e,r=null===(t=o.elements)||void 0===t?void 0:t.get("content");if(!r)throw new Error("InfoBlock content is empty.");const s="dark"===n?r.iconUrlDark:r.iconUrl;var l;const c=null!==(l=r.iconStyle)&&void 0!==l?l:124,d=r.subtype;return["text","subtext","description"].includes(d)?(0,v.jsx)(Zt,{meta:i,content:r,callback:a}):"divider"===d?(0,v.jsx)("hr",{}):"image"===d?(0,v.jsx)("div",{style:{display:"flex",alignItems:"center",padding:0},children:(0,v.jsx)("img",{src:s,height:c,width:"100%"})}):null})),Je.registerBlockCells("action",(e=>{const{meta:t,block:n,callback:i}=e,o=Array.from(n.elements||new Map);if(!o.some((([e])=>["action_right","action_center","action_left"].includes(e))))throw new Error("ActionBlock no button found.");return(0,v.jsx)(Ht,{children:o.map((([e,n])=>(0,v.jsx)(qt,{children:(0,v.jsx)(Xt,{meta:t,buttonElement:n,callback:i})},e)))})}));const Qt=e=>{const{position:t,colorScheme:n,meta:i,blocks:o,callback:a}=e,r={top:Ft,middle:zt,bottom:Vt}[t];return(0,v.jsx)(r,{children:o.map(((e,t)=>{const o=Je.cellByType(e.type);if(!o)throw new Error(`No block cell registered for type: ${e.type}`);const r=e.format;var s,l,c,d;const u=`${null!==(s=r.paddingTop)&&void 0!==s?s:0}px ${null!==(l=r.paddingRight)&&void 0!==l?l:0}px \n ${null!==(c=r.paddingBottom)&&void 0!==c?c:0}px ${null!==(d=r.paddingLeft)&&void 0!==d?d:0}px`;var p,m,g,h;const _=`${null!==(p=r.marginTop)&&void 0!==p?p:0}px ${null!==(m=r.marginRight)&&void 0!==m?m:0}px \n ${null!==(g=r.marginBottom)&&void 0!==g?g:0}px ${null!==(h=r.marginLeft)&&void 0!==h?h:0}px`;return(0,v.jsx)("div",{style:{padding:u,margin:_},children:(0,v.jsx)(o,{colorScheme:n,meta:i,block:e,callback:a})},t)}))})},Jt=e=>{const{blockData:t,metaData:n}=e;if("dialog"===t.style)return null;const i=(0,m.useCallback)((()=>{Je.close(n.business)}),[]),o=t.upperLeftBack?(0,v.jsx)(Re.PH3,{icon:(0,v.jsx)(Re.WZi,{}),onClick:i}):null,a=t.upperLeftBack?(0,v.jsx)(Re.PH3,{icon:(0,v.jsx)(Re.gn,{}),onClick:i}):null;return(0,v.jsx)(Re.Gil,{title:"",hideSeparator:!0,leading:o,style:{},trailing:a,hideBackground:!0})},en=e=>{const{colorScheme:t,metaData:n,blockData:i,blockCallback:o}=e,a=i.style===Ye.FULLSCREEN?"100vh":"80vh",r=i.style===Ye.FULLSCREEN?"100%":"",s=i.style;(0,m.useEffect)((()=>{o.onDisplay()}),[]);const l=(0,v.jsxs)(Ut,{style:{maxHeight:a,height:r},children:[(0,v.jsx)(Jt,{metaData:n,blockData:i,callback:o}),(0,v.jsx)(Qt,{position:"top",colorScheme:t,meta:n,blocks:i.topPinnedBlocks,callback:o}),(0,v.jsx)(Qt,{position:"middle",colorScheme:t,meta:n,blocks:i.blocks,callback:o}),(0,v.jsx)(Qt,{position:"bottom",colorScheme:t,meta:n,blocks:i.bottomPinnedBlocks,callback:o})]});return(()=>{switch(s){case Ye.BOTTOM:return(0,v.jsx)(Re.jdl,{open:!0,onOpenChange:()=>{},style:{padding:"32px 16px",zIndex:9999},children:l});case Ye.FULLSCREEN:return(0,v.jsx)(Bt,{style:{visibility:"visible",backgroundColor:"var(--brand-tiktok-background)"},children:l});case Ye.POP:default:return(0,v.jsx)(Re.nOL,{open:!0,onOpenChange:()=>{},style:{padding:"32px 16px",zIndex:9999},children:l})}})()},tn=e=>{const{eventReport:t,colorScheme:n,blockData:i,metaData:o,callback:a}=e,r=(0,m.useMemo)((()=>new dt(o,i,t)),[o,i,t]),s=(0,m.useMemo)((()=>new et(o,i,r,a)),[o,i,r,a]);return(0,v.jsx)(O.tH,{shouldReport:!1,onError:e=>s.onError(e.toString()),children:(0,v.jsx)(en,{colorScheme:n,metaData:o,blockData:i,blockCallback:s})})};function nn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function on(e){for(var t=1;t((0,m.useMemo)((()=>{var n,i,o,a,r;it.init(on({teaEventNameFormatter:e=>tt[e]},e),(a=on({bid:null!==(n=null==t?void 0:t.bid)&&void 0!==n?n:"pns_communication_service",version:"1.0.0",appId:1988},t),r=null!=(r={region:null!==(o=nt[null!==(i=null==t?void 0:t.deploymentRegion)&&void 0!==i?i:"DEFAULT"])&&void 0!==o?o:L.SINGAPORE_CENTRAL})?r:{},Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(r)):function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t}(Object(r)).forEach((function(e){Object.defineProperty(a,e,Object.getOwnPropertyDescriptor(r,e))})),a))}),[]),(0,v.jsx)(O.V7,{cujName:Qe.INTERACT,children:n}));function rn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function sn(e){for(var t=1;t{const{pnsPopupConfig:t,eventReport:n,colorScheme:i,textDirection:o}=e;return(0,m.useEffect)((()=>{null==n||n("pns_web_popup_request",{type:"popup"})}),[]),t.blockData?(0,v.jsxs)(Re.juU,{colorSchemePreference:i,textDirection:o,children:[(0,v.jsx)(ln,{}),(0,v.jsx)(tn,{eventReport:n,colorScheme:i,blockData:t.blockData,metaData:t.metaData,callback:t.callback})]}):null},dn=e=>{const{pnsPopupConfig:t,eventReport:n,colorScheme:i,textDirection:o,componentConfig:a}=e;let r,s=null,l=null;var c;if(t.popupData)switch(l=function(e,t){if(null==e)return{};var n,i,o=function(e,t){if(null==e)return{};var n,i,o={},a=Object.keys(e);for(i=0;i=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(c=t.popupData,["popupType"]),({popupType:r}=c),r){case $e.MOBILE_BANNER:s=(0,v.jsx)(gt,{colorScheme:i,content:l,open:!0,config:null==a?void 0:a.mBanner,meta:t.metaData,eventReport:n,callback:t.callback});break;case $e.PC_BANNER:s=(0,v.jsx)(Et,{colorScheme:i,content:l,open:!0,config:null==a?void 0:a.pcBanner,meta:t.metaData,eventReport:n,callback:t.callback});break;case $e.POP:default:s=(0,v.jsx)(jt,{colorScheme:i,content:l,open:!0,config:null==a?void 0:a.popup,meta:t.metaData,eventReport:n,callback:t.callback})}return(0,m.useEffect)((()=>{null==n||n("pns_web_popup_request",{type:r})}),[]),(0,v.jsxs)(Re.juU,{colorSchemePreference:i,textDirection:o,children:[(0,v.jsx)(ln,{}),s]})},un=e=>{const{pnsPopupConfig:t}=e,[n,i]=(0,m.useState)(!0);if((0,m.useEffect)((()=>{Je.registerVisibility(t.metaData.business,i)}),[]),!n)return null;let o=null;return t.blockData&&(o=(0,v.jsx)(cn,sn({},e))),t.popupData&&(o=(0,v.jsx)(dn,sn({},e))),o},pn=e=>(0,v.jsx)(an,{monitorConfig:e.monitorConfig,children:(0,v.jsx)(un,sn({},e))}),vn=De.fetchPopupData;var mn,gn,hn=n(67518),_n=n(93608);!function(e){e.None="none",e.Pop="pop",e.Float="float",e.Bottom="bottom",e.PcBanner="pc_banner",e.MobileBanner="mobile_banner"}(mn||(mn={})),function(e){e.Callback="callback",e.H5="h5"}(gn||(gn={}));const fn=e=>{var t,n;const{onHide:i,hideByDefault:o}=e,a=(0,m.useRef)(!1),[r,s]=(0,m.useState)(!1),l=(0,m.useCallback)((()=>{null==i||i(),s(!1)}),[i]),{language:c,wid:d,region:u}=null!==(t=(0,h.W)((()=>["language","wid","region"]),[]))&&void 0!==t?t:{},{isMobile:p}=null!==(n=(0,_.U)((()=>["isMobile"]),[]))&&void 0!==n?n:{},{isDark:y,direction:w}=(0,hn.u)(),{showFullSideNav:T}=(0,f.Oj)(),k=(0,m.useCallback)((e=>{a.current||(a.current=!0,vn({scene:555,extra:JSON.stringify(e)}).catch(null))}),[]),S=(0,m.useCallback)((e=>{vn({scene:555,extra:JSON.stringify(e)}).catch(null)}),[]);if((0,m.useEffect)((()=>(g.LZ.on(g.Rh,b()(k,2e3)),g.LZ.on(g.gk,b()(S,2e3)),()=>{g.LZ.clear(g.Rh),g.LZ.clear(g.gk)})),[k,S]),!d||!u||!c)return null;const E={appId:1988,wid:d,isMobile:p,region:u,lang:c,apiDomain:"https://www.tiktok.com",apiPath:x};return(0,v.jsx)("div",{id:"web-universal-popup",children:(0,v.jsx)(Rt,{eventReport:_n.f.event.bind(_n.f),noFetchDataAtInit:o,SDKConfig:E,visible:r,colorScheme:y?"dark":"light",textDirection:w,onReadyToClose:l,onReadyToShow:()=>s(!0),componentConfig:T?{pcBanner:{topOffset:"0"}}:void 0})})};function yn(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function bn(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){yn(a,i,o,r,s,"next",e)}function s(e){yn(a,i,o,r,s,"throw",e)}r(void 0)}))}}class wn{init(e){this._actionFactoryMap={},this._actionConfig=e}registerActionFactory(e,t){this._actionFactoryMap[e]=t}_createAction(e){if(!Object.prototype.hasOwnProperty.call(this._actionFactoryMap,e))throw new Error(`[ActionManager]: ${e} not registered`);const t=this._actionFactoryMap[e].createAction();return t.init(this._actionConfig),t}executeAction(e){var t=this;return bn((function*(){let n;try{n=t._createAction(e.processor)}catch(t){return void W.error(`[Action ${e.processor}]: create error`,t)}try{yield n.execute(e.params)}catch(t){W.error(`[Action ${e.processor}]: execute error`,t)}n.destruct()}))()}executeActions(e){var t=this;return bn((function*(){const n=e.action_list;for(const e of n)yield t.executeAction(e)}))()}destruct(){this._actionFactoryMap={},W.info("[ActionManager]: destruct")}constructor(){return this._actionFactoryMap={},wn._instance||(wn._instance=this),wn._instance}}var xn=new wn;function Tn(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}const kn=(0,n(34099).V)().imFrontier;var Sn,En,An,On,Pn=new class{init(e){var t,i=this;return(t=function*(){if(null!==i._sdk)return void W.info("[CommunicationReceiver]: SyncSdk isInitiated!");const{uid:t,debug:o}=e,a={apiUrl:"https://www.tiktok.com",uid:t,did:t,aid:1988,frontier:{url:kn,appKey:"e252eea4204adef812c32f35a4b80f4b",fpid:32,service:33554513,method:2},debug:o};try{const{SyncSdk:t}=yield Promise.all([n.e(4563),n.e(8873),n.e(6706),n.e(8904),n.e(1960),n.e(8537),n.e(8261)]).then(n.bind(n,50173));i._sdk=new t(a),yield i._sdk.init(),i._sdk.registerBusiness("67",(t=>{const n=(new TextDecoder).decode(t.data);W.info(`[CommunicationServiceSDK]: CommunicationReceiver received data ${n}`),e.onReceiveData(n)}))}catch(e){W.error(`[CommunicationServiceSDK]: CommunicationReceiver init and register bytesync failed: ${e}`)}},function(){var e=this,n=arguments;return new Promise((function(i,o){var a=t.apply(e,n);function r(e){Tn(a,i,o,r,s,"next",e)}function s(e){Tn(a,i,o,r,s,"throw",e)}r(void 0)}))})()}destruct(){W.info("[CommunicationServiceSDK]: CommunicationReceiver destruct"),this._sdk&&(this._sdk.dispose(),this._sdk=null)}constructor(){this._sdk=null}};(En=Sn||(Sn={})).POPUP="PopupShowProcessor",En.SCREEN_TIME="ScreenTimeProcessor",En.LOGOUT="LogoutProcessor",En.REDIRECT="RedirectProcessor",En.PPF="PPFProcessor",(On=An||(An={})).POPUP_V2="POPUP_V2",On.COMMUNICATION="COMMUNICATION";var In,Cn,Ln,jn,Mn;function Nn(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function Dn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e.PRODUCTION="production",e.DEV="dev",e.BOE="boe"}(In||(In={})),(Ln=Cn||(Cn={}))[Ln.COLD_START=0]="COLD_START",(Mn=jn||(jn={})).US_EAST="US-East",Mn.US_EASTRED="US-EastRed",Mn.SINGAPORE_CENTRAL="Singapore-Central",Mn.EU_TTP="EU-TTP",Mn.EU_TTP2="EU-TTP2",Mn.US_TTP="US-TTP",Mn.US_TTP2="US-TTP2";var Rn,Bn,Un=class{init(e){this.apiDomain=e.apiDomain,this.dataLoaderEndpoint=`${this.apiDomain}${this.apiPath}`}_fetch(e,t){return W.info("[CommunicationLoaderModule]: fetch ",this.dataLoaderEndpoint),me.sendRequest(this.dataLoaderEndpoint,"GET",function(e){for(var t=1;tVn[e]}},{region:zn[null!==(n=e.deploymentRegion)&&void 0!==n?n:"DEFAULT"],bid:"pns_communication_service",appId:e.appId,mode:e.mode,debug:e.debug,consumerBid:e.scene,version:"1.0.1"}),W.reportCUJ(Rn.SDK_INIT,O.PY.START);try{this._isInitialized=!0,this._dataLoader=new Fn,this._dataLoader.init(e),this._callbackAPI=`${e.apiDomain}/tiktok/popup/callback/v1`,xn.init({lang:e.lang}),me.init({domain:e.apiDomain,commonParams:{region:e.region,priority_region:e.region,aid:e.appId,device_id:e.wid,app_language:e.lang,device_platform:e.isMobile?"web_mobile":"web_pc"}}),this._onComplete=e.onComplete,W.reportCUJ(Rn.SDK_INIT,O.PY.FINISH)}catch(e){W.reportCUJ(Rn.SDK_INIT,O.PY.FAILURE,{error:e})}}}isInitialized(){return W.info("[CommunicationServiceSDK]: SDK isInitialized!"),this._isInitialized}registerActionFactory(e){for(const t of e)xn.registerActionFactory(t.key,t.instance)}onActionsComplete(){W.info("[CommunicationServiceSDK]: onActionsComplete"),this._onComplete&&this._onComplete()}sendCallbackRequest(e){var t=this;return qn((function*(){W.reportCUJ(Rn.SEND_CALLBACK,O.PY.START);try{const n="object"==typeof e?new URLSearchParams((e=>{const t={};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)){const i=e[n];void 0!==i&&(t[n]=String(i))}return t})(e)):e;yield me.sendRequest(t._callbackAPI,"POST",n,{headers:{"Content-Type":"application/x-www-form-urlencoded"}}),W.info("[Action]: sendCallback success"),W.reportCUJ(Rn.SEND_CALLBACK,O.PY.FINISH)}catch(e){W.error("[Action]: sendCallback error",e),W.reportCUJ(Rn.SEND_CALLBACK,O.PY.FAILURE,{error:e})}}))()}destruct(){W.info("[CommunicationServiceSDK]: destruct"),me.destruct(),W.destruct(),xn.destruct(),Pn.destruct(),this._dataLoader=void 0,this._isInitialized=!1}constructor(){this._isInitialized=!1,this._actionExecutionInProgress=!1,this._isActionExecuting=()=>!!this._actionExecutionInProgress&&(W.info("[CommunicationServiceSDK]: actionExecutionInProgress is true!"),!0);var e,t=this;this.execute=(e=qn((function*(e,n){if(t._isInitialized&&!t._isActionExecuting()){W.reportCUJ(Rn.EXECUTE,O.PY.START);try{var i;t._actionExecutionInProgress=!0,W.reportCUJ(Rn.EXECUTE,O.PY.IN_PROGRESS,{stepName:"LOAD_DATA_START"});const o=yield null===(i=t._dataLoader)||void 0===i?void 0:i.loadData(e,n);if(W.reportCUJ(Rn.EXECUTE,O.PY.IN_PROGRESS,{stepName:"LOAD_DATA_FINISH"}),!o)return t._actionExecutionInProgress=!1,void W.reportCUJ(Rn.EXECUTE,O.PY.FINISH);yield xn.executeActions(o),t.onActionsComplete(),t._actionExecutionInProgress=!1,W.reportCUJ(Rn.EXECUTE,O.PY.FINISH)}catch(e){t._actionExecutionInProgress=!1,W.reportCUJ(Rn.EXECUTE,O.PY.FAILURE,{error:e})}}})),function(t,n){return e.apply(this,arguments)});var n=this;return this._executeActions=function(){var e=qn((function*(e){if(n._isActionExecuting())return;n._actionExecutionInProgress=!0;const t=JSON.parse(e);yield xn.executeActions(t),n.onActionsComplete(),n._actionExecutionInProgress=!1}));return function(t){return e.apply(this,arguments)}}(),Gn._instance||(Gn._instance=this),Gn._instance}}var $n=new Gn;function Wn(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}class Zn{init(e){this.lang=e.lang}destruct(){W.info(`[Action ${this._actionType}]: destruct`),this.dataModel=null}constructor(){this.lang="";var e,t,n=this;this.execute=(e=function*(e){n.processData(e);try{n.executeAction()}catch(e){return e instanceof Error?Promise.reject(e):Promise.reject(new Error(`[Action ${n._actionType}]: execute fail with unknown error`))}return new Promise((e=>{n._executionResolve=e}))},t=function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){Wn(a,i,o,r,s,"next",e)}function s(e){Wn(a,i,o,r,s,"throw",e)}r(void 0)}))},function(e){return t.apply(this,arguments)}),this.completeAction=()=>{this._executionResolve?this._executionResolve():W.error(`[Action ${this._actionType}]: try to complete action before execution`);try{var e;null===(e=this.onActionComplete)||void 0===e||e.call(this)}catch(e){e instanceof Error?W.error(`[Action ${this._actionType}]: onActionComplete fail with error: ${e.message}`):W.error(`[Action ${this._actionType}]: onActionComplete fail with unknown error`)}},this._actionType=this.getActionType(),this.dataModel=null}}class Yn{}var Kn=$n,Xn=n(18499);const Qn="pns-communication-service";var Jn,ei;!function(e){e.CALLBACK="callback",e.H5="h5"}(Jn||(Jn={})),function(e){e.INFO="info",e.ACTION="action"}(ei||(ei={}));const ti="${locale}";function ni({link:e,lang:t}){return e.replace(ti,t)}function ii({lang:e,body:t,bodyLinks:n}){if(!t)return;if(!n||0===n.length)return[{type:We.TEXT,text:t}];const i=[],o=t;let a=0;const r=/%s/g;return n.forEach((({name:t,link:n="",operation:s,dismiss:l,approve:c,new_web_tab:d,extra:u,link_type:p})=>{const v=r.exec(o);if(!v)return;const m=ni({link:n,lang:e}),g=Boolean(c||l),h=p===Jn.CALLBACK||c;let _;_=n?d?Ze.LINK_EXTERNAL:Ze.LINK_INTERNAL:"";const f={type:n?We.LINK:We.BUTTON,text:t,link:m,linkType:d?Ge.EXTERNAL:Ge.INTERNAL,action:{actionType:_,link:m,dismiss:g,callback:h,extra:u,operation:s}};i.push({type:We.TEXT,text:o.slice(a,v.index)}),i.push(f),a=Number(v.index)+v[0].length})),i.push({type:We.TEXT,text:o.slice(a)}),i}function oi({lang:e,first_button_highlight:t,rawButtons:n}){if(0===n.length)return;const i=[];return n.forEach((({text:n,is_bold:o,link_type:a,link:r,extra:s,approve:l,operation:c,dismiss:d,dismiss_all:u,new_web_tab:p,is_close_style:v},m)=>{const g=Boolean(l||d||u),h=a===Jn.CALLBACK||l;let _;_=r?p?Ze.LINK_EXTERNAL:Ze.LINK_INTERNAL:"";const f={text:n,isCloseStyle:v,isBold:Boolean(o),isHighlight:0===m&&t,link:r?ni({link:r,lang:e}):void 0,linkType:p?Ge.EXTERNAL:Ge.INTERNAL,action:{actionType:_,link:r?ni({link:r,lang:e}):void 0,dismiss:g,callback:h,extra:s,operation:c}};i.push(f)})),i}function ai(e){if(e)return{url:e,width:"auto",height:"48px"}}function ri({links:e,lang:t}){if(!e||0===e.length)return;const n=[];return e.forEach((({text:e,action:i})=>{var o,a,r;const s={name:e,action:{actionType:null!==(a=null===(o=i.action_type)||void 0===o?void 0:o[0])&&void 0!==a?a:"",actionId:i.id,link:ni({link:null!==(r=i.link)&&void 0!==r?r:"",lang:t}),dismiss:i.dismiss,defaultOn:i.default_on,callback:i.callback,extra:i.extra,operation:i.operation,isHighlighted:i.is_highlighted}};n.push(s)})),n}const si=e=>{const{data:t,uiConfig:n}=e,{isDark:i,direction:o="ltr",showFullSideNav:a,debug:r,deploymentRegion:s}=n;return t&&(0,v.jsx)(pn,{eventReport:_n.f.event.bind(_n.f),pnsPopupConfig:t,colorScheme:i?"dark":"light",textDirection:o,componentConfig:a?{pcBanner:{topOffset:"0"}}:void 0,monitorConfig:{sdkConfig:{bid:"pns_communication_service",debug:r,appId:1988,deploymentRegion:s}}})};class li extends Zn{constructor(e){super(),this._onActionCallback=(e,t)=>{if(t.callback){const n={business:e.business,policy_version:e.policyVersion,style:this._style,extra:t.extra,operation:t.operation};Kn.sendCallbackRequest(n)}},this._onDismissCallback=()=>{this.completeAction()},this._uiConfig=e}getActionType(){return Sn.POPUP}_generatePopupDataV1(e){const t={eventInfo:{style:e.style,business:e.business},popupType:e.style,title:e.title,icon:ai(e.icon_url),iconDark:ai(e.icon_url_dark),body:ii({lang:this.lang,body:e.body,bodyLinks:e.body_link_list}),buttons:oi({lang:this.lang,first_button_highlight:Boolean(e.first_button_highlight),rawButtons:e.actions||[]})};return this._style=e.style,t}_processV1ResData(e){return{metaData:{business:e.business,popup_id:e.business,policyVersion:e.policy_version},popupData:this._generatePopupDataV1(e),callback:{onAction:this._onActionCallback,onDismiss:this._onDismissCallback}}}_generateBlocks(e){const t=[];return e.forEach((e=>{var n,i,o,a,r,s,l,c,d,u,p,v,m,g,h;const _={marginLeft:null===(n=e.format)||void 0===n?void 0:n.margin_left,marginRight:null===(i=e.format)||void 0===i?void 0:i.margin_right,marginTop:null===(o=e.format)||void 0===o?void 0:o.margin_top,marginBottom:null===(a=e.format)||void 0===a?void 0:a.margin_bottom,paddingLeft:null===(r=e.format)||void 0===r?void 0:r.padding_left,paddingRight:null===(s=e.format)||void 0===s?void 0:s.padding_right,paddingTop:null===(l=e.format)||void 0===l?void 0:l.padding_top,paddingBottom:null===(c=e.format)||void 0===c?void 0:c.padding_bottom,cornerRadius:null===(d=e.format)||void 0===d?void 0:d.corner_radius,cornerPosition:null===(u=e.format)||void 0===u?void 0:u.corner_position},f=new Map;switch(e.type){case ei.ACTION:[{name:"action_left",rawAction:null===(p=e.elements)||void 0===p?void 0:p.action_left},{name:"action_center",rawAction:null===(v=e.elements)||void 0===v?void 0:v.action_center},{name:"action_right",rawAction:null===(m=e.elements)||void 0===m?void 0:m.action_right}].forEach((({name:e,rawAction:t})=>{var n,i,o,a,r,s,l,c,d,u,p,v;if(t){const m={subtype:null!==(n=t.subtype)&&void 0!==n?n:"",action:{actionType:null!==(a=null===(o=null===(i=t.action)||void 0===i?void 0:i.action_type)||void 0===o?void 0:o[0])&&void 0!==a?a:"",actionId:null===(r=t.action)||void 0===r?void 0:r.id,link:ni({link:null!==(l=null===(s=t.action)||void 0===s?void 0:s.link)&&void 0!==l?l:"",lang:this.lang}),dismiss:null===(c=t.action)||void 0===c?void 0:c.dismiss,defaultOn:null===(d=t.action)||void 0===d?void 0:d.default_on,callback:null===(u=t.action)||void 0===u?void 0:u.callback,extra:null===(p=t.action)||void 0===p?void 0:p.extra,isHighlighted:null===(v=t.action)||void 0===v?void 0:v.is_highlighted},text:t.text};f.set(e,m)}}));break;case ei.INFO:default:if(null===(g=e.elements)||void 0===g?void 0:g.content){const t=e.elements.content,n={subtype:null!==(h=t.subtype)&&void 0!==h?h:"",text:t.text,font:t.font,align:t.align,iconUrl:t.icon_url,iconUrlDark:t.icon_url_dark,iconStyle:t.icon_style,groupId:t.group_id,bodyLinks:ri({links:t.body_links,lang:this.lang})};f.set("content",n)}}const y={id:e.id,type:e.type,format:_,elements:f};t.push(y)})),t}_generateBlockData(e){var t,n,i;const o={topPinnedBlocks:this._generateBlocks(null!==(t=e.top_pinned_blocks)&&void 0!==t?t:[]),blocks:this._generateBlocks(null!==(n=e.blocks)&&void 0!==n?n:[]),bottomPinnedBlocks:this._generateBlocks(null!==(i=e.bottom_pinned_blocks)&&void 0!==i?i:[]),style:e.style,upperRightClose:e.upper_right_close,upperLeftBack:e.upper_left_back,dismissOutside:e.dismiss_click_outside};return this._style=e.style,o}_processV2ResData(e){var t,n,i,o;return{metaData:{business:null===(t=e.popup_meta)||void 0===t?void 0:t.business,popup_id:null===(n=e.popup_meta)||void 0===n?void 0:n.popup_id,policyVersion:null!==(o=null===(i=e.popup_meta)||void 0===i?void 0:i.version)&&void 0!==o?o:""},blockData:this._generateBlockData(e.popup_ui),callback:{onAction:this._onActionCallback,onDismiss:this._onDismissCallback}}}processData(e){const t=JSON.parse(e),n=t.popup_responses,i=t.policy_notices;n&&0!==n.length?this.dataModel=this._processV2ResData(n[0]):i&&0!==i.length&&(this.dataModel=this._processV1ResData(i[0]))}executeAction(){const e=document.getElementById(Qn),t=(0,v.jsx)(si,{data:this.dataModel,uiConfig:this._uiConfig});if(!e)throw new Error("popup action error: no root element found");Xn.render(t,e)}}class ci extends Yn{constructor(e){super(),this._uiConfig=e}createAction(){return new li(this._uiConfig)}}class di extends Zn{getActionType(){return Sn.LOGOUT}processData(e){this.dataModel=JSON.parse(e)}executeAction(){window.location.href="https://www.tiktok.com/logout"}}class ui extends Yn{createAction(){return new di}}const pi=()=>{var e;const{initCommunicationServiceSDK:t}=(()=>{var e,t;const n=null!==(e=(0,h.W)((()=>["language","wid","region","user","env","clusterRegion"]),[]))&&void 0!==e?e:null,i=null!==(t=(0,_.U)((()=>["isMobile"]),[]))&&void 0!==t?t:null,o=(0,m.useCallback)((()=>{var e,t;if(!n||!i)return!1;const{language:o,wid:a,region:r,user:s,env:l,clusterRegion:c}=n,d={apiDomain:"",appId:1988,uid:null!==(e=null==s?void 0:s.uid)&&void 0!==e?e:"",wid:null!=a?a:"",lang:null!=o?o:"en",isMobile:null!==(t=i.isMobile)&&void 0!==t&&t,region:null!=r?r:"",debug:"boe"===(null==l?void 0:l.type)||"ppe"===(null==l?void 0:l.type),deploymentRegion:null!=c?c:""};return Kn.init(d),!0}),[n,i]);return{initCommunicationServiceSDK:o}})(),{isDark:n,direction:i}=(0,hn.u)(),{showFullSideNav:o}=(0,f.Oj)(),{env:a,clusterRegion:r}=null!==(e=(0,h.W)((()=>["env","clusterRegion"]),[]))&&void 0!==e?e:{},[s,l]=(0,m.useState)(!1);return(0,m.useEffect)((()=>{const e=t();l(e),Kn.registerActionFactory([{key:Sn.POPUP,instance:new ci({showFullSideNav:o,isDark:n,direction:i,debug:"boe"===(null==a?void 0:a.type)||"ppe"===(null==a?void 0:a.type),deploymentRegion:r})},{key:Sn.LOGOUT,instance:new ui}])}),[t,n,i,o,a,r]),(0,m.useEffect)((()=>{s&&Kn.execute(Cn.COLD_START)}),[s]),(0,v.jsx)("div",{id:Qn})},vi=function(e){return(0,f.KK)()?(0,v.jsx)(pi,{}):(0,v.jsx)(fn,Object.assign({},e))}},85612:(e,t,n)=>{"use strict";n.d(t,{B9:()=>s,OK:()=>a,Pl:()=>l,Rj:()=>o,Rp:()=>r,Vb:()=>c});var i=n(58632);function o(e,t){const n=function(e){const t=[];for(const[n]of Object.entries(e)){const i=`${n}=${encodeURIComponent(e[n])}`;t.push(i)}return t.join("&")}(t);return e.indexOf("?")>-1?`${e}&${n}`:`${e}?${n}`}function a(e,t){var n;const i={},o=function(e){if("string"==typeof e){let t={};try{t=JSON.parse(e)}catch(e){return{}}return t}return e}(e);for(const[e]of Object.entries(o)){const a=o[e];if("string"==typeof a){const o=a.split(".");let r=t;for(;o.length>0&&void 0!==r;)r=r[null!==(n=o.shift())&&void 0!==n?n:""];i[e]=r}}return i}function r(e,t){if(void 0!==t)for(const n of e)if(t===n.reason_code)return n;return null}function s(e){return/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e)}function l(e){return["live","live_comment","live_star_comment"].includes(e)}const c=(e,t,o)=>{if(!(null==t?void 0:t.need_captcha)||!(null==t?void 0:t.decision_conf))return Promise.resolve();{const a=JSON.parse(t.decision_conf).region;let r;switch(a){case"ttp":case"ttp2":r=n.e(2318).then(n.bind(n,10906));break;case"in":case"ie":case"ie2":r=n.e(1427).then(n.bind(n,17819));break;default:r=n.e(4336).then(n.bind(n,41002))}null==r||r.then((n=>(0,i.__awaiter)(void 0,void 0,void 0,(function*(){const i=yield n.getFp();n.init({commonOptions:{aid:1988,iid:"0",did:e},captchaOptions:{fp:i,showMode:"mask",successCb:()=>{console.log("verification passed, retry report"),null==o||o()}}},(()=>{console.log(`verification sdk (region: ${a}, wid: ${e}) initialize successfully`)}),(t=>{console.log(`verification sdk (region: ${a}, wid: ${e}) initialize failed`,t)})),n.render({verify_data:t.decision_conf})}))))}}},81230:(e,t,n)=>{"use strict";n.d(t,{s:()=>s});var i=n(58632),o=n(64162),a=n(4126),r=n(93995);let s=class extends o.E{constructor(){super(),this.defaultState={visible:!1,violationAppealInfo:{objectId:void 0,objectType:void 0,punishKey:void 0,penaltyDetails:void 0}}}setVisible(e,t){e.visible=t}setViolationAppealInfo(e,t){e.violationAppealInfo=t}};(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",void 0)],s.prototype,"setVisible",null),(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],s.prototype,"setViolationAppealInfo",null),s=(0,i.__decorate)([(0,r.n)("ViolationAppealModal"),(0,i.__metadata)("design:paramtypes",[])],s)},15637:(e,t,n)=>{"use strict";var i,o,a,r,s,l,c;n.d(t,{AT:()=>o,Ls:()=>s,d7:()=>d,fZ:()=>u,gq:()=>p,nW:()=>a,qZ:()=>c,w$:()=>i,ww:()=>r}),function(e){e.VIDEO="1",e.COMMENT="3",e.PROFILE="4",e.DM="5",e.SUICIDE="7",e.AUDIO="8",e.OLD_COPYRIGHT="101",e.COPYRIGHT="102",e.NETZDG_REPORTER="103",e.NETZDG="104",e.ANCHOR="105",e.LIVE_REPORTER="107",e.LIVE_COMMENT_REPORTER="130",e.PHOTO_AVIA_REPORTER="210",e.LIVE_COMMENT="302",e.COMMENT_NETZDG="303",e.COMMENT_NETZDG_REPORTER="304",e.AUDIO_COMMUNITY_GUIDELINE="801",e.AUDIO_COPYRIGHT="802",e.AUDIO_MULTIPLE_VIOLATIONS="803",e.MASK_LAYER="1011",e.COPYRIGHT_AUTO_REMOVAL="1014",e.DMCA_VIDEO="1024",e.DMCA_POST="1025",e.TRADEMARK_VIDEO="1026",e.TRADEMARK_POST="1027",e.COPYRIGHT_STRIKE="1033",e.TRADEMARK_STRIKE="1034",e.DSA_ILLEGAL_VIDEO="1035",e.DSA_ILLEGAL_PHOTO="1037",e.DSA_ILLEGAL_EFFECT="1041",e.SeriesVideoCopyright="1042",e.SeriesVideoTrademark="1043",e.SeriesCollectionCopyright="1044",e.SeriesCollectionTrademark="1045",e.DSA_ILLEGAL_PROFILE="2016",e.DSA_ILLEGAL_COMMENT="3006",e.OneLinerDSA="3008",e.SeriesReviewDSA="3009",e.DSA_CG_AUDIO="4000",e.DMCA_AUDIO="4001",e.DSA_ILLEGAL_AUDIO="4003",e.DSA_NR_AUDIO="4004",e.MCC_AUDIO="4005",e.COPYRIGHT_PROFILE="2011",e.TRADEMARK_PROFILE="2012",e.SUSPEND_LINK="2005",e.LiveCommentDSA="5005",e.HASHTAG="8000",e.CONTENT_CHECK_VIDEO="9000",e.RESET_LINK="20051",e.POI_COMMENT="300000",e.POI_COMMENT_ILLEGAL="300004",e.SUB_SPACE_COMMENT="300005",e.SUB_SPACE_COMMENT_ILLEGAL="300006"}(i||(i={})),function(e){e.VIDEO="video",e.COMMENT="comment",e.AUDIO="audio",e.LINK="link",e.USER="user",e.IMAGE="image",e.HASHTAG="hashtag",e.HEART="heart",e.STATUS_SUCCESS="status_success",e.STATUS_FAIL="status_fail",e.STATUS_FAIL_LIGHT="status_fail_light",e.STATUS_RECEIVED="status_received",e.PHOTO="photo",e.PROFILE="profile"}(o||(o={})),function(e){e[e.ON_APPEAL=0]="ON_APPEAL",e[e.NOT_APPEAL=1]="NOT_APPEAL",e[e.APPEAL_SUCCESS=2]="APPEAL_SUCCESS",e[e.APPEAL_FAIL=3]="APPEAL_FAIL",e[e.APPEAL_EXPIRED=4]="APPEAL_EXPIRED",e[e.CANNOT_APPEAL=5]="CANNOT_APPEAL"}(a||(a={})),function(e){e[e.VIOLATION_INFO_SUCCESS=1]="VIOLATION_INFO_SUCCESS",e[e.VIOLATION_INFO_VIOLATION=2]="VIOLATION_INFO_VIOLATION",e[e.VIOLATION_INFO_NR=3]="VIOLATION_INFO_NR",e[e.VIOLATION_INFO_NFF=4]="VIOLATION_INFO_NFF",e[e.VIOLATION_INFO_IN_PROGRESS=5]="VIOLATION_INFO_IN_PROGRESS"}(r||(r={})),function(e){e[e.UNCHANGEABLE=0]="UNCHANGEABLE",e[e.CHANGEABLE=1]="CHANGEABLE",e[e.CHANGED=2]="CHANGED"}(s||(s={})),function(e){e[e.NORMAL=0]="NORMAL",e[e.EXPIRE=1]="EXPIRE",e[e.EXCEED=2]="EXCEED",e[e.NOT_SUPPORTED=3]="NOT_SUPPORTED"}(l||(l={})),function(e){e[e.STATUS=0]="STATUS",e[e.SUBMIT=1]="SUBMIT"}(c||(c={}));const d=[i.VIDEO,i.DSA_ILLEGAL_VIDEO],u="https://www.tiktok.com/violation-appeal",p=[i.LIVE_REPORTER,i.LIVE_COMMENT_REPORTER];i.DSA_ILLEGAL_VIDEO,i.DSA_ILLEGAL_PHOTO,i.DSA_ILLEGAL_EFFECT,i.DSA_ILLEGAL_PROFILE,i.DSA_ILLEGAL_COMMENT,i.OneLinerDSA,i.SeriesReviewDSA,i.DSA_ILLEGAL_AUDIO,i.LiveCommentDSA,i.POI_COMMENT_ILLEGAL,i.SUB_SPACE_COMMENT_ILLEGAL},31367:(e,t,n)=>{"use strict";n.d(t,{D_:()=>l,Fh:()=>d,JN:()=>s,JS:()=>a,KW:()=>g,Ko:()=>c,Lo:()=>m,NR:()=>h,Rh:()=>v,TU:()=>f,UP:()=>w,Ug:()=>b,an:()=>u,bq:()=>r,fm:()=>_,g$:()=>A,jl:()=>k,lg:()=>x,n4:()=>E,nM:()=>p,rW:()=>T,sP:()=>S,uH:()=>O});var i=n(62186),o=n(72153);const a=(0,i.default)("form",{target:"ezqf9p60"})((({theme:e})=>[(0,o.zy)({theme:e,typography:"H6"}),{zIndex:2,background:e.colors.BGPrimary,borderRadius:"8px",overflow:"hidden",width:"700px",margin:0}]),"label:FormReport;"),r=(0,i.default)("div",{target:"ezqf9p61"})((({theme:e})=>({width:"400px",zIndex:2,background:e.colors.BGPrimary,borderRadius:"8px",overflow:"hidden",margin:0})),"label:DivFormBox;"),s=(0,i.default)("div",{target:"ezqf9p62"})({display:"flex",alignItems:"center",padding:"24px 24px 16px",height:"72px"},"label:DivFormHeader;"),l=(0,i.default)("div",{target:"ezqf9p63"})({cursor:"pointer",padding:"6px",height:"32px"},"label:DivBackButton;"),c=(0,i.default)("div",{target:"ezqf9p64"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),d=(0,i.default)("h4",{target:"ezqf9p65"})((({theme:e})=>({fontSize:"20px",lineHeight:"32px",color:e.colors.TextPrimary,fontFamily:e.fontFamilies.TikTokFont,fontWeight:e.fontWeights.bold,textAlign:"rtl"===e.direction?"right":"left",flex:1})),"label:H4FormTitle;");d.defaultProps=Object.assign(Object.assign({},d.defaultProps),{"data-e2e":"report-card-title"});const u=(0,i.default)("div",{target:"ezqf9p66"})((({theme:e})=>({borderTop:`1px solid ${e.colors.LineSecondary}`,height:"50vh",overflowY:"auto",overflowX:"hidden",padding:"16px 16px 0px"})),"label:DivRadioWrapper;"),p=(0,i.default)(u,{target:"ezqf9p67"})({padding:"0px 16px 100px",display:"flex",flexDirection:"column"},"label:DivSubmitWrapper;"),v=(0,i.default)("div",{target:"ezqf9p68"})((({theme:e})=>({paddingBottom:"8px",paddingLeft:"8px",color:e.colors.TextSecondary,height:"22px",lineHeight:"22px"})),"label:DivSelectText;"),m=(0,i.default)("div",{target:"ezqf9p69"})((({theme:e})=>({color:e.colors.TextPrimary,lineHeight:"22px",fontSize:"16px",userSelect:"none"})),"label:DivReasonText;"),g=(0,i.default)("label",{target:"ezqf9p610"})((({theme:e})=>({boxSizing:"border-box",minHeight:"54px",display:"flex",flex:"1 1 100%",flexDirection:"row",alignItems:"center",cursor:"pointer",position:"relative",wordBreak:"break-all",justifyContent:"space-between",padding:"8px",borderRadius:"8px",":hover":{background:e.colors.BGPlaceholderOpaque}})),"label:LabelRadio;");g.defaultProps=Object.assign(Object.assign({},g.defaultProps),{"data-e2e":"report-card-reason"});const h=(0,i.default)(g,{target:"ezqf9p611"})({justifyContent:"flex-start"},"label:RadioReasonChoice;"),_=(0,i.default)(m,{target:"ezqf9p612"})({padding:"0 12px"},"label:RadioReasonText;"),f=(0,i.default)("div",{target:"ezqf9p613"})({position:"absolute",left:"50%",top:"50%",transform:"translate(-50% , -50%)"},"label:DivMMid;"),y=(0,i.default)("div",{target:"ezqf9p614"})((({theme:e})=>({padding:"8px",color:e.colors.TextPrimary,fontSize:"18px",lineHeight:"24px"})),"label:DivTitle;"),b=(0,i.default)(y,{target:"ezqf9p615"})((({theme:e})=>({width:"calc(100% + 32px)",margin:"0 0 12px -16px",padding:"16px 24px",backgroundColor:e.colors.BGPlaceholderDefault})),"label:DivSubmitTitle;"),w=(0,i.default)("div",{target:"ezqf9p616"})((({theme:e})=>({padding:"4px 4px 10px 8px",color:e.colors.TextSecondary,fontSize:"16px",lineHeight:"22px"})),"label:DivSubTitle;"),x=(0,i.default)("li",{target:"ezqf9p617"})((({theme:e})=>({padding:"6px 6px 6px 0px",color:e.colors.TextSecondary,fontSize:"16px",lineHeight:"22px"})),"label:LiItem;"),T=(0,i.default)("div",{target:"ezqf9p618"})((({theme:e})=>({position:"absolute",bottom:"0",left:"0",height:"84px",width:"100%",borderTop:`0.5px solid ${e.colors.LinePrimary2}`,backgroundColor:e.colors.BGPrimary})),"label:DivFooter;"),k=(0,i.default)("button",{target:"ezqf9p619"})((({theme:e})=>({height:"36px",padding:"7px 16px",lineHeight:"22px",fontSize:"16px",position:"absolute",cursor:"pointer",top:"24px",right:"24px",color:e.colors.ConstTextInverse,background:e.colors.Primary,border:"none",borderRadius:"4px",":disabled":{background:e.colors.BGPlaceholderDefault,color:e.colors.TextQuaternary}})),"label:ButtonSubmit;"),S=(0,i.default)("div",{target:"ezqf9p620"})((({theme:e,top:t})=>({height:"72px",width:"72px",margin:"32px auto 24px",borderRadius:"36px",background:e.colors.BGView,padding:`${t}px 20px`})),"label:DivIconRoundBg;"),E=(0,i.default)("div",{target:"ezqf9p621"})((({theme:e})=>({margin:"0px auto 16px",padding:"0 32px",color:e.colors.TextPrimary,textAlign:"center",lineHeight:"32px",fontSize:"24px"})),"label:DivFinishTitle;"),A=(0,i.default)("div",{target:"ezqf9p622"})((({theme:e})=>({margin:"0px auto 24px",padding:"0 32px",color:e.colors.TextSecondary,textAlign:"center",lineHeight:"22px",fontSize:"16px"})),"label:DivFinishContent;"),O=(0,i.default)("button",{target:"ezqf9p623"})((({theme:e})=>({width:"336px",height:"46px",background:e.colors.Primary,margin:"0 32px 32px",borderRadius:"4px",textAlign:"center",lineHeight:"46px",fontSize:"16px",color:e.colors.ConstTextInverse,border:"none",cursor:"pointer"})),"label:ButtonFinish;")},48831:(e,t,n)=>{"use strict";n.d(t,{K:()=>v});var i=n(24643),o=n(41271),a=n(46682),r=n(40099),s=n(47172),l=n(47926),c=n(81230),d=n(49503);const u=(0,n(62186).default)("div",{target:"exv8p100"})((({theme:e})=>({width:"700px",backgroundColor:e.colors.BGPlaceholderOpaque})),"label:ViolationAppealWrapper;");var p=n(42617);const v=(0,r.memo)((function(){const e=function(){const{search:e}=(0,s.useLocation)();return(0,r.useMemo)((()=>new URLSearchParams(e)),[e])}(),[t,n]=(0,r.useState)(!1),v=(0,o.P)(c.s),m=(0,a.w)(c.s),g=(0,r.useRef)(0),[h,_]=(0,r.useState)({objectId:void 0,objectType:void 0,punishKey:void 0,penaltyDetails:void 0}),f=(0,r.useMemo)((()=>e.has("object_id")&&e.has("object_type")&&g.current<2||v.visible),[e,v,g.current]);(0,r.useEffect)((()=>{var t,i,o,a,r,s,l,c,d,u,p;if(f){const m=e.get("object_id"),h=e.get("object_type"),f=e.get("punish_key");return _({objectId:null!==(o=null!==(i=null===(t=v.violationAppealInfo)||void 0===t?void 0:t.objectId)&&void 0!==i?i:m)&&void 0!==o?o:void 0,objectType:null!==(s=null!==(r=null===(a=v.violationAppealInfo)||void 0===a?void 0:a.objectType)&&void 0!==r?r:h)&&void 0!==s?s:void 0,punishKey:null!==(d=null!==(c=null===(l=v.violationAppealInfo)||void 0===l?void 0:l.punishKey)&&void 0!==c?c:f)&&void 0!==d?d:void 0,penaltyDetails:null!==(p=null===(u=v.violationAppealInfo)||void 0===u?void 0:u.penaltyDetails)&&void 0!==p?p:void 0}),g.current++,void n(!0)}n(!1)}),[f,v]);const y=(0,r.useCallback)((()=>{m.setVisible(!1),n(!1)}),[]);return(0,i.jsx)(p.Ay,{autoFocus:!0,disabled:!t,returnFocus:!0,children:(0,i.jsx)(l.i,{compact:!0,isOpen:t,closeOnEsc:!0,children:(0,i.jsx)(u,{children:(0,i.jsx)(d.A,{objectId:h.objectId,objectType:h.objectType,punishKey:h.punishKey,penaltyDetails:h.penaltyDetails,onClose:()=>{y()}})})})})}))},49503:(e,t,n)=>{"use strict";n.d(t,{A:()=>On});var i,o,a,r,s,l,c,d,u=n(24643),p=n(46682),v=n(58632),m=n(64162),g=n(4126),h=n(93995),_=n(340);!function(e){e[e.VIDEO=1]="VIDEO",e[e.PHOTO_MODE=2]="PHOTO_MODE"}(i||(i={})),function(e){e[e.PUBLIC=1]="PUBLIC",e[e.PRIVATE=2]="PRIVATE",e[e.FRIENDS=3]="FRIENDS",e[e.INVISIBLE=4]="INVISIBLE"}(o||(o={})),function(e){e[e.OTHER=0]="OTHER",e[e.COMMUNITY_GUIDELINES=1]="COMMUNITY_GUIDELINES",e[e.TOBACCO=2]="TOBACCO",e[e.VIOLENT=3]="VIOLENT",e[e.DANGEROUS=4]="DANGEROUS",e[e.OVERLY_SEXUALIZED=5]="OVERLY_SEXUALIZED",e[e.SPAM=6]="SPAM",e[e.UNORIGINAL=7]="UNORIGINAL",e[e.MINOR_SAFETY=8]="MINOR_SAFETY",e[e.UNORIGINAL_NR=9]="UNORIGINAL_NR",e[e.REPRODUCED=10]="REPRODUCED"}(a||(a={})),function(e){e[e.CAN_SUBMIT=0]="CAN_SUBMIT",e[e.CANNOT_SUBMIT=1]="CANNOT_SUBMIT",e[e.NO_PENALTY=2]="NO_PENALTY",e[e.REVIEWING=3]="REVIEWING",e[e.SUCCEEDED=4]="SUCCEEDED",e[e.FAILED=5]="FAILED",e[e.TIMEOUT=6]="TIMEOUT"}(r||(r={})),function(e){e[e.SUBMITTED=0]="SUBMITTED",e[e.NOT_SUBMITTED=1]="NOT_SUBMITTED"}(s||(s={})),function(e){e[e.PENALTY_TYPE_NR=0]="PENALTY_TYPE_NR",e[e.PENALTY_TYPE_NFF=1]="PENALTY_TYPE_NFF"}(l||(l={})),function(e){e[e.PENALTY_SOURCE_HUMAN=0]="PENALTY_SOURCE_HUMAN",e[e.PENALTY_SOURCE_MACHINE=1]="PENALTY_SOURCE_MACHINE"}(c||(c={})),function(e){e[e.PENALTY_TRIGGER_REPORT=0]="PENALTY_TRIGGER_REPORT",e[e.PENALTY_TRIGGER_RECALL=1]="PENALTY_TRIGGER_RECALL"}(d||(d={}));var f=n(15637),y=n(64356),b=n(55322),w=n(7672),x=n(55099);let T=class{constructor(e){this.fetch=e}getAppealReasons({appeal_type:e,object_id:t}){return this.fetch.get("/tns-api/appeal/reason",{query:Object.assign({appeal_type:e},t&&{object_id:t}),baseUrlType:2})}getViolationDetail({objectId:e,objectType:t,punishKey:n}){return this.fetch.get("/tns-api/appeal/violation-detail",{query:Object.assign({object_id:e,object_type:t},n&&{punish_key:n}),baseUrlType:2})}getPenaltyDetail({vid:e,storeRegion:t,lang:n}){return this.fetch.get("/mod/v1/getPenaltyDetails/",{query:{vid:e,storeRegion:t,lang:n},baseUrlType:2})}getReporterAppeal(e){return this.fetch.get("/tns-api/appeal/reporter-appeal",{query:e,baseUrlType:2})}postAppealCommit({objectId:e,punishKey:t,appealType:n,reason:i}){return this.fetch.post("/tns-api/appeal/post-commit",{body:JSON.stringify({object_id:e,appeal_type:n,reason:i,punish_key:t,appeal_uri:"",extra:""}),baseUrlType:2,headers:{"content-type":"application/json"}})}postReporterAppeal({reportType:e,objectId:t,objectOwnerId:n,reason:i,uri:o,reportDesc:a,reportId:r,reporterAppealReason:s,loggedOutCode:l,relevantLaw:c,trustedFlaggerEmail:d,logoutReporterEmail:u,legalJurisdiction:p,relatedTtid:v,relatedUsername:m,commentWithEmoji:g,reportMenuClickTime:h,reporterSignature:_=""}){return this.fetch.get("/aweme/v2/aweme/feedback/",{query:Object.assign(Object.assign({report_type:e,object_id:t,owner_id:n,reason:i,uri:o,report_desc:a,parent_id:r,reporter_appeal_reason:s,submit_type:"3"},l&&{verification_code:l}),{relevant_law:c,trusted_flagger_email:d,logout_reporter_email:u,legal_jurisdiction:p,related_ttid:v,related_username:m,comment_with_emoji:g,report_menu_click_time:h,reporter_signature:_}),baseUrlType:2})}postLiveReporterAppeal({reportType:e,objectId:t,objectOwnerId:n,reason:i,uri:o,reportDesc:a,reportId:r,reporterAppealReason:s,loggedOutCode:l,relevantLaw:c,trustedFlaggerEmail:d,logoutReporterEmail:u,legalJurisdiction:p,relatedTtid:v,reportMenuClickTime:m,reporterSignature:g="",liveReportType:h="",liveRequestPage:_="",liveCmpIds:f="",liveEnterFromMerge:y="",liveEnterMethod:b="",liveActionType:w="",durationEntranceSubmit:x=0,targetAnchorId:T="",targetAudienceId:k="",reportedUserIds:S="",nonReportedUserIds:E="",roomId:A="",liveChatType:O="",content:P=""}){return this.fetch.post("/webcast/v1/aweme/feedback/",{body:JSON.stringify(Object.assign(Object.assign({report_type:e,object_id:t,owner_id:n,reason:i,uri:o,report_desc:a,parent_id:r,reporter_appeal_reason:s,submit_type:"3"},l&&{verification_code:l}),{relevant_law:c,trusted_flagger_email:d,logout_reporter_email:u,legal_jurisdiction:p,related_ttid:v,report_menu_click_time:m,reporter_signature:g,live_report_type:h,live_request_page:_,live_cmp_ids:f,live_enter_from_merge:y,live_enter_method:b,live_action_type:w,duration_entrance_submit:x,target_anchor_id:T,target_audience_id:k,reported_user_ids:S,non_reported_user_ids:E,room_id:A,live_chat_type:O,content:P})),baseUrlType:4,headers:{"content-type":"application/json"}})}};T=(0,v.__decorate)([(0,w._)(),(0,v.__metadata)("design:paramtypes",[x.p])],T);var k=n(35572),S=n(62564),E=n(74690),A=n(80339),O=n(26324),P=n(22113),I=n.n(P),C=n(300),L=n.n(C);const j={[a.TOBACCO]:0,[a.VIOLENT]:1,[a.DANGEROUS]:2,[a.OVERLY_SEXUALIZED]:3,[a.SPAM]:4,[a.UNORIGINAL]:5,[a.MINOR_SAFETY]:6,[a.UNORIGINAL_NR]:7,[a.REPRODUCED]:8,[a.COMMUNITY_GUIDELINES]:9,[a.OTHER]:10},M=110,N=999,D={[M]:0,[N]:1},R=e=>{var t;return null!==(t=D[e])&&void 0!==t?t:0},B=()=>({[a.MINOR_SAFETY]:{title:"vid_mod_analytics_penalty_reason_minor_title",description:"vid_mod_analytics_penalty_reason_minor_desc"},[a.UNORIGINAL]:{title:"vid_mod_analytics_penalty_reason_unoriginal_title",description:"vid_mod_analytics_penalty_reason_unoriginal_desc"},[a.UNORIGINAL_NR]:{title:"vid_mod_analytics_nr_vid_penalty_reason_unoriginal_title",description:"vid_mod_analytics_nr_vid_penalty_reason_unoriginal_desc"},[a.REPRODUCED]:{title:"vid_mod_analytics_nr_acct_penalty_reason_unoriginal_title",description:"vid_mod_analytics_nr_acct_penalty_reason_unoriginal_desc"},[a.SPAM]:{title:"vid_mod_analytics_penalty_reason_spam_title",description:"vid_mod_analytics_penalty_reason_spam_desc"},[a.OVERLY_SEXUALIZED]:{title:"vid_mod_analytics_penalty_reason_sexual_title",description:"vid_mod_analytics_penalty_reason_sexual_desc"},[a.TOBACCO]:{title:"vid_mod_analytics_penalty_reason_tobacco_title",description:"vid_mod_analytics_penalty_reason_tobacco_desc"},[a.DANGEROUS]:{title:"vid_mod_analytics_penalty_reason_stunts_title",description:"vid_mod_analytics_penalty_reason_stunts_desc"},[a.VIOLENT]:{title:"vid_mod_analytics_penalty_reason_graphic_title",description:"vid_mod_analytics_penalty_reason_graphic_desc"},[a.OTHER]:{title:"vid_mod_analytics_penalty_reason_fyf_title",description:"vid_mod_analytics_penalty_reason_fyf_desc"},[a.COMMUNITY_GUIDELINES]:{title:"vid_mod_analytics_penalty_reason_fyf_title",description:"vid_mod_analytics_penalty_reason_fyf_desc"}}),U={[r.CANNOT_SUBMIT]:f.nW.APPEAL_FAIL,[r.CAN_SUBMIT]:f.nW.ON_APPEAL,[r.NO_PENALTY]:f.nW.APPEAL_SUCCESS,[r.REVIEWING]:f.nW.ON_APPEAL,[r.SUCCEEDED]:f.nW.APPEAL_SUCCESS,[r.FAILED]:f.nW.APPEAL_FAIL,[r.TIMEOUT]:f.nW.APPEAL_EXPIRED};var F=n(11983),V=n(45297),z=n(11654);const H={punish_key:"",object_type:f.w$.VIDEO,object_id:"",content_info_list:[]};let q=class extends m.E{constructor(e,t,n){super(),this.service=e,this.slardarService=t,this.t=n,this.defaultState={detail:H,reporterAppealInfo:null,violationList:[],contentDetailList:[],appealReasons:[],audioCopyrightInfo:null,currentAppealReason:null,status:"init",isV2:!0,surveyData:null,loggedOutCode:null}}setLoggedOutCode(e,t){e.loggedOutCode=t}setCurrentAppealReason(e,t){e.currentAppealReason=t}setPunishKey(e,t){e.punishKey=t}setViolationAppealStatus(e,t){e.status=t}setReporterAppealData(e,t){e.contentDetailList=t.contentDetailList,e.detail=t.detail,e.reporterAppealInfo=t.reporterAppealInfo}setViolationAppealData(e,t){var n,i,o,a;const r=null!==(n=t.detail)&&void 0!==n?n:H,s=(null!==(o=null===(i=null==r?void 0:r.violation_info)||void 0===i?void 0:i.reason)&&void 0!==o?o:[]).map((e=>({title:e.reason_title,content:e.reason_content,content_v2:e.reason_content_v2,url:e.inner_link_url,urlText:e.inner_link_text})));e.detail=r,e.surveyData=null!==(a=t.surveyData)&&void 0!==a?a:null,e.contentDetailList=s}setAppealStatus(e,t){e.detail.violation_info&&e.detail.violation_info.appeal_info&&(e.detail.violation_info.appeal_info.appeal_status=t)}setPenaltyDetailData(e,t){var n,i,o,s;const l=(e=>{if(e.every((e=>e.reason_codes.every((e=>Number(e)<100))))){const t=B();return(e=>{let t=[];if(e.forEach((e=>t=t.concat(e.reason_codes.map(Number)))),t=I()(t.map((e=>Object.keys(j).includes(e.toString())?e:a.OTHER))).sort(((e,t)=>j[e]-j[t])),t.length>=2){const[e,n]=t.slice(-2);(1===n&&0===e||0===n&&1===e)&&t.pop()}return t})(e).map((e=>({code:String(e),description:t[e].description,title:t[e].title})))}let t=[],n=[];return e.forEach((e=>{var i;"TNS"!==e.issuer&&e.reason_codes.forEach((e=>{const{title:t,description:i}=B()[Number(e)];n.push({title:t,code:e,description:i})})),null===(i=e.penalty_reason_info_list)||void 0===i||i.forEach((e=>{const{title:n,content:i,code:o,url:a,link:r,dsa_content:s}=e;t.push({title:n,description:i,dsaDescriptionParagraphs:s,url:a,linkText:r,code:o})}))})),t=L()(t,"code").sort(((e,t)=>R(Number(e.code))-R(Number(t.code)))),n=L()(n,"code"),t.concat(n)})(null!==(n=t.penaltyDetails.penaltyDetails.penalties)&&void 0!==n?n:[]).map((e=>({title:this.t(e.title),content:this.t(e.dsaDescriptionParagraphs?`${e.dsaDescriptionParagraphs.join("\n")}\n${this.t("vidModAnalytics_detailPg_sectionHumanMod_sectionBody")}`:e.description),url:e.url,urlText:e.linkText}))),c=new Date(null!==(i=t.penaltyDetails.videoInfo.Items[0].CreateTime)&&void 0!==i?i:0);let d;d=t.penaltyDetails.penaltyDetails.appeal_status===r.SUCCEEDED?"appeal_approved":t.penaltyDetails.penaltyDetails.appeal_status!==r.CANNOT_SUBMIT&&t.penaltyDetails.penaltyDetails.appeal_status!==r.FAILED||141!==t.penaltyDetails.videoInfo.Items[0].Status?"video_not_eligible":"video_removed";const u={header:this.t("vidModAnalytics_detailPg_sectionVideoDetails_sectionLabel"),title:null!==(o=t.penaltyDetails.videoInfo.Items[0].Desc)&&void 0!==o?o:"",content:this.t("vidModAnalytics_detailPg_sectionDatePosted_sectionLabel").replace("%1$s",c.toLocaleDateString()).replace("%2$s",c.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})),image_url:t.penaltyDetails.videoInfo.Items[0].CoverUrl[0],content_id:t.penaltyDetails.videoInfo.Items[0].Vid?BigInt(t.penaltyDetails.videoInfo.Items[0].Vid):BigInt(0),reason_code:t.penaltyDetails.penaltyDetails.penalties?t.penaltyDetails.penaltyDetails.penalties[0].reason_codes[0]:"",result_type:d};e.detail={object_id:t.penaltyDetails.videoInfo.Items[0].ItemId,object_type:f.w$.VIDEO,punish_key:"",content_info_list:[u],violation_info:{header:this.t("vid_mod_analytics_appeal_detailpg_reason_title"),reason:[],appeal_info:{appeal_status:U[null!==(s=t.penaltyDetails.penaltyDetails.appeal_status)&&void 0!==s?s:2]}},base_info:{appeal_fail_page_title:{title:this.t("vid_mod_analytics_detail_pg_title"),sub_title:this.t("vid_mod_analytics_detail_pg_desc"),icon_type:f.AT.STATUS_FAIL},appeal_success_page_title:{title:this.t("vidModAnalytics_detailPg_sectionSuccess_header"),sub_title:this.t("vid_mod_analytics_appeal_success_detail_pg_desc"),icon_type:f.AT.STATUS_SUCCESS},appeal_video_removed_page_title:{title:this.t("vid_mod_analytics_appeal_detail_pg_title"),sub_title:this.t("vid_mod_analytics_appeal_detail_pg_desc"),icon_type:f.AT.STATUS_FAIL},index_page_title:{icon_type:f.AT.STATUS_RECEIVED,title:this.t("vidModAnalytics_appealSubmitted_sectionTitle_header"),sub_title:this.t("vid_mod_analytics_appeal_rcv_detail_pg_desc")},appeal_reviewing_page_title:{icon_type:f.AT.STATUS_RECEIVED,title:this.t("vidModAnalytics_appealSubmitted_sectionTitle_header"),sub_title:this.t("vid_mod_analytics_appeal_rcv_detail_pg_desc")}},video_status:t.penaltyDetails.videoInfo.Items[0].Status},e.contentDetailList=l}getPenaltyDetail(e){return e.pipe((0,k.p)((e=>this.service.getPenaltyDetail(e).pipe((0,S.T)((t=>{var n;return t&&0===t.status_code?this.getActions().setPenaltyDetailData({penaltyDetails:{penaltyDetails:t,videoInfo:e.videoInfo,vid:e.vid,uid:e.uid}}):(this.commonToastError(),this.slardarService.emitEvent("violation_detail_fetch_failed",{count:1},{status_code:(null===(n=t.status_code)||void 0===n?void 0:n.toString())||"",status_msg:t.status_msg||""}),this.getActions().setPenaltyDetailData({penaltyDetails:{penaltyDetails:{appeal_status:r.FAILED},videoInfo:e.videoInfo,vid:e.vid,uid:e.uid}}))})),(0,E.Z)(this.getActions().setViolationAppealStatus("loading")),(0,A.q)(this.getActions().setViolationAppealStatus("idle")),(0,b.n)({callback:this.commonToastError})))))}setAppealReasons(e,t){e.appealReasons=t}getAppealReasons(e){return e.pipe((0,k.p)((e=>this.service.getAppealReasons(e).pipe((0,S.T)((e=>{var t;return e&&0===e.status_code?this.getActions().setAppealReasons(e.appeal_reasons):(this.commonToastError(),this.slardarService.emitEvent("appeal_reasons_fetch_failed",{count:1},{status_code:(null===(t=e.status_code)||void 0===t?void 0:t.toString())||"",status_msg:e.status_msg||""}),this.noop())})),(0,E.Z)(this.getActions().setViolationAppealStatus("loading")),(0,A.q)(this.getActions().setViolationAppealStatus("idle")),(0,b.n)({callback:this.commonToastError})))))}getViolationDetail(e){return e.pipe((0,k.p)((e=>this.service.getViolationDetail(e).pipe((0,S.T)((e=>{var t;return e&&0===e.status_code&&e.detail?this.getActions().setViolationAppealData({detail:null==e?void 0:e.detail,surveyData:null==e?void 0:e.survey_data}):(this.commonToastError(),this.slardarService.emitEvent("violation_detail_fetch_failed",{count:1},{status_code:(null===(t=e.status_code)||void 0===t?void 0:t.toString())||"",status_msg:e.status_msg||""}),this.noop())})),(0,E.Z)(this.getActions().setViolationAppealStatus("loading")),(0,A.q)(this.getActions().setViolationAppealStatus("idle")),(0,b.n)({callback:this.commonToastError})))))}getReporterAppeal(e){return e.pipe((0,k.p)((({reportId:e,loggedOutCode:t})=>this.service.getReporterAppeal({report_id:e,verification_code:t}).pipe((0,S.T)((e=>{var t,n,i,o,a;if(e&&0===e.status_code&&e.detail){if(!e.report)return this.commonToastError(),this.slardarService.emitEvent("reporter_appeal_empty_report_info",{count:1},{status_code:(null===(t=e.status_code)||void 0===t?void 0:t.toString())||"",status_msg:e.status_msg||""}),this.noop();const a=((e,t)=>{var n;return{report_info:{common_data:e.common_data,live:e.live||null,non_live:e.non_live||null,live_comment:e.live_comment||null},post_info:"",reason:"",submit_status:null===(n=t.violation_info)||void 0===n?void 0:n.appeal_info.appeal_status}})(e.report,e.detail),r={detail:e.detail,reporterAppealInfo:a},s=(null!==(o=null===(i=null===(n=r.detail)||void 0===n?void 0:n.violation_info)||void 0===i?void 0:i.reason)&&void 0!==o?o:[]).map((e=>({title:e.reason_title,content:e.reason_content,url:e.inner_link_url,urlText:e.inner_link_text})));return this.getActions().setReporterAppealData({contentDetailList:s,detail:r.detail,reporterAppealInfo:r.reporterAppealInfo})}return this.commonToastError(),this.slardarService.emitEvent("reporter_appeal_status_not_ok",{count:1},{status_code:(null===(a=e.status_code)||void 0===a?void 0:a.toString())||"",status_msg:e.status_msg||""}),this.noop()})),(0,E.Z)(this.getActions().setViolationAppealStatus("loading")),(0,A.q)(this.getActions().setViolationAppealStatus("idle")),(0,b.n)({callback:this.commonToastError})))))}postReporterAppeal(e){return e.pipe((0,k.p)((e=>this.service.postReporterAppeal(e).pipe((0,S.T)((e=>{var t;return e&&0===e.status_code?this.getActions().setAppealStatus(f.nW.ON_APPEAL):(this.commonToastError(),this.slardarService.emitEvent("reporter_appeal_submit_fail",{count:1},{status_code:(null===(t=e.status_code)||void 0===t?void 0:t.toString())||"",status_msg:e.status_message||""}),this.noop())})),(0,E.Z)(this.getActions().setViolationAppealStatus("submitting")),(0,A.q)(this.getActions().setViolationAppealStatus("submitted")),(0,b.n)({callback:this.commonToastError})))))}postLiveReporterAppeal(e){return e.pipe((0,k.p)((e=>this.service.postLiveReporterAppeal(e).pipe((0,S.T)((e=>{var t;return e&&0===e.status_code?this.getActions().setAppealStatus(f.nW.ON_APPEAL):(this.commonToastError(),this.slardarService.emitEvent("live_reporter_appeal_submit_fail",{count:1},{status_code:(null===(t=e.status_code)||void 0===t?void 0:t.toString())||"",status_msg:e.status_message||""}),this.noop())})),(0,E.Z)(this.getActions().setViolationAppealStatus("submitting")),(0,A.q)(this.getActions().setViolationAppealStatus("submitted")),(0,b.n)({callback:this.commonToastError})))))}postViolationAppeal(e){return e.pipe((0,k.p)((e=>this.service.postAppealCommit(e).pipe((0,S.T)((e=>{var t;return e&&0===e.status_code?this.getActions().setAppealStatus(f.nW.ON_APPEAL):(this.commonToastError(),this.slardarService.emitEvent("violation_appeal_submit_fail",{count:1},{status_code:(null===(t=e.status_code)||void 0===t?void 0:t.toString())||"",status_msg:e.status_msg||""}),this.noop())})),(0,E.Z)(this.getActions().setViolationAppealStatus("submitting")),(0,A.q)(this.getActions().setViolationAppealStatus("submitted")),(0,b.n)({callback:this.commonToastError})))))}commonToastError(){F.F.destroy(),F.F.open({content:this.t(V.z$),duration:3,widthType:"half"})}};(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,String]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setLoggedOutCode",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,Object]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setCurrentAppealReason",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,String]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setPunishKey",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,String]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setViolationAppealStatus",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,Object]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setReporterAppealData",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,Object]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setViolationAppealData",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,Number]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setAppealStatus",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,Object]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setPenaltyDetailData",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"getPenaltyDetail",null),(0,v.__decorate)([(0,g.h5)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[Object,Array]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"setAppealReasons",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"getAppealReasons",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"getViolationDetail",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"getReporterAppeal",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"postReporterAppeal",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"postLiveReporterAppeal",null),(0,v.__decorate)([(0,g.Mj)(),(0,v.__metadata)("design:type",Function),(0,v.__metadata)("design:paramtypes",[O.c]),(0,v.__metadata)("design:returntype",void 0)],q.prototype,"postViolationAppeal",null),q=(0,v.__decorate)([(0,h.n)("ViolationAppeal"),(0,v.__param)(2,(0,_.y)(y.hp)),(0,v.__metadata)("design:paramtypes",[T,z.V$,Function])],q);var G=n(40099),$=n(62186),W=n(72153);const Z=(0,$.default)("div",{target:"esnvg680"})({height:"100%",width:"100%",display:"flex",flexDirection:"column",alignItems:"stretch",overflow:"hidden"},"label:Container;"),Y=(0,$.default)("div",{target:"esnvg681"})((({showTopBanner:e})=>[{display:"flex",flexDirection:"row",alignItems:"center",margin:"24px 24px 16px 24px"},e&&{marginBottom:"0"}]),"label:DivHeader;"),K=(0,$.default)("span",{target:"esnvg682"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"H4",color:"TextPrimary",fontWeight:"bold"}),{flexGrow:1}]),"label:SpanHeaderTitle;"),X=(0,$.default)("div",{target:"esnvg683"})((({theme:{direction:e,colors:t}})=>[Object.assign(Object.assign({width:"24px",height:"24px",cursor:"pointer"},"rtl"===e&&{transform:"rotate(180deg)"}),{"> svg > path":{fill:t.TextPrimary}})]),"label:DivBackButton;");var Q=n(93037),J=n(28261),ee=n(89162),te=n(86223),ne=n(54622),ie=n(41271),oe=n(84827),ae=n(25616);const re=(0,$.default)("div",{target:"edtqnxl0"})({padding:"32px",height:"100%"},"label:Container;"),se=(0,$.default)("div",{target:"edtqnxl1"})({display:"flex",flexDirection:"column",alignItems:"center",textAlign:"center"},"label:SectionAppealStatus;"),le=(0,$.default)("div",{target:"edtqnxl2"})((e=>[(0,W.zy)({theme:e.theme,color:e.$color}),{display:"flex",justifyContent:"center",alignItems:"center"}]),"label:DivIconWrapper;"),ce=(0,$.default)("div",{target:"edtqnxl3"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",color:"TextPrimary",fontWeight:"bold"}),{fontSize:"24px",lineHeight:"36px",marginTop:"27px",textAlign:"center"}]),"label:AppealTitle;"),de=(0,$.default)("div",{target:"edtqnxl4"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",color:"TextSecondary",fontWeight:"normal"}),{fontSize:"16px",lineHeight:"22px",marginTop:"16px",textAlign:"center"}]),"label:AppealSubtitle;"),ue=(0,$.default)("button",{target:"edtqnxl5"})((({theme:e})=>({marginTop:"24px",height:"48px",width:"100%",padding:"12px 24px",cursor:"pointer",background:e.colors.Primary,border:"none",borderRadius:"8px"})),"label:PrimaryButton;"),pe=(0,$.default)("div",{target:"edtqnxl6"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",color:"ConstTextInverse",fontWeight:"bold"}),{fontSize:"16px",lineHeight:"24px",textAlign:"center"}]),"label:PrimaryButtonText;"),ve=({handleClose:e})=>{const t=(0,ae.s)();return(0,u.jsxs)(re,{children:[(0,u.jsxs)(se,{children:[(0,u.jsx)(le,{$color:"LinePrimary2",children:(0,u.jsx)(te.Q,{size:72})}),(0,u.jsx)(ce,{children:t("dsa_illegal_appeal_expired_header")}),(0,u.jsx)(de,{children:t("dsa_illegal_appeal_expired_desc")})]}),(0,u.jsx)(ue,{onClick:e,children:(0,u.jsx)(pe,{children:t("dsa_illegal_appeal_button_ok")})})]})};var me=n(60094),ge=n(35626),he=n.n(ge);const _e={position:"absolute",bottom:0,left:0,height:0,overflow:"hidden","padding-top":0,"padding-bottom":0,border:"none"},fe=["box-sizing","width","font-size","font-weight","font-family","font-style","letter-spacing","text-indent","white-space","word-break","overflow-wrap","padding-left","padding-right"];function ye(e,t){var n;if("letters"!==t&&"words"!==t)throw new Error(`Unsupported options basedOn: ${t}`);if(e.nodeType===Node.TEXT_NODE){const t=document.createDocumentFragment();Array.from(e.textContent||"").forEach((e=>{t.appendChild(function(e){const t=document.createElement("span");return t.className="LinesEllipsis-unit",t.textContent=e,t}(e))})),null===(n=e.parentNode)||void 0===n||n.replaceChild(t,e)}else if(e.nodeType===Node.ELEMENT_NODE){const n=[].slice.call(e.childNodes),i=n.length;for(let e=0;enull,winWidth:void 0},Se=Object.keys(ke);class Ee extends G.Component{constructor(e){super(e),this.state={html:e.unsafeHTML,clamped:!1},this.canvas=null,this.maxLine=0,this.nlUnits=[]}componentDidMount(){this.initCanvas(),this.reflow(this.props)}componentDidUpdate(e){e.winWidth!==this.props.winWidth&&this.copyStyleToCanvas(),he()(this.props,e)||this.reflow(this.props)}componentWillUnmount(){this.canvas.parentNode.removeChild(this.canvas)}setState(e,t){return void 0!==e.clamped&&(this.clamped=e.clamped),super.setState(e,t)}initCanvas(){if(this.canvas)return;this.canvas=document.createElement("div");const{canvas:e}=this;e.className=`LinesEllipsis-canvas ${this.props.className}`,e.setAttribute("aria-hidden","true"),this.copyStyleToCanvas(),Object.keys(_e).forEach((t=>{e.style[t]=_e[t]})),document.body.appendChild(e)}copyStyleToCanvas(){const e=window.getComputedStyle(this.target);fe.forEach((t=>{this.canvas.style[t]=e[t]}))}reflow(e){this.maxLine=Number(e.maxLine)||1,this.canvas.innerHTML=e.unsafeHTML;const t=e.basedOn||(/^[\x00-\x7F]+$/.test(e.unsafeHTML)?"words":"letters");ye(this.canvas,t);const n={clamped:this.putEllipsis(this.calcIndexes()),html:this.canvas.innerHTML};this.setState(n,e.onReflow.bind(this,n))}calcIndexes(){const e=[0];this.nlUnits=Array.from(this.canvas.querySelectorAll(".LinesEllipsis-unit"));const{nlUnits:t}=this,n=t.length;if(!t.length)return e;const i=t.find(Te);if(!i)return e;let o=1,{offsetTop:a}=i;for(let i=1;i1&&(o++,e.push(i),a=t[i].offsetTop,o>this.maxLine));i++);return e}putEllipsis(e){if(e.length<=this.maxLine)return!1;this.nlUnits=this.nlUnits.slice(0,e[this.maxLine]);let t=this.nlUnits.pop();const n=this.makeEllipsisSpan();do{we(t,this.canvas),xe(t).appendChild(n),t=this.nlUnits.pop()}while(t&&(!Te(t)||n.offsetHeight>t.offsetHeight||n.offsetTop>t.offsetTop));return t&&be(t),this.nlUnits.forEach(be),!0}makeEllipsisSpan(){const{ellipsisHTML:e,ellipsis:t}=this.props,n=document.createElement("span"),i=document.createElement("span");return i.className="p1 font-semibold text-color-TextSecondary",i.setAttribute("style","cursor: pointer;"),e?i.innerHTML=e:i.textContent=t,n.appendChild(i),n}isClamped(){return this.clamped}render(){const{html:e,clamped:t}=this.state,n=this.props,{component:i,className:o,unsafeHTML:a}=n,r=(0,v.__rest)(n,["component","className","unsafeHTML"]);return(0,u.jsx)(i,Object.assign({className:`LinesEllipsis ${t?"LinesEllipsis--clamped":""} ${o}`,ref:e=>{this.target=e}},function(e,t){if(!e||"object"!=typeof e)return e;const n={};return Object.keys(e).forEach((i=>{t.indexOf(i)>-1||(n[i]=e[i])})),n}(r,Se),{children:(0,u.jsx)("div",{dangerouslySetInnerHTML:{__html:t?e:a}})}))}}Ee.defaultProps=ke;const Ae=Ee,Oe=(0,$.default)("div",{target:"e1q7dabl0"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:12}]),"label:SectionHeader;"),Pe=(0,$.default)("div",{target:"e1q7dabl1"})((({showDivider:e})=>[{display:"flex",alignItems:"flex-start",justifyContent:"space-between"},e&&{cursor:"pointer",paddingBottom:8}]),"label:ContentHeader;"),Ie=(0,$.default)("div",{target:"e1q7dabl2"})((({theme:e,isList:t})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{marginBottom:8},t&&{paddingInlineEnd:30}]),"label:ContentTitle;"),Ce=(0,$.default)("div",{target:"e1q7dabl3"})((({theme:e,showDivider:t,isList:n})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextTertiaryAlt",fontWeight:"normal"}),n&&Object.assign({paddingTop:16},t&&{paddingTop:0,marginBottom:12})]),"label:ContentDescription;"),Le=(0,$.default)("div",{target:"e1q7dabl4"})([{marginBottom:16}],"label:ContentDivider;"),je=(0,$.default)("div",{target:"e1q7dabl5"})((({theme:{direction:e,colors:t},isShow:n})=>[Object.assign(Object.assign({minWidth:"16px",width:"16px",height:"16px",transition:"transform .4s"},"rtl"===e&&{transform:"rotate(180deg)"}),{"> svg > path":{fill:t.TextTertiary}}),n&&{transform:"rotateZ(-90deg)"}]),"label:DivArrowContainer;");var Me=n(72241),Ne=n(88091),De=n(8475);const Re=({isShowByDefault:e,showSeeMore:t,showDivider:n,item:i,seeMoreText:o,onToggle:a})=>{const[r,s]=(0,G.useState)(e),[l,c]=(0,G.useState)(!0),d=(0,G.useCallback)((()=>{0!==i.contentList.length&&s((e=>(a&&a(!e),!e)))}),[a,i]),p=(0,u.jsx)("section",{children:(0,u.jsx)("article",{children:i.contentList.map(((e,t)=>"break"===e.type?(0,u.jsx)("br",{},t):"text"===e.type?(0,u.jsx)("p",{children:e.text},t):"list"===e.type?(0,u.jsx)("ul",{children:(e.list||[]).map(((e,n)=>(0,u.jsx)("li",{className:0===t?"mb-8":"my-8",children:e},n)))},t):null))})}),{value:v}=(0,G.useContext)(Me.xm),m=(0,u.jsx)("span",{style:Object.assign({color:"rgba(0, 0, 0, 0.72)",fontWeight:500},v&&{color:"rgba(255, 255, 255, 0.75)"}),children:`... ${o}`});return(0,u.jsx)(u.Fragment,{children:t?(0,u.jsxs)("article",{children:[(0,u.jsx)(Ie,{children:i.title}),l?(0,u.jsx)(Ce,{children:(0,u.jsx)(Ae,{"data-cy":"see-more-btn",onClick:()=>c(!1),unsafeHTML:me.renderToString(p),maxLine:"4",basedOn:"letters",ellipsisHTML:me.renderToString(m),style:{overflowWrap:"break-word",wordBreak:"break-word",wordWrap:"break-word"}})}):(0,u.jsx)(Ce,{children:p})]}):(0,u.jsxs)("article",{children:[(0,u.jsxs)(Pe,{showDivider:n,onClick:d,children:[(0,u.jsx)(Ie,{isList:!0,children:i.title}),i.contentList.length>0&&(0,u.jsx)(je,{isShow:r,children:(0,u.jsx)(De.A,{width:16,height:16})})]}),r&&(0,u.jsx)(Ce,{isList:!0,showDivider:n,children:p}),n&&(0,u.jsx)(Le,{children:(0,u.jsx)(Ne.zm,{size:"medium",color:"LineSecondary"})})]})})},Be=/
  • ([\s\S]*?)<\/li>/g,Ue=()=>{},Fe=({title:e,list:t,isShowByDefault:n=!1,seeMoreText:i="",handleOpenLink:o=Ue,onToggle:a})=>{const r=(0,G.useMemo)((()=>t.map((e=>{var t;const n=Object.assign(Object.assign({},e),{contentList:[]});if(e.content_v2&&e.content_v2.length>1&&""!==e.content_v2[0])return e.content_v2.forEach(((t,i)=>{n.contentList.push({text:t,type:"text"}),e.content_v2&&i!==e.content_v2.length-1&&n.contentList.push({text:"",type:"break"})})),n;if(!e.content)return n;let i=0,o=Be.exec(e.content);for(;null!==o;){o.index!==i&&n.contentList.push({text:e.content.slice(i,o.index),type:"text"});const{length:a}=n.contentList,r=o.length>1?o[1]:"";a&&"list"===n.contentList[a-1].type?null===(t=n.contentList[a-1].list)||void 0===t||t.push(r):n.contentList.push({list:[r],type:"list"}),i=o.index+o[0].length,o=Be.exec(e.content)}return i<=e.content.length&&n.contentList.push({text:e.content.slice(i),type:"text"}),n}))),[t]);return(0,u.jsxs)("div",{children:[(0,u.jsx)(Oe,{children:e}),r.map(((e,t)=>(0,u.jsx)(Re,{item:e,isShowByDefault:n,seeMoreText:i,showSeeMore:1===r.length,showDivider:1!==r.length&&t!==r.length-1,onToggle:e=>null==a?void 0:a(t,e),onOpenLink:o},t)))]})};var Ve=n(50708),ze=n.n(Ve);const He=(0,$.default)("div",{target:"e1updv710"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:12}]),"label:SectionHeader;"),qe=(0,$.default)("div",{target:"e1updv711"})((({theme:e,hasBorder:t})=>[{fontSize:0,height:40,width:40,borderRadius:24,display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:e.colors.BGTertiary,color:e.colors.TextPrimary},t&&{border:`1px solid ${e.colors.LineSecondary2}`}]),"label:DivIconWrapper;"),Ge=(0,$.default)("div",{target:"e1updv712"})((({isHelpAndSupport:e})=>[{display:"flex",flexDirection:"row"},e?{alignItems:"center"}:{alignItems:"start"}]),"label:SectionContentContainer;"),$e=(0,$.default)("div",{target:"e1updv713"})((({theme:{direction:e},hasHeartIcon:t})=>[Object.assign({display:"flex",flexDirection:"column",alignItems:"start",flexGrow:1},"rtl"===e&&{marginLeft:0}),t&&{paddingInlineStart:12}]),"label:SectionContent;"),We=(0,$.default)("div",{target:"e1updv714"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextSecondary",fontWeight:"normal"}),{wordBreak:"break-word"}]),"label:SectionContentMain;"),Ze=(0,$.default)("div",{target:"e1updv715"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{display:"inline"}]),"label:TitleText;"),Ye=(0,$.default)("div",{target:"e1updv716"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"}),{display:"inline",cursor:"pointer"}]),"label:InnerLinkText;"),Ke=(0,$.default)("div",{target:"e1updv717"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextTertiaryAlt",fontWeight:"normal"}),{marginTop:4}]),"label:SectionContentFooter;"),Xe=(0,$.default)("div",{target:"e1updv718"})((({theme:{direction:e},imageUrl:t,isProfileIcon:n})=>[Object.assign({width:68,height:87,borderRadius:4,overflow:"hidden",backgroundSize:"cover",backgroundPosition:"center",backgroundRepeat:"no-repeat",position:"relative",marginTop:-33,marginLeft:12,backgroundImage:`url(${t})`},"rtl"===e&&{marginLeft:0,marginRight:12}),n&&{height:44,width:44,borderRadius:40}]),"label:VideoPoster;"),Qe=(0,$.default)("div",{target:"e1updv719"})({position:"absolute",top:0,left:0,width:"100%",height:"100%",backgroundColor:"rgba(0, 0, 0, 0.5)",backgroundImage:"url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMjAiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHJlY3Qgd2lkdGg9IjEuNTAwNTYiIGhlaWdodD0iMTcuNzY4NCIgcng9IjAuNSIgdHJhbnNmb3JtPSJtYXRyaXgoMC42OTkxODYgLTAuNzE0OTQgLTAuNzE0OTQgLTAuNjk5MTg2IDE1LjIwMzMgMTYuMjUpIiBmaWxsPSJ3aGl0ZSIvPgo8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTEwLjA3MDcgMTQuNTU1OUMxMS4xODA2IDE0LjU1NTkgMTIuMjM0MyAxNC4zODcyIDEzLjE4MjMgMTQuMDg0NEwxMi4wMDIxIDEyLjkzMDJDMTEuOTgwMyAxMi45MDg5IDExLjk2MDggMTIuODg2IDExLjk0MzggMTIuODYyQzExLjM1OTMgMTIuOTg2NCAxMC43MzA4IDEzLjA1NTQgMTAuMDcwNyAxMy4wNTU0QzguMjY4OTUgMTMuMDU1NCA2LjcwMjE5IDEyLjU0MTggNS42MjU5NCAxMS43ODg0QzQuNTQ0OTUgMTEuMDMxNyA0LjA2ODQ5IDEwLjEzMDMgNC4wNjg0OSA5LjMwNDAzQzQuMDY4NDkgOC40Nzc4IDQuNTQ0OTUgNy41NzYzNiA1LjYyNTk0IDYuODE5NjdDNS42NTA3MSA2LjgwMjMzIDUuNjc1NzQgNi43ODUxMiA1LjcwMTAzIDYuNzY4MDRMNC42MTA4MSA1LjcwMTg1QzMuMzQ0MjUgNi42NDIxNyAyLjU2Nzk1IDcuOTA5NjQgMi41Njc5NSA5LjMwNDAzQzIuNTY3OTUgMTIuMjA0NiA1LjkyNzAyIDE0LjU1NTkgMTAuMDcwNyAxNC41NTU5Wk02Ljk3NzExIDQuNTE3OTRDNy45MjAzMyA0LjIxODczIDguOTY3NyA0LjA1MjE0IDEwLjA3MDcgNC4wNTIxNEMxNC4yMTQzIDQuMDUyMTQgMTcuNTczNCA2LjQwMzQ5IDE3LjU3MzQgOS4zMDQwM0MxNy41NzM0IDEwLjY5MzQgMTYuODAyNiAxMS45NTY4IDE1LjU0NDEgMTIuODk2MUwxNC40NTQ0IDExLjgzMDRDMTQuNDc0OSAxMS44MTY1IDE0LjQ5NTIgMTEuODAyNSAxNC41MTU0IDExLjc4ODRDMTUuNTk2NCAxMS4wMzE3IDE2LjA3MjggMTAuMTMwMyAxNi4wNzI4IDkuMzA0MDNDMTYuMDcyOCA4LjQ3NzggMTUuNTk2NCA3LjU3NjM2IDE0LjUxNTQgNi44MTk2N0MxMy40MzkxIDYuMDY2MyAxMS44NzI0IDUuNTUyNjggMTAuMDcwNyA1LjU1MjY4QzkuNDIxNDkgNS41NTI2OCA4LjgwMjgyIDUuNjE5MzYgOC4yMjY2MSA1LjczOTlMNi45NzcxMSA0LjUxNzk0WiIgZmlsbD0id2hpdGUiLz4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xMC44NTY5IDExLjgxMDJDMTAuNjA4NyAxMS44ODggMTAuMzQ0NiAxMS45MyAxMC4wNzA3IDExLjkzQzguNjIwMzkgMTEuOTMgNy40NDQ3MiAxMC43NTQzIDcuNDQ0NzIgOS4zMDQwM0M3LjQ0NDcyIDkuMDUwNjUgNy40ODA2IDguODA1NjUgNy41NDc1NyA4LjU3Mzg0TDEwLjg1NjkgMTEuODEwMlpNOS4zMDI2NSA2Ljc5MjE4QzkuNTQ1NTcgNi43MTc5OSA5LjgwMzQ2IDYuNjc4MDggMTAuMDcwNyA2LjY3ODA4QzExLjUyMDkgNi42NzgwOCAxMi42OTY2IDcuODUzNzYgMTIuNjk2NiA5LjMwNDAzQzEyLjY5NjYgOS41NTA3NCAxMi42NjI2IDkuNzg5NSAxMi41OTkgMTAuMDE1OUw5LjMwMjY1IDYuNzkyMThaIiBmaWxsPSJ3aGl0ZSIvPgo8L3N2Zz4K')",backgroundSize:"20px 20px",backgroundPosition:"center",backgroundRepeat:"no-repeat"},"label:MaskIcon;");var Je=n(84987);const et={id:"heart-4636b1b5",use:"heart-4636b1b5-usage",viewBox:"0 0 40 40",content:''};function tt(e){const t=(0,G.useContext)(Je.X);return(0,G.useLayoutEffect)((()=>(t.add(et),()=>{t.remove("heart-4636b1b5")})),[]),(0,u.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,u.jsx)("use",{xlinkHref:"#heart-4636b1b5"},void 0)}),void 0)}const nt={id:"photo-4dee05ae",use:"photo-4dee05ae-usage",viewBox:"0 0 48 48",content:''};function it(e){const t=(0,G.useContext)(Je.X);return(0,G.useLayoutEffect)((()=>(t.add(nt),()=>{t.remove("photo-4dee05ae")})),[]),(0,u.jsx)("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor"},e,{children:(0,u.jsx)("use",{xlinkHref:"#photo-4dee05ae"},void 0)}),void 0)}var ot=n(62541),at=n(32567),rt=n(54977),st=n(87992),lt=n(81678),ct=n(86406),dt=n(63581),ut=n(93608);const pt=e=>{var t;const{contentInfo:n,handlePressLink:i,title:o}=e;if(null==n?void 0:n.content_id){const e={item_id:n.content_id,result_type:n.result_type,reason_code:n.reason_code};ut.f.event("web_appeal_result_show",e)}const a=(e,t,n)=>{var i,o;if(n){let e=null!==(i=n.text)&&void 0!==i?i:"";for(const t of null!==(o=n.elements)&&void 0!==o?o:[])e=e.replace(t.placeholder,``);return t?`"${e}"`:e}return t?`"${e}"`:e},r=e=>{let t,n=!0;switch(e){case f.AT.VIDEO:t=(0,u.jsx)(ot.q,{size:20});break;case f.AT.COMMENT:t=(0,u.jsx)(at.S,{size:20});break;case f.AT.AUDIO:t=(0,u.jsx)(rt.G,{size:20});break;case f.AT.LINK:t=(0,u.jsx)(st.j,{size:20});break;case f.AT.HASHTAG:t=(0,u.jsx)(lt.g,{size:20});break;case f.AT.IMAGE:t=(0,u.jsx)(ct.P,{size:20});break;case f.AT.USER:t=(0,u.jsx)(dt.Y,{size:20});break;case f.AT.PHOTO:t=(0,u.jsx)(it,{width:20,height:20});break;case f.AT.HEART:t=(0,u.jsx)(tt,{width:40,height:40}),n=!1;break;default:t=(0,u.jsx)(dt.Y,{size:20})}return(0,u.jsx)(qe,{hasBorder:n,children:t})},s=n?[n]:[];return(0,u.jsxs)("div",{children:[(0,u.jsx)(He,{children:null!==(t=null==n?void 0:n.header)&&void 0!==t?t:o}),null==s?void 0:s.map(((e,t)=>{const{title:n,content:o,has_quote:s,inner_link_text:l,inner_link_url:c,image_url:d,image_has_mask:p,icon_type:v,rich_text:m}=e;return(0,u.jsxs)(Ge,{isHelpAndSupport:v===f.AT.HEART,children:[v===f.AT.HEART&&r(v),(0,u.jsxs)($e,{hasHeartIcon:v===f.AT.HEART,children:[(0,u.jsxs)(We,{children:[n&&(0,u.jsx)(Ze,{dangerouslySetInnerHTML:{__html:ze().sanitize(a(n,s,m))}}),l&&(0,u.jsxs)(Ye,{onClick:()=>i&&i(c),children:[" ",l]})]}),(0,u.jsx)(Ke,{children:o})]}),d&&(0,u.jsx)(Xe,{imageUrl:d,isProfileIcon:v===f.AT.PROFILE,children:p&&(0,u.jsx)(Qe,{})})]},t)}))]})},vt=(0,$.default)("div",{target:"ewrmc1w0"})({paddingLeft:24,paddingRight:24,height:"100%",flexGrow:1},"label:Container;"),mt=(0,$.default)("div",{target:"ewrmc1w1"})((({theme:e})=>({padding:16,backgroundColor:e.colors.BGPrimary,borderRadius:8,marginBottom:8})),"label:ComponentWrapper;"),gt=(0,$.default)("div",{target:"ewrmc1w2"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"})]),"label:FooterText;"),ht=(0,$.default)("div",{target:"ewrmc1w4"})((({showAppealButton:e})=>[{position:"relative",bottom:"0",left:"0",width:"100%",height:54,marginBottom:12,padding:8,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},e&&{alignItems:"start",paddingLeft:24}]),"label:DivFooter;"),_t=(0,$.default)("div",{target:"ewrmc1w5"})({display:"flex",flexDirection:"column",height:"580px",overflowY:"auto"},"label:ContainerWrapper;"),ft=(0,$.default)("div",{target:"ewrmc1w6"})({display:"flex",flexDirection:"column",alignItems:"center",textAlign:"center",marginBottom:32},"label:SectionAppealStatus;"),yt=(0,$.default)("div",{target:"ewrmc1w7"})((e=>[(0,W.zy)({theme:e.theme,color:e.$color}),{display:"flex",justifyContent:"center",alignItems:"center"}]),"label:DivIconWrapper;"),bt=(0,$.default)("div",{target:"ewrmc1w8"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"H4",color:"TextPrimary",fontWeight:"bold"}),{marginTop:18,textAlign:"center"}]),"label:AppealTitle;"),wt=(0,$.default)("div",{target:"ewrmc1w9"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{marginTop:12,textAlign:"center"}]),"label:AppealSubtitle;"),xt=(0,$.default)("div",{target:"ewrmc1w10"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),Tt=(0,$.default)("div",{target:"ewrmc1w11"})({flexGrow:1},"label:FlexGrowDiv;"),kt=(0,$.default)("button",{target:"ewrmc1w12"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"ConstTextInverse",fontWeight:"semiBold"}),{height:"36px",padding:"7px 16px",position:"absolute",cursor:"pointer",right:"24px",color:e.colors.ConstTextInverse,background:e.colors.Primary,border:"none",borderRadius:"4px",":disabled":{background:e.colors.BGPlaceholderDefault,color:e.colors.TextQuaternary}}]),"label:ButtonSubmit;"),St=(0,$.default)("div",{target:"e1ouhrz80"})((({hideMargin:e=!1})=>Object.assign({},!e&&{marginTop:12})),"label:HyperlinkTextContainer;"),Et=(0,$.default)("div",{target:"e1ouhrz81"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{display:"inline"}]),"label:MainTextContent;"),At=(0,$.default)("div",{target:"e1ouhrz82"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"}),{display:"inline",cursor:"pointer"}]),"label:LinkTextContent;"),Ot=e=>{const{hideMargin:t=!1,btnText:n,onClick:i}=e;if(!n)return null;const{text:o,links:a=[]}=n,r=function(e,t){let n=0;const i=[],o=[];try{t.forEach((t=>{e.indexOf(t.placeholder)>=0&&o.push({idx:e.indexOf(t.placeholder),length:t.placeholder.length,link_obj:t})})),o.sort(((e,t)=>e.idx-t.idx));let a=0;for(;n"string"===e.type&&e.text?(0,u.jsx)(Et,{children:e.text},`text_${t}`):"url"===e.type&&e.text&&e.url?(0,u.jsx)(At,{onClick:()=>i(e.url),children:e.text},`url_${t}`):null))})},Pt=(0,$.default)("div",{target:"e1uyuwid0"})((({theme:e})=>[{padding:"12px 16px",marginBottom:20,marginTop:44,backgroundColor:e.colors.BGPlaceholderDefault,display:"flex",flexDirection:"row"}]),"label:BannerContainer;"),It=(0,$.default)("div",{target:"e1uyuwid1"})((({isMobile:e})=>[{marginRight:4},!e&&{display:"flex",alignItems:"center"}]),"label:BannerIcon;"),Ct=(0,$.default)("div",{target:"e1uyuwid2"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"}),{display:"flex",alignItems:"center"}]),"label:BannerText;"),Lt=({icon:e,text:t,isMobile:n=!1})=>(0,u.jsxs)(Pt,{children:[(0,u.jsx)(It,{isMobile:n,children:e}),(0,u.jsx)(Ct,{children:t})]}),jt=(0,$.default)("div",{target:"e1yaooat0"})({display:"flex",flexDirection:"column",marginBottom:20,"&:last-of-type":{marginBottom:0}},"label:TextWrapper;"),Mt=(0,$.default)("div",{target:"e1yaooat1"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:6}]),"label:Title;"),Nt=(0,$.default)("div",{target:"e1yaooat2"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{wordBreak:"break-word"}]),"label:Description;"),Dt=({successTitle:e,failureTitle:t,successDesc:n,failureDesc:i})=>{const o=[{title:t,description:i},{title:e,description:n}];return(0,u.jsx)("div",{children:o.map((({title:e,description:t},n)=>(0,u.jsxs)(jt,{children:[(0,u.jsx)(Mt,{children:e}),(0,u.jsx)(Nt,{children:t})]},n)))})},Rt=({handleClose:e,handleAppealClick:t=()=>{}})=>{var n,i,o,a;const r=(0,ae.s)(),{status:s,detail:l,contentDetailList:c,reporterAppealInfo:d}=(0,ie.P)(q),p=(e=>{var t,n,i,o;const a=e.base_info,r=null===(n=null===(t=e.violation_info)||void 0===t?void 0:t.appeal_info)||void 0===n?void 0:n.appeal_status,s=null===(o=null===(i=e.violation_info)||void 0===i?void 0:i.appeal_info)||void 0===o?void 0:o.audio_change_status,l=e.video_status;return r===f.nW.APPEAL_SUCCESS||s===f.Ls.CHANGED?null==a?void 0:a.appeal_success_page_title:r===f.nW.ON_APPEAL?null==a?void 0:a.appeal_reviewing_page_title:r===f.nW.APPEAL_FAIL&&141===l?null==a?void 0:a.appeal_video_removed_page_title:r===f.nW.APPEAL_FAIL?null==a?void 0:a.appeal_fail_page_title:null==a?void 0:a.index_page_title})(l),m=null==l?void 0:l.object_type,g=null===(n=l.violation_info)||void 0===n?void 0:n.violation_info_status,h=null!==d,_=null===(o=null===(i=null==l?void 0:l.violation_info)||void 0===i?void 0:i.appeal_info)||void 0===o?void 0:o.appeal_status,y=_!==f.nW.APPEAL_SUCCESS||h,b=(null===(a=null==l?void 0:l.violation_info)||void 0===a?void 0:a.header)||"",w=_===f.nW.APPEAL_EXPIRED,x=w&&!h,T=w&&h,k=T||_===f.nW.NOT_APPEAL,S=(null==p?void 0:p.sub_title_v2)&&f.d7.includes(m.toString()),E=m===f.w$.CONTENT_CHECK_VIDEO,A=g===f.ww.VIOLATION_INFO_IN_PROGRESS,O=E&&A,P=l.content_info_list,I=(0,G.useRef)({}),C=(0,G.useCallback)(((e,t)=>{const n=`category_${e+1}`;"no"===I.current[n]&&t&&(I.current[n]="yes")}),[]),L=(0,G.useMemo)((()=>{switch(null==p?void 0:p.icon_type){case f.AT.STATUS_RECEIVED:return(0,u.jsx)(yt,{$color:"LinePrimary2",children:(0,u.jsx)(Q.i,{size:48})});case f.AT.STATUS_SUCCESS:return(0,u.jsx)(yt,{children:(0,u.jsx)(J.i,{size:48})});case f.AT.STATUS_FAIL:return(0,u.jsx)(yt,{children:(0,u.jsx)(ee.b,{size:48})});case f.AT.STATUS_FAIL_LIGHT:return(0,u.jsx)(yt,{$color:"LinePrimary2",children:(0,u.jsx)(te.Q,{size:48})});default:return(0,u.jsx)(yt,{children:(0,u.jsx)(ee.b,{size:48})})}}),[null==p?void 0:p.icon_type]),j=(0,G.useCallback)((e=>(0,v.__awaiter)(void 0,void 0,void 0,(function*(){e&&window.open(e,"_blank")}))),[s,l,c]);if("loading"===s)return(0,u.jsx)(oe.R,{center:!0,size:"small"});if(T)return(0,u.jsx)(ve,{handleClose:e});const M=(0,u.jsx)(yt,{$color:"TextQuaternary",children:(0,u.jsx)(te.Q,{size:18})}),N={text:r("dsaCGWebapp_detailPg_sectionCG_body"),links:[{link_text:r("dsaCGWebapp_detailPg_sectionCG_link"),placeholder:"%s",url:"https://www.tiktok.com/community-guidelines"}]};return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)(Y,{showTopBanner:x,children:[(0,u.jsx)(Tt,{}),(0,u.jsx)(xt,{onClick:e,children:(0,u.jsx)(ne.A,{width:14,height:14})})]}),x&&(0,u.jsx)(Lt,{icon:M,text:r("dsaCGWebapp_appealExpired_emptyState_body")}),(0,u.jsx)(_t,{children:(0,u.jsxs)(vt,{children:[(0,u.jsxs)(ft,{children:[L,(null==p?void 0:p.title)&&(0,u.jsx)(bt,{children:p.title}),S?(0,u.jsx)(Ot,{btnText:null==p?void 0:p.sub_title_v2,onClick:j}):(null==p?void 0:p.sub_title)&&(0,u.jsx)(wt,{children:null==p?void 0:p.sub_title})]}),(P||[]).map(((e,t)=>(0,u.jsxs)(mt,{children:[console.log("ContentInfoSection: ",e),(0,u.jsx)(pt,{contentInfo:e,handlePressLink:j})]},t))),O&&(0,u.jsx)(mt,{children:(0,u.jsx)(Dt,{successTitle:r("contentCheck_progressScreen_page_bullet2Header"),successDesc:r("contentCheck_progressScreen_page_bullet2Body"),failureTitle:r("contentCheck_progressScreen_page_bullet1Header"),failureDesc:r("contentCheck_progressScreen_page_bullet1Body_postPrivate")})}),y&&(null==c?void 0:c.length)>0&&(0,u.jsx)(mt,{children:(0,u.jsx)(Fe,{title:b,list:c,onToggle:C,handleOpenLink:j,seeMoreText:r("search_see_more")})})]})}),(0,u.jsxs)(ht,{showAppealButton:k,children:[(0,u.jsx)(gt,{children:(0,u.jsx)(Ot,{hideMargin:!0,btnText:N,onClick:j})}),k&&(0,u.jsx)(kt,{onClick:t,children:r("appeal_btn_new")})]})]})},Bt=(0,$.default)("div",{target:"e3yfed30"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"}),{marginTop:24}]),"label:SubtitleDiv;"),Ut=(0,$.default)("div",{target:"e3yfed31"})((({theme:e})=>({borderTop:`1px solid ${e.colors.LineSecondary}`,paddingLeft:24,paddingRight:24})),"label:Container;"),Ft=(0,$.default)("div",{target:"e3yfed32"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"}),{marginTop:32}]),"label:SectionHeaderDiv;"),Vt=(0,$.default)("div",{target:"e3yfed33"})({width:72,height:72,borderRadius:6,overflow:"hidden",backgroundSize:"cover",backgroundPosition:"center center",backgroundRepeat:"no-repeat"},"label:ImageDiv;"),zt=(0,$.default)("div",{target:"e3yfed34"})({display:"flex",flexDirection:"row",marginTop:16,alignItems:"center"},"label:ContentInfoRow;"),Ht=(0,$.default)("div",{target:"e3yfed35"})({display:"flex",flexDirection:"column",marginInlineStart:16},"label:ContentInfoDetails;"),qt=(0,$.default)("div",{target:"e3yfed36"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"})]),"label:ContentInfoDetailsTitle;"),Gt=(0,$.default)("div",{target:"e3yfed37"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextTertiaryAlt",fontWeight:"normal"})]),"label:ContentInfoDetailsContent;"),$t=(0,$.default)("div",{target:"e3yfed38"})({marginTop:32},"label:MarginTop32DivWrapper;"),Wt=(0,$.default)("div",{target:"e3yfed39"})({marginTop:16},"label:MarginTop16DivWrapper;"),Zt=(0,$.default)("span",{target:"e3yfed310"})((({theme:e})=>[(0,W.zy)({theme:e,color:"Primary"})]),"label:PrimarySpanText;"),Yt=(0,$.default)("textarea",{target:"e3yfed311"})((({theme:e})=>Object.assign(Object.assign({},(e=>({borderStyle:"none",borderColor:"transparent",boxShadow:"none",outline:"none",marginTop:"10px",fontSize:"16px",fontFamily:e.fontFamilies.TikTokFont,fontWeight:e.fontWeights.normal,color:e.colors.TextPrimary,":placeholder":{color:e.colors.TextQuaternary}}))(e)),{resize:"none",height:"48px",width:"100%",backgroundColor:e.colors.BGPrimary})),"label:TextareaDescription;"),Kt=(0,$.default)("div",{target:"e3yfed312"})((({theme:e})=>({paddingBottom:"12.5px",borderBottom:`0.5px solid ${e.colors.LineInput}`})),"label:TextareaWrapper;"),Xt=(0,$.default)("div",{target:"e3yfed313"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"})]),"label:TextAreaHeader;"),Qt=(0,$.default)("div",{target:"e3yfed314"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextSecondary",fontWeight:"normal"})]),"label:TextAreaWordCount;"),Jt=(0,$.default)("div",{target:"e3yfed315"})({display:"flex",flexDirection:"row"},"label:FlexRowDiv;"),en=(0,$.default)("div",{target:"e3yfed316"})({flexGrow:1},"label:FlexGrowDiv;"),tn=(0,$.default)("div",{target:"e3yfed317"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P4",color:"TextSecondary",fontWeight:"normal"}),{marginTop:32,marginBottom:17}]),"label:FooterText;"),nn=(0,$.default)("span",{target:"e3yfed318"})((({theme:e})=>[(0,W.zy)({theme:e,color:"TextPrimary",fontWeight:"semiBold"})]),"label:LinkSpan;"),on=(0,$.default)("div",{target:"e3yfed319"})((({theme:e})=>({position:"relative",bottom:"0",left:"0",height:"84px",width:"100%",borderTop:`0.5px solid ${e.colors.LinePrimary2}`,backgroundColor:e.colors.BGPrimary})),"label:DivFooter;"),an=(0,$.default)("div",{target:"e3yfed320"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),rn=(0,$.default)("div",{target:"e1trkmzg0"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextPrimary",fontWeight:"semiBold"})]),"label:TitleDiv;"),sn=(0,$.default)("div",{target:"e1trkmzg1"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"TextPrimary",fontWeight:"normal"}),{marginTop:16}]),"label:ContentDiv;"),ln=({title:e,list:t})=>(0,u.jsxs)("div",{children:[(0,u.jsx)(rn,{children:e}),t.map((({title:e},t)=>(0,u.jsx)(sn,{children:e},t)))]});var cn=n(31367),dn=n(75972);const un=({handleBack:e,handleBackKeyDown:t,handleClose:n})=>{var i,o,a;const r=(0,ae.s)(),s=(0,p.w)(q),{status:l,detail:c,contentDetailList:d,reporterAppealInfo:v,loggedOutCode:m}=(0,ie.P)(q),g=(null===(i=c.violation_info)||void 0===i?void 0:i.header)||"",h=JSON.parse(JSON.stringify(c.reporter_appeal_reason||[])).sort(((e,t)=>e.desc>t.desc?1:-1)),[_,y]=(0,G.useState)(""),[b,w]=(0,G.useState)(""),x=(0,G.useCallback)((e=>{y(e.target.value)}),[]),T=(0,G.useCallback)((e=>{w(b===e?"":e)}),[b,w]),k=(0,G.useCallback)((e=>{e.stopPropagation()}),[]),S=c.content_info_list,E=(e=>{const t=e.base_info,n=e.object_type;return n===f.w$.NETZDG_REPORTER||n===f.w$.COMMENT_NETZDG_REPORTER?null==t?void 0:t.appeal_submit_page_title:null==t?void 0:t.index_page_title})(c),A=(e,t=!1,n)=>{var i,o;if(e){let n=null!==(i=e.text)&&void 0!==i?i:"";for(const t of null!==(o=e.elements)&&void 0!==o?o:[])n=n.replace(t.placeholder,``);return t?`"${n}"`:n}return t?`"${n}"`:n},O=(0,G.useCallback)((e=>{var t,n,i;if(e.preventDefault(),e.stopPropagation(),"idle"===l&&null!==v){const e=v.report_info.common_data,o=Object.assign(Object.assign({reportType:e.report_type,objectId:e.object_id,objectOwnerId:e.object_owner_id,reason:e.reason,uri:e.uri,reportId:e.report_id,reportDesc:_,reporterAppealReason:b,reporterSignature:e.reporter_signature},m&&{loggedOutCode:m}),{legalJurisdiction:e.legal_jurisdiction,relevantLaw:e.relevant_law,logoutReporterEmail:e.logout_reporter_email,trustedFlaggerEmail:e.trusted_flagger_email,relatedTtid:e.related_ttid,reportMenuClickTime:e.report_menu_click_time}),a=null===(i=null===(n=null===(t=v.report_info)||void 0===t?void 0:t.common_data)||void 0===n?void 0:n.object_type)||void 0===i?void 0:i.toString();if(f.gq.includes(a)){const e=Object.assign(Object.assign({},o),((e,t)=>{const n=t.report_info.live,i=t.report_info.live_comment;return e===f.w$.LIVE_REPORTER?{liveReportType:(null==n?void 0:n.live_request_type)||"",liveRequestPage:(null==n?void 0:n.live_request_page)||"",liveCmpIds:(null==n?void 0:n.live_cmp_ids)||"",liveEnterFromMerge:(null==n?void 0:n.live_enter_from_merge)||"",liveEnterMethod:(null==n?void 0:n.live_enter_method)||"",liveActionType:(null==n?void 0:n.live_action_type)||"",durationEntranceSubmit:(null==n?void 0:n.duration_entrance_submit)||0,targetAnchorId:(null==n?void 0:n.target_anchor_id)||"",targetAudienceId:(null==n?void 0:n.target_audience_id)||"",reportedUserIds:(null==n?void 0:n.reported_user_ids)||"",nonReportedUserIds:(null==n?void 0:n.non_reported_user_ids)||""}:e===f.w$.LIVE_COMMENT_REPORTER?{liveReportType:(null==i?void 0:i.live_report_type)||"",roomId:(null==i?void 0:i.room_id)||"",liveChatType:(null==i?void 0:i.live_chat_type)||"",content:(null==i?void 0:i.content)||"",durationEntranceSubmit:(null==i?void 0:i.duration_entrance_submit)||0}:{}})(a,v));return void s.postLiveReporterAppeal(e)}const r=v.report_info.non_live,l=Object.assign(Object.assign({},o),{relatedUsername:null==r?void 0:r.related_username,commentWithEmoji:null==r?void 0:r.comment_with_emoji});s.postReporterAppeal(l)}}),[_,s,v,l,b]);return"loading"===l?(0,u.jsx)(oe.R,{center:!0,size:"small"}):"submitted"===l?(0,u.jsx)(Rt,{handleBack:e,handleBackKeyDown:t,handleClose:n}):(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)(Y,{children:[(0,u.jsx)(X,{onClick:e,onKeyDown:t,tabIndex:0,role:"button",children:(0,u.jsx)(dn.A,{width:24,height:24})}),(0,u.jsx)(K,{children:null==E?void 0:E.title}),(0,u.jsx)(an,{onClick:n,children:(0,u.jsx)(ne.A,{width:14,height:14})})]}),(0,u.jsxs)(Ut,{children:[(0,u.jsx)(Bt,{children:null==E?void 0:E.sub_title}),S&&S.length>0&&S.map(((e,t)=>(0,u.jsxs)("div",{children:[(0,u.jsx)(Ft,{children:e.header}),(0,u.jsxs)(zt,{children:[e.image_url&&(0,u.jsx)(Vt,{style:{backgroundImage:`url(${e.image_url})`}}),(0,u.jsxs)(Ht,{children:[(0,u.jsx)(qt,{dangerouslySetInnerHTML:{__html:ze().sanitize(A(e.rich_text,e.has_quote,e.title))}}),(0,u.jsx)(Gt,{children:e.content||""})]})]})]},t))),(0,u.jsx)($t,{children:(0,u.jsx)(ln,{title:g,list:d})}),(0,u.jsxs)($t,{children:[(0,u.jsxs)(Ft,{children:[r("dsa_illegal_appeal_dropdown_title"),(0,u.jsx)(Zt,{children:"*"})]}),h.map(((e,t)=>(0,u.jsx)(Wt,{onClick:()=>{T(e.code)},children:(0,u.jsx)(Ne.h$,{label:e.desc,checked:b.includes(e.code)})},`reporter-appeal-reason-${t}`)))]}),(0,u.jsxs)($t,{children:[(0,u.jsxs)(Jt,{children:[(0,u.jsx)(Xt,{children:(null===(o=c.description)||void 0===o?void 0:o.header)||r("dsa_illegal_appeal_explanation")}),(0,u.jsx)(en,{}),(0,u.jsx)(Qt,{children:`${_.length}/400`})]}),(0,u.jsx)(Kt,{children:(0,u.jsx)(Yt,{rows:2,maxLength:400,placeholder:(null===(a=c.description)||void 0===a?void 0:a.placeholder)||"",value:_,onChange:x,onKeyDown:k})})]}),(0,u.jsxs)(tn,{children:[r("dsa_illegal_appeal_alt_options").replace("%s",""),(0,u.jsx)(nn,{onClick:()=>{window.open(c.learn_more_link||"","_blank")},children:r("dsa_illegal_placeholder_learnmore")})]})]}),(0,u.jsx)(on,{children:(0,u.jsx)(cn.jl,{disabled:""===b,onClick:O,children:r("Submit")})})]})},pn=(0,$.default)("div",{target:"e1s71jua0"})({paddingLeft:24,paddingRight:24,height:"100%",flexGrow:1},"label:Container;"),vn=(0,$.default)("div",{target:"e1s71jua1"})((({theme:e})=>({padding:16,backgroundColor:e.colors.BGPrimary,borderRadius:8,marginBottom:8})),"label:ComponentWrapper;"),mn=(0,$.default)("div",{target:"e1s71jua2"})({position:"relative",bottom:"0",left:"0",width:"100%",height:54,marginBottom:16,marginTop:16,padding:8,display:"flex",flexDirection:"column",alignItems:"end",justifyContent:"center"},"label:DivFooter;"),gn=(0,$.default)("div",{target:"e1s71jua3"})({display:"flex",flexDirection:"column",height:"580px",overflowY:"auto"},"label:ContainerWrapper;"),hn=(0,$.default)("div",{target:"e1s71jua4"})({display:"flex",flexDirection:"column",alignItems:"start",marginBottom:32},"label:DivSubmitHeader;"),_n=(0,$.default)("div",{target:"e1s71jua5"})((({theme:e})=>({color:e.colors.Primary,display:"inline",marginLeft:"2px"})),"label:AsteriskColor;"),fn=(0,$.default)("div",{target:"e1s71jua6"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P1",color:"TextPrimary",fontWeight:"medium"}),{marginBottom:15}]),"label:SectionHeader;"),yn=(0,$.default)("div",{target:"e1s71jua7"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"H4",color:"TextPrimary",fontWeight:"bold"}),{marginTop:16}]),"label:AppealTitle;"),bn=(0,$.default)("div",{target:"e1s71jua8"})((()=>({marginBottom:"12px","&:last-child":{marginBottom:"0"}})),"label:RadioWrapper;"),wn=(0,$.default)("div",{target:"e1s71jua9"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P2",color:"TextSecondary",fontWeight:"normal"}),{marginTop:12}]),"label:AppealSubtitle;"),xn=(0,$.default)("div",{target:"e1s71jua10"})({cursor:"pointer",padding:"9px",height:"32px"},"label:DivCloseButton;"),Tn=(0,$.default)("div",{target:"e1s71jua11"})({flexGrow:1},"label:FlexGrowDiv;"),kn=(0,$.default)("button",{target:"e1s71jua12"})((({theme:e})=>[(0,W.zy)({theme:e,fontFamily:"TikTokFont",typography:"P3",color:"ConstTextInverse",fontWeight:"semiBold"}),{height:"36px",padding:"7px 16px",position:"absolute",cursor:"pointer",right:"24px",color:e.colors.ConstTextInverse,background:e.colors.Primary,border:"none",borderRadius:"4px",":disabled":{background:e.colors.BGPlaceholderDefault,color:e.colors.TextQuaternary}}]),"label:ButtonSubmit;"),Sn=({handleBack:e,handleBackKeyDown:t,handleClose:n})=>{var i,o,a,r,s,l,c,d;const v=(0,ae.s)(),m=(0,p.w)(q),{status:g,detail:h,contentDetailList:_,appealReasons:y}=(0,ie.P)(q),[b,w]=(0,G.useState)(null),[x,T]=(0,G.useState)(""),k=null===(o=null===(i=h.base_info)||void 0===i?void 0:i.appeal_submit_page_title)||void 0===o?void 0:o.title,S=null===(r=null===(a=h.base_info)||void 0===a?void 0:a.appeal_submit_page_title)||void 0===r?void 0:r.sub_title,E=null===(l=null===(s=h.base_info)||void 0===s?void 0:s.appeal_submit_page_title)||void 0===l?void 0:l.sub_title_v2,A=null===(c=null==h?void 0:h.violation_info)||void 0===c?void 0:c.appeal_info.appeal_type,O=null==h?void 0:h.object_id,P=null==h?void 0:h.punish_key,I=null==h?void 0:h.object_type,C=!!Array.isArray(y)&&y.length>0,L=E&&f.d7.includes(I.toString()),j=(null===(d=null==h?void 0:h.violation_info)||void 0===d?void 0:d.header)||"";(0,G.useEffect)((()=>{void 0!==A&&m.getAppealReasons({appeal_type:A,object_id:O})}),[A,m,O]);const M=e=>{e&&window.open(e,"_blank")},N=(0,G.useCallback)((t=>{if(t.preventDefault(),t.stopPropagation(),"idle"!==g||void 0===A)return;const n=(({appealType:e,objectId:t,punishKey:n,hasAppealReasons:i,selectedReason:o,descriptionBox:a})=>{const r={appealType:e,objectId:t,punishKey:n};if(a&&!i)r.reason=JSON.stringify({file_uri:"",description:a});else if(i&&null!==o){const e={type:2,options:[o],description:a||""};r.reason=JSON.stringify(e)}return r})({appealType:A,objectId:O,punishKey:P,hasAppealReasons:C,selectedReason:b,descriptionBox:x});m.postViolationAppeal(n),m.setViolationAppealStatus("loading"),e()}),[m,g,A,O,P,b,C,x,e]);return"loading"===g?(0,u.jsx)(oe.R,{center:!0,size:"small"}):(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)(Y,{children:[(0,u.jsx)(X,{onClick:e,onKeyDown:t,role:"button",children:(0,u.jsx)(dn.A,{width:24,height:24})}),(0,u.jsx)(Tn,{}),(0,u.jsx)(xn,{onClick:n,children:(0,u.jsx)(ne.A,{width:14,height:14})})]}),(0,u.jsx)(gn,{children:(0,u.jsxs)(pn,{children:[(0,u.jsxs)(hn,{children:[k&&(0,u.jsx)(yn,{children:k}),L?(0,u.jsx)(Ot,{btnText:E,onClick:M}):S&&(0,u.jsx)(wn,{children:S})]}),(0,u.jsx)(vn,{children:(0,u.jsx)(Fe,{title:j,list:_,handleOpenLink:M,seeMoreText:v("search_see_more")})}),C&&(0,u.jsxs)(vn,{children:[(0,u.jsxs)(fn,{children:[v("reasonForAppeal_appealPg_appealReasonCard_title"),(0,u.jsx)(_n,{children:"*"})]}),y.map((e=>(0,u.jsx)(bn,{children:(0,u.jsx)(Ne.v3,{label:e.text,name:"appealReason",value:e.code.toString(),checked:b===e.code,onChange:()=>w(e.code)})},e.code)))]}),C&&(0,u.jsx)(vn,{children:(0,u.jsx)(Ne.U5,{label:v("dsa_illegal_appeal_explanation"),value:x,onChange:e=>T(e.target.value),placeholder:v("dsa_illegal_uploader_vio_appeal_exp_desc"),maxLength:200,block:!0})})]})}),(0,u.jsx)(mn,{children:(0,u.jsx)(kn,{onClick:N,disabled:C&&null===b,children:v("Submit")})})]})};var En=n(57431),An=n(54775);const On=({reportId:e,onBack:t,objectId:n,objectType:i,punishKey:o,onClose:a,verificationCode:r,penaltyDetails:s})=>{const{user:l,language:c}=(0,En.x)(),d=(0,p.w)(q),[v,m]=(0,G.useState)(f.qZ.STATUS),g=(0,G.useCallback)((()=>{t?t():m(f.qZ.STATUS)}),[t]),h=(0,G.useCallback)((()=>{a()}),[a]),_=(0,G.useCallback)((()=>{m(f.qZ.SUBMIT)}),[]),y=(0,G.useCallback)((e=>{13!==e.keyCode&&32!==e.keyCode||(e.preventDefault(),e.stopPropagation(),g())}),[g]);return(0,G.useEffect)((()=>{var t,a,u;if(s)d.getPenaltyDetail({vid:null!==(t=s.vid)&&void 0!==t?t:"",storeRegion:null!==(a=null==l?void 0:l.storeRegion)&&void 0!==a?a:"",videoInfo:s.videoInfo,lang:c,uid:null!==(u=null==l?void 0:l.uid)&&void 0!==u?u:""});else if(e)d.getReporterAppeal({reportId:e,loggedOutCode:r});else{if(!n||!i)return;d.getViolationDetail({objectId:n,objectType:i,punishKey:o})}}),[n,i,o,d,s]),(0,G.useEffect)((()=>{r&&d.setLoggedOutCode(r)}),[r]),(0,u.jsx)(Z,{children:(0,u.jsx)(An.juU,{children:e?(0,u.jsx)(un,{handleBack:g,handleBackKeyDown:y,handleClose:h}):v===f.qZ.SUBMIT?(0,u.jsx)(Sn,{handleBack:g,handleBackKeyDown:y,handleClose:h}):(0,u.jsx)(Rt,{handleBack:g,handleBackKeyDown:y,handleClose:h,handleAppealClick:_})})})}},88920:(e,t,n)=>{"use strict";n.d(t,{$4:()=>Rt,$r:()=>he,A8:()=>Pe,AP:()=>Re,Ad:()=>Be,BM:()=>Te,CQ:()=>Se,E1:()=>mt,Eg:()=>jt,Eo:()=>M,Eq:()=>Xe,Ey:()=>Wt,FI:()=>Vt,FT:()=>ke,Fb:()=>Kt,Fl:()=>Ge,Fo:()=>Ce,Ge:()=>St,HL:()=>Zt,HW:()=>Jt,Hh:()=>je,IP:()=>Ut,JX:()=>He,Jc:()=>J,Jl:()=>st,KK:()=>Xt,KS:()=>ee,KV:()=>B,Kg:()=>Ze,Kj:()=>Ue,LK:()=>$t,M4:()=>oe,Md:()=>H,Mz:()=>de,NF:()=>gt,NV:()=>Ie,NY:()=>G,ON:()=>At,OQ:()=>dt,O_:()=>fe,Oi:()=>kt,Oj:()=>Ft,PV:()=>Ne,Pk:()=>Nt,Pl:()=>nt,Q5:()=>lt,QN:()=>xt,QY:()=>pt,RC:()=>we,Ry:()=>X,Sc:()=>R,TP:()=>ae,Tg:()=>W,Tt:()=>ge,Vn:()=>Ht,Vv:()=>rt,W3:()=>ne,W4:()=>U,WE:()=>tt,WO:()=>K,Wh:()=>F,X$:()=>qt,Xl:()=>$,Yu:()=>ue,ZC:()=>pe,ZO:()=>ye,ZT:()=>Ot,_Y:()=>Oe,_o:()=>et,aL:()=>Ye,aO:()=>Gt,ac:()=>Y,bx:()=>ut,c8:()=>re,cE:()=>N,cV:()=>Yt,d1:()=>Ae,eZ:()=>ot,eb:()=>be,eu:()=>ze,fH:()=>wt,fy:()=>at,gQ:()=>vt,gR:()=>q,gg:()=>Pt,hn:()=>$e,iM:()=>ve,iz:()=>Me,jC:()=>Je,jw:()=>Fe,k0:()=>bt,kT:()=>qe,kb:()=>D,l2:()=>te,lP:()=>ie,lZ:()=>Tt,mT:()=>Mt,mf:()=>Bt,ng:()=>it,oJ:()=>Qt,pC:()=>Et,pJ:()=>en,pd:()=>me,q:()=>De,q6:()=>se,qZ:()=>Z,r6:()=>xe,rl:()=>zt,rq:()=>ct,s0:()=>We,sF:()=>_e,tY:()=>ft,tc:()=>le,tj:()=>Dt,u6:()=>z,uT:()=>ce,ul:()=>Le,vY:()=>Lt,vh:()=>ht,vp:()=>It,wX:()=>Ve,xZ:()=>V,y9:()=>Q,yc:()=>yt,yk:()=>Qe,yl:()=>_t,zD:()=>Ee,zy:()=>Ct});var i=n(5441),o=n(6523),a=n(47172),r=n(4629),s=n(51660),l=n(4929),c=n(82715),d=n(8227),u=n(75792),p=n(35267),v=n(48961),m=n(4685),g=n(23294),h=n(95868),_=n(58305),f=n(93341),y=n(67823),b=n(40099),w=n(30721),x=n(49057),T=n(48615),k=n(89558),S=n(45297),E=n(34012),A=n(45212),O=n(60484),P=n(71281),I=n(32862);const C="abTestVersion",L="videoPlayerConfig",j="playbackNormalizePath";function M(){const{isSmartPlayer:e}=(0,w.Qt)();return{isMobileUiOptimize:!e}}const N=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[]));return{hasNonPersonalizedMenu:"v2"===(null!==(e=(0,P.qt)(t,k.W$))&&void 0!==e?e:"v1")}},D=e=>{var t,n;const{abTestVersion:i}=(0,O.L$)((0,x.W)((()=>[C]),[])),o=null!==(t=(0,P.qt)(i,"desktop_ui_reply"))&&void 0!==t?t:"v1",a="v5"===o,r="v6"===o;return{shouldAvatarShowNickName:"v2"===(null!==(n=(0,P.qt)(i,"desktop_avatar_nick_name"))&&void 0!==n?n:"v1"),shouldOptimizeCta:"v2"===o||a,allowRightPanelScroll:a||r,shouldOptimizeReply:a||r,onlyOptimizeCta:"v2"===o,shouldShowCommentsCnt:"v2"===o||"v3"===o||a||r,isDesktopUiOptDebugOn:(0,P.TQ)("desktop_ui_opt_debug")&&!e,shouldIncludeV3V4:r}};function R(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[])),{videoPlayerConfig:n}=(0,O.L$)((0,T.U)((()=>[L]),[]));return{isUseNativePlayer:null==n?void 0:n.fallback,adaptBitrateVid:null!==(e=(0,P.qt)(t,"video_bitrate_adapt"))&&void 0!==e?e:"v1"}}function B(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[])),{playbackNormalizePath:n}=(0,O.L$)((0,T.U)((()=>[j]),[]));return{normalizationVid:null!==(e=(0,P.qt)(t,"volume_normalize"))&&void 0!==e?e:"v1",playbackNormalizePath:n}}function U(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[]));return null!==(e=(0,P.qt)(t,"xg_volume_test"))&&void 0!==e?e:"v1"}function F(){var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>[C]),[])),i=null!==(e=(0,P.qt)(n,"feed_scroll_opt"))&&void 0!==e?e:"v0";return{hasLimitedItem:"v1"===i,hasMultiPlayerIns:"v2"===(null!==(t=(0,g.S)(n,"multiple_ins_model"))&&void 0!==t?t:"v0"),hasOptForFeed:"v1"===i}}function V(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[])),n=null!==(e=(0,P.qt)(t,"multiple_ins_new"))&&void 0!==e?e:"v0",{hardwareScore:i}=(0,m.fL)();return{hasRetainIns:"v4"===n&&i>8.5,hasBackupIns:"v1"===n||"v2"===n&&i>=5||"v3"===n&&i>=6||"v4"===n}}function z(e){const{vgeo:t}=(0,O.L$)((0,T.U)((()=>["vgeo"]),[])),{wid:n}=(0,O.L$)((0,x.W)((()=>["wid"]),[])),i=function(e){var t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>[C]),[]));return null!==(t=(0,P.qt)(n,e))&&void 0!==t?t:"v1"}(e);return{vgeo:t,wid:n,vid:i}}function H(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[]));return{preloadConfigVid:null!==(e=(0,P.qt)(t,"xgplayer_preload_config"))&&void 0!==e?e:"v1"}}function q(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[])),n=null!==(e=(0,P.qt)(t,"remove_tooltip"))&&void 0!==e?e:"v0";return{removeUploadPop:"v1"===n,removeLivePop:"v1"===n,removeEditProfilePop:"v1"===n,removeOtherPop:"v4"===n,removeShortcutPop:"v5"===n}}function G(){const{xgplayerInitHost:e}=(0,O.L$)((0,T.U)((()=>["xgplayerInitHost"]),[]));return{playerInitHost:e}}function $(){const{videoOrder:e}=(0,O.L$)((0,T.U)((()=>["videoOrder"]),[]));return{videoOrder:null==e?void 0:e.videoOrder}}function W(){const{bitrateSelectorConfigs:e}=(0,O.L$)((0,T.U)((()=>["bitrateSelectorConfigs"]),[]));return{bitrateSelectorConfigs:null==e?void 0:e.configs}}function Z(){const{hevcRobustness:e}=(0,O.L$)((0,T.U)((()=>["hevcRobustness"]),[]));return{useHevcRobustTest:!e||e.useHevcRobustTest,forceRobustTest:e?e.forceRobustTest:["Edge"]}}function Y(){const{pathname:e}=(0,a.useLocation)(),t=(0,E.Ig)()?"v1":"v2",n=(0,h.Fj)(e),i="v1"!==t,o="v1"!==t;return{isVideoPlayerOptimization:i,hasPip:o,isUIOptimization:!1,isVideoDetailUIOptimization:!1,hasVideoDetailPip:o&&n,isVideoDetailExperiment:"v1"!==t&&n,isVideoDetailPlayerExperiment:i&&n}}const K=e=>{if(!e)return{};const{id:t,type:n,isClaimed:i,cityCode:o,countryCode:a,ttTypeNameSuper:r,ttTypeNameMedium:s,ttTypeNameTiny:l,ttTypeCode:c,typeCode:d}=e;return{poi_id:t,poi_backend_type:n,poi_detail_type:v.Af[null!=n?n:0],is_claimed:i?1:0,poi_city:o,poi_region_code:a,tt_poi_backend_type:`${r},${s},${l}|${c}`,poi_type_code:d}},X=e=>{var t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=null!==(t=(0,P.qt)(n,"explore_ui_change"))&&void 0!==t?t:"v0";return{isClearUI:"v1"===i&&e,withCreator:"v1"!==i&&"v0"!==i&&e,withLike:("v3"===i||"v4"===i)&&e,withBack:"v4"===i&&e,withDes:("v4"===i||"v0"===i)&&e,withNoLeftInfo:"v2"===i}},Q=()=>{var e;const{abTestVersion:t,language:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion","language"]),[]));let i=null!==(e=(0,P.qt)(t,"search_preview_ui_change"))&&void 0!==e?e:"v0";return"hu-HU"!==n&&"hu"!==n||"v3"!==i||(i="v0"),{withLikeAndCreator:"v1"===i||"v2"===i||"v3"===i,removeDesc:"v1"===i,withOneLineDesc:"v2"===i||"v3"===i,withPublishTime:"v3"===i}},J=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"seo_preview_ui_change"))&&void 0!==e?e:"v0")},ee=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,g.S)(t,"perf_blur_background"))&&void 0!==e?e:"v0",{withBlurBG:i,withNoBG:o,withLinearGradientBG:a,withLinearGradientBlueBG:r,withLinearGradientBlackBG:s}=(0,b.useMemo)((()=>({withBlurBG:"v0"===n,withNoBG:"v1"===n,withLinearGradientBG:"v2"===n||"v3"===n,withLinearGradientBlueBG:"v3"===n,withLinearGradientBlackBG:"v2"===n})),[n]);return{withBlurBG:i,withNoBG:o,withLinearGradientBG:a,withLinearGradientBlueBG:r,withLinearGradientBlackBG:s}};function te(){var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>[C]),[])),{pathname:n}=(0,a.useLocation)(),i=null==t?void 0:t.versionName.split(",");return{isInHorizontalBoostUI:null!==(e=null==i?void 0:i.includes("71188781"))&&void 0!==e&&e&&((0,h.tO)(n)||(0,h.gq)(n))}}const ne=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"islands_arch_user_profile"))&&void 0!==e?e:"v0";return{delayUntilAnyItem:"v1"===n,delayUntilFirstItem:"v2"===n}},ie=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{hasCommonVideoFirst:"v1"===(null!==(e=(0,P.qt)(t,"islands_arch_rest_page"))&&void 0!==e?e:"v0")}},oe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{isOpenNewTab:"v2"===(null!==(e=(0,P.qt)(t,"webapp_browser_mode_new_tab"))&&void 0!==e?e:"v1")}},ae=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v2"===(null!==(e=(0,P.qt)(t,"sidenav_test"))&&void 0!==e?e:"v1")},re=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"webapp_auto_refresh"))&&void 0!==e?e:"v1";return{refreshWhenExpireAndEmpty:"v2"===n,refreshInAllCase:"v3"===n}},se=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"one_column_player_size"))&&void 0!==e?e:"v1";return{useEnlargedVideoPlayer:"v1"!==n,useCenterAligned:"v3"===n||"v4"===n,useWiderContainerSize:"v4"===n||"v5"===n}},le=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v2"===(null!==(e=(0,P.qt)(t,"use_follow_v2"))&&void 0!==e?e:"v1")},ce=()=>{const{abTestVersion:e}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(0,P.qt)(e,"playback_refactor_desktop")},de=()=>{var e,t;const{isElectronApp:n}=(0,i.B)(),{abTestVersion:o}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),a=null!==(e=(0,P.qt)(o,"on_device_ml_player_preload"))&&void 0!==e?e:{vid:"v0"},{isLowEndDevice:r}=(0,A.qo)(),s=null!==(t=null==a?void 0:a.vid)&&void 0!==t?t:"v0",l=!n&&"undefined"!=typeof WebAssembly&&!r;return{playerPreloadPredictStrategy:a,disablePreloadPredict:"v0"===s,enablePlayerPreloadPredict:("v1"===s||"v2"===s)&&l,enablePlayerPreloadDowngradePredict:"v3"===s||"v0"!==s&&!l}},ue=()=>{var e,t,n;const{abTestVersion:i}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),o=(0,P.qt)(i,"tt_player_hevc_ignore_env")||"v0",a=(0,P.qt)(i,"tt_player_hevc_local")||"v0",r=(0,P.qt)(i,"tt_player_reuse"),s=(0,P.qt)(i,"tt_player_openmse"),{disablePreloadPredict:l}=de(),c=(0,f.PU)(),d=null!==(e=(0,P.qt)(i,"tt_player_preload"))&&void 0!==e?e:{vid:"v0",maxQueueCount:3,preloadMaxCacheCount:5,preloadTime:10,segmentMinDuration:10,minBufferLength:10,startPreloadControl:!1,startPreloadMinBuffer:0,startPreloadMinPosTime:0};return{playerReuse:"v1"===r?1:0,playerPreload:l?d:Object.assign(Object.assign({},d),c),bitrateSelect:null!==(t=(0,P.qt)(i,"ttplayer_bitrate_select"))&&void 0!==t?t:{vid:"v0",selector:"default",qualityType:20,hevcQualityType:14},hevcIgnoreEnv:"v1"===o?1:0,hevcResultLocal:"v1"===a?1:0,playerUpgrade:null!==(n=(0,P.qt)(i,"tt_player_upgrade"))&&void 0!==n?n:{vid:"v0",playerType:"XG"},playerOpenMse:"v1"===s?1:0}},pe=()=>{const e={};return[{key:"tt_player_h265soft",retKey:"playerH265Soft"}].forEach((t=>{const n=(0,I.OW)(t.key,{});n.vid&&(e[t.retKey]=n)})),e},ve=e=>{const t={open:!1,qualityType:20,vid:"v0",closePreload:!1,testKey:"none"},n=["hevc_device_edge_low","hevc_device_edge_high","hevc_device_chrome_low","hevc_device_chrome_high","hevc_device_test"];if("desktop"===e){if("undefined"==typeof window)return t;let e=null,i="none";for(let t=0;t{if("undefined"==typeof window||"desktop"!==e)return"";const t=[];return["hevc_device_test","hevc_device_edge_low","hevc_device_edge_high","hevc_device_chrome_low","hevc_device_chrome_high","tt_player_h265soft"].forEach((e=>{const n=(0,I.HL)(e,{vid:""});n&&t.push(n)})),t.join(",")},ge=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"enable_ml_model_suggest_content"))&&void 0!==e?e:"v0")},he=({enterFrom:e,linkIncludeVid:t})=>{var n;const{abTestVersion:i}=(0,O.L$)((0,x.W)((()=>[C]),[])),o=null!==(n=(0,P.qt)(i,"studio_web_eh_entrance_v3"))&&void 0!==n?n:"v1";let a="https://effecthouse.tiktok.com/download?utm_source=tiktok_webapp_main";return e&&(a=`${a}&enter_from=${e}`),t&&(a=`${a}&utm_campaign=ttweb_entrance_${o}`),{showEhEntrance:!0,entranceVariant:o,ehLink:a}},_e=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{isAutoScrollReposition:"v0"!==(null!==(e=(0,P.qt)(t,"autoscroll_reposition"))&&void 0!==e?e:"v0")}},fe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v0"!==(null!==(e=(0,P.qt)(t,"banner_ad_enable"))&&void 0!==e?e:"v1")},ye=()=>{const{abTestVersion:e}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),t=(0,P.qt)(e,"project_ace_control");return"v0"===t||"v1"===t},be=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"add_profile_left_bar"))&&void 0!==e?e:"v0";return{showProfileLeftBar:"v1"===n||"v3"===n,enableClickTopRightIcon:"v2"===n||"v3"===n}},we=()=>{var e;const{abTestVersion:t,user:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion","user"]),[])),i=!!n;return"v1"===(null!==(e=(0,P.qt)(t,"friends_tab"))&&void 0!==e?e:"v0")&&i},xe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"video_detail_reflow_card"))&&void 0!==e?e:"v0")},Te=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"yml_ui_optimize"))&&void 0!==e?e:"v0";return{isCoverImageChanged:"v1"===n,isMetaDataChanged:"v2"===n,isCoverImageAndMetaDataChanged:"v3"===n}},ke=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"guide_user_to_next_video"))&&void 0!==e?e:"v0";return{isVideoDetailPage:"v1"===n,isFYP:"v2"===n}},Se=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"creator_to_fyp"))&&void 0!==e?e:"v0";let i=0;return"v1"===n?i=1:"v2"===n&&(i=2),{sendCreatorItemId:"v1"===n||"v2"===n,batchCount:i}},Ee=()=>{const{abTestVersion:e}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),t=(0,g.S)(e,"video_detail_end_card");return{toCreatorEndCard:"v1"===t||!t,toForyouEndCard:"v2"===t||!t,toExploreEndCard:"v3"===t}},Ae=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"detail_to_explore"))&&void 0!==e?e:"v0";return{inExploreEndCardExperiment:"v0"!==n,isExploreEndCardFourVideo:"v1"===n||"v2"===n,isExploreEndCardCategoryAll:"v2"!==n&&"v4"!==n}},Oe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"three_column_gif"))&&void 0!==e?e:"v0")},Pe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"creator_header_height"))&&void 0!==e?e:"v0";return{isShorterCreatorHeader:"v1"===n||"v2"===n||"v3"===n,isOneLineBio:"v2"===n||"v3"===n,isHeaderButtonLower:"v3"===n}},Ie=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"encourage_share_repost"))&&void 0!==e?e:"v0";return{isForyou:"v2"===n||"v4"===n,isVideoDetail:"v1"===n||"v4"===n,isBrowserMode:"v3"===n||"v4"===n,isInExperiment:"v0"!==n}},Ce=()=>{var e,t,n,i;const a=(0,o.wW)(),r=null!==(t=null===(e=null==a?void 0:a.parameters.seo_tag_and_title)||void 0===e?void 0:e.vid)&&void 0!==t?t:"v0",s=null!==(i=null===(n=null==a?void 0:a.parameters.seo_tag_and_title)||void 0===n?void 0:n.isArticleHtmlTag)&&void 0!==i&&i,{isSearchEngineBot:l=!1}=(0,O.L$)((0,T.U)((()=>["isSearchEngineBot"]),[]));return{useTitle:["v1","v3"].includes(r)&&l,useHtmlTag:["v2","v3"].includes(r),useArticleHtmlTag:s}},Le=()=>{var e,t,n,i;const a=(0,o.wW)(),r=null!==(e=null==a?void 0:a.vidList)&&void 0!==e?e:[],s=(0,x.W)((()=>["abTestVersion"]),[]);return[...r,...null!==(i=null===(n=null===(t=null==s?void 0:s.abTestVersion)||void 0===t?void 0:t.versionName)||void 0===n?void 0:n.split(","))&&void 0!==i?i:[]]},je=()=>{const{abTestVersion:e}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),t=(0,P.qt)(e,"webapp_causal_inference_auto_scroll_data_collection");return{useAutoScrollModelResult:"v2"===t||"v3"===t}},Me=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"auto_scroll"))&&void 0!==e?e:"v1";return"v1"===n&&(0,_.sc)("auto_scroll"),{hasAutoScrollButton:"v1"!==n}},Ne=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,g.S)(t,"preview_cover"))&&void 0!==e?e:"v0";return(0,b.useMemo)((()=>"v1"===n),[n])},De=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"show_aigc_label_web"))&&void 0!==e?e:"v0")},Re=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v2"===(null!==(e=(0,P.qt)(t,"use_profile_avatar"))&&void 0!==e?e:"v1")},Be=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"pc_non_personalized_suggested_account"))&&void 0!==e?e:"v0")},Ue=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"pc_non_personalized_explore"))&&void 0!==e?e:"v0")},Fe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"use_aligned_copies"))&&void 0!==e?e:"v0";return{default:"v0"===n,solution1:"v1"===n,solution2:"v2"===n}},Ve=()=>{var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=null!==(e=(0,P.qt)(n,"desktop_web_survey_new"))&&void 0!==e?e:"v0",o=null!==(t=(0,P.qt)(n,"desktop_web_survey_old"))&&void 0!==t?t:"v0";return{shouldShowSurvey:"v0"!==i||"v0"!==o,isNewUser:"v0"!==i}},ze=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"enable_autoscroll_moremenu"))&&void 0!==e?e:"v0")},He=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"enable_video_detail_moremenu_refactor"))&&void 0!==e?e:"v0";return{enableNewPopover:"v0"!==n,moveFullScreenToMoreMenu:"v1"===n||"v2"===n,showPopoverRightTopCorner:"v2"===n||"v3"===n}},qe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v2"===(null!==(e=(0,P.qt)(t,"video_detail_page_video_play"))&&void 0!==e?e:"v1")},Ge=()=>{var e,t,n,i;return{isRepostLabelEnabled:"v0"!==(null!==(e=(0,P.d)("webapp_repost_label"))&&void 0!==e?e:"v0"),isRepostTabEnabled:"v0"!==(null!==(t=(0,P.d)("webapp_repost_tab"))&&void 0!==t?t:"v0"),repostActionVid:null!==(n=(0,P.d)("webapp_repost_action"))&&void 0!==n?n:"v0",isRepostNoticeEnabled:"v0"!==(null!==(i=(0,P.d)("webapp_repost_notice"))&&void 0!==i?i:"v0")}},$e=()=>Ge(),We=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"webapp_creator_post_sort"))&&void 0!==e?e:"v0";return{isPostSortBottomLeftEnabled:"v1"===n,isPostSortBottomMiddleEnabled:"v2"===n,isPostSortRightTwoOptionsEnabled:"v3"===n,isPostSortRightMenuEnabled:"v4"===n,isPostSortRightThreeOptionsEnabled:"v5"===n}},Ze=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"webapp_creator_just_watched"))&&void 0!==e?e:"v0";return{isJustWatchedEnabled:"v0"!==n,isButtonPrimary:"v1"===n||"v3"===n,isButtonSizeLarge:"v3"===n||"v4"===n}},Ye=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"guest_mode_redesign"))&&void 0!==e?e:"v0";return{showRedesign:"v0"!==n,buttonKey:(e=>{switch(e){case"v1":default:return"pcWeb_guestLogin_contToVideo";case"v2":return"pcWeb_guestLogin_guest";case"v3":return"pcWeb_guestLogin_without"}})(n)}};function Ke(e){var t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=(0,P.qt)(n,e),o=null!==(t=(0,P.qt)(n,"delay_guest"))&&void 0!==t?t:"2",a=y.A.get(S.er)||"";if(void 0!==a&&""!==a){const e=Number(a);return isNaN(e)?(console.error(`Invalid vv limit: ${a}`),{vvLimit:Number(o)}):{vvLimit:e}}return void 0!==i?(y.A.set(S.er,i,S.Ah),{vvLimit:Number(i)}):{vvLimit:Number(o)}}const Xe=()=>{const{pathname:e}=(0,a.useLocation)(),t={delay_guest_fyp:Ke("delay_guest_fyp"),delay_guest_others_homepage:Ke("delay_guest_others_homepage"),delay_guest_videos:Ke("delay_guest_videos"),delay_guest_discover:Ke("delay_guest_discover"),delay_guest_explore:Ke("delay_guest_explore"),delay_guest_other:Ke("delay_guest_other")};return(0,h.tO)(e)?t.delay_guest_fyp:(0,h.cj)(e)?t.delay_guest_others_homepage:(0,h.Fj)(e)?t.delay_guest_videos:(0,h.pz)(e)?t.delay_guest_discover:(0,h.eD)(e)?t.delay_guest_explore:t.delay_guest_other},Qe=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"video_detail_yml_ui"))&&void 0!==e?e:"v1";return{shouldSwapInfo:"v2"===n||"v4"===n,shouldListView:"v3"===n||"v4"===n}},Je=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{hasPip:"v1"!==(null!==(e=(0,P.qt)(t,"video_detail_auto_pip_opt"))&&void 0!==e?e:"v0")}},et=()=>{var e;const t="webapp_dynamic_bottom_right",{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=null!==(e=(0,g.S)(n,t))&&void 0!==e?e:"v0",{isInDynamicBottomRightExperiment:o,isInDynamicBottomRightControl:a,isInDynamicBottomRightFolded:r,isInDynamicBottomRightExpanded:s}=(0,b.useMemo)((()=>({isInDynamicBottomRightExperiment:"v0"===i||"v1"===i||"v2"===i,isInDynamicBottomRightControl:"v0"===i,isInDynamicBottomRightFolded:"v1"===i,isInDynamicBottomRightExpanded:"v2"===i})),[i]);return{baseExpId:t,isInDynamicBottomRightExperiment:o,isInDynamicBottomRightControl:a,isInDynamicBottomRightFolded:r,isInDynamicBottomRightExpanded:s}},tt=()=>{var e;const t="webapp_auto_dark_mode",{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=null!==(e=(0,g.S)(n,t,!0))&&void 0!==e?e:"v0",{isInAutoDarkModeExperiment:o,isInAutoDarkModeControl:a,isInAutoDarkModeTreatment:r}=(0,b.useMemo)((()=>({isInAutoDarkModeExperiment:"v0"===i||"v1"===i,isInAutoDarkModeControl:"v0"===i,isInAutoDarkModeTreatment:"v1"===i})),[i]);return{baseExpId:t,isInAutoDarkModeControl:a,isInAutoDarkModeTreatment:r,isInAutoDarkModeExperiment:o}},nt=()=>{const{abTestVersion:e}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),t=(0,P.qt)(e,"browser_fingerprint_basic"),n=(0,P.qt)(e,"browser_fingerprint_verify");return{isInBasicTreatment:"v1"===t,isInVerification:"v0"===n||"v1"===n}},it=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"top_right_button"))&&void 0!==e?e:"v0",{pathname:i}=(0,a.useLocation)(),o=(0,h.tO)(i)||(0,h.gq)(i)||(0,h.K8)(i);return{isInTopRightButtonTreatment:"v0"!==n&&o,isInTopRightButtonLeftNavHide:("v2"===n||"v4"===n)&&o,isInTopRightButtonProfile:("v3"===n||"v4"===n)&&o}},ot=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),{isMobile:n}=(0,O.L$)((0,T.U)((()=>["isMobile"]),[])),i=null!==(e=(0,P.qt)(t,"top_right_button_group"))&&void 0!==e?e:"v0",{pathname:o}=(0,a.useLocation)(),r=((0,h.tO)(o)||(0,h.gq)(o)||(0,h.K8)(o))&&!n;return{isInTopRightButtonGroupTreatment:"v0"!==i&&r,isConnectedActionBar:("v3"===i||"v4"===i)&&r,isButtonGroupWithText:("v2"===i||"v4"===i)&&r}},at=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"keyboard_shortcut"))&&void 0!==e?e:"v0",{pathname:i}=(0,a.useLocation)(),o=(0,h.tO)(i)||(0,h.gq)(i)||(0,h.K8)(i);return{isInKeyboardShortcutTreatment:"v0"!==n&&o,isInKeyboardShortcutV1:"v1"===n&&o,isInKeyboardShortcutV2:"v2"===n&&o}},rt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"use_container_exp"))&&void 0!==e?e:"v0";return{isInProductHoldout:"v1"===n||"v3"===n,isInPerformanceHoldout:"v2"===n||"v3"===n}},st=(e,t)=>{var n;const{abTestVersion:i}=(0,O.L$)((0,x.W)((()=>[C]),[])),o=null!==(n=(0,P.qt)(i,"tteh_effect_anchor_v1"))&&void 0!==n?n:"v1",a="v1"!==o&&[5,129,0].includes(null!=t?t:999);let r=e;return a||(r=[]),{shouldShowEhEffectAnchor:a,effectAnchors:r,abVariant:o}},lt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"video_detail_yml_creator"))&&void 0!==e?e:"v0";return{useCreatorFeed:"v0"!==n,showPinnedVideos:"v2"===n}},ct=()=>{var e;const{abTestVersion:t,user:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion","user"]),[])),i=!!n;let o=null!==(e=(0,P.qt)(t,"video_detail_author_card"))&&void 0!==e?e:"v0";return i&&(o="v0"),{useAuthorCard:"v0"!==o,useLargeCard:"v3"===o,withCountDown:"v2"===o}},dt=()=>{var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=null!==(e=(0,P.qt)(n,"video_detail_nav_opt"))&&void 0!==e?e:"v0",o=null!==(t=(0,P.qt)(n,"video_detail_nav_shortcut"))&&void 0!==t?t:"v0";return{pushHistory:"v1"===i||"v3"===i,newTabAndShortcut:"v1"===o||"v4"===o,enableShortcutFocusAddressBar:"v2"===o||"v4"===o,enableShortcutRefreshAndCopy:"v3"===o||"v4"===o,enableAllShortcut:"v4"===o}},ut=()=>{var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),i=null!==(e=(0,P.qt)(n,"video_details_player_redesign_engagement"))&&void 0!==e?e:"v0",o=null!==(t=(0,P.qt)(n,"video_details_player_redesign_player"))&&void 0!==t?t:"v0",a="v0"!==i||"v3"===o,r=a&&"v1"!==i||"v3"===o,s="v0"!==o;return{showCurvedPlayerEdges:"v0"!==o||"v0"!==i,showFYPButtonStyle:a,moveCreatorIcon:r,moveEngagementPanel:r&&"v2"!==i||"v3"===o,updateButtonPanel:s,updatePlayerControls:s&&"v1"!==o}},pt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"search_top_author_card"))&&void 0!==e?e:"v0";return{withFollowButton:"v0"!==n,withVideoList:"v2"===n}},vt=()=>{var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{count:null!==(t={v0:10,v1:5,v2:8,v3:12}[null!==(e=(0,P.qt)(n,"search_yml_guess_count"))&&void 0!==e?e:"v0"])&&void 0!==t?t:10}},mt=()=>{var e;const{abTestVersion:t,user:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion","user"]),[])),i=null!==(e=(0,P.qt)(t,"use_navigation_refactor"))&&void 0!==e?e:"v0";return{showUpload:!("v5"===i&&!n),condenseProfileDropdown:"v5"===i}},gt=()=>{var e,t;const{abTestVersion:n,user:i}=(0,O.L$)((0,x.W)((()=>["abTestVersion","user"]),[])),o=!!i;return{enableUploadRefactor:"v1"===(null!==(e=(0,P.qt)(n,"enable_upload_refactor"))&&void 0!==e?e:"v0")&&o,enableMessageRefactor:"v1"===(null!==(t=(0,P.qt)(n,"enable_message_refactor"))&&void 0!==t?t:"v0")&&o}},ht=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"use_left_navigation_refactor"))&&void 0!==e?e:"v0";return{showNewLiveIcon:"v1"===n||"v3"===n,isCollapsibleFooter:"v2"===n||"v3"===n}},_t=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"video_detail_responsive_ui"))&&void 0!==e?e:"v0";return{responsiveUi:"v0"!==n,showUserInfo:"v2"===n}},ft=()=>{var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{showOnHot:"v0"!==(null!==(e=(0,P.qt)(n,"new_guest_mode_hot"))&&void 0!==e?e:"v0"),showOnRest:"v0"!==(null!==(t=(0,P.qt)(n,"new_guest_mode_other"))&&void 0!==t?t:"v0")}},yt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return null!==(e=(0,P.qt)(t,"webapp_explore_nav_order"))&&void 0!==e?e:"v0"},bt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return null!==(e=(0,P.qt)(t,"webapp_explore_video_info"))&&void 0!==e?e:"v0"},wt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"islands_arch_explore"))&&void 0!==e?e:"v0";return{delayAfterRender:"v1"===n,delayAfterVideoPlay:"v2"===n}},xt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{hasTrendingCard:"v1"===(null!==(e=(0,P.qt)(t,"explore_trending_topics"))&&void 0!==e?e:"v0")}},Tt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"video_resolution_auto"))&&void 0!==e?e:"v0",i=(0,r.Zo)();return{allowSelectResolution:"v0"!==n&&i,defaultAuto:"v1"===n,useStoredResolution:"v2"===n,shouldResetResolution:"v0"===n}},kt=()=>{var e;return"v0"!==(null!==(e=(0,P.d)("webapp_collection_profile"))&&void 0!==e?e:"v0")},St=()=>(0,b.useMemo)((()=>{return Object.assign({isCollectionEnabled:kt(),isAddToCollectionEnabled:"v0"!==(null!==(e=(0,P.d)("webapp_collection_adder"))&&void 0!==e?e:"v0"),popoverTriggerType:"bottomToast"},(()=>{var e;switch(null!==(e=(0,P.d)("webapp_collection_adder"))&&void 0!==e?e:"v0"){case"v2":return{toastTheme:"dark",toastDuration:5e3};case"v3":return{toastTheme:"dark",toastDuration:8e3};default:return{toastTheme:"default",toastDuration:3e3}}})());var e}),[]),Et=()=>(0,b.useMemo)((()=>{var e;const t=null!==(e=(0,P.d)("fyf_profile_uj"))&&void 0!==e?e:"v0";return{isFyfProfileUjEnabled:"v0"!==t,cacheRange:"v2"===t?"after":"v3"===t?"all":"one",shouldCacheIndex:"v3"===t}}),[]),At=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{shouldUseWebAppQueryCommentsPopover:"v1"===(null!==(e=(0,P.qt)(t,"webapp_query_comments_popover"))&&void 0!==e?e:"v0")}},Ot=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{showNewCommentDesign:"v0"!==(null!==(e=(0,P.qt)(t,"detail_page_comments_redesign"))&&void 0!==e?e:"v0")}},Pt=()=>{const{pathname:e}=(0,a.useLocation)(),{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=(0,P.qt)(t,"webapp_pc_apk");return n&&(0,h.tO)(e)?{shouldShowApkDownload:!0,link:n.link,version:n.version,scanText:n.scanText}:{shouldShowApkDownload:!1,link:"",version:""}},It=()=>{var e,t;const n=(0,o.wW)(),i=null!==(t=null===(e=null==n?void 0:n.parameters.seo_pc_traffic)||void 0===e?void 0:e.vid)&&void 0!==t?t:"v0",{isSearchEngineBot:a=!1}=(0,O.L$)((0,T.U)((()=>["isSearchEngineBot"]),[]));return{useInfoCard:["v1","v3"].includes(i)&&a,useHtmlTag:["v2","v3"].includes(i),useOnlineVersion:"v0"===i}},Ct=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"fyp_on_detail"))&&void 0!==e?e:"v0";return{fypOnDetail:"v1"===n||"v2"===n,endCardCloseShowNext:"v2"===n}},Lt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"grid_to_fyp"))&&void 0!==e?e:"v0";return{isInGridToFypExperiment:"v0"!==n,gridToFypVVCount:{v0:-1,v1:1,v2:2,v3:3,v4:5}[n]||-1}},jt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{inWebappFypCacheExperiment:"v1"===(null!==(e=(0,P.qt)(t,"webapp_fyp_cache"))&&void 0!==e?e:"v0")}},Mt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{hasNewShareMenu:"v0"!==(null!==(e=(0,P.qt)(t,"revamp_share_menu"))&&void 0!==e?e:"v0")}},Nt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return{isInAppStyleShareExperiment:"v0"!==(null!==(e=(0,P.qt)(t,"app_style_share"))&&void 0!==e?e:"v0")}},Dt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v0"!==(null!==(e=(0,P.qt)(t,"remove_disclaimer"))&&void 0!==e?e:"v0")},Rt=()=>{var e;const t=null!==(e=(0,P.d)("webapp_inapp_notice"))&&void 0!==e?e:"v0";return{isInAppNotificationEnabled:"v0"!==t,placement:"v1"===t||"v2"===t?"topEnd":"bottomEnd",layoutType:"v1"===t||"v3"===t?"withoutHeader":"withHeader"}},Bt=()=>{const{pathname:e,search:t}=(0,a.useLocation)();return(0,b.useMemo)((()=>{const n=Rt();return(0,h.Pz)(e,t)||(n.isInAppNotificationEnabled=!1),n}),[e,t])},Ut=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));if("v0"===(null!==(e=(0,P.qt)(t,"enable_language_expansion"))&&void 0!==e?e:"v0"))return!1;if("1"===(0,_._S)(S.Tz,"0"))return!1;(0,_.AP)(S.Tz,"1");const{pathname:n,query:i}=(0,p.xw)(),o=n.split("/")[1];if(o&&(0,s.x_)(o)&&l.d4.includes((0,s.Z0)(o)))return!1;const{lang:a,langCountry:r,language:c}=i,d=[r,a,c];for(const e of d)if(e&&(0,s.x_)(e)&&l.d4.includes((0,s.Z0)(e)))return!1;return!0},Ft=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"nav_phase_3"))&&void 0!==e?e:"v0",i="v0"!==n,o="v1"===(0,P.qt)(t,"enable_dm_side_nav"),r="v1"===(0,P.qt)(t,"enable_setting_side_nav"),s=[c.OZ.feedback,c.OZ.feedbackReport,c.OZ.feedbackHistory,c.OZ.upload,d.vI.kycSubmission,d.vI.kyc,d.vI.kycLoading,d.vI.kycPoa,u.tH.loginHome,u.tH.signupHome,c.OZ.download,...c.OZ.downloadWithLang,...o?[]:[c.OZ.messages],...r?[]:[c.OZ.setting,c.OZ.settingBlockList]],{pathname:l}=(0,a.useLocation)();return{vid:n,isInNavPhase3:i,showFullSideNav:!(0,a.matchPath)(l,{path:s,exact:!0})&&"v0"!==n}},Vt=()=>{var e,t,n;const{abTestVersion:i}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),o=null!==(e=(0,P.qt)(i,"feed_change_optimize_image"))&&void 0!==e?e:"v0",a=null!==(t=(0,P.qt)(i,"fyp_redesign"))&&void 0!==t?t:"v0",r=null!==(n=(0,P.qt)(i,"feed_change_optimize_ff"))&&void 0!==n?n:"v0",{isInProductHoldout:s}=rt();return{enableFeedChangeImageOptimize:"v1"===o,enableFeedChangeFirstFrameOptimize:"v1"===r&&!s&&"v1"===a}},zt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"enable_dm_side_nav"))&&void 0!==e?e:"v0",i=(0,E.Ig)();return"v0"!==n&&!i},Ht=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v0"!==(null!==(e=(0,P.qt)(t,"global_web_footer"))&&void 0!==e?e:"v0")},qt=()=>{var e,t;const{abTestVersion:n}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),{showLoading:i}=null!==(e=null==n?void 0:n.parameters.kep_click_opt_phase1)&&void 0!==e?e:{vid:"v0"},{waitTime:o}=null!==(t=null==n?void 0:n.parameters.kep_click_opt_phase2)&&void 0!==t?t:{vid:"v0"};return{showLoading:i,waitTime:o}},Gt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,P.qt)(t,"guest_mode_interest"))&&void 0!==e?e:"v0";return{showGuestModeInterestSelector:"v0"!==n,showContinueButton:"v2"!==n}},$t=()=>{const{abTestVersion:e}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),t=(0,g.S)(e,"redesign_login_popup");return{showLoginOptionSlider:"v3"===t||"v4"===t,showLoginOptionButton:"v1"===t||"v2"===t,showPopupWhenInitiallyLand:"v2"===t||"v4"===t,isInRedesignLoginPopupControl:"v0"===t,isInRedesignLoginPopupTreatment:void 0!==t&&"v0"!==t}},Wt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),{isAndroid:n}=(0,O.L$)((0,T.U)((()=>["isAndroid"]),[])),i=null!==(e=(0,P.qt)(t,"mobile_android_jump_optimization"))&&void 0!==e?e:"v0";return n?{experimentalUseAppLink:"v0"!==i,experimentalUseBetterAppLink:"v2"===i}:{}},Zt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v0"!==(null!==(e=(0,P.qt)(t,"video_auto_play_optimize"))&&void 0!==e?e:"v0")},Yt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v2"===(null!==(e=(0,P.qt)(t,"web_dm_group_chat"))&&void 0!==e?e:"v1")},Kt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[])),{isAndroid:n=!1}=null!==(e=(0,T.U)((()=>["isMobile","isAndroid"]),[]))&&void 0!==e?e:{},i=null==t?void 0:t.parameters.download_page_apk;return i?Object.assign(Object.assign({},i),{apps:i.apps.filter((e=>n?"android"===e.os||"both"===e.os:"ios"===e.os||"both"===e.os))}):i},Xt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"pns_communication_service_sdk"))&&void 0!==e?e:"v0")},Qt=()=>{var e;const t=null!==(e=(0,P.d)("side_nav_preload_cache"))&&void 0!==e?e:"v0";return{enableSideNavPreloadAndCache:"v4"===t,enableFYPSideNavPreloadAndCache:"v1"===t||"v2"===t||"v3"===t,cacheRange:"v1"===t?1:"v2"===t?2:0,cacheAfter:"v3"===t}},Jt=()=>{var e;const{abTestVersion:t}=(0,O.L$)((0,x.W)((()=>["abTestVersion"]),[]));return"v1"===(null!==(e=(0,P.qt)(t,"enable_creator_comments"))&&void 0!==e?e:"v0")},en=()=>(0,b.useMemo)((()=>{var e;return{isRefactorGroup:"v0"!==(null!==(e=(0,P.d)("page_init_refactor"))&&void 0!==e?e:"v0")}}),[])},45297:(e,t,n)=>{"use strict";n.d(t,{Ah:()=>R,BP:()=>w,DK:()=>s,F3:()=>u,HF:()=>M,Iw:()=>b,Kt:()=>a,LA:()=>E,Ly:()=>O,M2:()=>S,Nd:()=>U,Nj:()=>x,O_:()=>_,S0:()=>g,Tz:()=>h,Uw:()=>P,VD:()=>C,Z3:()=>l,_:()=>v,dj:()=>H,er:()=>D,fm:()=>d,gM:()=>m,iJ:()=>f,i_:()=>L,n9:()=>N,rd:()=>A,se:()=>z,sj:()=>p,tS:()=>j,v1:()=>o,vt:()=>r,vu:()=>I,xE:()=>k,xl:()=>y,z$:()=>T,z3:()=>c});var i=n(35248);const o="webapp-pwa-expanded",a="webapp-live-nav-click",r="webapp_showed_profile_tip",s="search_login",l="search_history_list",c="webapp_showed_explore_new_label",d="showed_desktop_app_download",u="time_of_last_prediction",p="timeOfLastPopup",v="pc_app_auto_tip",m="suggest_account_bind_last_show",g="last_watch_live_on_pc",h="new_language_notice",_="webapp_launch_mode",f="webapp_tiktok_open",y="webapp_tiktok_privious",b="webapp_open_edit_profile_modal_from",w="popup_profile_toast",x="watch_live_on_pc",T="Sorry, something wrong with the server, please try again.",k=1988,S=12,E=3e4,A=9,O=9,P=9,I=30,C=30,L="tiktok_webapp_feed_mode",j="tiktok_webapp_theme",M="tiktok_webapp_theme_manual",N="tiktok_webapp_theme_source",D="delay_guest_mode_vid",R={secure:!0,expires:300,domain:"www.tiktok.com"};var B;!function(e){e.DarkTheme="dark",e.LightTheme="light"}(B||(B={}));const U=i.$m.concat(["CH","US","GB"]),F="https://sf16-website-login.neutral.ttwstatic.com/obj/tiktok_web_login_static/",V="https://lf16-tiktok-web.tiktokcdn-us.com/obj/tiktok-web-tx/",z={ROW:{remScript:`${F}tiktok/static/nginx/rem-script.js`,slardarWeb:`${F}slardar/sdk-pre/browser.web.pre.js`,serviceWorker:`${F}tiktok/static/nginx/service-worker.js`},TTP:{remScript:`${V}tiktok/static/nginx/rem-script.js`,slardarWeb:"https://lf16-cdn-tos.tiktokcdn-us.com/obj/static-tx/tiktok-infra/csp/sdk-pre/slardar.web.pre.js",serviceWorker:`${V}tiktok/static/nginx/service-worker.js`}},H="swiper-no-swiping"},48211:(e,t,n)=>{"use strict";n.d(t,{Gu:()=>i,yH:()=>o});const i="tiktok_webapp",o="tiktok_webapp_login"},47888:(e,t,n)=>{"use strict";n.d(t,{Ao:()=>l,Pv:()=>s,bA:()=>d,dG:()=>c});var i=n(94999),o=n(93608),a=n(11654);const r=i.l.getInstance(a.V$);function s(e,t){o.f.event("feed_top_cache",{valid:e}),r.context({use_data_prefetched:e}),r.emitEvent("feed_top_cache",{count:1},{status:String(e),pageName:t})}function l(e,t){o.f.event("feed_top_cache_invalid",{check_count:e,invalid_count:t,allInvalid:t>=e?1:0}),r.emitEvent("feed_top_cache_invalid",{count:1},{checkCount:String(e),invalidCount:String(t),allInvalid:t>=e?"1":"0"})}function c(e){o.f.event("feed_fetch_error",{error_code:e})}function d(e){r.emitEvent("feed_cache_fetch",{count:1},{statusCode:String(e)})}},44349:(e,t,n)=>{"use strict";n.d(t,{n2:()=>i});const i="perf_feed_cache"},87715:(e,t,n)=>{"use strict";n.d(t,{Mc:()=>l,_1:()=>c});var i,o=n(88874),a=n(57431),r=n(71281);!function(e){e[e.CacheValid=0]="CacheValid",e[e.CacheExpired=1]="CacheExpired",e[e.NoCache=2]="NoCache",e[e.UserChange=3]="UserChange",e[e.CacheUpdateSuccess=4]="CacheUpdateSuccess",e[e.NoCacheWithUpdatedPush=8]="NoCacheWithUpdatedPush"}(i||(i={}));const s="webapp.updated-items";function l({itemList:e,cacheUid:t,uid:n,cacheWid:i,wid:l}){var c,d;let u=(0,o.YI)(s);const{abTestVersion:p}=(0,a.x)(),v=null!==(c=(0,r.V7)(p,"use_container_exp"))&&void 0!==c?c:"v0",m="v1"===v||"v3"===v;if(m&&(u=null!==(d=null==u?void 0:u.filter((e=>!e.imagePost)))&&void 0!==d?d:[]),!e||0===e.length)return u?{status:8,validItemList:u}:{status:2,validItemList:[]};if(!function({cacheUid:e,cacheWid:t,wid:n,uid:i}){return t===n&&(!e||e===i)}({cacheUid:t,cacheWid:i,wid:l,uid:n}))return{status:3,validItemList:[]};const g=e.filter((e=>{var t;const n=null===(t=e.video)||void 0===t?void 0:t.cover,i=/x-expires=(\d+)/.exec(n),o=i&&Date.now()<1e3*(Number(i[1])-60),a=m&&e.imagePost;return o&&!a}));return 0===g.length?u?{status:4,validItemList:u}:{status:1,validItemList:[]}:{status:0,validItemList:g}}function c(e){if(0===e.length)return 0;const t=e.map((e=>function(e){var t;const n=null===(t=e.video)||void 0===t?void 0:t.cover,i=/x-expires=(\d+)/.exec(n);return i?1e3*Number(i[1]):0}(e)));return Math.min(...t)}},20157:(e,t,n)=>{"use strict";n.d(t,{g9:()=>d,li:()=>c});var i=n(57432),o=n.n(i),a=n(40099),r=n(38259),s=n(58305);const l=(0,r.$)("ModalContext@tiktok/fe-shared")({counterRef:{current:0},scrollWidthRef:{current:0},subscribeRef:{current:[]},setCounter:o(),setScrollWidth:o(),subscribeModalChange:()=>o()});function c(){const e=(0,a.useRef)(0),t=(0,a.useRef)(0),n=(0,a.useRef)([]),i=(0,a.useCallback)((t=>{e.current=t}),[]),o=(0,a.useCallback)((e=>{t.current=e}),[]),r=(0,a.useCallback)((e=>(n.current.push(e),()=>{const t=n.current.indexOf(e);n.current.splice(t)})),[]),s=(0,a.useMemo)((()=>({counterRef:e,subscribeRef:n,scrollWidthRef:t,setCounter:i,setScrollWidth:o,subscribeModalChange:r})),[r,i,o]);return{GlobalModalProvider:l.Provider,value:s}}function d(){const{counterRef:e,setCounter:t,setScrollWidth:n,subscribeRef:i,scrollWidthRef:o,subscribeModalChange:r}=(0,a.useContext)(l),c=(0,a.useCallback)((e=>{i.current.forEach((t=>{t({hasModal:e,scrollWidth:o.current})}))}),[o,i]);return{showModal:(0,a.useCallback)(((i,o)=>{if(!(0,s.Lm)()&&!i||o)return;const{current:a}=e;if(t(a+1),0===a){const e=(0,s.aP)();n(e),document.body.style.paddingRight=`${e}px`,document.body.className+=" hidden",c(!0)}}),[e,c,t,n]),hideModal:(0,a.useCallback)((()=>{const{current:i}=e,o=Math.max(0,i-1);t(o),0===o&&(n(0),document.body.className=document.body.className.replace(/\s?hidden/g,""),document.body.style.paddingRight="0px",c(!1))}),[e,c,t,n]),subscribeModalChange:r}}},45212:(e,t,n)=>{"use strict";n.d(t,{id:()=>s,qo:()=>r});var i=n(57431),o=n(36272),a=n(92651);const r=()=>{var e,t,n,r;const{abTestVersion:s}=(0,i.x)(),l=null!==(n=null===(t=null===(e=null==s?void 0:s.parameters)||void 0===e?void 0:e.ff_avg_duration_portrait)||void 0===t?void 0:t.vid)&&void 0!==n?n:{vid:"v0"},c="v0"!==(null!==(r=null==l?void 0:l.vid)&&void 0!==r?r:"v0"),d="undefined"!=typeof navigator?null===navigator||void 0===navigator?void 0:navigator.hardwareConcurrency:4,u=(0,o.BX)((e=>{var t;return(null===(t=e.ff_duration_avg)||void 0===t?void 0:t.target)===a.L.Low}));return{isLowEndDevice:c&&(u||d<4)}},s=()=>{var e,t,n,o,a;const{abTestVersion:r}=(0,i.x)(),s=null!==(n=null===(t=null===(e=null==r?void 0:r.parameters)||void 0===e?void 0:e.vv_avg_per_day_portrait)||void 0===t?void 0:t.vid)&&void 0!==n?n:{vid:"v0"},l=null===(o=null==r?void 0:r.parameters.change_list_length_new)||void 0===o?void 0:o.vid;return{enableVVAvgPerDayStrategy:"v0"!==(null!==(a=null==s?void 0:s.vid)&&void 0!==a?a:"v0"),defaultRecommendFetchCount:Number(l)}}},4712:(e,t,n)=>{"use strict";n.d(t,{A5:()=>p,M2:()=>u,Zy:()=>d,zW:()=>c});var i=n(41271),o=n(52333),a=n(97071),r=n(8046),s=n(29909),l=n(32125);const c=e=>{var t;if(!e)return;const n=null!==(t=e.log_extra)&&void 0!==t?t:"";try{const e=JSON.parse(n);return{charge_type:e.charge_type,req_id:e.req_id,system_origin:e.system_origin}}catch(e){return}},d=({adInfo:e,refer:t,tag:n})=>{if(!e.web_url)return;const{web_url:i}=e,o=(0,a.n5)({ad_info:e,play_mode:"one_column"});window.open(i,"_blank"),r.pg.handleRealtimeClick(Object.assign(Object.assign({},o),{refer:t,tag:n}))},u=(e,t)=>{var n,a;const r=(0,s.Lu)((e=>null==e?void 0:e.list),l.bN),c=(0,i.P)(o.k,{selector:e=>e,dependencies:[e,t]});if(!(null===(n=c[e])||void 0===n?void 0:n.ad_info)||!r||t>=r.length)return 0;for(let e=t-1;e>=0;e--)if(null===(a=c[r[e]])||void 0===a?void 0:a.ad_info)return t-e;return 0},p=e=>{var t,n;const a=(0,s.Lu)((e=>null==e?void 0:e.list),l.bN),r=(0,i.P)(o.k,{selector:e=>e,dependencies:[e]});if(!(null===(t=r[e])||void 0===t?void 0:t.ad_info)||!a)return 0;for(let e=0;e<=a.length;e++)if(null===(n=r[a[e]])||void 0===n?void 0:n.ad_info)return e+1;return 0}},34012:(e,t,n)=>{"use strict";n.d(t,{Ig:()=>l,XJ:()=>c,_Y:()=>d});var i=n(47172),o=n(82715),a=n(7089),r=n(32125),s=n(5441);const l=()=>{const{search:e}=(0,i.useLocation)();return"business"===new URLSearchParams(e).get("scene")},c=()=>{const{search:e}=(0,i.useLocation)();return"true"===new URLSearchParams(e).get("allow_label")},d=e=>{const t=(0,a.VR)((e=>e.businessPermission),r.bN),{isElectronApp:n}=(0,s.B)();return{path:t.message?`/business-suite/messages?from=homepage&lang=${e}`:`${o.OZ.messages}?lang=${e}`,target:n&&t.message?"_blank":void 0}}},61730:(e,t,n)=>{"use strict";n.d(t,{P:()=>f});var i=n(58632),o=n(40099),a=n(47172),r=n(49057),s=n(60484),l=n(71281),c=n(96689),d=n(34871),u=n(58305),p=n(95868),v=n(45297),m=n(26956),g=n(92264),h=n(33063),_=n(16680);function f(e={}){const t=(0,s.L$)((0,r.W)((()=>["user","wid","abTestVersion","webIdCreatedTime"]),[])),{user:n,abTestVersion:f,webIdCreatedTime:y}=t,b=(0,l.qt)(f,"webapp_login_prediction_full"),w=(0,l.qt)(f,"webapp_login_prediction_reverse"),x=(0,l.qt)(f,"webapp_login_causal_inference_validation"),{pathname:T}=(0,a.useLocation)(),k=(0,d.mv)(y),S=b||w,E=!!x&&"v1"!==x,{getPriorityPopup:A}=(0,h._y)(),{popupPriority:O}=(0,h.lz)((e=>({popupPriority:e.priority,isReady:e.isReadyList[3]}))),{handlePopoverInitial:P,handlePopoverEnd:I}=(0,o.useMemo)((()=>A(3)),[A]),C=()=>{var t;null===(t=e.closeCallback)||void 0===t||t.call(e),I()},L=(0,c.G)({modalConfig:Object.assign(Object.assign({closeable:!1,isGuestMode:!1,query:{enter_method:"model_based"}},e),{closeCallback:C})}),j=(0,c.G)({modalConfig:Object.assign(Object.assign({query:{enter_method:"guest_mode"},isGuestMode:!1,isGuestModeUI:!0},e),{closeCallback:C})}),M=(0,_.b1)(),N=(0,o.useCallback)(((e,t,o)=>(0,i.__awaiter)(this,void 0,void 0,(function*(){if(n)return;void 0!==t&&-1>=t&&(0,d.CE)(o)&&3===O&&((0,u.AP)(v.sj,Date.now().toString()),j(),P()),M.setCheckPredictionLogin({showLoginOnLoad:Boolean(!1)})}))),[n,S,E,x,O,M,L,P,j]);return{loginPredictionHandler:(0,o.useCallback)((()=>{const e=(0,u.Hd)(v.iJ),t=(0,d.Vw)(k,e),i=[{expId:"webapp_login_prediction_full",segmentId:t,versionId:b,propertyList:["prediction_threshold"]},{expId:"webapp_login_prediction_reverse",segmentId:t,versionId:w,propertyList:["prediction_threshold"]}],{prediction_threshold:o,guest_mode_threshold:a,popup_interval:r}=(0,m.J)(g.a,i);n||void 0===o&&void 0===a&&!x?M.setCheckPredictionLogin({showLoginOnLoad:!1}):!(0,d.oX)("app_load","","")||(0,p.mQ)(T)||(0,p.FJ)(T)||N(o,a,r)}),[k,b,w,n,x,T,N,M])}}},34871:(e,t,n)=>{"use strict";n.d(t,{CE:()=>d,Vw:()=>c,mv:()=>l,oX:()=>s});var i=n(58305),o=n(45297),a=n(70322);const r=["homepage_hot","others_homepage"],s=(e,t="",n="")=>{const r=(0,i._S)(o.F3);return!r||Date.now()-parseInt(r,10)>=1e3?((0,i.AP)(o.F3,Date.now().toString()),!0):(a.w.handleInferenceDisqualify({enter_method:e,model_name:t,reason:"api_rate_control",page_name:n}),!1)},l=(e=0)=>{const t=(0,i._S)("old_user_ppe_test");return"1"!==t&&("0"===t||Date.now()/1e3-(e||0)<86400)},c=(e=!0,t="")=>e?"segment_1":(r.includes(t),"segment_default"),d=(e=6e4)=>{const t=(0,i._S)(o.sj);return!t||Date.now()-parseInt(t,10)>=e}},92264:(e,t,n)=>{"use strict";n.d(t,{a:()=>i});const i={online:{segment_default:{v1:[{name:"popup_interval",value:432e5,priority:0}]}},webapp_mobile_web2app_cta_guide:{segment_default:{v1:[{name:"prediction_threshold",value:.001,priority:1}],v2:[{name:"prediction_threshold",value:.009,priority:1}],v3:[{name:"prediction_threshold",value:.03,priority:1}],v4:[{name:"prediction_threshold",value:.07,priority:1}]}},webapp_login_prediction:{segment_default:{v2:[{name:"prediction_threshold",value:.602572,priority:1},{name:"popup_interval",value:-1,priority:1}],v3:[{name:"prediction_threshold",value:.261145,priority:1},{name:"popup_interval",value:-1,priority:1}],v4:[{name:"prediction_threshold",value:.114536,priority:1},{name:"popup_interval",value:-1,priority:1}],v5:[{name:"prediction_threshold",value:.067758,priority:1},{name:"popup_interval",value:-1,priority:1}],v6:[{name:"prediction_threshold",value:.031474,priority:1},{name:"popup_interval",value:-1,priority:1}],v7:[{name:"prediction_threshold",value:.018922,priority:1},{name:"popup_interval",value:-1,priority:1}],v8:[{name:"prediction_threshold",value:.012345,priority:1},{name:"popup_interval",value:-1,priority:1}],v9:[{name:"prediction_threshold",value:.008136,priority:1},{name:"popup_interval",value:-1,priority:1}]}},webapp_causal_inference_periodic_popup_validation:{segment_default:{v1:[{name:"popup_interval",value:432e5,priority:1}],v2:[{name:"popup_interval",value:36e5,priority:1}],v3:[{name:"popup_interval",value:36e5,priority:1}],v4:[{name:"popup_interval",value:36e5,priority:1}],v5:[{name:"popup_interval",value:432e5,priority:1}],v6:[{name:"popup_interval",value:432e5,priority:1}],v7:[{name:"popup_interval",value:432e5,priority:1}]}},webapp_login_prediction_full:{segment_1:{v1:[{name:"prediction_threshold",value:.012345,priority:1},{name:"popup_interval",value:-1,priority:1}],v2:[{name:"prediction_threshold",value:.012345,priority:1},{name:"popup_interval",value:-1,priority:1}]},segment_2:{v1:[{name:"prediction_threshold",value:.114536,priority:1},{name:"popup_interval",value:-1,priority:1}],v2:[{name:"prediction_threshold",value:.114536,priority:1},{name:"popup_interval",value:-1,priority:1}]}},webapp_login_prediction_reverse:{segment_1:{v1:[{name:"prediction_threshold",value:.012345,priority:1},{name:"popup_interval",value:-1,priority:1}]},segment_2:{v1:[{name:"prediction_threshold",value:.114536,priority:1},{name:"popup_interval",value:-1,priority:1}]}},webapp_guest_mode:{segment_default:{v2:[{name:"cta_style",value:"default",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!1,priority:0}],v3:[{name:"cta_style",value:"default",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!0,priority:0}],v4:[{name:"cta_style",value:"default",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!1}],v5:[{name:"cta_style",value:"default",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!0}],v6:[{name:"cta_style",value:"line",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!1,priority:0}],v7:[{name:"cta_style",value:"line",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!0,priority:0}],v8:[{name:"cta_style",value:"line",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!1}],v9:[{name:"cta_style",value:"line",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!0}],v10:[{name:"cta_style",value:"primary",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!1,priority:0}],v11:[{name:"cta_style",value:"primary",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!0,priority:0}],v12:[{name:"cta_style",value:"primary",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!1}],v13:[{name:"cta_style",value:"primary",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!0}],v14:[{name:"cta_style",value:"text",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!1,priority:0}],v15:[{name:"cta_style",value:"text",priority:0},{name:"login_text",value:"pcWeb_guestLogin_without",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_withoutSignup",priority:0},{name:"close_icon",value:!0,priority:0}],v16:[{name:"cta_style",value:"text",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!1}],v17:[{name:"cta_style",value:"text",priority:0},{name:"login_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"signup_text",value:"pcWeb_guestLogin_guest",priority:0},{name:"close_icon",value:!0}]}},mobile_predictive_data:{segment_default:{v0:[{name:"vv_count",value:-1,priority:0}],v1:[{name:"vv_count",value:3,priority:0}],v2:[{name:"vv_count",value:4,priority:0}],v3:[{name:"vv_count",value:5,priority:0}],v4:[{name:"vv_count",value:6,priority:0}],v5:[{name:"vv_count",value:7,priority:0}],v6:[{name:"vv_count",value:8,priority:0}],v7:[{name:"vv_count",value:9,priority:0}],v8:[{name:"vv_count",value:10,priority:0}],v9:[{name:"vv_count",value:11,priority:0}],v10:[{name:"vv_count",value:12,priority:0}],v11:[{name:"vv_count",value:13,priority:0}],v12:[{name:"vv_count",value:14,priority:0}],v13:[{name:"vv_count",value:15,priority:0}],v14:[{name:"vv_count",value:16,priority:0}],v15:[{name:"vv_count",value:17,priority:0}],v16:[{name:"vv_count",value:18,priority:0}],v17:[{name:"vv_count",value:19,priority:0}],v18:[{name:"vv_count",value:20,priority:0}],v19:[{name:"vv_count",value:21,priority:0}],v20:[{name:"vv_count",value:22,priority:0}],v21:[{name:"vv_count",value:23,priority:0}],v22:[{name:"vv_count",value:24,priority:0}],v23:[{name:"vv_count",value:25,priority:0}],v24:[{name:"vv_count",value:26,priority:0}],v25:[{name:"vv_count",value:27,priority:0}],v26:[{name:"vv_count",value:28,priority:0}],v27:[{name:"vv_count",value:29,priority:0}],v28:[{name:"vv_count",value:30,priority:0}],v29:[{name:"vv_count",value:31,priority:0}]}}}},26956:(e,t,n)=>{"use strict";function i(e,t){const n={},i=function(e){const t=e.reduce(((e,t)=>{const{expId:n,segmentId:i,versionId:o,propertyList:a}=t;return n&&i&&o?(a.forEach((t=>{const a={expId:n,segmentId:i,versionId:o,propertyName:t};e[t]=e[t]||[],e[t].push(a)})),e):e}),{});return t}(t);for(const[t,a]of Object.entries(i)){const i=o(e,a);n[t]=i}return n}function o(e,t){const n=t.map((t=>function(e,{expId:t,segmentId:n,versionId:i,propertyName:o}){const a=e[t];if(!a)return void console.error(`Error. Experiment: ${t} not found!`);const r=a[n];if(!r)return;if(!i)return;const s=r[i];return s?s.find((e=>e.name===o)):void 0}(e,t))).filter((e=>void 0!==e));if(0!==n.length)return n.reduce(((e,t)=>t.priority>e.priority?t:e)).value}n.d(t,{J:()=>i})},23721:(e,t,n)=>{"use strict";n.d(t,{HZ:()=>l,dg:()=>r,ug:()=>a}),n(24643);var i=n(38259),o=(n(44471),n(88062));(0,i.$)("SlardarControlContext@tiktok/fe-shared")(!1);const a=(0,i.$)("InlineSlardarConfigContext@tiktok/fe-shared")({enable:!0}),r={plugins:{ajax:{ignoreUrls:[".byteoversea.com",/mcs.*\.tiktok[vw]?\.(com|us|eu)/,".tiktokcdn.com",".tiktokcdn-us.com","mon.tiktokv.(com|us|eu)","ttwid/check","passport/token/beat/web",/.*-webapp-prime\.(.*\.)?tiktok\.com/]},fetch:{ignoreUrls:[".tiktokcdn.com",".tiktokcdn-us.com","mon.tiktokv.(com|us|eu)","policy/notice","feedback/v1/newest_reply","ba/business/suite/permission/list",/.*-webapp-prime\.(.*\.)?tiktok\.com/]},jsError:{ignoreErrors:["Blocked a frame with origin","__msg_type","vid_mate_check is not defined","ResizeObserver loop limit exceeded",'Video playback error: {"errorCode":',"Object Not Found Matching Id","The play method is not allowed by the user agent","The play() request was interrupted","Failed to load because no supported source was found","The request is not allowed by the user agent or the platform in the current context","Fetch is aborted","The operation was aborted"]},resource:{slowSessionThreshold:1e5},fmp:!1,tti:!1,pageview:{sendInit:!0,routeMode:"manual"}},sample:{sample_rate:1,sample_granularity:"session",include_users:[],rules:{resource:{enable:!0,sample_rate:.01,conditional_sample_rules:[]},resource_error:{enable:!0,sample_rate:.05,conditional_sample_rules:[]},performance_longtask:{enable:!0,sample_rate:.001,conditional_sample_rules:[]}}},env:"production",release:"1.0.2.6172",slardarClient:"SlardarClient",manual:1,sdkUrl:o.Qn.row,pluginPathPrefix:o.tz.row};var s;!function(e){e.P0="fatal",e.P1="error",e.P2="warning",e.P3="info",e.P4="debug",e.P5="critical"}(s||(s={}));const l=["lcp","fp","fid","ttfb","mpfid","fcp","actual_fmp"];var c;!function(e){e.TTAPPluginInfo="ttapplugin_info",e.TTAPPluginFirstScreenRequest="ttapplugin_first_screen_request",e.TTAPPluginEffectiveOpenPage="ttapplugin_effective_open_page",e.TTAPPluginCustomRequest="ttapplugin_custom_request",e.actualFMP="actual_fmp",e.LoginClickToNotifyDuration="login_click_to_notify_duration"}(c||(c={}))},72277:(e,t,n)=>{"use strict";n.d(t,{s:()=>i});const i=["live_im_sdk_socket_link","live_edenx_runtime","live_www_host","live_starling_optimize","live_chat_refactor_phase1","fyp_live_card_open_direct","live_non_logged_in_time_restriction_pc","live_disable_header_skeleton","image_fetch_priority","user_bundle_opt","sharing_video_first","live_recharge_login_sdk","page_loading_tiny_changes","react_upgrade_experiment","kep_streaming","web_dm_icon_click_check","web_dm_quote_message","web_dm_list_load_optimize","web_dm_combo","user_ssg","organic_video_streaming","mobile_micro_frontends"]},11654:(e,t,n)=>{"use strict";n.d(t,{V$:()=>k,Yr:()=>S});var i=n(58632),o=n(67134),a=n(7672),r=n(14285),s=n(94999),l=n(3452),c=n.n(l),d=n(93608),u=n(48211),p=n(23721),v=n(89023),m=n(97086),g=n(91498),h=n(88062),_=n(14974),f=n.n(_),y=n(71784),b=n.n(y),w=n(72277);const x=({message:e,defaultResult:t}={})=>(n,i,o)=>{const a=o.value;return o.value=function(...o){try{const s=a.apply(this,o);return(r=s)&&r instanceof Promise||("object"==typeof r||"function"==typeof r)&&"function"==typeof r.then&&"function"==typeof r.catch?s.catch((o=>(console.error(`${n.constructor.name}.${i.toString()}${e?` ${e}`:""}: ${o}`),t))):s}catch(o){return console.error(`${n.constructor.name}.${i.toString()}${e?` ${e}`:""}: ${o}`),t}var r},o};var T=n(73580);(0,m.fU)()||v.O.setGlobalSlardarName("SlardarClient");let k=class{constructor(){this.cachePreBid="",this._isPvFirstlyReported=!1,this._config=null,this._extraInfo=null,this._hasStart=!1,this._slardar=v.O}hasStarted(){return this._hasStart}mountBeforeSendEvent(){this._slardar.on("beforeSend",(e=>{var t,n,i,o,a,r;try{if("performance"===e.ev_type&&("metrics"in e.payload?e.payload.metrics.forEach(this.collectSlardarMetricsToTea):this.collectSlardarMetricsToTea(e.payload,null===(t=e.common)||void 0===t?void 0:t.pid)),"performance_timing"===e.ev_type){const{responseEnd:t,responseStart:a,domContentLoadedEventEnd:r,fetchStart:s,navigationStart:l}=null!==(n=e.payload.timing)&&void 0!==n?n:{},c=null!==(o=null===(i=e.payload.common)||void 0===i?void 0:i.pid)&&void 0!==o?o:"unknown",u=r-s,p=t-a,v=a-l;d.f.event("slardar_perf_domready",{metric_duration:u&&u>0?u.toString():-1,pid:c}),d.f.event("slardar_perf_response",{metric_duration:p&&p>0?p.toString():-1,pid:c}),d.f.event("slardar_perf_ttfb",{metric_duration:v&&v>0?v.toString():-1,pid:c})}if("custom"===e.ev_type&&"video_play_end"===(null===(a=e.payload)||void 0===a?void 0:a.name)){const{idc:t}=null!==(r=e.common.context)&&void 0!==r?r:{};e.common.context=t?{idc:t}:{}}}catch(e){}return e}))}init(e,t=!1,n={},i){this._option=i,t?this.preserveConfig(e):this._slardar.init(Object.assign({ttap:Object.assign({},n)},e))}start(e=""){this._config&&e&&!this._hasStart&&(this.init(Object.assign(Object.assign({},this._config),{pid:e})),this._hasStart=!0,this._extraInfo&&this.config(this._extraInfo)),this._slardar.start()}config(e){"pid"in e&&!this._isPvFirstlyReported&&(this._isPvFirstlyReported=!0,this.context({isLandingPage:0})),this._slardar.config(e)}registerImageXPlugin(e,t=.01){return e?[c().imageReport({debug:!1,sample_rate:t})]:[]}toggleLoginSlardar(e){var t,n;(null===(t=this._option)||void 0===t?void 0:t.disableToggleLoginSlardar)||(e?((null===(n=this._slardar.config())||void 0===n?void 0:n.bid)&&(this.cachePreBid=this._slardar.config().bid),this.config({bid:u.yH})):this.config({bid:this.cachePreBid}))}context(e){Object.entries(e).forEach((([e,t])=>{this._slardar.context({[e]:t})}))}captureMessage(e="",t,n={}){this._slardar.captureException("string"==typeof e?new Error(e):e,t?Object.assign(Object.assign({},n),{level:t}):n)}emitEvent(e,t,n){this._slardar.sendEvent({name:e,categories:n,metrics:t})}reportI18nLoadedFailed(e,t){this.emitEvent("I18nLoadFailed",{count:1},{staringName:e,lang:t})}sendLog(e,t,n){this._slardar.sendLog({content:e,level:t,extra:n})}sendPV(e){this._slardar.rawInstance()("sendPageview",e)}previousPid(){var e;return null===(e=this._slardar.config())||void 0===e?void 0:e.pid}sendCustomPerfMetric(e,t){const n=null!=t?t:performance.now();this._slardar.sendCustomPerfMetric({name:e,value:n,isCustom:!0})}preserveConfig(e){this._config=e}preserveExtraInfo(e){this._extraInfo=e}collectSlardarMetricsToTea(e,t){if(e.isSupport||e.isPolyfill){const n=e.name.toLowerCase();p.HZ.includes(n)&&d.f.event(`slardar_perf_${n}`,{metric_duration:e.value.toString(),pid:null!=t?t:"unknown",is_support:e.isSupport?"1":"0"})}}reportActualFMP(){return this._slardar.reportActualFMP()}reportRenderStart(){return this._slardar.reportRenderStart()}reportRenderEnd(){return this._slardar.reportRenderEnd()}reportFirstScreenRequest(e,t){this._slardar.reportFirstScreenRequest(e,t)}reportCustomRequest({name:e,startTime:t,endTime:n}){var i;const o=(null===(i=null===performance||void 0===performance?void 0:performance.timing)||void 0===i?void 0:i.navigationStart)||(null===performance||void 0===performance?void 0:performance.timeOrigin);this._slardar.reportCustomRequest(e,null!=t?t:o,n)}reportPageReady(){this._slardar.reportPageReady()}reportPageCrash({errorMsg:e}){this._slardar.reportPageCrash({errorMsg:e})}reportStabilityEvent(e){this._slardar.reportStabilityEvent(e)}reportStabilityStack(e){this._slardar.reportStabilityStack(e)}reportRouteRenderStart(){this._slardar.reportRouteRenderStart()}reportRouteRenderEnd(){this._slardar.reportRouteRenderEnd()}};k.start=(e,{bid:t,initLocation:n,appContext:i,bizContext:o,reportImage:a,slardarConfig:r={},ttapOption:s={},disableToggleLoginSlardar:l=!1,extractPid:c=e=>e,customContext:d,beforeStart:u,customMountBeforeSendEvent:v})=>{var _,y,x,T;const{abTestVersion:k,env:S,botType:E,user:A,wid:O,region:P}=null!=i?i:{},{isMobile:I,isTTP:C,domains:L,idc:j,config:M}=null!=o?o:{},N=!!a||"v2"===(null===(_=null==k?void 0:k.parameters.enable_slardar_image)||void 0===_?void 0:_.vid),D=e=>{const t=c(e);return"delay_start_until_manually_called"===t?"unknown":t};return e.context(Object.assign(Object.assign(Object.assign({region:null!=P?P:"",botType:null!=E?E:"",isMobile:Boolean(I).toString(),isDowngrade:(0,m.qk)().toString(),isLogin:Boolean(A).toString(),isPPE:"ppe"===(null==S?void 0:S.type),isLandingPage:1,isSSGPage:(0,m.$y)(),launchMode:(0,m.fU)()?"":(0,g.o7)()},b()(f()(null!==(y=null==k?void 0:k.parameters)&&void 0!==y?y:{},(e=>null==e?void 0:e.vid)),((e,t)=>w.s.includes(t)))),{uid:null!==(x=null==A?void 0:A.uid)&&void 0!==x?x:"",idc:null!=j?j:"unknown"}),d)),e.mountBeforeSendEvent(),null==v||v(e._slardar),e.init(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},p.dg),{bid:t,env:"boe"===(null==S?void 0:S.type)||"ppe"===(null==S?void 0:S.type)?"test":"production",domain:(null===(T=null==M?void 0:M.featureFlags)||void 0===T?void 0:T.slardar_sg_domain)&&"SG"===P?"mon-sg.tiktokv.com":null==L?void 0:L.slardar,useLocalConfig:"ppe"===(null==S?void 0:S.type)||"boe"===(null==S?void 0:S.type),integrations:[...e.registerImageXPlugin(N,a&&"boolean"!=typeof a?a.sample:void 0)]}),C?{sdkUrl:h.Qn.us,pluginPathPrefix:h.tz.us}:{}),{pid:D("string"==typeof n?n:n.pathname),userId:O}),r),!1,Object.assign({isSpa:!0},s),{disableToggleLoginSlardar:l}),"function"==typeof u?u().finally((()=>{e.start()})).catch((e=>{console.error("beforeStart failed",e)})):e.start(),{handleLocationChange:t=>{const n=D("string"==typeof t?t:t.pathname);e.context({isLandingPage:0}),e.sendPV(n)},slardar:e}},(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"mountBeforeSendEvent",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object,Object,Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"init",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[String]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"start",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"config",null),(0,i.__decorate)([x({defaultResult:[]}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Boolean,Object]),(0,i.__metadata)("design:returntype",Object)],k.prototype,"registerImageXPlugin",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Boolean]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"toggleLoginSlardar",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"context",null),(0,i.__decorate)([x({message:"capture exception error"}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String,Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"captureMessage",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[String,Object,Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"emitEvent",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[String,String]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportI18nLoadedFailed",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[String,String,Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"sendLog",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[String]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"sendPV",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"previousPid",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[String,Number]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"sendCustomPerfMetric",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"preserveConfig",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"preserveExtraInfo",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"collectSlardarMetricsToTea",null),(0,i.__decorate)([x({defaultResult:0}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",Number)],k.prototype,"reportActualFMP",null),(0,i.__decorate)([x({defaultResult:0}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",Number)],k.prototype,"reportRenderStart",null),(0,i.__decorate)([x({defaultResult:0}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",Number)],k.prototype,"reportRenderEnd",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Number,Number]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportFirstScreenRequest",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportCustomRequest",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportPageReady",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportPageCrash",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportStabilityEvent",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportStabilityStack",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportRouteRenderStart",null),(0,i.__decorate)([x(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[]),(0,i.__metadata)("design:returntype",void 0)],k.prototype,"reportRouteRenderEnd",null),k=(0,i.__decorate)([(0,a._)()],k);const S=e=>{const t=`createIsolatedSlardarService_${e}@tiktok/fe-shared`,n=(0,o.U)(t,(()=>new r.n(e)));s.l.addProvider({provide:n,useClass:k});const l={provide:n,useExisting:n};let c,d=class extends k{constructor(){super(),this._slardar=v.O.create(e)}reportActualFMP(){return 0}reportFirstScreenRequest(){}reportRenderEnd(){return 0}reportRenderStart(){return 0}reportCustomRequest(){}reportRouteRenderEnd(){}reportRouteRenderStart(){}};return d=(0,i.__decorate)([(0,a._)(),(0,i.__metadata)("design:paramtypes",[])],d),{inject:(e=d)=>{s.l.addProvider({provide:n,useClass:e})},getInstance:()=>s.l.getInstance(l),useInstance:()=>(0,T.Nj)(l),isIsolated:()=>s.l.getInstance(l)instanceof d,start:e=>{var t;const n=s.l.getInstance(l);if(n instanceof d)return c?c.handleLocationChange(e.initLocation):void(c=k.start(n,Object.assign(Object.assign({},e),{slardarConfig:Object.assign(Object.assign({},e.slardarConfig),{plugins:Object.assign(Object.assign(Object.assign({},p.dg.plugins),{performance:!1}),null===(t=e.slardarConfig)||void 0===t?void 0:t.plugins)})})))},handleLocationChange:e=>{null==c||c.handleLocationChange(e)},INJECTION_TOKEN:n}};s.l.getInstance(k)},31960:(e,t,n)=>{"use strict";n.d(t,{TJ:()=>w});var i=n(58632),o=n(33518);function a(e){if(!(null==e?void 0:e.geometry)||!(null==e?void 0:e.text))return e;const t=(0,o.SX)(e.geometry),n=(0,o.SX)(e.text);return Object.assign(Object.assign({},e),{text:n,geometry:t})}function r(){if("undefined"==typeof document)return null;const e=document.createElement("canvas");return e.width=256,e.height=128,e.getContext("webgl",{preserveDrawingBuffer:!0})}function s(){var e,t,n,i;const a={value:"",duration:0},s=r(),l=null===(e=null==s?void 0:s.createBuffer)||void 0===e?void 0:e.call(s),c=null===(t=null==s?void 0:s.createProgram)||void 0===t?void 0:t.call(s),d=null===(n=null==s?void 0:s.createShader)||void 0===n?void 0:n.call(s,s.VERTEX_SHADER),u=null===(i=null==s?void 0:s.createShader)||void 0===i?void 0:i.call(s,s.FRAGMENT_SHADER);if(s&&l&&c&&d&&u&&"undefined"!=typeof Uint8Array){let e="";try{s.bindBuffer(s.ARRAY_BUFFER,l),s.bufferData(s.ARRAY_BUFFER,new Float32Array([-.2,-.9,0,.4,-.26,0,0,.7321,0]),s.STATIC_DRAW);const t=3,n=3;s.shaderSource(d,"attribute vec2 attrVertex;varying vec2 varyinTexCoordinate;uniform vec2 uniformOffset;void main(){varyinTexCoordinate=attrVertex+uniformOffset;gl_Position=vec4(attrVertex,0,1);}"),s.compileShader(d),s.shaderSource(u,"precision mediump float;varying vec2 varyinTexCoordinate;void main() {gl_FragColor=vec4(varyinTexCoordinate,0,1);}"),s.compileShader(u),s.attachShader(c,d),s.attachShader(c,u),s.linkProgram(c),s.useProgram(c);const i=s.getAttribLocation(c,"attrVertex"),a=s.getUniformLocation(c,"uniformOffset");s.enableVertexAttribArray(i),s.vertexAttribPointer(i,t,s.FLOAT,!1,0,0),s.uniform2f(a,1,1),s.drawArrays(s.TRIANGLE_STRIP,0,n);const r=new Uint8Array(131072);s.readPixels(0,0,256,128,s.RGBA,s.UNSIGNED_BYTE,r);const p=JSON.stringify(r).replace(/,?"[0-9]+":/g,"").replace(/^{[0]+}$/g,"");e=(0,o.SX)(p)}catch(e){}a.value=e}return a}function l(){var e;return(0,i.__awaiter)(this,void 0,void 0,(function*(){const t={value:"",duration:0};try{if("undefined"!=typeof navigator&&(null===navigator||void 0===navigator?void 0:navigator.userAgentData)&&(null===(e=navigator.userAgentData)||void 0===e?void 0:e.getHighEntropyValues)){const e=yield navigator.userAgentData.getHighEntropyValues(["architecture","bitness","platform","platformVersion","uaFullVersion","fullVersionList"]);t.value=JSON.stringify(e)}}catch(e){t.value=""}return t}))}function c(){const e={value:"",duration:0};return"undefined"!=typeof navigator&&(null===navigator||void 0===navigator?void 0:navigator.userAgent)&&(e.value=navigator.userAgent),e}function d(){var e;return{value:null!==(e=null===window||void 0===window?void 0:window.devicePixelRatio)&&void 0!==e?e:1,duration:0}}function u(){const e={value:!1,duration:0};return"undefined"!=typeof navigator&&(null===navigator||void 0===navigator?void 0:navigator.pdfViewerEnabled)&&(e.value=navigator.pdfViewerEnabled),e}function p(){const e={value:0,duration:0};try{const{AudioContext:t}=window;if(t){const n=new t;e.value=n.sampleRate}}catch(t){e.value=0}return e}function v(){var e;const t={value:"",duration:0};try{const n=r(),i=null===(e=null==n?void 0:n.getExtension)||void 0===e?void 0:e.call(n,"WEBGL_debug_renderer_info");n&&i&&(t.value=n.getParameter(i.UNMASKED_VENDOR_WEBGL))}catch(e){t.value=""}return t}function m(){var e;const t={value:"",duration:0};try{const n=r(),i=null===(e=null==n?void 0:n.getExtension)||void 0===e?void 0:e.call(n,"WEBGL_debug_renderer_info");n&&i&&(t.value=n.getParameter(i.UNMASKED_RENDERER_WEBGL))}catch(e){t.value=""}return t}var g=n(93608);var h=n(71111),_=n(31209);const f=e=>{const t={};for(const[n,i]of e)t[n]=i;return t},y=Object.assign({globalWid:"",canvasId:"",hasReportedOnLanding:!1},f(["fonts","domBlockers","fontPreferences","audio","screenFrame","osCpu","languages","colorDepth","deviceMemory","screenResolution","hardwareConcurrency","timezone","sessionStorage","localStorage","indexedDB","openDatabase","cpuClass","platform","plugins","canvas","touchSupport","vendor","vendorFlavors","cookiesEnabled","colorGamut","invertedColors","forcedColors","monochrome","contrast","reducedMotion","hdr","math","videoCard","pdfViewerEnabled","architecture","userAgent","webglUnmaskedVendor","webglUnmaskedRenderer","webglImageHash"].map((e=>[e,""])))),b=(0,h.atom)(y);b.debugLabel="globalWidAtom";const{useServiceDispatchers:w,useServiceState:x}=(0,_.i)(b,((e,t)=>({maybeGenerateAndReportGlobalWidInfo:n=>(0,i.__awaiter)(void 0,void 0,void 0,(function*(){var r,h;const{isLanding:_=!1,enterMethod:y,hashedIP:w="",region:x=""}=n;try{let n="",k="",S={};if(!e(b).globalWid){const e=yield function(e,t){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const n=yield o.Ay.load({monitoring:!1}),r=(yield n.get()).components,{domBlockers:g,canvas:h}=r,_=(0,i.__rest)(r,["domBlockers","canvas"]),f={value:a(h.value),duration:0};Object.values(_).forEach((e=>e.duration=0));const y={value:e||"",duration:0},b={value:t||"",duration:0},w=Object.assign(Object.assign({},_),{canvasComponent:f,webglComponent:s(),highEntropyValues:yield l(),uaComponent:c(),devicePixelRatio:d(),pdfViewerEnabled:u(),sampleRate:p(),webGLUnmaskedVendorComponent:v(),webGLUnmaskedRendererComponent:m(),hashedIPComponent:y,regionComponent:b}),x={};Object.entries(w).forEach((([e,t])=>{x[e]=JSON.stringify(t.value||{})}));const T=o.Ay.hashComponents(w),k=f.value,S=(null==k?void 0:k.geometry)||"",E=(null==k?void 0:k.text)||"",A=S.concat(E);return x.canvas=JSON.stringify(k||{}),Object.assign({gwid:T,canvasId:A},x)}))}(w,x);n=null!==(r=null==e?void 0:e.gwid)&&void 0!==r?r:"",k=null!==(h=null==e?void 0:e.canvasId)&&void 0!==h?h:"",S=null!=e?e:{},n&&t(b,(e=>Object.assign(Object.assign(Object.assign({},e),{globalWid:n,canvasId:k}),S)))}return _&&e(b).hasReportedOnLanding||(T=Object.assign({global_wid:e(b).globalWid,canvas_id:e(b).canvasId,enter_method:y,page_name:g.f.commonParams.page_name},f(Object.entries(e(b)).filter((([e])=>!["globalWid","canvasId","hasReportedOnLanding"].includes(e))))),g.f.sendEvent("send_global_wid",T)),e(b).globalWid}catch(e){return console.error("Error in maybeGenerateAndReportGlobalWidInfo:",e),null}var T})),setLandingPageETSentFlag:e=>{const{hasReportedOnLanding:n}=e;t(b,(e=>Object.assign(Object.assign({},e),{hasReportedOnLanding:n})))}})))},4912:(e,t,n)=>{"use strict";n.d(t,{Gg:()=>M,ym:()=>I,ct:()=>C,Du:()=>L,LT:()=>j,tF:()=>P});var i=n(58632),o=n(73580),a=n(4474),r=n(40099),s=n(47172),l=n(71510),c=n.n(l),d=n(93608),u=n(92603),p=n(40040);function v(e,t){var n,i,o,a,r,s;const l=(0,u.Hd)(p.hk,"");if(l&&"{}"!==l)return l;const c=(0,u.$Z)()||{},d={object_id:null!==(n=c.object_id)&&void 0!==n?n:c.referer_video_id,object_type:c.object_type,share_device:null!==(o=null!==(i=c.share_device)&&void 0!==i?i:c.sender_device)&&void 0!==o?o:"",share_web_id:null!==(r=null!==(a=c.share_web_id)&&void 0!==a?a:c.sender_web_id)&&void 0!==r?r:"",share_user_id:null!==(s=c.share_user_id)&&void 0!==s?s:""};"referral_amp"===e||"referral_embed"===e?(d.object_type="video",d.object_id=c.referer_video_id):"reflow"===e||"webapp_reflow"===e?(d.object_type=null==t?void 0:t.object_type,d.object_id=null==t?void 0:t.object_id):"push"===e&&(d.push_type=c.push_type),Object.keys(d).forEach((e=>{d[e]||delete d[e]}));const v=JSON.stringify(d);return(0,u.J2)(p.hk,v),v}var m=n(68252),g=n(42721);const h=e=>{var t;const n=e,{page_name:o,enter_from:a,is_downgrade:r,object_id:s,object_type:l}=n,c=g.ET,p=(n[c],(0,i.__rest)(n,["page_name","enter_from","is_downgrade","object_id","object_type","symbol"==typeof c?c:c+""])),v=(0,u.$Z)();return Object.assign({previous_page:d.f.getPreviousInfo(o),page_name:o,enter_from:a,page_url:window.location.href,userAgent:navigator.userAgent,keyword:v.keyword,sub_keyword:v.sub_keyword,user_type_alias:window.navigator.userAgent.match(/google/gi)?"search":"user",domain_name:null!==(t=window.location.host)&&void 0!==t?t:"unknown",page_path:window.location.pathname},p)};const _=(e,t)=>{var n,i,o,a;const{user:r,region:s,wid:l,language:u}=e,{page_name:p,is_downgrade:m,object_id:h,object_type:_,utm_medium:f,utm_campaign:y,utm_source:b,embed_source:w="",vidab:x,seo_vidab:T,[g.ET]:k,source:S}=t,E=c()(d.f.initDimensionalData,{utm_medium:f,utm_campaign:y,utm_source:b}),A=Object.assign(Object.assign({release:"1.0.2.6172",user_is_login:r?1:0,priority_region:null==r?void 0:r.region,landing_page:d.f.getLandingPage(p),is_kids_mode:(null==r?void 0:r.ftcUser)?1:0,region:s,extraData:v(E.launch_mode,{object_id:h,object_type:_}),is_downgrade:m,session_id:d.f.getSessionId(l),embed_source:w,app_language:u,is_sharing:0,vidab:x,seo_vidab:T,[g.ET]:k,max_touch_points:null===navigator||void 0===navigator?void 0:navigator.maxTouchPoints,network_downlink:null===(n=navigator.connection)||void 0===n?void 0:n.downlink,network_rtt:null===(i=navigator.connection)||void 0===i?void 0:i.rtt,network_speed_effective_type:null===(o=navigator.connection)||void 0===o?void 0:o.effectiveType,network_connection_type:null===(a=navigator.connection)||void 0===a?void 0:a.type},function(){var e;const t=new URLSearchParams(null===(e=window.location)||void 0===e?void 0:e.search),n=!!t.get("gclid");let i={};const o="webapp-recharge-google_ads_info";try{if(n)i={utm_gclid:t.get("gclid"),utm_original_url:window.location.href,utm_medium:t.get("utm_medium"),utm_media_source:t.get("utm_source")||t.get("utm_media_source"),utm_campaign_id:t.get("campaign_id")||t.get("campaignid"),utm_adset_id:t.get("adset_id")||t.get("adgroupid"),utm_ad_id:t.get("ad_id")||t.get("creative"),utm_channel:t.get("channel")||t.get("network"),utm_keyword:t.get("keyword"),utm_placement:t.get("placement"),utm_match_type:t.get("match_type")},localStorage.setItem(o,JSON.stringify({value:i,expiryDate:(new Date).getTime()+2592e6}));else{const e=JSON.parse(localStorage.getItem(o)||"{}");e.expiryDate&&(new Date).getTime()["region","user","wid","abTestVersion","language","odinId"]),[])),a=(0,E.L$)((0,k.U)((()=>["domains","vgeo"]),[])),{abTestVersion:l,user:c}=o,u=(0,S.mx)(l,null!==(n=null==c?void 0:c.uid)&&void 0!==n?n:"");!function(e,t,n){const{user:o,region:a,wid:l,domains:c,odinId:u,vgeo:p,abTestVersion:v}=e,g=t(),{initConfig:f={}}=g,y=(0,i.__rest)(g,["initConfig"]);(0,r.useEffect)((()=>{var t;if(!y||y.skip_init)return;const n=h(y),i=_(e,y);d.f.config({initConfig:Object.assign({channel_domain:c.tea,ab_channel_domain:c.libraWebSDK,channel_type:c.teaChannelType,channel:c.teaChannel,id:1988},f),commonHeaderConfig:{region:a,user_id:null!==(t=null==o?void 0:o.uid)&&void 0!==t?t:u,user_is_login:Boolean(o),user_unique_id:l,user_type:12,device_id:l,"header.custom":i},commonEventParams:Object.assign(Object.assign({},n),{data_collection_enabled:(0,m.uh)(p,!!o)?1:0}),abTestVersion:v})}),[...n]),function(){const e=(0,s.useHistory)();(0,r.useEffect)((()=>{const t=null==e?void 0:e.listen((e=>{d.f.resetStayDuration(e.pathname,e.pathname,window.location.href)}));return()=>{null==t||t()}}),[])}()}(Object.assign(Object.assign({},a),o),(()=>Object.assign(Object.assign({},e()),{is_downgrade:(0,w.qk)(),is_non_personalized:u?"1":"0"})),t)}function I(e){const{loginPredictionHandler:t}=(0,O.P)(e);(0,r.useEffect)((()=>{t()}),[t])}function C({eParams:e}){var t,n;const{botType:o,webIdCreatedTime:l}=null!==(t=(0,T.W)((()=>["botType","webIdCreatedTime"]),[]))&&void 0!==t?t:{},{isMobile:c}=null!==(n=(0,k.U)((()=>["isMobile"]),[]))&&void 0!==n?n:{},{search:d,pathname:u}=(0,s.useLocation)(),p=(0,a.parse)(d);return(0,r.useCallback)((()=>{const t=e||{},{is_from_webapp:n}=t,a=(0,i.__rest)(t,["is_from_webapp"]),r=p.sender_web_id?{sender_device:p.sender_device,sender_web_id:p.sender_web_id}:{},s=c||(0,x.tO)(u)||(d=`#${location.pathname}`,/^#\/@.*\/video\/\d+$/.test(d))||location.search.indexOf("item_id")>-1?Object.assign({is_from_webapp:n||["v1","v2","v3"].indexOf(p.is_from_webapp)>-1?p.is_from_webapp:"0"},r):{};var d;const v={browser_height:"undefined"!=typeof window?window.innerHeight:0,browser_width:"undefined"!=typeof window?window.innerWidth:0},m=Object.assign(Object.assign(Object.assign({bot_type:null!=o?o:"others",keyword:p.keyword,sub_keyword:p.sub_keyword,duration:performance.now(),webIdCreatedTime:l},a),s),v);f.O.handlePageView(m)}),[e,p.sender_web_id,p.sender_device,p.is_from_webapp,c,p.keyword,p.sub_keyword,u,o])}function L(e){const{pathname:t}=(0,s.useLocation)(),n=(0,o.Nj)(y.AU);(0,r.useEffect)((()=>{const e=(0,A.N2)(t);n.handleRouteChange(t),n.updateCurrentPage(e),n.setCurrentPageReport(!1),n.resetExist(),n.reportVideoAdditionStart({startTime:Date.now(),situation:"addition_first_load"})}),[n,e,t])}function j(){const e=(0,o.Nj)(b.Gs);(0,r.useEffect)((()=>{e.reset()}),[e])}function M(){const e=(0,E.L$)((0,T.W)((()=>["region","user","wid","abTestVersion","language"]),[])),t=(0,E.L$)((0,k.U)((()=>["domains","vgeo"]),[])),n=(0,r.useMemo)((()=>Object.assign(Object.assign({},e),t)),[e,t]),{user:i,region:o,wid:a,domains:s,vgeo:l}=n;return(0,r.useCallback)((e=>{var t,r;const c={page_name:e,enter_from:e,is_downgrade:(0,w.qk)()},u=h(c),p=_(n,c);d.f.config({initConfig:{channel_domain:s.tea,channel_type:null!==(t=s.teaChannelType)&&void 0!==t?t:"tcpy",channel:s.teaChannel,ab_channel_domain:s.libraWebSDK,id:1988},commonHeaderConfig:{region:o,user_id:null!==(r=null==i?void 0:i.uid)&&void 0!==r?r:"",user_is_login:Boolean(i),user_unique_id:a,device_id:a,user_type:12,"header.custom":p},commonEventParams:Object.assign(Object.assign({},u),{data_collection_enabled:(0,m.uh)(l,!!i)?1:0})})}),[n,s,o,i,l,a])}},27375:(e,t,n)=>{"use strict";n.d(t,{$S:()=>p,BO:()=>s,Hw:()=>g,RS:()=>u,Zr:()=>m,i0:()=>l,lH:()=>a,qY:()=>v,sg:()=>d});const i=99,o="99+";function a(e,t=i,n=o){return e>t?n:String(e)}function r(e){var t,n;return null!==(n=null===(t=null==e?void 0:e.url_list)||void 0===t?void 0:t.find((e=>!/\.webp/.test(e))))&&void 0!==n?n:""}function s(e){var t;return void 0===e?"":e.url_list&&(null===(t=e.url_list)||void 0===t?void 0:t.length)>0?e.url_list[0]:""}const l={[-1]:-1,0:0,1:1,2:2,4:3};function c({is_block:e,is_blocked:t,follow_status:n}){if(null!=n)return e?4:t?5:l[n]}function d(e,t=!1){const{follower_count:n,following_count:i,aweme_count:o}=e;return{diggCount:0,followerCount:null!=n?n:0,followingCount:null!=i?i:0,heart:0,heartCount:0,videoCount:null!=o?o:0,needFix:t}}function u(e){const{avatar_medium:t,avatar_thumb:n,uid:i,short_id:o,unique_id:a,sec_uid:s,nickname:l,is_block:d,follow_status:u,signature:p,custom_verify:v,enterprise_verify_reason:m,follower_status:g}=e;return{avatarLarger:"",avatarMedium:r(t),avatarThumb:r(n),id:i,shortId:o,uniqueId:null!=a?a:"",secUid:null!=s?s:"",nickname:l,relation:c({is_block:d,is_blocked:void 0,follow_status:u}),signature:p,verified:Boolean(v||m),createTime:0,extraInfo:{followerStatus:g}}}function p(e){const{id_str:t,title:n,play_url:i,cover_medium:o,cover_large:a,cover_thumb:r,is_original:l,duration:c,author:d}=e;return{id:String(t),title:n,duration:c,keyToken:"",playUrl:s(i),coverMedium:s(o),coverLarge:s(a),coverThumb:s(r),original:null!=l&&l,authorName:d}}function v(e,t){if(!e)return!0;const{commentSetting:n,relation:i,id:o}=e;return 1===n&&2!==i&&t!==o}function m(e){return e.replace(/\n(\n)*( )*(\n)*\n/g,"\n")}function g(e,t){var n;const{duration:i,width:o,height:a,ratio:r,cover:l,play_addr:c,bit_rate:d}=e,u=null==d?void 0:d.map((e=>({GearName:e.gear_name,Bitrate:e.bit_rate,QualityType:e.quality_type,PlayAddr:{Uri:"",UrlList:[s(e.play_addr)]},CodecType:"adapt_h264"})));return{id:t,height:a,width:o,duration:null!=i?i:0,ratio:null!=r?r:"720p",cover:s(l),originCover:s(l),playAddr:s(c),bitrate:null===(n=null==d?void 0:d[0])||void 0===n?void 0:n.bit_rate,bitrateInfo:u,encodedType:"normal"}}},16469:(e,t,n)=>{"use strict";n.d(t,{Bv:()=>l,LU:()=>p,MX:()=>c,PC:()=>d,_w:()=>a,bc:()=>o,lA:()=>s,lL:()=>u});var i=n(10646);const o=new i.w1("frequency-control-config","local"),a=new i.w1("flip-control-config","local");var r;!function(e){e.Manual="manual",e.BrowserMode="browser_mode"}(r||(r={}));const s=new i.w1("webapp-video-mute","local"),l=new i.w1("keyboard-shortcut-config","local"),c=new i.w1("webapp-comment-url","session"),d=new i.w1("search-entry-block-map-storage","local"),u=new i.w1("fyp-feed-cache","local"),p=new i.w1("search_history_map","local");new i.w1("multi-account-info","local")},33805:(e,t,n)=>{"use strict";n.d(t,{AF:()=>_,Am:()=>y,N2:()=>g,Q2:()=>h,Sn:()=>b,m1:()=>f,oN:()=>p,rE:()=>x,sN:()=>w});var i=n(47172),o=n(9047),a=n(82715),r=n(8227),s=n(75792),l=n(95868),c=n(72688),d=n(85612);const u=1e3;function p(e){var t,n,r,s;return e.length>u?"":(0,l.tO)(e)?"homepage_hot":/^\/@(.*?)\/video\/(.*?)/.test(e)?"video_detail":/^\/@(.*?)/.test(e)?"others_homepage":/^\/music\//.test(e)?"single_song":/^\/effect\//.test(e)?"effect_detail":/^\/tag\//.test(e)?"challenge":/^\/following/.test(e)?"homepage_follow":/^\/explore/.test(e)?"explore_page":"expansion"===(null===(t=(0,o.uZ)(e))||void 0===t?void 0:t.name)?"discover_kw":/^\/channel\/.+/.test(e)?"channel":"discover"===(null===(n=(0,a.kv)(e))||void 0===n?void 0:n.name)?"discovery":/^\/profile/.test(e)?"personal_homepage":/^\/topics/.test(e)?`topic_${e.slice(1).split("/")[1]}`:/^\/inbox/.test(e)?"homepage_message":/^\/report/.test(e)?"report":/^\/ad-report/.test(e)?"report_ad":/^\/feedback\/report/.test(e)?"feedback_report":/^\/feedback\/history/.test(e)?"feedback_history":/^\/feedback/.test(e)?"feedback":(0,i.matchPath)(e,{path:a.OZ.searchHome,exact:!0})?"general_search":(0,i.matchPath)(e,{path:a.OZ.searchUser,exact:!0})?"search_user":(0,i.matchPath)(e,{path:a.OZ.searchVideo,exact:!0})?"search_video":/^\/playlist-music/.test(e)?"music_playlist":/^\/messages/.test(e)?"messages":/^\/setting/.test(e)?"setting":/^\/place/.test(e)?"place":/^\/@(.*?)\/collection\/(.*?)/.test(e)?"collection":/^\/@(.*?)\/playlist\/(.*?)/.test(e)?"reflow_video_playlist":/^\/download/.test(e)?"download":"trendingDetail"===(null===(r=(0,o.uZ)(e))||void 0===r?void 0:r.name)||"trendingDetailWithinDiscover"===(null===(s=(0,o.uZ)(e))||void 0===s?void 0:s.name)?"discover_pro":""}function v(e){return e.length>u?"":/^\/@(.*?)\/live\/(.*?)/.test(e)?"live_detail":(0,i.matchPath)(e,{path:r.vI.liveGoLive,exact:!0})?"live_take":(0,l.U0)(e)?"live_discover":(0,l.j)(e)?"live_event":(0,l.RR)(e)?"live_event_aggregation":(0,i.matchPath)(e,{path:r.vI.liveRoomEmbed,exact:!0})?"live_embed_detail":(0,i.matchPath)(e,{path:r.vI.liveRoom,exact:!0})?"live_detail":""}function m(e){return(0,i.matchPath)(e,{path:s.tH.loginHome,exact:!1})||(0,i.matchPath)(e,{path:s.tH.oauth,exact:!1})||(0,i.matchPath)(e,{path:s.tH.oauthLine,exact:!1})?"login":(0,i.matchPath)(e,{path:s.tH.signupHome,exact:!1})?"signup":""}function g(e){for(const t of[p,v,m]){const n=t(e);if(n)return n}return"unknown"}function h(){return location.pathname.startsWith(a.OZ.musicPlaylist.split(":")[0])&&location.pathname.length<=u?`${location.origin}${location.pathname.replace(/%23|%3F|%2F/g,"")}${location.search}`:location.href}function _(){return location.pathname.startsWith(a.OZ.musicPlaylist.split(":")[0])&&location.pathname.length<=u?`${location.origin}${location.pathname.replace(/%23|%3F|%2F/g,"")}`:`${location.origin}${location.pathname}`}function f(e,t){return`https://www.tiktok.com${y(e,t)}`}function y(e,t,n){return`/place/${(0,c.zpT)(t)}-${e}${n?`?language=${n}`:""}`}function b(e,t){var n,i,o,a;return(0,d.Rj)(`https://www.tiktok.com${(0,c.G2o)({uniqueId:null!==(i=null===(n=null==e?void 0:e.owner)||void 0===n?void 0:n.display_id)&&void 0!==i?i:"",secUid:null!==(a=null===(o=null==e?void 0:e.owner)||void 0===o?void 0:o.sec_uid)&&void 0!==a?a:""})}`,null!=t?t:{})}function w(e,t){return`https://www.tiktok.com/tns-inapp/pages/ai-generated-content?hide_nav_bar=1${e?`&enter_from=${e}`:""}${t?`&lang=${t}`:""}`}function x(e,t){return`/effect/${encodeURIComponent(e.replace(/\s+/g,"-"))}-${t}`}},32744:(e,t,n)=>{"use strict";n.d(t,{W:()=>g});var i=n(24643),o=n(73580),a=n(40099),r=n(93608);var s=n(11654),l=n(62186),c=n(97397);const d=(0,l.default)("div",{target:"emuynwa0"})((({isFullScreen:e})=>e?{flex:"1 1 auto"}:null),{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center",margin:"0 auto"},"label:DivErrorContainer;"),u=(0,l.default)("p",{target:"emuynwa1"})((({theme:{typography:e,fontWeights:t,fontFamilies:n,colors:i}})=>[e.H4,{fontFamily:n.TikTokDisplayFont,fontWeight:t.bold,color:i.TextPrimary,marginTop:"24px"}]),"label:PTitle;"),p=(0,l.default)("p",{target:"emuynwa2"})((({theme:{typography:e,fontWeights:t,fontFamilies:n,colors:i}})=>[e.P2,{fontFamily:n.TikTokFont,fontWeight:t.normal,color:i.TextSecondary,marginTop:"8px"}]),"label:PDesc;"),v=l.default.div` margin-top: 24px; `,m=(0,l.default)(c.y,{target:"emuynwa3"})({marginTop:"24px"},"label:StyledButton;"),g=function(e){const{iconElem:t,title:n,desc:l,buttonText:c,button:g,isFullScreen:h,style:_,brightness:f=1,e2eTitle:y,e2eDesc:b,e2eButton:w,onButtonShow:x,ignoreErrorReport:T=!1}=e,k=(0,o.Nj)(s.V$);return(0,a.useEffect)((()=>{(c||g)&&(null==x||x()),T||(k.emitEvent("handled_error_report",{},{}),r.f.sendEvent("handled_render_error"))}),[c,g,x,T,k]),(0,i.jsxs)(d,{isFullScreen:h,style:_,children:[t,n&&(0,i.jsx)(u,{"data-e2e":y,brightness:f,children:n}),l&&(0,i.jsx)(p,{"data-e2e":b,brightness:f,children:l}),g&&(0,i.jsx)(v,{"data-e2e":w,children:g}),!g&&Boolean(c)&&(0,i.jsx)(m,{type:"button",onClick:e.onButtonClick,buttonTheme:"default",size:"large",e2eTag:w,children:c})]})}},96689:(e,t,n)=>{"use strict";n.d(t,{G:()=>r,K:()=>s});var i=n(40099),o=n(49057),a=n(16680);function r({actionWhenUserLoggedIn:e,modalConfig:t={},reportClickEvent:n,openModalWhenUserLoggedIn:r}){const s=(0,o.W)((()=>["user"]),[]),l=(0,a.b1)();return(0,i.useCallback)(((...i)=>{null==n||n(...i);const o="function"==typeof t?t():t;if((null==s?void 0:s.user)&&!r){if(!o.isLinkPhoneOrEmail)return null==e?void 0:e(...i);l.openModal(o)}else l.openModal(o)}),[e,null==s?void 0:s.user,l,t,n,r])}function s(e={},t,n){return r({modalConfig:"function"==typeof e?e():e,reportClickEvent:t,openModalWhenUserLoggedIn:n})}},47926:(e,t,n)=>{"use strict";n.d(t,{i:()=>r});var i=n(24643),o=n(40099),a=n(88091);const r=(0,o.memo)((function({isOpen:e,onClose:t,children:n,closeOnBackdropClick:o=!1,closeOnEsc:r=!1,onCloseComplete:s,compact:l}){return(0,i.jsx)(a.Mw,{isOpen:e,onClose:t,onCloseComplete:s,size:"Medium",compact:l,closeOnBackdropClick:o,closeOnEsc:r,children:n})}))},33063:(e,t,n)=>{"use strict";n.d(t,{_y:()=>u,lz:()=>p});var i,o=n(43723),a=n(31209);!function(e){e[e.None=0]="None",e[e.PromotePopupTip=1]="PromotePopupTip",e[e.LoginPopupRedesign=2]="LoginPopupRedesign",e[e.LoginPopup=3]="LoginPopup",e[e.InterestSelector=4]="InterestSelector"}(i||(i={}));const r=new class{constructor(){this.priorityKeys=[],this.endPriorityKeys=[]}start(e){this.endPriorityKeys.filter((t=>t!==e))}end(e){if(!this.endPriorityKeys.includes(e)){this.endPriorityKeys.push(e);const t=this.priorityKeys.find((e=>!this.endPriorityKeys.includes(e)));if(t)return t}return null}remove(e){this.priorityKeys.filter((t=>t!==e))}add(e){this.priorityKeys.includes(e)||(this.priorityKeys=[...this.priorityKeys,e].sort(((e,t)=>e-t)))}clean(){this.priorityKeys=[],this.endPriorityKeys=[]}},s={0:!0,1:!1,3:!1},l=(0,o.p)("popupPriorityAtom@tiktok/fe-shared",{priority:0,isReadyList:s}),c=(0,o.p)("isAllReadyAtom@tiktok/fe-shared",(e=>Object.values(e(l).isReadyList).reduce(((e,t)=>e&&t)))),{useAtomService:d,useServiceDispatchers:u,useServiceState:p}=(0,a.i)(l,((e,t)=>({setIsPopupPriorityReady(n){const i=e(l);if(t(l,Object.assign(Object.assign({},i),{isReadyList:Object.assign(Object.assign({},i.isReadyList),{[n]:!0})})),e(c)){const n=r.end(0);n?t(l,Object.assign(Object.assign({},e(l)),{priority:n})):r.clean()}},clearReadyListOnRouteChange(){const n=e(l);t(l,Object.assign(Object.assign({},n),{isReadyList:s})),r.clean()},getPriorityPopup:n=>({handlePopoverInitial:()=>{r.start(n)},handlePopoverEnd:()=>{const i=e(l).priority;if(n!==i)r.remove(n);else{const i=r.end(n);i?t(l,Object.assign(Object.assign({},e(l)),{priority:i})):(r.clean(),t(l,Object.assign(Object.assign({},e(l)),{priority:0})))}},handlePopoverAdd:()=>{if(r.add(n),e(c)){const n=r.end(0);n&&t(l,Object.assign(Object.assign({},e(l)),{priority:n}))}}})})))},30721:(e,t,n)=>{"use strict";n.d(t,{Qt:()=>a}),n(40099),n(47172);var i=n(60484),o=n(48615);function a(){const{playerInfo:e}=(0,i.L$)((0,o.U)((()=>["playerInfo"]),[])),{name:t="",isSmartPlayer:n=!1,type:a=0,loop:r=!1,replyComment:s=!0,hideNavBar:l=!1}=(0,i.L$)(e);return{brand:t,isEchoShow:"echoshow"===t,isTtincar:"ttincar"===t,launchType:a,isSmartPlayer:n,loop:r,replyComment:s,hideNavBar:l}}},82290:(e,t,n)=>{"use strict";n.d(t,{PD:()=>l,t6:()=>s});var i=n(58632);const o=(()=>{let e;return()=>(e||(e=new Promise((e=>{"undefined"==typeof window&&e(!1);const t=new Image;t.onload=()=>{window.__support_webp__=160===(null==t?void 0:t.height),e(160===(null==t?void 0:t.height))},t.onerror=()=>{window.__support_webp__=!1,e(!1)},t.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvn8AnAAdQiUpUov+BiOh/AAA="}))),e)})(),a=(()=>{let e;return()=>(e||(e=new Promise((e=>{"undefined"==typeof window&&e(!1);const t=new Image;t.onload=()=>{window.__support_avif__=1===(null==t?void 0:t.width),e(1===(null==t?void 0:t.width))},t.onerror=()=>{window.__support_avif__=!1,e(!1)},t.src="data:image/avif;base64,AAAALGZ0eXBhdmlzAAAAAGF2aWZhdmlzbXNmMWlzbzhtaWYxbWlhZk1BMUEAAAElbWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAiaWxvYwAAAABEQAABAAIAAAAABgAAAQAAACUAAAAYAAAAKGlpbmYAAAAAAAEAAAAaaW5mZQIAAAAAAgAAYXYwMUFscGhhAAAAAAxpcmVmAAAAAAAAAI1pcHJwAAAAbmlwY28AAAAUaXNwZQAAAAAAAAABAAAAAQAAAA5waXhpAAAAAAEIAAAADGF2MUOBABwAAAAAOGF1eEMAAAAAdXJuOm1wZWc6bXBlZ0I6Y2ljcDpzeXN0ZW1zOmF1eGlsaWFyeTphbHBoYQAAAAAXaXBtYQAAAAAAAAABAAIEAQKDBAAABKdtb292AAAAbG12aGQAAAAA4GrKgOBqyoAAAABkAAAAZAABAAABAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAACGXRyYWsAAABcdGtoZAAAAAHgasqA4GrL+AAAAAEAAAAAAAAAZAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAQAAAAEAAAAAAbVtZGlhAAAAIG1kaGQAAAAA4GrKgOBqyoAAAABkAAAAZFXEAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAABZW1pbmYAAAAUdm1oZAAAAAEAAAAAAAAAAAAAACRkaW5mAAAAHGRyZWYAAAAAAAAAAQAAAAx1cmwgAAAAAQAAASVzdGJsAAAAlXN0c2QAAAAAAAAAAQAAAIVhdjAxAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAEAAQBIAAAASAAAAAAAAAABCkFPTSBDb2RpbmcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGP//AAAADGF2MUOBIAAAAAAAE2NvbHJuY2x4AAEADQAGgAAAABBjY3N0AAAAAHwAAAAAAAAYc3R0cwAAAAAAAAABAAAAAgAAADIAAAAUc3RzcwAAAAAAAAABAAAAAQAAAChzdHNjAAAAAAAAAAIAAAABAAAAAQAAAAEAAAACAAAAAQAAAAEAAAAcc3RzegAAAAAAAAAAAAAAAgAAACUAAAAaAAAAGHN0Y28AAAAAAAAAAgAABgAAAAY9AAACGnRyYWsAAABcdGtoZAAAAAHgasqA4GrL+AAAAAIAAAAAAAAAZAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAQAAAAEAAAAAABR0cmVmAAAADGF1eGwAAAABAAABom1kaWEAAAAgbWRoZAAAAADgasqA4GrKgAAAAGQAAABkVcQAAAAAAChoZGxyAAAAAAAAAABwaWN0AAAAAAAAAAAAAAAAbGliYXZpZgAAAAFSbWluZgAAABR2bWhkAAAAAQAAAAAAAAAAAAAAJGRpbmYAAAAcZHJlZgAAAAAAAAABAAAADHVybCAAAAABAAABEnN0YmwAAACCc3RzZAAAAAAAAAABAAAAcmF2MDEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAQABAEgAAABIAAAAAAAAAAEKQU9NIENvZGluZwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY//8AAAAMYXYxQ4EAHAAAAAAQY2NzdAAAAAB8AAAAAAAAGHN0dHMAAAAAAAAAAQAAAAIAAAAyAAAAFHN0c3MAAAAAAAAAAQAAAAEAAAAoc3RzYwAAAAAAAAACAAAAAQAAAAEAAAABAAAAAgAAAAEAAAABAAAAHHN0c3oAAAAAAAAAAAAAAAIAAAAYAAAAEAAAABhzdGNvAAAAAAAAAAIAAAYlAAAGVwAAAG9tZGF0EgAKCyAAAAAAffyQENBpMhQQALAAAAJAAAAAeUzeCGsZI8iw4BIACggAAAAAAH38lTIKEACAAAAY3qKVUBIAMhYwA8CAAABGsAAAAkAAIAAeeln6XS7gEgAyDDADwIAAAEaABACRkAAAAENmcmVlSXNvTWVkaWEgRmlsZSBQcm9kdWNlZCB3aXRoIEdQQUMgMi4yLXJldjAtZ2FiMDEyYmJmLW1hc3RlcgA="}))),e)})();let r=!1;const s=()=>(0,i.__awaiter)(void 0,void 0,void 0,(function*(){yield(0,i.__awaiter)(void 0,void 0,void 0,(function*(){const[e,t]=yield Promise.all([a(),o()]);return{supportAvif:e,supportWebp:t}})),r=!0})),l=()=>r?{supportAvif:window.__support_avif__,supportWebp:window.__support_webp__}:(console.warn("VideoCoverViewer: can not use `getCoverFormat` before `coverFormatCheck"),{})},84506:(e,t,n)=>{"use strict";n.d(t,{K8:()=>g,Sd:()=>f,W3:()=>_,_j:()=>h,gG:()=>y,sy:()=>b});var i=n(58632),o=n(40099),a=n(47172),r=n(5441),s=n(243),l=n.n(s),c=n(58305),d=n(95868),u=n(45297),p=n(60484),v=n(71281),m=n(49057);const g=()=>{const e=(0,c.Hd)(u.O_);return["pwa","msft","twa"].includes(e)},h=()=>{var e;const{abTestVersion:t}=(0,p.L$)((0,m.W)((()=>["abTestVersion"]),[])),n=null!==(e=(0,v.qt)(t,"desktop_app_test"))&&void 0!==e?e:"v1";return{desktopAppTestVid:n,isDesktopTestV1:"v1"===n,isDesktopTestV2:"v2"===n}},_=()=>{const[e,t]=(0,o.useState)(!0);return(0,o.useEffect)((()=>{var e;t(Boolean("MAIN_WINDOW"===(null===(e=null===window||void 0===window?void 0:window.TTE_ENV)||void 0===e?void 0:e.windowName)))}),[]),e},f=()=>{const{pathname:e}=(0,a.useLocation)();return(0,d.tO)(e)||(0,d.gq)(e)||(0,d.U0)(e)||(0,d.eD)(e)},y=()=>{const{isElectronApp:e}=(0,r.B)();(0,o.useEffect)((()=>{if(e){const e=Element.prototype.requestFullscreen;Element.prototype.requestFullscreen=function(...t){return(0,i.__awaiter)(this,void 0,void 0,(function*(){yield l().app.setFullScreenable(!0),e.call(this,...t)}))}}}),[e])},b=()=>{const[e,t]=(0,o.useState)("undefined"!=typeof window&&null!==(a=null===(i=null===(n=null===window||void 0===window?void 0:window.matchMedia)||void 0===n?void 0:n.call(window,"(prefers-color-scheme: dark)"))||void 0===i?void 0:i.matches)&&void 0!==a&&a);var n,i,a;const r=e=>{var n;t(null!==(n=null==e?void 0:e.matches)&&void 0!==n&&n)};return(0,o.useEffect)((()=>{var e;const t=null===(e=null===window||void 0===window?void 0:window.matchMedia)||void 0===e?void 0:e.call(window,"(prefers-color-scheme: dark)");return t.addListener(r),()=>t.removeListener(r)}),[]),e}},89311:(e,t,n)=>{"use strict";n.d(t,{m:()=>a});var i=n(60484),o=n(49057);const a=()=>{const{language:e}=(0,i.L$)((0,o.W)((()=>["language"]),[]));return{isRTL:"ar"===e||"ur"===e||"he-IL"===e}}},37434:(e,t,n)=>{"use strict";n.d(t,{Us:()=>a});var i=n(41271),o=(n(32877),n(50970));function a(){return(0,i.P)(o.L)}},50970:(e,t,n)=>{"use strict";n.d(t,{L:()=>h});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(46657),l=n(23999),c=n(26324),d=n(24451),u=n(62564),p=n(35572),v=n(8536),m=n(74690),g=n(80339);let h=class extends o.E{constructor(){super(...arguments),this.defaultState={appContext:null,initialized:!1,lang:"en",sideNavActive:!1}}setSideNavActive(e,t){return Object.assign(Object.assign({},e),{sideNavActive:t})}toggleSideNav(e){return e.pipe((0,d.E)(this.state$),(0,u.T)((([e,t])=>this.getActions().setSideNavActive(!t.sideNavActive))))}setAppContext(e,t){var{statusCode:n}=t,o=(0,i.__rest)(t,["statusCode"]);return 0!==n?e:Object.assign(Object.assign({},e),{appContext:o})}setInitialized(e,t){return Object.assign(Object.assign({},e),{initialized:t})}setLang(e,t){return Object.assign(Object.assign({},e),{lang:t})}init(e){return e.pipe((0,d.E)(this.state$),(0,p.p)((([{appContext:e},{initialized:t}])=>t?s.w:(0,l.of)(Object.assign(Object.assign({},e),{statusCode:0})).pipe((0,v.Z)((t=>(0,l.of)(this.getActions().setAppContext(t),this.getActions().setLang(e.language)))),(0,m.Z)(this.getActions().setInitialized(!1)),(0,g.q)(this.getActions().setInitialized(!0),this.terminate())))))}};(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",Object)],h.prototype,"setSideNavActive",null),(0,i.__decorate)([(0,a.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[c.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"toggleSideNav",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",Object)],h.prototype,"setAppContext",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",Object)],h.prototype,"setInitialized",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",Object)],h.prototype,"setLang",null),(0,i.__decorate)([(0,a.Mj)({payloadGetter:1}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[c.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"init",null),h=(0,i.__decorate)([(0,r.n)("AppContext")],h)},44926:(e,t,n)=>{"use strict";n.d(t,{Eq:()=>w,JV:()=>h,LV:()=>b,OB:()=>g,Sb:()=>y,Zl:()=>_,d8:()=>f,o1:()=>m});var i=n(71111),o=n(31209),a=n(18538),r=n(79479),s=n.n(r),l=n(99789),c=n.n(l);const d=(0,i.atom)({}),u=(0,i.atom)(null,((e,t,n,o)=>{if(o){const a=e(d)[n];a?t(a,o):t(d,(e=>Object.assign(Object.assign({},e),{[n]:(0,i.atom)(o)})))}else t(d,(e=>c()(e,n)))})),p=(0,i.atom)(null),v=(0,i.atom)([]),m=(0,i.atom)((e=>{const{browserList:t=[]}=(0,a.N)(e,"creator_tab");return t})),g=(0,i.atom)((e=>{const t=[],n=e(v);for(const i of n){const{browserList:n=[]}=(0,a.N)(e,i.itemListKey);if(i.skip>=n.length)break;const o=Math.min(i.skip+i.limit,n.length);if(t.push(...n.slice(i.skip,o)),i.limit===1/0)break}return t})),h=(0,i.atom)((e=>{const t=e(v),n=e(g);let i=null,o=0;for(const r of t){const{browserList:t=[],hasMore:s=!0}=(0,a.N)(e,r.itemListKey);if(o+=s?r.limit:t.length-r.skip,n.length{n.activeItemListKey&&t(p,n.activeItemListKey),n.browserListSources&&t(v,n.browserListSources)})),{useAtomService:_,useServiceState:f,useServiceDispatchers:y,getStaticApi:b}=(0,o.i)(h,((e,t)=>({registerBrowserListConfig(e){const{itemListKey:n,config:i}=e;t(u,null!=n?n:"",i)},setupBrowserList(n){var i;const{itemListKey:o,enterIndex:a}=n,r=e(d)[null!=o?o:""],l=r?e(r):null,c=[];if("explore"!==o||s()(l))c.push({itemListKey:o,skip:0,limit:1/0});else{const e=null!==(i=null==l?void 0:l.sources)&&void 0!==i?i:[];c.push(...function(e,t,n){const i={},o=[];return n.forEach((({itemListKey:n,limit:a},r)=>{var s;if(n){const l=null!==(s=i[n])&&void 0!==s?s:0,c=0===r&&n===e?t+a:a;o.push({itemListKey:n,skip:l,limit:c}),i[n]=l+c}})),o}(o,a,e))}t(p,o),t(v,c)},clearBrowserList(){t(p,null),t(v,[])},freezeSourceWithKey(n){const i=e(v),o=[];for(const t of i)if(t.itemListKey!==n)o.push(t);else{const{browserList:n=[]}=(0,a.N)(e,t.itemListKey);t.skip{"use strict";n.d(t,{$T:()=>A,bc:()=>L,YZ:()=>I,BI:()=>C,JD:()=>P});var i=n(58632),o=n(71111),a=n(31209),r=n(80417),s=n(93341),l=n(35043),c=n(92032),d=n(29909),u=n(38771),p=n(79983),v=n(52333),m=n(18538),g=n(15343),h=n(94999);const _=new WeakMap,f=e=>{const t=(e=>{if("undefined"!=typeof window){if(!_.has(e)){const t=h.l.getInstance(e);if(!t)return void console.error(`Instance has not mounted for Class: ${e.constructor.name}`);_.set(e,t)}return _.get(e)}console.warn("[Warning]: Unexpctedly get injectable instance in SSR runtime, will return null instead.")})(g.AU);null==t||t.reportVideoInteractStart({startTime:Date.now(),situation:e})};var y=n(56070),b=n(26325),w=n(22248),x=n(57381),T=n(44926),k=n(71777);const S={foryou:0,topic:0,following:0,video:0,find:1,music:1,music_new:1,challenge:1,challenge_new:1,sticker:1,effect:1,user:1,"user-post":1,"user-repost":1,"user-liked":1,search_top:1,search_video:1,question:1,playlist:1,live_event:1,video_playlist:0,create_video_playlist:0,messages:0,discover:1,poi:1,collection:1,"user-post-public":0,explore:0,channel:1,poi_category:1,search_live:1,favorites:1,"keyword-expansion":1,creator_tab:2,friends:0,trending_topics:1},E={3:"friends",2:"private",1:"public"},A=(0,o.atom)({currentIndex:0,enterIndex:0,prevFeedItemIndex:null,itemListKey:null,prevFeedItemListKey:null,jumpSamePageTime:0,belowPlayMode:0,enterWindowTimeSec:Number(new Date),showingBrowserMode:!1,isCreatorBrowserMode:!1});A.debugLabel="browserModeAtom";const O=(0,o.atom)((e=>{const{itemListKey:t}=e(A);return(0,m.N)(e,t)})),{useServiceState:P,useServiceDispatchers:I,useAtomService:C,getStaticApi:L}=(0,a.i)(A,((e,t)=>({setItemListKey(e){t(A,(t=>Object.assign(Object.assign({},t),{itemListKey:e})))},setCurrentIndex(e){t(A,(t=>Object.assign(Object.assign({},t),{currentIndex:e})))},setClickSamePage(){t(A,(e=>Object.assign(Object.assign({},e),{jumpSamePageTime:Date.now()})))},setShowingBrowserMode(e){t(A,(t=>Object.assign(Object.assign({},t),{showingBrowserMode:e})))},updateVideoIndexAndSavePrev({newFeedIndex:n,isIndexInvalid:i,newId:o,playProgress:a,itemListKey:r,currentIndex:l,newItemListKey:c,playMode:d}){if(i)return;const{isMiniPlayerShowing:u}=e(k.az);if(t(A,(e=>Object.assign(Object.assign({},e),{itemListKey:c,currentIndex:n,prevFeedItemIndex:l,prevFeedItemListKey:r}))),u)return(0,k.uZ)().setItemListKey("creator_tab"),void(0,k.uZ)().updateVideoIndex({newIndex:n,newId:o});const p={currentVideo:{index:n,id:o,mode:d},playProgress:null!=a?a:0};(0,s.LM)().updateVideo(p)},handleEnterCreatorMode(n){var i;try{f("enter_creator_mode");const{creatorFeedIndex:o}=n,{itemListKey:a,currentIndex:r}=e(A),s=e(T.o1),l=!s.length,c=null!==(i=s[o])&&void 0!==i?i:"";this.updateVideoIndexAndSavePrev({newFeedIndex:o,isIndexInvalid:l,newId:c,itemListKey:a,currentIndex:r,newItemListKey:"creator_tab",playMode:2}),t(A,(e=>Object.assign(Object.assign({},e),{isCreatorBrowserMode:!0})))}catch(e){}},handleExitCreatorMode(){var n;try{f("exit_creator_mode");const{prevFeedItemIndex:i,prevFeedItemListKey:o}=e(A),a=e(T.OB),r=null!=i?i:0,l=!a.length,c=null!==(n=a[r])&&void 0!==n?n:"";this.handleClearCreatorModeData({newIndex:r,isIndexInvalid:l,prevFeedItemListKey:o});const d={currentVideo:{index:r,id:c,mode:2},playProgress:0};(0,s.LM)().updateVideo(d),t(A,(e=>Object.assign(Object.assign({},e),{isCreatorBrowserMode:!1})))}catch(e){}},handleCreatorModeVideoClick(t){var n;try{f("click_creator_video");const{creatorFeedIndex:i}=t,{isMiniPlayerShowing:o}=e(k.az),a=e(T.o1),r=!a.length,s=null!==(n=a[i])&&void 0!==n?n:"";o?(0,k.uZ)().updateVideoIndex({newIndex:i,newId:s}):this.updateVideoIndex({newIndex:i,newId:s,isIndexInvalid:r})}catch(e){}},updateVideoIndex(n){const{newIndex:i,isIndexInvalid:o,newId:a,playProgress:r}=n,{isMiniPlayerShowing:c}=e(k.az),{itemListKey:d}=e(A);if(o)return;if(t(A,(e=>Object.assign(Object.assign({},e),{currentIndex:i}))),c)return;const u={currentVideo:{index:i,id:a,mode:2},playProgress:null!=r?r:0,pageType:d?l.FB[d]:999};(0,s.LM)().updateVideo(u)},updateDeleteVideo(n){const{currentIndex:i}=e(A),o=e(T.OB),a=o.length,r=a-1<=0,s=a-1===i,l=r?"":o[s?i-1:i+1],u=s?i-1:i;if(n){this.updateVideoIndex({newIndex:u,newId:l,isIndexInvalid:r});const e=(0,c.Ds)(),i=(0,d.HG)();e.setDeleteVideo(n),i.setDeleteVideo(n),t(p.D,"setDeleteVideo",n),t(v.t,"setDeleteVideo",n)}},handleClearCreatorModeData(e){const{prevFeedItemListKey:n,newIndex:i,isIndexInvalid:o}=e;o||t(A,(e=>Object.assign(Object.assign({},e),{currentIndex:i,itemListKey:n,prevFeedItemIndex:null,prevFeedItemListKey:null})))},postVideoDelete(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const t=(0,x.o)();try{const{status_code:n,status_msg:o}=yield function(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){return y.h.post("/api/aweme/delete/",{query:Object.assign(Object.assign({},e),{tt_csrf_token:y.h.csrfToken}),headers:{[b.nk]:y.h.csrfToken},baseUrlType:2})}))}(e);t.setBrowserModeStatus({statusCode:n,statusMessage:o,action:"delete"}),0===n&&(r.y.handleVideoDelete("delete"),this.updateDeleteVideo(e.aweme_id))}catch(e){t.setBrowserModeStatus({statusCode:-1,statusMessage:""})}}))},postScheduleDelete(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const t=(0,x.o)();try{yield function(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){return y.h.post("/api/schedule/aweme/delete/",{query:e,headers:{[b.nk]:y.h.csrfToken},baseUrlType:2})}))}({aweme_id:e}),t.setBrowserModeStatus({statusCode:0,statusMessage:"",action:"delete"}),this.updateDeleteVideo(e),r.y.handleScheduleDelete("delete")}catch(e){t.setBrowserModeStatus({statusCode:-1,statusMessage:""})}}))},postDuetOrStitchChange({type:e,enable:n,aweme_id:o}){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const a=(0,x.o)();try{const{status_code:s}=yield function(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){return y.h.post("/api/aweme/set/react_duet_stitch/",{query:Object.assign(Object.assign({},e),{tt_csrf_token:y.h.csrfToken}),headers:{[b.nk]:y.h.csrfToken},baseUrlType:2})}))}({aweme_id:o,[e]:n});if(0!==s)a.setBrowserModeStatus({statusCode:s,statusMessage:""}),2054===s&&this.updateDeleteVideo(o);else{r.y.handlePrivateSetting({target:e,to_status:n?"on":"off"});const i="item_duet"===e?"duetEnabled":"stitchEnabled";t(v.t,"updateItem",{id:o,[i]:0===n})}}catch(e){a.setBrowserModeStatus({statusCode:-1,statusMessage:""})}}))},postModifyVisibility(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const n=(0,x.o)();try{const{status_code:o,status_msg:a}=yield function(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){return y.h.post("/api/aweme/modify/visibility/",{query:Object.assign(Object.assign({},e),{tt_csrf_token:y.h.csrfToken}),headers:{[b.nk]:y.h.csrfToken},baseUrlType:2})}))}(e);0!==o?(n.setBrowserModeStatus({statusCode:o,statusMessage:a}),2054===o&&this.updateDeleteVideo(e.aweme_id)):(r.y.handleSelectPrivacySettingVideo({to_status:E[e.type]}),(0,w.G)(o,[0]),t(v.t,"setItemPrivateState",{id:e.aweme_id,visibility:e.type}))}catch(e){n.setBrowserModeStatus({statusCode:-1,statusMessage:""})}}))},postUserSetting(e){var n,o;return(0,i.__awaiter)(this,void 0,void 0,(function*(){const a=(0,x.o)();try{const{status_code:s}=yield function(e){return(0,i.__awaiter)(this,void 0,void 0,(function*(){return y.h.post("/api/user/set/settings/",{baseUrlType:2,query:Object.assign(Object.assign({},e),{tt_csrf_token:y.h.csrfToken}),headers:{[b.nk]:y.h.csrfToken}})}))}(e);0!==s?(a.setBrowserModeStatus({statusCode:s,statusMessage:""}),2054===s&&this.updateDeleteVideo(null!==(n=e.aweme_id)&&void 0!==n?n:"")):(r.y.handlePrivateSetting({target:"comment",to_status:0===e.private_setting?"on":"off"}),t(v.t,"updateItem",{id:null!==(o=e.aweme_id)&&void 0!==o?o:"",itemCommentStatus:e.private_setting}))}catch(e){a.setBrowserModeStatus({statusCode:-1,statusMessage:""})}}))},closeBrowserMode(n){var i;const{playProgress:o=0,shouldPause:a=!1}=null!=n?n:{},{itemListKey:r,currentIndex:c,belowPlayMode:d,isCreatorBrowserMode:u,prevFeedItemIndex:p,prevFeedItemListKey:v,afterCloseBrowserMode:m}=e(A),g=u?null!=v?v:"":null!=r?r:"",h=u?null!=p?p:0:c,_=e(T.OB),{list:f}=e(O),y=!_.length,b=null!==(i=_[h])&&void 0!==i?i:"",w=f.findIndex((e=>b===e));u&&(t(A,(e=>Object.assign(Object.assign({},e),{isCreatorBrowserMode:!1}))),this.handleClearCreatorModeData({prevFeedItemListKey:g,newIndex:h,isIndexInvalid:y}));const x={currentVideo:{index:a?-1:w,id:a?"":b,mode:null!=d?d:S[g],pageType:g?l.FB[g]:999},playProgress:o};(0,s.LM)().updateVideo(x),null==m||m(),t(A,(e=>Object.assign(Object.assign({},e),{showingBrowserMode:!1,belowPlayMode:null,afterCloseBrowserMode:void 0}))),(0,T.LV)().clearBrowserList()},showBrowserMode(n){const{index:i=0,playProgress:o=0,belowPlayMode:a,forceUseIndexLocation:r,shouldUsePreviousProgress:s=!1,afterCloseBrowserMode:l}=n,{browserList:c,list:d}=e(O),p=d[i],v=e(u.jD)[p],{currentTime:m}="video"===(null==v?void 0:v.contentType)?v:{currentTime:0},g=r?i:Math.max(0,Math.min(c.length-1,c.findIndex((e=>p===e)))),{itemListKey:h}=e(A),{isMiniPlayerShowing:_}=e(k.az);(0,T.LV)().setupBrowserList({itemListKey:h,enterIndex:g}),_&&(0,k.uZ)().setPrevPlayMode(2),this.updateVideoIndex({newIndex:g,newId:p,isIndexInvalid:!1,playProgress:s?m:o}),t(A,(e=>Object.assign(Object.assign(Object.assign({},e),a?{belowPlayMode:a}:{}),{afterCloseBrowserMode:l,showingBrowserMode:!0,enterIndex:g})))},handleNextVideo(){var t;try{f("browser_mode_next");const{currentIndex:n,isCreatorBrowserMode:i}=e(A),o=e(i?T.o1:T.OB),{liveCardDisplay:a}=e(O),r=e(v.t),{isMiniPlayerShowing:s}=e(k.az),l=(0,m.A)(n,o,r,a,"next"),c=!o.length||l<0,d=null!==(t=o[l])&&void 0!==t?t:"";if(c)return void console.warn("cannot switch to next video for some reasons");s?(0,k.uZ)().handleNextVideo():this.updateVideoIndex({newIndex:l,newId:d,isIndexInvalid:!1})}catch(e){}},handlePrevVideo(){var t;try{f("browser_mode_prev");const{currentIndex:n,isCreatorBrowserMode:i}=e(A),o=e(O),a=e(i?T.o1:T.OB),{liveCardDisplay:r}=o,s=e(v.t),{isMiniPlayerShowing:l}=e(k.az),c=(0,m.A)(n,a,s,r,"prev"),d=!a.length||c>a.length-1,u=null!==(t=a[c])&&void 0!==t?t:"";if(d)return void console.warn("cannot switch to prev video for some reasons");l?(0,k.uZ)().handlePrevVideo():this.updateVideoIndex({newIndex:c,newId:u,isIndexInvalid:!1})}catch(e){}},getAdjacentVideoInfo(){const{currentIndex:t,isCreatorBrowserMode:n}=e(A),i=e(n?T.o1:T.OB);return[i[t-1],i[t+1]].map((e=>null!=e?e:0))}})))},57381:(e,t,n)=>{"use strict";n.d(t,{W:()=>l,o:()=>s});var i=n(71111),o=n(31209);const a={statusCode:0,statusMessage:"",toastNotShown:!1},r=(0,i.atom)(Object.assign({},a)),{getStaticApi:s,useAtomService:l}=(0,o.i)(r,((e,t)=>({setBrowserModeStatus(e){t(r,Object.assign(Object.assign({},e),{toastNotShown:!0}))},clearBrowserModeStatus(){t(r,Object.assign({},a))}})))},18538:(e,t,n)=>{"use strict";n.d(t,{A:()=>r,N:()=>s});var i=n(92597),o=n(68783),a=n(79983);const r=(e,t,n,i,a)=>{var r,s;let l="next"===a?e+1:e-1;if(1===i){const i=null!==(r=t[l])&&void 0!==r?r:"";let c=(0,o.Jl)(n[i]);for(;c;){l="next"===a?l+1:l-1;const i=null!==(s=t[l])&&void 0!==s?s:"";if(c=(0,o.Jl)(n[i]),l>t.length-1||l<0||""===i)return e}}return Math.max(Math.min(l,t.length-1),0)},s=(e,t)=>{var n;const o=(0,i.D)(t);return o?e(o):null!==(n=e(a.D)[null!=t?t:""])&&void 0!==n?n:{}}},67805:(e,t,n)=>{"use strict";n.d(t,{BL:()=>l,MM:()=>s,nf:()=>r});var i=n(58305),o=n(67823);const a={METHOD:"last_login_success_method",TIMESTAMP:"last_login_success_timestamp",TRACKING_INFO:"last_login_success_tracking_info",ENTER_TYPE:"last_login_enter_type"},r=new class{constructor(){this.MAX_CLICK_TIMESTAMP_THRESHOLD_SECONDS=1e4,this.hasDurationSinceClickTimestampUsed=!1}populateTrackingInfoFromSessionStorage(){const e=(0,i.Qy)("login_btn_click_timestamp")||void 0,t=e?Number(e):void 0,n=void 0!==t&&Date.now()-t>this.MAX_CLICK_TIMESTAMP_THRESHOLD_SECONDS,o=(0,i.Qy)("login_tracking_info")||void 0,a=(0,i.Qy)("login_send_info_back_after_success")||void 0;if(n)return this.resetTrackingProps();let r;if(o)try{r=JSON.parse(o)}catch(e){console.log("Parse tracking info from session storage failed",e)}if(this.setTrackingInfo(r),this.setClickToLoginTimestamp(t),this.setHasDurationSinceClickTimestampUsed(!1),r){const e="1"===a;this.setSendInfoBackAfterLoginSuccess(e)}}setTrackingInfo(e){this.trackingInfo=e}getTrackingInfo(){return this.trackingInfo}setClickToLoginTimestamp(e){this.clickToLoginTimestamp=e}getClickToLoginTimestamp(){return this.clickToLoginTimestamp}setSendInfoBackAfterLoginSuccess(e){this.sendInfoBackAfterLoginSuccess=e}getSendInfoBackAfterLoginSuccess(){return this.sendInfoBackAfterLoginSuccess}resetTrackingProps(){this.trackingInfo=void 0,this.clickToLoginTimestamp=void 0,this.sendInfoBackAfterLoginSuccess=void 0,this.hasDurationSinceClickTimestampUsed=!1,this.loginSuccessPlatform=void 0,this.loginSuccessEnterType=void 0}setHasDurationSinceClickTimestampUsed(e){this.hasDurationSinceClickTimestampUsed=e}getDurationSinceClickTimestampOnce(){if(!this.hasDurationSinceClickTimestampUsed)return this.hasDurationSinceClickTimestampUsed=!0,void 0!==this.clickToLoginTimestamp?Date.now()-this.clickToLoginTimestamp:void 0}saveLoginSuccessInfo({teaPlatform:e,isSignUp:t}){this.trackingInfo&&(this.loginSuccessPlatform=e,this.loginSuccessEnterType=t?"click_sign_up":"click_login")}getLoginSuccessE2ETrackingProps(){if(this.trackingInfo&&this.sendInfoBackAfterLoginSuccess)return{trackingInfo:this.trackingInfo,successTimestamp:Date.now(),successEnterType:this.loginSuccessEnterType,successMethod:this.loginSuccessPlatform}}setUpLoginSuccessE2ETracking(){if(!this.trackingInfo||!this.sendInfoBackAfterLoginSuccess)return;const{TIMESTAMP:e,METHOD:t,TRACKING_INFO:n,ENTER_TYPE:r}=a;(0,i.J2)(e,Date.now().toString()),(0,i.J2)(n,JSON.stringify(this.trackingInfo)),this.loginSuccessEnterType&&(0,i.J2)(r,this.loginSuccessEnterType),this.loginSuccessPlatform&&(0,i.J2)(t,this.loginSuccessPlatform),o.A.set("TT_rp_login_track_pram","1",{path:"/",domain:"tiktok.com",secure:!1,sameSite:"lax","max-age":"4"})}},s={CLICK_TIMESTAMP:"logout_btn_click_timestamp",TRACKING_INFO:"logout_tracking_info"},l=new class{constructor(){this.MAX_CLICK_TIMESTAMP_THRESHOLD_SECONDS=1e4}populateTrackingInfoFromSessionStorage(){const e=(0,i.Qy)(s.CLICK_TIMESTAMP)||void 0,t=e?Number(e):void 0,n=void 0!==t&&Date.now()-t>this.MAX_CLICK_TIMESTAMP_THRESHOLD_SECONDS,o=(0,i.Qy)(s.TRACKING_INFO)||void 0;if(n)return;let a;if(console.log({trackingInfoJsonStr:o}),o)try{a=JSON.parse(o)}catch(e){console.log("Parse logout tracking info from session storage failed",e)}this.trackingInfo=a}getTrackingInfo(){return this.trackingInfo}}},71777:(e,t,n)=>{"use strict";n.d(t,{Dy:()=>h,Sp:()=>_,az:()=>v,mE:()=>g,uZ:()=>f});var i=n(58632),o=n(71111),a=n(31209),r=n(91257),s=n(93341),l=n(18538),c=n(19442),d=n(44926),u=n(93608);const p={isDocumentPipSupporting:"undefined"!=typeof window&&"documentPictureInPicture"in window&&function(){const e=navigator.userAgent.match(/Chrom(?:e|ium)\/([0-9]+)\./),t=e?Number(e[1]):-1;return t>=126&&133!==t}(),pipWindow:null,isMiniPlayerShowing:!1,itemListKey:null,currentIndex:0,prevPlayMode:null,miniPlayerRef:null,svgChangeObserver:null,enterTimestamp:0,windowHeight:598,windowWidth:306},v=(0,o.atom)(p);v.debugLabel="miniPlayerAtom";const m=(0,o.atom)((e=>{const{itemListKey:t}=e(v);return(0,l.N)(e,t)})),{useServiceState:g,useServiceDispatchers:h,useAtomService:_,getStaticApi:f}=(0,a.i)(v,((e,t)=>({setItemListKey(e){t(v,(t=>Object.assign(Object.assign({},t),{itemListKey:e})))},setCurrentIndex(e){t(v,(t=>Object.assign(Object.assign({},t),{currentIndex:e})))},setPrevPlayMode(e){t(v,(t=>Object.assign(Object.assign({},t),{prevPlayMode:e})))},setIsMiniPlayerShowing(e){t(v,(t=>Object.assign(Object.assign({},t),{isMiniPlayerShowing:e})))},setMiniPlayerRef(e){t(v,(t=>Object.assign(Object.assign({},t),{miniPlayerRef:e})))},setIsLandingIndicatorDismissed(e){t(v,(t=>Object.assign(Object.assign({},t),{isLandingIndicatorDismissed:e})))},initEnableNewLocalStorageKey(){t(v,(e=>Object.assign(Object.assign({},e),{enableNewLocalStorageKey:!1})))},setIsAfterSwitchTabOrWindowSizeChange(e){t(v,(t=>Object.assign(Object.assign({},t),{isAfterSwitchTabOrWindowSizeChange:e})))},setIsAfterSwitchTabOrWindowSizeChangeIndicatorDismissed(e){t(v,(t=>Object.assign(Object.assign({},t),{isAfterSwitchTabOrWindowSizeChangeIndicatorDismissed:e})))},updateMiniPlayerSize(){const{pipWindow:n}=e(v);if(!n)return;const i=n.innerHeight,o=n.innerWidth;t(v,(e=>Object.assign(Object.assign({},e),{windowHeight:i,windowWidth:o})))},updateVideoIndex(n){const{newIndex:i,newId:o,playProgress:a,isMiniPlayerNotSupported:r}=n,{prevPlayMode:l}=e(v);t(v,(e=>Object.assign(Object.assign({},e),{currentIndex:i})));const d={currentVideo:{index:i,id:o,mode:r?l:8},playProgress:null!=a?a:0};(0,s.LM)().updateVideo(d);const{showingBrowserMode:u}=e(c.$T);u&&(0,c.bc)().updateVideoIndex({newId:o,newIndex:i,isIndexInvalid:!1})},closeMiniPlayer(n){var i,o,a;const{playMode:l,enter_method:c}=n,{currentIndex:d,prevPlayMode:p,pipWindow:g,miniPlayerRef:h,svgChangeObserver:_,enterTimestamp:f}=e(v),{list:y=[]}=e(m),b=null!==(i=y[d])&&void 0!==i?i:"",w=y.findIndex((e=>b===e)),x=null!==(a=null===(o=null==h?void 0:h.current)||void 0===o?void 0:o.currentTime)&&void 0!==a?a:0;if(g){null==g||g.close(),u.f.sendEvent("turn_off_mini_player",{play_mode:r.Jr[null!=p?p:"-1"],group_id:b,enter_method:c,stay_duration:(Date.now()-f)/1e3,has_more:dObject.assign(Object.assign({},e),{pipWindow:null,isMiniPlayerShowing:!1,itemListKey:null,currentIndex:0,prevPlayMode:null,miniPlayerRef:null,svgChangeObserver:null,enterTimestamp:0})))}},openMiniPlayer(n){return(0,i.__awaiter)(this,void 0,void 0,(function*(){const{index:i=0,playMode:o,playProgress:a,itemListKey:p}=n,{pipWindow:m,isDocumentPipSupporting:g,windowHeight:h,windowWidth:_}=e(v);if(!g||"undefined"==typeof window||null!==m)return;const{list:f}=(0,l.N)(e,p),{showingBrowserMode:y,isCreatorBrowserMode:b}=e(c.$T),{browserList:w}=e(d.JV),x=y&&!b?w[i]:f[i];try{const e=Date.now();documentPictureInPicture.addEventListener("enter",(()=>{u.f.sendEvent("enter_mini_player",{latency:Date.now()-e,play_mode:r.Jr[o],group_id:x})}),{once:!0});const n=yield window.documentPictureInPicture.requestWindow({width:_,height:h});n.addEventListener("pagehide",(()=>{this.closeMiniPlayer({playMode:o})}),{once:!0}),[...document.styleSheets].forEach((e=>{try{const t=[...e.cssRules].map((e=>e.cssText)).join(""),i=document.createElement("style");i.textContent=t,n.document.head.appendChild(i)}catch(t){const i=document.createElement("link");if(null===e.href)return;i.rel="stylesheet",i.type=e.type,i.media=e.media.toString(),i.href=e.href,n.document.head.appendChild(i)}})),this.createOrUpdateSVGSprite(n);const l=document.querySelector("#svg-sprite-container"),c=new MutationObserver((()=>this.createOrUpdateSVGSprite(n)));l&&c.observe(l,{subtree:!0,childList:!0});const d={currentVideo:{index:i,id:x,mode:8},playProgress:a};(0,s.LM)().updateVideo(d),t(v,(e=>Object.assign(Object.assign({},e),{enterTimestamp:Date.now(),itemListKey:p,prevPlayMode:o,isMiniPlayerShowing:!0,currentIndex:i,pipWindow:n,svgChangeObserver:c})))}catch(e){console.error("DocumentPIP error",e)}}))},createOrUpdateSVGSprite(e){const t=document.querySelector("#svg-sprite-container");try{let n=e.document.body.querySelector("svg");n||(n=document.createElement("svg"),e.document.body.appendChild(n)),n.innerHTML=(null==t?void 0:t.outerHTML)||""}catch(e){console.log("error to copy svg sprite",e)}},handleNextVideo(){var t;try{const{currentIndex:n}=e(v),{list:i}=e(m),o=n+1,a=null!==(t=i[o])&&void 0!==t?t:"";if(!i.length||o<0||o>=i.length)return void console.warn("cannot switch to next video for some reasons");this.updateVideoIndex({newIndex:o,newId:a})}catch(e){}},handlePrevVideo(){var t;try{const{currentIndex:n}=e(v),{list:i}=e(m),o=n-1,a=!i.length||o<0||o>=i.length,r=null!==(t=i[o])&&void 0!==t?t:"";if(a)return void console.warn("cannot switch to prev video for some reasons");this.updateVideoIndex({newIndex:o,newId:r})}catch(e){}}})))},6523:(e,t,n)=>{"use strict";n.d(t,{Tx:()=>S,lF:()=>T,M0:()=>k,Nk:()=>P,yq:()=>E,O9:()=>x,wW:()=>O,dY:()=>A});var i=n(25616),o=n(10828),a=n(7971),r=n(46682),s=n(41271),l=n(39785),c=n(15203),d=n(91498);const u=(0,l.M)({csr:()=>(0,c.q)()}),p=(0,l.M)({csr:()=>(0,d.o7)()});var v=n(56013),m=n(97086),g=n(71281),h=n(60484),_=n(48615),f=n(40099),y=n(32125),b=n(49799),w=n(50789);const x=(e,t,n)=>{if(!e||e===t||(0,m.fU)()||133===n)return;const i=location.pathname.replace(/[^\/]+$/,e),a=`${o.C}/${i}${location.search}`,r=Object.assign(Object.assign({},history.state),{as:a});window.history.replaceState(r,"format_kap_page",a)},T=e=>{const t=O();return(0,a.zh)(e,t)},k=({keyword:e,relatedWordList:t})=>{const n=(0,g.TQ)("kep_remove_desc_keywords"),o=(0,i.s)(),r=(0,f.useMemo)((()=>(({keyword:e,keywordList:t,removeRelatedKeywords:n,t:i})=>{const o=`${i("seo_serp_expansion_num1",{expansion_keywords:(0,a.zh)(e)})}`;if(n)return o;const r=(0,a.gW)(t);return`${o}${r?` ${i("seo_aggre_metadesc2",{related_search_keywords:r})}`:""}`})({keyword:e,keywordList:t.map((e=>e.formattedWord)),t:o,removeRelatedKeywords:n})),[e,o,t]);return r};function S(e){const{pageType:t,topic:n,language:i="en"}=e,o=(0,r.w)(b.E);(0,f.useEffect)((()=>{o.setFeedSEOProps({pageType:t,topic:n,language:i})}),[o,t,n,i])}function E(){return(0,f.useMemo)((()=>p()),[])}function A(){return(0,f.useMemo)((()=>u()),[])}function O(){const e=(0,s.P)(w.p,{selector:e=>e.abtest,dependencies:[]});return(0,v.d7)((e=>e.abtest),{equalityFn:y.bN})||e}function P(){const{isBot:e}=(0,h.L$)((0,_.U)((()=>["isBot"]),[]));return Boolean(e)}},49799:(e,t,n)=>{"use strict";n.d(t,{E:()=>be});var i=n(58632),o=n(4126),a=n(93995),r=n(340),s=(n(72828),n(80339)),l=n(95719),c=n(23999),d=n(63700),u=n(26324),p=n(8536),v=n(35572),m=n(20259),g=n(62564),h=n(24451),_=n(17354),f=n(72916),y=n(53966),b=n(55734),w=n(77878),x=n(95584),T=n(13761),k=n(10828),S=n(30251),E=n(53038);const A=[{processType:T.k.SERPProcessType.META_PATH,targetId:103,content:function(e){const{t}=e,n=[t("SERP discover title"),t("TikTok i18n keywords")].join(",");return{title:t("SEO_discover_title"),keywords:n,description:t("SEO_discover_desc"),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}/discover`,applicableDevice:"pc, mobile"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:103,content:function(e){const{language:t="en"}=e,n={"@id":S.er,url:S._0,name:S.UN,description:S.OZ,publisher:(0,E.xM)(k.C,t)},i=(0,E.SH)([{url:k.C,name:S.e4},{url:S._0,name:S.UN}]);return[[x.Y.JsonldType.WebSite,n],[x.Y.JsonldType.BreadcrumbList,i]]}}],O=[{processType:T.k.SERPProcessType.META_PATH,targetId:11,content:function(e){const{language:t="en",t:n}=e;return{title:n("SEO_following_title"),keywords:n("TikTok i18n keywords"),description:n("SEO_following_desc"),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.Cb}?lang=${t}`,applicableDevice:"pc, mobile"}}}];var P=n(35047),I=n(93809),C=n(75486),L=n(95098),j=n(46859),M=n(61679),N=n(67982);const D=[{processType:T.k.SERPProcessType.META_PATH,targetId:16,content:function(e){const{questionInfo:t,t:n}=e,i=(0,j.F)(e),{id:o="",content:a="",videoCount:r}=null!=t?t:{},s=i&&a&&o,l=s?n("SEO_qa_title_1",{question:a}):"",c=[n("TikTok i18n keywords")].join(","),d=s?n("SEO_qa_desc_1",{question:a,number:(0,M.D1)(r)}):"",u=(0,N.WD)({questionContent:a,questionId:o});return{title:l,keywords:c,description:d,canonicalHref:s?`${k.C}${u}`:"",robotsContent:s?S.kl.INDEX:S.kl.NO_INDEX,applicableDevice:"pc, mobile"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:16,content:function(e){const{questionInfo:t,seoProps:n}=e,{itemList:i,metaParams:o}=null!=n?n:{},{id:a="",content:r=""}=null!=t?t:{},s=(0,j.F)(e)&&r&&a,{title:l}=null!=o?o:{},c=(0,N.WD)({questionContent:r,questionId:a}),d=`${k.C}${c}`,u=null!=l?l:`${r} | TikTok Q&A`,p={"@type":"ItemPage","@id":d},v=(0,E.SH)(s?[{url:k.C,name:S.e4},{url:d,name:u}]:[{url:k.C,name:S.e4}]);return[[x.Y.JsonldType.Page,p],[x.Y.JsonldType.ItemList,null!=i?i:{}],[x.Y.JsonldType.BreadcrumbList,v]]}}],R=[{processType:T.k.SERPProcessType.META_PATH,targetId:105,content:function(e){const{pathname:t="/search",input_keyword:n,t:i}=e,o=i("SEO_search_title",{searchkeywords:`'${n}'`}),a=i("SEO_search_desc",{searchkeywords:`'${n}'`});return{title:o,keywords:[n,"tiktok search",i("TikTok i18n keywords")].join(","),description:a,robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${t}?q=${n}`,applicableDevice:"pc, mobile"}}}];var B=n(49336),U=n(93639);const F=[{processType:T.k.SERPProcessType.META_PATH,targetId:116,content:function(e){const{language:t="en",t:n}=e;return{title:n("SEO_Recharge_title"),keywords:"recharge, coins recharge, get coins, TikTok, ティックトック, tik tok, tick tock, tic tok, tic toc, tictok, тик ток, ticktock",description:n("SEO_Recharge_desc"),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.Gj}?lang=${t}`,applicableDevice:"pc, mobile"}}}],V=[{processType:T.k.SERPProcessType.META_PATH,targetId:111,content:function(e){const{language:t="en",t:n,contentInfo:i,eventName:o}=e;return{title:i?n("search_on_tiktok",{eventname:null==i?void 0:i.query,ns:"MT_Reflow"}):n("offline_title",{ns:"MT_Reflow"}),keywords:`${n("landing_page_key_word_1",{ns:"MT_Reflow"})},${null==i?void 0:i.query}`,description:i?n("outapp_copywriter",{eventname:null==i?void 0:i.query,ns:"MT_Reflow"}):n("expiration_reminder",{ns:"MT_Reflow"}),robotsContent:S.kl.INDEX,canonicalHref:`${S.TB}/${o}?lang=${t}`,applicableDevice:"pc, mobile"}}}];function z(e){return/^\/tag\/.+/.test(e)}const H=[{processType:T.k.SERPProcessType.META_PATH,targetId:104,content:function(e){const{keyword:t,t:n,detailResponse:i,pathname:o=""}=e,{word:{content:a=""}={language:void 0}}=null!=i?i:{},r=a.replace(/-/g," ");return{title:n("seo_serp_expansion_title",{expansion_keywords:r}),keywords:`${r}, ${n("TikTok i18n keywords")}`,description:`${n("seo_serp_expansion_num1",{expansion_keywords:r})}`,canonicalHref:q(t,o),robotsContent:"index, follow",applicableDevice:"pc, mobile"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:104,content:function(e){var t,n;const{keyword:i="",seoProps:{itemList:o,abtest:a}={},pathname:r=""}=e,s=z(r)?`${S.sF}/${i}`:`${S._0}/${i}`,l=z(r)?S.sF:S._0,c=null!==(n=null===(t=null==a?void 0:a.parameters.kep_collection_page_modified_date)||void 0===t?void 0:t.vid)&&void 0!==n?n:"v0",d=z(r)?"Challenge":S.W4,u=(0,E.tl)(c,q(i,r)),p=(0,E.SH)([{url:k.C,name:S.e4},{url:l,name:d},{url:s,name:i}]);return[[x.Y.JsonldType.Page,u],[x.Y.JsonldType.BreadcrumbList,p],[x.Y.JsonldType.ItemList,null!=o?o:{}]]}}];function q(e,t){return/^\/tag\/.+/.test(t)?`${S.sF}/${e}`:`${S._0}/${e}`}const G=[{processType:T.k.SERPProcessType.META_PATH,targetId:14,content:function(e){var t;const{language:n="en",t:i,user:o}=e,a=null!==(t=null==o?void 0:o.uniqueId)&&void 0!==t?t:"",r=[null==o?void 0:o.nickName,`@${a}`,"live","live room","tiktok search",i("TikTok i18n keywords")].join(", ");return{title:i("SEO_live_title",{username:a}),keywords:r,description:i("SEO_live_title",{username:a}),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.yI}?lang=${n}`,applicableDevice:"pc, mobile"}}}],$=[{processType:T.k.SERPProcessType.META_PATH,targetId:15,content:function(e){const{t}=e;return{title:t("SEO_live_discover_title"),keywords:"live, live stream, TikTok, ティックトック, tik tok, tick tock, tic tok, tic toc, tictok, тик ток, ticktock",description:t("SEO_live_discover_desc"),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.Zt}`,applicableDevice:"pc, mobile"}}}],W=[{processType:T.k.SERPProcessType.META_PATH,targetId:12,content:function(e){var t,n,i,o;const{t:a,userInfo:r,LiveRoomInfo:s,event:l}=e,c=null!==(t=null==s?void 0:s.title)&&void 0!==t?t:"",d=null==s?void 0:s.status,u=null!==(i=null===(n=null==r?void 0:r.user)||void 0===n?void 0:n.uniqueId)&&void 0!==i?i:"",p=null===(o=null==r?void 0:r.user)||void 0===o?void 0:o.nickname,v=`${p} (@${u})`,m=[p,`@${u}`,"live","live room","tiktok search",a("TikTok i18n keywords")].join(", "),g=(0,N.G2)({uniqueId:u}),h=`${k.C}${g}`,_=a("SEO_live_title",{username:v});let f=`${c?`${c}. `:""}${a("SEO_live_desc",{username:v})}`;return!(2===d)&&l&&(f=`${a("SEO_live_desc2",{event_name:null==l?void 0:l.title,username:v})}`),{title:_,keywords:m,description:f,robotsContent:S.kl.INDEX,canonicalHref:h,applicableDevice:"pc, mobile"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:12,content:function(e){var t,n,i,o;const{t:a,userInfo:r,seoProps:s,event:l}=e,{videoObject:c}=null!=s?s:{},d=null!==(n=null===(t=null==r?void 0:r.user)||void 0===t?void 0:t.uniqueId)&&void 0!==n?n:"",u=null!==(o=null===(i=null==r?void 0:r.user)||void 0===i?void 0:i.nickname)&&void 0!==o?o:"",p=(0,N.G2)({uniqueId:d}),v=`${k.C}${p}`,m=(0,N.fJ)({uniqueId:d}),g=`${k.C}${m}`,h=(0,N.$2)(d)?`${u} (@${d})`:`${u}`,_=l?{"@type":"Event",name:l.title,url:v,description:l.description,startDate:new Date(1e3*Number(l.startTime)).toISOString(),endDate:new Date(1e3*(Number(l.startTime)+Number(l.duration))).toISOString(),eventStatus:"http://schema.org/EventScheduled",eventAttendanceMode:"http://schema.org/OnlineEventAttendanceMode",location:{"@type":"VirtualLocation",url:v},Organizer:{"@type":"Organization",name:u,alternateName:d,url:g}}:null,f=(0,E.SH)([{url:k.C,name:S.e4},{url:g,name:h},{url:v,name:"LIVE"}]),y=[];return _&&y.push(["Event",_]),y.push(["BreadcrumbList",f]),c&&y.push(["VideoObject",null!=c?c:{}]),y}}],Z=[{processType:T.k.SERPProcessType.META_PATH,targetId:17,content:function(e){const{mc_info:t,status_code:n,t:i}=e,{id_str:o="",name:a=""}=null!=t?t:{},r=0===n&&""!==a;let s=i("playlist_sharing_metatitle",{playlist_name:a});const l=[a,i("TikTok i18n keywords")].join(",");let c=i("playlist_sharing_metadescription",{playlist_name:a});return r||(s="",c=""),{title:s,keywords:l,description:c,canonicalHref:`${S.AQ}/playlist-music/${a}-${o}`,robotsContent:r?S.kl.INDEX:S.kl.NO_INDEX,applicableDevice:"pc, mobile"}}}],{JsonldType:Y}=x.Y,K=new Map([["animals",{titleI18NKey:"SEO_foryou_animals_title",descriptionI18NKey:"SEO_foryou_animals_desc"}],["beauty",{titleI18NKey:"SEO_foryou_beauty_title",descriptionI18NKey:"SEO_foryou_beauty_desc"}],["comedy",{titleI18NKey:"SEO_foryou_comedy_title",descriptionI18NKey:"SEO_foryou_comedy_desc"}],["dance",{titleI18NKey:"SEO_foryou_dance_title",descriptionI18NKey:"SEO_foryou_dance_desc"}],["food",{titleI18NKey:"SEO_foryou_food_title",descriptionI18NKey:"SEO_foryou_food_desc"}],["gaming",{titleI18NKey:"SEO_foryou_gaming_title",descriptionI18NKey:"SEO_foryou_gaming_desc"}],["sports",{titleI18NKey:"SEO_foryou_sports_title",descriptionI18NKey:"SEO_foryou_sports_desc"}]]),X=[{processType:T.k.SERPProcessType.META_PATH,targetId:113,content:function(e){var t;const{language:n="en",t:i,topic:o}=e,{titleI18NKey:a="",descriptionI18NKey:r=""}=null!==(t=K.get(o))&&void 0!==t?t:{};return a&&r?{title:i(a),keywords:i("TikTok i18n keywords"),description:i(r),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}/topics/${o}?lang=${n}`,applicableDevice:"pc, mobile"}:{}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:113,content:function(e){const{seoProps:{itemList:t}={}}=e;return[[Y.ItemList,null!=t?t:{}]]}}],Q=[{processType:T.k.SERPProcessType.META_PATH,targetId:114,content:function(e){const{t,eventTitle:n="",eventId:i="",subscriberCount:o=""}=e;return{title:t("share_live_event_title",{"Event Topic":n}).replace("{Event Topic}",n),keywords:"live, live event, TikTok, ティックトック, tik tok, tick tock, tic tok, tic toc, tictok, тик ток, ticktock",description:t("share_live_event_desc",{number:o}),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.wk}/${i}`,applicableDevice:"pc, mobile"}}}];var J=n(82715),ee=n(77229);const te=[{processType:T.k.SERPProcessType.META_PATH,targetId:119,content:function(e){var t,n;const{t:i,mixInfo:o,statusCode:a}=e,r=0===a,s=`@${null===(t=null==o?void 0:o.creator)||void 0===t?void 0:t.uniqueId}`,l=null!==(n=null==o?void 0:o.name)&&void 0!==n?n:"Untitled playlist";return{title:i("playlist_share_title",{Playlist_name:l,username:s},`Playlist ${l} created by ${s}`),description:i("playlist_share_desc",{},"Enjoy a curated video list and find more videos on TikTok!"),canonicalHref:r?`${k.C}/${s}/playlist/${null==o?void 0:o.name}-${null==o?void 0:o.id}`:k.C,robotsContent:r?S.kl.INDEX:S.kl.NO_INDEX,applicableDevice:"mobile"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:119,content:function(e){var t,n,i,o,a,r,s;const{seoProps:{itemList:l}={},mixInfo:c,t:d}=e;if(!(null==c?void 0:c.id))return[];const u=`${k.C}${J.$T.videoPlaylist({uniqueId:null!==(n=null===(t=c.creator)||void 0===t?void 0:t.uniqueId)&&void 0!==n?n:"",content:null!==(i=c.name)&&void 0!==i?i:"",id:c.id})}`,p=`${k.C}${J.$T.user({uniqueId:null!==(a=null===(o=c.creator)||void 0===o?void 0:o.uniqueId)&&void 0!==a?a:""})}`,{creator:v}=c,m=(null==v?void 0:v.uniqueId)?`${null==v?void 0:v.nickname} (@${null==v?void 0:v.uniqueId})`:`${null==v?void 0:v.nickname}`,g=d((null===(r=c.creator)||void 0===r?void 0:r.verified)?"user_SEO_official_title1":"user_SEO_title1",{username:m}),h={"@type":"ItemPage","@id":u};return[[x.Y.JsonldType.Page,h],[x.Y.JsonldType.ItemList,null!=l?l:{}],[ee.e.type,new ee.e([{url:k.C,name:S.e4},{url:p,name:g},{url:u,name:null!==(s=c.name)&&void 0!==s?s:"playlist"}])]]}}],ne=[{processType:T.k.SERPProcessType.META_PATH,targetId:6,content:function(e){var t,n,i,o;const{stickerInfo:{sticker:a}={},t:r}=e;return a?{title:r("share_effect_title",{sticker_name:a.name}),description:r("share_sticker_desc",{sticker_desc:a.desc,number:(0,M.D1)(null!==(n=null===(t=a.stickerStats)||void 0===t?void 0:t.useCount)&&void 0!==n?n:0),num:null!==(o=null===(i=a.stickerStats)||void 0===i?void 0:i.useCount)&&void 0!==o?o:0}),robotsContent:S.kl.INDEX,canonicalHref:`${k.C}/sticker/${a.name}-${a.id}`,applicableDevice:"mobile"}:{title:r("share_sticker_preset"),description:"",robotsContent:S.kl.NO_INDEX,applicableDevice:"mobile"}}}];var ie=n(66806),oe=n(566);function ae(e,t,n){return`/${n?"place":"travel"}/${t.replace(/\s/g,"-")}-${e}`}const re=[{processType:T.k.SERPProcessType.META_PATH,targetId:18,content:function(e){var t;const{poiInfo:n,statusCode:i,t:o,isUs:a,isRegion:r,relatedWordList:s,isPlacePath:l}=e,{poi:{id:c="",name:d="",indexEnabled:u=!1}={}}=null!=n?n:{},{videoCount:p}=null!==(t=null==n?void 0:n.stats)&&void 0!==t?t:{},v=ae(c,d,l),m=`${S.AQ}${v}`,g=u?S.kl.INDEX:S.kl.NO_INDEX;if(a&&(null==n?void 0:n.poi.allLevelGeoPoiInfo)){const e=n.poi.allLevelGeoPoiInfo,t=function(e){var t,n;return(null===(t=e.L1GeoPoiInfo)||void 0===t?void 0:t.PoiName)?e.L1GeoPoiInfo.PoiName:(null===(n=e.L0PoiGeoInfo)||void 0===n?void 0:n.PoiName)?e.L0PoiGeoInfo.PoiName:""}(e),i=function(e){var t;const n=Object.keys(e);return n.length&&(null===(t=e[n[n.length-1]])||void 0===t?void 0:t.PoiName)||""}(e),a=s?(0,oe.o8)(s).splice(0,20).join(","):"",l=o("basicPoi_metaTdk_title",{poiName:d}),c=r?o("basicPoi_metaTdk_regional_desc",{videoCount:p,regionalPoiName:d}):o("basicPoi_metaTdk_store_desc",{poiName:d,l1PoiName:t,videoCount:p});return{title:l,keywords:r?o("basicPoi_metaTdk_keyword",{poiName:d,relatedKeyword:a}):o("basicPoi_metaTdk_storeSite",{poiName:d,currentRegionalPoiName:i,currentL1RegionalPoiName:t,ttTypeNameMedium:n.poi.ttTypeNameMedium,ttTypeNameSuper:n.poi.ttTypeNameSuper,ttTypeNameTiny:n.poi.ttTypeNameTiny}),description:c,canonicalHref:m,robotsContent:g,applicableDevice:"pc"}}let h=`${d} | ${o("poidetails_tiktokplaces")}`,_=`${(0,M.D1)(p)} ${o("videos_")}. ${o("poidetails_location_name_placehldtwo").replace("{ }",d)}`;switch(i){case ie.kd:case ie.oe:h=o("poisuggest_placeuna_title_1"),_="";break;case ie.k2:h=o("err_feature_unavailable"),_=""}return{title:h,keywords:"",description:_,canonicalHref:m,robotsContent:g,applicableDevice:"pc"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:18,content:function(e){var t;const{poiInfo:n,seoProps:i,t:o,isUs:a,isPlacePath:r=!1,noStructureData:s}=e,{itemList:l,metaParams:c,videoObject:d}=null!=i?i:{};if(!(null==n?void 0:n.poi)||s)return[];const{name:u="",id:p="",allLevelGeoPoiInfo:v}=null!==(t=n.poi)&&void 0!==t?t:{},{title:m}=null!=c?c:{},g=ae(p,u,r),h=`${k.C}${g}`,_=null!=m?m:`${u} | TikTok`,f={"@type":"CollectionPage","@id":h},y=(0,E.SH)([{url:k.C,name:S.e4},...a?(0,oe.Pi)(v):[],{url:h,name:_}]);return[[x.Y.JsonldType.Page,f],[x.Y.JsonldType.ItemList,null!=l?l:{}],[x.Y.JsonldType.BreadcrumbList,y],[x.Y.JsonldType.VideoObject,null!=d?d:{}]]}}];var se=n(38053);const le=[{processType:T.k.SERPProcessType.META_PATH,targetId:130,content:function(e){const{t}=e;return{title:t("pm_mt_ls_download_button"),description:t("SEO TikTok Description"),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.z6}`,applicableDevice:"pc, mobile"}}}],ce=[{processType:T.k.SERPProcessType.META_PATH,targetId:131,content:function(e){const{t}=e;return{title:t("pm_mt_ls_download_button"),description:t("SEO TikTok Description"),robotsContent:S.kl.INDEX,canonicalHref:`${S.AQ}${S.dW}`,applicableDevice:"pc, mobile"}}}];var de=n(7971);const ue=[{processType:T.k.SERPProcessType.META_PATH,targetId:132,content:function(e){var t,n;const{relatedKeywordsResponse:i,detailResponse:o,t:a}=e,{formattedWord:r="",uniqueWord:s=""}=null!==(t=null==o?void 0:o.wordDetail)&&void 0!==t?t:{};if(!s)return{robotsContent:"noindex, nofollow"};const l=(null!==(n=null==i?void 0:i.relatedKeywords)&&void 0!==n?n:[]).map((e=>e.formattedWord)),c=function(e,t){return e("seo_tts_selected_title",{s_keywords:(0,de.zh)(t)})}(a,r),d=function(e,t){return e("seo_tts_selected_desc",{s_keywords:(0,de.zh)(t)})}(a,r),u=function(e,t,n){return e("seo_tts_selected_keywords",{keywords:`${(0,de.zh)(t)}, ${pe(n).join(", ")}`})}(a,r,l);return{title:c,keywords:u,description:d,canonicalHref:`${S.IQ}/${s}`,robotsContent:"index, follow",applicableDevice:"pc, mobile"}}},{processType:T.k.SERPProcessType.JSONLD_PATH,targetId:132,content:function(e){var t,n,i;const{detailResponse:o,seoProps:{itemList:a,abtest:r}={}}=e,{uniqueWord:s=""}=null!==(t=null==o?void 0:o.wordDetail)&&void 0!==t?t:{},l=null!==(i=null===(n=null==r?void 0:r.parameters.kep_collection_page_modified_date)||void 0===n?void 0:n.vid)&&void 0!==i?i:"v0",c=(0,E.tl)(l,`${S.IQ}/${s}`);return[[x.Y.JsonldType.Page,c],[x.Y.JsonldType.ItemList,null!=a?a:{}]]}}],pe=(e,t=6)=>e.slice(0,t).map((e=>(0,de.zh)(e)));var ve=n(62456);const me=[...b.Dj,...w.F,...A,...O,...P.c,...I.I,...C.H,...L.X,...D,...R,...B.f,...U.z,...F,...V,...H,...G,...$,...W,...Z,...X,...Q,...te,...ne,...re,...oe.Nr,...se.g,...le,...ce,...ue,...ve.Hm];var ge=n(64356),he=n(99101),_e=n(19331),fe=n(50789);const ye=[...me];let be=class extends y.E{constructor(e,t,n,i){super(),this.stateModule=e,this.service=t,this.sharingMeta=n,this.t=i,this.defaultState={}}updateSEOState(e){const{metaParams:t={},jsonldList:n=[],disableAlternateLink:i=!1,generateAlternateWithCanonical:o}=e;this.stateModule.updateAtom({metaParams:t,jsonldList:n,disableAlternateLink:i,generateAlternateWithCanonical:o})}setPCMusicSEOProps(e){return e.pipe((0,p.Z)((({response:e,language:t,appType:n})=>this.setMusicSEOProps(e,{language:t},n).pipe((0,s.q)(this.terminate("setPCMusicSEOProps"))))))}setFeedSEOProps(e){return e.pipe((0,v.p)((e=>{const{pageType:t,topic:n,topicType:i,language:o}=e,a={seoProps:{pageId:"",pageType:t},topic:n,topicType:i,language:o};return this.service.fetchSEOProps(a,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((()=>(0,c.of)(this.terminate()))),(0,m.W)((e=>(0,c.of)(this.noop(),this.terminate()))))})))}setGoLiveSEOProps(e){return e.pipe((0,v.p)((({language:e,user:t})=>{const n={seoProps:{pageId:"",pageType:14},user:t,language:e,t:this.t};return this.service.fetchSEOProps(n,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((()=>(0,c.of)(this.terminate()))),(0,m.W)((()=>(0,c.of)(this.noop()))))})))}setHomeSEOProps(e){return this.service.fetchSEOProps({seoProps:{pageId:"",pageType:101},language:e},ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((()=>(0,d.h)((0,c.of)(this.sharingMeta.setSharingMetaState({"og:image":k.U}))))))}setForyouSEOProps(e,t){if(-1===e.statusCode)return(0,c.of)(this.noop());const n=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageType:5},t:this.t});return this.service.fetchSEOProps(n,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,g.T)((()=>this.noop())))}setVideoSEOProps(e,t,n,i,o){var a,r,s,u,v,m,g,y;if(-1===e.statusCode)return(0,c.of)(this.noop());const b=null!==(s=null===(r=null===(a=null==e?void 0:e.itemInfo)||void 0===a?void 0:a.itemStruct)||void 0===r?void 0:r.id)&&void 0!==s?s:"",w=null!==(y=null===(g=null===(m=null===(v=null===(u=null==e?void 0:e.itemInfo)||void 0===u?void 0:u.itemStruct)||void 0===v?void 0:v.author)||void 0===m?void 0:m.bioLink)||void 0===g?void 0:g.link)&&void 0!==y?y:"";return(0,c.of)(e).pipe((0,h.E)(this.stateModule.state$.pipe((0,_.p)((e=>void 0!==e.abtest)))),(0,p.Z)((([a,r])=>{const s=Object.assign(Object.assign(Object.assign({},e),t),{transcriptContent:o,bioLink:w,seoProps:{pageId:b,pageType:0,abtest:r.abtest},t:this.t});return this.service.fetchSEOProps(s,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,f.n)((t=>(0,d.h)(this.sharingMeta.setVideoSharingMeta(t,e,n,i)))))})))}setCollectionSEOProps(e,t,n,i,o){var a,r,s;const u=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageId:null!==(s=null===(r=null===(a=e.collectionInfo)||void 0===a?void 0:a.collectionId)||void 0===r?void 0:r.toString())&&void 0!==s?s:"",pageType:121},t:this.t,items:o});return this.service.fetchSEOProps(u,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,f.n)((()=>{var t,o,a;return(0,d.h)(i?(0,c.of)(this.noop()):this.sharingMeta.setCollectionSharingMeta(e,n,null!==(a=null===(o=null===(t=null==e?void 0:e.collectionInfo)||void 0===t?void 0:t.collectionId)||void 0===o?void 0:o.toString())&&void 0!==a?a:""))})))}setSearchSharingSEOProps(e,t,n,i){if(-1===e.statusCode)return(0,c.of)(this.noop());const o=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageType:111},eventName:n,t:this.t});return this.service.fetchSEOProps(o,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((t=>(0,d.h)(this.sharingMeta.setSearchSharingMeta(t,e,n,i)))))}setQuestionSEOProps(e,t,n,i,o,a){var r;if(-1===e.statusCode)return(0,c.of)(this.noop());const s=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageId:null===(r=e.questionInfo)||void 0===r?void 0:r.id,pageType:16},answers:n,t:this.t,items:a});return this.service.fetchSEOProps(s,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((()=>(0,c.of)(this.sharingMeta.setQuestionSharingMeta(e,n[0],i,o)))))}setVideoPlaylistSEOProps(e,t,n,i){var o;if(-1===e.statusCode)return(0,c.of)(this.noop());const a=Object.assign(Object.assign(Object.assign({},e),n),{itemList:t,seoProps:{pageId:null===(o=e.mixInfo)||void 0===o?void 0:o.id,pageType:119},t:this.t});return this.service.fetchSEOProps(a,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((()=>(0,c.of)(this.sharingMeta.setVideoPlaylistSharingMeta(e,t,i)))))}setUserSEOProps(e,t,n,i){const{userInfo:o,statusCode:a}=e;return-1===a?(0,c.of)(this.noop()):(0,c.of)(e).pipe((0,h.E)(this.stateModule.state$),(0,p.Z)((([a,r])=>{var s,c;const u=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageId:null!==(c=null===(s=null==o?void 0:o.user)||void 0===s?void 0:s.id)&&void 0!==c?c:"",pageType:1,abtest:r.abtest},t:this.t,items:i});return this.service.fetchSEOProps(u,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,f.n)((t=>(0,d.h)(this.sharingMeta.setUserSharingMeta(t,e,n)))))})))}setChallengeSEOProps(e,t,n,i,o){var a;const{statusCode:r}=e;if(-1===r)return(0,c.of)(this.noop());const s=Object.assign(Object.assign(Object.assign({},e),t),{statusCode:r,seoProps:{pageId:null===(a=e.challengeInfo)||void 0===a?void 0:a.challenge.id,pageType:3},t:this.t,items:i,relatedChallengeList:o});return this.service.fetchSEOProps(s,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,f.n)((t=>(0,d.h)(this.sharingMeta.setChallengeSharingMeta(t,e,n)))))}setMusicSEOProps(e,t,n,i){var o;const{statusCode:a}=e;if(-1===a)return(0,c.of)(this.noop());const r=Object.assign(Object.assign(Object.assign({},e),t),{statusCode:a,seoProps:{pageId:null===(o=e.musicInfo)||void 0===o?void 0:o.music.id,pageType:4},items:i,t:this.t});return this.service.fetchSEOProps(r,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,f.n)((t=>(0,d.h)(this.sharingMeta.setMusicSharingMeta(t,e,n)))))}setMusicPlaylistSEOProps(e,t,n){var i;const{status_code:o}=e;if(-1===o)return(0,c.of)(this.noop());const a=Object.assign(Object.assign(Object.assign({},e),t),{status_code:o,seoProps:{pageId:null===(i=e.mc_info)||void 0===i?void 0:i.id_str,pageType:17},t:this.t});return this.service.fetchSEOProps(a,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((t=>(0,d.h)(this.sharingMeta.setMusicPlaylistSharingMeta(t,e,n)))))}setSearchSEOProps(e,t,n){const{status_code:i}=e;if(-1===i)return(0,c.of)(this.noop());const o=Object.assign(Object.assign(Object.assign(Object.assign({},e),t),n),{seoProps:{pageId:"",pageType:105},t:this.t});return this.service.fetchSEOProps(o,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,g.T)((()=>this.noop())))}setLiveRoomSEOProps(e,t,n){var i;const{userInfo:o,statusCode:a}=e,r=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageId:null!==(i=null==o?void 0:o.user.id)&&void 0!==i?i:"",pageType:12},t:this.t});return-1===a?(0,c.of)(this.noop()):this.service.fetchSEOProps(r,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((t=>(0,d.h)(this.sharingMeta.setLiveRoomSharingMeta(t,e,n)))))}setFollowingSEOProps(e,t,n){if(-1===e.statusCode)return(0,c.of)(this.noop());const i=Object.assign(Object.assign(Object.assign({},e),t),{seoProps:{pageType:11},t:this.t});return this.service.fetchSEOProps(i,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((e=>(0,d.h)(this.sharingMeta.setFollowingSharingMeta(e,n)))))}setPoiSEOProps(e,t,n,i){var o,a;const{statusCode:r}=e;if(-1===r)return(0,c.of)(this.noop());const s=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},e),t),{statusCode:r,seoProps:{pageId:null===(a=null===(o=e.poiInfo)||void 0===o?void 0:o.poi)||void 0===a?void 0:a.id,pageType:18}}),i),{t:this.t});return this.service.fetchSEOProps(s,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((t=>(0,d.h)(this.sharingMeta.setPoiSharingMeta(t,e,n)))))}setPoiCategorySEOProps(e,t,n,i){var o,a;const{statusCode:r}=e;if(-1===r)return(0,c.of)(this.noop());const s=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},e),t),{statusCode:r,seoProps:{pageId:null===(a=null===(o=e.poiInfo)||void 0===o?void 0:o.poi)||void 0===a?void 0:a.id,pageType:125}}),i),{t:this.t});return this.service.fetchSEOProps(s,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((t=>(0,d.h)(this.sharingMeta.setPoiSharingMeta(t,e,n)))))}setEventDetailSEOProps(e){return e.pipe((0,v.p)((e=>{const{eventTitle:t,eventId:n,subscriberCount:i,language:o="en"}=e,a={seoProps:{pageId:"",pageType:114},t:this.t,eventTitle:t,language:o,eventId:n,subscriberCount:i};return this.service.fetchSEOProps(a,ye).pipe((0,l.M)((e=>this.updateSEOState(e))),(0,p.Z)((()=>(0,c.of)(this.terminate()))),(0,m.W)((()=>(0,c.of)(this.noop()))))})))}reportImpressionByEventbus(e){return this.service.reportImpressionByEventbus(e)}reportImpressionByRpc(e){return this.service.reportImpressionByRpc(e)}};(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],be.prototype,"setPCMusicSEOProps",null),(0,i.__decorate)([(0,o.Mj)({payloadGetter:1}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],be.prototype,"setFeedSEOProps",null),(0,i.__decorate)([(0,o.Mj)({payloadGetter:1}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",u.c)],be.prototype,"setGoLiveSEOProps",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",u.c)],be.prototype,"setEventDetailSEOProps",null),be=(0,i.__decorate)([(0,a.n)("SEO"),(0,i.__param)(3,(0,r.y)(ge.hp)),(0,i.__metadata)("design:paramtypes",[fe.p,_e.F,he.e,Function])],be)},19331:(e,t,n)=>{"use strict";n.d(t,{F:()=>h});var i=n(58632),o=n(7672),a=n(340),r=n(57432),s=n.n(r),l=n(23999),c=n(66322),d=n(15203),u=n(91498),p=n(88874),v=n(65450),m=n(55099),g=n(64356);let h=class{constructor(e,t){this.t=e,this.fetch=t}fetchSEOProps(e,t){var n,i,o,a;e.t=this.t;const r=null!==(i=null===(n=(0,c.y)(e,t).seoProps)||void 0===n?void 0:n.metaParams)&&void 0!==i?i:{},s=null!==(a=null===(o=(0,c.d)(e,t).seoProps)||void 0===o?void 0:o.jsonldList)&&void 0!==a?a:[],d=Object.assign(Object.assign({},e.seoProps),{metaParams:r,jsonldList:s});return(0,l.of)(d)}getUA(){return window.navigator.userAgent}getTrafficType(){return(0,d.q)()}getLaunchMode(){return(0,u.o7)()}fetchABTest(e){const t=(0,p.YI)(v.X);return t?(0,l.of)(t):(0,l.of)({pageId:"-1",vidList:[],parameters:{}})}reportImpressionByEventbus(e){}reportImpressionByRpc(e){this.fetch.post("/api/discover/client_impression/",{body:JSON.stringify({timestamp:e.Timestamp,visitPageUrl:e.VisitPageUrl,urls:e.Urls,module:e.Module,trafficType:e.TrafficType}),headers:{"content-type":"application/json"},baseUrlType:2}).subscribe(s())}};h=(0,i.__decorate)([(0,o._)(),(0,i.__param)(0,(0,a.y)(g.hp)),(0,i.__metadata)("design:paramtypes",[Function,m.p])],h)},50789:(e,t,n)=>{"use strict";n.d(t,{p:()=>f});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(340),l=n(46657),c=n(23999),d=n(26324),u=n(72916),p=n(74690),v=n(80339),m=n(9472),g=n(17995),h=n(19331);const _=(e="")=>{try{return decodeURI(e)}catch(t){return e}};let f=class extends o.E{constructor(e,t){super(),this.service=e,this.jotaiStore=t,this.defaultState={abtest:void 0,loading:!1,canonical:void 0,pageType:999}}updateAtom(e){this.jotaiStore.set(m.b,e)}setSEOState(e,t){return Object.assign(Object.assign({},e),{metaParams:t.metaParams,jsonldList:t.jsonldList})}setAbTest(e,t){return Object.assign(Object.assign({},e),{abtest:t})}setLoading(e,t){return Object.assign(Object.assign({},e),{loading:t})}setCanonical(e,t){return Object.assign(Object.assign({},e),{canonical:t})}setRouterLoading(e,t){return Object.assign(Object.assign({},e),{routerLoading:t})}fetchAbTest(e){return e.pipe((0,u.n)((e=>_(e)===_(this.state.canonical)?l.w:this.service.fetchABTest(e).pipe((0,u.n)((t=>(0,c.of)(this.getActions().setAbTest(t),this.getActions().setCanonical(e),this.terminate()))),(0,p.Z)(this.getActions().setLoading(!0)),(0,v.q)(this.getActions().setLoading(!1))))))}};(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",Object)],f.prototype,"setSEOState",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",Object)],f.prototype,"setAbTest",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",Object)],f.prototype,"setLoading",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",Object)],f.prototype,"setCanonical",null),(0,i.__decorate)([(0,a.HI)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Boolean]),(0,i.__metadata)("design:returntype",Object)],f.prototype,"setRouterLoading",null),(0,i.__decorate)([(0,a.Mj)({payloadGetter:1}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[d.c]),(0,i.__metadata)("design:returntype",void 0)],f.prototype,"fetchAbTest",null),f=(0,i.__decorate)([(0,r.n)("SEOState"),(0,i.__param)(1,(0,s.y)(g.J7)),(0,i.__metadata)("design:paramtypes",[h.F,Object])],f)},99101:(e,t,n)=>{"use strict";n.d(t,{e:()=>h});var i=n(58632),o=n(4126),a=n(93995),r=n(53966),s=n(340),l=n(8536),c=n(23999),d=n(80339),u=n(26324),p=n(64356),v=n(27375),m=n(64810),g=n(9078);let h=class extends r.E{constructor(e,t){super(),this.t=e,this.stateModule=t,this.defaultState={}}setSharingMetaStateEffect(e){return e.pipe((0,l.Z)((e=>(0,c.of)(this.setSharingMetaState(e)).pipe((0,d.q)(this.terminate("setSharingMetaStateEffect"))))))}setSharingMetaState(e){return this.stateModule.getActions().setSharingMetaState(e)}setVideoSharingMetaEffect(e){return e.pipe((0,l.Z)((({seoProps:e,response:t,appType:n,query:i})=>this.setVideoSharingMeta(e,t,n,i).pipe((0,d.q)(this.terminate("setVideoSharingMetaEffect"))))))}setVideoSharingMeta(e,t,n,i){var o,a,r,s,l,d,u,p,v,m,h,_,f,y,b,w,x,T,k,S;const E=null===(o=t.itemInfo)||void 0===o?void 0:o.itemStruct,A=null==E?void 0:E.video,O=null==E?void 0:E.imagePost,{protocal:P}=(0,g.QJ)(n),I=`${P}${Boolean(null==E?void 0:E.story)?"story/detail":"aweme/detail"}/${null===(a=t.itemInfo)||void 0===a?void 0:a.itemStruct.id}?${i}`,C=(0,g.r1)({schema:I,metaParams:e.metaParams,pageType:0,shareMeta:null==t?void 0:t.shareMeta,response:t,appType:n}),L=(null===(r=null==A?void 0:A.shareCover)||void 0===r?void 0:r[0])||(null!==(p=O?null===(d=null===(l=null===(s=O.shareCover)||void 0===s?void 0:s.imageURL)||void 0===l?void 0:l.urlList)||void 0===d?void 0:d[0]:null===(u=null==A?void 0:A.shareCover)||void 0===u?void 0:u[1])&&void 0!==p?p:""),j=null!==(h=null!==(m=String(null===(v=null==O?void 0:O.shareCover)||void 0===v?void 0:v.imageWidth))&&void 0!==m?m:null==A?void 0:A.width)&&void 0!==h?h:"",M=null!==(y=null!==(f=String(null===(_=null==O?void 0:O.shareCover)||void 0===_?void 0:_.imageHeight))&&void 0!==f?f:null==A?void 0:A.height)&&void 0!==y?y:"",N=Object.assign(Object.assign({},C),{"og:image":L,"twitter:image":L,"og:image:width":j,"og:image:height":M}),D=null===(T=null===(x=null===(w=null===(b=e.jsonldList)||void 0===b?void 0:b.find((e=>"VideoObject"===e[0])))||void 0===w?void 0:w[1])||void 0===x?void 0:x.thumbnailUrl)||void 0===T?void 0:T[0];return Boolean(D)&&Object.assign(N,{"og:image":D,"og:image:width":String(null!==(k=null==A?void 0:A.width)&&void 0!==k?k:""),"og:image:height":String(null!==(S=null==A?void 0:A.height)&&void 0!==S?S:"")}),(0,c.of)(this.stateModule.getActions().setSharingMetaState(N))}setUserSharingMetaEffect(e){return e.pipe((0,l.Z)((({seoProps:e,response:t,appType:n})=>this.setUserSharingMeta(e,t,n).pipe((0,d.q)(this.terminate("setUserSharingMetaEffect"))))))}setUserSharingMeta(e,t,n){var i,o,a,r;const{protocal:s}=(0,g.QJ)(n),l=(0,g.r1)({response:t,pageType:1,schema:`${s}user/profile/`,metaParams:e.metaParams,appType:n}),d=null===(i=t.userInfo)||void 0===i?void 0:i.user,u=null!==(a=null!==(o=null==d?void 0:d.avatarMedium)&&void 0!==o?o:null==d?void 0:d.avatarThumb)&&void 0!==a?a:g.Zw,p=Object.assign(Object.assign({},l),{"og:image":u,"twitter:image":u,"og:image:width":"360","og:image:height":"360","og:image:alt":null===(r=e.metaParams)||void 0===r?void 0:r.title});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(p))}setMusicSharingMetaEffect(e){return e.pipe((0,l.Z)((({seoProps:e,response:t,appType:n})=>this.setMusicSharingMeta(e,t,n).pipe((0,d.q)(this.terminate("setMusicSharingMetaEffect"))))))}setMusicSharingMeta(e,t,n){var i,o,a,r,s,l;const d=null===(i=t.musicInfo)||void 0===i?void 0:i.music,{protocal:u}=(0,g.QJ)(n),p=(0,g.r1)({response:t,pageType:4,schema:`${u}user/profile/${null==d?void 0:d.id}`,metaParams:e.metaParams,appType:n}),v=null!==(a=null!==(o=null==d?void 0:d.coverMedium)&&void 0!==o?o:null==d?void 0:d.coverThumb)&&void 0!==a?a:"https://lf16-tiktok-web.ttwstatic.com/obj/tiktok-web-common-sg/mtact/static/images/music-default.png",m=null!==(r=null==d?void 0:d.title)&&void 0!==r?r:"",h=null!==(s=null==d?void 0:d.authorName)&&void 0!==s?s:"",_=Object.assign(Object.assign({},p),{"og:image":v,"twitter:image":v,"og:image:width":"720","og:image:height":"720","og:image:alt":null===(l=e.metaParams)||void 0===l?void 0:l.title,"music:duration":"0","music:album:track":m,"music:musician":h});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(_))}setMusicPlaylistSharingMeta(e,t,n){var i,o,a,r;const s=t.mc_info,{protocal:l}=(0,g.QJ)(n),d=(0,g.r1)({schema:`${l}assmusic/category/${null==s?void 0:s.id_str}?name=${encodeURIComponent(null!==(i=null==s?void 0:s.name)&&void 0!==i?i:"")}&previous_page=reflow_playlist&enter_method=reflow_return`,metaParams:Object.assign(Object.assign({},e.metaParams),{title:null===(o=null==s?void 0:s.share_info)||void 0===o?void 0:o.share_title,description:null===(a=null==s?void 0:s.share_info)||void 0===a?void 0:a.share_desc}),appType:n}),u=(null==s?void 0:s.share_cover)?(0,v.BO)(null==s?void 0:s.share_cover):"https://p19-aop-sg.tiktokcdn.com/tos-alisg-i-yzb763657w-sg/d2f2b037e19646ad5f2bbd779a550302.png~tplv-yzb763657w-resize:800:800.jpeg",p=Object.assign(Object.assign({},d),{"og:image":u,"twitter:image":u,"og:image:width":"720","og:image:height":"720","og:image:alt":null===(r=e.metaParams)||void 0===r?void 0:r.title});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(p))}setStickerSharingMeta(e,t,n){var i,o,a,r;const{protocal:s}=(0,g.QJ)(n),l=null===(i=t.stickerInfo)||void 0===i?void 0:i.sticker,d=(0,g.r1)({pageType:3,response:t,schema:`${s}sticker/detail/${null==l?void 0:l.id}`,metaParams:e.metaParams,appType:n}),u=null===(a=null===(o=null==l?void 0:l.coverUrls)||void 0===o?void 0:o.urlList)||void 0===a?void 0:a[0],p=Object.assign(Object.assign({},d),{"og:image":u,"twitter:image":u,"og:image:width":"720","og:image:height":"720","og:image:alt":null===(r=e.metaParams)||void 0===r?void 0:r.title});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(p))}setChallengeSharingMetaEffect(e){return e.pipe((0,l.Z)((({seoProps:e,response:t,appType:n})=>this.setChallengeSharingMeta(e,t,n).pipe((0,d.q)(this.terminate("setChallengeSharingMetaEffect"))))))}setChallengeSharingMeta(e,t,n){var i,o,a,r;const{protocal:s}=(0,g.QJ)(n),l=null===(i=t.challengeInfo)||void 0===i?void 0:i.challenge,d=(0,g.r1)({pageType:3,response:t,schema:`${s}challenge/detail/${null==l?void 0:l.id}`,metaParams:e.metaParams,appType:n}),u=null!==(a=null!==(o=null==l?void 0:l.profileMedium)&&void 0!==o?o:null==l?void 0:l.profileThumb)&&void 0!==a?a:"https://lf16-tiktok-web.ttwstatic.com/obj/ttfe-malisg/tiktok_web/amp/m-hashtag-default.png",p=Object.assign(Object.assign({},d),{"og:image":u,"twitter:image":u,"og:image:width":"720","og:image:height":"720","og:image:alt":null===(r=e.metaParams)||void 0===r?void 0:r.title});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(p))}setCollectionSharingMeta(e,t,n){var i,o,a,r,s,l,d;const{protocal:u}=(0,g.QJ)(t),p=e.shareMeta,v=(0,g.r1)({pageType:121,response:e,schema:`${u}collection/detail?collection_id=${n}&page_name=reflow_collection`,metaParams:{title:null!==(i=null==p?void 0:p.title)&&void 0!==i?i:this.t("TikTok | Make Your Day",{},"TikTok | Make Your Day"),description:null!==(o=null==p?void 0:p.desc)&&void 0!==o?o:this.t("SEO_homepage_desc",{},"TikTok - trends start here. On a device or on the web, viewers can watch and discover millions of personalized short videos. Download the app to get started.")},appType:t}),m=null!==(l=null===(s=null===(r=null===(a=null==e?void 0:e.collectionInfo)||void 0===a?void 0:a.cover)||void 0===r?void 0:r.urlList)||void 0===s?void 0:s[0])&&void 0!==l?l:"https://sf-static.tiktokcdn.com/obj/tiktok-web-common-sg/mtact/static/images/tiktok-logo/poster-square.png",h=Object.assign(Object.assign({},v),{"og:image":m,"twitter:image":m,"og:image:width":"720","og:image:height":"720","og:image:alt":null===(d=e.shareMeta)||void 0===d?void 0:d.title});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(h))}setSearchSharingMeta(e,t,n,i){var o,a,r,s;const{protocal:l}=(0,g.QJ)(i),d=(0,g.r1)({schema:`${l}search?keyword=${null!==(a=null===(o=null==t?void 0:t.contentInfo)||void 0===o?void 0:o.query)&&void 0!==a?a:n}`,metaParams:e.metaParams,appType:i}),u=null!==(s=null===(r=null==t?void 0:t.contentInfo)||void 0===r?void 0:r.thirdPartyPreviewImg)&&void 0!==s?s:"https://sf-static.tiktokcdn.com/obj/search-static-maliva/maliva/ugvonpsj1631257573250",p=Object.assign(Object.assign({},d),{"og:image":u,"twitter:image":u,"og:image:width":"1200","og:image:height":"678"});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(p))}setLiveRoomSharingMeta(e,t,n){var i,o,a,r,s,l,d;const{protocal:u}=(0,g.QJ)(n),p=(0,g.r1)({schema:`${u}live?room_id=${null===(o=null===(i=t.userInfo)||void 0===i?void 0:i.user)||void 0===o?void 0:o.roomId}`,metaParams:e.metaParams,pageType:12,appType:n}),v=null===(a=t.userInfo)||void 0===a?void 0:a.user,m=null!==(s=null!==(r=null==v?void 0:v.avatarMedium)&&void 0!==r?r:null==v?void 0:v.avatarThumb)&&void 0!==s?s:g.Zw,h=null!==(l=null==v?void 0:v.nickname)&&void 0!==l?l:null==v?void 0:v.uniqueId,_=null==v?void 0:v.uniqueId,f=Object.assign(Object.assign({},p),{"og:image":m,"og:image:secure_url":m,"og:image:width":"360","og:image:height":"360","og:image:alt":null===(d=e.metaParams)||void 0===d?void 0:d.title,"twitter:creator":h,"twitter:creator:id":_});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(f))}setQuestionSharingMeta(e,t,n,i){var o,a,r,s,l,c,d,u,p;const{protocal:v}=(0,g.QJ)(n),m=(0,g.r1)({schema:`${v}qna/detail/${null===(o=e.questionInfo)||void 0===o?void 0:o.id}`,metaParams:{title:null===(a=e.shareMeta)||void 0===a?void 0:a.title,description:null===(r=e.shareMeta)||void 0===r?void 0:r.desc},pageType:16,response:e,appType:n}),h="qna"===(null==i?void 0:i.scene)?{"og:title":this.t("qaoop_title",{},"Hi friends, I’m inviting you to answer a question on #TikTok!"),"og:description":this.t("qaoop_desc",{},"Share your wisdom!")}:void 0,_=null!==(d=null!==(l=null===(s=null==t?void 0:t.video.shareCover)||void 0===s?void 0:s[1])&&void 0!==l?l:null===(c=null==t?void 0:t.video.shareCover)||void 0===c?void 0:c[0])&&void 0!==d?d:g.Zw,f=Object.assign(Object.assign(Object.assign({},m),{"og:image":_,"twitter:image":_,"og:image:alt":null!==(p=null===(u=e.shareMeta)||void 0===u?void 0:u.title)&&void 0!==p?p:"the cover of first video"}),h);return this.stateModule.getActions().setSharingMetaState(f)}setVideoPlaylistSharingMeta(e,t,n){var i,o,a,r,s,l,c,d,u;const{protocal:p}=(0,g.QJ)(n),v=`@${null===(o=null===(i=e.mixInfo)||void 0===i?void 0:i.creator)||void 0===o?void 0:o.nickname}`,m=null!==(r=null===(a=e.mixInfo)||void 0===a?void 0:a.name)&&void 0!==r?r:"Untitled playlist",h=(0,g.r1)({schema:`${p}mix/detail?id=${null!==(l=null===(s=e.mixInfo)||void 0===s?void 0:s.id)&&void 0!==l?l:"nan"}`,metaParams:{title:this.t("playlist_share_title",{Playlist_name:m,username:v},`Playlist ${m} created by ${v}`),description:this.t("playlist_share_desc",{},"Enjoy a curated video list and find more videos on TikTok!")},pageType:119,response:e,appType:n}),[_]=null!=t?t:[],f=null!==(d=null===(c=null==_?void 0:_.video.shareCover)||void 0===c?void 0:c[1])&&void 0!==d?d:null===(u=null==_?void 0:_.video.shareCover)||void 0===u?void 0:u[0],y=Object.assign(Object.assign({},h),{"og:image":f,"twitter:image":f,"og:image:alt":`first video of ${m}`});return this.stateModule.getActions().setSharingMetaState(y)}setFollowingSharingMeta(e,t){const n=(0,g.r1)({metaParams:e.metaParams,appType:t}),i=Object.assign(Object.assign({},n),{"og:title":this.t("serp_following_title"),"og:description":this.t("serp_following_desc"),"og:image":g.Zw,"twitter:image":g.Zw,"twitter:title":this.t("SEO_following_title"),"twitter:description":this.t("SEO_following_desc")});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(i))}setPoiSharingMeta(e,t,n){var i;const{protocal:o}=(0,g.QJ)(n),a=null===(i=t.poiInfo)||void 0===i?void 0:i.poi,r=(0,g.r1)({pageType:18,response:t,schema:`${o}poi/detail?poi_id=${null==a?void 0:a.id}`,metaParams:e.metaParams,appType:n});return(0,c.of)(this.stateModule.getActions().setSharingMetaState(r))}};(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"setSharingMetaStateEffect",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"setVideoSharingMetaEffect",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"setUserSharingMetaEffect",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"setMusicSharingMetaEffect",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],h.prototype,"setChallengeSharingMetaEffect",null),h=(0,i.__decorate)([(0,a.n)("SharingMeta"),(0,i.__param)(0,(0,s.y)(p.hp)),(0,i.__metadata)("design:paramtypes",[Function,m.J])],h)},64810:(e,t,n)=>{"use strict";n.d(t,{J:()=>d});var i=n(58632),o=n(64162),a=n(4126),r=n(93995),s=n(19794),l=n.n(s),c=n(9078);let d=class extends o.E{constructor(){super(...arguments),this.defaultState={value:{}}}setSharingMetaState(e,t){var n;e.value=l()(t,{"og:image":c.Zw,"twitter:image":null!==(n=t["og:image"])&&void 0!==n?n:c.Zw})}};(0,i.__decorate)([(0,a.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],d.prototype,"setSharingMetaState",null),d=(0,i.__decorate)([(0,r.n)("SharingMetaState")],d)},9078:(e,t,n)=>{"use strict";var i;function o(e){const t="m"===e;return{isM:t,protocal:t?"snssdk1233://":"snssdk1180://"}}function a(e){var t,n,a,r;const{schema:s="",pageType:l,shareMeta:c,metaParams:d,appType:u}=e,p=o(u),{isM:v}=p,{APP_INFO:m}=i,g=v?m.M_NAME:m.T_NAME,h=v?m.M_STORE:m.T_STORE,_=v?m.M_PACKAGE:m.T_PACKAGE,f=0===l?null!==(t=null==c?void 0:c.title)&&void 0!==t?t:"":null!==(n=null==d?void 0:d.title)&&void 0!==n?n:"",y=0===l?null!==(a=null==c?void 0:c.desc)&&void 0!==a?a:"":null!==(r=null==d?void 0:d.description)&&void 0!==r?r:"",b={"al:ios:url":s,"al:android:url":s,"al:ios:app_store_id":h,"al:ios:app_name":g,"al:android:app_name":g,"al:android:package":_},w={"og:site_name":"TikTok","og:type":"website","og:title":f,"og:description":y,"fb:app_id":v?m.M_FACEBOOK_ID:m.T_FACEBOOK_ID},x={"twitter:app:id:iphone":h,"twitter:app:id:googleplay":_,"twitter:card":"summary","twitter:site":"TikTok","twitter:title":f,"twitter:description":y};return Object.assign(Object.assign(Object.assign({},b),w),x)}n.d(t,{Zw:()=>r,QJ:()=>o,r1:()=>a}),function(e){e.APP_INFO={M_PACKAGE:"com.zhiliaoapp.musically",T_PACKAGE:"com.ss.android.ugc.trill",M_STORE:"835599320",T_STORE:"1235601864",M_NAME:"musical.ly",T_NAME:"TIKTOK",M_FACEBOOK_ID:"597615686992125",T_FACEBOOK_ID:"1862952583919182"},e.TTNOW_INFO={NAME:"TIKTOK.NOW",STORE_ID:"1641062073",PACKAGE:"com.ss.android.ugc.now",FACEBOOK_ID:"1243781563051427"},e.COIN_LITE_INFO={PACKAGE:"com.ss.android.ugc.tiktok.lite",STORE:"6447160980",NAME:"TikTok Lite",FACEBOOK_ID:"171444425350301"},e.COIN_PRO_INFO={PACKAGE:"com.ss.android.ugc.tiktok.pro",STORE:"6741796873",NAME:"TikTok Pro",FACEBOOK_ID:"171444425350301"}}(i||(i={}));const r="https://lf16-tiktok-web.ttwstatic.com/obj/tiktok-web-common-sg/mtact/static/images/share_img.png"},55306:(e,t,n)=>{"use strict";n.d(t,{U:()=>j});var i=n(58632),o=n(4126),a=n(93995),r=n(340),s=n(23999),l=n(46657),c=n(68628),d=n(9543),u=n(26324),p=n(72916),v=n(95719),m=n(8536),g=n(64468),h=n(24451),_=n(62564),f=n(20259),y=n(74690),b=n(35572),w=n(34360),x=n(97792),T=n(8046),k=n(11983),S=n(53966),E=n(84908),A=n(79123),O=n(55322),P=n(22248),I=n(64356),C=n(27375),L=n(91543);let j=class extends S.E{constructor(e,t){super(),this.service=e,this.t=t,this.defaultState={users:{},stats:{}}}multiSetUser(e,t){(0,E.Gp)().multiSetUser(t)}setUser(e,t){(0,E.Gp)().setUser(t)}setUserRelation(e,t){(0,E.Gp)().setUserRelation(t)}setUserStats(e,t){(0,E.Gp)().setUserStats(t)}multiSetUserStats(e,t){(0,E.Gp)().multiSetUserStats(t)}getUserDetail(e){return e.pipe((0,p.n)((e=>this.service.getUserDetail(e).pipe((0,v.M)((e=>{(0!==e.statusCode&&10222!==e.statusCode||!e.userInfo)&&console.warn("Get user detail failed for getting wrong response")})),(0,m.Z)((e=>0!==e.statusCode&&10222!==e.statusCode||!e.userInfo?l.w:(0,s.of)(this.getActions().setUser(Object.assign(Object.assign({},e.userInfo.user),{extraInfo:{statusCode:e.statusCode}})),this.getActions().setUserStats({stats:Object.assign(Object.assign({},e.userInfo.stats),{needFix:!1}),uniqueId:e.userInfo.user.uniqueId})))),(0,O.n)({})))))}postCommitFollowUser(e){return e.pipe((0,g.$)((({uniqueId:e})=>e)),(0,m.Z)((e=>e.pipe((0,h.E)(this.state$),(0,_.T)((([e,t])=>{const n=t.users[e.uniqueId],{id:o,secUid:a="",relation:r=-1}=n,s=(0,A.gN)(r),l={type:1===s?1:0,action_type:1===s?1:0,user_id:o,sec_user_id:a,from:18,channel_id:0,from_pre:0},{uniqueId:c,useFollowV2:d,group_id:u,enter_method:p="click_direct_btn",action_position:v}=e;return{query:l,type:s,group_id:u,enter_method:p,action_position:v,restReportParams:(0,i.__rest)(e,["uniqueId","useFollowV2","group_id","enter_method","action_position"]),id:o,uniqueId:c,useFollowV2:d,relation:r,targetUser:n}})),(0,p.n)((({query:e,group_id:t,enter_method:n,action_position:i,restReportParams:o,id:a,uniqueId:r,useFollowV2:s,relation:l,targetUser:d})=>(s?this.service.postCommitFollowUserV2(e):this.service.postCommitFollowUser(e)).pipe((0,f.W)((e=>(0,c.H)(e.json()))),(0,_.T)((e=>Object.assign({status_code:null==e?void 0:e.status_code,follow_status:null==e?void 0:e.follow_status},e))),(0,v.M)((({status_code:r,follow_status:s})=>{if(24===r?k.F.open({content:this.t("inbox_follow_failed_banned"),duration:3,widthType:"half"}):-1===r?k.F.open({content:this.t("inbox_follow_failed_noconnection"),duration:3,widthType:"half"}):0!==r?k.F.open({content:this.t("inbox_follow_failed_other"),duration:3,widthType:"half"}):(0,P.G)(r,[24,-1,0]),x.t.handleFollowUser(Object.assign(Object.assign({},o),{status_code:r,follow_status:s,group_id:t,enter_method:n,action_position:i,to_user_id:a,author_id:a,follow_type:2===s?"mutual":"single",is_private:4===s?1:0}),e.type),o.is_ad_event&&o.tag&&o.value&&o.log_extra&&0===e.type){const{tag:e,value:t,log_extra:n}=o;T.pg.handleFollowCancel({log_extra:n,tag:e,value:t,is_ad_event:"1"})}})),(0,_.T)((({follow_status:e,status_code:t})=>0===t?this.getActions().setUserRelation({uniqueId:r,relation:C.i0[e],shouldUpdateFollowed:!0}):this.getActions().setUserRelation({uniqueId:r,relation:l}))),(0,y.Z)(this.getActions().setUserRelation({uniqueId:r,relation:(0,A.A7)({current:l,targetUser:d})})),(0,O.n)({}))))))))}blockOrUnblockUser(e){return e.pipe((0,b.p)((({secUid:e,isBlock:t,uniqueId:n})=>this.service.blockUser({sec_user_id:null!=e?e:"",block_type:t?0:1}).pipe((0,v.M)((({status_code:e})=>{0===e&&k.F.open({content:this.t(t?"webapp_mig_unblocked":"webapp_mig_blocked"),duration:3,e2eTag:"block-toast"})})),(0,_.T)((({status_code:e})=>0===e?this.getActions().setUserRelation({uniqueId:n,relation:t?0:4}):this.noop())),(0,O.n)({})))))}getLiveStatus(e){return e.pipe((0,p.n)((()=>(0,d.Y)(6e5).pipe((0,h.E)(this.state$),(0,_.T)((([e,{users:t}])=>Object.values(t).filter((e=>Boolean(null==e?void 0:e.roomId))))),(0,m.Z)((e=>(0,s.of)(...e.map((e=>this.getActions().getUserDetail({secUid:null==e?void 0:e.secUid}))))))))))}};j.jotaiAtom=E.p9,(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Array]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"multiSetUser",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"setUser",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"setUserRelation",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"setUserStats",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Array]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"multiSetUserStats",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"getUserDetail",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"postCommitFollowUser",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"blockOrUnblockUser",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[u.c]),(0,i.__metadata)("design:returntype",void 0)],j.prototype,"getLiveStatus",null),j=(0,i.__decorate)([(0,a.n)("UserModule"),(0,i.__param)(1,(0,r.y)(I.hp)),(0,i.__metadata)("design:paramtypes",[L.D,Function])],j),E.p9.__SIGI_MODULE__=j,(0,w.y)(j)},91543:(e,t,n)=>{"use strict";n.d(t,{D:()=>c});var i=n(58632),o=n(7672),a=n(23999),r=n(26325),s=n(55099),l=n(97487);let c=class{constructor(e){this.fetch=e}getUserDetail(e){const t=(0,l.Ni)("userDetail");return t?(0,a.of)(t):this.fetch.get("/api/user/detail/",{query:e,baseUrlType:2})}postCommitFollowUser(e){return this.fetch.post("/api/commit/follow/user/",{query:Object.assign(Object.assign({},e),{fromWeb:1}),baseUrlType:2,headers:{[r.nk]:this.fetch.csrfToken}})}postCommitFollowUserV2(e){return this.fetch.post("/api/follow/",{signal:(new AbortController).signal,query:Object.assign(Object.assign({},e),{fromWeb:1}),baseUrlType:2,headers:{[r.nk]:this.fetch.csrfToken}})}blockUser(e){return this.fetch.post("/api/user/block/",{query:Object.assign(Object.assign({},e),{source:3}),baseUrlType:2,headers:{[r.nk]:this.fetch.csrfToken}})}};c=(0,i.__decorate)([(0,o._)(),(0,i.__metadata)("design:paramtypes",[s.p])],c)},50834:(e,t,n)=>{"use strict";n.d(t,{t:()=>r});var i=n(14285),o=n(57432),a=n.n(o);const r={provide:(0,n(67134).U)("FirstVideoCover@tiktok/fe-shared",(()=>new i.n("FirstVideoCover"))),useValue:a()}},79983:(e,t,n)=>{"use strict";n.d(t,{D:()=>V,O:()=>F});var i=n(58632),o=n(4126),a=n(93995),r=n(340),s=(n(16378),n(45537)),l=n.n(s),c=n(300),d=n.n(c),u=n(23999),p=n(63700),v=n(26324),m=n(20259),g=n(72916),h=n(62564),_=n(80339),f=n(24451),y=n(35572),b=n(8536),w=n(95719),x=n(45525),T=n(74690),k=n(76435),S=n(34360),E=n(17995),A=n(65852),O=n(11983),P=n(53966),I=n(68783),C=n(2408),L=n(97086),j=n(64356),M=n(45297),N=n(59952),D=n(52333),R=n(50834),B=n(14576),U=n(54888);let F=class extends P.E{constructor(e,t,n,i,o,a,r){super(),this.service=e,this.item=t,this.videoMask=n,this.bizContext=i,this.jotaiStore=o,this.t=a,this.getFirstVideoCover=r,this.defaultState={},this.createItemListErrorCatcher=e=>t=>t.pipe((0,m.W)((t=>(O.F.destroy(),O.F.open({content:this.t("server_error_title"),duration:3,widthType:"padding"}),null==e||e(t),(0,u.of)({statusCode:-1})))))}resetItemList(e,t){const{key:n,hasMore:i=!0,loading:o=!0,cursor:a="0"}=t;e[n]={list:[],browserList:[],loading:o,statusCode:0,hasMore:i,cursor:a,preloadList:[]}}addItemList(e,t){var n;const{key:i,list:o,statusCode:a=0,hasMore:r,hasMorePrevious:s,hasMoreLatest:c,cursor:u,level:p,preloadList:v,addToHead:m,liveCardDisplay:g,unviewedCursor:h,viewedCursor:_,unique:f=!0}=t,y="topic"===i||"messages"===i;e[i]||(e[i]={list:[],browserList:[],loading:!1,statusCode:a,hasMore:Boolean(r),cursor:u,preloadList:[]});const b=e[i].list,w=f?d()(o,"id").filter((e=>!b.includes(e.id))):o;if(m)e[i].list.unshift(...w.map((({id:e})=>e))),e[i].browserList=[...(0,I.bp)({list:w}),...e[i].browserList];else{const t=l()(e[i].list,w.map((({id:e})=>e)));f?(e[i].list=y?b.concat(o.map((({id:e})=>e))):t,e[i].browserList=y?e[i].browserList.concat((0,I.bp)({list:o})):l()(e[i].browserList,(0,I.bp)({list:w}))):(e[i].list=o.map((({id:e})=>e)),e[i].browserList=(0,I.bp)({list:w}))}e[i].statusCode=a,e[i].hasMore=r,e[i].cursor=u,e[i].level=p,e[i].liveCardDisplay=g,e[i].preloadList=(null!==(n=e[i].preloadList)&&void 0!==n?n:[]).concat(null!=v?v:[]),"creator_tab"===i&&(e[i].hasMorePrevious=null!=s?s:e[i].hasMorePrevious,e[i].hasMoreLatest=null!=c?c:e[i].hasMoreLatest),"friends"===i&&(e[i].unviewedCursor=null!=h?h:e[i].unviewedCursor,e[i].viewedCursor=null!=_?_:e[i].viewedCursor)}setItemListById(e,t){const{key:n,list:i,statusCode:o=0,hasMore:a=!0,cursor:r,level:s}=t;e[n]||(e[n]={list:[],browserList:[],loading:!1,statusCode:o,hasMore:Boolean(a),cursor:r,preloadList:[]}),e[n].list=i,e[n].browserList=i,e[n].statusCode=o,e[n].hasMore=a,e[n].cursor=r,e[n].level=s}removeItemListById(e,t){var n;const{key:i,groupId:o}=t;(null===(n=e[i])||void 0===n?void 0:n.list)&&(e[i].list=e[i].list.filter((e=>e!==o)))}setLoading(e,t){const{loading:n,key:i}=t;e[i]||(e[i]={list:[],browserList:[],loading:n,statusCode:0,hasMore:!0,cursor:"0"}),e[i].loading=n}setListKeyword(e,t){const{keyword:n,key:i}=t;e[i]||(e[i]={keyword:n,list:[],browserList:[],loading:!1,statusCode:0,hasMore:!0,cursor:"0"}),e[i].keyword=n}getTopicList(e){return e.pipe((0,g.n)((({topic:e,abTestVersion:t,user:n,language:i})=>this.service.getTopicList({topic:e,language:i,count:M.Uw,aid:M.xE}).pipe((0,h.T)((e=>Object.assign(Object.assign({},e),{hasMore:!0}))),this.createItemListErrorCatcher(),this.handleListData({key:"topic",abTestVersion:t,user:n,language:i}),(0,_.q)(this.terminate())))))}getFollowingList(e){return e.pipe((0,f.E)(this.state$,this.bizContext.state$),(0,y.p)((([{pullType:e=1,abTestVersion:t,user:n,language:i},o,a])=>{var r,s,l;const{cursor:c="",level:d=1}=null!==(r=o.following)&&void 0!==r?r:{};return this.service.getFollowingList({aid:M.xE,count:M.rd,language:i,cursor:c,pullType:e,level:d,isResetCounterUsed:!0,isNonPersonalized:!(0,L.fU)()&&(0,C.PJ)(this.jotaiStore.get(C.WH)),coverFormat:null===(l=null===(s=a.bizContext)||void 0===s?void 0:s.videoCoverSettings)||void 0===l?void 0:l.format,clientABVersions:null==t?void 0:t.versionName}).pipe(this.createItemListErrorCatcher(),this.handleListData({key:"following",language:i,user:n,abTestVersion:t}))})))}getFriendsList(e){return e.pipe((0,f.E)(this.state$,this.bizContext.state$),(0,y.p)((([{pullType:e=1,abTestVersion:t,user:n,language:i},o,a])=>{var r,s,l;const{unviewedCursor:c="0",viewedCursor:d="0",level:u=1}=null!==(r=o.friends)&&void 0!==r?r:{};return this.service.getFriendsList({aid:M.xE,count:M.Ly,language:i,unviewedCursor:c,viewedCursor:d,pullType:e,level:u,isResetCounterUsed:!0,isNonPersonalized:!(0,L.fU)()&&(0,C.PJ)(this.jotaiStore.get(C.WH)),coverFormat:null===(l=null===(s=a.bizContext)||void 0===s?void 0:s.videoCoverSettings)||void 0===l?void 0:l.format,clientABVersions:null==t?void 0:t.versionName}).pipe(this.createItemListErrorCatcher(),this.handleListData({key:"friends",language:i,user:n,abTestVersion:t}))})))}getQuestionList(e){return e.pipe((0,b.Z)((e=>this.getQuestionList$(e))))}getQuestionList$(e){return(0,u.of)(e).pipe((0,f.E)(this.state$),(0,y.p)((([{questionID:e,abTestVersion:t,language:n,user:i},o])=>{var a,r;return this.service.getQuestionList({questionID:e,language:n,cursor:null!==(r=null===(a=o.question)||void 0===a?void 0:a.cursor)&&void 0!==r?r:"0",aid:M.xE,count:M.vu}).pipe(this.createItemListErrorCatcher(),this.handleListData({key:"question",abTestVersion:t,language:n,user:i}))})))}getPlaylistVideoList(e){return e.pipe((0,b.Z)((e=>this.getPlaylistVideoList$(e))))}getPlaylistVideoList$(e,t){return(0,u.of)(e).pipe((0,f.E)(this.state$),(0,y.p)((([{mixId:e,key:n,abTestVersion:i,language:o,user:a,isPlayList:r},s])=>{var l,c;return this.service.getPlaylistVideoList({mixId:e,language:o,cursor:null!==(c=null===(l=s[null!=n?n:e])||void 0===l?void 0:l.cursor)&&void 0!==c?c:"0",aid:M.xE,count:M.vu}).pipe(this.createItemListErrorCatcher(),(0,w.M)((e=>{var n;return null===(n=null==t?void 0:t.onVideoList)||void 0===n?void 0:n.call(t,e.itemList)})),this.handleListData({key:null!=n?n:e,abTestVersion:i,language:o,user:a,isPlayList:r}))})))}getCollectionList(e){return e.pipe((0,b.Z)((e=>this.getCollectionList$(e))))}getCollectionList$(e){return(0,u.of)(e).pipe((0,f.E)(this.state$),(0,y.p)((([{collectionId:e,abTestVersion:t,language:n,user:i},o])=>{var a,r;return this.service.getCollectionList({collectionId:e,language:n,cursor:null!==(r=null===(a=o.collection)||void 0===a?void 0:a.cursor)&&void 0!==r?r:"0",aid:M.xE,count:M.vu,sourceType:113}).pipe(this.createItemListErrorCatcher(),this.handleListData({key:"collection",abTestVersion:t,language:n,user:i}))})))}getUserVideoListByType(e){return e.pipe((0,b.Z)((e=>this.getUserVideoListByType$(e))))}getUserVideoListByType$(e){return(0,u.of)(e).pipe((0,f.E)(this.state$),(0,g.n)((([{count:e=M.VD,postItemType:t=2,key:n,abTestVersion:i,language:o,user:a},r])=>{var s,l;const c={appId:M.xE,count:e,cursor:null!==(l=null===(s=r[n])||void 0===s?void 0:s.cursor)&&void 0!==l?l:"0",language:o,postItemType:t};return this.service.getUserPostListByType(c).pipe(this.createItemListErrorCatcher(),this.handleListData({key:n,abTestVersion:i,language:o,user:a,otherInfo:{secUid:null==a?void 0:a.secUid}}))})))}getPoiList(e){return e.pipe((0,b.Z)((e=>this.getPoiList$(e))))}getPoiList$(e){return(0,u.of)(e).pipe((0,f.E)(this.state$),(0,y.p)((([{poiId:e,abTestVersion:t,language:n,user:i},o])=>{var a,r;return this.service.getPoiList({poiId:e,language:n,cursor:null!==(r=null===(a=o.poi)||void 0===a?void 0:a.cursor)&&void 0!==r?r:"0",aid:M.xE,count:M.vu}).pipe(this.createItemListErrorCatcher(),this.handleListData({key:"poi",abTestVersion:t,user:i,language:n}))})))}setDeleteVideo(e,t){for(const n of Object.keys(e)){const i=e[n];if(i){const o=i.list.filter((e=>e!==t));e[n].list=o,e[n].browserList=i.browserList.filter((e=>e!==t))}}}deleteLiveItem(e,t){for(const n of Object.keys(e)){const i=e[n];if(i){const e=i.list.filter((e=>e!==t));i.list=e,i.browserList=i.browserList.filter((e=>e!==t))}e[n]=i}}setList(e){return e.pipe((0,f.E)(this.state$,this.videoMask.state$),(0,w.M)((([{key:e,response:t,disableReportMore:n=!1,isPlayList:i=!1},o])=>{var a,r,s;(null!==(r=null===(a=o[e])||void 0===a?void 0:a.list)&&void 0!==r?r:[]).length&&!n&&A.L.handleListMore({is_success:(null===(s=t.itemList)||void 0===s?void 0:s.length)?1:0,error_code:t.statusCode,popup_type:i?"playlist":void 0})})),(0,h.T)((([{key:e,response:t,otherInfo:n,user:i},o,a])=>{var r,s;const l=null!==(s=null!==(r=t.itemList)&&void 0!==r?r:t.items)&&void 0!==s?s:[];return t.itemList||(t.itemList=l),1!==(null==i?void 0:i.photoSensitiveVideosSetting)&&(i||1!==a.photoSensitiveVideosSetting)||"user-post"===e&&(null==i?void 0:i.secUid)===(null==n?void 0:n.secUid)||!("video"!==e||l.length>1)||(t.itemList=l.filter((e=>2===e.containerType||4!==(null==e?void 0:e.maskType)))),t.itemList=t.itemList.map((e=>{var t;return(0,I.Jl)(e)&&(e.id=(0,I.Qw)(null===(t=e.liveRoomInfo)||void 0===t?void 0:t.roomID)),e})),{key:e,response:t,otherInfo:n}})),(0,w.M)((({key:e,response:t})=>{})),(0,b.Z)((({key:e,response:t,otherInfo:n})=>{const{log_pb:i,itemList:o=[],statusCode:a=0,hasMore:r=!1,hasMorePrevious:s,liveCardDisplay:l,hasMoreLatest:c,cursor:d="0",level:p,viewedCursor:v="0",unviewedCursor:m="0"}=t,g=o.filter((e=>2!==e.containerType)).map((e=>{var t,n,i,o;return{url:null!==(n=null===(t=e.video)||void 0===t?void 0:t.playAddr)&&void 0!==n?n:"",id:null!==(o=null===(i=e.video)||void 0===i?void 0:i.id)&&void 0!==o?o:""}}));return 0===a&&"creator_tab"===e?(0,u.of)(...this.item.addItems(o,null==i?void 0:i.impr_id),this.getActions().addItemList({key:e,list:o,statusCode:a,hasMore:r,hasMorePrevious:s,hasMoreLatest:c,preloadList:g,addToHead:null==n?void 0:n.addToHead})):0!==a&&10404!==a||"friends"!==e?0===a||10404===a?(0,u.of)(...this.item.addItems(o,null==i?void 0:i.impr_id),this.getActions().addItemList({key:e,list:o,statusCode:a,hasMore:r,cursor:d,level:p,preloadList:g,liveCardDisplay:l})):(0,u.of)(this.getActions().addItemList({key:e,list:[],statusCode:a,hasMore:!0,preloadList:g})):(0,u.of)(...this.item.addItems(o,null==i?void 0:i.impr_id),this.getActions().addItemList({key:e,list:o,statusCode:a,hasMore:r,level:p,preloadList:g,addToHead:null==n?void 0:n.addToHead,viewedCursor:v,unviewedCursor:m}))})))}handleListData({key:e,language:t,user:n,otherInfo:i,onResponse:o,isPlayList:a}){return r=>r.pipe((0,x.w)(M.LA),(0,b.Z)((r=>{var s;return(0,p.h)((0,u.of)(this.getActions().setList({key:e,response:r,otherInfo:i,language:t,user:n,isPlayList:a})),null!==(s=null==o?void 0:o(r))&&void 0!==s?s:(0,u.of)(this.noop()))})),(0,T.Z)(this.getActions().setLoading({key:e,loading:!0})),(0,_.q)(this.getActions().setLoading({key:e,loading:!1})),(0,k.Q)(this.dispose$))}};(0,i.__decorate)([(0,o.uk)(),(0,i.__metadata)("design:type",v.c)],F.prototype,"dispose$",void 0),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"resetItemList",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"addItemList",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"setItemListById",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"removeItemListById",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"setLoading",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"setListKeyword",null),(0,i.__decorate)([(0,o.Mj)({payloadGetter:1,skipFirstClientDispatch:!1}),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getTopicList",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getFollowingList",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getFriendsList",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getQuestionList",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getPlaylistVideoList",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",v.c)],F.prototype,"getCollectionList",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getUserVideoListByType",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"getPoiList",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"setDeleteVideo",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"deleteLiveItem",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[v.c]),(0,i.__metadata)("design:returntype",void 0)],F.prototype,"setList",null),F=(0,i.__decorate)([(0,a.n)("ItemList"),(0,i.__param)(4,(0,r.y)(E.J7)),(0,i.__param)(5,(0,r.y)(j.hp)),(0,i.__param)(6,(0,r.y)(R.t.provide)),(0,i.__metadata)("design:paramtypes",[B.j,D.k,N.w,U.$,Object,Function,Function])],F);const V=(0,S.y)(F)},14576:(e,t,n)=>{"use strict";n.d(t,{j:()=>u});var i=n(58632),o=n(7672),a=n(68628),r=n(20259),s=n(68881),l=n(55099),c=n(11654),d=n(50834);let u=class{constructor(e,t){this.fetch=e,this.slardar=t}getCollectionList(e){return this.fetch.get("/api/collection/item_list/",{query:e,baseUrlType:2})}getRecommendList(e){const t=(0,s.t$)("recommendItemList");if(t)return(0,a.H)(t);const n=(0,s.DV)("recommendItemList");return n?(this.slardar.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"unknown",from:"recommendItemList"}),(0,a.H)(n).pipe((0,r.W)((()=>(this.slardar.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"fail",from:"recommendItemList"}),this.fetch.get("/api/recommend/item_list/",{query:e,baseUrlType:2})))))):this.fetch.get("/api/recommend/item_list/",{query:e,baseUrlType:2})}getTopicList(e){return this.fetch.get("/api/topic/item_list/",{query:e,baseUrlType:2})}getFollowingList(e){return this.fetch.get("/api/following/item_list/",{query:e,baseUrlType:2})}getFriendsList(e){return this.fetch.get("/api/friends/item_list/",{query:e,baseUrlType:2})}getQuestionList(e){return this.fetch.get("/api/question/item_list/",{query:e,baseUrlType:2})}getPlaylistVideoList(e){return this.fetch.get("/api/mix/item_list/",{query:e,baseUrlType:2})}getChallengeList(e){return this.fetch.get("/api/challenge/item_list/",{query:e,baseUrlType:2})}getUserPostList(e){const t=(0,s.t$)("userPostList");if(t)return(0,a.H)(t);const n=(0,s.DV)("userPostList");return n?(this.slardar.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"unknown",from:"userPostList"}),(0,a.H)(n).pipe((0,r.W)((t=>(console.log("-===error",t),this.slardar.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"fail",from:"userPostList"}),this.fetch.get("/api/post/item_list/",{query:e,baseUrlType:2})))))):this.fetch.get("/api/post/item_list/",{query:e,baseUrlType:2})}getUserPostListByType(e){return this.fetch.get("/api/post/item_list/v1/",{query:e,baseUrlType:2})}getUserPostListBiDirection(e){return this.fetch.get("/api/creator/item_list/",{query:e,baseUrlType:2})}getUserLikedList(e){return this.fetch.get("/api/favorite/item_list/",{query:e,baseUrlType:2})}getUserFavoriteList(e){return this.fetch.get("/api/user/collect/item_list/",{query:e,baseUrlType:2})}getPoiList(e){return this.fetch.get("/api/poi/item_list/",{query:e,baseUrlType:2})}getExploreList(e){const t=(0,s.DV)("exploreItemList");return t?(this.slardar.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"unknown",from:"exploreItemList"}),(0,a.H)(t).pipe((0,r.W)((()=>(this.slardar.emitEvent("consume_prefetch_data",{now:performance.now()},{status:"fail",from:"exploreItemList"}),this.fetch.get("/api/explore/item_list/",{query:e,baseUrlType:2})))))):this.fetch.get("/api/explore/item_list/",{query:e,baseUrlType:2})}getFeedCacheList(e){return this.fetch.get("/api/preload/item_list/",{query:e,baseUrlType:2})}checkItemValidation(e){return this.fetch.get("/api/item/availability/",{query:e,baseUrlType:2})}};u=(0,i.__decorate)([(0,o._)({providers:[d.t]}),(0,i.__metadata)("design:paramtypes",[l.p,c.V$])],u)},52333:(e,t,n)=>{"use strict";n.d(t,{k:()=>G,t:()=>$});var i=n(58632),o=n(4126),a=n(93995),r=n(340),s=n(87933),l=n(23999),c=n(87662),d=n(46657),u=n(68628),p=n(26324),v=n(72916),m=n(24451),g=n(62564),h=n(8536),_=n(95719),f=n(74690),y=n(64468),b=n(78288),w=n(36166),x=n(20259),T=n(34360),k=n(17995),S=n(60072),E=n(10287),A=n(6986),O=n(97071),P=n(24154),I=n(25342),C=n(67974),L=n(11983),j=n(53966),M=n(57431),N=n(55322),D=n(64356),R=n(68783),B=n(45297),U=n(55306),F=n(7672),V=n(26325),z=n(55099);let H=class{constructor(e){this.fetch=e}postLikeVideo(e){return this.fetch.post("/api/commit/item/digg/",{query:e,baseUrlType:2,headers:{[V.nk]:this.fetch.csrfToken}})}postDislikeVideo(e){return this.fetch.post("/api/dislike/item/",{query:e,baseUrlType:2,headers:{[V.nk]:this.fetch.csrfToken}})}collectVideo(e){return this.fetch.post("/api/item/collect/",{query:e,baseUrlType:2,headers:{[V.nk]:this.fetch.csrfToken}})}};H=(0,i.__decorate)([(0,F._)(),(0,i.__metadata)("design:paramtypes",[z.p])],H);var q=n(53764);let G=class extends j.E{constructor(e,t,n,i){super(),this.service=e,this.userModule=t,this.jotaiStore=n,this.t=i,this.defaultState={}}setItem(e,t){(0,S.ud)().setItem(t)}updateItem(e,t){(0,S.ud)().updateItem(t)}multiSetItem(e,t){(0,S.ud)().multiSetItem(t)}setLike(e,t){(0,S.ud)().setLike(t)}setCollect(e,t){(0,S.ud)().setCollect(t)}setCommentCount(e,t){(0,S.ud)().setCommentCount(t)}setResolutionList(e,t){(0,S.ud)().setResolutionList(t)}reduceOrIncreaseCommentCount(e,t){(0,S.ud)().reduceOrIncreaseCommentCount(t)}addItems(e,t){const n=e.filter((e=>Boolean(e.author))).map((({author:e})=>e)),i=e.filter((e=>{var t;return Boolean((null===(t=null==e?void 0:e.liveRoomInfo)||void 0===t?void 0:t.ownerInfo)&&(0,R.Jl)(e))})).map((e=>Object.assign(Object.assign({},e.liveRoomInfo.ownerInfo),{roomId:e.liveRoomInfo.roomID}))),o=e.map((e=>Object.assign(Object.assign({},e),{logId:t})));return[this.userModule.getActions().multiSetUser(n.concat(i)),this.getActions().multiSetItem(o)]}addItems$(e){return e.pipe((0,v.n)((e=>this.addItems(e))))}postCollectVideo(e){return e.pipe((0,m.E)(this.state$,this.userModule.state$),(0,g.T)((([e,t,n])=>{var i,o,a,r;const{itemId:s}=e,l=t[s],c=n.users[null!==(i=null==l?void 0:l.author)&&void 0!==i?i:""],{collected:d=!1,stats:u}=l,p=d?2:1;return{collectCount:Number(null!==(o=null==u?void 0:u.collectCount)&&void 0!==o?o:0),collected:d,action:p,query:{aid:B.xE,itemId:s,action:p,secUid:null!==(a=null==c?void 0:c.secUid)&&void 0!==a?a:""},group_id:s,author_id:null!==(r=null==c?void 0:c.id)&&void 0!==r?r:""}})),(0,h.Z)((({collectCount:e,collected:t,query:n,group_id:i,author_id:o,action:a})=>this.service.collectVideo(n).pipe((0,_.M)((()=>{A.W.handleFavoriteResult({group_id:i,author_id:o},a)})),(0,h.Z)((n=>{const{statusCode:o}=n;return 0!==o?(0,s.O)(3e3).pipe((0,g.T)((()=>this.getActions().setCollect({id:i,collected:t,count:e})))):(0,l.of)(1===a?this.getActions().addMlModelTrainData({id:i,action:"favorite"}):this.noop())})),(0,f.Z)(this.getActions().setCollect({id:i,collected:!t,count:t?Math.max(0,e-1):e+1})),(0,N.n)({})))))}postLikeVideo(e){return e.pipe((0,y.$)((({id:e})=>e)),(0,h.Z)((e=>{const t=new c.t(0);return e.pipe((0,m.E)(this.state$,this.userModule.state$,t),(0,h.Z)((([e,t,n,o])=>{var a,r,s;const{language:c,play_mode:u}=e,p=t[e.id],v=n.users[null!==(a=null==p?void 0:p.author)&&void 0!==a?a:""],{user:m}=(0,M.x)(),{digged:g,stats:h,poi:_,imagePost:f,subVideoMeta:y,ad_info:b,repostList:w}=p,{id:x,forceLike:T,enter_method:k="click",channel_id:S}=e,E=(0,i.__rest)(e,["id","forceLike","enter_method","channel_id"]),A=null!==(r=null==h?void 0:h.diggCount)&&void 0!==r?r:0,O={aweme_id:x,channel_id:S,friends_upvote:null==w?void 0:w.some((e=>e.secUid!==(null==m?void 0:m.secUid))),type:T?1:g?0:1};return T&&g?d.w:(0,l.of)({query:O,enter_method:k,diggCount:A,digged:g,author_id:null!==(s=null==v?void 0:v.id)&&void 0!==s?s:"",group_id:p.id,poi_id:null==_?void 0:_.id,restReportParams:E,changeKey:`${O.type}_${o}`,language:c,imagePost:f,play_mode:u,is_sub_only_video:y?1:0,ad_info:b})})),(0,b.w)("changeKey"),(0,v.n)((({query:e,enter_method:n,diggCount:i,author_id:o,group_id:a,digged:r,poi_id:c,imagePost:d,is_sub_only_video:u,restReportParams:p,ad_info:v})=>{let m=!1;const y=(0,s.O)(3e3).pipe((0,g.T)((()=>this.getActions().setLike({id:a,liked:r,count:i}))),(0,w.j)((()=>{const e=t.getValue();t.next(e+1)}))),b=this.getActions().setLike({id:a,liked:!r,count:r?Math.max(0,i-1):i+1});return this.service.postLikeVideo(e).pipe((0,x.W)((()=>(0,l.of)({status_code:-1}))),(0,_.M)((({status_code:t,status_msg:i,log_pb:r={}})=>{var s,l;2150!==t&&2210!==t||i&&L.F.open({content:this.t(i),duration:3,widthType:"half"}),m=!0;let g={};v&&(g=(0,O.n5)({ad_info:v,play_mode:null!==(s=p.play_mode)&&void 0!==s?s:"one_column"})),P.z.handleLikeVideoResult(Object.assign(Object.assign(Object.assign({},p),g),{group_id:a,author_id:o,log_pb:r,enter_method:n,poi_id:c,aweme_type:d?150:0,pic_cnt:null===(l=null==d?void 0:d.images)||void 0===l?void 0:l.length,is_sub_only_video:u}),e.type)})),(0,w.j)((()=>{var t,i;let r={};v&&(r=(0,O.n5)({ad_info:v,play_mode:null!==(t=p.play_mode)&&void 0!==t?t:"one_column"})),m||P.z.handleLikeVideoResult(Object.assign(Object.assign(Object.assign({},p),r),{group_id:a,author_id:o,log_pb:{},enter_method:n,poi_id:c,aweme_type:d?150:0,pic_cnt:null===(i=null==d?void 0:d.images)||void 0===i?void 0:i.length,is_sub_only_video:u}),e.type)})),(0,h.Z)((t=>{const{status_code:n,is_digg:i}=t;return 0!==n||i===e.type?y:(0,l.of)(1===e.type?this.getActions().addMlModelTrainData({id:a,action:"like"}):this.noop())})),(0,f.Z)(b),(0,N.n)({}))})))})))}addMlModelTrainData(e){return e.pipe((0,m.E)(this.state$),(0,h.Z)((([e,t])=>{var n;const{id:i,action:o,isPreview:a}=e;return i&&t[i]&&!(null===(n=t[i])||void 0===n?void 0:n.liveRoomInfo)?(0,u.H)((0,E.xt)().addTrainData({item:t[i],action:o,isPreview:a})).pipe((0,h.Z)((()=>(0,l.of)(this.noop())))):(0,l.of)(this.noop())})))}postDislikeVideo(e){return e.pipe((0,m.E)(this.state$),(0,_.M)((([e,t])=>{const{id:n,author_id:i,play_mode:o}=e,a=t[n],r=null==a?void 0:a.ad_info;let s={};r&&(s=(0,O.n5)({ad_info:r,play_mode:o}),s.refer=I.Hq.Button),C.V.handleClickDislike(Object.assign({group_id:n,author_id:i,play_mode:o},s)),L.F.open({content:this.t("webapp_forYoufeed_videoRemoved_toast"),duration:3,widthType:"half",getContainer:q.M,getContainerPosition:"fixed"})})),(0,h.Z)((([e])=>{const{id:t,author_id:n}=e,i={item_id:t,item_author_id:n};return this.service.postDislikeVideo(i).pipe((0,x.W)((()=>(0,l.of)({status_code:-1}))),(0,g.T)((()=>this.getActions().addMlModelTrainData({id:e.id,action:"dislike"}))),(0,N.n)({}))})))}setItemPrivateState(e,t){(0,S.ud)().setItemPrivateState(t)}setDeleteVideo(e,t){(0,S.ud)().setDeleteVideo(t)}};G.jotaiAtom=S.Pu,(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setItem",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"updateItem",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Array]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"multiSetItem",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setLike",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setCollect",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setCommentCount",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setResolutionList",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"reduceOrIncreaseCommentCount",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"addItems$",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",p.c)],G.prototype,"postCollectVideo",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"postLikeVideo",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"addMlModelTrainData",null),(0,i.__decorate)([(0,o.Mj)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[p.c]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"postDislikeVideo",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,Object]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setItemPrivateState",null),(0,i.__decorate)([(0,o.h5)(),(0,i.__metadata)("design:type",Function),(0,i.__metadata)("design:paramtypes",[Object,String]),(0,i.__metadata)("design:returntype",void 0)],G.prototype,"setDeleteVideo",null),G=(0,i.__decorate)([(0,a.n)("ItemModule"),(0,i.__param)(2,(0,r.y)(k.J7)),(0,i.__param)(3,(0,r.y)(D.hp)),(0,i.__metadata)("design:paramtypes",[H,U.U,Object,Function])],G);const $=(0,T.y)(G)},26325:(e,t,n)=>{"use strict";n.d(t,{$_:()=>c,F0:()=>d,Ty:()=>s,nk:()=>r,si:()=>i});const i=(0,n(34099).V)();var o,a;!function(e){e[e.Default=0]="Default",e[e.Simple=1]="Simple",e[e.None=2]="None"}(o||(o={})),function(e){e[e.None=0]="None",e[e.AWEME=1]="AWEME",e[e.FixedWww=2]="FixedWww",e[e.AutoMOrT=3]="AutoMOrT",e[e.Webcast=4]="Webcast",e[e.AutoWebcastMOrT=5]="AutoWebcastMOrT",e[e.AWEMEV1=6]="AWEMEV1",e[e.CommentTest=8]="CommentTest",e[e.WebcastT=9]="WebcastT",e[e.Now=10]="Now"}(a||(a={}));const r="tt-csrf-token",s={FORM_ENCODE:"application/x-www-form-urlencoded; charset=UTF-8",JSON:"application/json; charset=UTF-8"},l=()=>{var e,t,n;try{const i=document.getElementById("__REGION__DATA__INJECTED__");return null===(n=null===(t=JSON.parse(null!==(e=null==i?void 0:i.textContent)&&void 0!==e?e:"{}").__DATA__)||void 0===t?void 0:t.region_data_domains)||void 0===n?void 0:n.WEBAPP_WEBCAST_API}catch(e){return}};function c(e=0){var t,n,o,a,r,s,c,d;switch(e){case 9:{let e="https://webcast.tiktok.com";return"us"===i.kind&&(e="https://webcast.us.tiktok.com"),e}case 2:return null!==(t=i.rootApi)&&void 0!==t?t:"https://www.tiktok.com";case 3:return null!==(n=i.mTApi)&&void 0!==n?n:"";case 6:return null!==(o=i.rootApi)&&void 0!==o?o:"";case 4:return null!==(r=null!==(a=l())&&void 0!==a?a:i.webcastRootApi)&&void 0!==r?r:"https://webcast.tiktok.com";case 5:return null!==(s=i.webcastApi)&&void 0!==s?s:"";case 0:return null!==(c=i.rootApi)&&void 0!==c?c:"";case 8:return null!==(d=i.rootApi)&&void 0!==d?d:"";case 10:return"https://now.tiktok.com";default:return""}}function d(){var e,t;try{const n=JSON.parse(null!==(t=null===(e=window.document.getElementById("__SCHEDULE_INFO__"))||void 0===e?void 0:e.textContent)&&void 0!==t?t:"{}");if(n.to)return n}catch(e){console.warn(e)}return{from:"",to:"",dispatchParams:{}}}},237:(e,t,n)=>{"use strict";n.d(t,{Rh:()=>l,gk:()=>c,LZ:()=>u,Gy:()=>p});class i{constructor(){this.events={}}on(e,t,n={}){var i;let o=t;return n.once&&(o=function(e){let t,n=!1;return i=>(n||(t=e.apply(this,i),n=!0),t)}(t)),this.events[e]?null===(i=this.events[e])||void 0===i||i.push(o):this.events[e]=[o],()=>{var n;this.events[e]=null===(n=this.events[e])||void 0===n?void 0:n.filter((e=>t!==e))}}emit(e,...t){const n=this.events[e]||[];for(const e of n)e(...t)}clear(e){this.events[e]=[]}}const o=503,a="X-TT-System-Error",r="23",s="/api/v3/register/verification/age",l="sig_api_geoblocked",c="sig_signup_api_geoblocked";class d{constructor(){this.emitter=new i}static getInstance(){return d.instance||(d.instance=new d),d.instance}on(...e){return this.emitter.on(...e)}emit(e,t){this.emitter.emit(e,t)}clear(e){this.emitter.clear(e)}}const u=d.getInstance();function p(e,t){const n=function(e){if(!e||e.status!==o||!e.headers)return!1;const t=e.headers.get?e.headers.get(a):e.headers[a.toLowerCase()];return!(!t||t!==r)}(e);if(n)if(function(e){return e.includes(s)}(t)){const e=function(e){const t=e.split("?")[0],n=t.indexOf(s);return{domain:t.substring(0,n),path:t.substring(n)}}(t);u.emit(c,e)}else u.emit(l)}},32970:(e,t,n)=>{"use strict";n.d(t,{Y:()=>r,w:()=>a});const i=(e,t)=>{try{return sessionStorage.getItem(e)||t}catch(e){return console.warn("sessionStorage get failed"),t}};function o(e,t=""){var n;try{return null!==(n=localStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}const a=(e,t,n)=>{var a,r,s;const l=document.cookie.match(/s_v_web_id=(\w+)/);try{const c="v1"===(null===(s=null===(r=null===(a=e.abTestVersion)||void 0===a?void 0:a.parameters)||void 0===r?void 0:r.webapp_odin_id_fe_reverse)||void 0===s?void 0:s.vid),d=!!(e||{}).user,u=Object.assign(Object.assign({aid:"1988",app_name:"tiktok_web",channel:"tiktok_web",device_platform:(e||{}).isMobile?"web_mobile":"web_pc",device_id:(e||{}).wid,region:(e||{}).region,priority_region:((e||{}).user||{}).region||"",os:(e||{}).os,referer:document.referrer,root_referer:i("webapp-session-referer"),cookie_enabled:navigator.cookieEnabled,screen_width:screen.width,screen_height:screen.height,browser_language:navigator.language,browser_platform:navigator.platform,browser_name:navigator.appCodeName,browser_version:navigator.appVersion,browser_online:navigator.onLine,verifyFp:(l||"")[1],app_language:(e||{}).language,webcast_language:(e||{}).language,tz_name:Intl.DateTimeFormat().resolvedOptions().timeZone,is_page_visible:t,focus_state:n,is_fullscreen:window.matchMedia("(display-mode: fullscreen)").matches,history_len:window.history.length},c?{}:{user_is_login:d}),{data_collection_enabled:d||"1"===o("guest-mode-flag","0")});return"ageVerify"===i("enter_method")&&(u.security_verification_aid="1459"),u}catch(e){}return{}},r=()=>({cookie_enabled:navigator.cookieEnabled,screen_width:screen.width,screen_height:screen.height,browser_language:navigator.language,browser_platform:navigator.platform,browser_name:navigator.appCodeName,browser_version:navigator.appVersion,browser_online:navigator.onLine,timezone_name:Intl.DateTimeFormat().resolvedOptions().timeZone})},12904:(e,t,n)=>{"use strict";n.d(t,{CQ:()=>r,Si:()=>c,Yp:()=>a,Zu:()=>s,sG:()=>l});var i,o=n(5902);!function(e){e[e.Unknown=0]="Unknown",e[e.WebLoggedIn=513]="WebLoggedIn",e[e.WebUSNotLoggedIn=514]="WebUSNotLoggedIn",e[e.WebUSNotLoggedInHighRisk=515]="WebUSNotLoggedInHighRisk",e[e.WebNonUSNotLoggedIn=516]="WebNonUSNotLoggedIn",e[e.WebUnder13=517]="WebUnder13",e[e.WebEUNotLoggedIn=518]="WebEUNotLoggedIn",e[e.WebEUNotLoggedInHighRisk=519]="WebEUNotLoggedInHighRisk"}(i||(i={}));const a=()=>"ageVerify"===(0,o.Hd)("enter_method"),r=3058,s=3059,l={m:"va",t:"sg",us:"ttp",boe:"boe","":void 0},c="bdturing-verify"},18829:(e,t,n)=>{"use strict";n.d(t,{n:()=>i});const i=({isVA:e,isLogin:t,isFTC:n,isHighRisk:i,isEU:o=!1})=>n?517:t?513:o&&i?519:o&&!i?518:e&&i?515:e&&!i?514:516},5902:(e,t,n)=>{"use strict";n.d(t,{Gz:()=>o,Hd:()=>a,J2:()=>r});const i=()=>{};function o(e=i,t=i){let n,o;function a(){n&&document[n]?e():t()}return"hidden"in document?(n="hidden",o="visibilitychange"):"msHidden"in document?(n="msHidden",o="msvisibilitychange"):"webkitHidden"in document&&(n="webkitHidden",o="webkitvisibilitychange"),"addEventListener"in document&&n&&o?(document.addEventListener(o,a,!1),document.removeEventListener.bind(document,o,a,!1)):i}function a(e,t=""){var n;try{return null!==(n=sessionStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}function r(e,t){try{sessionStorage.setItem(e,t)}catch(e){}}},58156:(e,t,n)=>{"use strict";n.d(t,{v:()=>o});const i={useast1a:"US-East",useast2a:"US-EastRed",useast5:"US-TTP",useast8:"US-TTP2",sg1:"Singapore-Central",my:"Singapore-Central",my2:"Singapore-Central",ie:"EU-TTP",no1a:"EU-TTP2"};function o(e){var t;return void 0!==e&&null!==(t=i[e])&&void 0!==t?t:"UNKNOWN"}},74631:(e,t,n)=>{"use strict";n.d(t,{MX:()=>r});var i=n(58632);const o=1e4;var a;!function(e){e[e.Pass=0]="Pass",e[e.Reject=1]="Reject",e[e.Retry=2]="Retry"}(a||(a={}));const r=new class{constructor(){this.domId="tiktok-verify-ele",this.captcha=null,this.verifyElement=null,this.open=!1,this.rejectPass=!1,this.checkVerify=(e,t,n,a,r)=>(0,i.__awaiter)(this,void 0,void 0,(function*(){var i;if("object"!=typeof e)return e;const{statusCode:s,code:l}=null!=e?e:{};if(s===o||l===String(o)){const s=l===String(o)?e:e.verifyConfig,c=a&&n&&!s.region.startsWith("ttp")?"ttp":s.region,d=yield this.loadCaptcha(c,t);if(-1===s.fp){const e=yield null===(i=this.captcha)||void 0===i?void 0:i.getFp();s.fp=e}return d?this.open?(yield this.updateState(),this.rejectPass?1:2):yield this.goVerify(s,a,null==r?void 0:r.lang,null==r?void 0:r.userMode):1}return 0})),this.destroy=()=>{var e;null===(e=this.captcha)||void 0===e||e.close(),this.verifyElement&&(document.body.removeChild(this.verifyElement),this.verifyElement=null)}}init(){this.verifyElement||(this.verifyElement=document.createElement("div"),this.verifyElement.setAttribute("id",this.domId),document.body.appendChild(this.verifyElement))}goVerify(e,t,n,i){return this.init(),new Promise((o=>{this.openVerify((()=>{this.closeVerify(),o(2)}),(()=>{this.closeVerify(!0),o(1)}),e,t,n,i)}))}closeVerify(e=!1){var t;this.open=!1,this.rejectPass=e,null===(t=this.captcha)||void 0===t||t.close()}openVerify(e,t,n,i,o,a){var r;const s={ele:this.domId,lang:null!=o?o:"en",successCb:e,showMode:"mask",closeCb:t,errorCb:()=>{},fpCookieOption:{domain:".tiktok.com",sameSite:"None",secure:!0}};i&&(s.host=i),this.open=!0,this.rejectPass=!0,null===(r=this.captcha)||void 0===r||r.render({userMode:a,verify_data:n,captchaOptions:s})}updateState(){return new Promise((e=>{if(!this.open)return void e();const t=setInterval((()=>{this.open||(clearInterval(t),e())}),800)}))}loadCaptcha(e,t){return(0,i.__awaiter)(this,void 0,void 0,(function*(){if(!this.captcha){let i;switch(e){case"boe":case"sg":i=n.e(4336).then(n.bind(n,41002));break;case"va":i=n.e(241).then(n.bind(n,24097));break;case"ie":i=n.e(3392).then(n.bind(n,78494));break;case"no1a":i=n.e(7181).then(n.bind(n,61521));break;case"gcp":case"in":i=n.e(1427).then(n.bind(n,17819));break;case"ttp":i=n.e(2318).then(n.bind(n,10906));break;case"ttp2":i=n.e(5112).then(n.bind(n,40906));break;case"useastred":i=n.e(1618).then(n.bind(n,13530));break;default:return!1}const o=yield i;this.captcha=o,o.init({commonOptions:{aid:1988,did:t||"0",iid:"0"},captchaOptions:{fpCookieOption:{domain:".tiktok.com",sameSite:"None",secure:!0}}})}return!0}))}}},11732:(e,t,n)=>{"use strict";var i,o,a,r,s,l,c;n.d(t,{JO:()=>d,$v:()=>u}),function(e){e[e.UNDEFINED=0]="UNDEFINED",e[e.CREATE=1]="CREATE",e[e.LIVING=2]="LIVING",e[e.STOP=3]="STOP"}(i||(i={})),function(e){e[e.DEFAULT=0]="DEFAULT",e[e.PREPARE=1]="PREPARE",e[e.ONLINE=2]="ONLINE",e[e.PAUSE=3]="PAUSE",e[e.OFFLINE=4]="OFFLINE",e[e.SUSPENDED=-1]="SUSPENDED",e[e.LIVE_AND_LEAVE=-2]="LIVE_AND_LEAVE",e[e.PAID_EVENT=-3]="PAID_EVENT",e[e.SUBSCRIBER_ONLY=-4]="SUBSCRIBER_ONLY",e[e.UNAVAILABLE=-5]="UNAVAILABLE",e[e.REGIONAL_UNAVAILABLE=-6]="REGIONAL_UNAVAILABLE",e[e.Blocked=-7]="Blocked",e[e.USER_RM_BLOCK=-8]="USER_RM_BLOCK",e[e.PARENT_RM_BLOCK=-9]="PARENT_RM_BLOCK",e[e.KickOut=-10]="KickOut",e[e.E_COMMERCE_BLOCK=-11]="E_COMMERCE_BLOCK",e[e.E_COMMERCE_USER_RM=-12]="E_COMMERCE_USER_RM",e[e.E_COMMERCE_PARENT_RM=-13]="E_COMMERCE_PARENT_RM"}(o||(o={})),function(e){e.Live="tiktok_live_view_window"}(a||(a={})),function(e){e[e.TRILL=1180]="TRILL",e[e.MUSICALLY=1233]="MUSICALLY"}(r||(r={})),function(e){e.TRILL="t",e.MUSICALLY="m",e.LITE="lite"}(s||(s={})),function(e){e[e.Normal=0]="Normal",e[e.SmartPlayer=1]="SmartPlayer"}(l||(l={})),function(e){e[e.UNSET=0]="UNSET",e[e.CLOSE=1]="CLOSE",e[e.OPEN=2]="OPEN"}(c||(c={}));const d=[{name:"use_container_exp",vid:["v0","v1","v2","v3"]},{name:"share_button_part1_test",vid:["v1","v2","v3","v4"]},{name:"expose_recharge_entry_pc",vid:["v1","v2","v3"]},{name:"fyp_live_preview_265",vid:["v0","v1"]},{name:"live_studio_download_type",vid:["v1","v2"]},{name:"live_studio_entry",vid:["v1","v2","v3"]},{name:"live_context_optimize",vid:["v0","v1","v2","v3"]},{name:"live_react_query_cache",vid:["v0","v1"]},{name:"live_discover_draw_hover",vid:["v0","v1"]},{name:"live_www_host",vid:["v0","v1"]},{name:"live_persister",vid:["v0","v1"]},{name:"live_discover_enter_shortcut",vid:["v0","v1"]},{name:"live_shortcuts_all",vid:["v0","v1"]},{name:"live_shortcuts_video",vid:["v0","v1"]},{name:"live_seamless_enter_room",vid:["v1","v2"]},{name:"live_player_h265",vid:["v0","v1","v2","v3"]},{name:"live_player_switch_button",vid:["v1","v2"]},{name:"live_loading_icon",vid:["v1","v2"]},{name:"live_player_mute_text",vid:["v1","v2"]},{name:"live_player_handler",vid:["v1","v2","v3"]},{name:"live_player_icon",vid:["v1","v2"]},{name:"live_detail_non_logged_in_entry",vid:["v1","v2","v3"]},{name:"live_dynamic_bg",vid:["v1","v2"]},{name:"live_player_enable_1080p",vid:["v1","v2"]},{name:"live_auto_definition_tips",vid:["v1","v2","v3"]},{name:"live_room_age_restriction",vid:["v1","v2","v3"]},{name:"live_feed_preload",vid:["v0","v1"]},{name:"live_feed_style",vid:["v1","v2","v3"]},{name:"live_feed_auto_play_3",vid:["v1","v2","v3"]},{name:"live_player_e2e_low_delay_preload_time_test",vid:["v1","v2","v3"]},{name:"show_player_stats_entry",vid:["v1","v2"]},{name:"live_lcp_perf_optimize",vid:["v1","v2","v3","v4"]},{name:"live_report_reason_api",vid:["v1","v2"]},{name:"live_report_comment_reason_api",vid:["v1","v2"]},{name:"live_recharge_by_amount",vid:["v0","v1","v2"]},{name:"live_recharge_login",vid:["v1","v2"]},{name:"exchange_retention_popup",vid:["v1","v2"]},{name:"live_recharge_homescreen",vid:["v0","v1","v2"]},{name:"live_wallet_performance_packup",vid:["v0","v1"]},{name:"live_subscription_cashier",vid:["v1","v2"]},{name:"show_recharge_advantage",vid:["v1","v2"]},{name:"live_stack_insert_context",vid:["v1","v2"]},{name:"live_csr_insert_context",vid:["v1","v2"]},{name:"live_room_csr",vid:["v1","v2"]},{name:"webapp_fyp_live_opt",vid:["v0","v1"]},{name:"live_survey_open",vid:["v0","v1"]},{name:"live_volume_balance",vid:["v0","v1","v2"]},{name:"live_abr_rt_bitrate",vid:["v0","v1"]},{name:"live_abr_preload_stream",vid:["v0","v1","v2"]},{name:"live_abr_bb4live_optimize",vid:["v0","v1"]},{name:"live_mse_in_worker",vid:["v0","v1"]},{name:"live_gift_logged_out_control",vid:["v0","v1","v2"]},{name:"live_abr_memo",vid:["v0","v1"]},{name:"live_stage_definition",vid:["v0","v1"]},{name:"live_recharge_path_shortening_home_screen",vid:["v0","v1","v2"]},{name:"live_recharge_get_coins_entrance_for_you_page",vid:["v0","v1","v2"]},{name:"enable_ec_lcc",vid:["v0","v1"]},{name:"live_chat_message_cache_opt",vid:["v0","v1"]},{name:"live_screen_radio_opt_display_bottom",vid:["v0","v1"]},{name:"live_screen_radio_opt_side_nav",vid:["v0","v1"]},{name:"live_quick_chat_expand",vid:["v0","v1"]},{name:"live_chat_refresh_rate_opt",vid:["v0","v1","v2"]},{name:"live_chat_like_btn_animate_downgrade",vid:["v0","v1"]},{name:"live_chat_other_animate_downgrade",vid:["v0","v1"]},{name:"live_discover_animate_downgrade",vid:["v0","v1"]},{name:"live_edenx_runtime",vid:["v1","v2"]},{name:"webapp_live_nav_avatar",vid:["v0","v1"]},{name:"live_nav_entrance",vid:["v0","v1","v2"]},{name:"live_new_sidenav",vid:["v0","v1"]},{name:"live_detail_endlive_auto_feed",vid:["v0","v1","v2"]},{name:"live_recharge_one_tap_polling_optimize",vid:["v1","v2","v3"]},{name:"live_recharge_supply_entrances_for_us_mobile",vid:["v0","v1","v2"]},{name:"live_recharge_supply_entrances_for_us",vid:["v0","v1"]},{name:"live_previewcard_opt",vid:["v0","v1"]},{name:"live_chat_refactor_phase1",vid:["v0","v1"]},{name:"one_tap_ios_deep_link",vid:["v0","v1","v2","v3"]},{name:"webapp_live_avator_animation",vid:["v0","v1"]},{name:"fyp_live_card_open_direct",vid:["v0","v1"]},{name:"live_disable_header_skeleton",vid:["v0","v1"]},{name:"live_non_logged_in_time_restriction_pc",vid:["v0","v1"]},{name:"live_non_logged_in_time_restriction_mobile",vid:["v0","v1"]},{name:"live_un_logged_in_time_restriction_pc",vid:["0","30","45","60"]},{name:"live_room_preview_card_opt",vid:["v0","v1"]},{name:"webapp_live_explore_card",vid:["v0","v1"]},{name:"fyp_live_preview_guide",vid:["v0","v1","v2"]},{name:"video_feed_mode_url_test",vid:["v1","v2"]},{name:"browser_device_id",vid:["v1"]},{name:"volume_normalize",vid:["v1","v2","v3","v4"]},{name:"xgplayer_preload_config",vid:["v1","v2","v3","v4"]},{name:"hevc_desktop_server",vid:["v1","v2","v3"]},{name:"hevc_mobile_server",vid:["v1","v2","v3"]},{name:"video_serverpush",vid:["v1","v2"]},{name:"mobile_vodkit",vid:["v1","v2","v3","v4"]},{name:"web_player_refactor",vid:["v1","v2"]},{name:"xg_volume_test",vid:["v1","v2","v3","v4","v5"]},{name:"feed_scroll_opt",vid:["v0","v1"]},{name:"multiple_ins_model",vid:["v0","v2"]},{name:"multiple_ins_new",vid:["v0","v1","v2","v3","v4"]},{name:"video_bitrate_adapt",vid:["v1","v2","v3"]},{name:"explore_trending_topics",vid:["v0","v1"]},{name:"islands_arch_phase1",vid:["v0","v1"]},{name:"islands_arch_phase2",vid:["v0","v1","v2"]},{name:"islands_arch_video_detail",vid:["v0","v1"]},{name:"islands_arch_explore",vid:["v0","v1","v2"]},{name:"bundle_size_reverse",vid:["v0","v1"]},{name:"remove_tooltip",vid:["v0","v1","v2","v3","v4","v5"]},{name:"optimize_bot_ssr_count",vid:["v1","v2","v3","v4"]},{name:"sharing_reverse_recommend",vid:["v1","v2","v3","v4","v5","v6"]},{name:"sharing_use_jump_best_practice",vid:["v0","v1","v2"]},{name:"sharing_jump_best_practice_ins_afdp",vid:["v0","v1"]},{name:"sharing_android_skeleton_jump_optimization",vid:["v0","v1"]},{name:"sharing_android_auto_awaken_perf",vid:["v0","v1"]},{name:"reflow_video_s2s",vid:["v1","v2","v3"]},{name:"mobile_s2s",vid:["v1","v2"]},{name:"s2s_afdp",vid:["v0","v1"]},{name:"yml_ui_optimize",vid:["v0","v1","v2","v3"]},{name:"islands_arch_user_profile",vid:["v0","v1","v2"]},{name:"islands_arch_rest_page",vid:["v0","v1"]},{name:"feed_scroll_opt_data_collection",vid:["v0","v2"]},{name:"explore_ui_change",vid:["v0","v1","v2","v3","v4"]},{name:"mobile_search_test",vid:["v1","v2"]},{name:"pumbaa_enable_test",vid:["v1","v2"]},{name:"tt4b_ads",vid:["v1","v2"]},{name:"foryou_prefetch",vid:["v1","v2"]},{name:"studio_web_eh_entrance_v3",vid:["v1","v2","v3","v4"]},{name:"tteh_effect_anchor_v1",vid:["v1","v2"]},{name:"periodic_login_popup_interval",vid:["v1","v2","v3","v4","v5"]},{name:"enable_slardar_image",vid:["v1","v2"]},{name:"explore_shunt_test",vid:["v1","v2","v3"]},{name:"new_redirect",vid:["v0","v1"]},{name:"search_video",vid:["v1","v2","v3","v4"]},{name:"fyp_clips",vid:["v0","v1","v2"]},{name:"video_reflow_onelink_preconnect",vid:["v1","v2"]},{name:"video_reflow_android_auto_awaken",vid:["v1","v2","v3"]},{name:"video_reflow_awaken_fb",vid:["v1","v2"]},{name:"video_reflow_awaken_delay",vid:["v0","v1","v2","v3","v4"]},{name:"sharing_video_remove_rem",vid:["v1","v2"]},{name:"sharing_hashtag_pns",vid:["v1","v2"]},{name:"video_reflow_csr_skeleton_enhance",vid:["v0","v1","v2","v3"]},{name:"video_reflow_mpa_optimization",vid:["v0","v1"]},{name:"video_reflow_skeleton_ui",vid:["v0","v1"]},{name:"video_reflow_downgrade",vid:["v1","v2"]},{name:"video_reflow_refactor_server_recommend_list",vid:["v0","v1"]},{name:"video_reflow_coin_install_reverse",vid:["v0","v1"]},{name:"video_reflow_recommend_vertical_list",vid:["v0","v1","v2"]},{name:"video_reflow_recommend_sort_type",vid:["0","1","2"]},{name:"video_reflow_preload_install",vid:["v0","v1"]},{name:"video_reflow_onelink_retargeting",vid:["v0","v1","v2"]},{name:"video_reflow_gp_referer",vid:["v0","v1"]},{name:"video_reflow_facebook_af_dp",vid:["v0","v1","v2"]},{name:"webapp_vdc_scedule",vid:["v1","v2"]},{name:"search_add_live",vid:["v1","v2"]},{name:"page_loading_tiny_changes",vid:["v0","v1","v2","v3","v4"]},{name:"device_score_fetch",vid:["v0","v1","v2"]},{name:"search_transfer_history",vid:["v1","v2"]},{name:"search_transfer_guesssearch",vid:["v1","v2"]},{name:"search_top_author_card",vid:["v0","v1","v2"]},{name:"search_yml_guess_count",vid:["v0","v1","v2","v3"]},{name:"sharing_video_use_smart",vid:["v0","v1","v2"]},{name:"sharing_video_reduce_consumption",vid:["v0","v1","v2","v3","v4","v5","v6","v7","v8"]},{name:"sharing_video_coin_ui_perf",vid:["v0","v1"]},{name:"sharing_short_dl",vid:["v0","v1"]},{name:"sharing_redirect_page_strategy",vid:["v0","v1"]},{name:"sharing_video_first",vid:["v0","v1","v2","v3","v4","v5"]},{name:"sharing_video_first_use_campaign",vid:["v0","v1"]},{name:"sharing_skeleton_lite",vid:["v0","v1"]},{name:"search_bar_style_opt",vid:["v1","v2","v3"]},{name:"search_remove_related_search",vid:["v0","v1","v2"]},{name:"search_add_non_personalized_switch",vid:["v1","v2"]},{name:"search_mobile_add_search_recommendations",vid:["v1","v2"]},{name:"feed_data_cache",vid:["v1","v2","v3","v4"]},{name:"webapp_browser_mode_new_tab",vid:["v1","v2"]},{name:"qr_sso_popup",vid:["v1","v2","v3","v4","v5"]},{name:"desktop_ui_opt",vid:["v1","v2","v3","v4"]},{name:"non_personalized_feeds_web",vid:["v1","v2"]},{name:"desktop_ui_reply",vid:["v1","v2","v3","v4","v5","v6"]},{name:"desktop_avatar_nick_name",vid:["v1","v2"]},{name:"search_entry_search_bar",vid:["v1","v2"]},{name:"search_entry_comment_top",vid:["v1","v2"]},{name:"use_inbox_notice_count_api",vid:["v1","v2"]},{name:"autoscroll_reposition",vid:["v0","v1"]},{name:"banner_ad_enable",vid:["v0"]},{name:"sidenav_test",vid:["v1","v2"]},{name:"enable_dm_side_nav",vid:["v0","v1","v2","v3"]},{name:"creator_center_connect",vid:["v1","v2","v3"]},{name:"creator_center_connect_global",vid:["v1","v2","v3"]},{name:"webapp_auto_refresh",vid:["v1","v2","v3"]},{name:"change_list_length_new",vid:["30","20","15"]},{name:"preload_with_left",vid:["0","2","3","4","5"]},{name:"browser_mode_video_controller",vid:["v1","v2"]},{name:"one_column_player_size",vid:["v1","v2","v3","v4","v5"]},{name:"sign_up_webapp_region_change",vid:["v1","v2"]},{name:"video_detail_search_bar",vid:["v1","v2"]},{name:"search_entry_comment_word",vid:["v1","v2"]},{name:"confirm_logout",vid:["v1","v2"]},{name:"creator_center_reverse",vid:["v1","v2"]},{name:"desktop_app_test",vid:["v1","v2"]},{name:"browser_login_redirect",vid:["v1","v2"]},{name:"webapp_switch_account",vid:["v1","v2","v3","v4"]},{name:"search_report",vid:["v1","v2"]},{name:"search_keep_sug_show",vid:["v1","v2"]},{name:"webapp_login_email_phone",vid:["v1","v2"]},{name:"use_follow_v2",vid:["v1","v2"]},{name:"search_server",vid:{}},{name:"add_kap_entry",vid:["v1","v2"]},{name:"enable_ml_model",vid:["v1","v2","v3","v4","v5","v6"]},{name:"enable_ml_model_suggest_content",vid:["v0","v1"]},{name:"mobile_csr_test",vid:["v1","v2"]},{name:"webapp_login_prediction",vid:["v1","v2","v3","v4","v5","v6","v7","v8","v9","v10"]},{name:"login_modal_ui_revamp",vid:["v1","v2","v3","v4"]},{name:"browser_mode_encourage_login",vid:["v1","v2","v3"]},{name:"project_ace_control",vid:["v0","v1"]},{name:"soft_bank_test",vid:["v1","v2"]},{name:"enable_ads",vid:["v1","v2"]},{name:"enable_about_this_ad",vid:["v1","v2"]},{name:"digital_wellbeing_web",vid:["v0","v1"]},{name:"scheduled_breaks_teens",vid:["v0","v1"]},{name:"fix_tea_session",vid:["v1","v2","v3"]},{name:"enable_profile_pinned_video",vid:["v1","v2","v3"]},{name:"enable_fb_sdk",vid:["v1","v2"]},{name:"live_preview_web",vid:["v1","v2","v3"]},{name:"live_preview_web_son",vid:["v1","v2","v3"]},{name:"live_login_reflow_btn",vid:["v1","v2"]},{name:"comment_self_send_optimize",vid:["v0","v1"]},{name:"mobile_consumption_limit_logged_in",vid:["v1","v2","v3","v4","v5"]},{name:"mobile_consumption_limit_non_logged_in",vid:["v1","v2","v3","v4","v5","v6","v7","v8"]},{name:"add_profile_left_bar",vid:["v0","v1","v2","v3"]},{name:"explore_all_tab",vid:["v0","v1","v2","v3","v4","v5"]},{name:"report_item_tag",vid:["v1","v2"]},{name:"login_option_order_by_metrics",vid:["v1","v2","v3"]},{name:"friends_tab",vid:["v0","v1"]},{name:"remove_bottom_banner",vid:["v1","v2","v3","v4","v5"]},{name:"webapp_login_prediction_full",vid:["v1","v2"]},{name:"webapp_login_prediction_reverse",vid:["v1","v2"]},{name:"video_detail_reflow_card",vid:["v0","v1"]},{name:"show_aigc_label_web",vid:["v0","v1"]},{name:"webapp_feature_expansion",vid:["v0","v1"]},{name:"webapp_login_causal_inference",vid:["v1","v2","v3","v4","v5","v6","v7","v8","v9","v10","v11","v12","v13","v14","v15","v16","v17","v18","v19","v20","v21","v22","v23","v24","v25","v26","v27","v28","v29","v30"]},{name:"non_logged_in_comments",vid:["v1","v2","v3","v4"]},{name:"s2s",vid:["v0","v1"]},{name:"kap_prefetch",vid:["v1","v2"]},{name:"kap_jumper_opt",vid:["v1","v2"]},{name:"auto_scroll",vid:["v1","v3"]},{name:"tiktok",vid:[]},{name:"mobile_consumption_limit_login",vid:["v1","v2","v3"]},{name:"preview_cover",vid:["v0","v1"]},{name:"default_auto_scroll",vid:["v0","v1"]},{name:"search_preview_ui_change",vid:["v0","v1","v2","v3"]},{name:"seo_preview_ui_change",vid:["v0","v1"]},{name:"use_profile_avatar",vid:["v1","v2"]},{name:"perf_blur_background",vid:["v0","v1","v2","v3"]},{name:"page_init_refactor",vid:["v0","v1"]},{name:"webapp_login_causal_inference_validation",vid:["v1","v2","v3","v4","v5"]},{name:"webapp_login_causal_inference_data_collection",vid:["v1","v2","v3","v4","v5"]},{name:"webapp_causal_inference_dark_mode_data_collection",vid:["v1","v2","v3"]},{name:"webapp_causal_inference_auto_mute_data_collection",vid:["v1","v2","v3"]},{name:"webapp_causal_inference_auto_scroll_data_collection",vid:["v1","v2","v3"]},{name:"webapp_causal_inference_auto_scroll_validation",vid:["v1","v2","v3"]},{name:"webapp_causal_inference_landing_page",vid:["v0","v1"]},{name:"webapp_causal_inference_dark_mode_validation",vid:["v1","v2","v3","v4","v5"]},{name:"webapp_causal_inference_periodic_popup_validation",vid:["v1","v2","v3","v4","v5","v6","v7"]},{name:"webapp_causal_inference_auto_mute_validation",vid:["v1","v2","v3","v4","v5"]},{name:"last_login_method",vid:["v1","v2","v3"]},{name:"webapp_moderation",vid:["v0","v1"]},{name:"mobile_swiping_gesture",vid:["v0","v1"]},{name:"should_recom_reduce_icon_risk",vid:["v0","v1"]},{name:"browser_content_logic",vid:["v1","v2","v3","v4"]},{name:"mobile_predictive_data",vid:["v0","v1","v2","v3","v4","v5","v6","v7","v8","v9","v10","v11","v12","v13","v14","v15","v16","v17","v18","v19","v20","v21","v22","v23","v24","v25","v26","v27","v28","v29"]},{name:"mobile_fps_logger",vid:["v0","v1"]},{name:"delay_guest",vid:["0","1","2","3","5","8","10"]},{name:"delay_guest_fyp",vid:["0","1","2","3","5","8","10"]},{name:"delay_guest_others_homepage",vid:["0","1","2","3","5","8","10"]},{name:"delay_guest_videos",vid:["0","1","2","3","5","8","10"]},{name:"delay_guest_discover",vid:["0","1","2","3","5","8","10"]},{name:"delay_guest_explore",vid:["0","1","2","3","5","8","10"]},{name:"delay_guest_other",vid:["0","1","2","3","5","8","10"]},{name:"webapp_auto_dark_mode",vid:["v0","v1","v2","v3"]},{name:"top_right_qr",vid:["v0","v1","v2","v3"]},{name:"webapp_dynamic_bottom_right",vid:["v0","v1","v2"]},{name:"browser_fingerprint_basic",vid:["v0","v1"]},{name:"browser_fingerprint_verify",vid:["v0","v1"]},{name:"top_right_button",vid:["v0","v1","v2","v3","v4"]},{name:"top_right_button_group",vid:["v0","v1","v2","v3","v4"]},{name:"keyboard_shortcut",vid:["v0","v1","v2"]},{name:"webapp_odin_id_fe_reverse",vid:["v0","v1"]},{name:"pc_non_personalized_suggested_account",vid:["v0","v1"]},{name:"pc_non_personalized_explore",vid:["v0","v1"]},{name:"mobile_non_personalized_suggest_account",vid:["v0","v1"]},{name:"video_detail_page_video_play",vid:["v1","v2"]},{name:"mobile_replace_signup_with_login",vid:["v0","v1"]},{name:"use_aligned_copies",vid:["v0","v1","v2"]},{name:"pns_communication_service_sdk",vid:["v0","v1"]},{name:"desktop_web_survey_new",vid:["v0","v1"]},{name:"desktop_web_survey_old",vid:["v0","v1"]},{name:"promote_qr_code",vid:["v0","v1"]},{name:"mobile_remove_music_info",vid:["v0","v1"]},{name:"mobile_enable_xg",vid:["v0","v1"]},{name:"enable_mini_player",vid:["v0","v1","v2","v3","v4","v5","v6"]},{name:"enable_upload_refactor",vid:["v0","v1"]},{name:"enable_language_expansion",vid:["v0","v1","v2"]},{name:"enable_message_refactor",vid:["v0","v1"]},{name:"guest_mode_redesign",vid:["v0","v1","v2","v3"]},{name:"sharing_aso",vid:["v1","v2","v3"]},{name:"webapp_repost_label",vid:["v0","v1"]},{name:"webapp_repost_tab",vid:["v0","v1"]},{name:"webapp_repost_action",vid:["v0","v1","v2","v3","v4"]},{name:"webapp_repost_notice",vid:["v0","v1"]},{name:"webapp_creator_post_sort",vid:["v0","v1","v2","v3","v4","v5"]},{name:"webapp_creator_just_watched",vid:["v0","v1","v2","v3","v4"]},{name:"guide_user_to_next_video",vid:["v0","v1","v2"]},{name:"creator_to_fyp",vid:["v0","v1","v2"]},{name:"video_detail_end_card",vid:["v0","v1","v2","v3"]},{name:"detail_to_explore",vid:["v0","v1","v2","v3","v4"]},{name:"three_column_gif",vid:["v0","v1"]},{name:"creator_header_height",vid:["v0","v1","v2","v3"]},{name:"encourage_share_repost",vid:["v0","v1","v2","v3","v4"]},{name:"webapp_jotai_detail",vid:["v0","v1"]},{name:"video_detail_yml_ui",vid:["v1","v2","v3","v4"]},{name:"webapp_mobile_web2app_cta_guide",vid:["v0","v1","v2","v3","v4"]},{name:"video_detail_auto_pip_opt",vid:["v0","v1","v2","v3","v4","v5","v6"]},{name:"fyp_redesign",vid:["v0","v1"]},{name:"video_detail_yml_creator",vid:["v0","v1","v2"]},{name:"video_detail_author_card",vid:["v0","v1","v2","v3"]},{name:"video_detail_nav_opt",vid:["v0","v1","v2","v3"]},{name:"video_detail_nav_shortcut",vid:["v0","v1","v2","v3","v4"]},{name:"playback_refactor_desktop",vid:["v0","v1"]},{name:"playback_refactor_mobile",vid:["v0","v1"]},{name:"tt_player_hevc_ignore_env",vid:["v0","v1"]},{name:"tt_player_hevc_local",vid:["v0","v1"]},{name:"tt_player_reuse",vid:["v0","v1"]},{name:"video_details_player_redesign_engagement",vid:["v0","v1","v2","v3"]},{name:"video_details_player_redesign_player",vid:["v0","v1","v2","v3"]},{name:"web_on_device_ml",vid:["v1","v2","v3","v4"]},{name:"use_navigation_refactor",vid:["v0","v1","v2","v3","v4","v5"]},{name:"use_left_navigation_refactor",vid:["v0","v1","v2","v3"]},{name:"video_detail_responsive_ui",vid:["v0","v1","v2"]},{name:"webapp_explore_nav_order",vid:["v0","v1","v2"]},{name:"webapp_explore_video_info",vid:["v0","v1","v2","v3","v4","v5","v6"]},{name:"explore_category_ranking",vid:["v0","v1","v2"]},{name:"webapp_collection_profile",vid:["v0","v1"]},{name:"webapp_collection_adder",vid:["v0","v1","v2","v3"]},{name:"webapp_inapp_notice",vid:["v0","v1","v2","v3","v4"]},{name:"webapp_node_opt",vid:["v0","v1"]},{name:"fyf_profile_uj",vid:["v0","v1","v2","v3"]},{name:"side_nav_preload_cache",vid:["v0","v1","v2","v3","v4"]},{name:"immersive_player",vid:["v0","v1","v2","v3","v4"]},{name:"new_guest_mode_hot",vid:["v0","v1"]},{name:"new_guest_mode_other",vid:["v0","v1"]},{name:"kep_skeleton_cta",vid:["v1","v2","v3"]},{name:"kep_streaming",vid:["v0","v1","v2"]},{name:"user_ssg",vid:["v0","v1","v2"]},{name:"kep_cta_style",vid:["v0","v1","v2","v3"]},{name:"fyp_comments_panel",vid:["v0","v1","v2","v3"]},{name:"web_dm_test_force_http",vid:["v1","v2"]},{name:"reduce_user_item_list",vid:["v0","v1","v2","v3","v4","v5"]},{name:"web_dm_enable_debug",vid:["v1","v2"]},{name:"web_dm_multimedia_msg",vid:["v1","v2"]},{name:"web_dm_sticker_msg_display",vid:["v1","v2"]},{name:"web_dm_combo",vid:["v1","v2","v3"]},{name:"web_dm_group_chat",vid:["v1","v2"]},{name:"web_dm_decrease_lcp",vid:["v1","v2"]},{name:"web_dm_share_panel_fix",vid:["v1","v2"]},{name:"web_dm_icon_click_check",vid:["v1","v2"]},{name:"web_dm_quote_message",vid:["v1","v2","v3"]},{name:"web_dm_message_reaction",vid:["v1","v2"]},{name:"web_dm_list_load_optimize",vid:["v1","v2"]},{name:"webapp_query_comments_popover",vid:["v0","v1"]},{name:"user_cta_optimization_user_phase2",vid:["v0","v1","v2"]},{name:"kep_coin_app",vid:["v0","v1","v2","v3"]},{name:"fyp_hide_music_info",vid:["v0","v1","v2"]},{name:"detail_page_comments_redesign",vid:["v0","v1","v2"]},{name:"enable_autoscroll_moremenu",vid:["v0","v1"]},{name:"enable_video_detail_moremenu_refactor",vid:["v0","v1","v2","v3"]},{name:"kep_reverse_cta_fix",vid:["v0","v1"]},{name:"detail_page_comments_right_side",vid:["v0","v1","v2","v3","v4"]},{name:"fyp_on_detail",vid:["v0","v1","v2"]},{name:"webapp_fyp_cache",vid:["v0","v1"]},{name:"aggregation_page_cta_enhancement",vid:["v0","v1","v2"]},{name:"user_page_redesign",vid:["v0","v1"]},{name:"kep_pop_up_auto_dismiss",vid:["v0","v1","v2","v3"]},{name:"kep_returning_popup",vid:["v0","v1","v2"]},{name:"revamp_share_menu",vid:["v0","v1","v2","v3","v4","v5"]},{name:"remove_disclaimer",vid:["v0","v1"]},{name:"player_error_optimize",vid:["v0","v1","v2","v3"]},{name:"video_closed_caption",vid:["v0","v1","v2","v3","v4"]},{name:"video_closed_caption_v2",vid:["v0","v1"]},{name:"video_resolution",vid:["v0","v1","v2","v3"]},{name:"video_resolution_auto",vid:["v0","v1","v2"]},{name:"for_you_page_cta_enhancement",vid:["v0","v1","v2","v3","v4","v5"]},{name:"nav_phase_3",vid:["v0","v1","v2","v3"]},{name:"live_manager_entrance",vid:["v0","v1"]},{name:"image_fetch_priority",vid:["v0","v1"]},{name:"km_webapp_stm",vid:["v0","v1"]},{name:"km_default_limit",vid:["v0","v1"]},{name:"kep_video_skeleton_cta",vid:["v0","v1","v2"]},{name:"feed_change_optimize_image",vid:["v0","v1","v2"]},{name:"feed_change_optimize_ff",vid:["v0","v1","v2"]},{name:"solaria_portrait_service",vid:["v0","v1"]},{name:"enable_post_translation",vid:["v0","v1","v2","v3"]},{name:"global_web_footer",vid:["v0","v1"]},{name:"user_bundle_opt",vid:["v0","v1","v2"]},{name:"kep_click_opt_phase1",vid:["v0","v1","v2","v3"]},{name:"kep_click_opt_phase2",vid:["v0","v1","v2","v3"]},{name:"mobile_android_jump_optimization",vid:["v0","v1","v2"]},{name:"seo_jump_optimization",vid:["v0","v1"]},{name:"guest_mode_interest",vid:["v0","v1","v2"]},{name:"redesign_login_popup",vid:["v0","v1","v2","v3","v4"]},{name:"react_upgrade_experiment",vid:["v0","v1"]},{name:"desktop_faas_render",vid:["v1","v2"]},{name:"ui_layout_alignment",vid:["v1","v2","v3"]},{name:"seo_smart_awaken",vid:["v0","v1","v2"]},{name:"live_public_screen_skeleton",vid:["v0","v1"]},{name:"long_video_popup_display_optimization",vid:["false","true"]},{name:"video_reflow_poi_anchor",vid:["v0","v1"]},{name:"search_add_related_search",vid:["v1","v2"]},{name:"should_highlight_hashtag",vid:["v1","v2"]},{name:"download_page_apk",vid:["v1","v2"]},{name:"hashtag_to_top_search",vid:["v1","v2"]},{name:"it_or_us",vid:["v1","v2"]},{name:"seo_non_us_lite_copy",vid:["v0","v1"]},{name:"fyp_up_down",vid:["v0","v1"]},{name:"video_auto_play_optimize",vid:["v0","v1"]},{name:"mobile_fyp_pwa",vid:["v0","v1","v2","v3"]},{name:"grid_to_fyp",vid:["v0","v1","v2","v3","v4"]},{name:"app_style_share",vid:["v0","v1"]},{name:"all_one_tap_login",vid:["v0","v1"]},{name:"media_card_redesign",vid:["v0","v1"]},{name:"kep_exp_migration",vid:["v0","v1","v2"]},{name:"organic_video_streaming",vid:["v0","v1","v2"]},{name:"enable_setting_side_nav",vid:["v0","v1"]},{name:"community_notes_starling",vid:["v0","v1"]},{name:"cds_grid_layout",vid:["v0","v1"]},{name:"tt_player_openmse",vid:["v0","v1"]},{name:"enable_creator_comments",vid:["v0","v1"]},{name:"mobile_micro_frontends",vid:["v0","v1"]}],u=["ram_lite_use_ssa_copy","desktop_app","desktop_ui_opt_debug","add_recipe_card","enable_privacy_center","collapse_seo_header","collapse_seo_header_mobile","desktop_app_survey","shape_loggedin_disabled","hashtag_viewcount","should_show_effect_detail_page","find_migrate_video_list_api","kep_remove_desc_keywords","kep_remove_meta_desc_keywords","user_canonical_url","hashtag_canonical_url","music_canonical_url","find_card_refactor","live_edenx_runtime","kep_new_grid","enable_kep_ecommerce_search","slardar_sg_domain","live_manager_entrance","feedback_project_u_switch","feedback_project_u_faq_whitelist","feedback_project_u_submit_entry_switch","feedback_project_u_submit_page_switch"]},95584:(e,t,n)=>{"use strict";var i;n.d(t,{Y:()=>i}),function(e){let t;!function(e){e.WebSite="WebSite",e.ItemList="ItemList",e.VideoObject="VideoObject",e.SocialMediaPosting="SocialMediaPosting",e.WebPage="WebPage",e.Page="Page",e.CollectionPage="CollectionPage",e.BreadcrumbList="BreadcrumbList",e.Person="Person",e.ProfilePage="ProfilePage",e.MusicRecording="MusicRecording",e.QAPage="QAPage",e.Event="Event",e.ListItem="ListItem",e.Thing="Thing",e.Product="Product"}(t=e.JsonldType||(e.JsonldType={}))}(i||(i={}))},13761:(e,t,n)=>{"use strict";var i;n.d(t,{k:()=>i}),function(e){let t;!function(e){e[e.META_PATH=1]="META_PATH",e[e.META_EXP=2]="META_EXP",e[e.META_PAGE=3]="META_PAGE",e[e.JSONLD_PATH=4]="JSONLD_PATH",e[e.JSONLD_EXP=5]="JSONLD_EXP",e[e.JSONLD_PAGE=6]="JSONLD_PAGE"}(t=e.SERPProcessType||(e.SERPProcessType={}))}(i||(i={}))},42721:(e,t,n)=>{"use strict";n.d(t,{ET:()=>o,FR:()=>i});const i="webapp.a-b",o="b_c"},35248:(e,t,n)=>{"use strict";n.d(t,{$m:()=>i,_v:()=>o});const i=["AT","BE","BG","HR","CY","CZ","DE","DK","EE","EL","FI","FR","GR","HU","IE","IT","LV","LT","LU","MT","NL","PL","PT","RO","SK","SI","ES","SE","NO","IS","LI"],o=i.concat(["GB","CH"]);var a,r;!function(e){e.DEFAULT="DEFAULT",e.SG="ALL_SG",e.VA="MALI_VA",e.TTP="TTP",e.BOE="BOE"}(a||(a={})),function(e){e.DEFAULT="DEFAULT",e.BOE="BOE",e.US_BOE="US_BOE",e.SG="ALL_SG",e.VA="MALI_VA",e.TTP="TTP",e.EU_TTP="EU_TTP",e.US_TTP="US_TTP",e.US_TTP2="US_TTP2"}(r||(r={}))},84323:(e,t,n)=>{"use strict";n.d(t,{G:()=>r,UH:()=>o,q7:()=>i,tt:()=>a});const i=["AT","BE","BG","HR","CY","CZ","DE","DK","EE","EL","FI","FR","GB","GR","HU","IE","IT","LV","LT","LU","MT","NL","PL","PT","RO","SK","SI","ES","SE","NO","IS","LI"],o=["AO","BF","BI","BJ","BW","CD","CF","CG","CI","CM","CV","ER","ET","GA","GH","GM","GN","GQ","GW","KE","KM","LR","LS","MG","ML","MU","MW","MZ","NA","NE","NG","RW","SC","SD","SL","SN","SO","SS","ST","SZ","TD","TG","TZ","UG","ZM","ZW"],a=["JP","KR"],r=["ES","DE","PT"]},4929:(e,t,n)=>{"use strict";n.d(t,{AY:()=>a,Lq:()=>i,Nm:()=>u,TZ:()=>c,Uy:()=>o,WU:()=>p,d4:()=>s,wX:()=>d});const i="5dc26cf008d511e9b571e1bc0c9e23b5",o="3f4a780066b911eba8eda5a15496ac5a",a="c5156440043611eab3e269e42dc9b378",r={az:{displayName:"Azərbaycan",alias:[]},"id-ID":{displayName:"Bahasa Indonesia",alias:["id","id-id","in-id","in"]},"ms-MY":{displayName:"Bahasa Melayu",alias:["ms","ms-bn","ms-my"]},"jv-ID":{displayName:"Basa Jawa",alias:["jv","jv-jv"]},ca:{displayName:"Català",alias:[]},"ceb-PH":{displayName:"Cebuano",alias:["ceb","ceb-ph"]},"cs-CZ":{displayName:"Čeština",alias:["cs","cs-cz"]},da:{displayName:"Dansk",alias:[]},"de-DE":{displayName:"Deutsch",alias:["de","de-at","de-ch","de-de","de-li","de-lu"]},et:{displayName:"Eesti",alias:[]},"en-GB":{displayName:"English (UK)",alias:["en-pk","en-bd","en-bt","en-bn","en-kh","en-la","en-mm","en-np","en-lk","af","en-au","en-nz","en-sg","en-ag","en-ai","en-bb","en-bm","en-bs","en-bw","en-bz","en-dm","en-fj","en-gd","en-gh","en-gm","en-gy","en-in","en-ie","en-jm","en-rw","en-kn","en-ky","en-lc","si-lk","en-ms","en-my","en-mt","en-mu","en-mw","en-na","en-ng","ne-np","en-nr","en-pg","en-sb","en-za","en-sc","en-sl","en-tc","en-to","en-tt","en-vc","en-vg","en-vu","en-zm","en-zw","en-sz","en-hk","en-mo"]},en:{displayName:"English (US)",alias:[]},es:{displayName:"Español",alias:["es-es","es-gq","es-ad"]},"es-419":{displayName:"Español (Latinoamérica)",alias:["es"]},"fil-PH":{displayName:"Filipino",alias:["fil","tl-ph","tl","fil-ph"]},fr:{displayName:"Français",alias:["fr-be","fr-ch","fr-fr","fr-lu","fr-mc"]},"fr-CA":{displayName:"Français (Canada)",alias:["fr-ca"]},ga:{displayName:"Gaeilge",alias:[]},hr:{displayName:"Hrvatski",alias:[]},is:{displayName:"Íslenska",alias:[]},"it-IT":{displayName:"Italiano",alias:["it","it-ch","it-it"]},sw:{displayName:"Kiswahili",alias:[]},lv:{displayName:"Latviešu",alias:[]},lt:{displayName:"Lietuvių",alias:[]},"hu-HU":{displayName:"Magyar",alias:["hu","hu-hu"]},"nl-NL":{displayName:"Nederlands",alias:["nl","nl-be","nl-nl"]},nb:{displayName:"norsk (bokmål)",alias:[]},uz:{displayName:"Oʻzbek",alias:[]},"pl-PL":{displayName:"Polski",alias:["pl","pl-pl"]},pt:{displayName:"Português",alias:["pu"]},"pt-BR":{displayName:"Português (Brasil)",alias:["pt_BR","pt-br"]},"ro-RO":{displayName:"Română",alias:["ro","ro-ro"]},sq:{displayName:"Shqip",alias:[]},sk:{displayName:"Slovenčina",alias:[]},sl:{displayName:"Slovenščina",alias:[]},"fi-FI":{displayName:"Suomi",alias:["fi","fi-fi"]},"sv-SE":{displayName:"Svenska",alias:["sv","sv-se"]},"vi-VN":{displayName:"Tiếng Việt",alias:["vi","vi-vn"]},"tr-TR":{displayName:"Türkçe",alias:["tr","tr-tr"]},"el-GR":{displayName:"Ελληνικά",alias:["el","el-gr"]},bg:{displayName:"Български",alias:[]},kk:{displayName:"Қазақша",alias:[]},"ru-RU":{displayName:"Русский",alias:["ru","ru-ru"]},"uk-UA":{displayName:"Українська",alias:["uk","uk-ua"]},"he-IL":{displayName:"עברית",alias:["he","he-il","iw"]},ur:{displayName:"اردو",alias:[]},ar:{displayName:"العربية",alias:["ar-ae","ar-bh","ar-dz","ar-eg","ar-iq","ar-jo","ar-kw","ar-lb","ar-ly","ar-ma","ar-om","ar-qa","ar-sa","ar-sy","ar-tn","ar-ye"]},"hi-IN":{displayName:"हिंदी",alias:["hi","hi-in"]},"bn-IN":{displayName:"বাংলা",alias:["bn","bn-in"]},"th-TH":{displayName:"ภาษาไทย",alias:["th","th-th"]},"my-MM":{displayName:"မြန်မာ",alias:["my","my","my-mm"]},"km-KH":{displayName:"ខ្មែរ",alias:["km","km-kh"]},"ja-JP":{displayName:"日本語",alias:["ja","ja-jpan","ja-jp"]},"zh-Hant-TW":{displayName:"中文 (繁體)",alias:["zh","zh_Hant","zh_TW","zh-tw","zh-hk","zh-Hant","zh-hant-tw"]},"zh-Hans":{displayName:"中文 (简体)",alias:["zh-hans","zh_hans","zh_Hans","zh-cn","zh-sg"]},"ko-KR":{displayName:"한국어",alias:["ko","ko-kr","ko-kore"]}},s=["az","ca","da","et","en-GB","es-419","fr-CA","ga","hr","is","sw","lv","lt","nb","uz","pt","sq","sk","sl","bg","kk"],l=Object.entries(r).map((([e,{alias:t}])=>[e,...t])),c=new Map(l.reduce(((e,t)=>{const n=t[0];return t.forEach((t=>{e.push([t.toLocaleLowerCase(),n])})),e}),[])),d=Object.entries(r).map((([e,{displayName:t}])=>({label:t,value:e}))),u="en",p="tiktok_webapp_lang"},10828:(e,t,n)=>{"use strict";n.d(t,{C:()=>i,U:()=>o});const i="https://www.tiktok.com",o="https://sf-static.tiktokcdn.com/obj/eden-sg/uhtyvueh7nulogpoguhm/tiktok-icon2.png"},65450:(e,t,n)=>{"use strict";n.d(t,{X:()=>i});const i="seo.abtest"},63615:(e,t,n)=>{"use strict";n.d(t,{Ow:()=>o}),n(24643);var i=n(38259);const o="webapp.app-context";(0,i.$)("AppContext@tiktok/isomorphic")(null)},64356:(e,t,n)=>{"use strict";n.d(t,{Ss:()=>s,hp:()=>l,rv:()=>c}),n(24643);var i=n(14285),o=n(16378),a=n.n(o),r=n(67134);const s=(0,n(38259).$)("I18nContextV2@tiktok/isomorphic")({t:(e,t,n)=>n&&"string"==typeof n?n:e,hasLoaded:a(),loadStarling:a(),initialNamespaces:[],lang:""}),l=(0,r.U)("I18nInjectionToken@tiktok/isomorphic",(()=>new i.n("i18n"))),c="webapp.i18n-translation"},84987:(e,t,n)=>{"use strict";n.d(t,{X:()=>r,d:()=>s});var i=n(24643),o=n(57432),a=n.n(o);const r=(0,n(38259).$)("SVGSpriteContext@tiktok/isomorphic")({sprites:new Map,add:a(),remove:()=>!1,serialize:()=>""}),s=function({context:e,children:t}){return(0,i.jsx)(r.Provider,{value:e,children:t})}},51660:(e,t,n)=>{"use strict";n.d(t,{Z0:()=>d,uk:()=>s,x_:()=>c,qm:()=>u}),n(4474);var i=n(35267),o=n(4929);const a=/(facebookexternalhit|whatsapp|twitterbot|developers\.snap\.com\/robots|Linespider|LinkedInBot|Discordbot|TelegramBot|LarkBot|vk\.com\/dev\/Share)|redditbot/i;var r;!function(e){e.WebApp="Webapp",e.Analytics="MT_Analytics",e.Reflow="MT_Reflow",e.Login="WebApp_Login",e.POI="poi_web",e.RechargeReferral="Webapp_recharge_referral",e.KickUserFrontier="kick_user_frontier"}(r||(r={}));const s=(e="")=>"zh-Hans"===e?e:e.split("-")[0].replace("zh","zh-Hant")||e||o.Nm;function l(e){let t;return t=Array.isArray(e)?e[e.length-1]:null!=e?e:"",t}function c(e){const t=l(e).toLocaleLowerCase();return!!t&&o.TZ.has(t)}function d(e){var t,n;const i=l(e).toLocaleLowerCase();if(c(i))return null!==(t=o.TZ.get(i))&&void 0!==t?t:o.Nm;const a=s(i).toLowerCase();return null!==(n=o.TZ.get(a))&&void 0!==n?n:o.Nm}function u(e){var t,n;const{pathname:r,query:s}=(0,i.xw)(),{userAgent:l,acceptLanguage:u}=(0,i.T6)();let p=(null!=e?e:r).split("/")[1];if(function(e){return Boolean(e.startsWith("/download"))}(null!=e?e:r)&&(p=(null!=e?e:r).split("/")[2]),p&&c(p))return d(p);const{lang:v,langCountry:m,language:g,sharer_language:h}=s,_=[m,v,g];a.test(l)&&_.push(h);for(const e of _)if(e&&c(e))return d(e);const f=(0,i.MJ)(o.WU);if(f&&c(f))return d(f);const y=null===(t=l.match(/ByteFullLocale\/([\w\-_]+)/))||void 0===t?void 0:t[1];if(y&&c(y))return d(y);const b=null===(n=l.match(/ByteLocale\/([\w\-_]+)/))||void 0===n?void 0:n[1];if(b&&c(b))return d(b);for(const e of u)if(e&&c(e))return d(e);return h&&c(h)?d(h):/yandex\.com\/bots/i.test(l)?d("ru-RU"):o.Nm}},31578:(e,t,n)=>{"use strict";n.d(t,{KJ:()=>u,Ny:()=>p,R0:()=>c,qu:()=>d});const i=/\(i[^;]+;( U;)? CPU.+Mac OS X/,o=/Android|android|Adr/,a=/X11/,r=/\(Macintosh; Intel /,s=/Win\d{2}|Windows/,l=1e3;function c(e){return e.length>l?"unknown":o.test(e)?"android":a.test(e)?"linux":i.test(e)?"ios":r.test(e)?"mac":s.test(e)?"windows":"unknown"}function d(e){return!(e.length>l)&&i.test(e)}function u(e){return o.test(e)}function p(e){return d(e)||u(e)}},13474:(e,t,n)=>{"use strict";n.d(t,{PR:()=>c,Nw:()=>l});var i=n(98885),o=n.n(i);function a({uniqueId:e,secUid:t}){return function(e=""){return e&&!function(e="",t=!0){return t?/^[0-9]*$/.test(e):/^[0-9]+$/.test(e)}(e)&&!function(e=""){return e&&/[^a-zA-Z0-9\_\.]/.test(e)}(e)&&e.length<=25}(e)?e:t}const r=({uniqueId:e,secUid:t,videoId:n},i="/")=>{const o=a({uniqueId:e,secUid:t});return o&&n?`/@${o}/video/${n}`:i},s=({uniqueId:e,secUid:t,videoId:n},i="/")=>{const o=a({uniqueId:e,secUid:t});return o&&n?`/@${o}/photo/${n}`:i};function l(e,t){var n,i,a;const{defaultPath:c=""}=null!=t?t:{};if(o()(e))return c;if(null===(n=e.author)||void 0===n?void 0:n.uniqueId){const n=e;return l({uniqueId:null===(i=n.author)||void 0===i?void 0:i.uniqueId,secUid:null===(a=n.author)||void 0===a?void 0:a.secUid,videoId:n.id,isPhotomode:void 0!==n.imagePost},t)}const{uniqueId:d="",secUid:u,videoId:p,isPhotomode:v}=e;return v?s({uniqueId:d,videoId:p,secUid:u}):r({uniqueId:d,videoId:p,secUid:u})}function c(e){if(!e)return"";const{nlpLanguage:t}=e;return`/${null!=t?t:"en"}/trending/detail/${e.uniqueWord}`}},7971:(e,t,n)=>{"use strict";function i(e){let t=0;return e&&e.forEach((e=>{var n,i;t+=null!==(i=null===(n=null==e?void 0:e.stats)||void 0===n?void 0:n.playCount)&&void 0!==i?i:0})),t}function o(e,t){return a(e)}function a(e){const t=["in","on","with","by","for","at","about","under","of","to","into","from","within","throughout","inside","outside","without","beside","behind","around","over","among","and","or"];return r(e).replace(/-/g," ").toLocaleLowerCase().split(" ").map((e=>"tiktok"===e?"TikTok":t.indexOf(e)>=0?e:e.charAt(0).toUpperCase()+e.slice(1))).join(" ")}function r(e){return e?e.replace(/\x20/g,"-").toLocaleLowerCase():""}function s(e){switch(!0){case e<727:return 4;case e>=727&&e<927:return 6;case e>=927&&e<1295:return 8;case e>=1295&&e<1495:return 10;case e>=1495&&e<1695:return 12;case e>=1695&&e<1895:return 14;default:return 16}}function l(e){var t;return e&&e.length<=0?"":null!==(t=null==e?void 0:e.slice(0,6).map((e=>a(e))).join(", "))&&void 0!==t?t:""}function c(e){return e.length<=0?[]:e.map((e=>{const{pageType:t,keyword:n}=e;switch(t){case 1:return{keyword:n,linkPath:`/channel/${n}`};case 2:return{keyword:n,linkPath:`/find/${n}`};case 0:return{keyword:n,linkPath:`/discover/${n}`};default:return{keyword:n,linkPath:""}}}))}n.d(t,{K6:()=>u,Kk:()=>c,Mh:()=>s,Of:()=>r,Sq:()=>a,XH:()=>p,Zo:()=>i,gW:()=>l,pS:()=>d,zh:()=>o});const d=e=>""===e?e:e.replace(new RegExp("[\\ufff0-\\uffff]","g"),"").replace(/-/g," "),u=e=>e+Date.now().toString(),p=()=>{const e=new Date,t=e.getDay(),n=new Date(e),i=0===t?6:t-1;n.setDate(e.getDate()-i);const o=e=>`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`;return{today:o(e),monday:o(n),ISOMonday:n.toISOString()}}},57431:(e,t,n)=>{"use strict";n.d(t,{D:()=>r,x:()=>a});const i=(0,n(67134).U)("GLOBAL_STORE@tiktok/isomorphic",(()=>new Map)),o="WEBAPP_APP_CONTEXT",a=()=>{const e=i.get(o);return e||console.error("Consume appContext before init"),e},r=e=>{i.get(o)&&console.warn("AppContext will be overwritten"),i.set(o,e)}},97895:(e,t,n)=>{"use strict";n.d(t,{e:()=>l});var i=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};const o="__UNIVERSAL_DATA_FOR_REHYDRATION__",a="__$UNIVERSAL_DATA$__",r="__DEFAULT_SCOPE__";function s(e,t){var n,i,s,l;if(!window[a]){let e={};try{e=JSON.parse(null!==(i=null===(n=document.getElementById(o))||void 0===n?void 0:n.textContent)&&void 0!==i?i:"{}")}catch(e){console.error("error while parsing rehydration data")}window[a]=e}return null!==(l=null===(s=window[a][null!=t?t:r])||void 0===s?void 0:s[e])&&void 0!==l?l:null}function l(){return i(this,void 0,void 0,(function*(){var e,t,n,i,o;const a=s("webapp.app-context"),r=null==a?void 0:a.abTestVersion,l=s("seo.abtest"),c=[...Object.keys(null!==(t=null===(e=null==r?void 0:r.parameters)||void 0===e?void 0:e.clientABVersions)&&void 0!==t?t:{}),...Object.keys(null!==(i=null===(n=null==l?void 0:l.parameters)||void 0===n?void 0:n.clientABVersions)&&void 0!==i?i:{}),...null!==(o=null==l?void 0:l.vidList)&&void 0!==o?o:[]];return Array.from(new Set(c))}))}},34099:(e,t,n)=>{"use strict";n.d(t,{V:()=>a});const i={kind:"m",captcha:"",imApi:"https://im-api-va.tiktok.com",imFrontier:"wss://im-ws-va.tiktok.com/ws/v2",mTApi:"https://m.tiktok.com",rootApi:"https://www.tiktok.com",secSDK:"",slardar:"mon.tiktokv.com",starling:"https://starling-va.tiktokv.com",tea:"https://mcs-va.tiktokv.com",teaChannel:"va",teaChannelType:"tcpy",libraWebSDK:"https://libraweb-va.tiktok.com",webcastApi:"https://webcast.tiktok.com",webcastRootApi:"https://webcast.tiktok.com",tcc:"https://sf-tcc-config.tiktokcdn.com/obj/tcc-config-web-maliva/",locationApi:"https://location-va.tiktokv.com"};let o=null;const a=()=>{var e,t;if(o)return o;try{const n=JSON.parse(null!==(t=null===(e=document.querySelector("#api-domains"))||void 0===e?void 0:e.innerHTML)&&void 0!==t?t:"");return n?(o=n,n):i}catch(e){return i}}},64431:(e,t,n)=>{"use strict";n.d(t,{c:()=>a});const i={vregion:"Singapore-Central",vgeo:"VGeo-ROW"};let o=null;const a=()=>{var e,t;if(o)return o;try{const n=JSON.parse(null!==(t=null===(e=document.querySelector("#service-region"))||void 0===e?void 0:e.innerHTML)&&void 0!==t?t:"");return n?(o=n,n):i}catch(e){return i}}},33543:(e,t,n)=>{"use strict";n.d(t,{$O:()=>r,Fd:()=>s,dK:()=>o,dl:()=>a,in:()=>l,pJ:()=>i});const i="15rem",o="4.5rem",a="20rem",r="24rem",s=400,l="4.5rem";var c;!function(e){e.Suggest="suggest",e.Recommend="recommend",e.Follow="follow",e.HotLive="hotLive",e.ContinueAndWatch="continueAndWatch",e.RecommendInRoomPlayer="RecommendInRoomPlayer",e.RecommendInFeed="recommendInFeed",e.FeedCommon="feedCommon",e.FollowInFeed="followInFeed",e.GameInFeed="gameInFeed",e.EventInFeed="eventInFeed",e.LifestyleInFeed="lifestyleInFeed"}(c||(c={}))},99661:(e,t,n)=>{"use strict";n.d(t,{eE:()=>v,xq:()=>m});var i=n(94999),o=n(62302),a=n(50970),r=n(63615),s=n(57431),l=n(88874),c=n(89558),d=n(2408),u=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))},p=function(e,t,n,i){return new(n||(n=Promise))((function(o,a){function r(e){try{l(i.next(e))}catch(e){a(e)}}function s(e){try{l(i.throw(e))}catch(e){a(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,s)}l((i=i.apply(e,t||[])).next())}))};function v(e){return p(this,void 0,void 0,(function*(){try{let t=(0,l.YI)(r.Ow);if(!t){const n=yield(0,o.zI)(e);if(0!==(null==n?void 0:n.statusCode))throw new Error("AppContext API response statusCode is not 0");t=n,(0,l.A7)(r.Ow,n)}(0,s.D)(t),yield function(e){return p(this,void 0,void 0,(function*(){const t=i.l.getInstance(a.L),n=t.getActions().init({appContext:e});t.store.dispatch(n),function(e){var t,n,i,o;u(this,void 0,void 0,(function*(){"v2"===(null===(n=null===(t=e.abTestVersion)||void 0===t?void 0:t.parameters.search_add_non_personalized_switch)||void 0===n?void 0:n.vid)&&(yield(0,d.nH)().init({})),"v2"===(null===(o=null===(i=e.abTestVersion)||void 0===i?void 0:i.parameters[c.W$])||void 0===o?void 0:o.vid)&&(yield(0,d.nH)().init({isFeed:!0}))}))}(e),yield new Promise((e=>{t.state$.subscribe((t=>{t.initialized&&e()}))}))}))}(t)}catch(e){console.error(`[Fetch Base App Context Error]: ${e}`)}}))}function m(){return(0,l.YI)(r.Ow)}},94337:(e,t,n)=>{"use strict";n.d(t,{Mh:()=>c,VU:()=>d,le:()=>u});var i=n(58632),o=n(7672),a=n(340),r=n(11654),s=n(67805),l=n(4474);const c=(0,r.Yr)("@tiktok/login");let d=class{constructor(e){this.service=e,this.defaultMetrics={count:1},this.currentMethod=null,this.setCurrentRequestMethod=e=>{this.currentMethod=e},this.handleRequestResultReport=e=>{if(!this.currentMethod)return;const{error_code:t=0,function_type:n}=e,o=(0,i.__rest)(e,["error_code","function_type"]);this.service.emitEvent(this.currentMethod,this.defaultMetrics,Object.assign(Object.assign({error_code:String(t)},o),{function_type:n||this.getFunctionType(this.currentMethod,e)}))},this.handleThirdGetToken=e=>{this.currentMethod="thirdGetToken",this.handleRequestResultReport(e)},this.QRCodeShortenFail=e=>{this.service.emitEvent("qrcode_shorten_fail",this.defaultMetrics,e)},this.handleUserRegionEscape=e=>{this.service.emitEvent("userRegionEscape",this.defaultMetrics,e)},this.oneTapLoginSuccessPopupShow=()=>{const e=s.nf.getTrackingInfo();this.service.emitEvent("oneTapLoginSuccessPopupShow",this.defaultMetrics,Object.assign({},e))},this.oneTapLoginSuccessPopupClick=e=>{const t=s.nf.getTrackingInfo();this.service.emitEvent("oneTapLoginSuccessPopupClick",this.defaultMetrics,Object.assign({type:e},t))}}emitOnce(e,t){this.service.emitEvent(e,this.defaultMetrics,t)}sendLoginClickToNotifyDurationPerfMetric(e){this.service.sendCustomPerfMetric("login_click_to_notify_duration",e)}getFunctionType(e,t){switch(e){case"sendPhoneCode":case"smsLogin":case"passwordLogin":case"thirdLogin":case"getQrCodeUrl":case"checkQrconnect":case"getOauthConfig":case"cancelDeleteAccount":case"thirdGetToken":return"login";case"notLoginSendCode":case"smsVerify":case"verifyPwdWithoutLogin":case"thirdVerify":return"verify";case"validateMobileCodeForLogin":case"validateEmailCodeForLogin":case"validateMobileCodeForReset":case"verifySendEmailCode":case"sendEmailCodeForLogin":case"emailCodeLogin":return"twostep";case"sendPhoneCodeWithType":return String(t.type).match(/13|12/)?"twostep":"reset";case"sendPhoneCodeForResetPwd":case"sendEmailCodeForResetPwd":case"resetPwdLoginByEmail":case"changePwdByMobile":return"reset";case"sendEmailCodeForForceResetPwd":case"sendPhoneCodeForForceResetPwd":case"validatePhoneCodeForForceReset":case"validateEmailCodeForForceReset":case"forceResetPwdByMobileTicket":case"forceResetPwdByEmailTicket":return"forcereset";case"sendEmailCodeForSignup":case"smsLoginContinue":case"usernameRegister":case"setAccount":case"emailRegister":return"signup";case"oidcPrepare":case"oidcLogin":case"checkOneTapState":case"getOneTapToken":return"onetap";default:return"ttp"}}};d=(0,i.__decorate)([(0,o._)(),(0,i.__param)(0,(0,a.y)(c.INJECTION_TOKEN)),(0,i.__metadata)("design:paramtypes",[r.V$])],d);let u=class{constructor(e){this.service=e,this.defaultMetrics={count:1},this.enterMethod="login",this.enterFrom="login",this.platform="unknown"}setPlatform(e){this.platform=e}setEnterMethod(e){this.enterMethod=e}setEnterFrom(){const e=(0,l.parse)(location.search);this.enterFrom=e.enter_from||"unknown"}loginNotify(){const e=s.nf.getTrackingInfo();this.service.emitEvent("login_notify",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom},e))}clickLoginOption(e={}){const{isSignUp:t}=e,n=s.nf.getTrackingInfo();this.service.emitEvent("click_login_button",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom,is_register:t?"1":"0"},n))}loginSubmit(e={}){const{signUp:t,forgetPwd:n}=e,i=s.nf.getTrackingInfo();this.service.emitEvent("login_submit",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom,platform:this.platform,is_register:t?"1":"0",is_forget_password:n?"1":"0"},i))}loginSuccess(e={}){var t;const n=null!==(t=e.e2eInfo)&&void 0!==t?t:s.nf.getTrackingInfo(),{signUp:i,forgetPwd:o}=e;this.service.emitEvent("login_success",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom,platform:this.platform,is_register:i?"1":"0",is_forget_password:o?"1":"0"},n))}loginFailure(e){const t=s.nf.getTrackingInfo(),{signUp:n,errorCode:i,errorMsg:o,forgetPwd:a}=e;this.service.emitEvent("login_failure",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom,platform:this.platform,is_register:n?"1":"0",error_code:String(i),is_forget_password:a?"1":"0",error_message:null!=o?o:""},t))}logout(e){var t;this.service.emitEvent("monitor_logout",this.defaultMetrics,{enter_method:this.enterMethod,enter_from:this.enterFrom,status:String(e.status),error_code:String(e.error_code),error_desc:null!==(t=e.error_desc)&&void 0!==t?t:""})}logoutSubmit(e={}){this.service.emitEvent("logout_submit",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom},e))}logoutCancel(e={}){this.service.emitEvent("logout_cancel",this.defaultMetrics,Object.assign({enter_method:this.enterMethod,enter_from:this.enterFrom},e))}};u=(0,i.__decorate)([(0,o._)(),(0,i.__param)(0,(0,a.y)(c.INJECTION_TOKEN)),(0,i.__metadata)("design:paramtypes",[r.V$])],u)},69589:(e,t,n)=>{"use strict";n.d(t,{QueryProvider:()=>I,getDataForQueryByKey:()=>l,performManualOptimisticUpdate:()=>m,setDataForQueryByKey:()=>d,useData:()=>M,useDataWithInfinite:()=>N,useMutateAction:()=>D,useWebAppQuery:()=>j});var i=n(24643),o=n(86805);function a(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function r(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var r=e.apply(t,n);function s(e){a(r,i,o,s,l,"next",e)}function l(e){a(r,i,o,s,l,"throw",e)}s(void 0)}))}}const s=new(n(84724).E)({defaultOptions:{queries:{staleTime:1/0}}}),l=e=>{try{const t=s.getQueryData(e);if(!t)throw new Error(`Failed to get query data for key ${e}. Verify your query key`);return t}catch(e){}},c=(e,t)=>{try{return s.setQueryData(e,t)}catch(t){throw new Error(`Failed to set query data for key ${e}. Verify your query key`)}},d=(e,t)=>{try{return s.setQueryData(e,t)}catch(t){throw new Error(`Failed to set query data for key ${e}. Verify your query key`)}},u=(p=r((function*(e,t){yield s.cancelQueries(e);const n=(e=>{try{const t=s.getQueryData(e);if(!t)throw new Error(`Failed to get query data for key ${e}. Verify your query key`);return t}catch(e){}})(e);return c(e,t),n})),function(e,t){return p.apply(this,arguments)});var p;const v=function(){var e=r((function*(e){}));return function(t){return e.apply(this,arguments)}}(),m=(r((function*(e){yield s.invalidateQueries(e)})),function(){var e=r((function*(e,t){yield s.cancelQueries(e),c(e,t)}));return function(t,n){return e.apply(this,arguments)}}());var g=n(94014),h=n(69958),_=n(91043);function f(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function y(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){f(a,i,o,r,s,"next",e)}function s(e){f(a,i,o,r,s,"throw",e)}r(void 0)}))}}function b(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w(e){for(var t=1;t=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}class T{constructor(e){this.useData=e=>{const{query:t,queryKeyParams:n,queryParams:i}=e,o=this.webappConfig.query[t],a=o.queryKeys(n);return(0,g.I)({queryKey:a,queryFn:y((function*(){return o.queryFn(i)}))})},this.useDataWithInfinite=e=>{const{query:t,queryKeyParams:n,queryParams:i,options:o}=e,a=this.webappConfig.query[t],r=a.queryKeys(n),s=(0,h.q)(w({queryKey:r,queryFn:function(){var e=y((function*({pageParam:e}){return a.queryFn((t=w({},i),n=null!=(n={cursor:e})?n:{},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t}(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))})),t));var t,n}));return function(t){return e.apply(this,arguments)}}(),getNextPageParam:e=>e.hasMore?e.cursor:void 0},o));return s},this.useMutateAction=e=>{var t;const{mutatorName:n,options:i}=e,o=this.webappConfig.mutation[n],{mutationFn:a}=o;var r;const s="queryKeys"in o&&null!==(r=null===(t=o.queryKeys)||void 0===t?void 0:t.call(o,e.queryKeyParams))&&void 0!==r?r:[];return(0,_.n)(w({mutationFn:a},"optimisticUpdate"in o?{onMutate:e=>{var t;return u(s,null===(t=o.optimisticUpdate)||void 0===t?void 0:t.call(o,e))},onError:e=>{c(s,e)},onSettled:()=>v(s)}:{},i))};var t=this;this.prefetchQuery=function(){var e=y((function*(e){const{query:n,queryKeyParams:i,queryParams:o}=e,a=x(e,["query","queryKeyParams","queryParams"]),r=t.webappConfig.query[n],l=r.queryKeys(i);return s.prefetchQuery(w({queryKey:l,queryFn:()=>r.queryFn(o)},a))}));return function(t){return e.apply(this,arguments)}}();var n=this;this.prefetchInfiniteQuery=function(){var e=y((function*(e){const{query:t,queryKeyParams:i,queryParams:o}=e,a=x(e,["query","queryKeyParams","queryParams"]),r=n.webappConfig.query[t],l=r.queryKeys(i);return s.prefetchInfiniteQuery(w({queryKey:l,queryFn:()=>r.queryFn(o)},a))}));return function(t){return e.apply(this,arguments)}}(),this.webappConfig=(e=>{const t={query:{},mutation:{}};for(const n of e)Object.assign(t.query,n.query),Object.assign(t.mutation,n.mutation);return t})(e)}}var k=n(40099),S=n(38259);let E,A=!1;const O=()=>(A||(E=(0,S.$)("queryContext@tiktok-fe/webapp-query")({}),A=!0),E),P=()=>(0,k.useContext)(O()),I=e=>{const{children:t,apiConfigs:n}=e,a=new T(n),r=O();return(0,i.jsx)(o.Ht,{client:s,children:(0,i.jsxs)(r.Provider,{value:a,children:[t," "]})})};function C(e,t,n,i,o,a,r){try{var s=e[a](r),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function L(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function r(e){C(a,i,o,r,s,"next",e)}function s(e){C(a,i,o,r,s,"throw",e)}r(void 0)}))}}n(78007);const j=()=>P(),M=e=>{const{useData:t}=P();return t(e)},N=e=>{const{useDataWithInfinite:t}=P();return t(e)},D=e=>{const{useMutateAction:t}=P();return t(e)};L((function*(e,t){const{prefetchQuery:n}=P();(0,k.useEffect)((()=>{n(e)}),t)})),L((function*(e,t){const{prefetchInfiniteQuery:n}=P();(0,k.useEffect)((()=>{n(e)}),t)}))},15015:()=>{},78007:(e,t,n)=>{"use strict";var i=n(13832);n.o(i,"useData")&&n.d(t,{useData:function(){return i.useData}}),n.o(i,"useDataWithInfinite")&&n.d(t,{useDataWithInfinite:function(){return i.useDataWithInfinite}}),n.o(i,"useMutateAction")&&n.d(t,{useMutateAction:function(){return i.useMutateAction}}),n.o(i,"useWebAppQuery")&&n.d(t,{useWebAppQuery:function(){return i.useWebAppQuery}});var o=n(8130);n.o(o,"useData")&&n.d(t,{useData:function(){return o.useData}}),n.o(o,"useDataWithInfinite")&&n.d(t,{useDataWithInfinite:function(){return o.useDataWithInfinite}}),n.o(o,"useMutateAction")&&n.d(t,{useMutateAction:function(){return o.useMutateAction}}),n.o(o,"useWebAppQuery")&&n.d(t,{useWebAppQuery:function(){return o.useWebAppQuery}});var a=n(15015);n.o(a,"useData")&&n.d(t,{useData:function(){return a.useData}}),n.o(a,"useDataWithInfinite")&&n.d(t,{useDataWithInfinite:function(){return a.useDataWithInfinite}}),n.o(a,"useMutateAction")&&n.d(t,{useMutateAction:function(){return a.useMutateAction}}),n.o(a,"useWebAppQuery")&&n.d(t,{useWebAppQuery:function(){return a.useWebAppQuery}})},13832:()=>{},8130:()=>{},8227:(e,t,n)=>{"use strict";n.d(t,{O:()=>s,vI:()=>r});var i,o,a=n(55907);!function(e){e.euTaxForm="euTaxForm",e.w9TaxSelect="w9TaxSelect",e.w9TaxInputIndividual="w9TaxInputIndividual",e.w9TaxInputEntity="w9TaxInputEntity",e.taxPaperlessConsent="taxPaperlessConsent",e.taxComplete="taxComplete",e.taxInfoUs="taxInfoUs",e.w8TaxInput="w8TaxInput",e.taxInfoW8="taxInfoW8",e.taxOverview="taxOverview",e.kyc="kyc",e.kycLoading="kycLoading",e.kycPoa="kycPoa",e.kycSubmission="kycSubmission",e.liveDiscover="liveDiscover",e.liveGoLive="liveGoLive",e.liveRoom="liveRoom",e.liveEvent="liveEvent",e.liveRoomEmbed="liveRoomEmbed",e.rechargeBindInfo="rechargeBindInfo",e.studioLogin="studioLogin",e.studioDownload="studioDownload",e.studioFaq="studioFaq",e.liveSubscription="liveSubscription",e.liveSubscriptionGuide="liveSubscriptionGuide",e.liveSubscriptionBadgeSetting="liveSubscriptionBadgeSetting",e.liveSubscriptionEmoteSetting="liveSubscriptionEmoteSetting",e.liveSubscriptionComplete="liveSubscriptionComplete",e.liveSubscriptionSetting="liveSubscriptionSetting",e.liveSubscriptionMysubsription="liveSubscriptionMysubsription",e.giftCpcFaq="giftCpcFaq",e.liveFollowing="liveFollowing",e.liveGaming="liveGaming",e.liveSingleGaming="liveSingleGaming",e.liveEventAggregation="liveEventAggregation",e.liveCategory="liveCategory",e.liveCategoryGaming="liveCategoryGaming",e.liveCategoryLifestyle="liveCategoryLifestyle",e.liveCategorySingleGaming="liveCategorySingleGaming",e.liveCategorySingleLifeStyle="liveCategorySingleLifeStyle",e.liveCategorySingleAction="liveCategorySingleAction",e.liveLifestyle="liveLifestyle",e.liveExplore="liveExplore",e.liveMenaAction="liveMenaAction"}(i||(i={})),function(e){e.euTaxForm="euTaxForm",e.w9TaxSelect="w9TaxSelect",e.w9TaxInputIndividual="w9TaxInputIndividual",e.w9TaxInputEntity="w9TaxInputEntity",e.taxPaperlessConsent="taxPaperlessConsent",e.taxComplete="taxComplete",e.taxInfoUs="taxInfoUs",e.w8TaxInput="w8TaxInput",e.taxInfoW8="taxInfoW8",e.taxOverview="taxOverview",e.kyc="kyc",e.kycLoading="kycLoading",e.kycPoa="kycPoa",e.kycSubmission="kycSubmission",e.liveDiscover="liveDiscover",e.liveGoLive="liveGoLive",e.liveRoom="liveRoom",e.liveEvent="liveEvent",e.liveRoomEmbed="liveRoomEmbed",e.rechargeBindInfo="rechargeBindInfo",e.studioLogin="studioLogin",e.studioDownload="studioDownload",e.studioFaq="studioFaq",e.liveSubscription="liveSubscription",e.liveSubscriptionGuide="liveSubscriptionGuide",e.liveSubscriptionBadgeSetting="liveSubscriptionBadgeSetting",e.liveSubscriptionEmoteSetting="liveSubscriptionEmoteSetting",e.liveSubscriptionComplete="liveSubscriptionComplete",e.liveSubscriptionSetting="liveSubscriptionSetting",e.liveSubscriptionMysubsription="liveSubscriptionMysubsription",e.giftCpcFaq="giftCpcFaq",e.liveFollowing="liveFollowing",e.liveGaming="liveGaming",e.liveSingleGaming="liveSingleGaming",e.liveEventAggregation="liveEventAggregation",e.liveCategory="liveCategory",e.liveCategoryGaming="liveCategoryGaming",e.liveCategoryLifestyle="liveCategoryLifestyle",e.liveCategorySingleGaming="liveCategorySingleGaming",e.liveCategorySingleLifeStyle="liveCategorySingleLifeStyle",e.liveCategorySingleAction="liveCategorySingleAction",e.liveLifestyle="liveLifestyle",e.liveExplore="liveExplore",e.liveMenaAction="liveMenaAction"}(o||(o={}));const r={euTaxForm:"/tax/eu-tax",w9TaxSelect:"/tax/us-w9-tax-select",w9TaxInputIndividual:"/tax/us-w9-tax-input-individual",w9TaxInputEntity:"/tax/us-w9-tax-input-entity",taxPaperlessConsent:"/tax/paperless-consent",taxComplete:"/tax/complete",taxInfoUs:"/tax/info-us",w8TaxInput:"/tax/w8-tax-input",taxInfoW8:"/tax/info-w8",taxOverview:"/tax/tax-overview",kyc:"/kyc",kycLoading:"/kyc/loading",kycPoa:"/kyc/poa",kycSubmission:"/kyc/submission",liveDiscover:"/live",liveGoLive:"/live/producer",liveRoom:"/:uniqueId/live",liveEvent:"/live/event/:eventId",liveRoomEmbed:"/embed/:uniqueId/live",rechargeBindInfo:"/recharge/bind-info",studioLogin:"/studio/login",studioDownload:"/studio/download",studioFaq:"/studio/faq",liveSubscription:"/live/subscription",liveSubscriptionGuide:"/live/subscription/guide",liveSubscriptionBadgeSetting:"/live/subscription/badge-setting",liveSubscriptionEmoteSetting:"/live/subscription/emote-setting",liveSubscriptionComplete:"/live/subscription/complete",liveSubscriptionSetting:"/live/subscription/setting",liveSubscriptionMysubsription:"/live/subscription/my-subscription",giftCpcFaq:"/live/gift/cpc/faq",liveFollowing:"/live/following",liveGaming:"/live/gaming",liveSingleGaming:"/live/gaming/:gameId",liveEventAggregation:"/live/event",liveCategory:"/live/category",liveCategoryGaming:"/live/category/gaming",liveCategoryLifestyle:"/live/category/lifestyle",liveCategorySingleGaming:"/live/category/gaming/:gameTag",liveCategorySingleLifeStyle:"/live/category/lifestyle/:category",liveCategorySingleAction:"/live/category/action/:action",liveLifestyle:"/live/lifestyle",liveExplore:"/live/explore/:keywords",liveMenaAction:"/live/mena-action"},s=(0,a.w)(r);var l;!function(e){e.euTaxForm="euTaxForm",e.w9TaxSelect="w9TaxSelect",e.w9TaxInputIndividual="w9TaxInputIndividual",e.w9TaxInputEntity="w9TaxInputEntity",e.taxPaperlessConsent="taxPaperlessConsent",e.taxComplete="taxComplete",e.taxInfoUs="taxInfoUs",e.w8TaxInput="w8TaxInput",e.taxInfoW8="taxInfoW8",e.taxOverview="taxOverview",e.kyc="kyc",e.kycLoading="kycLoading",e.kycPoa="kycPoa",e.kycSubmission="kycSubmission",e.liveDiscover="liveDiscover",e.liveGoLive="liveGoLive",e.liveRoom="liveRoom",e.liveEvent="liveEvent",e.liveRoomEmbed="liveRoomEmbed",e.rechargeBindInfo="rechargeBindInfo",e.studioLogin="studioLogin",e.studioDownload="studioDownload",e.studioFaq="studioFaq",e.liveSubscription="liveSubscription",e.liveSubscriptionGuide="liveSubscriptionGuide",e.liveSubscriptionBadgeSetting="liveSubscriptionBadgeSetting",e.liveSubscriptionEmoteSetting="liveSubscriptionEmoteSetting",e.liveSubscriptionComplete="liveSubscriptionComplete",e.liveSubscriptionSetting="liveSubscriptionSetting",e.liveSubscriptionMysubsription="liveSubscriptionMysubsription",e.giftCpcFaq="giftCpcFaq",e.liveFollowing="liveFollowing",e.liveGaming="liveGaming",e.liveSingleGaming="liveSingleGaming",e.liveEventAggregation="liveEventAggregation",e.liveCategory="liveCategory",e.liveCategoryGaming="liveCategoryGaming",e.liveCategoryLifestyle="liveCategoryLifestyle",e.liveCategorySingleGaming="liveCategorySingleGaming",e.liveCategorySingleLifeStyle="liveCategorySingleLifeStyle",e.liveCategorySingleAction="liveCategorySingleAction",e.liveLifestyle="liveLifestyle",e.liveExplore="liveExplore",e.liveMenaAction="liveMenaAction"}(l||(l={}))},75792:(e,t,n)=>{"use strict";n.d(t,{Bd:()=>c,Iv:()=>r,tH:()=>l});var i,o=n(11430);!function(e){e.loginHome="loginHome",e.loginPhoneOrEmail="loginPhoneOrEmail",e.loginPhone="loginPhone",e.loginEmail="loginEmail",e.loginPhonePassword="loginPhonePassword",e.loginDownloadApp="loginDownloadApp",e.loginTwoStepVerify="loginTwoStepVerify",e.loginForgetEmailPassword="loginForgetEmailPassword",e.loginForgetPhonePassword="loginForgetPhonePassword",e.loginQRcode="loginQRcode",e.loginSSO="loginSSO",e.loginGuestMode="loginGuestMode",e.tvLoginHome="tvLoginHome",e.tvLoginPhone="tvLoginPhone",e.tvLoginEmail="tvLoginEmail",e.loginWithSignedEmail="loginWithSignedEmail",e.loginPhoneDigit="loginPhoneDigit",e.loginReset="loginReset",e.phoneResetDigit="phoneResetDigit",e.emailResetDigit="emailResetDigit",e.resetPassword="resetPassword",e.signupHome="signupHome",e.signupPhoneOrEmail="signupPhoneOrEmail",e.signupPhone="signupPhone",e.signupEmail="signupEmail",e.signupAgeGate="signupAgeGate",e.signupAgeGateConfirm="signupAgeGateConfirm",e.signupPolicyConfirm="signupPolicyConfirm",e.signupCreateAccount="signupCreateAccount",e.signupCreateUsername="signupCreateUsername",e.signupCreatePassword="signupCreatePassword",e.signupPrivateOn="signupPrivateOn",e.signupPhoneDigit="signupPhoneDigit",e.signupEmailDigit="signupEmailDigit",e.signupEmailCreatePassword="signupEmailCreatePassword",e.signupCountrySelector="signupCountrySelector",e.signupInterestSelector="signupInterestSelector",e.oauth="oauth",e.oauthLine="oauthLine",e.accountDeactivate="accountDeactivate",e.logout="logout",e.linkPhoneOrEmail="linkPhoneOrEmail",e.linkPhone="linkPhone",e.linkEmail="linkEmail",e.linkPhoneDigit="linkPhoneDigit",e.linkEmailDigit="linkEmailDigit"}(i||(i={}));const a={loginHome:"/login",loginPhoneOrEmail:"/login/phone-or-email",loginPhone:"/login/phone-or-email/phone",loginEmail:"/login/phone-or-email/email",loginPhonePassword:"/login/phone-or-email/phone-password",loginDownloadApp:"/login/download-app",loginTwoStepVerify:"/login/2sv/:type",loginForgetEmailPassword:"/login/email/forget-password",loginForgetPhonePassword:"/login/phone/forget-password",loginQRcode:"/login/qrcode",loginSSO:"/login/sso",loginGuestMode:"/login/guest-mode",tvLoginHome:"/login/tv",tvLoginPhone:"/login/tv/phone",tvLoginEmail:"/login/tv/email",loginWithSignedEmail:"/login/with-signed-email",loginPhoneDigit:"/login/phone/digit-code",loginReset:"/login/reset",phoneResetDigit:"/login/reset/phone/digit-code",emailResetDigit:"/login/reset/email/digit-code",resetPassword:"/login/reset/password",signupHome:"/signup",signupPhoneOrEmail:"/signup/phone-or-email",signupPhone:"/signup/phone-or-email/phone",signupEmail:"/signup/phone-or-email/email",signupAgeGate:"/signup/age-gate",signupAgeGateConfirm:"/signup/age-gate/confirm",signupPolicyConfirm:"/signup/policy-confirm",signupCreateAccount:"/signup/create-account",signupCreateUsername:"/signup/create-username",signupCreatePassword:"/signup/create-password",signupPrivateOn:"/signup/private-on",signupPhoneDigit:"/signup/phone/digit-code",signupEmailDigit:"/signup/email/digit-code",signupEmailCreatePassword:"/signup/email/create-password",signupCountrySelector:"/signup/country-selector",signupInterestSelector:"/signup/interest",oauth:"/oauth",oauthLine:"/oauthLine",accountDeactivate:"/setting/account-delete/deactivate",logout:"/logout",linkPhoneOrEmail:"/link-phone-or-email",linkPhone:"/link-phone-or-email/phone",linkEmail:"/link-phone-or-email/email",linkPhoneDigit:"/link-phone-or-email/phone/digit-code",linkEmailDigit:"/link-phone-or-email/email/digit-code"},r=(0,o.r)(a);var s;!function(e){e.loginHome="loginHome",e.loginPhoneOrEmail="loginPhoneOrEmail",e.loginPhone="loginPhone",e.loginEmail="loginEmail",e.loginPhonePassword="loginPhonePassword",e.loginDownloadApp="loginDownloadApp",e.loginTwoStepVerify="loginTwoStepVerify",e.loginForgetEmailPassword="loginForgetEmailPassword",e.loginForgetPhonePassword="loginForgetPhonePassword",e.loginQRcode="loginQRcode",e.loginSSO="loginSSO",e.loginGuestMode="loginGuestMode",e.tvLoginHome="tvLoginHome",e.tvLoginPhone="tvLoginPhone",e.tvLoginEmail="tvLoginEmail",e.loginWithSignedEmail="loginWithSignedEmail",e.loginPhoneDigit="loginPhoneDigit",e.loginReset="loginReset",e.phoneResetDigit="phoneResetDigit",e.emailResetDigit="emailResetDigit",e.resetPassword="resetPassword",e.signupHome="signupHome",e.signupPhoneOrEmail="signupPhoneOrEmail",e.signupPhone="signupPhone",e.signupEmail="signupEmail",e.signupAgeGate="signupAgeGate",e.signupAgeGateConfirm="signupAgeGateConfirm",e.signupPolicyConfirm="signupPolicyConfirm",e.signupCreateAccount="signupCreateAccount",e.signupCreateUsername="signupCreateUsername",e.signupCreatePassword="signupCreatePassword",e.signupPrivateOn="signupPrivateOn",e.signupPhoneDigit="signupPhoneDigit",e.signupEmailDigit="signupEmailDigit",e.signupEmailCreatePassword="signupEmailCreatePassword",e.signupCountrySelector="signupCountrySelector",e.signupInterestSelector="signupInterestSelector",e.oauth="oauth",e.oauthLine="oauthLine",e.accountDeactivate="accountDeactivate",e.logout="logout",e.linkPhoneOrEmail="linkPhoneOrEmail",e.linkPhone="linkPhone",e.linkEmail="linkEmail",e.linkPhoneDigit="linkPhoneDigit",e.linkEmailDigit="linkEmailDigit"}(s||(s={}));const l={loginHome:"/login",loginPhoneOrEmail:"/login/phone-or-email",loginPhone:"/login/phone-or-email/phone",loginEmail:"/login/phone-or-email/email",loginPhonePassword:"/login/phone-or-email/phone-password",loginDownloadApp:"/login/download-app",loginTwoStepVerify:"/login/2sv/:type",loginForgetEmailPassword:"/login/email/forget-password",loginForgetPhonePassword:"/login/phone/forget-password",loginQRcode:"/login/qrcode",loginSSO:"/login/sso",loginGuestMode:"/login/guest-mode",tvLoginHome:"/login/tv",tvLoginPhone:"/login/tv/phone",tvLoginEmail:"/login/tv/email",loginWithSignedEmail:"/login/with-signed-email",loginPhoneDigit:"/login/phone/digit-code",loginReset:"/login/reset",phoneResetDigit:"/login/reset/phone/digit-code",emailResetDigit:"/login/reset/email/digit-code",resetPassword:"/login/reset/password",signupHome:"/signup",signupPhoneOrEmail:"/signup/phone-or-email",signupPhone:"/signup/phone-or-email/phone",signupEmail:"/signup/phone-or-email/email",signupAgeGate:"/signup/age-gate",signupAgeGateConfirm:"/signup/age-gate/confirm",signupPolicyConfirm:"/signup/policy-confirm",signupCreateAccount:"/signup/create-account",signupCreateUsername:"/signup/create-username",signupCreatePassword:"/signup/create-password",signupPrivateOn:"/signup/private-on",signupPhoneDigit:"/signup/phone/digit-code",signupEmailDigit:"/signup/email/digit-code",signupEmailCreatePassword:"/signup/email/create-password",signupCountrySelector:"/signup/country-selector",signupInterestSelector:"/signup/interest",oauth:"/oauth",oauthLine:"/oauthLine",accountDeactivate:"/setting/account-delete/deactivate",logout:"/logout",linkPhoneOrEmail:"/link-phone-or-email",linkPhone:"/link-phone-or-email/phone",linkEmail:"/link-phone-or-email/email",linkPhoneDigit:"/link-phone-or-email/phone/digit-code",linkEmailDigit:"/link-phone-or-email/email/digit-code"},c=(0,o.r)(l)},97497:(e,t,n)=>{"use strict";n.d(t,{Lj:()=>s});var i,o,a=n(55907);!function(e){e.video="video",e.photo="photo",e.user="user",e.music="music",e.challenge="challenge",e.musicPlaylist="musicPlaylist",e.collection="collection",e.videoPlaylist="videoPlaylist",e.searchReflow="searchReflow",e.sticker="sticker",e.group="group",e.chat="chat"}(i||(i={})),function(e){e.video="video",e.photo="photo",e.user="user",e.music="music",e.challenge="challenge",e.musicPlaylist="musicPlaylist",e.collection="collection",e.videoPlaylist="videoPlaylist",e.searchReflow="searchReflow",e.sticker="sticker",e.group="group",e.chat="chat"}(o||(o={}));const r={video:"/@:uniqueId(.*)/video/:id",photo:"/@:uniqueId(.*)/photo/:id",user:"/@:uniqueId",music:"/music/:title(.*)-:id",challenge:"/tag/:name",musicPlaylist:"/playlist-music/:title(.+)-:id",collection:"/@:uniqueId/collection/:title(.+)-:id",videoPlaylist:"/@:uniqueId/playlist/:content(.+)-:id",searchReflow:"/search/campaign/:eventName",sticker:"/sticker/:title(.*)-:id",group:"/messages/group",chat:"/messages/chat"},s=(0,a.w)(r)},82715:(e,t,n)=>{"use strict";n.d(t,{$T:()=>u,CA:()=>l,OZ:()=>d,eU:()=>i,jN:()=>s,kv:()=>p,no:()=>r});var i,o=n(55907),a=n(11430);!function(e){e.video="video",e.photo="photo",e.user="user",e.music="music",e.effect="effect",e.challenge="challenge",e.channel="channel",e.find="find",e.home="home",e.foryouWithLang="foryouWithLang",e.foryou="foryou",e.downloadWithLang="downloadWithLang",e.download="download",e.following="following",e.friends="friends",e.topics="topics",e.expansion="expansion",e.trendingDetailWithinDiscover="trendingDetailWithinDiscover",e.trendingDetail="trendingDetail",e.searchHome="searchHome",e.searchUser="searchUser",e.searchVideo="searchVideo",e.searchReminder="searchReminder",e.searchLive="searchLive",e.discover="discover",e.setting="setting",e.feedback="feedback",e.feedbackHistory="feedbackHistory",e.feedbackReport="feedbackReport",e.upload="upload",e.question="question",e.musicPlaylist="musicPlaylist",e.oauthSpotify="oauthSpotify",e.messages="messages",e.settingBlockList="settingBlockList",e.settingDownLoadYourData="settingDownLoadYourData",e.settingKeywordFiltering="settingKeywordFiltering",e.settingDailyScreenTimeEdit="settingDailyScreenTimeEdit",e.settingTimeBreakEdit="settingTimeBreakEdit",e.settingSleepReminderEdit="settingSleepReminderEdit",e.settingAdPrivacyPersonalizedAds="settingAdPrivacyPersonalizedAds",e.settingAdPrivacyPersonalizedAdsInferredByTikTokTopics="settingAdPrivacyPersonalizedAdsInferredByTikTokTopics",e.settingAdPrivacyPersonalizedAdsYourChoicesTopics="settingAdPrivacyPersonalizedAdsYourChoicesTopics",e.settingAdPrivacyPersonalizedAdsAllTopics="settingAdPrivacyPersonalizedAdsAllTopics",e.settingAdvertiserSettings="settingAdvertiserSettings",e.settingDisconnectAdvertisers="settingDisconnectAdvertisers",e.settingDisconnectAdvertisersDetails="settingDisconnectAdvertisersDetails",e.profile="profile",e.inbox="inbox",e.explore="explore",e.videoPlaylist="videoPlaylist",e.poi="poi",e.poiCategory="poiCategory",e.travel="travel",e.travelCategory="travelCategory",e.collection="collection"}(i||(i={}));const r={video:"/@:uniqueId(.*)/video/:id",photo:"/@:uniqueId(.*)/photo/:id",user:"/@:uniqueId",music:"/music/:title(.*)-:id",effect:"/effect/:title(.*)-:id",challenge:"/tag/:name",channel:"/channel/:name",find:"/find/:name",home:"/",foryouWithLang:["/az","/id-ID","/ms-MY","/jv-ID","/ca","/ceb-PH","/cs-CZ","/da","/de-DE","/et","/en-GB","/en","/es","/es-419","/fil-PH","/fr","/fr-CA","/ga","/hr","/is","/it-IT","/sw","/lv","/lt","/hu-HU","/nl-NL","/nb","/uz","/pl-PL","/pt","/pt-BR","/ro-RO","/sq","/sk","/sl","/fi-FI","/sv-SE","/vi-VN","/tr-TR","/el-GR","/bg","/kk","/ru-RU","/uk-UA","/he-IL","/ur","/ar","/hi-IN","/bn-IN","/th-TH","/my-MM","/km-KH","/ja-JP","/zh-Hant-TW","/zh-Hans","/ko-KR"],foryou:"/foryou",downloadWithLang:["/download/az","/download/id-ID","/download/ms-MY","/download/jv-ID","/download/ca","/download/ceb-PH","/download/cs-CZ","/download/da","/download/de-DE","/download/et","/download/en-GB","/download/en","/download/es","/download/es-419","/download/fil-PH","/download/fr","/download/fr-CA","/download/ga","/download/hr","/download/is","/download/it-IT","/download/sw","/download/lv","/download/lt","/download/hu-HU","/download/nl-NL","/download/nb","/download/uz","/download/pl-PL","/download/pt","/download/pt-BR","/download/ro-RO","/download/sq","/download/sk","/download/sl","/download/fi-FI","/download/sv-SE","/download/vi-VN","/download/tr-TR","/download/el-GR","/download/bg","/download/kk","/download/ru-RU","/download/uk-UA","/download/he-IL","/download/ur","/download/ar","/download/hi-IN","/download/bn-IN","/download/th-TH","/download/my-MM","/download/km-KH","/download/ja-JP","/download/zh-Hant-TW","/download/zh-Hans","/download/ko-KR"],download:"/download",following:"/following",friends:"/friends",topics:"/topics/:name",expansion:"/discover/:name",trendingDetailWithinDiscover:"/discover/trending/detail/:name",trendingDetail:"/:lang/trending/detail/:name",searchHome:"/search",searchUser:"/search/user",searchVideo:"/search/video",searchReminder:"/search/reminder",searchLive:"/search/live",discover:"/discover",setting:"/setting",feedback:"/feedback",feedbackHistory:"/feedback/history",feedbackReport:"/feedback/report",upload:"/upload",question:"/question/:content(.+)-:id",musicPlaylist:"/playlist-music/:title(.+)-:id",oauthSpotify:"/oauthSpotify",messages:"/messages",settingBlockList:"/setting/block-list",settingDownLoadYourData:"/setting/download-your-data",settingKeywordFiltering:"/setting/keyword-filtering",settingDailyScreenTimeEdit:"/setting/daily-screen-time-edit",settingTimeBreakEdit:"/setting/time-break-edit",settingSleepReminderEdit:"/setting/sleep-reminder-edit",settingAdPrivacyPersonalizedAds:"/setting/ad_privacy/personalized_ads",settingAdPrivacyPersonalizedAdsInferredByTikTokTopics:"/setting/ad_privacy/personalized_ads/inferred_by_tiktok_topics",settingAdPrivacyPersonalizedAdsYourChoicesTopics:"/setting/ad_privacy/personalized_ads/your_choices_topics",settingAdPrivacyPersonalizedAdsAllTopics:"/setting/ad_privacy/personalized_ads/all_topics",settingAdvertiserSettings:"/setting/ad_privacy/advertiser_settings",settingDisconnectAdvertisers:"/setting/ad_privacy/disconnect_advertisers",settingDisconnectAdvertisersDetails:"/setting/ad_privacy/disconnect_advertisers_details",profile:"/profile",inbox:"/inbox",explore:"/explore",videoPlaylist:"/@:uniqueId/playlist/:content(.+)-:id",poi:"/place/:name([^/]+)-:id",poiCategory:"/place/:name([^/]+)-:id/:category",travel:"/travel/:name([^/]+)-:id",travelCategory:"/travel/:name([^/]+)-:id/:category",collection:"/@:uniqueId/collection/:title(.+)-:id"},s=(0,a.r)(r),l=(0,a.k)(r);var c;!function(e){e.video="video",e.photo="photo",e.user="user",e.music="music",e.effect="effect",e.challenge="challenge",e.channel="channel",e.find="find",e.home="home",e.foryouWithLang="foryouWithLang",e.foryou="foryou",e.downloadWithLang="downloadWithLang",e.download="download",e.following="following",e.friends="friends",e.topics="topics",e.expansion="expansion",e.trendingDetailWithinDiscover="trendingDetailWithinDiscover",e.trendingDetail="trendingDetail",e.searchHome="searchHome",e.searchUser="searchUser",e.searchVideo="searchVideo",e.searchReminder="searchReminder",e.searchLive="searchLive",e.discover="discover",e.setting="setting",e.feedback="feedback",e.feedbackHistory="feedbackHistory",e.feedbackReport="feedbackReport",e.upload="upload",e.question="question",e.musicPlaylist="musicPlaylist",e.oauthSpotify="oauthSpotify",e.messages="messages",e.settingBlockList="settingBlockList",e.settingDownLoadYourData="settingDownLoadYourData",e.settingKeywordFiltering="settingKeywordFiltering",e.settingDailyScreenTimeEdit="settingDailyScreenTimeEdit",e.settingTimeBreakEdit="settingTimeBreakEdit",e.settingSleepReminderEdit="settingSleepReminderEdit",e.settingAdPrivacyPersonalizedAds="settingAdPrivacyPersonalizedAds",e.settingAdPrivacyPersonalizedAdsInferredByTikTokTopics="settingAdPrivacyPersonalizedAdsInferredByTikTokTopics",e.settingAdPrivacyPersonalizedAdsYourChoicesTopics="settingAdPrivacyPersonalizedAdsYourChoicesTopics",e.settingAdPrivacyPersonalizedAdsAllTopics="settingAdPrivacyPersonalizedAdsAllTopics",e.settingAdvertiserSettings="settingAdvertiserSettings",e.settingDisconnectAdvertisers="settingDisconnectAdvertisers",e.settingDisconnectAdvertisersDetails="settingDisconnectAdvertisersDetails",e.profile="profile",e.inbox="inbox",e.explore="explore",e.videoPlaylist="videoPlaylist",e.poi="poi",e.poiCategory="poiCategory",e.travel="travel",e.travelCategory="travelCategory",e.collection="collection"}(c||(c={}));const d={video:"/@:uniqueId(.*)/video/:id",photo:"/@:uniqueId(.*)/photo/:id",user:"/@:uniqueId",music:"/music/:title(.*)-:id",effect:"/effect/:title(.*)-:id",challenge:"/tag/:name",channel:"/channel/:name",find:"/find/:name",home:"/",foryouWithLang:["/az","/id-ID","/ms-MY","/jv-ID","/ca","/ceb-PH","/cs-CZ","/da","/de-DE","/et","/en-GB","/en","/es","/es-419","/fil-PH","/fr","/fr-CA","/ga","/hr","/is","/it-IT","/sw","/lv","/lt","/hu-HU","/nl-NL","/nb","/uz","/pl-PL","/pt","/pt-BR","/ro-RO","/sq","/sk","/sl","/fi-FI","/sv-SE","/vi-VN","/tr-TR","/el-GR","/bg","/kk","/ru-RU","/uk-UA","/he-IL","/ur","/ar","/hi-IN","/bn-IN","/th-TH","/my-MM","/km-KH","/ja-JP","/zh-Hant-TW","/zh-Hans","/ko-KR"],foryou:"/foryou",downloadWithLang:["/download/az","/download/id-ID","/download/ms-MY","/download/jv-ID","/download/ca","/download/ceb-PH","/download/cs-CZ","/download/da","/download/de-DE","/download/et","/download/en-GB","/download/en","/download/es","/download/es-419","/download/fil-PH","/download/fr","/download/fr-CA","/download/ga","/download/hr","/download/is","/download/it-IT","/download/sw","/download/lv","/download/lt","/download/hu-HU","/download/nl-NL","/download/nb","/download/uz","/download/pl-PL","/download/pt","/download/pt-BR","/download/ro-RO","/download/sq","/download/sk","/download/sl","/download/fi-FI","/download/sv-SE","/download/vi-VN","/download/tr-TR","/download/el-GR","/download/bg","/download/kk","/download/ru-RU","/download/uk-UA","/download/he-IL","/download/ur","/download/ar","/download/hi-IN","/download/bn-IN","/download/th-TH","/download/my-MM","/download/km-KH","/download/ja-JP","/download/zh-Hant-TW","/download/zh-Hans","/download/ko-KR"],download:"/download",following:"/following",friends:"/friends",topics:"/topics/:name",expansion:"/discover/:name",trendingDetailWithinDiscover:"/discover/trending/detail/:name",trendingDetail:"/:lang/trending/detail/:name",searchHome:"/search",searchUser:"/search/user",searchVideo:"/search/video",searchReminder:"/search/reminder",searchLive:"/search/live",discover:"/discover",setting:"/setting",feedback:"/feedback",feedbackHistory:"/feedback/history",feedbackReport:"/feedback/report",upload:"/upload",question:"/question/:content(.+)-:id",musicPlaylist:"/playlist-music/:title(.+)-:id",oauthSpotify:"/oauthSpotify",messages:"/messages",settingBlockList:"/setting/block-list",settingDownLoadYourData:"/setting/download-your-data",settingKeywordFiltering:"/setting/keyword-filtering",settingDailyScreenTimeEdit:"/setting/daily-screen-time-edit",settingTimeBreakEdit:"/setting/time-break-edit",settingSleepReminderEdit:"/setting/sleep-reminder-edit",settingAdPrivacyPersonalizedAds:"/setting/ad_privacy/personalized_ads",settingAdPrivacyPersonalizedAdsInferredByTikTokTopics:"/setting/ad_privacy/personalized_ads/inferred_by_tiktok_topics",settingAdPrivacyPersonalizedAdsYourChoicesTopics:"/setting/ad_privacy/personalized_ads/your_choices_topics",settingAdPrivacyPersonalizedAdsAllTopics:"/setting/ad_privacy/personalized_ads/all_topics",settingAdvertiserSettings:"/setting/ad_privacy/advertiser_settings",settingDisconnectAdvertisers:"/setting/ad_privacy/disconnect_advertisers",settingDisconnectAdvertisersDetails:"/setting/ad_privacy/disconnect_advertisers_details",profile:"/profile",inbox:"/inbox",explore:"/explore",videoPlaylist:"/@:uniqueId/playlist/:content(.+)-:id",poi:"/place/:name([^/]+)-:id",poiCategory:"/place/:name([^/]+)-:id/:category",travel:"/travel/:name([^/]+)-:id",travelCategory:"/travel/:name([^/]+)-:id/:category",collection:"/@:uniqueId/collection/:title(.+)-:id"},u=(0,o.w)(d),p=(0,a.r)(d)},91857:(e,t,n)=>{"use strict";var i,o;n.d(t,{Ob:()=>a}),function(e){e.video="video",e.photo="photo",e.user="user",e.music="music",e.challenge="challenge",e.home="home",e.foryouWithLang="foryouWithLang",e.foryou="foryou",e.following="following",e.topics="topics",e.profile="profile",e.searchHome="searchHome",e.searchUser="searchUser",e.discover="discover",e.feedback="feedback",e.feedbackHistory="feedbackHistory",e.feedbackReport="feedbackReport",e.inbox="inbox",e.report="report",e.reportInbox="reportInbox",e.reportInboxAd="reportInboxAd",e.violationAppeal="violationAppeal",e.setting="setting",e.privacyPrompt="privacyPrompt",e.poi="poi",e.poiCategory="poiCategory",e.travel="travel",e.travelCategory="travelCategory"}(i||(i={})),function(e){e.video="video",e.photo="photo",e.user="user",e.music="music",e.challenge="challenge",e.home="home",e.foryouWithLang="foryouWithLang",e.foryou="foryou",e.following="following",e.topics="topics",e.profile="profile",e.searchHome="searchHome",e.searchUser="searchUser",e.discover="discover",e.feedback="feedback",e.feedbackHistory="feedbackHistory",e.feedbackReport="feedbackReport",e.inbox="inbox",e.report="report",e.reportInbox="reportInbox",e.reportInboxAd="reportInboxAd",e.violationAppeal="violationAppeal",e.setting="setting",e.privacyPrompt="privacyPrompt",e.poi="poi",e.poiCategory="poiCategory",e.travel="travel",e.travelCategory="travelCategory"}(o||(o={}));const a={video:"/@:uniqueId(.*)/video/:id",photo:"/@:uniqueId(.*)/photo/:id",user:"/@:uniqueId",music:"/music/:title(.*)-:id",challenge:"/tag/:name",home:"/",foryouWithLang:["/az","/id-ID","/ms-MY","/jv-ID","/ca","/ceb-PH","/cs-CZ","/da","/de-DE","/et","/en-GB","/en","/es","/es-419","/fil-PH","/fr","/fr-CA","/ga","/hr","/is","/it-IT","/sw","/lv","/lt","/hu-HU","/nl-NL","/nb","/uz","/pl-PL","/pt","/pt-BR","/ro-RO","/sq","/sk","/sl","/fi-FI","/sv-SE","/vi-VN","/tr-TR","/el-GR","/bg","/kk","/ru-RU","/uk-UA","/he-IL","/ur","/ar","/hi-IN","/bn-IN","/th-TH","/my-MM","/km-KH","/ja-JP","/zh-Hant-TW","/zh-Hans","/ko-KR"],foryou:"/foryou",following:"/following",topics:"/topics/:name",profile:"/profile",searchHome:"/search",searchUser:"/search/user",discover:"/discover",feedback:"/feedback",feedbackHistory:"/feedback/history",feedbackReport:"/feedback/report",inbox:"/inbox",report:"/report/:type",reportInbox:"/report/inbox",reportInboxAd:"/ad-report/inbox",violationAppeal:"/violation-appeal",setting:"/setting",privacyPrompt:"/privacy-prompt",poi:"/place/:name([^/]+)-:id",poiCategory:"/place/:name([^/]+)-:id/:category",travel:"/travel/:name([^/]+)-:id",travelCategory:"/travel/:name([^/]+)-:id/:category"}},9047:(e,t,n)=>{"use strict";n.d(t,{fq:()=>r,uZ:()=>c});var i,o=n(11430);!function(e){e.channel="channel",e.expansion="expansion",e.find="find",e.product="product",e.downloadWithLang="downloadWithLang",e.download="download",e.trendingDetailWithinDiscover="trendingDetailWithinDiscover",e.trendingDetail="trendingDetail"}(i||(i={}));const a={channel:"/channel/:name",expansion:"/discover/:name",find:"/find/:name",product:"/product/:name",downloadWithLang:["/download/az","/download/id-ID","/download/ms-MY","/download/jv-ID","/download/ca","/download/ceb-PH","/download/cs-CZ","/download/da","/download/de-DE","/download/et","/download/en-GB","/download/en","/download/es","/download/es-419","/download/fil-PH","/download/fr","/download/fr-CA","/download/ga","/download/hr","/download/is","/download/it-IT","/download/sw","/download/lv","/download/lt","/download/hu-HU","/download/nl-NL","/download/nb","/download/uz","/download/pl-PL","/download/pt","/download/pt-BR","/download/ro-RO","/download/sq","/download/sk","/download/sl","/download/fi-FI","/download/sv-SE","/download/vi-VN","/download/tr-TR","/download/el-GR","/download/bg","/download/kk","/download/ru-RU","/download/uk-UA","/download/he-IL","/download/ur","/download/ar","/download/hi-IN","/download/bn-IN","/download/th-TH","/download/my-MM","/download/km-KH","/download/ja-JP","/download/zh-Hant-TW","/download/zh-Hans","/download/ko-KR"],download:"/download",trendingDetailWithinDiscover:"/discover/trending/detail/:name",trendingDetail:"/:lang/trending/detail/:name"},r=(0,o.r)(a);var s;!function(e){e.channel="channel",e.expansion="expansion",e.find="find",e.product="product",e.downloadWithLang="downloadWithLang",e.download="download",e.trendingDetailWithinDiscover="trendingDetailWithinDiscover",e.trendingDetail="trendingDetail"}(s||(s={}));const l={channel:"/channel/:name",expansion:"/discover/:name",find:"/find/:name",product:"/product/:name",downloadWithLang:["/download/az","/download/id-ID","/download/ms-MY","/download/jv-ID","/download/ca","/download/ceb-PH","/download/cs-CZ","/download/da","/download/de-DE","/download/et","/download/en-GB","/download/en","/download/es","/download/es-419","/download/fil-PH","/download/fr","/download/fr-CA","/download/ga","/download/hr","/download/is","/download/it-IT","/download/sw","/download/lv","/download/lt","/download/hu-HU","/download/nl-NL","/download/nb","/download/uz","/download/pl-PL","/download/pt","/download/pt-BR","/download/ro-RO","/download/sq","/download/sk","/download/sl","/download/fi-FI","/download/sv-SE","/download/vi-VN","/download/tr-TR","/download/el-GR","/download/bg","/download/kk","/download/ru-RU","/download/uk-UA","/download/he-IL","/download/ur","/download/ar","/download/hi-IN","/download/bn-IN","/download/th-TH","/download/my-MM","/download/km-KH","/download/ja-JP","/download/zh-Hant-TW","/download/zh-Hans","/download/ko-KR"],download:"/download",trendingDetailWithinDiscover:"/discover/trending/detail/:name",trendingDetail:"/:lang/trending/detail/:name"},c=(0,o.r)(l)},11430:(e,t,n)=>{"use strict";n.d(t,{k:()=>l,r:()=>r});var i=n(72828),o=n.n(i);const a=e=>{const t=[],n=Object.keys(e);for(const i of n){const n=e[i],a=Array.isArray(n)?n:[n];for(const e of a)t.push({re:o()(e),route:{name:i,path:e}})}return t};function r(e){const t=a(e);return e=>{for(const n of t)if(n.re.test(e))return n.route;return null}}const s=(e,t)=>{const n=[],i=o()(t,n).exec(e);if(!i)return;const a=Object.create(null);for(let e=1;e{for(const n of t){const t=s(e,n.route.path);if(t)return Object.assign(Object.assign({},n.route),{matchedParams:t})}return null}}},55907:(e,t,n)=>{"use strict";n.d(t,{w:()=>l});var i=n(14974),o=n.n(i),a=n(70833),r=n.n(a),s=n(72828);function l(e){return o()(e,(e=>function(e){return r()(e)?(0,s.compile)(e):()=>e[0]}(e)))}},66806:(e,t,n)=>{"use strict";n.d(t,{Ad:()=>g,CB:()=>w,E7:()=>T,Fq:()=>l,MG:()=>y,OT:()=>f,Wx:()=>c,YF:()=>m,Zi:()=>s,_d:()=>i,ab:()=>b,bb:()=>p,c:()=>r,f6:()=>d,k2:()=>E,kV:()=>_,kd:()=>S,nV:()=>o,nm:()=>a,oe:()=>k,p$:()=>u,uM:()=>v,wv:()=>h,x2:()=>x});const i=10204,o=10215,a=10217,r=10216,s=10231,l=10240,c=10241,d=10242,u=203005,p=10205,v=10212,m=10211,g=10209,h=10202,_=10221,f=10222,y=10102,b=10223,w=10203,x=10218,T=10219,k=205001,S=205002,E=205003;var A;!function(e){e[e.Aborted=1]="Aborted",e[e.Network=2]="Network",e[e.Decode=3]="Decode",e[e.SrcNotSupported=4]="SrcNotSupported"}(A||(A={}))},30251:(e,t,n)=>{"use strict";n.d(t,{A6:()=>E,AQ:()=>o,Cb:()=>h,E_:()=>v,Ec:()=>p,F4:()=>c,Gj:()=>_,IP:()=>d,IQ:()=>b,MA:()=>u,Mt:()=>l,OZ:()=>S,Sg:()=>m,TB:()=>f,UN:()=>w,W4:()=>P,Wf:()=>r,Zt:()=>C,_0:()=>x,ai:()=>g,dW:()=>N,e4:()=>i,er:()=>k,kl:()=>I,sF:()=>T,sP:()=>y,uZ:()=>a,wQ:()=>O,wk:()=>j,wl:()=>s,yI:()=>L,yN:()=>A,z6:()=>M});const i="TikTok",o="https://www.tiktok.com",a="https://www.tiktok.com/#website",r="TikTok - trends start here. On a device or on the web, viewers can watch and discover millions of personalized short videos. Download the app to get started.",s="TikTok - Make Your Day",l="https://www.tiktok.com/search?q={search_term_string}",c="tiktok://search?keyword={search_term_string}",d="required name=search_term_string",u="Watch trending videos for you",p="https://www.tiktok.com/foryou",v="/foryou",m="https://www.tiktok.com/#foryou",g="It starts on TikTok. Join the millions of viewers discovering content and creators on TikTok — available on the web or on your mobile device.",h="/following",_="/coin",f="https://www.tiktok.com/search/campaign",y="https://www.tiktok.com/find",b="https://www.tiktok.com/product",w="Discover popular videos",x="https://www.tiktok.com/discover",T="https://www.tiktok.com/tag",k="https://www.tiktok.com/#discover",S="On your device or on the web, join millions of viewers on the fastest growing video app. Download TikTok to discover new creators, search popular hashtags, and watch trending videos.",E="https://www.tiktok.com/#organization",A=["https://www.instagram.com/tiktok/","https://www.facebook.com/tiktok","https://www.twitter.com/tiktok_us","https://www.youtube.com/channel/UChPd_WHrv3O-XAXXHLixs7g"],O=["https://www.instagram.com/tiktok_kr/","https://www.facebook.com/tiktok","https://twitter.com/TiktokKR","https://www.youtube.com/c/tiktokkr","https://post.naver.com/my.naver?memberNo=52184197"],P="Discover",I={INDEX:"index, follow",NO_INDEX:"noindex, follow",IMAGE_PREVIEW_LARGE:"max-image-preview:large"},C="/live",L="/live/producer",j="/live/event",M="/studio/download",N="/studio/faq"},77229:(e,t,n)=>{"use strict";n.d(t,{e:()=>o});const i="BreadcrumbList";class o{constructor(e,t){this["@type"]=i,this.itemListElement=e.reduce(((e,t,n)=>{const{url:i,name:o}=t;return e.push({"@type":"ListItem",position:n+1,item:{"@type":"Thing","@id":i,name:o}}),e}),[])}}o.type=i},77878:(e,t,n)=>{"use strict";n.d(t,{F:()=>u});var i=n(95584),o=n(13761),a=n(7971),r=n(10828),s=n(82715),l=n(30251),c=n(61679),d=n(53038);const u=[{processType:o.k.SERPProcessType.META_PATH,targetId:122,content:function(e){var t,n,i;const{keyword:o,t:l,wordDetailResponse:d,itemResponse:u,wordListResponse:p}=e;if(!o)return{robotsContent:"noindex, nofollow"};const v=null!==(n=null===(t=null==d?void 0:d.wordDetail)||void 0===t?void 0:t.uniqueWord)&&void 0!==n?n:"",m=(0,a.zh)(o),g=`${m} | TikTok`,h=(0,c.D1)((0,a.Zo)(null!==(i=null==u?void 0:u.videoList)&&void 0!==i?i:[])),_=null==p?void 0:p.relatedKeywords;let f=l("seo_aggre_metadesc1",{views:h,keywords:m});const y=_?(0,a.gW)(_.map((e=>e.formattedWord))):"";y&&(f+=` ${l("seo_aggre_metadesc2",{related_search_keywords:y})}`);let b=m;return y&&(b+=`, ${y}`),{title:g,keywords:b,description:f,canonicalHref:`${r.C}${s.$T.channel({name:v})}`,robotsContent:"index, follow",applicableDevice:"pc, mobile"}}},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:122,content:function(e){const{keyword:t,seoProps:{itemList:n}={}}=e;if(!t)return[];const o=(0,a.zh)(t),c=t.replace(/\x20/g,"-").toLocaleLowerCase(),u=`${r.C}${s.$T.channel({name:c})}`,p={"@type":"CollectionPage","@id":u},v=(0,d.SH)([{url:r.C,name:l.e4},{url:u,name:o}]);return[[i.Y.JsonldType.Page,p],[i.Y.JsonldType.BreadcrumbList,v],[i.Y.JsonldType.ItemList,null!=n?n:{}]]}}]},38053:(e,t,n)=>{"use strict";n.d(t,{g:()=>u});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(67982),l=n(46859),c=n(53038);function d(e,t,n){const i=(0,s.fJ)({uniqueId:e});return t&&n?`${i}/collection/${t}-${n}`:i}const u=[{processType:o.k.SERPProcessType.META_PATH,targetId:121,content:function(e){const{t,collectionInfo:n}=e,{userName:i="",name:o="",collectionId:a=""}=null!=n?n:{},s=(0,l.F)(e),c=(0,l.y)(e),u=t("shared_collection_other_apps_title",void 0,"Collection %1$s created by %s").replace("%1$s",o).replace("%s",i),p=t("shared_collection_other_apps_description",void 0,"Watch amazing videos in this curated collection %1$s").replace("%1$s",o),v=s&&!c?r.kl.INDEX:r.kl.NO_INDEX,m=d(i,o,String(a));return{title:u,keywords:void 0,description:p,robotsContent:v,canonicalHref:`${r.AQ}${m}`,applicableDevice:"pc, mobile"}}},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:121,content:function(e){if(!(0,l.F)(e))return[];const{collectionInfo:t,seoProps:n,t:o}=e,{itemList:u}=null!=n?n:{},{userName:p="",name:v="",collectionId:m}=null!=t?t:{},g=(0,s.fJ)({uniqueId:p}),h=`${a.C}${g}`,_=`${p} | TikTok`,f=d(p,v,String(m)),y=`${a.C}${f}`,b=o("shared_collection_other_apps_title",void 0,"Collection %1$s created by %s").replace("%1$s",v).replace("%s",p),w={"@type":"ItemPage","@id":y},x=(0,c.SH)([{url:a.C,name:r.e4},{url:h,name:_},{url:y,name:null!=b?b:""}]);return[[i.Y.JsonldType.Page,w],[i.Y.JsonldType.BreadcrumbList,x],[i.Y.JsonldType.ItemList,null!=u?u:{}]]}}]},13671:(e,t,n)=>{"use strict";function i(e){return`${e} | TikTok`}n.d(t,{s:()=>i})},55734:(e,t,n)=>{"use strict";n.d(t,{Dj:()=>u});var i=n(13761),o=n(95584),a=n(7971),r=n(10828),s=n(30251),l=n(61679),c=n(53038),d=n(13671);const u=[{processType:i.k.SERPProcessType.META_PATH,targetId:124,content:function(e){var t,n,i;const{keyword:o,t:r,itemResponse:c,expansionResponse:d,detailResponse:u,seoProps:{isKEPInFindUI:v=!1,abtest:m,removeRelatedKeywordsInDesc:g,customTDK:h}={}}=e,{description:_="",keywords:f=[]}=null!=h?h:{},y=f.join(", "),b=null!==(n=null===(t=null==u?void 0:u.wordDetail)||void 0===t?void 0:t.formattedWord)&&void 0!==n?n:"",w=(0,a.zh)(b,m);if(!w)return{robotsContent:"noindex, nofollow"};const x=o.replace(/\x20/g,"-").toLocaleLowerCase(),T=p(w),k=(0,l.D1)((0,a.Zo)(null!==(i=null==c?void 0:c.videoList)&&void 0!==i?i:[])),S=null==d?void 0:d.relatedKeywords;let E=_||`${r("seo_aggre_metadesc1",{views:k,keywords:w})} `;const A=S?(0,a.gW)(S.map((e=>e.formattedWord))):"";!g&&A&&(E+=`${r("seo_aggre_metadesc2",{related_search_keywords:A})}`);let O=w;y?O+=`, ${y}`:A&&(O+=`, ${A}`);const P=`${s._0}/${o}`,I=`${s.sP}/${x}`;return{title:T,keywords:O,description:E,canonicalHref:v?P:I,robotsContent:"index, follow",applicableDevice:"pc, mobile"}}},{processType:i.k.SERPProcessType.JSONLD_PATH,targetId:124,content:function(e){var t,n;const{keyword:i="",seoProps:{itemList:a,isKEPInFindUI:l=!1,abtest:d}={}}=e,u=`${l?s._0:s.sP}${i?`/${i}`:""}`,p=null!==(n=null===(t=null==d?void 0:d.parameters.kep_collection_page_modified_date)||void 0===t?void 0:t.vid)&&void 0!==n?n:"v0",v=(0,c.tl)(p,u),m=l?(0,c.SH)([{url:r.C,name:s.e4},{url:s._0,name:s.W4},{url:`${s._0}/${i}`,name:i}]):(0,c.SH)([{url:r.C,name:s.e4},{url:`${s.sP}/${i}`,name:i}]);return[[o.Y.JsonldType.Page,v],[o.Y.JsonldType.BreadcrumbList,m],[o.Y.JsonldType.ItemList,null!=a?a:{}]]}}],p=d.s},35047:(e,t,n)=>{"use strict";n.d(t,{c:()=>l});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(53038);const l=[{processType:o.k.SERPProcessType.META_PATH,targetId:5,content:function(e){const{language:t="en",t:n}=e,i=["TikTok Trends","TikTok Trending","Trending Videos","Trending Hashtags","TikTok i18n keywords"].map((e=>n(e))).join(",");return{title:n("SEO_trending_title"),keywords:i,description:n("SEO_trending_desc"),robotsContent:r.kl.INDEX,canonicalHref:`${r.AQ}${r.E_}?lang=${t}`,applicableDevice:"pc, mobile"}}},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:5,content:function(e){const{seoProps:{itemList:t}={},language:n="en"}=e,o={"@id":r.Sg,url:r.Ec,name:r.MA,description:r.ai,publisher:(0,s.xM)(a.C,n)},l=(0,s.SH)([{url:a.C,name:r.e4},{url:r.Ec,name:r.MA}]);return[[i.Y.JsonldType.WebSite,o],[i.Y.JsonldType.BreadcrumbList,l],[i.Y.JsonldType.ItemList,null!=t?t:{}]]}}]},93809:(e,t,n)=>{"use strict";n.d(t,{I:()=>v,j:()=>p});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(66806),l=n(46859),c=n(67982),d=n(61679),u=n(53038);function p(e){var t,n,i;const o=null===(i=null===(n=null===(t=e.seoProps)||void 0===t?void 0:t.abtest)||void 0===n?void 0:n.parameters.hashtag_page_related_hashtag_tdk)||void 0===i?void 0:i.vid,{t:a,statusCode:u,challengeInfo:p}=e,v=(0,l.F)(e),{challenge:{title:m="",desc:g=""}={},statsV2:{videoCount:h=""}={}}=null!=p?p:{},_=`${m}`;let f=a("seo_serp_hashtag_title",{hashtag:_});const y=function(e,t){const{t:n,relatedChallengeList:i=[]}=e;let o;return o="v3"===t||"v4"===t?(0,d.$C)(i):void 0,o}(e,o);let b=function(e,t,n,i,o){var a,r;const{challengeInfo:s,seoProps:l,t:c,relatedChallengeList:u=[]}=e,{title:p,body:v}=null!==(a=null==s?void 0:s.challengeAnnouncement)&&void 0!==a?a:{},m=`${(0,d._9)(null!=p?p:"")} ${(0,d._9)(null!=v?v:"")}`.trim(),g=null!==(r=null==s?void 0:s.challenge.splitTitle)&&void 0!==r?r:null==l?void 0:l.splitTitle;let h;const _=c("seo_serp_hashtag_desc",{tagText:null!=g?g:n}),f=c("playlist_webapp_profileview_playlists_numbervid",{num:t,number:(0,d.D1)(t)}),y=c("seo_serp_hashtag_desc1",{hashtag:n}),b=`${_}${Number(t)>1e3?`${f} `:""}${y}${m?`${m} `:""}${(0,d._9)(i)}`,w=(0,d.$C)(u);return h="v2"===o||"v4"===o?`${b} ${w}`:`${b}`,h}(e,h,_,g,o);const w=v&&m,x=w?`${r.AQ}${(0,c.hw)({tagName:m})}`:"",T=w?r.kl.INDEX:r.kl.NO_INDEX;switch(u){case s.bb:case s.Ad:case s.YF:case s.uM:f=a("err_tag"),b=""}return{title:f,keywords:y,description:b,canonicalHref:x,robotsContent:T,applicableDevice:"pc, mobile"}}const v=[{processType:o.k.SERPProcessType.META_PATH,targetId:3,content:p},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:3,content:function(e){var t,n;const{challengeInfo:o,seoProps:{itemList:s,metaParams:l}={}}=e,{title:d=""}=null!==(t=null==o?void 0:o.challenge)&&void 0!==t?t:{},p=`${a.C}${(0,c.hw)({tagName:d})}`,v=null!==(n=null==l?void 0:l.title)&&void 0!==n?n:`#${d} | TikTok`,m={"@type":"ItemPage","@id":p},g=(0,u.SH)([{url:a.C,name:r.e4},{url:p,name:v}]);return[[i.Y.JsonldType.Page,m],[i.Y.JsonldType.ItemList,null!=s?s:{}],[i.Y.JsonldType.BreadcrumbList,g]]}}]},75486:(e,t,n)=>{"use strict";n.d(t,{H:()=>l});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(53038);const l=[{processType:o.k.SERPProcessType.META_PATH,targetId:101,content:function(e){const{language:t="en",t:n}=e,i=[n("SEO TikTok Keyword"),n("TikTok i18n keywords for home")].join(",");return{title:n("SEO_homepage_title"),keywords:i,description:n("SEO_homepage_desc"),robotsContent:r.kl.INDEX,canonicalHref:`${r.AQ}/${t}/`,applicableDevice:"pc, mobile"}}},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:101,content:function(e){const{language:t="en"}=e,n=`${a.C}/${t}/`,o={"@id":r.uZ,url:n,name:r.wl,description:r.Wf,publisher:(0,s.xM)(n,t),potentialAction:[{"@type":"SearchAction",target:r.Mt,"query-input":r.IP},{"@type":"SearchAction",target:r.F4,"query-input":r.IP}]};return[[i.Y.JsonldType.WebSite,o]]}}]},95098:(e,t,n)=>{"use strict";n.d(t,{I:()=>p,X:()=>v});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(66806),l=n(46859),c=n(61679),d=n(67982),u=n(53038);function p(e){var t;const{musicInfo:n,statusCode:i,t:o}=e,a=(0,l.F)(e),{music:{id:u="",title:p="",authorName:v="",scheduleSearchTime:m=0}={}}=null!=n?n:{},{videoCount:g}=null!==(t=null==n?void 0:n.stats)&&void 0!==t?t:{};let h,_=o("seo_serp_music_title",{musicName:p,authorName:v});h=p.toLowerCase().endsWith("song")?o("seo_serp_music_desc3",{musicName:p,authorName:v}):o("seo_serp_music_desc",{musicName:p,authorName:v});const f=o("seo_serp_music_desc1",{video_count:(0,c.D1)(g)}),y=o("seo_serp_music_desc2",{musicName:p});let b="";b=g&&g>=1e3?`${h} ${f} ${y}`:`${h} ${y}`;let w=!0;if(0!==m){const e=Number(new Date);w=1e3*Number(m)<=e}const x=a&&p&&u,T=(0,d.pH)({musicName:p,musicId:u}),k=x?`${r.AQ}${T}`:"",S=x&&w?r.kl.INDEX:r.kl.NO_INDEX;switch(i){case s.CB:case s.x2:_=o("err_sound"),b="";break;case s.E7:_=o("err_sound_copy"),b=""}return{title:_,keywords:void 0,description:b,canonicalHref:k,robotsContent:S,applicableDevice:"pc, mobile"}}const v=[{processType:o.k.SERPProcessType.META_PATH,targetId:4,content:p},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:4,content:function(e){var t;const{musicInfo:n,seoProps:o,t:s}=e,{itemList:l,metaParams:c}=null!=o?o:{};if(!(null==n?void 0:n.music))return[];const{title:p="",id:v="",authorName:m=""}=null!==(t=n.music)&&void 0!==t?t:{},{title:g,description:h}=null!=c?c:{},_=(0,d.pH)({musicName:p,musicId:v}),f=`${a.C}${_}`,y=null!=g?g:`${p}(${m}) | TikTok`,b={"@type":"ItemPage","@id":f},w=(0,u.SH)([{url:a.C,name:r.e4},{url:f,name:y}]),x=(0,u.Df)(n.music,{description:h});return[[i.Y.JsonldType.Page,b],[i.Y.JsonldType.ItemList,null!=l?l:{}],[i.Y.JsonldType.BreadcrumbList,w],[i.Y.JsonldType.MusicRecording,x]]}}]},566:(e,t,n)=>{"use strict";n.d(t,{Nr:()=>_,Pi:()=>h,SY:()=>m,o8:()=>p});var i=n(95584),o=n(13761),a=n(7971),r=n(10828),s=n(30251),l=n(66806),c=n(38838),d=n(61679),u=n(53038);function p(e){const{relatedWordList:t=[]}=e;return t.map((e=>e.content))}function v(e,t,n){return`/${n?"place":"travel"}/${t.replace(/ /g,"-")}-${e}`}function m(e,t){var n;const i=null===(n=c.Wk[e])||void 0===n?void 0:n.subTitles;return i?i.map((e=>{const n=e.display.endsWith("downtown")?`${e.display} ${t}`:`${e.display} in ${t}`;return{i18nTitle:e.title,title:n}})):[]}function g(e){return{url:`${s.AQ}${v(String(null==e?void 0:e.PoiId)||"",(null==e?void 0:e.PoiName)||"")}`,name:`${(null==e?void 0:e.PoiName)||""} | TikTok`}}function h(e){return e?[e.L0PoiGeoInfo,e.L1GeoPoiInfo,e.L2GeoPoiInfo,e.L3GeoPoiInfo,e.L4GeoPoiInfo].filter((e=>void 0!==e)).map(g):[]}const _=[{processType:o.k.SERPProcessType.META_PATH,targetId:125,content:function(e){var t,n,i;const{poiInfo:o,statusCode:r,subcategoryPath:u="",items:m,t:g,relatedWordList:h,isPlacePath:_}=e,{poi:{id:f="",name:y="",allLevelGeoPoiInfo:b,indexEnabled:w=!1}={}}=null!=o?o:{},x=(0,d.D1)((0,a.Zo)(null!=m?m:[])),T=(null===(t=c.Wk[u])||void 0===t?void 0:t.display)||"";let k=".";(null===(n=null==b?void 0:b.L1GeoPoiInfo)||void 0===n?void 0:n.PoiName)?k=b.L1GeoPoiInfo.PoiName:(null===(i=null==b?void 0:b.L0PoiGeoInfo)||void 0===i?void 0:i.PoiName)&&(k=b.L0PoiGeoInfo.PoiName);const S=function(e,t){var n;const i=null===(n=c.Wk[e])||void 0===n?void 0:n.subTitles;return i?i.map((e=>{const n=e.display;return n.endsWith("downtown")?`${n} ${t}`:`${n} in ${t}`})):[]}(u,y),E=h?p(h).splice(0,20).join(","):"";let A=g("basicPoi_task2_metaTdk_title",{subcategoryName:T,poiName:y}),O=g("basicPoi_task2_metaTdk_desc",{subcategoryName:T,poiName:y,upperLevelPoiName:k,views:x,subtitle1:S[0],subtitle2:S[1],subtitle3:S[2],subtitle4:S[3]}),P=g("basicPoi_task2_metaTdk_keyword",{keywords:A,relatedSearch:E});const I=v(f,y,_),C=`${s.AQ}${I}/${u}`,L=w?s.kl.INDEX:s.kl.NO_INDEX;switch(r){case l.kd:case l.oe:A=g("poisuggest_placeuna_title_1"),O="",P="";break;case l.k2:A=g("err_feature_unavailable"),O="",P=""}return{title:A,keywords:P,description:O,canonicalHref:C,robotsContent:L,applicableDevice:"pc"}}},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:125,content:function(e){var t,n;const{poiInfo:o,seoProps:a,subcategoryPath:l="",isPlacePath:d=!1,t:p}=e,{itemList:m,videoObject:g}=null!=a?a:{};if(!(null==o?void 0:o.poi))return[];const{name:_="",id:f="",allLevelGeoPoiInfo:y}=null!==(t=o.poi)&&void 0!==t?t:{},b=(null===(n=c.Wk[l])||void 0===n?void 0:n.display)||"",w=v(f,_,d),x=`${r.C}${w}/${l}`,T=`${b} in ${_} | TikTok`,k={"@type":"CollectionPage","@id":x},S=(0,u.SH)([{url:r.C,name:s.e4},...h(y),{url:`${r.C}${w}`,name:`${_} | TikTok`},{url:x,name:T}]);return[[i.Y.JsonldType.Page,k],[i.Y.JsonldType.ItemList,null!=m?m:{}],[i.Y.JsonldType.BreadcrumbList,S],[i.Y.JsonldType.VideoObject,null!=g?g:{}]]}}]},62456:(e,t,n)=>{"use strict";n.d(t,{Hm:()=>c});var i=n(13761),o=n(95584),a=n(7971),r=n(30251),s=n(13474),l=n(13671);const c=[{processType:i.k.SERPProcessType.META_PATH,targetId:133,content:function(e){var t,n;const{t:i,detailResponse:o,seoProps:{abtest:c}={}}=e,d=null!==(n=null===(t=null==o?void 0:o.wordDetail)||void 0===t?void 0:t.formattedWord)&&void 0!==n?n:"",u=(0,a.zh)(d,c);if(!u)return{robotsContent:"noindex, nofollow"};const p=`${i("seo_kep_metaTitle",{s_title:u})}`,v=`${i("seo_kep_news_metaDesc",{s_title:u})} `,m=(0,l.s)(u),g=(0,s.PR)(null==o?void 0:o.wordDetail);return{title:m,keywords:v,description:p,canonicalHref:`${r.AQ}${g}`,robotsContent:"index, follow",applicableDevice:"pc, mobile"}}},{processType:i.k.SERPProcessType.JSONLD_PATH,targetId:133,content:function(e){const{detailResponse:t,seoProps:{itemList:n}={}}=e,i=(0,s.PR)(null==t?void 0:t.wordDetail),l=`${r.AQ}${i}`,{monday:c}=(0,a.XH)(),d={"@type":"CollectionPage","@id":l,dateModified:c};return[[o.Y.JsonldType.Page,d],[o.Y.JsonldType.ItemList,null!=n?n:{}]]}}]},49336:(e,t,n)=>{"use strict";n.d(t,{f:()=>x});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(66806),l=n(46859),c=n(67982),d=n(61679),u=n(77229),p=n(82715),v=n(53038);const m="InteractionCounter";class g{constructor(e,t){this["@type"]=m,this.interactionType={"@type":`http://schema.org/${e.type}`},this.userInteractionCount=e.count}}g.type=m;const h="ProfilePage";class _{constructor(e,t,n,i){var o,r;this["@type"]=h;const s=p.$T.user({uniqueId:e.uniqueId}),l=`${a.C}${s}`,c=null===(o=null==i?void 0:i.parameters.user_structure_data_long_term)||void 0===o?void 0:o.vid;this.mainEntity={"@id":l,"@type":"Person",name:null!==(r=null==e?void 0:e.nickname)&&void 0!==r?r:"",image:(0,v.nE)(e.id),description:e.signature,alternateName:e.uniqueId,url:l,sameAs:e.bioLink&&e.bioLink.link?[e.bioLink.link]:void 0,knowsLanguage:e.language,nationality:e.region,interactionStatistic:[new g({type:"LikeAction",count:Number(t.heart)||t.heartCount},n),new g({type:"FollowAction",count:t.followerCount},n)]},"v1"!==c&&(this.mainEntity.disambiguatingDescription=e.verified?"verified":"",this.mainEntity.identifier=e.uniqueId,this.mainEntity["@type"]=1===e.isOrganization?"Organization":"Person",delete this.mainEntity["@id"]),e.verified&&(this.mainEntity.reviewedBy=v.A_)}}_.type=h;const f="ItemList";class y{constructor(e,t){this["@type"]=f,this.itemListElement=e.map(((e,t)=>Object.assign({position:t+1},e)))}}y.type=f;const b="MusicRecording";class w{constructor(e,t,n){var i,o,r;this["@type"]=b;const s=p.$T.music({id:e.id,title:e.title});this.url=`${a.C}${s}`,this.name=e.title,this.description=n.t("music_SEO_desc3",{musicName:e.title,authorName:e.authorName,posts:(0,d.D1)(t.videoCount)}),this.image=e.coverMedium,this.duration=(0,d.NI)(null!==(i=e.duration)&&void 0!==i?i:0),this.byArtist={"@type":"Person",name:[null!==(o=e.authorName)&&void 0!==o?o:""]},this.inAlbum={"@type":"MusicAlbum",name:null!==(r=e.album)&&void 0!==r?r:""}}}w.type=b;const x=[{processType:o.k.SERPProcessType.META_PATH,targetId:1,content:function(e){var t,n,i,o,a;const{userInfo:u={},statusCode:p,t:v,seoProps:{abtest:m,userPageTagBlackList:g=[]}={},items:h}=e,_=(0,l.F)(e),{user:{verified:f=!1,nickname:y="",uniqueId:b="",signature:w=""}={},stats:{heart:x=0,followerCount:T=0}={}}=u,k=(0,c.$2)(b),S=(0,d.Ug)(y,b),E=(0,c.fJ)({secUid:"",uniqueId:b}),A=_&&y&&k;let O=A?r.kl.INDEX:r.kl.NO_INDEX;O=[O,r.kl.IMAGE_PREVIEW_LARGE].join(", ");const P=A?`${r.AQ}${E}`:"";let I=f?"seo_serp_user2_title":"seo_serp_user1_title";"v1"===(null===(t=null==m?void 0:m.parameters.user_tdk_improvement)||void 0===t?void 0:t.vid)&&"desc"!==(null===(n=null==m?void 0:m.parameters.user_tdk_improvement)||void 0===n?void 0:n.mode)&&(I="seo_serp_user1_title");let C=v(I,{username:S});const L=(0,d._9)(w);let j=v("seo_serp_user_desc",{username:S});if(x>20&&(j+=v("seo_serp_user_desc1",{heart:(0,d.D1)(Number(x))})),T>20&&(j+=v("seo_serp_user_desc2",{follower:(0,d.D1)(T)})),j+=`${L}${L&&!(0,d.Ch)(L)?".":""}`,"v1"===(null===(i=null==m?void 0:m.parameters.user_tdk_improvement)||void 0===i?void 0:i.vid)&&"title"!==(null===(o=null==m?void 0:m.parameters.user_tdk_improvement)||void 0===o?void 0:o.mode)&&(T>1e3||f)&&h&&h.length>2){const{mostPopularTitle:e="",mostRecentTitle:t="",topTags:n=[]}=null!==(a=((e,t)=>{var n,i;if(0===e.length)return;let o=e[0],a=e[0];const r=new Map,s=new Set(t);for(const t of e)if(t.createTime>o.createTime&&(o=t),((null===(n=t.stats)||void 0===n?void 0:n.playCount)||0)>((null===(i=a.stats)||void 0===i?void 0:i.playCount)||0)&&(a=t),t.contents)for(const e of t.contents)for(const t of e.textExtra||[]){const{hashtagName:e}=t;if(e&&!s.has(e)){const t=r.get(e)||0;r.set(e,t+1)}}const l=Array.from(r.entries()).sort(((e,t)=>t[1]-e[1])).slice(0,3).map((([e])=>e));return{mostRecentTitle:o.desc.length>20?`${o.desc.slice(0,20)}...`:o.desc,mostPopularTitle:a.desc.length>20?`${a.desc.slice(0,20)}...`:a.desc,topTags:l}})(h,g))&&void 0!==a?a:{};j+=v("seo_tdkImprove_body",{s_nickname:y,most_recent_video_title_1:t,hot_video_title2:e,followers_count:(0,d.D1)(T),tags:n.join(", "),num:T},j)}else j+=v("seo_serp_user_desc3",{username:S});switch(p){case s.wv:case s.kV:case s.MG:case s.ab:C=v("err_user"),j="";break;case s.OT:C=v("err_user_private"),j=""}return{title:C,keywords:void 0,description:j,canonicalHref:P,robotsContent:O,applicableDevice:"pc, mobile"}}},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:1,content:function(e){var t,n;const{userInfo:o,seoProps:{itemList:s,abtest:l}={},musicList:d=[],t:p}=e;if(!(null===(t=null==o?void 0:o.user)||void 0===t?void 0:t.uniqueId))return[];const{nickname:v,uniqueId:m="",secUid:g}=o.user,h=(0,c.fJ)({secUid:null!=g?g:"",uniqueId:m}),f=`${a.C}${h}`,b=((0,c.$2)(m)?`${v} (@${m})`:`${v}`)+" | TikTok",x="v1"===(null===(n=null==l?void 0:l.parameters.user_structure_data_long_term)||void 0===n?void 0:n.vid)?[[i.Y.JsonldType.ItemList,null!=s?s:{}],[u.e.type,new u.e([{url:a.C,name:r.e4},{url:f,name:b}])],[_.type,new _(o.user,o.stats,void 0,l)]]:[[_.type,new _(o.user,o.stats,void 0,l)],[u.e.type,new u.e([{url:a.C,name:r.e4},{url:f,name:b}])],[i.Y.JsonldType.ItemList,null!=s?s:{}]];return d.length&&x.push([y.type,new y(d.filter((e=>e.stats)).slice(0,9).map((e=>new w(e.music,e.stats,{t:p})))),{name:"MusicRecordingItemList"}]),x}}]},93639:(e,t,n)=>{"use strict";n.d(t,{z:()=>f,G:()=>_});var i=n(95584),o=n(13761),a=n(10828),r=n(30251),s=n(66806),l=n(46859),c=n(67982),d=n(61679);const u=({__:e,_i18n:t,usernameTag:n,musicTag:i,diggCount:o,commentCount:a,stickersOnItem:r,videoText:s,topSearchQueryAfterViewWord:l,customDescription:c})=>{const u=(0,d.qV)(r,[4],3).join(" | "),p=(0,d.qV)(r,[9],3).join(" "),v=o>=20?e("seo_serp_videotxt_desc1",t({likes:(0,d.D1)(o)})):"",m=a>=20?e("seo_serp_videotxt_desc2",t({comments:(0,d.D1)(a)})):"",g=c||s,h=e("seo_serp_videotxt_desc3",t({username:n,videoText:g})),_=l?e("seo_serp_searchQuery_desc",{searchQueryAfterView:l}).concat(" "):"",f=e("seo_serp_musicName_desc",t({musicName:i})),y=[u].filter((e=>Boolean(e))).join(". "),b=[p].filter((e=>Boolean(e))).join(". ");return`${v}${m}${0===g.length?h.replace(': ""',""):h}${0===c.length?`${_}${b}${y}${f}`:""}`},p=({searchQueryAfterViewList:e,customKeywords:t})=>{let n="";return t?n=t:e.length>0&&(n=e.slice(0,10).join(",")),n},v=(e,t)=>{let n=0;const i=[];return[...e].forEach((e=>{const o=e.length;o+n<=t&&(n+=o,i.push(e))})),i.join("")},m=({__:e,_i18n:t,videoText:n,usernameTag:i,musicTag:o,topSearchQueryAfterViewWord:a,customTitle:r})=>{const s=n.length;let l="";return r?l=`${r} | TikTok`:n&&a?l=e("serp_videoText_searchQuery_title",t({videoText:s>70?`${v(n,70)}...`:n,searchQueryAfterView:a})):a&&!n?l=e("serp_videoText_searchQuery_title2",t({username:i,searchQueryAfterView:a})):!a&&n?l=e("seo_serp_videotxt_title",t({videoText:s>70?`${v(n,70)}...`:n})):a||n||(l=e("seo_serp_videotxt_title2",t({username:i,musicName:o}))),l};var g=n(53038),h=n(82715);function _(e){var t,n,i,o,a,v,g,h,_,f,y;const{itemInfo:b,statusCode:w,seoProps:x,t:T}=e,{preferredLanguage:k,customTDK:S}=null!=x?x:{},{title:E="",description:A="",keywords:O=[],article:P=""}=null!=S?S:{},I=(0,l.F)(e);if((0,l.y)(e))return{};const{id:C,desc:L,stickersOnItem:j=[],stats:M}=null!==(t=null==b?void 0:b.itemStruct)&&void 0!==t?t:{},{diggCount:N=0,commentCount:D=0}=null!=M?M:{},{nickname:R,uniqueId:B}=null!==(i=null===(n=null==b?void 0:b.itemStruct)||void 0===n?void 0:n.author)&&void 0!==i?i:{},{title:U,authorName:F}=null!==(a=null===(o=null==b?void 0:b.itemStruct)||void 0===o?void 0:o.music)&&void 0!==a?a:{},V=null!==(g=null===(v=null==b?void 0:b.itemStruct)||void 0===v?void 0:v.suggestedWords)&&void 0!==g?g:[],z=V.length>0?V[0]:"",H=null!==(_=null===(h=null==b?void 0:b.itemStruct)||void 0===h?void 0:h.indexEnabled)&&void 0!==_&&_,q=(0,c.$2)(B),G=(0,d.Ug)(R,B),$=L?(0,d._9)(L):"",W=(0,d.E)(U,null!=F?F:""),Z=function(e){const t=e?{lng:e}:{};return(e={})=>Object.assign(Object.assign({},e),t)}(k);let Y=m({__:T,_i18n:Z,preferredLanguage:k,videoText:$,usernameTag:G,musicTag:W,topSearchQueryAfterViewWord:z,customTitle:E});const K=O.join(", "),X="v1"===(null===(y=null===(f=null==x?void 0:x.abtest)||void 0===f?void 0:f.parameters.video_aigc_article)||void 0===y?void 0:y.vid)?P:A,Q=p({searchQueryAfterViewList:V,customKeywords:K});let J=u({__:T,_i18n:Z,usernameTag:G,musicTag:W,diggCount:N,commentCount:D,stickersOnItem:j,videoText:$,topSearchQueryAfterViewWord:z,customDescription:X});const ee=I&&R&&q&&C,te=!!(null==b?void 0:b.itemStruct.imagePost),ne=ee?te?`${r.AQ}/@${B}/photo/${C}`:`${r.AQ}/@${B}/video/${C}`:"";let ie=ee&&H?r.kl.INDEX:r.kl.NO_INDEX;switch(ie=[ie,r.kl.IMAGE_PREVIEW_LARGE].join(", "),w){case s.Zi:Y=T("err_vid_geo"),J="";break;case s.c:case s._d:case s.nV:case s.nm:case s.Fq:case s.Wx:case s.f6:Y=T("err_vid"),J="";break;case s.p$:Y=T("subVideo_outApp_sharing_title",{creator:R}),J=""}return{title:Y,keywords:Q,description:J,canonicalHref:ne,robotsContent:ie,applicableDevice:"pc, mobile"}}const f=[{processType:o.k.SERPProcessType.META_PATH,targetId:0,content:_},{processType:o.k.SERPProcessType.JSONLD_PATH,targetId:0,content:function(e){var t,n,o,s,d,u,p;if(!(0,l.F)(e))return[];const{itemInfo:v,seoProps:m,t:_}=e,{abtest:f,metaParams:y,videoObject:b,customTDK:w,socialMediaPosting:x}=null!=m?m:{};let{title:T,description:k,keywords:S,article:E}=null!=w?w:{};const{id:A,desc:O}=null!==(t=null==v?void 0:v.itemStruct)&&void 0!==t?t:{},{nickname:P,uniqueId:I,secUid:C,verified:L}=null!==(o=null===(n=null==v?void 0:v.itemStruct)||void 0===n?void 0:n.author)&&void 0!==o?o:{};if(!A||!I)return[];const j=(0,c.fJ)({secUid:C,uniqueId:I}),M=`${a.C}${j}`,N=_(L?"user_SEO_official_title1":"user_SEO_title1",{username:(0,c.$2)(I)?`${P} (@${I})`:`${P}`}),D=(null==v?void 0:v.itemStruct.imagePost)?h.$T.photo({id:A,uniqueId:I}):h.$T.video({id:A,uniqueId:I}),R=`${a.C}${D}`,B={"@type":"ItemPage","@id":R},U=null!==(s=null==y?void 0:y.title)&&void 0!==s?s:O,F=U&&N?(0,g.SH)([{url:a.C,name:r.e4},{url:M,name:N},{url:R,name:U}]):{},V=null!==(u=null===(d=null==f?void 0:f.parameters.video_schema_title)||void 0===d?void 0:d.vid)&&void 0!==u?u:"v0",z=[];return z.push([i.Y.JsonldType.Page,B]),z.push([i.Y.JsonldType.BreadcrumbList,F]),k="v1"===(null===(p=null==f?void 0:f.parameters.video_aigc_article)||void 0===p?void 0:p.vid)?E:k,b&&(T&&(b.name=T),S&&S.length>0&&(b.keywords=S.join(", ")),k&&(b.description=`${k} ${b.description}`),"v1"===V&&(b.name=`${b.creator.name} (@${b.creator.alternateName}) - ${b.name}`),z.push([i.Y.JsonldType.VideoObject,null!=b?b:{}])),x&&(T&&(x.headline=T),k&&(x.articleBody=`${k} ${x.articleBody}`),z.push([i.Y.JsonldType.SocialMediaPosting,null!=x?x:{}])),z}}]},66322:(e,t,n)=>{"use strict";n.d(t,{d:()=>u,y:()=>d});var i=n(13761);const o=new Set([i.k.SERPProcessType.JSONLD_PATH,i.k.SERPProcessType.META_PATH]),a=new Set([i.k.SERPProcessType.JSONLD_EXP,i.k.SERPProcessType.META_EXP]),r=new Set([i.k.SERPProcessType.JSONLD_PAGE,i.k.SERPProcessType.META_PAGE]),s=new Set([i.k.SERPProcessType.META_EXP,i.k.SERPProcessType.META_PAGE,i.k.SERPProcessType.META_PATH]),l=new Set([i.k.SERPProcessType.JSONLD_EXP,i.k.SERPProcessType.JSONLD_PAGE,i.k.SERPProcessType.JSONLD_PATH]),c=(e,t)=>{var n;const{seoProps:{pageId:i,pageType:s,abtest:l}={}}=t,c=null!==(n=null==l?void 0:l.vidList)&&void 0!==n?n:[];return[...e.filter((e=>o.has(e.processType)&&e.targetId===s)),...e.filter((e=>a.has(e.processType)&&c.includes(e.targetId.toString()))),...e.filter((e=>r.has(e.processType)&&e.targetId===i))]};function d(e,t){return c(t,e).filter((e=>s.has(e.processType))).reduce(((e,t)=>{var n,i;const o=t.content(e),a=null!==(i=null===(n=e.seoProps)||void 0===n?void 0:n.metaParams)&&void 0!==i?i:{};return Object.assign(Object.assign({},e),{seoProps:Object.assign(Object.assign({},e.seoProps),{metaParams:Object.assign(Object.assign({},a),o)})})}),e)}function u(e,t){return c(t,e).filter((e=>l.has(e.processType))).reduce(((e,t)=>{var n,i;const o=t.content(e),a=null!==(i=null===(n=e.seoProps)||void 0===n?void 0:n.jsonldList)&&void 0!==i?i:[];return Object.assign(Object.assign({},e),{seoProps:Object.assign(Object.assign({},e.seoProps),{jsonldList:[...a,...o]})})}),e)}},61679:(e,t,n)=>{"use strict";n.d(t,{$C:()=>g,Ch:()=>b,D1:()=>v,E:()=>_,NI:()=>y,Ug:()=>h,_9:()=>m,qV:()=>f});var i=n(94810);const{isRealUniqueId:o}=i.A;function a(e,t=1){return Math.round(Number(`${Number(e)}e${t}`))/Math.pow(10,t)}const r=1e3,s="K",l=1e3*r,c="M",d=1e3*l,u="B",p=BigInt(4294967296);function v(e=0){let t,n=Number(e);return n<0&&(n=Number(p+BigInt(e))),t=n<1e4?n.toString():ne.replace(/^\s+/gm,""))).join(" ").trim()}function g(e){return`${e.slice(0,10).map((e=>e.challenge.title.replace("#",""))).join(" ")}`}const h=(e="",t="")=>o(t)?`${e} (@${t})`:`${e}`;function _(e="",t=""){return e.replace(` - ${t}`,"")+(t?` - ${t}`:"")}function f(e=[],t,n=3){const i=[],o=t;e.forEach((e=>{const{stickerType:t,stickerText:n=[]}=e;-1!==o.indexOf(null!=t?t:0)&&(null==n?void 0:n.length)&&i.push(...n)}));const a=i.length;return n>0&&a>n&&(i.splice(n,a-n),i.push("...")),i}function y(e){if(0===e)return"";const t=e%60,n=Math.floor(e/60),i=n%60,o=Math.floor(n/60),a=o%24,r=Math.floor(o/24);let s="P";return r>0&&(s+=`${r}D`),s+="T",a>0&&(s+=`${a}H`),i>0&&(s+=`${i}M`),s+=`${t}S`,s}function b(e){return/([!@&/\\#,+()$~%.'":*?<>{}!?。]$)/.test(e)}},67982:(e,t,n)=>{"use strict";n.d(t,{$2:()=>r,G2:()=>d,WD:()=>g,fJ:()=>c,hw:()=>p,l3:()=>s,pH:()=>v});var i=n(94810);const{isPureNumber:o,hasIllegalText:a,isRealUniqueId:r,getPureUniqueId:s,purifyMusicName:l}=i.A,{getPureUserPath:c,getPureLivePath:d,getPureVideoPath:u,getPureTagPath:p,getPureMusicPath:v,getPureStickerPath:m,getPureQuestionPath:g}=i.h},53038:(e,t,n)=>{"use strict";n.d(t,{A_:()=>h,Df:()=>u,SH:()=>c,nE:()=>g,tl:()=>_,xM:()=>d});var i=n(94810),o=n(95584),a=n(10828),r=n(7971),s=n(30251),l=n(61679);function c(e=[]){return{itemListElement:e.reduce(((e,t,n)=>{const{url:i,name:a}=t;return e.push({"@type":o.Y.JsonldType.ListItem,position:n+1,item:{"@type":"Thing","@id":i,name:a}}),e}),[])}}function d(e,t){const n=/ko/.test(t)?s.wQ:s.yN;return{"@type":"Organization","@id":s.A6,name:s.e4,url:e,sameAs:n,logo:{"@type":"ImageObject",url:a.U}}}function u(e,t){var n;const{title:o="",id:r="",authorName:s="",coverMedium:c="",duration:d=0,album:u=""}=e,p=i.h.getPureMusicPath({musicName:o,musicId:r});return{url:`${a.C}${p}`,name:o,description:null!==(n=null==t?void 0:t.description)&&void 0!==n?n:"",image:c,duration:(0,l.NI)(null!=d?d:0),byArtist:{"@type":"Person",name:[null!=s?s:""]},inAlbum:{"@type":"MusicAlbum",name:null!=u?u:""}}}const p="1988",v=`${a.C}/api/img`,m={COVERS:"0",COVERS_ORIGIN:"1",USER_IMAGE:"2"};function g(e){return e?`${v}/?userId=${e}&location=${m.USER_IMAGE}&aid=${p}`:void 0}const h={"@type":"Organization",name:"TikTok",url:"www.tiktok.com"},_=(e,t)=>{const n={"@type":"CollectionPage","@id":t};if("v0"===e)return n;const{today:i,monday:o}=(0,r.XH)();return Object.assign(Object.assign({},n),{dateModified:"v1"===e?i:o})}},46859:(e,t,n)=>{"use strict";function i({statusCode:e=0}={}){return 0===e||function(e){return 10229===e||10230===e}(e)}function o({statusCode:e=0}={}){return 10216===e||2040001===e}n.d(t,{F:()=>i,y:()=>o})},38838:(e,t,n)=>{"use strict";n.d(t,{Am:()=>u,Cc:()=>_,Eo:()=>h,R:()=>f,Ri:()=>r,Rx:()=>c,SW:()=>v,V3:()=>a,WG:()=>d,Wk:()=>s,lv:()=>o,xG:()=>p,yh:()=>g});const i="place",o="place",a="travel",r="travel",s={"things-to-do":{display:"Things to do",title:"basicPoi_toDoList_region",entry:"basicPoi_toDoList",popularListDisplay:"popular sightseeings in",popularListTitle:"seo_popular_sightseeing",idlType:0,subTitles:[{display:"Sightseeings",title:"basicPoi_sightSeeing",idlType:1},{display:"Outdoor activities",title:"basicPoi_outdoorActivities",idlType:2},{display:"Nightlife",title:"basicPoi_nightLife",idlType:3},{display:"Family friendly activities",title:"basicPoi_familyFriendly",idlType:4}]},"best-restaurants":{display:"Best restaurants",title:"basicPoi_bestRestaurant_region",entry:"basicPoi_foodNDrinks",popularListDisplay:"popular restaurants in",popularListTitle:"seo_popular_restaurant",idlType:1,subTitles:[{display:"Best brunch restaurants",title:"basicPoi_brunchRestaurants",idlType:6},{display:"Best fine dining restaurants",title:"basicPoi_fineDining",idlType:7},{display:"Best seafood restaurants",title:"basicPoi_seaFood",idlType:8},{display:"Best vegan restaurants",title:"basicPoi_veganRestaurants",idlType:9}]},hotels:{display:"Hotels",title:"basicPoi_hotels_region",entry:"basicPoi_hotels",popularListDisplay:"popular hotels in",popularListTitle:"seo_popular_hotel",idlType:2,subTitles:[{display:"Hotels in downtown",title:"basicPoi_downtownHotels",idlType:11},{display:"Pet friendly hotels",title:"basicPoi_petFriendly",idlType:12},{display:"Airbnbs",title:"basicPoi_airbnbs",idlType:13},{display:"Luxury hotels",title:"basicPoi_luxuryHotels",idlType:14}]},parks:{display:"Parks",title:"basicPoi_parks_region",entry:"basicPoi_parks",popularListDisplay:"popular parks in",popularListTitle:"seo_popular_park",idlType:4,subTitles:[{display:"Amusement parks",title:"basicPoi_amusementParks",idlType:16},{display:"Dog parks",title:"basicPoi_dogParks",idlType:17},{display:"Skate parks",title:"basicPoi_skateParks",idlType:18},{display:"Indoor parks",title:"basicPoi_indoorParks",idlType:19}]},shopping:{display:"Shopping",title:"basicPoi_shopping_region",entry:"basicPoi_shopping",popularListDisplay:"popular shopping malls in",popularListTitle:"seo_popular_shoppingMall",idlType:3,subTitles:[{display:"Shopping malls",title:"basicPoi_shoppingMalls",idlType:21},{display:"Shopping in downtown",title:"basicPoi_downtownShopping",idlType:22},{display:"Vintage shopping",title:"basicPoi_vintageShopping",idlType:23},{display:"Gift shops",title:"basicPoi_giftShops",idlType:24}]}};function l(e=""){return e?e.replace(/([\[\]\,.?"\(\)+_*\/\\&\$#^@!%~`<>:;\{\}?,。·!¥……()+{}【】、|《》]|(?!\s)'\s+|\s+'(?!\s))/gi,"").trim().replace(/(\s+)-(\s+)/gi," ").replace(/\s+|・/gi,"-"):""}function c(){return Object.values(s).map((e=>({title:e.display,i18nTitle:e.title})))}function d(e,t){const n=u(e,t,{path:r});return Object.keys(s).map((e=>`${n}/${e}`))}function u(e,t,n){const{path:i="travel",lang:o}=null!=n?n:{};return`/${i}/${l(t)}-${e}${o?`?language=${o}`:""}`}const p=e=>s[e.toLowerCase()],v=e=>e?{isUS:"6252001"===e.countryCode,isRegional:1===e.type}:{isUS:!1,isRegional:!1},m=(Object.keys(s),(e,t)=>{if(!e.poiInfo)return"";const{path:n,category:i}=null!=t?t:{};return`${u(e.poiInfo.poi.id,e.poiInfo.poi.name,{path:n})}${i?`/${i.toLocaleLowerCase()}`:""}`});function g({poi:e,category:t,path:n}){if(t)return{pageType:"subcategory",pagePath:r};if(!e)return{pageType:"nonUs",pagePath:i};const{isUS:s,isRegional:l}=v(e);return s?l?{pageType:"regional",pagePath:"place"===n?o:a}:{pageType:"store",pagePath:o}:{pageType:"nonUs",pagePath:i}}function h(e,t=!1,n,i){var o,a;const{category:s,path:c="travel"}=null!=i?i:{},d="place"===c;if(!e||0!==e.statusCode)return{instruction:"redirect",code:t?404:301};const{pageType:u,pagePath:p}=g({poi:null===(o=e.poiInfo)||void 0===o?void 0:o.poi,category:s,path:c});return"nonUs"===u?{instruction:"moveOn"}:d||"store"!==u?d&&"subcategory"===u?{instruction:"redirect",code:404}:!t&&s&&s!==s.toLocaleLowerCase()?{instruction:"redirect",code:301,redirectUrl:m(e,{path:r,category:s})}:n!==l(null===(a=e.poiInfo)||void 0===a?void 0:a.poi.name)?{instruction:"redirect",code:301,redirectUrl:m(e,{path:p,category:s})}:{instruction:"moveOn"}:{instruction:"redirect",code:404}}function _(e,t=!1,n){return e.some((e=>{var t;return 0!==e.statusCode||0===(null===(t=e.itemList)||void 0===t?void 0:t.length)}))?t?{instruction:"redirect",code:n?404:301}:{instruction:"loadMore"}:{instruction:"moveOn"}}function f(e){for(const t of e)if("redirect"===t.instruction)return t;for(const t of e)if("loadMore"===t.instruction)return t;return{instruction:"moveOn"}}},35267:(e,t,n)=>{"use strict";n.d(t,{MJ:()=>s,T6:()=>a,mH:()=>c,xw:()=>r,yK:()=>l});var i=n(67823),o=n(4474);function a(){return{userAgent:window.navigator.userAgent||"",acceptLanguage:window.navigator.languages||[],referrer:document.referrer||""}}function r(){return{hostname:window.location.hostname||"",pathname:window.location.pathname||"",query:(0,o.parse)(window.location.search)}}function s(e){return i.A.get(e)}function l(){throw new Error("this function only works on server side")}function c(){return console}},39785:(e,t,n)=>{"use strict";function i({csr:e}){return e}n.d(t,{M:()=>i})},40438:(e,t,n)=>{"use strict";n.d(t,{L:()=>o});var i=n(94999);const o=()=>i.l},53966:(e,t,n)=>{"use strict";n.d(t,{E:()=>r});var i=n(64162),o=n(1055);function a(e=""){return o.p8+e}class r extends i.E{constructor(){super(...arguments),this.terminate=e=>({type:a(e),payload:null,store:this.store})}}},46682:(e,t,n)=>{"use strict";n.d(t,{S:()=>a,w:()=>r});var i=n(73580),o=n(41271);function a(e,t){return[(0,o.P)(e,t),r(e)]}function r(e){return(0,i.Nj)(e).dispatchers}},41271:(e,t,n)=>{"use strict";n.d(t,{P:()=>p});var i=n(73580),o=n(71111),a=n(40099),r=n(28103),s=n(1475),l=n(95719);function c(e,t){if(e===t)return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;const n=Object.keys(e),i=Object.keys(t);if(n.length!==i.length)return!1;const o=Object.prototype.hasOwnProperty;for(const i of n)if(!o.call(t,i)||e[i]!==t[i])return!1;return!0}var d=n(7570);const u=(0,o.atom)(null);function p(e,t){const n=e.jotaiAtom,p="jotaiAtom"in e;e.jotaiAtom&&(e.jotaiAtom.__SIGI_MODULE__=e);const{store:v}=(0,i.Nj)(e),m=function(e,t,n,i=c){const o=n||[],d=(0,a.useRef)(),u=(0,a.useRef)(),p=(0,a.useRef)();i(u.current,o)||(p.current=null!=t?t:r.D,d.current=p.current(e.state)),u.current=o;const v=function(){const[,e]=(0,a.useReducer)((e=>e+1),0);return e}(),m=(0,a.useCallback)((e=>{const t=p.current(e);i(d.current,t)||(d.current=t,v())}),[]),g=(0,a.useCallback)((()=>e.state$.pipe((0,s.i)(1),(0,l.M)(m)).subscribe()),[e,m]),h=(0,a.useMemo)((()=>g()),[g]);return(0,a.useEffect)((()=>{const e=h.closed?g():h;return()=>{e.unsubscribe()}}),[h,g]),d.current}(v,null==t?void 0:t.selector,null==t?void 0:t.dependencies,null==t?void 0:t.equalFn),g=function(e,t){const n=(0,o.useStore)(t),{equalityFn:i=Object.is,selector:a}=null!=t?t:{},r=null!=a?a:e=>e,s=()=>n.get(e);return(0,d.useSyncExternalStoreWithSelector)((t=>n.sub(e,t)),s,s,r,i)}(null!=n?n:u,{selector:e=>{var n;return e?null!==(n=null==t?void 0:t.selector(e))&&void 0!==n?n:e:null},equalityFn:c});return p?g:m}},66476:(e,t,n)=>{"use strict";n.d(t,{$9:()=>s,DA:()=>o,LH:()=>a,cc:()=>r,xD:()=>i});const i="__UNIVERSAL_DATA_FOR_REHYDRATION__",o="__$UNIVERSAL_DATA$__",a="__DEFAULT_SCOPE__",r=Symbol("i"),s=Symbol("s")},82231:(e,t,n)=>{"use strict";n.d(t,{Dh:()=>s});var i=n(71510),o=n.n(i),a=n(40099),r=n(66476);function s(e,t,n){let i="",s="";"string"==typeof e?i=e:(i=e.key,s=e.scope);const[l,c]=(0,a.useState)((()=>{var e,a,l,c;if(!window[r.DA]||window[r.DA][r.cc]){let t={};try{t=JSON.parse(null!==(a=null===(e=document.getElementById(r.xD))||void 0===e?void 0:e.textContent)&&void 0!==a?a:"{}")}catch(e){console.error("error while parsing rehydration data")}window[r.DA]=window[r.DA]||{},window[r.DA][r.cc]=!1,window[r.DA][r.$9]=!0,window[r.DA]=o()(window[r.DA],t)}const d=window[r.DA],u=s||r.LH,p=null!==(c=null===(l=d[u])||void 0===l?void 0:l[i])&&void 0!==c?c:void 0;if(void 0===p)return t;if(null==n?void 0:n.volatile){const e=`${i}_volatile`;d[u][e]=p,d[u][i]=void 0}return p}));return[l,c,()=>null]}},88874:(e,t,n)=>{"use strict";n.d(t,{YI:()=>o,A7:()=>a}),n(40099);var i=n(66476);function o(e,t){var n,o,a,r;if(!window[i.DA]){let e={};try{e=JSON.parse(null!==(o=null===(n=document.getElementById(i.xD))||void 0===n?void 0:n.textContent)&&void 0!==o?o:"{}")}catch(e){console.error("error while parsing rehydration data")}window[i.DA]=e}return null!==(r=null===(a=window[i.DA][null!=t?t:i.LH])||void 0===a?void 0:a[e])&&void 0!==r?r:null}function a(e,t){var n,o;if(null===(n=window[i.DA])||void 0===n?void 0:n[i.$9])throw new Error("set universal data is not allowed after ReactDom kicked in");let a="",r="";"string"==typeof e?a=e:(a=e.key,r=null!==(o=e.scope)&&void 0!==o?o:""),window[i.DA]=window[i.DA]||{[i.cc]:!0},function(e,t,n){let i=e,o=0;for(;i&&o{"use strict";var i,o;n.d(t,{Jr:()=>a,Tk:()=>i,ey:()=>o}),function(e){e.ThreeColumnAuto="list_auto",e.ThreeColumnTrigger="list_mouse_trigger",e.BrowserMode="browser_mode",e.SwiperMode="swiper_mode",e.FullscreenMode="fullscreen",e.OneColumn="one_column",e.ThreeColumn="three_column",e.WideScreen="wide_screen",e.VideoDetail="video_detail",e.Pip="pip",e.Others="others",e.MiniPlayer="mini_player",e.BannerAds="banner_ad",e.ImmersivePlayer="immersive_player"}(i||(i={})),function(e){e[e.OneColumn=0]="OneColumn",e[e.ThreeColumn=1]="ThreeColumn",e[e.BrowserMode=2]="BrowserMode",e[e.SwiperMode=3]="SwiperMode",e[e.VideoDetail=4]="VideoDetail",e[e.FullscreenMode=5]="FullscreenMode",e[e.Pip=6]="Pip",e[e.CreatorTab=7]="CreatorTab",e[e.MiniPlayer=8]="MiniPlayer",e[e.ImmersivePlayer=9]="ImmersivePlayer"}(o||(o={}));const a={2:"browser_mode",8:"mini_player",0:"one_column",1:"three_column",4:"video_detail",5:"fullscreen",7:"browser_mode",6:"pip",3:"swiper_mode",9:"immersive_player","-1":"others"}},25342:(e,t,n)=>{"use strict";n.d(t,{EM:()=>r,Hq:()=>s,OZ:()=>i,XJ:()=>d,_8:()=>c,aS:()=>l,uY:()=>o,xY:()=>a});const i=11988001,o=11988090;var a;!function(e){e.OneColumn="draw_ad",e.BrowserMode="videodetail_ad",e.ATA="about_this_ad",e.BannerAd="banner_ad"}(a||(a={}));const r={one_column:a.OneColumn,browser_mode:a.BrowserMode,immersive_player:a.BrowserMode};var s,l,c;!function(e){e.Photo="photo",e.Title="title",e.Name="name",e.Button="button",e.Comment="comment_sign",e.Share="share_sign",e.ATA="about_tiktok_ads",e.Sponsored="sponsored"}(s||(s={})),function(e){e.HowTTAdsWork="how_tiktok_ads_work",e.PA="pa_setting"}(l||(l={})),function(e){e.PA="pa_setting",e.HowTTAdsWork="how_tiktok_ads_work",e.CloseButton="close_button",e.Others="all_others"}(c||(c={}));const d="umeng"},2584:(e,t,n)=>{"use strict";n.d(t,{O:()=>o});var i=n(93608);const o={handlePageView:e=>{i.f.sendEvent("page_view",e)},handleToTop:()=>{i.f.sendEvent("click_to_top")},handleTap:e=>{i.f.sendEvent("tap",Object.assign(Object.assign({},e),{duration:performance.now()})),window.__COIN_ACTIVITY_TAP_PARAMS&&i.f.sendEvent("luckycat_click_download",window.__COIN_ACTIVITY_TAP_PARAMS)},handlePageSlide:()=>{i.f.sendEvent("page_slide")},handleGeneralClick:(e,t={})=>{i.f.sendEvent("general_click",Object.assign({section:e},t))},reportDownloadSpeed:(e,t={})=>{i.f.sendEvent("device_internet_speed",Object.assign({internet_speed:e},t))},reportFPS:(e,t={})=>{i.f.sendEvent("page_fps",Object.assign({fps:e},t))},handleCommonClick:()=>{i.f.sendEvent("common_click")},handleCommonMousemove:()=>{i.f.sendEvent("common_mousemove")},handleCommonScroll:()=>{i.f.sendEvent("common_scroll")},handleCommonTap:()=>{i.f.sendEvent("common_tap")},reportUserPreference:e=>{i.f.sendEvent("user_preference",{system_theme:e.system_theme,reduced_motion:e.reduced_motion})}}},70322:(e,t,n)=>{"use strict";n.d(t,{w:()=>o});var i=n(93608);const o={handleInferenceDisqualify:e=>{i.f.sendEvent("inference_disqualify",e)},handleInferenceTrigger:e=>{i.f.sendEvent("inference_trigger",e)}}},8615:(e,t,n)=>{"use strict";n.d(t,{_:()=>o});var i=n(93608);const o={handleLinkPhoneOrEmailPopupShow:e=>{i.f.sendEvent("link_phone_number_notify",{enter_method:e.enterMethod})},clickLinkPhoneNumber:()=>{i.f.sendEvent("click_link_phone_number")},linkPhoneNumberSuccess:()=>{i.f.sendEvent("link_phone_number_success")},clickLinkEmail:()=>{i.f.sendEvent("click_link_email")},linkEmailSuccess:()=>{i.f.sendEvent("link_email_success")},ClickFeedback:()=>{i.f.sendEvent("feedback")}}},31974:(e,t,n)=>{"use strict";n.d(t,{$F:()=>m});var i,o=n(58632),a=n(94999),r=n(7672),s=n(92603),l=n(40040),c=n(93608),d=n(67823);var u,p,v;!function(e){e.ClickSignUp="click_sign_up",e.ClickLogin="click_login"}(u||(u={})),function(e){e.Qrcode="QRcode",e.Email="email",e.EmailOrPhoneOrUsername="sms_email_handle",e.Username="handle",e.PhonePassword="phone",e.Sms="sms_verification",e.Repeat="repeatLogin",e.TWITTER="twitter",e.GOOGLE="google",e.FACEBOOK="facebook",e.INSTAGRAM="instagram",e.VK="vk",e.KAKAOTALK="kakaotalk",e.LINE="line",e.APPLE="apple",e.TIKTOK="tiktok"}(p||(p={})),function(e){e[e.Success=0]="Success",e[e.Failed=1]="Failed",e[e.Cancelled=2]="Cancelled"}(v||(v={}));let m=i=class{constructor(){this.setPlatform=e=>{this.platform=e},this.setEnterMethod=e=>{e&&(this.enter_method=e)},this.setCloseable=e=>{void 0!==e&&(this.closeable=e)},this.setGroupId=e=>{this.groupId=e},this.setLastGroupId=e=>{this.lastGroupId=e},this.setSignUpRegionSourceParams=e=>{this.signUpRegionSourceParams=e},this.setPredictionPayload=e=>{void 0!==e&&(this.predictionPayload=e)},this.event=(e,t,n)=>{const i=Object.assign({platform:this.platform},t);if(this.enter_method&&(i.enter_method=this.enter_method),void 0!==this.closeable&&(i.closeable=this.closeable),this.groupId)i.group_id=this.groupId;else if("click_follow"===this.enter_method){const e=(0,s.Hd)(l.DK);e&&(i.from_group_id=e)}!this.lastGroupId||"click_top_bar"!==this.enter_method&&"click_navigation"!==this.enter_method||(i.last_group_id=this.lastGroupId),void 0!==this.predictionPayload&&(i.prediction_payload=this.predictionPayload),n?c.f.beconEvent(e,i):c.f.event(e,i)},this.loginNotify=(e={})=>{const{e2eInfo:t,click_to_notify_duration:n}=e;this.event("login_notify",Object.assign({click_to_notify_duration:n},t))},this.oneTapShow=({e2eInfo:e}={})=>{this.event("show_tiktok_onetap",e)},this.loginWaitingShow=({e2eInfo:e}={})=>{this.event("login_waiting_show",e)},this.pollingOneTapLoginPopupShow=({e2eInfo:e}={})=>{this.event("login_waiting_onetap_popup_show",e)},this.failureOneTapLoginPopupShow=e=>{const{error_code:t,e2eInfo:n}=e;this.event("login_failure_onetap_popup_show",Object.assign({error_code:t},n))},this.copyLinkShow=()=>{this.event("login_copy_link_show")},this.copyLinkClick=()=>{this.event("login_copy_link_click")},this.helpCenterClick=e=>{this.event("__bav_click",Object.assign(Object.assign({},e),{element_title:e.texts}))},this.reactiveConfirmClick=e=>{this.event("reactivate_domain",Object.assign({page_name:"account_reactivate",texts:"reactivate"},e))},this.reactiveCancelClick=e=>{this.event("login_failure",Object.assign({page_name:"account_reactivate",texts:"cancel"},e))},this.smsCodeLimitTipNotify=()=>{this.event("rate_limit_2fa",{page_name:"web_tt_ticket_guard_consumer_response"})},this.smsCodeLimitTipConfirm=()=>{this.event("rate_limit_2fa_password_login",{page_name:"web_tt_ticket_guard_consumer_response"})},this.smsCodeLimitTipCancel=()=>{this.event("rate_limit_2fa_cancel",{page_name:"web_tt_ticket_guard_consumer_response"})},this.updateTeaDataCollectionEnabled=e=>{c.f.setDataCollectionEnabled(e),c.f.config({})},this.loginNotifyClose=e=>{c.f.commonParams.enter_from&&"unknown"!==c.f.commonParams.enter_from&&c.f.config({commonEventParams:{page_name:c.f.commonParams.enter_from}});const{e2eInfo:t,isSignUp:n,enter_method:i}=e;this.event("login_notify_close",Object.assign({isSignUp:n,enter_method:i},t)),this.setGroupId(void 0)},this.loginSubmit=e=>{const{signUp:t,e2eInfo:n}=null!=e?e:{};this.event("login_submit",Object.assign({enter_type:t?"click_sign_up":"click_login"},n)),Boolean(t)&&Boolean(this.signUpRegionSourceParams)&&this.event("sign_up_region_source",this.signUpRegionSourceParams)},this.clickLoginOption=(e={})=>{const{isSignUp:t,e2eInfo:n}=e;this.event("click_login_button",Object.assign({enter_type:t?"click_sign_up":"click_login"},n))},this.loginSuccess=e=>{var t;"repeatLogin"!==this.platform&&d.A.set("last_login_method",null!==(t=this.platform)&&void 0!==t?t:"",{expires:90,path:"/"});const{is_register:n,signUp:i,e2eInfo:o}=e;this.event("login_success",Object.assign({enter_type:i?"click_sign_up":"click_login",is_register:n},o),!0)},this.loginFailure=e=>{const{signUp:t,error_code:n,e2eInfo:i}=e;this.event("login_failure",Object.assign({enter_type:t?"click_sign_up":"click_login",error_code:n},i))},this.enterSignUp=({groupId:e,e2eInfo:t}={})=>{this.event("enter_sign_up",Object.assign({group_id:e},t))},this.loginMethodExpand=()=>{this.event("login_method_expand")},this.clickGoBackButton=()=>{this.event("click_go_back_btn")},this.switchAccountSubmit=()=>{this.event("switch_account_submit")},this.switchAccountClick=()=>{this.event("click_switch_account")},this.manageAccountsClick=()=>{this.event("click_manage_accounts")},this.addAccountClick=()=>{this.event("click_add_account")},this.doneEditingClick=()=>{this.event("click_done_editing")},this.removeNotify=()=>{this.event("remove_notify")},this.failToOpenApp=e=>{const{message:t,error_code:n,e2eInfo:i}=e;this.event("login_fail_before_auth_toast",Object.assign({message:t,error_code:n},i))},this.oneTapSuccessPopupShow=e=>{const{e2eInfo:t}=null!=e?e:{};this.event("onetap_success_popup_show",t)},this.oneTapSuccessPopupClick=e=>{const{e2eInfo:t}=null!=e?e:{};this.event("onetap_success_popup_click",t)},this.removeSubmit=()=>{this.event("remove_submit")},this.removeSuccess=()=>{this.event("remove_success")},this.removeCancel=()=>{this.event("remove_cancel")},this.thirdPartyLoginResult=e=>{this.event("monitor_login_thirdparty",e)},this.ageGateShow=()=>{this.event("age_gate_show",{enter_type:"click_sign_up"})},this.twoStepNotify=e=>{this.event("login_two_step_verification_notify",e)},this.twoStepSubmit=e=>{this.event("login_two_step_verification_submit",e)},this.twoStepResult=e=>{this.event("login_two_step_verification_result",e)},this.forceResetSubmit=()=>{this.event("forced_pwchange_submit")},this.forceResetSuccess=()=>{this.event("forced_pwchange_success")},this.checkPointShow=e=>{this.event("checkpoint_verification_show",e)},this.checkPointResponse=e=>{this.event("checkpoint_verification_response",e)},this.checkPointTyping=e=>{this.event("start_verification_typing",e)}}};m.getInstance=()=>a.l.getInstance(i),m=i=(0,o.__decorate)([(0,r._)()],m)},71828:(e,t,n)=>{"use strict";n.d(t,{F:()=>o});var i=n(93608);const o={handleTrainRequest:e=>{i.f.sendEvent("frontend_rec_classifier_train_request",e)},handleTrainReturn:e=>{i.f.sendEvent("frontend_rec_classifier_train_return",e)},handleStorageWrite:e=>{i.f.sendEvent("frontend_rec_classifier_storage_write",e)},handleStorageLoad:e=>{i.f.sendEvent("frontend_rec_classifier_storage_load",e)},handleClassifyRequest:e=>{i.f.sendEvent("frontend_rec_classifier_serve_request",e)},handleClassifyReturn:e=>{i.f.sendEvent("frontend_rec_classifier_serve_return",e)},handleModelPredict:e=>{i.f.sendEvent("on_device_ml_predict",e)}}},48961:(e,t,n)=>{"use strict";n.d(t,{Af:()=>r,Gt:()=>s,Kg:()=>o});var i=n(93608);const o={PoiRegion:"regional",PoiStore:"store",PoiCategory:"sub_category"};var a;!function(e){e.OneColumn="one_column",e.BrowserMode="browser_mode",e.VideoDetail="video_detail",e.VideoAnchor="video_anchor",e.CommentAnchor="comment_anchor",e.ClickCaption="click_caption"}(a||(a={}));const r={1:"regional",2:"store",3:"independent"},s={handlePoiAnchorShow:e=>{i.f.sendEvent("poi_anchor_show",e)},handlePoiAnchorClick:e=>{i.f.sendEvent("poi_anchor_click",e)}}},28889:(e,t,n)=>{"use strict";n.d(t,{X:()=>o});var i=n(93608);const o={handleEnterAccountSafety:()=>{i.f.sendEvent("enter_account_safety",{enter_method:"click"})},handleEnterDeleteAccount:()=>{i.f.sendEvent("enter_delete_account")},handleAccountRegionEntranceShow:(e,t="settings_page")=>{i.f.sendEvent("account_region_status_show",{regionStatus:e,enter_from:t})},handleAccountRegionEntranceClick:(e="settings_page")=>{i.f.sendEvent("account_region_status_click",{enter_from:e})},handleEnterPrivacySetting:()=>{i.f.sendEvent("enter_privacy_setting",{enter_method:"click"})},handlePrivateAccountChange:e=>{const t=e?"private_account_on":"private_account_off";i.f.sendEvent(t,{enter_from:"privacy_and_safety_settings"})},handleConfirmPrivateAccountChange:e=>{const t=e?"confirm_private_account_on":"confirm_private_account_off";i.f.sendEvent(t,{enter_from:"privacy_and_safety_settings"})},handleEnterDydSetting:()=>{i.f.sendEvent("enter_dyd_setting",{enter_method:"click"})},handleShowPrivateAccountPopUp:()=>{i.f.sendEvent("show_private_account_pop_up")},handleShowLiveChangePrivacyAccountPopUp:()=>{i.f.sendEvent("show_live_change_privacy_account_popup",{enter_from:"privacy_and_safety_settings"})},handleClickLiveChangePrivacyAccountPopUp:e=>{i.f.sendEvent("click_live_change_privacy_account_popup",{enter_from:"privacy_and_safety_settings",status:e})},handleBrowserPushSetting:e=>{i.f.sendEvent("desktop_push_notification_click",{to_status:e})},handleNoticePushSetting:({field:e,to_status:t})=>{i.f.sendEvent("desktop_notification_switch",{label:e,to_status:t})},handleBrowserPushUnlockShow:()=>{i.f.sendEvent("desktop_notification_toast_show")},handleBrowserPushUnlockOk:()=>{i.f.sendEvent("desktop_notification_toast_click")},handleClickBASideNav:()=>{i.f.sendEvent("ttelite_setting_BA_click")},handleClickBASwitchButton:e=>{i.f.sendEvent("ttelite_setting_switchBA_click",e)},handleConfirmSwitchOut:e=>{i.f.sendEvent("ttelite_setting_switchout_confirm",e)},handleSwitchoutError:({err_type:e})=>{i.f.sendEvent("ttelite_switchout_error",{err_type:e})},handleScreenTimeClick:()=>{i.f.sendEvent("web_screen_time_page_show")},handleEnterOpenSourceSoftwareNotice:(e="privacy_and_safety_settings")=>{i.f.sendEvent("enter_open_source_software_notice",{enter_from:e})}}},8046:(e,t,n)=>{"use strict";n.d(t,{pg:()=>c});var i,o,a=n(93608),r=n(25342),s=n(97071);!function(e){e.RealtimeClick="realtime_click",e.Othershow="othershow",e.Otherclick="otherclick",e.Comment="comment",e.Share="share",e.FollowCancel="follow_cancel",e.ChallengeClick="challenge_click",e.Resume="resume",e.Pause="pause",e.Play="play",e.Play2S="play_2s",e.Play6S="play_6s",e.Play15S="play_15s",e.FirstQuartile="first_quartile",e.Midpoint="midpoint",e.ThirdQuartile="third_quartile",e.Over="over",e.Break="break",e.Show="show",e.MusicClick="music_click",e.Receive="receive",e.Dislike="dislike",e.View2S="view_2s",e.View6S="view_6s",e.View15S="view_15s",e.ViewFirstQuartile="view_firstquartile",e.ViewMidpoint="view_midpoint",e.ViewThirdQuartile="view_thirdquartile",e.ViewableImpression="viewable_impression"}(i||(i={})),function(e){e.ProfileImage="profile_image",e.UserName="user_name",e.HyperLink="hyperlink",e.SignUpButton="sign_up_button",e.VideoSection="video_section",e.CrossOut="cross_out",e.LikeButton="like_button",e.CommentButton="comment_button"}(o||(o={}));const l=(e,t)=>{var n,i;const o=Object.assign(Object.assign({},t),{value:null===(i=null===(n=null==t?void 0:t.value)||void 0===n?void 0:n.toString)||void 0===i?void 0:i.call(n),is_ad_event:"1",category:r.XJ,ad_extra_data:Object.assign(Object.assign({},t.ad_extra_data),{user_session:(0,s.q)()})});a.f.event(e,o)},c={handleRealtimeClick:e=>{l("realtime_click",e)},handleOthershow:e=>{l("othershow",e)},handleOtherclick:e=>{l("otherclick",e)},handleComment:e=>{l("comment",e)},handleShare:e=>{l("share",e)},handleFollowCancel:e=>{l("follow_cancel",e)},handleChallengeClick:e=>{l("challenge_click",e)},handleResume:e=>{(null==e?void 0:e.is_ad_event)&&e.tag&&e.value&&l("resume",e)},handlePause:e=>{(null==e?void 0:e.is_ad_event)&&e.tag&&e.value&&l("pause",e)},handleDislike:e=>{l("dislike",e)},handlePlayEvent:(e,t)=>{if((null==t?void 0:t.is_ad_event)&&t.tag&&t.value&&t.log_extra){const{tag:n,value:i,log_extra:o,ad_extra_data:a,video_length:r,duration:s}=t,c=["break","over","view_2s","view_6s","view_15s","view_firstquartile","view_midpoint","view_thirdquartile"].includes(e);l(e,{log_extra:o,tag:n,value:i,ad_extra_data:a,is_ad_event:"1",video_length:c?r:void 0,duration:c?s:void 0})}},handleShow:e=>{l("show",e)},handleReceive:e=>{l("receive",e)},handleMusicClick:e=>{l("music_click",e)}}},97792:(e,t,n)=>{"use strict";n.d(t,{t:()=>s});var i,o=n(92603),a=n(40040),r=n(93608);!function(e){e.FollowButton="follow_button",e.Card="card",e.DirectButton="direct_btn",e.SuggestedAccountButton="suggested_account_btn",e.ToolBarButton="toolbar_btn",e.Notice="notice",e.UserProfile="user_profile",e.Follower="follower",e.Following="following",e.SuggestedCard="suggested_card",e.SuggestedList="suggested_list"}(i||(i={}));const s={handleFollowUser:(e,t)=>{const n=(0,o.Hd)(a.DK),i=0===t?"unfollow":"follow";r.f.sendEvent(i,Object.assign(Object.assign({},e),{from_group_id:n}))}}},15343:(e,t,n)=>{"use strict";n.d(t,{AU:()=>v,Ii:()=>m,Mq:()=>g});var i,o=n(58632),a=n(7672),r=n(93608),s=n(243),l=n.n(s);!function(e){e.PageFCP="page_content_paint",e.FirstScreen="first_screen_video",e.FirstFrame="first_frame_video",e.InteractAddition="interact_additional_video_end",e.InteractExisted="interact_existed_video_end",e.RouteChange="video_route_change",e.InteractAdditionStart="interact_additional_video_start",e.InteractExistedStart="interact_existed_video_start",e.SwiperSlideTransitionEnd="swiper_slide_transition_end"}(i||(i={}));const c=["homepage_hot","homepage_hot_h5","homepage_following","others_homepage","challenge","single_song","video_detail","video_detail_h5"],d=["homepage_hot","homepage_follow","others_homepage","challenge","video_detail","single_song","explore_page"];var u,p;!function(e){e.BrowserModeNext="browser_mode_next",e.BrowserModePrev="browser_mode_prev",e.EnterCreatorMode="enter_creator_mode",e.ExitCreatorMode="exit_creator_mode",e.ClickCreatorTabVideo="click_creator_video",e.OneColumnScrollNext="one_column_scroll_next",e.OneColumnScrollPrev="one_column_scroll_prev",e.OpenBrowserMode="open_browser_mode",e.AdditionFirstLoad="addition_first_load",e.SwiperSlideNext="swiper_slide_next",e.SwiperSlidePrev="swiper_slide_prev",e.ThreeColumnUserHover="three_column_user_hover",e.ThreeColumnUserTouch="three_column_user_touch",e.VideoDatailSelect="video_detail_select"}(u||(u={})),function(e){e.PlayerErrorUIExposed="player_error_ui_exposed",e.PlayerErrorUICta="player_error_ui_cta"}(p||(p={}));let v=class{constructor(){this.additionQueue=[],this.existedQueue=[],this.firstLoadReport=!1,this.shouldFirstLoadReportSkip=!1,this.firstFrameReport=!1,this.currentPageReport=!1,this.currentPage="",this.reportedCanPlayVideoSource="",this.reportedPlayingVideoSource="",this.reportedScrollPrevIndex=-1,this.reportedScrollCurrIndex=-1,this.slideTransitionExsitedQueue=[],this.emit=(e,t)=>{try{r.f.event(e,t)}catch(e){console.error(`Video Scene Evnet Tea Report Error: ${e}`)}},this.reportVideoPageFCP=e=>{this.emit("page_content_paint",e)},this.reportVideoFirstScreen=e=>{const{endTime:t,videoSource:n}=e;if(!this.firstLoadReport){if(this.firstLoadReport=!0,this.currentPageReport=!0,!this.checkIfCanReportFirstPlay()||this.shouldFirstLoadReportSkip)return;const e=()=>!(window&&!window.MediaSource)&&((null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.1.6.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.2.4.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.3.E.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.4.10.L120.90"'))),i=performance.timeOrigin||performance.timing.navigationStart,o={duration:Math.round(t-i),to_page:this.currentPage,can_use_hevc:e()?1:0};this.emit("first_screen_video",o),this.resetAddition(),this.setReportVideoSource(n,0),this.reportClientEvent()}},this.reportClientEvent=()=>{var e,t;l()&&(null===(t=null===(e=null===l()||void 0===l()?void 0:l().app)||void 0===e?void 0:e.printFirstFeedShow)||void 0===t||t.call(e,{info:{page_name:this.currentPage}}))},this.reportVideoFirstFrame=e=>{if(e&&!this.firstFrameReport){if(this.firstFrameReport=!0,!this.checkIfCanReportFirstFrame())return;const e=performance.timeOrigin||performance.timing.navigationStart,t={duration:Math.round(Date.now()-e),to_page:this.currentPage,page_name:this.currentPage};this.emit("first_frame_video",t)}},this.reportVideoAddition=e=>{const t=this.additionQueue[0],{endTime:n,videoSource:i}=e;if(this.isEmptyEvent(t)||this.checkIfHasReported(i,0))return;const{startTime:o=0,situation:a="",from_page:r=""}=t,s=this.currentPage;if(!this.currentPageReport&&r!==s){this.currentPageReport=!0;const e={situation:a,from_page:r,to_page:s,duration:n-o};this.emit("interact_additional_video_end",e),this.resetAddition(),this.setReportVideoSource(i,0)}},this.reportVideoInteract=e=>{const t=this.existedQueue[0]||{},{startTime:n=0,situation:i="",from_page:o=""}=t,{endTime:a,videoSource:r}=e;if(this.isEmptyEvent(t)||this.checkIfHasReported(r,1)&&"open_browser_mode"!==i)return;const s={situation:i,from_page:o,to_page:this.currentPage,duration:a-n};this.emit("interact_existed_video_end",s),this.resetExist(),this.setReportVideoSource(r,1)},this.reportVideoAdditionStart=e=>{const{situation:t,startTime:n}=e;this.currentPageReport=!1,this.additionQueue=[{startTime:n,situation:t,from_page:this.currentPage}]},this.reportVideoInteractStart=e=>{var t;const n=this.existedQueue[0];if(!this.isEmptyEvent(n)){const{situation:i=""}=n;if((null!==(t=e.situation)&&void 0!==t?t:"").indexOf("one_column_scroll")>-1&&i.indexOf("browser_mode")>-1)return}const{startTime:i,situation:o,currVideoIndex:a,prevVideoIndex:r,enterMethod:s}=e;if(a&&a>0&&a===this.reportedScrollCurrIndex&&r===this.reportedScrollPrevIndex)return;const l=this.currentPage;this.existedQueue=[{startTime:i,situation:o,from_page:l}];const c={situation:o,from_page:this.currentPage,enter_method:s};this.emit("interact_existed_video_start",c),this.reportedScrollCurrIndex=null!=a?a:-1,this.reportedScrollPrevIndex=null!=r?r:-1},this.reportSlideTransitionStart=e=>{const{from_page:t,start_time:n,current_index:i}=e;this.slideTransitionExsitedQueue=[{from_page:t,start_time:n,current_index:i}]},this.reportSlideTransitionEnd=e=>{const t=this.slideTransitionExsitedQueue[0]||{},{from_page:n,start_time:i,current_index:o}=t,{from_page:a,end_time:r,current_index:s}=e;if(this.isEmptyEvent(t)||a!==n||s===o)return;const l={from_page:a,situation:s-o>0?"swiper_slide_next":"swiper_slide_prev",duration:r-i};this.emit("swiper_slide_transition_end",l),this.slideTransitionExsitedQueue=[]},this.updateCurrentPage=e=>{this.currentPage=e},this.setReportVideoSource=(e,t)=>{0===t?this.reportedCanPlayVideoSource=e:this.reportedPlayingVideoSource=e},this.setCurrentPageReport=e=>{this.currentPageReport=e},this.getCurrentPageReport=()=>this.currentPageReport,this.getFirstLoadReport=()=>this.firstLoadReport,this.getFirstFrameReport=()=>this.firstFrameReport,this.isEmptyEvent=e=>!e||0===Object.keys(e).length,this.checkIfCanReportFirstPlay=()=>c.indexOf(this.currentPage)>-1&&performance,this.checkIfCanReportFirstFrame=()=>d.indexOf(this.currentPage)>-1&&performance,this.checkIfHasReported=(e,t)=>(0===t?this.reportedCanPlayVideoSource:this.reportedPlayingVideoSource)===e,this.resetAddition=()=>this.additionQueue=[],this.resetExist=()=>this.existedQueue=[],this.handleUserChangeVideoOrPlayMode=()=>{this.shouldFirstLoadReportSkip=!0},this.handleRouteChange=e=>{this.currentPage&&e&&(this.shouldFirstLoadReportSkip=!0)}}};v=(0,o.__decorate)([(0,a._)()],v);const m=e=>{r.f.event("player_error_ui_exposed",e)},g=e=>{r.f.event("player_error_ui_cta",e)}},67974:(e,t,n)=>{"use strict";n.d(t,{V:()=>o});var i=n(93608);const o={handleDislikeShow:e=>{i.f.sendEvent("dislike_button_show",e)},handleClickDislike:e=>{i.f.sendEvent("dislike",e)}}},6986:(e,t,n)=>{"use strict";n.d(t,{W:()=>o});var i=n(93608);const o={handleFavoriteResult:(e,t)=>{const n=1===t?"favourite_video":"cancel_favourite_video";i.f.sendEvent(n,e)},handleShowEntrance:()=>{i.f.sendEvent("show_my_favourite_entrance")},handleClickEntrance:()=>{i.f.sendEvent("click_my_favourite_entrance")},handleEnterFavourite:e=>{i.f.sendEvent("enter_personal_favourite",{enter_method:e})}}},24154:(e,t,n)=>{"use strict";n.d(t,{z:()=>r});var i=n(92603),o=n(40040),a=n(93608);const r={handleLikeVideoResult:(e,t)=>{const n=1===t?"like":"like_cancel",r=(0,i.Hd)(o.DK);a.f.sendEvent(n,Object.assign(Object.assign({},e),{from_group_id:r}))},handleEnterLike:e=>{a.f.sendEvent("enter_personal_like",{enter_method:e})}}},38739:(e,t,n)=>{"use strict";n.d(t,{Gs:()=>f,Mp:()=>g});var i,o,a=n(58632),r=n(7672),s=n(4474),l=n(93608),c=n(92603),d=n(40040),u=n(25342),p=n(65852),v=n(8046),m=n(97071);!function(e){e.Play="video_play",e.Finish="video_play_finish",e.Stop="play_time",e.SchedulePlay="schedule_video_play",e.ScheduleFinish="schedule_video_play_finish",e.ScheduleStop="schedule_video_play_time",e.PreviewVideoPlay="preview_video_play",e.PreviewVideoFinish="preview_video_play_finish",e.PreviewVideoStop="preview_play_time",e.Pause="video_pause",e.Resume="video_resume"}(i||(i={})),function(e){e.ClickPause="click_pause",e.Slide="slide",e.Keyboard="keyboard"}(o||(o={}));const g=e=>{const{video_width:t,video_height:n,video_duration:i}=e;return{video_width:t,video_height:n,video_duration:i}},h=e=>{const{caption_options:t,caption_mode:n,caption_language:i,always_translate_post_mode:o,do_not_translate_mode:a,translate_into_mode:r,see_original_show:s,see_translation_show:l}=e;return{caption_options:t,caption_mode:n,caption_language:i,always_translate_post_mode:o,do_not_translate_mode:a,translate_into_mode:r,see_original_show:s,see_translation_show:l}},_={is2sPlayReported:!1,is6sPlayReported:!1,is15sPlayReported:!1,isFirstQuartilePlayReported:!1,isMidPointPlayReported:!1,isThirdQuartilePlayReported:!1,playOrder:0,video_length:0,is1sViewableImpressionReported:!1,is2sViewableImpressionReported:!1,is6sViewableImpressionReported:!1,is15sViewableImpressionReported:!1};let f=class{constructor(){this.isFirstPlayReported=!1,this.isFirstPlayEndReported=!1,this.isPause=!1,this.startPlayTimestamp=0,this.currentCycleStartTimestamp=0,this.enterMethod="",this.backendSourceEventTracking="",this.prevReportId="",this.videoFocusTime=0,this.isThreeColumnAuto=!1,this.isVideoDetail=!1,this.isDarkMode=!1,this.ttamAdsParams=Object.assign({},_),this.videosPlayed=0,this.isFirstPreviewPlayReported=!1,this.setEnterMethod=e=>{this.enterMethod=e},this.setBackendSourceEventTracking=e=>{this.backendSourceEventTracking=e},this.setIsDarkMode=e=>{this.isDarkMode=e},this.setIsThreeColumnAuto=e=>{this.isThreeColumnAuto=e},this.setIsVideoDetail=e=>{this.isVideoDetail=e},this.reset=()=>{if(0!==this.ttamAdsParams.playOrder){const e=Date.now(),t=Math.max(e-this.currentCycleStartTimestamp,0),n=this.ttamAdsParams.video_length;v.pg.handlePlayEvent("break",Object.assign(Object.assign({},this.ttamAdsParams),{duration:t,ad_extra_data:Object.assign(Object.assign({},this.ttamAdsParams.ad_extra_data),{play_order:this.ttamAdsParams.playOrder})}));const i=Object.assign(Object.assign({},this.ttamAdsParams),{duration:t,video_length:n,ad_extra_data:Object.assign(Object.assign({},this.ttamAdsParams.ad_extra_data),{play_order:this.ttamAdsParams.playOrder,trigger_from:1,percent:Math.trunc(t/n*100)})});t/1e3>=2&&v.pg.handlePlayEvent("view_2s",i),t/1e3>=6&&v.pg.handlePlayEvent("view_6s",i),t/1e3>=15&&v.pg.handlePlayEvent("view_15s",i),t/this.ttamAdsParams.video_length>=.25&&v.pg.handlePlayEvent("view_firstquartile",i),t/this.ttamAdsParams.video_length>=.5&&v.pg.handlePlayEvent("view_midpoint",i),t/this.ttamAdsParams.video_length>=.75&&v.pg.handlePlayEvent("view_thirdquartile",i)}this.isFirstPlayReported=!1,this.isFirstPlayEndReported=!1,this.ttamAdsParams=Object.assign({},_)},this.updateVideoFocusTime=e=>{const{isPause:t,startPlayTimestamp:n}=this,{ttWebappFocusTime:i}=window;!t&&i&&(this.videoFocusTime+=i>n?e-i:e-n)},this.handlePlayTime=e=>{this.playTimeEvent(e)},this.handleTimeUpdate=(e,t=!1)=>{var n,i;const{isFirstPlayReported:o,startPlayTimestamp:a,enterMethod:r,backendSourceEventTracking:s}=this,{itemId:c,index:d,authorId:p,isScheduled:m,autoplayStatus:_=0,currentTime:f,searchId:y="",searchKeyword:b,searchResultId:w,questionId:x,playMode:T,isMute:k=!1,fromTab:S,hasSubtitle:E,captionsShowType:A,collectionId:O,collectionName:P,isPaidPartnership:I=!1,poiId:C,awemeType:L,picCnt:j,playlistId:M="",popupType:N="",enterTab:D,diversifyId:R,tab_name:B,enterMethod:U,isSubOnlyVideo:F,isCopyrightMuted:V=!1,isPinnedItem:z,isAutoScroll:H=!1,isReposted:q=!1,is_just_watched:G,index_from_just_watched:$,currentBackendSourceEventTracking:W,render_state:Z,resolution:Y,is_auto_resolution:K}=e;if(!f)return;const X="1"===E?{has_subtitle:E,captions_show_type:A}:{has_subtitle:E};let Q=null;if(!o){const i=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({group_id:c,author_id:p,play_mode:this.getPlayModeForTea(T),autoplay_status:_,enter_method:null!=U?U:r,backend_source_event_tracking:null!=W?W:s,search_id:y,search_keyword:b,search_result_id:w,question_id:x,from_tab:S,is_dark:this.isDarkMode?"1":"0",collection_id:O,collection_name:P,poi_id:C,aweme_type:null!=L?L:0,pic_cnt:j,playlist_id:M,popup_type:N,enter_tab:D,tab_name:B,diversify_id:R,is_sub_only_video:F,is_copyright_muted:V,is_reposted:q?1:0,render_state:Z},void 0!==G&&{is_just_watched:G}),void 0!==$&&{index_from_just_watched:$}),X),this.getExtraParams()),g(e)),(e=>{const{video_freshness:t,video_duration:n,video_like_history:i,video_vv_history:o,video_share_history:a,video_comment_history:r,video_favorite_history:s,video_resolution:l,video_is_portrait:c,video_100k_vv:d,video_creator_bluev:u,video_creator_1k_follower:p,video_creator_10k_follower:v,video_creator_100k_follower:m,video_next_info:g}=e;return{video_freshness:t,video_duration:n,video_like_history:i,video_vv_history:o,video_share_history:a,video_comment_history:r,video_favorite_history:s,video_resolution:l,video_is_portrait:c,video_100k_vv:d,video_creator_bluev:u,video_creator_1k_follower:p,video_creator_10k_follower:v,video_creator_100k_follower:m,video_next_info:g}})(e)),h(e)),o=m?"schedule_video_play":1===T||7===T?"preview_video_play":"video_play",a=t&&this.prevReportId===c;if("video_play"===o&&(i.is_mute=k?"1":"0",i.is_partnership=I?"1":"0",i.is_autoscroll=H?"1":"0",i.item_list_index=d,i.num_video_played=++this.videosPlayed,i.resolution=Y,i.is_auto_resolution=K?"1":"0"),"preview_video_play"===o&&void 0!==z&&(i.is_pinned=z?"1":"0"),!a&&(Q=o,l.f.event(o,i),this.reportExploreVideoPlayForFirstPreview(i),this.isFirstPlayReported=!0,this.prevReportId=c,e.is_ad_event)){this.ttamAdsParams.playOrder=1;const t=Object.assign(Object.assign({},e),{ad_extra_data:Object.assign(Object.assign({},e.ad_extra_data),{play_order:this.ttamAdsParams.playOrder}),tag:T&&u.EM[this.getPlayModeForTea(T)]||u.xY.OneColumn});v.pg.handlePlayEvent("play",t),this.ttamAdsParams=Object.assign(Object.assign(Object.assign({},t),this.ttamAdsParams),{video_length:null!==(n=e.video_duration)&&void 0!==n?n:0})}}if(e.is_ad_event){const t=(null!==(i=e.video_duration)&&void 0!==i?i:1e8)/1e3;this.reportTTAMAdsVideoPlayEvents({currentTime:f,ttamAdsTeaParams:Object.assign(Object.assign({},e),{ad_extra_data:Object.assign(Object.assign({},e.ad_extra_data),{play_order:this.ttamAdsParams.playOrder}),tag:T&&u.EM[this.getPlayModeForTea(T)]||u.xY.OneColumn}),videoDuration:t,playMode:T,itemId:c})}return 0===a&&this.setStartPlay(),this.isPause=!1,Q},this.reportExploreVideoPlayForFirstPreview=e=>{!this.isFirstPreviewPlayReported&&"list_auto"===e.play_mode&&/\/explore/.test(e.page_url)&&(e.enter_method="explore_preview",l.f.event("video_play",e),this.isFirstPreviewPlayReported=!0)},this.handleTimeUpdateForSideCards=(e,t=!1)=>{const{startPlayTimestamp:n,enterMethod:i}=this,{itemId:o,authorId:a,playMode:r,fromTab:s,enterMethod:c}=e;let d=null;const u=Object.assign(Object.assign({group_id:o,author_id:a,play_mode:this.getPlayModeForTea(r),enter_method:null!=c?c:i,from_tab:s,is_dark:this.isDarkMode?"1":"0"},this.getExtraParams()),g(e)),p="preview_video_play";return t&&this.prevReportId===o||(d=p,l.f.event(p,u),this.isFirstPlayReported=!0,this.prevReportId=o),0===n&&this.setStartPlay(),this.isPause=!1,d},this.handleEnded=e=>{this.playFinishEvent(e),this.currentCycleStartTimestamp=Date.now()},this.handleEndedForSideCards=e=>{this.playFinishEventForSideCards(e)},this.handlePause=e=>{const{currentTime:t,duration:n}=e;n!==t&&this.playTimeEvent(e),this.isPause=!0},this.handleWaiting=e=>{const{currentTime:t,duration:n}=e;0!==t&&t!==n&&this.playTimeEvent(e)},this.handleError=e=>{this.playTimeEvent(e)},this.triggerPause=e=>{if(!this.isPause){const{enter_method:t,playMode:n,aweme_type:i=0,pic_cnt:o,currentBackendSourceEventTracking:a,group_id:r}=e,{backendSourceEventTracking:s}=this,c={enter_method:t,backend_source_event_tracking:null!=a?a:s,play_mode:this.getPlayModeForTea(n),aweme_type:i,pic_cnt:o,group_id:r};l.f.event("video_pause",c),0!==this.ttamAdsParams.playOrder&&v.pg.handlePlayEvent("pause",Object.assign(Object.assign({},this.ttamAdsParams),{ad_extra_data:{play_order:this.ttamAdsParams.playOrder,duration:this.getFocusTime(Date.now())}}))}this.isPause=!0},this.triggerResume=e=>{if(this.isPause){const t=Object.assign(Object.assign({},e),{play_mode:this.getPlayModeForTea(e.playMode)});l.f.event("video_resume",t),0!==this.ttamAdsParams.playOrder&&v.pg.handlePlayEvent("resume",Object.assign(Object.assign({},this.ttamAdsParams),{ad_extra_data:{play_order:this.ttamAdsParams.playOrder}}))}},this.triggerPlay=()=>{this.isPause=!1},this.handleAudioPlay=e=>{this.prevReportId=e},this.getFocusTime=e=>{const{startPlayTimestamp:t,videoFocusTime:n}=this,{ttWebappFocusTime:i,ttWebappBlurTime:o}=window;let a=0;return i?a=it?n:0),a}}getPlayModeForTea(e){let t="others";switch(e){case 2:t="browser_mode";break;case 9:t="immersive_player";break;case 0:t=this.isVideoDetail?"others":"one_column";break;case 1:t=this.isThreeColumnAuto?"list_auto":"list_mouse_trigger";break;case 3:t="swiper_mode";break;case 4:t="video_detail";break;case 6:t="pip";break;case 5:t="fullscreen";break;case 7:t="list_mouse_trigger";break;case 8:t="mini_player"}return t}setStartPlay(){this.startPlayTimestamp=Date.now(),this.currentCycleStartTimestamp=this.startPlayTimestamp,this.videoFocusTime=0}playFinishEvent(e){const{isFirstPlayEndReported:t,enterMethod:n,backendSourceEventTracking:i}=this,{itemId:o,authorId:a,isScheduled:r,autoplayStatus:s=0,searchId:c="",searchKeyword:d,searchResultId:u,playMode:p,isMute:v,collectionId:m,collectionName:h,poiId:_,awemeType:f,picCnt:y,playlistId:b="",popupType:w="",enterTab:x,diversifyId:T,tab_name:k,enterMethod:S,isSubOnlyVideo:E,isAutoScroll:A,isReposted:O,currentBackendSourceEventTracking:P}=e;if(!t){const t=Object.assign(Object.assign({group_id:o,author_id:a,play_mode:this.getPlayModeForTea(p),autoplay_status:s,enter_method:null!=S?S:n,backend_source_event_tracking:null!=P?P:i,search_id:c,search_keyword:d,search_result_id:u,collection_id:m,collection_name:h,poi_id:_,aweme_type:null!=f?f:0,pic_cnt:y,enter_tab:x,diversify_id:T,is_dark:this.isDarkMode?"1":"0",playlist_id:b,popup_type:w,is_sub_only_video:E,is_reposted:O?1:0,tab_name:k},this.getExtraParams()),g(e));void 0!==v&&(t.is_mute=v?"1":"0");const I=r?"schedule_video_play_finish":1===p||7===p?"preview_video_play_finish":"video_play_finish";"video_play_finish"===I&&void 0!==A&&(t.is_autoscroll=A?"1":"0"),l.f.event(I,t),this.isFirstPlayEndReported=!0}}playFinishEventForSideCards(e){const{enterMethod:t}=this,{itemId:n,authorId:i,playMode:o,enterMethod:a}=e,r=Object.assign({group_id:n,author_id:i,play_mode:this.getPlayModeForTea(o),enter_method:null!=a?a:t,is_dark:this.isDarkMode?"1":"0"},g(e));l.f.event("preview_video_play_finish",r)}playTimeEvent(e){const{startPlayTimestamp:t,enterMethod:n,backendSourceEventTracking:i}=this,{itemId:o,authorId:a,isScheduled:r,autoplayStatus:s=0,searchId:u="",searchKeyword:v,searchResultId:m,questionId:_,playMode:f,isMute:y,fromTab:b,hasSubtitle:w,captionsShowType:x,collectionId:T,collectionName:k,poiId:S,awemeType:E,picCnt:A,playlistId:O="",popupType:P="",enterTab:I,diversifyId:C,tab_name:L,enterMethod:j,isSubOnlyVideo:M,isAutoScroll:N,isReposted:D,is_just_watched:R,index_from_just_watched:B,currentBackendSourceEventTracking:U}=e,F=Date.now(),V=this.getFocusTime(F),z="1"===w?{has_subtitle:w,captions_show_type:x}:{has_subtitle:w},H=Math.max(F-t,0);if(0!==t){const t=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({group_id:o,author_id:a,play_mode:this.getPlayModeForTea(f),autoplay_status:s,duration:H,enter_method:null!=j?j:n,backend_source_event_tracking:null!=U?U:i,search_id:u,search_keyword:v,search_result_id:m,question_id:_,focus_time:V,from_tab:b,is_dark:this.isDarkMode?"1":"0",collection_id:T,collection_name:k,poi_id:S,aweme_type:null!=E?E:0,pic_cnt:A,playlist_id:O,popup_type:P,enter_tab:I,diversify_id:C,is_sub_only_video:M,is_reposted:D?1:0,tab_name:L},void 0!==R&&{is_just_watched:R}),void 0!==B&&{index_from_just_watched:B}),z),this.getExtraParams()),p.L.getScreenRatio()),g(e)),h(e));void 0!==y&&(t.is_mute=y?"1":"0");const w=(0,c.Hd)(d.DK),x=r?"schedule_video_play_time":1===f||7===f?"preview_play_time":"play_time";"play_time"===x&&(t.is_autoscroll=N?"1":"0"),l.f.event(x,Object.assign(Object.assign({},t),{from_group_id:w})),this.startPlayTimestamp=0,this.currentCycleStartTimestamp=0}}getExtraParams(){var e;const{href:t,search:n}=window.location;return{is_from_webapp:null!==(e=(0,s.parse)(n).is_from_webapp)&&void 0!==e?e:"0",page_url:t}}reportTTAMAdsVideoPlayEvents({currentTime:e,ttamAdsTeaParams:t,videoDuration:n,playMode:i,itemId:o}){const a=(0,m.CN)(i.toString(),o,e);if(a.isVisible){const n=e-a.startTime;n>=1&&!this.ttamAdsParams.is1sViewableImpressionReported&&(v.pg.handlePlayEvent("viewable_impression",Object.assign(Object.assign({},t),{ad_extra_data:Object.assign(Object.assign({},t.ad_extra_data),{viewable_length:"1s"})})),this.ttamAdsParams.is1sViewableImpressionReported=!0),n>=2&&!this.ttamAdsParams.is2sViewableImpressionReported&&(v.pg.handlePlayEvent("viewable_impression",Object.assign(Object.assign({},t),{ad_extra_data:Object.assign(Object.assign({},t.ad_extra_data),{viewable_length:"2s"})})),this.ttamAdsParams.is2sViewableImpressionReported=!0),n>=6&&!this.ttamAdsParams.is6sViewableImpressionReported&&(v.pg.handlePlayEvent("viewable_impression",Object.assign(Object.assign({},t),{ad_extra_data:Object.assign(Object.assign({},t.ad_extra_data),{viewable_length:"6s"})})),this.ttamAdsParams.is6sViewableImpressionReported=!0),n>=15&&!this.ttamAdsParams.is15sViewableImpressionReported&&(v.pg.handlePlayEvent("viewable_impression",Object.assign(Object.assign({},t),{ad_extra_data:Object.assign(Object.assign({},t.ad_extra_data),{viewable_length:"15s"})})),this.ttamAdsParams.is15sViewableImpressionReported=!0)}else this.ttamAdsParams.is1sViewableImpressionReported=!1,this.ttamAdsParams.is2sViewableImpressionReported=!1,this.ttamAdsParams.is6sViewableImpressionReported=!1,this.ttamAdsParams.is15sViewableImpressionReported=!1;if(e>=2&&!this.ttamAdsParams.is2sPlayReported&&(v.pg.handlePlayEvent("play_2s",t),this.ttamAdsParams.is2sPlayReported=!0),e>=6&&!this.ttamAdsParams.is6sPlayReported&&(v.pg.handlePlayEvent("play_6s",t),this.ttamAdsParams.is6sPlayReported=!0),e>=15&&!this.ttamAdsParams.is15sPlayReported&&(v.pg.handlePlayEvent("play_15s",t),this.ttamAdsParams.is15sPlayReported=!0),e/n>=.25&&!this.ttamAdsParams.isFirstQuartilePlayReported&&(v.pg.handlePlayEvent("first_quartile",t),this.ttamAdsParams.isFirstQuartilePlayReported=!0),e/n>=.5&&!this.ttamAdsParams.isMidPointPlayReported&&(v.pg.handlePlayEvent("midpoint",t),this.ttamAdsParams.isMidPointPlayReported=!0),e/n>=.75&&!this.ttamAdsParams.isThirdQuartilePlayReported&&(v.pg.handlePlayEvent("third_quartile",t),this.ttamAdsParams.isThirdQuartilePlayReported=!0),e/n>=.99&&this.ttamAdsParams.isThirdQuartilePlayReported){const i=1e3*n;v.pg.handlePlayEvent("over",Object.assign(Object.assign({},t),{duration:i,video_length:i}));const o=Object.assign(Object.assign({},t),{duration:i,video_length:i,ad_extra_data:Object.assign(Object.assign({},t.ad_extra_data),{trigger_from:2,percent:100})});e>=2&&v.pg.handlePlayEvent("view_2s",o),e>=6&&v.pg.handlePlayEvent("view_6s",o),e>=15&&v.pg.handlePlayEvent("view_15s",o),v.pg.handlePlayEvent("view_firstquartile",o),v.pg.handlePlayEvent("view_midpoint",o),v.pg.handlePlayEvent("view_thirdquartile",o),this.ttamAdsParams=Object.assign(Object.assign(Object.assign({},_),t),{playOrder:this.ttamAdsParams.playOrder+1,video_length:i})}}};f=(0,a.__decorate)([(0,r._)()],f)},81824:(e,t,n)=>{"use strict";n.d(t,{W3:()=>s});var i=n(93608),o=n(67134);class a{constructor(){this.msLastScrollStart=-1,this.msLastScrollEnd=-1,this.indexOnScrollStart=-1}}const r=(0,o.U)("ScrollReportStruct@tiktok/tea-events",(()=>new a)),s={struct:r,scrollStart:({index:e,playModeForTea:t,pageType:n,enterMethod:o})=>{const a=performance.now();r.msLastScrollStart=a,-1===r.indexOnScrollStart&&e&&(r.indexOnScrollStart=e),i.f.sendEvent("scroll_start",{utc_ms:a,play_mode:t,page_type:n,enter_method:o})},scrollEnd:({index:e,playModeForTea:t,pageType:n,enterMethod:o,didFinish:a})=>{const s=performance.now();r.msLastScrollEnd=s,i.f.sendEvent("scroll_end",{utc_ms:s,duration:r.msLastScrollEnd-r.msLastScrollStart,did_change_video:e!==r.indexOnScrollStart,did_finish:a,play_mode:t,page_type:n,enter_method:o}),r.indexOnScrollStart=-1}}},80417:(e,t,n)=>{"use strict";n.d(t,{y:()=>o});var i=n(93608);const o={handleClickPrivacySettingVideo:e=>{i.f.sendEvent("click_privacy_setting_video",e)},handleSelectPrivacySettingVideo:e=>{i.f.sendEvent("select_privacy_setting_video",e)},handlePrivateSetting:e=>{i.f.sendEvent("privacy_setting_allow_interaction",e)},handleClickDeleteVideo:e=>{i.f.sendEvent("click_delete_video",e)},handleVideoDelete:e=>{i.f.sendEvent("action_on_delete_video",{action:e})},handleScheduleConfirm:e=>{i.f.sendEvent("click_delete_scheduled_video",{group_id:e})},handleScheduleDelete:e=>{i.f.sendEvent("action_on_delete_scheduled_video",{action:e})}}},14107:(e,t,n)=>{"use strict";n.d(t,{j:()=>o});var i=n(93608);const o={handleVideoReceive:e=>{i.f.sendEvent("video_receive",e)},handleVideoContentShow:e=>{i.f.sendEvent("video_content_show",e)}}},65852:(e,t,n)=>{"use strict";n.d(t,{L:()=>a});var i=n(93608),o=n(81824);const a={handleListMore:e=>{i.f.sendEvent("load_more",e)},handleVideoChange:(e,t)=>{const n="next"===t?"video_slide_up":"video_slide_down",a=o.W3.struct.msLastScrollEnd>0?Date.now()-o.W3.struct.msLastScrollEnd:void 0;i.f.sendEvent(n,a?Object.assign(Object.assign({},e),{ms_since_scroll:a}):e),a&&(o.W3.struct.msLastScrollEnd=-1)},handleHotVideoChange:(e,t)=>{const n="next"===t?"homepage_hot_slide_up":"homepage_hot_slide_down";i.f.sendEvent(n,e)},handleEnterBrowser:e=>{i.f.sendEvent("feed_enter",e)},handleEnterBrowserOpt:e=>{i.f.sendEvent("feed_enter",e)},handleExitBrowser:e=>{i.f.sendEvent("feed_exit",e)},handleAdjustBrowserSize:e=>{i.f.sendEvent("browser_size_adjust",e)},handleCloseWindow:e=>{i.f.sendEvent("close_window",e)},handleVideoCoverClick:(e,t)=>{i.f.sendEvent("video_cover_click",Object.assign(Object.assign({},e),{rank:t,backend_source_event_tracking:""}))},getScreenRatio:()=>{const e=screen.height,t=screen.width,n=window.innerWidth,i=window.innerHeight;return{width:n,height:i,width_max:t,height_max:e,height_ratio:i/e,width_ratio:n/t}}}},43201:(e,t,n)=>{"use strict";n.d(t,{T:()=>a});var i=n(93608),o=n(91257);const a=({windowObj:e,playMode:t,height_before:n,width_before:a})=>{if(!e)return;const r=e.innerHeight,s=e.innerWidth,l=o.Jr[null!=t?t:"-1"];i.f.event("window_size_change",{height_after:r,width_after:s,play_mode:l,height_before:n,width_before:a})}},51388:(e,t,n)=>{"use strict";function i(e,t=""){var n;try{return null!==(n=sessionStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}function o(e,t){try{sessionStorage.setItem(e,t)}catch(e){}}n.d(t,{Hd:()=>i,J2:()=>o,bp:()=>a});const a=e=>{if(!e||"string"!=typeof e)return 0;let t=0;try{const n=new RegExp("(\\?|&)expire=([^&]*)(&|$)"),i=e.match(n);if(null!==i)t=parseInt(i[2],10);else{const n=e.split("/");n.length>5&&8===n[4].length&&(t=parseInt(n[4],16))}return t>0?t{"use strict";n.d(t,{AR:()=>u,CN:()=>m,n5:()=>r,q:()=>p});var i=n(25342),o=n(51388),a=n(24473);const r=({ad_info:e,play_mode:t})=>{if(!e)return{};const n=(e=>{if(e)try{return JSON.parse(e)}catch(e){return}})(e.log_extra);let o=i.xY.BrowserMode;return o="one_column"===t?i.xY.OneColumn:i.xY.BrowserMode,{log_extra:n,ad_extra_data:{charge_type:e.charge_type},tag:o,value:e.creative_id.toString(),is_ad_event:"1",category:i.XJ}},s="user_session",l="lastUpdated",c=()=>(new Date).getTime().toString(),d=e=>{(0,o.J2)(s,JSON.stringify(e))},u=e=>{const t=(0,o.Hd)(s);if(e){if(""===t||"0"===JSON.parse(t).uid){const t={uid:e.uid,lastUpdated:c()};d(t)}}else if(""===t||"0"!==JSON.parse(t).uid){const e={uid:"0",lastUpdated:c()};d(e)}var n;n=18e5,(0,a.hb)({onIdle:()=>{((e,t)=>{const n=(0,o.Hd)(s);if(!n)throw new Error("User Session did not find!");{const i=JSON.parse(n);if("string"!=typeof t)throw new Error("Invalid input!");i[e]=t,d(i)}})(l,c())},timeout:n,debounce:1e4})},p=()=>{const e=JSON.parse((0,o.Hd)(s));return`${e.uid}${e.lastUpdated}`},v={id:"",isVisible:!1,startTime:0},m=(e,t,n)=>{const i=`xgwrapper-${e}-${t}`,o=(()=>{const e=document.querySelector('section[role="dialog"]');return e||(document.getElementById("header-transfer")||null)})();if(o||v.id!==i){v.id=i;const e=document.getElementById(i);if(!e)throw new Error("Cannot find the current Video Container!");{const t=new IntersectionObserver((t=>{const i=t[0];if(i.isIntersecting)if(o){const t=((e,t,n)=>{const i=e.getBoundingClientRect(),o=Math.abs(i.top-i.bottom)*Math.abs(i.left-i.right),a=o*n,r=t.getBoundingClientRect(),s=Math.max(i.top,r.top),l=Math.min(i.bottom,r.bottom),c=Math.max(i.left,r.left),d=Math.min(i.right,r.right);return(a-Math.abs(s-l)*Math.abs(c-d))/o})(e,o,i.intersectionRatio);t<.5&&(v.id="",v.startTime=0,v.isVisible=!1)}else v.startTime=n,v.isVisible=!0;else v.id="",v.startTime=0,v.isVisible=!1}),{root:null,rootMargin:"0px",threshold:.5});t.observe(e)}}return v}},40040:(e,t,n)=>{"use strict";n.d(t,{DK:()=>d,Is:()=>m,LN:()=>_,O_:()=>o,QI:()=>c,YH:()=>g,em:()=>a,hk:()=>r,iJ:()=>l,lG:()=>v,ne:()=>u,oE:()=>h,qZ:()=>s,uV:()=>p,wO:()=>f,xE:()=>i});const i=1988,o="webapp_launch_mode",a="webapp_original_traffic_type",r="webapp_extra_data",s="webapp_session_id",l="webapp_tiktok_open",c="webapp_tiktok_privious",d="webapp_from_group_id",u="f_s_1",p=14,v=["VGeo-EU"],m="guest-mode-flag",g="others",h="direct",_=/h5_t|h5_m|landing_page|webapp/,f=/embed/},56203:(e,t,n)=>{"use strict";var i;n.d(t,{mD:()=>i,NX:()=>o,gb:()=>a}),function(e){e.OS="os",e.BROWSER_BRAND="browser_brand",e.SCREEN_RESOLUTION="screen_resolution",e.SCREEN_ORIENTATION="screen_orientation",e.CPU_CORE_NUMBER="cpu_core_number",e.NETWORK_DOWNLINK="network_downlink",e.NETWORK_RTT="network_rtt",e.NETWORK_SPEED_EFFECTIVE_TYPE="network_speed_effective_type",e.REGION="region",e.LAUNCH_MODE="launch_mode",e.LANDING_PAGE="landing_page",e.LANGUAGE_SYSTEM="language_system",e.LANGUAGE_APP="language_app",e.FIRST_ACTIVE_DATE="first_active_date",e.TIMEZONE="timezone",e.TIME_OF_DAY_LANDING="time_of_day_landing",e.DAY_OF_WEEK="day_of_week",e.IS_NEW_USER="is_new_user",e.IS_LOCAL_DAYTIME="is_local_daytime",e.IS_LOGIN="is_login",e.MAX_TOUCH_POINTS="max_touch_points",e.RET_ACC="ret_acc",e.SESSION_CNT="session_cnt",e.STAY_DURATION="stay_duration",e.SESSION_LAST_UPDATE_TIME="session_last_update_time",e.LOGIN_DAYS_COUNT="login_days_count",e.LOGIN_SUMBIT_COUNT="login_submit_count",e.LOING_BUTTON_CLICKED_COUNT="login_button_clicked_count",e.LOGIN_NOTIFY_TIME_STAMP="login_notify_time_stamp",e.TOGGLE_DARK_MODE_COUNT="toggle_dark_mode_count",e.TOGGLE_LIGHT_MODE_COUNT="toggle_light_mode_count",e.TOTAL_SCORE="total_score",e.HARDWARE_SCORE="hardware_score"}(i||(i={}));const o=["event_name","page_name","enter_method","platform","play_mode","popup_type","previous_page","enter_from"],a=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},{os:{available_values:["windows","mac","linux","ios","chromeos"],is_snapshot:!0},browser_brand:{available_values:["chrome","edge","safari","firefox"],is_snapshot:!0},screen_resolution:{is_snapshot:!0},screen_orientation:{is_snapshot:!0},cpu_core_number:{is_snapshot:!0},network_downlink:{is_snapshot:!0},network_rtt:{is_snapshot:!0},network_speed_effective_type:{available_values:["slow-2g","2g","3g","4g"],is_snapshot:!0},region:{available_values:["US","VN","JP","SG","BR","ID","FR","GB","PH","CA","DE","TH","MX","ES","PE","RU","AU","CO","DZ","UA","MY","KR","TR","AR","NL","IT","PL","TW","FI","PK","SA","EC","CL","EG","ZA","SE","KZ","RO","AE","BE"],is_snapshot:!0},launch_mode:{available_values:["organic","reflow","direct","referral","referral_embed","msft","webapp_reflow","pwa","twa","referral_creator_embed","push","referral_amp","referral_tiktok_browse","referral_music_embed","referral_hashtag_embed","referral_curated_embed","launch_mode_win_desktop_app","launch_mode_mac_desktop_app"],is_snapshot:!0},landing_page:{available_values:["homepage_hot","video_detail","others_homepage","discover_kw","explore_page","login","personal_homepage","general_search"],is_snapshot:!0},language_system:{available_values:["en-us","vi-vn","es-es","en-gb","zh-cn","pt-br","es-419","ja","ru-ru","fr-fr","de-de","th-th","es","vi","id-id","fr","es-us","ru","tr-tr","en"],is_snapshot:!0},language_app:{available_values:["en","es","vi-VN","pt-BR","zh-Hans","ru-RU","null","ja-JP","id-ID","th-TH","ar","fr","tr-TR","ko-KR","zh-Hant-TW"],is_snapshot:!0},first_active_date:{is_snapshot:!0},timezone:{is_snapshot:!0},time_of_day_landing:{is_snapshot:!0},day_of_week:{is_snapshot:!0},is_new_user:{is_snapshot:!0},is_local_daytime:{is_snapshot:!0},is_login:{is_snapshot:!0},max_touch_points:{is_snapshot:!0}}),{ret_acc:{},session_cnt:{},stay_duration:{},vv:{event_name:"video_play"},vv_finish:{event_name:"video_play_finish"},preview_vv:{event_name:"preview_video_play"},play_duration:{event_name:"play_time",aggregate_field:"duration"},page_view:{event_name:"page_view"},hot_page_view:{event_name:"page_view",page_name:"homepage_hot"},hot_vv:{event_name:"video_play",page_name:"homepage_hot"},hot_vv_finish:{event_name:"video_play_finish",page_name:"homepage_hot"},hot_play_duration:{event_name:"play_time",page_name:"homepage_hot",aggregate_field:"duration"},video_detail_page_view:{event_name:"page_view",page_name:"video_detail"},video_detail_vv:{event_name:"video_play",page_name:"video_detail"},video_detail_vv_finish:{event_name:"video_play_finish",page_name:"video_detail"},video_detail_play_duration:{event_name:"play_time",page_name:"video_detail",aggregate_field:"duration"},others_profile_page_view:{event_name:"page_view",page_name:"others_homepage"},others_profile_vv:{event_name:"video_play",page_name:"others_homepage"},others_profile_preview_vv:{event_name:"preview_video_play",page_name:"others_homepage"},others_profile_vv_finish:{event_name:"video_play_finish",page_name:"others_homepage"},others_profile_play_duration:{event_name:"play_time",page_name:"others_homepage",aggregate_field:"duration"},explore_page_view:{event_name:"page_view",page_name:"explore_page"},explore_page_preview_vv:{event_name:"preview_video_play",page_name:"explore_page"},explore_page_vv:{event_name:"video_play",page_name:"explore_page"},explore_page_vv_finish:{event_name:"video_play_finish",page_name:"explore_page"},explore_page_play_duration:{event_name:"play_time",page_name:"explore_page",aggregate_field:"duration"},self_profile_page_view:{event_name:"page_view",page_name:"personal_homepage"},self_profile_vv:{event_name:"video_play",page_name:"personal_homepage"},song_detail_page_view:{event_name:"page_view",page_name:"single_song"},song_detail_vv:{event_name:"video_play",page_name:"single_song"},song_detail_vv_finish:{event_name:"video_play_finish",page_name:"single_song"},song_detail_play_duration:{event_name:"play_time",page_name:"single_song",aggregate_field:"duration"},challenge_page_view:{event_name:"page_view",page_name:"challenge"},challenge_vv:{event_name:"video_play",page_name:"challenge"},challenge_vv_finish:{event_name:"video_play_finish",page_name:"challenge"},challenge_play_duration:{event_name:"play_time",page_name:"challenge",aggregate_field:"duration"},discover_kw_page_view:{event_name:"page_view",page_name:"discover_kw"},discover_kw_vv:{event_name:"video_play",page_name:"discover_kw"},discover_kw_vv_finish:{event_name:"video_play_finish",page_name:"discover_kw"},discover_kw_play_duration:{event_name:"play_time",page_name:"discover_kw",aggregate_field:"duration"},follow_vv:{event_name:"video_play",page_name:"homepage_follow"},live_recharge_page_view:{event_name:"page_view",page_name:"live_recharge"},business_suite_page_view:{event_name:"enter_business_suite"},slardar_perf_lcp_acc:{event_name:"slardar_perf_lcp",aggregate_field:"metric_duration",count_field_name:"slardar_perf_lcp_cnt",is_avg:!0},slardar_perf_lcp_cnt:{event_name:"slardar_perf_lcp",should_skip_sending:!0},slardar_perf_fcp_acc:{event_name:"slardar_perf_fcp",aggregate_field:"metric_duration",count_field_name:"slardar_perf_fcp_cnt",is_avg:!0},slardar_perf_fcp_cnt:{event_name:"slardar_perf_fcp",should_skip_sending:!0},login_page_view:{event_name:"page_view",page_name:"login"},general_search_page_view:{event_name:"page_view",page_name:"general_search"},messages_page_view:{event_name:"page_view",page_name:"messages"},upload_page_view:{event_name:"page_view",page_name:"upload"},live_detail_page_view:{event_name:"page_view",page_name:"live_detail"}}),{search_cnt:{event_name:"search"},app_download_cnt:{event_name:"click_get_app_for_pc"},auto_scroll_cnt:{event_name:"autoscroll_on"},muted_cnt:{event_name:"switch_sound"},floating_player_cnt:{event_name:"enter_mini_player"},report_cnt:{event_name:"click_report"},not_interested_cnt:{event_name:"dislike"},publish_cnt:{event_name:"click_upload_entrance"},push_cnt:{event_name:"browser_push_notifications_show"},update_profile_cnt:{event_name:"save_profile"},livesdk_studio_download_cnt:{event_name:"livesdk_web_livestudio_download"},send_message_cnt:{event_name:"send_message"},share_to_friends_cnt:{event_name:"share_video",platform:"message"},like_cnt:{event_name:"like"},comment_cnt:{event_name:"post_comment"},follow_cnt:{event_name:"follow"},favourite_cnt:{event_name:"favourite_video"},browser_mode_vv:{event_name:"video_play",play_mode:"browser_mode"},playlist_vv:{event_name:"video_play",popup_type:"playlist"},repost_cnt:{event_name:"repost_success"},share_cnt:{event_name:"share_video"},video_download_cnt:{event_name:"click_download"},left_navigation_suggested_account_visit_cnt:{event_name:"enter_personal_detail",enter_method:["click_navigation"]},creator_tab_show_cnt:{event_name:"from_this_creator_tab_show"},login_notify_cnt_periodic:{event_name:"login_notify",enter_method:["periodic_popup"]},login_notify_cnt_non_periodic:{event_name:"login_notify",enter_method:["click_like","click_comment","click_follow","click_top_bar","click_navigation","click_favorite"]},login_days_cnt:{},login_submit_cnt:{event_name:"login_submit"},login_button_clicked_cnt:{event_name:"login_notify",enter_method:["click_top_bar","click_navigation"]},login_popup_duration:{event_name:"login_notify_close",start_event_name:"login_notify_time_stamp",count_field_name:"login_notify_close_cnt",is_time_stamp:!0},login_notify_time_stamp:{event_name:"login_notify",enter_method:["click_like","click_comment","click_follow","click_top_bar","click_navigation","click_favorite"],aggregate_field:"time_stamp",should_skip_sending:!0},login_notify_close_cnt:{event_name:"login_notify_close",should_skip_sending:!0},toggle_dark_mode_cnt:{event_name:"dark_mode_click"},video_pause_by_switch_tab_cnt:{event_name:"video_pause",enter_method:["switch_tab"]},like_cnt_non_login:{event_name:"login_notify",enter_method:["click_like"]},comment_cnt_non_login:{event_name:"login_notify",enter_method:["click_comment"]},follow_cnt_non_login:{event_name:"login_notify",enter_method:["click_follow"]},favorite_cnt_non_login:{event_name:"login_notify",enter_method:["click_favorite"]}}),{item_avg_freshness:{event_name:"video_play",aggregate_field:"video_freshness",count_field_name:"vv",is_avg:!0},item_avg_duration:{event_name:"video_play",aggregate_field:"video_duration",count_field_name:"vv",is_avg:!0},item_avg_like_history:{event_name:"video_play",aggregate_field:"video_like_history",count_field_name:"vv",is_avg:!0},item_avg_vv_history:{event_name:"video_play",aggregate_field:"video_vv_history",count_field_name:"vv",is_avg:!0},item_avg_share_history:{event_name:"video_play",aggregate_field:"video_share_history",count_field_name:"vv",is_avg:!0},item_avg_comment_history:{event_name:"video_play",aggregate_field:"video_comment_history",count_field_name:"vv",is_avg:!0},item_avg_favorite_history:{event_name:"video_play",aggregate_field:"video_favorite_history",count_field_name:"vv",is_avg:!0},item_avg_resolution:{event_name:"video_play",aggregate_field:"video_resolution",count_field_name:"vv",is_avg:!0},item_portrait:{event_name:"video_play",aggregate_field:"video_is_portrait",count_field_name:"vv",is_avg:!0},item_100k_vv_vv:{event_name:"video_play",aggregate_field:"video_100k_vv"},creator_bluev_vv:{event_name:"video_play",aggregate_field:"video_creator_bluev"},creator_1k_follower_vv:{event_name:"video_play",aggregate_field:"video_creator_1k_follower"},creator_10k_follower_vv:{event_name:"video_play",aggregate_field:"video_creator_10k_follower"},creator_100k_follower_vv:{event_name:"video_play",aggregate_field:"video_creator_100k_follower"}}),{hot_like_cnt:{event_name:"like",page_name:"homepage_hot"},hot_comment_cnt:{event_name:"post_comment",page_name:"homepage_hot"},hot_follow_cnt:{event_name:"follow",page_name:"homepage_hot"},hot_favourite_cnt:{event_name:"favourite_video",page_name:"homepage_hot"},hot_browser_mode_vv:{event_name:"video_play",play_mode:"browser_mode",page_name:"homepage_hot"},hot_share_cnt:{event_name:"share_video",page_name:"homepage_hot"},hot_item_avg_freshness:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_freshness",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_duration:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_duration",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_like_history:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_like_history",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_vv_history:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_vv_history",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_share_history:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_share_history",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_comment_history:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_comment_history",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_favorite_history:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_favorite_history",count_field_name:"hot_vv",is_avg:!0},hot_item_avg_resolution:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_resolution",count_field_name:"hot_vv",is_avg:!0},hot_item_portrait:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_is_portrait",count_field_name:"hot_vv",is_avg:!0},hot_item_100k_vv_vv:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_100k_vv"},hot_creator_bluev_vv:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_creator_bluev"},hot_creator_1k_follower_vv:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_creator_1k_follower"},hot_creator_10k_follower_vv:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_creator_10k_follower"},hot_creator_100k_follower_vv:{event_name:"video_play",page_name:"homepage_hot",aggregate_field:"video_creator_100k_follower"},hot_to_video_detail_page_view:{event_name:"page_view",page_name:"video_detail",previous_page:"homepage_hot"},hot_to_explore_page_view:{event_name:"enter_explore_page",enter_from:"homepage_hot"},hot_to_follow_page_view:{event_name:"enter_homepage_follow",enter_from:"homepage_hot"},hot_to_other_profile_view:{event_name:"enter_personal_detail",enter_from:"homepage_hot"},hot_slardar_perf_lcp_acc:{event_name:"slardar_perf_lcp",page_name:"homepage_hot",aggregate_field:"metric_duration",count_field_name:"hot_slardar_perf_lcp_cnt",is_avg:!0},hot_slardar_perf_lcp_cnt:{event_name:"slardar_perf_lcp",page_name:"homepage_hot",should_skip_sending:!0}}),{explore_like_cnt:{event_name:"like",page_name:"explore_page"},explore_comment_cnt:{event_name:"post_comment",page_name:"explore_page"},explore_follow_cnt:{event_name:"follow",page_name:"explore_page"},explore_favourite_cnt:{event_name:"favourite_video",page_name:"explore_page"},explore_browser_mode_vv:{event_name:"video_play",play_mode:"browser_mode",page_name:"explore_page"},explore_share_cnt:{event_name:"share_video",page_name:"explore_page"},explore_item_avg_freshness:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_freshness",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_duration:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_duration",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_like_history:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_like_history",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_vv_history:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_vv_history",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_share_history:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_share_history",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_comment_history:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_comment_history",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_favorite_history:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_favorite_history",count_field_name:"explore_page_vv",is_avg:!0},explore_item_avg_resolution:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_resolution",count_field_name:"explore_page_vv",is_avg:!0},explore_item_portrait:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_is_portrait",count_field_name:"explore_page_vv",is_avg:!0},explore_item_100k_vv_vv:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_100k_vv"},explore_creator_bluev_vv:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_creator_bluev"},explore_creator_1k_follower_vv:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_creator_1k_follower"},explore_creator_10k_follower_vv:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_creator_10k_follower"},explore_creator_100k_follower_vv:{event_name:"video_play",page_name:"explore_page",aggregate_field:"video_creator_100k_follower"},explore_to_video_detail_page_view:{event_name:"page_view",page_name:"video_detail",previous_page:"explore_page"},explore_to_hot_page_view:{event_name:"enter_homepage_hot",enter_from:"explore_page"},explore_to_follow_page_view:{event_name:"enter_homepage_follow",enter_from:"explore_page"},explore_to_other_profile_view:{event_name:"enter_personal_detail",enter_from:"explore_page"},explore_slardar_perf_lcp_acc:{event_name:"slardar_perf_lcp",page_name:"explore_page",aggregate_field:"metric_duration",count_field_name:"explore_slardar_perf_lcp_cnt",is_avg:!0},explore_slardar_perf_lcp_cnt:{event_name:"slardar_perf_lcp",page_name:"explore_page",should_skip_sending:!0}}),{follow_like_cnt:{event_name:"like",page_name:"homepage_follow"},follow_comment_cnt:{event_name:"post_comment",page_name:"homepage_follow"},follow_follow_cnt:{event_name:"follow",page_name:"homepage_follow"},follow_favourite_cnt:{event_name:"favourite_video",page_name:"homepage_follow"},follow_browser_mode_vv:{event_name:"video_play",play_mode:"browser_mode",page_name:"homepage_follow"},follow_share_cnt:{event_name:"share_video",page_name:"homepage_follow"},follow_item_avg_freshness:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_freshness",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_duration:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_duration",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_like_history:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_like_history",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_vv_history:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_vv_history",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_share_history:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_share_history",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_comment_history:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_comment_history",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_favorite_history:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_favorite_history",count_field_name:"follow_vv",is_avg:!0},follow_item_avg_resolution:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_resolution",count_field_name:"follow_vv",is_avg:!0},follow_item_portrait:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_is_portrait",count_field_name:"follow_vv",is_avg:!0},follow_item_100k_vv_vv:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_100k_vv"},follow_creator_bluev_vv:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_creator_bluev"},follow_creator_1k_follower_vv:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_creator_1k_follower"},follow_creator_10k_follower_vv:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_creator_10k_follower"},follow_creator_100k_follower_vv:{event_name:"video_play",page_name:"homepage_follow",aggregate_field:"video_creator_100k_follower"},follow_to_video_detail_page_view:{event_name:"page_view",page_name:"video_detail",previous_page:"homepage_follow"},follow_to_explore_page_view:{event_name:"enter_explore_page",enter_from:"homepage_follow"},follow_to_hot_page_view:{event_name:"enter_homepage_hot",enter_from:"homepage_follow"},follow_to_other_profile_view:{event_name:"enter_personal_detail",enter_from:"homepage_follow"},follow_slardar_perf_lcp_acc:{event_name:"slardar_perf_lcp",page_name:"homepage_follow",aggregate_field:"metric_duration",count_field_name:"follow_slardar_perf_lcp_cnt",is_avg:!0},follow_slardar_perf_lcp_cnt:{event_name:"slardar_perf_lcp",page_name:"homepage_follow",should_skip_sending:!0}}),{video_detail_like_cnt:{event_name:"like",page_name:"video_detail"},video_detail_comment_cnt:{event_name:"post_comment",page_name:"video_detail"},video_detail_follow_cnt:{event_name:"follow",page_name:"video_detail"},video_detail_favourite_cnt:{event_name:"favourite_video",page_name:"video_detail"},video_detail_share_cnt:{event_name:"share_video",page_name:"video_detail"},video_detail_item_avg_freshness:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_freshness",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_duration:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_duration",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_like_history:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_like_history",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_vv_history:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_vv_history",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_share_history:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_share_history",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_comment_history:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_comment_history",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_favorite_history:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_favorite_history",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_avg_resolution:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_resolution",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_portrait:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_is_portrait",count_field_name:"video_detail_vv",is_avg:!0},video_detail_item_100k_vv_vv:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_100k_vv"},video_detail_creator_bluev_vv:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_creator_bluev"},video_detail_creator_1k_follower_vv:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_creator_1k_follower"},video_detail_creator_10k_follower_vv:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_creator_10k_follower"},video_detail_creator_100k_follower_vv:{event_name:"video_play",page_name:"video_detail",aggregate_field:"video_creator_100k_follower"},video_detail_to_hot_page_view:{event_name:"enter_homepage_hot",enter_from:"video_detail"},video_detail_to_explore_page_view:{event_name:"enter_explore_page",enter_from:"video_detail"},video_detail_to_follow_page_view:{event_name:"enter_homepage_follow",enter_from:"video_detail"},video_detail_to_other_profile_view:{event_name:"enter_personal_detail",enter_from:"video_detail"},video_detail_yml_cover_clicks_cnt:{event_name:"video_cover_click"},video_detail_slardar_perf_lcp_acc:{event_name:"slardar_perf_lcp",page_name:"video_detail",aggregate_field:"metric_duration",count_field_name:"video_detail_slardar_perf_lcp_cnt",is_avg:!0},video_detail_slardar_perf_lcp_cnt:{event_name:"slardar_perf_lcp",page_name:"video_detail",should_skip_sending:!0}}),{other_profile_creator_bluev_vv:{event_name:"video_play",page_name:"others_homepage",aggregate_field:"video_creator_bluev"},other_profile_creator_1k_follower_vv:{event_name:"video_play",page_name:"others_homepage",aggregate_field:"video_creator_1k_follower"},other_profile_creator_10k_follower_vv:{event_name:"video_play",page_name:"others_homepage",aggregate_field:"video_creator_10k_follower"},other_profile_creator_100k_follower_vv:{event_name:"video_play",page_name:"others_homepage",aggregate_field:"video_creator_100k_follower"},other_profile_to_video_detail_page_view:{event_name:"page_view",page_name:"video_detail",previous_page:"others_homepage"},other_profile_to_hot_page_view:{event_name:"enter_homepage_hot",enter_from:"others_homepage"},other_profile_to_follow_view:{event_name:"enter_homepage_follow",enter_from:"others_homepage"},other_profile_to_explore_page_view:{event_name:"enter_explore_page",enter_from:"others_homepage"},other_profile_playlist_vv:{event_name:"video_play",popup_type:"playlist",page_name:"others_homepage"},other_profile_follow_cnt:{event_name:"follow",page_name:"others_homepage"},other_profile_send_message_cnt:{event_name:"send_message",page_name:"others_homepage"},other_profile_sort_cnt:{event_name:"click_sort_option"},other_profile_share_user_profile_cnt:{event_name:"share",page_name:"others_homepage",type:"profile"},other_profile_slardar_perf_lcp_acc:{event_name:"slardar_perf_lcp",page_name:"others_homepage",aggregate_field:"metric_duration",count_field_name:"other_profile_slardar_perf_lcp_cnt",is_avg:!0},other_profile_slardar_perf_lcp_cnt:{event_name:"slardar_perf_lcp",page_name:"others_homepage",should_skip_sending:!0}}),{ret_acc_3:{is_retention:!0,retention_count:3},ret_acc_7:{is_retention:!0,retention_count:7},total_score:{is_snapshot:!0},hardware_score:{is_snapshot:!0}})},93608:(e,t,n)=>{"use strict";n.d(t,{f:()=>_});var i,o=n(71510),a=n.n(o),r=n(67823),s=n(31578),l=n(67134),c=n(40040),d=n(92603),u=n(68252),p=n(15203),v=n(91498);!function(e){e.Firefox="firefox",e.Google="google",e.Edge="edge",e.Safari="safari",e.Opera="opera",e.Yandex="yandex",e.Samsung="samsung",e.UC="uc",e.Other="unknown"}(i||(i={}));var m=n(56203);function g(){try{return Math.floor(performance.now())}catch(e){}return Date.now()-(performance.timeOrigin||performance.timing.navigationStart)}class h{get commonParams(){return this.commonEventParams}get teaBaseConfig(){return this.baseConfig}get isOff(){return!1}get isDebugOn(){return!1}get initDimensionalData(){return this.dimensionalData||(this.dimensionalData=this.getDimensionalData()),this.dimensionalData}get dataCollectionEnabled(){return!!this.commonEventParams.data_collection_enabled}constructor(e=n(80249).A,t=[],i=!1,o=!1,a={},r={},s={},l=void 0){this.instance=e,this.missEventsCaches=t,this.initialized=i,this.isCommonParamsUpdated=o,this.baseConfig=a,this.additionalConfig=r,this.localEventMap=s,this.abTestVersion=l,this.commonEventParams={},this.exposedExperiments=new Set,this.webExperimentExposeCallback=(e,t)=>{t&&this.exposedExperiments.add(e)}}config(e){const{initConfig:t,commonHeaderConfig:n,commonEventParams:i,abTestVersion:o}=e;if(this.abTestVersion=o,this.initialized||this.init(t),n){const e=(0,d.$Z)();this.baseConfig=a()(this.baseConfig,n,{evtParams:{object_id:e.object_id}})}i&&(this.baseConfig=a()(this.baseConfig,{evtParams:{page_name:i.page_name,enter_from:i.enter_from}}),this.commonEventParams=Object.assign(Object.assign({},this.commonEventParams),i),this.isCommonParamsUpdated=!0),this.instance.config(this.baseConfig),this.sendMissedCache()}beconEvent(e,t={}){if(this.initialized&&!this.isOff)try{this.instance.beconEvent(e,Object.assign(Object.assign({time_from_origin:g()},this.commonEventParams),t))}catch(e){}}event(e,t={},n=!0,i=!1){var o,a,r;if(this.isOff)return;const s=g();let l=Object.assign(Object.assign({time_from_origin:s},this.commonEventParams),t);const c=Object.assign(Object.assign({},this.baseConfig),this.additionalConfig);let d=!1;try{this.abTestVersion&&(d="v1"===(null===(r=null===(a=null===(o=this.abTestVersion)||void 0===o?void 0:o.parameters)||void 0===a?void 0:a.webapp_feature_expansion)||void 0===r?void 0:r.vid))}catch(e){console.error("Error: Unable to get AB info for feature collection status!",e)}if(d)try{(0,u.rS)(e,Object.assign(Object.assign({},c),l),m.gb,this.localEventMap),l=(0,u.vG)(l)}catch(e){console.log("Error updating feature store: ",e)}if(!this.initialized||n&&!this.isCommonParamsUpdated)this.missEventsCaches.push([e,Object.assign({time_from_origin:s},t)]);else try{this.isDebugOn&&(console.log(`[tea]: ${e}`),console.log(l)),this.createTeaEventHandler(e)(l,i),this.sendMissedCache()}catch(e){}}getInstance(){return this.instance}setDomain(e){this.instance.setDomain(e),this.instance.event("reactive_domain")}setDataCollectionEnabled(e){this.commonEventParams.data_collection_enabled=e?1:0}resetConfig(){this.isCommonParamsUpdated=!1,this.missEventsCaches.length=0}on(e,t){this.instance.on(e,t)}off(e,t){this.instance.off(e,t)}resetStayDuration(e,t,n){this.instance.resetStayDuration(e,t,n)}getDimensionalData(){var e;const t=(0,d.$Z)();"microsoft-store"!==t["app-install-source"]&&"app-info://platform/microsoft-store"!==document.referrer||(t.source="msft");const{traffic_type:n,referer_video_id:i,refer:o,source:a="",referer_url:r}=t,l=(null!==(e=new RegExp(`${location.origin}/(@?\\w+)`).exec(document.referrer))&&void 0!==e?e:[])[1],u=(0,s.Ny)(navigator.userAgent)?"mobile":"pc",m=(0,p.q)(r),g=(0,v.o7)(),h=(_=navigator.userAgent,/(Edge|Edg)\/([\w.]+)/i.test(_)?"edge":/Firefox|FxiOS/i.exec(_)?"firefox":/\s(opr)\/([\w.]+)/i.test(_)?"opera":/yabrowser\/([\w.]+)/i.test(_)?"yandex":/SamsungBrowser\/([\w.]+)/i.test(_)?"samsung":/(UCBrowser|UBrowser)\/([\w.]+)/i.test(_)?"uc":/Chrome|chromium|CriOS/i.test(_)?"google":/Safari/i.test(_)?"safari":"unknown");var _;const f=(()=>{if("undefined"==typeof window||"undefined"==typeof document)return!1;const e=window.navigator.userAgent;if(!/iPad|iPhone|iPod/.test(e))return!!(null===window||void 0===window?void 0:window.MediaSource)&&((null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.1.6.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.2.4.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.3.E.L120.90"'))||(null===window||void 0===window?void 0:window.MediaSource.isTypeSupported('video/mp4;codecs="hev1.4.10.L120.90"')));try{const e=document.createElement("video");return[e.canPlayType('video/mp4; codecs="hvc1.1.L0.0"'),e.canPlayType('video/mp4;codecs="hev1.1.6.L120.90"'),e.canPlayType('video/mp4;codecs="hev1.2.4.L120.90"'),e.canPlayType('video/mp4;codecs="hev1.3.E.L120.90"'),e.canPlayType('video/mp4;codecs="hev1.4.10.L120.90"')].some((e=>"probably"===e||"maybe"===e))}catch(e){return!1}})(),y=function(){if("undefined"!=typeof navigator)return null===navigator||void 0===navigator?void 0:navigator.deviceMemory}();return(0,d._i)(t),this.dimensionalData={device:u,launch_mode:g,device_memory:y,traffic_type:null!=n?n:m,source:c.LN.test(a)?"":a,referer_video_id:i,utm_source:t.utm_source,utm_medium:t.utm_medium,utm_campaign:t.utm_campaign,utm_term:t.utm_term,utm_content:t.utm_content,embed_source:t.embed_source,referer_url:r?decodeURIComponent(r):(null==o?void 0:o.replace(c.wO,""))||l||document.referrer||c.oE,browserName:h,hevcSupported:f?1:0,cpu_core:navigator.hardwareConcurrency||0},this.dimensionalData}getSessionId(e){let t=(0,d.Hd)(c.qZ);return t||(t=e+Date.now().toString(),(0,d.J2)("webapp_session_id",t)),t}getLandingPage(e){const t=(0,d.Hd)(c.iJ);return t?(this.commonEventParams.is_landing_page=0,t):(this.commonEventParams.is_landing_page=1,(0,d.J2)(c.iJ,e),e)}getPreviousInfo(e){var t;let n={};try{n=JSON.parse(null!==(t=(0,d.Hd)(c.QI))&&void 0!==t?t:"null")||{}}catch(e){n={}}return location.href!==n.href||e!==n.pageName?((0,d.J2)(c.QI,JSON.stringify({href:location.href,pageName:e,twoPrev:n.pageName,twoPrevHref:n.href})),n.pageName):n.twoPrev}getVar(e,t){var n;const i=this.webExperimentExposeCallback.bind(null,e);return this.exposedExperiments.has(e)||this.instance.getVar(e,t,i),(null===(n=this.webExperiments)||void 0===n?void 0:n.values)&&this.webExperiments.values[e]||{}}getVarWithCb(e,t,n){this.instance.getVar(e,t,n)}initWebExperiments(){this.instance.getAllVars((e=>{this.webExperiments={values:e,isReady:!0}}))}init(e){var t,n,i,o,a,s,l,c,d;this.instance.init({site_name:"",enable_ttwebid:!0,channel_domain:e.channel_domain,channel:e.channel,channel_type:null!==(t=e.channel_type)&&void 0!==t?t:"tcpy",app_id:e.id,need_zip:null!==(n=e.need_zip)&&void 0!==n?n:void 0,enable_stay_duration:null===(i=e.enable_stay_duration)||void 0===i||i,reportTime:null!==(o=e.reportTime)&&void 0!==o?o:void 0,enable_ab_test:!0,ab_channel_domain:e.ab_channel_domain||e.channel_domain,commonParams:{page_type:!0},enable_debug:!0,autotrack:e.autotrack}),this.initialized=!0;const p=r.A.get("tea_sid");var v;(v=p)&&/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(v)&&(console.log("use TEA_SID_KEY",p),this.instance.setSessionId(p)),this.instance.start(),this.initWebExperiments(),this.additionalConfig={os:null!==(a=this.instance.getConfig("os_name"))&&void 0!==a?a:"",browser_brand:null!==(s=this.instance.getConfig("browser"))&&void 0!==s?s:"",width:null!==(l=this.instance.getConfig("screen_width"))&&void 0!==l?l:0,height:null!==(c=this.instance.getConfig("screen_height"))&&void 0!==c?c:0,language_sys:null!==(d=this.instance.getConfig("language"))&&void 0!==d?d:""},this.localEventMap=(0,u.Zl)(m.gb)}sendMissedCache(){try{this.missEventsCaches.length&&(this.missEventsCaches.forEach((e=>{const t=Object.assign(Object.assign({},this.commonEventParams),e[1]);this.instance.event(e[0],t),this.isDebugOn&&(console.log("[tea]: send cached event",e),console.log(t))})),this.missEventsCaches.length=0)}catch(e){}}createTeaEventHandler(e){return(...[t])=>{this.instance.event(e,t)}}sendEvent(e,t={},n=!0,i=!0){this.event(e,t,n,i)}}const _=(0,l.U)("Tea@tiktok/tea",(()=>new h))},92603:(e,t,n)=>{"use strict";n.d(t,{$Z:()=>o,Hd:()=>r,J2:()=>s,X:()=>l,_i:()=>a});var i=n(4474);function o(){if("undefined"==typeof document)return{};const e=(0,i.parse)(location.search,{arrayFormat:"bracket"});return Object.keys(e).forEach((t=>{var n,i;"string"!=typeof e[t]&&(e[t]=null!==(i=null===(n=e[t])||void 0===n?void 0:n[0])&&void 0!==i?i:"")})),e}function a(e){["utm_source","utm_medium","utm_campaign","utm_term","utm_content","referer_url","referer_video_id"].forEach((t=>{var n;e[t]&&s(t,null!==(n=e[t])&&void 0!==n?n:"")}))}function r(e,t=""){var n;try{return null!==(n=sessionStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}function s(e,t){try{sessionStorage.setItem(e,t)}catch(e){}}function l(e){try{sessionStorage.removeItem(e)}catch(e){}}},91498:(e,t,n)=>{"use strict";n.d(t,{o7:()=>l});var i=n(31578),o=n(40040),a=n(92603),r=n(15203);const s=(e,t=!1)=>{const n=new URL(window.location.href);if(t){const{origin:e,pathname:t}=n;return`${e}${t}`}return e.forEach((e=>n.searchParams.delete(e))),n.href};function l(e){var t;const n=null!=e?e:(0,a.$Z)();"microsoft-store"!==n["app-install-source"]&&"app-info://platform/microsoft-store"!==(null===document||void 0===document?void 0:document.referrer)||(n.source="msft");const{lm:l,refer:c,source:d="",is_from_webapp:u,referer_url:p="",_r:v,previous_launch_mode:m,previous_langding_page:g,show_promote:h}=n,_=(null!==(t=new RegExp(`${location.origin}/(@?\\w+)`).exec(document.referrer))&&void 0!==t?t:[])[1],f=(0,a.Hd)(o.O_,void 0),y="embed"===_||"embed"===c,b="creator_embed"===c,w="amp"===_||/^amp_\w+/.test(p);if(f&&!y&&!w&&!b)return f;const x=function({device:e,source:t,lm:n,siteOnePath:i,refer:o,refererUrl:a="",fromWebapp:r,queryR:s,trafficType:l,previousLaunchMode:c,showPromote:d}){var u;const p="embed"===i||"embed"===o,v="creator_embed"===o,m="music_embed"===o,g="hashtag_embed"===o,h="curated_embed"===o,_="trending_embed"===o,f="amp"===i||/^amp_\w+/.test(a);return"1"===d?"email":"undefined"!=typeof window&&(null===(u=null===window||void 0===window?void 0:window.TTE_ENV)||void 0===u?void 0:u.isElectron)?window.TTE_ENV.osVersion.includes("Mac OS")?"mac_desktop_app":"win_desktop_app":c||("msft"===t?"msft":"twa"===t?"twa":"push"===t?"push":"samsung_quick_access"===t?"samsung_quick_access":"undefined"!=typeof window&&(navigator.standalone||"pc"===e&&window.matchMedia("(display-mode: standalone), (display-mode: minimal-ui)").matches||"mobile"===e&&window.matchMedia("(display-mode: standalone), (display-mode: minimal-ui), (display-mode: fullscreen)").matches)?"pwa":"11"===n?"paid":p?"referral_embed":v?"referral_creator_embed":m?"referral_music_embed":g?"referral_hashtag_embed":_?"referral_trending_embed":h?"referral_curated_embed":f?"referral_amp":"tiktok_browse"===o?"referral_tiktok_browse":/google|yahoo|yandex|bing|naver|duckduckgo/gi.test(l)?"organic":"1"===s?"reflow":"webapp"===t||r?"webapp_reflow":o||a||"undefined"!=typeof document&&document.referrer?"referral":"direct")}({refer:c,device:(0,i.Ny)(navigator.userAgent)?"mobile":"pc",refererUrl:p,lm:l,trafficType:(0,r.q)(p),source:d,fromWebapp:u,siteOnePath:_,queryR:v,previousLaunchMode:m,showPromote:h});return(0,a.J2)(o.O_,x),g&&(0,a.J2)(o.iJ,g),m&&window.history.replaceState({},"",s(["previous_launch_mode","previous_langding_page"])),x}},68252:(e,t,n)=>{"use strict";n.d(t,{AP:()=>h,QR:()=>d,SE:()=>p,Zl:()=>l,_S:()=>g,rS:()=>m,sG:()=>c,uh:()=>_,vG:()=>v});var i=n(58632),o=n(40040),a=n(56203),r=n(93608),s=n(92603);const l=e=>{const t={};return Object.entries(e).forEach((([e,n])=>{const i=n.event_name;i&&(t[i]||(t[i]=[]),t[i].push(e))})),t},c=e=>{const t=e.match(/^(\d+)p$/);return t?parseInt(t[1],10):0},d=(e=0)=>{if(!e||0===e)return 0;const t=10===e.toString().length?1e3*e:e,n=(new Date).getTime()-new Date(t).getTime();return Math.floor(n/864e5)},u=(e,t)=>{var n,i,o,r,s,l,c,u,p,v,m;const g={[a.mD.OS]:null!==(i=null===(n=t.os)||void 0===n?void 0:n.toLowerCase())&&void 0!==i?i:"",[a.mD.BROWSER_BRAND]:"microsoft edge"===(null===(o=t.browser_brand)||void 0===o?void 0:o.toLowerCase())?"edge":null!==(s=null===(r=t.browser_brand)||void 0===r?void 0:r.toLowerCase())&&void 0!==s?s:"",[a.mD.SCREEN_RESOLUTION]:(null!==(l=t.width)&&void 0!==l?l:0)*(null!==(c=t.height)&&void 0!==c?c:0),[a.mD.SCREEN_ORIENTATION]:(null!==(u=t.width)&&void 0!==u?u:0)>(null!==(p=t.height)&&void 0!==p?p:0)?1:0,[a.mD.CPU_CORE_NUMBER]:t["header.custom"].cpu_core,[a.mD.NETWORK_DOWNLINK]:t["header.custom"].network_downlink,[a.mD.NETWORK_RTT]:t["header.custom"].network_rtt,[a.mD.NETWORK_SPEED_EFFECTIVE_TYPE]:t["header.custom"].network_speed_effective_type,[a.mD.REGION]:t.region,[a.mD.LAUNCH_MODE]:t["header.custom"].launch_mode,[a.mD.LANDING_PAGE]:t["header.custom"].landing_page,[a.mD.LANGUAGE_SYSTEM]:null!==(m=null===(v=t.language_sys)||void 0===v?void 0:v.toLowerCase())&&void 0!==m?m:"",[a.mD.LANGUAGE_APP]:t["header.custom"].app_language,[a.mD.TIMEZONE]:-(new Date).getTimezoneOffset()/60,[a.mD.TIME_OF_DAY_LANDING]:(new Date).getHours(),[a.mD.DAY_OF_WEEK]:(new Date).getDay(),[a.mD.IS_LOCAL_DAYTIME]:(new Date).getHours()>=6&&(new Date).getHours()<18?1:0,[a.mD.IS_LOGIN]:t["header.custom"].user_is_login,[a.mD.MAX_TOUCH_POINTS]:t["header.custom"].max_touch_points,[a.mD.RET_ACC]:1,[a.mD.TOTAL_SCORE]:t["header.custom"].total_score,[a.mD.HARDWARE_SCORE]:t["header.custom"].hardware_score};t.webIdCreatedTime&&0!==t.webIdCreatedTime&&(g[a.mD.FIRST_ACTIVE_DATE]=d(t.webIdCreatedTime),g[a.mD.IS_NEW_USER]=0===d(t.webIdCreatedTime)?1:0),t.user_is_login&&(g[a.mD.LOGIN_DAYS_COUNT]=1),e[(new Date).toLocaleDateString("en-US")][t.user_unique_id]=Object.assign(Object.assign({},e[(new Date).toLocaleDateString("en-US")][t.user_unique_id]),g)},p=e=>{var t,n,i,s,l,c,d,p,v,m,h,_,f;const y=g(o.ne)||"{}",b=JSON.parse(y),w=(new Date).toLocaleDateString("en-US");b[w]||(b[w]={[e]:{}}),b[w][e]||(b[w][e]={});const x=b[w][e];x[a.mD.SESSION_LAST_UPDATE_TIME]||(x[a.mD.SESSION_LAST_UPDATE_TIME]=(new Date).getTime()),x[a.mD.STAY_DURATION]||(x[a.mD.STAY_DURATION]=0),x[a.mD.SESSION_CNT]||(x[a.mD.SESSION_CNT]=1);const T=r.f.getInstance(),k=null==T?void 0:T.getConfig();if(!k)return console.error("Error. Tea config not found!"),b;const S=k.header,E={user_unique_id:e,user_is_login:null!==(n=null===(t=k.user)||void 0===t?void 0:t.user_is_login)&&void 0!==n?n:0,webIdCreatedTime:null===(i=null==S?void 0:S.custom)||void 0===i?void 0:i.webid_created_time,os:null==S?void 0:S.os_name,browser_brand:null==S?void 0:S.browser,width:null==S?void 0:S.screen_width,height:null==S?void 0:S.screen_height,region:null==S?void 0:S.region,language_sys:null==S?void 0:S.language,"header.custom":{cpu_core:null===(s=null==S?void 0:S.custom)||void 0===s?void 0:s.cpu_core,network_downlink:null===(l=navigator.connection)||void 0===l?void 0:l.downlink,network_rtt:null===(c=navigator.connection)||void 0===c?void 0:c.rtt,network_speed_effective_type:null===(d=navigator.connection)||void 0===d?void 0:d.effectiveType,launch_mode:null===(p=null==S?void 0:S.custom)||void 0===p?void 0:p.launch_mode,landing_page:0,app_language:null===(v=null==S?void 0:S.custom)||void 0===v?void 0:v.app_language,user_is_login:null!==(h=null===(m=k.user)||void 0===m?void 0:m.user_is_login)&&void 0!==h?h:0,max_touch_points:null===navigator||void 0===navigator?void 0:navigator.maxTouchPoints,total_score:null===(_=null==S?void 0:S.custom)||void 0===_?void 0:_.total_score,hardware_score:null===(f=null==S?void 0:S.custom)||void 0===f?void 0:f.hardware_score}};return u(b,E),b},v=e=>{const{video_freshness:t,video_like_history:n,video_vv_history:o,video_share_history:a,video_comment_history:r,video_favorite_history:s,video_resolution:l,video_is_portrait:c,video_100k_vv:d,video_creator_bluev:u,video_creator_1k_follower:p,video_creator_10k_follower:v,video_creator_100k_follower:m}=e;return(0,i.__rest)(e,["video_freshness","video_like_history","video_vv_history","video_share_history","video_comment_history","video_favorite_history","video_resolution","video_is_portrait","video_100k_vv","video_creator_bluev","video_creator_1k_follower","video_creator_10k_follower","video_creator_100k_follower"])},m=(e,t,n,i)=>{const{page_name:r,user_unique_id:l,enter_method:c,platform:d,play_mode:v,popup_type:m,previous_page:g,enter_from:_}=t,f=p(l),y=((e,t,n)=>{if(!e.event_name||!n||!n[e.event_name])return[];const i=[],o=n[e.event_name]||[];return o&&0!==o.length?(o.forEach((n=>{const o=t[n];o&&!o.is_snapshot&&a.NX.every((t=>!o[t]||(Array.isArray(o[t])?o[t].includes(e[t]):o[t]===e[t])))&&i.push(n)})),i):[]})({event_name:e,page_name:r,enter_method:c,platform:d,play_mode:v,popup_type:m,previous_page:g,enter_from:_},n,i);0!==y.length&&(l&&(y.forEach((e=>{((e,t,n,i,o)=>{const a=(new Date).toLocaleDateString("en-US"),r=t[a][e],{aggregate_field:s,should_skip_updating:l,is_time_stamp:c}=i[n];if(!l&&(void 0!==r[n]?r[n]="time_stamp"===s?(new Date).getHours():parseFloat((r[n]+o).toFixed(2)):t[a][e]="time_stamp"===s?Object.assign(Object.assign({},r),{[n]:(new Date).getHours()}):Object.assign(Object.assign({},r),{[n]:parseFloat(o.toFixed(2))}),c)){const o=i[n].start_event_name;r[o]&&(void 0!==r[n]?r[n]+=(new Date).getTime()-r[o]:t[a][e]=Object.assign(Object.assign({},r),{[n]:(new Date).getTime()-r[o]}))}})(l,f,e,n,((e,t,n)=>{var i,o,a;if(!e||!e[t])return console.error(`featureName: ${t} not found on feature def!`),0;const{aggregate_field:r}=e[t];return"duration"===r?parseFloat(null===(i=n[r]/6e4)||void 0===i?void 0:i.toFixed(2)):"metric_duration"===r?parseFloat(null===(o=n[r]/1e3)||void 0===o?void 0:o.toFixed(2)):r?parseFloat(null===(a=n[r])||void 0===a?void 0:a.toFixed(2)):1})(n,e,t))})),u(f,t),((e,t)=>{var n;const i=(new Date).toLocaleDateString("en-US"),r=(0,s.Hd)(o.qZ),l=null===(n=e["header.custom"])||void 0===n?void 0:n.session_id,c=t[i][e.user_unique_id];r===l?c[a.mD.STAY_DURATION]+=parseFloat((((new Date).getTime()-c[a.mD.SESSION_LAST_UPDATE_TIME])/6e4).toFixed(2)):c[a.mD.SESSION_CNT]++,c[a.mD.SESSION_LAST_UPDATE_TIME]=(new Date).getTime()})(t,f)),h(o.ne,JSON.stringify(f)))};function g(e,t=""){var n;try{return null!==(n=localStorage.getItem(e))&&void 0!==n?n:t}catch(e){return t}}function h(e,t){try{localStorage.setItem(e,t)}catch(e){}}const _=(e="",t=!1)=>{if(t)return!0;const n="1"===g(o.Is,"0"),i=o.lG.includes(e);return n&&!i}},15203:(e,t,n)=>{"use strict";n.d(t,{q:()=>r});var i=n(40040),o=n(92603);const a=1e3;function r(e){var t;let n;const r="undefined"!=typeof window;if(r&&(e=e?decodeURIComponent(e):document.referrer,n=(0,o.Hd)(i.em)),!n){if(!e||e.length>a)n="no_referrer";else{const o=/^https?:\/\/.*(google|yahoo|yandex|bing|naver|duckduckgo|neeva|wikipedia|facebook|instagram|youtube|twitter|tiktok|buzzfeed|debate|greenlemon|cloudfront|multimedios|huffpost|sdpnoticias|pinterest|bluradio|eluniversal|elcomercio|insider|medialeaks|intheknow|distractify|telediario|msn|linkedin|discord|whatsapp|telegram|viber|reddit|twitch|snapchat|messenger).*\/?/;n=(null!==(t=e.match(o))&&void 0!==t?t:[])[1]||i.YH}r&&(0,o.J2)(i.em,n)}return n}},40407:(e,t,n)=>{"use strict";n.d(t,{ZC:()=>s});var i=n(68252),o=n(40040);const a=e=>new Date((new Date).getTime()-864e5*e).toLocaleDateString("en-US"),r=(e,t,n,i)=>Array.from({length:e},((e,t)=>a(t))).reduce(((e,o)=>{var a,r;return void 0!==(null===(r=null===(a=n[o])||void 0===a?void 0:a[t])||void 0===r?void 0:r[i])?e+1:e}),0),s=(e,t,n)=>{var s;if(!e)return[];try{const l=(0,i.SE)(e),c={},d=[];return Array(t).fill(0).forEach(((i,o)=>{var s;const u=a(t-o-1);(null===(s=l[u])||void 0===s?void 0:s[e])&&(d.push(((e,t,n,i,o)=>{let a=[];const s=t===(new Date).toLocaleDateString("en-US");return Object.entries(n).forEach((([n,l])=>{var c,d,u;const{should_skip_sending:p,available_values:v,is_snapshot:m,is_avg:g,count_field_name:h,is_retention:_,retention_count:f}=l;if(!p)if(v)a=a.concat(((e,t,n,i,o,a)=>{var r,s;const l=t===(new Date).toLocaleDateString("en-US"),c=null===(s=null===(r=a[t])||void 0===r?void 0:r[e])||void 0===s?void 0:s[n];return[...i.map((e=>e!==c||o&&!l?0:1)),i.includes(c)||o&&!l?0:1]})(e,t,n,v,m,i));else if(_&&f){const t=r(f,e,i,"ret_acc")/r(o,e,i,"ret_acc");a.push(t)}else if(null===(d=null===(c=i[t])||void 0===c?void 0:c[e])||void 0===d?void 0:d[n])if(!m||s)if(g&&h){const s=i[t][e][h];if(s&&s>=1&&i[t][e][n]){const l=i[t][e][n]/(s*(null!==(u=r(o,e,i,n))&&void 0!==u?u:1));a.push(parseFloat(l.toFixed(2)))}else a.push(0)}else a.push(i[t][e][n]);else a.push(0);else a.push(0)})),a})(e,u,n,l,t)),c[u]=l[u])})),(0,i.AP)(o.ne,JSON.stringify(c)),d.reduce(((e,t)=>(e.length!==t.length&&console.error("Error! Payload length mismatch!"),e.forEach(((n,i)=>{e[i]+=t[i]})),e)),new Array(null===(s=d[0])||void 0===s?void 0:s.length).fill(0))}catch(e){return console.error("Error generating prediction payload! ",e),[]}}},39522:(e,t,n)=>{"use strict";n.d(t,{J:()=>o,Z:()=>i});const i={Positive:"rgba(11, 224, 155, 1)",Negative:"rgba(255, 76, 58, 1)",ToastDefault:"rgba(84, 84, 84, .92)",ToastNegative:"rgba(255, 76, 58, .92)",Secondary:"rgba(32, 213, 236, 1)",TUXSecondary2:"rgba(16, 162, 197, 1)",Positive2:"rgba(79, 171, 126, 1)",ConstTextInverse:"rgba(255, 255, 255, 1)",ConstTextInverse2:"rgba(255, 255, 255, .9)",ConstTextInverse3:"rgba(255, 255, 255, .75)",ConstTextInverse4:"rgba(255, 255, 255, .5)",ConstTextInverse5:"rgba(255, 255, 255, .34)",ConstTextPrimary:"rgba(22, 24, 35, 1)",ConstBGInverse:"rgba(0, 0, 0, 1)",ConstBGInverse2:"rgba(0, 0, 0, .6)",ConstBGInverse3:"rgba(37, 37, 37, .6)",ConstBGInverse4:"rgba(84, 84, 84, .5)",TUXBGCreation:"rgba(0, 0, 0, 1)",BGCreation2:"rgba(27, 27, 27, 1)",BGCreation5:"rgba(0, 0, 0, .15)",ConstBGMat:"rgba(255, 255, 255, .2)",ConstBGContainer:"rgba(255, 255, 255, .12)",ConstBGContainer2:"rgba(255, 255, 255, .08)",ConstBGContainer3:"rgba(255, 255, 255, .04)",ConstBGPlaceholderOpaque:"rgba(241, 241, 241, 1)",ConstBGInverseOpaque:"rgba(37, 37, 37, 1)",ConstBGInverse1:"rgba(56, 56, 56, .95)",ConstLineInverse:"rgba(255, 255, 255, .2)",ConstLineInverse2:"rgba(255, 255, 255, .12)",SDPrimary:"rgba(0, 0, 0, .8)",AssistColorYellow:"rgba(250, 206, 21, 1)",Primary:"rgba(254, 44, 85, 1)",Link:"rgba(254, 44, 85, 1)",Primary2:"rgba(22, 24, 35, 1)",TextPrimary:"rgba(22, 24, 35, 1)",TextSecondary:"rgba(22, 24, 35, .75)",TextTertiary:"rgba(22, 24, 35, .5)",TextQuaternary:"rgba(22, 24, 35, .34)",BGBase:"rgba(245, 245, 245, 1)",BGPrimary:"rgba(255, 255, 255, 1)",BGSecondary:"rgba(255, 255, 255, 1)",BGTertiary:"rgba(255, 255, 255, 1)",BGQuaternary:"rgba(255, 255, 255, 1)",BGQuinary:"rgba(255, 255, 255, 1)",BGSecondary2:"rgba(255, 255, 255, 1)",BGTertiary2:"rgba(255, 255, 255, 1)",BGPlaceholderDefault:"rgba(22, 24, 35, .06)",BGPlaceholderOpaque:"rgba(241, 241, 241, 1)",BGInput:"rgba(22, 24, 35, .06)",BGInput2:"rgba(22, 24, 35, .06)",BGView:"rgba(22, 24, 35, .03)",BGCreation3:"rgba(248, 248, 248, 1)",BGCreation4:"rgba(255, 255, 255, 1)",BGHover:"rgba(22, 24, 35, .06)",BGBrand:"rgba(254, 44, 85, .06)",LinePrimary:"rgba(22, 24, 35, .2)",LineSecondary:"rgba(22, 24, 35, .12)",LineInput:"rgba(22, 24, 35, .5)",LinePrimary2:"rgba(22, 24, 35, .2)",LineSecondary2:"rgba(22, 24, 35, .12)",TUXLineSecondary3:"rgba(22, 24, 35, .12)",LineDarker:"rgba(22, 24, 35, .12)",SDSecondary:"rgba(0, 0, 0, .5)",SDTertiary:"rgba(0, 0, 0, .2)",UIText1:"rgba(0, 0, 0, 1)",UIText2:"rgba(0, 0, 0, .65)",UIText3:"rgba(0, 0, 0, .48)",UITextPlaceholder:"rgba(0, 0, 0, .34)",UITextDanger:"rgba(218, 49, 35, 1)",UIShapeNeutral3:"rgba(0, 0, 0, 0.12)",Secondary2:"rgba(0, 198, 233, 1.0)",Link2:"rgba(254, 44, 85, 1.0)",Link3:"rgba(254, 44, 85, 1.0)",TextTertiary2:"rgba(22, 24, 35, 0.5)",TextReverse:"rgba(22, 24, 35, 1.0)",TextReverse2:"rgba(22, 24, 35, 0.75)",TextReverse3:"rgba(22, 24, 35, 0.5)",TextReverse4:"rgba(22, 24, 35, 0.34)",BGPrimary2:"rgba(255, 255, 255, 1.0)",BGView2:"rgba(22, 24, 35, 0.03)",BGCreation:"rgba(18, 18, 18, 1.0)",BGInverse3:"rgba(37, 37, 37, 0.6)",BGReverse:"rgba(255, 255, 255, 1.0)",BGReverse2:"rgba(255, 255, 255, 0.9)",ShadowPrimary:"rgba(0, 0, 0, 0.12)",ShadowSecondary:"rgba(0, 0, 0, 0.06)",LineSecondary3:"rgba(22, 24, 35, 0.03)",LineReverse2:"rgba(22, 24, 35, 0.12)",LineReverse3:"rgba(22, 24, 35, 0.12)",LineInverse:"rgba(22, 24, 35, 0.2)",TagGreenText:"rgba(89, 128, 108, 1.0)",TagGreenBG:"rgba(239, 245, 242, 1.0)",TagPurpleText:"rgba(128, 89, 121, 1.0)",TagPurpleBG:"rgba(246, 240, 245, 1.0)",TagBrownText:"rgba(128, 89, 89, 1.0)",TagBrownBG:"rgba(245, 240, 240, 1.0)",LiveColorStart:"rgba(255, 23, 100, 1.0)",LiveColorEnd:"rgba(237, 52, 149, 1.0)",ConstSecondary:"rgba(32, 213, 236, 1.0)",ConstSecondary2:"rgba(16, 162, 197, 1.0)",BGMessageIcon:"rgb(241, 241, 242)",BGMessageOperateHover:"rgba(196, 196, 196, .425)",TextTertiaryAlt:"rgba(22, 24, 35, 0.6)",AssistColorAzure:"rgba(43, 93, 185, 1)",UIShapeNeutral4:"rgba(0, 0, 0, 0.05)",UISheetFlat3:"rgba(255, 255, 255, 1)"},o={Positive:"rgba(11, 224, 155, 1)",Negative:"rgba(255, 76, 58, 1)",ToastDefault:"rgba(84, 84, 84, .92)",ToastNegative:"rgba(255, 76, 58, .92)",Secondary:"rgba(32, 213, 236, 1)",TUXSecondary2:"rgba(16, 162, 197, 1)",Positive2:"rgba(79, 171, 126, 1)",ConstTextInverse:"rgba(255, 255, 255, 1)",ConstTextInverse2:"rgba(255, 255, 255, .9)",ConstTextInverse3:"rgba(255, 255, 255, .75)",ConstTextInverse4:"rgba(255, 255, 255, .5)",ConstTextInverse5:"rgba(255, 255, 255, .34)",ConstTextPrimary:"rgba(22, 24, 35, 1)",ConstBGInverse:"rgba(0, 0, 0, 1)",ConstBGInverse2:"rgba(0, 0, 0, .6)",ConstBGInverse3:"rgba(37, 37, 37, .6)",ConstBGInverse4:"rgba(84, 84, 84, .5)",TUXBGCreation:"rgba(0, 0, 0, 1)",BGCreation2:"rgba(27, 27, 27, 1)",BGCreation5:"rgba(0, 0, 0, .15)",ConstBGMat:"rgba(255, 255, 255, .2)",ConstBGContainer:"rgba(255, 255, 255, .12)",ConstBGContainer2:"rgba(255, 255, 255, .08)",ConstBGContainer3:"rgba(255, 255, 255, .04)",ConstBGPlaceholderOpaque:"rgba(241, 241, 241, 1)",ConstBGInverseOpaque:"rgba(37, 37, 37, 1)",ConstBGInverse1:"rgba(56, 56, 56, .95)",ConstLineInverse:"rgba(255, 255, 255, .2)",ConstLineInverse2:"rgba(255, 255, 255, .12)",SDPrimary:"rgba(0, 0, 0, .8)",AssistColorYellow:"rgba(250, 206, 21, 1)",Primary:"rgba(255, 59, 92, 1)",Link:"rgba(255, 59, 92, 1)",Primary2:"rgba(255, 255, 255, .9)",TextPrimary:"rgba(255, 255, 255, .9)",TextSecondary:"rgba(255, 255, 255, .75)",TextTertiary:"rgba(255, 255, 255, .5)",TextQuaternary:"rgba(255, 255, 255, .34)",BGBase:"rgba(0, 0, 0, 1)",BGPrimary:"rgba(18, 18, 18, 1)",BGSecondary:"rgba(37, 37, 37, 1)",BGTertiary:"rgba(46, 46, 46, 1)",BGQuaternary:"rgba(56, 56, 56, 1)",BGQuinary:"rgba(75, 75, 75, 1)",BGSecondary2:"rgba(255, 255, 255, .08)",BGTertiary2:"rgba(255, 255, 255, .12)",BGPlaceholderDefault:"rgba(255, 255, 255, .08)",BGPlaceholderOpaque:"rgba(37, 37, 37, 1)",BGInput:"rgba(255, 255, 255, .12)",BGInput2:"rgba(255, 255, 255, .08)",BGView:"rgba(255, 255, 255, .04)",BGCreation3:"rgba(18, 18, 18, 1)",BGCreation4:"rgba(27, 27, 27, 1)",BGHover:"rgba(255, 255, 255, .9)",BGBrand:"rgba(254, 44, 85, .34)",LinePrimary:"rgba(255, 255, 255, 0)",LineSecondary:"rgba(255, 255, 255, .12)",LineInput:"rgba(255, 255, 255, .5)",LinePrimary2:"rgba(255, 255, 255, .2)",LineSecondary2:"rgba(255, 255, 255, 0)",TUXLineSecondary3:"rgba(255, 255, 255, .5)",LineDarker:"rgba(0, 0, 0, .6)",SDSecondary:"rgba(0, 0, 0, .68)",SDTertiary:"rgba(0, 0, 0, .5)",UIText1:"rgba(246, 246, 246, 1)",UIText2:"rgba(255, 255, 255, .88)",UIText3:"rgba(255, 255, 255, .6)",UITextPlaceholder:"rgba(255, 255, 255, .4)",UITextDanger:"rgba(255, 118, 96, 1)",UIShapeNeutral3:"rgba(255, 255, 255, 0.19);",Secondary2:"rgba(0, 198, 233, 1.0)",Link2:"rgba(255, 59, 92, 1.0)",Link3:"rgba(255, 59, 92, 1.0)",TextTertiary2:"rgba(255, 255, 255, 0.75)",TextReverse:"rgba(255, 255, 255, 0.9)",TextReverse2:"rgba(255, 255, 255, 0.75)",TextReverse3:"rgba(255, 255, 255, 0.5)",TextReverse4:"rgba(255, 255, 255, 0.34)",BGPrimary2:"rgba(255, 255, 255, 0.04)",BGView2:"rgba(255, 255, 255, 0.0)",BGCreation:"rgba(18, 18, 18, 1.0)",BGInverse3:"rgba(37, 37, 37, 0.6)",BGReverse:"rgba(18, 18, 18, 1.0)",BGReverse2:"rgba(18, 18, 18, 0.9)",ShadowPrimary:"rgba(255, 255, 255, 0.12)",ShadowSecondary:"rgba(0, 0, 0, 0.06)",LineSecondary3:"rgba(255, 255, 255, 0.0)",LineReverse2:"rgba(255, 255, 255, 0.12)",LineReverse3:"rgba(255, 255, 255, 0.0)",LineInverse:"rgba(255, 255, 255, 0.0)",TagGreenText:"rgba(178, 255, 217, 1.0)",TagGreenBG:"rgba(89, 128, 102, 1.0)",TagPurpleText:"rgba(255, 178, 217, 1.0)",TagPurpleBG:"rgba(128, 89, 108, 1.0)",TagBrownText:"rgba(255, 179, 179, 1.0)",TagBrownBG:"rgba(128, 89, 89, 1.0)",LiveColorStart:"rgba(255, 23, 100, 1.0)",LiveColorEnd:"rgba(237, 52, 149, 1.0)",ConstSecondary:"rgba(32, 213, 236, 1)",ConstSecondary2:"rgba(16, 162, 197, 1)",BGMessageIcon:"rgba(255, 255, 255, 0.08)",BGMessageOperateHover:"rgba(255, 255, 255, 0.12)",TextTertiaryAlt:"rgba(255, 255, 255, 0.6)",AssistColorAzure:"rgba(143, 190, 233, 1)",UIShapeNeutral4:"rgba(255, 255, 255, 0.13)",UISheetFlat3:"rgba(58, 58, 58, 1)"}},72241:(e,t,n)=>{"use strict";n.d(t,{xm:()=>m,pz:()=>d,O4:()=>p});var i=n(57432),o=n.n(i),a=n(38259),r=n(39522);const s={TikTokFont:'"IBM Plex Sans", TikTokFont, Arial, Tahoma, PingFangSC, sans-serif',TikTokDisplayFont:'"IBM Plex Sans", TikTokDisplayFont, Arial, Tahoma, PingFangSC, sans-serif'},l={P0:{fontSize:"24px",lineHeight:"32px"},P1:{fontSize:"18px",lineHeight:"25px"},P2:{fontSize:"16px",lineHeight:"22px"},P3:{fontSize:"14px",lineHeight:"20px"},P4:{fontSize:"12px",lineHeight:"17px"},H0:{fontSize:"96px",lineHeight:"115px"},H1:{fontSize:"72px",lineHeight:"86px"},H2:{fontSize:"56px",lineHeight:"68px"},H3:{fontSize:"32px",lineHeight:"38px"},H4:{fontSize:"24px",lineHeight:"28px"},H5:{fontSize:"18px",lineHeight:"22px"},H6:{fontSize:"14px",lineHeight:"17px"}};var c;!function(e){e[e.Dark=0]="Dark",e[e.Bright=1]="Bright",e[e.System=2]="System"}(c||(c={}));const d={isMobile:!1,direction:"ltr",isDark:!1,colors:r.Z,link:{color:"#0078d4",hoverColor:"#004578",activeColor:"#004578",focusColor:"#0078d4",visitedColor:"#0078d4"},selection:{background:"rgba(141, 214, 249, 0.35)"},text:{fontFamily:'"TikTokDisplayFont", PingFangSC, sans-serif',fontSize:"14px",color:"#000"},border:{radius:"3px"},boxShadowBase:"0 1.6px 3.6px 0 rgba(0,0,0,.132), 0 0.3px 0.9px 0 rgba(0,0,0,.108)",markdown:{blockquote:{color:"#4e7182",backgroundColor:"#eaf8ff"},inlineCode:{color:"hotpink",background:"rgba(70, 94, 105, 0.05)"}},zIndex:{background:0,default:1,overlay:3e3,dropdown:3100,modal:3500,popover:4e3,tooltip:4500,toast:5500},typography:{P0:{fontSize:"24px",lineHeight:"30px"},P1:{fontSize:"18px",lineHeight:"24px"},P2:{fontSize:"16px",lineHeight:"21px"},P3:{fontSize:"14px",lineHeight:"18px"},P4:{fontSize:"12px",lineHeight:"16px"},H0:{fontSize:"96px",lineHeight:"110px"},H1:{fontSize:"72px",lineHeight:"83px"},H2:{fontSize:"56px",lineHeight:"64px"},H3:{fontSize:"32px",lineHeight:"38px"},H4:{fontSize:"24px",lineHeight:"30px"},H5:{fontSize:"18px",lineHeight:"24px"},H6:{fontSize:"14px",lineHeight:"18px"}},fontFamilies:{TikTokFont:"TikTokFont, Arial, Tahoma, PingFangSC, sans-serif",TikTokDisplayFont:"TikTokDisplayFont, Arial, Tahoma, PingFangSC, sans-serif"},fontWeights:{normal:400,medium:500,semiBold:600,bold:700}};function u(e,t){var n;const i=Object.create(null);for(const[o,a]of Object.entries(e)){const e=t[o];i[o]="object"==typeof e?u(a,e):null!==(n=t[o])&&void 0!==n?n:a}return i}function p(e){const{isDark:t,isMobile:n,lang:i}=e,o={};return t&&(o.colors=r.J,o.isDark=!0),n&&(o.typography=l),"vi-VN"===i?o.fontFamilies=s:"ar"!==i&&"he-IL"!==i&&"ur"!==i||(o.direction="rtl"),o.isMobile=n,u(d,o)}var v;!function(e){e.System="system",e.Auto="auto",e.Dark="dark",e.Light="light"}(v||(v={}));const m=(0,a.$)("DarkThemeToggleContext@tiktok/theme")({value:!1,toggle:o(),currentThemeOption:"light",setCurrentThemeOption:o()})},72153:(e,t,n)=>{"use strict";n.d(t,{AB:()=>a,Ee:()=>m,PR:()=>s,RE:()=>f,WA:()=>d,WB:()=>u,hj:()=>o,jJ:()=>v,m4:()=>l,mp:()=>h,oO:()=>c,t7:()=>_,uF:()=>i,zy:()=>r});const i=60,o=1150,a={":hover, :active, :link":{textDecoration:"none"}};function r({theme:e,typography:t,color:n,fontFamily:i,fontWeight:o,isLink:a=!1}){const r=a&&n?{":hover, :active, :link, :visited":{color:e.colors[n]}}:null;let s;return t&&(s=Number(e.typography[t].fontSize.replace("px",""))<20?e.fontFamilies.TikTokFont:e.fontFamilies.TikTokDisplayFont),[{color:n&&e.colors[n],fontFamily:null!=s?s:i,fontWeight:o&&e.fontWeights[o]},t?e.typography[t]:void 0,r]}const s={textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},l=e=>({display:"-webkit-box",overflow:"hidden",textOverflow:"ellipsis",lineClamp:e,boxOrient:"vertical",WebkitLineClamp:e,WebkitBoxOrient:"vertical"}),c=({theme:e,isUiOptimise:t=!1})=>t?{backgroundColor:e.colors.ConstBGInverse4,":hover":{backgroundColor:e.colors.ConstBGInverse3}}:{},d={border:"none",background:"none",outline:"none",padding:0},u=e=>({position:"absolute",left:"0",[e]:"0",width:"100%",height:"1px",transform:"scaleY(0.5)"});var p;function v(...e){return e.map((({max:e,min:t,orientation:n,minAspectRatio:i,aspectRatio:o,maxAspectRatio:a,style:r={}})=>{if(!e&&!t&&!o)return{};let s="@media screen";return"number"==typeof t&&(s+=` and (min-width: ${t}px)`),"number"==typeof e&&(s+=` and (max-width: ${e}px)`),"string"==typeof n&&(s+=` and (orientation: ${n})`),"string"==typeof i&&(s+=` and (min-aspect-ratio: ${i})`),"string"==typeof o&&(s+=` and (aspect-ratio: ${o})`),"string"==typeof a&&(s+=` and (max-aspect-ratio: ${a})`),{[s]:r}}))}function m(...e){return e.map((({max:e,min:t,orientation:n,minAspectRatio:i,aspectRatio:o,maxAspectRatio:a,style:r={}})=>{if(!e&&!t&&!o)return{};let s="@media screen";return"number"==typeof t&&(s+=` and (min-height: ${t}px)`),"number"==typeof e&&(s+=` and (max-height: ${e}px)`),"string"==typeof n&&(s+=` and (orientation: ${n})`),"string"==typeof i&&(s+=` and (min-aspect-ratio: ${i})`),"string"==typeof o&&(s+=` and (aspect-ratio: ${o})`),"string"==typeof a&&(s+=` and (max-aspect-ratio: ${a})`),{[s]:r}}))}!function(e){e[e.Laptop=1920]="Laptop",e[e.MediumScreen=1536]="MediumScreen",e[e.HeaderWidth=1080]="HeaderWidth",e[e.NarrowLaptop=1072]="NarrowLaptop",e[e.LandscapePad=992]="LandscapePad",e[e.Pad=768]="Pad",e[e.Phone=480]="Phone"}(p||(p={}));const g={ltr:{end:"right",start:"left",marginEnd:"marginRight",marginStart:"marginLeft",paddingEnd:"paddingRight",paddingStart:"paddingLeft"},rtl:{end:"left",start:"right",marginEnd:"marginLeft",marginStart:"marginRight",paddingEnd:"paddingLeft",paddingStart:"paddingRight"}};function h({direction:e,marginEnd:t,marginStart:n,end:i,start:o,textAlign:a,paddingEnd:r,paddingStart:s}){const l=g[e],c={};return a&&(c.textAlign=_(e,a)),t&&(c[l.marginEnd]=t),n&&(c[l.marginStart]=n),o&&(c[l.start]=o),i&&(c[l.end]=i),r&&(c[l.paddingEnd]=r),s&&(c[l.paddingStart]=s),c}function _(e,t){return g[e][t]}function f({theme:e,hover:t=e.colors.BGView,active:n=e.colors.BGInput}){return{transition:"background ease-in-out 200ms",":hover":{background:t},":active":{background:n}}}},97397:(e,t,n)=>{"use strict";n.d(t,{y:()=>h});var i=n(58632),o=n(24643),a=n(40099),r=n(45446),s=n(81322),l=n(62186);const c="rgb(208, 209, 211)",d=({theme:e,buttonTheme:t})=>{switch(t){case"default":return{borderWidth:"1px",borderStyle:"solid",borderRadius:"4px",color:e.colors.TextPrimary,borderColor:e.colors.LineSecondary2,backgroundColor:e.colors.BGSecondary2,":hover":{borderColor:c,backgroundColor:e.colors.BGCreation3},":active":{borderColor:c,backgroundColor:e.colors.BGMessageIcon},":disabled":{borderColor:"rgb(227, 227, 229)",backgroundColor:e.colors.BGSecondary2,color:e.colors.TextQuaternary}};case"line":return{borderWidth:"1px",borderStyle:"solid",borderRadius:"4px",color:e.colors.Primary,borderColor:e.colors.Primary,backgroundColor:e.colors.BGSecondary2,":hover":{backgroundColor:"rgba(254, 44, 85, 0.06)"},":active":{backgroundColor:"rgba(254, 44, 85, 0.16)"},":disabled":{borderColor:e.colors.LineSecondary2,backgroundColor:e.colors.BGSecondary2,color:e.colors.TextQuaternary,pointerEvents:"none"}};case"primary":return{borderRadius:"4px",border:"none",color:e.colors.ConstTextInverse,backgroundColor:e.colors.Primary,":hover":{background:"linear-gradient(0deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.06)), #FE2C55"},":active":{background:"linear-gradient(0deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.12)), #FE2C55"},":disabled":{border:"none",color:e.colors.TextQuaternary,backgroundColor:e.colors.BGInput2,pointerEvents:"none"}};case"round":return{borderRadius:"52px",border:"none",color:e.colors.ConstTextInverse,backgroundColor:e.colors.ToastDefault,":hover":{},":active":{},":disabled":{}};default:return{":hover":{},":active":{},":disabled":{}}}},u=({theme:e,buttonTheme:t})=>{const n=t=>({":focus-visible":{outline:`2px solid ${null!=t?t:e.colors.Negative}`,outlineOffset:"1px"}});switch(t){case"default":case"round":case"line":default:return n();case"primary":return n("rgba(24, 27, 105, 1.0)")}},p="TikTokFont, PingFangSC, sans-serif",v="TikTokDisplayFont, PingFangSC, sans-serif",m={largeNew:{minWidth:"120px",minHeight:"46px",fontSize:"16px",lineHeight:"22px",fontWeight:700,fontFamily:p},large:{minWidth:"168px",minHeight:"48px",fontSize:"18px",lineHeight:"25px",fontWeight:600,fontFamily:v},medium:{minWidth:"164px",minHeight:"36px",fontSize:"18px",lineHeight:"25px",fontWeight:600,fontFamily:v},small:{minWidth:"106px",minHeight:"28px",fontSize:"16px",lineHeight:"22px",fontWeight:600,fontFamily:p},tiny:{minWidth:"96px",minHeight:"28px",fontFamily:p,fontSize:"14px",lineHeight:"17px",fontWeight:600}},g=(0,l.default)("button",{shouldForwardProp:e=>(0,s.A)(e)&&"loading"!==e,target:"ehk74z00"})((({buttonTheme:e="default",size:t="large",theme:n,loading:i=!1})=>[d({theme:n,buttonTheme:e}),m[t],{display:"flex",position:"relative",alignItems:"center",justifyContent:"center",padding:"6px 8px",userSelect:"none",cursor:"pointer",boxSizing:"border-box",":focus":{outline:"none"}},Object.assign({},i?{color:"transparent",pointerEvents:"none"}:{}),u({theme:n,buttonTheme:e})]),"label:Button;"),h=(0,a.memo)((function(e){var{buttonTheme:t,size:n,type:a="button",loading:s=!1,loadingTheme:l="primary",loadingSize:c="medium",loadingFill:d,children:u,e2eTag:p}=e,v=(0,i.__rest)(e,["buttonTheme","size","type","loading","loadingTheme","loadingSize","loadingFill","children","e2eTag"]);return(0,o.jsxs)(g,Object.assign({type:a,buttonTheme:t,loading:s,size:n,"data-e2e":p},v,{children:[u,s&&(0,o.jsx)(r.h,{style:{position:"absolute",top:"50%",transform:"translateY(-50%)"},theme:l,size:c,fill:d})]}))}))},45446:(e,t,n)=>{"use strict";n.d(t,{h:()=>p});var i=n(24643),o=n(67518),a=n(40099),r=n(75431),s=n(62186);const l=(0,s.default)("div",{target:"ef2t4c20"})((({center:e})=>({display:"flex",flexDirection:"column",alignItems:e?"center":"flex-start"})),"label:DivContainer;"),c=(0,r.i7)({"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}}),d=(0,s.default)("svg",{target:"ef2t4c21"})({margin:"0 !important",fill:"none",animation:`${c} 1s linear infinite`},"label:SvgBox;"),u={small:16,medium:18,large:20},p=(0,a.memo)((function({theme:e="primary",size:t="medium",center:n=!1,style:r={},fill:s=""}){const{colors:c}=(0,o.u)(),p=(0,a.useMemo)((()=>{const{BGCreation:t,BGPrimary:n,Primary:i}=c;return s||{white:t,primary:n,transparent:i}[e]}),[c,s,e]),v="string"==typeof t?u[t]:t,m=Object.assign(Object.assign({},r),{width:v,height:v});return(0,i.jsx)(l,Object.assign({center:n,style:m},{children:(0,i.jsx)(d,Object.assign({width:v,height:v,viewBox:"0 0 18 18",xmlns:"http://www.w3.org/2000/svg"},{children:(0,i.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",fill:p,d:"M0 9C0 4.02944 4.02944 0 9 0C13.9706 0 18 4.02944 18 9C18 9.82843 17.3284 10.5 16.5 10.5C15.6716 10.5 15 9.82843 15 9C15 5.68629 12.3137 3 9 3C5.68629 3 3 5.68629 3 9C3 12.3137 5.68629 15 9 15C10.415 15 11.7119 14.512 12.7375 13.6941C13.3852 13.1775 14.329 13.2838 14.8455 13.9315C15.3621 14.5792 15.2558 15.5229 14.6081 16.0395C13.0703 17.266 11.1188 18 9 18C4.02944 18 0 13.9706 0 9Z"})}))}))}))},84827:(e,t,n)=>{"use strict";n.d(t,{R:()=>f,W:()=>w});var i=n(58632),o=n(24643),a=n(40099),r=n(18499),s=n(75431),l=n(62186);const c=36,d=(0,s.i7)({"25%":{cx:100,r:1.2*c},"50%":{cx:140,r:c},"75%":{cx:100,r:.6*c},"100%":{cx:60,r:c}}),u=(0,s.i7)({"25%":{cx:100,r:24},"50%":{cx:60,r:c},"75%":{cx:100,r:1.2*c},"100%":{cx:140,r:c}});var p;!function(e){e[e.Red=0]="Red",e[e.Green=1]="Green",e[e.Black=2]="Black"}(p||(p={}));const v={strokeWidth:0,r:c,cy:99},m={0:{fill:"#fe2c55",cx:128,animation:`${u} 1s cubic-bezier(.05, 0, 1, 1) infinite`},1:{fill:"#3af2ff",cx:60,animation:`${d} 1s cubic-bezier(.05, 0, 1, 1) infinite`},2:{fill:"#0f0f0f",cx:60,animation:`${d} 1s cubic-bezier(.05, 0, 1, 1) infinite`}},g=(0,l.default)("circle",{target:"e1ugmybf0"})((({circleType:e,isBlack:t})=>[v,m[e],t?{fill:"#000"}:null]),"label:Circle;"),h=(0,l.default)("svg",{target:"e1ugmybf1"})({display:"block"},(({center:e})=>e?{margin:"6px auto"}:null),"label:SvgContainer;"),_={default:48,small:32},f=(0,a.memo)((0,a.forwardRef)((function(e,t){var{size:n=48,center:a=!1,maskKey:r=Date.now()}=e,s=(0,i.__rest)(e,["size","center","maskKey"]);const l="string"==typeof n?_[n]:n;return(0,o.jsxs)(h,Object.assign({center:a,preserveAspectRatio:"none",viewBox:"0 0 200 200",width:l,height:l},s,{ref:t},{children:[(0,o.jsxs)("defs",{children:[(0,o.jsxs)("mask",Object.assign({id:`redhole-${r}`},{children:[(0,o.jsx)("rect",{width:"100%",height:"100%",fill:"white"}),(0,o.jsx)(g,{circleType:0,isBlack:!0})]})),(0,o.jsxs)("mask",Object.assign({id:`greenhole-${r}`},{children:[(0,o.jsx)("rect",{width:"100%",height:"100%",fill:"white"}),(0,o.jsx)(g,{circleType:1,isBlack:!0})]}))]}),(0,o.jsx)(g,{strokeWidth:2,stroke:"#3AF2FF",circleType:2}),(0,o.jsx)(g,{circleType:1,mask:`url(#redhole-${r})`}),(0,o.jsx)(g,{circleType:0,mask:`url(#greenhole-${r})`})]}))})));let y=null;function b(e){var t;return y||(y=document.createElement("div"),y.style.cssText="display: inline-block; position: fixed; left: calc(50% - 15px); top: 38%; z-index: 100",(e&&null!==(t=document.querySelector(e))&&void 0!==t?t:document.body).appendChild(y)),y}const w={show:e=>r.render((0,o.jsx)(f,{size:30}),b(e)),hide:()=>y?r.unmountComponentAtNode(b()):void 0}},11328:(e,t,n)=>{"use strict";n.d(t,{EA:()=>f,NH:()=>w,aw:()=>y,eg:()=>b,sH:()=>x});var i=n(58632),o=n(24643),a=n(75431),r=n(62186),s=n(72153);const l=(0,a.i7)({"0%":{backgroundPositionX:"200%"},"100%":{backgroundPositionX:"-150%"}}),c=(0,r.default)("div",{target:"e12rwi320"})((({theme:{colors:e}})=>({backgroundColor:e.BGPlaceholderDefault,borderRadius:"4px",backgroundImage:"linear-gradient(90deg, rgba(22, 24, 35, 0) 0%, rgba(22, 24, 35, .04) 50%, rgba(22, 24, 35, 0) 100%)",backgroundSize:"200% 100%",backgroundRepeat:"no-repeat",width:"100%",height:"100%"})),"label:DivBaseComponent;"),d=(0,r.default)("div",{target:"e12rwi321"})({width:"100%"},"label:DivComponent;"),u=(0,r.default)(c,{target:"e12rwi322"})({borderRadius:"100%",animation:`${l} cubic-bezier(0, 0, 1, 1) 1.5s infinite`},"label:StyledAvatar;"),p=(0,r.default)(c,{target:"e12rwi323"})({height:"16px",width:"40%",animation:`${l} cubic-bezier(0, 0, 1, 1) 1.5s infinite`},"label:StyledTitle;"),v=(0,r.default)(c,{target:"e12rwi324"})((({theme:e})=>[{backgroundColor:"transparent",backgroundImage:"unset"},(0,s.mp)({direction:e.direction})]),"label:StyledParagraph;"),m=(0,r.default)(c,{target:"e12rwi325"})((({shrinkLastLine:e=!0})=>({height:"12px",animation:`${l} cubic-bezier(0, 0, 1, 1) 1.5s infinite`,":last-child":{width:e?"60%":"100%",marginTop:"12px"},":not(:last-child)":{marginBottom:"8px"}})),"label:StyledParagraphLine;"),g=(0,r.default)(c,{target:"e12rwi326"})({minHeight:"100px",animation:`${l} cubic-bezier(0, 0, 1, 1) 1.5s infinite`},"label:StyledVideoCover;"),h=(0,r.default)(c,{target:"e12rwi327"})({height:"36px",width:"164px",animation:`${l} cubic-bezier(0, 0, 1, 1) 1.5s infinite`},"label:StyledButton;"),_=(0,r.default)(c,{target:"e12rwi328"})({height:"36px",width:"164px",animation:`${l} cubic-bezier(0, 0, 1, 1) 1.5s infinite`},"label:StyledTextBox;");function f(e){const{children:t,style:n,className:a}=e,r=(0,i.__rest)(e,["children","style","className"]);return(0,o.jsx)(d,Object.assign({style:n,className:a},r,{children:t}))}function y(e){const{lines:t=2,shrinkLastLine:n=!0,style:a,className:r}=e,s=(0,i.__rest)(e,["lines","shrinkLastLine","style","className"]),l=[];for(let e=0;e{"use strict";n.d(t,{F:()=>y});var i=n(24643),o=(n(57432),n(93545)),a=n(66283),r=n(75431),s=n(62186);const l=(0,r.i7)({"0%":{transform:"translateY(0%)",transformOrigin:"0 0",opacity:"1"},"100%":{transform:"translateY(-100%)",transformOrigin:"0 0",opacity:"0"}}),c=(0,r.i7)({"0%":{transform:"translateY(-100%)",transformOrigin:"0 0",opacity:"0"},"100%":{transform:"translateY(0%)",transformOrigin:"0 0",opacity:"1"}}),d=(0,a.AH)({"&-enter":{opacity:"0"},"&-enter-active":{animationName:c,animationDuration:"0.3s"},"&-leave-active":{animationName:l,animationDuration:"0.3s"}}),u=(0,a.AH)({fontFamily:"TikTokFont, PingFangSC, sans-serif",fontWeight:600,position:"fixed",top:"16px",left:"0px",color:"#fff",zIndex:3003,width:"100%",pointerEvents:"none",userSelect:"none","&-notice":{padding:"8px 0",textAlign:"center",":first-of-type":{marginTop:"-8px"}},"&-notice-content":{backgroundColor:"rgba(84, 84, 84, 0.92)",display:"inline-block",padding:"10px 8px",pointerEvents:"all",maxWidth:"100%",borderRadius:"2px"}}),p={auto:{},full:{width:"100vw",borderRadius:"0"},padding:{width:"calc(100vw - 40px)",margin:"0 auto"},half:{width:"50vw"}},v=(0,s.default)("div",{target:"e1wz89c90"})((({widthType:e="auto",isRTL:t})=>[p[e],{direction:t?"rtl":"ltr"}]),"label:DivMessageContainer;");let m,g=[],h=1;const _={prefixCls:u,transitionName:d,style:{top:void 0},getContainer:void 0,maxCount:void 0,type:"default"},f={success:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTE3Ljg0MDQgNi44NTk4NkMxOC4wMzc3IDYuNjYyMDcgMTguMzU4NyA2LjY2NDI1IDE4LjU1MzMgNi44NjQ3MUwxOS40NTc0IDcuNzk2MjlDMTkuNjQ3NSA3Ljk5MjE3IDE5LjY0NTQgOC4zMDQzMiAxOS40NTI2IDguNDk3NTlMMTAuNTU4MiAxNy40MTYzQzEwLjEwNSAxNy44NzA3IDkuMzczMzMgMTcuODU5NiA4LjkzMzY2IDE3LjM5MTZMNC44MzY4MSAxMy4wMzA2QzQuNjQ5OTEgMTIuODMxNyA0LjY1NzExIDEyLjUxOTYgNC44NTI5OSAxMi4zMjk1TDUuNzgzNzQgMTEuNDI2MUM1Ljk4NDE4IDExLjIzMTUgNi4zMDUxNCAxMS4yMzg5IDYuNDk2MzkgMTEuNDQyNUw5Ljc4MjE0IDE0Ljk0MDFMMTcuODQwNCA2Ljg1OTg2WiIgZmlsbD0iIzBCRTA5QiIvPgo8L3N2Zz4K",fail:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjYiIGhlaWdodD0iMjYiIHZpZXdCb3g9IjAgMCAyNiAyNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAwKSI+CjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNMTEuNDY4IDEzTDcuMjAwNCA4LjczMjM4QzYuOTg4ODYgOC41MjA4NSA2Ljk4ODg2IDguMTc3ODggNy4yMDA0IDcuOTY2MzVMNy45NjY0MyA3LjIwMDMyQzguMTc3OTcgNi45ODg3OCA4LjUyMDkzIDYuOTg4NzggOC43MzI0NiA3LjIwMDMyTDEzLjAwMDEgMTEuNDY3OUwxNy4yNjc3IDcuMjAwMzJDMTcuNDc5MiA2Ljk4ODc4IDE3LjgyMjIgNi45ODg3OCAxOC4wMzM3IDcuMjAwMzJMMTguNzk5OCA3Ljk2NjM1QzE5LjAxMTMgOC4xNzc4OCAxOS4wMTEzIDguNTIwODUgMTguNzk5OCA4LjczMjM4TDE0LjUzMjEgMTNMMTguNzk5OCAxNy4yNjc2QzE5LjAxMTMgMTcuNDc5MiAxOS4wMTEzIDE3LjgyMjEgMTguNzk5OCAxOC4wMzM3TDE4LjAzMzcgMTguNzk5N0MxNy44MjIyIDE5LjAxMTIgMTcuNDc5MiAxOS4wMTEyIDE3LjI2NzcgMTguNzk5N0wxMy4wMDAxIDE0LjUzMjFMOC43MzI0NiAxOC43OTk3QzguNTIwOTMgMTkuMDExMiA4LjE3Nzk3IDE5LjAxMTIgNy45NjY0MyAxOC43OTk3TDcuMjAwNCAxOC4wMzM3QzYuOTg4ODYgMTcuODIyMSA2Ljk4ODg2IDE3LjQ3OTIgNy4yMDA0IDE3LjI2NzZMMTEuNDY4IDEzWiIgZmlsbD0iI0ZGNEMzQSIvPgo8L2c+CjxkZWZzPgo8Y2xpcFBhdGggaWQ9ImNsaXAwIj4KPHJlY3Qgd2lkdGg9IjI2IiBoZWlnaHQ9IjI2IiBmaWxsPSJ3aGl0ZSIvPgo8L2NsaXBQYXRoPgo8L2RlZnM+Cjwvc3ZnPgo="},y={open:function(e){const t=void 0!==e.duration?e.duration:3,n=e.key||h++,a=new Promise((a=>{var r,s;const l={key:n,duration:t,className:e.className,content:(0,i.jsxs)(v,Object.assign({isRTL:e.isRTL,widthType:e.widthType,"data-e2e":e.e2eTag,role:"alert",style:Object.assign({display:"flex",justifyContent:"center",alignItems:"center"},null!==(r=e.style)&&void 0!==r?r:{})},{children:[e.type&&"default"!==e.type&&(0,i.jsx)("img",{src:f[e.type],style:Object.assign({width:"24px",height:"24px"},e.isRTL?{marginLeft:"8px"}:{marginRight:"8px"}),"aria-hidden":"true"}),(0,i.jsx)("span",{children:e.content})]})),onClose:()=>("function"==typeof e.onClose&&e.onClose(),a(!0))};var c;e.getContainer?o.A.newInstance(Object.assign(Object.assign({},_),{style:{position:null!==(s=e.getContainerPosition)&&void 0!==s?s:"absolute",top:void 0},getContainer:e.getContainer}),(e=>{e.notice(l),g.push(e)})):(c=e=>{e.notice(l)},m?c(m):o.A.newInstance(Object.assign({},_),(e=>{m?c(m):(m=e,c(e),g.push(e))})))})),r=()=>{m&&m.removeNotice(n)};return r.then=(e,t)=>a.then(e,t),r.promise=a,r},destroy(){m&&(m.destroy(),m=null),g.length>0&&(g.forEach((e=>e.destroy())),g=[])}}},31209:(e,t,n)=>{"use strict";n.d(t,{i:()=>d});var i=n(67134),o=n(40438),a=n(71111),r=n(40099),s=n(17995),l=n(98796);const c=(0,i.U)("internalAtomToServiceCache@webapp-vendors",(()=>new WeakMap));function d(e,t){const n=(t,...n)=>{var i;if("__SIGI_MODULE__"in e&&"init"in e){const a=(0,o.L)(),{store:r}=null!==(i=a.getInstance(e.__SIGI_MODULE__))&&void 0!==i?i:{};if(r){let i=n[0];"function"==typeof i&&(i=i(t.get(e))),r.state$.next(i)}}},i=(t,n)=>{const{equalityFn:i=Object.is}="function"==typeof n?{equalityFn:n}:null!=n?n:{};return(0,l.X)(e,{selector:t,equalityFn:i})},d=()=>{const i=(0,a.useStore)(),o=(0,r.useCallback)(((t,...o)=>{if(!("write"in e))throw new Error("not writable atom");return n(i,...o),i.set(t,...o)}),[i]),s=(0,r.useCallback)((e=>i.get(e)),[i]);return(0,r.useMemo)((()=>{const e={},n=t(s,o);for(const t of Object.keys(n))e[t]=n[t].bind(n);return e}),[s,o])},u=new WeakMap;return p=e,v={useServiceState:i,useServiceDispatchers:d,useAtomService:(e,t)=>[i(e,t),d()],getStaticApi:i=>{const o=null!=i?i:(0,s.LM)();let a=u.get(o);if(a)return a;const{get:r,set:l,sub:c}=o,d=t(r,((e,...t)=>(n(o,...t),l(e,...t))));return a=Object.assign({},d,{get:r,set:l,sub:t=>c(e,t)}),u.set(o,a),a}},c.has(p)?c.get(p):(c.set(p,v),v);var p,v}},17995:(e,t,n)=>{"use strict";n.d(t,{J7:()=>p,LM:()=>m,ZB:()=>h,sF:()=>g});var i=n(58632),o=n(24643),a=n(14285),r=n(340),s=n(94999),l=n(67134),c=n(40438),d=n(71111),u=n(1569);const p=(0,l.U)("JotaiStoreInjectionToken@webapp-vendors",(()=>new a.n("jotaiStore")));let v=class{constructor(e){this.jotaiStore=e}getJotaiStore(){return this.jotaiStore}};function m(){return(0,c.L)().getInstance({provide:p,useExisting:p})}function g(e){p.__IS_STORE_SET__||(s.l.addProvider({provide:p,useValue:e}),s.l.addProvider({useClass:v,provide:v}),p.__IS_STORE_SET__=!0)}function h(e,t){const{jotaiStore:n}=null!=t?t:{},i=null!=n?n:(0,u.S)();return g(i),()=>(0,o.jsx)(d.Provider,Object.assign({store:i},{children:e}))}v=(0,i.__decorate)([(0,i.__param)(0,(0,r.y)(p)),(0,i.__metadata)("design:paramtypes",[Object])],v)},44241:(e,t,n)=>{"use strict";n.d(t,{S:()=>o,d:()=>i});const i=Symbol("BASE_DATA_ATOM_KEY"),o=Symbol("HYDRATION_TOGGLE_PROP")},98796:(e,t,n)=>{"use strict";n.d(t,{X:()=>r});var i=n(71111),o=n(7570),a=n(32125);function r(e,t){const n=(0,i.useStore)(t),{equalityFn:r=Object.is,selector:s}=null!=t?t:{},l=null!=s?s:e=>e,c=()=>n.get(e),d=(0,o.useSyncExternalStoreWithSelector)((t=>n.sub(e,t)),c,c,l,r);return(0,a.$X)(d)?(0,a.Yx)(d):d}},32125:(e,t,n)=>{"use strict";n.d(t,{$X:()=>l,Yx:()=>c,bN:()=>s,pj:()=>a,xb:()=>r});var i=n(40099),o=n(44241);function a(e){return e[o.d]}function r(e,t){return Object.assign(Object.assign({},e),{atomState:t})}function s(e,t){if(Object.is(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(const[n,i]of e)if(!Object.is(i,t.get(n)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0}const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let i=0;i"function"==typeof(null==e?void 0:e.then),c=i.use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;throw"rejected"===e.status?e.reason:(e.status="pending",e.then((t=>{e.status="fulfilled",e.value=t}),(t=>{e.status="rejected",e.reason=t})),e)})},50296:(e,t,n)=>{"use strict";n.d(t,{L:()=>r,S:()=>a});const i=new WeakMap,o=e=>{let t=i.get(e);return t||(t=new WeakSet,i.set(e,t)),t},a=(e,t)=>{const n=o(e);for(const[i,o]of t)n.has(i)||(n.add(i),e.set(i,o))},r=(e,t,n)=>{const i=o(e);i.has(t)||(i.add(t),e.set(t,n))}},14374:(e,t,n)=>{"use strict";n.d(t,{_:()=>s});var i=n(66476),o=n(17995),a=n(50296);const r=Symbol("REHYDRATED_FROM_SSR"),s=(e,{rehydrationKey:t})=>{if(!("init"in e))throw new Error("Only primitive atom can be hydrated");{e.rehydrationKey=t;const n=e.read.bind(e),s=function(){var e,t;if(!window[i.DA]){let n={};try{n=JSON.parse(null!==(t=null===(e=document.getElementById(i.xD))||void 0===e?void 0:e.textContent)&&void 0!==t?t:"{}"),window[i.DA]=n}catch(e){console.error("error while parsing rehydration data"),window[i.DA]={}}}return window[i.DA][i.LH]}();(null==s?void 0:s[e.rehydrationKey])&&(e[r]=!0),e.read=(t,i)=>{if(s){const t=s[e.rehydrationKey];if(t){const n=e;(0,a.L)((0,o.LM)(),n,t)}}return n(t,i)}}return e}},34360:(e,t,n)=>{"use strict";n.d(t,{y:()=>c});var i=n(40438),o=n(71111),a=n(57432),r=n.n(a),s=n(1475),l=n(17995);function c(e){const t=Symbol("null"),n=(0,o.atom)(t),a=(0,o.atom)((o=>{const s=o(n);if(a.__IS_SUBSCRIBED__||(a.__IS_SUBSCRIBED__=!0,(0,l.LM)().sub(a,r())),s===t){const t=(0,i.L)().getInstance(e),{store:n}=t;return n.state}return s}),((e,t,i)=>{t(n,i)}));return a.onMount=t=>{const n=(0,i.L)().getInstance(e),{store:o}=n,a=()=>{t(o.state)},r=o.state$.pipe((0,s.i)(1)).subscribe(a);return a(),()=>r.unsubscribe()},(0,o.atom)((e=>e(a)),((t,n,o,...a)=>{(0,i.L)().getInstance(e).dispatchers[o](...a)}))}},1569:(e,t,n)=>{"use strict";n.d(t,{S:()=>r});var i=n(88874),o=n(71111),a=n(50296);const r=()=>{const e=(0,o.createStore)();return Object.assign(Object.assign({},e),{get:t=>{if(t.rehydrationKey){const n=(0,i.YI)(t.rehydrationKey);if(n&&"init"in t){const i=t;(0,a.L)(e,i,n)}}return e.get(t)}})}},34832:(e,t,n)=>{"use strict";e.exports=n.p+"8c38d0bc3eca55cfff39.css"},28658:(e,t,n)=>{"use strict";e.exports=n.p+"556f30c6486bf9513700.css"}},e=>{e.O(0,[9443,1799,8564,5956,3699,1878,1888,3824,6534,1476,4121],(()=>e(e.s=68010))),e.O()}]);