(window.__LOADABLE_LOADED_CHUNKS__=window.__LOADABLE_LOADED_CHUNKS__||[]).push([[32],{1e3:function(e,t,r){e.exports=r.p+"images/img-info-circle-75e9090a84713f04d63d5183df1a8b57.svg"},1001:function(e,t,r){e.exports=r.p+"images/img-embed-new-share-24088591e15a23ff5c4af30ed4c11d70.svg"},1002:function(e,t,r){e.exports=r.p+"images/icon_alert_white-a95bbc715988fb8b82b512b25e102b5e.svg"},1003:function(e,t,r){e.exports=r.p+"images/icon_warn_arrow-ad48af04f3daab604c13cfc85c008c19.svg"},1007:function(e,t,r){e.exports=r.p+"images/img-embed-previous-ad15e871ecc7afadf24624d1f5681da5.svg"},1008:function(e,t,r){e.exports=r.p+"images/img-embed-rec-card-play-f39dbfc3de0894bfeb5194a8c89c24ad.svg"},1010:function(e,t,r){e.exports=r.p+"images/img-embed-controller-full-screen-exit-7df04411ccf4608eec2e208cac1b749c.svg"},1011:function(e,t,r){e.exports=r.p+"images/img-embed-controller-full-screen-v3-a80f39a093d837a250394e07b8fe8ede.svg"},1012:function(e,t,r){e.exports=r.p+"images/img-embed-controller-pause-single-29ff80f3914717284d661c77a996d09b.svg"},1013:function(e,t,r){e.exports=r.p+"images/img-embed-music-white-3179ccdc4096b2f4cd5c3cd0e865f054.svg"},1014:function(e,t,r){"use strict";(function(e){var n=r(10),a=r.n(n),i=r(0),o=r(964),s=r(1);function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function c(e){for(var t=1;t{const r=Object(i.forwardRef)((r,n)=>{const a=Object(i.useRef)();return e&&(e.__player=a),Object(s.jsx)(t,c(c({},r),{},{ref:e=>{e&&(a.current=e,Object(o.a)(n)(e))},"data-e2e":"hoc-with-debug-ref-Component"}))});return r.displayName="WithDebugRef",r}}).call(this,r(58))},216:function(e,t,r){"use strict";function n(){const e=navigator.userAgent;return/android/i.test(e)?"android":/iPhone|iPad|iPod|iOS/i.test(e)?"ios":/\(Macintosh; Intel /.test(e)?"mac":/Win\d{2}|Windows/.test(e)?"windows":"unknown"}function a(){return"android"===n()}r.d(t,"a",(function(){return a})),r.d(t,"b",(function(){return i}));const i=(e=!0)=>{try{return window.self!==window.top}catch(t){return e}}},780:function(e,t,r){"use strict";r.r(t);r(9);var n=r(2),a=r(0),i=r.n(a),o=r(958),s=r(14),l=r(57),c=r(132),d=r(636);var u={creativeCenterConfig:{hiddenCommerceBannerContent:!0,hiddenLayerBannerContent:!0,hiddenVideoControllerBannerContent:!0,hiddenVideoProgressContent:!0,hiddenTTLogoContent:!0,hiddenProfileBannerContent:!0,hiddenRecommendVideosBannerContent:!0,hiddenVideoInitCover:!0,videoStyleConfig:{ratio:9/16,width:"100%",minWidth:220,border:"none"},videoPlayConfig:{noneAutoPlay:!0}}},p=r(10),b=r.n(p),m=(r(4),r(5),r(105)),f=r(147),g=r(110),h=r(13),j=r(988),O=r(962),v=r(82),y=r(993),x=r.n(y),w=r(994),P=r.n(w),E=r(995),k=r.n(E);r(6),r(15),r(67);let S;!function(e){e.CHALLENGE="challenge",e.TEXT="text",e.DUET="duet",e.USER="user",e.Question="question"}(S||(S={}));const C=0,I=1;let T;!function(e){e[e.Question=5]="Question",e[e.Answer=7]="Answer"}(T||(T={}));var R=r(171),_=r(963),A=r(975),L=r(969),D=r(970),V=r.n(D),N=r(996),W=r.n(N),H=r(1);function F(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function M(e){for(var t=1;t{const[j,y]=Object(a.useState)(!1),x=Object(a.useRef)(null),{state:w}=Object(n.useConnect)(),P=w.theme.globalParams,E=e=>Boolean(e)&&e.clientHeight{if(x.current){if(y(e=>e||E(x.current)),window.ResizeObserver){const e=new ResizeObserver(e=>{const t=e[0];y(e=>e||E(t.target))});return e.observe(x.current),()=>{e.disconnect()}}{const e=e=>{y(t=>t||E(e.target))};return x.current.addEventListener("resize",e),()=>{var t;null===(t=x.current)||void 0===t||t.removeEventListener("resize",e)}}}},[]),j?Object(H.jsx)(q,{isInPlayer:f,isSmall:g,className:e,css:t,text:i,maxLine:"2",ellipsis:" ..."+h.b.t("embed_profile_card_see_more"),trimRight:!0,basedOn:"letters","data-e2e":"video-v2-ClampedText-StyledResponsiveEllipsis"}):Object(H.jsx)($,{className:e,css:t,ref:x,"data-e2e":"video-v2-ClampedText-Text",children:r.map(({type:e,id:t,text:r,name:n},a)=>{if(S.CHALLENGE===e&&n)return Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:o,redirectLink:Object(R.d)({tagName:n,globalQueryParams:P(B.TAG),optionalParams:l}),target:v.b.HASHTAG_WRAPPER,teaTarget:B.TAG,gd_label:s.m.Hashtag,id:t||"",pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.TAG}))},jumpStartHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.TAG})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},shouldStopInteractEventPropagation:!0,useSmartWrapper:p,fallbackURLParams:{tagName:n,type:s.c.Video},"data-e2e":"video-v2-ClampedText-SmartWrapperExtension",children:Object(H.jsx)(Y,{isInPlayer:f,"data-e2e":"video-v2-ClampedText-CardTag",children:r})},`${n}-${a}`);if(S.DUET===e&&n&&t){const e=r.replace(/^@/,"");return Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:o,redirectLink:Object(R.f)({uniqueId:e,videoId:m,globalQueryParams:P(B.RELATED_VIDEO),optionalParams:l}),target:v.b.VIDEO_WRAPPER,teaTarget:B.RELATED_VIDEO,gd_label:s.m.Video,id:t||"",pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.RELATED_VIDEO}))},jumpStartHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.RELATED_VIDEO})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},shouldStopInteractEventPropagation:!0,useSmartWrapper:p,"data-e2e":"video-v2-ClampedText-SmartWrapperExtension",children:Object(H.jsx)(K,{"data-e2e":"video-v2-ClampedText-CardDuet",children:e})},t)}return S.USER===e&&t&&n?Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:o,redirectLink:Object(R.e)({uniqueId:b,globalQueryParams:P(B.NAME),optionalParams:l}),target:v.b.USER_WRAPPER,teaTarget:B.NAME,gd_label:s.m.User,id:t||"",pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.NAME}))},jumpStartHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.NAME})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},shouldStopInteractEventPropagation:!0,useSmartWrapper:p,"data-e2e":"video-v2-ClampedText-SmartWrapperExtension",children:Object(H.jsx)(Y,{isInPlayer:f,"data-e2e":"video-v2-ClampedText-CardTag",children:r})},n):r?Object(H.jsx)(Q,{refer:s.j.Video,referrer_url:o,redirectLink:Object(R.f)({uniqueId:b,videoId:m,globalQueryParams:P(B.BLANK),optionalParams:l}),target:v.b.VIDEO_WRAPPER,teaTarget:B.BLANK,gd_label:s.m.Video,id:m,useSmartWrapper:p,pid:s.h.WebOther,linkOnClickHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.BLANK}))},jumpStartHandler:()=>{c.a.event(z.TAP,M(M({},d),{},{target:B.BLANK})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},jumpHook:e=>Object(_.a)(e,!0),shouldStopInteractEventPropagation:!0,isInPlayer:f,"data-e2e":"video-v2-ClampedText-ClampedTextSmartWrapperExtension",children:r},a):null})})});const q=Object(n.styled)(U,{target:"e17sly924"})(({isInPlayer:e,isSmall:t})=>e?t?"width: 254px;":"width: 346px;":"width: 100%",";"),$=Object(n.styled)("div",{target:"e17sly923"})({name:"1we4jwl",styles:"width:100%;max-height:41px;overflow:hidden"}),Y=Object(n.styled)("div",{target:"e17sly922"})("display:inline-block;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);",e=>e.isInPlayer&&"color: #fff;"," font-size:1.5rem;&:hover{text-decoration:underline ",e=>e.isInPlayer&&"#fff",";}"),Q=Object(n.styled)(O.a,{target:"e17sly921"})("font-size:1.5rem;",e=>e.isInPlayer&&"color: #fff !important;"," text-decoration:none!important;&:hover{",e=>e.isInPlayer&&"\n text-decoration: underline !important;\n color: #fff !important;\n ",";}"),K=Object(n.styled)("div",{target:"e17sly920"})("display:inline-block;font-size:1.5rem;line-height:1.9rem;background:rgb(255 255 255 / 12%);border-radius:3px;position:relative;padding:2px 6px 2px 24px;&::before{content:'';display:block;width:11px;height:12px;background:center no-repeat;background-size:contain;position:absolute;left:9px;top:5px;background-image:url(",W.a,");}");var X=r(976);let Z;function J(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function ee(e){for(var t=1;t{const{videoData:{itemInfos:t,authorInfos:r,musicInfos:a,textExtra:i=[]},logParams:o={},playerState:d,responsiveType:u,referrer:p,isMobile:b,isStrategyAvailable:m,jumpFailHandler:f}=e,{id:y,text:x}=t,{state:w}=Object(n.useConnect)(),P=w.theme.globalParams,E=h.b.t("embed_iterations_watch_more_header_scroll_bar"),T=h.b.t("embed_banner_button_2"),{uniqueId:L,verified:D,userId:V,stateControlledMedia:N}=r,{musicId:W,musicName:F,authorName:M}=a,z=function(e="",t=[]){if(!t||0===t.length)return[{type:S.TEXT,text:e}];const r=[];return t.sort((e,t)=>e.Start-t.Start),t.forEach(({Start:n,End:a,AwemeId:i,UserId:o,HashtagName:s,HashtagId:l,Type:c,UserUniqueId:d,SecUid:u},p)=>{const b=0===p?0:t[p-1].End,m=n;let f=e.slice(n,a),g=e.slice(b,m);const h=c===C?"@":c===I?"#":"",j=f.indexOf(h);if(h&&f.indexOf(h)>0){const t=n+j;g=e.slice(b,t),f=e.slice(t,a)}r.push({type:S.TEXT,text:g}),c===C&&(i||o)?i?r.push({type:S.DUET,id:i,name:f,text:f}):r.push({type:S.USER,id:o,name:null!=d?d:"",text:f,SecUid:u}):c===I&&s?r.push({type:S.CHALLENGE,id:l,name:s,text:f}):r.push({type:S.TEXT,text:f})}),r.push({type:S.TEXT,text:e.substr(t[t.length-1].End)}),r}(x,i),B=ee({page_name:l.k.PAGE,enter_from:l.k.PAGE,video_id:y},o),U={referer_video_id:y};ie||d!==re&&d!==te||(ie=!0);const q=Object(X.a)(t),$=b&&m,Y=Object(H.jsxs)(de,{"data-e2e":"video-v2-Card-LeftWrapper",children:[Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:p,redirectLink:Object(R.e)({uniqueId:L,globalQueryParams:P(ne.NAME),optionalParams:U}),target:v.b.USER_WRAPPER,teaTarget:ne.NAME,gd_label:s.m.User,id:V,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.NAME}))},jumpStartHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.NAME})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{f()},shouldStopInteractEventPropagation:!0,useSmartWrapper:$,"data-e2e":"video-v2-Card-SmartWrapperExtension",children:Object(H.jsx)(ue,{"data-e2e":"video-v2-Card-CardUser",children:Object(H.jsxs)(pe,{"data-e2e":"video-v2-Card-CardUserSpan",children:["@"+L,D?Object(H.jsx)(j.a,{css:oe,width:14,height:14,"data-e2e":"video-v2-Card-VerifiedBadgeColor"}):null]})})}),N&&Object(H.jsx)("div",{style:{marginTop:"9px"},"data-e2e":"video-v2-Card-div",children:Object(H.jsx)(A.a,{scmUrl:N.Url,scmText:N.Text,"data-e2e":"video-v2-Card-ScmLabel"})}),Object(H.jsx)(G,{css:fe,itemText:z,text:x,referrer:p,queryParams:U,teaParams:B,jumpFailHandler:f,useSmartWrapper:$,uniqueId:L,videoId:y,"data-e2e":"video-v2-Card-ClampedText"}),Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:p,redirectLink:Object(R.c)({musicId:W,musicName:F,globalQueryParams:P(ne.SONG_NAME)}),target:v.b.MUSIC_WRAPPER,teaTarget:ne.SONG_NAME,gd_label:s.m.Music,id:W,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.SONG_NAME}))},jumpStartHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.SONG_NAME})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{f()},shouldStopInteractEventPropagation:!0,useSmartWrapper:$,fallbackURLParams:{musicName:F,musicId:W,type:s.c.Video},"data-e2e":"video-v2-Card-SmartWrapperExtension",children:Object(H.jsxs)(be,{css:fe,"data-e2e":"video-v2-Card-CardMusic",children:[Object(H.jsx)(me,{style:{backgroundImage:`url(${k.a})`},"data-e2e":"video-v2-Card-IconMusic"}),Object(g.q)(`${F} - ${M}`)]})}),q&&Object(H.jsx)(ye,{"data-e2e":"video-v2-Card-CardBCBOLabel",children:q})]});return Object(H.jsxs)(le,{"data-testid":"card-component","data-e2e":"video-v2-Card-CardContainer",children:[Object(H.jsx)(ge,{hasPaused:ie,"data-testid":"card-banner","data-e2e":"video-v2-Card-CardBanner",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:p,redirectLink:Object(R.b)({globalQueryParams:P(ne.DISCOVER_BTN)}),target:v.b.FOR_YOU_WRAPPER,gd_label:s.m.ForYou,id:"",useSmartWrapper:$,pid:s.h.WebOther,teaTarget:ne.DISCOVER_BTN,linkOnClickHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.DISCOVER_BTN}))},jumpStartHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.DISCOVER_BTN})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{f()},jumpHook:e=>Object(_.a)(e,!0),"data-e2e":"video-v2-Card-SmartWrapperExtension",children:Object(H.jsxs)(H.Fragment,{children:[Object(H.jsx)(je,{hasPaused:ie,"data-e2e":"video-v2-Card-CardBannerTitle",children:u===s.d.PC_BIG?Object(H.jsx)("span",{"data-e2e":"video-v2-Card-span",children:E}):Object(H.jsxs)(ve,{"data-e2e":"video-v2-Card-Marquee",children:[Object(H.jsx)("span",{className:"real","data-e2e":"video-v2-Card-span",children:E}),Object(H.jsxs)("div",{className:"floating","data-e2e":"video-v2-Card-div",children:[Object(H.jsx)("span",{"data-e2e":"video-v2-Card-span",children:E}),Object(H.jsx)("span",{"data-e2e":"video-v2-Card-span-21",children:E})]})]})}),Object(H.jsx)(Oe,{style:{borderRadius:999},hasPaused:ie,type:"button","data-e2e":"video-v2-Card-CardBannerButton",children:T})]})})}),Object(H.jsx)(ce,{"data-e2e":"video-v2-Card-CardInfo",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:p,redirectLink:Object(R.f)({uniqueId:L,videoId:y,globalQueryParams:P(ne.BLANK),optionalParams:U}),target:v.b.VIDEO_WRAPPER,teaTarget:ne.BLANK,gd_label:s.m.Video,id:y,useSmartWrapper:$,pid:s.h.WebOther,linkOnClickHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.BLANK}))},jumpStartHandler:()=>{c.a.event(ae.TAP,ee(ee({},B),{},{target:ne.BLANK})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{f()},jumpHook:e=>Object(_.a)(e,!0),"data-e2e":"video-v2-Card-SmartWrapperExtension",children:Y})})]})});const le=Object(n.styled)("div",{target:"evf3f5612"})({name:"1hcx8jb",styles:"padding:0"}),ce=Object(n.styled)("div",{target:"evf3f5611"})({name:"xgbqrj",styles:"display:flex;flex-direction:row;align-items:flex-end;margin-bottom:0;a{color:#161823;text-decoration:none!important;}"}),de=Object(n.styled)("div",{target:"evf3f5610"})({name:"1r2yhgy",styles:"display:flex;flex-flow:column nowrap;justify-content:flex-start;align-items:flex-start;flex:1;padding:0 12px 14px;cursor:pointer;width:323px;&:hover{background:#f8f8f8;text-decoration:none!important;}"}),ue=Object(n.styled)("div",{target:"evf3f569"})({name:"ymqa2g",styles:"position:relative;padding-top:12px;display:block;font-size:1.7rem;line-height:2rem;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold)"}),pe=Object(n.styled)("span",{target:"evf3f568"})({name:"1e5yu7e",styles:"display:flex;justify-content:flex-start;align-items:center;&:hover{text-decoration:underline;}"}),be=Object(n.styled)("div",{target:"evf3f567"})({name:"59hurh",styles:"&&:hover{text-decoration:underline;}"}),me=Object(n.styled)("div",{target:"evf3f566"})({name:"1mvax6y",styles:"display:inline-block;vertical-align:middle;margin-right:4px;width:20px;height:20px;background-size:contain;background-position:center;background-repeat:no-repeat"}),fe={name:"hix8e6",styles:"font-family:var(--tux-fontFamilyParagraph);display:block;font-size:1.5rem;line-height:1.8rem;margin-top:8px;font-weight:400;word-break:keep-all;white-space:pre-wrap;margin-bottom:0;color:black!important;div{display:inline-block;}"},ge=Object(n.styled)("div",{target:"evf3f565"})(e=>e.hasPaused&&"background-color: #fe2c55;",">a,>div>div{text-decoration:none;line-height:4.4rem;padding:0 12px;display:flex;flex-flow:row nowrap;justify-content:space-between;align-items:center;position:relative;",e=>`\n &::after {\n display: block;\n content: '';\n width: calc(100% - 24px);\n height: 1px;\n background-color: ${e.hasPaused?"rgba(22, 24, 35, 0.2);":"rgb(22 24 35 / 12%);"}\n\n position: absolute;\n bottom: 0;\n left: 12px;\n }\n `,";}"),he=Object(n.keyframes)(Z||(Z=(e=>e)` 0% { left: 0; } 100% { left: -100%; } `)),je=Object(n.styled)("div",{target:"evf3f564"})("flex:auto;color:#161823;font-size:1.6rem;position:relative;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);white-space:nowrap;overflow:hidden;",e=>e.hasPaused&&"color: #fff;"," &&:hover span{text-decoration:underline;}html[dir='rtl'] &{direction:rtl;}&::after{display:block;content:'';width:100%;height:100%;position:absolute;top:0;left:0;",e=>e.hasPaused?" background: linear-gradient(\n to left,\n #fe2c55,\n rgba(254, 44, 85, 0) 73px,\n rgba(254, 44, 85, 0)\n );":" background: linear-gradient(\n to left,\n #fff,\n rgba(255, 255, 255, 0) 73px,\n rgba(255, 255, 255, 0)\n );",";}html[dir='rtl'] &::after{",e=>e.hasPaused?"\n background: linear-gradient(\n to right,\n #fe2c55,\n rgb(254 44 85 / 0%) 73px,\n rgb(254 44 85 / 0%)\n ) !important;\n ":"\n background: linear-gradient(\n to right,\n #fff,\n rgb(255 255 255 / 0%) 73px,\n rgb(255 255 255 / 0%)\n ) !important;",";}"),Oe=Object(n.styled)("button",{target:"evf3f563"})("border-radius:999px;flex:0 0 126px;display:block;height:28px;line-height:2.8rem;font-size:1.6rem;text-align:center;color:#fff;background-color:#fe2c55;border:1px solid #fe2c55;white-space:nowrap;padding:0 4px;outline:none;cursor:pointer;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);&&:visited{background:linear-gradient(0deg, rgb(0 0 0 / 12%), rgb(0 0 0 / 12%)),#fe2c55;}&&:hover,&&:active{background:linear-gradient(0deg, rgb(0 0 0 / 6%), rgb(0 0 0 / 6%)),#fe2c55;}",e=>e.hasPaused&&"border-color: #fff;",";"),ve=(Object(n.styled)("span",{target:"evf3f562"})("width:20px;height:20px;background-size:contain;background-position:center;background-repeat:no-repeat;flex:0 0 20px;margin-right:6px;",e=>e.hasPaused?`background-image: url(${x.a});`:`background-image: url(${P.a});`," ",e=>e.hasPaused&&"border-color: #fff;",";"),Object(n.styled)("div",{target:"evf3f561"})("position:relative;display:inline-block;.real{opacity:0;margin-right:30px;}.floating{position:absolute;animation:",he," 5s linear infinite;top:0;left:0;>span{margin-right:30px;}}")),ye=Object(n.styled)("div",{target:"evf3f560"})({name:"wn4uoc",styles:"padding:3px 6px;border-radius:4px;background:rgb(22 24 35 / 6%);margin-top:8px;font-family:var(--tux-fontFamilyParagraph);font-size:var(--tux-fontSizeP5);font-weight:var(--tux-fontWeightRegular);color:var(--tux-colorTextSecondary)"});r(977),r(7);var xe=r(3),we=r(125),Pe=r(998),Ee=r.n(Pe),ke=r(978),Se=r.n(ke),Ce=r(999),Ie=r.n(Ce),Te=r(973),Re=r.n(Te),_e=r(979),Ae=r.n(_e),Le=r(980),De=r.n(Le),Ve=r(968),Ne=r.n(Ve),We=r(1e3),He=r.n(We),Fe=r(1001),Me=r.n(Fe);async function ze(e,t,r){if(!t)throw new Error(`mediaElement from Component ${e} is undefined`);try{return await t.play(),void(document.pictureInPictureElement&&document.pictureInPictureElement.play())}catch(n){r&&r(n),console.error(`${t.tagName||"media"} from Component ${e} play error:`,n.message)}}var Be=r(17),Ue=r.n(Be),Ge=r(18);const qe=({show:e=!0,isSmall:t=!1,style:r})=>Object(H.jsx)(Ye,{"data-e2e":"common-Loading-LoadingContainer",children:e?Object(H.jsx)(Ge.g,{center:!0,size:t?"small":"large",deprecatedStyle:r,"data-testid":"loading-icon","data-e2e":"common-Loading-TUXLoading"}):null});qe.propTypes={show:Ue.a.bool,isSmall:Ue.a.bool},qe.defaultProps={show:!0,isSmall:!1};var $e=qe;const Ye=Object(n.styled)("div",{target:"epfctpq0"})("");var Qe={getEmbedRecommendList:async({aid:e=1988,count:t=24,secUid:r=""})=>{const a=Object(g.l)(),{statusCode:i,items:o}=await(await Object(n.fetch)(`/api/recommend/embed_videos/?aid=${e}&count=${t}&secUid=${r}&lang=${a.lang||"en"}`)).json();return{statusCode:i,list:o||[]}},getEmbedRecommendListFromReflow:async({aid:e=1284,appId:t=1233,count:r=24,language:a="en",itemID:i,codeId:o=800200304,appName:s="tiktok_web",fromPage:l="video_embed",devicePlatform:c="wap",siteId:d=5002003,channel:u="tiktok_web",region:p="unknown",referer:b=""})=>{const{statusCode:m,itemList:f}=await(await Object(n.fetch)(`/api/recommend/item_list/?aid=${e}&app_id=${t}&count=${r}&language=${a}&itemID=${i}&channel=${u}&app_name=${s}&from_page=${l}&device_platform=${c}&code_id=${o}&site_id=${d}®ion=${p}&referer=${b}`)).json();return{statusCode:m,list:f||[]}}},Ke=r(1002),Xe=r.n(Ke),Ze=r(1003),Je=r.n(Ze);var et=({text:e="",url:t,mode:r="",lang:n="",target:i="",scene:o="",id:s=""})=>{Object(a.useEffect)(()=>{c.a.event(l.j.WARN_INFO_SHOW,{page_name:l.k.PAGE,enter_from:o,videoId:s,target:i})},[o,s,i]);const d=Object(xe.d)(n),u=()=>{t&&(c.a.event(l.j.WARN_INFO_CLICK,{page_name:l.k.PAGE,enter_from:o,videoId:s,target:i}),window.open(t,"_blank"))},p="ar"!==n?0:180;if("pc"===r){const r="ar"!==n?Xe.a:Je.a,a="ar"!==n?Je.a:Xe.a;return Object(H.jsx)(tt,{className:"warn-info-pc",title:e,onClick:u,style:{direction:d?"rtl":"ltr",cursor:t?"pointer":"initial"},"data-testid":"warn-info","data-e2e":"common-WarnInfo-Container",children:Object(H.jsxs)(rt,{"data-e2e":"common-WarnInfo-WarnInfoPCContainer",children:[Object(H.jsx)("span",{className:"warn-info-pc-left",style:{backgroundImage:`url(${r})`,transform:`rotate(${p}deg)`},"data-e2e":"common-WarnInfo-span"}),Object(H.jsx)(nt,{style:{textAlign:"ar"!==n?"left":"right"},"data-e2e":"common-WarnInfo-PCContent",children:e}),t?Object(H.jsx)("span",{className:"warn-info-pc-right",style:{backgroundImage:`url(${a})`},"data-e2e":"common-WarnInfo-span"}):null]})})}return Object(H.jsxs)(tt,{className:"warn-info-h5",title:e,onClick:u,style:{direction:d?"rtl":"ltr"},"data-testid":"warn-info","data-e2e":"common-WarnInfo-Container",children:[Object(H.jsx)("span",{className:"warn-info-h5-icon",style:{backgroundImage:`url(${Xe.a})`},"data-e2e":"common-WarnInfo-span"}),Object(H.jsx)("span",{className:"warn-info-h5-content",style:{textAlign:"ar"!==n?"left":"right"},"data-e2e":"common-WarnInfo-span-7",children:e}),t?Object(H.jsx)("span",{className:"warn-info-h5-icon",style:{backgroundImage:`url(${Je.a})`,transform:`rotate(${p}deg)`},"data-e2e":"common-WarnInfo-span-8"}):null]})};const tt=Object(n.styled)("div",{target:"e14nj5ps2"})({name:"787nld",styles:"font-family:var(--tux-fontFamilyParagraph);font-weight:400;color:#fff;background:rgb(37 37 37 / 60%);padding:16px 12px;text-align:center;&container{display:inline-block;position:relative;line-height:1.7rem;}&left{display:inline-block;position:absolute;left:0;top:0;width:16px;height:16px;background-size:16px;background-repeat:no-repeat;margin-right:4px;}&content{font-size:1.3rem;word-break:break-all;padding:0 20px;display:inline-block;text-align:left;vertical-align:top;}&right{position:absolute;right:0;top:0;width:16px;height:16px;background-size:16px;background-repeat:no-repeat;}.warn-info-h5{cursor:pointer;font-family:var(--tux-fontFamilyParagraph);display:flex;color:#fff;background:rgb(37 37 37 / 60%);padding:10px 12px;&-icon{width:16px;height:16px;background-size:16px;}&-content{font-size:1.3rem;padding:0 4px;line-height:1.7rem;word-break:break-all;flex:1;}}"}),rt=Object(n.styled)("div",{target:"e14nj5ps1"})({name:"1vll03e",styles:"display:inline-block;position:relative;line-height:1.7rem;.warn-info-pc-left{display:inline-block;position:absolute;left:0;top:0;width:16px;height:16px;background-size:16px;background-repeat:no-repeat;margin-right:4px;}"}),nt=Object(n.styled)("span",{target:"e14nj5ps0"})({name:"1wxc6ji",styles:"font-size:1.3rem;word-break:break-all;padding:0 20px;display:inline-block;text-align:left;vertical-align:top"});var at=r(1004),it=r.n(at),ot=r(1007),st=r.n(ot),lt=(r(32),r(981)),ct=r.n(lt),dt=r(1008),ut=r.n(dt),pt=r(40),bt=r(41);function mt(e){return a.createElement("svg",Object(pt.a)({fill:"currentColor"},e,{viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",className:"flip-rtl "+(e.className?e.className:"")}),a.createElement("path",{d:"m19.26 24 13.66-13.67a1 1 0 0 0 0-1.41l-1.84-1.84a1 1 0 0 0-1.41 0L13.46 23.3a1 1 0 0 0 0 1.42l16.2 16.21a1 1 0 0 0 1.42 0l1.84-1.84a1 1 0 0 0 0-1.41L19.26 24Z"}))}var ft=Object(bt.a)(mt);function gt(e){return a.createElement("svg",Object(pt.a)({fill:"currentColor"},e,{viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",className:"flip-rtl "+(e.className?e.className:"")}),a.createElement("path",{d:"M28.74 24 15.08 10.33a1 1 0 0 1 0-1.41l1.84-1.84a1 1 0 0 1 1.41 0L34.54 23.3a1 1 0 0 1 0 1.42l-16.2 16.21a1 1 0 0 1-1.42 0l-1.84-1.84a1 1 0 0 1 0-1.41L28.74 24Z"}))}var ht=Object(bt.a)(gt);const jt=({description:e,authorUniqueId:t,avatarThumbUrl:r,playCount:n,playedFiftyPercent:a,isRTL:i})=>Object(H.jsxs)(yt,{"data-e2e":"embed-swiper-SwiperInfo-DivSwiperInfo",children:[Object(H.jsx)(xt,{"data-e2e":"embed-swiper-SwiperInfo-DescriptionOverlay"}),Object(H.jsxs)(wt,{isActive:Boolean(a),isRTL:i,"data-e2e":"embed-swiper-SwiperInfo-SwiperInfoWrapper",children:[Object(H.jsxs)(Pt,{"data-e2e":"embed-swiper-SwiperInfo-SwiperInfoText",children:[Object(H.jsx)(kt,{"data-e2e":"embed-swiper-SwiperInfo-DescContainer",children:Object(H.jsx)(St,{maxLine:"2",text:e,ellipsis:"...","data-e2e":"embed-swiper-SwiperInfo-StyledLinesEllipsis"})}),Object(H.jsxs)(Ct,{"data-e2e":"embed-swiper-SwiperInfo-VideoDetailRow",children:[Object(H.jsxs)(_t,{"data-e2e":"embed-swiper-SwiperInfo-UserDetailWrapper",children:[Object(H.jsx)(At,{src:r,"data-e2e":"embed-swiper-SwiperInfo-Avatar"}),Object(H.jsx)(Rt,{fontWeight:"600",maxWidth:"100px","data-e2e":"embed-swiper-SwiperInfo-VideoDetailText",children:t})]}),Object(H.jsxs)(It,{"data-e2e":"embed-swiper-SwiperInfo-PlayCountWrapper",children:[Object(H.jsx)(Tt,{isRTL:null!=i&&i,"data-e2e":"embed-swiper-SwiperInfo-PlayCountIcon"}),Object(H.jsx)(Rt,{fontWeight:"600","data-e2e":"embed-swiper-SwiperInfo-VideoDetailText",children:Object(g.b)(n)})]})]})]}),Object(H.jsxs)(Lt,{"data-e2e":"embed-swiper-SwiperInfo-CTAWrapper",children:[Object(H.jsx)(Rt,{fontWeight:"600","data-e2e":"embed-swiper-SwiperInfo-VideoDetailText",children:h.b.t("Click to see full video")}),i?Object(H.jsx)(mt,{color:"#FFFFFF","data-e2e":"embed-swiper-SwiperInfo-IconChevronLeftLTR"}):Object(H.jsx)(gt,{color:"#FFFFFF","data-e2e":"embed-swiper-SwiperInfo-IconChevronRightLTR"})]})]})]}),Ot=(e,t)=>{const{description:r,authorUniqueId:n,avatarThumbUrl:a,playCount:i,playedFiftyPercent:o}=e;return r===t.description&&n===t.authorUniqueId&&a===t.avatarThumbUrl&&i===t.playCount&&o===t.playedFiftyPercent};var vt=i.a.memo(jt,Ot);const yt=Object(n.styled)("div",{target:"egxfm5d12"})({name:"mjzgrq",styles:"width:100%;height:100%;overflow:hidden;position:relative"}),xt=Object(n.styled)("div",{target:"egxfm5d11"})({name:"1vm7gir",styles:"display:block;content:'';position:absolute;bottom:0;width:100%;height:100px;background:linear-gradient(180deg, rgb(0 0 0 / 0%) 0%, rgb(0 0 0 / 40%) 50%, rgb(0 0 0 / 60%) 100%);z-index:1"}),wt=Object(n.styled)("div",{target:"egxfm5d10"})("position:absolute;bottom:16px;width:200%;height:62px;transition:all .7s ease;z-index:2;",({isActive:e,isRTL:t})=>e?{transform:t?"translateX(50%)":"translateX(-50%)"}:null,""),Pt=Object(n.styled)("div",{target:"egxfm5d9"})({name:"z7njv",styles:"padding-inline:10px;width:50%;position:absolute;inset-inline-start:0"}),Et={name:"1q0x4bm",styles:"color:#fff;font-size:1.3rem;line-height:1.7rem;font-family:var(--tux-fontFamilyParagraph);font-style:normal"},kt=Object(n.styled)("div",{target:"egxfm5d8"})({name:"idemhy",styles:"min-height:42px;display:flex;flex-direction:column;justify-content:flex-end"}),St=Object(n.styled)(L.a,{target:"egxfm5d7"})(Et," font-weight:400;margin-bottom:8px;width:185px;"),Ct=Object(n.styled)("div",{target:"egxfm5d6"})({name:"17gnx5n",styles:"display:flex;align-items:center;width:191px"}),It=Object(n.styled)("div",{target:"egxfm5d5"})({name:"wegu7m",styles:"margin-inline-start:auto;display:flex;align-items:center"}),Tt=Object(n.styled)("span",{target:"egxfm5d4"})("width:16px;height:16px;background-image:url(",ct.a,");background-size:cover;",e=>e.isRTL?"margin-inline-end: 3px; transform: rotate(180deg);":"margin-inline-end: 5px;",";"),Rt=Object(n.styled)("span",{target:"egxfm5d3"})(Et," font-weight:",e=>e.fontWeight,";text-overflow:ellipsis;overflow:hidden;white-space:nowrap;",e=>e.maxWidth&&`max-width: ${e.maxWidth};`,";"),_t=Object(n.styled)("div",{target:"egxfm5d2"})({name:"s5xdrg",styles:"display:flex;align-items:center"}),At=Object(n.styled)("div",{target:"egxfm5d1"})("background-image:url('",e=>e.src,"');width:20px;height:20px;border-radius:50%;background-size:cover;margin-inline-end:8px;"),Lt=Object(n.styled)("div",{target:"egxfm5d0"})({name:"1q49fif",styles:"display:flex;flex-direction:row;justify-content:center;align-items:center;bottom:8px;width:50%;row-gap:4px;position:absolute;inset-inline-end:0"});var Dt=Object(n.connect)(({itemNum:e,cover:t,playCount:r,uniqueId:i,videoId:o,logQueryParams:d,referrer:u,teaCallback:p,jumpFailHandler:b,useSmartWrapper:m,visible:f,videoPlayerStatus:h,setRecommendVideoProgress:j,swiperTouchStatus:O,playVideo:y,isActive:x,description:w,avatarThumbUrl:P,useDetailedDescription:E,isRTL:k})=>{const[S,C]=Object(a.useState)(0),I=Object(a.useMemo)(()=>h===Bt.Playing,[h]),[T,A]=Object(a.useState)(I),L=Object(a.useRef)(),{state:D}=Object(n.useConnect)(),V=D.theme.globalParams,N=Object(a.useCallback)(()=>{clearTimeout(L.current)},[L]);Object(a.useEffect)(()=>{I&&A(I)},[I]);const W=Object(a.useCallback)(()=>{if(!x||!I)return;N();const e=100/((I?8e3:4e3)/50);C(t=>t+e),L.current=window.setTimeout(()=>{N(),W()},50)},[I,N,x]);return Object(a.useEffect)(()=>(x&&T?(C(0),W()):N(),()=>{N()}),[W,x,N,T]),Object(a.useEffect)(()=>{x||C(0)},[x]),Object(a.useEffect)(()=>{j(S),(S>=100&&"touchEnd"===O||h===Bt.End)&&x&&(y(!0),N())},[S,y,O,x,N,h]),Object(H.jsx)(Vt,{refer:s.j.Video,referrer_url:u,redirectLink:Object(R.g)({videoId:o,globalQueryParams:V(l.k.TARGETS.CARD_PLAY),optionalParams:d}),target:v.b.VIDEO_WRAPPER,gd_label:s.m.Video,id:o,useSmartWrapper:m,pid:s.h.WebOther,teaTarget:l.k.TARGETS.CARD_PLAY,linkOnClickHandler:()=>{p(o,e)},jumpStartHandler:()=>{p(o,e),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{b()},jumpHook:e=>Object(_.a)(e,!0),shouldStopInteractEventPropagation:!0,customStyle:{width:"100%",height:"100%"},fallbackURLParams:{videoId:o,uniqueId:i,type:s.c.Video},"data-e2e":"embed-swiper-RecommendationCard-SwiperCardSmartWrapperExtension",children:Object(H.jsx)(H.Fragment,{children:f&&Object(H.jsx)(Nt,{"data-swiper-parallax-opacity":"0.2",style:{backgroundImage:`url(${t})`},"data-e2e":"embed-swiper-RecommendationCard-SwiperCardSmall",children:E?Object(H.jsx)(vt,{authorUniqueId:i,avatarThumbUrl:P,description:w,playCount:r,isRTL:k,"data-e2e":"embed-swiper-RecommendationCard-SwiperInfo"}):Object(H.jsxs)(H.Fragment,{children:[Object(H.jsx)(Wt,{"data-e2e":"embed-swiper-RecommendationCard-SwiperCardSmallIcon"}),Object(H.jsx)(Ht,{"data-e2e":"embed-swiper-RecommendationCard-SwiperCardSmallPlayCount",children:Object(g.b)(r)})]})})})},o)});const Vt=Object(n.styled)(O.a,{target:"e1dnpsem3"})({name:"w1atjl",styles:"width:100%;height:100%"}),Nt=Object(n.styled)("div",{target:"e1dnpsem2"})("display:block;width:100%;height:100%;border-radius:4px;background-size:cover;background-repeat:no-repeat;background-position:center;position:relative;&::after{display:block;content:'';width:100%;height:100%;position:absolute;top:0;left:0;background-color:transparent;background-image:url(",ut.a,");background-size:48px 48px;background-position:center;background-repeat:no-repeat;}&:hover{cursor:pointer;&::after{background-color:rgb(0 0 0 / 60%);}}"),Wt=Object(n.styled)("span",{target:"e1dnpsem1"})("display:block;width:16px;height:16px;background-image:url(",ct.a,");background-size:cover;position:absolute;bottom:4px;left:4px;"),Ht=Object(n.styled)("span",{target:"e1dnpsem0"})({name:"198vwvx",styles:"color:#fff;display:inline;font-size:1.3rem;line-height:1.7rem;position:absolute;bottom:3px;left:22px;font-family:var(--tux-fontFamilyParagraph)"});const Ft=Object(a.forwardRef)(({showVideo:e,imgCover:t,playAddr:r,muted:n,description:a,authorUniqueId:i,avatarThumbUrl:o,playCount:s,playedFiftyPercent:l,useDetailedDescription:c,isRTL:d},u)=>Object(H.jsxs)(zt,{showVideo:e,"data-e2e":"embed-swiper-SwiperVideoPlayer-DivSwiperVideoItem",children:[Object(H.jsx)(Mt,{"x-webkit-airplay":"allow","webkit-playsinline":"true",preload:"auto",playsInline:!0,height:"100%",width:"100%",ref:u,muted:n,src:r,poster:t,"data-e2e":"embed-swiper-SwiperVideoPlayer-VideoPlayer"}),c&&e&&Object(H.jsx)(vt,{description:a,authorUniqueId:i,avatarThumbUrl:o,playCount:s,playedFiftyPercent:l,isRTL:d,"data-e2e":"embed-swiper-SwiperVideoPlayer-SwiperInfo"})]})),Mt=Object(n.styled)("video",{target:"e1azokb21"})({name:"k9zpyo",styles:"position:absolute;left:0;right:0;bottom:0;top:0;object-fit:cover;border-radius:4px"}),zt=Object(n.styled)("div",{target:"e1azokb20"})("width:211px;height:280px;overflow:hidden;",({showVideo:e})=>({visibility:e?"visible":"hidden"}),"");let Bt;!function(e){e.Init="init",e.Playing="playing",e.Paused="paused",e.Error="error",e.End="end",e.Waiting="waiting"}(Bt||(Bt={}));const Ut=(e,t)=>{const{itemList:r=[],responsiveType:n,muted:a,visible:i}=e;return r.length===t.itemList.length&&n===t.responsiveType&&a===t.muted&&i===t.visible};var Gt=i.a.memo(Object(n.connect)(e=>{const[t,r]=Object(a.useState)(0),[n,i]=Object(a.useState)(!1),[o,l]=Object(a.useState)(Bt.Init),[c,d]=Object(a.useState)("touchEnd"),[u,p]=Object(a.useState)(0),b=Object(a.useMemo)(()=>u>50,[u]),m=Object(a.useRef)(),f=Object(a.useRef)(null),g=Object(a.useRef)(),j=Object(a.useRef)(),{teaCallback:O,responsiveType:v,itemList:y,logQueryParams:x,isMobile:w,referrer:P,isStrategyAvailable:E,jumpFailHandler:k,muted:S,visible:C,isRTL:I,useDetailedDescription:T}=e;Object(a.useEffect)(()=>(i(!1),m.current&&(m.current.on("touchStart",()=>{d("touchStart"),j.current&&clearTimeout(j.current),V()}),m.current.on("touchEnd",()=>{j.current=setTimeout(()=>{d("touchEnd"),D()},500)}),m.current.on("transitionStart",()=>{d("touchStart")}),m.current.on("transitionEnd",()=>{d("touchEnd"),D()})),()=>{var e,t,r,n;null===(e=m.current)||void 0===e||e.off("touchStart"),null===(t=m.current)||void 0===t||t.off("touchEnd"),null===(r=m.current)||void 0===r||r.off("transitionStart"),null===(n=m.current)||void 0===n||n.off("transitionEnd")}),[C]);const R=v!==s.d.PC_BIG,_=y[t];Object(a.useEffect)(()=>{if(n){const e=()=>{l(Bt.Playing)},t=()=>{l(Bt.Error)},r=()=>{l(Bt.Waiting)},n=()=>{l(Bt.End)},a=f.current;return null==a||a.addEventListener("playing",e),null==a||a.addEventListener("error",t),null==a||a.addEventListener("waiting",r),null==a||a.addEventListener("ended",n),()=>{null==a||a.removeEventListener("playing",e),null==a||a.removeEventListener("error",t),null==a||a.removeEventListener("waiting",r),null==a||a.removeEventListener("ended",n)}}return()=>{}},[f,n]);const A=0===t?null:Object(H.jsx)(Yt,{small:v!==s.d.PC_BIG,type:"button",onClick:e=>{e.stopPropagation(),null!==m.current&&void 0!==m.current&&m.current.slidePrev()},"data-testid":"left-button","data-e2e":"embed-swiper-index-SwiperButtonPrev"}),L=t===y.length-1?null:Object(H.jsx)(Qt,{small:v!==s.d.PC_BIG,type:"button",onClick:e=>{e.stopPropagation(),null!==m.current&&void 0!==m.current&&m.current.slideNext()},"data-testid":"right-button","data-e2e":"embed-swiper-index-SwiperButtonNxt"}),D=Object(a.useCallback)(()=>{n&&(g.current=setTimeout(()=>{var e;null===(e=f.current)||void 0===e||e.play().catch(e=>{console.error(e),l(Bt.Error)})},500))},[n]),V=Object(a.useCallback)(()=>{var e;null===(e=f.current)||void 0===e||e.pause()},[]),N=Object(a.useCallback)(()=>{f.current&&(f.current.pause(),f.current.currentTime=0,l(Bt.Paused))},[]),W=Object(a.useCallback)(e=>{if(y.length>1&&y.length>t+1){var r;if(e)null===(r=m.current)||void 0===r||r.slideNext();l(Bt.Init),D()}else V(),l(Bt.End)},[D,V,y,t]);Object(a.useEffect)(()=>(n?D():N(),()=>{g.current&&clearTimeout(g.current),j.current&&clearTimeout(j.current)}),[D,N,n]);const F=y.map((e,r)=>{const{id:a="",video:{cover:i=""},author:{uniqueId:s="",avatarThumb:l=""},stats:{playCount:d=0},desc:u}=e;return Object(H.jsx)(Jt,{"data-e2e":"embed-swiper-index-SwiperCardBig",children:Object(H.jsx)(Dt,{itemNum:r,cover:i,playCount:d,uniqueId:s,videoId:a,logQueryParams:x,referrer:P,teaCallback:O,jumpFailHandler:k,useSmartWrapper:w&&E,playVideo:W,visible:C,videoPlayerStatus:o,swiperTouchStatus:c,isActive:r===t&&n,setRecommendVideoProgress:p,avatarThumbUrl:l,description:u,useDetailedDescription:T,isRTL:I,"data-e2e":"embed-swiper-index-RecommendationCard"},a)},r)});return 0===y.length?null:Object(H.jsx)(H.Fragment,{children:Object(H.jsxs)(qt,{small:R,"data-testid":"embed-swiper","data-e2e":"embed-swiper-index-EmbedSwiperContainer",children:[Object(H.jsx)(Kt,{small:R,"data-e2e":"embed-swiper-index-RecommendationCardTitleContainer",children:Object(H.jsx)(Xt,{small:R,"data-e2e":"embed-swiper-index-RecommendationCardTitle",children:h.b.t("embed_end_title_1")})}),Object(H.jsxs)(Zt,{small:R,"data-e2e":"embed-swiper-index-RecommendationCardContainer",children:[A,F.length>0&&Object(H.jsx)(it.a,{getSwiper:e=>{e&&(e.on("slideChange",()=>{r(e.activeIndex)}),m.current=e)},effect:"coverflow",grabCursor:!0,centeredSlides:!0,slidesPerView:"auto",loopedSlides:0,coverflowEffect:{rotate:0,stretch:-30,depth:140,modifier:1,slideShadows:!1},parallax:!0,"data-e2e":"embed-swiper-index-Swiper",children:F}),L,Object(H.jsxs)(er,{"data-e2e":"embed-swiper-index-SwiperVideoPlayerWrapper",children:[Object(H.jsx)(Ft,{ref:f,showVideo:n,playAddr:_.video.playAddr,imgCover:_.video.cover,authorUniqueId:_.author.uniqueId,avatarThumbUrl:_.author.avatarThumb,description:_.desc,playCount:_.stats.playCount,muted:S,playedFiftyPercent:b,useDetailedDescription:T,isRTL:I,"data-e2e":"embed-swiper-index-SwiperVideoPlayer"}),n&&Object(H.jsx)(tr,{"data-e2e":"embed-swiper-index-ProgressBarWrapper",children:Object(H.jsx)(rr,{style:{width:u+"%"},"data-e2e":"embed-swiper-index-ProgressBarInnerLine"})})]})]})]})})}),Ut);const qt=Object(n.styled)("div",{target:"e4nbkl110"})(".swiper-container-3d{perspective:1200px;}.swiper-container{width:273px;height:354px;margin-left:auto;margin-right:auto;position:relative;overflow:hidden;list-style:none;padding:0;z-index:1;}.swiper-wrapper{position:relative;width:100%;height:100%;z-index:1;display:flex;transition-property:transform;box-sizing:content-box;}.swiper-slide{flex-shrink:0;width:100%;height:100%;position:relative;transition-property:transform;}",e=>e.small&&"\n .swiper-container {\n width: 100%;\n height: 280px;\n }\n\n .swiper-slide {\n width: 211px;\n height: 280px;\n }",";"),$t=Object(n.styled)("button",{target:"e4nbkl19"})("width:48px;height:48px;border-radius:24px;border-style:none;background-color:transparent;background-image:url(",st.a,");background-size:contain;outline:none;cursor:pointer;position:absolute;top:50%;z-index:2;"),Yt=Object(n.styled)($t,{target:"e4nbkl18"})("transform:translateY(-50%);left:16px;",e=>e.small&&"left: 9px;",";"),Qt=Object(n.styled)($t,{target:"e4nbkl17"})("transform:translateY(-50%) rotate(180deg);right:16px;",e=>e.small&&"right: 9px;",";"),Kt=Object(n.styled)("div",{target:"e4nbkl16"})("display:flex;",e=>e.small?"padding: 56px 0 16px;":"padding: 26px 0 12px;",";"),Xt=Object(n.styled)("h3",{target:"e4nbkl15"})("font-size:1.7rem;line-height:2.1rem;color:#fff;font-family:var(--tux-fontFamilyParagraph);",e=>e.small?"width: 211px;":"width: 273px;"," margin:auto;"),Zt=Object(n.styled)("div",{target:"e4nbkl14"})("display:flex;flex-flow:row nowrap;justify-content:space-between;align-items:center;",e=>e.small?"padding: 0;":"padding: 0 24px;"," position:relative;"),Jt=Object(n.styled)("div",{target:"e4nbkl13"})({name:"yz8bu5",styles:"width:100%;height:100%;display:flex;flex-flow:row wrap;justify-content:space-between;align-content:space-between;cursor:default"}),er=Object(n.styled)("div",{target:"e4nbkl12"})({name:"pfqv95",styles:"position:absolute;top:0;left:50%;transform:translateX(-50%);z-index:1;pointer-events:none"}),tr=Object(n.styled)("div",{target:"e4nbkl11"})({name:"vx1kyd",styles:"position:absolute;bottom:0;left:0;height:4px;z-index:20;width:100%;html[dir='rtl'] &{left:initial;right:0!important;}border-radius:4px"}),rr=Object(n.styled)("div",{target:"e4nbkl10"})({name:"1j2pue7",styles:"display:block;height:100%;z-index:10;background-color:#fe2c55;width:0"});var nr=r(1024),ar=r(1025),ir=r(1026),or=r(1027);function sr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function lr(e){for(var t=1;t{const{videoData:{itemInfos:t,authorInfos:r},logParams:a={},referrer:i,isMobile:o,isStrategyAvailable:d,jumpFailHandler:u}=e,{commentCount:p,diggCount:b,shareCount:m,id:f}=t,{covers:h=[],uniqueId:j,userId:y}=r,x=lr({page_name:l.k.PAGE,enter_from:l.k.PAGE,video_id:f},a),w={referer_video_id:f},{state:P}=Object(n.useConnect)(),E=P.theme.globalParams,k=o&&d;return Object(H.jsxs)(pr,{"data-testid":"layer-component","data-e2e":"Player-Layer-LayerContainer",children:[Object(H.jsx)("span",{"data-e2e":"Player-Layer-span"}),Object(H.jsxs)(br,{"data-e2e":"Player-Layer-LayerInfo",children:[Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:i,redirectLink:Object(R.e)({uniqueId:j,globalQueryParams:E(cr.HEAD),optionalParams:w}),target:v.b.USER_WRAPPER,teaTarget:cr.HEAD,gd_label:s.m.User,id:y,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.HEAD}))},jumpStartHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.HEAD})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},useSmartWrapper:k,"data-e2e":"Player-Layer-SmartWrapperExtension",children:Object(H.jsx)(mr,{style:{backgroundImage:`url(${h[0]})`},"data-e2e":"Player-Layer-LayerAvatar"})}),Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:i,redirectLink:Object(R.e)({uniqueId:j,globalQueryParams:E(cr.HEAD),optionalParams:w}),target:v.b.USER_WRAPPER,teaTarget:cr.HEAD,gd_label:s.m.User,id:y,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.HEAD_PLUS}))},jumpStartHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.HEAD_PLUS})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},useSmartWrapper:k,"data-e2e":"Player-Layer-SmartWrapperExtension",children:Object(H.jsx)(fr,{"data-e2e":"Player-Layer-LayerFollow",children:Object(H.jsx)(nr.a,{width:20,height:20,"data-e2e":"Player-Layer-RedPlusCircleColor"})})}),Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:i,redirectLink:Object(R.f)({uniqueId:j,videoId:f,globalQueryParams:E(cr.LIKE),optionalParams:w}),target:v.b.VIDEO_WRAPPER,teaTarget:cr.LIKE,gd_label:s.m.Video,id:f,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.LIKE}))},jumpStartHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.LIKE})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},useSmartWrapper:k,"data-e2e":"Player-Layer-SmartWrapperExtension",children:Object(H.jsxs)(gr,{"data-e2e":"Player-Layer-LayerLikeCommentShareComponent",children:[Object(H.jsx)(ar.a,{width:40,height:40,"data-e2e":"Player-Layer-LikeShadowColor"}),Object(H.jsx)(hr,{"data-e2e":"Player-Layer-LayerText",children:Object(g.b)(b)})]})}),Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:i,redirectLink:Object(R.f)({uniqueId:j,videoId:f,globalQueryParams:E(cr.COMMENT_BTN),optionalParams:w}),target:v.b.VIDEO_WRAPPER,teaTarget:cr.COMMENT_BTN,gd_label:s.m.Video,id:f,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.COMMENT_BTN}))},jumpStartHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.COMMENT_BTN})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},useSmartWrapper:k,"data-e2e":"Player-Layer-SmartWrapperExtension",children:Object(H.jsxs)(gr,{"data-e2e":"Player-Layer-LayerLikeCommentShareComponent",children:[Object(H.jsx)(ir.a,{width:40,height:40,"data-e2e":"Player-Layer-CommentShadowColor"}),Object(H.jsx)(hr,{"data-e2e":"Player-Layer-LayerText",children:Object(g.b)(p)})]})}),Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:i,redirectLink:Object(R.f)({uniqueId:j,videoId:f,globalQueryParams:E(cr.SHARE),optionalParams:w}),target:v.b.VIDEO_WRAPPER,teaTarget:cr.SHARE,gd_label:s.m.Video,id:f,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.SHARE}))},jumpStartHandler:()=>{c.a.event(dr.TAP,lr(lr({},x),{},{target:cr.SHARE})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{u()},useSmartWrapper:k,"data-e2e":"Player-Layer-SmartWrapperExtension",children:Object(H.jsxs)(gr,{"data-e2e":"Player-Layer-LayerLikeCommentShareComponent",children:[Object(H.jsx)(or.a,{width:40,height:40,"data-e2e":"Player-Layer-ShareShadowColor"}),Object(H.jsx)(hr,{"data-e2e":"Player-Layer-LayerText",children:Object(g.b)(m)})]})})]})]})});const pr=Object(n.styled)("div",{target:"es828bz5"})({name:"5a8089",styles:"position:absolute;top:0;inset-inline-end:0;width:5em;height:100%;margin:0;padding:1em 0 2em;display:flex;flex-direction:column;align-items:center;justify-content:space-between;z-index:9;font-size:1.6rem;a{display:block;background-position:center;background-repeat:no-repeat;background-size:contain;color:#fff;opacity:0.9;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);}a:link,a:visited{opacity:0.9;color:#fff;}a:active,a:hover,a:focus{opacity:1;text-shadow:0 1px 1px rgb(22 24 35 / 20%);}"}),br=Object(n.styled)("div",{target:"es828bz4"})({name:"bjn8wh",styles:"position:relative"}),mr=Object(n.styled)("div",{target:"es828bz3"})({name:"1gr60dp",styles:"width:3em;height:3em;margin-bottom:-2px;border-radius:50%;border:1px solid #fff;background-size:cover"}),fr=Object(n.styled)("div",{target:"es828bz2"})({name:"kevzz6",styles:"width:1.25em;height:1.25em;position:absolute;top:3em;left:50%;transform:translate(-50%, -50%)"}),gr=Object(n.styled)("div",{target:"es828bz1"})({name:"1o8oa5s",styles:"cursor:pointer;margin:32px auto 16px;width:40px;height:40px;display:block;background-position:center;background-repeat:no-repeat;background-size:contain;color:#fff;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);:active,:hover,:focus{text-shadow:0 1px 1px rgb(22 24 35 / 20%);}"}),hr=Object(n.styled)("span",{target:"es828bz0"})({name:"1rj220v",styles:"display:inline-block;width:100%;text-align:center;font-size:1.3rem;line-height:1.7rem;letter-spacing:-0.025em"});let jr;!function(e){e.LAYER="LAYER",e.USER="USER"}(jr||(jr={}));var Or={name:"7khr44",styles:"margin-left:4px;flex-shrink:0"};const vr=({authorInfos:e,type:t=jr.USER})=>{const{uniqueId:r,covers:n=[],verified:a,nickName:i}=e;return Object(H.jsxs)(yr,{"data-testid":"player-profile",layer:t===jr.LAYER,"data-e2e":"Player-Profile-ProfileContainer",children:[Object(H.jsx)("div",{"data-e2e":"Player-Profile-div",children:Object(H.jsx)(xr,{style:{width:t===jr.LAYER?48:32,height:t===jr.LAYER?48:32},"data-e2e":"Player-Profile-AvatarContainer",children:Object(H.jsx)(wr,{className:"embed-avatar",src:n[0],alt:a?i+" TikTok":"","data-e2e":"Player-Profile-Avatar"})})}),Object(H.jsxs)(Pr,{className:"info-desc","data-e2e":"Player-Profile-InfoDescContainer",children:[Object(H.jsxs)(Er,{layer:t===jr.LAYER,"data-e2e":"Player-Profile-UniqueId",children:[Object(H.jsx)("span",{"data-e2e":"Player-Profile-span",children:r}),a&&Object(H.jsx)(j.a,{css:Or,width:14,height:14,"data-e2e":"Player-Profile-VerifiedBadgeColor"})]}),Object(H.jsx)(kr,{layer:t===jr.LAYER,"data-e2e":"Player-Profile-NickName",children:i})]}),Object(H.jsx)(Sr,{style:{borderRadius:999},"data-e2e":"Player-Profile-Button",children:h.b.t("embed_hover_button")})]})},yr=Object(n.styled)("div",{target:"e4pr55s6"})("display:flex;flex-flow:row nowrap;justify-content:flex-start;align-items:center;position:relative;>:first-child{flex:0 0 32px;}",e=>e.layer&&"\n color: #fff;\n\n .small-size.paused &{\n padding-bottom: 16px;\n border-bottom: 1px solid rgb(255 255 255 / 20%);\n }\n\n > :first-child {\n flex: 0 0 48px;\n }\n ",";"),xr=Object(n.styled)("span",{target:"e4pr55s5"})({name:"mik1yo",styles:"display:inline-block;box-sizing:border-box;margin:0;padding:0;overflow:hidden;white-space:nowrap;text-align:center;vertical-align:middle;border-radius:50%"}),wr=Object(n.styled)("img",{target:"e4pr55s4"})({name:"4uwt2b",styles:"width:100%;height:100%;object-fit:cover"}),Pr=Object(n.styled)("div",{target:"e4pr55s3"})({name:"u1vlg7",styles:"flex:auto;padding:0 8px;overflow:hidden"}),Er=Object(n.styled)("h5",{target:"e4pr55s2"})("font-size:1.6rem;line-height:2.2rem;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);display:flex;align-items:center;>span{white-space:pre;overflow:hidden;text-overflow:ellipsis;}>svg{flex-shrink:0;}",e=>e.layer&&"\n font-size: 1.8rem;\n line-height: 2.5rem;\n ",";"),kr=Object(n.styled)("h5",{target:"e4pr55s1"})("font-size:1.4rem;line-height:2rem;font-family:var(--tux-fontFamilyParagraph);font-weight:400;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:100%;",e=>e.layer&&"\n font-size: 1.4rem;\n line-height: 2rem;\n ",";"),Sr=Object(n.styled)("button",{target:"e4pr55s0"})({name:"1cncrli",styles:"flex:0 0 98px;display:inline-block;height:28px;line-height:2.6rem;font-size:1.4rem;text-align:center;border-radius:2px;color:#fff;background-color:#fe2c55;transition:all 100ms linear;white-space:nowrap;padding:0 6px;font-family:var(--tux-fontFamilyParagraph);font-weight:var(--tux-fontWeightSemibold);cursor:pointer;&:visited{background:linear-gradient(0deg, rgb(0 0 0 / 12%), rgb(0 0 0 / 12%)),#fe2c55;}&:hover,&:active{background:linear-gradient(0deg, rgb(0 0 0 / 6%), rgb(0 0 0 / 6%)),#fe2c55;}"});function Cr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ir(e){for(var t=1;t{const{onPlayerStateChange:t}=e,{state:r,libraries:i}=Object(n.useConnect)(),{projectSpecialConfig:o={},data:{}}=r.source,{videoPlayConfig:u,hiddenLayerBannerContent:p,hiddenRecommendVideosBannerContent:b,hiddenProfileBannerContent:m,hiddenVideoControllerBannerContent:f,hiddenTTLogoContent:g,hiddenVideoInitCover:h,hiddenVideoProgressContent:j}=o,y=r.theme.globalParams,{lang:x}=r.theme,[w,P]=Object(a.useState)(""),[E,k]=Object(a.useState)(!1),[S,C]=Object(a.useState)([]),[I,T]=Object(a.useState)(!0),[A,L]=Object(a.useState)(!1),[D,V]=Object(a.useState)(!1),[N,W]=Object(a.useState)(!1),[F,M]=Object(a.useState)("0"),z=Object(a.useRef)(e.logParams),B=Object(a.useRef)(e.videoInfos.id),U=Object(a.useRef)(null),G=Object(a.useRef)(null),q=Object(a.useRef)(),$=Object(a.useRef)(!1),Y=Object(a.useRef)(!1),Q=Object(a.useRef)(!1),K=Object(a.useRef)(),X=Object(a.useRef)(0),Z=()=>{const{videoInfos:t}=e,{warnInfo:r=[]}=t;return r.length>0},{isMobile:J}=e,ee=()=>{X.current=Date.now()},te=()=>{c.a.event(Tr.EMBED_VIDEO_PLAY_TIME,Ir(Ir({},We),{},{duration:Date.now()-X.current}))};Object(a.useEffect)(()=>(K.current=re([[_r,ie(_r)],[Ar,ie(Ar)],[Lr,ie(Lr)],[Dr,ie(Dr)],[Vr,ie(Vr)],[Nr,ie(Nr)],[Wr,ie(Wr)]]),ue(),I&&U.current&&U.current.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?T(!1):setTimeout(()=>{I&&T(!1)},1e3),Z()&&ne(),()=>{K.current&&K.current()}),[]),Object(a.useEffect)(()=>{var e,t,n;const a=()=>{w===Ar&&("hidden"===document.visibilityState&&te(),"visible"===document.visibilityState&&ee())},o=null===(e=r.abtest)||void 0===e||null===(t=e.webExperiments)||void 0===t||null===(n=t.values)||void 0===n?void 0:n.videoEmbedIterationsRecommendation;var s;Boolean(o)&&(W(o.val.useDetailedDescription),null==i||null===(s=i.abtest)||void 0===s||!s.exposeConfig||w!==Vr&&w!==Dr||i.abtest.exposeConfig("videoEmbedIterationsRecommendation",null,e=>{var t,r;null===(t=i.service)||void 0===t||null===(r=t.logger)||void 0===r||r.info("Exposed experiment with value ",e)}));return document.addEventListener("visibilitychange",a),()=>{document.removeEventListener("visibilitychange",a)}},[w]);const re=(e=[])=>{const t=U.current;return t?(e.forEach(([e,r])=>{t.addEventListener(e,r)}),()=>{e.forEach(([e,r])=>{t.removeEventListener(e,r)}),q.current&&(window.clearInterval(q.current),q.current=null)}):null},ne=()=>{c.a.event(l.j.VPA_VIDEO_SHOW,Ir({video_id:B.current},z.current))},ae=e=>{c.a.event(Tr.TAP,Ir({target:e,video_id:B.current},z.current))},ie=r=>function(){switch(P(r),t(r),e.onEventChange(r),r){case Wr:T(!1);break;case _r:de(!1),ee(),$.current?ae(Rr.RESUME_PLAY):Y.current?ae(Rr.REPLAY):ae(Rr.PLAY),$.current=!1,Y.current=!1;break;case Ar:break;case Lr:te();try{const{videoInfos:{video:t}}=e,{urls:r=[]}=t;Object(we.a)(`Embed video listener Error - ${document.referrer} - ${location.href} - ${r[0]}`)}catch(e){}break;case Dr:te(),Y.current=!0,$.current=!1,c.a.event(Tr.FINISH,Ir({video_id:B.current},z.current)),de(!0);break;case Vr:te(),ae(Rr.PAUSE),$.current=!0}},oe=()=>{w===Ar?($.current=!0,le()):se()},se=()=>{const{current:e}=U,{current:t}=G;q.current||(q.current=window.setInterval(()=>{try{const t=(Number(null==e?void 0:e.currentTime)/Number(null==e?void 0:e.duration)*100).toFixed(2)+"%";M(t)}catch(e){console.warn("playVideo function: issue",e.message)}},16)),ze("EmbedVideo/Player",e,ce),ze("EmbedVideo/Player",t)},le=()=>{const{current:e}=U,{current:t}=G;null==e||e.pause(),null==t||t.pause(),q.current&&(window.clearInterval(q.current),q.current=null)},ce=()=>{try{const{videoInfos:{video:t}}=e,{urls:r=[]}=t;Object(we.a)(`Embed video Error - ${document.referrer} - ${location.href} - ${r[0]}`)}catch(e){console.warn("handleVideoError: issue",null==e?void 0:e.message)}},de=(e=!1)=>{V(e)},ue=async()=>{var t,n,a,i;const{useReflowRecommendation:o=!1}=(null===(t=r.abtest)||void 0===t||null===(n=t.webExperiments)||void 0===n||null===(a=n.values)||void 0===a||null===(i=a.videoEmbedIterationsRecommendation)||void 0===i?void 0:i.val)||{},{commerceConfig:{isCommerce:s,isCommonCommerce:l}}=e,c=!s&&!l;if(!Q.current&&c){const{authorInfos:{secUid:t}}=e,{list:r=[]}=o?await Qe.getEmbedRecommendListFromReflow({count:24,itemID:ke}).catch(e=>e.message):await Qe.getEmbedRecommendList({aid:1284,count:24,secUid:t}).catch(e=>e.message);C(r)}Q.current=!0},pe=e=>{e&&k(!0),L(!0),oe()},{showVideoMask:be}=e;Object(d.a)({intersectionHandler:()=>{be||null!=u&&u.noneAutoPlay||pe(!0)},observedElementId:l.k.OBSERVER,threshold:[.8]});const{videoInfos:me,layerProps:fe,authorInfos:ge,authorStats:he,responsiveType:je,referrer:Oe,isStrategyAvailable:ve,jumpFailHandler:ye}=e,{uniqueId:Pe,userId:Ee}=ge,{id:ke,video:{urls:Se},warnInfo:Ce=[],covers:Ie=[],coversOrigin:Te=[],coversDynamic:Re=[]}=me,_e=Se[0]||"",Ae=Ie[0]||Te[0]||Re[0]||"",Le=I||w===Nr,De=Z()?Ce[0]:{},Ve=w===_r||w===Ar,Ne=w===Vr||w===Dr,{logParams:We={}}=fe,He=Ir({page_name:l.k.PAGE,enter_from:l.k.PAGE,video_id:ke},We),Fe={referer_video_id:ke},Me=!I&&!A,Be=I?"init":"",Ue=Le||Me?"cover":"",Ge=!h&&Me?"init-cover":"",qe=D&&!b?"hidden":"";let Ye="playing";w===Dr?Ye="ended":Ve||(Ye="paused");const Ke=u&&!Le&&"playing"!==Ye?"none-playing":"",Xe=J&&ve,Ze=je===s.d.PC_BIG;return Object(H.jsxs)(Fr,{"data-testid":"player-component","data-e2e":"Player-index-Container",children:[Object(H.jsxs)(H.Fragment,{children:[!j&&Object(H.jsx)(Mr,{style:{width:F},"data-e2e":"Player-index-ProgressBar"}),A?Object(H.jsxs)(H.Fragment,{children:[!m&&Object(H.jsx)(zr,{"data-testid":"embed-player-embed-profile",paused:Ne,small:je!==s.d.PC_BIG,className:`embed-player-embed-profile ${Ne?"paused":""} ${je!==s.d.PC_BIG?"small-size":""}`,"data-e2e":"Player-index-EmbedPlayerEmbedProfile",children:Object(H.jsx)("div",{"data-e2e":"Player-index-div",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:Oe,redirectLink:Object(R.e)({uniqueId:Pe,globalQueryParams:y(Rr.MASKING),optionalParams:Fe}),target:v.b.USER_WRAPPER,teaTarget:Rr.NAME,gd_label:s.m.User,id:Ee,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.MASKING}))},jumpStartHandler:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.MASKING})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{ye()},useSmartWrapper:Xe,"data-e2e":"Player-index-SmartWrapperExtension",children:Object(H.jsx)(vr,{authorInfos:ge,type:jr.LAYER,responsiveType:je,authorStats:he,notPlaying:Ne,teaParams:He,"data-e2e":"Player-index-EmbedProfile"})})})}),!f&&Object(H.jsxs)(Br,{paused:Ne,className:"embed-player-embed-controller","data-testid":"embed-player-controller","data-e2e":"Player-index-EmbedPlayerEmbedController",children:[Object(H.jsxs)("div",{"data-e2e":"Player-index-div",children:[Object(H.jsx)(qr,{playingStatus:Ye,onClick:oe,"data-testid":"play-pause-btn","data-e2e":"Player-index-ControllerToggleVideo"}),Object(H.jsx)($r,{muted:E,"data-testid":"play-mute-btn",onClick:()=>{k(!E),c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.SWITCH_SOUND}))},"data-e2e":"Player-index-ControllerToggleSound"}),Object(H.jsx)(Kr,{"data-e2e":"Player-index-ControllerToggleFullScreen",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:Oe,redirectLink:Object(R.f)({uniqueId:Pe,videoId:ke,globalQueryParams:y(Rr.FULLSCREEN),optionalParams:Fe}),target:v.b.VIDEO_WRAPPER,teaTarget:Rr.FULLSCREEN,gd_label:s.m.Video,id:ke,useSmartWrapper:Xe,pid:s.h.WebOther,linkOnClickHandler:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.FULLSCREEN}))},jumpStartHandler:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.FULLSCREEN})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{ye()},jumpHook:e=>Object(_.a)(e,!0),customStyle:{width:"100%",height:"100%"},"data-e2e":"Player-index-SmartWrapperExtension"})})]}),je!==s.d.PC_BIG&&Ne&&(N?Object(H.jsx)(Qr,{target:"_blank",rel:"noreferrer",href:"https://www.tiktok.com/embed",onClick:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.INFORMATION_ICON}))},"data-e2e":"Player-index-ControllerInfoButton"}):Object(H.jsx)("div",{"data-e2e":"Player-index-div",children:Object(H.jsx)(Xr,{className:"share","data-e2e":"Player-index-ControllerToggleShare",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:Oe,redirectLink:Object(R.f)({uniqueId:Pe,videoId:ke,globalQueryParams:y(Rr.PAUSE_SHARE),optionalParams:Fe}),target:v.b.VIDEO_WRAPPER,teaTarget:Rr.PAUSE_SHARE,gd_label:s.m.Video,id:ke,useSmartWrapper:Xe,pid:s.h.WebOther,linkOnClickHandler:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.PAUSE_SHARE}))},jumpStartHandler:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.PAUSE_SHARE})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{ye()},jumpHook:e=>Object(_.a)(e,!0),customStyle:{width:"100%",height:"100%"},"data-e2e":"Player-index-SmartWrapperExtension"})})}))]})]}):null,!g&&Object(H.jsx)(Zr,{target:"_blank",rel:"noreferrer",href:Object(R.b)({globalQueryParams:y(Rr.LOGO),optionalParams:Fe}),onClick:()=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target:Rr.LOGO}))},"data-e2e":"Player-index-LayerColorfulLogo"}),!b&&Object(H.jsx)(tn,{"data-testid":"embed-recommendation",big:Ze,visible:Ne,clickable:w===Vr||0===S.length,onClick:w===Vr||0===S.length?oe:void 0,"data-e2e":"Player-index-EmbedRecommendation",children:Object(H.jsx)(Gt,{itemList:S,responsiveType:je,isMobile:J,teaCallback:(e,t)=>{c.a.event(Tr.TAP,Ir(Ir({},He),{},{target_id:e,target:Rr.CARD_PLAY,position:t+1}))},logQueryParams:Fe,referrer:Oe,isStrategyAvailable:ve,jumpFailHandler:ye,muted:E||J&&w===Vr,visible:Ne,isRTL:Object(xe.d)(x),useDetailedDescription:N,"data-e2e":"Player-index-EmbedSwiper"})})]}),Object(H.jsxs)(rn,{className:`${Be} ${Ue} ${Ge} ${Ke}`,onClick:()=>pe(!1),"data-e2e":"Player-index-EmbedPlayerLoading",children:[Boolean(Ke)&&Object(H.jsx)(Jr,{"data-e2e":"Player-index-ScreenControllerToggleVideo",children:Object(H.jsx)(en,{playingStatus:"ended"===Ye?"paused":Ye,onClick:oe,"data-testid":"play-pause-btn","data-e2e":"Player-index-CustomControllerToggleVideo"})}),Object(H.jsx)($e,{show:Le,"data-e2e":"Player-index-Loading"}),Me&&!Ke?Object(H.jsx)(nn,{"data-testid":"play-button",onClick:()=>pe(!1),"data-e2e":"Player-index-ClickInitButton"}):null]}),Object(H.jsxs)(an,{"data-e2e":"Player-index-EmbedPlayerContainer",children:[Object(H.jsx)(on,{"data-e2e":"Player-index-EmbedPlayerBlurWrapper",children:Object(H.jsx)(sn,{"data-testid":"play-video-blur",ref:G,src:_e,poster:Ae,muted:!0,"webkit-playsinline":"true",playsInline:!0,"data-e2e":"Player-index-EmbedPlayerVideoBlur"})}),Object(H.jsx)(ln,{className:""+qe,onClick:oe,"data-e2e":"Player-index-EmbedPlayerVideoWrapper",children:Object(H.jsx)(cn,{"data-testid":"play-video",muted:E,ref:U,src:_e,poster:Ae,"webkit-playsinline":"true",preload:"auto",playsInline:!0,"data-e2e":"Player-index-EmbedPlayerVideoItem"})}),Z()&&!Ne?Object(H.jsx)(dn,{"data-e2e":"Player-index-EmbedPlayerVideoWarn",children:Object(H.jsx)(et,{text:De.text,url:De.url,lang:De.lang,type:De.type,target:De.key,scene:"embed",mode:"pc",id:ke,"data-e2e":"Player-index-WarnInfo"})}):null]}),p||!Ze&&Ne?null:Object(H.jsx)(ur,Ir(Ir({isMobile:J,referrer:Oe,isStrategyAvailable:ve,jumpFailHandler:ye},fe),{},{"data-e2e":"Player-index-Layer"}))]})});const Fr=Object(n.styled)("div",{target:"e1hu91t722"})({name:"1efm0bg",styles:"&:hover,&:active{.embed-player-embed-profile{visibility:visible;}.embed-player-embed-controller{visibility:visible;}.embed-player-video-control{visibility:visible;}}"}),Mr=Object(n.styled)("div",{target:"e1hu91t721"})({name:"cf4onp",styles:"position:absolute;top:0;left:0;height:4px;background-color:#fe2c55;z-index:20;html[dir='rtl'] &{left:initial;right:0!important;}"}),zr=Object(n.styled)("div",{target:"e1hu91t720"})("display:block;visibility:hidden;transition:all 0s ease-in-out;position:absolute;width:100%;height:146px;background:linear-gradient(180deg, rgb(0 0 0 / 80%) 3.58%, rgb(0 0 0 / 0%) 85.89%);top:0;left:0;z-index:10;& a{text-decoration:none;}>div{padding:16px;border-bottom:1px solid transparent;}",e=>e.paused&&"background: transparent;\n visibility: visible;\n height: 81px;\n\n > div {\n border-bottom-color: rgb(255 255 255 / 20%);\n }\n "," ",e=>e.paused&&e.small&&"> div {\n border-bottom: 1px solid transparent;\n }",";"),Br=Object(n.styled)("div",{target:"e1hu91t719"})("display:flex;visibility:hidden;transition:all 0s ease-in-out;position:absolute;width:100%;height:104px;background:linear-gradient(0deg, rgb(0 0 0 / 80%) 3.58%, rgb(0 0 0 / 0%) 85.89%);bottom:0;left:0;z-index:8;padding:8px;flex-flow:row nowrap;justify-content:space-between;align-items:flex-end;&>div{display:flex;}",e=>e.paused&&" background: transparent;\n visibility: visible;\n height: 64px;",";"),Ur=Object(n.styled)("span",{target:"e1hu91t718"})({name:"khpxyj",styles:"width:48px;height:48px;margin-right:4px;cursor:pointer"}),Gr={playing:`url(${Ie.a})`,paused:`url(${Re.a})`,ended:`url(${Ae.a})`},qr=Object(n.styled)(Ur,{target:"e1hu91t717"})("background-image:",e=>Gr[e.playingStatus],";"),$r=Object(n.styled)(Ur,{target:"e1hu91t716"})("background-image:",e=>e.muted?`url(${Se.a}) `:`url(${De.a}) `,";"),Yr=Object(n.styled)(Ur,{target:"e1hu91t715"})({name:"9y0gu",styles:">div,>a{display:inline-block;width:100%;height:100%;}"}),Qr=Object(n.styled)("a",{target:"e1hu91t714"})("width:48px;height:48px;margin-right:4px;cursor:pointer;background-image:url(",He.a,");"),Kr=Object(n.styled)(Yr,{target:"e1hu91t713"})("background-image:url(",Ee.a,");"),Xr=Object(n.styled)(Yr,{target:"e1hu91t712"})("background-image:url(",Me.a,");margin-right:0;"),Zr=Object(n.styled)("a",{target:"e1hu91t711"})("width:48px;height:48px;position:absolute;top:8px;right:8px;z-index:7;background-image:url(",Ne.a,");"),Jr=Object(n.styled)("div",{target:"e1hu91t710"})({name:"1kw570m",styles:"background-color:rgba(0 0 0 / 40%);width:70px;height:70px;display:flex;align-items:center;justify-content:center;border-radius:50%"}),en=Object(n.styled)("span",{target:"e1hu91t79"})("background-image:",e=>Gr[e.playingStatus],";background-position:center center;height:40px;width:40px;cursor:pointer;"),tn=Object(n.styled)("div",{target:"e1hu91t78"})("background:rgb(0 0 0 / 90%);width:100%;height:100%;z-index:7;padding-top:81px;position:absolute;visibility:hidden;",e=>e.clickable&&"cursor: pointer;"," ",e=>e.big&&"padding-inline-end: 87px;"," ",e=>e.visible&&"visibility: visible;",";"),rn=Object(n.styled)("div",{target:"e1hu91t77"})({name:"1rwjhy3",styles:"position:absolute;width:100%;height:100%;top:0;left:0;display:flex;align-items:center;justify-content:center;&.init{background-color:#161823;}&.init-cover{background:rgb(0 0 0 / 50%);}&.cover{z-index:10;}&.none-playing{z-index:10;}cursor:pointer"}),nn=Object(n.styled)("span",{target:"e1hu91t76"})("width:96px;height:96px;cursor:pointer;background-image:url(",Re.a,");background-size:contain;"),an=Object(n.styled)("div",{target:"e1hu91t75"})({name:"g4ahfd",styles:"position:absolute;overflow:hidden;width:100%;height:100%"}),on=Object(n.styled)("div",{target:"e1hu91t74"})({name:"1odgfp4",styles:"position:absolute;top:0;left:0;width:100%;height:100%;background-position:center center;background-repeat:no-repeat;background-size:cover;background-color:rgb(22 24 35 / 60%);filter:blur(6px);&::after{content:'';display:block;position:absolute;top:0;left:0;right:0;bottom:0;background-color:rgb(22 24 35 / 60%);}"}),sn=Object(n.styled)("video",{target:"e1hu91t73"})({name:"miszvl",styles:"border-radius:1px;width:100%;height:100%;object-fit:cover;object-position:center"}),ln=Object(n.styled)("div",{target:"e1hu91t72"})({name:"jn6mlp",styles:"position:relative;height:100%;&.hidden{visibility:hidden;}cursor:pointer"}),cn=Object(n.styled)("video",{target:"e1hu91t71"})({name:"ukfjzf",styles:"width:100%;height:100%;object-fit:contain"}),dn=Object(n.styled)("div",{target:"e1hu91t70"})({name:"j7b465",styles:"z-index:7;position:absolute;bottom:0;left:0;right:0;color:#fff"});var un=r(8),pn=r.n(un);const bn=["className","children","ratio","otherChildren"];function mn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function fn(e){for(var t=1;t{const{className:t="",children:r,ratio:n=1,otherChildren:a}=e,i=pn()(e,bn),o=0===n?100:100/n;return Object(H.jsxs)(hn,fn(fn({className:""+t},i),{},{"data-testid":"ratio","data-e2e":"video-v2-Ratio-Container",children:[Object(H.jsx)("div",{"data-e2e":"video-v2-Ratio-div",children:Object(H.jsx)("div",{style:{paddingTop:o+"%"},"data-testid":"wrapper-div","data-e2e":"video-v2-Ratio-div-2",children:Object(H.jsx)(jn,{"data-e2e":"video-v2-Ratio-RatioWrapper",children:r})})}),a]}))};const hn=Object(n.styled)("div",{target:"evgfhlu1"})({name:"bomv9v",styles:">div{position:relative;width:100%;}"}),jn=Object(n.styled)("div",{target:"evgfhlu0"})({name:"j2pfbl",styles:"position:absolute;top:0;left:0;right:0;bottom:0"});var On=r(953),vn=r(954),yn=r(955);let xn,wn,Pn;!function(e){e[e.GeneralSensitive=3]="GeneralSensitive",e[e.PhotoSensitive=4]="PhotoSensitive"}(xn||(xn={})),function(e){e[e.Default=0]="Default",e[e.RemovePhotoSensitiveVideos=1]="RemovePhotoSensitiveVideos",e[e.KeepPhotoSensitiveVideos=2]="KeepPhotoSensitiveVideos"}(wn||(wn={})),function(e){e.GeneralSensitive="general",e.PhotoSensitive="photosensitive",e.PhotoSensitiveRemoved="photosensitive_denied"}(Pn||(Pn={}));Pn.GeneralSensitive,Pn.PhotoSensitive,Pn.PhotoSensitiveRemoved,Pn.GeneralSensitive,Pn.PhotoSensitive,Pn.PhotoSensitiveRemoved,Pn.GeneralSensitive,Pn.PhotoSensitive,Pn.PhotoSensitiveRemoved,Pn.GeneralSensitive,Pn.PhotoSensitive,Pn.PhotoSensitiveRemoved,Pn.GeneralSensitive,Object(H.jsx)(On.a,{width:36,height:36,fill:"rgba(255, 255, 255, .75)","data-e2e":"VideoMask-constants-EyeSlash"}),Pn.PhotoSensitive,Object(H.jsx)(vn.a,{width:32,height:32,fill:"#fff","data-e2e":"VideoMask-constants-Flash"}),Pn.PhotoSensitiveRemoved,Object(H.jsx)(yn.a,{width:48,height:48,fill:"#0BE09B","data-e2e":"VideoMask-constants-Tick"});var En=Object(a.memo)(e=>{const{videoMaskType:t,groupId:r="",icon:n,title:i,desc:o,confirmText:s,cancelText:d,onConfirm:u,onCancel:p}=e,b=Boolean(s),m=Boolean(d);return Object(a.useEffect)(()=>{t!==Pn.PhotoSensitiveRemoved?c.a.event(l.g.TNS_SHOW_MASK_LAYER,{page_name:l.k.PAGE,enter_from:l.k.PAGE,scenario:t,group_id:r}):c.a.event(l.g.TNS_SHOW_PHOTOSENSITIVE_REMOVED,{page_name:l.k.PAGE,enter_from:l.k.PAGE,group_id:r})},[t,r]),Object(H.jsxs)(Sn,{"data-testid":"video-mask","data-e2e":"VideoMask-index-VideoMaskEmbedContainer",children:[Object(H.jsxs)(Cn,{"data-e2e":"VideoMask-index-VideoMaskInfo",children:[Boolean(n)&&Object(H.jsx)(Tn,{"data-e2e":"VideoMask-index-VideoMaskIcon",children:n}),Boolean(i)&&Object(H.jsx)(Rn,{"data-e2e":"VideoMask-index-VideoMaskTitle",children:i}),Boolean(o)&&Object(H.jsx)(_n,{"data-e2e":"VideoMask-index-VideoMaskDesc",children:o})]}),Object(H.jsxs)(In,{"data-e2e":"VideoMask-index-VideoMaskBtnWrapper",children:[b&&Object(H.jsx)(An,{type:"button",onClick:u,"data-e2e":"VideoMask-index-VideoMaskWatchVideoBtn",children:s}),m&&Object(H.jsx)(Ln,{type:"button",onClick:p,"data-e2e":"VideoMask-index-VideoMaskSkipVideoBtn",children:d})]})]})});const kn=Object(n.styled)("div",{target:"eptocrf8"})({name:"1d14l49",styles:"position:absolute;left:0;top:0;width:100vw;height:calc(100vh - 49px - env(safe-area-inset-bottom));display:flex;flex-direction:column;align-items:center;justify-content:space-between;background-color:rgba(0 0 0 / 50%);backdrop-filter:blur(50px);padding:15vh 32px;box-sizing:border-box;z-index:1001;@media (max-height: 460px){padding-top:60px;}@media (max-height: 400px){padding-top:30px;}"}),Sn=Object(n.styled)(kn,{target:"eptocrf7"})({name:"15q7t74",styles:"width:100%;height:100%;padding:25% 32px 15%"}),Cn=Object(n.styled)("div",{target:"eptocrf6"})({name:"v99vt5",styles:"max-width:320px;display:flex;flex-direction:column;align-items:center;justify-content:center"}),In=Object(n.styled)("div",{target:"eptocrf5"})({name:"edk60p",styles:"max-width:320px;width:100%;display:flex;flex-direction:column;align-items:center;padding:0;box-sizing:border-box;transform:translateY(0)"}),Tn=Object(n.styled)("div",{target:"eptocrf4"})({name:"1vmc44h",styles:"width:72px;height:72px;display:flex;border-radius:100px;justify-content:center;align-items:center;background:rgba(255 255 255 / 12%)"}),Rn=Object(n.styled)("p",{target:"eptocrf3"})({name:"1wlfeiw",styles:"font-family:var(--tux-fontFamilyParagraph);font-size:1.7rem;line-height:2rem;text-align:center;color:rgba(255 255 255 / 90%);margin-top:24px"}),_n=Object(n.styled)("p",{target:"eptocrf2"})({name:"3ot6ux",styles:"font-family:var(--tux-fontFamilyParagraph);font-size:1.4rem;line-height:1.7rem;text-align:center;color:rgba(255 255 255 / 74%);margin-top:8px"}),An=Object(n.styled)("button",{target:"eptocrf1"})({name:"1dbhyti",styles:"font-family:var(--tux-fontFamilyParagraph);width:100%;height:44px;margin-bottom:8px;background:#fe2c55;border:none;outline:none;border-radius:999px;display:flex;justify-content:center;align-items:center;text-align:center;font-size:1.5rem;line-height:1.8rem;color:#fff;cursor:pointer"}),Ln=Object(n.styled)(An,{target:"eptocrf0"})({name:"g7lrof",styles:"font-size:1.5rem;line-height:1.8rem;background:rgb(255 255 255 / 12%);margin-bottom:0"});function Dn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Vn(e){for(var t=1;t{const{state:t}=Object(n.useConnect)(),r=t.theme.isMobileView,{uniqueId:a,userId:i}=e.authorInfos,o=t.theme.globalParams,{referrer:d,isStrategyAvailable:u,jumpFailHandler:p,authorInfos:b={},authorStats:m={},responsiveType:f,teaParams:g,postId:h}=e,{EVENTS:j,TARGETS:y}=l.k,x={referer_video_id:h},w=r&&u;return Object(H.jsx)(zr,{"data-testid":"embed-player-embed-profile",paused:!0,small:f!==s.d.PC_BIG,className:"embed-player-embed-profile "+(f!==s.d.PC_BIG?"small-size":""),"data-e2e":"EmbedPhotomode-Profile-EmbedPlayerEmbedProfile",children:Object(H.jsx)("div",{"data-e2e":"EmbedPhotomode-Profile-div",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:d,redirectLink:Object(R.e)({uniqueId:a,globalQueryParams:o(y.MASKING),optionalParams:x}),target:v.b.USER_WRAPPER,teaTarget:y.NAME,gd_label:s.m.User,id:i,pid:s.h.WebOther,jumpHook:e=>Object(_.a)(e,!0),linkOnClickHandler:()=>{c.a.event(j.TAP,Vn(Vn({},g),{},{target:y.MASKING}))},jumpStartHandler:()=>{c.a.event(j.TAP,Vn(Vn({},g),{},{target:y.MASKING})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{p()},useSmartWrapper:w,"data-e2e":"EmbedPhotomode-Profile-SmartWrapperExtension",children:Object(H.jsx)(vr,{authorInfos:b,type:jr.LAYER,responsiveType:f,authorStats:m,notPlaying:!0,teaParams:g,"data-e2e":"EmbedPhotomode-Profile-EmbedProfile"})})})})});Object(n.styled)("div",{target:"e13tdd0v3"})({name:"vptvdy",styles:"position:relative;overflow:hidden;margin:0 auto;min-width:325px;height:fit-content;border:1px solid rgb(22 24 35 / 12%);box-sizing:border-box;border-radius:8px;width:540px"});const Wn=Object(n.styled)(gn,{target:"e13tdd0v2"})({name:"155ze66",styles:"position:relative;width:100%;margin:auto;border-radius:8px 8px 0 0"}),Hn=(Object(n.styled)("a",{target:"e13tdd0v1"})("width:48px;height:48px;position:absolute;top:8px;right:8px;z-index:7;background-image:url(",Ne.a,");"),Object(n.styled)("div",{target:"e13tdd0v0"})({name:"154u1s0",styles:"width:100%;height:100%;&:hover,&:active{.embed-player-embed-profile{visibility:visible;}.embed-player-embed-controller{visibility:visible;}.embed-player-video-control{visibility:visible;}}"})),Fn=Object(a.forwardRef)(({url:e},t)=>{const[r,n]=Object(a.useState)(null);return Object(a.useImperativeHandle)(t,()=>r,[r]),Object(H.jsx)("audio",{ref:n,playsInline:!0,autoPlay:!0,loop:!0,muted:!0,src:e,"data-e2e":"PhotomodeContainer-AudioPlayer-audio"})});Fn.displayName="AudioPlayer";var Mn=Fn,zn=r(1029),Bn=r(1028);r(1009);const Un=Object(n.styled)("button",{target:"e1c3yds910"})("background-color:rgba(84 84 84 / 50%);height:100%;aspect-ratio:1;border-radius:50%;border:none;color:#fff;cursor:pointer;display:flex;justify-content:center;align-items:center;margin:4px;visibility:",e=>e.hidden?"hidden":"visible",";"),Gn=Object(n.styled)("div",{target:"e1c3yds99"})({name:"1tbud86",styles:"z-index:1;position:absolute;display:flex;justify-content:space-between;height:32px;width:158px;left:50%;transform:translateX(-50%);bottom:16px"}),qn=Object(n.styled)("div",{target:"e1c3yds98"})({padding:"16px 24px",borderRadius:"18px",display:"flex",justifyContent:"center",alignItems:"center",bottom:"calc(min(1%,24px))",position:"absolute",zIndex:0,left:"50%",transform:"translateX(-50%)",background:"radial-gradient(rgb(0 0 0 / 15%), rgb(0 0 0 / 10%), rgb(0 0 0 / 0%), rgb(0 0 0 / 0%))",overflow:"hidden"},""),$n=Object(n.styled)("div",{target:"e1c3yds97"})(({dotCount:e,isRTL:t})=>[{position:"relative",display:"flex",height:12,width:12*e,overflow:"hidden",transform:t?"rotate(180deg)":"none"}],""),Yn=Object(n.styled)("div",{target:"e1c3yds96"})(({index:e})=>[{position:"absolute",width:12,height:12,transition:"all 200ms cubic-bezier(65%, 0, 35%, 1)",display:"flex",justifyContent:"center",alignItems:"center",left:12*e}],""),Qn=Object(n.styled)("div",{target:"e1c3yds95"})(({active:e})=>({width:"6px",height:"6px",margin:"3px",borderRadius:"100%",backgroundColor:e?"#fff":"rgba(255 255 255 / 70%)",transition:"all 200ms cubic-bezier(65%, 0, 35%, 1)"}),""),Kn=(Object(n.styled)("div",{target:"e1c3yds94"})({name:"1weorz6",styles:"position:absolute;bottom:min(3vh, 3vw);left:min(3vh, 3vw);z-index:1;width:100%"}),Object(n.styled)("div",{target:"e1c3yds93"})({name:"14k0l9b",styles:"z-index:1;position:absolute;bottom:min(3vh, 3vw);right:min(3vh, 3vw);display:flex;flex-direction:column;align-items:end;gap:2vh"}),Object(n.styled)("div",{target:"e1c3yds92"})({name:"18fm9ui",styles:"display:flex;gap:max(1%, 1.5%)"}),Object(n.styled)("div",{target:"e1c3yds91"})({name:"w8jyao",styles:"width:100%;height:100%;overflow:hidden;.swiper-wrapper{display:flex;flex-direction:row;height:100%;}.swiper-slide{width:100%!important;height:100%!important;display:flex;justify-content:center;align-items:center;flex-shrink:0;overflow:hidden;}"})),Xn=Object(n.styled)("div",{target:"e1c3yds90"})("position:absolute;",({isRTL:e})=>e?"right: 4px":"left: 4px",";bottom:4px;display:flex;");var Zn=({swiperRef:e,isRTL:t})=>{const[r,n]=Object(a.useState)({isBeginning:!0,isEnd:!1});Object(a.useEffect)(()=>{const t=e.current;if(!t)return;const r=e=>{n({isBeginning:e.isBeginning,isEnd:e.isEnd})};return t.on("slideChange",r),()=>{t.off("slideChange",r)}},[e]);const i=t?Object(H.jsx)(ht,{size:16,"data-e2e":"PhotomodeContainer-ImageControl-TUXIconChevronRightLTR"}):Object(H.jsx)(ft,{size:16,"data-e2e":"PhotomodeContainer-ImageControl-TUXIconChevronLeftLTR"}),o=t?Object(H.jsx)(ft,{size:16,"data-e2e":"PhotomodeContainer-ImageControl-TUXIconChevronLeftLTR-2"}):Object(H.jsx)(ht,{size:16,"data-e2e":"PhotomodeContainer-ImageControl-TUXIconChevronRightLTR"}),s=Object(H.jsx)(Un,{hidden:r.isBeginning,onClick:()=>{var t;return null===(t=e.current)||void 0===t?void 0:t.slidePrev()},"data-e2e":"PhotomodeContainer-ImageControl-StyledNavButton",children:i}),l=Object(H.jsx)(Un,{hidden:r.isEnd,onClick:()=>{var t;return null===(t=e.current)||void 0===t?void 0:t.slideNext()},"data-e2e":"PhotomodeContainer-ImageControl-StyledNavButton-5",children:o});return Object(H.jsxs)(Gn,{isRTL:t,"data-e2e":"PhotomodeContainer-ImageControl-DivNavButtonsContainer",children:[s,l]})};var Jn=({length:e,swiperRef:t,isRTL:r})=>{const[n,i]=Object(a.useState)(0),[o,s]=Object(a.useState)(0);Object(a.useEffect)(()=>{if(!(e<6))if(n-o>=5){s(n-6+(n===e-1?1:2))}else if(n<=o&&0!==o){s(n-(0===n?0:1))}},[n,e,o]),Object(a.useEffect)(()=>{const e=t.current;e&&e.on("slideChange",e=>{i(e.activeIndex)})},[e,t]);const l=e>6&&n>=6,c=e>6&&ne===o&&l||e===o+6-1&&c?{height:4,width:4}:{height:6,width:6};return Object(H.jsx)(qn,{"data-e2e":"PhotomodeContainer-ImageNavDots-DivDotBackground",children:Object(H.jsx)($n,{dotCount:Math.min(e,6),isRTL:r,"data-e2e":"PhotomodeContainer-ImageNavDots-DivPaginationContainer",children:Array.from({length:e}).map((e,t)=>Object(H.jsx)(Yn,{index:t,style:{left:12*(t-o)},"data-e2e":"PhotomodeContainer-ImageNavDots-DivDotWrapper",children:Object(H.jsx)(Qn,{active:n===t,style:d(t),"data-e2e":"PhotomodeContainer-ImageNavDots-DivDot"})},t))})})};var ea=({urls:e,isRTL:t})=>{const r=Object(a.useRef)(null);return Object(H.jsxs)(Kn,{"data-e2e":"PhotomodeContainer-ImageSlider-DivSwiperWrapper",children:[Object(H.jsx)(zn.a,{style:{height:"100%",width:"100%",position:"relative",background:"#000"},speed:800,slidesPerView:1,spaceBetween:0,onSwiper:e=>r.current=e,dir:t?"rtl":"ltr","data-e2e":"PhotomodeContainer-ImageSlider-Swiper",children:e.map((e,t)=>Object(H.jsx)(Bn.a,{"data-e2e":"PhotomodeContainer-ImageSlider-SwiperSlide",children:Object(H.jsx)("img",{style:{objectFit:"contain",maxWidth:"100%",maxHeight:"100%"},src:e,alt:"Image "+(t+1),"data-e2e":"PhotomodeContainer-ImageSlider-img"})},String(t)))}),Object(H.jsx)(Zn,{swiperRef:r,isRTL:t,"data-e2e":"PhotomodeContainer-ImageSlider-ImageNavigation"}),Object(H.jsx)(Jn,{length:e.length,swiperRef:r,isRTL:t,"data-e2e":"PhotomodeContainer-ImageSlider-ImageNavDots"})]})};function ta(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function ra(e){for(var t=1;t{const{imageUrls:t,audioUrl:r,teaParams:i,referrer:o,jumpFailHandler:l,postId:d,authorInfos:u,isStrategyAvailable:p}=e,[b,m]=Object(a.useState)(!0),f=Object(a.useRef)(null),{state:g}=Object(n.useConnect)(),h=g.theme.isMobileView,{lang:j}=g.theme,y=Object(xe.d)(j),x=h&&p,w=g.theme.globalParams;return Object(H.jsxs)("div",{"data-testid":"photomode-ui",style:{width:"100%",height:"100%"},"data-e2e":"PhotomodeContainer-index-div",children:[Object(H.jsx)(Mn,{url:r,ref:f,"data-e2e":"PhotomodeContainer-index-AudioPlayer"}),Object(H.jsx)(ea,{urls:t,isRTL:y,"data-e2e":"PhotomodeContainer-index-ImageSlider"}),Object(H.jsxs)(Xn,{isRTL:y,"data-e2e":"PhotomodeContainer-index-DivPhotomodeBottomControls",children:[Object(H.jsx)($r,{style:{marginRight:y?0:-16,marginLeft:y?-16:0,zIndex:1},muted:b,"data-testid":"play-mute-btn",onClick:()=>{f.current&&(f.current.play(),f.current.muted=!b,m(e=>!e))},"data-e2e":"PhotomodeContainer-index-ControllerToggleSound"}),Object(H.jsx)(Kr,{"data-e2e":"PhotomodeContainer-index-ControllerToggleFullScreen",children:Object(H.jsx)(O.a,{refer:s.j.Video,referrer_url:o,redirectLink:Object(R.f)({uniqueId:null==u?void 0:u.uniqueId,videoId:String(d),globalQueryParams:w(aa.FULLSCREEN),optionalParams:{}}),target:v.b.VIDEO_WRAPPER,teaTarget:aa.FULLSCREEN,gd_label:s.m.Video,id:d,useSmartWrapper:x,pid:s.h.WebOther,linkOnClickHandler:()=>{c.a.event(na.TAP,ra(ra({},i),{},{target:aa.FULLSCREEN}))},jumpStartHandler:()=>{c.a.event(na.TAP,ra(ra({},i),{},{target:aa.FULLSCREEN})),Object(c.f)(s.c.Video)},jumpFailHandler:()=>{l()},jumpHook:e=>Object(_.a)(e,!0),customStyle:{width:"100%",height:"100%"},"data-e2e":"PhotomodeContainer-index-SmartWrapperExtension"})})]})]})}),oa=r(80);function sa(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function la(e){for(var t=1;t{var t,r,i,o,d;const{state:u}=Object(n.useConnect)(),{projectSpecialConfig:p={}}=u.source,b=u.theme.isMobileView,{imagePostInfo:m,authorInfos:f,authorStats:g,referrer:h,isStrategyAvailable:j,jumpFailHandler:O,postId:v,itemInfos:y,musicInfos:x}=e,[w,P]=Object(a.useState)(s.d.MOBILE),E=null===(t=p.videoStyleConfig)||void 0===t?void 0:t.ratio,k=null!=E?E:325/563;Object(a.useEffect)(()=>{Object(c.d)(),P(s.d.MOBILE)},[]);const S={page_name:l.k.PHOTOMODE_PAGE,enter_from:l.k.PHOTOMODE_PAGE,video_id:v,url:u.router.link},C={videoData:{itemInfos:y,authorInfos:f},logoLink:oa.d,logParams:{}};return Object(H.jsx)(Wn,{ratio:k,"data-e2e":"EmbedPhotomode-index-StyledRatio",children:Object(H.jsxs)(Hn,{"data-testid":"photomode-component","data-e2e":"EmbedPhotomode-index-Container",children:[Object(H.jsx)(Nn,{referrer:h,isStrategyAvailable:j,jumpFailHandler:O,responsiveType:w,authorInfos:f,authorStats:g,teaParams:S,postId:y.id,"data-e2e":"EmbedPhotomode-index-Profile"}),Object(H.jsx)(ia,{referrer:h,imageUrls:null!==(r=null==m||null===(i=m.displayImages)||void 0===i?void 0:i.map(e=>e.urlList[0]))&&void 0!==r?r:[],audioUrl:null!==(o=null==x||null===(d=x.playUrl)||void 0===d?void 0:d[0])&&void 0!==o?o:"",isStrategyAvailable:j,jumpFailHandler:O,responsiveType:w,authorInfos:f,teaParams:S,postId:v,"data-e2e":"EmbedPhotomode-index-PhotomodeContainer"}),Object(H.jsx)(ur,la(la({referrer:h,isStrategyAvailable:j,jumpFailHandler:O,isMobile:b},C),{},{"data-e2e":"EmbedPhotomode-index-Layer"}))]})})});function da(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function ua(e){for(var t=1;t{var t,r,i,o;const{state:d}=Object(n.useConnect)(),{projectSpecialConfig:u={}}=d.source,p=d.theme.isMobileView,{videoData:b,isCommerce:m,isCommonCommerce:h,$appType:j,referrer:O,isStrategyAvailable:v,jumpFailHandler:y,videoData:{itemInfos:x={},itemInfos:{video:{videoMeta:{width:w,height:P}={width:0,height:0}},id:E},authorInfos:k={},authorStats:S={},imagePostInfo:C=null,musicInfos:I={}}={},shareUser:T,appId:R}=e,[_,A]=Object(a.useState)(!1),[L,D]=Object(a.useState)(!1),[V,N]=Object(a.useState)(""),[W,F]=Object(a.useState)(s.d.MOBILE),M=w/P,z=(null===(t=u.videoStyleConfig)||void 0===t?void 0:t.ratio)||Math.min(M,325/563),B=null===(r=u.videoStyleConfig)||void 0===r?void 0:r.width,U=null===(i=u.videoStyleConfig)||void 0===i?void 0:i.minWidth;Object(a.useEffect)(()=>{Object(c.d)(),F(s.d.MOBILE)},[]);const G=e=>A(Object(g.o)(e)),q=e=>t=>{var r;null==t||null===(r=t.stopPropagation)||void 0===r||r.call(t);const{videoMaskType:n}=Object(g.n)(b,L);n===e&&(D(!0),Object(c.c)(n,E))},$={videoData:b,isPlaying:_,isMobile:p,appType:j,logParams:{url:d.router.link},playerState:V,responsiveType:W,referrer:O,isStrategyAvailable:v,jumpFailHandler:y},Y=m||h||u.hiddenCommerceBannerContent;return Object(H.jsxs)(ba,{style:{maxWidth:325,width:B,minWidth:U,border:null===(o=u.videoStyleConfig)||void 0===o?void 0:o.border},"data-testid":"embed-video","data-e2e":"video-v2-EmbedVideo-EmbedVideoWrapper",children:[C?Object(H.jsx)(ca,{postId:E,itemInfos:x,authorInfos:k,authorStats:S,imagePostInfo:C,referrer:O,isCommerce:m,isCommonCommerce:h,$appType:j,appId:R,isStrategyAvailable:v,musicInfos:I,jumpFailHandler:y,"data-e2e":"video-v2-EmbedVideo-EmbedPhotomode"}):(()=>{const e={shareUser:T,appId:R},t={isCommerce:m,isCommonCommerce:h},r={page_name:l.k.PAGE,enter_from:l.k.PAGE,url:d.router.link},n={videoData:b,logoLink:l.i,logParams:r},{videoMaskType:a=f.g.GeneralSensitive,showVideoMask:i,videoMaskTitle:o,videoMaskDesc:s,icon:c,videoMaskConfirmBtnText:u,videoMaskCancelBtnText:j}=Object(g.n)(b,L);return Object(H.jsxs)(ma,{ratio:z,"data-e2e":"video-v2-EmbedVideo-StyledRatio",children:[Object(H.jsx)(Hr,{onEventChange:G,recommendParams:e,videoInfos:x,commerceConfig:t,logParams:r,layerProps:n,authorInfos:k,authorStats:S,onPlayerStateChange:N,responsiveType:W,isMobile:p,appId:R,referrer:O,isStrategyAvailable:v,jumpFailHandler:y,showVideoMask:i,"data-e2e":"video-v2-EmbedVideo-Player"}),i&&Object(H.jsx)(En,{videoMaskType:a,groupId:E,icon:c,title:o,desc:s,confirmText:u,cancelText:j,onConfirm:q(f.g.PhotoSensitive),onCancel:q(f.g.GeneralSensitive),"data-e2e":"video-v2-EmbedVideo-VideoMask"})]})})(),!Y&&Object(H.jsx)(se,ua(ua({},$),{},{"data-e2e":"video-v2-EmbedVideo-Card"}))]})});const ba=Object(n.styled)("div",{target:"e1b4x27k1"})({name:"vptvdy",styles:"position:relative;overflow:hidden;margin:0 auto;min-width:325px;height:fit-content;border:1px solid rgb(22 24 35 / 12%);box-sizing:border-box;border-radius:8px;width:540px"}),ma=Object(n.styled)(gn,{target:"e1b4x27k0"})({name:"155ze66",styles:"position:relative;width:100%;margin:auto;border-radius:8px 8px 0 0"});var fa={name:"vt3tc7",styles:"/* @styled-jsx=global */#main{display:flex;align-items:center;justify-content:space-between;flex-direction:column;width:100%;height:100%;letter-spacing:0;}html[lang^='vi'] *{font-family:'IBM Plex Sans',Arial,Tahoma,TikTokFont,PingFangSC,sans-serif,'Segoe UI Emoji','Noto Emoji'!important;}"};t.default=Object(n.connect)(({state:e,libraries:t})=>{const{strategy:r}=e.source.data,{referrer:a}=e.source,i=e.source.get(e.router.link),{statusCode:p=0,videoData:b,$appType:m,isCommerce:f,isCommonCommerce:h,appId:j=1233,query:O}=i||{},v=Boolean(r),{defaultSchemeParams:y,defaultOnelinkParams:x}=(w=b.itemInfos.id,{defaultSchemeParams:{page_name:"embed_video",referer:s.j.Video,utm_campaign:s.h.WebOther},defaultOnelinkParams:{pid:s.h.WebOther,af_adset:s.j.Video,af_ad_id:"others",c:"embed_video_"+w}});var w;if(Object(d.a)({intersectionHandler:()=>{const t={page_name:l.k.PAGE,enter_from:l.k.PAGE,url:e.router.link,video_id:b.itemInfos.id};Object(c.g)(l.k.EVENTS.EMBED_VIDEO_SHOW,t)},observedElementId:l.k.OBSERVER,threshold:[.5]}),null!=O&&O.flag&&null!=O&&O.token){const t=Object(g.a)(O.token,"101112131415161718191a1b1c1d1e1f");Object(g.s)(t,36e5)&&(Object.assign(e.source,{projectSpecialConfig:u[null==O?void 0:O.flag]}),Object.assign(e.theme.sourceComponents={partnerSource:"cc"}))}return Object(H.jsx)(o.a,{strategy:r,enableApiOptimization:!0,experimentalUseAppLink:!0,checkOpenTime:50,fallbackURLParams:x,schemeParams:y,"data-e2e":"video-v2-home-StrategyProvider",children:Object(H.jsxs)(ga,{id:l.k.OBSERVER,"data-e2e":"video-v2-home-ContainerWrapper",children:[Object(H.jsx)(n.Global,{styles:fa,"data-e2e":"video-v2-home-Global"}),Object(H.jsx)(pa,{referrer:a,statusCode:p,videoData:b,isCommerce:f,isCommonCommerce:h,$appType:m,appId:j,isStrategyAvailable:v,jumpFailHandler:()=>{Object(c.e)(s.c.Video)},"data-e2e":"video-v2-home-EmbedVideo"})]})})});const ga=Object(n.styled)("div",{target:"e1osuh9m0"})({name:"g03djc",styles:"display:flex;justify-content:center;width:100%;background:#fff;flex:1 1 auto"})},781:function(e,t,r){"use strict";r.r(t);var n=r(2),a=r(0),i=r.n(a),o=r(57),s=r(10),l=r.n(s);r(25),r(4),r(5);var c=r(962),d=r(82),u=r(14),p=r(171),b=r(132),m=r(966),f=r(19),g=r(1);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function j(e){for(var t=1;t{const t=i.a.forwardRef((t,r)=>{const[n,i]=Object(a.useState)(!1);return Object(a.useEffect)(()=>{if("undefined"==typeof window)return;if(!Object(f.a)())return;let e;const t=()=>{e=setTimeout(()=>{i(!0),console.log("longTimeNoTouch")},3e3)},r=()=>{i(!1),clearTimeout(e),t()};return window.document.body.addEventListener("click",r),t(),()=>{window.document.body.removeEventListener("click",r),clearTimeout(e)}},[]),Object(g.jsx)(O.Provider,{value:n,children:Object(g.jsx)(e,j(j({},t),{},{ref:r,"data-e2e":"hoc-with-long-time-no-touch-Component"}))})});return t.displayName="WithLongTimeNoTouch",t};const y=()=>Object(a.useContext)(O);var x=r(964);function w(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function P(e){for(var t=1;t{}});var k=e=>{const t=i.a.forwardRef((t,r)=>{const n=Object(a.useRef)(),i=Object(x.b)(n);((e,{logParams:t},r)=>{const n=Object(a.useRef)(0),i=()=>{n.current=Date.now()},s=()=>{Object(f.h)(o.l.EVENTS.EMBED_VIDEO_PLAY_TIME,P(P({},t),{},{duration:Date.now()-n.current}))};Object(a.useEffect)(()=>{switch(r){case"play":i();break;case"pause":case"ended":case"error":s()}},[r]),Object(a.useEffect)(()=>{const e=()=>{"playing"===r&&("hidden"===document.visibilityState?s():"visible"===document.visibilityState&&i())};return document.addEventListener("visibilitychange",e),()=>{document.removeEventListener("visibilitychange",e)}},[r])})(0,t,i),((e,{logParams:t},r)=>{Object(a.useEffect)(()=>{"ended"===r&&Object(f.h)(o.l.EVENTS.FINISH,t)},[t,r])})(0,t,i),((e,{logParams:t})=>{Object(a.useEffect)(()=>{Object(f.h)(o.l.EVENTS.EMBED_VIDEO_SHOW,t)},[])})(0,t);const s=Object(a.useMemo)(()=>({tap:e=>{var r;Object(f.h)(o.l.EVENTS.TAP,P(P({},null!==(r=t.logParams)&&void 0!==r?r:{}),{},{target:e}))}}),[t.logParams]);return Object(g.jsx)(E.Provider,{value:s,children:Object(g.jsx)(e,P(P({},t),{},{ref:e=>{e&&(n.current=e,Object(x.a)(r)(e))},"data-e2e":"hoc-with-tea-Component"}))})});return t.displayName="WithTea",t},S=r(976);function C(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function I(e){for(var t=1;te.shouldHide?`calc(-100% - ${m.a.paddingY} - 1rem) `:"0",");transition:transform 0.3s ease;height:5vh;max-width:calc(100% - ",m.a.paddingY,"*2 - 10vh);img.avatar{height:100%;border-radius:10000px;margin-right:1vw;object-fit:cover;}:hover,:focus{text-decoration:none;}div.text{display:flex;flex-direction:column;height:5vh;max-width:calc(100% - 5vh);.unique-id:hover,.unique-id:focus,.nick-name:hover,.nick-name:focus{text-decoration:underline;}div.nick-name{height:2.6vh;display:flex;align-items:center;color:rgb(255 255 255);span{font-size:2.6vh;font-weight:var(--tux-fontWeightSemibold);}span.nick-name-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}}div.unique-id{height:2.4vh;display:inline-block;font-size:2.4vh;color:rgb(255 255 255 / 90%);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}}"),R=Object(n.connect)(({state:e,videoData:t})=>{const r=Object(a.useContext)(E),n=y(),{source:{referrer:i}}=e,s=e.theme.globalParams,{authorInfos:{covers:l=[],nickName:c,uniqueId:m="",userId:f=""}={},itemInfos:{id:h=""}={}}=t,j={referer_video_id:h},O=Object(S.a)(t.itemInfos);return Object(g.jsxs)(T,{shouldHide:n,refer:u.j.Video,referrer_url:i,redirectLink:Object(p.e)({uniqueId:m,globalQueryParams:s(o.l.TARGETS.MASKING),optionalParams:j}),target:d.b.USER_WRAPPER,teaTarget:o.l.TARGETS.NAME,gd_label:u.m.User,id:f,pid:u.h.Video,jumpHook:e=>{},linkOnClickHandler:()=>{},jumpStartHandler:()=>{Object(b.f)(u.c.Video)},jumpFailHandler:()=>{},"data-e2e":"hoc-with-author-profile-Container",children:[Object(g.jsx)("img",{className:"avatar",src:l[0],alt:"avatar","data-e2e":"hoc-with-author-profile-img"}),Object(g.jsxs)("div",{className:"text",onClick:()=>r.tap(o.l.TARGETS.CREATOR_NAME),"data-e2e":"hoc-with-author-profile-div",children:[Object(g.jsxs)(A,{className:"nick-name","data-e2e":"hoc-with-author-profile-Row",children:[Object(g.jsx)("span",{className:"nick-name-text","data-e2e":"hoc-with-author-profile-span",children:c}),O&&Object(g.jsx)(L,{"data-e2e":"hoc-with-author-profile-CardBCBOLabel",children:O})]}),Object(g.jsx)(A,{className:"unique-id","data-e2e":"hoc-with-author-profile-Row",children:m})]})]})});var _=e=>{const t=i.a.forwardRef((t,r)=>{const{videoData:n}=t;return Object(g.jsxs)(g.Fragment,{children:[Object(g.jsx)(e,I(I({},t),{},{ref:r,"data-e2e":"hoc-with-author-profile-Component"})),Object(g.jsx)(R,{videoData:n,"data-e2e":"hoc-with-author-profile-Profile"})]})});return t.displayName="WithAuthorProfile",t};const A=Object(n.styled)("div",{target:"e10xsdio1"})({name:"ho1qnd",styles:"display:flex;flex-direction:row"}),L=Object(n.styled)("span",{target:"e10xsdio0"})("text-decoration:none!important;font-weight:500;border-radius:4px;margin-left:0.5vw;background:rgba(255 255 255 / 12%);font-size:clamp(",6/16,"rem, 1.8vh, min(1.8vh, 2.4vw));color:rgba(255 255 255 / 100%);");let D,V;!function(e){e[e.VPA=0]="VPA",e[e.WARN=1]="WARN",e[e.NOTICE=2]="NOTICE"}(D||(D={})),function(e){e.Yes="1",e.No="0"}(V||(V={}));var N=r(965);function W(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function H(e){for(var t=1;t{const t=i.a.forwardRef((t,r)=>{const{customOptions:{loop:n},logParams:i}=t,s=Object(a.useRef)();return Object(a.useEffect)(()=>{let e;const t=Object(N.a)(s)([["ended",()=>{n===V.Yes&&(e=setTimeout(()=>{var e,t;null===(e=s.current)||void 0===e||null===(t=e.play)||void 0===t||t.call(e),Object(b.g)(o.l.EVENTS.AUTO_REPLAY,i)},1e3))}],["play",()=>clearTimeout(e)]]);return()=>{null==t||t(),clearTimeout(e)}},[i,n,s]),Object(g.jsx)(e,H(H({},t),{},{ref:e=>{e&&(s.current=e,Object(x.a)(r)(e))},"data-e2e":"hoc-with-auto-replay-Component"}))});return t.displayName="WitAutoReplay",t};function M(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function z(e){for(var t=1;t{const t=i.a.forwardRef((t,r)=>{const i=Object(a.useRef)(),s=Object(x.b)(i),{state:l}=Object(n.useConnect)(),c=l.theme.globalParams,{videoData:d}=t,{authorInfos:{uniqueId:u=""}={},itemInfos:{id:b=""}={}}=d,m=Object(p.f)({uniqueId:u,videoId:b,globalQueryParams:c(o.l.TARGETS.CARD_PLAY),optionalParams:{referer_video_id:b}});return Object(a.useEffect)(()=>{if(!Object(f.a)())return Object(N.a)(i)([["click",()=>{if("ended"===s)window.open(m);else if("play"===s||"playing"===s){var e,t;null===(e=i.current)||void 0===e||null===(t=e.pause)||void 0===t||t.call(e)}else{var r,n;null===(r=i.current)||void 0===r||null===(n=r.play)||void 0===n||n.call(r)}}]])},[s,m]),Object(g.jsx)(e,z(z({},t),{},{ref:e=>{e&&(i.current=e,Object(x.a)(r)(e))},"data-e2e":"hoc-with-click-control-Component"}))});return t.displayName="WithClickControl",t},U=r(973),G=r.n(U);function q(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function $(e){for(var t=1;t{const t=i.a.forwardRef((t,r)=>{var n,i,s;const l=Object(a.useContext)(E),[c,d]=Object(a.useState)(!1),u=Object(a.useRef)(),p=Object(x.b)(u),b=(null===(n=t.customOptions)||void 0===n?void 0:n.require_init_ui)===V.Yes,m=(null===(i=t.customOptions)||void 0===i?void 0:i.autoplay)===V.Yes,f=(null===(s=t.customOptions)||void 0===s?void 0:s.directplay)===V.Yes;Object(a.useEffect)(()=>{if(!u.current)return;const e=()=>d(!0);return u.current.addEventListener("playing",e),()=>{var t;null===(t=u.current)||void 0===t||t.removeEventListener("playing",e)}},[]),Object(a.useEffect)(()=>{u.current&&(m&&(u.current.muted=!0,h()),f&&j())},[]);const h=()=>{var e,t;d(!0),null===(e=u.current)||void 0===e||null===(t=e.play)||void 0===t||t.call(e),l.tap(o.l.TARGETS.PLAY)},j=()=>{var e,t;h();const r=new Event("play"),n=new Event("playing");null===(e=u.current)||void 0===e||e.dispatchEvent(r),null===(t=u.current)||void 0===t||t.dispatchEvent(n)};return Object(g.jsxs)(K.Provider,{value:c,children:[Object(g.jsx)(e,$($({},t),{},{ref:e=>{e&&(u.current=e,Object(x.a)(r)(e))},"data-e2e":"hoc-with-init-click-Component"})),(!c&&b||"pause"===p)&&Object(g.jsx)(Q,{onClick:h,"data-e2e":"hoc-with-init-click-Container",children:Object(g.jsx)(Y,{"data-e2e":"hoc-with-init-click-PlayButton",children:Object(g.jsx)("img",{className:"play-icon",src:G.a,"data-e2e":"hoc-with-init-click-img"})})})]})});return t.displayName="WithInitClick",t},Z=r(1010),J=r.n(Z),ee=r(1011),te=r.n(ee),re=r(978),ne=r.n(re),ae=r(1012),ie=r.n(ae),oe=r(979),se=r.n(oe),le=r(980),ce=r.n(le),de=r(1013),ue=r.n(de);const pe=Object(n.styled)("span",{target:"e12bgsfa10"})({name:"gqhlw6",styles:"display:inline-block;width:clamp(1rem, 5vh, 2rem);height:clamp(1rem, 5vh, 2rem);margin-right:1vw;cursor:pointer;background-size:contain;background-position:center;background-repeat:no-repeat"}),be=Object(n.styled)("div",{target:"e12bgsfa9"})("position:absolute;left:0;bottom:0;right:0;display:flex;align-items:center;flex-wrap:wrap;z-index:",m.b.withControls,";padding:max(0.5rem, 1vh) max(0.75rem, 1.5vh);transition:transform 0.3s ease;"),me={playing:`url(${ie.a})`,paused:`url(${G.a})`,ended:`url(${se.a})`},fe=Object(n.styled)(pe,{target:"e12bgsfa8"})("background-image:",e=>me[e.playingStatus],";background-size:160% 160%;"),ge=Object(n.styled)(pe,{target:"e12bgsfa7"})("background-image:",e=>e.muted?`url(${ne.a}) `:`url(${ce.a}) `,";background-size:200% 200%;"),he=Object(n.styled)(pe,{target:"e12bgsfa6"})("background-image:",e=>e.fullscreen?`url(${J.a}) `:`url(${te.a}) `,";"),je=Object(n.styled)("span",{target:"e12bgsfa5"})({name:"18mmp0b",styles:"color:rgb(255 255 255 / 75%);font-family:var(--tux-fontFamilyParagraph);font-weight:400;font-size:clamp(0.5rem, 4vmin, 1.6rem)"}),Oe=Object(n.styled)("div",{target:"e12bgsfa4"})({name:"11vwntr",styles:"width:100%;display:flex;justify-content:space-between;align-items:center"}),ve=Object(n.styled)("div",{target:"e12bgsfa3"})({name:"9xa5cd",styles:"display:flex;align-items:center;overflow-x:hidden"}),ye=Object(n.styled)(pe,{target:"e12bgsfa2"})("background-image:url(",ue.a,");width:clamp(0.6rem, 3vh, 1.2rem)!important;margin-right:0!important;background-size:120% 120%!important;"),xe=Object(n.styled)("div",{target:"e12bgsfa1"})({name:"17j7aao",styles:"font-size:clamp(0.5rem, 2.4vh, 1rem);white-space:nowrap;overflow:hidden;text-overflow:ellipsis"}),we=Object(n.styled)("div",{target:"e12bgsfa0"})({name:"xdlc0o",styles:"width:100%;display:flex;align-items:center;color:rgb(255 255 255 / 90%);text-shadow:0 1px 1px rgb(0 0 0 / 12%);font-weight:400"});var Pe=e=>{const{videoData:{musicInfos:{musicName:t,authorName:r}={}}}=e,n=Object(a.useContext)(E);return Object(g.jsxs)(we,{onClick:()=>n.tap(o.l.TARGETS.SONG_NAME),"data-e2e":"with-controls-ControlMusicInfo-StyledMusicInfoContainer",children:[Object(g.jsx)(ye,{"data-e2e":"with-controls-ControlMusicInfo-StyledMusicIcon"}),Object(g.jsx)(xe,{"data-e2e":"with-controls-ControlMusicInfo-StyledMusicText",children:[t,r].join(" - ")})]})},Ee=(r(977),r(110));const ke="clamp(0.06rem, 0.5vh, 0.24rem)",Se=Object(n.styled)("div",{target:"eui207n4"})({width:"100%",height:ke,flex:"1 1 auto",position:"relative"},""),Ce=Object(n.styled)("div",{target:"eui207n3"})({height:ke,width:"100%",backgroundColor:"rgb(255 255 255 / 20%)",position:"absolute",left:"0",top:"50%",transform:"translateY(-50%)",cursor:"pointer",touchAction:"none"},""),Ie=Object(n.styled)("div",{target:"eui207n2"})(()=>({height:ke,backgroundColor:"#FE2C55",position:"absolute",top:"50%",transform:"translateY(-50%)",cursor:"pointer",transformOrigin:"left",borderBottom:"1px solid rgb(22 24 35 / 12%)",touchAction:"none"}),""),Te=Object(n.styled)("div",{target:"eui207n1"})(({isRTL:e})=>({display:"none",width:"clamp(0.18rem, 1.5vh, 0.72rem)",height:"clamp(0.18rem, 1.5vh, 0.72rem)",backgroundColor:"#FE2C55",borderRadius:"50%",boxShadow:"0 0 4px rgb(0 0 0 / 10%)",position:"absolute",top:"50%",transform:`translateX(${e?"50%":"-50%"}) translateY(-50%)`,cursor:"pointer",zIndex:10,touchAction:"none"}),""),Re=Object(n.styled)("div",{target:"eui207n0"})(({show:e})=>({width:"100%",position:"absolute",transform:"translateY(20px)",bottom:"0",opacity:"1",zIndex:"10",height:"43px",transition:"opacity .3s",cursor:"initial",display:"flex",alignItems:"center",visibility:e?"visible":"hidden",[":hover "+Ce]:{height:"clamp(0.09rem, 0.75vh, 0.36rem)"},[":hover "+Ie]:{height:"clamp(0.09rem, 0.75vh, 0.36rem)"},[":hover "+Te]:{display:"block"}}),""),_e=Object(a.memo)((function(e){const t=Object(a.useRef)(null),r=Object(a.useRef)(null),n=Object(a.useRef)(null),i=Object(a.useRef)(null),[o,s]=Object(a.useState)(!1),[l,c]=Object(a.useState)(!1),{videoRef:d,isRTL:u,progress:p,show:b,className:m,videoSeek:f}=e,{percent:h,bindDrag:j,seek:O}=Object(Ee.r)({progressRef:r,circleRef:n,barRef:i,initialPercent:0,draggingStateCb:s,draggingPercentCb:f,direction:u?"rtl":"ltr"});Object(a.useEffect)(()=>{var e,t;null===(e=d.current)||void 0===e||e.addEventListener("seeked",()=>{setTimeout(()=>{c(!1)},0)}),null===(t=d.current)||void 0===t||t.addEventListener("seeking",()=>{c(!0)})},[d.current,c]);const v=o||l?`calc(${100*h}%`:`calc(${p})`,y=u?{right:v}:{left:v};return Object(g.jsx)(Re,{show:b,onPointerDown:e=>{e.stopPropagation()},className:m,"data-e2e":"video-control-index-DivVideoControlContainer",children:Object(g.jsxs)(Se,{ref:t,"data-e2e":"video-control-index-DivSeekBarContainer",children:[Object(g.jsx)(Ce,{ref:r,onClick:O,onPointerDown:j,"data-e2e":"video-control-index-DivSeekBarProgress"}),Object(g.jsx)(Te,{ref:n,style:y,onPointerDown:j,isRTL:u,"data-e2e":"video-control-index-DivSeekBarCircle"}),Object(g.jsx)(Ie,{ref:i,style:{width:v},onClick:O,onPointerDown:j,"data-e2e":"video-control-index-DivSeekBar"})]})})}));const Ae=Object(n.styled)(_e,{target:"e1tdj8n0"})({name:"1dbln2h",styles:"position:relative!important;visibility:inherit!important;transform:none!important;height:clamp(0.5rem, 4.8vh, 2rem)!important"});var Le=e=>{const{playerRef:t}=e,r=Object(a.useContext)(E),{currentTime:n,duration:i,setCurrentTime:s}=Object(N.b)(e),l=Math.min(100,i?n/i*100:0).toFixed(2)+"%",c=Object(a.useCallback)(e=>{const n=i*e;s(n),t.current&&(t.current.currentTime=n),r.tap(o.l.TARGETS.PROGRESS_BAR)},[i,t,s,r]);return Object(g.jsx)(Ae,{className:"",progress:l,videoRef:t,show:!0,isRTL:!1,videoSeek:c,"data-e2e":"with-controls-ControlSeekBar-StyledVideoControl"})};var De=e=>{const{currentTime:t,duration:r}=Object(N.b)(e);return Object(g.jsx)(je,{"data-e2e":"with-controls-ControlDuration-StyledTimestamp",children:[t,r].map(e=>(e=>{const t=Math.floor(e%60);return[Math.floor(e/60),t].map(e=>((e,t=2)=>`${"0".repeat(t)}${e}`.slice(-t))(e)).join(":")})(e)).join("/")})};const Ve={fullscreenEnabled:0,fullscreenElement:1,requestFullscreen:2,exitFullscreen:3,fullscreenchange:4,fullscreenerror:5,fullscreen:6},Ne=["webkitFullscreenEnabled","webkitFullscreenElement","webkitRequestFullscreen","webkitExitFullscreen","webkitfullscreenchange","webkitfullscreenerror","-webkit-full-screen"],We=["mozFullScreenEnabled","mozFullScreenElement","mozRequestFullScreen","mozCancelFullScreen","mozfullscreenchange","mozfullscreenerror","-moz-full-screen"],He=["msFullscreenEnabled","msFullscreenElement","msRequestFullscreen","msExitFullscreen","MSFullscreenChange","MSFullscreenError","-ms-fullscreen"],Fe=()=>"undefined"!=typeof window&&void 0!==window.document?window.document:{},Me=()=>{const e=Fe();return"fullscreenEnabled"in e&&Object.keys(Ve)||Ne[0]in e&&Ne||We[0]in e&&We||He[0]in e&&He||[]};var ze={requestFullscreen:e=>e[Me()[Ve.requestFullscreen]](),requestFullscreenFunction:e=>e[Me()[Ve.requestFullscreen]],get exitFullscreen(){const e=Fe();return e[Me()[Ve.exitFullscreen]].bind(e)},get fullscreenPseudoClass(){return":"+Me()[Ve.fullscreen]},addEventListener:(e,t,r)=>Fe().addEventListener(Me()[Ve[e]],t,r),removeEventListener:(e,t,r)=>Fe().removeEventListener(Me()[Ve[e]],t,r),get fullscreenEnabled(){return Boolean(Fe()[Me()[Ve.fullscreenEnabled]])},set fullscreenEnabled(e){},get fullscreenElement(){return Fe()[Me()[Ve.fullscreenElement]]},set fullscreenElement(e){}};var Be=()=>{const e=Object(a.useContext)(E),[t,r]=Object(a.useState)(!1),n=ze.fullscreenEnabled;return Object(a.useEffect)(()=>{const e=()=>{r(Boolean(document.fullscreenElement))};return document.documentElement.addEventListener("fullscreenchange",e),()=>document.documentElement.removeEventListener("fullscreenchange",e)},[]),n?Object(g.jsx)(he,{fullscreen:t,onClick:()=>{ze.fullscreenElement?ze.exitFullscreen():ze.requestFullscreen(document.documentElement),e.tap(o.l.TARGETS.FULLSCREEN)},"data-e2e":"with-controls-ControlFullscreen-ControllerToggleFullscreen"}):null};var Ue=e=>{const t=Object(a.useContext)(E),{playerRef:r}=e,n=Object(x.b)(r);let i="playing";"ended"===n?i="ended":"play"===n||"playing"===n||(i="paused");const s=Object(a.useMemo)(()=>({playing:()=>{var e,n;null===(e=r.current)||void 0===e||null===(n=e.pause)||void 0===n||n.call(e),t.tap(o.l.TARGETS.PAUSE)},paused:()=>{var e,n;null===(e=r.current)||void 0===e||null===(n=e.play)||void 0===n||n.call(e),t.tap(o.l.TARGETS.PLAY)},ended:()=>{var e,n;null===(e=r.current)||void 0===e||null===(n=e.play)||void 0===n||n.call(e),t.tap(o.l.TARGETS.REPLAY)}}),[r,t]);return Object(g.jsx)(fe,{playingStatus:i,onClick:s[i],"data-e2e":"with-controls-ControlPlay-ControllerToggleVideo"})};var Ge=e=>{const{playerRef:t}=e,r=Object(a.useContext)(E),[n,i]=Object(a.useState)(()=>{var e;return Boolean(null===(e=t.current)||void 0===e?void 0:e.muted)});Object(a.useEffect)(()=>Object(N.a)(t)([["volumechange",()=>{var e;i(Boolean(null===(e=t.current)||void 0===e?void 0:e.muted))}]]),[t]);return Object(g.jsx)(ge,{muted:n,onClick:()=>{const e=t.current;e&&(e.muted=!e.muted,r.tap(o.l.TARGETS.SWITCH_SOUND))},"data-e2e":"with-controls-ControlVolume-ControllerToggleSound"})};function qe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function $e(e){for(var t=1;te===V.Yes;var Qe=e=>{const{customOptions:{enable_play_button:t,enable_fullscreen:r,enable_volume_control:n,enable_timestamp:a}}=e;return Object(g.jsxs)(Oe,{"data-e2e":"with-controls-ControlButtons-StyledControlButtonsContainer",children:[Object(g.jsxs)(ve,{"data-e2e":"with-controls-ControlButtons-StyledControlButtonsSubContainer",children:[Ye(t)?Object(g.jsx)(Ue,$e($e({},e),{},{"data-e2e":"with-controls-ControlButtons-ControlPlay"}),"play"):null,Ye(a)?Object(g.jsx)(De,$e($e({},e),{},{"data-e2e":"with-controls-ControlButtons-ControlDuration"}),"duration"):null]}),Object(g.jsxs)(ve,{"data-e2e":"with-controls-ControlButtons-StyledControlButtonsSubContainer",children:[Ye(n)?Object(g.jsx)(Ge,$e($e({},e),{},{"data-e2e":"with-controls-ControlButtons-ControlVolume"}),"sound"):null,Ye(r)?Object(g.jsx)(Be,$e($e({},e),{},{"data-e2e":"with-controls-ControlButtons-ControlFullscreen"}),"fullscreen"):null]})]},"control_buttons")};function Ke(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Xe(e){for(var t=1;te===V.Yes;var Je=e=>{const t=i.a.forwardRef((t,r)=>{const{customOptions:{enable_progress_bar:n,enable_music_info:i}}=t,o=Object(a.useContext)(K),s=y(),l=Object(a.useRef)(),c=!o||s;return Object(g.jsxs)(g.Fragment,{children:[Object(g.jsx)(e,Xe(Xe({},t),{},{ref:e=>{e&&(l.current=e,Object(x.a)(r)(e))},"data-e2e":"with-controls-index-Component"})),Object(g.jsx)(be,{onClick:e=>{e.stopPropagation()},style:{transform:c?"translateY(100%)":"none"},"data-e2e":"with-controls-index-Bar",children:(()=>{const e=Xe(Xe({},t),{},{playerRef:l});return[Ze(i)?Object(g.jsx)(Pe,Xe(Xe({},e),{},{"data-e2e":"with-controls-index-ControlMusicInfo"}),"music_info"):null,Ze(n)?Object(g.jsx)(Le,Xe(Xe({},e),{},{"data-e2e":"with-controls-index-ControlSeekBar"}),"seek_bar"):null,Object(g.jsx)(Qe,Xe(Xe({},e),{},{"data-e2e":"with-controls-index-ControlButtons"}),"control_buttons")]})()})]})});return t.displayName="WithControls",t},et=r(1014),tt=r(8),rt=r.n(tt);const nt=["customOptions"];function at(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function it(e){for(var t=1;t{const t=Object(a.forwardRef)((t,r)=>{const{customOptions:n}=t,i=rt()(t,nt),o=Object(a.useMemo)(()=>{return e=n,t=ot,Object.keys(t).reduce((e,r)=>{var n;return e[r]=null!==(n=e[r])&&void 0!==n?n:t[r],e},it({},e));var e,t},[n]);return Object(g.jsx)(e,it(it({},i),{},{customOptions:o,"data-e2e":"hoc-with-default-custom-options-Component"}))});return t.displayName="WithDefaultCustomOptions",t};function lt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function ct(e){for(var t=1;tObject(g.jsxs)("svg",{viewBox:"0 0 210 210",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-e2e":"hoc-with-loading-svg",children:[Object(g.jsx)("path",{d:"M144.521 6H111.374V140.87C111.374 156.939 98.6256 170.139 82.7605 170.139C66.8955 170.139 54.1467 156.939 54.1467 140.87C54.1467 125.087 66.6121 112.174 81.9106 111.6V77.7391C48.1973 78.313 21 106.148 21 140.87C21 175.878 48.7639 204 83.0438 204C117.324 204 145.088 175.591 145.088 140.87V71.7131C157.553 80.8957 172.852 86.3478 189 86.6348V52.7739C164.069 51.913 144.521 31.2522 144.521 6Z",fill:"url(#paint0_linear_5871_55569)",className:"loading-logo","data-e2e":"hoc-with-loading-path"}),Object(g.jsx)("defs",{"data-e2e":"hoc-with-loading-defs",children:Object(g.jsxs)("linearGradient",{id:"paint0_linear_5871_55569",x1:"105",y1:"6",x2:"105",y2:"204",gradientUnits:"userSpaceOnUse","data-e2e":"hoc-with-loading-linearGradient",children:[Object(g.jsx)("stop",{offset:"0",stopColor:"white","data-e2e":"hoc-with-loading-stop"}),Object(g.jsx)("stop",{offset:"1",stopColor:"white",stopOpacity:"0.5","data-e2e":"hoc-with-loading-stop-5"})]})})]}),ut=Object(n.styled)("div",{target:"e1khkb10"})("position:absolute;width:100%;height:100%;background-color:#000;color:#fff;z-index:",m.b.withLoading,";display:flex;justify-content:center;align-items:center;&>svg{width:140px;height:140px;@keyframes faded{from{fill-opacity:0.2;}to{fill-opacity:0.05;}}.loading-logo{animation:faded 800ms ease-in infinite alternate;}}");var pt=e=>{const t=i.a.forwardRef((t,r)=>{const n=Object(a.useRef)(),[i,o]=Object(a.useState)(!0),s=i;return Object(a.useEffect)(()=>{const e=n.current;if(e)return e&&e.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?o(!1):setTimeout(()=>{o(!1)},1e3),Object(N.a)(n)([["loadeddata",()=>o(!1)]])},[]),Object(g.jsxs)(g.Fragment,{children:[Object(g.jsx)(e,ct(ct({},t),{},{ref:e=>{e&&(n.current=e,Object(x.a)(r)(e))},"data-e2e":"hoc-with-loading-Component"})),s&&Object(g.jsx)(ut,{"data-e2e":"hoc-with-loading-Loading",children:Object(g.jsx)(dt,{"data-e2e":"hoc-with-loading-LoadingSVG"})})]})});return t.displayName="WithLoading",t},bt=r(972),mt=r(1015),ft=r.n(mt);let gt;!function(e){e[e.Init=-1]="Init",e[e.Ended=0]="Ended",e[e.Playing=1]="Playing",e[e.Paused=2]="Paused",e[e.Buffering=3]="Buffering"}(gt||(gt={}));class ht{constructor(){l()(this,"listeners",[]),this.listenToMessageEvent()}static getInstance(){return this.instance||(this.instance=new ht),this.instance}on(e,t){const r={type:e,callback:t};return this.listeners.push(r),()=>this.listeners=this.listeners.filter(e=>e!==r)}emit(e,t){var r;null===(r=this.getParentWindow())||void 0===r||r.postMessage({type:e,value:t,"x-tiktok-embed":!0},"*")}getParentWindow(){return"undefined"==typeof window?void 0:window.parent}listenToMessageEvent(){"undefined"!=typeof window&&window.addEventListener("message",e=>{const{data:t}=e;if("object"==typeof t&&t["x-tiktok-embed"]){const e=t;this.listeners.filter(t=>t.type===e.type).forEach(t=>t.callback(e.value))}})}}function jt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ot(e){for(var t=1;t{ht.getInstance().emit("onCurrentSecond",e),ht.getInstance().emit("onCurrentTime",{currentTime:e,duration:t})},500),yt=[["ended",()=>ht.getInstance().emit("onStateChange",gt.Ended)],["playing",()=>ht.getInstance().emit("onStateChange",gt.Playing)],["pause",()=>ht.getInstance().emit("onStateChange",gt.Paused)],["waiting",()=>ht.getInstance().emit("onStateChange",gt.Buffering)],["volumechange",e=>{var t;return ht.getInstance().emit("onMute",Boolean(null===(t=e.currentTarget)||void 0===t?void 0:t.muted))}],["timeupdate",e=>vt(e.currentTarget.currentTime,e.currentTarget.duration)]];var xt=e=>{const t=i.a.forwardRef((t,r)=>{const n=Object(a.useRef)();return Object(a.useEffect)(()=>{if(!n.current)return;const e=Object(N.a)(n)(yt);return ht.getInstance().emit("onPlayerReady",void 0),()=>{null==e||e()}},[]),Object(a.useEffect)(()=>{const e=ht.getInstance(),t=[e.on("play",()=>{var t,r;return null===(t=n.current)||void 0===t||null===(r=t.play())||void 0===r?void 0:r.catch(()=>e.emit("onError",1))}),e.on("pause",()=>{var e;return null===(e=n.current)||void 0===e?void 0:e.pause()}),e.on("seekTo",e=>n.current&&(n.current.currentTime=e)),e.on("mute",()=>n.current&&(n.current.muted=!0)),e.on("unMute",()=>n.current&&(n.current.muted=!1))];return()=>t.forEach(e=>e())},[]),Object(g.jsx)(e,Ot(Ot({ref:e=>{e&&(n.current=e,Object(x.a)(r)(e))}},t),{},{"data-e2e":"hoc-with-post-message-Component"}))});return t.displayName="WithPostMessage",t};function wt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Pt(e){for(var t=1;t{const t=Object(a.forwardRef)((t,r)=>Object(g.jsx)(Et,{"data-e2e":"hoc-with-wrapper-Wrapper",children:Object(g.jsx)(e,Pt(Pt({},t),{},{ref:r,"data-e2e":"hoc-with-wrapper-Component"}))}));return t.displayName="WithWrapper",t};const St=Object(n.styled)("div",{target:"e1cef57p3"})({name:"g4ahfd",styles:"position:absolute;overflow:hidden;width:100%;height:100%"}),Ct=Object(n.styled)("div",{target:"e1cef57p2"})({name:"7iif1r",styles:"position:relative;height:100%;width:100%;cursor:pointer"}),It=Object(n.styled)("video",{target:"e1cef57p1"})({name:"f32xs6",styles:"width:100%;height:100%;object-fit:contain;object-position:center"}),Tt=Object(n.styled)("div",{target:"e1cef57p0"})({name:"qr38wd",styles:"position:absolute;top:-2%;left:-2%;width:104%;height:104%;background-position:center center;background-repeat:no-repeat;background-size:cover;background-color:black;filter:blur(6px)"});r(276);const Rt=["play","pause"],_t=["loop","currentTime","src"];function At(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Lt(e){for(var t=1;t{const{videoData:{itemInfos:{video:{urls:r=[]}={},covers:n=[]}={}}}=e,i=r[0],o=n[0],s=Object(a.useRef)(),l=Object(a.useRef)();Object(a.useImperativeHandle)(t,()=>((e,...t)=>e.current?new Proxy(e.current,{get(e,r){if(Rt.includes(r))return(...n)=>{const a=()=>{t.forEach(e=>{var t,a;const i=null===(t=e.current)||void 0===t?void 0:t[r];null==i||null===(a=i.call)||void 0===a||a.call(i,e.current,...n)})};if("play"===r)return e.play().then(a);{var i;const t=e[r];return a(),null===(i=t.call)||void 0===i?void 0:i.call(t,e,...n)}};{const t=e[r];return"function"==typeof t?t.bind(e):t}},set:(e,r,n)=>(_t.includes(r)&&t.forEach(e=>e.current&&Reflect.set(e.current,r,n,e.current)),Reflect.set(e,r,n,e))}):e.current)(s,l),[s.current,l.current]);const c={src:i,poster:o,"webkit-playsinline":!0,playsInline:!0,preload:"auto"};return Object(g.jsxs)(St,{id:"embed-v3","data-e2e":"Player-index-EmbedPlayerContainer",children:[Object(g.jsx)(Tt,{"data-e2e":"Player-index-EmbedPlayerBlurWrapper",children:Object(g.jsx)(It,Lt(Lt({},c),{},{ref:l,muted:!0,style:{objectFit:"cover"},"data-testid":"play-video-blur","data-e2e":"Player-index-EmbedPlayerVideoItem"}))}),Object(g.jsx)(Ct,{"data-e2e":"Player-index-EmbedPlayerVideoWrapper",children:Object(g.jsx)(It,Lt(Lt({},c),{},{ref:s,"data-testid":"play-video",onError:e=>{console.log("onError",e.currentTarget.error)},"data-e2e":"Player-index-EmbedPlayerVideoItem"}))})]})});Dt.displayName="Player";var Vt=function(...e){return 0===e.length?e=>e:1===e.length?e[0]:e.reduce((e,t)=>(...r)=>e(t(...r)))}(st,k,et.a,kt,X,v,bt.b,_,pt,Je,xt,B,F)(Dt);const Nt={name:"t157k6",styles:"html{font-size:16px!important;}/* @styled-jsx=global */#main{width:100%;height:100%;letter-spacing:0;margin:0;}"};t.default=Object(n.connect)(({state:e})=>{var t;const r=e.source.get(e.router.link),{videoData:i,query:s}=r,l=Object(a.useRef)(),c=Object(a.useMemo)(()=>{var t;return{page_name:o.l.PAGE,enter_from:o.l.PAGE,url:e.router.link,video_id:null==i||null===(t=i.itemInfos)||void 0===t?void 0:t.id}},[e.router.link,null==i||null===(t=i.itemInfos)||void 0===t?void 0:t.id]);return Object(g.jsxs)(g.Fragment,{children:[Object(g.jsx)(n.Global,{styles:Nt,"data-e2e":"video-v3-home-Global"}),Object(g.jsx)(Vt,{videoData:i,customOptions:s,ref:l,logParams:c,"data-e2e":"video-v3-home-Player"})]})})},962:function(e,t,r){"use strict";var n=r(10),a=r.n(n),i=r(2),o=(r(0),r(1030)),s=r(82),l=r(1);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function d(e){for(var t=1;t{const E={id:p,gd_label:c,referrer_url:t,refer:u};a&&(E.target=a),n===s.b.VIDEO_WRAPPER&&(E.video_id=p),n===s.b.MUSIC_WRAPPER&&(E.music_id=p,delete E.id),O&&Object.keys(O).forEach(e=>{E[e]=O[e]});const{state:k}=Object(i.useConnect)();if(m){const{globalQueryParams:t={},sourceComponents:r={}}=k.theme,i=k.theme.globalParams,s=k.theme.isMobileView;let u={};if(t&&r){const{vidab:e,ipSource:n}=r;u=JSON.parse(JSON.stringify(t)),u.vidab=e||"null",u.utm_source=n||"null",u.target=null!=a?a:"null"}return Object(l.jsx)("div",{role:"link",className:f,style:j,tabIndex:0,onKeyDown:e=>{h&&e.stopPropagation()},onClick:e=>{h&&e.stopPropagation()},"data-e2e":"src-SmartWrapperExtension-div",children:Object(l.jsx)(o.a,{target:n,jumpStartHandler:x,jumpFailHandler:P,jumpHook:w,schemeParams:d(d({},E),u),fallbackURLParams:d(d({pid:b,af_ad:c,af_siteid:s?"mobile":"pc"},v),"function"==typeof i?i(null!=a?a:"null"):{}),customStyle:g,"data-e2e":"src-SmartWrapperExtension-SmartWrapper",children:e})})}return Object(l.jsx)("a",{target:"_blank",href:r,onClick:e=>{y(e),h&&e.stopPropagation()},style:j,className:f,rel:"noreferrer","data-e2e":"src-SmartWrapperExtension-a",children:e})};u.defaultProps={shouldStopInteractEventPropagation:!1,className:void 0,extensionStyle:void 0,teaTarget:void 0,customSchemeParams:void 0},t.a=Object(i.connect)(u)},963:function(e,t,r){"use strict";r.d(t,"a",(function(){return a}));var n=r(216);const a=(e,t=!1)=>{const r=Object(n.a)();if(r&&Object(n.b)()&&!t){const t=JSON.stringify({signalSource:window.name,link:e});window.parent.postMessage(t,"*")}else{const t=document.createElement("a");t.href=e,t.target=r?"_top":"_blank",t.click()}}},964:function(e,t,r){"use strict";r.d(t,"a",(function(){return i})),r.d(t,"b",(function(){return o}));r(4),r(5);var n=r(0),a=r(965);const i=e=>t=>{e&&("function"==typeof e?e(t):e.current=t)},o=e=>{const[t,r]=Object(n.useState)();return Object(n.useEffect)(()=>Object(a.a)(e)(["play","playing","pause","waiting","ended","error"].map(e=>{return[e,(t=e,()=>r(t))];var t})),[e]),t}},965:function(e,t,r){"use strict";r.d(t,"a",(function(){return a})),r.d(t,"b",(function(){return i}));r(4),r(5);var n=r(0);const a=e=>(t=[])=>{const r=e.current;if(r)return t.forEach(([e,t])=>{r.addEventListener(e,t)}),()=>{t.forEach(([e,t])=>{r.removeEventListener(e,t)})}},i=e=>{const{playerRef:t,videoData:{itemInfos:{video:{videoMeta:r}={}}={}}={}}=e,[i,o]=Object(n.useState)(0),[s,l]=Object(n.useState)(()=>{var e;return null!==(e=null==r?void 0:r.duration)&&void 0!==e?e:0});return Object(n.useEffect)(()=>a(t)([["timeupdate",e=>{var t,r;return o(null!==(t=null===(r=e.currentTarget)||void 0===r?void 0:r.currentTime)&&void 0!==t?t:0)}],["loadedmetadata",e=>{var t,r,n;console.log("loadedmetadata",e.currentTarget,null===(t=e.currentTarget)||void 0===t?void 0:t.duration),l(null!==(r=null===(n=e.currentTarget)||void 0===n?void 0:n.duration)&&void 0!==r?r:0)}]]),[t]),{currentTime:i,setCurrentTime:o,duration:s}}},966:function(e,t,r){"use strict";r.d(t,"a",(function(){return n})),r.d(t,"b",(function(){return a}));const n={paddingX:"16px",paddingY:"12px"},a={withLogo:20,withProfiler:18,withInitClick:18,withControls:16,withLoading:14}},968:function(e,t,r){e.exports=r.p+"images/img-embed-logo-colorful-6e578f33c94fb378e31eb676c51d6ac2.svg"},972:function(e,t,r){"use strict";r.d(t,"a",(function(){return g}));var n=r(10),a=r.n(n),i=r(2),o=r(0),s=r.n(o),l=r(968),c=r.n(l),d=r(57),u=r(171),p=r(966),b=r(1);function m(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function f(e){for(var t=1;t{const r=e.theme.globalParams,{itemInfos:{id:n=""}={}}=t,a={referer_video_id:n};return Object(b.jsx)(g,{target:"_blank",rel:"noreferrer",href:Object(u.b)({globalQueryParams:r(d.l.TARGETS.LOGO),optionalParams:a}),"data-e2e":"hoc-with-logo-ColorfulLogo"})});t.b=e=>{const t=s.a.forwardRef((t,r)=>Object(b.jsxs)(b.Fragment,{children:[Object(b.jsx)(e,f(f({},t),{},{ref:r,"data-e2e":"hoc-with-logo-Component"})),Object(b.jsx)(h,{videoData:t.videoData,"data-e2e":"hoc-with-logo-Logo"})]}));return t.displayName="WithLogo",t}},973:function(e,t,r){e.exports=r.p+"images/img-embed-controller-play-50633fd697e3a54c76c42c2a03aab3ea.svg"},975:function(e,t,r){"use strict";var n=r(2),a=r(0),i=r(40),o=r(41);function s(e){return a.createElement("svg",Object(i.a)({fill:"currentColor"},e,{viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",className:e.className}),a.createElement("path",{d:"M2 24a22 22 0 1 1 44 0 22 22 0 0 1-44 0Zm25.3-8.8a3.3 3.3 0 1 0-6.6 0 3.3 3.3 0 0 0 6.6 0Zm-4.4 6.6c-.6 0-1.1.5-1.1 1.1V35c0 .6.5 1.1 1.1 1.1h2.2c.6 0 1.1-.5 1.1-1.1V22.9c0-.6-.5-1.1-1.1-1.1h-2.2Z"}))}Object(o.a)(s);var l=r(18),c=r(65),d=r(1);const u=Object(n.styled)("div",{target:"e10i65ja0"})({name:"bkxkhj",styles:"display:flex;flex-direction:row;justify-content:center;align-items:center;padding:1px 4px;gap:2px;height:18px;background:rgba(22 24 35 / 6%);border-radius:2px"});t.a=({scmText:e,scmUrl:t})=>Object(d.jsx)(u,{"data-e2e":"common-scmWarning-ScmLabelWrapper",children:Object(d.jsx)(c.a,{target:"_blank",link:t,href:t,"data-e2e":"common-scmWarning-Link",children:Object(d.jsx)(l.o,{label:e,icon:Object(d.jsx)(s,{"data-e2e":"common-scmWarning-IconInfoCircleFill"}),iconPosition:"before",variant:"primary",size:"P5","data-e2e":"common-scmWarning-TUXTextButton"})})})},976:function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(630),a=r(13);function i(e){const{adLabelVersion:t,brandOrganicType:r=0,isECVideo:i,locationCreated:o}=e,s=o,l=t===n.a.New,c=Number(r)>0;let d="";return l&&i?"US"===s?d="bc_disclosure_tag_ecommerce_us":"GB"===s&&(d="bc_disclosure_tag_ecommerce_uk"):d=l?"bc_new_disclosure":"tcm_closedLoop_commercialContent_brandOrganic_videoTag",l&&i&&"US"!==s&&"GB"!==s?"":l||c?a.b.t(d):""}},978:function(e,t,r){e.exports=r.p+"images/img-embed-controller-mute-dc2568a21aab02cea553c5e9695aaaa8.svg"},979:function(e,t,r){e.exports=r.p+"images/img-embed-controller-replay-73ec448f6492728a7be65038b024f5f8.svg"},980:function(e,t,r){e.exports=r.p+"images/img-embed-controller-sounds-on-cfa541fc496fdf4cc2eec3fbadb053ee.svg"},981:function(e,t,r){e.exports=r.p+"images/img-embed-rec-card-play-hollow-777ace2e51d9cbf10667405c93897ba7.svg"},993:function(e,t,r){e.exports=r.p+"images/img-embed-banner-comment-paused-525ef181d912eff7cd232b1111140043.svg"},994:function(e,t,r){e.exports=r.p+"images/img-embed-banner-comment-d1335fb135de82a0a6b923df2e515c06.svg"},995:function(e,t,r){e.exports=r.p+"images/img-embed-music-26847fc3f0c6f8b667c268b0c0a2bd0f.svg"},996:function(e,t,r){e.exports=r.p+"images/duet_icon_play-6eb9a40fb124cf79b6bc3a8b538a5585.svg"},998:function(e,t,r){e.exports=r.p+"images/img-embed-controller-full-screen-a89cf7768ff89b1e0b9139df809729d7.svg"},999:function(e,t,r){e.exports=r.p+"images/img-embed-controller-pause-6516376e0e318a6bda5d656e064da523.svg"}}]);