@vkontakte/videoplayer 1.1.82-dev.fbdd1f70.0 → 1.1.82
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es2015.cjs +38 -38
- package/es2015.esm.js +38 -38
- package/es2018.cjs +38 -38
- package/es2018.esm.js +38 -38
- package/es2024.cjs +38 -38
- package/es2024.esm.js +38 -38
- package/esnext.cjs +38 -38
- package/esnext.esm.js +38 -38
- package/evergreen.esm.js +38 -38
- package/package.json +5 -5
- package/types/config.d.ts +4 -0
- package/types/store/index.d.ts +3 -3
- package/types/types/index.d.ts +4 -2
package/es2015.cjs
CHANGED
|
@@ -1,63 +1,63 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vkontakte/videoplayer v1.1.82
|
|
3
|
-
* Tue,
|
|
2
|
+
* @vkontakte/videoplayer v1.1.82
|
|
3
|
+
* Tue, 10 Feb 2026 14:16:20 GMT
|
|
4
4
|
* https://st.mycdn.me/static/vkontakte-videoplayer/1-1-82/doc/
|
|
5
5
|
*/
|
|
6
|
-
"use strict";var
|
|
6
|
+
"use strict";var K$=Object.create;var _d=Object.defineProperty,q$=Object.defineProperties,Q$=Object.getOwnPropertyDescriptor,G$=Object.getOwnPropertyDescriptors,Y$=Object.getOwnPropertyNames,Eg=Object.getOwnPropertySymbols,j$=Object.getPrototypeOf,Pg=Object.prototype.hasOwnProperty,X$=Object.prototype.propertyIsEnumerable;var kg=i=>{throw TypeError(i)};var Zp=(i,e,t)=>e in i?_d(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,Ve=(i,e)=>{for(var t in e||(e={}))Pg.call(e,t)&&Zp(i,t,e[t]);if(Eg)for(var t of Eg(e))X$.call(e,t)&&Zp(i,t,e[t]);return i},Gt=(i,e)=>q$(i,G$(e));var Z$=(i,e)=>{for(var t in e)_d(i,t,{get:e[t],enumerable:!0})},Ag=(i,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of Y$(e))!Pg.call(i,r)&&r!==t&&_d(i,r,{get:()=>e[r],enumerable:!(o=Q$(e,r))||o.enumerable});return i};var Lg=(i,e,t)=>(t=i!=null?K$(j$(i)):{},Ag(e||!i||!i.__esModule?_d(t,"default",{value:i,enumerable:!0}):t,i)),J$=i=>Ag(_d({},"__esModule",{value:!0}),i);var ur=(i,e,t)=>Zp(i,typeof e!="symbol"?e+"":e,t),Jp=(i,e,t)=>e.has(i)||kg("Cannot "+t);var Ni=(i,e,t)=>(Jp(i,e,"read from private field"),t?t.call(i):e.get(i)),ea=(i,e,t)=>e.has(i)?kg("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(i):e.set(i,t),$l=(i,e,t,o)=>(Jp(i,e,"write to private field"),o?o.call(i,t):e.set(i,t),t),Mg=(i,e,t)=>(Jp(i,e,"access private method"),t);var bt=(i,e,t)=>new Promise((o,r)=>{var a=s=>{try{d(t.next(s))}catch(u){r(u)}},l=s=>{try{d(t.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((t=t.apply(i,e)).next())});var YT={};Z$(YT,{ControlButtonType:()=>bc,GridTypes:()=>os,InterfaceLanguage:()=>md.InterfaceLanguage,MenuItemType:()=>jl,PlayerPhase:()=>ns,VERSION:()=>Ua,VKNumericLanguage:()=>md.VKNumericLanguage,VideoFormat:()=>zp.VideoFormat,VideoQuality:()=>zp.VideoQuality,loadVKLangPack:()=>md.loadVKLangPack,registerPlayerWebComponent:()=>GT});module.exports=J$(YT);var ta="[",ia="[!",Ta="]",ms={};var ro=Symbol(),Gn=Symbol("filename"),Vg=Symbol("hmr"),Rg="http://www.w3.org/1999/xhtml",au="http://www.w3.org/2000/svg";var ef="@attach";var lu=!0;var Dg,Ng,Og=(Ng=(Dg=globalThis.process)==null?void 0:Dg.env)==null?void 0:Ng.NODE_ENV,Re=Og&&!Og.toLowerCase().startsWith("prod");var pr=Array.isArray,Bg=Array.prototype.indexOf,bd=Array.from,tf=Object.keys,vo=Object.defineProperty,jo=Object.getOwnPropertyDescriptor,du=Object.getOwnPropertyDescriptors,of=Object.prototype,Hg=Array.prototype,Ia=Object.getPrototypeOf,nf=Object.isExtensible;function oa(i){return typeof i=="function"}var $t=()=>{};function Fg(i){return i()}function na(i){for(var e=0;e<i.length;e++)i[e]()}var Xo=Symbol("$state"),yl=Symbol("legacy props"),Ug=Symbol(""),cu=Symbol("proxy path"),uu=1,xl=3,fr=8;function pu(i){return i===this.v}function wl(i,e){return i!=i?e==e:i!==e||i!==null&&typeof i=="object"||typeof i=="function"}function zg(i,e){return i!==e}function Sl(i){return!wl(i,this.v)}function Wg(){if(Re){let i=new Error(`derived_references_self
|
|
7
7
|
A derived value cannot reference itself recursively
|
|
8
|
-
https://svelte.dev/e/derived_references_self`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/derived_references_self")}function
|
|
8
|
+
https://svelte.dev/e/derived_references_self`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/derived_references_self")}function Kg(i){if(Re){let e=new Error(`effect_in_teardown
|
|
9
9
|
\`${i}\` cannot be used inside an effect cleanup function
|
|
10
|
-
https://svelte.dev/e/effect_in_teardown`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/effect_in_teardown")}function
|
|
10
|
+
https://svelte.dev/e/effect_in_teardown`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/effect_in_teardown")}function qg(){if(Re){let i=new Error("effect_in_unowned_derived\nEffect cannot be created inside a `$derived` value that was not itself created inside an effect\nhttps://svelte.dev/e/effect_in_unowned_derived");throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Qg(i){if(Re){let e=new Error(`effect_orphan
|
|
11
11
|
\`${i}\` can only be used inside an effect (e.g. during component initialisation)
|
|
12
|
-
https://svelte.dev/e/effect_orphan`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/effect_orphan")}function
|
|
12
|
+
https://svelte.dev/e/effect_orphan`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/effect_orphan")}function Gg(){if(Re){let i=new Error(`effect_update_depth_exceeded
|
|
13
13
|
Maximum update depth exceeded. This can happen when a reactive block or effect repeatedly sets a new value. Svelte limits the number of nested updates to prevent infinite loops
|
|
14
|
-
https://svelte.dev/e/effect_update_depth_exceeded`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function
|
|
14
|
+
https://svelte.dev/e/effect_update_depth_exceeded`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Yg(){if(Re){let i=new Error(`hydration_failed
|
|
15
15
|
Failed to hydrate the application
|
|
16
|
-
https://svelte.dev/e/hydration_failed`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/hydration_failed")}function
|
|
16
|
+
https://svelte.dev/e/hydration_failed`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/hydration_failed")}function jg(){if(Re){let i=new Error("invalid_snippet\nCould not `{@render}` snippet due to the expression being `null` or `undefined`. Consider using optional chaining `{@render snippet?.()}`\nhttps://svelte.dev/e/invalid_snippet");throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/invalid_snippet")}function Xg(i){if(Re){let e=new Error(`props_invalid_value
|
|
17
17
|
Cannot do \`bind:${i}={undefined}\` when \`${i}\` has a fallback value
|
|
18
|
-
https://svelte.dev/e/props_invalid_value`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/props_invalid_value")}function
|
|
18
|
+
https://svelte.dev/e/props_invalid_value`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/props_invalid_value")}function Zg(i){if(Re){let e=new Error(`props_rest_readonly
|
|
19
19
|
Rest element properties of \`$props()\` such as \`${i}\` are readonly
|
|
20
|
-
https://svelte.dev/e/props_rest_readonly`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/props_rest_readonly")}function
|
|
20
|
+
https://svelte.dev/e/props_rest_readonly`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/props_rest_readonly")}function Jg(i){if(Re){let e=new Error(`rune_outside_svelte
|
|
21
21
|
The \`${i}\` rune is only available inside \`.svelte\` and \`.svelte.js/ts\` files
|
|
22
|
-
https://svelte.dev/e/rune_outside_svelte`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/rune_outside_svelte")}function
|
|
22
|
+
https://svelte.dev/e/rune_outside_svelte`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/rune_outside_svelte")}function eh(){if(Re){let i=new Error("state_descriptors_fixed\nProperty descriptors defined on `$state` objects must contain `value` and always be `enumerable`, `configurable` and `writable`.\nhttps://svelte.dev/e/state_descriptors_fixed");throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function th(){if(Re){let i=new Error("state_prototype_fixed\nCannot set prototype of `$state` object\nhttps://svelte.dev/e/state_prototype_fixed");throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/state_prototype_fixed")}function ih(){if(Re){let i=new Error("state_unsafe_mutation\nUpdating state inside `$derived(...)`, `$inspect(...)` or a template expression is forbidden. If the value should not be reactive, declare it without `$state`\nhttps://svelte.dev/e/state_unsafe_mutation");throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/state_unsafe_mutation")}var vs=!1,gs=!1;function oh(){vs=!0}var $d=null;function ks(i){let e=Error(),t=e.stack;if(t){let o=t.split(`
|
|
23
23
|
`),r=[`
|
|
24
|
-
`];for(let a=0;a<o.length;a++){let l=o[a];if(l!=="Error"){if(l.includes("validate_each_keys"))return null;l.includes("svelte/src/internal")||r.push(l)}}if(r.length===1)return null;
|
|
25
|
-
`)}),
|
|
24
|
+
`];for(let a=0;a<o.length;a++){let l=o[a];if(l!=="Error"){if(l.includes("validate_each_keys"))return null;l.includes("svelte/src/internal")||r.push(l)}}if(r.length===1)return null;vo(e,"stack",{value:r.join(`
|
|
25
|
+
`)}),vo(e,"name",{value:`${i}Error`})}return e}function jr(i,e){return i.label=e,fu(i.v,e),i}function fu(i,e){var t;return(t=i==null?void 0:i[cu])==null||t.call(i,e),i}function Cl(i){if(Re){let e=new Error(`lifecycle_outside_component
|
|
26
26
|
\`${i}(...)\` can only be used during component initialisation
|
|
27
|
-
https://svelte.dev/e/lifecycle_outside_component`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/lifecycle_outside_component")}var Wt=null;function
|
|
27
|
+
https://svelte.dev/e/lifecycle_outside_component`);throw e.name="Svelte error",e}else throw new Error("https://svelte.dev/e/lifecycle_outside_component")}var Wt=null;function yd(i){Wt=i}var mr=null;function xd(i){mr=i}function Tl(i){return af("getContext").get(i)}function Il(i,e){return af("setContext").set(i,e),e}function wd(){return af("getAllContexts")}function B(i,e=!1,t){var o=Wt={p:Wt,c:null,d:!1,e:null,m:!1,s:i,x:null,l:null};vs&&!e&&(Wt.l={s:null,u:null,r1:[],r2:Lr(!1)}),Mo(()=>{o.d=!0}),Re&&(Wt.function=t,mr=t)}function H(i){var l,d;let e=Wt;if(e!==null){i!==void 0&&(e.x=i);let s=e.e;if(s!==null){var t=xt,o=Nt;e.e=null;try{for(var r=0;r<s.length;r++){var a=s[r];go(a.effect),Gi(a.reaction),Vo(a.fn)}}finally{go(t),Gi(o)}}Wt=e.p,Re&&(mr=(d=(l=e.p)==null?void 0:l.function)!=null?d:null),e.m=!0}return i||{}}function hs(){return!vs||Wt!==null&&Wt.l===null}function af(i){var e;return Wt===null&&Cl(i),(e=Wt.c)!=null?e:Wt.c=new Map(t1(Wt)||void 0)}function t1(i){let e=i.p;for(;e!==null;){let t=e.c;if(t!==null)return t;e=e.p}return null}var i1=/^[a-zA-Z_$][a-zA-Z_$0-9]*$/;function li(i){if(typeof i!="object"||i===null||Xo in i)return i;let e=Ia(i);if(e!==of&&e!==Hg)return i;var t=new Map,o=pr(i),r=K(0),a=Re&&gs?ks("CreatedAt"):null,l=Nt,d=m=>{var p=Nt;Gi(l);var v=m();return Gi(p),v};o&&t.set("length",K(i.length,a));var s="";function u(m){s=m,jr(r,`${s} version`);for(let[p,v]of t)jr(v,Ea(s,p))}return new Proxy(i,{defineProperty(m,p,v){(!("value"in v)||v.configurable===!1||v.enumerable===!1||v.writable===!1)&&eh();var b=t.get(p);return b===void 0?b=d(()=>{var y=K(v.value,a);return t.set(p,y),Re&&typeof p=="string"&&jr(y,Ea(s,p)),y}):O(b,v.value,!0),!0},deleteProperty(m,p){var v=t.get(p);if(v===void 0){if(p in m){let _=d(()=>K(ro,a));t.set(p,_),lf(r),Re&&jr(_,Ea(s,p))}}else{if(o&&typeof p=="string"){var b=t.get("length"),y=Number(p);Number.isInteger(y)&&y<b.v&&O(b,y)}O(v,ro),lf(r)}return!0},get(m,p,v){var x;if(p===Xo)return i;if(Re&&p===cu)return u;var b=t.get(p),y=p in m;if(b===void 0&&(!y||(x=jo(m,p))!=null&&x.writable)&&(b=d(()=>{var I=li(y?m[p]:ro),C=K(I,a);return Re&&jr(C,Ea(s,p)),C}),t.set(p,b)),b!==void 0){var _=n(b);return _===ro?void 0:_}return Reflect.get(m,p,v)},getOwnPropertyDescriptor(m,p){var v=Reflect.getOwnPropertyDescriptor(m,p);if(v&&"value"in v){var b=t.get(p);b&&(v.value=n(b))}else if(v===void 0){var y=t.get(p),_=y==null?void 0:y.v;if(y!==void 0&&_!==ro)return{enumerable:!0,configurable:!0,value:_,writable:!0}}return v},has(m,p){var _;if(p===Xo)return!0;var v=t.get(p),b=v!==void 0&&v.v!==ro||Reflect.has(m,p);if(v!==void 0||xt!==null&&(!b||(_=jo(m,p))!=null&&_.writable)){v===void 0&&(v=d(()=>{var x=b?li(m[p]):ro,I=K(x,a);return Re&&jr(I,Ea(s,p)),I}),t.set(p,v));var y=n(v);if(y===ro)return!1}return b},set(m,p,v,b){var E;var y=t.get(p),_=p in m;if(o&&p==="length")for(var x=v;x<y.v;x+=1){var I=t.get(x+"");I!==void 0?O(I,ro):x in m&&(I=d(()=>K(ro,a)),t.set(x+"",I),Re&&jr(I,Ea(s,x)))}if(y===void 0)(!_||(E=jo(m,p))!=null&&E.writable)&&(y=d(()=>K(void 0,a)),O(y,li(v)),t.set(p,y),Re&&jr(y,Ea(s,p)));else{_=y.v!==ro;var C=d(()=>li(v));O(y,C)}var R=Reflect.getOwnPropertyDescriptor(m,p);if(R!=null&&R.set&&R.set.call(b,v),!_){if(o&&typeof p=="string"){var A=t.get("length"),P=Number(p);Number.isInteger(P)&&P>=A.v&&O(A,P+1)}lf(r)}return!0},ownKeys(m){n(r);var p=Reflect.ownKeys(m).filter(y=>{var _=t.get(y);return _===void 0||_.v!==ro});for(var[v,b]of t)b.v!==ro&&!(v in m)&&p.push(v);return p},setPrototypeOf(){th()}})}function Ea(i,e){var t;return typeof e=="symbol"?`${i}[Symbol(${(t=e.description)!=null?t:""})]`:i1.test(e)?`${i}.${e}`:/^\d+$/.test(e)?`${i}[${e}]`:`${i}['${e}']`}function lf(i,e=1){O(i,i.v+e)}function El(i){try{if(i!==null&&typeof i=="object"&&Xo in i)return i[Xo]}catch(e){}return i}function df(i,e){return Object.is(El(i),El(e))}function Xr(i){var e=2050,t=Nt!==null&&(Nt.f&2)!==0?Nt:null;xt===null||t!==null&&(t.f&256)!==0?e|=256:xt.f|=1048576;let o={ctx:Wt,deps:null,effects:null,equals:pu,f:e,fn:i,reactions:null,rv:0,v:null,wv:0,parent:t!=null?t:xt};return Re&&gs&&(o.created=ks("CreatedAt")),o}function f(i){let e=Xr(i);return gu(e),e}function gr(i){let e=Xr(i);return e.equals=Sl,e}function mu(i){var e=i.effects;if(e!==null){i.effects=null;for(var t=0;t<e.length;t+=1)Yi(e[t])}}var cf=[];function o1(i){for(var e=i.parent;e!==null;){if((e.f&2)===0)return e;e=e.parent}return null}function ff(i){var e,t=xt;if(go(o1(i)),Re){let o=Pa;uf(new Set);try{cf.includes(i)&&Wg(),cf.push(i),mu(i),e=vu(i)}finally{go(t),uf(o),cf.pop()}}else try{mu(i),e=vu(i)}finally{go(t)}return e}function mf(i){var e=ff(i);if(i.equals(e)||(i.v=e,i.wv=Sd()),!As){var t=(Ls||(i.f&256)!==0)&&i.deps!==null?4096:1024;Tn(i,t)}}var Pa=new Set,Pl=new Map;function uf(i){Pa=i}function Lr(i,e){var t={f:0,v:i,reactions:null,equals:pu,rv:0,wv:0};return Re&&gs&&(t.created=e!=null?e:ks("CreatedAt"),t.updated=null,t.set_during_effect=!1,t.trace=null),t}function K(i,e){let t=Lr(i,e);return gu(t),t}function _s(i,e=!1,t=!0){var r,a;let o=Lr(i);return e||(o.equals=Sl),vs&&t&&Wt!==null&&Wt.l!==null&&((a=(r=Wt.l).s)!=null?a:r.s=[]).push(o),o}function O(i,e,t=!1){var r;Nt!==null&&(!_r||(Nt.f&262144)!==0)&&hs()&&(Nt.f&262162)!==0&&!((r=Jo)!=null&&r[1].includes(i)&&Jo[0]===Nt)&&ih();let o=t?li(e):e;return Re&&fu(o,i.label),kl(i,o)}function kl(i,e){if(!i.equals(e)){var t=i.v;if(As?Pl.set(i,e):Pl.set(i,t),i.v=e,Re&&gs&&(i.updated=ks("UpdatedAt"),xt!==null&&(i.set_during_effect=!0)),(i.f&2)!==0&&((i.f&2048)!==0&&ff(i),Tn(i,(i.f&256)===0?1024:4096)),i.wv=Sd(),rh(i,2048),hs()&&xt!==null&&(xt.f&1024)!==0&&(xt.f&96)===0&&(hr===null?sh([i]):hr.push(i)),Re&&Pa.size>0){let o=Array.from(Pa);for(let r of o)(r.f&1024)!==0&&Tn(r,4096),Aa(r)&&Al(r);Pa.clear()}}return e}function rh(i,e){var t=i.reactions;if(t!==null)for(var o=hs(),r=t.length,a=0;a<r;a++){var l=t[a],d=l.f;if((d&2048)===0&&!(!o&&l===xt)){if(Re&&(d&262144)!==0){Pa.add(l);continue}Tn(l,e),(d&1280)!==0&&((d&2)!==0?rh(l,4096):Td(l))}}}var Ll="font-weight: bold",Ml="font-weight: normal";function ah(i,e,t){Re?console.warn(`%c[svelte] hydration_attribute_changed
|
|
28
28
|
%cThe \`${i}\` attribute on \`${e}\` changed its value between server and client renders. The client value, \`${t}\`, will be ignored in favour of the server value
|
|
29
|
-
https://svelte.dev/e/hydration_attribute_changed`,
|
|
29
|
+
https://svelte.dev/e/hydration_attribute_changed`,Ll,Ml):console.warn("https://svelte.dev/e/hydration_attribute_changed")}function lh(i){Re?console.warn(`%c[svelte] hydration_html_changed
|
|
30
30
|
%c${i?`The value of an \`{@html ...}\` block ${i} changed between server and client renders. The client value will be ignored in favour of the server value`:"The value of an `{@html ...}` block changed between server and client renders. The client value will be ignored in favour of the server value"}
|
|
31
|
-
https://svelte.dev/e/hydration_html_changed`,
|
|
31
|
+
https://svelte.dev/e/hydration_html_changed`,Ll,Ml):console.warn("https://svelte.dev/e/hydration_html_changed")}function ra(i){Re?console.warn(`%c[svelte] hydration_mismatch
|
|
32
32
|
%c${i?`Hydration failed because the initial UI does not match what was rendered on the server. The error occurred near ${i}`:"Hydration failed because the initial UI does not match what was rendered on the server"}
|
|
33
|
-
https://svelte.dev/e/hydration_mismatch`,
|
|
33
|
+
https://svelte.dev/e/hydration_mismatch`,Ll,Ml):console.warn("https://svelte.dev/e/hydration_mismatch")}function dh(){Re?console.warn(`%c[svelte] lifecycle_double_unmount
|
|
34
34
|
%cTried to unmount a component that was not mounted
|
|
35
|
-
https://svelte.dev/e/lifecycle_double_unmount`,
|
|
35
|
+
https://svelte.dev/e/lifecycle_double_unmount`,Ll,Ml):console.warn("https://svelte.dev/e/lifecycle_double_unmount")}function ch(){Re?console.warn("%c[svelte] select_multiple_invalid_value\n%cThe `value` property of a `<select multiple>` element should be an array, but it received a non-array value. The selection will be kept as is.\nhttps://svelte.dev/e/select_multiple_invalid_value",Ll,Ml):console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function hu(i){Re?console.warn(`%c[svelte] state_proxy_equality_mismatch
|
|
36
36
|
%cReactive \`$state(...)\` proxies and the values they proxy have different identities. Because of this, comparisons with \`${i}\` will produce unexpected results
|
|
37
|
-
https://svelte.dev/e/state_proxy_equality_mismatch`,
|
|
37
|
+
https://svelte.dev/e/state_proxy_equality_mismatch`,Ll,Ml):console.warn("https://svelte.dev/e/state_proxy_equality_mismatch")}var nt=!1;function ho(i){nt=i}var wt;function Ti(i){if(i===null)throw ra(),ms;return wt=i}function ji(){return Ti(en(wt))}function S(i){if(nt){if(en(wt)!==null)throw ra(),ms;wt=i}}function ni(i=1){if(nt){for(var e=i,t=wt;e--;)t=en(t);wt=t}}function La(){for(var i=0,e=wt;;){if(e.nodeType===fr){var t=e.data;if(t===Ta){if(i===0)return e;i-=1}else(t===ta||t===ia)&&(i+=1)}var o=en(e);e.remove(),e=o}}function _u(i){if(!i||i.nodeType!==fr)throw ra(),ms;return i.data}function uh(){let i=Array.prototype,e=Array.__svelte_cleanup;e&&e();let{indexOf:t,lastIndexOf:o,includes:r}=i;i.indexOf=function(a,l){let d=t.call(this,a,l);if(d===-1){for(let s=l!=null?l:0;s<this.length;s+=1)if(El(this[s])===a){hu("array.indexOf(...)");break}}return d},i.lastIndexOf=function(a,l){let d=o.call(this,a,l!=null?l:this.length-1);if(d===-1){for(let s=0;s<=(l!=null?l:this.length-1);s+=1)if(El(this[s])===a){hu("array.lastIndexOf(...)");break}}return d},i.includes=function(a,l){let d=r.call(this,a,l);if(!d){for(let s=0;s<this.length;s+=1)if(El(this[s])===a){hu("array.includes(...)");break}}return d},Array.__svelte_cleanup=()=>{i.indexOf=t,i.lastIndexOf=o,i.includes=r}}var Ma,ph,Id,fh,mh;function bu(){if(Ma===void 0){Ma=window,ph=document,Id=/Firefox/.test(navigator.userAgent);var i=Element.prototype,e=Node.prototype,t=Text.prototype;fh=jo(e,"firstChild").get,mh=jo(e,"nextSibling").get,nf(i)&&(i.__click=void 0,i.__className=void 0,i.__attributes=null,i.__style=void 0,i.__e=void 0),nf(t)&&(t.__t=void 0),Re&&(i.__svelte_meta=null,uh())}}function In(i=""){return document.createTextNode(i)}function Ei(i){return fh.call(i)}function en(i){return mh.call(i)}function T(i,e){if(!nt)return Ei(i);var t=Ei(wt);if(t===null)t=wt.appendChild(In());else if(e&&t.nodeType!==xl){var o=In();return t==null||t.before(o),Ti(o),o}return Ti(t),t}function le(i,e){var r,a;if(!nt){var t=Ei(i);return t.nodeType===8&&t.data===""?en(t):t}if(e&&((r=wt)==null?void 0:r.nodeType)!==xl){var o=In();return(a=wt)==null||a.before(o),Ti(o),o}return wt}function k(i,e=1,t=!1){let o=nt?wt:i;for(var r;e--;)r=o,o=en(o);if(!nt)return o;if(t&&(o==null?void 0:o.nodeType)!==xl){var a=In();return o===null?r==null||r.after(a):o.before(a),Ti(a),a}return Ti(o),o}function Ed(i){i.textContent=""}function hf(i){xt===null&&Nt===null&&Qg(i),Nt!==null&&(Nt.f&256)!==0&&xt===null&&qg(),As&&Kg(i)}function n1(i,e){var t=e.last;t===null?e.last=e.first=i:(t.next=i,i.prev=t,e.last=i)}function Va(i,e,t,o=!0){var s;var r=xt;if(Re)for(;r!==null&&(r.f&262144)!==0;)r=r.parent;var a={ctx:Wt,deps:null,nodes_start:null,nodes_end:null,f:i|2048,first:null,fn:e,last:null,next:null,parent:r,prev:null,teardown:null,transitions:null,wv:0};if(Re&&(a.component_function=mr),t)try{Al(a),a.f|=32768}catch(u){throw Yi(a),u}else e!==null&&Td(a);var l=t&&a.deps===null&&a.first===null&&a.nodes_start===null&&a.teardown===null&&(a.f&1048704)===0;if(!l&&o&&(r!==null&&n1(a,r),Nt!==null&&(Nt.f&2)!==0)){var d=Nt;((s=d.effects)!=null?s:d.effects=[]).push(a)}return a}function Mo(i){let e=Va(8,null,!1);return Tn(e,1024),e.teardown=i,e}function Fe(i){var r;hf("$effect");var e=xt!==null&&(xt.f&32)!==0&&Wt!==null&&!Wt.m;if(Re&&vo(i,"name",{value:"$effect"}),e){var t=Wt;((r=t.e)!=null?r:t.e=[]).push({fn:i,effect:xt,reaction:Nt})}else{var o=Vo(i);return o}}function Ad(i){return hf("$effect.pre"),Re&&vo(i,"name",{value:"$effect.pre"}),tn(i)}function xu(i){let e=Va(64,i,!0);return()=>{Yi(e)}}function gh(i){let e=Va(64,i,!0);return(t={})=>new Promise(o=>{t.outro?Zn(e,()=>{Yi(e),o(void 0)}):(Yi(e),o(void 0))})}function Vo(i){return Va(4,i,!1)}function tn(i){return Va(8,i,!0)}function N(i,e=[],t=Xr){if(Re)return tn(()=>{var r=xt,a=()=>i(...l.map(n));vo(r.fn,"name",{value:"{expression}"}),vo(a,"name",{value:"{expression}"});let l=e.map(t);Xi(a)});let o=e.map(t);return Xi(()=>i(...o.map(n)))}function Xi(i,e=0){return Va(24|e,i,!0)}function Bi(i,e=!0){return Va(40,i,!0,e)}function _f(i){var e=i.teardown;if(e!==null){let t=As,o=Nt;vf(!0),Gi(null);try{e.call(null)}finally{vf(t),Gi(o)}}}function bf(i,e=!1){var t=i.first;for(i.first=i.last=null;t!==null;){var o=t.next;(t.f&64)!==0?t.parent=null:Yi(t,e),t=o}}function hh(i){for(var e=i.first;e!==null;){var t=e.next;(e.f&32)===0&&Yi(e),e=t}}function Yi(i,e=!0){var t=!1;(e||(i.f&524288)!==0)&&i.nodes_start!==null&&i.nodes_end!==null&&($f(i.nodes_start,i.nodes_end),t=!0),bf(i,e&&!t),Ld(i,0),Tn(i,16384);var o=i.transitions;if(o!==null)for(let a of o)a.stop();_f(i);var r=i.parent;r!==null&&r.first!==null&&yf(i),Re&&(i.component_function=null),i.next=i.prev=i.teardown=i.ctx=i.deps=i.fn=i.nodes_start=i.nodes_end=null}function $f(i,e){for(;i!==null;){var t=i===e?null:en(i);i.remove(),i=t}}function yf(i){var e=i.parent,t=i.prev,o=i.next;t!==null&&(t.next=o),o!==null&&(o.prev=t),e!==null&&(e.first===i&&(e.first=o),e.last===i&&(e.last=t))}function Zn(i,e){var t=[];wu(i,t,!0),xf(t,()=>{Yi(i),e&&e()})}function xf(i,e){var t=i.length;if(t>0){var o=()=>--t||e();for(var r of i)r.out(o)}else e()}function wu(i,e,t){if((i.f&8192)===0){if(i.f^=8192,i.transitions!==null)for(let l of i.transitions)(l.is_global||t)&&e.push(l);for(var o=i.first;o!==null;){var r=o.next,a=(o.f&65536)!==0||(o.f&32)!==0;wu(o,e,a?t:!1),o=r}}}function Vs(i){_h(i,!0)}function _h(i,e){if((i.f&8192)!==0){i.f^=8192;for(var t=i.first;t!==null;){var o=t.next,r=(t.f&65536)!==0||(t.f&32)!==0;_h(t,r?e:!1),t=o}if(i.transitions!==null)for(let a of i.transitions)(a.is_global||e)&&a.in()}}var Md=[],wf=[];function bh(){var i=Md;Md=[],na(i)}function r1(){var i=wf;wf=[],na(i)}function En(i){Md.length===0&&queueMicrotask(bh),Md.push(i)}function $h(){Md.length>0&&bh(),wf.length>0&&r1()}function xh(i){var e=xt;if(Re&&i instanceof Error&&s1(i,e),(e.f&32768)===0){if((e.f&128)===0)throw i;e.fn(i)}else Vd(i,e)}function Vd(i,e){for(;e!==null;){if((e.f&128)!==0)try{e.fn(i);return}catch(t){}e=e.parent}throw i}var yh=new WeakSet;function s1(i,e){var l,d;if(yh.has(i))return;yh.add(i);let t=jo(i,"message");if(!(t&&!t.configurable)){for(var o=Id?" ":" ",r=`
|
|
38
38
|
${o}in ${((l=e.fn)==null?void 0:l.name)||"<unknown>"}`,a=e.ctx;a!==null;)r+=`
|
|
39
|
-
${o}in ${(d=a.function)==null?void 0:d[
|
|
39
|
+
${o}in ${(d=a.function)==null?void 0:d[Gn].split("/").pop()}`,a=a.p;vo(i,"message",{value:i.message+`
|
|
40
40
|
${r}
|
|
41
|
-
`}),i.stack&&
|
|
41
|
+
`}),i.stack&&vo(i,"stack",{value:i.stack.split(`
|
|
42
42
|
`).filter(s=>!s.includes("svelte/src/internal")).join(`
|
|
43
|
-
`)})}}var Da=!1,Nl=null,Oa=!1,Ls=!1;function hf(i){Ls=i}var Dd=[],Od=[],Ht=null,gr=!1;function Yi(i){Ht=i}var $t=null;function vo(i){$t=i}var Xo=null;function _u(i){Ht!==null&&Ht.f&2097152&&(Xo===null?Xo=[Ht,[i]]:Xo[1].push(i))}var Vn=null,hr=0,vr=null;function ah(i){vr=i}var Th=1,Iu=0,Ms=!1,Eu=null;function Td(){return++Th}function Ma(i){var p,v;var e=i.f;if((e&2048)!==0)return!0;if((e&4096)!==0){var t=i.deps,o=(e&256)!==0;if(t!==null){var r,a,l=(e&512)!==0,d=o&&$t!==null&&!Ms,s=t.length;if(l||d){var u=i,m=u.parent;for(r=0;r<s;r++)a=t[r],(l||!((p=a==null?void 0:a.reactions)!=null&&p.includes(u)))&&((v=a.reactions)!=null?v:a.reactions=[]).push(u);l&&(u.f^=512),d&&m!==null&&(m.f&256)===0&&(u.f^=256)}for(r=0;r<s;r++)if(a=t[r],Ma(a)&&gf(a),a.wv>i.wv)return!0}(!o||$t!==null&&!Ms)&&An(i,1024)}return!1}function Ih(i,e,t=!0){var o=i.reactions;if(o!==null)for(var r=0;r<o.length;r++){var a=o[r];Xo!=null&&Xo[1].includes(i)&&Xo[0]===Ht||((a.f&2)!==0?Ih(a,e,!1):e===a&&(t?An(a,2048):(a.f&1024)!==0&&An(a,4096),Ed(a)))}}function hu(i){var b,y;var e=Vn,t=hr,o=vr,r=Ht,a=Ms,l=Xo,d=Wt,s=gr,u=i.f;Vn=null,hr=0,vr=null,Ms=(u&256)!==0&&(gr||!Oa||Ht===null),Ht=(u&96)===0?i:null,Xo=null,wd(i.ctx),gr=!1,Iu++,i.f|=2097152;try{var m=(0,i.fn)(),p=i.deps;if(Vn!==null){var v;if(Vd(i,hr),p!==null&&hr>0)for(p.length=hr+Vn.length,v=0;v<Vn.length;v++)p[hr+v]=Vn[v];else i.deps=p=Vn;if(!Ms||(u&2)!==0&&i.reactions!==null)for(v=hr;v<p.length;v++)((y=(b=p[v]).reactions)!=null?y:b.reactions=[]).push(i)}else p!==null&&hr<p.length&&(Vd(i,hr),p.length=hr);if(gs()&&vr!==null&&!gr&&p!==null&&(i.f&6146)===0)for(v=0;v<vr.length;v++)Ih(vr[v],i);return r!==null&&r!==i&&(Iu++,vr!==null&&(o===null?o=vr:o.push(...vr))),m}catch(_){wh(_)}finally{Vn=e,hr=t,vr=o,Ht=r,Ms=a,Xo=l,wd(d),gr=s,i.f^=2097152}}function s1(i,e){let t=e.reactions;if(t!==null){var o=Hg.call(t,i);if(o!==-1){var r=t.length-1;r===0?t=e.reactions=null:(t[o]=t[r],t.pop())}}t===null&&(e.f&2)!==0&&(Vn===null||!Vn.includes(e))&&(An(e,4096),(e.f&768)===0&&(e.f^=512),gu(e),Vd(e,0))}function Vd(i,e){var t=i.deps;if(t!==null)for(var o=e;o<t.length;o++)s1(i,t[o])}function Ml(i){var e=i.f;if((e&16384)===0){An(i,1024);var t=$t,o=Oa;if($t=i,Oa=!0,Ae){var r=fr;Sd(i.component_function)}try{(e&16)!==0?_h(i):yf(i),$f(i);var a=hu(i);if(i.teardown=typeof a=="function"?a:null,i.wv=Th,Ae&&vs&&(i.f&2048)!==0&&i.deps!==null)for(var l of i.deps)l.set_during_effect&&(l.wv=Td(),l.set_during_effect=!1);Ae&&Od.push(i)}finally{Oa=o,$t=t,Ae&&Sd(r)}}}function Sh(){console.error("Last ten effects were: ",Od.slice(-10).map(i=>i.fn)),Od=[]}function a1(){try{Yg()}catch(i){if(Ae&&mo(i,"stack",{value:""}),Nl!==null)if(Ae)try{Nd(i,Nl)}catch(e){throw Sh(),e}else Nd(i,Nl);else throw Ae&&Sh(),i}}function If(){var i=Oa;try{var e=0;for(Oa=!0;Dd.length>0;){e++>1e3&&a1();var t=Dd,o=t.length;Dd=[];for(var r=0;r<o;r++){var a=d1(t[r]);l1(a)}Al.clear()}}finally{Da=!1,Oa=i,Nl=null,Ae&&(Od=[])}}function l1(i){var e=i.length;if(e!==0)for(var t=0;t<e;t++){var o=i[t];(o.f&24576)===0&&Ma(o)&&(Ml(o),o.deps===null&&o.first===null&&o.nodes_start===null&&(o.teardown===null?wf(o):o.fn=null))}}function Ed(i){Da||(Da=!0,queueMicrotask(If));for(var e=Nl=i;e.parent!==null;){e=e.parent;var t=e.f;if((t&96)!==0){if((t&1024)===0)return;e.f^=1024}}Dd.push(e)}function d1(i){for(var e=[],t=i;t!==null;){var o=t.f,r=(o&96)!==0,a=r&&(o&1024)!==0;if(!a&&(o&8192)===0){(o&4)!==0?e.push(t):r?t.f^=1024:Ma(t)&&Ml(t);var l=t.first;if(l!==null){t=l;continue}}var d=t.parent;for(t=t.next;t===null&&d!==null;)t=d.next,d=d.parent}return e}function Dl(i){var e;for(i&&(Da=!0,If(),Da=!0,e=i());;){if(yh(),Dd.length===0)return Da=!1,Nl=null,Ae&&(Od=[]),e;Da=!0,If()}}function ho(){return ht(this,null,function*(){yield Promise.resolve(),Dl()})}function n(i){var e=i.f,t=(e&2)!==0;if(Eu!==null&&Eu.add(i),Ht!==null&&!gr){if(!(Xo!=null&&Xo[1].includes(i))||Xo[0]!==Ht){var o=Ht.deps;i.rv<Iu&&(i.rv=Iu,Vn===null&&o!==null&&o[hr]===i?hr++:Vn===null?Vn=[i]:(!Ms||!Vn.includes(i))&&Vn.push(i))}}else if(t&&i.deps===null&&i.effects===null){var r=i,a=r.parent;a!==null&&(a.f&256)===0&&(r.f^=256)}if(t&&(r=i,Ma(r)&&gf(r)),Ae&&vs&&!gr&&xd!==null&&Ht!==null&&xd.reaction===Ht)if(i.trace)i.trace();else{var l=As("TracedAt");if(l){var d=xd.entries.get(i);d===void 0&&(d={traces:[]},xd.entries.set(i,d));var s=d.traces[d.traces.length-1];l.stack!==(s==null?void 0:s.stack)&&d.traces.push(l)}}return Ls&&Al.has(i)?Al.get(i):i.v}function Pt(i){var e=gr;try{return gr=!0,i()}finally{gr=e}}var c1=-7169;function An(i,e){i.f=i.f&c1|e}function ku(i){if(!(typeof i!="object"||!i||i instanceof EventTarget)){if(Yo in i)Pu(i);else if(!Array.isArray(i))for(let e in i){let t=i[e];typeof t=="object"&&t&&Yo in t&&Pu(t)}}}function Pu(i,e=new Set){if(typeof i=="object"&&i!==null&&!(i instanceof EventTarget)&&!e.has(i)){e.add(i),i instanceof Date&&i.getTime();for(let o in i)try{Pu(i[o],e)}catch(r){}let t=Pa(i);if(t!==Object.prototype&&t!==Array.prototype&&t!==Map.prototype&&t!==Set.prototype&&t!==Date.prototype){let o=uu(t);for(let r in o){let a=o[r].get;if(a)try{a.call(i)}catch(l){}}}}}function Ef(i,e){if(e){let t=document.body;i.autofocus=!0,Mn(()=>{document.activeElement===t&&i.focus()})}}function Bd(i){var e=Ht,t=$t;Yi(null),vo(null);try{return i()}finally{Yi(e),vo(t)}}var Pf=new Set,Au=new Set;function Ba(i){if(!tt)return;i.removeAttribute("onload"),i.removeAttribute("onerror");let e=i.__e;e!==void 0&&(i.__e=void 0,queueMicrotask(()=>{i.isConnected&&i.dispatchEvent(e)}))}function kf(i,e,t,o={}){function r(a){if(o.capture||Ol.call(e,a),!a.cancelBubble)return Bd(()=>t==null?void 0:t.call(this,a))}return i.startsWith("pointer")||i.startsWith("touch")||i==="wheel"?Mn(()=>{e.addEventListener(i,r,o)}):e.addEventListener(i,r,o),r}function ut(i,e,t,o,r){var a={capture:o,passive:r},l=kf(i,e,t,a);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&Vo(()=>{e.removeEventListener(i,l,a)})}function Ye(i){for(var e=0;e<i.length;e++)Pf.add(i[e]);for(var t of Au)t(i)}function Ol(i){var T;var e=this,t=e.ownerDocument,o=i.type,r=((T=i.composedPath)==null?void 0:T.call(i))||[],a=r[0]||i.target,l=0,d=i.__root;if(d){var s=r.indexOf(d);if(s!==-1&&(e===document||e===window)){i.__root=e;return}var u=r.indexOf(e);if(u===-1)return;s<=u&&(l=s)}if(a=r[l]||i.target,a!==e){mo(i,"currentTarget",{configurable:!0,get(){return a||t}});var m=Ht,p=$t;Yi(null),vo(null);try{for(var v,b=[];a!==null;){var y=a.assignedSlot||a.parentNode||a.host||null;try{var _=a["__"+o];if(_!=null&&(!a.disabled||i.target===a))if(ur(_)){var[x,...I]=_;x.apply(a,[i,...I])}else _.call(a,i)}catch(R){v?b.push(R):v=R}if(i.cancelBubble||y===e||y===null)break;a=y}if(v){for(let R of b)queueMicrotask(()=>{throw R});throw v}}finally{i.__root=e,delete i.currentTarget,Yi(m),vo(p)}}}var p1;function Eh(){p1=void 0}function Bl(i){var e=document.createElement("template");return e.innerHTML=i.replaceAll("<!>","<!---->"),e.content}function No(i,e){var t=$t;t.nodes_start===null&&(t.nodes_start=i,t.nodes_end=e)}function L(i,e){var t=(e&1)!==0,o=(e&2)!==0,r,a=!i.startsWith("<!>");return()=>{if(tt)return No(yt,null),yt;r===void 0&&(r=Bl(a?i:"<!>"+i),t||(r=Ii(r)));var l=o||Pd?document.importNode(r,!0):r.cloneNode(!0);if(t){var d=Ii(l),s=l.lastChild;No(d,s)}else No(l,l);return l}}function v1(i,e,t="svg"){var o=!i.startsWith("<!>"),r=(e&1)!==0,a=`<${t}>${o?i:"<!>"+i}</${t}>`,l;return()=>{if(tt)return No(yt,null),yt;if(!l){var d=Bl(a),s=Ii(d);if(r)for(l=document.createDocumentFragment();Ii(s);)l.appendChild(Ii(s));else l=Ii(s)}var u=l.cloneNode(!0);if(r){var m=Ii(u),p=u.lastChild;No(m,p)}else No(u,u);return u}}function Ie(i,e){return v1(i,e,"svg")}function _s(i=""){if(!tt){var e=Ln(i+"");return No(e,e),e}var t=yt;return t.nodeType!==Sl&&(t.before(t=Ln()),Ci(t)),No(t,t),t}function Me(){if(tt)return No(yt,null),yt;var i=document.createDocumentFragment(),e=document.createComment(""),t=Ln();return i.append(e,t),No(e,t),i}function $(i,e){if(tt){$t.nodes_end=yt,Xi();return}i!==null&&i.before(e)}var g1=/\r/g;function kh(i){i=i.replace(g1,"");let e=5381,t=i.length;for(;t--;)e=(e<<5)-e^i.charCodeAt(t);return(e>>>0).toString(36)}function Ah(i){return i.endsWith("capture")&&i!=="gotpointercapture"&&i!=="lostpointercapture"}var h1=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function Lh(i){return h1.includes(i)}var _1=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected","webkitdirectory","defer","disablepictureinpicture","disableremoteplayback"];var b1={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"};function Mh(i){var e;return i=i.toLowerCase(),(e=b1[i])!=null?e:i}var DP=[..._1,"formNoValidate","isMap","noModule","playsInline","readOnly","value","volume","defaultValue","defaultChecked","srcObject","noValidate","allowFullscreen","disablePictureInPicture","disableRemotePlayback"];var $1=["touchstart","touchmove"];function Vh(i){return $1.includes(i)}var y1=["$state","$state.raw","$derived","$derived.by"],OP=[...y1,"$state.snapshot","$props","$props.id","$bindable","$effect","$effect.pre","$effect.tracking","$effect.root","$inspect","$inspect().with","$inspect.trace","$host"];var x1=["textarea","script","style","title"];function Rh(i){return x1.includes(i)}function Lu(i){return i==null?void 0:i.replace(/\//g,"/")}var Hd=!0;function Mu(i){Hd=i}function ve(i,e){var o;var t=e==null?"":typeof e=="object"?e+"":e;t!==((o=i.__t)!=null?o:i.__t=i.nodeValue)&&(i.__t=t,i.nodeValue=t+"")}function is(i,e){return Nh(i,e)}function Lf(i,e){var l;yu(),e.intro=(l=e.intro)!=null?l:!1;let t=e.target,o=tt,r=yt;try{for(var a=Ii(t);a&&(a.nodeType!==pr||a.data!==ta);)a=Zo(a);if(!a)throw fs;go(!0),Ci(a),Xi();let d=Nh(i,Gt(ke({},e),{anchor:a}));if(yt===null||yt.nodeType!==pr||yt.data!==Ea)throw ra(),fs;return go(!1),d}catch(d){if(d===fs)return e.recover===!1&&jg(),yu(),kd(t),go(!1),is(i,e);throw d}finally{go(o),Ci(r),Eh()}}var Hl=new Map;function Nh(i,{target:e,anchor:t,props:o={},events:r,context:a,intro:l=!0}){yu();var d=new Set,s=p=>{for(var v=0;v<p.length;v++){var b=p[v];if(!d.has(b)){d.add(b);var y=Vh(b);e.addEventListener(b,Ol,{passive:y});var _=Hl.get(b);_===void 0?(document.addEventListener(b,Ol,{passive:y}),Hl.set(b,1)):Hl.set(b,_+1)}}};s(yd(Pf)),Au.add(s);var u=void 0,m=hh(()=>{var p=t!=null?t:e.appendChild(Ln());return Ni(()=>{if(a){B({});var v=Wt;v.c=a}r&&(o.$$events=r),tt&&No(p,null),Hd=l,u=i(p,o)||{},Hd=!0,tt&&($t.nodes_end=yt),a&&H()}),()=>{var y;for(var v of d){e.removeEventListener(v,Ol);var b=Hl.get(v);--b===0?(document.removeEventListener(v,Ol),Hl.delete(v)):Hl.set(v,b)}Au.delete(s),p!==t&&((y=p.parentNode)==null||y.removeChild(p))}});return Af.set(u,m),u}var Af=new WeakMap;function Ha(i,e){let t=Af.get(i);return t?(Af.delete(i),t(e)):(Ae&&ch(),Promise.resolve())}function ri(i,e,...t){var o=i,r=_t,a;Zi(()=>{r!==(r=e())&&(a&&(ji(a),a=null),Ae&&r==null&&Xg(),a=Ni(()=>r(o,...t)))},65536),tt&&(o=yt)}if(Ae){let i=function(e){if(!(e in globalThis)){let t;Object.defineProperty(globalThis,e,{configurable:!0,get:()=>{if(t!==void 0)return t;eh(e)},set:o=>{t=o}})}};T1=i,i("$state"),i("$effect"),i("$derived"),i("$inspect"),i("$props"),i("$bindable")}var T1;function Dt(i){Wt===null&&Il("onMount"),ms&&Wt.l!==null?C1(Wt).m.push(i):Oe(()=>{let e=Pt(i);if(typeof e=="function")return e})}function pn(i){Wt===null&&Il("onDestroy"),Dt(()=>()=>Pt(i))}function C1(i){var t;var e=i.l;return(t=e.u)!=null?t:e.u={a:[],b:[],m:[]}}var Dh=new Map;function Oh(i,e){var t=Dh.get(i);t||(t=new Set,Dh.set(i,t)),t.add(e)}function V(i,e,[t,o]=[0,0]){tt&&t===0&&Xi();var r=i,a=null,l=null,d=oo,s=t>0?65536:0,u=!1;let m=(v,b=!0)=>{u=!0,p(b,v)},p=(v,b)=>{if(d===(d=v))return;let y=!1;if(tt&&o!==-1){if(t===0){let x=$u(r);x===ta?o=0:x===ia?o=1/0:(o=parseInt(x.substring(1)),o!==o&&(o=d?1/0:-1))}let _=o>t;!!d===_&&(r=Va(),Ci(r),go(!1),y=!0,o=-1)}d?(a?Rs(a):b&&(a=Ni(()=>b(r))),l&&tr(l,()=>{l=null})):(l?Rs(l):b&&(l=Ni(()=>b(r,[t+1,o]))),a&&tr(a,()=>{a=null})),y&&go(!0)};Zi(()=>{u=!1,e(m),u||p(null,null)},s),tt&&(r=yt)}function Ns(i,e,t){tt&&Xi();var o=i,r=oo,a,l=gs()?Wg:Cl;Zi(()=>{l(r,r=e())&&(a&&tr(a),a=Ni(()=>t(o)))}),tt&&(o=yt)}var aa=null;function Rf(i){aa=i}function Fd(i,e){return e}function P1(i,e,t,o){for(var r=[],a=e.length,l=0;l<a;l++)Cu(e[l].e,r,!0);var d=a>0&&r.length===0&&t!==null;if(d){var s=t.parentNode;kd(s),s.append(t),o.clear(),sa(i,e[0].prev,e[a-1].next)}Sf(r,()=>{for(var u=0;u<a;u++){var m=e[u];d||(o.delete(m.k),sa(i,m.prev,m.next)),ji(m.e,!d)}})}function yi(i,e,t,o,r,a=null){var l=i,d={flags:e,items:new Map,first:null},s=(e&4)!==0;if(s){var u=i;l=tt?Ci(Ii(u)):u.appendChild(Ln())}tt&&Xi();var m=null,p=!1,v=kn(()=>{var b=t();return ur(b)?b:b==null?[]:yd(b)});Zi(()=>{var b=n(v),y=b.length;if(p&&y===0)return;p=y===0;let _=!1;if(tt){var x=$u(l)===ia;x!==(y===0)&&(l=Va(),Ci(l),go(!1),_=!0)}if(tt){for(var I=null,T,R=0;R<y;R++){if(yt.nodeType===pr&&yt.data===Ea){l=yt,_=!0,go(!1);break}var A=b[R],P=o(A,R);T=Fh(yt,d,I,null,A,P,R,r,e,t),d.items.set(P,T),I=T}y>0&&Ci(Va())}tt||k1(b,d,l,r,e,o,t),a!==null&&(y===0?m?Rs(m):m=Ni(()=>a(l)):m!==null&&tr(m,()=>{m=null})),_&&go(!0),n(v)}),tt&&(l=yt)}function k1(i,e,t,o,r,a,l){var J,we,me,ee;var d=(r&8)!==0,s=(r&3)!==0,u=i.length,m=e.items,p=e.first,v=p,b,y=null,_,x=[],I=[],T,R,A,P;if(d)for(P=0;P<u;P+=1)T=i[P],R=a(T,P),A=m.get(R),A!==void 0&&((J=A.a)==null||J.measure(),(_!=null?_:_=new Set).add(A));for(P=0;P<u;P+=1){if(T=i[P],R=a(T,P),A=m.get(R),A===void 0){var E=v?v.e.nodes_start:t;y=Fh(E,e,y,y===null?e.first:y.next,T,R,P,o,r,l),m.set(R,y),x=[],I=[],v=y.next;continue}if(s&&A1(A,T,P,r),(A.e.f&8192)!==0&&(Rs(A.e),d&&((we=A.a)==null||we.unfix(),(_!=null?_:_=new Set).delete(A))),A!==v){if(b!==void 0&&b.has(A)){if(x.length<I.length){var z=I[0],F;y=z.prev;var U=x[0],X=x[x.length-1];for(F=0;F<x.length;F+=1)Bh(x[F],z,t);for(F=0;F<I.length;F+=1)b.delete(I[F]);sa(e,U.prev,X.next),sa(e,y,U),sa(e,X,z),v=z,y=X,P-=1,x=[],I=[]}else b.delete(A),Bh(A,v,t),sa(e,A.prev,A.next),sa(e,A,y===null?e.first:y.next),sa(e,y,A),y=A;continue}for(x=[],I=[];v!==null&&v.k!==R;)(v.e.f&8192)===0&&(b!=null?b:b=new Set).add(v),I.push(v),v=v.next;if(v===null)continue;A=v}x.push(A),y=A,v=A.next}if(v!==null||b!==void 0){for(var ae=b===void 0?[]:yd(b);v!==null;)(v.e.f&8192)===0&&ae.push(v),v=v.next;var Z=ae.length;if(Z>0){var re=(r&4)!==0&&u===0?t:null;if(d){for(P=0;P<Z;P+=1)(me=ae[P].a)==null||me.measure();for(P=0;P<Z;P+=1)(ee=ae[P].a)==null||ee.fix()}P1(e,ae,re,m)}}d&&Mn(()=>{var _e;if(_!==void 0)for(A of _)(_e=A.a)==null||_e.apply()}),$t.first=e.first&&e.first.e,$t.last=y&&y.e}function A1(i,e,t,o){(o&1)!==0&&Ll(i.v,e),(o&2)!==0?Ll(i.i,t):i.i=t}function Fh(i,e,t,o,r,a,l,d,s,u){var m=aa,p=(s&1)!==0,v=(s&16)===0,b=p?v?hs(r,!1,!1):Mr(r):r,y=(s&2)===0?l:Mr(l);Ae&&p&&(b.trace=()=>{var x=typeof y=="number"?l:y.v;u()[x]});var _={i:y,v:b,k:a,a:null,e:null,prev:t,next:o};aa=_;try{return _.e=Ni(()=>d(i,b,y,u),tt),_.e.prev=t&&t.e,_.e.next=o&&o.e,t===null?e.first=_:(t.next=_,t.e.next=_.e),o!==null&&(o.prev=_,o.e.prev=_.e),_}finally{aa=m}}function Bh(i,e,t){for(var o=i.next?i.next.e.nodes_start:t,r=e?e.e.nodes_start:t,a=i.e.nodes_start;a!==o;){var l=Zo(a);r.before(a),a=l}}function sa(i,e,t){e===null?i.first=t:(e.next=t,e.e.next=t&&t.e),t!==null&&(t.prev=e,t.e.prev=e&&e.e)}function L1(i,e,t){var a,l;if(!e||e===kh(String(t!=null?t:"")))return;let o,r=(a=i.__svelte_meta)==null?void 0:a.loc;r?o=`near ${r.file}:${r.line}:${r.column}`:(l=fr)!=null&&l[Xn]&&(o=`in ${fr[Xn]}`),dh(Lu(o))}function Ud(i,e,t=!1,o=!1,r=!1){var a=i,l="";O(()=>{var b;var d=$t;if(l===(l=(b=e())!=null?b:"")){tt&&Xi();return}if(d.nodes_start!==null&&(xf(d.nodes_start,d.nodes_end),d.nodes_start=d.nodes_end=null),l!==""){if(tt){for(var s=yt.data,u=Xi(),m=u;u!==null&&(u.nodeType!==pr||u.data!=="");)m=u,u=Zo(u);if(u===null)throw ra(),fs;Ae&&!r&&L1(u.parentNode,s,l),No(yt,m),a=Ci(u);return}var p=l+"";t?p=`<svg>${p}</svg>`:o&&(p=`<math>${p}</math>`);var v=Bl(p);if((t||o)&&(v=Ii(v)),No(Ii(v),v.lastChild),t||o)for(;Ii(v);)a.before(Ii(v));else a.before(v)}})}function Di(i,e,t){tt&&Xi();var o=i,r,a;Zi(()=>{r!==(r=e())&&(a&&(tr(a),a=null),r&&(a=Ni(()=>t(o,r))))},65536),tt&&(o=yt)}function Fa(i,e,t,o,r,a){var y;let l=tt;tt&&Xi();var d=Ae&&a&&((y=Wt)==null?void 0:y.function[Xn]),s,u,m=null;tt&&yt.nodeType===fu&&(m=yt,Xi());var p=tt?yt:i,v,b=aa;Zi(()=>{let _=e()||null;var x=r?r():t||_==="svg"?du:null;if(_!==s){var I=aa;Rf(b),v&&(_===null?tr(v,()=>{v=null,u=null}):_===u?Rs(v):(ji(v),Mu(!1))),_&&_!==u&&(v=Ni(()=>{if(m=tt?m:x?document.createElementNS(x,_):document.createElement(_),Ae&&a&&(m.__svelte_meta={loc:{file:d,line:a[0],column:a[1]}}),No(m,m),o){tt&&Rh(_)&&m.append(document.createComment(""));var T=tt?Ii(m):m.appendChild(Ln());tt&&(T===null?go(!1):Ci(T)),o(m,T)}$t.nodes_end=m,p.before(m)})),s=_,s&&(u=s),Mu(!0),Rf(I)}},65536),l&&(go(!0),Ci(p))}var Df;function Uh(i){return Df=i.target,new Nf(i)}var Ds,Vr,Nf=class{constructor(e){ea(this,Ds);ea(this,Vr);var a,l;var t=new Map,o=(d,s)=>{var u=hs(s,!1,!1);return t.set(d,u),u};let r=new Proxy(Gt(ke({},e.props||{}),{$$events:{}}),{get(d,s){var u;return n((u=t.get(s))!=null?u:o(s,Reflect.get(d,s)))},has(d,s){var u;return s===wl?!0:(n((u=t.get(s))!=null?u:o(s,Reflect.get(d,s))),Reflect.has(d,s))},set(d,s,u){var m;return N((m=t.get(s))!=null?m:o(s,u),u),Reflect.set(d,s,u)}});xl(this,Vr,(e.hydrate?Lf:is)(e.component,{target:e.target,anchor:e.anchor,props:r,context:e.context,intro:(a=e.intro)!=null?a:!1,recover:e.recover})),(!((l=e==null?void 0:e.props)!=null&&l.$$host)||e.sync===!1)&&Dl(),xl(this,Ds,r.$$events);for(let d of Object.keys(Ri(this,Vr)))d==="$set"||d==="$destroy"||d==="$on"||mo(this,d,{get(){return Ri(this,Vr)[d]},set(s){Ri(this,Vr)[d]=s},enumerable:!0});Ri(this,Vr).$set=d=>{Object.assign(r,d)},Ri(this,Vr).$destroy=()=>{Ha(Ri(this,Vr))}}$set(e){Ri(this,Vr).$set(e)}$on(e,t){Ri(this,Ds)[e]=Ri(this,Ds)[e]||[];let o=(...r)=>t.call(this,...r);return Ri(this,Ds)[e].push(o),()=>{Ri(this,Ds)[e]=Ri(this,Ds)[e].filter(r=>r!==o)}}$destroy(){Ri(this,Vr).$destroy()}};Ds=new WeakMap,Vr=new WeakMap;function Q(i,e){Mn(()=>{var r,a,l;var t=i.getRootNode(),o=t.host?t:(l=(r=t.head)!=null?r:t.ownerDocument.head)!=null?l:(a=Df)==null?void 0:a.parentNode;if(!(o!=null&&o.querySelector("#"+e.hash))){let d=document.createElement("style");d.id=e.hash,d.textContent=e.code,o.appendChild(d),Ae&&Oh(e.hash,d)}})}function Os(i,e){var t=void 0,o;Zi(()=>{t!==(t=e())&&(o&&(ji(o),o=null),t&&(o=Ni(()=>{Ro(()=>t(i))})))})}function zh(i){var e,t,o="";if(typeof i=="string"||typeof i=="number")o+=i;else if(typeof i=="object")if(Array.isArray(i)){var r=i.length;for(e=0;e<r;e++)i[e]&&(t=zh(i[e]))&&(o&&(o+=" "),o+=t)}else for(t in i)i[t]&&(o&&(o+=" "),o+=t);return o}function Wh(){for(var i,e,t=0,o="",r=arguments.length;t<r;t++)(i=arguments[t])&&(e=zh(i))&&(o&&(o+=" "),o+=e);return o}function zd(i){return typeof i=="object"?Wh(i):i!=null?i:""}var Kh=[...`
|
|
44
|
-
\r\f \v\uFEFF`];function Qh(i,e,t){var o=i==null?"":""+i;if(e&&(o=o?o+" "+e:e),t){for(var r in t)if(t[r])o=o?o+" "+r:r;else if(o.length)for(var a=r.length,l=0;(l=o.indexOf(r,l))>=0;){var d=l+a;(l===0||Kh.includes(o[l-1]))&&(d===o.length||Kh.includes(o[d]))?o=(l===0?"":o.substring(0,l))+o.substring(d+1):l=d}}return o===""?null:o}function qh(i,e=!1){var t=e?" !important;":";",o="";for(var r in i){var a=i[r];a!=null&&a!==""&&(o+=" "+r+": "+a+t)}return o}function Of(i){return i[0]!=="-"||i[1]!=="-"?i.toLowerCase():i}function Gh(i,e){if(e){var t="",o,r;if(Array.isArray(e)?(o=e[0],r=e[1]):o=e,i){i=String(i).replaceAll(/\s*\/\*.*?\*\/\s*/g,"").trim();var a=!1,l=0,d=!1,s=[];o&&s.push(...Object.keys(o).map(Of)),r&&s.push(...Object.keys(r).map(Of));var u=0,m=-1;let _=i.length;for(var p=0;p<_;p++){var v=i[p];if(d?v==="/"&&i[p-1]==="*"&&(d=!1):a?a===v&&(a=!1):v==="/"&&i[p+1]==="*"?d=!0:v==='"'||v==="'"?a=v:v==="("?l++:v===")"&&l--,!d&&a===!1&&l===0){if(v===":"&&m===-1)m=p;else if(v===";"||p===_-1){if(m!==-1){var b=Of(i.substring(u,m).trim());if(!s.includes(b)){v!==";"&&p++;var y=i.substring(u,p).trim();t+=" "+y+";"}}u=p+1,m=-1}}}}return o&&(t+=qh(o)),r&&(t+=qh(r,!0)),t=t.trim(),t===""?null:t}return i==null?null:String(i)}function oe(i,e,t,o,r,a){var l=i.__className;if(tt||l!==t||l===void 0){var d=Qh(t,o,a);(!tt||d!==i.getAttribute("class"))&&(d==null?i.removeAttribute("class"):e?i.className=d:i.setAttribute("class",d)),i.__className=t}else if(a&&r!==a)for(var s in a){var u=!!a[s];(r==null||u!==!!r[s])&&i.classList.toggle(s,u)}return a}function Bf(i,e={},t,o){for(var r in t){var a=t[r];e[r]!==a&&(t[r]==null?i.style.removeProperty(r):i.style.setProperty(r,a,o))}}function qe(i,e,t,o){var r=i.__style;if(tt||r!==e){var a=Gh(e,o);(!tt||a!==i.getAttribute("style"))&&(a==null?i.removeAttribute("style"):i.style.cssText=a),i.__style=e}else o&&(Array.isArray(o)?(Bf(i,t==null?void 0:t[0],o[0]),Bf(i,t==null?void 0:t[1],o[1],"important")):Bf(i,t,o));return o}function Wd(i,e,t){if(i.multiple){if(e==null)return;if(!ur(e))return uh();for(var o of i.options)o.selected=e.includes(Yh(o));return}for(o of i.options){var r=Yh(o);if(uf(r,e)){o.selected=!0;return}}(!t||e!==void 0)&&(i.selectedIndex=-1)}function Hf(i){var e=new MutationObserver(()=>{Wd(i,i.__value)});e.observe(i,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),Vo(()=>{e.disconnect()})}function Yh(i){return"__value"in i?i.__value:i.value}var Fl=Symbol("class"),Ul=Symbol("style"),Zh=Symbol("is custom element"),Jh=Symbol("is html");function e_(i,e){e?i.hasAttribute("selected")||i.setAttribute("selected",""):i.removeAttribute("selected")}function Re(i,e,t,o){var r=i_(i);if(tt&&(r[e]=i.getAttribute(e),e==="src"||e==="srcset"||e==="href"&&i.nodeName==="LINK")){o||H1(i,e,t!=null?t:"");return}r[e]!==(r[e]=t)&&(e==="loading"&&(i[zg]=t),t==null?i.removeAttribute(e):typeof t!="string"&&o_(i).includes(e)?i[e]=t:i.setAttribute(e,t))}function t_(i,e,t,o,r=!1){var A;var a=i_(i),l=a[Zh],d=!a[Jh];let s=tt&&l;s&&go(!1);var u=e||{},m=i.tagName==="OPTION";for(var p in e)p in t||(t[p]=null);t.class?t.class=zd(t.class):(o||t[Fl])&&(t.class=null),t[Ul]&&((A=t.style)!=null||(t.style=null));var v=o_(i);for(let P in t){let E=t[P];if(m&&P==="value"&&E==null){i.value=i.__value="",u[P]=E;continue}if(P==="class"){var b=i.namespaceURI==="http://www.w3.org/1999/xhtml";oe(i,b,E,o,e==null?void 0:e[Fl],t[Fl]),u[P]=E,u[Fl]=t[Fl];continue}if(P==="style"){qe(i,E,e==null?void 0:e[Ul],t[Ul]),u[P]=E,u[Ul]=t[Ul];continue}var y=u[P];if(!(E===y&&!(E===void 0&&i.hasAttribute(P)))){u[P]=E;var _=P[0]+P[1];if(_!=="$$")if(_==="on"){let z={},F="$$"+P,U=P.slice(2);var x=Lh(U);if(Ah(U)&&(U=U.slice(0,-7),z.capture=!0),!x&&y){if(E!=null)continue;i.removeEventListener(U,u[F],z),u[F]=null}if(E!=null)if(x)i[`__${U}`]=E,Ye([U]);else{let X=function(ae){u[P].call(this,ae)};var R=X;u[F]=kf(U,i,X,z)}else x&&(i[`__${U}`]=void 0)}else if(P==="style")Re(i,P,E);else if(P==="autofocus")Ef(i,!!E);else if(!l&&(P==="__value"||P==="value"&&E!=null))i.value=i.__value=E;else if(P==="selected"&&m)e_(i,E);else{var I=P;d||(I=Mh(I));var T=I==="defaultValue"||I==="defaultChecked";if(E==null&&!l&&!T)if(a[P]=null,I==="value"||I==="checked"){let z=i,F=e===void 0;if(I==="value"){let U=z.defaultValue;z.removeAttribute(I),z.defaultValue=U,z.value=z.__value=F?U:null}else{let U=z.defaultChecked;z.removeAttribute(I),z.defaultChecked=U,z.checked=F?U:!1}}else i.removeAttribute(P);else T||v.includes(I)&&(l||typeof E!="string")?i[I]=E:typeof E!="function"&&Re(i,I,E,r)}}}return s&&go(!0),u}function no(i,e,t=[],o,r=!1,a=Jr){let l=t.map(a);var d=void 0,s={},u=i.nodeName==="SELECT",m=!1;if(Zi(()=>{var v=e(...l.map(n)),b=t_(i,d,v,o,r);m&&u&&"value"in v&&Wd(i,v.value,!1);for(let _ of Object.getOwnPropertySymbols(s))v[_]||ji(s[_]);for(let _ of Object.getOwnPropertySymbols(v)){var y=v[_];_.description===of&&(!d||y!==d[_])&&(s[_]&&ji(s[_]),s[_]=Ni(()=>Os(i,()=>y))),b[_]=y}d=b}),u){var p=i;Ro(()=>{Wd(p,d.value),Hf(p)})}m=!0}function i_(i){var e;return(e=i.__attributes)!=null?e:i.__attributes={[Zh]:i.nodeName.includes("-"),[Jh]:i.namespaceURI===Ng}}var jh=new Map;function o_(i){var e=jh.get(i.nodeName);if(e)return e;jh.set(i.nodeName,e=[]);for(var t,o=i,r=Element.prototype;r!==o;){t=uu(o);for(var a in t)t[a].set&&e.push(a);o=Pa(o)}return e}function H1(i,e,t){var o;Ae&&(e==="srcset"&&F1(i,t)||Ff((o=i.getAttribute(e))!=null?o:"",t)||lh(e,i.outerHTML.replace(i.innerHTML,i.innerHTML&&"..."),String(t)))}function Ff(i,e){return i===e?!0:new URL(i,document.baseURI).href===new URL(e,document.baseURI).href}function Xh(i){return i.split(",").map(e=>e.trim().split(" ").filter(Boolean))}function F1(i,e){var t=Xh(i.srcset),o=Xh(e);return o.length===t.length&&o.every(([r,a],l)=>a===t[l][1]&&(Ff(t[l][0],r)||Ff(r,t[l][0])))}var U1=cu?()=>performance.now():()=>Date.now(),os={tick:i=>(cu?requestAnimationFrame:_t)(i),now:()=>U1(),tasks:new Set};function n_(){let i=os.now();os.tasks.forEach(e=>{e.c(i)||(os.tasks.delete(e),e.f())}),os.tasks.size!==0&&os.tick(n_)}function r_(i){let e;return os.tasks.size===0&&os.tick(n_),{promise:new Promise(t=>{os.tasks.add(e={c:i,f:t})}),abort(){os.tasks.delete(e)}}}function Vu(i,e){Bd(()=>{i.dispatchEvent(new CustomEvent(e))})}function q1(i){if(i==="float")return"cssFloat";if(i==="offset")return"cssOffset";if(i.startsWith("--"))return i;let e=i.split("-");return e.length===1?e[0]:e[0]+e.slice(1).map(t=>t[0].toUpperCase()+t.slice(1)).join("")}function s_(i){let e={},t=i.split(";");for(let o of t){let[r,a]=o.split(":");if(!r||a===void 0)break;let l=q1(r.trim());e[l]=a.trim()}return e}var Q1=i=>i;function ns(i,e,t,o){var R;var r=(i&1)!==0,a=(i&2)!==0,l=r&&a,d=(i&4)!==0,s=l?"both":r?"in":"out",u,m=e.inert,p=e.style.overflow,v,b;function y(){var E;var A=Ht,P=$t;Yi(null),vo(null);try{return u!=null?u:u=t()(e,(E=o==null?void 0:o())!=null?E:{},{direction:s})}finally{Yi(A),vo(P)}}var _={is_global:d,in(){var A;if(e.inert=m,!r){b==null||b.abort(),(A=b==null?void 0:b.reset)==null||A.call(b);return}a||v==null||v.abort(),Vu(e,"introstart"),v=Uf(e,y(),b,1,()=>{Vu(e,"introend"),v==null||v.abort(),v=u=void 0,e.style.overflow=p})},out(A){if(!a){A==null||A(),u=void 0;return}e.inert=!0,Vu(e,"outrostart"),b=Uf(e,y(),v,0,()=>{Vu(e,"outroend"),A==null||A()})},stop:()=>{v==null||v.abort(),b==null||b.abort()}},x=$t;if(((R=x.transitions)!=null?R:x.transitions=[]).push(_),r&&Hd){var I=d;if(!I){for(var T=x.parent;T&&(T.f&65536)!==0;)for(;(T=T.parent)&&(T.f&16)===0;);I=!T||(T.f&32768)!==0}I&&Ro(()=>{Pt(()=>_.in())})}}function Uf(i,e,t,o,r){var a=o===1;if(oa(e)){var l,d=!1;return Mn(()=>{if(!d){var x=e({direction:a?"in":"out"});l=Uf(i,x,t,o,r)}}),{abort:()=>{d=!0,l==null||l.abort()},deactivate:()=>l.deactivate(),reset:()=>l.reset(),t:()=>l.t()}}if(t==null||t.deactivate(),!(e!=null&&e.duration))return r(),{abort:_t,deactivate:_t,reset:_t,t:()=>o};let{delay:s=0,css:u,tick:m,easing:p=Q1}=e;var v=[];if(a&&t===void 0&&(m&&m(0,1),u)){var b=s_(u(0,1));v.push(b,b)}var y=()=>1-o,_=i.animate(v,{duration:s,fill:"forwards"});return _.onfinish=()=>{var U;_.cancel();var x=(U=t==null?void 0:t.t())!=null?U:1-o;t==null||t.abort();var I=o-x,T=e.duration*Math.abs(I),R=[];if(T>0){var A=!1;if(u)for(var P=Math.ceil(T/16.666666666666668),E=0;E<=P;E+=1){var z=x+I*p(E/P),F=s_(u(z,1-z));R.push(F),A||(A=F.overflow==="hidden")}A&&(i.style.overflow="hidden"),y=()=>{var X=_.currentTime;return x+I*p(X/T)},m&&r_(()=>{if(_.playState!=="running")return!1;var X=y();return m(X,1-X),!0})}_=i.animate(R,{duration:T,fill:"forwards"}),_.onfinish=()=>{y=()=>o,m==null||m(o,1-o),r()}},{abort:()=>{_&&(_.cancel(),_.effect=null,_.onfinish=_t)},deactivate:()=>{r=_t},reset:()=>{o===0&&(m==null||m(1,0))},t:()=>y()}}function zf(i,e,t){var o=Go(i,e);o&&o.set&&(i[e]=t,Vo(()=>{i[e]=null}))}var la,zl,Kd,Nu,a_,Du=class Du{constructor(e){ea(this,Nu);ea(this,la,new WeakMap);ea(this,zl);ea(this,Kd);xl(this,Kd,e)}observe(e,t){var o=Ri(this,la).get(e)||new Set;return o.add(t),Ri(this,la).set(e,o),Vg(this,Nu,a_).call(this).observe(e,Ri(this,Kd)),()=>{var r=Ri(this,la).get(e);r.delete(t),r.size===0&&(Ri(this,la).delete(e),Ri(this,zl).unobserve(e))}}};la=new WeakMap,zl=new WeakMap,Kd=new WeakMap,Nu=new WeakSet,a_=function(){var e;return(e=Ri(this,zl))!=null?e:xl(this,zl,new ResizeObserver(t=>{for(var o of t){Du.entries.set(o.target,o);for(var r of Ri(this,la).get(o.target)||[])r(o)}}))},cr(Du,"entries",new WeakMap);var Wf=Du;var G1=new Wf({box:"border-box"});function Rn(i,e,t){var o=G1.observe(i,()=>t(i[e]));Ro(()=>(Pt(()=>t(i[e])),o))}function l_(i,e){return i===e||(i==null?void 0:i[Yo])===e}function Xe(i={},e,t,o){return Ro(()=>{var r,a;return Jo(()=>{r=a,a=(o==null?void 0:o())||[],Pt(()=>{i!==t(...a)&&(e(i,...a),r&&l_(t(...r),i)&&e(null,...r))})}),()=>{Mn(()=>{a&&l_(t(...a),i)&&e(null,...a)})}}),i}function $o(i=!1){let e=Wt,t=e.l.u;if(!t)return;let o=()=>ku(e.s);if(i){let r=0,a={},l=Jr(()=>{let d=!1,s=e.s;for(let u in s)s[u]!==a[u]&&(a[u]=s[u],d=!0);return d&&r++,r});o=()=>n(l)}t.b.length&&Md(()=>{d_(e,o),na(t.b)}),Oe(()=>{let r=Pt(()=>t.m.map(Ug));return()=>{for(let a of r)typeof a=="function"&&a()}}),t.a.length&&Oe(()=>{d_(e,o),na(t.a)})}function d_(i,e){if(i.l.s)for(let t of i.l.s)n(t);e()}function qd(i,e,t){if(i==null)return e(void 0),t&&t(void 0),_t;let o=Pt(()=>i.subscribe(e,t));return o.unsubscribe?()=>o.unsubscribe():o}var Wl=[];function Rr(i,e){return{subscribe:de(i,e).subscribe}}function de(i,e=_t){let t=null,o=new Set;function r(d){if(Cl(i,d)&&(i=d,t)){let s=!Wl.length;for(let u of o)u[1](),Wl.push(u,i);if(s){for(let u=0;u<Wl.length;u+=2)Wl[u][0](Wl[u+1]);Wl.length=0}}}function a(d){r(d(i))}function l(d,s=_t){let u=[d,s];return o.add(u),o.size===1&&(t=e(r,a)||_t),d(i),()=>{o.delete(u),o.size===0&&t&&(t(),t=null)}}return{set:r,update:a,subscribe:l}}function gi(i,e,t){let o=!Array.isArray(i),r=o?[i]:i;if(!r.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");let a=e.length<2;return Rr(t,(l,d)=>{let s=!1,u=[],m=0,p=_t,v=()=>{if(m)return;p();let y=e(o?u[0]:u,l,d);a?l(y):p=typeof y=="function"?y:_t},b=r.map((y,_)=>qd(y,x=>{u[_]=x,m&=~(1<<_),s&&v()},()=>{m|=1<<_}));return s=!0,v(),function(){na(b),p(),s=!1}})}function ye(i){let e;return qd(i,t=>e=t)(),e}var Ou=!1,Kf=Symbol();function w(i,e,t){var a;let o=(a=t[e])!=null?a:t[e]={store:null,source:hs(void 0),unsubscribe:_t};if(o.store!==i&&!(Kf in t))if(o.unsubscribe(),o.store=i!=null?i:null,i==null)o.source.v=void 0,o.unsubscribe=_t;else{var r=!0;o.unsubscribe=qd(i,l=>{r?o.source.v=l:N(o.source,l)}),r=!1}return i&&Kf in t?ye(i):n(o.source)}function De(){let i={};function e(){Vo(()=>{for(var t in i)i[t].unsubscribe();mo(i,Kf,{enumerable:!1,value:!0})})}return[i,e]}function qf(i){var e=Ou;try{return Ou=!1,[i(),Ou]}finally{Ou=e}}var ty={get(i,e){if(!i.exclude.includes(e))return i.props[e]},set(i,e){return Ae&&Jg(`${i.name}.${String(e)}`),!1},getOwnPropertyDescriptor(i,e){if(!i.exclude.includes(e)&&e in i.props)return{enumerable:!0,configurable:!0,value:i.props[e]}},has(i,e){return i.exclude.includes(e)?!1:e in i.props},ownKeys(i){return Reflect.ownKeys(i.props).filter(e=>!i.exclude.includes(e))}};function Nn(i,e,t){return new Proxy(Ae?{props:i,exclude:e,name:t,other:{},to_proxy:[]}:{props:i,exclude:e},ty)}var iy={get(i,e){let t=i.props.length;for(;t--;){let o=i.props[t];if(oa(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o)return o[e]}},set(i,e,t){let o=i.props.length;for(;o--;){let r=i.props[o];oa(r)&&(r=r());let a=Go(r,e);if(a&&a.set)return a.set(t),!0}return!1},getOwnPropertyDescriptor(i,e){let t=i.props.length;for(;t--;){let o=i.props[t];if(oa(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o){let r=Go(o,e);return r&&!r.configurable&&(r.configurable=!0),r}}},has(i,e){if(e===Yo||e===wl)return!1;for(let t of i.props)if(oa(t)&&(t=t()),t!=null&&e in t)return!0;return!1},ownKeys(i){let e=[];for(let t of i.props)if(oa(t)&&(t=t()),!!t){for(let o in t)e.includes(o)||e.push(o);for(let o of Object.getOwnPropertySymbols(t))e.includes(o)||e.push(o)}return e}};function rs(...i){return new Proxy({props:i},iy)}function c_(i){var e,t;return(t=(e=i.ctx)==null?void 0:e.d)!=null?t:!1}function h(i,e,t,o){var z,F;var r=(t&1)!==0,a=!ms||(t&2)!==0,l=(t&8)!==0,d=(t&16)!==0,s=!1,u;l?[u,s]=qf(()=>i[e]):u=i[e];var m=Yo in i||wl in i,p=l&&((F=(z=Go(i,e))==null?void 0:z.set)!=null?F:m&&e in i&&(U=>i[e]=U))||void 0,v=o,b=!0,y=!1,_=()=>(y=!0,b&&(b=!1,d?v=Pt(o):v=o),v);u===void 0&&o!==void 0&&(p&&a&&Zg(e),u=_(),p&&p(u));var x;if(a)x=()=>{var U=i[e];return U===void 0?_():(b=!0,y=!1,U)};else{var I=(r?Jr:kn)(()=>i[e]);I.f|=131072,x=()=>{var U=n(I);return U!==void 0&&(v=void 0),U===void 0?v:U}}if((t&4)===0&&a)return x;if(p){var T=i.$$legacy;return function(U,X){return arguments.length>0?((!a||!X||T||s)&&p(X?x():U),U):x()}}var R=!1,A=!1,P=hs(u),E=Jr(()=>{var U=x(),X=n(P);return R?(R=!1,A=!0,X):(A=!1,P.v=U)});return l&&n(E),r||(E.equals=Tl),function(U,X){if(Eu!==null&&(R=A,x(),n(P)),arguments.length>0){let ae=X?n(E):a&&l?ui(U):U;if(!E.equals(ae)){if(R=!0,N(P,ae),y&&v!==void 0&&(v=ae),c_(E))return U;Pt(()=>n(E))}return U}return c_(E)?E.v:n(E)}}var oy;typeof HTMLElement=="function"&&(oy=class extends HTMLElement{constructor(e,t,o){super();cr(this,"$$ctor");cr(this,"$$s");cr(this,"$$c");cr(this,"$$cn",!1);cr(this,"$$d",{});cr(this,"$$r",!1);cr(this,"$$p_d",{});cr(this,"$$l",{});cr(this,"$$l_u",new Map);cr(this,"$$me");this.$$ctor=e,this.$$s=t,o&&this.attachShadow({mode:"open"})}addEventListener(e,t,o){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){let r=this.$$c.$on(e,t);this.$$l_u.set(t,r)}super.addEventListener(e,t,o)}removeEventListener(e,t,o){if(super.removeEventListener(e,t,o),this.$$c){let r=this.$$l_u.get(t);r&&(r(),this.$$l_u.delete(t))}}connectedCallback(){return ht(this,null,function*(){if(this.$$cn=!0,!this.$$c){let t=function(a){return l=>{let d=document.createElement("slot");a!=="default"&&(d.name=a),$(l,d)}};var e=t;if(yield Promise.resolve(),!this.$$cn||this.$$c)return;let o={},r=ny(this);for(let a of this.$$s)a in r&&(a==="default"&&!this.$$d.children?(this.$$d.children=t(a),o.default=!0):o[a]=t(a));for(let a of this.attributes){let l=this.$$g_p(a.name);l in this.$$d||(this.$$d[l]=Qf(l,a.value,this.$$p_d,"toProp"))}for(let a in this.$$p_d)!(a in this.$$d)&&this[a]!==void 0&&(this.$$d[a]=this[a],delete this[a]);this.$$c=Uh({component:this.$$ctor,target:this.shadowRoot||this,props:Gt(ke({},this.$$d),{$$slots:o,$$host:this})}),this.$$me=Su(()=>{Jo(()=>{var a;this.$$r=!0;for(let l of nf(this.$$c)){if(!((a=this.$$p_d[l])!=null&&a.reflect))continue;this.$$d[l]=this.$$c[l];let d=Qf(l,this.$$d[l],this.$$p_d,"toAttribute");d==null?this.removeAttribute(this.$$p_d[l].attribute||l):this.setAttribute(this.$$p_d[l].attribute||l,d)}this.$$r=!1})});for(let a in this.$$l)for(let l of this.$$l[a]){let d=this.$$c.$on(a,l);this.$$l_u.set(l,d)}this.$$l={}}})}attributeChangedCallback(e,t,o){var r;this.$$r||(e=this.$$g_p(e),this.$$d[e]=Qf(e,o,this.$$p_d,"toProp"),(r=this.$$c)==null||r.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return nf(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Qf(i,e,t,o){var a;let r=(a=t[i])==null?void 0:a.type;if(e=r==="Boolean"&&typeof e!="boolean"?e!=null:e,!o||!t[i])return e;if(o==="toAttribute")switch(r){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e==null?null:e;default:return e}else switch(r){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}function ny(i){let e={};return i.childNodes.forEach(t=>{e[t.slot||"default"]=!0}),e}var u_="5";var p_,f_,m_;typeof window!="undefined"&&((m_=(f_=(p_=window.__svelte)!=null?p_:window.__svelte={}).v)!=null?m_:f_.v=new Set).add(u_);var cd=require("@vkontakte/videoplayer-core/es2015"),MJ=require("@vkontakte/videoplayer-core/es2015"),ml=require("@vkontakte/videoplayer-shared/es2015"),C$=require("@vkontakte/videoplayer-statistics/es2015");var Ua=require("@vkontakte/videoplayer-shared/es2015");var ry={isMobile:void 0,disableInvisibleComponentsTimeout:500,debugLog:!1,devNullLog:!1,defaultLanguage:Ua.InterfaceLanguage.RU,downloadVKLanguages:!0,updateBuiltinLanguages:!0,isSmoothVideoRotate:!0,showSupport:!0,supportLink:"https://vk.com/support?act=new&from=v",showLogo:void 0,logoLink:"https://vk.com/video",logoType:"vk_video",volumeDefault:1,volumeMinRestore:.05,loaderDelay:500,minSubtitlesFontSize:13,autoSubtitlesTimeout:2e3,allowChangingFullscreenTarget:!0,trafficSavingLimit:Ua.VideoQuality.Q_480P,highQualityLimit:Ua.VideoQuality.Q_720P,episodeMinWidthPc:8,hideThumbTimerAfterTouch:!0,preventPauseOnVideoClick:!1,sentry:{dsn:"https://e349fd23c68f405388980d0868d0ff27@sentry.mvk.com/126",sampleRate:.01,whiteErrorCategoryList:[],blackErrorCategoryList:[],whiteErrorIdList:[],blackErrorIdList:[]},features:{autoplay:!0,statistics:!0,thinStatistics:!1,sentry:!0,preload:!0,subtitles:!0,episodes:!0,fullscreen:!0,timelinePreview:!0,mediaSession:!0,annotations:!0,slots:!0,annotationsInside:!1,pip:!0,dpip:!0,download:!0,liveRewind:!0,playbackRate:!0,trafficSaving:!0,episodesClustering:!0,copyVideoLink:!0,videoRotate:!0,tracer:!1,interactiveGraph:!1,interactiveResponsiveUi:!1,seekToInteractive:!0,interactiveLastFrame:!1,interactiveTextPermanent:!0,interactiveHideTime:!0,interactivePlayPrevChapter:!0,interactiveTimeIndicator:!0,interactiveTimeOpenUri:!1,interactiveAreaControlShadow:!1,interactiveControlsExpectTimeBlinkAnimation:!1,interactiveControlsTapPlace:!1,interactiveControlsFillAnimation:!1,interactiveControlsHideAnimation:!1,interactiveHistoryEndChapterFix:!0,thumbTimer:!0,hotKeyMapModal:!0,hotKeyHelpers:!0,saveDebugInfoToFile:!1,saveTraceInfoToFile:!1,additionalButtons:!0,additionalButtonsDesktopControlPanelRight:!0,additionalSettingsMenuItems:!0,additionalContextMenuItems:!0,contextMenuButton:!0,audioLanguages:!1,saveRate:!1,fullscreenInternalTargetPlayerContainer:!1,endScreen:!0,autoplayNext:!0,nextPrevButtons:!0,previewNoEmptySpace:!1,exposeInternalsToGlobal:!1,qualityDetailsSubMenuEnabled:!1,showSlowVideoNotification:!1,forceAutoQualityWhenSevereStallHappens:!1,timeoutShowSlowVideoNotification:0,maxCountShowSlowVideoNotification:1,forcePlayerDisplayBlock:!1,playbackStatusShow:!1,playbackStatusNextVideoShow:!1,initSubtitles:!0,useCallbackForMediaSessionNextPrevClick:!1,usePerformanceFix:!1,userVideoPrefs:!1,savePreferredStatesOnUserActionOnly:!1,useLoopSetting:!1,doubleForwardAvailable:!1,useRichSeek:!1,disableThumbUnstartedOnAutoplay:!1},controls:{showOnStartupAtAutoplay:!0,hideTimeout:500,hideTimeoutMobile:3e3,hideTimeoutInitial:200,hideTimeoutFullscreen:3e3,hideTimeoutCursor:3e3,hideTimeoutTooltips:1e3,collapseMobileUnmute:6e3,hide360IconTimeout:3e3,hideHotKeyHelpers:2e3,playbackRateMin:.25,playbackRateMax:2,playbackRateStep:.25,volumeStepKeyboard:.05,volumeStepWheel:.05,volumeBarTimeout:300,seekStepKeyboard:1e4,seekStepMobile:15e3,seekStepFrame:400},ads:{enable:void 0,initTimeout:2e3,loadTimeout:2e3,runtimeTimeout:5e3,slot:void 0,preview:void 0,paramsOverride:void 0,isMobileGoToSiteButton:!0,useAdmanFromNPM:!1,volumeMultiplier:1,isVsidOriginal:!1},interactive:{historyMaxLength:100,noInteractionEventTimeout:3e4},view:{timelineSliderColor:null,timelineSliderHandleColor:null,timelineSliderFilledColor:null,timelineSliderLoadedColor:null,volumeSliderColor:null,volumeSliderHandleColor:null,volumeSliderFilledColor:null,controlsTimeColor:null,timelineSliderFilledActiveLiveColor:null,timelineSliderHandleActiveLiveColor:null,buttonColor:null,buttonToggleOnColor:null,focusedColor:null,font:null,focusedOutlineWidth:null,focusedOutlineRadius:null,controlsDesktopPaddingHorizontal:null,timelinePaddingHorizontal:null,settingsBackgroundColor:null,controlsGradientHeight:null,controlsGradient:null},userSalt:"0",doubleForwardActivationTime:600,playbackStatusAnimationDuration:1e3,playbackStatusNextVideoAnimationDuration:1e3,suitableDurationForUsingRichSeek:180,titleShowBehaviour:"fullscreen",disabledSlotIds:[],disabledAdditionalButtonIds:[]},v_=i=>(0,Ua.fillWithDefault)(i,ry),g_=i=>Pl("ui-config",i),Ot=()=>El("ui-config");var Qd="vk_player_debug_panel_opened";var h_="videoplayer",__="videoplayer";var bs={KeyF:"f",KeyK:"k",KeyC:"c",KeyM:"m"},b_=new Set(["ArrowLeft","ArrowRight","KeyL","KeyJ"]),$_=new Set(["Tab","Space","ArrowLeft","ArrowRight","ArrowUp","ArrowDown"]),y_=new Set(["ShiftRight","ShiftLeft"]);var x_=["TIMELINE"],Gd=[...x_,"GRAPH_BUTTON"],Gf=[...x_,"PLAY_BUTTON"],Yd=[...Gd,"PLAY_BUTTON"];var ss=(a=>(a.XS="xs",a.S="s",a.M="m",a.L="l",a.XL="xl",a))(ss||{}),jd={xs:0,s:1,m:2,l:3,xl:4};var Xd=require("@vkontakte/videoplayer-shared/es2015"),w_=require("@vkontakte/videoplayer-core/es2015"),S_=require("@vkontakte/videoplayer-statistics/es2015");var Bu="prod",Wa="1.1.82-dev.fbdd1f70.0";var Ka=(i,e,t)=>{let o=document.createElement("a");o.href=i,o.download=`${e}.${t}`,o.style.display="none",o.click()};var C_=Symbol("storeContext"),T_=Symbol("microStoresContext"),I_=(i,e)=>{Pl(C_,i),Pl(T_,e),Bu==="dev"&&(window.app={store:i,microStores:e})},be=()=>{let i=El(C_);return(0,Xd.assertNonNullable)(i,"Store context is empty!"),i},yo=()=>{let i=El(T_);return(0,Xd.assertNonNullable)(i,"MicroStores context is empty!"),i},si=(i,e)=>Fu(i,i.getValue(),e),Fu=(i,e,t)=>Rr(e,o=>{let r=i.subscribe(a=>{o(a),t==null||t(a)});return()=>r.unsubscribe()}),E_=(i,e,t,o,r=["meta config not provided"])=>{var F,U,X,ae,Z,re,J,we,me;let a=i.info,{width:l,height:d}=ye(t.ui.playerSize),s=(U=(F=a.throughputEstimation$.getValue())==null?void 0:F.toFixed(0))!=null?U:0,u=(ae=(X=a.rttEstimation$.getValue())==null?void 0:X.toFixed(0))!=null?ae:0,m=a.isAutoQualityEnabled$.getValue()?"auto":"manual",p=`${Wa} (core: ${w_.VERSION}, stat: ${S_.VERSION}, shared: ${Xd.VERSION})`,v=ye(t.state.errorLog$),b=v.length?`
|
|
45
|
-
`+v.map((
|
|
46
|
-
`,
|
|
47
|
-
`,
|
|
48
|
-
`;return Ce+
|
|
49
|
-
`):void 0,y=t.state.isAudioDisabled?"disabled":
|
|
50
|
-
`)},P_=(i,e,t)=>{var F,U,X,ae;let o=i.info,{width:r,height:a}=ye(t.ui.playerSize),l={version:Wa,viewport:`${r}x${a}`,volume:Math.round(ye(t.state.volume$)*100)};l.id=t.videoId,o.currentFormat$.getValue()&&(l.provider=o.currentFormat$.getValue()),o.hostname$.getValue()&&(l.cdn=o.hostname$.getValue());let u=o.intrinsicVideoSize$.getValue();u&&(l.videoSize=`${u.width}x${u.height}`);let m=o.currentBuffer$.getValue(),p=o.currentNativeBuffer$.getValue(),v=o.isLive$.getValue(),b=o.liveBufferTime$.getValue();m&&p&&(v&&b?(l.buffer=m.end-b,l.nativeBuffer=p.end-b):(l.buffer=Math.max(m.end-ye(t.state.positionExact$),0),l.nativeBuffer=Math.max(p.end-ye(t.state.positionExact$),0))),l.position=ye(t.state.positionExact$);let y=o.throughputEstimation$.getValue();y&&(l.speed=y);let _=o.videoBitrate$.getValue();_&&(l.bitrate=_);let x=o.liveLatency$.getValue();x&&(l.liveLatency=x);let I=o.currentVideoSegmentLength$.getValue();I&&(l.currentVideoSegmentLength=I);let T=o.currentAudioSegmentLength$.getValue();T&&(l.currentAudioSegmentLength=T);let R=ye(t.vsid);typeof R=="string"&&(l.vsid=R);let A=(F=i.info.currentVideoStream$.getValue())==null?void 0:F.codec;A&&(l.videoCodec=A);let P=(U=i.info.currentAudioStream$.getValue())==null?void 0:U.codec;P&&(l.audioCodec=P),((X=i.info.currentVideoStream$.getValue())==null?void 0:X.hdr)&&(l.hdr=!0);let z=(ae=i.info.currentAudioStream$.getValue())==null?void 0:ae.language;return z&&(l.audioLanguage=z),l},k_=(i,e)=>Ka(i,e,"mp4"),A_=i=>!i.type,L_=i=>!!i.type,M_=()=>{let e=[],t=0;return{add:(o,r)=>{e[t]=[o,r],t=(t+1)%10},find:o=>e.find(([r])=>r===o)}},Hu=class{constructor(){this.destroyController=new AbortController;this.pendingDownloads=new Set}download(e){return ht(this,null,function*(){if(this.pendingDownloads.has(e))return null;this.pendingDownloads.add(e);try{let t=yield fetch(e,{signal:this.destroyController.signal});if(t.ok)return yield t.text();throw t}finally{this.pendingDownloads.delete(e)}})}destroy(){this.destroyController.abort(),this.pendingDownloads.clear()}isDestroyed(){return this.destroyController.signal.aborted}};var hi=require("@vkontakte/videoplayer-shared/es2015"),nV=require("@vkontakte/videoplayer-core/es2015");var sy="vk_player_",V_="vk_player_prefer_traffic_saving_enabled",R_="vk_player_preferred_volume",N_="vk_player_prefer_volume_mute",Zf="vk_player_preferred_quality",Yf="vk_player_preferred_default_quality_settings",jf="vk_player_preferred_quality_settings_by_video",D_="vk_player_preferred_stream_language",O_="vk_player_preferred_rate",B_="vk_player_preferred_autoplay_next",Xf="vk_player_preferred_subtitles_language",H_="vk_player_user_video_prefs",F_=`${sy}preview_track_close_tooltip`,U_=i=>i>1?1:i<0?0:i,Jf=i=>hi.safeStorage.set(R_,U_(i).toString(10)),Uu=()=>{let i=hi.safeStorage.get(R_);return(0,hi.isNullable)(i)?void 0:U_(parseFloat(i))},em=(i,e)=>hi.safeStorage.set(Zf,JSON.stringify({videoId:i,value:e})),zu=()=>hi.safeStorage.remove(Zf),tm=i=>{let e=hi.safeStorage.get(Zf);if((0,hi.isNullable)(e))return;let{videoId:t,value:o}=JSON.parse(e);if(i!==t){zu();return}return o},z_=(i,e)=>{e?hi.safeStorage.set(i,"true"):hi.safeStorage.remove(i)},im=i=>hi.safeStorage.get(i)==="true",om=i=>z_(N_,i),W_=()=>im(N_),Zd=i=>z_(V_,i),nm=()=>im(V_),K_=()=>hi.safeStorage.get(D_),rm=i=>hi.safeStorage.set(D_,i),sm=()=>hi.safeStorage.get(Xf),am=i=>{i?hi.safeStorage.set(Xf,i):hi.safeStorage.remove(Xf)},q_=i=>hi.safeStorage.set(O_,JSON.stringify({rate:i})),Q_=()=>{let i=hi.safeStorage.get(O_);if((0,hi.isNullable)(i))return;let{rate:e}=JSON.parse(i);return e},G_=i=>{hi.safeStorage.set(B_,String(i))},Y_=()=>im(B_),ay=()=>{let i=m=>{hi.safeStorage.set(Yf,JSON.stringify(m))},e=()=>{try{let m=hi.safeStorage.get(Yf);return m?JSON.parse(m):null}catch(m){return null}},t=()=>{try{let m=hi.safeStorage.get(jf);return m?JSON.parse(m):null}catch(m){return null}},o=m=>{hi.safeStorage.set(jf,JSON.stringify(m))},r=m=>{u(m);let p=m?t():null;if(p&&(p==null?void 0:p.videoId)===m)return Gt(ke({},p),{appliesTo:"to-video"});p&&a();let v=e();return v?Gt(ke({},v),{appliesTo:"as-default"}):(i({type:"auto_quality"}),{type:"auto_quality",appliesTo:"as-default"})},a=()=>{hi.safeStorage.remove(jf)},l=()=>{hi.safeStorage.remove(Yf)},d=(m,p="as-default")=>{m.type==="exact_quality"||p==="to-video"?o(m):i(m)},s=m=>{let p=r(m);if(p){switch(p.type){case"traffic_saving":Zd(!0);break;case"exact_quality":em(m,p.quality)}a(),l()}},u=m=>{let p=tm(m);if(p){o({type:"exact_quality",videoId:m,quality:p});return}nm()&&i({type:"traffic_saving",videoId:m}),Zd(!1),zu()};return{getPreferredQualitySettings:r,migrateSettingsToLegacyWay:s,savePreferredQualitySettings:d,savePreferredDefaultQualitySettings:i,removePreferredQualitySettingsByVideo:a,getPreferredDefaultQualitySettings:e,getPreferredSubtitlesLanguage:sm,savePreferredSubtitlesLanguage:am}},{getPreferredQualitySettings:j_,migrateSettingsToLegacyWay:X_,savePreferredQualitySettings:Wu,savePreferredDefaultQualitySettings:rV,removePreferredQualitySettingsByVideo:sV,getPreferredDefaultQualitySettings:Ku}=ay(),ly=3,dy=3,Z_=()=>{let i=hi.safeStorage.get(H_);if(i)try{return JSON.parse(i)}catch(e){return null}return null},qu=(i,e)=>{var r,a;let t=Z_();return(a=(r=t==null?void 0:t[i])==null?void 0:r[e])!=null?a:null},lm=(i,e,t)=>{var l,d,s;let o=(l=Z_())!=null?l:{},r=(s=(d=o[i])==null?void 0:d[e])!=null?s:{};Object.assign(r,t,{updatedTs:Date.now()}),i in o||(o[i]={}),o[i][e]=r;let a=cy(o);hi.safeStorage.set(H_,JSON.stringify(a))};function cy(i){let e=Object.entries(i).reduce((o,[r,a])=>{let l=0;return Object.values(a).forEach(d=>{l<d.updatedTs&&(l=d.updatedTs)}),o.push([r,l]),o},[]);return e.sort(([,o],[,r])=>o>r?-1:1),e.splice(dy),e.reduce((o,[r])=>(o[r]=uy(i[r]),o),{})}function uy(i){let e=Object.entries(i);return e.sort(([,t],[,o])=>t.updatedTs>o.updatedTs?-1:1),e.splice(ly),Object.fromEntries(e)}function J_(){hi.safeStorage.set(F_,JSON.stringify(!0))}function eb(){let i=hi.safeStorage.get(F_);try{return i?JSON.parse(i):!1}catch(e){return!1}}var lg=require("@vkontakte/videoplayer-core/es2015");nh();var da="var(--btn-color, #fff)";var py=Ie('<g filter="url(#strokeAndShadow)"><!></g><defs><filter x="-12" width="72" y="-12" height="72" id="strokeAndShadow"><feMorphology operator="dilate" radius=".4" result="outer"></feMorphology><feFlood flood-color="rgba(0,0,0,0.1)" result="outerColor"></feFlood><feComposite operator="in" in="outerColor" in2="outer" result="outerOutline"></feComposite><feDropShadow in="SourceGraphic" dx="0" dy="0" stdDeviation="3" flood-color="rgba(0,0,0,0.4)" result="outerShadow"></feDropShadow><feMerge><feMergeNode in="outerShadow"></feMergeNode><feMergeNode in="outerOutline"></feMergeNode><feMergeNode in="SourceGraphic"></feMergeNode></feMerge></filter></defs>',1),fy=Ie('<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill-rule="evenodd" clip-rule="evenodd"><!></svg>');function Ze(i,e){var m;B(e,!0);let t=h(e,"width",19,()=>"24"),o=h(e,"height",19,()=>"24"),r=h(e,"fill",3,da),a=(m=e.viewBox)!=null?m:`0 0 ${t()} ${o()}`;var l=fy(),d=C(l);{var s=p=>{var v=py(),b=ue(v),y=C(b);ri(y,()=>e.children),S(b),pi(),$(p,v)},u=p=>{var v=Me(),b=ue(v);ri(b,()=>e.children),$(p,v)};V(d,p=>{e.shadow?p(s):p(u,!1)})}S(l),O(()=>{Re(l,"aria-label",e.ariaLabel),Re(l,"aria-hidden",!e.ariaLabel),Re(l,"width",t()),Re(l,"height",o()),Re(l,"viewBox",a),Re(l,"fill",r()),qe(l,e.style),Re(l,"data-testid",e.testId)}),$(i,l),H()}var Kl=require("@vkontakte/videoplayer-shared/es2015");var my={auto_quality_invariant:"Авто",auto_quality:"Авто ({actual})",auto_quality_option:"Авто",other_quality:"Другое",high_quality:"Высокое качество",high_quality_description:"Будет использовано больше трафика",auto_quality_limit:"Автоматически",traffic_saving_quality:"Экономия трафика",traffic_saving_quality_description:"Видео грузятся быстрее, но качество ниже",default_quality_for_any_video:"Качество для всех видео",quality_applience:"Качество по умолчанию можно {action}",quality_applience_action:"изменить",menu_quality:"Качество",menu_traffic_saving:"Экономия данных",menu_playback_rate:"Скорость",menu_report:"Сообщить о проблеме",menu_pip:"Картинка в картинке",menu_pip_close:"Развернуть видео",menu_copy_video_link:"Скопировать ссылку на видео",menu_copy_video_link_with_timestamp:"Скопировать ссылку на кадр",menu_video_rotate:"Повернуть",menu_video_loop_on:"Включить повторение",menu_video_loop_off:"Отключить повторение",menu_chromecast:"Chromecast трансляция",menu_copy_debug:"Копировать данные для диагностики",menu_save_debug:"Сохранить данные для диагностики",menu_debug_overlay:"Техническая информация",menu_copy_embed_code:"Копировать код для встраивания",menu_audio_languages:"Звуковая дорожка",audio_stream_display_language_label:"{label} ({language})",audio_stream_display_language_label_index:"{label} {index} ({language})",audio_stream_display_label_index:"{label} {index}",audio_stream_display_language_index:"{language} {index}",audio_stream_display_unknown:"Дорожка {index}",pip_dummy_title:"Видео воспроизводится в режиме картинка в картинке",submenu_quality:"Качество",submenu_playback_rate:"Скорость",submenu_settings:"Настройки",submenu_traffic_saving:"Экономия данных",submenu_audio_languages:"Звуковая дорожка",playing_ads:"Реклама {timeleft}",skip_ads_now:"Пропустить рекламу",skip_ads_after:"Пропустить {time}с",visit_advertiser:"Перейти на сайт",aria_timeline:"Ползунок временной шкалы",aria_timeline_value:"{position} (общая длительность {duration}",doubletap_seek_step:"{seconds} секунд",playback_rate_1:"Обычная",playback_rate:"{multiplier}x",video360:"панорамное видео",subtitles_caption:"Субтитры",subtitles_auto:"{language} (Автоматические)",subtitles_off:"Выкл.",subtitles_auto_caption:"Автоматические субтитры",subtitles_turn_on:"Включить субтитры",subtitles_turn_off:"Выключить субтитры",traffic_saving_off:"Откл.",traffic_saving_on:"Вкл.",traffic_saving_helper_text:"При включении качество видео будет снижено для экономии трафика",tooltip_button_disabled:"Кнопка недоступна",tooltip_previous:"Предыдущее видео",tooltip_restart:"Начать заново",tooltip_play:"Смотреть",tooltip_pause:"Пауза",tooltip_next:"Следующее видео",tooltip_interactive_go_back:"Вернуться к предыдущей главе",tooltip_interactive_go_back_disabled:"История прохождения недоступна",tooltip_interactive_go_back_disabled_first:"Вы смотрите первую главу",tooltip_interactive_go_back_disabled_limit:"Лимит возвратов исчерпан",tooltip_chapter_without_interactive:"В этой главе нет интерактива",tooltip_interactive_of_chapter_completed:"Интерактивы этой главы уже пройдены",tooltip_interactive_seek:"Перейти к интерактиву",tooltip_interactive_graph_off:"Показать карту сюжета",tooltip_interactive_graph_on:"Скрыть карту сюжета",tooltip_live:"Перемотать на актуальный лайв",tooltip_episodes:"Эпизоды",tooltip_volume:"Включить звук",tooltip_volume_muted:"Выключить звук",tooltip_sound_unavailable:"Звук недоступен",tooltip_subtitles_off:"Включить субтитры",tooltip_subtitles_on:"Выключить субтитры",tooltip_settings_off:"Открыть настройки",tooltip_settings_on:"Закрыть настройки",tooltip_fullscreen_off:"На весь экран",tooltip_fullscreen_on:"Выйти из полноэкранного режима",tooltip_chromecast_off:"Включить Chromecast",tooltip_chromecast_on:"Выключить Chromecast",tooltip_episode_finished:"Вы уже сделали свой выбор",tooltip_episode_unfinished:"Не пройдено",tooltip_disabled_when_interactive:"Интерактив уже идёт",tooltip_disabled_when_graph_on:"Кнопка недоступна во время просмотра карты",tooltip_interactive_interaction_time_indicator:"Нажмите на элемент интерактива",tooltip_vk_logo:"Открыть в VK Видео",tooltip_vk_video_logo:"Перейти в VK Видео",tooltip_autoplay_off:"Включить автовоспроизведение",tooltip_autoplay_on:"Отключить автовоспроизведение",tooltip_context_menu_open:"Открыть контекстное меню",tooltip_context_menu_close:"Закрыть контекстное меню",download_video_caption:"Скачать видео",hotkey_helper_current_volume:"{value} %",hotkey_map_modal_title:"Быстрые клавиши",hotkey_map_modal_close_btn_text:"Закрыть",hotkey_map_group_title_common:"Общие",hotkey_map_group_title_playback:"Воспроизведение",hotkey_map_group_title_subtitles:"Субтитры",hotkey_map_group_title_episodes:"Эпизоды",hotkey_map_item_mute_description:"Включить или отключить звук",hotkey_map_item_mute_value:"m",hotkey_map_item_volume_up_description:"Увеличить громкость",hotkey_map_item_volume_up_value:"Стрелка вверх",hotkey_map_item_volume_down_description:"Уменьшить громкость",hotkey_map_item_volume_down_value:"Стрелка вниз",hotkey_map_item_pip_description:"Свернуть или развернуть мини-проигрыватель",hotkey_map_item_pip_value:"i",hotkey_map_item_full_screen_description:"Включить или выключить полноэкранный режим",hotkey_map_item_full_screen_value:"f",hotkey_map_item_show_context_menu_description:"Скрыть или показать контекстное меню",hotkey_map_item_show_context_menu_value:"Shift + !",hotkey_map_item_show_hotkey_map_description:"Скрыть или показать список горячих клавиш",hotkey_map_item_show_hotkey_map_value:"Shift + ?",hotkey_map_item_play_toggle_description:"Приостановить или продолжить воспроизведение",hotkey_map_item_play_toggle_value:"Пробел (или k)",hotkey_map_item_seek_backward_description:"Перемотать ролик на 10 секунд назад",hotkey_map_item_seek_backward_value:"Стрелка влево (или j)",hotkey_map_item_seek_forward_description:"Перемотать ролик на 10 секунд вперёд",hotkey_map_item_seek_forward_value:"Стрелка вправо (или l)",hotkey_map_item_fast_seek_backward_description:"Ускоренная перемотка назад",hotkey_map_item_fast_seek_backward_value:"Shift + Стрелка влево",hotkey_map_item_fast_seek_forward_description:"Ускоренная перемотка вперёд",hotkey_map_item_fast_seek_forward_value:"Shift + Стрелка вправо",hotkey_map_item_rate_down_description:"Уменьшить скорость воспроизведения",hotkey_map_item_rate_down_value:"< (Shift + ,)",hotkey_map_item_rate_up_description:"Увеличить скорость воспроизведения",hotkey_map_item_rate_up_value:"> (Shift + .)",hotkey_map_item_prev_frame_description:"Перейти к предыдущему кадру <br />(когда воспроизведение приостановлено)",hotkey_map_item_prev_frame_value:",",hotkey_map_item_next_frame_description:"Перейти к следующему кадру <br />(когда воспроизведение приостановлено)",hotkey_map_item_next_frame_value:".",hotkey_map_item_jump_seek_description:"Перейти к определённому моменту видео <br />(например, при нажатии на цифру «7» ролик будет перемотан до временной отметки, которая соответствует 70% от длительности видео)",hotkey_map_item_jump_seek_value:"0, 1, 2, 3, 4, 5, 6, 7, 8, 9",hotkey_map_item_subtitles_toggle_description:"Включить или отключить субтитры",hotkey_map_item_subtitles_toggle_value:"c",hotkey_map_item_prev_episode_description:"Перейти к предыдущему эпизоду",hotkey_map_item_prev_episode_pc_value:"Ctrl + Стрелка влево",hotkey_map_item_prev_episode_mac_value:"Option + Стрелка влево",hotkey_map_item_next_episode_description:"Перейти к следующему эпизоду",hotkey_map_item_next_episode_pc_value:"Ctrl + Стрелка вправо",hotkey_map_item_next_episode_mac_value:"Option + Стрелка вправо",hotkey_map_item_next_video_description:"Перейти к следующему видео",hotkey_map_item_next_video_value:"Shift + N",hotkey_map_item_prev_video_description:"Перейти к предыдущему видео",hotkey_map_item_prev_video_value:"Shift + P",waiting_live_day_value:"дн",waiting_live_hour_value:"ч",waiting_live_minute_value:"мин",waiting_live_second_value:"сек",waiting_live_colon:":",waiting_live_upcoming_title:"Трансляция еще не началась",waiting_live_timer_title:"До начала трансляции осталось",waiting_live_recover_title:"Трансляция приостановлена - она продолжится, когда автор вернётся",waiting_record_title:"Трансляция завершена - запись появится позже",aria_label_video_player:"Видео плеер",aria_label_spherical_control:"Контроллер для сферического видео. Используйте клавиши со стрелками для панорамирования видео.",aria_label_debug_panel:"Область с технической информацией, сделайте скриншот для техподдержки",aria_label_new_tab_alert:"Откроется в новой вкладке.",aria_label_menu_quality:"Качество: {actual}",aria_label_menu_audio_languages:"Язык аудио: {actual}",aria_label_menu_rate:"Скорость: {actual}",aria_label_menu_subtitle:"Субтитры: {actual}",aria_label_menu_download:"Скачать видео",aria_label_menu_debug_overlay:"Отображение технической информации",aria_label_menu_rotate:"Повернуть видео на 90 градусов",aria_label_menu_loop:"Переключение режима повторения",aria_label_submenu_back:"Вернуться в меню настроек",aria_label_submenu_traffic_saving:"Режим экономии данных",aria_label_settings:"Настройки",aria_label_context_menu:"Контекстное меню",aria_label_autoplay:"Автовоспроизведение",end_screen_next_video:"Следующее видео",end_screen_recommended_video:"Рекомендуемое видео",slow_video_notification_button:"Выбрать качество «Авто»",slow_video_notification_force_description:`Видео грузится слишком медленно,
|
|
43
|
+
`)})}}var Ra=!1,Vl=null,Oa=!1,As=!1;function vf(i){As=i}var Rd=[],Od=[],Nt=null,_r=!1;function Gi(i){Nt=i}var xt=null;function go(i){xt=i}var Jo=null;function gu(i){Nt!==null&&Nt.f&2097152&&(Jo===null?Jo=[Nt,[i]]:Jo[1].push(i))}var Pn=null,br=0,hr=null;function sh(i){hr=i}var Ch=1,Cu=0,Ls=!1,Tu=null;function Sd(){return++Ch}function Aa(i){var p,v;var e=i.f;if((e&2048)!==0)return!0;if((e&4096)!==0){var t=i.deps,o=(e&256)!==0;if(t!==null){var r,a,l=(e&512)!==0,d=o&&xt!==null&&!Ls,s=t.length;if(l||d){var u=i,m=u.parent;for(r=0;r<s;r++)a=t[r],(l||!((p=a==null?void 0:a.reactions)!=null&&p.includes(u)))&&((v=a.reactions)!=null?v:a.reactions=[]).push(u);l&&(u.f^=512),d&&m!==null&&(m.f&256)===0&&(u.f^=256)}for(r=0;r<s;r++)if(a=t[r],Aa(a)&&mf(a),a.wv>i.wv)return!0}(!o||xt!==null&&!Ls)&&Tn(i,1024)}return!1}function Th(i,e,t=!0){var o=i.reactions;if(o!==null)for(var r=0;r<o.length;r++){var a=o[r];Jo!=null&&Jo[1].includes(i)&&Jo[0]===Nt||((a.f&2)!==0?Th(a,e,!1):e===a&&(t?Tn(a,2048):(a.f&1024)!==0&&Tn(a,4096),Td(a)))}}function vu(i){var b,y;var e=Pn,t=br,o=hr,r=Nt,a=Ls,l=Jo,d=Wt,s=_r,u=i.f;Pn=null,br=0,hr=null,Ls=(u&256)!==0&&(_r||!Oa||Nt===null),Nt=(u&96)===0?i:null,Jo=null,yd(i.ctx),_r=!1,Cu++,i.f|=2097152;try{var m=(0,i.fn)(),p=i.deps;if(Pn!==null){var v;if(Ld(i,br),p!==null&&br>0)for(p.length=br+Pn.length,v=0;v<Pn.length;v++)p[br+v]=Pn[v];else i.deps=p=Pn;if(!Ls||(u&2)!==0&&i.reactions!==null)for(v=br;v<p.length;v++)((y=(b=p[v]).reactions)!=null?y:b.reactions=[]).push(i)}else p!==null&&br<p.length&&(Ld(i,br),p.length=br);if(hs()&&hr!==null&&!_r&&p!==null&&(i.f&6146)===0)for(v=0;v<hr.length;v++)Th(hr[v],i);return r!==null&&r!==i&&(Cu++,hr!==null&&(o===null?o=hr:o.push(...hr))),m}catch(_){xh(_)}finally{Pn=e,br=t,hr=o,Nt=r,Ls=a,Jo=l,yd(d),_r=s,i.f^=2097152}}function a1(i,e){let t=e.reactions;if(t!==null){var o=Bg.call(t,i);if(o!==-1){var r=t.length-1;r===0?t=e.reactions=null:(t[o]=t[r],t.pop())}}t===null&&(e.f&2)!==0&&(Pn===null||!Pn.includes(e))&&(Tn(e,4096),(e.f&768)===0&&(e.f^=512),mu(e),Ld(e,0))}function Ld(i,e){var t=i.deps;if(t!==null)for(var o=e;o<t.length;o++)a1(i,t[o])}function Al(i){var e=i.f;if((e&16384)===0){Tn(i,1024);var t=xt,o=Oa;if(xt=i,Oa=!0,Re){var r=mr;xd(i.component_function)}try{(e&16)!==0?hh(i):bf(i),_f(i);var a=vu(i);if(i.teardown=typeof a=="function"?a:null,i.wv=Ch,Re&&gs&&(i.f&2048)!==0&&i.deps!==null)for(var l of i.deps)l.set_during_effect&&(l.wv=Sd(),l.set_during_effect=!1);Re&&Od.push(i)}finally{Oa=o,xt=t,Re&&xd(r)}}}function wh(){console.error("Last ten effects were: ",Od.slice(-10).map(i=>i.fn)),Od=[]}function l1(){try{Gg()}catch(i){if(Re&&vo(i,"stack",{value:""}),Vl!==null)if(Re)try{Vd(i,Vl)}catch(e){throw wh(),e}else Vd(i,Vl);else throw Re&&wh(),i}}function Cf(){var i=Oa;try{var e=0;for(Oa=!0;Rd.length>0;){e++>1e3&&l1();var t=Rd,o=t.length;Rd=[];for(var r=0;r<o;r++){var a=c1(t[r]);d1(a)}Pl.clear()}}finally{Ra=!1,Oa=i,Vl=null,Re&&(Od=[])}}function d1(i){var e=i.length;if(e!==0)for(var t=0;t<e;t++){var o=i[t];(o.f&24576)===0&&Aa(o)&&(Al(o),o.deps===null&&o.first===null&&o.nodes_start===null&&(o.teardown===null?yf(o):o.fn=null))}}function Td(i){Ra||(Ra=!0,queueMicrotask(Cf));for(var e=Vl=i;e.parent!==null;){e=e.parent;var t=e.f;if((t&96)!==0){if((t&1024)===0)return;e.f^=1024}}Rd.push(e)}function c1(i){for(var e=[],t=i;t!==null;){var o=t.f,r=(o&96)!==0,a=r&&(o&1024)!==0;if(!a&&(o&8192)===0){(o&4)!==0?e.push(t):r?t.f^=1024:Aa(t)&&Al(t);var l=t.first;if(l!==null){t=l;continue}}var d=t.parent;for(t=t.next;t===null&&d!==null;)t=d.next,d=d.parent}return e}function Rl(i){var e;for(i&&(Ra=!0,Cf(),Ra=!0,e=i());;){if($h(),Rd.length===0)return Ra=!1,Vl=null,Re&&(Od=[]),e;Ra=!0,Cf()}}function _o(){return bt(this,null,function*(){yield Promise.resolve(),Rl()})}function n(i){var e=i.f,t=(e&2)!==0;if(Tu!==null&&Tu.add(i),Nt!==null&&!_r){if(!(Jo!=null&&Jo[1].includes(i))||Jo[0]!==Nt){var o=Nt.deps;i.rv<Cu&&(i.rv=Cu,Pn===null&&o!==null&&o[br]===i?br++:Pn===null?Pn=[i]:(!Ls||!Pn.includes(i))&&Pn.push(i))}}else if(t&&i.deps===null&&i.effects===null){var r=i,a=r.parent;a!==null&&(a.f&256)===0&&(r.f^=256)}if(t&&(r=i,Aa(r)&&mf(r)),Re&&gs&&!_r&&$d!==null&&Nt!==null&&$d.reaction===Nt)if(i.trace)i.trace();else{var l=ks("TracedAt");if(l){var d=$d.entries.get(i);d===void 0&&(d={traces:[]},$d.entries.set(i,d));var s=d.traces[d.traces.length-1];l.stack!==(s==null?void 0:s.stack)&&d.traces.push(l)}}return As&&Pl.has(i)?Pl.get(i):i.v}function Et(i){var e=_r;try{return _r=!0,i()}finally{_r=e}}var u1=-7169;function Tn(i,e){i.f=i.f&u1|e}function Eu(i){if(!(typeof i!="object"||!i||i instanceof EventTarget)){if(Xo in i)Iu(i);else if(!Array.isArray(i))for(let e in i){let t=i[e];typeof t=="object"&&t&&Xo in t&&Iu(t)}}}function Iu(i,e=new Set){if(typeof i=="object"&&i!==null&&!(i instanceof EventTarget)&&!e.has(i)){e.add(i),i instanceof Date&&i.getTime();for(let o in i)try{Iu(i[o],e)}catch(r){}let t=Ia(i);if(t!==Object.prototype&&t!==Array.prototype&&t!==Map.prototype&&t!==Set.prototype&&t!==Date.prototype){let o=du(t);for(let r in o){let a=o[r].get;if(a)try{a.call(i)}catch(l){}}}}}function Tf(i,e){if(e){let t=document.body;i.autofocus=!0,En(()=>{document.activeElement===t&&i.focus()})}}function Dd(i){var e=Nt,t=xt;Gi(null),go(null);try{return i()}finally{Gi(e),go(t)}}var If=new Set,Pu=new Set;function Da(i){if(!nt)return;i.removeAttribute("onload"),i.removeAttribute("onerror");let e=i.__e;e!==void 0&&(i.__e=void 0,queueMicrotask(()=>{i.isConnected&&i.dispatchEvent(e)}))}function Ef(i,e,t,o={}){function r(a){if(o.capture||Ol.call(e,a),!a.cancelBubble)return Dd(()=>t==null?void 0:t.call(this,a))}return i.startsWith("pointer")||i.startsWith("touch")||i==="wheel"?En(()=>{e.addEventListener(i,r,o)}):e.addEventListener(i,r,o),r}function vt(i,e,t,o,r){var a={capture:o,passive:r},l=Ef(i,e,t,a);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&Mo(()=>{e.removeEventListener(i,l,a)})}function et(i){for(var e=0;e<i.length;e++)If.add(i[e]);for(var t of Pu)t(i)}function Ol(i){var C;var e=this,t=e.ownerDocument,o=i.type,r=((C=i.composedPath)==null?void 0:C.call(i))||[],a=r[0]||i.target,l=0,d=i.__root;if(d){var s=r.indexOf(d);if(s!==-1&&(e===document||e===window)){i.__root=e;return}var u=r.indexOf(e);if(u===-1)return;s<=u&&(l=s)}if(a=r[l]||i.target,a!==e){vo(i,"currentTarget",{configurable:!0,get(){return a||t}});var m=Nt,p=xt;Gi(null),go(null);try{for(var v,b=[];a!==null;){var y=a.assignedSlot||a.parentNode||a.host||null;try{var _=a["__"+o];if(_!=null&&(!a.disabled||i.target===a))if(pr(_)){var[x,...I]=_;x.apply(a,[i,...I])}else _.call(a,i)}catch(R){v?b.push(R):v=R}if(i.cancelBubble||y===e||y===null)break;a=y}if(v){for(let R of b)queueMicrotask(()=>{throw R});throw v}}finally{i.__root=e,delete i.currentTarget,Gi(m),go(p)}}}var f1;function Ih(){f1=void 0}function Dl(i){var e=document.createElement("template");return e.innerHTML=i.replaceAll("<!>","<!---->"),e.content}function Ro(i,e){var t=xt;t.nodes_start===null&&(t.nodes_start=i,t.nodes_end=e)}function L(i,e){var t=(e&1)!==0,o=(e&2)!==0,r,a=!i.startsWith("<!>");return()=>{if(nt)return Ro(wt,null),wt;r===void 0&&(r=Dl(a?i:"<!>"+i),t||(r=Ei(r)));var l=o||Id?document.importNode(r,!0):r.cloneNode(!0);if(t){var d=Ei(l),s=l.lastChild;Ro(d,s)}else Ro(l,l);return l}}function g1(i,e,t="svg"){var o=!i.startsWith("<!>"),r=(e&1)!==0,a=`<${t}>${o?i:"<!>"+i}</${t}>`,l;return()=>{if(nt)return Ro(wt,null),wt;if(!l){var d=Dl(a),s=Ei(d);if(r)for(l=document.createDocumentFragment();Ei(s);)l.appendChild(Ei(s));else l=Ei(s)}var u=l.cloneNode(!0);if(r){var m=Ei(u),p=u.lastChild;Ro(m,p)}else Ro(u,u);return u}}function Ee(i,e){return g1(i,e,"svg")}function bs(i=""){if(!nt){var e=In(i+"");return Ro(e,e),e}var t=wt;return t.nodeType!==xl&&(t.before(t=In()),Ti(t)),Ro(t,t),t}function Oe(){if(nt)return Ro(wt,null),wt;var i=document.createDocumentFragment(),e=document.createComment(""),t=In();return i.append(e,t),Ro(e,t),i}function $(i,e){if(nt){xt.nodes_end=wt,ji();return}i!==null&&i.before(e)}var h1=/\r/g;function Ph(i){i=i.replace(h1,"");let e=5381,t=i.length;for(;t--;)e=(e<<5)-e^i.charCodeAt(t);return(e>>>0).toString(36)}function kh(i){return i.endsWith("capture")&&i!=="gotpointercapture"&&i!=="lostpointercapture"}var _1=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function Ah(i){return _1.includes(i)}var b1=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected","webkitdirectory","defer","disablepictureinpicture","disableremoteplayback"];var $1={formnovalidate:"formNoValidate",ismap:"isMap",nomodule:"noModule",playsinline:"playsInline",readonly:"readOnly",defaultvalue:"defaultValue",defaultchecked:"defaultChecked",srcobject:"srcObject",novalidate:"noValidate",allowfullscreen:"allowFullscreen",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback"};function Lh(i){var e;return i=i.toLowerCase(),(e=$1[i])!=null?e:i}var NP=[...b1,"formNoValidate","isMap","noModule","playsInline","readOnly","value","volume","defaultValue","defaultChecked","srcObject","noValidate","allowFullscreen","disablePictureInPicture","disableRemotePlayback"];var y1=["touchstart","touchmove"];function Mh(i){return y1.includes(i)}var x1=["$state","$state.raw","$derived","$derived.by"],BP=[...x1,"$state.snapshot","$props","$props.id","$bindable","$effect","$effect.pre","$effect.tracking","$effect.root","$inspect","$inspect().with","$inspect.trace","$host"];var w1=["textarea","script","style","title"];function Vh(i){return w1.includes(i)}function ku(i){return i==null?void 0:i.replace(/\//g,"/")}var Nd=!0;function Au(i){Nd=i}function ge(i,e){var o;var t=e==null?"":typeof e=="object"?e+"":e;t!==((o=i.__t)!=null?o:i.__t=i.nodeValue)&&(i.__t=t,i.nodeValue=t+"")}function es(i,e){return Rh(i,e)}function kf(i,e){var l;bu(),e.intro=(l=e.intro)!=null?l:!1;let t=e.target,o=nt,r=wt;try{for(var a=Ei(t);a&&(a.nodeType!==fr||a.data!==ta);)a=en(a);if(!a)throw ms;ho(!0),Ti(a),ji();let d=Rh(i,Gt(Ve({},e),{anchor:a}));if(wt===null||wt.nodeType!==fr||wt.data!==Ta)throw ra(),ms;return ho(!1),d}catch(d){if(d===ms)return e.recover===!1&&Yg(),bu(),Ed(t),ho(!1),es(i,e);throw d}finally{ho(o),Ti(r),Ih()}}var Nl=new Map;function Rh(i,{target:e,anchor:t,props:o={},events:r,context:a,intro:l=!0}){bu();var d=new Set,s=p=>{for(var v=0;v<p.length;v++){var b=p[v];if(!d.has(b)){d.add(b);var y=Mh(b);e.addEventListener(b,Ol,{passive:y});var _=Nl.get(b);_===void 0?(document.addEventListener(b,Ol,{passive:y}),Nl.set(b,1)):Nl.set(b,_+1)}}};s(bd(If)),Pu.add(s);var u=void 0,m=gh(()=>{var p=t!=null?t:e.appendChild(In());return Bi(()=>{if(a){B({});var v=Wt;v.c=a}r&&(o.$$events=r),nt&&Ro(p,null),Nd=l,u=i(p,o)||{},Nd=!0,nt&&(xt.nodes_end=wt),a&&H()}),()=>{var y;for(var v of d){e.removeEventListener(v,Ol);var b=Nl.get(v);--b===0?(document.removeEventListener(v,Ol),Nl.delete(v)):Nl.set(v,b)}Pu.delete(s),p!==t&&((y=p.parentNode)==null||y.removeChild(p))}});return Pf.set(u,m),u}var Pf=new WeakMap;function Na(i,e){let t=Pf.get(i);return t?(Pf.delete(i),t(e)):(Re&&dh(),Promise.resolve())}function ri(i,e,...t){var o=i,r=$t,a;Xi(()=>{r!==(r=e())&&(a&&(Yi(a),a=null),Re&&r==null&&jg(),a=Bi(()=>r(o,...t)))},65536),nt&&(o=wt)}if(Re){let i=function(e){if(!(e in globalThis)){let t;Object.defineProperty(globalThis,e,{configurable:!0,get:()=>{if(t!==void 0)return t;Jg(e)},set:o=>{t=o}})}};I1=i,i("$state"),i("$effect"),i("$derived"),i("$inspect"),i("$props"),i("$bindable")}var I1;function Ot(i){Wt===null&&Cl("onMount"),vs&&Wt.l!==null?T1(Wt).m.push(i):Fe(()=>{let e=Et(i);if(typeof e=="function")return e})}function mn(i){Wt===null&&Cl("onDestroy"),Ot(()=>()=>Et(i))}function T1(i){var t;var e=i.l;return(t=e.u)!=null?t:e.u={a:[],b:[],m:[]}}var Oh=new Map;function Dh(i,e){var t=Oh.get(i);t||(t=new Set,Oh.set(i,t)),t.add(e)}function V(i,e,[t,o]=[0,0]){nt&&t===0&&ji();var r=i,a=null,l=null,d=ro,s=t>0?65536:0,u=!1;let m=(v,b=!0)=>{u=!0,p(b,v)},p=(v,b)=>{if(d===(d=v))return;let y=!1;if(nt&&o!==-1){if(t===0){let x=_u(r);x===ta?o=0:x===ia?o=1/0:(o=parseInt(x.substring(1)),o!==o&&(o=d?1/0:-1))}let _=o>t;!!d===_&&(r=La(),Ti(r),ho(!1),y=!0,o=-1)}d?(a?Vs(a):b&&(a=Bi(()=>b(r))),l&&Zn(l,()=>{l=null})):(l?Vs(l):b&&(l=Bi(()=>b(r,[t+1,o]))),a&&Zn(a,()=>{a=null})),y&&ho(!0)};Xi(()=>{u=!1,e(m),u||p(null,null)},s),nt&&(r=wt)}function Rs(i,e,t){nt&&ji();var o=i,r=ro,a,l=hs()?zg:wl;Xi(()=>{l(r,r=e())&&(a&&Zn(a),a=Bi(()=>t(o)))}),nt&&(o=wt)}var aa=null;function Mf(i){aa=i}function Bd(i,e){return e}function k1(i,e,t,o){for(var r=[],a=e.length,l=0;l<a;l++)wu(e[l].e,r,!0);var d=a>0&&r.length===0&&t!==null;if(d){var s=t.parentNode;Ed(s),s.append(t),o.clear(),sa(i,e[0].prev,e[a-1].next)}xf(r,()=>{for(var u=0;u<a;u++){var m=e[u];d||(o.delete(m.k),sa(i,m.prev,m.next)),Yi(m.e,!d)}})}function xi(i,e,t,o,r,a=null){var l=i,d={flags:e,items:new Map,first:null},s=(e&4)!==0;if(s){var u=i;l=nt?Ti(Ei(u)):u.appendChild(In())}nt&&ji();var m=null,p=!1,v=gr(()=>{var b=t();return pr(b)?b:b==null?[]:bd(b)});Xi(()=>{var b=n(v),y=b.length;if(p&&y===0)return;p=y===0;let _=!1;if(nt){var x=_u(l)===ia;x!==(y===0)&&(l=La(),Ti(l),ho(!1),_=!0)}if(nt){for(var I=null,C,R=0;R<y;R++){if(wt.nodeType===fr&&wt.data===Ta){l=wt,_=!0,ho(!1);break}var A=b[R],P=o(A,R);C=Hh(wt,d,I,null,A,P,R,r,e,t),d.items.set(P,C),I=C}y>0&&Ti(La())}nt||A1(b,d,l,r,e,o,t),a!==null&&(y===0?m?Vs(m):m=Bi(()=>a(l)):m!==null&&Zn(m,()=>{m=null})),_&&ho(!0),n(v)}),nt&&(l=wt)}function A1(i,e,t,o,r,a,l){var Z,Te,fe,te;var d=(r&8)!==0,s=(r&3)!==0,u=i.length,m=e.items,p=e.first,v=p,b,y=null,_,x=[],I=[],C,R,A,P;if(d)for(P=0;P<u;P+=1)C=i[P],R=a(C,P),A=m.get(R),A!==void 0&&((Z=A.a)==null||Z.measure(),(_!=null?_:_=new Set).add(A));for(P=0;P<u;P+=1){if(C=i[P],R=a(C,P),A=m.get(R),A===void 0){var E=v?v.e.nodes_start:t;y=Hh(E,e,y,y===null?e.first:y.next,C,R,P,o,r,l),m.set(R,y),x=[],I=[],v=y.next;continue}if(s&&L1(A,C,P,r),(A.e.f&8192)!==0&&(Vs(A.e),d&&((Te=A.a)==null||Te.unfix(),(_!=null?_:_=new Set).delete(A))),A!==v){if(b!==void 0&&b.has(A)){if(x.length<I.length){var W=I[0],F;y=W.prev;var U=x[0],X=x[x.length-1];for(F=0;F<x.length;F+=1)Nh(x[F],W,t);for(F=0;F<I.length;F+=1)b.delete(I[F]);sa(e,U.prev,X.next),sa(e,y,U),sa(e,X,W),v=W,y=X,P-=1,x=[],I=[]}else b.delete(A),Nh(A,v,t),sa(e,A.prev,A.next),sa(e,A,y===null?e.first:y.next),sa(e,y,A),y=A;continue}for(x=[],I=[];v!==null&&v.k!==R;)(v.e.f&8192)===0&&(b!=null?b:b=new Set).add(v),I.push(v),v=v.next;if(v===null)continue;A=v}x.push(A),y=A,v=A.next}if(v!==null||b!==void 0){for(var se=b===void 0?[]:bd(b);v!==null;)(v.e.f&8192)===0&&se.push(v),v=v.next;var j=se.length;if(j>0){var ne=(r&4)!==0&&u===0?t:null;if(d){for(P=0;P<j;P+=1)(fe=se[P].a)==null||fe.measure();for(P=0;P<j;P+=1)(te=se[P].a)==null||te.fix()}k1(e,se,ne,m)}}d&&En(()=>{var _e;if(_!==void 0)for(A of _)(_e=A.a)==null||_e.apply()}),xt.first=e.first&&e.first.e,xt.last=y&&y.e}function L1(i,e,t,o){(o&1)!==0&&kl(i.v,e),(o&2)!==0?kl(i.i,t):i.i=t}function Hh(i,e,t,o,r,a,l,d,s,u){var m=aa,p=(s&1)!==0,v=(s&16)===0,b=p?v?_s(r,!1,!1):Lr(r):r,y=(s&2)===0?l:Lr(l);Re&&p&&(b.trace=()=>{var x=typeof y=="number"?l:y.v;u()[x]});var _={i:y,v:b,k:a,a:null,e:null,prev:t,next:o};aa=_;try{return _.e=Bi(()=>d(i,b,y,u),nt),_.e.prev=t&&t.e,_.e.next=o&&o.e,t===null?e.first=_:(t.next=_,t.e.next=_.e),o!==null&&(o.prev=_,o.e.prev=_.e),_}finally{aa=m}}function Nh(i,e,t){for(var o=i.next?i.next.e.nodes_start:t,r=e?e.e.nodes_start:t,a=i.e.nodes_start;a!==o;){var l=en(a);r.before(a),a=l}}function sa(i,e,t){e===null?i.first=t:(e.next=t,e.e.next=t&&t.e),t!==null&&(t.prev=e,t.e.prev=e&&e.e)}function M1(i,e,t){var a,l;if(!e||e===Ph(String(t!=null?t:"")))return;let o,r=(a=i.__svelte_meta)==null?void 0:a.loc;r?o=`near ${r.file}:${r.line}:${r.column}`:(l=mr)!=null&&l[Gn]&&(o=`in ${mr[Gn]}`),lh(ku(o))}function Hd(i,e,t=!1,o=!1,r=!1){var a=i,l="";N(()=>{var b;var d=xt;if(l===(l=(b=e())!=null?b:"")){nt&&ji();return}if(d.nodes_start!==null&&($f(d.nodes_start,d.nodes_end),d.nodes_start=d.nodes_end=null),l!==""){if(nt){for(var s=wt.data,u=ji(),m=u;u!==null&&(u.nodeType!==fr||u.data!=="");)m=u,u=en(u);if(u===null)throw ra(),ms;Re&&!r&&M1(u.parentNode,s,l),Ro(wt,m),a=Ti(u);return}var p=l+"";t?p=`<svg>${p}</svg>`:o&&(p=`<math>${p}</math>`);var v=Dl(p);if((t||o)&&(v=Ei(v)),Ro(Ei(v),v.lastChild),t||o)for(;Ei(v);)a.before(Ei(v));else a.before(v)}})}function Hi(i,e,t){nt&&ji();var o=i,r,a;Xi(()=>{r!==(r=e())&&(a&&(Zn(a),a=null),r&&(a=Bi(()=>t(o,r))))},65536),nt&&(o=wt)}function Ba(i,e,t,o,r,a){var y;let l=nt;nt&&ji();var d=Re&&a&&((y=Wt)==null?void 0:y.function[Gn]),s,u,m=null;nt&&wt.nodeType===uu&&(m=wt,ji());var p=nt?wt:i,v,b=aa;Xi(()=>{let _=e()||null;var x=r?r():t||_==="svg"?au:null;if(_!==s){var I=aa;Mf(b),v&&(_===null?Zn(v,()=>{v=null,u=null}):_===u?Vs(v):(Yi(v),Au(!1))),_&&_!==u&&(v=Bi(()=>{if(m=nt?m:x?document.createElementNS(x,_):document.createElement(_),Re&&a&&(m.__svelte_meta={loc:{file:d,line:a[0],column:a[1]}}),Ro(m,m),o){nt&&Vh(_)&&m.append(document.createComment(""));var C=nt?Ei(m):m.appendChild(In());nt&&(C===null?ho(!1):Ti(C)),o(m,C)}xt.nodes_end=m,p.before(m)})),s=_,s&&(u=s),Au(!0),Mf(I)}},65536),l&&(ho(!0),Ti(p))}var Rf;function Fh(i){return Rf=i.target,new Vf(i)}var Os,Mr,Vf=class{constructor(e){ea(this,Os);ea(this,Mr);var a,l;var t=new Map,o=(d,s)=>{var u=_s(s,!1,!1);return t.set(d,u),u};let r=new Proxy(Gt(Ve({},e.props||{}),{$$events:{}}),{get(d,s){var u;return n((u=t.get(s))!=null?u:o(s,Reflect.get(d,s)))},has(d,s){var u;return s===yl?!0:(n((u=t.get(s))!=null?u:o(s,Reflect.get(d,s))),Reflect.has(d,s))},set(d,s,u){var m;return O((m=t.get(s))!=null?m:o(s,u),u),Reflect.set(d,s,u)}});$l(this,Mr,(e.hydrate?kf:es)(e.component,{target:e.target,anchor:e.anchor,props:r,context:e.context,intro:(a=e.intro)!=null?a:!1,recover:e.recover})),(!((l=e==null?void 0:e.props)!=null&&l.$$host)||e.sync===!1)&&Rl(),$l(this,Os,r.$$events);for(let d of Object.keys(Ni(this,Mr)))d==="$set"||d==="$destroy"||d==="$on"||vo(this,d,{get(){return Ni(this,Mr)[d]},set(s){Ni(this,Mr)[d]=s},enumerable:!0});Ni(this,Mr).$set=d=>{Object.assign(r,d)},Ni(this,Mr).$destroy=()=>{Na(Ni(this,Mr))}}$set(e){Ni(this,Mr).$set(e)}$on(e,t){Ni(this,Os)[e]=Ni(this,Os)[e]||[];let o=(...r)=>t.call(this,...r);return Ni(this,Os)[e].push(o),()=>{Ni(this,Os)[e]=Ni(this,Os)[e].filter(r=>r!==o)}}$destroy(){Ni(this,Mr).$destroy()}};Os=new WeakMap,Mr=new WeakMap;function Q(i,e){En(()=>{var r,a,l;var t=i.getRootNode(),o=t.host?t:(l=(r=t.head)!=null?r:t.ownerDocument.head)!=null?l:(a=Rf)==null?void 0:a.parentNode;if(!(o!=null&&o.querySelector("#"+e.hash))){let d=document.createElement("style");d.id=e.hash,d.textContent=e.code,o.appendChild(d),Re&&Dh(e.hash,d)}})}function Ds(i,e){var t=void 0,o;Xi(()=>{t!==(t=e())&&(o&&(Yi(o),o=null),t&&(o=Bi(()=>{Vo(()=>t(i))})))})}function Uh(i){var e,t,o="";if(typeof i=="string"||typeof i=="number")o+=i;else if(typeof i=="object")if(Array.isArray(i)){var r=i.length;for(e=0;e<r;e++)i[e]&&(t=Uh(i[e]))&&(o&&(o+=" "),o+=t)}else for(t in i)i[t]&&(o&&(o+=" "),o+=t);return o}function zh(){for(var i,e,t=0,o="",r=arguments.length;t<r;t++)(i=arguments[t])&&(e=Uh(i))&&(o&&(o+=" "),o+=e);return o}function Fd(i){return typeof i=="object"?zh(i):i!=null?i:""}var Wh=[...`
|
|
44
|
+
\r\f \v\uFEFF`];function qh(i,e,t){var o=i==null?"":""+i;if(e&&(o=o?o+" "+e:e),t){for(var r in t)if(t[r])o=o?o+" "+r:r;else if(o.length)for(var a=r.length,l=0;(l=o.indexOf(r,l))>=0;){var d=l+a;(l===0||Wh.includes(o[l-1]))&&(d===o.length||Wh.includes(o[d]))?o=(l===0?"":o.substring(0,l))+o.substring(d+1):l=d}}return o===""?null:o}function Kh(i,e=!1){var t=e?" !important;":";",o="";for(var r in i){var a=i[r];a!=null&&a!==""&&(o+=" "+r+": "+a+t)}return o}function Of(i){return i[0]!=="-"||i[1]!=="-"?i.toLowerCase():i}function Qh(i,e){if(e){var t="",o,r;if(Array.isArray(e)?(o=e[0],r=e[1]):o=e,i){i=String(i).replaceAll(/\s*\/\*.*?\*\/\s*/g,"").trim();var a=!1,l=0,d=!1,s=[];o&&s.push(...Object.keys(o).map(Of)),r&&s.push(...Object.keys(r).map(Of));var u=0,m=-1;let _=i.length;for(var p=0;p<_;p++){var v=i[p];if(d?v==="/"&&i[p-1]==="*"&&(d=!1):a?a===v&&(a=!1):v==="/"&&i[p+1]==="*"?d=!0:v==='"'||v==="'"?a=v:v==="("?l++:v===")"&&l--,!d&&a===!1&&l===0){if(v===":"&&m===-1)m=p;else if(v===";"||p===_-1){if(m!==-1){var b=Of(i.substring(u,m).trim());if(!s.includes(b)){v!==";"&&p++;var y=i.substring(u,p).trim();t+=" "+y+";"}}u=p+1,m=-1}}}}return o&&(t+=Kh(o)),r&&(t+=Kh(r,!0)),t=t.trim(),t===""?null:t}return i==null?null:String(i)}function oe(i,e,t,o,r,a){var l=i.__className;if(nt||l!==t||l===void 0){var d=qh(t,o,a);(!nt||d!==i.getAttribute("class"))&&(d==null?i.removeAttribute("class"):e?i.className=d:i.setAttribute("class",d)),i.__className=t}else if(a&&r!==a)for(var s in a){var u=!!a[s];(r==null||u!==!!r[s])&&i.classList.toggle(s,u)}return a}function Df(i,e={},t,o){for(var r in t){var a=t[r];e[r]!==a&&(t[r]==null?i.style.removeProperty(r):i.style.setProperty(r,a,o))}}function Qe(i,e,t,o){var r=i.__style;if(nt||r!==e){var a=Qh(e,o);(!nt||a!==i.getAttribute("style"))&&(a==null?i.removeAttribute("style"):i.style.cssText=a),i.__style=e}else o&&(Array.isArray(o)?(Df(i,t==null?void 0:t[0],o[0]),Df(i,t==null?void 0:t[1],o[1],"important")):Df(i,t,o));return o}function Ud(i,e,t){if(i.multiple){if(e==null)return;if(!pr(e))return ch();for(var o of i.options)o.selected=e.includes(Gh(o));return}for(o of i.options){var r=Gh(o);if(df(r,e)){o.selected=!0;return}}(!t||e!==void 0)&&(i.selectedIndex=-1)}function Nf(i){var e=new MutationObserver(()=>{Ud(i,i.__value)});e.observe(i,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),Mo(()=>{e.disconnect()})}function Gh(i){return"__value"in i?i.__value:i.value}var Bl=Symbol("class"),Hl=Symbol("style"),Xh=Symbol("is custom element"),Zh=Symbol("is html");function Jh(i,e){e?i.hasAttribute("selected")||i.setAttribute("selected",""):i.removeAttribute("selected")}function De(i,e,t,o){var r=t_(i);if(nt&&(r[e]=i.getAttribute(e),e==="src"||e==="srcset"||e==="href"&&i.nodeName==="LINK")){o||F1(i,e,t!=null?t:"");return}r[e]!==(r[e]=t)&&(e==="loading"&&(i[Ug]=t),t==null?i.removeAttribute(e):typeof t!="string"&&i_(i).includes(e)?i[e]=t:i.setAttribute(e,t))}function e_(i,e,t,o,r=!1){var A;var a=t_(i),l=a[Xh],d=!a[Zh];let s=nt&&l;s&&ho(!1);var u=e||{},m=i.tagName==="OPTION";for(var p in e)p in t||(t[p]=null);t.class?t.class=Fd(t.class):(o||t[Bl])&&(t.class=null),t[Hl]&&((A=t.style)!=null||(t.style=null));var v=i_(i);for(let P in t){let E=t[P];if(m&&P==="value"&&E==null){i.value=i.__value="",u[P]=E;continue}if(P==="class"){var b=i.namespaceURI==="http://www.w3.org/1999/xhtml";oe(i,b,E,o,e==null?void 0:e[Bl],t[Bl]),u[P]=E,u[Bl]=t[Bl];continue}if(P==="style"){Qe(i,E,e==null?void 0:e[Hl],t[Hl]),u[P]=E,u[Hl]=t[Hl];continue}var y=u[P];if(!(E===y&&!(E===void 0&&i.hasAttribute(P)))){u[P]=E;var _=P[0]+P[1];if(_!=="$$")if(_==="on"){let W={},F="$$"+P,U=P.slice(2);var x=Ah(U);if(kh(U)&&(U=U.slice(0,-7),W.capture=!0),!x&&y){if(E!=null)continue;i.removeEventListener(U,u[F],W),u[F]=null}if(E!=null)if(x)i[`__${U}`]=E,et([U]);else{let X=function(se){u[P].call(this,se)};var R=X;u[F]=Ef(U,i,X,W)}else x&&(i[`__${U}`]=void 0)}else if(P==="style")De(i,P,E);else if(P==="autofocus")Tf(i,!!E);else if(!l&&(P==="__value"||P==="value"&&E!=null))i.value=i.__value=E;else if(P==="selected"&&m)Jh(i,E);else{var I=P;d||(I=Lh(I));var C=I==="defaultValue"||I==="defaultChecked";if(E==null&&!l&&!C)if(a[P]=null,I==="value"||I==="checked"){let W=i,F=e===void 0;if(I==="value"){let U=W.defaultValue;W.removeAttribute(I),W.defaultValue=U,W.value=W.__value=F?U:null}else{let U=W.defaultChecked;W.removeAttribute(I),W.defaultChecked=U,W.checked=F?U:!1}}else i.removeAttribute(P);else C||v.includes(I)&&(l||typeof E!="string")?i[I]=E:typeof E!="function"&&De(i,I,E,r)}}}return s&&ho(!0),u}function so(i,e,t=[],o,r=!1,a=Xr){let l=t.map(a);var d=void 0,s={},u=i.nodeName==="SELECT",m=!1;if(Xi(()=>{var v=e(...l.map(n)),b=e_(i,d,v,o,r);m&&u&&"value"in v&&Ud(i,v.value,!1);for(let _ of Object.getOwnPropertySymbols(s))v[_]||Yi(s[_]);for(let _ of Object.getOwnPropertySymbols(v)){var y=v[_];_.description===ef&&(!d||y!==d[_])&&(s[_]&&Yi(s[_]),s[_]=Bi(()=>Ds(i,()=>y))),b[_]=y}d=b}),u){var p=i;Vo(()=>{Ud(p,d.value),Nf(p)})}m=!0}function t_(i){var e;return(e=i.__attributes)!=null?e:i.__attributes={[Xh]:i.nodeName.includes("-"),[Zh]:i.namespaceURI===Rg}}var Yh=new Map;function i_(i){var e=Yh.get(i.nodeName);if(e)return e;Yh.set(i.nodeName,e=[]);for(var t,o=i,r=Element.prototype;r!==o;){t=du(o);for(var a in t)t[a].set&&e.push(a);o=Ia(o)}return e}function F1(i,e,t){var o;Re&&(e==="srcset"&&U1(i,t)||Bf((o=i.getAttribute(e))!=null?o:"",t)||ah(e,i.outerHTML.replace(i.innerHTML,i.innerHTML&&"..."),String(t)))}function Bf(i,e){return i===e?!0:new URL(i,document.baseURI).href===new URL(e,document.baseURI).href}function jh(i){return i.split(",").map(e=>e.trim().split(" ").filter(Boolean))}function U1(i,e){var t=jh(i.srcset),o=jh(e);return o.length===t.length&&o.every(([r,a],l)=>a===t[l][1]&&(Bf(t[l][0],r)||Bf(r,t[l][0])))}var z1=lu?()=>performance.now():()=>Date.now(),ts={tick:i=>(lu?requestAnimationFrame:$t)(i),now:()=>z1(),tasks:new Set};function o_(){let i=ts.now();ts.tasks.forEach(e=>{e.c(i)||(ts.tasks.delete(e),e.f())}),ts.tasks.size!==0&&ts.tick(o_)}function n_(i){let e;return ts.tasks.size===0&&ts.tick(o_),{promise:new Promise(t=>{ts.tasks.add(e={c:i,f:t})}),abort(){ts.tasks.delete(e)}}}function Lu(i,e){Dd(()=>{i.dispatchEvent(new CustomEvent(e))})}function Q1(i){if(i==="float")return"cssFloat";if(i==="offset")return"cssOffset";if(i.startsWith("--"))return i;let e=i.split("-");return e.length===1?e[0]:e[0]+e.slice(1).map(t=>t[0].toUpperCase()+t.slice(1)).join("")}function r_(i){let e={},t=i.split(";");for(let o of t){let[r,a]=o.split(":");if(!r||a===void 0)break;let l=Q1(r.trim());e[l]=a.trim()}return e}var G1=i=>i;function Ns(i,e,t,o){var R;var r=(i&1)!==0,a=(i&2)!==0,l=r&&a,d=(i&4)!==0,s=l?"both":r?"in":"out",u,m=e.inert,p=e.style.overflow,v,b;function y(){var E;var A=Nt,P=xt;Gi(null),go(null);try{return u!=null?u:u=t()(e,(E=o==null?void 0:o())!=null?E:{},{direction:s})}finally{Gi(A),go(P)}}var _={is_global:d,in(){var A;if(e.inert=m,!r){b==null||b.abort(),(A=b==null?void 0:b.reset)==null||A.call(b);return}a||v==null||v.abort(),Lu(e,"introstart"),v=Hf(e,y(),b,1,()=>{Lu(e,"introend"),v==null||v.abort(),v=u=void 0,e.style.overflow=p})},out(A){if(!a){A==null||A(),u=void 0;return}e.inert=!0,Lu(e,"outrostart"),b=Hf(e,y(),v,0,()=>{Lu(e,"outroend"),A==null||A()})},stop:()=>{v==null||v.abort(),b==null||b.abort()}},x=xt;if(((R=x.transitions)!=null?R:x.transitions=[]).push(_),r&&Nd){var I=d;if(!I){for(var C=x.parent;C&&(C.f&65536)!==0;)for(;(C=C.parent)&&(C.f&16)===0;);I=!C||(C.f&32768)!==0}I&&Vo(()=>{Et(()=>_.in())})}}function Hf(i,e,t,o,r){var a=o===1;if(oa(e)){var l,d=!1;return En(()=>{if(!d){var x=e({direction:a?"in":"out"});l=Hf(i,x,t,o,r)}}),{abort:()=>{d=!0,l==null||l.abort()},deactivate:()=>l.deactivate(),reset:()=>l.reset(),t:()=>l.t()}}if(t==null||t.deactivate(),!(e!=null&&e.duration))return r(),{abort:$t,deactivate:$t,reset:$t,t:()=>o};let{delay:s=0,css:u,tick:m,easing:p=G1}=e;var v=[];if(a&&t===void 0&&(m&&m(0,1),u)){var b=r_(u(0,1));v.push(b,b)}var y=()=>1-o,_=i.animate(v,{duration:s,fill:"forwards"});return _.onfinish=()=>{var U;_.cancel();var x=(U=t==null?void 0:t.t())!=null?U:1-o;t==null||t.abort();var I=o-x,C=e.duration*Math.abs(I),R=[];if(C>0){var A=!1;if(u)for(var P=Math.ceil(C/16.666666666666668),E=0;E<=P;E+=1){var W=x+I*p(E/P),F=r_(u(W,1-W));R.push(F),A||(A=F.overflow==="hidden")}A&&(i.style.overflow="hidden"),y=()=>{var X=_.currentTime;return x+I*p(X/C)},m&&n_(()=>{if(_.playState!=="running")return!1;var X=y();return m(X,1-X),!0})}_=i.animate(R,{duration:C,fill:"forwards"}),_.onfinish=()=>{y=()=>o,m==null||m(o,1-o),r()}},{abort:()=>{_&&(_.cancel(),_.effect=null,_.onfinish=$t)},deactivate:()=>{r=$t},reset:()=>{o===0&&(m==null||m(1,0))},t:()=>y()}}function Ff(i,e,t){var o=jo(i,e);o&&o.set&&(i[e]=t,Mo(()=>{i[e]=null}))}var la,Fl,zd,Vu,s_,Ru=class Ru{constructor(e){ea(this,Vu);ea(this,la,new WeakMap);ea(this,Fl);ea(this,zd);$l(this,zd,e)}observe(e,t){var o=Ni(this,la).get(e)||new Set;return o.add(t),Ni(this,la).set(e,o),Mg(this,Vu,s_).call(this).observe(e,Ni(this,zd)),()=>{var r=Ni(this,la).get(e);r.delete(t),r.size===0&&(Ni(this,la).delete(e),Ni(this,Fl).unobserve(e))}}};la=new WeakMap,Fl=new WeakMap,zd=new WeakMap,Vu=new WeakSet,s_=function(){var e;return(e=Ni(this,Fl))!=null?e:$l(this,Fl,new ResizeObserver(t=>{for(var o of t){Ru.entries.set(o.target,o);for(var r of Ni(this,la).get(o.target)||[])r(o)}}))},ur(Ru,"entries",new WeakMap);var Uf=Ru;var Y1=new Uf({box:"border-box"});function kn(i,e,t){var o=Y1.observe(i,()=>t(i[e]));Vo(()=>(Et(()=>t(i[e])),o))}function a_(i,e){return i===e||(i==null?void 0:i[Xo])===e}function it(i={},e,t,o){return Vo(()=>{var r,a;return tn(()=>{r=a,a=(o==null?void 0:o())||[],Et(()=>{i!==t(...a)&&(e(i,...a),r&&a_(t(...r),i)&&e(null,...r))})}),()=>{En(()=>{a&&a_(t(...a),i)&&e(null,...a)})}}),i}function on(i=!1){let e=Wt,t=e.l.u;if(!t)return;let o=()=>Eu(e.s);if(i){let r=0,a={},l=Xr(()=>{let d=!1,s=e.s;for(let u in s)s[u]!==a[u]&&(a[u]=s[u],d=!0);return d&&r++,r});o=()=>n(l)}t.b.length&&Ad(()=>{l_(e,o),na(t.b)}),Fe(()=>{let r=Et(()=>t.m.map(Fg));return()=>{for(let a of r)typeof a=="function"&&a()}}),t.a.length&&Fe(()=>{l_(e,o),na(t.a)})}function l_(i,e){if(i.l.s)for(let t of i.l.s)n(t);e()}function Wd(i,e,t){if(i==null)return e(void 0),t&&t(void 0),$t;let o=Et(()=>i.subscribe(e,t));return o.unsubscribe?()=>o.unsubscribe():o}var Ul=[];function Vr(i,e){return{subscribe:ae(i,e).subscribe}}function ae(i,e=$t){let t=null,o=new Set;function r(d){if(wl(i,d)&&(i=d,t)){let s=!Ul.length;for(let u of o)u[1](),Ul.push(u,i);if(s){for(let u=0;u<Ul.length;u+=2)Ul[u][0](Ul[u+1]);Ul.length=0}}}function a(d){r(d(i))}function l(d,s=$t){let u=[d,s];return o.add(u),o.size===1&&(t=e(r,a)||$t),d(i),()=>{o.delete(u),o.size===0&&t&&(t(),t=null)}}return{set:r,update:a,subscribe:l}}function mi(i,e,t){let o=!Array.isArray(i),r=o?[i]:i;if(!r.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");let a=e.length<2;return Vr(t,(l,d)=>{let s=!1,u=[],m=0,p=$t,v=()=>{if(m)return;p();let y=e(o?u[0]:u,l,d);a?l(y):p=typeof y=="function"?y:$t},b=r.map((y,_)=>Wd(y,x=>{u[_]=x,m&=~(1<<_),s&&v()},()=>{m|=1<<_}));return s=!0,v(),function(){na(b),p(),s=!1}})}function be(i){let e;return Wd(i,t=>e=t)(),e}var Ou=!1,zf=Symbol();function w(i,e,t){var a;let o=(a=t[e])!=null?a:t[e]={store:null,source:_s(void 0),unsubscribe:$t};if(o.store!==i&&!(zf in t))if(o.unsubscribe(),o.store=i!=null?i:null,i==null)o.source.v=void 0,o.unsubscribe=$t;else{var r=!0;o.unsubscribe=Wd(i,l=>{r?o.source.v=l:O(o.source,l)}),r=!1}return i&&zf in t?be(i):n(o.source)}function He(){let i={};function e(){Mo(()=>{for(var t in i)i[t].unsubscribe();vo(i,zf,{enumerable:!1,value:!0})})}return[i,e]}function Wf(i){var e=Ou;try{return Ou=!1,[i(),Ou]}finally{Ou=e}}var iy={get(i,e){if(!i.exclude.includes(e))return i.props[e]},set(i,e){return Re&&Zg(`${i.name}.${String(e)}`),!1},getOwnPropertyDescriptor(i,e){if(!i.exclude.includes(e)&&e in i.props)return{enumerable:!0,configurable:!0,value:i.props[e]}},has(i,e){return i.exclude.includes(e)?!1:e in i.props},ownKeys(i){return Reflect.ownKeys(i.props).filter(e=>!i.exclude.includes(e))}};function An(i,e,t){return new Proxy(Re?{props:i,exclude:e,name:t,other:{},to_proxy:[]}:{props:i,exclude:e},iy)}var oy={get(i,e){let t=i.props.length;for(;t--;){let o=i.props[t];if(oa(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o)return o[e]}},set(i,e,t){let o=i.props.length;for(;o--;){let r=i.props[o];oa(r)&&(r=r());let a=jo(r,e);if(a&&a.set)return a.set(t),!0}return!1},getOwnPropertyDescriptor(i,e){let t=i.props.length;for(;t--;){let o=i.props[t];if(oa(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o){let r=jo(o,e);return r&&!r.configurable&&(r.configurable=!0),r}}},has(i,e){if(e===Xo||e===yl)return!1;for(let t of i.props)if(oa(t)&&(t=t()),t!=null&&e in t)return!0;return!1},ownKeys(i){let e=[];for(let t of i.props)if(oa(t)&&(t=t()),!!t){for(let o in t)e.includes(o)||e.push(o);for(let o of Object.getOwnPropertySymbols(t))e.includes(o)||e.push(o)}return e}};function is(...i){return new Proxy({props:i},oy)}function d_(i){var e,t;return(t=(e=i.ctx)==null?void 0:e.d)!=null?t:!1}function h(i,e,t,o){var W,F;var r=(t&1)!==0,a=!vs||(t&2)!==0,l=(t&8)!==0,d=(t&16)!==0,s=!1,u;l?[u,s]=Wf(()=>i[e]):u=i[e];var m=Xo in i||yl in i,p=l&&((F=(W=jo(i,e))==null?void 0:W.set)!=null?F:m&&e in i&&(U=>i[e]=U))||void 0,v=o,b=!0,y=!1,_=()=>(y=!0,b&&(b=!1,d?v=Et(o):v=o),v);u===void 0&&o!==void 0&&(p&&a&&Xg(e),u=_(),p&&p(u));var x;if(a)x=()=>{var U=i[e];return U===void 0?_():(b=!0,y=!1,U)};else{var I=(r?Xr:gr)(()=>i[e]);I.f|=131072,x=()=>{var U=n(I);return U!==void 0&&(v=void 0),U===void 0?v:U}}if((t&4)===0&&a)return x;if(p){var C=i.$$legacy;return function(U,X){return arguments.length>0?((!a||!X||C||s)&&p(X?x():U),U):x()}}var R=!1,A=!1,P=_s(u),E=Xr(()=>{var U=x(),X=n(P);return R?(R=!1,A=!0,X):(A=!1,P.v=U)});return l&&n(E),r||(E.equals=Sl),function(U,X){if(Tu!==null&&(R=A,x(),n(P)),arguments.length>0){let se=X?n(E):a&&l?li(U):U;if(!E.equals(se)){if(R=!0,O(P,se),y&&v!==void 0&&(v=se),d_(E))return U;Et(()=>n(E))}return U}return d_(E)?E.v:n(E)}}var ny;typeof HTMLElement=="function"&&(ny=class extends HTMLElement{constructor(e,t,o){super();ur(this,"$$ctor");ur(this,"$$s");ur(this,"$$c");ur(this,"$$cn",!1);ur(this,"$$d",{});ur(this,"$$r",!1);ur(this,"$$p_d",{});ur(this,"$$l",{});ur(this,"$$l_u",new Map);ur(this,"$$me");this.$$ctor=e,this.$$s=t,o&&this.attachShadow({mode:"open"})}addEventListener(e,t,o){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){let r=this.$$c.$on(e,t);this.$$l_u.set(t,r)}super.addEventListener(e,t,o)}removeEventListener(e,t,o){if(super.removeEventListener(e,t,o),this.$$c){let r=this.$$l_u.get(t);r&&(r(),this.$$l_u.delete(t))}}connectedCallback(){return bt(this,null,function*(){if(this.$$cn=!0,!this.$$c){let t=function(a){return l=>{let d=document.createElement("slot");a!=="default"&&(d.name=a),$(l,d)}};var e=t;if(yield Promise.resolve(),!this.$$cn||this.$$c)return;let o={},r=ry(this);for(let a of this.$$s)a in r&&(a==="default"&&!this.$$d.children?(this.$$d.children=t(a),o.default=!0):o[a]=t(a));for(let a of this.attributes){let l=this.$$g_p(a.name);l in this.$$d||(this.$$d[l]=Kf(l,a.value,this.$$p_d,"toProp"))}for(let a in this.$$p_d)!(a in this.$$d)&&this[a]!==void 0&&(this.$$d[a]=this[a],delete this[a]);this.$$c=Fh({component:this.$$ctor,target:this.shadowRoot||this,props:Gt(Ve({},this.$$d),{$$slots:o,$$host:this})}),this.$$me=xu(()=>{tn(()=>{var a;this.$$r=!0;for(let l of tf(this.$$c)){if(!((a=this.$$p_d[l])!=null&&a.reflect))continue;this.$$d[l]=this.$$c[l];let d=Kf(l,this.$$d[l],this.$$p_d,"toAttribute");d==null?this.removeAttribute(this.$$p_d[l].attribute||l):this.setAttribute(this.$$p_d[l].attribute||l,d)}this.$$r=!1})});for(let a in this.$$l)for(let l of this.$$l[a]){let d=this.$$c.$on(a,l);this.$$l_u.set(l,d)}this.$$l={}}})}attributeChangedCallback(e,t,o){var r;this.$$r||(e=this.$$g_p(e),this.$$d[e]=Kf(e,o,this.$$p_d,"toProp"),(r=this.$$c)==null||r.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return tf(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Kf(i,e,t,o){var a;let r=(a=t[i])==null?void 0:a.type;if(e=r==="Boolean"&&typeof e!="boolean"?e!=null:e,!o||!t[i])return e;if(o==="toAttribute")switch(r){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e==null?null:e;default:return e}else switch(r){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}function ry(i){let e={};return i.childNodes.forEach(t=>{e[t.slot||"default"]=!0}),e}var c_="5";var u_,p_,f_;typeof window!="undefined"&&((f_=(p_=(u_=window.__svelte)!=null?u_:window.__svelte={}).v)!=null?f_:p_.v=new Set).add(c_);var ld=require("@vkontakte/videoplayer-core/es2015"),LJ=require("@vkontakte/videoplayer-core/es2015"),pl=require("@vkontakte/videoplayer-shared/es2015"),C$=require("@vkontakte/videoplayer-statistics/es2015");var Ha=require("@vkontakte/videoplayer-shared/es2015");var sy={isMobile:void 0,disableInvisibleComponentsTimeout:500,debugLog:!1,devNullLog:!1,defaultLanguage:Ha.InterfaceLanguage.RU,downloadVKLanguages:!0,updateBuiltinLanguages:!0,isSmoothVideoRotate:!0,showSupport:!0,supportLink:"https://vk.com/support?act=new&from=v",showLogo:void 0,logoLink:"https://vk.com/video",logoType:"vk_video",volumeDefault:1,volumeMinRestore:.05,loaderDelay:500,minSubtitlesFontSize:13,autoSubtitlesTimeout:2e3,allowChangingFullscreenTarget:!0,trafficSavingLimit:Ha.VideoQuality.Q_480P,highQualityLimit:Ha.VideoQuality.Q_720P,episodeMinWidthPc:8,hideThumbTimerAfterTouch:!0,preventPauseOnVideoClick:!1,sentry:{dsn:"https://e349fd23c68f405388980d0868d0ff27@sentry.mvk.com/126",sampleRate:.01,whiteErrorCategoryList:[],blackErrorCategoryList:[],whiteErrorIdList:[],blackErrorIdList:[]},features:{autoplay:!0,statistics:!0,thinStatistics:!1,sentry:!0,preload:!0,subtitles:!0,episodes:!0,fullscreen:!0,timelinePreview:!0,mediaSession:!0,annotations:!0,slots:!0,annotationsInside:!1,pip:!0,dpip:!0,download:!0,liveRewind:!0,playbackRate:!0,trafficSaving:!0,episodesClustering:!0,copyVideoLink:!0,videoRotate:!0,tracer:!1,interactiveGraph:!1,interactiveResponsiveUi:!1,seekToInteractive:!0,interactiveLastFrame:!1,interactiveTextPermanent:!0,interactiveHideTime:!0,interactivePlayPrevChapter:!0,interactiveTimeIndicator:!0,interactiveTimeOpenUri:!1,interactiveAreaControlShadow:!1,interactiveControlsExpectTimeBlinkAnimation:!1,interactiveControlsTapPlace:!1,interactiveControlsFillAnimation:!1,interactiveControlsHideAnimation:!1,interactiveHistoryEndChapterFix:!0,thumbTimer:!0,hotKeyMapModal:!0,hotKeyHelpers:!0,saveDebugInfoToFile:!1,saveTraceInfoToFile:!1,additionalButtons:!0,additionalButtonsDesktopControlPanelRight:!0,additionalSettingsMenuItems:!0,additionalContextMenuItems:!0,contextMenuButton:!0,audioLanguages:!1,saveRate:!1,fullscreenInternalTargetPlayerContainer:!1,endScreen:!0,autoplayNext:!0,nextPrevButtons:!0,previewNoEmptySpace:!1,exposeInternalsToGlobal:!1,qualityDetailsSubMenuEnabled:!1,showSlowVideoNotification:!1,forceAutoQualityWhenSevereStallHappens:!1,timeoutShowSlowVideoNotification:0,maxCountShowSlowVideoNotification:1,forcePlayerDisplayBlock:!1,playbackStatusShow:!1,playbackStatusNextVideoShow:!1,initSubtitles:!0,useCallbackForMediaSessionNextPrevClick:!1,usePerformanceFix:!1,userVideoPrefs:!1,savePreferredStatesOnUserActionOnly:!1,useLoopSetting:!1,doubleForwardAvailable:!1,useRichSeek:!1,disableThumbUnstartedOnAutoplay:!1},controls:{showOnStartupAtAutoplay:!0,hideTimeout:500,hideTimeoutMobile:3e3,hideTimeoutInitial:200,hideTimeoutFullscreen:3e3,hideTimeoutCursor:3e3,hideTimeoutTooltips:1e3,collapseMobileUnmute:6e3,hide360IconTimeout:3e3,hideHotKeyHelpers:2e3,playbackRateMin:.25,playbackRateMax:2,playbackRateStep:.25,volumeStepKeyboard:.05,volumeStepWheel:.05,volumeBarTimeout:300,seekStepKeyboard:1e4,seekStepMobile:15e3,seekStepFrame:400},ads:{enable:void 0,initTimeout:2e3,loadTimeout:2e3,runtimeTimeout:5e3,slot:void 0,preview:void 0,paramsOverride:void 0,isMobileGoToSiteButton:!0,useAdmanFromNPM:!1,volumeMultiplier:1,isVsidOriginal:!1},disablePiPResizeHandling:!1,interactive:{historyMaxLength:100,noInteractionEventTimeout:3e4},view:{timelineSliderColor:null,timelineSliderHandleColor:null,timelineSliderFilledColor:null,timelineSliderLoadedColor:null,volumeSliderColor:null,volumeSliderHandleColor:null,volumeSliderFilledColor:null,controlsTimeColor:null,timelineSliderFilledActiveLiveColor:null,timelineSliderHandleActiveLiveColor:null,buttonColor:null,buttonToggleOnColor:null,focusedColor:null,font:null,focusedOutlineWidth:null,focusedOutlineRadius:null,controlsDesktopPaddingHorizontal:null,timelinePaddingHorizontal:null,settingsBackgroundColor:null,controlsGradientHeight:null,controlsGradient:null},userSalt:"0",doubleForwardActivationTime:600,playbackStatusAnimationDuration:1e3,playbackStatusNextVideoAnimationDuration:1e3,suitableDurationForUsingRichSeek:180,titleShowBehaviour:"fullscreen",disabledSlotIds:[],disabledAdditionalButtonIds:[]},m_=i=>(0,Ha.fillWithDefault)(i,sy),v_=i=>Il("ui-config",i),Dt=()=>Tl("ui-config");var Kd="vk_player_debug_panel_opened";var g_="videoplayer",h_="videoplayer";var $s={KeyF:"f",KeyK:"k",KeyC:"c",KeyM:"m"},__=new Set(["ArrowLeft","ArrowRight","KeyL","KeyJ"]),b_=new Set(["Tab","Space","ArrowLeft","ArrowRight","ArrowUp","ArrowDown"]),$_=new Set(["ShiftRight","ShiftLeft"]);var y_=["TIMELINE"],qd=[...y_,"GRAPH_BUTTON"],qf=[...y_,"PLAY_BUTTON"],Qd=[...qd,"PLAY_BUTTON"];var os=(a=>(a.XS="xs",a.S="s",a.M="m",a.L="l",a.XL="xl",a))(os||{}),Gd={xs:0,s:1,m:2,l:3,xl:4};var Yd=require("@vkontakte/videoplayer-shared/es2015"),x_=require("@vkontakte/videoplayer-core/es2015"),w_=require("@vkontakte/videoplayer-statistics/es2015");var Du="prod",Ua="1.1.82";var za=(i,e,t)=>{let o=document.createElement("a");o.href=i,o.download=`${e}.${t}`,o.style.display="none",o.click()};var S_=Symbol("storeContext"),C_=Symbol("microStoresContext"),T_=(i,e)=>{Il(S_,i),Il(C_,e),Du==="dev"&&(window.app={store:i,microStores:e})},$e=()=>{let i=Tl(S_);return(0,Yd.assertNonNullable)(i,"Store context is empty!"),i},xo=()=>{let i=Tl(C_);return(0,Yd.assertNonNullable)(i,"MicroStores context is empty!"),i},si=(i,e)=>Bu(i,i.getValue(),e),Bu=(i,e,t)=>Vr(e,o=>{let r=i.subscribe(a=>{o(a),t==null||t(a)});return()=>r.unsubscribe()}),I_=(i,e,t,o,r=["meta config not provided"])=>{var F,U,X,se,j,ne,Z,Te,fe;let a=i.info,{width:l,height:d}=be(t.ui.playerSize),s=(U=(F=a.throughputEstimation$.getValue())==null?void 0:F.toFixed(0))!=null?U:0,u=(se=(X=a.rttEstimation$.getValue())==null?void 0:X.toFixed(0))!=null?se:0,m=a.isAutoQualityEnabled$.getValue()?"auto":"manual",p=`${Ua} (core: ${x_.VERSION}, stat: ${w_.VERSION}, shared: ${Yd.VERSION})`,v=be(t.state.errorLog$),b=v.length?`
|
|
45
|
+
`+v.map((te,_e)=>{var Ye;let Ce=`${_e}) Type: ${te.id}
|
|
46
|
+
`,me=`Message: ${te.message} (${te.thrown})
|
|
47
|
+
`,ce=`Trace: ${(Ye=te.thrown)==null?void 0:Ye.stack}
|
|
48
|
+
`;return Ce+me+ce}).join(`
|
|
49
|
+
`):void 0,y=t.state.isAudioDisabled?"disabled":be(t.state.isAudioAvailable$)?void 0:"unavailable",_=i.info.currentVideoStream$.getValue(),x=i.info.currentAudioStream$.getValue(),I=[];_&&I.push(`Video: ${(j=_==null?void 0:_.codec)!=null?j:""}`+(_!=null&&_.hdr?" (HDR)":"")),x&&I.push(`Audio: ${(ne=x==null?void 0:x.codec)!=null?ne:""}`+(x!=null&&x.language?` (${x.language})`:""));let C=a.currentQuality$.getValue(),R="";if(C){let te=a.availableQualitiesFps$.getValue()[C];R=te?`${te}fps`:""}let A=a.httpConnectionType$.getValue(),P=(Te=(Z=a.currentBuffer$.getValue())==null?void 0:Z.end)!=null?Te:0,E=Math.max(P-be(t.state.positionExact$),0),W={Version:p,Browser:navigator.userAgent,Config:r.join(", "),"United video id":String(t.videoId),TraceId:o,VSID:be(t.vsid),"Content host":a.hostname$.getValue(),"Connection type":A?A+(a.httpConnectionReused$.getValue()?" (reused)":""):"",Throughput:`${s}Kbps @ ${u}ms RTT`,Format:a.currentFormat$.getValue(),"Available Formats":e!=null&&e.sources?Object.keys(e.sources).join(", "):"",Streams:I.join(", "),Quality:`${m} ${C!=null?C:""} ${R}`,"Available qualities":a.availableQualities$.getValue().join(", "),Audio:y,Position:`${be(t.state.positionExact$)}s`,Buffer:`${E}s`,State:`${be(t.playerPhase)} ${(fe=a.playbackState$.getValue())!=null?fe:""}`,"Player size":`${l}x${d}`,URL:window.location.href,Errors:b};return Object.entries(W).filter(([te,_e])=>_e!==void 0).map(([te,_e])=>`${te}: ${_e}`).join(`
|
|
50
|
+
`)},E_=(i,e,t)=>{var F,U,X,se;let o=i.info,{width:r,height:a}=be(t.ui.playerSize),l={version:Ua,viewport:`${r}x${a}`,volume:Math.round(be(t.state.volume$)*100)};l.id=t.videoId,o.currentFormat$.getValue()&&(l.provider=o.currentFormat$.getValue()),o.hostname$.getValue()&&(l.cdn=o.hostname$.getValue());let u=o.intrinsicVideoSize$.getValue();u&&(l.videoSize=`${u.width}x${u.height}`);let m=o.currentBuffer$.getValue(),p=o.currentNativeBuffer$.getValue(),v=o.isLive$.getValue(),b=o.liveBufferTime$.getValue();m&&p&&(v&&b?(l.buffer=m.end-b,l.nativeBuffer=p.end-b):(l.buffer=Math.max(m.end-be(t.state.positionExact$),0),l.nativeBuffer=Math.max(p.end-be(t.state.positionExact$),0))),l.position=be(t.state.positionExact$);let y=o.throughputEstimation$.getValue();y&&(l.speed=y);let _=o.videoBitrate$.getValue();_&&(l.bitrate=_);let x=o.liveLatency$.getValue();x&&(l.liveLatency=x);let I=o.currentVideoSegmentLength$.getValue();I&&(l.currentVideoSegmentLength=I);let C=o.currentAudioSegmentLength$.getValue();C&&(l.currentAudioSegmentLength=C);let R=be(t.vsid);typeof R=="string"&&(l.vsid=R);let A=(F=i.info.currentVideoStream$.getValue())==null?void 0:F.codec;A&&(l.videoCodec=A);let P=(U=i.info.currentAudioStream$.getValue())==null?void 0:U.codec;P&&(l.audioCodec=P),((X=i.info.currentVideoStream$.getValue())==null?void 0:X.hdr)&&(l.hdr=!0);let W=(se=i.info.currentAudioStream$.getValue())==null?void 0:se.language;return W&&(l.audioLanguage=W),l},P_=(i,e)=>za(i,e,"mp4"),k_=i=>!i.type,A_=i=>!!i.type,L_=()=>{let e=[],t=0;return{add:(o,r)=>{e[t]=[o,r],t=(t+1)%10},find:o=>e.find(([r])=>r===o)}},Nu=class{constructor(){this.destroyController=new AbortController;this.pendingDownloads=new Set}download(e){return bt(this,null,function*(){if(this.pendingDownloads.has(e))return null;this.pendingDownloads.add(e);try{let t=yield fetch(e,{signal:this.destroyController.signal});if(t.ok)return yield t.text();throw t}finally{this.pendingDownloads.delete(e)}})}destroy(){this.destroyController.abort(),this.pendingDownloads.clear()}isDestroyed(){return this.destroyController.signal.aborted}};var vi=require("@vkontakte/videoplayer-shared/es2015"),rV=require("@vkontakte/videoplayer-core/es2015");var ay="vk_player_",M_="vk_player_prefer_traffic_saving_enabled",V_="vk_player_preferred_volume",R_="vk_player_prefer_volume_mute",jf="vk_player_preferred_quality",Qf="vk_player_preferred_default_quality_settings",Gf="vk_player_preferred_quality_settings_by_video",O_="vk_player_preferred_stream_language",D_="vk_player_preferred_rate",N_="vk_player_preferred_autoplay_next",Yf="vk_player_preferred_subtitles_language",B_="vk_player_user_video_prefs",H_=`${ay}preview_track_close_tooltip`,F_=i=>i>1?1:i<0?0:i,Xf=i=>vi.safeStorage.set(V_,F_(i).toString(10)),Hu=()=>{let i=vi.safeStorage.get(V_);return(0,vi.isNullable)(i)?void 0:F_(parseFloat(i))},Zf=(i,e)=>vi.safeStorage.set(jf,JSON.stringify({videoId:i,value:e})),Fu=()=>vi.safeStorage.remove(jf),Jf=i=>{let e=vi.safeStorage.get(jf);if((0,vi.isNullable)(e))return;let{videoId:t,value:o}=JSON.parse(e);if(i!==t){Fu();return}return o},U_=(i,e)=>{e?vi.safeStorage.set(i,"true"):vi.safeStorage.remove(i)},em=i=>vi.safeStorage.get(i)==="true",tm=i=>U_(R_,i),z_=()=>em(R_),jd=i=>U_(M_,i),im=()=>em(M_),W_=()=>vi.safeStorage.get(O_),om=i=>vi.safeStorage.set(O_,i),nm=()=>vi.safeStorage.get(Yf),rm=i=>{i?vi.safeStorage.set(Yf,i):vi.safeStorage.remove(Yf)},K_=i=>vi.safeStorage.set(D_,JSON.stringify({rate:i})),q_=()=>{let i=vi.safeStorage.get(D_);if((0,vi.isNullable)(i))return;let{rate:e}=JSON.parse(i);return e},Q_=i=>{vi.safeStorage.set(N_,String(i))},G_=()=>em(N_),ly=()=>{let i=m=>{vi.safeStorage.set(Qf,JSON.stringify(m))},e=()=>{try{let m=vi.safeStorage.get(Qf);return m?JSON.parse(m):null}catch(m){return null}},t=()=>{try{let m=vi.safeStorage.get(Gf);return m?JSON.parse(m):null}catch(m){return null}},o=m=>{vi.safeStorage.set(Gf,JSON.stringify(m))},r=m=>{u(m);let p=m?t():null;if(p&&(p==null?void 0:p.videoId)===m)return Gt(Ve({},p),{appliesTo:"to-video"});p&&a();let v=e();return v?Gt(Ve({},v),{appliesTo:"as-default"}):(i({type:"auto_quality"}),{type:"auto_quality",appliesTo:"as-default"})},a=()=>{vi.safeStorage.remove(Gf)},l=()=>{vi.safeStorage.remove(Qf)},d=(m,p="as-default")=>{m.type==="exact_quality"||p==="to-video"?o(m):i(m)},s=m=>{let p=r(m);if(p){switch(p.type){case"traffic_saving":jd(!0);break;case"exact_quality":Zf(m,p.quality)}a(),l()}},u=m=>{let p=Jf(m);if(p){o({type:"exact_quality",videoId:m,quality:p});return}im()&&i({type:"traffic_saving",videoId:m}),jd(!1),Fu()};return{getPreferredQualitySettings:r,migrateSettingsToLegacyWay:s,savePreferredQualitySettings:d,savePreferredDefaultQualitySettings:i,removePreferredQualitySettingsByVideo:a,getPreferredDefaultQualitySettings:e,getPreferredSubtitlesLanguage:nm,savePreferredSubtitlesLanguage:rm}},{getPreferredQualitySettings:Y_,migrateSettingsToLegacyWay:j_,savePreferredQualitySettings:Uu,savePreferredDefaultQualitySettings:sV,removePreferredQualitySettingsByVideo:aV,getPreferredDefaultQualitySettings:zu}=ly(),dy=3,cy=3,X_=()=>{let i=vi.safeStorage.get(B_);if(i)try{return JSON.parse(i)}catch(e){return null}return null},Wu=(i,e)=>{var r,a;let t=X_();return(a=(r=t==null?void 0:t[i])==null?void 0:r[e])!=null?a:null},sm=(i,e,t)=>{var l,d,s;let o=(l=X_())!=null?l:{},r=(s=(d=o[i])==null?void 0:d[e])!=null?s:{};Object.assign(r,t,{updatedTs:Date.now()}),i in o||(o[i]={}),o[i][e]=r;let a=uy(o);vi.safeStorage.set(B_,JSON.stringify(a))};function uy(i){let e=Object.entries(i).reduce((o,[r,a])=>{let l=0;return Object.values(a).forEach(d=>{l<d.updatedTs&&(l=d.updatedTs)}),o.push([r,l]),o},[]);return e.sort(([,o],[,r])=>o>r?-1:1),e.splice(cy),e.reduce((o,[r])=>(o[r]=py(i[r]),o),{})}function py(i){let e=Object.entries(i);return e.sort(([,t],[,o])=>t.updatedTs>o.updatedTs?-1:1),e.splice(dy),Object.fromEntries(e)}function Z_(){vi.safeStorage.set(H_,JSON.stringify(!0))}function J_(){let i=vi.safeStorage.get(H_);try{return i?JSON.parse(i):!1}catch(e){return!1}}var sg=require("@vkontakte/videoplayer-core/es2015");oh();var da="var(--btn-color, #fff)";var fy=Ee('<g filter="url(#strokeAndShadow)"><!></g><defs><filter x="-12" width="72" y="-12" height="72" id="strokeAndShadow"><feMorphology operator="dilate" radius=".4" result="outer"></feMorphology><feFlood flood-color="rgba(0,0,0,0.1)" result="outerColor"></feFlood><feComposite operator="in" in="outerColor" in2="outer" result="outerOutline"></feComposite><feDropShadow in="SourceGraphic" dx="0" dy="0" stdDeviation="3" flood-color="rgba(0,0,0,0.4)" result="outerShadow"></feDropShadow><feMerge><feMergeNode in="outerShadow"></feMergeNode><feMergeNode in="outerOutline"></feMergeNode><feMergeNode in="SourceGraphic"></feMergeNode></feMerge></filter></defs>',1),my=Ee('<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill-rule="evenodd" clip-rule="evenodd"><!></svg>');function Ze(i,e){var m;B(e,!0);let t=h(e,"width",19,()=>"24"),o=h(e,"height",19,()=>"24"),r=h(e,"fill",3,da),a=(m=e.viewBox)!=null?m:`0 0 ${t()} ${o()}`;var l=my(),d=T(l);{var s=p=>{var v=fy(),b=le(v),y=T(b);ri(y,()=>e.children),S(b),ni(),$(p,v)},u=p=>{var v=Oe(),b=le(v);ri(b,()=>e.children),$(p,v)};V(d,p=>{e.shadow?p(s):p(u,!1)})}S(l),N(()=>{De(l,"aria-label",e.ariaLabel),De(l,"aria-hidden",!e.ariaLabel),De(l,"width",t()),De(l,"height",o()),De(l,"viewBox",a),De(l,"fill",r()),Qe(l,e.style),De(l,"data-testid",e.testId)}),$(i,l),H()}var zl=require("@vkontakte/videoplayer-shared/es2015");var vy={auto_quality_invariant:"Авто",auto_quality:"Авто ({actual})",auto_quality_option:"Авто",other_quality:"Другое",high_quality:"Высокое качество",high_quality_description:"Будет использовано больше трафика",auto_quality_limit:"Автоматически",traffic_saving_quality:"Экономия трафика",traffic_saving_quality_description:"Видео грузятся быстрее, но качество ниже",default_quality_for_any_video:"Качество для всех видео",quality_applience:"Качество по умолчанию можно {action}",quality_applience_action:"изменить",menu_quality:"Качество",menu_traffic_saving:"Экономия данных",menu_playback_rate:"Скорость",menu_report:"Сообщить о проблеме",menu_pip:"Картинка в картинке",menu_pip_close:"Развернуть видео",menu_copy_video_link:"Скопировать ссылку на видео",menu_copy_video_link_with_timestamp:"Скопировать ссылку на кадр",menu_video_rotate:"Повернуть",menu_video_loop_on:"Включить повторение",menu_video_loop_off:"Отключить повторение",menu_chromecast:"Chromecast трансляция",menu_copy_debug:"Копировать данные для диагностики",menu_save_debug:"Сохранить данные для диагностики",menu_debug_overlay:"Техническая информация",menu_copy_embed_code:"Копировать код для встраивания",menu_audio_languages:"Звуковая дорожка",audio_stream_display_language_label:"{label} ({language})",audio_stream_display_language_label_index:"{label} {index} ({language})",audio_stream_display_label_index:"{label} {index}",audio_stream_display_language_index:"{language} {index}",audio_stream_display_unknown:"Дорожка {index}",pip_dummy_title:"Видео воспроизводится в режиме картинка в картинке",submenu_quality:"Качество",submenu_playback_rate:"Скорость",submenu_settings:"Настройки",submenu_traffic_saving:"Экономия данных",submenu_audio_languages:"Звуковая дорожка",playing_ads:"Реклама {timeleft}",skip_ads_now:"Пропустить рекламу",skip_ads_after:"Пропустить {time}с",visit_advertiser:"Перейти на сайт",aria_timeline:"Ползунок временной шкалы",aria_timeline_value:"{position} (общая длительность {duration}",doubletap_seek_step:"{seconds} секунд",playback_rate_1:"Обычная",playback_rate:"{multiplier}x",video360:"панорамное видео",subtitles_caption:"Субтитры",subtitles_auto:"{language} (Автоматические)",subtitles_off:"Выкл.",subtitles_auto_caption:"Автоматические субтитры",subtitles_turn_on:"Включить субтитры",subtitles_turn_off:"Выключить субтитры",traffic_saving_off:"Откл.",traffic_saving_on:"Вкл.",traffic_saving_helper_text:"При включении качество видео будет снижено для экономии трафика",tooltip_button_disabled:"Кнопка недоступна",tooltip_previous:"Предыдущее видео",tooltip_restart:"Начать заново",tooltip_play:"Смотреть",tooltip_pause:"Пауза",tooltip_next:"Следующее видео",tooltip_interactive_go_back:"Вернуться к предыдущей главе",tooltip_interactive_go_back_disabled:"История прохождения недоступна",tooltip_interactive_go_back_disabled_first:"Вы смотрите первую главу",tooltip_interactive_go_back_disabled_limit:"Лимит возвратов исчерпан",tooltip_chapter_without_interactive:"В этой главе нет интерактива",tooltip_interactive_of_chapter_completed:"Интерактивы этой главы уже пройдены",tooltip_interactive_seek:"Перейти к интерактиву",tooltip_interactive_graph_off:"Показать карту сюжета",tooltip_interactive_graph_on:"Скрыть карту сюжета",tooltip_live:"Перемотать на актуальный лайв",tooltip_episodes:"Эпизоды",tooltip_volume:"Включить звук",tooltip_volume_muted:"Выключить звук",tooltip_sound_unavailable:"Звук недоступен",tooltip_subtitles_off:"Включить субтитры",tooltip_subtitles_on:"Выключить субтитры",tooltip_settings_off:"Открыть настройки",tooltip_settings_on:"Закрыть настройки",tooltip_fullscreen_off:"На весь экран",tooltip_fullscreen_on:"Выйти из полноэкранного режима",tooltip_chromecast_off:"Включить Chromecast",tooltip_chromecast_on:"Выключить Chromecast",tooltip_episode_finished:"Вы уже сделали свой выбор",tooltip_episode_unfinished:"Не пройдено",tooltip_disabled_when_interactive:"Интерактив уже идёт",tooltip_disabled_when_graph_on:"Кнопка недоступна во время просмотра карты",tooltip_interactive_interaction_time_indicator:"Нажмите на элемент интерактива",tooltip_vk_logo:"Открыть в VK Видео",tooltip_vk_video_logo:"Перейти в VK Видео",tooltip_autoplay_off:"Включить автовоспроизведение",tooltip_autoplay_on:"Отключить автовоспроизведение",tooltip_context_menu_open:"Открыть контекстное меню",tooltip_context_menu_close:"Закрыть контекстное меню",download_video_caption:"Скачать видео",hotkey_helper_current_volume:"{value} %",hotkey_map_modal_title:"Быстрые клавиши",hotkey_map_modal_close_btn_text:"Закрыть",hotkey_map_group_title_common:"Общие",hotkey_map_group_title_playback:"Воспроизведение",hotkey_map_group_title_subtitles:"Субтитры",hotkey_map_group_title_episodes:"Эпизоды",hotkey_map_item_mute_description:"Включить или отключить звук",hotkey_map_item_mute_value:"m",hotkey_map_item_volume_up_description:"Увеличить громкость",hotkey_map_item_volume_up_value:"Стрелка вверх",hotkey_map_item_volume_down_description:"Уменьшить громкость",hotkey_map_item_volume_down_value:"Стрелка вниз",hotkey_map_item_pip_description:"Свернуть или развернуть мини-проигрыватель",hotkey_map_item_pip_value:"i",hotkey_map_item_full_screen_description:"Включить или выключить полноэкранный режим",hotkey_map_item_full_screen_value:"f",hotkey_map_item_show_context_menu_description:"Скрыть или показать контекстное меню",hotkey_map_item_show_context_menu_value:"Shift + !",hotkey_map_item_show_hotkey_map_description:"Скрыть или показать список горячих клавиш",hotkey_map_item_show_hotkey_map_value:"Shift + ?",hotkey_map_item_play_toggle_description:"Приостановить или продолжить воспроизведение",hotkey_map_item_play_toggle_value:"Пробел (или k)",hotkey_map_item_seek_backward_description:"Перемотать ролик на 10 секунд назад",hotkey_map_item_seek_backward_value:"Стрелка влево (или j)",hotkey_map_item_seek_forward_description:"Перемотать ролик на 10 секунд вперёд",hotkey_map_item_seek_forward_value:"Стрелка вправо (или l)",hotkey_map_item_fast_seek_backward_description:"Ускоренная перемотка назад",hotkey_map_item_fast_seek_backward_value:"Shift + Стрелка влево",hotkey_map_item_fast_seek_forward_description:"Ускоренная перемотка вперёд",hotkey_map_item_fast_seek_forward_value:"Shift + Стрелка вправо",hotkey_map_item_rate_down_description:"Уменьшить скорость воспроизведения",hotkey_map_item_rate_down_value:"< (Shift + ,)",hotkey_map_item_rate_up_description:"Увеличить скорость воспроизведения",hotkey_map_item_rate_up_value:"> (Shift + .)",hotkey_map_item_prev_frame_description:"Перейти к предыдущему кадру <br />(когда воспроизведение приостановлено)",hotkey_map_item_prev_frame_value:",",hotkey_map_item_next_frame_description:"Перейти к следующему кадру <br />(когда воспроизведение приостановлено)",hotkey_map_item_next_frame_value:".",hotkey_map_item_jump_seek_description:"Перейти к определённому моменту видео <br />(например, при нажатии на цифру «7» ролик будет перемотан до временной отметки, которая соответствует 70% от длительности видео)",hotkey_map_item_jump_seek_value:"0, 1, 2, 3, 4, 5, 6, 7, 8, 9",hotkey_map_item_subtitles_toggle_description:"Включить или отключить субтитры",hotkey_map_item_subtitles_toggle_value:"c",hotkey_map_item_prev_episode_description:"Перейти к предыдущему эпизоду",hotkey_map_item_prev_episode_pc_value:"Ctrl + Стрелка влево",hotkey_map_item_prev_episode_mac_value:"Option + Стрелка влево",hotkey_map_item_next_episode_description:"Перейти к следующему эпизоду",hotkey_map_item_next_episode_pc_value:"Ctrl + Стрелка вправо",hotkey_map_item_next_episode_mac_value:"Option + Стрелка вправо",hotkey_map_item_next_video_description:"Перейти к следующему видео",hotkey_map_item_next_video_value:"Shift + N",hotkey_map_item_prev_video_description:"Перейти к предыдущему видео",hotkey_map_item_prev_video_value:"Shift + P",waiting_live_day_value:"дн",waiting_live_hour_value:"ч",waiting_live_minute_value:"мин",waiting_live_second_value:"сек",waiting_live_colon:":",waiting_live_upcoming_title:"Трансляция еще не началась",waiting_live_timer_title:"До начала трансляции осталось",waiting_live_recover_title:"Трансляция приостановлена - она продолжится, когда автор вернётся",waiting_record_title:"Трансляция завершена - запись появится позже",aria_label_video_player:"Видео плеер",aria_label_spherical_control:"Контроллер для сферического видео. Используйте клавиши со стрелками для панорамирования видео.",aria_label_debug_panel:"Область с технической информацией, сделайте скриншот для техподдержки",aria_label_new_tab_alert:"Откроется в новой вкладке.",aria_label_menu_quality:"Качество: {actual}",aria_label_menu_audio_languages:"Язык аудио: {actual}",aria_label_menu_rate:"Скорость: {actual}",aria_label_menu_subtitle:"Субтитры: {actual}",aria_label_menu_download:"Скачать видео",aria_label_menu_debug_overlay:"Отображение технической информации",aria_label_menu_rotate:"Повернуть видео на 90 градусов",aria_label_menu_loop:"Переключение режима повторения",aria_label_submenu_back:"Вернуться в меню настроек",aria_label_submenu_traffic_saving:"Режим экономии данных",aria_label_settings:"Настройки",aria_label_context_menu:"Контекстное меню",aria_label_autoplay:"Автовоспроизведение",end_screen_next_video:"Следующее видео",end_screen_recommended_video:"Рекомендуемое видео",slow_video_notification_button:"Выбрать качество «Авто»",slow_video_notification_force_description:`Видео грузится слишком медленно,
|
|
51
51
|
качество изменено на «Авто»`,slow_video_notification_suggest_description:`Видео загружается слишком медленно -
|
|
52
|
-
попробуйте изменить качество на «Авто»`,double_forward_label:"2x",preview_track_notification_text:"Потяните вверх для точной перемотки",preview_track_close_tooltip:"Выйти из режима точной перемотки"},
|
|
52
|
+
попробуйте изменить качество на «Авто»`,double_forward_label:"2x",preview_track_notification_text:"Потяните вверх для точной перемотки",preview_track_close_tooltip:"Выйти из режима точной перемотки"},eb=vy;var gy={auto_quality_invariant:"Auto",auto_quality:"Auto ({actual})",auto_quality_option:"Auto",other_quality:"Other",high_quality:"High quality",high_quality_description:"Uses more data",auto_quality_limit:"Auto",traffic_saving_quality:"Data saving",traffic_saving_quality_description:"Videos load faster but at lower quality",quality_applience:"You can {action} the default quality",quality_applience_action:"change",default_quality_for_any_video:"Quality for all videos",menu_quality:"Quality",menu_playback_rate:"Playback rate",menu_traffic_saving:"Data saving",menu_report:"Report a problem",menu_pip:"Picture in picture",menu_pip_close:"Expand video",menu_copy_video_link:"Copy video link",menu_copy_video_link_with_timestamp:"Copy link with timestamp",menu_video_rotate:"Rotate",menu_video_loop_on:"Enable loop",menu_video_loop_off:"Disable loop",menu_chromecast:"Chromecast stream",menu_copy_debug:"Copy debug info",menu_save_debug:"Save debug info",menu_debug_overlay:"Tech stats",menu_copy_embed_code:"Copy embed code",menu_audio_languages:"Audio track",audio_stream_display_language_label:"{label} ({language})",audio_stream_display_language_label_index:"{label} {index} ({language})",audio_stream_display_label_index:"{label} {index}",audio_stream_display_language_index:"{language} {index}",audio_stream_display_unknown:"Audio track {index}",pip_dummy_title:"Video plays in picture-in-picture mode",submenu_quality:"Quality",submenu_playback_rate:"Playback rate",submenu_traffic_saving:"Data saving",submenu_settings:"Settings",submenu_audio_languages:"Audio track",playing_ads:"Ads {timeleft}",skip_ads_after:"Skip ads",skip_ads_now:"Skip {time}s",visit_advertiser:"Visit site",aria_timeline:"Time scale slider",aria_timeline_value:"{position} out of {duration}",doubletap_seek_step:"{seconds} seconds",playback_rate_1:"Normal",playback_rate:"{multiplier}x",video360:"spherical video",subtitles_caption:"Subtitles",subtitles_auto:"{language} (Auto-generated)",subtitles_off:"Off",subtitles_auto_caption:"Auto subtitles",subtitles_turn_on:"Turn on subtitles",subtitles_turn_off:"Turn off subtitles",traffic_saving_off:"Off",traffic_saving_on:"On",traffic_saving_helper_text:"When turned on the video quality will be reduced to save data",tooltip_button_disabled:"Button disabled",tooltip_previous:"Previous video",tooltip_restart:"Watch again",tooltip_play:"Play",tooltip_pause:"Pause",tooltip_next:"Next video",tooltip_interactive_go_back:"Back to previous chapter",tooltip_interactive_go_back_disabled:"Interactive history unavailable",tooltip_interactive_go_back_disabled_first:"You're watching the first chapter",tooltip_interactive_go_back_disabled_limit:"Go-back limit exceeded",tooltip_chapter_without_interactive:"This chapter has no interactive segment",tooltip_interactive_of_chapter_completed:"Chapter's interactive segments already watched",tooltip_interactive_seek:"Go to interactive",tooltip_interactive_graph_off:"Show interactive graph",tooltip_interactive_graph_on:"Hide interactive graph",tooltip_live:"Go to the live edge",tooltip_episodes:"Episodes",tooltip_volume:"Volume off",tooltip_volume_muted:"Turn volume on",tooltip_sound_unavailable:"Sound unavailable",tooltip_subtitles_off:"Turn subtitles on",tooltip_subtitles_on:"Turn subtitles off",tooltip_settings_off:"Open settings",tooltip_settings_on:"Close settings",tooltip_fullscreen_off:"Enter fullscreen mode",tooltip_fullscreen_on:"Exit fullscreen mode",tooltip_chromecast_off:"Turn Chromecast on",tooltip_chromecast_on:"Turn Chromecast off",tooltip_episode_finished:"You have already viewed interactive episode",tooltip_episode_unfinished:"Interactive episode not finished",tooltip_disabled_when_interactive:"Interactive video in progress",tooltip_disabled_when_graph_on:"Button is disabled when graph is opened",tooltip_interactive_interaction_time_indicator:"Press the interactive element",tooltip_vk_logo:"Open in VK Video",tooltip_vk_video_logo:"Go to VK Video",tooltip_autoplay_off:"Turn autoplay on",tooltip_autoplay_on:"Turn autoplay off",tooltip_context_menu_open:"Open context menu",tooltip_context_menu_close:"Close context menu",download_video_caption:"Download video",hotkey_helper_current_volume:"{value} %",hotkey_map_modal_title:"Keyboard shortcuts",hotkey_map_modal_close_btn_text:"Close",hotkey_map_group_title_common:"Common",hotkey_map_group_title_playback:"Playback",hotkey_map_group_title_subtitles:"Subtitles",hotkey_map_group_title_episodes:"Episodes",hotkey_map_item_mute_description:"Toggle mute",hotkey_map_item_mute_value:"m",hotkey_map_item_volume_up_description:"Increase volume",hotkey_map_item_volume_up_value:"Arrow up",hotkey_map_item_volume_down_description:"Decrease volume",hotkey_map_item_volume_down_value:"Arrow down",hotkey_map_item_pip_description:"Toggle miniplayer",hotkey_map_item_pip_value:"i",hotkey_map_item_full_screen_description:"Toggle full screen",hotkey_map_item_full_screen_value:"f",hotkey_map_item_show_context_menu_description:"Hide or show context menu",hotkey_map_item_show_context_menu_value:"Shift + !",hotkey_map_item_show_hotkey_map_description:"Hide or show list of hotkeys",hotkey_map_item_show_hotkey_map_value:"Shift + ?",hotkey_map_item_play_toggle_description:"Toggle play/pause",hotkey_map_item_play_toggle_value:"Space (or k)",hotkey_map_item_seek_backward_description:"Rewind 10 seconds",hotkey_map_item_seek_backward_value:"Arrow left (or j)",hotkey_map_item_seek_forward_description:"Forward 10 seconds",hotkey_map_item_seek_forward_value:"Arrow right (or l)",hotkey_map_item_fast_seek_backward_description:"Fast rewind",hotkey_map_item_fast_seek_backward_value:"Shift + Arrow left",hotkey_map_item_fast_seek_forward_description:"Fast forward",hotkey_map_item_fast_seek_forward_value:"Shift + Arrow right",hotkey_map_item_rate_down_description:"Decrease playback rate",hotkey_map_item_rate_down_value:"< (Shift + ,)",hotkey_map_item_rate_up_description:"Increase playback rate",hotkey_map_item_rate_up_value:"> (Shift + .)",hotkey_map_item_prev_frame_description:"Previous frame (while paused)",hotkey_map_item_prev_frame_value:",",hotkey_map_item_next_frame_description:"Next frame (while paused)",hotkey_map_item_next_frame_value:".",hotkey_map_item_jump_seek_description:"Seek to specific point in the video (7 advances to 70% of duration)",hotkey_map_item_jump_seek_value:"0, 1, 2, 3, 4, 5, 6, 7, 8, 9",hotkey_map_item_subtitles_toggle_description:"Toggle captions ON/OFF",hotkey_map_item_subtitles_toggle_value:"c",hotkey_map_item_prev_episode_description:"Seek to previous episode",hotkey_map_item_prev_episode_pc_value:"Ctrl + Arrow left",hotkey_map_item_prev_episode_mac_value:"Option + Arrow left",hotkey_map_item_next_episode_description:"Seek to next episode",hotkey_map_item_next_episode_pc_value:"Ctrl + Arrow right",hotkey_map_item_next_episode_mac_value:"Option + Arrow right",hotkey_map_item_next_video_description:"Next video",hotkey_map_item_next_video_value:"Shift + N",hotkey_map_item_prev_video_description:"Previous video",hotkey_map_item_prev_video_value:"Shift + P",waiting_live_day_value:"d",waiting_live_hour_value:"h",waiting_live_minute_value:"min",waiting_live_second_value:"sec",waiting_live_colon:":",waiting_live_upcoming_title:"The broadcast hasn't started yet",waiting_live_timer_title:"Before the start of the broadcast left",waiting_live_recover_title:"The broadcast has been paused - it will resume when the author returns",waiting_record_title:"The broadcast completed - recording will appear later",aria_label_video_player:"Video player",aria_label_spherical_control:"Spherical video control. Use the arrow keys to pan the video.",aria_label_debug_panel:"Technical information area, take a screenshot for technical support",aria_label_new_tab_alert:"Opens in a new tab.",aria_label_menu_quality:"Quality: {actual}",aria_label_menu_audio_languages:"Audio language: {actual}",aria_label_menu_rate:"Rate: {actual}",aria_label_menu_subtitle:"Subtitles: {actual}",aria_label_menu_download:"Download video",aria_label_menu_debug_overlay:"Display of technical information",aria_label_menu_rotate:"Rotate video 90 degrees",aria_label_menu_loop:"Toggle loop",aria_label_submenu_back:"Return to settings menu",aria_label_submenu_traffic_saving:"Data saving mode",aria_label_settings:"Settings",aria_label_context_menu:"Context menu",aria_label_autoplay:"Autoplay",end_screen_next_video:"Next video",end_screen_recommended_video:"Recommended video",slow_video_notification_button:"Select Auto quality",slow_video_notification_force_description:`The video is loading too slowly,
|
|
53
53
|
so the quality was changed to Auto`,slow_video_notification_suggest_description:`The video is loading too slowly.
|
|
54
|
-
Try switching the quality to Auto.`,double_forward_label:"2x",preview_track_notification_text:"pull up to open precise rewind",preview_track_close_tooltip:"dismiss precise rewind"},
|
|
55
|
-
`),o,r;for(let a=0;a<t.length;++a){if(o=
|
|
56
|
-
`).filter(t=>!!t)[0]}function wy(i){try{let e=xy(i);if(e)return e}catch(e){}return{value:nb(i),type:i&&i.name,stacktrace:{frames:[]}}}function Sy(){return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,i=>{let e=Math.random()*16|0;return(i==="x"?e:e&3|8).toString(16)})}var Gu=class{constructor(e){if(e&&e.dsn){let t=yy.exec(e.dsn),o=t?t.slice(1):[],r=o[5].split("/"),a=r.slice(0,-1).join("/");this.apiUrl=o[0]+"://"+o[3]+(o[4]?":"+o[4]:"")+(a?"/"+a:"")+"/api/"+r.pop()+"/store/",this.authHeader="Sentry sentry_version=7,sentry_key="+o[1]+(o[2]?",sentry_secret="+o[2]:"")}this.environment=e&&e.environment}prepare(e){return Gt(ke({},this.getRequestBlank()),{exception:{values:[wy(e)]}})}report(e){this.send(this.prepare(e))}send(e){!this.apiUrl||!e||this.createRequest(e)}createRequest(e){let t=new XMLHttpRequest;t.open("POST",this.apiUrl,!0),t.setRequestHeader("Content-type","application/json"),t.setRequestHeader($y,this.authHeader||""),t.send(JSON.stringify(e))}getRequestBlank(){return{platform:"javascript",event_id:Sy(),sdk:{name:"micro-sentry.javascript.core",version:"0.0.0"},timestamp:Date.now()/1e3,environment:this.environment}}};function rb(i,e){return Object.prototype.toString.call(e)==="[object RegExp]"?e.test(i):typeof e=="string"?i.indexOf(e)!==-1:!1}function Cy(){return window}var Yu=class i extends Gu{constructor(e,t=Cy()){super(e),this.options=e,this.window=t,this.destroyed=!1,this._state={};let{plugins:o=[],beforeSend:r=u=>u,beforeBreadcrumb:a=u=>u,blacklistUrls:l=[],ignoreErrors:d=[],release:s=void 0}=this.options||{};this.plugins=o.map(u=>new u(this)),this.beforeSend=r,this.beforeBreadcrumb=a,this.blacklistUrls=l,this.ignoreErrors=d,this.release=s}get state(){return this._state}clearState(){this._state={}}setTags(e){return this.setKeyState("tags",ke({},e)),this}setTag(e,t){return this.extendState({tags:{[e]:t}}),this}setExtra(e,t){return this.extendState({extra:{[e]:t}}),this}setExtras(e){return this.setKeyState("extra",ke({},e)),this}setUser(e){return this.setKeyState("user",ke({},e)),this}clone(){let e=new i(Gt(ke({},this.options),{plugins:[]}));return e.extendState(this.state),e}withScope(e){let t=this.clone();e(t),t.destroy(),this.setBreadcrumbs(void 0)}addBreadcrumb(e){this.extendState({breadcrumbs:[ke({timestamp:Date.now()/1e3},this.beforeBreadcrumb(e))]})}setBreadcrumbs(e){this.setKeyState("breadcrumbs",e)}captureMessage(e,t){this.send(Gt(ke({},this.getRequestBlank()),{message:e,level:t}))}destroy(){this.destroyed=!0,this.plugins.forEach(e=>{e.destroy&&e.destroy()})}isIgnoredError(e){return this.ignoreErrors.length?this.getPossibleEventMessages(e).some(t=>this.ignoreErrors.some(o=>rb(t,o))):!1}getRequestBlank(){return ke(Gt(ke({request:{url:this.window.location.toString(),headers:{"User-Agent":this.window.navigator.userAgent}}},super.getRequestBlank()),{sdk:{name:"micro-sentry.javascript.browser",version:"0.0.0"}}),this.state)}send(e){this.destroyed||this.isDeniedUrl(e)||this.isIgnoredError(e)||(super.send(this.beforeSend(ke({release:this.release},e))),this.setBreadcrumbs(void 0))}getPossibleEventMessages(e){if(e.message)return[e.message];if(e.exception)try{let{type:t="",value:o=""}=e.exception.values&&e.exception.values[0]||{};return[`${o}`,`${t}: ${o}`]}catch(t){return[]}return[]}isDeniedUrl(e){if(!this.blacklistUrls.length)return!1;let t=this.getEventFilterUrl(e);return t?this.blacklistUrls.some(o=>rb(t,o)):!1}getEventFilterUrl(e){try{if(e.exception){let t=e.exception.values&&e.exception.values[0].stacktrace&&e.exception.values[0].stacktrace.frames;return t&&t[t.length-1].filename||null}return null}catch(t){return null}}extendState(e){this._state=Object.keys(e).reduce((t,o)=>{let r=this._state[o],a=Array.isArray(r)?r:null,l=e[o],d=Array.isArray(l)?l:null;return Gt(ke({},t),{[o]:a||d?[...a||[],...d||[]]:ke(ke({},typeof r!="string"?r:{}),typeof l!="string"?l:{})})},this._state)}setKeyState(e,t){this._state[e]=t}};var qa=require("@vkontakte/videoplayer-shared/es2015");var ju=null,Qa=class{constructor(e,t,o={}){!ju&&e.dsn&&(this.sentryClient=new Yu({dsn:e.dsn,environment:t.env}),this.version=t.version,this.sentrySubscription=new qa.Subscription,this.options=e,this.context=o,ju=this)}destroy(){var e,t;(e=this.sentryClient)==null||e.destroy(),(t=this.sentrySubscription)==null||t.unsubscribe(),ju=null}logIError(e,t=!1){e.thrown&&this.report(e.thrown,{fatal:t,errorType:e.id,category:e.category},{message:e.message,errorData:e.data})}report(e,t={},o={}){let{sentryClient:r,context:a,options:l}=this,{sampleRate:d=0,whiteErrorIdList:s,whiteErrorCategoryList:u=[],blackErrorIdList:m,blackErrorCategoryList:p}=l,{errorType:v,category:b}=t;if((0,qa.isNonNullable)(b)&&p.includes(b)||(0,qa.isNonNullable)(v)&&m.includes(v))return;if(Math.random()<=d||(0,qa.isNonNullable)(b)&&u.includes(b)||(0,qa.isNonNullable)(v)&&s.includes(v)){Object.keys(t).length&&r.setTags(ke({version:this.version},t)),(Object.keys(a).length||Object.keys(o).length)&&r.setExtras(ke(ke({},a),o));try{v&&r.captureMessage(v,t.fatal?ql.fatal:ql.error),r.report(e)}catch(_){console.error(_)}}}static getInstance(){return ju}};var as=(d=>(d.Thumb="thumb",d.Video="video",d.Ads="ads",d.Crashed="crashed",d.LiveWaitingStart="LiveWaitingStart",d.LiveWaitingRecover="LiveWaitingRecover",d.LiveWaitingRecord="LiveWaitingRecord",d))(as||{});var Xu=i=>{if(i.requestFullscreen)return i.requestFullscreen();if(i.msRequestFullscreen)return i.msRequestFullscreen();if(i.webkitRequestFullscreen)return i.webkitRequestFullscreen();if(i.mozRequestFullScreen)return i.mozRequestFullScreen();let e=i.querySelector("video");return e!=null&&e.webkitEnterFullscreen?(e.webkitEnterFullscreen(),Promise.resolve()):Promise.reject()},Zu=i=>i.exitFullscreen?i.exitFullscreen():i.msExitFullscreen?i.msExitFullscreen():i.webkitExitFullscreen?i.webkitExitFullscreen():i.mozCancelFullScreen?i.mozCancelFullScreen():Promise.reject(),sb=(i,e)=>e?!0:i.fullscreenEnabled||!!i.webkitFullscreenEnabled||!!i.mozFullscreenEnabled||!!i.msFullscreenEnabled,ab=i=>{let e=i;e!=null&&e.webkitExitFullscreen&&(e==null||e.webkitExitFullscreen())},ec=()=>{let i=document;return i.fullscreenElement||i.mozFullScreenElement||i.webkitFullscreenElement||i.msFullscreenElement},ca=()=>!!ec(),Ju=i=>{document.addEventListener("fullscreenchange",i),document.addEventListener("webkitfullscreenchange",i),document.addEventListener("mozfullscreenchange",i),document.addEventListener("MSFullscreenChange",i)},ep=i=>{document.removeEventListener("fullscreenchange",i),document.removeEventListener("webkitfullscreenchange",i),document.removeEventListener("mozfullscreenchange",i),document.removeEventListener("MSFullscreenChange",i)},lb=i=>{let e=window.screen;return(r=>ht(null,null,function*(){return e.orientation?e.orientation.lock(r):e.mozLockOrientation?e.mozLockOrientation(r):e.msLockOrientation?e.msLockOrientation(r):Promise.reject()}))(((r={width:0,height:0})=>r.width<=r.height?"portrait":"landscape")(i))};var pm=require("@vkontakte/videoplayer-core/es2015"),db=()=>({title:j("hotkey_map_modal_title"),closeBtnText:j("hotkey_map_modal_close_btn_text"),groups:[{title:j("hotkey_map_group_title_common"),items:[{description:j("hotkey_map_item_mute_description"),value:j("hotkey_map_item_mute_value")},{description:j("hotkey_map_item_volume_up_description"),value:j("hotkey_map_item_volume_up_value")},{description:j("hotkey_map_item_volume_down_description"),value:j("hotkey_map_item_volume_down_value")},{description:j("hotkey_map_item_pip_description"),value:j("hotkey_map_item_pip_value")},{description:j("hotkey_map_item_full_screen_description"),value:j("hotkey_map_item_full_screen_value")},{description:j("hotkey_map_item_show_context_menu_description"),value:j("hotkey_map_item_show_context_menu_value")},{description:j("hotkey_map_item_show_hotkey_map_description"),value:j("hotkey_map_item_show_hotkey_map_value")}]},{title:j("hotkey_map_group_title_playback"),items:[{description:j("hotkey_map_item_play_toggle_description"),value:j("hotkey_map_item_play_toggle_value")},{description:j("hotkey_map_item_seek_backward_description"),value:j("hotkey_map_item_seek_backward_value")},{description:j("hotkey_map_item_seek_forward_description"),value:j("hotkey_map_item_seek_forward_value")},{description:j("hotkey_map_item_fast_seek_backward_description"),value:j("hotkey_map_item_fast_seek_backward_value")},{description:j("hotkey_map_item_fast_seek_forward_description"),value:j("hotkey_map_item_fast_seek_forward_value")},{description:j("hotkey_map_item_rate_down_description"),value:j("hotkey_map_item_rate_down_value")},{description:j("hotkey_map_item_rate_up_description"),value:j("hotkey_map_item_rate_up_value")},{description:j("hotkey_map_item_prev_frame_description"),value:j("hotkey_map_item_prev_frame_value")},{description:j("hotkey_map_item_next_frame_description"),value:j("hotkey_map_item_next_frame_value")},{description:j("hotkey_map_item_jump_seek_description"),value:j("hotkey_map_item_jump_seek_value")},{description:j("hotkey_map_item_next_video_description"),value:j("hotkey_map_item_next_video_value")},{description:j("hotkey_map_item_prev_video_description"),value:j("hotkey_map_item_prev_video_value")}]},{title:j("hotkey_map_group_title_subtitles"),items:[{description:j("hotkey_map_item_subtitles_toggle_description"),value:j("hotkey_map_item_subtitles_toggle_value")}]},{title:j("hotkey_map_group_title_episodes"),items:[{description:j("hotkey_map_item_prev_episode_description"),value:pm.clientChecker.device.isApple?j("hotkey_map_item_prev_episode_mac_value"):j("hotkey_map_item_prev_episode_pc_value")},{description:j("hotkey_map_item_next_episode_description"),value:pm.clientChecker.device.isApple?j("hotkey_map_item_next_episode_mac_value"):j("hotkey_map_item_next_episode_pc_value")}]}]});var Ql=require("@vkontakte/videoplayer-shared/es2015");function fm(i,e){B(e,!1);let t=be();Dt(()=>{t.getAdmanWrapper().startPostroll()}),$o(),H()}var cb=require("@vkontakte/videoplayer-shared/es2015");var Ty=Ie('<path d="M11.74 6.74a.9.9 0 0 1-1.28 0L6 2.27 1.54 6.74A.9.9 0 1 1 .26 5.46l5.1-5.1a.9.9 0 0 1 1.28 0l5.1 5.1a.9.9 0 0 1 0 1.28Z"></path>'),Iy=Ie('<path d="m5.773 8 3.363 3.364a.9.9 0 1 1-1.272 1.272l-4-4a.9.9 0 0 1 0-1.272l4-4a.9.9 0 0 1 1.272 1.272L5.773 8z"></path>');function Nr(i,e){B(e,!0);let t=h(e,"direction",3,"left"),o=h(e,"useBtnColor",3,!1),r=f(()=>["up","down"].includes(t())),a=f(()=>["right","down"].includes(t())),l=f(()=>`chevron-icon--${t()}`),d=f(()=>(()=>{let m="";return n(a)&&(m+="transform: rotate(180deg);"),m.length?m:void 0})()),s=f(()=>o()?da:"currentColor"),u=f(()=>n(r)?"7":"16");Ze(i,{width:"12",get height(){return n(u)},get fill(){return n(s)},get testId(){return n(l)},get style(){return n(d)},children:(m,p)=>{var v=Me(),b=ue(v);{var y=x=>{var I=Ty();$(x,I)},_=x=>{var I=Iy();$(x,I)};V(b,x=>{n(r)?x(y):x(_,!1)})}$(m,v)},$$slots:{default:!0}}),H()}var Ey=(i,e,t)=>{i.stopPropagation(),n(e)&&t()()},Py=L('<div class="skip s-1h"> <!></div>'),ky=L("<div><!></div>"),Ay={hash:"s-1h",code:".container.s-1h{background:rgba(0,0,0,.56);border-radius:6px;color:#fff;font-size:13px;padding:6px 10px;position:absolute;right:16px;top:14px;transition:color .2s}.container-mobile.s-1h{bottom:14px;font-size:15px;max-width:142px;top:unset}.skip.s-1h{align-items:flex-end;display:flex;gap:4px;white-space:nowrap}.skippable.s-1h{color:var(--white);cursor:pointer}.skippable.s-1h:hover{color:hsla(0,0%,100%,.75)}"};function mm(i,e){B(e,!0),Q(i,Ay);let[t,o]=De(),r=()=>w(u,"$isMobile",t),a=h(e,"position",3,0),l=h(e,"secondsToWatchBeforeSkip",3,0),d=h(e,"skipAd",3,cb.noop),u=be().ui.isMobile,m=f(()=>a()>0&&a()>=l());var p=ky();let v;p.__click=[Ey,m,d];var b=C(p);{var y=x=>{var I=Py(),T=C(I),R=k(T);Nr(R,{direction:"right"}),S(I),O(A=>ve(T,`${A!=null?A:""} `),[()=>j("skip_ads_now")]),$(x,I)},_=x=>{var I=_s();O(T=>ve(I,T),[()=>j("skip_ads_after",{time:Math.ceil(l()-a()).toFixed(0)})]),$(x,I)};V(b,x=>{n(m)?x(y):x(_,!1)})}S(p),O(x=>v=oe(p,1,"container s-1h",null,v,x),[()=>({"container-mobile":r(),skippable:n(m)})]),$(i,p),H(),o()}Ye(["click"]);var Ly=L('<button class="go-to-site s-1g"> </button>'),My={hash:"s-1g",code:"button.go-to-site.s-1g{background:#fff;border:none;border-radius:6px;bottom:14px;color:#000;font-size:15px;left:16px;padding:6px 10px;pointer-events:none;position:absolute}"};function vm(i,e){B(e,!1),Q(i,My),$o();var t=Ly(),o=C(t,!0);S(t),O(r=>ve(o,r),[()=>j("visit_advertiser")],kn),$(i,t),H()}var Vy=L('<div class="top-gradient-mobile s-o"></div>'),Ry=L('<div class="container s-o"><!> <video style="width: 100%; height: 100%" playsinline=""></video> <!> <!> <!></div>',2),Ny={hash:"s-o",code:".container.s-o{height:100%;width:100%}.top-gradient-mobile.s-o{background:linear-gradient(1turn,transparent,rgba(0,0,0,.05) 12%,rgba(0,0,0,.15) 25%,rgba(0,0,0,.3) 45%,rgba(0,0,0,.4) 57%,rgba(0,0,0,.5) 77%,rgba(0,0,0,.55) 88%,rgba(0,0,0,.65));height:80px;left:0;pointer-events:none;position:absolute;top:0;width:100%}"};function tc(i,e){B(e,!0),Q(i,Ny);let[t,o]=De(),r=()=>w(U,"$canSkipAd",t),a=()=>w(F,"$adPlaybackState",t),l=()=>w(R,"$isMobile",t),d=()=>w(X,"$adPosition",t),s=()=>w(ae,"$secondsToWatchBeforeSkipAd",t),u=()=>w(T,"$isVideoEnded",t),m=h(e,"adsSlotId",3,void 0),p=h(e,"adsParams",3,void 0),v=h(e,"adsAutoplayParam",3,void 0),b=h(e,"duration",3,0),y=h(e,"adsExternalApi",3,void 0),_=h(e,"adsJson",3,void 0),x=be(),I=Ot(),T=x.state.isEnded$,R=x.ui.isMobile,A=I.ads.isMobileGoToSiteButton,P=q(void 0),E=q(void 0),z=!1,F=x.ads.playbackState,U=x.ads.canSkip,X=x.ads.position,ae=x.ads.secondsToWatchBeforeSkip,Z=f(()=>r()&&a()!=="inactive"),re=f(()=>l()&&a()!=="inactive"&&A);Dt(()=>{let D=x.getAdmanWrapper();if(Ql.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_mount"],numbers:[(0,Ql.now)(),m()]}),!m()){D.onAdmanLoadingError();return}let Ge=()=>{var Le;let{width:He,height:it}=ye(x.ui.playerSize),ne=ye(x.ui.isFullscreen),ce=(Le=v())!=null?Le:ye(x.ui.isAutoplay),Ne=I.ads.paramsOverride;return{width:He,height:it,isFullscreen:ne,isAutoplay:ce,adsContainer:n(P),adsVideoElement:n(E),slotId:m(),params:p(),paramsOverride:Ne,duration:b(),externalApi:y(),json:_()}},K=He=>ht(null,null,function*(){He&&(yield ho());let it=Ge();yield D.initAdman(it),z=!0}),se=new AbortController,xe=()=>{se.abort()};return window.AdmanHTML?K(!0).catch(()=>{D.onAdmanLoadingError()}):D.loadAdman(se.signal).then(()=>K(!1)).catch(()=>{D.onAdmanLoadingError()}),()=>{Ql.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_unmount"],numbers:[(0,Ql.now)(),m()]}),!z&&xe()}});var J=Ry(),we=C(J);{var me=D=>{var Ge=Vy();$(D,Ge)};V(we,D=>{l()&&D(me)})}var ee=k(we,2);Xe(ee,D=>N(E,D),()=>n(E));var _e=k(ee,2);{var Ce=D=>{mm(D,{get position(){return d()},get secondsToWatchBeforeSkip(){return s()},get skipAd(){return x.actions.internal.skipAd}})};V(_e,D=>{n(Z)&&D(Ce)})}var ge=k(_e,2);{var pe=D=>{fm(D,{})};V(ge,D=>{u()&&D(pe)})}var Qe=k(ge,2);{var G=D=>{vm(D,{})};V(Qe,D=>{n(re)&&D(G)})}S(J),Xe(J,D=>N(P,D),()=>n(P)),$(i,J),H(),o()}var en=i=>{if(!isFinite(i))return"00:00";let e=Math.round(i),t=Math.floor(e/(60*60));e-=t*3600;let o=Math.floor(e/60);e-=o*60;let r=[o,e].map(a=>String(a).padStart(2,"0")).join(":");return t>0&&(r=`${t}:${r}`),r};var Dy=Ie('<path fill="#fff"></path>'),Oy=Ie("<path></path><!>",1);function ic(i,e){let t=h(e,"isActive",3,!1),o=f(()=>t()?"live-active-icon":"live-icon"),r=f(()=>t()?"var(--timeline-slider-filled-active-live-bg, #FF3347)":void 0),a="M8 5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h4a1 1 0 1 0 0-2H9V6a1 1 0 0 0-1-1m7 1a1 1 0 1 1 2 0v8a1 1 0 1 1-2 0zm15-1a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h4a1 1 0 1 0 0-2h-3v-2h3a1 1 0 1 0 0-2h-3V7h3a1 1 0 1 0 0-2zm-8.32 9.31-2.55-7.82a1 1 0 0 1-.12-.37L19 6.1a1 1 0 1 1 2-.2l2 6.4 2-6.4a1 1 0 0 1 2 .2v.02a1 1 0 0 1-.13.37l-2.55 7.82a1 1 0 0 1-.95.69h-.74a1 1 0 0 1-.95-.69";Ze(i,{width:"42",height:"20",get testId(){return n(o)},get fill(){return n(r)},children:(l,d)=>{var s=Oy(),u=ue(s),m=k(u);{var p=v=>{var b=Dy();Re(b,"d",a),$(v,b)};V(m,v=>{t()&&v(p)})}O(()=>Re(u,"d",`M5 0h32s5 0 5 5v10s0 5 -5 5h-32s-5 0 -5 -5v-10s0 -5 5 -5${t()?"":"M5.5 2h31s3.5 0 3.5 3.5v9s0 3.5-3.5 3.5h-31s-3.5 0-3.5-3.5v-9s0-3.5 3.5-3.5"+a}z`)),$(l,s)},$$slots:{default:!0}})}var By=L('<div class="equalizer s-b"><div class="col s-b"></div> <div class="col s-b"></div> <div class="col s-b"></div></div>'),Hy=L('<div class="live-icon s-b"><!></div>'),Fy=L('<span class="text s-b"> </span>'),Uy=L("<div><!> <!></div>"),zy={hash:"s-b",code:".wrapper.s-b{background-color:var(--black-alpha-40);border-radius:4px;padding:2px 6px;transition:visibility var(--controls-transition-duration),opacity var(--controls-transition-duration);white-space:nowrap}.wrapper.live.s-b{background:var(--red);border-radius:2px;font-size:0;height:20px;line-height:20px;padding:0 7px}.equalizer.s-b{display:inline-block;height:10px;margin-right:4px;margin-top:-4px;position:relative;vertical-align:middle;width:10px}.live.s-b .equalizer:where(.s-b){margin-top:-2px}.equalizer.s-b .col:where(.s-b){animation:1.5s linear infinite alternate;animation-play-state:paused;background:var(--btn-color,--white);bottom:0;height:10px;margin-right:2px;position:absolute;transform-origin:50% 100%;width:2px}.playing.s-b .equalizer:where(.s-b) .col:where(.s-b){animation-play-state:running}.equalizer.s-b .col:where(.s-b):first-child{animation-name:s-b-thumb-timer-equalizer-col1;left:0}.equalizer.s-b .col:where(.s-b):nth-child(2){animation-name:s-b-thumb-timer-equalizer-col2;left:3px}.equalizer.s-b .col:where(.s-b):nth-child(3){animation-name:s-b-thumb-timer-equalizer-col3;left:6px}.live-icon.s-b{display:inline-block;height:20px;margin:0 -7px;vertical-align:middle;width:42px}@keyframes s-b-thumb-timer-equalizer-col1{0%{transform:scaleY(.1)}25%{transform:scaleY(.8)}50%{transform:scaleY(.4)}75%{transform:scaleY(.6)}to{transform:scaleY(.1)}}@keyframes s-b-thumb-timer-equalizer-col2{0%{transform:scaleY(1)}25%{transform:scaleY(.3)}50%{transform:scaleY(.9)}75%{transform:scaleY(.6)}to{transform:scaleY(1)}}@keyframes s-b-thumb-timer-equalizer-col3{0%{transform:scaleY(.6)}25%{transform:scaleY(.9)}50%{transform:scaleY(.1)}75%{transform:scaleY(.9)}to{transform:scaleY(.6)}}.text.s-b{color:var(--controls-time);font-size:13px;font-weight:500;line-height:16px}"};function oc(i,e){Q(i,zy);let t=h(e,"withEqualizer",3,!1),o=h(e,"isLive",3,!1),r=h(e,"isPlaying",3,!1);var a=Uy();let l;var d=C(a);{var s=v=>{var b=By();$(v,b)};V(d,v=>{t()&&v(s)})}var u=k(d,2);{var m=v=>{var b=Hy(),y=C(b);ic(y,{isActive:!0}),S(b),$(v,b)},p=v=>{var b=Fy(),y=C(b,!0);S(b),O(()=>ve(y,e.time)),$(v,b)};V(u,v=>{o()?v(m):v(p,!1)})}S(a),O(v=>l=oe(a,1,"wrapper s-b",null,l,v),[()=>({live:o(),playing:r()})]),$(i,a)}var Gl=(i,e,t)=>{let o;return()=>(window.clearTimeout(o),i?o=window.setTimeout(()=>e.set(!0),t):e.set(!1),()=>window.clearTimeout(o))};var Wy=L('<div role="timer" data-testid="thumb-timer"><!></div>'),Ky={hash:"s-n",code:".thumb-timer.s-n{bottom:0;margin:8px;position:absolute;right:0;transition:visibility var(--controls-transition-duration),opacity var(--controls-transition-duration);z-index:var(--thumb-timer-z-index)}"};function nc(i,e){B(e,!0),Q(i,Ky);let[t,o]=De(),r=()=>w(m,"$disabled",t),a=h(e,"isHidden",3,!1),l=h(e,"isLive",3,!1),d=h(e,"isPlaying",3,!1),s=Ot(),u=f(()=>en(e.duration-e.position)),m=de(!1);var p=Wy();let v;var b=C(p);oc(b,{get time(){return n(u)},get isLive(){return l()},get isPlaying(){return d()},withEqualizer:!0}),S(p),Os(p,()=>Gl(a()&&s.features.usePerformanceFix,m,s.disableInvisibleComponentsTimeout)),O(y=>v=oe(p,1,"thumb-timer s-n",null,v,y),[()=>({"out-of-flow":r(),hidden:a()})]),$(i,p),H(),o()}var Yl=i=>{if(!navigator.clipboard){ub(i);return}navigator.clipboard.writeText(i).catch(()=>ub(i))};function ub(i){if(document.queryCommandSupported&&document.queryCommandSupported("copy")){let e=document.createElement("textarea");e.textContent=i,e.style.position="absolute",e.style.top="-9999px",document.body.appendChild(e),e.select();try{document.execCommand("copy")}finally{document.body.removeChild(e)}}}var op=require("@vkontakte/videoplayer-core/es2015");var hm=require("@vkontakte/videoplayer-core/es2015");var gm="focus-hidden";var Dr=i=>{i.stopPropagation(),i.preventDefault()},_m=i=>{var e,t;(t=(e=i.parentNode)==null?void 0:e.firstElementChild)==null||t.classList.remove(gm)},Qy=i=>{var t;let e=i.previousElementSibling;e||(e=(t=i.parentNode)==null?void 0:t.lastElementChild),e==null||e.focus()},Gy=i=>{var t;let e=i.nextElementSibling;e||(e=(t=i.parentNode)==null?void 0:t.firstElementChild),e==null||e.focus()},Yy=i=>{let e=i.code;return e==="Tab"&&!i.shiftKey||e==="ArrowDown"},jy=i=>{let e=i.code;return e==="Tab"||e==="ArrowUp"},pb=i=>i.code==="Escape",Xy=i=>i.code==="ArrowLeft",rc=(i,e=[])=>{let t=i.code;return["Enter","Space",...e].includes(t)},fb=i=>{Yy(i)?(Dr(i),Gy(i.target)):jy(i)&&(Dr(i),Qy(i.target))},fa=i=>!hm.clientChecker.device.isAndroid&&(i==null?void 0:i.detail)===0||hm.clientChecker.device.isAndroid&&(i==null?void 0:i.pointerType)==="",jl=(i,e,t)=>ht(null,null,function*(){yield ho(),i&&!i.classList.contains("opened")&&!e&&ye(t)&&(yield ho(),t.set(!1),i.focus())}),mb=(i,e,t)=>ht(null,null,function*(){yield ho(),i&&!e&&ye(t)&&(t.set(!1),i.focus())}),sc=(i,e,t,o=!1)=>ht(null,null,function*(){if(yield ho(),!!i&&e&&!o){let a=i.children[0];a==null||a.classList.toggle(gm,!t),a==null||a.focus()}}),vb=(i,e)=>ht(null,null,function*(){setTimeout(()=>{let t=i[e];!!t&&t.focus()},100)}),tp=(i,e)=>{fb(i),_m(i.target),pb(i)&&(Dr(i),e())},ip=(i,e)=>ht(null,null,function*(){rc(i,["ArrowRight"])&&(Dr(i),e())}),gb=(i,e,t)=>ht(null,null,function*(){if(fb(i),Xy(i)){Dr(i),e();return}pb(i)&&(Dr(i),t())}),Xl=(i,e)=>{rc(i)&&(Dr(i),e())},hb=(i,e,t)=>{if(rc(i))Dr(i),t(!e);else{let o=i.code;if(o==="ArrowLeft"&&e){t(!1),Dr(i);return}o==="ArrowRight"&&!e&&(t(!0),Dr(i))}},_b=i=>{let e=i.getBoundingClientRect(),t=-14,o=e.left+e.width,r=e.top+t;return{right:o,bottom:r}},bb=i=>{if(!i)return{top:0,left:0};let e=i.getBoundingClientRect(),t=-58,o=8,r=e.left+o;return{bottom:e.bottom+t,left:r}};var ja=require("@vkontakte/videoplayer-shared/es2015");var ls={"copy-link":100,"copy-link-timestamp":200,"copy-embed-code":300,pip:400,"video-loop":500,rotate:600,report:700,"save-debug":800,"save-trace":900,"debug-info":1e3};var bm=require("@vkontakte/videoplayer-shared/es2015");var Jy=(i,e)=>{Xl(i,()=>e())},e0=L('<li class="item s-1m" role="menuitem" tabindex="0"> </li>'),t0={hash:"s-1m",code:".item.s-1m{color:hsla(0,0%,100%,.72);cursor:pointer;display:block;font-size:13px;letter-spacing:-.14px;line-height:18px;padding:8px 16px;position:relative;white-space:nowrap}.item.s-1m:hover{background:rgba(66,66,66,.5);color:var(--white)}"};function $m(i,e){B(e,!0),Q(i,t0);let t=h(e,"onClick",3,bm.noop),o=h(e,"closeContextMenu",3,bm.noop),r=d=>{d==null||d.stopPropagation(),t()(),o()()};var a=e0();a.__click=r,a.__keydown=[Jy,r];var l=C(a,!0);S(a),O(()=>{var d;Re(a,"aria-label",(d=e.ariaLabel)!=null?d:e.label),Re(a,"data-testid",e.id),ve(l,e.label)}),$(i,a),H()}Ye(["click","keydown"]);var Ya=(i,e)=>i.weight-e.weight;var Zl=(o=>(o.OPEN_SUB_MENU="OPEN_SUB_MENU",o.CLICK="CLICK",o.SWITCH="SWITCH",o))(Zl||{});var i0=(i,e)=>{tp(i,e)},o0=i=>{i.preventDefault()},n0=L('<ul role="menu" data-testid="context-menu" class="s-y"></ul>'),r0={hash:"s-y",code:"ul.s-y{background:rgba(0,0,0,.72);border-radius:8px;list-style:none;margin:0;max-height:100%;max-width:100%;overflow-x:hidden;overflow-y:auto;padding:6px 0;position:absolute;transition:visibility .1s,opacity .1s;z-index:var(--context-menu-z-index)}"};function ym(i,e){B(e,!0),Q(i,r0);let[t,o]=De(),r=()=>w(we,"$playerPhase",t),a=()=>w(ae,"$isLive$",t),l=()=>w(me,"$isPiPEnabled$",t),d=()=>w(X,"$chromecastState$",t),s=()=>w(ee,"$pictureInPictureApiIsActive$",t),u=()=>w(J,"$isLooped$",t),m=()=>w(Z,"$positionExact$",t),p=()=>w(z,"$additionalContextMenuItems$",t),v=h(e,"visible",3,!1),b=h(e,"position",19,()=>({top:0,left:0})),y=h(e,"playerContainerRef",3,void 0),_=h(e,"menuElementRef",15,void 0),x=q(0),I=q(0),T=be(),{pictureInPicture$:R}=yo(),A=Ot(),P=T.ui.contextMenu.visible$,E=T.ui.debugPanelVisible,z=T.ui.additionalContextMenuItems$,F=T.ui.t,U=T.actions.internal.togglePictureInPicture,X=T.state.chromecastState$,ae=T.state.isLive$,Z=T.state.positionExact$,re=T.state.isInteractive,J=T.state.looped$,we=T.playerPhase,{isEnabled$:me,isActive$:ee}=R,_e=f(()=>r()==="video"),Ce=f(()=>!!a()&&n(_e)),ge=f(()=>["thumb","LiveWaitingStart","LiveWaitingRecover","LiveWaitingRecord"].includes(r())),pe=f(()=>{var fe;return A.features.copyVideoLink&&((fe=T.callbacks)==null?void 0:fe.onCopyVideoLink)}),Qe=f(()=>n(pe)&&!n(ge)&&!re&&!n(Ce)),G=f(()=>{var fe;return!!((fe=T.callbacks)!=null&&fe.onCopyEmbedCodeClicked)}),D=f(()=>l()&&d()!==op.ChromecastState.CONNECTED&&!re&&n(_e)&&!op.clientChecker.browser.isFirefox),Ge=f(()=>!re&&!n(ge)&&!n(Ce)),K=f(()=>A.features.videoRotate&&!re&&!n(ge)),se=f(()=>A.showSupport&&!s()),xe=f(()=>A.features.saveTraceInfoToFile),He=()=>{var fe;P.set(!1),(fe=e.returnFocus)==null||fe.call(e)},it=(fe,Be)=>{if(!_()||!y())return;let We=_().getBoundingClientRect(),Ct=y().getBoundingClientRect();N(x,fe-Ct.left),N(I,Be-Ct.top),n(x)+We.width>Ct.width&&N(x,Ct.width-We.width),n(I)+We.height>Ct.height&&N(I,Ct.height-We.height),N(x,Math.max(n(x),0),!0),N(I,Math.max(n(I),0),!0)};Oe(()=>{ht(null,null,function*(){if(_()&&y()){yield ho();let{top:Be,left:We,bottom:Ct,right:Xt}=b(),It=We!=null?We:0,ai=Be!=null?Be:0,fi=_().getBoundingClientRect();(0,ja.isNullable)(We)&&!(0,ja.isNullable)(Xt)&&(It=Xt-fi.width),(0,ja.isNullable)(Be)&&!(0,ja.isNullable)(Ct)&&(ai=Ct-fi.height),It=Math.max(It,0),ai=Math.max(ai,0),it(It,ai)}})});let ne=()=>{T.actions.internal.videoRotate()},ce=()=>{(0,ja.isValidURL)(e.supportLink)&&window.open(e.supportLink,"_blank"),T.actions.internal.reportProblem(),T.actions.internal.pause()},Ne=()=>{let fe=T.actions.internal.getDebugTextData();if(A.features.saveDebugInfoToFile){let Be=new Blob([...fe],{type:"plain/text"}),We=window.URL.createObjectURL(Be);Ka(We,"vk_player_debug_info","txt")}else Yl(T.actions.internal.getDebugTextData())},Le=()=>{let fe=T.actions.internal.getTraceTextData(),Be=new Blob([...fe],{type:"application/json"}),We=window.URL.createObjectURL(Be);Ka(We,"vk_player_trace_info","json")},et=()=>{E.set(!0)},Ee=()=>ht(null,null,function*(){var fe;try{U()}finally{(fe=e.returnFocus)==null||fe.call(e)}}),Te=()=>{T.actions.internal.setLooped(!u())},Fe=()=>{var fe,Be;if(n(G)){let We=(Be=(fe=T.callbacks)==null?void 0:fe.onCopyEmbedCodeClicked)==null?void 0:Be.call(fe);We&&Yl(We)}},kt=(fe=!1)=>{var Be,We;if((Be=T.callbacks)!=null&&Be.onCopyVideoLink){let Ct=(We=T.callbacks)==null?void 0:We.onCopyVideoLink(fe,m());Ct&&Yl(Ct)}},Tt=f(()=>A.features.saveDebugInfoToFile?F("menu_save_debug"):F("menu_copy_debug")),Vt=f(()=>n(pe)?{id:"copy-link",weight:ls["copy-link"],label:F("menu_copy_video_link"),onClick:()=>kt()}:void 0),pt=f(()=>n(Qe)?{id:"copy-link-timestamp",weight:ls["copy-link-timestamp"],label:F("menu_copy_video_link_with_timestamp"),onClick:()=>kt(!0)}:void 0),At=f(()=>n(G)?{id:"copy-embed-code",weight:ls["copy-embed-code"],label:F("menu_copy_embed_code"),onClick:Fe}:void 0),ti=f(()=>n(D)?{id:"pip",weight:ls.pip,label:s()?F("menu_pip_close"):F("menu_pip"),onClick:Ee}:void 0),Lt=f(()=>n(Ge)?{id:"video-loop",weight:ls["video-loop"],label:u()?F("menu_video_loop_off"):F("menu_video_loop_on"),ariaLabel:F("aria_label_menu_loop"),onClick:Te}:void 0),Ft=f(()=>n(K)?{id:"rotate",weight:ls.rotate,label:F("menu_video_rotate"),ariaLabel:F("aria_label_menu_rotate"),onClick:ne}:void 0),qt=f(()=>n(se)?{id:"report",weight:ls.report,label:F("menu_report"),ariaLabel:`${F("menu_report")}. ${F("aria_label_new_tab_alert")}`,onClick:ce}:void 0),Y=f(()=>({id:"save-debug",weight:ls["save-debug"],label:n(Tt),onClick:Ne})),Pe=f(()=>n(xe)?{id:"save-trace",weight:ls["save-trace"],label:F("menu_save_debug"),onClick:Le}:void 0),le=f(()=>({id:"debug-info",weight:ls["debug-info"],label:F("menu_debug_overlay"),ariaLabel:F("aria_label_menu_debug_overlay"),onClick:et})),$e=f(()=>[n(Vt),n(pt),n(At),n(ti),n(Lt),n(Ft),n(qt),n(Y),n(Pe),n(le),...p()].filter(fe=>!!fe).sort(Ya));var Ve=Me(),dt=ue(Ve);{var St=fe=>{var Be=n0();Be.__contextmenu=[o0],Be.__keydown=[i0,He],yi(Be,21,()=>n($e),We=>We.id,(We,Ct)=>{$m(We,{get id(){return n(Ct).id},get label(){return n(Ct).label},get ariaLabel(){return n(Ct).ariaLabel},get onClick(){return n(Ct).onClick},closeContextMenu:He})}),S(Be),Xe(Be,We=>_(We),()=>_()),O(()=>{var We,Ct;return qe(Be,`top: ${(We=n(I))!=null?We:""}px; left: ${(Ct=n(x))!=null?Ct:""}px;`)}),$(fe,Be)};V(dt,fe=>{v()&&fe(St)})}$(i,Ve),H(),o()}Ye(["contextmenu","keydown"]);var np=class{constructor(e){this.value=e,this.next=null}};var Jl=class{constructor(e){this.top=null,this.bottom=null,this.size=0,this.maxSize=e}push(e){let t=new np(e);this.top?(this.top.next=t,this.top=t):(this.top=t,this.bottom=t),this.size++,this.size>this.maxSize&&this.bottom&&(this.bottom=this.bottom.next)}getValuesFromBottom(){let e=[],t=this.bottom;for(;t;)e.push(t.value),t=t.next;return e}};var s0=L('<div class="container s-1f"><canvas class="s-1f"></canvas></div>'),a0={hash:"s-1f",code:".container.s-1f{display:inline-block;height:16px;width:120px}canvas.s-1f{margin-top:2px;transform:scaleY(-1)}"};function ac(i,e){B(e,!0),Q(i,a0);let t=h(e,"values",19,()=>[]),o=q(void 0),r=q(null),a=16,l=120,d=60,s=l/d;Dt(()=>{n(o).width=l,n(o).height=a,N(r,n(o).getContext("2d"),!0)});function u(v,b,y,_,x){x===0&&(x=1),v.fillStyle="#fff",v.fillRect(b,y,_,x)}Oe(()=>{let v="";if(n(r)){let b=t()[0];for(let _=1;_<t().length;_++)t()[_]>b&&(b=t()[_]);n(r).clearRect(0,0,l,a);let y=d-1;for(let _=t().length-1;_>=0;_--){let x=y*s,I=b>0?a*(t()[_]/b):0;u(n(r),x,0,s,I),v=I+" "+v,y--}}});var m=s0(),p=C(m);Xe(p,v=>N(o,v),()=>n(o)),S(m),$(i,m),H()}var xm=require("@vkontakte/videoplayer-shared/es2015");var l0=(i,e)=>{i.stopPropagation(),xm.safeStorage.remove(Qd),e.set(!1)},d0=L('<div class="s-h"><div class="s-h">Video id</div> <span> </span></div>'),c0=L('<div class="s-h"><div class="s-h">VSID</div> <span> </span></div>'),u0=L('<div class="s-h"><div class="s-h">Provider</div> <span> </span></div>'),p0=L('<div class="s-h"><div class="s-h">Streams</div> <span> </span></div>'),f0=L('<div class="s-h"><div class="s-h">Viewport</div> <span> </span></div>'),m0=L('<div class="s-h"><div class="s-h">Video size</div> <span> </span></div>'),v0=L('<div class="s-h"><div class="s-h">CDN host</div> <span> </span></div>'),g0=L('<div class="s-h"><div class="s-h">Volume</div> <span> </span></div>'),h0=L('<div class="s-h"><div class="s-h">Position</div> <span> </span></div>'),_0=L('<div class="s-h"><div class="s-h">Buffer</div> <span> </span></div>'),b0=L('<div class="s-h"><div class="s-h">Nbuffer</div> <span> </span></div>'),$0=L('<div class="s-h"><div class="s-h">Live latency</div> <span> </span></div>'),y0=L('<div class="s-h"><div class="s-h">Segment</div> <span> </span></div>'),x0=L('<div class="s-h"><div class="s-h">Network</div> <!> <span> </span></div>'),w0=L('<div class="s-h"><div class="s-h">V bitrate</div> <!> <span> </span></div>'),S0=L('<div role="region"><button class="close s-h" title="закрыть">[x]</button> <div class="content s-h"><div class="s-h"><div class="s-h">Version</div> <span> </span></div> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <div class="s-h"><div class="s-h">Dropped</div> <span> </span></div> <!> <!> <div class="s-h"><div class="s-h">FPS</div> <!> <span> </span></div></div></div>'),C0={hash:"s-h",code:".container.s-h{background:rgba(28,28,28,.8);border-radius:4px;color:#fff;font-size:10px;left:20px;min-width:160px;position:absolute;text-align:left;top:45px;user-select:text;z-index:var(--debug-panel-z-index)}.container-mobile.s-h{left:16px;top:16px}button.close.s-h{background-color:transparent;border:none;color:#fff;cursor:pointer;outline:0;padding:0;position:absolute;right:5px;top:3px}.content.s-h{padding:5px}.content.s-h>div:where(.s-h)>div:where(.s-h){display:inline-block;padding:0 5px;text-align:right;width:60px}"};function lc(i,e){B(e,!0),Q(i,C0);let[t,o]=De(),r=()=>w(d,"$isMobile",t),a=be(),l=a.ui.debugPanelVisible,d=a.ui.isMobile,s=q(ui(a.actions.internal.getDebugPanelData())),u=a.actions.internal.getVideoElement(),m=q(0),p=q(0),v=q(0),b=new Jl(60),y=new Jl(60),_=new Jl(60),x=q(ui([])),I=q(ui([])),T=q(ui([])),R=j("aria_label_debug_panel");Dt(()=>{xm.safeStorage.set(Qd,"true"),a.actions.internal.startLogging(),u&&(N(p,u.getVideoPlaybackQuality().droppedVideoFrames,!0),N(m,u.getVideoPlaybackQuality().totalVideoFrames,!0));let Y=window.setInterval(()=>{N(s,a.actions.internal.getDebugPanelData(),!0)},500),Pe;return u&&(Pe=window.setInterval(()=>{if(u){N(p,u.getVideoPlaybackQuality().droppedVideoFrames,!0);let le=u.getVideoPlaybackQuality().totalVideoFrames;N(v,le-n(m)),N(m,le,!0),b.push(n(v)),n(s).speed&&y.push(n(s).speed),n(s).bitrate&&_.push(n(s).bitrate),N(x,b.getValuesFromBottom(),!0),N(I,y.getValuesFromBottom(),!0),N(T,_.getValuesFromBottom(),!0)}},1e3)),()=>{a.actions.internal.stopLogging(),clearInterval(Y),Pe&&clearInterval(Pe)}});var A=S0();let P;var E=C(A);E.__click=[l0,l];var z=k(E,2),F=C(z),U=k(C(F),2),X=C(U,!0);S(U),S(F);var ae=k(F,2);{var Z=Y=>{var Pe=d0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(()=>ve($e,n(s).id)),$(Y,Pe)};V(ae,Y=>{n(s).id&&Y(Z)})}var re=k(ae,2);{var J=Y=>{var Pe=c0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(()=>ve($e,n(s).vsid)),$(Y,Pe)};V(re,Y=>{n(s).vsid&&Y(J)})}var we=k(re,2);{var me=Y=>{var Pe=u0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(()=>ve($e,n(s).provider)),$(Y,Pe)};V(we,Y=>{n(s).provider&&Y(me)})}var ee=k(we,2);{var _e=Y=>{var Pe=p0(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),O(()=>{var Ve,dt;return ve($e,`Video: ${(Ve=n(s).videoCodec||"")!=null?Ve:""} ${n(s).hdr?"(HDR)":""}
|
|
54
|
+
Try switching the quality to Auto.`,double_forward_label:"2x",preview_track_notification_text:"pull up to open precise rewind",preview_track_close_tooltip:"dismiss precise rewind"},tb=gy;var Bs=new Map;Bs.set(zl.InterfaceLanguage.EN,tb);Bs.set(zl.InterfaceLanguage.RU,eb);var ib=new Map,am=({language:i,pack:e,fallback:t})=>{if(Bs.has(i)){let o=Bs.get(i);Bs.set(i,Ve(Ve({},o),e))}else Bs.set(i,e);ib.set(i,t)},lm=i=>Bs.has(i),dm=(i,e,t,o)=>{var l;let r=Bs.get(i),a=r==null?void 0:r[e];if((0,zl.isNullable)(a)){let d=(l=ib.get(i))!=null?l:o,s=d?Bs.get(d):void 0;a=s==null?void 0:s[e]}return(0,zl.isNullable)(a)?e+Object.values(t!=null?t:{}).join(" "):t?a.replaceAll(/{(\w+?)}/g,(d,s)=>{var u;return(u=t[s])!=null?u:""}):a},Y=(i,e)=>{let{interfaceLanguage$:t}=$e(),o=be(t),r=Dt();return dm(o,i,e,r.defaultLanguage)};var hy=Ee('<path d="M26.86 15.18a3.7 3.7 0 0 0 2.53-3.6C29.4 8.91 27.2 7 24.07 7c-1.96 0-3.57.78-4.67 2.29l-.1.15a1.33 1.33 0 0 0 .26 1.85c.54.4 1.3.35 1.74-.16l.2-.25a3 3 0 0 1 2.5-1.3c1.53 0 2.6.91 2.6 2.25 0 1.36-1.09 2.27-2.65 2.27h-.58a1.23 1.23 0 0 0 0 2.47h.58c1.75 0 2.91.98 2.91 2.39 0 1.45-1.19 2.46-2.88 2.46a3.2 3.2 0 0 1-2.89-1.6l-.2-.29a1.4 1.4 0 0 0-2.05-.25 1.3 1.3 0 0 0-.3 1.68l.21.33A6 6 0 0 0 24 24c3.28 0 5.63-2.04 5.63-4.92a4 4 0 0 0-2.77-3.9M37.73 12.68c-.46 0-1 .04-1.5.16L38.8 9.1a1.34 1.34 0 1 0-2.2-1.52l-3.76 5.47C31.43 15.18 31 16.87 31 18.33 31 21.8 33.56 24 37.19 24c3.6 0 6.16-2.4 6.16-5.77a5.4 5.4 0 0 0-5.63-5.56m-.53 8.74c-1.98 0-3.33-1.27-3.33-3.14 0-1.85 1.35-3.14 3.33-3.14 1.95 0 3.3 1.29 3.3 3.14 0 1.87-1.35 3.14-3.3 3.14m20.8-5.9c0 5.03-2.7 8.43-6.63 8.43s-6.62-3.4-6.62-8.44 2.7-8.44 6.62-8.44S58 10.47 58 15.51m-10.35 0c0 3.56 1.49 5.85 3.72 5.85s3.72-2.3 3.72-5.86-1.48-5.86-3.72-5.86c-2.23 0-3.72 2.3-3.72 5.86M67 9.49A3.5 3.5 0 0 1 63.51 13 3.5 3.5 0 0 1 60 9.49 3.5 3.5 0 0 1 63.51 6 3.5 3.5 0 0 1 67 9.49m-5 0c0 .83.68 1.51 1.51 1.51.81 0 1.5-.68 1.5-1.51 0-.81-.69-1.5-1.5-1.5-.83 0-1.51.69-1.51 1.5ZM67 23.5c0-1.32-1.2-3.1-4.2-4.67a1.5 1.5 0 1 1 1.4-2.66c3.25 1.72 5.8 4.26 5.8 7.33 0 3.13-2.56 5.55-6.09 7.27-3.63 1.77-8.82 3.06-15.26 3.72a1.5 1.5 0 0 1-.3-2.98c6.25-.64 11.05-1.88 14.25-3.44 3.3-1.6 4.4-3.27 4.4-4.57M38.88 35H38c-9.64 0-17.45-1.13-22.9-3.02-2.72-.94-4.94-2.1-6.5-3.47C7.01 27.14 6 25.44 6 23.5a6.2 6.2 0 0 1 1.9-4.25 16 16 0 0 1 4.43-3.1 1.5 1.5 0 1 1 1.34 2.7q-2.39 1.19-3.59 2.46C9.3 22.14 9 22.87 9 23.5c0 .8.4 1.74 1.57 2.76s3 2.01 5.51 2.89C21.11 30.89 28.55 32 38 32h.88l-1.44-1.44a1.5 1.5 0 0 1 2.12-2.12l4 4h.01a1.5 1.5 0 0 1 .32 1.63 2 2 0 0 1-.33.5l-4 4a1.5 1.5 0 0 1-2.12-2.13z"></path>');function Xd(i,e){B(e,!1);let t=Y("video360");on(),Ze(i,{width:"76",height:"45",get ariaLabel(){return t},testId:"video-360-icon",shadow:!0,children:(o,r)=>{var a=hy();$(o,a)},$$slots:{default:!0}}),H()}var BV=require("@vkontakte/videoplayer-core/es2015");var Wl;(function(i){i.fatal="fatal",i.error="error",i.warning="warning",i.log="log",i.info="info",i.debug="debug",i.critical="critical"})(Wl||(Wl={}));var _y=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,by=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js))(?::(\d+))?(?::(\d+))?\s*$/i,$y=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Ku="?",yy="X-Sentry-Auth",xy=/^(?:(\w+):)\/\/(?:([\w-]+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function wy(i){if(!i.stack)return null;let e=[],t=i.stack.split(`
|
|
55
|
+
`),o,r;for(let a=0;a<t.length;++a){if(o=_y.exec(t[a]))r={filename:o[2]&&o[2].indexOf("address at ")===0?o[2].substr(11):o[2],function:o[1]||Ku,lineno:o[3]?+o[3]:null,colno:o[4]?+o[4]:null};else if(o=$y.exec(t[a]))r={filename:o[2],function:o[1]||Ku,lineno:+o[3],colno:o[4]?+o[4]:null};else if(o=by.exec(t[a]))a===0&&!o[5]&&i.columnNumber!==void 0&&(e[0].column=i.columnNumber+1),r={filename:o[3],function:o[1]||Ku,lineno:o[4]?+o[4]:null,colno:o[5]?+o[5]:null};else continue;!r.function&&r.lineno&&(r.function=Ku),e.push(r)}return e.length?{value:ob(i),type:i.name,stacktrace:{frames:e.reverse()}}:null}function ob(i){return(i&&i.message||"No error message").split(`
|
|
56
|
+
`).filter(t=>!!t)[0]}function Sy(i){try{let e=wy(i);if(e)return e}catch(e){}return{value:ob(i),type:i&&i.name,stacktrace:{frames:[]}}}function Cy(){return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,i=>{let e=Math.random()*16|0;return(i==="x"?e:e&3|8).toString(16)})}var qu=class{constructor(e){if(e&&e.dsn){let t=xy.exec(e.dsn),o=t?t.slice(1):[],r=o[5].split("/"),a=r.slice(0,-1).join("/");this.apiUrl=o[0]+"://"+o[3]+(o[4]?":"+o[4]:"")+(a?"/"+a:"")+"/api/"+r.pop()+"/store/",this.authHeader="Sentry sentry_version=7,sentry_key="+o[1]+(o[2]?",sentry_secret="+o[2]:"")}this.environment=e&&e.environment}prepare(e){return Gt(Ve({},this.getRequestBlank()),{exception:{values:[Sy(e)]}})}report(e){this.send(this.prepare(e))}send(e){!this.apiUrl||!e||this.createRequest(e)}createRequest(e){let t=new XMLHttpRequest;t.open("POST",this.apiUrl,!0),t.setRequestHeader("Content-type","application/json"),t.setRequestHeader(yy,this.authHeader||""),t.send(JSON.stringify(e))}getRequestBlank(){return{platform:"javascript",event_id:Cy(),sdk:{name:"micro-sentry.javascript.core",version:"0.0.0"},timestamp:Date.now()/1e3,environment:this.environment}}};function nb(i,e){return Object.prototype.toString.call(e)==="[object RegExp]"?e.test(i):typeof e=="string"?i.indexOf(e)!==-1:!1}function Ty(){return window}var Qu=class i extends qu{constructor(e,t=Ty()){super(e),this.options=e,this.window=t,this.destroyed=!1,this._state={};let{plugins:o=[],beforeSend:r=u=>u,beforeBreadcrumb:a=u=>u,blacklistUrls:l=[],ignoreErrors:d=[],release:s=void 0}=this.options||{};this.plugins=o.map(u=>new u(this)),this.beforeSend=r,this.beforeBreadcrumb=a,this.blacklistUrls=l,this.ignoreErrors=d,this.release=s}get state(){return this._state}clearState(){this._state={}}setTags(e){return this.setKeyState("tags",Ve({},e)),this}setTag(e,t){return this.extendState({tags:{[e]:t}}),this}setExtra(e,t){return this.extendState({extra:{[e]:t}}),this}setExtras(e){return this.setKeyState("extra",Ve({},e)),this}setUser(e){return this.setKeyState("user",Ve({},e)),this}clone(){let e=new i(Gt(Ve({},this.options),{plugins:[]}));return e.extendState(this.state),e}withScope(e){let t=this.clone();e(t),t.destroy(),this.setBreadcrumbs(void 0)}addBreadcrumb(e){this.extendState({breadcrumbs:[Ve({timestamp:Date.now()/1e3},this.beforeBreadcrumb(e))]})}setBreadcrumbs(e){this.setKeyState("breadcrumbs",e)}captureMessage(e,t){this.send(Gt(Ve({},this.getRequestBlank()),{message:e,level:t}))}destroy(){this.destroyed=!0,this.plugins.forEach(e=>{e.destroy&&e.destroy()})}isIgnoredError(e){return this.ignoreErrors.length?this.getPossibleEventMessages(e).some(t=>this.ignoreErrors.some(o=>nb(t,o))):!1}getRequestBlank(){return Ve(Gt(Ve({request:{url:this.window.location.toString(),headers:{"User-Agent":this.window.navigator.userAgent}}},super.getRequestBlank()),{sdk:{name:"micro-sentry.javascript.browser",version:"0.0.0"}}),this.state)}send(e){this.destroyed||this.isDeniedUrl(e)||this.isIgnoredError(e)||(super.send(this.beforeSend(Ve({release:this.release},e))),this.setBreadcrumbs(void 0))}getPossibleEventMessages(e){if(e.message)return[e.message];if(e.exception)try{let{type:t="",value:o=""}=e.exception.values&&e.exception.values[0]||{};return[`${o}`,`${t}: ${o}`]}catch(t){return[]}return[]}isDeniedUrl(e){if(!this.blacklistUrls.length)return!1;let t=this.getEventFilterUrl(e);return t?this.blacklistUrls.some(o=>nb(t,o)):!1}getEventFilterUrl(e){try{if(e.exception){let t=e.exception.values&&e.exception.values[0].stacktrace&&e.exception.values[0].stacktrace.frames;return t&&t[t.length-1].filename||null}return null}catch(t){return null}}extendState(e){this._state=Object.keys(e).reduce((t,o)=>{let r=this._state[o],a=Array.isArray(r)?r:null,l=e[o],d=Array.isArray(l)?l:null;return Gt(Ve({},t),{[o]:a||d?[...a||[],...d||[]]:Ve(Ve({},typeof r!="string"?r:{}),typeof l!="string"?l:{})})},this._state)}setKeyState(e,t){this._state[e]=t}};var Wa=require("@vkontakte/videoplayer-shared/es2015");var Gu=null,Ka=class{constructor(e,t,o={}){!Gu&&e.dsn&&(this.sentryClient=new Qu({dsn:e.dsn,environment:t.env}),this.version=t.version,this.sentrySubscription=new Wa.Subscription,this.options=e,this.context=o,Gu=this)}destroy(){var e,t;(e=this.sentryClient)==null||e.destroy(),(t=this.sentrySubscription)==null||t.unsubscribe(),Gu=null}logIError(e,t=!1){e.thrown&&this.report(e.thrown,{fatal:t,errorType:e.id,category:e.category},{message:e.message,errorData:e.data})}report(e,t={},o={}){let{sentryClient:r,context:a,options:l}=this,{sampleRate:d=0,whiteErrorIdList:s,whiteErrorCategoryList:u=[],blackErrorIdList:m,blackErrorCategoryList:p}=l,{errorType:v,category:b}=t;if((0,Wa.isNonNullable)(b)&&p.includes(b)||(0,Wa.isNonNullable)(v)&&m.includes(v))return;if(Math.random()<=d||(0,Wa.isNonNullable)(b)&&u.includes(b)||(0,Wa.isNonNullable)(v)&&s.includes(v)){Object.keys(t).length&&r.setTags(Ve({version:this.version},t)),(Object.keys(a).length||Object.keys(o).length)&&r.setExtras(Ve(Ve({},a),o));try{v&&r.captureMessage(v,t.fatal?Wl.fatal:Wl.error),r.report(e)}catch(_){console.error(_)}}}static getInstance(){return Gu}};var ns=(d=>(d.Thumb="thumb",d.Video="video",d.Ads="ads",d.Crashed="crashed",d.LiveWaitingStart="LiveWaitingStart",d.LiveWaitingRecover="LiveWaitingRecover",d.LiveWaitingRecord="LiveWaitingRecord",d))(ns||{});var Yu=i=>{if(i.requestFullscreen)return i.requestFullscreen();if(i.msRequestFullscreen)return i.msRequestFullscreen();if(i.webkitRequestFullscreen)return i.webkitRequestFullscreen();if(i.mozRequestFullScreen)return i.mozRequestFullScreen();let e=i.querySelector("video");return e!=null&&e.webkitEnterFullscreen?(e.webkitEnterFullscreen(),Promise.resolve()):Promise.reject()},ju=i=>i.exitFullscreen?i.exitFullscreen():i.msExitFullscreen?i.msExitFullscreen():i.webkitExitFullscreen?i.webkitExitFullscreen():i.mozCancelFullScreen?i.mozCancelFullScreen():Promise.reject(),rb=(i,e)=>e?!0:i.fullscreenEnabled||!!i.webkitFullscreenEnabled||!!i.mozFullscreenEnabled||!!i.msFullscreenEnabled,sb=i=>{let e=i;e!=null&&e.webkitExitFullscreen&&(e==null||e.webkitExitFullscreen())},Zd=()=>{let i=document;return i.fullscreenElement||i.mozFullScreenElement||i.webkitFullscreenElement||i.msFullscreenElement},ca=()=>!!Zd(),Xu=i=>{document.addEventListener("fullscreenchange",i),document.addEventListener("webkitfullscreenchange",i),document.addEventListener("mozfullscreenchange",i),document.addEventListener("MSFullscreenChange",i)},Zu=i=>{document.removeEventListener("fullscreenchange",i),document.removeEventListener("webkitfullscreenchange",i),document.removeEventListener("mozfullscreenchange",i),document.removeEventListener("MSFullscreenChange",i)},ab=i=>{let e=window.screen;return(r=>bt(null,null,function*(){return e.orientation?e.orientation.lock(r):e.mozLockOrientation?e.mozLockOrientation(r):e.msLockOrientation?e.msLockOrientation(r):Promise.reject()}))(((r={width:0,height:0})=>r.width<=r.height?"portrait":"landscape")(i))};var cm=require("@vkontakte/videoplayer-core/es2015"),lb=()=>({title:Y("hotkey_map_modal_title"),closeBtnText:Y("hotkey_map_modal_close_btn_text"),groups:[{title:Y("hotkey_map_group_title_common"),items:[{description:Y("hotkey_map_item_mute_description"),value:Y("hotkey_map_item_mute_value")},{description:Y("hotkey_map_item_volume_up_description"),value:Y("hotkey_map_item_volume_up_value")},{description:Y("hotkey_map_item_volume_down_description"),value:Y("hotkey_map_item_volume_down_value")},{description:Y("hotkey_map_item_pip_description"),value:Y("hotkey_map_item_pip_value")},{description:Y("hotkey_map_item_full_screen_description"),value:Y("hotkey_map_item_full_screen_value")},{description:Y("hotkey_map_item_show_context_menu_description"),value:Y("hotkey_map_item_show_context_menu_value")},{description:Y("hotkey_map_item_show_hotkey_map_description"),value:Y("hotkey_map_item_show_hotkey_map_value")}]},{title:Y("hotkey_map_group_title_playback"),items:[{description:Y("hotkey_map_item_play_toggle_description"),value:Y("hotkey_map_item_play_toggle_value")},{description:Y("hotkey_map_item_seek_backward_description"),value:Y("hotkey_map_item_seek_backward_value")},{description:Y("hotkey_map_item_seek_forward_description"),value:Y("hotkey_map_item_seek_forward_value")},{description:Y("hotkey_map_item_fast_seek_backward_description"),value:Y("hotkey_map_item_fast_seek_backward_value")},{description:Y("hotkey_map_item_fast_seek_forward_description"),value:Y("hotkey_map_item_fast_seek_forward_value")},{description:Y("hotkey_map_item_rate_down_description"),value:Y("hotkey_map_item_rate_down_value")},{description:Y("hotkey_map_item_rate_up_description"),value:Y("hotkey_map_item_rate_up_value")},{description:Y("hotkey_map_item_prev_frame_description"),value:Y("hotkey_map_item_prev_frame_value")},{description:Y("hotkey_map_item_next_frame_description"),value:Y("hotkey_map_item_next_frame_value")},{description:Y("hotkey_map_item_jump_seek_description"),value:Y("hotkey_map_item_jump_seek_value")},{description:Y("hotkey_map_item_next_video_description"),value:Y("hotkey_map_item_next_video_value")},{description:Y("hotkey_map_item_prev_video_description"),value:Y("hotkey_map_item_prev_video_value")}]},{title:Y("hotkey_map_group_title_subtitles"),items:[{description:Y("hotkey_map_item_subtitles_toggle_description"),value:Y("hotkey_map_item_subtitles_toggle_value")}]},{title:Y("hotkey_map_group_title_episodes"),items:[{description:Y("hotkey_map_item_prev_episode_description"),value:cm.clientChecker.device.isApple?Y("hotkey_map_item_prev_episode_mac_value"):Y("hotkey_map_item_prev_episode_pc_value")},{description:Y("hotkey_map_item_next_episode_description"),value:cm.clientChecker.device.isApple?Y("hotkey_map_item_next_episode_mac_value"):Y("hotkey_map_item_next_episode_pc_value")}]}]});var Kl=require("@vkontakte/videoplayer-shared/es2015");function um(i,e){B(e,!1);let t=$e();Ot(()=>{t.getAdmanWrapper().startPostroll()}),on(),H()}var db=require("@vkontakte/videoplayer-shared/es2015");var Iy=Ee('<path d="M11.74 6.74a.9.9 0 0 1-1.28 0L6 2.27 1.54 6.74A.9.9 0 1 1 .26 5.46l5.1-5.1a.9.9 0 0 1 1.28 0l5.1 5.1a.9.9 0 0 1 0 1.28Z"></path>'),Ey=Ee('<path d="m5.773 8 3.363 3.364a.9.9 0 1 1-1.272 1.272l-4-4a.9.9 0 0 1 0-1.272l4-4a.9.9 0 0 1 1.272 1.272L5.773 8z"></path>');function Rr(i,e){B(e,!0);let t=h(e,"direction",3,"left"),o=h(e,"useBtnColor",3,!1),r=f(()=>["up","down"].includes(t())),a=f(()=>["right","down"].includes(t())),l=f(()=>`chevron-icon--${t()}`),d=f(()=>(()=>{let m="";return n(a)&&(m+="transform: rotate(180deg);"),m.length?m:void 0})()),s=f(()=>o()?da:"currentColor"),u=f(()=>n(r)?"7":"16");Ze(i,{width:"12",get height(){return n(u)},get fill(){return n(s)},get testId(){return n(l)},get style(){return n(d)},children:(m,p)=>{var v=Oe(),b=le(v);{var y=x=>{var I=Iy();$(x,I)},_=x=>{var I=Ey();$(x,I)};V(b,x=>{n(r)?x(y):x(_,!1)})}$(m,v)},$$slots:{default:!0}}),H()}var Py=(i,e,t)=>{i.stopPropagation(),n(e)&&t()()},ky=L('<div class="skip s-1g"> <!></div>'),Ay=L("<div><!></div>"),Ly={hash:"s-1g",code:".container.s-1g{background:rgba(0,0,0,.56);border-radius:6px;color:#fff;font-size:13px;padding:6px 10px;position:absolute;right:16px;top:14px;transition:color .2s}.container-mobile.s-1g{bottom:14px;font-size:15px;max-width:142px;top:unset}.skip.s-1g{align-items:flex-end;display:flex;gap:4px;white-space:nowrap}.skippable.s-1g{color:var(--white);cursor:pointer}.skippable.s-1g:hover{color:hsla(0,0%,100%,.75)}"};function pm(i,e){B(e,!0),Q(i,Ly);let[t,o]=He(),r=()=>w(u,"$isMobile",t),a=h(e,"position",3,0),l=h(e,"secondsToWatchBeforeSkip",3,0),d=h(e,"skipAd",3,db.noop),u=$e().ui.isMobile,m=f(()=>a()>0&&a()>=l());var p=Ay();let v;p.__click=[Py,m,d];var b=T(p);{var y=x=>{var I=ky(),C=T(I),R=k(C);Rr(R,{direction:"right"}),S(I),N(A=>ge(C,`${A!=null?A:""} `),[()=>Y("skip_ads_now")]),$(x,I)},_=x=>{var I=bs();N(C=>ge(I,C),[()=>Y("skip_ads_after",{time:Math.ceil(l()-a()).toFixed(0)})]),$(x,I)};V(b,x=>{n(m)?x(y):x(_,!1)})}S(p),N(x=>v=oe(p,1,"container s-1g",null,v,x),[()=>({"container-mobile":r(),skippable:n(m)})]),$(i,p),H(),o()}et(["click"]);var My=L('<button class="go-to-site s-1h"> </button>'),Vy={hash:"s-1h",code:"button.go-to-site.s-1h{background:#fff;border:none;border-radius:6px;bottom:14px;color:#000;font-size:15px;left:16px;padding:6px 10px;pointer-events:none;position:absolute}"};function fm(i,e){B(e,!1),Q(i,Vy),on();var t=My(),o=T(t,!0);S(t),N(r=>ge(o,r),[()=>Y("visit_advertiser")],gr),$(i,t),H()}var Ry=L('<div class="top-gradient-mobile s-o"></div>'),Oy=L('<div class="container s-o"><!> <video style="width: 100%; height: 100%" playsinline=""></video> <!> <!> <!></div>',2),Dy={hash:"s-o",code:".container.s-o{height:100%;width:100%}.top-gradient-mobile.s-o{background:linear-gradient(1turn,transparent,rgba(0,0,0,.05) 12%,rgba(0,0,0,.15) 25%,rgba(0,0,0,.3) 45%,rgba(0,0,0,.4) 57%,rgba(0,0,0,.5) 77%,rgba(0,0,0,.55) 88%,rgba(0,0,0,.65));height:80px;left:0;pointer-events:none;position:absolute;top:0;width:100%}"};function Jd(i,e){B(e,!0),Q(i,Dy);let[t,o]=He(),r=()=>w(U,"$canSkipAd",t),a=()=>w(F,"$adPlaybackState",t),l=()=>w(R,"$isMobile",t),d=()=>w(X,"$adPosition",t),s=()=>w(se,"$secondsToWatchBeforeSkipAd",t),u=()=>w(C,"$isVideoEnded",t),m=h(e,"adsSlotId",3,void 0),p=h(e,"adsParams",3,void 0),v=h(e,"adsAutoplayParam",3,void 0),b=h(e,"duration",3,0),y=h(e,"adsExternalApi",3,void 0),_=h(e,"adsJson",3,void 0),x=$e(),I=Dt(),C=x.state.isEnded$,R=x.ui.isMobile,A=I.ads.isMobileGoToSiteButton,P=K(void 0),E=K(void 0),W=!1,F=x.ads.playbackState,U=x.ads.canSkip,X=x.ads.position,se=x.ads.secondsToWatchBeforeSkip,j=f(()=>r()&&a()!=="inactive"),ne=f(()=>l()&&a()!=="inactive"&&A);Ot(()=>{let D=x.getAdmanWrapper();if(Kl.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_mount"],numbers:[(0,Kl.now)(),m()]}),!m()){D.onAdmanLoadingError();return}let Xe=()=>{var xe;let{width:Ae,height:ze}=be(x.ui.playerSize),ee=be(x.ui.isFullscreen),de=(xe=v())!=null?xe:be(x.ui.isAutoplay),ke=I.ads.paramsOverride;return{width:Ae,height:ze,isFullscreen:ee,isAutoplay:de,adsContainer:n(P),adsVideoElement:n(E),slotId:m(),params:p(),paramsOverride:ke,duration:b(),externalApi:y(),json:_()}},re=Ae=>bt(null,null,function*(){Ae&&(yield _o());let ze=Xe();yield D.initAdman(ze),W=!0}),pe=new AbortController,ue=()=>{pe.abort()};return window.AdmanHTML?re(!0).catch(()=>{D.onAdmanLoadingError()}):D.loadAdman(pe.signal).then(()=>re(!1)).catch(()=>{D.onAdmanLoadingError()}),()=>{Kl.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_unmount"],numbers:[(0,Kl.now)(),m()]}),!W&&ue()}});var Z=Oy(),Te=T(Z);{var fe=D=>{var Xe=Ry();$(D,Xe)};V(Te,D=>{l()&&D(fe)})}var te=k(Te,2);it(te,D=>O(E,D),()=>n(E));var _e=k(te,2);{var Ce=D=>{pm(D,{get position(){return d()},get secondsToWatchBeforeSkip(){return s()},get skipAd(){return x.actions.internal.skipAd}})};V(_e,D=>{n(j)&&D(Ce)})}var me=k(_e,2);{var ce=D=>{um(D,{})};V(me,D=>{u()&&D(ce)})}var Ye=k(me,2);{var G=D=>{fm(D,{})};V(Ye,D=>{n(ne)&&D(G)})}S(Z),it(Z,D=>O(P,D),()=>n(P)),$(i,Z),H(),o()}var nn=i=>{if(!isFinite(i))return"00:00";let e=Math.round(i),t=Math.floor(e/(60*60));e-=t*3600;let o=Math.floor(e/60);e-=o*60;let r=[o,e].map(a=>String(a).padStart(2,"0")).join(":");return t>0&&(r=`${t}:${r}`),r};var Ny=Ee('<path fill="#fff"></path>'),By=Ee("<path></path><!>",1);function ec(i,e){let t=h(e,"isActive",3,!1),o=f(()=>t()?"live-active-icon":"live-icon"),r=f(()=>t()?"var(--timeline-slider-filled-active-live-bg, #FF3347)":void 0),a="M8 5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h4a1 1 0 1 0 0-2H9V6a1 1 0 0 0-1-1m7 1a1 1 0 1 1 2 0v8a1 1 0 1 1-2 0zm15-1a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h4a1 1 0 1 0 0-2h-3v-2h3a1 1 0 1 0 0-2h-3V7h3a1 1 0 1 0 0-2zm-8.32 9.31-2.55-7.82a1 1 0 0 1-.12-.37L19 6.1a1 1 0 1 1 2-.2l2 6.4 2-6.4a1 1 0 0 1 2 .2v.02a1 1 0 0 1-.13.37l-2.55 7.82a1 1 0 0 1-.95.69h-.74a1 1 0 0 1-.95-.69";Ze(i,{width:"42",height:"20",get testId(){return n(o)},get fill(){return n(r)},children:(l,d)=>{var s=By(),u=le(s),m=k(u);{var p=v=>{var b=Ny();De(b,"d",a),$(v,b)};V(m,v=>{t()&&v(p)})}N(()=>De(u,"d",`M5 0h32s5 0 5 5v10s0 5 -5 5h-32s-5 0 -5 -5v-10s0 -5 5 -5${t()?"":"M5.5 2h31s3.5 0 3.5 3.5v9s0 3.5-3.5 3.5h-31s-3.5 0-3.5-3.5v-9s0-3.5 3.5-3.5"+a}z`)),$(l,s)},$$slots:{default:!0}})}var Hy=L('<div class="equalizer s-b"><div class="col s-b"></div> <div class="col s-b"></div> <div class="col s-b"></div></div>'),Fy=L('<div class="live-icon s-b"><!></div>'),Uy=L('<span class="text s-b"> </span>'),zy=L("<div><!> <!></div>"),Wy={hash:"s-b",code:".wrapper.s-b{background-color:var(--black-alpha-40);border-radius:4px;padding:2px 6px;transition:visibility var(--controls-transition-duration),opacity var(--controls-transition-duration);white-space:nowrap}.wrapper.live.s-b{background:var(--red);border-radius:2px;font-size:0;height:20px;line-height:20px;padding:0 7px}.equalizer.s-b{display:inline-block;height:10px;margin-right:4px;margin-top:-4px;position:relative;vertical-align:middle;width:10px}.live.s-b .equalizer:where(.s-b){margin-top:-2px}.equalizer.s-b .col:where(.s-b){animation:1.5s linear infinite alternate;animation-play-state:paused;background:var(--btn-color,--white);bottom:0;height:10px;margin-right:2px;position:absolute;transform-origin:50% 100%;width:2px}.playing.s-b .equalizer:where(.s-b) .col:where(.s-b){animation-play-state:running}.equalizer.s-b .col:where(.s-b):first-child{animation-name:s-b-thumb-timer-equalizer-col1;left:0}.equalizer.s-b .col:where(.s-b):nth-child(2){animation-name:s-b-thumb-timer-equalizer-col2;left:3px}.equalizer.s-b .col:where(.s-b):nth-child(3){animation-name:s-b-thumb-timer-equalizer-col3;left:6px}.live-icon.s-b{display:inline-block;height:20px;margin:0 -7px;vertical-align:middle;width:42px}@keyframes s-b-thumb-timer-equalizer-col1{0%{transform:scaleY(.1)}25%{transform:scaleY(.8)}50%{transform:scaleY(.4)}75%{transform:scaleY(.6)}to{transform:scaleY(.1)}}@keyframes s-b-thumb-timer-equalizer-col2{0%{transform:scaleY(1)}25%{transform:scaleY(.3)}50%{transform:scaleY(.9)}75%{transform:scaleY(.6)}to{transform:scaleY(1)}}@keyframes s-b-thumb-timer-equalizer-col3{0%{transform:scaleY(.6)}25%{transform:scaleY(.9)}50%{transform:scaleY(.1)}75%{transform:scaleY(.9)}to{transform:scaleY(.6)}}.text.s-b{color:var(--controls-time);font-size:13px;font-weight:500;line-height:16px}"};function tc(i,e){Q(i,Wy);let t=h(e,"withEqualizer",3,!1),o=h(e,"isLive",3,!1),r=h(e,"isPlaying",3,!1);var a=zy();let l;var d=T(a);{var s=v=>{var b=Hy();$(v,b)};V(d,v=>{t()&&v(s)})}var u=k(d,2);{var m=v=>{var b=Fy(),y=T(b);ec(y,{isActive:!0}),S(b),$(v,b)},p=v=>{var b=Uy(),y=T(b,!0);S(b),N(()=>ge(y,e.time)),$(v,b)};V(u,v=>{o()?v(m):v(p,!1)})}S(a),N(v=>l=oe(a,1,"wrapper s-b",null,l,v),[()=>({live:o(),playing:r()})]),$(i,a)}var ql=(i,e,t)=>{let o;return()=>(window.clearTimeout(o),i?o=window.setTimeout(()=>e.set(!0),t):e.set(!1),()=>window.clearTimeout(o))};var Ky=L('<div role="timer" data-testid="thumb-timer"><!></div>'),qy={hash:"s-n",code:".thumb-timer.s-n{bottom:0;margin:8px;position:absolute;right:0;transition:visibility var(--controls-transition-duration),opacity var(--controls-transition-duration);z-index:var(--thumb-timer-z-index)}"};function ic(i,e){B(e,!0),Q(i,qy);let[t,o]=He(),r=()=>w(m,"$disabled",t),a=h(e,"isHidden",3,!1),l=h(e,"isLive",3,!1),d=h(e,"isPlaying",3,!1),s=Dt(),u=f(()=>nn(e.duration-e.position)),m=ae(!1);var p=Ky();let v;var b=T(p);tc(b,{get time(){return n(u)},get isLive(){return l()},get isPlaying(){return d()},withEqualizer:!0}),S(p),Ds(p,()=>ql(a()&&s.features.usePerformanceFix,m,s.disableInvisibleComponentsTimeout)),N(y=>v=oe(p,1,"thumb-timer s-n",null,v,y),[()=>({"out-of-flow":r(),hidden:a()})]),$(i,p),H(),o()}var Ql=i=>{if(!navigator.clipboard){cb(i);return}navigator.clipboard.writeText(i).catch(()=>cb(i))};function cb(i){if(document.queryCommandSupported&&document.queryCommandSupported("copy")){let e=document.createElement("textarea");e.textContent=i,e.style.position="absolute",e.style.top="-9999px",document.body.appendChild(e),e.select();try{document.execCommand("copy")}finally{document.body.removeChild(e)}}}var tp=require("@vkontakte/videoplayer-core/es2015");var vm=require("@vkontakte/videoplayer-core/es2015");var mm="focus-hidden";var Or=i=>{i.stopPropagation(),i.preventDefault()},gm=i=>{var e,t;(t=(e=i.parentNode)==null?void 0:e.firstElementChild)==null||t.classList.remove(mm)},Gy=i=>{var t;let e=i.previousElementSibling;e||(e=(t=i.parentNode)==null?void 0:t.lastElementChild),e==null||e.focus()},Yy=i=>{var t;let e=i.nextElementSibling;e||(e=(t=i.parentNode)==null?void 0:t.firstElementChild),e==null||e.focus()},jy=i=>{let e=i.code;return e==="Tab"&&!i.shiftKey||e==="ArrowDown"},Xy=i=>{let e=i.code;return e==="Tab"||e==="ArrowUp"},ub=i=>i.code==="Escape",Zy=i=>i.code==="ArrowLeft",oc=(i,e=[])=>{let t=i.code;return["Enter","Space",...e].includes(t)},pb=i=>{jy(i)?(Or(i),Yy(i.target)):Xy(i)&&(Or(i),Gy(i.target))},fa=i=>!vm.clientChecker.device.isAndroid&&(i==null?void 0:i.detail)===0||vm.clientChecker.device.isAndroid&&(i==null?void 0:i.pointerType)==="",Gl=(i,e,t)=>bt(null,null,function*(){yield _o(),i&&!i.classList.contains("opened")&&!e&&be(t)&&(yield _o(),t.set(!1),i.focus())}),fb=(i,e,t)=>bt(null,null,function*(){yield _o(),i&&!e&&be(t)&&(t.set(!1),i.focus())}),nc=(i,e,t,o=!1)=>bt(null,null,function*(){if(yield _o(),!!i&&e&&!o){let a=i.children[0];a==null||a.classList.toggle(mm,!t),a==null||a.focus()}}),mb=(i,e)=>bt(null,null,function*(){setTimeout(()=>{let t=i[e];!!t&&t.focus()},100)}),Ju=(i,e)=>{pb(i),gm(i.target),ub(i)&&(Or(i),e())},ep=(i,e)=>bt(null,null,function*(){oc(i,["ArrowRight"])&&(Or(i),e())}),vb=(i,e,t)=>bt(null,null,function*(){if(pb(i),Zy(i)){Or(i),e();return}ub(i)&&(Or(i),t())}),Yl=(i,e)=>{oc(i)&&(Or(i),e())},gb=(i,e,t)=>{if(oc(i))Or(i),t(!e);else{let o=i.code;if(o==="ArrowLeft"&&e){t(!1),Or(i);return}o==="ArrowRight"&&!e&&(t(!0),Or(i))}},hb=i=>{let e=i.getBoundingClientRect(),t=-14,o=e.left+e.width,r=e.top+t;return{right:o,bottom:r}},_b=i=>{if(!i)return{top:0,left:0};let e=i.getBoundingClientRect(),t=-58,o=8,r=e.left+o;return{bottom:e.bottom+t,left:r}};var Ga=require("@vkontakte/videoplayer-shared/es2015");var rs={"copy-link":100,"copy-link-timestamp":200,"copy-embed-code":300,pip:400,"video-loop":500,rotate:600,report:700,"save-debug":800,"save-trace":900,"debug-info":1e3};var hm=require("@vkontakte/videoplayer-shared/es2015");var e0=(i,e)=>{Yl(i,()=>e())},t0=L('<li class="item s-1j" role="menuitem" tabindex="0"> </li>'),i0={hash:"s-1j",code:".item.s-1j{color:hsla(0,0%,100%,.72);cursor:pointer;display:block;font-size:13px;letter-spacing:-.14px;line-height:18px;padding:8px 16px;position:relative;white-space:nowrap}.item.s-1j:hover{background:rgba(66,66,66,.5);color:var(--white)}"};function _m(i,e){B(e,!0),Q(i,i0);let t=h(e,"onClick",3,hm.noop),o=h(e,"closeContextMenu",3,hm.noop),r=d=>{d==null||d.stopPropagation(),t()(),o()()};var a=t0();a.__click=r,a.__keydown=[e0,r];var l=T(a,!0);S(a),N(()=>{var d;De(a,"aria-label",(d=e.ariaLabel)!=null?d:e.label),De(a,"data-testid",e.id),ge(l,e.label)}),$(i,a),H()}et(["click","keydown"]);var Qa=(i,e)=>i.weight-e.weight;var jl=(o=>(o.OPEN_SUB_MENU="OPEN_SUB_MENU",o.CLICK="CLICK",o.SWITCH="SWITCH",o))(jl||{});var o0=(i,e)=>{Ju(i,e)},n0=i=>{i.preventDefault()},r0=L('<ul role="menu" data-testid="context-menu" class="s-t"></ul>'),s0={hash:"s-t",code:"ul.s-t{background:rgba(0,0,0,.72);border-radius:8px;list-style:none;margin:0;max-height:100%;max-width:100%;overflow-x:hidden;overflow-y:auto;padding:6px 0;position:absolute;transition:visibility .1s,opacity .1s;z-index:var(--context-menu-z-index)}"};function bm(i,e){B(e,!0),Q(i,s0);let[t,o]=He(),r=()=>w(Te,"$playerPhase",t),a=()=>w(se,"$isLive$",t),l=()=>w(fe,"$isPiPEnabled$",t),d=()=>w(X,"$chromecastState$",t),s=()=>w(te,"$pictureInPictureApiIsActive$",t),u=()=>w(Z,"$isLooped$",t),m=()=>w(j,"$positionExact$",t),p=()=>w(W,"$additionalContextMenuItems$",t),v=h(e,"visible",3,!1),b=h(e,"position",19,()=>({top:0,left:0})),y=h(e,"playerContainerRef",3,void 0),_=h(e,"menuElementRef",15,void 0),x=K(0),I=K(0),C=$e(),{pictureInPicture$:R}=xo(),A=Dt(),P=C.ui.contextMenu.visible$,E=C.ui.debugPanelVisible,W=C.ui.additionalContextMenuItems$,F=C.ui.t,U=C.actions.internal.togglePictureInPicture,X=C.state.chromecastState$,se=C.state.isLive$,j=C.state.positionExact$,ne=C.state.isInteractive,Z=C.state.looped$,Te=C.playerPhase,{isEnabled$:fe,isActive$:te}=R,_e=f(()=>r()==="video"),Ce=f(()=>!!a()&&n(_e)),me=f(()=>["thumb","LiveWaitingStart","LiveWaitingRecover","LiveWaitingRecord"].includes(r())),ce=f(()=>{var ve;return A.features.copyVideoLink&&((ve=C.callbacks)==null?void 0:ve.onCopyVideoLink)}),Ye=f(()=>n(ce)&&!n(me)&&!ne&&!n(Ce)),G=f(()=>{var ve;return!!((ve=C.callbacks)!=null&&ve.onCopyEmbedCodeClicked)}),D=f(()=>l()&&d()!==tp.ChromecastState.CONNECTED&&!ne&&n(_e)&&!tp.clientChecker.browser.isFirefox),Xe=f(()=>!ne&&!n(me)&&!n(Ce)),re=f(()=>A.features.videoRotate&&!ne&&!n(me)),pe=f(()=>A.showSupport&&!s()),ue=f(()=>A.features.saveTraceInfoToFile),Ae=()=>{var ve;P.set(!1),(ve=e.returnFocus)==null||ve.call(e)},ze=(ve,Be)=>{if(!_()||!y())return;let qe=_().getBoundingClientRect(),ct=y().getBoundingClientRect();O(x,ve-ct.left),O(I,Be-ct.top),n(x)+qe.width>ct.width&&O(x,ct.width-qe.width),n(I)+qe.height>ct.height&&O(I,ct.height-qe.height),O(x,Math.max(n(x),0),!0),O(I,Math.max(n(I),0),!0)};Fe(()=>{bt(null,null,function*(){if(_()&&y()){yield _o();let{top:Be,left:qe,bottom:ct,right:Xt}=b(),Mt=qe!=null?qe:0,di=Be!=null?Be:0,ci=_().getBoundingClientRect();(0,Ga.isNullable)(qe)&&!(0,Ga.isNullable)(Xt)&&(Mt=Xt-ci.width),(0,Ga.isNullable)(Be)&&!(0,Ga.isNullable)(ct)&&(di=ct-ci.height),Mt=Math.max(Mt,0),di=Math.max(di,0),ze(Mt,di)}})});let ee=()=>{C.actions.internal.videoRotate()},de=()=>{(0,Ga.isValidURL)(e.supportLink)&&window.open(e.supportLink,"_blank"),C.actions.internal.reportProblem(),C.actions.internal.pause()},ke=()=>{let ve=C.actions.internal.getDebugTextData();if(A.features.saveDebugInfoToFile){let Be=new Blob([...ve],{type:"plain/text"}),qe=window.URL.createObjectURL(Be);za(qe,"vk_player_debug_info","txt")}else Ql(C.actions.internal.getDebugTextData())},xe=()=>{let ve=C.actions.internal.getTraceTextData(),Be=new Blob([...ve],{type:"application/json"}),qe=window.URL.createObjectURL(Be);za(qe,"vk_player_trace_info","json")},Je=()=>{E.set(!0)},Pe=()=>bt(null,null,function*(){var ve;try{U()}finally{(ve=e.returnFocus)==null||ve.call(e)}}),we=()=>{C.actions.internal.setLooped(!u())},Ne=()=>{var ve,Be;if(n(G)){let qe=(Be=(ve=C.callbacks)==null?void 0:ve.onCopyEmbedCodeClicked)==null?void 0:Be.call(ve);qe&&Ql(qe)}},Pt=(ve=!1)=>{var Be,qe;if((Be=C.callbacks)!=null&&Be.onCopyVideoLink){let ct=(qe=C.callbacks)==null?void 0:qe.onCopyVideoLink(ve,m());ct&&Ql(ct)}},kt=f(()=>A.features.saveDebugInfoToFile?F("menu_save_debug"):F("menu_copy_debug")),Lt=f(()=>n(ce)?{id:"copy-link",weight:rs["copy-link"],label:F("menu_copy_video_link"),onClick:()=>Pt()}:void 0),pt=f(()=>n(Ye)?{id:"copy-link-timestamp",weight:rs["copy-link-timestamp"],label:F("menu_copy_video_link_with_timestamp"),onClick:()=>Pt(!0)}:void 0),It=f(()=>n(G)?{id:"copy-embed-code",weight:rs["copy-embed-code"],label:F("menu_copy_embed_code"),onClick:Ne}:void 0),ei=f(()=>n(D)?{id:"pip",weight:rs.pip,label:s()?F("menu_pip_close"):F("menu_pip"),onClick:Pe}:void 0),Ft=f(()=>n(Xe)?{id:"video-loop",weight:rs["video-loop"],label:u()?F("menu_video_loop_off"):F("menu_video_loop_on"),ariaLabel:F("aria_label_menu_loop"),onClick:we}:void 0),Bt=f(()=>n(re)?{id:"rotate",weight:rs.rotate,label:F("menu_video_rotate"),ariaLabel:F("aria_label_menu_rotate"),onClick:ee}:void 0),qt=f(()=>n(pe)?{id:"report",weight:rs.report,label:F("menu_report"),ariaLabel:`${F("menu_report")}. ${F("aria_label_new_tab_alert")}`,onClick:de}:void 0),q=f(()=>({id:"save-debug",weight:rs["save-debug"],label:n(kt),onClick:ke})),Le=f(()=>n(ue)?{id:"save-trace",weight:rs["save-trace"],label:F("menu_save_debug"),onClick:xe}:void 0),Me=f(()=>({id:"debug-info",weight:rs["debug-info"],label:F("menu_debug_overlay"),ariaLabel:F("aria_label_menu_debug_overlay"),onClick:Je})),ye=f(()=>[n(Lt),n(pt),n(It),n(ei),n(Ft),n(Bt),n(qt),n(q),n(Le),n(Me),...p()].filter(ve=>!!ve).sort(Qa));var Ue=Oe(),Se=le(Ue);{var Tt=ve=>{var Be=r0();Be.__contextmenu=[n0],Be.__keydown=[o0,Ae],xi(Be,21,()=>n(ye),qe=>qe.id,(qe,ct)=>{_m(qe,{get id(){return n(ct).id},get label(){return n(ct).label},get ariaLabel(){return n(ct).ariaLabel},get onClick(){return n(ct).onClick},closeContextMenu:Ae})}),S(Be),it(Be,qe=>_(qe),()=>_()),N(()=>{var qe,ct;return Qe(Be,`top: ${(qe=n(I))!=null?qe:""}px; left: ${(ct=n(x))!=null?ct:""}px;`)}),$(ve,Be)};V(Se,ve=>{v()&&ve(Tt)})}$(i,Ue),H(),o()}et(["contextmenu","keydown"]);var ip=class{constructor(e){this.value=e,this.next=null}};var Xl=class{constructor(e){this.top=null,this.bottom=null,this.size=0,this.maxSize=e}push(e){let t=new ip(e);this.top?(this.top.next=t,this.top=t):(this.top=t,this.bottom=t),this.size++,this.size>this.maxSize&&this.bottom&&(this.bottom=this.bottom.next)}getValuesFromBottom(){let e=[],t=this.bottom;for(;t;)e.push(t.value),t=t.next;return e}};var a0=L('<div class="container s-1f"><canvas class="s-1f"></canvas></div>'),l0={hash:"s-1f",code:".container.s-1f{display:inline-block;height:16px;width:120px}canvas.s-1f{margin-top:2px;transform:scaleY(-1)}"};function rc(i,e){B(e,!0),Q(i,l0);let t=h(e,"values",19,()=>[]),o=K(void 0),r=K(null),a=16,l=120,d=60,s=l/d;Ot(()=>{n(o).width=l,n(o).height=a,O(r,n(o).getContext("2d"),!0)});function u(v,b,y,_,x){x===0&&(x=1),v.fillStyle="#fff",v.fillRect(b,y,_,x)}Fe(()=>{let v="";if(n(r)){let b=t()[0];for(let _=1;_<t().length;_++)t()[_]>b&&(b=t()[_]);n(r).clearRect(0,0,l,a);let y=d-1;for(let _=t().length-1;_>=0;_--){let x=y*s,I=b>0?a*(t()[_]/b):0;u(n(r),x,0,s,I),v=I+" "+v,y--}}});var m=a0(),p=T(m);it(p,v=>O(o,v),()=>n(o)),S(m),$(i,m),H()}var $m=require("@vkontakte/videoplayer-shared/es2015");var d0=(i,e)=>{i.stopPropagation(),$m.safeStorage.remove(Kd),e.set(!1)},c0=L('<div class="s-q"><div class="s-q">Video id</div> <span> </span></div>'),u0=L('<div class="s-q"><div class="s-q">VSID</div> <span> </span></div>'),p0=L('<div class="s-q"><div class="s-q">Provider</div> <span> </span></div>'),f0=L('<div class="s-q"><div class="s-q">Streams</div> <span> </span></div>'),m0=L('<div class="s-q"><div class="s-q">Viewport</div> <span> </span></div>'),v0=L('<div class="s-q"><div class="s-q">Video size</div> <span> </span></div>'),g0=L('<div class="s-q"><div class="s-q">CDN host</div> <span> </span></div>'),h0=L('<div class="s-q"><div class="s-q">Volume</div> <span> </span></div>'),_0=L('<div class="s-q"><div class="s-q">Position</div> <span> </span></div>'),b0=L('<div class="s-q"><div class="s-q">Buffer</div> <span> </span></div>'),$0=L('<div class="s-q"><div class="s-q">Nbuffer</div> <span> </span></div>'),y0=L('<div class="s-q"><div class="s-q">Live latency</div> <span> </span></div>'),x0=L('<div class="s-q"><div class="s-q">Segment</div> <span> </span></div>'),w0=L('<div class="s-q"><div class="s-q">Network</div> <!> <span> </span></div>'),S0=L('<div class="s-q"><div class="s-q">V bitrate</div> <!> <span> </span></div>'),C0=L('<div role="region"><button class="close s-q" title="закрыть">[x]</button> <div class="content s-q"><div class="s-q"><div class="s-q">Version</div> <span> </span></div> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <div class="s-q"><div class="s-q">Dropped</div> <span> </span></div> <!> <!> <div class="s-q"><div class="s-q">FPS</div> <!> <span> </span></div></div></div>'),T0={hash:"s-q",code:".container.s-q{background:rgba(28,28,28,.8);border-radius:4px;color:#fff;font-size:10px;left:20px;min-width:160px;position:absolute;text-align:left;top:45px;user-select:text;z-index:var(--debug-panel-z-index)}.container-mobile.s-q{left:16px;top:16px}button.close.s-q{background-color:transparent;border:none;color:#fff;cursor:pointer;outline:0;padding:0;position:absolute;right:5px;top:3px}.content.s-q{padding:5px}.content.s-q>div:where(.s-q)>div:where(.s-q){display:inline-block;padding:0 5px;text-align:right;width:60px}"};function sc(i,e){B(e,!0),Q(i,T0);let[t,o]=He(),r=()=>w(d,"$isMobile",t),a=$e(),l=a.ui.debugPanelVisible,d=a.ui.isMobile,s=K(li(a.actions.internal.getDebugPanelData())),u=a.actions.internal.getVideoElement(),m=K(0),p=K(0),v=K(0),b=new Xl(60),y=new Xl(60),_=new Xl(60),x=K(li([])),I=K(li([])),C=K(li([])),R=Y("aria_label_debug_panel");Ot(()=>{$m.safeStorage.set(Kd,"true"),a.actions.internal.startLogging(),u&&(O(p,u.getVideoPlaybackQuality().droppedVideoFrames,!0),O(m,u.getVideoPlaybackQuality().totalVideoFrames,!0));let q=window.setInterval(()=>{O(s,a.actions.internal.getDebugPanelData(),!0)},500),Le;return u&&(Le=window.setInterval(()=>{if(u){O(p,u.getVideoPlaybackQuality().droppedVideoFrames,!0);let Me=u.getVideoPlaybackQuality().totalVideoFrames;O(v,Me-n(m)),O(m,Me,!0),b.push(n(v)),n(s).speed&&y.push(n(s).speed),n(s).bitrate&&_.push(n(s).bitrate),O(x,b.getValuesFromBottom(),!0),O(I,y.getValuesFromBottom(),!0),O(C,_.getValuesFromBottom(),!0)}},1e3)),()=>{a.actions.internal.stopLogging(),clearInterval(q),Le&&clearInterval(Le)}});var A=C0();let P;var E=T(A);E.__click=[d0,l];var W=k(E,2),F=T(W),U=k(T(F),2),X=T(U,!0);S(U),S(F);var se=k(F,2);{var j=q=>{var Le=c0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(()=>ge(ye,n(s).id)),$(q,Le)};V(se,q=>{n(s).id&&q(j)})}var ne=k(se,2);{var Z=q=>{var Le=u0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(()=>ge(ye,n(s).vsid)),$(q,Le)};V(ne,q=>{n(s).vsid&&q(Z)})}var Te=k(ne,2);{var fe=q=>{var Le=p0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(()=>ge(ye,n(s).provider)),$(q,Le)};V(Te,q=>{n(s).provider&&q(fe)})}var te=k(Te,2);{var _e=q=>{var Le=f0(),Me=k(T(Le),2),ye=T(Me);S(Me),S(Le),N(()=>{var Ue,Se;return ge(ye,`Video: ${(Ue=n(s).videoCodec||"")!=null?Ue:""} ${n(s).hdr?"(HDR)":""}
|
|
57
57
|
&
|
|
58
|
-
Audio: ${(dt=n(s).audioCodec||"")!=null?dt:""} ${n(s).audioLanguage?`(${n(s).audioLanguage})`:""}`)}),$(Y,Pe)};V(ee,Y=>{(n(s).videoCodec||n(s).audioCodec)&&Y(_e)})}var Ce=k(ee,2);{var ge=Y=>{var Pe=f0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(()=>ve($e,n(s).viewport)),$(Y,Pe)};V(Ce,Y=>{n(s).viewport&&Y(ge)})}var pe=k(Ce,2);{var Qe=Y=>{var Pe=m0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(()=>ve($e,n(s).videoSize)),$(Y,Pe)};V(pe,Y=>{n(s).videoSize&&Y(Qe)})}var G=k(pe,2);{var D=Y=>{var Pe=v0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(()=>ve($e,n(s).cdn)),$(Y,Pe)};V(G,Y=>{n(s).cdn&&Y(D)})}var Ge=k(G,2);{var K=Y=>{var Pe=g0(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),O(()=>{var Ve;return ve($e,`${(Ve=n(s).volume)!=null?Ve:""} %`)}),$(Y,Pe)};V(Ge,Y=>{n(s).volume&&Y(K)})}var se=k(Ge,2);{var xe=Y=>{var Pe=h0(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),O(Ve=>ve($e,`${Ve!=null?Ve:""} s`),[()=>n(s).position.toFixed(2)]),$(Y,Pe)};V(se,Y=>{n(s).position&&Y(xe)})}var He=k(se,2);{var it=Y=>{var Pe=_0(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),O(Ve=>ve($e,`${Ve!=null?Ve:""} s`),[()=>n(s).buffer.toFixed(2)]),$(Y,Pe)};V(He,Y=>{n(s).buffer&&Y(it)})}var ne=k(He,2);{var ce=Y=>{var Pe=b0(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),O(Ve=>ve($e,`${Ve!=null?Ve:""} s`),[()=>n(s).nativeBuffer.toFixed(2)]),$(Y,Pe)};V(ne,Y=>{n(s).nativeBuffer&&Y(ce)})}var Ne=k(ne,2);{var Le=Y=>{var Pe=$0(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),O(Ve=>ve($e,`${Ve!=null?Ve:""} s`),[()=>n(s).liveLatency.toFixed(2)]),$(Y,Pe)};V(Ne,Y=>{n(s).liveLatency&&Y(Le)})}var et=k(Ne,2);{var Ee=Y=>{var Pe=y0(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),O(Ve=>ve($e,Ve),[()=>[{value:n(s).currentVideoSegmentLength,title:"Video:"},{value:n(s).currentAudioSegmentLength,title:"Audio:"}].filter(({value:Ve})=>Ve).map(({value:Ve,title:dt})=>`${dt} ${((Ve!=null?Ve:0)/1e3).toFixed(2)} s`).join(" & ")]),$(Y,Pe)};V(et,Y=>{(n(s).currentVideoSegmentLength||n(s).currentAudioSegmentLength)&&Y(Ee)})}var Te=k(et,2),Fe=k(C(Te),2),kt=C(Fe);S(Fe),S(Te);var Tt=k(Te,2);{var Vt=Y=>{var Pe=x0(),le=k(C(Pe),2);ac(le,{get values(){return n(I)}});var $e=k(le,2),Ve=C($e);S($e),S(Pe),O(dt=>ve(Ve,`${dt!=null?dt:""} Kbps`),[()=>n(s).speed.toFixed(2)]),$(Y,Pe)};V(Tt,Y=>{n(s).speed&&Y(Vt)})}var pt=k(Tt,2);{var At=Y=>{var Pe=w0(),le=k(C(Pe),2);ac(le,{get values(){return n(T)}});var $e=k(le,2),Ve=C($e);S($e),S(Pe),O(dt=>ve(Ve,`${dt!=null?dt:""} Kbps`),[()=>n(s).bitrate.toFixed(2)]),$(Y,Pe)};V(pt,Y=>{n(s).bitrate&&Y(At)})}var ti=k(pt,2),Lt=k(C(ti),2);ac(Lt,{get values(){return n(x)}});var Ft=k(Lt,2),qt=C(Ft,!0);S(Ft),S(ti),S(z),S(A),O(Y=>{var Pe,le;P=oe(A,1,"container s-h",null,P,Y),Re(A,"aria-label",R),ve(X,n(s).version),ve(kt,`${(Pe=n(p))!=null?Pe:""} / ${(le=n(m))!=null?le:""} frames`),ve(qt,n(v))},[()=>({"container-mobile":r()})]),$(i,A),H(),o()}Ye(["click"]);var $b=require("@vkontakte/videoplayer-shared/es2015"),T0=(i,e)=>{i.stopPropagation(),e()()},I0=L('<div class="close s-16"></div>'),E0={hash:"s-16",code:'.close.s-16{cursor:pointer;height:16px;opacity:.8;position:relative;transition:opacity .2s;width:16px}.close.s-16:hover{opacity:1}.close.s-16:after,.close.s-16:before{background-color:var(--white);content:" ";height:16px;left:8px;position:absolute;width:2px}.close.s-16:before{transform:rotate(45deg)}.close.s-16:after{transform:rotate(-45deg)}'};function Hs(i,e){B(e,!0),Q(i,E0);let t=h(e,"onClick",3,$b.noop);var o=I0();o.__click=[T0,t],$(i,o),H()}Ye(["click"]);var yb=require("@vkontakte/videoplayer-shared/es2015");var fn=i=>`width:${i}px;height:${i}px;`;var P0=Ie('<path d="m14.4 8.76 24.02 13.85a1.6 1.6 0 0 1 0 2.78L14.4 39.24a1.6 1.6 0 0 1-2.4-1.39v-27.7a1.6 1.6 0 0 1 2.4-1.39"></path>');function Dn(i,e){B(e,!0);let t=f(()=>fn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(t)},testId:"play-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=P0();$(o,a)},$$slots:{default:!0}}),H()}var k0=L('<div class="timer s-17"><canvas class="timer-canvas s-17" width="100" height="100"></canvas> <!></div>'),A0={hash:"s-17",code:".timer.s-17{align-items:center;background:rgba(31,31,31,.65);border-radius:50%;display:flex;height:50px;justify-content:space-around;transition:background .2s;width:50px}.timer.s-17:hover{background:rgba(31,31,31,.85)}.timer-canvas.s-17{height:50px;position:absolute;width:50px}"};function dc(i,e){B(e,!0),Q(i,A0);let t=h(e,"isRunning",3,!0),o=h(e,"onTimerEnded",3,yb.noop),r=5e3,a=q(void 0),l,d,s=0,u;Oe(()=>{t()&&Pt(()=>{d=Date.now(),s=requestAnimationFrame(p)})});let m=()=>{s&&(cancelAnimationFrame(s),s=0)},p=()=>{m(),t()&&(u=(Date.now()-d)/r,u<1?(l==null||l.clearRect(0,0,100,100),l==null||l.beginPath(),l==null||l.arc(50,50,47,-Math.PI/2,-Math.PI/2+Math.PI*2*u),l==null||l.stroke(),s=requestAnimationFrame(p)):o()())};Dt(()=>{l=n(a).getContext("2d"),l&&(l.lineWidth=6,l.lineCap="round",l.strokeStyle="#fff")}),pn(()=>{m()});var v=k0(),b=C(v);Xe(b,_=>N(a,_),()=>n(a));var y=k(b,2);Dn(y,{get size(){return"24"}}),S(v),$(i,v),H()}var L0=(i,e,t)=>{e(!1),t()},M0=L('<div class="overlay s-w"></div> <div class="next-video s-w"><div class="top s-w"><div class="caption s-w"> </div> <!></div> <div class="row s-w"><div class="column s-w"><div class="thumb s-w"><div></div> <!></div></div> <div class="column s-w"><div class="title s-w"> </div></div></div></div>',1),V0={hash:"s-w",code:".overlay.s-w{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-w{display:flex;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:362px}.top.s-w{display:flex;justify-content:space-between}.caption.s-w{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-w{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-w{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-w{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-w,.thumb-overlay.s-w{height:100%;width:100%}.thumb-overlay.s-w{position:absolute}.thumb-overlay.withOpacity.s-w{background:var(--black);opacity:.3}.title.s-w{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function wm(i,e){B(e,!0),Q(i,V0);let[t,o]=De(),r=()=>w(d,"$autoplayNextEnabled$",t),a=()=>w(s,"$timerNextVideoRunning$",t),l=be(),d=l.ui.autoplayNextEnabled$,s=l.ui.timerNextVideoRunning$,u=l.actions.internal.nextVideoClick,m=l.actions.internal.nextVideoAnnouncementShow,p=l.actions.internal.nextVideoAnnouncementClick,v=l.actions.internal.nextVideoAnnouncementAuto,b=l.actions.internal.nextVideoAnnouncementCancel,y=()=>{r()&&(u(!1),v())},_=()=>{e.clickCloseIcon(),b()};Dt(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Me(),I=ue(x);{var T=R=>{var A=M0(),P=k(ue(A),2),E=C(P),z=C(E),F=C(z,!0);S(z);var U=k(z,2);Hs(U,{onClick:_}),S(E);var X=k(E,2);X.__click=[L0,u,p];var ae=C(X),Z=C(ae),re=C(Z);let J;var we=k(re,2);{var me=ge=>{let pe=f(()=>a()&&r());dc(ge,{get isRunning(){return n(pe)},onTimerEnded:y})};V(we,ge=>{r()&&ge(me)})}S(Z),S(ae);var ee=k(ae,2),_e=C(ee),Ce=C(_e,!0);S(_e),S(ee),S(X),S(P),O((ge,pe)=>{ve(F,ge),qe(Z,`background-image: url('${e.thumb}')`),J=oe(re,1,"thumb-overlay s-w",null,J,pe),ve(Ce,e.title)},[()=>j("end_screen_next_video"),()=>({withOpacity:r()})]),$(R,A)};V(I,R=>{e.isHide||R(T)})}$(i,x),H(),o()}Ye(["click"]);var va=require("@vkontakte/videoplayer-core/es2015"),xb=require("@vkontakte/videoplayer-shared/es2015"),On=require("@vkontakte/videoplayer-statistics/es2015");var Sm=(i,e)=>Math.min(+(i+e).toFixed(2),1),Cm=(i,e)=>Math.max(+(i-e).toFixed(2),0),rp=(i,e,t)=>{let o=Sm(e,t);e<1&&i.actions.internal.setVolume(o)},sp=(i,e,t)=>{let o=Cm(e,t);e>0&&i.actions.internal.setVolume(o)};var ma=({isAudioDisabled:i,isAudioAvailable:e,isAds:t,audioDisabledHintCallback:o,audioIsNotExistHintCallback:r})=>i?t?!0:(o==null||o(),!1):e?!0:(r==null||r(),!1);function ap(){var i,e,t;return(t=(e=(i=document.activeElement)==null?void 0:i.shadowRoot)==null?void 0:e.activeElement)!=null?t:null}var N0=(i,e)=>{e(i)},D0=L('<div class="keyboard-controls s-14" tabindex="-1" role="region"><!></div>'),O0={hash:"s-14",code:".keyboard-controls.s-14{bottom:0;left:0;position:absolute;right:0;top:0}"};function Tm(i,e){var Y,Pe;B(e,!0),Q(i,O0);let[t,o]=De(),r=()=>w(we,"$disabledControls$",t),a=()=>w(it,"$isInteractiveTime$",t),l=()=>w(ne,"$showInteractiveTimeIndicatorTooltip$",t),d=()=>w(U,"$playbackState$",t),s=()=>w(D,"$isEnded$",t),u=()=>w(Qe,"$doubleForwardAvailable$",t),m=()=>w(pe,"$doubleForwardOn$",t),p=()=>w(Ge,"$overlayContainer$",t),v=()=>w(ae,"$adPlaybackState",t),b=()=>w(Z,"$positionExact$",t),y=()=>w(re,"$duration$",t),_=()=>w(xe,"$isAudioAvailable$",t),x=()=>w(J,"$volume$",t),I=()=>w(X,"$canChangePlaybackSpeed$",t),T=()=>w(me,"$muted$",t),R=()=>w(ee,"$currentSubtitle$",t),A=h(e,"nextButtonActive",3,!1),P=h(e,"prevButtonActive",3,!1),E=be(),z=Ot(),F=E.getLogger().createComponentLog("KeyboardControls component"),U=E.state.playbackState$,X=E.state.canChangePlaybackSpeed$,ae=E.ads.playbackState,Z=E.state.positionExact$,re=E.state.duration$,J=E.state.volume$,we=E.ui.controls.disabledControls$,me=E.state.muted$,ee=E.state.currentSubtitle$,_e=E.ui.contextMenu.openedByHotKey$,Ce=E.ui.contextMenu.lastActiveElem$,ge=E.ui.contextMenu.visible$,pe=E.ui.doubleForwardOn$,Qe=E.ui.doubleForwardAvailable$,G=E.ui.contextMenu.position$,D=E.state.isEnded$,Ge=E.ui.overlayContainer$,K=(Y=E.callbacks)==null?void 0:Y.onAudioDoesNotExistHint,se=(Pe=E.callbacks)==null?void 0:Pe.onAudioDisabledHint,xe=E.state.isAudioAvailable$,He=E.state.isAudioDisabled,it=E.state.isInteractiveTime$,{showInteractiveTimeIndicatorTooltip$:ne}=yo(),ce=0,Ne=!0,Le=q(void 0),et=le=>(le!==Ne&&(Ne=le,ce=0),ce+=1,(z.controls.seekStepKeyboard+z.controls.seekStepKeyboard*ce)/1e3),Ee=!0,Te=({type:le,repeat:$e,disableDoubleForward:Ve})=>{let dt=()=>{if(!r().has("PLAY_BUTTON"))if(a()&&l()&&ne.set(!1),e.fakePlayButtonHandler)e.fakePlayButtonHandler();else{E.actions.internal.togglePlay();let fe="PLAY";d()===va.PlaybackState.PAUSED?fe="PAUSE":s()&&(fe="REPLAY"),e.showHotKeyHelpers({type:fe})}},St=le==="down";if(!u()||Ve){St&&dt(),Ee=!0;return}if(St)Ee=!1;else if(Ee)return;if(St){!$e&&e.startDoubleForwardActivationTimer();return}m()||dt(),e.stopDoubleForward(),Ee=!0},Fe=le=>{let $e=bb(p());G.set($e),Ce.set(le.target),_e.set(!0),ge.set(!0)},kt=(le,$e=!1)=>{var _o,vi;let Ve=le.target,dt=(_o=Ve==null?void 0:Ve.getAttribute("role"))==null?void 0:_o.includes("menuitem"),St=Ve.classList.contains("btn"),fe=le.code;if(St&&fe==="Space")return!1;let Be=$_.has(fe);if(dt&&Be)return!1;let We=!b_.has(fe);if(le.ctrlKey&&We||le.altKey&&We||le.metaKey)return!1;let Ct=dt&&fe==="Escape";y_.has(fe)||Ct||e.hideContextMenu();let Xt=d()===va.PlaybackState.PLAYING||d()===va.PlaybackState.PAUSED,It=e.isAds&&(v()==="paused"||v()==="playing"),ai=!It&&!r().has("TIMELINE"),fi=le.shiftKey&&["Digit1","Numpad1"].includes(fe);if(!fi&&!(Xt||It))return!1;F({message:`key down, code: ${fe}, isExternal = ${$e}`});let Bi=!1,Bt=()=>{Bi=!0,$e||le.preventDefault()};if(fi)return Fe(le),Bt(),!0;switch(fe){case"KeyJ":case"ArrowLeft":{if(!ai)break;if(le.ctrlKey||le.altKey){let ot=E.actions.internal.getPrevEpisode();E.actions.internal.seekToPrevEpisode(ot),ot&&e.showHotKeyHelpers({type:"EPISODE_PREV",text:ot.text}),Bt()}else{let ot=le.shiftKey?et(!1):z.controls.seekStepKeyboard/1e3,Jt=Math.max(b()-ot,0);b()>0&&(E.actions.internal.seekTime(Jt,On.SeekAction.DOUBLE_TAP),e.showHotKeyHelpers({type:"BACKWARD_SEEK",text:ot.toString()}),Bt())}break}case"KeyL":case"ArrowRight":{if(!ai)break;if(le.ctrlKey||le.altKey){let ot=E.actions.internal.getNextEpisode();E.actions.internal.seekToNextEpisode(ot),ot&&e.showHotKeyHelpers({type:"EPISODE_NEXT",text:ot.text}),Bt()}else{let ot=le.shiftKey?et(!0):z.controls.seekStepKeyboard/1e3,Jt=Math.min(b()+ot,y());Math.round(b())<Math.round(y())&&(E.actions.internal.seekTime(Jt,On.SeekAction.DOUBLE_TAP),e.showHotKeyHelpers({type:"FORWARD_SEEK",text:ot.toString()}),Bt())}break}case"ArrowUp":{if(ma({isAudioDisabled:He,audioDisabledHintCallback:se,isAudioAvailable:_(),audioIsNotExistHintCallback:K,isAds:e.isAds})){let ot=x(),Jt=z.controls.volumeStepKeyboard,Hi=ot<=1;if(rp(E,ot,Jt),Hi){let xi=Math.round(Sm(ot,Jt)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:xi}})}}Bt();break}case"ArrowDown":{if(ma({isAudioDisabled:He,audioDisabledHintCallback:se,isAudioAvailable:_(),audioIsNotExistHintCallback:K,isAds:e.isAds})){let ot=x(),Jt=z.controls.volumeStepKeyboard,Hi=ot>=0;if(sp(E,ot,Jt),Hi){let xi=Math.round(Cm(ot,Jt)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:xi}})}}Bt();break}case"Comma":{if(le.shiftKey){if(!m()&&I()){let ot=E.actions.internal.decrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_DOWN",text:ot==null?void 0:ot.displayValue}),Bt()}}else{if(It||d()!==va.PlaybackState.PAUSED)break;let ot=Math.max(b()-z.controls.seekStepFrame/1e3,0);b()>0&&(e.showHotKeyHelpers({type:"BACKWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(ot,On.SeekAction.DOUBLE_TAP),Bt())}break}case"Period":{if(le.shiftKey){if(!m()&&I()){let ot=E.actions.internal.incrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_UP",text:ot==null?void 0:ot.displayValue}),Bt()}}else{if(It||d()!==va.PlaybackState.PAUSED)break;let ot=Math.min(b()+z.controls.seekStepFrame/1e3,y());b()<y()&&(e.showHotKeyHelpers({type:"FORWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(ot,On.SeekAction.DOUBLE_TAP),Bt())}break}case"KeyK":case"Space":Te({type:"down",repeat:le.repeat,disableDoubleForward:"KeyK"===fe}),Bt();break;case"KeyM":{ma({isAudioDisabled:He,audioDisabledHintCallback:se,isAudioAvailable:_(),audioIsNotExistHintCallback:K,isAds:e.isAds})&&(e.showHotKeyHelpers({type:T()?"VOLUME":"MUTE"}),E.actions.internal.toggleMuted()),Bt();break}case"KeyF":e.toggleFullscreen(),Bt();break;case"KeyC":E.actions.internal.toggleSubtitle(),R().value!=="off"?e.showHotKeyHelpers({type:"SUBTITLES_ON",text:(vi=R())==null?void 0:vi.displayValue}):e.showHotKeyHelpers({type:"SUBTITLES_OFF"}),Bt();break;case"KeyI":E.actions.internal.togglePictureInPicture(),Bt();break;case"Digit1":case"Numpad1":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.1,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit2":case"Numpad2":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.2,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit3":case"Numpad3":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.3,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit4":case"Numpad4":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.4,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit5":case"Numpad5":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.5,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit6":case"Numpad6":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.6,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit7":case"Numpad7":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.7,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit8":case"Numpad8":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.8,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit9":case"Numpad9":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.9,On.SeekAction.DOUBLE_TAP),Bt();break;case"Digit0":case"Numpad0":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(0,On.SeekAction.DOUBLE_TAP),Bt();break;case"Slash":{le.shiftKey&&z.features.hotKeyMapModal&&(e.showKeyMap(),Bt());break}case"KeyN":le.shiftKey&&A()&&(E.actions.internal.nextVideoClick(),Bt());break;case"KeyP":le.shiftKey&&P()&&(E.actions.internal.prevVideoClick(),Bt());break;case"ShiftLeft":case"ShiftRight":Bt();break;case"Tab":case"Escape":case"Enter":break;default:(0,xb.checkNever)(fe);break}return Bi},Tt=le=>{let $e=le.code;if(le.ctrlKey||le.altKey||le.metaKey)return;let Ve=d()===va.PlaybackState.PLAYING||d()===va.PlaybackState.PAUSED,dt=e.isAds&&(v()==="paused"||v()==="playing");if(Ve||dt)switch($e){case"ShiftLeft":case"ShiftRight":ce=0;break;case"Space":Te({type:"up"});break}},Vt=j("aria_label_video_player"),pt=()=>{var le;return(le=n(Le))==null?void 0:le.focus()},At=()=>n(Le)===ap(),ti=le=>le.type==="keydown"?kt(le,!0):(le.type==="keyup"&&Tt(le),!1);var Lt=D0();Lt.__keyup=Tt,Lt.__keydown=[N0,kt];var Ft=C(Lt);ri(Ft,()=>{var le;return(le=e.children)!=null?le:_t}),S(Lt),Xe(Lt,le=>N(Le,le),()=>n(Le)),O(()=>Re(Lt,"aria-label",Vt)),$(i,Lt);var qt=H({focus:pt,isFocused:At,handleExternalKeyboardEvent:ti});return o(),qt}Ye(["keyup","keydown"]);var B0=L('<div class="container s-k"><div class="dot s-k"></div> <div class="dot s-k"></div> <div class="dot s-k"></div></div>'),H0={hash:"s-k",code:".container.s-k{display:flex;left:50%;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%)}.dot.s-k:first-child{animation-delay:0s}.dot.s-k:nth-child(2){animation-delay:.18s}.dot.s-k:nth-child(3){animation-delay:.36s}@keyframes s-k-dot_animation{0%{opacity:.2}30%{opacity:1}to{opacity:.2}}.dot.s-k{animation-duration:.75s;animation-iteration-count:infinite;animation-name:s-k-dot_animation;background:var(--btn-color);border-radius:4px;height:8px;width:8px}.dot.s-k+.dot:where(.s-k){margin-left:4px}"};function Xa(i,e){Q(i,H0);let t=h(e,"style",3,"");var o=B0();O(()=>qe(o,t())),$(i,o)}var F0=Ie('<path d="M5.26 5.26a.9.9 0 0 1 1.28 0L12 10.73l5.46-5.47a.9.9 0 0 1 1.28 1.28L13.27 12l5.47 5.46a.9.9 0 1 1-1.28 1.28L12 13.27l-5.46 5.47a.9.9 0 1 1-1.28-1.28L10.73 12 5.26 6.54a.9.9 0 0 1 0-1.28Z"></path>');function Im(i,e){Ze(i,{get fill(){return e.fill},children:(t,o)=>{var r=F0();$(t,r)},$$slots:{default:!0}})}var Za=require("@vkontakte/videoplayer-shared/es2015"),U0=i=>{i.stopPropagation()},z0=L("<button><!></button>"),W0={hash:"s-1o",code:"button.btn.s-1o{align-items:center;display:flex;flex-direction:row;height:var(--controls-height);justify-content:center;margin:0;padding:8px;will-change:opacity}button.w-max.s-1o{width:100%}button.btn--live.s-1o{padding:10px 4px}button.btn-jc-l.s-1o{justify-content:left}button.btn-m.s-1o{background-color:rgba(0,0,0,.56);border-radius:12px;height:44px;left:12px;position:absolute;top:50%;transform:translateY(-50%);transition:opacity var(--controls-transition-duration);width:44px}button.btn-m.s-1o,button.btn-m--play.s-1o{align-items:center;display:flex;justify-content:center}button.btn-m--play.s-1o{height:var(--big-play-size);padding:16px;position:relative;width:var(--big-play-size)}button.btn-m--next.s-1o,button.btn-m--prev.s-1o{height:50px;position:absolute;width:50px}button.btn-m--prev.s-1o{right:calc(100% + 35px)}button.btn-m--next.s-1o{left:calc(100% + 35px)}button.btn.s-1o:disabled{cursor:default;pointer-events:none}button.btn.s-1o:not(.btn-full-opacity):disabled{opacity:.4}button.btn.s-1o:not(:disabled):hover{opacity:.8}button.pr-0.s-1o{padding-right:0}button.pl-0.s-1o{padding-left:0}"};function Kt(i,e){B(e,!0),Q(i,W0);let t=h(e,"className",3,""),o=h(e,"style",3,""),r=h(e,"disabled",3,void 0),a=h(e,"testId",3,void 0),l=h(e,"ariaHidden",3,void 0),d=h(e,"ariaLabel",3,void 0),s=h(e,"ref",15,void 0),u=h(e,"ariaKeyShortCut",3,void 0),m=h(e,"ariaExpanded",3,void 0),p=h(e,"tabIndex",3,0),v=h(e,"click",3,Za.noop),b=h(e,"focus",3,Za.noop),y=h(e,"blur",3,Za.noop),_=f(()=>v()===Za.noop?null:A=>{A.stopPropagation(),v()(A)}),x=f(()=>b()===Za.noop?null:A=>{A.preventDefault(),b()()}),I=f(()=>y()===Za.noop?null:A=>{A.preventDefault(),y()()});var T=z0();T.__pointerdown=[U0],T.__click=function(...A){var P;(P=n(_))==null||P.apply(this,A)};var R=C(T);ri(R,()=>{var A;return(A=e.children)!=null?A:_t}),S(T),Xe(T,A=>s(A),()=>s()),O(()=>{var A,P,E,z,F,U,X,ae;oe(T,1,`btn ${(A=t())!=null?A:""}`,"s-1o"),qe(T,o()||null),T.disabled=(P=r())!=null?P:null,Re(T,"aria-hidden",(E=l())!=null?E:null),Re(T,"aria-label",(z=d())!=null?z:null),Re(T,"aria-keyshortcuts",(F=u())!=null?F:null),Re(T,"aria-expanded",(U=m())!=null?U:null),Re(T,"data-testid",(X=a())!=null?X:null),Re(T,"tabindex",p()),Re(T,"role",e.role),Re(T,"aria-checked",(ae=e.areaChecked)!=null?ae:null)}),ut("focus",T,function(...A){var P;(P=n(x))==null||P.apply(this,A)}),ut("blur",T,function(...A){var P;(P=n(I))==null||P.apply(this,A)}),$(i,T),H()}Ye(["pointerdown","click"]);var K0=(i,e)=>{i.key==="Escape"&&e.onClose(),(i.key==="ArrowUp"||i.key==="ArrowDown")&&i.stopPropagation()},q0=L('<div class="modal-header s-1i"><h3 class="modal-title s-1i"> </h3> <!></div>'),Q0=L('<div class="modal-overlay s-1i"><div class="modal-container s-1i" role="dialog" aria-modal="true"><!> <div class="modal-scroll s-1i" tabindex="0" role="scrollbar"><div class="modal-main s-1i"><!></div></div></div></div>'),G0={hash:"s-1i",code:'.modal-overlay.s-1i{align-items:center;background:transparent;bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0;z-index:var(--modal-z-index)}.modal-container.s-1i{background:var(--mobile-settings-bg);border-radius:8px;color:var(--white);display:flex;flex-direction:column;height:calc(100% - 24px);max-height:490px;max-width:600px;width:calc(100% - 32px)}.modal-header.s-1i{align-items:start;border-bottom:1px solid var(--white-alpha-24);box-sizing:border-box;display:flex;height:40px;justify-content:space-between;padding:8px 10px}.modal-title.s-1i{color:var(--white);font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:600;line-height:16px;margin:3px 0 0 6px}.modal-scroll.s-1i{height:100%;margin:8px 4px 8px 0;overflow-x:hidden;overflow-y:auto}.modal-scroll.s-1i::-webkit-scrollbar{width:8px}.modal-scroll.s-1i::-webkit-scrollbar-track{background-color:transparent;border-radius:4px;box-shadow:none;margin-right:2px}.modal-scroll.s-1i::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#666;border:1px solid transparent;border-radius:5px;min-height:40px}.modal-scroll.s-1i::-webkit-scrollbar-thumb:hover{background-color:#777}.modal-main.s-1i{margin:-8px -4px 0 0}'};function Em(i,e){B(e,!0),Q(i,G0);let t=h(e,"showHeader",3,!0),o=h(e,"showCloseCross",3,!0),r=q(void 0),a=q(void 0),{webApi:{focusManager:l}}=be(),d=j("hotkey_map_modal_close_btn_text");Dt(()=>{var _;return(_=n(r))==null||_.focus(),n(a)&&l&&(l.setContainerForFocusLock(n(a)),l.activateLock()),()=>l==null?void 0:l.deactivateLock()});var s=Q0();s.__keydown=[K0,e];var u=C(s),m=C(u);{var p=_=>{var x=q0(),I=C(x),T=C(I,!0);S(I);var R=k(I,2);{var A=P=>{Kt(P,{get click(){return e.onClose},testId:"close-modal",style:"padding: 0; height: 24px; width: 24px",get ariaLabel(){return d},children:(E,z)=>{Im(E,{fill:"currentColor"})},$$slots:{default:!0}})};V(R,P=>{o()&&P(A)})}S(x),O(()=>ve(T,e.title)),$(_,x)};V(m,_=>{t()&&_(p)})}var v=k(m,2),b=C(v),y=C(b);ri(y,()=>{var _;return(_=e.children)!=null?_:_t}),S(b),S(v),Xe(v,_=>N(r,_),()=>n(r)),S(u),Xe(u,_=>N(a,_),()=>n(a)),S(s),$(i,s),H()}Ye(["keydown"]);var Y0=new Set(["BR"]),wb=i=>{var r;let e=document.createElement("DIV");e.innerHTML=i;let t=e.querySelectorAll("*"),o=t.length;for(;o--;){let a=t[o],l=a.tagName;Y0.has(l)||(r=a.parentElement)==null||r.removeChild(a)}return e.innerHTML};var j0=L('<li class="hot-key-map-item s-11"><span class="hot-key-map-item-description s-11"><!></span> <span class="hot-key-map-item-value s-11"> </span></li>'),X0=L('<div class="hot-key-map-group s-11"><h5 class="hot-key-map-group-title s-11"> </h5> <ul class="hot-key-map-group-items s-11"></ul></div>'),Z0=L('<div class="hot-key-map s-11"></div>'),J0={hash:"s-11",code:'.hot-key-map.s-11{box-sizing:border-box;color:var(--black);overflow-x:hidden}.hot-key-map-group.s-11{border-bottom:1px solid var(--white-alpha-24);margin:0 20px 0 16px}.hot-key-map-group.s-11:last-child{border-bottom:none}.hot-key-map-group-title.s-11{color:var(--white);font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:600;line-height:16px}.hot-key-map-group-title.s-11,.hot-key-map-item.s-11{margin:0;padding:12px 0;width:100%}.hot-key-map-group-items.s-11{box-sizing:border-box;list-style:none;margin:0;padding:0}.hot-key-map-item.s-11{align-items:center;box-sizing:border-box;display:flex;justify-content:space-between;--videoplayer-hotkey-item-value-width:156px;--videoplayer-hotkey-item-value-padding-left:24px}.hot-key-map-item-description.s-11{color:var(--white-alpha-72);max-width:388px;width:calc(100% - var(--videoplayer-hotkey-item-value-width) - var(--videoplayer-hotkey-item-value-padding-left))}.hot-key-map-item-value.s-11{color:var(--white);letter-spacing:-.14px;padding-left:var(--videoplayer-hotkey-item-value-padding-left);width:var(--videoplayer-hotkey-item-value-width)}.hot-key-map-item-description.s-11,.hot-key-map-item-value.s-11{font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:400;line-height:16px}'};function Pm(i,e){B(e,!1),Q(i,J0);let[t,o]=De(),r=()=>w(l,"$data",t),a=be(),{data:l,show:d}=a.ui.modals.hotKeyMap,s=()=>{d.set(!1)};$o(),Em(i,{get title(){return r().title},onClose:s,children:(u,m)=>{var p=Z0();yi(p,5,()=>r().groups,({title:v,items:b})=>v,(v,b)=>{let y=()=>n(b).title,_=()=>n(b).items;var x=X0(),I=C(x),T=C(I,!0);S(I);var R=k(I,2);yi(R,5,_,({description:A,value:P})=>P,(A,P)=>{let E=()=>n(P).description,z=()=>n(P).value;var F=j0(),U=C(F),X=C(U);Ud(X,()=>wb(E())),S(U);var ae=k(U,2),Z=C(ae,!0);S(ae),S(F),O(()=>ve(Z,z())),$(A,F)}),S(R),S(x),O(()=>ve(T,y())),$(v,x)}),S(p),$(u,p)},$$slots:{default:!0}}),H(),o()}var Iv=require("@vkontakte/videoplayer-shared/es2015");var rl=require("@vkontakte/videoplayer-core/es2015");var Sb=require("@vkontakte/videoplayer-shared/es2015");var ex=L('<div class="pillow s-1y"><!></div>'),tx={hash:"s-1y",code:".pillow.s-1y{background-color:#679ff8;color:var(--white);font-size:6px;font-weight:600;-webkit-font-smoothing:antialiased;border-radius:12px;padding:2px 4px}"};function km(i,e){Q(i,tx);var t=ex(),o=C(t);ri(o,()=>{var r;return(r=e.children)!=null?r:_t}),S(t),O(()=>Re(t,"data-testid",e.testId)),$(i,t)}var ed=require("@vkontakte/videoplayer-shared/es2015");var ix=Ie('<svg><!><path d="M5.52 5c.32 0 .51-.2.51-.54V3.5l.5-.51 1.46 1.74c.16.2.3.28.51.28a.5.5 0 0 0 .5-.5c0-.14-.07-.29-.22-.48L7.3 2.3 8.8.87c.16-.14.2-.25.2-.4A.47.47 0 0 0 8.52 0c-.18 0-.3.07-.45.22l-2 2.03h-.04V.54C6.03.2 5.84 0 5.52 0S5 .2 5 .54v3.92c0 .34.2.54.52.54M2.55 1.05 1.05 3.1h1.5zM3.5 3.1V.83C3.5.03 2.41-.3 1.94.35L.14 2.82A.75.75 0 0 0 .75 4h1.8v.55c0 .25.25.45.5.45a.45.45 0 0 0 .45-.45V4h.05a.45.45 0 0 0 0-.9z"></path></svg>');function Am(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=ix();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(),S(o),$(i,o)}var ox=Ie('<svg><!><path d="M5.51 5c.33 0 .52-.2.52-.54V3.5l.49-.51L7.99 4.7c.16.21.3.29.51.29a.49.49 0 0 0 .5-.5c0-.14-.07-.29-.22-.48L7.29 2.3 8.82.87C8.95.73 9 .62 9 .47A.47.47 0 0 0 8.52 0c-.17 0-.3.07-.44.22L6.06 2.25h-.03V.54C6.03.2 5.83 0 5.5 0S5 .2 5 .54v3.92c0 .34.19.54.51.54M2 0c-.35 0-.67.06-.95.17a1.5 1.5 0 0 0-.66.49c-.15.2-.23.44-.23.7 0 .43.21.76.62 1-.23.11-.41.26-.55.44-.15.2-.23.44-.23.71 0 .29.08.55.25.78.18.23.41.4.71.52.3.13.65.19 1.04.19s.73-.06 1.03-.19c.3-.12.54-.3.71-.52a1.26 1.26 0 0 0 .03-1.49 1.45 1.45 0 0 0-.55-.44c.4-.23.62-.57.62-1a1.14 1.14 0 0 0-.24-.7 1.44 1.44 0 0 0-.66-.49A2.4 2.4 0 0 0 2 0m-.57.96C1.56.86 1.75.8 2 .8s.43.06.56.16a.51.51 0 0 1 .2.43c0 .2-.06.34-.2.44A.87.87 0 0 1 2 2a.9.9 0 0 1-.57-.16.52.52 0 0 1-.2-.44c0-.18.06-.32.2-.43ZM1.08 3.5a.6.6 0 0 1 .24-.5c.16-.13.38-.2.68-.2s.52.07.68.2a.6.6 0 0 1 .24.5.63.63 0 0 1-.24.52c-.16.12-.38.19-.68.19s-.52-.07-.68-.19a.64.64 0 0 1-.24-.52"></path></svg>');function Lm(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=ox();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(),S(o),$(i,o)}var nx=Ie('<svg><!><path d="M5.52 5h1.1C8.1 5 9 4.07 9 2.5S8.1 0 6.62 0h-1.1C5.19 0 5 .2 5 .54v3.92c0 .34.2.54.52.54m.51-.85V.85h.47C7.41.85 8 1.47 8 2.5c0 1.07-.58 1.65-1.5 1.65zM.52 5c.32 0 .51-.2.51-.54V2.92h1.94v1.54c0 .34.19.54.51.54S4 4.8 4 4.46V.54C4 .2 3.8 0 3.48 0s-.51.2-.51.54v1.53H1.03V.54C1.03.2.84 0 .52 0S0 .2 0 .54v3.99c0 .34.2.47.52.47"></path></svg>');function Mm(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=nx();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(),S(o),$(i,o)}var rx=Ie('<svg><!><path d="M9.52 5h1.1C12.1 5 13 4.07 13 2.5S12.1 0 10.62 0h-1.1C9.19 0 9 .2 9 .54v3.92c0 .34.2.54.52.54m.51-.85V.85h.47c.91 0 1.5.62 1.5 1.65 0 1.07-.58 1.65-1.5 1.65zM4.52 5c.32 0 .51-.2.51-.54V2.92h1.94v1.54c0 .34.19.54.51.54S8 4.8 8 4.46V.54C8 .2 7.8 0 7.48 0s-.51.2-.51.54v1.53H5.03V.54C5.03.2 4.84 0 4.52 0S4 .2 4 .54v3.99c0 .34.2.47.52.47m-4 0c.32 0 .51-.2.51-.54V3h1.33c.27 0 .45-.15.45-.41 0-.25-.18-.4-.45-.4H1.03V.84h1.5C2.81.85 3 .7 3 .43S2.8 0 2.53 0H.52C.19 0 0 .2 0 .54v3.92C0 4.8.2 5 .52 5"></path></svg>');function Vm(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=rx();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"13",height:"5",fill:"currentColor",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(),S(o),$(i,o)}var sx=Ie('<svg><!><path d="M11.52 5.75h1.1c1.48 0 2.38-.94 2.38-2.5s-.9-2.5-2.38-2.5h-1.1c-.33 0-.52.2-.52.54V5.2c0 .34.2.54.52.54Zm.51-.85V1.6h.47c.91 0 1.5.62 1.5 1.65 0 1.07-.58 1.65-1.5 1.65zm-5.51.85c.32 0 .51-.2.51-.54V3.67h1.94v1.54c0 .34.19.54.51.54s.52-.2.52-.54V1.3c0-.34-.2-.54-.52-.54s-.51.2-.51.54v1.53H7.03V1.3c0-.34-.19-.54-.51-.54S6 .95 6 1.29v3.99c0 .34.2.47.52.47m-3.18-.09a4 4 0 0 1-.84.09C1.04 5.75 0 4.88 0 3.3 0 1.73 1.04.75 2.5.75S5 1.73 5 3.3c0 .87-.27 1.46-.78 1.88l.2.3a.5.5 0 0 1-.84.55zm-.52-.78-.24-.35a.5.5 0 1 1 .84-.56l.24.37c.18-.26.29-.62.29-1.04 0-1.03-.64-1.65-1.45-1.65s-1.45.62-1.45 1.65.64 1.6 1.45 1.6c.08 0 .2 0 .32-.02"></path></svg>');function Rm(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=sx();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"15",height:"7",fill:"currentColor",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(),S(o),$(i,o)}var lp=i=>{switch(i){case ed.VideoQuality.Q_720P:return Mm;case ed.VideoQuality.Q_1080P:return Vm;case ed.VideoQuality.Q_1440P:return Rm;case ed.VideoQuality.Q_2160P:return Am;case ed.VideoQuality.Q_4320P:return Lm}};var ax=Ie('<path d="M12.72 2.21q1.8.07 2.41 1.96l.06.21.06.2.06.23.06.16.04.01.06-.02.14-.05.15-.07c1.42-.66 2.5-.53 3.4.44l.12.14.82 1.02c.73.96.7 2 0 3.1l-.13.19-.12.16-.14.2-.07.12-.04.05v.03l.1.06.13.07.15.09c1.39.7 1.96 1.64 1.74 2.93l-.04.19-.24 1.06c-.16.68-.28 1-.77 1.45-.48.43-1.02.61-1.73.67l-.22.02h-.2l-.25.02-.18.02.02.14v.1l.04.17c.32 1.53-.04 2.56-1.19 3.2l-.17.1-1.17.57q-1.64.73-3.02-.7l-.15-.17-.13-.15-.17-.19-.1-.1-.05-.04-.1.09-.1.1-.12.14c-.95 1.13-1.95 1.54-3.17 1.07l-.18-.08-1.05-.5-.31-.17a2 2 0 0 1-1-1.06 3 3 0 0 1-.16-1.88l.04-.23.04-.24.02-.17-.1-.02-.15-.01h-.18c-1.56-.04-2.48-.62-2.85-1.89l-.05-.18-.3-1.28q-.33-1.77 1.37-2.78l.2-.11.17-.1.22-.12.15-.1v-.02l-.06-.1-.08-.13-.1-.14c-.94-1.25-1.04-2.34-.28-3.4L4 6.32l.82-1.01c.8-.92 1.8-1.1 3.04-.64l.2.08.19.08.22.1.13.04.04-.01.03-.1.05-.13.04-.17c.36-1.43 1.09-2.24 2.4-2.35h1.58Zm-.05 1.8h-1.34l-.14.01c-.28.04-.47.2-.65.83l-.04.16-.06.2a6 6 0 0 1-.46 1.14 6 6 0 0 0-1.15.56 7 7 0 0 1-1.16-.35l-.35-.16q-.37-.15-.59-.17h-.08a.6.6 0 0 0-.4.19l-.08.07-.78.98-.1.12c-.18.26-.2.5.2 1.08l.22.31q.34.48.6 1.1-.2.59-.27 1.2-.51.45-1.01.73l-.34.18c-.62.34-.7.56-.65.88l.01.08.28 1.21.04.16c.1.3.27.47.97.5l.39.02q.57.03 1.22.2.35.53.78.97a6 6 0 0 1-.12 1.45c-.2.95-.01 1.1.38 1.3l1.13.54a1 1 0 0 0 .34.1l.06-.01q.26-.03.67-.49l.26-.3q.4-.42.95-.83l.3.02.3.01h.3l.3-.03q.56.4.95.84l.26.3c.32.36.53.48.73.48h.07l.18-.05.09-.04 1.13-.54.14-.08c.3-.17.42-.4.24-1.22a6 6 0 0 1-.12-1.45q.44-.45.78-.97a7 7 0 0 1 1.22-.2l.39-.01c.81-.04.91-.26 1-.66l.27-1.15c.09-.4.1-.64-.62-1.03l-.34-.18a6 6 0 0 1-1.01-.73 6 6 0 0 0-.27-1.2q.26-.62.6-1.1l.22-.31c.4-.58.38-.81.2-1.08l-.05-.06-.78-.97c-.14-.18-.26-.3-.46-.33h-.07q-.23 0-.67.17l-.35.16a6 6 0 0 1-1.16.35 6 6 0 0 0-1.15-.56 7 7 0 0 1-.45-1.1l-.11-.4c-.2-.68-.4-.81-.72-.83zM12 8.2a3.8 3.8 0 1 1 0 7.6 3.8 3.8 0 0 1 0-7.6m0 1.8a2 2 0 1 0 0 4 2 2 0 0 0 0-4"></path>');function Nm(i,e){Ze(i,{get testId(){return e.testId},children:(t,o)=>{var r=ax();$(t,r)},$$slots:{default:!0}})}var lx=Ie('<path d="M13.25 2.83c.23.75.38 1.5 1.63 2.23 1.4.38 2.08 0 2.72-.42.66-.45.86-.32 1.12-.06l.65.64c.29.3.4.42 0 1.18-.38.7-.8 1.33-.42 2.73.72 1.25 1.47 1.47 2.22 1.62.78.16.83.39.83.76v.9c0 .42 0 .59-.83.84-.75.23-1.5.38-2.23 1.63-.38 1.4 0 2.08.42 2.72.45.66.32.86.06 1.12l-.64.65c-.3.29-.42.4-1.18 0-.7-.38-1.34-.8-2.73-.42-1.25.72-1.47 1.47-1.62 2.22-.16.78-.39.83-.76.83h-.9c-.42 0-.59 0-.84-.83-.23-.75-.38-1.5-1.63-2.23-1.4-.38-2.08 0-2.72.42-.66.45-.86.32-1.12.06l-.65-.64c-.29-.3-.4-.42 0-1.18.38-.7.8-1.34.42-2.73-.72-1.25-1.47-1.47-2.22-1.62-.78-.16-.83-.39-.83-.76v-.9c0-.42 0-.59.83-.84.75-.23 1.5-.38 2.22-1.63.38-1.4 0-2.08-.42-2.72-.44-.66-.31-.86-.05-1.12l.64-.65c.3-.29.42-.4 1.18 0 .7.38 1.33.8 2.73.42 1.25-.72 1.47-1.47 1.62-2.22.16-.78.39-.83.76-.83h.9c.42 0 .59 0 .84.83M12 7.25a4.75 4.75 0 1 0 0 9.5 4.75 4.75 0 0 0 0-9.5"></path>');function Dm(i,e){Ze(i,{get testId(){return e.testId},children:(t,o)=>{var r=lx();$(t,r)},$$slots:{default:!0}})}var dx=L('<div aria-hidden="true"><!> <!></div>'),cx={hash:"s-1v",code:".icon.s-1v{display:flex;height:24px;position:relative;width:24px}.icon.s-1v .pillow{position:absolute;right:-9px;top:1px}.icon.triple.s-1v .pillow{right:-13px}.icon.s-1v svg[data-testid=settings-icon--labeled] ._full{opacity:0;visibility:hidden}"};function cc(i,e){B(e,!0),Q(i,cx);let t=h(e,"isMobile",3,!1),o=h(e,"currentQuality",3,void 0),r=f(()=>o()?(0,Sb.getVideoQualityLabel)(o()):""),a=f(()=>lp(o())),l=f(()=>n(r).length>2);var d=Me(),s=ue(d);{var u=p=>{Nm(p,{testId:"settings-mobile-icon"})},m=p=>{var v=dx();let b;var y=C(v);{var _=T=>{let R=f(()=>`${n(r)}-pill-icon`);km(T,{get testId(){return n(R)},children:(A,P)=>{var E=Me(),z=ue(E);Di(z,()=>n(a),(F,U)=>{U(F,{})}),$(A,E)},$$slots:{default:!0}})};V(y,T=>{n(a)&&T(_)})}var x=k(y,2);let I=f(()=>n(a)?"settings-icon--labeled":"settings-icon");Dm(x,{get testId(){return n(I)}}),S(v),O(T=>b=oe(v,1,"icon s-1v",null,b,T),[()=>({triple:n(l)})]),$(p,v)};V(s,p=>{t()?p(u):p(m,!1)})}$(i,d),H()}var ux=L('<span class="settings-icon-wrapper s-23"><!></span>'),px={hash:"s-23",code:".settings-icon-wrapper.s-23{position:relative;width:24px}"};function td(i,e){B(e,!0),Q(i,px);let[t,o]=De(),r=()=>w(u,"$settingsMenuVisible",t),a=()=>w(v,"$isMobile",t),l=()=>w(s,"$currentQuality",t),d=be(),s=d.state.currentQuality$,u=d.ui.settingsMenu.visible$,m=d.actions.internal.openSettingsMenu,p=d.actions.internal.closeSettingsMenu,v=d.ui.isMobile,b=d.ui.t,y=q(void 0);Oe(()=>{n(y)&&Pt(()=>{e.ref$.set(n(y))})});let _=b("aria_label_settings");function x(T){return ht(this,null,function*(){let R=fa(T);r()?p():m(R,ho)})}let I=f(()=>r()?"opened":"");Kt(i,{get className(){return n(I)},testId:"settings-btn",click:x,get ariaLabel(){return _},get ariaExpanded(){return r()},get ref(){return n(y)},set ref(T){N(y,T,!0)},children:(T,R)=>{var A=ux(),P=C(A);cc(P,{get isMobile(){return a()},get currentQuality(){return l()}}),S(A),$(T,A)},$$slots:{default:!0}}),H(),o()}var fx=Ie('<path d="M6.56 4.44a1.5 1.5 0 1 0-2.12 2.12l3.09 3.09a11 11 0 0 0-2.39 3.08 11 11 0 0 0-1.01 4.14C4 18.43 4 20.37 4 22.83v2.34c0 2.46 0 4.4.13 5.96.13 1.6.4 2.93 1.01 4.14a10.5 10.5 0 0 0 4.6 4.59c1.2.61 2.53.88 4.13 1.01 1.56.13 3.5.13 5.96.13h8.34c2.46 0 4.4 0 5.96-.13 1.44-.12 2.66-.35 3.78-.84l3.53 3.53a1.5 1.5 0 0 0 2.12-2.12zM13.5 28a1.5 1.5 0 0 0 0 3h11a1.5 1.5 0 0 0 0-3zM12 22a1.5 1.5 0 0 1 1.5-1.5h4a1.5 1.5 0 0 1 0 3h-4A1.5 1.5 0 0 1 12 22"></path><path d="M34.5 23.5h-4.64l12.55 12.55q.23-.37.45-.78a11 11 0 0 0 1.01-4.14c.13-1.56.13-3.5.13-5.96v-2.34c0-2.46 0-4.4-.13-5.96a11 11 0 0 0-1.01-4.14 10.5 10.5 0 0 0-4.6-4.59 11 11 0 0 0-4.13-1.01C32.57 7 30.63 7 28.17 7h-8.34c-2.46 0-4.4 0-5.96.13l-.35.03L26.86 20.5h7.64a1.5 1.5 0 0 1 0 3"></path>',1),mx=Ie("<path></path>");function ga(i,e){B(e,!0);let t=f(()=>`subtitles-icon${e.type==="off"?"-off":e.type==="outline"?"-outline":""}`),o=f(()=>fn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(o)},get testId(){return n(t)},get shadow(){return e.shadow},children:(r,a)=>{var l=Me(),d=ue(l);{var s=m=>{var p=fx();pi(),$(m,p)},u=m=>{var p=mx();O(()=>Re(p,"d",`M16.92 8h14.16q2.82-.02 4.66.1c1.28.1 2.4.32 3.46.86a8.8 8.8 90 013.84 3.84c.54 1.04.76 2.18.86 3.46q.12 1.84.1 4.66v6.16q.02 2.82-.1 4.66a10 10 90 01-.86 3.46 8.8 8.8 90 01-3.84 3.84 10 10 90 01-3.46.86q-1.84.12-4.66.1H16.92q-2.82.02-4.66-.1a10 10 90 01-3.46-.86 8.8 8.8 90 01-3.84-3.84 10 10 90 01-.86-3.46Q4 29.9 4 27.08v-6.16q-.02-2.82.1-4.66c.1-1.28.32-2.4.86-3.46A8.8 8.8 90 018.8 8.96a10 10 90 013.46-.86Q14.1 8 16.92 8
|
|
58
|
+
Audio: ${(Se=n(s).audioCodec||"")!=null?Se:""} ${n(s).audioLanguage?`(${n(s).audioLanguage})`:""}`)}),$(q,Le)};V(te,q=>{(n(s).videoCodec||n(s).audioCodec)&&q(_e)})}var Ce=k(te,2);{var me=q=>{var Le=m0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(()=>ge(ye,n(s).viewport)),$(q,Le)};V(Ce,q=>{n(s).viewport&&q(me)})}var ce=k(Ce,2);{var Ye=q=>{var Le=v0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(()=>ge(ye,n(s).videoSize)),$(q,Le)};V(ce,q=>{n(s).videoSize&&q(Ye)})}var G=k(ce,2);{var D=q=>{var Le=g0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(()=>ge(ye,n(s).cdn)),$(q,Le)};V(G,q=>{n(s).cdn&&q(D)})}var Xe=k(G,2);{var re=q=>{var Le=h0(),Me=k(T(Le),2),ye=T(Me);S(Me),S(Le),N(()=>{var Ue;return ge(ye,`${(Ue=n(s).volume)!=null?Ue:""} %`)}),$(q,Le)};V(Xe,q=>{n(s).volume&&q(re)})}var pe=k(Xe,2);{var ue=q=>{var Le=_0(),Me=k(T(Le),2),ye=T(Me);S(Me),S(Le),N(Ue=>ge(ye,`${Ue!=null?Ue:""} s`),[()=>n(s).position.toFixed(2)]),$(q,Le)};V(pe,q=>{n(s).position&&q(ue)})}var Ae=k(pe,2);{var ze=q=>{var Le=b0(),Me=k(T(Le),2),ye=T(Me);S(Me),S(Le),N(Ue=>ge(ye,`${Ue!=null?Ue:""} s`),[()=>n(s).buffer.toFixed(2)]),$(q,Le)};V(Ae,q=>{n(s).buffer&&q(ze)})}var ee=k(Ae,2);{var de=q=>{var Le=$0(),Me=k(T(Le),2),ye=T(Me);S(Me),S(Le),N(Ue=>ge(ye,`${Ue!=null?Ue:""} s`),[()=>n(s).nativeBuffer.toFixed(2)]),$(q,Le)};V(ee,q=>{n(s).nativeBuffer&&q(de)})}var ke=k(ee,2);{var xe=q=>{var Le=y0(),Me=k(T(Le),2),ye=T(Me);S(Me),S(Le),N(Ue=>ge(ye,`${Ue!=null?Ue:""} s`),[()=>n(s).liveLatency.toFixed(2)]),$(q,Le)};V(ke,q=>{n(s).liveLatency&&q(xe)})}var Je=k(ke,2);{var Pe=q=>{var Le=x0(),Me=k(T(Le),2),ye=T(Me,!0);S(Me),S(Le),N(Ue=>ge(ye,Ue),[()=>[{value:n(s).currentVideoSegmentLength,title:"Video:"},{value:n(s).currentAudioSegmentLength,title:"Audio:"}].filter(({value:Ue})=>Ue).map(({value:Ue,title:Se})=>`${Se} ${((Ue!=null?Ue:0)/1e3).toFixed(2)} s`).join(" & ")]),$(q,Le)};V(Je,q=>{(n(s).currentVideoSegmentLength||n(s).currentAudioSegmentLength)&&q(Pe)})}var we=k(Je,2),Ne=k(T(we),2),Pt=T(Ne);S(Ne),S(we);var kt=k(we,2);{var Lt=q=>{var Le=w0(),Me=k(T(Le),2);rc(Me,{get values(){return n(I)}});var ye=k(Me,2),Ue=T(ye);S(ye),S(Le),N(Se=>ge(Ue,`${Se!=null?Se:""} Kbps`),[()=>n(s).speed.toFixed(2)]),$(q,Le)};V(kt,q=>{n(s).speed&&q(Lt)})}var pt=k(kt,2);{var It=q=>{var Le=S0(),Me=k(T(Le),2);rc(Me,{get values(){return n(C)}});var ye=k(Me,2),Ue=T(ye);S(ye),S(Le),N(Se=>ge(Ue,`${Se!=null?Se:""} Kbps`),[()=>n(s).bitrate.toFixed(2)]),$(q,Le)};V(pt,q=>{n(s).bitrate&&q(It)})}var ei=k(pt,2),Ft=k(T(ei),2);rc(Ft,{get values(){return n(x)}});var Bt=k(Ft,2),qt=T(Bt,!0);S(Bt),S(ei),S(W),S(A),N(q=>{var Le,Me;P=oe(A,1,"container s-q",null,P,q),De(A,"aria-label",R),ge(X,n(s).version),ge(Pt,`${(Le=n(p))!=null?Le:""} / ${(Me=n(m))!=null?Me:""} frames`),ge(qt,n(v))},[()=>({"container-mobile":r()})]),$(i,A),H(),o()}et(["click"]);var bb=require("@vkontakte/videoplayer-shared/es2015"),I0=(i,e)=>{i.stopPropagation(),e()()},E0=L('<div class="close s-17"></div>'),P0={hash:"s-17",code:'.close.s-17{cursor:pointer;height:16px;opacity:.8;position:relative;transition:opacity .2s;width:16px}.close.s-17:hover{opacity:1}.close.s-17:after,.close.s-17:before{background-color:var(--white);content:" ";height:16px;left:8px;position:absolute;width:2px}.close.s-17:before{transform:rotate(45deg)}.close.s-17:after{transform:rotate(-45deg)}'};function Hs(i,e){B(e,!0),Q(i,P0);let t=h(e,"onClick",3,bb.noop);var o=E0();o.__click=[I0,t],$(i,o),H()}et(["click"]);var $b=require("@vkontakte/videoplayer-shared/es2015");var vn=i=>`width:${i}px;height:${i}px;`;var k0=Ee('<path d="m14.4 8.76 24.02 13.85a1.6 1.6 0 0 1 0 2.78L14.4 39.24a1.6 1.6 0 0 1-2.4-1.39v-27.7a1.6 1.6 0 0 1 2.4-1.39"></path>');function Ln(i,e){B(e,!0);let t=f(()=>vn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(t)},testId:"play-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=k0();$(o,a)},$$slots:{default:!0}}),H()}var A0=L('<div class="timer s-16"><canvas class="timer-canvas s-16" width="100" height="100"></canvas> <!></div>'),L0={hash:"s-16",code:".timer.s-16{align-items:center;background:rgba(31,31,31,.65);border-radius:50%;display:flex;height:50px;justify-content:space-around;transition:background .2s;width:50px}.timer.s-16:hover{background:rgba(31,31,31,.85)}.timer-canvas.s-16{height:50px;position:absolute;width:50px}"};function ac(i,e){B(e,!0),Q(i,L0);let t=h(e,"isRunning",3,!0),o=h(e,"onTimerEnded",3,$b.noop),r=5e3,a=K(void 0),l,d,s=0,u;Fe(()=>{t()&&Et(()=>{d=Date.now(),s=requestAnimationFrame(p)})});let m=()=>{s&&(cancelAnimationFrame(s),s=0)},p=()=>{m(),t()&&(u=(Date.now()-d)/r,u<1?(l==null||l.clearRect(0,0,100,100),l==null||l.beginPath(),l==null||l.arc(50,50,47,-Math.PI/2,-Math.PI/2+Math.PI*2*u),l==null||l.stroke(),s=requestAnimationFrame(p)):o()())};Ot(()=>{l=n(a).getContext("2d"),l&&(l.lineWidth=6,l.lineCap="round",l.strokeStyle="#fff")}),mn(()=>{m()});var v=A0(),b=T(v);it(b,_=>O(a,_),()=>n(a));var y=k(b,2);Ln(y,{get size(){return"24"}}),S(v),$(i,v),H()}var M0=(i,e,t)=>{e(!1),t()},V0=L('<div class="overlay s-u"></div> <div class="next-video s-u"><div class="top s-u"><div class="caption s-u"> </div> <!></div> <div class="row s-u"><div class="column s-u"><div class="thumb s-u"><div></div> <!></div></div> <div class="column s-u"><div class="title s-u"> </div></div></div></div>',1),R0={hash:"s-u",code:".overlay.s-u{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-u{display:flex;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:362px}.top.s-u{display:flex;justify-content:space-between}.caption.s-u{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-u{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-u{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-u{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-u,.thumb-overlay.s-u{height:100%;width:100%}.thumb-overlay.s-u{position:absolute}.thumb-overlay.withOpacity.s-u{background:var(--black);opacity:.3}.title.s-u{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function ym(i,e){B(e,!0),Q(i,R0);let[t,o]=He(),r=()=>w(d,"$autoplayNextEnabled$",t),a=()=>w(s,"$timerNextVideoRunning$",t),l=$e(),d=l.ui.autoplayNextEnabled$,s=l.ui.timerNextVideoRunning$,u=l.actions.internal.nextVideoClick,m=l.actions.internal.nextVideoAnnouncementShow,p=l.actions.internal.nextVideoAnnouncementClick,v=l.actions.internal.nextVideoAnnouncementAuto,b=l.actions.internal.nextVideoAnnouncementCancel,y=()=>{r()&&(u(!1),v())},_=()=>{e.clickCloseIcon(),b()};Ot(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Oe(),I=le(x);{var C=R=>{var A=V0(),P=k(le(A),2),E=T(P),W=T(E),F=T(W,!0);S(W);var U=k(W,2);Hs(U,{onClick:_}),S(E);var X=k(E,2);X.__click=[M0,u,p];var se=T(X),j=T(se),ne=T(j);let Z;var Te=k(ne,2);{var fe=me=>{let ce=f(()=>a()&&r());ac(me,{get isRunning(){return n(ce)},onTimerEnded:y})};V(Te,me=>{r()&&me(fe)})}S(j),S(se);var te=k(se,2),_e=T(te),Ce=T(_e,!0);S(_e),S(te),S(X),S(P),N((me,ce)=>{ge(F,me),Qe(j,`background-image: url('${e.thumb}')`),Z=oe(ne,1,"thumb-overlay s-u",null,Z,ce),ge(Ce,e.title)},[()=>Y("end_screen_next_video"),()=>({withOpacity:r()})]),$(R,A)};V(I,R=>{e.isHide||R(C)})}$(i,x),H(),o()}et(["click"]);var va=require("@vkontakte/videoplayer-core/es2015"),yb=require("@vkontakte/videoplayer-shared/es2015"),Mn=require("@vkontakte/videoplayer-statistics/es2015");var xm=(i,e)=>Math.min(+(i+e).toFixed(2),1),wm=(i,e)=>Math.max(+(i-e).toFixed(2),0),op=(i,e,t)=>{let o=xm(e,t);e<1&&i.actions.internal.setVolume(o)},np=(i,e,t)=>{let o=wm(e,t);e>0&&i.actions.internal.setVolume(o)};var ma=({isAudioDisabled:i,isAudioAvailable:e,isAds:t,audioDisabledHintCallback:o,audioIsNotExistHintCallback:r})=>i?t?!0:(o==null||o(),!1):e?!0:(r==null||r(),!1);function rp(){var i,e,t;return(t=(e=(i=document.activeElement)==null?void 0:i.shadowRoot)==null?void 0:e.activeElement)!=null?t:null}var D0=(i,e)=>{e(i)},N0=L('<div class="keyboard-controls s-x" tabindex="-1" role="region"><!></div>'),B0={hash:"s-x",code:".keyboard-controls.s-x{bottom:0;left:0;position:absolute;right:0;top:0}"};function Sm(i,e){var ye,Ue;B(e,!0),Q(i,B0);let[t,o]=He(),r=()=>w(Te,"$disabledControls$",t),a=()=>w(ze,"$isInteractiveTime$",t),l=()=>w(ee,"$showInteractiveTimeIndicatorTooltip$",t),d=()=>w(U,"$playbackState$",t),s=()=>w(D,"$isEnded$",t),u=()=>w(Ye,"$doubleForwardAvailable$",t),m=()=>w(ce,"$doubleForwardOn$",t),p=()=>w(Xe,"$overlayContainer$",t),v=()=>w(se,"$adPlaybackState",t),b=()=>w(j,"$positionExact$",t),y=()=>w(ne,"$duration$",t),_=()=>w(ue,"$isAudioAvailable$",t),x=()=>w(Z,"$volume$",t),I=()=>w(X,"$canChangePlaybackSpeed$",t),C=()=>w(fe,"$muted$",t),R=()=>w(te,"$currentSubtitle$",t),A=h(e,"nextButtonActive",3,!1),P=h(e,"prevButtonActive",3,!1),E=$e(),W=Dt(),F=E.getLogger().createComponentLog("KeyboardControls component"),U=E.state.playbackState$,X=E.state.canChangePlaybackSpeed$,se=E.ads.playbackState,j=E.state.positionExact$,ne=E.state.duration$,Z=E.state.volume$,Te=E.ui.controls.disabledControls$,fe=E.state.muted$,te=E.state.currentSubtitle$,_e=E.ui.contextMenu.openedByHotKey$,Ce=E.ui.contextMenu.lastActiveElem$,me=E.ui.contextMenu.visible$,ce=E.ui.doubleForwardOn$,Ye=E.ui.doubleForwardAvailable$,G=E.ui.contextMenu.position$,D=E.state.isEnded$,Xe=E.ui.overlayContainer$,re=(ye=E.callbacks)==null?void 0:ye.onAudioDoesNotExistHint,pe=(Ue=E.callbacks)==null?void 0:Ue.onAudioDisabledHint,ue=E.state.isAudioAvailable$,Ae=E.state.isAudioDisabled,ze=E.state.isInteractiveTime$,{showInteractiveTimeIndicatorTooltip$:ee}=xo(),de=0,ke=!0,xe=K(void 0),Je=Se=>(Se!==ke&&(ke=Se,de=0),de+=1,(W.controls.seekStepKeyboard+W.controls.seekStepKeyboard*de)/1e3),Pe=!0,we=()=>{if(!r().has("PLAY_BUTTON"))if(a()&&l()&&ee.set(!1),e.fakePlayButtonHandler)e.fakePlayButtonHandler();else{E.actions.internal.togglePlay();let Se="PLAY";d()===va.PlaybackState.PAUSED?Se="PAUSE":s()&&(Se="REPLAY"),e.showHotKeyHelpers({type:Se})}},Ne=Se=>{if(!u()||!Se&&m()){we(),e.stopDoubleForward(),Pe=!0;return}Pe=!1,!Se&&e.startDoubleForwardActivationTimer()},Pt=()=>{Pe||(m()||we(),e.stopDoubleForward(),Pe=!0)},kt=Se=>{Se!=="Space"&&e.stopDoubleForward()},Lt=Se=>{let Tt=_b(p());G.set(Tt),Ce.set(Se.target),_e.set(!0),me.set(!0)},pt=(Se,Tt=!1)=>{var pi,Ji;let ve=Se.target,Be=(pi=ve==null?void 0:ve.getAttribute("role"))==null?void 0:pi.includes("menuitem"),qe=ve.classList.contains("btn"),ct=Se.code;if(qe&&ct==="Space")return!1;let Xt=b_.has(ct);if(Be&&Xt)return!1;let Mt=!__.has(ct);if(Se.ctrlKey&&Mt||Se.altKey&&Mt||Se.metaKey)return!1;let di=Be&&ct==="Escape";$_.has(ct)||di||e.hideContextMenu();let ci=d()===va.PlaybackState.PLAYING||d()===va.PlaybackState.PAUSED,Li=e.isAds&&(v()==="paused"||v()==="playing"),bo=!Li&&!r().has("TIMELINE"),$o=Se.shiftKey&&["Digit1","Numpad1"].includes(ct);if(!$o&&!(ci||Li))return!1;F({message:`key down, code: ${ct}, isExternal = ${Tt}`});let ui=!1,at=()=>{ui=!0,Tt||Se.preventDefault()};if(kt(ct),$o)return Lt(Se),at(),!0;switch(ct){case"KeyJ":case"ArrowLeft":{if(!bo)break;if(Se.ctrlKey||Se.altKey){let ft=E.actions.internal.getPrevEpisode();E.actions.internal.seekToPrevEpisode(ft),ft&&e.showHotKeyHelpers({type:"EPISODE_PREV",text:ft.text}),at()}else{let ft=Se.shiftKey?Je(!1):W.controls.seekStepKeyboard/1e3,Ht=Math.max(b()-ft,0);b()>0&&(E.actions.internal.seekTime(Ht,Mn.SeekAction.DOUBLE_TAP),e.showHotKeyHelpers({type:"BACKWARD_SEEK",text:ft.toString()}),at())}break}case"KeyL":case"ArrowRight":{if(!bo)break;if(Se.ctrlKey||Se.altKey){let ft=E.actions.internal.getNextEpisode();E.actions.internal.seekToNextEpisode(ft),ft&&e.showHotKeyHelpers({type:"EPISODE_NEXT",text:ft.text}),at()}else{let ft=Se.shiftKey?Je(!0):W.controls.seekStepKeyboard/1e3,Ht=Math.min(b()+ft,y());Math.round(b())<Math.round(y())&&(E.actions.internal.seekTime(Ht,Mn.SeekAction.DOUBLE_TAP),e.showHotKeyHelpers({type:"FORWARD_SEEK",text:ft.toString()}),at())}break}case"ArrowUp":{if(ma({isAudioDisabled:Ae,audioDisabledHintCallback:pe,isAudioAvailable:_(),audioIsNotExistHintCallback:re,isAds:e.isAds})){let ft=x(),Ht=W.controls.volumeStepKeyboard,hi=ft<=1;if(op(E,ft,Ht),hi){let rt=Math.round(xm(ft,Ht)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:rt}})}}at();break}case"ArrowDown":{if(ma({isAudioDisabled:Ae,audioDisabledHintCallback:pe,isAudioAvailable:_(),audioIsNotExistHintCallback:re,isAds:e.isAds})){let ft=x(),Ht=W.controls.volumeStepKeyboard,hi=ft>=0;if(np(E,ft,Ht),hi){let rt=Math.round(wm(ft,Ht)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:rt}})}}at();break}case"Comma":{if(Se.shiftKey){if(!m()&&I()){let ft=E.actions.internal.decrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_DOWN",text:ft==null?void 0:ft.displayValue}),at()}}else{if(Li||d()!==va.PlaybackState.PAUSED)break;let ft=Math.max(b()-W.controls.seekStepFrame/1e3,0);b()>0&&(e.showHotKeyHelpers({type:"BACKWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(ft,Mn.SeekAction.DOUBLE_TAP),at())}break}case"Period":{if(Se.shiftKey){if(!m()&&I()){let ft=E.actions.internal.incrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_UP",text:ft==null?void 0:ft.displayValue}),at()}}else{if(Li||d()!==va.PlaybackState.PAUSED)break;let ft=Math.min(b()+W.controls.seekStepFrame/1e3,y());b()<y()&&(e.showHotKeyHelpers({type:"FORWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(ft,Mn.SeekAction.DOUBLE_TAP),at())}break}case"KeyK":we(),at();break;case"Space":Ne(Se.repeat),at();break;case"KeyM":{ma({isAudioDisabled:Ae,audioDisabledHintCallback:pe,isAudioAvailable:_(),audioIsNotExistHintCallback:re,isAds:e.isAds})&&(e.showHotKeyHelpers({type:C()?"VOLUME":"MUTE"}),E.actions.internal.toggleMuted()),at();break}case"KeyF":e.toggleFullscreen(),at();break;case"KeyC":E.actions.internal.toggleSubtitle(),R().value!=="off"?e.showHotKeyHelpers({type:"SUBTITLES_ON",text:(Ji=R())==null?void 0:Ji.displayValue}):e.showHotKeyHelpers({type:"SUBTITLES_OFF"}),at();break;case"KeyI":E.actions.internal.togglePictureInPicture(),at();break;case"Digit1":case"Numpad1":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.1,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit2":case"Numpad2":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.2,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit3":case"Numpad3":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.3,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit4":case"Numpad4":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.4,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit5":case"Numpad5":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.5,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit6":case"Numpad6":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.6,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit7":case"Numpad7":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.7,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit8":case"Numpad8":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.8,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit9":case"Numpad9":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.9,Mn.SeekAction.DOUBLE_TAP),at();break;case"Digit0":case"Numpad0":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(0,Mn.SeekAction.DOUBLE_TAP),at();break;case"Slash":{Se.shiftKey&&W.features.hotKeyMapModal&&(e.showKeyMap(),at());break}case"KeyN":Se.shiftKey&&A()&&(E.actions.internal.nextVideoClick(),at());break;case"KeyP":Se.shiftKey&&P()&&(E.actions.internal.prevVideoClick(),at());break;case"ShiftLeft":case"ShiftRight":at();break;case"Tab":case"Escape":case"Enter":break;default:(0,yb.checkNever)(ct);break}return ui},It=Se=>{let Tt=Se.code;if(Se.ctrlKey||Se.altKey||Se.metaKey)return;let ve=d()===va.PlaybackState.PLAYING||d()===va.PlaybackState.PAUSED,Be=e.isAds&&(v()==="paused"||v()==="playing");if(ve||Be)switch(Tt){case"ShiftLeft":case"ShiftRight":de=0;break;case"Space":Pt();break}},ei=Y("aria_label_video_player"),Ft=()=>{var Se;return(Se=n(xe))==null?void 0:Se.focus()},Bt=()=>n(xe)===rp(),qt=Se=>Se.type==="keydown"?pt(Se,!0):(Se.type==="keyup"&&It(Se),!1);var q=N0();q.__keyup=It,q.__keydown=[D0,pt];var Le=T(q);ri(Le,()=>{var Se;return(Se=e.children)!=null?Se:$t}),S(q),it(q,Se=>O(xe,Se),()=>n(xe)),N(()=>De(q,"aria-label",ei)),$(i,q);var Me=H({focus:Ft,isFocused:Bt,handleExternalKeyboardEvent:qt});return o(),Me}et(["keyup","keydown"]);var H0=L('<div class="container s-k"><div class="dot s-k"></div> <div class="dot s-k"></div> <div class="dot s-k"></div></div>'),F0={hash:"s-k",code:".container.s-k{display:flex;left:50%;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%)}.dot.s-k:first-child{animation-delay:0s}.dot.s-k:nth-child(2){animation-delay:.18s}.dot.s-k:nth-child(3){animation-delay:.36s}@keyframes s-k-dot_animation{0%{opacity:.2}30%{opacity:1}to{opacity:.2}}.dot.s-k{animation-duration:.75s;animation-iteration-count:infinite;animation-name:s-k-dot_animation;background:var(--btn-color);border-radius:4px;height:8px;width:8px}.dot.s-k+.dot:where(.s-k){margin-left:4px}"};function Ya(i,e){Q(i,F0);let t=h(e,"style",3,"");var o=H0();N(()=>Qe(o,t())),$(i,o)}var U0=Ee('<path d="M5.26 5.26a.9.9 0 0 1 1.28 0L12 10.73l5.46-5.47a.9.9 0 0 1 1.28 1.28L13.27 12l5.47 5.46a.9.9 0 1 1-1.28 1.28L12 13.27l-5.46 5.47a.9.9 0 1 1-1.28-1.28L10.73 12 5.26 6.54a.9.9 0 0 1 0-1.28Z"></path>');function Cm(i,e){Ze(i,{get fill(){return e.fill},children:(t,o)=>{var r=U0();$(t,r)},$$slots:{default:!0}})}var ja=require("@vkontakte/videoplayer-shared/es2015"),z0=i=>{i.stopPropagation()},W0=L("<button><!></button>"),K0={hash:"s-1n",code:"button.btn.s-1n{align-items:center;display:flex;flex-direction:row;height:var(--controls-height);justify-content:center;margin:0;padding:8px;will-change:opacity}button.w-max.s-1n{width:100%}button.btn--live.s-1n{padding:10px 4px}button.btn-jc-l.s-1n{justify-content:left}button.btn-m.s-1n{background-color:rgba(0,0,0,.56);border-radius:12px;height:44px;left:12px;position:absolute;top:50%;transform:translateY(-50%);transition:opacity var(--controls-transition-duration);width:44px}button.btn-m.s-1n,button.btn-m--play.s-1n{align-items:center;display:flex;justify-content:center}button.btn-m--play.s-1n{height:var(--big-play-size);padding:16px;position:relative;width:var(--big-play-size)}button.btn-m--next.s-1n,button.btn-m--prev.s-1n{height:50px;position:absolute;width:50px}button.btn-m--prev.s-1n{right:calc(100% + 35px)}button.btn-m--next.s-1n{left:calc(100% + 35px)}button.btn.s-1n:disabled{cursor:default;pointer-events:none}button.btn.s-1n:not(.btn-full-opacity):disabled{opacity:.4}button.btn.s-1n:not(:disabled):hover{opacity:.8}button.pr-0.s-1n{padding-right:0}button.pl-0.s-1n{padding-left:0}"};function Kt(i,e){B(e,!0),Q(i,K0);let t=h(e,"className",3,""),o=h(e,"style",3,""),r=h(e,"disabled",3,void 0),a=h(e,"testId",3,void 0),l=h(e,"ariaHidden",3,void 0),d=h(e,"ariaLabel",3,void 0),s=h(e,"ref",15,void 0),u=h(e,"ariaKeyShortCut",3,void 0),m=h(e,"ariaExpanded",3,void 0),p=h(e,"tabIndex",3,0),v=h(e,"click",3,ja.noop),b=h(e,"focus",3,ja.noop),y=h(e,"blur",3,ja.noop),_=f(()=>v()===ja.noop?null:A=>{A.stopPropagation(),v()(A)}),x=f(()=>b()===ja.noop?null:A=>{A.preventDefault(),b()()}),I=f(()=>y()===ja.noop?null:A=>{A.preventDefault(),y()()});var C=W0();C.__pointerdown=[z0],C.__click=function(...A){var P;(P=n(_))==null||P.apply(this,A)};var R=T(C);ri(R,()=>{var A;return(A=e.children)!=null?A:$t}),S(C),it(C,A=>s(A),()=>s()),N(()=>{var A,P,E,W,F,U,X,se;oe(C,1,`btn ${(A=t())!=null?A:""}`,"s-1n"),Qe(C,o()||null),C.disabled=(P=r())!=null?P:null,De(C,"aria-hidden",(E=l())!=null?E:null),De(C,"aria-label",(W=d())!=null?W:null),De(C,"aria-keyshortcuts",(F=u())!=null?F:null),De(C,"aria-expanded",(U=m())!=null?U:null),De(C,"data-testid",(X=a())!=null?X:null),De(C,"tabindex",p()),De(C,"role",e.role),De(C,"aria-checked",(se=e.areaChecked)!=null?se:null)}),vt("focus",C,function(...A){var P;(P=n(x))==null||P.apply(this,A)}),vt("blur",C,function(...A){var P;(P=n(I))==null||P.apply(this,A)}),$(i,C),H()}et(["pointerdown","click"]);var q0=(i,e)=>{i.key==="Escape"&&e.onClose(),(i.key==="ArrowUp"||i.key==="ArrowDown")&&i.stopPropagation()},Q0=L('<div class="modal-header s-18"><h3 class="modal-title s-18"> </h3> <!></div>'),G0=L('<div class="modal-overlay s-18"><div class="modal-container s-18" role="dialog" aria-modal="true"><!> <div class="modal-scroll s-18" tabindex="0" role="scrollbar"><div class="modal-main s-18"><!></div></div></div></div>'),Y0={hash:"s-18",code:'.modal-overlay.s-18{align-items:center;background:transparent;bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0;z-index:var(--modal-z-index)}.modal-container.s-18{background:var(--mobile-settings-bg);border-radius:8px;color:var(--white);display:flex;flex-direction:column;height:calc(100% - 24px);max-height:490px;max-width:600px;width:calc(100% - 32px)}.modal-header.s-18{align-items:start;border-bottom:1px solid var(--white-alpha-24);box-sizing:border-box;display:flex;height:40px;justify-content:space-between;padding:8px 10px}.modal-title.s-18{color:var(--white);font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:600;line-height:16px;margin:3px 0 0 6px}.modal-scroll.s-18{height:100%;margin:8px 4px 8px 0;overflow-x:hidden;overflow-y:auto}.modal-scroll.s-18::-webkit-scrollbar{width:8px}.modal-scroll.s-18::-webkit-scrollbar-track{background-color:transparent;border-radius:4px;box-shadow:none;margin-right:2px}.modal-scroll.s-18::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#666;border:1px solid transparent;border-radius:5px;min-height:40px}.modal-scroll.s-18::-webkit-scrollbar-thumb:hover{background-color:#777}.modal-main.s-18{margin:-8px -4px 0 0}'};function Tm(i,e){B(e,!0),Q(i,Y0);let t=h(e,"showHeader",3,!0),o=h(e,"showCloseCross",3,!0),r=K(void 0),a=K(void 0),{webApi:{focusManager:l}}=$e(),d=Y("hotkey_map_modal_close_btn_text");Ot(()=>{var _;return(_=n(r))==null||_.focus(),n(a)&&l&&(l.setContainerForFocusLock(n(a)),l.activateLock()),()=>l==null?void 0:l.deactivateLock()});var s=G0();s.__keydown=[q0,e];var u=T(s),m=T(u);{var p=_=>{var x=Q0(),I=T(x),C=T(I,!0);S(I);var R=k(I,2);{var A=P=>{Kt(P,{get click(){return e.onClose},testId:"close-modal",style:"padding: 0; height: 24px; width: 24px",get ariaLabel(){return d},children:(E,W)=>{Cm(E,{fill:"currentColor"})},$$slots:{default:!0}})};V(R,P=>{o()&&P(A)})}S(x),N(()=>ge(C,e.title)),$(_,x)};V(m,_=>{t()&&_(p)})}var v=k(m,2),b=T(v),y=T(b);ri(y,()=>{var _;return(_=e.children)!=null?_:$t}),S(b),S(v),it(v,_=>O(r,_),()=>n(r)),S(u),it(u,_=>O(a,_),()=>n(a)),S(s),$(i,s),H()}et(["keydown"]);var j0=new Set(["BR"]),xb=i=>{var r;let e=document.createElement("DIV");e.innerHTML=i;let t=e.querySelectorAll("*"),o=t.length;for(;o--;){let a=t[o],l=a.tagName;j0.has(l)||(r=a.parentElement)==null||r.removeChild(a)}return e.innerHTML};var X0=L('<li class="hot-key-map-item s-11"><span class="hot-key-map-item-description s-11"><!></span> <span class="hot-key-map-item-value s-11"> </span></li>'),Z0=L('<div class="hot-key-map-group s-11"><h5 class="hot-key-map-group-title s-11"> </h5> <ul class="hot-key-map-group-items s-11"></ul></div>'),J0=L('<div class="hot-key-map s-11"></div>'),ex={hash:"s-11",code:'.hot-key-map.s-11{box-sizing:border-box;color:var(--black);overflow-x:hidden}.hot-key-map-group.s-11{border-bottom:1px solid var(--white-alpha-24);margin:0 20px 0 16px}.hot-key-map-group.s-11:last-child{border-bottom:none}.hot-key-map-group-title.s-11{color:var(--white);font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:600;line-height:16px}.hot-key-map-group-title.s-11,.hot-key-map-item.s-11{margin:0;padding:12px 0;width:100%}.hot-key-map-group-items.s-11{box-sizing:border-box;list-style:none;margin:0;padding:0}.hot-key-map-item.s-11{align-items:center;box-sizing:border-box;display:flex;justify-content:space-between;--videoplayer-hotkey-item-value-width:156px;--videoplayer-hotkey-item-value-padding-left:24px}.hot-key-map-item-description.s-11{color:var(--white-alpha-72);max-width:388px;width:calc(100% - var(--videoplayer-hotkey-item-value-width) - var(--videoplayer-hotkey-item-value-padding-left))}.hot-key-map-item-value.s-11{color:var(--white);letter-spacing:-.14px;padding-left:var(--videoplayer-hotkey-item-value-padding-left);width:var(--videoplayer-hotkey-item-value-width)}.hot-key-map-item-description.s-11,.hot-key-map-item-value.s-11{font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:400;line-height:16px}'};function Im(i,e){B(e,!1),Q(i,ex);let[t,o]=He(),r=()=>w(l,"$data",t),a=$e(),{data:l,show:d}=a.ui.modals.hotKeyMap,s=()=>{d.set(!1)};on(),Tm(i,{get title(){return r().title},onClose:s,children:(u,m)=>{var p=J0();xi(p,5,()=>r().groups,({title:v,items:b})=>v,(v,b)=>{let y=()=>n(b).title,_=()=>n(b).items;var x=Z0(),I=T(x),C=T(I,!0);S(I);var R=k(I,2);xi(R,5,_,({description:A,value:P})=>P,(A,P)=>{let E=()=>n(P).description,W=()=>n(P).value;var F=X0(),U=T(F),X=T(U);Hd(X,()=>xb(E())),S(U);var se=k(U,2),j=T(se,!0);S(se),S(F),N(()=>ge(j,W())),$(A,F)}),S(R),S(x),N(()=>ge(C,y())),$(v,x)}),S(p),$(u,p)},$$slots:{default:!0}}),H(),o()}var Tv=require("@vkontakte/videoplayer-shared/es2015");var ol=require("@vkontakte/videoplayer-core/es2015");var wb=require("@vkontakte/videoplayer-shared/es2015");var tx=L('<div class="pillow s-1x"><!></div>'),ix={hash:"s-1x",code:".pillow.s-1x{background-color:#679ff8;color:var(--white);font-size:6px;font-weight:600;-webkit-font-smoothing:antialiased;border-radius:12px;padding:2px 4px}"};function Em(i,e){Q(i,ix);var t=tx(),o=T(t);ri(o,()=>{var r;return(r=e.children)!=null?r:$t}),S(t),N(()=>De(t,"data-testid",e.testId)),$(i,t)}var Zl=require("@vkontakte/videoplayer-shared/es2015");var ox=Ee('<svg><!><path d="M5.52 5c.32 0 .51-.2.51-.54V3.5l.5-.51 1.46 1.74c.16.2.3.28.51.28a.5.5 0 0 0 .5-.5c0-.14-.07-.29-.22-.48L7.3 2.3 8.8.87c.16-.14.2-.25.2-.4A.47.47 0 0 0 8.52 0c-.18 0-.3.07-.45.22l-2 2.03h-.04V.54C6.03.2 5.84 0 5.52 0S5 .2 5 .54v3.92c0 .34.2.54.52.54M2.55 1.05 1.05 3.1h1.5zM3.5 3.1V.83C3.5.03 2.41-.3 1.94.35L.14 2.82A.75.75 0 0 0 .75 4h1.8v.55c0 .25.25.45.5.45a.45.45 0 0 0 .45-.45V4h.05a.45.45 0 0 0 0-.9z"></path></svg>');function Pm(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=ox();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(),S(o),$(i,o)}var nx=Ee('<svg><!><path d="M5.51 5c.33 0 .52-.2.52-.54V3.5l.49-.51L7.99 4.7c.16.21.3.29.51.29a.49.49 0 0 0 .5-.5c0-.14-.07-.29-.22-.48L7.29 2.3 8.82.87C8.95.73 9 .62 9 .47A.47.47 0 0 0 8.52 0c-.17 0-.3.07-.44.22L6.06 2.25h-.03V.54C6.03.2 5.83 0 5.5 0S5 .2 5 .54v3.92c0 .34.19.54.51.54M2 0c-.35 0-.67.06-.95.17a1.5 1.5 0 0 0-.66.49c-.15.2-.23.44-.23.7 0 .43.21.76.62 1-.23.11-.41.26-.55.44-.15.2-.23.44-.23.71 0 .29.08.55.25.78.18.23.41.4.71.52.3.13.65.19 1.04.19s.73-.06 1.03-.19c.3-.12.54-.3.71-.52a1.26 1.26 0 0 0 .03-1.49 1.45 1.45 0 0 0-.55-.44c.4-.23.62-.57.62-1a1.14 1.14 0 0 0-.24-.7 1.44 1.44 0 0 0-.66-.49A2.4 2.4 0 0 0 2 0m-.57.96C1.56.86 1.75.8 2 .8s.43.06.56.16a.51.51 0 0 1 .2.43c0 .2-.06.34-.2.44A.87.87 0 0 1 2 2a.9.9 0 0 1-.57-.16.52.52 0 0 1-.2-.44c0-.18.06-.32.2-.43ZM1.08 3.5a.6.6 0 0 1 .24-.5c.16-.13.38-.2.68-.2s.52.07.68.2a.6.6 0 0 1 .24.5.63.63 0 0 1-.24.52c-.16.12-.38.19-.68.19s-.52-.07-.68-.19a.64.64 0 0 1-.24-.52"></path></svg>');function km(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=nx();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(),S(o),$(i,o)}var rx=Ee('<svg><!><path d="M5.52 5h1.1C8.1 5 9 4.07 9 2.5S8.1 0 6.62 0h-1.1C5.19 0 5 .2 5 .54v3.92c0 .34.2.54.52.54m.51-.85V.85h.47C7.41.85 8 1.47 8 2.5c0 1.07-.58 1.65-1.5 1.65zM.52 5c.32 0 .51-.2.51-.54V2.92h1.94v1.54c0 .34.19.54.51.54S4 4.8 4 4.46V.54C4 .2 3.8 0 3.48 0s-.51.2-.51.54v1.53H1.03V.54C1.03.2.84 0 .52 0S0 .2 0 .54v3.99c0 .34.2.47.52.47"></path></svg>');function Am(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=rx();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(),S(o),$(i,o)}var sx=Ee('<svg><!><path d="M9.52 5h1.1C12.1 5 13 4.07 13 2.5S12.1 0 10.62 0h-1.1C9.19 0 9 .2 9 .54v3.92c0 .34.2.54.52.54m.51-.85V.85h.47c.91 0 1.5.62 1.5 1.65 0 1.07-.58 1.65-1.5 1.65zM4.52 5c.32 0 .51-.2.51-.54V2.92h1.94v1.54c0 .34.19.54.51.54S8 4.8 8 4.46V.54C8 .2 7.8 0 7.48 0s-.51.2-.51.54v1.53H5.03V.54C5.03.2 4.84 0 4.52 0S4 .2 4 .54v3.99c0 .34.2.47.52.47m-4 0c.32 0 .51-.2.51-.54V3h1.33c.27 0 .45-.15.45-.41 0-.25-.18-.4-.45-.4H1.03V.84h1.5C2.81.85 3 .7 3 .43S2.8 0 2.53 0H.52C.19 0 0 .2 0 .54v3.92C0 4.8.2 5 .52 5"></path></svg>');function Lm(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=sx();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"13",height:"5",fill:"currentColor",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(),S(o),$(i,o)}var ax=Ee('<svg><!><path d="M11.52 5.75h1.1c1.48 0 2.38-.94 2.38-2.5s-.9-2.5-2.38-2.5h-1.1c-.33 0-.52.2-.52.54V5.2c0 .34.2.54.52.54Zm.51-.85V1.6h.47c.91 0 1.5.62 1.5 1.65 0 1.07-.58 1.65-1.5 1.65zm-5.51.85c.32 0 .51-.2.51-.54V3.67h1.94v1.54c0 .34.19.54.51.54s.52-.2.52-.54V1.3c0-.34-.2-.54-.52-.54s-.51.2-.51.54v1.53H7.03V1.3c0-.34-.19-.54-.51-.54S6 .95 6 1.29v3.99c0 .34.2.47.52.47m-3.18-.09a4 4 0 0 1-.84.09C1.04 5.75 0 4.88 0 3.3 0 1.73 1.04.75 2.5.75S5 1.73 5 3.3c0 .87-.27 1.46-.78 1.88l.2.3a.5.5 0 0 1-.84.55zm-.52-.78-.24-.35a.5.5 0 1 1 .84-.56l.24.37c.18-.26.29-.62.29-1.04 0-1.03-.64-1.65-1.45-1.65s-1.45.62-1.45 1.65.64 1.6 1.45 1.6c.08 0 .2 0 .32-.02"></path></svg>');function Mm(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=ax();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"15",height:"7",fill:"currentColor",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(),S(o),$(i,o)}var sp=i=>{switch(i){case Zl.VideoQuality.Q_720P:return Am;case Zl.VideoQuality.Q_1080P:return Lm;case Zl.VideoQuality.Q_1440P:return Mm;case Zl.VideoQuality.Q_2160P:return Pm;case Zl.VideoQuality.Q_4320P:return km}};var lx=Ee('<path d="M12.72 2.21q1.8.07 2.41 1.96l.06.21.06.2.06.23.06.16.04.01.06-.02.14-.05.15-.07c1.42-.66 2.5-.53 3.4.44l.12.14.82 1.02c.73.96.7 2 0 3.1l-.13.19-.12.16-.14.2-.07.12-.04.05v.03l.1.06.13.07.15.09c1.39.7 1.96 1.64 1.74 2.93l-.04.19-.24 1.06c-.16.68-.28 1-.77 1.45-.48.43-1.02.61-1.73.67l-.22.02h-.2l-.25.02-.18.02.02.14v.1l.04.17c.32 1.53-.04 2.56-1.19 3.2l-.17.1-1.17.57q-1.64.73-3.02-.7l-.15-.17-.13-.15-.17-.19-.1-.1-.05-.04-.1.09-.1.1-.12.14c-.95 1.13-1.95 1.54-3.17 1.07l-.18-.08-1.05-.5-.31-.17a2 2 0 0 1-1-1.06 3 3 0 0 1-.16-1.88l.04-.23.04-.24.02-.17-.1-.02-.15-.01h-.18c-1.56-.04-2.48-.62-2.85-1.89l-.05-.18-.3-1.28q-.33-1.77 1.37-2.78l.2-.11.17-.1.22-.12.15-.1v-.02l-.06-.1-.08-.13-.1-.14c-.94-1.25-1.04-2.34-.28-3.4L4 6.32l.82-1.01c.8-.92 1.8-1.1 3.04-.64l.2.08.19.08.22.1.13.04.04-.01.03-.1.05-.13.04-.17c.36-1.43 1.09-2.24 2.4-2.35h1.58Zm-.05 1.8h-1.34l-.14.01c-.28.04-.47.2-.65.83l-.04.16-.06.2a6 6 0 0 1-.46 1.14 6 6 0 0 0-1.15.56 7 7 0 0 1-1.16-.35l-.35-.16q-.37-.15-.59-.17h-.08a.6.6 0 0 0-.4.19l-.08.07-.78.98-.1.12c-.18.26-.2.5.2 1.08l.22.31q.34.48.6 1.1-.2.59-.27 1.2-.51.45-1.01.73l-.34.18c-.62.34-.7.56-.65.88l.01.08.28 1.21.04.16c.1.3.27.47.97.5l.39.02q.57.03 1.22.2.35.53.78.97a6 6 0 0 1-.12 1.45c-.2.95-.01 1.1.38 1.3l1.13.54a1 1 0 0 0 .34.1l.06-.01q.26-.03.67-.49l.26-.3q.4-.42.95-.83l.3.02.3.01h.3l.3-.03q.56.4.95.84l.26.3c.32.36.53.48.73.48h.07l.18-.05.09-.04 1.13-.54.14-.08c.3-.17.42-.4.24-1.22a6 6 0 0 1-.12-1.45q.44-.45.78-.97a7 7 0 0 1 1.22-.2l.39-.01c.81-.04.91-.26 1-.66l.27-1.15c.09-.4.1-.64-.62-1.03l-.34-.18a6 6 0 0 1-1.01-.73 6 6 0 0 0-.27-1.2q.26-.62.6-1.1l.22-.31c.4-.58.38-.81.2-1.08l-.05-.06-.78-.97c-.14-.18-.26-.3-.46-.33h-.07q-.23 0-.67.17l-.35.16a6 6 0 0 1-1.16.35 6 6 0 0 0-1.15-.56 7 7 0 0 1-.45-1.1l-.11-.4c-.2-.68-.4-.81-.72-.83zM12 8.2a3.8 3.8 0 1 1 0 7.6 3.8 3.8 0 0 1 0-7.6m0 1.8a2 2 0 1 0 0 4 2 2 0 0 0 0-4"></path>');function Vm(i,e){Ze(i,{get testId(){return e.testId},children:(t,o)=>{var r=lx();$(t,r)},$$slots:{default:!0}})}var dx=Ee('<path d="M13.25 2.83c.23.75.38 1.5 1.63 2.23 1.4.38 2.08 0 2.72-.42.66-.45.86-.32 1.12-.06l.65.64c.29.3.4.42 0 1.18-.38.7-.8 1.33-.42 2.73.72 1.25 1.47 1.47 2.22 1.62.78.16.83.39.83.76v.9c0 .42 0 .59-.83.84-.75.23-1.5.38-2.23 1.63-.38 1.4 0 2.08.42 2.72.45.66.32.86.06 1.12l-.64.65c-.3.29-.42.4-1.18 0-.7-.38-1.34-.8-2.73-.42-1.25.72-1.47 1.47-1.62 2.22-.16.78-.39.83-.76.83h-.9c-.42 0-.59 0-.84-.83-.23-.75-.38-1.5-1.63-2.23-1.4-.38-2.08 0-2.72.42-.66.45-.86.32-1.12.06l-.65-.64c-.29-.3-.4-.42 0-1.18.38-.7.8-1.34.42-2.73-.72-1.25-1.47-1.47-2.22-1.62-.78-.16-.83-.39-.83-.76v-.9c0-.42 0-.59.83-.84.75-.23 1.5-.38 2.22-1.63.38-1.4 0-2.08-.42-2.72-.44-.66-.31-.86-.05-1.12l.64-.65c.3-.29.42-.4 1.18 0 .7.38 1.33.8 2.73.42 1.25-.72 1.47-1.47 1.62-2.22.16-.78.39-.83.76-.83h.9c.42 0 .59 0 .84.83M12 7.25a4.75 4.75 0 1 0 0 9.5 4.75 4.75 0 0 0 0-9.5"></path>');function Rm(i,e){Ze(i,{get testId(){return e.testId},children:(t,o)=>{var r=dx();$(t,r)},$$slots:{default:!0}})}var cx=L('<div aria-hidden="true"><!> <!></div>'),ux={hash:"s-1u",code:".icon.s-1u{display:flex;height:24px;position:relative;width:24px}.icon.s-1u .pillow{position:absolute;right:-9px;top:1px}.icon.triple.s-1u .pillow{right:-13px}.icon.s-1u svg[data-testid=settings-icon--labeled] ._full{opacity:0;visibility:hidden}"};function lc(i,e){B(e,!0),Q(i,ux);let t=h(e,"isMobile",3,!1),o=h(e,"currentQuality",3,void 0),r=f(()=>o()?(0,wb.getVideoQualityLabel)(o()):""),a=f(()=>sp(o())),l=f(()=>n(r).length>2);var d=Oe(),s=le(d);{var u=p=>{Vm(p,{testId:"settings-mobile-icon"})},m=p=>{var v=cx();let b;var y=T(v);{var _=C=>{let R=f(()=>`${n(r)}-pill-icon`);Em(C,{get testId(){return n(R)},children:(A,P)=>{var E=Oe(),W=le(E);Hi(W,()=>n(a),(F,U)=>{U(F,{})}),$(A,E)},$$slots:{default:!0}})};V(y,C=>{n(a)&&C(_)})}var x=k(y,2);let I=f(()=>n(a)?"settings-icon--labeled":"settings-icon");Rm(x,{get testId(){return n(I)}}),S(v),N(C=>b=oe(v,1,"icon s-1u",null,b,C),[()=>({triple:n(l)})]),$(p,v)};V(s,p=>{t()?p(u):p(m,!1)})}$(i,d),H()}var px=L('<span class="settings-icon-wrapper s-1y"><!></span>'),fx={hash:"s-1y",code:".settings-icon-wrapper.s-1y{position:relative;width:24px}"};function Jl(i,e){B(e,!0),Q(i,fx);let[t,o]=He(),r=()=>w(u,"$settingsMenuVisible",t),a=()=>w(v,"$isMobile",t),l=()=>w(s,"$currentQuality",t),d=$e(),s=d.state.currentQuality$,u=d.ui.settingsMenu.visible$,m=d.actions.internal.openSettingsMenu,p=d.actions.internal.closeSettingsMenu,v=d.ui.isMobile,b=d.ui.t,y=K(void 0);Fe(()=>{n(y)&&Et(()=>{e.ref$.set(n(y))})});let _=b("aria_label_settings");function x(C){return bt(this,null,function*(){let R=fa(C);r()?p():m(R,_o)})}let I=f(()=>r()?"opened":"");Kt(i,{get className(){return n(I)},testId:"settings-btn",click:x,get ariaLabel(){return _},get ariaExpanded(){return r()},get ref(){return n(y)},set ref(C){O(y,C,!0)},children:(C,R)=>{var A=px(),P=T(A);lc(P,{get isMobile(){return a()},get currentQuality(){return l()}}),S(A),$(C,A)},$$slots:{default:!0}}),H(),o()}var mx=Ee('<path d="M6.56 4.44a1.5 1.5 0 1 0-2.12 2.12l3.09 3.09a11 11 0 0 0-2.39 3.08 11 11 0 0 0-1.01 4.14C4 18.43 4 20.37 4 22.83v2.34c0 2.46 0 4.4.13 5.96.13 1.6.4 2.93 1.01 4.14a10.5 10.5 0 0 0 4.6 4.59c1.2.61 2.53.88 4.13 1.01 1.56.13 3.5.13 5.96.13h8.34c2.46 0 4.4 0 5.96-.13 1.44-.12 2.66-.35 3.78-.84l3.53 3.53a1.5 1.5 0 0 0 2.12-2.12zM13.5 28a1.5 1.5 0 0 0 0 3h11a1.5 1.5 0 0 0 0-3zM12 22a1.5 1.5 0 0 1 1.5-1.5h4a1.5 1.5 0 0 1 0 3h-4A1.5 1.5 0 0 1 12 22"></path><path d="M34.5 23.5h-4.64l12.55 12.55q.23-.37.45-.78a11 11 0 0 0 1.01-4.14c.13-1.56.13-3.5.13-5.96v-2.34c0-2.46 0-4.4-.13-5.96a11 11 0 0 0-1.01-4.14 10.5 10.5 0 0 0-4.6-4.59 11 11 0 0 0-4.13-1.01C32.57 7 30.63 7 28.17 7h-8.34c-2.46 0-4.4 0-5.96.13l-.35.03L26.86 20.5h7.64a1.5 1.5 0 0 1 0 3"></path>',1),vx=Ee("<path></path>");function ga(i,e){B(e,!0);let t=f(()=>`subtitles-icon${e.type==="off"?"-off":e.type==="outline"?"-outline":""}`),o=f(()=>vn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(o)},get testId(){return n(t)},get shadow(){return e.shadow},children:(r,a)=>{var l=Oe(),d=le(l);{var s=m=>{var p=mx();ni(),$(m,p)},u=m=>{var p=vx();N(()=>De(p,"d",`M16.92 8h14.16q2.82-.02 4.66.1c1.28.1 2.4.32 3.46.86a8.8 8.8 90 013.84 3.84c.54 1.04.76 2.18.86 3.46q.12 1.84.1 4.66v6.16q.02 2.82-.1 4.66a10 10 90 01-.86 3.46 8.8 8.8 90 01-3.84 3.84 10 10 90 01-3.46.86q-1.84.12-4.66.1H16.92q-2.82.02-4.66-.1a10 10 90 01-3.46-.86 8.8 8.8 90 01-3.84-3.84 10 10 90 01-.86-3.46Q4 29.9 4 27.08v-6.16q-.02-2.82.1-4.66c.1-1.28.32-2.4.86-3.46A8.8 8.8 90 018.8 8.96a10 10 90 013.46-.86Q14.1 8 16.92 8
|
|
59
59
|
${e.type==="outline"?"M12.54 11.68c-1.04.1-1.64.26-2.1.48a5.2 5.2 90 00-2.28 2.28c-.22.46-.4 1.06-.48 2.1-.08 1.08-.08 2.46-.08 4.46v6c0 2 0 3.38.08 4.46.1 1.04.26 1.64.48 2.1q.78 1.5 2.28 2.28c.46.22 1.06.4 2.1.48 1.08.08 2.48.08 4.46.08h14c2 0 3.38 0 4.46-.08 1.04-.1 1.64-.26 2.1-.48a5.2 5.2 90 002.28-2.28c.22-.46.4-1.06.48-2.1.08-1.08.08-2.48.08-4.46v-6c0-2 0-3.38-.08-4.46a6 6 90 00-.48-2.1 5.2 5.2 90 00-2.28-2.28c-.46-.22-1.06-.4-2.1-.48-1.08-.08-2.48-.08-4.46-.08h-14c-2 0-3.38 0-4.46.08":""}
|
|
60
|
-
M12 29.8c0-1 .8-1.8 1.8-1.8h10.4a1.8 1.8 90 010 3.6H13.8a1.8 1.8 90 01-1.8-1.8m0-7.6c0-1 .8-1.8 1.8-1.8h3.4a1.8 1.8 90 110 3.6H13.8a1.8 1.8 90 01-1.8-1.8m17 7.6c0-1 .8-1.8 1.8-1.8h3.4a1.8 1.8 90 110 3.6h-3.4a1.8 1.8 90 01-1.8-1.8M22 22.2c0-1 .8-1.8 1.8-1.8h10.4a1.8 1.8 90 010 3.6h-10.4a1.8 1.8 90 01-1.8-1.8`)),$(m,p)};V(d,m=>{e.type==="off"?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}}),H()}function Om(i,e){B(e,!0);let t=h(e,"isSubtitlesEnabled",3,!1),r=be().ui.t,a=f(()=>t()?r("tooltip_subtitles_on"):r("tooltip_subtitles_off"));Kt(i,{testId:"subtitles-btn",get ariaLabel(){return n(a)},get click(){return e.click},get ariaKeyShortCut(){return bs.KeyC},role:"button",children:(l,d)=>{let s=f(()=>t()?void 0:"outline");ga(l,{get size(){return"24"},get type(){return n(s)}})},$$slots:{default:!0}}),H()}var vx=L('<span class="duration s-20" data-testid="video_duration"> </span>'),gx=L('<div data-testid="time"><span class="current s-20" data-testid="current_time"> </span> <!></div>'),hx={hash:"s-20",code:'.time.s-20{align-items:center;color:var(--controls-time);display:flex;font-variant-numeric:tabular-nums;font-weight:500;padding:12px 6px}.time.mobile.s-20{padding:0 0 0 8px}.current.s-20{position:relative}.duration.s-20{opacity:.7}.duration.s-20:before{content:" / ";white-space:pre}'};function uc(i,e){B(e,!0),Q(i,hx);let t=h(e,"isMobile",3,!1),o=h(e,"isHidden",3,!1),r=h(e,"showDuration",3,!0),a=h(e,"ref",15),l=Ot(),d=de(!1),s=f(()=>en(e.duration)),u=f(()=>en(e.position));var m=gx();let p;var v=C(m),b=C(v,!0);S(v);var y=k(v,2);{var _=x=>{var I=vx(),T=C(I,!0);S(I),O(()=>ve(T,n(s))),$(x,I)};V(y,x=>{r()&&x(_)})}S(m),Os(m,()=>Gl(o()&&l.features.usePerformanceFix,d,l.disableInvisibleComponentsTimeout)),Xe(m,x=>a(x),()=>a()),O(x=>{p=oe(m,1,"time s-20",null,p,x),ve(b,n(u))},[()=>({mobile:t()})]),$(i,m),H()}var fc=require("@vkontakte/videoplayer-shared/es2015");var _x=Ie('<path d="M21.8632 10.0832C22.2147 9.73171 22.7852 9.73171 23.1367 10.0832C23.4881 10.4347 23.4881 11.0051 23.1367 11.3566L18.6367 15.8566C18.2852 16.2081 17.7147 16.2081 17.3632 15.8566C17.0117 15.5051 17.0117 14.9347 17.3632 14.5832L21.8632 10.0832Z"></path><path d="M17.3632 11.3566C17.0117 11.0051 17.0117 10.4347 17.3632 10.0832C17.7147 9.73171 18.2852 9.73171 18.6367 10.0832L23.1367 14.5832C23.4881 14.9347 23.4881 15.5051 23.1367 15.8566C22.7852 16.2081 22.2147 16.2081 21.8632 15.8566L17.3632 11.3566Z"></path>',1),bx=Ie("<path></path>"),$x=Ie('<path d="M14 3.96997C14.5523 3.96997 15 4.41769 15 4.96997V20.97C15 21.5223 14.5523 21.97 14 21.97C13.3585 21.97 12.7422 21.7208 12.2808 21.2751L6.79013 15.97H4C2.89543 15.97 2 15.0745 2 13.97V11.97C2 10.8654 2.89543 9.96997 4 9.96997H6.765L12.2794 4.66337C12.7417 4.21849 13.3584 3.96997 14 3.96997Z"></path><!>',1);function ha(i,e){B(e,!0);let t=h(e,"volume",3,1),o=h(e,"muted",3,!1),r=(u,m)=>m?"off":u>.5?"max":u>.2?"mid":u>0?"min":"off",a=f(()=>r(t(),o())),l=f(()=>fn(e.size)),d="M16.8748 8.85259C17.2324 8.50731 17.8021 8.51726 18.1474 8.87481C18.5465 9.28803 18.8614 9.77691 19.0757 10.3128C19.2901 10.8486 19.4 11.4218 19.4 12C19.4 12.5782 19.2901 13.1514 19.0757 13.6872C18.8614 14.2231 18.5465 14.712 18.1474 15.1252C17.8021 15.4827 17.2324 15.4927 16.8748 15.1474C16.5173 14.8021 16.5073 14.2324 16.8526 13.8748C17.0876 13.6314 17.2757 13.3408 17.4045 13.0187C17.5333 12.6966 17.6 12.3504 17.6 12C17.6 11.6496 17.5333 11.3034 17.4045 10.9813C17.2757 10.6592 17.0876 10.3686 16.8526 10.1252C16.5073 9.76764 16.5173 9.19788 16.8748 8.85259Z",s="M19.2636 6.2636C19.6151 5.91213 20.1849 5.91213 20.5364 6.2636C21.2516 6.97878 21.9929 7.99659 22.3989 8.97678C22.7959 9.93525 23.0003 10.9625 23.0003 12C23.0003 13.0374 22.7959 14.0647 22.3989 15.0232C21.9929 16.0034 21.2516 17.0212 20.5364 17.7364C20.1849 18.0879 19.6151 18.0879 19.2636 17.7364C18.9121 17.3849 18.9121 16.8151 19.2636 16.4636C19.8484 15.8788 20.4384 15.0527 20.7359 14.3343C21.0425 13.5943 21.2003 12.801 21.2003 12C21.2003 11.1989 21.0425 10.4057 20.7359 9.66561C20.4384 8.94724 19.8484 8.12124 19.2636 7.5364C18.9121 7.18492 18.9121 6.61508 19.2636 6.2636Z";Ze(i,{get style(){return n(l)},get testId(){var u;return`volume-${(u=n(a))!=null?u:""}-icon`},get shadow(){return e.shadow},children:(u,m)=>{var p=$x(),v=k(ue(p));{var b=_=>{var x=_x();pi(),$(_,x)},y=_=>{var x=bx();O(()=>Re(x,"d",`${d}${n(a)==="max"?s:""}`)),$(_,x)};V(v,_=>{n(a)==="off"?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}var Oo=require("@vkontakte/videoplayer-shared/es2015");var dp=require("@vkontakte/videoplayer-shared/es2015");var Cb=require("@vkontakte/videoplayer-shared/es2015");var yx=L('<div class="overlay"><!></div>');function Bm(i,e){B(e,!0);let[t,o]=De(),r=()=>w(l,"$overlayContainer$",t),l=be().ui.overlayContainer$,d=q(void 0),s=v=>{!v||!n(d)||!v.contains(n(d))||v.removeChild(n(d))},u=v=>{!v||!n(d)||v.contains(n(d))||v.appendChild(n(d))};Oe(()=>{u(r())}),Dt(()=>(u(r()),()=>s(r())));var m=yx(),p=C(m);ri(p,()=>{var v;return(v=e.children)!=null?v:_t}),S(m),Xe(m,v=>N(d,v),()=>n(d)),$(i,m),H(),o()}var xx=L('<div class="tooltip s-1r"><div class="content s-1r"> </div> <div class="tooltip-pointer s-1r"></div></div>'),wx=L("<div><!></div> <!>",1),Sx={hash:"s-1r",code:'.tooltip-wrapper.s-1r{display:flex;flex-direction:column;min-width:0}.full-width.s-1r{width:100%}.tooltip.s-1r{bottom:100%;left:0;opacity:0;position:absolute;transition:opacity .2s,visibility .2s;visibility:hidden}.content.s-1r{background-color:rgba(41,41,41,.8);border-radius:3px;color:var(--white);display:inline-block;padding:6px 10px}.tooltip-pointer.s-1r{border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid rgba(41,41,41,.8);bottom:0;content:" ";font-size:0;line-height:0;position:absolute;width:0}'};function Ja(i,e){B(e,!0),Q(i,Sx);let[t,o]=De(),r=()=>w(X,"$overlayContainer$",t),a=()=>w(U,"$containerSize",t),l=h(e,"isMobile",3,!1),d=h(e,"content",3,""),s=h(e,"active",15,!1),u=h(e,"translateX",3,0),m=h(e,"translateY",3,0),p=h(e,"isFullWidthWrapper",3,!1),v=h(e,"maxTooltipWidth",3,void 0),b=h(e,"placement",3,"top"),y=h(e,"onVisibilityChange",3,Cb.noop),_=5,x=q(void 0),I=q(void 0),T,R=q(0),A=q(0),P=q(0),E=q(0),z=Ot(),F=be(),U=F.ui.playerSize,X=F.ui.overlayContainer$;Oe(()=>{Pt(()=>{y()(s())})});let ae=F.getLogger().createComponentLog("Tooltip component"),Z=()=>{if(!r()||!n(I)||!n(x))return;N(A,_);let ne=r().getBoundingClientRect(),ce=n(x).getBoundingClientRect(),Ne=ce.width,Le=n(I).clientWidth,et=a().width,Ee=(Ne-Le)/2,Te=ce.left+u()-ne.left,Fe=Te+Ee,kt=ce.top+m()-ne.top,Tt=Le/2-_,Vt=Fe<8,pt=Fe+Le>et-8;Vt&&(Fe=8,Tt=Te+ce.width/2-2.5*_),pt&&(Fe=et-8-Le,Tt=ce.left-ne.left+ce.width/2-Fe-_),N(P,Fe,!0),N(E,kt),N(R,Tt,!0)},re=()=>{!r()||!n(I)||!n(x)||N(A,-_)},J=()=>{if(!r()||!n(I)||!n(x))return;N(R,_);let ne=r().getBoundingClientRect(),ce=n(x).getBoundingClientRect(),Ne=ce.height,Le=n(I).clientHeight,et=(Ne-Le)/2+Le,Ee=ce.left+u()-ne.left-n(I).clientWidth,Te=2,Fe=Ee-_;Fe<8&&(Fe=8);let Tt=ce.top+m()-ne.top+et,Vt=Te-et/2,pt=Te-_;N(P,Fe,!0),N(E,Tt),N(A,Vt),N(R,pt)},we=()=>{!r()||!n(I)||!n(x)||N(R,-_)},me=()=>{switch(b()){case"top":Z();break;case"bottom":re();break;case"left":J();break;default:we()}},ee=()=>{try{if(!r()||!n(x))return;me(),s(!0)}catch(ne){ae({message:String(ne)})}},_e=()=>{s(!1)},Ce=()=>{n(I)&&(T||(T=window.setTimeout(ee,z.controls.hideTimeoutTooltips)),s()&&ee())},ge=()=>{_e(),window.clearTimeout(T),T=void 0},pe=(ne,ce,Ne)=>{let Le="";switch(b()){case"top":Le=`transform: translate(${ne}px, ${ce}px);`;break;case"bottom":Le=`transform: translate(${ne}px, ${ce}px); top: auto; bottom: 100%;`;break;case"left":Le=`transform: translate(${ne}px, ${ce}px); left: 0; right: auto;`;break;default:Le=`transform: translate(${ne}px, ${ce}px);`}return Le+=` max-width: ${v()===void 0?"auto":`${v()}px`};`,Le+=` opacity: ${Ne?1:0}; visibility: ${Ne?"visible":"hidden"}`,Le},Qe=(ne,ce)=>{let Ne="";switch(b()){case"top":Ne=`transform: translate(${ne}px, ${ce}px) rotate(0); top: auto; bottom: 0;`;break;case"bottom":Ne=`transform: translate(${ne}px, ${ce}px) rotate(180deg); top: 0; bottom: auto;`;break;case"left":Ne=`transform: translate(${ne}px, ${ce}px) rotate(-90deg); left: 100%; top: auto; bottom: 0;`;break;default:Ne=`transform: translate(${ne}px, ${ce}px) rotate(90deg); right: 100%; top: auto; bottom: 0;`}return Ne},G=f(()=>pe(n(P),n(E),s())),D=f(()=>Qe(n(R),n(A)));Dt(me),pn(()=>window.clearTimeout(T));var Ge=wx(),K=ue(Ge);let se;K.__pointermove=Ce,K.__pointerdown=ge,K.__pointerup=function(...ne){var ce;(ce=e.disableMouseupTooltipShow?void 0:Ce)==null||ce.apply(this,ne)};var xe=C(K);ri(xe,()=>{var ne;return(ne=e.children)!=null?ne:_t}),S(K),Xe(K,ne=>N(x,ne),()=>n(x));var He=k(K,2);{var it=ne=>{Bm(ne,{children:(ce,Ne)=>{var Le=xx(),et=C(Le),Ee=C(et,!0);S(et);var Te=k(et,2);S(Le),Xe(Le,Fe=>N(I,Fe),()=>n(I)),O(()=>{qe(Le,n(G)),ve(Ee,d()),qe(Te,n(D))}),$(ce,Le)},$$slots:{default:!0}})};V(He,ne=>{d()&&!l()&&ne(it)})}O(ne=>se=oe(K,1,"tooltip-wrapper s-1r",null,se,ne),[()=>({"full-width":p()})]),ut("pointerenter",K,Ce),ut("pointerleave",K,ge),$(i,Ge),H(),o()}Ye(["pointermove","pointerdown","pointerup"]);var Tb=i=>{i.stopPropagation()},Cx=L("<div><!></div>"),Tx={hash:"s-1n",code:".btn-container.s-1n{align-items:center;display:flex;height:100%;position:relative;transition:var(--button-hover-transition);will-change:opacity;-webkit-tap-highlight-color:transparent}.w-max.s-1n{min-width:0;width:100%}"};function Do(i,e){B(e,!0),Q(i,Tx);let[t,o]=De(),r=()=>w(u,"$isGraphOpened$",t),a=()=>w(s,"$isMobile",t),l=be(),d=yo(),s=l.ui.isMobile,u=d.graphIsOpened$,m=l.ui.t,p=h(e,"className",3,""),v=h(e,"disabled",3,!1),b=h(e,"hasTooltip",3,!0),y=h(e,"ref",15,void 0),_=h(e,"width",15,void 0),x=h(e,"isFullWidthTooltip",3,!0),I=h(e,"tooltipContent",3,""),T=h(e,"tooltipVisible",3,!1),R=h(e,"tooltipPlacement",3,"top"),A=h(e,"disabledTooltipContent",19,()=>m("tooltip_button_disabled")),P=h(e,"isAriaHidden",3,!1),E=h(e,"onTooltipVisibilityChange",3,dp.noop),z=h(e,"initialTranslateXPx",3,0),F=h(e,"initialTranslateYPx",19,()=>-18),U=h(e,"mouseEnter",3,dp.noop),X=h(e,"mouseLeave",3,dp.noop),ae=f(()=>v()?r()?m("tooltip_disabled_when_graph_on"):A():I()),Z=q(!1);Oe(()=>{T()||N(Z,!1)});var re=Cx();re.__pointerdown=[Tb],re.__click=[Tb];var J=C(re);{var we=ee=>{Ja(ee,{get content(){return n(ae)},get translateX(){return z()},get translateY(){return F()},get isFullWidthWrapper(){return x()},get placement(){return R()},get onVisibilityChange(){return E()},get disableMouseupTooltipShow(){return e.disableMouseupTooltipShow},get active(){return n(Z)},set active(_e){N(Z,_e,!0)},children:(_e,Ce)=>{var ge=Me(),pe=ue(ge);ri(pe,()=>{var Qe;return(Qe=e.children)!=null?Qe:_t}),$(_e,ge)},$$slots:{default:!0}})},me=ee=>{var _e=Me(),Ce=ue(_e);ri(Ce,()=>{var ge;return(ge=e.children)!=null?ge:_t}),$(ee,_e)};V(J,ee=>{b()&&n(ae)&&!a()?ee(we):ee(me,!1)})}S(re),Xe(re,ee=>y(ee),()=>y()),O(()=>{var ee;oe(re,1,`btn-container ${(ee=p())!=null?ee:""}`,"s-1n"),Re(re,"aria-hidden",P()||null)}),ut("mouseenter",re,function(...ee){var _e;(_e=U())==null||_e.apply(this,ee)}),ut("mouseleave",re,function(...ee){var _e;(_e=X())==null||_e.apply(this,ee)}),Rn(re,"clientWidth",_),$(i,re),H(),o()}Ye(["pointerdown","click"]);var Ix=Ie('<rect width="20" height="20" rx="10"></rect><path d="m12.53 8.69.06.19-.22-.64a.83.83 0 0 0-1.6.47l.13.48-.23-.85a.82.82 0 0 0-1.6.24l-.73-2.93a.85.85 0 0 0-1.65.4L8 11.34l-1.12-1.16a.8.8 0 0 0-1.21 1.03l2.23 2.94s1.23 1.83 4.3 1.23c2.43-.48 3.25-2.67 2.58-4.88l-.55-2.3a.88.88 0 1 0-1.7.49"></path>',1);function pc(i,e){let t=f(()=>(e.completed,"interactive-episode-completed-icon"));Ze(i,{width:"20",height:"20",fill:"none",get testId(){return n(t)},children:(o,r)=>{var a=Ix(),l=ue(a),d=k(l);O(()=>{Re(l,"fill",da),Re(l,"fill-opacity",e.completed?1:.24),Re(d,"fill",e.completed?"var(--interactive-episode-complete)":"white")}),$(o,a)},$$slots:{default:!0}})}var Ex=L("<div><!></div>"),Px={hash:"s-1e",code:".interactive-episode-icon.s-1e{cursor:default;height:20px;position:absolute;transform:translateX(-50%);width:20px}.interactive-episode-icon.disabled.s-1e{opacity:.4;pointer-events:none}"};function Hm(i,e){B(e,!0),Q(i,Px);let o=be().ui.t,r=q(0),a=f(()=>o(e.videoEpisode.completed?"tooltip_episode_finished":"tooltip_episode_unfinished"));Do(i,{get tooltipContent(){return n(a)},initialTranslateXPx:-10,initialTranslateYPx:-10,get disabled(){return e.disabled},get width(){return n(r)},isAriaHidden:!0,isFullWidthTooltip:!1,children:(l,d)=>{var s=Ex();let u;var m=C(s);let p=f(()=>!!e.videoEpisode.completed);pc(m,{get completed(){return n(p)}}),S(s),O(v=>{u=oe(s,1,"interactive-episode-icon s-1e",null,u,v),qe(s,`left: ${e.videoEpisode.from+e.videoEpisode.width/2}%`)},[()=>({disabled:e.disabled})]),Rn(s,"clientWidth",v=>N(r,v)),$(l,s)},$$slots:{default:!0}}),H()}var kx=L('<div><div class="video-episode-inner s-1d"><div class="video-episode-loaded s-1d"></div> <div></div></div></div>'),Ax=L('<div class="video-episodes-wrap s-1d"></div>'),Lx={hash:"s-1d",code:".video-episodes-wrap.s-1d{height:100%;position:absolute;width:100%}.video-episode.s-1d{box-sizing:border-box;height:calc(var(--slider-height)*3);margin-top:calc(var(--slider-height)*-1);padding:var(--slider-height) var(--slider-video-episode-gap);position:absolute;transition:transform .2s}.video-episode.s-1d:first-child{padding-left:0}.video-episode.s-1d:last-child{padding-right:0}.video-episode.s-1d:not(.disabled):where(:hover,:active){transform:scaleY(1.5)}.video-episode-filled.s-1d,.video-episode-inner.s-1d,.video-episode-loaded.s-1d{border-radius:var(--slider-radius);height:var(--slider-height);position:absolute}.video-episode-inner.s-1d{background:var(--slider-bg);overflow:hidden;position:absolute;width:calc(100% - var(--slider-video-episode-gap)*2)}.video-episode.s-1d:first-child .video-episode-inner:where(.s-1d),.video-episode.s-1d:last-child .video-episode-inner:where(.s-1d){width:calc(100% - var(--slider-video-episode-gap))}.video-episode-loaded.s-1d{background:var(--slider-loaded-bg);transition:transform .2s}.video-episode-filled.s-1d,.video-episode-loaded.s-1d{border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.video-episode-filled.s-1d{background-color:var(--slider-filled-bg)}"};function Fm(i,e){Q(i,Lx);let t=h(e,"videoEpisodes",19,()=>[]);var o=Ax();yi(o,21,t,r=>r.from,(r,a)=>{var l=kx();let d;var s=C(l),u=C(s),m=k(u,2);let p;S(s),S(l),O((v,b)=>{d=oe(l,1,"video-episode s-1d",null,d,v),qe(l,`left: ${n(a).from}%; width: ${n(a).width}%`),qe(u,`transform: translateX(${n(a).loadedWidth/n(a).width*100}%)`),p=oe(m,1,"video-episode-filled s-1d",null,p,b),qe(m,`transform: translateX(${n(a).filledWidth/n(a).width*100}%)`)},[()=>({disabled:e.disabled,mobile:e.isMobile}),()=>({mobile:e.isMobile})]),$(r,l)}),S(o),$(i,o)}function Mx(i,e,t,o,r,a,l){if(i.preventDefault(),e()&&N(t,e().getBoundingClientRect(),!0),o()||n(r)||!e())return;N(r,!0);let d=a(i.clientX,i.clientY);l()(d,i),e().setPointerCapture(i.pointerId)}function Vx(i,e,t,o,r,a,l,d){if(i.preventDefault(),e())return;let s=t(i.clientX,i.clientY),u=o(i.clientX);r()(s,u,n(a).width,i),n(l)&&d()(s)}function Rx(i,e,t,o,r){if(i.preventDefault(),e()||!n(t))return;N(t,!1);let a=o(i.clientX,i.clientY);r()(a,i)}function Nx(i,e,t,o){i.stopPropagation(),i.preventDefault(),e()&&t()(o(i.clientX,i.clientY))}function Dx(i,e,t,o,r,a){let l=e(i.clientX,i.clientY);t()&&o()(l),N(r,!1),a()(l)}var Ox=L("<div></div>"),Bx=L('<div class="bars s-t"><div class="loaded s-t"></div> <div></div></div>'),Hx=L('<!> <div role="slider" tabindex="0"><!> <div><div></div></div></div>',1),Fx={hash:"s-t",code:'.interactive-icons.s-t{position:absolute;top:-28px;width:calc(100% - 20px)}.interactive-icons.mobile.s-t{top:-10px}.slider.s-t{border-radius:var(--slider-radius);cursor:pointer;height:var(--slider-height);position:relative;touch-action:none;transition:opacity .2s;width:100%;will-change:opacity,transform;-webkit-tap-highlight-color:transparent}.no-handle.s-t{cursor:default}.slider.s-t:before{content:"";height:calc(var(--controls-height)/2);left:0;position:absolute;right:0;top:calc((var(--controls-height)/2 - var(--slider-height))*-1/2)}.bars.s-t{background:var(--slider-bg);overflow:hidden}.bars.s-t,.loaded.s-t{border-radius:var(--slider-radius);height:100%;position:absolute;width:100%}.loaded.s-t{background:var(--slider-loaded-bg);left:-100%;transition:transform .2s;will-change:transform}.filled.s-t{background-color:var(--slider-filled-bg);border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.slider.square.s-t,.slider.square.s-t .filled:where(.s-t),.slider.square.s-t .loaded:where(.s-t),.slider.square.s-t>.bars:where(.s-t){border-radius:unset}.filled.active-live.s-t{background-color:var(--timeline-slider-filled-active-live-bg)}.filled.ads.s-t{background-color:var(--slider-filled-ads)}.handleWrap.s-t{left:-100%;position:absolute;width:100%}.handle.s-t{background-color:var(--slider-handle-bg);border-radius:50%;height:var(--slider-handle-size);opacity:0;position:absolute;right:calc(var(--slider-handle-size)*-1/2);top:calc((var(--slider-height) - var(--slider-handle-size))/2);transform:scale(0);transition:opacity .2s,transform .2s;visibility:hidden;width:var(--slider-handle-size);will-change:opacity,transform}.handle.active-live.s-t{background-color:var(--timeline-slider-handle-active-live-bg)}.handle-always-visible.s-t .handle:where(.s-t),.slider-dragging.s-t .handle:where(.s-t),.slider.s-t:hover .handle:where(.s-t){opacity:1;transform:scale(1);visibility:visible}.slider-dragging.s-t .handle:where(.s-t){transform:scale(1.3)}.slider-vertical.s-t{left:-8px;position:absolute;top:-18px;transform:rotate(-90deg);transform-origin:0 0}.slider.disabled.s-t{cursor:default;opacity:.4}'};function el(i,e){B(e,!0),Q(i,Fx);let t=h(e,"ref",15,void 0),o=h(e,"className",3,""),r=h(e,"testId",3,void 0),a=h(e,"isHidden",3,!1),l=h(e,"isVertical",3,!1),d=h(e,"isActiveLive",3,!1),s=h(e,"isMobile",3,!1),u=h(e,"squareBorders",3,!1),m=h(e,"videoEpisodes",19,()=>[]),p=h(e,"withWheelHandler",3,!1),v=h(e,"isInteractive",3,!1),b=h(e,"disabled",3,!1),y=h(e,"hideHandel",3,!1),_=h(e,"onPointerDown",3,Oo.noop),x=h(e,"onHandleMove",3,Oo.noop),I=h(e,"onPointerUp",3,Oo.noop),T=h(e,"onPointerEnter",3,Oo.noop),R=h(e,"onPointerMove",3,Oo.noop),A=h(e,"onPointerLeave",3,Oo.noop),P=h(e,"onMouseEnter",3,Oo.noop),E=h(e,"onMouseLeave",3,Oo.noop),z=h(e,"onWheelUp",3,Oo.noop),F=h(e,"onWheelDown",3,Oo.noop),U=h(e,"onWheelLeft",3,Oo.noop),X=h(e,"onWheelRight",3,Oo.noop),ae=h(e,"onDisabledClick",3,Oo.noop),Z=h(e,"loadedProgress",3,0),re=h(e,"filledProgress",3,0),J=h(e,"handleProgress",3,0),we=h(e,"ariaLabel",3,""),me=h(e,"ariaValueMin",3,void 0),ee=h(e,"ariaValueMax",3,void 0),_e=h(e,"ariaValueNow",3,void 0),Ce=h(e,"ariaValueText",3,""),ge=h(e,"onContextMenu",3,Oo.noop),pe=h(e,"handleAlwaysVisible",3,!1),Qe=Ot(),G=q(void 0),D=q(!1),Ge=f(()=>{var $e;return($e=ee())!=null?$e:0}),K=f(()=>{var $e;return(0,Oo.isNonNullable)(m())&&(($e=m()[m().length-1])==null?void 0:$e.time)<n(Ge)}),se=f(()=>(0,Oo.isNonNullable)(m())&&m().length&&n(K)&&n(Ge)?et(Z()*100,re()*100):[]);function xe($e){if($e.preventDefault(),t()&&N(G,t().getBoundingClientRect(),!0),b())return;let Ve=Ne($e.clientX,$e.clientY),dt=Le($e.clientX);T()(Ve,dt,n(G).width)}function He($e){$e.preventDefault(),!b()&&A()()}function it(){P()()}function ne(){E()()}function ce($e){b()||p()&&($e.preventDefault(),$e.deltaY<0?z()():$e.deltaY>0?F()():$e.deltaX>0?X()():U()())}function Ne($e,Ve){return l()?Math.max(0,Math.min(1,(n(G).height-(Ve-n(G).top))/n(G).height)):Math.min(Math.max($e-n(G).x,0),n(G).width)/n(G).width}function Le($e){return Math.min(Math.max($e-n(G).x,0),n(G).width)}function et($e,Ve){let dt=Qe.features.episodesClustering&&!v()?Qe.episodeMinWidthPc:0,St=[],fe=m()[0].time/n(Ge)*100,Be=0,We=0;for(let It=1;It<m().length;It++)Be=m()[It].time/n(Ge)*100,Be-fe>dt&&(St.push({from:fe,width:Math.max(0,Be-fe),loadedWidth:Math.max(0,Math.min(Be,$e)-fe),filledWidth:Math.max(0,Math.min(Be,Ve)-fe),interactive:m()[It-1].interactive,completed:m()[It-1].completed}),fe=m()[It].time/n(Ge)*100,We++);let Ct={from:fe,width:Math.max(0,100-fe),loadedWidth:Math.max(0,Math.min($e,100)-fe),filledWidth:Math.max(0,Math.min(Ve,100)-fe),interactive:m()[We].interactive,completed:m()[We].completed};100-fe<dt?(We-=1,St[We].width+=100-fe,St[We].loadedWidth+=Math.max(0,Math.min($e,100)-fe),St[We].filledWidth+=Math.max(0,Math.min(Ve,100)-fe)):St[We]=Ct;let Xt=m()[0].time;if(Xt!==0){let It=Xt/n(Ge)*100;St.unshift({from:0,width:It,loadedWidth:Math.min(It,$e),filledWidth:Math.min(It,Ve)})}return St}function Ee($e){return Math.max(0,Math.min(100,$e*100))}let Te=f(()=>Ee(Z())),Fe=f(()=>Ee(re()));var kt=Hx(),Tt=ue(kt);{var Vt=$e=>{var Ve=Ox();let dt;yi(Ve,21,()=>n(se),St=>St.from,(St,fe)=>{var Be=Me(),We=ue(Be);{var Ct=Xt=>{Hm(Xt,{get videoEpisode(){return n(fe)},get disabled(){return b()}})};V(We,Xt=>{n(fe).interactive&&Xt(Ct)})}$(St,Be)}),S(Ve),O(St=>dt=oe(Ve,1,"interactive-icons s-t",null,dt,St),[()=>({mobile:s(),hidden:s()&&!n(D)})]),$($e,Ve)};V(Tt,$e=>{v()&&$e(Vt)})}var pt=k(Tt,2);let At;pt.__pointerdown=[Mx,t,G,b,D,Ne,_],pt.__pointermove=[Vx,b,Ne,Le,R,G,D,x],pt.__pointerup=[Rx,b,D,Ne,I],pt.__click=[Nx,b,ae,Ne],pt.__contextmenu=[Dx,Ne,b,ae,D,ge];var ti=C(pt);{var Lt=$e=>{Fm($e,{get videoEpisodes(){return n(se)},get disabled(){return b()},get isMobile(){return s()}})},Ft=$e=>{var Ve=Bx(),dt=C(Ve),St=k(dt,2);let fe;S(Ve),O(Be=>{Re(dt,"data-value",n(Te)),qe(dt,`transform: translateX(${n(Te)}%);`),fe=oe(St,1,"filled s-t",null,fe,Be),Re(St,"data-value",n(Fe)),qe(St,`transform: translateX(${n(Fe)}%);`)},[()=>({"active-live":d()})]),$($e,Ve)};V(ti,$e=>{n(se).length?$e(Lt):$e(Ft,!1)})}var qt=k(ti,2);let Y;var Pe=C(qt);let le;S(qt),S(pt),Xe(pt,$e=>t($e),()=>t()),O(($e,Ve,dt,St)=>{var fe,Be;At=oe(pt,1,`slider ${(fe=o())!=null?fe:""}`,"s-t",At,$e),Re(pt,"aria-label",we()),Re(pt,"aria-valuemin",me()),Re(pt,"aria-valuemax",ee()),Re(pt,"aria-valuenow",_e()),Re(pt,"aria-valuetext",Ce()),Re(pt,"data-testid",(Be=r())!=null?Be:null),Y=oe(qt,1,"handleWrap s-t",null,Y,Ve),qe(qt,dt),le=oe(Pe,1,"handle s-t",null,le,St)},[()=>({disabled:b(),"slider-dragging":n(D),hidden:a(),"handle-always-visible":pe(),"slider-vertical":l(),"no-handle":y(),square:u()}),()=>({hidden:y()}),()=>`transform: translateX(${Ee(J())}%);`,()=>({"active-live":d()})]),ut("pointerenter",pt,xe),ut("pointerleave",pt,He),ut("mouseenter",pt,it),ut("mouseleave",pt,ne),ut("wheel",pt,ce),$(i,kt),H()}Ye(["pointerdown","pointermove","pointerup","click","contextmenu"]);var ro=(i,e)=>jd[i]>=jd[e];var Fs=(i,e)=>jd[i]<=jd[e],Ib=i=>i>699?"xl":i>599?"l":i>509?"m":i>320?"s":"xs";var zx=L("<div><!></div>"),Wx=L("<div><!> <!></div>"),Kx={hash:"s-28",code:".volumeBar-container.s-28{align-items:center;display:flex}.vertical.s-28 .btn,.vertical.s-28 .tooltip-wrapper,.volumeBar-container.vertical.s-28{width:40px}.volumeBar.s-28{align-items:center;display:flex;margin:0 8px;position:relative;width:70px;--slider-height:var(--slider-volume-height);--slider-radius:var(--slider-volume-radius);--slider-handle-size:var(--slider-volume-handle-size);--slider-bg:var(--volume-slider-bg);--slider-filled-bg:var(--volume-slider-filled-bg);--slider-handle-bg:var(--volume-slider-handle-bg)}.volumeBar-slider-vertical{width:50px!important}.volumeBar-vertical.s-28{padding:0 8px 0 0;width:0}"};function Um(i,e){var Le,et;B(e,!0),Q(i,Kx);let[t,o]=De(),r=()=>w(R,"$isAudioAvailable$",t),a=()=>w(v,"$muted$",t),l=()=>w(p,"$volume$",t),d=()=>w(x,"$currentGridType$",t),s=()=>w(xe,"$controlsVisible",t),u=be(),m=Ot(),p=u.state.volume$,v=u.state.muted$,{setVolume:b,startVolumeChanging:y,stopVolumeChanging:_}=u.actions.internal,x=u.ui.currentGridType$,I=(Le=u.callbacks)==null?void 0:Le.onAudioDoesNotExistHint,T=(et=u.callbacks)==null?void 0:et.onAudioDisabledHint,R=u.state.isAudioAvailable$,A=u.state.isAudioDisabled,P=u.ui.t,E=q(!1),z,F=f(()=>e.isAds||r()),U=f(()=>!n(F)||a()||l()===0),X=f(()=>Fs(d(),"l")),ae=f(()=>n(X)?"":n(U)?!r()||A?P("tooltip_sound_unavailable"):P("tooltip_volume"):P("tooltip_volume_muted")),Z=f(()=>n(U)?P("tooltip_volume"):P("tooltip_volume_muted")),re=f(()=>n(U)?0:l()),J=!1,we=f(()=>e.isAds?!1:A?!T:r()?!1:!I);function me(Ee){y(),b(Ee)}function ee(){rp(u,l(),m.controls.volumeStepWheel)}function _e(){sp(u,l(),m.controls.volumeStepWheel)}function Ce(Ee){b(Ee)}function ge(Ee){b(Ee),_()}function pe(){J=!0}function Qe(){J=!1,Ge()}function G(){clearTimeout(z),N(E,!0)}function D(){Ge()}function Ge(){z=window.setTimeout(()=>{J||N(E,!1)},m.controls.volumeBarTimeout)}function K(Ee){Ee.preventDefault(),Ee.deltaY<0?ee():Ee.deltaY>0&&_e()}let se=q(!1),xe=u.ui.controlsVisible;Oe(()=>{s()||N(se,!1)});var He=Wx();let it;var ne=C(He);Ja(ne,{get content(){return n(ae)},translateY:-18,get active(){return n(se)},set active(Ee){N(se,Ee,!0)},children:(Ee,Te)=>{let Fe=f(()=>n(X)?"btn-volume-vertical":"btn-volume-horizontal");Kt(Ee,{className:"btn-full-opacity",get disabled(){return n(we)},get testId(){return n(Fe)},get ariaLabel(){return n(Z)},get click(){return e.click},get ariaKeyShortCut(){return bs.KeyM},role:"button",children:(kt,Tt)=>{ha(kt,{get size(){return"24"},get volume(){return l()},get muted(){return n(U)}})},$$slots:{default:!0}})},$$slots:{default:!0}});var ce=k(ne,2);{var Ne=Ee=>{var Te=zx();let Fe;var kt=C(Te);let Tt=f(()=>n(X)?"volumeBar-slider-vertical":""),Vt=f(()=>n(X)&&!n(E)),pt=f(()=>n(X)?pe:fc.noop),At=f(()=>n(X)?Qe:fc.noop),ti=f(()=>Math.round(n(re)*100)),Lt=f(()=>`${Math.round(n(re)*100)}%`),Ft=f(()=>n(X)?"volume-slider-vertical":"volume-slider");el(kt,{get className(){return n(Tt)},get isHidden(){return n(Vt)},get isVertical(){return n(X)},withWheelHandler:!0,onWheelUp:ee,onWheelDown:_e,onPointerDown:me,onHandleMove:Ce,onPointerUp:ge,get onPointerEnter(){return n(pt)},get onPointerLeave(){return n(At)},ariaLabel:"Ползунок громкости",ariaValueMin:0,ariaValueMax:100,get ariaValueNow(){return n(ti)},get ariaValueText(){return n(Lt)},get filledProgress(){return n(re)},get handleProgress(){return n(re)},get testId(){return n(Ft)}}),S(Te),O(qt=>Fe=oe(Te,1,"volumeBar s-28",null,Fe,qt),[()=>({"volumeBar-vertical":n(X)})]),$(Ee,Te)};V(ce,Ee=>{n(F)&&Ee(Ne)})}S(He),O(Ee=>it=oe(He,1,"volumeBar-container s-28",null,it,Ee),[()=>({vertical:n(X)})]),ut("mouseenter",He,function(...Ee){var Te;(Te=n(X)?G:fc.noop)==null||Te.apply(this,Ee)}),ut("mouseleave",He,function(...Ee){var Te;(Te=n(X)?D:fc.noop)==null||Te.apply(this,Ee)}),ut("wheel",He,K),$(i,He),H(),o()}var Eb=require("@vkontakte/videoplayer-shared/es2015");var qx=Ie('<path d="M4.58 13.98a1 1 0 0 1 .99-1h4.45a1 1 0 0 1 1 1v4.45a.99.99 0 0 1-1.99 0v-2.05L5.71 19.7a1 1 0 1 1-1.41-1.4l3.32-3.32H5.57a1 1 0 0 1-.99-1m10.39-6.36 3.32-3.32a1 1 0 1 1 1.41 1.4l-3.32 3.32h2.05a.99.99 0 0 1 0 1.98H14a1 1 0 0 1-1-1V5.57a.99.99 0 1 1 1.98 0z"></path>'),Qx=Ie('<path d="M10.5 19a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-4.5a1 1 0 0 1 2 0v2.07l3.36-3.36a1 1 0 0 1 1.42 0l.01.01a1 1 0 0 1 0 1.42L7.43 18H9.5a1 1 0 0 1 1 1M18 7.43l-3.36 3.36a1 1 0 0 1-1.42 0l-.01-.01a1 1 0 0 1 0-1.42L16.57 6H14.5a1 1 0 0 1 0-2H19a1 1 0 0 1 1 1v4.5a1 1 0 0 1-2 0z"></path>');function zm(i,e){let t=h(e,"isFullscreen",8,!1),o=kn(()=>t()?"close-fullscreen-icon":"open-fullscreen-icon");Ze(i,{get testId(){return n(o)},children:(r,a)=>{var l=Me(),d=ue(l);{var s=m=>{var p=qx();$(m,p)},u=m=>{var p=Qx();$(m,p)};V(d,m=>{t()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}function mc(i,e){B(e,!0);let t=h(e,"isFullscreen",3,!1),o=h(e,"click",3,Eb.noop),r=be(),a=r.ui.isFullscreenOpenedByKeyboard,l=r.ui.t,d=f(()=>t()?l("tooltip_fullscreen_on"):l("tooltip_fullscreen_off"));Kt(i,{testId:"fullscreen-btn",get ariaLabel(){return n(d)},click:u=>{let m=fa(u);a.set(m),o()()},get ariaKeyShortCut(){return bs.KeyF},role:"button",children:(u,m)=>{zm(u,{get isFullscreen(){return t()}})},$$slots:{default:!0}}),H()}var Gx=Ie('<svg><!><path fill="var(--btn-color, #fff)" fill-rule="evenodd" d="M4.26 4.26C3 5.54 3 7.57 3 11.65v.72c0 4.07 0 6.11 1.26 7.38C5.54 21 7.57 21 11.65 21h.72c4.07 0 6.11 0 7.38-1.26C21 18.47 21 16.43 21 12.36v-.72c0-4.07 0-6.11-1.26-7.38C18.47 3 16.43 3 12.36 3h-.72C7.57 3 5.53 3 4.26 4.26M6 8.5c.1 4.68 2.56 7.5 6.61 7.5h.24v-2.68c1.47.15 2.57 1.25 3.02 2.68H18a6 6 0 0 0-3-3.76 5.7 5.7 0 0 0 2.55-3.74h-1.94c-.4 1.49-1.61 2.84-2.77 2.97V8.5h-1.96v5.2c-1.2-.3-2.76-1.76-2.83-5.2z" clip-rule="evenodd"></path></svg>');function Wm(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=Gx();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none","aria-hidden":"true","data-testid":"vk-logo-icon",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(),S(o),$(i,o)}var Yx=Ie('<svg><!><svg data-logo="vk_video"><path d="M7 8.6c0-1.96 0-2.94.38-3.69a3.5 3.5 0 0 1 1.53-1.53C9.66 3 10.64 3 12.6 3h1.36c2.46 0 3.7 0 4.64.48a4.4 4.4 0 0 1 1.92 1.92c.48.94.48 2.18.48 4.64v3.92c0 2.46 0 3.7-.48 4.64a4.4 4.4 0 0 1-1.92 1.92c-.94.48-2.18.48-4.64.48H12.6c-1.96 0-2.94 0-3.69-.38a3.5 3.5 0 0 1-1.53-1.53C7 18.34 7 17.36 7 15.4zm9.26 1.74c.9.54 1.36.81 1.51 1.16.13.3.13.65 0 .96-.15.34-.6.61-1.5 1.15l-2.4 1.43c-.93.56-1.4.84-1.8.8-.33-.03-.64-.2-.84-.48-.23-.31-.23-.86-.23-1.96v-2.85c0-1.1 0-1.64.23-1.96q.31-.42.85-.48c.38-.04.86.25 1.8.8zM5 9.04c0-2.46 0-3.7.48-4.64q.37-.71.95-1.25-.58.1-1.03.33A4.4 4.4 0 0 0 3.48 5.4C3 6.34 3 7.58 3 10.04v3.92c0 2.46 0 3.7.48 4.64a4.4 4.4 0 0 0 1.92 1.92q.45.23 1.03.33a4 4 0 0 1-.95-1.25C5 18.66 5 17.42 5 14.96z"></path></svg><svg x="4" y="3" data-logo="play_market"><path d="M0 1.26v15.47q0 .66.34 1L9.52 9 .33.28C.08.53 0 .92 0 1.26"></path><path d="M.33.28.38.23c.34-.3.89-.32 1.49 0l10.75 5.81-2.6 2.48zm10.29 8.75 2.88 2.45-.53.29-.34.18-2.58-2.44-9.71 8.22c.33.34.9.37 1.53.04l11.1-6 .53-.29 2.73-1.47c1.03-.56 1.03-1.47 0-2.02l-2.77-1.5-.84-.45.84.45.1.05z"></path></svg><svg x="3" data-logo="app_store"><path d="M17.62 16.37q-.48 1.09-1.15 2.03-.9 1.27-1.48 1.75-.88.8-1.9.83-.72 0-1.76-.42a5 5 0 0 0-1.89-.4q-.9 0-1.94.4a5 5 0 0 1-1.68.44q-.98.04-1.95-.85-.62-.53-1.55-1.82a13 13 0 0 1-1.63-3.2 12 12 0 0 1-.69-3.8q0-2.1.93-3.64A5.4 5.4 0 0 1 5.5 5.03q.77 0 2.03.46t1.62.47q.26 0 1.79-.55a6 6 0 0 1 2.43-.42 5.2 5.2 0 0 1 4.05 2.09q-2.4 1.44-2.4 4.02a4.4 4.4 0 0 0 1.49 3.34q.66.61 1.48.95-.18.5-.38.98M13.5.42q0 1.58-1.17 2.94c-.94 1.08-2.07 1.7-3.3 1.6L9 4.56c0-1 .45-2.08 1.24-2.96q.6-.67 1.5-1.12.93-.44 1.74-.48z"></path></svg><path d="M32.55 17.04h2.5L38.7 7h-1.8l-2.94 8.28h-.28L30.84 7H29zm15.52 0-4.61-5.2L47.72 7H45.6l-3.56 4.09h-.42V7h-1.7v10.04h1.7v-4.3h.43l3.76 4.3z"></path><path d="M57.89 11.89a2.2 2.2 0 0 0 1.44-2.16C59.33 8.14 58 7 56.06 7h-3.92v10.04h4.2c1.96 0 3.29-1.14 3.29-2.8 0-1.17-.66-2.04-1.74-2.35m-4.04-3.4h2.21c.92 0 1.54.56 1.54 1.39 0 .8-.62 1.36-1.54 1.36h-2.2zm2.5 7.06h-2.5v-2.81h2.5c.9 0 1.52.57 1.52 1.4 0 .84-.62 1.4-1.52 1.4m4.84 1.5h2.32l2.77-5.5h.22v5.5h1.57v-7.4h-2.32l-2.77 5.5h-.22v-5.5h-1.57zm7.96 2.21h1.64v-2.2h5.33v2.2h1.64v-3.7h-1.29V9.64h-5.43l-.37 3.78c-.13 1.34-.53 2.13-1.34 2.13h-.18zm2.49-3.7c.4-.39.57-1.04.68-2.15l.23-2.27h2.28v4.42zm14.38-2.3a3.7 3.7 0 0 0-3.84-3.76 3.7 3.7 0 0 0-3.85 3.85 3.7 3.7 0 0 0 3.85 3.84c1.54 0 2.99-.72 3.55-2.13l-1.54-.26c-.36.53-1.04.9-1.91.9-1.26 0-2.09-.77-2.24-1.91H86zm-3.84-2.33c1.02 0 1.8.65 2.06 1.58h-4.1a2.1 2.1 0 0 1 2.04-1.58m8.66 6.26c2.32 0 3.96-1.6 3.96-3.84 0-2.25-1.64-3.85-3.96-3.85s-3.97 1.6-3.97 3.85 1.64 3.84 3.97 3.84m0-1.5c-1.34 0-2.25-.95-2.25-2.34 0-1.4.9-2.35 2.25-2.35 1.34 0 2.25.95 2.25 2.35s-.91 2.35-2.25 2.35" class="_ru"></path><path d="M35.02 17.36h-2.48L29 7.42h1.83l2.83 8.2h.28l2.93-8.2h1.8zm8.41-5.15 4.6 5.15h-2.24l-3.75-4.26h-.43v4.26h-1.7V7.42h1.7v4.05h.41l3.55-4.05h2.1zm13.37 5.15h-2.48L50.8 7.42h1.83l2.82 8.2h.29l2.92-8.2h1.8zm6.46 0h-1.64v-7.33h1.64zm-.81-8.37q-.45 0-.74-.27a1 1 0 0 1-.28-.72q0-.44.28-.72.3-.28.74-.28t.72.28q.3.29.29.72 0 .44-.29.72t-.72.27m5.93 8.51q-1.03 0-1.86-.48a3.5 3.5 0 0 1-1.29-1.35 4 4 0 0 1-.45-1.98q0-1.1.45-1.95.46-.88 1.3-1.36.81-.5 1.85-.5.9 0 1.6.38.68.35 1.13.88V7.42h1.63v9.94h-1.22l-.34-1.18q-.46.54-1.17.94a3.4 3.4 0 0 1-1.63.38m.4-1.45q1.04 0 1.68-.65.65-.66.65-1.7t-.65-1.7a2.2 2.2 0 0 0-1.68-.66 2.2 2.2 0 0 0-1.66.66q-.64.66-.64 1.7t.64 1.7q.64.65 1.66.65m13.15-2.44-.03.52h-5.94q.12.86.71 1.38.6.51 1.52.51.63 0 1.13-.24.51-.24.78-.65l1.53.26q-.39 1.01-1.38 1.56-.96.55-2.16.55-1.1 0-1.98-.48a3.6 3.6 0 0 1-1.85-3.33q0-1.1.48-1.95.5-.88 1.37-1.36a4 4 0 0 1 1.98-.5q1.11 0 1.98.5.88.48 1.36 1.34.5.86.5 1.89m-3.84-2.31q-.73 0-1.29.42-.53.42-.74 1.14h4.1a2.2 2.2 0 0 0-2.07-1.56m8.66 6.2q-1.14 0-2.04-.48a3.7 3.7 0 0 1-1.4-1.35 4 4 0 0 1-.5-1.98q0-1.1.5-1.95.5-.88 1.4-1.36.9-.5 2.04-.5t2.03.5q.91.48 1.4 1.36.52.86.52 1.95 0 1.11-.51 1.98-.5.86-1.4 1.35-.9.48-2.04.48m0-1.48q.99 0 1.62-.63.63-.66.63-1.7t-.63-1.67a2.2 2.2 0 0 0-1.62-.65q-.99 0-1.62.65-.62.63-.62 1.67 0 1.05.62 1.7.63.63 1.62.63" class="_en"></path></svg>');function Km(i,e){let t=Nn(e,["$$slots","$$events","$$legacy","children"]);var o=Yx();no(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"95",height:"24",fill:"var(--btn-color, #fff)","fill-rule":"evenodd","aria-hidden":"true","clip-rule":"evenodd",viewBox:"0 0 95 24",role:"img"},t));var r=C(o);ri(r,()=>{var a;return(a=e.children)!=null?a:_t}),pi(6),S(o),$(i,o)}var jx={hash:"s-2a",code:"svg [data-logo],svg[data-testid=vk-video-logo-icon--en] ._ru,svg[data-testid=vk-video-logo-icon--short] ._en,svg[data-testid=vk-video-logo-icon--short] ._ru,svg[data-testid=vk-video-logo-icon] ._en{opacity:0;visibility:hidden}svg[data-logo=app_store] [data-logo=app_store],svg[data-logo=play_market] [data-logo=play_market],svg[data-logo=vk_video] [data-logo=vk_video]{opacity:1;visibility:visible}"};function qm(i,e){B(e,!0),Q(i,jx);let t=h(e,"short",3,!1),o=h(e,"isCyrillic",3,!0),r=h(e,"logo",19,()=>"vk_video"),a="vk-video-logo-icon--short",l=24,d=f(()=>!o()&&!t()?91:t()?l:95),s=f(()=>!o()&&!t()?"vk-video-logo-icon--en":t()?a:"vk-video-logo-icon"),u=f(()=>`0 0 ${n(d)} 24`);Km(i,{get width(){return n(d)},height:"24",get viewBox(){return n(u)},get"data-testid"(){return n(s)},get"data-logo"(){return r()}}),H()}function vc(i,e){B(e,!0);let[t,o]=De(),r=()=>w(b,"$isMobile",t),a=()=>w(v,"$currentGridType$",t),l=()=>w(_,"$isCyrillicRelatedInterface$",t),d=h(e,"ref",15,void 0),s=h(e,"logoClickable",3,!1),u=h(e,"targetUrl",3,""),m=Ot(),p=be(),v=p.ui.currentGridType$,b=p.ui.isMobile,y=p.ui.t,_=p.isCyrillicRelatedInterface$,x=f(()=>m.logoType!=="vk"),I=f(()=>n(x)?y("tooltip_vk_video_logo"):y("tooltip_vk_logo")),T=f(()=>(r()&&Fs(a(),"m")||Fs(a(),"l"))&&n(x)),R=()=>{var E,z;e.click(),(E=p.callbacks)!=null&&E.onLogoClicked?(z=p.callbacks)==null||z.onLogoClicked():u()&&window.open(u(),"_blank")},A=f(()=>!s()),P=f(()=>n(x)?"btn-vk-video-logo":"btn-vk-logo");Kt(i,{className:"btn-full-opacity",get disabled(){return n(A)},click:R,get testId(){return n(P)},get ariaLabel(){return n(I)},get ref(){return d()},set ref(E){d(E)},children:(E,z)=>{var F=Me(),U=ue(F);{var X=Z=>{qm(Z,{get logo(){return m.logoType},get short(){return n(T)},get isCyrillic(){return l()}})},ae=Z=>{Wm(Z,{})};V(U,Z=>{n(x)?Z(X):Z(ae,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}var kb=require("@vkontakte/videoplayer-core/es2015");var Qm=require("@vkontakte/videoplayer-core/es2015");var Xx=Ie('<path d="M3.6 13.3a5.1 5.1 0 0 1 5.05 5.83.9.9 0 0 1-1.78-.26 3.3 3.3 0 0 0-3.74-3.74.9.9 0 0 1-.26-1.78c.24-.03.49-.05.73-.05Z" class="s-18"></path><path d="M3.6 9.7a8.7 8.7 0 0 1 8.68 9.37.9.9 0 0 1-1.8-.14c.02-.17.02-.35.02-.53a6.9 6.9 0 0 0-7.43-6.88.9.9 0 0 1-.14-1.8l.67-.02ZM3.6 16.9a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3Z" class="s-18"></path><path d="M16.24 4.1c.8 0 1.47 0 2 .04a4 4 0 0 1 1.53.38 3.9 3.9 0 0 1 1.7 1.71 4 4 0 0 1 .39 1.53c.04.53.04 1.2.04 2v4.48c0 .8 0 1.47-.04 2a4 4 0 0 1-.38 1.53 3.9 3.9 0 0 1-1.7 1.7 4 4 0 0 1-1.54.39c-.53.04-1.2.04-2 .04H15a.9.9 0 0 1 0-1.8h1.2c.85 0 1.44 0 1.9-.04.44-.03.68-.1.85-.19.4-.2.72-.52.92-.92.09-.17.16-.4.2-.85.03-.46.03-1.05.03-1.9V9.8c0-.85 0-1.44-.04-1.9-.03-.44-.1-.68-.19-.85a2.1 2.1 0 0 0-.92-.92 2.25 2.25 0 0 0-.85-.2 25.9 25.9 0 0 0-1.9-.03H5.83a2.1 2.1 0 0 0-1.81 1.4.9.9 0 1 1-1.7-.6A3.9 3.9 0 0 1 6 4.1h10.24Z" class="s-18"></path>',1),Zx=Ie('<path d="M3.60219 13.2993C6.41858 13.2995 8.70256 15.5835 8.70278 18.3999C8.70277 18.6469 8.68424 18.8909 8.65004 19.1294C8.57937 19.6212 8.12333 19.9625 7.63149 19.8921C7.13968 19.8213 6.79823 19.3654 6.86879 18.8735C6.89087 18.7195 6.90199 18.5611 6.902 18.3999C6.90178 16.5776 5.42447 15.1003 3.60219 15.1001C3.441 15.1001 3.28267 15.1112 3.12856 15.1333C2.63666 15.2039 2.18077 14.8624 2.11 14.3706C2.03966 13.8788 2.38091 13.4227 2.8727 13.3521C3.11125 13.3178 3.35516 13.2993 3.60219 13.2993Z"></path><path d="M3.60219 9.69971C8.40682 9.69977 12.3021 13.5953 12.3024 18.3999C12.3024 18.6248 12.2938 18.8489 12.277 19.0698C12.239 19.5651 11.8065 19.9365 11.3112 19.8989C10.8157 19.8611 10.4445 19.4286 10.4821 18.9331C10.4954 18.7576 10.5026 18.5791 10.5026 18.3999C10.5023 14.5894 7.41271 11.5005 3.60219 11.5005C3.42268 11.5005 3.24474 11.5066 3.06899 11.52C2.57352 11.5578 2.14115 11.1863 2.10317 10.6909C2.06587 10.1957 2.43694 9.76287 2.93227 9.7251C3.15348 9.70823 3.37699 9.69971 3.60219 9.69971Z"></path><path d="M3.60219 16.8999C4.43047 16.8999 5.10198 17.5717 5.10219 18.3999C5.10209 19.2282 4.43054 19.8999 3.60219 19.8999C2.77383 19.8999 2.10229 19.2282 2.10219 18.3999C2.10241 17.5717 2.7739 16.8999 3.60219 16.8999Z"></path><path d="M16.2379 4.1001C17.0459 4.10009 17.7067 4.10017 18.2438 4.14404C18.7997 4.18946 19.3022 4.28599 19.7711 4.5249C20.5049 4.89882 21.1014 5.49623 21.4752 6.22998C21.714 6.69873 21.8107 7.20063 21.8561 7.75635C21.9 8.29338 21.9001 8.95424 21.9 9.76221V14.2378C21.9001 15.0458 21.9 15.7066 21.8561 16.2437C21.8107 16.7996 21.7141 17.3021 21.4752 17.771C21.1014 18.5046 20.5048 19.1012 19.7711 19.4751C19.3022 19.714 18.7997 19.8105 18.2438 19.856C17.7067 19.8998 17.0459 19.8999 16.2379 19.8999H14.9997C14.503 19.8996 14.1005 19.4972 14.1002 19.0005C14.1002 18.5036 14.5028 18.1004 14.9997 18.1001H16.1998C17.0548 18.1001 17.6422 18.0992 18.0973 18.062C18.5419 18.0257 18.7809 17.9596 18.9538 17.8716C19.3489 17.6702 19.6704 17.3487 19.8717 16.9536C19.9598 16.7808 20.0258 16.5417 20.0622 16.0972C20.0993 15.6421 20.1002 15.0546 20.1002 14.1997V9.80029C20.1002 8.94536 20.0993 8.35794 20.0622 7.90283C20.0258 7.45834 19.9598 7.21921 19.8717 7.04639C19.6704 6.6514 19.3487 6.33073 18.9538 6.12939C18.7809 6.04133 18.5419 5.97431 18.0973 5.93799C17.6422 5.9008 17.0548 5.8999 16.1998 5.8999H6.00063L5.83071 5.90674C4.99191 5.97398 4.28981 6.53462 4.01918 7.30029C3.85342 7.76872 3.33928 8.01472 2.87075 7.84912C2.40214 7.68346 2.15628 7.16833 2.32192 6.69971C2.85696 5.18632 4.30125 4.1001 6.00063 4.1001H16.2379Z"></path><path d="M2.95114 7.11345C2.42394 7.1914 1.90399 6.78569 2.00995 6.2634C2.05777 6.0277 2.12517 5.82449 2.22018 5.63803C2.5078 5.07354 2.96674 4.6146 3.53123 4.32698C4.17296 4 5.01304 4 6.6932 4H17.2001C18.8803 4 19.7204 4 20.3621 4.32698C20.9266 4.6146 21.3855 5.07354 21.6731 5.63803C22.0001 6.27976 22.0001 7.11984 22.0001 8.8V15.2C22.0001 16.8802 22.0001 17.7202 21.6731 18.362C21.3855 18.9265 20.9266 19.3854 20.3621 19.673C19.7204 20 18.8803 20 17.2001 20H15.7196C15.2009 20 14.8203 19.5134 14.8938 19C14.9638 18.5101 15.0001 18.0093 15.0001 17.5C15.0001 11.701 10.2991 7 4.5001 7C3.97384 7 3.45662 7.03872 2.95114 7.11345Z"></path>',1),Jx={hash:"s-18",code:".animated.s-18{animation-duration:1s;animation-iteration-count:infinite}.wave1.animated.s-18{animation-name:s-18-wave1}.wave2.animated.s-18{animation-name:s-18-wave2}.wave3.animated.s-18{animation-name:s-18-wave3}@keyframes s-18-wave1{0%{opacity:.3}33%{opacity:1}66%{opacity:1}to{opacity:1}}@keyframes s-18-wave2{0%{opacity:.3}33%{opacity:.3}66%{opacity:1}to{opacity:1}}@keyframes s-18-wave3{0%{opacity:.3}33%{opacity:.3}66%{opacity:.3}to{opacity:1}}"};function gc(i,e){B(e,!0),Q(i,Jx);let t=h(e,"isMobile",3,!1),o=f(()=>e.iconState===Qm.ChromecastState.CONNECTED),r=f(()=>e.iconState===Qm.ChromecastState.CONNECTING),a=f(()=>n(o)?"#2688EB":da),l=f(()=>e.size?fn(e.size):void 0);var d=Me(),s=ue(d);{var u=p=>{Ze(p,{get fill(){return n(a)},get style(){return n(l)},testId:"chromecast-mobile-icon",children:(v,b)=>{var y=Xx();pi(2),$(v,y)},$$slots:{default:!0}})},m=p=>{Ze(p,{get style(){return n(l)},testId:"chromecast-icon",children:(v,b)=>{var y=Zx(),_=ue(y);let x;var I=k(_);let T;var R=k(I);let A;var P=k(R);let E;var z=k(P);let F;O((U,X,ae,Z,re)=>{x=oe(_,0,"wave2 s-18",null,x,U),T=oe(I,0,"wave3 s-18",null,T,X),A=oe(R,0,"wave1 s-18",null,A,ae),E=oe(P,0,"s-18",null,E,Z),F=oe(z,0,"s-18",null,F,re)},[()=>({animated:n(r)}),()=>({animated:n(r)}),()=>({animated:n(r)}),()=>({hidden:n(o)}),()=>({hidden:!n(o)})]),$(v,y)},$$slots:{default:!0}})};V(s,p=>{t()?p(u):p(m,!1)})}$(i,d),H()}var Ab=require("@vkontakte/videoplayer-shared/es2015");function hc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"click",3,Ab.noop),l=be().ui.t,d=f(()=>e.state===kb.ChromecastState.CONNECTED?l("tooltip_chromecast_on"):l("tooltip_chromecast_off"));Kt(i,{get ariaLabel(){return n(d)},get click(){return r()},testId:"btn-chromecast",get ref(){return t()},set ref(s){t(s)},children:(s,u)=>{gc(s,{get isMobile(){return o()},get iconState(){return e.state}})},$$slots:{default:!0}}),H()}var Lb=require("@vkontakte/videoplayer-shared/es2015");var e2=Ie('<path d="m21.62 16.5-.02.07q-.22 1.27-.42 2.09a5 5 0 0 1-.64 1.5 4.4 4.4 0 0 1-2.51 1.73q-.77.18-1.63.07t-2.11-.34l-4.34-.8q-1.27-.22-2.1-.42a5 5 0 0 1-1.5-.65 4.4 4.4 0 0 1-1.72-2.5 5 5 0 0 1-.07-1.63q.1-.84.34-2.11l.01-.07q.22-1.27.43-2.1a5 5 0 0 1 .64-1.5 4.4 4.4 0 0 1 2.5-1.73 5 5 0 0 1 1.64-.07q.83.1 2.1.35l4.34.8q1.28.21 2.1.42a5 5 0 0 1 1.5.64 4.4 4.4 0 0 1 1.73 2.5q.18.78.07 1.64-.1.83-.34 2.1m-1.45-2.3c.05-.49.03-.77-.02-1a2.6 2.6 0 0 0-1.02-1.48 3 3 0 0 0-.93-.37c-.48-.13-1.1-.24-2-.4l-4.26-.79c-.9-.16-1.52-.27-2.01-.33a3 3 0 0 0-1 .03 2.6 2.6 0 0 0-1.48 1.02 3 3 0 0 0-.37.92c-.13.48-.24 1.1-.4 2s-.28 1.51-.33 2c-.06.5-.04.78.02 1 .15.6.51 1.13 1.02 1.48.19.13.45.25.92.37.48.13 1.1.25 2 .4l4.27.79c.9.16 1.52.28 2.01.33s.77.03 1-.02a2.6 2.6 0 0 0 1.47-1.03c.14-.19.25-.45.38-.92.12-.48.24-1.1.4-2s.28-1.51.33-2"></path><path d="M18.19 7.49a.9.9 0 0 1-1.05-.73c-.14-.8-.2-1.08-.28-1.3A2.6 2.6 0 0 0 14.5 3.8c-.22 0-.5.04-1.31.17l-5.85.96a8 8 0 0 0-2.17.5 2.6 2.6 0 0 0-1.33 1.75c-.08.38-.04.85.11 2.23l.01.1a.9.9 0 1 1-1.78.2l-.01-.1-.02-.17a9 9 0 0 1-.07-2.64 4.4 4.4 0 0 1 2.25-2.97c.63-.33 1.42-.46 2.56-.65l.16-.03 5.85-.96.1-.01c.67-.11 1.13-.19 1.55-.18a4.4 4.4 0 0 1 4 2.82c.14.39.23.85.35 1.53l.01.1a.9.9 0 0 1-.72 1.04"></path><path d="M12.72 12.41a.42.42 0 0 0-.69.23l-.72 4.18a.4.4 0 0 0 .03.23c.08.2.33.3.54.22l3.67-1.47a.4.4 0 0 0 .12-.68z"></path>',1);function Gm(i){Ze(i,{testId:"episodes-icon",children:(e,t)=>{var o=e2();pi(2),$(e,o)},$$slots:{default:!0}})}var cp=(i,e,t)=>t.filter(o=>o.time<=i*e).pop();var t2=L('<span class="text mobile s-26"> </span> <div class="chevron-episodes s-26" data-testid="btn-episodes_icon"><!></div>',1),i2=L('<span class="text s-26"> </span>'),o2=L('<span class="text count s-26"> </span>'),n2=L('<span class="icon s-26"><!></span> <!>',1),r2={hash:"s-26",code:".icon.s-26{flex-shrink:0}.text.s-26{overflow:hidden;padding:0 8px;text-overflow:ellipsis;white-space:nowrap}.text.count.s-26{overflow:visible}.text.mobile.s-26{padding:0 3px 0 4px}.chevron-episodes.s-26{margin-bottom:-6px;opacity:.7;transform:scale(.8)}"};function _c(i,e){var J,we,me;B(e,!0),Q(i,r2);let[t,o]=De(),r=()=>w(y,"$currentGridType$",t),a=()=>w(_,"$openedByKeyboard$",t),l=()=>w(x,"$panelOpened$",t),d=()=>w(I,"$isMobile",t),s=h(e,"position",3,0),u=h(e,"duration",3,0),m=h(e,"timeCodes",19,()=>[]),p=be(),v=(we=(J=p.callbacks)==null?void 0:J.onEpisodeChanged)!=null?we:Lb.noop,b=!!((me=p.callbacks)!=null&&me.onEpisodeClicked),y=p.ui.currentGridType$,_=p.ui.episodes.openedByKeyboard$,x=p.ui.episodes.panelOpened$,I=p.ui.isMobile,T=p.ui.t,R=q(void 0),A=ee=>{var Ce,ge,pe;if(!!((Ce=p.callbacks)!=null&&Ce.onEpisodeClicked)){let Qe=fa(ee);_.set(Qe),x.set(!0),(pe=(ge=p.callbacks)==null?void 0:ge.onEpisodeClicked)==null||pe.call(ge,Qe)}},P=q(null),E=f(()=>s()/u());Oe(()=>{var _e;let ee=cp(n(E),u(),m());ee?((_e=n(P))==null?void 0:_e.time)!==ee.time&&(v(ee),N(P,ee,!0)):N(P,null)});let z=f(()=>{var ee;return((ee=n(P))==null?void 0:ee.text)||""}),F=f(()=>ro(r(),"xl")?"FULL":ro(r(),"m")?"COUNT":"SHORT"),U=f(()=>`${T("tooltip_episodes")}: ${n(z)}`),X=(ee,_e,Ce)=>ht(null,null,function*(){yield ho(),(ee==null?void 0:ee.getAttribute("aria-expanded"))==="false"&&_e&&!Ce&&Pt(()=>{_.set(!1),ee.focus()})});Oe(()=>{X(n(R),a(),l())});var ae=Me(),Z=ue(ae);{var re=ee=>{let _e=f(()=>d()?"px-0":""),Ce=f(()=>!b);Kt(ee,{get className(){var ge;return`w-max btn-full-opacity btn-jc-l ${(ge=n(_e))!=null?ge:""}`},testId:"btn-episodes",click:A,get disabled(){return n(Ce)},get ariaExpanded(){return l()},get ariaLabel(){return n(U)},get ref(){return n(R)},set ref(ge){N(R,ge,!0)},children:(ge,pe)=>{var Qe=Me(),G=ue(Qe);{var D=K=>{var se=t2(),xe=ue(se),He=C(xe,!0);S(xe);var it=k(xe,2),ne=C(it);Nr(ne,{direction:"right"}),S(it),O(()=>ve(He,n(z))),$(K,se)},Ge=K=>{var se=n2(),xe=ue(se),He=C(xe);Gm(He,{}),S(xe);var it=k(xe,2);{var ne=Ne=>{var Le=i2(),et=C(Le,!0);S(Le),O(()=>ve(et,n(z))),$(Ne,Le)},ce=(Ne,Le)=>{{var et=Ee=>{var Te=o2(),Fe=C(Te,!0);S(Te),O(()=>ve(Fe,m().length)),$(Ee,Te)};V(Ne,Ee=>{n(F)==="COUNT"&&Ee(et)},Le)}};V(it,Ne=>{n(F)==="FULL"?Ne(ne):Ne(ce,!1)})}$(K,se)};V(G,K=>{d()?K(D):K(Ge,!1)})}$(ge,Qe)},$$slots:{default:!0}})};V(Z,ee=>{n(P)&&ee(re)})}$(i,ae),H(),o()}var _v=require("@vkontakte/videoplayer-shared/es2015");var _i=require("@vkontakte/videoplayer-core/es2015"),at=require("@vkontakte/videoplayer-shared/es2015"),xs=require("@vkontakte/videoplayer-statistics/es2015");var Ke=require("@vkontakte/videoplayer-shared/es2015"),so=require("@vkontakte/videoplayer-shared/es2015");var s2="//ad.mail.ru/static/admanhtml/rbadman-html5.min.js",up=class{constructor(e,t){this.adman=null;this.initialVolume=1;this.videoElement=null;this.currentAdSection=null;this.actions=null;this.adsState=null;this.playerState=null;this.events={init$:new so.Subject,loadStarted$:new so.Subject,loadEnded$:new so.Subject,loadError$:new so.Subject,ready$:new so.Subject,slotRequested$:new so.Subject,started$:new so.Subject,timeRemained$:new so.Subject,paused$:new so.Subject,resumed$:new so.Subject,ended$:new so.Subject,empty$:new so.Subject,skipped$:new so.Subject,clicked$:new so.Subject,closed$:new so.Subject,error$:new so.Subject};this.loadAdman=e=>(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_start",this.useAdmanFromNPM?"npm":"http"],numbers:[(0,Ke.now)()]}),this.useAdmanFromNPM?this.loadAdmanNPM(e):this.loadAdmanMailRu(e));this.loadAdmanMailRu=e=>new Promise((t,o)=>{let r;this.events.loadStarted$.next();let a=()=>{clearTimeout(r),delete window.admanAsyncInit,window.AdmanHTML?(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_async_init_done","http"],numbers:[(0,Ke.now)()]}),t(),this.events.loadEnded$.next()):(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","http"],numbers:[(0,Ke.now)()]}),o())};(0,so.addScript)(s2,e,this.loadTimeout).then(()=>{Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_loaded","http"],numbers:[(0,Ke.now)()]}),window.AdmanHTML?(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","http"],numbers:[(0,Ke.now)()]}),t(),this.events.loadEnded$.next()):(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","http"],numbers:[(0,Ke.now)()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout))}).catch(l=>{Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_load_error","http",String(l)],numbers:[(0,Ke.now)()]}),o(),clearTimeout(r)})});this.loadAdmanNPM=e=>new Promise((t,o)=>{let r;this.events.loadStarted$.next();let a=()=>{clearTimeout(r),delete window.admanAsyncInit,window.AdmanHTML?(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_done","npm"],numbers:[(0,Ke.now)()]}),t(),this.events.loadEnded$.next()):(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","npm"],numbers:[(0,Ke.now)()]}),o())},l=()=>{d=!0,o()},d=!1,s=window.setTimeout(()=>{Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_timed_out","npm"],numbers:[(0,Ke.now)()]}),l()},this.loadTimeout);e.addEventListener("abort",l),e.aborted&&(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_aborted","npm"],numbers:[(0,Ke.now)()]}),l()),window.AdmanHTML=window.AdmanHTML||null,import("@adtech/rbadman/out/rbadman-html5.min.js").then(()=>{Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_chunk_imorted","npm","failed: "+String(d)],numbers:[(0,Ke.now)()]}),!d&&(window.AdmanHTML?(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","npm"],numbers:[(0,Ke.now)()]}),t(),this.events.loadEnded$.next()):(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","npm"],numbers:[(0,Ke.now)()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout)))},l).finally(()=>{clearTimeout(r),clearTimeout(s),e.removeEventListener("abort",l)})});this.onAdsReady=()=>{Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_ready"],numbers:[(0,Ke.now)()]}),this.log({message:"ads ready"}),this.events.ready$.next(),this.startPreroll()};this.onAdStarted=(e,t)=>{var o;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_started",e,"muted: "+t.muted],numbers:[(0,Ke.now)(),t.bannerID]}),this.adsState&&this.playerState&&this.actions?(this.log({message:`ad started, section: ${e}, banner: ${JSON.stringify(t)}`}),this.events.started$.next(e),t.muted&&(this.setVolume(0),this.actions.setMuted(!0),this.log({message:"ad muted start"})),this.adsState.duration.set(t.duration),this.adsState.playbackState.set("playing"),this.adsState.canSkip.set(t.allowClose),this.adsState.secondsToWatchBeforeSkip.set(t.allowCloseDelay),this.startWatchDog(),(o=this.externalApi)!=null&&o.videoTrackAdEvent&&this.safeExternalCall(this.externalApi.videoTrackAdEvent,e,String(t.bannerID))):this.onAdError("Started callback failed: Adman is not initialized")};this.onAdTimeRemained=e=>{var o;((o=this.adsState)!=null&&o.playbackState?ye(this.adsState.playbackState):void 0)!=="inactive"&&(this.adsState?(this.adsState.position.set(e.currentTime),this.events.timeRemained$.next(e),this.startWatchDog()):this.onAdError("TimeRemained callback failed: Adman state is not initialized"))};this.onAdPaused=()=>{var e;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_pased",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.stopWatchDog(),this.adsState?(this.log({message:"ad paused"}),this.adsState.playbackState.set("paused")):this.onAdError("Paused callback failed: Adman state is not initialized")};this.onAdPlayed=()=>{var e;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_played",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.startWatchDog(),this.adsState?(this.log({message:"ad played"}),this.adsState.playbackState.set("playing")):this.onAdError("Player callback failed: Adman is not initialized")};this.onAdMidrollPoint=()=>{if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_midroll_pioint"],numbers:[(0,Ke.now)()]}),this.adman&&this.actions){this.log({message:"midroll point"}),this.actions.switchFromVideoToAds(),this.currentAdSection="midroll",this.startWatchDog();try{this.adman.start("midroll")}catch(e){this.onAdError("could not start midroll")}}else this.onAdError("Midroll callback failed: Adman is not initialized")};this.onAdSkipped=()=>{var e;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_skipped",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.log({message:"ad skipped"}),this.stopWatchDog()};this.onAdClosed=()=>{var e;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_closed",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.log({message:"ad closed"}),this.currentAdSection&&this.events.closed$.next(this.currentAdSection),this.stopWatchDog(),this.switchToVideo()};this.onAdCompleted=()=>{var e;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_completed",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.log({message:"ad completed"}),this.currentAdSection?(this.events.ended$.next(this.currentAdSection),this.currentAdSection==="postroll"&&this.setPostrollPassed(!0)):this.events.empty$.next(),this.switchToVideo(),this.stopWatchDog()};this.onAdClicked=()=>{var e,t;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_clicked",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.log({message:"ad clicked"}),(t=this.videoElement)==null||t.pause(),this.currentAdSection&&this.events.clicked$.next(this.currentAdSection),this.stopWatchDog()};this.onAdError=(e="ad error")=>{Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_error",e],numbers:[(0,Ke.now)()]}),this.log({message:e}),this.events.error$.next(e),this.currentAdSection==="postroll"&&this.setPostrollPassed(!0),this.switchToVideo(!0),this.stopWatchDog()};this.log=e.createComponentLog("AdmanWrapper"),Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_created"],numbers:[(0,Ke.now)()]}),this.loadTimeout=t.loadTimeout,this.initTimeout=t.initTimeout,this.runtimeTimeout=t.runtimeTimeout,this.useAdmanFromNPM=t.useAdmanFromNPM,this.volumeMultiplier=Math.max(0,Math.min(t.volumeMultiplier,1)),this.isVsidOriginal=t.isVsidOriginal}init(e,t,o){this.actions=e,this.adsState=t,this.playerState=o}onAdmanLoadingError(){this.onAdError("adman loading error")}initAdman(e){return ht(this,null,function*(){var A,P;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init","already inited: "+!!this.adman],numbers:[(0,Ke.now)(),e.slotId]}),this.adman)return;this.events.init$.next(e.slotId),this.startWatchDog();let{width:t,height:o,isAutoplay:r,adsContainer:a,adsVideoElement:l,slotId:d,params:s={},paramsOverride:u={},duration:m,externalApi:p,json:v}=e;this.externalApi=p;let b,y=this.playerState&&ye(this.playerState.vsid);y&&(this.isVsidOriginal?b=y:b=parseInt(y,36));let{isEmbed:_,immediateOrigin:x}=(0,Ke.detectEmbed)(),I=(A=_?x:window.location.href)!=null?A:window.location.href,T=(0,Ke.withoutNullable)(ke(Gt(ke(Gt(ke({},s),{dl:encodeURIComponent(I),autoplay:r?1:0,player_width:t,player_height:o}),b?{request_id:b}:{}),{duration:m}),u)),R=(0,Ke.withoutNullable)({slot:v?void 0:d,wrapper:a,videoEl:l,videoQuality:o,params:v?void 0:T,browser:{mobile:!1},json:v});try{let E=new window.AdmanHTML;if(E.onReady(this.onAdsReady),E.onStarted(this.onAdStarted),E.onPlayed(this.onAdPlayed),E.onPaused(this.onAdPaused),E.adMidrollPoint(this.onAdMidrollPoint),E.onClosed(this.onAdClosed),E.onSkipped(this.onAdSkipped),E.onClicked(this.onAdClicked),E.onTimeRemained(this.onAdTimeRemained),E.onCompleted(this.onAdCompleted),E.onError(this.onAdError),E.setDebug(!1),!v&&((P=this.externalApi)!=null&&P.videoGetAds)){let z=yield this.safeExternalCall(this.externalApi.videoGetAds,T);z&&(delete R.slot,delete R.params,Object.assign(R,{json:z}))}E.init(R),this.adman=E,this.videoElement=l,this.events.slotRequested$.next(),this.log({message:`adman init, config: ${JSON.stringify(R)}`})}catch(E){Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_threw",String(E)],numbers:[(0,Ke.now)()]}),this.onAdError("could not init adman")}})}switchToVideo(e=!1){var o,r,a;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_switch_to_video",(o=this.currentAdSection)!=null?o:"","force: "+e],numbers:[(0,Ke.now)()]}),this.currentAdSection===null&&!e){this.log({message:"switch to video, no currentAdSection. can't switch"});return}let t=this.currentAdSection==="postroll";if(this.actions){if(this.adsState&&this.playerState)this.adsState.playbackState.set("inactive"),this.currentAdSection=null,this.log({message:`switch to video, isPostroll: ${t}`});else{let l="Switch to video: Adman state was not updated correctly";this.log({message:l}),this.events.error$.next(l)}(a=(r=this.actions).switchFromAdsToVideo)==null||a.call(r,!t)}}setPostrollPassed(e){var t;(t=this.adsState)==null||t.postrollPassed.set(e),this.log({message:"postroll passed"})}togglePlay(){var e;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_toggle_play",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.adsState){this.log({message:"toggle play"});let t=ye(this.adsState.playbackState);t==="playing"?this.pause():t==="paused"&&this.play()}else this.onAdError("Can not toggle play: Adman state is not initialized")}setInitialVolume(e){this.log({message:`set initial volume ${e}`}),this.initialVolume=e}setVolume(e){let t=e*this.volumeMultiplier;if(this.log({message:`set volume ${t}`}),this.adman)try{this.adman.setVolume(t)}catch(o){this.onAdError("could not set ad volume")}this.videoElement&&(this.videoElement.volume=t)}setFullscreen(e){if(this.log({message:`set fullscreen ${e}`}),this.adman)try{this.adman.setFullscreen(e)}catch(t){this.onAdError("could not set ad fullscreen")}}startPreroll(){if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_preroll"],numbers:[(0,Ke.now)()]}),this.adman){if(!this.isDestroyed){this.log({message:"start preroll"}),this.setVolume(this.initialVolume),this.currentAdSection="preroll",this.startWatchDog();try{this.adman.start("preroll")}catch(e){this.onAdError("could not start preroll")}}}else this.onAdError("Can not start preroll: Adman is not initialized")}startPostroll(){var e;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_postroll",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.adman&&this.actions){this.log({message:"start postroll"}),this.actions.switchFromVideoToAds(),this.currentAdSection="postroll",this.startWatchDog();try{this.adman.start("postroll")}catch(t){this.onAdError("could not start postroll")}}else this.onAdError("Can not start postroll: Adman is not initialized")}startWatchDog(){this.watchDogTimeout&&this.stopWatchDog(),this.watchDogTimeout=window.setTimeout(()=>this.onAdError("Watchdog timeout"),this.runtimeTimeout)}stopWatchDog(){clearTimeout(this.watchDogTimeout)}play(){var e;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_pplay",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.adman){this.log({message:"ad play"}),this.startWatchDog();try{this.adman.resume(),this.events.resumed$.next()}catch(t){this.onAdError("could not resume ad")}}else this.onAdError("Can not play: Adman is not initialized")}pause(){var e;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_pause",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.adman){this.stopWatchDog(),this.log({message:"ad pause"});try{this.adman.pause(),this.events.paused$.next()}catch(t){this.onAdError("could not pause ad")}}else this.onAdError("Can not pause: Adman is not initialized")}skip(){var e;if(Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_skip",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ke.now)()]}),this.adman){this.stopWatchDog(),this.log({message:"ad skip"});try{this.adman.skip(),this.events.skipped$.next()}catch(t){this.onAdError("could not skip ad")}}else this.onAdError("Can not skip: Adman is not initialized")}setPosition(e,t){var o;(o=this.adman)==null||o.setPosition(Math.floor(e),Math.floor(t))}destroy(){var e,t,o,r,a,l,d,s,u,m,p,v;Ke.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_destroy"],numbers:[(0,Ke.now)()]}),this.log({message:"destroy"}),this.stopWatchDog(),(e=this.adman)==null||e.onReady(void 0),(t=this.adman)==null||t.onStarted(void 0),(o=this.adman)==null||o.onPlayed(void 0),(r=this.adman)==null||r.onPaused(void 0),(a=this.adman)==null||a.adMidrollPoint(void 0),(l=this.adman)==null||l.onClosed(void 0),(d=this.adman)==null||d.onSkipped(void 0),(s=this.adman)==null||s.onClicked(void 0),(u=this.adman)==null||u.onTimeRemained(void 0),(m=this.adman)==null||m.onCompleted(void 0),(p=this.adman)==null||p.onError(void 0),(v=this.adman)==null||v.destroy(),this.videoElement&&(0,so.clearVideoElement)(this.videoElement),this.isDestroyed=!0}safeExternalCall(e,...t){return ht(this,null,function*(){var o;try{return yield e(...t)}catch(r){return this.onAdError((o=r==null?void 0:r.message)!=null?o:"External call failed"),null}})}};var Mb=i=>{let e=Math.round(i);return isNaN(e)||e<40?"":e>=40&&e<55?50:e>=55&&e<90?60:e>=90&&e<180?120:e>=180?240:""};var Ym=class{constructor(){this.oneLineRegExp=/\r\n|\n|\r/;this.twoLinesRegExp=/\r\n\r\n|\n\n|\r\r/}parse(e,t){let o=[],r=e.split(this.twoLinesRegExp);for(let a of r){let l={startTime:0,endTime:0,texts:[],lang:t},d=a.split(this.oneLineRegExp);for(let s of d)if(!l.startTime&&!l.endTime){let u=new pp,{startTime:m,endTime:p}=u.parse(s);l.startTime=m,l.endTime=p}else if(s.trim()!==""){let u=new jm,{texts:m}=u.parse(s);l.texts=[...l.texts,...m]}(l.startTime||l.endTime)&&l.texts.length>0&&o.push(l)}return o}},pp=class{constructor(){this.timeRegExp=/(\d{2,})?:?(\d{2}):(\d{2}).(\d{2,3})/;this.timingRegExp=new RegExp(`${this.timeRegExp.source}( ?--> ?)${this.timeRegExp.source}`)}parse(e){let t={startTime:0,endTime:0},o=this.timingRegExp.exec(e);return o&&(t.startTime=this.calcTime(o[1],o[2],o[3],o[4]),t.endTime=this.calcTime(o[6],o[7],o[8],o[9])),t}parseTime(e){let t=this.timeRegExp.exec(e);return t?this.calcTime(t[1],t[2],t[3],t[4]):0}isTime(e){return this.timeRegExp.test(e)}calcTime(e="0",t="0",o="0",r="0"){let a=Number(e)*60*60,l=Number(t)*60,d=Number(o),s=+`0.${r}`;return a+l+d+s}},jm=class{constructor(){this.letterTagRegExp=/<[a-z]*>|<\/[a-z]*>/}parse(e){let t={texts:[]},r=e.replace(new RegExp(this.letterTagRegExp,"g"),"").split({[Symbol.split](l){let d=0,s=[];for(;d<l.length;){let u=["<",">"].reduce((m,p)=>{let v=l.indexOf(p,d);return m===-1||m>v?v:m},-1);if(u===-1){s.push(l.substring(d));break}s.push(l.substring(d,u)),d=u+1}return s}}),a=new pp;for(let l of r)a.isTime(l)?t.texts.push({type:"timestamp",value:a.parseTime(l)}):t.texts.push({type:"text",value:l});return t}},Vb=Ym;var mp=require("@vkontakte/videoplayer-shared/es2015"),tl,Li,Xm=0,Zm=!1,Rb="",Nb=(i,e=0,t=0)=>i<e&&i<t,fp=(i,e=0,t=0)=>i>=e&&i<=t,a2=(i,e=0,t=0)=>i>e&&i>t,Db=(i,e,t,o=!1)=>{var d;let r=(d=t.find(({id:s})=>s===e.value))==null?void 0:d.subtitles;if(o)return r==null?void 0:r.find(({startTime:u,endTime:m})=>fp(i,u,m));let a=i>=Xm,l=i<Xm;if(Xm=i,l&&(Zm=!1),(0,mp.isNonNullable)(tl)&&fp(i,tl.startTime,tl.endTime)&&Rb===e.value)return tl;if(!(0,mp.isNonNullable)(Li)&&(r!=null&&r.length)&&!Zm){Li=r.find(({startTime:u,endTime:m})=>fp(i,u,m)||a&&Nb(i,u,m)),tl=void 0,!(0,mp.isNonNullable)(Li)&&r[r.length-1].endTime<i&&(Zm=!0);return}else{if(fp(i,Li==null?void 0:Li.startTime,Li==null?void 0:Li.endTime))return tl=Li,Li=void 0,Rb=e.value,tl;(a&&a2(i,Li==null?void 0:Li.startTime,Li==null?void 0:Li.endTime)||l&&Nb(i,Li==null?void 0:Li.startTime,Li==null?void 0:Li.endTime))&&(Li=void 0)}};var vp={ru:"Русский",en:"English",uk:"Українська",be:"Беларуская (тарашкевiца)",es:"Español",fi:"Suomi",de:"Deutsch",it:"Italiano",bg:"Български",hr:"Hrvatski",hu:"Magyar",sr:"Српски",pt:"Português",el:"Ελληνικά",pl:"Polski",fr:"Français",ko:"한국어","zh-CN":"汉语",lt:"Lietuvių",ja:"日本語",cs:"Čeština",et:"Eesti",tt:"Татарча",ba:"Башҡортса",cv:"Чăвашла",sk:"Slovenčina",ro:"Română",no:"Norsk",lv:"Latviešu",az:"Azərbaycan dili",hy:"Հայերեն",sv:"Svenska",nl:"Nederlands",tk:"Türkmen",ka:"ქართული",da:"Dansk",uz:"O‘zbek",th:"ภาษาไทย",id:"Bahasa Indonesia",tg:"Тоҷикӣ",sl:"Slovenščina",bs:"Bosanski","pt-BR":"Português brasileiro",fa:"فارسی",vi:"Tiếng Việt",hi:"हिन्दी",si:"සිංහල",bn:"বাংলা",tl:"Tagalog",mn:"Монгол",my:"ဗမာစာ",tr:"Türkçe",ne:"नेपाली",ur:"اردو",ky:"Кыргыз тили",pa:"پنجابی",os:"Ирон",kn:"ಕನ್ನಡ",sw:"Kiswahili",kk:"Қазақша",ar:"العربية",he:"עברית",ab:"Аҧсшәа",eu:"Euskara",eo:"Esperanto"},l2={abk:"as",ara:"ar",aze:"az",bak:"ba",bel:"be",ben:"bn",bos:"bs",bul:"bg",ces:"cs",chv:"cv",dan:"da",deu:"de",ell:"el",eng:"en",epo:"eo",est:"et",eus:"eu",fas:"fa",fin:"fi",fra:"fr",heb:"he",hin:"hi",hrv:"hr",hun:"hu",hye:"hy",ind:"id",ita:"it",jpn:"ja",kan:"kn",kat:"ka",kaz:"kk",kir:"ky",kor:"ko",lav:"lv",lit:"lt",mon:"mn",mya:"my",nep:"ne",nld:"nl",nor:"no",oss:"os",pan:"pa",pol:"pl",por:"pt",ron:"ro",rus:"ru",sin:"si",slk:"sk",slv:"sl",spa:"es",srp:"sr",swa:"sw",swe:"sv",tat:"tt",tgk:"tg",tgl:"tl",tha:"th",tuk:"tk",tur:"tr",ukr:"uk",urd:"ur",uzb:"uz",vie:"vi"},bc=i=>{var e,t;return(t=(e=vp[i])!=null?e:vp[l2[i]])!=null?t:void 0};var Jm=require("@vkontakte/videoplayer-core/es2015"),$s=require("@vkontakte/videoplayer-shared/es2015");var Ob=require("@vkontakte/videoplayer-shared/es2015"),gp=()=>{var i;return(i=(0,Ob.getWindow)().document)==null?void 0:i.pictureInPictureEnabled},hp=i=>!!i.pictureInPictureWindow,Bb=i=>!!i.target&&"height"in i.target&&"width"in i.target;var Us=class{constructor({enabled:e=!0}={enabled:!0}){this.isRequested=!1;this.videoElement=void 0;this.playerContainer=void 0;this.externalEventHandlers={};this.eventHandlers={enterpictureinpicture:this.onEnterPictureInPicture.bind(this),leavepictureinpicture:this.onLeavePictureInPicture.bind(this),resize:(0,$s.debounceFn)(this.onResize.bind(this),300)};this.info={isActive$:new $s.ValueSubject(!1),isEnabled$:new $s.ValueSubject(!1),type:0};this.info.isEnabled$=new $s.ValueSubject(e)}isSupported(){return gp()}isActive(){return this.info.isActive$.getValue()}setContext(e){this.svelteContext=e}revealPictureInPicture(){return ht(this,null,function*(){this.isRequested&&(this.removeEventHandlers(),yield this.request(),this.addEventHandlers())})}request(){return ht(this,null,function*(){var e;if(!(!this.isSupported()||this.isActive()))try{yield(e=this.videoElement)==null?void 0:e.requestPictureInPicture()}catch(t){this.isRequested=!1}})}exit(){return ht(this,null,function*(){let{document:e}=(0,$s.getWindow)();!this.isSupported()||!this.isActive()||!this.videoElement||!e.pictureInPictureElement||(yield e.exitPictureInPicture(),Jm.clientChecker.browser.isYandex&&!this.videoElement.isConnected&&this.onLeavePictureInPicture())})}assignPlayerContainer(e){this.isSupported()&&(this.playerContainer=e)}updateVideoElement(){this.isSupported()&&this.exit().finally(()=>{var t;this.removeEventHandlers();let e=this.videoElement;this.videoElement=(t=this.playerContainer)==null?void 0:t.querySelector("video"),this.waitForSafariLeavePictureInPicture(e,this.videoElement),this.addEventHandlers()})}addEventHandlers(){var e,t;(e=this.videoElement)==null||e.addEventListener("enterpictureinpicture",this.eventHandlers.enterpictureinpicture),(t=this.videoElement)==null||t.addEventListener("leavepictureinpicture",this.eventHandlers.leavepictureinpicture)}setExternalEventHandlers(e){this.externalEventHandlers=ke({},e)}removeEventHandlers(){var e,t;(e=this.videoElement)==null||e.removeEventListener("enterpictureinpicture",this.eventHandlers.enterpictureinpicture),(t=this.videoElement)==null||t.removeEventListener("leavepictureinpicture",this.eventHandlers.leavepictureinpicture)}dispose(){return ht(this,null,function*(){this.removeEventHandlers(),yield this.exit(),this.info.isActive$.next(!1),this.isRequested=!1})}onEnterPictureInPicture(e){var o,r;let t=hp(e)?e.pictureInPictureWindow:void 0;this.info.isActive$.next(!0),this.isRequested=!0,this.eventHandlers.resize(e),t==null||t.addEventListener("resize",this.eventHandlers.resize),(r=(o=this.externalEventHandlers).enterpictureinpicture)==null||r.call(o)}onLeavePictureInPicture(e){var t,o;if(e){let r=hp(e)?e.pictureInPictureWindow:void 0;r==null||r.removeEventListener("resize",this.eventHandlers.resize)}this.info.isActive$.next(!1),this.isRequested=!1,this.eventHandlers.resize.cancel(),(o=(t=this.externalEventHandlers).leavepictureinpicture)==null||o.call(t)}onResize(e){var o,r;let t=Bb(e)?e.target:hp(e)?e.pictureInPictureWindow:void 0;t&&((r=(o=this.externalEventHandlers).resize)==null||r.call(o,{width:t.width,height:t.height}))}setEnabled(e){this.info.isEnabled$.next(e)}waitForSafariLeavePictureInPicture(e,t){if(Jm.clientChecker.browser.isSafari&&e&&e!==t){let r=this.eventHandlers.leavepictureinpicture,a=0,l=()=>{(0,$s.getWindow)().clearTimeout(a),e.removeEventListener("leavepictureinpicture",d)},d=s=>(r(s),l());e.addEventListener("leavepictureinpicture",d),a=(0,$s.getWindow)().setTimeout(l,1e3)}}};function Hb(i){return i instanceof Us}var Fb=require("@vkontakte/videoplayer-shared/es2015"),rH=require("@vkontakte/videoplayer-statistics/es2015"),_p=class{constructor(e,t,o,r=new Fb.Subscription){this.oneStat=e;this.thinOneStat=t;this.mediascopePixel=o;this.statSubscription=r}destroy(){var e,t,o;(e=this.oneStat)==null||e.destroy(),(t=this.thinOneStat)==null||t.destroy(),(o=this.mediascopePixel)==null||o.destroy(),this.statSubscription.unsubscribe()}};var yc=(t=>(t.DESKTOP_CONTROL_PANEL_LEFT="desktop-control-panel-left",t.DESKTOP_CONTROL_PANEL_RIGHT="desktop-control-panel-right",t))(yc||{});var ys=i=>i!=null?i:0,zs=(i,e)=>{var r,a;let t=(r=i==null?void 0:i.getBoundingClientRect)==null?void 0:r.call(i),o=(a=e==null?void 0:e.getBoundingClientRect)==null?void 0:a.call(e);return{top:Math.round(ys(t==null?void 0:t.top)-ys(o==null?void 0:o.top)),left:Math.round(ys(t==null?void 0:t.left)-ys(o==null?void 0:o.left)),bottom:Math.round(ys(t==null?void 0:t.bottom)-ys(o==null?void 0:o.top)),right:Math.round(ys(t==null?void 0:t.right)-ys(o==null?void 0:o.left))}},id=i=>{var t;let e=(t=i==null?void 0:i.getBoundingClientRect)==null?void 0:t.call(i);return{width:ys(e==null?void 0:e.width),height:ys(e==null?void 0:e.height)}};var Bn="off";var od=i=>!!(Math.round(Math.abs(i)/90)%2);var Ub=({interfaceLanguage:i,isCyrillicRelatedInterface:e,videoId:t,isClip:o,isLiveCatchUpMode:r,statAuthToken:a,isAudioDisabled:l,canDownload:d,callbacks:s,webApi:u,videoEpisodes:m,previewThumbsData:p,uiConfig:v,coreConfig:b,player:y,disabledControls:_,isInteractive:x,interactiveRanges$:I,isInteractiveTime$:T,replayInteractive:R,stopPlayer:A,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,additionalButtons:z,additionalSettingsMenuItems:F,additionalContextMenuItems:U,playPrevVideo:X,playNextVideo:ae,onVideoChanged:Z,looped:re=!1,statistics:J,saveRate:we,internalsExposure:me,playerView:ee,playerId:_e,metaConfig:Ce})=>{var Ig,Eg;let ge=Gt(ke({},b),{isAudioDisabled:l,live:Gt(ke({},(Ig=b.live)!=null?Ig:{}),{isLiveCatchUpMode:!!r})}),pe=v,Qe=at.TracerFactory.createRootTracer(pe.features.tracer),G=Qe.createComponentTracer("Store"),D=y||new _i.Player(ge,Qe,{playerId:_e,onDevNullLog:s==null?void 0:s.onDevNullLog});me==null||me.expose({corePlayer:D});let Ge=new at.Logger,K=new up(Ge,{loadTimeout:pe.ads.loadTimeout,initTimeout:pe.ads.initTimeout,runtimeTimeout:pe.ads.runtimeTimeout,useAdmanFromNPM:pe.ads.useAdmanFromNPM,volumeMultiplier:pe.ads.volumeMultiplier,isVsidOriginal:pe.ads.isVsidOriginal}),se=Qa.getInstance(),xe=u==null?void 0:u.pictureInPictureApi,He=u==null?void 0:u.annotationsApi,it=u==null?void 0:u.slotsApi,ne=u==null?void 0:u.focusManager,ce=Ge.createComponentLog("Store"),Ne,Le,et={},Ee=new Hu,Te=new at.Subscription,Fe="",kt=de(!1),Tt=J&&J.oneStat?si(J.oneStat.vsid$):Rr(void 0),Vt=de(ca()),pt=de(!1),At=()=>sb(document,_i.clientChecker.device.isIOS),ti=(Eg=xe==null?void 0:xe.info.isActive$)!=null?Eg:new at.ValueSubject(!1),Lt=de(0),Ft=de(!1),qt=de(!1),Y=de([]),Pe=(0,at.merge)(D.events.fatalError$,D.events.managedError$).subscribe(c=>Y.update(g=>[...g,c])),le=Rr(!1,c=>{let g=D.events.fatalError$.subscribe(()=>c(!0));return()=>g.unsubscribe()}),$e=c=>ht(null,null,function*(){var ie;let g=Object.values(at.InterfaceLanguage).includes(c);if(pe.downloadVKLanguages&&(g&&pe.updateBuiltinLanguages||!cm(c))){let Se;try{Se=yield(0,at.loadVKLangPack)(c,h_,__)}catch(je){(ie=J==null?void 0:J.oneStat)==null||ie.logError({errorType:"VKLangPack",fatal:!1}),se==null||se.report(je,{errorType:"VKLangPack",fatal:!1})}Se&&(dm({language:c,pack:Se,fallback:pe.defaultLanguage}),Ve.set(c),dt.update(je=>je+1))}cm(c)&&Ve.set(c)}),Ve=de(i),dt=de(0),St=de(e);$e(i);let fe=(c,g)=>{let M=ye(Ve);return um(M,c,g,pe.defaultLanguage)},Be=de("thumb");Be.subscribe(c=>{c==="ads"&&D.info.playbackState$.getValue()&&Xt()});let We=(()=>{let c=gi([le,Be],([g,M])=>g?"crashed":M);return Gt(ke({},c),{is:g=>ye(c)===g})})(),Ct=de(),Xt=()=>{Ct.set({muted:D.info.muted$.getValue()})},It=(()=>{let c=de(new Set(_));return Gt(ke({},c),{add:g=>{c.update(M=>new Set([...M].concat(g)))},remove:g=>{c.update(M=>{let ie=[...M];return new Set(Array.isArray(g)?ie.filter(Se=>!g.includes(Se)):ie.filter(Se=>Se!==g))})},includes:g=>{let M=ye(c);return Array.isArray(g)?g.every(ie=>M.has(ie)):M.has(g)}})})(),ai=de({width:0,height:0}),fi=null,Bi=D.info.isBuffering$,Bt=Rr(Bi.getValue(),c=>{let g=Bi.subscribe(M=>{M&&fi===null?fi=window.setTimeout(()=>{c(Bi.getValue()),fi=null},pe.loaderDelay):c(M)});return()=>{g.unsubscribe(),fi&&clearTimeout(fi)}});G.log("create store"),ce({message:"create store"});let _o=c=>{let g=c.container,M=()=>{Ti=new MutationObserver(Se=>{let{removedNodes:je}=Se[0];je.length&&g.append(D.experimental.element$.getValue())}),Ti.observe(g,{childList:!0})},ie=D.experimental.element$.getValue();if(ie)g.append(ie),M();else{let Se=D.experimental.element$.pipe((0,at.filter)(je=>!!je),(0,at.once)()).subscribe(je=>{g.append(je),M()});Te.add(Se)}},vi=c=>{ce({message:`init video, config: ${JSON.stringify(c)}`}),x?_o(c):(at.devNull.push("ui",{key:"videoplayer_embed",strings:["new","core_init_video"],numbers:[(0,at.now)()]}),D.initVideo(c)),G.log("init video",{isInteractive:x}),c.subtitles&&D.setExternalTextTracks(c.subtitles),Ne=c,Fe=c.subtitlesForcedLanguage||""},ot=new at.Subject,Jt=c=>ot.next(c),Hi=new at.Subject,xi=new at.Subject,oi=new at.Subject,Ti=null,lt={actionRewind$:Hi,actionSeek$:xi,inPiP$:ti,inFullscreen$:new at.Observable(c=>Vt.subscribe(g=>c.next(g))),actionSetSubtitle$:oi,nextMovie$:ot},nt=new at.Subject,Ei=new at.Subject,tn={actionSeek$:xi,actionSubtitlesSwitched$:nt,actionQuality$:Ei,playerSize$:new at.Observable(c=>ai.subscribe(g=>c.next(g))),inPiP$:ti,inFullscreen$:new at.Observable(c=>Vt.subscribe(g=>c.next(g))),isLoaderVisible$:new at.Observable(c=>Bt.subscribe(g=>c.next(g)))};if(J){let{oneStat:c,thinOneStat:g,mediascopePixel:M,statSubscription:ie}=J;c&&(x||ie.add(c.attachTo(D)),ie.add(c.attachToUi(lt)),ie.add(c.attachToAds(K.events)),c.authorize(a).catch(Se=>{ce({message:`onestat auth error ${String(Se)}`})}),M&&M.attachTo(D)),g&&(ie.add(g.attachTo(D,K.events)),ie.add(g.attachToUi(tn)),ie.add(g.attachToAds(K.events)),g.updateContext({isMobile:ye(kt)}),g.authorize(a))}if(se){let c=new at.Subscription,g=(M,ie)=>c.add(M.subscribe(ie));if(g(D.events.managedError$,M=>{se.logIError(M)}),g(D.events.fatalError$,M=>{se.logIError(M,!0)}),J){let{oneStat:M}=J;M&&g(M.experimental.error$,ie=>{se.logIError(ie)})}se.sentrySubscription.add(c)}let Bo=()=>{if(_i.clientChecker.device.isIOS&&Le)try{ab(Le)}catch(c){ce({message:`exitIosSafariFullscreen failed: ${c}`})}};Te.add(D.experimental.element$.subscribe(c=>{c&&(Le=c,c.classList.add("player-media"),xe==null||xe.updateVideoElement(),x&&c.setAttribute("pip","false"),(ee==="preview"||!pe.features.pip&&!pe.features.dpip)&&(c.setAttribute("disablePictureInPicture","true"),c.setAttribute("x-yandex-pip","false")))})).add(D.events.ended$.subscribe(()=>{var c;Bo(),(c=s==null?void 0:s.onEnded)==null||c.call(s)})).add(D.events.looped$.subscribe(()=>{var c;(c=s==null?void 0:s.onLooped)==null||c.call(s)})).add(D.events.started$.subscribe(()=>ht(null,null,function*(){var g,M;Hb(xe)&&(yield xe==null?void 0:xe.revealPictureInPicture());let c=D.info.muted$.getValue();(g=s==null?void 0:s.onStarted)==null||g.call(s),(M=et.onStarted)==null||M.call(et,c)}))).add(D.events.willSeek$.subscribe(({from:c,to:g})=>{var M;(M=s==null?void 0:s.onSeek)==null||M.call(s,c,g)})).add(D.events.autoplaySoundProhibited$.subscribe(()=>{var c;(c=s==null?void 0:s.onAutoplaySoundProhibited)==null||c.call(s)})).add(D.info.position$.subscribe(c=>{var M;let g=D.info.duration$.getValue();isFinite(g)&&g>0&&((M=s==null?void 0:s.onTimeupdate)==null||M.call(s,g,c),K.setPosition(c,g))})).add(D.events.fatalError$.subscribe(c=>{var g;(g=s==null?void 0:s.onCrashed)==null||g.call(s,c?`${c.id}: ${c.message}`:void 0)})).add(D.events.fetcherRecoverableError$.subscribe(c=>{var g;(g=s==null?void 0:s.onRecoverableError)==null||g.call(s,c?`${c.id}: ${c.message}`:void 0)})).add(D.events.loadedMetadata$.subscribe(()=>{Ft.set(!0)})).add(D.info.is3DVideo$.subscribe(c=>{qt.set(c)})).add(D.info.isEnded$.subscribe(c=>{x&&(c?(T!=null&&T.getValue()&&It.add(Yd),It.add("PLAY_BUTTON")):It.remove("PLAY_BUTTON"))})).add(D.info.liveTime$.subscribe(c=>{var g;(g=s==null?void 0:s.onLiveTime)==null||g.call(s,c)})).add(D.info.isStalled$.subscribe(c=>{var g;(g=s==null?void 0:s.onStalledChanged)==null||g.call(s,c)})).add(D.info.isLiveEnded$.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onLiveEnded)==null?void 0:g.call(s))})).add(K.events.loadStarted$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onLoadStarted)==null?void 0:g.call(c)})).add(K.events.loadEnded$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onLoadEnded)==null?void 0:g.call(c)})).add(K.events.loadError$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onLoadError)==null?void 0:g.call(c)})).add(K.events.init$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onInit)==null?void 0:g.call(c)})).add(K.events.ready$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onReady)==null?void 0:g.call(c)})).add(K.events.started$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onStarted)==null?void 0:M.call(g,c)})).add(K.events.timeRemained$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onTimeRemained)==null?void 0:M.call(g,c)})).add(K.events.ended$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onCompleted)==null?void 0:M.call(g,c)})).add(K.events.empty$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onEmpty)==null?void 0:g.call(c)})).add(K.events.clicked$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onClicked)==null?void 0:M.call(g,c)})).add(K.events.closed$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onClosed)==null?void 0:M.call(g,c)})).add(K.events.error$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onError)==null?void 0:M.call(g,c)})).add(K.events.paused$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onPaused)==null?void 0:g.call(c)})).add(K.events.resumed$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onResumed)==null?void 0:g.call(c)}));let bt=new at.Subscription,Ut=()=>{var je,Mt,zt;let{debugLog:c}=pe,g,M="#9df7b7",ie="#efd169";if(c&&c!==!0){let{colors:Yt}=c;g=c.tag,M=(je=Yt==null?void 0:Yt[0])!=null?je:M,ie=(zt=(Mt=Yt==null?void 0:Yt[1])!=null?Mt:Yt==null?void 0:Yt[0])!=null?zt:ie}let Se=g?`: ${g}`:"";bt.add(D.events.log$.subscribe(Yt=>{console.debug(`%c sdk${Se} `,`background:${M};`,`sdk component: ${Yt.component}`,Yt.message)})).add(Ge.log$.subscribe(Yt=>{console.debug(`%c ui${Se} `,`background:${ie};`,`ui component: ${Yt.component}.`,Yt.message)}))},W=()=>{bt.unsubscribe()},Rt=(c,g)=>{G.log("start camera manual rotation",{mx:c,my:g}),D.startCameraManualRotation(c,g)},li=(c=!1)=>{G.log("stop camera manual rotation",{immediate:c}),D.stopCameraManualRotation(c)},gt=(c,g,M)=>{G.log("move camera focus px",{xpx:c,ypx:g,dt:M}),D.moveCameraFocusPX(c,g,M)},ii=()=>{D.holdCamera()},xt=()=>{D.releaseCamera()},st=Rr(D.info.position$.getValue(),c=>{let g,M,ie=()=>{let Se=D.info.playbackState$.getValue(),je=D.info.isLive$.getValue(),Mt=D.info.duration$.getValue(),zt=D.info.position$.getValue();if(Se&&[_i.PlaybackState.PLAYING,_i.PlaybackState.PAUSED].includes(Se)){let Yt=je?zt-Mt:D.getExactTime();Yt!==M&&c(Yt),M=Yt}g=requestAnimationFrame(ie)};return ie(),()=>cancelAnimationFrame(g)}),Fi=si(D.info.playbackState$),Mi=si(D.info.isBuffering$),vn=gi([Fi,Mi],([c,g])=>g?"buffering":c),gn=si(D.info.currentBuffer$),Vi=si(D.info.isEnded$),Ui=si(D.info.isLive$),Hn=pe.features.playbackRate?si(D.info.canChangePlaybackSpeed$):Rr(!1),bo=si(D.info.liveBufferTime$),lo=si(D.info.volume$),Ai=si(D.info.muted$),Ho=Fu(D.info.predefinedQualityLimitType$.pipe((0,at.map)(c=>c===_i.PredefinedQualityLimits.TRAFFIC_SAVING)),D.info.predefinedQualityLimitType$.getValue()===_i.PredefinedQualityLimits.TRAFFIC_SAVING),Fo=Fu(D.info.predefinedQualityLimitType$.pipe((0,at.map)(c=>c===_i.PredefinedQualityLimits.HIGH_QUALITY)),D.info.predefinedQualityLimitType$.getValue()===_i.PredefinedQualityLimits.HIGH_QUALITY),hn=si(D.info.autoQualityLimitingAvailable$),Or=si(D.info.availableQualities$),Br=si(D.info.availableQualitiesFps$),Hr=si(D.info.chromecastState$),Ss=si(D.info.chromecastDeviceName$),Fr=si(D.info.currentFormat$),nr=si(D.info.throughputEstimation$),Ur=si(D.info.videoBitrate$),_n=si(D.info.intrinsicVideoSize$),bn=si(D.info.duration$),_r=si(D.info.isAudioAvailable$),br=()=>{fi&&clearTimeout(fi),fi=null},on=gi([bn,Ui],([c,g])=>g?-c:c),$r=gi([Fi],([c])=>c===_i.PlaybackState.PLAYING),yr=si(D.info.atLiveEdge$),rr=si(D.info.atLiveDurationEdge$),Fn=si(D.info.position$),cs=gi([Fn,bn],([c,g])=>isFinite(c)&&isFinite(g)&&!!g),xo=gi([Hr],([c])=>c===_i.ChromecastState.CONNECTED),xr=si(D.info.availableVideoStreams$),zi=pe.features.audioLanguages?si(D.info.availableAudioStreams$):Rr([]),wr=si(D.info.currentVideoStream$),Un=si(D.info.currentAudioStream$),vt=c=>{c.language&&rm(c.language),D.setVideoStream(c)},ni=(c,g)=>{D.setAudioStream(c),Uo(g)&&(c.language&&rm(c.language),pe.features.userVideoPrefs&&t&&lm(pe.userSalt,String(t),{audioTrackId:c.id}))},Sr=c=>{let g;if(c.length===1&&(g=c.at(0)),g!=null||(g=c.find(ie=>"isDefault"in ie&&ie.isDefault)),pe.features.userVideoPrefs&&t){let ie=qu(pe.userSalt,String(t));if(ie!=null&&ie.audioTrackId){let Se=c.find(je=>je.id===ie.audioTrackId);g=Se!=null?Se:g}}let M=K_();return M&&(g!=null||(g=c.find(({language:ie})=>M===ie))),g!=null||(g=c.at(0)),g},zr=c=>{G.log("change audio stream",{id:c});let g=D.info.availableAudioStreams$.getValue().find(M=>M.id===c);g&&ni(g,!0)},Wr=!1;Te.add(D.info.availableAudioStreams$.subscribe(c=>{if(!Wr&&c.length){let g=Sr(c);g&&(D.setAudioStream(g),Wr=!0)}})),zi.subscribe(c=>{var g;(g=s==null?void 0:s.onAvailableAudioStreamsChanged)==null||g.call(s,c.map(({label:M="",id:ie="",language:Se=""})=>({label:M,language:Se,id:ie})))}),Un.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onAudioStreamChanged)==null?void 0:g.call(s,c.id))});let zn=!1;Te.add(D.info.availableVideoStreams$.subscribe(c=>{if(!zn&&c.length){let g=Sr(c);g&&(D.setVideoStream(g),zn=!0)}}));let sr=de(void 0),wo=si(D.info.isAutoQualityEnabled$,c=>c&&sr.set(void 0)),Wn=si(D.info.currentQuality$,()=>sr.set(void 0)),ar=gi([sr,Wn],([c,g])=>c!=null?c:g),Kn=gi(Fr,c=>c!==_i.VideoFormat.MPEG),$n=gi([Or,Br,wo,ar,Kn],([c,g,M,ie,Se])=>{let je=[];Se&&je.push({value:"auto",displayValue:fe("auto_quality_option"),selected:M});let Mt=c.filter(zt=>!(0,at.isInvariantQuality)(zt));for(let zt of Mt){let Yt=g[zt];je.push({value:zt,displayValue:`${zt}${Yt?Mb(Yt):""}`,selected:M?!1:zt===ie})}return je}),yn=si(D.info.currentPlaybackRate$),xn=gi([yn,yr,rr],([c,g,M])=>{let ie=M||x?1:pe.controls.playbackRateMin,Se=g?1:pe.controls.playbackRateMax,je=pe.controls.playbackRateStep,Mt=[];for(let zt=ie;zt<=Se;zt+=je)Mt.push({value:zt,displayValue:zt===1?fe("playback_rate_1"):fe("playback_rate",{multiplier:zt.toString(10)}),selected:c===zt});return Mt}),nn=()=>({displayValue:fe("subtitles_off"),value:Bn,language:""}),Wi=de(nn()),eo=gi([Wi,dt],([c],g)=>{c.value===Bn?g(nn()):g(c)}),rn=pe.features.subtitles?si(D.info.availableTextTracks$):Rr([]),lr=M_(),Cr=gi([rn,eo],([c,g],M)=>{var je;let ie=[],Se=c.find(({id:Mt})=>Mt===g.value);if(Se!=null&&Se.url){let[,Mt]=(je=lr.find(Se.url))!=null?je:[];if(Mt){M(Mt);return}Ee.download(Se.url).then(zt=>{if(!zt||Ee.isDestroyed())return;let Yt=new Vb,Js=Se.language;if(Js){let U$=!!Se.isAuto,z$=Yt.parse(zt,Js);ie.push({lang:Js,subtitles:z$,isAuto:U$,id:Se.id})}lr.add(Se.url,ie),ye(eo).value===g.value&&M(ie)}).catch(zt=>{var Yt;(Yt=J==null?void 0:J.oneStat)==null||Yt.logError({errorType:"Subtitles download",fatal:!1}),se==null||se.report(zt,{errorType:"Subtitles download",fatal:!1})})}M(ie)}),wn=gi([yn,$r,eo],([c,g,M],ie)=>{let Mt;if(D.info.isLive$.getValue()&&g&&M.value!==Bn){let Yt=()=>{let Js=1e3/(3*c);Mt=setTimeout(Yt,Js),ie(Date.now())};return Yt(),()=>clearTimeout(Mt)}}),Tr=gi([rn,eo],([c,g])=>{if(!c.length)return[];let M=[];for(let{language:ie,isAuto:Se,id:je}of c){let Mt=ie&&bc(ie);ie&&Mt&&M.push({displayValue:Se?fe("subtitles_auto",{language:Mt}):Mt,value:je,selected:(g==null?void 0:g.value)===je,isAuto:Se,language:ie})}return M.length?(M.unshift(Gt(ke({},nn()),{selected:(g==null?void 0:g.value)===Bn})),M):[]}),ft={available:[],prev:[]},Nt=()=>{var g,M;let c=D.experimental.getCurrentTime$.getValue();return(M=(g=c==null?void 0:c())!=null?g:Le==null?void 0:Le.currentTime)!=null?M:0},So=gi([st,eo,Cr,wn],([c,g,M,ie])=>{var je;let Se=D.info.isLive$.getValue();if(Se&&ft.prev!==M){let Mt=M.find(({id:Yt})=>Yt===g.value),zt=ft.prev.find(({id:Yt})=>Yt===g.value);if(Mt){let Yt=Gt(ke({},Mt),{subtitles:[...(je=zt==null?void 0:zt.subtitles)!=null?je:[],...Mt.subtitles]});ft.available=[Yt],ft.prev=M}}if(g&&g.value!==Bn){let Mt=Se?Nt():c,zt=Se?ft.available:M;return Db(Mt,g,zt,Se)}}),Sn=gi([So],([c])=>c!=null&&c.texts?c.texts:[]);Te.add(eo.subscribe(c=>{var g,M;if(c.value===Bn)(g=s==null?void 0:s.onSubtitleOff)==null||g.call(s);else{let ie=Object.entries(vp).find(([Se,je])=>je===c.displayValue);(M=s==null?void 0:s.onSubtitleOn)==null||M.call(s,ie?ie[0]:"",c.value)}}));let Co=de(!0),sn=gi([gn,on,Fn,bo],([c,g,M,ie])=>{var zt;let Se=(zt=c==null?void 0:c.end)!=null?zt:0;if(!ie)return Se/g;let Mt=-M+ie-g;return(Se-Mt)/g}),co=si(D.info.availableSources$),To=gi([co],([c])=>Object.keys((c==null?void 0:c[_i.VideoFormat.MPEG])||{}).length>0),Pi=()=>{var M,ie,Se;let c=Object.keys(((ie=(M=D.info.availableSources$)==null?void 0:M.getValue())==null?void 0:ie[_i.VideoFormat.MPEG])||{}),g=(0,at.getHighestQuality)(c)||at.VideoQuality.Q_144P;return(Se=Ne.sources[_i.VideoFormat.MPEG])==null?void 0:Se[g]},Kr=()=>{var g;let c=Pi();if(c)G.log("download video",{url:c}),k_(c,((g=Ne==null?void 0:Ne.meta)==null?void 0:g.title)||"video");else{let M="There is no URL for download video";G.log("download video",{message:M}),ce({message:M})}},qn=()=>{ce({message:"toggle muted"});let c=D.info.muted$.getValue();D.info.volume$.getValue()===0&&!c?qr(Ir(),!1):an(!c,!1)},Cs=()=>{var c;if(Qt.ui.settingsMenu.visible$.set(!1),!ye(Qt.ui.settingsSubMenu.visible$)){let g=ye(Qt.ui.settingsMenu.ref$);if((c=s==null?void 0:s.uiInfo)!=null&&c.onSettingsMenu&&g){let ie=id(g),Se={top:0,left:0,bottom:0,right:0};s.uiInfo.onSettingsMenu({visible:!1,size:ie,position:Se,name:"settings"})}}G.log("close settings menu")},Ki=(c,g=()=>Promise.resolve())=>ht(null,null,function*(){var Se;Qt.ui.settingsMenu.openedByBtnKeyboard$.set(!!c),Qt.ui.settingsMenu.visible$.set(!0),yield g();let M=ye(Qt.ui.settingsMenu.ref$),ie=Ia();if((Se=s==null?void 0:s.uiInfo)!=null&&Se.onSettingsMenu&&M&&ie){let Mt=id(M),zt=zs(M,ie);s.uiInfo.onSettingsMenu({visible:!0,size:Mt,position:zt,name:"settings"})}G.log("open settings menu",{wasOpenedByKeyboard:c})}),Ts=(c,g=!1)=>{var je;Qt.ui.settingsSubMenu.visible$.set(!1);let M=ye(Qt.ui.settingsMenu.ref$),ie=Ia(),Se=ye(Qt.ui.settingsMenu.visible$);if((je=s==null?void 0:s.uiInfo)!=null&&je.onSettingsMenu&&M&&ie)if(Se&&!g){let zt=id(M),Yt=zs(M,ie);s.uiInfo.onSettingsMenu({visible:!0,size:zt,position:Yt,name:"settings"})}else{let zt=id(c),Yt={top:0,left:0,bottom:0,right:0},Js=ye(Qt.ui.settingsSubMenu.name$);s.uiInfo.onSettingsMenu({visible:!1,size:zt,position:Yt,name:Js})}G.log("close settings sub menu")},us=(c,g)=>{var ie;Qt.ui.settingsSubMenu.visible$.set(!0),Qt.ui.settingsSubMenu.ref$.set(g),Qt.ui.settingsSubMenu.name$.set(c);let M=Ia();if((ie=s==null?void 0:s.uiInfo)!=null&&ie.onSettingsMenu&&g&&M){let je=id(g),Mt=zs(g,M);s.uiInfo.onSettingsMenu({visible:!0,name:c,size:je,position:Mt})}G.log("open settings sub menu",{name:c})},Ir=()=>{var g;let c=Math.max(pe.volumeMinRestore,(g=Uu())!=null?g:0);return c===0?pe.volumeDefault:c},Uo=c=>{let g=pe.features.savePreferredStatesOnUserActionOnly;return!g||g&&!c},qr=(c,g)=>{let M=c===0?Ir():c,ie=D.info.muted$.getValue();ce({message:`set volume, volume: ${c}, preferredVolume: ${M}`});let Se=!l||We.is("ads");ie&&c>0&&Se&&(ie=!1,Uo(g)&&om(!1)),D.setVolume(c,ie),K.setVolume(c),Uo(g)&&Jf(M)},an=(c,g)=>{let M=D.info.volume$.getValue();ce({message:`set muted, currentVolume: ${M}, mute: ${c}`});let ie=We.is("ads");if(D.setMuted(c,ie),K.setVolume(c?0:M),Uo(g)&&(!ie||!c)&&om(c),!c&&M===0){let Se=Ir();D.setVolume(Se),Uo(g)&&Jf(Se),K.setVolume(Se)}},ln=de(!1),Ue=c=>{var g,M;G.log("set looped",{isLooped:c}),ln.set(c),D.setLooped(c),(M=(g=s==null?void 0:s.uiInfo)==null?void 0:g.onLoopedChanged)==null||M.call(g,c)};Ue(re);let Et=()=>{var c,g;(g=(c=s==null?void 0:s.uiInfo)==null?void 0:c.onReportProblem)==null||g.call(c)},mi=(c,g=!1)=>{var M;ce({message:`set autoplayNextEnabled, value: ${c}`}),G.log("set autoplay next enabled",{autoplayNextEnabled:c}),Qt.ui.autoplayNextEnabled$.set(c),G_(c),g&&((M=s==null?void 0:s.onSetAutoplayNextEnabled)==null||M.call(s,c))},zo=c=>{ce({message:`set timerNextVideoRunning, value: ${c}`}),G.log("set timer next video running",{timerNextVideoRunning:c}),Qt.ui.timerNextVideoRunning$.set(c)},Io=(c=!0)=>{var M;let g=!0;if(c&&(s!=null&&s.onPrevVideoClick))try{g=(M=s==null?void 0:s.onPrevVideoClick)==null?void 0:M.call(s)}catch(ie){ce({message:"onPrevVideoClick callback failed to execute"})}Z(!0),g&&X()},Wo=(c=!0)=>{var M;let g=!0;if(c&&(s!=null&&s.onNextVideoClick))try{g=(M=s==null?void 0:s.onNextVideoClick)==null?void 0:M.call(s)}catch(ie){ce({message:"onNextVideoClick callback failed to execute"})}Z(!1),g&&ae()},qi=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementShow)==null||c.call(s)},Eo=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementClick)==null||c.call(s)},Qn=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementAuto)==null||c.call(s)},Er=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementCancel)==null||c.call(s)},Po=()=>{D.prepare()},uo=()=>{(0,at.assertNonNullable)(Qt);let c=ye(Qt.ui.controls.disabledControls$),g=ye(Qt.playerPhase),M={playerPhase:g,isInteractive:x,isVideoEnded:!1,action:"none"};if(c.has("PLAY_BUTTON"))return;if(ce({message:"toggle play"}),g==="ads"){M.action="play",G.log("toggle adman play",M),K.togglePlay();return}let ie=()=>{var je;ce({message:"toggle play, call player.play"}),M.action="play",D.play(),(je=s==null?void 0:s.onPlay)==null||je.call(s)},Se=()=>{var je;ce({message:"toggle play, call player.pause"}),M.action="pause",D.pause(),(je=s==null?void 0:s.onPause)==null||je.call(s)};if(D.info.isEnded$.getValue()){if(ce({message:"toggle play, video ended, seek to 0"}),Hi.next(),xi.next(xs.SeekAction.REWIND),x){R==null||R();return}D.seekTime(0),ie()}else D.info.playbackState$.getValue()!==_i.PlaybackState.PLAYING?ie():Se();G.log("toggle play",M)},Cn=(c,{changeReason:g="default",appliesTo:M="to-video",byUser:ie=!1}={},Se)=>{ce({message:`set quality, quality: ${c}`}),G.log("set quality",{quality:c}),ie&&Ei.next(c),D.setAutoQuality(c==="auto");let{qualityDetailsSubMenuEnabled:je}=pe.features;zu(),c!=="auto"?(je?(Wu({type:"exact_quality",quality:c,videoId:t},M),D.setPredefinedQualityLimits(_i.PredefinedQualityLimits.UNKNOWN)):em(t,c),sr.set(c),D.setQuality(c)):je&&g==="default"&&(Gr("auto_quality",M,Se),ye(Ho)&&Ko(!1,void 0,Se),ye(Fo)&&Gn(!1,void 0,Se))},Ko=(c,g="as-default",M)=>{ce({message:`set trafficSavingEnabled, value: ${c}`}),G.log("set traffic saving enabled",{trafficSavingEnabled:c});let ie=c?_i.PredefinedQualityLimits.TRAFFIC_SAVING:_i.PredefinedQualityLimits.UNKNOWN;pe.features.qualityDetailsSubMenuEnabled?(Qr(ie,g,M),Zd(!1)):(D.setPredefinedQualityLimits(ie),Uo(M)&&Zd(c))},Gn=(c,g="as-default",M)=>{ce({message:`set highQualityEnabled, value: ${c}`}),G.log("set high quality enabled",{highQualityEnabled:c}),Qr(c?_i.PredefinedQualityLimits.HIGH_QUALITY:_i.PredefinedQualityLimits.UNKNOWN,g,M)},Qr=(c,g,M)=>{c!==_i.PredefinedQualityLimits.UNKNOWN&&(ye(hn)&&!ye(wo)&&Cn("auto",{appliesTo:g,changeReason:"limit-changed"},M),Gr(c,g,M)),D.setPredefinedQualityLimits(c)},Gr=(c,g,M)=>{Uo(M)&&(Wu({type:c,videoId:t},g),g==="as-default"&&Wu({type:c,videoId:t},"to-video"))},Yn=(c,g=!0)=>{G.log("set playback rate",{playbackRate:c}),D.setPlaybackRate(c),pe.features.saveRate&&we&&!D.info.isLive$.getValue()&&g&&q_(c)},Je=()=>{let c=ye(Hn),g=ye(xn),M=g.findIndex(({selected:Se})=>Se);if(M===g.length-1||!c)return g[M];let ie=g[M+1];return Yn(ie.value),ie},ei=()=>{let c=ye(Hn),g=ye(xn),M=g.findIndex(({selected:Se})=>Se);if(M===0||!c)return g[M];let ie=g[M-1];return Yn(ie.value),ie},wi=(c=Gt(ke({},nn()),{selected:!1}),g)=>{G.log("set subtitles",ke({},c)),c.value!==Bn&&oi.next(c.isAuto?c.value+"_auto":c.value),nt.next({enabled:c.value!==Bn,lang:c.language,auto:!!c.isAuto}),Wi.set(c),Uo(g)&&(am(c.value===Bn?void 0:c.language),pe.features.userVideoPrefs&&t&&lm(pe.userSalt,String(t),{subtitleTrackId:c.value===Bn?void 0:c.value}))},ko=c=>{G.log("toggle subtitles");let g=ye(eo);(g==null?void 0:g.value)===Bn?jn(c):qo(c)},Tn=(c,g)=>{G.log("change subtitle",{enabled:c}),c?jn(!0,g):qo(!0)},jn=(c,g)=>{G.log("subtitle on");let M=ye(Tr),ie=ye(Ve),Se=Fe!=null?Fe:ie,je;g&&(je=M.find(Mt=>Mt.value===g)),je!=null||(je=M.filter(Mt=>Mt.value!==Bn).find(Mt=>Mt.language===Se)),wi(je!=null?je:M[1],c)},qo=c=>{G.log("subtitle off"),wi(void 0,c)};Te.add(D.info.availableTextTracks$.subscribe(c=>{var M;function g(){let ie=[];for(let{language:Se,isAuto:je,id:Mt}of c){let zt=Se&&bc(Se);Se&&zt&&ie.push({id:Mt,language:Se,title:je?fe("subtitles_auto",{language:zt}):zt})}return ie}(M=s==null?void 0:s.onAvailableSubtitlesChanged)==null||M.call(s,g())}));let dr=de(!0),ps=c=>{dr.set(c)},Pr=(c,g,M=!0)=>{var ie;if(ce({message:`seek to time, time: ${c}`}),G.log("seek to time",{time:c,action:g,forcePrecise:M}),xi.next(g),D.info.isLive$.getValue()){let Se=D.info.duration$.getValue(),je=Math.min(0,Se+c);D.seekTime(je,M)}else{if(T!=null&&T.getValue())return;D.info.isEnded$.getValue()&&(ce({message:"seek after ended, call callbacks.onPlay"}),(ie=s==null?void 0:s.onPlay)==null||ie.call(s)),D.seekTime(dn(c),M)}},Is=c=>{ce({message:`seek to episode start time: ${c}`}),G.log("seek to episode start time",{time:c}),Pr(c,xs.SeekAction.EPISODE,!0)},Ys=(c,g,M=!1)=>{ce({message:`seek to percent, percent: ${c}`}),G.log("seek to percent",{percent:c,action:g});let ie=ye(on)*c;Pr(ie,g,M)},ya=c=>{ce({message:`seek external, time: ${c}`}),G.log("seek external",{time:c}),xi.next(xs.SeekAction.UNKNOWN),D.seekTime(D.info.isLive$.getValue()?-c:c)},ct=c=>{var ie,Se;let g=(ie=c.max)!=null?ie:"none",M=(Se=c.min)!=null?Se:"none";ce({message:`set auto quality limitation. Max: ${g}. Min: ${M}`}),G.log("set auto quality limits",{max:g,min:M}),D.setAutoQualityLimits(c)},di=c=>{ce({message:`seek external to episode start time: ${c}`}),G.log("seek external to episode start time",{time:c}),Pr(c,xs.SeekAction.EPISODE,!0)},Ao=c=>{ce({message:`set playback rate to: ${c}`}),G.log("set playback rate external",{playbackRate:c}),D.setPlaybackRate(c)},Si=de(!1),In=de(!1),En=gi([on],([c])=>!!p&&c>=pe.suitableDurationForUsingRichSeek&&pe.features.useRichSeek&&!x),Es=((p==null?void 0:p.frameWidth)||0)>=((p==null?void 0:p.frameHeight)||0),Ps=gi([Lt],([c])=>{let g=od(c);return Es?!g:g});Te.add(We.subscribe(c=>{c!=="video"&&Si.set(!1)})),Si.subscribe(c=>{var g;(g=s==null?void 0:s.onRichSeekActiveChanged)==null||g.call(s,c)});let Qi=de(void 0),ki=de(!1),he=c=>{ce({message:`start scrubbing, progress: ${c}`}),G.log("start scrubbing",{progress:c}),ki.set(!0),wt(c)},wt=c=>{Qi.set(c)},ci,Zt,Lo=()=>{Qi.set(void 0),ki.set(!1)},po=()=>{clearTimeout(Zt),clearTimeout(ci),ci=window.setTimeout(()=>{Lo()},500),Le==null||Le.removeEventListener("seeked",po)},Qo=(c,g=!1)=>{ce({message:`complete scrubbing, progress: ${c}`}),G.log("complete scrubbing",{progress:c}),Ys(c,xs.SeekAction.SLIDER,g),ye(Qt.ui.isMobile)&&ye(Qt.state.currentFormat$)===_i.VideoFormat.HLS?(Le==null||Le.addEventListener("seeked",po),Zt=window.setTimeout(()=>{po()},300)):Lo()},ks=gi([st,on,Qi],([c,g,M],ie)=>{ie((0,at.isNonNullable)(M)?M*g:c)}),Yr=de(!1),kr=()=>{Yr.set(!0)},xa=()=>{Yr.set(!1)},js=gi([ai],([{width:c}],g)=>{let M=Ib(c);g(M)}),wa=z.filter(c=>A_(c)),jr=gi([js,kt],([c,g])=>g?wa.filter(M=>!M.hideOnMobile):wa.filter(M=>{var ie;return!((ie=M.hideOnDesktopGridTypes)!=null&&ie.includes(c))})),Pn=de(z.filter(c=>L_(c))),gl=gi([Pn,js],([c,g])=>c.filter(M=>{var ie;return!((ie=M.hideOnDesktopGridTypes)!=null&&ie.includes(g))})),Sa=gi([gl,jr],([c,g])=>[...pe.features.additionalButtonsDesktopControlPanelRight?c.filter(M=>M.type==="desktop-control-panel-right"):[],...pe.features.additionalButtons?g.map((M,ie)=>{var Se;return{id:ie,weight:ie,type:"desktop-control-panel-right",testId:M.testId,icon:M.iconUrl,onClick:M.onClick,ariaLabel:(Se=M.ariaLabel)!=null?Se:M.tooltip,tooltipText:M.tooltip}}):[]].filter(M=>!v.disabledAdditionalButtonIds.includes(M.id))),Xr=de(F),hl=gi([Xr],([c])=>pe.features.additionalSettingsMenuItems?c.map(g=>g.type==="SWITCH"?Gt(ke({},g),{onClick:g.onChangeEnabled}):g):[]),hd=(c,g)=>{let M=ye(Pn).map(ie=>ie.id!==c?ie:ke(ke({},ie),g));Pn.set(M)},Ca=c=>{let g=ye(Pn);if(g.some(M=>M.id===c.id)){ce({message:`Additional button with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),Pn.set(g)},_d=c=>{let g=ye(Pn);if(!g.some(M=>M.id===c)){ce({message:`Can't find additional button with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),Pn.set(g)},_l=c=>{xi.next(xs.SeekAction.LIVE),ce({message:"live switch to low latency "+c}),G.log("live switch to low latency "+c),D.setLiveLowLatency(c)},bl=(c,g)=>{let M=ye(Xr).map(ie=>ie.id!==c?ie:ke(ke({},ie),g));Xr.set(M)},Ta=c=>{let g=ye(Xr);if(g.some(M=>M.id===c.id)){ce({message:`Settings menu item with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),Xr.set(g)},mt=c=>{let g=ye(Xr);if(!g.some(M=>M.id===c)){ce({message:`Can't find settings menu item with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),Xr.set(g)},rt=de(U),to=gi([rt],([c])=>pe.features.additionalContextMenuItems?c:[]),Mo=(c,g)=>{let M=ye(rt).map(ie=>ie.id!==c?ie:ke(ke({},ie),g));rt.set(M)},io=c=>{let g=ye(rt);if(g.some(M=>M.id===c.id)){ce({message:`Context menu item with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),rt.set(g)},bi=c=>{let g=ye(rt);if(!g.some(M=>M.id===c)){ce({message:`Can't find context menu item with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),rt.set(g)},Gi=gi([kt,le],([c,g],M)=>{M(c&&g)}),Xs=()=>{xi.next(xs.SeekAction.LIVE),ce({message:"switch to active live"}),G.log("switch to active live"),D.seekTime(0),D.info.playbackState$.getValue()!==_i.PlaybackState.PLAYING&&Qt.actions.internal.togglePlay()},bd=()=>{G.log("skip adman"),K.skip()},Zc=(c=!0)=>{var ie;(0,at.assertNonNullable)(Qt),ce({message:`switch from ads to video, callPlay: ${c}`}),G.log("switch from ads to video",{callPlay:c}),Be.set("video"),c&&D.play(),l&&an(!0,!0);let g=(ie=ye(Ct))==null?void 0:ie.muted,M=!D.info.muted$.getValue();g!==void 0&&!M&&an(g,!0),Ct.set(void 0)},qp=()=>{(0,at.assertNonNullable)(Qt),ce({message:"switch from video to ads"}),G.log("switch from video to ads"),Qt.actions.internal.pause(),Bo(),Be.set("ads")},Jc=c=>{(0,at.assertNonNullable)(Qt);let g=c?"LiveWaitingStart":"thumb";G.log("set live waiting start",{state:c,playerPhase:g}),Be.set(g)},Qp=c=>{(0,at.assertNonNullable)(Qt);let g=c?"LiveWaitingRecover":"thumb";G.log("set live waiting recover",{state:c,playerPhase:g}),Be.set(g)},eu=c=>{(0,at.assertNonNullable)(Qt);let g=c?"LiveWaitingRecord":"thumb";G.log("set live waiting record",{state:c,playerPhase:g}),Be.set(g)},Gp=()=>((0,at.assertNonNullable)(Qt),G.log("get debug text data"),E_(D,Ne,Qt,Qe.getTraceId(),Ce)),tu=()=>((0,at.assertNonNullable)(Qt),JSON.stringify(Qe.getFinishedSpans())),Yp=()=>((0,at.assertNonNullable)(Qt),P_(D,Ne,Qt)),Ia=()=>Le,iu=()=>{ce({message:"toggle chromecast"}),G.log("toggle chromecast"),D.toggleChromecast()},Zs=c=>{var M;if((0,at.assertNonNullable)(Qt),D.info.isEnded$.getValue())return;let g=!c;if(ye(Qt.playerPhase)==="ads"){ce({message:`pause ads, internalCall: ${g}`}),G.log("pause ads",{internalCall:g}),K.pause();return}ce({message:`pause video, internalCall: ${g}`}),G.log("pause video",{internalCall:g}),g&&((M=s==null?void 0:s.onPause)==null||M.call(s)),D.pause()},$l=c=>{var M;(0,at.assertNonNullable)(Qt);let g=!c;if(ye(Qt.playerPhase)==="ads"){ce({message:`play ads, internalCall: ${g}`}),G.log("play ads",{internalCall:g}),K.play();return}ce({message:`play video, internalCall: ${g}`}),G.log("play video",{internalCall:g}),g&&((M=s==null?void 0:s.onPlay)==null||M.call(s)),D.play()},ou=c=>{(0,at.assertNonNullable)(Qt);let g=!c;if(ye(Qt.playerPhase)==="ads"){ce({message:"player cannot be stopped during ads via external method"});return}ce({message:`player will be stopped, internalCall: ${g}`}),A==null||A()},nu=(c,g)=>{(0,at.assertNonNullable)(Qt),ce({message:`first start, show ads: ${c}, internalCall: ${!g}`}),G.log("first start",{showAds:c,external:g}),c?Be.set("ads"):(Be.set("video"),g?D.play():Qt.actions.internal.togglePlay())},yl=()=>(ce({message:"getting time codes"}),m),ru=()=>{let c=yl();if(!c||[0,1].includes(c.length))return;let g=D.info.position$.getValue();return c.find(M=>M.time>g)},su=c=>{let g=c;g||(g=ru());let M=D.info.position$.getValue();G.log("seek to next episode",ke({currentTime:M},g)),g&&(ce({message:"seek to next episode"}),Pr(g.time,xs.SeekAction.EPISODE,!0))},au=()=>{let c=yl();if(!c||[0,1].includes(c.length))return;let g=D.info.position$.getValue(),M=c.findIndex(Se=>Se.time>g),ie=M===-1?c.length-2:M-2;if(!(ie<0))return c[ie]},jp=c=>{let g=c;g||(g=au());let M=D.info.position$.getValue();G.log("seek to prev episode",ke({currentTime:M},g)),g&&(ce({message:"seek to prev episode"}),Pr(g.time,xs.SeekAction.EPISODE,!0))},Xp=()=>(ce({message:"getting preview thumbs data"}),G.log("get preview thumbs data",ke({},p)),p),ze=()=>ht(null,null,function*(){let c=xe==null?void 0:xe.isActive(),g="none";xe!=null&&xe.isActive()?(g="exit",yield xe==null?void 0:xe.exit()):(g="request",yield xe==null?void 0:xe.request()),G.log("toggle picture in picture",{isActive:c,action:g})}),$i=(c=-90)=>{G.log("rotate video",{alphaDiff:c}),Lt.update(g=>g+c)},fo=de([]);I==null||I.subscribe(c=>{let g=[];for(let M=0;M<c.length;M++){let{range:[ie,Se],subjects:je}=c[M];M===0&&ie!==0&&g.push({time:0,text:"",interactive:!1,completed:!0}),g.push({time:ie/1e3,text:"",interactive:!0,completed:pe.features.interactiveTimeOpenUri?!je.length||je.every(Mt=>Mt.isRemoved):!je.length}),Se!==1/0&&g.push({time:Se/1e3,text:"",interactive:!1,completed:!0})}fo.set(g)});let Ar=de(!1);T==null||T.subscribe(c=>{c&&ye(ki)&&Lo()});let dn=c=>{if(!x)return c;let g=ye(fo),M=ye(on),Se=ye(Fn)/M,je=g.find(Mt=>Mt.interactive&&!Mt.completed&&Mt.time>Se);return typeof(je==null?void 0:je.time)=="number"?Math.min(c,je.time-.05):c},R$=()=>{Qt.ui.episodes.panelOpened$.set(!1)},N$=()=>{G.log("destroy store"),clearTimeout(Zt),clearTimeout(ci),Te.unsubscribe(),bt.unsubscribe(),D.destroy(),K.destroy(),J==null||J.destroy(),se==null||se.destroy(),Pe.unsubscribe(),Ti==null||Ti.disconnect(),Ti=null,Ee.destroy()},D$=gi([yr,We,Hn],([c,g,M])=>v.features.doubleForwardAvailable&&!c&&g==="video"&&M),Zp=de(!1),Cg=2,lu=null,Tg=c=>{if(!ye($r)&&c)return;let g=D.info.currentPlaybackRate$.getValue();c?g!==Cg&&(lu=g,Yn(Cg,!1),Zp.set(!0)):(lu&&Yn(lu,!1),Zp.set(!1),lu=null)};We.subscribe(c=>{c!=="video"&&Tg(!1)});let O$=()=>{Zs(!1),Si.set(!0)},B$=()=>{$l(!1),Si.set(!1)},Jp=!1,H$=()=>{In.set(!0),Jp=D.info.playbackState$.getValue()===_i.PlaybackState.PLAYING,Zs(!1)},F$=()=>{In.set(!1),!ye(Si)&&Jp&&$l(!1),Jp=!1};D.events.playing$.subscribe(()=>{ye(Si)&&Zs(!1)});let Qt={interfaceLanguage$:Ve,isCyrillicRelatedInterface$:St,initVideo:vi,videoId:t,isClip:o,playerPhase:We,vsid:Tt,state:{positionExact$:st,positionWithScrubbing$:ks,duration$:on,playbackState$:Fi,playbackStateRealistic$:vn,isPlaying$:$r,isLoaderVisible:Bt,bufferedProgress$:sn,isLive$:Ui,canChangePlaybackSpeed$:Hn,isActiveLive$:yr,isOldestAvailableLive$:rr,isRewindableLive$:cs,isEnded$:Vi,muted$:Ai,volume$:lo,trafficSavingEnabled$:Ho,highQualityEnabled$:Fo,autoQualityLimitingAvailable$:hn,availableVideoStreams$:xr,availableAudioStreams$:zi,videoStream$:wr,audioStream$:Un,currentQuality$:ar,isAutoQualityEnabled$:wo,availableQualities$:$n,currentPlaybackRate$:yn,availablePlaybackRates$:xn,currentSubtitle$:eo,availableTextTracks$:rn,availableSubtitlesList$:Tr,currentSubtitleCaptions$:Sn,isAutoSubtitleCaptionVisible$:Co,chromecastState$:Hr,chromecastDeviceName$:Ss,chromecastConnected$:xo,currentFormat$:Fr,throughputEstimation$:nr,videoBitrate$:Ur,videoSize$:_n,errorLog$:Y,crashed$:le,isAudioAvailable$:_r,isAudioDisabled:!!l,canDownload:pe.features.download&&!!d,availableSources$:co,hasMpegSources$:To,isInteractive:x,showInteractiveGraph:pe.features.interactiveGraph,showSeekToInteractive:pe.features.seekToInteractive,showPlayPrevChapter:pe.features.interactivePlayPrevChapter,showInteractiveTimeIndicator:pe.features.interactiveTimeIndicator&&!!ye(fo).length,interactiveEpisodes$:fo,isInteractiveTime$:T?si(T):de(!1),isInteractiveExpectation$:Ar,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,looped$:ln,loadedMetadata$:Ft,isAutoQualityAvailable$:Kn,previewTrackActive:Si,previewTrackDragInProgress:In},ui:{t:fe,controlsVisible:de(!1),touched:de(!1),controls:{prevButton:de(void 0),playButton:de(void 0),replayButton:de(void 0),nextButton:de(void 0),playPrevChapterButton:de(void 0),seekToInteractiveButton:de(void 0),interactiveGraphButton:de(void 0),liveButton:de(void 0),time:de(void 0),episodes:de(void 0),volume:de(void 0),subtitles:de(void 0),settings:de(void 0),context:de(void 0),chromecast:de(void 0),pip:de(void 0),fullscreen:de(void 0),vkLogo:de(void 0),interactiveTimeIndicator:de(void 0),timeline:de(void 0),autoplayNextToggle:de(void 0),additionalButtons:z.length?z.reduce(c=>[...c,de(void 0)],[]):[],disabledControls$:It},modals:{hotKeyMap:{show:de(!1),data:de({title:"",closeBtnText:"",groups:[]})}},isFullscreen:Vt,isFullscreenOpenedByKeyboard:pt,rotateAlpha:Lt,isAutoplay:de(!1),debugPanelVisible:de(!1),episodes:{panelOpened$:de(!1),openedByKeyboard$:de(!1)},contextMenu:{visible$:de(!1),btnRef$:de(void 0),openedByBtnKeyboard$:de(!1),openedByHotKey$:de(!1),lastActiveElem$:de(void 0),showContextMenuBtn$:de(!1),position$:de({top:0,left:0})},playerSize:ai,isMobile:kt,mobileNotReportControlHidden$:Gi,icon3DVideoVisible:de(!1),scrubbingInProgress:ki,volumeChangingInProgress:Yr,is3DVideo:qt,currentGridType$:js,additionalButtonsDeprecated$:jr,additionalDesktopControlPanelRightButtons$:Sa,additionalSettingsMenuItems$:hl,additionalContextMenuItems$:to,interactiveHideMobileControls:de(!1),overlayContainer$:de(void 0),startedByKeyboard$:de(!1),autoplayNextEnabled$:de(!1),timerNextVideoRunning$:de(!0),settingsMenu:{visible$:de(!1),ref$:de(void 0),openedByBtnKeyboard$:de(!1)},settingsSubMenu:{visible$:de(!1),ref$:de(void 0),name$:de(void 0)},userActionsDisabled:de(!1),hiddenControls:{volume:de(!1),vkLogo:de(!1),pip:de(!1),chromecast:de(!1),settings:de(!1)},isControlsAvailable:dr,controlBlocks:{topLeft:de(void 0),topRight:de(void 0),middle:de(void 0),bottom:de(void 0),bottomLeft:de(void 0),bottomRight:de(void 0)},videoTitleInfo:de(void 0),doubleForwardOn$:Zp,doubleForwardAvailable$:D$,previewTrackNotificationVisible:de(!1),previewTrackActive:Si,previewTrackDragInProgress:In,previewTrackAvailable:En,isPreviewTrackHorizontallyAligned:Ps},ads:{position:de(0),duration:de(0),playbackState:de("inactive"),canSkip:de(!1),secondsToWatchBeforeSkip:de(0),postrollPassed:de(!1)},webApi:{pictureInPictureApi:xe,annotationsApi:He,slotsApi:it,focusManager:ne},actions:{internal:{preload:Po,firstStart:c=>nu(c,!1),play:()=>$l(!1),pause:()=>Zs(!1),togglePlay:uo,toggleMuted:qn,openSettingsMenu:Ki,closeSettingsMenu:Cs,openSettingsSubMenu:us,closeSettingsSubMenu:Ts,setVolume:c=>qr(c,!1),setMuted:c=>an(c,!1),startVolumeChanging:kr,stopVolumeChanging:xa,setVideoStream:vt,setAudioStream:c=>ni(c,!1),setQuality:(c,g)=>Cn(c,g,!1),setTrafficSavingEnabled:(c,g)=>Ko(c,g,!1),setHighQualityEnabled:(c,g)=>Gn(c,g,!1),setPlaybackRate:Yn,incrementPlaybackRate:Je,decrementPlaybackRate:ei,setSubtitle:c=>wi(c,!1),toggleSubtitle:()=>ko(!1),togglePictureInPicture:ze,startScrubbing:he,progressScrubbing:wt,completeScrubbing:Qo,toggleChromecast:iu,switchToActiveLive:Xs,switchFromAdsToVideo:Zc,switchFromVideoToAds:qp,skipAd:bd,setLiveWaitingStart:Jc,setLiveWaitingRecover:Qp,setLiveWaitingRecord:eu,getDebugTextData:Gp,getTraceTextData:tu,getDebugPanelData:Yp,getVideoElement:Ia,seekTime:(c,g,M)=>Pr(c,g,M),clearDelayedBufferingCheckTimeout:br,seekEpisodeStartTime:Is,seekToPercent:Ys,getNextEpisode:ru,seekToNextEpisode:su,getPrevEpisode:au,seekToPrevEpisode:jp,startLogging:Ut,stopLogging:W,startCameraManualRotation:Rt,stopCameraManualRotation:li,moveCameraFocusPX:gt,holdCamera:ii,releaseCamera:xt,getVideoEpisodes:yl,getPreviewThumbsData:Xp,downloadVideo:Kr,addLanguage:dm,setLanguage:$e,nextMovie:Jt,videoRotate:$i,correctSeekTimeToInteractive:dn,replayInteractive:R,setLooped:Ue,reportProblem:Et,setAutoplayNextEnabled:mi,setTimerNextVideoRunning:zo,prevVideoClick:Io,nextVideoClick:Wo,nextVideoAnnouncementShow:qi,nextVideoAnnouncementClick:Eo,nextVideoAnnouncementAuto:Qn,nextVideoAnnouncementCancel:Er,checkFullscreenSupport:At,changeDoubleForwardOn:Tg,closePreviewTrack:B$,previewTrackOpened:O$,previewTrackDragStarted:H$,previewTrackDragFinished:F$},external:{firstStart:c=>nu(c,!0),play:()=>$l(!0),pause:()=>Zs(!0),stop:()=>ou(!0),seekTime:c=>ya(c),seekEpisodeStartTime:c=>di(c),setPlaybackRate:c=>Ao(c),setAutoQualityLimits:c=>ct(c),setMuted:c=>an(c,!0),toggleSubtitle:()=>ko(!0),changeSubtitle:Tn,setVolume:c=>qr(c,!0),returnFocusToEpisodes:R$,updateAdditionalSettingsItem:bl,addAdditionalSettingsItem:Ta,removeAdditionalSettingsItem:mt,updateAdditionalContextItem:Mo,addAdditionalContextItem:io,removeAdditionalContextItem:bi,updateAdditionalButton:hd,addAdditionalButton:Ca,removeAdditionalButton:_d,setLiveLowLatency:_l,hideControls:()=>ps(!1),showControls:()=>ps(!0),setQuality:c=>Cn(c,{appliesTo:"to-video"},!0),setTrafficSavingEnabled:c=>Ko(c,"to-video",!0),setHighQualityEnabled:c=>Gn(c,"to-video",!0),changeAudioStream:zr}},callbacks:s,setUiCallbacks:c=>{et=ke({},c)},getAdmanWrapper:()=>K,getLogger:()=>Ge,getPlayer:()=>D,destroy:N$};return Qt};function ir(i,e,t,o){var m;let r=(m=e[t])==null?void 0:m.getBoundingClientRect(),a=o&&!!r&&!!(r.right-r.left),{top:l,left:d,bottom:s,right:u}=zs(e[t],i||void 0);return{left:a?d:0,right:a?u:0,top:a?l:0,bottom:a?s:0,isDisplayed:a}}var d2=["disabledControls$","additionalButtons"],c2=["interactiveTimeIndicator"],rd=(i,e,t,o)=>{if(i){for(let[r,a]of Object.entries(e))if(!d2.includes(r)){let l=o||c2.includes(r);a.set(ir(i,t,r,l))}}};var bp=(i,e,t)=>ht(null,null,function*(){yield ho(),e&&t&&(t.focus(),i.set(!1))});var u2=Ie('<path d="M18 10c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2Zm-6 4c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2Zm-6 0c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2Z"></path>');function tv(i){Ze(i,{children:(e,t)=>{var o=u2();$(e,o)},$$slots:{default:!0}})}function iv(i,e){B(e,!0);let[t,o]=De(),r=()=>w(s,"$contextMenuVisible$",t),a=h(e,"disabled",3,!1),l=h(e,"ariaLabel",3,""),d=be(),s=d.ui.contextMenu.visible$,u=d.ui.contextMenu.openedByBtnKeyboard$,m=d.ui.contextMenu.showContextMenuBtn$,p=d.ui.contextMenu.position$,v=d.ui.contextMenu.btnRef$,b=q(void 0);Oe(()=>{n(b)&&Pt(()=>{v.set(n(b))})});let y=T=>{let R=fa(T),A=_b(n(b));p.set(A),u.set(R),s.set(!r())},_=()=>{m.set(!0)},x=()=>{m.set(!1)},I=f(()=>r()?"opened":"");Kt(i,{get className(){return n(I)},testId:"btn-context-menu",get disabled(){return a()},get ariaLabel(){return l()},click:y,focus:_,blur:x,get ariaExpanded(){return r()},get ref(){return n(b)},set ref(T){N(b,T,!0)},children:(T,R)=>{tv(T,{})},$$slots:{default:!0}}),H(),o()}var p2=i=>{i.stopPropagation()},f2=L("<div><!> <div></div> <div></div></div>"),m2={hash:"s-22",code:'.interactive-episode-icon-animated.s-22{height:32px;opacity:1;position:absolute;right:16px;top:16px;transition:.3s;width:32px}.interactive-episode-icon-animated.icon-small.s-22{height:28px;width:28px}.invisible.s-22{opacity:0;visibility:hidden}.fullscreen.s-22:not(.mobile){height:40px;right:23px;top:19px;width:40px}.mobile.s-22{height:28px;right:14px;top:12px;width:28px}.fullscreen.mobile.s-22{height:32px;width:32px}@media screen and (orientation:portrait){.interactive-episode-icon-animated.mobile.fullscreen.s-22{right:16px;top:40px}}@keyframes s-22-pulse{0%{border-width:1px;opacity:0;transform:scale(1)}10%{opacity:1}50%{border-width:1px;opacity:.5;transform:scale(1.5)}to{border-width:.5px;opacity:0;transform:scale(1.5)}}.pulse.s-22{animation:s-22-pulse 1s infinite;border:1px solid #fff;border-radius:100%;bottom:0;content:"";display:block;left:0;pointer-events:none;position:absolute;right:0;top:0;transform:scale(1.8);transition:.3s}.pulse.paused.s-22{animation-play-state:paused}.interactive-episode-icon-animated svg{height:100%;width:100%}.ref-block.s-22{height:100%;position:absolute;top:0;visibility:hidden;width:100%}.hidden.s-22{display:none}'};function xc(i,e){var K;B(e,!0),Q(i,m2);let[t,o]=De(),r=()=>w(x,"$isMobile",t),a=()=>w(A,"$areControlsVisible",t),l=()=>w(E,"$currentGridType$",t),d=()=>w(T,"$isInteractiveTime$",t),s=()=>w(_,"$interactiveControlsOpacity$",t),u=()=>w(R,"$showInteractiveTimeIndicatorTooltip$",t),m=()=>w(I,"$isFullscreen",t),p=h(e,"ref",15,void 0),v=q(void 0),b=be(),y=yo(),{interactiveControlsOpacity$:_}=y,x=b.ui.isMobile,I=b.ui.isFullscreen,T=b.state.isInteractiveTime$,R=y.showInteractiveTimeIndicatorTooltip$,A=b.ui.controlsVisible,P=(K=b.callbacks)==null?void 0:K.onInteractiveTimeIndicatorClick,E=b.ui.currentGridType$,z=f(()=>!r()&&a()),F=f(()=>Fs(l(),"s")),U=f(()=>!d()||!!s()||n(z)),X=q(!1);Oe(()=>{N(X,n(U),!0)});let ae=()=>{N(X,!0)},Z=()=>{var se;re(),(se=n(v))==null||se.addEventListener("animationiteration",ae,{once:!0})},re=()=>{var se;N(X,!1),(se=n(v))==null||se.removeEventListener("animationiteration",ae)},J=se=>{R.set(se)},we=f(()=>u()&&!n(U));Oe(()=>{u()?Z():re()});let me=()=>{n(U)||(R.set(!0),P==null||P())};pn(()=>{R.clearTimeout(),re()});let ee=()=>{R.set(!1)},_e=j("tooltip_interactive_interaction_time_indicator");var Ce=f2();let ge;Ce.__mousemove=[p2],Ce.__click=me;var pe=C(Ce);Do(pe,{get tooltipContent(){return _e},get tooltipVisible(){return n(we)},initialTranslateYPx:72,tooltipPlacement:"bottom",onTooltipVisibilityChange:J,get ref(){return p()},set ref(se){p(se)},children:(se,xe)=>{pc(se,{completed:!0})},$$slots:{default:!0}});var Qe=k(pe,2);let G;Xe(Qe,se=>p(se),()=>p());var D=k(Qe,2);let Ge;Xe(D,se=>N(v,se),()=>n(v)),S(Ce),O((se,xe,He)=>{ge=oe(Ce,1,"interactive-episode-icon-animated s-22",null,ge,se),G=oe(Qe,1,"ref-block s-22",null,G,xe),Ge=oe(D,1,"pulse s-22",null,Ge,He)},[()=>({mobile:r(),fullscreen:m(),invisible:n(U),"icon-small":n(F)}),()=>({hidden:n(U)}),()=>({paused:n(X)})]),ut("mouseleave",Ce,ee),$(i,Ce),H(),o()}Ye(["mousemove","click"]);function $p(i,e){B(e,!0);let t=h(e,"tooltipEnabled",3,!0),o=h(e,"disabled",3,!1),r=h(e,"className",3,void 0),a=h(e,"ref",15),l=h(e,"tooltipVisible",3,!1);Do(i,{get disabled(){return o()},get tooltipContent(){return e.tooltipText},get disabledTooltipContent(){return e.disabledTooltipContent},get hasTooltip(){return t()},get mouseEnter(){return e.mouseEnter},get mouseLeave(){return e.mouseLeave},get tooltipVisible(){return l()},get className(){return r()},get ref(){return a()},set ref(d){a(d)},children:(d,s)=>{var u=Me();let m=f(()=>e.buttonComponent);var p=ue(u);Di(p,()=>n(m),(v,b)=>{b(v,rs(()=>{var y;return(y=e.buttonComponentProps)!=null?y:{}}))}),$(d,u)},$$slots:{default:!0}}),H()}var Ws={prevButton:100,replayButton:200,playButton:300,nextButton:400,playPrevChapterButton:500,seekToInteractiveButton:600,interactiveGraphButton:700,liveButton:800};var g2=Ie('<path d="M32 21.68V15a2 2 90 114 0v18a2 2 90 01-4 0v-6.66l-16.3 9.32A2.48 2.48 90 0112 33.56V14.46c0-1.9 2.06-3.08 3.7-2.12z"></path>');function _a(i,e){B(e,!0);let t=h(e,"reversed",3,!1),o=f(()=>t()?"transform: scaleX(-1);transform-origin: 50%;":void 0),r=f(()=>`${fn(e.size)}${n(o)}`),a=f(()=>t()?"prev-icon":"next-icon");Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(r)},get testId(){return n(a)},get shadow(){return e.shadow},children:(l,d)=>{var s=g2();$(l,s)},$$slots:{default:!0}}),H()}var h2=L('<div class="icon-background-mobile s-1z"><!></div>'),_2={hash:"s-1z",code:".icon-background-mobile.s-1z{align-items:center;background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);display:flex;height:100%;justify-content:space-around;left:0;position:absolute;top:0;width:100%}"};function il(i,e){B(e,!0),Q(i,_2);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"disabled",3,!1),l=be().ui.t,d=f(()=>e.type==="prev"?l("tooltip_previous"):l("tooltip_next")),s=f(()=>e.type==="prev"?l("hotkey_map_item_prev_video_value"):l("hotkey_map_item_next_video_value")),u=f(()=>`btn-${o()?"m":"d"}--${e.type}`);Kt(i,{get className(){return n(u)},get testId(){var m;return`btn-${(m=e.type)!=null?m:""}`},get disabled(){return r()},get ariaLabel(){return n(d)},get click(){return e.click},get ariaKeyShortCut(){return n(s)},get ref(){return t()},set ref(m){t(m)},children:(m,p)=>{var v=Me(),b=ue(v);{var y=x=>{var I=h2(),T=C(I);let R=f(()=>e.type==="prev");_a(T,{get size(){return"32"},get reversed(){return n(R)}}),S(I),$(x,I)},_=x=>{let I=f(()=>e.type==="prev");_a(x,{get size(){return"24"},get reversed(){return n(I)}})};V(b,x=>{o()?x(y):x(_,!1)})}$(m,v)},$$slots:{default:!0}}),H()}var b2=Ie('<path d="M24 21.2a.8.8 90 01-1.34.6L14.08 14a1.34 1.34 90 010-2l8.6-7.8a.8.8 90 011.32.6V11a16 16 90 11-16 16 2 2 90 114 0 12 12 90 1012-12z"></path>');function wc(i,e){B(e,!0);let t=f(()=>fn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(t)},testId:"replay-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=b2();$(o,a)},$$slots:{default:!0}}),H()}var zb=require("@vkontakte/videoplayer-shared/es2015");var $2=L('<div class="icon-background-mobile s-25"></div>'),y2=L("<!> <div><!></div>",1),x2={hash:"s-25",code:".mobile.s-25{align-items:center;display:flex;justify-content:center;position:relative}.icon-background-mobile.s-25{background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);height:calc(100% - 32px);left:16px;position:absolute;top:16px;width:calc(100% - 32px)}"};function sd(i,e){B(e,!0),Q(i,x2);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"disabled",3,!1),a=h(e,"className",3,""),l=h(e,"click",3,zb.noop),d=j("tooltip_restart"),s=f(()=>`${o()?"btn-m--play":""} ${a()}`);Kt(i,{get className(){return n(s)},testId:"replay-btn",get ariaLabel(){return d},get disabled(){return r()},get click(){return l()},get ariaKeyShortCut(){return bs.KeyK},get ref(){return t()},set ref(u){t(u)},children:(u,m)=>{var p=y2(),v=ue(p);{var b=T=>{var R=$2();$(T,R)};V(v,T=>{o()&&T(b)})}var y=k(v,2);let _;var x=C(y);let I=f(()=>o()?"48":"24");wc(x,{get size(){return n(I)}}),S(y),O(T=>_=oe(y,1,"s-25",null,_,T),[()=>({mobile:o()})]),$(u,p)},$$slots:{default:!0}}),H()}var w2=Ie('<path d="m17.4 10 1.6.2a2 2 90 01.8.8l.2 1.6v22.8l-.2 1.6a2 2 90 01-.8.8l-1.6.2h-4l-1.4-.2a2 2 90 01-.8-.8l-.2-1.6V12.6l.2-1.6a2 2 90 01.8-.8l1.6-.2h3.801zm16 0 1.6.2a2 2 90 01.8.8l.2 1.6v22.8l-.2 1.6a2 2 90 01-.8.8l-1.6.2h-4l-1.4-.2a2 2 90 01-.8-.8l-.2-1.6V12.6l.2-1.6a2 2 90 01.8-.8l1.6-.2h4z"></path>');function Ks(i,e){B(e,!0);let t=f(()=>fn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(t)},testId:"pause-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=w2();$(o,a)},$$slots:{default:!0}}),H()}var Wb=require("@vkontakte/videoplayer-shared/es2015");var S2=L('<div class="icon-background-mobile s-27"><!></div>'),C2={hash:"s-27",code:".icon-background-mobile.s-27{align-items:center;background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);display:flex;height:calc(100% - 32px);justify-content:space-around;left:16px;position:absolute;top:16px;width:calc(100% - 32px)}"};function ad(i,e){B(e,!0),Q(i,C2);let[t,o]=De(),r=()=>w(a,"$fakeIsPlaying$",t),{fakeIsPlaying$:a}=yo(),l=h(e,"ref",15,void 0),d=h(e,"isMobile",3,!1),s=h(e,"isPlaying",3,!1),u=h(e,"disabled",3,!1),m=h(e,"className",3,""),p=h(e,"click",3,Wb.noop),b=be().ui.t,{toggle:y}=a,_=f(()=>y),x=f(()=>r()!==null),I=f(()=>n(x)?r():s()),T=f(()=>n(I)?b("tooltip_pause"):b("tooltip_play")),R=f(()=>n(I)?Ks:Dn),A=f(()=>`${d()?"btn-m--play":""} ${m()}`),P=f(()=>n(x)?n(_):p());Kt(i,{get className(){return n(A)},testId:"play-btn",get click(){return n(P)},get disabled(){return u()},get ariaLabel(){return n(T)},get ariaKeyShortCut(){return bs.KeyK},get ref(){return l()},set ref(E){l(E)},children:(E,z)=>{var F=Me();let U=f(()=>n(R));var X=ue(F);{var ae=re=>{var J=S2(),we=C(J);Di(we,()=>n(U),(me,ee)=>{ee(me,{get size(){return"48"}})}),S(J),$(re,J)},Z=re=>{var J=Me(),we=ue(J);Di(we,()=>n(U),(me,ee)=>{ee(me,{get size(){return"24"}})}),$(re,J)};V(X,re=>{d()?re(ae):re(Z,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}var T2=Ie('<path d="M12.58 12.92v2.5a1 1 0 0 1-1.52.85l-5.58-3.42a1 1 0 0 1 0-1.7l5.58-3.42a1 1 0 0 1 1.52.86v2.5l5.48-3.36a1 1 0 0 1 1.52.86v6.82a1 1 0 0 1-1.52.86z"></path>');function ov(i){Ze(i,{testId:"play-prev-chapter-icon",children:(e,t)=>{var o=T2();$(e,o)},$$slots:{default:!0}})}function Sc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"hidden",3,!1),r=h(e,"disabled",3,!1),a=j("tooltip_interactive_go_back"),l=f(()=>o()?"hidden":"");Kt(i,{get className(){return n(l)},testId:"play-prev-chapter-btn",get ariaLabel(){return a},get disabled(){return r()},get click(){return e.click},get ref(){return t()},set ref(d){t(d)},children:(d,s)=>{ov(d,{})},$$slots:{default:!0}}),H()}var I2=L('<span class="gutter s-21"><span><!></span></span>'),E2={hash:"s-21",code:".gutter.s-21{--gutterWidth:32px;--gutterHeight:12px;--togglerWidth:18px;--togglerHeight:18px;--togglerGap:calc(var(--togglerWidth)/6);background-color:hsla(0,0%,100%,.3);border-radius:50px;height:var(--gutterHeight);position:relative;width:var(--gutterWidth)}.toggler.s-21{align-items:center;background-color:#626364;border-radius:50%;display:flex;height:var(--togglerHeight);justify-content:center;left:0;position:absolute;top:calc((var(--togglerHeight) - var(--gutterHeight))/2*-1);transform:translateX(calc(var(--togglerGap)*-1));transition-duration:.2s;transition-property:background-color,transform;transition-timing-function:ease;width:var(--togglerWidth)}.toggler.enabled.s-21{background-color:var(--toggle-color-autoplay-on);transform:translateX(calc(var(--gutterWidth) - var(--togglerWidth) + var(--togglerGap)))}"};function Cc(i,e){B(e,!0),Q(i,E2);let[t,o]=De(),r=()=>w(s,"$autoplayNextEnabled$",t),a=h(e,"ref",15,void 0),l=be(),d=l.ui.t,s=l.ui.autoplayNextEnabled$,u=l.actions.internal.setAutoplayNextEnabled,m=()=>{u(!r(),!0)},p=d("aria_label_autoplay"),v="12",b="#000",y=f(()=>r()?"true":"false");Kt(i,{click:m,get ariaLabel(){return p},role:"switch",get areaChecked(){return n(y)},get ref(){return a()},set ref(_){a(_)},children:(_,x)=>{var I=I2(),T=C(I);let R;var A=C(T);{var P=z=>{Dn(z,{get size(){return v},fill:b})},E=z=>{Ks(z,{get size(){return v},fill:b})};V(A,z=>{r()?z(P):z(E,!1)})}S(T),S(I),O(z=>R=oe(T,1,"toggler s-21",null,R,z),[()=>({enabled:r()})]),$(_,I)},$$slots:{default:!0}}),H(),o()}var P2=Ie('<path d="M16.73 4.85c-.54-.05-1.23-.05-2.23-.05H7.9a.9.9 0 1 1 0-1.8h6.64q1.41-.01 2.33.05c.64.05 1.2.16 1.73.43a4.4 4.4 0 0 1 1.92 1.92c.27.52.38 1.09.43 1.73q.06.92.05 2.33v5.08q.01 1.41-.05 2.33a5 5 0 0 1-.43 1.73 4.4 4.4 0 0 1-1.92 1.92 5 5 0 0 1-1.73.43q-.92.06-2.33.05H7.9a.9.9 0 1 1 0-1.8h6.6c1 0 1.69 0 2.23-.04.52-.05.82-.13 1.05-.24a2.6 2.6 0 0 0 1.14-1.14c.11-.23.2-.53.24-1.06s.04-1.23.04-2.22v-5c0-1 0-1.69-.04-2.23a3 3 0 0 0-.24-1.05 2.6 2.6 0 0 0-1.14-1.14c-.23-.11-.53-.2-1.05-.24"></path><path d="M7.76 11.17V8.9c0-.71.7-1.15 1.25-.78l4.6 3.1a.96.96 0 0 1 0 1.54L9 15.87c-.55.37-1.25-.07-1.25-.78v-2.26l-4.5 3.04C2.7 16.24 2 15.8 2 15.09V8.91c0-.71.7-1.15 1.25-.78z "></path>',1);function nv(i){Ze(i,{testId:"seek-to-interactive-icon",children:(e,t)=>{var o=P2();pi(),$(e,o)},$$slots:{default:!0}})}function Tc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"hidden",3,!1),r=h(e,"disabled",3,!1),a=j("tooltip_interactive_seek"),l=f(()=>o()?"hidden":"");Kt(i,{get className(){return n(l)},testId:"btn-seek-to-interactive",get ariaLabel(){return a},get disabled(){return r()},get click(){return e.click},get ref(){return t()},set ref(d){t(d)},children:(d,s)=>{nv(d,{})},$$slots:{default:!0}}),H()}var k2=Ie('<path d="M15.2 5.9v1.2c0 .6 0 .9.12 1.12q.15.3.46.46c.23.12.52.12 1.12.12h1.2c.6 0 .9 0 1.12-.12q.3-.15.46-.46c.12-.23.12-.52.12-1.12V5.9c0-.6 0-.9-.12-1.12a1 1 0 0 0-.46-.46c-.23-.12-.52-.12-1.12-.12h-1.2c-.6 0-.9 0-1.12.12q-.3.15-.47.46c-.11.23-.11.53-.11 1.12m-.05 11.03v1.14c0 .6 0 .91.12 1.14q.15.31.47.47c.23.12.53.12 1.14.12h1.22c.6 0 .9 0 1.14-.12a1 1 0 0 0 .47-.47c.12-.23.12-.53.12-1.14v-1.14c0-.6 0-.9-.12-1.14a1 1 0 0 0-.47-.47c-.23-.12-.54-.12-1.14-.12h-1.22c-.6 0-.91 0-1.14.12a1 1 0 0 0-.47.47c-.12.23-.12.53-.12 1.14"></path>'),A2=Ie('<path d="M16.78 3h1.42q.47 0 .83.02.4.02.82.21.61.31.92.92.2.41.21.81.03.36.02.83v1.4q0 .47-.02.83-.02.4-.21.81a2 2 0 0 1-.92.92 2 2 0 0 1-.82.21q-.36.02-.83.02h-1.42q-.47 0-.84-.02a2 2 0 0 1-.81-.2 2 2 0 0 1-.93-.93 2 2 0 0 1-.2-.8l-.03-.64h-2.2c-.49 0-.8 0-1.04.02a1 1 0 0 0-.35.06 1 1 0 0 0-.35.35 1 1 0 0 0-.07.35c-.02.24-.02.55-.02 1.04v5.57c0 .5 0 .8.02 1.04s.05.31.07.34q.12.23.35.35c.03.02.11.05.34.07s.56.02 1.05.02h2.2q0-.34.02-.62.01-.4.21-.81.31-.61.93-.92.42-.2.81-.21.37-.02.84-.02h1.42q.47 0 .83.02.4.01.82.2.61.31.92.93.2.41.21.8.03.37.02.84v1.4q0 .47-.02.83-.02.39-.21.81a2 2 0 0 1-.92.92q-.43.2-.82.21-.36.02-.83.02h-1.42q-.47 0-.84-.02a2 2 0 0 1-.81-.21 2 2 0 0 1-.93-.92 2 2 0 0 1-.2-.81l-.03-.63h-2.24q-.68 0-1.16-.03a3 3 0 0 1-1.01-.26 2.6 2.6 0 0 1-1.14-1.14 3 3 0 0 1-.26-1q-.04-.5-.03-1.16v-1.93H2.9A.9.9 0 0 1 2 12c0-.5.4-.9.9-.9h5.23V9.18q0-.68.03-1.16.02-.51.26-1.02a2.6 2.6 0 0 1 1.14-1.13q.5-.24 1.02-.26.48-.04 1.16-.02h2.23q0-.34.02-.63.01-.4.21-.81.31-.61.93-.92.42-.2.81-.21.37-.02.84-.02m-.84 1.84.15-.02c.16-.02.37-.02.72-.02h1.35c.36 0 .57 0 .72.02l.15.02a.3.3 0 0 1 .12.12l.03.15.01.71v1.34l-.01.71-.02.15a.3.3 0 0 1-.13.13l-.15.02-.72.01h-1.35l-.72-.01-.15-.03a.3.3 0 0 1-.12-.12l-.02-.15-.02-.71V5.82q0-.5.02-.71l.02-.15a.3.3 0 0 1 .12-.12m0 11.02.15-.03.72-.01h1.35l.72.01.15.03a.3.3 0 0 1 .12.12l.03.15.01.71v1.34l-.01.71-.02.15a.3.3 0 0 1-.13.12l-.15.02c-.15.02-.36.02-.72.02h-1.35c-.35 0-.56 0-.72-.02l-.15-.02a.3.3 0 0 1-.12-.12l-.02-.15-.02-.71v-1.34c0-.35 0-.56.02-.71l.02-.15a.3.3 0 0 1 .12-.13"></path><!>',1);function rv(i,e){let t=h(e,"isOpened",3,!1),o=f(()=>t()?"graph-close-icon":"graph-open-icon");Ze(i,{get testId(){return n(o)},children:(r,a)=>{var l=A2(),d=k(ue(l));{var s=u=>{var m=k2();$(u,m)};V(d,u=>{t()&&u(s)})}$(r,l)},$$slots:{default:!0}})}function Ic(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"hidden",3,!1),r=h(e,"disabled",3,!1),a=h(e,"graphIsOpened",3,!1),d=be().ui.t,s=f(()=>a()?d("tooltip_interactive_graph_on"):d("tooltip_interactive_graph_off")),u=f(()=>o()?"hidden":"");Kt(i,{get className(){return n(u)},testId:"btn-graph",get disabled(){return r()},get ariaLabel(){return n(s)},get click(){return e.click},get ref(){return t()},set ref(m){t(m)},children:(m,p)=>{let v=f(()=>!!a());rv(m,{get isOpened(){return n(v)}})},$$slots:{default:!0}}),H()}var sv=require("@vkontakte/videoplayer-core/es2015");function Ec(i,e){B(e,!0);let[t,o]=De(),r=()=>w(u,"$playbackState$",t),a=h(e,"isMobile",3,!1),l=h(e,"isLiveActive",3,!1),d=h(e,"ariaLabel",3,""),s=be(),u=s.state.playbackState$,m=s.actions.internal.switchToActiveLive,p=s.actions.internal.togglePlay,v=f(()=>()=>{if(!l()){m();return}r()===sv.PlaybackState.PAUSED&&p()}),b=f(()=>a()?"":"btn--live btn-full-opacity"),y=f(()=>l()?"btn-live":"btn-live-offset"),_=f(()=>l()&&r()===sv.PlaybackState.PLAYING);Kt(i,{get className(){return n(b)},get testId(){return n(y)},get disabled(){return n(_)},get ariaLabel(){return d()},get click(){return n(v)},children:(x,I)=>{ic(x,{get isActive(){return l()}})},$$slots:{default:!0}}),H(),o()}var av=require("@vkontakte/videoplayer-shared/es2015");var L2=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),M2=L('<img class="icon" aria-hidden="true"/>');function ol(i,e){"use strict";let t=q(!1),o=()=>{N(t,!0)};var r=Me(),a=ue(r);{var l=s=>{var u=L2();$(s,u)},d=s=>{var u=M2();O(()=>Re(u,"src",e.icon)),ut("error",u,o),Ba(u),$(s,u)};V(a,s=>{n(t)?s(l):s(d,!1)})}$(i,r)}function lv(i,e){B(e,!0);let t=h(e,"disabled",3,!1),o=h(e,"onClick",3,av.noop),r=h(e,"ref",15),a=f(()=>o()===av.noop),l=f(()=>n(a)||t()),d=f(()=>n(a)?"btn-full-opacity":"");Do(i,{get disabled(){return n(l)},get tooltipContent(){return e.tooltipText},get disabledTooltipContent(){return e.disabledTooltipContent},width:40,get disableMouseupTooltipShow(){return e.disableMouseupTooltipShow},get tooltipVisible(){return e.tooltipVisible},get ref(){return r()},set ref(s){r(s)},children:(s,u)=>{let m=f(()=>{var p;return(p=e.testId)!=null?p:e.id});Kt(s,{get className(){return n(d)},get ariaLabel(){return e.ariaLabel},get click(){return o()},get disabled(){return n(l)},get testId(){return n(m)},children:(p,v)=>{ol(p,{get icon(){return e.icon}})},$$slots:{default:!0}})},$$slots:{default:!0}}),H()}var Kb=i=>!!i.buttonComponent;var qs={vkLogo:100,autoplayNext:200,volume:300,subtitles:400,settings:500,context:600,fullscreen:700,chromecast:800};var yp=(i,e,t,o)=>{if(i)for(let[r,a]of Object.entries(e))a.set(ir(i,t,r,o))};var xp=require("@vkontakte/videoplayer-shared/es2015"),qb=10,Qb=40,dv=.2,R2=.5,N2=65,D2=114,O2=4,Gb=({onPreviewTrackOpened:i,getTimelineRef:e,isHorizontal:t})=>{let o=f(()=>t?N2:D2),r=q(!1),a=q(0),l=q(0),d=f(()=>n(o)+qb-Qb-O2),s=f(()=>(0,xp.interpolate)(n(a),[dv,1],[0,-n(d)])),u=f(()=>(0,xp.interpolate)(n(a),[dv,1],[0,Qb])),m=f(()=>(0,xp.interpolate)(n(a),[dv,1],[0,n(o)+qb]));return{progressBarY:()=>n(s),controlsY:()=>n(u),calculatedHeight:()=>n(m),onPointerDown:_=>{var x;N(l,((x=e())==null?void 0:x.getBoundingClientRect().bottom)||0,!0),N(r,!0)},onPointerMove:_=>{if(!n(r))return;let x=Math.max(Math.min(_.clientY-n(l),0),-n(d));N(a,Math.abs(x/n(d)),!0)},onPointerUp:()=>{N(r,!1),N(a,n(a)>=R2?1:0,!0),n(a)===1&&i()},closePreviewTrack:()=>{N(a,0)}}};var B2=i=>i;function ws(i,{delay:e=0,duration:t=400,easing:o=B2}={}){let r=+getComputedStyle(i).opacity;return{delay:e,duration:t,easing:o,css:a=>`opacity: ${a*r}`}}var H2=L('<span class="root s-2c"> </span>'),F2={hash:"s-2c",code:".root.s-2c{box-shadow:0 8px 24px 0 rgba(0,0,0,.08);box-shadow:0 0 2px 0 rgba(0,0,0,.08);color:#fff;font-size:13px;font-weight:500;line-height:16px}"};function cv(i,e){Q(i,F2);var t=H2(),o=C(t,!0);S(t),O(()=>ve(o,e.time)),$(i,t)}var U2=L('<div class="tooltip-wrapper s-u"><div><!></div></div>'),z2={hash:"s-u",code:'.tooltip-wrapper.s-u{display:block;position:relative}.tooltip.s-u{bottom:100%;opacity:0;position:absolute;transform:translateX(-50%);transition:opacity .2s;visibility:hidden}.pointer.s-u:after{border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid rgba(41,41,41,.8);bottom:0;content:" ";font-size:0;left:50%;line-height:0;position:absolute;transform:translate(-50%,5px);width:0}.tooltip.active.s-u{opacity:1;visibility:visible}'};function uv(i,e){Q(i,z2);let t=h(e,"active",3,!1),o=h(e,"pointer",3,!1),r=h(e,"translateXPx",3,0),a=h(e,"translateYPx",3,0),l=h(e,"leftOffset",3,0),d=h(e,"rightOffset",3,0),s=q(void 0),u=q(void 0);function m(x){if(!n(u))return 0;let{width:I}=n(u).getBoundingClientRect(),T=I/2;return x<T?T+l():x>e.containerWidth-T?e.containerWidth-T-d():x}let p=f(()=>m(r()));var v=U2(),b=C(v);let y;var _=C(b);ri(_,()=>{var x;return(x=e.children)!=null?x:_t}),S(b),Xe(b,x=>N(u,x),()=>n(u)),S(v),Xe(v,x=>N(s,x),()=>n(s)),O(x=>{qe(v,`transform: translate(${n(p)}px, ${a()}px);`),y=oe(b,1,"tooltip s-u",null,y,x),qe(b,`opacity: ${t()?1:0}; visibility: ${t()?"visible":"hidden"}`)},[()=>({active:t(),pointer:o()})]),$(i,v)}var Yb=i=>Math.abs(i)/90%4===1;var W2=L('<div class="preview s-v"></div>'),K2=L('<div class="time s-v"> </div>'),q2=L('<div><!> <div class="episode s-v"><!></div> <!></div>'),Q2={hash:"s-v",code:".timeline-preview.s-v{border-radius:2px;bottom:18px;pointer-events:none}.timeline-preview.mobile.s-v{bottom:72px}.preview.s-v{background-color:var(--timeline-preview-bg);border:1px solid var(--white);border-radius:8px;box-shadow:0 0 2px var(--timeline-preview-shadow),0 8px 24px var(--timeline-preview-shadow)}.episode.s-v{margin-bottom:4px;margin-top:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.episode.s-v,.time.s-v{font-size:13px;font-weight:500;line-height:16px;text-align:center;text-shadow:0 8px 24px var(--timeline-preview-shadow),0 0 2px var(--timeline-preview-shadow)}.time.s-v{color:var(--white)}"};function pv(i,e){B(e,!0),Q(i,Q2);let[t,o]=De(),r=()=>w(y,"$rotateAlpha",t),a=()=>w(_,"$playerSize",t),l={MOBILE:150,DESKTOP:278},d=h(e,"time",3,""),s=h(e,"isMobile",3,!1),u=h(e,"videoEpisodes",19,()=>[]),m=h(e,"progress",3,0),p=h(e,"duration",3,0),v=h(e,"isInteractive",3,!1),b=be(),y=b.ui.rotateAlpha,_=b.ui.playerSize,x=q(0),I=q(0),T=q(""),R=q(0),A=q(0),P=q(0),E=q(0),z=f(()=>cp(m(),p(),u())),F=f(()=>od(r())),U=f(()=>Yb(r())),X=f(re),ae=f(()=>(n(U)?1:-1)*(n(x)/2-n(I)/2)),Z=f(()=>n(ae)*-1);Oe(()=>{(K=>{N(x,K.width,!0),N(I,K.height,!0)})(we())}),Oe(()=>{(K=>{N(T,K.imgSrc,!0),N(R,K.imgWidth,!0),N(A,K.imgHeight,!0),N(P,K.imgOffsetX,!0),N(E,K.imgOffsetY,!0)})(me(m()))});function re(){var He;let K=s()?l.MOBILE:l.DESKTOP,{isVertical:se}=J(),xe=30;return(He=n(z))!=null&&He.text&&(xe+=16),(se||n(F))&&(xe+=18,xe+=50),Math.min(Math.max(a().height-xe,0),K)}function J(){let K=e.previewThumbsData.frameWidth,se=e.previewThumbsData.frameHeight,xe=se>K;return{width:K,height:se,isHorizontal:!xe,isVertical:xe}}function we(){let{height:K,isHorizontal:se,isVertical:xe,width:He}=J();return se&&(K=K/He*n(X),He=n(X)),xe&&(He=He/K*n(X),K=n(X)),{width:He,height:K}}function me(K){let se;e.previewThumbsData.isUV?se=Math.floor(p()*K/e.previewThumbsData.frequency):se=Math.min(e.previewThumbsData.countTotal,Math.max(0,Math.floor(e.previewThumbsData.countTotal*K)));let xe=Math.floor(se/e.previewThumbsData.countPerImage),He=Math.floor(se%e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow),it=se%e.previewThumbsData.countPerRow,ne=Math.floor(e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow);!e.previewThumbsData.isUV&&xe===Math.floor(e.previewThumbsData.countTotal/e.previewThumbsData.countPerImage)&&(ne=Math.floor(e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow),e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage%e.previewThumbsData.countPerRow>0&&ne++);let ce=e.previewThumbsData.countPerRow;!e.previewThumbsData.isUV&&xe===Math.floor(e.previewThumbsData.countTotal/e.previewThumbsData.countPerImage)&&e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage>0&&(ce=Math.min(e.previewThumbsData.countPerRow,e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage));let Ne=n(x)*ce,Le=n(I)*ne,et=-it*n(x),Ee=-He*n(I);return{imgSrc:e.previewThumbsData.links[xe],imgWidth:Ne,imgHeight:Le,imgOffsetX:et,imgOffsetY:Ee}}var ee=q2();let _e;var Ce=C(ee);{var ge=K=>{var se=W2();O(()=>qe(se,`width: ${n(x)}px; height: ${n(I)}px; background-image: url(${n(T)}); background-size: ${n(R)}px ${n(A)}px; background-position: ${n(P)}px ${n(E)}px;
|
|
61
|
-
transform: rotate(${r()}deg) ${n(
|
|
62
|
-
`)),$(K,se)};V(Ce,K=>{n(T)&&K(ge)})}var pe=k(Ce,2),Qe=C(pe);{var G=K=>{var se=Me(),xe=ue(se);{var He=ne=>{var ce=_s();O(Ne=>ve(ce,Ne),[()=>j("tooltip_episode_unfinished")]),$(ne,ce)},it=ne=>{var ce=_s();O(()=>ve(ce,n(z).text||"")),$(ne,ce)};V(xe,ne=>{v()&&n(z).completed===!1?ne(He):ne(it,!1)})}$(K,se)};V(Qe,K=>{n(z)&&K(G)})}S(pe);var D=k(pe,2);{var Ge=K=>{var se=K2(),xe=C(se,!0);S(se),O(()=>ve(xe,d())),$(K,se)};V(D,K=>{v()||K(Ge)})}S(ee),O(K=>{_e=oe(ee,1,"timeline-preview s-v",null,_e,K),qe(ee,`width: ${n(F)?n(I):n(x)}px;`)},[()=>({mobile:s()})]),$(i,ee),H(),o()}var G2=L('<span class="time s-f"> </span>'),Y2=L("<!> <!>",1),j2={hash:"s-f",code:".time.s-f{background-color:rgba(41,41,41,.8);border-radius:3px;color:var(--white);display:inline-block;padding:6px 10px}.timeline-slider{--slider-bg:var(--timeline-slider-bg);--slider-filled-bg:var(--timeline-slider-filled-bg);--slider-handle-bg:var(--timeline-slider-handle-bg);--slider-loaded-bg:var(--timeline-slider-loaded-bg)}"};function fv(i,e){var le,$e,Ve,dt,St;B(e,!0),Q(i,j2);let[t,o]=De(),r=()=>w(Z,"$interactiveEpisodes$",t),a=()=>w(E,"$duration$",t),l=()=>w(P,"$position$",t),d=()=>w(we,"$isInteractiveExpectation$",t),s=()=>w(J,"$isInteractiveTime$",t),u=()=>w(Ce,"$previewTrackActive",t),m=()=>w(z,"$isLive$",t),p=()=>w(_e,"$disabledControls$",t),v=()=>w(U,"$isMobile",t),b=()=>w(F,"$isActiveLive$",t),y=()=>w(A,"$bufferedProgress$",t),_=h(e,"showTimeline",3,!1),x=h(e,"withEpisodes",3,!0),I=h(e,"ref",15,void 0),T=be(),R=Ot(),A=T.state.bufferedProgress$,P=T.state.positionWithScrubbing$,E=T.state.duration$,z=T.state.isLive$,F=T.state.isActiveLive$,U=T.ui.isMobile,X=R.features.episodes&&x()?T.actions.internal.getVideoEpisodes():void 0,ae=T.actions.internal.getPreviewThumbsData(),Z=T.state.interactiveEpisodes$,re=T.state.isInteractive,J=T.state.isInteractiveTime$,we=T.state.isInteractiveExpectation$,me=T.actions.internal.correctSeekTimeToInteractive,ee=(le=T.callbacks)==null?void 0:le.onDisabledTimelineClick,_e=T.ui.controls.disabledControls$,Ce=T.ui.previewTrackActive,ge=(Ve=($e=T.callbacks)==null?void 0:$e.uiInfo)==null?void 0:Ve.onTimelineMouseEnter,pe=(St=(dt=T.callbacks)==null?void 0:dt.uiInfo)==null?void 0:St.onTimelineMouseLeave,Qe=T.ui.t,G=R.features.interactiveResponsiveUi,D=f(()=>re?r():X),Ge=f(()=>en(a())),K=f(()=>en(l())),se=f(()=>l()/a()),xe=f(()=>d()||s()),He=q(!1),it=q(""),ne=q(0),ce=q(0),Ne=q(0),Le=f(()=>({containerWidth:n(ce),translateXPx:n(ne),translateYPx:re&&ae?-36:-16,active:n(He)&&_()&&!n(xe)&&!G&&!u(),pointer:!R.features.timelinePreview||!ae||m()})),et=Qe("aria_timeline"),Ee=f(()=>Qe("aria_timeline_value",{position:n(K),duration:n(Ge)}));function Te(fe){return!me||!re?fe:me(fe*a())/a()}function Fe(fe,Be){var We;(We=e.onSliderPointerDown)==null||We.call(e,Be),T.actions.internal.startScrubbing(Te(fe))}function kt(fe){s()||T.actions.internal.progressScrubbing(Te(fe))}function Tt(fe){var Be;T.actions.internal.completeScrubbing(Te(fe)),N(He,!1),(Be=e.onSliderPointerUp)==null||Be.call(e)}function Vt(fe,Be,We){var Ct;(Ct=e.onSliderPointerEnter)==null||Ct.call(e,fe),ti(fe,Be,We),N(He,!0)}function pt(fe,Be,We,Ct){var Xt;(Xt=e.onSliderMove)==null||Xt.call(e,Ct,fe),ti(fe,Be,We),N(He,!0)}function At(){var fe;N(He,!1),(fe=e.onSliderLeave)==null||fe.call(e)}function ti(fe,Be,We){N(Ne,Te(fe),!0),N(ne,Be,!0),We&&N(ce,We,!0),N(it,Lt(fe),!0)}function Lt(fe){let Be=en((m()?1-fe:fe)*a());return m()?`-${Be}`:Be}let Ft=f(()=>p().has("TIMELINE"));var qt=Y2(),Y=ue(qt);uv(Y,rs(()=>n(Le),{get leftOffset(){return e.tooltipLeftOffset},get rightOffset(){return e.tooltipRightOffset},children:(fe,Be)=>{var We=Me(),Ct=ue(We);{var Xt=ai=>{pv(ai,{get time(){return n(it)},get isMobile(){return v()},get videoEpisodes(){return n(D)},get previewThumbsData(){return ae},get progress(){return n(Ne)},get duration(){return a()},get isInteractive(){return re}})},It=ai=>{var fi=G2(),Bi=C(fi,!0);S(fi),O(()=>ve(Bi,n(it))),$(ai,fi)};V(Ct,ai=>{R.features.timelinePreview&&ae&&!m()?ai(Xt):ai(It,!1)})}$(fe,We)},$$slots:{default:!0}}));var Pe=k(Y,2);el(Pe,{className:"timeline-slider",get isActiveLive(){return b()},get isMobile(){return v()},get ariaLabel(){return et},ariaValueMin:0,get ariaValueMax(){return a()},get ariaValueNow(){return l()},get ariaValueText(){return n(Ee)},get loadedProgress(){return y()},get filledProgress(){return n(se)},get handleProgress(){return n(se)},get videoEpisodes(){return n(D)},onPointerDown:Fe,onHandleMove:kt,onPointerMove:pt,onPointerUp:Tt,onPointerEnter:Vt,onPointerLeave:At,get onMouseEnter(){return ge},get onMouseLeave(){return pe},get onDisabledClick(){return ee},get isInteractive(){return re},get disabled(){return n(Ft)},get handleAlwaysVisible(){return u()},get hideHandel(){return s()},testId:"progress_bar",onContextMenu:Tt,get ref(){return I()},set ref(fe){I(fe)}}),$(i,qt),H(),o()}var X2={hash:"s-g",code:".timeline-ads-slider{--slider-bg:var(--timeline-slider-bg);--slider-filled-bg:var(--timeline-slider-filled-bg);--slider-handle-bg:var(--timeline-slider-handle-bg);--slider-loaded-bg:var(--timeline-slider-loaded-bg)}"};function Pc(i,e){B(e,!0),Q(i,X2);let[t,o]=De(),r=()=>w(s,"$isMobile",t),a=h(e,"position",3,0),l=h(e,"duration",3,0),d=be(),s=d.ui.isMobile,u=d.ui.t,m=f(()=>en(l())),p=f(()=>en(a())),v=f(()=>a()/l()),b=f(()=>u("aria_timeline_value",{position:n(p),duration:n(m)})),y=f(()=>Math.round(n(v)*100));el(i,{className:"timeline-ads-slider",ariaValueMin:0,get ariaValueMax(){return l()},get ariaValueNow(){return n(y)},get ariaValueText(){return n(b)},get filledProgress(){return n(v)},hideHandel:!0,get squareBorders(){return r()}}),H(),o()}var Z2=L("<div><!></div>"),J2=L("<div></div>"),ew={hash:"s-e",code:".timeline.s-e{align-items:center;bottom:0;box-sizing:border-box;display:flex;min-width:86px;pointer-events:all;position:relative;width:100%}.timeline.mobile.s-e{height:16px;margin-top:6px;padding:6px 12px 7px}.withoutPadding.s-e{padding:0}.timeline-stub.s-e{min-width:20px;width:100%}.timeline-stub.mobile.s-e{height:8px}"};function nl(i,e){B(e,!0),Q(i,ew);let[t,o]=De(),r=()=>w(x,"$isLive$",t),a=()=>w(R,"$isMobile",t),l=()=>w(A,"$disabled",t),d=()=>w(T,"$adPosition",t),s=()=>w(I,"$adDuration",t),u=h(e,"isAds",3,!1),m=h(e,"isHidden",3,!1),p=h(e,"timelineNotAvailable",3,!1),v=h(e,"needPadding",3,!0),b=h(e,"ref",15,void 0),y=be(),_=Ot(),x=y.state.isLive$,I=y.ads.duration,T=y.ads.position,R=y.ui.isMobile,A=de(!1),P=f(()=>!p()&&(!r()||r()&&e.canRewindLive&&e.isRewindableLive||u()));var E=Me(),z=ue(E);{var F=X=>{var ae=Z2();let Z;var re=C(ae);{var J=me=>{Pc(me,{get position(){return d()},get duration(){return s()}})},we=me=>{fv(me,{get tooltipLeftOffset(){return e.tooltipLeftOffset},get tooltipRightOffset(){return e.tooltipRightOffset},get showTimeline(){return n(P)},get withEpisodes(){return e.withEpisodes},get onSliderMove(){return e.onSliderMove},get onSliderPointerDown(){return e.onSliderPointerDown},get onSliderPointerUp(){return e.onSliderPointerUp},get onSliderLeave(){return e.onSliderLeave},get onSliderPointerEnter(){return e.onSliderPointerEnter},get ref(){return b()},set ref(ee){b(ee)}})};V(re,me=>{u()?me(J):me(we,!1)})}S(ae),Os(ae,()=>Gl(m()&&_.features.usePerformanceFix,A,_.disableInvisibleComponentsTimeout)),O(me=>Z=oe(ae,1,"timeline s-e",null,Z,me),[()=>({withoutPadding:!v(),mobile:a(),"out-of-flow":l()})]),$(X,ae)},U=X=>{var ae=J2();let Z;O(re=>Z=oe(ae,1,"timeline-stub s-e",null,Z,re),[()=>({mobile:a()})]),$(X,ae)};V(z,X=>{n(P)?X(F):X(U,!1)})}$(i,E),H(),o()}var jb=require("@vkontakte/videoplayer-shared/es2015");var tw=(i,e,t,o,r,a,l)=>{N(e,!0),N(t,i.clientX,!0),N(o,n(r),!0),a(l())},iw=L("<div></div>"),ow=L('<div><div class="track s-2b"></div></div>'),nw={hash:"s-2b",code:'.root.s-2b{display:flex;height:var(--preview-track-frame-height-horizontal);overflow:hidden;position:relative;width:100%}.root.is-vertical-video.s-2b,.root.vertically-rotated.s-2b{height:var(--preview-track-frame-height-vertical)}.root.s-2b:after{background-color:#fff;box-shadow:0 2px 2px 0 rgba(0,0,0,.12);box-shadow:0 0 2px 0 rgba(0,0,0,.06);content:"";height:100%;margin:0 auto;pointer-events:none;width:3px;z-index:1}.track.s-2b{bottom:0;display:flex;left:0;padding:0 50%;top:0}.frame.s-2b,.track.s-2b{position:absolute}.frame.s-2b{background-position-x:calc(var(--column-index)*-1*var(--frame-width));background-position-y:calc(var(--frame-height)*-1*var(--row-index));background-size:calc(var(--frame-width)*var(--column-numbers)) calc(var(--frame-height)*var(--row-numbers));flex-shrink:0;height:var(--frame-height);pointer-events:none;transform-origin:center;width:var(--frame-width)}.vertically-rotated.s-2b .frame:where(.s-2b){transform-origin:0 0}.rotate-1.s-2b{transform:rotate(-90deg) translateX(-100%)}.rotate-2.s-2b{transform:rotate(-180deg)}.rotate-3.s-2b{transform:rotate(-270deg) translateY(-100%)}'};function vv(i,e){B(e,!0),Q(i,nw);let[t,o]=De(),r=()=>w(R,"$rotateAlpha",t),a=()=>w(_,"$position$",t),l=()=>w(y,"$duration$",t),d=be(),{countPerImage:s=0,countPerRow:u=0,countTotal:m=0,links:p=[],frameHeight:v=0,frameWidth:b=0}=d.actions.internal.getPreviewThumbsData()||{},{duration$:y,positionWithScrubbing$:_}=d.state,{startScrubbing:x,progressScrubbing:I,completeScrubbing:T}=d.actions.internal,R=d.ui.rotateAlpha,A=q(void 0),P=q(!1),E=q(0),z=q(0),F=q(0),U=q(0),X=f(()=>v<=b),ae=f(()=>od(r())),Z=f(()=>n(X)?!n(ae):n(ae)),re=114,J=65,we=3,me=f(()=>n(Z)?re:J),ee=f(()=>n(X)?re:J),_e=f(()=>n(X)?"var(--preview-track-frame-height-horizontal)":"var(--preview-track-frame-height-vertical)"),Ce=f(()=>m*n(me)),ge=q(0);Oe(()=>{N(U,Math.ceil(-n(F)/n(me))-1),N(F,-n(Ce)*a()/l())});let pe=()=>{T(Qe(),!0)},Qe=()=>l()*-n(F)/n(Ce)/l(),G=!1,D=Ee=>{if(!n(P))return!1;let Te=Ee.clientX-n(E);N(F,n(z)+Te),N(F,Math.max(Math.min(n(F),0),-n(Ce)),!0),Math.abs(Te)>1&&(G=!0),I(Qe())},Ge=Ee=>{n(P)&&(N(P,!1),!G&&Ee&&N(F,-(Ee.offsetX-n(ge)/2)),G=!1,pe())},K=()=>{n(P)&&Ge()},se=f(()=>s/u),xe=(Ee,Te)=>{if(Ee!==p.length-1)return u;let Fe=0,kt=Te*u;for(let Tt=1;Tt<=u;Tt++)Ee*s+Fe+kt<m&&Fe++;return Fe},He=f(()=>Math.floor(n(U)/s)),it=f(()=>(0,jb.getRangeAroundIndex)(3,n(He),p.length-1)),ne=(Ee,Te,Fe)=>{let kt=s*n(me);return Ee*kt+Te*n(me)*u+n(ge)/2-we/2+Fe*n(me)},ce=f(()=>[`--row-numbers: ${n(se)}`,`--column-numbers: ${u}`,`--frame-width: ${n(ee)}px`,`--frame-height: ${n(_e)}`].join(";"));var Ne=ow();let Le;var et=C(Ne);et.__pointerdown=[tw,P,E,z,F,x,Qe],et.__pointermove=D,et.__pointerup=Ge,yi(et,20,()=>n(it),Ee=>Ee,(Ee,Te)=>{var Fe=Me(),kt=ue(Fe);yi(kt,16,()=>Array.from({length:n(se)},(Tt,Vt)=>Vt),Tt=>Tt,(Tt,Vt)=>{var pt=Me(),At=ue(pt);yi(At,16,()=>Array.from({length:xe(Te,Vt)},(ti,Lt)=>Lt),ti=>ti,(ti,Lt)=>{var Ft=iw();O((qt,Y)=>{qe(Ft,qt),oe(Ft,1,Y,"s-2b")},[()=>`--row-index: ${Vt}; --column-index: ${Lt}; left: ${ne(Te,Vt,Lt)}px; background-image: url(${p[Te]});`,()=>`frame rotate-${Math.abs(r())/90%4}`]),$(ti,Ft)}),$(Tt,pt)}),$(Ee,Fe)}),S(et),S(Ne),Xe(Ne,Ee=>N(A,Ee),()=>n(A)),O(Ee=>{Le=oe(Ne,1,"root s-2b",null,Le,Ee),qe(Ne,n(ce)),qe(et,`transform: translateX(${n(F)}px); width: ${n(Ce)}px;`)},[()=>({"is-vertical-video":!n(X),"vertically-rotated":n(ae)})]),ut("mouseleave",et,K),Rn(Ne,"clientWidth",Ee=>N(ge,Ee)),$(i,Ne),H(),o()}Ye(["pointerdown","pointermove","pointerup"]);var rw=L('<div class="notification s-2d"><span class="description s-2d"> </span></div>'),sw={hash:"s-2d",code:".notification.s-2d{background:var(--notification-bg);border-radius:var(--notification-radius);padding:9px 14px 10px 12px}.description.s-2d{font-size:14px;line-height:18px}"};function gv(i,e){B(e,!1),Q(i,sw);let t=340,{ui:{t:o}}=be();$o();var r=rw(),a=C(r),l=C(a,!0);S(a),S(r),O(d=>ve(l,d),[()=>o("preview_track_close_tooltip")],kn),ns(3,r,()=>ws,()=>({duration:t})),$(i,r),H()}var Xb=require("@vkontakte/videoplayer-shared/es2015"),aw=L('<div class="preview-track-close tooltip s-29"><!></div>'),lw=L('<div class="preview-track-control s-29"><!> <div class="preview-track-close s-29"><!></div> <!></div>'),dw=L('<div class="wrapper-preview-track s-29"><!></div>'),cw=L('<div class="enriched-timeline s-29"><!> <!> <!></div>'),uw={hash:"s-29",code:".enriched-timeline.s-29{padding:var(--timeline-padding-vertical-top) var(--timeline-padding-horizontal) var(--timeline-padding-vertical-bottom);pointer-events:auto;position:relative}.preview-track-control.s-29{align-items:center;display:flex;justify-content:center;left:0;padding:0 calc(var(--timeline-padding-horizontal));pointer-events:none;position:absolute;right:0;top:calc((var(--timeline-height) + var(--preview-track-controls-top))*-1)}.preview-track-close.s-29{pointer-events:auto;position:absolute;right:calc(var(--timeline-padding-horizontal))}.preview-track-close.tooltip.s-29{bottom:32px;opacity:0;transition:opacity .2s}.preview-track-close.s-29:hover+.tooltip:where(.s-29){opacity:1}.wrapper-preview-track.s-29{box-sizing:border-box;left:0;overflow:hidden;padding:0 calc(var(--timeline-padding-horizontal));position:absolute;right:0;z-index:-1}"};function hv(i,e){B(e,!0),Q(i,uw);let[t,o]=De(),r=()=>w(_,"$playerSize",t),a=()=>w(y,"$duration$",t),l=()=>w(x,"$previewTrackActive",t),d=()=>w(v,"$position$",t),s=()=>w(b,"$isRewindableLive$",t),u=h(e,"timelineRef",15,void 0),m=be(),p=200,{positionWithScrubbing$:v,isRewindableLive$:b,duration$:y}=m.state,{playerSize:_,previewTrackActive:x}=m.ui,{countPerImage:I=0,links:T=[],frequency:R=0}=m.actions.internal.getPreviewThumbsData()||{},A=f(()=>r().width>100),P=q(!eb()),E=()=>{n(P)&&(J_(),N(P,!1))},z=me=>{let ee=Math.floor(a()*me/R),_e=Math.floor(ee/I),Ce=(0,Xb.getRangeAroundIndex)(3,_e,T.length-1);for(let ge of Ce){let pe=new Image;pe.src=T[ge]}},F=(me,ee)=>{z(ee),!l()&&e.onTimelineMove(me)};var U=cw(),X=C(U);{var ae=me=>{var ee=lw(),_e=C(ee);let Ce=f(()=>en(d()));cv(_e,{get time(){return n(Ce)}});var ge=k(_e,2),pe=C(ge);Hs(pe,{onClick:()=>m.actions.internal.closePreviewTrack()}),S(ge);var Qe=k(ge,2);{var G=D=>{var Ge=aw(),K=C(Ge);gv(K,{}),S(Ge),$(D,Ge)};V(Qe,D=>{n(P)&&D(G)})}S(ee),ut("mouseleave",ge,E),ns(3,ee,()=>ws,()=>({duration:p})),$(me,ee)};V(X,me=>{l()&&me(ae)})}var Z=k(X,2);let re=f(()=>!n(A));nl(Z,{get isHidden(){return n(re)},get isAds(){return e.isAds},get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return s()},onSliderMove:F,get onSliderPointerDown(){return e.onTimelinePointerDown},get onSliderPointerUp(){return e.onTimelinePointerUp},get onSliderLeave(){return e.onTimelinePointerLeave},onSliderPointerEnter:z,get ref(){return u()},set ref(me){u(me)}});var J=k(Z,2);{var we=me=>{var ee=dw(),_e=C(ee);vv(_e,{}),S(ee),O(()=>qe(ee,`height: ${e.animatedPreviewTrackHeight}px;`)),$(me,ee)};V(J,me=>{e.previewTrackAvailable&&me(we)})}S(U),O(()=>qe(U,`transform: translateY(${e.animatedOffsetY}px);`)),$(i,U),H(),o()}var fw=L('<div><!> <div class="controls s-1b" data-testid="player_controls"><div class="controls-left s-1b"><!> <!> <!></div> <div class="controls-right s-1b"></div></div></div> <!>',1),mw={hash:"s-1b",code:'.wrapper-bottom.s-1b{bottom:0;box-sizing:border-box;display:flex;flex-direction:column;justify-content:flex-end;left:0;pointer-events:none;position:absolute;transition:transform var(--controls-transition-duration) var(--controls-transition-fn);width:100%;will-change:transform;z-index:var(--controls-container-z-index)}.wrapper-bottom.s-1b:before{background:var(--controls-gradient);content:"";height:var(--controls-gradient-height);position:absolute;width:100%}.wrapper-bottom.s-1b>:where(.s-1b){pointer-events:auto}.controls.s-1b{align-items:center;box-sizing:border-box;display:flex;font-size:13px;height:var(--controls-height);justify-content:space-between;padding:0 var(--controls-desktop-padding-horizontal) 4px;white-space:nowrap;width:100%}.controls-left.s-1b,.controls-right.s-1b{align-content:center;display:flex}.controls-left.s-1b{flex-grow:1;min-width:0;overflow:hidden}.controls-left.s-1b >:not(:first-child),.controls-right.s-1b >*{margin-left:var(--controls-desktop-item-margin-left)}.controls-hidden.s-1b{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-1b{transition:none}'};function bv(i,e){var bl,Ta;B(e,!0),Q(i,mw);let[t,o]=De(),r=()=>w(tn,"$disabledControls$",t),a=()=>w(st,"$adPlaybackState",t),l=()=>w(It,"$playbackState$",t),d=()=>w(Ei,"$currentSubtitle$",t),s=()=>w(Bi,"$isEnded$",t),u=()=>w(vn,"$currentGridType$",t),m=()=>w(Bt,"$isLive$",t),p=()=>w(lt,"$chromecastState$",t),v=()=>w(ot,"$isPictureInPictureActive",t),b=()=>w(Jt,"$pictureInPictureType$",t),y=()=>w(nt,"$availableSubtitlesList$",t),_=()=>w(Ut,"$contextMenuOpenedByKeyboard$",t),x=()=>w(bt,"$showContextMenuBtn$",t),I=()=>w(vi,"$isRewindableLive$",t),T=()=>w(_o,"$isActiveLive$",t),R=()=>w(Fr,"$graphIsOpened$",t),A=()=>w(Bo,"$contextMenuVisible$",t),P=()=>w(Fi,"$isFullscreen",t),E=()=>w(Vi,"$autoplayNextEnabled",t),z=()=>w(n(Sn),"$prevButton",t),F=()=>w(n(Co),"$replayButton",t),U=()=>w(n(sn),"$playButton",t),X=()=>w(n(co),"$nextButton",t),ae=()=>w(n(To),"$playPrevChapterButton",t),Z=()=>w(n(Pi),"$seekToInteractiveButton",t),re=()=>w(n(Kr),"$interactiveGraphButton",t),J=()=>w(n(qn),"$liveButton",t),we=()=>w(n(Cs),"$time",t),me=()=>w(n(Ki),"$episodes",t),ee=()=>w(n(Ts),"$vkLogo",t),_e=()=>w(n(us),"$volume",t),Ce=()=>w(n(Ir),"$subtitles",t),ge=()=>w(n(Uo),"$settings",t),pe=()=>w(n(qr),"$context",t),Qe=()=>w(n(an),"$fullscreen",t),G=()=>w(n(ln),"$chromecast",t),D=()=>w(gn,"$additionalDesktopControlPanelRightButtons$",t),Ge=()=>w(Mi,"$playerSize",t),K=()=>w(Ho,"$isInteractiveTime$",t),se=()=>w(di,"$previewTrackActive",t),xe=()=>w(Hi,"$settingsMenuVisible",t),He=()=>w(qi,"$settingButtonRef$",t),it=()=>w(W,"$startedByKeyboard$",t),ne=()=>w(ai,"$isAudioAvailable$",t),ce=()=>w(qt,"$fakeIsPlaying$",t),Ne=()=>w(Ss,"$seekToInteractiveDisabledTooltip$",t),Le=()=>w(In,"$isPreviewTrackHorizontallyAligned$",t),et=()=>w(Si,"$previewTrackAvailable",t),Ee=()=>w(Ao,"$previewTrackDragInProgress",t),Te=()=>w(xt,"$adPosition",t),Fe=()=>w(Xt,"$position$",t),kt=()=>w(ii,"$adDuration",t),Tt=()=>w(Ct,"$duration$",t),Vt=h(e,"playerControlsWrapperRef",15,void 0),pt=h(e,"playerControlsRef",15,void 0),At=h(e,"isAds",3,!1),ti=h(e,"logoTargetUrl",3,""),Lt=h(e,"isOneVideoPlaylist",3,!1),Ft=h(e,"customFullscreenSupported",3,!0),{fakeIsPlaying$:qt}=yo(),Y=be(),Pe=yo(),le=Ot(),$e=Y.actions.internal.toggleMuted,Ve=Y.actions.internal.togglePlay,dt=Y.actions.internal.pause,St=Y.actions.internal.toggleSubtitle,fe=Y.actions.internal.checkFullscreenSupport,Be=(bl=Y.callbacks)==null?void 0:bl.onAudioDoesNotExistHint,We=(Ta=Y.callbacks)==null?void 0:Ta.onAudioDisabledHint,Ct=Y.state.duration$,Xt=Y.state.positionWithScrubbing$,It=Y.state.playbackState$,ai=Y.state.isAudioAvailable$,fi=Y.state.isAudioDisabled,Bi=Y.state.isEnded$,Bt=Y.state.isLive$,_o=Y.state.isActiveLive$,vi=Y.state.isRewindableLive$,{isActive$:ot,type$:Jt}=Pe.pictureInPicture$,Hi=Y.ui.settingsMenu.visible$,xi=Y.ui.settingsMenu.openedByBtnKeyboard$,oi=Y.ui.controls,Ti=Y.actions.internal.getVideoEpisodes(),lt=Y.state.chromecastState$,nt=Y.state.availableSubtitlesList$,Ei=Y.state.currentSubtitle$,tn=oi.disabledControls$,Bo=Y.ui.contextMenu.visible$,bt=Y.ui.contextMenu.showContextMenuBtn$,Ut=Y.ui.contextMenu.openedByBtnKeyboard$,W=Y.ui.startedByKeyboard$,Rt=Y.ui.controlBlocks,li=Y.ui.previewTrackNotificationVisible,gt=Y.ui.t,ii=Y.ads.duration,xt=Y.ads.position,st=Y.ads.playbackState,Fi=Y.ui.isFullscreen,Mi=Y.ui.playerSize,vn=Y.ui.currentGridType$,gn=Y.ui.additionalDesktopControlPanelRightButtons$,Vi=Y.ui.autoplayNextEnabled$,Ui=Y.actions.internal.getVideoElement,Hn=Y.actions.internal.replayInteractive,bo=Y.actions.internal.prevVideoClick,lo=Y.actions.internal.nextVideoClick,Ai=Y.state.isInteractive,Ho=Y.state.isInteractiveTime$,Fo=Y.state.showInteractiveGraph,hn=Y.state.showSeekToInteractive,Or=Y.state.showPlayPrevChapter,Br=Y.state.showInteractiveTimeIndicator,Hr=Y.state.playPrevChapterDisabledTooltip,Ss=Pe.seekToInteractiveDisabledTooltip$,Fr=Pe.graphIsOpened$,nr=le.features.interactiveResponsiveUi,Ur=f(()=>r().has("EPISODE_BUTTON")),_n=f(()=>r().has("GRAPH_BUTTON")),bn=f(()=>r().has("SEEK_TO_INTERACTIVE_BUTTON")),_r=f(()=>r().has("PLAY_BUTTON")),br=f(()=>r().has("REPLAY_BUTTON")),on=f(()=>r().has("PLAY_PREV_CHAPTER_BUTTON")),$r=()=>Y.actions.internal.toggleChromecast(),yr=f(()=>At()?a()==="playing":l()===rl.PlaybackState.PLAYING),rr=f(()=>d().value!=="off"),Fn=f(()=>s()&&!At()||Ai),cs=f(()=>nr?n(Fn)&&ro(u(),"m"):n(Fn)),xo=f(()=>!s()||Ai||At()),xr=f(()=>ro(u(),"m")),zi=f(()=>e.showNextPrevButtons&&ro(u(),"m")&&!At()&&e.nextButtonActive),wr=f(()=>e.showNextPrevButtons&&ro(u(),"m")&&!At()&&e.prevButtonActive),Un=f(()=>!At()&&!!m()),vt=f(()=>p()!==rl.ChromecastState.NOT_AVAILABLE&&!(v()&&b()===1)&&ro(u(),"m")&&!Ai),ni=f(()=>e.showAutoplayNext&&!Lt()&&ro(u(),"s")),Sr=f(()=>y().length>0&&ro(u(),"m")),zr=f(()=>_()||x()),Wr=f(()=>ro(u(),"s")&&!At()),zn=f(()=>!e.logoHidden&&!At()),sr=f(()=>le.features.fullscreen&&fe()&&(e.logoHidden||ro(u(),nr?"xs":"s"))&&!(v()&&b()===1)&&(Ai?Ft():!0)),wo=f(()=>(!m()||At())&&!(le.features.interactiveHideTime&&Ai)),Wn=f(()=>Fo&&ro(u(),"m")),ar=f(()=>nr?hn&&ro(u(),"s"):hn),Kn=f(()=>nr?Or&&ro(u(),"s"):Or),$n=f(()=>!At()&&!m()&&!!(Ti!=null&&Ti.length)&&n(xr)&&!n(Ur)),yn=f(()=>!I()||!!T()),xn=f(()=>R()?gt("tooltip_interactive_graph_on"):gt("tooltip_interactive_graph_off")),nn=f(()=>A()?gt("tooltip_context_menu_close"):gt("tooltip_context_menu_open")),Wi=(mt,rt)=>mt?rt&&rt===rl.PlaybackState.PAUSED?gt("tooltip_play"):"":gt("tooltip_live"),eo=f(()=>Wi(n(yn),l())),rn=f(()=>le.logoType==="vk_video"?gt("tooltip_vk_video_logo"):gt("tooltip_vk_logo")),lr=f(()=>n(rr)?gt("tooltip_subtitles_on"):gt("tooltip_subtitles_off")),Cr=f(()=>P()?gt("tooltip_fullscreen_on"):gt("tooltip_fullscreen_off")),wn=f(()=>p()===rl.ChromecastState.CONNECTED?gt("tooltip_chromecast_on"):gt("tooltip_chromecast_off")),Tr=f(()=>E()?gt("tooltip_autoplay_on"):gt("tooltip_autoplay_off")),ft=q(0),Nt=ui({}),So=ui({}),Sn=f(()=>oi.prevButton),Co=f(()=>oi.replayButton),sn=f(()=>oi.playButton),co=f(()=>oi.nextButton),To=f(()=>oi.playPrevChapterButton),Pi=f(()=>oi.seekToInteractiveButton),Kr=f(()=>oi.interactiveGraphButton),qn=f(()=>oi.liveButton),Cs=f(()=>oi.time),Ki=f(()=>oi.episodes),Ts=f(()=>oi.vkLogo),us=f(()=>oi.volume),Ir=f(()=>oi.subtitles),Uo=f(()=>oi.settings),qr=f(()=>oi.context),an=f(()=>oi.fullscreen),ln=f(()=>oi.chromecast),Ue=f(()=>({prevButton:z()?z().right-z().left:0,replayButton:F()?F().right-F().left:0,playButton:U()?U().right-U().left:0,nextButton:X()?X().right-X().left:0,playPrevChapterButton:ae()?ae().right-ae().left:0,seekToInteractiveButton:Z()?Z().right-Z().left:0,interactiveGraphButton:re()?re().right-re().left:0,liveButton:J()?J().right-J().left:0,time:we()?we().right-we().left:0,episodes:me()?me().right-me().left:0,vkLogo:ee()?ee().right-ee().left:0,volume:_e()?_e().right-_e().left:0,subtitles:Ce()?Ce().right-Ce().left:0,settings:ge()?ge().right-ge().left:0,context:pe()?pe().right-pe().left:0,fullscreen:Qe()?Qe().right-Qe().left:0,chromecast:G()?G().right-G().left:0,additionalButtons:D().length?D().reduce(mt=>[...mt,40],[]):[]})),Et=q(0);Oe(()=>{(!n(Et)||n(Et)<n(Ue).time)&&Pt(()=>N(Et,n(Ue).time,!0))});let mi=q(!1);Oe(()=>{let mt=0;n($n)&&(ro(u(),"xl")?mt=n(Ue).time:mt=60);let rt=n(Ue).prevButton+n(Ue).playButton+n(Ue).nextButton+n(Ue).seekToInteractiveButton+n(Ue).interactiveGraphButton+n(Ue).liveButton+n(Et)+mt;N(mi,n(wo)&&n(ft)>=rt,!0)});let zo=f(()=>n(mi)&&ro(u(),"m")),Io=(0,_v.debounceFn)(rd,260),Wo=(0,_v.debounceFn)(yp,260);Oe(()=>{Ge(),K(),se(),Io(Ui(),oi,Nt,e.showControls),Wo(Ui(),Rt,So,e.showControls)}),Oe(()=>{So.bottom=Vt()});let qi=de();Oe(()=>{xe(),He()&&Pt(()=>jl(He(),xe(),xi))});let Eo;Oe(()=>{it(),Pt(()=>bp(W,it(),Eo))});function Qn(){ma({isAudioDisabled:fi,isAudioAvailable:ne(),isAds:At(),audioIsNotExistHintCallback:Be,audioDisabledHintCallback:We})&&$e()}let Er=Ai?Hn:Ve,Po=f(()=>ce()!==null),uo=f(()=>n(Po)?ce():n(yr)),Cn=f(()=>n(uo)?gt("tooltip_pause"):gt("tooltip_play")),Ko=gt("tooltip_episodes"),Gn=f(()=>{var mt,rt,to,Mo;return n(wr)?{id:"prevButton",type:"desktop-control-panel-left",weight:Ws.prevButton,buttonComponent:il,buttonComponentProps:{disabled:!e.prevButtonActive,type:"prev",click:bo.bind(null,!0)},tooltipEnabled:!((rt=(mt=Y.callbacks)==null?void 0:mt.uiInfo)!=null&&rt.onPrevButtonMouseEnter)&&!((Mo=(to=Y.callbacks)==null?void 0:to.uiInfo)!=null&&Mo.onPrevButtonMouseLeave),mouseEnter:()=>{var io,bi,Gi;(Gi=(bi=(io=Y.callbacks)==null?void 0:io.uiInfo)==null?void 0:bi.onPrevButtonMouseEnter)==null||Gi.call(bi,ir(Ui(),Nt,"prevButton",e.showControls))},mouseLeave:()=>{var io,bi,Gi;(Gi=(bi=(io=Y.callbacks)==null?void 0:io.uiInfo)==null?void 0:bi.onPrevButtonMouseLeave)==null||Gi.call(bi,ir(Ui(),Nt,"prevButton",e.showControls))},tooltipText:gt("tooltip_previous"),disabled:!e.prevButtonActive}:void 0}),Qr=f(()=>n(cs)?{id:"replayButton",type:"desktop-control-panel-left",weight:Ws.replayButton,buttonComponent:sd,buttonComponentProps:{disabled:n(br),click:Er},tooltipText:gt("tooltip_restart"),disabled:n(br)}:void 0),Gr=f(()=>n(xo)?{id:"playButton",type:"desktop-control-panel-left",weight:Ws.playButton,buttonComponent:ad,buttonComponentProps:{disabled:n(_r),isPlaying:n(yr),click:Ve},tooltipText:n(Cn),disabled:n(_r)}:void 0),Yn=f(()=>{var mt,rt,to,Mo;return n(zi)?{id:"nextButton",type:"desktop-control-panel-left",weight:Ws.nextButton,buttonComponent:il,buttonComponentProps:{disabled:!e.nextButtonActive,type:"next",click:lo.bind(null,!0)},tooltipEnabled:!((rt=(mt=Y.callbacks)==null?void 0:mt.uiInfo)!=null&&rt.onNextButtonMouseEnter)&&!((Mo=(to=Y.callbacks)==null?void 0:to.uiInfo)!=null&&Mo.onNextButtonMouseLeave),mouseEnter:()=>{var io,bi,Gi;(Gi=(bi=(io=Y.callbacks)==null?void 0:io.uiInfo)==null?void 0:bi.onNextButtonMouseEnter)==null||Gi.call(bi,ir(Ui(),Nt,"nextButton",e.showControls))},mouseLeave:()=>{var io,bi,Gi;(Gi=(bi=(io=Y.callbacks)==null?void 0:io.uiInfo)==null?void 0:bi.onNextButtonMouseLeave)==null||Gi.call(bi,ir(Ui(),Nt,"nextButton",e.showControls))},tooltipText:gt("tooltip_next"),disabled:!e.nextButtonActive}:void 0}),Je=f(()=>Ai&&n(Kn)?{id:"playPrevChapterButton",type:"desktop-control-panel-left",weight:Ws.playPrevChapterButton,buttonComponent:Sc,buttonComponentProps:{disabled:n(on),click:e.playPrevChapter},tooltipText:gt("tooltip_interactive_go_back"),disabledTooltipContent:gt(Hr),disabled:n(on)}:void 0),ei=f(()=>Ai&&n(ar)?{id:"seekToInteractiveButton",type:"desktop-control-panel-left",weight:Ws.seekToInteractiveButton,buttonComponent:Tc,buttonComponentProps:{disabled:n(bn),click:e.seekToInteractive},tooltipText:gt("tooltip_interactive_seek"),disabled:n(bn),disabledTooltipContent:gt(Ne())}:void 0),wi=f(()=>Ai&&n(Wn)?{id:"interactiveGraphButton",type:"desktop-control-panel-left",weight:Ws.interactiveGraphButton,buttonComponent:Ic,buttonComponentProps:{disabled:n(_n),click:Fr.toggle,graphIsOpened:R()},tooltipText:n(xn)}:void 0),ko=f(()=>n(Un)?{id:"liveButton",type:"desktop-control-panel-left",weight:Ws.liveButton,buttonComponent:Ec,buttonComponentProps:{isLiveActive:n(yn),ariaLabel:n(eo)},tooltipText:n(eo),disabled:n(yn)&&l()===rl.PlaybackState.PLAYING}:void 0),Tn=f(()=>[n(Gn),n(Qr),n(Gr),n(Yn),n(Je),n(ei),n(wi),n(ko)].filter(mt=>!!mt).sort(Ya)),jn=f(()=>n(zn)?{id:"vkLogo",type:"desktop-control-panel-right",weight:qs.vkLogo,buttonComponent:vc,buttonComponentProps:{targetUrl:ti(),logoClickable:e.logoClickable,click:dt},tooltipText:n(rn),disabledTooltipContent:"",disabled:!e.logoClickable}:void 0),qo=f(()=>n(ni)?{id:"autoplayNext",type:"desktop-control-panel-right",weight:qs.autoplayNext,buttonComponent:Cc,tooltipText:n(Tr)}:void 0),dr=f(()=>({id:"volume",type:"desktop-control-panel-right",weight:qs.volume,buttonComponent:Um,buttonComponentProps:{click:Qn,isAds:At()}})),ps=f(()=>n(Sr)?{id:"subtitles",type:"desktop-control-panel-right",weight:qs.subtitles,buttonComponent:Om,buttonComponentProps:{isSubtitlesEnabled:n(rr),click:St},tooltipText:n(lr)}:void 0),Pr=f(()=>n(Wr)?{id:"settings",type:"desktop-control-panel-right",weight:qs.settings,buttonComponent:td,buttonComponentProps:{ref$:qi},tooltipText:xe()?void 0:gt("tooltip_settings_off")}:void 0),Is=f(()=>le.features.contextMenuButton?{id:"context",type:"desktop-control-panel-right",weight:qs.context,buttonComponent:iv,buttonComponentProps:{ariaLabel:gt("aria_label_context_menu")},className:n(zr)?"":"out-of-view",tooltipText:n(nn)}:void 0),Ys=f(()=>n(sr)?{id:"fullscreen",type:"desktop-control-panel-right",weight:qs.fullscreen,buttonComponent:mc,buttonComponentProps:{isFullscreen:P(),click:e.toggleFullscreen},tooltipText:n(Cr)}:void 0),ya=f(()=>n(vt)?{id:"chromecast",type:"desktop-control-panel-right",weight:qs.chromecast,buttonComponent:hc,buttonComponentProps:{state:p(),click:$r},tooltipText:n(wn)}:void 0),ct=f(()=>[n(jn),n(qo),n(dr),n(ps),n(Pr),n(Is),n(Ys),n(ya),...D()].filter(mt=>!!mt).sort(Ya)),di=Y.ui.previewTrackActive,Ao=Y.ui.previewTrackDragInProgress,Si=Y.ui.previewTrackAvailable,In=Y.ui.isPreviewTrackHorizontallyAligned,En=f(()=>Gb({onPreviewTrackOpened:Y.actions.internal.previewTrackOpened,getTimelineRef:()=>Nt.timeline,isHorizontal:Le()})),Es=f(()=>n(En).progressBarY),Ps=f(()=>n(En).controlsY),Qi=f(()=>n(En).onPointerDown),ki=f(()=>n(En).onPointerMove),he=f(()=>n(En).onPointerUp),wt=f(()=>n(En).calculatedHeight),ci=f(()=>n(En).closePreviewTrack);Oe(()=>{se()?li.set(!1):n(ci)()});let Zt;Dt(()=>()=>Zt&&clearTimeout(Zt));let Lo=mt=>{se()||!et()||(n(Qi)(mt),Zt=setTimeout(()=>{Y.actions.internal.previewTrackDragStarted()},200))},po=()=>{se()||n(he)(),Zt&&clearTimeout(Zt),Ee()&&Y.actions.internal.previewTrackDragFinished()},Qo=mt=>{n(ki)(mt),!se()&&et()&&!se()&&li.set(!0)},ks=()=>{li.set(!1)};var Yr=fw(),kr=ue(Yr);let xa;var js=C(kr);{var wa=mt=>{let rt=f(()=>n(Es)()),to=f(()=>n(wt)());hv(mt,{get animatedOffsetY(){return n(rt)},get animatedPreviewTrackHeight(){return n(to)},get canRewindLive(){return e.canRewindLive},get isAds(){return At()},onTimelineMove:Qo,onTimelinePointerDown:Lo,onTimelinePointerUp:po,onTimelinePointerLeave:ks,get previewTrackAvailable(){return et()},get timelineRef(){return Nt.timeline},set timelineRef(Mo){Nt.timeline=Mo}})};V(js,mt=>{e.showControls&&mt(wa)})}var jr=k(js,2),Pn=C(jr),gl=C(Pn);yi(gl,17,()=>n(Tn),mt=>mt.id,(mt,rt)=>{$p(mt,{get buttonComponent(){return n(rt).buttonComponent},get buttonComponentProps(){return n(rt).buttonComponentProps},get tooltipText(){return n(rt).tooltipText},get disabledTooltipContent(){return n(rt).disabledTooltipContent},get disabled(){return n(rt).disabled},get className(){return n(rt).className},get tooltipEnabled(){return n(rt).tooltipEnabled},get mouseEnter(){return n(rt).mouseEnter},get mouseLeave(){return n(rt).mouseLeave},get tooltipVisible(){return e.showControls},get ref(){return Nt[n(rt).id]},set ref(to){Nt[n(rt).id]=to}})});var Sa=k(gl,2);{var Xr=mt=>{let rt=f(()=>!e.showControls),to=f(()=>At()?Te():Fe()),Mo=f(()=>At()?kt():Tt());uc(mt,{get isHidden(){return n(rt)},isMobile:!1,get showDuration(){return n(zo)},get position(){return n(to)},get duration(){return n(Mo)},get ref(){return Nt.time},set ref(io){Nt.time=io}})};V(Sa,mt=>{n(wo)&&mt(Xr)})}var hl=k(Sa,2);let hd=f(()=>!n($n));Do(hl,{className:"w-max",get disabled(){return n(hd)},get tooltipContent(){return Ko},get tooltipVisible(){return e.showControls},get ref(){return Nt.episodes},set ref(mt){Nt.episodes=mt},children:(mt,rt)=>{var to=Me(),Mo=ue(to);{var io=bi=>{_c(bi,{get position(){return Fe()},get duration(){return Tt()},get timeCodes(){return Ti}})};V(Mo,bi=>{n($n)&&bi(io)})}$(mt,to)},$$slots:{default:!0}}),S(Pn);var Ca=k(Pn,2);yi(Ca,21,()=>n(ct),mt=>mt.id,(mt,rt)=>{var to=Me(),Mo=ue(to);{var io=Gi=>{$p(Gi,{get buttonComponent(){return n(rt).buttonComponent},get buttonComponentProps(){return n(rt).buttonComponentProps},get tooltipText(){return n(rt).tooltipText},get disabledTooltipContent(){return n(rt).disabledTooltipContent},get disabled(){return n(rt).disabled},get className(){return n(rt).className},get tooltipVisible(){return e.showControls},get ref(){return Nt[n(rt).id]},set ref(Xs){Nt[n(rt).id]=Xs}})},bi=Gi=>{let Xs=f(()=>!!n(rt).disabled);lv(Gi,{get id(){return n(rt).id},get testId(){return n(rt).testId},get icon(){return n(rt).icon},get ariaLabel(){return n(rt).ariaLabel},get tooltipText(){return n(rt).tooltipText},get disabledTooltipContent(){return n(rt).disabledTooltipContent},get disabled(){return n(Xs)},get onClick(){return n(rt).onClick},get disableMouseupTooltipShow(){return n(rt).disableMouseupTooltipShow},get tooltipVisible(){return e.showControls},get ref(){return Nt[n(rt).id]},set ref(bd){Nt[n(rt).id]=bd}})};V(Mo,Gi=>{Kb(n(rt))?Gi(io):Gi(bi,!1)})}$(mt,to)}),S(Ca),S(jr),Xe(jr,mt=>pt(mt),()=>pt()),S(kr),Xe(kr,mt=>Vt(mt),()=>Vt());var _d=k(kr,2);{var _l=mt=>{xc(mt,{get ref(){return Nt.interactiveTimeIndicator},set ref(rt){Nt.interactiveTimeIndicator=rt}})};V(_d,mt=>{Br&&mt(_l)})}O((mt,rt)=>{xa=oe(kr,1,"wrapper-bottom s-1b",null,xa,mt),qe(jr,rt),jr.inert=se()},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth||Ee()}),()=>`transform: translateY(${n(Ps)()}px);`]),Rn(Pn,"clientWidth",mt=>N(ft,mt)),$(i,Yr),H(),o()}var ld=require("@vkontakte/videoplayer-core/es2015");var $v=require("@vkontakte/videoplayer-shared/es2015");var vw=L('<div class="icon icon-error-stub s-24"><div class="inner s-24"></div></div>'),gw=L('<img class="icon s-24" aria-hidden="true"/>'),hw={hash:"s-24",code:".icon.s-24{height:24px!important;width:24px!important}.inner.s-24{background-color:var(--white);height:16px;width:16px}"};function yv(i,e){Q(i,hw);let t=h(e,"disabled",3,!1),o=h(e,"onClick",3,$v.noop),r=f(()=>o()===$v.noop),a=f(()=>n(r)||t()),l=q(!1),d=()=>{N(l,!0)},s=f(()=>n(r)?"btn-full-opacity":"");Kt(i,{get className(){return n(s)},get ariaLabel(){return e.ariaLabel},get click(){return o()},get disabled(){return n(a)},get testId(){return e.testId},children:(u,m)=>{var p=Me(),v=ue(p);{var b=_=>{var x=vw();$(_,x)},y=_=>{var x=gw();O(()=>Re(x,"src",e.iconUrl)),ut("error",x,d),Ba(x),$(_,x)};V(v,_=>{n(l)?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}})}var _w=Ie('<path d="M8.7 8.1 5.3 4.72A1 1 0 0 1 6.72 3.3L20.7 17.29a1 1 0 0 1-1.41 1.41L16 15.41V20a1 1 0 0 1-1 1c-.64 0-1.26-.25-1.72-.7L7.79 15H5a2 2 0 0 1-2-2v-2a2 2 0 0 1 2-2h2.77zm2.88-2.76 1.7-1.65A2.5 2.5 0 0 1 15 3a1 1 0 0 1 1 1v5.76z"></path>');function xv(i){Ze(i,{testId:"muted-icon",children:(e,t)=>{var o=_w();$(e,o)},$$slots:{default:!0}})}var Zb=require("@vkontakte/videoplayer-shared/es2015");function wp(i,e){B(e,!0);let t=h(e,"muted",3,!1),o=h(e,"click",3,Zb.noop),r=h(e,"ref",15,void 0),l=be().ui.t,d=f(()=>t()?l("tooltip_volume"):l("tooltip_volume_muted")),s=f(()=>t()?"btn-mobile-muted":"btn-mobile-unmuted");Kt(i,{get testId(){return n(s)},get click(){return o()},get ariaLabel(){return n(d)},role:"button",get ref(){return r()},set ref(u){r(u)},children:(u,m)=>{var p=Me(),v=ue(p);{var b=_=>{xv(_,{})},y=_=>{ha(_,{get size(){return"24"}})};V(v,_=>{t()?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}var bw=Ie('<path d="M11.64 12.37 9.07 9.8h1.03a.9.9 0 1 0 0-1.8H6.9a.9.9 0 0 0-.9.9v3.2a.9.9 0 0 0 1.8 0v-1.02l2.53 2.52.13.14a.9.9 0 0 0 1.28-1.28z"></path>'),$w=Ie('<path d="m6.36 9.63 2.57 2.57H7.9a.9.9 0 1 0 0 1.8h3.2a.9.9 0 0 0 .9-.9V9.9a.9.9 0 0 0-1.8 0v1.02L7.67 8.4l-.13-.14a.9.9 0 0 0-1.28 1.28z"></path>'),yw=Ie('<path d="M7.66 4h6.68q1.2-.01 2 .04.83.06 1.53.38a4 4 0 0 1 1.7 1.7c.24.48.34.98.39 1.54q.05.8.04 2v1.44a.9.9 0 0 1-1.8 0V9.7c0-.85 0-1.44-.04-1.9-.03-.44-.1-.68-.19-.85a2 2 0 0 0-.92-.92 2 2 0 0 0-.85-.2c-.46-.03-1.04-.03-1.9-.03H7.7c-.85 0-1.44 0-1.9.04-.44.03-.68.1-.85.19a2 2 0 0 0-.92.92c-.09.17-.16.4-.2.85-.03.46-.03 1.05-.03 1.9v2.65c0 .85 0 1.44.04 1.9.03.44.1.68.19.85a2 2 0 0 0 .92.92c.17.08.4.15.85.19.46.03 1.04.04 1.9.04h2.4a.9.9 0 0 1 0 1.8H7.66q-1.2.01-2-.05a4 4 0 0 1-1.53-.38 4 4 0 0 1-1.7-1.7 4 4 0 0 1-.39-1.53q-.05-.8-.04-2V9.65q-.01-1.2.04-2c.05-.56.15-1.06.39-1.53a4 4 0 0 1 1.7-1.7c.47-.24.97-.34 1.53-.39q.8-.05 2-.04M13 16.8c0-.98 0-1.47.19-1.84a2 2 0 0 1 .77-.77c.37-.19.86-.19 1.84-.19h3.4c.98 0 1.47 0 1.85.19q.5.27.76.77c.19.37.19.86.19 1.84v.4c0 .98 0 1.47-.19 1.85a2 2 0 0 1-.77.76c-.37.19-.86.19-1.84.19h-3.4c-.98 0-1.47 0-1.85-.19a2 2 0 0 1-.76-.76c-.19-.38-.19-.87-.19-1.85z"></path><!>',1);function wv(i,e){let t=h(e,"isActive",3,!1),o=f(()=>t()?"pip-icon--active":"pip-icon");Ze(i,{get testId(){return n(o)},children:(r,a)=>{var l=yw(),d=k(ue(l));{var s=m=>{var p=bw();$(m,p)},u=m=>{var p=$w();$(m,p)};V(d,m=>{t()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}var Jb=require("@vkontakte/videoplayer-shared/es2015");function Sv(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"isPictureInPictureActive",3,!1),r=h(e,"click",3,Jb.noop),a=j("menu_pip");Kt(i,{testId:"btn-pip",get ariaLabel(){return a},get click(){return r()},get ref(){return t()},set ref(l){t(l)},children:(l,d)=>{wv(l,{get isActive(){return o()}})},$$slots:{default:!0}}),H()}var Cv=require("@vkontakte/videoplayer-shared/es2015");var xw=(i,e,t,o)=>{n(e)&&t.onDisabledPlayPrevChapterClick(n(o))},ww=(i,e,t,o)=>{n(e)&&t.onDisabledSeekToInteractiveClick(n(o))},Sw=L("<div><!></div>"),Cw=L("<div><!></div>"),Tw=L("<div><!></div>"),Iw=L("<!> <!> <!>",1),Ew=L("<div></div> <div></div> <div><!> <!> <!> <!> <!> <!></div> <div><!> <!> <!> <!></div> <!>",1),Pw=L('<div class="wrapper-middle s-19"><!></div>'),kw=L("<div><!></div> <!> <div><!></div>",1),Aw=L('<div aria-hidden="true">·</div> <!>',1),Lw=L('<!> <!> <div><div><div class="controls mobile s-19" data-testid="bottom-controls"><div class="controls-group contain s-19"><!> <!> <!> <!></div> <div class="controls-group s-19"><!> <!> <!></div></div> <!></div></div> <!>',1),Mw={hash:"s-19",code:".wrapper-bottom.s-19{background:var(--controls-gradient);bottom:0;box-sizing:border-box;display:flex;flex-direction:column;height:var(--controls-gradient-height);justify-content:flex-end;left:0;padding:0 4px 8px;pointer-events:none;position:absolute;transition:transform var(--controls-transition-duration) var(--controls-transition-fn);width:100%;z-index:var(--controls-container-z-index)}.wrapper-bottom.s-19>:where(.s-19){pointer-events:auto}.wrapper-bottom.ads-timeline-mobile.s-19{height:9px;padding:0 4px 4px}.wrapper-middle.s-19{align-items:center;left:50%;top:50%;transform:translate(-50%,-50%)}.wrapper-middle.s-19,.wrapper-top-right.s-19{display:flex;position:absolute;transition:opacity var(--controls-transition-duration);z-index:var(--controls-container-z-index)}.wrapper-top-right.s-19{right:8px;top:4px}.wrapper-top-left.s-19{left:8px;position:absolute;top:4px;z-index:var(--controls-container-z-index)}.wrapper-middle-left.s-19,.wrapper-middle-left-second.s-19,.wrapper-middle-right.s-19{align-items:center;background-color:rgba(0,0,0,.56);border-radius:12px;display:flex;height:44px;justify-content:center;position:absolute;top:50%;transform:translateY(-50%);transition:opacity var(--controls-transition-duration);width:44px}.wrapper-middle-left.s-19{left:12px}.wrapper-middle-left-second.s-19{left:64px}.wrapper-middle-right.s-19{right:12px}.controls.s-19{align-items:center;box-sizing:border-box;font-size:13px;height:var(--controls-height);justify-content:space-between;padding:0 4px;transition:transform var(--controls-transition-duration) var(--controls-transition-fn);white-space:nowrap;width:100%;will-change:transform}.controls.s-19,.controls-group.s-19{display:flex}.controls-group.contain.s-19{min-width:0}.controls-group.s-19 >:not(:first-child){margin-left:8px}.hidden.s-19{opacity:0;visibility:hidden}.controls-hidden.s-19{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-19{transition:none}.overlay-mobile.s-19{background-color:rgba(0,0,0,.3);height:100%;left:0;pointer-events:none;position:absolute;top:0;transition:opacity var(--controls-transition-duration);width:100%}@media screen and (orientation:portrait){.wrapper-top-left.fullscreen.s-19,.wrapper-top-right.fullscreen.s-19{top:16px}.controls-wrapper.fullscreen.s-19{bottom:30px;position:absolute;width:calc(100% - 8px)}}@media screen and (orientation:landscape){.wrapper-top-left.fullscreen.s-19{left:44px;top:12px}.wrapper-top-right.fullscreen.s-19{right:44px;top:12px}.wrapper-middle-left.fullscreen.s-19{left:44px}.wrapper-middle-left-second.fullscreen.s-19{left:96px}.wrapper-middle-right.fullscreen.s-19{right:44px}.controls-wrapper.fullscreen.s-19{bottom:32px;left:36px;position:absolute;right:36px;width:calc(100% - 72px)}}"};function Tv(i,e){var an,ln;B(e,!0),Q(i,Mw);let[t,o]=De(),r=()=>w(Mi,"$seekToInteractiveDisabledTooltip$",t),a=()=>w(oi,"$disabledControls$",t),l=()=>w(Lt,"$playbackState$",t),d=()=>w(tn,"$adPlaybackState",t),s=()=>w(Y,"$isEnded$",t),u=()=>w(bt,"$playerSize",t),m=()=>w(St,"$scrubbingInProgress",t),p=()=>w(Hi,"$chromecastState$",t),v=()=>w(Be,"$isPictureInPictureActive",t),b=()=>w(We,"$pictureInPictureType$",t),y=()=>w(fe,"$mobileNotReportControlHidden$",t),_=()=>w(vi,"$chromecastHidden",t),x=()=>w(pt,"$playerPhase",t),I=()=>w(Bt,"$pipHidden",t),T=()=>w(lt,"$currentGridType$",t),R=()=>w(fi,"$vkLogoHidden",t),A=()=>w(ai,"$volumeHidden",t),P=()=>w(Pe,"$isLive$",t),E=()=>w(Ct,"$settingsMenuVisible",t),z=()=>w(dt,"$isRewindableLive$",t),F=()=>w(Ve,"$isActiveLive$",t),U=()=>w(Ft,"$isAudioAvailable$",t),X=()=>w($e,"$muted$",t),ae=()=>w(le,"$volume$",t),Z=()=>w(gt,"$isInteractiveTime$",t),re=()=>w(ar,"$settingButtonRef$",t),J=()=>w(Ti,"$startedByKeyboard$",t),we=()=>w(Bo,"$isFullscreen",t),me=()=>w(Ut,"$additionalButtons$",t),ee=()=>w(Bi,"$autoplayNextToggleHidden",t),_e=()=>w(xi,"$crashed$",t),Ce=()=>w(_o,"$settingsHidden",t),ge=()=>w(vn,"$graphIsOpened$",t),pe=()=>w(Ei,"$adPosition",t),Qe=()=>w(nt,"$adDuration",t),G=()=>w(ti,"$position$",t),D=()=>w(At,"$duration$",t),Ge=h(e,"playerControlsWrapperRef",15,void 0),K=h(e,"playerControlsRef",15,void 0),se=h(e,"isAds",3,!1),xe=h(e,"logoTargetUrl",3,""),He=h(e,"isOneVideoPlaylist",3,!1),it=h(e,"customFullscreenSupported",3,!0),ne=be(),ce=yo(),Ne=Ot(),Le=ne.actions.internal.toggleMuted,et=ne.actions.internal.togglePlay,Ee=ne.actions.internal.pause,Te=ne.actions.internal.prevVideoClick,Fe=ne.actions.internal.nextVideoClick,kt=ne.actions.internal.checkFullscreenSupport,Tt=(an=ne.callbacks)==null?void 0:an.onAudioDoesNotExistHint,Vt=(ln=ne.callbacks)==null?void 0:ln.onAudioDisabledHint,pt=ne.playerPhase,At=ne.state.duration$,ti=ne.state.positionWithScrubbing$,Lt=ne.state.playbackState$,Ft=ne.state.isAudioAvailable$,qt=ne.state.isAudioDisabled,Y=ne.state.isEnded$,Pe=ne.state.isLive$,le=ne.state.volume$,$e=ne.state.muted$,Ve=ne.state.isActiveLive$,dt=ne.state.isRewindableLive$,St=ne.ui.scrubbingInProgress,fe=ne.ui.mobileNotReportControlHidden$,{isActive$:Be,type$:We}=ce.pictureInPicture$,Ct=ne.ui.settingsMenu.visible$,Xt=ne.ui.settingsMenu.openedByBtnKeyboard$,It=ne.ui.controls,{volume:ai,vkLogo:fi,autoplayNextToggle:Bi,pip:Bt,settings:_o,chromecast:vi}=ne.ui.hiddenControls,ot=ne.actions.internal.getVideoEpisodes(),Jt=ne.webApi.pictureInPictureApi,Hi=ne.state.chromecastState$,xi=ne.state.crashed$,oi=It.disabledControls$,Ti=ne.ui.startedByKeyboard$,lt=ne.ui.currentGridType$,nt=ne.ads.duration,Ei=ne.ads.position,tn=ne.ads.playbackState,Bo=ne.ui.isFullscreen,bt=ne.ui.playerSize,Ut=ne.ui.additionalButtonsDeprecated$,W=ne.actions.internal.getVideoElement,Rt=ne.actions.internal.replayInteractive,li=ne.state.isInteractive,gt=ne.state.isInteractiveTime$,ii=ne.state.showInteractiveGraph,xt=ne.state.showSeekToInteractive,st=ne.state.showPlayPrevChapter,Fi=ne.state.showInteractiveTimeIndicator,Mi=ce.seekToInteractiveDisabledTooltip$,vn=ce.graphIsOpened$,gn=ne.ui.controlBlocks,Vi=f(()=>j(ne.state.playPrevChapterDisabledTooltip)),Ui=f(()=>j(r())),Hn=f(()=>a().has("EPISODE_BUTTON")),bo=f(()=>a().has("GRAPH_BUTTON")),lo=f(()=>a().has("SEEK_TO_INTERACTIVE_BUTTON")),Ai=f(()=>a().has("PLAY_BUTTON")),Ho=f(()=>a().has("REPLAY_BUTTON")),Fo=f(()=>a().has("PLAY_PREV_CHAPTER_BUTTON")),hn=f(()=>l()===ld.PlaybackState.PLAYING),Or=f(()=>d()==="paused"),Br=f(()=>s()&&!se()&&!li),Hr=f(()=>!s()||se()),Ss=f(()=>e.showNextPrevButtons&&!se()&&e.prevButtonActive),Fr=f(()=>e.showNextPrevButtons&&!se()&&e.nextButtonActive),nr=f(()=>u().width>300),Ur=f(()=>u().width>400),_n=f(m),bn=f(()=>p()!==ld.ChromecastState.NOT_AVAILABLE&&!(v()&&b()===1)&&!y()&&!li&&!_()),_r=f(()=>x()==="LiveWaitingStart"),br=f(()=>!!Jt&&p()!==ld.ChromecastState.CONNECTED&&!y()&&(b()===1&&n(_r)||!n(_r))&&!n(_n)&&!li&&!I()),on=q(!1);Dt(()=>{let Ue=Jt==null?void 0:Jt.info.isActive$.subscribe(Et=>N(on,Et,!0));return()=>Ue==null?void 0:Ue.unsubscribe()});let $r=f(()=>!n(_n)&&ro(T(),"s")),yr=f(()=>!e.logoHidden&&u().width>350&&!R()),rr=f(()=>Ne.features.fullscreen&&kt()&&!(v()&&b()===1)&&(li?it():!0)&&!n(_n)&&!n(on)),Fn=f(()=>!A()&&!n(_n)),cs=f(()=>(!P()||se())&&u().width>260&&!n(_n)&&!(Ne.features.interactiveHideTime&&li)),xo=f(()=>E()||e.showControls),xr=f(()=>!se()&&!P()&&!!(ot!=null&&ot.length)&&n(nr)&&!n(Hn)&&!n(_n)),zi=f(()=>!z()||!!F()),wr=f(()=>ii&&ro(T(),"m")),Un=f(()=>!U()||X()||ae()===0),vt=ui({}),ni=ui({}),Sr=(0,Cv.debounceFn)(rd,260),zr=(0,Cv.debounceFn)(yp,260);Oe(()=>{u(),Z(),Sr(W(),It,vt,e.showControls),zr(W(),gn,ni,e.showControls)});let Wr=()=>ne.actions.internal.toggleChromecast();function zn(){return ht(this,null,function*(){Jt!=null&&Jt.isActive()?yield Jt==null?void 0:Jt.exit():yield Jt==null?void 0:Jt.request()})}function sr(){ma({isAudioDisabled:qt,audioDisabledHintCallback:Vt,isAudioAvailable:U(),audioIsNotExistHintCallback:Tt,isAds:se()})&&Le()}let wo=q(""),Wn=(Ue,Et)=>{if(!Ue){N(wo,j("tooltip_live"),!0);return}Et&&Et===ld.PlaybackState.PAUSED&&N(wo,j("tooltip_play"),!0)};Oe(()=>{Wn(n(zi),l())});let ar=de();Oe(()=>{re()&&jl(re(),E(),Xt)}),Oe(()=>{bp(Ti,J(),vt.playButton)});var Kn=Lw(),$n=ue(Kn);{var yn=Ue=>{var Et=Ew(),mi=ue(Et);let zo;var Io=k(mi,2);let Wo;Xe(Io,ct=>ni.topLeft=ct,()=>ni==null?void 0:ni.topLeft);var qi=k(Io,2);let Eo;var Qn=C(qi);yi(Qn,1,me,({iconUrl:ct,ariaLabel:di,testId:Ao,onClick:Si,tooltip:In})=>ct,(ct,di)=>{let Ao=()=>n(di).iconUrl,Si=()=>n(di).ariaLabel,In=()=>n(di).testId,En=()=>n(di).onClick,Es=()=>n(di).tooltip,Ps=f(()=>{var Qi;return(Qi=Si())!=null?Qi:Es()});yv(ct,{get iconUrl(){return Ao()},get ariaLabel(){return n(Ps)},get testId(){return In()},get onClick(){return En()}})});var Er=k(Qn,2);{var Po=ct=>{Cc(ct,{get ref(){return vt.autoplayNextToggle},set ref(di){vt.autoplayNextToggle=di}})};V(Er,ct=>{e.showAutoplayNext&&!He()&&!ee()&&ct(Po)})}var uo=k(Er,2);{var Cn=ct=>{hc(ct,{isMobile:!0,click:Wr,get state(){return p()},get ref(){return vt.chromecast},set ref(di){vt.chromecast=di}})};V(uo,ct=>{n(bn)&&ct(Cn)})}var Ko=k(uo,2);{var Gn=ct=>{Sv(ct,{click:zn,get isPictureInPictureActive(){return v()},get ref(){return vt.pip},set ref(di){vt.pip=di}})};V(Ko,ct=>{n(br)&&ct(Gn)})}var Qr=k(Ko,2);{var Gr=ct=>{td(ct,{get ref$(){return ar}})};V(Qr,ct=>{_e()&&!Ce()&&ct(Gr)})}var Yn=k(Qr,2);{var Je=ct=>{vc(ct,{get click(){return Ee},get targetUrl(){return xe()},get logoClickable(){return e.logoClickable},get ref(){return vt.vkLogo},set ref(di){vt.vkLogo=di}})};V(Yn,ct=>{n(yr)&&ct(Je)})}S(qi),Xe(qi,ct=>ni.topRight=ct,()=>ni==null?void 0:ni.topRight);var ei=k(qi,2);let wi;var ko=C(ei);{var Tn=ct=>{let di=f(()=>Te.bind(null,!0));il(ct,{get click(){return n(di)},type:"prev",isMobile:!0,get ref(){return vt.prevButton},set ref(Ao){vt.prevButton=Ao}})};V(ko,ct=>{n(Ss)&&ct(Tn)})}var jn=k(ko,2);{var qo=ct=>{ad(ct,{get disabled(){return n(Ai)},get click(){return et},isMobile:!0,get isPlaying(){return n(hn)},get ref(){return vt.playButton},set ref(di){vt.playButton=di}})};V(jn,ct=>{n(Hr)&&ct(qo)})}var dr=k(jn,2);{var ps=ct=>{sd(ct,{get disabled(){return n(Ho)},get click(){return et},isMobile:!0,get ref(){return vt.replayButton},set ref(di){vt.replayButton=di}})};V(dr,ct=>{n(Br)&&ct(ps)})}var Pr=k(dr,2);{var Is=ct=>{let di=f(()=>Fe.bind(null,!0));il(ct,{get click(){return n(di)},type:"next",isMobile:!0,get ref(){return vt.nextButton},set ref(Ao){vt.nextButton=Ao}})};V(Pr,ct=>{n(Fr)&&ct(Is)})}S(ei),Xe(ei,ct=>ni.middle=ct,()=>ni==null?void 0:ni.middle);var Ys=k(ei,2);{var ya=ct=>{var di=Iw(),Ao=ue(di);{var Si=Qi=>{var ki=Sw();let he;ki.__click=[xw,Fo,e,Vi];var wt=C(ki);let ci=f(()=>!e.showControls);Sc(wt,{get hidden(){return n(ci)},get disabled(){return n(Fo)},get click(){return e.playPrevChapter},get ref(){return vt.playPrevChapterButton},set ref(Zt){vt.playPrevChapterButton=Zt}}),S(ki),O(Zt=>he=oe(ki,1,"wrapper-middle-left s-19",null,he,Zt),[()=>({fullscreen:we(),hidden:!e.showControls})]),$(Qi,ki)};V(Ao,Qi=>{st&&Qi(Si)})}var In=k(Ao,2);{var En=Qi=>{var ki=Cw();let he;var wt=C(ki);let ci=f(()=>!e.showControls&&!ge());Ic(wt,{get hidden(){return n(ci)},get disabled(){return n(bo)},get click(){return vn.toggle},get graphIsOpened(){return ge()},get ref(){return vt.interactiveGraphButton},set ref(Zt){vt.interactiveGraphButton=Zt}}),S(ki),O(Zt=>he=oe(ki,1,zd(st?"wrapper-middle-left-second":"wrapper-middle-left"),"s-19",he,Zt),[()=>({fullscreen:we(),hidden:!e.showControls&&!ge()})]),$(Qi,ki)};V(In,Qi=>{n(wr)&&Qi(En)})}var Es=k(In,2);{var Ps=Qi=>{var ki=Tw();let he;ki.__click=[ww,lo,e,Ui];var wt=C(ki);let ci=f(()=>!e.showControls);Tc(wt,{get hidden(){return n(ci)},get disabled(){return n(lo)},get click(){return e.seekToInteractive},get ref(){return vt.seekToInteractiveButton},set ref(Zt){vt.seekToInteractiveButton=Zt}}),S(ki),O(Zt=>he=oe(ki,1,"wrapper-middle-right s-19",null,he,Zt),[()=>({fullscreen:we(),hidden:!e.showControls})]),$(Qi,ki)};V(Es,Qi=>{xt&&Qi(Ps)})}$(ct,di)};V(Ys,ct=>{li&&!m()&&ct(ya)})}O((ct,di,Ao,Si)=>{zo=oe(mi,1,"overlay-mobile s-19",null,zo,ct),Wo=oe(Io,1,"wrapper-top-left s-19",null,Wo,di),Eo=oe(qi,1,"wrapper-top-right s-19",null,Eo,Ao),wi=oe(ei,1,"wrapper-middle s-19",null,wi,Si)},[()=>({hidden:!n(xo)}),()=>({hidden:!e.showControls,fullscreen:we()}),()=>({hidden:!e.showControls&&!y(),fullscreen:we()}),()=>({hidden:!e.showControls||m()||e.endScreenShown&&e.showNextPrevButtons})]),$(Ue,Et)};V($n,Ue=>{se()||Ue(yn)})}var xn=k($n,2);{var nn=Ue=>{var Et=kw(),mi=ue(Et);let zo;var Io=C(mi);wp(Io,{get muted(){return X()},click:sr,get ref(){return vt.volume},set ref(Po){vt.volume=Po}}),S(mi);var Wo=k(mi,2);{var qi=Po=>{var uo=Pw(),Cn=C(uo);let Ko=f(()=>!n(Or));ad(Cn,{get disabled(){return n(Ai)},get click(){return et},isMobile:!0,get isPlaying(){return n(Ko)},get ref(){return vt.playButton},set ref(Gn){vt.playButton=Gn}}),S(uo),$(Po,uo)};V(Wo,Po=>{n(Or)&&Po(qi)})}var Eo=k(Wo,2);let Qn;var Er=C(Eo);Pc(Er,{get position(){return pe()},get duration(){return Qe()}}),S(Eo),O((Po,uo)=>{zo=oe(mi,1,"wrapper-top-right s-19",null,zo,Po),Qn=oe(Eo,1,"wrapper-bottom ads-timeline-mobile s-19",null,Qn,uo)},[()=>({fullscreen:we()}),()=>({fullscreen:we()})]),$(Ue,Et)};V(xn,Ue=>{se()&&d()!=="inactive"&&Ue(nn)})}var Wi=k(xn,2);let eo;var rn=C(Wi);let lr;var Cr=C(rn),wn=C(Cr),Tr=C(wn);{var ft=Ue=>{Do(Ue,{get disabled(){return n(Ho)},get ref(){return vt.replayButton},set ref(Et){vt.replayButton=Et},children:(Et,mi)=>{sd(Et,{get disabled(){return n(Ho)},get click(){return Rt}})},$$slots:{default:!0}})};V(Tr,Ue=>{li&&Ue(ft)})}var Nt=k(Tr,2);{var So=Ue=>{Do(Ue,{get ref(){return vt.liveButton},set ref(Et){vt.liveButton=Et},children:(Et,mi)=>{Ec(Et,{get isLiveActive(){return n(zi)},isMobile:!0,get ariaLabel(){return n(wo)}})},$$slots:{default:!0}})};V(Nt,Ue=>{!se()&&P()&&Ue(So)})}var Sn=k(Nt,2);{var Co=Ue=>{let Et=f(()=>se()?pe():G()),mi=f(()=>se()?Qe():D()),zo=f(()=>!e.showControls);uc(Ue,{get showDuration(){return n(Ur)},get position(){return n(Et)},get duration(){return n(mi)},isMobile:!0,get isHidden(){return n(zo)},get ref(){return vt.time},set ref(Io){vt.time=Io}})};V(Sn,Ue=>{n(cs)&&Ue(Co)})}var sn=k(Sn,2);let co=f(()=>!n(xr));Do(sn,{className:"w-max",get disabled(){return n(co)},get ref(){return vt.episodes},set ref(Ue){vt.episodes=Ue},children:(Ue,Et)=>{var mi=Me(),zo=ue(mi);{var Io=Wo=>{var qi=Aw(),Eo=k(ue(qi),2);_c(Eo,{get position(){return G()},get duration(){return D()},get timeCodes(){return ot}}),$(Wo,qi)};V(zo,Wo=>{n(xr)&&Wo(Io)})}$(Ue,mi)},$$slots:{default:!0}}),S(wn),Xe(wn,Ue=>ni.bottomLeft=Ue,()=>ni==null?void 0:ni.bottomLeft);var To=k(wn,2),Pi=C(To);{var Kr=Ue=>{Do(Ue,{get ref(){return vt.volume},set ref(Et){vt.volume=Et},children:(Et,mi)=>{wp(Et,{get muted(){return n(Un)},click:sr})},$$slots:{default:!0}})};V(Pi,Ue=>{n(Fn)&&Ue(Kr)})}var qn=k(Pi,2);{var Cs=Ue=>{Do(Ue,{get ref(){return vt.settings},set ref(Et){vt.settings=Et},children:(Et,mi)=>{td(Et,{get ref$(){return ar}})},$$slots:{default:!0}})};V(qn,Ue=>{n($r)&&Ue(Cs)})}var Ki=k(qn,2);{var Ts=Ue=>{Do(Ue,{get ref(){return vt.fullscreen},set ref(Et){vt.fullscreen=Et},children:(Et,mi)=>{mc(Et,{get click(){return e.toggleFullscreen},get isFullscreen(){return we()}})},$$slots:{default:!0}})};V(Ki,Ue=>{n(rr)&&Ue(Ts)})}S(To),Xe(To,Ue=>ni.bottomRight=Ue,()=>ni==null?void 0:ni.bottomRight),S(Cr),Xe(Cr,Ue=>K(Ue),()=>K());var us=k(Cr,2);let Ir=f(()=>!e.showControls);nl(us,{get isHidden(){return n(Ir)},get isAds(){return se()},get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return z()},get ref(){return vt.timeline},set ref(Ue){vt.timeline=Ue}}),S(rn),Xe(rn,Ue=>ni.bottom=Ue,()=>ni==null?void 0:ni.bottom),S(Wi),Xe(Wi,Ue=>Ge(Ue),()=>Ge());var Uo=k(Wi,2);{var qr=Ue=>{xc(Ue,{get ref(){return vt.interactiveTimeIndicator},set ref(Et){vt.interactiveTimeIndicator=Et}})};V(Uo,Ue=>{Fi&&Ue(qr)})}O((Ue,Et)=>{eo=oe(Wi,1,"wrapper-bottom mobile s-19",null,eo,Ue),lr=oe(rn,1,"controls-wrapper s-19",null,lr,Et)},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth}),()=>({fullscreen:we()})]),$(i,Kn),H(),o()}Ye(["click"]);function kc(i,e){B(e,!0);let[t,o]=De(),r=()=>w(I,"$isMobile",t),a=h(e,"bottomNoSmooth",3,!1),l=h(e,"playerControlsWrapperRef",15,void 0),d=h(e,"playerControlsRef",15,void 0),s=h(e,"isAds",3,!1),u=h(e,"logoTargetUrl",3,""),m=h(e,"showAutoplayNext",3,!1),p=h(e,"isOneVideoPlaylist",3,!1),v=h(e,"customFullscreenSupported",3,!0),b=h(e,"endScreenShown",3,!1),y=h(e,"onDisabledPlayPrevChapterClick",3,Iv.noop),_=h(e,"onDisabledSeekToInteractiveClick",3,Iv.noop),I=be().ui.isMobile,T=q(!1);Dt(()=>{let E=setTimeout(()=>N(T,!0),0);return()=>clearTimeout(E)});var R=Me(),A=ue(R);{var P=E=>{var z=Me(),F=ue(z);{var U=ae=>{Tv(ae,{get bottomHidden(){return e.bottomHidden},get bottomNoSmooth(){return a()},get showControls(){return e.showControls},get isAds(){return s()},get canRewindLive(){return e.canRewindLive},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return u()},get showAutoplayNext(){return m()},get showNextPrevButtons(){return e.showNextPrevButtons},get nextButtonActive(){return e.nextButtonActive},get prevButtonActive(){return e.prevButtonActive},get isOneVideoPlaylist(){return p()},get customFullscreenSupported(){return v()},get endScreenShown(){return b()},get toggleFullscreen(){return e.toggleFullscreen},get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get onDisabledPlayPrevChapterClick(){return y()},get onDisabledSeekToInteractiveClick(){return _()},get playerControlsWrapperRef(){return l()},set playerControlsWrapperRef(Z){l(Z)},get playerControlsRef(){return d()},set playerControlsRef(Z){d(Z)}})},X=ae=>{bv(ae,{get bottomHidden(){return e.bottomHidden},get bottomNoSmooth(){return a()},get showControls(){return e.showControls},get isAds(){return s()},get canRewindLive(){return e.canRewindLive},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return u()},get isOneVideoPlaylist(){return p()},get showAutoplayNext(){return m()},get showNextPrevButtons(){return e.showNextPrevButtons},get nextButtonActive(){return e.nextButtonActive},get prevButtonActive(){return e.prevButtonActive},get customFullscreenSupported(){return v()},get toggleFullscreen(){return e.toggleFullscreen},get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get playerControlsWrapperRef(){return l()},set playerControlsWrapperRef(Z){l(Z)},get playerControlsRef(){return d()},set playerControlsRef(Z){d(Z)}})};V(F,ae=>{r()?ae(U):ae(X,!1)})}$(E,z)};V(A,E=>{n(T)&&E(P)})}$(i,R),H(),o()}var Vw=Ie('<path d="M23.75 31.2v-5.45l-11.84 6.7a1.45 1.45 180 01-2.16-1.25v-14.4a1.45 1.45 180 012.16-1.26l11.84 6.7v-5.44a1.45 1.45 180 012.16-1.26l12.7 7.19a1.45 1.45 180 010 2.52l-12.7 7.2a1.45 1.45 180 01-2.16-1.27Z"></path>');function Ac(i,e){B(e,!0);let t=f(()=>e.reversed?"transform:scaleX(-1);transform-origin:50% 0;":""),o=f(()=>`${fn(e.size)}${n(t)}`);Ze(i,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(o)},get testId(){return e.testId},get shadow(){return e.shadow},children:(r,a)=>{var l=Vw();$(r,l)},$$slots:{default:!0}}),H()}var Rw=Ie('<path d="M32.46 9.53a1.16 1.16 90 010 1.96l-7.66 4.83c-.78.49-1.8-.07-1.8-.98v-3.3a14 14 90 1014.1 18.93 1.5 1.5 90 012.8 1.06 17 17 90 11-16.9-23V5.66c0-.91 1.03-1.47 1.8-.98z"></path>');function Ev(i,e){B(e,!0);let t=h(e,"reversed",3,!1),o=f(()=>t()?"transform:scaleX(-1);transform-origin: 50% 0;":void 0),r=f(()=>`seek-icon-${t()?"backward":"forward"}`);Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(o)},get testId(){return n(r)},get shadow(){return e.shadow},children:(a,l)=>{var d=Rw();$(a,d)},$$slots:{default:!0}}),H()}var Nw=L('<span class="hot-key-helpers-text s-13"> </span>'),Dw=L('<div data-testid="hotkey-helper-icon" class="s-13"><!> <!> <!> <!> <!> <!> <!> <!> <!> <!></div> <!>',1),Ow=L("<div><!></div>"),Bw={hash:"s-13",code:'.hot-key-helpers-container.s-13{align-items:center;animation:s-13-fadeIn ease var(--controls-transition-duration);box-sizing:border-box;display:flex;flex-direction:column;height:120px;left:calc(50% - 100px);padding-top:14px;position:absolute;top:calc(50% - 40px);width:200px;z-index:var(--hot-key-helpers-container-z-index)}.hot-key-helpers-container--left.s-13{left:calc(25% - 100px)}.hot-key-helpers-container--right.s-13{left:calc(75% - 100px)}.hot-key-helpers-text.s-13{display:-webkit-box;font-feature-settings:"clig" off,"liga" off;font-size:15px;font-style:normal;font-weight:600;letter-spacing:-.105px;-webkit-line-clamp:2;line-height:20px;margin-top:4px;max-height:40px;overflow:hidden;text-align:center;text-overflow:ellipsis;text-shadow:0 0 5px rgba(0,0,0,.16);white-space:pre-wrap;width:100%;-webkit-box-orient:vertical}.hidden.s-13{animation:s-13-fadeOut ease var(--controls-transition-duration);height:0;visibility:hidden;width:0}@keyframes s-13-fadeIn{0%{opacity:0}to{opacity:1}}@keyframes s-13-fadeOut{0%{opacity:1}to{opacity:0}}'};function Pv(i,e){B(e,!0),Q(i,Bw);let[t,o]=De(),r=()=>w(e.data,"$data",t),a=be(),{features:l}=Ot(),d=a.ui.t,s=f(()=>!r()),u=f(()=>{var I;return((I=r())==null?void 0:I.type)==="BACKWARD_SEEK"}),m=f(()=>{var I;return((I=r())==null?void 0:I.type)==="FORWARD_SEEK"}),p=f(()=>{var I;return(I=r())==null?void 0:I.type}),v=f(()=>{var I,T;return(I=r())!=null&&I.t?d(r().t.key,{value:r().t.value||""}):(T=r())==null?void 0:T.text});var b=Ow();let y;var _=C(b);{var x=I=>{var T=Dw(),R=ue(T),A=C(R);{var P=K=>{let se=f(()=>n(p)==="BACKWARD_SEEK");Ev(K,{get reversed(){return n(se)},shadow:!0})};V(A,K=>{["BACKWARD_SEEK","FORWARD_SEEK"].includes(n(p))&&K(P)})}var E=k(A,2);{var z=K=>{Ks(K,{get size(){return"48"},shadow:!0})};V(E,K=>{n(p)==="PAUSE"&&!l.playbackStatusShow&&K(z)})}var F=k(E,2);{var U=K=>{Dn(K,{get size(){return"48"},shadow:!0})};V(F,K=>{n(p)==="PLAY"&&!l.playbackStatusShow&&K(U)})}var X=k(F,2);{var ae=K=>{wc(K,{get size(){return"48"},shadow:!0})};V(X,K=>{n(p)==="REPLAY"&&!l.playbackStatusShow&&K(ae)})}var Z=k(X,2);{var re=K=>{ga(K,{get size(){return"48"},type:"off",shadow:!0})};V(Z,K=>{n(p)==="SUBTITLES_OFF"&&K(re)})}var J=k(Z,2);{var we=K=>{ga(K,{get size(){return"48"},shadow:!0})};V(J,K=>{n(p)==="SUBTITLES_ON"&&K(we)})}var me=k(J,2);{var ee=K=>{let se=f(()=>n(p)==="RATE_DOWN");Ac(K,{get size(){return"48"},get reversed(){return n(se)},testId:"rate-change-icon",shadow:!0})};V(me,K=>{["RATE_DOWN","RATE_UP"].includes(n(p))&&K(ee)})}var _e=k(me,2);{var Ce=K=>{let se=f(()=>n(p)==="EPISODE_PREV");_a(K,{get size(){return"48"},get reversed(){return n(se)},shadow:!0})};V(_e,K=>{["EPISODE_PREV","EPISODE_NEXT"].includes(n(p))&&K(Ce)})}var ge=k(_e,2);{var pe=K=>{ha(K,{get size(){return"48"},volume:0,shadow:!0})};V(ge,K=>{n(p)==="MUTE"&&K(pe)})}var Qe=k(ge,2);{var G=K=>{ha(K,{get size(){return"48"},volume:1,shadow:!0})};V(Qe,K=>{n(p)==="VOLUME"&&K(G)})}S(R);var D=k(R,2);{var Ge=K=>{var se=Nw(),xe=C(se,!0);S(se),O(()=>ve(xe,n(v))),$(K,se)};V(D,K=>{n(v)&&K(Ge)})}O(()=>Re(R,"data-type",n(p))),$(I,T)};V(_,I=>{!n(s)&&n(p)&&I(x)})}S(b),O(I=>y=oe(b,1,"hot-key-helpers-container s-13",null,y,I),[()=>({hidden:n(s),"hot-key-helpers-container--left":n(u),"hot-key-helpers-container--right":n(m)})]),$(i,b),H(),o()}var Hw=(i,e,t,o,r,a)=>{if(e.has(i.code))switch(i.preventDefault(),i.stopPropagation(),i.code){case"ArrowUp":t();break;case"ArrowDown":o();break;case"ArrowLeft":r();break;case"ArrowRight":a();break}},Fw=(i,e,t)=>{e.has(i.code)&&(i.preventDefault(),i.stopPropagation(),t())},Uw=L('<div tabindex="0" role="button"><div class="button-block s-m" aria-hidden="true"><div class="button-row s-m"><div class="button button-up s-m"><!></div> <div class="button button-right s-m"><!></div></div> <div class="button-row s-m"><div class="button button-left s-m"><!></div> <div class="button button-down s-m"><!></div></div></div></div>'),zw={hash:"s-m",code:".immersive-controls.s-m{background-color:rgba(0,0,0,.56);border-radius:8px;display:flex;flex-direction:row;height:56px;left:10px;position:absolute;top:10px;transition-duration:var(--controls-transition-duration);transition-property:top,left;transition-timing-function:var(--controls-transition-fn);width:56px}.immersive-controls.m-shifted.s-m{left:20px;top:50px}.button-block.s-m{height:40px;margin:auto;transform:rotate(45deg);width:40px}.button-row.s-m{display:flex;flex-direction:row;position:relative}.button.s-m{cursor:pointer;height:20px;text-align:center;width:20px}.button.s-m svg{opacity:.7;transition:opacity .2s linear}.button.button-up.s-m svg{transform:rotate(-45deg) translate(-1px,-1px)}.button.button-right.s-m svg{transform:rotate(45deg) translate(1px,-1px)}.button.button-down.s-m svg{transform:rotate(135deg) translate(1px,-3px)}.button.button-left.s-m svg{transform:rotate(-135deg) translate(-1px,-3px)}.button.s-m:hover svg{opacity:1}"};function Lc(i,e){B(e,!0),Q(i,zw);let t=h(e,"isShifted",3,!1),o=be(),r=new Set(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"]),a=()=>{o.actions.internal.startCameraManualRotation(0,1)},l=()=>{o.actions.internal.startCameraManualRotation(0,-1)},d=()=>{o.actions.internal.startCameraManualRotation(1,0)},s=()=>{o.actions.internal.startCameraManualRotation(-1,0)},u=()=>(o.actions.internal.stopCameraManualRotation(),null),m=j("aria_label_spherical_control");var p=Uw();let v;p.__keydown=[Hw,r,a,l,s,d],p.__keyup=[Fw,r,u];var b=C(p),y=C(b),_=C(y);_.__mousedown=a,_.__mouseup=u;var x=C(_);Nr(x,{direction:"up",useBtnColor:!0}),S(_);var I=k(_,2);I.__mousedown=d,I.__mouseup=u;var T=C(I);Nr(T,{direction:"up",useBtnColor:!0}),S(I),S(y);var R=k(y,2),A=C(R);A.__mousedown=s,A.__mouseup=u;var P=C(A);Nr(P,{direction:"up",useBtnColor:!0}),S(A);var E=k(A,2);E.__mousedown=l,E.__mouseup=u;var z=C(E);Nr(z,{direction:"up",useBtnColor:!0}),S(E),S(R),S(b),S(p),O(F=>{v=oe(p,1,"immersive-controls s-m",null,v,F),Re(p,"aria-label",m)},[()=>({"m-shifted":t()})]),ut("mouseleave",_,u),ut("mouseleave",I,u),ut("mouseleave",A,u),ut("mouseleave",E,u),$(i,p),H()}Ye(["keydown","keyup","mousedown","mouseup"]);var Qs=require("@vkontakte/videoplayer-shared/es2015");var e$=(i=1e3)=>{let e=null,t=()=>{e&&(clearTimeout(e),e=null)};return{add:o=>{t(),e=setTimeout(o,i)},clear:t}};var Sp=class{constructor(){this.flickeringTimeout=e$(1e3);this.subscriptions=new Qs.Subscription;this.isAuto=!1;this.isLive=!1;this.captions$=new Qs.ValueSubject([]);this.captionsPrepared$=new Qs.ValueSubject([])}subscribe(){return this.subscriptions.add(this.captions$.pipe((0,Qs.filter)(()=>this.isEnabled()),(0,Qs.filterChanged)()).subscribe(e=>{this.processCaptions(e)})),this}setIsAuto(e){this.isAuto=e}setIsLive(e){this.isLive=e}setCaptions(e){this.captions$.next(e)}destroy(){this.subscriptions.unsubscribe(),this.flickeringTimeout.clear()}isEnabled(){return this.isAuto&&!this.isLive}processCaptions(e){if(!e.length){this.flickeringTimeout.add(()=>{this.captionsPrepared$.next([])});return}this.flickeringTimeout.clear();let t=[],o=e.length>1&&e[0].type!=="timestamp"&&e[1].type!=="timestamp";o&&t.push([{value:String(e[0].value),timeAppeared:null}]),t.push(e.reduce((r,{type:a,value:l},d)=>(o&&!d||(a==="timestamp"?r.push({timeAppeared:Number(l),value:""}):r.length===0?r.push({value:String(l)}):r[r.length-1].value=String(l)),r),[])),this.captionsPrepared$.next(t)}};var Ww=L('<span class="caption-line s-a"><span class="caption-segment s-a"> </span></span>'),Kw=L('<span class="caption-line s-a"><span class="caption-segment s-a"></span></span>'),qw=L('<span class="caption-line s-a"><span class="caption-segment s-a"> </span></span>'),Qw=L('<div><span class="caption s-a"><!></span></div>'),Gw=L("<div><!></div>"),Yw={hash:"s-a",code:".subtitles-container.s-a{height:100%;left:0;pointer-events:none;position:absolute;top:0;transition:transform var(--controls-transition-duration);width:100%}.subtitles-container.shifted.s-a{transform:translateY(calc(var(--controls-height)*-1))}.subtitles-container.preview-track-active.s-a{transform:translateY(calc(var(--preview-track-height)*-1))}.preview-track-active.s-a .subtitles-caption:where(.s-a){bottom:var(--preview-track-controls-top-offset)}.subtitles-caption.s-a{bottom:4%;display:flex;justify-content:center;left:4%;position:absolute;right:4%}.subtitles-caption.mobile.s-a{bottom:8%}.subtitles-container.auto.s-a .subtitles-caption:where(.s-a){left:var(--subtitles-caption-margin);right:var(--subtitles-caption-margin)}.caption.s-a{background:rgba(0,0,0,.4);border-radius:4px;display:block;overflow-wrap:normal;padding:4px 8px}.subtitles-container.auto.s-a .caption:where(.s-a){width:100%}.caption-line.s-a{display:block;text-align:center}.subtitles-container.auto.s-a .caption-line:where(.s-a){text-align:left}.caption-segment.s-a{color:var(--white);display:inline-block;font-size:13px;line-height:1.2;white-space:pre-wrap}"};function al(i,e){B(e,!0),Q(i,Yw);let[t,o]=De(),r=()=>w(v,"$currentSubtitle$",t),a=()=>w(y,"$isLive$",t),l=()=>w(_,"$isFullscreen",t),d=()=>w(x,"$previewTrackActive",t),s=()=>w(b,"$isAutoSubtitleCaptionVisible$",t),u=h(e,"isMobile",3,!1),m=be(),p=Ot(),v=m.state.currentSubtitle$,b=m.state.isAutoSubtitleCaptionVisible$,y=m.state.isLive$,_=m.ui.isFullscreen,x=m.ui.previewTrackActive,I=f(()=>!!r().isAuto),T=f(()=>!!a()),R=f(()=>e.playerSize.width*.02),A=f(()=>u()&&!l()||n(R)<=p.minSubtitlesFontSize?p.minSubtitlesFontSize:n(R)),P=q(null);Oe(()=>{var Z,re,J;(Z=n(P))==null||Z.setIsAuto(n(I)),(re=n(P))==null||re.setIsLive(n(T)),(J=n(P))==null||J.setCaptions(e.captions)});let E=q(ui([[]]));Dt(()=>{N(P,new Sp().subscribe(),!0);let Z=n(P).captionsPrepared$.subscribe(re=>{N(E,re,!0)});return()=>{var re;(re=n(P))==null||re.destroy(),Z.unsubscribe()}}),Dt(()=>{if(n(I)){let Z=window.setTimeout(()=>{b.set(!1)},p.autoSubtitlesTimeout);return()=>{window.clearTimeout(Z)}}else b.set(!1)});let z=f(()=>e.playerSize.width<400?10:e.playerSize.width<550?14:24);var F=Gw();let U;var X=C(F);{var ae=Z=>{var re=Qw();let J;var we=C(re),me=C(we);{var ee=Ce=>{var ge=Ww(),pe=C(ge),Qe=C(pe,!0);S(pe),S(ge),O(G=>{var D;qe(pe,`font-size: ${(D=n(A))!=null?D:""}px`),ve(Qe,G)},[()=>j("subtitles_auto_caption")]),$(Ce,ge)},_e=(Ce,ge)=>{{var pe=G=>{var D=Me(),Ge=ue(D);yi(Ge,17,()=>n(E),Fd,(K,se)=>{var xe=Kw(),He=C(xe);yi(He,21,()=>n(se),({value:it,timeAppeared:ne})=>ne,(it,ne)=>{let ce=()=>n(ne).value,Ne=()=>n(ne).timeAppeared;var Le=Me(),et=ue(Le);{var Ee=Te=>{var Fe=_s();O(()=>ve(Fe,ce())),$(Te,Fe)};V(et,Te=>{(!Ne()||Ne()<=e.position)&&Te(Ee)})}$(it,Le)}),S(He),S(xe),O(()=>{var it;return qe(He,`font-size: ${(it=n(A))!=null?it:""}px`)}),$(K,xe)}),$(G,D)},Qe=G=>{var D=Me(),Ge=ue(D);yi(Ge,17,()=>e.captions,({value:K})=>K,(K,se)=>{let xe=()=>n(se).value;var He=qw(),it=C(He),ne=C(it,!0);S(it),S(He),O(()=>{var ce;qe(it,`font-size: ${(ce=n(A))!=null?ce:""}px`),ve(ne,xe())}),$(K,He)}),$(G,D)};V(Ce,G=>{var D;n(I)&&((D=n(E))!=null&&D.length)?G(pe):G(Qe,!1)},ge)}};V(me,Ce=>{n(I)&&s()?Ce(ee):Ce(_e,!1)})}S(we),S(re),O(Ce=>{var ge;J=oe(re,1,"subtitles-caption s-a",null,J,Ce),qe(re,`--subtitles-caption-margin: ${(ge=n(z))!=null?ge:""}%`)},[()=>({mobile:u()})]),$(Z,re)};V(X,Z=>{var re;(e.captions.length||(re=n(E))!=null&&re.length)&&Z(ae)})}S(F),O(Z=>U=oe(F,1,"subtitles-container s-a",null,U,Z),[()=>({shifted:e.shifted,"preview-track-active":d(),auto:n(I)&&!n(T)&&!s()})]),$(i,F),H(),o()}var t$=require("@vkontakte/videoplayer-core/es2015");var jw=L('<div class="text s-l"> </div>'),Xw=L('<div><div class="icon_wrapper s-l"><!></div> <!></div>'),Zw={hash:"s-l",code:".wrapper.s-l{align-items:center;background-position:50%;background-repeat:no-repeat;background-size:contain;display:flex;flex-direction:column;font-size:16px;height:100%;justify-content:center}.wrapper.bgCover.s-l{background-size:cover}.icon_wrapper.s-l{align-items:center;display:flex;flex-direction:column;width:400px}.text.s-l{margin-top:20px}"};function Mc(i,e){B(e,!0),Q(i,Zw);let t=h(e,"chromecastDeviceName",3,"chromecastDeviceName"),o=Ot();var r=Xw();let a;r.__contextmenu=function(...m){var p;(p=e.onContextMenu)==null||p.apply(this,m)},r.__click=function(...m){var p;(p=e.onClick)==null||p.apply(this,m)},r.__dblclick=function(...m){var p;(p=e.onDblClick)==null||p.apply(this,m)};var l=C(r),d=C(l);gc(d,{get size(){return"48"},get iconState(){return t$.ChromecastState.CONNECTED}}),S(l);var s=k(l,2);{var u=m=>{var p=jw(),v=C(p);S(p),O(()=>{var b;return ve(v,`Видео воспроизводится на ${(b=t())!=null?b:""}`)}),$(m,p)};V(s,m=>{t()&&m(u)})}S(r),O(m=>{a=oe(r,1,"wrapper s-l",null,a,m),qe(r,`background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('${e.thumbUrl||""}')`)},[()=>({bgCover:o.features.previewNoEmptySpace})]),$(i,r),H()}Ye(["contextmenu","click","dblclick"]);var Jw=Ie('<path d="M460 194a4 4 0 0 1 4-4h122a4 4 0 0 1 4 4v82a4 4 0 0 1-4 4H464a4 4 0 0 1-4-4zm6 3a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm112-72a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm-71-37a6 6 0 1 0 0-12 6 6 0 0 0 0 12m36 0a6 6 0 1 0 0-12 6 6 0 0 0 0 12m-18.05 15c6.05 0 11.62 4.45 11.94 4.65 2.11 1.35 3.26.77 3.96.16s1.15-2.81-1.04-4.66c-1.74-1.48-5.8-5.16-14.86-5.15s-12.95 3.5-14.8 5.18c-1.83 1.69-2.28 3.5-.96 4.66s2.31 1.16 4.35-.33c0 .01 5.36-4.51 11.41-4.51"></path>');function kv(i){Ze(i,{width:"200",height:"200",viewBox:"460 190 130 90",testId:"error-icon",children:(e,t)=>{var o=Jw();$(e,o)},$$slots:{default:!0}})}var eS=L('<div class="container s-4"><!></div>'),tS={hash:"s-4",code:".container.s-4{align-items:center;background:#000;bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0}"};function ll(i){Q(i,tS);var e=eS(),t=C(e);kv(t,{}),S(e),$(i,e)}var iS=L('<div class="playButton s-d" tabindex="0" role="button"><div class="playButtonBackground s-d"></div> <!></div>'),oS=L('<div data-testid="unstarted-thumb"><!></div>'),nS={hash:"s-d",code:".container.s-d{background-position:50%;background-repeat:no-repeat;background-size:contain;bottom:0;cursor:pointer;left:0;position:absolute;right:0;top:0;transition:opacity .2s,visibility .2s;will-change:opacity}.container.hidden.s-d{opacity:0;visibility:hidden}.container.bgCover.s-d{background-size:cover}.playButton.s-d{align-items:center;display:flex;height:var(--big-play-size);justify-content:center;margin:auto;width:var(--big-play-size)}.playButton.s-d,.playButtonBackground.s-d{bottom:0;left:0;position:absolute;right:0;top:0}.playButtonBackground.s-d{background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);transition:background .2s,transform .2s;transition-timing-function:ease-out;will-change:background,transform}.container.s-d:hover .playButtonBackground:where(.s-d){background-color:var(--big-play-hover-bg-color);transform:scale(1.15)}.playButton.s-d svg{position:relative}"};function dl(i,e){B(e,!0),Q(i,nS);let t=h(e,"iconVisible",3,!0),o=be(),r=Ot(),a=o.ui.startedByKeyboard$,l=j("tooltip_play"),d=b=>{var _;let y=b.code;["Enter","Space"].includes(y)&&(b.stopPropagation(),b.preventDefault(),a.set(!0),(_=e.startVideo)==null||_.call(e))},s=b=>{var y,_;b.stopPropagation(),(y=e.startVideo)==null||y.call(e),(_=e.onClick)==null||_.call(e,b)};var u=oS();let m;u.__click=s,u.__contextmenu=function(...b){var y;(y=e.onContextMenu)==null||y.apply(this,b)};var p=C(u);{var v=b=>{var y=iS();y.__keydown=d;var _=k(C(y),2);Dn(_,{get size(){return"48"}}),S(y),O(()=>Re(y,"aria-label",l)),$(b,y)};V(p,b=>{t()&&b(v)})}return S(u),O(b=>{m=oe(u,1,"container s-d",null,m,b),qe(u,`background-color: #222; background-image: url('${e.thumbUrl||""}')`)},[()=>({hidden:e.hidden,bgCover:r.features.previewNoEmptySpace})]),$(i,u),H({handlePressKey:d,handleClick:s})}Ye(["click","contextmenu","keydown"]);var rS=L('<span class="text s-x"> </span>'),sS=(i,e)=>{var t;return(t=e.onTitleClicked)==null?void 0:t.call(e)},aS=L('<a target="_blank" class="link s-x"><!></a>'),lS=(i,e)=>e.onTitleClicked(),dS=L("<button><!></button>"),cS=L('<div data-testid="video_title"><!></div>'),uS={hash:"s-x",code:".title.s-x{background:linear-gradient(0deg,transparent,rgba(0,0,0,.02) 19%,rgba(0,0,0,.1) 34%,rgba(0,0,0,.4) 60%,rgba(0,0,0,.6));box-sizing:border-box;font-size:15px;height:var(--controls-gradient-height);left:0;overflow:hidden;padding:18px 20px 10px;pointer-events:none;position:absolute;text-overflow:ellipsis;top:0;transition-duration:var(--controls-transition-duration);transition-property:visibility,transform,opacity;transition-timing-function:var(--controls-transition-fn);white-space:nowrap;width:100%;will-change:transform,opacity;z-index:var(--controls-container-z-index)}.link.s-x,.title.s-x{color:var(--white)}.link.s-x{pointer-events:auto;text-decoration:none}.link.s-x:hover{text-decoration:underline}.text.s-x{pointer-events:auto}.size-sm.s-x{font-size:14px;font-weight:500;line-height:18px}.hidden.s-x{opacity:0;transform:translateY(calc(var(--controls-gradient-height)*-1));visibility:hidden}"};function Av(i,e){B(e,!0),Q(i,uS);let t=b=>{var y=rS(),_=C(y,!0);S(y),Xe(y,x=>l(x),()=>l()),O(()=>ve(_,o())),ut("mouseenter",y,function(...x){var I;(I=e.onMouseEnter)==null||I.apply(this,x)}),ut("mouseleave",y,function(...x){var I;(I=e.onMouseLeave)==null||I.apply(this,x)}),$(b,y)},o=h(e,"title",3,""),r=h(e,"isHidden",3,!1),a=h(e,"size",3,"md"),l=h(e,"ref",15),d=q(void 0);Dt(()=>{var y;requestAnimationFrame(()=>{var _;(_=e.onVisibilityChanged)==null||_.call(e,!0)});function b(_){var x;_.propertyName==="transform"&&((x=e.onVisibilityChanged)==null||x.call(e,!r()))}return(y=n(d))==null||y.addEventListener("transitionend",b),()=>{var _;return(_=n(d))==null?void 0:_.removeEventListener("transitionend",b)}});var s=cS();let u;var m=C(s);{var p=b=>{var y=aS();y.__click=[sS,e];var _=C(y);t(_),S(y),O(()=>Re(y,"href",e.titleLinkHref)),$(b,y)},v=(b,y)=>{{var _=I=>{var T=dS();T.__click=[lS,e];var R=C(T);t(R),S(T),$(I,T)},x=I=>{t(I)};V(b,I=>{e.onTitleClicked?I(_):I(x,!1)},y)}};V(m,b=>{e.titleLinkHref?b(p):b(v,!1)})}S(s),Xe(s,b=>N(d,b),()=>n(d)),O(b=>u=oe(s,1,`title size-${a()}`,"s-x",u,b),[()=>({hidden:r()})]),$(i,s),H()}Ye(["click"]);var i$=require("@vkontakte/videoplayer-shared/es2015");var pS=L('<div class="timer__cell cell s-1a"><span class="cell__value s-1a"> </span> <span class="cell__unit s-1a"> </span></div> <span class="timer__points s-1a"> </span>',1),fS=L('<div class="timer__cell cell s-1a"><span class="cell__value s-1a"> </span> <span class="cell__unit s-1a"> </span></div> <span class="timer__points s-1a"> </span>',1),mS=L('<div class="timer__cell cell s-1a"><span class="cell__value s-1a"> </span> <span class="cell__unit s-1a"> </span></div> <span class="timer__points s-1a"> </span>',1),vS=L('<div class="timer__cell cell s-1a"><span class="cell__value s-1a"> </span> <span class="cell__unit s-1a"> </span></div>'),gS=L("<div><!> <!> <!> <!></div>"),hS={hash:"s-1a",code:".timer__container.s-1a{align-items:flex-start;display:flex;justify-content:center}.cell.s-1a{align-items:center;display:flex;flex-direction:column}.cell__value.s-1a{font-size:48px;font-weight:600;line-height:1.2}.small.s-1a .cell__value:where(.s-1a){font-size:24px}.cell__unit.s-1a{font-size:14px;font-weight:400;line-height:1.2}.small.s-1a .cell__unit:where(.s-1a){font-size:12px}.timer__points.s-1a{display:inline-block;font-size:42px;font-weight:600;line-height:1.2;margin:0 8px}.small.s-1a .timer__points:where(.s-1a){font-size:20px}"};function Lv(i,e){B(e,!0),Q(i,hS);let t=q(""),o=q(""),r=q(""),a=q(""),l,d=32,s=d/2,u=F=>String(F).padStart(2,"0"),m=F=>Math.max(F.length,1),p=F=>`${(e.isSmallSize?s:d)*m(F)}px`,v=F=>{let U=Math.floor(F/86400);U&&(F-=U*86400,N(t,u(U),!0));let X=Math.floor(F/3600);N(o,u(X),!0);let ae=Math.floor(F/60)%60;N(r,u(ae),!0);let Z=F%60;N(a,u(Z),!0)},b=()=>{let F=Math.floor(Date.now()/1e3),U=e.startTime-F;v(U),U>=1?l=requestAnimationFrame(b):e.onTimerOver()};Dt(()=>{l=requestAnimationFrame(b)}),pn(()=>{cancelAnimationFrame(l)});var y=gS();let _;var x=C(y);{var I=F=>{var U=pS(),X=ue(U);let ae;var Z=C(X),re=C(Z,!0);S(Z);var J=k(Z,2),we=C(J,!0);S(J),S(X);var me=k(X,2),ee=C(me,!0);S(me),O((_e,Ce,ge)=>{ae=qe(X,"",ae,{width:_e}),ve(re,n(t)),ve(we,Ce),ve(ee,ge)},[()=>p(n(t)),()=>j("waiting_live_day_value"),()=>j("waiting_live_colon")]),$(F,U)};V(x,F=>{n(t)&&F(I)})}var T=k(x,2);{var R=F=>{var U=fS(),X=ue(U);let ae;var Z=C(X),re=C(Z,!0);S(Z);var J=k(Z,2),we=C(J,!0);S(J),S(X);var me=k(X,2),ee=C(me,!0);S(me),O((_e,Ce,ge)=>{ae=qe(X,"",ae,{width:_e}),ve(re,n(o)),ve(we,Ce),ve(ee,ge)},[()=>p(n(o)),()=>j("waiting_live_hour_value"),()=>j("waiting_live_colon")]),$(F,U)};V(T,F=>{n(o)&&F(R)})}var A=k(T,2);{var P=F=>{var U=mS(),X=ue(U);let ae;var Z=C(X),re=C(Z,!0);S(Z);var J=k(Z,2),we=C(J,!0);S(J),S(X);var me=k(X,2),ee=C(me,!0);S(me),O((_e,Ce,ge)=>{ae=qe(X,"",ae,{width:_e}),ve(re,n(r)),ve(we,Ce),ve(ee,ge)},[()=>p(n(r)),()=>j("waiting_live_minute_value"),()=>j("waiting_live_colon")]),$(F,U)};V(A,F=>{n(r)&&F(P)})}var E=k(A,2);{var z=F=>{var U=vS();let X;var ae=C(U),Z=C(ae,!0);S(ae);var re=k(ae,2),J=C(re,!0);S(re),S(U),O((we,me)=>{X=qe(U,"",X,{width:we}),ve(Z,n(a)),ve(J,me)},[()=>p(n(a)),()=>j("waiting_live_second_value")]),$(F,U)};V(E,F=>{n(a)&&F(z)})}S(y),O(F=>_=oe(y,1,"timer__container s-1a",null,_,F),[()=>({small:e.isSmallSize})]),$(i,y),H()}var _S=L('<div class="waiting s-s"><span> </span></div>'),bS=L('<div class="upcoming-timer timer s-s"><span> </span> <!></div>'),$S=L('<div class="waiting-container s-s"><!></div>'),yS={hash:"s-s",code:'.waiting-container.s-s{background-color:var(--black);background-position:50%;background-repeat:no-repeat;background-size:cover;white-space:nowrap}.waiting-container.s-s,.waiting-container.s-s:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-s:before{backdrop-filter:blur(15px);background-color:rgba(0,0,0,.56);content:"";z-index:1}.waiting.s-s{align-items:center;display:flex;flex-direction:column;justify-content:center;left:0;position:absolute;top:50%;transform:translateY(-50%);width:100%;z-index:2}.waiting__title.s-s{font-size:20px;font-weight:600;line-height:1.2}.upcoming-timer.s-s{left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:2}.timer.s-s{align-items:center;display:flex;flex-direction:column;justify-content:center}.timer__title.s-s{display:inline-block;font-size:20px;font-weight:600;line-height:1.2;margin-bottom:12px;vertical-align:middle}.small.s-s{font-size:15px}.medium.s-s{font-size:17px}'};function Vc(i,e){B(e,!0),Q(i,yS);let t=h(e,"startTime",3,0),o=f(()=>t()<Math.floor(Date.now()/1e3)),r=q(void 0),a=q(void 0),l=0,d=q(void 0),s=q(void 0),u=f(()=>{var x,I;return((x=n(d))!=null?x:1/0)<=509||((I=n(s))!=null?I:1/0)<=320}),m=f(()=>{var x,I;return!n(u)&&(((x=n(d))!=null?x:1/0)<=699||((I=n(s))!=null?I:1/0)<=599)}),p=e.onUpcomingLiveViewStateChanged?(0,i$.throttleFn)(()=>{cancelAnimationFrame(l),l=requestAnimationFrame(()=>{let x={type:n(o)?"expired":"default",size:n(u)?"s":n(m)?"m":"l"},I=n(o)?n(r):n(a);e.onUpcomingLiveViewStateChanged(x,I)})},300):void 0;Oe(()=>{n(s),n(d),n(o),p==null||p()}),pn(()=>{if(cancelAnimationFrame(l),p==null||p.cancel(),e.onUpcomingLiveViewStateChanged){let x={type:n(o)?"expired":"default",size:n(u)?"s":n(m)?"m":"l"};e.onUpcomingLiveViewStateChanged(x)}});var v=$S();v.__contextmenu=function(...x){var I;(I=e.onContextMenu)==null||I.apply(this,x)},v.__click=function(...x){var I;(I=e.onClick)==null||I.apply(this,x)};var b=C(v);{var y=x=>{var I=_S(),T=C(I);let R;var A=C(T,!0);S(T),S(I),Xe(I,P=>N(r,P),()=>n(r)),O((P,E)=>{R=oe(T,1,"waiting__title s-s",null,R,P),ve(A,E)},[()=>({medium:n(m),small:n(u)}),()=>j("waiting_live_upcoming_title")]),$(x,I)},_=x=>{var I=bS(),T=C(I);let R;var A=C(T,!0);S(T);var P=k(T,2);let E=f(()=>n(u)||n(m)),z=f(()=>t()||0);Lv(P,{get isSmallSize(){return n(E)},get startTime(){return n(z)},onTimerOver:()=>N(o,!0)}),S(I),Xe(I,F=>N(a,F),()=>n(a)),O((F,U)=>{R=oe(T,1,"timer__title s-s",null,R,F),ve(A,U)},[()=>({medium:n(m),small:n(u)}),()=>j("waiting_live_timer_title")]),$(x,I)};V(b,x=>{n(o)?x(y):x(_,!1)})}S(v),O(()=>qe(v,`background-image: url(${e.thumbUrl})`)),Rn(v,"clientWidth",x=>N(d,x)),Rn(v,"clientHeight",x=>N(s,x)),$(i,v),H()}Ye(["contextmenu","click"]);var xS=L('<div class="waiting-container s-p"><div class="waiting-caption s-p"><!> <p class="waiting-title s-p"> </p></div></div>'),wS={hash:"s-p",code:'.waiting-container.s-p{align-items:center;background-color:var(--black);background-position:50%;background-repeat:no-repeat;background-size:cover;display:flex;justify-content:center}.waiting-container.s-p,.waiting-container.s-p:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-p:before{backdrop-filter:blur(10px);background-color:rgba(0,0,0,.4);content:""}.waiting-caption.s-p{align-items:center;display:flex;flex-direction:column;position:relative}.waiting-title.s-p{font-size:20px;font-weight:400;line-height:1.2;margin:0;padding:20px;text-align:center}'};function cl(i,e){B(e,!0),Q(i,wS);let t=h(e,"thumbUrl",3,""),o={recover:j("waiting_live_recover_title"),record:j("waiting_record_title")},r=f(()=>o[e.kind]||"");var a=xS();a.__contextmenu=function(...m){var p;(p=e.onContextMenu)==null||p.apply(this,m)},a.__click=function(...m){var p;(p=e.onClick)==null||p.apply(this,m)};var l=C(a),d=C(l);Xa(d,{style:"position: static; transform: translate(0, 0)"});var s=k(d,2),u=C(s,!0);S(s),S(l),S(a),O(()=>{qe(a,`background-image: url('${t()}')`),ve(u,n(r))}),$(i,a),H()}Ye(["contextmenu","click"]);var SS=Ie('<path d="M6 10.2 3.5 7.7a.99.99 0 0 0-1.4 1.4l3.2 3.2a1 1 0 0 0 1.4 0l7.6-7.6a.99.99 0 0 0-1.4-1.4z"></path>');function Mv(i){Ze(i,{width:"16",height:"16",testId:"check-mark-icon",children:(e,t)=>{var o=SS();$(e,o)},$$slots:{default:!0}})}var CS=L('<div class="select-icon s-1x"><!></div>'),TS={hash:"s-1x",code:".select-icon.s-1x{margin-right:auto;opacity:.9;padding-right:12px;position:relative;top:3px}"};function Rc(i){Q(i,TS);var e=CS(),t=C(e);Mv(t,{}),S(e),$(i,e)}var IS=(i,e)=>{i.stopPropagation(),e.item.selectItem(e.item.value)},ES=(i,e)=>{Xl(i,()=>e.item.selectItem(e.item.value))},PS=L("<p> </p>"),kS=L('<p class="sublabel s-1u"> </p>'),AS=L('<li role="menuitem" tabindex="0"><!> <div><!> <!></div></li>'),LS={hash:"s-1u",code:".menu-item-value.s-1u{align-items:end;display:flex;flex-direction:column;min-width:0}.menu-item-value[data-selected=false].s-1u{--select-icon-width:16px;--icon-padding:12px;margin-left:calc(var(--icon-padding) + var(--select-icon-width))}.label.s-1u,.sublabel.s-1u{max-width:100%;overflow:hidden;text-overflow:ellipsis}.sublabel.s-1u{opacity:.5}"};function Vv(i,e){B(e,!0),Q(i,LS);let t=h(e,"isMobile",3,!1);var o=AS();let r;o.__click=[IS,e],o.__keydown=[ES,e];var a=C(o);{var l=y=>{Rc(y,{})};V(a,y=>{e.item.selected&&y(l)})}var d=k(a,2);let s;var u=C(d);{var m=y=>{var _=Me(),x=ue(_);Di(x,()=>e.item.valueComponent,(I,T)=>{T(I,rs(()=>{var R;return(R=e.item.valueComponentParams)!=null?R:{}}))}),$(y,_)},p=y=>{var _=PS();let x;var I=C(_,!0);S(_),O(T=>{var R;x=oe(_,1,"label s-1u",null,x,T),ve(I,(R=e.item.label)!=null?R:e.item.value)},[()=>({mobile:t()})]),$(y,_)};V(u,y=>{e.item.valueComponent?y(m):y(p,!1)})}var v=k(u,2);{var b=y=>{var _=kS(),x=C(_,!0);S(_),O(()=>ve(x,e.item.sublabel)),$(y,_)};V(v,y=>{e.item.sublabel&&y(b)})}S(d),S(o),O((y,_,x)=>{var I;r=oe(o,1,"item",null,r,y),Re(o,"data-value",(I=e.item.dataValue)!=null?I:e.item.value),Re(o,"aria-label",_),Re(o,"data-testid",e.item.dataTestid),s=oe(d,1,"menu-item-value s-1u",null,s,x),Re(d,"data-selected",e.item.selected)},[()=>({mobile:t()}),()=>{var y,_;return(_=(y=e.item.ariaLabel)!=null?y:e.item.label)!=null?_:e.item.value.toString()},()=>({"submenu-value-mobile":t()})]),$(i,o),H()}Ye(["click","keydown"]);var MS=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><!> <div><!></div></li>');function Rv(i,e){B(e,!0);let t=h(e,"isMobile",3,!1),o=h(e,"refMenuItems",15),r=f(()=>()=>e.openSubMenuList(e.item.children)),a=f(()=>_=>ip(_,n(r)));var l=MS();let d;l.__click=function(..._){var x;(x=n(r))==null||x.apply(this,_)},l.__keydown=function(..._){var x;(x=n(a))==null||x.apply(this,_)};var s=C(l);{var u=_=>{Rc(_,{})};V(s,_=>{e.item.selected&&_(u)})}var m=k(s,2);let p;var v=C(m);{var b=_=>{var x=Me();let I=f(()=>e.item.valueComponent);var T=ue(x);Di(T,()=>n(I),(R,A)=>{A(R,rs(()=>{var P;return(P=e.item.valueComponentParams)!=null?P:{}}))}),$(_,x)},y=_=>{var x=_s();O(()=>ve(x,e.item.label)),$(_,x)};V(v,_=>{e.item.valueComponent?_(b):_(y,!1)})}S(m),S(l),Xe(l,_=>o(o()[e.item.id]=_,!0),()=>{var _;return(_=o())==null?void 0:_[e.item.id]}),O((_,x)=>{var I;d=oe(l,1,"item",null,d,_),Re(l,"aria-label",(I=e.item.ariaLabel)!=null?I:e.item.label),Re(l,"data-testid",e.item.id),p=oe(m,1,"menu-item-value",null,p,x)},[()=>({mobile:t(),bottomBordered:e.item.bottomBordered}),()=>({"submenu-value-mobile":t()})]),$(i,l),H()}Ye(["click","keydown"]);var ds={"quality-settings":100,"audio-language-settings":200,"playback-rate-settings":300,"subtitles-settings":400,"traffic-saving-settings":500,download:600,report:700,"copy-data":800,"save-trace-info":900,"debug-info":1e3};var RS=(i,e)=>{gb(i,e.returnFromSubMenu,e.closeSettingsMenu)},NS=(i,e)=>{i.stopPropagation(),e.returnFromSubMenu()},DS=(i,e)=>{rc(i)&&(Dr(i),e.returnFromSubMenu())},OS=L('<div><ul role="menu"><li role="menuitem" tabindex="0" data-testid="return-to-settings-menu"><!> <p class="title s-1j"> </p></li> <!></ul></div>'),BS={hash:"s-1j",code:".sub-menu.s-1j{--item-padding-vertical-mobile:16px;--item-padding-vertical:7px;--item-label-line-height:18px;--edge-item-padding-vertical-mobile:calc(6px + var(--item-padding-vertical-mobile));--edge-item-padding-vertical:calc(8px + var(--item-padding-vertical))}.sub-menu.s-1j .item.mobile{font-size:14px;line-height:var(--item-label-line-height);padding:var(--item-padding-vertical-mobile) 17px}.sub-menu.s-1j{padding-top:calc(var(--edge-item-padding-vertical) + var(--item-padding-vertical) + var(--item-label-line-height))}.sub-menu.mobile.s-1j{padding-top:calc(var(--edge-item-padding-vertical-mobile) + var(--item-padding-vertical-mobile) + var(--item-label-line-height) + 1px)}.sub-menu.s-1j .items:where(.s-1j) .item.header:where(.s-1j){border-bottom:var(--divider-border);display:flex;justify-content:space-between;left:0;min-width:max-content;position:absolute;right:0;top:0}.header.s-1j .title:where(.s-1j){margin-left:8px}.sub-menu.s-1j .item{padding:var(--item-padding-vertical) 12px;padding-right:22px}.items.s-1j .item:first-child:not(.mobile){padding-top:var(--edge-item-padding-vertical)}.items.s-1j .item:last-child:not(.mobile){padding-bottom:var(--edge-item-padding-vertical)}.items.s-1j .item.mobile:first-child{padding-top:var(--edge-item-padding-vertical-mobile)}.items.s-1j .item.mobile:last-child{padding-bottom:var(--edge-item-padding-vertical-mobile)}.sub-menu.s-1j .item.bottomBordered{border-bottom:var(--divider-border)}.sub-menu.s-1j .item .sublabel{font-size:12px;line-height:14px}.item.s-1j:not(.mobile) p:where(.s-1j),.sub-menu.s-1j .item:not(.mobile) .label{font-size:13px;line-height:var(--item-label-line-height)}"};function Dv(i,e){B(e,!0),Q(i,BS);let[t,o]=De(),r=()=>w(p,"$isFullscreen",t),a=()=>w(v,"$playerSize",t),l=h(e,"isMobile",3,!1),d=h(e,"playerControlsHeight",3,0),s=h(e,"ariaLabelReturnFromSubMenu",19,()=>j("aria_label_submenu_back")),u=h(e,"listRef",15);Dt(()=>{let Z=e.items.findIndex(re=>re.selected);u().children[Z+1].focus()});let m=be(),p=m.ui.isFullscreen,v=m.ui.playerSize,b=q(void 0),y=q(0),_=q(0),x=f(()=>l()&&r()?`max-height: ${Math.round(a().height*.6)}px`:l()?"":`max-height: ${a().height-32-n(_)-d()}px; overflow: auto;`),I=f(()=>Math.max(e.minWidth,n(y)));var T=OS();let R;var A=C(T);let P;A.__keydown=[RS,e];var E=C(A);let z;E.__click=[NS,e],E.__keydown=[DS,e];var F=C(E);Nr(F,{direction:"left"});var U=k(F,2),X=C(U,!0);S(U),S(E),Xe(E,Z=>N(b,Z),()=>n(b));var ae=k(E,2);yi(ae,17,()=>e.items,Fd,(Z,re)=>{var J=Me(),we=ue(J);{var me=_e=>{Vv(_e,{get item(){return n(re)},get isMobile(){return l()}})},ee=(_e,Ce)=>{{var ge=pe=>{Rv(pe,{get isMobile(){return l()},get item(){return n(re)},get openSubMenuList(){return e.openSubMenuList},get refMenuItems(){return e.refMenuItems}})};V(_e,pe=>{n(re).type==="OPEN_SUB_MENU"&&pe(ge)},Ce)}};V(we,_e=>{n(re).type==="SELECT_VALUE"?_e(me):_e(ee,!1)})}$(Z,J)}),S(A),Xe(A,Z=>u(Z),()=>u()),S(T),O((Z,re,J)=>{R=oe(T,1,"sub-menu menu s-1j",null,R,Z),Re(T,"data-testid",`${e.id}-sub-menu`),qe(T,`min-width: ${n(I)}px`),P=oe(A,1,"items s-1j",null,P,re),qe(A,n(x)),z=oe(E,1,"item header back s-1j",null,z,J),Re(E,"aria-label",s()),ve(X,e.title)},[()=>({desktop:!l(),mobile:l()}),()=>({mobile:l()}),()=>({mobile:l()})]),Rn(E,"clientWidth",Z=>N(y,Z)),Rn(E,"clientHeight",Z=>N(_,Z)),$(i,T),H(),o()}Ye(["keydown","click"]);var n$=require("@vkontakte/videoplayer-shared/es2015");var HS=(i,e)=>ip(i,e()),FS=(i,e)=>{i.stopPropagation(),e()()},US=L('<div class="value s-1l"> </div>'),zS=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></li>'),WS={hash:"s-1l",code:".value.s-1l{opacity:.7;overflow:hidden;position:relative;text-overflow:ellipsis}"};function Ov(i,e){B(e,!0),Q(i,WS);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,n$.noop),r=h(e,"valueComponent",3,void 0),a=h(e,"iconProps",19,()=>({})),l=h(e,"ref",15);var d=zS();let s;d.__click=[FS,o],d.__keydown=[HS,o];var u=C(d),m=C(u);{var p=T=>{ol(T,{get icon(){return e.icon}})},v=T=>{var R=Me();let A=f(()=>e.icon);var P=ue(R);Di(P,()=>n(A),(E,z)=>{z(E,rs(a))}),$(T,R)};V(m,T=>{typeof e.icon=="string"?T(p):T(v,!1)})}S(u);var b=k(u,2),y=C(b,!0);S(b);var _=k(b,2);{var x=T=>{var R=Me();let A=f(r);var P=ue(R);Di(P,()=>n(A),(E,z)=>{z(E,{})}),$(T,R)},I=T=>{var R=US(),A=C(R,!0);S(R),O(()=>ve(A,e.value)),$(T,R)};V(_,T=>{r()?T(x):T(I,!1)})}S(d),Xe(d,T=>l(T),()=>l()),O(T=>{s=oe(d,1,"item",null,s,T),Re(d,"aria-label",e.ariaLabel),Re(d,"data-testid",e.id),ve(y,e.label)},[()=>({mobile:t()})]),$(i,d),H()}Ye(["click","keydown"]);var Bv=require("@vkontakte/videoplayer-shared/es2015");var KS=(i,e)=>{Xl(i,()=>e())},qS=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),QS=L('<img class="icon" aria-hidden="true"/>'),GS=L('<li role="menuitem" tabindex="0"><div class="icon-wrapper"><!></div> <div class="label s-1k"> </div></li>'),YS={hash:"s-1k",code:".label.s-1k{overflow:hidden;text-overflow:ellipsis}"};function Hv(i,e){B(e,!0),Q(i,YS);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,Bv.noop),r=h(e,"closeSettings",3,Bv.noop),a=q(!1),l=()=>{N(a,!0)},d=x=>{x==null||x.stopPropagation(),o()(),r()()};var s=GS();let u;s.__click=d,s.__keydown=[KS,d];var m=C(s),p=C(m);{var v=x=>{var I=Me(),T=ue(I);{var R=P=>{var E=qS();$(P,E)},A=P=>{var E=QS();O(()=>Re(E,"src",e.icon)),ut("error",E,l),Ba(E),$(P,E)};V(T,P=>{n(a)?P(R):P(A,!1)})}$(x,I)},b=x=>{var I=Me();let T=f(()=>e.icon);var R=ue(I);Di(R,()=>n(T),(A,P)=>{P(A,{})}),$(x,I)};V(p,x=>{typeof e.icon=="string"?x(v):x(b,!1)})}S(m);var y=k(m,2),_=C(y,!0);S(y),S(s),O(x=>{var I;u=oe(s,1,"item",null,u,x),Re(s,"aria-label",(I=e.ariaLabel)!=null?I:e.label),Re(s,"data-testid",e.id),ve(_,e.label)},[()=>({mobile:t()})]),$(i,s),H()}Ye(["click","keydown"]);var r$=require("@vkontakte/videoplayer-shared/es2015");var jS=L('<div class="toggle_wrap s-1q"><div></div> <div class="toggle-label s-1q"></div></div>'),XS={hash:"s-1q",code:'.toggle_wrap.s-1q{cursor:pointer;font-size:12px;line-height:15px;min-height:15px;padding:0;user-select:none}.toggle.s-1q{background-color:var(--toggle-color-separator);border-radius:45px;cursor:pointer;float:right;height:9px;margin-top:3px;width:28px}.toggle.s-1q:after{background-color:var(--toggle-color-off);border-radius:50%;content:"";float:left;height:15px;left:0;position:relative;top:-3px;transition:left .1s ease;width:15px}.toggle.on.s-1q:after{background-color:var(--toggle-color-on);left:13px}.toggle-label.s-1q{overflow:hidden}'};function Fv(i,e){Q(i,XS);let t=h(e,"enabled",3,!1);var o=jS(),r=C(o);let a;pi(2),S(o),O(l=>a=oe(r,1,"toggle s-1q",null,a,l),[()=>({on:t()})]),$(i,o)}var ZS=(i,e,t)=>{hb(i,e(),o=>t()(o))},JS=(i,e,t)=>{i.stopPropagation(),e()(!t())},eC=L('<div><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></div>'),tC=L('<li role="menuitem" tabindex="0"><!></li>');function Uv(i,e){B(e,!0);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,r$.noop),r=h(e,"enabled",3,!1),a=h(e,"tooltipText",3,void 0),l=h(e,"maxTooltipWidth",3,void 0);var d=tC();let s;d.__click=[JS,o,r],d.__keydown=[ZS,r,o];var u=C(d);Ja(u,{get content(){return a()},get isMobile(){return t()},placement:"left",translateX:10,isFullWidthWrapper:!0,get maxTooltipWidth(){return l()},children:(m,p)=>{var v=eC();let b;var y=C(v),_=C(y);{var x=P=>{ol(P,{get icon(){return e.icon}})},I=P=>{var E=Me();let z=f(()=>e.icon);var F=ue(E);Di(F,()=>n(z),(U,X)=>{X(U,{})}),$(P,E)};V(_,P=>{typeof e.icon=="string"?P(x):P(I,!1)})}S(y);var T=k(y,2),R=C(T,!0);S(T);var A=k(T,2);Fv(A,{get enabled(){return r()}}),S(v),O(P=>{b=oe(v,1,"switch-wrapper",null,b,P),ve(R,e.label)},[()=>({mobile:t()})]),$(m,v)},$$slots:{default:!0}}),S(d),O(m=>{var p;s=oe(d,1,"item switch-item",null,s,m),Re(d,"aria-label",(p=e.ariaLabel)!=null?p:e.label),Re(d,"data-testid",e.id)},[()=>({mobile:t()})]),$(i,d),H()}Ye(["click","keydown"]);var Dc=require("@vkontakte/videoplayer-shared/es2015");var s$=()=>{let i=q(ui([])),e=f(()=>(n(i).length?n(i).at(-1):null)||null);return{get current(){return n(e)},pushSubMenu:t=>{n(i).push(t)},popSubMenu:()=>{N(i,n(i).slice(0,-1),!0)},popAllSubMenus:()=>{N(i,[],!0)}}};var a$=require("@vkontakte/videoplayer-shared/es2015");var iC=L('<div class="quality-icon s-1p"><!></div>'),oC=L('<div class="quality-label s-1p"><span> </span> <!></div>'),nC={hash:"s-1p",code:".quality-label.s-1p{position:relative}.quality.s-1p{font-size:13px;line-height:18px}.quality.sub.s-1p{opacity:.7}.quality-icon.s-1p{display:flex;padding-left:2px;position:absolute;right:0;top:0;transform:translateX(100%)}.quality-icon.s-1p svg{color:var(--blue-light)}"};function ul(i,e){B(e,!0),Q(i,nC);let t=h(e,"isSubCase",3,!1),o=f(()=>e.quality?(0,a$.getVideoQualityLabel)(e.quality):""),r=f(()=>lp(e.quality));var a=oC(),l=C(a);let d;var s=C(l,!0);S(l);var u=k(l,2);{var m=p=>{var v=iC();let b=f(()=>n(r));var y=C(v);Di(y,()=>n(b),(_,x)=>{x(_,{})}),S(v),O(()=>Re(v,"data-testid",`${n(o)}-icon`)),$(p,v)};V(u,p=>{n(r)&&!e.isMobile&&p(m)})}S(a),O(p=>{d=oe(l,1,"s-1p",null,d,p),ve(s,e.label)},[()=>({sub:!t(),quality:!e.isMobile})]),$(i,a),H()}var u$=require("@vkontakte/videoplayer-shared/es2015");var zv=require("@vkontakte/videoplayer-core/es2015");var l$=({quality:i,availableQualities:e})=>{let t=e.find(o=>o.value===i);return t?t.displayValue:i},d$=({quality:i,availableQualities:e,isAutoQualityEnabled:t})=>{if(!i)return"...";let o=l$({quality:i,availableQualities:e});return t?i===zv.VideoQuality.INVARIANT?j("auto_quality_invariant"):j("auto_quality",{actual:o}):o},c$=({quality:i,availableQualities:e,prefix:t,onlyPrefix:o})=>i?o||i===zv.VideoQuality.INVARIANT?t:`${t}${l$({quality:i,availableQualities:e})}`:"...";var rC=L('<div class="menu-item-value-wrapper s-1t"><!></div>'),sC={hash:"s-1t",code:".menu-item-value-wrapper.s-1t{line-height:normal}"};function dd(i,e){B(e,!0),Q(i,sC);let[t,o]=De(),r=()=>w(s,"$currentQuality$",t),a=()=>w(u,"$availableQualities$",t),l=()=>w(m,"$isMobile$",t),d=be(),s=d.state.currentQuality$,u=d.state.availableQualities$,m=d.ui.isMobile,p=" · ",v=f(()=>e.prefix+(e.selected&&r()!==u$.VideoQuality.INVARIANT?p:"")),b=f(()=>c$({prefix:n(v),quality:r(),availableQualities:a(),onlyPrefix:!e.selected}));var y=rC(),_=C(y);let x=f(()=>e.selected?r():void 0);ul(_,{get quality(){return n(x)},get label(){return n(b)},get isMobile(){return l()},isSubCase:!0}),S(y),$(i,y),H(),o()}var aC=i=>{let e=i.join("|"),t="<(?<keyhtml>.*?)(?<propshtml> .*?)?>(?<childrenhtml>.*?)</\\k<keyhtml>>",o=`{(?<keyi18n>${e})}(?<childreni18n>.*?){/\\k<keyi18n>}`,r="<(?<keyhtmlself>.*?)(?<propshtmlself> .*?)?/?>",a=`{(?<keyi18nself>${e})}`;return new RegExp(`${t}|${o}|${r}|${a}`,"g")},lC={br:!0,span:!0},Wv=(i,e={})=>{var d,s,u,m,p,v,b;if(!i)return i;let t=ke(ke({},lC),e),o=Object.keys(t);if(!o.length)return i;let r=aC(o),a=[],l=0;for(let y of i.matchAll(r)){let _=y[0],x=((d=y.groups)==null?void 0:d.keyhtml)||((s=y.groups)==null?void 0:s.keyi18n)||((u=y.groups)==null?void 0:u.keyhtmlself)||((m=y.groups)==null?void 0:m.keyi18nself)||"",{index:I}=y;if(!t[x]){a.push(i.slice(l,I)),l=I+_.length;continue}let T=(p=y.groups)!=null&&p.childrenhtml?Wv(y.groups.childrenhtml,t):"",R=(v=y.groups)!=null&&v.childrenhtml?_.replace(new RegExp((b=y.groups)==null?void 0:b.childrenhtml),()=>T||""):_;a.push(i.slice(l,I),R),l=I+_.length}return l===0?i:(a.push(i.slice(l)),a.join(""))};function Nc(i,e){B(e,!1);let t=h(e,"message",8),o=Wv(t());$o();var r=Me(),a=ue(r);{var l=d=>{var s=Me(),u=ue(s);Ud(u,()=>o),$(d,s)};V(a,d=>{o&&d(l)})}$(i,r),H()}var dC=L('<p class="quality-applies sublabel s-1s"><!></p>'),cC={hash:"s-1s",code:".quality-applies.s-1s{color:hsla(0,0%,100%,.5);display:flex;justify-content:end;padding:3px 0}.quality-applies span{color:#70c1ff}"};function Kv(i,e){B(e,!1),Q(i,cC),$o();var t=dC(),o=C(t);let r=kn(()=>j("quality_applience",{action:`<span>${j("quality_applience_action")}</span>`}));Nc(o,{get message(){return n(r)}}),S(t),$(i,t),H()}var f$=({isAutoQualityEnabled:i,trafficSavingEnabled:e,highQualityEnabled:t})=>{let o=!i&&!e&&!t;return{id:"quality-other-settings",type:"OPEN_SUB_MENU",label:j("other_quality"),selected:o,valueComponent:dd,valueComponentParams:{prefix:j("other_quality"),selected:o},children:"quality-other-settings"}},qv=({appliesTo:i,labelWithQuality:e,selected:t},{selectQuality:o})=>({id:"quality-auto",type:"SELECT_VALUE",value:"auto",label:j("auto_quality_limit"),valueComponent:e?dd:void 0,valueComponentParams:{prefix:j("auto_quality_limit"),selected:t},selectItem:()=>o("auto",i),selected:t}),m$=()=>({id:"quality-appliance-settings",type:"OPEN_SUB_MENU",valueComponent:Kv,bottomBordered:!0,children:"quality-appliance"}),Qv=({labelWithQuality:i,appliesTo:e,selected:t},{toggleHighQuality:o})=>({id:"quality-high",type:"SELECT_VALUE",value:"high_quality",selectItem:()=>o(!0,e),selected:t,label:j("high_quality"),valueComponent:i?dd:void 0,valueComponentParams:{prefix:j("high_quality"),selected:t},sublabel:j("high_quality_description")}),Gv=({labelWithQuality:i,appliesTo:e,selected:t},{toggleTrafficSaving:o})=>({id:"quality-traffic-saving",type:"SELECT_VALUE",value:"save_traffic",selectItem:()=>o(!0,e),selected:t,label:j("traffic_saving_quality"),valueComponent:i?dd:void 0,valueComponentParams:{prefix:j("traffic_saving_quality"),selected:t},sublabel:j("traffic_saving_quality_description")});var Cp=(i,e)=>String(e.findIndex(t=>t.id===i.id)+1),Tp=(i,e)=>{var l;if(!i)return"";let{language:t,label:o}=i,r;if(t==="und"?r=void 0:t&&(r=(l=bc(t))!=null?l:t),o&&t&&r){let d=e.filter(s=>s.label===o&&s.language===t);if(d.length===1)return j("audio_stream_display_language_label",{language:r,label:o});{let s=Cp(i,d);return j("audio_stream_display_language_label_index",{language:r,label:o,index:s})}}if(o){let d=e.filter(s=>s.label===o);if(d.length===1)return o;{let s=Cp(i,d);return j("audio_stream_display_label_index",{label:o,index:s})}}if(t&&r){let d=e.filter(s=>s.language===t);if(d.length===1)return r;{let s=Cp(i,d);return j("audio_stream_display_language_index",{language:r,index:s})}}let a=Cp(i,e);return j("audio_stream_display_unknown",{index:a})};var uC={"quality-settings":i=>{let{isAutoQualityEnabled:e,isAutoQualityAvailable:t,trafficSavingEnabled:o,highQualityEnabled:r}=i,a=[];return t&&a.push({handler:qv,selected:e&&!o&&!r||!1}),a.push({handler:Gv,selected:o},{handler:Qv,selected:r}),{title:j("submenu_quality"),id:"quality-settings",items:[m$(i),...a.map(({handler:l,selected:d})=>l({labelWithQuality:!0,appliesTo:"to-video",selected:d},i)),f$(i)]}},"quality-other-settings":({closeSettingsMenu:i,selectQuality:e,availableQualities:t,isMobile:o})=>({id:"quality-other-settings",title:j("submenu_quality"),closeSettingsMenu:i,items:t.map(r=>({type:"SELECT_VALUE",value:r.value,valueComponent:ul,valueComponentParams:{quality:r.value,label:r.displayValue,isMobile:o,isSubCase:!0},selectItem:a=>e(a,"to-video"),selected:r.selected,label:r.displayValue}))}),"quality-appliance":i=>{var t,o,r;let{closeSettingsMenu:e}=i;return{id:"quality-appliance",title:j("default_quality_for_any_video"),closeSettingsMenu:e,items:[{handler:qv,selected:((t=Ku())==null?void 0:t.type)==="auto_quality"},{handler:Gv,selected:((o=Ku())==null?void 0:o.type)==="traffic_saving"},{handler:Qv,selected:((r=Ku())==null?void 0:r.type)==="high_quality"}].map(({handler:a,selected:l})=>a({labelWithQuality:!1,appliesTo:"as-default",selected:l},i))}},"audio-tracks":({closeSettingsMenu:i,availableAudioStreams:e,currentAudioStream:t,selectAudioLanguage:o})=>({id:"audio-tracks",title:j("submenu_audio_languages"),closeSettingsMenu:i,items:e.map(r=>({type:"SELECT_VALUE",value:r,dataValue:r.id,selectItem:o,selected:r.id===(t==null?void 0:t.id),label:Tp(r,e)}))}),"playback-rate":({closeSettingsMenu:i,availablePlaybackRates:e,selectPlaybackRate:t})=>({id:"playback-rate",title:j("submenu_playback_rate"),closeSettingsMenu:i,items:e.map(o=>({type:"SELECT_VALUE",value:o.value,selectItem:t,selected:o.selected,label:o.displayValue}))}),subtitles:({availableSubtitlesList:i,selectSubtitle:e})=>({id:"subtitles",minWidth:164,title:j("subtitles_caption"),items:i.map(t=>({type:"SELECT_VALUE",value:t.value,selectItem:()=>e(t),selected:t.selected,label:t.displayValue,dataTestid:t.value===Bn?"sub_off":void 0}))})},v$=({subMenuId:i,context:e})=>i?[uC[i](e)]:[];var pC=Ie('<path d="M3.1 9.5c0-2.24 0-3.36.44-4.22A4 4 0 015.28 3.54C6.14 3.1 7.26 3.1 9.5 3.1h5c2.24 0 3.36 0 4.22.44a4 4 0 011.74 1.74c.44.86.44 1.98.44 4.22s0 3.36-.44 4.22a4 4 0 01-1.74 1.74c-.84.43-1.93.44-4.07.44l.55 2.2h1.9a.9.9 0 010 1.8H6.9a.9.9 0 110-1.8h1.9l.55-2.2c-2.14 0-3.23-.01-4.07-.44a4 4 0 01-1.74-1.74C3.1 12.86 3.1 11.74 3.1 9.5m11.4-4.6h-5c-1.15 0-1.9 0-2.48.05-.56.04-.79.12-.92.19a2.2 2.2 0 00-.96.96 2 2 0 00-.2.92C4.9 7.6 4.9 8.35 4.9 9.5s0 1.9.05 2.48c.04.56.12.79.19.92q.33.63.96.96c.13.07.36.15.92.2.58.04 1.33.04 2.48.04h5c1.15 0 1.9 0 2.48-.05.56-.04.79-.12.92-.19a2.2 2.2 0 00.96-.96c.07-.13.15-.36.2-.92.04-.58.04-1.33.04-2.48s0-1.9-.05-2.48a3 3 0 00-.19-.92 2.2 2.2 0 00-.96-.96 2 2 0 00-.92-.2c-.58-.04-1.33-.04-2.48-.04m-3.3 11-.55 2.2h2.7l-.55-2.2z"></path>');function Yv(i){Ze(i,{testId:"traffic-saving-icon",children:(e,t)=>{var o=pC();$(e,o)},$$slots:{default:!0}})}var fC=Ie('<path d="M8.3 14.25c1.86 1.9 5.5.02 5.5-3.55V5.64l2.4-.7A2.74 2.74 0 0 0 18 2.37V.64a.75.75 0 0 0-.92-.62l-.26.06C15.88.3 14.93.51 14 .8c-1.33.45-2.03 1.62-2.01 3.08V9c-3.89.2-5.64 3.29-3.7 5.25ZM.9.1a.9.9 0 0 0 0 1.8h8.2a.9.9 0 0 0 0-1.8H.9ZM.9 5.1a.9.9 0 1 0 0 1.8h7.2a.9.9 0 0 0 0-1.8H.9ZM0 11c0-.5.4-.9.9-.9h4.18a.9.9 0 1 1 0 1.8H.9A.9.9 0 0 1 0 11Z"></path>');function jv(i){Ze(i,{width:"18",height:"15",children:(e,t)=>{var o=fC();$(e,o)},$$slots:{default:!0}})}var mC=Ie('<path d="M11 4.07V2.05c-2.01.2-3.84 1-5.32 2.21L7.1 5.69A8 8 0 0 1 11 4.07M5.69 7.1 4.26 5.68A10 10 0 0 0 2.05 11h2.02a8 8 0 0 1 1.62-3.9M2.05 13c.2 2.01 1 3.84 2.21 5.32l1.43-1.43A8 8 0 0 1 4.07 13zM11 21.95v-2.02a8 8 0 0 1-3.9-1.62l-1.42 1.43A10 10 0 0 0 11 21.95M22 12c0 5.16-3.92 9.42-8.95 9.95v-2.02C16.97 19.41 20 16.05 20 12s-3.03-7.41-6.95-7.93V2.05C18.08 2.58 22 6.84 22 12M10.69 8.58l4.74 2.73a.8.8 0 0 1 0 1.37l-4.74 2.74a.8.8 0 0 1-1.19-.68V9.26a.8.8 0 0 1 1.19-.68"></path>');function Xv(i){Ze(i,{testId:"play-speed-icon",children:(e,t)=>{var o=mC();$(e,o)},$$slots:{default:!0}})}var vC=Ie('<path d="M12 2a.9.9 0 01.9.9v10.93l4.56-4.57a.9.9 0 011.28 1.28l-6.1 6.1a.9.9 0 01-1.28 0l-6.1-6.1a.9.9 0 111.28-1.28l4.56 4.57V2.9A.9.9 0 0112 2M4 20a.9.9 0 01.9-.9h14.2a.9.9 0 110 1.8H4.9A.9.9 0 014 20"></path>');function Zv(i){Ze(i,{testId:"download-icon",children:(e,t)=>{var o=vC();$(e,o)},$$slots:{default:!0}})}var gC=Ie('<path d="M8.86 2.1h6.28c.67 0 1.2.21 1.68.7l4.38 4.38c.48.48.7 1 .7 1.68v6.28c0 .68-.22 1.2-.7 1.68l-4.38 4.38c-.48.48-1 .7-1.68.7H8.86c-.68 0-1.2-.22-1.68-.7L2.8 16.82c-.48-.48-.7-1-.7-1.68V8.86c0-.68.22-1.2.7-1.68L7.18 2.8c.48-.49 1-.7 1.68-.7m-.44 2L4.1 8.43c-.18.18-.21.24-.21.5v6.17c0 .25.03.31.2.5l4.32 4.3c.18.18.24.21.5.21h6.17c.25 0 .31-.03.5-.2l4.3-4.32c.18-.18.21-.24.21-.5V8.92c0-.25-.03-.31-.2-.5l-4.32-4.3c-.18-.18-.24-.21-.5-.21H8.92c-.25 0-.32.03-.5.2M13 16a1 1 0 1 1-2 0 1 1 0 0 1 2 0m-.1-8.1a.9.9 0 0 0-1.8 0v5.2a.9.9 0 1 0 1.8 0z"></path>');function Jv(i){Ze(i,{testId:"report-icon",children:(e,t)=>{var o=gC();$(e,o)},$$slots:{default:!0}})}var hC=Ie('<path d="M4 12.3V12c0-1.47 0-2.55.08-3.4.07-.9.21-1.48.45-1.95a4.85 4.85 0 0 1 2.12-2.12 5.1 5.1 0 0 1 1.95-.45C9.5 4 10.68 4 12.3 4h4.51c-.03-.16-.09-.33-.17-.49a2.4 2.4 0 0 0-1.05-1.05c-.3-.16-.63-.21-.93-.24-.29-.02-.64-.02-1.03-.02h-1.37c-1.58 0-2.81 0-3.81.08a6.84 6.84 0 0 0-2.62.64 6.65 6.65 0 0 0-2.9 2.91c-.4.76-.57 1.6-.65 2.62-.08 1-.08 2.23-.08 3.81v1.37c0 .4 0 .74.02 1.03.03.3.08.62.24.93A2.4 2.4 0 0 0 4 16.8V12.3ZM10.08 6h-.03c-.53 0-.97 0-1.33.03-.39.03-.76.1-1.12.28a2.9 2.9 0 0 0-1.3 1.3c-.17.35-.24.72-.27 1.1C6 9.09 6 9.53 6 10.06v7.9c0 .53 0 .97.03 1.33.03.39.1.76.28 1.12a2.9 2.9 0 0 0 1.3 1.3c.35.17.72.24 1.1.27.37.03.81.03 1.33.03h6.91c.53 0 .97 0 1.33-.03.39-.03.76-.1 1.12-.28a2.9 2.9 0 0 0 1.3-1.3c.17-.35.24-.72.27-1.1.03-.37.03-.81.03-1.34v-7.9c0-.53 0-.97-.03-1.33-.03-.39-.1-.76-.28-1.12a2.9 2.9 0 0 0-1.3-1.3 2.96 2.96 0 0 0-1.1-.27C17.91 6 17.47 6 16.94 6h-6.87ZM8.41 7.92c.06-.04.18-.07.45-.1.28-.02.65-.02 1.22-.02h6.84c.57 0 .94 0 1.22.02.27.03.39.06.45.1.21.1.39.28.5.49.03.06.06.18.09.45.02.28.02.65.02 1.22v7.84c0 .57 0 .94-.02 1.22-.03.27-.06.39-.1.45-.1.21-.28.39-.49.5-.06.03-.18.06-.45.09-.28.02-.65.02-1.22.02h-6.84c-.57 0-.94 0-1.22-.02a1.23 1.23 0 0 1-.45-.1 1.1 1.1 0 0 1-.5-.49 1.23 1.23 0 0 1-.09-.45c-.02-.28-.02-.65-.02-1.22v-7.84c0-.57 0-.94.02-1.22.03-.27.06-.39.1-.45.1-.21.28-.39.49-.5Z"></path>');function Ip(i){Ze(i,{children:(e,t)=>{var o=hC();$(e,o)},$$slots:{default:!0}})}var _C=Ie('<path d="M12 20.1a8.1 8.1 0 1 0 0-16.2 8.1 8.1 0 0 0 0 16.2m0 1.9a10 10 0 1 1 0-20 10 10 0 0 1 0 20m0-12.37A1.32 1.32 0 1 1 12 7a1.32 1.32 0 0 1 0 2.63m-.95 2.82c0-.54.43-.98.95-.98s.95.44.95.98v3.83c0 .54-.43.98-.95.98a.96.96 0 0 1-.95-.98z"></path>');function eg(i){Ze(i,{testId:"info-icon",children:(e,t)=>{var o=_C();$(e,o)},$$slots:{default:!0}})}var bC=L('<div class="menu-item-value-wrapper s-1w"><!></div>'),$C={hash:"s-1w",code:".menu-item-value-wrapper.s-1w{line-height:normal}"};function tg(i,e){B(e,!0),Q(i,$C);let[t,o]=De(),r=()=>w(u,"$currentQuality$",t),a=()=>w(m,"$availableQualities$",t),l=()=>w(p,"$isAutoQualityEnabled$",t),d=()=>w(v,"$isMobile$",t),s=be(),u=s.state.currentQuality$,m=s.state.availableQualities$,p=s.state.isAutoQualityEnabled$,v=s.ui.isMobile,b=f(()=>d$({quality:r(),availableQualities:a(),isAutoQualityEnabled:l()}));var y=bC(),_=C(y);ul(_,{get quality(){return r()},get label(){return n(b)},get isMobile(){return d()}}),S(y),$(i,y),H(),o()}var xC={"quality-settings":({isAutoQualityEnabled:i,currentQuality:e,qualityDetailsSubMenuEnabled:t})=>{let o=(i?j("auto_quality_option"):e)||"";return{id:"quality-settings",type:"OPEN_SUB_MENU",ariaLabel:j("aria_label_menu_quality",{actual:o}),icon:cc,label:j("menu_quality"),value:e,valueComponent:tg,weight:ds["quality-settings"],children:t?"quality-settings":"quality-other-settings"}},"traffic-saving-switch":({trafficSavingEnabled:i,toggleTrafficSaving:e})=>({id:"traffic-saving-switch",weight:ds["traffic-saving-settings"],type:"SWITCH",onClick:t=>e(t,"to-video"),ariaLabel:j("aria_label_submenu_traffic_saving"),icon:Yv,label:j("menu_traffic_saving"),enabled:i,tooltipText:j("traffic_saving_helper_text"),maxTooltipWidth:175}),"audio-tracks-settings":({currentAudioStream:i,availableAudioStreams:e})=>{let t=Tp(i,e);return{id:"audio-tracks-settings",weight:ds["audio-language-settings"],type:"OPEN_SUB_MENU",ariaLabel:j("aria_label_menu_audio_languages",{actual:t}),icon:jv,label:j("menu_audio_languages"),value:t,children:"audio-tracks"}},"playback-rate-settings":({availablePlaybackRates:i,currentPlaybackRate:e})=>{var o;let t=((o=i.find(r=>r.value===e))==null?void 0:o.displayValue)||"";return{id:"playback-rate-settings",weight:ds["playback-rate-settings"],type:"OPEN_SUB_MENU",ariaLabel:j("aria_label_menu_rate",{actual:t}),icon:Xv,label:j("menu_playback_rate"),value:`${e}x`,children:"playback-rate"}},"subtitles-settings":({currentSubtitle:i})=>({id:"subtitles-settings",weight:ds["subtitles-settings"],type:"OPEN_SUB_MENU",ariaLabel:j("aria_label_menu_subtitle",{actual:i.displayValue}),icon:ga,iconProps:{type:"outline"},label:j("subtitles_caption"),value:i.displayValue,children:"subtitles"}),download:({onDownloadClick:i})=>({id:"download",weight:ds.download,type:"CLICK",onClick:i,label:j("download_video_caption"),ariaLabel:j("aria_label_menu_download"),icon:Zv}),"show-support":({onReportProblemClick:i})=>({id:"show-support",weight:ds.report,type:"CLICK",onClick:i,label:j("menu_report"),ariaLabel:`${j("menu_report")}. ${j("aria_label_new_tab_alert")}`,icon:Jv,isHiddenFor:["desktop"]}),"copy-data":({onCopyDataClick:i})=>({id:"copy-data",weight:ds["copy-data"],type:"CLICK",onClick:i,label:j("menu_copy_debug"),ariaLabel:j("menu_copy_debug"),icon:Ip,isHiddenFor:["desktop"]}),"save-trace-info":({onSaveTraceDataClick:i})=>({id:"save-trace-info",weight:ds["save-trace-info"],type:"CLICK",onClick:i,label:j("menu_save_debug"),ariaLabel:j("menu_save_debug"),icon:Ip,isHiddenFor:["desktop"]}),"debug-info":({toggleShowDebugInfo:i})=>({id:"debug-info",weight:ds["debug-info"],type:"CLICK",onClick:i,ariaLabel:j("aria_label_menu_debug_overlay"),label:j("menu_debug_overlay"),icon:eg,isHiddenFor:["desktop"]})},g$=({items:i,context:e,additionalSettingsMenuItems:t})=>{let{isMobile:o}=e;return[...i.map(r=>xC[r](e)),...t.map(r=>Gt(ke({},r),{isAdditional:!0}))].filter(r=>{var a,l,d;return!((a=r==null?void 0:r.isHiddenFor)!=null&&a.length)||!((l=r==null?void 0:r.isHiddenFor)!=null&&l.includes("desktop"))&&!o||!((d=r==null?void 0:r.isHiddenFor)!=null&&d.includes("mobile"))&&o}).sort(Ya)};var SC=(i,e)=>{tp(i,e)},CC=L('<div><div> </div> <div class="close s-q" data-testid="close-settings-menu"></div></div>'),TC=L('<div data-testid="settings-menu" role="presentation"><!> <ul role="menu"></ul></div>'),IC=L("<div><!> <!></div>"),EC={hash:"s-q",code:'.settings-menu-container.mobile.s-q{width:100%;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}.settings-menu-container.s-q ul{list-style-type:none;margin:0;padding:0}.settings-menu-container.s-q .menu{background-color:var(--settings-bg);border-radius:var(--settings-radius);overflow:hidden;transition:opacity .2s,visibility .2s}.settings-menu-container.s-q .menu .item:first-child:not(.mobile){border-top-left-radius:var(--settings-radius);border-top-right-radius:var(--settings-radius)}.settings-menu-container.s-q .menu .item:last-child{border-bottom-left-radius:var(--settings-radius);border-bottom-right-radius:var(--settings-radius)}.settings-menu-container.s-q .settings-menu .item:first-child:not(.mobile){padding-top:6px}.settings-menu-container.s-q .settings-menu .item:last-child:not(.mobile){padding-bottom:6px}.settings-menu-container.s-q .menu.desktop{bottom:0;max-width:100%;position:absolute;right:0}.settings-menu.s-q{line-height:40px}.settings-menu.desktop.s-q{min-width:300px}.settings-menu-container.s-q .menu.mobile{background:var(--mobile-settings-bg);font-size:15px;line-height:50px;width:100%}.settings-menu-container.s-q .menu.mobile.hidden{display:none}.settings-menu-container.s-q .menu .item:not(.switch-item),.settings-menu-container.s-q .menu .switch-wrapper{align-items:center;color:var(--white);cursor:pointer;display:flex;justify-content:flex-end;position:relative;white-space:nowrap}.settings-menu-container.s-q .menu .item:hover{background-color:var(--settings-item-bg-hover)}.settings-menu-container.s-q .menu .item.mobile:hover{background:var(--mobile-settings-bg)}.settings-menu.s-q .item:not(.switch-item),.settings-menu.s-q .switch-wrapper{padding:0 32px 0 18px}.settings-menu.s-q .item.mobile:not(.switch-item),.settings-menu.s-q .switch-wrapper.mobile{padding:0 14px}.settings-menu.s-q .icon-wrapper{align-items:center;display:flex;height:24px;justify-content:center;margin-right:16px;min-width:24px;width:24px}.settings-menu.s-q .label{flex-grow:1;margin-right:24px;overflow:hidden;text-overflow:ellipsis}.settings-menu.s-q .item.header.mobile:where(.s-q){border-bottom:var(--divider-border);color:var(--white);column-gap:12px;cursor:pointer;display:flex;justify-content:space-between;margin-bottom:4px}.settings-menu-container.s-q .items::-webkit-scrollbar{width:8px}.settings-menu-container.s-q .items::-webkit-scrollbar-track{background-color:#3a3a3a;border-radius:4px;box-shadow:none}.settings-menu-container.s-q .items::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#666;border:1px solid transparent;border-radius:5px;min-height:40px}.settings-menu-container.s-q .items::-webkit-scrollbar-thumb:hover{background-color:#777}.settings-menu-container.s-q .items.mobile{max-height:160px;overflow-x:hidden;overflow-y:auto;text-align:left}.close.s-q{height:12px;margin-right:-12px;padding:12px;position:relative;width:12px}.close.s-q:after,.close.s-q:before{background-color:var(--white);content:" ";height:12px;left:18px;position:absolute;width:2px}.close.s-q:before{transform:rotate(45deg)}.close.s-q:after{transform:rotate(-45deg)}'};function Oc(i,e){B(e,!0),Q(i,EC);let[t,o]=De(),r=()=>w(He,"$settingsMenuVisible",t),a=()=>w(it,"$settingsMenuOpenedByKeyboard",t),l=()=>w(Fe,"$debugPanelVisible",t),d=()=>w(ce,"$isMobile",t),s=()=>w(Te,"$playerSize",t),u=()=>w(xe,"$hasMpegSources$",t),m=()=>w(Ne,"$mobileNotReportControlHidden$",t),p=()=>w(ge,"$autoQualityLimitingAvailable$",t),v=()=>w(K,"$availableSubtitlesList$",t),b=()=>w(Le,"$isLiveWithPlaybackSpeed",t),y=()=>w(ee,"$availableAudioStreams$",t),_=()=>w(D,"$availablePlaybackRates$",t),x=()=>w(me,"$currentAudioStream$",t),I=()=>w(G,"$currentPlaybackRate$",t),T=()=>w(et,"$trafficSavingEnabled",t),R=()=>w(_e,"$currentQuality$",t),A=()=>w(pe,"$isAutoQualityEnabled$",t),P=()=>w(Ge,"$currentSubtitle$",t),E=()=>w(Tt,"$additionalSettingsMenuItems$",t),z=()=>w(Qe,"$isAutoQualityAvailable$",t),F=()=>w(Ce,"$availableQualities$",t),U=()=>w(Ee,"$highQualityEnabled",t),X=h(e,"ref",15,void 0),ae=h(e,"playerControlsHeight",3,0),Z=ui({}),re=ui({}),J=be(),we=Ot(),me=J.state.audioStream$,ee=J.state.availableAudioStreams$,_e=J.state.currentQuality$,Ce=J.state.availableQualities$,ge=J.state.autoQualityLimitingAvailable$,pe=J.state.isAutoQualityEnabled$,Qe=J.state.isAutoQualityAvailable$,G=J.state.currentPlaybackRate$,D=J.state.availablePlaybackRates$,Ge=J.state.currentSubtitle$,K=J.state.availableSubtitlesList$,se=J.state.canDownload,xe=J.state.hasMpegSources$,He=J.ui.settingsMenu.visible$,it=J.ui.settingsMenu.openedByBtnKeyboard$,ne=J.ui.settingsMenu.ref$,ce=J.ui.isMobile,Ne=J.ui.mobileNotReportControlHidden$,Le=J.state.canChangePlaybackSpeed$,et=J.state.trafficSavingEnabled$,Ee=J.state.highQualityEnabled$,Te=J.ui.playerSize,Fe=J.ui.debugPanelVisible,kt=J.state.isInteractiveTime$,Tt=J.ui.additionalSettingsMenuItems$,Vt=J.ui.t,pt=J.actions.internal.downloadVideo,At=J.actions.internal.closeSettingsMenu,ti=J.actions.internal.openSettingsSubMenu,Lt=J.actions.internal.closeSettingsSubMenu,Ft=q(!1),qt=q(void 0),Y=s$();Oe(()=>{!r()&&Y.current&&(Lt(re[Y.current]),Y.popAllSubMenus())}),Oe(()=>{r()||N(qt,void 0)}),Oe(()=>{!Y.current&&n(qt)&&vb(Z,n(qt))}),Oe(()=>{X()&&ne.set(X())});function Pe(bt){return ht(this,null,function*(){var W;Y.pushSubMenu(bt),yield ho(),ti(bt,re[bt]);let Ut=(W=X())==null?void 0:W.firstElementChild;Ut&&_m(Ut)})}function le(bt){var Ut;bt==null||bt.stopPropagation(),a()||(Ut=e.returnFocus)==null||Ut.call(e),At(),N(Ft,!1)}function $e(bt,Ut){J.actions.internal.setQuality(bt,{appliesTo:Ut,byUser:!0}),le()}function Ve(bt){J.actions.internal.setAudioStream(bt),le()}function dt(bt,Ut){J.actions.internal.setTrafficSavingEnabled(bt,Ut),we.features.qualityDetailsSubMenuEnabled&&le()}function St(bt,Ut){J.actions.internal.setHighQualityEnabled(bt,Ut),le()}function fe(bt){J.actions.internal.setPlaybackRate(bt),le()}function Be(bt){J.actions.internal.setSubtitle(bt),le()}function We(){pt()}function Ct(){(0,Dc.isValidURL)(e.supportLink)&&window.open(e.supportLink,"_blank"),J.actions.internal.reportProblem(),J.actions.internal.pause()}function Xt(){Yl(J.actions.internal.getDebugTextData())}let It=()=>{let bt=J.actions.internal.getTraceTextData(),Ut=new Blob([...bt],{type:"application/json"}),W=window.URL.createObjectURL(Ut);Ka(W,"vk_player_trace_info","json")};function ai(){Fe.set(!l())}function fi(){N(Ft,!0)}function Bi(){N(Ft,!1)}function Bt(){return d()?`max-height: ${Math.round(s().height*.6)}px`:`max-height: ${s().height-32-ae()}px; overflow: auto;`}let _o=f(()=>se&&u()&&!m()),vi=f(()=>we.features.trafficSaving&&!m()&&p()&&!we.features.qualityDetailsSubMenuEnabled),ot=f(()=>v().length>0&&!m()),Jt=f(()=>!!b()&&!m()),Hi=f(()=>we.features.audioLanguages&&y().length>=2&&!m()),xi=f(()=>!m());Dt(()=>kt.subscribe(bt=>{bt&&!d()&&!n(Ft)&&!a()&&le()}));let oi=f(()=>{let bt=[n(xi)&&"quality-settings",n(Hi)&&"audio-tracks-settings",n(Jt)&&"playback-rate-settings",n(ot)&&"subtitles-settings",n(vi)&&"traffic-saving-switch",n(_o)&&"download",we.showSupport&&"show-support","copy-data",we.features.saveTraceInfoToFile&&"save-trace-info","debug-info"].filter(Ut=>!!Ut);return g$({items:bt,context:{qualityDetailsSubMenuEnabled:we.features.qualityDetailsSubMenuEnabled,availablePlaybackRates:_(),currentAudioStream:x(),availableAudioStreams:y(),currentPlaybackRate:I(),selectPlaybackRate:fe,trafficSavingEnabled:T(),toggleTrafficSaving:dt,currentQuality:R()||Dc.VideoQuality.INVARIANT,isAutoQualityEnabled:A()||!1,currentSubtitle:P(),isMobile:d(),onDownloadClick:We,onCopyDataClick:Xt,onReportProblemClick:Ct,onSaveTraceDataClick:It,toggleShowDebugInfo:ai},additionalSettingsMenuItems:E()})}),Ti=f(()=>v$({subMenuId:Y.current,context:{availablePlaybackRates:_(),selectPlaybackRate:fe,trafficSavingEnabled:T(),toggleTrafficSaving:dt,currentQuality:R()||Dc.VideoQuality.INVARIANT,isAutoQualityEnabled:A()||!1,isAutoQualityAvailable:z()||!1,availableQualities:F(),highQualityEnabled:U(),toggleHighQuality:St,availableAudioStreams:y(),availableSubtitlesList:v(),closeSettingsMenu:At,currentAudioStream:x(),isMobile:d(),selectAudioLanguage:Ve,selectQuality:$e,selectSubtitle:Be}}));var lt=IC();let nt;var Ei=C(lt);{var tn=bt=>{var Ut=TC();let W;Ut.__keydown=[SC,At];var Rt=C(Ut);{var li=xt=>{var st=CC();let Fi;var Mi=C(st),vn=C(Mi,!0);S(Mi);var gn=k(Mi,2);gn.__click=le,S(st),O((Vi,Ui)=>{Fi=oe(st,1,"item header s-q",null,Fi,Vi),ve(vn,Ui)},[()=>({mobile:d()}),()=>Vt("submenu_settings")]),$(xt,st)};V(Rt,xt=>{d()&&xt(li)})}var gt=k(Rt,2);let ii;yi(gt,21,()=>n(oi),xt=>xt.id,(xt,st)=>{var Fi=Me(),Mi=ue(Fi);{var vn=Vi=>{Ov(Vi,{get isMobile(){return d()},get id(){return n(st).id},get icon(){return n(st).icon},get iconProps(){return n(st).iconProps},get label(){return n(st).label},get ariaLabel(){return n(st).ariaLabel},get value(){return n(st).value},get valueComponent(){return n(st).valueComponent},onClick:()=>{Pe(n(st).children),N(qt,n(st).id,!0)},get ref(){return Z[n(st).id]},set ref(Ui){Z[n(st).id]=Ui}})},gn=(Vi,Ui)=>{{var Hn=lo=>{let Ai=f(()=>`${n(st).id}-menu-item`);Hv(lo,{get isMobile(){return d()},get id(){return n(Ai)},get onClick(){return n(st).onClick},get icon(){return n(st).icon},get label(){return n(st).label},get ariaLabel(){return n(st).ariaLabel},closeSettings:le})},bo=(lo,Ai)=>{{var Ho=Fo=>{let hn=f(()=>`${n(st).id}-menu-item`);Uv(Fo,{get isMobile(){return d()},get id(){return n(hn)},get onClick(){return n(st).onClick},get icon(){return n(st).icon},get label(){return n(st).label},get ariaLabel(){return n(st).ariaLabel},get enabled(){return n(st).enabled},get tooltipText(){return n(st).tooltipText},get maxTooltipWidth(){return n(st).maxTooltipWidth}})};V(lo,Fo=>{n(st).type==="SWITCH"&&Fo(Ho)},Ai)}};V(Vi,lo=>{n(st).type==="CLICK"?lo(Hn):lo(bo,!1)},Ui)}};V(Mi,Vi=>{n(st).type==="OPEN_SUB_MENU"?Vi(vn):Vi(gn,!1)})}$(xt,Fi)}),S(gt),Xe(gt,xt=>X(xt),()=>X()),S(Ut),O((xt,st,Fi)=>{W=oe(Ut,1,"settings-menu menu s-q",null,W,xt),ii=oe(gt,1,"items",null,ii,st),qe(gt,Fi)},[()=>({desktop:!d(),mobile:d(),hidden:!!Y.current}),()=>({mobile:d()}),Bt]),ut("mouseenter",Ut,fi),ut("mouseleave",Ut,Bi),$(bt,Ut)};V(Ei,bt=>{r()&&bt(tn)})}var Bo=k(Ei,2);yi(Bo,17,()=>n(Ti),bt=>bt.id,(bt,Ut)=>{let W=f(()=>{var Rt;return(Rt=n(Ut).minWidth)!=null?Rt:137});Dv(bt,{get isMobile(){return d()},get playerControlsHeight(){return ae()},get returnFromSubMenu(){return Y.popSubMenu},get id(){return n(Ut).id},get title(){return n(Ut).title},get closeSettingsMenu(){return At},openSubMenuList:Pe,get items(){return n(Ut).items},get minWidth(){return n(W)},get refMenuItems(){return Z},get listRef(){return re[n(Ut).id]},set listRef(Rt){re[n(Ut).id]=Rt}})}),S(lt),O(bt=>nt=oe(lt,1,"settings-menu-container s-q",null,nt,bt),[()=>({mobile:d(),hidden:!r()})]),$(i,lt),H(),o()}Ye(["keydown","click"]);var PC=L('<button class="btn s-1c"> </button>'),kC={hash:"s-1c",code:"button.btn.s-1c{background:hsla(0,0%,100%,.1);border-radius:8px;font-size:14px;line-height:18px;margin-top:12px;padding:6px 12px 7px}"};function ig(i,e){Q(i,kC);var t=PC();t.__click=function(...r){var a;(a=e.onClick)==null||a.apply(this,r)};var o=C(t,!0);S(t),O(()=>ve(o,e.label)),$(i,t)}Ye(["click"]);var AC=L('<div class="container s-r"><div class="notification s-r"><div><p class="description s-r"><!></p> <!></div> <!></div></div>'),LC={hash:"s-r",code:".container.s-r{display:flex;justify-content:center;left:0;pointer-events:none;position:absolute;right:0;top:20px;z-index:var(--controls-container-z-index)}.notification.s-r{background:var(--notification-bg);border-radius:var(--notification-radius);display:inline-flex;gap:10px;padding:9px 14px 10px 12px;pointer-events:auto}.description.s-r{font-size:13px;line-height:16px;margin:0;white-space:pre}"};function Bc(i,e){B(e,!0),Q(i,LC);let t=340,{features:{forceAutoQualityWhenSevereStallHappens:o}}=Ot(),{ui:{t:r}}=be(),a=r(o?"slow_video_notification_force_description":"slow_video_notification_suggest_description");var l=AC(),d=C(l),s=C(d),u=C(s),m=C(u);Nc(m,{get message(){return a}}),S(u);var p=k(u,2);{var v=y=>{let _=f(()=>r("slow_video_notification_button"));ig(y,{get label(){return n(_)},get onClick(){return e.onSelectAutoQuality}})};V(p,y=>{o||y(v)})}S(s);var b=k(s,2);Hs(b,{get onClick(){return e.onClose}}),S(d),S(l),ns(3,d,()=>ws,()=>({duration:t})),$(i,l),H()}var Hc=require("@vkontakte/videoplayer-shared/es2015");var pl="annotation",Ep=class{constructor(e){this.slots=new Map;this.disabledIds=new Set(e)}init(e,t){this.shadowRootContainer=e,this.store=t}add(e,t){var s;let{overlay:o,id:r,controlsBehaviour:a,hideAllControls:l}=t;if(this.disabledIds.has(r))return{success:!1,message:"current slotId is disabled via config"};let d=typeof e=="function"?e():e;return d.setAttribute("slot",pl),this.setupSlotStyles(d,o),this.shadowRootContainer.append(d),this.slots.set(r,{rootElement:d,options:t}),a&&this.runHidingControlsWhenIntersected(r,a),l&&((s=this.store)==null||s.ui.isControlsAvailable.set(!1)),{success:!0}}setupSlotStyles(e,t){switch(e.style.position="absolute",t){case"over_video":e.style.zIndex="calc(var(--video-container-z-index) + 1)";break;case"over_controls":e.style.zIndex="calc(var(--controls-container-z-index) + 1)";break;default:e.style.zIndex="0"}}runHidingControlsWhenIntersected(r,a){return ht(this,arguments,function*(e,{observedSlotElementId:t,controlsToObserve:o}){var v;let l=this.slots.get(e);if(!l)return;let d=yield this.findSlotElement(l.rootElement,t,e),{controls:s,hiddenControls:u}=((v=this.store)==null?void 0:v.ui)||{},m=new MutationObserver(b=>b.forEach(()=>{let y=zs(d,this.shadowRootContainer);o.forEach(_=>{let x=s==null?void 0:s[_],I=x?ye(x):null,T=u==null?void 0:u[_];I&&(T==null||T.set((0,Hc.isIntersecting)(I,y)))})}));m.observe(d,{childList:!0,subtree:!0}),l.observer=m;let p=new Hc.Subscription;o.forEach(b=>{s&&p.add(s[b].subscribe(y=>{let _=u==null?void 0:u[b];y&&y.isDisplayed?_==null||_.set((0,Hc.isIntersecting)(y,zs(d,this.shadowRootContainer))):_==null||_.set(!1)}))}),l.subs=p})}findSlotElement(e,t,o){return ht(this,null,function*(){return new Promise(r=>{let a=null,l=new MutationObserver(()=>{if(a=e.querySelector(`#${t}`),a){l.disconnect();let s=this.slots.get(o);s&&(s.observerForFindingSlotElement=void 0),r(a)}});l.observe(e,{childList:!0,subtree:!0});let d=this.slots.get(o);d&&(d.observerForFindingSlotElement=l)})})}remove(e){var u,m;let t=this.slots.get(e);if(!t)return;let{rootElement:o,observer:r,observerForFindingSlotElement:a,subs:l,options:{controlsBehaviour:d,hideAllControls:s}}=t;o&&o.remove(),[r,a].forEach(p=>p==null?void 0:p.disconnect()),l==null||l.unsubscribe(),this.slots.delete(e),s&&((u=this.store)==null||u.ui.isControlsAvailable.set(!0)),(m=d==null?void 0:d.controlsToObserve)==null||m.forEach(p=>{var v,b;(b=(v=this.store)==null?void 0:v.ui.hiddenControls[p])==null||b.set(!1)})}destroy(){for(let e in this.slots.keys())this.remove(e);this.slots.clear()}haveSlots(){return this.slots.size>0}};var MC=L('<div class="container s-5"><!></div>'),VC={hash:"s-5",code:".container.s-5{align-items:center;animation-fill-mode:forwards;animation-name:s-5-videoPlayerStatusIconPopup;background-color:#00000073;border-radius:100%;display:flex;height:64px;justify-content:center;width:64px;will-change:opacity,scale}@keyframes s-5-videoPlayerStatusIconPopup{0%{opacity:0;scale:.6}10%{animation-timing-function:ease-in;opacity:1;scale:1}75%{opacity:1;scale:1}90%{animation-timing-function:ease-out;opacity:0;scale:.4}to{opacity:0;scale:0}}"};function Fc(i,e){B(e,!0),Q(i,VC);let t=h(e,"reversed",3,!1);var o=Me(),r=ue(o);Ns(r,()=>e.Icon,a=>{var l=MC(),d=C(l);Di(d,()=>e.Icon,(s,u)=>{u(s,{get size(){return"48"},get reversed(){return t()}})}),S(l),O(()=>qe(l,`animation-duration: ${e.duration}ms`)),$(a,l)}),$(i,o),H()}var og=require("@vkontakte/videoplayer-core/es2015"),RC=L('<div class="container s-12"><!></div>'),NC={hash:"s-12",code:".container.s-12{align-items:center;display:flex;height:100%;justify-content:center;pointer-events:none;position:absolute;width:100%}"};function ng(i,e){B(e,!0),Q(i,NC);let[t,o]=De(),r=()=>w(s,"$playbackState$",t),a=()=>w(m,"$previewTrackActive",t),l=()=>w(p,"$previewTrackDragInProgress",t),d=()=>w(u,"$isPlaying$",t),{state:{playbackState$:s,isPlaying$:u},ui:{previewTrackActive:m,previewTrackDragInProgress:p}}=be(),{features:{playbackStatusShow:v},playbackStatusAnimationDuration:b}=Ot(),y=0,_=q(null),x=q(!1);Oe(()=>{r()===og.PlaybackState.PLAYING?N(_,Dn,!0):r()===og.PlaybackState.PAUSED?N(_,Ks,!0):N(_,null)}),Oe(()=>{if(!(!v||a()||l()))return y=window.setTimeout(()=>{y=0,N(_,null)},b),()=>{y&&(window.clearTimeout(y),y=0)}}),Oe(()=>{d()&&!n(x)&&(N(x,!0),N(_,null))});var I=Me(),T=ue(I);{var R=A=>{var P=RC(),E=C(P);Fc(E,{get duration(){return b},get Icon(){return n(_)}}),S(P),$(A,P)};V(T,A=>{n(_)&&v&&A(R)})}$(i,I),H(),o()}var DC=L('<div><div data-testid="video-container"></div></div>'),OC={hash:"s-c",code:".video-container.s-c,.video-wrapper.s-c{height:100%;left:0;position:absolute;top:0;width:100%}.video-wrapper.s-c{background:var(--black)}.video-container.s-c,.video-wrapper.s-c{z-index:var(--video-container-z-index)}.video-container.s-c{transition:var(--rotate-transition-duration) ease all}.video-container.fast-rotate.s-c{transition:none}.nocursor.s-c{cursor:none}"};function fl(i,e){B(e,!0),Q(i,OC);let[t,o]=De(),r=()=>w(p,"$rotateAlpha",t),a=()=>w(v,"$playerSize",t),l=()=>w(m,"$playerPhase",t),d=()=>w(y,"$chromecastConnected$",t),s=()=>w(b,"$isPlaying$",t),u=h(e,"videoContainer",15),{playerPhase:m,ui:{rotateAlpha:p,playerSize:v},state:{isPlaying$:b,chromecastConnected$:y}}=be(),{isSmoothVideoRotate:_}=Ot(),x=f(()=>u()&&r()%180?a().height/a().width:1);var I=DC();let T;I.__contextmenu=function(...P){var E;(E=e.onContextMenu)==null||E.apply(this,P)},I.__mousedown=function(...P){var E;(E=e.onMouseDown)==null||E.apply(this,P)},I.__mouseup=function(...P){var E;(E=e.onMouseUp)==null||E.apply(this,P)},I.__click=function(...P){var E;(E=e.onClick)==null||E.apply(this,P)},I.__dblclick=function(...P){var E;(E=e.onDblClick)==null||E.apply(this,P)};var R=C(I);let A;Xe(R,P=>u(P),()=>u()),S(I),O((P,E)=>{T=oe(I,1,"video-wrapper s-c",null,T,P),A=oe(R,1,"video-container s-c",null,A,E),qe(R,`transform: rotate(${r()}deg) scale(${n(x)})`),Re(R,"data-is-playing",s())},[()=>({hidden:l()!=="video"||d(),nocursor:e.hideCursor}),()=>({"fast-rotate":!_})]),$(i,I),H(),o()}Ye(["contextmenu","mousedown","mouseup","click","dblclick"]);var BC=L('<div><span class="text s-10"> </span> <!></div>'),HC={hash:"s-10",code:".root.s-10{background-color:var(--double-forward-bg);border-radius:100px;color:var(--white);display:flex;gap:4px;left:50%;opacity:0;padding:6px 12px;pointer-events:none;position:absolute;top:24px;transition:opacity var(--controls-transition-duration) var(--controls-transition-fn);visibility:hidden}.root.s-10,.root.visible.s-10{transform:translateX(-50%)}.root.visible.s-10{opacity:1;visibility:visible}.text.s-10{font-size:13px;font-weight:600;line-height:16px}"};function rg(i,e){B(e,!0),Q(i,HC);let{ui:{t}}=be();var o=BC();let r;var a=C(o),l=C(a,!0);S(a);var d=k(a,2);Ac(d,{get size(){return"16"},fill:"currentColor"}),S(o),O((s,u)=>{r=oe(o,1,"root s-10",null,r,s),ve(l,u)},[()=>({visible:e.isVisible}),()=>t("double_forward_label")]),$(i,o),H()}var FC=L('<div class="container s-15" role="button" data-testid="preview-track-overlay"><div class="icon s-15"><!></div></div>'),UC={hash:"s-15",code:".container.s-15{background-color:rgba(0,0,0,.48);cursor:pointer;height:100%;position:absolute;width:100%}.container.s-15,.icon.s-15{align-items:center;display:flex;justify-content:center}.icon.s-15{background-color:#00000073;border-radius:100%;height:64px;transition:transform .2s;transition-timing-function:ease-out;width:64px;will-change:transform}.container.s-15:hover .icon:where(.s-15){transform:scale(1.15)}"};function sg(i,e){B(e,!1),Q(i,UC);let o=be().actions.internal.closePreviewTrack,r=200,a=u=>{u.stopPropagation(),o()};$o();var l=FC();l.__click=a;var d=C(l),s=C(d);return Dn(s,{get size(){return"32"}}),S(d),S(l),ns(3,l,()=>ws,()=>({duration:r})),$(i,l),zf(e,"handleClick",a),H({handleClick:a})}Ye(["click"]);var zC=L('<div class="container s-z"><div class="notification s-z"><span class="text s-z"> </span></div></div>'),WC={hash:"s-z",code:".container.s-z{display:flex;justify-content:center;left:0;pointer-events:none;position:absolute;right:0;top:20px}.notification.s-z{background-color:var(--black-alpha-40);border-radius:var(--notification-radius);padding:10px 16px}.text.s-z{font-size:14px;font-weight:500;line-height:18px}"};function ag(i,e){B(e,!1),Q(i,WC);let{ui:{t}}=be();$o();var o=zC(),r=C(o),a=C(r),l=C(a,!0);S(a),S(r),S(o),O(d=>ve(l,d),[()=>t("preview_track_notification_text")],kn),ns(3,r,()=>ws,()=>({duration:340})),$(i,o),H()}var KC=(i,e,t,o,r,a)=>{if(i.stopPropagation(),e()||o()){a();return}},qC=L("<div><!></div>"),QC=L('<div class="spherical-video-icon s-8"><!></div>'),GC=L("<div><!></div>"),YC=L('<div class="settings-menu s-8"><!></div>'),jC=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),XC=L("<!> <!> <!>",1),ZC=L('<div class="blocked s-8"></div>'),JC=L('<div class="player-wrapper s-8"><!> <div class="overlay-container"></div></div> <!>',1),eT={hash:"s-8",code:".blocked.s-8,.player-wrapper.s-8{height:100%;position:absolute;width:100%}.blocked.s-8{z-index:var(--overlay-container-z-index)}.player-wrapper.s-8 .player-media{background:var(--black);height:100%;left:0;position:absolute;top:0;transition:transform .2s ease-in-out;width:100%}.spherical-video-icon.s-8{display:inline-block;left:calc(50% - 38px);position:absolute;top:calc(50% - 23px)}.ads-container.s-8{background:var(--black);height:100%;left:0;position:absolute;top:0;width:100%;z-index:var(--ads-container-z-index)}.settings-menu.s-8{bottom:57px;left:0;position:absolute;right:18px;transition:opacity .2s;z-index:var(--settings-menu-z-index)}"};function dg(i,e){B(e,!0),Q(i,eT);let[t,o]=De(),r=()=>w(zr,"$notificationsToShow$",t),a=()=>w(vi,"$playerPhase",t),l=()=>w(tn,"$isLoaderVisible",t),d=()=>w(Bi,"$adPlaybackState",t),s=()=>w(gt,"$crashed",t),u=()=>w(Ui,"$isInteractiveTime$",t),m=()=>w(xi,"$settingsMenuVisible",t),p=()=>w(Hn,"$isInteractiveExpectation$",t),v=()=>w(Hi,"$controlsVisible",t),b=()=>w(lo,"$touched",t),y=()=>w(cs,"$graphIsOpened$",t),_=()=>w(ot,"$isFullscreen",t),x=()=>w(nr,"$autoplayNextEnabled$",t),I=()=>w(W,"$postrollPassed",t),T=()=>w(Bo,"$isEnded$",t),R=()=>w(yn,"$cursorInside",t),A=()=>w(_n,"$isControlsAvailable",t),P=()=>w(_r,"$doubleForwardOn$",t),E=()=>w(rr,"$fakeIsPlaying$",t),z=()=>w(Wn,"$bottomNoSmooth",t),F=()=>w(Or,"$interactiveTimeIndicator",t),U=()=>w(Mi,"$playerSize",t),X=()=>w(vn,"$is3DVideo",t),ae=()=>w(br,"$doubleForwardAvailable$",t),Z=()=>w(nt,"$contextMenuVisible$",t),re=()=>w(fi,"$playbackState$",t),J=()=>w(Ai,"$hotKeyMapData",t),we=()=>w(Ti,"$scrubbingInProgress",t),me=()=>w(lt,"$volumeChangingInProgress",t),ee=()=>w(bt,"$chromecastConnected$",t),_e=()=>w(Kn,"$controlsTimeoutActive",t),Ce=()=>w(oi,"$settingsMenuOpenedByKeyboard",t),ge=()=>w(ko,"$contextMenuOpenedByKeyboard$",t),pe=()=>w(qo,"$contextMenuOpenedByHotKey$",t),Qe=()=>w(Tn,"$contextMenuButtonRef$",t),G=()=>w(dr,"$contextMenuLastActiveElem$",t),D=()=>w(Jt,"$isFullscreenOpenedByKeyboard",t),Ge=()=>w(Fo,"$positionExact$",t),K=()=>w(ai,"$language$",t),se=()=>w(Pr,"$previewTrackActive$",t),xe=()=>w(gn,"$icon3DVideoVisible",t),He=()=>w(Ut,"$chromecastDeviceName$",t),it=()=>w(st,"$currentSubtitle$",t),ne=()=>w(Fi,"$currentSubtitleCaptions$",t),ce=()=>w(Bt,"$position$",t),Ne=()=>w(_o,"$duration$",t),Le=()=>w(Rt,"$isLive$",t),et=()=>w(li,"$isPlaying$",t),Ee=()=>w(Hr,"$contextMenuPosition$",t),Te=()=>w(on,"$previewTrackNotificationVisible$",t),Fe=()=>w(Ho,"$showHotKeyMap",t),kt=()=>w(Ei,"$debugPanelVisible",t),Tt=()=>w(Ur,"$userActionsDisabled$",t),Vt=h(e,"videoContainer",15),pt=h(e,"adsSlotId",3,void 0),At=h(e,"adsParams",3,void 0),ti=h(e,"adsAutoplayParam",3,void 0),Lt=h(e,"duration",3,void 0),Ft=h(e,"logoTargetUrl",3,""),qt=h(e,"showNextPrevButtons",3,!1),Y=h(e,"nextButtonActive",3,!1),Pe=h(e,"prevButtonActive",3,!1),le=h(e,"endScreenVideoTitle",3,void 0),$e=h(e,"endScreenVideoThumb",3,void 0),Ve=h(e,"isOneVideoPlaylist",3,!1),dt=h(e,"shadowRootContainer",3,void 0),St=h(e,"outerContainerRef",3,void 0),fe=h(e,"playerStarted",3,!1),Be=h(e,"fullScreenTarget",3,void 0),We=h(e,"showMiniTimer",3,!1),Ct=h(e,"showEndScreen",3,!0),Xt=h(e,"keyboardControls",15),It=e.store.getLogger().createComponentLog("Root component"),ai=e.store.interfaceLanguage$,fi=e.store.state.playbackState$,Bi=e.store.ads.playbackState,Bt=e.store.state.positionWithScrubbing$,_o=e.store.state.duration$,vi=e.store.playerPhase,ot=e.store.ui.isFullscreen,Jt=e.store.ui.isFullscreenOpenedByKeyboard,Hi=e.store.ui.controlsVisible,xi=e.store.ui.settingsMenu.visible$,oi=e.store.ui.settingsMenu.openedByBtnKeyboard$,Ti=e.store.ui.scrubbingInProgress,lt=e.store.ui.volumeChangingInProgress,nt=e.store.ui.contextMenu.visible$,Ei=e.store.ui.debugPanelVisible,tn=e.store.state.isLoaderVisible,Bo=e.store.state.isEnded$,bt=e.store.state.chromecastConnected$,Ut=e.store.state.chromecastDeviceName$,W=e.store.ads.postrollPassed,Rt=e.store.state.isLive$,li=e.store.state.isPlaying$,gt=e.store.state.crashed$,ii=e.store.webApi.annotationsApi,xt=e.store.webApi.pictureInPictureApi,st=e.store.state.currentSubtitle$,Fi=e.store.state.currentSubtitleCaptions$,Mi=e.store.ui.playerSize,vn=e.store.ui.is3DVideo,gn=e.store.ui.icon3DVideoVisible,Vi=e.store.state.isInteractive,Ui=e.store.state.isInteractiveTime$,Hn=e.store.state.isInteractiveExpectation$,bo=e.store.state.hasInteractiveBranches,lo=e.store.ui.touched,Ai=e.store.ui.modals.hotKeyMap.data,Ho=e.store.ui.modals.hotKeyMap.show,Fo=e.store.state.positionExact$,hn=e.store.ui.overlayContainer$,Or=e.store.ui.controls.interactiveTimeIndicator,Br=e.store.state.showInteractiveTimeIndicator,Hr=e.store.ui.contextMenu.position$,Ss=e.store.actions.internal.setQuality,Fr=e.store.actions.internal.closeSettingsMenu,nr=e.store.ui.autoplayNextEnabled$,Ur=e.store.ui.userActionsDisabled,_n=e.store.ui.isControlsAvailable,bn=e.store.ui.videoTitleInfo,_r=e.store.ui.doubleForwardOn$,br=e.store.ui.doubleForwardAvailable$,on=e.store.ui.previewTrackNotificationVisible,$r=e.store.actions.internal.getVideoElement,yr=e.store.actions.internal.checkFullscreenSupport,{fakeIsPlaying$:rr,notifications$:Fn,graphIsOpened$:cs}=yo(),xo=q(void 0),xr=q(void 0),zi=q(void 0),wr=q(void 0),Un,vt,ni;Ai.set(db());let{closeNotification:Sr,notificationsToShow$:zr}=Fn,Wr=f(()=>!!r().slow_video),zn=()=>Sr("slow_video"),sr=f(()=>(a()==="video"&&l()||a()==="ads"&&d()==="inactive")&&!s()),wo=q(void 0),Wn=de(!1),ar,Kn=de(!1),$n=de(),yn=de(!1),xn=q(!1),nn=q(!1),Wi=q(!1),eo=q(!(e.autoplay&&!e.uiConfig.controls.showOnStartupAtAutoplay)),rn=f(()=>u()&&!m()&&!(n(xn)||n(nn))&&!(n(Wi)&&!p())),lr=!0,Cr=f(()=>e.uiConfig.features.thumbTimer&&We()&&a()==="video"&&!v()&&!s()&&!Vi&&(e.uiConfig.hideThumbTimerAfterTouch&&!b()||!e.uiConfig.hideThumbTimerAfterTouch)),wn=e.uiConfig.titleShowBehaviour,Tr=f(()=>!["video","thumb"].includes(a())||wn==="never"||y()?!1:wn==="fullscreen"?_():!0),ft=f(()=>wn==="always"||a()==="thumb"?!1:!v()),Nt=q(!1),So=f(()=>(Ct()||e.showAutoplayNext&&x())&&!!le()&&!!$e()&&(e.showAds&&I()||!e.showAds)&&T()&&!s()&&!n(Nt)&&!bo),Sn=f(()=>R()&&!(v()||n(So))&&!u()&&A()&&!P()),Co=q(!1),sn=f(()=>E()!==null),{toggle:co}=rr,To=!1,Pi=null;xt==null||xt.setContext(Cd());let Kr=()=>{e.autoplay&&!Vi&&e.uiConfig.controls.showOnStartupAtAutoplay&&Ki(e.uiConfig.controls.hideTimeout)};e.store.setUiCallbacks({onStarted:Kr});let qn=()=>{window.clearTimeout(Un),Kn.set(!1)},Cs=()=>{window.clearTimeout(vt),$n.set(null)},Ki=he=>{qn(),Kn.set(!0),Un=window.setTimeout(()=>Kn.set(!1),he);let wt=he-100;ar=window.setTimeout(()=>{z()&&Wn.set(!1)},wt>0?wt:he)},Ts=(he,wt)=>{Cs(),$n.set(wt),vt=window.setTimeout(()=>$n.set(null),he)},us=vn.subscribe(he=>{gn.set(he),he&&(window.clearTimeout(ni),ni=window.setTimeout(()=>gn.set(!1),e.uiConfig.controls.hide360IconTimeout))}),Ir=()=>ht(null,null,function*(){var wt,ci,Zt,Lo;let he=ca();if(he){let po=ec(),Qo=an();he=po===Qo||po===dt()}if(he){Ki(e.uiConfig.controls.hideTimeoutFullscreen);try{yield xt==null?void 0:xt.exit()}catch(po){It({message:String(po)})}}ot.set(he),e.store.getAdmanWrapper().setFullscreen(he),_()?(ci=(wt=e.store.callbacks)==null?void 0:wt.onFullscreenEnter)==null||ci.call(wt):(Lo=(Zt=e.store.callbacks)==null?void 0:Zt.onFullscreenExit)==null||Lo.call(Zt)}),Uo=he=>{Mi.set(he)},qr=()=>{if(n(xo)){let{width:he,height:wt}=n(xo).getBoundingClientRect();Mi.set({width:he,height:wt})}};Dt(()=>{var wt;return Ju(Ir),e.uiConfig.features.annotationsInside&&(ii==null||ii.init(n(xo))),xt==null||xt.assignPlayerContainer(n(xo)),xt==null||xt.setExternalEventHandlers({resize:Uo,leavepictureinpicture:qr}),e.interactiveContainer&&((wt=Vt().parentElement)==null||wt.insertBefore(e.interactiveContainer,Vt().nextSibling)),()=>{window.clearTimeout(Un),window.clearTimeout(ar),window.clearTimeout(vt),window.clearTimeout(ni),us(),xt==null||xt.dispose().catch(ci=>{It({message:String(ci)})}),ep(Ir)}});let an=()=>{let he=e.uiConfig.features.fullscreenInternalTargetPlayerContainer||!St()?n(xo):St(),wt=he.getRootNode(),ci=wt instanceof ShadowRoot?wt.host:wt,Zt=Be()instanceof HTMLElement&&Be().contains(ci);return e.uiConfig.allowChangingFullscreenTarget&&Be()&&Zt?Be():he},ln=()=>{nt.set(!1)},Ue=()=>{Fr(),ln()},Et=()=>ht(null,null,function*(){if(!yr()){It({message:"fullscreen disabled"});return}ln(),ca()?(yield Zu(document),It({message:"exit fullscreen"})):(It({message:"request fullscreen"}),yield Xu(an()))}),mi=he=>{y()||(he.preventDefault(),nt.set(!0),Hr.set({left:he.clientX,top:he.clientY}))};function zo(){yn.set(!0),Vi||Ki(e.uiConfig.controls.hideTimeoutCursor)}function Io(he){var Lo,po;let{relatedTarget:wt}=he,Zt=!!(wt&&((Lo=n(zi))!=null&&Lo.contains(wt)))&&((po=Xt())==null?void 0:po.isFocused());!Vi&&!Zt&&(Wn.set(!0),Ki(e.uiConfig.controls.hideTimeoutCursor))}function Wo(){yn.set(!1),N(nn,!1),N(xn,!1),To=!1,e.store.actions.internal.releaseCamera(),Ki(e.uiConfig.controls.hideTimeout),P()&&Ko()}function qi(he){return he?he.offsetTop+qi(he.offsetParent):0}function Eo(he){return he?he.offsetLeft+Eo(he.offsetParent):0}function Qn(he){if(F()&&Br){let wt=he.currentTarget,ci=qi(wt),Zt=Eo(wt),Lo=he.pageX-Zt,po=he.pageY-ci,{left:Qo,bottom:ks,right:Yr}=F(),kr=Yr-Qo;return Lo>=Qo-kr&&po<=ks+kr}}function Er(he){if(n(xo)){let wt=qi(he.currentTarget),ci=U().height,Zt=he.pageY-wt;if(Qn(he)){N(nn,!1);return}Zt<40?N(nn,!0):Zt>ci-40?N(xn,!0):(N(nn,!1),m()||N(xn,!1))}}function Po(he){Er(he),!n(rn)&&!P()&&Ki(e.uiConfig.controls.hideTimeoutCursor),X()&&To&&Pi&&e.store.actions.internal.moveCameraFocusPX(Pi.clientX-he.clientX,Pi.clientY-he.clientY,he.timeStamp-Pi.timeStamp),Pi=he}let uo=null,Cn=()=>{uo=window.setTimeout(()=>{e.store.actions.internal.changeDoubleForwardOn(!0),qn()},e.uiConfig.doubleForwardActivationTime)},Ko=()=>{e.store.actions.internal.changeDoubleForwardOn(!1),uo&&clearTimeout(uo),uo=null},Gn=he=>{he.preventDefault(),he.button===0&&(To=!0,e.store.actions.internal.holdCamera(),ae()&&Cn()),!To&&Ki(e.uiConfig.controls.hideTimeoutCursor)},Qr=he=>{he.preventDefault(),he.button===0&&(Pi=he,To=!1,e.store.actions.internal.releaseCamera()),!P()&&Ki(e.uiConfig.controls.hideTimeoutCursor)},Gr=he=>{he.preventDefault(),lr&&(It({message:"double click on video"}),Et(),Ki(e.uiConfig.controls.hideTimeoutCursor))},Yn=he=>{var wt;if(he.preventDefault(),P()){Ko();return}if(uo&&Ko(),Z()||m()){Ue();return}if(!(T()&&!bo)){if(n(sn))return co();if((wt=Xt())==null||wt.focus(),!fe()){e.firstStart(),Ki(e.uiConfig.controls.hideTimeoutCursor);return}(!e.uiConfig.preventPauseOnVideoClick||re()!==lg.PlaybackState.PLAYING)&&e.store.actions.internal.togglePlay(),Ki(e.uiConfig.controls.hideTimeoutCursor)}},Je=he=>{Ue(),lo.set(!0),Ki(e.uiConfig.controls.hideTimeout),he&&Ts(e.uiConfig.controls.hideHotKeyHelpers,he)},ei=()=>{var he,wt;Ue(),(he=e.store.callbacks)!=null&&he.onOpenHotKeyMap?(wt=e.store.callbacks)==null||wt.onOpenHotKeyMap(J()):Ho.update(ci=>!ci)},wi=()=>{lo.set(!0)},ko=e.store.ui.contextMenu.openedByBtnKeyboard$,Tn=e.store.ui.contextMenu.btnRef$,jn=q(void 0),qo=e.store.ui.contextMenu.openedByHotKey$,dr=e.store.ui.contextMenu.lastActiveElem$,ps=q(!1),Pr=e.store.ui.previewTrackActive;Oe(()=>{hn.set(n(wo))}),Oe(()=>{N(Wi,n(eo)&&re()!==lg.PlaybackState.PLAYING,!0),n(eo)||Pt(()=>N(eo,!0))}),Oe(()=>{var wt,ci;let he=(n(Wi)||T()||m()||we()||me()||ee()||_e()||n(ps))&&!n(rn)&&(a()==="video"||a()==="ads")&&!s()&&A();Hi.set(he),!he&&!_e()&&((wt=n(zi))!=null&&wt.contains(ap()))&&((ci=Xt())==null||ci.focus())}),Oe(()=>{!we()&&n(Co)&&!u()&&Ki(e.uiConfig.controls.hideTimeoutCursor),Pt(()=>N(Co,we(),!0))}),Oe(()=>{n(wr),m(),Ce(),Pt(()=>sc(n(wr),m(),Ce()))}),Oe(()=>{n(jn),Z(),ge(),pe(),Pt(()=>{let he=ge()||pe();sc(n(jn),Z(),he)})}),Oe(()=>{let he=Qe();he&&(Z(),Pt(()=>jl(he,Z(),ko)))}),Oe(()=>{let he=G();he&&(Z(),Pt(()=>mb(he,Z(),qo)))}),Oe(()=>{var he;!D()&&_()&&(Pt(()=>Jt.set(!1)),(he=Xt())==null||he.focus())}),Oe(()=>{y()&&Ue()});let Is=q(void 0),Ys=he=>{bn.set(ir($r(),{title:n(Is)},"title",he))},ya=(he,wt)=>{var po,Qo;let ci=(Qo=(po=e.store.callbacks)==null?void 0:po.uiInfo)==null?void 0:Qo.onUpcomingLiveViewStateChanged;if(!ci)return;let Zt=!!wt,Lo=ke(ke({},ir(n(xo),{upcomingLiveScreen:wt},"upcomingLiveScreen",Zt)),he);ci(Lo)},ct="",di=f(()=>{var he;return n(ft)?ct:(he=e.getVideoDeeplink)==null?void 0:he.call(e,Ge())});Oe(()=>{ct=n(di)});var Ao=JC();ut("blur",Ra,Ue);var Si=ue(Ao);Si.__mousemove=Po;var In=C(Si);let En=f(()=>a()==="ads"),Es=f(()=>n(sn)?co:void 0);Xe(Tm(In,{startDoubleForwardActivationTimer:Cn,stopDoubleForward:Ko,toggleFullscreen:Et,hideContextMenu:Ue,showHotKeyHelpers:Je,showKeyMap:ei,get isAds(){return n(En)},get fakePlayButtonHandler(){return n(Es)},get nextButtonActive(){return Y()},get prevButtonActive(){return Pe()},children:(he,wt)=>{var ci=XC(),Zt=ue(ci);fl(Zt,{get hideCursor(){return n(Sn)},onClick:Yn,onContextMenu:mi,onMouseDown:Gn,onMouseUp:Qr,onDblClick:Gr,get videoContainer(){return Vt()},set videoContainer(Qo){Vt(Qo)}});var Lo=k(Zt,2);Fa(Lo,()=>"slot",!1,(Qo,ks)=>{no(Qo,()=>({name:pl}))});var po=k(Lo,2);Ns(po,K,Qo=>{var ks=jC(),Yr=ue(ks);let kr=f(()=>a()!=="thumb"||s()||Vi&&e.autoplay);dl(Yr,{get hidden(){return n(kr)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart},onContextMenu:mi,onClick:ln});var xa=k(Yr,2);{var js=ze=>{sg(ze,{})};V(xa,ze=>{se()&&ze(js)})}var wa=k(xa,2);ng(wa,{});var jr=k(wa,2);rg(jr,{get isVisible(){return P()}});var Pn=k(jr,2);{var gl=ze=>{let $i=f(()=>{var fo;return(fo=e.live)==null?void 0:fo.startTime});Vc(ze,{get thumbUrl(){return e.thumbUrl},get startTime(){return n($i)},onUpcomingLiveViewStateChanged:ya,onContextMenu:mi,onClick:ln})};V(Pn,ze=>{a()==="LiveWaitingStart"&&ze(gl)})}var Sa=k(Pn,2);{var Xr=ze=>{cl(ze,{kind:"recover",get thumbUrl(){return e.thumbUrl},onContextMenu:mi,onClick:ln})};V(Sa,ze=>{a()==="LiveWaitingRecover"&&ze(Xr)})}var hl=k(Sa,2);{var hd=ze=>{cl(ze,{kind:"record",get thumbUrl(){return e.thumbUrl},onContextMenu:mi,onClick:ln})};V(hl,ze=>{a()==="LiveWaitingRecord"&&ze(hd)})}var Ca=k(hl,2);{var _d=ze=>{var $i=qC();let fo;var Ar=C($i);tc(Ar,{get adsSlotId(){return pt()},get adsParams(){return At()},get adsAutoplayParam(){return ti()},get duration(){return Lt()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S($i),O(dn=>fo=oe($i,1,"ads-container s-8",null,fo,dn),[()=>({hidden:a()!=="ads"})]),$(ze,$i)};V(Ca,ze=>{e.showAds&&fe()&&ze(_d)})}var _l=k(Ca,2);{var bl=ze=>{let $i=f(()=>!Ct()&&e.showAutoplayNext&&x());wm(ze,{get title(){return le()},get thumb(){return $e()},get isHide(){return n($i)},clickCloseIcon:()=>N(Nt,!0)})};V(_l,ze=>{n(So)&&le()&&$e()&&ze(bl)})}var Ta=k(_l,2);{var mt=ze=>{let $i=f(()=>_()?"md":"sm"),fo=f(()=>{var Ar;return(Ar=e.store.callbacks)==null?void 0:Ar.onTitleClicked});Av(ze,{get title(){return e.title},get isHidden(){return n(ft)},onVisibilityChanged:Ys,get titleLinkHref(){return n(di)},onMouseEnter:()=>{N(ps,!0)},onMouseLeave:()=>{N(ps,!1)},get size(){return n($i)},get onTitleClicked(){return n(fo)},get ref(){return n(Is)},set ref(Ar){N(Is,Ar,!0)}})};V(Ta,ze=>{n(Tr)&&ze(mt)})}var rt=k(Ta,2);{var to=ze=>{let $i=f(()=>a()==="video"&&v());Lc(ze,{get isShifted(){return n($i)}})};V(rt,ze=>{X()&&ze(to)})}var Mo=k(rt,2);{var io=ze=>{var $i=QC(),fo=C($i);Jd(fo,{}),S($i),$(ze,$i)};V(Mo,ze=>{xe()&&ze(io)})}var bi=k(Mo,2);{var Gi=ze=>{Mc(ze,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return He()},onClick:Yn,onContextMenu:mi,onDblClick:Gr})};V(bi,ze=>{ee()&&ze(Gi)})}var Xs=k(bi,2);{var bd=ze=>{al(ze,{get shifted(){return v()},get captions(){return ne()},get position(){return ce()},get playerSize(){return U()}})};V(Xs,ze=>{it().value!=="off"&&ze(bd)})}var Zc=k(Xs,2);{var qp=ze=>{var $i=GC();$i.__contextmenu=mi,$i.__click=[KC,Z,nt,m,xi,Ue];var fo=C($i);ll(fo,{}),S($i),$(ze,$i)};V(Zc,ze=>{s()&&ze(qp)})}var Jc=k(Zc,2);{var Qp=ze=>{let $i=f(()=>a()==="thumb"||a()==="LiveWaitingStart"||a()==="LiveWaitingRecover"||a()==="LiveWaitingRecord"),fo=f(()=>a()==="ads"),Ar=f(()=>e.canRewindLive&&Ne()!==0);kc(ze,{get bottomHidden(){return n($i)},get bottomNoSmooth(){return z()},get showControls(){return v()},get isAds(){return n(fo)},get canRewindLive(){return n(Ar)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return Ft()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return qt()},get nextButtonActive(){return Y()},get prevButtonActive(){return Pe()},get isOneVideoPlaylist(){return Ve()},customFullscreenSupported:lr,toggleFullscreen:Et,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get playerControlsWrapperRef(){return n(xr)},set playerControlsWrapperRef(dn){N(xr,dn,!0)},get playerControlsRef(){return n(zi)},set playerControlsRef(dn){N(zi,dn,!0)}})};V(Jc,ze=>{fe()&&ze(Qp)})}var eu=k(Jc,2);{var Gp=ze=>{var $i=YC(),fo=C($i);let Ar=f(()=>{var dn;return(dn=n(zi))==null?void 0:dn.clientHeight});Oc(fo,{get supportLink(){return e.supportLink},get playerControlsHeight(){return n(Ar)},returnFocus:()=>{var dn;return(dn=Xt())==null?void 0:dn.focus()},get ref(){return n(wr)},set ref(dn){N(wr,dn,!0)}}),S($i),$(ze,$i)};V(eu,ze=>{!ee()&&a()!=="ads"&&ze(Gp)})}var tu=k(eu,2);let Yp=f(()=>!n(Cr));nc(tu,{get isLive(){return Le()},get isHidden(){return n(Yp)},get isPlaying(){return et()},get position(){return ce()},get duration(){return Ne()}});var Ia=k(tu,2);Pv(Ia,{get data(){return $n}});var iu=k(Ia,2);ym(iu,{get supportLink(){return e.supportLink},returnFocus:()=>{var ze;return(ze=Xt())==null?void 0:ze.focus()},get visible(){return Z()},get playerContainerRef(){return n(xo)},get position(){return Ee()},get menuElementRef(){return n(jn)},set menuElementRef(ze){N(jn,ze,!0)}});var Zs=k(iu,2);{var $l=ze=>{Bc(ze,{onClose:zn,onSelectAutoQuality:()=>{Ss("auto"),zn()}})};V(Zs,ze=>{n(Wr)&&ze($l)})}var ou=k(Zs,2);{var nu=ze=>{ag(ze,{})};V(ou,ze=>{Te()&&ze(nu)})}var yl=k(ou,2);{var ru=ze=>{Xa(ze,{})};V(yl,ze=>{n(sr)&&ze(ru)})}var su=k(yl,2);{var au=ze=>{Pm(ze,{})};V(su,ze=>{Fe()&&ze(au)})}var jp=k(su,2);{var Xp=ze=>{lc(ze,{})};V(jp,ze=>{kt()&&ze(Xp)})}$(Qo,ks)}),$(he,ci)},$$slots:{default:!0}}),he=>Xt(he),()=>Xt());var Ps=k(In,2);Xe(Ps,he=>N(wo,he),()=>n(wo)),S(Si),Xe(Si,he=>N(xo,he),()=>n(xo));var Qi=k(Si,2);{var ki=he=>{var wt=ZC();$(he,wt)};V(Qi,he=>{Tt()&&he(ki)})}ut("mouseenter",Si,zo),ut("mouseleave",Si,Wo),ut("click",Si,wi,!0),ut("focusin",Si,Io,!0),$(i,Ao),H(),o()}Ye(["mousemove","contextmenu","click"]);var ba=require("@vkontakte/videoplayer-core/es2015"),w$=require("@vkontakte/videoplayer-shared/es2015");var tT=L('<div></div> <div class="info s-j"><div class="triangles-wrapper s-j"><div></div> <div></div> <div></div></div> <p class="step-caption s-j"> </p></div>',1),iT=L("<div><!></div>"),oT={hash:"s-j",code:".double-click-area.s-j{height:100%;overflow:hidden;position:absolute;top:0;width:25%}.double-click-area.left.s-j{left:0}.double-click-area.right.s-j{right:0}.semicircle.s-j{background-color:rgba(0,0,0,.5);height:100%;position:absolute;top:0;width:100%}.semicircle.left.s-j{border-bottom-right-radius:50%;border-top-right-radius:50%;left:0}.semicircle.right.s-j{border-bottom-left-radius:50%;border-top-left-radius:50%;right:0}.info.s-j{align-items:center;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%)}.info.s-j,.triangles-wrapper.s-j{display:flex;justify-content:center}.triangles-wrapper.s-j{margin-bottom:10px;position:relative}.triangle.s-j{animation:s-j-blink .5s infinite;border-bottom:6px solid transparent;border-top:6px solid transparent;height:0;opacity:0;width:0}.triangle.left.s-j:nth-child(3),.triangle.right.s-j:first-child{animation-delay:0s}.triangle.left.s-j:nth-child(2),.triangle.right.s-j:nth-child(2){animation-delay:.1s}.triangle.left.s-j:first-child,.triangle.right.s-j:nth-child(3){animation-delay:.2s}@keyframes s-j-blink{0%{opacity:0}50%{opacity:1}to{opacity:0}}.triangle.left.s-j{border-right:8px solid var(--white)}.triangle.right.s-j{border-left:8px solid var(--white)}.triangle.s-j:not(:last-child){margin-right:5px}.step-caption.s-j{color:var(--white);font-size:12px;line-height:1;margin:0;text-align:center}"};function Pp(i,e){B(e,!0),Q(i,oT);let t=h(e,"seekStep",3,0),o=q(!1),r=0,a=0,l=q(ui(t())),d=p=>{p.stopPropagation(),a+=1,N(l,t()*(a-1)),a===1?e.handleSingleFirstClick(p):(N(o,!0),e.handleSecondClick()),window.clearTimeout(r),r=window.setTimeout(()=>{a=0,N(o,!1)},300)};pn(()=>{window.clearTimeout(r)});var s=iT();s.__click=d;var u=C(s);{var m=p=>{var v=tT(),b=ue(v),y=k(b,2),_=C(y),x=C(_),I=k(x,2),T=k(I,2);S(_);var R=k(_,2),A=C(R,!0);S(R),S(y),O(P=>{var E,z,F,U;oe(b,1,`semicircle ${(E=e.side)!=null?E:""}`,"s-j"),oe(x,1,`triangle ${(z=e.side)!=null?z:""}`,"s-j"),oe(I,1,`triangle ${(F=e.side)!=null?F:""}`,"s-j"),oe(T,1,`triangle ${(U=e.side)!=null?U:""}`,"s-j"),ve(A,P)},[()=>j("doubletap_seek_step",{seconds:n(l).toFixed(0)})]),$(p,v)};V(u,p=>{n(o)&&p(m)})}S(s),O(()=>{var p;return oe(s,1,`double-click-area ${(p=e.side)!=null?p:""}`,"s-j")}),$(i,s),H()}Ye(["click"]);var nT=(i,e,t)=>{e(!1),t()},rT=L('<div class="overlay s-i"></div> <div class="next-video s-i"><div class="top s-i"><div class="caption s-i"> </div> <!></div> <div class="row s-i"><div class="column s-i"><div class="thumb s-i"><div></div> <!></div></div> <div class="column s-i"><div class="title s-i"> </div></div></div></div>',1),sT={hash:"s-i",code:".overlay.s-i{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-i{display:flex;flex-direction:column;left:50%;margin:0 auto;max-width:362px;min-width:320px;padding-bottom:12px;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:var(--end-screen-mobile-z-index)}.top.s-i{display:flex;justify-content:space-between}.caption.s-i{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-i{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-i{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-i{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-i,.thumb-overlay.s-i{height:100%;width:100%}.thumb-overlay.s-i{position:absolute}.thumb-overlay.withOpacity.s-i{background:var(--black);opacity:.3}.title.s-i{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function cg(i,e){B(e,!0),Q(i,sT);let[t,o]=De(),r=()=>w(d,"$autoplayNextEnabled$",t),a=()=>w(s,"$timerNextVideoRunning$",t),l=be(),d=l.ui.autoplayNextEnabled$,s=l.ui.timerNextVideoRunning$,u=l.actions.internal.nextVideoClick,m=l.actions.internal.nextVideoAnnouncementShow,p=l.actions.internal.nextVideoAnnouncementClick,v=l.actions.internal.nextVideoAnnouncementAuto,b=l.actions.internal.nextVideoAnnouncementCancel,y=()=>{u(!1),v()},_=()=>{e.clickCloseIcon(),b()};Dt(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Me(),I=ue(x);{var T=R=>{var A=rT(),P=k(ue(A),2),E=C(P),z=C(E),F=C(z,!0);S(z);var U=k(z,2);Hs(U,{onClick:_}),S(E);var X=k(E,2);X.__click=[nT,u,p];var ae=C(X),Z=C(ae),re=C(Z);let J;var we=k(re,2);{var me=ge=>{dc(ge,{get isRunning(){return a()},onTimerEnded:y})};V(we,ge=>{r()&&ge(me)})}S(Z),S(ae);var ee=k(ae,2),_e=C(ee),Ce=C(_e,!0);S(_e),S(ee),S(X),S(P),O((ge,pe)=>{ve(F,ge),qe(Z,`background-image: url('${e.thumb}')`),J=oe(re,1,"thumb-overlay s-i",null,J,pe),ve(Ce,e.title)},[()=>r()?j("end_screen_next_video"):j("end_screen_recommended_video"),()=>({withOpacity:r()})]),$(R,A)};V(I,R=>{e.isHide||R(T)})}$(i,x),H(),o()}Ye(["click"]);var _$=require("@vkontakte/videoplayer-core/es2015");var b$=({getFullscreenTarget:i,fullScreenChangeHandler:e})=>{let t=null,o;Dt(()=>{_$.clientChecker.device.isIOS&&(o=setTimeout(()=>{let a=i().querySelector("video");if(!a)return;let l=()=>e(!0),d=()=>e(!1);a.addEventListener("webkitbeginfullscreen",l),a.addEventListener("webkitendfullscreen",d),t=()=>{a.removeEventListener("webkitbeginfullscreen",l),a.removeEventListener("webkitendfullscreen",d)}},0))}),pn(()=>{t==null||t(),clearTimeout(o)})};var $$=require("@vkontakte/videoplayer-core/es2015");var kp=class{constructor(e){this.video=e}getTracksArray(){return Array.from(this.video.getElementsByTagName("track"))}attach(e,t=!1){let o=document.createElement("track");o.setAttribute("src",e.url),o.setAttribute("id",e.id),e.label&&o.setAttribute("label",e.label),e.language&&o.setAttribute("srclang",e.language),t&&(o.track.mode="showing"),this.video.appendChild(o)}detachAll(){for(let e of this.getTracksArray())this.video.removeChild(e)}updateSrc(e){let t=this.getTracksArray().find(o=>o.id===e.id);t&&(t.src=e.url)}getCurrentShowingId(){var e,t;return(t=(e=this.getTracksArray().find(o=>o.track.mode==="showing"))==null?void 0:e.id)!=null?t:null}};var y$=require("@vkontakte/videoplayer-core/es2015"),x$=({store:i,getFullscreenTarget:e})=>{let{isFullscreen:t}=i.ui,{setSubtitle:o}=i.actions.internal,{currentSubtitle$:r,availableSubtitlesList$:a,currentFormat$:l,availableTextTracks$:d}=i.state,s=null,u=()=>e().querySelector("video"),m=()=>y$.clientChecker.device.isIOS&&ye(l)===$$.VideoFormat.DASH_LIVE_CMAF,p=()=>{s==null||s(),s=null},v=b=>{if(p(),!m()||!b)return;let y=u();if(!y)return;let _=new kp(y),x=ye(d),I=ye(a),T=ye(r);for(let P of x)I.some(z=>z.value===P.id)&&_.attach(P,T.value===P.id);let R=d.subscribe(P=>{for(let E of P)_.updateSrc(E)}),A=()=>{let P=_.getCurrentShowingId();o(ye(a).find(E=>E.value===P))};y.textTracks.addEventListener("change",A),s=()=>{R(),_.detachAll(),y.textTracks.removeEventListener("change",A)}};Dt(()=>t.subscribe(v)),pn(p)};var aT=(i,e,t,o)=>{if(i.stopPropagation(),e()){o();return}},lT=L("<!> <!>",1),dT=L("<div><!></div>"),cT=L('<div class="spherical-video-icon s-7"><!></div>'),uT=L("<div><!></div>"),pT=L('<div class="settings-mobile s-7"><!></div>'),fT=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),mT=L('<div class="player-wrapper s-7" role="region" tabindex="-1"><!> <!> <!> <div class="overlay-container"></div></div>'),vT={hash:"s-7",code:".player-wrapper.s-7{height:100%;position:absolute;width:100%}.player-wrapper.s-7 .player-media{background:var(--black);height:100%;left:0;position:absolute;top:0;transition:transform .2s ease-in-out;width:100%}.spherical-video-icon.s-7{display:inline-block;left:calc(50% - 38px);position:absolute;top:calc(50% - 23px)}.ads-container.s-7{background:var(--black);height:100%;left:0;position:absolute;top:0;width:100%;z-index:var(--ads-container-z-index)}.settings-mobile.s-7{align-items:center;display:flex;left:50%;max-width:320px;position:absolute;top:50%;transform:translate(-50%,-50%);transition:opacity var(--controls-transition-duration);width:90%;z-index:var(--settings-menu-z-index)}"};function ug(i,e){var wn,Tr;B(e,!0),Q(i,vT);let[t,o]=De(),r=()=>w(Ve,"$playerPhase",t),a=()=>w(fi,"$isLoaderVisible",t),l=()=>w(Pe,"$adPlaybackState",t),d=()=>w(oi,"$crashed",t),s=()=>w(Ss,"$notificationsToShow$",t),u=()=>w(Y,"$playbackState$",t),m=()=>w(Lt,"$graphIsOpened$",t),p=()=>w(Be,"$interactiveHideMobileControls",t),v=()=>w(Bi,"$isEnded$",t),b=()=>w(gt,"$isInteractiveExpectation$",t),y=()=>w(St,"$controlsVisible",t),_=()=>w(st,"$touched",t),x=()=>w(Mi,"$autoplayNextEnabled$",t),I=()=>w(vi,"$postrollPassed",t),T=()=>w(Ur,"$bottomNoSmooth",t),R=()=>w(nt,"$videoSize",t),A=()=>w(bt,"$playerSize",t),P=()=>w(dt,"$isFullscreen",t),E=()=>w(le,"$position$",t),z=()=>w($e,"$duration$",t),F=()=>w(vn,"$loadedMetadata",t),U=()=>w(We,"$settingsMenuVisible",t),X=()=>w(Xt,"$scrubbingInProgress",t),ae=()=>w(It,"$volumeChangingInProgress",t),Z=()=>w(Bt,"$chromecastConnected$",t),re=()=>w(fe,"$isControlsAvailable",t),J=()=>w(li,"$isInteractiveTime$",t),we=()=>w(Hi,"$isActiveLive",t),me=()=>w(Ct,"$settingsMenuOpenedByKeyboard",t),ee=()=>w(qt,"$language$",t),_e=()=>w(xt,"$disabledControls$",t),Ce=()=>w(Ut,"$is3DVideo",t),ge=()=>w(W,"$icon3DVideoVisible",t),pe=()=>w(_o,"$chromecastDeviceName$",t),Qe=()=>w(Ei,"$currentSubtitle$",t),G=()=>w(tn,"$currentSubtitleCaptions$",t),D=()=>w(Bo,"$realDuration$",t),Ge=()=>w(ot,"$isLive$",t),K=()=>w(Jt,"$isPlaying$",t),se=()=>w(ai,"$debugPanelVisible",t),xe=h(e,"videoContainer",15),He=h(e,"adsSlotId",3,void 0),it=h(e,"adsParams",3,void 0),ne=h(e,"adsAutoplayParam",3,void 0),ce=h(e,"duration",3,void 0),Ne=h(e,"logoTargetUrl",3,""),Le=h(e,"showNextPrevButtons",3,!1),et=h(e,"nextButtonActive",3,!1),Ee=h(e,"prevButtonActive",3,!1),Te=h(e,"endScreenVideoTitle",3,void 0),Fe=h(e,"endScreenVideoThumb",3,void 0),kt=h(e,"isOneVideoPlaylist",3,!1),Tt=h(e,"showMiniTimer",3,!1),Vt=h(e,"fullScreenTarget",3,void 0),pt=h(e,"playerStarted",3,!1),At=h(e,"showEndScreen",3,!0),{notifications$:ti,graphIsOpened$:Lt}=yo(),Ft=e.store.getLogger().createComponentLog("Root component"),qt=e.store.interfaceLanguage$,Y=e.store.state.playbackState$,Pe=e.store.ads.playbackState,le=e.store.state.positionWithScrubbing$,$e=e.store.state.duration$,Ve=e.store.playerPhase,dt=e.store.ui.isFullscreen,St=e.store.ui.controlsVisible,fe=e.store.ui.isControlsAvailable,Be=e.store.ui.interactiveHideMobileControls,We=e.store.ui.settingsMenu.visible$,Ct=e.store.ui.settingsMenu.openedByBtnKeyboard$,Xt=e.store.ui.scrubbingInProgress,It=e.store.ui.volumeChangingInProgress,ai=e.store.ui.debugPanelVisible,fi=e.store.state.isLoaderVisible,Bi=e.store.state.isEnded$,Bt=e.store.state.chromecastConnected$,_o=e.store.state.chromecastDeviceName$,vi=e.store.ads.postrollPassed,ot=e.store.state.isLive$,Jt=e.store.state.isPlaying$,Hi=e.store.state.isActiveLive$,xi=e.store.state.isRewindableLive$,oi=e.store.state.crashed$,Ti=e.store.webApi.annotationsApi,lt=e.store.webApi.pictureInPictureApi,nt=e.store.state.videoSize$,Ei=e.store.state.currentSubtitle$,tn=e.store.state.currentSubtitleCaptions$,Bo=e.store.state.duration$,bt=e.store.ui.playerSize,Ut=e.store.ui.is3DVideo,W=e.store.ui.icon3DVideoVisible,Rt=e.store.state.isInteractive,li=e.store.state.isInteractiveTime$,gt=e.store.state.isInteractiveExpectation$,ii=e.store.state.hasInteractiveBranches,xt=e.store.ui.controls.disabledControls$,st=e.store.ui.touched,Fi=e.store.ui.overlayContainer$,Mi=e.store.ui.autoplayNextEnabled$,vn=e.store.state.loadedMetadata$,gn=e.store.actions.internal.closeSettingsMenu,Vi=(wn=e.store.callbacks)==null?void 0:wn.onDisabledPlayPrevChapterClick,Ui=(Tr=e.store.callbacks)==null?void 0:Tr.onDisabledSeekToInteractiveClick,Hn=e.store.actions.internal.setQuality,bo=q(void 0),lo=q(void 0),Ai=q(void 0),Ho=q(void 0),Fo,hn,Or=f(()=>(r()==="video"&&a()||r()==="ads"&&l()==="inactive")&&!d()),Br=q(void 0),{closeNotification:Hr,notificationsToShow$:Ss}=ti,Fr=f(()=>!!s().slow_video),nr=()=>Hr("slow_video"),Ur=de(!1),_n,bn=q(!1),_r=f(()=>u()!==ba.PlaybackState.PLAYING),br=q(!1),on=f(()=>m()||p()||!n(bn)&&(v()&&!!ii||n(_r)&&b())),$r=q(!0),yr=f(()=>e.uiConfig.features.thumbTimer&&Tt()&&r()==="video"&&!y()&&!d()&&!Rt&&(e.uiConfig.hideThumbTimerAfterTouch&&!_()||!e.uiConfig.hideThumbTimerAfterTouch)),rr=q(!1),Fn=f(()=>(At()||e.showAutoplayNext&&x())&&!!Te()&&!!Fe()&&(e.showAds&&I()||!e.showAds)&&v()&&!d()&&!n(rr)),cs=q(!1);lt==null||lt.setContext(Cd());let xo=ft=>{ft&&!Rt&&zi(e.uiConfig.controls.hideTimeoutMobile)};e.store.setUiCallbacks({onStarted:xo});let xr=()=>{clearTimeout(Fo),N(bn,!1),p()&&Be.set(!1)},zi=ft=>{xr(),N(bn,!0),Fo=setTimeout(()=>N(bn,!1),ft);let Nt=ft-100;_n=setTimeout(()=>{T()&&Ur.set(!1)},Nt>0?Nt:ft)},wr=Ut.subscribe(ft=>{W.set(ft),ft&&(clearTimeout(hn),hn=setTimeout(()=>W.set(!1),e.uiConfig.controls.hide360IconTimeout))}),Un=(...Nt)=>ht(null,[...Nt],function*(ft=ca()){var So,Sn,Co,sn,co,To;if(ft&&!ba.clientChecker.device.isIOS){let Pi=ec(),Kr=zn(),qn=ba.clientChecker.browser.isSamsungBrowser&&Pi===e.shadowRootContainer;ft=Pi===Kr||qn}if(ft){zi(e.uiConfig.controls.hideTimeoutFullscreen);try{yield lt==null?void 0:lt.exit()}catch(Pi){Ft({message:String(Pi)})}try{let Pi=(So=R())!=null&&So.width&&((Sn=R())!=null&&Sn.height)?R():A();yield lb(Pi)}catch(Pi){Ft({message:String(Pi)})}}dt.set(ft),e.store.getAdmanWrapper().setFullscreen(ft),P()?(sn=(Co=e.store.callbacks)==null?void 0:Co.onFullscreenEnter)==null||sn.call(Co):(To=(co=e.store.callbacks)==null?void 0:co.onFullscreenExit)==null||To.call(co)}),vt=ft=>{bt.set(ft)},ni=()=>{if(n(bo)){let{width:ft,height:Nt}=n(bo).getBoundingClientRect();bt.set({width:ft,height:Nt})}};Dt(()=>{var ft;return Ju(Un),e.uiConfig.features.annotationsInside&&(Ti==null||Ti.init(n(bo))),lt==null||lt.assignPlayerContainer(n(bo)),lt==null||lt.setExternalEventHandlers({resize:vt,leavepictureinpicture:ni}),N($r,!ba.clientChecker.device.isIphoneOrOldIpad),e.interactiveContainer&&((ft=xe().parentElement)==null||ft.insertBefore(e.interactiveContainer,xe().nextSibling)),()=>{clearTimeout(Fo),clearTimeout(_n),clearTimeout(hn),wr(),lt==null||lt.dispose().catch(Nt=>{Ft({message:String(Nt)})}),ep(Un)}});let Sr=q(!0),zr=q(!0),Wr=ft=>{let Nt=E()+(ft==="forward"?1:-1)*e.uiConfig.controls.seekStepMobile/1e3;Nt<0?(N(Sr,!1),Nt=0):Nt>=z()&&(N(zr,!1),Nt=z()),N(br,!0),e.seekTime(Nt)},zn=()=>ba.clientChecker.device.isIOS?n(bo):!e.uiConfig.allowChangingFullscreenTarget||!Vt()?e.outerContainerRef:Vt().contains(e.outerContainerRef)?Vt():e.outerContainerRef,sr=()=>ht(null,null,function*(){try{if(ca())yield Zu(document),Ft({message:"exit fullscreen"});else{if(Ft({message:"request fullscreen"}),ba.clientChecker.device.isIOS&&!F())return;yield Xu(zn())}}catch(ft){Ft({message:String(ft)})}}),wo=()=>{gn()},Wn=ft=>{if(ft.preventDefault(),U()){wo();return}if(!pt()){e.firstStart(),zi(e.uiConfig.controls.hideTimeoutCursor);return}N(br,!1),y()?xr():zi(e.uiConfig.controls.hideTimeoutMobile)},ar=()=>{st.set(!0)},Kn=()=>{Rt||(Ur.set(!0),zi(e.uiConfig.controls.hideTimeoutCursor))},$n=ft=>{Vi&&(Vi(ft),zi(e.uiConfig.controls.hideTimeoutMobile))},yn=ft=>{Ui&&(Ui(ft),zi(e.uiConfig.controls.hideTimeoutMobile))};Oe(()=>{Fi.set(n(Br))}),Oe(()=>{St.set((n(_r)||U()||X()||ae()||Z()||!n(Fn)&&(v()||n(bn)&&!n(br)))&&!n(on)&&r()==="video"&&!d()&&re())}),Oe(()=>{!X()&&n(cs)&&!J()&&zi(e.uiConfig.controls.hideTimeoutMobile),N(cs,X(),!0)}),Oe(()=>{N(Sr,E()>0),N(zr,!we()&&E()<z(),!0)}),Oe(()=>{sc(n(Ho),U(),me(),!0)});let xn=j("aria_label_video_player");b$({fullScreenChangeHandler:Un,getFullscreenTarget:zn}),x$({store:e.store,getFullscreenTarget:zn});let nn=(ft,Nt)=>{var sn,co;let So=(co=(sn=e.store.callbacks)==null?void 0:sn.uiInfo)==null?void 0:co.onUpcomingLiveViewStateChanged;if(!So)return;let Sn=!!Nt,Co=ke(ke({},ir(n(bo),{upcomingLiveScreen:Nt},"upcomingLiveScreen",Sn)),ft);So(Co)};var Wi=mT();ut("blur",Ra,wo);var eo=C(Wi);fl(eo,{onClick:Wn,get videoContainer(){return xe()},set videoContainer(ft){xe(ft)}});var rn=k(eo,2);Fa(rn,()=>"slot",!1,(ft,Nt)=>{no(ft,()=>({name:pl}))});var lr=k(rn,2);Ns(lr,ee,ft=>{var Nt=fT(),So=ue(Nt);let Sn=f(()=>r()!=="thumb"||d()||Rt&&e.autoplay||e.uiConfig.features.disableThumbUnstartedOnAutoplay&&e.autoplay);dl(So,{get hidden(){return n(Sn)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart}});var Co=k(So,2);{var sn=Je=>{var ei=lT(),wi=ue(ei);{var ko=qo=>{let dr=f(()=>e.uiConfig.controls.seekStepMobile/1e3);Pp(qo,{side:"left",get seekStep(){return n(dr)},handleSingleFirstClick:Wn,handleSecondClick:()=>Wr("backward")})};V(wi,qo=>{n(Sr)&&qo(ko)})}var Tn=k(wi,2);{var jn=qo=>{let dr=f(()=>e.uiConfig.controls.seekStepMobile/1e3);Pp(qo,{side:"right",get seekStep(){return n(dr)},handleSingleFirstClick:Wn,handleSecondClick:()=>Wr("forward")})};V(Tn,qo=>{n(zr)&&qo(jn)})}$(Je,ei)};V(Co,Je=>{e.canRewindLive&&xi&&!_e().has("TIMELINE")&&Je(sn)})}var co=k(Co,2);{var To=Je=>{let ei=f(()=>{var wi;return(wi=e.live)==null?void 0:wi.startTime});Vc(Je,{get thumbUrl(){return e.thumbUrl},get startTime(){return n(ei)},onUpcomingLiveViewStateChanged:nn})};V(co,Je=>{r()==="LiveWaitingStart"&&Je(To)})}var Pi=k(co,2);{var Kr=Je=>{cl(Je,{kind:"recover",get thumbUrl(){return e.thumbUrl}})};V(Pi,Je=>{r()==="LiveWaitingRecover"&&Je(Kr)})}var qn=k(Pi,2);{var Cs=Je=>{cl(Je,{kind:"record",get thumbUrl(){return e.thumbUrl}})};V(qn,Je=>{r()==="LiveWaitingRecord"&&Je(Cs)})}var Ki=k(qn,2);{var Ts=Je=>{var ei=dT();let wi;var ko=C(ei);tc(ko,{get adsSlotId(){return He()},get adsParams(){return it()},get adsAutoplayParam(){return ne()},get duration(){return ce()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S(ei),O(Tn=>wi=oe(ei,1,"ads-container s-7",null,wi,Tn),[()=>({hidden:r()!=="ads"})]),$(Je,ei)};V(Ki,Je=>{e.showAds&&pt()&&Je(Ts)})}var us=k(Ki,2);{var Ir=Je=>{let ei=f(()=>!At()&&e.showAutoplayNext&&x());cg(Je,{get title(){return Te()},get thumb(){return Fe()},get isHide(){return n(ei)},clickCloseIcon:()=>N(rr,!0)})};V(us,Je=>{n(Fn)&&Te()&&Fe()&&Je(Ir)})}var Uo=k(us,2);{var qr=Je=>{Lc(Je,{})};V(Uo,Je=>{Ce()&&Je(qr)})}var an=k(Uo,2);{var ln=Je=>{var ei=cT(),wi=C(ei);Jd(wi,{}),S(ei),$(Je,ei)};V(an,Je=>{ge()&&Je(ln)})}var Ue=k(an,2);{var Et=Je=>{Mc(Je,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return pe()},onClick:Wn})};V(Ue,Je=>{Z()&&Je(Et)})}var mi=k(Ue,2);{var zo=Je=>{al(Je,{get shifted(){return y()},get captions(){return G()},get position(){return E()},get playerSize(){return A()},isMobile:!0})};V(mi,Je=>{Qe().value!=="off"&&Je(zo)})}var Io=k(mi,2);{var Wo=Je=>{var ei=uT();ei.__click=[aT,U,We,wo];var wi=C(ei);ll(wi,{}),S(ei),$(Je,ei)};V(Io,Je=>{d()&&Je(Wo)})}var qi=k(Io,2);{var Eo=Je=>{let ei=f(()=>r()==="thumb"||r()==="LiveWaitingStart"||r()==="LiveWaitingRecover"||r()==="LiveWaitingRecord"||r()==="ads"),wi=f(()=>r()==="ads"),ko=f(()=>e.canRewindLive&&D()!==0);kc(Je,{get bottomHidden(){return n(ei)},get showControls(){return y()},get bottomNoSmooth(){return T()},get isAds(){return n(wi)},get canRewindLive(){return n(ko)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return Ne()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return Le()},get nextButtonActive(){return et()},get prevButtonActive(){return Ee()},get isOneVideoPlaylist(){return kt()},get customFullscreenSupported(){return n($r)},get endScreenShown(){return n(Fn)},toggleFullscreen:sr,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},onDisabledPlayPrevChapterClick:$n,onDisabledSeekToInteractiveClick:yn,get playerControlsWrapperRef(){return n(lo)},set playerControlsWrapperRef(Tn){N(lo,Tn,!0)},get playerControlsRef(){return n(Ai)},set playerControlsRef(Tn){N(Ai,Tn,!0)}})};V(qi,Je=>{pt()&&Je(Eo)})}var Qn=k(qi,2);{var Er=Je=>{var ei=pT(),wi=C(ei);Oc(wi,{get supportLink(){return e.supportLink},get returnFocus(){return w$.noop},get ref(){return n(Ho)},set ref(ko){N(Ho,ko,!0)}}),S(ei),$(Je,ei)};V(Qn,Je=>{U()&&Je(Er)})}var Po=k(Qn,2);let uo=f(()=>!n(yr));nc(Po,{get isLive(){return Ge()},get isHidden(){return n(uo)},get isPlaying(){return K()},get position(){return E()},get duration(){return z()}});var Cn=k(Po,2);{var Ko=Je=>{Xa(Je,{})};V(Cn,Je=>{n(Or)&&Je(Ko)})}var Gn=k(Cn,2);{var Qr=Je=>{lc(Je,{})};V(Gn,Je=>{se()&&Je(Qr)})}var Gr=k(Gn,2);{var Yn=Je=>{Bc(Je,{onClose:nr,onSelectAutoQuality:()=>{Hn("auto"),nr()}})};V(Gr,Je=>{n(Fr)&&Je(Yn)})}$(ft,Nt)});var Cr=k(lr,2);Xe(Cr,ft=>N(Br,ft),()=>n(Br)),S(Wi),Xe(Wi,ft=>N(bo,ft),()=>n(bo)),O(()=>Re(Wi,"aria-label",xn)),ut("click",Wi,ar,!0),ut("focusin",Wi,Kn,!0),$(i,Wi),H(),o()}Ye(["click"]);function Ap(i){let e="";return ao(i.timelineSliderFilledColor)&&(e+=`--timeline-slider-filled-bg:${i.timelineSliderFilledColor};`),ao(i.timelineSliderHandleColor)&&(e+=`--timeline-slider-handle-bg:${i.timelineSliderHandleColor};`),ao(i.timelineSliderLoadedColor)&&(e+=`--timeline-slider-loaded-bg:${i.timelineSliderLoadedColor};`),ao(i.timelineSliderColor)&&(e+=`--timeline-slider-bg:${i.timelineSliderColor};`),ao(i.volumeSliderColor)&&(e+=`--volume-slider-bg:${i.volumeSliderColor};`),ao(i.volumeSliderHandleColor)&&(e+=`--volume-slider-handle-bg:${i.volumeSliderHandleColor};`),ao(i.volumeSliderFilledColor)&&(e+=`--volume-slider-filled-bg:${i.volumeSliderFilledColor};`),ao(i.controlsTimeColor)&&(e+=`--controls-time:${i.controlsTimeColor};`),ao(i.timelineSliderFilledActiveLiveColor)&&(e+=`--timeline-slider-filled-active-live-bg:${i.timelineSliderFilledActiveLiveColor};`),ao(i.timelineSliderHandleActiveLiveColor)&&(e+=`--timeline-slider-handle-active-live-bg:${i.timelineSliderHandleActiveLiveColor};`),ao(i.buttonColor)&&(e+=`--btn-color:${i.buttonColor};`),ao(i.buttonToggleOnColor)&&(e+=`--toggle-color-on:${i.buttonToggleOnColor};`,e+=`--toggle-color-autoplay-on:${i.buttonToggleOnColor};`),ao(i.focusedColor)&&(e+=`--focused:${i.focusedColor};`),ao(i.focusedOutlineWidth)&&(e+=`--focused-outline-width:${i.focusedOutlineWidth};`),ao(i.focusedOutlineRadius)&&(e+=`--focused-outline-radius:${i.focusedOutlineRadius};`),ao(i.controlsDesktopPaddingHorizontal)&&(e+=`--controls-desktop-padding-horizontal:${i.controlsDesktopPaddingHorizontal};`),ao(i.timelinePaddingHorizontal)&&(e+=`--timeline-padding-horizontal:${i.timelinePaddingHorizontal};`),ao(i.settingsBackgroundColor)&&(e+=`--settings-bg:${i.settingsBackgroundColor};`),ao(i.font)&&(e+=`--font:${i.font};`),ao(i.controlsGradientHeight)&&(e+=`--controls-gradient-height:${i.controlsGradientHeight};`),ao(i.controlsGradient)&&(e+=`--controls-gradient:${i.controlsGradient};`),e.length&&e||void 0}function ao(i){return typeof i=="string"&&!i.includes(";")}var S$=require("@vkontakte/videoplayer-shared/es2015");var gT=L('<div class="time-container s-6"><!></div>'),hT=L('<div class="player-wrapper s-6" role="region"><!> <!> <!> <!> <!> <div><!></div></div>'),_T={hash:"s-6",code:".player-wrapper.s-6{height:100%;position:absolute;width:100%}.player-wrapper.s-6 .player-media{background:var(--black);height:100%;left:0;position:absolute;top:0;transition:transform .2s ease-in-out;width:100%}.timeline.s-6{bottom:0;left:0;opacity:0;opacity:1;position:absolute;transition:opacity var(--controls-transition-duration) var(--controls-transition-fn);width:100%;z-index:var(--controls-container-z-index)}.visible.s-6{opacity:1}.time-container.s-6{bottom:8px;position:absolute;right:8px;z-index:var(--thumb-timer-z-index)}"};function pg(i,e){B(e,!0),Q(i,_T);let[t,o]=De(),r=()=>w(J,"$scrubbingInProgress",t),a=()=>w(Z,"$playerSize",t),l=()=>w(E,"$isPlaying$",t),d=()=>w(A,"$duration$",t),s=()=>w(U,"$positionWithScrubbing$",t),u=()=>w(T,"$playerPhase",t),m=()=>w(R,"$crashed$",t),p=()=>w(z,"$currentSubtitle$",t),v=()=>w(F,"$currentSubtitleCaptions$",t),b=()=>w(P,"$positionExact$",t),y=()=>w(X,"$isLive$",t),_=()=>w(ae,"$isRewindableLive$",t),x=h(e,"outsideDuration",3,0),I=h(e,"videoContainer",15),{playerPhase:T,state:{crashed$:R,duration$:A,positionExact$:P,isPlaying$:E,currentSubtitle$:z,currentSubtitleCaptions$:F,positionWithScrubbing$:U,isLive$:X,isRewindableLive$:ae},ui:{playerSize:Z,controls:re,scrubbingInProgress:J},actions:{internal:{getVideoElement:we}}}=be(),me=8,ee=q(!1),_e=ui({}),Ce=q(!1),ge=f(()=>!r()&&!n(Ce)),pe=()=>{N(ee,!0)},Qe=()=>{N(ee,!1)},G=(0,S$.debounceFn)(rd,260);Oe(()=>{a(),G(we(),re,_e,n(ee))});let D=f(()=>l()?en(d()-s()):en(isFinite(d())?d():x()));var Ge=hT(),K=C(Ge);fl(K,{hideCursor:!1,get videoContainer(){return I()},set videoContainer(Te){I(Te)}});var se=k(K,2);Fa(se,()=>"slot",!1,(Te,Fe)=>{no(Te,()=>({name:pl}))});var xe=k(se,2);let He=f(()=>u()!=="thumb"||m());dl(xe,{get hidden(){return n(He)},get thumbUrl(){return e.thumbUrl},iconVisible:!1});var it=k(xe,2);{var ne=Te=>{al(Te,{shifted:!1,get captions(){return v()},get position(){return b()},get playerSize(){return a()}})};V(it,Te=>{p().value!=="off"&&n(ge)&&Te(ne)})}var ce=k(it,2);{var Ne=Te=>{var Fe=gT(),kt=C(Fe);oc(kt,{get isLive(){return y()},get isPlaying(){return l()},get time(){return n(D)}}),S(Fe),$(Te,Fe)};V(ce,Te=>{n(ge)&&Te(Ne)})}var Le=k(ce,2);let et;var Ee=C(Le);nl(Ee,{get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return _()},isAds:!1,needPadding:!1,isHidden:!1,withEpisodes:!1,tooltipLeftOffset:me,tooltipRightOffset:me,get ref(){return _e.timeline},set ref(Te){_e.timeline=Te}}),S(Le),S(Ge),O(Te=>et=oe(Le,1,"timeline s-6",null,et,Te),[()=>({visible:n(ee)})]),ut("mouseenter",Ge,pe),ut("mouseleave",Ge,Qe),ut("mouseenter",Le,()=>N(Ce,!0)),ut("mouseleave",Le,()=>N(Ce,!1)),$(i,Ge),H(),o()}var bT=L("<div><!></div>"),$T={hash:"s-0",code:'.vk-vp-root.s-0{--white:#fff;--black:#000;--red:#ff3347;--blue-light:#70c1ff;--black-alpha-40:rgba(0,0,0,.4);--white-alpha-24:hsla(0,0%,100%,.24);--white-alpha-72:hsla(0,0%,100%,.72);--devider-gray:#dce1e6;--text-gray:#626d7a;--font:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;--controls-height:40px;--controls-gradient-height:100px;--controls-transition-duration:0.25s;--controls-transition-fn:cubic-bezier(0.455,0.03,0.515,0.955);--controls-desktop-item-margin-left:4px;--controls-desktop-padding-horizontal:4px;--focused:var(--white);--focused-outline-width:2px;--focused-outline-radius:0;--focused-element-shadow:inset 0 0 0 var(--focused-outline-width) var(--focused);--focused-slider-shadow:0 0 0 2px var(--focused);--big-play-size:96px;--big-play-radius:50%;--big-play-bg-color:rgba(0,0,0,.5);--big-play-hover-bg-color:rgba(0,0,0,.6);--big-play-icon-width:38px;--big-play-icon-height:33px;--interactive-episode-complete:#5c9ce6;--slider-bg:hsla(0,0%,100%,.4);--slider-filled-bg:var(--white);--slider-handle-bg:var(--white);--slider-loaded-bg:hsla(0,0%,100%,.4);--slider-height:3px;--slider-video-episode-gap:1.5px;--slider-radius:0px;--slider-handle-size:12px;--slider-filled-ads:#67a5eb;--slider-disabled-color:hsla(0,0%,97%,.31);--slider-volume-height:5px;--slider-volume-radius:calc(var(--slider-volume-height)/2);--slider-volume-handle-size:13px;--timeline-slider-filled-active-live-bg:var(--red);--timeline-slider-handle-active-live-bg:var(--red);--timeline-slider-bg:var(--slider-bg);--timeline-slider-filled-bg:var(--slider-filled-bg);--timeline-slider-handle-bg:var(--slider-handle-bg);--timeline-slider-loaded-bg:var(--slider-loaded-bg);--volume-slider-bg:var(--slider-bg);--volume-slider-filled-bg:var(--slider-filled-bg);--volume-slider-handle-bg:var(--slider-handle-bg);--controls-time:var(--white);--controls-gradient:linear-gradient(180deg,transparent 0%,rgba(0,0,0,.005) 6.67%,rgba(0,0,0,.02) 13.33%,rgba(1,1,1,.04) 20%,rgba(1,1,1,.07) 26.67%,rgba(2,2,2,.11) 33.33%,rgba(3,3,3,.16) 40%,rgba(4,4,4,.22) 46.67%,rgba(6,6,6,.28) 53.33%,rgba(7,7,7,.33) 60%,rgba(8,8,8,.38) 66.67%,rgba(9,9,9,.42) 73.33%,rgba(9,9,9,.46) 80%,hsla(0,0%,4%,.48) 86.67%,hsla(0,0%,4%,.5));--timeline-preview-shadow:rgba(0,0,0,.08);--timeline-preview-bg:#222;--timeline-padding-horizontal:10px;--timeline-padding-vertical-top:3px;--timeline-padding-vertical-bottom:4px;--timeline-height:calc(var(--timeline-padding-vertical-bottom) + var(--timeline-padding-vertical-top) + var(--slider-height));--preview-track-frame-height-vertical:114px;--preview-track-frame-height-horizontal:65px;--preview-track-controls-top:16px;--preview-track-time-line-height:16px;--preview-track-bottom-offset:10px;--preview-track-height:calc(var(--preview-track-frame-height-vertical) + var(--preview-track-bottom-offset));--preview-track-controls-top-offset:calc(var(--timeline-height) + var(--preview-track-controls-top) + var(--preview-track-time-line-height));--settings-bg:rgba(0,0,0,.72);--settings-item-bg-hover:hsla(0,0%,100%,.08);--settings-radius:8px;--mobile-settings-bg:#2c2d2e;--divider-border:1px solid var(--white-alpha-24);--toggle-color-separator:#363738;--toggle-color-off:#656565;--toggle-color-on:#71aaeb;--toggle-color-autoplay-on:var(--white);--notification-bg:#2c2d2e;--notification-radius:8px;--button-hover-transition:opacity 0.2s;--video-container-z-index:0;--controls-container-z-index:1;--ads-container-z-index:1;--end-screen-mobile-z-index:1;--notification-z-index:1;--thumb-timer-z-index:2;--debug-panel-z-index:2;--modal-z-index:2;--settings-menu-z-index:2;--context-menu-z-index:3;--hot-key-helpers-container-z-index:3;--overlay-container-z-index:4;--rotate-transition-duration:0.25s;--btn-color:var(--white);--double-forward-bg:rgba(0,0,0,.6);background:var(--black);color:var(--white);font-family:var(--vk-vp-custom-font,var(--font));font-size:12px;height:100%;line-height:normal;outline:0;overflow:hidden;position:relative;user-select:none;width:100%}.vk-vp-root.visible-outside.s-0{overflow:visible}.vk-vp-root.s-0 *{-webkit-tap-highlight-color:transparent}.vk-vp-root.s-0 button{background:transparent;border:none;color:inherit;font:inherit;line-height:normal;margin:0;overflow:visible;padding:0;width:auto;-webkit-font-smoothing:inherit;-moz-osx-font-smoothing:inherit;-webkit-appearance:none;cursor:pointer}.vk-vp-root.s-0 p{margin:0}.vk-vp-root.s-0 svg:not(.interactive-root svg){pointer-events:none}.vk-vp-root.s-0 .interactive-root{font-family:var(--vk-vp-int-custom-font,inherit)}.vk-vp-root.s-0 :focus,.vk-vp-root.s-0 :focus-visible{outline:none}.vk-vp-root.s-0 :focus-visible{border-radius:var(--focused-outline-radius);box-shadow:var(--focused-element-shadow)}.vk-vp-root.s-0 .focus-hidden:focus-visible{box-shadow:none}.vk-vp-root.s-0 .hidden{opacity:0;visibility:hidden}.vk-vp-root.s-0 .out-of-flow{content-visibility:hidden!important}.vk-vp-root.s-0 .overlay-container{height:100%;left:0;pointer-events:none;position:fixed;top:0;width:100%;z-index:var(--overlay-container-z-index)}.vk-vp-root.s-0 .out-of-view{left:-1000vh!important;position:absolute!important}.vk-vp-root.s-0 .icon.icon-error-stub{align-items:center;display:flex;justify-content:center}'};function fg(i,e){B(e,!0),Q(i,$T);let[t,o]=De(),r=()=>w(pt,"$isLive$",t),a=()=>w(Ti,"$availableSubtitlesList$",t),l=()=>w(lt,"$isPreviewTrackHorizontallyAligned$",t),d=h(e,"sources",7),s=h(e,"store",7),u=h(e,"microStoresRoot",7),m=h(e,"videoConfig",7),p=h(e,"uiConfig",7),v=h(e,"title",7),b=h(e,"thumbUrl",7),y=h(e,"interactiveContainer",7),_=h(e,"interactiveController",7),x=h(e,"subtitles",7),I=h(e,"subtitlesForcedLanguage",7),T=h(e,"live",7),R=h(e,"preload",7),A=h(e,"autoplay",7),P=h(e,"volume",7,void 0),E=h(e,"muted",7,void 0),z=h(e,"fromTime",7),F=h(e,"canRewindLive",7),U=h(e,"showAds",7),X=h(e,"adsSlotId",7,void 0),ae=h(e,"adsParams",7,void 0),Z=h(e,"adsAutoplayParam",7,void 0),re=h(e,"duration",7,void 0),J=h(e,"logoClickable",7),we=h(e,"logoHidden",7),me=h(e,"isMobile",7),ee=h(e,"showNextPrevButtons",7,!1),_e=h(e,"nextButtonActive",7,!1),Ce=h(e,"prevButtonActive",7,!1),ge=h(e,"endScreenVideoTitle",7,void 0),pe=h(e,"endScreenVideoThumb",7,void 0),Qe=h(e,"isOneVideoPlaylist",7,!1),G=h(e,"supportLink",7),D=h(e,"shadowRootContainer",7),Ge=h(e,"outerContainerRef",7),K=h(e,"fullScreenTarget",7,void 0),se=h(e,"failoverHosts",7,void 0),xe=h(e,"showMiniTimer",7,!1),He=h(e,"saveRate",7),it=h(e,"seekToInteractive",7,ml.noop),ne=h(e,"playPrevChapter",7,ml.noop),ce=h(e,"volumeMultiplier",7),Ne=h(e,"showAutoplayNext",7),Le=h(e,"showEndScreen",7,!0),et=h(e,"keyboardControls",15,void 0),{subscribers:Ee,stores:Te}=u();g_(p());let Fe=Ot(),kt=p().logoLink,Tt=s().ui.debugPanelVisible,Vt=s().ui.playerSize,pt=s().state.isLive$,ti=s().state.isInteractive&&cd.clientChecker.device.isAndroid,Lt=q(void 0),Ft=null,qt=q(!1);s().getAdmanWrapper().init({switchFromAdsToVideo:s().actions.internal.switchFromAdsToVideo,switchFromVideoToAds:s().actions.internal.switchFromVideoToAds,setMuted:s().actions.external.setMuted},s().ads,{vsid:s().vsid}),I_(s(),Te),Oe(()=>{var W,Rt;s().ui.isMobile.set(me()),(Rt=(W=m().callbacks)==null?void 0:W.onDomReady)==null||Rt.call(W)});let Y=(W=!1)=>{N(qt,!0),W?s().actions.external.firstStart(U()):s().actions.internal.firstStart(U())},Pe=()=>{if(Fe.features.qualityDetailsSubMenuEnabled){let W=j_(s().videoId);if(W)switch(W.type){case"high_quality":s().actions.internal.setHighQualityEnabled(!0,W.appliesTo);break;case"traffic_saving":s().actions.internal.setTrafficSavingEnabled(!0,W.appliesTo);break;case"exact_quality":s().actions.internal.setQuality(W.quality);break}}else{X_(s().videoId),nm()&&s().actions.internal.setTrafficSavingEnabled(!0);let Rt=tm(s().videoId);Rt&&s().actions.internal.setQuality(Rt)}};function le(W){var xt,st,Fi;let Rt=d()||W;Rt&&s().initVideo({container:n(Lt),sources:Rt,failoverHosts:se(),subtitles:x(),subtitlesForcedLanguage:I(),volumeMultiplier:ce()});let li=ml.safeStorage.get(Qd)==="true";Tt.set(li),z()>0&&s().actions.external.seekTime(z());let gt=me()?Fe.volumeDefault:(st=(xt=P())!=null?xt:Uu())!=null?st:Fe.volumeDefault,ii=(Fi=E())!=null?Fi:W_();if(s().actions.external.setVolume(gt),s().actions.external.setMuted(ii),s().getAdmanWrapper().setInitialVolume(ii?0:gt),Pe(),Fe.features.saveRate&&He()){let Mi=Q_();Mi&&!r()&&s().actions.internal.setPlaybackRate(Mi)}if(Ne()){let Mi=Y_();Mi&&s().actions.internal.setAutoplayNextEnabled(Mi)}s().ui.isAutoplay.set(A()),A()&&Y(),R()&&Fe.features.preload&&s().actions.internal.preload()}let $e=W=>{if(window.ResizeObserver){let Rt,li;Ft=new ResizeObserver((0,ml.throttleFn)(gt=>{let ii=gt[0];if(ii.contentBoxSize){let xt=Array.isArray(ii.contentBoxSize)?ii.contentBoxSize[0]:ii.contentBoxSize;Rt=xt.inlineSize,li=xt.blockSize}else ii.contentRect&&(Rt=ii.contentRect.width,li=ii.contentRect.height);Vt.set({width:Rt,height:li})},300)),Ft.observe(W)}W.clientWidth&&W.clientHeight&&Vt.set({width:W.clientWidth,height:W.clientHeight})},Ve=()=>{document.hidden&&s().actions.external.stop()};Dt(()=>{var li,gt,ii,xt;ti&&document.addEventListener("visibilitychange",Ve),Fe.debugLog&&s().actions.internal.startLogging(),$e(n(Lt));let W=Ee.map(st=>st.init({store:s(),microStores:Te,config:m(),interactiveController:_(),uiConfig:p()})),Rt=()=>{ti&&document.removeEventListener("visibilitychange",Ve),Ft==null||Ft.disconnect(),W.forEach(st=>st.unsubscribe()),s().destroy()};return((li=T())==null?void 0:li.status)==="upcoming"?(s().actions.internal.setLiveWaitingStart(!0),Rt):((gt=T())==null?void 0:gt.status)==="waiting"?(s().actions.internal.setLiveWaitingRecover(!0),Rt):(((ii=T())==null?void 0:ii.status)==="finished"||((xt=T())==null?void 0:xt.status)==="postlive")&&!(d()&&(0,cd.areValidLiveRecordSources)(d()))?(s().actions.internal.setLiveWaitingRecord(!0),Rt):(le(),Rt)});function dt(){n(qt)?s().actions.external.play():Y(!0)}function St(){s().actions.external.pause()}function fe(W){s().actions.external.setMuted(W)}function Be(){s().actions.external.toggleSubtitle()}function We(W,Rt){s().actions.external.changeSubtitle(W,Rt)}function Ct(W){s().actions.external.changeAudioStream(W)}function Xt(){var W;(W=s().webApi.slotsApi)!=null&&W.haveSlots()&&s().actions.external.hideControls()}function It(){var W;(W=s().webApi.slotsApi)!=null&&W.haveSlots()&&s().actions.external.showControls()}function ai(W){me()||W>=0&&W<=1&&s().actions.external.setVolume(W)}function fi(W){s().actions.internal.seekTime(W,C$.SeekAction.UNKNOWN)}function Bi(W){s().actions.external.seekEpisodeStartTime(W)}function Bt(){s().actions.external.returnFocusToEpisodes()}function _o(W){s().actions.external.setPlaybackRate(W)}function vi(W){s().actions.external.setAutoQualityLimits(W)}function ot(){s().actions.external.setQuality("auto")}function Jt(W){s().actions.external.setTrafficSavingEnabled(W)}function Hi(W){s().actions.external.setHighQualityEnabled(W)}let xi=Ap(Fe.view),oi=m().playerView==="preview",Ti=s().state.availableSubtitlesList$;if(Fe.features.initSubtitles){let W=!1;Oe(()=>{var Rt;if(!W&&a().length){W=!0;let li;if(Fe.features.userVideoPrefs&&s().videoId){let ii=qu(Fe.userSalt,String(s().videoId));ii!=null&&ii.subtitleTrackId&&(li=a().find(xt=>xt.value===ii.subtitleTrackId))}let gt=(Rt=I())!=null?Rt:sm();gt&&(li=a().find(ii=>ii.language===gt)),s().actions.internal.setSubtitle(li)}})}let lt=s().ui.isPreviewTrackHorizontallyAligned;var nt=bT();let Ei;var tn=C(nt);{var Bo=W=>{ug(W,{get store(){return s()},get uiConfig(){return Fe},get thumbUrl(){return b()},get interactiveContainer(){return y()},get live(){return T()},get autoplay(){return A()},get canRewindLive(){return F()},get showAds(){return U()},get adsSlotId(){return X()},get adsParams(){return ae()},get adsAutoplayParam(){return Z()},get duration(){return re()},get logoClickable(){return J()},get logoHidden(){return we()},get logoTargetUrl(){return kt},get nextButtonActive(){return _e()},get prevButtonActive(){return Ce()},get endScreenVideoTitle(){return ge()},get endScreenVideoThumb(){return pe()},get isOneVideoPlaylist(){return Qe()},get supportLink(){return G()},get shadowRootContainer(){return D()},get outerContainerRef(){return Ge()},get fullScreenTarget(){return K()},get showMiniTimer(){return xe()},get playerStarted(){return n(qt)},get seekToInteractive(){return it()},get playPrevChapter(){return ne()},firstStart:Y,seekTime:fi,get showEndScreen(){return Le()},get showAutoplayNext(){return Ne()},get showNextPrevButtons(){return ee()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson},get videoContainer(){return n(Lt)},set videoContainer(Rt){N(Lt,Rt,!0)}})},bt=W=>{var Rt=Me(),li=ue(Rt);{var gt=xt=>{pg(xt,{get thumbUrl(){return b()},get outsideDuration(){return re()},get canRewindLive(){return F()},get videoContainer(){return n(Lt)},set videoContainer(st){N(Lt,st,!0)}})},ii=xt=>{dg(xt,{get store(){return s()},get uiConfig(){return Fe},get title(){return v()},get thumbUrl(){return b()},get interactiveContainer(){return y()},get live(){return T()},get autoplay(){return A()},get canRewindLive(){return F()},get showAds(){return U()},get adsSlotId(){return X()},get adsParams(){return ae()},get adsAutoplayParam(){return Z()},get duration(){return re()},get logoClickable(){return J()},get logoHidden(){return we()},get logoTargetUrl(){return kt},get nextButtonActive(){return _e()},get prevButtonActive(){return Ce()},get endScreenVideoTitle(){return ge()},get endScreenVideoThumb(){return pe()},get isOneVideoPlaylist(){return Qe()},get supportLink(){return G()},get shadowRootContainer(){return D()},get outerContainerRef(){return Ge()},get fullScreenTarget(){return K()},get showMiniTimer(){return xe()},get playerStarted(){return n(qt)},get seekToInteractive(){return it()},get playPrevChapter(){return ne()},firstStart:Y,get showEndScreen(){return Le()},get showAutoplayNext(){return Ne()},get showNextPrevButtons(){return ee()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson},get getVideoDeeplink(){return e.getVideoDeeplink},get videoContainer(){return n(Lt)},set videoContainer(st){N(Lt,st,!0)},get keyboardControls(){return et()},set keyboardControls(st){et(st)}})};V(li,xt=>{oi?xt(gt):xt(ii,!1)})}$(W,Rt)};V(tn,W=>{me()?W(Bo):W(bt,!1)})}S(nt),O(W=>{Ei=oe(nt,1,"vk-vp-root s-0",null,Ei,W),qe(nt,xi)},[()=>({"root--miui-browser":cd.clientChecker.device.isMobile&&cd.clientChecker.browser.isMiuiBrowser,"visible-outside":oi,"preview-track-horizontally-alinged":l()})]),$(i,nt);var Ut=H({initVideo:le,play:dt,pause:St,setMuted:fe,toggleSubtitle:Be,changeSubtitle:We,changeAudioStream:Ct,hideControls:Xt,showControls:It,setVolume:ai,seekTime:fi,seekEpisodeStartTime:Bi,returnFocusToEpisodes:Bt,setPlaybackRate:_o,setAutoQualityLimits:vi,setAutoQuality:ot,toggleTrafficSaving:Jt,toggleHighQuality:Hi,get sources(){return d()},set sources(W){d(W)},get store(){return s()},set store(W){s(W)},get microStoresRoot(){return u()},set microStoresRoot(W){u(W)},get videoConfig(){return m()},set videoConfig(W){m(W)},get uiConfig(){return p()},set uiConfig(W){p(W)},get title(){return v()},set title(W){v(W)},get thumbUrl(){return b()},set thumbUrl(W){b(W)},get interactiveContainer(){return y()},set interactiveContainer(W){y(W)},get interactiveController(){return _()},set interactiveController(W){_(W)},get subtitles(){return x()},set subtitles(W){x(W)},get subtitlesForcedLanguage(){return I()},set subtitlesForcedLanguage(W){I(W)},get live(){return T()},set live(W){T(W)},get preload(){return R()},set preload(W){R(W)},get autoplay(){return A()},set autoplay(W){A(W)},get volume(){return P()},set volume(W){P(W)},get muted(){return E()},set muted(W){E(W)},get fromTime(){return z()},set fromTime(W){z(W)},get canRewindLive(){return F()},set canRewindLive(W){F(W)},get showAds(){return U()},set showAds(W){U(W)},get adsSlotId(){return X()},set adsSlotId(W){X(W)},get adsParams(){return ae()},set adsParams(W){ae(W)},get adsAutoplayParam(){return Z()},set adsAutoplayParam(W){Z(W)},get duration(){return re()},set duration(W){re(W)},get logoClickable(){return J()},set logoClickable(W){J(W)},get logoHidden(){return we()},set logoHidden(W){we(W)},get isMobile(){return me()},set isMobile(W){me(W)},get showNextPrevButtons(){return ee()},set showNextPrevButtons(W){ee(W)},get nextButtonActive(){return _e()},set nextButtonActive(W){_e(W)},get prevButtonActive(){return Ce()},set prevButtonActive(W){Ce(W)},get endScreenVideoTitle(){return ge()},set endScreenVideoTitle(W){ge(W)},get endScreenVideoThumb(){return pe()},set endScreenVideoThumb(W){pe(W)},get isOneVideoPlaylist(){return Qe()},set isOneVideoPlaylist(W){Qe(W)},get supportLink(){return G()},set supportLink(W){G(W)},get shadowRootContainer(){return D()},set shadowRootContainer(W){D(W)},get outerContainerRef(){return Ge()},set outerContainerRef(W){Ge(W)},get fullScreenTarget(){return K()},set fullScreenTarget(W){K(W)},get failoverHosts(){return se()},set failoverHosts(W){se(W)},get showMiniTimer(){return xe()},set showMiniTimer(W){xe(W)},get saveRate(){return He()},set saveRate(W){He(W)},get showAutoplayNext(){return Ne()},set showAutoplayNext(W){Ne(W)},get seekToInteractive(){return it()},set seekToInteractive(W){it(W)},get playPrevChapter(){return ne()},set playPrevChapter(W){ne(W)},get volumeMultiplier(){return ce()},set volumeMultiplier(W){ce(W)},get showEndScreen(){return Le()},set showEndScreen(W){Le(W)},get keyboardControls(){return et()},set keyboardControls(W){et(W)}});return o(),Ut}var yT=Ie('<defs><path id="rect" d="m2.72 0c.45 0 .6.05.77.13a1 1 0 01.38.38c.09.16.13.33.13.77v1.44c0 .44-.04.6-.13.77a1 1 0 01-.38.38c-.16.08-.32.13-.77.13h-1.44c-.44 0-.6-.05-.77-.13a1 1 0 01-.37-.38c-.1-.16-.14-.33-.14-.77v-1.44c0-.44.05-.6.13-.77a1 1 0 01.38-.38c.17-.08.33-.13.77-.13z"></path></defs><path d="M38.24 6c3.57 0 4.86.37 6.17 1.07a7.3 7.3 0 0 1 3.02 3.02c.7 1.3 1.07 2.6 1.07 6.17v23.49c0 3.56-.37 4.85-1.07 6.16a7.3 7.3 0 0 1-3.02 3.02c-1.3.7-2.6 1.07-6.16 1.07h-19.5c-3.56 0-4.85-.37-6.16-1.07a7.3 7.3 0 0 1-3.02-3.02c-.7-1.3-1.07-2.6-1.07-6.16v-23.5c0-3.56.37-4.85 1.07-6.16a7.3 7.3 0 0 1 3.02-3.02C13.9 6.37 15.2 6 18.76 6zm.32 3h-19.8c-2.8 0-3.77.19-4.75.71a4.3 4.3 0 0 0-1.8 1.8c-.5.95-.7 1.87-.7 4.43l-.01 23.8c0 2.8.19 3.76.71 4.75a4.3 4.3 0 0 0 1.8 1.8c.98.52 1.95.71 4.75.71h19.49c2.8 0 3.76-.19 4.74-.71a4.3 4.3 0 0 0 1.8-1.8c.52-.98.71-1.95.71-4.74v-23.5c0-2.8-.19-3.75-.71-4.74a4.3 4.3 0 0 0-1.8-1.8c-.95-.5-1.87-.7-4.43-.7z"></path><use xlink:href="#rect" x="16.5" y="14"></use><use xlink:href="#rect" x="16.5" y="22"></use><use xlink:href="#rect" x="16.5" y="30"></use><use xlink:href="#rect" x="16.5" y="38"></use><use xlink:href="#rect" x="37" y="14"></use><use xlink:href="#rect" x="37" y="22"></use><use xlink:href="#rect" x="37" y="30"></use><use xlink:href="#rect" x="37" y="38"></use>',1);function mg(i,e){let t=h(e,"isWhite",3,!1),o=f(()=>t()?"#fff":"#909499");Ze(i,{width:"57",height:"60",get fill(){return n(o)},testId:"stub-icon",children:(r,a)=>{var l=yT();pi(9),$(r,l)},$$slots:{default:!0}})}var xT=L('<div class="title s-2"> </div>'),wT=L('<div class="playerStub s-2"><!> <!></div>'),ST={hash:"s-2",code:".playerStub.s-2{align-items:center;background-color:#222;background-position:50%;background-size:cover;display:flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;height:100%;justify-content:center;position:relative;width:100%}.title.s-2{box-sizing:border-box;color:#fff;font-size:15px;left:0;overflow:hidden;padding:18px 20px 10px;position:absolute;text-overflow:ellipsis;top:0;white-space:nowrap;width:100%}"};function vg(i,e){Q(i,ST);var t=wT(),o=C(t);{var r=d=>{var s=xT(),u=C(s,!0);S(s),O(()=>ve(u,e.title)),$(d,s)};V(o,d=>{e.title&&d(r)})}var a=k(o,2);{var l=d=>{let s=f(()=>!!e.thumbUrl);mg(d,{get isWhite(){return n(s)}})};V(a,d=>{(!e.title||!e.thumbUrl)&&d(l)})}S(t),O(()=>qe(t,e.thumbUrl?`background-image: url('${e.thumbUrl}')`:"")),$(i,t)}var CT=L('<div class="playerError s-1"><!></div>'),TT={hash:"s-1",code:".playerError.s-1{align-items:center;background-color:#222;background-position:50%;background-size:cover;display:flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;height:100%;justify-content:center;position:relative;width:100%}"};function gg(i){Q(i,TT);var e=CT(),t=C(e);ll(t,{}),S(e),$(i,e)}var Wp=require("@vkontakte/videoplayer-shared/es2015"),Oi=require("@vkontakte/videoplayer-shared/es2015"),Xc=require("@vkontakte/videoplayer-core/es2015"),vd=require("@vkontakte/videoplayer-statistics/es2015");var Mp=require("@vkontakte/videoplayer-shared/es2015"),Lp=class{constructor(){this.subscription=new Mp.Subscription,this.logger=new Mp.Logger,this.log=this.logger.createComponentLog("MediaSessionApi")}isSupported(){return"mediaSession"in navigator}setMetaData({title:e,artist:t="",thumbUrl:o=""}){this.isSupported()&&(navigator.mediaSession.metadata=new MediaMetadata({title:e,artist:t,artwork:[{src:o,sizes:"96x96",type:"image/png"},{src:o,sizes:"128x128",type:"image/png"},{src:o,sizes:"192x192",type:"image/png"},{src:o,sizes:"256x256",type:"image/png"},{src:o,sizes:"384x384",type:"image/png"},{src:o,sizes:"512x512",type:"image/png"}]}))}updateActionHandlers(e){this.resetActionHandlers(),this.setActionHandlers(e)}resetActionHandlers(){let e=[["play",null],["pause",null],["stop",null],["nexttrack",null],["previoustrack",null],["seekto",null],["seekbackward",null],["seekforward",null]];this.setActionHandlers(e)}setActionHandlers(e){var t,o;if(this.isSupported())for(let[r,a]of e)try{(o=(t=navigator.mediaSession).setActionHandler)==null||o.call(t,r,a)}catch(l){throw new Error(`The media session action "${r}" is not supported yet.`)}}attachToStore(e){!this.isSupported()||!e||(this.clearSubscriptions(),this.subscription.add(e.state.positionExact$.subscribe(t=>{var a,l;let o=ye(e.state.currentPlaybackRate$),r=ye(e.state.duration$);if(!(!isFinite(t)||!isFinite(r)))try{(l=(a=navigator.mediaSession).setPositionState)==null||l.call(a,{position:t,playbackRate:o,duration:r})}catch(d){this.log({message:`MediaSession setPositionState can't call with position: ${t} and duration: ${r}`})}})))}clearSubscriptions(){this.subscription.unsubscribe()}destroy(){this.resetActionHandlers(),this.clearSubscriptions()}};var ud=require("@vkontakte/videoplayer-shared/es2015");var IT=Ie('<path d="M31.257 3.998c3.037.01 4.52.39 6.13 1.24a9 9 0 013.47 3.35l.17.31.15.3c.78 1.55 1.07 3.18 1.09 6.25v9.04a1.5 1.5 0 01-3 .02v-9.65c-.05-2.04-.24-3.12-.64-4.04l-.12-.27-.13-.25A6 6 0 0036.2 7.9c-1.19-.64-2.34-.88-5.11-.9h-8.84c-2.73 0-4 .2-5.07.7l-.25.13a6 6 0 00-2.4 2.41c-.64 1.19-.88 2.34-.9 5.11v20.83c0 2.74.2 4 .7 5.08l.13.25a6 6 0 002.41 2.4c1.1.6 2.13.83 4.44.89H26a1.5 1.5 0 010 3h-4.47c-3-.05-4.53-.38-6.14-1.24a9 9 0 01-3.48-3.35l-.15-.3c-.73-1.47-1.04-3.01-1.08-5.8V15c.05-2.98.39-4.52 1.25-6.12a9 9 0 013.293-3.582c1.85-.871 2.623-1.27 5.747-1.27z"></path><path d="M30.5 33.8c0-1.68 0-2.52.33-3.16a3 3 0 0 1 1.3-1.31c.65-.33 1.49-.33 3.17-.33h6.4c1.68 0 2.52 0 3.16.33a3 3 0 0 1 1.31 1.3c.33.65.33 1.49.33 3.17v13.4c0 1.68 0 2.52-.33 3.16a3 3 0 0 1-1.3 1.31c-.65.33-1.49.33-3.17.33h-6.4c-1.68 0-2.52 0-3.16-.33a3 3 0 0 1-1.31-1.3c-.33-.65-.33-1.49-.33-3.17z"></path>',1),ET=L('<div><div><!></div> <span class="title s-9"> </span></div>'),PT={hash:"s-9",code:".player-pip-dummy.s-9{align-items:center;background-color:#19191a;display:flex;flex-direction:column;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;height:100%;justify-content:center;width:100%}.player-pip-dummy.is-pip-api.s-9{position:relative}.dummy-image.s-9 svg{transform:scale(1.07143)}.dummy-image.desktop.s-9{transform:scale(1.07143) rotate(-90deg) rotateY(180deg)}.title.s-9{color:#fff;font-size:16px;padding:18px 20px 10px;text-align:center}"};function hg(i,e){B(e,!0),Q(i,PT);let[t,o]=De(),r=()=>w(u,"$interfaceLanguage$",t),a=()=>w(m,"$isMobile$",t),l=be(),d=Ot(),s=!!l.webApi.pictureInPictureApi,u=l.interfaceLanguage$,m=l.ui.isMobile,p=l.ui.t,v=f(()=>r()&&p("pip_dummy_title")),b=Ap(d.view);var y=ET();let _;var x=C(y);let I;var T=C(x);Ze(T,{width:"57",height:"56",testId:"pip-dummy-icon",children:(P,E)=>{var z=IT();pi(),$(P,z)},$$slots:{default:!0}}),S(x);var R=k(x,2),A=C(R,!0);S(R),S(y),O((P,E)=>{_=oe(y,1,"player-pip-dummy s-9",null,_,P),qe(y,b),I=oe(x,1,"dummy-image s-9",null,I,E),ve(A,n(v))},[()=>({"is-pip-api":s}),()=>({desktop:!a()})]),$(i,y),H(),o()}var kT=Object.defineProperty,AT=(i,e,t)=>e in i?kT(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,$a=(i,e,t)=>AT(i,typeof e!="symbol"?e+"":e,t),_g=(i,e,t)=>new Promise((o,r)=>{var a=s=>{try{d(t.next(s))}catch(u){r(u)}},l=s=>{try{d(t.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((t=t.apply(i,e)).next())}),LT=460,MT=280,Uc=class{constructor({enabled:e=!0}={enabled:!0}){$a(this,"playerDomElement"),$a(this,"playerParentShadowRoot"),$a(this,"playerDummyElement"),$a(this,"svelteContext"),$a(this,"pipWindow"),$a(this,"info",{isActive$:new ud.ValueSubject(!1),isEnabled$:new ud.ValueSubject(!1),type:1}),$a(this,"pipActive",!1),$a(this,"pipApi"),this.info.isEnabled$=new ud.ValueSubject(e),gp()&&(this.pipApi=new Us({enabled:e}),this.pipApi.info.isActive$.subscribe(t=>{(t&&!this.info.isActive$.getValue()||!t&&this.pipActive)&&this.info.isActive$.next(t),this.pipActive=t}))}isSupported(){let{isEmbed:e}=(0,ud.detectEmbed)();return"documentPictureInPicture"in window&&!e}isActive(){return this.info.isActive$.getValue()}setPlayerDomElement(e,t){this.playerDomElement=e,this.playerParentShadowRoot=t}setContext(e){this.svelteContext=e}request(){return _g(this,null,function*(){var e,t;if(!this.isSupported()||!this.playerDomElement||!this.playerParentShadowRoot)return;this.pipWindow=yield documentPictureInPicture.requestWindow({width:LT,height:MT,copyStyleSheets:!0}),this.pipWindow.document.body.style.margin="0";let o=[...this.playerParentShadowRoot.styleSheets].map(s=>[...s.cssRules].map(u=>u.cssText).join(" ")).filter(Boolean).join(`
|
|
63
|
-
`),r=document.createElement("style");r.textContent=o;let a=this.createStretchedContainer(),l=a.attachShadow({mode:"open"});l.append(r),l.append(this.playerDomElement);let d={target:this.playerParentShadowRoot,context:this.svelteContext};this.playerDummyElement=is(hg,d),(e=this.pipWindow)==null||e.document.body.append(a),this.info.isActive$.next(!0),(t=this.pipWindow)==null||t.addEventListener("unload",s=>{!this.playerDomElement||!this.playerParentShadowRoot||!this.playerDummyElement||(Ha(this.playerDummyElement),this.playerParentShadowRoot.append(this.playerDomElement),this.info.isActive$.next(!1),this.pipWindow=void 0)})})}exit(){return _g(this,null,function*(){return new Promise(e=>{var t,o,r;this.pipWindow?(t=documentPictureInPicture.window)==null||t.close():(o=this.pipApi)!=null&&o.isActive()&&((r=this.pipApi)==null||r.exit()),e()})})}dispose(){return _g(this,null,function*(){yield this.exit()})}setEnabled(e){var t;this.info.isEnabled$.next(e),(t=this.pipApi)==null||t.setEnabled(e)}assignPlayerContainer(e){var t;(t=this.pipApi)==null||t.assignPlayerContainer(e)}updateVideoElement(){var e;(e=this.pipApi)==null||e.updateVideoElement()}setExternalEventHandlers(e){var t;(t=this.pipApi)==null||t.setExternalEventHandlers(e)}createStretchedContainer(){let e=document.createElement("div");return e.style.position="absolute",e.style.top="0",e.style.left="0",e.style.width="100%",e.style.height="100%",e}};function T$(i){return i instanceof Uc}var Vp=class{static getLatestSupportedVersion(e){let t=new Us(e),o=new Uc(e);if(o.isSupported())return o;if(t.isSupported())return t}};function zc(i,e){var r,a;let t=new Set([...Object.keys(i),...Object.keys(e)]),o={};for(let l of t)o[l]=(a=(r=e[l])!=null?r:i[l])!=null?a:void 0;return o}var I$="Inner error. Unexpectedly root annotation container null reference exception",E$="Annotation with such name already exists",P$="Annotation with such name does not exist";var pd=class extends Error{constructor(e){super(e),this.name="AnnotationError"}};var fd=require("@vkontakte/videoplayer-shared/es2015"),VT="1",RT=100,Rp=class{constructor(e){this.annotationsInside=e;this.annotations=new Map;this.subscriptions=new fd.Subscription}init(e){if(this.rootAnnotationsContainer=e,this.annotationsInside)return;let t=(0,fd.throttleFn)(()=>{for(let o of this.annotations.values())this.isElementExceedsBoundaries(o,this.playerSize.width,this.playerSize.height)?o.style.visibility="hidden":o.style.visibility="visible"},RT);this.subscriptions.add((0,fd.observeElementSize)(this.rootAnnotationsContainer).subscribe(({width:o,height:r})=>{this.playerSize={width:o,height:r},t()})),this.mutationObserver=new MutationObserver(t),this.mutationObserver.observe(this.rootAnnotationsContainer,{attributes:!0,childList:!0,subtree:!0,characterData:!0})}add(e,t){var o;if(!this.rootAnnotationsContainer)throw new pd(I$);if(this.annotations.has(e))throw new pd(E$);t.style.zIndex=(o=t.style.zIndex)!=null?o:VT,t.style.position="absolute",this.rootAnnotationsContainer.append(t),this.annotations.set(e,t)}get(e){let t=this.annotations.get(e);if(!t)throw new pd(P$);return t}remove(e){let t=this.get(e);this.annotations.delete(e)&&t.remove()}clear(){for(let e in this.annotations.keys())this.remove(e)}destroy(){var e;this.annotations.clear(),this.subscriptions.unsubscribe(),(e=this.mutationObserver)==null||e.disconnect(),this.rootAnnotationsContainer=null}isElementExceedsBoundaries(e,t,o){let r=e.offsetTop,a=e.offsetLeft,l=e.offsetWidth,d=e.offsetHeight;return r<0||a<0||a+l>t||r+d>o}registryRootContainer(e){}addLayer(e){return document.createElement("div")}getLayer(e){}removeLayer(e){}clearLayer(e){}detach(){}reattach(){}};var vl=require("@vkontakte/videoplayer-shared/es2015"),mn=class{init({store:e,microStores:t,interactiveController:o,config:r}){return(0,vl.assertNonNullable)(e),(0,vl.assertNonNullable)(t),(0,vl.assertNonNullable)(r),r.interactiveData&&(0,vl.assertNonNullable)(o),this.subscription=new vl.Subscription,this.subscription}};var Wc=class extends mn{constructor(){super(...arguments);this.stateName="fakeIsPlaying$";this.state$=Gt(ke({},de(null)),{toggle:()=>this.state$.update(t=>!t)})}init(t){let o=super.init(t),{isInteractiveExpectation$:r}=t.store.state;return o.add(r.subscribe(a=>{this.state$.set(a?!0:null)})),o}};var Kc=class extends mn{constructor(){super(...arguments);this.stateName="interactiveControlsOpacity$";this.state$=Gt(ke({},de(null)),{toggle:()=>this.state$.update(t=>!t)})}init(t){let o=super.init(t),{microStores:r,store:a}=t,{fakeIsPlaying$:l}=r,{isInteractiveExpectation$:d,isPlaying$:s}=a.state,{controlsVisible:u,isMobile:m}=a.ui,p=ye(m),v=()=>p&&ye(u);return o.add(u.subscribe(b=>{if(!p)return;let y=ye(l);ye(s)?this.state$.set(b):y!==null&&this.state$.set(!y||b)})),o.add(s.subscribe(b=>{this.state$.set(!b||v())})),o.add(l.subscribe(b=>{if(b===null)return;let y=ye(d);if(v()){this.state$.set(!0);return}y&&this.state$.set(!b)})),o}};var qc=class extends mn{constructor(){super(...arguments);this.stateName="seekToInteractiveDisabledTooltip$";this.state$=de("tooltip_chapter_without_interactive")}init(t){let o=super.init(t),{store:r}=t;return o.add(r.state.interactiveEpisodes$.subscribe(a=>{a.length&&(a.every(l=>l.completed)?this.state$.set("tooltip_interactive_of_chapter_completed"):this.state$.set("tooltip_disabled_when_interactive"))})),o}};var k$=require("@vkontakte/videoplayer-shared/es2015");var bg=de(!1),Np=null,Qc=class extends mn{constructor(){super(...arguments);this.stateName="showInteractiveTimeIndicatorTooltip$";this.state$=Gt(ke({},bg),{set:(t,o=!1)=>{t!==ye(bg)&&(this.clearTimeout(),bg.set(t),!t&&Np&&(Np=!1),t&&o&&(this.timeout=setTimeout(()=>{this.state$.set(!1)},3e3)))},clearTimeout:()=>this.clearTimeout()})}init(t){let o=super.init(t),{store:r,config:a}=t,{isInteractiveTime$:l,isPlaying$:d}=r.state,s=r.ui.controlsVisible,{interactiveTimeIndicator:u}=r.ui.controls;o.add(s.subscribe(p=>{ye(l)&&p&&this.state$.set(!1)}));let m=(a==null?void 0:a.interactiveData)||{tooltipHelpHintActive:!1};return o.add((0,k$.combine)({isPlaying$:d,isInteractiveTime$:l,interactiveTimeIndicator:u}).subscribe(({isPlaying$:p,isInteractiveTime$:v,interactiveTimeIndicator:b})=>{var y,_;if(!(!p||!(b!=null&&b.isDisplayed))){if(!v)return this.state$.set(!1);m.tooltipHelpHintActive&&Np===null&&(Np=!0,m.tooltipHelpHintActive=!1,this.state$.set(!0),(_=(y=r.callbacks)==null?void 0:y.onInteractiveTimeIndicatorHintDeactivated)==null||_.call(y))}})),o}clearTimeout(){window.clearTimeout(this.timeout)}};var Dp=require("@vkontakte/videoplayer-shared/es2015");var Gc=class extends mn{constructor(){super(...arguments);this.stateName="graphIsOpened$";this.graphMadePause=!1;this.state$=Gt(ke({},de(null)),{toggle:Dp.noop});this.checkIfShouldHide=t=>Fs(t,"s")}init(t){let o=super.init(t),{store:r,interactiveController:a}=t,l=r.ui.currentGridType$,d=r.getLogger().createComponentLog("GraphIsOpened microStore");return this.state$.toggle=()=>ht(this,null,function*(){if(this.checkIfShouldHide(ye(l)))return;let s=ye(this.state$),{isEnded$:u,playbackState$:m}=r.state,{disabledControls$:p}=r.ui.controls,v=ye(u),b=ye(m);if(s)try{yield a==null?void 0:a.toggleGraphView(!1),this.state$.set(!1),p.remove(Gf),!v&&this.graphMadePause&&r.actions.internal.play()}catch(y){d({message:"Cant hide graph"})}else{this.graphMadePause=b==="playing";try{yield a==null?void 0:a.toggleGraphView(!0),this.state$.set(!0),p.add(Gf),!v&&this.graphMadePause&&r.actions.internal.pause()}catch(y){d({message:"Cant show graph"})}}}),o.add((0,Dp.combine)({graphIsOpened:this.state$,currentGridType:l}).subscribe(m=>ht(this,[m],function*({graphIsOpened:s,currentGridType:u}){if(this.checkIfShouldHide(u)&&s)try{yield a==null?void 0:a.toggleGraphView(!1),this.state$.set(!1)}catch(v){d({message:"Cant hide graph"})}}))),o}};var $g=require("@vkontakte/videoplayer-shared/es2015"),Yc=class extends mn{constructor(){super(...arguments);this.stateName="pictureInPicture$";this.state$={isActive$:de(!1),isEnabled$:de(!1),type$:de(void 0)}}init(t){let o=super.init(t),{store:r}=t,{info:{isActive$:a,isEnabled$:l,type:d}}=r.webApi.pictureInPictureApi||{info:{isActive$:new $g.ValueSubject(!1),isEnabled$:new $g.ValueSubject(!1)}};return o.add(a.subscribe(s=>{this.state$.isActive$.set(s)})),o.add(l.subscribe(s=>{this.state$.isEnabled$.set(s)})),this.state$.type$.set(d),o}};var Bp=require("@vkontakte/videoplayer-shared/es2015");var Op=require("@vkontakte/videoplayer-shared/es2015");var A$=({maxShowCount:i,timeout:e})=>{let t=[i!==0?NT({maxCount:i}):void 0,e!==0?DT({timeout:e}):void 0].filter(o=>!!o);return{notificationShowed:o=>t.forEach(r=>r.notificationShowed(o)),canShowNotification:o=>t.every(r=>r.canShowNotification(o))}},NT=({maxCount:i})=>{let e={};return{notificationShowed:t=>{var o,r;e[t]=((o=e[t])!=null?o:0)+1,Op.safeStorage.set("videoplayer_notifications_manager_count",JSON.stringify((r=e[t])!=null?r:0))},canShowNotification:t=>{var o;return((o=e[t])!=null?o:0)<i}}},DT=({timeout:i})=>{let e="videoplayer_notifications_manager",t=()=>{try{return JSON.parse(Op.safeStorage.get(e)||"{}")}catch(a){return{}}},o=a=>Op.safeStorage.set(e,JSON.stringify(a)),r=a=>{let l=t();delete l[a],o(l)};return{notificationShowed:a=>{o(Gt(ke({},t()),{[a]:{timeout:i,launchTime:Date.now()}}))},canShowNotification:a=>{let l=t()[a];if(l){let d=Date.now()-l.launchTime>i;return d&&r(a),d}else return!0}}};var jc=class extends mn{constructor(){super(...arguments);this.stateName="notifications$";this.state$={notificationsToShow$:de({}),showNotification:t=>{this.state$.notificationsToShow$.update(o=>(o[t]=!0,o)),this.notificationManager.notificationShowed(t)},closeNotification:t=>{this.state$.notificationsToShow$.update(o=>(delete o[t],o))}}}init(t){let o=super.init(t),{store:r,uiConfig:{features:{maxCountShowSlowVideoNotification:a,timeoutShowSlowVideoNotification:l,showSlowVideoNotification:d,forceAutoQualityWhenSevereStallHappens:s}}}=t;this.notificationManager=A$({maxShowCount:a,timeout:l});let u=r.getPlayer();return o.add(u.events.severeStallOccured$.pipe((0,Bp.filterChanged)(),(0,Bp.filter)(m=>m)).subscribe(()=>{d&&!u.info.isAutoQualityEnabled$.getValue()&&this.notificationManager.canShowNotification("slow_video")&&(s&&r.actions.internal.setQuality("auto"),this.state$.showNotification("slow_video"))})),o}};var L$=()=>[Wc,Kc,qc,Qc,Gc,Yc,jc].reduce(({subscribers:i,stores:e},t)=>{let o=new t;return{subscribers:[...i,o],stores:Gt(ke({},e),{[o.stateName]:o.state$})}},{subscribers:[],stores:{}});var md=require("@vkontakte/videoplayer-shared/es2015");var Hp=class{constructor(e){this.getActiveElement=e;this.focusableElements=[];this.isActive=!1;this.handleTabKey=e=>{if(this.updateFocusableElements(),!this.focusableElements.length)return;let t=this.focusableElements[0],o=this.focusableElements[this.focusableElements.length-1],r=this.getActiveElement();e.shiftKey&&r===t?(e.preventDefault(),o.focus()):!e.shiftKey&&r===o&&(e.preventDefault(),t.focus())}}activate(){this.isActive||(document.addEventListener("keydown",this.handleTabKey),this.isActive=!0)}deactivate(){this.isActive&&(document.removeEventListener("keydown",this.handleTabKey),this.isActive=!1,this.focusableElements=[])}updateFocusableElements(){this.isActive&&(this.focusableElements=this.getFocusableElements())}getFocusableElements(){let e=["button:not([disabled])","[href]:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"]):not([disabled])'].join(", ");return Array.from(this.container.querySelectorAll(e)).filter(t=>!t.disabled&&t.offsetParent!==null)}destroy(){this.deactivate()}setContainer(e){this.container=e}};var Fp=class{constructor(e){this.shadowRoot=e;this.lastFocusedNode=null;this.init=()=>{this.shadowRoot.addEventListener("focusin",this.handleFocusChange)};this.handleFocusChange=()=>{this.lastFocusedNode=this.shadowRoot.activeElement};this.restoreFocus=()=>{var e;(e=this.lastFocusedNode)==null||e.focus()};this.focusLock=new Hp(()=>this.lastFocusedNode),this.init()}destroy(){this.shadowRoot.removeEventListener("focusin",this.handleFocusChange),this.focusLock.destroy()}getLastFocusedNode(){return this.lastFocusedNode}activateLock(){this.focusLock.activate()}deactivateLock(){this.focusLock.deactivate()}setContainerForFocusLock(e){this.focusLock.setContainer(e)}};var OT=L('<div class="root s-3"><!></div>'),BT={hash:"s-3",code:".root.s-3{align-items:center;display:flex;inset:0;justify-content:center;pointer-events:none;position:absolute;z-index:1}"};function yg(i,e){B(e,!0),Q(i,BT);let t=null,o=q(null);Oe(()=>(n(o)&&(t=window.setTimeout(()=>{N(o,null)},e.animationDuration)),()=>{t&&clearTimeout(t)}));function r(s){e.playbackStatusShow&&N(o,s?"prev":"next",!0)}var a=Me(),l=ue(a);{var d=s=>{var u=Me(),m=ue(u);Ns(m,()=>n(o),p=>{var v=OT(),b=C(v);let y=f(()=>n(o)==="prev");Fc(b,{get duration(){return e.animationDuration},get Icon(){return _a},get reversed(){return n(y)}}),S(v),$(p,v)}),$(s,u)};V(l,s=>{e.playbackStatusShow&&n(o)&&s(d)})}return $(i,a),H({startVideoChangedAnimation:r})}var M$=require("@vkontakte/videoplayer-shared/es2015"),xg=(0,M$.getWindow)().HTMLElement||class{constructor(){this.isConnected=!1}};var HT=Object.defineProperty,FT=Object.defineProperties,UT=Object.getOwnPropertyDescriptors,V$=Object.getOwnPropertySymbols,zT=Object.prototype.hasOwnProperty,WT=Object.prototype.propertyIsEnumerable,Sg=(i,e,t)=>e in i?HT(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,Gs=(i,e)=>{for(var t in e||(e={}))zT.call(e,t)&&Sg(i,t,e[t]);if(V$)for(var t of V$(e))WT.call(e,t)&&Sg(i,t,e[t]);return i},KT=(i,e)=>FT(i,UT(e)),jt=(i,e,t)=>Sg(i,typeof e!="symbol"?e+"":e,t),Up=(i,e,t)=>new Promise((o,r)=>{var a=s=>{try{d(t.next(s))}catch(u){r(u)}},l=s=>{try{d(t.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((t=t.apply(i,e)).next())}),qT={preload:!0,autoplay:!1,repeat:!1,loop:!1,fromTime:0,canRewindLive:!0,showAds:!1,interfaceLanguage:Oi.InterfaceLanguage.RU,isCyrillicRelatedInterface:!0,logoClickable:!1,logoHidden:!1,isTouch:(0,Xc.isMobile)(),isMediaSessionEnabled:!0,isPictureInPictureEnabled:!0,isAudioDisabled:!1,callbacks:{uiInfo:{}},tuningConfig:{},saveRate:!0,volumeMultiplier:1,showEndScreen:!0,showAutoplayNext:!0,showNextPrevButtons:!0},or=q(void 0),wg=ui({animationDuration:0,playbackStatusShow:!1}),zp=class extends xg{constructor(){super(),jt(this,"svelteStubComponent"),jt(this,"svelteRootComponent"),jt(this,"sveltePersistentLayerComponent"),jt(this,"svelteErrorComponent"),jt(this,"store"),jt(this,"microStoresRoot"),jt(this,"statistics"),jt(this,"sentry"),jt(this,"_shadowRoot"),jt(this,"playerContainer"),jt(this,"rootContainer"),jt(this,"stateContainer"),jt(this,"shadowRootContainer"),jt(this,"playerId"),jt(this,"uiConfig"),jt(this,"coreConfig"),jt(this,"statisticsConfig"),jt(this,"metaConfig"),jt(this,"interactiveController"),jt(this,"interactiveContainer"),jt(this,"graphMadePause"),jt(this,"currentPlayingVideoIndex",0),jt(this,"needToRepeatPlaylist",!1),jt(this,"videoConfig"),jt(this,"pictureInPictureApi"),jt(this,"mediaSessionApi"),jt(this,"unsubscribePlayerPhaseSubscription"),jt(this,"logger"),jt(this,"log"),jt(this,"subscription"),jt(this,"interactiveSubscription"),jt(this,"annotationsApi"),jt(this,"slotsApi"),jt(this,"focusManager"),jt(this,"prevIsid"),jt(this,"isInited",!1),jt(this,"postponedInitParams",null),jt(this,"internalsExposure",null),jt(this,"shadowDOMCallbacksDisabled",!1),jt(this,"fatalError$",new Wp.ValueSubject(null)),jt(this,"createOneStat",(e,t={})=>{var o,r,a,l;if(!this.videoConfig)return;let{albumId:d,statPlace:s,statUserSalt:u,statTrackCode:m,statVKAppId:p,refreshStatAuthToken:v,autoplay:b,isMobile:y,isTouch:_,refDomain:x,deviceId:I,interactiveData:T}=zc(this.videoConfig,t),R=(o=T==null?void 0:T.projectInfo)==null?void 0:o.pid,A=(a=(r=this.interactiveController)==null?void 0:r.state.isReplay$.getValue())!=null?a:!1;A&&(this.prevIsid=void 0);let{unitedVideoId:P,isClip:E=!1}=e;if(this.uiConfig.features.statistics&&P)try{return new vd.OneStat(Gs({movieId:P,albumId:d,place:s,trackCode:m,vkAppId:p,autoplay:(l=b&&!this.interactiveController)!=null?l:!1,mobile:_!=null?_:y,clip:E,refDomain:x,deviceId:I,isPreviewPlayerView:this.videoConfig.playerView==="preview"},R&&(!this.isInited||A)&&{projectId:Number(R)}),Gs({refreshAuthToken:v,userSalt:u,config:this.statisticsConfig},this.interactiveController&&{useIsid:!0,isid:this.prevIsid}))}catch(F){console.error(F),this.log({message:F.message})}}),md.devNull.create("ui"),this.logger=new Oi.Logger,this.log=this.logger.createComponentLog("VKVideoPlayer"),this.subscription=new Oi.Subscription,this.interactiveSubscription=new Oi.Subscription,this.graphMadePause=!1,this.fatalError$.subscribe(e=>{this.unmountComponent(this.svelteErrorComponent),e&&(this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteRootComponent),this.svelteErrorComponent=is(gg,{target:this.playerContainer}))})}connectedCallback(){var e,t;if(this.rootContainer)return;this.initPlayerRootContainers();let o=(e=this.getAttribute("stub-title"))!=null?e:void 0,r=(t=this.getAttribute("stub-thumb-url"))!=null?t:void 0,a=ui({title:o,thumbUrl:r}),l={target:this.playerContainer,props:a};this.svelteStubComponent=is(vg,l),this.sveltePersistentLayerComponent=is(yg,{target:this.playerContainer,props:wg}),this.postponedInitParams&&(this.initPlayer(...this.postponedInitParams),this.postponedInitParams=null)}updatePersistentLayerProps(){if(!this.uiConfig)return;let{playbackStatusNextVideoAnimationDuration:e,features:{playbackStatusShow:t,playbackStatusNextVideoShow:o}}=this.uiConfig;wg.animationDuration=e,wg.playbackStatusShow=t&&o}disconnectedCallback(){var e,t,o,r,a,l,d;this.shadowDOMCallbacksDisabled||((e=this.annotationsApi)==null||e.destroy(),(t=this.slotsApi)==null||t.destroy(),(o=this.focusManager)==null||o.destroy(),(r=this.mediaSessionApi)==null||r.destroy(),this.unmountComponent(this.svelteRootComponent),this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteErrorComponent),this.unmountComponent(this.sveltePersistentLayerComponent),this.subscription.unsubscribe(),(a=this.unsubscribePlayerPhaseSubscription)==null||a.call(this),(l=this.interactiveController)==null||l.destroy(),this.interactiveSubscription.unsubscribe(),(d=this.internalsExposure)==null||d.destroy(),md.devNull.destroy("ui"))}initPlayerRootContainers(){this.rootContainer=document.createElement("div"),this.rootContainer.style.position="relative",this.rootContainer.className="root-container",this.rootContainer.style.width="100%",this.rootContainer.style.height="100%",this.rootContainer.style.minHeight="206px",this.shadowRootContainer=document.createElement("div"),this.shadowRootContainer.style.position="absolute",this.shadowRootContainer.className="shadow-root-container",this.shadowRootContainer.style.width="100%",this.shadowRootContainer.style.height="100%",this._shadowRoot=this.shadowRootContainer.attachShadow({mode:"open"}),this.playerContainer=document.createElement("div"),this.playerContainer.style.all="initial",this.playerContainer.style.display="block",this.playerContainer.style.contain="strict",this.playerContainer.style.width="100%",this.playerContainer.style.height="100%",this._shadowRoot.append(this.playerContainer),this.rootContainer.append(this.shadowRootContainer),this.stateContainer=document.createElement("div"),this.stateContainer.className="state-container",this.stateContainer.style.width="1px",this.stateContainer.style.height="1px",this.stateContainer.style.position="absolute",this.stateContainer.style.backgroundColor="transparent",this.stateContainer.style.left="-100000px",this.append(this.rootContainer),this.append(this.stateContainer)}needToShowNextPrevButtons(){return this.videoConfig?this.videoConfig.videos.length>1&&this.videoConfig.showNextPrevButtons:!1}isNextButtonActive(){return this.videoConfig?this.needToShowNextPrevButtons()&&(this.currentPlayingVideoIndex<this.videoConfig.videos.length-1||this.needToRepeatPlaylist):!1}isPrevButtonActive(){return this.videoConfig?this.needToShowNextPrevButtons()&&(this.currentPlayingVideoIndex>0||this.needToRepeatPlaylist):!1}isControlDisabled(e){var t;let o=(t=this.store)==null?void 0:t.ui.controls.disabledControls$;return(o==null?void 0:o.includes(e))||!1}getNextVideoInfo(){if(!this.videoConfig)return{nextVideoTitle:void 0,nextVideoThumb:void 0};let e=this.videoConfig.videos[this.currentPlayingVideoIndex+1]||{};return{nextVideoTitle:e.title,nextVideoThumb:e.thumbUrl}}createThinOneStat(e,t={}){if(!this.videoConfig)return;let{deviceId:o,preload:r,refreshStatAuthToken:a}=zc(this.videoConfig,t),{unitedVideoId:l}=e;if(this.uiConfig.features.thinStatistics&&l)return new vd.ThinOneStat.ThinOneStat({deviceId:o,movieId:l,preload:r,isPreviewPlayerView:this.videoConfig.playerView==="preview"},{config:this.statisticsConfig,refreshAuthToken:a})}createPlayer(e,t={},o){var r,a,l,d,s,u,m,p,v,b;if(!this.videoConfig)return;let{albumId:y,statPlace:_,statAuthToken:x,preload:I,autoplay:T,volume:R,muted:A,fromTime:P,canRewindLive:E,supportLink:z,showAds:F,adsSlotId:U,adsParams:X={},adsAutoplayParam:ae,interfaceLanguage:Z,isCyrillicRelatedInterface:re,logoClickable:J,logoHidden:we,isMobile:me,isTouch:ee,isAudioDisabled:_e,isLiveCatchUpMode:Ce,fullScreenTarget:ge,failoverHosts:pe,canDownload:Qe,callbacks:G,interactiveData:D,showThumbTimer:Ge,additionalButtons:K=[],additionalSettingsMenuItems:se=[],additionalContextMenuItems:xe=[],repeat:He,loop:it,saveRate:ne,volumeMultiplier:ce,showEndScreen:Ne,showAutoplayNext:Le,mediascopePixels:et}=zc(this.videoConfig,t),{sources:Ee,title:Te,thumbUrl:Fe,unitedVideoId:kt,isClip:Tt=!1,duration:Vt,adsParams:pt={},videoEpisodes:At,previewThumbsData:ti,subtitles:Lt,subtitlesForcedLanguage:Ft,live:qt,adsExternalApi:Y,adsJson:Pe}=e;if(!Ee&&!qt){let vi=new Error("empty sources and live");this.fatalError$.next(vi),(r=G.onCrashed)==null||r.call(G,vi.message);return}let le=Gs(Gs({},X),pt),$e=this.getNextVideoInfo(),Ve={sources:Ee,title:Te,thumbUrl:Fe,subtitles:Lt,subtitlesForcedLanguage:Ft,unitedVideoId:kt,isClip:Tt,live:qt,albumId:y,statPlace:_,autoplay:T,muted:A,volume:R,fromTime:P,canRewindLive:E,showAds:F,adsSlotId:U,adsParams:le,adsAutoplayParam:ae,duration:Vt,logoClickable:J,logoHidden:we,isTouch:ee!=null?ee:me,repeat:He,loop:it,showNextPrevButtons:this.needToShowNextPrevButtons(),nextButtonActive:this.isNextButtonActive(),prevButtonActive:this.isPrevButtonActive(),endScreenVideoTitle:$e.nextVideoTitle,endScreenVideoThumb:$e.nextVideoThumb,isOneVideoPlaylist:this.isOneVideoPlaylist()},dt={pictureInPictureApi:this.pictureInPictureApi,annotationsApi:this.annotationsApi,slotsApi:this.slotsApi,focusManager:this.focusManager};this.log({message:`create player, props: ${JSON.stringify(Ve)}`});let St=(a=this.interactiveController)==null?void 0:a.state.statistics$.getValue(),fe=(St==null?void 0:St.oneStat)||this.createOneStat(e,t),Be=this.createThinOneStat(e,t),We;et&&(We=new vd.MediascopePixel({pixels:et})),(fe||Be)&&(this.statistics=new _p(fe,Be,We,St==null?void 0:St.statSubscription)),this.uiConfig.features.sentry&&this.uiConfig.sentry.dsn&&new Qa(this.uiConfig.sentry,{version:Wa,env:Bu},{movieId:kt,albumId:y,place:_,autoplay:(l=T&&!this.interactiveController)!=null?l:!1,mobile:ee!=null?ee:me,clip:Tt}),this.interactiveController&&((u=this.prevIsid)!=null||(this.prevIsid=(s=(d=this.statistics)==null?void 0:d.oneStat)==null?void 0:s.isid$.getValue())),this.sentry=Gs(Gs({},this.sentry),Qa.getInstance());let Xt=!!D,It=[],ai="tooltip_interactive_go_back_disabled_first";if(Xt&&this.interactiveController){let vi=this.interactiveController.state.isInitialChapter$.getValue(),ot=this.interactiveController.getHistoryState();vi&&It.push("REPLAY_BUTTON"),this.interactiveController.getIsSeekable().getValue()||It.push("SEEK_TO_INTERACTIVE_BUTTON"),ot.hasPrevChapter$.getValue()||(It.push("PLAY_PREV_CHAPTER_BUTTON"),vi||(ot.isGoBackLimited$.getValue()?ai="tooltip_interactive_go_back_disabled_limit":ai="tooltip_interactive_go_back_disabled"))}let fi=()=>{var vi;this.isInited=!1,this.prevIsid=void 0;let ot=(o==null?void 0:o.info.isEnded$.getValue())&&((vi=this.interactiveController)==null?void 0:vi.state.isEndChapter$.getValue());G.onReplayInteractiveVideo&&!ot?G.onReplayInteractiveVideo():this.replayInteractiveVideo()},Bi=He&&this.videoConfig.videos.length===1;this.store=Ub({player:o,interfaceLanguage:Z,isCyrillicRelatedInterface:re,videoId:kt,isClip:Tt,isLiveCatchUpMode:Ce,isAudioDisabled:_e,statAuthToken:x,callbacks:G,webApi:dt,videoEpisodes:At,previewThumbsData:ti,canDownload:Qe,uiConfig:this.uiConfig,coreConfig:this.coreConfig,metaConfig:this.metaConfig,disabledControls:It,isInteractive:Xt,saveRate:ne,interactiveRanges$:(m=this.interactiveController)==null?void 0:m.state.interactiveRanges$,isInteractiveTime$:(p=this.interactiveController)==null?void 0:p.state.isInteractiveTime$,stopPlayer:()=>this.stop(),replayInteractive:fi,playPrevChapterDisabledTooltip:ai,hasInteractiveBranches:!!((b=(v=this.interactiveController)==null?void 0:v.getChapterBranches())!=null&&b.length),additionalButtons:this.uiConfig.features.additionalButtons?K:[],additionalSettingsMenuItems:se!=null?se:[],additionalContextMenuItems:xe!=null?xe:[],playPrevVideo:()=>this.playPrevVideo(),playNextVideo:()=>this.playNextVideo(),onVideoChanged:vi=>{var ot;return(ot=this.sveltePersistentLayerComponent)==null?void 0:ot.startVideoChangedAnimation(vi)},looped:this.uiConfig.features.useLoopSetting?it:Bi,statistics:this.statistics,internalsExposure:this.internalsExposure,playerView:this.videoConfig.playerView,playerId:this.playerId});let{stores:Bt}=this.microStoresRoot=L$(),_o=()=>{var vi,ot,Jt,Hi,xi,oi;if(!this.store||!this.microStoresRoot||!this.videoConfig)return;this.subscription.add(this.store.state.currentFormat$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onCurrentFormatChanged)==null?void 0:nt.call(G,lt)})),this.subscription.add(Bt.interactiveControlsOpacity$.subscribe(lt=>{var nt;lt!==null&&((nt=this==null?void 0:this.interactiveController)==null||nt.setDisabledControls(lt))})),this.subscription.add(this.store.state.throughputEstimation$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onThroughputEstimationChanged)==null?void 0:nt.call(G,lt)})),this.subscription.add(this.store.state.trafficSavingEnabled$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onTrafficSavingEnabledChanged)==null?void 0:nt.call(G,lt)})),this.subscription.add(this.store.state.highQualityEnabled$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onHighQualityEnabledChanged)==null?void 0:nt.call(G,lt)})),this.subscription.add(this.store.state.isAutoQualityEnabled$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onAutoQualityEnabledChanged)==null?void 0:nt.call(G,!!lt)})),this.subscription.add(new Oi.Observable(lt=>{this.store&&this.subscription.add(this.store.state.currentPlaybackRate$.subscribe(nt=>lt.next(nt)))}).pipe((0,Oi.skip)(1)).subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onCurrentPlaybackRateChanged)==null?void 0:nt.call(G,lt)})),this.subscription.add(this.store.state.volume$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onVolumeChange)==null?void 0:nt.call(G,lt)})),this.subscription.add(this.store.state.muted$.subscribe(lt=>{var nt,Ei,tn,Bo;if(lt)(nt=G==null?void 0:G.onMute)==null||nt.call(G);else{let bt=(tn=((Ei=this.store)==null?void 0:Ei.state.volume$)&&ye(this.store.state.volume$))!=null?tn:0;(Bo=G==null?void 0:G.onUnmute)==null||Bo.call(G,bt)}})),this.subscription.add(this.store.state.videoBitrate$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onVideoBitrateChanged)==null?void 0:nt.call(G,lt)})),this.subscription.add(this.store.state.isInteractiveTime$.subscribe(lt=>{var nt;let Ei=(nt=this.store)==null?void 0:nt.ui.controls.disabledControls$;Ei&&(lt&&!Ei.includes(Gd)&&Ei.add(Gd),lt||Ei.remove(Gd))})),this.subscription.add(this.store.ui.isFullscreen.subscribe(lt=>Up(this,null,function*(){var nt;if(!Xc.clientChecker.browser.isSamsungBrowser||!lt||!this.interactiveController)return;document.fullscreenElement===this.shadowRootContainer&&(yield this.replayInteractiveChapter((nt=this.videoConfig)==null?void 0:nt.callbacks.onExternalFullscreenExit))}))),this.statistics&&this.statistics.oneStat&&this.subscription.add(this.statistics.oneStat.vsid$.subscribe(lt=>{var nt;return(nt=G==null?void 0:G.onVSIDChanged)==null?void 0:nt.call(G,lt)})),this.initMediaSession(),N(or,{interactiveController:this.interactiveController,interactiveContainer:this.interactiveContainer,sources:Ee,store:this.store,microStoresRoot:this.microStoresRoot,videoConfig:this.videoConfig,uiConfig:this.uiConfig,title:Te,thumbUrl:Fe,subtitles:Lt,subtitlesForcedLanguage:Ft,live:qt,preload:I,autoplay:T,muted:A,volume:R,fromTime:P,canRewindLive:E,supportLink:z,showAds:F,adsSlotId:U,adsParams:le,adsAutoplayParam:ae,duration:Vt,logoClickable:J,logoHidden:we,isMobile:ee!=null?ee:me,failoverHosts:pe,fullScreenTarget:ge,saveRate:ne,shadowRootContainer:this.shadowRootContainer,showMiniTimer:Ge,outerContainerRef:this.rootContainer,showNextPrevButtons:this.needToShowNextPrevButtons(),nextButtonActive:this.isNextButtonActive(),prevButtonActive:this.isPrevButtonActive(),endScreenVideoTitle:$e.nextVideoTitle,endScreenVideoThumb:$e.nextVideoThumb,isOneVideoPlaylist:this.isOneVideoPlaylist(),playPrevChapter:()=>this.playPrevChapter(),seekToInteractive:()=>this.seekToInteractive(),volumeMultiplier:ce,showEndScreen:Ne,showAutoplayNext:Le,adsExternalApi:Y,adsJson:Pe,getVideoDeeplink:this.videoConfig.getVideoDeeplink},!0);let Ti={target:this.playerContainer,props:n(or)};this.svelteRootComponent=is(fg,Ti),this.addPlayerInfoSubscriptions(),this.isInited||(this.isInited=!0,(Jt=(ot=(vi=this.videoConfig)==null?void 0:vi.callbacks)==null?void 0:ot.onInited)==null||Jt.call(ot)),(Hi=this.internalsExposure)==null||Hi.expose({player:this,videoConfig:this.videoConfig,coreConfig:this.coreConfig,uiConfig:this.uiConfig,statisticsConfig:this.statisticsConfig,logger:this.logger,log:this.log}),this.uiConfig.devNullLog&&((oi=(xi=this.videoConfig)==null?void 0:xi.callbacks)!=null&&oi.onDevNullLog)?md.devNull.subscribe("ui",this.videoConfig.callbacks.onDevNullLog):md.devNull.destroy("ui")};this.coreConfig.asyncResolveClientChecker?Xc.clientChecker.isInited$.subscribe(vi=>{vi&&(console.log("UI SDK async start"),_o())}):_o()}addPlayerInfoSubscriptions(){var e,t;let o=this.store,r=(e=this.microStoresRoot)==null?void 0:e.stores;if(!o||!r)return;let a=(t=this.videoConfig)==null?void 0:t.callbacks;a&&this.subscription.add(o.playerPhase.subscribe(d=>{var s;return(s=a.onPlayerPhaseChanged)==null?void 0:s.call(a,d)})).add(o.state.playbackState$.subscribe(d=>{var s;return d&&((s=a.onPlaybackStateChanged)==null?void 0:s.call(a,d))})).add(o.state.playbackStateRealistic$.subscribe(d=>{d?this.stateContainer.setAttribute("data-playback-state",d):this.stateContainer.removeAttribute("data-playback-state")})).add(o.state.isLive$.subscribe(d=>{var s;return(s=a.onIsLiveChanged)==null?void 0:s.call(a,d)})).add(o.state.isActiveLive$.subscribe(d=>{var s;return(s=a.onIsActiveLiveChanged)==null?void 0:s.call(a,d)})).add(o.state.isAudioAvailable$.subscribe(d=>{var s;return(s=a.onIsAudioAvailableChanged)==null?void 0:s.call(a,d)})).add(o.state.currentQuality$.subscribe(d=>{var s;return(s=a.onCurrentQualityChanged)==null?void 0:s.call(a,d)})).add(o.state.availableQualities$.subscribe(d=>{var s;return(s=a.onAvailableQualitiesChanged)==null?void 0:s.call(a,d.map(({value:u})=>u).filter(u=>u!=="auto"))})).add(o.state.availableAudioStreams$.subscribe(d=>{d.length>1&&a.onAudioLanguagesAvailable&&a.onAudioLanguagesAvailable()})).add(r.pictureInPicture$.isActive$.subscribe(d=>{var s,u;return d?(s=a.onPiPEnter)==null?void 0:s.call(a):(u=a.onPiPExit)==null?void 0:u.call(a)}));let l=a==null?void 0:a.uiInfo;l&&this.subscription.add(o.ui.controlsVisible.subscribe(d=>{var s;return(s=l.onControlsVisibleChanged)==null?void 0:s.call(l,d)})).add(o.ui.isMobile.subscribe(d=>{var s;return(s=l.onIsMobileChanged)==null?void 0:s.call(l,d)})).add(o.ui.playerSize.subscribe(d=>{var s;return(s=l.onPlayerSizeChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.prevButton.subscribe(d=>{var s;return(s=l.onPrevButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.playButton.subscribe(d=>{var s;return(s=l.onPlayButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.replayButton.subscribe(d=>{var s;return(s=l.onReplayButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.nextButton.subscribe(d=>{var s;return(s=l.onNextButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.playPrevChapterButton.subscribe(d=>{var s;return(s=l.onPlayPrevChapterChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.seekToInteractiveButton.subscribe(d=>{var s;return(s=l.onSeekToInteractiveButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.interactiveGraphButton.subscribe(d=>{var s;return(s=l.onGraphButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.liveButton.subscribe(d=>{var s;return(s=l.onLiveButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.time.subscribe(d=>{var s;return(s=l.onTimeUpdateChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.episodes.subscribe(d=>{var s;return(s=l.onEpisodesChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.subtitles.subscribe(d=>{var s;return(s=l.onSubtitlesChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.topLeft.subscribe(d=>{var s;return(s=l.onTopLeftControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.topRight.subscribe(d=>{var s;return(s=l.onTopRightControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.bottomLeft.subscribe(d=>{var s;return(s=l.onBottomLeftControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.bottomRight.subscribe(d=>{var s;return(s=l.onBottomRightControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.middle.subscribe(d=>{var s;return(s=l.onMiddleControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.bottom.subscribe(d=>{var s;return(s=l.onBottomControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.videoTitleInfo.subscribe(d=>{var s;return(s=l.onTitleChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.settings.subscribe(d=>{var s;return(s=l.onSettingsChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.fullscreen.subscribe(d=>{var s;return(s=l.onFullscreenChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.chromecast.subscribe(d=>{var s;return(s=l.onChromecastChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.pip.subscribe(d=>{var s;return(s=l.onPipChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.vkLogo.subscribe(d=>{var s;return(s=l.onVkLogoChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.interactiveTimeIndicator.subscribe(d=>{var s;return(s=l.onInteractiveTimeIndicatorChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.timeline.subscribe(d=>{var s;return(s=l.onTimelineChanged)==null?void 0:s.call(l,d)}))}playNextVideo(){this.videoConfig&&(this.currentPlayingVideoIndex++,this.currentPlayingVideoIndex>=this.videoConfig.videos.length&&(this.currentPlayingVideoIndex=0),this.log({message:`play next video, index: ${this.currentPlayingVideoIndex}`}),this.createPlayerWithCurrentVideo())}playPrevVideo(){this.videoConfig&&(this.currentPlayingVideoIndex--,this.currentPlayingVideoIndex<0&&(this.currentPlayingVideoIndex=this.videoConfig.videos.length-1),this.log({message:`play prev video, index: ${this.currentPlayingVideoIndex}`}),this.createPlayerWithCurrentVideo())}createPlayerWithCurrentVideo(e,t=!0){var o;if(!this.videoConfig)return;let r=this.videoConfig.videos[this.currentPlayingVideoIndex];if(!r){this.log({message:"no next video"});return}this.isInited&&(0,Oi.isNonNullable)(r.unitedVideoId)&&((o=this.store)==null||o.actions.internal.nextMovie(r.unitedVideoId)),this.unmountComponent(this.svelteRootComponent),this.createPlayer(r,{autoplay:t,fromTime:0},e)}playPrevChapter(){var e;(e=this.interactiveController)==null||e.playPrevChapter()}seekToInteractive(){var e;let t=(e=this.interactiveController)==null?void 0:e.getNextInteractiveStartTime();typeof t=="number"&&this.seekTime(t/1e3)}initInteractives(){return Up(this,null,function*(){var e,t,o,r,a,l;if((e=this.videoConfig)!=null&&e.interactiveData)try{let{Interactives:d}=yield import("@vkontakte/videoplayer-interactive/es2015");this.interactiveContainer=document.createElement("div"),this.interactiveContainer.classList.add("interactive-root");let s=(t=this.store)==null?void 0:t.interfaceLanguage$,u=s?ye(s):this.videoConfig.interfaceLanguage,{projectInfo:m,initChapterId:p,historyApi:v,videoLoader:b}=this.videoConfig.interactiveData;this.interactiveController=new d({parentElement:this.interactiveContainer,fullscreenTargetElement:this.playerContainer,lang:u,graph:this.uiConfig.features.interactiveGraph,projectInfo:m,initChapterId:p,historyApi:v,vkVideoLoader:b,lastFrame:this.uiConfig.features.interactiveLastFrame,permanentTextControls:this.uiConfig.features.interactiveTextPermanent,interactiveTimeOpenUri:this.uiConfig.features.interactiveTimeOpenUri,initSeamless:!0,config:this.uiConfig.interactive,coreConfig:this.coreConfig,createOneStat:this.createOneStat,isTouch:this.videoConfig.isTouch,animationsFeatureToggles:{areaControlShadow:this.uiConfig.features.interactiveAreaControlShadow,controlsExpectTimeBlinkAnimation:this.uiConfig.features.interactiveControlsExpectTimeBlinkAnimation,controlsTapPlace:this.uiConfig.features.interactiveControlsTapPlace,controlsFillAnimation:this.uiConfig.features.interactiveControlsFillAnimation,controlsHideAnimation:this.uiConfig.features.interactiveControlsHideAnimation},endChapterHistoryFix:this.uiConfig.features.interactiveHistoryEndChapterFix});let{isInteractiveExpectation$:y,isSeekable$:_}=this.interactiveController.state;this.uiConfig.features.seekToInteractive&&this.subscription.add(_.subscribe(I=>{if(!this.isInited)return;let T=this.store;I?T.ui.controls.disabledControls$.remove("SEEK_TO_INTERACTIVE_BUTTON"):T.ui.controls.disabledControls$.add("SEEK_TO_INTERACTIVE_BUTTON")})),this.subscription.add(y.subscribe(I=>{this.store&&this.store.state.isInteractiveExpectation$.set(I)}));let x=!0;if(this.subscription.add(this.interactiveController.events.playerChanged$.subscribe(I=>{if(!this.videoConfig)return;this.videoConfig.videos[this.currentPlayingVideoIndex]=KT(Gs({},I.config),{title:(m==null?void 0:m.title)||I.config.title});let T=x?this.videoConfig.autoplay:!0;this.createPlayerWithCurrentVideo(I.player,T),x&&(x=!1)})),this.interactiveSubscription.add(this.interactiveController.events.interactiveActionChoice$.subscribe(({type:I,actionType:T})=>{var R,A,P,E,z,F;if(!this.store||!this.microStoresRoot)return;let U=y.getValue();if(I==="action-choice"&&T==="setRandomBranch"&&(this.microStoresRoot.stores.graphIsOpened$.set(!1),this.store.ui.controls.disabledControls$.remove(Yd)),I==="action-choice-canceled"){let X=ye(this.store.state.isPlaying$)||U;if(((P=(R=this.videoConfig)==null?void 0:R.isTouch)!=null?P:(A=this.videoConfig)!=null&&A.isMobile)&&X){this.store.ui.interactiveHideMobileControls.set(!0);return}(F=(E=this.videoConfig)==null?void 0:(z=E.callbacks).onDisabledInteractiveClick)==null||F.call(z)}})),this.interactiveSubscription.add(this.interactiveController.events.interactiveContainerFakeRemoved$.subscribe(({type:I,removeAllOpenURI:T})=>{this.store&&I==="container-fake-removed"&&T&&this.store.ui.controls.disabledControls$.remove(Yd)})),yield this.interactiveController.setManifest(this.videoConfig.interactiveData.manifest),(r=(o=this.videoConfig)==null?void 0:o.callbacks)!=null&&r.onInteractiveHistoryChanged){let I=this.interactiveController.getHistoryState();this.subscription.add(I.history$.subscribe(T=>{var R,A,P;T.length&&((P=(A=(R=this.videoConfig)==null?void 0:R.callbacks)==null?void 0:A.onInteractiveHistoryChanged)==null||P.call(A,T))}))}(l=(a=this.videoConfig)==null?void 0:a.callbacks)!=null&&l.onInteractiveChapterChanged&&this.subscription.add(this.interactiveController.events.chapterChanged$.subscribe(I=>{var T,R,A;(A=(T=this.videoConfig)==null?void 0:(R=T.callbacks).onInteractiveChapterChanged)==null||A.call(R,I.chapter,I.manifestVideo)})),this.uiConfig.features.interactiveTimeIndicator&&this.subscription.add(this.interactiveController.events.noInteraction$.subscribe(()=>{var I,T,R,A;(I=this.microStoresRoot)==null||I.stores.showInteractiveTimeIndicatorTooltip$.set(!0,!0),(A=(T=this.videoConfig)==null?void 0:(R=T.callbacks).onInteractiveTimeIndicatorClick)==null||A.call(R)})),this.interactiveSubscription.add(this.interactiveController.events.error$.subscribe(I=>{this.log({message:I.toString()})}))}catch(d){this.log({message:d.message})}})}initPlayer(e,t={}){var o,r,a,l,d,s,u,m,p,v,b,y,_,x,I,T,R,A,P,E,z,F,U,X,ae;if(!this.isConnected){this.postponedInitParams=[e,t];return}if(!Array.isArray(e.videos)||e.videos.length===0&&!e.interactiveData){let Z=new Error("empty videos");this.fatalError$.next(Z),(r=(o=e.callbacks)==null?void 0:o.onCrashed)==null||r.call(o,Z.message);return}else this.fatalError$.next(null);if(this.videoConfig=zc(qT,(0,Oi.cloneDeepWith)(e,Z=>Z instanceof xg?Z:void 0)),this.playerId=(0,Oi.getPlayerId)(e.playerId),this.uiConfig=v_((a=t.ui)!=null?a:{}),this.updatePersistentLayerProps(),this.coreConfig=(l=t.core)!=null?l:{},this.statisticsConfig=(d=t.statistics)!=null?d:{},this.metaConfig=t.meta,this.uiConfig.features.forcePlayerDisplayBlock&&(this.rootContainer&&(this.rootContainer.style.minHeight="unset"),this.style.display="block",this.style.width="100%",this.style.height="100%"),this.videoConfig.playerView==="preview"&&(this.playerContainer.style.contain="none"),this.sentry={config:(s=this.uiConfig.sentry)!=null?s:{}},this.uiConfig.features.exposeInternalsToGlobal&&((u=this.internalsExposure)!=null||(this.internalsExposure=new Oi.InternalsExposure("ui",this.playerId))),md.devNull.push("ui",{key:"videoplayer_embed",strings:["new","player_init_player","ads.enable: "+this.uiConfig.ads.enable,"showAds: "+((m=this.videoConfig)==null?void 0:m.showAds)],numbers:[(0,Wp.now)()]}),(0,Oi.isNonNullable)(this.videoConfig.isMediaSessionEnabled)&&(this.uiConfig.features.mediaSession=(v=(p=this.uiConfig.features.mediaSession)!=null?p:this.videoConfig.isMediaSessionEnabled)!=null?v:!0),(0,Oi.isNonNullable)(this.videoConfig.isPictureInPictureEnabled)&&(this.uiConfig.features.pip=(y=(b=this.uiConfig.features.pip)!=null?b:this.videoConfig.isPictureInPictureEnabled)!=null?y:!0,this.uiConfig.features.dpip=(x=(_=this.uiConfig.features.dpip)!=null?_:this.videoConfig.isPictureInPictureEnabled)!=null?x:!0),this.uiConfig.ads.paramsOverride=Gs({preview:(I=this.uiConfig.ads.preview)!=null?I:this.videoConfig.adsPreviewParam},this.uiConfig.ads.paramsOverride),this.videoConfig.isTouch=(R=(T=this.uiConfig.isMobile)!=null?T:this.videoConfig.isTouch)!=null?R:this.videoConfig.isMobile,(A=this.videoConfig).autoplay&&(A.autoplay=this.uiConfig.features.autoplay),this.videoConfig.showAds=(P=this.uiConfig.ads.enable)!=null?P:this.videoConfig.showAds,this.videoConfig.adsSlotId=(E=this.uiConfig.ads.slot)!=null?E:this.videoConfig.adsSlotId,this.videoConfig.logoHidden=!((z=this.uiConfig.showLogo)!=null?z:!this.videoConfig.logoHidden),(F=this.videoConfig).canRewindLive&&(F.canRewindLive=this.uiConfig.features.liveRewind),this.videoConfig.supportLink=(U=this.videoConfig.supportLink)!=null?U:this.uiConfig.supportLink,this.videoConfig.showEndScreen=this.uiConfig.features.endScreen&&this.videoConfig.showEndScreen,this.videoConfig.showAutoplayNext=this.uiConfig.features.autoplayNext&&this.videoConfig.showAutoplayNext,this.videoConfig.showNextPrevButtons=this.uiConfig.features.nextPrevButtons&&this.videoConfig.showNextPrevButtons,this.currentPlayingVideoIndex=this.videoConfig.videoIndex&&((X=this.videoConfig.videos)!=null&&X[this.videoConfig.videoIndex])?this.videoConfig.videoIndex:0,this.needToRepeatPlaylist=this.videoConfig.repeat,this.uiConfig.features.pip){let Z={enabled:this.videoConfig.pipEnabled};this.uiConfig.features.dpip?this.pictureInPictureApi=Vp.getLatestSupportedVersion(Z):this.pictureInPictureApi=new Us(Z)}this.mediaSessionApi=this.uiConfig.features.mediaSession?new Lp:void 0,this.slotsApi=this.uiConfig.features.slots?new Ep(this.uiConfig.disabledSlotIds):void 0,this.annotationsApi=this.uiConfig.features.annotations?new Rp(this.uiConfig.features.annotationsInside):void 0,this.annotationsApi&&!this.uiConfig.features.annotationsInside&&this.annotationsApi.init(this.rootContainer),this.focusManager=this._shadowRoot?new Fp(this._shadowRoot):void 0,this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteRootComponent),this.unmountComponent(this.svelteErrorComponent),this.isInited=!1,this.prevIsid=void 0,this.interactiveController&&(this.interactiveController.destroy(),this.interactiveController=void 0,this.interactiveSubscription.unsubscribe()),this.videoConfig.interactiveData?this.initInteractives():this.createPlayer(this.videoConfig.videos[this.currentPlayingVideoIndex]),T$(this.pictureInPictureApi)&&this.pictureInPictureApi.setPlayerDomElement(this.playerContainer,this._shadowRoot),(ae=this.slotsApi)==null||ae.init(this.shadowRootContainer,this.store)}isOneVideoPlaylist(){return this.videoConfig?this.videoConfig.videos.length===1:!1}updateVideos(e,t){if(!this.videoConfig)return;this.log({message:`update ${t} videos, videos: ${JSON.stringify(e)}`}),t==="prev"?(this.videoConfig.videos.splice(0,this.currentPlayingVideoIndex),this.videoConfig.videos.unshift(...e),this.currentPlayingVideoIndex=e.length):t==="next"&&(this.videoConfig.videos.splice(this.currentPlayingVideoIndex+1),this.videoConfig.videos.push(...e));let o=this.getNextVideoInfo();n(or)&&(n(or).showNextPrevButtons=this.needToShowNextPrevButtons(),n(or).nextButtonActive=this.isNextButtonActive(),n(or).prevButtonActive=this.isPrevButtonActive(),n(or).endScreenVideoTitle=o.nextVideoTitle,n(or).endScreenVideoThumb=o.nextVideoThumb,n(or).isOneVideoPlaylist=this.isOneVideoPlaylist())}updatePrevVideos(e){this.updateVideos(e,"prev")}updateNextVideos(e){this.updateVideos(e,"next")}initMediaSession(){var e,t;this.mediaSessionApi&&((e=this.unsubscribePlayerPhaseSubscription)==null||e.call(this),this.mediaSessionApi.clearSubscriptions(),this.unsubscribePlayerPhaseSubscription=(t=this.store)==null?void 0:t.playerPhase.subscribe(o=>{o==="video"?this.setupMediaSessionForVideo():o==="ads"&&this.setupMediaSessionForAds()}))}setupMediaSessionForVideo(){if(!(!this.videoConfig||!this.mediaSessionApi))try{let{title:e,thumbUrl:t}=Gs({},this.videoConfig.videos[this.currentPlayingVideoIndex]),o=[["play",()=>this.play()],["pause",()=>this.pause()],["seekto",r=>this.seekTime(r.seekTime)]];this.videoConfig.videos.length>1&&(this.currentPlayingVideoIndex<this.videoConfig.videos.length-1&&o.push(["nexttrack",()=>{var r,a,l;if(this.uiConfig.features.useCallbackForMediaSessionNextPrevClick)try{(l=(a=(r=this.videoConfig)==null?void 0:r.callbacks)==null?void 0:a.onNextVideoClick)==null||l.call(a)}catch(d){this.log({message:"onNextVideoClick callback failed to execute"})}else this.playNextVideo()}]),this.currentPlayingVideoIndex>0&&o.push(["previoustrack",()=>{var r,a,l;if(this.uiConfig.features.useCallbackForMediaSessionNextPrevClick)try{(l=(a=(r=this.videoConfig)==null?void 0:r.callbacks)==null?void 0:a.onPrevVideoClick)==null||l.call(a)}catch(d){this.log({message:"onPrevVideoClick callback failed to execute"})}else this.playPrevVideo()}])),this.mediaSessionApi.setMetaData({title:e,thumbUrl:t}),this.mediaSessionApi.updateActionHandlers(o),this.mediaSessionApi.attachToStore(this.store)}catch(e){this.log({message:e.message})}}setupMediaSessionForAds(){if(!(!this.videoConfig||!this.mediaSessionApi))try{let e="Реклама",t=[["play",()=>this.play()],["pause",()=>this.pause()]];this.mediaSessionApi.setMetaData({title:e}),this.mediaSessionApi.updateActionHandlers(t),this.mediaSessionApi.attachToStore(this.store)}catch(e){this.log({message:e.message})}}moveTo(e){this.shadowDOMCallbacksDisabled=!0,e.append(this),this.shadowDOMCallbacksDisabled=!1}play(){var e,t,o,r;this.isControlDisabled("PLAY_BUTTON")||(e=this.store)!=null&&e.playerPhase.is("LiveWaitingStart")||(t=this.store)!=null&&t.playerPhase.is("LiveWaitingRecover")||(o=this.store)!=null&&o.playerPhase.is("LiveWaitingRecord")||(this.log({message:"play"}),(r=this.svelteRootComponent)==null||r.play())}pause(){var e;this.log({message:"pause"}),(e=this.svelteRootComponent)==null||e.pause()}stop(){var e;if(!this.videoConfig)return;this.log({message:"stop"});let t=!!this.interactiveController;t&&(this.interactiveController.destroy(),this.interactiveController=void 0,this.interactiveContainer=void 0,this.interactiveSubscription.unsubscribe()),this.unmountComponent(this.svelteStubComponent),(e=this.mediaSessionApi)==null||e.destroy();let o=this.videoConfig.videos[0];o&&(this.unmountComponent(this.svelteRootComponent),t?(this.videoConfig.autoplay=!1,this.initInteractives()):this.createPlayer(o))}setMuted(e){var t;this.log({message:`set muted, muted: ${e}`}),(t=this.svelteRootComponent)==null||t.setMuted(e)}toggleSubtitle(){var e;this.log({message:"toggle subtitle"}),(e=this.svelteRootComponent)==null||e.toggleSubtitle()}changeSubtitle(e,t){var o;this.log({message:"change subtitle"}),(o=this.svelteRootComponent)==null||o.changeSubtitle(e,t)}hideControls(){var e;this.log({message:"hide controls"}),(e=this.svelteRootComponent)==null||e.hideControls()}showControls(){var e;this.log({message:"show controls"}),(e=this.svelteRootComponent)==null||e.showControls()}setPiPEnabled(e){var t,o;(o=(t=this.store)==null?void 0:t.webApi.pictureInPictureApi)==null||o.setEnabled(e)}setVolume(e){var t;this.log({message:`set volume, volume: ${e}`}),(t=this.svelteRootComponent)==null||t.setVolume(e)}setRepeat(e){this.log({message:`set repeat, repeat: ${e}`}),this.needToRepeatPlaylist=e,n(or)&&(n(or).needToRepeatPlaylist=this.needToRepeatPlaylist,n(or).showNextPrevButtons=this.needToShowNextPrevButtons(),n(or).nextButtonActive=this.isNextButtonActive(),n(or).prevButtonActive=this.isPrevButtonActive())}seekTime(e){var t;this.isControlDisabled("TIMELINE")||(this.log({message:`seek time, time: ${e}`}),(t=this.svelteRootComponent)==null||t.seekTime(e))}seekEpisodeStartTime(e){var t;this.log({message:`seek episode start time, time: ${e}`}),(t=this.svelteRootComponent)==null||t.seekEpisodeStartTime(e)}returnFocusToEpisodes(){var e;this.log({message:"return focus to episodes button"}),(e=this.svelteRootComponent)==null||e.returnFocusToEpisodes()}setPlaybackRate(e){var t;this.log({message:`set playback rate to: ${e}`}),(t=this.svelteRootComponent)==null||t.setPlaybackRate(e)}setAutoQualityLimits(e){var t,o,r;this.log({message:`set auto quality limitation. Max: ${(t=e.max)!=null?t:"none"}. Min: ${(o=e.min)!=null?o:"none"}`}),(r=this.svelteRootComponent)==null||r.setAutoQualityLimits(e)}setAutoQuality(){var e;(e=this.svelteRootComponent)==null||e.setAutoQuality()}toggleTrafficSaving(e){var t;(t=this.svelteRootComponent)==null||t.toggleTrafficSaving(e)}toggleHighQuality(e){var t;(t=this.svelteRootComponent)==null||t.toggleHighQuality(e)}changeAudioStream(e){var t;(t=this.svelteRootComponent)==null||t.changeAudioStream(e)}addLanguage(e){var t;(t=this.store)==null||t.actions.internal.addLanguage(e)}setLanguage(e){return Up(this,null,function*(){var t;yield(t=this.store)==null?void 0:t.actions.internal.setLanguage(e)})}setLiveStart(e){var t,o;let r=this.isLiveTailPlaying();this.log({message:`live started: liveTailPlaying = ${r}`}),r||((t=this.store)==null||t.actions.internal.setLiveWaitingRecover(!1),(o=this.store)==null||o.actions.internal.setLiveWaitingStart(!1),this.unmountComponent(this.svelteRootComponent),this.createPlayer(e,{autoplay:!0}))}setLiveWaitingStart(){var e;this.log({message:"live waiting"}),(e=this.store)==null||e.actions.internal.setLiveWaitingStart(!0)}isLiveTailPlaying(){var e;let t=(e=this.store)==null?void 0:e.getPlayer();if(!t)return!1;let{info:o}=t;return o.canPlayLiveTailBuffer$.getValue()&&!o.isStalled$.getValue()&&!o.atLiveEdge$.getValue()}setLiveWaitingRecover(e=!1){var t;let o=this.isLiveTailPlaying(),r=e||!o;this.log({message:`live waiting recover: forceImmediate = ${e}, liveTailPlaying = ${o}`});let a=()=>{var l;(l=this.store)==null||l.actions.internal.setLiveWaitingRecover(!0)};r&&a(),(t=this.store)!=null&&t.callbacks&&(this.store.callbacks.onLiveEnded=()=>{var l;r||a(),(l=this.store)==null||l.destroy()})}setLiveWaitingRecord(){var e;let t=this.isLiveTailPlaying(),o=!t;this.log({message:`live waiting record: liveTailPlaying = ${t}`});let r=()=>{var a;(a=this.store)==null||a.actions.internal.setLiveWaitingRecord(!0)};o&&r(),(e=this.store)!=null&&e.callbacks&&(this.store.callbacks.onLiveEnded=()=>{var a;o||r(),(a=this.store)==null||a.destroy()})}setLiveEnd(e){var t;let o=this.isLiveTailPlaying(),r=!o;this.log({message:`live ended: liveTailPlaying = ${o}`});let a=()=>{var l,d;(l=this.store)==null||l.actions.internal.setLiveWaitingRecover(!1),(d=this.store)==null||d.actions.internal.setLiveWaitingRecord(!1),this.unmountComponent(this.svelteRootComponent),this.createPlayer(e,{autoplay:!1})};if(r){a();return}(t=this.store)!=null&&t.callbacks&&(this.store.callbacks.onLiveEnded=a)}setLiveLowLatency(e){var t;this.log({message:"live switch to low latency "+e}),(t=this.store)==null||t.actions.external.setLiveLowLatency(e)}setLooped(e){var t;(t=this.store)==null||t.actions.internal.setLooped(e)}getDebugData(){var e,t;return(t=(e=this.store)==null?void 0:e.actions.internal.getDebugTextData())!=null?t:""}getDeviceId(){var e,t,o;return(o=(t=(e=this.statistics)==null?void 0:e.oneStat)==null?void 0:t.getDeviceId())!=null?o:void 0}replayInteractiveVideo(){this.interactiveController&&this.interactiveController.setChapter()}replayInteractiveChapter(e){return Up(this,null,function*(){var t,o;if(this.interactiveController&&((t=this.store)!=null&&t.state.positionExact$)){let r=ye(this.store.state.positionExact$),l=ye(this.store.state.interactiveEpisodes$).find(s=>!s.completed);this.interactiveController.events.playerChanged$.pipe((0,Oi.once)()).subscribe(()=>{l&&r>=l.time?this.seekTime(l.time):this.seekTime(r),e==null||e()});let d=this.interactiveController.getCurrentChapter();yield this.interactiveController.setChapter({chapterId:(o=d==null?void 0:d.chapter)==null?void 0:o.id,pushToHistory:!1})}})}showInteractiveIndicatorTooltip(e,t=!1){var o;(o=this.microStoresRoot)==null||o.stores.showInteractiveTimeIndicatorTooltip$.set(e,t)}switchToActiveLive(){var e;(e=this.store)==null||e.actions.internal.switchToActiveLive()}updateAdditionalSettingsItem(e,t){var o;(o=this.store)==null||o.actions.external.updateAdditionalSettingsItem(e,t)}addAdditionalSettingsItem(e){var t;(t=this.store)==null||t.actions.external.addAdditionalSettingsItem(e)}removeAdditionalSettingsItem(e){var t;(t=this.store)==null||t.actions.external.removeAdditionalSettingsItem(e)}updateAdditionalContextItem(e,t){var o;(o=this.store)==null||o.actions.external.updateAdditionalContextItem(e,t)}addAdditionalContextItem(e){var t;(t=this.store)==null||t.actions.external.addAdditionalContextItem(e)}removeAdditionalContextItem(e){var t;(t=this.store)==null||t.actions.external.removeAdditionalContextItem(e)}updateAdditionalButton(e,t){var o;(o=this.store)==null||o.actions.external.updateAdditionalButton(e,t)}addAdditionalButton(e){var t;(t=this.store)==null||t.actions.external.addAdditionalButton(e)}removeAdditionalButton(e){var t;(t=this.store)==null||t.actions.external.removeAdditionalButton(e)}updateStatContext(e){this.statistics&&(this.statistics.oneStat&&this.statistics.oneStat.updateContext(e),this.statistics.thinOneStat&&this.statistics.thinOneStat.updateContext(e))}handleTimerNextVideo(e){var t;(t=this.store)==null||t.actions.internal.setTimerNextVideoRunning(e)}togglePictureInPicture(){var e;(e=this.store)==null||e.actions.internal.togglePictureInPicture()}focus(){var e,t,o;(o=(t=(e=this.svelteRootComponent)==null?void 0:e.keyboardControls)==null?void 0:t.focus)==null||o.call(t)}restoreFocus(){var e;(e=this.focusManager)==null||e.restoreFocus()}handleExternalKeyboardEvent(e){var t,o;return!!((o=(t=this.svelteRootComponent)==null?void 0:t.keyboardControls)!=null&&o.handleExternalKeyboardEvent(e))}setAutoplayNext(e){var t;(t=this.store)==null||t.actions.internal.setAutoplayNextEnabled(e)}getTotalViewTime(){var e,t;return(t=(e=this.statistics)==null?void 0:e.thinOneStat)==null?void 0:t.getTotalViewTime()}unmountComponent(e){e&&Ha(e)}};var gd=require("@vkontakte/videoplayer-shared/es2015"),Kp=require("@vkontakte/videoplayer-core/es2015"),QT=()=>{window.customElements.define("vk-video-player",zp)};
|
|
60
|
+
M12 29.8c0-1 .8-1.8 1.8-1.8h10.4a1.8 1.8 90 010 3.6H13.8a1.8 1.8 90 01-1.8-1.8m0-7.6c0-1 .8-1.8 1.8-1.8h3.4a1.8 1.8 90 110 3.6H13.8a1.8 1.8 90 01-1.8-1.8m17 7.6c0-1 .8-1.8 1.8-1.8h3.4a1.8 1.8 90 110 3.6h-3.4a1.8 1.8 90 01-1.8-1.8M22 22.2c0-1 .8-1.8 1.8-1.8h10.4a1.8 1.8 90 010 3.6h-10.4a1.8 1.8 90 01-1.8-1.8`)),$(m,p)};V(d,m=>{e.type==="off"?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}}),H()}function Om(i,e){B(e,!0);let t=h(e,"isSubtitlesEnabled",3,!1),r=$e().ui.t,a=f(()=>t()?r("tooltip_subtitles_on"):r("tooltip_subtitles_off"));Kt(i,{testId:"subtitles-btn",get ariaLabel(){return n(a)},get click(){return e.click},get ariaKeyShortCut(){return $s.KeyC},role:"button",children:(l,d)=>{let s=f(()=>t()?void 0:"outline");ga(l,{get size(){return"24"},get type(){return n(s)}})},$$slots:{default:!0}}),H()}var gx=L('<span class="duration s-20" data-testid="video_duration"> </span>'),hx=L('<div data-testid="time"><span class="current s-20" data-testid="current_time"> </span> <!></div>'),_x={hash:"s-20",code:'.time.s-20{align-items:center;color:var(--controls-time);display:flex;font-variant-numeric:tabular-nums;font-weight:500;padding:12px 6px}.time.mobile.s-20{padding:0 0 0 8px}.current.s-20{position:relative}.duration.s-20{opacity:.7}.duration.s-20:before{content:" / ";white-space:pre}'};function dc(i,e){B(e,!0),Q(i,_x);let t=h(e,"isMobile",3,!1),o=h(e,"isHidden",3,!1),r=h(e,"showDuration",3,!0),a=h(e,"ref",15),l=Dt(),d=ae(!1),s=f(()=>nn(e.duration)),u=f(()=>nn(e.position));var m=hx();let p;var v=T(m),b=T(v,!0);S(v);var y=k(v,2);{var _=x=>{var I=gx(),C=T(I,!0);S(I),N(()=>ge(C,n(s))),$(x,I)};V(y,x=>{r()&&x(_)})}S(m),Ds(m,()=>ql(o()&&l.features.usePerformanceFix,d,l.disableInvisibleComponentsTimeout)),it(m,x=>a(x),()=>a()),N(x=>{p=oe(m,1,"time s-20",null,p,x),ge(b,n(u))},[()=>({mobile:t()})]),$(i,m),H()}var uc=require("@vkontakte/videoplayer-shared/es2015");var bx=Ee('<path d="M21.8632 10.0832C22.2147 9.73171 22.7852 9.73171 23.1367 10.0832C23.4881 10.4347 23.4881 11.0051 23.1367 11.3566L18.6367 15.8566C18.2852 16.2081 17.7147 16.2081 17.3632 15.8566C17.0117 15.5051 17.0117 14.9347 17.3632 14.5832L21.8632 10.0832Z"></path><path d="M17.3632 11.3566C17.0117 11.0051 17.0117 10.4347 17.3632 10.0832C17.7147 9.73171 18.2852 9.73171 18.6367 10.0832L23.1367 14.5832C23.4881 14.9347 23.4881 15.5051 23.1367 15.8566C22.7852 16.2081 22.2147 16.2081 21.8632 15.8566L17.3632 11.3566Z"></path>',1),$x=Ee("<path></path>"),yx=Ee('<path d="M14 3.96997C14.5523 3.96997 15 4.41769 15 4.96997V20.97C15 21.5223 14.5523 21.97 14 21.97C13.3585 21.97 12.7422 21.7208 12.2808 21.2751L6.79013 15.97H4C2.89543 15.97 2 15.0745 2 13.97V11.97C2 10.8654 2.89543 9.96997 4 9.96997H6.765L12.2794 4.66337C12.7417 4.21849 13.3584 3.96997 14 3.96997Z"></path><!>',1);function ha(i,e){B(e,!0);let t=h(e,"volume",3,1),o=h(e,"muted",3,!1),r=(u,m)=>m?"off":u>.5?"max":u>.2?"mid":u>0?"min":"off",a=f(()=>r(t(),o())),l=f(()=>vn(e.size)),d="M16.8748 8.85259C17.2324 8.50731 17.8021 8.51726 18.1474 8.87481C18.5465 9.28803 18.8614 9.77691 19.0757 10.3128C19.2901 10.8486 19.4 11.4218 19.4 12C19.4 12.5782 19.2901 13.1514 19.0757 13.6872C18.8614 14.2231 18.5465 14.712 18.1474 15.1252C17.8021 15.4827 17.2324 15.4927 16.8748 15.1474C16.5173 14.8021 16.5073 14.2324 16.8526 13.8748C17.0876 13.6314 17.2757 13.3408 17.4045 13.0187C17.5333 12.6966 17.6 12.3504 17.6 12C17.6 11.6496 17.5333 11.3034 17.4045 10.9813C17.2757 10.6592 17.0876 10.3686 16.8526 10.1252C16.5073 9.76764 16.5173 9.19788 16.8748 8.85259Z",s="M19.2636 6.2636C19.6151 5.91213 20.1849 5.91213 20.5364 6.2636C21.2516 6.97878 21.9929 7.99659 22.3989 8.97678C22.7959 9.93525 23.0003 10.9625 23.0003 12C23.0003 13.0374 22.7959 14.0647 22.3989 15.0232C21.9929 16.0034 21.2516 17.0212 20.5364 17.7364C20.1849 18.0879 19.6151 18.0879 19.2636 17.7364C18.9121 17.3849 18.9121 16.8151 19.2636 16.4636C19.8484 15.8788 20.4384 15.0527 20.7359 14.3343C21.0425 13.5943 21.2003 12.801 21.2003 12C21.2003 11.1989 21.0425 10.4057 20.7359 9.66561C20.4384 8.94724 19.8484 8.12124 19.2636 7.5364C18.9121 7.18492 18.9121 6.61508 19.2636 6.2636Z";Ze(i,{get style(){return n(l)},get testId(){var u;return`volume-${(u=n(a))!=null?u:""}-icon`},get shadow(){return e.shadow},children:(u,m)=>{var p=yx(),v=k(le(p));{var b=_=>{var x=bx();ni(),$(_,x)},y=_=>{var x=$x();N(()=>De(x,"d",`${d}${n(a)==="max"?s:""}`)),$(_,x)};V(v,_=>{n(a)==="off"?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}var Do=require("@vkontakte/videoplayer-shared/es2015");var ap=require("@vkontakte/videoplayer-shared/es2015");var Sb=require("@vkontakte/videoplayer-shared/es2015");var xx=L('<div class="overlay"><!></div>');function Dm(i,e){B(e,!0);let[t,o]=He(),r=()=>w(l,"$overlayContainer$",t),l=$e().ui.overlayContainer$,d=K(void 0),s=v=>{!v||!n(d)||!v.contains(n(d))||v.removeChild(n(d))},u=v=>{!v||!n(d)||v.contains(n(d))||v.appendChild(n(d))};Fe(()=>{u(r())}),Ot(()=>(u(r()),()=>s(r())));var m=xx(),p=T(m);ri(p,()=>{var v;return(v=e.children)!=null?v:$t}),S(m),it(m,v=>O(d,v),()=>n(d)),$(i,m),H(),o()}var wx=L('<div class="tooltip s-1o"><div class="content s-1o"> </div> <div class="tooltip-pointer s-1o"></div></div>'),Sx=L("<div><!></div> <!>",1),Cx={hash:"s-1o",code:'.tooltip-wrapper.s-1o{display:flex;flex-direction:column;min-width:0}.full-width.s-1o{width:100%}.tooltip.s-1o{bottom:100%;left:0;opacity:0;position:absolute;transition:opacity .2s,visibility .2s;visibility:hidden}.content.s-1o{background-color:rgba(41,41,41,.8);border-radius:3px;color:var(--white);display:inline-block;padding:6px 10px}.tooltip-pointer.s-1o{border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid rgba(41,41,41,.8);bottom:0;content:" ";font-size:0;line-height:0;position:absolute;width:0}'};function Xa(i,e){B(e,!0),Q(i,Cx);let[t,o]=He(),r=()=>w(X,"$overlayContainer$",t),a=()=>w(U,"$containerSize",t),l=h(e,"isMobile",3,!1),d=h(e,"content",3,""),s=h(e,"active",15,!1),u=h(e,"translateX",3,0),m=h(e,"translateY",3,0),p=h(e,"isFullWidthWrapper",3,!1),v=h(e,"maxTooltipWidth",3,void 0),b=h(e,"placement",3,"top"),y=h(e,"onVisibilityChange",3,Sb.noop),_=5,x=K(void 0),I=K(void 0),C,R=K(0),A=K(0),P=K(0),E=K(0),W=Dt(),F=$e(),U=F.ui.playerSize,X=F.ui.overlayContainer$;Fe(()=>{Et(()=>{y()(s())})});let se=F.getLogger().createComponentLog("Tooltip component"),j=()=>{if(!r()||!n(I)||!n(x))return;O(A,_);let ee=r().getBoundingClientRect(),de=n(x).getBoundingClientRect(),ke=de.width,xe=n(I).clientWidth,Je=a().width,Pe=(ke-xe)/2,we=de.left+u()-ee.left,Ne=we+Pe,Pt=de.top+m()-ee.top,kt=xe/2-_,Lt=Ne<8,pt=Ne+xe>Je-8;Lt&&(Ne=8,kt=we+de.width/2-2.5*_),pt&&(Ne=Je-8-xe,kt=de.left-ee.left+de.width/2-Ne-_),O(P,Ne,!0),O(E,Pt),O(R,kt,!0)},ne=()=>{!r()||!n(I)||!n(x)||O(A,-_)},Z=()=>{if(!r()||!n(I)||!n(x))return;O(R,_);let ee=r().getBoundingClientRect(),de=n(x).getBoundingClientRect(),ke=de.height,xe=n(I).clientHeight,Je=(ke-xe)/2+xe,Pe=de.left+u()-ee.left-n(I).clientWidth,we=2,Ne=Pe-_;Ne<8&&(Ne=8);let kt=de.top+m()-ee.top+Je,Lt=we-Je/2,pt=we-_;O(P,Ne,!0),O(E,kt),O(A,Lt),O(R,pt)},Te=()=>{!r()||!n(I)||!n(x)||O(R,-_)},fe=()=>{switch(b()){case"top":j();break;case"bottom":ne();break;case"left":Z();break;default:Te()}},te=()=>{try{if(!r()||!n(x))return;fe(),s(!0)}catch(ee){se({message:String(ee)})}},_e=()=>{s(!1)},Ce=()=>{n(I)&&(C||(C=window.setTimeout(te,W.controls.hideTimeoutTooltips)),s()&&te())},me=()=>{_e(),window.clearTimeout(C),C=void 0},ce=(ee,de,ke)=>{let xe="";switch(b()){case"top":xe=`transform: translate(${ee}px, ${de}px);`;break;case"bottom":xe=`transform: translate(${ee}px, ${de}px); top: auto; bottom: 100%;`;break;case"left":xe=`transform: translate(${ee}px, ${de}px); left: 0; right: auto;`;break;default:xe=`transform: translate(${ee}px, ${de}px);`}return xe+=` max-width: ${v()===void 0?"auto":`${v()}px`};`,xe+=` opacity: ${ke?1:0}; visibility: ${ke?"visible":"hidden"}`,xe},Ye=(ee,de)=>{let ke="";switch(b()){case"top":ke=`transform: translate(${ee}px, ${de}px) rotate(0); top: auto; bottom: 0;`;break;case"bottom":ke=`transform: translate(${ee}px, ${de}px) rotate(180deg); top: 0; bottom: auto;`;break;case"left":ke=`transform: translate(${ee}px, ${de}px) rotate(-90deg); left: 100%; top: auto; bottom: 0;`;break;default:ke=`transform: translate(${ee}px, ${de}px) rotate(90deg); right: 100%; top: auto; bottom: 0;`}return ke},G=f(()=>ce(n(P),n(E),s())),D=f(()=>Ye(n(R),n(A)));Ot(fe),mn(()=>window.clearTimeout(C));var Xe=Sx(),re=le(Xe);let pe;re.__pointermove=Ce,re.__pointerdown=me,re.__pointerup=function(...ee){var de;(de=e.disableMouseupTooltipShow?void 0:Ce)==null||de.apply(this,ee)};var ue=T(re);ri(ue,()=>{var ee;return(ee=e.children)!=null?ee:$t}),S(re),it(re,ee=>O(x,ee),()=>n(x));var Ae=k(re,2);{var ze=ee=>{Dm(ee,{children:(de,ke)=>{var xe=wx(),Je=T(xe),Pe=T(Je,!0);S(Je);var we=k(Je,2);S(xe),it(xe,Ne=>O(I,Ne),()=>n(I)),N(()=>{Qe(xe,n(G)),ge(Pe,d()),Qe(we,n(D))}),$(de,xe)},$$slots:{default:!0}})};V(Ae,ee=>{d()&&!l()&&ee(ze)})}N(ee=>pe=oe(re,1,"tooltip-wrapper s-1o",null,pe,ee),[()=>({"full-width":p()})]),vt("pointerenter",re,Ce),vt("pointerleave",re,me),$(i,Xe),H(),o()}et(["pointermove","pointerdown","pointerup"]);var Cb=i=>{i.stopPropagation()},Tx=L("<div><!></div>"),Ix={hash:"s-1i",code:".btn-container.s-1i{align-items:center;display:flex;height:100%;position:relative;transition:var(--button-hover-transition);will-change:opacity;-webkit-tap-highlight-color:transparent}.w-max.s-1i{min-width:0;width:100%}"};function Oo(i,e){B(e,!0),Q(i,Ix);let[t,o]=He(),r=()=>w(u,"$isGraphOpened$",t),a=()=>w(s,"$isMobile",t),l=$e(),d=xo(),s=l.ui.isMobile,u=d.graphIsOpened$,m=l.ui.t,p=h(e,"className",3,""),v=h(e,"disabled",3,!1),b=h(e,"hasTooltip",3,!0),y=h(e,"ref",15,void 0),_=h(e,"width",15,void 0),x=h(e,"isFullWidthTooltip",3,!0),I=h(e,"tooltipContent",3,""),C=h(e,"tooltipVisible",3,!1),R=h(e,"tooltipPlacement",3,"top"),A=h(e,"disabledTooltipContent",19,()=>m("tooltip_button_disabled")),P=h(e,"isAriaHidden",3,!1),E=h(e,"onTooltipVisibilityChange",3,ap.noop),W=h(e,"initialTranslateXPx",3,0),F=h(e,"initialTranslateYPx",19,()=>-18),U=h(e,"mouseEnter",3,ap.noop),X=h(e,"mouseLeave",3,ap.noop),se=f(()=>v()?r()?m("tooltip_disabled_when_graph_on"):A():I()),j=K(!1);Fe(()=>{C()||O(j,!1)});var ne=Tx();ne.__pointerdown=[Cb],ne.__click=[Cb];var Z=T(ne);{var Te=te=>{Xa(te,{get content(){return n(se)},get translateX(){return W()},get translateY(){return F()},get isFullWidthWrapper(){return x()},get placement(){return R()},get onVisibilityChange(){return E()},get disableMouseupTooltipShow(){return e.disableMouseupTooltipShow},get active(){return n(j)},set active(_e){O(j,_e,!0)},children:(_e,Ce)=>{var me=Oe(),ce=le(me);ri(ce,()=>{var Ye;return(Ye=e.children)!=null?Ye:$t}),$(_e,me)},$$slots:{default:!0}})},fe=te=>{var _e=Oe(),Ce=le(_e);ri(Ce,()=>{var me;return(me=e.children)!=null?me:$t}),$(te,_e)};V(Z,te=>{b()&&n(se)&&!a()?te(Te):te(fe,!1)})}S(ne),it(ne,te=>y(te),()=>y()),N(()=>{var te;oe(ne,1,`btn-container ${(te=p())!=null?te:""}`,"s-1i"),De(ne,"aria-hidden",P()||null)}),vt("mouseenter",ne,function(...te){var _e;(_e=U())==null||_e.apply(this,te)}),vt("mouseleave",ne,function(...te){var _e;(_e=X())==null||_e.apply(this,te)}),kn(ne,"clientWidth",_),$(i,ne),H(),o()}et(["pointerdown","click"]);var Ex=Ee('<rect width="20" height="20" rx="10"></rect><path d="m12.53 8.69.06.19-.22-.64a.83.83 0 0 0-1.6.47l.13.48-.23-.85a.82.82 0 0 0-1.6.24l-.73-2.93a.85.85 0 0 0-1.65.4L8 11.34l-1.12-1.16a.8.8 0 0 0-1.21 1.03l2.23 2.94s1.23 1.83 4.3 1.23c2.43-.48 3.25-2.67 2.58-4.88l-.55-2.3a.88.88 0 1 0-1.7.49"></path>',1);function cc(i,e){let t=f(()=>(e.completed,"interactive-episode-completed-icon"));Ze(i,{width:"20",height:"20",fill:"none",get testId(){return n(t)},children:(o,r)=>{var a=Ex(),l=le(a),d=k(l);N(()=>{De(l,"fill",da),De(l,"fill-opacity",e.completed?1:.24),De(d,"fill",e.completed?"var(--interactive-episode-complete)":"white")}),$(o,a)},$$slots:{default:!0}})}var Px=L("<div><!></div>"),kx={hash:"s-1b",code:".interactive-episode-icon.s-1b{cursor:default;height:20px;position:absolute;transform:translateX(-50%);width:20px}.interactive-episode-icon.disabled.s-1b{opacity:.4;pointer-events:none}"};function Nm(i,e){B(e,!0),Q(i,kx);let o=$e().ui.t,r=K(0),a=f(()=>o(e.videoEpisode.completed?"tooltip_episode_finished":"tooltip_episode_unfinished"));Oo(i,{get tooltipContent(){return n(a)},initialTranslateXPx:-10,initialTranslateYPx:-10,get disabled(){return e.disabled},get width(){return n(r)},isAriaHidden:!0,isFullWidthTooltip:!1,children:(l,d)=>{var s=Px();let u;var m=T(s);let p=f(()=>!!e.videoEpisode.completed);cc(m,{get completed(){return n(p)}}),S(s),N(v=>{u=oe(s,1,"interactive-episode-icon s-1b",null,u,v),Qe(s,`left: ${e.videoEpisode.from+e.videoEpisode.width/2}%`)},[()=>({disabled:e.disabled})]),kn(s,"clientWidth",v=>O(r,v)),$(l,s)},$$slots:{default:!0}}),H()}var Ax=L('<div><div class="video-episode-inner s-1a"><div class="video-episode-loaded s-1a"></div> <div></div></div></div>'),Lx=L('<div class="video-episodes-wrap s-1a"></div>'),Mx={hash:"s-1a",code:".video-episodes-wrap.s-1a{height:100%;position:absolute;width:100%}.video-episode.s-1a{box-sizing:border-box;height:calc(var(--slider-height)*3);margin-top:calc(var(--slider-height)*-1);padding:var(--slider-height) var(--slider-video-episode-gap);position:absolute;transition:transform .2s}.video-episode.s-1a:first-child{padding-left:0}.video-episode.s-1a:last-child{padding-right:0}.video-episode.s-1a:not(.disabled):where(:hover,:active){transform:scaleY(1.5)}.video-episode-filled.s-1a,.video-episode-inner.s-1a,.video-episode-loaded.s-1a{border-radius:var(--slider-radius);height:var(--slider-height);position:absolute}.video-episode-inner.s-1a{background:var(--slider-bg);overflow:hidden;position:absolute;width:calc(100% - var(--slider-video-episode-gap)*2)}.video-episode.s-1a:first-child .video-episode-inner:where(.s-1a),.video-episode.s-1a:last-child .video-episode-inner:where(.s-1a){width:calc(100% - var(--slider-video-episode-gap))}.video-episode-loaded.s-1a{background:var(--slider-loaded-bg);transition:transform .2s}.video-episode-filled.s-1a,.video-episode-loaded.s-1a{border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.video-episode-filled.s-1a{background-color:var(--slider-filled-bg)}"};function Bm(i,e){Q(i,Mx);let t=h(e,"videoEpisodes",19,()=>[]);var o=Lx();xi(o,21,t,r=>r.from,(r,a)=>{var l=Ax();let d;var s=T(l),u=T(s),m=k(u,2);let p;S(s),S(l),N((v,b)=>{d=oe(l,1,"video-episode s-1a",null,d,v),Qe(l,`left: ${n(a).from}%; width: ${n(a).width}%`),Qe(u,`transform: translateX(${n(a).loadedWidth/n(a).width*100}%)`),p=oe(m,1,"video-episode-filled s-1a",null,p,b),Qe(m,`transform: translateX(${n(a).filledWidth/n(a).width*100}%)`)},[()=>({disabled:e.disabled,mobile:e.isMobile}),()=>({mobile:e.isMobile})]),$(r,l)}),S(o),$(i,o)}function Vx(i,e,t,o,r,a,l){if(i.preventDefault(),e()&&O(t,e().getBoundingClientRect(),!0),o()||n(r)||!e())return;O(r,!0);let d=a(i.clientX,i.clientY);l()(d,i),e().setPointerCapture(i.pointerId)}function Rx(i,e,t,o,r,a,l,d){if(i.preventDefault(),e())return;let s=t(i.clientX,i.clientY),u=o(i.clientX);r()(s,u,n(a).width,i),n(l)&&d()(s)}function Ox(i,e,t,o,r){if(i.preventDefault(),e()||!n(t))return;O(t,!1);let a=o(i.clientX,i.clientY);r()(a,i)}function Dx(i,e,t,o){i.stopPropagation(),i.preventDefault(),e()&&t()(o(i.clientX,i.clientY))}function Nx(i,e,t,o,r,a){let l=e(i.clientX,i.clientY);t()&&o()(l),O(r,!1),a()(l)}var Bx=L("<div></div>"),Hx=L('<div class="bars s-12"><div class="loaded s-12"></div> <div></div></div>'),Fx=L('<!> <div role="slider" tabindex="0"><!> <div><div></div></div></div>',1),Ux={hash:"s-12",code:'.interactive-icons.s-12{position:absolute;top:-28px;width:calc(100% - 20px)}.interactive-icons.mobile.s-12{top:-10px}.slider.s-12{border-radius:var(--slider-radius);cursor:pointer;height:var(--slider-height);position:relative;touch-action:none;transition:opacity .2s;width:100%;will-change:opacity,transform;-webkit-tap-highlight-color:transparent}.no-handle.s-12{cursor:default}.slider.s-12:before{content:"";height:calc(var(--controls-height)/2);left:0;position:absolute;right:0;top:calc((var(--controls-height)/2 - var(--slider-height))*-1/2)}.bars.s-12{background:var(--slider-bg);overflow:hidden}.bars.s-12,.loaded.s-12{border-radius:var(--slider-radius);height:100%;position:absolute;width:100%}.loaded.s-12{background:var(--slider-loaded-bg);left:-100%;transition:transform .2s;will-change:transform}.filled.s-12{background-color:var(--slider-filled-bg);border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.slider.square.s-12,.slider.square.s-12 .filled:where(.s-12),.slider.square.s-12 .loaded:where(.s-12),.slider.square.s-12>.bars:where(.s-12){border-radius:unset}.filled.active-live.s-12{background-color:var(--timeline-slider-filled-active-live-bg)}.filled.ads.s-12{background-color:var(--slider-filled-ads)}.handleWrap.s-12{left:-100%;position:absolute;width:100%}.handle.s-12{background-color:var(--slider-handle-bg);border-radius:50%;height:var(--slider-handle-size);opacity:0;position:absolute;right:calc(var(--slider-handle-size)*-1/2);top:calc((var(--slider-height) - var(--slider-handle-size))/2);transform:scale(0);transition:opacity .2s,transform .2s;visibility:hidden;width:var(--slider-handle-size);will-change:opacity,transform}.handle.active-live.s-12{background-color:var(--timeline-slider-handle-active-live-bg)}.handle-always-visible.s-12 .handle:where(.s-12),.slider-dragging.s-12 .handle:where(.s-12),.slider.s-12:hover .handle:where(.s-12){opacity:1;transform:scale(1);visibility:visible}.slider-dragging.s-12 .handle:where(.s-12){transform:scale(1.3)}.slider-vertical.s-12{left:-8px;position:absolute;top:-18px;transform:rotate(-90deg);transform-origin:0 0}.slider.disabled.s-12{cursor:default;opacity:.4}'};function Za(i,e){B(e,!0),Q(i,Ux);let t=h(e,"ref",15,void 0),o=h(e,"className",3,""),r=h(e,"testId",3,void 0),a=h(e,"isHidden",3,!1),l=h(e,"isVertical",3,!1),d=h(e,"isActiveLive",3,!1),s=h(e,"isMobile",3,!1),u=h(e,"squareBorders",3,!1),m=h(e,"videoEpisodes",19,()=>[]),p=h(e,"withWheelHandler",3,!1),v=h(e,"isInteractive",3,!1),b=h(e,"disabled",3,!1),y=h(e,"hideHandel",3,!1),_=h(e,"onPointerDown",3,Do.noop),x=h(e,"onHandleMove",3,Do.noop),I=h(e,"onPointerUp",3,Do.noop),C=h(e,"onPointerEnter",3,Do.noop),R=h(e,"onPointerMove",3,Do.noop),A=h(e,"onPointerLeave",3,Do.noop),P=h(e,"onMouseEnter",3,Do.noop),E=h(e,"onMouseLeave",3,Do.noop),W=h(e,"onWheelUp",3,Do.noop),F=h(e,"onWheelDown",3,Do.noop),U=h(e,"onWheelLeft",3,Do.noop),X=h(e,"onWheelRight",3,Do.noop),se=h(e,"onDisabledClick",3,Do.noop),j=h(e,"loadedProgress",3,0),ne=h(e,"filledProgress",3,0),Z=h(e,"handleProgress",3,0),Te=h(e,"ariaLabel",3,""),fe=h(e,"ariaValueMin",3,void 0),te=h(e,"ariaValueMax",3,void 0),_e=h(e,"ariaValueNow",3,void 0),Ce=h(e,"ariaValueText",3,""),me=h(e,"onContextMenu",3,Do.noop),ce=h(e,"handleAlwaysVisible",3,!1),Ye=Dt(),G=K(void 0),D=K(!1),Xe=f(()=>{var ye;return(ye=te())!=null?ye:0}),re=f(()=>{var ye;return(0,Do.isNonNullable)(m())&&((ye=m()[m().length-1])==null?void 0:ye.time)<n(Xe)}),pe=f(()=>(0,Do.isNonNullable)(m())&&m().length&&n(re)&&n(Xe)?Je(j()*100,ne()*100):[]);function ue(ye){if(ye.preventDefault(),t()&&O(G,t().getBoundingClientRect(),!0),b())return;let Ue=ke(ye.clientX,ye.clientY),Se=xe(ye.clientX);C()(Ue,Se,n(G).width)}function Ae(ye){ye.preventDefault(),!b()&&A()()}function ze(){P()()}function ee(){E()()}function de(ye){b()||p()&&(ye.preventDefault(),ye.deltaY<0?W()():ye.deltaY>0?F()():ye.deltaX>0?X()():U()())}function ke(ye,Ue){return l()?Math.max(0,Math.min(1,(n(G).height-(Ue-n(G).top))/n(G).height)):Math.min(Math.max(ye-n(G).x,0),n(G).width)/n(G).width}function xe(ye){return Math.min(Math.max(ye-n(G).x,0),n(G).width)}function Je(ye,Ue){let Se=Ye.features.episodesClustering&&!v()?Ye.episodeMinWidthPc:0,Tt=[],ve=m()[0].time/n(Xe)*100,Be=0,qe=0;for(let Mt=1;Mt<m().length;Mt++)Be=m()[Mt].time/n(Xe)*100,Be-ve>Se&&(Tt.push({from:ve,width:Math.max(0,Be-ve),loadedWidth:Math.max(0,Math.min(Be,ye)-ve),filledWidth:Math.max(0,Math.min(Be,Ue)-ve),interactive:m()[Mt-1].interactive,completed:m()[Mt-1].completed}),ve=m()[Mt].time/n(Xe)*100,qe++);let ct={from:ve,width:Math.max(0,100-ve),loadedWidth:Math.max(0,Math.min(ye,100)-ve),filledWidth:Math.max(0,Math.min(Ue,100)-ve),interactive:m()[qe].interactive,completed:m()[qe].completed};100-ve<Se?(qe-=1,Tt[qe].width+=100-ve,Tt[qe].loadedWidth+=Math.max(0,Math.min(ye,100)-ve),Tt[qe].filledWidth+=Math.max(0,Math.min(Ue,100)-ve)):Tt[qe]=ct;let Xt=m()[0].time;if(Xt!==0){let Mt=Xt/n(Xe)*100;Tt.unshift({from:0,width:Mt,loadedWidth:Math.min(Mt,ye),filledWidth:Math.min(Mt,Ue)})}return Tt}function Pe(ye){return Math.max(0,Math.min(100,ye*100))}let we=f(()=>Pe(j())),Ne=f(()=>Pe(ne()));var Pt=Fx(),kt=le(Pt);{var Lt=ye=>{var Ue=Bx();let Se;xi(Ue,21,()=>n(pe),Tt=>Tt.from,(Tt,ve)=>{var Be=Oe(),qe=le(Be);{var ct=Xt=>{Nm(Xt,{get videoEpisode(){return n(ve)},get disabled(){return b()}})};V(qe,Xt=>{n(ve).interactive&&Xt(ct)})}$(Tt,Be)}),S(Ue),N(Tt=>Se=oe(Ue,1,"interactive-icons s-12",null,Se,Tt),[()=>({mobile:s(),hidden:s()&&!n(D)})]),$(ye,Ue)};V(kt,ye=>{v()&&ye(Lt)})}var pt=k(kt,2);let It;pt.__pointerdown=[Vx,t,G,b,D,ke,_],pt.__pointermove=[Rx,b,ke,xe,R,G,D,x],pt.__pointerup=[Ox,b,D,ke,I],pt.__click=[Dx,b,se,ke],pt.__contextmenu=[Nx,ke,b,se,D,me];var ei=T(pt);{var Ft=ye=>{Bm(ye,{get videoEpisodes(){return n(pe)},get disabled(){return b()},get isMobile(){return s()}})},Bt=ye=>{var Ue=Hx(),Se=T(Ue),Tt=k(Se,2);let ve;S(Ue),N(Be=>{De(Se,"data-value",n(we)),Qe(Se,`transform: translateX(${n(we)}%);`),ve=oe(Tt,1,"filled s-12",null,ve,Be),De(Tt,"data-value",n(Ne)),Qe(Tt,`transform: translateX(${n(Ne)}%);`)},[()=>({"active-live":d()})]),$(ye,Ue)};V(ei,ye=>{n(pe).length?ye(Ft):ye(Bt,!1)})}var qt=k(ei,2);let q;var Le=T(qt);let Me;S(qt),S(pt),it(pt,ye=>t(ye),()=>t()),N((ye,Ue,Se,Tt)=>{var ve,Be;It=oe(pt,1,`slider ${(ve=o())!=null?ve:""}`,"s-12",It,ye),De(pt,"aria-label",Te()),De(pt,"aria-valuemin",fe()),De(pt,"aria-valuemax",te()),De(pt,"aria-valuenow",_e()),De(pt,"aria-valuetext",Ce()),De(pt,"data-testid",(Be=r())!=null?Be:null),q=oe(qt,1,"handleWrap s-12",null,q,Ue),Qe(qt,Se),Me=oe(Le,1,"handle s-12",null,Me,Tt)},[()=>({disabled:b(),"slider-dragging":n(D),hidden:a(),"handle-always-visible":ce(),"slider-vertical":l(),"no-handle":y(),square:u()}),()=>({hidden:y()}),()=>`transform: translateX(${Pe(Z())}%);`,()=>({"active-live":d()})]),vt("pointerenter",pt,ue),vt("pointerleave",pt,Ae),vt("mouseenter",pt,ze),vt("mouseleave",pt,ee),vt("wheel",pt,de),$(i,Pt),H()}et(["pointerdown","pointermove","pointerup","click","contextmenu"]);var ao=(i,e)=>Gd[i]>=Gd[e];var Fs=(i,e)=>Gd[i]<=Gd[e],Tb=i=>i>699?"xl":i>599?"l":i>509?"m":i>320?"s":"xs";var Wx=L("<div><!></div>"),Kx=L("<div><!> <!></div>"),qx={hash:"s-27",code:".volumeBar-container.s-27{align-items:center;display:flex}.vertical.s-27 .btn,.vertical.s-27 .tooltip-wrapper,.volumeBar-container.vertical.s-27{width:40px}.volumeBar.s-27{align-items:center;display:flex;margin:0 8px;position:relative;width:70px;--slider-height:var(--slider-volume-height);--slider-radius:var(--slider-volume-radius);--slider-handle-size:var(--slider-volume-handle-size);--slider-bg:var(--volume-slider-bg);--slider-filled-bg:var(--volume-slider-filled-bg);--slider-handle-bg:var(--volume-slider-handle-bg)}.volumeBar-slider-vertical{width:50px!important}.volumeBar-vertical.s-27{padding:0 8px 0 0;width:0}"};function Hm(i,e){var xe,Je;B(e,!0),Q(i,qx);let[t,o]=He(),r=()=>w(R,"$isAudioAvailable$",t),a=()=>w(v,"$muted$",t),l=()=>w(p,"$volume$",t),d=()=>w(x,"$currentGridType$",t),s=()=>w(ue,"$controlsVisible",t),u=$e(),m=Dt(),p=u.state.volume$,v=u.state.muted$,{setVolume:b,startVolumeChanging:y,stopVolumeChanging:_}=u.actions.internal,x=u.ui.currentGridType$,I=(xe=u.callbacks)==null?void 0:xe.onAudioDoesNotExistHint,C=(Je=u.callbacks)==null?void 0:Je.onAudioDisabledHint,R=u.state.isAudioAvailable$,A=u.state.isAudioDisabled,P=u.ui.t,E=K(!1),W,F=f(()=>e.isAds||r()),U=f(()=>!n(F)||a()||l()===0),X=f(()=>Fs(d(),"l")),se=f(()=>n(X)?"":n(U)?!r()||A?P("tooltip_sound_unavailable"):P("tooltip_volume"):P("tooltip_volume_muted")),j=f(()=>n(U)?P("tooltip_volume"):P("tooltip_volume_muted")),ne=f(()=>n(U)?0:l()),Z=!1,Te=f(()=>e.isAds?!1:A?!C:r()?!1:!I);function fe(Pe){y(),b(Pe)}function te(){op(u,l(),m.controls.volumeStepWheel)}function _e(){np(u,l(),m.controls.volumeStepWheel)}function Ce(Pe){b(Pe)}function me(Pe){b(Pe),_()}function ce(){Z=!0}function Ye(){Z=!1,Xe()}function G(){clearTimeout(W),O(E,!0)}function D(){Xe()}function Xe(){W=window.setTimeout(()=>{Z||O(E,!1)},m.controls.volumeBarTimeout)}function re(Pe){Pe.preventDefault(),Pe.deltaY<0?te():Pe.deltaY>0&&_e()}let pe=K(!1),ue=u.ui.controlsVisible;Fe(()=>{s()||O(pe,!1)});var Ae=Kx();let ze;var ee=T(Ae);Xa(ee,{get content(){return n(se)},translateY:-18,get active(){return n(pe)},set active(Pe){O(pe,Pe,!0)},children:(Pe,we)=>{let Ne=f(()=>n(X)?"btn-volume-vertical":"btn-volume-horizontal");Kt(Pe,{className:"btn-full-opacity",get disabled(){return n(Te)},get testId(){return n(Ne)},get ariaLabel(){return n(j)},get click(){return e.click},get ariaKeyShortCut(){return $s.KeyM},role:"button",children:(Pt,kt)=>{ha(Pt,{get size(){return"24"},get volume(){return l()},get muted(){return n(U)}})},$$slots:{default:!0}})},$$slots:{default:!0}});var de=k(ee,2);{var ke=Pe=>{var we=Wx();let Ne;var Pt=T(we);let kt=f(()=>n(X)?"volumeBar-slider-vertical":""),Lt=f(()=>n(X)&&!n(E)),pt=f(()=>n(X)?ce:uc.noop),It=f(()=>n(X)?Ye:uc.noop),ei=f(()=>Math.round(n(ne)*100)),Ft=f(()=>`${Math.round(n(ne)*100)}%`),Bt=f(()=>n(X)?"volume-slider-vertical":"volume-slider");Za(Pt,{get className(){return n(kt)},get isHidden(){return n(Lt)},get isVertical(){return n(X)},withWheelHandler:!0,onWheelUp:te,onWheelDown:_e,onPointerDown:fe,onHandleMove:Ce,onPointerUp:me,get onPointerEnter(){return n(pt)},get onPointerLeave(){return n(It)},ariaLabel:"Ползунок громкости",ariaValueMin:0,ariaValueMax:100,get ariaValueNow(){return n(ei)},get ariaValueText(){return n(Ft)},get filledProgress(){return n(ne)},get handleProgress(){return n(ne)},get testId(){return n(Bt)}}),S(we),N(qt=>Ne=oe(we,1,"volumeBar s-27",null,Ne,qt),[()=>({"volumeBar-vertical":n(X)})]),$(Pe,we)};V(de,Pe=>{n(F)&&Pe(ke)})}S(Ae),N(Pe=>ze=oe(Ae,1,"volumeBar-container s-27",null,ze,Pe),[()=>({vertical:n(X)})]),vt("mouseenter",Ae,function(...Pe){var we;(we=n(X)?G:uc.noop)==null||we.apply(this,Pe)}),vt("mouseleave",Ae,function(...Pe){var we;(we=n(X)?D:uc.noop)==null||we.apply(this,Pe)}),vt("wheel",Ae,re),$(i,Ae),H(),o()}var Ib=require("@vkontakte/videoplayer-shared/es2015");var Qx=Ee('<path d="M4.58 13.98a1 1 0 0 1 .99-1h4.45a1 1 0 0 1 1 1v4.45a.99.99 0 0 1-1.99 0v-2.05L5.71 19.7a1 1 0 1 1-1.41-1.4l3.32-3.32H5.57a1 1 0 0 1-.99-1m10.39-6.36 3.32-3.32a1 1 0 1 1 1.41 1.4l-3.32 3.32h2.05a.99.99 0 0 1 0 1.98H14a1 1 0 0 1-1-1V5.57a.99.99 0 1 1 1.98 0z"></path>'),Gx=Ee('<path d="M10.5 19a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-4.5a1 1 0 0 1 2 0v2.07l3.36-3.36a1 1 0 0 1 1.42 0l.01.01a1 1 0 0 1 0 1.42L7.43 18H9.5a1 1 0 0 1 1 1M18 7.43l-3.36 3.36a1 1 0 0 1-1.42 0l-.01-.01a1 1 0 0 1 0-1.42L16.57 6H14.5a1 1 0 0 1 0-2H19a1 1 0 0 1 1 1v4.5a1 1 0 0 1-2 0z"></path>');function Fm(i,e){let t=h(e,"isFullscreen",8,!1),o=gr(()=>t()?"close-fullscreen-icon":"open-fullscreen-icon");Ze(i,{get testId(){return n(o)},children:(r,a)=>{var l=Oe(),d=le(l);{var s=m=>{var p=Qx();$(m,p)},u=m=>{var p=Gx();$(m,p)};V(d,m=>{t()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}function pc(i,e){B(e,!0);let t=h(e,"isFullscreen",3,!1),o=h(e,"click",3,Ib.noop),r=$e(),a=r.ui.isFullscreenOpenedByKeyboard,l=r.ui.t,d=f(()=>t()?l("tooltip_fullscreen_on"):l("tooltip_fullscreen_off"));Kt(i,{testId:"fullscreen-btn",get ariaLabel(){return n(d)},click:u=>{let m=fa(u);a.set(m),o()()},get ariaKeyShortCut(){return $s.KeyF},role:"button",children:(u,m)=>{Fm(u,{get isFullscreen(){return t()}})},$$slots:{default:!0}}),H()}var Yx=Ee('<svg><!><path fill="var(--btn-color, #fff)" fill-rule="evenodd" d="M4.26 4.26C3 5.54 3 7.57 3 11.65v.72c0 4.07 0 6.11 1.26 7.38C5.54 21 7.57 21 11.65 21h.72c4.07 0 6.11 0 7.38-1.26C21 18.47 21 16.43 21 12.36v-.72c0-4.07 0-6.11-1.26-7.38C18.47 3 16.43 3 12.36 3h-.72C7.57 3 5.53 3 4.26 4.26M6 8.5c.1 4.68 2.56 7.5 6.61 7.5h.24v-2.68c1.47.15 2.57 1.25 3.02 2.68H18a6 6 0 0 0-3-3.76 5.7 5.7 0 0 0 2.55-3.74h-1.94c-.4 1.49-1.61 2.84-2.77 2.97V8.5h-1.96v5.2c-1.2-.3-2.76-1.76-2.83-5.2z" clip-rule="evenodd"></path></svg>');function Um(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=Yx();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none","aria-hidden":"true","data-testid":"vk-logo-icon",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(),S(o),$(i,o)}var jx=Ee('<svg><!><svg data-logo="vk_video"><path d="M7 8.6c0-1.96 0-2.94.38-3.69a3.5 3.5 0 0 1 1.53-1.53C9.66 3 10.64 3 12.6 3h1.36c2.46 0 3.7 0 4.64.48a4.4 4.4 0 0 1 1.92 1.92c.48.94.48 2.18.48 4.64v3.92c0 2.46 0 3.7-.48 4.64a4.4 4.4 0 0 1-1.92 1.92c-.94.48-2.18.48-4.64.48H12.6c-1.96 0-2.94 0-3.69-.38a3.5 3.5 0 0 1-1.53-1.53C7 18.34 7 17.36 7 15.4zm9.26 1.74c.9.54 1.36.81 1.51 1.16.13.3.13.65 0 .96-.15.34-.6.61-1.5 1.15l-2.4 1.43c-.93.56-1.4.84-1.8.8-.33-.03-.64-.2-.84-.48-.23-.31-.23-.86-.23-1.96v-2.85c0-1.1 0-1.64.23-1.96q.31-.42.85-.48c.38-.04.86.25 1.8.8zM5 9.04c0-2.46 0-3.7.48-4.64q.37-.71.95-1.25-.58.1-1.03.33A4.4 4.4 0 0 0 3.48 5.4C3 6.34 3 7.58 3 10.04v3.92c0 2.46 0 3.7.48 4.64a4.4 4.4 0 0 0 1.92 1.92q.45.23 1.03.33a4 4 0 0 1-.95-1.25C5 18.66 5 17.42 5 14.96z"></path></svg><svg x="4" y="3" data-logo="play_market"><path d="M0 1.26v15.47q0 .66.34 1L9.52 9 .33.28C.08.53 0 .92 0 1.26"></path><path d="M.33.28.38.23c.34-.3.89-.32 1.49 0l10.75 5.81-2.6 2.48zm10.29 8.75 2.88 2.45-.53.29-.34.18-2.58-2.44-9.71 8.22c.33.34.9.37 1.53.04l11.1-6 .53-.29 2.73-1.47c1.03-.56 1.03-1.47 0-2.02l-2.77-1.5-.84-.45.84.45.1.05z"></path></svg><svg x="3" data-logo="app_store"><path d="M17.62 16.37q-.48 1.09-1.15 2.03-.9 1.27-1.48 1.75-.88.8-1.9.83-.72 0-1.76-.42a5 5 0 0 0-1.89-.4q-.9 0-1.94.4a5 5 0 0 1-1.68.44q-.98.04-1.95-.85-.62-.53-1.55-1.82a13 13 0 0 1-1.63-3.2 12 12 0 0 1-.69-3.8q0-2.1.93-3.64A5.4 5.4 0 0 1 5.5 5.03q.77 0 2.03.46t1.62.47q.26 0 1.79-.55a6 6 0 0 1 2.43-.42 5.2 5.2 0 0 1 4.05 2.09q-2.4 1.44-2.4 4.02a4.4 4.4 0 0 0 1.49 3.34q.66.61 1.48.95-.18.5-.38.98M13.5.42q0 1.58-1.17 2.94c-.94 1.08-2.07 1.7-3.3 1.6L9 4.56c0-1 .45-2.08 1.24-2.96q.6-.67 1.5-1.12.93-.44 1.74-.48z"></path></svg><path d="M32.55 17.04h2.5L38.7 7h-1.8l-2.94 8.28h-.28L30.84 7H29zm15.52 0-4.61-5.2L47.72 7H45.6l-3.56 4.09h-.42V7h-1.7v10.04h1.7v-4.3h.43l3.76 4.3z"></path><path d="M57.89 11.89a2.2 2.2 0 0 0 1.44-2.16C59.33 8.14 58 7 56.06 7h-3.92v10.04h4.2c1.96 0 3.29-1.14 3.29-2.8 0-1.17-.66-2.04-1.74-2.35m-4.04-3.4h2.21c.92 0 1.54.56 1.54 1.39 0 .8-.62 1.36-1.54 1.36h-2.2zm2.5 7.06h-2.5v-2.81h2.5c.9 0 1.52.57 1.52 1.4 0 .84-.62 1.4-1.52 1.4m4.84 1.5h2.32l2.77-5.5h.22v5.5h1.57v-7.4h-2.32l-2.77 5.5h-.22v-5.5h-1.57zm7.96 2.21h1.64v-2.2h5.33v2.2h1.64v-3.7h-1.29V9.64h-5.43l-.37 3.78c-.13 1.34-.53 2.13-1.34 2.13h-.18zm2.49-3.7c.4-.39.57-1.04.68-2.15l.23-2.27h2.28v4.42zm14.38-2.3a3.7 3.7 0 0 0-3.84-3.76 3.7 3.7 0 0 0-3.85 3.85 3.7 3.7 0 0 0 3.85 3.84c1.54 0 2.99-.72 3.55-2.13l-1.54-.26c-.36.53-1.04.9-1.91.9-1.26 0-2.09-.77-2.24-1.91H86zm-3.84-2.33c1.02 0 1.8.65 2.06 1.58h-4.1a2.1 2.1 0 0 1 2.04-1.58m8.66 6.26c2.32 0 3.96-1.6 3.96-3.84 0-2.25-1.64-3.85-3.96-3.85s-3.97 1.6-3.97 3.85 1.64 3.84 3.97 3.84m0-1.5c-1.34 0-2.25-.95-2.25-2.34 0-1.4.9-2.35 2.25-2.35 1.34 0 2.25.95 2.25 2.35s-.91 2.35-2.25 2.35" class="_ru"></path><path d="M35.02 17.36h-2.48L29 7.42h1.83l2.83 8.2h.28l2.93-8.2h1.8zm8.41-5.15 4.6 5.15h-2.24l-3.75-4.26h-.43v4.26h-1.7V7.42h1.7v4.05h.41l3.55-4.05h2.1zm13.37 5.15h-2.48L50.8 7.42h1.83l2.82 8.2h.29l2.92-8.2h1.8zm6.46 0h-1.64v-7.33h1.64zm-.81-8.37q-.45 0-.74-.27a1 1 0 0 1-.28-.72q0-.44.28-.72.3-.28.74-.28t.72.28q.3.29.29.72 0 .44-.29.72t-.72.27m5.93 8.51q-1.03 0-1.86-.48a3.5 3.5 0 0 1-1.29-1.35 4 4 0 0 1-.45-1.98q0-1.1.45-1.95.46-.88 1.3-1.36.81-.5 1.85-.5.9 0 1.6.38.68.35 1.13.88V7.42h1.63v9.94h-1.22l-.34-1.18q-.46.54-1.17.94a3.4 3.4 0 0 1-1.63.38m.4-1.45q1.04 0 1.68-.65.65-.66.65-1.7t-.65-1.7a2.2 2.2 0 0 0-1.68-.66 2.2 2.2 0 0 0-1.66.66q-.64.66-.64 1.7t.64 1.7q.64.65 1.66.65m13.15-2.44-.03.52h-5.94q.12.86.71 1.38.6.51 1.52.51.63 0 1.13-.24.51-.24.78-.65l1.53.26q-.39 1.01-1.38 1.56-.96.55-2.16.55-1.1 0-1.98-.48a3.6 3.6 0 0 1-1.85-3.33q0-1.1.48-1.95.5-.88 1.37-1.36a4 4 0 0 1 1.98-.5q1.11 0 1.98.5.88.48 1.36 1.34.5.86.5 1.89m-3.84-2.31q-.73 0-1.29.42-.53.42-.74 1.14h4.1a2.2 2.2 0 0 0-2.07-1.56m8.66 6.2q-1.14 0-2.04-.48a3.7 3.7 0 0 1-1.4-1.35 4 4 0 0 1-.5-1.98q0-1.1.5-1.95.5-.88 1.4-1.36.9-.5 2.04-.5t2.03.5q.91.48 1.4 1.36.52.86.52 1.95 0 1.11-.51 1.98-.5.86-1.4 1.35-.9.48-2.04.48m0-1.48q.99 0 1.62-.63.63-.66.63-1.7t-.63-1.67a2.2 2.2 0 0 0-1.62-.65q-.99 0-1.62.65-.62.63-.62 1.67 0 1.05.62 1.7.63.63 1.62.63" class="_en"></path></svg>');function zm(i,e){let t=An(e,["$$slots","$$events","$$legacy","children"]);var o=jx();so(o,()=>Ve({xmlns:"http://www.w3.org/2000/svg",width:"95",height:"24",fill:"var(--btn-color, #fff)","fill-rule":"evenodd","aria-hidden":"true","clip-rule":"evenodd",viewBox:"0 0 95 24",role:"img"},t));var r=T(o);ri(r,()=>{var a;return(a=e.children)!=null?a:$t}),ni(6),S(o),$(i,o)}var Xx={hash:"s-29",code:"svg [data-logo],svg[data-testid=vk-video-logo-icon--en] ._ru,svg[data-testid=vk-video-logo-icon--short] ._en,svg[data-testid=vk-video-logo-icon--short] ._ru,svg[data-testid=vk-video-logo-icon] ._en{opacity:0;visibility:hidden}svg[data-logo=app_store] [data-logo=app_store],svg[data-logo=play_market] [data-logo=play_market],svg[data-logo=vk_video] [data-logo=vk_video]{opacity:1;visibility:visible}"};function Wm(i,e){B(e,!0),Q(i,Xx);let t=h(e,"short",3,!1),o=h(e,"isCyrillic",3,!0),r=h(e,"logo",19,()=>"vk_video"),a="vk-video-logo-icon--short",l=24,d=f(()=>!o()&&!t()?91:t()?l:95),s=f(()=>!o()&&!t()?"vk-video-logo-icon--en":t()?a:"vk-video-logo-icon"),u=f(()=>`0 0 ${n(d)} 24`);zm(i,{get width(){return n(d)},height:"24",get viewBox(){return n(u)},get"data-testid"(){return n(s)},get"data-logo"(){return r()}}),H()}function fc(i,e){B(e,!0);let[t,o]=He(),r=()=>w(b,"$isMobile",t),a=()=>w(v,"$currentGridType$",t),l=()=>w(_,"$isCyrillicRelatedInterface$",t),d=h(e,"ref",15,void 0),s=h(e,"logoClickable",3,!1),u=h(e,"targetUrl",3,""),m=Dt(),p=$e(),v=p.ui.currentGridType$,b=p.ui.isMobile,y=p.ui.t,_=p.isCyrillicRelatedInterface$,x=f(()=>m.logoType!=="vk"),I=f(()=>n(x)?y("tooltip_vk_video_logo"):y("tooltip_vk_logo")),C=f(()=>(r()&&Fs(a(),"m")||Fs(a(),"l"))&&n(x)),R=()=>{var E,W;e.click(),(E=p.callbacks)!=null&&E.onLogoClicked?(W=p.callbacks)==null||W.onLogoClicked():u()&&window.open(u(),"_blank")},A=f(()=>!s()),P=f(()=>n(x)?"btn-vk-video-logo":"btn-vk-logo");Kt(i,{className:"btn-full-opacity",get disabled(){return n(A)},click:R,get testId(){return n(P)},get ariaLabel(){return n(I)},get ref(){return d()},set ref(E){d(E)},children:(E,W)=>{var F=Oe(),U=le(F);{var X=j=>{Wm(j,{get logo(){return m.logoType},get short(){return n(C)},get isCyrillic(){return l()}})},se=j=>{Um(j,{})};V(U,j=>{n(x)?j(X):j(se,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}var Pb=require("@vkontakte/videoplayer-core/es2015");var Km=require("@vkontakte/videoplayer-core/es2015");var Zx=Ee('<path d="M3.6 13.3a5.1 5.1 0 0 1 5.05 5.83.9.9 0 0 1-1.78-.26 3.3 3.3 0 0 0-3.74-3.74.9.9 0 0 1-.26-1.78c.24-.03.49-.05.73-.05Z" class="s-15"></path><path d="M3.6 9.7a8.7 8.7 0 0 1 8.68 9.37.9.9 0 0 1-1.8-.14c.02-.17.02-.35.02-.53a6.9 6.9 0 0 0-7.43-6.88.9.9 0 0 1-.14-1.8l.67-.02ZM3.6 16.9a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3Z" class="s-15"></path><path d="M16.24 4.1c.8 0 1.47 0 2 .04a4 4 0 0 1 1.53.38 3.9 3.9 0 0 1 1.7 1.71 4 4 0 0 1 .39 1.53c.04.53.04 1.2.04 2v4.48c0 .8 0 1.47-.04 2a4 4 0 0 1-.38 1.53 3.9 3.9 0 0 1-1.7 1.7 4 4 0 0 1-1.54.39c-.53.04-1.2.04-2 .04H15a.9.9 0 0 1 0-1.8h1.2c.85 0 1.44 0 1.9-.04.44-.03.68-.1.85-.19.4-.2.72-.52.92-.92.09-.17.16-.4.2-.85.03-.46.03-1.05.03-1.9V9.8c0-.85 0-1.44-.04-1.9-.03-.44-.1-.68-.19-.85a2.1 2.1 0 0 0-.92-.92 2.25 2.25 0 0 0-.85-.2 25.9 25.9 0 0 0-1.9-.03H5.83a2.1 2.1 0 0 0-1.81 1.4.9.9 0 1 1-1.7-.6A3.9 3.9 0 0 1 6 4.1h10.24Z" class="s-15"></path>',1),Jx=Ee('<path d="M3.60219 13.2993C6.41858 13.2995 8.70256 15.5835 8.70278 18.3999C8.70277 18.6469 8.68424 18.8909 8.65004 19.1294C8.57937 19.6212 8.12333 19.9625 7.63149 19.8921C7.13968 19.8213 6.79823 19.3654 6.86879 18.8735C6.89087 18.7195 6.90199 18.5611 6.902 18.3999C6.90178 16.5776 5.42447 15.1003 3.60219 15.1001C3.441 15.1001 3.28267 15.1112 3.12856 15.1333C2.63666 15.2039 2.18077 14.8624 2.11 14.3706C2.03966 13.8788 2.38091 13.4227 2.8727 13.3521C3.11125 13.3178 3.35516 13.2993 3.60219 13.2993Z"></path><path d="M3.60219 9.69971C8.40682 9.69977 12.3021 13.5953 12.3024 18.3999C12.3024 18.6248 12.2938 18.8489 12.277 19.0698C12.239 19.5651 11.8065 19.9365 11.3112 19.8989C10.8157 19.8611 10.4445 19.4286 10.4821 18.9331C10.4954 18.7576 10.5026 18.5791 10.5026 18.3999C10.5023 14.5894 7.41271 11.5005 3.60219 11.5005C3.42268 11.5005 3.24474 11.5066 3.06899 11.52C2.57352 11.5578 2.14115 11.1863 2.10317 10.6909C2.06587 10.1957 2.43694 9.76287 2.93227 9.7251C3.15348 9.70823 3.37699 9.69971 3.60219 9.69971Z"></path><path d="M3.60219 16.8999C4.43047 16.8999 5.10198 17.5717 5.10219 18.3999C5.10209 19.2282 4.43054 19.8999 3.60219 19.8999C2.77383 19.8999 2.10229 19.2282 2.10219 18.3999C2.10241 17.5717 2.7739 16.8999 3.60219 16.8999Z"></path><path d="M16.2379 4.1001C17.0459 4.10009 17.7067 4.10017 18.2438 4.14404C18.7997 4.18946 19.3022 4.28599 19.7711 4.5249C20.5049 4.89882 21.1014 5.49623 21.4752 6.22998C21.714 6.69873 21.8107 7.20063 21.8561 7.75635C21.9 8.29338 21.9001 8.95424 21.9 9.76221V14.2378C21.9001 15.0458 21.9 15.7066 21.8561 16.2437C21.8107 16.7996 21.7141 17.3021 21.4752 17.771C21.1014 18.5046 20.5048 19.1012 19.7711 19.4751C19.3022 19.714 18.7997 19.8105 18.2438 19.856C17.7067 19.8998 17.0459 19.8999 16.2379 19.8999H14.9997C14.503 19.8996 14.1005 19.4972 14.1002 19.0005C14.1002 18.5036 14.5028 18.1004 14.9997 18.1001H16.1998C17.0548 18.1001 17.6422 18.0992 18.0973 18.062C18.5419 18.0257 18.7809 17.9596 18.9538 17.8716C19.3489 17.6702 19.6704 17.3487 19.8717 16.9536C19.9598 16.7808 20.0258 16.5417 20.0622 16.0972C20.0993 15.6421 20.1002 15.0546 20.1002 14.1997V9.80029C20.1002 8.94536 20.0993 8.35794 20.0622 7.90283C20.0258 7.45834 19.9598 7.21921 19.8717 7.04639C19.6704 6.6514 19.3487 6.33073 18.9538 6.12939C18.7809 6.04133 18.5419 5.97431 18.0973 5.93799C17.6422 5.9008 17.0548 5.8999 16.1998 5.8999H6.00063L5.83071 5.90674C4.99191 5.97398 4.28981 6.53462 4.01918 7.30029C3.85342 7.76872 3.33928 8.01472 2.87075 7.84912C2.40214 7.68346 2.15628 7.16833 2.32192 6.69971C2.85696 5.18632 4.30125 4.1001 6.00063 4.1001H16.2379Z"></path><path d="M2.95114 7.11345C2.42394 7.1914 1.90399 6.78569 2.00995 6.2634C2.05777 6.0277 2.12517 5.82449 2.22018 5.63803C2.5078 5.07354 2.96674 4.6146 3.53123 4.32698C4.17296 4 5.01304 4 6.6932 4H17.2001C18.8803 4 19.7204 4 20.3621 4.32698C20.9266 4.6146 21.3855 5.07354 21.6731 5.63803C22.0001 6.27976 22.0001 7.11984 22.0001 8.8V15.2C22.0001 16.8802 22.0001 17.7202 21.6731 18.362C21.3855 18.9265 20.9266 19.3854 20.3621 19.673C19.7204 20 18.8803 20 17.2001 20H15.7196C15.2009 20 14.8203 19.5134 14.8938 19C14.9638 18.5101 15.0001 18.0093 15.0001 17.5C15.0001 11.701 10.2991 7 4.5001 7C3.97384 7 3.45662 7.03872 2.95114 7.11345Z"></path>',1),e2={hash:"s-15",code:".animated.s-15{animation-duration:1s;animation-iteration-count:infinite}.wave1.animated.s-15{animation-name:s-15-wave1}.wave2.animated.s-15{animation-name:s-15-wave2}.wave3.animated.s-15{animation-name:s-15-wave3}@keyframes s-15-wave1{0%{opacity:.3}33%{opacity:1}66%{opacity:1}to{opacity:1}}@keyframes s-15-wave2{0%{opacity:.3}33%{opacity:.3}66%{opacity:1}to{opacity:1}}@keyframes s-15-wave3{0%{opacity:.3}33%{opacity:.3}66%{opacity:.3}to{opacity:1}}"};function mc(i,e){B(e,!0),Q(i,e2);let t=h(e,"isMobile",3,!1),o=f(()=>e.iconState===Km.ChromecastState.CONNECTED),r=f(()=>e.iconState===Km.ChromecastState.CONNECTING),a=f(()=>n(o)?"#2688EB":da),l=f(()=>e.size?vn(e.size):void 0);var d=Oe(),s=le(d);{var u=p=>{Ze(p,{get fill(){return n(a)},get style(){return n(l)},testId:"chromecast-mobile-icon",children:(v,b)=>{var y=Zx();ni(2),$(v,y)},$$slots:{default:!0}})},m=p=>{Ze(p,{get style(){return n(l)},testId:"chromecast-icon",children:(v,b)=>{var y=Jx(),_=le(y);let x;var I=k(_);let C;var R=k(I);let A;var P=k(R);let E;var W=k(P);let F;N((U,X,se,j,ne)=>{x=oe(_,0,"wave2 s-15",null,x,U),C=oe(I,0,"wave3 s-15",null,C,X),A=oe(R,0,"wave1 s-15",null,A,se),E=oe(P,0,"s-15",null,E,j),F=oe(W,0,"s-15",null,F,ne)},[()=>({animated:n(r)}),()=>({animated:n(r)}),()=>({animated:n(r)}),()=>({hidden:n(o)}),()=>({hidden:!n(o)})]),$(v,y)},$$slots:{default:!0}})};V(s,p=>{t()?p(u):p(m,!1)})}$(i,d),H()}var kb=require("@vkontakte/videoplayer-shared/es2015");function vc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"click",3,kb.noop),l=$e().ui.t,d=f(()=>e.state===Pb.ChromecastState.CONNECTED?l("tooltip_chromecast_on"):l("tooltip_chromecast_off"));Kt(i,{get ariaLabel(){return n(d)},get click(){return r()},testId:"btn-chromecast",get ref(){return t()},set ref(s){t(s)},children:(s,u)=>{mc(s,{get isMobile(){return o()},get iconState(){return e.state}})},$$slots:{default:!0}}),H()}var Ab=require("@vkontakte/videoplayer-shared/es2015");var t2=Ee('<path d="m21.62 16.5-.02.07q-.22 1.27-.42 2.09a5 5 0 0 1-.64 1.5 4.4 4.4 0 0 1-2.51 1.73q-.77.18-1.63.07t-2.11-.34l-4.34-.8q-1.27-.22-2.1-.42a5 5 0 0 1-1.5-.65 4.4 4.4 0 0 1-1.72-2.5 5 5 0 0 1-.07-1.63q.1-.84.34-2.11l.01-.07q.22-1.27.43-2.1a5 5 0 0 1 .64-1.5 4.4 4.4 0 0 1 2.5-1.73 5 5 0 0 1 1.64-.07q.83.1 2.1.35l4.34.8q1.28.21 2.1.42a5 5 0 0 1 1.5.64 4.4 4.4 0 0 1 1.73 2.5q.18.78.07 1.64-.1.83-.34 2.1m-1.45-2.3c.05-.49.03-.77-.02-1a2.6 2.6 0 0 0-1.02-1.48 3 3 0 0 0-.93-.37c-.48-.13-1.1-.24-2-.4l-4.26-.79c-.9-.16-1.52-.27-2.01-.33a3 3 0 0 0-1 .03 2.6 2.6 0 0 0-1.48 1.02 3 3 0 0 0-.37.92c-.13.48-.24 1.1-.4 2s-.28 1.51-.33 2c-.06.5-.04.78.02 1 .15.6.51 1.13 1.02 1.48.19.13.45.25.92.37.48.13 1.1.25 2 .4l4.27.79c.9.16 1.52.28 2.01.33s.77.03 1-.02a2.6 2.6 0 0 0 1.47-1.03c.14-.19.25-.45.38-.92.12-.48.24-1.1.4-2s.28-1.51.33-2"></path><path d="M18.19 7.49a.9.9 0 0 1-1.05-.73c-.14-.8-.2-1.08-.28-1.3A2.6 2.6 0 0 0 14.5 3.8c-.22 0-.5.04-1.31.17l-5.85.96a8 8 0 0 0-2.17.5 2.6 2.6 0 0 0-1.33 1.75c-.08.38-.04.85.11 2.23l.01.1a.9.9 0 1 1-1.78.2l-.01-.1-.02-.17a9 9 0 0 1-.07-2.64 4.4 4.4 0 0 1 2.25-2.97c.63-.33 1.42-.46 2.56-.65l.16-.03 5.85-.96.1-.01c.67-.11 1.13-.19 1.55-.18a4.4 4.4 0 0 1 4 2.82c.14.39.23.85.35 1.53l.01.1a.9.9 0 0 1-.72 1.04"></path><path d="M12.72 12.41a.42.42 0 0 0-.69.23l-.72 4.18a.4.4 0 0 0 .03.23c.08.2.33.3.54.22l3.67-1.47a.4.4 0 0 0 .12-.68z"></path>',1);function qm(i){Ze(i,{testId:"episodes-icon",children:(e,t)=>{var o=t2();ni(2),$(e,o)},$$slots:{default:!0}})}var lp=(i,e,t)=>t.filter(o=>o.time<=i*e).pop();var i2=L('<span class="text mobile s-22"> </span> <div class="chevron-episodes s-22" data-testid="btn-episodes_icon"><!></div>',1),o2=L('<span class="text s-22"> </span>'),n2=L('<span class="text count s-22"> </span>'),r2=L('<span class="icon s-22"><!></span> <!>',1),s2={hash:"s-22",code:".icon.s-22{flex-shrink:0}.text.s-22{overflow:hidden;padding:0 8px;text-overflow:ellipsis;white-space:nowrap}.text.count.s-22{overflow:visible}.text.mobile.s-22{padding:0 3px 0 4px}.chevron-episodes.s-22{margin-bottom:-6px;opacity:.7;transform:scale(.8)}"};function gc(i,e){var Z,Te,fe;B(e,!0),Q(i,s2);let[t,o]=He(),r=()=>w(y,"$currentGridType$",t),a=()=>w(_,"$openedByKeyboard$",t),l=()=>w(x,"$panelOpened$",t),d=()=>w(I,"$isMobile",t),s=h(e,"position",3,0),u=h(e,"duration",3,0),m=h(e,"timeCodes",19,()=>[]),p=$e(),v=(Te=(Z=p.callbacks)==null?void 0:Z.onEpisodeChanged)!=null?Te:Ab.noop,b=!!((fe=p.callbacks)!=null&&fe.onEpisodeClicked),y=p.ui.currentGridType$,_=p.ui.episodes.openedByKeyboard$,x=p.ui.episodes.panelOpened$,I=p.ui.isMobile,C=p.ui.t,R=K(void 0),A=te=>{var Ce,me,ce;if(!!((Ce=p.callbacks)!=null&&Ce.onEpisodeClicked)){let Ye=fa(te);_.set(Ye),x.set(!0),(ce=(me=p.callbacks)==null?void 0:me.onEpisodeClicked)==null||ce.call(me,Ye)}},P=K(null),E=f(()=>s()/u());Fe(()=>{var _e;let te=lp(n(E),u(),m());te?((_e=n(P))==null?void 0:_e.time)!==te.time&&(v(te),O(P,te,!0)):O(P,null)});let W=f(()=>{var te;return((te=n(P))==null?void 0:te.text)||""}),F=f(()=>ao(r(),"xl")?"FULL":ao(r(),"m")?"COUNT":"SHORT"),U=f(()=>`${C("tooltip_episodes")}: ${n(W)}`),X=(te,_e,Ce)=>bt(null,null,function*(){yield _o(),(te==null?void 0:te.getAttribute("aria-expanded"))==="false"&&_e&&!Ce&&Et(()=>{_.set(!1),te.focus()})});Fe(()=>{X(n(R),a(),l())});var se=Oe(),j=le(se);{var ne=te=>{let _e=f(()=>d()?"px-0":""),Ce=f(()=>!b);Kt(te,{get className(){var me;return`w-max btn-full-opacity btn-jc-l ${(me=n(_e))!=null?me:""}`},testId:"btn-episodes",click:A,get disabled(){return n(Ce)},get ariaExpanded(){return l()},get ariaLabel(){return n(U)},get ref(){return n(R)},set ref(me){O(R,me,!0)},children:(me,ce)=>{var Ye=Oe(),G=le(Ye);{var D=re=>{var pe=i2(),ue=le(pe),Ae=T(ue,!0);S(ue);var ze=k(ue,2),ee=T(ze);Rr(ee,{direction:"right"}),S(ze),N(()=>ge(Ae,n(W))),$(re,pe)},Xe=re=>{var pe=r2(),ue=le(pe),Ae=T(ue);qm(Ae,{}),S(ue);var ze=k(ue,2);{var ee=ke=>{var xe=o2(),Je=T(xe,!0);S(xe),N(()=>ge(Je,n(W))),$(ke,xe)},de=(ke,xe)=>{{var Je=Pe=>{var we=n2(),Ne=T(we,!0);S(we),N(()=>ge(Ne,m().length)),$(Pe,we)};V(ke,Pe=>{n(F)==="COUNT"&&Pe(Je)},xe)}};V(ze,ke=>{n(F)==="FULL"?ke(ee):ke(de,!1)})}$(re,pe)};V(G,re=>{d()?re(D):re(Xe,!1)})}$(me,Ye)},$$slots:{default:!0}})};V(j,te=>{n(P)&&te(ne)})}$(i,se),H(),o()}var hv=require("@vkontakte/videoplayer-shared/es2015");var gi=require("@vkontakte/videoplayer-core/es2015"),dt=require("@vkontakte/videoplayer-shared/es2015"),Dr=require("@vkontakte/videoplayer-statistics/es2015");var Ge=require("@vkontakte/videoplayer-shared/es2015"),lo=require("@vkontakte/videoplayer-shared/es2015");var a2="//ad.mail.ru/static/admanhtml/rbadman-html5.min.js",dp=class{constructor(e,t){this.adman=null;this.initialVolume=1;this.videoElement=null;this.currentAdSection=null;this.actions=null;this.adsState=null;this.playerState=null;this.events={init$:new lo.Subject,loadStarted$:new lo.Subject,loadEnded$:new lo.Subject,loadError$:new lo.Subject,ready$:new lo.Subject,slotRequested$:new lo.Subject,started$:new lo.Subject,timeRemained$:new lo.Subject,paused$:new lo.Subject,resumed$:new lo.Subject,ended$:new lo.Subject,empty$:new lo.Subject,skipped$:new lo.Subject,clicked$:new lo.Subject,closed$:new lo.Subject,error$:new lo.Subject};this.loadAdman=e=>(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_start",this.useAdmanFromNPM?"npm":"http"],numbers:[(0,Ge.now)()]}),this.useAdmanFromNPM?this.loadAdmanNPM(e):this.loadAdmanMailRu(e));this.loadAdmanMailRu=e=>new Promise((t,o)=>{let r;this.events.loadStarted$.next();let a=()=>{clearTimeout(r),delete window.admanAsyncInit,window.AdmanHTML?(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_async_init_done","http"],numbers:[(0,Ge.now)()]}),t(),this.events.loadEnded$.next()):(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","http"],numbers:[(0,Ge.now)()]}),o())};(0,lo.addScript)(a2,e,this.loadTimeout).then(()=>{Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_loaded","http"],numbers:[(0,Ge.now)()]}),window.AdmanHTML?(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","http"],numbers:[(0,Ge.now)()]}),t(),this.events.loadEnded$.next()):(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","http"],numbers:[(0,Ge.now)()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout))}).catch(l=>{Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_load_error","http",String(l)],numbers:[(0,Ge.now)()]}),o(),clearTimeout(r)})});this.loadAdmanNPM=e=>new Promise((t,o)=>{let r;this.events.loadStarted$.next();let a=()=>{clearTimeout(r),delete window.admanAsyncInit,window.AdmanHTML?(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_done","npm"],numbers:[(0,Ge.now)()]}),t(),this.events.loadEnded$.next()):(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","npm"],numbers:[(0,Ge.now)()]}),o())},l=()=>{d=!0,o()},d=!1,s=window.setTimeout(()=>{Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_timed_out","npm"],numbers:[(0,Ge.now)()]}),l()},this.loadTimeout);e.addEventListener("abort",l),e.aborted&&(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_aborted","npm"],numbers:[(0,Ge.now)()]}),l()),window.AdmanHTML=window.AdmanHTML||null,import("@adtech/rbadman/out/rbadman-html5.min.js").then(()=>{Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_chunk_imorted","npm","failed: "+String(d)],numbers:[(0,Ge.now)()]}),!d&&(window.AdmanHTML?(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","npm"],numbers:[(0,Ge.now)()]}),t(),this.events.loadEnded$.next()):(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","npm"],numbers:[(0,Ge.now)()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout)))},l).finally(()=>{clearTimeout(r),clearTimeout(s),e.removeEventListener("abort",l)})});this.onAdsReady=()=>{Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_ready"],numbers:[(0,Ge.now)()]}),this.log({message:"ads ready"}),this.events.ready$.next(),this.startPreroll()};this.onAdStarted=(e,t)=>{var o;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_started",e,"muted: "+t.muted],numbers:[(0,Ge.now)(),t.bannerID]}),this.adsState&&this.playerState&&this.actions?(this.log({message:`ad started, section: ${e}, banner: ${JSON.stringify(t)}`}),this.events.started$.next(e),t.muted&&(this.setVolume(0),this.actions.setMuted(!0),this.log({message:"ad muted start"})),this.adsState.duration.set(t.duration),this.adsState.playbackState.set("playing"),this.adsState.canSkip.set(t.allowClose),this.adsState.secondsToWatchBeforeSkip.set(t.allowCloseDelay),this.startWatchDog(),(o=this.externalApi)!=null&&o.videoTrackAdEvent&&this.safeExternalCall(this.externalApi.videoTrackAdEvent,e,String(t.bannerID))):this.onAdError("Started callback failed: Adman is not initialized")};this.onAdTimeRemained=e=>{var o;((o=this.adsState)!=null&&o.playbackState?be(this.adsState.playbackState):void 0)!=="inactive"&&(this.adsState?(this.adsState.position.set(e.currentTime),this.events.timeRemained$.next(e),this.startWatchDog()):this.onAdError("TimeRemained callback failed: Adman state is not initialized"))};this.onAdPaused=()=>{var e;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_pased",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.stopWatchDog(),this.adsState?(this.log({message:"ad paused"}),this.adsState.playbackState.set("paused")):this.onAdError("Paused callback failed: Adman state is not initialized")};this.onAdPlayed=()=>{var e;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_played",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.startWatchDog(),this.adsState?(this.log({message:"ad played"}),this.adsState.playbackState.set("playing")):this.onAdError("Player callback failed: Adman is not initialized")};this.onAdMidrollPoint=()=>{if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_midroll_pioint"],numbers:[(0,Ge.now)()]}),this.adman&&this.actions){this.log({message:"midroll point"}),this.actions.switchFromVideoToAds(),this.currentAdSection="midroll",this.startWatchDog();try{this.adman.start("midroll")}catch(e){this.onAdError("could not start midroll")}}else this.onAdError("Midroll callback failed: Adman is not initialized")};this.onAdSkipped=()=>{var e;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_skipped",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.log({message:"ad skipped"}),this.stopWatchDog()};this.onAdClosed=()=>{var e;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_closed",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.log({message:"ad closed"}),this.currentAdSection&&this.events.closed$.next(this.currentAdSection),this.stopWatchDog(),this.switchToVideo()};this.onAdCompleted=()=>{var e;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_completed",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.log({message:"ad completed"}),this.currentAdSection?(this.events.ended$.next(this.currentAdSection),this.currentAdSection==="postroll"&&this.setPostrollPassed(!0)):this.events.empty$.next(),this.switchToVideo(),this.stopWatchDog()};this.onAdClicked=()=>{var e,t;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_clicked",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.log({message:"ad clicked"}),(t=this.videoElement)==null||t.pause(),this.currentAdSection&&this.events.clicked$.next(this.currentAdSection),this.stopWatchDog()};this.onAdError=(e="ad error")=>{Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_error",e],numbers:[(0,Ge.now)()]}),this.log({message:e}),this.events.error$.next(e),this.currentAdSection==="postroll"&&this.setPostrollPassed(!0),this.switchToVideo(!0),this.stopWatchDog()};this.log=e.createComponentLog("AdmanWrapper"),Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_created"],numbers:[(0,Ge.now)()]}),this.loadTimeout=t.loadTimeout,this.initTimeout=t.initTimeout,this.runtimeTimeout=t.runtimeTimeout,this.useAdmanFromNPM=t.useAdmanFromNPM,this.volumeMultiplier=Math.max(0,Math.min(t.volumeMultiplier,1)),this.isVsidOriginal=t.isVsidOriginal}init(e,t,o){this.actions=e,this.adsState=t,this.playerState=o}onAdmanLoadingError(){this.onAdError("adman loading error")}initAdman(e){return bt(this,null,function*(){var A,P;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init","already inited: "+!!this.adman],numbers:[(0,Ge.now)(),e.slotId]}),this.adman)return;this.events.init$.next(e.slotId),this.startWatchDog();let{width:t,height:o,isAutoplay:r,adsContainer:a,adsVideoElement:l,slotId:d,params:s={},paramsOverride:u={},duration:m,externalApi:p,json:v}=e;this.externalApi=p;let b,y=this.playerState&&be(this.playerState.vsid);y&&(this.isVsidOriginal?b=y:b=parseInt(y,36));let{isEmbed:_,immediateOrigin:x}=(0,Ge.detectEmbed)(),I=(A=_?x:window.location.href)!=null?A:window.location.href,C=(0,Ge.withoutNullable)(Ve(Gt(Ve(Gt(Ve({},s),{dl:encodeURIComponent(I),autoplay:r?1:0,player_width:t,player_height:o}),b?{request_id:b}:{}),{duration:m}),u)),R=(0,Ge.withoutNullable)({slot:v?void 0:d,wrapper:a,videoEl:l,videoQuality:o,params:v?void 0:C,browser:{mobile:!1},json:v});try{let E=new window.AdmanHTML;if(E.onReady(this.onAdsReady),E.onStarted(this.onAdStarted),E.onPlayed(this.onAdPlayed),E.onPaused(this.onAdPaused),E.adMidrollPoint(this.onAdMidrollPoint),E.onClosed(this.onAdClosed),E.onSkipped(this.onAdSkipped),E.onClicked(this.onAdClicked),E.onTimeRemained(this.onAdTimeRemained),E.onCompleted(this.onAdCompleted),E.onError(this.onAdError),E.setDebug(!1),!v&&((P=this.externalApi)!=null&&P.videoGetAds)){let W=yield this.safeExternalCall(this.externalApi.videoGetAds,C);W&&(delete R.slot,delete R.params,Object.assign(R,{json:W}))}E.init(R),this.adman=E,this.videoElement=l,this.events.slotRequested$.next(),this.log({message:`adman init, config: ${JSON.stringify(R)}`})}catch(E){Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_threw",String(E)],numbers:[(0,Ge.now)()]}),this.onAdError("could not init adman")}})}switchToVideo(e=!1){var o,r,a;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_switch_to_video",(o=this.currentAdSection)!=null?o:"","force: "+e],numbers:[(0,Ge.now)()]}),this.currentAdSection===null&&!e){this.log({message:"switch to video, no currentAdSection. can't switch"});return}let t=this.currentAdSection==="postroll";if(this.actions){if(this.adsState&&this.playerState)this.adsState.playbackState.set("inactive"),this.currentAdSection=null,this.log({message:`switch to video, isPostroll: ${t}`});else{let l="Switch to video: Adman state was not updated correctly";this.log({message:l}),this.events.error$.next(l)}(a=(r=this.actions).switchFromAdsToVideo)==null||a.call(r,!t)}}setPostrollPassed(e){var t;(t=this.adsState)==null||t.postrollPassed.set(e),this.log({message:"postroll passed"})}togglePlay(){var e;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_toggle_play",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.adsState){this.log({message:"toggle play"});let t=be(this.adsState.playbackState);t==="playing"?this.pause():t==="paused"&&this.play()}else this.onAdError("Can not toggle play: Adman state is not initialized")}setInitialVolume(e){this.log({message:`set initial volume ${e}`}),this.initialVolume=e}setVolume(e){let t=e*this.volumeMultiplier;if(this.log({message:`set volume ${t}`}),this.adman)try{this.adman.setVolume(t)}catch(o){this.onAdError("could not set ad volume")}this.videoElement&&(this.videoElement.volume=t)}setFullscreen(e){if(this.log({message:`set fullscreen ${e}`}),this.adman)try{this.adman.setFullscreen(e)}catch(t){this.onAdError("could not set ad fullscreen")}}startPreroll(){if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_preroll"],numbers:[(0,Ge.now)()]}),this.adman){if(!this.isDestroyed){this.log({message:"start preroll"}),this.setVolume(this.initialVolume),this.currentAdSection="preroll",this.startWatchDog();try{this.adman.start("preroll")}catch(e){this.onAdError("could not start preroll")}}}else this.onAdError("Can not start preroll: Adman is not initialized")}startPostroll(){var e;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_postroll",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.adman&&this.actions){this.log({message:"start postroll"}),this.actions.switchFromVideoToAds(),this.currentAdSection="postroll",this.startWatchDog();try{this.adman.start("postroll")}catch(t){this.onAdError("could not start postroll")}}else this.onAdError("Can not start postroll: Adman is not initialized")}startWatchDog(){this.watchDogTimeout&&this.stopWatchDog(),this.watchDogTimeout=window.setTimeout(()=>this.onAdError("Watchdog timeout"),this.runtimeTimeout)}stopWatchDog(){clearTimeout(this.watchDogTimeout)}play(){var e;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_pplay",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.adman){this.log({message:"ad play"}),this.startWatchDog();try{this.adman.resume(),this.events.resumed$.next()}catch(t){this.onAdError("could not resume ad")}}else this.onAdError("Can not play: Adman is not initialized")}pause(){var e;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_pause",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.adman){this.stopWatchDog(),this.log({message:"ad pause"});try{this.adman.pause(),this.events.paused$.next()}catch(t){this.onAdError("could not pause ad")}}else this.onAdError("Can not pause: Adman is not initialized")}skip(){var e;if(Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_skip",(e=this.currentAdSection)!=null?e:""],numbers:[(0,Ge.now)()]}),this.adman){this.stopWatchDog(),this.log({message:"ad skip"});try{this.adman.skip(),this.events.skipped$.next()}catch(t){this.onAdError("could not skip ad")}}else this.onAdError("Can not skip: Adman is not initialized")}setPosition(e,t){var o;(o=this.adman)==null||o.setPosition(Math.floor(e),Math.floor(t))}destroy(){var e,t,o,r,a,l,d,s,u,m,p,v;Ge.devNull.push("ui",{key:"videoplayer_embed",strings:["new","adman_destroy"],numbers:[(0,Ge.now)()]}),this.log({message:"destroy"}),this.stopWatchDog(),(e=this.adman)==null||e.onReady(void 0),(t=this.adman)==null||t.onStarted(void 0),(o=this.adman)==null||o.onPlayed(void 0),(r=this.adman)==null||r.onPaused(void 0),(a=this.adman)==null||a.adMidrollPoint(void 0),(l=this.adman)==null||l.onClosed(void 0),(d=this.adman)==null||d.onSkipped(void 0),(s=this.adman)==null||s.onClicked(void 0),(u=this.adman)==null||u.onTimeRemained(void 0),(m=this.adman)==null||m.onCompleted(void 0),(p=this.adman)==null||p.onError(void 0),(v=this.adman)==null||v.destroy(),this.videoElement&&(0,lo.clearVideoElement)(this.videoElement),this.isDestroyed=!0}safeExternalCall(e,...t){return bt(this,null,function*(){var o;try{return yield e(...t)}catch(r){return this.onAdError((o=r==null?void 0:r.message)!=null?o:"External call failed"),null}})}};var Lb=i=>{let e=Math.round(i);return isNaN(e)||e<40?"":e>=40&&e<55?50:e>=55&&e<90?60:e>=90&&e<180?120:e>=180?240:""};var Qm=class{constructor(){this.oneLineRegExp=/\r\n|\n|\r/;this.twoLinesRegExp=/\r\n\r\n|\n\n|\r\r/}parse(e,t){let o=[],r=e.split(this.twoLinesRegExp);for(let a of r){let l={startTime:0,endTime:0,texts:[],lang:t},d=a.split(this.oneLineRegExp);for(let s of d)if(!l.startTime&&!l.endTime){let u=new cp,{startTime:m,endTime:p}=u.parse(s);l.startTime=m,l.endTime=p}else if(s.trim()!==""){let u=new Gm,{texts:m}=u.parse(s);l.texts=[...l.texts,...m]}(l.startTime||l.endTime)&&l.texts.length>0&&o.push(l)}return o}},cp=class{constructor(){this.timeRegExp=/(\d{2,})?:?(\d{2}):(\d{2}).(\d{2,3})/;this.timingRegExp=new RegExp(`${this.timeRegExp.source}( ?--> ?)${this.timeRegExp.source}`)}parse(e){let t={startTime:0,endTime:0},o=this.timingRegExp.exec(e);return o&&(t.startTime=this.calcTime(o[1],o[2],o[3],o[4]),t.endTime=this.calcTime(o[6],o[7],o[8],o[9])),t}parseTime(e){let t=this.timeRegExp.exec(e);return t?this.calcTime(t[1],t[2],t[3],t[4]):0}isTime(e){return this.timeRegExp.test(e)}calcTime(e="0",t="0",o="0",r="0"){let a=Number(e)*60*60,l=Number(t)*60,d=Number(o),s=+`0.${r}`;return a+l+d+s}},Gm=class{constructor(){this.letterTagRegExp=/<[a-z]*>|<\/[a-z]*>/}parse(e){let t={texts:[]},r=e.replace(new RegExp(this.letterTagRegExp,"g"),"").split({[Symbol.split](l){let d=0,s=[];for(;d<l.length;){let u=["<",">"].reduce((m,p)=>{let v=l.indexOf(p,d);return m===-1||m>v?v:m},-1);if(u===-1){s.push(l.substring(d));break}s.push(l.substring(d,u)),d=u+1}return s}}),a=new cp;for(let l of r)a.isTime(l)?t.texts.push({type:"timestamp",value:a.parseTime(l)}):t.texts.push({type:"text",value:l});return t}},Mb=Qm;var pp=require("@vkontakte/videoplayer-shared/es2015"),Ja,Ri,Ym=0,jm=!1,Vb="",Rb=(i,e=0,t=0)=>i<e&&i<t,up=(i,e=0,t=0)=>i>=e&&i<=t,l2=(i,e=0,t=0)=>i>e&&i>t,Ob=(i,e,t,o=!1)=>{var d;let r=(d=t.find(({id:s})=>s===e.value))==null?void 0:d.subtitles;if(o)return r==null?void 0:r.find(({startTime:u,endTime:m})=>up(i,u,m));let a=i>=Ym,l=i<Ym;if(Ym=i,l&&(jm=!1),(0,pp.isNonNullable)(Ja)&&up(i,Ja.startTime,Ja.endTime)&&Vb===e.value)return Ja;if(!(0,pp.isNonNullable)(Ri)&&(r!=null&&r.length)&&!jm){Ri=r.find(({startTime:u,endTime:m})=>up(i,u,m)||a&&Rb(i,u,m)),Ja=void 0,!(0,pp.isNonNullable)(Ri)&&r[r.length-1].endTime<i&&(jm=!0);return}else{if(up(i,Ri==null?void 0:Ri.startTime,Ri==null?void 0:Ri.endTime))return Ja=Ri,Ri=void 0,Vb=e.value,Ja;(a&&l2(i,Ri==null?void 0:Ri.startTime,Ri==null?void 0:Ri.endTime)||l&&Rb(i,Ri==null?void 0:Ri.startTime,Ri==null?void 0:Ri.endTime))&&(Ri=void 0)}};var fp={ru:"Русский",en:"English",uk:"Українська",be:"Беларуская (тарашкевiца)",es:"Español",fi:"Suomi",de:"Deutsch",it:"Italiano",bg:"Български",hr:"Hrvatski",hu:"Magyar",sr:"Српски",pt:"Português",el:"Ελληνικά",pl:"Polski",fr:"Français",ko:"한국어","zh-CN":"汉语",lt:"Lietuvių",ja:"日本語",cs:"Čeština",et:"Eesti",tt:"Татарча",ba:"Башҡортса",cv:"Чăвашла",sk:"Slovenčina",ro:"Română",no:"Norsk",lv:"Latviešu",az:"Azərbaycan dili",hy:"Հայերեն",sv:"Svenska",nl:"Nederlands",tk:"Türkmen",ka:"ქართული",da:"Dansk",uz:"O‘zbek",th:"ภาษาไทย",id:"Bahasa Indonesia",tg:"Тоҷикӣ",sl:"Slovenščina",bs:"Bosanski","pt-BR":"Português brasileiro",fa:"فارسی",vi:"Tiếng Việt",hi:"हिन्दी",si:"සිංහල",bn:"বাংলা",tl:"Tagalog",mn:"Монгол",my:"ဗမာစာ",tr:"Türkçe",ne:"नेपाली",ur:"اردو",ky:"Кыргыз тили",pa:"پنجابی",os:"Ирон",kn:"ಕನ್ನಡ",sw:"Kiswahili",kk:"Қазақша",ar:"العربية",he:"עברית",ab:"Аҧсшәа",eu:"Euskara",eo:"Esperanto"},d2={abk:"as",ara:"ar",aze:"az",bak:"ba",bel:"be",ben:"bn",bos:"bs",bul:"bg",ces:"cs",chv:"cv",dan:"da",deu:"de",ell:"el",eng:"en",epo:"eo",est:"et",eus:"eu",fas:"fa",fin:"fi",fra:"fr",heb:"he",hin:"hi",hrv:"hr",hun:"hu",hye:"hy",ind:"id",ita:"it",jpn:"ja",kan:"kn",kat:"ka",kaz:"kk",kir:"ky",kor:"ko",lav:"lv",lit:"lt",mon:"mn",mya:"my",nep:"ne",nld:"nl",nor:"no",oss:"os",pan:"pa",pol:"pl",por:"pt",ron:"ro",rus:"ru",sin:"si",slk:"sk",slv:"sl",spa:"es",srp:"sr",swa:"sw",swe:"sv",tat:"tt",tgk:"tg",tgl:"tl",tha:"th",tuk:"tk",tur:"tr",ukr:"uk",urd:"ur",uzb:"uz",vie:"vi"},hc=i=>{var e,t;return(t=(e=fp[i])!=null?e:fp[d2[i]])!=null?t:void 0};var Xm=require("@vkontakte/videoplayer-core/es2015"),ys=require("@vkontakte/videoplayer-shared/es2015");var Db=require("@vkontakte/videoplayer-shared/es2015"),mp=()=>{var i;return(i=(0,Db.getWindow)().document)==null?void 0:i.pictureInPictureEnabled},vp=i=>!!i.pictureInPictureWindow,Nb=i=>!!i.target&&"height"in i.target&&"width"in i.target;var Us=class{constructor({enabled:e=!0}={enabled:!0}){this.isRequested=!1;this.videoElement=void 0;this.playerContainer=void 0;this.externalEventHandlers={};this.eventHandlers={enterpictureinpicture:this.onEnterPictureInPicture.bind(this),leavepictureinpicture:this.onLeavePictureInPicture.bind(this),resize:(0,ys.debounceFn)(this.onResize.bind(this),300)};this.info={isActive$:new ys.ValueSubject(!1),isEnabled$:new ys.ValueSubject(!1),type:0};this.info.isEnabled$=new ys.ValueSubject(e)}isSupported(){return mp()}isActive(){return this.info.isActive$.getValue()}setContext(e){this.svelteContext=e}revealPictureInPicture(){return bt(this,null,function*(){this.isRequested&&(this.removeEventHandlers(),yield this.request(),this.addEventHandlers())})}request(){return bt(this,null,function*(){var e;if(!(!this.isSupported()||this.isActive()))try{yield(e=this.videoElement)==null?void 0:e.requestPictureInPicture()}catch(t){this.isRequested=!1}})}exit(){return bt(this,null,function*(){let{document:e}=(0,ys.getWindow)();!this.isSupported()||!this.isActive()||!this.videoElement||!e.pictureInPictureElement||(yield e.exitPictureInPicture(),Xm.clientChecker.browser.isYandex&&!this.videoElement.isConnected&&this.onLeavePictureInPicture())})}assignPlayerContainer(e){this.isSupported()&&(this.playerContainer=e)}updateVideoElement(){this.isSupported()&&this.exit().finally(()=>{var t;this.removeEventHandlers();let e=this.videoElement;this.videoElement=(t=this.playerContainer)==null?void 0:t.querySelector("video"),this.waitForSafariLeavePictureInPicture(e,this.videoElement),this.addEventHandlers()})}addEventHandlers(){var e,t;(e=this.videoElement)==null||e.addEventListener("enterpictureinpicture",this.eventHandlers.enterpictureinpicture),(t=this.videoElement)==null||t.addEventListener("leavepictureinpicture",this.eventHandlers.leavepictureinpicture)}setExternalEventHandlers(e){this.externalEventHandlers=Ve({},e)}removeEventHandlers(){var e,t;(e=this.videoElement)==null||e.removeEventListener("enterpictureinpicture",this.eventHandlers.enterpictureinpicture),(t=this.videoElement)==null||t.removeEventListener("leavepictureinpicture",this.eventHandlers.leavepictureinpicture)}dispose(){return bt(this,null,function*(){this.removeEventHandlers(),yield this.exit(),this.info.isActive$.next(!1),this.isRequested=!1})}onEnterPictureInPicture(e){var o,r;let t=vp(e)?e.pictureInPictureWindow:void 0;this.info.isActive$.next(!0),this.isRequested=!0,t==null||t.addEventListener("resize",this.eventHandlers.resize),(r=(o=this.externalEventHandlers).enterpictureinpicture)==null||r.call(o)}onLeavePictureInPicture(e){var t,o;if(e){let r=vp(e)?e.pictureInPictureWindow:void 0;r==null||r.removeEventListener("resize",this.eventHandlers.resize)}this.info.isActive$.next(!1),this.isRequested=!1,this.eventHandlers.resize.cancel(),(o=(t=this.externalEventHandlers).leavepictureinpicture)==null||o.call(t)}onResize(e){var o,r;let t=Nb(e)?e.target:vp(e)?e.pictureInPictureWindow:void 0;t&&((r=(o=this.externalEventHandlers).resize)==null||r.call(o,{width:t.width,height:t.height}))}setEnabled(e){this.info.isEnabled$.next(e)}waitForSafariLeavePictureInPicture(e,t){if(Xm.clientChecker.browser.isSafari&&e&&e!==t){let r=this.eventHandlers.leavepictureinpicture,a=0,l=()=>{(0,ys.getWindow)().clearTimeout(a),e.removeEventListener("leavepictureinpicture",d)},d=s=>(r(s),l());e.addEventListener("leavepictureinpicture",d),a=(0,ys.getWindow)().setTimeout(l,1e3)}}};function Bb(i){return i instanceof Us}var Hb=require("@vkontakte/videoplayer-shared/es2015"),sH=require("@vkontakte/videoplayer-statistics/es2015"),gp=class{constructor(e,t,o,r=new Hb.Subscription){this.oneStat=e;this.thinOneStat=t;this.mediascopePixel=o;this.statSubscription=r}destroy(){var e,t,o;(e=this.oneStat)==null||e.destroy(),(t=this.thinOneStat)==null||t.destroy(),(o=this.mediascopePixel)==null||o.destroy(),this.statSubscription.unsubscribe()}};var bc=(t=>(t.DESKTOP_CONTROL_PANEL_LEFT="desktop-control-panel-left",t.DESKTOP_CONTROL_PANEL_RIGHT="desktop-control-panel-right",t))(bc||{});var xs=i=>i!=null?i:0,zs=(i,e)=>{var r,a;let t=(r=i==null?void 0:i.getBoundingClientRect)==null?void 0:r.call(i),o=(a=e==null?void 0:e.getBoundingClientRect)==null?void 0:a.call(e);return{top:Math.round(xs(t==null?void 0:t.top)-xs(o==null?void 0:o.top)),left:Math.round(xs(t==null?void 0:t.left)-xs(o==null?void 0:o.left)),bottom:Math.round(xs(t==null?void 0:t.bottom)-xs(o==null?void 0:o.top)),right:Math.round(xs(t==null?void 0:t.right)-xs(o==null?void 0:o.left))}},ed=i=>{var t;let e=(t=i==null?void 0:i.getBoundingClientRect)==null?void 0:t.call(i);return{width:xs(e==null?void 0:e.width),height:xs(e==null?void 0:e.height)}};var Vn="off";var td=i=>!!(Math.round(Math.abs(i)/90)%2);var Fb=({interfaceLanguage:i,isCyrillicRelatedInterface:e,videoId:t,isClip:o,isLiveCatchUpMode:r,statAuthToken:a,isAudioDisabled:l,canDownload:d,callbacks:s,webApi:u,videoEpisodes:m,previewThumbsData:p,uiConfig:v,coreConfig:b,player:y,disabledControls:_,isInteractive:x,interactiveRanges$:I,isInteractiveTime$:C,replayInteractive:R,stopPlayer:A,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,additionalButtons:W,additionalSettingsMenuItems:F,additionalContextMenuItems:U,playPrevVideo:X,playNextVideo:se,onVideoChanged:j,looped:ne=!1,statistics:Z,saveRate:Te,internalsExposure:fe,playerView:te,playerId:_e,metaConfig:Ce})=>{var Tg,Ig;let me=Gt(Ve({},b),{isAudioDisabled:l,live:Gt(Ve({},(Tg=b.live)!=null?Tg:{}),{isLiveCatchUpMode:!!r})}),ce=v,Ye=dt.TracerFactory.createRootTracer(ce.features.tracer),G=Ye.createComponentTracer("Store"),D=y||new gi.Player(me,Ye,{playerId:_e,onDevNullLog:s==null?void 0:s.onDevNullLog});fe==null||fe.expose({corePlayer:D});let Xe=new dt.Logger,re=new dp(Xe,{loadTimeout:ce.ads.loadTimeout,initTimeout:ce.ads.initTimeout,runtimeTimeout:ce.ads.runtimeTimeout,useAdmanFromNPM:ce.ads.useAdmanFromNPM,volumeMultiplier:ce.ads.volumeMultiplier,isVsidOriginal:ce.ads.isVsidOriginal}),pe=Ka.getInstance(),ue=u==null?void 0:u.pictureInPictureApi,Ae=u==null?void 0:u.annotationsApi,ze=u==null?void 0:u.slotsApi,ee=u==null?void 0:u.focusManager,de=Xe.createComponentLog("Store"),ke,xe,Je={},Pe=new Nu,we=new dt.Subscription,Ne="",Pt=ae(!1),kt=Z&&Z.oneStat?si(Z.oneStat.vsid$):Vr(void 0),Lt=ae(ca()),pt=ae(!1),It=()=>rb(document,gi.clientChecker.device.isIOS),ei=(Ig=ue==null?void 0:ue.info.isActive$)!=null?Ig:new dt.ValueSubject(!1),Ft=ae(0),Bt=ae(!1),qt=ae(!1),q=ae([]),Le=(0,dt.merge)(D.events.fatalError$,D.events.managedError$).subscribe(c=>q.update(g=>[...g,c])),Me=Vr(!1,c=>{let g=D.events.fatalError$.subscribe(()=>c(!0));return()=>g.unsubscribe()}),ye=c=>bt(null,null,function*(){var ie;let g=Object.values(dt.InterfaceLanguage).includes(c);if(ce.downloadVKLanguages&&(g&&ce.updateBuiltinLanguages||!lm(c))){let Ie;try{Ie=yield(0,dt.loadVKLangPack)(c,g_,h_)}catch(tt){(ie=Z==null?void 0:Z.oneStat)==null||ie.logError({errorType:"VKLangPack",fatal:!1}),pe==null||pe.report(tt,{errorType:"VKLangPack",fatal:!1})}Ie&&(am({language:c,pack:Ie,fallback:ce.defaultLanguage}),Ue.set(c),Se.update(tt=>tt+1))}lm(c)&&Ue.set(c)}),Ue=ae(i),Se=ae(0),Tt=ae(e);ye(i);let ve=(c,g)=>{let M=be(Ue);return dm(M,c,g,ce.defaultLanguage)},Be=ae("thumb");Be.subscribe(c=>{c==="ads"&&D.info.playbackState$.getValue()&&Xt()});let qe=(()=>{let c=mi([Me,Be],([g,M])=>g?"crashed":M);return Gt(Ve({},c),{is:g=>be(c)===g})})(),ct=ae(),Xt=()=>{ct.set({muted:D.info.muted$.getValue()})},Mt=(()=>{let c=ae(new Set(_));return Gt(Ve({},c),{add:g=>{c.update(M=>new Set([...M].concat(g)))},remove:g=>{c.update(M=>{let ie=[...M];return new Set(Array.isArray(g)?ie.filter(Ie=>!g.includes(Ie)):ie.filter(Ie=>Ie!==g))})},includes:g=>{let M=be(c);return Array.isArray(g)?g.every(ie=>M.has(ie)):M.has(g)}})})(),di=ae({width:0,height:0}),ci=null,Li=D.info.isBuffering$,bo=Vr(Li.getValue(),c=>{let g=Li.subscribe(M=>{M&&ci===null?ci=window.setTimeout(()=>{c(Li.getValue()),ci=null},ce.loaderDelay):c(M)});return()=>{g.unsubscribe(),ci&&clearTimeout(ci)}});G.log("create store"),de({message:"create store"});let $o=c=>{let g=c.container,M=()=>{hi=new MutationObserver(Ie=>{let{removedNodes:tt}=Ie[0];tt.length&&g.append(D.experimental.element$.getValue())}),hi.observe(g,{childList:!0})},ie=D.experimental.element$.getValue();if(ie)g.append(ie),M();else{let Ie=D.experimental.element$.pipe((0,dt.filter)(tt=>!!tt),(0,dt.once)()).subscribe(tt=>{g.append(tt),M()});we.add(Ie)}},ui=c=>{de({message:`init video, config: ${JSON.stringify(c)}`}),x?$o(c):(dt.devNull.push("ui",{key:"videoplayer_embed",strings:["new","core_init_video"],numbers:[(0,dt.now)()]}),D.initVideo(c)),G.log("init video",{isInteractive:x}),c.subtitles&&D.setExternalTextTracks(c.subtitles),ke=c,Ne=c.subtitlesForcedLanguage||""},at=new dt.Subject,pi=c=>at.next(c),Ji=new dt.Subject,ft=new dt.ValueSubject(Dr.SeekAction.UNKNOWN),Ht=new dt.Subject,hi=null,rt={actionRewind$:Ji,actionSeek$:ft,inPiP$:ei,inFullscreen$:new dt.Observable(c=>Lt.subscribe(g=>c.next(g))),actionSetSubtitle$:Ht,nextMovie$:at},st=new dt.Subject,Pi=new dt.Subject,rn={actionSeek$:ft,actionSubtitlesSwitched$:st,actionQuality$:Pi,playerSize$:new dt.Observable(c=>di.subscribe(g=>c.next(g))),inPiP$:ei,inFullscreen$:new dt.Observable(c=>Lt.subscribe(g=>c.next(g))),isLoaderVisible$:new dt.Observable(c=>bo.subscribe(g=>c.next(g)))};if(Z){let{oneStat:c,thinOneStat:g,mediascopePixel:M,statSubscription:ie}=Z;c&&(x||ie.add(c.attachTo(D)),ie.add(c.attachToUi(rt)),ie.add(c.attachToAds(re.events)),c.authorize(a).catch(Ie=>{de({message:`onestat auth error ${String(Ie)}`})}),M&&M.attachTo(D)),g&&(ie.add(g.attachTo(D,re.events)),ie.add(g.attachToUi(rn)),ie.add(g.attachToAds(re.events)),g.updateContext({isMobile:be(Pt)}),g.authorize(a))}if(pe){let c=new dt.Subscription,g=(M,ie)=>c.add(M.subscribe(ie));if(g(D.events.managedError$,M=>{pe.logIError(M)}),g(D.events.fatalError$,M=>{pe.logIError(M,!0)}),Z){let{oneStat:M}=Z;M&&g(M.experimental.error$,ie=>{pe.logIError(ie)})}pe.sentrySubscription.add(c)}let No=()=>{if(gi.clientChecker.device.isIOS&&xe)try{sb(xe)}catch(c){de({message:`exitIosSafariFullscreen failed: ${c}`})}};we.add(D.experimental.element$.subscribe(c=>{c&&(xe=c,c.classList.add("player-media"),ue==null||ue.updateVideoElement(),x&&c.setAttribute("pip","false"),(te==="preview"||!ce.features.pip&&!ce.features.dpip)&&(c.setAttribute("disablePictureInPicture","true"),c.setAttribute("x-yandex-pip","false")))})).add(D.events.ended$.subscribe(()=>{var c;No(),(c=s==null?void 0:s.onEnded)==null||c.call(s)})).add(D.events.looped$.subscribe(()=>{var c;(c=s==null?void 0:s.onLooped)==null||c.call(s)})).add(D.events.started$.subscribe(()=>bt(null,null,function*(){var g,M;Bb(ue)&&(yield ue==null?void 0:ue.revealPictureInPicture());let c=D.info.muted$.getValue();(g=s==null?void 0:s.onStarted)==null||g.call(s),(M=Je.onStarted)==null||M.call(Je,c)}))).add(D.events.willSeek$.subscribe(({from:c,to:g})=>{var M;(M=s==null?void 0:s.onSeek)==null||M.call(s,c,g,ft.getValue())})).add(D.events.autoplaySoundProhibited$.subscribe(()=>{var c;(c=s==null?void 0:s.onAutoplaySoundProhibited)==null||c.call(s)})).add(D.info.position$.subscribe(c=>{var M;let g=D.info.duration$.getValue();isFinite(g)&&g>0&&((M=s==null?void 0:s.onTimeupdate)==null||M.call(s,g,c),re.setPosition(c,g))})).add(D.events.fatalError$.subscribe(c=>{var g;(g=s==null?void 0:s.onCrashed)==null||g.call(s,c?`${c.id}: ${c.message}`:void 0)})).add(D.events.fetcherRecoverableError$.subscribe(c=>{var g;(g=s==null?void 0:s.onRecoverableError)==null||g.call(s,c?`${c.id}: ${c.message}`:void 0)})).add(D.events.loadedMetadata$.subscribe(()=>{Bt.set(!0)})).add(D.info.is3DVideo$.subscribe(c=>{qt.set(c)})).add(D.info.isEnded$.subscribe(c=>{x&&(c?(C!=null&&C.getValue()&&Mt.add(Qd),Mt.add("PLAY_BUTTON")):Mt.remove("PLAY_BUTTON"))})).add(D.info.liveTime$.subscribe(c=>{var g;(g=s==null?void 0:s.onLiveTime)==null||g.call(s,c)})).add(D.info.isStalled$.subscribe(c=>{var g;(g=s==null?void 0:s.onStalledChanged)==null||g.call(s,c)})).add(D.info.isLiveEnded$.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onLiveEnded)==null?void 0:g.call(s))})).add(re.events.loadStarted$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onLoadStarted)==null?void 0:g.call(c)})).add(re.events.loadEnded$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onLoadEnded)==null?void 0:g.call(c)})).add(re.events.loadError$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onLoadError)==null?void 0:g.call(c)})).add(re.events.init$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onInit)==null?void 0:g.call(c)})).add(re.events.ready$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onReady)==null?void 0:g.call(c)})).add(re.events.started$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onStarted)==null?void 0:M.call(g,c)})).add(re.events.timeRemained$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onTimeRemained)==null?void 0:M.call(g,c)})).add(re.events.ended$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onCompleted)==null?void 0:M.call(g,c)})).add(re.events.empty$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onEmpty)==null?void 0:g.call(c)})).add(re.events.clicked$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onClicked)==null?void 0:M.call(g,c)})).add(re.events.closed$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onClosed)==null?void 0:M.call(g,c)})).add(re.events.error$.subscribe(c=>{var g,M;return(M=(g=s==null?void 0:s.adsInfo)==null?void 0:g.onError)==null?void 0:M.call(g,c)})).add(re.events.paused$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onPaused)==null?void 0:g.call(c)})).add(re.events.resumed$.subscribe(()=>{var c,g;return(g=(c=s==null?void 0:s.adsInfo)==null?void 0:c.onResumed)==null?void 0:g.call(c)}));let yt=new dt.Subscription,Ut=()=>{var tt,At,zt;let{debugLog:c}=ce,g,M="#9df7b7",ie="#efd169";if(c&&c!==!0){let{colors:Yt}=c;g=c.tag,M=(tt=Yt==null?void 0:Yt[0])!=null?tt:M,ie=(zt=(At=Yt==null?void 0:Yt[1])!=null?At:Yt==null?void 0:Yt[0])!=null?zt:ie}let Ie=g?`: ${g}`:"";yt.add(D.events.log$.subscribe(Yt=>{console.debug(`%c sdk${Ie} `,`background:${M};`,`sdk component: ${Yt.component}`,Yt.message)})).add(Xe.log$.subscribe(Yt=>{console.debug(`%c ui${Ie} `,`background:${ie};`,`ui component: ${Yt.component}.`,Yt.message)}))},z=()=>{yt.unsubscribe()},Vt=(c,g)=>{G.log("start camera manual rotation",{mx:c,my:g}),D.startCameraManualRotation(c,g)},ut=(c=!1)=>{G.log("stop camera manual rotation",{immediate:c}),D.stopCameraManualRotation(c)},yi=(c,g,M)=>{G.log("move camera focus px",{xpx:c,ypx:g,dt:M}),D.moveCameraFocusPX(c,g,M)},ti=()=>{D.holdCamera()},St=()=>{D.releaseCamera()},lt=Vr(D.info.position$.getValue(),c=>{let g,M,ie=()=>{let Ie=D.info.playbackState$.getValue(),tt=D.info.isLive$.getValue(),At=D.info.duration$.getValue(),zt=D.info.position$.getValue();if(Ie&&[gi.PlaybackState.PLAYING,gi.PlaybackState.PAUSED].includes(Ie)){let Yt=tt?zt-At:D.getExactTime();Yt!==M&&c(Yt),M=Yt}g=requestAnimationFrame(ie)};return ie(),()=>cancelAnimationFrame(g)}),Ui=si(D.info.playbackState$),Oi=si(D.info.isBuffering$),Rn=mi([Ui,Oi],([c,g])=>g?"buffering":c),On=si(D.info.currentBuffer$),Ii=si(D.info.isEnded$),eo=si(D.info.isLive$),Dn=ce.features.playbackRate?si(D.info.canChangePlaybackSpeed$):Vr(!1),wo=si(D.info.liveBufferTime$),wi=si(D.info.volume$),Bo=si(D.info.muted$),Ho=Bu(D.info.predefinedQualityLimitType$.pipe((0,dt.map)(c=>c===gi.PredefinedQualityLimits.TRAFFIC_SAVING)),D.info.predefinedQualityLimitType$.getValue()===gi.PredefinedQualityLimits.TRAFFIC_SAVING),yo=Bu(D.info.predefinedQualityLimitType$.pipe((0,dt.map)(c=>c===gi.PredefinedQualityLimits.HIGH_QUALITY)),D.info.predefinedQualityLimitType$.getValue()===gi.PredefinedQualityLimits.HIGH_QUALITY),hn=si(D.info.autoQualityLimitingAvailable$),as=si(D.info.availableQualities$),Nr=si(D.info.availableQualitiesFps$),ls=si(D.info.chromecastState$),Br=si(D.info.chromecastDeviceName$),tr=si(D.info.currentFormat$),ds=si(D.info.throughputEstimation$),Hr=si(D.info.videoBitrate$),sn=si(D.info.intrinsicVideoSize$),_n=si(D.info.duration$),$r=si(D.info.isAudioAvailable$),yr=()=>{ci&&clearTimeout(ci),ci=null},bn=mi([_n,eo],([c,g])=>g?-c:c),ir=mi([Ui],([c])=>c===gi.PlaybackState.PLAYING),xr=si(D.info.atLiveEdge$),or=si(D.info.atLiveDurationEdge$),nr=si(D.info.position$),cs=mi([nr,_n],([c,g])=>isFinite(c)&&isFinite(g)&&!!g),So=mi([ls],([c])=>c===gi.ChromecastState.CONNECTED),wr=si(D.info.availableVideoStreams$),zi=ce.features.audioLanguages?si(D.info.availableAudioStreams$):Vr([]),Sr=si(D.info.currentVideoStream$),Nn=si(D.info.currentAudioStream$),_t=c=>{c.language&&om(c.language),D.setVideoStream(c)},ii=(c,g)=>{D.setAudioStream(c),zo(g)&&(c.language&&om(c.language),ce.features.userVideoPrefs&&t&&sm(ce.userSalt,String(t),{audioTrackId:c.id}))},Cr=c=>{let g;if(c.length===1&&(g=c.at(0)),g!=null||(g=c.find(ie=>"isDefault"in ie&&ie.isDefault)),ce.features.userVideoPrefs&&t){let ie=Wu(ce.userSalt,String(t));if(ie!=null&&ie.audioTrackId){let Ie=c.find(tt=>tt.id===ie.audioTrackId);g=Ie!=null?Ie:g}}let M=W_();return M&&(g!=null||(g=c.find(({language:ie})=>M===ie))),g!=null||(g=c.at(0)),g},Fr=c=>{G.log("change audio stream",{id:c});let g=D.info.availableAudioStreams$.getValue().find(M=>M.id===c);g&&ii(g,!0)},Ur=!1;we.add(D.info.availableAudioStreams$.subscribe(c=>{if(!Ur&&c.length){let g=Cr(c);g&&(D.setAudioStream(g),Ur=!0)}})),zi.subscribe(c=>{var g;(g=s==null?void 0:s.onAvailableAudioStreamsChanged)==null||g.call(s,c.map(({label:M="",id:ie="",language:Ie=""})=>({label:M,language:Ie,id:ie})))}),Nn.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onAudioStreamChanged)==null?void 0:g.call(s,c.id))});let Bn=!1;we.add(D.info.availableVideoStreams$.subscribe(c=>{if(!Bn&&c.length){let g=Cr(c);g&&(D.setVideoStream(g),Bn=!0)}}));let Hn=ae(void 0),Fo=si(D.info.isAutoQualityEnabled$,c=>c&&Hn.set(void 0)),Fn=si(D.info.currentQuality$,()=>Hn.set(void 0)),rr=mi([Hn,Fn],([c,g])=>c!=null?c:g),an=mi(tr,c=>c!==gi.VideoFormat.MPEG),$n=mi([as,Nr,Fo,rr,an],([c,g,M,ie,Ie])=>{let tt=[];Ie&&tt.push({value:"auto",displayValue:ve("auto_quality_option"),selected:M});let At=c.filter(zt=>!(0,dt.isInvariantQuality)(zt));for(let zt of At){let Yt=g[zt];tt.push({value:zt,displayValue:`${zt}${Yt?Lb(Yt):""}`,selected:M?!1:zt===ie})}return tt}),sr=si(D.info.currentPlaybackRate$),yn=mi([sr,xr,or],([c,g,M])=>{let ie=M||x?1:ce.controls.playbackRateMin,Ie=g?1:ce.controls.playbackRateMax,tt=ce.controls.playbackRateStep,At=[];for(let zt=ie;zt<=Ie;zt+=tt)At.push({value:zt,displayValue:zt===1?ve("playback_rate_1"):ve("playback_rate",{multiplier:zt.toString(10)}),selected:c===zt});return At}),ln=()=>({displayValue:ve("subtitles_off"),value:Vn,language:""}),Di=ae(ln()),uo=mi([Di,Se],([c],g)=>{c.value===Vn?g(ln()):g(c)}),dn=ce.features.subtitles?si(D.info.availableTextTracks$):Vr([]),ar=L_(),Tr=mi([dn,uo],([c,g],M)=>{var tt;let ie=[],Ie=c.find(({id:At})=>At===g.value);if(Ie!=null&&Ie.url){let[,At]=(tt=ar.find(Ie.url))!=null?tt:[];if(At){M(At);return}Pe.download(Ie.url).then(zt=>{if(!zt||Pe.isDestroyed())return;let Yt=new Mb,Js=Ie.language;if(Js){let z$=!!Ie.isAuto,W$=Yt.parse(zt,Js);ie.push({lang:Js,subtitles:W$,isAuto:z$,id:Ie.id})}ar.add(Ie.url,ie),be(uo).value===g.value&&M(ie)}).catch(zt=>{var Yt;(Yt=Z==null?void 0:Z.oneStat)==null||Yt.logError({errorType:"Subtitles download",fatal:!1}),pe==null||pe.report(zt,{errorType:"Subtitles download",fatal:!1})})}M(ie)}),xn=mi([sr,ir,uo],([c,g,M],ie)=>{let At;if(D.info.isLive$.getValue()&&g&&M.value!==Vn){let Yt=()=>{let Js=1e3/(3*c);At=setTimeout(Yt,Js),ie(Date.now())};return Yt(),()=>clearTimeout(At)}}),lr=mi([dn,uo],([c,g])=>{if(!c.length)return[];let M=[];for(let{language:ie,isAuto:Ie,id:tt}of c){let At=ie&&hc(ie);ie&&At&&M.push({displayValue:Ie?ve("subtitles_auto",{language:At}):At,value:tt,selected:(g==null?void 0:g.value)===tt,isAuto:Ie,language:ie})}return M.length?(M.unshift(Gt(Ve({},ln()),{selected:(g==null?void 0:g.value)===Vn})),M):[]}),je={available:[],prev:[]},_i=()=>{var g,M;let c=D.experimental.getCurrentTime$.getValue();return(M=(g=c==null?void 0:c())!=null?g:xe==null?void 0:xe.currentTime)!=null?M:0},Uo=mi([lt,uo,Tr,xn],([c,g,M,ie])=>{var tt;let Ie=D.info.isLive$.getValue();if(Ie&&je.prev!==M){let At=M.find(({id:Yt})=>Yt===g.value),zt=je.prev.find(({id:Yt})=>Yt===g.value);if(At){let Yt=Gt(Ve({},At),{subtitles:[...(tt=zt==null?void 0:zt.subtitles)!=null?tt:[],...At.subtitles]});je.available=[Yt],je.prev=M}}if(g&&g.value!==Vn){let At=Ie?_i():c,zt=Ie?je.available:M;return Ob(At,g,zt,Ie)}}),wn=mi([Uo],([c])=>c!=null&&c.texts?c.texts:[]);we.add(uo.subscribe(c=>{var g,M;if(c.value===Vn)(g=s==null?void 0:s.onSubtitleOff)==null||g.call(s);else{let ie=Object.entries(fp).find(([Ie,tt])=>tt===c.displayValue);(M=s==null?void 0:s.onSubtitleOn)==null||M.call(s,ie?ie[0]:"",c.value)}}));let Co=ae(!0),cn=mi([On,bn,nr,wo],([c,g,M,ie])=>{var zt;let Ie=(zt=c==null?void 0:c.end)!=null?zt:0;if(!ie)return Ie/g;let At=-M+ie-g;return(Ie-At)/g}),po=si(D.info.availableSources$),To=mi([po],([c])=>Object.keys((c==null?void 0:c[gi.VideoFormat.MPEG])||{}).length>0),ki=()=>{var M,ie,Ie;let c=Object.keys(((ie=(M=D.info.availableSources$)==null?void 0:M.getValue())==null?void 0:ie[gi.VideoFormat.MPEG])||{}),g=(0,dt.getHighestQuality)(c)||dt.VideoQuality.Q_144P;return(Ie=ke.sources[gi.VideoFormat.MPEG])==null?void 0:Ie[g]},zr=()=>{var g;let c=ki();if(c)G.log("download video",{url:c}),P_(c,((g=ke==null?void 0:ke.meta)==null?void 0:g.title)||"video");else{let M="There is no URL for download video";G.log("download video",{message:M}),de({message:M})}},Un=()=>{de({message:"toggle muted"});let c=D.info.muted$.getValue();D.info.volume$.getValue()===0&&!c?Wr(Ir(),!1):un(!c,!1)},ws=()=>{var c;if(Qt.ui.settingsMenu.visible$.set(!1),!be(Qt.ui.settingsSubMenu.visible$)){let g=be(Qt.ui.settingsMenu.ref$);if((c=s==null?void 0:s.uiInfo)!=null&&c.onSettingsMenu&&g){let ie=ed(g),Ie={top:0,left:0,bottom:0,right:0};s.uiInfo.onSettingsMenu({visible:!1,size:ie,position:Ie,name:"settings"})}}G.log("close settings menu")},Wi=(c,g=()=>Promise.resolve())=>bt(null,null,function*(){var Ie;Qt.ui.settingsMenu.openedByBtnKeyboard$.set(!!c),Qt.ui.settingsMenu.visible$.set(!0),yield g();let M=be(Qt.ui.settingsMenu.ref$),ie=Ca();if((Ie=s==null?void 0:s.uiInfo)!=null&&Ie.onSettingsMenu&&M&&ie){let At=ed(M),zt=zs(M,ie);s.uiInfo.onSettingsMenu({visible:!0,size:At,position:zt,name:"settings"})}G.log("open settings menu",{wasOpenedByKeyboard:c})}),Ss=(c,g=!1)=>{var tt;Qt.ui.settingsSubMenu.visible$.set(!1);let M=be(Qt.ui.settingsMenu.ref$),ie=Ca(),Ie=be(Qt.ui.settingsMenu.visible$);if((tt=s==null?void 0:s.uiInfo)!=null&&tt.onSettingsMenu&&M&&ie)if(Ie&&!g){let zt=ed(M),Yt=zs(M,ie);s.uiInfo.onSettingsMenu({visible:!0,size:zt,position:Yt,name:"settings"})}else{let zt=ed(c),Yt={top:0,left:0,bottom:0,right:0},Js=be(Qt.ui.settingsSubMenu.name$);s.uiInfo.onSettingsMenu({visible:!1,size:zt,position:Yt,name:Js})}G.log("close settings sub menu")},us=(c,g)=>{var ie;Qt.ui.settingsSubMenu.visible$.set(!0),Qt.ui.settingsSubMenu.ref$.set(g),Qt.ui.settingsSubMenu.name$.set(c);let M=Ca();if((ie=s==null?void 0:s.uiInfo)!=null&&ie.onSettingsMenu&&g&&M){let tt=ed(g),At=zs(g,M);s.uiInfo.onSettingsMenu({visible:!0,name:c,size:tt,position:At})}G.log("open settings sub menu",{name:c})},Ir=()=>{var g;let c=Math.max(ce.volumeMinRestore,(g=Hu())!=null?g:0);return c===0?ce.volumeDefault:c},zo=c=>{let g=ce.features.savePreferredStatesOnUserActionOnly;return!g||g&&!c},Wr=(c,g)=>{let M=c===0?Ir():c,ie=D.info.muted$.getValue();de({message:`set volume, volume: ${c}, preferredVolume: ${M}`});let Ie=!l||qe.is("ads");ie&&c>0&&Ie&&(ie=!1,zo(g)&&tm(!1)),D.setVolume(c,ie),re.setVolume(c),zo(g)&&Xf(M)},un=(c,g)=>{let M=D.info.volume$.getValue();de({message:`set muted, currentVolume: ${M}, mute: ${c}`});let ie=qe.is("ads");if(D.setMuted(c,ie),re.setVolume(c?0:M),zo(g)&&(!ie||!c)&&tm(c),!c&&M===0){let Ie=Ir();D.setVolume(Ie),zo(g)&&Xf(Ie),re.setVolume(Ie)}},Mi=ae(!1),We=c=>{var g,M;G.log("set looped",{isLooped:c}),Mi.set(c),D.setLooped(c),(M=(g=s==null?void 0:s.uiInfo)==null?void 0:g.onLoopedChanged)==null||M.call(g,c)};We(ne);let Rt=()=>{var c,g;(g=(c=s==null?void 0:s.uiInfo)==null?void 0:c.onReportProblem)==null||g.call(c)},fi=(c,g=!1)=>{var M;de({message:`set autoplayNextEnabled, value: ${c}`}),G.log("set autoplay next enabled",{autoplayNextEnabled:c}),Qt.ui.autoplayNextEnabled$.set(c),Q_(c),g&&((M=s==null?void 0:s.onSetAutoplayNextEnabled)==null||M.call(s,c))},Wo=c=>{de({message:`set timerNextVideoRunning, value: ${c}`}),G.log("set timer next video running",{timerNextVideoRunning:c}),Qt.ui.timerNextVideoRunning$.set(c)},Io=(c=!0)=>{var M;let g=!0;if(c&&(s!=null&&s.onPrevVideoClick))try{g=(M=s==null?void 0:s.onPrevVideoClick)==null?void 0:M.call(s)}catch(ie){de({message:"onPrevVideoClick callback failed to execute"})}j(!0),g&&X()},Eo=(c=!0)=>{var M;let g=!0;if(c&&(s!=null&&s.onNextVideoClick))try{g=(M=s==null?void 0:s.onNextVideoClick)==null?void 0:M.call(s)}catch(ie){de({message:"onNextVideoClick callback failed to execute"})}j(!1),g&&se()},Ki=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementShow)==null||c.call(s)},Ko=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementClick)==null||c.call(s)},zn=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementAuto)==null||c.call(s)},Er=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementCancel)==null||c.call(s)},Po=()=>{D.prepare()},fo=()=>{(0,dt.assertNonNullable)(Qt);let c=be(Qt.ui.controls.disabledControls$),g=be(Qt.playerPhase),M={playerPhase:g,isInteractive:x,isVideoEnded:!1,action:"none"};if(c.has("PLAY_BUTTON"))return;if(de({message:"toggle play"}),g==="ads"){M.action="play",G.log("toggle adman play",M),re.togglePlay();return}let ie=()=>{var tt;de({message:"toggle play, call player.play"}),M.action="play",D.play(),(tt=s==null?void 0:s.onPlay)==null||tt.call(s)},Ie=()=>{var tt;de({message:"toggle play, call player.pause"}),M.action="pause",D.pause(),(tt=s==null?void 0:s.onPause)==null||tt.call(s)};if(D.info.isEnded$.getValue()){if(de({message:"toggle play, video ended, seek to 0"}),Ji.next(),ft.next(Dr.SeekAction.REWIND),x){R==null||R();return}D.seekTime(0),ie()}else D.info.playbackState$.getValue()!==gi.PlaybackState.PLAYING?ie():Ie();G.log("toggle play",M)},Sn=(c,{changeReason:g="default",appliesTo:M="to-video",byUser:ie=!1}={},Ie)=>{de({message:`set quality, quality: ${c}`}),G.log("set quality",{quality:c}),ie&&Pi.next(c),D.setAutoQuality(c==="auto");let{qualityDetailsSubMenuEnabled:tt}=ce.features;Fu(),c!=="auto"?(tt?(Uu({type:"exact_quality",quality:c,videoId:t},M),D.setPredefinedQualityLimits(gi.PredefinedQualityLimits.UNKNOWN)):Zf(t,c),Hn.set(c),D.setQuality(c)):tt&&g==="default"&&(qr("auto_quality",M,Ie),be(Ho)&&qo(!1,void 0,Ie),be(yo)&&Wn(!1,void 0,Ie))},qo=(c,g="as-default",M)=>{de({message:`set trafficSavingEnabled, value: ${c}`}),G.log("set traffic saving enabled",{trafficSavingEnabled:c});let ie=c?gi.PredefinedQualityLimits.TRAFFIC_SAVING:gi.PredefinedQualityLimits.UNKNOWN;ce.features.qualityDetailsSubMenuEnabled?(Kr(ie,g,M),jd(!1)):(D.setPredefinedQualityLimits(ie),zo(M)&&jd(c))},Wn=(c,g="as-default",M)=>{de({message:`set highQualityEnabled, value: ${c}`}),G.log("set high quality enabled",{highQualityEnabled:c}),Kr(c?gi.PredefinedQualityLimits.HIGH_QUALITY:gi.PredefinedQualityLimits.UNKNOWN,g,M)},Kr=(c,g,M)=>{c!==gi.PredefinedQualityLimits.UNKNOWN&&(be(hn)&&!be(Fo)&&Sn("auto",{appliesTo:g,changeReason:"limit-changed"},M),qr(c,g,M)),D.setPredefinedQualityLimits(c)},qr=(c,g,M)=>{zo(M)&&(Uu({type:c,videoId:t},g),g==="as-default"&&Uu({type:c,videoId:t},"to-video"))},Kn=(c,g=!0)=>{G.log("set playback rate",{playbackRate:c}),D.setPlaybackRate(c),ce.features.saveRate&&Te&&!D.info.isLive$.getValue()&&g&&K_(c)},ot=()=>{let c=be(Dn),g=be(yn),M=g.findIndex(({selected:Ie})=>Ie);if(M===g.length-1||!c)return g[M];let ie=g[M+1];return Kn(ie.value),ie},Zt=()=>{let c=be(Dn),g=be(yn),M=g.findIndex(({selected:Ie})=>Ie);if(M===0||!c)return g[M];let ie=g[M-1];return Kn(ie.value),ie},Si=(c=Gt(Ve({},ln()),{selected:!1}),g)=>{G.log("set subtitles",Ve({},c)),c.value!==Vn&&Ht.next(c.isAuto?c.value+"_auto":c.value),st.next({enabled:c.value!==Vn,lang:c.language,auto:!!c.isAuto}),Di.set(c),zo(g)&&(rm(c.value===Vn?void 0:c.language),ce.features.userVideoPrefs&&t&&sm(ce.userSalt,String(t),{subtitleTrackId:c.value===Vn?void 0:c.value}))},ko=c=>{G.log("toggle subtitles");let g=be(uo);(g==null?void 0:g.value)===Vn?qn(c):Qo(c)},Cn=(c,g)=>{G.log("change subtitle",{enabled:c}),c?qn(!0,g):Qo(!0)},qn=(c,g)=>{G.log("subtitle on");let M=be(lr),ie=be(Ue),Ie=Ne!=null?Ne:ie,tt;g&&(tt=M.find(At=>At.value===g)),tt!=null||(tt=M.filter(At=>At.value!==Vn).find(At=>At.language===Ie)),Si(tt!=null?tt:M[1],c)},Qo=c=>{G.log("subtitle off"),Si(void 0,c)};we.add(D.info.availableTextTracks$.subscribe(c=>{var M;function g(){let ie=[];for(let{language:Ie,isAuto:tt,id:At}of c){let zt=Ie&&hc(Ie);Ie&&zt&&ie.push({id:At,language:Ie,title:tt?ve("subtitles_auto",{language:zt}):zt})}return ie}(M=s==null?void 0:s.onAvailableSubtitlesChanged)==null||M.call(s,g())}));let dr=ae(!0),ps=c=>{dr.set(c)},Pr=(c,g,M=!0)=>{var ie;if(de({message:`seek to time, time: ${c}`}),G.log("seek to time",{time:c,action:g,forcePrecise:M}),ft.next(g),D.info.isLive$.getValue()){let Ie=D.info.duration$.getValue(),tt=Math.min(0,Ie+c);D.seekTime(tt,M)}else{if(C!=null&&C.getValue())return;D.info.isEnded$.getValue()&&(de({message:"seek after ended, call callbacks.onPlay"}),(ie=s==null?void 0:s.onPlay)==null||ie.call(s)),D.seekTime(wg(c),M)}},Cs=c=>{de({message:`seek to episode start time: ${c}`}),G.log("seek to episode start time",{time:c}),Pr(c,Dr.SeekAction.EPISODE,!0)},Ys=(c,g,M=!1)=>{de({message:`seek to percent, percent: ${c}`}),G.log("seek to percent",{percent:c,action:g});let ie=be(bn)*c;Pr(ie,g,M)},xa=c=>{de({message:`seek external, time: ${c}`}),G.log("seek external",{time:c}),ft.next(Dr.SeekAction.UNKNOWN),D.seekTime(D.info.isLive$.getValue()?-c:c)},mt=c=>{var ie,Ie;let g=(ie=c.max)!=null?ie:"none",M=(Ie=c.min)!=null?Ie:"none";de({message:`set auto quality limitation. Max: ${g}. Min: ${M}`}),G.log("set auto quality limits",{max:g,min:M}),D.setAutoQualityLimits(c)},ai=c=>{de({message:`seek external to episode start time: ${c}`}),G.log("seek external to episode start time",{time:c}),Pr(c,Dr.SeekAction.EPISODE,!0)},Ao=c=>{de({message:`set playback rate to: ${c}`}),G.log("set playback rate external",{playbackRate:c}),D.setPlaybackRate(c)},Ci=ae(!1),to=ae(!1),Ts=mi([bn],([c])=>!!p&&c>=ce.suitableDurationForUsingRichSeek&&ce.features.useRichSeek&&!x&&te!=="preview"),Is=((p==null?void 0:p.frameWidth)||0)>=((p==null?void 0:p.frameHeight)||0),Es=mi([Ft],([c])=>{let g=td(c);return Is?!g:g});we.add(qe.subscribe(c=>{c!=="video"&&Ci.set(!1)})),Ci.subscribe(c=>{var g;(g=s==null?void 0:s.onRichSeekActiveChanged)==null||g.call(s,c)});let qi=ae(void 0),Ai=ae(!1),he=c=>{de({message:`start scrubbing, progress: ${c}`}),G.log("start scrubbing",{progress:c}),Ai.set(!0),Ct(c)},Ct=c=>{qi.set(c)},Jt,oi,Go=()=>{qi.set(void 0),Ai.set(!1)},mo=()=>{clearTimeout(oi),clearTimeout(Jt),Jt=window.setTimeout(()=>{Go()},500),xe==null||xe.removeEventListener("seeked",mo)},io=(c,g=!1,M=Dr.ThinOneStat.ActionSeekType.SLIDER)=>{de({message:`complete scrubbing, progress: ${c}`}),G.log("complete scrubbing",{progress:c}),Ys(c,M,g),be(Qt.ui.isMobile)&&be(Qt.state.currentFormat$)===gi.VideoFormat.HLS?(xe==null||xe.addEventListener("seeked",mo),oi=window.setTimeout(()=>{mo()},300)):Go()},Qn=mi([lt,bn,qi],([c,g,M],ie)=>{ie((0,dt.isNonNullable)(M)?M*g:c)}),Qr=ae(!1),Ps=()=>{Qr.set(!0)},ml=()=>{Qr.set(!1)},Gr=mi([di],([{width:c}],g)=>{let M=Tb(c);g(M)}),fs=W.filter(c=>k_(c)),js=mi([Gr,Pt],([c,g])=>g?fs.filter(M=>!M.hideOnMobile):fs.filter(M=>{var ie;return!((ie=M.hideOnDesktopGridTypes)!=null&&ie.includes(c))})),cr=ae(W.filter(c=>A_(c))),vd=mi([cr,Gr],([c,g])=>c.filter(M=>{var ie;return!((ie=M.hideOnDesktopGridTypes)!=null&&ie.includes(g))})),vl=mi([vd,js],([c,g])=>[...ce.features.additionalButtonsDesktopControlPanelRight?c.filter(M=>M.type==="desktop-control-panel-right"):[],...ce.features.additionalButtons?g.map((M,ie)=>{var Ie;return{id:ie,weight:ie,type:"desktop-control-panel-right",testId:M.testId,icon:M.iconUrl,onClick:M.onClick,ariaLabel:(Ie=M.ariaLabel)!=null?Ie:M.tooltip,tooltipText:M.tooltip}}):[]].filter(M=>!v.disabledAdditionalButtonIds.includes(M.id))),Yr=ae(F),wa=mi([Yr],([c])=>ce.features.additionalSettingsMenuItems?c.map(g=>g.type==="SWITCH"?Gt(Ve({},g),{onClick:g.onChangeEnabled}):g):[]),gd=(c,g)=>{let M=be(cr).map(ie=>ie.id!==c?ie:Ve(Ve({},ie),g));cr.set(M)},gl=c=>{let g=be(cr);if(g.some(M=>M.id===c.id)){de({message:`Additional button with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),cr.set(g)},hl=c=>{let g=be(cr);if(!g.some(M=>M.id===c)){de({message:`Can't find additional button with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),cr.set(g)},Sa=c=>{ft.next(Dr.SeekAction.LIVE),de({message:"live switch to low latency "+c}),G.log("live switch to low latency "+c),D.setLiveLowLatency(c)},gt=(c,g)=>{let M=be(Yr).map(ie=>ie.id!==c?ie:Ve(Ve({},ie),g));Yr.set(M)},ht=c=>{let g=be(Yr);if(g.some(M=>M.id===c.id)){de({message:`Settings menu item with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),Yr.set(g)},oo=c=>{let g=be(Yr);if(!g.some(M=>M.id===c)){de({message:`Can't find settings menu item with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),Yr.set(g)},Vi=ae(U),no=mi([Vi],([c])=>ce.features.additionalContextMenuItems?c:[]),bi=(c,g)=>{let M=be(Vi).map(ie=>ie.id!==c?ie:Ve(Ve({},ie),g));Vi.set(M)},Qi=c=>{let g=be(Vi);if(g.some(M=>M.id===c.id)){de({message:`Context menu item with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),Vi.set(g)},Xs=c=>{let g=be(Vi);if(!g.some(M=>M.id===c)){de({message:`Can't find context menu item with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),Vi.set(g)},hd=mi([Pt,Me],([c,g],M)=>{M(c&&g)}),jc=()=>{ft.next(Dr.SeekAction.LIVE),de({message:"switch to active live"}),G.log("switch to active live"),D.seekTime(0),D.info.playbackState$.getValue()!==gi.PlaybackState.PLAYING&&Qt.actions.internal.togglePlay()},Wp=()=>{G.log("skip adman"),re.skip()},Xc=(c=!0)=>{var ie;(0,dt.assertNonNullable)(Qt),de({message:`switch from ads to video, callPlay: ${c}`}),G.log("switch from ads to video",{callPlay:c}),Be.set("video"),c&&D.play(),l&&un(!0,!0);let g=(ie=be(ct))==null?void 0:ie.muted,M=!D.info.muted$.getValue();g!==void 0&&!M&&un(g,!0),ct.set(void 0)},Kp=()=>{(0,dt.assertNonNullable)(Qt),de({message:"switch from video to ads"}),G.log("switch from video to ads"),Qt.actions.internal.pause(),No(),Be.set("ads")},Zc=c=>{(0,dt.assertNonNullable)(Qt);let g=c?"LiveWaitingStart":"thumb";G.log("set live waiting start",{state:c,playerPhase:g}),Be.set(g)},qp=c=>{(0,dt.assertNonNullable)(Qt);let g=c?"LiveWaitingRecover":"thumb";G.log("set live waiting recover",{state:c,playerPhase:g}),Be.set(g)},Jc=c=>{(0,dt.assertNonNullable)(Qt);let g=c?"LiveWaitingRecord":"thumb";G.log("set live waiting record",{state:c,playerPhase:g}),Be.set(g)},Qp=()=>((0,dt.assertNonNullable)(Qt),G.log("get debug text data"),I_(D,ke,Qt,Ye.getTraceId(),Ce)),eu=()=>((0,dt.assertNonNullable)(Qt),JSON.stringify(Ye.getFinishedSpans())),Gp=()=>((0,dt.assertNonNullable)(Qt),E_(D,ke,Qt)),Ca=()=>xe,tu=()=>{de({message:"toggle chromecast"}),G.log("toggle chromecast"),D.toggleChromecast()},Zs=c=>{var M;if((0,dt.assertNonNullable)(Qt),D.info.isEnded$.getValue())return;let g=!c;if(be(Qt.playerPhase)==="ads"){de({message:`pause ads, internalCall: ${g}`}),G.log("pause ads",{internalCall:g}),re.pause();return}de({message:`pause video, internalCall: ${g}`}),G.log("pause video",{internalCall:g}),g&&((M=s==null?void 0:s.onPause)==null||M.call(s)),D.pause()},_l=c=>{var M;(0,dt.assertNonNullable)(Qt);let g=!c;if(be(Qt.playerPhase)==="ads"){de({message:`play ads, internalCall: ${g}`}),G.log("play ads",{internalCall:g}),re.play();return}de({message:`play video, internalCall: ${g}`}),G.log("play video",{internalCall:g}),g&&((M=s==null?void 0:s.onPlay)==null||M.call(s)),D.play()},iu=c=>{(0,dt.assertNonNullable)(Qt);let g=!c;if(be(Qt.playerPhase)==="ads"){de({message:"player cannot be stopped during ads via external method"});return}de({message:`player will be stopped, internalCall: ${g}`}),A==null||A()},ou=(c,g)=>{(0,dt.assertNonNullable)(Qt),de({message:`first start, show ads: ${c}, internalCall: ${!g}`}),G.log("first start",{showAds:c,external:g}),c?Be.set("ads"):(Be.set("video"),g?D.play():Qt.actions.internal.togglePlay())},bl=()=>(de({message:"getting time codes"}),m),nu=()=>{let c=bl();if(!c||[0,1].includes(c.length))return;let g=D.info.position$.getValue();return c.find(M=>M.time>g)},Yp=c=>{let g=c;g||(g=nu());let M=D.info.position$.getValue();G.log("seek to next episode",Ve({currentTime:M},g)),g&&(de({message:"seek to next episode"}),Pr(g.time,Dr.SeekAction.EPISODE,!0))},ru=()=>{let c=bl();if(!c||[0,1].includes(c.length))return;let g=D.info.position$.getValue(),M=c.findIndex(Ie=>Ie.time>g),ie=M===-1?c.length-2:M-2;if(!(ie<0))return c[ie]},Ke=c=>{let g=c;g||(g=ru());let M=D.info.position$.getValue();G.log("seek to prev episode",Ve({currentTime:M},g)),g&&(de({message:"seek to prev episode"}),Pr(g.time,Dr.SeekAction.EPISODE,!0))},$i=()=>(de({message:"getting preview thumbs data"}),G.log("get preview thumbs data",Ve({},p)),p),Yo=()=>bt(null,null,function*(){let c=ue==null?void 0:ue.isActive(),g="none";ue!=null&&ue.isActive()?(g="exit",yield ue==null?void 0:ue.exit()):(g="request",yield ue==null?void 0:ue.request()),G.log("toggle picture in picture",{isActive:c,action:g})}),kr=(c=-90)=>{G.log("rotate video",{alphaDiff:c}),Ft.update(g=>g+c)},Lo=ae([]);I==null||I.subscribe(c=>{let g=[];for(let M=0;M<c.length;M++){let{range:[ie,Ie],subjects:tt}=c[M];M===0&&ie!==0&&g.push({time:0,text:"",interactive:!1,completed:!0}),g.push({time:ie/1e3,text:"",interactive:!0,completed:ce.features.interactiveTimeOpenUri?!tt.length||tt.every(At=>At.isRemoved):!tt.length}),Ie!==1/0&&g.push({time:Ie/1e3,text:"",interactive:!1,completed:!0})}Lo.set(g)});let R$=ae(!1);C==null||C.subscribe(c=>{c&&be(Ai)&&Go()});let wg=c=>{if(!x)return c;let g=be(Lo),M=be(bn),Ie=be(nr)/M,tt=g.find(At=>At.interactive&&!At.completed&&At.time>Ie);return typeof(tt==null?void 0:tt.time)=="number"?Math.min(c,tt.time-.05):c},O$=()=>{Qt.ui.episodes.panelOpened$.set(!1)},D$=()=>{G.log("destroy store"),clearTimeout(oi),clearTimeout(Jt),we.unsubscribe(),yt.unsubscribe(),D.destroy(),re.destroy(),Z==null||Z.destroy(),pe==null||pe.destroy(),Le.unsubscribe(),hi==null||hi.disconnect(),hi=null,Pe.destroy()},N$=mi([xr,qe,Dn],([c,g,M])=>v.features.doubleForwardAvailable&&!c&&g==="video"&&M),jp=ae(!1),Sg=2,su=null,Cg=c=>{if(!be(ir)&&c)return;let g=D.info.currentPlaybackRate$.getValue();c?g!==Sg&&(su=g,Kn(Sg,!1),jp.set(!0)):(su&&Kn(su,!1),jp.set(!1),su=null)};qe.subscribe(c=>{c!=="video"&&Cg(!1)});let B$=()=>{Zs(!1),Ci.set(!0)},H$=()=>{_l(!1),Ci.set(!1)},Xp=!1,F$=()=>{to.set(!0),Xp=D.info.playbackState$.getValue()===gi.PlaybackState.PLAYING,Zs(!1)},U$=()=>{to.set(!1),!be(Ci)&&Xp&&_l(!1),Xp=!1};D.events.playing$.subscribe(()=>{be(Ci)&&Zs(!1)});let Qt={interfaceLanguage$:Ue,isCyrillicRelatedInterface$:Tt,initVideo:ui,videoId:t,isClip:o,playerPhase:qe,vsid:kt,state:{positionExact$:lt,positionWithScrubbing$:Qn,duration$:bn,playbackState$:Ui,playbackStateRealistic$:Rn,isPlaying$:ir,isLoaderVisible:bo,bufferedProgress$:cn,isLive$:eo,canChangePlaybackSpeed$:Dn,isActiveLive$:xr,isOldestAvailableLive$:or,isRewindableLive$:cs,isEnded$:Ii,muted$:Bo,volume$:wi,trafficSavingEnabled$:Ho,highQualityEnabled$:yo,autoQualityLimitingAvailable$:hn,availableVideoStreams$:wr,availableAudioStreams$:zi,videoStream$:Sr,audioStream$:Nn,currentQuality$:rr,isAutoQualityEnabled$:Fo,availableQualities$:$n,currentPlaybackRate$:sr,availablePlaybackRates$:yn,currentSubtitle$:uo,availableTextTracks$:dn,availableSubtitlesList$:lr,currentSubtitleCaptions$:wn,isAutoSubtitleCaptionVisible$:Co,chromecastState$:ls,chromecastDeviceName$:Br,chromecastConnected$:So,currentFormat$:tr,throughputEstimation$:ds,videoBitrate$:Hr,videoSize$:sn,errorLog$:q,crashed$:Me,isAudioAvailable$:$r,isAudioDisabled:!!l,canDownload:ce.features.download&&!!d,availableSources$:po,hasMpegSources$:To,isInteractive:x,showInteractiveGraph:ce.features.interactiveGraph,showSeekToInteractive:ce.features.seekToInteractive,showPlayPrevChapter:ce.features.interactivePlayPrevChapter,showInteractiveTimeIndicator:ce.features.interactiveTimeIndicator&&!!be(Lo).length,interactiveEpisodes$:Lo,isInteractiveTime$:C?si(C):ae(!1),isInteractiveExpectation$:R$,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,looped$:Mi,loadedMetadata$:Bt,isAutoQualityAvailable$:an,previewTrackActive:Ci,previewTrackDragInProgress:to},ui:{t:ve,controlsVisible:ae(!1),touched:ae(!1),controls:{prevButton:ae(void 0),playButton:ae(void 0),replayButton:ae(void 0),nextButton:ae(void 0),playPrevChapterButton:ae(void 0),seekToInteractiveButton:ae(void 0),interactiveGraphButton:ae(void 0),liveButton:ae(void 0),time:ae(void 0),episodes:ae(void 0),volume:ae(void 0),subtitles:ae(void 0),settings:ae(void 0),context:ae(void 0),chromecast:ae(void 0),pip:ae(void 0),"theater-mode-button":ae(void 0),fullscreen:ae(void 0),vkLogo:ae(void 0),interactiveTimeIndicator:ae(void 0),timeline:ae(void 0),autoplayNextToggle:ae(void 0),additionalButtons:W.length?W.reduce(c=>[...c,ae(void 0)],[]):[],disabledControls$:Mt},modals:{hotKeyMap:{show:ae(!1),data:ae({title:"",closeBtnText:"",groups:[]})}},isFullscreen:Lt,isFullscreenOpenedByKeyboard:pt,rotateAlpha:Ft,isAutoplay:ae(!1),debugPanelVisible:ae(!1),episodes:{panelOpened$:ae(!1),openedByKeyboard$:ae(!1)},contextMenu:{visible$:ae(!1),btnRef$:ae(void 0),openedByBtnKeyboard$:ae(!1),openedByHotKey$:ae(!1),lastActiveElem$:ae(void 0),showContextMenuBtn$:ae(!1),position$:ae({top:0,left:0})},playerSize:di,isMobile:Pt,mobileNotReportControlHidden$:hd,icon3DVideoVisible:ae(!1),scrubbingInProgress:Ai,volumeChangingInProgress:Qr,is3DVideo:qt,currentGridType$:Gr,additionalButtonsDeprecated$:js,additionalDesktopControlPanelRightButtons$:vl,additionalSettingsMenuItems$:wa,additionalContextMenuItems$:no,interactiveHideMobileControls:ae(!1),overlayContainer$:ae(void 0),startedByKeyboard$:ae(!1),autoplayNextEnabled$:ae(!1),timerNextVideoRunning$:ae(!0),settingsMenu:{visible$:ae(!1),ref$:ae(void 0),openedByBtnKeyboard$:ae(!1)},settingsSubMenu:{visible$:ae(!1),ref$:ae(void 0),name$:ae(void 0)},userActionsDisabled:ae(!1),hiddenControls:{volume:ae(!1),vkLogo:ae(!1),pip:ae(!1),chromecast:ae(!1),settings:ae(!1)},isControlsAvailable:dr,controlBlocks:{topLeft:ae(void 0),topRight:ae(void 0),middle:ae(void 0),bottom:ae(void 0),bottomLeft:ae(void 0),bottomRight:ae(void 0)},videoTitleInfo:ae(void 0),doubleForwardOn$:jp,doubleForwardAvailable$:N$,previewTrackActive:Ci,previewTrackDragInProgress:to,previewTrackAvailable:Ts,isPreviewTrackHorizontallyAligned:Es},ads:{position:ae(0),duration:ae(0),playbackState:ae("inactive"),canSkip:ae(!1),secondsToWatchBeforeSkip:ae(0),postrollPassed:ae(!1)},webApi:{pictureInPictureApi:ue,annotationsApi:Ae,slotsApi:ze,focusManager:ee},actions:{internal:{preload:Po,firstStart:c=>ou(c,!1),play:()=>_l(!1),pause:()=>Zs(!1),togglePlay:fo,toggleMuted:Un,openSettingsMenu:Wi,closeSettingsMenu:ws,openSettingsSubMenu:us,closeSettingsSubMenu:Ss,setVolume:c=>Wr(c,!1),setMuted:c=>un(c,!1),startVolumeChanging:Ps,stopVolumeChanging:ml,setVideoStream:_t,setAudioStream:c=>ii(c,!1),setQuality:(c,g)=>Sn(c,g,!1),setTrafficSavingEnabled:(c,g)=>qo(c,g,!1),setHighQualityEnabled:(c,g)=>Wn(c,g,!1),setPlaybackRate:Kn,incrementPlaybackRate:ot,decrementPlaybackRate:Zt,setSubtitle:c=>Si(c,!1),toggleSubtitle:()=>ko(!1),togglePictureInPicture:Yo,startScrubbing:he,progressScrubbing:Ct,completeScrubbing:io,toggleChromecast:tu,switchToActiveLive:jc,switchFromAdsToVideo:Xc,switchFromVideoToAds:Kp,skipAd:Wp,setLiveWaitingStart:Zc,setLiveWaitingRecover:qp,setLiveWaitingRecord:Jc,getDebugTextData:Qp,getTraceTextData:eu,getDebugPanelData:Gp,getVideoElement:Ca,seekTime:(c,g,M)=>Pr(c,g,M),clearDelayedBufferingCheckTimeout:yr,seekEpisodeStartTime:Cs,seekToPercent:Ys,getNextEpisode:nu,seekToNextEpisode:Yp,getPrevEpisode:ru,seekToPrevEpisode:Ke,startLogging:Ut,stopLogging:z,startCameraManualRotation:Vt,stopCameraManualRotation:ut,moveCameraFocusPX:yi,holdCamera:ti,releaseCamera:St,getVideoEpisodes:bl,getPreviewThumbsData:$i,downloadVideo:zr,addLanguage:am,setLanguage:ye,nextMovie:pi,videoRotate:kr,correctSeekTimeToInteractive:wg,replayInteractive:R,setLooped:We,reportProblem:Rt,setAutoplayNextEnabled:fi,setTimerNextVideoRunning:Wo,prevVideoClick:Io,nextVideoClick:Eo,nextVideoAnnouncementShow:Ki,nextVideoAnnouncementClick:Ko,nextVideoAnnouncementAuto:zn,nextVideoAnnouncementCancel:Er,checkFullscreenSupport:It,changeDoubleForwardOn:Cg,closePreviewTrack:H$,previewTrackOpened:B$,previewTrackDragStarted:F$,previewTrackDragFinished:U$},external:{firstStart:c=>ou(c,!0),play:()=>_l(!0),pause:()=>Zs(!0),stop:()=>iu(!0),seekTime:c=>xa(c),seekEpisodeStartTime:c=>ai(c),setPlaybackRate:c=>Ao(c),setAutoQualityLimits:c=>mt(c),setMuted:c=>un(c,!0),toggleSubtitle:()=>ko(!0),changeSubtitle:Cn,setVolume:c=>Wr(c,!0),returnFocusToEpisodes:O$,updateAdditionalSettingsItem:gt,addAdditionalSettingsItem:ht,removeAdditionalSettingsItem:oo,updateAdditionalContextItem:bi,addAdditionalContextItem:Qi,removeAdditionalContextItem:Xs,updateAdditionalButton:gd,addAdditionalButton:gl,removeAdditionalButton:hl,setLiveLowLatency:Sa,hideControls:()=>ps(!1),showControls:()=>ps(!0),setQuality:c=>Sn(c,{appliesTo:"to-video"},!0),setTrafficSavingEnabled:c=>qo(c,"to-video",!0),setHighQualityEnabled:c=>Wn(c,"to-video",!0),changeAudioStream:Fr}},callbacks:s,setUiCallbacks:c=>{Je=Ve({},c)},getAdmanWrapper:()=>re,getLogger:()=>Xe,getPlayer:()=>D,destroy:D$};return Qt};function Jn(i,e,t,o){var m;let r=(m=e[t])==null?void 0:m.getBoundingClientRect(),a=o&&!!r&&!!(r.right-r.left),{top:l,left:d,bottom:s,right:u}=zs(e[t],i||void 0);return{left:a?d:0,right:a?u:0,top:a?l:0,bottom:a?s:0,isDisplayed:a}}var c2=["disabledControls$","additionalButtons"],u2=["interactiveTimeIndicator"],od=(i,e,t,o)=>{if(i){for(let[r,a]of Object.entries(e))if(!c2.includes(r)){let l=o||u2.includes(r);a.set(Jn(i,t,r,l))}}};var hp=(i,e,t)=>bt(null,null,function*(){yield _o(),e&&t&&(t.focus(),i.set(!1))});var p2=Ee('<path d="M18 10c1.1 0 2 .9 2 2s-.9 2-2 2-2-.9-2-2 .9-2 2-2Zm-6 4c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2Zm-6 0c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2Z"></path>');function Jm(i){Ze(i,{children:(e,t)=>{var o=p2();$(e,o)},$$slots:{default:!0}})}function ev(i,e){B(e,!0);let[t,o]=He(),r=()=>w(s,"$contextMenuVisible$",t),a=h(e,"disabled",3,!1),l=h(e,"ariaLabel",3,""),d=$e(),s=d.ui.contextMenu.visible$,u=d.ui.contextMenu.openedByBtnKeyboard$,m=d.ui.contextMenu.showContextMenuBtn$,p=d.ui.contextMenu.position$,v=d.ui.contextMenu.btnRef$,b=K(void 0);Fe(()=>{n(b)&&Et(()=>{v.set(n(b))})});let y=C=>{let R=fa(C),A=hb(n(b));p.set(A),u.set(R),s.set(!r())},_=()=>{m.set(!0)},x=()=>{m.set(!1)},I=f(()=>r()?"opened":"");Kt(i,{get className(){return n(I)},testId:"btn-context-menu",get disabled(){return a()},get ariaLabel(){return l()},click:y,focus:_,blur:x,get ariaExpanded(){return r()},get ref(){return n(b)},set ref(C){O(b,C,!0)},children:(C,R)=>{Jm(C,{})},$$slots:{default:!0}}),H(),o()}var f2=i=>{i.stopPropagation()},m2=L("<div><!> <div></div> <div></div></div>"),v2={hash:"s-26",code:'.interactive-episode-icon-animated.s-26{height:32px;opacity:1;position:absolute;right:16px;top:16px;transition:.3s;width:32px}.interactive-episode-icon-animated.icon-small.s-26{height:28px;width:28px}.invisible.s-26{opacity:0;visibility:hidden}.fullscreen.s-26:not(.mobile){height:40px;right:23px;top:19px;width:40px}.mobile.s-26{height:28px;right:14px;top:12px;width:28px}.fullscreen.mobile.s-26{height:32px;width:32px}@media screen and (orientation:portrait){.interactive-episode-icon-animated.mobile.fullscreen.s-26{right:16px;top:40px}}@keyframes s-26-pulse{0%{border-width:1px;opacity:0;transform:scale(1)}10%{opacity:1}50%{border-width:1px;opacity:.5;transform:scale(1.5)}to{border-width:.5px;opacity:0;transform:scale(1.5)}}.pulse.s-26{animation:s-26-pulse 1s infinite;border:1px solid #fff;border-radius:100%;bottom:0;content:"";display:block;left:0;pointer-events:none;position:absolute;right:0;top:0;transform:scale(1.8);transition:.3s}.pulse.paused.s-26{animation-play-state:paused}.interactive-episode-icon-animated svg{height:100%;width:100%}.ref-block.s-26{height:100%;position:absolute;top:0;visibility:hidden;width:100%}.hidden.s-26{display:none}'};function $c(i,e){var re;B(e,!0),Q(i,v2);let[t,o]=He(),r=()=>w(x,"$isMobile",t),a=()=>w(A,"$areControlsVisible",t),l=()=>w(E,"$currentGridType$",t),d=()=>w(C,"$isInteractiveTime$",t),s=()=>w(_,"$interactiveControlsOpacity$",t),u=()=>w(R,"$showInteractiveTimeIndicatorTooltip$",t),m=()=>w(I,"$isFullscreen",t),p=h(e,"ref",15,void 0),v=K(void 0),b=$e(),y=xo(),{interactiveControlsOpacity$:_}=y,x=b.ui.isMobile,I=b.ui.isFullscreen,C=b.state.isInteractiveTime$,R=y.showInteractiveTimeIndicatorTooltip$,A=b.ui.controlsVisible,P=(re=b.callbacks)==null?void 0:re.onInteractiveTimeIndicatorClick,E=b.ui.currentGridType$,W=f(()=>!r()&&a()),F=f(()=>Fs(l(),"s")),U=f(()=>!d()||!!s()||n(W)),X=K(!1);Fe(()=>{O(X,n(U),!0)});let se=()=>{O(X,!0)},j=()=>{var pe;ne(),(pe=n(v))==null||pe.addEventListener("animationiteration",se,{once:!0})},ne=()=>{var pe;O(X,!1),(pe=n(v))==null||pe.removeEventListener("animationiteration",se)},Z=pe=>{R.set(pe)},Te=f(()=>u()&&!n(U));Fe(()=>{u()?j():ne()});let fe=()=>{n(U)||(R.set(!0),P==null||P())};mn(()=>{R.clearTimeout(),ne()});let te=()=>{R.set(!1)},_e=Y("tooltip_interactive_interaction_time_indicator");var Ce=m2();let me;Ce.__mousemove=[f2],Ce.__click=fe;var ce=T(Ce);Oo(ce,{get tooltipContent(){return _e},get tooltipVisible(){return n(Te)},initialTranslateYPx:72,tooltipPlacement:"bottom",onTooltipVisibilityChange:Z,get ref(){return p()},set ref(pe){p(pe)},children:(pe,ue)=>{cc(pe,{completed:!0})},$$slots:{default:!0}});var Ye=k(ce,2);let G;it(Ye,pe=>p(pe),()=>p());var D=k(Ye,2);let Xe;it(D,pe=>O(v,pe),()=>n(v)),S(Ce),N((pe,ue,Ae)=>{me=oe(Ce,1,"interactive-episode-icon-animated s-26",null,me,pe),G=oe(Ye,1,"ref-block s-26",null,G,ue),Xe=oe(D,1,"pulse s-26",null,Xe,Ae)},[()=>({mobile:r(),fullscreen:m(),invisible:n(U),"icon-small":n(F)}),()=>({hidden:n(U)}),()=>({paused:n(X)})]),vt("mouseleave",Ce,te),$(i,Ce),H(),o()}et(["mousemove","click"]);function _p(i,e){B(e,!0);let t=h(e,"tooltipEnabled",3,!0),o=h(e,"disabled",3,!1),r=h(e,"className",3,void 0),a=h(e,"ref",15),l=h(e,"tooltipVisible",3,!1);Oo(i,{get disabled(){return o()},get tooltipContent(){return e.tooltipText},get disabledTooltipContent(){return e.disabledTooltipContent},get hasTooltip(){return t()},get mouseEnter(){return e.mouseEnter},get mouseLeave(){return e.mouseLeave},get tooltipVisible(){return l()},get className(){return r()},get ref(){return a()},set ref(d){a(d)},children:(d,s)=>{var u=Oe();let m=f(()=>e.buttonComponent);var p=le(u);Hi(p,()=>n(m),(v,b)=>{b(v,is(()=>{var y;return(y=e.buttonComponentProps)!=null?y:{}}))}),$(d,u)},$$slots:{default:!0}}),H()}var Ws={prevButton:100,replayButton:200,playButton:300,nextButton:400,playPrevChapterButton:500,seekToInteractiveButton:600,interactiveGraphButton:700,liveButton:800};var h2=Ee('<path d="M32 21.68V15a2 2 90 114 0v18a2 2 90 01-4 0v-6.66l-16.3 9.32A2.48 2.48 90 0112 33.56V14.46c0-1.9 2.06-3.08 3.7-2.12z"></path>');function _a(i,e){B(e,!0);let t=h(e,"reversed",3,!1),o=f(()=>t()?"transform: scaleX(-1);transform-origin: 50%;":void 0),r=f(()=>`${vn(e.size)}${n(o)}`),a=f(()=>t()?"prev-icon":"next-icon");Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(r)},get testId(){return n(a)},get shadow(){return e.shadow},children:(l,d)=>{var s=h2();$(l,s)},$$slots:{default:!0}}),H()}var _2=L('<div class="icon-background-mobile s-25"><!></div>'),b2={hash:"s-25",code:".icon-background-mobile.s-25{align-items:center;background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);display:flex;height:100%;justify-content:space-around;left:0;position:absolute;top:0;width:100%}"};function el(i,e){B(e,!0),Q(i,b2);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"disabled",3,!1),l=$e().ui.t,d=f(()=>e.type==="prev"?l("tooltip_previous"):l("tooltip_next")),s=f(()=>e.type==="prev"?l("hotkey_map_item_prev_video_value"):l("hotkey_map_item_next_video_value")),u=f(()=>`btn-${o()?"m":"d"}--${e.type}`);Kt(i,{get className(){return n(u)},get testId(){var m;return`btn-${(m=e.type)!=null?m:""}`},get disabled(){return r()},get ariaLabel(){return n(d)},get click(){return e.click},get ariaKeyShortCut(){return n(s)},get ref(){return t()},set ref(m){t(m)},children:(m,p)=>{var v=Oe(),b=le(v);{var y=x=>{var I=_2(),C=T(I);let R=f(()=>e.type==="prev");_a(C,{get size(){return"32"},get reversed(){return n(R)}}),S(I),$(x,I)},_=x=>{let I=f(()=>e.type==="prev");_a(x,{get size(){return"24"},get reversed(){return n(I)}})};V(b,x=>{o()?x(y):x(_,!1)})}$(m,v)},$$slots:{default:!0}}),H()}var $2=Ee('<path d="M24 21.2a.8.8 90 01-1.34.6L14.08 14a1.34 1.34 90 010-2l8.6-7.8a.8.8 90 011.32.6V11a16 16 90 11-16 16 2 2 90 114 0 12 12 90 1012-12z"></path>');function yc(i,e){B(e,!0);let t=f(()=>vn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(t)},testId:"replay-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=$2();$(o,a)},$$slots:{default:!0}}),H()}var Ub=require("@vkontakte/videoplayer-shared/es2015");var y2=L('<div class="icon-background-mobile s-23"></div>'),x2=L("<!> <div><!></div>",1),w2={hash:"s-23",code:".mobile.s-23{align-items:center;display:flex;justify-content:center;position:relative}.icon-background-mobile.s-23{background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);height:calc(100% - 32px);left:16px;position:absolute;top:16px;width:calc(100% - 32px)}"};function nd(i,e){B(e,!0),Q(i,w2);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"disabled",3,!1),a=h(e,"className",3,""),l=h(e,"click",3,Ub.noop),d=Y("tooltip_restart"),s=f(()=>`${o()?"btn-m--play":""} ${a()}`);Kt(i,{get className(){return n(s)},testId:"replay-btn",get ariaLabel(){return d},get disabled(){return r()},get click(){return l()},get ariaKeyShortCut(){return $s.KeyK},get ref(){return t()},set ref(u){t(u)},children:(u,m)=>{var p=x2(),v=le(p);{var b=C=>{var R=y2();$(C,R)};V(v,C=>{o()&&C(b)})}var y=k(v,2);let _;var x=T(y);let I=f(()=>o()?"48":"24");yc(x,{get size(){return n(I)}}),S(y),N(C=>_=oe(y,1,"s-23",null,_,C),[()=>({mobile:o()})]),$(u,p)},$$slots:{default:!0}}),H()}var S2=Ee('<path d="m17.4 10 1.6.2a2 2 90 01.8.8l.2 1.6v22.8l-.2 1.6a2 2 90 01-.8.8l-1.6.2h-4l-1.4-.2a2 2 90 01-.8-.8l-.2-1.6V12.6l.2-1.6a2 2 90 01.8-.8l1.6-.2h3.801zm16 0 1.6.2a2 2 90 01.8.8l.2 1.6v22.8l-.2 1.6a2 2 90 01-.8.8l-1.6.2h-4l-1.4-.2a2 2 90 01-.8-.8l-.2-1.6V12.6l.2-1.6a2 2 90 01.8-.8l1.6-.2h4z"></path>');function Ks(i,e){B(e,!0);let t=f(()=>vn(e.size));Ze(i,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(t)},testId:"pause-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=S2();$(o,a)},$$slots:{default:!0}}),H()}var zb=require("@vkontakte/videoplayer-shared/es2015");var C2=L('<div class="icon-background-mobile s-21"><!></div>'),T2={hash:"s-21",code:".icon-background-mobile.s-21{align-items:center;background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);display:flex;height:calc(100% - 32px);justify-content:space-around;left:16px;position:absolute;top:16px;width:calc(100% - 32px)}"};function rd(i,e){B(e,!0),Q(i,T2);let[t,o]=He(),r=()=>w(a,"$fakeIsPlaying$",t),{fakeIsPlaying$:a}=xo(),l=h(e,"ref",15,void 0),d=h(e,"isMobile",3,!1),s=h(e,"isPlaying",3,!1),u=h(e,"disabled",3,!1),m=h(e,"className",3,""),p=h(e,"click",3,zb.noop),b=$e().ui.t,{toggle:y}=a,_=f(()=>y),x=f(()=>r()!==null),I=f(()=>n(x)?r():s()),C=f(()=>n(I)?b("tooltip_pause"):b("tooltip_play")),R=f(()=>n(I)?Ks:Ln),A=f(()=>`${d()?"btn-m--play":""} ${m()}`),P=f(()=>n(x)?n(_):p());Kt(i,{get className(){return n(A)},testId:"play-btn",get click(){return n(P)},get disabled(){return u()},get ariaLabel(){return n(C)},get ariaKeyShortCut(){return $s.KeyK},get ref(){return l()},set ref(E){l(E)},children:(E,W)=>{var F=Oe();let U=f(()=>n(R));var X=le(F);{var se=ne=>{var Z=C2(),Te=T(Z);Hi(Te,()=>n(U),(fe,te)=>{te(fe,{get size(){return"48"}})}),S(Z),$(ne,Z)},j=ne=>{var Z=Oe(),Te=le(Z);Hi(Te,()=>n(U),(fe,te)=>{te(fe,{get size(){return"24"}})}),$(ne,Z)};V(X,ne=>{d()?ne(se):ne(j,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}var I2=Ee('<path d="M12.58 12.92v2.5a1 1 0 0 1-1.52.85l-5.58-3.42a1 1 0 0 1 0-1.7l5.58-3.42a1 1 0 0 1 1.52.86v2.5l5.48-3.36a1 1 0 0 1 1.52.86v6.82a1 1 0 0 1-1.52.86z"></path>');function tv(i){Ze(i,{testId:"play-prev-chapter-icon",children:(e,t)=>{var o=I2();$(e,o)},$$slots:{default:!0}})}function xc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"hidden",3,!1),r=h(e,"disabled",3,!1),a=Y("tooltip_interactive_go_back"),l=f(()=>o()?"hidden":"");Kt(i,{get className(){return n(l)},testId:"play-prev-chapter-btn",get ariaLabel(){return a},get disabled(){return r()},get click(){return e.click},get ref(){return t()},set ref(d){t(d)},children:(d,s)=>{tv(d,{})},$$slots:{default:!0}}),H()}var E2=L('<span class="gutter s-24"><span><!></span></span>'),P2={hash:"s-24",code:".gutter.s-24{--gutterWidth:32px;--gutterHeight:12px;--togglerWidth:18px;--togglerHeight:18px;--togglerGap:calc(var(--togglerWidth)/6);background-color:hsla(0,0%,100%,.3);border-radius:50px;height:var(--gutterHeight);position:relative;width:var(--gutterWidth)}.toggler.s-24{align-items:center;background-color:#626364;border-radius:50%;display:flex;height:var(--togglerHeight);justify-content:center;left:0;position:absolute;top:calc((var(--togglerHeight) - var(--gutterHeight))/2*-1);transform:translateX(calc(var(--togglerGap)*-1));transition-duration:.2s;transition-property:background-color,transform;transition-timing-function:ease;width:var(--togglerWidth)}.toggler.enabled.s-24{background-color:var(--toggle-color-autoplay-on);transform:translateX(calc(var(--gutterWidth) - var(--togglerWidth) + var(--togglerGap)))}"};function wc(i,e){B(e,!0),Q(i,P2);let[t,o]=He(),r=()=>w(s,"$autoplayNextEnabled$",t),a=h(e,"ref",15,void 0),l=$e(),d=l.ui.t,s=l.ui.autoplayNextEnabled$,u=l.actions.internal.setAutoplayNextEnabled,m=()=>{u(!r(),!0)},p=d("aria_label_autoplay"),v="12",b="#000",y=f(()=>r()?"true":"false");Kt(i,{click:m,get ariaLabel(){return p},role:"switch",get areaChecked(){return n(y)},get ref(){return a()},set ref(_){a(_)},children:(_,x)=>{var I=E2(),C=T(I);let R;var A=T(C);{var P=W=>{Ln(W,{get size(){return v},fill:b})},E=W=>{Ks(W,{get size(){return v},fill:b})};V(A,W=>{r()?W(P):W(E,!1)})}S(C),S(I),N(W=>R=oe(C,1,"toggler s-24",null,R,W),[()=>({enabled:r()})]),$(_,I)},$$slots:{default:!0}}),H(),o()}var k2=Ee('<path d="M16.73 4.85c-.54-.05-1.23-.05-2.23-.05H7.9a.9.9 0 1 1 0-1.8h6.64q1.41-.01 2.33.05c.64.05 1.2.16 1.73.43a4.4 4.4 0 0 1 1.92 1.92c.27.52.38 1.09.43 1.73q.06.92.05 2.33v5.08q.01 1.41-.05 2.33a5 5 0 0 1-.43 1.73 4.4 4.4 0 0 1-1.92 1.92 5 5 0 0 1-1.73.43q-.92.06-2.33.05H7.9a.9.9 0 1 1 0-1.8h6.6c1 0 1.69 0 2.23-.04.52-.05.82-.13 1.05-.24a2.6 2.6 0 0 0 1.14-1.14c.11-.23.2-.53.24-1.06s.04-1.23.04-2.22v-5c0-1 0-1.69-.04-2.23a3 3 0 0 0-.24-1.05 2.6 2.6 0 0 0-1.14-1.14c-.23-.11-.53-.2-1.05-.24"></path><path d="M7.76 11.17V8.9c0-.71.7-1.15 1.25-.78l4.6 3.1a.96.96 0 0 1 0 1.54L9 15.87c-.55.37-1.25-.07-1.25-.78v-2.26l-4.5 3.04C2.7 16.24 2 15.8 2 15.09V8.91c0-.71.7-1.15 1.25-.78z "></path>',1);function iv(i){Ze(i,{testId:"seek-to-interactive-icon",children:(e,t)=>{var o=k2();ni(),$(e,o)},$$slots:{default:!0}})}function Sc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"hidden",3,!1),r=h(e,"disabled",3,!1),a=Y("tooltip_interactive_seek"),l=f(()=>o()?"hidden":"");Kt(i,{get className(){return n(l)},testId:"btn-seek-to-interactive",get ariaLabel(){return a},get disabled(){return r()},get click(){return e.click},get ref(){return t()},set ref(d){t(d)},children:(d,s)=>{iv(d,{})},$$slots:{default:!0}}),H()}var A2=Ee('<path d="M15.2 5.9v1.2c0 .6 0 .9.12 1.12q.15.3.46.46c.23.12.52.12 1.12.12h1.2c.6 0 .9 0 1.12-.12q.3-.15.46-.46c.12-.23.12-.52.12-1.12V5.9c0-.6 0-.9-.12-1.12a1 1 0 0 0-.46-.46c-.23-.12-.52-.12-1.12-.12h-1.2c-.6 0-.9 0-1.12.12q-.3.15-.47.46c-.11.23-.11.53-.11 1.12m-.05 11.03v1.14c0 .6 0 .91.12 1.14q.15.31.47.47c.23.12.53.12 1.14.12h1.22c.6 0 .9 0 1.14-.12a1 1 0 0 0 .47-.47c.12-.23.12-.53.12-1.14v-1.14c0-.6 0-.9-.12-1.14a1 1 0 0 0-.47-.47c-.23-.12-.54-.12-1.14-.12h-1.22c-.6 0-.91 0-1.14.12a1 1 0 0 0-.47.47c-.12.23-.12.53-.12 1.14"></path>'),L2=Ee('<path d="M16.78 3h1.42q.47 0 .83.02.4.02.82.21.61.31.92.92.2.41.21.81.03.36.02.83v1.4q0 .47-.02.83-.02.4-.21.81a2 2 0 0 1-.92.92 2 2 0 0 1-.82.21q-.36.02-.83.02h-1.42q-.47 0-.84-.02a2 2 0 0 1-.81-.2 2 2 0 0 1-.93-.93 2 2 0 0 1-.2-.8l-.03-.64h-2.2c-.49 0-.8 0-1.04.02a1 1 0 0 0-.35.06 1 1 0 0 0-.35.35 1 1 0 0 0-.07.35c-.02.24-.02.55-.02 1.04v5.57c0 .5 0 .8.02 1.04s.05.31.07.34q.12.23.35.35c.03.02.11.05.34.07s.56.02 1.05.02h2.2q0-.34.02-.62.01-.4.21-.81.31-.61.93-.92.42-.2.81-.21.37-.02.84-.02h1.42q.47 0 .83.02.4.01.82.2.61.31.92.93.2.41.21.8.03.37.02.84v1.4q0 .47-.02.83-.02.39-.21.81a2 2 0 0 1-.92.92q-.43.2-.82.21-.36.02-.83.02h-1.42q-.47 0-.84-.02a2 2 0 0 1-.81-.21 2 2 0 0 1-.93-.92 2 2 0 0 1-.2-.81l-.03-.63h-2.24q-.68 0-1.16-.03a3 3 0 0 1-1.01-.26 2.6 2.6 0 0 1-1.14-1.14 3 3 0 0 1-.26-1q-.04-.5-.03-1.16v-1.93H2.9A.9.9 0 0 1 2 12c0-.5.4-.9.9-.9h5.23V9.18q0-.68.03-1.16.02-.51.26-1.02a2.6 2.6 0 0 1 1.14-1.13q.5-.24 1.02-.26.48-.04 1.16-.02h2.23q0-.34.02-.63.01-.4.21-.81.31-.61.93-.92.42-.2.81-.21.37-.02.84-.02m-.84 1.84.15-.02c.16-.02.37-.02.72-.02h1.35c.36 0 .57 0 .72.02l.15.02a.3.3 0 0 1 .12.12l.03.15.01.71v1.34l-.01.71-.02.15a.3.3 0 0 1-.13.13l-.15.02-.72.01h-1.35l-.72-.01-.15-.03a.3.3 0 0 1-.12-.12l-.02-.15-.02-.71V5.82q0-.5.02-.71l.02-.15a.3.3 0 0 1 .12-.12m0 11.02.15-.03.72-.01h1.35l.72.01.15.03a.3.3 0 0 1 .12.12l.03.15.01.71v1.34l-.01.71-.02.15a.3.3 0 0 1-.13.12l-.15.02c-.15.02-.36.02-.72.02h-1.35c-.35 0-.56 0-.72-.02l-.15-.02a.3.3 0 0 1-.12-.12l-.02-.15-.02-.71v-1.34c0-.35 0-.56.02-.71l.02-.15a.3.3 0 0 1 .12-.13"></path><!>',1);function ov(i,e){let t=h(e,"isOpened",3,!1),o=f(()=>t()?"graph-close-icon":"graph-open-icon");Ze(i,{get testId(){return n(o)},children:(r,a)=>{var l=L2(),d=k(le(l));{var s=u=>{var m=A2();$(u,m)};V(d,u=>{t()&&u(s)})}$(r,l)},$$slots:{default:!0}})}function Cc(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"hidden",3,!1),r=h(e,"disabled",3,!1),a=h(e,"graphIsOpened",3,!1),d=$e().ui.t,s=f(()=>a()?d("tooltip_interactive_graph_on"):d("tooltip_interactive_graph_off")),u=f(()=>o()?"hidden":"");Kt(i,{get className(){return n(u)},testId:"btn-graph",get disabled(){return r()},get ariaLabel(){return n(s)},get click(){return e.click},get ref(){return t()},set ref(m){t(m)},children:(m,p)=>{let v=f(()=>!!a());ov(m,{get isOpened(){return n(v)}})},$$slots:{default:!0}}),H()}var nv=require("@vkontakte/videoplayer-core/es2015");function Tc(i,e){B(e,!0);let[t,o]=He(),r=()=>w(u,"$playbackState$",t),a=h(e,"isMobile",3,!1),l=h(e,"isLiveActive",3,!1),d=h(e,"ariaLabel",3,""),s=$e(),u=s.state.playbackState$,m=s.actions.internal.switchToActiveLive,p=s.actions.internal.togglePlay,v=f(()=>()=>{if(!l()){m();return}r()===nv.PlaybackState.PAUSED&&p()}),b=f(()=>a()?"":"btn--live btn-full-opacity"),y=f(()=>l()?"btn-live":"btn-live-offset"),_=f(()=>l()&&r()===nv.PlaybackState.PLAYING);Kt(i,{get className(){return n(b)},get testId(){return n(y)},get disabled(){return n(_)},get ariaLabel(){return d()},get click(){return n(v)},children:(x,I)=>{ec(x,{get isActive(){return l()}})},$$slots:{default:!0}}),H(),o()}var rv=require("@vkontakte/videoplayer-shared/es2015");var M2=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),V2=L('<img class="icon" aria-hidden="true"/>');function tl(i,e){"use strict";let t=K(!1),o=()=>{O(t,!0)};var r=Oe(),a=le(r);{var l=s=>{var u=M2();$(s,u)},d=s=>{var u=V2();N(()=>De(u,"src",e.icon)),vt("error",u,o),Da(u),$(s,u)};V(a,s=>{n(t)?s(l):s(d,!1)})}$(i,r)}function sv(i,e){B(e,!0);let t=h(e,"disabled",3,!1),o=h(e,"onClick",3,rv.noop),r=h(e,"ref",15),a=f(()=>o()===rv.noop),l=f(()=>n(a)||t()),d=f(()=>n(a)?"btn-full-opacity":"");Oo(i,{get disabled(){return n(l)},get tooltipContent(){return e.tooltipText},get disabledTooltipContent(){return e.disabledTooltipContent},width:40,get disableMouseupTooltipShow(){return e.disableMouseupTooltipShow},get tooltipVisible(){return e.tooltipVisible},get ref(){return r()},set ref(s){r(s)},children:(s,u)=>{let m=f(()=>{var p;return(p=e.testId)!=null?p:e.id});Kt(s,{get className(){return n(d)},get ariaLabel(){return e.ariaLabel},get click(){return o()},get disabled(){return n(l)},get testId(){return n(m)},children:(p,v)=>{tl(p,{get icon(){return e.icon}})},$$slots:{default:!0}})},$$slots:{default:!0}}),H()}var Wb=i=>!!i.buttonComponent;var qs={vkLogo:100,autoplayNext:200,volume:300,subtitles:400,settings:500,context:600,fullscreen:700,chromecast:800};var bp=(i,e,t,o)=>{if(i)for(let[r,a]of Object.entries(e))a.set(Jn(i,t,r,o))};var $p=require("@vkontakte/videoplayer-shared/es2015"),Kb=10,qb=40,av=.2,O2=.5,D2=65,N2=114,B2=4,Qb=({onPreviewTrackOpened:i,getTimelineRef:e,isHorizontal:t})=>{let o=f(()=>t?D2:N2),r=K(!1),a=K(0),l=K(0),d=f(()=>n(o)+Kb-qb-B2),s=f(()=>(0,$p.interpolate)(n(a),[av,1],[0,-n(d)])),u=f(()=>(0,$p.interpolate)(n(a),[av,1],[0,qb])),m=f(()=>(0,$p.interpolate)(n(a),[av,1],[0,n(o)+Kb]));return{progressBarY:()=>n(s),controlsY:()=>n(u),calculatedHeight:()=>n(m),onPointerDown:_=>{var x;O(l,((x=e())==null?void 0:x.getBoundingClientRect().bottom)||0,!0),O(r,!0)},onPointerMove:_=>{if(!n(r))return;let x=Math.max(Math.min(_.clientY-n(l),0),-n(d));O(a,Math.abs(x/n(d)),!0)},onPointerUp:()=>{O(r,!1),O(a,n(a)>=O2?1:0,!0),n(a)===1&&i()},closePreviewTrack:()=>{O(a,0)}}};var H2=i=>i;function ba(i,{delay:e=0,duration:t=400,easing:o=H2}={}){let r=+getComputedStyle(i).opacity;return{delay:e,duration:t,easing:o,css:a=>`opacity: ${a*r}`}}var F2=L('<span class="root s-2c"> </span>'),U2={hash:"s-2c",code:".root.s-2c{box-shadow:0 8px 24px 0 rgba(0,0,0,.08);box-shadow:0 0 2px 0 rgba(0,0,0,.08);color:#fff;font-size:13px;font-weight:500;line-height:16px}"};function lv(i,e){Q(i,U2);var t=F2(),o=T(t,!0);S(t),N(()=>ge(o,e.time)),$(i,t)}var z2=L('<div class="tooltip-wrapper s-13"><div><!></div></div>'),W2={hash:"s-13",code:'.tooltip-wrapper.s-13{display:block;position:relative}.tooltip.s-13{bottom:100%;opacity:0;position:absolute;transform:translateX(-50%);transition:opacity .2s;visibility:hidden}.pointer.s-13:after{border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid rgba(41,41,41,.8);bottom:0;content:" ";font-size:0;left:50%;line-height:0;position:absolute;transform:translate(-50%,5px);width:0}.tooltip.active.s-13{opacity:1;visibility:visible}'};function dv(i,e){Q(i,W2);let t=h(e,"active",3,!1),o=h(e,"pointer",3,!1),r=h(e,"translateXPx",3,0),a=h(e,"translateYPx",3,0),l=h(e,"leftOffset",3,0),d=h(e,"rightOffset",3,0),s=K(void 0),u=K(void 0);function m(x){if(!n(u))return 0;let{width:I}=n(u).getBoundingClientRect(),C=I/2;return x<C?C+l():x>e.containerWidth-C?e.containerWidth-C-d():x}let p=f(()=>m(r()));var v=z2(),b=T(v);let y;var _=T(b);ri(_,()=>{var x;return(x=e.children)!=null?x:$t}),S(b),it(b,x=>O(u,x),()=>n(u)),S(v),it(v,x=>O(s,x),()=>n(s)),N(x=>{Qe(v,`transform: translate(${n(p)}px, ${a()}px);`),y=oe(b,1,"tooltip s-13",null,y,x),Qe(b,`opacity: ${t()?1:0}; visibility: ${t()?"visible":"hidden"}`)},[()=>({active:t(),pointer:o()})]),$(i,v)}var Gb=i=>Math.abs(i)/90%4===1;var K2=Ee('<path xmlns="http://www.w3.org/2000/svg" d="M15.782 10.152a.75.75 0 0 1-1.06 0L9.999 5.438l-4.72 4.716a.75.75 0 0 1-1.061-1.061l5.251-5.246a.75.75 0 0 1 1.06 0l5.253 5.246a.75.75 0 0 1 0 1.06Z"></path><path xmlns="http://www.w3.org/2000/svg" d="M15.782 16.152a.75.75 0 0 1-1.06 0l-4.723-4.715-4.72 4.716a.75.75 0 0 1-1.061-1.061l5.251-5.246a.75.75 0 0 1 1.06 0l5.253 5.245a.75.75 0 0 1 0 1.061Z"></path>',1);function cv(i){Ze(i,{height:"20",width:"20",shadow:!0,children:(e,t)=>{var o=K2();ni(),$(e,o)},$$slots:{default:!0}})}var q2=L('<div class="rich-seek-hint s-14"><span class="icon_wrapper s-14"><!></span> <span class="rich-seek-hint-text s-14"> </span></div>'),Q2=L('<div class="preview s-14"><!></div>'),G2=L('<div class="time s-14"> </div>'),Y2=L('<div><!> <div class="episode s-14"><!></div> <!></div>'),j2={hash:"s-14",code:".timeline-preview.s-14{border-radius:2px;bottom:18px;pointer-events:none}.timeline-preview.mobile.s-14{bottom:72px}.preview.s-14{background-color:var(--timeline-preview-bg);border:1px solid var(--white);border-radius:8px;box-shadow:0 0 2px var(--timeline-preview-shadow),0 8px 24px var(--timeline-preview-shadow);display:flex;justify-content:center}.episode.s-14{margin-bottom:4px;margin-top:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.episode.s-14,.time.s-14{font-size:13px;font-weight:500;line-height:16px;text-align:center;text-shadow:0 8px 24px var(--timeline-preview-shadow),0 0 2px var(--timeline-preview-shadow)}.time.s-14{color:var(--white)}.rich-seek-hint.s-14{position:absolute;text-align:center;top:-12px;transform:translateY(-100%)}.icon_wrapper.s-14{display:inline-block;height:20px;margin-right:6px;vertical-align:top;width:20px}.rich-seek-hint-text.s-14{font-size:14px;line-height:18px;text-shadow:0 2px 4px rgba(0,0,0,.3),0 7px 16px rgba(0,0,0,.25);vertical-align:top}"};function uv(i,e){B(e,!0),Q(i,j2);let[t,o]=He(),r=()=>w(_,"$rotateAlpha",t),a=()=>w(x,"$playerSize",t),l=()=>w(I,"$previewTrackAvailable",t),d={MOBILE:150,DESKTOP:278},s=h(e,"time",3,""),u=h(e,"isMobile",3,!1),m=h(e,"videoEpisodes",19,()=>[]),p=h(e,"progress",3,0),v=h(e,"duration",3,0),b=h(e,"isInteractive",3,!1),y=$e(),_=y.ui.rotateAlpha,x=y.ui.playerSize,I=y.ui.previewTrackAvailable,C=K(0),R=K(0),A=K(""),P=K(0),E=K(0),W=K(0),F=K(0),U=f(()=>lp(p(),v(),m())),X=f(()=>td(r())),se=f(()=>Gb(r())),j=f(Te),ne=f(()=>(n(se)?1:-1)*(n(C)/2-n(R)/2)),Z=f(()=>n(ne)*-1);Fe(()=>{(ue=>{O(C,ue.width,!0),O(R,ue.height,!0)})(te())}),Fe(()=>{(ue=>{O(A,ue.imgSrc,!0),O(P,ue.imgWidth,!0),O(E,ue.imgHeight,!0),O(W,ue.imgOffsetX,!0),O(F,ue.imgOffsetY,!0)})(_e(p()))});function Te(){var ee;let ue=u()?d.MOBILE:d.DESKTOP,{isVertical:Ae}=fe(),ze=30;return(ee=n(U))!=null&&ee.text&&(ze+=16),(Ae||n(X))&&(ze+=18,ze+=50),Math.min(Math.max(a().height-ze,0),ue)}function fe(){let ue=e.previewThumbsData.frameWidth,Ae=e.previewThumbsData.frameHeight,ze=Ae>ue;return{width:ue,height:Ae,isHorizontal:!ze,isVertical:ze}}function te(){let{height:ue,isHorizontal:Ae,isVertical:ze,width:ee}=fe();return Ae&&(ue=ue/ee*n(j),ee=n(j)),ze&&(ee=ee/ue*n(j),ue=n(j)),{width:ee,height:ue}}function _e(ue){let Ae;e.previewThumbsData.isUV?Ae=Math.floor(v()*ue/e.previewThumbsData.frequency):Ae=Math.min(e.previewThumbsData.countTotal,Math.max(0,Math.floor(e.previewThumbsData.countTotal*ue)));let ze=Math.floor(Ae/e.previewThumbsData.countPerImage),ee=Math.floor(Ae%e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow),de=Ae%e.previewThumbsData.countPerRow,ke=Math.floor(e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow);!e.previewThumbsData.isUV&&ze===Math.floor(e.previewThumbsData.countTotal/e.previewThumbsData.countPerImage)&&(ke=Math.floor(e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow),e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage%e.previewThumbsData.countPerRow>0&&ke++);let xe=e.previewThumbsData.countPerRow;!e.previewThumbsData.isUV&&ze===Math.floor(e.previewThumbsData.countTotal/e.previewThumbsData.countPerImage)&&e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage>0&&(xe=Math.min(e.previewThumbsData.countPerRow,e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage));let Je=n(C)*xe,Pe=n(R)*ke,we=-de*n(C),Ne=-ee*n(R);return{imgSrc:e.previewThumbsData.links[ze],imgWidth:Je,imgHeight:Pe,imgOffsetX:we,imgOffsetY:Ne}}var Ce=Y2();let me;var ce=T(Ce);{var Ye=ue=>{var Ae=Q2(),ze=T(Ae);{var ee=de=>{var ke=q2(),xe=T(ke),Je=T(xe);cv(Je,{}),S(xe);var Pe=k(xe,2),we=T(Pe,!0);S(Pe),S(ke),N(Ne=>ge(we,Ne),[()=>Y("preview_track_notification_text")]),$(de,ke)};V(ze,de=>{l()&&de(ee)})}S(Ae),N(()=>Qe(Ae,`width: ${n(C)}px; height: ${n(R)}px; background-image: url(${n(A)}); background-size: ${n(P)}px ${n(E)}px; background-position: ${n(W)}px ${n(F)}px;
|
|
61
|
+
transform: rotate(${r()}deg) ${n(X)?`translate(${n(ne)}px, ${n(Z)}px)`:""};
|
|
62
|
+
`)),$(ue,Ae)};V(ce,ue=>{n(A)&&ue(Ye)})}var G=k(ce,2),D=T(G);{var Xe=ue=>{var Ae=Oe(),ze=le(Ae);{var ee=ke=>{var xe=bs();N(Je=>ge(xe,Je),[()=>Y("tooltip_episode_unfinished")]),$(ke,xe)},de=ke=>{var xe=bs();N(()=>ge(xe,n(U).text||"")),$(ke,xe)};V(ze,ke=>{b()&&n(U).completed===!1?ke(ee):ke(de,!1)})}$(ue,Ae)};V(D,ue=>{n(U)&&ue(Xe)})}S(G);var re=k(G,2);{var pe=ue=>{var Ae=G2(),ze=T(Ae,!0);S(Ae),N(()=>ge(ze,s())),$(ue,Ae)};V(re,ue=>{b()||ue(pe)})}S(Ce),N(ue=>{me=oe(Ce,1,"timeline-preview s-14",null,me,ue),Qe(Ce,`width: ${n(X)?n(R):n(C)}px;`)},[()=>({mobile:u()})]),$(i,Ce),H(),o()}var X2=L('<span class="time s-f"> </span>'),Z2=L("<!> <!>",1),J2={hash:"s-f",code:".time.s-f{background-color:rgba(41,41,41,.8);border-radius:3px;color:var(--white);display:inline-block;padding:6px 10px}.timeline-slider{--slider-bg:var(--timeline-slider-bg);--slider-filled-bg:var(--timeline-slider-filled-bg);--slider-handle-bg:var(--timeline-slider-handle-bg);--slider-loaded-bg:var(--timeline-slider-loaded-bg)}"};function pv(i,e){var Me,ye,Ue,Se,Tt;B(e,!0),Q(i,J2);let[t,o]=He(),r=()=>w(j,"$interactiveEpisodes$",t),a=()=>w(E,"$duration$",t),l=()=>w(P,"$position$",t),d=()=>w(Te,"$isInteractiveExpectation$",t),s=()=>w(Z,"$isInteractiveTime$",t),u=()=>w(Ce,"$previewTrackActive",t),m=()=>w(W,"$isLive$",t),p=()=>w(_e,"$disabledControls$",t),v=()=>w(U,"$isMobile",t),b=()=>w(F,"$isActiveLive$",t),y=()=>w(A,"$bufferedProgress$",t),_=h(e,"showTimeline",3,!1),x=h(e,"withEpisodes",3,!0),I=h(e,"ref",15,void 0),C=$e(),R=Dt(),A=C.state.bufferedProgress$,P=C.state.positionWithScrubbing$,E=C.state.duration$,W=C.state.isLive$,F=C.state.isActiveLive$,U=C.ui.isMobile,X=R.features.episodes&&x()?C.actions.internal.getVideoEpisodes():void 0,se=C.actions.internal.getPreviewThumbsData(),j=C.state.interactiveEpisodes$,ne=C.state.isInteractive,Z=C.state.isInteractiveTime$,Te=C.state.isInteractiveExpectation$,fe=C.actions.internal.correctSeekTimeToInteractive,te=(Me=C.callbacks)==null?void 0:Me.onDisabledTimelineClick,_e=C.ui.controls.disabledControls$,Ce=C.ui.previewTrackActive,me=(Ue=(ye=C.callbacks)==null?void 0:ye.uiInfo)==null?void 0:Ue.onTimelineMouseEnter,ce=(Tt=(Se=C.callbacks)==null?void 0:Se.uiInfo)==null?void 0:Tt.onTimelineMouseLeave,Ye=C.ui.t,G=R.features.interactiveResponsiveUi,D=f(()=>ne?r():X),Xe=f(()=>nn(a())),re=f(()=>nn(l())),pe=f(()=>l()/a()),ue=f(()=>d()||s()),Ae=K(!1),ze=K(""),ee=K(0),de=K(0),ke=K(0),xe=f(()=>({containerWidth:n(de),translateXPx:n(ee),translateYPx:ne&&se?-36:-16,active:n(Ae)&&_()&&!n(ue)&&!G&&!u(),pointer:!R.features.timelinePreview||!se||m()})),Je=Ye("aria_timeline"),Pe=f(()=>Ye("aria_timeline_value",{position:n(re),duration:n(Xe)}));function we(ve){return!fe||!ne?ve:fe(ve*a())/a()}function Ne(ve,Be){var qe;(qe=e.onSliderPointerDown)==null||qe.call(e,Be),C.actions.internal.startScrubbing(we(ve))}function Pt(ve){s()||C.actions.internal.progressScrubbing(we(ve))}function kt(ve){var Be;C.actions.internal.completeScrubbing(we(ve)),O(Ae,!1),(Be=e.onSliderPointerUp)==null||Be.call(e)}function Lt(ve,Be,qe){var ct;(ct=e.onSliderPointerEnter)==null||ct.call(e,ve),ei(ve,Be,qe),O(Ae,!0)}function pt(ve,Be,qe,ct){var Xt;(Xt=e.onSliderMove)==null||Xt.call(e,ct,ve),ei(ve,Be,qe),O(Ae,!0)}function It(){var ve;O(Ae,!1),(ve=e.onSliderLeave)==null||ve.call(e)}function ei(ve,Be,qe){O(ke,we(ve),!0),O(ee,Be,!0),qe&&O(de,qe,!0),O(ze,Ft(ve),!0)}function Ft(ve){let Be=nn((m()?1-ve:ve)*a());return m()?`-${Be}`:Be}let Bt=f(()=>p().has("TIMELINE"));var qt=Z2(),q=le(qt);dv(q,is(()=>n(xe),{get leftOffset(){return e.tooltipLeftOffset},get rightOffset(){return e.tooltipRightOffset},children:(ve,Be)=>{var qe=Oe(),ct=le(qe);{var Xt=di=>{uv(di,{get time(){return n(ze)},get isMobile(){return v()},get videoEpisodes(){return n(D)},get previewThumbsData(){return se},get progress(){return n(ke)},get duration(){return a()},get isInteractive(){return ne}})},Mt=di=>{var ci=X2(),Li=T(ci,!0);S(ci),N(()=>ge(Li,n(ze))),$(di,ci)};V(ct,di=>{R.features.timelinePreview&&se&&!m()?di(Xt):di(Mt,!1)})}$(ve,qe)},$$slots:{default:!0}}));var Le=k(q,2);Za(Le,{className:"timeline-slider",get isActiveLive(){return b()},get isMobile(){return v()},get ariaLabel(){return Je},ariaValueMin:0,get ariaValueMax(){return a()},get ariaValueNow(){return l()},get ariaValueText(){return n(Pe)},get loadedProgress(){return y()},get filledProgress(){return n(pe)},get handleProgress(){return n(pe)},get videoEpisodes(){return n(D)},onPointerDown:Ne,onHandleMove:Pt,onPointerMove:pt,onPointerUp:kt,onPointerEnter:Lt,onPointerLeave:It,get onMouseEnter(){return me},get onMouseLeave(){return ce},get onDisabledClick(){return te},get isInteractive(){return ne},get disabled(){return n(Bt)},get handleAlwaysVisible(){return u()},get hideHandel(){return s()},testId:"progress_bar",onContextMenu:kt,get ref(){return I()},set ref(ve){I(ve)}}),$(i,qt),H(),o()}var ew={hash:"s-g",code:".timeline-ads-slider{--slider-bg:var(--timeline-slider-bg);--slider-filled-bg:var(--timeline-slider-filled-bg);--slider-handle-bg:var(--timeline-slider-handle-bg);--slider-loaded-bg:var(--timeline-slider-loaded-bg)}"};function Ic(i,e){B(e,!0),Q(i,ew);let[t,o]=He(),r=()=>w(s,"$isMobile",t),a=h(e,"position",3,0),l=h(e,"duration",3,0),d=$e(),s=d.ui.isMobile,u=d.ui.t,m=f(()=>nn(l())),p=f(()=>nn(a())),v=f(()=>a()/l()),b=f(()=>u("aria_timeline_value",{position:n(p),duration:n(m)})),y=f(()=>Math.round(n(v)*100));Za(i,{className:"timeline-ads-slider",ariaValueMin:0,get ariaValueMax(){return l()},get ariaValueNow(){return n(y)},get ariaValueText(){return n(b)},get filledProgress(){return n(v)},hideHandel:!0,get squareBorders(){return r()}}),H(),o()}var tw=L("<div><!></div>"),iw=L("<div></div>"),ow={hash:"s-e",code:".timeline.s-e{align-items:center;bottom:0;box-sizing:border-box;display:flex;min-width:86px;pointer-events:all;position:relative;width:100%}.timeline.mobile.s-e{height:16px;margin-top:6px;padding:6px 12px 7px}.withoutPadding.s-e{padding:0}.timeline-stub.s-e{min-width:20px;width:100%}.timeline-stub.mobile.s-e{height:8px}"};function il(i,e){B(e,!0),Q(i,ow);let[t,o]=He(),r=()=>w(x,"$isLive$",t),a=()=>w(R,"$isMobile",t),l=()=>w(A,"$disabled",t),d=()=>w(C,"$adPosition",t),s=()=>w(I,"$adDuration",t),u=h(e,"isAds",3,!1),m=h(e,"isHidden",3,!1),p=h(e,"timelineNotAvailable",3,!1),v=h(e,"needPadding",3,!0),b=h(e,"ref",15,void 0),y=$e(),_=Dt(),x=y.state.isLive$,I=y.ads.duration,C=y.ads.position,R=y.ui.isMobile,A=ae(!1),P=f(()=>!p()&&(!r()||r()&&e.canRewindLive&&e.isRewindableLive||u()));var E=Oe(),W=le(E);{var F=X=>{var se=tw();let j;var ne=T(se);{var Z=fe=>{Ic(fe,{get position(){return d()},get duration(){return s()}})},Te=fe=>{pv(fe,{get tooltipLeftOffset(){return e.tooltipLeftOffset},get tooltipRightOffset(){return e.tooltipRightOffset},get showTimeline(){return n(P)},get withEpisodes(){return e.withEpisodes},get onSliderMove(){return e.onSliderMove},get onSliderPointerDown(){return e.onSliderPointerDown},get onSliderPointerUp(){return e.onSliderPointerUp},get onSliderLeave(){return e.onSliderLeave},get onSliderPointerEnter(){return e.onSliderPointerEnter},get ref(){return b()},set ref(te){b(te)}})};V(ne,fe=>{u()?fe(Z):fe(Te,!1)})}S(se),Ds(se,()=>ql(m()&&_.features.usePerformanceFix,A,_.disableInvisibleComponentsTimeout)),N(fe=>j=oe(se,1,"timeline s-e",null,j,fe),[()=>({withoutPadding:!v(),mobile:a(),"out-of-flow":l()})]),$(X,se)},U=X=>{var se=iw();let j;N(ne=>j=oe(se,1,"timeline-stub s-e",null,j,ne),[()=>({mobile:a()})]),$(X,se)};V(W,X=>{n(P)?X(F):X(U,!1)})}$(i,E),H(),o()}var Yb=require("@vkontakte/videoplayer-shared/es2015");var jb=require("@vkontakte/videoplayer-statistics/es2015"),nw=(i,e,t,o,r,a,l)=>{O(e,!0),O(t,i.clientX,!0),O(o,n(r),!0),a(l())},rw=L("<div></div>"),sw=L('<div><div class="track s-2a"></div></div>'),aw={hash:"s-2a",code:'.root.s-2a{display:flex;height:var(--preview-track-frame-height-horizontal);overflow:hidden;position:relative;width:100%}.root.is-vertical-video.s-2a,.root.vertically-rotated.s-2a{height:var(--preview-track-frame-height-vertical)}.root.s-2a:after{background-color:#fff;box-shadow:0 2px 2px 0 rgba(0,0,0,.12);box-shadow:0 0 2px 0 rgba(0,0,0,.06);content:"";height:100%;margin:0 auto;pointer-events:none;width:3px;z-index:1}.track.s-2a{bottom:0;display:flex;left:0;padding:0 50%;top:0}.frame.s-2a,.track.s-2a{position:absolute}.frame.s-2a{background-position-x:calc(var(--column-index)*-1*var(--frame-width));background-position-y:calc(var(--frame-height)*-1*var(--row-index));background-size:calc(var(--frame-width)*var(--column-numbers)) calc(var(--frame-height)*var(--row-numbers));flex-shrink:0;height:var(--frame-height);pointer-events:none;transform-origin:center;width:var(--frame-width)}.vertically-rotated.s-2a .frame:where(.s-2a){transform-origin:0 0}.rotate-1.s-2a{transform:rotate(-90deg) translateX(-100%)}.rotate-2.s-2a{transform:rotate(-180deg)}.rotate-3.s-2a{transform:rotate(-270deg) translateY(-100%)}'};function mv(i,e){B(e,!0),Q(i,aw);let[t,o]=He(),r=()=>w(R,"$rotateAlpha",t),a=()=>w(_,"$position$",t),l=()=>w(y,"$duration$",t),d=$e(),{countPerImage:s=0,countPerRow:u=0,countTotal:m=0,links:p=[],frameHeight:v=0,frameWidth:b=0}=d.actions.internal.getPreviewThumbsData()||{},{duration$:y,positionWithScrubbing$:_}=d.state,{startScrubbing:x,progressScrubbing:I,completeScrubbing:C}=d.actions.internal,R=d.ui.rotateAlpha,A=K(void 0),P=K(!1),E=K(0),W=K(0),F=K(0),U=K(0),X=f(()=>v<=b),se=f(()=>td(r())),j=f(()=>n(X)?!n(se):n(se)),ne=114,Z=65,Te=3,fe=f(()=>n(j)?ne:Z),te=f(()=>n(X)?ne:Z),_e=f(()=>n(X)?"var(--preview-track-frame-height-horizontal)":"var(--preview-track-frame-height-vertical)"),Ce=f(()=>m*n(fe)),me=K(0);Fe(()=>{O(U,Math.ceil(-n(F)/n(fe))-1),O(F,-n(Ce)*a()/l())});let ce=()=>{C(Ye(),!0,jb.ThinOneStat.ActionSeekType.RICH)},Ye=()=>l()*-n(F)/n(Ce)/l(),G=!1,D=Pe=>{if(!n(P))return!1;let we=Pe.clientX-n(E);O(F,n(W)+we),O(F,Math.max(Math.min(n(F),0),-n(Ce)),!0),Math.abs(we)>1&&(G=!0),I(Ye())},Xe=Pe=>{n(P)&&(O(P,!1),!G&&Pe&&O(F,-(Pe.offsetX-n(me)/2)),G=!1,ce())},re=()=>{n(P)&&Xe()},pe=f(()=>s/u),ue=(Pe,we)=>{if(Pe!==p.length-1)return u;let Ne=0,Pt=we*u;for(let kt=1;kt<=u;kt++)Pe*s+Ne+Pt<m&&Ne++;return Ne},Ae=f(()=>Math.floor(n(U)/s)),ze=f(()=>(0,Yb.getRangeAroundIndex)(3,n(Ae),p.length-1)),ee=(Pe,we,Ne)=>{let Pt=s*n(fe);return Pe*Pt+we*n(fe)*u+n(me)/2-Te/2+Ne*n(fe)},de=f(()=>[`--row-numbers: ${n(pe)}`,`--column-numbers: ${u}`,`--frame-width: ${n(te)}px`,`--frame-height: ${n(_e)}`].join(";"));var ke=sw();let xe;var Je=T(ke);Je.__pointerdown=[nw,P,E,W,F,x,Ye],Je.__pointermove=D,Je.__pointerup=Xe,xi(Je,20,()=>n(ze),Pe=>Pe,(Pe,we)=>{var Ne=Oe(),Pt=le(Ne);xi(Pt,16,()=>Array.from({length:n(pe)},(kt,Lt)=>Lt),kt=>kt,(kt,Lt)=>{var pt=Oe(),It=le(pt);xi(It,16,()=>Array.from({length:ue(we,Lt)},(ei,Ft)=>Ft),ei=>ei,(ei,Ft)=>{var Bt=rw();N((qt,q)=>{Qe(Bt,qt),oe(Bt,1,q,"s-2a")},[()=>`--row-index: ${Lt}; --column-index: ${Ft}; left: ${ee(we,Lt,Ft)}px; background-image: url(${p[we]});`,()=>`frame rotate-${Math.abs(r())/90%4}`]),$(ei,Bt)}),$(kt,pt)}),$(Pe,Ne)}),S(Je),S(ke),it(ke,Pe=>O(A,Pe),()=>n(A)),N(Pe=>{xe=oe(ke,1,"root s-2a",null,xe,Pe),Qe(ke,n(de)),Qe(Je,`transform: translateX(${n(F)}px); width: ${n(Ce)}px;`)},[()=>({"is-vertical-video":!n(X),"vertically-rotated":n(se)})]),vt("mouseleave",Je,re),kn(ke,"clientWidth",Pe=>O(me,Pe)),$(i,ke),H(),o()}et(["pointerdown","pointermove","pointerup"]);var lw=L('<div class="notification s-2b"><span class="description s-2b"> </span></div>'),dw={hash:"s-2b",code:".notification.s-2b{background:var(--notification-bg);border-radius:var(--notification-radius);padding:9px 14px 10px 12px}.description.s-2b{font-size:14px;line-height:18px}"};function vv(i,e){B(e,!1),Q(i,dw);let t=340,{ui:{t:o}}=$e();on();var r=lw(),a=T(r),l=T(a,!0);S(a),S(r),N(d=>ge(l,d),[()=>o("preview_track_close_tooltip")],gr),Ns(3,r,()=>ba,()=>({duration:t})),$(i,r),H()}var Xb=require("@vkontakte/videoplayer-shared/es2015"),cw=L('<div class="preview-track-close tooltip s-28"><!></div>'),uw=L('<div class="preview-track-control s-28"><!> <div class="preview-track-close s-28"><!></div> <!></div>'),pw=L('<div class="wrapper-preview-track s-28"><!></div>'),fw=L('<div class="enriched-timeline s-28"><!> <!> <!></div>'),mw={hash:"s-28",code:".enriched-timeline.s-28{padding:var(--timeline-padding-vertical-top) var(--timeline-padding-horizontal) var(--timeline-padding-vertical-bottom);pointer-events:auto;position:relative}.preview-track-control.s-28{align-items:center;display:flex;justify-content:center;left:0;padding:0 calc(var(--timeline-padding-horizontal));pointer-events:none;position:absolute;right:0;top:calc((var(--timeline-height) + var(--preview-track-controls-top))*-1)}.preview-track-close.s-28{pointer-events:auto;position:absolute;right:calc(var(--timeline-padding-horizontal))}.preview-track-close.tooltip.s-28{bottom:32px;opacity:0;transition:opacity .2s}.preview-track-close.s-28:hover+.tooltip:where(.s-28){opacity:1}.wrapper-preview-track.s-28{box-sizing:border-box;left:0;overflow:hidden;padding:0 calc(var(--timeline-padding-horizontal));position:absolute;right:0;z-index:-1}"};function gv(i,e){B(e,!0),Q(i,mw);let[t,o]=He(),r=()=>w(_,"$playerSize",t),a=()=>w(y,"$duration$",t),l=()=>w(x,"$previewTrackActive",t),d=()=>w(v,"$position$",t),s=()=>w(b,"$isRewindableLive$",t),u=h(e,"timelineRef",15,void 0),m=$e(),p=200,{positionWithScrubbing$:v,isRewindableLive$:b,duration$:y}=m.state,{playerSize:_,previewTrackActive:x}=m.ui,{countPerImage:I=0,links:C=[],frequency:R=0}=m.actions.internal.getPreviewThumbsData()||{},A=f(()=>r().width>100),P=K(!J_()),E=()=>{n(P)&&(Z_(),O(P,!1))},W=fe=>{let te=Math.floor(a()*fe/R),_e=Math.floor(te/I),Ce=(0,Xb.getRangeAroundIndex)(3,_e,C.length-1);for(let me of Ce){let ce=new Image;ce.src=C[me]}},F=(fe,te)=>{W(te),!l()&&e.onTimelineMove(fe)};var U=fw(),X=T(U);{var se=fe=>{var te=uw(),_e=T(te);let Ce=f(()=>nn(d()));lv(_e,{get time(){return n(Ce)}});var me=k(_e,2),ce=T(me);Hs(ce,{onClick:()=>m.actions.internal.closePreviewTrack()}),S(me);var Ye=k(me,2);{var G=D=>{var Xe=cw(),re=T(Xe);vv(re,{}),S(Xe),$(D,Xe)};V(Ye,D=>{n(P)&&D(G)})}S(te),vt("mouseleave",me,E),Ns(3,te,()=>ba,()=>({duration:p})),$(fe,te)};V(X,fe=>{l()&&fe(se)})}var j=k(X,2);let ne=f(()=>!n(A));il(j,{get isHidden(){return n(ne)},get isAds(){return e.isAds},get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return s()},onSliderMove:F,get onSliderPointerDown(){return e.onTimelinePointerDown},get onSliderPointerUp(){return e.onTimelinePointerUp},get onSliderLeave(){return e.onTimelinePointerLeave},onSliderPointerEnter:W,get ref(){return u()},set ref(fe){u(fe)}});var Z=k(j,2);{var Te=fe=>{var te=pw(),_e=T(te);mv(_e,{}),S(te),N(()=>Qe(te,`height: ${e.animatedPreviewTrackHeight}px;`)),$(fe,te)};V(Z,fe=>{e.previewTrackAvailable&&fe(Te)})}S(U),N(()=>Qe(U,`transform: translateY(${e.animatedOffsetY}px);`)),$(i,U),H(),o()}var gw=L('<div><!> <div class="controls s-1e" data-testid="player_controls"><div class="controls-left s-1e"><!> <!> <!></div> <div class="controls-right s-1e"></div></div></div> <!>',1),hw={hash:"s-1e",code:'.wrapper-bottom.s-1e{bottom:0;box-sizing:border-box;display:flex;flex-direction:column;justify-content:flex-end;left:0;pointer-events:none;position:absolute;transition:transform var(--controls-transition-duration) var(--controls-transition-fn);width:100%;will-change:transform;z-index:var(--controls-container-z-index)}.wrapper-bottom.s-1e:before{background:var(--controls-gradient);content:"";height:var(--controls-gradient-height);position:absolute;width:100%}.wrapper-bottom.s-1e>:where(.s-1e){pointer-events:auto}.controls.s-1e{align-items:center;box-sizing:border-box;display:flex;font-size:13px;height:var(--controls-height);justify-content:space-between;padding:0 var(--controls-desktop-padding-horizontal) 4px;white-space:nowrap;width:100%}.controls-left.s-1e,.controls-right.s-1e{align-content:center;display:flex}.controls-left.s-1e{flex-grow:1;min-width:0;overflow:hidden}.controls-left.s-1e >:not(:first-child),.controls-right.s-1e >*{margin-left:var(--controls-desktop-item-margin-left)}.controls-hidden.s-1e{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-1e{transition:none}'};function _v(i,e){var hl,Sa;B(e,!0),Q(i,hw);let[t,o]=He(),r=()=>w(rn,"$disabledControls$",t),a=()=>w(St,"$adPlaybackState",t),l=()=>w(Mt,"$playbackState$",t),d=()=>w(Pi,"$currentSubtitle$",t),s=()=>w(Li,"$isEnded$",t),u=()=>w(Oi,"$currentGridType$",t),m=()=>w(bo,"$isLive$",t),p=()=>w(rt,"$chromecastState$",t),v=()=>w(at,"$isPictureInPictureActive",t),b=()=>w(pi,"$pictureInPictureType$",t),y=()=>w(st,"$availableSubtitlesList$",t),_=()=>w(Ut,"$contextMenuOpenedByKeyboard$",t),x=()=>w(yt,"$showContextMenuBtn$",t),I=()=>w(ui,"$isRewindableLive$",t),C=()=>w($o,"$isActiveLive$",t),R=()=>w(Br,"$graphIsOpened$",t),A=()=>w(No,"$contextMenuVisible$",t),P=()=>w(lt,"$isFullscreen",t),E=()=>w(On,"$autoplayNextEnabled",t),W=()=>w(n(Uo),"$prevButton",t),F=()=>w(n(wn),"$replayButton",t),U=()=>w(n(Co),"$playButton",t),X=()=>w(n(cn),"$nextButton",t),se=()=>w(n(po),"$playPrevChapterButton",t),j=()=>w(n(To),"$seekToInteractiveButton",t),ne=()=>w(n(ki),"$interactiveGraphButton",t),Z=()=>w(n(zr),"$liveButton",t),Te=()=>w(n(Un),"$time",t),fe=()=>w(n(ws),"$episodes",t),te=()=>w(n(Wi),"$vkLogo",t),_e=()=>w(n(Ss),"$volume",t),Ce=()=>w(n(us),"$subtitles",t),me=()=>w(n(Ir),"$settings",t),ce=()=>w(n(zo),"$context",t),Ye=()=>w(n(Wr),"$fullscreen",t),G=()=>w(n(un),"$chromecast",t),D=()=>w(Rn,"$additionalDesktopControlPanelRightButtons$",t),Xe=()=>w(Ui,"$playerSize",t),re=()=>w(Bo,"$isInteractiveTime$",t),pe=()=>w(mt,"$previewTrackActive",t),ue=()=>w(Ji,"$settingsMenuVisible",t),Ae=()=>w(Eo,"$settingButtonRef$",t),ze=()=>w(z,"$startedByKeyboard$",t),ee=()=>w(di,"$isAudioAvailable$",t),de=()=>w(qt,"$fakeIsPlaying$",t),ke=()=>w(ls,"$seekToInteractiveDisabledTooltip$",t),xe=()=>w(Ci,"$isPreviewTrackHorizontallyAligned$",t),Je=()=>w(Ao,"$previewTrackAvailable",t),Pe=()=>w(ai,"$previewTrackDragInProgress",t),we=()=>w(ti,"$adPosition",t),Ne=()=>w(Xt,"$position$",t),Pt=()=>w(yi,"$adDuration",t),kt=()=>w(ct,"$duration$",t),Lt=h(e,"playerControlsWrapperRef",15,void 0),pt=h(e,"playerControlsRef",15,void 0),It=h(e,"isAds",3,!1),ei=h(e,"logoTargetUrl",3,""),Ft=h(e,"isOneVideoPlaylist",3,!1),Bt=h(e,"customFullscreenSupported",3,!0),{fakeIsPlaying$:qt}=xo(),q=$e(),Le=xo(),Me=Dt(),ye=q.actions.internal.toggleMuted,Ue=q.actions.internal.togglePlay,Se=q.actions.internal.pause,Tt=q.actions.internal.toggleSubtitle,ve=q.actions.internal.checkFullscreenSupport,Be=(hl=q.callbacks)==null?void 0:hl.onAudioDoesNotExistHint,qe=(Sa=q.callbacks)==null?void 0:Sa.onAudioDisabledHint,ct=q.state.duration$,Xt=q.state.positionWithScrubbing$,Mt=q.state.playbackState$,di=q.state.isAudioAvailable$,ci=q.state.isAudioDisabled,Li=q.state.isEnded$,bo=q.state.isLive$,$o=q.state.isActiveLive$,ui=q.state.isRewindableLive$,{isActive$:at,type$:pi}=Le.pictureInPicture$,Ji=q.ui.settingsMenu.visible$,ft=q.ui.settingsMenu.openedByBtnKeyboard$,Ht=q.ui.controls,hi=q.actions.internal.getVideoEpisodes(),rt=q.state.chromecastState$,st=q.state.availableSubtitlesList$,Pi=q.state.currentSubtitle$,rn=Ht.disabledControls$,No=q.ui.contextMenu.visible$,yt=q.ui.contextMenu.showContextMenuBtn$,Ut=q.ui.contextMenu.openedByBtnKeyboard$,z=q.ui.startedByKeyboard$,Vt=q.ui.controlBlocks,ut=q.ui.t,yi=q.ads.duration,ti=q.ads.position,St=q.ads.playbackState,lt=q.ui.isFullscreen,Ui=q.ui.playerSize,Oi=q.ui.currentGridType$,Rn=q.ui.additionalDesktopControlPanelRightButtons$,On=q.ui.autoplayNextEnabled$,Ii=q.actions.internal.getVideoElement,eo=q.actions.internal.replayInteractive,Dn=q.actions.internal.prevVideoClick,wo=q.actions.internal.nextVideoClick,wi=q.state.isInteractive,Bo=q.state.isInteractiveTime$,Ho=q.state.showInteractiveGraph,yo=q.state.showSeekToInteractive,hn=q.state.showPlayPrevChapter,as=q.state.showInteractiveTimeIndicator,Nr=q.state.playPrevChapterDisabledTooltip,ls=Le.seekToInteractiveDisabledTooltip$,Br=Le.graphIsOpened$,tr=Me.features.interactiveResponsiveUi,ds=f(()=>r().has("EPISODE_BUTTON")),Hr=f(()=>r().has("GRAPH_BUTTON")),sn=f(()=>r().has("SEEK_TO_INTERACTIVE_BUTTON")),_n=f(()=>r().has("PLAY_BUTTON")),$r=f(()=>r().has("REPLAY_BUTTON")),yr=f(()=>r().has("PLAY_PREV_CHAPTER_BUTTON")),bn=()=>q.actions.internal.toggleChromecast(),ir=f(()=>It()?a()==="playing":l()===ol.PlaybackState.PLAYING),xr=f(()=>d().value!=="off"),or=f(()=>s()&&!It()||wi),nr=f(()=>tr?n(or)&&ao(u(),"m"):n(or)),cs=f(()=>!s()||wi||It()),So=f(()=>ao(u(),"m")),wr=f(()=>e.showNextPrevButtons&&ao(u(),"m")&&!It()&&e.nextButtonActive),zi=f(()=>e.showNextPrevButtons&&ao(u(),"m")&&!It()&&e.prevButtonActive),Sr=f(()=>!It()&&!!m()),Nn=f(()=>p()!==ol.ChromecastState.NOT_AVAILABLE&&!(v()&&b()===1)&&ao(u(),"m")&&!wi),_t=f(()=>e.showAutoplayNext&&!Ft()&&ao(u(),"s")),ii=f(()=>y().length>0&&ao(u(),"m")),Cr=f(()=>_()||x()),Fr=f(()=>ao(u(),"s")&&!It()),Ur=f(()=>!e.logoHidden&&!It()),Bn=f(()=>Me.features.fullscreen&&ve()&&(e.logoHidden||ao(u(),tr?"xs":"s"))&&!(v()&&b()===1)&&(wi?Bt():!0)),Hn=f(()=>(!m()||It())&&!(Me.features.interactiveHideTime&&wi)),Fo=f(()=>Ho&&ao(u(),"m")),Fn=f(()=>tr?yo&&ao(u(),"s"):yo),rr=f(()=>tr?hn&&ao(u(),"s"):hn),an=f(()=>!It()&&!m()&&!!(hi!=null&&hi.length)&&n(So)&&!n(ds)),$n=f(()=>!I()||!!C()),sr=f(()=>R()?ut("tooltip_interactive_graph_on"):ut("tooltip_interactive_graph_off")),yn=f(()=>A()?ut("tooltip_context_menu_close"):ut("tooltip_context_menu_open")),ln=(gt,ht)=>gt?ht&&ht===ol.PlaybackState.PAUSED?ut("tooltip_play"):"":ut("tooltip_live"),Di=f(()=>ln(n($n),l())),uo=f(()=>Me.logoType==="vk_video"?ut("tooltip_vk_video_logo"):ut("tooltip_vk_logo")),dn=f(()=>n(xr)?ut("tooltip_subtitles_on"):ut("tooltip_subtitles_off")),ar=f(()=>P()?ut("tooltip_fullscreen_on"):ut("tooltip_fullscreen_off")),Tr=f(()=>p()===ol.ChromecastState.CONNECTED?ut("tooltip_chromecast_on"):ut("tooltip_chromecast_off")),xn=f(()=>E()?ut("tooltip_autoplay_on"):ut("tooltip_autoplay_off")),lr=K(0),je=li({}),_i=li({}),Uo=f(()=>Ht.prevButton),wn=f(()=>Ht.replayButton),Co=f(()=>Ht.playButton),cn=f(()=>Ht.nextButton),po=f(()=>Ht.playPrevChapterButton),To=f(()=>Ht.seekToInteractiveButton),ki=f(()=>Ht.interactiveGraphButton),zr=f(()=>Ht.liveButton),Un=f(()=>Ht.time),ws=f(()=>Ht.episodes),Wi=f(()=>Ht.vkLogo),Ss=f(()=>Ht.volume),us=f(()=>Ht.subtitles),Ir=f(()=>Ht.settings),zo=f(()=>Ht.context),Wr=f(()=>Ht.fullscreen),un=f(()=>Ht.chromecast),Mi=f(()=>({prevButton:W()?W().right-W().left:0,replayButton:F()?F().right-F().left:0,playButton:U()?U().right-U().left:0,nextButton:X()?X().right-X().left:0,playPrevChapterButton:se()?se().right-se().left:0,seekToInteractiveButton:j()?j().right-j().left:0,interactiveGraphButton:ne()?ne().right-ne().left:0,liveButton:Z()?Z().right-Z().left:0,time:Te()?Te().right-Te().left:0,episodes:fe()?fe().right-fe().left:0,vkLogo:te()?te().right-te().left:0,volume:_e()?_e().right-_e().left:0,subtitles:Ce()?Ce().right-Ce().left:0,settings:me()?me().right-me().left:0,context:ce()?ce().right-ce().left:0,fullscreen:Ye()?Ye().right-Ye().left:0,chromecast:G()?G().right-G().left:0,additionalButtons:D().length?D().reduce(gt=>[...gt,40],[]):[]})),We=K(0);Fe(()=>{(!n(We)||n(We)<n(Mi).time)&&Et(()=>O(We,n(Mi).time,!0))});let Rt=K(!1);Fe(()=>{let gt=0;n(an)&&(ao(u(),"xl")?gt=n(Mi).time:gt=60);let ht=n(Mi).prevButton+n(Mi).playButton+n(Mi).nextButton+n(Mi).seekToInteractiveButton+n(Mi).interactiveGraphButton+n(Mi).liveButton+n(We)+gt;O(Rt,n(Hn)&&n(lr)>=ht,!0)});let fi=f(()=>n(Rt)&&ao(u(),"m")),Wo=(0,hv.debounceFn)(od,260),Io=(0,hv.debounceFn)(bp,260);Fe(()=>{Xe(),re(),pe(),Wo(Ii(),Ht,je,e.showControls),Io(Ii(),Vt,_i,e.showControls)}),Fe(()=>{_i.bottom=Lt()});let Eo=ae();Fe(()=>{ue(),Ae()&&Et(()=>Gl(Ae(),ue(),ft))});let Ki;Fe(()=>{ze(),Et(()=>hp(z,ze(),Ki))});function Ko(){ma({isAudioDisabled:ci,isAudioAvailable:ee(),isAds:It(),audioIsNotExistHintCallback:Be,audioDisabledHintCallback:qe})&&ye()}let zn=wi?eo:Ue,Er=f(()=>de()!==null),Po=f(()=>n(Er)?de():n(ir)),fo=f(()=>n(Po)?ut("tooltip_pause"):ut("tooltip_play")),Sn=ut("tooltip_episodes"),qo=f(()=>{var gt,ht,oo,Vi;return n(zi)?{id:"prevButton",type:"desktop-control-panel-left",weight:Ws.prevButton,buttonComponent:el,buttonComponentProps:{disabled:!e.prevButtonActive,type:"prev",click:Dn.bind(null,!0)},tooltipEnabled:!((ht=(gt=q.callbacks)==null?void 0:gt.uiInfo)!=null&&ht.onPrevButtonMouseEnter)&&!((Vi=(oo=q.callbacks)==null?void 0:oo.uiInfo)!=null&&Vi.onPrevButtonMouseLeave),mouseEnter:()=>{var no,bi,Qi;(Qi=(bi=(no=q.callbacks)==null?void 0:no.uiInfo)==null?void 0:bi.onPrevButtonMouseEnter)==null||Qi.call(bi,Jn(Ii(),je,"prevButton",e.showControls))},mouseLeave:()=>{var no,bi,Qi;(Qi=(bi=(no=q.callbacks)==null?void 0:no.uiInfo)==null?void 0:bi.onPrevButtonMouseLeave)==null||Qi.call(bi,Jn(Ii(),je,"prevButton",e.showControls))},tooltipText:ut("tooltip_previous"),disabled:!e.prevButtonActive}:void 0}),Wn=f(()=>n(nr)?{id:"replayButton",type:"desktop-control-panel-left",weight:Ws.replayButton,buttonComponent:nd,buttonComponentProps:{disabled:n($r),click:zn},tooltipText:ut("tooltip_restart"),disabled:n($r)}:void 0),Kr=f(()=>n(cs)?{id:"playButton",type:"desktop-control-panel-left",weight:Ws.playButton,buttonComponent:rd,buttonComponentProps:{disabled:n(_n),isPlaying:n(ir),click:Ue},tooltipText:n(fo),disabled:n(_n)}:void 0),qr=f(()=>{var gt,ht,oo,Vi;return n(wr)?{id:"nextButton",type:"desktop-control-panel-left",weight:Ws.nextButton,buttonComponent:el,buttonComponentProps:{disabled:!e.nextButtonActive,type:"next",click:wo.bind(null,!0)},tooltipEnabled:!((ht=(gt=q.callbacks)==null?void 0:gt.uiInfo)!=null&&ht.onNextButtonMouseEnter)&&!((Vi=(oo=q.callbacks)==null?void 0:oo.uiInfo)!=null&&Vi.onNextButtonMouseLeave),mouseEnter:()=>{var no,bi,Qi;(Qi=(bi=(no=q.callbacks)==null?void 0:no.uiInfo)==null?void 0:bi.onNextButtonMouseEnter)==null||Qi.call(bi,Jn(Ii(),je,"nextButton",e.showControls))},mouseLeave:()=>{var no,bi,Qi;(Qi=(bi=(no=q.callbacks)==null?void 0:no.uiInfo)==null?void 0:bi.onNextButtonMouseLeave)==null||Qi.call(bi,Jn(Ii(),je,"nextButton",e.showControls))},tooltipText:ut("tooltip_next"),disabled:!e.nextButtonActive}:void 0}),Kn=f(()=>wi&&n(rr)?{id:"playPrevChapterButton",type:"desktop-control-panel-left",weight:Ws.playPrevChapterButton,buttonComponent:xc,buttonComponentProps:{disabled:n(yr),click:e.playPrevChapter},tooltipText:ut("tooltip_interactive_go_back"),disabledTooltipContent:ut(Nr),disabled:n(yr)}:void 0),ot=f(()=>wi&&n(Fn)?{id:"seekToInteractiveButton",type:"desktop-control-panel-left",weight:Ws.seekToInteractiveButton,buttonComponent:Sc,buttonComponentProps:{disabled:n(sn),click:e.seekToInteractive},tooltipText:ut("tooltip_interactive_seek"),disabled:n(sn),disabledTooltipContent:ut(ke())}:void 0),Zt=f(()=>wi&&n(Fo)?{id:"interactiveGraphButton",type:"desktop-control-panel-left",weight:Ws.interactiveGraphButton,buttonComponent:Cc,buttonComponentProps:{disabled:n(Hr),click:Br.toggle,graphIsOpened:R()},tooltipText:n(sr)}:void 0),Si=f(()=>n(Sr)?{id:"liveButton",type:"desktop-control-panel-left",weight:Ws.liveButton,buttonComponent:Tc,buttonComponentProps:{isLiveActive:n($n),ariaLabel:n(Di)},tooltipText:n(Di),disabled:n($n)&&l()===ol.PlaybackState.PLAYING}:void 0),ko=f(()=>[n(qo),n(Wn),n(Kr),n(qr),n(Kn),n(ot),n(Zt),n(Si)].filter(gt=>!!gt).sort(Qa)),Cn=f(()=>n(Ur)?{id:"vkLogo",type:"desktop-control-panel-right",weight:qs.vkLogo,buttonComponent:fc,buttonComponentProps:{targetUrl:ei(),logoClickable:e.logoClickable,click:Se},tooltipText:n(uo),disabledTooltipContent:"",disabled:!e.logoClickable}:void 0),qn=f(()=>n(_t)?{id:"autoplayNext",type:"desktop-control-panel-right",weight:qs.autoplayNext,buttonComponent:wc,tooltipText:n(xn)}:void 0),Qo=f(()=>({id:"volume",type:"desktop-control-panel-right",weight:qs.volume,buttonComponent:Hm,buttonComponentProps:{click:Ko,isAds:It()}})),dr=f(()=>n(ii)?{id:"subtitles",type:"desktop-control-panel-right",weight:qs.subtitles,buttonComponent:Om,buttonComponentProps:{isSubtitlesEnabled:n(xr),click:Tt},tooltipText:n(dn)}:void 0),ps=f(()=>n(Fr)?{id:"settings",type:"desktop-control-panel-right",weight:qs.settings,buttonComponent:Jl,buttonComponentProps:{ref$:Eo},tooltipText:ue()?void 0:ut("tooltip_settings_off")}:void 0),Pr=f(()=>Me.features.contextMenuButton?{id:"context",type:"desktop-control-panel-right",weight:qs.context,buttonComponent:ev,buttonComponentProps:{ariaLabel:ut("aria_label_context_menu")},className:n(Cr)?"":"out-of-view",tooltipText:n(yn)}:void 0),Cs=f(()=>n(Bn)?{id:"fullscreen",type:"desktop-control-panel-right",weight:qs.fullscreen,buttonComponent:pc,buttonComponentProps:{isFullscreen:P(),click:e.toggleFullscreen},tooltipText:n(ar)}:void 0),Ys=f(()=>n(Nn)?{id:"chromecast",type:"desktop-control-panel-right",weight:qs.chromecast,buttonComponent:vc,buttonComponentProps:{state:p(),click:bn},tooltipText:n(Tr)}:void 0),xa=f(()=>[n(Cn),n(qn),n(Qo),n(dr),n(ps),n(Pr),n(Cs),n(Ys),...D()].filter(gt=>!!gt).sort(Qa)),mt=q.ui.previewTrackActive,ai=q.ui.previewTrackDragInProgress,Ao=q.ui.previewTrackAvailable,Ci=q.ui.isPreviewTrackHorizontallyAligned,to=f(()=>Qb({onPreviewTrackOpened:q.actions.internal.previewTrackOpened,getTimelineRef:()=>je.timeline,isHorizontal:xe()})),Ts=f(()=>n(to).progressBarY),Is=f(()=>n(to).controlsY),Es=f(()=>n(to).onPointerDown),qi=f(()=>n(to).onPointerMove),Ai=f(()=>n(to).onPointerUp),he=f(()=>n(to).calculatedHeight),Ct=f(()=>n(to).closePreviewTrack);Fe(()=>{pe()||n(Ct)()});let Jt;Ot(()=>()=>Jt&&clearTimeout(Jt));let oi=gt=>{pe()||!Je()||(n(Es)(gt),Jt=setTimeout(()=>{q.actions.internal.previewTrackDragStarted()},200))},Go=()=>{pe()||n(Ai)(),Jt&&clearTimeout(Jt),Pe()&&q.actions.internal.previewTrackDragFinished()},mo=gt=>{n(qi)(gt)};var io=gw(),Qn=le(io);let Qr;var Ps=T(Qn);{var ml=gt=>{let ht=f(()=>n(Ts)()),oo=f(()=>n(he)());gv(gt,{get animatedOffsetY(){return n(ht)},get animatedPreviewTrackHeight(){return n(oo)},get canRewindLive(){return e.canRewindLive},get isAds(){return It()},onTimelineMove:mo,onTimelinePointerDown:oi,onTimelinePointerUp:Go,get previewTrackAvailable(){return Je()},get timelineRef(){return je.timeline},set timelineRef(Vi){je.timeline=Vi}})};V(Ps,gt=>{e.showControls&>(ml)})}var Gr=k(Ps,2),fs=T(Gr),js=T(fs);xi(js,17,()=>n(ko),gt=>gt.id,(gt,ht)=>{_p(gt,{get buttonComponent(){return n(ht).buttonComponent},get buttonComponentProps(){return n(ht).buttonComponentProps},get tooltipText(){return n(ht).tooltipText},get disabledTooltipContent(){return n(ht).disabledTooltipContent},get disabled(){return n(ht).disabled},get className(){return n(ht).className},get tooltipEnabled(){return n(ht).tooltipEnabled},get mouseEnter(){return n(ht).mouseEnter},get mouseLeave(){return n(ht).mouseLeave},get tooltipVisible(){return e.showControls},get ref(){return je[n(ht).id]},set ref(oo){je[n(ht).id]=oo}})});var cr=k(js,2);{var vd=gt=>{let ht=f(()=>!e.showControls),oo=f(()=>It()?we():Ne()),Vi=f(()=>It()?Pt():kt());dc(gt,{get isHidden(){return n(ht)},isMobile:!1,get showDuration(){return n(fi)},get position(){return n(oo)},get duration(){return n(Vi)},get ref(){return je.time},set ref(no){je.time=no}})};V(cr,gt=>{n(Hn)&>(vd)})}var vl=k(cr,2);let Yr=f(()=>!n(an));Oo(vl,{className:"w-max",get disabled(){return n(Yr)},get tooltipContent(){return Sn},get tooltipVisible(){return e.showControls},get ref(){return je.episodes},set ref(gt){je.episodes=gt},children:(gt,ht)=>{var oo=Oe(),Vi=le(oo);{var no=bi=>{gc(bi,{get position(){return Ne()},get duration(){return kt()},get timeCodes(){return hi}})};V(Vi,bi=>{n(an)&&bi(no)})}$(gt,oo)},$$slots:{default:!0}}),S(fs);var wa=k(fs,2);xi(wa,21,()=>n(xa),gt=>gt.id,(gt,ht)=>{var oo=Oe(),Vi=le(oo);{var no=Qi=>{_p(Qi,{get buttonComponent(){return n(ht).buttonComponent},get buttonComponentProps(){return n(ht).buttonComponentProps},get tooltipText(){return n(ht).tooltipText},get disabledTooltipContent(){return n(ht).disabledTooltipContent},get disabled(){return n(ht).disabled},get className(){return n(ht).className},get tooltipVisible(){return e.showControls},get ref(){return je[n(ht).id]},set ref(Xs){je[n(ht).id]=Xs}})},bi=Qi=>{let Xs=f(()=>!!n(ht).disabled);sv(Qi,{get id(){return n(ht).id},get testId(){return n(ht).testId},get icon(){return n(ht).icon},get ariaLabel(){return n(ht).ariaLabel},get tooltipText(){return n(ht).tooltipText},get disabledTooltipContent(){return n(ht).disabledTooltipContent},get disabled(){return n(Xs)},get onClick(){return n(ht).onClick},get disableMouseupTooltipShow(){return n(ht).disableMouseupTooltipShow},get tooltipVisible(){return e.showControls},get ref(){return je[n(ht).id]},set ref(hd){je[n(ht).id]=hd}})};V(Vi,Qi=>{Wb(n(ht))?Qi(no):Qi(bi,!1)})}$(gt,oo)}),S(wa),S(Gr),it(Gr,gt=>pt(gt),()=>pt()),S(Qn),it(Qn,gt=>Lt(gt),()=>Lt());var gd=k(Qn,2);{var gl=gt=>{$c(gt,{get ref(){return je.interactiveTimeIndicator},set ref(ht){je.interactiveTimeIndicator=ht}})};V(gd,gt=>{as&>(gl)})}N((gt,ht)=>{Qr=oe(Qn,1,"wrapper-bottom s-1e",null,Qr,gt),Qe(Qn,`transform: ${e.showControls?"translateY(0)":"translateY(100%)"}`),Qe(Gr,ht),Gr.inert=pe()},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth||Pe()}),()=>`transform: translateY(${n(Is)()}px);`]),kn(fs,"clientWidth",gt=>O(lr,gt)),$(i,io),H(),o()}var sd=require("@vkontakte/videoplayer-core/es2015");var bv=require("@vkontakte/videoplayer-shared/es2015");var _w=L('<div class="icon icon-error-stub s-1z"><div class="inner s-1z"></div></div>'),bw=L('<img class="icon s-1z" aria-hidden="true"/>'),$w={hash:"s-1z",code:".icon.s-1z{height:24px!important;width:24px!important}.inner.s-1z{background-color:var(--white);height:16px;width:16px}"};function $v(i,e){Q(i,$w);let t=h(e,"disabled",3,!1),o=h(e,"onClick",3,bv.noop),r=f(()=>o()===bv.noop),a=f(()=>n(r)||t()),l=K(!1),d=()=>{O(l,!0)},s=f(()=>n(r)?"btn-full-opacity":"");Kt(i,{get className(){return n(s)},get ariaLabel(){return e.ariaLabel},get click(){return o()},get disabled(){return n(a)},get testId(){return e.testId},children:(u,m)=>{var p=Oe(),v=le(p);{var b=_=>{var x=_w();$(_,x)},y=_=>{var x=bw();N(()=>De(x,"src",e.iconUrl)),vt("error",x,d),Da(x),$(_,x)};V(v,_=>{n(l)?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}})}var yw=Ee('<path d="M8.7 8.1 5.3 4.72A1 1 0 0 1 6.72 3.3L20.7 17.29a1 1 0 0 1-1.41 1.41L16 15.41V20a1 1 0 0 1-1 1c-.64 0-1.26-.25-1.72-.7L7.79 15H5a2 2 0 0 1-2-2v-2a2 2 0 0 1 2-2h2.77zm2.88-2.76 1.7-1.65A2.5 2.5 0 0 1 15 3a1 1 0 0 1 1 1v5.76z"></path>');function yv(i){Ze(i,{testId:"muted-icon",children:(e,t)=>{var o=yw();$(e,o)},$$slots:{default:!0}})}var Zb=require("@vkontakte/videoplayer-shared/es2015");function yp(i,e){B(e,!0);let t=h(e,"muted",3,!1),o=h(e,"click",3,Zb.noop),r=h(e,"ref",15,void 0),l=$e().ui.t,d=f(()=>t()?l("tooltip_volume"):l("tooltip_volume_muted")),s=f(()=>t()?"btn-mobile-muted":"btn-mobile-unmuted");Kt(i,{get testId(){return n(s)},get click(){return o()},get ariaLabel(){return n(d)},role:"button",get ref(){return r()},set ref(u){r(u)},children:(u,m)=>{var p=Oe(),v=le(p);{var b=_=>{yv(_,{})},y=_=>{ha(_,{get size(){return"24"}})};V(v,_=>{t()?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}var xw=Ee('<path d="M11.64 12.37 9.07 9.8h1.03a.9.9 0 1 0 0-1.8H6.9a.9.9 0 0 0-.9.9v3.2a.9.9 0 0 0 1.8 0v-1.02l2.53 2.52.13.14a.9.9 0 0 0 1.28-1.28z"></path>'),ww=Ee('<path d="m6.36 9.63 2.57 2.57H7.9a.9.9 0 1 0 0 1.8h3.2a.9.9 0 0 0 .9-.9V9.9a.9.9 0 0 0-1.8 0v1.02L7.67 8.4l-.13-.14a.9.9 0 0 0-1.28 1.28z"></path>'),Sw=Ee('<path d="M7.66 4h6.68q1.2-.01 2 .04.83.06 1.53.38a4 4 0 0 1 1.7 1.7c.24.48.34.98.39 1.54q.05.8.04 2v1.44a.9.9 0 0 1-1.8 0V9.7c0-.85 0-1.44-.04-1.9-.03-.44-.1-.68-.19-.85a2 2 0 0 0-.92-.92 2 2 0 0 0-.85-.2c-.46-.03-1.04-.03-1.9-.03H7.7c-.85 0-1.44 0-1.9.04-.44.03-.68.1-.85.19a2 2 0 0 0-.92.92c-.09.17-.16.4-.2.85-.03.46-.03 1.05-.03 1.9v2.65c0 .85 0 1.44.04 1.9.03.44.1.68.19.85a2 2 0 0 0 .92.92c.17.08.4.15.85.19.46.03 1.04.04 1.9.04h2.4a.9.9 0 0 1 0 1.8H7.66q-1.2.01-2-.05a4 4 0 0 1-1.53-.38 4 4 0 0 1-1.7-1.7 4 4 0 0 1-.39-1.53q-.05-.8-.04-2V9.65q-.01-1.2.04-2c.05-.56.15-1.06.39-1.53a4 4 0 0 1 1.7-1.7c.47-.24.97-.34 1.53-.39q.8-.05 2-.04M13 16.8c0-.98 0-1.47.19-1.84a2 2 0 0 1 .77-.77c.37-.19.86-.19 1.84-.19h3.4c.98 0 1.47 0 1.85.19q.5.27.76.77c.19.37.19.86.19 1.84v.4c0 .98 0 1.47-.19 1.85a2 2 0 0 1-.77.76c-.37.19-.86.19-1.84.19h-3.4c-.98 0-1.47 0-1.85-.19a2 2 0 0 1-.76-.76c-.19-.38-.19-.87-.19-1.85z"></path><!>',1);function xv(i,e){let t=h(e,"isActive",3,!1),o=f(()=>t()?"pip-icon--active":"pip-icon");Ze(i,{get testId(){return n(o)},children:(r,a)=>{var l=Sw(),d=k(le(l));{var s=m=>{var p=xw();$(m,p)},u=m=>{var p=ww();$(m,p)};V(d,m=>{t()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}var Jb=require("@vkontakte/videoplayer-shared/es2015");function wv(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"isPictureInPictureActive",3,!1),r=h(e,"click",3,Jb.noop),a=Y("menu_pip");Kt(i,{testId:"btn-pip",get ariaLabel(){return a},get click(){return r()},get ref(){return t()},set ref(l){t(l)},children:(l,d)=>{xv(l,{get isActive(){return o()}})},$$slots:{default:!0}}),H()}var Sv=require("@vkontakte/videoplayer-shared/es2015");var Cw=(i,e,t,o)=>{n(e)&&t.onDisabledPlayPrevChapterClick(n(o))},Tw=(i,e,t,o)=>{n(e)&&t.onDisabledSeekToInteractiveClick(n(o))},Iw=L("<div><!></div>"),Ew=L("<div><!></div>"),Pw=L("<div><!></div>"),kw=L("<!> <!> <!>",1),Aw=L("<div></div> <div></div> <div><!> <!> <!> <!> <!> <!></div> <div><!> <!> <!> <!></div> <!>",1),Lw=L('<div class="wrapper-middle s-1d"><!></div>'),Mw=L("<div><!></div> <!> <div><!></div>",1),Vw=L('<div aria-hidden="true">·</div> <!>',1),Rw=L('<!> <!> <div><div><div class="controls mobile s-1d" data-testid="bottom-controls"><div class="controls-group contain s-1d"><!> <!> <!> <!></div> <div class="controls-group s-1d"><!> <!> <!></div></div> <!></div></div> <!>',1),Ow={hash:"s-1d",code:".wrapper-bottom.s-1d{background:var(--controls-gradient);bottom:0;box-sizing:border-box;display:flex;flex-direction:column;height:var(--controls-gradient-height);justify-content:flex-end;left:0;padding:0 4px 8px;pointer-events:none;position:absolute;transition:transform var(--controls-transition-duration) var(--controls-transition-fn);width:100%;z-index:var(--controls-container-z-index)}.wrapper-bottom.s-1d>:where(.s-1d){pointer-events:auto}.wrapper-bottom.ads-timeline-mobile.s-1d{height:9px;padding:0 4px 4px}.wrapper-middle.s-1d{align-items:center;left:50%;top:50%;transform:translate(-50%,-50%)}.wrapper-middle.s-1d,.wrapper-top-right.s-1d{display:flex;position:absolute;transition:opacity var(--controls-transition-duration);z-index:var(--controls-container-z-index)}.wrapper-top-right.s-1d{right:8px;top:4px}.wrapper-top-left.s-1d{left:8px;position:absolute;top:4px;z-index:var(--controls-container-z-index)}.wrapper-middle-left.s-1d,.wrapper-middle-left-second.s-1d,.wrapper-middle-right.s-1d{align-items:center;background-color:rgba(0,0,0,.56);border-radius:12px;display:flex;height:44px;justify-content:center;position:absolute;top:50%;transform:translateY(-50%);transition:opacity var(--controls-transition-duration);width:44px}.wrapper-middle-left.s-1d{left:12px}.wrapper-middle-left-second.s-1d{left:64px}.wrapper-middle-right.s-1d{right:12px}.controls.s-1d{align-items:center;box-sizing:border-box;font-size:13px;height:var(--controls-height);justify-content:space-between;padding:0 4px;transition:transform var(--controls-transition-duration) var(--controls-transition-fn);white-space:nowrap;width:100%;will-change:transform}.controls.s-1d,.controls-group.s-1d{display:flex}.controls-group.contain.s-1d{min-width:0}.controls-group.s-1d >:not(:first-child){margin-left:8px}.hidden.s-1d{opacity:0;visibility:hidden}.controls-hidden.s-1d{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-1d{transition:none}.overlay-mobile.s-1d{background-color:rgba(0,0,0,.3);height:100%;left:0;pointer-events:none;position:absolute;top:0;transition:opacity var(--controls-transition-duration);width:100%}@media screen and (orientation:portrait){.wrapper-top-left.fullscreen.s-1d,.wrapper-top-right.fullscreen.s-1d{top:16px}.controls-wrapper.fullscreen.s-1d{bottom:30px;position:absolute;width:calc(100% - 8px)}}@media screen and (orientation:landscape){.wrapper-top-left.fullscreen.s-1d{left:44px;top:12px}.wrapper-top-right.fullscreen.s-1d{right:44px;top:12px}.wrapper-middle-left.fullscreen.s-1d{left:44px}.wrapper-middle-left-second.fullscreen.s-1d{left:96px}.wrapper-middle-right.fullscreen.s-1d{right:44px}.controls-wrapper.fullscreen.s-1d{bottom:32px;left:36px;position:absolute;right:36px;width:calc(100% - 72px)}}"};function Cv(i,e){var un,Mi;B(e,!0),Q(i,Ow);let[t,o]=He(),r=()=>w(Oi,"$seekToInteractiveDisabledTooltip$",t),a=()=>w(Ht,"$disabledControls$",t),l=()=>w(Ft,"$playbackState$",t),d=()=>w(rn,"$adPlaybackState",t),s=()=>w(q,"$isEnded$",t),u=()=>w(yt,"$playerSize",t),m=()=>w(Tt,"$scrubbingInProgress",t),p=()=>w(Ji,"$chromecastState$",t),v=()=>w(Be,"$isPictureInPictureActive",t),b=()=>w(qe,"$pictureInPictureType$",t),y=()=>w(ve,"$mobileNotReportControlHidden$",t),_=()=>w(ui,"$chromecastHidden",t),x=()=>w(pt,"$playerPhase",t),I=()=>w(bo,"$pipHidden",t),C=()=>w(rt,"$currentGridType$",t),R=()=>w(ci,"$vkLogoHidden",t),A=()=>w(di,"$volumeHidden",t),P=()=>w(Le,"$isLive$",t),E=()=>w(ct,"$settingsMenuVisible",t),W=()=>w(Se,"$isRewindableLive$",t),F=()=>w(Ue,"$isActiveLive$",t),U=()=>w(Bt,"$isAudioAvailable$",t),X=()=>w(ye,"$muted$",t),se=()=>w(Me,"$volume$",t),j=()=>w(yi,"$isInteractiveTime$",t),ne=()=>w(rr,"$settingButtonRef$",t),Z=()=>w(hi,"$startedByKeyboard$",t),Te=()=>w(No,"$isFullscreen",t),fe=()=>w(Ut,"$additionalButtons$",t),te=()=>w(Li,"$autoplayNextToggleHidden",t),_e=()=>w(ft,"$crashed$",t),Ce=()=>w($o,"$settingsHidden",t),me=()=>w(Rn,"$graphIsOpened$",t),ce=()=>w(Pi,"$adPosition",t),Ye=()=>w(st,"$adDuration",t),G=()=>w(ei,"$position$",t),D=()=>w(It,"$duration$",t),Xe=h(e,"playerControlsWrapperRef",15,void 0),re=h(e,"playerControlsRef",15,void 0),pe=h(e,"isAds",3,!1),ue=h(e,"logoTargetUrl",3,""),Ae=h(e,"isOneVideoPlaylist",3,!1),ze=h(e,"customFullscreenSupported",3,!0),ee=$e(),de=xo(),ke=Dt(),xe=ee.actions.internal.toggleMuted,Je=ee.actions.internal.togglePlay,Pe=ee.actions.internal.pause,we=ee.actions.internal.prevVideoClick,Ne=ee.actions.internal.nextVideoClick,Pt=ee.actions.internal.checkFullscreenSupport,kt=(un=ee.callbacks)==null?void 0:un.onAudioDoesNotExistHint,Lt=(Mi=ee.callbacks)==null?void 0:Mi.onAudioDisabledHint,pt=ee.playerPhase,It=ee.state.duration$,ei=ee.state.positionWithScrubbing$,Ft=ee.state.playbackState$,Bt=ee.state.isAudioAvailable$,qt=ee.state.isAudioDisabled,q=ee.state.isEnded$,Le=ee.state.isLive$,Me=ee.state.volume$,ye=ee.state.muted$,Ue=ee.state.isActiveLive$,Se=ee.state.isRewindableLive$,Tt=ee.ui.scrubbingInProgress,ve=ee.ui.mobileNotReportControlHidden$,{isActive$:Be,type$:qe}=de.pictureInPicture$,ct=ee.ui.settingsMenu.visible$,Xt=ee.ui.settingsMenu.openedByBtnKeyboard$,Mt=ee.ui.controls,{volume:di,vkLogo:ci,autoplayNextToggle:Li,pip:bo,settings:$o,chromecast:ui}=ee.ui.hiddenControls,at=ee.actions.internal.getVideoEpisodes(),pi=ee.webApi.pictureInPictureApi,Ji=ee.state.chromecastState$,ft=ee.state.crashed$,Ht=Mt.disabledControls$,hi=ee.ui.startedByKeyboard$,rt=ee.ui.currentGridType$,st=ee.ads.duration,Pi=ee.ads.position,rn=ee.ads.playbackState,No=ee.ui.isFullscreen,yt=ee.ui.playerSize,Ut=ee.ui.additionalButtonsDeprecated$,z=ee.actions.internal.getVideoElement,Vt=ee.actions.internal.replayInteractive,ut=ee.state.isInteractive,yi=ee.state.isInteractiveTime$,ti=ee.state.showInteractiveGraph,St=ee.state.showSeekToInteractive,lt=ee.state.showPlayPrevChapter,Ui=ee.state.showInteractiveTimeIndicator,Oi=de.seekToInteractiveDisabledTooltip$,Rn=de.graphIsOpened$,On=ee.ui.controlBlocks,Ii=f(()=>Y(ee.state.playPrevChapterDisabledTooltip)),eo=f(()=>Y(r())),Dn=f(()=>a().has("EPISODE_BUTTON")),wo=f(()=>a().has("GRAPH_BUTTON")),wi=f(()=>a().has("SEEK_TO_INTERACTIVE_BUTTON")),Bo=f(()=>a().has("PLAY_BUTTON")),Ho=f(()=>a().has("REPLAY_BUTTON")),yo=f(()=>a().has("PLAY_PREV_CHAPTER_BUTTON")),hn=f(()=>l()===sd.PlaybackState.PLAYING),as=f(()=>d()==="paused"),Nr=f(()=>s()&&!pe()&&!ut),ls=f(()=>!s()||pe()),Br=f(()=>e.showNextPrevButtons&&!pe()&&e.prevButtonActive),tr=f(()=>e.showNextPrevButtons&&!pe()&&e.nextButtonActive),ds=f(()=>u().width>300),Hr=f(()=>u().width>400),sn=f(m),_n=f(()=>p()!==sd.ChromecastState.NOT_AVAILABLE&&!(v()&&b()===1)&&!y()&&!ut&&!_()),$r=f(()=>x()==="LiveWaitingStart"),yr=f(()=>!!pi&&p()!==sd.ChromecastState.CONNECTED&&!y()&&(b()===1&&n($r)||!n($r))&&!n(sn)&&!ut&&!I()),bn=K(!1);Ot(()=>{let We=pi==null?void 0:pi.info.isActive$.subscribe(Rt=>O(bn,Rt,!0));return()=>We==null?void 0:We.unsubscribe()});let ir=f(()=>!n(sn)&&ao(C(),"s")),xr=f(()=>!e.logoHidden&&u().width>350&&!R()),or=f(()=>ke.features.fullscreen&&Pt()&&!(v()&&b()===1)&&(ut?ze():!0)&&!n(sn)&&!n(bn)),nr=f(()=>!A()&&!n(sn)),cs=f(()=>(!P()||pe())&&u().width>260&&!n(sn)&&!(ke.features.interactiveHideTime&&ut)),So=f(()=>E()||e.showControls),wr=f(()=>!pe()&&!P()&&!!(at!=null&&at.length)&&n(ds)&&!n(Dn)&&!n(sn)),zi=f(()=>!W()||!!F()),Sr=f(()=>ti&&ao(C(),"m")),Nn=f(()=>!U()||X()||se()===0),_t=li({}),ii=li({}),Cr=(0,Sv.debounceFn)(od,260),Fr=(0,Sv.debounceFn)(bp,260);Fe(()=>{u(),j(),Cr(z(),Mt,_t,e.showControls),Fr(z(),On,ii,e.showControls)});let Ur=()=>ee.actions.internal.toggleChromecast();function Bn(){return bt(this,null,function*(){pi!=null&&pi.isActive()?yield pi==null?void 0:pi.exit():yield pi==null?void 0:pi.request()})}function Hn(){ma({isAudioDisabled:qt,audioDisabledHintCallback:Lt,isAudioAvailable:U(),audioIsNotExistHintCallback:kt,isAds:pe()})&&xe()}let Fo=K(""),Fn=(We,Rt)=>{if(!We){O(Fo,Y("tooltip_live"),!0);return}Rt&&Rt===sd.PlaybackState.PAUSED&&O(Fo,Y("tooltip_play"),!0)};Fe(()=>{Fn(n(zi),l())});let rr=ae();Fe(()=>{ne()&&Gl(ne(),E(),Xt)}),Fe(()=>{hp(hi,Z(),_t.playButton)});var an=Rw(),$n=le(an);{var sr=We=>{var Rt=Aw(),fi=le(Rt);let Wo;var Io=k(fi,2);let Eo;it(Io,mt=>ii.topLeft=mt,()=>ii==null?void 0:ii.topLeft);var Ki=k(Io,2);let Ko;var zn=T(Ki);xi(zn,1,fe,({iconUrl:mt,ariaLabel:ai,testId:Ao,onClick:Ci,tooltip:to})=>mt,(mt,ai)=>{let Ao=()=>n(ai).iconUrl,Ci=()=>n(ai).ariaLabel,to=()=>n(ai).testId,Ts=()=>n(ai).onClick,Is=()=>n(ai).tooltip,Es=f(()=>{var qi;return(qi=Ci())!=null?qi:Is()});$v(mt,{get iconUrl(){return Ao()},get ariaLabel(){return n(Es)},get testId(){return to()},get onClick(){return Ts()}})});var Er=k(zn,2);{var Po=mt=>{wc(mt,{get ref(){return _t.autoplayNextToggle},set ref(ai){_t.autoplayNextToggle=ai}})};V(Er,mt=>{e.showAutoplayNext&&!Ae()&&!te()&&mt(Po)})}var fo=k(Er,2);{var Sn=mt=>{vc(mt,{isMobile:!0,click:Ur,get state(){return p()},get ref(){return _t.chromecast},set ref(ai){_t.chromecast=ai}})};V(fo,mt=>{n(_n)&&mt(Sn)})}var qo=k(fo,2);{var Wn=mt=>{wv(mt,{click:Bn,get isPictureInPictureActive(){return v()},get ref(){return _t.pip},set ref(ai){_t.pip=ai}})};V(qo,mt=>{n(yr)&&mt(Wn)})}var Kr=k(qo,2);{var qr=mt=>{Jl(mt,{get ref$(){return rr}})};V(Kr,mt=>{_e()&&!Ce()&&mt(qr)})}var Kn=k(Kr,2);{var ot=mt=>{fc(mt,{get click(){return Pe},get targetUrl(){return ue()},get logoClickable(){return e.logoClickable},get ref(){return _t.vkLogo},set ref(ai){_t.vkLogo=ai}})};V(Kn,mt=>{n(xr)&&mt(ot)})}S(Ki),it(Ki,mt=>ii.topRight=mt,()=>ii==null?void 0:ii.topRight);var Zt=k(Ki,2);let Si;var ko=T(Zt);{var Cn=mt=>{let ai=f(()=>we.bind(null,!0));el(mt,{get click(){return n(ai)},type:"prev",isMobile:!0,get ref(){return _t.prevButton},set ref(Ao){_t.prevButton=Ao}})};V(ko,mt=>{n(Br)&&mt(Cn)})}var qn=k(ko,2);{var Qo=mt=>{rd(mt,{get disabled(){return n(Bo)},get click(){return Je},isMobile:!0,get isPlaying(){return n(hn)},get ref(){return _t.playButton},set ref(ai){_t.playButton=ai}})};V(qn,mt=>{n(ls)&&mt(Qo)})}var dr=k(qn,2);{var ps=mt=>{nd(mt,{get disabled(){return n(Ho)},get click(){return Je},isMobile:!0,get ref(){return _t.replayButton},set ref(ai){_t.replayButton=ai}})};V(dr,mt=>{n(Nr)&&mt(ps)})}var Pr=k(dr,2);{var Cs=mt=>{let ai=f(()=>Ne.bind(null,!0));el(mt,{get click(){return n(ai)},type:"next",isMobile:!0,get ref(){return _t.nextButton},set ref(Ao){_t.nextButton=Ao}})};V(Pr,mt=>{n(tr)&&mt(Cs)})}S(Zt),it(Zt,mt=>ii.middle=mt,()=>ii==null?void 0:ii.middle);var Ys=k(Zt,2);{var xa=mt=>{var ai=kw(),Ao=le(ai);{var Ci=qi=>{var Ai=Iw();let he;Ai.__click=[Cw,yo,e,Ii];var Ct=T(Ai);let Jt=f(()=>!e.showControls);xc(Ct,{get hidden(){return n(Jt)},get disabled(){return n(yo)},get click(){return e.playPrevChapter},get ref(){return _t.playPrevChapterButton},set ref(oi){_t.playPrevChapterButton=oi}}),S(Ai),N(oi=>he=oe(Ai,1,"wrapper-middle-left s-1d",null,he,oi),[()=>({fullscreen:Te(),hidden:!e.showControls})]),$(qi,Ai)};V(Ao,qi=>{lt&&qi(Ci)})}var to=k(Ao,2);{var Ts=qi=>{var Ai=Ew();let he;var Ct=T(Ai);let Jt=f(()=>!e.showControls&&!me());Cc(Ct,{get hidden(){return n(Jt)},get disabled(){return n(wo)},get click(){return Rn.toggle},get graphIsOpened(){return me()},get ref(){return _t.interactiveGraphButton},set ref(oi){_t.interactiveGraphButton=oi}}),S(Ai),N(oi=>he=oe(Ai,1,Fd(lt?"wrapper-middle-left-second":"wrapper-middle-left"),"s-1d",he,oi),[()=>({fullscreen:Te(),hidden:!e.showControls&&!me()})]),$(qi,Ai)};V(to,qi=>{n(Sr)&&qi(Ts)})}var Is=k(to,2);{var Es=qi=>{var Ai=Pw();let he;Ai.__click=[Tw,wi,e,eo];var Ct=T(Ai);let Jt=f(()=>!e.showControls);Sc(Ct,{get hidden(){return n(Jt)},get disabled(){return n(wi)},get click(){return e.seekToInteractive},get ref(){return _t.seekToInteractiveButton},set ref(oi){_t.seekToInteractiveButton=oi}}),S(Ai),N(oi=>he=oe(Ai,1,"wrapper-middle-right s-1d",null,he,oi),[()=>({fullscreen:Te(),hidden:!e.showControls})]),$(qi,Ai)};V(Is,qi=>{St&&qi(Es)})}$(mt,ai)};V(Ys,mt=>{ut&&!m()&&mt(xa)})}N((mt,ai,Ao,Ci)=>{Wo=oe(fi,1,"overlay-mobile s-1d",null,Wo,mt),Eo=oe(Io,1,"wrapper-top-left s-1d",null,Eo,ai),Ko=oe(Ki,1,"wrapper-top-right s-1d",null,Ko,Ao),Si=oe(Zt,1,"wrapper-middle s-1d",null,Si,Ci)},[()=>({hidden:!n(So)}),()=>({hidden:!e.showControls,fullscreen:Te()}),()=>({hidden:!e.showControls&&!y(),fullscreen:Te()}),()=>({hidden:!e.showControls||m()||e.endScreenShown&&e.showNextPrevButtons})]),$(We,Rt)};V($n,We=>{pe()||We(sr)})}var yn=k($n,2);{var ln=We=>{var Rt=Mw(),fi=le(Rt);let Wo;var Io=T(fi);yp(Io,{get muted(){return X()},click:Hn,get ref(){return _t.volume},set ref(Po){_t.volume=Po}}),S(fi);var Eo=k(fi,2);{var Ki=Po=>{var fo=Lw(),Sn=T(fo);let qo=f(()=>!n(as));rd(Sn,{get disabled(){return n(Bo)},get click(){return Je},isMobile:!0,get isPlaying(){return n(qo)},get ref(){return _t.playButton},set ref(Wn){_t.playButton=Wn}}),S(fo),$(Po,fo)};V(Eo,Po=>{n(as)&&Po(Ki)})}var Ko=k(Eo,2);let zn;var Er=T(Ko);Ic(Er,{get position(){return ce()},get duration(){return Ye()}}),S(Ko),N((Po,fo)=>{Wo=oe(fi,1,"wrapper-top-right s-1d",null,Wo,Po),zn=oe(Ko,1,"wrapper-bottom ads-timeline-mobile s-1d",null,zn,fo)},[()=>({fullscreen:Te()}),()=>({fullscreen:Te()})]),$(We,Rt)};V(yn,We=>{pe()&&d()!=="inactive"&&We(ln)})}var Di=k(yn,2);let uo;var dn=T(Di);let ar;var Tr=T(dn),xn=T(Tr),lr=T(xn);{var je=We=>{Oo(We,{get disabled(){return n(Ho)},get ref(){return _t.replayButton},set ref(Rt){_t.replayButton=Rt},children:(Rt,fi)=>{nd(Rt,{get disabled(){return n(Ho)},get click(){return Vt}})},$$slots:{default:!0}})};V(lr,We=>{ut&&We(je)})}var _i=k(lr,2);{var Uo=We=>{Oo(We,{get ref(){return _t.liveButton},set ref(Rt){_t.liveButton=Rt},children:(Rt,fi)=>{Tc(Rt,{get isLiveActive(){return n(zi)},isMobile:!0,get ariaLabel(){return n(Fo)}})},$$slots:{default:!0}})};V(_i,We=>{!pe()&&P()&&We(Uo)})}var wn=k(_i,2);{var Co=We=>{let Rt=f(()=>pe()?ce():G()),fi=f(()=>pe()?Ye():D()),Wo=f(()=>!e.showControls);dc(We,{get showDuration(){return n(Hr)},get position(){return n(Rt)},get duration(){return n(fi)},isMobile:!0,get isHidden(){return n(Wo)},get ref(){return _t.time},set ref(Io){_t.time=Io}})};V(wn,We=>{n(cs)&&We(Co)})}var cn=k(wn,2);let po=f(()=>!n(wr));Oo(cn,{className:"w-max",get disabled(){return n(po)},get ref(){return _t.episodes},set ref(We){_t.episodes=We},children:(We,Rt)=>{var fi=Oe(),Wo=le(fi);{var Io=Eo=>{var Ki=Vw(),Ko=k(le(Ki),2);gc(Ko,{get position(){return G()},get duration(){return D()},get timeCodes(){return at}}),$(Eo,Ki)};V(Wo,Eo=>{n(wr)&&Eo(Io)})}$(We,fi)},$$slots:{default:!0}}),S(xn),it(xn,We=>ii.bottomLeft=We,()=>ii==null?void 0:ii.bottomLeft);var To=k(xn,2),ki=T(To);{var zr=We=>{Oo(We,{get ref(){return _t.volume},set ref(Rt){_t.volume=Rt},children:(Rt,fi)=>{yp(Rt,{get muted(){return n(Nn)},click:Hn})},$$slots:{default:!0}})};V(ki,We=>{n(nr)&&We(zr)})}var Un=k(ki,2);{var ws=We=>{Oo(We,{get ref(){return _t.settings},set ref(Rt){_t.settings=Rt},children:(Rt,fi)=>{Jl(Rt,{get ref$(){return rr}})},$$slots:{default:!0}})};V(Un,We=>{n(ir)&&We(ws)})}var Wi=k(Un,2);{var Ss=We=>{Oo(We,{get ref(){return _t.fullscreen},set ref(Rt){_t.fullscreen=Rt},children:(Rt,fi)=>{pc(Rt,{get click(){return e.toggleFullscreen},get isFullscreen(){return Te()}})},$$slots:{default:!0}})};V(Wi,We=>{n(or)&&We(Ss)})}S(To),it(To,We=>ii.bottomRight=We,()=>ii==null?void 0:ii.bottomRight),S(Tr),it(Tr,We=>re(We),()=>re());var us=k(Tr,2);let Ir=f(()=>!e.showControls);il(us,{get isHidden(){return n(Ir)},get isAds(){return pe()},get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return W()},get ref(){return _t.timeline},set ref(We){_t.timeline=We}}),S(dn),it(dn,We=>ii.bottom=We,()=>ii==null?void 0:ii.bottom),S(Di),it(Di,We=>Xe(We),()=>Xe());var zo=k(Di,2);{var Wr=We=>{$c(We,{get ref(){return _t.interactiveTimeIndicator},set ref(Rt){_t.interactiveTimeIndicator=Rt}})};V(zo,We=>{Ui&&We(Wr)})}N((We,Rt)=>{uo=oe(Di,1,"wrapper-bottom mobile s-1d",null,uo,We),ar=oe(dn,1,"controls-wrapper s-1d",null,ar,Rt)},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth}),()=>({fullscreen:Te()})]),$(i,an),H(),o()}et(["click"]);function Ec(i,e){B(e,!0);let[t,o]=He(),r=()=>w(I,"$isMobile",t),a=h(e,"bottomNoSmooth",3,!1),l=h(e,"playerControlsWrapperRef",15,void 0),d=h(e,"playerControlsRef",15,void 0),s=h(e,"isAds",3,!1),u=h(e,"logoTargetUrl",3,""),m=h(e,"showAutoplayNext",3,!1),p=h(e,"isOneVideoPlaylist",3,!1),v=h(e,"customFullscreenSupported",3,!0),b=h(e,"endScreenShown",3,!1),y=h(e,"onDisabledPlayPrevChapterClick",3,Tv.noop),_=h(e,"onDisabledSeekToInteractiveClick",3,Tv.noop),I=$e().ui.isMobile,C=K(!1);Ot(()=>{let E=setTimeout(()=>O(C,!0),0);return()=>clearTimeout(E)});var R=Oe(),A=le(R);{var P=E=>{var W=Oe(),F=le(W);{var U=se=>{Cv(se,{get bottomHidden(){return e.bottomHidden},get bottomNoSmooth(){return a()},get showControls(){return e.showControls},get isAds(){return s()},get canRewindLive(){return e.canRewindLive},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return u()},get showAutoplayNext(){return m()},get showNextPrevButtons(){return e.showNextPrevButtons},get nextButtonActive(){return e.nextButtonActive},get prevButtonActive(){return e.prevButtonActive},get isOneVideoPlaylist(){return p()},get customFullscreenSupported(){return v()},get endScreenShown(){return b()},get toggleFullscreen(){return e.toggleFullscreen},get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get onDisabledPlayPrevChapterClick(){return y()},get onDisabledSeekToInteractiveClick(){return _()},get playerControlsWrapperRef(){return l()},set playerControlsWrapperRef(j){l(j)},get playerControlsRef(){return d()},set playerControlsRef(j){d(j)}})},X=se=>{_v(se,{get bottomHidden(){return e.bottomHidden},get bottomNoSmooth(){return a()},get showControls(){return e.showControls},get isAds(){return s()},get canRewindLive(){return e.canRewindLive},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return u()},get isOneVideoPlaylist(){return p()},get showAutoplayNext(){return m()},get showNextPrevButtons(){return e.showNextPrevButtons},get nextButtonActive(){return e.nextButtonActive},get prevButtonActive(){return e.prevButtonActive},get customFullscreenSupported(){return v()},get toggleFullscreen(){return e.toggleFullscreen},get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get playerControlsWrapperRef(){return l()},set playerControlsWrapperRef(j){l(j)},get playerControlsRef(){return d()},set playerControlsRef(j){d(j)}})};V(F,se=>{r()?se(U):se(X,!1)})}$(E,W)};V(A,E=>{n(C)&&E(P)})}$(i,R),H(),o()}var Dw=Ee('<path d="M23.75 31.2v-5.45l-11.84 6.7a1.45 1.45 180 01-2.16-1.25v-14.4a1.45 1.45 180 012.16-1.26l11.84 6.7v-5.44a1.45 1.45 180 012.16-1.26l12.7 7.19a1.45 1.45 180 010 2.52l-12.7 7.2a1.45 1.45 180 01-2.16-1.27Z"></path>');function Pc(i,e){B(e,!0);let t=f(()=>e.reversed?"transform:scaleX(-1);transform-origin:50% 0;":""),o=f(()=>`${vn(e.size)}${n(t)}`);Ze(i,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(o)},get testId(){return e.testId},get shadow(){return e.shadow},children:(r,a)=>{var l=Dw();$(r,l)},$$slots:{default:!0}}),H()}var Nw=Ee('<path d="M32.46 9.53a1.16 1.16 90 010 1.96l-7.66 4.83c-.78.49-1.8-.07-1.8-.98v-3.3a14 14 90 1014.1 18.93 1.5 1.5 90 012.8 1.06 17 17 90 11-16.9-23V5.66c0-.91 1.03-1.47 1.8-.98z"></path>');function Iv(i,e){B(e,!0);let t=h(e,"reversed",3,!1),o=f(()=>t()?"transform:scaleX(-1);transform-origin: 50% 0;":void 0),r=f(()=>`seek-icon-${t()?"backward":"forward"}`);Ze(i,{get width(){return"48"},get height(){return"48"},get style(){return n(o)},get testId(){return n(r)},get shadow(){return e.shadow},children:(a,l)=>{var d=Nw();$(a,d)},$$slots:{default:!0}}),H()}var Bw=L('<span class="hot-key-helpers-text s-w"> </span>'),Hw=L('<div data-testid="hotkey-helper-icon" class="s-w"><!> <!> <!> <!> <!> <!> <!> <!> <!> <!></div> <!>',1),Fw=L("<div><!></div>"),Uw={hash:"s-w",code:'.hot-key-helpers-container.s-w{align-items:center;animation:s-w-fadeIn ease var(--controls-transition-duration);box-sizing:border-box;display:flex;flex-direction:column;height:120px;left:calc(50% - 100px);padding-top:14px;position:absolute;top:calc(50% - 40px);width:200px;z-index:var(--hot-key-helpers-container-z-index)}.hot-key-helpers-container--left.s-w{left:calc(25% - 100px)}.hot-key-helpers-container--right.s-w{left:calc(75% - 100px)}.hot-key-helpers-text.s-w{display:-webkit-box;font-feature-settings:"clig" off,"liga" off;font-size:15px;font-style:normal;font-weight:600;letter-spacing:-.105px;-webkit-line-clamp:2;line-height:20px;margin-top:4px;max-height:40px;overflow:hidden;text-align:center;text-overflow:ellipsis;text-shadow:0 0 5px rgba(0,0,0,.16);white-space:pre-wrap;width:100%;-webkit-box-orient:vertical}.hidden.s-w{animation:s-w-fadeOut ease var(--controls-transition-duration);height:0;visibility:hidden;width:0}@keyframes s-w-fadeIn{0%{opacity:0}to{opacity:1}}@keyframes s-w-fadeOut{0%{opacity:1}to{opacity:0}}'};function Ev(i,e){B(e,!0),Q(i,Uw);let[t,o]=He(),r=()=>w(e.data,"$data",t),a=$e(),{features:l}=Dt(),d=a.ui.t,s=f(()=>!r()),u=f(()=>{var I;return((I=r())==null?void 0:I.type)==="BACKWARD_SEEK"}),m=f(()=>{var I;return((I=r())==null?void 0:I.type)==="FORWARD_SEEK"}),p=f(()=>{var I;return(I=r())==null?void 0:I.type}),v=f(()=>{var I,C;return(I=r())!=null&&I.t?d(r().t.key,{value:r().t.value||""}):(C=r())==null?void 0:C.text});var b=Fw();let y;var _=T(b);{var x=I=>{var C=Hw(),R=le(C),A=T(R);{var P=re=>{let pe=f(()=>n(p)==="BACKWARD_SEEK");Iv(re,{get reversed(){return n(pe)},shadow:!0})};V(A,re=>{["BACKWARD_SEEK","FORWARD_SEEK"].includes(n(p))&&re(P)})}var E=k(A,2);{var W=re=>{Ks(re,{get size(){return"48"},shadow:!0})};V(E,re=>{n(p)==="PAUSE"&&!l.playbackStatusShow&&re(W)})}var F=k(E,2);{var U=re=>{Ln(re,{get size(){return"48"},shadow:!0})};V(F,re=>{n(p)==="PLAY"&&!l.playbackStatusShow&&re(U)})}var X=k(F,2);{var se=re=>{yc(re,{get size(){return"48"},shadow:!0})};V(X,re=>{n(p)==="REPLAY"&&!l.playbackStatusShow&&re(se)})}var j=k(X,2);{var ne=re=>{ga(re,{get size(){return"48"},type:"off",shadow:!0})};V(j,re=>{n(p)==="SUBTITLES_OFF"&&re(ne)})}var Z=k(j,2);{var Te=re=>{ga(re,{get size(){return"48"},shadow:!0})};V(Z,re=>{n(p)==="SUBTITLES_ON"&&re(Te)})}var fe=k(Z,2);{var te=re=>{let pe=f(()=>n(p)==="RATE_DOWN");Pc(re,{get size(){return"48"},get reversed(){return n(pe)},testId:"rate-change-icon",shadow:!0})};V(fe,re=>{["RATE_DOWN","RATE_UP"].includes(n(p))&&re(te)})}var _e=k(fe,2);{var Ce=re=>{let pe=f(()=>n(p)==="EPISODE_PREV");_a(re,{get size(){return"48"},get reversed(){return n(pe)},shadow:!0})};V(_e,re=>{["EPISODE_PREV","EPISODE_NEXT"].includes(n(p))&&re(Ce)})}var me=k(_e,2);{var ce=re=>{ha(re,{get size(){return"48"},volume:0,shadow:!0})};V(me,re=>{n(p)==="MUTE"&&re(ce)})}var Ye=k(me,2);{var G=re=>{ha(re,{get size(){return"48"},volume:1,shadow:!0})};V(Ye,re=>{n(p)==="VOLUME"&&re(G)})}S(R);var D=k(R,2);{var Xe=re=>{var pe=Bw(),ue=T(pe,!0);S(pe),N(()=>ge(ue,n(v))),$(re,pe)};V(D,re=>{n(v)&&re(Xe)})}N(()=>De(R,"data-type",n(p))),$(I,C)};V(_,I=>{!n(s)&&n(p)&&I(x)})}S(b),N(I=>y=oe(b,1,"hot-key-helpers-container s-w",null,y,I),[()=>({hidden:n(s),"hot-key-helpers-container--left":n(u),"hot-key-helpers-container--right":n(m)})]),$(i,b),H(),o()}var zw=(i,e,t,o,r,a)=>{if(e.has(i.code))switch(i.preventDefault(),i.stopPropagation(),i.code){case"ArrowUp":t();break;case"ArrowDown":o();break;case"ArrowLeft":r();break;case"ArrowRight":a();break}},Ww=(i,e,t)=>{e.has(i.code)&&(i.preventDefault(),i.stopPropagation(),t())},Kw=L('<div tabindex="0" role="button"><div class="button-block s-l" aria-hidden="true"><div class="button-row s-l"><div class="button button-up s-l"><!></div> <div class="button button-right s-l"><!></div></div> <div class="button-row s-l"><div class="button button-left s-l"><!></div> <div class="button button-down s-l"><!></div></div></div></div>'),qw={hash:"s-l",code:".immersive-controls.s-l{background-color:rgba(0,0,0,.56);border-radius:8px;display:flex;flex-direction:row;height:56px;left:10px;position:absolute;top:10px;transition-duration:var(--controls-transition-duration);transition-property:top,left;transition-timing-function:var(--controls-transition-fn);width:56px}.immersive-controls.m-shifted.s-l{left:20px;top:50px}.button-block.s-l{height:40px;margin:auto;transform:rotate(45deg);width:40px}.button-row.s-l{display:flex;flex-direction:row;position:relative}.button.s-l{cursor:pointer;height:20px;text-align:center;width:20px}.button.s-l svg{opacity:.7;transition:opacity .2s linear}.button.button-up.s-l svg{transform:rotate(-45deg) translate(-1px,-1px)}.button.button-right.s-l svg{transform:rotate(45deg) translate(1px,-1px)}.button.button-down.s-l svg{transform:rotate(135deg) translate(1px,-3px)}.button.button-left.s-l svg{transform:rotate(-135deg) translate(-1px,-3px)}.button.s-l:hover svg{opacity:1}"};function kc(i,e){B(e,!0),Q(i,qw);let t=h(e,"isShifted",3,!1),o=$e(),r=new Set(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"]),a=()=>{o.actions.internal.startCameraManualRotation(0,1)},l=()=>{o.actions.internal.startCameraManualRotation(0,-1)},d=()=>{o.actions.internal.startCameraManualRotation(1,0)},s=()=>{o.actions.internal.startCameraManualRotation(-1,0)},u=()=>(o.actions.internal.stopCameraManualRotation(),null),m=Y("aria_label_spherical_control");var p=Kw();let v;p.__keydown=[zw,r,a,l,s,d],p.__keyup=[Ww,r,u];var b=T(p),y=T(b),_=T(y);_.__mousedown=a,_.__mouseup=u;var x=T(_);Rr(x,{direction:"up",useBtnColor:!0}),S(_);var I=k(_,2);I.__mousedown=d,I.__mouseup=u;var C=T(I);Rr(C,{direction:"up",useBtnColor:!0}),S(I),S(y);var R=k(y,2),A=T(R);A.__mousedown=s,A.__mouseup=u;var P=T(A);Rr(P,{direction:"up",useBtnColor:!0}),S(A);var E=k(A,2);E.__mousedown=l,E.__mouseup=u;var W=T(E);Rr(W,{direction:"up",useBtnColor:!0}),S(E),S(R),S(b),S(p),N(F=>{v=oe(p,1,"immersive-controls s-l",null,v,F),De(p,"aria-label",m)},[()=>({"m-shifted":t()})]),vt("mouseleave",_,u),vt("mouseleave",I,u),vt("mouseleave",A,u),vt("mouseleave",E,u),$(i,p),H()}et(["keydown","keyup","mousedown","mouseup"]);var Qs=require("@vkontakte/videoplayer-shared/es2015");var e$=(i=1e3)=>{let e=null,t=()=>{e&&(clearTimeout(e),e=null)};return{add:o=>{t(),e=setTimeout(o,i)},clear:t}};var xp=class{constructor(){this.flickeringTimeout=e$(1e3);this.subscriptions=new Qs.Subscription;this.isAuto=!1;this.isLive=!1;this.captions$=new Qs.ValueSubject([]);this.captionsPrepared$=new Qs.ValueSubject([])}subscribe(){return this.subscriptions.add(this.captions$.pipe((0,Qs.filter)(()=>this.isEnabled()),(0,Qs.filterChanged)()).subscribe(e=>{this.processCaptions(e)})),this}setIsAuto(e){this.isAuto=e}setIsLive(e){this.isLive=e}setCaptions(e){this.captions$.next(e)}destroy(){this.subscriptions.unsubscribe(),this.flickeringTimeout.clear()}isEnabled(){return this.isAuto&&!this.isLive}processCaptions(e){if(!e.length){this.flickeringTimeout.add(()=>{this.captionsPrepared$.next([])});return}this.flickeringTimeout.clear();let t=[],o=e.length>1&&e[0].type!=="timestamp"&&e[1].type!=="timestamp";o&&t.push([{value:String(e[0].value),timeAppeared:null}]),t.push(e.reduce((r,{type:a,value:l},d)=>(o&&!d||(a==="timestamp"?r.push({timeAppeared:Number(l),value:""}):r.length===0?r.push({value:String(l)}):r[r.length-1].value=String(l)),r),[])),this.captionsPrepared$.next(t)}};var Qw=L('<span class="caption-line s-a"><span class="caption-segment s-a"> </span></span>'),Gw=L('<span class="caption-line s-a"><span class="caption-segment s-a"></span></span>'),Yw=L('<span class="caption-line s-a"><span class="caption-segment s-a"> </span></span>'),jw=L('<div><span class="caption s-a"><!></span></div>'),Xw=L("<div><!></div>"),Zw={hash:"s-a",code:".subtitles-container.s-a{height:100%;left:0;pointer-events:none;position:absolute;top:0;transition:transform var(--controls-transition-duration);width:100%}.subtitles-container.shifted.s-a{transform:translateY(calc(var(--controls-height)*-1))}.subtitles-container.preview-track-active.s-a{transform:translateY(calc(var(--preview-track-height)*-1))}.preview-track-active.s-a .subtitles-caption:where(.s-a){bottom:var(--preview-track-controls-top-offset)}.subtitles-caption.s-a{bottom:4%;display:flex;justify-content:center;left:4%;position:absolute;right:4%}.subtitles-caption.mobile.s-a{bottom:8%}.subtitles-container.auto.s-a .subtitles-caption:where(.s-a){left:var(--subtitles-caption-margin);right:var(--subtitles-caption-margin)}.caption.s-a{background:rgba(0,0,0,.4);border-radius:4px;display:block;overflow-wrap:normal;padding:4px 8px}.subtitles-container.auto.s-a .caption:where(.s-a){width:100%}.caption-line.s-a{display:block;text-align:center}.subtitles-container.auto.s-a .caption-line:where(.s-a){text-align:left}.caption-segment.s-a{color:var(--white);display:inline-block;font-size:13px;line-height:1.2;white-space:pre-wrap}"};function rl(i,e){B(e,!0),Q(i,Zw);let[t,o]=He(),r=()=>w(v,"$currentSubtitle$",t),a=()=>w(y,"$isLive$",t),l=()=>w(_,"$isFullscreen",t),d=()=>w(x,"$previewTrackActive",t),s=()=>w(b,"$isAutoSubtitleCaptionVisible$",t),u=h(e,"isMobile",3,!1),m=$e(),p=Dt(),v=m.state.currentSubtitle$,b=m.state.isAutoSubtitleCaptionVisible$,y=m.state.isLive$,_=m.ui.isFullscreen,x=m.ui.previewTrackActive,I=f(()=>!!r().isAuto),C=f(()=>!!a()),R=f(()=>e.playerSize.width*.02),A=f(()=>u()&&!l()||n(R)<=p.minSubtitlesFontSize?p.minSubtitlesFontSize:n(R)),P=K(null);Fe(()=>{var j,ne,Z;(j=n(P))==null||j.setIsAuto(n(I)),(ne=n(P))==null||ne.setIsLive(n(C)),(Z=n(P))==null||Z.setCaptions(e.captions)});let E=K(li([[]]));Ot(()=>{O(P,new xp().subscribe(),!0);let j=n(P).captionsPrepared$.subscribe(ne=>{O(E,ne,!0)});return()=>{var ne;(ne=n(P))==null||ne.destroy(),j.unsubscribe()}}),Ot(()=>{if(n(I)){let j=window.setTimeout(()=>{b.set(!1)},p.autoSubtitlesTimeout);return()=>{window.clearTimeout(j)}}else b.set(!1)});let W=f(()=>e.playerSize.width<400?10:e.playerSize.width<550?14:24);var F=Xw();let U;var X=T(F);{var se=j=>{var ne=jw();let Z;var Te=T(ne),fe=T(Te);{var te=Ce=>{var me=Qw(),ce=T(me),Ye=T(ce,!0);S(ce),S(me),N(G=>{var D;Qe(ce,`font-size: ${(D=n(A))!=null?D:""}px`),ge(Ye,G)},[()=>Y("subtitles_auto_caption")]),$(Ce,me)},_e=(Ce,me)=>{{var ce=G=>{var D=Oe(),Xe=le(D);xi(Xe,17,()=>n(E),Bd,(re,pe)=>{var ue=Gw(),Ae=T(ue);xi(Ae,21,()=>n(pe),({value:ze,timeAppeared:ee})=>ee,(ze,ee)=>{let de=()=>n(ee).value,ke=()=>n(ee).timeAppeared;var xe=Oe(),Je=le(xe);{var Pe=we=>{var Ne=bs();N(()=>ge(Ne,de())),$(we,Ne)};V(Je,we=>{(!ke()||ke()<=e.position)&&we(Pe)})}$(ze,xe)}),S(Ae),S(ue),N(()=>{var ze;return Qe(Ae,`font-size: ${(ze=n(A))!=null?ze:""}px`)}),$(re,ue)}),$(G,D)},Ye=G=>{var D=Oe(),Xe=le(D);xi(Xe,17,()=>e.captions,({value:re})=>re,(re,pe)=>{let ue=()=>n(pe).value;var Ae=Yw(),ze=T(Ae),ee=T(ze,!0);S(ze),S(Ae),N(()=>{var de;Qe(ze,`font-size: ${(de=n(A))!=null?de:""}px`),ge(ee,ue())}),$(re,Ae)}),$(G,D)};V(Ce,G=>{var D;n(I)&&((D=n(E))!=null&&D.length)?G(ce):G(Ye,!1)},me)}};V(fe,Ce=>{n(I)&&s()?Ce(te):Ce(_e,!1)})}S(Te),S(ne),N(Ce=>{var me;Z=oe(ne,1,"subtitles-caption s-a",null,Z,Ce),Qe(ne,`--subtitles-caption-margin: ${(me=n(W))!=null?me:""}%`)},[()=>({mobile:u()})]),$(j,ne)};V(X,j=>{var ne;(e.captions.length||(ne=n(E))!=null&&ne.length)&&j(se)})}S(F),N(j=>U=oe(F,1,"subtitles-container s-a",null,U,j),[()=>({shifted:e.shifted,"preview-track-active":d(),auto:n(I)&&!n(C)&&!s()})]),$(i,F),H(),o()}var t$=require("@vkontakte/videoplayer-core/es2015");var Jw=L('<div class="text s-i"> </div>'),eS=L('<div><div class="icon_wrapper s-i"><!></div> <!></div>'),tS={hash:"s-i",code:".wrapper.s-i{align-items:center;background-position:50%;background-repeat:no-repeat;background-size:contain;display:flex;flex-direction:column;font-size:16px;height:100%;justify-content:center}.wrapper.bgCover.s-i{background-size:cover}.icon_wrapper.s-i{align-items:center;display:flex;flex-direction:column;width:400px}.text.s-i{margin-top:20px}"};function Ac(i,e){B(e,!0),Q(i,tS);let t=h(e,"chromecastDeviceName",3,"chromecastDeviceName"),o=Dt();var r=eS();let a;r.__contextmenu=function(...m){var p;(p=e.onContextMenu)==null||p.apply(this,m)},r.__click=function(...m){var p;(p=e.onClick)==null||p.apply(this,m)},r.__dblclick=function(...m){var p;(p=e.onDblClick)==null||p.apply(this,m)};var l=T(r),d=T(l);mc(d,{get size(){return"48"},get iconState(){return t$.ChromecastState.CONNECTED}}),S(l);var s=k(l,2);{var u=m=>{var p=Jw(),v=T(p);S(p),N(()=>{var b;return ge(v,`Видео воспроизводится на ${(b=t())!=null?b:""}`)}),$(m,p)};V(s,m=>{t()&&m(u)})}S(r),N(m=>{a=oe(r,1,"wrapper s-i",null,a,m),Qe(r,`background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('${e.thumbUrl||""}')`)},[()=>({bgCover:o.features.previewNoEmptySpace})]),$(i,r),H()}et(["contextmenu","click","dblclick"]);var iS=Ee('<path d="M460 194a4 4 0 0 1 4-4h122a4 4 0 0 1 4 4v82a4 4 0 0 1-4 4H464a4 4 0 0 1-4-4zm6 3a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm112-72a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm0 12a1 1 0 0 1 .99-1h4.02a1 1 0 0 1 .99 1v4a1 1 0 0 1-.99 1h-4.02a1 1 0 0 1-.99-1zm-71-37a6 6 0 1 0 0-12 6 6 0 0 0 0 12m36 0a6 6 0 1 0 0-12 6 6 0 0 0 0 12m-18.05 15c6.05 0 11.62 4.45 11.94 4.65 2.11 1.35 3.26.77 3.96.16s1.15-2.81-1.04-4.66c-1.74-1.48-5.8-5.16-14.86-5.15s-12.95 3.5-14.8 5.18c-1.83 1.69-2.28 3.5-.96 4.66s2.31 1.16 4.35-.33c0 .01 5.36-4.51 11.41-4.51"></path>');function Pv(i){Ze(i,{width:"200",height:"200",viewBox:"460 190 130 90",testId:"error-icon",children:(e,t)=>{var o=iS();$(e,o)},$$slots:{default:!0}})}var oS=L('<div class="container s-4"><!></div>'),nS={hash:"s-4",code:".container.s-4{align-items:center;background:#000;bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0}"};function sl(i){Q(i,nS);var e=oS(),t=T(e);Pv(t,{}),S(e),$(i,e)}var rS=L('<div class="playButton s-d" tabindex="0" role="button"><div class="playButtonBackground s-d"></div> <!></div>'),sS=L('<div data-testid="unstarted-thumb"><!></div>'),aS={hash:"s-d",code:".container.s-d{background-position:50%;background-repeat:no-repeat;background-size:contain;bottom:0;cursor:pointer;left:0;position:absolute;right:0;top:0;transition:opacity .2s,visibility .2s;will-change:opacity}.container.hidden.s-d{opacity:0;visibility:hidden}.container.bgCover.s-d{background-size:cover}.playButton.s-d{align-items:center;display:flex;height:var(--big-play-size);justify-content:center;margin:auto;width:var(--big-play-size)}.playButton.s-d,.playButtonBackground.s-d{bottom:0;left:0;position:absolute;right:0;top:0}.playButtonBackground.s-d{background-color:var(--big-play-bg-color);border-radius:var(--big-play-radius);transition:background .2s,transform .2s;transition-timing-function:ease-out;will-change:background,transform}.container.s-d:hover .playButtonBackground:where(.s-d){background-color:var(--big-play-hover-bg-color);transform:scale(1.15)}.playButton.s-d svg{position:relative}"};function al(i,e){B(e,!0),Q(i,aS);let t=h(e,"iconVisible",3,!0),o=$e(),r=Dt(),a=o.ui.startedByKeyboard$,l=Y("tooltip_play"),d=b=>{var _;let y=b.code;["Enter","Space"].includes(y)&&(b.stopPropagation(),b.preventDefault(),a.set(!0),(_=e.startVideo)==null||_.call(e))},s=b=>{var y,_;b.stopPropagation(),(y=e.startVideo)==null||y.call(e),(_=e.onClick)==null||_.call(e,b)};var u=sS();let m;u.__click=s,u.__contextmenu=function(...b){var y;(y=e.onContextMenu)==null||y.apply(this,b)};var p=T(u);{var v=b=>{var y=rS();y.__keydown=d;var _=k(T(y),2);Ln(_,{get size(){return"48"}}),S(y),N(()=>De(y,"aria-label",l)),$(b,y)};V(p,b=>{t()&&b(v)})}return S(u),N(b=>{m=oe(u,1,"container s-d",null,m,b),Qe(u,`background-color: #222; background-image: url('${e.thumbUrl||""}')`)},[()=>({hidden:e.hidden,bgCover:r.features.previewNoEmptySpace})]),$(i,u),H({handlePressKey:d,handleClick:s})}et(["click","contextmenu","keydown"]);var lS=L('<span class="text s-v"> </span>'),dS=(i,e)=>{var t;return(t=e.onTitleClicked)==null?void 0:t.call(e)},cS=L('<a target="_blank" class="link s-v"><!></a>'),uS=(i,e)=>e.onTitleClicked(),pS=L("<button><!></button>"),fS=L('<div data-testid="video_title"><!></div>'),mS={hash:"s-v",code:".title.s-v{background:linear-gradient(0deg,transparent,rgba(0,0,0,.02) 19%,rgba(0,0,0,.1) 34%,rgba(0,0,0,.4) 60%,rgba(0,0,0,.6));box-sizing:border-box;font-size:15px;height:var(--controls-gradient-height);left:0;overflow:hidden;padding:18px 20px 10px;pointer-events:none;position:absolute;text-overflow:ellipsis;top:0;transition-duration:var(--controls-transition-duration);transition-property:visibility,transform,opacity;transition-timing-function:var(--controls-transition-fn);white-space:nowrap;width:100%;will-change:transform,opacity;z-index:var(--controls-container-z-index)}.link.s-v,.title.s-v{color:var(--white)}.link.s-v{pointer-events:auto;text-decoration:none}.link.s-v:hover{text-decoration:underline}.text.s-v{pointer-events:auto}.size-sm.s-v{font-size:14px;font-weight:500;line-height:18px}.hidden.s-v{opacity:0;transform:translateY(calc(var(--controls-gradient-height)*-1));visibility:hidden}"};function kv(i,e){B(e,!0),Q(i,mS);let t=b=>{var y=lS(),_=T(y,!0);S(y),it(y,x=>l(x),()=>l()),N(()=>ge(_,o())),vt("mouseenter",y,function(...x){var I;(I=e.onMouseEnter)==null||I.apply(this,x)}),vt("mouseleave",y,function(...x){var I;(I=e.onMouseLeave)==null||I.apply(this,x)}),$(b,y)},o=h(e,"title",3,""),r=h(e,"isHidden",3,!1),a=h(e,"size",3,"md"),l=h(e,"ref",15),d=K(void 0);Ot(()=>{var y;requestAnimationFrame(()=>{var _;(_=e.onVisibilityChanged)==null||_.call(e,!0)});function b(_){var x;_.propertyName==="transform"&&((x=e.onVisibilityChanged)==null||x.call(e,!r()))}return(y=n(d))==null||y.addEventListener("transitionend",b),()=>{var _;return(_=n(d))==null?void 0:_.removeEventListener("transitionend",b)}});var s=fS();let u;var m=T(s);{var p=b=>{var y=cS();y.__click=[dS,e];var _=T(y);t(_),S(y),N(()=>De(y,"href",e.titleLinkHref)),$(b,y)},v=(b,y)=>{{var _=I=>{var C=pS();C.__click=[uS,e];var R=T(C);t(R),S(C),$(I,C)},x=I=>{t(I)};V(b,I=>{e.onTitleClicked?I(_):I(x,!1)},y)}};V(m,b=>{e.titleLinkHref?b(p):b(v,!1)})}S(s),it(s,b=>O(d,b),()=>n(d)),N(b=>u=oe(s,1,`title size-${a()}`,"s-v",u,b),[()=>({hidden:r()})]),$(i,s),H()}et(["click"]);var i$=require("@vkontakte/videoplayer-shared/es2015");var vS=L('<div class="timer__cell cell s-19"><span class="cell__value s-19"> </span> <span class="cell__unit s-19"> </span></div> <span class="timer__points s-19"> </span>',1),gS=L('<div class="timer__cell cell s-19"><span class="cell__value s-19"> </span> <span class="cell__unit s-19"> </span></div> <span class="timer__points s-19"> </span>',1),hS=L('<div class="timer__cell cell s-19"><span class="cell__value s-19"> </span> <span class="cell__unit s-19"> </span></div> <span class="timer__points s-19"> </span>',1),_S=L('<div class="timer__cell cell s-19"><span class="cell__value s-19"> </span> <span class="cell__unit s-19"> </span></div>'),bS=L("<div><!> <!> <!> <!></div>"),$S={hash:"s-19",code:".timer__container.s-19{align-items:flex-start;display:flex;justify-content:center}.cell.s-19{align-items:center;display:flex;flex-direction:column}.cell__value.s-19{font-size:48px;font-weight:600;line-height:1.2}.small.s-19 .cell__value:where(.s-19){font-size:24px}.cell__unit.s-19{font-size:14px;font-weight:400;line-height:1.2}.small.s-19 .cell__unit:where(.s-19){font-size:12px}.timer__points.s-19{display:inline-block;font-size:42px;font-weight:600;line-height:1.2;margin:0 8px}.small.s-19 .timer__points:where(.s-19){font-size:20px}"};function Av(i,e){B(e,!0),Q(i,$S);let t=K(""),o=K(""),r=K(""),a=K(""),l,d=32,s=d/2,u=F=>String(F).padStart(2,"0"),m=F=>Math.max(F.length,1),p=F=>`${(e.isSmallSize?s:d)*m(F)}px`,v=F=>{let U=Math.floor(F/86400);U&&(F-=U*86400,O(t,u(U),!0));let X=Math.floor(F/3600);O(o,u(X),!0);let se=Math.floor(F/60)%60;O(r,u(se),!0);let j=F%60;O(a,u(j),!0)},b=()=>{let F=Math.floor(Date.now()/1e3),U=e.startTime-F;v(U),U>=1?l=requestAnimationFrame(b):e.onTimerOver()};Ot(()=>{l=requestAnimationFrame(b)}),mn(()=>{cancelAnimationFrame(l)});var y=bS();let _;var x=T(y);{var I=F=>{var U=vS(),X=le(U);let se;var j=T(X),ne=T(j,!0);S(j);var Z=k(j,2),Te=T(Z,!0);S(Z),S(X);var fe=k(X,2),te=T(fe,!0);S(fe),N((_e,Ce,me)=>{se=Qe(X,"",se,{width:_e}),ge(ne,n(t)),ge(Te,Ce),ge(te,me)},[()=>p(n(t)),()=>Y("waiting_live_day_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(x,F=>{n(t)&&F(I)})}var C=k(x,2);{var R=F=>{var U=gS(),X=le(U);let se;var j=T(X),ne=T(j,!0);S(j);var Z=k(j,2),Te=T(Z,!0);S(Z),S(X);var fe=k(X,2),te=T(fe,!0);S(fe),N((_e,Ce,me)=>{se=Qe(X,"",se,{width:_e}),ge(ne,n(o)),ge(Te,Ce),ge(te,me)},[()=>p(n(o)),()=>Y("waiting_live_hour_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(C,F=>{n(o)&&F(R)})}var A=k(C,2);{var P=F=>{var U=hS(),X=le(U);let se;var j=T(X),ne=T(j,!0);S(j);var Z=k(j,2),Te=T(Z,!0);S(Z),S(X);var fe=k(X,2),te=T(fe,!0);S(fe),N((_e,Ce,me)=>{se=Qe(X,"",se,{width:_e}),ge(ne,n(r)),ge(Te,Ce),ge(te,me)},[()=>p(n(r)),()=>Y("waiting_live_minute_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(A,F=>{n(r)&&F(P)})}var E=k(A,2);{var W=F=>{var U=_S();let X;var se=T(U),j=T(se,!0);S(se);var ne=k(se,2),Z=T(ne,!0);S(ne),S(U),N((Te,fe)=>{X=Qe(U,"",X,{width:Te}),ge(j,n(a)),ge(Z,fe)},[()=>p(n(a)),()=>Y("waiting_live_second_value")]),$(F,U)};V(E,F=>{n(a)&&F(W)})}S(y),N(F=>_=oe(y,1,"timer__container s-19",null,_,F),[()=>({small:e.isSmallSize})]),$(i,y),H()}var yS=L('<div class="waiting s-m"><span> </span></div>'),xS=L('<div class="upcoming-timer timer s-m"><span> </span> <!></div>'),wS=L('<div class="waiting-container s-m"><!></div>'),SS={hash:"s-m",code:'.waiting-container.s-m{background-color:var(--black);background-position:50%;background-repeat:no-repeat;background-size:cover;white-space:nowrap}.waiting-container.s-m,.waiting-container.s-m:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-m:before{backdrop-filter:blur(15px);background-color:rgba(0,0,0,.56);content:"";z-index:1}.waiting.s-m{align-items:center;display:flex;flex-direction:column;justify-content:center;left:0;position:absolute;top:50%;transform:translateY(-50%);width:100%;z-index:2}.waiting__title.s-m{font-size:20px;font-weight:600;line-height:1.2}.upcoming-timer.s-m{left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:2}.timer.s-m{align-items:center;display:flex;flex-direction:column;justify-content:center}.timer__title.s-m{display:inline-block;font-size:20px;font-weight:600;line-height:1.2;margin-bottom:12px;vertical-align:middle}.small.s-m{font-size:15px}.medium.s-m{font-size:17px}'};function Lc(i,e){B(e,!0),Q(i,SS);let t=h(e,"startTime",3,0),o=f(()=>t()<Math.floor(Date.now()/1e3)),r=K(void 0),a=K(void 0),l=0,d=K(void 0),s=K(void 0),u=f(()=>{var x,I;return((x=n(d))!=null?x:1/0)<=509||((I=n(s))!=null?I:1/0)<=320}),m=f(()=>{var x,I;return!n(u)&&(((x=n(d))!=null?x:1/0)<=699||((I=n(s))!=null?I:1/0)<=599)}),p=e.onUpcomingLiveViewStateChanged?(0,i$.throttleFn)(()=>{cancelAnimationFrame(l),l=requestAnimationFrame(()=>{let x={type:n(o)?"expired":"default",size:n(u)?"s":n(m)?"m":"l"},I=n(o)?n(r):n(a);e.onUpcomingLiveViewStateChanged(x,I)})},300):void 0;Fe(()=>{n(s),n(d),n(o),p==null||p()}),mn(()=>{if(cancelAnimationFrame(l),p==null||p.cancel(),e.onUpcomingLiveViewStateChanged){let x={type:n(o)?"expired":"default",size:n(u)?"s":n(m)?"m":"l"};e.onUpcomingLiveViewStateChanged(x)}});var v=wS();v.__contextmenu=function(...x){var I;(I=e.onContextMenu)==null||I.apply(this,x)},v.__click=function(...x){var I;(I=e.onClick)==null||I.apply(this,x)};var b=T(v);{var y=x=>{var I=yS(),C=T(I);let R;var A=T(C,!0);S(C),S(I),it(I,P=>O(r,P),()=>n(r)),N((P,E)=>{R=oe(C,1,"waiting__title s-m",null,R,P),ge(A,E)},[()=>({medium:n(m),small:n(u)}),()=>Y("waiting_live_upcoming_title")]),$(x,I)},_=x=>{var I=xS(),C=T(I);let R;var A=T(C,!0);S(C);var P=k(C,2);let E=f(()=>n(u)||n(m)),W=f(()=>t()||0);Av(P,{get isSmallSize(){return n(E)},get startTime(){return n(W)},onTimerOver:()=>O(o,!0)}),S(I),it(I,F=>O(a,F),()=>n(a)),N((F,U)=>{R=oe(C,1,"timer__title s-m",null,R,F),ge(A,U)},[()=>({medium:n(m),small:n(u)}),()=>Y("waiting_live_timer_title")]),$(x,I)};V(b,x=>{n(o)?x(y):x(_,!1)})}S(v),N(()=>Qe(v,`background-image: url(${e.thumbUrl})`)),kn(v,"clientWidth",x=>O(d,x)),kn(v,"clientHeight",x=>O(s,x)),$(i,v),H()}et(["contextmenu","click"]);var CS=L('<div class="waiting-container s-s"><div class="waiting-caption s-s"><!> <p class="waiting-title s-s"> </p></div></div>'),TS={hash:"s-s",code:'.waiting-container.s-s{align-items:center;background-color:var(--black);background-position:50%;background-repeat:no-repeat;background-size:cover;display:flex;justify-content:center}.waiting-container.s-s,.waiting-container.s-s:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-s:before{backdrop-filter:blur(10px);background-color:rgba(0,0,0,.4);content:""}.waiting-caption.s-s{align-items:center;display:flex;flex-direction:column;position:relative}.waiting-title.s-s{font-size:20px;font-weight:400;line-height:1.2;margin:0;padding:20px;text-align:center}'};function ll(i,e){B(e,!0),Q(i,TS);let t=h(e,"thumbUrl",3,""),o={recover:Y("waiting_live_recover_title"),record:Y("waiting_record_title")},r=f(()=>o[e.kind]||"");var a=CS();a.__contextmenu=function(...m){var p;(p=e.onContextMenu)==null||p.apply(this,m)},a.__click=function(...m){var p;(p=e.onClick)==null||p.apply(this,m)};var l=T(a),d=T(l);Ya(d,{style:"position: static; transform: translate(0, 0)"});var s=k(d,2),u=T(s,!0);S(s),S(l),S(a),N(()=>{Qe(a,`background-image: url('${t()}')`),ge(u,n(r))}),$(i,a),H()}et(["contextmenu","click"]);var IS=Ee('<path d="M6 10.2 3.5 7.7a.99.99 0 0 0-1.4 1.4l3.2 3.2a1 1 0 0 0 1.4 0l7.6-7.6a.99.99 0 0 0-1.4-1.4z"></path>');function Lv(i){Ze(i,{width:"16",height:"16",testId:"check-mark-icon",children:(e,t)=>{var o=IS();$(e,o)},$$slots:{default:!0}})}var ES=L('<div class="select-icon s-1w"><!></div>'),PS={hash:"s-1w",code:".select-icon.s-1w{margin-right:auto;opacity:.9;padding-right:12px;position:relative;top:3px}"};function Mc(i){Q(i,PS);var e=ES(),t=T(e);Lv(t,{}),S(e),$(i,e)}var kS=(i,e)=>{i.stopPropagation(),e.item.selectItem(e.item.value)},AS=(i,e)=>{Yl(i,()=>e.item.selectItem(e.item.value))},LS=L("<p> </p>"),MS=L('<p class="sublabel s-1r"> </p>'),VS=L('<li role="menuitem" tabindex="0"><!> <div><!> <!></div></li>'),RS={hash:"s-1r",code:".menu-item-value.s-1r{align-items:end;display:flex;flex-direction:column;min-width:0}.menu-item-value[data-selected=false].s-1r{--select-icon-width:16px;--icon-padding:12px;margin-left:calc(var(--icon-padding) + var(--select-icon-width))}.label.s-1r,.sublabel.s-1r{max-width:100%;overflow:hidden;text-overflow:ellipsis}.sublabel.s-1r{opacity:.5}"};function Mv(i,e){B(e,!0),Q(i,RS);let t=h(e,"isMobile",3,!1);var o=VS();let r;o.__click=[kS,e],o.__keydown=[AS,e];var a=T(o);{var l=y=>{Mc(y,{})};V(a,y=>{e.item.selected&&y(l)})}var d=k(a,2);let s;var u=T(d);{var m=y=>{var _=Oe(),x=le(_);Hi(x,()=>e.item.valueComponent,(I,C)=>{C(I,is(()=>{var R;return(R=e.item.valueComponentParams)!=null?R:{}}))}),$(y,_)},p=y=>{var _=LS();let x;var I=T(_,!0);S(_),N(C=>{var R;x=oe(_,1,"label s-1r",null,x,C),ge(I,(R=e.item.label)!=null?R:e.item.value)},[()=>({mobile:t()})]),$(y,_)};V(u,y=>{e.item.valueComponent?y(m):y(p,!1)})}var v=k(u,2);{var b=y=>{var _=MS(),x=T(_,!0);S(_),N(()=>ge(x,e.item.sublabel)),$(y,_)};V(v,y=>{e.item.sublabel&&y(b)})}S(d),S(o),N((y,_,x)=>{var I;r=oe(o,1,"item",null,r,y),De(o,"data-value",(I=e.item.dataValue)!=null?I:e.item.value),De(o,"aria-label",_),De(o,"data-testid",e.item.dataTestid),s=oe(d,1,"menu-item-value s-1r",null,s,x),De(d,"data-selected",e.item.selected)},[()=>({mobile:t()}),()=>{var y,_;return(_=(y=e.item.ariaLabel)!=null?y:e.item.label)!=null?_:e.item.value.toString()},()=>({"submenu-value-mobile":t()})]),$(i,o),H()}et(["click","keydown"]);var OS=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><!> <div><!></div></li>');function Vv(i,e){B(e,!0);let t=h(e,"isMobile",3,!1),o=h(e,"refMenuItems",15),r=f(()=>()=>e.openSubMenuList(e.item.children)),a=f(()=>_=>ep(_,n(r)));var l=OS();let d;l.__click=function(..._){var x;(x=n(r))==null||x.apply(this,_)},l.__keydown=function(..._){var x;(x=n(a))==null||x.apply(this,_)};var s=T(l);{var u=_=>{Mc(_,{})};V(s,_=>{e.item.selected&&_(u)})}var m=k(s,2);let p;var v=T(m);{var b=_=>{var x=Oe();let I=f(()=>e.item.valueComponent);var C=le(x);Hi(C,()=>n(I),(R,A)=>{A(R,is(()=>{var P;return(P=e.item.valueComponentParams)!=null?P:{}}))}),$(_,x)},y=_=>{var x=bs();N(()=>ge(x,e.item.label)),$(_,x)};V(v,_=>{e.item.valueComponent?_(b):_(y,!1)})}S(m),S(l),it(l,_=>o(o()[e.item.id]=_,!0),()=>{var _;return(_=o())==null?void 0:_[e.item.id]}),N((_,x)=>{var I;d=oe(l,1,"item",null,d,_),De(l,"aria-label",(I=e.item.ariaLabel)!=null?I:e.item.label),De(l,"data-testid",e.item.id),p=oe(m,1,"menu-item-value",null,p,x)},[()=>({mobile:t(),bottomBordered:e.item.bottomBordered}),()=>({"submenu-value-mobile":t()})]),$(i,l),H()}et(["click","keydown"]);var ss={"quality-settings":100,"audio-language-settings":200,"playback-rate-settings":300,"subtitles-settings":400,"traffic-saving-settings":500,download:600,report:700,"copy-data":800,"save-trace-info":900,"debug-info":1e3};var NS=(i,e)=>{vb(i,e.returnFromSubMenu,e.closeSettingsMenu)},BS=(i,e)=>{i.stopPropagation(),e.returnFromSubMenu()},HS=(i,e)=>{oc(i)&&(Or(i),e.returnFromSubMenu())},FS=L('<div><ul role="menu"><li role="menuitem" tabindex="0" data-testid="return-to-settings-menu"><!> <p class="title s-1k"> </p></li> <!></ul></div>'),US={hash:"s-1k",code:".sub-menu.s-1k{--item-padding-vertical-mobile:16px;--item-padding-vertical:7px;--item-label-line-height:18px;--edge-item-padding-vertical-mobile:calc(6px + var(--item-padding-vertical-mobile));--edge-item-padding-vertical:calc(8px + var(--item-padding-vertical))}.sub-menu.s-1k .item.mobile{font-size:14px;line-height:var(--item-label-line-height);padding:var(--item-padding-vertical-mobile) 17px}.sub-menu.s-1k{padding-top:calc(var(--edge-item-padding-vertical) + var(--item-padding-vertical) + var(--item-label-line-height))}.sub-menu.mobile.s-1k{padding-top:calc(var(--edge-item-padding-vertical-mobile) + var(--item-padding-vertical-mobile) + var(--item-label-line-height) + 1px)}.sub-menu.s-1k .items:where(.s-1k) .item.header:where(.s-1k){border-bottom:var(--divider-border);display:flex;justify-content:space-between;left:0;min-width:max-content;position:absolute;right:0;top:0}.header.s-1k .title:where(.s-1k){margin-left:8px}.sub-menu.s-1k .item{padding:var(--item-padding-vertical) 12px;padding-right:22px}.items.s-1k .item:first-child:not(.mobile){padding-top:var(--edge-item-padding-vertical)}.items.s-1k .item:last-child:not(.mobile){padding-bottom:var(--edge-item-padding-vertical)}.items.s-1k .item.mobile:first-child{padding-top:var(--edge-item-padding-vertical-mobile)}.items.s-1k .item.mobile:last-child{padding-bottom:var(--edge-item-padding-vertical-mobile)}.sub-menu.s-1k .item.bottomBordered{border-bottom:var(--divider-border)}.sub-menu.s-1k .item .sublabel{font-size:12px;line-height:14px}.item.s-1k:not(.mobile) p:where(.s-1k),.sub-menu.s-1k .item:not(.mobile) .label{font-size:13px;line-height:var(--item-label-line-height)}"};function Ov(i,e){B(e,!0),Q(i,US);let[t,o]=He(),r=()=>w(p,"$isFullscreen",t),a=()=>w(v,"$playerSize",t),l=h(e,"isMobile",3,!1),d=h(e,"playerControlsHeight",3,0),s=h(e,"ariaLabelReturnFromSubMenu",19,()=>Y("aria_label_submenu_back")),u=h(e,"listRef",15);Ot(()=>{let j=e.items.findIndex(ne=>ne.selected);u().children[j+1].focus()});let m=$e(),p=m.ui.isFullscreen,v=m.ui.playerSize,b=K(void 0),y=K(0),_=K(0),x=f(()=>l()&&r()?`max-height: ${Math.round(a().height*.6)}px`:l()?"":`max-height: ${a().height-32-n(_)-d()}px; overflow: auto;`),I=f(()=>Math.max(e.minWidth,n(y)));var C=FS();let R;var A=T(C);let P;A.__keydown=[NS,e];var E=T(A);let W;E.__click=[BS,e],E.__keydown=[HS,e];var F=T(E);Rr(F,{direction:"left"});var U=k(F,2),X=T(U,!0);S(U),S(E),it(E,j=>O(b,j),()=>n(b));var se=k(E,2);xi(se,17,()=>e.items,Bd,(j,ne)=>{var Z=Oe(),Te=le(Z);{var fe=_e=>{Mv(_e,{get item(){return n(ne)},get isMobile(){return l()}})},te=(_e,Ce)=>{{var me=ce=>{Vv(ce,{get isMobile(){return l()},get item(){return n(ne)},get openSubMenuList(){return e.openSubMenuList},get refMenuItems(){return e.refMenuItems}})};V(_e,ce=>{n(ne).type==="OPEN_SUB_MENU"&&ce(me)},Ce)}};V(Te,_e=>{n(ne).type==="SELECT_VALUE"?_e(fe):_e(te,!1)})}$(j,Z)}),S(A),it(A,j=>u(j),()=>u()),S(C),N((j,ne,Z)=>{R=oe(C,1,"sub-menu menu s-1k",null,R,j),De(C,"data-testid",`${e.id}-sub-menu`),Qe(C,`min-width: ${n(I)}px`),P=oe(A,1,"items s-1k",null,P,ne),Qe(A,n(x)),W=oe(E,1,"item header back s-1k",null,W,Z),De(E,"aria-label",s()),ge(X,e.title)},[()=>({desktop:!l(),mobile:l()}),()=>({mobile:l()}),()=>({mobile:l()})]),kn(E,"clientWidth",j=>O(y,j)),kn(E,"clientHeight",j=>O(_,j)),$(i,C),H(),o()}et(["keydown","click"]);var n$=require("@vkontakte/videoplayer-shared/es2015");var zS=(i,e)=>ep(i,e()),WS=(i,e)=>{i.stopPropagation(),e()()},KS=L('<div class="value s-1m"> </div>'),qS=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></li>'),QS={hash:"s-1m",code:".value.s-1m{opacity:.7;overflow:hidden;position:relative;text-overflow:ellipsis}"};function Dv(i,e){B(e,!0),Q(i,QS);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,n$.noop),r=h(e,"valueComponent",3,void 0),a=h(e,"iconProps",19,()=>({})),l=h(e,"ref",15);var d=qS();let s;d.__click=[WS,o],d.__keydown=[zS,o];var u=T(d),m=T(u);{var p=C=>{tl(C,{get icon(){return e.icon}})},v=C=>{var R=Oe();let A=f(()=>e.icon);var P=le(R);Hi(P,()=>n(A),(E,W)=>{W(E,is(a))}),$(C,R)};V(m,C=>{typeof e.icon=="string"?C(p):C(v,!1)})}S(u);var b=k(u,2),y=T(b,!0);S(b);var _=k(b,2);{var x=C=>{var R=Oe();let A=f(r);var P=le(R);Hi(P,()=>n(A),(E,W)=>{W(E,{})}),$(C,R)},I=C=>{var R=KS(),A=T(R,!0);S(R),N(()=>ge(A,e.value)),$(C,R)};V(_,C=>{r()?C(x):C(I,!1)})}S(d),it(d,C=>l(C),()=>l()),N(C=>{s=oe(d,1,"item",null,s,C),De(d,"aria-label",e.ariaLabel),De(d,"data-testid",e.id),ge(y,e.label)},[()=>({mobile:t()})]),$(i,d),H()}et(["click","keydown"]);var Nv=require("@vkontakte/videoplayer-shared/es2015");var GS=(i,e)=>{Yl(i,()=>e())},YS=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),jS=L('<img class="icon" aria-hidden="true"/>'),XS=L('<li role="menuitem" tabindex="0"><div class="icon-wrapper"><!></div> <div class="label s-1l"> </div></li>'),ZS={hash:"s-1l",code:".label.s-1l{overflow:hidden;text-overflow:ellipsis}"};function Bv(i,e){B(e,!0),Q(i,ZS);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,Nv.noop),r=h(e,"closeSettings",3,Nv.noop),a=K(!1),l=()=>{O(a,!0)},d=x=>{x==null||x.stopPropagation(),o()(),r()()};var s=XS();let u;s.__click=d,s.__keydown=[GS,d];var m=T(s),p=T(m);{var v=x=>{var I=Oe(),C=le(I);{var R=P=>{var E=YS();$(P,E)},A=P=>{var E=jS();N(()=>De(E,"src",e.icon)),vt("error",E,l),Da(E),$(P,E)};V(C,P=>{n(a)?P(R):P(A,!1)})}$(x,I)},b=x=>{var I=Oe();let C=f(()=>e.icon);var R=le(I);Hi(R,()=>n(C),(A,P)=>{P(A,{})}),$(x,I)};V(p,x=>{typeof e.icon=="string"?x(v):x(b,!1)})}S(m);var y=k(m,2),_=T(y,!0);S(y),S(s),N(x=>{var I;u=oe(s,1,"item",null,u,x),De(s,"aria-label",(I=e.ariaLabel)!=null?I:e.label),De(s,"data-testid",e.id),ge(_,e.label)},[()=>({mobile:t()})]),$(i,s),H()}et(["click","keydown"]);var r$=require("@vkontakte/videoplayer-shared/es2015");var JS=L('<div class="toggle_wrap s-1q"><div></div> <div class="toggle-label s-1q"></div></div>'),eC={hash:"s-1q",code:'.toggle_wrap.s-1q{cursor:pointer;font-size:12px;line-height:15px;min-height:15px;padding:0;user-select:none}.toggle.s-1q{background-color:var(--toggle-color-separator);border-radius:45px;cursor:pointer;float:right;height:9px;margin-top:3px;width:28px}.toggle.s-1q:after{background-color:var(--toggle-color-off);border-radius:50%;content:"";float:left;height:15px;left:0;position:relative;top:-3px;transition:left .1s ease;width:15px}.toggle.on.s-1q:after{background-color:var(--toggle-color-on);left:13px}.toggle-label.s-1q{overflow:hidden}'};function Hv(i,e){Q(i,eC);let t=h(e,"enabled",3,!1);var o=JS(),r=T(o);let a;ni(2),S(o),N(l=>a=oe(r,1,"toggle s-1q",null,a,l),[()=>({on:t()})]),$(i,o)}var tC=(i,e,t)=>{gb(i,e(),o=>t()(o))},iC=(i,e,t)=>{i.stopPropagation(),e()(!t())},oC=L('<div><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></div>'),nC=L('<li role="menuitem" tabindex="0"><!></li>');function Fv(i,e){B(e,!0);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,r$.noop),r=h(e,"enabled",3,!1),a=h(e,"tooltipText",3,void 0),l=h(e,"maxTooltipWidth",3,void 0);var d=nC();let s;d.__click=[iC,o,r],d.__keydown=[tC,r,o];var u=T(d);Xa(u,{get content(){return a()},get isMobile(){return t()},placement:"left",translateX:10,isFullWidthWrapper:!0,get maxTooltipWidth(){return l()},children:(m,p)=>{var v=oC();let b;var y=T(v),_=T(y);{var x=P=>{tl(P,{get icon(){return e.icon}})},I=P=>{var E=Oe();let W=f(()=>e.icon);var F=le(E);Hi(F,()=>n(W),(U,X)=>{X(U,{})}),$(P,E)};V(_,P=>{typeof e.icon=="string"?P(x):P(I,!1)})}S(y);var C=k(y,2),R=T(C,!0);S(C);var A=k(C,2);Hv(A,{get enabled(){return r()}}),S(v),N(P=>{b=oe(v,1,"switch-wrapper",null,b,P),ge(R,e.label)},[()=>({mobile:t()})]),$(m,v)},$$slots:{default:!0}}),S(d),N(m=>{var p;s=oe(d,1,"item switch-item",null,s,m),De(d,"aria-label",(p=e.ariaLabel)!=null?p:e.label),De(d,"data-testid",e.id)},[()=>({mobile:t()})]),$(i,d),H()}et(["click","keydown"]);var Rc=require("@vkontakte/videoplayer-shared/es2015");var s$=()=>{let i=K(li([])),e=f(()=>(n(i).length?n(i).at(-1):null)||null);return{get current(){return n(e)},pushSubMenu:t=>{n(i).push(t)},popSubMenu:()=>{O(i,n(i).slice(0,-1),!0)},popAllSubMenus:()=>{O(i,[],!0)}}};var a$=require("@vkontakte/videoplayer-shared/es2015");var rC=L('<div class="quality-icon s-1p"><!></div>'),sC=L('<div class="quality-label s-1p"><span> </span> <!></div>'),aC={hash:"s-1p",code:".quality-label.s-1p{position:relative}.quality.s-1p{font-size:13px;line-height:18px}.quality.sub.s-1p{opacity:.7}.quality-icon.s-1p{display:flex;padding-left:2px;position:absolute;right:0;top:0;transform:translateX(100%)}.quality-icon.s-1p svg{color:var(--blue-light)}"};function dl(i,e){B(e,!0),Q(i,aC);let t=h(e,"isSubCase",3,!1),o=f(()=>e.quality?(0,a$.getVideoQualityLabel)(e.quality):""),r=f(()=>sp(e.quality));var a=sC(),l=T(a);let d;var s=T(l,!0);S(l);var u=k(l,2);{var m=p=>{var v=rC();let b=f(()=>n(r));var y=T(v);Hi(y,()=>n(b),(_,x)=>{x(_,{})}),S(v),N(()=>De(v,"data-testid",`${n(o)}-icon`)),$(p,v)};V(u,p=>{n(r)&&!e.isMobile&&p(m)})}S(a),N(p=>{d=oe(l,1,"s-1p",null,d,p),ge(s,e.label)},[()=>({sub:!t(),quality:!e.isMobile})]),$(i,a),H()}var u$=require("@vkontakte/videoplayer-shared/es2015");var Uv=require("@vkontakte/videoplayer-core/es2015");var l$=({quality:i,availableQualities:e})=>{let t=e.find(o=>o.value===i);return t?t.displayValue:i},d$=({quality:i,availableQualities:e,isAutoQualityEnabled:t})=>{if(!i)return"...";let o=l$({quality:i,availableQualities:e});return t?i===Uv.VideoQuality.INVARIANT?Y("auto_quality_invariant"):Y("auto_quality",{actual:o}):o},c$=({quality:i,availableQualities:e,prefix:t,onlyPrefix:o})=>i?o||i===Uv.VideoQuality.INVARIANT?t:`${t}${l$({quality:i,availableQualities:e})}`:"...";var lC=L('<div class="menu-item-value-wrapper s-1t"><!></div>'),dC={hash:"s-1t",code:".menu-item-value-wrapper.s-1t{line-height:normal}"};function ad(i,e){B(e,!0),Q(i,dC);let[t,o]=He(),r=()=>w(s,"$currentQuality$",t),a=()=>w(u,"$availableQualities$",t),l=()=>w(m,"$isMobile$",t),d=$e(),s=d.state.currentQuality$,u=d.state.availableQualities$,m=d.ui.isMobile,p=" · ",v=f(()=>e.prefix+(e.selected&&r()!==u$.VideoQuality.INVARIANT?p:"")),b=f(()=>c$({prefix:n(v),quality:r(),availableQualities:a(),onlyPrefix:!e.selected}));var y=lC(),_=T(y);let x=f(()=>e.selected?r():void 0);dl(_,{get quality(){return n(x)},get label(){return n(b)},get isMobile(){return l()},isSubCase:!0}),S(y),$(i,y),H(),o()}var cC=i=>{let e=i.join("|"),t="<(?<keyhtml>.*?)(?<propshtml> .*?)?>(?<childrenhtml>.*?)</\\k<keyhtml>>",o=`{(?<keyi18n>${e})}(?<childreni18n>.*?){/\\k<keyi18n>}`,r="<(?<keyhtmlself>.*?)(?<propshtmlself> .*?)?/?>",a=`{(?<keyi18nself>${e})}`;return new RegExp(`${t}|${o}|${r}|${a}`,"g")},uC={br:!0,span:!0},zv=(i,e={})=>{var d,s,u,m,p,v,b;if(!i)return i;let t=Ve(Ve({},uC),e),o=Object.keys(t);if(!o.length)return i;let r=cC(o),a=[],l=0;for(let y of i.matchAll(r)){let _=y[0],x=((d=y.groups)==null?void 0:d.keyhtml)||((s=y.groups)==null?void 0:s.keyi18n)||((u=y.groups)==null?void 0:u.keyhtmlself)||((m=y.groups)==null?void 0:m.keyi18nself)||"",{index:I}=y;if(!t[x]){a.push(i.slice(l,I)),l=I+_.length;continue}let C=(p=y.groups)!=null&&p.childrenhtml?zv(y.groups.childrenhtml,t):"",R=(v=y.groups)!=null&&v.childrenhtml?_.replace(new RegExp((b=y.groups)==null?void 0:b.childrenhtml),()=>C||""):_;a.push(i.slice(l,I),R),l=I+_.length}return l===0?i:(a.push(i.slice(l)),a.join(""))};function Vc(i,e){B(e,!1);let t=h(e,"message",8),o=zv(t());on();var r=Oe(),a=le(r);{var l=d=>{var s=Oe(),u=le(s);Hd(u,()=>o),$(d,s)};V(a,d=>{o&&d(l)})}$(i,r),H()}var pC=L('<p class="quality-applies sublabel s-1s"><!></p>'),fC={hash:"s-1s",code:".quality-applies.s-1s{color:hsla(0,0%,100%,.5);display:flex;justify-content:end;padding:3px 0}.quality-applies span{color:#70c1ff}"};function Wv(i,e){B(e,!1),Q(i,fC),on();var t=pC(),o=T(t);let r=gr(()=>Y("quality_applience",{action:`<span>${Y("quality_applience_action")}</span>`}));Vc(o,{get message(){return n(r)}}),S(t),$(i,t),H()}var f$=({isAutoQualityEnabled:i,trafficSavingEnabled:e,highQualityEnabled:t})=>{let o=!i&&!e&&!t;return{id:"quality-other-settings",type:"OPEN_SUB_MENU",label:Y("other_quality"),selected:o,valueComponent:ad,valueComponentParams:{prefix:Y("other_quality"),selected:o},children:"quality-other-settings"}},Kv=({appliesTo:i,labelWithQuality:e,selected:t},{selectQuality:o})=>({id:"quality-auto",type:"SELECT_VALUE",value:"auto",label:Y("auto_quality_limit"),valueComponent:e?ad:void 0,valueComponentParams:{prefix:Y("auto_quality_limit"),selected:t},selectItem:()=>o("auto",i),selected:t}),m$=()=>({id:"quality-appliance-settings",type:"OPEN_SUB_MENU",valueComponent:Wv,bottomBordered:!0,children:"quality-appliance"}),qv=({labelWithQuality:i,appliesTo:e,selected:t},{toggleHighQuality:o})=>({id:"quality-high",type:"SELECT_VALUE",value:"high_quality",selectItem:()=>o(!0,e),selected:t,label:Y("high_quality"),valueComponent:i?ad:void 0,valueComponentParams:{prefix:Y("high_quality"),selected:t},sublabel:Y("high_quality_description")}),Qv=({labelWithQuality:i,appliesTo:e,selected:t},{toggleTrafficSaving:o})=>({id:"quality-traffic-saving",type:"SELECT_VALUE",value:"save_traffic",selectItem:()=>o(!0,e),selected:t,label:Y("traffic_saving_quality"),valueComponent:i?ad:void 0,valueComponentParams:{prefix:Y("traffic_saving_quality"),selected:t},sublabel:Y("traffic_saving_quality_description")});var wp=(i,e)=>String(e.findIndex(t=>t.id===i.id)+1),Sp=(i,e)=>{var l;if(!i)return"";let{language:t,label:o}=i,r;if(t==="und"?r=void 0:t&&(r=(l=hc(t))!=null?l:t),o&&t&&r){let d=e.filter(s=>s.label===o&&s.language===t);if(d.length===1)return Y("audio_stream_display_language_label",{language:r,label:o});{let s=wp(i,d);return Y("audio_stream_display_language_label_index",{language:r,label:o,index:s})}}if(o){let d=e.filter(s=>s.label===o);if(d.length===1)return o;{let s=wp(i,d);return Y("audio_stream_display_label_index",{label:o,index:s})}}if(t&&r){let d=e.filter(s=>s.language===t);if(d.length===1)return r;{let s=wp(i,d);return Y("audio_stream_display_language_index",{language:r,index:s})}}let a=wp(i,e);return Y("audio_stream_display_unknown",{index:a})};var mC={"quality-settings":i=>{let{isAutoQualityEnabled:e,isAutoQualityAvailable:t,trafficSavingEnabled:o,highQualityEnabled:r}=i,a=[];return t&&a.push({handler:Kv,selected:e&&!o&&!r||!1}),a.push({handler:Qv,selected:o},{handler:qv,selected:r}),{title:Y("submenu_quality"),id:"quality-settings",items:[m$(i),...a.map(({handler:l,selected:d})=>l({labelWithQuality:!0,appliesTo:"to-video",selected:d},i)),f$(i)]}},"quality-other-settings":({closeSettingsMenu:i,selectQuality:e,availableQualities:t,isMobile:o})=>({id:"quality-other-settings",title:Y("submenu_quality"),closeSettingsMenu:i,items:t.map(r=>({type:"SELECT_VALUE",value:r.value,valueComponent:dl,valueComponentParams:{quality:r.value,label:r.displayValue,isMobile:o,isSubCase:!0},selectItem:a=>e(a,"to-video"),selected:r.selected,label:r.displayValue}))}),"quality-appliance":i=>{var t,o,r;let{closeSettingsMenu:e}=i;return{id:"quality-appliance",title:Y("default_quality_for_any_video"),closeSettingsMenu:e,items:[{handler:Kv,selected:((t=zu())==null?void 0:t.type)==="auto_quality"},{handler:Qv,selected:((o=zu())==null?void 0:o.type)==="traffic_saving"},{handler:qv,selected:((r=zu())==null?void 0:r.type)==="high_quality"}].map(({handler:a,selected:l})=>a({labelWithQuality:!1,appliesTo:"as-default",selected:l},i))}},"audio-tracks":({closeSettingsMenu:i,availableAudioStreams:e,currentAudioStream:t,selectAudioLanguage:o})=>({id:"audio-tracks",title:Y("submenu_audio_languages"),closeSettingsMenu:i,items:e.map(r=>({type:"SELECT_VALUE",value:r,dataValue:r.id,selectItem:o,selected:r.id===(t==null?void 0:t.id),label:Sp(r,e)}))}),"playback-rate":({closeSettingsMenu:i,availablePlaybackRates:e,selectPlaybackRate:t})=>({id:"playback-rate",title:Y("submenu_playback_rate"),closeSettingsMenu:i,items:e.map(o=>({type:"SELECT_VALUE",value:o.value,selectItem:t,selected:o.selected,label:o.displayValue}))}),subtitles:({availableSubtitlesList:i,selectSubtitle:e})=>({id:"subtitles",minWidth:164,title:Y("subtitles_caption"),items:i.map(t=>({type:"SELECT_VALUE",value:t.value,selectItem:()=>e(t),selected:t.selected,label:t.displayValue,dataTestid:t.value===Vn?"sub_off":void 0}))})},v$=({subMenuId:i,context:e})=>i?[mC[i](e)]:[];var vC=Ee('<path d="M3.1 9.5c0-2.24 0-3.36.44-4.22A4 4 0 015.28 3.54C6.14 3.1 7.26 3.1 9.5 3.1h5c2.24 0 3.36 0 4.22.44a4 4 0 011.74 1.74c.44.86.44 1.98.44 4.22s0 3.36-.44 4.22a4 4 0 01-1.74 1.74c-.84.43-1.93.44-4.07.44l.55 2.2h1.9a.9.9 0 010 1.8H6.9a.9.9 0 110-1.8h1.9l.55-2.2c-2.14 0-3.23-.01-4.07-.44a4 4 0 01-1.74-1.74C3.1 12.86 3.1 11.74 3.1 9.5m11.4-4.6h-5c-1.15 0-1.9 0-2.48.05-.56.04-.79.12-.92.19a2.2 2.2 0 00-.96.96 2 2 0 00-.2.92C4.9 7.6 4.9 8.35 4.9 9.5s0 1.9.05 2.48c.04.56.12.79.19.92q.33.63.96.96c.13.07.36.15.92.2.58.04 1.33.04 2.48.04h5c1.15 0 1.9 0 2.48-.05.56-.04.79-.12.92-.19a2.2 2.2 0 00.96-.96c.07-.13.15-.36.2-.92.04-.58.04-1.33.04-2.48s0-1.9-.05-2.48a3 3 0 00-.19-.92 2.2 2.2 0 00-.96-.96 2 2 0 00-.92-.2c-.58-.04-1.33-.04-2.48-.04m-3.3 11-.55 2.2h2.7l-.55-2.2z"></path>');function Gv(i){Ze(i,{testId:"traffic-saving-icon",children:(e,t)=>{var o=vC();$(e,o)},$$slots:{default:!0}})}var gC=Ee('<path d="M8.3 14.25c1.86 1.9 5.5.02 5.5-3.55V5.64l2.4-.7A2.74 2.74 0 0 0 18 2.37V.64a.75.75 0 0 0-.92-.62l-.26.06C15.88.3 14.93.51 14 .8c-1.33.45-2.03 1.62-2.01 3.08V9c-3.89.2-5.64 3.29-3.7 5.25ZM.9.1a.9.9 0 0 0 0 1.8h8.2a.9.9 0 0 0 0-1.8H.9ZM.9 5.1a.9.9 0 1 0 0 1.8h7.2a.9.9 0 0 0 0-1.8H.9ZM0 11c0-.5.4-.9.9-.9h4.18a.9.9 0 1 1 0 1.8H.9A.9.9 0 0 1 0 11Z"></path>');function Yv(i){Ze(i,{width:"18",height:"15",children:(e,t)=>{var o=gC();$(e,o)},$$slots:{default:!0}})}var hC=Ee('<path d="M11 4.07V2.05c-2.01.2-3.84 1-5.32 2.21L7.1 5.69A8 8 0 0 1 11 4.07M5.69 7.1 4.26 5.68A10 10 0 0 0 2.05 11h2.02a8 8 0 0 1 1.62-3.9M2.05 13c.2 2.01 1 3.84 2.21 5.32l1.43-1.43A8 8 0 0 1 4.07 13zM11 21.95v-2.02a8 8 0 0 1-3.9-1.62l-1.42 1.43A10 10 0 0 0 11 21.95M22 12c0 5.16-3.92 9.42-8.95 9.95v-2.02C16.97 19.41 20 16.05 20 12s-3.03-7.41-6.95-7.93V2.05C18.08 2.58 22 6.84 22 12M10.69 8.58l4.74 2.73a.8.8 0 0 1 0 1.37l-4.74 2.74a.8.8 0 0 1-1.19-.68V9.26a.8.8 0 0 1 1.19-.68"></path>');function jv(i){Ze(i,{testId:"play-speed-icon",children:(e,t)=>{var o=hC();$(e,o)},$$slots:{default:!0}})}var _C=Ee('<path d="M12 2a.9.9 0 01.9.9v10.93l4.56-4.57a.9.9 0 011.28 1.28l-6.1 6.1a.9.9 0 01-1.28 0l-6.1-6.1a.9.9 0 111.28-1.28l4.56 4.57V2.9A.9.9 0 0112 2M4 20a.9.9 0 01.9-.9h14.2a.9.9 0 110 1.8H4.9A.9.9 0 014 20"></path>');function Xv(i){Ze(i,{testId:"download-icon",children:(e,t)=>{var o=_C();$(e,o)},$$slots:{default:!0}})}var bC=Ee('<path d="M8.86 2.1h6.28c.67 0 1.2.21 1.68.7l4.38 4.38c.48.48.7 1 .7 1.68v6.28c0 .68-.22 1.2-.7 1.68l-4.38 4.38c-.48.48-1 .7-1.68.7H8.86c-.68 0-1.2-.22-1.68-.7L2.8 16.82c-.48-.48-.7-1-.7-1.68V8.86c0-.68.22-1.2.7-1.68L7.18 2.8c.48-.49 1-.7 1.68-.7m-.44 2L4.1 8.43c-.18.18-.21.24-.21.5v6.17c0 .25.03.31.2.5l4.32 4.3c.18.18.24.21.5.21h6.17c.25 0 .31-.03.5-.2l4.3-4.32c.18-.18.21-.24.21-.5V8.92c0-.25-.03-.31-.2-.5l-4.32-4.3c-.18-.18-.24-.21-.5-.21H8.92c-.25 0-.32.03-.5.2M13 16a1 1 0 1 1-2 0 1 1 0 0 1 2 0m-.1-8.1a.9.9 0 0 0-1.8 0v5.2a.9.9 0 1 0 1.8 0z"></path>');function Zv(i){Ze(i,{testId:"report-icon",children:(e,t)=>{var o=bC();$(e,o)},$$slots:{default:!0}})}var $C=Ee('<path d="M4 12.3V12c0-1.47 0-2.55.08-3.4.07-.9.21-1.48.45-1.95a4.85 4.85 0 0 1 2.12-2.12 5.1 5.1 0 0 1 1.95-.45C9.5 4 10.68 4 12.3 4h4.51c-.03-.16-.09-.33-.17-.49a2.4 2.4 0 0 0-1.05-1.05c-.3-.16-.63-.21-.93-.24-.29-.02-.64-.02-1.03-.02h-1.37c-1.58 0-2.81 0-3.81.08a6.84 6.84 0 0 0-2.62.64 6.65 6.65 0 0 0-2.9 2.91c-.4.76-.57 1.6-.65 2.62-.08 1-.08 2.23-.08 3.81v1.37c0 .4 0 .74.02 1.03.03.3.08.62.24.93A2.4 2.4 0 0 0 4 16.8V12.3ZM10.08 6h-.03c-.53 0-.97 0-1.33.03-.39.03-.76.1-1.12.28a2.9 2.9 0 0 0-1.3 1.3c-.17.35-.24.72-.27 1.1C6 9.09 6 9.53 6 10.06v7.9c0 .53 0 .97.03 1.33.03.39.1.76.28 1.12a2.9 2.9 0 0 0 1.3 1.3c.35.17.72.24 1.1.27.37.03.81.03 1.33.03h6.91c.53 0 .97 0 1.33-.03.39-.03.76-.1 1.12-.28a2.9 2.9 0 0 0 1.3-1.3c.17-.35.24-.72.27-1.1.03-.37.03-.81.03-1.34v-7.9c0-.53 0-.97-.03-1.33-.03-.39-.1-.76-.28-1.12a2.9 2.9 0 0 0-1.3-1.3 2.96 2.96 0 0 0-1.1-.27C17.91 6 17.47 6 16.94 6h-6.87ZM8.41 7.92c.06-.04.18-.07.45-.1.28-.02.65-.02 1.22-.02h6.84c.57 0 .94 0 1.22.02.27.03.39.06.45.1.21.1.39.28.5.49.03.06.06.18.09.45.02.28.02.65.02 1.22v7.84c0 .57 0 .94-.02 1.22-.03.27-.06.39-.1.45-.1.21-.28.39-.49.5-.06.03-.18.06-.45.09-.28.02-.65.02-1.22.02h-6.84c-.57 0-.94 0-1.22-.02a1.23 1.23 0 0 1-.45-.1 1.1 1.1 0 0 1-.5-.49 1.23 1.23 0 0 1-.09-.45c-.02-.28-.02-.65-.02-1.22v-7.84c0-.57 0-.94.02-1.22.03-.27.06-.39.1-.45.1-.21.28-.39.49-.5Z"></path>');function Cp(i){Ze(i,{children:(e,t)=>{var o=$C();$(e,o)},$$slots:{default:!0}})}var yC=Ee('<path d="M12 20.1a8.1 8.1 0 1 0 0-16.2 8.1 8.1 0 0 0 0 16.2m0 1.9a10 10 0 1 1 0-20 10 10 0 0 1 0 20m0-12.37A1.32 1.32 0 1 1 12 7a1.32 1.32 0 0 1 0 2.63m-.95 2.82c0-.54.43-.98.95-.98s.95.44.95.98v3.83c0 .54-.43.98-.95.98a.96.96 0 0 1-.95-.98z"></path>');function Jv(i){Ze(i,{testId:"info-icon",children:(e,t)=>{var o=yC();$(e,o)},$$slots:{default:!0}})}var xC=L('<div class="menu-item-value-wrapper s-1v"><!></div>'),wC={hash:"s-1v",code:".menu-item-value-wrapper.s-1v{line-height:normal}"};function eg(i,e){B(e,!0),Q(i,wC);let[t,o]=He(),r=()=>w(u,"$currentQuality$",t),a=()=>w(m,"$availableQualities$",t),l=()=>w(p,"$isAutoQualityEnabled$",t),d=()=>w(v,"$isMobile$",t),s=$e(),u=s.state.currentQuality$,m=s.state.availableQualities$,p=s.state.isAutoQualityEnabled$,v=s.ui.isMobile,b=f(()=>d$({quality:r(),availableQualities:a(),isAutoQualityEnabled:l()}));var y=xC(),_=T(y);dl(_,{get quality(){return r()},get label(){return n(b)},get isMobile(){return d()}}),S(y),$(i,y),H(),o()}var CC={"quality-settings":({isAutoQualityEnabled:i,currentQuality:e,qualityDetailsSubMenuEnabled:t})=>{let o=(i?Y("auto_quality_option"):e)||"";return{id:"quality-settings",type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_quality",{actual:o}),icon:lc,label:Y("menu_quality"),value:e,valueComponent:eg,weight:ss["quality-settings"],children:t?"quality-settings":"quality-other-settings"}},"traffic-saving-switch":({trafficSavingEnabled:i,toggleTrafficSaving:e})=>({id:"traffic-saving-switch",weight:ss["traffic-saving-settings"],type:"SWITCH",onClick:t=>e(t,"to-video"),ariaLabel:Y("aria_label_submenu_traffic_saving"),icon:Gv,label:Y("menu_traffic_saving"),enabled:i,tooltipText:Y("traffic_saving_helper_text"),maxTooltipWidth:175}),"audio-tracks-settings":({currentAudioStream:i,availableAudioStreams:e})=>{let t=Sp(i,e);return{id:"audio-tracks-settings",weight:ss["audio-language-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_audio_languages",{actual:t}),icon:Yv,label:Y("menu_audio_languages"),value:t,children:"audio-tracks"}},"playback-rate-settings":({availablePlaybackRates:i,currentPlaybackRate:e})=>{var o;let t=((o=i.find(r=>r.value===e))==null?void 0:o.displayValue)||"";return{id:"playback-rate-settings",weight:ss["playback-rate-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_rate",{actual:t}),icon:jv,label:Y("menu_playback_rate"),value:`${e}x`,children:"playback-rate"}},"subtitles-settings":({currentSubtitle:i})=>({id:"subtitles-settings",weight:ss["subtitles-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_subtitle",{actual:i.displayValue}),icon:ga,iconProps:{type:"outline"},label:Y("subtitles_caption"),value:i.displayValue,children:"subtitles"}),download:({onDownloadClick:i})=>({id:"download",weight:ss.download,type:"CLICK",onClick:i,label:Y("download_video_caption"),ariaLabel:Y("aria_label_menu_download"),icon:Xv}),"show-support":({onReportProblemClick:i})=>({id:"show-support",weight:ss.report,type:"CLICK",onClick:i,label:Y("menu_report"),ariaLabel:`${Y("menu_report")}. ${Y("aria_label_new_tab_alert")}`,icon:Zv,isHiddenFor:["desktop"]}),"copy-data":({onCopyDataClick:i})=>({id:"copy-data",weight:ss["copy-data"],type:"CLICK",onClick:i,label:Y("menu_copy_debug"),ariaLabel:Y("menu_copy_debug"),icon:Cp,isHiddenFor:["desktop"]}),"save-trace-info":({onSaveTraceDataClick:i})=>({id:"save-trace-info",weight:ss["save-trace-info"],type:"CLICK",onClick:i,label:Y("menu_save_debug"),ariaLabel:Y("menu_save_debug"),icon:Cp,isHiddenFor:["desktop"]}),"debug-info":({toggleShowDebugInfo:i})=>({id:"debug-info",weight:ss["debug-info"],type:"CLICK",onClick:i,ariaLabel:Y("aria_label_menu_debug_overlay"),label:Y("menu_debug_overlay"),icon:Jv,isHiddenFor:["desktop"]})},g$=({items:i,context:e,additionalSettingsMenuItems:t})=>{let{isMobile:o}=e;return[...i.map(r=>CC[r](e)),...t.map(r=>Gt(Ve({},r),{isAdditional:!0}))].filter(r=>{var a,l,d;return!((a=r==null?void 0:r.isHiddenFor)!=null&&a.length)||!((l=r==null?void 0:r.isHiddenFor)!=null&&l.includes("desktop"))&&!o||!((d=r==null?void 0:r.isHiddenFor)!=null&&d.includes("mobile"))&&o}).sort(Qa)};var IC=(i,e)=>{Ju(i,e)},EC=L('<div><div> </div> <div class="close s-p" data-testid="close-settings-menu"></div></div>'),PC=L('<div data-testid="settings-menu" role="presentation"><!> <ul role="menu"></ul></div>'),kC=L("<div><!> <!></div>"),AC={hash:"s-p",code:'.settings-menu-container.mobile.s-p{width:100%;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}.settings-menu-container.s-p ul{list-style-type:none;margin:0;padding:0}.settings-menu-container.s-p .menu{background-color:var(--settings-bg);border-radius:var(--settings-radius);overflow:hidden;transition:opacity .2s,visibility .2s}.settings-menu-container.s-p .menu .item:first-child:not(.mobile){border-top-left-radius:var(--settings-radius);border-top-right-radius:var(--settings-radius)}.settings-menu-container.s-p .menu .item:last-child{border-bottom-left-radius:var(--settings-radius);border-bottom-right-radius:var(--settings-radius)}.settings-menu-container.s-p .settings-menu .item:first-child:not(.mobile){padding-top:6px}.settings-menu-container.s-p .settings-menu .item:last-child:not(.mobile){padding-bottom:6px}.settings-menu-container.s-p .menu.desktop{bottom:0;max-width:100%;position:absolute;right:0}.settings-menu.s-p{line-height:40px}.settings-menu.desktop.s-p{min-width:300px}.settings-menu-container.s-p .menu.mobile{background:var(--mobile-settings-bg);font-size:15px;line-height:50px;width:100%}.settings-menu-container.s-p .menu.mobile.hidden{display:none}.settings-menu-container.s-p .menu .item:not(.switch-item),.settings-menu-container.s-p .menu .switch-wrapper{align-items:center;color:var(--white);cursor:pointer;display:flex;justify-content:flex-end;position:relative;white-space:nowrap}.settings-menu-container.s-p .menu .item:hover{background-color:var(--settings-item-bg-hover)}.settings-menu-container.s-p .menu .item.mobile:hover{background:var(--mobile-settings-bg)}.settings-menu.s-p .item:not(.switch-item),.settings-menu.s-p .switch-wrapper{padding:0 32px 0 18px}.settings-menu.s-p .item.mobile:not(.switch-item),.settings-menu.s-p .switch-wrapper.mobile{padding:0 14px}.settings-menu.s-p .icon-wrapper{align-items:center;display:flex;height:24px;justify-content:center;margin-right:16px;min-width:24px;width:24px}.settings-menu.s-p .label{flex-grow:1;margin-right:24px;overflow:hidden;text-overflow:ellipsis}.settings-menu.s-p .item.header.mobile:where(.s-p){border-bottom:var(--divider-border);color:var(--white);column-gap:12px;cursor:pointer;display:flex;justify-content:space-between;margin-bottom:4px}.settings-menu-container.s-p .items::-webkit-scrollbar{width:8px}.settings-menu-container.s-p .items::-webkit-scrollbar-track{background-color:#3a3a3a;border-radius:4px;box-shadow:none}.settings-menu-container.s-p .items::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#666;border:1px solid transparent;border-radius:5px;min-height:40px}.settings-menu-container.s-p .items::-webkit-scrollbar-thumb:hover{background-color:#777}.settings-menu-container.s-p .items.mobile{max-height:160px;overflow-x:hidden;overflow-y:auto;text-align:left}.close.s-p{height:12px;margin-right:-12px;padding:12px;position:relative;width:12px}.close.s-p:after,.close.s-p:before{background-color:var(--white);content:" ";height:12px;left:18px;position:absolute;width:2px}.close.s-p:before{transform:rotate(45deg)}.close.s-p:after{transform:rotate(-45deg)}'};function Oc(i,e){B(e,!0),Q(i,AC);let[t,o]=He(),r=()=>w(Ae,"$settingsMenuVisible",t),a=()=>w(ze,"$settingsMenuOpenedByKeyboard",t),l=()=>w(Ne,"$debugPanelVisible",t),d=()=>w(de,"$isMobile",t),s=()=>w(we,"$playerSize",t),u=()=>w(ue,"$hasMpegSources$",t),m=()=>w(ke,"$mobileNotReportControlHidden$",t),p=()=>w(me,"$autoQualityLimitingAvailable$",t),v=()=>w(re,"$availableSubtitlesList$",t),b=()=>w(xe,"$isLiveWithPlaybackSpeed",t),y=()=>w(te,"$availableAudioStreams$",t),_=()=>w(D,"$availablePlaybackRates$",t),x=()=>w(fe,"$currentAudioStream$",t),I=()=>w(G,"$currentPlaybackRate$",t),C=()=>w(Je,"$trafficSavingEnabled",t),R=()=>w(_e,"$currentQuality$",t),A=()=>w(ce,"$isAutoQualityEnabled$",t),P=()=>w(Xe,"$currentSubtitle$",t),E=()=>w(kt,"$additionalSettingsMenuItems$",t),W=()=>w(Ye,"$isAutoQualityAvailable$",t),F=()=>w(Ce,"$availableQualities$",t),U=()=>w(Pe,"$highQualityEnabled",t),X=h(e,"ref",15,void 0),se=h(e,"playerControlsHeight",3,0),j=li({}),ne=li({}),Z=$e(),Te=Dt(),fe=Z.state.audioStream$,te=Z.state.availableAudioStreams$,_e=Z.state.currentQuality$,Ce=Z.state.availableQualities$,me=Z.state.autoQualityLimitingAvailable$,ce=Z.state.isAutoQualityEnabled$,Ye=Z.state.isAutoQualityAvailable$,G=Z.state.currentPlaybackRate$,D=Z.state.availablePlaybackRates$,Xe=Z.state.currentSubtitle$,re=Z.state.availableSubtitlesList$,pe=Z.state.canDownload,ue=Z.state.hasMpegSources$,Ae=Z.ui.settingsMenu.visible$,ze=Z.ui.settingsMenu.openedByBtnKeyboard$,ee=Z.ui.settingsMenu.ref$,de=Z.ui.isMobile,ke=Z.ui.mobileNotReportControlHidden$,xe=Z.state.canChangePlaybackSpeed$,Je=Z.state.trafficSavingEnabled$,Pe=Z.state.highQualityEnabled$,we=Z.ui.playerSize,Ne=Z.ui.debugPanelVisible,Pt=Z.state.isInteractiveTime$,kt=Z.ui.additionalSettingsMenuItems$,Lt=Z.ui.t,pt=Z.actions.internal.downloadVideo,It=Z.actions.internal.closeSettingsMenu,ei=Z.actions.internal.openSettingsSubMenu,Ft=Z.actions.internal.closeSettingsSubMenu,Bt=K(!1),qt=K(void 0),q=s$();Fe(()=>{!r()&&q.current&&(Ft(ne[q.current]),q.popAllSubMenus())}),Fe(()=>{r()||O(qt,void 0)}),Fe(()=>{!q.current&&n(qt)&&mb(j,n(qt))}),Fe(()=>{X()&&ee.set(X())});function Le(yt){return bt(this,null,function*(){var z;q.pushSubMenu(yt),yield _o(),ei(yt,ne[yt]);let Ut=(z=X())==null?void 0:z.firstElementChild;Ut&&gm(Ut)})}function Me(yt){var Ut;yt==null||yt.stopPropagation(),a()||(Ut=e.returnFocus)==null||Ut.call(e),It(),O(Bt,!1)}function ye(yt,Ut){Z.actions.internal.setQuality(yt,{appliesTo:Ut,byUser:!0}),Me()}function Ue(yt){Z.actions.internal.setAudioStream(yt),Me()}function Se(yt,Ut){Z.actions.internal.setTrafficSavingEnabled(yt,Ut),Te.features.qualityDetailsSubMenuEnabled&&Me()}function Tt(yt,Ut){Z.actions.internal.setHighQualityEnabled(yt,Ut),Me()}function ve(yt){Z.actions.internal.setPlaybackRate(yt),Me()}function Be(yt){Z.actions.internal.setSubtitle(yt),Me()}function qe(){pt()}function ct(){(0,Rc.isValidURL)(e.supportLink)&&window.open(e.supportLink,"_blank"),Z.actions.internal.reportProblem(),Z.actions.internal.pause()}function Xt(){Ql(Z.actions.internal.getDebugTextData())}let Mt=()=>{let yt=Z.actions.internal.getTraceTextData(),Ut=new Blob([...yt],{type:"application/json"}),z=window.URL.createObjectURL(Ut);za(z,"vk_player_trace_info","json")};function di(){Ne.set(!l())}function ci(){O(Bt,!0)}function Li(){O(Bt,!1)}function bo(){return d()?`max-height: ${Math.round(s().height*.6)}px`:`max-height: ${s().height-32-se()}px; overflow: auto;`}let $o=f(()=>pe&&u()&&!m()),ui=f(()=>Te.features.trafficSaving&&!m()&&p()&&!Te.features.qualityDetailsSubMenuEnabled),at=f(()=>v().length>0&&!m()),pi=f(()=>!!b()&&!m()),Ji=f(()=>Te.features.audioLanguages&&y().length>=2&&!m()),ft=f(()=>!m());Ot(()=>Pt.subscribe(yt=>{yt&&!d()&&!n(Bt)&&!a()&&Me()}));let Ht=f(()=>{let yt=[n(ft)&&"quality-settings",n(Ji)&&"audio-tracks-settings",n(pi)&&"playback-rate-settings",n(at)&&"subtitles-settings",n(ui)&&"traffic-saving-switch",n($o)&&"download",Te.showSupport&&"show-support","copy-data",Te.features.saveTraceInfoToFile&&"save-trace-info","debug-info"].filter(Ut=>!!Ut);return g$({items:yt,context:{qualityDetailsSubMenuEnabled:Te.features.qualityDetailsSubMenuEnabled,availablePlaybackRates:_(),currentAudioStream:x(),availableAudioStreams:y(),currentPlaybackRate:I(),selectPlaybackRate:ve,trafficSavingEnabled:C(),toggleTrafficSaving:Se,currentQuality:R()||Rc.VideoQuality.INVARIANT,isAutoQualityEnabled:A()||!1,currentSubtitle:P(),isMobile:d(),onDownloadClick:qe,onCopyDataClick:Xt,onReportProblemClick:ct,onSaveTraceDataClick:Mt,toggleShowDebugInfo:di},additionalSettingsMenuItems:E()})}),hi=f(()=>v$({subMenuId:q.current,context:{availablePlaybackRates:_(),selectPlaybackRate:ve,trafficSavingEnabled:C(),toggleTrafficSaving:Se,currentQuality:R()||Rc.VideoQuality.INVARIANT,isAutoQualityEnabled:A()||!1,isAutoQualityAvailable:W()||!1,availableQualities:F(),highQualityEnabled:U(),toggleHighQuality:Tt,availableAudioStreams:y(),availableSubtitlesList:v(),closeSettingsMenu:It,currentAudioStream:x(),isMobile:d(),selectAudioLanguage:Ue,selectQuality:ye,selectSubtitle:Be}}));var rt=kC();let st;var Pi=T(rt);{var rn=yt=>{var Ut=PC();let z;Ut.__keydown=[IC,It];var Vt=T(Ut);{var ut=St=>{var lt=EC();let Ui;var Oi=T(lt),Rn=T(Oi,!0);S(Oi);var On=k(Oi,2);On.__click=Me,S(lt),N((Ii,eo)=>{Ui=oe(lt,1,"item header s-p",null,Ui,Ii),ge(Rn,eo)},[()=>({mobile:d()}),()=>Lt("submenu_settings")]),$(St,lt)};V(Vt,St=>{d()&&St(ut)})}var yi=k(Vt,2);let ti;xi(yi,21,()=>n(Ht),St=>St.id,(St,lt)=>{var Ui=Oe(),Oi=le(Ui);{var Rn=Ii=>{Dv(Ii,{get isMobile(){return d()},get id(){return n(lt).id},get icon(){return n(lt).icon},get iconProps(){return n(lt).iconProps},get label(){return n(lt).label},get ariaLabel(){return n(lt).ariaLabel},get value(){return n(lt).value},get valueComponent(){return n(lt).valueComponent},onClick:()=>{Le(n(lt).children),O(qt,n(lt).id,!0)},get ref(){return j[n(lt).id]},set ref(eo){j[n(lt).id]=eo}})},On=(Ii,eo)=>{{var Dn=wi=>{let Bo=f(()=>`${n(lt).id}-menu-item`);Bv(wi,{get isMobile(){return d()},get id(){return n(Bo)},get onClick(){return n(lt).onClick},get icon(){return n(lt).icon},get label(){return n(lt).label},get ariaLabel(){return n(lt).ariaLabel},closeSettings:Me})},wo=(wi,Bo)=>{{var Ho=yo=>{let hn=f(()=>`${n(lt).id}-menu-item`);Fv(yo,{get isMobile(){return d()},get id(){return n(hn)},get onClick(){return n(lt).onClick},get icon(){return n(lt).icon},get label(){return n(lt).label},get ariaLabel(){return n(lt).ariaLabel},get enabled(){return n(lt).enabled},get tooltipText(){return n(lt).tooltipText},get maxTooltipWidth(){return n(lt).maxTooltipWidth}})};V(wi,yo=>{n(lt).type==="SWITCH"&&yo(Ho)},Bo)}};V(Ii,wi=>{n(lt).type==="CLICK"?wi(Dn):wi(wo,!1)},eo)}};V(Oi,Ii=>{n(lt).type==="OPEN_SUB_MENU"?Ii(Rn):Ii(On,!1)})}$(St,Ui)}),S(yi),it(yi,St=>X(St),()=>X()),S(Ut),N((St,lt,Ui)=>{z=oe(Ut,1,"settings-menu menu s-p",null,z,St),ti=oe(yi,1,"items",null,ti,lt),Qe(yi,Ui)},[()=>({desktop:!d(),mobile:d(),hidden:!!q.current}),()=>({mobile:d()}),bo]),vt("mouseenter",Ut,ci),vt("mouseleave",Ut,Li),$(yt,Ut)};V(Pi,yt=>{r()&&yt(rn)})}var No=k(Pi,2);xi(No,17,()=>n(hi),yt=>yt.id,(yt,Ut)=>{let z=f(()=>{var Vt;return(Vt=n(Ut).minWidth)!=null?Vt:137});Ov(yt,{get isMobile(){return d()},get playerControlsHeight(){return se()},get returnFromSubMenu(){return q.popSubMenu},get id(){return n(Ut).id},get title(){return n(Ut).title},get closeSettingsMenu(){return It},openSubMenuList:Le,get items(){return n(Ut).items},get minWidth(){return n(z)},get refMenuItems(){return j},get listRef(){return ne[n(Ut).id]},set listRef(Vt){ne[n(Ut).id]=Vt}})}),S(rt),N(yt=>st=oe(rt,1,"settings-menu-container s-p",null,st,yt),[()=>({mobile:d(),hidden:!r()})]),$(i,rt),H(),o()}et(["keydown","click"]);var LC=L('<button class="btn s-1c"> </button>'),MC={hash:"s-1c",code:"button.btn.s-1c{background:hsla(0,0%,100%,.1);border-radius:8px;font-size:14px;line-height:18px;margin-top:12px;padding:6px 12px 7px}"};function tg(i,e){Q(i,MC);var t=LC();t.__click=function(...r){var a;(a=e.onClick)==null||a.apply(this,r)};var o=T(t,!0);S(t),N(()=>ge(o,e.label)),$(i,t)}et(["click"]);var VC=L('<div class="container s-r"><div class="notification s-r"><div><p class="description s-r"><!></p> <!></div> <!></div></div>'),RC={hash:"s-r",code:".container.s-r{display:flex;justify-content:center;left:0;pointer-events:none;position:absolute;right:0;top:20px;z-index:var(--controls-container-z-index)}.notification.s-r{background:var(--notification-bg);border-radius:var(--notification-radius);display:inline-flex;gap:10px;padding:9px 14px 10px 12px;pointer-events:auto}.description.s-r{font-size:13px;line-height:16px;margin:0;white-space:pre}"};function Dc(i,e){B(e,!0),Q(i,RC);let t=340,{features:{forceAutoQualityWhenSevereStallHappens:o}}=Dt(),{ui:{t:r}}=$e(),a=r(o?"slow_video_notification_force_description":"slow_video_notification_suggest_description");var l=VC(),d=T(l),s=T(d),u=T(s),m=T(u);Vc(m,{get message(){return a}}),S(u);var p=k(u,2);{var v=y=>{let _=f(()=>r("slow_video_notification_button"));tg(y,{get label(){return n(_)},get onClick(){return e.onSelectAutoQuality}})};V(p,y=>{o||y(v)})}S(s);var b=k(s,2);Hs(b,{get onClick(){return e.onClose}}),S(d),S(l),Ns(3,d,()=>ba,()=>({duration:t})),$(i,l),H()}var Nc=require("@vkontakte/videoplayer-shared/es2015");var cl="annotation",Tp=class{constructor(e){this.slots=new Map;this.disabledIds=new Set(e)}init(e,t){this.shadowRootContainer=e,this.store=t}add(e,t){var s;let{overlay:o,id:r,controlsBehaviour:a,hideAllControls:l}=t;if(this.disabledIds.has(r))return{success:!1,message:"current slotId is disabled via config"};let d=typeof e=="function"?e():e;return d.setAttribute("slot",cl),this.setupSlotStyles(d,o),this.shadowRootContainer.append(d),this.slots.set(r,{rootElement:d,options:t}),a&&this.runHidingControlsWhenIntersected(r,a),l&&((s=this.store)==null||s.ui.isControlsAvailable.set(!1)),{success:!0}}setupSlotStyles(e,t){switch(e.style.position="absolute",t){case"over_video":e.style.zIndex="calc(var(--video-container-z-index) + 1)";break;case"over_controls":e.style.zIndex="calc(var(--controls-container-z-index) + 1)";break;default:e.style.zIndex="0"}}runHidingControlsWhenIntersected(r,a){return bt(this,arguments,function*(e,{observedSlotElementId:t,controlsToObserve:o}){var v;let l=this.slots.get(e);if(!l)return;let d=yield this.findSlotElement(l.rootElement,t,e),{controls:s,hiddenControls:u}=((v=this.store)==null?void 0:v.ui)||{},m=new MutationObserver(b=>b.forEach(()=>{let y=zs(d,this.shadowRootContainer);o.forEach(_=>{let x=s==null?void 0:s[_],I=x?be(x):null,C=u==null?void 0:u[_];I&&(C==null||C.set((0,Nc.isIntersecting)(I,y)))})}));m.observe(d,{childList:!0,subtree:!0}),l.observer=m;let p=new Nc.Subscription;o.forEach(b=>{s&&p.add(s[b].subscribe(y=>{let _=u==null?void 0:u[b];y&&y.isDisplayed?_==null||_.set((0,Nc.isIntersecting)(y,zs(d,this.shadowRootContainer))):_==null||_.set(!1)}))}),l.subs=p})}findSlotElement(e,t,o){return bt(this,null,function*(){return new Promise(r=>{let a=null,l=new MutationObserver(()=>{if(a=e.querySelector(`#${t}`),a){l.disconnect();let s=this.slots.get(o);s&&(s.observerForFindingSlotElement=void 0),r(a)}});l.observe(e,{childList:!0,subtree:!0});let d=this.slots.get(o);d&&(d.observerForFindingSlotElement=l)})})}remove(e){var u,m;let t=this.slots.get(e);if(!t)return;let{rootElement:o,observer:r,observerForFindingSlotElement:a,subs:l,options:{controlsBehaviour:d,hideAllControls:s}}=t;o&&o.remove(),[r,a].forEach(p=>p==null?void 0:p.disconnect()),l==null||l.unsubscribe(),this.slots.delete(e),s&&((u=this.store)==null||u.ui.isControlsAvailable.set(!0)),(m=d==null?void 0:d.controlsToObserve)==null||m.forEach(p=>{var v,b;(b=(v=this.store)==null?void 0:v.ui.hiddenControls[p])==null||b.set(!1)})}destroy(){for(let e in this.slots.keys())this.remove(e);this.slots.clear()}haveSlots(){return this.slots.size>0}};var OC=L('<div class="container s-5"><!></div>'),DC={hash:"s-5",code:".container.s-5{align-items:center;animation-fill-mode:forwards;animation-name:s-5-videoPlayerStatusIconPopup;background-color:#00000073;border-radius:100%;display:flex;height:64px;justify-content:center;width:64px;will-change:opacity,scale}@keyframes s-5-videoPlayerStatusIconPopup{0%{opacity:0;scale:.6}10%{animation-timing-function:ease-in;opacity:1;scale:1}75%{opacity:1;scale:1}90%{animation-timing-function:ease-out;opacity:0;scale:.4}to{opacity:0;scale:0}}"};function Bc(i,e){B(e,!0),Q(i,DC);let t=h(e,"reversed",3,!1);var o=Oe(),r=le(o);Rs(r,()=>e.Icon,a=>{var l=OC(),d=T(l);Hi(d,()=>e.Icon,(s,u)=>{u(s,{get size(){return"48"},get reversed(){return t()}})}),S(l),N(()=>Qe(l,`animation-duration: ${e.duration}ms`)),$(a,l)}),$(i,o),H()}var ig=require("@vkontakte/videoplayer-core/es2015"),NC=L('<div class="container s-z"><!></div>'),BC={hash:"s-z",code:".container.s-z{align-items:center;display:flex;height:100%;justify-content:center;pointer-events:none;position:absolute;width:100%}"};function og(i,e){B(e,!0),Q(i,BC);let[t,o]=He(),r=()=>w(s,"$playbackState$",t),a=()=>w(m,"$previewTrackActive",t),l=()=>w(p,"$previewTrackDragInProgress",t),d=()=>w(u,"$isPlaying$",t),{state:{playbackState$:s,isPlaying$:u},ui:{previewTrackActive:m,previewTrackDragInProgress:p}}=$e(),{features:{playbackStatusShow:v},playbackStatusAnimationDuration:b}=Dt(),y=0,_=K(null),x=K(!1);Fe(()=>{r()===ig.PlaybackState.PLAYING?O(_,Ln,!0):r()===ig.PlaybackState.PAUSED?O(_,Ks,!0):O(_,null)}),Fe(()=>{if(!(!v||a()||l()))return y=window.setTimeout(()=>{y=0,O(_,null)},b),()=>{y&&(window.clearTimeout(y),y=0)}}),Fe(()=>{d()&&!n(x)&&(O(x,!0),O(_,null))});var I=Oe(),C=le(I);{var R=A=>{var P=NC(),E=T(P);Bc(E,{get duration(){return b},get Icon(){return n(_)}}),S(P),$(A,P)};V(C,A=>{n(_)&&v&&A(R)})}$(i,I),H(),o()}var HC=L('<div><div data-testid="video-container"></div></div>'),FC={hash:"s-c",code:".video-container.s-c,.video-wrapper.s-c{height:100%;left:0;position:absolute;top:0;width:100%}.video-wrapper.s-c{background:var(--black)}.video-container.s-c,.video-wrapper.s-c{z-index:var(--video-container-z-index)}.video-container.s-c{transition:var(--rotate-transition-duration) ease all}.video-container.fast-rotate.s-c{transition:none}.nocursor.s-c{cursor:none}"};function ul(i,e){B(e,!0),Q(i,FC);let[t,o]=He(),r=()=>w(p,"$rotateAlpha",t),a=()=>w(v,"$playerSize",t),l=()=>w(m,"$playerPhase",t),d=()=>w(y,"$chromecastConnected$",t),s=()=>w(b,"$isPlaying$",t),u=h(e,"videoContainer",15),{playerPhase:m,ui:{rotateAlpha:p,playerSize:v},state:{isPlaying$:b,chromecastConnected$:y}}=$e(),{isSmoothVideoRotate:_}=Dt(),x=f(()=>u()&&r()%180?a().height/a().width:1);var I=HC();let C;I.__contextmenu=function(...P){var E;(E=e.onContextMenu)==null||E.apply(this,P)},I.__mousedown=function(...P){var E;(E=e.onMouseDown)==null||E.apply(this,P)},I.__mouseup=function(...P){var E;(E=e.onMouseUp)==null||E.apply(this,P)},I.__click=function(...P){var E;(E=e.onClick)==null||E.apply(this,P)},I.__dblclick=function(...P){var E;(E=e.onDblClick)==null||E.apply(this,P)};var R=T(I);let A;it(R,P=>u(P),()=>u()),S(I),N((P,E)=>{C=oe(I,1,"video-wrapper s-c",null,C,P),A=oe(R,1,"video-container s-c",null,A,E),Qe(R,`transform: rotate(${r()}deg) scale(${n(x)})`),De(R,"data-is-playing",s())},[()=>({hidden:l()!=="video"||d(),nocursor:e.hideCursor}),()=>({"fast-rotate":!_})]),$(i,I),H(),o()}et(["contextmenu","mousedown","mouseup","click","dblclick"]);var UC=L('<div><span class="text s-10"> </span> <!></div>'),zC={hash:"s-10",code:".root.s-10{background-color:var(--double-forward-bg);border-radius:100px;color:var(--white);display:flex;gap:4px;left:50%;opacity:0;padding:6px 12px;pointer-events:none;position:absolute;top:24px;transition:opacity var(--controls-transition-duration) var(--controls-transition-fn);visibility:hidden}.root.s-10,.root.visible.s-10{transform:translateX(-50%)}.root.visible.s-10{opacity:1;visibility:visible}.text.s-10{font-size:13px;font-weight:600;line-height:16px}"};function ng(i,e){B(e,!0),Q(i,zC);let{ui:{t}}=$e();var o=UC();let r;var a=T(o),l=T(a,!0);S(a);var d=k(a,2);Pc(d,{get size(){return"16"},fill:"currentColor"}),S(o),N((s,u)=>{r=oe(o,1,"root s-10",null,r,s),ge(l,u)},[()=>({visible:e.isVisible}),()=>t("double_forward_label")]),$(i,o),H()}var WC=L('<div class="container s-y" role="button" data-testid="preview-track-overlay"><div class="icon s-y"><!></div></div>'),KC={hash:"s-y",code:".container.s-y{background-color:rgba(0,0,0,.48);cursor:pointer;height:100%;position:absolute;width:100%}.container.s-y,.icon.s-y{align-items:center;display:flex;justify-content:center}.icon.s-y{background-color:#00000073;border-radius:100%;height:64px;transition:transform .2s;transition-timing-function:ease-out;width:64px;will-change:transform}.container.s-y:hover .icon:where(.s-y){transform:scale(1.15)}"};function rg(i,e){B(e,!1),Q(i,KC);let o=$e().actions.internal.closePreviewTrack,r=200,a=u=>{u.stopPropagation(),o()};on();var l=WC();l.__click=a;var d=T(l),s=T(d);return Ln(s,{get size(){return"32"}}),S(d),S(l),Ns(3,l,()=>ba,()=>({duration:r})),$(i,l),Ff(e,"handleClick",a),H({handleClick:a})}et(["click"]);var qC=(i,e,t,o,r,a)=>{if(i.stopPropagation(),e()||o()){a();return}},QC=L("<div><!></div>"),GC=L('<div class="spherical-video-icon s-8"><!></div>'),YC=L("<div><!></div>"),jC=L('<div class="settings-menu s-8"><!></div>'),XC=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),ZC=L("<!> <!> <!>",1),JC=L('<div class="blocked s-8"></div>'),eT=L('<div class="player-wrapper s-8"><!> <div class="overlay-container"></div></div> <!>',1),tT={hash:"s-8",code:".blocked.s-8,.player-wrapper.s-8{height:100%;position:absolute;width:100%}.blocked.s-8{z-index:var(--overlay-container-z-index)}.player-wrapper.s-8 .player-media{background:var(--black);height:100%;left:0;position:absolute;top:0;transition:transform .2s ease-in-out;width:100%}.spherical-video-icon.s-8{display:inline-block;left:calc(50% - 38px);position:absolute;top:calc(50% - 23px)}.ads-container.s-8{background:var(--black);height:100%;left:0;position:absolute;top:0;width:100%;z-index:var(--ads-container-z-index)}.settings-menu.s-8{bottom:57px;left:0;position:absolute;right:18px;transition:opacity .2s;z-index:var(--settings-menu-z-index)}"};function ag(i,e){B(e,!0),Q(i,tT);let[t,o]=He(),r=()=>w(Fr,"$notificationsToShow$",t),a=()=>w(ui,"$playerPhase",t),l=()=>w(rn,"$isLoaderVisible",t),d=()=>w(Li,"$adPlaybackState",t),s=()=>w(yi,"$crashed",t),u=()=>w(Dn,"$isInteractiveTime$",t),m=()=>w(ft,"$settingsMenuVisible",t),p=()=>w(wo,"$isInteractiveExpectation$",t),v=()=>w(Ji,"$controlsVisible",t),b=()=>w(Bo,"$touched",t),y=()=>w(cs,"$graphIsOpened$",t),_=()=>w(at,"$isFullscreen",t),x=()=>w(Hr,"$autoplayNextEnabled$",t),I=()=>w(z,"$postrollPassed",t),C=()=>w(No,"$isEnded$",t),R=()=>w(sr,"$cursorInside",t),A=()=>w(_n,"$isControlsAvailable",t),P=()=>w(yr,"$doubleForwardOn$",t),E=()=>w(or,"$fakeIsPlaying$",t),W=()=>w(Fn,"$bottomNoSmooth",t),F=()=>w(Nr,"$interactiveTimeIndicator",t),U=()=>w(Oi,"$playerSize",t),X=()=>w(On,"$is3DVideo",t),se=()=>w(bn,"$doubleForwardAvailable$",t),j=()=>w(st,"$contextMenuVisible$",t),ne=()=>w(ci,"$playbackState$",t),Z=()=>w(Ho,"$hotKeyMapData",t),Te=()=>w(hi,"$scrubbingInProgress",t),fe=()=>w(rt,"$volumeChangingInProgress",t),te=()=>w(yt,"$chromecastConnected$",t),_e=()=>w(an,"$controlsTimeoutActive",t),Ce=()=>w(Rn,"$adsPlaybackState",t),me=()=>w(Ht,"$settingsMenuOpenedByKeyboard",t),ce=()=>w(ko,"$contextMenuOpenedByKeyboard$",t),Ye=()=>w(Qo,"$contextMenuOpenedByHotKey$",t),G=()=>w(Cn,"$contextMenuButtonRef$",t),D=()=>w(dr,"$contextMenuLastActiveElem$",t),Xe=()=>w(pi,"$isFullscreenOpenedByKeyboard",t),re=()=>w(hn,"$positionExact$",t),pe=()=>w(di,"$language$",t),ue=()=>w(Pr,"$previewTrackActive$",t),Ae=()=>w(Ii,"$icon3DVideoVisible",t),ze=()=>w(Ut,"$chromecastDeviceName$",t),ee=()=>w(lt,"$currentSubtitle$",t),de=()=>w(Ui,"$currentSubtitleCaptions$",t),ke=()=>w(bo,"$position$",t),xe=()=>w($o,"$duration$",t),Je=()=>w(Vt,"$isLive$",t),Pe=()=>w(ut,"$isPlaying$",t),we=()=>w(Br,"$contextMenuPosition$",t),Ne=()=>w(yo,"$showHotKeyMap",t),Pt=()=>w(Pi,"$debugPanelVisible",t),kt=()=>w(sn,"$userActionsDisabled$",t),Lt=h(e,"videoContainer",15),pt=h(e,"adsSlotId",3,void 0),It=h(e,"adsParams",3,void 0),ei=h(e,"adsAutoplayParam",3,void 0),Ft=h(e,"duration",3,void 0),Bt=h(e,"logoTargetUrl",3,""),qt=h(e,"showNextPrevButtons",3,!1),q=h(e,"nextButtonActive",3,!1),Le=h(e,"prevButtonActive",3,!1),Me=h(e,"endScreenVideoTitle",3,void 0),ye=h(e,"endScreenVideoThumb",3,void 0),Ue=h(e,"isOneVideoPlaylist",3,!1),Se=h(e,"shadowRootContainer",3,void 0),Tt=h(e,"outerContainerRef",3,void 0),ve=h(e,"playerStarted",3,!1),Be=h(e,"fullScreenTarget",3,void 0),qe=h(e,"showMiniTimer",3,!1),ct=h(e,"showEndScreen",3,!0),Xt=h(e,"keyboardControls",15),Mt=e.store.getLogger().createComponentLog("Root component"),di=e.store.interfaceLanguage$,ci=e.store.state.playbackState$,Li=e.store.ads.playbackState,bo=e.store.state.positionWithScrubbing$,$o=e.store.state.duration$,ui=e.store.playerPhase,at=e.store.ui.isFullscreen,pi=e.store.ui.isFullscreenOpenedByKeyboard,Ji=e.store.ui.controlsVisible,ft=e.store.ui.settingsMenu.visible$,Ht=e.store.ui.settingsMenu.openedByBtnKeyboard$,hi=e.store.ui.scrubbingInProgress,rt=e.store.ui.volumeChangingInProgress,st=e.store.ui.contextMenu.visible$,Pi=e.store.ui.debugPanelVisible,rn=e.store.state.isLoaderVisible,No=e.store.state.isEnded$,yt=e.store.state.chromecastConnected$,Ut=e.store.state.chromecastDeviceName$,z=e.store.ads.postrollPassed,Vt=e.store.state.isLive$,ut=e.store.state.isPlaying$,yi=e.store.state.crashed$,ti=e.store.webApi.annotationsApi,St=e.store.webApi.pictureInPictureApi,lt=e.store.state.currentSubtitle$,Ui=e.store.state.currentSubtitleCaptions$,Oi=e.store.ui.playerSize,Rn=e.store.ads.playbackState,On=e.store.ui.is3DVideo,Ii=e.store.ui.icon3DVideoVisible,eo=e.store.state.isInteractive,Dn=e.store.state.isInteractiveTime$,wo=e.store.state.isInteractiveExpectation$,wi=e.store.state.hasInteractiveBranches,Bo=e.store.ui.touched,Ho=e.store.ui.modals.hotKeyMap.data,yo=e.store.ui.modals.hotKeyMap.show,hn=e.store.state.positionExact$,as=e.store.ui.overlayContainer$,Nr=e.store.ui.controls.interactiveTimeIndicator,ls=e.store.state.showInteractiveTimeIndicator,Br=e.store.ui.contextMenu.position$,tr=e.store.actions.internal.setQuality,ds=e.store.actions.internal.closeSettingsMenu,Hr=e.store.ui.autoplayNextEnabled$,sn=e.store.ui.userActionsDisabled,_n=e.store.ui.isControlsAvailable,$r=e.store.ui.videoTitleInfo,yr=e.store.ui.doubleForwardOn$,bn=e.store.ui.doubleForwardAvailable$,ir=e.store.actions.internal.getVideoElement,xr=e.store.actions.internal.checkFullscreenSupport,{fakeIsPlaying$:or,notifications$:nr,graphIsOpened$:cs}=xo(),So=K(void 0),wr=K(void 0),zi=K(void 0),Sr=K(void 0),Nn,_t,ii;Ho.set(lb());let{closeNotification:Cr,notificationsToShow$:Fr}=nr,Ur=f(()=>!!r().slow_video),Bn=()=>Cr("slow_video"),Hn=f(()=>(a()==="video"&&l()||a()==="ads"&&d()==="inactive")&&!s()),Fo=K(void 0),Fn=ae(!1),rr,an=ae(!1),$n=ae(),sr=ae(!1),yn=K(!1),ln=K(!1),Di=K(!1),uo=K(!(e.autoplay&&!e.uiConfig.controls.showOnStartupAtAutoplay)),dn=f(()=>u()&&!m()&&!(n(yn)||n(ln))&&!(n(Di)&&!p())),ar=!0,Tr=f(()=>e.uiConfig.features.thumbTimer&&qe()&&a()==="video"&&!v()&&!s()&&!eo&&(e.uiConfig.hideThumbTimerAfterTouch&&!b()||!e.uiConfig.hideThumbTimerAfterTouch)),xn=e.uiConfig.titleShowBehaviour,lr=f(()=>!["video","thumb"].includes(a())||xn==="never"||y()?!1:xn==="fullscreen"?_():!0),je=f(()=>xn==="always"||a()==="thumb"?!1:!v()),_i=K(!1),Uo=f(()=>(ct()||e.showAutoplayNext&&x())&&!!Me()&&!!ye()&&(e.showAds&&I()||!e.showAds)&&C()&&!s()&&!n(_i)&&!wi),wn=f(()=>R()&&!(v()||n(Uo))&&!u()&&A()&&!P()),Co=K(!1),cn=f(()=>E()!==null),{toggle:po}=or,To=!1,ki=null;St==null||St.setContext(wd());let zr=()=>{e.autoplay&&!eo&&e.uiConfig.controls.showOnStartupAtAutoplay&&Wi(e.uiConfig.controls.hideTimeout)};e.store.setUiCallbacks({onStarted:zr});let Un=()=>{window.clearTimeout(Nn),an.set(!1)},ws=()=>{window.clearTimeout(_t),$n.set(null)},Wi=he=>{Un(),an.set(!0),Nn=window.setTimeout(()=>an.set(!1),he);let Ct=he-100;rr=window.setTimeout(()=>{W()&&Fn.set(!1)},Ct>0?Ct:he)},Ss=(he,Ct)=>{ws(),$n.set(Ct),_t=window.setTimeout(()=>$n.set(null),he)},us=On.subscribe(he=>{Ii.set(he),he&&(window.clearTimeout(ii),ii=window.setTimeout(()=>Ii.set(!1),e.uiConfig.controls.hide360IconTimeout))}),Ir=()=>bt(null,null,function*(){var Ct,Jt,oi,Go;let he=ca();if(he){let mo=Zd(),io=un();he=mo===io||mo===Se()}if(he){Wi(e.uiConfig.controls.hideTimeoutFullscreen);try{yield St==null?void 0:St.exit()}catch(mo){Mt({message:String(mo)})}}at.set(he),e.store.getAdmanWrapper().setFullscreen(he),_()?(Jt=(Ct=e.store.callbacks)==null?void 0:Ct.onFullscreenEnter)==null||Jt.call(Ct):(Go=(oi=e.store.callbacks)==null?void 0:oi.onFullscreenExit)==null||Go.call(oi)}),zo=he=>{Oi.set(he)},Wr=()=>{if(n(So)){let{width:he,height:Ct}=n(So).getBoundingClientRect();Oi.set({width:he,height:Ct})}};Ot(()=>{var Ct;return Xu(Ir),e.uiConfig.features.annotationsInside&&(ti==null||ti.init(n(So))),St==null||St.assignPlayerContainer(n(So)),e.uiConfig.disablePiPResizeHandling||St==null||St.setExternalEventHandlers({resize:zo,leavepictureinpicture:Wr}),e.interactiveContainer&&((Ct=Lt().parentElement)==null||Ct.insertBefore(e.interactiveContainer,Lt().nextSibling)),()=>{window.clearTimeout(Nn),window.clearTimeout(rr),window.clearTimeout(_t),window.clearTimeout(ii),us(),St==null||St.dispose().catch(Jt=>{Mt({message:String(Jt)})}),Zu(Ir)}});let un=()=>{let he=e.uiConfig.features.fullscreenInternalTargetPlayerContainer||!Tt()?n(So):Tt(),Ct=he.getRootNode(),Jt=Ct instanceof ShadowRoot?Ct.host:Ct,oi=Be()instanceof HTMLElement&&Be().contains(Jt);return e.uiConfig.allowChangingFullscreenTarget&&Be()&&oi?Be():he},Mi=()=>{st.set(!1)},We=()=>{ds(),Mi()},Rt=()=>bt(null,null,function*(){if(!xr()){Mt({message:"fullscreen disabled"});return}Mi(),ca()?(yield ju(document),Mt({message:"exit fullscreen"})):(Mt({message:"request fullscreen"}),yield Yu(un()))}),fi=he=>{y()||(he.preventDefault(),st.set(!0),Br.set({left:he.clientX,top:he.clientY}))};function Wo(){sr.set(!0),eo||Wi(e.uiConfig.controls.hideTimeoutCursor)}function Io(he){var mo,io;let{relatedTarget:Ct}=he,oi=!!(Ct&&((mo=n(zi))!=null&&mo.contains(Ct)))&&((io=Xt())==null?void 0:io.isFocused()),Go=e.uiConfig.controls.showOnStartupAtAutoplay||!!Ct;!eo&&!oi&&Go&&(Fn.set(!0),Wi(e.uiConfig.controls.hideTimeoutCursor))}function Eo(){sr.set(!1),O(ln,!1),O(yn,!1),To=!1,e.store.actions.internal.releaseCamera(),Wi(e.uiConfig.controls.hideTimeout),P()&&qo()}function Ki(he){return he?he.offsetTop+Ki(he.offsetParent):0}function Ko(he){return he?he.offsetLeft+Ko(he.offsetParent):0}function zn(he){if(F()&&ls){let Ct=he.currentTarget,Jt=Ki(Ct),oi=Ko(Ct),Go=he.pageX-oi,mo=he.pageY-Jt,{left:io,bottom:Qn,right:Qr}=F(),Ps=Qr-io;return Go>=io-Ps&&mo<=Qn+Ps}}function Er(he){if(n(So)){let Ct=Ki(he.currentTarget),Jt=U().height,oi=he.pageY-Ct;if(zn(he)){O(ln,!1);return}oi<40?O(ln,!0):oi>Jt-40?O(yn,!0):(O(ln,!1),m()||O(yn,!1))}}function Po(he){Er(he),!n(dn)&&!P()&&Wi(e.uiConfig.controls.hideTimeoutCursor),X()&&To&&ki&&e.store.actions.internal.moveCameraFocusPX(ki.clientX-he.clientX,ki.clientY-he.clientY,he.timeStamp-ki.timeStamp),ki=he}let fo=null,Sn=()=>{fo=window.setTimeout(()=>{e.store.actions.internal.changeDoubleForwardOn(!0),Un()},e.uiConfig.doubleForwardActivationTime)},qo=()=>{e.store.actions.internal.changeDoubleForwardOn(!1),fo&&clearTimeout(fo),fo=null},Wn=he=>{he.preventDefault(),he.button===0&&(To=!0,e.store.actions.internal.holdCamera(),se()&&Sn()),!To&&Wi(e.uiConfig.controls.hideTimeoutCursor)},Kr=he=>{he.preventDefault(),he.button===0&&(ki=he,To=!1,e.store.actions.internal.releaseCamera()),!P()&&Wi(e.uiConfig.controls.hideTimeoutCursor)},qr=he=>{he.preventDefault(),ar&&(Mt({message:"double click on video"}),Rt(),Wi(e.uiConfig.controls.hideTimeoutCursor))},Kn=he=>{var Ct;if(he.preventDefault(),P()){qo();return}if(fo&&qo(),j()||m()){We();return}if(!(C()&&!wi)){if(n(cn))return po();if((Ct=Xt())==null||Ct.focus(),!ve()){e.firstStart(),Wi(e.uiConfig.controls.hideTimeoutCursor);return}(!e.uiConfig.preventPauseOnVideoClick||ne()!==sg.PlaybackState.PLAYING)&&e.store.actions.internal.togglePlay(),Wi(e.uiConfig.controls.hideTimeoutCursor)}},ot=he=>{We(),Bo.set(!0),Wi(e.uiConfig.controls.hideTimeout),he&&Ss(e.uiConfig.controls.hideHotKeyHelpers,he)},Zt=()=>{var he,Ct;We(),(he=e.store.callbacks)!=null&&he.onOpenHotKeyMap?(Ct=e.store.callbacks)==null||Ct.onOpenHotKeyMap(Z()):yo.update(Jt=>!Jt)},Si=()=>{Bo.set(!0)},ko=e.store.ui.contextMenu.openedByBtnKeyboard$,Cn=e.store.ui.contextMenu.btnRef$,qn=K(void 0),Qo=e.store.ui.contextMenu.openedByHotKey$,dr=e.store.ui.contextMenu.lastActiveElem$,ps=K(!1),Pr=e.store.ui.previewTrackActive;Fe(()=>{as.set(n(Fo))}),Fe(()=>{O(Di,n(uo)&&ne()!==sg.PlaybackState.PLAYING,!0),n(uo)||Et(()=>O(uo,!0))}),Fe(()=>{var Ct,Jt;let he=(n(Di)||C()||m()||Te()||fe()||te()||_e()||n(ps))&&!n(dn)&&(a()==="video"||a()==="ads"&&(e.uiConfig.controls.showOnStartupAtAutoplay||Ce()!=="inactive"))&&!s()&&A();Ji.set(he),!he&&!_e()&&((Ct=n(zi))!=null&&Ct.contains(rp()))&&((Jt=Xt())==null||Jt.focus())}),Fe(()=>{!Te()&&n(Co)&&!u()&&Wi(e.uiConfig.controls.hideTimeoutCursor),Et(()=>O(Co,Te(),!0))}),Fe(()=>{n(Sr),m(),me(),Et(()=>nc(n(Sr),m(),me()))}),Fe(()=>{n(qn),j(),ce(),Ye(),Et(()=>{let he=ce()||Ye();nc(n(qn),j(),he)})}),Fe(()=>{let he=G();he&&(j(),Et(()=>Gl(he,j(),ko)))}),Fe(()=>{let he=D();he&&(j(),Et(()=>fb(he,j(),Qo)))}),Fe(()=>{var he;!Xe()&&_()&&(Et(()=>pi.set(!1)),(he=Xt())==null||he.focus())}),Fe(()=>{y()&&We()});let Cs=K(void 0),Ys=he=>{$r.set(Jn(ir(),{title:n(Cs)},"title",he))},xa=(he,Ct)=>{var mo,io;let Jt=(io=(mo=e.store.callbacks)==null?void 0:mo.uiInfo)==null?void 0:io.onUpcomingLiveViewStateChanged;if(!Jt)return;let oi=!!Ct,Go=Ve(Ve({},Jn(n(So),{upcomingLiveScreen:Ct},"upcomingLiveScreen",oi)),he);Jt(Go)},mt="",ai=f(()=>{var he;return n(je)?mt:(he=e.getVideoDeeplink)==null?void 0:he.call(e,re())});Fe(()=>{mt=n(ai)});var Ao=eT();vt("blur",Ma,We);var Ci=le(Ao);Ci.__mousemove=Po;var to=T(Ci);let Ts=f(()=>a()==="ads"),Is=f(()=>n(cn)?po:void 0);it(Sm(to,{startDoubleForwardActivationTimer:Sn,stopDoubleForward:qo,toggleFullscreen:Rt,hideContextMenu:We,showHotKeyHelpers:ot,showKeyMap:Zt,get isAds(){return n(Ts)},get fakePlayButtonHandler(){return n(Is)},get nextButtonActive(){return q()},get prevButtonActive(){return Le()},children:(he,Ct)=>{var Jt=ZC(),oi=le(Jt);ul(oi,{get hideCursor(){return n(wn)},onClick:Kn,onContextMenu:fi,onMouseDown:Wn,onMouseUp:Kr,onDblClick:qr,get videoContainer(){return Lt()},set videoContainer(io){Lt(io)}});var Go=k(oi,2);Ba(Go,()=>"slot",!1,(io,Qn)=>{so(io,()=>({name:cl}))});var mo=k(Go,2);Rs(mo,pe,io=>{var Qn=XC(),Qr=le(Qn);let Ps=f(()=>a()!=="thumb"||s()||eo&&e.autoplay);al(Qr,{get hidden(){return n(Ps)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart},onContextMenu:fi,onClick:Mi});var ml=k(Qr,2);{var Gr=Ke=>{rg(Ke,{})};V(ml,Ke=>{ue()&&Ke(Gr)})}var fs=k(ml,2);og(fs,{});var js=k(fs,2);ng(js,{get isVisible(){return P()}});var cr=k(js,2);{var vd=Ke=>{let $i=f(()=>{var Yo;return(Yo=e.live)==null?void 0:Yo.startTime});Lc(Ke,{get thumbUrl(){return e.thumbUrl},get startTime(){return n($i)},onUpcomingLiveViewStateChanged:xa,onContextMenu:fi,onClick:Mi})};V(cr,Ke=>{a()==="LiveWaitingStart"&&Ke(vd)})}var vl=k(cr,2);{var Yr=Ke=>{ll(Ke,{kind:"recover",get thumbUrl(){return e.thumbUrl},onContextMenu:fi,onClick:Mi})};V(vl,Ke=>{a()==="LiveWaitingRecover"&&Ke(Yr)})}var wa=k(vl,2);{var gd=Ke=>{ll(Ke,{kind:"record",get thumbUrl(){return e.thumbUrl},onContextMenu:fi,onClick:Mi})};V(wa,Ke=>{a()==="LiveWaitingRecord"&&Ke(gd)})}var gl=k(wa,2);{var hl=Ke=>{var $i=QC();let Yo;var kr=T($i);Jd(kr,{get adsSlotId(){return pt()},get adsParams(){return It()},get adsAutoplayParam(){return ei()},get duration(){return Ft()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S($i),N(Lo=>Yo=oe($i,1,"ads-container s-8",null,Yo,Lo),[()=>({hidden:a()!=="ads"})]),$(Ke,$i)};V(gl,Ke=>{e.showAds&&ve()&&Ke(hl)})}var Sa=k(gl,2);{var gt=Ke=>{let $i=f(()=>!ct()&&e.showAutoplayNext&&x());ym(Ke,{get title(){return Me()},get thumb(){return ye()},get isHide(){return n($i)},clickCloseIcon:()=>O(_i,!0)})};V(Sa,Ke=>{n(Uo)&&Me()&&ye()&&Ke(gt)})}var ht=k(Sa,2);{var oo=Ke=>{let $i=f(()=>_()?"md":"sm"),Yo=f(()=>{var kr;return(kr=e.store.callbacks)==null?void 0:kr.onTitleClicked});kv(Ke,{get title(){return e.title},get isHidden(){return n(je)},onVisibilityChanged:Ys,get titleLinkHref(){return n(ai)},onMouseEnter:()=>{O(ps,!0)},onMouseLeave:()=>{O(ps,!1)},get size(){return n($i)},get onTitleClicked(){return n(Yo)},get ref(){return n(Cs)},set ref(kr){O(Cs,kr,!0)}})};V(ht,Ke=>{n(lr)&&Ke(oo)})}var Vi=k(ht,2);{var no=Ke=>{let $i=f(()=>a()==="video"&&v());kc(Ke,{get isShifted(){return n($i)}})};V(Vi,Ke=>{X()&&Ke(no)})}var bi=k(Vi,2);{var Qi=Ke=>{var $i=GC(),Yo=T($i);Xd(Yo,{}),S($i),$(Ke,$i)};V(bi,Ke=>{Ae()&&Ke(Qi)})}var Xs=k(bi,2);{var hd=Ke=>{Ac(Ke,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return ze()},onClick:Kn,onContextMenu:fi,onDblClick:qr})};V(Xs,Ke=>{te()&&Ke(hd)})}var jc=k(Xs,2);{var Wp=Ke=>{rl(Ke,{get shifted(){return v()},get captions(){return de()},get position(){return ke()},get playerSize(){return U()}})};V(jc,Ke=>{ee().value!=="off"&&a()==="video"&&Ke(Wp)})}var Xc=k(jc,2);{var Kp=Ke=>{var $i=YC();$i.__contextmenu=fi,$i.__click=[qC,j,st,m,ft,We];var Yo=T($i);sl(Yo,{}),S($i),$(Ke,$i)};V(Xc,Ke=>{s()&&Ke(Kp)})}var Zc=k(Xc,2);{var qp=Ke=>{let $i=f(()=>a()==="thumb"||a()==="LiveWaitingStart"||a()==="LiveWaitingRecover"||a()==="LiveWaitingRecord"),Yo=f(()=>a()==="ads"),kr=f(()=>e.canRewindLive&&xe()!==0);Ec(Ke,{get bottomHidden(){return n($i)},get bottomNoSmooth(){return W()},get showControls(){return v()},get isAds(){return n(Yo)},get canRewindLive(){return n(kr)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return Bt()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return qt()},get nextButtonActive(){return q()},get prevButtonActive(){return Le()},get isOneVideoPlaylist(){return Ue()},customFullscreenSupported:ar,toggleFullscreen:Rt,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get playerControlsWrapperRef(){return n(wr)},set playerControlsWrapperRef(Lo){O(wr,Lo,!0)},get playerControlsRef(){return n(zi)},set playerControlsRef(Lo){O(zi,Lo,!0)}})};V(Zc,Ke=>{ve()&&Ke(qp)})}var Jc=k(Zc,2);{var Qp=Ke=>{var $i=jC(),Yo=T($i);let kr=f(()=>{var Lo;return(Lo=n(zi))==null?void 0:Lo.clientHeight});Oc(Yo,{get supportLink(){return e.supportLink},get playerControlsHeight(){return n(kr)},returnFocus:()=>{var Lo;return(Lo=Xt())==null?void 0:Lo.focus()},get ref(){return n(Sr)},set ref(Lo){O(Sr,Lo,!0)}}),S($i),$(Ke,$i)};V(Jc,Ke=>{!te()&&a()!=="ads"&&Ke(Qp)})}var eu=k(Jc,2);let Gp=f(()=>!n(Tr));ic(eu,{get isLive(){return Je()},get isHidden(){return n(Gp)},get isPlaying(){return Pe()},get position(){return ke()},get duration(){return xe()}});var Ca=k(eu,2);Ev(Ca,{get data(){return $n}});var tu=k(Ca,2);bm(tu,{get supportLink(){return e.supportLink},returnFocus:()=>{var Ke;return(Ke=Xt())==null?void 0:Ke.focus()},get visible(){return j()},get playerContainerRef(){return n(So)},get position(){return we()},get menuElementRef(){return n(qn)},set menuElementRef(Ke){O(qn,Ke,!0)}});var Zs=k(tu,2);{var _l=Ke=>{Dc(Ke,{onClose:Bn,onSelectAutoQuality:()=>{tr("auto"),Bn()}})};V(Zs,Ke=>{n(Ur)&&Ke(_l)})}var iu=k(Zs,2);{var ou=Ke=>{Ya(Ke,{})};V(iu,Ke=>{n(Hn)&&Ke(ou)})}var bl=k(iu,2);{var nu=Ke=>{Im(Ke,{})};V(bl,Ke=>{Ne()&&Ke(nu)})}var Yp=k(bl,2);{var ru=Ke=>{sc(Ke,{})};V(Yp,Ke=>{Pt()&&Ke(ru)})}$(io,Qn)}),$(he,Jt)},$$slots:{default:!0}}),he=>Xt(he),()=>Xt());var Es=k(to,2);it(Es,he=>O(Fo,he),()=>n(Fo)),S(Ci),it(Ci,he=>O(So,he),()=>n(So));var qi=k(Ci,2);{var Ai=he=>{var Ct=JC();$(he,Ct)};V(qi,he=>{kt()&&he(Ai)})}vt("mouseenter",Ci,Wo),vt("mouseleave",Ci,Eo),vt("click",Ci,Si,!0),vt("focusin",Ci,Io,!0),$(i,Ao),H(),o()}et(["mousemove","contextmenu","click"]);var $a=require("@vkontakte/videoplayer-core/es2015"),w$=require("@vkontakte/videoplayer-shared/es2015");var iT=L('<div></div> <div class="info s-h"><div class="triangles-wrapper s-h"><div></div> <div></div> <div></div></div> <p class="step-caption s-h"> </p></div>',1),oT=L("<div><!></div>"),nT={hash:"s-h",code:".double-click-area.s-h{height:100%;overflow:hidden;position:absolute;top:0;width:25%}.double-click-area.left.s-h{left:0}.double-click-area.right.s-h{right:0}.semicircle.s-h{background-color:rgba(0,0,0,.5);height:100%;position:absolute;top:0;width:100%}.semicircle.left.s-h{border-bottom-right-radius:50%;border-top-right-radius:50%;left:0}.semicircle.right.s-h{border-bottom-left-radius:50%;border-top-left-radius:50%;right:0}.info.s-h{align-items:center;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%)}.info.s-h,.triangles-wrapper.s-h{display:flex;justify-content:center}.triangles-wrapper.s-h{margin-bottom:10px;position:relative}.triangle.s-h{animation:s-h-blink .5s infinite;border-bottom:6px solid transparent;border-top:6px solid transparent;height:0;opacity:0;width:0}.triangle.left.s-h:nth-child(3),.triangle.right.s-h:first-child{animation-delay:0s}.triangle.left.s-h:nth-child(2),.triangle.right.s-h:nth-child(2){animation-delay:.1s}.triangle.left.s-h:first-child,.triangle.right.s-h:nth-child(3){animation-delay:.2s}@keyframes s-h-blink{0%{opacity:0}50%{opacity:1}to{opacity:0}}.triangle.left.s-h{border-right:8px solid var(--white)}.triangle.right.s-h{border-left:8px solid var(--white)}.triangle.s-h:not(:last-child){margin-right:5px}.step-caption.s-h{color:var(--white);font-size:12px;line-height:1;margin:0;text-align:center}"};function Ip(i,e){B(e,!0),Q(i,nT);let t=h(e,"seekStep",3,0),o=K(!1),r=0,a=0,l=K(li(t())),d=p=>{p.stopPropagation(),a+=1,O(l,t()*(a-1)),a===1?e.handleSingleFirstClick(p):(O(o,!0),e.handleSecondClick()),window.clearTimeout(r),r=window.setTimeout(()=>{a=0,O(o,!1)},300)};mn(()=>{window.clearTimeout(r)});var s=oT();s.__click=d;var u=T(s);{var m=p=>{var v=iT(),b=le(v),y=k(b,2),_=T(y),x=T(_),I=k(x,2),C=k(I,2);S(_);var R=k(_,2),A=T(R,!0);S(R),S(y),N(P=>{var E,W,F,U;oe(b,1,`semicircle ${(E=e.side)!=null?E:""}`,"s-h"),oe(x,1,`triangle ${(W=e.side)!=null?W:""}`,"s-h"),oe(I,1,`triangle ${(F=e.side)!=null?F:""}`,"s-h"),oe(C,1,`triangle ${(U=e.side)!=null?U:""}`,"s-h"),ge(A,P)},[()=>Y("doubletap_seek_step",{seconds:n(l).toFixed(0)})]),$(p,v)};V(u,p=>{n(o)&&p(m)})}S(s),N(()=>{var p;return oe(s,1,`double-click-area ${(p=e.side)!=null?p:""}`,"s-h")}),$(i,s),H()}et(["click"]);var rT=(i,e,t)=>{e(!1),t()},sT=L('<div class="overlay s-j"></div> <div class="next-video s-j"><div class="top s-j"><div class="caption s-j"> </div> <!></div> <div class="row s-j"><div class="column s-j"><div class="thumb s-j"><div></div> <!></div></div> <div class="column s-j"><div class="title s-j"> </div></div></div></div>',1),aT={hash:"s-j",code:".overlay.s-j{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-j{display:flex;flex-direction:column;left:50%;margin:0 auto;max-width:362px;min-width:320px;padding-bottom:12px;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:var(--end-screen-mobile-z-index)}.top.s-j{display:flex;justify-content:space-between}.caption.s-j{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-j{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-j{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-j{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-j,.thumb-overlay.s-j{height:100%;width:100%}.thumb-overlay.s-j{position:absolute}.thumb-overlay.withOpacity.s-j{background:var(--black);opacity:.3}.title.s-j{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function lg(i,e){B(e,!0),Q(i,aT);let[t,o]=He(),r=()=>w(d,"$autoplayNextEnabled$",t),a=()=>w(s,"$timerNextVideoRunning$",t),l=$e(),d=l.ui.autoplayNextEnabled$,s=l.ui.timerNextVideoRunning$,u=l.actions.internal.nextVideoClick,m=l.actions.internal.nextVideoAnnouncementShow,p=l.actions.internal.nextVideoAnnouncementClick,v=l.actions.internal.nextVideoAnnouncementAuto,b=l.actions.internal.nextVideoAnnouncementCancel,y=()=>{u(!1),v()},_=()=>{e.clickCloseIcon(),b()};Ot(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Oe(),I=le(x);{var C=R=>{var A=sT(),P=k(le(A),2),E=T(P),W=T(E),F=T(W,!0);S(W);var U=k(W,2);Hs(U,{onClick:_}),S(E);var X=k(E,2);X.__click=[rT,u,p];var se=T(X),j=T(se),ne=T(j);let Z;var Te=k(ne,2);{var fe=me=>{ac(me,{get isRunning(){return a()},onTimerEnded:y})};V(Te,me=>{r()&&me(fe)})}S(j),S(se);var te=k(se,2),_e=T(te),Ce=T(_e,!0);S(_e),S(te),S(X),S(P),N((me,ce)=>{ge(F,me),Qe(j,`background-image: url('${e.thumb}')`),Z=oe(ne,1,"thumb-overlay s-j",null,Z,ce),ge(Ce,e.title)},[()=>r()?Y("end_screen_next_video"):Y("end_screen_recommended_video"),()=>({withOpacity:r()})]),$(R,A)};V(I,R=>{e.isHide||R(C)})}$(i,x),H(),o()}et(["click"]);var _$=require("@vkontakte/videoplayer-core/es2015");var b$=({getFullscreenTarget:i,fullScreenChangeHandler:e})=>{let t=null,o;Ot(()=>{_$.clientChecker.device.isIOS&&(o=setTimeout(()=>{let a=i().querySelector("video");if(!a)return;let l=()=>e(!0),d=()=>e(!1);a.addEventListener("webkitbeginfullscreen",l),a.addEventListener("webkitendfullscreen",d),t=()=>{a.removeEventListener("webkitbeginfullscreen",l),a.removeEventListener("webkitendfullscreen",d)}},0))}),mn(()=>{t==null||t(),clearTimeout(o)})};var $$=require("@vkontakte/videoplayer-core/es2015");var Ep=class{constructor(e){this.video=e}getTracksArray(){return Array.from(this.video.getElementsByTagName("track"))}attach(e,t=!1){let o=document.createElement("track");o.setAttribute("src",e.url),o.setAttribute("id",e.id),e.label&&o.setAttribute("label",e.label),e.language&&o.setAttribute("srclang",e.language),t&&(o.track.mode="showing"),this.video.appendChild(o)}detachAll(){for(let e of this.getTracksArray())this.video.removeChild(e)}updateSrc(e){let t=this.getTracksArray().find(o=>o.id===e.id);t&&(t.src=e.url)}getCurrentShowingId(){var e,t;return(t=(e=this.getTracksArray().find(o=>o.track.mode==="showing"))==null?void 0:e.id)!=null?t:null}};var y$=require("@vkontakte/videoplayer-core/es2015"),x$=({store:i,getFullscreenTarget:e})=>{let{isFullscreen:t}=i.ui,{setSubtitle:o}=i.actions.internal,{currentSubtitle$:r,availableSubtitlesList$:a,currentFormat$:l,availableTextTracks$:d}=i.state,s=null,u=()=>e().querySelector("video"),m=()=>y$.clientChecker.device.isIOS&&be(l)===$$.VideoFormat.DASH_LIVE_CMAF,p=()=>{s==null||s(),s=null},v=b=>{if(p(),!m()||!b)return;let y=u();if(!y)return;let _=new Ep(y),x=be(d),I=be(a),C=be(r);for(let P of x)I.some(W=>W.value===P.id)&&_.attach(P,C.value===P.id);let R=d.subscribe(P=>{for(let E of P)_.updateSrc(E)}),A=()=>{let P=_.getCurrentShowingId();o(be(a).find(E=>E.value===P))};y.textTracks.addEventListener("change",A),s=()=>{R(),_.detachAll(),y.textTracks.removeEventListener("change",A)}};Ot(()=>t.subscribe(v)),mn(p)};var lT=(i,e,t,o)=>{if(i.stopPropagation(),e()){o();return}},dT=L("<!> <!>",1),cT=L("<div><!></div>"),uT=L('<div class="spherical-video-icon s-9"><!></div>'),pT=L("<div><!></div>"),fT=L('<div class="settings-mobile s-9"><!></div>'),mT=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),vT=L('<div class="player-wrapper s-9" role="region" tabindex="-1"><!> <!> <!> <div class="overlay-container"></div></div>'),gT={hash:"s-9",code:".player-wrapper.s-9{height:100%;position:absolute;width:100%}.player-wrapper.s-9 .player-media{background:var(--black);height:100%;left:0;position:absolute;top:0;transition:transform .2s ease-in-out;width:100%}.spherical-video-icon.s-9{display:inline-block;left:calc(50% - 38px);position:absolute;top:calc(50% - 23px)}.ads-container.s-9{background:var(--black);height:100%;left:0;position:absolute;top:0;width:100%;z-index:var(--ads-container-z-index)}.settings-mobile.s-9{align-items:center;display:flex;left:50%;max-width:320px;position:absolute;top:50%;transform:translate(-50%,-50%);transition:opacity var(--controls-transition-duration);width:90%;z-index:var(--settings-menu-z-index)}"};function dg(i,e){var xn,lr;B(e,!0),Q(i,gT);let[t,o]=He(),r=()=>w(Ue,"$playerPhase",t),a=()=>w(ci,"$isLoaderVisible",t),l=()=>w(Le,"$adPlaybackState",t),d=()=>w(Ht,"$crashed",t),s=()=>w(Br,"$notificationsToShow$",t),u=()=>w(q,"$playbackState$",t),m=()=>w(Ft,"$graphIsOpened$",t),p=()=>w(Be,"$interactiveHideMobileControls",t),v=()=>w(Li,"$isEnded$",t),b=()=>w(yi,"$isInteractiveExpectation$",t),y=()=>w(Tt,"$controlsVisible",t),_=()=>w(lt,"$touched",t),x=()=>w(Oi,"$autoplayNextEnabled$",t),I=()=>w(ui,"$postrollPassed",t),C=()=>w(Hr,"$bottomNoSmooth",t),R=()=>w(st,"$videoSize",t),A=()=>w(yt,"$playerSize",t),P=()=>w(Se,"$isFullscreen",t),E=()=>w(Me,"$position$",t),W=()=>w(ye,"$duration$",t),F=()=>w(Rn,"$loadedMetadata",t),U=()=>w(qe,"$settingsMenuVisible",t),X=()=>w(Xt,"$scrubbingInProgress",t),se=()=>w(Mt,"$volumeChangingInProgress",t),j=()=>w(bo,"$chromecastConnected$",t),ne=()=>w(ve,"$isControlsAvailable",t),Z=()=>w(ut,"$isInteractiveTime$",t),Te=()=>w(Ji,"$isActiveLive",t),fe=()=>w(ct,"$settingsMenuOpenedByKeyboard",t),te=()=>w(qt,"$language$",t),_e=()=>w(St,"$disabledControls$",t),Ce=()=>w(Ut,"$is3DVideo",t),me=()=>w(z,"$icon3DVideoVisible",t),ce=()=>w($o,"$chromecastDeviceName$",t),Ye=()=>w(Pi,"$currentSubtitle$",t),G=()=>w(rn,"$currentSubtitleCaptions$",t),D=()=>w(No,"$realDuration$",t),Xe=()=>w(at,"$isLive$",t),re=()=>w(pi,"$isPlaying$",t),pe=()=>w(di,"$debugPanelVisible",t),ue=h(e,"videoContainer",15),Ae=h(e,"adsSlotId",3,void 0),ze=h(e,"adsParams",3,void 0),ee=h(e,"adsAutoplayParam",3,void 0),de=h(e,"duration",3,void 0),ke=h(e,"logoTargetUrl",3,""),xe=h(e,"showNextPrevButtons",3,!1),Je=h(e,"nextButtonActive",3,!1),Pe=h(e,"prevButtonActive",3,!1),we=h(e,"endScreenVideoTitle",3,void 0),Ne=h(e,"endScreenVideoThumb",3,void 0),Pt=h(e,"isOneVideoPlaylist",3,!1),kt=h(e,"showMiniTimer",3,!1),Lt=h(e,"fullScreenTarget",3,void 0),pt=h(e,"playerStarted",3,!1),It=h(e,"showEndScreen",3,!0),{notifications$:ei,graphIsOpened$:Ft}=xo(),Bt=e.store.getLogger().createComponentLog("Root component"),qt=e.store.interfaceLanguage$,q=e.store.state.playbackState$,Le=e.store.ads.playbackState,Me=e.store.state.positionWithScrubbing$,ye=e.store.state.duration$,Ue=e.store.playerPhase,Se=e.store.ui.isFullscreen,Tt=e.store.ui.controlsVisible,ve=e.store.ui.isControlsAvailable,Be=e.store.ui.interactiveHideMobileControls,qe=e.store.ui.settingsMenu.visible$,ct=e.store.ui.settingsMenu.openedByBtnKeyboard$,Xt=e.store.ui.scrubbingInProgress,Mt=e.store.ui.volumeChangingInProgress,di=e.store.ui.debugPanelVisible,ci=e.store.state.isLoaderVisible,Li=e.store.state.isEnded$,bo=e.store.state.chromecastConnected$,$o=e.store.state.chromecastDeviceName$,ui=e.store.ads.postrollPassed,at=e.store.state.isLive$,pi=e.store.state.isPlaying$,Ji=e.store.state.isActiveLive$,ft=e.store.state.isRewindableLive$,Ht=e.store.state.crashed$,hi=e.store.webApi.annotationsApi,rt=e.store.webApi.pictureInPictureApi,st=e.store.state.videoSize$,Pi=e.store.state.currentSubtitle$,rn=e.store.state.currentSubtitleCaptions$,No=e.store.state.duration$,yt=e.store.ui.playerSize,Ut=e.store.ui.is3DVideo,z=e.store.ui.icon3DVideoVisible,Vt=e.store.state.isInteractive,ut=e.store.state.isInteractiveTime$,yi=e.store.state.isInteractiveExpectation$,ti=e.store.state.hasInteractiveBranches,St=e.store.ui.controls.disabledControls$,lt=e.store.ui.touched,Ui=e.store.ui.overlayContainer$,Oi=e.store.ui.autoplayNextEnabled$,Rn=e.store.state.loadedMetadata$,On=e.store.actions.internal.closeSettingsMenu,Ii=(xn=e.store.callbacks)==null?void 0:xn.onDisabledPlayPrevChapterClick,eo=(lr=e.store.callbacks)==null?void 0:lr.onDisabledSeekToInteractiveClick,Dn=e.store.actions.internal.setQuality,wo=K(void 0),wi=K(void 0),Bo=K(void 0),Ho=K(void 0),yo,hn,as=f(()=>(r()==="video"&&a()||r()==="ads"&&l()==="inactive")&&!d()),Nr=K(void 0),{closeNotification:ls,notificationsToShow$:Br}=ei,tr=f(()=>!!s().slow_video),ds=()=>ls("slow_video"),Hr=ae(!1),sn,_n=K(!1),$r=f(()=>u()!==$a.PlaybackState.PLAYING),yr=K(!1),bn=f(()=>m()||p()||!n(_n)&&(v()&&!!ti||n($r)&&b())),ir=K(!0),xr=f(()=>e.uiConfig.features.thumbTimer&&kt()&&r()==="video"&&!y()&&!d()&&!Vt&&(e.uiConfig.hideThumbTimerAfterTouch&&!_()||!e.uiConfig.hideThumbTimerAfterTouch)),or=K(!1),nr=f(()=>(It()||e.showAutoplayNext&&x())&&!!we()&&!!Ne()&&(e.showAds&&I()||!e.showAds)&&v()&&!d()&&!n(or)),cs=K(!1);rt==null||rt.setContext(wd());let So=je=>{je&&!Vt&&zi(e.uiConfig.controls.hideTimeoutMobile)};e.store.setUiCallbacks({onStarted:So});let wr=()=>{clearTimeout(yo),O(_n,!1),p()&&Be.set(!1)},zi=je=>{wr(),O(_n,!0),yo=setTimeout(()=>O(_n,!1),je);let _i=je-100;sn=setTimeout(()=>{C()&&Hr.set(!1)},_i>0?_i:je)},Sr=Ut.subscribe(je=>{z.set(je),je&&(clearTimeout(hn),hn=setTimeout(()=>z.set(!1),e.uiConfig.controls.hide360IconTimeout))}),Nn=(..._i)=>bt(null,[..._i],function*(je=ca()){var Uo,wn,Co,cn,po,To;if(je&&!$a.clientChecker.device.isIOS){let ki=Zd(),zr=Bn(),Un=$a.clientChecker.browser.isSamsungBrowser&&ki===e.shadowRootContainer;je=ki===zr||Un}if(je){zi(e.uiConfig.controls.hideTimeoutFullscreen);try{yield rt==null?void 0:rt.exit()}catch(ki){Bt({message:String(ki)})}try{let ki=(Uo=R())!=null&&Uo.width&&((wn=R())!=null&&wn.height)?R():A();yield ab(ki)}catch(ki){Bt({message:String(ki)})}}Se.set(je),e.store.getAdmanWrapper().setFullscreen(je),P()?(cn=(Co=e.store.callbacks)==null?void 0:Co.onFullscreenEnter)==null||cn.call(Co):(To=(po=e.store.callbacks)==null?void 0:po.onFullscreenExit)==null||To.call(po)}),_t=je=>{yt.set(je)},ii=()=>{if(n(wo)){let{width:je,height:_i}=n(wo).getBoundingClientRect();yt.set({width:je,height:_i})}};Ot(()=>{var je;return Xu(Nn),e.uiConfig.features.annotationsInside&&(hi==null||hi.init(n(wo))),rt==null||rt.assignPlayerContainer(n(wo)),e.uiConfig.disablePiPResizeHandling||rt==null||rt.setExternalEventHandlers({resize:_t,leavepictureinpicture:ii}),O(ir,!$a.clientChecker.device.isIphoneOrOldIpad),e.interactiveContainer&&((je=ue().parentElement)==null||je.insertBefore(e.interactiveContainer,ue().nextSibling)),()=>{clearTimeout(yo),clearTimeout(sn),clearTimeout(hn),Sr(),rt==null||rt.dispose().catch(_i=>{Bt({message:String(_i)})}),Zu(Nn)}});let Cr=K(!0),Fr=K(!0),Ur=je=>{let _i=E()+(je==="forward"?1:-1)*e.uiConfig.controls.seekStepMobile/1e3;_i<0?(O(Cr,!1),_i=0):_i>=W()&&(O(Fr,!1),_i=W()),O(yr,!0),e.seekTime(_i)},Bn=()=>$a.clientChecker.device.isIOS?n(wo):!e.uiConfig.allowChangingFullscreenTarget||!Lt()?e.outerContainerRef:Lt().contains(e.outerContainerRef)?Lt():e.outerContainerRef,Hn=()=>bt(null,null,function*(){try{if(ca())yield ju(document),Bt({message:"exit fullscreen"});else{if(Bt({message:"request fullscreen"}),$a.clientChecker.device.isIOS&&!F())return;yield Yu(Bn())}}catch(je){Bt({message:String(je)})}}),Fo=()=>{On()},Fn=je=>{if(je.preventDefault(),U()){Fo();return}if(!pt()){e.firstStart(),zi(e.uiConfig.controls.hideTimeoutCursor);return}O(yr,!1),y()?wr():zi(e.uiConfig.controls.hideTimeoutMobile)},rr=()=>{lt.set(!0)},an=()=>{Vt||(Hr.set(!0),zi(e.uiConfig.controls.hideTimeoutCursor))},$n=je=>{Ii&&(Ii(je),zi(e.uiConfig.controls.hideTimeoutMobile))},sr=je=>{eo&&(eo(je),zi(e.uiConfig.controls.hideTimeoutMobile))};Fe(()=>{Ui.set(n(Nr))}),Fe(()=>{Tt.set((n($r)||U()||X()||se()||j()||!n(nr)&&(v()||n(_n)&&!n(yr)))&&!n(bn)&&r()==="video"&&!d()&&ne())}),Fe(()=>{!X()&&n(cs)&&!Z()&&zi(e.uiConfig.controls.hideTimeoutMobile),O(cs,X(),!0)}),Fe(()=>{O(Cr,E()>0),O(Fr,!Te()&&E()<W(),!0)}),Fe(()=>{nc(n(Ho),U(),fe(),!0)});let yn=Y("aria_label_video_player");b$({fullScreenChangeHandler:Nn,getFullscreenTarget:Bn}),x$({store:e.store,getFullscreenTarget:Bn});let ln=(je,_i)=>{var cn,po;let Uo=(po=(cn=e.store.callbacks)==null?void 0:cn.uiInfo)==null?void 0:po.onUpcomingLiveViewStateChanged;if(!Uo)return;let wn=!!_i,Co=Ve(Ve({},Jn(n(wo),{upcomingLiveScreen:_i},"upcomingLiveScreen",wn)),je);Uo(Co)};var Di=vT();vt("blur",Ma,Fo);var uo=T(Di);ul(uo,{onClick:Fn,get videoContainer(){return ue()},set videoContainer(je){ue(je)}});var dn=k(uo,2);Ba(dn,()=>"slot",!1,(je,_i)=>{so(je,()=>({name:cl}))});var ar=k(dn,2);Rs(ar,te,je=>{var _i=mT(),Uo=le(_i);let wn=f(()=>r()!=="thumb"||d()||Vt&&e.autoplay||e.uiConfig.features.disableThumbUnstartedOnAutoplay&&e.autoplay);al(Uo,{get hidden(){return n(wn)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart}});var Co=k(Uo,2);{var cn=ot=>{var Zt=dT(),Si=le(Zt);{var ko=Qo=>{let dr=f(()=>e.uiConfig.controls.seekStepMobile/1e3);Ip(Qo,{side:"left",get seekStep(){return n(dr)},handleSingleFirstClick:Fn,handleSecondClick:()=>Ur("backward")})};V(Si,Qo=>{n(Cr)&&Qo(ko)})}var Cn=k(Si,2);{var qn=Qo=>{let dr=f(()=>e.uiConfig.controls.seekStepMobile/1e3);Ip(Qo,{side:"right",get seekStep(){return n(dr)},handleSingleFirstClick:Fn,handleSecondClick:()=>Ur("forward")})};V(Cn,Qo=>{n(Fr)&&Qo(qn)})}$(ot,Zt)};V(Co,ot=>{e.canRewindLive&&ft&&!_e().has("TIMELINE")&&ot(cn)})}var po=k(Co,2);{var To=ot=>{let Zt=f(()=>{var Si;return(Si=e.live)==null?void 0:Si.startTime});Lc(ot,{get thumbUrl(){return e.thumbUrl},get startTime(){return n(Zt)},onUpcomingLiveViewStateChanged:ln})};V(po,ot=>{r()==="LiveWaitingStart"&&ot(To)})}var ki=k(po,2);{var zr=ot=>{ll(ot,{kind:"recover",get thumbUrl(){return e.thumbUrl}})};V(ki,ot=>{r()==="LiveWaitingRecover"&&ot(zr)})}var Un=k(ki,2);{var ws=ot=>{ll(ot,{kind:"record",get thumbUrl(){return e.thumbUrl}})};V(Un,ot=>{r()==="LiveWaitingRecord"&&ot(ws)})}var Wi=k(Un,2);{var Ss=ot=>{var Zt=cT();let Si;var ko=T(Zt);Jd(ko,{get adsSlotId(){return Ae()},get adsParams(){return ze()},get adsAutoplayParam(){return ee()},get duration(){return de()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S(Zt),N(Cn=>Si=oe(Zt,1,"ads-container s-9",null,Si,Cn),[()=>({hidden:r()!=="ads"})]),$(ot,Zt)};V(Wi,ot=>{e.showAds&&pt()&&ot(Ss)})}var us=k(Wi,2);{var Ir=ot=>{let Zt=f(()=>!It()&&e.showAutoplayNext&&x());lg(ot,{get title(){return we()},get thumb(){return Ne()},get isHide(){return n(Zt)},clickCloseIcon:()=>O(or,!0)})};V(us,ot=>{n(nr)&&we()&&Ne()&&ot(Ir)})}var zo=k(us,2);{var Wr=ot=>{kc(ot,{})};V(zo,ot=>{Ce()&&ot(Wr)})}var un=k(zo,2);{var Mi=ot=>{var Zt=uT(),Si=T(Zt);Xd(Si,{}),S(Zt),$(ot,Zt)};V(un,ot=>{me()&&ot(Mi)})}var We=k(un,2);{var Rt=ot=>{Ac(ot,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return ce()},onClick:Fn})};V(We,ot=>{j()&&ot(Rt)})}var fi=k(We,2);{var Wo=ot=>{rl(ot,{get shifted(){return y()},get captions(){return G()},get position(){return E()},get playerSize(){return A()},isMobile:!0})};V(fi,ot=>{Ye().value!=="off"&&ot(Wo)})}var Io=k(fi,2);{var Eo=ot=>{var Zt=pT();Zt.__click=[lT,U,qe,Fo];var Si=T(Zt);sl(Si,{}),S(Zt),$(ot,Zt)};V(Io,ot=>{d()&&ot(Eo)})}var Ki=k(Io,2);{var Ko=ot=>{let Zt=f(()=>r()==="thumb"||r()==="LiveWaitingStart"||r()==="LiveWaitingRecover"||r()==="LiveWaitingRecord"||r()==="ads"),Si=f(()=>r()==="ads"),ko=f(()=>e.canRewindLive&&D()!==0);Ec(ot,{get bottomHidden(){return n(Zt)},get showControls(){return y()},get bottomNoSmooth(){return C()},get isAds(){return n(Si)},get canRewindLive(){return n(ko)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return ke()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return xe()},get nextButtonActive(){return Je()},get prevButtonActive(){return Pe()},get isOneVideoPlaylist(){return Pt()},get customFullscreenSupported(){return n(ir)},get endScreenShown(){return n(nr)},toggleFullscreen:Hn,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},onDisabledPlayPrevChapterClick:$n,onDisabledSeekToInteractiveClick:sr,get playerControlsWrapperRef(){return n(wi)},set playerControlsWrapperRef(Cn){O(wi,Cn,!0)},get playerControlsRef(){return n(Bo)},set playerControlsRef(Cn){O(Bo,Cn,!0)}})};V(Ki,ot=>{pt()&&ot(Ko)})}var zn=k(Ki,2);{var Er=ot=>{var Zt=fT(),Si=T(Zt);Oc(Si,{get supportLink(){return e.supportLink},get returnFocus(){return w$.noop},get ref(){return n(Ho)},set ref(ko){O(Ho,ko,!0)}}),S(Zt),$(ot,Zt)};V(zn,ot=>{U()&&ot(Er)})}var Po=k(zn,2);let fo=f(()=>!n(xr));ic(Po,{get isLive(){return Xe()},get isHidden(){return n(fo)},get isPlaying(){return re()},get position(){return E()},get duration(){return W()}});var Sn=k(Po,2);{var qo=ot=>{Ya(ot,{})};V(Sn,ot=>{n(as)&&ot(qo)})}var Wn=k(Sn,2);{var Kr=ot=>{sc(ot,{})};V(Wn,ot=>{pe()&&ot(Kr)})}var qr=k(Wn,2);{var Kn=ot=>{Dc(ot,{onClose:ds,onSelectAutoQuality:()=>{Dn("auto"),ds()}})};V(qr,ot=>{n(tr)&&ot(Kn)})}$(je,_i)});var Tr=k(ar,2);it(Tr,je=>O(Nr,je),()=>n(Nr)),S(Di),it(Di,je=>O(wo,je),()=>n(wo)),N(()=>De(Di,"aria-label",yn)),vt("click",Di,rr,!0),vt("focusin",Di,an,!0),$(i,Di),H(),o()}et(["click"]);function Pp(i){let e="";return co(i.timelineSliderFilledColor)&&(e+=`--timeline-slider-filled-bg:${i.timelineSliderFilledColor};`),co(i.timelineSliderHandleColor)&&(e+=`--timeline-slider-handle-bg:${i.timelineSliderHandleColor};`),co(i.timelineSliderLoadedColor)&&(e+=`--timeline-slider-loaded-bg:${i.timelineSliderLoadedColor};`),co(i.timelineSliderColor)&&(e+=`--timeline-slider-bg:${i.timelineSliderColor};`),co(i.volumeSliderColor)&&(e+=`--volume-slider-bg:${i.volumeSliderColor};`),co(i.volumeSliderHandleColor)&&(e+=`--volume-slider-handle-bg:${i.volumeSliderHandleColor};`),co(i.volumeSliderFilledColor)&&(e+=`--volume-slider-filled-bg:${i.volumeSliderFilledColor};`),co(i.controlsTimeColor)&&(e+=`--controls-time:${i.controlsTimeColor};`),co(i.timelineSliderFilledActiveLiveColor)&&(e+=`--timeline-slider-filled-active-live-bg:${i.timelineSliderFilledActiveLiveColor};`),co(i.timelineSliderHandleActiveLiveColor)&&(e+=`--timeline-slider-handle-active-live-bg:${i.timelineSliderHandleActiveLiveColor};`),co(i.buttonColor)&&(e+=`--btn-color:${i.buttonColor};`),co(i.buttonToggleOnColor)&&(e+=`--toggle-color-on:${i.buttonToggleOnColor};`,e+=`--toggle-color-autoplay-on:${i.buttonToggleOnColor};`),co(i.focusedColor)&&(e+=`--focused:${i.focusedColor};`),co(i.focusedOutlineWidth)&&(e+=`--focused-outline-width:${i.focusedOutlineWidth};`),co(i.focusedOutlineRadius)&&(e+=`--focused-outline-radius:${i.focusedOutlineRadius};`),co(i.controlsDesktopPaddingHorizontal)&&(e+=`--controls-desktop-padding-horizontal:${i.controlsDesktopPaddingHorizontal};`),co(i.timelinePaddingHorizontal)&&(e+=`--timeline-padding-horizontal:${i.timelinePaddingHorizontal};`),co(i.settingsBackgroundColor)&&(e+=`--settings-bg:${i.settingsBackgroundColor};`),co(i.font)&&(e+=`--font:${i.font};`),co(i.controlsGradientHeight)&&(e+=`--controls-gradient-height:${i.controlsGradientHeight};`),co(i.controlsGradient)&&(e+=`--controls-gradient:${i.controlsGradient};`),e.length&&e||void 0}function co(i){return typeof i=="string"&&!i.includes(";")}var S$=require("@vkontakte/videoplayer-shared/es2015");var hT=L('<div class="time-container s-7"><!></div>'),_T=L('<div class="player-wrapper s-7" role="region"><!> <!> <!> <!> <!> <div><!></div></div>'),bT={hash:"s-7",code:".player-wrapper.s-7{height:100%;position:absolute;width:100%}.player-wrapper.s-7 .player-media{background:var(--black);height:100%;left:0;position:absolute;top:0;transition:transform .2s ease-in-out;width:100%}.timeline.s-7{bottom:0;left:0;opacity:0;opacity:1;position:absolute;transition:opacity var(--controls-transition-duration) var(--controls-transition-fn);width:100%;z-index:var(--controls-container-z-index)}.visible.s-7{opacity:1}.time-container.s-7{bottom:8px;position:absolute;right:8px;z-index:var(--thumb-timer-z-index)}"};function cg(i,e){B(e,!0),Q(i,bT);let[t,o]=He(),r=()=>w(Z,"$scrubbingInProgress",t),a=()=>w(j,"$playerSize",t),l=()=>w(E,"$isPlaying$",t),d=()=>w(A,"$duration$",t),s=()=>w(U,"$positionWithScrubbing$",t),u=()=>w(C,"$playerPhase",t),m=()=>w(R,"$crashed$",t),p=()=>w(W,"$currentSubtitle$",t),v=()=>w(F,"$currentSubtitleCaptions$",t),b=()=>w(P,"$positionExact$",t),y=()=>w(X,"$isLive$",t),_=()=>w(se,"$isRewindableLive$",t),x=h(e,"outsideDuration",3,0),I=h(e,"videoContainer",15),{playerPhase:C,state:{crashed$:R,duration$:A,positionExact$:P,isPlaying$:E,currentSubtitle$:W,currentSubtitleCaptions$:F,positionWithScrubbing$:U,isLive$:X,isRewindableLive$:se},ui:{playerSize:j,controls:ne,scrubbingInProgress:Z},actions:{internal:{getVideoElement:Te}}}=$e(),fe=8,te=K(!1),_e=li({}),Ce=K(!1),me=f(()=>!r()&&!n(Ce)),ce=()=>{O(te,!0)},Ye=()=>{O(te,!1)},G=(0,S$.debounceFn)(od,260);Fe(()=>{a(),G(Te(),ne,_e,n(te))});let D=f(()=>l()?nn(d()-s()):nn(isFinite(d())?d():x()));var Xe=_T(),re=T(Xe);ul(re,{hideCursor:!1,get videoContainer(){return I()},set videoContainer(we){I(we)}});var pe=k(re,2);Ba(pe,()=>"slot",!1,(we,Ne)=>{so(we,()=>({name:cl}))});var ue=k(pe,2);let Ae=f(()=>u()!=="thumb"||m());al(ue,{get hidden(){return n(Ae)},get thumbUrl(){return e.thumbUrl},iconVisible:!1});var ze=k(ue,2);{var ee=we=>{rl(we,{shifted:!1,get captions(){return v()},get position(){return b()},get playerSize(){return a()}})};V(ze,we=>{p().value!=="off"&&n(me)&&we(ee)})}var de=k(ze,2);{var ke=we=>{var Ne=hT(),Pt=T(Ne);tc(Pt,{get isLive(){return y()},get isPlaying(){return l()},get time(){return n(D)}}),S(Ne),$(we,Ne)};V(de,we=>{n(me)&&we(ke)})}var xe=k(de,2);let Je;var Pe=T(xe);il(Pe,{get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return _()},isAds:!1,needPadding:!1,isHidden:!1,withEpisodes:!1,tooltipLeftOffset:fe,tooltipRightOffset:fe,get ref(){return _e.timeline},set ref(we){_e.timeline=we}}),S(xe),S(Xe),N(we=>Je=oe(xe,1,"timeline s-7",null,Je,we),[()=>({visible:n(te)})]),vt("mouseenter",Xe,ce),vt("mouseleave",Xe,Ye),vt("mouseenter",xe,()=>O(Ce,!0)),vt("mouseleave",xe,()=>O(Ce,!1)),$(i,Xe),H(),o()}var $T=L("<div><!></div>"),yT={hash:"s-0",code:'.vk-vp-root.s-0{--white:#fff;--black:#000;--red:#ff3347;--blue-light:#70c1ff;--black-alpha-40:rgba(0,0,0,.4);--white-alpha-24:hsla(0,0%,100%,.24);--white-alpha-72:hsla(0,0%,100%,.72);--devider-gray:#dce1e6;--text-gray:#626d7a;--font:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;--controls-height:40px;--controls-gradient-height:100px;--controls-transition-duration:0.25s;--controls-transition-fn:cubic-bezier(0.455,0.03,0.515,0.955);--controls-desktop-item-margin-left:4px;--controls-desktop-padding-horizontal:4px;--focused:var(--white);--focused-outline-width:2px;--focused-outline-radius:0;--focused-element-shadow:inset 0 0 0 var(--focused-outline-width) var(--focused);--focused-slider-shadow:0 0 0 2px var(--focused);--big-play-size:96px;--big-play-radius:50%;--big-play-bg-color:rgba(0,0,0,.5);--big-play-hover-bg-color:rgba(0,0,0,.6);--big-play-icon-width:38px;--big-play-icon-height:33px;--interactive-episode-complete:#5c9ce6;--slider-bg:hsla(0,0%,100%,.4);--slider-filled-bg:var(--white);--slider-handle-bg:var(--white);--slider-loaded-bg:hsla(0,0%,100%,.4);--slider-height:3px;--slider-video-episode-gap:1.5px;--slider-radius:0px;--slider-handle-size:12px;--slider-filled-ads:#67a5eb;--slider-disabled-color:hsla(0,0%,97%,.31);--slider-volume-height:5px;--slider-volume-radius:calc(var(--slider-volume-height)/2);--slider-volume-handle-size:13px;--timeline-slider-filled-active-live-bg:var(--red);--timeline-slider-handle-active-live-bg:var(--red);--timeline-slider-bg:var(--slider-bg);--timeline-slider-filled-bg:var(--slider-filled-bg);--timeline-slider-handle-bg:var(--slider-handle-bg);--timeline-slider-loaded-bg:var(--slider-loaded-bg);--volume-slider-bg:var(--slider-bg);--volume-slider-filled-bg:var(--slider-filled-bg);--volume-slider-handle-bg:var(--slider-handle-bg);--controls-time:var(--white);--controls-gradient:linear-gradient(180deg,transparent 0%,rgba(0,0,0,.005) 6.67%,rgba(0,0,0,.02) 13.33%,rgba(1,1,1,.04) 20%,rgba(1,1,1,.07) 26.67%,rgba(2,2,2,.11) 33.33%,rgba(3,3,3,.16) 40%,rgba(4,4,4,.22) 46.67%,rgba(6,6,6,.28) 53.33%,rgba(7,7,7,.33) 60%,rgba(8,8,8,.38) 66.67%,rgba(9,9,9,.42) 73.33%,rgba(9,9,9,.46) 80%,hsla(0,0%,4%,.48) 86.67%,hsla(0,0%,4%,.5));--timeline-preview-shadow:rgba(0,0,0,.08);--timeline-preview-bg:#222;--timeline-padding-horizontal:10px;--timeline-padding-vertical-top:3px;--timeline-padding-vertical-bottom:4px;--timeline-height:calc(var(--timeline-padding-vertical-bottom) + var(--timeline-padding-vertical-top) + var(--slider-height));--preview-track-frame-height-vertical:114px;--preview-track-frame-height-horizontal:65px;--preview-track-controls-top:16px;--preview-track-time-line-height:16px;--preview-track-bottom-offset:10px;--preview-track-height:calc(var(--preview-track-frame-height-vertical) + var(--preview-track-bottom-offset));--preview-track-controls-top-offset:calc(var(--timeline-height) + var(--preview-track-controls-top) + var(--preview-track-time-line-height));--settings-bg:rgba(0,0,0,.72);--settings-item-bg-hover:hsla(0,0%,100%,.08);--settings-radius:8px;--mobile-settings-bg:#2c2d2e;--divider-border:1px solid var(--white-alpha-24);--toggle-color-separator:#363738;--toggle-color-off:#656565;--toggle-color-on:#71aaeb;--toggle-color-autoplay-on:var(--white);--notification-bg:#2c2d2e;--notification-radius:8px;--button-hover-transition:opacity 0.2s;--video-container-z-index:0;--controls-container-z-index:1;--ads-container-z-index:1;--end-screen-mobile-z-index:1;--notification-z-index:1;--thumb-timer-z-index:2;--debug-panel-z-index:2;--modal-z-index:2;--settings-menu-z-index:2;--context-menu-z-index:3;--hot-key-helpers-container-z-index:3;--overlay-container-z-index:4;--rotate-transition-duration:0.25s;--btn-color:var(--white);--double-forward-bg:rgba(0,0,0,.6);background:var(--black);color:var(--white);font-family:var(--vk-vp-custom-font,var(--font));font-size:12px;height:100%;line-height:normal;outline:0;overflow:hidden;position:relative;user-select:none;width:100%}.vk-vp-root.visible-outside.s-0{overflow:visible}.vk-vp-root.s-0 *{-webkit-tap-highlight-color:transparent}.vk-vp-root.s-0 button{background:transparent;border:none;color:inherit;font:inherit;line-height:normal;margin:0;overflow:visible;padding:0;width:auto;-webkit-font-smoothing:inherit;-moz-osx-font-smoothing:inherit;-webkit-appearance:none;cursor:pointer}.vk-vp-root.s-0 p{margin:0}.vk-vp-root.s-0 svg:not(.interactive-root svg){pointer-events:none}.vk-vp-root.s-0 .interactive-root{font-family:var(--vk-vp-int-custom-font,inherit)}.vk-vp-root.s-0 :focus,.vk-vp-root.s-0 :focus-visible{outline:none}.vk-vp-root.s-0 :focus-visible{border-radius:var(--focused-outline-radius);box-shadow:var(--focused-element-shadow)}.vk-vp-root.s-0 .focus-hidden:focus-visible{box-shadow:none}.vk-vp-root.s-0 .hidden{opacity:0;visibility:hidden}.vk-vp-root.s-0 .out-of-flow{content-visibility:hidden!important}.vk-vp-root.s-0 .overlay-container{height:100%;left:0;pointer-events:none;position:fixed;top:0;width:100%;z-index:var(--overlay-container-z-index)}.vk-vp-root.s-0 .out-of-view{left:-1000vh!important;position:absolute!important}.vk-vp-root.s-0 .icon.icon-error-stub{align-items:center;display:flex;justify-content:center}'};function ug(i,e){B(e,!0),Q(i,yT);let[t,o]=He(),r=()=>w(pt,"$isLive$",t),a=()=>w(hi,"$availableSubtitlesList$",t),l=()=>w(rt,"$isPreviewTrackHorizontallyAligned$",t),d=h(e,"sources",7),s=h(e,"store",7),u=h(e,"microStoresRoot",7),m=h(e,"videoConfig",7),p=h(e,"uiConfig",7),v=h(e,"title",7),b=h(e,"thumbUrl",7),y=h(e,"interactiveContainer",7),_=h(e,"interactiveController",7),x=h(e,"subtitles",7),I=h(e,"subtitlesForcedLanguage",7),C=h(e,"live",7),R=h(e,"preload",7),A=h(e,"autoplay",7),P=h(e,"volume",7,void 0),E=h(e,"muted",7,void 0),W=h(e,"fromTime",7),F=h(e,"canRewindLive",7),U=h(e,"showAds",7),X=h(e,"adsSlotId",7,void 0),se=h(e,"adsParams",7,void 0),j=h(e,"adsAutoplayParam",7,void 0),ne=h(e,"duration",7,void 0),Z=h(e,"logoClickable",7),Te=h(e,"logoHidden",7),fe=h(e,"isMobile",7),te=h(e,"showNextPrevButtons",7,!1),_e=h(e,"nextButtonActive",7,!1),Ce=h(e,"prevButtonActive",7,!1),me=h(e,"endScreenVideoTitle",7,void 0),ce=h(e,"endScreenVideoThumb",7,void 0),Ye=h(e,"isOneVideoPlaylist",7,!1),G=h(e,"supportLink",7),D=h(e,"shadowRootContainer",7),Xe=h(e,"outerContainerRef",7),re=h(e,"fullScreenTarget",7,void 0),pe=h(e,"failoverHosts",7,void 0),ue=h(e,"showMiniTimer",7,!1),Ae=h(e,"saveRate",7),ze=h(e,"seekToInteractive",7,pl.noop),ee=h(e,"playPrevChapter",7,pl.noop),de=h(e,"volumeMultiplier",7),ke=h(e,"showAutoplayNext",7),xe=h(e,"showEndScreen",7,!0),Je=h(e,"keyboardControls",15,void 0),{subscribers:Pe,stores:we}=u();v_(p());let Ne=Dt(),Pt=p().logoLink,kt=s().ui.debugPanelVisible,Lt=s().ui.playerSize,pt=s().state.isLive$,ei=s().state.isInteractive&&ld.clientChecker.device.isAndroid,Ft=K(void 0),Bt=null,qt=K(!1);s().getAdmanWrapper().init({switchFromAdsToVideo:s().actions.internal.switchFromAdsToVideo,switchFromVideoToAds:s().actions.internal.switchFromVideoToAds,setMuted:s().actions.external.setMuted},s().ads,{vsid:s().vsid}),T_(s(),we),Fe(()=>{var z,Vt;s().ui.isMobile.set(fe()),(Vt=(z=m().callbacks)==null?void 0:z.onDomReady)==null||Vt.call(z)});let q=(z=!1)=>{O(qt,!0),z?s().actions.external.firstStart(U()):s().actions.internal.firstStart(U())},Le=()=>{if(Ne.features.qualityDetailsSubMenuEnabled){let z=Y_(s().videoId);if(z)switch(z.type){case"high_quality":s().actions.internal.setHighQualityEnabled(!0,z.appliesTo);break;case"traffic_saving":s().actions.internal.setTrafficSavingEnabled(!0,z.appliesTo);break;case"exact_quality":s().actions.internal.setQuality(z.quality);break}}else{j_(s().videoId),im()&&s().actions.internal.setTrafficSavingEnabled(!0);let Vt=Jf(s().videoId);Vt&&s().actions.internal.setQuality(Vt)}};function Me(z){var St,lt,Ui;let Vt=d()||z;Vt&&s().initVideo({container:n(Ft),sources:Vt,failoverHosts:pe(),subtitles:x(),subtitlesForcedLanguage:I(),volumeMultiplier:de()});let ut=pl.safeStorage.get(Kd)==="true";kt.set(ut),W()>0&&s().actions.external.seekTime(W());let yi=fe()?Ne.volumeDefault:(lt=(St=P())!=null?St:Hu())!=null?lt:Ne.volumeDefault,ti=(Ui=E())!=null?Ui:z_();if(s().actions.external.setVolume(yi),s().actions.external.setMuted(ti),s().getAdmanWrapper().setInitialVolume(ti?0:yi),Le(),Ne.features.saveRate&&Ae()){let Oi=q_();Oi&&!r()&&s().actions.internal.setPlaybackRate(Oi)}if(ke()){let Oi=G_();Oi&&s().actions.internal.setAutoplayNextEnabled(Oi)}s().ui.isAutoplay.set(A()),A()&&q(),R()&&Ne.features.preload&&s().actions.internal.preload()}let ye=z=>{if(window.ResizeObserver){let Vt,ut;Bt=new ResizeObserver((0,pl.throttleFn)(yi=>{let ti=yi[0];if(ti.contentBoxSize){let St=Array.isArray(ti.contentBoxSize)?ti.contentBoxSize[0]:ti.contentBoxSize;Vt=St.inlineSize,ut=St.blockSize}else ti.contentRect&&(Vt=ti.contentRect.width,ut=ti.contentRect.height);Lt.set({width:Vt,height:ut})},300)),Bt.observe(z)}z.clientWidth&&z.clientHeight&&Lt.set({width:z.clientWidth,height:z.clientHeight})},Ue=()=>{document.hidden&&s().actions.external.stop()};Ot(()=>{var ut,yi,ti,St;ei&&document.addEventListener("visibilitychange",Ue),Ne.debugLog&&s().actions.internal.startLogging(),ye(n(Ft));let z=Pe.map(lt=>lt.init({store:s(),microStores:we,config:m(),interactiveController:_(),uiConfig:p()})),Vt=()=>{ei&&document.removeEventListener("visibilitychange",Ue),Bt==null||Bt.disconnect(),z.forEach(lt=>lt.unsubscribe()),s().destroy()};return((ut=C())==null?void 0:ut.status)==="upcoming"?(s().actions.internal.setLiveWaitingStart(!0),Vt):((yi=C())==null?void 0:yi.status)==="waiting"?(s().actions.internal.setLiveWaitingRecover(!0),Vt):(((ti=C())==null?void 0:ti.status)==="finished"||((St=C())==null?void 0:St.status)==="postlive")&&!(d()&&(0,ld.areValidLiveRecordSources)(d()))?(s().actions.internal.setLiveWaitingRecord(!0),Vt):(Me(),Vt)});function Se(){n(qt)?s().actions.external.play():q(!0)}function Tt(){s().actions.external.pause()}function ve(z){s().actions.external.setMuted(z)}function Be(){s().actions.external.toggleSubtitle()}function qe(z,Vt){s().actions.external.changeSubtitle(z,Vt)}function ct(z){s().actions.external.changeAudioStream(z)}function Xt(){var z;(z=s().webApi.slotsApi)!=null&&z.haveSlots()&&s().actions.external.hideControls()}function Mt(){var z;(z=s().webApi.slotsApi)!=null&&z.haveSlots()&&s().actions.external.showControls()}function di(z){fe()||z>=0&&z<=1&&s().actions.external.setVolume(z)}function ci(z){s().actions.internal.seekTime(z,C$.SeekAction.UNKNOWN)}function Li(z){s().actions.external.seekEpisodeStartTime(z)}function bo(){s().actions.external.returnFocusToEpisodes()}function $o(z){s().actions.external.setPlaybackRate(z)}function ui(z){s().actions.external.setAutoQualityLimits(z)}function at(){s().actions.external.setQuality("auto")}function pi(z){s().actions.external.setTrafficSavingEnabled(z)}function Ji(z){s().actions.external.setHighQualityEnabled(z)}let ft=Pp(Ne.view),Ht=m().playerView==="preview",hi=s().state.availableSubtitlesList$;if(Ne.features.initSubtitles){let z=!1;Fe(()=>{var Vt;if(!z&&a().length){z=!0;let ut;if(Ne.features.userVideoPrefs&&s().videoId){let ti=Wu(Ne.userSalt,String(s().videoId));ti!=null&&ti.subtitleTrackId&&(ut=a().find(St=>St.value===ti.subtitleTrackId))}let yi=(Vt=I())!=null?Vt:nm();yi&&(ut=a().find(ti=>ti.language===yi)),s().actions.internal.setSubtitle(ut)}})}let rt=s().ui.isPreviewTrackHorizontallyAligned;var st=$T();let Pi;var rn=T(st);{var No=z=>{dg(z,{get store(){return s()},get uiConfig(){return Ne},get thumbUrl(){return b()},get interactiveContainer(){return y()},get live(){return C()},get autoplay(){return A()},get canRewindLive(){return F()},get showAds(){return U()},get adsSlotId(){return X()},get adsParams(){return se()},get adsAutoplayParam(){return j()},get duration(){return ne()},get logoClickable(){return Z()},get logoHidden(){return Te()},get logoTargetUrl(){return Pt},get nextButtonActive(){return _e()},get prevButtonActive(){return Ce()},get endScreenVideoTitle(){return me()},get endScreenVideoThumb(){return ce()},get isOneVideoPlaylist(){return Ye()},get supportLink(){return G()},get shadowRootContainer(){return D()},get outerContainerRef(){return Xe()},get fullScreenTarget(){return re()},get showMiniTimer(){return ue()},get playerStarted(){return n(qt)},get seekToInteractive(){return ze()},get playPrevChapter(){return ee()},firstStart:q,seekTime:ci,get showEndScreen(){return xe()},get showAutoplayNext(){return ke()},get showNextPrevButtons(){return te()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson},get videoContainer(){return n(Ft)},set videoContainer(Vt){O(Ft,Vt,!0)}})},yt=z=>{var Vt=Oe(),ut=le(Vt);{var yi=St=>{cg(St,{get thumbUrl(){return b()},get outsideDuration(){return ne()},get canRewindLive(){return F()},get videoContainer(){return n(Ft)},set videoContainer(lt){O(Ft,lt,!0)}})},ti=St=>{ag(St,{get store(){return s()},get uiConfig(){return Ne},get title(){return v()},get thumbUrl(){return b()},get interactiveContainer(){return y()},get live(){return C()},get autoplay(){return A()},get canRewindLive(){return F()},get showAds(){return U()},get adsSlotId(){return X()},get adsParams(){return se()},get adsAutoplayParam(){return j()},get duration(){return ne()},get logoClickable(){return Z()},get logoHidden(){return Te()},get logoTargetUrl(){return Pt},get nextButtonActive(){return _e()},get prevButtonActive(){return Ce()},get endScreenVideoTitle(){return me()},get endScreenVideoThumb(){return ce()},get isOneVideoPlaylist(){return Ye()},get supportLink(){return G()},get shadowRootContainer(){return D()},get outerContainerRef(){return Xe()},get fullScreenTarget(){return re()},get showMiniTimer(){return ue()},get playerStarted(){return n(qt)},get seekToInteractive(){return ze()},get playPrevChapter(){return ee()},firstStart:q,get showEndScreen(){return xe()},get showAutoplayNext(){return ke()},get showNextPrevButtons(){return te()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson},get getVideoDeeplink(){return e.getVideoDeeplink},get videoContainer(){return n(Ft)},set videoContainer(lt){O(Ft,lt,!0)},get keyboardControls(){return Je()},set keyboardControls(lt){Je(lt)}})};V(ut,St=>{Ht?St(yi):St(ti,!1)})}$(z,Vt)};V(rn,z=>{fe()?z(No):z(yt,!1)})}S(st),N(z=>{Pi=oe(st,1,"vk-vp-root s-0",null,Pi,z),Qe(st,ft)},[()=>({"root--miui-browser":ld.clientChecker.device.isMobile&&ld.clientChecker.browser.isMiuiBrowser,"visible-outside":Ht,"preview-track-horizontally-alinged":l()})]),$(i,st);var Ut=H({initVideo:Me,play:Se,pause:Tt,setMuted:ve,toggleSubtitle:Be,changeSubtitle:qe,changeAudioStream:ct,hideControls:Xt,showControls:Mt,setVolume:di,seekTime:ci,seekEpisodeStartTime:Li,returnFocusToEpisodes:bo,setPlaybackRate:$o,setAutoQualityLimits:ui,setAutoQuality:at,toggleTrafficSaving:pi,toggleHighQuality:Ji,get sources(){return d()},set sources(z){d(z)},get store(){return s()},set store(z){s(z)},get microStoresRoot(){return u()},set microStoresRoot(z){u(z)},get videoConfig(){return m()},set videoConfig(z){m(z)},get uiConfig(){return p()},set uiConfig(z){p(z)},get title(){return v()},set title(z){v(z)},get thumbUrl(){return b()},set thumbUrl(z){b(z)},get interactiveContainer(){return y()},set interactiveContainer(z){y(z)},get interactiveController(){return _()},set interactiveController(z){_(z)},get subtitles(){return x()},set subtitles(z){x(z)},get subtitlesForcedLanguage(){return I()},set subtitlesForcedLanguage(z){I(z)},get live(){return C()},set live(z){C(z)},get preload(){return R()},set preload(z){R(z)},get autoplay(){return A()},set autoplay(z){A(z)},get volume(){return P()},set volume(z){P(z)},get muted(){return E()},set muted(z){E(z)},get fromTime(){return W()},set fromTime(z){W(z)},get canRewindLive(){return F()},set canRewindLive(z){F(z)},get showAds(){return U()},set showAds(z){U(z)},get adsSlotId(){return X()},set adsSlotId(z){X(z)},get adsParams(){return se()},set adsParams(z){se(z)},get adsAutoplayParam(){return j()},set adsAutoplayParam(z){j(z)},get duration(){return ne()},set duration(z){ne(z)},get logoClickable(){return Z()},set logoClickable(z){Z(z)},get logoHidden(){return Te()},set logoHidden(z){Te(z)},get isMobile(){return fe()},set isMobile(z){fe(z)},get showNextPrevButtons(){return te()},set showNextPrevButtons(z){te(z)},get nextButtonActive(){return _e()},set nextButtonActive(z){_e(z)},get prevButtonActive(){return Ce()},set prevButtonActive(z){Ce(z)},get endScreenVideoTitle(){return me()},set endScreenVideoTitle(z){me(z)},get endScreenVideoThumb(){return ce()},set endScreenVideoThumb(z){ce(z)},get isOneVideoPlaylist(){return Ye()},set isOneVideoPlaylist(z){Ye(z)},get supportLink(){return G()},set supportLink(z){G(z)},get shadowRootContainer(){return D()},set shadowRootContainer(z){D(z)},get outerContainerRef(){return Xe()},set outerContainerRef(z){Xe(z)},get fullScreenTarget(){return re()},set fullScreenTarget(z){re(z)},get failoverHosts(){return pe()},set failoverHosts(z){pe(z)},get showMiniTimer(){return ue()},set showMiniTimer(z){ue(z)},get saveRate(){return Ae()},set saveRate(z){Ae(z)},get showAutoplayNext(){return ke()},set showAutoplayNext(z){ke(z)},get seekToInteractive(){return ze()},set seekToInteractive(z){ze(z)},get playPrevChapter(){return ee()},set playPrevChapter(z){ee(z)},get volumeMultiplier(){return de()},set volumeMultiplier(z){de(z)},get showEndScreen(){return xe()},set showEndScreen(z){xe(z)},get keyboardControls(){return Je()},set keyboardControls(z){Je(z)}});return o(),Ut}var xT=Ee('<defs><path id="rect" d="m2.72 0c.45 0 .6.05.77.13a1 1 0 01.38.38c.09.16.13.33.13.77v1.44c0 .44-.04.6-.13.77a1 1 0 01-.38.38c-.16.08-.32.13-.77.13h-1.44c-.44 0-.6-.05-.77-.13a1 1 0 01-.37-.38c-.1-.16-.14-.33-.14-.77v-1.44c0-.44.05-.6.13-.77a1 1 0 01.38-.38c.17-.08.33-.13.77-.13z"></path></defs><path d="M38.24 6c3.57 0 4.86.37 6.17 1.07a7.3 7.3 0 0 1 3.02 3.02c.7 1.3 1.07 2.6 1.07 6.17v23.49c0 3.56-.37 4.85-1.07 6.16a7.3 7.3 0 0 1-3.02 3.02c-1.3.7-2.6 1.07-6.16 1.07h-19.5c-3.56 0-4.85-.37-6.16-1.07a7.3 7.3 0 0 1-3.02-3.02c-.7-1.3-1.07-2.6-1.07-6.16v-23.5c0-3.56.37-4.85 1.07-6.16a7.3 7.3 0 0 1 3.02-3.02C13.9 6.37 15.2 6 18.76 6zm.32 3h-19.8c-2.8 0-3.77.19-4.75.71a4.3 4.3 0 0 0-1.8 1.8c-.5.95-.7 1.87-.7 4.43l-.01 23.8c0 2.8.19 3.76.71 4.75a4.3 4.3 0 0 0 1.8 1.8c.98.52 1.95.71 4.75.71h19.49c2.8 0 3.76-.19 4.74-.71a4.3 4.3 0 0 0 1.8-1.8c.52-.98.71-1.95.71-4.74v-23.5c0-2.8-.19-3.75-.71-4.74a4.3 4.3 0 0 0-1.8-1.8c-.95-.5-1.87-.7-4.43-.7z"></path><use xlink:href="#rect" x="16.5" y="14"></use><use xlink:href="#rect" x="16.5" y="22"></use><use xlink:href="#rect" x="16.5" y="30"></use><use xlink:href="#rect" x="16.5" y="38"></use><use xlink:href="#rect" x="37" y="14"></use><use xlink:href="#rect" x="37" y="22"></use><use xlink:href="#rect" x="37" y="30"></use><use xlink:href="#rect" x="37" y="38"></use>',1);function pg(i,e){let t=h(e,"isWhite",3,!1),o=f(()=>t()?"#fff":"#909499");Ze(i,{width:"57",height:"60",get fill(){return n(o)},testId:"stub-icon",children:(r,a)=>{var l=xT();ni(9),$(r,l)},$$slots:{default:!0}})}var wT=L('<div class="title s-1"> </div>'),ST=L('<div class="playerStub s-1"><!> <!></div>'),CT={hash:"s-1",code:".playerStub.s-1{align-items:center;background-color:#222;background-position:50%;background-size:cover;display:flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;height:100%;justify-content:center;position:relative;width:100%}.title.s-1{box-sizing:border-box;color:#fff;font-size:15px;left:0;overflow:hidden;padding:18px 20px 10px;position:absolute;text-overflow:ellipsis;top:0;white-space:nowrap;width:100%}"};function fg(i,e){Q(i,CT);var t=ST(),o=T(t);{var r=d=>{var s=wT(),u=T(s,!0);S(s),N(()=>ge(u,e.title)),$(d,s)};V(o,d=>{e.title&&d(r)})}var a=k(o,2);{var l=d=>{let s=f(()=>!!e.thumbUrl);pg(d,{get isWhite(){return n(s)}})};V(a,d=>{(!e.title||!e.thumbUrl)&&d(l)})}S(t),N(()=>Qe(t,e.thumbUrl?`background-image: url('${e.thumbUrl}')`:"")),$(i,t)}var TT=L('<div class="playerError s-2"><!></div>'),IT={hash:"s-2",code:".playerError.s-2{align-items:center;background-color:#222;background-position:50%;background-size:cover;display:flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;height:100%;justify-content:center;position:relative;width:100%}"};function mg(i){Q(i,IT);var e=TT(),t=T(e);sl(t,{}),S(e),$(i,e)}var Up=require("@vkontakte/videoplayer-shared/es2015"),Fi=require("@vkontakte/videoplayer-shared/es2015"),Yc=require("@vkontakte/videoplayer-core/es2015"),fd=require("@vkontakte/videoplayer-statistics/es2015");var Ap=require("@vkontakte/videoplayer-shared/es2015"),kp=class{constructor(){this.subscription=new Ap.Subscription,this.logger=new Ap.Logger,this.log=this.logger.createComponentLog("MediaSessionApi")}isSupported(){return"mediaSession"in navigator}setMetaData({title:e,artist:t="",thumbUrl:o=""}){this.isSupported()&&(navigator.mediaSession.metadata=new MediaMetadata({title:e,artist:t,artwork:[{src:o,sizes:"96x96",type:"image/png"},{src:o,sizes:"128x128",type:"image/png"},{src:o,sizes:"192x192",type:"image/png"},{src:o,sizes:"256x256",type:"image/png"},{src:o,sizes:"384x384",type:"image/png"},{src:o,sizes:"512x512",type:"image/png"}]}))}updateActionHandlers(e){this.resetActionHandlers(),this.setActionHandlers(e)}resetActionHandlers(){let e=[["play",null],["pause",null],["stop",null],["nexttrack",null],["previoustrack",null],["seekto",null],["seekbackward",null],["seekforward",null]];this.setActionHandlers(e)}setActionHandlers(e){var t,o;if(this.isSupported())for(let[r,a]of e)try{(o=(t=navigator.mediaSession).setActionHandler)==null||o.call(t,r,a)}catch(l){throw new Error(`The media session action "${r}" is not supported yet.`)}}attachToStore(e){!this.isSupported()||!e||(this.clearSubscriptions(),this.subscription.add(e.state.positionExact$.subscribe(t=>{var a,l;let o=be(e.state.currentPlaybackRate$),r=be(e.state.duration$);if(!(!isFinite(t)||!isFinite(r)))try{(l=(a=navigator.mediaSession).setPositionState)==null||l.call(a,{position:t,playbackRate:o,duration:r})}catch(d){this.log({message:`MediaSession setPositionState can't call with position: ${t} and duration: ${r}`})}})))}clearSubscriptions(){this.subscription.unsubscribe()}destroy(){this.resetActionHandlers(),this.clearSubscriptions()}};var dd=require("@vkontakte/videoplayer-shared/es2015");var ET=Ee('<path d="M31.257 3.998c3.037.01 4.52.39 6.13 1.24a9 9 0 013.47 3.35l.17.31.15.3c.78 1.55 1.07 3.18 1.09 6.25v9.04a1.5 1.5 0 01-3 .02v-9.65c-.05-2.04-.24-3.12-.64-4.04l-.12-.27-.13-.25A6 6 0 0036.2 7.9c-1.19-.64-2.34-.88-5.11-.9h-8.84c-2.73 0-4 .2-5.07.7l-.25.13a6 6 0 00-2.4 2.41c-.64 1.19-.88 2.34-.9 5.11v20.83c0 2.74.2 4 .7 5.08l.13.25a6 6 0 002.41 2.4c1.1.6 2.13.83 4.44.89H26a1.5 1.5 0 010 3h-4.47c-3-.05-4.53-.38-6.14-1.24a9 9 0 01-3.48-3.35l-.15-.3c-.73-1.47-1.04-3.01-1.08-5.8V15c.05-2.98.39-4.52 1.25-6.12a9 9 0 013.293-3.582c1.85-.871 2.623-1.27 5.747-1.27z"></path><path d="M30.5 33.8c0-1.68 0-2.52.33-3.16a3 3 0 0 1 1.3-1.31c.65-.33 1.49-.33 3.17-.33h6.4c1.68 0 2.52 0 3.16.33a3 3 0 0 1 1.31 1.3c.33.65.33 1.49.33 3.17v13.4c0 1.68 0 2.52-.33 3.16a3 3 0 0 1-1.3 1.31c-.65.33-1.49.33-3.17.33h-6.4c-1.68 0-2.52 0-3.16-.33a3 3 0 0 1-1.31-1.3c-.33-.65-.33-1.49-.33-3.17z"></path>',1),PT=L('<div><div><!></div> <span class="title s-6"> </span></div>'),kT={hash:"s-6",code:".player-pip-dummy.s-6{align-items:center;background-color:#19191a;display:flex;flex-direction:column;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;height:100%;justify-content:center;width:100%}.player-pip-dummy.is-pip-api.s-6{position:relative}.dummy-image.s-6 svg{transform:scale(1.07143)}.dummy-image.desktop.s-6{transform:scale(1.07143) rotate(-90deg) rotateY(180deg)}.title.s-6{color:#fff;font-size:16px;padding:18px 20px 10px;text-align:center}"};function vg(i,e){B(e,!0),Q(i,kT);let[t,o]=He(),r=()=>w(u,"$interfaceLanguage$",t),a=()=>w(m,"$isMobile$",t),l=$e(),d=Dt(),s=!!l.webApi.pictureInPictureApi,u=l.interfaceLanguage$,m=l.ui.isMobile,p=l.ui.t,v=f(()=>r()&&p("pip_dummy_title")),b=Pp(d.view);var y=PT();let _;var x=T(y);let I;var C=T(x);Ze(C,{width:"57",height:"56",testId:"pip-dummy-icon",children:(P,E)=>{var W=ET();ni(),$(P,W)},$$slots:{default:!0}}),S(x);var R=k(x,2),A=T(R,!0);S(R),S(y),N((P,E)=>{_=oe(y,1,"player-pip-dummy s-6",null,_,P),Qe(y,b),I=oe(x,1,"dummy-image s-6",null,I,E),ge(A,n(v))},[()=>({"is-pip-api":s}),()=>({desktop:!a()})]),$(i,y),H(),o()}var AT=Object.defineProperty,LT=(i,e,t)=>e in i?AT(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,ya=(i,e,t)=>LT(i,typeof e!="symbol"?e+"":e,t),gg=(i,e,t)=>new Promise((o,r)=>{var a=s=>{try{d(t.next(s))}catch(u){r(u)}},l=s=>{try{d(t.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((t=t.apply(i,e)).next())}),MT=460,VT=280,Hc=class{constructor({enabled:e=!0}={enabled:!0}){ya(this,"playerDomElement"),ya(this,"playerParentShadowRoot"),ya(this,"playerDummyElement"),ya(this,"svelteContext"),ya(this,"pipWindow"),ya(this,"info",{isActive$:new dd.ValueSubject(!1),isEnabled$:new dd.ValueSubject(!1),type:1}),ya(this,"pipActive",!1),ya(this,"pipApi"),this.info.isEnabled$=new dd.ValueSubject(e),mp()&&(this.pipApi=new Us({enabled:e}),this.pipApi.info.isActive$.subscribe(t=>{(t&&!this.info.isActive$.getValue()||!t&&this.pipActive)&&this.info.isActive$.next(t),this.pipActive=t}))}isSupported(){let{isEmbed:e}=(0,dd.detectEmbed)();return"documentPictureInPicture"in window&&!e}isActive(){return this.info.isActive$.getValue()}setPlayerDomElement(e,t){this.playerDomElement=e,this.playerParentShadowRoot=t}setContext(e){this.svelteContext=e}request(){return gg(this,null,function*(){var e,t;if(!this.isSupported()||!this.playerDomElement||!this.playerParentShadowRoot)return;this.pipWindow=yield documentPictureInPicture.requestWindow({width:MT,height:VT,copyStyleSheets:!0}),this.pipWindow.document.body.style.margin="0";let o=[...this.playerParentShadowRoot.styleSheets].map(s=>[...s.cssRules].map(u=>u.cssText).join(" ")).filter(Boolean).join(`
|
|
63
|
+
`),r=document.createElement("style");r.textContent=o;let a=this.createStretchedContainer(),l=a.attachShadow({mode:"open"});l.append(r),l.append(this.playerDomElement);let d={target:this.playerParentShadowRoot,context:this.svelteContext};this.playerDummyElement=es(vg,d),(e=this.pipWindow)==null||e.document.body.append(a),this.info.isActive$.next(!0),(t=this.pipWindow)==null||t.addEventListener("unload",s=>{!this.playerDomElement||!this.playerParentShadowRoot||!this.playerDummyElement||(Na(this.playerDummyElement),this.playerParentShadowRoot.append(this.playerDomElement),this.info.isActive$.next(!1),this.pipWindow=void 0)})})}exit(){return gg(this,null,function*(){return new Promise(e=>{var t,o,r;this.pipWindow?(t=documentPictureInPicture.window)==null||t.close():(o=this.pipApi)!=null&&o.isActive()&&((r=this.pipApi)==null||r.exit()),e()})})}dispose(){return gg(this,null,function*(){yield this.exit()})}setEnabled(e){var t;this.info.isEnabled$.next(e),(t=this.pipApi)==null||t.setEnabled(e)}assignPlayerContainer(e){var t;(t=this.pipApi)==null||t.assignPlayerContainer(e)}updateVideoElement(){var e;(e=this.pipApi)==null||e.updateVideoElement()}setExternalEventHandlers(e){var t;(t=this.pipApi)==null||t.setExternalEventHandlers(e)}createStretchedContainer(){let e=document.createElement("div");return e.style.position="absolute",e.style.top="0",e.style.left="0",e.style.width="100%",e.style.height="100%",e}};function T$(i){return i instanceof Hc}var Lp=class{static getLatestSupportedVersion(e){let t=new Us(e),o=new Hc(e);if(o.isSupported())return o;if(t.isSupported())return t}};function Fc(i,e){var r,a;let t=new Set([...Object.keys(i),...Object.keys(e)]),o={};for(let l of t)o[l]=(a=(r=e[l])!=null?r:i[l])!=null?a:void 0;return o}var I$="Inner error. Unexpectedly root annotation container null reference exception",E$="Annotation with such name already exists",P$="Annotation with such name does not exist";var cd=class extends Error{constructor(e){super(e),this.name="AnnotationError"}};var ud=require("@vkontakte/videoplayer-shared/es2015"),RT="1",OT=100,Mp=class{constructor(e){this.annotationsInside=e;this.annotations=new Map;this.subscriptions=new ud.Subscription}init(e){if(this.rootAnnotationsContainer=e,this.annotationsInside)return;let t=(0,ud.throttleFn)(()=>{for(let o of this.annotations.values())this.isElementExceedsBoundaries(o,this.playerSize.width,this.playerSize.height)?o.style.visibility="hidden":o.style.visibility="visible"},OT);this.subscriptions.add((0,ud.observeElementSize)(this.rootAnnotationsContainer).subscribe(({width:o,height:r})=>{this.playerSize={width:o,height:r},t()})),this.mutationObserver=new MutationObserver(t),this.mutationObserver.observe(this.rootAnnotationsContainer,{attributes:!0,childList:!0,subtree:!0,characterData:!0})}add(e,t){var o;if(!this.rootAnnotationsContainer)throw new cd(I$);if(this.annotations.has(e))throw new cd(E$);t.style.zIndex=(o=t.style.zIndex)!=null?o:RT,t.style.position="absolute",this.rootAnnotationsContainer.append(t),this.annotations.set(e,t)}get(e){let t=this.annotations.get(e);if(!t)throw new cd(P$);return t}remove(e){let t=this.get(e);this.annotations.delete(e)&&t.remove()}clear(){for(let e in this.annotations.keys())this.remove(e)}destroy(){var e;this.annotations.clear(),this.subscriptions.unsubscribe(),(e=this.mutationObserver)==null||e.disconnect(),this.rootAnnotationsContainer=null}isElementExceedsBoundaries(e,t,o){let r=e.offsetTop,a=e.offsetLeft,l=e.offsetWidth,d=e.offsetHeight;return r<0||a<0||a+l>t||r+d>o}registryRootContainer(e){}addLayer(e){return document.createElement("div")}getLayer(e){}removeLayer(e){}clearLayer(e){}detach(){}reattach(){}};var fl=require("@vkontakte/videoplayer-shared/es2015"),gn=class{init({store:e,microStores:t,interactiveController:o,config:r}){return(0,fl.assertNonNullable)(e),(0,fl.assertNonNullable)(t),(0,fl.assertNonNullable)(r),r.interactiveData&&(0,fl.assertNonNullable)(o),this.subscription=new fl.Subscription,this.subscription}};var Uc=class extends gn{constructor(){super(...arguments);this.stateName="fakeIsPlaying$";this.state$=Gt(Ve({},ae(null)),{toggle:()=>this.state$.update(t=>!t)})}init(t){let o=super.init(t),{isInteractiveExpectation$:r}=t.store.state;return o.add(r.subscribe(a=>{this.state$.set(a?!0:null)})),o}};var zc=class extends gn{constructor(){super(...arguments);this.stateName="interactiveControlsOpacity$";this.state$=Gt(Ve({},ae(null)),{toggle:()=>this.state$.update(t=>!t)})}init(t){let o=super.init(t),{microStores:r,store:a}=t,{fakeIsPlaying$:l}=r,{isInteractiveExpectation$:d,isPlaying$:s}=a.state,{controlsVisible:u,isMobile:m}=a.ui,p=be(m),v=()=>p&&be(u);return o.add(u.subscribe(b=>{if(!p)return;let y=be(l);be(s)?this.state$.set(b):y!==null&&this.state$.set(!y||b)})),o.add(s.subscribe(b=>{this.state$.set(!b||v())})),o.add(l.subscribe(b=>{if(b===null)return;let y=be(d);if(v()){this.state$.set(!0);return}y&&this.state$.set(!b)})),o}};var Wc=class extends gn{constructor(){super(...arguments);this.stateName="seekToInteractiveDisabledTooltip$";this.state$=ae("tooltip_chapter_without_interactive")}init(t){let o=super.init(t),{store:r}=t;return o.add(r.state.interactiveEpisodes$.subscribe(a=>{a.length&&(a.every(l=>l.completed)?this.state$.set("tooltip_interactive_of_chapter_completed"):this.state$.set("tooltip_disabled_when_interactive"))})),o}};var k$=require("@vkontakte/videoplayer-shared/es2015");var hg=ae(!1),Vp=null,Kc=class extends gn{constructor(){super(...arguments);this.stateName="showInteractiveTimeIndicatorTooltip$";this.state$=Gt(Ve({},hg),{set:(t,o=!1)=>{t!==be(hg)&&(this.clearTimeout(),hg.set(t),!t&&Vp&&(Vp=!1),t&&o&&(this.timeout=setTimeout(()=>{this.state$.set(!1)},3e3)))},clearTimeout:()=>this.clearTimeout()})}init(t){let o=super.init(t),{store:r,config:a}=t,{isInteractiveTime$:l,isPlaying$:d}=r.state,s=r.ui.controlsVisible,{interactiveTimeIndicator:u}=r.ui.controls;o.add(s.subscribe(p=>{be(l)&&p&&this.state$.set(!1)}));let m=(a==null?void 0:a.interactiveData)||{tooltipHelpHintActive:!1};return o.add((0,k$.combine)({isPlaying$:d,isInteractiveTime$:l,interactiveTimeIndicator:u}).subscribe(({isPlaying$:p,isInteractiveTime$:v,interactiveTimeIndicator:b})=>{var y,_;if(!(!p||!(b!=null&&b.isDisplayed))){if(!v)return this.state$.set(!1);m.tooltipHelpHintActive&&Vp===null&&(Vp=!0,m.tooltipHelpHintActive=!1,this.state$.set(!0),(_=(y=r.callbacks)==null?void 0:y.onInteractiveTimeIndicatorHintDeactivated)==null||_.call(y))}})),o}clearTimeout(){window.clearTimeout(this.timeout)}};var Rp=require("@vkontakte/videoplayer-shared/es2015");var qc=class extends gn{constructor(){super(...arguments);this.stateName="graphIsOpened$";this.graphMadePause=!1;this.state$=Gt(Ve({},ae(null)),{toggle:Rp.noop});this.checkIfShouldHide=t=>Fs(t,"s")}init(t){let o=super.init(t),{store:r,interactiveController:a}=t,l=r.ui.currentGridType$,d=r.getLogger().createComponentLog("GraphIsOpened microStore");return this.state$.toggle=()=>bt(this,null,function*(){if(this.checkIfShouldHide(be(l)))return;let s=be(this.state$),{isEnded$:u,playbackState$:m}=r.state,{disabledControls$:p}=r.ui.controls,v=be(u),b=be(m);if(s)try{yield a==null?void 0:a.toggleGraphView(!1),this.state$.set(!1),p.remove(qf),!v&&this.graphMadePause&&r.actions.internal.play()}catch(y){d({message:"Cant hide graph"})}else{this.graphMadePause=b==="playing";try{yield a==null?void 0:a.toggleGraphView(!0),this.state$.set(!0),p.add(qf),!v&&this.graphMadePause&&r.actions.internal.pause()}catch(y){d({message:"Cant show graph"})}}}),o.add((0,Rp.combine)({graphIsOpened:this.state$,currentGridType:l}).subscribe(m=>bt(this,[m],function*({graphIsOpened:s,currentGridType:u}){if(this.checkIfShouldHide(u)&&s)try{yield a==null?void 0:a.toggleGraphView(!1),this.state$.set(!1)}catch(v){d({message:"Cant hide graph"})}}))),o}};var _g=require("@vkontakte/videoplayer-shared/es2015"),Qc=class extends gn{constructor(){super(...arguments);this.stateName="pictureInPicture$";this.state$={isActive$:ae(!1),isEnabled$:ae(!1),type$:ae(void 0)}}init(t){let o=super.init(t),{store:r}=t,{info:{isActive$:a,isEnabled$:l,type:d}}=r.webApi.pictureInPictureApi||{info:{isActive$:new _g.ValueSubject(!1),isEnabled$:new _g.ValueSubject(!1)}};return o.add(a.subscribe(s=>{this.state$.isActive$.set(s)})),o.add(l.subscribe(s=>{this.state$.isEnabled$.set(s)})),this.state$.type$.set(d),o}};var Dp=require("@vkontakte/videoplayer-shared/es2015");var Op=require("@vkontakte/videoplayer-shared/es2015");var A$=({maxShowCount:i,timeout:e})=>{let t=[i!==0?DT({maxCount:i}):void 0,e!==0?NT({timeout:e}):void 0].filter(o=>!!o);return{notificationShowed:o=>t.forEach(r=>r.notificationShowed(o)),canShowNotification:o=>t.every(r=>r.canShowNotification(o))}},DT=({maxCount:i})=>{let e={};return{notificationShowed:t=>{var o,r;e[t]=((o=e[t])!=null?o:0)+1,Op.safeStorage.set("videoplayer_notifications_manager_count",JSON.stringify((r=e[t])!=null?r:0))},canShowNotification:t=>{var o;return((o=e[t])!=null?o:0)<i}}},NT=({timeout:i})=>{let e="videoplayer_notifications_manager",t=()=>{try{return JSON.parse(Op.safeStorage.get(e)||"{}")}catch(a){return{}}},o=a=>Op.safeStorage.set(e,JSON.stringify(a)),r=a=>{let l=t();delete l[a],o(l)};return{notificationShowed:a=>{o(Gt(Ve({},t()),{[a]:{timeout:i,launchTime:Date.now()}}))},canShowNotification:a=>{let l=t()[a];if(l){let d=Date.now()-l.launchTime>i;return d&&r(a),d}else return!0}}};var Gc=class extends gn{constructor(){super(...arguments);this.stateName="notifications$";this.state$={notificationsToShow$:ae({}),showNotification:t=>{this.state$.notificationsToShow$.update(o=>(o[t]=!0,o)),this.notificationManager.notificationShowed(t)},closeNotification:t=>{this.state$.notificationsToShow$.update(o=>(delete o[t],o))}}}init(t){let o=super.init(t),{store:r,uiConfig:{features:{maxCountShowSlowVideoNotification:a,timeoutShowSlowVideoNotification:l,showSlowVideoNotification:d,forceAutoQualityWhenSevereStallHappens:s}}}=t;this.notificationManager=A$({maxShowCount:a,timeout:l});let u=r.getPlayer();return o.add(u.events.severeStallOccured$.pipe((0,Dp.filterChanged)(),(0,Dp.filter)(m=>m)).subscribe(()=>{d&&!u.info.isAutoQualityEnabled$.getValue()&&this.notificationManager.canShowNotification("slow_video")&&(s&&r.actions.internal.setQuality("auto"),this.state$.showNotification("slow_video"))})),o}};var L$=()=>[Uc,zc,Wc,Kc,qc,Qc,Gc].reduce(({subscribers:i,stores:e},t)=>{let o=new t;return{subscribers:[...i,o],stores:Gt(Ve({},e),{[o.stateName]:o.state$})}},{subscribers:[],stores:{}});var pd=require("@vkontakte/videoplayer-shared/es2015");var Np=class{constructor(e){this.getActiveElement=e;this.focusableElements=[];this.isActive=!1;this.handleTabKey=e=>{if(this.updateFocusableElements(),!this.focusableElements.length)return;let t=this.focusableElements[0],o=this.focusableElements[this.focusableElements.length-1],r=this.getActiveElement();e.shiftKey&&r===t?(e.preventDefault(),o.focus()):!e.shiftKey&&r===o&&(e.preventDefault(),t.focus())}}activate(){this.isActive||(document.addEventListener("keydown",this.handleTabKey),this.isActive=!0)}deactivate(){this.isActive&&(document.removeEventListener("keydown",this.handleTabKey),this.isActive=!1,this.focusableElements=[])}updateFocusableElements(){this.isActive&&(this.focusableElements=this.getFocusableElements())}getFocusableElements(){let e=["button:not([disabled])","[href]:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"]):not([disabled])'].join(", ");return Array.from(this.container.querySelectorAll(e)).filter(t=>!t.disabled&&t.offsetParent!==null)}destroy(){this.deactivate()}setContainer(e){this.container=e}};var Bp=class{constructor(e){this.shadowRoot=e;this.lastFocusedNode=null;this.init=()=>{this.shadowRoot.addEventListener("focusin",this.handleFocusChange)};this.handleFocusChange=()=>{this.lastFocusedNode=this.shadowRoot.activeElement};this.restoreFocus=()=>{var e;(e=this.lastFocusedNode)==null||e.focus()};this.focusLock=new Np(()=>this.lastFocusedNode),this.init()}destroy(){this.shadowRoot.removeEventListener("focusin",this.handleFocusChange),this.focusLock.destroy()}getLastFocusedNode(){return this.lastFocusedNode}activateLock(){this.focusLock.activate()}deactivateLock(){this.focusLock.deactivate()}setContainerForFocusLock(e){this.focusLock.setContainer(e)}};var BT=L('<div class="root s-3"><!></div>'),HT={hash:"s-3",code:".root.s-3{align-items:center;display:flex;inset:0;justify-content:center;pointer-events:none;position:absolute;z-index:1}"};function bg(i,e){B(e,!0),Q(i,HT);let t=null,o=K(null);Fe(()=>(n(o)&&(t=window.setTimeout(()=>{O(o,null)},e.animationDuration)),()=>{t&&clearTimeout(t)}));function r(s){e.playbackStatusShow&&O(o,s?"prev":"next",!0)}var a=Oe(),l=le(a);{var d=s=>{var u=Oe(),m=le(u);Rs(m,()=>n(o),p=>{var v=BT(),b=T(v);let y=f(()=>n(o)==="prev");Bc(b,{get duration(){return e.animationDuration},get Icon(){return _a},get reversed(){return n(y)}}),S(v),$(p,v)}),$(s,u)};V(l,s=>{e.playbackStatusShow&&n(o)&&s(d)})}return $(i,a),H({startVideoChangedAnimation:r})}var M$=require("@vkontakte/videoplayer-shared/es2015"),$g=(0,M$.getWindow)().HTMLElement||class{constructor(){this.isConnected=!1}};var FT=Object.defineProperty,UT=Object.defineProperties,zT=Object.getOwnPropertyDescriptors,V$=Object.getOwnPropertySymbols,WT=Object.prototype.hasOwnProperty,KT=Object.prototype.propertyIsEnumerable,xg=(i,e,t)=>e in i?FT(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,Gs=(i,e)=>{for(var t in e||(e={}))WT.call(e,t)&&xg(i,t,e[t]);if(V$)for(var t of V$(e))KT.call(e,t)&&xg(i,t,e[t]);return i},qT=(i,e)=>UT(i,zT(e)),jt=(i,e,t)=>xg(i,typeof e!="symbol"?e+"":e,t),Hp=(i,e,t)=>new Promise((o,r)=>{var a=s=>{try{d(t.next(s))}catch(u){r(u)}},l=s=>{try{d(t.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((t=t.apply(i,e)).next())}),QT={preload:!0,autoplay:!1,repeat:!1,loop:!1,fromTime:0,canRewindLive:!0,showAds:!1,interfaceLanguage:Fi.InterfaceLanguage.RU,isCyrillicRelatedInterface:!0,logoClickable:!1,logoHidden:!1,isTouch:(0,Yc.isMobile)(),isMediaSessionEnabled:!0,isPictureInPictureEnabled:!0,isAudioDisabled:!1,callbacks:{uiInfo:{}},tuningConfig:{},saveRate:!0,volumeMultiplier:1,showEndScreen:!0,showAutoplayNext:!0,showNextPrevButtons:!0},er=K(void 0),yg=li({animationDuration:0,playbackStatusShow:!1}),Fp=class extends $g{constructor(){super(),jt(this,"svelteStubComponent"),jt(this,"svelteRootComponent"),jt(this,"sveltePersistentLayerComponent"),jt(this,"svelteErrorComponent"),jt(this,"store"),jt(this,"microStoresRoot"),jt(this,"statistics"),jt(this,"sentry"),jt(this,"_shadowRoot"),jt(this,"playerContainer"),jt(this,"rootContainer"),jt(this,"stateContainer"),jt(this,"shadowRootContainer"),jt(this,"playerId"),jt(this,"uiConfig"),jt(this,"coreConfig"),jt(this,"statisticsConfig"),jt(this,"metaConfig"),jt(this,"interactiveController"),jt(this,"interactiveContainer"),jt(this,"graphMadePause"),jt(this,"currentPlayingVideoIndex",0),jt(this,"needToRepeatPlaylist",!1),jt(this,"videoConfig"),jt(this,"pictureInPictureApi"),jt(this,"mediaSessionApi"),jt(this,"unsubscribePlayerPhaseSubscription"),jt(this,"logger"),jt(this,"log"),jt(this,"subscription"),jt(this,"interactiveSubscription"),jt(this,"annotationsApi"),jt(this,"slotsApi"),jt(this,"focusManager"),jt(this,"prevIsid"),jt(this,"isInited",!1),jt(this,"postponedInitParams",null),jt(this,"internalsExposure",null),jt(this,"shadowDOMCallbacksDisabled",!1),jt(this,"fatalError$",new Up.ValueSubject(null)),jt(this,"createOneStat",(e,t={})=>{var o,r,a,l;if(!this.videoConfig)return;let{albumId:d,statPlace:s,statUserSalt:u,statTrackCode:m,statVKAppId:p,refreshStatAuthToken:v,autoplay:b,isMobile:y,isTouch:_,refDomain:x,deviceId:I,interactiveData:C}=Fc(this.videoConfig,t),R=(o=C==null?void 0:C.projectInfo)==null?void 0:o.pid,A=(a=(r=this.interactiveController)==null?void 0:r.state.isReplay$.getValue())!=null?a:!1;A&&(this.prevIsid=void 0);let{unitedVideoId:P,isClip:E=!1}=e;if(this.uiConfig.features.statistics&&P)try{return new fd.OneStat(Gs({movieId:P,albumId:d,place:s,trackCode:m,vkAppId:p,autoplay:(l=b&&!this.interactiveController)!=null?l:!1,mobile:_!=null?_:y,clip:E,refDomain:x,deviceId:I,isPreviewPlayerView:this.videoConfig.playerView==="preview"},R&&(!this.isInited||A)&&{projectId:Number(R)}),Gs({refreshAuthToken:v,userSalt:u,config:this.statisticsConfig},this.interactiveController&&{useIsid:!0,isid:this.prevIsid}))}catch(F){console.error(F),this.log({message:F.message})}}),pd.devNull.create("ui"),this.logger=new Fi.Logger,this.log=this.logger.createComponentLog("VKVideoPlayer"),this.subscription=new Fi.Subscription,this.interactiveSubscription=new Fi.Subscription,this.graphMadePause=!1,this.fatalError$.subscribe(e=>{this.unmountComponent(this.svelteErrorComponent),e&&(this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteRootComponent),this.svelteErrorComponent=es(mg,{target:this.playerContainer}))})}connectedCallback(){var e,t;if(this.rootContainer)return;this.initPlayerRootContainers();let o=(e=this.getAttribute("stub-title"))!=null?e:void 0,r=(t=this.getAttribute("stub-thumb-url"))!=null?t:void 0,a=li({title:o,thumbUrl:r}),l={target:this.playerContainer,props:a};this.svelteStubComponent=es(fg,l),this.sveltePersistentLayerComponent=es(bg,{target:this.playerContainer,props:yg}),this.postponedInitParams&&(this.initPlayer(...this.postponedInitParams),this.postponedInitParams=null)}updatePersistentLayerProps(){if(!this.uiConfig)return;let{playbackStatusNextVideoAnimationDuration:e,features:{playbackStatusShow:t,playbackStatusNextVideoShow:o}}=this.uiConfig;yg.animationDuration=e,yg.playbackStatusShow=t&&o}disconnectedCallback(){var e,t,o,r,a,l,d;this.shadowDOMCallbacksDisabled||((e=this.annotationsApi)==null||e.destroy(),(t=this.slotsApi)==null||t.destroy(),(o=this.focusManager)==null||o.destroy(),(r=this.mediaSessionApi)==null||r.destroy(),this.unmountComponent(this.svelteRootComponent),this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteErrorComponent),this.unmountComponent(this.sveltePersistentLayerComponent),this.subscription.unsubscribe(),(a=this.unsubscribePlayerPhaseSubscription)==null||a.call(this),(l=this.interactiveController)==null||l.destroy(),this.interactiveSubscription.unsubscribe(),(d=this.internalsExposure)==null||d.destroy(),pd.devNull.destroy("ui"))}initPlayerRootContainers(){this.rootContainer=document.createElement("div"),this.rootContainer.style.position="relative",this.rootContainer.className="root-container",this.rootContainer.style.width="100%",this.rootContainer.style.height="100%",this.rootContainer.style.minHeight="206px",this.shadowRootContainer=document.createElement("div"),this.shadowRootContainer.style.position="absolute",this.shadowRootContainer.className="shadow-root-container",this.shadowRootContainer.style.width="100%",this.shadowRootContainer.style.height="100%",this._shadowRoot=this.shadowRootContainer.attachShadow({mode:"open"}),this.playerContainer=document.createElement("div"),this.playerContainer.style.all="initial",this.playerContainer.style.display="block",this.playerContainer.style.contain="strict",this.playerContainer.style.width="100%",this.playerContainer.style.height="100%",this._shadowRoot.append(this.playerContainer),this.rootContainer.append(this.shadowRootContainer),this.stateContainer=document.createElement("div"),this.stateContainer.className="state-container",this.stateContainer.style.width="1px",this.stateContainer.style.height="1px",this.stateContainer.style.position="absolute",this.stateContainer.style.backgroundColor="transparent",this.stateContainer.style.left="-100000px",this.append(this.rootContainer),this.append(this.stateContainer)}needToShowNextPrevButtons(){return this.videoConfig?this.videoConfig.videos.length>1&&this.videoConfig.showNextPrevButtons:!1}isNextButtonActive(){return this.videoConfig?this.needToShowNextPrevButtons()&&(this.currentPlayingVideoIndex<this.videoConfig.videos.length-1||this.needToRepeatPlaylist):!1}isPrevButtonActive(){return this.videoConfig?this.needToShowNextPrevButtons()&&(this.currentPlayingVideoIndex>0||this.needToRepeatPlaylist):!1}isControlDisabled(e){var t;let o=(t=this.store)==null?void 0:t.ui.controls.disabledControls$;return(o==null?void 0:o.includes(e))||!1}getNextVideoInfo(){if(!this.videoConfig)return{nextVideoTitle:void 0,nextVideoThumb:void 0};let e=this.videoConfig.videos[this.currentPlayingVideoIndex+1]||{};return{nextVideoTitle:e.title,nextVideoThumb:e.thumbUrl}}createThinOneStat(e,t={}){if(!this.videoConfig)return;let{deviceId:o,preload:r,refreshStatAuthToken:a}=Fc(this.videoConfig,t),{unitedVideoId:l}=e;if(this.uiConfig.features.thinStatistics&&l)return new fd.ThinOneStat.ThinOneStat({deviceId:o,movieId:l,preload:r,isPreviewPlayerView:this.videoConfig.playerView==="preview"},{config:this.statisticsConfig,refreshAuthToken:a})}createPlayer(e,t={},o){var r,a,l,d,s,u,m,p,v,b;if(!this.videoConfig)return;let{albumId:y,statPlace:_,statAuthToken:x,preload:I,autoplay:C,volume:R,muted:A,fromTime:P,canRewindLive:E,supportLink:W,showAds:F,adsSlotId:U,adsParams:X={},adsAutoplayParam:se,interfaceLanguage:j,isCyrillicRelatedInterface:ne,logoClickable:Z,logoHidden:Te,isMobile:fe,isTouch:te,isAudioDisabled:_e,isLiveCatchUpMode:Ce,fullScreenTarget:me,failoverHosts:ce,canDownload:Ye,callbacks:G,interactiveData:D,showThumbTimer:Xe,additionalButtons:re=[],additionalSettingsMenuItems:pe=[],additionalContextMenuItems:ue=[],repeat:Ae,loop:ze,saveRate:ee,volumeMultiplier:de,showEndScreen:ke,showAutoplayNext:xe,mediascopePixels:Je}=Fc(this.videoConfig,t),{sources:Pe,title:we,thumbUrl:Ne,unitedVideoId:Pt,isClip:kt=!1,duration:Lt,adsParams:pt={},videoEpisodes:It,previewThumbsData:ei,subtitles:Ft,subtitlesForcedLanguage:Bt,live:qt,adsExternalApi:q,adsJson:Le}=e;if(!Pe&&!qt){let ui=new Error("empty sources and live");this.fatalError$.next(ui),(r=G.onCrashed)==null||r.call(G,ui.message);return}let Me=Gs(Gs({},X),pt),ye=this.getNextVideoInfo(),Ue={sources:Pe,title:we,thumbUrl:Ne,subtitles:Ft,subtitlesForcedLanguage:Bt,unitedVideoId:Pt,isClip:kt,live:qt,albumId:y,statPlace:_,autoplay:C,muted:A,volume:R,fromTime:P,canRewindLive:E,showAds:F,adsSlotId:U,adsParams:Me,adsAutoplayParam:se,duration:Lt,logoClickable:Z,logoHidden:Te,isTouch:te!=null?te:fe,repeat:Ae,loop:ze,showNextPrevButtons:this.needToShowNextPrevButtons(),nextButtonActive:this.isNextButtonActive(),prevButtonActive:this.isPrevButtonActive(),endScreenVideoTitle:ye.nextVideoTitle,endScreenVideoThumb:ye.nextVideoThumb,isOneVideoPlaylist:this.isOneVideoPlaylist()},Se={pictureInPictureApi:this.pictureInPictureApi,annotationsApi:this.annotationsApi,slotsApi:this.slotsApi,focusManager:this.focusManager};this.log({message:`create player, props: ${JSON.stringify(Ue)}`});let Tt=(a=this.interactiveController)==null?void 0:a.state.statistics$.getValue(),ve=(Tt==null?void 0:Tt.oneStat)||this.createOneStat(e,t),Be=this.createThinOneStat(e,t),qe;Je&&(qe=new fd.MediascopePixel({pixels:Je})),(ve||Be)&&(this.statistics=new gp(ve,Be,qe,Tt==null?void 0:Tt.statSubscription)),this.uiConfig.features.sentry&&this.uiConfig.sentry.dsn&&new Ka(this.uiConfig.sentry,{version:Ua,env:Du},{movieId:Pt,albumId:y,place:_,autoplay:(l=C&&!this.interactiveController)!=null?l:!1,mobile:te!=null?te:fe,clip:kt}),this.interactiveController&&((u=this.prevIsid)!=null||(this.prevIsid=(s=(d=this.statistics)==null?void 0:d.oneStat)==null?void 0:s.isid$.getValue())),this.sentry=Gs(Gs({},this.sentry),Ka.getInstance());let Xt=!!D,Mt=[],di="tooltip_interactive_go_back_disabled_first";if(Xt&&this.interactiveController){let ui=this.interactiveController.state.isInitialChapter$.getValue(),at=this.interactiveController.getHistoryState();ui&&Mt.push("REPLAY_BUTTON"),this.interactiveController.getIsSeekable().getValue()||Mt.push("SEEK_TO_INTERACTIVE_BUTTON"),at.hasPrevChapter$.getValue()||(Mt.push("PLAY_PREV_CHAPTER_BUTTON"),ui||(at.isGoBackLimited$.getValue()?di="tooltip_interactive_go_back_disabled_limit":di="tooltip_interactive_go_back_disabled"))}let ci=()=>{var ui;this.isInited=!1,this.prevIsid=void 0;let at=(o==null?void 0:o.info.isEnded$.getValue())&&((ui=this.interactiveController)==null?void 0:ui.state.isEndChapter$.getValue());G.onReplayInteractiveVideo&&!at?G.onReplayInteractiveVideo():this.replayInteractiveVideo()},Li=Ae&&this.videoConfig.videos.length===1;this.store=Fb({player:o,interfaceLanguage:j,isCyrillicRelatedInterface:ne,videoId:Pt,isClip:kt,isLiveCatchUpMode:Ce,isAudioDisabled:_e,statAuthToken:x,callbacks:G,webApi:Se,videoEpisodes:It,previewThumbsData:ei,canDownload:Ye,uiConfig:this.uiConfig,coreConfig:this.coreConfig,metaConfig:this.metaConfig,disabledControls:Mt,isInteractive:Xt,saveRate:ee,interactiveRanges$:(m=this.interactiveController)==null?void 0:m.state.interactiveRanges$,isInteractiveTime$:(p=this.interactiveController)==null?void 0:p.state.isInteractiveTime$,stopPlayer:()=>this.stop(),replayInteractive:ci,playPrevChapterDisabledTooltip:di,hasInteractiveBranches:!!((b=(v=this.interactiveController)==null?void 0:v.getChapterBranches())!=null&&b.length),additionalButtons:this.uiConfig.features.additionalButtons?re:[],additionalSettingsMenuItems:pe!=null?pe:[],additionalContextMenuItems:ue!=null?ue:[],playPrevVideo:()=>this.playPrevVideo(),playNextVideo:()=>this.playNextVideo(),onVideoChanged:ui=>{var at;return(at=this.sveltePersistentLayerComponent)==null?void 0:at.startVideoChangedAnimation(ui)},looped:this.uiConfig.features.useLoopSetting?ze:Li,statistics:this.statistics,internalsExposure:this.internalsExposure,playerView:this.videoConfig.playerView,playerId:this.playerId});let{stores:bo}=this.microStoresRoot=L$(),$o=()=>{var ui,at,pi,Ji,ft,Ht;if(!this.store||!this.microStoresRoot||!this.videoConfig)return;this.subscription.add(this.store.state.currentFormat$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onCurrentFormatChanged)==null?void 0:st.call(G,rt)})),this.subscription.add(bo.interactiveControlsOpacity$.subscribe(rt=>{var st;rt!==null&&((st=this==null?void 0:this.interactiveController)==null||st.setDisabledControls(rt))})),this.subscription.add(this.store.state.throughputEstimation$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onThroughputEstimationChanged)==null?void 0:st.call(G,rt)})),this.subscription.add(this.store.state.trafficSavingEnabled$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onTrafficSavingEnabledChanged)==null?void 0:st.call(G,rt)})),this.subscription.add(this.store.state.highQualityEnabled$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onHighQualityEnabledChanged)==null?void 0:st.call(G,rt)})),this.subscription.add(this.store.state.isAutoQualityEnabled$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onAutoQualityEnabledChanged)==null?void 0:st.call(G,!!rt)})),this.subscription.add(new Fi.Observable(rt=>{this.store&&this.subscription.add(this.store.state.currentPlaybackRate$.subscribe(st=>rt.next(st)))}).pipe((0,Fi.skip)(1)).subscribe(rt=>{var st;return(st=G==null?void 0:G.onCurrentPlaybackRateChanged)==null?void 0:st.call(G,rt)})),this.subscription.add(this.store.state.volume$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onVolumeChange)==null?void 0:st.call(G,rt)})),this.subscription.add(this.store.state.muted$.subscribe(rt=>{var st,Pi,rn,No;if(rt)(st=G==null?void 0:G.onMute)==null||st.call(G);else{let yt=(rn=((Pi=this.store)==null?void 0:Pi.state.volume$)&&be(this.store.state.volume$))!=null?rn:0;(No=G==null?void 0:G.onUnmute)==null||No.call(G,yt)}})),this.subscription.add(this.store.state.videoBitrate$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onVideoBitrateChanged)==null?void 0:st.call(G,rt)})),this.subscription.add(this.store.state.isInteractiveTime$.subscribe(rt=>{var st;let Pi=(st=this.store)==null?void 0:st.ui.controls.disabledControls$;Pi&&(rt&&!Pi.includes(qd)&&Pi.add(qd),rt||Pi.remove(qd))})),this.subscription.add(this.store.ui.isFullscreen.subscribe(rt=>Hp(this,null,function*(){var st;if(!Yc.clientChecker.browser.isSamsungBrowser||!rt||!this.interactiveController)return;document.fullscreenElement===this.shadowRootContainer&&(yield this.replayInteractiveChapter((st=this.videoConfig)==null?void 0:st.callbacks.onExternalFullscreenExit))}))),this.statistics&&this.statistics.oneStat&&this.subscription.add(this.statistics.oneStat.vsid$.subscribe(rt=>{var st;return(st=G==null?void 0:G.onVSIDChanged)==null?void 0:st.call(G,rt)})),this.initMediaSession(),O(er,{interactiveController:this.interactiveController,interactiveContainer:this.interactiveContainer,sources:Pe,store:this.store,microStoresRoot:this.microStoresRoot,videoConfig:this.videoConfig,uiConfig:this.uiConfig,title:we,thumbUrl:Ne,subtitles:Ft,subtitlesForcedLanguage:Bt,live:qt,preload:I,autoplay:C,muted:A,volume:R,fromTime:P,canRewindLive:E,supportLink:W,showAds:F,adsSlotId:U,adsParams:Me,adsAutoplayParam:se,duration:Lt,logoClickable:Z,logoHidden:Te,isMobile:te!=null?te:fe,failoverHosts:ce,fullScreenTarget:me,saveRate:ee,shadowRootContainer:this.shadowRootContainer,showMiniTimer:Xe,outerContainerRef:this.rootContainer,showNextPrevButtons:this.needToShowNextPrevButtons(),nextButtonActive:this.isNextButtonActive(),prevButtonActive:this.isPrevButtonActive(),endScreenVideoTitle:ye.nextVideoTitle,endScreenVideoThumb:ye.nextVideoThumb,isOneVideoPlaylist:this.isOneVideoPlaylist(),playPrevChapter:()=>this.playPrevChapter(),seekToInteractive:()=>this.seekToInteractive(),volumeMultiplier:de,showEndScreen:ke,showAutoplayNext:xe,adsExternalApi:q,adsJson:Le,getVideoDeeplink:this.videoConfig.getVideoDeeplink},!0);let hi={target:this.playerContainer,props:n(er)};this.svelteRootComponent=es(ug,hi),this.addPlayerInfoSubscriptions(),this.isInited||(this.isInited=!0,(pi=(at=(ui=this.videoConfig)==null?void 0:ui.callbacks)==null?void 0:at.onInited)==null||pi.call(at)),(Ji=this.internalsExposure)==null||Ji.expose({player:this,videoConfig:this.videoConfig,coreConfig:this.coreConfig,uiConfig:this.uiConfig,statisticsConfig:this.statisticsConfig,logger:this.logger,log:this.log}),this.uiConfig.devNullLog&&((Ht=(ft=this.videoConfig)==null?void 0:ft.callbacks)!=null&&Ht.onDevNullLog)?pd.devNull.subscribe("ui",this.videoConfig.callbacks.onDevNullLog):pd.devNull.destroy("ui")};this.coreConfig.asyncResolveClientChecker?Yc.clientChecker.isInited$.subscribe(ui=>{ui&&(console.log("UI SDK async start"),$o())}):$o()}addPlayerInfoSubscriptions(){var e,t;let o=this.store,r=(e=this.microStoresRoot)==null?void 0:e.stores;if(!o||!r)return;let a=(t=this.videoConfig)==null?void 0:t.callbacks;a&&this.subscription.add(o.playerPhase.subscribe(d=>{var s;return(s=a.onPlayerPhaseChanged)==null?void 0:s.call(a,d)})).add(o.state.playbackState$.subscribe(d=>{var s;return d&&((s=a.onPlaybackStateChanged)==null?void 0:s.call(a,d))})).add(o.state.playbackStateRealistic$.subscribe(d=>{d?this.stateContainer.setAttribute("data-playback-state",d):this.stateContainer.removeAttribute("data-playback-state")})).add(o.state.isLive$.subscribe(d=>{var s;return(s=a.onIsLiveChanged)==null?void 0:s.call(a,d)})).add(o.state.isActiveLive$.subscribe(d=>{var s;return(s=a.onIsActiveLiveChanged)==null?void 0:s.call(a,d)})).add(o.state.isAudioAvailable$.subscribe(d=>{var s;return(s=a.onIsAudioAvailableChanged)==null?void 0:s.call(a,d)})).add(o.state.currentQuality$.subscribe(d=>{var s;return(s=a.onCurrentQualityChanged)==null?void 0:s.call(a,d)})).add(o.state.availableQualities$.subscribe(d=>{var s;return(s=a.onAvailableQualitiesChanged)==null?void 0:s.call(a,d.map(({value:u})=>u).filter(u=>u!=="auto"))})).add(o.state.availableAudioStreams$.subscribe(d=>{d.length>1&&a.onAudioLanguagesAvailable&&a.onAudioLanguagesAvailable()})).add(r.pictureInPicture$.isActive$.subscribe(d=>{var s,u;return d?(s=a.onPiPEnter)==null?void 0:s.call(a):(u=a.onPiPExit)==null?void 0:u.call(a)}));let l=a==null?void 0:a.uiInfo;l&&this.subscription.add(o.ui.controlsVisible.subscribe(d=>{var s;return(s=l.onControlsVisibleChanged)==null?void 0:s.call(l,d)})).add(o.ui.isMobile.subscribe(d=>{var s;return(s=l.onIsMobileChanged)==null?void 0:s.call(l,d)})).add(o.ui.playerSize.subscribe(d=>{var s;return(s=l.onPlayerSizeChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.prevButton.subscribe(d=>{var s;return(s=l.onPrevButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.playButton.subscribe(d=>{var s;return(s=l.onPlayButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.replayButton.subscribe(d=>{var s;return(s=l.onReplayButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.nextButton.subscribe(d=>{var s;return(s=l.onNextButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.playPrevChapterButton.subscribe(d=>{var s;return(s=l.onPlayPrevChapterChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.seekToInteractiveButton.subscribe(d=>{var s;return(s=l.onSeekToInteractiveButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.interactiveGraphButton.subscribe(d=>{var s;return(s=l.onGraphButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.liveButton.subscribe(d=>{var s;return(s=l.onLiveButtonChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.time.subscribe(d=>{var s;return(s=l.onTimeUpdateChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.episodes.subscribe(d=>{var s;return(s=l.onEpisodesChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.subtitles.subscribe(d=>{var s;return(s=l.onSubtitlesChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.topLeft.subscribe(d=>{var s;return(s=l.onTopLeftControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.topRight.subscribe(d=>{var s;return(s=l.onTopRightControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.bottomLeft.subscribe(d=>{var s;return(s=l.onBottomLeftControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.bottomRight.subscribe(d=>{var s;return(s=l.onBottomRightControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.middle.subscribe(d=>{var s;return(s=l.onMiddleControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.controlBlocks.bottom.subscribe(d=>{var s;return(s=l.onBottomControlBlockChanged)==null?void 0:s.call(l,d)})).add(o.ui.videoTitleInfo.subscribe(d=>{var s;return(s=l.onTitleChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.settings.subscribe(d=>{var s;return(s=l.onSettingsChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.fullscreen.subscribe(d=>{var s;return(s=l.onFullscreenChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.chromecast.subscribe(d=>{var s;return(s=l.onChromecastChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.pip.subscribe(d=>{var s;return(s=l.onPipChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls["theater-mode-button"].subscribe(d=>{var s;return(s=l.onTheaterModeChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.vkLogo.subscribe(d=>{var s;return(s=l.onVkLogoChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.interactiveTimeIndicator.subscribe(d=>{var s;return(s=l.onInteractiveTimeIndicatorChanged)==null?void 0:s.call(l,d)})).add(o.ui.controls.timeline.subscribe(d=>{var s;return(s=l.onTimelineChanged)==null?void 0:s.call(l,d)}))}playNextVideo(){this.videoConfig&&(this.currentPlayingVideoIndex++,this.currentPlayingVideoIndex>=this.videoConfig.videos.length&&(this.currentPlayingVideoIndex=0),this.log({message:`play next video, index: ${this.currentPlayingVideoIndex}`}),this.createPlayerWithCurrentVideo())}playPrevVideo(){this.videoConfig&&(this.currentPlayingVideoIndex--,this.currentPlayingVideoIndex<0&&(this.currentPlayingVideoIndex=this.videoConfig.videos.length-1),this.log({message:`play prev video, index: ${this.currentPlayingVideoIndex}`}),this.createPlayerWithCurrentVideo())}createPlayerWithCurrentVideo(e,t=!0){var o;if(!this.videoConfig)return;let r=this.videoConfig.videos[this.currentPlayingVideoIndex];if(!r){this.log({message:"no next video"});return}this.isInited&&(0,Fi.isNonNullable)(r.unitedVideoId)&&((o=this.store)==null||o.actions.internal.nextMovie(r.unitedVideoId)),this.unmountComponent(this.svelteRootComponent),this.createPlayer(r,{autoplay:t,fromTime:0},e)}playPrevChapter(){var e;(e=this.interactiveController)==null||e.playPrevChapter()}seekToInteractive(){var e;let t=(e=this.interactiveController)==null?void 0:e.getNextInteractiveStartTime();typeof t=="number"&&this.seekTime(t/1e3)}initInteractives(){return Hp(this,null,function*(){var e,t,o,r,a,l;if((e=this.videoConfig)!=null&&e.interactiveData)try{let{Interactives:d}=yield import("@vkontakte/videoplayer-interactive/es2015");this.interactiveContainer=document.createElement("div"),this.interactiveContainer.classList.add("interactive-root");let s=(t=this.store)==null?void 0:t.interfaceLanguage$,u=s?be(s):this.videoConfig.interfaceLanguage,{projectInfo:m,initChapterId:p,historyApi:v,videoLoader:b}=this.videoConfig.interactiveData;this.interactiveController=new d({parentElement:this.interactiveContainer,fullscreenTargetElement:this.playerContainer,lang:u,graph:this.uiConfig.features.interactiveGraph,projectInfo:m,initChapterId:p,historyApi:v,vkVideoLoader:b,lastFrame:this.uiConfig.features.interactiveLastFrame,permanentTextControls:this.uiConfig.features.interactiveTextPermanent,interactiveTimeOpenUri:this.uiConfig.features.interactiveTimeOpenUri,initSeamless:!0,config:this.uiConfig.interactive,coreConfig:this.coreConfig,createOneStat:this.createOneStat,isTouch:this.videoConfig.isTouch,animationsFeatureToggles:{areaControlShadow:this.uiConfig.features.interactiveAreaControlShadow,controlsExpectTimeBlinkAnimation:this.uiConfig.features.interactiveControlsExpectTimeBlinkAnimation,controlsTapPlace:this.uiConfig.features.interactiveControlsTapPlace,controlsFillAnimation:this.uiConfig.features.interactiveControlsFillAnimation,controlsHideAnimation:this.uiConfig.features.interactiveControlsHideAnimation},endChapterHistoryFix:this.uiConfig.features.interactiveHistoryEndChapterFix});let{isInteractiveExpectation$:y,isSeekable$:_}=this.interactiveController.state;this.uiConfig.features.seekToInteractive&&this.subscription.add(_.subscribe(I=>{if(!this.isInited)return;let C=this.store;I?C.ui.controls.disabledControls$.remove("SEEK_TO_INTERACTIVE_BUTTON"):C.ui.controls.disabledControls$.add("SEEK_TO_INTERACTIVE_BUTTON")})),this.subscription.add(y.subscribe(I=>{this.store&&this.store.state.isInteractiveExpectation$.set(I)}));let x=!0;if(this.subscription.add(this.interactiveController.events.playerChanged$.subscribe(I=>{if(!this.videoConfig)return;this.videoConfig.videos[this.currentPlayingVideoIndex]=qT(Gs({},I.config),{title:(m==null?void 0:m.title)||I.config.title});let C=x?this.videoConfig.autoplay:!0;this.createPlayerWithCurrentVideo(I.player,C),x&&(x=!1)})),this.interactiveSubscription.add(this.interactiveController.events.interactiveActionChoice$.subscribe(({type:I,actionType:C})=>{var R,A,P,E,W,F;if(!this.store||!this.microStoresRoot)return;let U=y.getValue();if(I==="action-choice"&&C==="setRandomBranch"&&(this.microStoresRoot.stores.graphIsOpened$.set(!1),this.store.ui.controls.disabledControls$.remove(Qd)),I==="action-choice-canceled"){let X=be(this.store.state.isPlaying$)||U;if(((P=(R=this.videoConfig)==null?void 0:R.isTouch)!=null?P:(A=this.videoConfig)!=null&&A.isMobile)&&X){this.store.ui.interactiveHideMobileControls.set(!0);return}(F=(E=this.videoConfig)==null?void 0:(W=E.callbacks).onDisabledInteractiveClick)==null||F.call(W)}})),this.interactiveSubscription.add(this.interactiveController.events.interactiveContainerFakeRemoved$.subscribe(({type:I,removeAllOpenURI:C})=>{this.store&&I==="container-fake-removed"&&C&&this.store.ui.controls.disabledControls$.remove(Qd)})),yield this.interactiveController.setManifest(this.videoConfig.interactiveData.manifest),(r=(o=this.videoConfig)==null?void 0:o.callbacks)!=null&&r.onInteractiveHistoryChanged){let I=this.interactiveController.getHistoryState();this.subscription.add(I.history$.subscribe(C=>{var R,A,P;C.length&&((P=(A=(R=this.videoConfig)==null?void 0:R.callbacks)==null?void 0:A.onInteractiveHistoryChanged)==null||P.call(A,C))}))}(l=(a=this.videoConfig)==null?void 0:a.callbacks)!=null&&l.onInteractiveChapterChanged&&this.subscription.add(this.interactiveController.events.chapterChanged$.subscribe(I=>{var C,R,A;(A=(C=this.videoConfig)==null?void 0:(R=C.callbacks).onInteractiveChapterChanged)==null||A.call(R,I.chapter,I.manifestVideo)})),this.uiConfig.features.interactiveTimeIndicator&&this.subscription.add(this.interactiveController.events.noInteraction$.subscribe(()=>{var I,C,R,A;(I=this.microStoresRoot)==null||I.stores.showInteractiveTimeIndicatorTooltip$.set(!0,!0),(A=(C=this.videoConfig)==null?void 0:(R=C.callbacks).onInteractiveTimeIndicatorClick)==null||A.call(R)})),this.interactiveSubscription.add(this.interactiveController.events.error$.subscribe(I=>{this.log({message:I.toString()})}))}catch(d){this.log({message:d.message})}})}initPlayer(e,t={}){var o,r,a,l,d,s,u,m,p,v,b,y,_,x,I,C,R,A,P,E,W,F,U,X,se;if(!this.isConnected){this.postponedInitParams=[e,t];return}if(!Array.isArray(e.videos)||e.videos.length===0&&!e.interactiveData){let j=new Error("empty videos");this.fatalError$.next(j),(r=(o=e.callbacks)==null?void 0:o.onCrashed)==null||r.call(o,j.message);return}else this.fatalError$.next(null);if(this.videoConfig=Fc(QT,(0,Fi.cloneDeepWith)(e,j=>j instanceof $g?j:void 0)),this.playerId=(0,Fi.getPlayerId)(e.playerId),this.uiConfig=m_((a=t.ui)!=null?a:{}),this.updatePersistentLayerProps(),this.coreConfig=(l=t.core)!=null?l:{},this.statisticsConfig=(d=t.statistics)!=null?d:{},this.metaConfig=t.meta,this.uiConfig.features.forcePlayerDisplayBlock&&(this.rootContainer&&(this.rootContainer.style.minHeight="unset"),this.style.display="block",this.style.width="100%",this.style.height="100%"),this.videoConfig.playerView==="preview"&&(this.playerContainer.style.contain="none"),this.sentry={config:(s=this.uiConfig.sentry)!=null?s:{}},this.uiConfig.features.exposeInternalsToGlobal&&((u=this.internalsExposure)!=null||(this.internalsExposure=new Fi.InternalsExposure("ui",this.playerId))),pd.devNull.push("ui",{key:"videoplayer_embed",strings:["new","player_init_player","ads.enable: "+this.uiConfig.ads.enable,"showAds: "+((m=this.videoConfig)==null?void 0:m.showAds)],numbers:[(0,Up.now)()]}),(0,Fi.isNonNullable)(this.videoConfig.isMediaSessionEnabled)&&(this.uiConfig.features.mediaSession=(v=(p=this.uiConfig.features.mediaSession)!=null?p:this.videoConfig.isMediaSessionEnabled)!=null?v:!0),(0,Fi.isNonNullable)(this.videoConfig.isPictureInPictureEnabled)&&(this.uiConfig.features.pip=(y=(b=this.uiConfig.features.pip)!=null?b:this.videoConfig.isPictureInPictureEnabled)!=null?y:!0,this.uiConfig.features.dpip=(x=(_=this.uiConfig.features.dpip)!=null?_:this.videoConfig.isPictureInPictureEnabled)!=null?x:!0),this.uiConfig.ads.paramsOverride=Gs({preview:(I=this.uiConfig.ads.preview)!=null?I:this.videoConfig.adsPreviewParam},this.uiConfig.ads.paramsOverride),this.videoConfig.isTouch=(R=(C=this.uiConfig.isMobile)!=null?C:this.videoConfig.isTouch)!=null?R:this.videoConfig.isMobile,(A=this.videoConfig).autoplay&&(A.autoplay=this.uiConfig.features.autoplay),this.videoConfig.showAds=(P=this.uiConfig.ads.enable)!=null?P:this.videoConfig.showAds,this.videoConfig.adsSlotId=(E=this.uiConfig.ads.slot)!=null?E:this.videoConfig.adsSlotId,this.videoConfig.logoHidden=!((W=this.uiConfig.showLogo)!=null?W:!this.videoConfig.logoHidden),(F=this.videoConfig).canRewindLive&&(F.canRewindLive=this.uiConfig.features.liveRewind),this.videoConfig.supportLink=(U=this.videoConfig.supportLink)!=null?U:this.uiConfig.supportLink,this.videoConfig.showEndScreen=this.uiConfig.features.endScreen&&this.videoConfig.showEndScreen,this.videoConfig.showAutoplayNext=this.uiConfig.features.autoplayNext&&this.videoConfig.showAutoplayNext,this.videoConfig.showNextPrevButtons=this.uiConfig.features.nextPrevButtons&&this.videoConfig.showNextPrevButtons,this.currentPlayingVideoIndex=this.videoConfig.videoIndex&&((X=this.videoConfig.videos)!=null&&X[this.videoConfig.videoIndex])?this.videoConfig.videoIndex:0,this.needToRepeatPlaylist=this.videoConfig.repeat,this.uiConfig.features.pip){let j={enabled:this.videoConfig.pipEnabled};this.uiConfig.features.dpip?this.pictureInPictureApi=Lp.getLatestSupportedVersion(j):this.pictureInPictureApi=new Us(j)}this.mediaSessionApi=this.uiConfig.features.mediaSession?new kp:void 0,this.slotsApi=this.uiConfig.features.slots?new Tp(this.uiConfig.disabledSlotIds):void 0,this.annotationsApi=this.uiConfig.features.annotations?new Mp(this.uiConfig.features.annotationsInside):void 0,this.annotationsApi&&!this.uiConfig.features.annotationsInside&&this.annotationsApi.init(this.rootContainer),this.focusManager=this._shadowRoot?new Bp(this._shadowRoot):void 0,this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteRootComponent),this.unmountComponent(this.svelteErrorComponent),this.isInited=!1,this.prevIsid=void 0,this.interactiveController&&(this.interactiveController.destroy(),this.interactiveController=void 0,this.interactiveSubscription.unsubscribe()),this.videoConfig.interactiveData?this.initInteractives():this.createPlayer(this.videoConfig.videos[this.currentPlayingVideoIndex]),T$(this.pictureInPictureApi)&&this.pictureInPictureApi.setPlayerDomElement(this.playerContainer,this._shadowRoot),(se=this.slotsApi)==null||se.init(this.shadowRootContainer,this.store)}isOneVideoPlaylist(){return this.videoConfig?this.videoConfig.videos.length===1:!1}updateVideos(e,t){if(!this.videoConfig)return;this.log({message:`update ${t} videos, videos: ${JSON.stringify(e)}`}),t==="prev"?(this.videoConfig.videos.splice(0,this.currentPlayingVideoIndex),this.videoConfig.videos.unshift(...e),this.currentPlayingVideoIndex=e.length):t==="next"&&(this.videoConfig.videos.splice(this.currentPlayingVideoIndex+1),this.videoConfig.videos.push(...e));let o=this.getNextVideoInfo();n(er)&&(n(er).showNextPrevButtons=this.needToShowNextPrevButtons(),n(er).nextButtonActive=this.isNextButtonActive(),n(er).prevButtonActive=this.isPrevButtonActive(),n(er).endScreenVideoTitle=o.nextVideoTitle,n(er).endScreenVideoThumb=o.nextVideoThumb,n(er).isOneVideoPlaylist=this.isOneVideoPlaylist())}updatePrevVideos(e){this.updateVideos(e,"prev")}updateNextVideos(e){this.updateVideos(e,"next")}initMediaSession(){var e,t;this.mediaSessionApi&&((e=this.unsubscribePlayerPhaseSubscription)==null||e.call(this),this.mediaSessionApi.clearSubscriptions(),this.unsubscribePlayerPhaseSubscription=(t=this.store)==null?void 0:t.playerPhase.subscribe(o=>{o==="video"?this.setupMediaSessionForVideo():o==="ads"&&this.setupMediaSessionForAds()}))}setupMediaSessionForVideo(){if(!(!this.videoConfig||!this.mediaSessionApi))try{let{title:e,thumbUrl:t}=Gs({},this.videoConfig.videos[this.currentPlayingVideoIndex]),o=[["play",()=>this.play()],["pause",()=>this.pause()],["seekto",r=>this.seekTime(r.seekTime)]];this.videoConfig.videos.length>1&&(this.currentPlayingVideoIndex<this.videoConfig.videos.length-1&&o.push(["nexttrack",()=>{var r,a,l;if(this.uiConfig.features.useCallbackForMediaSessionNextPrevClick)try{(l=(a=(r=this.videoConfig)==null?void 0:r.callbacks)==null?void 0:a.onNextVideoClick)==null||l.call(a)}catch(d){this.log({message:"onNextVideoClick callback failed to execute"})}else this.playNextVideo()}]),this.currentPlayingVideoIndex>0&&o.push(["previoustrack",()=>{var r,a,l;if(this.uiConfig.features.useCallbackForMediaSessionNextPrevClick)try{(l=(a=(r=this.videoConfig)==null?void 0:r.callbacks)==null?void 0:a.onPrevVideoClick)==null||l.call(a)}catch(d){this.log({message:"onPrevVideoClick callback failed to execute"})}else this.playPrevVideo()}])),this.mediaSessionApi.setMetaData({title:e,thumbUrl:t}),this.mediaSessionApi.updateActionHandlers(o),this.mediaSessionApi.attachToStore(this.store)}catch(e){this.log({message:e.message})}}setupMediaSessionForAds(){if(!(!this.videoConfig||!this.mediaSessionApi))try{let e="Реклама",t=[["play",()=>this.play()],["pause",()=>this.pause()]];this.mediaSessionApi.setMetaData({title:e}),this.mediaSessionApi.updateActionHandlers(t),this.mediaSessionApi.attachToStore(this.store)}catch(e){this.log({message:e.message})}}moveTo(e){this.shadowDOMCallbacksDisabled=!0,e.append(this),this.shadowDOMCallbacksDisabled=!1}play(){var e,t,o,r;this.isControlDisabled("PLAY_BUTTON")||(e=this.store)!=null&&e.playerPhase.is("LiveWaitingStart")||(t=this.store)!=null&&t.playerPhase.is("LiveWaitingRecover")||(o=this.store)!=null&&o.playerPhase.is("LiveWaitingRecord")||(this.log({message:"play"}),(r=this.svelteRootComponent)==null||r.play())}pause(){var e;this.log({message:"pause"}),(e=this.svelteRootComponent)==null||e.pause()}stop(){var e;if(!this.videoConfig)return;this.log({message:"stop"});let t=!!this.interactiveController;t&&(this.interactiveController.destroy(),this.interactiveController=void 0,this.interactiveContainer=void 0,this.interactiveSubscription.unsubscribe()),this.unmountComponent(this.svelteStubComponent),(e=this.mediaSessionApi)==null||e.destroy();let o=this.videoConfig.videos[0];o&&(this.unmountComponent(this.svelteRootComponent),t?(this.videoConfig.autoplay=!1,this.initInteractives()):this.createPlayer(o))}setMuted(e){var t;this.log({message:`set muted, muted: ${e}`}),(t=this.svelteRootComponent)==null||t.setMuted(e)}toggleSubtitle(){var e;this.log({message:"toggle subtitle"}),(e=this.svelteRootComponent)==null||e.toggleSubtitle()}changeSubtitle(e,t){var o;this.log({message:"change subtitle"}),(o=this.svelteRootComponent)==null||o.changeSubtitle(e,t)}hideControls(){var e;this.log({message:"hide controls"}),(e=this.svelteRootComponent)==null||e.hideControls()}showControls(){var e;this.log({message:"show controls"}),(e=this.svelteRootComponent)==null||e.showControls()}setPiPEnabled(e){var t,o;(o=(t=this.store)==null?void 0:t.webApi.pictureInPictureApi)==null||o.setEnabled(e)}setVolume(e){var t;this.log({message:`set volume, volume: ${e}`}),(t=this.svelteRootComponent)==null||t.setVolume(e)}setRepeat(e){this.log({message:`set repeat, repeat: ${e}`}),this.needToRepeatPlaylist=e,n(er)&&(n(er).needToRepeatPlaylist=this.needToRepeatPlaylist,n(er).showNextPrevButtons=this.needToShowNextPrevButtons(),n(er).nextButtonActive=this.isNextButtonActive(),n(er).prevButtonActive=this.isPrevButtonActive())}seekTime(e){var t;this.isControlDisabled("TIMELINE")||(this.log({message:`seek time, time: ${e}`}),(t=this.svelteRootComponent)==null||t.seekTime(e))}seekEpisodeStartTime(e){var t;this.log({message:`seek episode start time, time: ${e}`}),(t=this.svelteRootComponent)==null||t.seekEpisodeStartTime(e)}returnFocusToEpisodes(){var e;this.log({message:"return focus to episodes button"}),(e=this.svelteRootComponent)==null||e.returnFocusToEpisodes()}setPlaybackRate(e){var t;this.log({message:`set playback rate to: ${e}`}),(t=this.svelteRootComponent)==null||t.setPlaybackRate(e)}setAutoQualityLimits(e){var t,o,r;this.log({message:`set auto quality limitation. Max: ${(t=e.max)!=null?t:"none"}. Min: ${(o=e.min)!=null?o:"none"}`}),(r=this.svelteRootComponent)==null||r.setAutoQualityLimits(e)}setAutoQuality(){var e;(e=this.svelteRootComponent)==null||e.setAutoQuality()}toggleTrafficSaving(e){var t;(t=this.svelteRootComponent)==null||t.toggleTrafficSaving(e)}toggleHighQuality(e){var t;(t=this.svelteRootComponent)==null||t.toggleHighQuality(e)}changeAudioStream(e){var t;(t=this.svelteRootComponent)==null||t.changeAudioStream(e)}addLanguage(e){var t;(t=this.store)==null||t.actions.internal.addLanguage(e)}setLanguage(e){return Hp(this,null,function*(){var t;yield(t=this.store)==null?void 0:t.actions.internal.setLanguage(e)})}setLiveStart(e){var t,o;let r=this.isLiveTailPlaying();this.log({message:`live started: liveTailPlaying = ${r}`}),r||((t=this.store)==null||t.actions.internal.setLiveWaitingRecover(!1),(o=this.store)==null||o.actions.internal.setLiveWaitingStart(!1),this.unmountComponent(this.svelteRootComponent),this.createPlayer(e,{autoplay:!0}))}setLiveWaitingStart(){var e;this.log({message:"live waiting"}),(e=this.store)==null||e.actions.internal.setLiveWaitingStart(!0)}isLiveTailPlaying(){var e;let t=(e=this.store)==null?void 0:e.getPlayer();if(!t)return!1;let{info:o}=t;return o.canPlayLiveTailBuffer$.getValue()&&!o.isStalled$.getValue()&&!o.atLiveEdge$.getValue()}setLiveWaitingRecover(e=!1){var t;let o=this.isLiveTailPlaying(),r=e||!o;this.log({message:`live waiting recover: forceImmediate = ${e}, liveTailPlaying = ${o}`});let a=()=>{var l;(l=this.store)==null||l.actions.internal.setLiveWaitingRecover(!0)};r&&a(),(t=this.store)!=null&&t.callbacks&&(this.store.callbacks.onLiveEnded=()=>{var l;r||a(),(l=this.store)==null||l.destroy()})}setLiveWaitingRecord(){var e;let t=this.isLiveTailPlaying(),o=!t;this.log({message:`live waiting record: liveTailPlaying = ${t}`});let r=()=>{var a;(a=this.store)==null||a.actions.internal.setLiveWaitingRecord(!0)};o&&r(),(e=this.store)!=null&&e.callbacks&&(this.store.callbacks.onLiveEnded=()=>{var a;o||r(),(a=this.store)==null||a.destroy()})}setLiveEnd(e){var t;let o=this.isLiveTailPlaying(),r=!o;this.log({message:`live ended: liveTailPlaying = ${o}`});let a=()=>{var l,d;(l=this.store)==null||l.actions.internal.setLiveWaitingRecover(!1),(d=this.store)==null||d.actions.internal.setLiveWaitingRecord(!1),this.unmountComponent(this.svelteRootComponent),this.createPlayer(e,{autoplay:!1})};if(r){a();return}(t=this.store)!=null&&t.callbacks&&(this.store.callbacks.onLiveEnded=a)}setLiveLowLatency(e){var t;this.log({message:"live switch to low latency "+e}),(t=this.store)==null||t.actions.external.setLiveLowLatency(e)}setLooped(e){var t;(t=this.store)==null||t.actions.internal.setLooped(e)}getDebugData(){var e,t;return(t=(e=this.store)==null?void 0:e.actions.internal.getDebugTextData())!=null?t:""}getDeviceId(){var e,t,o;return(o=(t=(e=this.statistics)==null?void 0:e.oneStat)==null?void 0:t.getDeviceId())!=null?o:void 0}replayInteractiveVideo(){this.interactiveController&&this.interactiveController.setChapter()}replayInteractiveChapter(e){return Hp(this,null,function*(){var t,o;if(this.interactiveController&&((t=this.store)!=null&&t.state.positionExact$)){let r=be(this.store.state.positionExact$),l=be(this.store.state.interactiveEpisodes$).find(s=>!s.completed);this.interactiveController.events.playerChanged$.pipe((0,Fi.once)()).subscribe(()=>{l&&r>=l.time?this.seekTime(l.time):this.seekTime(r),e==null||e()});let d=this.interactiveController.getCurrentChapter();yield this.interactiveController.setChapter({chapterId:(o=d==null?void 0:d.chapter)==null?void 0:o.id,pushToHistory:!1})}})}showInteractiveIndicatorTooltip(e,t=!1){var o;(o=this.microStoresRoot)==null||o.stores.showInteractiveTimeIndicatorTooltip$.set(e,t)}switchToActiveLive(){var e;(e=this.store)==null||e.actions.internal.switchToActiveLive()}updateAdditionalSettingsItem(e,t){var o;(o=this.store)==null||o.actions.external.updateAdditionalSettingsItem(e,t)}addAdditionalSettingsItem(e){var t;(t=this.store)==null||t.actions.external.addAdditionalSettingsItem(e)}removeAdditionalSettingsItem(e){var t;(t=this.store)==null||t.actions.external.removeAdditionalSettingsItem(e)}updateAdditionalContextItem(e,t){var o;(o=this.store)==null||o.actions.external.updateAdditionalContextItem(e,t)}addAdditionalContextItem(e){var t;(t=this.store)==null||t.actions.external.addAdditionalContextItem(e)}removeAdditionalContextItem(e){var t;(t=this.store)==null||t.actions.external.removeAdditionalContextItem(e)}updateAdditionalButton(e,t){var o;(o=this.store)==null||o.actions.external.updateAdditionalButton(e,t)}addAdditionalButton(e){var t;(t=this.store)==null||t.actions.external.addAdditionalButton(e)}removeAdditionalButton(e){var t;(t=this.store)==null||t.actions.external.removeAdditionalButton(e)}updateStatContext(e){this.statistics&&(this.statistics.oneStat&&this.statistics.oneStat.updateContext(e),this.statistics.thinOneStat&&this.statistics.thinOneStat.updateContext(e))}handleTimerNextVideo(e){var t;(t=this.store)==null||t.actions.internal.setTimerNextVideoRunning(e)}togglePictureInPicture(){var e;(e=this.store)==null||e.actions.internal.togglePictureInPicture()}focus(){var e,t,o;(o=(t=(e=this.svelteRootComponent)==null?void 0:e.keyboardControls)==null?void 0:t.focus)==null||o.call(t)}restoreFocus(){var e;(e=this.focusManager)==null||e.restoreFocus()}handleExternalKeyboardEvent(e){var t,o;return!!((o=(t=this.svelteRootComponent)==null?void 0:t.keyboardControls)!=null&&o.handleExternalKeyboardEvent(e))}setAutoplayNext(e){var t;(t=this.store)==null||t.actions.internal.setAutoplayNextEnabled(e)}getTotalViewTime(){var e,t;return(t=(e=this.statistics)==null?void 0:e.thinOneStat)==null?void 0:t.getTotalViewTime()}unmountComponent(e){e&&Na(e)}};var md=require("@vkontakte/videoplayer-shared/es2015"),zp=require("@vkontakte/videoplayer-core/es2015"),GT=()=>{window.customElements.define("vk-video-player",Fp)};
|